From d011693a970dbc96b115bb50965bb9486ab6b823 Mon Sep 17 00:00:00 2001 From: Jan Zerebecki Date: Sat, 25 Jul 2009 15:39:54 +0200 Subject: [PATCH] push ac694015ba9a1d7cf8fc6346c6e51d4c35a62962 --- .gitignore | 7 +- ANNOUNCE | 1275 +++++----- AUTHORS | 98 +- Make.rules.in | 7 +- VERSION | 2 +- configure | 188 +- configure.ac | 60 +- dlls/Makefile.in | 15 +- dlls/Maketest.rules.in | 1 - dlls/advapi32/advapi32.spec | 4 +- dlls/advapi32/registry.c | 8 +- dlls/advapi32/security.c | 2 - dlls/advapi32/tests/registry.c | 6 - dlls/advapi32/tests/security.c | 35 - dlls/advapi32/tests/service.c | 14 - dlls/appwiz.cpl/De.rc | 16 +- dlls/appwiz.cpl/En.rc | 13 +- dlls/appwiz.cpl/Fr.rc | 54 +- dlls/appwiz.cpl/Ja.rc | 12 +- dlls/appwiz.cpl/Ko.rc | 11 +- dlls/appwiz.cpl/Lt.rc | 21 +- dlls/appwiz.cpl/Makefile.in | 19 +- dlls/appwiz.cpl/Nl.rc | 15 +- dlls/appwiz.cpl/No.rc | 32 +- dlls/appwiz.cpl/Pt.rc | 39 +- dlls/appwiz.cpl/Ro.rc | 13 +- dlls/appwiz.cpl/Ru.rc | 57 +- dlls/appwiz.cpl/Si.rc | 13 +- dlls/appwiz.cpl/Sv.rc | 88 - dlls/appwiz.cpl/Zh.rc | 12 +- dlls/appwiz.cpl/appwiz.c | 137 +- dlls/appwiz.cpl/appwiz.ico | Bin 3262 -> 766 bytes dlls/appwiz.cpl/appwiz.rc | 21 +- dlls/appwiz.cpl/res.h | 8 - dlls/avifil32/Makefile.in | 22 - dlls/avifil32/avifile_Cs.rc | 2 - dlls/avifil32/avifile_Da.rc | 2 - dlls/avifil32/avifile_De.rc | 8 +- dlls/avifil32/avifile_En.rc | 4 +- dlls/avifil32/avifile_Es.rc | 2 - dlls/avifil32/avifile_Fr.rc | 29 +- dlls/avifil32/avifile_Hu.rc | 2 - dlls/avifil32/avifile_It.rc | 2 - dlls/avifil32/avifile_Ja.rc | 4 +- dlls/avifil32/avifile_Ko.rc | 2 - dlls/avifil32/avifile_Lt.rc | 55 - dlls/avifil32/avifile_Nl.rc | 2 - dlls/avifil32/avifile_No.rc | 2 - dlls/avifil32/avifile_Pl.rc | 2 - dlls/avifil32/avifile_Pt.rc | 2 - dlls/avifil32/avifile_Ro.rc | 57 - dlls/avifil32/avifile_Ru.rc | 37 +- dlls/avifil32/avifile_Si.rc | 4 +- dlls/avifil32/avifile_Sv.rc | 2 - dlls/avifil32/avifile_Tr.rc | 2 - dlls/avifil32/avifile_Uk.rc | 1 - dlls/avifil32/avifile_Zh.rc | 4 +- dlls/avifil32/avifile_private.h | 3 - dlls/avifil32/rsrc.rc | 33 +- dlls/avifile.dll16/Makefile.in | 2 + dlls/browseui/Makefile.in | 19 +- dlls/browseui/browseui.spec | 2 +- dlls/browseui/browseui_main.c | 9 - dlls/browseui/resids.h | 4 - dlls/browseui/rsrc.rc | 41 + dlls/browseui/rsrc_De.rc | 3 - dlls/browseui/rsrc_En.rc | 1 - dlls/browseui/rsrc_Es.rc | 1 - dlls/browseui/rsrc_Fr.rc | 1 - dlls/browseui/rsrc_Ja.rc | 42 - dlls/browseui/rsrc_Ko.rc | 1 - dlls/browseui/rsrc_Lt.rc | 4 +- dlls/browseui/rsrc_Nl.rc | 1 - dlls/browseui/rsrc_No.rc | 1 - dlls/browseui/rsrc_Pl.rc | 1 - dlls/browseui/rsrc_Pt.rc | 1 - dlls/browseui/rsrc_Ro.rc | 3 +- dlls/browseui/rsrc_Ru.rc | 8 +- dlls/browseui/rsrc_Si.rc | 4 +- dlls/browseui/rsrc_Sv.rc | 1 - dlls/browseui/rsrc_Zh.rc | 3 +- dlls/cabinet/tests/fdi.c | 40 +- dlls/cards/Makefile.in | 3 +- dlls/cards/cards.rc | 2 + dlls/comctl32/Makefile.in | 29 +- dlls/comctl32/comctl_Bg.rc | 2 - dlls/comctl32/comctl_Cs.rc | 2 - dlls/comctl32/comctl_De.rc | 22 +- dlls/comctl32/comctl_El.rc | 2 - dlls/comctl32/comctl_En.rc | 2 - dlls/comctl32/comctl_Eo.rc | 2 - dlls/comctl32/comctl_Es.rc | 2 - dlls/comctl32/comctl_Fr.rc | 25 +- dlls/comctl32/comctl_Hu.rc | 2 - dlls/comctl32/comctl_It.rc | 2 - dlls/comctl32/comctl_Ja.rc | 4 +- dlls/comctl32/comctl_Ko.rc | 2 - dlls/comctl32/comctl_Lt.rc | 4 +- dlls/comctl32/comctl_Nl.rc | 2 - dlls/comctl32/comctl_No.rc | 2 - dlls/comctl32/comctl_Pl.rc | 2 - dlls/comctl32/comctl_Pt.rc | 45 +- dlls/comctl32/comctl_Ro.rc | 4 +- dlls/comctl32/comctl_Ru.rc | 55 +- dlls/comctl32/comctl_Si.rc | 4 +- dlls/comctl32/comctl_Sk.rc | 2 - dlls/comctl32/comctl_Sv.rc | 2 - dlls/comctl32/comctl_Th.rc | 2 - dlls/comctl32/comctl_Tr.rc | 2 - dlls/comctl32/comctl_Uk.rc | 2 - dlls/comctl32/comctl_Zh.rc | 4 +- dlls/comctl32/dpa.c | 3 +- dlls/comctl32/header.c | 53 +- dlls/comctl32/listview.c | 426 +--- dlls/comctl32/progress.c | 16 - dlls/comctl32/rebar.c | 14 +- dlls/comctl32/rsrc.rc | 40 + dlls/comctl32/tests/datetime.c | 26 +- dlls/comctl32/tests/dpa.c | 4 +- dlls/comctl32/tests/header.c | 82 +- dlls/comctl32/tests/listview.c | 580 +---- dlls/comctl32/tests/rebar.c | 18 +- dlls/comctl32/tests/toolbar.c | 15 +- dlls/comctl32/tests/updown.c | 10 +- dlls/comctl32/toolbar.c | 547 ++-- dlls/comctl32/treeview.c | 20 +- dlls/comdlg32/Makefile.in | 33 +- dlls/comdlg32/cdlg_Bg.rc | 3 - dlls/comdlg32/cdlg_Ca.rc | 3 - dlls/comdlg32/cdlg_Cs.rc | 3 - dlls/comdlg32/cdlg_Da.rc | 3 - dlls/comdlg32/cdlg_De.rc | 91 +- dlls/comdlg32/cdlg_El.rc | 3 - dlls/comdlg32/cdlg_En.rc | 3 - dlls/comdlg32/cdlg_Eo.rc | 3 - dlls/comdlg32/cdlg_Es.rc | 3 - dlls/comdlg32/cdlg_Fi.rc | 3 - dlls/comdlg32/cdlg_Fr.rc | 431 ++-- dlls/comdlg32/cdlg_Hu.rc | 3 - dlls/comdlg32/cdlg_It.rc | 3 - dlls/comdlg32/cdlg_Ja.rc | 5 +- dlls/comdlg32/cdlg_Ko.rc | 3 - dlls/comdlg32/cdlg_Lt.rc | 54 +- dlls/comdlg32/cdlg_Nl.rc | 5 +- dlls/comdlg32/cdlg_No.rc | 3 - dlls/comdlg32/cdlg_Pl.rc | 3 - dlls/comdlg32/cdlg_Pt.rc | 287 +-- dlls/comdlg32/cdlg_Ro.rc | 5 +- dlls/comdlg32/cdlg_Ru.rc | 968 ++++--- dlls/comdlg32/cdlg_Si.rc | 5 +- dlls/comdlg32/cdlg_Sk.rc | 3 - dlls/comdlg32/cdlg_Sv.rc | 3 - dlls/comdlg32/cdlg_Th.rc | 3 - dlls/comdlg32/cdlg_Tr.rc | 3 - dlls/comdlg32/cdlg_Uk.rc | 3 - dlls/comdlg32/cdlg_Wa.rc | 3 - dlls/comdlg32/cdlg_Zh.rc | 5 +- dlls/comdlg32/cdlg_xx.rc | 4 +- dlls/comdlg32/filedlg.c | 108 +- dlls/comdlg32/rsrc.rc | 73 + dlls/comdlg32/tests/filedlg.c | 286 +-- dlls/comdlg32/tests/rsrc.rc | 2 +- dlls/comm.drv16/Makefile.in | 2 + dlls/compobj.dll16/Makefile.in | 2 + dlls/credui/Makefile.in | 19 +- dlls/credui/credui.rc | 21 + dlls/credui/credui_Da.rc | 2 - dlls/credui/credui_De.rc | 8 +- dlls/credui/credui_En.rc | 2 - dlls/credui/credui_Es.rc | 5 +- dlls/credui/credui_Fr.rc | 5 +- dlls/credui/credui_Ko.rc | 2 - dlls/credui/credui_Lt.rc | 4 +- dlls/credui/credui_Nl.rc | 2 - dlls/credui/credui_No.rc | 2 - dlls/credui/credui_Pl.rc | 2 - dlls/credui/credui_Pt.rc | 2 - dlls/credui/credui_Ro.rc | 4 +- dlls/credui/credui_Ru.rc | 27 +- dlls/credui/credui_Si.rc | 4 +- dlls/credui/credui_Sv.rc | 2 - dlls/credui/credui_Zh.rc | 4 +- dlls/credui/credui_resources.h | 3 - dlls/crypt32/Makefile.in | 13 +- dlls/crypt32/cert.c | 32 - dlls/crypt32/crypt32.rc | 34 + dlls/crypt32/crypt32.spec | 3 +- dlls/crypt32/crypt32_De.rc | 5 +- dlls/crypt32/crypt32_En.rc | 3 - dlls/crypt32/crypt32_Fr.rc | 482 ++-- dlls/crypt32/crypt32_Ko.rc | 3 - dlls/crypt32/crypt32_Lt.rc | 244 -- dlls/crypt32/crypt32_Nl.rc | 5 - dlls/crypt32/crypt32_No.rc | 125 +- dlls/crypt32/crypt32_Pt.rc | 31 +- dlls/crypt32/crypt32_Ro.rc | 244 -- dlls/crypt32/crypt32_Sv.rc | 5 +- dlls/crypt32/cryptres.h | 3 - dlls/crypt32/decode.c | 2 +- dlls/crypt32/encode.c | 11 +- dlls/crypt32/oid.c | 13 +- dlls/crypt32/tests/cert.c | 11 +- dlls/crypt32/tests/encode.c | 5 +- dlls/cryptdlg/Makefile.in | 10 +- dlls/cryptdlg/cryptdlg.rc | 29 + dlls/cryptdlg/cryptdlg_De.rc | 4 - dlls/cryptdlg/cryptdlg_En.rc | 4 +- dlls/cryptdlg/cryptdlg_Fr.rc | 26 +- dlls/cryptdlg/cryptdlg_Ko.rc | 4 +- dlls/cryptdlg/cryptdlg_Lt.rc | 41 - dlls/cryptdlg/cryptdlg_Nl.rc | 2 - dlls/cryptdlg/cryptdlg_Pt.rc | 40 - dlls/cryptdlg/cryptdlg_Ro.rc | 41 - dlls/cryptdlg/cryptres.h | 2 - dlls/cryptnet/cryptnet_main.c | 28 +- dlls/cryptui/Makefile.in | 10 +- dlls/cryptui/cryptui.rc | 10 + dlls/cryptui/cryptui_De.rc | 4 +- dlls/cryptui/cryptui_En.rc | 36 +- dlls/cryptui/cryptui_Fr.rc | 466 ---- dlls/cryptui/cryptui_Ko.rc | 17 +- dlls/cryptui/cryptui_Lt.rc | 466 ---- dlls/cryptui/cryptui_Nl.rc | 64 +- dlls/cryptui/cryptui_Pt.rc | 465 ---- dlls/cryptui/cryptuires.h | 4 - dlls/cryptui/main.c | 23 +- dlls/ctl3d.dll16/Makefile.in | 2 + dlls/ctl3dv2.dll16/Makefile.in | 2 + dlls/d3d10/d3d10_private.h | 38 +- dlls/d3d10/effect.c | 659 ++--- dlls/d3d8/directx.c | 36 +- dlls/d3d8/tests/device.c | 88 +- dlls/d3d8/tests/visual.c | 2 +- dlls/d3d9/device.c | 2 +- dlls/d3d9/directx.c | 28 +- dlls/d3d9/tests/device.c | 173 +- dlls/d3d9/tests/query.c | 23 +- dlls/d3d9/tests/visual.c | 188 +- dlls/d3dx8/Makefile.in | 17 + dlls/d3dx8/core.c | 148 ++ dlls/d3dx8/d3dx8.spec | 156 ++ dlls/d3dx8/d3dx8_main.c | 43 + dlls/d3dx8/d3dx8_private.h | 94 + dlls/d3dx8/math.c | 1524 +++++++++++ dlls/d3dx8/mesh.c | 247 ++ dlls/d3dx8/tests/Makefile.in | 14 + dlls/d3dx8/tests/math.c | 1523 +++++++++++ dlls/d3dx8/tests/mesh.c | 396 +++ dlls/d3dx9_36/Makefile.in | 3 +- dlls/d3dx9_36/core.c | 120 - dlls/d3dx9_36/d3dx9_36.spec | 184 +- dlls/d3dx9_36/d3dx9_36_private.h | 33 - dlls/d3dx9_36/font.c | 84 +- dlls/d3dx9_36/math.c | 2154 +++------------- dlls/d3dx9_36/mesh.c | 93 +- dlls/d3dx9_36/surface.c | 588 ++--- dlls/d3dx9_36/tests/Makefile.in | 2 +- dlls/d3dx9_36/tests/core.c | 148 +- dlls/d3dx9_36/tests/math.c | 3065 ++++++---------------- dlls/d3dx9_36/tests/mesh.c | 562 +---- dlls/d3dx9_36/tests/texture.c | 209 +- dlls/d3dxof/Makefile.in | 2 +- dlls/dbghelp/coff.c | 20 +- dlls/dbghelp/dbghelp_private.h | 6 +- dlls/dbghelp/dwarf.c | 4 +- dlls/dbghelp/dwarf.h | 12 - dlls/dbghelp/elf_module.c | 18 +- dlls/dbghelp/macho_module.c | 4 +- dlls/dbghelp/minidump.c | 62 +- dlls/dbghelp/module.c | 5 - dlls/dbghelp/msc.c | 14 +- dlls/dbghelp/pe_module.c | 4 +- dlls/dbghelp/source.c | 9 +- dlls/dbghelp/stabs.c | 43 +- dlls/dbghelp/symbol.c | 135 +- dlls/ddeml.dll16/Makefile.in | 2 + dlls/ddraw/device.c | 8 +- dlls/ddraw/executebuffer.c | 2 +- dlls/ddraw/tests/d3d.c | 1 - dlls/ddraw/tests/dsurface.c | 63 +- dlls/ddraw/tests/overlay.c | 3 +- dlls/ddraw/tests/refcount.c | 20 +- dlls/devenum/devenum.rc | 11 +- dlls/dispdib.dll16/Makefile.in | 2 + dlls/display.drv16/Makefile.in | 2 + dlls/dmband/Makefile.in | 2 +- dlls/dplayx/tests/dplayx.c | 133 - dlls/drmclien/Makefile.in | 13 - dlls/drmclien/drmclien.spec | 31 - dlls/drmclien/main.c | 42 - dlls/dsound/tests/dsound8.c | 4 +- dlls/dxdiagn/Makefile.in | 2 - dlls/dxdiagn/fil_data.idl | 45 - dlls/dxdiagn/provider.c | 119 +- dlls/dxgi/Makefile.in | 4 +- dlls/dxguid/Makefile.in | 4 +- dlls/dxguid/dx8guid.c | 1 + dlls/dxguid/dx9guid.c | 2 +- dlls/fusion/tests/asmname.c | 1 - dlls/gdi32/dc.c | 91 +- dlls/gdi32/dib.c | 2 +- dlls/gdi32/enhmfdrv/init.c | 2 - dlls/gdi32/freetype.c | 7 +- dlls/gdi32/gdi_private.h | 4 - dlls/gdi32/mapping.c | 70 +- dlls/gdi32/metafile.c | 186 +- dlls/gdi32/mfdrv/init.c | 2 - dlls/gdi32/tests/bitmap.c | 83 +- dlls/gdi32/tests/font.c | 76 +- dlls/gdi32/tests/mapping.c | 218 -- dlls/gdi32/tests/metafile.c | 209 +- dlls/gdiplus/brush.c | 29 +- dlls/gdiplus/gdiplus.spec | 6 +- dlls/gdiplus/gdiplus_private.h | 3 - dlls/gdiplus/graphics.c | 295 +-- dlls/gdiplus/image.c | 2 +- dlls/gdiplus/tests/brush.c | 66 - dlls/gdiplus/tests/graphics.c | 578 +---- dlls/gphoto2.ds/Makefile.in | 16 +- dlls/gphoto2.ds/gphoto2_Da.rc | 2 - dlls/gphoto2.ds/gphoto2_De.rc | 10 +- dlls/gphoto2.ds/gphoto2_En.rc | 2 - dlls/gphoto2.ds/gphoto2_Es.rc | 5 +- dlls/gphoto2.ds/gphoto2_Fr.rc | 20 +- dlls/gphoto2.ds/gphoto2_Ko.rc | 2 - dlls/gphoto2.ds/gphoto2_Lt.rc | 4 +- dlls/gphoto2.ds/gphoto2_Nl.rc | 2 - dlls/gphoto2.ds/gphoto2_No.rc | 2 - dlls/gphoto2.ds/gphoto2_Pl.rc | 2 - dlls/gphoto2.ds/gphoto2_Pt.rc | 22 +- dlls/gphoto2.ds/gphoto2_Ru.rc | 27 +- dlls/gphoto2.ds/gphoto2_Si.rc | 4 +- dlls/gphoto2.ds/gphoto2_Sv.rc | 2 - dlls/gphoto2.ds/gphoto2_Zh.rc | 4 +- dlls/gphoto2.ds/resource.h | 5 - dlls/gphoto2.ds/rsrc.rc | 43 + dlls/hal/hal.c | 6 - dlls/hal/hal.spec | 2 +- dlls/hhctrl.ocx/Cs.rc | 2 - dlls/hhctrl.ocx/Da.rc | 2 - dlls/hhctrl.ocx/De.rc | 10 +- dlls/hhctrl.ocx/El.rc | 2 - dlls/hhctrl.ocx/En.rc | 12 - dlls/hhctrl.ocx/Fi.rc | 2 - dlls/hhctrl.ocx/Fr.rc | 13 +- dlls/hhctrl.ocx/Hu.rc | 2 - dlls/hhctrl.ocx/Ko.rc | 2 - dlls/hhctrl.ocx/Lt.rc | 4 +- dlls/hhctrl.ocx/Makefile.in | 22 +- dlls/hhctrl.ocx/Nl.rc | 2 - dlls/hhctrl.ocx/No.rc | 2 - dlls/hhctrl.ocx/Pl.rc | 2 - dlls/hhctrl.ocx/Pt.rc | 2 - dlls/hhctrl.ocx/Ru.rc | 61 +- dlls/hhctrl.ocx/Si.rc | 4 +- dlls/hhctrl.ocx/Sv.rc | 2 - dlls/hhctrl.ocx/Tr.rc | 2 - dlls/hhctrl.ocx/Zh.rc | 4 +- dlls/hhctrl.ocx/chm.c | 12 +- dlls/hhctrl.ocx/hhctrl.c | 33 +- dlls/hhctrl.ocx/hhctrl.h | 2 +- dlls/hhctrl.ocx/hhctrl.rc | 50 + dlls/hhctrl.ocx/resource.h | 5 - dlls/iccvid/Makefile.in | 19 +- dlls/iccvid/iccvid_Da.rc | 2 - dlls/iccvid/iccvid_De.rc | 4 - dlls/iccvid/iccvid_En.rc | 2 - dlls/iccvid/iccvid_Fr.rc | 9 +- dlls/iccvid/iccvid_Hu.rc | 2 - dlls/iccvid/iccvid_Ja.rc | 30 - dlls/iccvid/iccvid_Ko.rc | 2 - dlls/iccvid/iccvid_Lt.rc | 30 - dlls/iccvid/iccvid_Nl.rc | 2 - dlls/iccvid/iccvid_No.rc | 2 - dlls/iccvid/iccvid_Pl.rc | 2 - dlls/iccvid/iccvid_Pt.rc | 2 - dlls/iccvid/iccvid_Ro.rc | 4 - dlls/iccvid/iccvid_Ru.rc | 9 +- dlls/iccvid/iccvid_Si.rc | 4 +- dlls/iccvid/iccvid_Sv.rc | 2 - dlls/iccvid/iccvid_Tr.rc | 2 - dlls/iccvid/iccvid_private.h | 2 - dlls/iccvid/rsrc.rc | 36 + dlls/imm.dll16/Makefile.in | 2 + dlls/iphlpapi/iphlpapi_main.c | 6 +- dlls/iphlpapi/tests/iphlpapi.c | 1 - dlls/itss/Makefile.in | 2 +- dlls/jscript/Makefile.in | 13 +- dlls/jscript/array.c | 125 +- dlls/jscript/bool.c | 100 +- dlls/jscript/date.c | 3764 +++++++++------------------- dlls/jscript/dispex.c | 20 +- dlls/jscript/engine.c | 50 +- dlls/jscript/error.c | 481 ---- dlls/jscript/function.c | 88 +- dlls/jscript/global.c | 93 +- dlls/jscript/jscript.h | 42 +- dlls/jscript/jscript_De.rc | 37 - dlls/jscript/jscript_En.rc | 40 - dlls/jscript/jscript_Fr.rc | 40 - dlls/jscript/jscript_Lt.rc | 38 - dlls/jscript/jscript_Nl.rc | 40 - dlls/jscript/jscript_main.c | 2 +- dlls/jscript/jsutils.c | 95 +- dlls/jscript/math.c | 1 - dlls/jscript/number.c | 127 +- dlls/jscript/object.c | 72 +- dlls/jscript/parser.y | 76 +- dlls/jscript/regexp.c | 22 +- dlls/jscript/resource.h | 35 - dlls/jscript/string.c | 586 +---- dlls/jscript/tests/api.js | 315 +-- dlls/jscript/tests/lang.js | 23 +- dlls/jscript/tests/regexp.js | 18 +- dlls/kernel32/Makefile.in | 7 +- dlls/kernel32/except.c | 9 +- dlls/kernel32/kernel.rc | 29 + dlls/kernel32/kernel32.spec | 3 +- dlls/kernel32/kernel_private.h | 1 - dlls/kernel32/ne_module.c | 43 +- dlls/kernel32/nls/winerr_deu.mc | 529 ++-- dlls/kernel32/nls/winerr_enu.mc | 19 +- dlls/kernel32/nls/winerr_fra.mc | 1219 +++++---- dlls/kernel32/nls/winerr_kor.mc | 6 - dlls/kernel32/nls/winerr_lth.mc | 3736 --------------------------- dlls/kernel32/nls/winerr_nld.mc | 6 - dlls/kernel32/nls/winerr_nor.mc | 1 - dlls/kernel32/nls/winerr_plk.mc | 1 - dlls/kernel32/path.c | 53 +- dlls/kernel32/process.c | 38 +- dlls/kernel32/relay16.c | 49 +- dlls/kernel32/tests/codepage.c | 4 +- dlls/kernel32/tests/virtual.c | 40 +- dlls/kernel32/tests/volume.c | 4 +- dlls/kernel32/volume.c | 66 +- dlls/keyboard.drv16/Makefile.in | 2 + dlls/loadperf/Makefile.in | 2 +- dlls/localspl/Makefile.in | 18 +- dlls/localspl/localspl.rc | 18 + dlls/localspl/localspl_private.h | 1 - dlls/localspl/spl_Da.rc | 4 +- dlls/localspl/spl_De.rc | 4 - dlls/localspl/spl_En.rc | 2 - dlls/localspl/spl_Fr.rc | 2 - dlls/localspl/spl_Ko.rc | 2 - dlls/localspl/spl_Lt.rc | 32 - dlls/localspl/spl_Nl.rc | 2 - dlls/localspl/spl_No.rc | 2 - dlls/localspl/spl_Pl.rc | 2 - dlls/localspl/spl_Pt.rc | 2 - dlls/localspl/spl_Ro.rc | 4 - dlls/localspl/spl_Ru.rc | 9 +- dlls/localspl/spl_Si.rc | 4 +- dlls/localspl/spl_Sv.rc | 2 - dlls/localspl/spl_Zh.rc | 4 +- dlls/localui/Makefile.in | 18 +- dlls/localui/localui.h | 2 - dlls/localui/localui.rc | 20 + dlls/localui/ui_Da.rc | 2 - dlls/localui/ui_De.rc | 14 +- dlls/localui/ui_En.rc | 2 - dlls/localui/ui_Fr.rc | 5 +- dlls/localui/ui_Ko.rc | 2 - dlls/localui/ui_Lt.rc | 59 - dlls/localui/ui_Nl.rc | 2 - dlls/localui/ui_No.rc | 2 - dlls/localui/ui_Pl.rc | 2 - dlls/localui/ui_Pt.rc | 2 - dlls/localui/ui_Ro.rc | 4 +- dlls/localui/ui_Ru.rc | 27 +- dlls/localui/ui_Si.rc | 4 +- dlls/localui/ui_Sv.rc | 2 - dlls/localui/ui_Zh.rc | 4 +- dlls/lzexpand.dll16/Makefile.in | 2 + dlls/mapi32/version.rc | 4 - dlls/mlang/mlang.c | 67 +- dlls/mlang/tests/mlang.c | 156 +- dlls/mountmgr.sys/device.c | 630 ++--- dlls/mountmgr.sys/diskarb.c | 29 +- dlls/mountmgr.sys/hal.c | 49 +- dlls/mountmgr.sys/mountmgr.c | 35 +- dlls/mountmgr.sys/mountmgr.h | 12 +- dlls/mouse.drv16/Makefile.in | 2 + dlls/mpr/Makefile.in | 26 +- dlls/mpr/mpr.rc | 48 + dlls/mpr/mpr_Bg.rc | 2 - dlls/mpr/mpr_Cs.rc | 2 - dlls/mpr/mpr_Da.rc | 2 - dlls/mpr/mpr_De.rc | 4 - dlls/mpr/mpr_En.rc | 2 - dlls/mpr/mpr_Eo.rc | 2 - dlls/mpr/mpr_Es.rc | 2 - dlls/mpr/mpr_Fr.rc | 35 +- dlls/mpr/mpr_Hu.rc | 2 - dlls/mpr/mpr_It.rc | 2 - dlls/mpr/mpr_Ja.rc | 4 +- dlls/mpr/mpr_Ko.rc | 2 - dlls/mpr/mpr_Lt.rc | 51 - dlls/mpr/mpr_Nl.rc | 2 - dlls/mpr/mpr_No.rc | 2 - dlls/mpr/mpr_Pl.rc | 2 - dlls/mpr/mpr_Pt.rc | 12 +- dlls/mpr/mpr_Ro.rc | 4 +- dlls/mpr/mpr_Ru.rc | 21 +- dlls/mpr/mpr_Si.rc | 4 +- dlls/mpr/mpr_Sv.rc | 2 - dlls/mpr/mpr_Tr.rc | 2 - dlls/mpr/mpr_Zh.rc | 4 +- dlls/mpr/mprres.h | 3 - dlls/msacm.dll16/Makefile.in | 2 + dlls/msacm32/Makefile.in | 23 +- dlls/msacm32/msacm.rc | 46 + dlls/msacm32/msacm_Cs.rc | 2 - dlls/msacm32/msacm_Da.rc | 2 - dlls/msacm32/msacm_De.rc | 4 - dlls/msacm32/msacm_En.rc | 2 - dlls/msacm32/msacm_Es.rc | 2 - dlls/msacm32/msacm_Fr.rc | 21 +- dlls/msacm32/msacm_Hu.rc | 2 - dlls/msacm32/msacm_It.rc | 2 - dlls/msacm32/msacm_Ja.rc | 4 +- dlls/msacm32/msacm_Ko.rc | 2 - dlls/msacm32/msacm_Lt.rc | 4 +- dlls/msacm32/msacm_Nl.rc | 2 - dlls/msacm32/msacm_No.rc | 2 - dlls/msacm32/msacm_Pl.rc | 3 - dlls/msacm32/msacm_Pt.rc | 2 - dlls/msacm32/msacm_Ro.rc | 4 +- dlls/msacm32/msacm_Ru.rc | 21 +- dlls/msacm32/msacm_Si.rc | 4 +- dlls/msacm32/msacm_Sv.rc | 2 - dlls/msacm32/msacm_Tr.rc | 2 - dlls/msacm32/msacm_Zh.rc | 4 +- dlls/msacm32/wineacm.h | 3 - dlls/msctf/compartmentmgr.c | 295 +-- dlls/msctf/context.c | 24 +- dlls/msctf/documentmgr.c | 160 +- dlls/msctf/inputprocessor.c | 107 +- dlls/msctf/msctf.c | 11 +- dlls/msctf/msctf.spec | 2 +- dlls/msctf/msctf_internal.h | 3 - dlls/msctf/tests/inputprocessor.c | 200 +- dlls/msctf/threadmgr.c | 214 +- dlls/msdmo/rsrc.rc | 2 +- dlls/mshtml/Bg.rc | 1 - dlls/mshtml/Da.rc | 1 - dlls/mshtml/De.rc | 3 +- dlls/mshtml/En.rc | 1 - dlls/mshtml/Es.rc | 1 - dlls/mshtml/Fi.rc | 1 - dlls/mshtml/Fr.rc | 16 +- dlls/mshtml/Hu.rc | 1 - dlls/mshtml/Ja.rc | 13 +- dlls/mshtml/Ko.rc | 1 - dlls/mshtml/Lt.rc | 4 +- dlls/mshtml/Makefile.in | 24 +- dlls/mshtml/Nl.rc | 1 - dlls/mshtml/No.rc | 1 - dlls/mshtml/Pl.rc | 1 - dlls/mshtml/Pt.rc | 30 +- dlls/mshtml/Ro.rc | 3 +- dlls/mshtml/Ru.rc | 36 +- dlls/mshtml/Si.rc | 15 +- dlls/mshtml/Sv.rc | 1 - dlls/mshtml/Tr.rc | 1 - dlls/mshtml/Zh.rc | 4 +- dlls/mshtml/dispex.c | 2 - dlls/mshtml/htmlelemcol.c | 51 +- dlls/mshtml/htmllocation.c | 2 +- dlls/mshtml/main.c | 2 - dlls/mshtml/mshtml_private.h | 2 - dlls/mshtml/nsembed.c | 4 + dlls/mshtml/omnavigator.c | 2 +- dlls/mshtml/resource.h | 4 - dlls/mshtml/rsrc.rc | 31 + dlls/mshtml/tests/dom.c | 54 +- dlls/msi/Makefile.in | 26 +- dlls/msi/custom.c | 30 +- dlls/msi/database.c | 8 +- dlls/msi/dialog.c | 54 +- dlls/msi/msi.rc | 31 + dlls/msi/msi_Bg.rc | 2 - dlls/msi/msi_Da.rc | 2 - dlls/msi/msi_De.rc | 4 +- dlls/msi/msi_En.rc | 2 - dlls/msi/msi_Eo.rc | 2 - dlls/msi/msi_Es.rc | 2 - dlls/msi/msi_Fi.rc | 2 - dlls/msi/msi_Fr.rc | 19 +- dlls/msi/msi_Hu.rc | 2 - dlls/msi/msi_It.rc | 2 - dlls/msi/msi_Ko.rc | 2 - dlls/msi/msi_Lt.rc | 39 - dlls/msi/msi_Nl.rc | 2 - dlls/msi/msi_No.rc | 2 - dlls/msi/msi_Pl.rc | 2 - dlls/msi/msi_Pt.rc | 2 - dlls/msi/msi_Ro.rc | 4 +- dlls/msi/msi_Ru.rc | 2 - dlls/msi/msi_Si.rc | 4 +- dlls/msi/msi_Sv.rc | 2 - dlls/msi/msi_Tr.rc | 2 - dlls/msi/msi_Zh.rc | 4 +- dlls/msi/msipriv.h | 4 - dlls/msi/msiquery.c | 2 + dlls/msi/table.c | 58 +- dlls/msi/tests/db.c | 277 -- dlls/msi/tests/install.c | 20 +- dlls/msrle32/Makefile.in | 23 +- dlls/msrle32/msrle_Bg.rc | 2 - dlls/msrle32/msrle_Cs.rc | 2 - dlls/msrle32/msrle_Da.rc | 2 - dlls/msrle32/msrle_De.rc | 8 +- dlls/msrle32/msrle_En.rc | 8 +- dlls/msrle32/msrle_Es.rc | 2 - dlls/msrle32/msrle_Fr.rc | 11 +- dlls/msrle32/msrle_Hu.rc | 2 - dlls/msrle32/msrle_It.rc | 2 - dlls/msrle32/msrle_Ja.rc | 4 +- dlls/msrle32/msrle_Ko.rc | 2 - dlls/msrle32/msrle_Lt.rc | 33 - dlls/msrle32/msrle_Nl.rc | 2 - dlls/msrle32/msrle_No.rc | 2 - dlls/msrle32/msrle_Pl.rc | 2 - dlls/msrle32/msrle_Pt.rc | 2 - dlls/msrle32/msrle_Ro.rc | 4 +- dlls/msrle32/msrle_Ru.rc | 2 - dlls/msrle32/msrle_Si.rc | 4 +- dlls/msrle32/msrle_Sv.rc | 2 - dlls/msrle32/msrle_Tr.rc | 2 - dlls/msrle32/rsrc.rc | 53 + dlls/msvcrt/cppexcept.c | 8 - dlls/msvcrt/errno.c | 1 - dlls/msvcrt/except.c | 5 - dlls/msvcrt/misc.c | 5 - dlls/msvfw32/Makefile.in | 23 +- dlls/msvfw32/msvfw32_Da.rc | 2 - dlls/msvfw32/msvfw32_De.rc | 10 +- dlls/msvfw32/msvfw32_En.rc | 2 - dlls/msvfw32/msvfw32_Es.rc | 2 - dlls/msvfw32/msvfw32_Fr.rc | 39 +- dlls/msvfw32/msvfw32_Hu.rc | 2 - dlls/msvfw32/msvfw32_Ko.rc | 2 - dlls/msvfw32/msvfw32_Lt.rc | 56 - dlls/msvfw32/msvfw32_Nl.rc | 2 - dlls/msvfw32/msvfw32_No.rc | 2 - dlls/msvfw32/msvfw32_Pl.rc | 2 - dlls/msvfw32/msvfw32_Pt.rc | 2 - dlls/msvfw32/msvfw32_Ru.rc | 2 - dlls/msvfw32/msvfw32_Si.rc | 4 +- dlls/msvfw32/msvfw32_Sv.rc | 2 - dlls/msvfw32/msvfw32_Tr.rc | 2 - dlls/msvfw32/msvfw32_Zh.rc | 4 +- dlls/msvfw32/msvideo_main.c | 175 +- dlls/msvfw32/msvideo_private.h | 4 +- dlls/msvfw32/rsrc.rc | 38 + dlls/msvidc32/Makefile.in | 19 +- dlls/msvidc32/msvidc32_Da.rc | 2 - dlls/msvidc32/msvidc32_De.rc | 4 - dlls/msvidc32/msvidc32_En.rc | 2 - dlls/msvidc32/msvidc32_Fr.rc | 7 +- dlls/msvidc32/msvidc32_Hu.rc | 2 - dlls/msvidc32/msvidc32_Ja.rc | 30 - dlls/msvidc32/msvidc32_Ko.rc | 2 - dlls/msvidc32/msvidc32_Lt.rc | 30 - dlls/msvidc32/msvidc32_Nl.rc | 2 - dlls/msvidc32/msvidc32_No.rc | 2 - dlls/msvidc32/msvidc32_Pl.rc | 2 - dlls/msvidc32/msvidc32_Pt.rc | 2 - dlls/msvidc32/msvidc32_Ro.rc | 4 - dlls/msvidc32/msvidc32_Ru.rc | 2 - dlls/msvidc32/msvidc32_Si.rc | 4 +- dlls/msvidc32/msvidc32_Sv.rc | 2 - dlls/msvidc32/msvidc32_Tr.rc | 2 - dlls/msvidc32/msvidc32_private.h | 2 - dlls/msvidc32/rsrc.rc | 36 + dlls/msvideo.dll16/Makefile.in | 2 + dlls/mswsock/version.rc | 2 +- dlls/ntdll/directory.c | 23 - dlls/ntdll/heap.c | 32 +- dlls/ntdll/loader.c | 9 +- dlls/ntdll/nt.c | 11 +- dlls/ntdll/ntdll.spec | 2 - dlls/ntdll/ntdll_misc.h | 9 +- dlls/ntdll/process.c | 18 +- dlls/ntdll/relay.c | 49 +- dlls/ntdll/server.c | 49 +- dlls/ntdll/signal_i386.c | 99 +- dlls/ntdll/sync.c | 2 +- dlls/ntdll/thread.c | 3 +- dlls/ntdll/virtual.c | 90 +- dlls/ole2.dll16/Makefile.in | 2 + dlls/ole2conv.dll16/Makefile.in | 2 + dlls/ole2disp.dll16/Makefile.in | 2 + dlls/ole2nls.dll16/Makefile.in | 2 + dlls/ole2prox.dll16/Makefile.in | 2 + dlls/ole2thk.dll16/Makefile.in | 2 + dlls/ole32/Makefile.in | 2 +- dlls/ole32/clipboard.c | 46 - dlls/ole32/compobj.c | 989 ++++---- dlls/ole32/compobj_private.h | 4 +- dlls/ole32/defaulthandler.c | 69 +- dlls/ole32/ole2.c | 2 +- dlls/ole32/ole32.spec | 2 +- dlls/ole32/ole32res.rc | 14 +- dlls/ole32/stubmanager.c | 324 +-- dlls/ole32/tests/clipboard.c | 9 - dlls/ole32/tests/compobj.c | 142 +- dlls/ole32/tests/marshal.c | 4 +- dlls/ole32/tests/moniker.c | 6 +- dlls/ole32/tests/usrmarshal.c | 2 +- dlls/ole32/version.rc | 24 + dlls/oleacc/Makefile.in | 10 +- dlls/oleacc/main.c | 6 - dlls/oleacc/oleacc.rc | 30 + dlls/oleacc/oleacc.spec | 2 +- dlls/oleacc/oleacc_De.rc | 4 - dlls/oleacc/oleacc_En.rc | 2 - dlls/oleacc/oleacc_Fr.rc | 54 +- dlls/oleacc/oleacc_Ko.rc | 2 - dlls/oleacc/oleacc_Lt.rc | 4 +- dlls/oleacc/oleacc_Nl.rc | 2 - dlls/oleacc/oleacc_Pl.rc | 2 - dlls/oleacc/oleacc_Pt.rc | 94 - dlls/oleaut32/Makefile.in | 27 +- dlls/oleaut32/oleaut32.rc | 56 + dlls/oleaut32/oleaut32_Bg.rc | 2 - dlls/oleaut32/oleaut32_Cz.rc | 2 - dlls/oleaut32/oleaut32_Da.rc | 2 - dlls/oleaut32/oleaut32_De.rc | 4 - dlls/oleaut32/oleaut32_El.rc | 2 - dlls/oleaut32/oleaut32_En.rc | 2 - dlls/oleaut32/oleaut32_Eo.rc | 2 - dlls/oleaut32/oleaut32_Es.rc | 2 - dlls/oleaut32/oleaut32_Fr.rc | 2 - dlls/oleaut32/oleaut32_Hu.rc | 2 - dlls/oleaut32/oleaut32_It.rc | 2 - dlls/oleaut32/oleaut32_Ko.rc | 2 - dlls/oleaut32/oleaut32_Lt.rc | 36 - dlls/oleaut32/oleaut32_Nl.rc | 2 - dlls/oleaut32/oleaut32_No.rc | 2 - dlls/oleaut32/oleaut32_Pl.rc | 2 - dlls/oleaut32/oleaut32_Pt.rc | 2 - dlls/oleaut32/oleaut32_Ro.rc | 4 +- dlls/oleaut32/oleaut32_Ru.rc | 2 - dlls/oleaut32/oleaut32_Si.rc | 4 +- dlls/oleaut32/oleaut32_Sv.rc | 2 - dlls/oleaut32/oleaut32_Th.rc | 2 - dlls/oleaut32/oleaut32_Tr.rc | 2 - dlls/oleaut32/oleaut32_Zh.rc | 4 +- dlls/oleaut32/olefont.c | 4 +- dlls/oleaut32/olepicture.c | 8 +- dlls/oleaut32/resource.h | 2 - dlls/oleaut32/tests/usrmarshal.c | 172 +- dlls/oleaut32/tests/vartype.c | 100 - dlls/oleaut32/typelib.c | 6 +- dlls/oleaut32/typelib2.c | 2 +- dlls/oleaut32/usrmarshal.c | 22 +- dlls/oleaut32/variant.c | 6 +- dlls/oleaut32/vartype.c | 10 - dlls/olecli.dll16/Makefile.in | 2 + dlls/oledlg/Makefile.in | 22 +- dlls/oledlg/oledlg_Cs.rc | 2 - dlls/oledlg/oledlg_Da.rc | 2 - dlls/oledlg/oledlg_De.rc | 38 +- dlls/oledlg/oledlg_En.rc | 2 - dlls/oledlg/oledlg_Es.rc | 2 - dlls/oledlg/oledlg_Fr.rc | 91 +- dlls/oledlg/oledlg_Hu.rc | 2 - dlls/oledlg/oledlg_It.rc | 2 - dlls/oledlg/oledlg_Ja.rc | 4 +- dlls/oledlg/oledlg_Ko.rc | 2 - dlls/oledlg/oledlg_Lt.rc | 100 - dlls/oledlg/oledlg_Nl.rc | 2 - dlls/oledlg/oledlg_No.rc | 2 - dlls/oledlg/oledlg_Pl.rc | 2 - dlls/oledlg/oledlg_Pt.rc | 59 +- dlls/oledlg/oledlg_Ru.rc | 2 - dlls/oledlg/oledlg_Si.rc | 4 +- dlls/oledlg/oledlg_Sv.rc | 2 - dlls/oledlg/oledlg_Tr.rc | 2 - dlls/oledlg/oledlg_Zh.rc | 4 +- dlls/oledlg/resource.h | 2 - dlls/oledlg/rsrc.rc | 54 + dlls/olepro32/README | 9 + dlls/olesvr.dll16/Makefile.in | 2 + dlls/opengl32/tests/opengl.c | 2 +- dlls/rasapi16.dll16/Makefile.in | 2 + dlls/riched20/editor.c | 99 +- dlls/riched20/paint.c | 131 +- dlls/riched20/reader.c | 27 +- dlls/riched20/rtf.h | 2 +- dlls/riched20/tests/editor.c | 54 +- dlls/rpcrt4/cproxy.c | 2 - dlls/rpcrt4/ndr_stubless.c | 13 +- dlls/rpcrt4/ndr_stubless.h | 2 +- dlls/rpcrt4/rpc_assoc.c | 4 +- dlls/rpcrt4/rpc_assoc.h | 2 +- dlls/rpcrt4/rpc_binding.c | 2 +- dlls/rpcrt4/rpc_defs.h | 18 +- dlls/rpcrt4/rpc_epmap.c | 16 +- dlls/rpcrt4/rpc_message.c | 49 +- dlls/rpcrt4/rpc_message.h | 14 +- dlls/rtutils/Makefile.in | 15 - dlls/rtutils/main.c | 47 - dlls/rtutils/rtutils.spec | 56 - dlls/rtutils/tracing.c | 64 - dlls/sane.ds/Makefile.in | 19 +- dlls/sane.ds/resource.h | 4 - dlls/sane.ds/rsrc.rc | 43 + dlls/sane.ds/sane_Da.rc | 2 - dlls/sane.ds/sane_De.rc | 4 - dlls/sane.ds/sane_En.rc | 2 - dlls/sane.ds/sane_Es.rc | 5 +- dlls/sane.ds/sane_Fi.rc | 2 - dlls/sane.ds/sane_Fr.rc | 2 - dlls/sane.ds/sane_Ja.rc | 45 - dlls/sane.ds/sane_Ko.rc | 2 - dlls/sane.ds/sane_Lt.rc | 45 - dlls/sane.ds/sane_Nl.rc | 2 - dlls/sane.ds/sane_No.rc | 2 - dlls/sane.ds/sane_Pl.rc | 2 - dlls/sane.ds/sane_Pt.rc | 2 - dlls/sane.ds/sane_Ro.rc | 4 +- dlls/sane.ds/sane_Ru.rc | 2 - dlls/sane.ds/sane_Si.rc | 4 +- dlls/sane.ds/sane_Sv.rc | 2 - dlls/sane.ds/sane_Zh.rc | 4 +- dlls/secur32/dispatcher.c | 30 +- dlls/serialui/Bg.rc | 2 - dlls/serialui/Cs.rc | 2 - dlls/serialui/Da.rc | 2 - dlls/serialui/De.rc | 6 +- dlls/serialui/En.rc | 2 - dlls/serialui/Eo.rc | 2 - dlls/serialui/Es.rc | 2 - dlls/serialui/Fi.rc | 2 - dlls/serialui/Fr.rc | 36 +- dlls/serialui/Hu.rc | 2 - dlls/serialui/It.rc | 2 - dlls/serialui/Ja.rc | 4 +- dlls/serialui/Ko.rc | 2 - dlls/serialui/Lt.rc | 46 - dlls/serialui/Makefile.in | 24 +- dlls/serialui/Nl.rc | 2 - dlls/serialui/No.rc | 2 - dlls/serialui/Pt.rc | 2 - dlls/serialui/Ru.rc | 2 - dlls/serialui/Si.rc | 4 +- dlls/serialui/Sv.rc | 2 - dlls/serialui/Tr.rc | 2 - dlls/serialui/Zh.rc | 4 +- dlls/serialui/serialui.h | 3 - dlls/serialui/serialui_rc.rc | 44 + dlls/setupapi/Bg.rc | 2 - dlls/setupapi/Cs.rc | 2 - dlls/setupapi/Da.rc | 2 - dlls/setupapi/De.rc | 4 +- dlls/setupapi/En.rc | 2 - dlls/setupapi/Eo.rc | 2 - dlls/setupapi/Es.rc | 2 - dlls/setupapi/Fi.rc | 2 - dlls/setupapi/Fr.rc | 19 +- dlls/setupapi/Hu.rc | 2 - dlls/setupapi/It.rc | 2 - dlls/setupapi/Ja.rc | 4 +- dlls/setupapi/Ko.rc | 2 - dlls/setupapi/Lt.rc | 61 - dlls/setupapi/Makefile.in | 27 +- dlls/setupapi/Nl.rc | 2 - dlls/setupapi/No.rc | 2 - dlls/setupapi/Pl.rc | 2 - dlls/setupapi/Pt.rc | 31 +- dlls/setupapi/Ro.rc | 4 +- dlls/setupapi/Ru.rc | 2 - dlls/setupapi/Si.rc | 24 +- dlls/setupapi/Sk.rc | 2 - dlls/setupapi/Sv.rc | 2 - dlls/setupapi/Tr.rc | 2 - dlls/setupapi/Zh.rc | 4 +- dlls/setupapi/setupapi.rc | 50 + dlls/setupapi/setupapi_private.h | 3 - dlls/shdoclc/Bg.rc | 1 - dlls/shdoclc/Da.rc | 1 - dlls/shdoclc/De.rc | 71 +- dlls/shdoclc/En.rc | 221 +- dlls/shdoclc/Es.rc | 1 - dlls/shdoclc/Fi.rc | 1 - dlls/shdoclc/Fr.rc | 158 +- dlls/shdoclc/Hu.rc | 1 - dlls/shdoclc/Ko.rc | 1 - dlls/shdoclc/Lt.rc | 251 -- dlls/shdoclc/Makefile.in | 20 +- dlls/shdoclc/Nl.rc | 1 - dlls/shdoclc/No.rc | 1 - dlls/shdoclc/Pt.rc | 62 +- dlls/shdoclc/Ru.rc | 1 - dlls/shdoclc/Si.rc | 3 +- dlls/shdoclc/Sv.rc | 1 - dlls/shdoclc/Tr.rc | 1 - dlls/shdoclc/Zh.rc | 3 +- dlls/shdoclc/rsrc.rc | 41 + dlls/shdoclc/shdoclc.h | 3 - dlls/shdocvw/oleobject.c | 3 - dlls/shdocvw/shdocvw.rc | 10 +- dlls/shdocvw/version.rc | 27 + dlls/shell.dll16/Makefile.in | 2 + dlls/shell32/Makefile.in | 34 +- dlls/shell32/control.c | 43 +- dlls/shell32/cpanel.h | 1 - dlls/shell32/dialogs.c | 8 +- dlls/shell32/shell32.spec | 4 +- dlls/shell32/shell32_Bg.rc | 2 - dlls/shell32/shell32_Ca.rc | 2 - dlls/shell32/shell32_Cs.rc | 2 - dlls/shell32/shell32_Da.rc | 2 - dlls/shell32/shell32_De.rc | 132 +- dlls/shell32/shell32_En.rc | 8 +- dlls/shell32/shell32_Eo.rc | 2 - dlls/shell32/shell32_Es.rc | 2 - dlls/shell32/shell32_Fi.rc | 2 - dlls/shell32/shell32_Fr.rc | 54 +- dlls/shell32/shell32_Hu.rc | 2 - dlls/shell32/shell32_It.rc | 2 - dlls/shell32/shell32_Ja.rc | 4 +- dlls/shell32/shell32_Ko.rc | 2 - dlls/shell32/shell32_Lt.rc | 16 +- dlls/shell32/shell32_Nl.rc | 106 +- dlls/shell32/shell32_No.rc | 64 +- dlls/shell32/shell32_Pl.rc | 2 - dlls/shell32/shell32_Pt.rc | 255 +- dlls/shell32/shell32_Ro.rc | 82 +- dlls/shell32/shell32_Ru.rc | 2 - dlls/shell32/shell32_Si.rc | 13 +- dlls/shell32/shell32_Sk.rc | 2 - dlls/shell32/shell32_Sv.rc | 2 - dlls/shell32/shell32_Tr.rc | 2 - dlls/shell32/shell32_Uk.rc | 2 - dlls/shell32/shell32_Wa.rc | 2 - dlls/shell32/shell32_Zh.rc | 4 +- dlls/shell32/shellord.c | 60 +- dlls/shell32/shellpath.c | 21 +- dlls/shell32/shfldr_desktop.c | 14 +- dlls/shell32/shres.rc | 46 + dlls/shell32/shresdef.h | 7 - dlls/shell32/tests/shellpath.c | 18 +- dlls/shell32/tests/shfldr_special.c | 15 +- dlls/shell32/tests/shlexec.c | 17 +- dlls/shell32/tests/shlfolder.c | 12 +- dlls/shlwapi/Makefile.in | 26 +- dlls/shlwapi/resource.h | 3 - dlls/shlwapi/shlwapi.rc | 50 + dlls/shlwapi/shlwapi.spec | 4 +- dlls/shlwapi/shlwapi_Da.rc | 2 - dlls/shlwapi/shlwapi_De.rc | 4 - dlls/shlwapi/shlwapi_En.rc | 2 - dlls/shlwapi/shlwapi_Eo.rc | 2 - dlls/shlwapi/shlwapi_Es.rc | 2 - dlls/shlwapi/shlwapi_Fi.rc | 2 - dlls/shlwapi/shlwapi_Fr.rc | 7 +- dlls/shlwapi/shlwapi_Hu.rc | 2 - dlls/shlwapi/shlwapi_It.rc | 2 - dlls/shlwapi/shlwapi_Ja.rc | 4 +- dlls/shlwapi/shlwapi_Ko.rc | 2 - dlls/shlwapi/shlwapi_Lt.rc | 48 - dlls/shlwapi/shlwapi_Nl.rc | 2 - dlls/shlwapi/shlwapi_No.rc | 2 - dlls/shlwapi/shlwapi_Pl.rc | 2 - dlls/shlwapi/shlwapi_Pt.rc | 2 - dlls/shlwapi/shlwapi_Ro.rc | 4 +- dlls/shlwapi/shlwapi_Ru.rc | 2 - dlls/shlwapi/shlwapi_Si.rc | 4 +- dlls/shlwapi/shlwapi_Sk.rc | 2 - dlls/shlwapi/shlwapi_Sv.rc | 2 - dlls/shlwapi/shlwapi_Tr.rc | 2 - dlls/shlwapi/shlwapi_Uk.rc | 2 - dlls/shlwapi/shlwapi_Zh.rc | 4 +- dlls/shlwapi/string.c | 76 +- dlls/sound.drv16/Makefile.in | 2 + dlls/spoolss/Makefile.in | 2 +- dlls/storage.dll16/Makefile.in | 2 + dlls/stress.dll16/Makefile.in | 2 + dlls/t2embed/main.c | 18 - dlls/t2embed/t2embed.spec | 2 +- dlls/twain.dll16/Makefile.in | 2 + dlls/typelib.dll16/Makefile.in | 2 + dlls/urlmon/bindctx.c | 170 +- dlls/urlmon/rsrc.rc | 8 +- dlls/urlmon/sec_mgr.c | 412 +-- dlls/urlmon/session.c | 154 +- dlls/urlmon/tests/misc.c | 117 +- dlls/urlmon/tests/protocol.c | 84 +- dlls/urlmon/tests/sec_mgr.c | 223 +- dlls/urlmon/tests/url.c | 213 +- dlls/urlmon/urlmon.inf | 11 +- dlls/urlmon/urlmon_main.c | 37 +- dlls/urlmon/urlmon_main.h | 6 - dlls/urlmon/version.rc | 27 + dlls/user32/Makefile.in | 32 +- dlls/user32/button.c | 21 +- dlls/user32/cursoricon.c | 232 +- dlls/user32/defwnd.c | 2 +- dlls/user32/menu.c | 305 +-- dlls/user32/resources.h | 28 - dlls/user32/resources/user32.rc | 76 + dlls/user32/resources/user32_Bg.rc | 2 - dlls/user32/resources/user32_Ca.rc | 2 - dlls/user32/resources/user32_Cs.rc | 2 - dlls/user32/resources/user32_Da.rc | 2 - dlls/user32/resources/user32_De.rc | 38 +- dlls/user32/resources/user32_En.rc | 2 - dlls/user32/resources/user32_Eo.rc | 2 - dlls/user32/resources/user32_Es.rc | 2 - dlls/user32/resources/user32_Fi.rc | 2 - dlls/user32/resources/user32_Fr.rc | 33 +- dlls/user32/resources/user32_Hu.rc | 2 - dlls/user32/resources/user32_It.rc | 2 - dlls/user32/resources/user32_Ja.rc | 8 +- dlls/user32/resources/user32_Ko.rc | 2 - dlls/user32/resources/user32_Lt.rc | 4 +- dlls/user32/resources/user32_Nl.rc | 2 - dlls/user32/resources/user32_No.rc | 2 - dlls/user32/resources/user32_Pl.rc | 2 - dlls/user32/resources/user32_Pt.rc | 21 +- dlls/user32/resources/user32_Ro.rc | 4 +- dlls/user32/resources/user32_Ru.rc | 2 - dlls/user32/resources/user32_Si.rc | 4 +- dlls/user32/resources/user32_Sk.rc | 2 - dlls/user32/resources/user32_Sv.rc | 2 - dlls/user32/resources/user32_Tr.rc | 2 - dlls/user32/resources/user32_Uk.rc | 2 - dlls/user32/resources/user32_Wa.rc | 2 - dlls/user32/resources/user32_Zh.rc | 4 +- dlls/user32/resources/user32_bin.rc | 1 - dlls/user32/resources/version.rc | 2 - dlls/user32/spy.c | 48 +- dlls/user32/tests/cursoricon.c | 258 -- dlls/user32/tests/input.c | 3 +- dlls/user32/tests/menu.c | 151 +- dlls/user32/tests/msg.c | 86 +- dlls/user32/winproc.c | 11 - dlls/uuid/uuid.c | 6 - dlls/w32sys.dll16/Makefile.in | 2 + dlls/wbemprox/Makefile.in | 6 +- dlls/wbemprox/main.c | 192 +- dlls/wbemprox/regsvr.c | 424 ---- dlls/wbemprox/wbemlocator.c | 130 - dlls/wbemprox/wbemprox.spec | 8 +- dlls/wbemprox/wbemprox_private.h | 19 - dlls/win32s16.dll16/Makefile.in | 2 + dlls/win87em.dll16/Makefile.in | 2 + dlls/winaspi.dll16/Makefile.in | 2 + dlls/windebug.dll16/Makefile.in | 2 + dlls/windowscodecs/Makefile.in | 10 +- dlls/windowscodecs/bmpdecode.c | 983 -------- dlls/windowscodecs/clsfactory.c | 171 -- dlls/windowscodecs/imgfactory.c | 339 --- dlls/windowscodecs/main.c | 53 - dlls/windowscodecs/palette.c | 279 --- dlls/windowscodecs/regsvr.c | 628 ----- dlls/windowscodecs/tests/Makefile.in | 14 - dlls/windowscodecs/tests/bmpformat.c | 901 ------- dlls/windowscodecs/tests/palette.c | 158 -- dlls/windowscodecs/wincodecs_private.h | 31 - dlls/windowscodecs/windowscodecs.spec | 4 +- dlls/winealsa.drv/Makefile.in | 2 +- dlls/winealsa.drv/dsoutput.c | 152 +- dlls/wined3d/Makefile.in | 4 +- dlls/wined3d/arb_program_shader.c | 1282 ++++------ dlls/wined3d/ati_fragment_shader.c | 36 +- dlls/wined3d/baseshader.c | 223 +- dlls/wined3d/basetexture.c | 7 +- dlls/wined3d/buffer.c | 47 +- dlls/wined3d/context.c | 902 +++---- dlls/wined3d/cubetexture.c | 15 +- dlls/wined3d/device.c | 292 ++- dlls/wined3d/directx.c | 2574 +++++++++---------- dlls/wined3d/drawprim.c | 113 +- dlls/wined3d/gl_compat.c | 75 +- dlls/wined3d/glsl_shader.c | 480 ++-- dlls/wined3d/nvidia_texture_shader.c | 9 +- dlls/wined3d/palette.c | 5 +- dlls/wined3d/query.c | 228 +- dlls/wined3d/shader_sm1.c | 2 - dlls/wined3d/shader_sm4.c | 59 +- dlls/wined3d/state.c | 115 +- dlls/wined3d/surface.c | 399 ++- dlls/wined3d/surface_base.c | 37 +- dlls/wined3d/surface_gdi.c | 21 +- dlls/wined3d/swapchain.c | 22 +- dlls/wined3d/texture.c | 25 +- dlls/wined3d/utils.c | 196 +- dlls/wined3d/vertexshader.c | 8 +- dlls/wined3d/volume.c | 2 - dlls/wined3d/volumetexture.c | 15 +- dlls/wined3d/wined3d_gl.h | 133 +- dlls/wined3d/wined3d_main.c | 32 - dlls/wined3d/wined3d_private.h | 222 +- dlls/winedos/int21.c | 4 +- dlls/winedos/int31.c | 9 - dlls/wineesd.drv/Makefile.in | 4 +- dlls/wineps.drv/Makefile.in | 25 +- dlls/wineps.drv/driver.c | 2 +- dlls/wineps.drv/psdlg.h | 3 - dlls/wineps.drv/rsrc.rc | 57 + dlls/wineps.drv/truetype.c | 4 + dlls/wineps.drv/wps_Bg.rc | 2 - dlls/wineps.drv/wps_Cs.rc | 2 - dlls/wineps.drv/wps_Da.rc | 2 - dlls/wineps.drv/wps_De.rc | 6 +- dlls/wineps.drv/wps_En.rc | 2 - dlls/wineps.drv/wps_Es.rc | 2 - dlls/wineps.drv/wps_Fr.rc | 11 +- dlls/wineps.drv/wps_Hu.rc | 2 - dlls/wineps.drv/wps_It.rc | 2 - dlls/wineps.drv/wps_Ja.rc | 4 +- dlls/wineps.drv/wps_Ko.rc | 2 - dlls/wineps.drv/wps_Lt.rc | 3 +- dlls/wineps.drv/wps_Nl.rc | 2 - dlls/wineps.drv/wps_No.rc | 2 - dlls/wineps.drv/wps_Pl.rc | 2 - dlls/wineps.drv/wps_Pt.rc | 2 - dlls/wineps.drv/wps_Ro.rc | 4 +- dlls/wineps.drv/wps_Ru.rc | 2 - dlls/wineps.drv/wps_Si.rc | 2 - dlls/wineps.drv/wps_Sk.rc | 2 - dlls/wineps.drv/wps_Sv.rc | 2 - dlls/wineps.drv/wps_Tr.rc | 2 - dlls/wineps.drv/wps_Zh.rc | 4 +- dlls/winex11.drv/bitblt.c | 22 +- dlls/winex11.drv/bitmap.c | 51 +- dlls/winex11.drv/brush.c | 15 +- dlls/winex11.drv/clipboard.c | 91 +- dlls/winex11.drv/dib.c | 6 +- dlls/winex11.drv/graphics.c | 4 +- dlls/winex11.drv/keyboard.c | 6 +- dlls/winex11.drv/opengl.c | 3 + dlls/winex11.drv/window.c | 18 +- dlls/winex11.drv/x11drv.h | 12 +- dlls/winex11.drv/x11drv_main.c | 2 - dlls/winex11.drv/xrandr.c | 5 + dlls/winex11.drv/xrender.c | 566 ++--- dlls/winhttp/Makefile.in | 2 +- dlls/winhttp/net.c | 120 +- dlls/winhttp/request.c | 239 +- dlls/winhttp/session.c | 490 +--- dlls/winhttp/tests/Makefile.in | 2 +- dlls/winhttp/tests/winhttp.c | 142 +- dlls/winhttp/winhttp_private.h | 11 +- dlls/wininet/Makefile.in | 28 +- dlls/wininet/cookie.c | 110 +- dlls/wininet/dialogs.c | 248 +- dlls/wininet/ftp.c | 388 ++- dlls/wininet/http.c | 464 ++-- dlls/wininet/internet.c | 223 +- dlls/wininet/internet.h | 120 +- dlls/wininet/resource.h | 5 - dlls/wininet/rsrc.rc | 67 + dlls/wininet/tests/http.c | 29 +- dlls/wininet/tests/internet.c | 29 - dlls/wininet/urlcache.c | 93 +- dlls/wininet/utility.c | 61 +- dlls/wininet/wininet_Bg.rc | 2 - dlls/wininet/wininet_Cs.rc | 2 - dlls/wininet/wininet_Da.rc | 2 - dlls/wininet/wininet_De.rc | 29 +- dlls/wininet/wininet_En.rc | 22 - dlls/wininet/wininet_Eo.rc | 2 - dlls/wininet/wininet_Es.rc | 2 - dlls/wininet/wininet_Fi.rc | 2 - dlls/wininet/wininet_Fr.rc | 124 +- dlls/wininet/wininet_Hu.rc | 2 - dlls/wininet/wininet_It.rc | 2 - dlls/wininet/wininet_Ja.rc | 4 +- dlls/wininet/wininet_Ko.rc | 2 - dlls/wininet/wininet_Lt.rc | 24 +- dlls/wininet/wininet_Nl.rc | 22 - dlls/wininet/wininet_No.rc | 2 - dlls/wininet/wininet_Pl.rc | 2 - dlls/wininet/wininet_Pt.rc | 2 - dlls/wininet/wininet_Ro.rc | 4 +- dlls/wininet/wininet_Ru.rc | 2 - dlls/wininet/wininet_Si.rc | 4 +- dlls/wininet/wininet_Sv.rc | 2 - dlls/wininet/wininet_Tr.rc | 2 - dlls/wininet/wininet_Uk.rc | 2 - dlls/wininet/wininet_Zh.rc | 4 +- dlls/winmm/Makefile.in | 21 +- dlls/winmm/mci.c | 2 +- dlls/winmm/tests/mci.c | 2 +- dlls/winmm/winmm_Cs.rc | 3 - dlls/winmm/winmm_Da.rc | 3 - dlls/winmm/winmm_De.rc | 257 +- dlls/winmm/winmm_En.rc | 3 - dlls/winmm/winmm_Es.rc | 3 - dlls/winmm/winmm_Fr.rc | 268 +- dlls/winmm/winmm_It.rc | 3 - dlls/winmm/winmm_Ja.rc | 5 +- dlls/winmm/winmm_Ko.rc | 3 - dlls/winmm/winmm_Lt.rc | 134 - dlls/winmm/winmm_Nl.rc | 3 - dlls/winmm/winmm_No.rc | 3 - dlls/winmm/winmm_Pl.rc | 3 - dlls/winmm/winmm_Pt.rc | 3 - dlls/winmm/winmm_Ru.rc | 3 - dlls/winmm/winmm_Si.rc | 5 +- dlls/winmm/winmm_Sk.rc | 3 - dlls/winmm/winmm_Tr.rc | 3 - dlls/winmm/winmm_res.rc | 23 + dlls/winnls.dll16/Makefile.in | 2 + dlls/winspool.drv/Bg.rc | 2 - dlls/winspool.drv/Da.rc | 2 - dlls/winspool.drv/De.rc | 8 +- dlls/winspool.drv/En.rc | 2 - dlls/winspool.drv/Eo.rc | 2 - dlls/winspool.drv/Es.rc | 2 - dlls/winspool.drv/Fi.rc | 2 - dlls/winspool.drv/Fr.rc | 11 +- dlls/winspool.drv/It.rc | 2 - dlls/winspool.drv/Ko.rc | 2 - dlls/winspool.drv/Lt.rc | 6 +- dlls/winspool.drv/Makefile.in | 23 +- dlls/winspool.drv/Nl.rc | 2 - dlls/winspool.drv/No.rc | 2 - dlls/winspool.drv/Pl.rc | 2 - dlls/winspool.drv/Pt.rc | 2 - dlls/winspool.drv/Ru.rc | 2 - dlls/winspool.drv/Si.rc | 4 +- dlls/winspool.drv/Sv.rc | 2 - dlls/winspool.drv/Tr.rc | 2 - dlls/winspool.drv/Zh.rc | 4 +- dlls/winspool.drv/winspool.rc | 25 + dlls/winspool.drv/wspool.h | 3 - dlls/wintab.dll16/Makefile.in | 2 + dlls/wintrust/Makefile.in | 2 +- dlls/wintrust/crypt.c | 35 +- dlls/wintrust/tests/asn.c | 4 - dlls/wintrust/wintrust.spec | 1 - dlls/wintrust/wintrust_main.c | 9 - dlls/wldap32/Makefile.in | 16 +- dlls/wldap32/wldap32.rc | 37 + dlls/wldap32/wldap32_Da.rc | 2 - dlls/wldap32/wldap32_De.rc | 42 +- dlls/wldap32/wldap32_En.rc | 2 - dlls/wldap32/wldap32_Es.rc | 2 - dlls/wldap32/wldap32_Fr.rc | 86 +- dlls/wldap32/wldap32_Ko.rc | 2 - dlls/wldap32/wldap32_Lt.rc | 128 - dlls/wldap32/wldap32_Nl.rc | 2 - dlls/wldap32/wldap32_No.rc | 2 - dlls/wldap32/wldap32_Pl.rc | 2 - dlls/wldap32/wldap32_Pt.rc | 2 - dlls/wldap32/wldap32_Ru.rc | 2 - dlls/wldap32/wldap32_Sv.rc | 2 - dlls/wldap32/wldap32_Tr.rc | 2 - dlls/wmiutils/Makefile.in | 15 - dlls/wmiutils/main.c | 147 -- dlls/wmiutils/regsvr.c | 424 ---- dlls/wmiutils/statuscode.c | 153 -- dlls/wmiutils/wmiutils.spec | 4 - dlls/wmiutils/wmiutils_private.h | 19 - dlls/ws2_32/socket.c | 68 +- dlls/ws2_32/tests/sock.c | 486 +--- documentation/README.de | 8 +- include/Makefile.in | 17 +- include/activscp.idl | 7 +- include/binres.idl | 49 - include/commctrl.h | 12 - include/config.h.in | 15 +- include/crtrow.idl | 51 - include/d3d10effect.h | 43 - include/d3dx8.h | 32 + include/d3dx8core.h | 130 + include/d3dx8math.h | 415 +++ include/d3dx8math.inl | 1268 ++++++++++ include/d3dx8mesh.h | 41 + include/d3dx9math.h | 73 +- include/dbccmd.idl | 36 - include/dbcses.idl | 36 - include/dbdsad.idl | 75 - include/dbprop.idl | 11 +- include/dbs.idl | 10 - include/gdiplusflat.h | 4 - include/msctf.idl | 389 --- include/mshtmdid.h | 7 - include/mshtml.idl | 156 +- include/netcon.idl | 412 --- include/ntddndis.h | 168 -- include/objidl.idl | 17 - include/oledb.idl | 12 +- include/opnrst.idl | 47 - include/rtutils.h | 49 - include/sesprp.idl | 51 - include/shlobj.h | 35 - include/t2embapi.h | 46 - include/textstor.idl | 16 +- include/urlmon.idl | 127 +- include/wbemcli.idl | 211 -- include/winbase.h | 7 - include/wincodec.idl | 92 - include/wine/pthread.h | 67 + include/wine/server_protocol.h | 4 +- include/wine/wined3d.idl | 33 +- include/wingdi.h | 4 +- include/winternl.h | 2 - libs/port/interlocked.c | 8 - libs/wine/Makefile.in | 98 +- libs/wine/port.c | 23 +- libs/wine/wctomb.c | 9 +- loader/Makefile.in | 13 +- loader/main.c | 7 +- loader/main.h | 6 + loader/preloader.c | 2 +- loader/pthread.c | 241 ++ programs/clock/De.rc | 22 +- programs/clock/Fr.rc | 37 +- programs/clock/It.rc | 2 +- programs/clock/Lt.rc | 79 - programs/clock/Makefile.in | 2 - programs/clock/Pt.rc | 50 +- programs/clock/README | 5 + programs/clock/Ro.rc | 76 - programs/clock/Ru.rc | 35 +- programs/clock/TODO | 4 + programs/cmd/Cs.rc | 2 - programs/cmd/Da.rc | 2 - programs/cmd/De.rc | 180 +- programs/cmd/En.rc | 2 - programs/cmd/Es.rc | 2 - programs/cmd/Fr.rc | 556 ++-- programs/cmd/Ja.rc | 4 +- programs/cmd/Ko.rc | 2 - programs/cmd/Lt.rc | 279 --- programs/cmd/Makefile.in | 19 +- programs/cmd/Nl.rc | 2 - programs/cmd/No.rc | 2 - programs/cmd/Pl.rc | 2 - programs/cmd/Pt.rc | 2 - programs/cmd/README | 39 + programs/cmd/Ru.rc | 569 +++-- programs/cmd/Si.rc | 4 +- programs/cmd/Tr.rc | 2 - programs/cmd/wcmd.h | 1 - programs/cmd/wcmdrc.rc | 21 + programs/cmdlgtst/Cs.rc | 2 - programs/cmdlgtst/Da.rc | 2 - programs/cmdlgtst/De.rc | 28 +- programs/cmdlgtst/En.rc | 2 - programs/cmdlgtst/Es.rc | 2 - programs/cmdlgtst/Fr.rc | 69 +- programs/cmdlgtst/It.rc | 26 +- programs/cmdlgtst/Ja.rc | 4 +- programs/cmdlgtst/Ko.rc | 2 - programs/cmdlgtst/Lt.rc | 300 --- programs/cmdlgtst/Makefile.in | 21 +- programs/cmdlgtst/Nl.rc | 2 - programs/cmdlgtst/No.rc | 2 - programs/cmdlgtst/Pl.rc | 2 - programs/cmdlgtst/Pt.rc | 123 +- programs/cmdlgtst/Ru.rc | 127 +- programs/cmdlgtst/Si.rc | 4 +- programs/cmdlgtst/Sv.rc | 2 - programs/cmdlgtst/Tr.rc | 2 - programs/cmdlgtst/cmdlgr.rc | 24 + programs/cmdlgtst/cmdlgtst.h | 4 - programs/control/cpl_list | 95 + programs/msiexec/rsrc.rc | 11 +- programs/msiexec/version.rc | 28 + programs/net/Da.rc | 2 - programs/net/De.rc | 4 +- programs/net/En.rc | 2 - programs/net/Fr.rc | 5 +- programs/net/Ko.rc | 2 - programs/net/Lt.rc | 49 - programs/net/Makefile.in | 14 +- programs/net/Nl.rc | 2 - programs/net/No.rc | 2 - programs/net/Pl.rc | 2 - programs/net/Pt.rc | 2 - programs/net/Ru.rc | 93 +- programs/net/Si.rc | 4 +- programs/net/resources.h | 2 - programs/net/rsrc.rc | 35 + programs/notepad/Bg.rc | 2 - programs/notepad/Cs.rc | 2 - programs/notepad/Da.rc | 2 - programs/notepad/De.rc | 50 +- programs/notepad/En.rc | 34 +- programs/notepad/Eo.rc | 2 - programs/notepad/Es.rc | 3 - programs/notepad/Fi.rc | 3 - programs/notepad/Fr.rc | 72 +- programs/notepad/Hu.rc | 2 - programs/notepad/It.rc | 2 - programs/notepad/Ja.rc | 5 +- programs/notepad/Ko.rc | 18 +- programs/notepad/Lt.rc | 49 +- programs/notepad/Makefile.in | 29 +- programs/notepad/Nl.rc | 20 - programs/notepad/No.rc | 52 +- programs/notepad/Pl.rc | 2 - programs/notepad/Pt.rc | 86 +- programs/notepad/Ro.rc | 4 +- programs/notepad/Ru.rc | 257 +- programs/notepad/Si.rc | 5 +- programs/notepad/Sv.rc | 19 - programs/notepad/Th.rc | 2 - programs/notepad/Tr.rc | 2 - programs/notepad/Wa.rc | 2 - programs/notepad/Zh.rc | 4 +- programs/notepad/dialog.c | 402 +-- programs/notepad/dialog.h | 3 +- programs/notepad/main.c | 22 +- programs/notepad/main.h | 18 +- programs/notepad/notepad_res.h | 12 - programs/notepad/rsrc.rc | 33 + programs/oleview/Da.rc | 2 - programs/oleview/De.rc | 38 +- programs/oleview/En.rc | 2 - programs/oleview/Fr.rc | 131 +- programs/oleview/Ja.rc | 4 +- programs/oleview/Ko.rc | 2 - programs/oleview/Lt.rc | 218 -- programs/oleview/Makefile.in | 17 +- programs/oleview/Nl.rc | 2 - programs/oleview/No.rc | 2 - programs/oleview/Pl.rc | 2 - programs/oleview/Pt.rc | 2 - programs/oleview/Ru.rc | 137 +- programs/oleview/Sv.rc | 2 - programs/oleview/Zh.rc | 4 +- programs/oleview/resource.h | 3 - programs/oleview/rsrc.rc | 17 + programs/progman/Cs.rc | 2 - programs/progman/Da.rc | 2 - programs/progman/De.rc | 54 +- programs/progman/En.rc | 2 - programs/progman/Es.rc | 2 - programs/progman/Fr.rc | 147 +- programs/progman/Hu.rc | 2 - programs/progman/It.rc | 12 +- programs/progman/Ko.rc | 2 - programs/progman/Lt.rc | 244 -- programs/progman/Makefile.in | 22 +- programs/progman/Nl.rc | 2 - programs/progman/No.rc | 2 - programs/progman/Pl.rc | 2 - programs/progman/Pt.rc | 108 +- programs/progman/README | 14 + programs/progman/Ru.rc | 204 +- programs/progman/Si.rc | 4 +- programs/progman/Sv.rc | 2 - programs/progman/TODO | 6 + programs/progman/Tr.rc | 2 - programs/progman/Zh.rc | 4 +- programs/progman/accel.rc | 3 - programs/progman/progman.h | 3 +- programs/progman/rsrc.rc | 42 + programs/reg/Da.rc | 2 - programs/reg/De.rc | 4 +- programs/reg/En.rc | 2 - programs/reg/Fr.rc | 21 +- programs/reg/Ja.rc | 4 +- programs/reg/Ko.rc | 2 - programs/reg/Lt.rc | 4 +- programs/reg/Makefile.in | 15 +- programs/reg/Nl.rc | 2 - programs/reg/No.rc | 21 +- programs/reg/Pl.rc | 2 - programs/reg/Pt.rc | 11 +- programs/reg/Ru.rc | 13 +- programs/reg/Si.rc | 9 +- programs/reg/reg.c | 74 +- programs/reg/reg.h | 2 - programs/reg/rsrc.rc | 37 + programs/regedit/Bg.rc | 1 - programs/regedit/Cs.rc | 2 - programs/regedit/Da.rc | 4 +- programs/regedit/De.rc | 4 +- programs/regedit/En.rc | 25 - programs/regedit/Es.rc | 4 - programs/regedit/Fr.rc | 209 +- programs/regedit/Hu.rc | 2 - programs/regedit/It.rc | 14 +- programs/regedit/Ja.rc | 4 +- programs/regedit/Ko.rc | 2 - programs/regedit/Lt.rc | 18 +- programs/regedit/Makefile.in | 24 +- programs/regedit/Nl.rc | 2 - programs/regedit/No.rc | 69 +- programs/regedit/Pl.rc | 2 - programs/regedit/Pt.rc | 198 +- programs/regedit/Ru.rc | 661 +++-- programs/regedit/Si.rc | 5 +- programs/regedit/Sv.rc | 2 - programs/regedit/Tr.rc | 2 - programs/regedit/Zh.rc | 4 +- programs/regedit/childwnd.c | 51 - programs/regedit/resource.h | 3 - programs/regedit/rsrc.rc | 27 + programs/secedit/Makefile.in | 2 +- programs/services/services.c | 2 +- programs/start/Cs.rc | 2 - programs/start/De.rc | 14 +- programs/start/En.rc | 2 - programs/start/Es.rc | 2 - programs/start/Fr.rc | 4 +- programs/start/It.rc | 2 - programs/start/Ko.rc | 4 +- programs/start/Lt.rc | 6 +- programs/start/Makefile.in | 17 +- programs/start/Nl.rc | 2 - programs/start/No.rc | 2 - programs/start/Pl.rc | 2 - programs/start/Pt.rc | 2 - programs/start/Ru.rc | 49 +- programs/start/Si.rc | 4 +- programs/start/Tr.rc | 2 - programs/start/resources.h | 2 - programs/start/rsrc.rc | 39 + programs/taskmgr/Da.rc | 2 - programs/taskmgr/De.rc | 166 +- programs/taskmgr/En.rc | 88 - programs/taskmgr/Fr.rc | 370 +-- programs/taskmgr/Ja.rc | 5 +- programs/taskmgr/Ko.rc | 87 - programs/taskmgr/Lt.rc | 564 ----- programs/taskmgr/Makefile.in | 19 +- programs/taskmgr/Nl.rc | 101 +- programs/taskmgr/No.rc | 174 +- programs/taskmgr/Pl.rc | 2 - programs/taskmgr/Pt.rc | 186 +- programs/taskmgr/Ru.rc | 1053 ++++---- programs/taskmgr/Si.rc | 4 +- programs/taskmgr/Sv.rc | 2 - programs/taskmgr/Tr.rc | 2 - programs/taskmgr/Zh.rc | 4 +- programs/taskmgr/affinity.c | 18 +- programs/taskmgr/applpage.c | 16 +- programs/taskmgr/column.c | 81 +- programs/taskmgr/dbgchnl.c | 16 +- programs/taskmgr/debug.c | 18 +- programs/taskmgr/endproc.c | 17 +- programs/taskmgr/perfdata.c | 3 +- programs/taskmgr/perfpage.c | 5 +- programs/taskmgr/priority.c | 11 +- programs/taskmgr/procpage.c | 19 +- programs/taskmgr/resource.h | 66 - programs/taskmgr/taskmgr.c | 53 +- programs/taskmgr/taskmgr.rc | 24 +- programs/taskmgr/trayicon.c | 8 +- programs/uninstaller/Bg.rc | 2 - programs/uninstaller/Cs.rc | 2 - programs/uninstaller/Da.rc | 2 - programs/uninstaller/De.rc | 6 +- programs/uninstaller/En.rc | 2 - programs/uninstaller/Eo.rc | 2 - programs/uninstaller/Es.rc | 2 - programs/uninstaller/Fi.rc | 2 - programs/uninstaller/Fr.rc | 12 +- programs/uninstaller/Hu.rc | 2 - programs/uninstaller/It.rc | 2 - programs/uninstaller/Ko.rc | 2 - programs/uninstaller/Lt.rc | 6 +- programs/uninstaller/Makefile.in | 25 +- programs/uninstaller/Nl.rc | 2 - programs/uninstaller/No.rc | 2 - programs/uninstaller/Pl.rc | 2 - programs/uninstaller/Pt.rc | 2 - programs/uninstaller/README | 21 + programs/uninstaller/Ro.rc | 4 +- programs/uninstaller/Ru.rc | 9 +- programs/uninstaller/Si.rc | 4 +- programs/uninstaller/Sv.rc | 2 - programs/uninstaller/Tr.rc | 2 - programs/uninstaller/Zh.rc | 4 +- programs/uninstaller/resource.h | 2 - programs/uninstaller/rsrc.rc | 51 + programs/view/Cs.rc | 2 - programs/view/Da.rc | 2 - programs/view/De.rc | 8 +- programs/view/En.rc | 2 - programs/view/Eo.rc | 2 - programs/view/Es.rc | 2 - programs/view/Fr.rc | 13 +- programs/view/It.rc | 2 - programs/view/Ja.rc | 4 +- programs/view/Ko.rc | 2 - programs/view/Lt.rc | 75 - programs/view/Makefile.in | 23 +- programs/view/Nl.rc | 2 - programs/view/No.rc | 2 - programs/view/Pl.rc | 2 - programs/view/Pt.rc | 2 - programs/view/Ro.rc | 4 +- programs/view/Ru.rc | 25 +- programs/view/Si.rc | 4 +- programs/view/Sv.rc | 2 - programs/view/Tr.rc | 2 - programs/view/Zh.rc | 4 +- programs/view/resource.h | 2 - programs/view/viewrc.rc | 48 + programs/wineboot/Makefile.in | 19 +- programs/wineboot/resource.h | 3 - programs/wineboot/wineboot.rc | 46 + programs/wineboot/wineboot_Da.rc | 2 - programs/wineboot/wineboot_De.rc | 6 +- programs/wineboot/wineboot_En.rc | 2 - programs/wineboot/wineboot_Es.rc | 5 +- programs/wineboot/wineboot_Fr.rc | 5 +- programs/wineboot/wineboot_Ja.rc | 4 +- programs/wineboot/wineboot_Ko.rc | 2 - programs/wineboot/wineboot_Lt.rc | 4 +- programs/wineboot/wineboot_Nl.rc | 2 - programs/wineboot/wineboot_No.rc | 2 - programs/wineboot/wineboot_Pl.rc | 2 - programs/wineboot/wineboot_Pt.rc | 2 - programs/wineboot/wineboot_Ro.rc | 4 +- programs/wineboot/wineboot_Ru.rc | 15 +- programs/wineboot/wineboot_Si.rc | 4 +- programs/wineboot/wineboot_Sv.rc | 2 - programs/wineboot/wineboot_Zh.rc | 4 +- programs/winebrowser/main.c | 48 +- programs/winecfg/Bg.rc | 5 +- programs/winecfg/Cs.rc | 6 +- programs/winecfg/Da.rc | 5 +- programs/winecfg/De.rc | 107 +- programs/winecfg/En.rc | 78 +- programs/winecfg/Es.rc | 5 +- programs/winecfg/Fi.rc | 5 +- programs/winecfg/Fr.rc | 657 +++-- programs/winecfg/Hu.rc | 5 +- programs/winecfg/It.rc | 7 +- programs/winecfg/Ja.rc | 7 +- programs/winecfg/Ko.rc | 15 +- programs/winecfg/Lt.rc | 25 +- programs/winecfg/Makefile.in | 26 +- programs/winecfg/Nl.rc | 86 +- programs/winecfg/No.rc | 5 +- programs/winecfg/Pl.rc | 5 +- programs/winecfg/Pt.rc | 166 +- programs/winecfg/Ro.rc | 79 +- programs/winecfg/Ru.rc | 664 +++-- programs/winecfg/Si.rc | 7 +- programs/winecfg/Sv.rc | 5 +- programs/winecfg/Tr.rc | 5 +- programs/winecfg/Zh.rc | 7 +- programs/winecfg/drive.c | 2 +- programs/winecfg/drivedetect.c | 2 - programs/winecfg/resource.h | 4 - programs/winecfg/winecfg.rc | 32 + programs/wineconsole/Makefile.in | 21 +- programs/wineconsole/wineconsole_Cs.rc | 2 - programs/wineconsole/wineconsole_De.rc | 46 +- programs/wineconsole/wineconsole_En.rc | 20 - programs/wineconsole/wineconsole_Eo.rc | 2 - programs/wineconsole/wineconsole_Es.rc | 2 - programs/wineconsole/wineconsole_Fr.rc | 108 +- programs/wineconsole/wineconsole_Hu.rc | 2 - programs/wineconsole/wineconsole_It.rc | 2 - programs/wineconsole/wineconsole_Ko.rc | 2 - programs/wineconsole/wineconsole_Lt.rc | 139 - programs/wineconsole/wineconsole_Nl.rc | 2 - programs/wineconsole/wineconsole_No.rc | 2 - programs/wineconsole/wineconsole_Pl.rc | 2 - programs/wineconsole/wineconsole_Pt.rc | 88 +- programs/wineconsole/wineconsole_Ru.rc | 127 +- programs/wineconsole/wineconsole_Si.rc | 4 +- programs/wineconsole/wineconsole_Sv.rc | 2 - programs/wineconsole/wineconsole_Tr.rc | 2 - programs/wineconsole/wineconsole_Zh.rc | 4 +- programs/wineconsole/wineconsole_res.h | 4 - programs/wineconsole/wineconsole_res.rc | 44 + programs/winedbg/Makefile.in | 13 +- programs/winedbg/be_i386.c | 3 + programs/winedbg/crashdlg.c | 5 +- programs/winedbg/resource.h | 2 - programs/winedbg/rsrc.rc | 31 + programs/winedbg/rsrc_De.rc | 4 +- programs/winedbg/rsrc_En.rc | 2 - programs/winedbg/rsrc_Fr.rc | 58 - programs/winedbg/rsrc_Ko.rc | 2 - programs/winedbg/rsrc_Lt.rc | 4 +- programs/winedbg/rsrc_Nl.rc | 2 - programs/winedbg/rsrc_Pt.rc | 57 - programs/winedbg/rsrc_Ru.rc | 31 +- programs/winedbg/rsrc_Sv.rc | 58 - programs/winedbg/types.c | 8 +- programs/winedbg/winedbg.c | 2 +- programs/winefile/Cs.rc | 2 - programs/winefile/Da.rc | 2 - programs/winefile/De.rc | 56 +- programs/winefile/En.rc | 2 - programs/winefile/Es.rc | 2 - programs/winefile/Fr.rc | 167 +- programs/winefile/Hu.rc | 2 - programs/winefile/It.rc | 2 - programs/winefile/Ja.rc | 4 +- programs/winefile/Ko.rc | 2 - programs/winefile/Lt.rc | 263 -- programs/winefile/Makefile.in | 23 +- programs/winefile/Nl.rc | 2 - programs/winefile/No.rc | 2 - programs/winefile/Pl.rc | 2 - programs/winefile/Pt.rc | 155 +- programs/winefile/Ru.rc | 519 ++-- programs/winefile/Si.rc | 4 +- programs/winefile/Sv.rc | 2 - programs/winefile/Tr.rc | 2 - programs/winefile/Zh.rc | 4 +- programs/winefile/resource.h | 2 - programs/winefile/rsrc.rc | 25 + programs/winemenubuilder/winemenubuilder.c | 128 +- programs/winemine/Cs.rc | 2 - programs/winemine/Da.rc | 2 - programs/winemine/De.rc | 14 +- programs/winemine/En.rc | 6 +- programs/winemine/Es.rc | 2 - programs/winemine/Fi.rc | 2 - programs/winemine/Fr.rc | 49 +- programs/winemine/It.rc | 6 +- programs/winemine/Ja.rc | 4 +- programs/winemine/Ko.rc | 2 - programs/winemine/Lt.rc | 6 +- programs/winemine/Makefile.in | 26 +- programs/winemine/Nl.rc | 2 - programs/winemine/No.rc | 2 - programs/winemine/Pl.rc | 2 - programs/winemine/Pt.rc | 2 - programs/winemine/README | 17 + programs/winemine/Ro.rc | 4 +- programs/winemine/Ru.rc | 51 +- programs/winemine/Si.rc | 4 +- programs/winemine/Sv.rc | 98 - programs/winemine/Tr.rc | 2 - programs/winemine/Zh.rc | 4 +- programs/winemine/resource.h | 2 - programs/winemine/rsrc.rc | 24 + programs/winetest/Makefile.in | 24 +- programs/winetest/README | 22 + programs/winetest/main.c | 18 +- programs/winetest/resource.h | 9 + programs/winetest/winetest.rc | 9 + programs/winhlp32/Bg.rc | 2 - programs/winhlp32/Cs.rc | 2 - programs/winhlp32/Da.rc | 2 - programs/winhlp32/De.rc | 14 +- programs/winhlp32/En.rc | 70 - programs/winhlp32/Eo.rc | 2 - programs/winhlp32/Es.rc | 2 - programs/winhlp32/Fi.rc | 2 - programs/winhlp32/Fr.rc | 37 +- programs/winhlp32/Hu.rc | 2 - programs/winhlp32/It.rc | 34 +- programs/winhlp32/Ja.rc | 4 +- programs/winhlp32/Ko.rc | 2 - programs/winhlp32/Lt.rc | 131 - programs/winhlp32/Makefile.in | 29 +- programs/winhlp32/Nl.rc | 48 +- programs/winhlp32/No.rc | 2 - programs/winhlp32/Pl.rc | 2 - programs/winhlp32/Pt.rc | 94 +- programs/winhlp32/Rm.rc | 2 - programs/winhlp32/Ru.rc | 239 +- programs/winhlp32/Si.rc | 4 +- programs/winhlp32/Sk.rc | 2 - programs/winhlp32/Sv.rc | 2 - programs/winhlp32/Tr.rc | 2 - programs/winhlp32/Wa.rc | 2 - programs/winhlp32/Zh.rc | 4 +- programs/winhlp32/macro.c | 7 +- programs/winhlp32/rsrc.rc | 30 + programs/winhlp32/winhelp.c | 4 +- programs/winhlp32/winhelp_res.h | 3 - programs/wordpad/Da.rc | 2 - programs/wordpad/De.rc | 4 +- programs/wordpad/En.rc | 37 +- programs/wordpad/Fr.rc | 103 +- programs/wordpad/Hu.rc | 2 - programs/wordpad/Ja.rc | 6 +- programs/wordpad/Ko.rc | 1 - programs/wordpad/Lt.rc | 249 -- programs/wordpad/Makefile.in | 20 +- programs/wordpad/Nl.rc | 22 +- programs/wordpad/No.rc | 48 +- programs/wordpad/Pl.rc | 2 - programs/wordpad/Pt.rc | 73 +- programs/wordpad/Ru.rc | 483 ++-- programs/wordpad/Si.rc | 7 +- programs/wordpad/Sv.rc | 4 +- programs/wordpad/Tr.rc | 2 - programs/wordpad/Zh.rc | 4 +- programs/wordpad/rsrc.rc | 20 + programs/wordpad/wordpad.h | 31 +- programs/write/De.rc | 4 - programs/write/En.rc | 2 - programs/write/Fr.rc | 5 +- programs/write/Ja.rc | 4 +- programs/write/Ko.rc | 2 - programs/write/Lt.rc | 31 - programs/write/Makefile.in | 16 +- programs/write/Nl.rc | 2 - programs/write/No.rc | 2 - programs/write/Pl.rc | 2 - programs/write/Pt.rc | 2 - programs/write/Ro.rc | 4 +- programs/write/Ru.rc | 7 +- programs/write/Si.rc | 4 +- programs/write/Sv.rc | 2 - programs/write/resources.h | 2 - programs/write/rsrc.rc | 37 + programs/xcopy/Da.rc | 1 - programs/xcopy/De.rc | 27 +- programs/xcopy/En.rc | 1 - programs/xcopy/Fr.rc | 31 +- programs/xcopy/Ko.rc | 1 - programs/xcopy/Lt.rc | 83 - programs/xcopy/Makefile.in | 14 +- programs/xcopy/Nl.rc | 1 - programs/xcopy/No.rc | 1 - programs/xcopy/Pl.rc | 1 - programs/xcopy/Pt.rc | 1 - programs/xcopy/Ru.rc | 168 +- programs/xcopy/Si.rc | 4 +- programs/xcopy/rsrc.rc | 35 + programs/xcopy/xcopy.h | 2 - server/change.c | 9 +- server/file.c | 2 +- server/process.c | 1 - server/protocol.def | 1 - server/request.h | 3 +- server/trace.c | 1 - tools/Makefile.in | 2 +- tools/make_makefiles | 129 +- tools/makedep.c | 32 +- tools/widl/typegen.c | 55 +- tools/winapi/c_function.pm | 158 +- tools/winapi/c_parser.pm | 855 ++++--- tools/winapi/c_type.pm | 408 +-- tools/wine.inf.in | 5 +- tools/winebuild/main.c | 2 +- tools/winebuild/res16.c | 2 +- tools/winebuild/res32.c | 63 +- tools/winebuild/spec16.c | 1 + tools/winedump/pdb.c | 1 - tools/winegcc/winegcc.c | 12 +- tools/wmc/mcl.c | 8 +- tools/wmc/mcy.y | 6 +- tools/wmc/write.c | 29 +- tools/wrc/parser.l | 9 +- tools/wrc/parser.y | 22 +- tools/wrc/wrc.c | 210 +- tools/wrc/wrc.man.in | 4 +- 1853 files changed, 31158 insertions(+), 65521 deletions(-) rewrite ANNOUNCE (97%) delete mode 100644 dlls/appwiz.cpl/Sv.rc rewrite dlls/appwiz.cpl/appwiz.ico (100%) delete mode 100644 dlls/avifil32/avifile_Lt.rc delete mode 100644 dlls/avifil32/avifile_Ro.rc create mode 100644 dlls/browseui/rsrc.rc delete mode 100644 dlls/browseui/rsrc_Ja.rc rewrite dlls/comdlg32/cdlg_Ru.rc (65%) create mode 100644 dlls/comdlg32/rsrc.rc create mode 100644 dlls/crypt32/crypt32.rc rewrite dlls/crypt32/crypt32_Fr.rc (79%) delete mode 100644 dlls/crypt32/crypt32_Lt.rc delete mode 100644 dlls/crypt32/crypt32_Ro.rc create mode 100644 dlls/cryptdlg/cryptdlg.rc delete mode 100644 dlls/cryptdlg/cryptdlg_Lt.rc delete mode 100644 dlls/cryptdlg/cryptdlg_Pt.rc delete mode 100644 dlls/cryptdlg/cryptdlg_Ro.rc delete mode 100644 dlls/cryptui/cryptui_Fr.rc delete mode 100644 dlls/cryptui/cryptui_Lt.rc delete mode 100644 dlls/cryptui/cryptui_Pt.rc create mode 100644 dlls/d3dx8/Makefile.in create mode 100644 dlls/d3dx8/core.c create mode 100644 dlls/d3dx8/d3dx8.spec create mode 100644 dlls/d3dx8/d3dx8_main.c create mode 100644 dlls/d3dx8/d3dx8_private.h create mode 100644 dlls/d3dx8/math.c create mode 100644 dlls/d3dx8/mesh.c create mode 100644 dlls/d3dx8/tests/Makefile.in create mode 100644 dlls/d3dx8/tests/math.c create mode 100644 dlls/d3dx8/tests/mesh.c delete mode 100644 dlls/d3dx9_36/core.c rewrite dlls/d3dx9_36/math.c (87%) rewrite dlls/d3dx9_36/surface.c (68%) rewrite dlls/d3dx9_36/tests/math.c (74%) rewrite dlls/d3dx9_36/tests/mesh.c (76%) delete mode 100644 dlls/drmclien/Makefile.in delete mode 100644 dlls/drmclien/drmclien.spec delete mode 100644 dlls/drmclien/main.c delete mode 100644 dlls/dxdiagn/fil_data.idl create mode 100644 dlls/gphoto2.ds/rsrc.rc create mode 100644 dlls/hhctrl.ocx/hhctrl.rc delete mode 100644 dlls/iccvid/iccvid_Ja.rc delete mode 100644 dlls/iccvid/iccvid_Lt.rc create mode 100644 dlls/iccvid/rsrc.rc rewrite dlls/jscript/date.c (65%) delete mode 100644 dlls/jscript/error.c delete mode 100644 dlls/jscript/jscript_De.rc delete mode 100644 dlls/jscript/jscript_En.rc delete mode 100644 dlls/jscript/jscript_Fr.rc delete mode 100644 dlls/jscript/jscript_Lt.rc delete mode 100644 dlls/jscript/jscript_Nl.rc delete mode 100644 dlls/jscript/resource.h create mode 100644 dlls/kernel32/kernel.rc delete mode 100644 dlls/kernel32/nls/winerr_lth.mc delete mode 100644 dlls/localspl/spl_Lt.rc delete mode 100644 dlls/localui/ui_Lt.rc create mode 100644 dlls/mpr/mpr.rc delete mode 100644 dlls/mpr/mpr_Lt.rc create mode 100644 dlls/msacm32/msacm.rc delete mode 100644 dlls/msi/msi_Lt.rc delete mode 100644 dlls/msrle32/msrle_Lt.rc create mode 100644 dlls/msrle32/rsrc.rc delete mode 100644 dlls/msvfw32/msvfw32_Lt.rc create mode 100644 dlls/msvfw32/rsrc.rc delete mode 100644 dlls/msvidc32/msvidc32_Ja.rc delete mode 100644 dlls/msvidc32/msvidc32_Lt.rc create mode 100644 dlls/msvidc32/rsrc.rc create mode 100644 dlls/ole32/version.rc create mode 100644 dlls/oleacc/oleacc.rc delete mode 100644 dlls/oleacc/oleacc_Pt.rc create mode 100644 dlls/oleaut32/oleaut32.rc delete mode 100644 dlls/oleaut32/oleaut32_Lt.rc delete mode 100644 dlls/oledlg/oledlg_Lt.rc create mode 100644 dlls/oledlg/rsrc.rc create mode 100644 dlls/olepro32/README delete mode 100644 dlls/rtutils/Makefile.in delete mode 100644 dlls/rtutils/main.c delete mode 100644 dlls/rtutils/rtutils.spec delete mode 100644 dlls/rtutils/tracing.c create mode 100644 dlls/sane.ds/rsrc.rc delete mode 100644 dlls/sane.ds/sane_Ja.rc delete mode 100644 dlls/sane.ds/sane_Lt.rc delete mode 100644 dlls/serialui/Lt.rc create mode 100644 dlls/serialui/serialui_rc.rc delete mode 100644 dlls/setupapi/Lt.rc create mode 100644 dlls/setupapi/setupapi.rc delete mode 100644 dlls/shdoclc/Lt.rc create mode 100644 dlls/shdoclc/rsrc.rc create mode 100644 dlls/shdocvw/version.rc create mode 100644 dlls/shlwapi/shlwapi.rc delete mode 100644 dlls/shlwapi/shlwapi_Lt.rc create mode 100644 dlls/urlmon/version.rc delete mode 100644 dlls/user32/resources.h create mode 100644 dlls/user32/resources/user32.rc rewrite dlls/wbemprox/main.c (67%) delete mode 100644 dlls/wbemprox/regsvr.c delete mode 100644 dlls/wbemprox/wbemlocator.c delete mode 100644 dlls/wbemprox/wbemprox_private.h delete mode 100644 dlls/windowscodecs/bmpdecode.c delete mode 100644 dlls/windowscodecs/clsfactory.c delete mode 100644 dlls/windowscodecs/imgfactory.c delete mode 100644 dlls/windowscodecs/palette.c delete mode 100644 dlls/windowscodecs/regsvr.c delete mode 100644 dlls/windowscodecs/tests/Makefile.in delete mode 100644 dlls/windowscodecs/tests/bmpformat.c delete mode 100644 dlls/windowscodecs/tests/palette.c delete mode 100644 dlls/windowscodecs/wincodecs_private.h create mode 100644 dlls/wineps.drv/rsrc.rc create mode 100644 dlls/wininet/rsrc.rc rewrite dlls/wininet/wininet_Fr.rc (62%) rewrite dlls/winmm/winmm_De.rc (68%) rewrite dlls/winmm/winmm_Fr.rc (84%) delete mode 100644 dlls/winmm/winmm_Lt.rc create mode 100644 dlls/wldap32/wldap32.rc delete mode 100644 dlls/wldap32/wldap32_Lt.rc delete mode 100644 dlls/wmiutils/Makefile.in delete mode 100644 dlls/wmiutils/main.c delete mode 100644 dlls/wmiutils/regsvr.c delete mode 100644 dlls/wmiutils/statuscode.c delete mode 100644 dlls/wmiutils/wmiutils.spec delete mode 100644 dlls/wmiutils/wmiutils_private.h delete mode 100644 include/binres.idl delete mode 100644 include/crtrow.idl create mode 100644 include/d3dx8.h create mode 100644 include/d3dx8core.h create mode 100644 include/d3dx8math.h create mode 100644 include/d3dx8math.inl create mode 100644 include/d3dx8mesh.h delete mode 100644 include/dbccmd.idl delete mode 100644 include/dbcses.idl delete mode 100644 include/dbdsad.idl delete mode 100644 include/netcon.idl delete mode 100644 include/ntddndis.h delete mode 100644 include/opnrst.idl delete mode 100644 include/rtutils.h delete mode 100644 include/sesprp.idl delete mode 100644 include/t2embapi.h delete mode 100644 include/wbemcli.idl create mode 100644 include/wine/pthread.h create mode 100644 loader/pthread.c delete mode 100644 programs/clock/Lt.rc create mode 100644 programs/clock/README delete mode 100644 programs/clock/Ro.rc create mode 100644 programs/clock/TODO rewrite programs/cmd/Fr.rc (68%) delete mode 100644 programs/cmd/Lt.rc create mode 100644 programs/cmd/README rewrite programs/cmd/Ru.rc (91%) delete mode 100644 programs/cmdlgtst/Lt.rc create mode 100644 programs/control/cpl_list create mode 100644 programs/msiexec/version.rc delete mode 100644 programs/net/Lt.rc rewrite programs/net/Ru.rc (64%) create mode 100644 programs/net/rsrc.rc rewrite programs/notepad/Ru.rc (71%) delete mode 100644 programs/oleview/Lt.rc delete mode 100644 programs/progman/Lt.rc create mode 100644 programs/progman/README create mode 100644 programs/progman/TODO create mode 100644 programs/progman/rsrc.rc create mode 100644 programs/reg/rsrc.rc rewrite programs/regedit/Ru.rc (69%) create mode 100644 programs/start/rsrc.rc delete mode 100644 programs/taskmgr/Lt.rc rewrite programs/taskmgr/Ru.rc (72%) create mode 100644 programs/uninstaller/README create mode 100644 programs/uninstaller/rsrc.rc delete mode 100644 programs/view/Lt.rc create mode 100644 programs/view/viewrc.rc create mode 100644 programs/wineboot/wineboot.rc rewrite programs/winecfg/Fr.rc (62%) rewrite programs/winecfg/Ru.rc (70%) delete mode 100644 programs/wineconsole/wineconsole_Lt.rc create mode 100644 programs/wineconsole/wineconsole_res.rc create mode 100644 programs/winedbg/rsrc.rc delete mode 100644 programs/winedbg/rsrc_Fr.rc delete mode 100644 programs/winedbg/rsrc_Pt.rc delete mode 100644 programs/winedbg/rsrc_Sv.rc delete mode 100644 programs/winefile/Lt.rc rewrite programs/winefile/Ru.rc (66%) create mode 100644 programs/winemine/README delete mode 100644 programs/winemine/Sv.rc create mode 100644 programs/winetest/README delete mode 100644 programs/winhlp32/Lt.rc rewrite programs/winhlp32/Ru.rc (70%) delete mode 100644 programs/wordpad/Lt.rc rewrite programs/wordpad/Ru.rc (71%) delete mode 100644 programs/write/Lt.rc create mode 100644 programs/write/rsrc.rc delete mode 100644 programs/xcopy/Lt.rc rewrite programs/xcopy/Ru.rc (73%) create mode 100644 programs/xcopy/rsrc.rc diff --git a/.gitignore b/.gitignore index 1f9c9088047..a47a09636fb 100644 --- a/.gitignore +++ b/.gitignore @@ -26,7 +26,6 @@ dlls/advapi32/svcctl.h dlls/advapi32/svcctl_c.c dlls/atl/atliface.h dlls/commdlg.dll16 -dlls/dxdiagn/fil_data.h dlls/gdi.exe16 dlls/jscript/jsglobal.tlb dlls/jscript/parser.tab.c @@ -35,7 +34,6 @@ dlls/kernel32/nls/winerr_deu.mc.rc dlls/kernel32/nls/winerr_enu.mc.rc dlls/kernel32/nls/winerr_fra.mc.rc dlls/kernel32/nls/winerr_kor.mc.rc -dlls/kernel32/nls/winerr_lth.mc.rc dlls/kernel32/nls/winerr_nld.mc.rc dlls/kernel32/nls/winerr_nor.mc.rc dlls/kernel32/nls/winerr_plk.mc.rc @@ -138,7 +136,6 @@ include/msinkaut.h include/mstask.h include/msxml.h include/msxml2.h -include/netcon.h include/netfw.h include/oaidl.h include/objidl.h @@ -168,7 +165,6 @@ include/unknwn.h include/urlhist.h include/urlmon.h include/vmr9.h -include/wbemcli.h include/wincodec.h include/wine/itss.h include/wine/svcctl.h @@ -200,8 +196,7 @@ programs/winedbg/dbg.tab.h programs/winedbg/debug.yy.c programs/winedbg/winedbg.man programs/winetest/*_test.exe -programs/winetest/*_test.rc -programs/winetest/build.rc +programs/winetest/tests.rc programs/winhlp32/macro.lex.yy.c server/wineserver server/wineserver-installed diff --git a/ANNOUNCE b/ANNOUNCE dissimilarity index 97% index 099274bbeb9..15c808e95be 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -1,715 +1,560 @@ -The Wine development release 1.1.26 is now available. - -What's new in this release (see below for details): - - Still more translation updates. - - Faster bitmap stretching using XRender. - - Proxy support in WinHTTP. - - Many more JScript functions. - - Various bug fixes. - -The source is available from the following locations: - - http://ibiblio.org/pub/linux/system/emulators/wine/wine-1.1.26.tar.bz2 - http://prdownloads.sourceforge.net/wine/wine-1.1.26.tar.bz2 - -Binary packages for various distributions will be available from: - - http://www.winehq.org/site/download - -You will find documentation on http://www.winehq.org/site/documentation - -You can also get the current source directly from the git -repository. Check http://www.winehq.org/site/git for details. - -Wine is available thanks to the work of many people. See the file -AUTHORS in the distribution for the complete list. - ----------------------------------------------------------------- - -Bugs fixed in 1.1.26: - - 758 Menu/combo-box-functionality in managed mode. - 4277 GetPixel() returns wrong value for monochrome bitmaps - 5034 Wrong size of commdlg OpenFile dialog in radvideo.exe - 8290 Lotus Notes 6.5 demo fails to install - 9036 Adobe Photoshop Elements 1.0 fails to install, says IE4 is required - 9599 Caesar3 hackled sound - 9614 scroll wheel causes farcry crash. - 10394 No$gba Open file dialog non-resizable (OFN_ENABLESIZING not implemented) - 11015 Save games not ordered properly. - 11520 resident evil 4: the black,the white and the glitch - 12080 Portal 1.0: Graphics go haywire when first portal opens - 12101 SpellForce: The Order Of Dawn - Graphical bug - 12259 CoWaitForMultipleHandles Unexpected wait termination - 12600 Adobe Acrobat Pro 6 -- File Open should default to a more logical location - 12807 Team Fortress 2 crashes after running for several minutes at 1680x1050 - 12906 MyScript Notes 2.2 : Crashes on program startup after clicking "continue trial" - 13525 Word 2003: Copy/Paste Textbox converts to picture - 13575 iTunes does not start on x64 computers - 13689 Word 2003: Last opened files appear incorrectly in File menu - 13926 Dune 2000 crashes after starting a mission - 13958 Services: handle null display names properly when populating SCM db entries - 14259 Wordview hang when open Doc file with picture - 14300 winhelp: Wrong initial view position in pages - 14404 Diablo LOD/Starcraft, no sound with ALSA - 14500 Supreme Commander: Input field too narrow to enter the CD key - 14878 Some places of Far Cry game world covered by one color - 15461 Security zones are not displayed in inetcpl.cpl (ZoneMgr_CreateZoneEnumerator, _GetZoneAt, _GetZoneAttributes) - 15631 Dragon NaturallySpeaking 10 crashes after opening Accuracy Center - 15789 Icewind Dale 2 : very low framerate - 15844 Weird Dutch translation for Program files folder - 15958 "make test" hangs in winmm/wave.c in wave_out_test_device - 16454 emule crashs after an undefined time - 16682 Messed up fonts in Civilization 4 - 16767 Azgard Defence: game too slow - 16770 MSN Messenger 7.0: Chat window get the focus incorrectly - 17240 Full Tilt poker crashing - 17283 Steam crashes by logging in into the Steam Community with Gecko - 17604 The PlayOnline viewer fails to start after the initial update. - 17802 RegiStax 5 crashes at the end of stacking process - 18021 When starting The Lord of the Ring Online in additional X session, there is no sound. - 18419 Condemned: Criminal Origins: Camera images sometimes appear upside down - 18649 The Sims 3 crashes for no specific reason after a while - 18709 Breakout crashes:System.OverflowException: Value was either too large or too small for a Decimal - 18901 WoW crashes on exit when running in D3D - 19005 SimCity 4 crashes on start - 19047 Assertion failure at listview.c:2741 - 19049 Motocross Madness 2 on MacOSX: crash with fbo - 19072 Reg.exe doesn't respect help commands (appinstall) - 19143 Anarchy Online corrupted graphics - 19157 CoGetContextToken and CoGetObjectContext need to take existing MTA into account - 19169 Albumplayer closes with an abnormal program termination - 19211 netconn_set_timeout() is unused in winhttp - 19216 winecfg - Wine version lost - 19220 Firefox 3.5 crashes because of stub in t2embed - 19225 notepad: launching with a non-existent file does not have 'cancel' option (appinstall) - 19246 winemenubuilder.exe error - 19327 LiveZilla 3.1.8.1 installer fails to complete - 19338 ResHacker - only small part of treeview is visible - ----------------------------------------------------------------- - -Changes since 1.1.25: - -Alexander Nicolaysen Sørnes (4): - reg: Update Norwegian Bokmål translation. - notepad: Update Norwegian Bokmål translation. - crypt32: Update Norwegian Bokmål translation. - taskmgr: Update Norwegian Bokmål translation. - -Alexander Scott-Johns (3): - notepad: Refactor DoOpenFile to simplify next patch. - notepad: When opening a file, replace \0 characters with spaces, instead of truncating the file at the first \0. - notepad: Add Cancel button to message box displayed when opening a non-existent file with the command line. - -Alexandre Julliard (38): - winetest: Build exe resources as separate .res files. - loader: Get rid of the pthread support routines. - include: Get rid of the no longer used wine/pthread.h. - ntdll: Add management of the Wow64 filesystem redirection flag. - kernel32: Forward the Wow64 redirection functions to ntdll. - winetest: Load resources by name instead of id. - server: Return the process CPU in the get_process_info request. - ntdll: Support querying the Wow64 state of other processes. - kernel32: Add implementation of GetSystemWow64DirectoryA/W. - shell32: Add support for the CSIDL_SYSTEMX86 folder. - shell32/tests: Revive the test for CSIDL_SYSTEMX86. - kernel32/tests: Avoid using non-ASCII characters in strings. - configure: Apply makedep flags when doing automatic dependencies. - winebuild: Dump resource data as dwords to reduce the output file size. - winetest: Create a separate resource file with the SHA1 build id. - ws2_32: Check buffers before recvmsg() to trigger write watches. - ntdll: Display write watch status in virtual traces. - taskmgr: Convert the language-neutral resource file to UTF-8. - avifil32: Convert the language-neutral resource file to UTF-8. - msdmo: Convert the language-neutral resource file to UTF-8. - mswsock: Convert the language-neutral resource file to UTF-8. - Remove some obsolete README files. - ntdll: Add support for the MEM_RESET flag in VirtualAlloc, with tests. - kernel32: Explicitly specify the codepage in message files. - wmc: Add support for utf-8 codepage. - dbghelp: Grow all arrays by doubling the size. - oleaut32/tests: Fix the usrmarshal tests on 64-bit. - oleaut32: Fix safe array marshalling on 64-bit. - ddraw/tests: Fix a few tests that fail on Win64. - widl: Take into account the alignment of conformant arrays to pad a structure. - ddraw/tests: Fix a failing test on 64-bit. - ddraw/tests: Properly release surfaces even if we can't get the texture object. - msvcrt: Add an errno mapping for ERROR_SHARING_VIOLATION. - msi: Build a proper tab chain by walking through the controls list. - wrc: Avoid a crash if a file didn't contain any resources. - wrc: Report an error when encountering non-ASCII characters. - uuid: Include some more headers. - Updated the authors list. - -Anders Jonsson (4): - notepad: Update Swedish translation. - winedbg: Add Swedish translation. - winemine: Add ellipses for menu entries that open new dialog windows. - winemine: Add Swedish translation. - -Andrew Eikum (4): - gdiplus: Implement GdipBeginContainer2 and GdipEndContainer. - gdiplus/tests: Test cases for GdipBeginContainer2. - gdiplus: Don't modify container list if container restoration fails. - gdiplus: Implement GdipSaveGraphics and GdipRestoreGraphics. - -Andrew Nguyen (3): - server: Remap the EROFS errno value to STATUS_ACCESS_DENIED. - kernel32: Implement WTSGetActiveConsoleSessionId as a stub. - t2embed: Implement TTLoadEmbeddedFont as a stub. - -Andrew Talbot (3): - dbghelp: Constify some variables. - dbghelp: Constify some variables. - dbghelp: Constify some variables. - -André Hentschel (8): - crypt32: Update German translation. - winecfg: Improve German About dialog. - cmd: Fix German translation. - cmd: Update German translation. - appwiz.cpl: Correct German language. - shell32: Correct German language. - appwiz.cpl: Fix German translation. - winecfg: Add the codepage pragma for German translation. - -Aric Stewart (13): - shlwapi: Forward UrlCrackW to wininet.InternetCrackUrlW. - msctf: Correct return value from GetValue. - msctf: Add definition for IEnumTfDocumentMgrs. - msctf: Add code to track created ITfDocumentMgrs. - msctf: Implement ITfThreadMgr::EnumDocumentMgrs. - msctf/tests: Test EnumDocumentMgrs. - taskmgr: Update Japanese resource. - sane: Add Japanese resource. - msvidc32: Add Japanese resource. - iccvid: Add Japanese resource. - devenum: Add Japanese resource. - sane: Remove BOM from Japanese resource. - gdi32: In init_system_links, reinitialize val_len and data_len before continuing. - -Aurimas Fišeras (7): - crypt32: Add "Disallowed" to CryptFindLocalizedName. - Various spelling fixes for Lithuanian translation. - cryptui: Add Lithuanian translation. - crypt32: Add Lithuanian translation. - cryptdlg: Translate "CPS" (Certification Practice Statement) to Lithuanian and add a comment to English resource. - kernel32/nls: Add Lithuanian winerr translation. - appwiz.cpl: Update Lithuanian translation. - -Austin English (4): - notepad: Fix English resource line breaks. - hal: Add stub for KeGetCurrentIrql. - shell32: Fix folder names for Dutch locale. - shell32: More Dutch translations fixes. - -Damjan Jovanovic (3): - ws2_32: Add some AcceptEx tests. - ws2_32: Test AcceptEx short reads. - ws2_32: Test AcceptEx early disconnects and invalid parameters. - -Dan Kegel (1): - winmm: Don't convert return string in mciSendStringA on error. - -Daniel Nylander (1): - appwiz.cpl: Add Swedish translation. - -David Adam (18): - d3dx9_36: Fix tests to make them pass in Windows. - d3dx9_36: Fix the sprite tests to make them pass in Windows. - d3dx9: Fix the prototype of some functions. - d3dx9: Add d3dx9.h in dxguid. - d3dx9: Merge d3dx8 core into d3dx9. - d3dx9: Merge d3dx8 mesh into d3dx9. - d3dx9: Merge d3dx8 mesh tests into d3dx9. - d3dx9: Merge d3dx8 math into d3dx9. - d3dx9: Clean-up the spec file. - d3dx9: Merge d3dx8 math tests into d3dx9. - d3dx9: Remove the useless d3dx8 import. - dxguid: Remove the useless d3dx8 include. - d3dx8: Remove the d3dx8 dll. - include: Remove useless headers. - d3dx9: Fix D3DXQuaternionToAxisAngle to make tests pass in Windows. - d3dx9: Remove a failing test in Windows. - d3dx9: Fix D3DXQuaternionInverse to make tests pass in Windows. - d3dx9: Fix D3DXQuaternionNormalize to make tests pass in Windows. - -Detlef Riekenberg (5): - include: Add IInternetZoneManagerEx2 interface for IE7. - urlmon: Partial InternetZoneManagerEx2 implementation. - urlmon/tests: Add tests for CoInternetCreateZoneManager. - urlmon/tests: Windows headers need _WIN32_IE for IInternetZoneManagerEx2. - winemine: Add ellipses for IDM_CUSTOM. - -Dmitry Timoshkov (3): - user32: Fix some BM_SETSTYLE test failres under Win9x. - comctl32: Do not redraw treeview in TVM_INSERTITEM handler if bRedraw is not set, trigger the redraw on WM_SETREDRAW/TRUE. - comctl32: Explicitly initialize visible order of a newly added item, force visible order recalculation on redraw. - -Dylan Smith (6): - richedit: Support ascii RTF in WM_SETTEXT even for unicode messages. - richedit: Add more tests for WM_SETTEXT RTF support. - richedit: Prevent autoscrolling without ES_AUTO[VH]SCROLL style. - richedit: Initially disable scrollbars for ES_DISABLENOSCROLL. - richedit: Keep scrollbars hidden without WS_HSCROLL & WS_VSCROLL. - richedit: Handle missing colours in rtf colour table. - -Eric Pouech (2): - winedbg: 'Int XX' is not a function call, so don't try to handle it as such on i386. - dbghelp: Fixed regressions introduced by growing arrays exponentially instead of linearly. - -Erik Inge Bolsø (1): - wined3d: Fix Nvidia GTX series misdetection. - -Francois Gouget (10): - winapi: Simplify and improve the readability of the C parsers. - ole32: Reorder some compobj functions to avoid forward declarations. - ole32: Make apartment_addref() static. - notepad: Remove spaces before '\n's. - winefile: Remove space before ellipsis. - urlmon/tests: Fix two ok() trailing '\n's. - winapi: Introduce a pseudo-loop in parse_c_variable() to get rid of the $finished variable. - winapi: Modify parse_c_typedef() to get rid of the $finished variable. - winapi/c_parser: Badly indenting a closing brace should be a warning, not an error. - winapi/c_parser: Remove special cases for DEFINE_SHLGUID() and ICOM_DEFINE(). - -Frédéric Delanoy (54): - oleacc: Update French translation. - user32: Update French translation. - winmm: Fix French translation. - cmd: Fix French translation. - notepad: Update French translation. - oleview: Fix French translation. - regedit: Fix French translation & UI display. - taskmgr: Update French translation; display fixes. - uninstaller: Fix French translation. - winecfg: Fix French translation & UI display. - wineconsole: Fix French translation & UI display. - winhlp32: Fix French translation. - notepad: Update French translation. - winefile: Fix French translation & UI display. - wordpad: Fix French translation & UI display. - xcopy: Fix French translation. - wininet: Fix French translation & UI display. - crypt32: Update French translation. - serialui: Fix French translation & UI display. - avifil32: Fix French translation. - iccvid: Fix French translation. - oledlg: Fix French translation & UI display. - wineps.drv: Fix French translation & UI display. - setupapi: Fix French translation & UI display. - shlwapi: Fix French translation. - msrle32: Fix French translation. - appwiz.cpl: Fix French translation & UI display. - msacm32: Fix French translation & UI display. - wldap32: Fix French translation. - comdlg32: Fix French translation & UI display. - comctl32: Fix French translation & UI display. - mpr: Fix French translation. - winspool.drv: Convert French resources to UTF-8. - mshtml: Convert French resources to UTF-8. - taskmgr: Fix typo in French translation. - shdoclc: Fix French translation & UI display. - msvfw32: Fix French UI display. - msvidc32: Convert French resources to UTF-8. - progman: Fix French translation & UI display. - winemine: Fix French translation & UI display. - view: Convert French resources to UTF-8. - comdlg32: Fix left-right margins inversion in French page setup UI. - comdlgtst: Fix French translation & UI display. - reg: Fix French translation. - clock: Convert French resources to UTF-8. - shell32: Fix French translation & UI display. - cryptdlg: Update French translation. - cryptui: Fix UI display. - cryptui: Fix French translation & UI display. - kernel32: Convert French resources to UTF-8. - kernel32: Convert German error msgs resources to UTF-8. - kernel32: Fix typos in English errors messages. - appwiz.cpl: Fix French UI display and wording. - kernel32: Update French translation of error messages. - -Hans Leidekker (10): - iphlpapi: Use a separate index to count addresses in GetAdaptersAddresses. - winhttp: Implement WinHttpSetTimeouts. - include: Add IWbemStatusCodeText and IWbemLocator interfaces. - wbemprox: Add a stub implementation of IWbemLocator. - wbemprox: Add class factory. - wbemprox: Register interfaces. - wmiutils: New dll. - wmiutils: Add a stub implementation of IWbemStatusCodeText. - wmiutils: Add class factory. - wmiutils: Register interfaces. - -Henri Verbeet (45): - wined3d: Get rid of the redundant "return_value" variable. - winedd3d: Get rid of a useless trace. - wined3d: Get rid of the unused gl_version and glx_version fields. - wined3d: Remove the gl_renderer field from WineD3D_GL_Info. - wined3d: Avoid a forward declaration. - wined3d: Avoid an unnecessary strcpy(). - wined3d: Add some missing float suffixes. - wined3d: checkGLcall() doesn't need a \n. - wined3d: Get rid of some pointers in WINED3DADAPTER_IDENTIFIER. - wined3d: Replace some shader_is_pshader_version() calls with plain type checks. - wined3d: Implement a A8R8G8B8 to X8R8G8B8 surface format converter. - wined3d: Avoid destroying the currently active context for non-implicit swapchains. - wined3d: Trace the D3D shader in find_glsl_vshader() / find_glsl_pshader(). - wined3d: Fix a sign compare warning in glsl_shader.c. - wined3d: Fix a sign compare warning in shader_vaddline(). - wined3d: Reuse the shader buffer between shaders. - wined3d: Rename "SHADER_BUFFER" to something sane. - wined3d: Allow shader_buffer_init() to fail. - wined3d: Get rid of the useless "fragcolor" variable in shader_glsl_generate_pshader(). - wined3d: Fix some cast-qual warnings. - wined3d: Simplify the GLSL sRGB write code. - wined3d: Remove GetGlDesc() from the public IWineD3DSurface interface. - wined3d: Get rid of struct glDescriptor. - wined3d: Take geometry shaders into account in shader_glsl_load_constantsB(). - d3d9/tests: Use color_match() in a few more places. - d3d10: Add the ID3D10EffectMatrixVariable interface. - d3d10: Parse local buffers. - d3d10: Parse local buffer names. - d3d10: Merge parse_fx10_technique() and parse_fx10_technique_index(). - d3d10: Marge parse_fx10_pass() and parse_fx10_pass_index(). - wined3d: Remove the remains of an ATI_fragment_shader hack. - wined3d: Check the return values for some wgl calls. - d3d10: Do all effect object parsing in parse_fx10_object(). - d3d10: Parse effect variables. - d3d10: Implement ID3D10Effect::GetVariableByName(). - wined3d: Recognize SM4 arrays. - wined3d: Recognize the SM4 constant buffer register type. - wined3d: Recognize the SM4 rsq opcode. - wined3d: Recognize the SM4 dp3 opcode. - wined3d: Recognize the SM4 dp4 opcode. - wined3d: Rename _WineD3D_GL_Info to struct wined3d_gl_info. - wined3d: Store a pointer to wined3d_gl_info in struct WineD3DContext. - wined3d: Pass the context instead of the device to the various context functions. - wined3d: Always use context_bind_fbo() to change the framebuffer binding. - wined3d: Avoid redundant FBO binds. - -Hib Eris (4): - msi/tests: Add tests for MsiViewModify ASSIGN mode. - msi: Implement ASSIGN mode in MsiViewModify. - oleaut32/tests: Add tests for VarDecCmp. - oleaut32: Prevent overflow in VarDecCmp. - -Huw Davies (11): - gdi32: Use a modified version of MulDiv to match native behaviour. - winhlp32: Add English neutral translations. - wineconsole: Add English neutral translations. - winecfg: Add English neutral translations. - hhctrl.ocx: Add English neutral translations. - regedit: Update English neutral translations. - shdoclc: Add English neutral translations and fix US English. - gdi32/tests: Don't continue with the tests if GetWinMetaFileBits fails. - wordpad: Add English neutral translations. - gdi32/tests: Allow a small tolerance when comparing scaling values. - gdi32/tests: Add a broken case for some versions of winxp. - -Hwang YunSong (4): - crypt32: Updated Korean resource. - cryptdlg: Updated Korean resource. - cryptui: Updated Korean resource. - notepad: Updated Korean resource. - -Jacek Caban (17): - mshtml: Don't call AutoRegister on GRE directory - it's no longer needed. - urlmon: Ignore QueryInterface call for an undocumented interface. - urlmon: Moved more initialization code to init_test. - mshtml: Added support for VT_UINT name in IHTMLElementCollection::item. - wininet: Rename WININETHANDLEHEADER to object_header_t. - wininet: Rename WININETHTTPSESSIONW to http_session_t. - wininet: Rename WININETHTTPREQW to http_request_t. - wininet: Rename WININETAPPINFOW to appinfo_t. - wininet: Rename WININETFTPSESSIONW to ftp_session_t. - wininet: Rename WININETFTPFILEW to ftp_file_t. - include: Added netcon.idl. - wininet: Rename WININET_strdupW to standard heap_strdupW. - wininet: Rename WININET_strdup_AtoW to heap_strdupAtoW and handle NULL argument in its implementation. - wininet: Rename WININET_strdup_WtoA to heap_strdupWtoA. - wininet: Code clean up by using heap_strdup* functions. - wininet: Code clean up by using heap_strdup* functions. - include: Added ntddndis.h. - -Jeff Latimer (2): - ws2_32/tests: IPv6 tests for WSAAddressToStringW. - ws2_32: IPv6 functionality for WSAAddressToStringW. - -Joel Holdsworth (1): - gdi32/tests: Added tests for BitBlt. - -Juan Lang (34): - cryptui: Increase control width to support larger fonts. - winhttp: Change type of netconn_resolve from struct sockaddr_in * to struct sockaddr *. - winhttp: Simplify netconn_resolve when using getaddrinfo. - winhttp: Convert connect_t's address type from a struct sockaddr_in to a struct sockaddr_storage. - winhttp: Support IPv6 addresses in open_connection. - winhttp: Support IPv6 in netconn_resolve. - wininet: Fix tests when running behind a proxy server. - wininet: Change type of GetAddress from struct sockaddr_in * to struct sockaddr *. - wininet: Simplify GetAddress when using getaddrinfo. - wininet: Use struct sockaddr_storage in InternetCheckConnectionW. - wininet: Use length reported by GetAddress in FTP_Connect. - wininet: Use sizeof(member) rather than sizeof(type) for address lengths. - wininet: Use address length returned by GetAddress in NETCON_connect. - wininet: Convert WININETSESSIONW's socketAddress to a struct sockaddr_storage. - wininet: Support IPv6 addresses in HTTP_ResolveName and HTTP_OpenConnection. - wininet: Fail in FTP if the resolved name is not an IPv4 address. - wininet: Support IPv6 in GetAddress. - winhttp: Add tests for WinHttpSetDefaultProxyConfiguration. - winhttp: Implement WinHttpSetDefaultProxyConfiguration. - winhttp: Implement WinHttpGetDefaultProxyConfiguration. - winhttp: Support getting the default proxy settings from the http_proxy environment variable. - winhttp: Honor WINHTTP_ACCESS_TYPE_DEFAULT_PROXY in WinHttpOpen. - winhttp: Set connect_t's servername and port based on proxy settings. - winhttp: When connecting via a proxy include full hostname and scheme in path. - winhttp: Connect to the proxy port rather than the host port. - winhttp: Use a helper function to set connect_t's servername and port. - winhttp: Use proxy server when redirecting. - winhttp: Allow full path in addition to relative path in headers to accomodate proxy servers. - winhttp: Don't set port number to a default before scheme is known. - winhttp: Issue CONNECT command to connect to a secure server through a proxy server. - winhttp: Fix a comment typo. - winhttp: Use the correct address length when connecting. - ws2_32: Remove an unnecessary cast. - ws2_32: Make sure sockaddr is big enough when formatting an IPv6 address. - -Maarten Lankhorst (1): - winealsa.drv: Add support for indirect read/write in directsound support. - -Michael Stefaniuc (42): - winecfg: Fix regression introduced by 807d75a94e378d05. - oleacc: Add missing encoding info to the German resource file. - cryptdlg: Add missing encoding info to the German resource file. - shdoclc: Convert the German resources to UTF-8. - cmd: Convert the German resources to UTF-8. - view: Convert the German resources to UTF-8. - wineps.drv: Convert the German resources to UTF-8. - winspool.drv: Convert the German resources to UTF-8. - uninstaller: Convert the German resources to UTF-8. - msrle32: Convert the German resources to UTF-8. - wineboot: Convert the German resources to UTF-8. - serialui: Convert the German resources to UTF-8. - avifil32: Convert the German resources to UTF-8. - msvfw32: Convert the German resources to UTF-8. - hhctrl.ocx: Convert the German resources to UTF-8. - credui: Convert the German resources to UTF-8. - gphoto2.ds: Convert the German resources to UTF-8. - winhlp32: Convert the German resources to UTF-8. - winemine: Convert the German resources to UTF-8. - localui: Convert the German resources to UTF-8. - start: Convert the German resources to UTF-8. - clock: Convert the German resources to UTF-8. - comctl32: Convert the German resources to UTF-8. - xcopy: Convert the German resources to UTF-8. - wldap32: Convert the German resources to UTF-8. - cmdlgtst: Convert the German resources to UTF-8. - notepad: Convert the German resources to UTF-8. - oleview: Convert the German resources to UTF-8. - progman: Convert the German resources to UTF-8. - wineconsole: Convert the German resources to UTF-8. - oledlg: Convert the German resources to UTF-8. - winefile: Convert the German resources to UTF-8. - comdlg32: Convert the German resources to UTF-8. - winmm: Convert the German resources to UTF-8. - wrc: Reset the language before processing multiple rc files. - winecfg: Convert the German resources to UTF-8. - user32: Update the German resources and switch them to UTF-8. - shell32: Convert the German resources to UTF-8. - taskmgr: Convert the German resources to UTF-8. - Set the encoding of the remaining German resources to UTF-8. - Set the encoding of the Romanian resources to UTF-8. - wordpad: Change some string resource ids to logically group the strings in separate STRINGTABLEs. - -Mike Kaplinskiy (1): - ws2/tests: Test AcceptEx with a deferred socket. - -Nikolay Sivov (15): - comctl32/listview: Basic LVM_GETITEMSPACING tests. - user32/spy: Update ListView message table. - comctl32/listview: Fix some test failures on 4.7x. - comctl32/listview: More LVM_*HITTEST tests. - comctl32/listview: Fix hittesting for "small" positive Y coordinates. - comctl32/listview: Fix hittest flag calculation for negative Y values on report mode. - comctl32/listview: A basic test for column width default value. - comctl32/listview: Basic LVN_(BEGIN|END)SCROLL tests. - comctl32/listview: Fix selection and focus rectangles on reordered list (report mode). - comctl32/header: Test item rectangles updating after reordering. - comctl32/header: Always update rectangles after HDM_SETORDERARRAY. - comctl32/header: Use macro to define LPARAM value. - comctl32/header: Update item bounds on WM_SIZE. - comctl32/header: Fix hittesting flags, extend tests a bit. - comctl32/dpa: Don't use start index on searching sorted array. - -Owen Rudge (4): - appwiz.cpl: Replace Add/Remove button with separate Modify and Remove buttons. - appwiz.cpl: Read modification path from registry. - appwiz.cpl: Enable/disable Modify button, and modify title on Remove button, as appropriate. - appwiz.cpl: Execute installer when Modify clicked. - -Paul Chitescu (1): - crypt32: Updated Romanian translation. - -Paul Vriens (16): - gdi32/tests: Mark an intermittent failure as broken() on Win9x/ME. - d3d9/tests: Skip a test on failure. - ole32/tests: Reset a variable before testing. - comdlg32: Fixed size of Dutch control. - cryptui: Fix Dutch translations. - crypt32: Make sure we show Unicode characters (Dutch translation). - cryptui: Show the select store text when browsing stores. - crypt32: Improve an English resource. - crypt32: Fix Dutch translations. - shell32: Add missing encoding for Dutch resources. - winhlp32: Improve Dutch translations and convert to UTF8. - ws2_32/tests: Fix a test failure on NT4. - comctl32/tests: Fix test failures with comctl32 <= 5.80. - appwiz.cpl: Fix Dutch translations. - winedbg: Remove an unneeded pragma from the Swedish translation. - winhttp: Fix a crash on Vista and higher. - -Peter Oberndorfer (1): - winemenubuilder: Use heap_printf to allocate the right amount of memory and not cause heap corruption. - -Piotr Caban (46): - jscript: Added DateConstr_parse implementation. - jscript: Added string argument handling to Date constructor. - jscript: Added calling Date as function implementation. - jscript: Fix do while loop parsing. - jscript: Added Date_valueOf implementation. - jscript: Added Boolean constructor implementation. - jscript: Added Bool_toString implementation. - jscript: Added Bool_valueOf implementation. - jscript: Added Bool_toLocaleString implementation. - jscript: Fixed to_boolean implementation. - jscript: Fix DateConstr_parse implementation. - jscript: Inherit Array valueOf from Object. - jscript: Added Object_valueOf implementation. - jscript: Added Object_toString and Object_toLocaleString implementation. - jscript: Added Function_valueOf implementation. - jscript: Changed to_primitive implementation. - jscript: Added String_fontcolor implementation. - jscript: Added String_fontsize implementation. - jscript: Added String_anchor implementation. - jscript: Added String_link implementation. - jscript: Change do_attributeless_tag_format so it works on non string objects. - jscript: Make do_attribute_tag_format generic. - jscript: Make String_charAt generic. - jscript: Make String_charCodeAt generic. - jscript: Make String_indexOf generic. - jscript: Make String_match generic. - jscript: Make String_replace generic. - jscript: Make String_slice generic. - jscript: Make String_split generic. - jscript: Make String_substring generic. - jscript: Make String_toLowerCase generic. - jscript: Make String_toUpperCase generic. - jscript: Fix String_match implementation. - jscript: Inherit Function_valueOf from Object. - jscript: Added Array length setting implementation. - jscript: Added implementation of Array constructor called as a function. - jscript: Added call_expression_eval implementation for EXPRVAL_VARIANT values. - jscript: Added Array_slice implementation. - jscript: Added String_fromCharCode implementation. - jscript: Added Date_getYear implementation. - jscript: Improve to_string implementation. - jscript: Improve Number_toString implementation. - jscript: Added RegExp_test stub. - jscript: Improve Object_toString implementation. - jscript: Remove broken tests. - jscript: Fix create_exec_ctx implementation. - -Rein Klazes (5): - comdlg32: Rearrange some more controls when resizing a file dialog. - comdlg32: Fix a problem with resizing a customized file dialog. - comdlg32: Memorize and restore the size of the file dialog between calls. - comdlg32/tests: Remove file dialog resize tests that rely on CDN_SELCHANGE notifications. - user32/tests: Show that Windows avoids creating loops in a menu tree, probably by limiting the depth of such tree. - -Ricardo Filipe (27): - comdlg32: Update Portuguese translation and convert to UTF8. - oledlg: Update Portuguese translation and convert to UTF8. - notepad: Update Portuguese translation and convert to UTF8. - cmdlgtst: Update Portuguese translation and convert to UTF8. - setupapi: Update Portuguese translation and convert to UTF8. - shell32: Update Portuguese translation and convert to UTF8. - user32: Update Portuguese translation and convert to UTF8. - clock: Update Portuguese translation and convert to UTF8. - mpr: Update Portuguese translation and convert to UTF8. - comctl32: Update Portuguese translation and convert to UTF8. - oledlg: Fix Portuguese translation. - progman: Update Portuguese translation and convert to UTF8. - regedit: Update Portuguese translation and convert to UTF8. - winecfg: Update Portuguese translation and convert to UTF8. - wineconsole: Update Portuguese translation and convert to UTF8. - winefile: Update Portuguese translation and convert to UTF8. - crypt32: Update Portuguese translation and convert to UTF8. - reg: Update Portuguese translation and convert to UTF8. - taskmgr: Update Portuguese translation and convert to UTF8. - gphoto2.ds: Fix Portuguese translation and convert to UTF8. - mshtml: Update Portuguese translation and convert to UTF8. - shdoclc: Fix Portuguese translation and convert to UTF8. - appwiz.cpl: Update Portuguese translation and convert to UTF8. - winefile: Fix Portuguese translation. - wordpad: Update Portuguese translation and convert to UTF8. - cryptdlg: Add Portuguese translation. - devenum: Update Portuguese translation. - -Rico Schüller (1): - d3d10: Rename struct d3d10_effect_variable to struct d3d10_effect_object. - -Roderick Colenbrander (8): - winex11: Get rid of the static Xrender picture format table. - winex11: Move AlphaBlend over to get_xrender_format. - winex11: Move glyph code over to get_xrender_format. - winex11: Get rid of depth conversion fixme. - winex11: Add a helper function for converting a random color to a XRenderColor. - winex11: Add an XRender based GetSrcAreaStretch. - winex11: Use set_xrender_transformation in AlphaBlend. - winex11: Add a function for retrieving the bitmap GC. - -Stefan Dösinger (10): - wined3d: An indirect address op can adjust min and max at the same time. - wined3d: Add Intel GMA X3100 to our card DB. - wined3d: Update Nvidia driver versions. - wined3d: Only use 4 component specular colors if GL allows it. - wined3d: Drop the color0 mov optimization if the src is overwritten. - wined3d: Check the correct constant limit. - wined3d: EXP and EXPP are scalar operations. - wined3d: Set the depth blit helper texture address mode to clamp. - wined3d: Don't call glGetError if nobody is listening. - wined3d: Use the unmodified source in MOVA. - -Vincent Povirk (15): - windowscodecs: Implement CopyPalette for BMP decoder. - windowscodecs: Add test for 1-bit indexed color BMP. - windowscodecs: Add test for 4-bit indexed color BMP. - windowscodecs: Return proper error codes in unneeded BMP decoder methods. - windowscodecs: Add support for decoding RLE8-encoded BMP files. - windowscodecs: Add support for decoding RLE4-encoded BMP files. - gdiplus: Use brush_fill_path in GdipFillEllipse. - gdiplus: Use brush_fill_path in GdipFillPie. - gdiplus: Use brush_fill_path in GdipFillPolygon. - gdiplus: Use brush_fill_path in GdipFillPolygonI. - gdiplus: Use brush_fill_path in GdipFillRegion. - gdiplus: Use brush_fill_path in GdipFillRectangleI. - gdiplus: Implement GdipSetLineLinearBlend. - windowscodecs: Don't leak memory when BmpFrameDecode_CopyPalette fails. - windowscodecs: Register BMP decoder as a bitmap decoder. - -Vitaliy Margolen (1): - shell32: Export IsUserAnAdmin by name as well. - -Vladimir Pankratov (3): - regedit: Implement open last key at startup. - comctl32: Fix division by zero. - cmd: Convert the Russian resources to UTF-8. - -Yuri Khan (1): - winex11.drv: Handle clipboard on an auxiliary thread for windowless apps. - --- -Alexandre Julliard -julliard@winehq.org +The Wine development release 1.1.24 is now available. + +What's new in this release (see below for details): + - Support for freedesktop file associations. + - Support for exception handling on 64-bit. + - Improved ARB shaders. + - Fixes for the FBO mode. + - Many listview improvements. + - Various bug fixes. + +The source is available from the following locations: + + http://ibiblio.org/pub/linux/system/emulators/wine/wine-1.1.24.tar.bz2 + http://prdownloads.sourceforge.net/wine/wine-1.1.24.tar.bz2 + +Binary packages for various distributions will be available from: + + http://www.winehq.org/site/download + +You will find documentation on http://www.winehq.org/site/documentation + +You can also get the current source directly from the git +repository. Check http://www.winehq.org/site/git for details. + +Wine is available thanks to the work of many people. See the file +AUTHORS in the distribution for the complete list. + +---------------------------------------------------------------- + +Bugs fixed in 1.1.24: + + 2720 File open dialog crashes in Micrographic designer + 9042 Paradise Poker Client gives black desktop background - bug + 10551 When emulating Sprint-Layout the mouse doesn't catch obejects + 10981 Anti-Grain Geometry GDI Demo does not run + 11030 JIT fails to launch + 11942 Trouble with actor's shadow in "Journey to the Center of the Earth" + 12137 Test Drive: Unlimited slow performance + 12169 Supreme Commander: Black bar obscuring screen when fidelity >low + 12183 EVE Premium 4.10.51200 does not render correctly with shadows on + 12380 Support fd.o file type associations + 12405 Crash at starting WISO Sparbuch 2008 + 13266 ArchiCad 11 installer: Crashes after extraction (Java related?) + 13705 keyboard does not work in Trackmania Nations Forever + 13917 Supreme Commander won't let me select high fidelity + 13922 configure script produces misleading warning about libhal + 14767 WGL_SWAP_METHOD_ARB attribute not implemented + 15206 Trouble with symbolic stack dumps and Chromium + 15371 HDR not rendered correctly (e.g. in Rainbow 6 Vegas) + 15377 1.1.5 breaks d3d game that worked in 1.1.4 + 15457 Languages dialog is empty in inetcpl.cpl (IMultiLanguage2_GetRfc1766Info) + 15878 Dogfood: Gimp 2.6 will not open images. + 15925 World of Warcraft: Extreme FPS drop since 3.0.2 + 16115 jscript: field with has wrong type + 16195 GetKeyNameTextW returns a wrong length + 16267 Vista Winetest24112008 MSItest loop + 16331 inetcomm: possible null pointer dereferences + 16385 Photoshop CS4 interface doesn't load + 16506 some GUI feedback is needed when wine crashes + 16521 With separate x-screens, windowed applications in the secondary screen are limited to resolution of primary screen + 16609 Wine's XDnD should support text/uri-list lines not ending in \r\n + 16681 Adobe Photoshop CS4 fails to start, complains "Some of the application components are missing..." + 17433 Photoshop CS4 crash in unimplemented function gdiplus.dll.GdipMeasureDriverString + 17437 ATI and EVE Premium: no models display / crashes on startup + 17591 WISO MeinBuero 2009 trial segfaults in wintrust.dll + 17600 MSOffice installer (XP, 2003, 2007) : msi crash in custom action + 17681 mcm2 Help immediately exists (Motocross Madness 2) + 17914 Using \n rather then \r\n breaks HTTP RFC with HTTP_AddRequestHeadersW + 18202 Programs show unhandled exception dialog on every run + 18256 Quicktime 2 Unimplemented function olesvr32.dll.OleRevokeServer on exit + 18516 Goldwave 5.25 File Save dialog no longer has options for file format... + 18610 Quicken 2009 crashes + 18617 Regedit can't import registry from standard input + 18638 .NET 3.0 apps abort with: Call from to unimplemented function GDI32.dll.GdiEntry13, aborting + 18641 Adobe Lightroom 2.3 crashes on unimplemented function gdiplus.dll.GdipCreateHICONFromBitmap + 18735 Photoshop CS4 crash in unimplemented function GdipGetVisibleClipBoundsI + 18736 Photoshop CS4 crash in unimplemented function GdipDrawDriverString + 18742 WoW: Icons under d3d are incorrectly desaturated + 18797 CATIAV5R19: Fails to install on Wine higher than 1.1.18 + 18798 Neuro-Programmer v2.5 unable to start + 18809 Dragon NaturallySpeaking 10 no longer installs + 18811 Lexware: wine crashes during .Net 2.0 SP1 Installation + 18824 Thief 3 crashes when starting a new game + 18841 Ghost Recon Installer Crashes + 18882 Allow windows links (.lnk) to be handled by Wine + 18895 Thief 3 crashes on closing. + 18900 Wineserver crashes starting Team Fortress 2 + 18915 FAR Manager: crashes shortly after startup + 18916 Thief 2 crashes when bringing up in-game menu + 18925 OS X build broken + +---------------------------------------------------------------- + +Changes since 1.1.23: + +Alexander Nicolaysen Sørnes (1): + regedit: Fix reading from stdin. + +Alexandre Julliard (47): + wininet: Always use a full URL for redirects, even with an absolute path. + user32: Disable assert() for the mingw build since mingw gets confused trying to import MessageBoxA. + kernel32: Fix handling of %ws format for Unicode. + comctl32: Avoid repainting a NULL link. + widl: Don't make the proxy virtual tables const if they use delegation. + server: Avoid a crash when trying to wait on a disconnected pipe client. + ole32: Get rid of line feeds and tabs in traces. + kernel32: Forward RtlUnwindEx to ntdll for x86_64. + winebuild: Properly restore %rax and %rbx in call_from_regs on x86_64. + rpcrt4: Adjust the start of the proxy virtual table for stubless proxies. + opengl32: Make the script default to version 1.1. Remove the glGetLevelParameter stubs. + configure: Detect the appropriate form for the __ASM_GLOBAL_FUNC macro. + configure: Add .cfi_startproc/endproc directives to assembly functions if supported. + riched20: Move the textHostVtbl definition to work around Mac OS X breakage with __ASM_GLOBAL_FUNC. + server: Restart at the head of the wait queue when we woke a thread, since this can modify the queue. + configure: Make sure that gcc is recent enough for building 64-bit code. + configure: Add a macro to define an stdcall suffix in assembly code. + configure: Add a macro to define an stdcall function in assembly. + msvcrt: Add appropriate stdcall decorations to assembly functions. + riched20: Add appropriate stdcall decorations to assembly functions. + rpcrt4: Add appropriate stdcall decorations to assembly functions. + hal: Add appropriate stdcall decorations to assembly functions. + ntoskrnl.exe: Add appropriate stdcall decorations to assembly functions. + kernel32: Add appropriate stdcall decorations to assembly functions. + ntdll: Add appropriate stdcall decorations to assembly functions. + advapi32/tests: Avoid accessing an uninitialized pointer. + advapi32: Fix self-relative security descriptor creation for 64-bit. + ntdll: Fix handling of self-relative security descriptors for 64-bit. + msvcrtd/tests: Fix calling convention for operator_new_dbg. + libwine: Add unwind annotations to the stack switching functions for x86_64. + ntdll: Add unwind annotations to the call_entry_point function for x86_64. + winebuild: Add unwind annotations to all the generated functions for x86_64. + ntdll: Handle x86_64 signals on a separate signal stack. + winebuild: Implement a --large-address-aware flag. + winegcc: Add support for the -Wl,--large-address-aware option. + ntdll: Implement stack unwinding for x86_64 builtin modules based on the Dwarf data. + include: Add a target address for unwinding for platforms that need it. + ntdll: Add support for calling the TEB exception chain handlers on x86_64. + server: The ptrace interfaces uses longs, not ints. + kernel32: Fix the HGLOBAL header size for 64-bit. + ntdll: Simplify the thread startup routine and make it CPU-specific. + ntdll: Move all thread exit processing to exit_thread(), and make RtlExitUserThread() CPU-specific. + configure: Don't accept mingw32 as target name, we need an explicit CPU specification. + rpcrt4/tests: Fix the marshalling test for Win64. + rpcrt4/tests: Fix the marshalling test for Win9x. + rpcrt4: Fix memory sizes of marshalled pointers on 64-bit. + urlmon/tests: Avoid comparing uninitialized structure data. + +Anders Jonsson (8): + ntoskrnl.exe: Stub for KeInitializeMutex. + ntoskrnl.exe: Stub for KeWaitForSingleObject. + ntoskrnl.exe: Stub for IoInitializeTimer. + ntoskrnl.exe: Stub for IoStartTimer. + ntoskrnl.exe: Stub for ExInitializeResourceLite. + ntoskrnl.exe: Stub for ExInitializeZone. + ntoskrnl.exe: Stub for PsTerminateSystemThread. + ntoskrnl.exe: Stub for ExInitializeNPagedLookasideList. + +Andrew Eikum (1): + gdiplus: Test cases and parameter checks for GdipDrawCurve. + +Andrew Talbot (8): + comctl32: Constify some variables. + comctl32: Constify some variables. + comdlg32: Constify some variables. + credui: Constify a variable. + crypt32: Constify some variables. + crypt32: Constify some variables. + crypt32: Constify some variables. + crypt32: Constify some variables. + +André Hentschel (10): + shell32/tests: Fix error messages. + wordpad: Add German translation. + shell32: Add German translation. + setupapi: Add German translation. + oleacc: Add German translation. + winedbg: Fix comment header. + cryptui: Add German translation. + cryptdlg: Add German translation. + cryptui: Improve German translation. + documentation: Keep README.de in sync. + +Aric Stewart (11): + msctf: Framework for ITfCompartmentMgr. + msctf: Define ITfCompartmentMgr for ThreadMgr. + msctf: Add ITfComponentMgr to documentmgr. + msctf: Define ITfCompartmentMgr for Context. + msctf: Setup global CompartmentMgr. + msctf: Implement ITfContext::GetDocumentMgr. + msctf: Implement ITfThreadMgr::IsThreadFocus. + msctf: Contexts have a default DocumentMgr of the one that creates them. + msctf: Implement ITfCompartmentMgr::ClearCompartment. + msctf: Implement ITfCompartmentMgr::EnumCompartments. + comctl32: In COMBOEX_FindStringExact do not try to get text from invalid items. + +Aurimas Fišeras (4): + winemine: Add Lithuanian translation. + wininet: Add Lithuanian translation. + hhctrl.ocx: Add Lithuanian translation. + oleacc: Add Lithuanian translation. + +Austin English (10): + mshtml: Make the wine-gecko warning more clear. + winex11: Return correct length for GetKeyNameText. + wine.desktop: Allow start to execute lnk files. + kernel32: GetConsoleAliasW is a stub, make sure it acts like one. + configure: Fix mach-o/dyld_images.h detection on OS X. + configure: Add a note about missing dbus if libhal is missing. + oleaut32: Fix a compiler warning for libjpeg includes. + gphoto2.ds: Fix a compiler warning for libjpeg includes. + wine.inf: Fix incorrect entry for hh.exe. + wine.inf: Add placeholder exe for wordpad.exe. + +Damjan Jovanovic (6): + winemenubuilder: Generate icons for Wine's MIME types. + start.exe: Add infrastructure to launch windows file open associations from freedesktop. + wine.inf: Update file type associations on startup. + shell32: Update file type associations when requested. + winex11.drv: Fix file drops on KDE4 and XFCE. + winemenubuilder: Log where freedesktop menu files are created, and provide an option to clean them up. + +Detlef Riekenberg (12): + mlang/tests: Fix failures with IE 5.5 and below. + mlang: Implement IMultiLanguage2_GetRfc1766Info. + mlang/tests: Add tests for IMultiLanguage2_GetRfc1766Info. + mlang/tests: Fix a failure on win98 with mlang 4.72. + mlang/tests: Store the expected results for GetRfc1766Info as Unicode. + shlwapi: Forward DnsRecordSetCompare to dnsapi. + mlang: Implement IMultiLanguage_GetRfc1766Info. + urlmon/tests: Move SecurityManager and ZoneManager tests to a separate file. + setupapi: Move IsUserAdmin to shell32.IsUserAnAdmin. + urlmon/tests: Fix a typo in an ok message. + mlang/tests: Some old IE versions truncate one character too short. + mlang: Implement IMultiLanguage_GetNumberOfCodePageInfo, with test. + +Dmitry Timoshkov (4): + wine.inf: Add kernel32.48/kernel32.49 (ReleaseThunkLock/RestoreThunkLock) to the RelayExclude list. + user32: Add support for SPI_GETFOCUSBORDERWIDTH and SPI_GETFOCUSBORDERHEIGHT. + user32: Add a test for PeekMessage((HWND)-1), make it pass under Wine. + user32: Invalidate button on WM_KILLFOCUS, like Windows does. + +Eric Pouech (1): + dbghelp: Improve speed of our hashtable implementation by remembering the last element added to every bucket. + +Francois Gouget (19): + cryptdlg & cryptui: Use SUBLANG_NEUTRAL for German. + winedos: Move VGA_SetGraphicMode() up a bit and make it static. VGA_GetModeInfoList() is unused so remove it. + winedos: DPMI_FreeInternalRMCB() is not used so remove it. + winedos: DOSVM_GetTimer() is not used so remove it. + gdi32/tests: Small indentation fix. + msctf/tests: Make EditSession_Constructor() static. + msctf: Make the CompartmentMgr functions static. + gdiplus: Remove spaces before '\n's. + winapi/c_parser: Remove some dead code. + rpcrt4/tests: Replace malloc() with HeapAlloc(). + cmd: Introduce a WCMD_strsubstW() function to simplify string substitutions. + cmd: Replace malloc() with HeapAlloc(). + comctl32: Extend the LVTILEINFO structure. + winapi: Fix a $blevel / $plevel mismatch. + wineesd.drv: Initialize the stream name before using it. + winweesd.drv: Make sure esd_all_info is always initialized and freed when needed. + wineesd.drv: Remove a redundant assignment. + dmime: Remove patterntrack.c and tool.c as they are unused and don't correspond to objects. + comctl32/tests: Make DummyCompareEx() static. + +Frank Richter (1): + d3d9: Fix bitmask for A2R10G10B10 format. + +Frédéric Delanoy (1): + documentation: Keep README.fr in sync. + +Ge van Geldorp (1): + advapi32: Set values to 0 in LsaEnumerateAccountRights. + +Gerald Pfeifer (7): + user32: Fix logic condition in SPY_DumpStructure(). + winmm: Use & instead of && for bit test in wave_out_test_deviceOut(). + wined3d: Use & instead of && for bit test in IWineD3DDeviceImpl_CreateSurface(). + wined3d: Fix (and simplify) the ATI case in IWineD3DImpl_FillGLCaps. + d3d9: Use correct constant types (WINED3DPOOL_DEFAULT instead of D3DPOOL_DEFAULT and WINED3DRTYPE_SURFACE instead of D3DRTYPE_SURFACE). + cmd.exe: Fix incorrect check in WCMD_HandleTildaModifiers(). + crypt32: Fix incorrect logic condition in test_decodePKCSAttribute(). + +Guy Albertelli (2): + kernel32/tests: Fix tests when GetVolumeNameForVolumeMountPoint fails. + kernel32/tests: Fix tests to pass on Win9x and WinME. + +Hans Leidekker (5): + msi: Add some reinstall tests. + wintrust: Add stub implementations of HTTPSCertificateTrust and HTTPSFinalProv. + wininet: Always create a URL cache entry. + wininet: Don't fail if dwReserved is set in CreateUrlCacheEntryW. + wininet: Implement InternetQueryOption(INTERNET_OPTION_CACHE_TIMESTAMPS). + +Henri Verbeet (51): + wined3d: Add support for the ARB_depth_buffer_float extension. + wined3d: Use GL_DEPTH_COMPONENT32F for WINED3DFMT_D32F_LOCKABLE. + wined3d: Use GL_DEPTH32F_STENCIL8 for WINED3DFMT_D24FS8. + wined3d: Use context_attach_depth_stencil_fbo() to clear FBO depth attachments. + wined3d: Set FBO stencil attachments for relevant depth stencil formats. + wined3d: Avoid comparing shader compile args if the relevant shader isn't present. + wined3d: Simplify some code in set_glsl_shader_program(). + wined3d: Don't modify the internal format in d3dfmt_get_conv(). + wined3d: Get rid of the silly pointers in WINED3DVOLUME_DESC. + wined3d: Add some FIXMEs about blitting with unsupported fixups. + wined3d: Set explicitly sized internal formats for color key conversion in d3dfmt_get_conv(). + wined3d: Check the correct extensions in d3dfmt_get_conv(). + wined3d: Round rows up to whole blocks for compressed surface blits in BltFast(). + wined3d: Store compression information about compressed formats. + wined3d: Use the format info for doing compressed surface blits in BltFast(). + wined3d: Remove some redundant s3tc extension checks. + wined3d: Improve some TRACEs in init_format_fbo_compat_info(). + wined3d: Use the format info to calculate compressed surface size in IWineD3DDeviceImpl_CreateSurface(). + wined3d: Use the format info to calculate compressed surface size in IWineD3DBaseSurfaceImpl_SetFormat(). + wined3d: Use the format info to calculate compressed surface pitch in IWineD3DBaseSurfaceImpl_GetPitch(). + wined3d: Use the compressed format info in IWineD3DBaseSurfaceImpl_LockRect(). + wined3d: Use WINED3DFMT_FLAG_COMPRESSED instead of checking for specific formats. + wined3d: Remove the useless "resource_type" parameter from IWineD3DDevice::CreateSurface(). + wined3d: Respect the "srgb" parameter to IWineD3DSurfaceImpl_BindTexture(). + wined3d: Avoid checking depth/stencil and compressed formats in init_format_fbo_compat_info(). + wined3d: Introduce surface_cleanup(). + wined3d: Introduce surface_gdi_cleanup(). + wined3d: Introduce surface_init() to handle most of the surface initialization. + wined3d: Introduce surface_calculate_size(). + wined3d: Get rid of the pointers in WINED3DSURFACE_DESC. + shdocvw: Take the riid parameter to TaskbarList_Create() into account. + shdocvw: Add SHDOCVW_LockModule()/SHDOCVW_UnlockModule() calls to ITaskbarList. + d3d8: Do some more verification on handles. + d3d8: Deleting an invalid pixel shader handle should return D3D_OK. + d3d8: Add tests for deleting invalid shader handles. + wined3d: Add format conversions for some depth stencil formats. + wined3d: Fix a typo. + wined3d: Fall back to backbuffer offscreen rendering if FBOs are unavailable. + wined3d: Only initialize unused components of varyings that are read. + wined3d: Avoid some unneeded depthstencil copies. + wined3d: Avoid some unneeded rendertarget copies. + wined3d: Make sure we have a context in stretch_rect_fbo(). + wined3d: Reuse the FBO for check_fbo_compat(). + wined3d: Remove some useless code in IWineD3DDeviceImpl_SetLightEnable(). + wined3d: Simplify IWineD3DSurfaceImpl_LockRect() a bit. + wined3d: Remove a redundant ActivateContext() call in IWineD3DSurfaceImpl_UnlockRect(). + d3d8: Add WINED3DFMT_W11V11U10 <=> D3DFMT_W11V11U10 conversion. + wined3d: Don't load a rendertarget just because alpha test is enabled. + d3dx9_36: Implement D3DXGetDeclVertexSize(). + d3dx9_36: Add a test for D3DXGetDeclVertexSize(). + d3d9: Use color_match() in the fog test. + +Hib Eris (1): + msi: Fix a crash when freeing memory. + +Huw Davies (6): + widl: Add support for the lcid parameter attribute. + widl: Fix typelib lcid fields to match those produced by midl. + oleaut32: TLibAttr.lcid is read from the second lcid field in the header. Confirmed by manually editing a tlb file. + oleaut32: Calling SetLcid with LOCALE_NEUTRAL is a special case which sets the first header lcid to US English and the second one to 0. + tools/widl: Fix behaviour when both lcid and retval arguments are present. + oleaut32/tests: Add some tests for [lcid] parameters. + +Jacek Caban (2): + wininet: Fixed gzip decoding on chunked stream. + urlmon: Fixed test on IE8. + +Jonathan Ernst (8): + crypt32: Updated French translation. + mshtml: Updated French translation. + notepad: Updated French translation. + regedit: Updated French translation. + setupapi: Updated French translation. + wordpad: Updated French translation. + reg: Updated French translation. + shell32: Updated French translation. + +Joris Huizer (1): + winemenubuilder: reg_get_val[AW]: Fix memory leak. + +José Manuel Ferrer Ortiz (1): + winecfg: Spanish resources update. + +Juan Lang (3): + wintrust: Only check the pgKnownSubject member if the struct includes it. + wintrust: Check for the presence of required members of WINTRUST_BLOB_INFO rather than requiring callers to be compiled with the same SDK version. + wintrust: Check for the presence of required members of WINTRUST_CERT_INFO rather than requiring callers to be compiled with the same SDK version. + +Ken Sharp (6): + gdiplus: Add stubs for GdipGetVisibleClipBoundsI, GdipDrawDriverString & GdipMeasureDriverString. + olesvr32: Add OleRevokeServer stub. + ntoskrnl: Add ObfReferenceObject stub. + ntoskrnl: Add IoRegisterFileSystem stub. + ntoskrnl: Add IoUnregisterFileSystem stub. + ntoskrnl: Add FsRtlRegisterUncProvider stub. + +Louis Lenders (1): + gdi32: Add stub for GdiEntry13. + +Marcus Meissner (2): + widl: ifdef some not always present LANG_*. + ddraw: Use correct union member. + +Michael Abbott (1): + wined3d: Remove division from inner loop. + +Mike Kaplinskiy (4): + msi: Store temporary rows in the same place as persistent rows, just with a flag. + msi: Add a test to insert a null primary key temporary row and check its order. + wininet: Make \r and \n valid header separators. + wininet/test: Test malformed header separators. + +Mikio Idneuma (1): + appwiz.cpl: Update Japanese translation. + +Nikolay Sivov (25): + ntdll: Call NtCreateSection with NULL attributes loading native dll. + comctl32/listview: Edit box should be destroyed on invalid index too (LVM_EDITLABEL). + comctl32/listview: Test showing that Edit box should be positioned after LVN_BEGINLABELEDIT. + comctl32/listview: Position edit box after notification. + comctl32/listview: Defaulting to NFR_ANSI on query failure. + comctl32/listview: Use LV_VIEW_* constants instead of style. + comctl32/listview: Revert column scrolling recent change, it should be handled differently. + comctl32/listview: Fix item count tests to be dpi aware. + comctl32/listview: Remove outdated todo entries. + comctl32/listview: Test for indentation callback. + comctl32/listview: Implement callback functionality for item indentation. + comctl32/listview: Update some ListView structures with recently added members. + comctl32/listview: Make item width calculation not rely on column order for LV_VIEW_DETAILS. + comctl32/listview: Don't use special value (1) for item width to represent both zero and one pixel width. + comctl32/header: Update some Header flags and structures. + comctl32/listview: Don't offset item box to item position on LVS_EX_FULLROWSELECT if item isn't in leftmost column. + comctl32/listview: Fix some hittest problems on LVS_EX_FULLROWSELECT. + comctl32/listview: Don't offset subitems on painting. + comctl32/listview: Get rid of Header_* macros. + comctl32/listview: Setting item text to callback stub value already having it raises item-change notifications. + comctl32/listview: Block header items drag if LVS_EX_HEADERDRAGDROP isn't set. + comctl32/listview: Forward HDN_DIVIDERDBLCLICK to parent. + comctl32/listview: Convert forwarded header notifications to ANSI if NFR_ANSI is current format. + comctl32/listview: Fix test crashes on comctl32 <5.80. + comctl32/listview: Add ability to test comctl32 version 6. Add basic LVM_[G,S]ETVIEW test. + +Paul Vriens (36): + mshtml/tests: Correct a test and show a Wine bug. + mshtml/tests: Use lstrcmpA in a helper function to make it work correctly on Win98. + mshtml/tests: Correct another test. + mshtml/tests: Use strcmp_wa instead of lstrcmpW to test correctly on Win98. + kernel32/tests: Only report unimplemented functions once. + winecfg: Fix Dutch translations. + setupapi/tests: pSetupGetField returns A or W string depending on OS. + msi/tests: Make sure we only create one logfile. + riched32/tests: Fix some test failures on Win9x/WinME/NT4. + riched32/tests: Fix a few test failures on Win9x, WinME and NT4. + riched32/tests: Correct a test to better show the behavior. + riched32/tests: Fix a few test failures on Win9x/WinME/NT4. + riched32/tests: Cater for differences between platforms. + riched32/tests: Fix test failures on Win9x, WinMe and NT4. + mlang/tests: Fix a test failure on Win95. + user32/tests: Skip some tests on Win9x/WinME. + shell32/tests: Fix a test failure on some Win95 boxes and NT4. + gdi32/tests: Fix several test failures on Win9x/WinME/NT4. + gdi32/tests: Fix some test failures on NT4. + gdi32/tests: Fix the last test failure on NT4. + shell32/tests: Fix some test failures on NT4 (and some Win95 boxes). + comdlg32/tests: Fix some typos. + comctl32/tests: Fix some typos (copy-paste). + shell32/tests: Fix a test failure on Vista. + shell32/tests: Fix a test failure on Vista. + shell32/tests: Fix a test failure on Vista and higher. + shell32/tests: Fix some test failures on Vista and higher. + wldap32/tests: Skip a test on older versions of wldap32 to prevent a crash. + shell32/tests: Fix a test failure on Vista and higher. + shell32/tests: Fix some test failures on Vista and higher. + msi/tests: Fix test (logical || with non-zero constant). + d3d8/tests: Fix some tests (logical || with non-zero constant). + msi/tests: Fix some test failures on Win95 by using more A-functions. + mapi32/tests: Don't run tests if ScInitMapiUtil() fails. + mapi32/tests: Don't run tests if ScInitMapiUtil() fails. + mapi32/tests: Don't run tests if ScInitMapiUtil() fails. + +Piotr Caban (13): + jscript: Added Date_getFullYear and Date_getUTCFullYear implementation. + jscript: Added Date_getMonth and Date_getUTCMonth implementation. + jscript: Added Date_getDate and Date_getUTCDate implementation. + jscript: Added Date_getDay and Date_getUTCDay implementation. + jscript: Added Date_getHours and Date_getUTCHours implementation. + jscript: Fixed hour_from_time and week_day functions. + jscript: Added Date_getUTCMinutes and Date_getMinutes implementation. + jscript: Added Date_getUTCSeconds and Date_getSeconds implementation. + jscript: Added Date_getUTCMilliseconds and Date_getMilliseconds implementation. + jscript: Added Date_setUTCMilliseconds and Date_setMilliseconds implementation. + jscript: Added Date_setUTCSeconds and Date_setSeconds implementation. + jscript: Added Date_setUTCMinutes and Date_setMinutes implementation. + jscript: Added Date_setUTCHours and Date_setHours implementation. + +Rein Klazes (4): + gdi32: Fix RectInRegion() if right < left or bottom < top. + winedos: int21, function 32h returns data in DS:BX, not DS:DX. + comdlg32: Delay setting the initial size of resizable file dialog until the CDN_INITDONE notification has been processed. + comdlg32/tests: Fix file dialog resize failures on NT4 and with tiny desktops. + +Rico Schüller (1): + wined3d: Don't allow a negative lock_count in buffer_Unmap. + +Robert Key (1): + wined3d: Add missing HD 3400 renderer string. + +Roderick Colenbrander (3): + opengl32: Sync with the latest opengl 3.1 extensions and don't export opengl32 1.2 functions. + opengl32: Get rid of glext.h. + wgl: Get rid of glXQueryDrawable because officially it only works on GLXDrawables. + +Stefan Doesinger (20): + wined3d: Unroll loops in ARB if needed. + wined3d: Implement break and breakc. + wined3d: Implement IFC in ARB. + wined3d: Use flags instead of bools to control shader_hw_sample. + wined3d: Implement texldd in ARB. + wined3d: Implement texldl in ARB. + wined3d: Implement vpos and vface. + wined3d: Use bitfields for reg_maps uses* members. + d3d9: Accept an alternative oFog->ps_3_0 handling. + wined3d: Fix texm3x3pad. + wined3d: Add modifier support to tex and friends. + wined3d: Implement D3DSPDM_PARTIALPRECISION support. + wined3d: Deal with instructions that do not support _SAT. + wined3d: Properly free srgb textures. + wined3d: Properly load the y correction. + wined3d: Handle SM 3.0 varyings in ARB. + wined3d: Don't run out of varyings because of clipplanes. + wined3d: Implement vertex texture fetch in ARB. + wined3d: Emulate clipplanes in ARB if the NV extensions are not available. + wined3d: Implement EvictManagedResources. + +Stefan Dösinger (5): +  wined3d: Store the bumpmap ARB constants in ARB structures. + wined3d: Implement loops with the NV extensions. + wined3d: Implement dsy in ARB. + wined3d: A small atifs bump map improvement. + wined3d: Don't set unloaded arrays to zero. + +Stefan Leichter (1): + kernel32: Implement QueryFullProcessImageNameA. + +Stefan Stranz (1): + c2man: Add xml documentation creation. + +Vincent Povirk (7): + windowscodecs: Add stub dll. + include: Add wincodec.idl. + include: Extend TVITEMEX and add NMTVDISPINFOEX. + comctl32: Use NMTVDISPINFOEX in the TVN_GETDISPINFO notification. + kernel32/tests: Test waiting on a disconnected client pipe. + gdiplus: Stub GdipSetPathGradientPresetBlend. + include: Add definitions needed for image decoding to wincodec.idl. + +Vladimir Pankratov (1): + advpack: Add stub for ExtractFilesW. + +Yann Droneaud (1): + wined3d: Improved ATI Radeon HD 4xxx detection. + +-- +Alexandre Julliard +julliard@winehq.org diff --git a/AUTHORS b/AUTHORS index 20b15d639ce..14c0d37b85f 100644 --- a/AUTHORS +++ b/AUTHORS @@ -2,7 +2,6 @@ Wine is available thanks to the work of: Sami Aario James Abbatiello -Michael Abbott Michael Abd-El-Malek Howard Abrams David Adam @@ -52,11 +51,8 @@ Nerijus Baliunas Alexandru Balut Scott Bambrough Andre Malafaya Baptista -Denis Baranov Justin Santa Barbara Aaron Barnes -Cesar Eduardo Barros -Ismael Barros Guido Barzini Jean-Claude Batista Jacek Bator @@ -73,7 +69,6 @@ Ken Belleau Yvon Belleau Maxime Bellengé Elias Benali -Luke Benstead Leo van den Berg Anders Bergh Christopher Berner @@ -86,9 +81,7 @@ Peter Beutner Stephan Beuze Georg Beyerle Pierre Beyssac -Przemysław Białek Fabian Bieler -Giuseppe Bilotta Bobby Bingham Ross Biro Hartmut Birr @@ -124,12 +117,11 @@ John Brezak Alastair Bridgewater Simon Britnell Christian Britz -Dustin Brody Nicolas Brouard Alban Browaeys Marcus R. Brown Philip Brown -Zachary Brown +Zac Brown Gregor Brunmar Stefan Brüns Tom Brus @@ -151,7 +143,6 @@ Jonathan Buzzard Jacek Caban Piotr Caban Stewart Caie -Jim Cameron Brad Campbell Jose Marcos López Caravaca Michael Cardenas @@ -225,11 +216,9 @@ Evan Deaubl Lionel Debroux Bryan DeGrendel Moses DeJong -Frédéric Delanoy Nicolas Delcros Sam Dennis Matthias Derer -Andrei Derevyanko Raul Dias Robert Dickenson Darryl Dixon @@ -237,17 +226,13 @@ Jan Djarv Petar Djukic Petr Dlouhý Roman Dolejsi -François Dorin Alexander Dorofeyev Frans van Dorsselaer Stefan Dösinger -Jeremy Drake -Yann Droneaud Josh DuBois Marcelo Duarte Charles Duffy Mark Dufour -Warren Dumortier Reece H. Dunn EA Durbin Zoran Dzelajlija @@ -255,7 +240,6 @@ Jason Edmeades Steven Edwards Christian Eggers Rikhardur Egilsson -Andrew Eikum Karsten Elfenbein John Elliot David Elliott @@ -263,10 +247,8 @@ Steven Elliott Dan Engel Ralf S. Engelschall Austin English -Rich Ercolani Morten Eriksen Jakob Eriksson -Hib Eris Jonathan Ernst Nicolas Escuder Andrey Esin @@ -279,22 +261,16 @@ Susan Farley Rob Farnum David Faure Matthias Fechner -Massimo Del Fedele -Andrew Fenn Tim Ferguson Raul Fernandes -Filipe Ferreira Wesley Filardo -Ricardo Filipe Colin Finck Matt Finnicum Aurimas Fischer Claus Fischer -Aurimas Fišeras Thomas Fitzsimmons Olaf Flebbe Yuval Fledel -Jeremiah Flerchinger Tom Fogal Krzysztof Foltman Chad Fraleigh @@ -311,7 +287,6 @@ Philippe Froidevaux Mike Frysinger Martin Fuchs Bernd Fuhrmann -Shunichi Fuji Satsuki Fujishima Ron Gage Louis Philippe Gagnon @@ -322,11 +297,9 @@ Gabriel Garcia Ramon Garcia Johan Gardell Michael Gardiner -Jérôme Gardou Martin Garton Jeff Garzik Sebastian Gasiorek -Patrick Gauthier Christopher Gautier David Gay Julio César Gázquez @@ -366,11 +339,9 @@ Jason Green Jon Griffiths Kevin Groeneveld Gerhard W. Gruber -Michael Gruber Tobias Gruetzmacher Marcin Grześkowiak Daniel Gudbjartsson -Stefano Guidoni Adam Gundy Michael Günnewig Ivan Gyurdiev @@ -383,7 +354,6 @@ Patrick Haller Stefan Haller Jake Hamby David Hammerton -Paul TBBle Hampson Noomen Hamza Anssi Hannula Charles M. Hannum @@ -403,22 +373,18 @@ Peter Hawkins Shi Quan He Mike Hearn Waldek Hebisch -Ulrich Hecht David Hedberg -Peter Hedlund Lars Heete Cameron Heide Hagen Heiduck Jukka Heinonen David Hemmo -André Hentschel Pierre d'Herbemont Juraj Hercek Bernd Herd Robert van Herk Theodore S. Hetke Dan Hipschman -Markus Hitter Haithem Hmida Roger Hoang Ben Hodgetts @@ -430,7 +396,6 @@ Erik Hofman Jörg Höhle John K. Hohm Kevin Holbrook -Joel Holdsworth Nick Holloway Alfons Hoogervorst Erich Hoover @@ -454,13 +419,11 @@ Peter Hunnisett A C Hurst Choe Hwanjin Miguel de Icaza -Mikio Idneuma Mounir Idrassi Romain Iehl Jukka Iivonen Vladdy Impaler Hiroshi Inoue -Simon C. Ion Kostya Ivanov Serge Ivanov Peter Ivanyi @@ -469,7 +432,6 @@ Michael Jacobsen Francois Jacques Lee Jaekil Gautam Jain -Tobias Jakobi Jeroen Janssen Oldrich Jedlicka György 'Nog' Jeney @@ -486,7 +448,6 @@ Jeff Johann André Johansen Andrew Johnston Matt Jones -Anders Jonsson Damjan Jovanovic Alexandre Julliard Jussi Jumppanen @@ -494,47 +455,38 @@ Bang Jun-Young Michael Jung Raphael Junqueira James Juran -Mario Kacmar Achim Kaiser Rolf Kalbermatter Maciek Kaliszewski Kaj Kaloinen -Yuriy Kaminskiy Alexander Kanavin Srivatsa Kanchi, R Jukka Kangas Thorsten Kani Pavel Kankovsky Lauris Kaplinski -Mike Kaplinskiy Michael Karcher Reinhard Karcher Niclas Karlsson Jochen Karrer Valery Kartel Rudolf Kastl -Hirofumi Katayama Michael Kaufmann Tapio Kautto Dan Kegel Matthew Kehrer Don Kelly -Robert Key -Yuri Khan Thomas Kho Sergey Khodych Vijay Kiran Kamuju Andreas Kirschbaum -Dmitry Kislyuk Simon Kissane Rafael Kitover Rein Klazes John Klehm -Ben Klein Albrecht Kleine Dietmar Kling William Knop -Florian Köberle Johannes Koch Eric Kohl Kevin Koltzau @@ -545,10 +497,7 @@ Frans Kool Oleg Korda Ilya Korniyko Alex Korobka -David Korth -Mathias Kosch Misha Koshelev -Krzysztof Kotlenga Kusanagi Kouichi András Kovács Zoltan Kovacs @@ -560,11 +509,9 @@ Jan Kratochvil David Kredba Marko Kreen Greg Kreider -Timo Kreuzer Oleg Krylov Phil Krylov Junichi Kuchinishi -Maksim Kuleshov Vik Kumar Anand Kumria Matthias Kupfer @@ -596,7 +543,6 @@ David Lassonde Jeff Latimer Paul Laufer Klaus Layer -Nicolas Le Cam Albert Lee Jaekil Lee Sander van Leeuwen @@ -609,7 +555,6 @@ Crestez Leonard Alistair Leslie-Hughes Karl Lessard Pascal Lessard -Eddie Leung Hin-Tak Leung Blake Leverett Wim Lewis @@ -638,7 +583,6 @@ Carlos Lozano Jean-Bruno Luginbühl Denis Lukianov Alexander V. Lukyanov -Austin Lund Daniel Lund Magnus Lundborg Robert Lunnon @@ -667,7 +611,6 @@ Daniel Marmier Juergen Marquardt Greg Marsden Kris Marsh -Brad Martin Philip Mason Alberto Massari Ricardo Massaro @@ -712,7 +655,6 @@ David Miller Donn Miller Jeff Miller Bruce Milner -Roman Mindalev Michal Janusz Miroslaw Anish Mistry Royce Mitchell III @@ -723,7 +665,6 @@ Andreas Mohr Todd Mokros Slava Monich James Moody -Jan de Mooij David Moore Patrick Moran Chris Morgan @@ -742,13 +683,11 @@ Gregor Münch Krishna Murthy Rick Mutzke Philippe De Muyter -Rafał Mużyło Ken Myers Kimmo Myllyvirta Zoltan Nagy Itai Nahshon Filip Navara -Juan M. Navarro Dustin Navea Felix Nawothnig Jonathan Naylor @@ -757,16 +696,12 @@ Nathan Neulinger Christian Neumair Jeremy Newman Tim Newsome -Andrew Nguyen Thuy Nguyen -Hongbo Ni Kristian Nielsen Arjen Nienhuis Jan Nieuwenhuizen -Jan-Peter Nilsson Philip Nilsson Nix N. Nix -Muneyuki Noguchi Sami Nopanen Leonard Norrgård Robert North @@ -812,7 +747,6 @@ Ted Percival Vitaly Perov James Perry Ori Pessach -Adam Petaccia Nemeth Peter Chris Peterson Jim Peterson @@ -832,7 +766,6 @@ Laurent Pinchart Aviad Pineles Brian Pirie Colin Pitrat -Davide Pizzetti Michael Ploujnikov William Poetra Yoga Hadisoesen Gracjan Polak @@ -849,7 +782,6 @@ Joseph Pranevich Raimonds Praude Aneurin Price Alex Priem -Martin Profittlich Oleg Prokhorov Roberto Augusto Pungartnik Francesco Di Punzio @@ -864,15 +796,12 @@ Pete Ratzlaff Jaime Rave Ron Record Robert Reif -Stefan Reimer Petter Reinholdtsen -John Reiser Karl Relton Daniel Remenak Andrew de los Reyes Keith Reynolds Slaven Rezic -Artem Reznikov John Richardson Rick Richardson Frank Richter @@ -884,7 +813,6 @@ Detlef Riekenberg Robert Riggs Peter Riocreux Scott Ritchie -Paul Bryan Roberts Matthew Robertson Chris Robinson Vedran Rodic @@ -892,33 +820,26 @@ Wino Rojo Troy Rollo Paul Romanyszyn Drew Ronneberg -Stephan Rose Andreas Rosenberg Bernhard Rosenkraenzer Pavel Roskin Herbert Rosmanith Elias Ross Lilia Roumiantseva -Owen Rudge Paul Rupe -Mike Ruprecht Johannes Ruscheinski Andy Rysin Daniel Sabo Adam Sacarny Ivan de Saedeleer Madhura Sahasrabudhe -Diaa Sami Kasper Sandberg Thomas Sandford -Daniel Santos Constantine Sapuntzakis Pablo Saratxaga Kouji Sasaki Mike Schaadt Carl van Schaik -Florian Tobias Schandinat -Peter Schauer Paul van Schayck Daniel Schepler Johannes E. Schindelin @@ -929,7 +850,6 @@ Ulrich Schmid Axel Schmidt Bernd Schmidt Ian Schmidt -Ryan Schmidt Juergen Schmied Ingo Schneider Victor Schneider @@ -942,20 +862,17 @@ Tim Schwartz Federico Schwindt Wolfgang Schwotzer Dan Scott -Alexander Scott-Johns Tim Segall Hajime Segawa Pavel Semerad Hippocrates Sendoukas Stas Sergeev -Ken Sharp Jeremy Shaw Roy Shea Robert Shearman John Sheets Shachar Shemesh Nickolay V. Shmyrev -Ilya Shpigor Santosh Siddheshwar Stefan Siebert Yngvi Sigurjonsson @@ -967,7 +884,6 @@ Ivan Sinitsin Dmitrij Sinukov Willie Sippel Nikolay Sivov -Kjell Rune Skaaraas Daniel Skorka Jesper Skov Neil Skrypuch @@ -988,7 +904,6 @@ Pablo Spallanzani Thomas Spear Chris Spencer Liu Spider -Matej Spindler Patrick Spinler Serge S. Spiridonoff Alexey Spiridonov @@ -1009,9 +924,7 @@ Johannes Stezenbach Oliver Stieber Clinton Stimpson William Stinson -Adam Stoelting Richard Stonehouse -Stefan Stranz Dominik Strasser Patrik Stridvall Vadim Strizhevsky @@ -1052,17 +965,14 @@ Goran Thyni Steve Tibbett Dmitry Timoshkov Marco Timpano -Will Tipton Jimmy Tirtawangsa Petr Tomasek Jon Tombs Janusz Tomczak Allan Tong -Gal Topper Linus Torvalds Luc Tourangeau Jeff Tranter -Pavel Troller Gregory Trubetskoy Lauri Tulmin Petri Tuomola @@ -1100,7 +1010,6 @@ Ferenc Wagner Ronan Waide Daniel Walker Martin Walker -Wolfgang Walter Simon Walton Owen Wang Eric Warnke @@ -1127,11 +1036,9 @@ Jan Willamowius Carl Williams Eric Williams Grant Williamson -Chris Wilson Jed Wing Andre Wisplinghoff Christoph von Wittich -Łukasz Wojniłowicz Dan Wolf Erwin Wolff Philipp Wollermann @@ -1139,7 +1046,6 @@ Ivan Wong Brandon Woodmansee Alex Woods Cliff Wright -Tim Wright Chia-I Wu Gerold Jens Wucherpfennig Karl Guenter Wuensch @@ -1163,8 +1069,6 @@ Lei Zhang Yuxi Zhang Shanren Zhou Andrew Ziem -G. Paul Ziemba -Daniel Zimmermann Nikolas Zimmermann Alex Zorach Nathan Zorich diff --git a/Make.rules.in b/Make.rules.in index 2b83943117d..c01a2b714a4 100644 --- a/Make.rules.in +++ b/Make.rules.in @@ -118,8 +118,7 @@ IDL_GEN_HEADERS = $(IDL_H_SRCS:.idl=.h) $(IDL_C_SRCS:.idl=.h) $(IDL_I_SRCS:.idl= CLEAN_TARGETS = $(IDL_GEN_C_SRCS) $(IDL_GEN_HEADERS) $(IDL_TLB_SRCS:.idl=.tlb) $(IDL_P_SRCS:%=dlldata.c) \ $(BISON_SRCS:.y=.tab.c) $(BISON_SRCS:.y=.tab.h) $(LEX_SRCS:.l=.yy.c) $(MC_SRCS:.mc=.mc.rc) -OBJS = $(C_SRCS:.c=.o) $(BISON_SRCS:.y=.tab.o) $(LEX_SRCS:.l=.yy.o) $(IDL_GEN_C_SRCS:.c=.o) \ - $(RC_SRCS:.rc=.res) $(MC_SRCS:.mc=.mc.res) $(EXTRA_OBJS) +OBJS = $(C_SRCS:.c=.o) $(BISON_SRCS:.y=.tab.o) $(LEX_SRCS:.l=.yy.o) $(IDL_GEN_C_SRCS:.c=.o) $(RC_SRCS:.rc=.res) $(EXTRA_OBJS) LINTS = $(C_SRCS:.c=.ln) @@ -230,7 +229,7 @@ $(SUBDIRS:%=%/__depend__): dummy @cd `dirname $@` && $(MAKE) depend depend: $(SUBDIRS:%=%/__depend__) dummy - $(MAKEDEP) $(MAKEDEPFLAGS) -C$(SRCDIR) -S$(TOPSRCDIR) -T$(TOPOBJDIR) $(EXTRAINCL) $(DEPEND_SRCS) + $(MAKEDEP) -C$(SRCDIR) -S$(TOPSRCDIR) -T$(TOPOBJDIR) $(EXTRAINCL) $(DEPEND_SRCS) .PHONY: depend $(SUBDIRS:%=%/__depend__) @@ -319,7 +318,7 @@ $(MC_SRCS:.mc=.mc.rc): $(WMC) $(IDL_GEN_HEADERS) $(IDL_GEN_C_SRCS) $(IDL_TLB_SRCS:.idl=.tlb): $(WIDL) -$(RC_SRCS:.rc=.res) $(MC_SRCS:.mc=.mc.res) $(RC_SRCS16:.rc=.res): $(WRC) +$(RC_SRCS:.rc=.res) $(RC_SRCS16:.rc=.res): $(WRC) $(SUBDIRS): dummy @cd $@ && $(MAKE) diff --git a/VERSION b/VERSION index 9ee63cb1018..502a10b9125 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -Wine version 1.1.26 +Wine version 1.1.24 diff --git a/configure b/configure index 5ce51c1390d..d317c6a307c 100755 --- a/configure +++ b/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.61 for Wine 1.1.26. +# Generated by GNU Autoconf 2.61 for Wine 1.1.24. # # Report bugs to . # @@ -574,8 +574,8 @@ SHELL=${CONFIG_SHELL-/bin/sh} # Identity of this package. PACKAGE_NAME='Wine' PACKAGE_TARNAME='wine' -PACKAGE_VERSION='1.1.26' -PACKAGE_STRING='Wine 1.1.26' +PACKAGE_VERSION='1.1.24' +PACKAGE_STRING='Wine 1.1.24' PACKAGE_BUGREPORT='wine-devel@winehq.org' ac_unique_file="server/atom.c" @@ -1301,7 +1301,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures Wine 1.1.26 to adapt to many kinds of systems. +\`configure' configures Wine 1.1.24 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1370,7 +1370,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of Wine 1.1.26:";; + short | recursive ) echo "Configuration of Wine 1.1.24:";; esac cat <<\_ACEOF @@ -1503,7 +1503,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -Wine configure 1.1.26 +Wine configure 1.1.24 generated by GNU Autoconf 2.61 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -1517,7 +1517,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by Wine $as_me 1.1.26, which was +It was created by Wine $as_me 1.1.24, which was generated by GNU Autoconf 2.61. Invocation command line was $ $0 $@ @@ -5595,7 +5595,6 @@ done - for ac_header in \ AudioUnit/AudioUnit.h \ Carbon/Carbon.h \ @@ -5680,7 +5679,6 @@ for ac_header in \ sys/event.h \ sys/exec_elf.h \ sys/filio.h \ - sys/inotify.h \ sys/ioctl.h \ sys/ipc.h \ sys/limits.h \ @@ -7092,7 +7090,7 @@ fi IOKITLIB="-framework IOKit -framework CoreFoundation" - LDEXECFLAGS="-image_base 0x7bf00000 -Wl,-segaddr,WINE_DOS,0x00000000,-segaddr,WINE_SHAREDHEAP,0x7f000000" + LDEXECFLAGS="-image_base 0x7bf00000 -Wl,-segaddr,WINE_DOS,0x00000000,-segaddr,WINE_SHARED_HEAP,0x7f000000" if test "$ac_cv_header_DiskArbitration_DiskArbitration_h" = "yes" then @@ -7214,74 +7212,6 @@ done enable_winequartz_drv=${enable_winequartz_drv:-yes} fi - if test "x$enable_win16" = "xyes" - then - { echo "$as_me:$LINENO: checking whether 16-bit code can be built correctly" >&5 -echo $ECHO_N "checking whether 16-bit code can be built correctly... $ECHO_C" >&6; } - if test "$cross_compiling" = yes; then - { echo "$as_me:$LINENO: result: cross-compiling, assuming yes" >&5 -echo "${ECHO_T}cross-compiling, assuming yes" >&6; } -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -asm(".text\n" - "bad:\tnop;nop\n" - "good:\tnop;nop\n\t" - ".globl _testfunc\n" - "_testfunc:\tcallw good"); - extern void testfunc(); -int -main () -{ -unsigned short *p = (unsigned short *)testfunc; - return p[0] != 0xe866 || p[1] != 0xfffa - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - { echo "$as_me:$LINENO: result: yes" >&5 -echo "${ECHO_T}yes" >&6; } -else - echo "$as_me: program exited with status $ac_status" >&5 -echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -{ echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } - { { echo "$as_me:$LINENO: error: Xcode 3.x cannot build 16-bit code correctly. Use --disable-win16 if you don't need 16-bit support." >&5 -echo "$as_me: error: Xcode 3.x cannot build 16-bit code correctly. Use --disable-win16 if you don't need 16-bit support." >&2;} - { (exit 1); exit 1; }; } -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - - fi ;; *) DLLFLAGS="$DLLFLAGS -fPIC" @@ -8189,21 +8119,8 @@ test -n "$MINGWAR" || MINGWAR="false" then CROSSTEST="\$(CROSSTEST)" - set x $CROSSCC - shift - target="" - while test $# -ge 1 - do - case "$1" in - *-gcc) target=`expr "$1" : '\(.*\)-gcc'` ;; - esac - shift - done - if test -n "$target" - then - CROSSTARGETFLAGS="-b $target" + CROSSTARGETFLAGS="-b `expr $CROSSCC : '\(.*\)-gcc'`" - fi fi fi @@ -11024,7 +10941,8 @@ fi -for ac_header in GL/gl.h GL/glx.h GL/glu.h + +for ac_header in GL/gl.h GL/glx.h GL/glext.h GL/glu.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_header" >&5 @@ -14103,11 +14021,13 @@ fi + for ac_header in ft2build.h \ freetype/freetype.h \ freetype/ftglyph.h \ freetype/fttypes.h \ freetype/tttables.h \ + freetype/ftnames.h \ freetype/ftsnames.h \ freetype/ttnameid.h \ freetype/ftoutln.h \ @@ -17534,16 +17454,6 @@ if test "$ac_cv_c_cfi_support" = "yes" then asm_func_header="$asm_func_header.cfi_startproc\\n\\t" asm_func_trailer="\\n\\t.cfi_endproc$asm_func_trailer" - -cat >>confdefs.h <<\_ACEOF -#define __ASM_CFI(str) str -_ACEOF - -else - cat >>confdefs.h <<\_ACEOF -#define __ASM_CFI(str) "" -_ACEOF - fi asm_func_code="$asm_func_header\" code \"$asm_func_trailer" @@ -17678,7 +17588,6 @@ CFLAGS="$CFLAGS $BUILTINFLAG" - for ac_func in \ _pclose \ _popen \ @@ -17716,7 +17625,6 @@ for ac_func in \ memmove \ mmap \ pclose \ - pipe2 \ poll \ popen \ prctl \ @@ -23263,7 +23171,7 @@ DEPENDENCIES="### Dependencies: .BEGIN: Makefile .MAKEFILEDEPS: Makefile: dummy - -\$(MAKEDEP) \$(MAKEDEPFLAGS) -C\$(SRCDIR) -S\$(TOPSRCDIR) -T\$(TOPOBJDIR) \$(EXTRAINCL) \$(DEPEND_SRCS) + -\$(MAKEDEP) -C\$(SRCDIR) -S\$(TOPSRCDIR) -T\$(TOPOBJDIR) \$(EXTRAINCL) \$(DEPEND_SRCS) \$(OBJS) \$(C_SRCS16:.c=.o): \$(IDL_GEN_HEADERS) \$(IDL_GEN_C_SRCS:.c=.o): \$(IDL_GEN_C_SRCS) @@ -23852,6 +23760,22 @@ dlls/d3drm/tests/Makefile: dlls/d3drm/tests/Makefile.in dlls/Maketest.rules" ac_config_files="$ac_config_files dlls/d3drm/tests/Makefile" ALL_MAKEFILES="$ALL_MAKEFILES \\ + dlls/d3dx8/Makefile" +test "x$enable_d3dx8" != xno && ALL_DLL_DIRS="$ALL_DLL_DIRS \\ + d3dx8" +ALL_MAKEFILE_DEPENDS="$ALL_MAKEFILE_DEPENDS +dlls/d3dx8/Makefile: dlls/d3dx8/Makefile.in dlls/Makedll.rules" +ac_config_files="$ac_config_files dlls/d3dx8/Makefile" + +ALL_MAKEFILES="$ALL_MAKEFILES \\ + dlls/d3dx8/tests/Makefile" +test "x$enable_tests" != xno && ALL_TEST_DIRS="$ALL_TEST_DIRS \\ + d3dx8/tests" +ALL_MAKEFILE_DEPENDS="$ALL_MAKEFILE_DEPENDS +dlls/d3dx8/tests/Makefile: dlls/d3dx8/tests/Makefile.in dlls/Maketest.rules" +ac_config_files="$ac_config_files dlls/d3dx8/tests/Makefile" + +ALL_MAKEFILES="$ALL_MAKEFILES \\ dlls/d3dx9_24/Makefile" test "x$enable_d3dx9_24" != xno && ALL_DLL_DIRS="$ALL_DLL_DIRS \\ d3dx9_24" @@ -24276,14 +24200,6 @@ dlls/dpwsockx/Makefile: dlls/dpwsockx/Makefile.in dlls/Makedll.rules" ac_config_files="$ac_config_files dlls/dpwsockx/Makefile" ALL_MAKEFILES="$ALL_MAKEFILES \\ - dlls/drmclien/Makefile" -test "x$enable_drmclien" != xno && ALL_DLL_DIRS="$ALL_DLL_DIRS \\ - drmclien" -ALL_MAKEFILE_DEPENDS="$ALL_MAKEFILE_DEPENDS -dlls/drmclien/Makefile: dlls/drmclien/Makefile.in dlls/Makedll.rules" -ac_config_files="$ac_config_files dlls/drmclien/Makefile" - -ALL_MAKEFILES="$ALL_MAKEFILES \\ dlls/dsound/Makefile" test "x$enable_dsound" != xno && ALL_DLL_DIRS="$ALL_DLL_DIRS \\ dsound" @@ -25812,14 +25728,6 @@ dlls/rsaenh/tests/Makefile: dlls/rsaenh/tests/Makefile.in dlls/Maketest.rules" ac_config_files="$ac_config_files dlls/rsaenh/tests/Makefile" ALL_MAKEFILES="$ALL_MAKEFILES \\ - dlls/rtutils/Makefile" -test "x$enable_rtutils" != xno && ALL_DLL_DIRS="$ALL_DLL_DIRS \\ - rtutils" -ALL_MAKEFILE_DEPENDS="$ALL_MAKEFILE_DEPENDS -dlls/rtutils/Makefile: dlls/rtutils/Makefile.in dlls/Makedll.rules" -ac_config_files="$ac_config_files dlls/rtutils/Makefile" - -ALL_MAKEFILES="$ALL_MAKEFILES \\ dlls/sane.ds/Makefile" test "x$enable_sane_ds" != xno && ALL_DLL_DIRS="$ALL_DLL_DIRS \\ sane.ds" @@ -26436,14 +26344,6 @@ dlls/windowscodecs/Makefile: dlls/windowscodecs/Makefile.in dlls/Makedll.rules" ac_config_files="$ac_config_files dlls/windowscodecs/Makefile" ALL_MAKEFILES="$ALL_MAKEFILES \\ - dlls/windowscodecs/tests/Makefile" -test "x$enable_tests" != xno && ALL_TEST_DIRS="$ALL_TEST_DIRS \\ - windowscodecs/tests" -ALL_MAKEFILE_DEPENDS="$ALL_MAKEFILE_DEPENDS -dlls/windowscodecs/tests/Makefile: dlls/windowscodecs/tests/Makefile.in dlls/Maketest.rules" -ac_config_files="$ac_config_files dlls/windowscodecs/tests/Makefile" - -ALL_MAKEFILES="$ALL_MAKEFILES \\ dlls/winealsa.drv/Makefile" test "x$enable_winealsa_drv" != xno && ALL_DLL_DIRS="$ALL_DLL_DIRS \\ winealsa.drv" @@ -26724,14 +26624,6 @@ dlls/wmi/Makefile: dlls/wmi/Makefile.in dlls/Makedll.rules" ac_config_files="$ac_config_files dlls/wmi/Makefile" ALL_MAKEFILES="$ALL_MAKEFILES \\ - dlls/wmiutils/Makefile" -test "x$enable_wmiutils" != xno && ALL_DLL_DIRS="$ALL_DLL_DIRS \\ - wmiutils" -ALL_MAKEFILE_DEPENDS="$ALL_MAKEFILE_DEPENDS -dlls/wmiutils/Makefile: dlls/wmiutils/Makefile.in dlls/Makedll.rules" -ac_config_files="$ac_config_files dlls/wmiutils/Makefile" - -ALL_MAKEFILES="$ALL_MAKEFILES \\ dlls/wnaspi32/Makefile" test "x$enable_wnaspi32" != xno && ALL_DLL_DIRS="$ALL_DLL_DIRS \\ wnaspi32" @@ -27437,14 +27329,10 @@ for dir in $ALL_TEST_DIRS do if test "$dir" != "\\" then - testname=`expr $dir : '\(.*\)/tests'`_test + testname=`expr $dir : '\(.*\)/tests'`_test.exe ALL_WINETEST_DEPENDS="$ALL_WINETEST_DEPENDS - -$testname.exe: \$(DLLDIR)/$dir/$testname.exe\$(DLLEXT) - cp \$(DLLDIR)/$dir/$testname.exe\$(DLLEXT) \$@ && \$(STRIP) \$@ -$testname.rc: - echo \"$testname.exe TESTRES \\\"$testname.exe\\\"\" >\$@ || (\$(RM) \$@ && false) -$testname.res: $testname.rc $testname.exe" +$testname: \$(DLLDIR)/$dir/$testname\$(DLLEXT) + cp \$(DLLDIR)/$dir/$testname\$(DLLEXT) \$@ && \$(STRIP) \$@" fi done @@ -27846,7 +27734,7 @@ exec 6>&1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by Wine $as_me 1.1.26, which was +This file was extended by Wine $as_me 1.1.24, which was generated by GNU Autoconf 2.61. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -27899,7 +27787,7 @@ Report bugs to ." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF ac_cs_version="\\ -Wine config.status 1.1.26 +Wine config.status 1.1.24 configured by $0, generated by GNU Autoconf 2.61, with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" @@ -28083,6 +27971,8 @@ do "dlls/d3dim/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3dim/Makefile" ;; "dlls/d3drm/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3drm/Makefile" ;; "dlls/d3drm/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3drm/tests/Makefile" ;; + "dlls/d3dx8/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3dx8/Makefile" ;; + "dlls/d3dx8/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3dx8/tests/Makefile" ;; "dlls/d3dx9_24/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3dx9_24/Makefile" ;; "dlls/d3dx9_25/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3dx9_25/Makefile" ;; "dlls/d3dx9_26/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3dx9_26/Makefile" ;; @@ -28136,7 +28026,6 @@ do "dlls/dpnhpast/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dpnhpast/Makefile" ;; "dlls/dpnlobby/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dpnlobby/Makefile" ;; "dlls/dpwsockx/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dpwsockx/Makefile" ;; - "dlls/drmclien/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/drmclien/Makefile" ;; "dlls/dsound/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dsound/Makefile" ;; "dlls/dsound/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dsound/tests/Makefile" ;; "dlls/dssenh/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dssenh/Makefile" ;; @@ -28328,7 +28217,6 @@ do "dlls/rsabase/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/rsabase/Makefile" ;; "dlls/rsaenh/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/rsaenh/Makefile" ;; "dlls/rsaenh/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/rsaenh/tests/Makefile" ;; - "dlls/rtutils/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/rtutils/Makefile" ;; "dlls/sane.ds/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/sane.ds/Makefile" ;; "dlls/sccbase/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/sccbase/Makefile" ;; "dlls/schannel/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/schannel/Makefile" ;; @@ -28406,7 +28294,6 @@ do "dlls/winaspi.dll16/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winaspi.dll16/Makefile" ;; "dlls/windebug.dll16/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/windebug.dll16/Makefile" ;; "dlls/windowscodecs/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/windowscodecs/Makefile" ;; - "dlls/windowscodecs/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/windowscodecs/tests/Makefile" ;; "dlls/winealsa.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winealsa.drv/Makefile" ;; "dlls/wineaudioio.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wineaudioio.drv/Makefile" ;; "dlls/winecoreaudio.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winecoreaudio.drv/Makefile" ;; @@ -28442,7 +28329,6 @@ do "dlls/wldap32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wldap32/Makefile" ;; "dlls/wldap32/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wldap32/tests/Makefile" ;; "dlls/wmi/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wmi/Makefile" ;; - "dlls/wmiutils/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wmiutils/Makefile" ;; "dlls/wnaspi32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wnaspi32/Makefile" ;; "dlls/wow32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wow32/Makefile" ;; "dlls/ws2_32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/ws2_32/Makefile" ;; diff --git a/configure.ac b/configure.ac index 5cce1b78ebd..3b0e958651c 100644 --- a/configure.ac +++ b/configure.ac @@ -348,7 +348,6 @@ AC_CHECK_HEADERS(\ sys/event.h \ sys/exec_elf.h \ sys/filio.h \ - sys/inotify.h \ sys/ioctl.h \ sys/ipc.h \ sys/limits.h \ @@ -582,7 +581,7 @@ case $host_os in AC_SUBST(SECURITYLIB,"-framework Security -framework CoreFoundation") AC_SUBST(COREFOUNDATIONLIB,"-framework CoreFoundation") AC_SUBST(IOKITLIB,"-framework IOKit -framework CoreFoundation") - AC_SUBST(LDEXECFLAGS,["-image_base 0x7bf00000 -Wl,-segaddr,WINE_DOS,0x00000000,-segaddr,WINE_SHAREDHEAP,0x7f000000"]) + AC_SUBST(LDEXECFLAGS,["-image_base 0x7bf00000 -Wl,-segaddr,WINE_DOS,0x00000000,-segaddr,WINE_SHARED_HEAP,0x7f000000"]) if test "$ac_cv_header_DiskArbitration_DiskArbitration_h" = "yes" then dnl DiskArbitration API is not public on Darwin < 8.0, use it only if header found @@ -611,23 +610,6 @@ case $host_os in AC_SUBST(CARBONLIB,"-framework Carbon") enable_winequartz_drv=${enable_winequartz_drv:-yes} fi - dnl Check for Xcode 3.x broken 16-bit support - if test "x$enable_win16" = "xyes" - then - AC_MSG_CHECKING([whether 16-bit code can be built correctly]) - AC_RUN_IFELSE(AC_LANG_PROGRAM([[asm(".text\n" - "bad:\tnop;nop\n" - "good:\tnop;nop\n\t" - ".globl _testfunc\n" - "_testfunc:\tcallw good"); - extern void testfunc();]], - [[unsigned short *p = (unsigned short *)testfunc; - return p[[0]] != 0xe866 || p[[1]] != 0xfffa]]), - AC_MSG_RESULT(yes), - [AC_MSG_RESULT(no) - AC_MSG_ERROR([Xcode 3.x cannot build 16-bit code correctly. Use --disable-win16 if you don't need 16-bit support.])], - AC_MSG_RESULT([[cross-compiling, assuming yes]])) - fi ;; *) DLLFLAGS="$DLLFLAGS -fPIC" @@ -718,20 +700,7 @@ then if test "$CROSSCC" != "false" then AC_SUBST(CROSSTEST,"\$(CROSSTEST)") - set x $CROSSCC - shift - target="" - while test $# -ge 1 - do - case "$1" in - *-gcc) target=`expr "$1" : '\(.*\)-gcc'` ;; - esac - shift - done - if test -n "$target" - then - AC_SUBST(CROSSTARGETFLAGS,"-b $target") - fi + AC_SUBST(CROSSTARGETFLAGS,"-b `expr $CROSSCC : '\(.*\)-gcc'`") fi fi @@ -882,7 +851,7 @@ then opengl_msg="" if test "x$with_opengl" != "xno" then - AC_CHECK_HEADERS(GL/gl.h GL/glx.h GL/glu.h,,, + AC_CHECK_HEADERS(GL/gl.h GL/glx.h GL/glext.h GL/glu.h,,, [#ifdef HAVE_GL_GLX_H # include #endif]) @@ -1171,6 +1140,7 @@ then freetype/ftglyph.h \ freetype/fttypes.h \ freetype/tttables.h \ + freetype/ftnames.h \ freetype/ftsnames.h \ freetype/ttnameid.h \ freetype/ftoutln.h \ @@ -1538,9 +1508,6 @@ if test "$ac_cv_c_cfi_support" = "yes" then asm_func_header="$asm_func_header.cfi_startproc\\n\\t" asm_func_trailer="\\n\\t.cfi_endproc$asm_func_trailer" - AC_DEFINE([__ASM_CFI(str)],[str],[Define to a macro to output a .cfi assembly pseudo-op]) -else - AC_DEFINE([__ASM_CFI(str)],[""]) fi asm_func_code="$asm_func_header\" code \"$asm_func_trailer" @@ -1629,7 +1596,6 @@ AC_CHECK_FUNCS(\ memmove \ mmap \ pclose \ - pipe2 \ poll \ popen \ prctl \ @@ -1997,7 +1963,7 @@ AC_SUBST(DEPENDENCIES,["### Dependencies: .BEGIN: Makefile .MAKEFILEDEPS: Makefile: dummy - -\$(MAKEDEP) \$(MAKEDEPFLAGS) -C\$(SRCDIR) -S\$(TOPSRCDIR) -T\$(TOPOBJDIR) \$(EXTRAINCL) \$(DEPEND_SRCS) + -\$(MAKEDEP) -C\$(SRCDIR) -S\$(TOPSRCDIR) -T\$(TOPOBJDIR) \$(EXTRAINCL) \$(DEPEND_SRCS) \$(OBJS) \$(C_SRCS16:.c=.o): \$(IDL_GEN_HEADERS) \$(IDL_GEN_C_SRCS:.c=.o): \$(IDL_GEN_C_SRCS) @@ -2097,6 +2063,8 @@ WINE_CONFIG_MAKEFILE([dlls/d3d9/tests/Makefile],[dlls/Maketest.rules],[dlls],[AL WINE_CONFIG_MAKEFILE([dlls/d3dim/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/d3drm/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/d3drm/tests/Makefile],[dlls/Maketest.rules],[dlls],[ALL_TEST_DIRS],[enable_tests]) +WINE_CONFIG_MAKEFILE([dlls/d3dx8/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) +WINE_CONFIG_MAKEFILE([dlls/d3dx8/tests/Makefile],[dlls/Maketest.rules],[dlls],[ALL_TEST_DIRS],[enable_tests]) WINE_CONFIG_MAKEFILE([dlls/d3dx9_24/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/d3dx9_25/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/d3dx9_26/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) @@ -2150,7 +2118,6 @@ WINE_CONFIG_MAKEFILE([dlls/dpnet/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_ WINE_CONFIG_MAKEFILE([dlls/dpnhpast/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/dpnlobby/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/dpwsockx/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) -WINE_CONFIG_MAKEFILE([dlls/drmclien/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/dsound/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/dsound/tests/Makefile],[dlls/Maketest.rules],[dlls],[ALL_TEST_DIRS],[enable_tests]) WINE_CONFIG_MAKEFILE([dlls/dssenh/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) @@ -2342,7 +2309,6 @@ WINE_CONFIG_MAKEFILE([dlls/rpcrt4/tests/Makefile],[dlls/Maketest.rules],[dlls],[ WINE_CONFIG_MAKEFILE([dlls/rsabase/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/rsaenh/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/rsaenh/tests/Makefile],[dlls/Maketest.rules],[dlls],[ALL_TEST_DIRS],[enable_tests]) -WINE_CONFIG_MAKEFILE([dlls/rtutils/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/sane.ds/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/sccbase/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/schannel/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) @@ -2420,7 +2386,6 @@ WINE_CONFIG_MAKEFILE([dlls/win87em.dll16/Makefile],[dlls/Makedll.rules],[dlls],[ WINE_CONFIG_MAKEFILE([dlls/winaspi.dll16/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS],[enable_win16]) WINE_CONFIG_MAKEFILE([dlls/windebug.dll16/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS],[enable_win16]) WINE_CONFIG_MAKEFILE([dlls/windowscodecs/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) -WINE_CONFIG_MAKEFILE([dlls/windowscodecs/tests/Makefile],[dlls/Maketest.rules],[dlls],[ALL_TEST_DIRS],[enable_tests]) WINE_CONFIG_MAKEFILE([dlls/winealsa.drv/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/wineaudioio.drv/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/winecoreaudio.drv/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) @@ -2456,7 +2421,6 @@ WINE_CONFIG_MAKEFILE([dlls/wintrust/tests/Makefile],[dlls/Maketest.rules],[dlls] WINE_CONFIG_MAKEFILE([dlls/wldap32/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/wldap32/tests/Makefile],[dlls/Maketest.rules],[dlls],[ALL_TEST_DIRS],[enable_tests]) WINE_CONFIG_MAKEFILE([dlls/wmi/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) -WINE_CONFIG_MAKEFILE([dlls/wmiutils/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/wnaspi32/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/wow32/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) WINE_CONFIG_MAKEFILE([dlls/ws2_32/Makefile],[dlls/Makedll.rules],[dlls],[ALL_DLL_DIRS]) @@ -2546,14 +2510,10 @@ for dir in $ALL_TEST_DIRS do if test "$dir" != "\\" then - testname=`expr $dir : '\(.*\)/tests'`_test + testname=`expr $dir : '\(.*\)/tests'`_test.exe ALL_WINETEST_DEPENDS="$ALL_WINETEST_DEPENDS - -$testname.exe: \$(DLLDIR)/$dir/$testname.exe\$(DLLEXT) - cp \$(DLLDIR)/$dir/$testname.exe\$(DLLEXT) \$@ && \$(STRIP) \$@ -$testname.rc: - echo \"$testname.exe TESTRES \\\"$testname.exe\\\"\" >\$@ || (\$(RM) \$@ && false) -$testname.res: $testname.rc $testname.exe" +$testname: \$(DLLDIR)/$dir/$testname\$(DLLEXT) + cp \$(DLLDIR)/$dir/$testname\$(DLLEXT) \$@ && \$(STRIP) \$@" fi done diff --git a/dlls/Makefile.in b/dlls/Makefile.in index 8f2a9779bcc..b600c3ac83b 100644 --- a/dlls/Makefile.in +++ b/dlls/Makefile.in @@ -116,6 +116,7 @@ IMPORT_LIBS = \ d3d9/libd3d9.$(IMPLIBEXT) \ d3dim/libd3dim.$(IMPLIBEXT) \ d3drm/libd3drm.$(IMPLIBEXT) \ + d3dx8/libd3dx8.$(IMPLIBEXT) \ d3dx9_36/libd3dx9.$(IMPLIBEXT) \ d3dxof/libd3dxof.$(IMPLIBEXT) \ dbghelp/libdbghelp.$(IMPLIBEXT) \ @@ -187,7 +188,6 @@ IMPORT_LIBS = \ riched20/libriched20.$(IMPLIBEXT) \ rpcrt4/librpcrt4.$(IMPLIBEXT) \ rsaenh/librsaenh.$(IMPLIBEXT) \ - rtutils/librtutils.$(IMPLIBEXT) \ secur32/libsecur32.$(IMPLIBEXT) \ sensapi/libsensapi.$(IMPLIBEXT) \ serialui/libserialui.$(IMPLIBEXT) \ @@ -212,7 +212,6 @@ IMPORT_LIBS = \ uxtheme/libuxtheme.$(IMPLIBEXT) \ vdmdbg/libvdmdbg.$(IMPLIBEXT) \ version/libversion.$(IMPLIBEXT) \ - windowscodecs/libwindowscodecs.$(IMPLIBEXT) \ wined3d/libwined3d.$(IMPLIBEXT) \ winhttp/libwinhttp.$(IMPLIBEXT) \ wininet/libwininet.$(IMPLIBEXT) \ @@ -262,6 +261,7 @@ CROSS_IMPLIBS = \ d3d9/libd3d9.a \ d3dim/libd3dim.a \ d3drm/libd3drm.a \ + d3dx8/libd3dx8.a \ d3dx9_36/libd3dx9.a \ d3dxof/libd3dxof.a \ dbghelp/libdbghelp.a \ @@ -331,7 +331,6 @@ CROSS_IMPLIBS = \ riched20/libriched20.a \ rpcrt4/librpcrt4.a \ rsaenh/librsaenh.a \ - rtutils/librtutils.a \ secur32/libsecur32.a \ sensapi/libsensapi.a \ serialui/libserialui.a \ @@ -356,7 +355,6 @@ CROSS_IMPLIBS = \ uxtheme/libuxtheme.a \ vdmdbg/libvdmdbg.a \ version/libversion.a \ - windowscodecs/libwindowscodecs.a \ wined3d/libwined3d.a \ winhttp/libwinhttp.a \ wininet/libwininet.a \ @@ -466,6 +464,9 @@ d3dim/libd3dim.def d3dim/libd3dim.a: d3dim/d3dim.spec $(WINEBUILD) d3drm/libd3drm.def d3drm/libd3drm.a: d3drm/d3drm.spec $(WINEBUILD) @cd d3drm && $(MAKE) `basename $@` +d3dx8/libd3dx8.def d3dx8/libd3dx8.a: d3dx8/d3dx8.spec $(WINEBUILD) + @cd d3dx8 && $(MAKE) `basename $@` + d3dx9_36/libd3dx9.def d3dx9_36/libd3dx9.a: d3dx9_36/d3dx9_36.spec $(WINEBUILD) @cd d3dx9_36 && $(MAKE) `basename $@` @@ -679,9 +680,6 @@ rpcrt4/librpcrt4.def rpcrt4/librpcrt4.a: rpcrt4/rpcrt4.spec $(WINEBUILD) rsaenh/librsaenh.def rsaenh/librsaenh.a: rsaenh/rsaenh.spec $(WINEBUILD) @cd rsaenh && $(MAKE) `basename $@` -rtutils/librtutils.def rtutils/librtutils.a: rtutils/rtutils.spec $(WINEBUILD) - @cd rtutils && $(MAKE) `basename $@` - secur32/libsecur32.def secur32/libsecur32.a: secur32/secur32.spec $(WINEBUILD) @cd secur32 && $(MAKE) `basename $@` @@ -754,9 +752,6 @@ vdmdbg/libvdmdbg.def vdmdbg/libvdmdbg.a: vdmdbg/vdmdbg.spec $(WINEBUILD) version/libversion.def version/libversion.a: version/version.spec $(WINEBUILD) @cd version && $(MAKE) `basename $@` -windowscodecs/libwindowscodecs.def windowscodecs/libwindowscodecs.a: windowscodecs/windowscodecs.spec $(WINEBUILD) - @cd windowscodecs && $(MAKE) `basename $@` - wined3d/libwined3d.def wined3d/libwined3d.a: wined3d/wined3d.spec $(WINEBUILD) @cd wined3d && $(MAKE) `basename $@` diff --git a/dlls/Maketest.rules.in b/dlls/Maketest.rules.in index aff002c66a6..b112c452b6b 100644 --- a/dlls/Maketest.rules.in +++ b/dlls/Maketest.rules.in @@ -24,7 +24,6 @@ EXTRA_OBJS = testlist.o CROSSTEST = $(TESTDLL:%.dll=%)_crosstest.exe CROSSCC = @CROSSCC@ CROSSWINEGCC = $(TOOLSDIR)/tools/winegcc/winegcc @CROSSTARGETFLAGS@ -B$(TOOLSDIR)/tools/winebuild --sysroot=$(TOPOBJDIR) -MAKEDEPFLAGS = -xo -xcross.o @MAKE_RULES@ diff --git a/dlls/advapi32/advapi32.spec b/dlls/advapi32/advapi32.spec index e9168aa7c39..d641efdbf2c 100644 --- a/dlls/advapi32/advapi32.spec +++ b/dlls/advapi32/advapi32.spec @@ -98,8 +98,8 @@ @ stdcall CreateProcessAsUserW(long str str ptr ptr long long ptr str ptr ptr) @ stdcall CreateProcessWithLogonW(wstr wstr wstr long wstr wstr long ptr wstr ptr ptr) @ stdcall CreateRestrictedToken(long long long ptr long ptr long ptr ptr) -@ stdcall CreateServiceA(long str str long long long long str str ptr str str str) -@ stdcall CreateServiceW(long wstr wstr long long long long wstr wstr ptr wstr wstr wstr) +@ stdcall CreateServiceA(long ptr ptr long long long long ptr ptr ptr ptr ptr ptr) +@ stdcall CreateServiceW (long ptr ptr long long long long ptr ptr ptr ptr ptr ptr) # @ stub CreateTraceInstanceId @ stdcall CreateWellKnownSid(long ptr ptr ptr) @ stdcall CredDeleteA(str long long) diff --git a/dlls/advapi32/registry.c b/dlls/advapi32/registry.c index 3762908aff1..52de6c5d427 100644 --- a/dlls/advapi32/registry.c +++ b/dlls/advapi32/registry.c @@ -381,9 +381,6 @@ LSTATUS WINAPI RegOpenKeyExA( HKEY hkey, LPCSTR name, DWORD reserved, REGSAM acc */ LSTATUS WINAPI RegOpenKeyW( HKEY hkey, LPCWSTR name, PHKEY retkey ) { - if (!retkey) - return ERROR_INVALID_PARAMETER; - if (!name || !*name) { *retkey = hkey; @@ -405,13 +402,10 @@ LSTATUS WINAPI RegOpenKeyW( HKEY hkey, LPCWSTR name, PHKEY retkey ) * * RETURNS * Success: ERROR_SUCCESS - * Failure: A standard Win32 error code. When retkey is valid, *retkey is set to 0. + * Failure: A standard Win32 error code. retkey is set to 0. */ LSTATUS WINAPI RegOpenKeyA( HKEY hkey, LPCSTR name, PHKEY retkey ) { - if (!retkey) - return ERROR_INVALID_PARAMETER; - if (!name || !*name) { *retkey = hkey; diff --git a/dlls/advapi32/security.c b/dlls/advapi32/security.c index e1cbb1a62f9..773a839104b 100644 --- a/dlls/advapi32/security.c +++ b/dlls/advapi32/security.c @@ -1073,7 +1073,6 @@ GetSidIdentifierAuthority( PSID pSid ) PDWORD WINAPI GetSidSubAuthority( PSID pSid, DWORD nSubAuthority ) { - SetLastError(ERROR_SUCCESS); return RtlSubAuthoritySid(pSid, nSubAuthority); } @@ -1086,7 +1085,6 @@ GetSidSubAuthority( PSID pSid, DWORD nSubAuthority ) PUCHAR WINAPI GetSidSubAuthorityCount (PSID pSid) { - SetLastError(ERROR_SUCCESS); return RtlSubAuthorityCountSid(pSid); } diff --git a/dlls/advapi32/tests/registry.c b/dlls/advapi32/tests/registry.c index 71317c4bd9b..47e76b28634 100644 --- a/dlls/advapi32/tests/registry.c +++ b/dlls/advapi32/tests/registry.c @@ -959,12 +959,6 @@ static void test_reg_open_key(void) ret = RegOpenKeyA(HKEY_CURRENT_USER, "Software\\Wine\\Test", NULL); ok(ret == ERROR_INVALID_PARAMETER, "expected ERROR_INVALID_PARAMETER, got %d\n", ret); - ret = RegOpenKeyA(HKEY_CURRENT_USER, NULL, NULL); - ok(ret == ERROR_INVALID_PARAMETER, "expected ERROR_INVALID_PARAMETER, got %d\n", ret); - - ret = RegOpenKeyA(NULL, NULL, NULL); - ok(ret == ERROR_INVALID_PARAMETER, "expected ERROR_INVALID_PARAMETER, got %d\n", ret); - /* beginning backslash character */ ret = RegOpenKeyA(HKEY_CURRENT_USER, "\\Software\\Wine\\Test", &hkResult); ok(ret == ERROR_BAD_PATHNAME || /* NT/2k/XP */ diff --git a/dlls/advapi32/tests/security.c b/dlls/advapi32/tests/security.c index 4479ddfca8b..af52a3acf05 100644 --- a/dlls/advapi32/tests/security.c +++ b/dlls/advapi32/tests/security.c @@ -92,9 +92,6 @@ typedef BOOL (WINAPI *fnSetFileSecurityA)(LPCSTR, SECURITY_INFORMATION, static DWORD (WINAPI *pGetNamedSecurityInfoA)(LPSTR, SE_OBJECT_TYPE, SECURITY_INFORMATION, PSID*, PSID*, PACL*, PACL*, PSECURITY_DESCRIPTOR*); -static PDWORD (WINAPI *pGetSidSubAuthority)(PSID, DWORD); -static PUCHAR (WINAPI *pGetSidSubAuthorityCount)(PSID); -static BOOL (WINAPI *pIsValidSid)(PSID); typedef DWORD (WINAPI *fnRtlAdjustPrivilege)(ULONG,BOOLEAN,BOOLEAN,PBOOLEAN); typedef BOOL (WINAPI *fnCreateWellKnownSid)(WELL_KNOWN_SID_TYPE,PSID,PSID,DWORD*); typedef BOOL (WINAPI *fnDuplicateTokenEx)(HANDLE,DWORD,LPSECURITY_ATTRIBUTES, @@ -163,9 +160,6 @@ static void init(void) pSetFileSecurityA = (fnSetFileSecurityA)GetProcAddress(hmod, "SetFileSecurityA" ); pCreateWellKnownSid = (fnCreateWellKnownSid)GetProcAddress( hmod, "CreateWellKnownSid" ); pGetNamedSecurityInfoA = (void *)GetProcAddress(hmod, "GetNamedSecurityInfoA"); - pGetSidSubAuthority = (void *)GetProcAddress(hmod, "GetSidSubAuthority"); - pGetSidSubAuthorityCount = (void *)GetProcAddress(hmod, "GetSidSubAuthorityCount"); - pIsValidSid = (void *)GetProcAddress(hmod, "IsValidSid"); pMakeSelfRelativeSD = (void *)GetProcAddress(hmod, "MakeSelfRelativeSD"); pSetEntriesInAclW = (void *)GetProcAddress(hmod, "SetEntriesInAclW"); pSetSecurityDescriptorControl = (void *)GetProcAddress(hmod, "SetSecurityDescriptorControl"); @@ -3182,34 +3176,6 @@ static void test_GetSecurityInfo(void) CloseHandle(obj); } -static void test_GetSidSubAuthority(void) -{ - PSID psid = NULL; - - if (!pGetSidSubAuthority || !pConvertStringSidToSidA || !pIsValidSid || !pGetSidSubAuthorityCount) - { - win_skip("Some functions not available\n"); - return; - } - /* Note: on windows passing in an invalid index like -1, lets GetSidSubAuthority return 0x05000000 but - still GetLastError returns ERROR_SUCCESS then. We don't test these unlikely cornercases here for now */ - ok(pConvertStringSidToSidA("S-1-5-21-93476-23408-4576",&psid),"ConvertStringSidToSidA failed\n"); - ok(pIsValidSid(psid),"Sid is not valid\n"); - SetLastError(0xbebecaca); - ok(*pGetSidSubAuthorityCount(psid) == 4,"GetSidSubAuthorityCount gave %d expected 4\n",*pGetSidSubAuthorityCount(psid)); - ok(GetLastError() == 0,"GetLastError returned %d instead of 0\n",GetLastError()); - SetLastError(0xbebecaca); - ok(*pGetSidSubAuthority(psid,0) == 21,"GetSidSubAuthority gave %d expected 21\n",*pGetSidSubAuthority(psid,0)); - ok(GetLastError() == 0,"GetLastError returned %d instead of 0\n",GetLastError()); - SetLastError(0xbebecaca); - ok(*pGetSidSubAuthority(psid,1) == 93476,"GetSidSubAuthority gave %d expected 93476\n",*pGetSidSubAuthority(psid,1)); - ok(GetLastError() == 0,"GetLastError returned %d instead of 0\n",GetLastError()); - SetLastError(0xbebecaca); - todo_wine ok(*pGetSidSubAuthority(psid,4) == 0,"GetSidSubAuthority gave %d,expected 0\n",*pGetSidSubAuthority(psid,4)); - ok(GetLastError() == 0,"GetLastError returned %d instead of 0\n",GetLastError()); - LocalFree(psid); -} - START_TEST(security) { init(); @@ -3239,5 +3205,4 @@ START_TEST(security) test_PrivateObjectSecurity(); test_acls(); test_GetSecurityInfo(); - test_GetSidSubAuthority(); } diff --git a/dlls/advapi32/tests/service.c b/dlls/advapi32/tests/service.c index 0851384b70b..b924c69d3d4 100644 --- a/dlls/advapi32/tests/service.c +++ b/dlls/advapi32/tests/service.c @@ -28,7 +28,6 @@ #include "winsvc.h" #include "winnls.h" #include "lmcons.h" -#include "aclapi.h" #include "wine/test.h" @@ -38,8 +37,6 @@ static BOOL (WINAPI *pChangeServiceConfig2A)(SC_HANDLE,DWORD,LPVOID); static BOOL (WINAPI *pEnumServicesStatusExA)(SC_HANDLE, SC_ENUM_TYPE, DWORD, DWORD, LPBYTE, DWORD, LPDWORD, LPDWORD, LPDWORD, LPCSTR); -static DWORD (WINAPI *pGetSecurityInfo)(HANDLE, SE_OBJECT_TYPE, SECURITY_INFORMATION, - PSID*, PSID*, PACL*, PACL*, PSECURITY_DESCRIPTOR*); static BOOL (WINAPI *pQueryServiceConfig2A)(SC_HANDLE,DWORD,LPBYTE,DWORD,LPDWORD); static BOOL (WINAPI *pQueryServiceConfig2W)(SC_HANDLE,DWORD,LPBYTE,DWORD,LPDWORD); static BOOL (WINAPI *pQueryServiceStatusEx)(SC_HANDLE, SC_STATUS_TYPE, LPBYTE, @@ -51,7 +48,6 @@ static void init_function_pointers(void) pChangeServiceConfig2A = (void*)GetProcAddress(hadvapi32, "ChangeServiceConfig2A"); pEnumServicesStatusExA= (void*)GetProcAddress(hadvapi32, "EnumServicesStatusExA"); - pGetSecurityInfo = (void *)GetProcAddress(hadvapi32, "GetSecurityInfo"); pQueryServiceConfig2A= (void*)GetProcAddress(hadvapi32, "QueryServiceConfig2A"); pQueryServiceConfig2W= (void*)GetProcAddress(hadvapi32, "QueryServiceConfig2W"); pQueryServiceStatusEx= (void*)GetProcAddress(hadvapi32, "QueryServiceStatusEx"); @@ -1747,17 +1743,7 @@ static void test_sequence(void) return; } else - { ok(svc_handle != NULL, "Could not create the service : %d\n", GetLastError()); - if ((svc_handle != NULL) && (pGetSecurityInfo != NULL)) - { - PSID sidOwner, sidGroup; - PACL dacl, sacl; - PSECURITY_DESCRIPTOR pSD; - HRESULT retval = pGetSecurityInfo(svc_handle,SE_SERVICE,DACL_SECURITY_INFORMATION,&sidOwner,&sidGroup,&dacl,&sacl,&pSD); - todo_wine ok(ERROR_SUCCESS == retval, "Expected GetSecurityInfo to succeed: result %d\n",retval); - } - } if (!svc_handle) return; diff --git a/dlls/appwiz.cpl/De.rc b/dlls/appwiz.cpl/De.rc index c266d8f2810..b85d43ec1e6 100644 --- a/dlls/appwiz.cpl/De.rc +++ b/dlls/appwiz.cpl/De.rc @@ -19,8 +19,6 @@ * */ -#include "res.h" - #pragma code_page(65001) LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL @@ -28,7 +26,7 @@ LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE { IDS_CPL_TITLE, "Software" - IDS_CPL_DESC, "Erlaubt ihnen neue Software hinzuzufügen oder zu entfernen." + IDS_CPL_DESC, "Erlaubt ihnen neue Software hinzuzufügen, oder vorhandene zu entfernen." IDS_TAB1_TITLE, "Anwendungen" IDS_UNINSTALL_FAILED, "Der Uninstaller konnte nicht gestartet werden, '%s'. Möchten Sie den Uninstall-Eintrag für dieses Programm aus der Registrierung entfernen?" @@ -37,10 +35,6 @@ STRINGTABLE IDS_COLUMN_NAME, "Name" IDS_COLUMN_PUBLISHER, "Herausgeber" IDS_COLUMN_VERSION, "Version" - IDS_INSTALL_FILTER, "Setup-Programme\0*instal*.exe;*setup*.exe;*.msi\0Programme (*.exe)\0*.exe\0Alle Dateien (*.*)\0*.*\0\0" - - IDS_REMOVE, "&Entfernen..." - IDS_MODIFY_REMOVE, "Än&dern/Entfernen..." } IDD_MAIN DIALOG 0, 0, 320, 220 @@ -54,10 +48,8 @@ FONT 8, "MS Shell Dlg" CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 CONTROL "Folgende Programme können automatisch entfernt werden. Um ein Programm zu entfernen oder um installierte Komponenten zu ändern, wählen Sie es aus der Liste aus und klicken Sie auf Ändern/Entfernen.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "&Informationen...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 104, 198, 64, 14 - CONTROL "Än&dern...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "&Entfernen...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 - + CONTROL "Än&dern/Entfernen...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 230, 198, 80, 14 + CONTROL "&Informationen...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 160, 198, 64, 14 CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 } @@ -85,3 +77,5 @@ FONT 8, "MS Shell Dlg" CONTROL "", IDC_INFO_UPDATES, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 90, 136, 8 CONTROL "", IDC_INFO_COMMENTS, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 100, 136, 8 } + +#pragma code_page(default) diff --git a/dlls/appwiz.cpl/En.rc b/dlls/appwiz.cpl/En.rc index 4f775aa86f2..d0b4de3ce6a 100644 --- a/dlls/appwiz.cpl/En.rc +++ b/dlls/appwiz.cpl/En.rc @@ -19,8 +19,6 @@ * */ -#include "res.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE @@ -35,10 +33,6 @@ STRINGTABLE IDS_COLUMN_NAME, "Name" IDS_COLUMN_PUBLISHER, "Publisher" IDS_COLUMN_VERSION, "Version" - IDS_INSTALL_FILTER, "Installation Programs\0*instal*.exe;*setup*.exe;*.msi\0Programs (*.exe)\0*.exe\0All Files (*.*)\0*.*\0\0" - - IDS_REMOVE, "&Remove..." - IDS_MODIFY_REMOVE, "&Modify/Remove..." } IDD_MAIN DIALOG 0, 0, 320, 220 @@ -50,11 +44,10 @@ FONT 8, "MS Shell Dlg" CONTROL "&Install...", IDC_INSTALL, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 26, 64, 14 CONTROL "", -1, "STATIC", SS_LEFT | SS_SUNKEN | WS_CHILD | WS_VISIBLE, 7, 46, 303, 1 CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 - CONTROL "The following software can be automatically removed. To remove a program or to modify its installed components, select it from the list and click Change/Remove.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 + CONTROL "The following software can be automatically removed. To remove a program or to modify its installed components, select it from the list and click Add/Remove.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "&Support Info...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 104, 198, 64, 14 - CONTROL "&Modify...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "&Remove...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 + CONTROL "Add/&Remove...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 198, 64, 14 + CONTROL "&Support Info...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 176, 198, 64, 14 CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 } diff --git a/dlls/appwiz.cpl/Fr.rc b/dlls/appwiz.cpl/Fr.rc index e8e67e55804..8dbdff14119 100644 --- a/dlls/appwiz.cpl/Fr.rc +++ b/dlls/appwiz.cpl/Fr.rc @@ -1,5 +1,5 @@ /* -* Ressources françaises pour Ajout/Suppression de programmes +* Ajoute/Supprime des programmes resources francaises * * Copyright 2008 David Adam * @@ -19,63 +19,53 @@ * */ -#include "res.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE { - IDS_CPL_TITLE, "Ajout/Suppression de programmes" - IDS_CPL_DESC, "Vous permet d'installer un nouveau logiciel, ou supprimer un logiciel existant de votre ordinateur." + IDS_CPL_TITLE, "Ajouter/Supprimer des programmes" + IDS_CPL_DESC, "Vous autorise à installer un nouveau logiciel, ou supprimer un logiciel existant de votre ordinateur." IDS_TAB1_TITLE, "Applications" - IDS_UNINSTALL_FAILED, "Impossible d'exécuter le désinstalleur « %s ». Voulez-vous supprimer l'entrée de désinstallation de ce programme de la base de registre ?" - IDS_NOT_SPECIFIED, "Non spécifié" + IDS_UNINSTALL_FAILED, "Incapable d'exécuter le désinstalleur, '%s'. Voulez-vous supprimer l'entrée de ce programme du registre?" + IDS_NOT_SPECIFIED, "Non spécifié" IDS_COLUMN_NAME, "Nom" - IDS_COLUMN_PUBLISHER, "Éditeur" + IDS_COLUMN_PUBLISHER, "Editeur" IDS_COLUMN_VERSION, "Version" - IDS_INSTALL_FILTER, "Programmes d'installation\0*instal*.exe;*setup*.exe;*.msi\0Programmes (*.exe)\0*.exe\0Tous les fichiers (*.*)\0*.*\0\0" - - IDS_REMOVE, "&Supprimer..." - IDS_MODIFY_REMOVE, "&Modifier/Supprimer..." } IDD_MAIN DIALOG 0, 0, 320, 220 STYLE DS_MODALFRAME | DS_3DLOOK | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Installation/Désinstallation" +CAPTION "Installation/Désinstallation" FONT 8, "MS Shell Dlg" { -CONTROL "Pour installer un nouveau programme à partir d'une disquette, d'un CD-ROM ou d'un disque dur, cliquez sur Installer.", 1000, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 7, 270, 20 - CONTROL "&Installer...", IDC_INSTALL, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 242, 26, 68, 14 +CONTROL "Pour installer un nouveau programme à partir d'une disquette, d'un cdrom ou de votre disque dur, cliquer sur Installer.", 1000, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 7, 270, 20 + CONTROL "&Installer", IDC_INSTALL, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 26, 64, 14 CONTROL "", -1, "STATIC", SS_LEFT | SS_SUNKEN | WS_CHILD | WS_VISIBLE, 7, 46, 303, 1 CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 - CONTROL "Les logiciels suivants peuvent être désinstallés automatiquement.\nPour supprimer un programme ou modifier ses composants, sélectionnez-le dans la liste et cliquez sur Supprimer ou Modifier respectivement.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 + CONTROL "Les logiciels suivants peuvent être automatiquement désinstallés. Pour supprimer un programme ou modifier ses composants, le sélectionner dans la liste, et cliquer sur Ajouter/Supprimer.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "Inf&ormations de support...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 73, 198, 95, 14 - CONTROL "&Modifier...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "&Supprimer...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 + CONTROL "Ajouter/&Supprimer", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 198, 64, 14 + CONTROL "&Info. support", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 176, 198, 64, 14 CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 } IDD_INFO DIALOG 0, 0, 256, 138 STYLE DS_MODALFRAME | DS_3DLOOK | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Informations de support" +CAPTION "Information pour support" FONT 8, "MS Shell Dlg" { CONTROL "OK", IDOK, "BUTTON", BS_DEFPUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 103, 116, 50, 14 - CONTROL "Les informations suivantes peuvent être utilisées pour obtenir du support technique pour %s :", IDC_INFO_LABEL, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 12, 9, 228, 19 - CONTROL "Éditeur :", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 30, 54, 8 - CONTROL "Version :", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 40, 54, 8 - CONTROL "Contact :", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 50, 54, 8 - CONTROL "Support :", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 60, 54, 8 - CONTROL "Téléphone :", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 70, 54, 8 - CONTROL "Lisez-moi :", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 80, 54, 8 - CONTROL "Mises à jour :", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 90, 54, 8 - CONTROL "Commentaires :", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 100, 54, 8 + CONTROL "Les informations suivantes peuvent être utilisées pour obtenir un support technique pour %s:", IDC_INFO_LABEL, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 12, 9, 228, 19 + CONTROL "Editeur:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 30, 60, 8 + CONTROL "Version:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 40, 60, 8 + CONTROL "Contact:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 50, 60, 8 + CONTROL "Support Information:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 60, 64, 8 + CONTROL "Support Telephone:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 70, 68, 8 + CONTROL "Lisez-moi:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 80, 60, 8 + CONTROL "Mise à jour des produits:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 90, 60, 8 + CONTROL "Commentaires:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 100, 60, 8 CONTROL "", IDC_INFO_PUBLISHER, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 30, 136, 8 CONTROL "", IDC_INFO_VERSION, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 40, 136, 8 CONTROL "", IDC_INFO_CONTACT, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 50, 136, 8 diff --git a/dlls/appwiz.cpl/Ja.rc b/dlls/appwiz.cpl/Ja.rc index f4e45d092e5..0dd3fdd21f6 100644 --- a/dlls/appwiz.cpl/Ja.rc +++ b/dlls/appwiz.cpl/Ja.rc @@ -19,8 +19,6 @@ * */ -#include "res.h" - /* UTF-8 */ #pragma code_page(65001) @@ -38,9 +36,6 @@ STRINGTABLE IDS_COLUMN_NAME, "名前" IDS_COLUMN_PUBLISHER, "発行元" IDS_COLUMN_VERSION, "バージョン" - - IDS_REMOVE, "&Remove..." - IDS_MODIFY_REMOVE, "&Modify/Remove..." } IDD_MAIN DIALOG 0, 0, 320, 220 @@ -54,9 +49,8 @@ FONT 9, "MS Shell Dlg" CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 CONTROL "以下のソフトウェアを自動的に削除できます。プログラムを削除またはインストールされたコンポーネントを変更するには、リストからプログラムを選択し [追加と削除] をクリックしてください。", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "サポート情報(&S)...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 104, 198, 64, 14 - CONTROL "&Modify...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "&Remove...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 + CONTROL "追加と削除(&R)...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 198, 64, 14 + CONTROL "サポート情報(&S)...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 176, 198, 64, 14 CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 } @@ -84,3 +78,5 @@ FONT 9, "MS Shell Dlg" CONTROL "", IDC_INFO_UPDATES, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 90, 136, 8 CONTROL "", IDC_INFO_COMMENTS, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 100, 136, 8 } + +#pragma code_page(default) diff --git a/dlls/appwiz.cpl/Ko.rc b/dlls/appwiz.cpl/Ko.rc index 19076e0f528..f74a7700dd3 100644 --- a/dlls/appwiz.cpl/Ko.rc +++ b/dlls/appwiz.cpl/Ko.rc @@ -20,8 +20,6 @@ * */ -#include "res.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE @@ -35,10 +33,6 @@ STRINGTABLE IDS_COLUMN_NAME, "À̸§" IDS_COLUMN_PUBLISHER, "Á¦ÀÛ»ç" IDS_COLUMN_VERSION, "¹öÁ¯" - IDS_INSTALL_FILTER, "¼³Ä¡ ÇÁ·Î±×·¥0*instal*.exe;*setup*.exe;*.msi\0ÇÁ·Î±×·¥ (*.exe)\0*.exe\0¸ðµç ÆÄÀϵé (*.*)\0*.*\0\0" - - IDS_REMOVE, "&Remove..." - IDS_MODIFY_REMOVE, "&Modify/Remove..." } IDD_MAIN DIALOG 0, 0, 320, 220 @@ -52,9 +46,8 @@ FONT 9, "MS Shell Dlg" CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 CONTROL "ÀÌ ¼ÒÇÁÆ®¿þ¾î´Â ÀÚµ¿À¸·Î »èÁ¦µÇ¾úÀ» ¼öµµ ÀÖ½À´Ï´Ù.¼³Ä¡µÈ ±¸¼º¿ä¼Ò¸¦ °íÄ¡°Å³ª ÇÁ·Î±×·¥À» Áö¿ì·Á¸é , Ãß°¡/»èÁ¦ ¸ñ·Ï¿¡¼­ ¼±ÅÃÇϽʽÿÀ..", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 36 CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "Áö¿ø Á¤º¸(&S)...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 104, 198, 64, 14 - CONTROL "&Modify...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "&Remove...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 + CONTROL "Ãß°¡/»èÁ¦(&R)..", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 198, 64, 14 + CONTROL "Áö¿ø Á¤º¸(&S)...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 176, 198, 64, 14 CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 } diff --git a/dlls/appwiz.cpl/Lt.rc b/dlls/appwiz.cpl/Lt.rc index 88f491e17fe..6f524ac519c 100644 --- a/dlls/appwiz.cpl/Lt.rc +++ b/dlls/appwiz.cpl/Lt.rc @@ -19,8 +19,6 @@ * */ -#include "res.h" - /* UTF-8 */ #pragma code_page(65001) @@ -32,16 +30,12 @@ STRINGTABLE IDS_CPL_DESC, "Leidžia įdiegti naują programinę įrangą, ar pašalinti jau įdiegtą iš jūsų kompiuterio." IDS_TAB1_TITLE, "Programos" - IDS_UNINSTALL_FAILED, "Nepavyko įvykdyti programos pašalinimo komandos „%s“. Ar norite pašalinti programos šalinimo įrašą iš registro?" + IDS_UNINSTALL_FAILED, "Nepavyko įvykdyti programos pašalinimo komandos '%s'. Ar norite pašalinti programos šalinimo įrašą iš registro?" IDS_NOT_SPECIFIED, "Nenurodyta" IDS_COLUMN_NAME, "Vardas" IDS_COLUMN_PUBLISHER, "Leidėjas" IDS_COLUMN_VERSION, "Versija" - IDS_INSTALL_FILTER, "Diegimo programos\0*instal*.exe;*setup*.exe;*.msi\0Programos (*.exe)\0*.exe\0Visi failai (*.*)\0*.*\0\0" - - IDS_REMOVE, "Pa&šalinti..." - IDS_MODIFY_REMOVE, "Pa&keisti/pašalinti..." } IDD_MAIN DIALOG 0, 0, 320, 220 @@ -49,15 +43,14 @@ STYLE DS_MODALFRAME | DS_3DLOOK | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMEN CAPTION "Įdiegti/Pašalinti" FONT 8, "MS Shell Dlg" { - CONTROL "Norėdami įdiegti naują programą iš diskelio, kompaktinio disko ar standžiojo disko spauskite „Įdiegti“.", 1000, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 7, 270, 20 + CONTROL "Norėdami įdiegti naują programą iš diskelio, kompaktinio disko ar standžiojo disko spauskite 'Įdiegti'.", 1000, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 7, 270, 20 CONTROL "Į&diegti...", IDC_INSTALL, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 26, 64, 14 CONTROL "", -1, "STATIC", SS_LEFT | SS_SUNKEN | WS_CHILD | WS_VISIBLE, 7, 46, 303, 1 CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 - CONTROL "Ši programinė įranga gali būti automatiškai pašalinta. Norėdami pašalinti programą ar modifikuoti jos įdiegtus komponentus pažymėkite ją sąraše ir spauskite „Pakeisti/pašalinti“.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 + CONTROL "Ši programinė įranga gali būti automatiškai pašalinta. Norėdami pašalinti programą ar modifikuoti jos įdiegtus komponentus pažymėkite ją sąraše ir spauskite 'Įdiegti/Pašalinti'.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "&Priežiūros informacija...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 84, 198, 84, 14 - CONTROL "Pa&keisti...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "Pa&šalinti...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 + CONTROL "Įdiegti/Pa&šalinti...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 198, 64, 14 + CONTROL "&Priežiūros informacija...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 156, 198, 84, 14 CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 } @@ -67,7 +60,7 @@ CAPTION "Priežiūros informacija" FONT 8, "MS Shell Dlg" { CONTROL "Gerai", IDOK, "BUTTON", BS_DEFPUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 103, 116, 50, 14 - CONTROL "Ši informacija gali būti panaudota programos „%s“ techninei priežiūrai gauti:", IDC_INFO_LABEL, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 12, 9, 228, 19 + CONTROL "Ši informacija gali būti panaudota programos '%s' techninei priežiūrai gauti:", IDC_INFO_LABEL, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 12, 9, 228, 19 CONTROL "Leidėjas:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 30, 60, 8 CONTROL "Versija:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 40, 60, 8 CONTROL "Kontaktas:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 50, 60, 8 @@ -85,3 +78,5 @@ FONT 8, "MS Shell Dlg" CONTROL "", IDC_INFO_UPDATES, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 90, 136, 8 CONTROL "", IDC_INFO_COMMENTS, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 100, 136, 8 } + +#pragma code_page(default) diff --git a/dlls/appwiz.cpl/Makefile.in b/dlls/appwiz.cpl/Makefile.in index b7ae32e064e..141715d7447 100644 --- a/dlls/appwiz.cpl/Makefile.in +++ b/dlls/appwiz.cpl/Makefile.in @@ -3,27 +3,12 @@ TOPOBJDIR = ../.. SRCDIR = @srcdir@ VPATH = @srcdir@ MODULE = appwiz.cpl -IMPORTS = kernel32 comctl32 advapi32 shell32 user32 comdlg32 +IMPORTS = kernel32 comctl32 advapi32 shell32 user32 C_SRCS = \ appwiz.c -RC_SRCS = \ - De.rc \ - En.rc \ - Fr.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pt.rc \ - Ro.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Zh.rc \ - appwiz.rc +RC_SRCS = appwiz.rc @MAKE_DLL_RULES@ diff --git a/dlls/appwiz.cpl/Nl.rc b/dlls/appwiz.cpl/Nl.rc index 34704ec3d78..62a82f45f42 100644 --- a/dlls/appwiz.cpl/Nl.rc +++ b/dlls/appwiz.cpl/Nl.rc @@ -19,10 +19,6 @@ * */ -#include "res.h" - -#pragma code_page(65001) - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE @@ -37,10 +33,6 @@ STRINGTABLE IDS_COLUMN_NAME, "Naam" IDS_COLUMN_PUBLISHER, "Uitgever" IDS_COLUMN_VERSION, "Versie" - IDS_INSTALL_FILTER, "Installatie-programma's\0*instal*.exe;*setup*.exe;*.msi\0Programma's (*.exe)\0*.exe\0Alle bestanden (*.*)\0*.*\0\0" - - IDS_REMOVE, "&Verwijderen..." - IDS_MODIFY_REMOVE, "&Modify/Remove..." } IDD_MAIN DIALOG 0, 0, 320, 220 @@ -52,11 +44,10 @@ FONT 8, "MS Shell Dlg" CONTROL "&Installeren...", IDC_INSTALL, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 26, 64, 14 CONTROL "", -1, "STATIC", SS_LEFT | SS_SUNKEN | WS_CHILD | WS_VISIBLE, 7, 46, 303, 1 CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 - CONTROL "De volgende software kan automatisch verwijderd worden. Om het programma te verwijderen of de geïnstalleerde onderdelen te wijzigen, selecteer het in de lijst en druk op Wijzigen/Verwijderen.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 + CONTROL "De volgende software kan automatisch verwijderd worden. Om het programma te verwijderen of de geïnstalleerde onderdelen te wijzigen, selecteer het in de lijst en druk op Toevoegen/Verwijderen.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "&Support Informatie...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 104, 198, 64, 14 - CONTROL "&Modify...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "&Verwijderen...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 + CONTROL "Toevoegen/&Verwijderen...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 198, 64, 14 + CONTROL "&Support Informatie...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 176, 198, 64, 14 CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 } diff --git a/dlls/appwiz.cpl/No.rc b/dlls/appwiz.cpl/No.rc index a6106a43915..2b15cbbbcb0 100644 --- a/dlls/appwiz.cpl/No.rc +++ b/dlls/appwiz.cpl/No.rc @@ -1,7 +1,7 @@ /* -* Add/Remove Programs Norwegian Bokmål resources +* Add/Remove Programs Norwegian Bokmål resources * -* Copyright 2008-2009 Alexander N. Sørnes +* Copyright 2008 Alexander N. Sørnes * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -19,11 +19,6 @@ * */ -#include "res.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE @@ -32,16 +27,12 @@ STRINGTABLE IDS_CPL_DESC, "Lar deg installere ny programvare eller fjerne installerte programmer." IDS_TAB1_TITLE, "Programmer" - IDS_UNINSTALL_FAILED, "Klarte ikke kjøre avinstalleringsprogrammet, «%s». Vil du fjerne oppføringen fra listen over installerte programmer?" + IDS_UNINSTALL_FAILED, "Klarte ikke kjøre avinstalleringsprogrammet, «%s». Vil du fjerne oppføringen fra listen over installerte programmer?" IDS_NOT_SPECIFIED, "Ikke oppgitt" IDS_COLUMN_NAME, "Navn" IDS_COLUMN_PUBLISHER, "Utgiver" IDS_COLUMN_VERSION, "Versjon" - IDS_INSTALL_FILTER, "Installasjonsprogrammer\0*instal*.exe;*setup*.exe;*.msi\0Programmer (*.exe)\0*.exe\0Alle filer (*.*)\0*.*\0\0" - - IDS_REMOVE, "Fje&rn..." - IDS_MODIFY_REMOVE, "&Modify/Remove..." } IDD_MAIN DIALOG 0, 0, 320, 220 @@ -49,30 +40,29 @@ STYLE DS_MODALFRAME | DS_3DLOOK | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMEN CAPTION "Installer/Avinstaller" FONT 8, "MS Shell Dlg" { - CONTROL "Trykk «Installer» for å installere et program fra en diskett, CD-stasjon eller annet medium.", 1000, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 7, 270, 20 + CONTROL "Trykk «Installer» for å installere et program fra en diskett, CD-stasjon eller annet medium.", 1000, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 7, 270, 20 CONTROL "&Installer...", IDC_INSTALL, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 26, 64, 14 CONTROL "", -1, "STATIC", SS_LEFT | SS_SUNKEN | WS_CHILD | WS_VISIBLE, 7, 46, 303, 1 CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 - CONTROL "Følgende programmer kan fjernes automatisk. Merk et program og trykk «Legg til/Fjern» for å fjerne det eller endre installerte komponenter", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 + CONTROL "Følgende programmer kan fjernes automatisk. Merk et program og trykk «Legg til/Fjern» for å fjerne det eller endre installerte komponenter", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "&Støtteinformasjon...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 98, 198, 70, 14 - CONTROL "&Modify...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "Fje&rn...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 + CONTROL "Legg til/Fje&rn...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 198, 64, 14 + CONTROL "&Støtteinformasjon...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 170, 198, 70, 14 CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 } IDD_INFO DIALOG 0, 0, 256, 138 STYLE DS_MODALFRAME | DS_3DLOOK | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Støtteinformasjon" +CAPTION "Støtteinformasjon" FONT 8, "MS Shell Dlg" { CONTROL "OK", IDOK, "BUTTON", BS_DEFPUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 103, 116, 50, 14 - CONTROL "Følgende informasjon kan brukes til å få teknisk støtte for %s:", IDC_INFO_LABEL, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 12, 9, 228, 19 + CONTROL "Følgende informasjon kan brukes til å få teknisk støtte for %s:", IDC_INFO_LABEL, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 12, 9, 228, 19 CONTROL "Utgiver:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 30, 60, 8 CONTROL "Versjon:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 40, 60, 8 CONTROL "Kontakt:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 50, 60, 8 - CONTROL "Støtteinformasjon:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 60, 64, 8 - CONTROL "Kundestøtte, tlf:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 70, 68, 8 + CONTROL "Støtteinformasjon:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 60, 64, 8 + CONTROL "Kundestøtte, tlf:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 70, 68, 8 CONTROL "Lesmeg-fil:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 80, 60, 8 CONTROL "Produktoppdateringer:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 90, 60, 8 CONTROL "Kommentarer:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 100, 60, 8 diff --git a/dlls/appwiz.cpl/Pt.rc b/dlls/appwiz.cpl/Pt.rc index 4abcb507449..31c7d8aef30 100644 --- a/dlls/appwiz.cpl/Pt.rc +++ b/dlls/appwiz.cpl/Pt.rc @@ -19,28 +19,20 @@ * */ -#include "res.h" - -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE +LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE { IDS_CPL_TITLE, "Adicionar/Remover Programas" - IDS_CPL_DESC, "Permite a instalação de novo software, ou a remoção de software existente no seu computador." - IDS_TAB1_TITLE, "Aplicações" + IDS_CPL_DESC, "Permite a instalação de novo software, ou a remoção de software existente no seu computador." + IDS_TAB1_TITLE, "Aplicações" - IDS_UNINSTALL_FAILED, "Não foi possível executar o desinstalador, '%s'. Deseja remover do registo a entrada de desinstalação para este programa?" - IDS_NOT_SPECIFIED, "Não especificado" + IDS_UNINSTALL_FAILED, "Não foi possível executar o desinstalador, '%s'. Deseja remover do registo a entrada de desinstalação para este programa?" + IDS_NOT_SPECIFIED, "Não especificado" IDS_COLUMN_NAME, "Nome" IDS_COLUMN_PUBLISHER, "Editor" - IDS_COLUMN_VERSION, "Versão" - IDS_INSTALL_FILTER, "Programas de Instalação\0*instal*.exe;*setup*.exe;*.msi\0Programas (*.exe)\0*.exe\0Todos os ficheiros (*.*)\0*.*\0\0" - - IDS_REMOVE, "&Remover..." - IDS_MODIFY_REMOVE, "&Modificar/Remover..." + IDS_COLUMN_VERSION, "Versão" } IDD_MAIN DIALOG 0, 0, 320, 220 @@ -48,33 +40,32 @@ STYLE DS_MODALFRAME | DS_3DLOOK | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMEN CAPTION "Instalar/Desinstalar" FONT 8, "MS Shell Dlg" { - CONTROL "Para instalar um programa novo a partir de uma disquete, CD-ROM ou do seu disco rígido clique em Instalar.", 1000, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 7, 270, 20 + CONTROL "Para instalar um programa novo a partir de uma disquete, CD-ROM ou do seu disco rígido clique em Instalar.", 1000, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 7, 270, 20 CONTROL "&Instalar...", IDC_INSTALL, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 26, 64, 14 CONTROL "", -1, "STATIC", SS_LEFT | SS_SUNKEN | WS_CHILD | WS_VISIBLE, 7, 46, 303, 1 CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 CONTROL "O software seguinte pode ser automaticamente removido. Para remover um programa ou modificar os seus componentes instalados seleccione-o da lista e clique em Adicionar/Remover.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "&Informação de Suporte...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 104, 198, 64, 14 - CONTROL "&Modificar...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "&Remover...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 + CONTROL "Adicionar/&Remover...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 198, 64, 14 + CONTROL "&Informação de Suporte...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 176, 198, 64, 14 CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 } IDD_INFO DIALOG 0, 0, 256, 138 STYLE DS_MODALFRAME | DS_3DLOOK | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Informação de Suporte" +CAPTION "Informação de Suporte" FONT 8, "MS Shell Dlg" { CONTROL "OK", IDOK, "BUTTON", BS_DEFPUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 103, 116, 50, 14 - CONTROL "A informação seguinte pode ser usada para obter suporte técnico para %s:", IDC_INFO_LABEL, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 12, 9, 228, 19 + CONTROL "A informação seguinte pode ser usada para obter suporte técnico para %s:", IDC_INFO_LABEL, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 12, 9, 228, 19 CONTROL "Editor:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 30, 60, 8 - CONTROL "Versão:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 40, 60, 8 + CONTROL "Versão:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 40, 60, 8 CONTROL "Contacto:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 50, 60, 8 - CONTROL "Informação de Suporte:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 60, 64, 8 + CONTROL "Informação de Suporte:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 60, 64, 8 CONTROL "Telefone de Suporte:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 70, 68, 8 CONTROL "Readme:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 80, 60, 8 - CONTROL "Actualizações de Produto:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 90, 60, 8 - CONTROL "Comentários:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 100, 60, 8 + CONTROL "Updates Producto:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 90, 60, 8 + CONTROL "Comentários:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 100, 60, 8 CONTROL "", IDC_INFO_PUBLISHER, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 30, 136, 8 CONTROL "", IDC_INFO_VERSION, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 40, 136, 8 CONTROL "", IDC_INFO_CONTACT, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 50, 136, 8 diff --git a/dlls/appwiz.cpl/Ro.rc b/dlls/appwiz.cpl/Ro.rc index 46c339b3a54..321e9ddd52e 100644 --- a/dlls/appwiz.cpl/Ro.rc +++ b/dlls/appwiz.cpl/Ro.rc @@ -20,8 +20,6 @@ * */ -#include "res.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -38,10 +36,6 @@ STRINGTABLE IDS_COLUMN_NAME, "Nume" IDS_COLUMN_PUBLISHER, "Emitent" IDS_COLUMN_VERSION, "Versiune" - IDS_INSTALL_FILTER, "Programe de instalare\0*instal*.exe;*setup*.exe;*.msi\0Programe (*.exe)\0*.exe\0Toate fișierele (*.*)\0*.*\0\0" - - IDS_REMOVE, "&Sterge..." - IDS_MODIFY_REMOVE, "&Modify/Remove..." } IDD_MAIN DIALOG 0, 0, 320, 220 @@ -55,9 +49,8 @@ FONT 8, "MS Shell Dlg" CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 CONTROL "Urmatoarele programe pot fi îndepărtate automat. Pentru a îndepărta un program sau pentru ai modifica componentele instalate, alegeți programul din listă și apăsați pe „Adaugă/&șterge”.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "Informații a&sistență...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 94, 198, 74, 14 - CONTROL "&Modify...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "&Sterge...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 + CONTROL "Adaugă/&șterge...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 236, 198, 74, 14 + CONTROL "Informații a&sistență...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 156, 198, 74, 14 CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 } @@ -85,3 +78,5 @@ FONT 8, "MS Shell Dlg" CONTROL "", IDC_INFO_UPDATES, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 90, 136, 8 CONTROL "", IDC_INFO_COMMENTS, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 100, 136, 8 } + +#pragma code_page(default) diff --git a/dlls/appwiz.cpl/Ru.rc b/dlls/appwiz.cpl/Ru.rc index 4de5991f7d3..49322e4e106 100644 --- a/dlls/appwiz.cpl/Ru.rc +++ b/dlls/appwiz.cpl/Ru.rc @@ -19,62 +19,53 @@ * */ -#include "res.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE { - IDS_CPL_TITLE, "Установка/Удаление программ" - IDS_CPL_DESC, "Позволяет устанавливать новое ПО, или удалять существующее с Вашего компьютера." - IDS_TAB1_TITLE, "Приложения" - - IDS_UNINSTALL_FAILED, "Невозможно выполнить, '%s'. Вы хотите удалить программу из списка?" - IDS_NOT_SPECIFIED, "Отсутствует" + IDS_CPL_TITLE, "Óñòàíîâêà/Óäàëåíèå ïðîãðàìì" + IDS_CPL_DESC, "Ïîçâîëÿåò óñòàíàâëèâàòü íîâîå ÏÎ, èëè óäàëÿòü ñóùåñòâóþùåå ñ Âàøåãî êîìïüþòåðà." + IDS_TAB1_TITLE, "Ïðèëîæåíèÿ" - IDS_COLUMN_NAME, "Название" - IDS_COLUMN_PUBLISHER, "Издатель" - IDS_COLUMN_VERSION, "Версия" + IDS_UNINSTALL_FAILED, "Íåâîçìîæíî âûïîëíèòü, '%s'. Âû õîòèòå óäàëèòü ïðîãðàììó èç ñïèñêà?" + IDS_NOT_SPECIFIED, "Îòñóòñòâóåò" - IDS_REMOVE, "&Удалить..." - IDS_MODIFY_REMOVE, "&Изменить/Удалить..." + IDS_COLUMN_NAME, "Íàçâàíèå" + IDS_COLUMN_PUBLISHER, "Èçäàòåëü" + IDS_COLUMN_VERSION, "Âåðñèÿ" } IDD_MAIN DIALOG 0, 0, 320, 235 STYLE DS_MODALFRAME | DS_3DLOOK | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Установка/Удаление" +CAPTION "Óñòàíîâêà/Óäàëåíèå" FONT 8, "MS Shell Dlg" { -CONTROL "Чтобы установить программу с CD-ROM, дискеты или жёсткого диска, нажмите Установить.", 1000, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 7, 270, 20 - CONTROL "Ус&тановить...", IDC_INSTALL, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 26, 64, 14 +CONTROL "×òîáû óñòàíîâèòü ïðîãðàììó ñ CD-ROM, äèñêåòû èëè æ¸ñòêîãî äèñêà, íàæìèòå Óñòàíîâèòü.", 1000, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 7, 270, 20 + CONTROL "Óñ&òàíîâèòü...", IDC_INSTALL, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 26, 64, 14 CONTROL "", -1, "STATIC", SS_LEFT | SS_SUNKEN | WS_CHILD | WS_VISIBLE, 7, 46, 303, 1 CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 - CONTROL "&Перечисленные программы можно удалить или переустановить автоматически. Чтобы удалить программу или изменить состав установленных компонентов, выберите нужный пункт списка и нажмите кнопку Установить/Удалить.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 55, 270, 32 + CONTROL "&Ïåðå÷èñëåííûå ïðîãðàììû ìîæíî óäàëèòü èëè ïåðåóñòàíîâèòü àâòîìàòè÷åñêè. ×òîáû óäàëèòü ïðîãðàììó èëè èçìåíèòü ñîñòàâ óñòàíîâëåííûõ êîìïîíåíòîâ, âûáåðèòå íóæíûé ïóíêò ñïèñêà è íàæìèòå êíîïêó Óñòàíîâèòü/Óäàëèòü.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 55, 270, 32 CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "&Сведения о поддержке...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 74, 198, 94, 14 - CONTROL "&Изменить...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "&Удалить...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 + CONTROL "Óñòàíîâèòü/&Óäàëèòü...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 216, 198, 94, 14 + CONTROL "&Ñâåäåíèÿ î ïîääåðæêå...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 116, 198, 94, 14 CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 } IDD_INFO DIALOG 0, 0, 256, 138 STYLE DS_MODALFRAME | DS_3DLOOK | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Сведения о поддержке" +CAPTION "Ñâåäåíèÿ î ïîääåðæêå" FONT 8, "MS Shell Dlg" { CONTROL "OK", IDOK, "BUTTON", BS_DEFPUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 103, 116, 50, 14 - CONTROL "Перечисленная информация может быть использована для получения технической поддержки приложения %s:", IDC_INFO_LABEL, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 12, 9, 228, 23 - CONTROL "Издатель:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 33, 60, 8 - CONTROL "Версия:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 43, 60, 8 - CONTROL "Контактное лицо:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 53, 60, 8 - CONTROL "Поддержка:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 63, 64, 8 - CONTROL "Телефон:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 73, 68, 8 - CONTROL "Файл 'Readme':", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 83, 60, 8 - CONTROL "Обновления:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 93, 60, 8 - CONTROL "Комментарий:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 103, 60, 8 + CONTROL "Ïåðå÷èñëåííàÿ èíôîðìàöèÿ ìîæåò áûòü èñïîëüçîâàíà äëÿ ïîëó÷åíèÿ òåõíè÷åñêîé ïîääåðæêè ïðèëîæåíèÿ %s:", IDC_INFO_LABEL, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 12, 9, 228, 23 + CONTROL "Èçäàòåëü:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 33, 60, 8 + CONTROL "Âåðñèÿ:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 43, 60, 8 + CONTROL "Êîíòàêòíîå ëèöî:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 53, 60, 8 + CONTROL "Ïîääåðæêà:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 63, 64, 8 + CONTROL "Òåëåôîí:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 73, 68, 8 + CONTROL "Ôàéë 'Readme':", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 83, 60, 8 + CONTROL "Îáíîâëåíèÿ:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 93, 60, 8 + CONTROL "Êîììåíòàðèé:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 103, 60, 8 CONTROL "", IDC_INFO_PUBLISHER, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 33, 136, 8 CONTROL "", IDC_INFO_VERSION, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 43, 136, 8 CONTROL "", IDC_INFO_CONTACT, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 53, 136, 8 diff --git a/dlls/appwiz.cpl/Si.rc b/dlls/appwiz.cpl/Si.rc index dc37ae0ef6a..83f2d4b82ff 100644 --- a/dlls/appwiz.cpl/Si.rc +++ b/dlls/appwiz.cpl/Si.rc @@ -19,8 +19,6 @@ * */ -#include "res.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -37,10 +35,6 @@ STRINGTABLE IDS_COLUMN_NAME, "Ime" IDS_COLUMN_PUBLISHER, "Založnik" IDS_COLUMN_VERSION, "Različica" - IDS_INSTALL_FILTER, "Instalacijski programi\0*instal*.exe;*setup*.exe;*.msi\0Programi (*.exe)\0*.exe\0Vse datoteke (*.*)\0*.*\0\0" - - IDS_REMOVE, "&Odstrani ..." - IDS_MODIFY_REMOVE, "&Modify/Remove ..." } IDD_MAIN DIALOG 0, 0, 320, 220 @@ -54,9 +48,8 @@ FONT 8, "MS Shell Dlg" CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 CONTROL "Naslednji programi omogočajo samodejno odstranitev. Za odstranitev programa oz. spremembo nameščenih komponent izberite program s seznama in kliknite 'Dodaj/Odstrani'.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "&Informacije ...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 104, 198, 64, 14 - CONTROL "&Modify ...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "&Odstrani ...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 + CONTROL "Dodaj/&Odstrani ...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 198, 64, 14 + CONTROL "&Informacije ...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 176, 198, 64, 14 CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 } @@ -84,3 +77,5 @@ FONT 8, "MS Shell Dlg" CONTROL "", IDC_INFO_UPDATES, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 90, 136, 8 CONTROL "", IDC_INFO_COMMENTS, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 100, 136, 8 } + +#pragma code_page(default) diff --git a/dlls/appwiz.cpl/Sv.rc b/dlls/appwiz.cpl/Sv.rc deleted file mode 100644 index 75aa17ab8a7..00000000000 --- a/dlls/appwiz.cpl/Sv.rc +++ /dev/null @@ -1,88 +0,0 @@ -/* -* Add/Remove Programs Swedish resources -* -* Copyright 2001-2002, 2008 Owen Rudge -* Copyright 2008 Daniel Nylander -* -* 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA -* -*/ - -#include "res.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL - -STRINGTABLE -{ - IDS_CPL_TITLE, "Lägg till/Ta bort program" - IDS_CPL_DESC, "Låter dig installera ny programvara, eller ta bort befintlig programvara från din dator." - IDS_TAB1_TITLE, "Program" - - IDS_UNINSTALL_FAILED, "Kunde inte köra avinstalleraren, '%s'. Vill du ta bort avinstallationsobjektet för detta program från registret?" - IDS_NOT_SPECIFIED, "Inte angivet" - - IDS_COLUMN_NAME, "Namn" - IDS_COLUMN_PUBLISHER, "Utgivare" - IDS_COLUMN_VERSION, "Version" - IDS_INSTALL_FILTER, "Installationsprogram\0*instal*.exe;*setup*.exe;*.msi\0Program (*.exe)\0*.exe\0Alla filer (*.*)\0*.*\0\0" - - IDS_REMOVE, "&Ta bort..." - IDS_MODIFY_REMOVE, "&Modify/Remove..." -} - -IDD_MAIN DIALOG 0, 0, 320, 220 -STYLE DS_MODALFRAME | DS_3DLOOK | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Installera/Avinstallera" -FONT 8, "MS Shell Dlg" -{ - CONTROL "Klicka på Installera för att installera ett nytt program från en diskett, cd-skiva eller din hårddisk.", 1000, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 7, 270, 20 - CONTROL "&Installera...", IDC_INSTALL, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 26, 64, 14 - CONTROL "", -1, "STATIC", SS_LEFT | SS_SUNKEN | WS_CHILD | WS_VISIBLE, 7, 46, 303, 1 - CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 - CONTROL "Följande programvara kan automatiskt tas bort. Markera den från listan och klicka på Lägg till/Ta bort för att ta bort eller ändra dess installerade komponenter.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 - CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "&Supportinfo...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 104, 198, 64, 14 - CONTROL "&Modify...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "&Ta bort....", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 - CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 -} - -IDD_INFO DIALOG 0, 0, 256, 138 -STYLE DS_MODALFRAME | DS_3DLOOK | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Supportinformation" -FONT 8, "MS Shell Dlg" -{ - CONTROL "OK", IDOK, "BUTTON", BS_DEFPUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 103, 116, 50, 14 - CONTROL "Följande information kan användas för att få teknisk support för %s:", IDC_INFO_LABEL, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 12, 9, 228, 19 - CONTROL "Utgivare:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 30, 60, 8 - CONTROL "Version:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 40, 60, 8 - CONTROL "Kontakt:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 50, 60, 8 - CONTROL "Supportinformation:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 60, 64, 8 - CONTROL "Telefonsupport:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 70, 68, 8 - CONTROL "Readme:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 80, 60, 8 - CONTROL "Produktuppdateringar:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 90, 60, 8 - CONTROL "Kommentarer:", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 16, 100, 60, 8 - CONTROL "", IDC_INFO_PUBLISHER, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 30, 136, 8 - CONTROL "", IDC_INFO_VERSION, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 40, 136, 8 - CONTROL "", IDC_INFO_CONTACT, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 50, 136, 8 - CONTROL "", IDC_INFO_SUPPORT, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 60, 136, 8 - CONTROL "", IDC_INFO_PHONE, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 70, 136, 8 - CONTROL "", IDC_INFO_README, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 80, 136, 8 - CONTROL "", IDC_INFO_UPDATES, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 90, 136, 8 - CONTROL "", IDC_INFO_COMMENTS, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 100, 136, 8 -} diff --git a/dlls/appwiz.cpl/Zh.rc b/dlls/appwiz.cpl/Zh.rc index 974104b678a..53071f795f9 100644 --- a/dlls/appwiz.cpl/Zh.rc +++ b/dlls/appwiz.cpl/Zh.rc @@ -19,8 +19,6 @@ * */ -#include "res.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -38,9 +36,6 @@ STRINGTABLE IDS_COLUMN_NAME, "名称" IDS_COLUMN_PUBLISHER, "生产商" IDS_COLUMN_VERSION, "版本" - - IDS_REMOVE, "&Remove..." - IDS_MODIFY_REMOVE, "&Modify/Remove..." } IDD_MAIN DIALOG 0, 0, 320, 220 @@ -54,9 +49,8 @@ FONT 9, "MS Shell Dlg" CONTROL 2, 1001, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 7, 21, 20 CONTROL "下列软件可以自动卸载. 按'添加/删除'可卸载选定程序或者调整已安装部件.", 1002, "STATIC", SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 40, 57, 270, 30 CONTROL "", IDL_PROGRAMS, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SORTASCENDING | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 7, 90, 303, 100 - CONTROL "技术支持(&S)...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 104, 198, 64, 14 - CONTROL "&Modify...", IDC_MODIFY, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 172, 198, 68, 14 - CONTROL "&Remove...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 244, 198, 68, 14 + CONTROL "添加/删除(&R)...", IDC_ADDREMOVE, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 246, 198, 64, 14 + CONTROL "技术支持(&S)...", IDC_SUPPORT_INFO, "button", BS_PUSHBUTTON | BS_CENTER | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 176, 198, 64, 14 CONTROL 3, 1003, "STATIC", SS_ICON | WS_CHILD | WS_VISIBLE, 7, 57, 21, 20 } @@ -141,3 +135,5 @@ FONT 9, "MS Shell Dlg" CONTROL "", IDC_INFO_UPDATES, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 90, 136, 8 CONTROL "", IDC_INFO_COMMENTS, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 104, 100, 136, 8 } + +#pragma code_page(default) diff --git a/dlls/appwiz.cpl/appwiz.c b/dlls/appwiz.cpl/appwiz.c index 0d9e555fc30..892c6354a17 100644 --- a/dlls/appwiz.cpl/appwiz.c +++ b/dlls/appwiz.cpl/appwiz.c @@ -41,7 +41,6 @@ #include #include #include -#include #include #include "res.h" @@ -56,7 +55,6 @@ typedef struct APPINFO { LPWSTR title; LPWSTR path; - LPWSTR path_modify; LPWSTR icon; int iconIdx; @@ -73,11 +71,6 @@ typedef struct APPINFO { static struct APPINFO *AppInfo = NULL; static HINSTANCE hInst; -static WCHAR btnRemove[MAX_STRING_LEN]; -static WCHAR btnModifyRemove[MAX_STRING_LEN]; - -static const WCHAR openW[] = {'o','p','e','n',0}; - /* names of registry keys */ static const WCHAR BackSlashW[] = { '\\', 0 }; static const WCHAR DisplayNameW[] = {'D','i','s','p','l','a','y','N','a','m','e',0}; @@ -89,8 +82,6 @@ static const WCHAR ContactW[] = {'C','o','n','t','a','c','t',0}; static const WCHAR HelpLinkW[] = {'H','e','l','p','L','i','n','k',0}; static const WCHAR HelpTelephoneW[] = {'H','e','l','p','T','e','l','e','p','h', 'o','n','e',0}; -static const WCHAR ModifyPathW[] = {'M','o','d','i','f','y','P','a','t','h',0}; -static const WCHAR NoModifyW[] = {'N','o','M','o','d','i','f','y',0}; static const WCHAR ReadmeW[] = {'R','e','a','d','m','e',0}; static const WCHAR URLUpdateInfoW[] = {'U','R','L','U','p','d','a','t','e','I', 'n','f','o',0}; @@ -135,7 +126,6 @@ static void FreeAppInfo(APPINFO *info) HeapFree(GetProcessHeap(), 0, info->title); HeapFree(GetProcessHeap(), 0, info->path); - HeapFree(GetProcessHeap(), 0, info->path_modify); HeapFree(GetProcessHeap(), 0, info->icon); HeapFree(GetProcessHeap(), 0, info->publisher); HeapFree(GetProcessHeap(), 0, info->version); @@ -156,7 +146,6 @@ static BOOL ReadApplicationsFromRegistry(HKEY root) HKEY hkeyUninst, hkeyApp; int i, id = 0; DWORD sizeOfSubKeyName, displen, uninstlen; - DWORD dwNoModify, dwType; WCHAR subKeyName[256]; WCHAR key_app[MAX_STRING_LEN]; WCHAR *p; @@ -281,34 +270,6 @@ static BOOL ReadApplicationsFromRegistry(HKEY root) &displen); } - /* Check if NoModify is set */ - dwType = REG_DWORD; - dwNoModify = 0; - displen = sizeof(DWORD); - - if (RegQueryValueExW(hkeyApp, NoModifyW, NULL, &dwType, (LPBYTE)&dwNoModify, &displen) - != ERROR_SUCCESS) - { - dwNoModify = 0; - } - - /* Some installers incorrectly create a REG_SZ instead of a REG_DWORD - check for - ASCII 49, which equals 1 */ - if (dwType == REG_SZ) - dwNoModify = (dwNoModify == 49) ? 1 : 0; - - /* Fetch the modify path */ - if ((dwNoModify == 0) && (RegQueryValueExW(hkeyApp, ModifyPathW, 0, 0, NULL, &displen) - == ERROR_SUCCESS)) - { - iter->path_modify = HeapAlloc(GetProcessHeap(), 0, displen); - - if (!iter->path_modify) - goto err; - - RegQueryValueExW(hkeyApp, ModifyPathW, 0, 0, (LPBYTE)iter->path_modify, &displen); - } - /* registry key */ iter->regroot = root; lstrcpyW(iter->regkey, subKeyName); @@ -404,94 +365,18 @@ static inline void EmptyList(void) */ static void UpdateButtons(HWND hWnd) { - APPINFO *iter; - LVITEMW lvItem; - DWORD selitem = SendDlgItemMessageW(hWnd, IDL_PROGRAMS, LVM_GETNEXTITEM, -1, - LVNI_FOCUSED | LVNI_SELECTED); - BOOL enable_modify = FALSE; - - if (selitem != -1) - { - lvItem.iItem = selitem; - lvItem.mask = LVIF_PARAM; - - if (SendDlgItemMessageW(hWnd, IDL_PROGRAMS, LVM_GETITEMW, 0, (LPARAM) &lvItem)) - { - for (iter = AppInfo; iter; iter = iter->next) - { - if (iter->id == lvItem.lParam) - { - /* Decide whether to display Modify/Remove as one button or two */ - enable_modify = (iter->path_modify != NULL); - - /* Update title as appropriate */ - if (iter->path_modify == NULL) - SetWindowTextW(GetDlgItem(hWnd, IDC_ADDREMOVE), btnModifyRemove); - else - SetWindowTextW(GetDlgItem(hWnd, IDC_ADDREMOVE), btnRemove); - - break; - } - } - } - } - - /* Enable/disable other buttons if necessary */ - EnableWindow(GetDlgItem(hWnd, IDC_ADDREMOVE), (selitem != -1)); - EnableWindow(GetDlgItem(hWnd, IDC_SUPPORT_INFO), (selitem != -1)); - EnableWindow(GetDlgItem(hWnd, IDC_MODIFY), enable_modify); -} + BOOL sel = SendMessageW(GetDlgItem(hWnd, IDL_PROGRAMS), LVM_GETSELECTEDCOUNT, 0, 0) != 0; -/****************************************************************************** - * Name : InstallProgram - * Description: Search for potential Installer and execute it. - * Parameters : hWnd - Handle of the dialog box - */ -static void InstallProgram(HWND hWnd) -{ - OPENFILENAMEW ofn; - WCHAR titleW[MAX_STRING_LEN]; - WCHAR FilterBufferW[MAX_STRING_LEN]; - WCHAR FileNameBufferW[MAX_PATH]; - - LoadStringW(hInst, IDS_CPL_TITLE, titleW, sizeof(titleW)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_INSTALL_FILTER, FilterBufferW, sizeof(FilterBufferW)/sizeof(WCHAR)); - - memset(&ofn, 0, sizeof(OPENFILENAMEW)); - ofn.lStructSize = sizeof(OPENFILENAMEW); - ofn.hwndOwner = hWnd; - ofn.hInstance = hInst; - ofn.lpstrFilter = FilterBufferW; - ofn.nFilterIndex = 0; - ofn.lpstrFile = FileNameBufferW; - ofn.nMaxFile = MAX_PATH; - ofn.lpstrFileTitle = NULL; - ofn.nMaxFileTitle = 0; - ofn.lpstrTitle = titleW; - ofn.Flags = OFN_HIDEREADONLY | OFN_ENABLESIZING; - FileNameBufferW[0] = 0; - - if (GetOpenFileNameW(&ofn)) - { - SHELLEXECUTEINFOW sei; - memset(&sei, 0, sizeof(sei)); - sei.cbSize = sizeof(sei); - sei.lpVerb = openW; - sei.nShow = SW_SHOWDEFAULT; - sei.fMask = SEE_MASK_NO_CONSOLE; - sei.lpFile = ofn.lpstrFile; - - ShellExecuteExW(&sei); - } + EnableWindow(GetDlgItem(hWnd, IDC_ADDREMOVE), sel); + EnableWindow(GetDlgItem(hWnd, IDC_SUPPORT_INFO), sel); } /****************************************************************************** * Name : UninstallProgram * Description: Executes the specified program's installer. * Parameters : id - the internal ID of the installer to remove - * Parameters : button - ID of button pressed (Modify or Remove) */ -static void UninstallProgram(int id, DWORD button) +static void UninstallProgram(int id) { APPINFO *iter; STARTUPINFOW si; @@ -514,9 +399,8 @@ static void UninstallProgram(int id, DWORD button) memset(&si, 0, sizeof(STARTUPINFOW)); si.cb = sizeof(STARTUPINFOW); si.wShowWindow = SW_NORMAL; - - res = CreateProcessW(NULL, (button == IDC_MODIFY) ? iter->path_modify : iter->path, - NULL, NULL, FALSE, 0, NULL, NULL, &si, &info); + res = CreateProcessW(NULL, iter->path, NULL, NULL, FALSE, 0, NULL, + NULL, &si, &info); if (res) { @@ -853,12 +737,7 @@ static BOOL CALLBACK MainDlgProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lPar case WM_COMMAND: switch (LOWORD(wParam)) { - case IDC_INSTALL: - InstallProgram(hWnd); - break; - case IDC_ADDREMOVE: - case IDC_MODIFY: selitem = SendDlgItemMessageW(hWnd, IDL_PROGRAMS, LVM_GETNEXTITEM, -1, LVNI_FOCUSED|LVNI_SELECTED); @@ -869,7 +748,7 @@ static BOOL CALLBACK MainDlgProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lPar if (SendDlgItemMessageW(hWnd, IDL_PROGRAMS, LVM_GETITEMW, 0, (LPARAM) &lvItem)) - UninstallProgram(lvItem.lParam, LOWORD(wParam)); + UninstallProgram(lvItem.lParam); } hImageList = ResetApplicationList(FALSE, hWnd, hImageList); @@ -913,8 +792,6 @@ static void StartApplet(HWND hWnd) /* Load the strings we will use */ LoadStringW(hInst, IDS_TAB1_TITLE, tab_title, sizeof(tab_title) / sizeof(tab_title[0])); LoadStringW(hInst, IDS_CPL_TITLE, app_title, sizeof(app_title) / sizeof(app_title[0])); - LoadStringW(hInst, IDS_REMOVE, btnRemove, sizeof(btnRemove) / sizeof(btnRemove[0])); - LoadStringW(hInst, IDS_MODIFY_REMOVE, btnModifyRemove, sizeof(btnModifyRemove) / sizeof(btnModifyRemove[0])); /* Fill out the PROPSHEETPAGE */ psp.dwSize = sizeof (PROPSHEETPAGEW); diff --git a/dlls/appwiz.cpl/appwiz.ico b/dlls/appwiz.cpl/appwiz.ico dissimilarity index 100% index 752cf2789919ca0516cd046a1034673f8b679050..fcc5894c69cb0de40227d44089dedfd8b8cc579d 100644 GIT binary patch literal 766 zcwV)UJx;?w5QWEKBT8(^LZTwtxS+*O&nABKDYEBrj>ai`297|1w9Jp!u|-3}Sfky~ z@9p0VQNiDCSCYi%hUk&U7tS4L;4H|gMjM)=oW}HI<1h@AQj$M3jwAgwP^|(uF0lr% zavy7i8#;((DOXjAzMJBJg4rQ6f-vFaeb;*5fRqoD0ljf629Z1C&J4Woqt1zU1s5&kbry literal 3262 zcwV)YO-Ni<7>2J#5M(5x_yYzVaViqUg(5B*>J+pt6g!m$p{6Dqp|~3tsZvS?8rnsy z&7!Gwp((g%aN#CFEP{llrBthgI5QcwMQH0JGdhkLjdiNr+vlD$KX){l+d%tz&h^Z9 z-tRr%`OcrBWbkLTDtt?nI~GMLQWT|{ib=66(*B?0{odZ!?H8t}r|0J899{3cd-0h@BOypR7{UHkmT@U5?It*)+`DV>C^?zMrzf#btt)w8dKN=k!_4#~el1U)`UQf@`;-cz35aLqbYb+6gz30y#yFERZE2ww$gXpFW@C^?epy_Hx$vsjdW!`V5_3(+J2$eWVaXR`xOw zKNCYseL}imz_lw^(iA3Z)F%}rgtU+xh9*&@i=>e{nM25=bl8CO@yqp%#KBUspz?Ci zldtb0v7J^z^fHiK-|A``zKB~a7LVPYrm)%Aa*63j#5szcUtct3$GY{Yv6qbTm8K93N5(h>^f^|B^P3nV%%n&fM=~ob3+24LypoaFMMC9X+%>~Q)XsnmVg;I21&*XUo)=K+}up&^YinIii#>KDypigxQJR> zTHX?t6nDC{enf(8*-`Cd% z+39o+4Gm39OrXH5J3Big-k-w1%%abiHWuvk!hs1NFMQ4971l1HKQ%Rlg2Ulp?e>3r z`0Ua5=<}tG1v|ZP68iX>$){j)a$;@GCyQtCher>-Te$NjU)l*f95a~|Xxja=n&vvA fX-bBsQjf8ns%J!v!=5UULDf66sb~48y-NKD&;=8z diff --git a/dlls/appwiz.cpl/appwiz.rc b/dlls/appwiz.cpl/appwiz.rc index 152ea4c5a06..f59cb9774b5 100644 --- a/dlls/appwiz.cpl/appwiz.rc +++ b/dlls/appwiz.cpl/appwiz.rc @@ -18,8 +18,27 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA * */ +#include +#include +#include +#include #include "res.h" -/* @makedep: appwiz.ico */ +#include "De.rc" +#include "En.rc" +#include "Fr.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Lt.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pt.rc" +#include "Ro.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Zh.rc" + +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + ICO_MAIN ICON "appwiz.ico" diff --git a/dlls/appwiz.cpl/res.h b/dlls/appwiz.cpl/res.h index c336cf30b61..34129c4d375 100644 --- a/dlls/appwiz.cpl/res.h +++ b/dlls/appwiz.cpl/res.h @@ -19,10 +19,6 @@ * */ -#include -#include -#include - /* Dialogs */ #define IDD_MAIN 1 @@ -33,7 +29,6 @@ #define IDL_PROGRAMS 1011 #define IDC_ADDREMOVE 1012 #define IDC_SUPPORT_INFO 1013 -#define IDC_MODIFY 1014 #define IDC_INFO_PUBLISHER 1100 #define IDC_INFO_VERSION 1101 @@ -58,6 +53,3 @@ #define IDS_COLUMN_NAME 6 #define IDS_COLUMN_PUBLISHER 7 #define IDS_COLUMN_VERSION 8 -#define IDS_INSTALL_FILTER 9 -#define IDS_REMOVE 10 -#define IDS_MODIFY_REMOVE 11 diff --git a/dlls/avifil32/Makefile.in b/dlls/avifil32/Makefile.in index 849bf187ab7..d645d8823f6 100644 --- a/dlls/avifil32/Makefile.in +++ b/dlls/avifil32/Makefile.in @@ -20,28 +20,6 @@ C_SRCS = \ wavfile.c RC_SRCS = \ - avifile_Cs.rc \ - avifile_Da.rc \ - avifile_De.rc \ - avifile_En.rc \ - avifile_Es.rc \ - avifile_Fr.rc \ - avifile_Hu.rc \ - avifile_It.rc \ - avifile_Ja.rc \ - avifile_Ko.rc \ - avifile_Lt.rc \ - avifile_Nl.rc \ - avifile_No.rc \ - avifile_Pl.rc \ - avifile_Pt.rc \ - avifile_Ro.rc \ - avifile_Ru.rc \ - avifile_Si.rc \ - avifile_Sv.rc \ - avifile_Tr.rc \ - avifile_Uk.rc \ - avifile_Zh.rc \ rsrc.rc @MAKE_DLL_RULES@ diff --git a/dlls/avifil32/avifile_Cs.rc b/dlls/avifil32/avifile_Cs.rc index 180ac73838f..86dac3fdf85 100644 --- a/dlls/avifil32/avifile_Cs.rc +++ b/dlls/avifil32/avifile_Cs.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/dlls/avifil32/avifile_Da.rc b/dlls/avifil32/avifile_Da.rc index 22f4576eb1f..669e9185906 100644 --- a/dlls/avifil32/avifile_Da.rc +++ b/dlls/avifil32/avifile_Da.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 diff --git a/dlls/avifil32/avifile_De.rc b/dlls/avifil32/avifile_De.rc index b0f0babb91d..9e3e5f284d0 100644 --- a/dlls/avifil32/avifile_De.rc +++ b/dlls/avifil32/avifile_De.rc @@ -1,5 +1,5 @@ /* - * Copyright 2002 Michael Günnewig + * Copyright 2002 Michael Günnewig * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -16,10 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 @@ -27,7 +23,7 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Komprimierungsoptionen" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "&Wählen Sie die Eingangsdaten aus:",-1,2,5,154,10 + LTEXT "&Wählen Sie die Eingangsdaten aus:",-1,2,5,154,10 COMBOBOX IDC_STREAM,2,18,154,61,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP PUSHBUTTON "&Optionen...",IDC_OPTIONS,170,17,50,14 diff --git a/dlls/avifil32/avifile_En.rc b/dlls/avifil32/avifile_En.rc index e136569e044..0947cbd47d0 100644 --- a/dlls/avifil32/avifile_En.rc +++ b/dlls/avifil32/avifile_En.rc @@ -1,5 +1,5 @@ /* - * Copyright 2002 Michael Günnewig + * Copyright 2002 Michael Günnewig * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 diff --git a/dlls/avifil32/avifile_Es.rc b/dlls/avifil32/avifile_Es.rc index ddeee99f610..45d7003fb7d 100644 --- a/dlls/avifil32/avifile_Es.rc +++ b/dlls/avifil32/avifile_Es.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 diff --git a/dlls/avifil32/avifile_Fr.rc b/dlls/avifil32/avifile_Fr.rc index d313226b0a1..6a38721d58f 100644 --- a/dlls/avifil32/avifile_Fr.rc +++ b/dlls/avifil32/avifile_Fr.rc @@ -2,8 +2,8 @@ * Avifil32 * French language support * - * Copyright 2002 Michael Günnewig - * Copyright 2003 Vincent Béron + * Copyright 2002 Michael Günnewig + * Copyright 2003 Vincent Béron * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -20,11 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 @@ -32,28 +27,28 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Options de compression" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "&Sélectionnez un flux :",-1,2,5,154,10 + LTEXT "&Sélectionnez un flux :",-1,2,5,154,10 COMBOBOX IDC_STREAM,2,18,154,61,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP PUSHBUTTON "&Options...",IDC_OPTIONS,170,17,50,14 - AUTOCHECKBOX "&Imbriquer toutes les",IDC_INTERLEAVE,3,42,85,11,WS_TABSTOP + AUTOCHECKBOX "&Imbriquer à chaque",IDC_INTERLEAVE,3,42,85,11,WS_TABSTOP EDITTEXT IDC_INTERLEAVEEVERY,91,41,32,12,ES_AUTOHSCROLL LTEXT "images",-1,129,43,36,9 - LTEXT "Format actuel :",-1,3,56,73,9 - LTEXT "Cet espace est à louer",IDC_FORMATTEXT,75,56,90,26 + LTEXT "Format actuel:",-1,3,56,73,9 + LTEXT "Cet espace est à louer",IDC_FORMATTEXT,75,56,90,26 DEFPUSHBUTTON "OK",IDOK,170,42,50,14 PUSHBUTTON "Annuler",IDCANCEL,170,61,50,14 END STRINGTABLE DISCARDABLE { - IDS_WAVESTREAMFORMAT "Waveform : %s" + IDS_WAVESTREAMFORMAT "Waveform : %s" IDS_WAVEFILETYPE "Waveform" - IDS_ALLMULTIMEDIA "Tous les fichiers multimédia" - IDS_ALLFILES "Tous les fichiers (*.*)@*.*" - IDS_VIDEO "vidéo" + IDS_ALLMULTIMEDIA "Tous les fichiers multimédias" + IDS_ALLFILES "Tous les fichier (*.*)@*.*" + IDS_VIDEO "vidéo" IDS_AUDIO "audio" IDS_AVISTREAMFORMAT "%s %s #%d" - IDS_AVIFILETYPE "Gestionnaire de fichiers AVI par défaut de Wine" - IDS_UNCOMPRESSED "non compressé" + IDS_AVIFILETYPE "Wine AVI-default-filehandler" + IDS_UNCOMPRESSED "non compressé" } diff --git a/dlls/avifil32/avifile_Hu.rc b/dlls/avifil32/avifile_Hu.rc index 6c3e9c256ff..e9bdce9997a 100644 --- a/dlls/avifil32/avifile_Hu.rc +++ b/dlls/avifil32/avifile_Hu.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 diff --git a/dlls/avifil32/avifile_It.rc b/dlls/avifil32/avifile_It.rc index 314d34dc70b..6f06ec538a8 100644 --- a/dlls/avifil32/avifile_It.rc +++ b/dlls/avifil32/avifile_It.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 diff --git a/dlls/avifil32/avifile_Ja.rc b/dlls/avifil32/avifile_Ja.rc index 847a1fd471f..ab5bdfe6a7f 100644 --- a/dlls/avifil32/avifile_Ja.rc +++ b/dlls/avifil32/avifile_Ja.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - /* UTF-8 */ #pragma code_page(65001) @@ -53,3 +51,5 @@ STRINGTABLE DISCARDABLE IDS_AVIFILETYPE "Wine AVI-default-filehandler" IDS_UNCOMPRESSED "未圧縮" } + +#pragma code_page(default) diff --git a/dlls/avifil32/avifile_Ko.rc b/dlls/avifil32/avifile_Ko.rc index 622880cb01b..46c482122ed 100644 --- a/dlls/avifil32/avifile_Ko.rc +++ b/dlls/avifil32/avifile_Ko.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 diff --git a/dlls/avifil32/avifile_Lt.rc b/dlls/avifil32/avifile_Lt.rc deleted file mode 100644 index e4795b5ea03..00000000000 --- a/dlls/avifil32/avifile_Lt.rc +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "avifile_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Glaudinimo parametrai" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Pasirinkite srautą:",-1,2,5,154,10 - COMBOBOX IDC_STREAM,2,18,154,61,CBS_DROPDOWNLIST | WS_VSCROLL | - WS_TABSTOP - PUSHBUTTON "&Parinktys...",IDC_OPTIONS,170,17,50,14 - AUTOCHECKBOX "&Įtarpuoti kas",IDC_INTERLEAVE,3,42,85,11,WS_TABSTOP - EDITTEXT IDC_INTERLEAVEEVERY,91,41,32,12,ES_AUTOHSCROLL - LTEXT "kadrų",-1,129,43,36,9 - LTEXT "Dabartinis formatas:",-1,3,56,73,9 - LTEXT "Ši vieta išnuomojama",IDC_FORMATTEXT,75,56,90,26 - DEFPUSHBUTTON "Gerai",IDOK,170,42,50,14 - PUSHBUTTON "Atsisakyti",IDCANCEL,170,61,50,14 -END - -STRINGTABLE DISCARDABLE -{ - IDS_WAVESTREAMFORMAT "Bangos forma: %s" - IDS_WAVEFILETYPE "Bangos forma" - IDS_ALLMULTIMEDIA "Visi multimedijos failai" - IDS_ALLFILES "Visi failai (*.*)@*.*" - IDS_VIDEO "vaizdas" - IDS_AUDIO "garsas" - IDS_AVISTREAMFORMAT "%s %s #%d" - IDS_AVIFILETYPE "Wine numatyta-AVI-doroklė" - IDS_UNCOMPRESSED "neglaudintas" -} diff --git a/dlls/avifil32/avifile_Nl.rc b/dlls/avifil32/avifile_Nl.rc index b2546a0aaee..b1205721871 100644 --- a/dlls/avifil32/avifile_Nl.rc +++ b/dlls/avifil32/avifile_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 diff --git a/dlls/avifil32/avifile_No.rc b/dlls/avifil32/avifile_No.rc index 84198511762..8483ab25b14 100644 --- a/dlls/avifil32/avifile_No.rc +++ b/dlls/avifil32/avifile_No.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 diff --git a/dlls/avifil32/avifile_Pl.rc b/dlls/avifil32/avifile_Pl.rc index f5e8edadc50..49abdb0c5b8 100644 --- a/dlls/avifil32/avifile_Pl.rc +++ b/dlls/avifil32/avifile_Pl.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 diff --git a/dlls/avifil32/avifile_Pt.rc b/dlls/avifil32/avifile_Pt.rc index ce3d032eb91..37bb941673b 100644 --- a/dlls/avifil32/avifile_Pt.rc +++ b/dlls/avifil32/avifile_Pt.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 diff --git a/dlls/avifil32/avifile_Ro.rc b/dlls/avifil32/avifile_Ro.rc deleted file mode 100644 index 6e63780045f..00000000000 --- a/dlls/avifil32/avifile_Ro.rc +++ /dev/null @@ -1,57 +0,0 @@ -/* - * avifil32.dll (Romanian resources) - * - * Copyright 2009 Paul Chitescu - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "avifile_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL - -IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Opțiuni de compresie" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Alegeți un flux:",-1,2,5,154,10 - COMBOBOX IDC_STREAM,2,18,154,61,CBS_DROPDOWNLIST | WS_VSCROLL | - WS_TABSTOP - PUSHBUTTON "&Opțiuni...",IDC_OPTIONS,170,17,50,14 - AUTOCHECKBOX "Ȋ&ntrețese fiecare",IDC_INTERLEAVE,3,42,85,11,WS_TABSTOP - EDITTEXT IDC_INTERLEAVEEVERY,91,41,32,12,ES_AUTOHSCROLL - LTEXT "cadre",-1,129,43,36,9 - LTEXT "Formatul curent:",-1,3,56,73,9 - LTEXT "This space for rent",IDC_FORMATTEXT,75,56,90,26 - DEFPUSHBUTTON "OK",IDOK,170,42,50,14 - PUSHBUTTON "Renunță",IDCANCEL,170,61,50,14 -END - -STRINGTABLE DISCARDABLE -{ - IDS_WAVESTREAMFORMAT "Forma de undă: %s" - IDS_WAVEFILETYPE "Formă de undă" - IDS_ALLMULTIMEDIA "Toate fișierele multimedia" - IDS_ALLFILES "Toate fișierele (*.*)@*.*" - IDS_VIDEO "video" - IDS_AUDIO "audio" - IDS_AVISTREAMFORMAT "%s %s #%d" - IDS_AVIFILETYPE "Tratare implicită Wine pentru AVI" - IDS_UNCOMPRESSED "necomprimat" -} diff --git a/dlls/avifil32/avifile_Ru.rc b/dlls/avifil32/avifile_Ru.rc index 12ac27d3b98..fa8206d3824 100644 --- a/dlls/avifil32/avifile_Ru.rc +++ b/dlls/avifil32/avifile_Ru.rc @@ -18,40 +18,35 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Настройки сжатия" +CAPTION "Íàñòðîéêè ñæàòèÿ" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "&Выберите поток:",-1,2,5,154,10 + LTEXT "&Âûáåðèòå ïîòîê:",-1,2,5,154,10 COMBOBOX IDC_STREAM,2,18,154,61,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Опции...",IDC_OPTIONS,170,17,50,14 - AUTOCHECKBOX "&Прослаивать каждые",IDC_INTERLEAVE,3,42,85,11,WS_TABSTOP + PUSHBUTTON "&Îïöèè...",IDC_OPTIONS,170,17,50,14 + AUTOCHECKBOX "&Ïðîñëàèâàòü êàæäûå",IDC_INTERLEAVE,3,42,85,11,WS_TABSTOP EDITTEXT IDC_INTERLEAVEEVERY,91,41,32,12,ES_AUTOHSCROLL - LTEXT "фрейма",-1,129,43,36,9 - LTEXT "Текущий формат:",-1,3,56,73,9 - LTEXT "Это место сдаётся в аренду",IDC_FORMATTEXT,75,56,90,26 + LTEXT "ôðåéìà",-1,129,43,36,9 + LTEXT "Òåêóùèé ôîðìàò:",-1,3,56,73,9 + LTEXT "Ýòî ìåñòî ñäà¸òñÿ â àðåíäó",IDC_FORMATTEXT,75,56,90,26 DEFPUSHBUTTON "OK",IDOK,170,42,50,14 - PUSHBUTTON "Отмена",IDCANCEL,170,61,50,14 + PUSHBUTTON "Îòìåíà",IDCANCEL,170,61,50,14 END STRINGTABLE DISCARDABLE { - IDS_WAVESTREAMFORMAT "Звуковой поток: %s" - IDS_WAVEFILETYPE "Звуковой поток" - IDS_ALLMULTIMEDIA "Все файлы мультимедиа" - IDS_ALLFILES "Все файлы (*.*)@*.*" - IDS_VIDEO "видео" - IDS_AUDIO "аудио" + IDS_WAVESTREAMFORMAT "Çâóêîâîé ïîòîê: %s" + IDS_WAVEFILETYPE "Çâóêîâîé ïîòîê" + IDS_ALLMULTIMEDIA "Âñå ôàéëû ìóëüòèìåäèà" + IDS_ALLFILES "Âñå ôàéëû (*.*)@*.*" + IDS_VIDEO "âèäåî" + IDS_AUDIO "àóäèî" IDS_AVISTREAMFORMAT "%s %s #%d" - IDS_AVIFILETYPE "Обработчик по умолчанию avi-файлов в Wine" - IDS_UNCOMPRESSED "без сжатия" + IDS_AVIFILETYPE "Îáðàáîò÷èê ïî óìîë÷àíèþ avi-ôàéëîâ â Wine" + IDS_UNCOMPRESSED "áåç ñæàòèÿ" } diff --git a/dlls/avifil32/avifile_Si.rc b/dlls/avifil32/avifile_Si.rc index 0840321eaa1..579be48d02d 100644 --- a/dlls/avifil32/avifile_Si.rc +++ b/dlls/avifil32/avifile_Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -52,3 +50,5 @@ STRINGTABLE DISCARDABLE IDS_AVIFILETYPE "Wine privzeti-upravljalec-AVI-datotek" IDS_UNCOMPRESSED "nestisnjeno" } + +#pragma code_page(default) diff --git a/dlls/avifil32/avifile_Sv.rc b/dlls/avifil32/avifile_Sv.rc index 126bca6e6a1..f65e4d216cc 100644 --- a/dlls/avifil32/avifile_Sv.rc +++ b/dlls/avifil32/avifile_Sv.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 diff --git a/dlls/avifil32/avifile_Tr.rc b/dlls/avifil32/avifile_Tr.rc index c5dbf6e818d..451802f42bf 100644 --- a/dlls/avifil32/avifile_Tr.rc +++ b/dlls/avifil32/avifile_Tr.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT IDD_SAVEOPTIONS DIALOG FIXED IMPURE 43, 37, 226, 82 diff --git a/dlls/avifil32/avifile_Uk.rc b/dlls/avifil32/avifile_Uk.rc index 9934ab411fa..d380c8ad78c 100644 --- a/dlls/avifil32/avifile_Uk.rc +++ b/dlls/avifil32/avifile_Uk.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" LANGUAGE LANG_UKRAINIAN, SUBLANG_DEFAULT diff --git a/dlls/avifil32/avifile_Zh.rc b/dlls/avifil32/avifile_Zh.rc index 5d962e7fdd5..0075ed8ecfe 100644 --- a/dlls/avifil32/avifile_Zh.rc +++ b/dlls/avifil32/avifile_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "avifile_private.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -88,3 +86,5 @@ STRINGTABLE DISCARDABLE IDS_AVIFILETYPE "Wine AVI-默認處理器" IDS_UNCOMPRESSED "未壓縮" } + +#pragma code_page(default) diff --git a/dlls/avifil32/avifile_private.h b/dlls/avifil32/avifile_private.h index 0cff6ad56b9..db31bd497cf 100644 --- a/dlls/avifil32/avifile_private.h +++ b/dlls/avifil32/avifile_private.h @@ -19,9 +19,6 @@ #ifndef __AVIFILE_PRIVATE_H #define __AVIFILE_PRIVATE_H -#include -#include - #ifndef MAX_AVISTREAMS #define MAX_AVISTREAMS 8 #endif diff --git a/dlls/avifil32/rsrc.rc b/dlls/avifil32/rsrc.rc index 330d473f1fc..68fbab3e5bc 100644 --- a/dlls/avifil32/rsrc.rc +++ b/dlls/avifil32/rsrc.rc @@ -1,7 +1,7 @@ /* * Top level resource file for avifil32.dll * - * Copyright 2002 Michael Günnewig + * Copyright 2002 Michael Günnewig * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -18,8 +18,14 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winver.h" #include "avifile_private.h" +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + #define WINE_OLESELFREGISTER #define WINE_FILEDESCRIPTION_STR "Wine AVI file support library" #define WINE_FILENAME_STR "avifil32.dll" @@ -27,3 +33,28 @@ #define WINE_FILEVERSION_STR "4.03.1998" #include "wine/wine_common_ver.rc" + +/* + * Everything specific to any language goes + * in one of the specific files. + */ +#include "avifile_Cs.rc" +#include "avifile_Da.rc" +#include "avifile_De.rc" +#include "avifile_En.rc" +#include "avifile_Es.rc" +#include "avifile_Fr.rc" +#include "avifile_Hu.rc" +#include "avifile_It.rc" +#include "avifile_Ja.rc" +#include "avifile_Ko.rc" +#include "avifile_Nl.rc" +#include "avifile_No.rc" +#include "avifile_Pl.rc" +#include "avifile_Pt.rc" +#include "avifile_Ru.rc" +#include "avifile_Si.rc" +#include "avifile_Sv.rc" +#include "avifile_Tr.rc" +#include "avifile_Uk.rc" +#include "avifile_Zh.rc" diff --git a/dlls/avifile.dll16/Makefile.in b/dlls/avifile.dll16/Makefile.in index 8776e4a73f2..396118eb1ed 100644 --- a/dlls/avifile.dll16/Makefile.in +++ b/dlls/avifile.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = avifile.dll16 IMPORTS = avifil32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,avifil32.dll +SPEC_SRCS = avifile.dll16.spec + @MAKE_DLL_RULES@ @DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/browseui/Makefile.in b/dlls/browseui/Makefile.in index 777a2179d4f..845e66a5e72 100644 --- a/dlls/browseui/Makefile.in +++ b/dlls/browseui/Makefile.in @@ -14,24 +14,7 @@ C_SRCS = \ progressdlg.c \ regsvr.c -RC_SRCS = \ - rsrc_De.rc \ - rsrc_En.rc \ - rsrc_Es.rc \ - rsrc_Fr.rc \ - rsrc_Ja.rc \ - rsrc_Ko.rc \ - rsrc_Lt.rc \ - rsrc_Nl.rc \ - rsrc_No.rc \ - rsrc_Pl.rc \ - rsrc_Pt.rc \ - rsrc_Ro.rc \ - rsrc_Ru.rc \ - rsrc_Si.rc \ - rsrc_Sv.rc \ - rsrc_Zh.rc \ - version.rc +RC_SRCS = rsrc.rc @MAKE_DLL_RULES@ diff --git a/dlls/browseui/browseui.spec b/dlls/browseui/browseui.spec index b7a2a7a900b..5d1d2d33c12 100644 --- a/dlls/browseui/browseui.spec +++ b/dlls/browseui/browseui.spec @@ -1,6 +1,6 @@ @ stdcall -private DllCanUnloadNow() @ stdcall -private DllGetClassObject(ptr ptr ptr) @ stdcall -private DllGetVersion(ptr) -@ stdcall -private DllInstall(long wstr) +@ stub DllInstall @ stdcall -private DllRegisterServer() @ stdcall -private DllUnregisterServer() diff --git a/dlls/browseui/browseui_main.c b/dlls/browseui/browseui_main.c index f09d817f545..54e9c5271f9 100644 --- a/dlls/browseui/browseui_main.c +++ b/dlls/browseui/browseui_main.c @@ -212,12 +212,3 @@ HRESULT WINAPI DllGetClassObject(REFCLSID clsid, REFIID iid, LPVOID *ppvOut) FIXME("CLSID %s not supported\n", debugstr_guid(clsid)); return CLASS_E_CLASSNOTAVAILABLE; } - -/*********************************************************************** - * DllInstall (BROWSEUI.@) - */ -HRESULT WINAPI DllInstall(BOOL bInstall, LPCWSTR cmdline) -{ - FIXME("(%s, %s): stub\n", bInstall ? "TRUE" : "FALSE", debugstr_w(cmdline)); - return S_OK; -} diff --git a/dlls/browseui/resids.h b/dlls/browseui/resids.h index cd44a8ebd98..a5b53371580 100644 --- a/dlls/browseui/resids.h +++ b/dlls/browseui/resids.h @@ -16,10 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "winuser.h" -#include "commctrl.h" - #define IDS_CANCELLING 16 #define IDC_ANIMATION 100 diff --git a/dlls/browseui/rsrc.rc b/dlls/browseui/rsrc.rc new file mode 100644 index 00000000000..c16391f6ab2 --- /dev/null +++ b/dlls/browseui/rsrc.rc @@ -0,0 +1,41 @@ +/* + * Copyright 2007 Mikolaj Zalewski + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winuser.h" +#include "commctrl.h" + +#include "resids.h" + +#include "version.rc" + +#include "rsrc_De.rc" +#include "rsrc_En.rc" +#include "rsrc_Es.rc" +#include "rsrc_Fr.rc" +#include "rsrc_Ko.rc" +#include "rsrc_Lt.rc" +#include "rsrc_Nl.rc" +#include "rsrc_No.rc" +#include "rsrc_Pl.rc" +#include "rsrc_Pt.rc" +#include "rsrc_Ro.rc" +#include "rsrc_Ru.rc" +#include "rsrc_Si.rc" +#include "rsrc_Sv.rc" +#include "rsrc_Zh.rc" diff --git a/dlls/browseui/rsrc_De.rc b/dlls/browseui/rsrc_De.rc index 9a0b78e81de..c5c237fe7cb 100644 --- a/dlls/browseui/rsrc_De.rc +++ b/dlls/browseui/rsrc_De.rc @@ -17,9 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" - -#pragma code_page(65001) LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL diff --git a/dlls/browseui/rsrc_En.rc b/dlls/browseui/rsrc_En.rc index c6f597e26cf..1749d1cb6ff 100644 --- a/dlls/browseui/rsrc_En.rc +++ b/dlls/browseui/rsrc_En.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT diff --git a/dlls/browseui/rsrc_Es.rc b/dlls/browseui/rsrc_Es.rc index 0fe5d14bb12..d1478a837b8 100644 --- a/dlls/browseui/rsrc_Es.rc +++ b/dlls/browseui/rsrc_Es.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL diff --git a/dlls/browseui/rsrc_Fr.rc b/dlls/browseui/rsrc_Fr.rc index 5db8abc3b39..85bca2fd6f1 100644 --- a/dlls/browseui/rsrc_Fr.rc +++ b/dlls/browseui/rsrc_Fr.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL diff --git a/dlls/browseui/rsrc_Ja.rc b/dlls/browseui/rsrc_Ja.rc deleted file mode 100644 index 9274c195eeb..00000000000 --- a/dlls/browseui/rsrc_Ja.rc +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Copyright 2009 Aric Stewart, CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resids.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT - -STRINGTABLE -{ - IDS_CANCELLING "キャンセル…" -} - -IDD_PROGRESS_DLG DIALOG 0, 0, 260, 85 -STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU -CAPTION "" -FONT 8, "MS Shell Dlg" -{ - CONTROL "", IDC_ANIMATION, ANIMATE_CLASSA, 0, 12, 10, 236, 25 /* TODO: style */ - LTEXT "", IDC_TEXT_LINE, 7, 45, 250, 10, SS_LEFT|SS_NOPREFIX - LTEXT "", IDC_TEXT_LINE + 1, 7, 55, 250, 10, SS_LEFT|SS_NOPREFIX - CONTROL "", IDC_PROGRESS_BAR, PROGRESS_CLASSA, WS_BORDER, 7, 65, 190, 8 - PUSHBUTTON "キャンセル(&C)", IDCANCEL, 205, 65, 40, 15, WS_GROUP | WS_TABSTOP | WS_VISIBLE - LTEXT "", IDC_TEXT_LINE + 2, 7, 75, 190, 10, SS_LEFT|SS_NOPREFIX -} diff --git a/dlls/browseui/rsrc_Ko.rc b/dlls/browseui/rsrc_Ko.rc index c6d4a68fb6c..e3d0d6d79e7 100644 --- a/dlls/browseui/rsrc_Ko.rc +++ b/dlls/browseui/rsrc_Ko.rc @@ -17,7 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT diff --git a/dlls/browseui/rsrc_Lt.rc b/dlls/browseui/rsrc_Lt.rc index fabad168e70..8814534bcdc 100644 --- a/dlls/browseui/rsrc_Lt.rc +++ b/dlls/browseui/rsrc_Lt.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" - /* UTF-8 */ #pragma code_page(65001) @@ -40,3 +38,5 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "&Atsisakyti", IDCANCEL, 205, 65, 40, 15, WS_GROUP | WS_TABSTOP | WS_VISIBLE LTEXT "", IDC_TEXT_LINE + 2, 7, 75, 190, 10, SS_LEFT|SS_NOPREFIX } + +#pragma code_page(default) diff --git a/dlls/browseui/rsrc_Nl.rc b/dlls/browseui/rsrc_Nl.rc index c15f63128dd..06ee906818b 100644 --- a/dlls/browseui/rsrc_Nl.rc +++ b/dlls/browseui/rsrc_Nl.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL diff --git a/dlls/browseui/rsrc_No.rc b/dlls/browseui/rsrc_No.rc index dc980765782..88798cc9151 100644 --- a/dlls/browseui/rsrc_No.rc +++ b/dlls/browseui/rsrc_No.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL diff --git a/dlls/browseui/rsrc_Pl.rc b/dlls/browseui/rsrc_Pl.rc index 1677c03bd66..1f638904e1b 100644 --- a/dlls/browseui/rsrc_Pl.rc +++ b/dlls/browseui/rsrc_Pl.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" LANGUAGE LANG_POLISH, SUBLANG_DEFAULT diff --git a/dlls/browseui/rsrc_Pt.rc b/dlls/browseui/rsrc_Pt.rc index fe07405a062..a1f446cc10b 100644 --- a/dlls/browseui/rsrc_Pt.rc +++ b/dlls/browseui/rsrc_Pt.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL diff --git a/dlls/browseui/rsrc_Ro.rc b/dlls/browseui/rsrc_Ro.rc index 5da07e7582b..faf3afa1144 100644 --- a/dlls/browseui/rsrc_Ro.rc +++ b/dlls/browseui/rsrc_Ro.rc @@ -17,7 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL @@ -40,3 +39,5 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "&Renunță", IDCANCEL, 205, 65, 40, 15, WS_GROUP | WS_TABSTOP | WS_VISIBLE LTEXT "", IDC_TEXT_LINE + 2, 7, 75, 190, 10, SS_LEFT|SS_NOPREFIX } + +#pragma code_page(default) diff --git a/dlls/browseui/rsrc_Ru.rc b/dlls/browseui/rsrc_Ru.rc index 31c9ec04111..bab8e449287 100644 --- a/dlls/browseui/rsrc_Ru.rc +++ b/dlls/browseui/rsrc_Ru.rc @@ -16,16 +16,12 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" - -/* UTF-8 */ -#pragma code_page(65001) LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE { - IDS_CANCELLING "Отмена..." + IDS_CANCELLING "Îòìåíà..." } IDD_PROGRESS_DLG DIALOG 0, 0, 260, 85 @@ -37,6 +33,6 @@ FONT 8, "MS Shell Dlg" LTEXT "", IDC_TEXT_LINE, 7, 45, 250, 10, SS_LEFT|SS_NOPREFIX LTEXT "", IDC_TEXT_LINE + 1, 7, 55, 250, 10, SS_LEFT|SS_NOPREFIX CONTROL "", IDC_PROGRESS_BAR, PROGRESS_CLASSA, WS_BORDER, 7, 65, 190, 8 - PUSHBUTTON "&Отмена", IDCANCEL, 205, 65, 40, 15, WS_GROUP | WS_TABSTOP | WS_VISIBLE + PUSHBUTTON "&Îòìåíà", IDCANCEL, 205, 65, 40, 15, WS_GROUP | WS_TABSTOP | WS_VISIBLE LTEXT "", IDC_TEXT_LINE + 2, 7, 75, 190, 10, SS_LEFT|SS_NOPREFIX } diff --git a/dlls/browseui/rsrc_Si.rc b/dlls/browseui/rsrc_Si.rc index a4ca2ec0b9a..e4541f79f48 100644 --- a/dlls/browseui/rsrc_Si.rc +++ b/dlls/browseui/rsrc_Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -39,3 +37,5 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "&Prekliči", IDCANCEL, 205, 65, 40, 15, WS_GROUP | WS_TABSTOP | WS_VISIBLE LTEXT "", IDC_TEXT_LINE + 2, 7, 75, 190, 10, SS_LEFT|SS_NOPREFIX } + +#pragma code_page(default) diff --git a/dlls/browseui/rsrc_Sv.rc b/dlls/browseui/rsrc_Sv.rc index 544d62ba6c8..795f73728ae 100644 --- a/dlls/browseui/rsrc_Sv.rc +++ b/dlls/browseui/rsrc_Sv.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL diff --git a/dlls/browseui/rsrc_Zh.rc b/dlls/browseui/rsrc_Zh.rc index 52c067256c0..92a3e07b6d7 100644 --- a/dlls/browseui/rsrc_Zh.rc +++ b/dlls/browseui/rsrc_Zh.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resids.h" /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -62,3 +61,5 @@ FONT 9, "MS Shell Dlg" PUSHBUTTON "取消(&C)", IDCANCEL, 205, 65, 40, 15, WS_GROUP | WS_TABSTOP | WS_VISIBLE LTEXT "", IDC_TEXT_LINE + 2, 7, 75, 190, 10, SS_LEFT|SS_NOPREFIX } + +#pragma code_page(default) diff --git a/dlls/cabinet/tests/fdi.c b/dlls/cabinet/tests/fdi.c index 5d470fade4c..1fa38516e79 100644 --- a/dlls/cabinet/tests/fdi.c +++ b/dlls/cabinet/tests/fdi.c @@ -287,9 +287,10 @@ static void createTestFile(const CHAR *name) static void create_test_files(void) { - DWORD len; + int len; - len = GetCurrentDirectoryA(MAX_PATH, CURR_DIR); + GetCurrentDirectoryA(MAX_PATH, CURR_DIR); + len = lstrlenA(CURR_DIR); if(len && (CURR_DIR[len-1] == '\\')) CURR_DIR[len-1] = 0; @@ -608,6 +609,8 @@ static void test_FDICopy(void) char name[] = "extract.cab"; char path[MAX_PATH + 1]; + GetCurrentDirectoryA(MAX_PATH, path); + set_cab_parameters(&cabParams); hfci = FCICreate(&erf, file_placed, mem_alloc, mem_free, fci_open, @@ -619,31 +622,6 @@ static void test_FDICopy(void) FCIDestroy(hfci); - lstrcpyA(path, CURR_DIR); - - /* path doesn't have a trailing backslash */ - if (lstrlenA(path) > 2) - { - hfdi = FDICreate(fdi_alloc, fdi_free, fdi_open, fdi_read, - fdi_write, fdi_close, fdi_seek, - cpuUNKNOWN, &erf); - - SetLastError(0xdeadbeef); - ret = FDICopy(hfdi, name, path, 0, CopyProgress, NULL, 0); - ok(ret == FALSE, "Expected FALSE, got %d\n", ret); - todo_wine - { - ok(GetLastError() == ERROR_INVALID_HANDLE, - "Expected ERROR_INVALID_HANDLE, got %d\n", GetLastError()); - } - - FDIDestroy(hfdi); - } - else - skip("Running on a root drive directory.\n"); - - lstrcatA(path, "\\"); - hfdi = FDICreate(fdi_alloc, fdi_free, fdi_open, fdi_read, fdi_write, fdi_close, fdi_seek, cpuUNKNOWN, &erf); @@ -651,12 +629,14 @@ static void test_FDICopy(void) /* cabinet with no files or folders */ SetLastError(0xdeadbeef); ret = FDICopy(hfdi, name, path, 0, CopyProgress, NULL, 0); + ok(ret == FALSE, "Expected FALSE, got %d\n", ret); todo_wine - ok(ret == TRUE, "Expected TRUE, got %d\n", ret); - ok(GetLastError() == 0, "Expected 0f, got %d\n", GetLastError()); + { + ok(GetLastError() == ERROR_INVALID_HANDLE, + "Expected ERROR_INVALID_HANDLE, got %d\n", GetLastError()); + } FDIDestroy(hfdi); - DeleteFileA(name); } diff --git a/dlls/cards/Makefile.in b/dlls/cards/Makefile.in index 11ca3a8d378..93c53fc14e7 100644 --- a/dlls/cards/Makefile.in +++ b/dlls/cards/Makefile.in @@ -10,8 +10,7 @@ C_SRCS = \ cards.c RC_SRCS = \ - cards.rc \ - version.rc + cards.rc @MAKE_DLL_RULES@ diff --git a/dlls/cards/cards.rc b/dlls/cards/cards.rc index f881aa85e58..b4ef1de3132 100644 --- a/dlls/cards/cards.rc +++ b/dlls/cards/cards.rc @@ -240,3 +240,5 @@ unused2 BITMAP b2fv.bmp /* @makedep: theo.bmp */ 68 BITMAP theo.bmp + +#include "version.rc" diff --git a/dlls/comctl32/Makefile.in b/dlls/comctl32/Makefile.in index e6715f7cc85..ad96a505f51 100644 --- a/dlls/comctl32/Makefile.in +++ b/dlls/comctl32/Makefile.in @@ -46,34 +46,7 @@ C_SRCS = \ treeview.c \ updown.c -RC_SRCS = \ - comctl_Bg.rc \ - comctl_Cs.rc \ - comctl_De.rc \ - comctl_El.rc \ - comctl_En.rc \ - comctl_Eo.rc \ - comctl_Es.rc \ - comctl_Fr.rc \ - comctl_Hu.rc \ - comctl_It.rc \ - comctl_Ja.rc \ - comctl_Ko.rc \ - comctl_Lt.rc \ - comctl_Nl.rc \ - comctl_No.rc \ - comctl_Pl.rc \ - comctl_Pt.rc \ - comctl_Ro.rc \ - comctl_Ru.rc \ - comctl_Si.rc \ - comctl_Sk.rc \ - comctl_Sv.rc \ - comctl_Th.rc \ - comctl_Tr.rc \ - comctl_Uk.rc \ - comctl_Zh.rc \ - rsrc.rc +RC_SRCS = rsrc.rc @MAKE_DLL_RULES@ diff --git a/dlls/comctl32/comctl_Bg.rc b/dlls/comctl32/comctl_Bg.rc index 6c64f9ac0c8..94dd8703c64 100644 --- a/dlls/comctl32/comctl_Bg.rc +++ b/dlls/comctl32/comctl_Bg.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_Cs.rc b/dlls/comctl32/comctl_Cs.rc index e770e331e5c..63cc0bbc68b 100644 --- a/dlls/comctl32/comctl_Cs.rc +++ b/dlls/comctl32/comctl_Cs.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/dlls/comctl32/comctl_De.rc b/dlls/comctl32/comctl_De.rc index 4a94f238e23..831e2ee9b94 100644 --- a/dlls/comctl32/comctl_De.rc +++ b/dlls/comctl32/comctl_De.rc @@ -16,15 +16,11 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { - IDS_CLOSE "Schließen" + IDS_CLOSE "Schließen" } STRINGTABLE DISCARDABLE @@ -45,7 +41,7 @@ STRINGTABLE DISCARDABLE IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 STYLE DS_CONTEXTHELP | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE -CAPTION "Eigenschaften für %s" +CAPTION "Eigenschaften für %s" FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "&OK", IDOK,4,122,50,14, WS_TABSTOP | WS_GROUP @@ -61,7 +57,7 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE CAPTION "Wizard" FONT 8, "MS Shell Dlg" BEGIN - PUSHBUTTON "< &Zurück", IDC_BACK_BUTTON,71,138,50,14 + PUSHBUTTON "< &Zurück", IDC_BACK_BUTTON,71,138,50,14 DEFPUSHBUTTON "&Weiter >", IDC_NEXT_BUTTON,121,138,50,14 DEFPUSHBUTTON "&Beenden", IDC_FINISH_BUTTON,121,138,50,14 PUSHBUTTON "Abbrechen", IDCANCEL,178,138,50,14 @@ -77,15 +73,15 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Toolbar einrichten" FONT 8, "MS Shell Dlg" BEGIN - DEFPUSHBUTTON "&Schließen", IDCANCEL,308,6,44,14 - PUSHBUTTON "&Zurücksetzen", IDC_RESET_BTN,308,23,44,14 + DEFPUSHBUTTON "&Schließen", IDCANCEL,308,6,44,14 + PUSHBUTTON "&Zurücksetzen", IDC_RESET_BTN,308,23,44,14 PUSHBUTTON "&Hilfe", IDC_HELP_BTN,308,40,44,14 PUSHBUTTON "Nach &Oben verschieben", IDC_MOVEUP_BTN,308,74,44,14 PUSHBUTTON "Nach &Unten verschieben", IDC_MOVEDN_BTN,308,91,44,14 - LTEXT "&Vorhandene Knöpfe:", -1,4,5,84,10 + LTEXT "&Vorhandene Knöpfe:", -1,4,5,84,10 LISTBOX IDC_AVAILBTN_LBOX,4,17,120,100, LBS_NOTIFY | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT | LBS_DISABLENOSCROLL | WS_BORDER | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP - PUSHBUTTON "H&inzufügen ->", IDOK, 131, 42, 44, 14 - PUSHBUTTON "<- &Löschen", IDC_REMOVE_BTN,131,62,44,14 - LTEXT "&Toolbarknöpfe:", -1,182,5,78,10 + PUSHBUTTON "H&inzufügen ->", IDOK, 131, 42, 44, 14 + PUSHBUTTON "<- &Löschen", IDC_REMOVE_BTN,131,62,44,14 + LTEXT "&Toolbarknöpfe:", -1,182,5,78,10 LISTBOX IDC_TOOLBARBTN_LBOX, 182,17,120,100,LBS_NOTIFY | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT | LBS_DISABLENOSCROLL | WS_BORDER | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP END diff --git a/dlls/comctl32/comctl_El.rc b/dlls/comctl32/comctl_El.rc index de08357270d..a505620adfa 100644 --- a/dlls/comctl32/comctl_El.rc +++ b/dlls/comctl32/comctl_El.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_GREEK, SUBLANG_DEFAULT IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_En.rc b/dlls/comctl32/comctl_En.rc index d8055e98f3f..369eecd90ff 100644 --- a/dlls/comctl32/comctl_En.rc +++ b/dlls/comctl32/comctl_En.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_Eo.rc b/dlls/comctl32/comctl_Eo.rc index 59fe39ed8e8..bda181759f8 100644 --- a/dlls/comctl32/comctl_Eo.rc +++ b/dlls/comctl32/comctl_Eo.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_Es.rc b/dlls/comctl32/comctl_Es.rc index ce4621791f0..ea2968edcaa 100644 --- a/dlls/comctl32/comctl_Es.rc +++ b/dlls/comctl32/comctl_Es.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_Fr.rc b/dlls/comctl32/comctl_Fr.rc index 2fd2f89dde7..df56339f4c6 100644 --- a/dlls/comctl32/comctl_Fr.rc +++ b/dlls/comctl32/comctl_Fr.rc @@ -3,7 +3,7 @@ * French language support * * Copyright 1999 Eric Kohl - * Copyright 2003 Vincent Béron + * Copyright 2003 Vincent Béron * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -20,16 +20,11 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 STYLE DS_CONTEXTHELP | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE -CAPTION "Propriétés pour %s" +CAPTION "Propriétés pour %s" FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "OK", IDOK,4,122,50,14, WS_TABSTOP | WS_GROUP @@ -45,9 +40,9 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE CAPTION "Assistant" FONT 8, "MS Shell Dlg" BEGIN - PUSHBUTTON "< &Précédent", IDC_BACK_BUTTON,71,138,50,14 - DEFPUSHBUTTON "&Suivant >", IDC_NEXT_BUTTON,123,138,50,14 - DEFPUSHBUTTON "Terminer", IDC_FINISH_BUTTON,123,138,50,14 + PUSHBUTTON "< &Précédent", IDC_BACK_BUTTON,71,138,50,14 + DEFPUSHBUTTON "&Suivant >", IDC_NEXT_BUTTON,121,138,50,14 + DEFPUSHBUTTON "Terminer", IDC_FINISH_BUTTON,121,138,50,14 PUSHBUTTON "Annuler", IDCANCEL,178,138,50,14 PUSHBUTTON "Aide", IDHELP,235,138,50,14,WS_GROUP LTEXT "", IDC_SUNKEN_LINE,7,129,278,1,SS_SUNKEN @@ -62,15 +57,15 @@ CAPTION "Personnaliser la barre d'outils" FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "&Fermer", IDCANCEL,308,6,44,14 - PUSHBUTTON "&Réinitialiser", IDC_RESET_BTN,308,23,44,14 + PUSHBUTTON "&Réinitialiser", IDC_RESET_BTN,308,23,44,14 PUSHBUTTON "Aid&e", IDC_HELP_BTN,308,40,44,14 PUSHBUTTON "&Monter", IDC_MOVEUP_BTN,308,74,44,14 PUSHBUTTON "&Descendre", IDC_MOVEDN_BTN,308,91,44,14 - LTEXT "Boutons &disponibles :", -1,4,5,84,10 + LTEXT "Boutons disponibles :", -1,4,5,84,10 LISTBOX IDC_AVAILBTN_LBOX,4,17,120,100, LBS_NOTIFY | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT | LBS_DISABLENOSCROLL | WS_BORDER | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP PUSHBUTTON "A&jouter ->", IDOK, 131, 42, 44, 14 PUSHBUTTON "<- E&nlever", IDC_REMOVE_BTN,131,62,44,14 - LTEXT "&Boutons de la barre d'outils :", -1,182,5,93,10 + LTEXT "&Boutons de la barre d'outils :", -1,182,5,78,10 LISTBOX IDC_TOOLBARBTN_LBOX, 182,17,120,100,LBS_NOTIFY | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT | LBS_DISABLENOSCROLL | WS_BORDER | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP END @@ -82,12 +77,12 @@ STRINGTABLE DISCARDABLE STRINGTABLE DISCARDABLE { IDM_TODAY "Aujourd'hui:" - IDM_GOTODAY "Aller à aujourd'hui" + IDM_GOTODAY "Aller à aujourd'hui" } STRINGTABLE DISCARDABLE { - IDS_SEPARATOR "Séparateur" + IDS_SEPARATOR "Séparateur" } STRINGTABLE DISCARDABLE diff --git a/dlls/comctl32/comctl_Hu.rc b/dlls/comctl32/comctl_Hu.rc index 2ba1160efc1..6019777c1bd 100644 --- a/dlls/comctl32/comctl_Hu.rc +++ b/dlls/comctl32/comctl_Hu.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_It.rc b/dlls/comctl32/comctl_It.rc index 75bd9c19c4c..2b2f315589e 100644 --- a/dlls/comctl32/comctl_It.rc +++ b/dlls/comctl32/comctl_It.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_Ja.rc b/dlls/comctl32/comctl_Ja.rc index 3262f33e6d9..e3c1272f29a 100644 --- a/dlls/comctl32/comctl_Ja.rc +++ b/dlls/comctl32/comctl_Ja.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - /* UTF-8 */ #pragma code_page(65001) @@ -90,3 +88,5 @@ STRINGTABLE DISCARDABLE { HKY_NONE "None" } + +#pragma code_page(default) diff --git a/dlls/comctl32/comctl_Ko.rc b/dlls/comctl32/comctl_Ko.rc index daf9917e62a..6574b66a74e 100644 --- a/dlls/comctl32/comctl_Ko.rc +++ b/dlls/comctl32/comctl_Ko.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_Lt.rc b/dlls/comctl32/comctl_Lt.rc index f5f329429cb..bfe0986d749 100644 --- a/dlls/comctl32/comctl_Lt.rc +++ b/dlls/comctl32/comctl_Lt.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - /* UTF-8 */ #pragma code_page(65001) @@ -90,3 +88,5 @@ STRINGTABLE DISCARDABLE { HKY_NONE "Joks" } + +#pragma code_page(default) diff --git a/dlls/comctl32/comctl_Nl.rc b/dlls/comctl32/comctl_Nl.rc index c89403d328f..a277b0f6cb9 100644 --- a/dlls/comctl32/comctl_Nl.rc +++ b/dlls/comctl32/comctl_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_No.rc b/dlls/comctl32/comctl_No.rc index 6361f048943..77b9ec8da70 100644 --- a/dlls/comctl32/comctl_No.rc +++ b/dlls/comctl32/comctl_No.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_Pl.rc b/dlls/comctl32/comctl_Pl.rc index 12f13a63fa1..91441344597 100644 --- a/dlls/comctl32/comctl_Pl.rc +++ b/dlls/comctl32/comctl_Pl.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_Pt.rc b/dlls/comctl32/comctl_Pt.rc index 914c4c22439..3ab75fda596 100644 --- a/dlls/comctl32/comctl_Pt.rc +++ b/dlls/comctl32/comctl_Pt.rc @@ -1,7 +1,6 @@ /* * Copyright 2003 Marcelo Duarte - * Copyright 2006-2007 Américo José Melo - * Copyright 2009 Ricardo Filipe + * Copyright 2006-2007 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 @@ -18,11 +17,21 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN -#pragma code_page(65001) +IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 +STYLE DS_CONTEXTHELP | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE +CAPTION "Propriedades para %s" +FONT 8, "MS Shell Dlg" +BEGIN + DEFPUSHBUTTON "OK", IDOK,4,122,50,14, WS_TABSTOP | WS_GROUP + PUSHBUTTON "Cancelar", IDCANCEL,58,122,50,14 + PUSHBUTTON "&Aplicar", IDC_APPLY_BUTTON,112,122,50,14,WS_DISABLED + PUSHBUTTON "Ajuda", IDHELP,166,122,50,14,WS_TABSTOP|WS_GROUP + CONTROL "Tab", IDC_TABCONTROL,"SysTabControl32",WS_CLIPSIBLINGS|WS_GROUP|WS_TABSTOP|TCS_MULTILINE,4,4,212,114 +END -LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 STYLE DS_CONTEXTHELP | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE @@ -36,21 +45,27 @@ BEGIN CONTROL "Separador", IDC_TABCONTROL,"SysTabControl32",WS_CLIPSIBLINGS|WS_GROUP|WS_TABSTOP|TCS_MULTILINE,4,4,212,114 END + +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN + IDD_WIZARD DIALOG DISCARDABLE 0, 0, 290, 159 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE CAPTION "Assistente" FONT 8, "MS Shell Dlg" BEGIN PUSHBUTTON "< &Voltar", IDC_BACK_BUTTON,71,138,50,14 - DEFPUSHBUTTON "&Avançar >", IDC_NEXT_BUTTON,121,138,50,14 + DEFPUSHBUTTON "&Avançar >", IDC_NEXT_BUTTON,121,138,50,14 DEFPUSHBUTTON "Finalizar", IDC_FINISH_BUTTON,121,138,50,14 PUSHBUTTON "Cancelar", IDCANCEL,178,138,50,14 PUSHBUTTON "Ajuda", IDHELP,235,138,50,14,WS_GROUP LTEXT "", IDC_SUNKEN_LINE,7,129,278,1,SS_SUNKEN - CONTROL "Separador", IDC_TABCONTROL,"SysTabControl32",WS_CLIPSIBLINGS | WS_DISABLED,7,7,258,5 + CONTROL "Tab", IDC_TABCONTROL,"SysTabControl32",WS_CLIPSIBLINGS | WS_DISABLED,7,7,258,5 LTEXT "", IDC_SUNKEN_LINEHEADER,0,35,290,1,SS_LEFT | SS_SUNKEN | WS_CHILD | WS_VISIBLE END + +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN + IDD_TBCUSTOMIZE DIALOG DISCARDABLE 10, 20, 357, 125 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Personalizar barra de ferramentas" @@ -61,30 +76,42 @@ BEGIN PUSHBUTTON "&Ajuda", IDC_HELP_BTN,308,40,44,14 PUSHBUTTON "A&cima", IDC_MOVEUP_BTN,308,74,44,14 PUSHBUTTON "A&baixo", IDC_MOVEDN_BTN,308,91,44,14 - LTEXT "Botões &disponíveis:", -1,4,5,84,10 + LTEXT "Botões &disponíveis:", -1,4,5,84,10 LISTBOX IDC_AVAILBTN_LBOX,4,17,120,100, LBS_NOTIFY | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT | LBS_DISABLENOSCROLL | WS_BORDER | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP PUSHBUTTON "&Adicionar ->", IDOK, 131, 42, 44, 14 PUSHBUTTON "<- &Remover", IDC_REMOVE_BTN,131,62,44,14 - LTEXT "&Botões da barra de ferramentas:", -1,182,5,78,10 + LTEXT "&Botões da barra de ferramentas:", -1,182,5,78,10 LISTBOX IDC_TOOLBARBTN_LBOX, 182,17,120,100,LBS_NOTIFY | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT | LBS_DISABLENOSCROLL | WS_BORDER | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP END + +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN + STRINGTABLE DISCARDABLE { IDS_CLOSE "Fechar" } + +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN + STRINGTABLE DISCARDABLE { IDM_TODAY "Hoje:" IDM_GOTODAY "Ir para hoje" } + +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN + STRINGTABLE DISCARDABLE { IDS_SEPARATOR "Separador" } + +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN + STRINGTABLE DISCARDABLE { HKY_NONE "Nenhum" diff --git a/dlls/comctl32/comctl_Ro.rc b/dlls/comctl32/comctl_Ro.rc index 497f626ee5b..0581d0dadbd 100644 --- a/dlls/comctl32/comctl_Ro.rc +++ b/dlls/comctl32/comctl_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -90,3 +88,5 @@ STRINGTABLE DISCARDABLE { HKY_NONE "Nimic" } + +#pragma code_page(default) diff --git a/dlls/comctl32/comctl_Ru.rc b/dlls/comctl32/comctl_Ru.rc index 9cba44d1b62..2bbb513a09c 100644 --- a/dlls/comctl32/comctl_Ru.rc +++ b/dlls/comctl32/comctl_Ru.rc @@ -18,36 +18,31 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 STYLE DS_CONTEXTHELP | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE -CAPTION "Свойства для %s" +CAPTION "Ñâîéñòâà äëÿ %s" FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "OK", IDOK,4,122,50,14, WS_TABSTOP | WS_GROUP - PUSHBUTTON "Отмена", IDCANCEL,58,122,50,14 - PUSHBUTTON "При&менить", IDC_APPLY_BUTTON,112,122,50,14,WS_DISABLED - PUSHBUTTON "&Справка", IDHELP,166,122,50,14,WS_TABSTOP|WS_GROUP + PUSHBUTTON "Îòìåíà", IDCANCEL,58,122,50,14 + PUSHBUTTON "Ïðè&ìåíèòü", IDC_APPLY_BUTTON,112,122,50,14,WS_DISABLED + PUSHBUTTON "&Ñïðàâêà", IDHELP,166,122,50,14,WS_TABSTOP|WS_GROUP CONTROL "Tab", IDC_TABCONTROL,"SysTabControl32",WS_CLIPSIBLINGS|WS_GROUP|WS_TABSTOP|TCS_MULTILINE,4,4,212,114 END IDD_WIZARD DIALOG DISCARDABLE 0, 0, 290, 159 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE -CAPTION "Мастер" +CAPTION "Ìàñòåð" FONT 8, "MS Shell Dlg" BEGIN - PUSHBUTTON "< &Назад", IDC_BACK_BUTTON,71,138,50,14 - DEFPUSHBUTTON "&Далее >", IDC_NEXT_BUTTON,121,138,50,14 - DEFPUSHBUTTON "Готово", IDC_FINISH_BUTTON,121,138,50,14 - PUSHBUTTON "Отмена", IDCANCEL,178,138,50,14 - PUSHBUTTON "&Справка", IDHELP,235,138,50,14,WS_GROUP + PUSHBUTTON "< &Íàçàä", IDC_BACK_BUTTON,71,138,50,14 + DEFPUSHBUTTON "&Äàëåå >", IDC_NEXT_BUTTON,121,138,50,14 + DEFPUSHBUTTON "Ãîòîâî", IDC_FINISH_BUTTON,121,138,50,14 + PUSHBUTTON "Îòìåíà", IDCANCEL,178,138,50,14 + PUSHBUTTON "&Ñïðàâêà", IDHELP,235,138,50,14,WS_GROUP LTEXT "", IDC_SUNKEN_LINE,7,129,278,1,SS_SUNKEN CONTROL "Tab", IDC_TABCONTROL,"SysTabControl32",WS_CLIPSIBLINGS | WS_DISABLED,7,7,258,5 LTEXT "", IDC_SUNKEN_LINEHEADER,0,35,290,1,SS_LEFT | SS_SUNKEN | WS_CHILD | WS_VISIBLE @@ -56,39 +51,39 @@ END IDD_TBCUSTOMIZE DIALOG DISCARDABLE 10, 20, 357, 125 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Настройка панели инструментов" +CAPTION "Íàñòðîéêà ïàíåëè èíñòðóìåíòîâ" FONT 8, "MS Shell Dlg" BEGIN - DEFPUSHBUTTON "&Закрыть", IDCANCEL,308,6,44,14 - PUSHBUTTON "С&бросить", IDC_RESET_BTN,308,23,44,14 - PUSHBUTTON "&Справка", IDC_HELP_BTN,308,40,44,14 - PUSHBUTTON "Переместить &вверх", IDC_MOVEUP_BTN,308,74,44,14 - PUSHBUTTON "Переместить &вниз", IDC_MOVEDN_BTN,308,91,44,14 - LTEXT "&Доступные кнопки:", -1,4,5,84,10 + DEFPUSHBUTTON "&Çàêðûòü", IDCANCEL,308,6,44,14 + PUSHBUTTON "Ñ&áðîñèòü", IDC_RESET_BTN,308,23,44,14 + PUSHBUTTON "&Ñïðàâêà", IDC_HELP_BTN,308,40,44,14 + PUSHBUTTON "Ïåðåìåñòèòü &ââåðõ", IDC_MOVEUP_BTN,308,74,44,14 + PUSHBUTTON "Ïåðåìåñòèòü &âíèç", IDC_MOVEDN_BTN,308,91,44,14 + LTEXT "&Äîñòóïíûå êíîïêè:", -1,4,5,84,10 LISTBOX IDC_AVAILBTN_LBOX,4,17,120,100, LBS_NOTIFY | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT | LBS_DISABLENOSCROLL | WS_BORDER | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP - PUSHBUTTON "&Добавить ->", IDOK, 131, 42, 44, 14 - PUSHBUTTON "<- &Удалить", IDC_REMOVE_BTN,131,62,44,14 - LTEXT "&Кнопки панели инструментов:", -1,182,5,78,10 + PUSHBUTTON "&Äîáàâèòü ->", IDOK, 131, 42, 44, 14 + PUSHBUTTON "<- &Óäàëèòü", IDC_REMOVE_BTN,131,62,44,14 + LTEXT "&Êíîïêè ïàíåëè èíñòðóìåíòîâ:", -1,182,5,78,10 LISTBOX IDC_TOOLBARBTN_LBOX, 182,17,120,100,LBS_NOTIFY | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT | LBS_DISABLENOSCROLL | WS_BORDER | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP END STRINGTABLE DISCARDABLE { - IDS_CLOSE "Закрыть" + IDS_CLOSE "Çàêðûòü" } STRINGTABLE DISCARDABLE { - IDM_TODAY "Сегодня:" - IDM_GOTODAY "Текущая дата" + IDM_TODAY "Ñåãîäíÿ:" + IDM_GOTODAY "Òåêóùàÿ äàòà" } STRINGTABLE DISCARDABLE { - IDS_SEPARATOR "Разделитель" + IDS_SEPARATOR "Ðàçäåëèòåëü" } STRINGTABLE DISCARDABLE { - HKY_NONE "Нет" + HKY_NONE "Íåò" } diff --git a/dlls/comctl32/comctl_Si.rc b/dlls/comctl32/comctl_Si.rc index cc1053f18f6..aa9a7b69975 100644 --- a/dlls/comctl32/comctl_Si.rc +++ b/dlls/comctl32/comctl_Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -89,3 +87,5 @@ STRINGTABLE DISCARDABLE { HKY_NONE "Brez" } + +#pragma code_page(default) diff --git a/dlls/comctl32/comctl_Sk.rc b/dlls/comctl32/comctl_Sk.rc index c543e376f30..fb5f65dcfa0 100644 --- a/dlls/comctl32/comctl_Sk.rc +++ b/dlls/comctl32/comctl_Sk.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - /* Slovak strings in CP1250 */ LANGUAGE LANG_SLOVAK, SUBLANG_DEFAULT diff --git a/dlls/comctl32/comctl_Sv.rc b/dlls/comctl32/comctl_Sv.rc index 18bfefc6635..2037d797c24 100644 --- a/dlls/comctl32/comctl_Sv.rc +++ b/dlls/comctl32/comctl_Sv.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_Th.rc b/dlls/comctl32/comctl_Th.rc index ff1e1fa4feb..3195e1b9a55 100644 --- a/dlls/comctl32/comctl_Th.rc +++ b/dlls/comctl32/comctl_Th.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_THAI, SUBLANG_DEFAULT IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_Tr.rc b/dlls/comctl32/comctl_Tr.rc index cdc89ca0533..c0f65127f9d 100644 --- a/dlls/comctl32/comctl_Tr.rc +++ b/dlls/comctl32/comctl_Tr.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_Uk.rc b/dlls/comctl32/comctl_Uk.rc index 608697da80a..95e502dd471 100644 --- a/dlls/comctl32/comctl_Uk.rc +++ b/dlls/comctl32/comctl_Uk.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - LANGUAGE LANG_UKRAINIAN, SUBLANG_DEFAULT IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 diff --git a/dlls/comctl32/comctl_Zh.rc b/dlls/comctl32/comctl_Zh.rc index 8919119cae9..b6c5692dea6 100644 --- a/dlls/comctl32/comctl_Zh.rc +++ b/dlls/comctl32/comctl_Zh.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "comctl32.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -163,3 +161,5 @@ STRINGTABLE DISCARDABLE { HKY_NONE "無" } + +#pragma code_page(default) diff --git a/dlls/comctl32/dpa.c b/dlls/comctl32/dpa.c index 43f2a3adf61..bbad10df8d0 100644 --- a/dlls/comctl32/dpa.c +++ b/dlls/comctl32/dpa.c @@ -802,8 +802,7 @@ INT WINAPI DPA_Search (const HDPA hdpa, LPVOID pFind, INT nStart, INT l, r, x, n; LPVOID *lpPtr; - /* for binary search ignore start index */ - l = 0; + l = (nStart == -1) ? 0 : nStart; r = hdpa->nItemCount - 1; lpPtr = hdpa->ptrs; while (r >= l) { diff --git a/dlls/comctl32/header.c b/dlls/comctl32/header.c index 7c8f161a17e..fed582d945c 100644 --- a/dlls/comctl32/header.c +++ b/dlls/comctl32/header.c @@ -247,7 +247,8 @@ HEADER_SetItemBounds (HEADER_INFO *infoPtr) static LRESULT HEADER_Size (HEADER_INFO *infoPtr) { - HEADER_SetItemBounds(infoPtr); + infoPtr->bRectsValid = FALSE; + return 0; } @@ -328,21 +329,18 @@ HEADER_DrawItem (HEADER_INFO *infoPtr, HDC hdc, INT iItem, BOOL bHotTrack, LRESU } else { HBRUSH hbr; - - if (!(infoPtr->dwStyle & HDS_FLAT)) - { - if (infoPtr->dwStyle & HDS_BUTTONS) { - if (phdi->bDown) { - DrawEdge (hdc, &r, BDR_RAISEDOUTER, - BF_RECT | BF_FLAT | BF_MIDDLE | BF_ADJUST); - } - else - DrawEdge (hdc, &r, EDGE_RAISED, - BF_RECT | BF_SOFT | BF_MIDDLE | BF_ADJUST); + + if (infoPtr->dwStyle & HDS_BUTTONS) { + if (phdi->bDown) { + DrawEdge (hdc, &r, BDR_RAISEDOUTER, + BF_RECT | BF_FLAT | BF_MIDDLE | BF_ADJUST); } else - DrawEdge (hdc, &r, EDGE_ETCHED, BF_BOTTOM | BF_RIGHT | BF_ADJUST); + DrawEdge (hdc, &r, EDGE_RAISED, + BF_RECT | BF_SOFT | BF_MIDDLE | BF_ADJUST); } + else + DrawEdge (hdc, &r, EDGE_ETCHED, BF_BOTTOM | BF_RIGHT | BF_ADJUST); hbr = CreateSolidBrush(GetBkColor(hdc)); FillRect(hdc, &r, hbr); @@ -549,19 +547,14 @@ HEADER_Refresh (HEADER_INFO *infoPtr, HDC hdc) if (theme != NULL) { DrawThemeBackground(theme, hdc, HP_HEADERITEM, HIS_NORMAL, &rcRest, NULL); } - else if (infoPtr->dwStyle & HDS_FLAT) { - hbrBk = GetSysColorBrush(COLOR_3DFACE); - FillRect(hdc, &rcRest, hbrBk); - } - else - { + else { if (infoPtr->dwStyle & HDS_BUTTONS) DrawEdge (hdc, &rcRest, EDGE_RAISED, BF_TOP|BF_LEFT|BF_BOTTOM|BF_SOFT|BF_MIDDLE); else DrawEdge (hdc, &rcRest, EDGE_ETCHED, BF_BOTTOM|BF_MIDDLE); } } - + if (infoPtr->iHotDivider != -1) HEADER_DrawHotDivider(infoPtr, hdc); @@ -1209,7 +1202,7 @@ HEADER_SetOrderArray(HEADER_INFO *infoPtr, INT size, const INT *order) lpItem = &infoPtr->items[*order++]; lpItem->iOrder=i; } - HEADER_SetItemBounds(infoPtr); + infoPtr->bRectsValid=0; InvalidateRect(infoPtr->hwndSelf, NULL, FALSE); return TRUE; } @@ -1224,12 +1217,10 @@ HEADER_GetUnicodeFormat (const HEADER_INFO *infoPtr) static LRESULT HEADER_HitTest (const HEADER_INFO *infoPtr, LPHDHITTESTINFO phti) { - UINT outside = HHT_NOWHERE | HHT_ABOVE | HHT_BELOW | HHT_TOLEFT | HHT_TORIGHT; - HEADER_InternalHitTest (infoPtr, &phti->pt, &phti->flags, &phti->iItem); - if (phti->flags & outside) - return phti->iItem = -1; + if (phti->flags == HHT_NOWHERE) + return -1; else return phti->iItem; } @@ -1591,9 +1582,6 @@ HEADER_LButtonUp (HEADER_INFO *infoPtr, INT x, INT y) HEADER_InternalHitTest (infoPtr, &pt, &flags, &nItem); if (infoPtr->bPressed) { - - infoPtr->items[infoPtr->iMoveItem].bDown = FALSE; - if (infoPtr->bDragging) { HEADER_ITEM *lpItem = &infoPtr->items[infoPtr->iMoveItem]; @@ -1601,7 +1589,8 @@ HEADER_LButtonUp (HEADER_INFO *infoPtr, INT x, INT y) ImageList_DragShowNolock(FALSE); ImageList_EndDrag(); - + lpItem->bDown=FALSE; + if (infoPtr->iHotDivider == -1) iNewOrder = -1; else if (infoPtr->iHotDivider == infoPtr->uNumItem) @@ -1626,14 +1615,14 @@ HEADER_LButtonUp (HEADER_INFO *infoPtr, INT x, INT y) infoPtr->bDragging = FALSE; HEADER_SetHotDivider(infoPtr, FALSE, -1); } - else + else if (!(infoPtr->dwStyle & HDS_DRAGDROP) || !HEADER_IsDragDistance(infoPtr, &pt)) { + infoPtr->items[infoPtr->iMoveItem].bDown = FALSE; hdc = GetDC (infoPtr->hwndSelf); HEADER_RefreshItem (infoPtr, infoPtr->iMoveItem); ReleaseDC (infoPtr->hwndSelf, hdc); - if (!(infoPtr->dwStyle & HDS_DRAGDROP) || !HEADER_IsDragDistance(infoPtr, &pt)) - HEADER_SendNotifyWithHDItemT(infoPtr, HDN_ITEMCLICKW, infoPtr->iMoveItem, NULL); + HEADER_SendNotifyWithHDItemT(infoPtr, HDN_ITEMCLICKW, infoPtr->iMoveItem, NULL); } TRACE("Released item %d!\n", infoPtr->iMoveItem); diff --git a/dlls/comctl32/listview.c b/dlls/comctl32/listview.c index 07133086af2..ebf49c622eb 100644 --- a/dlls/comctl32/listview.c +++ b/dlls/comctl32/listview.c @@ -106,6 +106,7 @@ * -- LVN_BEGINRDRAG * * Messages: + * -- LVM_CANCELEDITLABEL * -- LVM_ENABLEGROUPVIEW * -- LVM_GETBKIMAGE, LVM_SETBKIMAGE * -- LVM_GETGROUPINFO, LVM_SETGROUPINFO @@ -124,6 +125,7 @@ * -- LVM_INSERTGROUPSORTED * -- LVM_INSERTMARKHITTEST * -- LVM_ISGROUPVIEWENABLED + * -- LVM_MAPIDTOINDEX, LVM_MAPINDEXTOID * -- LVM_MOVEGROUP * -- LVM_MOVEITEMTOGROUP * -- LVM_SETINFOTIP @@ -193,23 +195,14 @@ typedef struct tagSUBITEM_INFO INT iSubItem; } SUBITEM_INFO; -typedef struct tagITEM_ID ITEM_ID; - typedef struct tagITEM_INFO { ITEMHDR hdr; UINT state; LPARAM lParam; INT iIndent; - ITEM_ID *id; } ITEM_INFO; -struct tagITEM_ID -{ - UINT id; /* item id */ - HDPA item; /* link to item data */ -}; - typedef struct tagRANGE { INT lower; @@ -286,7 +279,6 @@ typedef struct tagLISTVIEW_INFO DWORD uView; /* current view available through LVM_[G,S]ETVIEW */ INT nItemCount; /* the number of items in the list */ HDPA hdpaItems; /* array ITEM_INFO pointers */ - HDPA hdpaItemIds; /* array of ITEM_ID pointers */ HDPA hdpaPosX; /* maintains the (X, Y) coordinates of the */ HDPA hdpaPosY; /* items in LVS_ICON, and LVS_SMALLICON modes */ HDPA hdpaColumns; /* array of COLUMN_INFO pointers */ @@ -360,8 +352,6 @@ typedef struct tagLISTVIEW_INFO /* default label width for items in list and small icon display modes */ #define DEFAULT_LABEL_WIDTH 40 -/* maximum select rectangle width for empty text item in LV_VIEW_DETAILS */ -#define MAX_EMPTYTEXT_SELECT_WIDTH 80 /* default column width for items in list display mode */ #define DEFAULT_COLUMN_WIDTH 128 @@ -429,7 +419,6 @@ static BOOL LISTVIEW_EnsureVisible(LISTVIEW_INFO *, INT, BOOL); static HWND CreateEditLabelT(LISTVIEW_INFO *, LPCWSTR, DWORD, BOOL); static HIMAGELIST LISTVIEW_SetImageList(LISTVIEW_INFO *, INT, HIMAGELIST); static INT LISTVIEW_HitTest(const LISTVIEW_INFO *, LPLVHITTESTINFO, BOOL, BOOL); -static BOOL LISTVIEW_EndEditLabelT(LISTVIEW_INFO *, BOOL, BOOL); /******** Text handling functions *************************************/ @@ -761,7 +750,6 @@ static LRESULT notify_forward_header(const LISTVIEW_INFO *infoPtr, const NMHEADE /* convert item text */ if (lpnmh->pitem->mask & HDI_TEXT) { - hditema.pszText = NULL; Str_SetPtrWtoA(&hditema.pszText, lpnmh->pitem->pszText); text = hditema.pszText; } @@ -771,7 +759,6 @@ static LRESULT notify_forward_header(const LISTVIEW_INFO *infoPtr, const NMHEADE { hditema.pvFilter = &textfilter; textfilter = *(HD_TEXTFILTERA*)(lpnmh->pitem->pvFilter); - textfilter.pszText = NULL; Str_SetPtrWtoA(&textfilter.pszText, ((HD_TEXTFILTERW*)lpnmh->pitem->pvFilter)->pszText); filter = textfilter.pszText; } @@ -1031,25 +1018,6 @@ static inline DWORD notify_postpaint (const LISTVIEW_INFO *infoPtr, NMLVCUSTOMDR return notify_customdraw(infoPtr, CDDS_POSTPAINT, lpnmlvcd); } -/* returns TRUE when repaint needed, FALSE otherwise */ -static BOOL notify_measureitem(LISTVIEW_INFO *infoPtr) -{ - MEASUREITEMSTRUCT mis; - mis.CtlType = ODT_LISTVIEW; - mis.CtlID = GetWindowLongPtrW(infoPtr->hwndSelf, GWLP_ID); - mis.itemID = -1; - mis.itemWidth = 0; - mis.itemData = 0; - mis.itemHeight= infoPtr->nItemHeight; - SendMessageW(infoPtr->hwndNotify, WM_MEASUREITEM, mis.CtlID, (LPARAM)&mis); - if (infoPtr->nItemHeight != max(mis.itemHeight, 1)) - { - infoPtr->nMeasureItemHeight = infoPtr->nItemHeight = max(mis.itemHeight, 1); - return TRUE; - } - return FALSE; -} - /******** Item iterator functions **********************************/ static RANGES ranges_create(int count); @@ -1462,19 +1430,6 @@ static inline void map_style_view(LISTVIEW_INFO *infoPtr) } } -/* computes next item id value */ -static DWORD get_next_itemid(const LISTVIEW_INFO *infoPtr) -{ - INT count = DPA_GetPtrCount(infoPtr->hdpaItemIds); - - if (count > 0) - { - ITEM_ID *lpID = DPA_GetPtr(infoPtr->hdpaItemIds, count - 1); - return lpID->id + 1; - } - return 0; -} - /******** Internal API functions ************************************/ static inline COLUMN_INFO * LISTVIEW_GetColumnInfo(const LISTVIEW_INFO *infoPtr, INT nSubItem) @@ -2237,9 +2192,7 @@ static void LISTVIEW_GetItemMetrics(const LISTVIEW_INFO *infoPtr, const LVITEMW DrawTextW (hdc, lpLVItem->pszText, -1, &rcText, uFormat | DT_CALCRECT); - if (rcText.right != rcText.left) - labelSize.cx = min(rcText.right - rcText.left + TRAILING_LABEL_PADDING, infoPtr->nItemWidth); - + labelSize.cx = min(rcText.right - rcText.left + TRAILING_LABEL_PADDING, infoPtr->nItemWidth); labelSize.cy = rcText.bottom - rcText.top; SelectObject(hdc, hOldFont); @@ -2292,11 +2245,7 @@ calc_label: SelectBox.left = Icon.left; SelectBox.top = Box.top; SelectBox.bottom = Box.bottom; - - if (labelSize.cx) - SelectBox.right = min(Label.left + labelSize.cx, Label.right); - else - SelectBox.right = min(Label.left + MAX_EMPTYTEXT_SELECT_WIDTH, Label.right); + SelectBox.right = min(Label.left + labelSize.cx, Label.right); } else { @@ -2361,76 +2310,6 @@ static void LISTVIEW_GetItemBox(const LISTVIEW_INFO *infoPtr, INT nItem, LPRECT OffsetRect(lprcBox, Position.x + Origin.x, Position.y + Origin.y); } -/* LISTVIEW_MapIdToIndex helper */ -static INT CALLBACK MapIdSearchCompare(LPVOID p1, LPVOID p2, LPARAM lParam) -{ - ITEM_ID *id1 = (ITEM_ID*)p1; - ITEM_ID *id2 = (ITEM_ID*)p2; - - if (id1->id == id2->id) return 0; - - return (id1->id < id2->id) ? -1 : 1; -} - -/*** - * DESCRIPTION: - * Returns the item index for id specified. - * - * PARAMETER(S): - * [I] infoPtr : valid pointer to the listview structure - * [I] iID : item id to get index for - * - * RETURN: - * Item index, or -1 on failure. - */ -static INT LISTVIEW_MapIdToIndex(const LISTVIEW_INFO *infoPtr, UINT iID) -{ - ITEM_ID ID; - INT index; - - TRACE("iID=%d\n", iID); - - if (infoPtr->dwStyle & LVS_OWNERDATA) return -1; - if (infoPtr->nItemCount == 0) return -1; - - ID.id = iID; - index = DPA_Search(infoPtr->hdpaItemIds, &ID, -1, &MapIdSearchCompare, 0, DPAS_SORTED); - - if (index != -1) - { - ITEM_ID *lpID = DPA_GetPtr(infoPtr->hdpaItemIds, index); - return DPA_GetPtrIndex(infoPtr->hdpaItems, lpID->item); - } - - return -1; -} - -/*** - * DESCRIPTION: - * Returns the item id for index given. - * - * PARAMETER(S): - * [I] infoPtr : valid pointer to the listview structure - * [I] iItem : item index to get id for - * - * RETURN: - * Item id. - */ -static DWORD LISTVIEW_MapIndexToId(const LISTVIEW_INFO *infoPtr, INT iItem) -{ - ITEM_INFO *lpItem; - HDPA hdpaSubItems; - - TRACE("iItem=%d\n", iItem); - - if (infoPtr->dwStyle & LVS_OWNERDATA) return -1; - if (iItem < 0 || iItem >= infoPtr->nItemCount) return -1; - - hdpaSubItems = DPA_GetPtr(infoPtr->hdpaItems, iItem); - lpItem = DPA_GetPtr(hdpaSubItems, 0); - - return lpItem->id->id; -} /*** * DESCRIPTION: @@ -4120,45 +3999,6 @@ static BOOL LISTVIEW_DrawItem(LISTVIEW_INFO *infoPtr, HDC hdc, INT nItem, INT nS if (nSubItem && infoPtr->uView == LV_VIEW_DETAILS && (infoPtr->dwLvExStyle & LVS_EX_FULLROWSELECT)) nmlvcd.clrTextBk = CLR_NONE; - /* FIXME: temporary hack */ - rcSelect.left = rcLabel.left; - - /* draw the selection background, if we're drawing the main item */ - if (nSubItem == 0) - { - /* in icon mode, the label rect is really what we want to draw the - * background for */ - if (infoPtr->uView == LV_VIEW_ICON) - rcSelect = rcLabel; - - if (infoPtr->uView == LV_VIEW_DETAILS && (infoPtr->dwLvExStyle & LVS_EX_FULLROWSELECT)) - { - /* we have to update left focus bound too if item isn't in leftmost column - and reduce right box bound */ - if (DPA_GetPtrCount(infoPtr->hdpaColumns) > 0) - { - INT leftmost; - - if ((leftmost = SendMessageW(infoPtr->hwndHeader, HDM_ORDERTOINDEX, 0, 0))) - { - INT Originx = pos.x - LISTVIEW_GetColumnInfo(infoPtr, 0)->rcHeader.left; - INT index = SendMessageW(infoPtr->hwndHeader, HDM_ORDERTOINDEX, - DPA_GetPtrCount(infoPtr->hdpaColumns) - 1, 0); - - rcBox.right = LISTVIEW_GetColumnInfo(infoPtr, index)->rcHeader.right + Originx; - rcSelect.left = LISTVIEW_GetColumnInfo(infoPtr, leftmost)->rcHeader.left + Originx; - } - } - - rcSelect.right = rcBox.right; - } - - if (nmlvcd.clrTextBk != CLR_NONE) - ExtTextOutW(hdc, rcSelect.left, rcSelect.top, ETO_OPAQUE, &rcSelect, NULL, 0, NULL); - /* store new focus rectangle */ - if (infoPtr->nFocusedItem == nItem) infoPtr->rcFocus = rcSelect; - } - /* state icons */ if (infoPtr->himlState && STATEIMAGEINDEX(lvItem.state) && (nSubItem == 0)) { @@ -4183,6 +4023,26 @@ static BOOL LISTVIEW_DrawItem(LISTVIEW_INFO *infoPtr, HDC hdc, INT nItem, INT nS /* Don't bother painting item being edited */ if (infoPtr->hwndEdit && nItem == infoPtr->nEditLabelItem && nSubItem == 0) goto postpaint; + + /* FIXME: temporary hack */ + rcSelect.left = rcLabel.left; + + /* draw the selection background, if we're drawing the main item */ + if (nSubItem == 0) + { + /* in icon mode, the label rect is really what we want to draw the + * background for */ + if (infoPtr->uView == LV_VIEW_ICON) + rcSelect = rcLabel; + + if (infoPtr->uView == LV_VIEW_DETAILS && (infoPtr->dwLvExStyle & LVS_EX_FULLROWSELECT)) + rcSelect.right = rcBox.right; + + if (nmlvcd.clrTextBk != CLR_NONE) + ExtTextOutW(hdc, rcSelect.left, rcSelect.top, ETO_OPAQUE, &rcSelect, 0, 0, 0); + /* store new focus rectangle */ + if (infoPtr->nFocusedItem == nItem) infoPtr->rcFocus = rcSelect; + } /* figure out the text drawing flags */ uFormat = (infoPtr->uView == LV_VIEW_ICON ? (lprcFocus ? LV_FL_DT_FLAGS : LV_ML_DT_FLAGS) : LV_SL_DT_FLAGS); @@ -4731,26 +4591,6 @@ static DWORD LISTVIEW_ApproximateViewRect(const LISTVIEW_INFO *infoPtr, INT nIte return dwViewRect; } -/*** - * DESCRIPTION: - * Cancel edit label with saving item text. - * - * PARAMETER(S): - * [I] infoPtr : valid pointer to the listview structure - * - * RETURN: - * Always returns TRUE. - */ -static LRESULT LISTVIEW_CancelEditLabel(LISTVIEW_INFO *infoPtr) -{ - /* handle value will be lost after LISTVIEW_EndEditLabelT */ - HWND edit = infoPtr->hwndEdit; - - LISTVIEW_EndEditLabelT(infoPtr, TRUE, IsWindowUnicode(infoPtr->hwndEdit)); - SendMessageW(edit, WM_CLOSE, 0, 0); - - return TRUE; -} /*** * DESCRIPTION: @@ -5128,18 +4968,9 @@ static BOOL LISTVIEW_DeleteItem(LISTVIEW_INFO *infoPtr, INT nItem) { HDPA hdpaSubItems; ITEMHDR *hdrItem; - ITEM_INFO *lpItem; - ITEM_ID *lpID; INT i; hdpaSubItems = DPA_DeletePtr(infoPtr->hdpaItems, nItem); - lpItem = DPA_GetPtr(hdpaSubItems, 0); - - /* free id struct */ - i = DPA_GetPtrIndex(infoPtr->hdpaItemIds, lpItem->id); - lpID = DPA_GetPtr(infoPtr->hdpaItemIds, i); - DPA_DeletePtr(infoPtr->hdpaItemIds, i); - Free(lpID); for (i = 0; i < DPA_GetPtrCount(hdpaSubItems); i++) { hdrItem = DPA_GetPtr(hdpaSubItems, i); @@ -6825,50 +6656,55 @@ static INT LISTVIEW_HitTest(const LISTVIEW_INFO *infoPtr, LPLVHITTESTINFO lpht, lpht->iItem = -1; if (subitem) lpht->iSubItem = 0; - LISTVIEW_GetOrigin(infoPtr, &Origin); - - /* set whole list relation flags */ - if (subitem && infoPtr->uView == LV_VIEW_DETAILS) - { - /* LVM_SUBITEMHITTEST checks left bound of possible client area */ - if (infoPtr->rcList.left > lpht->pt.x && Origin.x < lpht->pt.x) - lpht->flags |= LVHT_TOLEFT; + if (infoPtr->rcList.left > lpht->pt.x) + lpht->flags |= LVHT_TOLEFT; + else if (infoPtr->rcList.right < lpht->pt.x) + lpht->flags |= LVHT_TORIGHT; + + if (infoPtr->rcList.top > lpht->pt.y) + lpht->flags |= LVHT_ABOVE; + else if (infoPtr->rcList.bottom < lpht->pt.y) + lpht->flags |= LVHT_BELOW; - if (lpht->pt.y < infoPtr->rcList.top && lpht->pt.y >= 0) - opt.y = lpht->pt.y + infoPtr->rcList.top; - else - opt.y = lpht->pt.y; + TRACE("lpht->flags=0x%x\n", lpht->flags); + if (lpht->flags) return -1; - if (infoPtr->rcList.bottom < opt.y) - lpht->flags |= LVHT_BELOW; - } - else - { - if (infoPtr->rcList.left > lpht->pt.x) - lpht->flags |= LVHT_TOLEFT; - else if (infoPtr->rcList.right < lpht->pt.x) - lpht->flags |= LVHT_TORIGHT; + lpht->flags |= LVHT_NOWHERE; - if (infoPtr->rcList.top > lpht->pt.y) - lpht->flags |= LVHT_ABOVE; - else if (infoPtr->rcList.bottom < lpht->pt.y) - lpht->flags |= LVHT_BELOW; - } + LISTVIEW_GetOrigin(infoPtr, &Origin); + + /* first deal with the large items */ + rcSearch.left = lpht->pt.x; + rcSearch.top = lpht->pt.y; + rcSearch.right = rcSearch.left + 1; + rcSearch.bottom = rcSearch.top + 1; + + iterator_frameditems(&i, infoPtr, &rcSearch); + iterator_next(&i); /* go to first item in the sequence */ + iItem = i.nItem; + iterator_destroy(&i); + + TRACE("lpht->iItem=%d\n", iItem); + if (iItem == -1) return -1; - /* even if item is invalid try to find subitem */ if (infoPtr->uView == LV_VIEW_DETAILS && subitem) { - RECT *pRect; + RECT bounds, *pRect; INT j; + /* for top/bottom only */ + bounds.left = LVIR_BOUNDS; + LISTVIEW_GetItemRect(infoPtr, iItem, &bounds); opt.x = lpht->pt.x - Origin.x; + opt.y = lpht->pt.y; - lpht->iSubItem = -1; for (j = 0; j < DPA_GetPtrCount(infoPtr->hdpaColumns); j++) { pRect = &LISTVIEW_GetColumnInfo(infoPtr, j)->rcHeader; + bounds.left = pRect->left; + bounds.right = pRect->right; - if ((opt.x >= pRect->left) && (opt.x < pRect->right)) + if (PtInRect(&bounds, opt)) { lpht->iSubItem = j; break; @@ -6877,25 +6713,6 @@ static INT LISTVIEW_HitTest(const LISTVIEW_INFO *infoPtr, LPLVHITTESTINFO lpht, TRACE("lpht->iSubItem=%d\n", lpht->iSubItem); } - TRACE("lpht->flags=0x%x\n", lpht->flags); - if (lpht->flags) return -1; - - lpht->flags |= LVHT_NOWHERE; - - /* first deal with the large items */ - rcSearch.left = lpht->pt.x; - rcSearch.top = lpht->pt.y; - rcSearch.right = rcSearch.left + 1; - rcSearch.bottom = rcSearch.top + 1; - - iterator_frameditems(&i, infoPtr, &rcSearch); - iterator_next(&i); /* go to first item in the sequence */ - iItem = i.nItem; - iterator_destroy(&i); - - TRACE("lpht->iItem=%d\n", iItem); - if (iItem == -1) return -1; - lvItem.mask = LVIF_STATE | LVIF_TEXT; if (infoPtr->uView == LV_VIEW_DETAILS) lvItem.mask |= LVIF_INDENT; lvItem.stateMask = LVIS_STATEIMAGEMASK; @@ -6910,12 +6727,8 @@ static INT LISTVIEW_HitTest(const LISTVIEW_INFO *infoPtr, LPLVHITTESTINFO lpht, LISTVIEW_GetItemMetrics(infoPtr, &lvItem, &rcBox, NULL, &rcIcon, &rcState, &rcLabel); LISTVIEW_GetItemOrigin(infoPtr, iItem, &Position); opt.x = lpht->pt.x - Position.x - Origin.x; - - if (lpht->pt.y < infoPtr->rcList.top && lpht->pt.y >= 0) - opt.y = lpht->pt.y - Position.y - Origin.y + infoPtr->rcList.top; - else - opt.y = lpht->pt.y - Position.y - Origin.y; - + opt.y = lpht->pt.y - Position.y - Origin.y; + if (infoPtr->uView == LV_VIEW_DETAILS) { rcBounds = rcBox; @@ -6982,7 +6795,6 @@ static INT LISTVIEW_InsertItemT(LISTVIEW_INFO *infoPtr, const LVITEMW *lpLVItem, HDPA hdpaSubItems; NMLISTVIEW nmlv; ITEM_INFO *lpItem; - ITEM_ID *lpID; BOOL is_sorted, has_changed; LVITEMW item; HWND hwndSelf = infoPtr->hwndSelf; @@ -7002,13 +6814,6 @@ static INT LISTVIEW_InsertItemT(LISTVIEW_INFO *infoPtr, const LVITEMW *lpLVItem, if ( !(hdpaSubItems = DPA_Create(8)) ) goto fail; if ( !DPA_SetPtr(hdpaSubItems, 0, lpItem) ) assert (FALSE); - /* link with id struct */ - if (!(lpID = Alloc(sizeof(ITEM_ID)))) goto fail; - lpItem->id = lpID; - lpID->item = hdpaSubItems; - lpID->id = get_next_itemid(infoPtr); - if ( DPA_InsertPtr(infoPtr->hdpaItemIds, infoPtr->nItemCount, lpID) == -1) goto fail; - is_sorted = (infoPtr->dwStyle & (LVS_SORTASCENDING | LVS_SORTDESCENDING)) && !(infoPtr->dwStyle & LVS_OWNERDRAWFIXED) && (LPSTR_TEXTCALLBACKW != lpLVItem->pszText); @@ -7121,44 +6926,6 @@ fail: /*** * DESCRIPTION: - * Checks item visibility. - * - * PARAMETER(S): - * [I] infoPtr : valid pointer to the listview structure - * [I] nFirst : item index to check for - * - * RETURN: - * Item visible : TRUE - * Item invisible or failure : FALSE - */ -static BOOL LISTVIEW_IsItemVisible(const LISTVIEW_INFO *infoPtr, INT nItem) -{ - POINT Origin, Position; - RECT rcItem; - HDC hdc; - BOOL ret; - - TRACE("nItem=%d\n", nItem); - - if (nItem < 0 || nItem >= DPA_GetPtrCount(infoPtr->hdpaItems)) return FALSE; - - LISTVIEW_GetOrigin(infoPtr, &Origin); - LISTVIEW_GetItemOrigin(infoPtr, nItem, &Position); - rcItem.left = Position.x + Origin.x; - rcItem.top = Position.y + Origin.y; - rcItem.right = rcItem.left + infoPtr->nItemWidth; - rcItem.bottom = rcItem.top + infoPtr->nItemHeight; - - hdc = GetDC(infoPtr->hwndSelf); - if (!hdc) return FALSE; - ret = RectVisible(hdc, &rcItem); - ReleaseDC(infoPtr->hwndSelf, hdc); - - return ret; -} - -/*** - * DESCRIPTION: * Redraws a range of items. * * PARAMETER(S): @@ -8108,9 +7875,6 @@ static BOOL LISTVIEW_SetItemState(LISTVIEW_INFO *infoPtr, INT nItem, const LVITE if ((lvItem.state & lvItem.stateMask & LVIS_SELECTED) && (infoPtr->dwStyle & LVS_SINGLESEL)) return FALSE; - /* focus all isn't allowed */ - if (lvItem.state & lvItem.stateMask & LVIS_FOCUSED) return FALSE; - /* apply to all items */ for (lvItem.iItem = 0; lvItem.iItem < infoPtr->nItemCount; lvItem.iItem++) if (!LISTVIEW_SetItemT(infoPtr, &lvItem, TRUE)) bResult = FALSE; @@ -8118,6 +7882,39 @@ static BOOL LISTVIEW_SetItemState(LISTVIEW_INFO *infoPtr, INT nItem, const LVITE else bResult = LISTVIEW_SetItemT(infoPtr, &lvItem, TRUE); + /* + * Update selection mark + * + * Investigation on windows 2k showed that selection mark was updated + * whenever a new selection was made, but if the selected item was + * unselected it was not updated. + * + * we are probably still not 100% accurate, but this at least sets the + * proper selection mark when it is needed + */ + + if (bResult && (lvItem.state & lvItem.stateMask & LVIS_SELECTED) && + (infoPtr->nSelectionMark == -1)) + { + int i; + for (i = 0; i < infoPtr->nItemCount; i++) + { + if (infoPtr->uCallbackMask & LVIS_SELECTED) + { + if (LISTVIEW_GetItemState(infoPtr, i, LVIS_SELECTED)) + { + infoPtr->nSelectionMark = i; + break; + } + } + else if (ranges_contain(infoPtr->selectionRanges, i)) + { + infoPtr->nSelectionMark = i; + break; + } + } + } + return bResult; } @@ -8628,7 +8425,6 @@ static LRESULT LISTVIEW_NCCreate(HWND hwnd, const CREATESTRUCTW *lpcs) /* allocate memory for the data structure */ if (!(infoPtr->selectionRanges = ranges_create(10))) goto fail; if (!(infoPtr->hdpaItems = DPA_Create(10))) goto fail; - if (!(infoPtr->hdpaItemIds = DPA_Create(10))) goto fail; if (!(infoPtr->hdpaPosX = DPA_Create(10))) goto fail; if (!(infoPtr->hdpaPosY = DPA_Create(10))) goto fail; if (!(infoPtr->hdpaColumns = DPA_Create(10))) goto fail; @@ -8638,7 +8434,6 @@ fail: DestroyWindow(infoPtr->hwndHeader); ranges_destroy(infoPtr->selectionRanges); DPA_Destroy(infoPtr->hdpaItems); - DPA_Destroy(infoPtr->hdpaItemIds); DPA_Destroy(infoPtr->hdpaPosX); DPA_Destroy(infoPtr->hdpaPosY); DPA_Destroy(infoPtr->hdpaColumns); @@ -8690,8 +8485,6 @@ static LRESULT LISTVIEW_Create(HWND hwnd, const CREATESTRUCTW *lpcs) ShowWindow(infoPtr->hwndHeader, SW_SHOWNORMAL); } LISTVIEW_UpdateScroll(infoPtr); - /* send WM_MEASUREITEM notification */ - if (infoPtr->dwStyle & LVS_OWNERDRAWFIXED) notify_measureitem(infoPtr); } OpenThemeData(hwnd, themeClass); @@ -9413,7 +9206,6 @@ static LRESULT LISTVIEW_NCDestroy(LISTVIEW_INFO *infoPtr) /* destroy data structure */ DPA_Destroy(infoPtr->hdpaItems); - DPA_Destroy(infoPtr->hdpaItemIds); DPA_Destroy(infoPtr->hdpaPosX); DPA_Destroy(infoPtr->hdpaPosY); DPA_Destroy(infoPtr->hdpaColumns); @@ -10321,8 +10113,7 @@ LISTVIEW_WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) case LVM_ARRANGE: return LISTVIEW_Arrange(infoPtr, (INT)wParam); - case LVM_CANCELEDITLABEL: - return LISTVIEW_CancelEditLabel(infoPtr); +/* case LVM_CANCELEDITLABEL: */ case LVM_CREATEDRAGIMAGE: return (LRESULT)LISTVIEW_CreateDragImage(infoPtr, (INT)wParam, (LPPOINT)lParam); @@ -10528,14 +10319,9 @@ LISTVIEW_WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) /* case LVM_ISGROUPVIEWENABLED: */ - case LVM_ISITEMVISIBLE: - return LISTVIEW_IsItemVisible(infoPtr, (INT)wParam); + /* case LVM_MAPIDTOINDEX: */ - case LVM_MAPIDTOINDEX: - return LISTVIEW_MapIdToIndex(infoPtr, (UINT)wParam); - - case LVM_MAPINDEXTOID: - return LISTVIEW_MapIndexToId(infoPtr, (INT)wParam); + /* case LVM_MAPINDEXTOID: */ /* case LVM_MOVEGROUP: */ @@ -10623,7 +10409,6 @@ LISTVIEW_WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return LISTVIEW_SetItemPosition(infoPtr, (INT)wParam, *((POINT*)lParam)); case LVM_SETITEMSTATE: - if (lParam == 0) return FALSE; return LISTVIEW_SetItemState(infoPtr, (INT)wParam, (LPLVITEMW)lParam); case LVM_SETITEMTEXTA: @@ -10815,7 +10600,16 @@ LISTVIEW_WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) if ((infoPtr->dwStyle & LVS_OWNERDRAWFIXED) && (infoPtr->uView == LV_VIEW_DETAILS)) { - if (notify_measureitem(infoPtr)) LISTVIEW_InvalidateList(infoPtr); + MEASUREITEMSTRUCT mis; + mis.CtlType = ODT_LISTVIEW; + mis.CtlID = GetWindowLongPtrW(infoPtr->hwndSelf, GWLP_ID); + mis.itemID = -1; + mis.itemWidth = 0; + mis.itemData = 0; + mis.itemHeight= infoPtr->nItemHeight; + SendMessageW(infoPtr->hwndNotify, WM_MEASUREITEM, mis.CtlID, (LPARAM)&mis); + if (infoPtr->nItemHeight != max(mis.itemHeight, 1)) + infoPtr->nMeasureItemHeight = infoPtr->nItemHeight = max(mis.itemHeight, 1); } LISTVIEW_UpdateSize(infoPtr); @@ -10940,7 +10734,11 @@ static LRESULT LISTVIEW_Command(LISTVIEW_INFO *infoPtr, WPARAM wParam, LPARAM lP } case EN_KILLFOCUS: { - LISTVIEW_CancelEditLabel(infoPtr); + /* handle value will be lost after LISTVIEW_EndEditLabelT */ + HWND edit = infoPtr->hwndEdit; + + LISTVIEW_EndEditLabelT(infoPtr, TRUE, IsWindowUnicode(infoPtr->hwndEdit)); + SendMessageW(edit, WM_CLOSE, 0, 0); } default: diff --git a/dlls/comctl32/progress.c b/dlls/comctl32/progress.c index 56f40bb2fb4..776345ffda1 100644 --- a/dlls/comctl32/progress.c +++ b/dlls/comctl32/progress.c @@ -27,16 +27,6 @@ * the specification mentioned above. * If you discover missing features, or bugs, please note them below. * - * TODO: - * - * Messages: - * -- PBM_GETSTEP - * -- PBM_SETSTATE - * -- PBM_GETSTATE - * - * Styles: - * -- PBS_SMOOTHREVERSE - * */ #include @@ -713,17 +703,11 @@ static LRESULT WINAPI ProgressWindowProc(HWND hwnd, UINT message, InvalidateRect(hwnd, NULL, TRUE); return 0; - case PBM_GETBARCOLOR: - return infoPtr->ColorBar; - case PBM_SETBKCOLOR: infoPtr->ColorBk = (COLORREF)lParam; InvalidateRect(hwnd, NULL, TRUE); return 0; - case PBM_GETBKCOLOR: - return infoPtr->ColorBk; - case PBM_SETMARQUEE: if(wParam != 0) { diff --git a/dlls/comctl32/rebar.c b/dlls/comctl32/rebar.c index e11d974e208..8e18e228192 100644 --- a/dlls/comctl32/rebar.c +++ b/dlls/comctl32/rebar.c @@ -1699,11 +1699,11 @@ REBAR_CommonSetupBand(HWND hwnd, const REBARBANDINFOW *lprbbi, REBAR_BAND *lpBan if( (lprbbi->fMask & RBBIM_CHILDSIZE) && ( (lpBand->cxMinChild != lprbbi->cxMinChild) || (lpBand->cyMinChild != lprbbi->cyMinChild ) || - ( (lprbbi->cbSize >= REBARBANDINFOA_V6_SIZE && (lpBand->fStyle & RBBS_VARIABLEHEIGHT)) && + ( (lprbbi->cbSize >= sizeof (REBARBANDINFOA) && (lpBand->fStyle & RBBS_VARIABLEHEIGHT)) && ( (lpBand->cyChild != lprbbi->cyChild ) || (lpBand->cyMaxChild != lprbbi->cyMaxChild ) || (lpBand->cyIntegral != lprbbi->cyIntegral ) ) ) || - ( (lprbbi->cbSize < REBARBANDINFOA_V6_SIZE) && + ( (lprbbi->cbSize < sizeof (REBARBANDINFOA)) && ( (lpBand->cyChild || lpBand->cyMaxChild || lpBand->cyIntegral ) ) ) ) ) @@ -1711,7 +1711,7 @@ REBAR_CommonSetupBand(HWND hwnd, const REBARBANDINFOW *lprbbi, REBAR_BAND *lpBan lpBand->cxMinChild = lprbbi->cxMinChild; lpBand->cyMinChild = lprbbi->cyMinChild; /* These fields where added in WIN32_IE == 0x400 and are set only for RBBS_VARIABLEHEIGHT bands */ - if (lprbbi->cbSize >= REBARBANDINFOA_V6_SIZE && (lpBand->fStyle & RBBS_VARIABLEHEIGHT)) { + if (lprbbi->cbSize >= sizeof (REBARBANDINFOA) && (lpBand->fStyle & RBBS_VARIABLEHEIGHT)) { lpBand->cyMaxChild = lprbbi->cyMaxChild; lpBand->cyIntegral = lprbbi->cyIntegral; @@ -1747,7 +1747,7 @@ REBAR_CommonSetupBand(HWND hwnd, const REBARBANDINFOW *lprbbi, REBAR_BAND *lpBan } /* check for additional data */ - if (lprbbi->cbSize >= REBARBANDINFOA_V6_SIZE) { + if (lprbbi->cbSize >= sizeof (REBARBANDINFOA)) { if( (lprbbi->fMask & RBBIM_IDEALSIZE) && ( lpBand->cxIdeal != lprbbi->cxIdeal ) ) { @@ -2167,7 +2167,7 @@ REBAR_GetBandInfoT(const REBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam, BOOL lprbbi->cyMinChild = lpBand->cyMinChild; /* to make tests pass we follow Windows behaviour and allow to read these fields only * for RBBS_VARIABLEHEIGHTS bands */ - if (lprbbi->cbSize >= REBARBANDINFOW_V6_SIZE && (lpBand->fStyle & RBBS_VARIABLEHEIGHT)) { + if (lprbbi->cbSize >= sizeof (REBARBANDINFOA) && (lpBand->fStyle & RBBS_VARIABLEHEIGHT)) { lprbbi->cyChild = lpBand->cyChild; lprbbi->cyMaxChild = lpBand->cyMaxChild; lprbbi->cyIntegral = lpBand->cyIntegral; @@ -2184,7 +2184,7 @@ REBAR_GetBandInfoT(const REBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam, BOOL lprbbi->wID = lpBand->wID; /* check for additional data */ - if (lprbbi->cbSize >= REBARBANDINFOW_V6_SIZE) { + if (lprbbi->cbSize >= sizeof (REBARBANDINFOA)) { if (lprbbi->fMask & RBBIM_IDEALSIZE) lprbbi->cxIdeal = lpBand->cxIdeal; @@ -2424,7 +2424,7 @@ REBAR_InsertBandT(REBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam, BOOL bUnico REBAR_CommonSetupBand(infoPtr->hwndSelf, lprbbi, lpBand); /* Make sure the defaults for these are correct */ - if (lprbbi->cbSize < REBARBANDINFOA_V6_SIZE || !(lpBand->fStyle & RBBS_VARIABLEHEIGHT)) { + if (lprbbi->cbSize < sizeof (REBARBANDINFOA) || !(lpBand->fStyle & RBBS_VARIABLEHEIGHT)) { lpBand->cyChild = lpBand->cyMinChild; lpBand->cyMaxChild = 0x7fffffff; lpBand->cyIntegral = 0; diff --git a/dlls/comctl32/rsrc.rc b/dlls/comctl32/rsrc.rc index a8b3e965aa5..1fac6d9ddc3 100644 --- a/dlls/comctl32/rsrc.rc +++ b/dlls/comctl32/rsrc.rc @@ -19,6 +19,10 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winnls.h" #include "comctl32.h" LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL @@ -76,3 +80,39 @@ IDI_TT_WARN_SM ICON LOADONCALL DISCARDABLE idi_tt_warn_sm.ico /* @makedep: idi_tt_error_sm.ico */ IDI_TT_ERROR_SM ICON LOADONCALL DISCARDABLE idi_tt_error_sm.ico + + +/* + * Everything specific to any language goes + * in one of the specific files. + * Note that you can and may override resources + * which also have a neutral version. This is to + * get localized bitmaps for example. + */ + +#include "comctl_Bg.rc" +#include "comctl_Cs.rc" +#include "comctl_De.rc" +#include "comctl_El.rc" +#include "comctl_En.rc" +#include "comctl_Eo.rc" +#include "comctl_Es.rc" +#include "comctl_Fr.rc" +#include "comctl_Hu.rc" +#include "comctl_It.rc" +#include "comctl_Ja.rc" +#include "comctl_Ko.rc" +#include "comctl_Lt.rc" +#include "comctl_Nl.rc" +#include "comctl_No.rc" +#include "comctl_Pl.rc" +#include "comctl_Pt.rc" +#include "comctl_Ro.rc" +#include "comctl_Ru.rc" +#include "comctl_Si.rc" +#include "comctl_Sk.rc" +#include "comctl_Sv.rc" +#include "comctl_Th.rc" +#include "comctl_Tr.rc" +#include "comctl_Uk.rc" +#include "comctl_Zh.rc" diff --git a/dlls/comctl32/tests/datetime.c b/dlls/comctl32/tests/datetime.c index 038a7898118..8fdbbe53608 100644 --- a/dlls/comctl32/tests/datetime.c +++ b/dlls/comctl32/tests/datetime.c @@ -423,13 +423,10 @@ static void test_dtm_set_range_swap_min_max(HWND hWndDateTime) r = SendMessage(hWndDateTime, DTM_GETRANGE, 0, (LPARAM)getSt); ok(r == (GDTR_MIN | GDTR_MAX), "Expected %x, not %x(GDTR_MIN) or %x(GDTR_MAX), got %lx\n", (GDTR_MIN | GDTR_MAX), GDTR_MIN, GDTR_MAX, r); todo_wine { - ok(compare_systime(&st[0], &getSt[0]) == 1 || - broken(compare_systime(&st[0], &getSt[1]) == 1), /* comctl32 version <= 5.80 */ - "ST1 != ST2\n"); - - ok(compare_systime(&st[1], &getSt[1]) == 1 || - broken(compare_systime(&st[1], &getSt[0]) == 1), /* comctl32 version <= 5.80 */ - "ST1 != ST2\n"); + expect_systime(&st[0], &getSt[0]); + } + todo_wine { + expect_systime(&st[1], &getSt[1]); } fill_systime_struct(&st[0], 1980, 1, 3, 23, 14, 34, 37, 465); @@ -442,9 +439,7 @@ static void test_dtm_set_range_swap_min_max(HWND hWndDateTime) and doing DTM_SETSYSTEMTIME */ expect_systime_date(&st[0], &getSt[0]); todo_wine { - ok(compare_systime_time(&origSt, &getSt[0]) == 1 || - broken(compare_systime_time(&st[0], &getSt[0]) == 1), /* comctl32 version <= 5.80 */ - "ST1.time != ST2.time\n"); + expect_systime_time(&origSt, &getSt[0]); } /* set st[0] to value higher than minimum */ @@ -460,13 +455,10 @@ static void test_dtm_set_range_swap_min_max(HWND hWndDateTime) r = SendMessage(hWndDateTime, DTM_GETRANGE, 0, (LPARAM)getSt); ok(r == (GDTR_MIN | GDTR_MAX), "Expected %x, not %x(GDTR_MIN) or %x(GDTR_MAX), got %lx\n", (GDTR_MIN | GDTR_MAX), GDTR_MIN, GDTR_MAX, r); todo_wine { - ok(compare_systime(&st[0], &getSt[1]) == 1 || - broken(compare_systime(&st[0], &getSt[0]) == 1), /* comctl32 version <= 5.80 */ - "ST1 != ST2\n"); - - ok(compare_systime(&st[1], &getSt[0]) == 1 || - broken(compare_systime(&st[1], &getSt[1]) == 1), /* comctl32 version <= 5.80 */ - "ST1 != ST2\n"); + expect_systime(&st[0], &getSt[1]); + } + todo_wine { + expect_systime(&st[1], &getSt[0]); } /* set st[0] to value higher than st[1] */ diff --git a/dlls/comctl32/tests/dpa.c b/dlls/comctl32/tests/dpa.c index 741aeb63b23..ed28119ac89 100644 --- a/dlls/comctl32/tests/dpa.c +++ b/dlls/comctl32/tests/dpa.c @@ -289,9 +289,9 @@ static void test_dpa(void) ok(j == DPA_ERR, "j=%d\n", j); /* ... but for a binary search it's ignored */ j = pDPA_Search(dpa, (PVOID)(INT_PTR)i, i+1, CB_CmpLT, 0xdeadbeef, DPAS_SORTED); - ok(j+1 == i, "j=%d i=%d\n", j, i); + todo_wine ok(j+1 == i, "j=%d i=%d\n", j, i); } - + /* Try to get the index of a nonexistent item */ i = pDPA_GetPtrIndex(dpa, (PVOID)7); ok(i == DPA_ERR, "i=%d\n", i); diff --git a/dlls/comctl32/tests/header.c b/dlls/comctl32/tests/header.c index 611433e3cda..76612530c98 100644 --- a/dlls/comctl32/tests/header.c +++ b/dlls/comctl32/tests/header.c @@ -121,6 +121,7 @@ static const struct message deleteItem_getItemCount_seq[] = { }; static const struct message orderArray_seq[] = { + { HDM_GETITEMCOUNT, sent }, { HDM_SETORDERARRAY, sent|wparam, 2 }, { HDM_GETORDERARRAY, sent|wparam, 2 }, { 0 } @@ -819,8 +820,10 @@ static void test_hdm_getitemrect(HWND hParent) expect(80, rect.left); expect(0, rect.top); expect(160, rect.right); - expect(g_customheight, rect.bottom); - + todo_wine + { + expect(g_customheight, rect.bottom); + } retVal = SendMessage(hChild, HDM_GETITEMRECT, 0, (LPARAM) &rect); ok(retVal == TRUE, "Getting item rect should TRUE, got %d\n", retVal); @@ -829,8 +832,10 @@ static void test_hdm_getitemrect(HWND hParent) expect(0, rect.top); expect(80, rect.right); - expect(g_customheight, rect.bottom); - + todo_wine + { + expect(g_customheight, rect.bottom); + } retVal = SendMessage(hChild, HDM_GETITEMRECT, 10, (LPARAM) &rect); ok(retVal == 0, "Getting rect of nonexistent item should return 0, got %d\n", retVal); @@ -902,25 +907,30 @@ static void test_hdm_hittest(HWND hParent) flush_sequences(sequences, NUM_MSG_SEQUENCES); retVal = SendMessage(hChild, HDM_HITTEST, 0, (LPARAM) &hdHitTestInfo); - expect(0, retVal); - expect(0, hdHitTestInfo.iItem); - expect(HHT_ONDIVIDER, hdHitTestInfo.flags); + todo_wine + { + expect(0, retVal); + expect(0, hdHitTestInfo.iItem); + } pt.x = secondItemRightBoundary - 1; pt.y = bottomBoundary - 1; hdHitTestInfo.pt = pt; retVal = SendMessage(hChild, HDM_HITTEST, 1, (LPARAM) &hdHitTestInfo); - expect(1, retVal); + todo_wine + { + expect(1, retVal); + } expect(1, hdHitTestInfo.iItem); - expect(HHT_ONDIVIDER, hdHitTestInfo.flags); pt.x = secondItemRightBoundary; pt.y = bottomBoundary + 1; hdHitTestInfo.pt = pt; - retVal = SendMessage(hChild, HDM_HITTEST, 0, (LPARAM) &hdHitTestInfo); - expect(-1, retVal); - expect(-1, hdHitTestInfo.iItem); - expect(HHT_BELOW, hdHitTestInfo.flags); + todo_wine + { + retVal = SendMessage(hChild, HDM_HITTEST, 0, (LPARAM) &hdHitTestInfo); + expect(-1, retVal); + } ok_sequence(sequences, HEADER_SEQ_INDEX, hittest_seq, "hittest sequence testing", FALSE); @@ -941,9 +951,11 @@ static void test_hdm_sethotdivider(HWND hParent) "adder header control to parent", FALSE); flush_sequences(sequences, NUM_MSG_SEQUENCES); - retVal = SendMessage(hChild, HDM_SETHOTDIVIDER, TRUE, MAKELPARAM(5, 5)); - expect(0, retVal); - + todo_wine + { + retVal = SendMessage(hChild, HDM_SETHOTDIVIDER, TRUE, 0X00050005); + expect(0, retVal); + } retVal = SendMessage(hChild, HDM_SETHOTDIVIDER, FALSE, 100); expect(100, retVal); retVal = SendMessage(hChild, HDM_SETHOTDIVIDER, FALSE, 1); @@ -1013,16 +1025,9 @@ static void test_hdm_filterMessages(HWND hParent) todo_wine { retVal = SendMessage(hChild, HDM_CLEARFILTER, 0, 1); - if (retVal == 0) - win_skip("HDM_CLEARFILTER needs 5.80\n"); - else - expect(1, retVal); - + expect(1, retVal); retVal = SendMessage(hChild, HDM_EDITFILTER, 1, 0); - if (retVal == 0) - win_skip("HDM_EDITFILTER needs 5.80\n"); - else - expect(1, retVal); + expect(1, retVal); } if (winetest_interactive) ok_sequence(sequences, HEADER_SEQ_INDEX, filterMessages_seq_interactive, @@ -1071,10 +1076,7 @@ static void test_hdm_bitmapmarginMessages(HWND hParent) flush_sequences(sequences, NUM_MSG_SEQUENCES); retVal = SendMessage(hChild, HDM_GETBITMAPMARGIN, 0, 0); - if (retVal == 0) - win_skip("HDM_GETBITMAPMARGIN needs 5.80\n"); - else - expect(6, retVal); + expect(6, retVal); ok_sequence(sequences, HEADER_SEQ_INDEX, bitmapmarginMessages_seq, "bitmapmarginMessages sequence testing", FALSE); @@ -1096,7 +1098,6 @@ static void test_hdm_index_messages(HWND hParent) static char thirdHeaderItem[] = "Type"; static char fourthHeaderItem[] = "Date Modified"; static char *items[] = {firstHeaderItem, secondHeaderItem, thirdHeaderItem, fourthHeaderItem}; - RECT rect; HDITEM hdItem; hdItem.mask = HDI_TEXT | HDI_WIDTH | HDI_FORMAT; hdItem.fmt = HDF_LEFT; @@ -1124,17 +1125,17 @@ static void test_hdm_index_messages(HWND hParent) retVal = SendMessage(hChild, HDM_DELETEITEM, 3, (LPARAM) &hdItem); ok(retVal == TRUE, "Deleting item 3 should return TRUE, got %d\n", retVal); - retVal = SendMessage(hChild, HDM_GETITEMCOUNT, 0, 0); + retVal = SendMessage(hChild, HDM_GETITEMCOUNT, 0, (LPARAM) &hdItem); ok(retVal == 3, "Getting item count should return 3, got %d\n", retVal); retVal = SendMessage(hChild, HDM_DELETEITEM, 3, (LPARAM) &hdItem); ok(retVal == FALSE, "Deleting already-deleted item should return FALSE, got %d\n", retVal); - retVal = SendMessage(hChild, HDM_GETITEMCOUNT, 0, 0); + retVal = SendMessage(hChild, HDM_GETITEMCOUNT, 0, (LPARAM) &hdItem); ok(retVal == 3, "Getting item count should return 3, got %d\n", retVal); retVal = SendMessage(hChild, HDM_DELETEITEM, 2, (LPARAM) &hdItem); ok(retVal == TRUE, "Deleting item 2 should return TRUE, got %d\n", retVal); - retVal = SendMessage(hChild, HDM_GETITEMCOUNT, 0, 0); + retVal = SendMessage(hChild, HDM_GETITEMCOUNT, 0, (LPARAM) &hdItem); ok(retVal == 2, "Getting item count should return 2, got %d\n", retVal); ok_sequence(sequences, HEADER_SEQ_INDEX, deleteItem_getItemCount_seq, @@ -1155,19 +1156,9 @@ static void test_hdm_index_messages(HWND hParent) expect(0, strcmpResult); expect(80, hdItem.cxy); - iSize = SendMessage(hChild, HDM_GETITEMCOUNT, 0, 0); - - /* item should be updated just after accepting new array */ - ShowWindow(hChild, SW_HIDE); - retVal = SendMessage(hChild, HDM_SETORDERARRAY, iSize, (LPARAM) lpiarray); - expect(TRUE, retVal); - rect.left = 0; - retVal = SendMessage(hChild, HDM_GETITEMRECT, 0, (LPARAM) &rect); - expect(TRUE, retVal); - ok(rect.left != 0, "Expected updated rectangle\n"); - flush_sequences(sequences, NUM_MSG_SEQUENCES); + iSize = SendMessage(hChild, HDM_GETITEMCOUNT, 0, (LPARAM) &hdItem); retVal = SendMessage(hChild, HDM_SETORDERARRAY, iSize, (LPARAM) lpiarray); ok(retVal == TRUE, "Setting header items order should return TRUE, got %d\n", retVal); @@ -1201,8 +1192,7 @@ static void test_hdm_index_messages(HWND hParent) if (item_spec != -1) \ ok(nm->dwItemSpec == item_spec, "Invalid dwItemSpec %d vs %ld\n", item_spec, nm->dwItemSpec); \ ok(nm->lItemlParam == lparam, "Invalid lItemlParam %d vs %ld\n", lparam, nm->lItemlParam); \ - ok((nm->rc.top == _top && nm->rc.bottom == _bottom && nm->rc.left == _left && nm->rc.right == _right) || \ - broken(draw_stage != CDDS_ITEMPREPAINT), /* comctl32 < 5.80 */ \ + ok(nm->rc.top == _top && nm->rc.bottom == _bottom && nm->rc.left == _left && nm->rc.right == _right, \ "Invalid rect (%d,%d) (%d,%d) vs (%d,%d) (%d,%d)\n", _left, _top, _right, _bottom, \ nm->rc.left, nm->rc.top, nm->rc.right, nm->rc.bottom); diff --git a/dlls/comctl32/tests/listview.c b/dlls/comctl32/tests/listview.c index 888b323bb3b..2c3ab64dba0 100644 --- a/dlls/comctl32/tests/listview.c +++ b/dlls/comctl32/tests/listview.c @@ -79,8 +79,6 @@ static const WCHAR testparentclassW[] = HWND hwndparent, hwndparentW; /* prevents edit box creation, LVN_BEGINLABELEDIT return value */ BOOL blockEdit; -/* dumps LVN_ITEMCHANGED message data */ -static BOOL g_dump_itemchanged; /* format reported to control: -1 falls to defproc, anything else returned */ INT notifyFormat; @@ -91,11 +89,28 @@ static HWND subclass_editbox(HWND hwndListview); static struct msg_sequence *sequences[NUM_MSG_SEQUENCES]; -static const struct message create_ownerdrawfixed_parent_seq[] = { - { WM_NOTIFYFORMAT, sent }, - { WM_QUERYUISTATE, sent|optional }, /* Win2K and higher */ - { WM_MEASUREITEM, sent }, - { WM_PARENTNOTIFY, sent }, +static const struct message create_parent_wnd_seq[] = { + { WM_GETMINMAXINFO, sent }, + { WM_NCCREATE, sent }, + { WM_NCCALCSIZE, sent|wparam, 0 }, + { WM_CREATE, sent }, + { WM_SHOWWINDOW, sent|wparam, 1 }, + { WM_WINDOWPOSCHANGING, sent|wparam, 0 }, + { WM_QUERYNEWPALETTE, sent|optional }, + { WM_WINDOWPOSCHANGING, sent|wparam, 0 }, + { WM_WINDOWPOSCHANGED, sent|optional }, + { WM_NCCALCSIZE, sent|wparam|optional, 1 }, + { WM_ACTIVATEAPP, sent|wparam, 1 }, + { WM_NCACTIVATE, sent|wparam, 1 }, + { WM_ACTIVATE, sent|wparam, 1 }, + { WM_IME_SETCONTEXT, sent|wparam|defwinproc|optional, 1 }, + { WM_IME_NOTIFY, sent|defwinproc|optional }, + { WM_SETFOCUS, sent|wparam|defwinproc, 0 }, + /* Win9x adds SWP_NOZORDER below */ + { WM_WINDOWPOSCHANGED, sent, /*|wparam, SWP_SHOWWINDOW|SWP_NOSIZE|SWP_NOMOVE|SWP_NOCLIENTSIZE|SWP_NOCLIENTMOVE*/ }, + { WM_NCCALCSIZE, sent|wparam|optional, 1 }, + { WM_SIZE, sent }, + { WM_MOVE, sent }, { 0 } }; @@ -203,43 +218,6 @@ static const struct message forward_erasebkgnd_parent_seq[] = { static const struct message ownderdata_select_focus_parent_seq[] = { { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGED }, { WM_NOTIFY, sent|id, 0, 0, LVN_GETDISPINFOA }, - { WM_NOTIFY, sent|id|optional, 0, 0, LVN_GETDISPINFOA }, /* version 4.7x */ - { 0 } -}; - -static const struct message ownerdata_setstate_all_parent_seq[] = { - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGED }, - { 0 } -}; - -static const struct message ownerdata_defocus_all_parent_seq[] = { - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGED }, - { WM_NOTIFY, sent|id, 0, 0, LVN_GETDISPINFOA }, - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGED }, - { 0 } -}; - -static const struct message ownerdata_deselect_all_parent_seq[] = { - { WM_NOTIFY, sent|id, 0, 0, LVN_ODCACHEHINT }, - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGED }, - { 0 } -}; - -static const struct message select_all_parent_seq[] = { - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGING }, - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGED }, - - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGING }, - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGED }, - - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGING }, - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGED }, - - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGING }, - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGED }, - - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGING }, - { WM_NOTIFY, sent|id, 0, 0, LVN_ITEMCHANGED }, { 0 } }; @@ -278,12 +256,6 @@ static const struct message editbox_create_pos[] = { { 0 } }; -static const struct message scroll_parent_seq[] = { - { WM_NOTIFY, sent|id, 0, 0, LVN_BEGINSCROLL }, - { WM_NOTIFY, sent|id, 0, 0, LVN_ENDSCROLL }, - { 0 } -}; - struct subclass_info { WNDPROC oldproc; @@ -334,23 +306,6 @@ static LRESULT WINAPI parent_wnd_proc(HWND hwnd, UINT message, WPARAM wParam, LP case LVN_ENDLABELEDIT: /* always accept new item text */ return TRUE; - case LVN_BEGINSCROLL: - case LVN_ENDSCROLL: - { - NMLVSCROLL *pScroll = (NMLVSCROLL*)lParam; - - trace("LVN_%sSCROLL: (%d,%d)\n", pScroll->hdr.code == LVN_BEGINSCROLL ? - "BEGIN" : "END", pScroll->dx, pScroll->dy); - } - break; - case LVN_ITEMCHANGED: - if (g_dump_itemchanged) - { - NMLISTVIEW *nmlv = (NMLISTVIEW*)lParam; - trace("LVN_ITEMCHANGED: item=%d,new=%x,old=%x,changed=%x\n", - nmlv->iItem, nmlv->uNewState, nmlv->uOldState, nmlv->uChanged); - } - break; } break; } @@ -1407,9 +1362,7 @@ static void test_create(void) ok(NULL == GetDlgItem(hList, 0), "NULL dialog item expected\n"); SendMessage(hList, LVM_SETEXTENDEDLISTVIEWSTYLE, 0, LVS_EX_HEADERDRAGDROP); hHeader = (HWND)SendMessage(hList, LVM_GETHEADER, 0, 0); - ok(IsWindow(hHeader) || - broken(!IsWindow(hHeader)), /* 4.7x common controls */ - "Header should be created\n"); + ok(IsWindow(hHeader), "Header should be created\n"); ok(hHeader == GetDlgItem(hList, 0), "Expected header as dialog item\n"); DestroyWindow(hList); @@ -1437,13 +1390,6 @@ static void test_create(void) ok(NULL == GetDlgItem(hList, 0), "NULL dialog item expected\n"); DestroyWindow(hList); - - /* WM_MEASUREITEM should be sent when created with LVS_OWNERDRAWFIXED */ - flush_sequences(sequences, NUM_MSG_SEQUENCES); - hList = create_listview_control(LVS_OWNERDRAWFIXED); - ok_sequence(sequences, PARENT_SEQ_INDEX, create_ownerdrawfixed_parent_seq, - "created with LVS_OWNERDRAWFIXED|LVS_REPORT - parent seq", FALSE); - DestroyWindow(hList); } static void test_redraw(void) @@ -1962,24 +1908,6 @@ static void test_multiselect(void) } item_count = (int)SendMessage(hwnd, LVM_GETITEMCOUNT, 0, 0); expect(items,item_count); - - /* try with NULL pointer */ - r = SendMessageA(hwnd, LVM_SETITEMSTATE, 0, (LPARAM)NULL); - expect(FALSE, r); - - /* select all, check notifications */ - ListView_SetItemState(hwnd, -1, 0, LVIS_SELECTED); - - flush_sequences(sequences, NUM_MSG_SEQUENCES); - - item.stateMask = LVIS_SELECTED; - item.state = LVIS_SELECTED; - r = SendMessageA(hwnd, LVM_SETITEMSTATE, -1, (LPARAM)&item); - expect(TRUE, r); - - ok_sequence(sequences, PARENT_SEQ_INDEX, select_all_parent_seq, - "select all notification", FALSE); - /* deselect all items */ ListView_SetItemState(hwnd, -1, 0, LVIS_SELECTED); SendMessage(hwnd, LVM_SETSELECTIONMARK, 0, -1); @@ -1990,6 +1918,7 @@ static void test_multiselect(void) r = SendMessage(hwnd, LVM_GETSELECTEDCOUNT, 0, 0); expect(3, r); r = SendMessage(hwnd, LVM_GETSELECTIONMARK, 0, 0); +todo_wine expect(-1, r); style = GetWindowLongPtrA(hwnd, GWL_STYLE); @@ -2021,6 +1950,7 @@ static void test_multiselect(void) r = SendMessage(hwnd, LVM_GETSELECTEDCOUNT, 0, 0); expect(1, r); r = SendMessage(hwnd, LVM_GETSELECTIONMARK, 0, 0); +todo_wine expect(-1, r); /* try to select all on LVS_SINGLESEL */ @@ -2447,7 +2377,7 @@ static void test_ownerdata(void) /* check notifications after focused/selected changed */ hwnd = create_listview_control(LVS_OWNERDATA); ok(hwnd != NULL, "failed to create a listview window\n"); - res = SendMessageA(hwnd, LVM_SETITEMCOUNT, 20, 0); + res = SendMessageA(hwnd, LVM_SETITEMCOUNT, 1, 0); ok(res != 0, "Expected LVM_SETITEMCOUNT to succeed\n"); flush_sequences(sequences, NUM_MSG_SEQUENCES); @@ -2471,119 +2401,6 @@ static void test_ownerdata(void) ok_sequence(sequences, PARENT_SEQ_INDEX, ownderdata_select_focus_parent_seq, "ownerdata focus notification", TRUE); - - /* select all, check notifications */ - item.stateMask = LVIS_SELECTED; - item.state = 0; - res = SendMessageA(hwnd, LVM_SETITEMSTATE, -1, (LPARAM)&item); - expect(TRUE, res); - - flush_sequences(sequences, NUM_MSG_SEQUENCES); - - item.stateMask = LVIS_SELECTED; - item.state = LVIS_SELECTED; - - g_dump_itemchanged = TRUE; - res = SendMessageA(hwnd, LVM_SETITEMSTATE, -1, (LPARAM)&item); - expect(TRUE, res); - g_dump_itemchanged = FALSE; - - ok_sequence(sequences, PARENT_SEQ_INDEX, ownerdata_setstate_all_parent_seq, - "ownerdata select all notification", TRUE); - - /* select all again, note that all items are selected already */ - flush_sequences(sequences, NUM_MSG_SEQUENCES); - item.stateMask = LVIS_SELECTED; - item.state = LVIS_SELECTED; - g_dump_itemchanged = TRUE; - res = SendMessageA(hwnd, LVM_SETITEMSTATE, -1, (LPARAM)&item); - expect(TRUE, res); - g_dump_itemchanged = FALSE; - ok_sequence(sequences, PARENT_SEQ_INDEX, ownerdata_setstate_all_parent_seq, - "ownerdata select all notification", TRUE); - /* deselect all */ - flush_sequences(sequences, NUM_MSG_SEQUENCES); - item.stateMask = LVIS_SELECTED; - item.state = 0; - g_dump_itemchanged = TRUE; - res = SendMessageA(hwnd, LVM_SETITEMSTATE, -1, (LPARAM)&item); - expect(TRUE, res); - g_dump_itemchanged = FALSE; - ok_sequence(sequences, PARENT_SEQ_INDEX, ownerdata_deselect_all_parent_seq, - "ownerdata deselect all notification", TRUE); - - /* select one, then deselect all */ - item.stateMask = LVIS_SELECTED; - item.state = LVIS_SELECTED; - res = SendMessageA(hwnd, LVM_SETITEMSTATE, 0, (LPARAM)&item); - expect(TRUE, res); - flush_sequences(sequences, NUM_MSG_SEQUENCES); - item.stateMask = LVIS_SELECTED; - item.state = 0; - g_dump_itemchanged = TRUE; - res = SendMessageA(hwnd, LVM_SETITEMSTATE, -1, (LPARAM)&item); - expect(TRUE, res); - g_dump_itemchanged = FALSE; - ok_sequence(sequences, PARENT_SEQ_INDEX, ownerdata_deselect_all_parent_seq, - "ownerdata select all notification", TRUE); - - /* remove focused, try to focus all */ - item.stateMask = LVIS_FOCUSED; - item.state = LVIS_FOCUSED; - res = SendMessageA(hwnd, LVM_SETITEMSTATE, 0, (LPARAM)&item); - expect(TRUE, res); - item.stateMask = LVIS_FOCUSED; - item.state = 0; - res = SendMessageA(hwnd, LVM_SETITEMSTATE, -1, (LPARAM)&item); - expect(TRUE, res); - item.stateMask = LVIS_FOCUSED; - res = SendMessageA(hwnd, LVM_GETITEMSTATE, 0, LVIS_FOCUSED); - expect(0, res); - /* setting all to focused returns failure value */ - flush_sequences(sequences, NUM_MSG_SEQUENCES); - item.stateMask = LVIS_FOCUSED; - item.state = LVIS_FOCUSED; - g_dump_itemchanged = TRUE; - res = SendMessageA(hwnd, LVM_SETITEMSTATE, -1, (LPARAM)&item); - expect(FALSE, res); - g_dump_itemchanged = FALSE; - ok_sequence(sequences, PARENT_SEQ_INDEX, empty_seq, - "ownerdata focus all notification", FALSE); - /* focus single item, remove all */ - item.stateMask = LVIS_FOCUSED; - item.state = LVIS_FOCUSED; - res = SendMessage(hwnd, LVM_SETITEMSTATE, 0, (LPARAM)&item); - expect(TRUE, res); - flush_sequences(sequences, NUM_MSG_SEQUENCES); - item.stateMask = LVIS_FOCUSED; - item.state = 0; - g_dump_itemchanged = TRUE; - res = SendMessageA(hwnd, LVM_SETITEMSTATE, -1, (LPARAM)&item); - expect(TRUE, res); - g_dump_itemchanged = FALSE; - ok_sequence(sequences, PARENT_SEQ_INDEX, ownerdata_defocus_all_parent_seq, - "ownerdata remove focus all notification", TRUE); - /* set all cut */ - flush_sequences(sequences, NUM_MSG_SEQUENCES); - item.stateMask = LVIS_CUT; - item.state = LVIS_CUT; - g_dump_itemchanged = TRUE; - res = SendMessageA(hwnd, LVM_SETITEMSTATE, -1, (LPARAM)&item); - expect(TRUE, res); - g_dump_itemchanged = FALSE; - ok_sequence(sequences, PARENT_SEQ_INDEX, ownerdata_setstate_all_parent_seq, - "ownerdata cut all notification", TRUE); - /* all marked cut, try again */ - flush_sequences(sequences, NUM_MSG_SEQUENCES); - item.stateMask = LVIS_CUT; - item.state = LVIS_CUT; - g_dump_itemchanged = TRUE; - res = SendMessageA(hwnd, LVM_SETITEMSTATE, -1, (LPARAM)&item); - expect(TRUE, res); - g_dump_itemchanged = FALSE; - ok_sequence(sequences, PARENT_SEQ_INDEX, ownerdata_setstate_all_parent_seq, - "ownerdata cut all notification #2", TRUE); - DestroyWindow(hwnd); /* check notifications on LVM_GETITEM */ @@ -2850,55 +2667,24 @@ static void test_hittest(void) x = pos.x + 150; /* outside column */ y = pos.y + (bounds.bottom - bounds.top) / 2; test_lvm_hittest(hwnd, x, y, -1, LVHT_TORIGHT, FALSE, FALSE, __LINE__); - test_lvm_subitemhittest(hwnd, x, y, 0, 1, LVHT_ONITEMLABEL, FALSE, FALSE, FALSE, __LINE__); - y = (bounds.bottom - bounds.top) / 2; - test_lvm_hittest(hwnd, x, y, -1, LVHT_TORIGHT, FALSE, TRUE, __LINE__); - test_lvm_subitemhittest(hwnd, x, y, 0, 1, LVHT_ONITEMLABEL, FALSE, FALSE, FALSE, __LINE__); - /* outside possible client rectangle (to right) */ - x = pos.x + 500; - y = pos.y + (bounds.bottom - bounds.top) / 2; - test_lvm_hittest(hwnd, x, y, -1, LVHT_TORIGHT, FALSE, FALSE, __LINE__); - test_lvm_subitemhittest(hwnd, x, y, -1, -1, LVHT_NOWHERE, FALSE, FALSE, FALSE, __LINE__); - y = (bounds.bottom - bounds.top) / 2; - test_lvm_hittest(hwnd, x, y, -1, LVHT_TORIGHT, FALSE, TRUE, __LINE__); - test_lvm_subitemhittest(hwnd, x, y, -1, -1, LVHT_NOWHERE, FALSE, FALSE, FALSE, __LINE__); - /* subitem returned with -1 item too */ - x = pos.x + 150; - y = -10; - test_lvm_subitemhittest(hwnd, x, y, -1, 1, LVHT_NOWHERE, FALSE, FALSE, FALSE, __LINE__); + test_lvm_subitemhittest(hwnd, x, y, 0, 1, LVHT_ONITEMLABEL, TRUE, TRUE, TRUE, __LINE__); /* parent client area is 100x100 by default */ MoveWindow(hwnd, 0, 0, 300, 100, FALSE); x = pos.x + 150; /* outside column */ y = pos.y + (bounds.bottom - bounds.top) / 2; test_lvm_hittest(hwnd, x, y, -1, LVHT_NOWHERE, FALSE, FALSE, __LINE__); test_lvm_subitemhittest(hwnd, x, y, 0, 1, LVHT_ONITEMLABEL, FALSE, FALSE, FALSE, __LINE__); - y = (bounds.bottom - bounds.top) / 2; - test_lvm_hittest(hwnd, x, y, -1, LVHT_NOWHERE, FALSE, TRUE, __LINE__); - test_lvm_subitemhittest(hwnd, x, y, 0, 1, LVHT_ONITEMLABEL, FALSE, FALSE, FALSE, __LINE__); /* the same with LVS_EX_FULLROWSELECT */ SendMessage(hwnd, LVM_SETEXTENDEDLISTVIEWSTYLE, 0, LVS_EX_FULLROWSELECT); x = pos.x + 150; /* outside column */ y = pos.y + (bounds.bottom - bounds.top) / 2; test_lvm_hittest(hwnd, x, y, 0, LVHT_ONITEM, FALSE, FALSE, __LINE__); test_lvm_subitemhittest(hwnd, x, y, 0, 1, LVHT_ONITEMLABEL, FALSE, FALSE, FALSE, __LINE__); - y = (bounds.bottom - bounds.top) / 2; - test_lvm_subitemhittest(hwnd, x, y, 0, 1, LVHT_ONITEMLABEL, FALSE, FALSE, FALSE, __LINE__); MoveWindow(hwnd, 0, 0, 100, 100, FALSE); x = pos.x + 150; /* outside column */ y = pos.y + (bounds.bottom - bounds.top) / 2; test_lvm_hittest(hwnd, x, y, -1, LVHT_TORIGHT, FALSE, FALSE, __LINE__); - test_lvm_subitemhittest(hwnd, x, y, 0, 1, LVHT_ONITEMLABEL, FALSE, FALSE, FALSE, __LINE__); - y = (bounds.bottom - bounds.top) / 2; - test_lvm_hittest(hwnd, x, y, -1, LVHT_TORIGHT, FALSE, TRUE, __LINE__); - test_lvm_subitemhittest(hwnd, x, y, 0, 1, LVHT_ONITEMLABEL, FALSE, FALSE, FALSE, __LINE__); - /* outside possible client rectangle (to right) */ - x = pos.x + 500; - y = pos.y + (bounds.bottom - bounds.top) / 2; - test_lvm_hittest(hwnd, x, y, -1, LVHT_TORIGHT, FALSE, FALSE, __LINE__); - test_lvm_subitemhittest(hwnd, x, y, -1, -1, LVHT_NOWHERE, FALSE, FALSE, FALSE, __LINE__); - y = (bounds.bottom - bounds.top) / 2; - test_lvm_hittest(hwnd, x, y, -1, LVHT_TORIGHT, FALSE, TRUE, __LINE__); - test_lvm_subitemhittest(hwnd, x, y, -1, -1, LVHT_NOWHERE, FALSE, FALSE, FALSE, __LINE__); + test_lvm_subitemhittest(hwnd, x, y, 0, 1, LVHT_ONITEMLABEL, TRUE, TRUE, TRUE, __LINE__); /* try with icons, state icons index is 1 based so at least 2 bitmaps needed */ himl = ImageList_Create(16, 16, 0, 4, 4); ok(himl != NULL, "failed to create imagelist\n"); @@ -2925,8 +2711,6 @@ static void test_hittest(void) y = pos.y + (bounds.bottom - bounds.top) / 2; test_lvm_hittest(hwnd, x, y, 0, LVHT_ONITEMSTATEICON, FALSE, FALSE, __LINE__); test_lvm_subitemhittest(hwnd, x, y, 0, 0, LVHT_ONITEMSTATEICON, FALSE, FALSE, FALSE, __LINE__); - y = (bounds.bottom - bounds.top) / 2; - test_lvm_subitemhittest(hwnd, x, y, 0, 0, LVHT_ONITEMSTATEICON, FALSE, FALSE, FALSE, __LINE__); /* state icons indices are 1 based, check with valid index */ item.mask = LVIF_STATE; @@ -2941,8 +2725,6 @@ static void test_hittest(void) y = pos.y + (bounds.bottom - bounds.top) / 2; test_lvm_hittest(hwnd, x, y, 0, LVHT_ONITEMSTATEICON, FALSE, FALSE, __LINE__); test_lvm_subitemhittest(hwnd, x, y, 0, 0, LVHT_ONITEMSTATEICON, FALSE, FALSE, FALSE, __LINE__); - y = (bounds.bottom - bounds.top) / 2; - test_lvm_subitemhittest(hwnd, x, y, 0, 0, LVHT_ONITEMSTATEICON, FALSE, FALSE, FALSE, __LINE__); himl2 = (HIMAGELIST)SendMessage(hwnd, LVM_SETIMAGELIST, LVSIL_STATE, (LPARAM)NULL); ok(himl2 == himl, "should return handle\n"); @@ -2954,8 +2736,6 @@ static void test_hittest(void) y = pos.y + (bounds.bottom - bounds.top) / 2; test_lvm_hittest(hwnd, x, y, 0, LVHT_ONITEMICON, FALSE, FALSE, __LINE__); test_lvm_subitemhittest(hwnd, x, y, 0, 0, LVHT_ONITEMICON, FALSE, FALSE, FALSE, __LINE__); - y = (bounds.bottom - bounds.top) / 2; - test_lvm_subitemhittest(hwnd, x, y, 0, 0, LVHT_ONITEMICON, FALSE, FALSE, FALSE, __LINE__); DestroyWindow(hwnd); } @@ -3256,7 +3036,7 @@ static void test_getitemrect(void) expect(TRUE, r); /* padding, column width */ expect(2, rect.left); - expect(50, rect.right); + todo_wine expect(50, rect.right); /* try with indentation */ item.mask = LVIF_INDENT; @@ -3282,7 +3062,7 @@ static void test_getitemrect(void) expect(TRUE, r); /* padding + 1 icon width, column width */ expect(2 + 16, rect.left); - expect(50, rect.right); + todo_wine expect(50, rect.right); /* label bounds */ rect.left = LVIR_LABEL; @@ -3422,7 +3202,7 @@ static void test_editbox(void) ok(hwndedit2 == NULL, "Expected Edit window not to be created\n"); ok(!IsWindow(hwndedit), "Expected Edit window to be destroyed\n"); ok(GetFocus() == hwnd, "Expected List to be focused\n"); - /* and value greater than max item index */ + /* and value greater then max item index */ hwndedit = (HWND)SendMessage(hwnd, LVM_EDITLABEL, 0, 0); ok(IsWindow(hwndedit), "Expected Edit window to be created\n"); ok(GetFocus() == hwndedit, "Expected Edit to be focused\n"); @@ -3530,7 +3310,7 @@ static void test_notifyformat(void) r = SendMessage(header, HDM_GETUNICODEFORMAT, 0, 0); expect(1, r); DestroyWindow(hwnd); - /* receiving error code defaulting to ansi */ + /* recieving error code defaulting to ansi */ notifyFormat = 0; hwnd = create_listview_controlW(0, hwndparentW); ok(hwnd != NULL, "failed to create a listview window\n"); @@ -3541,7 +3321,7 @@ static void test_notifyformat(void) r = SendMessage(header, HDM_GETUNICODEFORMAT, 0, 0); expect(1, r); DestroyWindow(hwnd); - /* receiving ansi code from unicode window, use it */ + /* recieving ansi code from unicode window, use it */ notifyFormat = NFR_ANSI; hwnd = create_listview_controlW(0, hwndparentW); ok(hwnd != NULL, "failed to create a listview window\n"); @@ -3628,24 +3408,6 @@ static BOOL is_below_comctl_5(void) return !ret; } -static void unload_v6_module(ULONG_PTR cookie) -{ - HANDLE hKernel32; - BOOL (WINAPI *pDeactivateActCtx)(DWORD, ULONG_PTR); - - hKernel32 = GetModuleHandleA("kernel32.dll"); - pDeactivateActCtx = (void*)GetProcAddress(hKernel32, "DeactivateActCtx"); - if (!pDeactivateActCtx) - { - win_skip("Activation contexts unsupported\n"); - return; - } - - pDeactivateActCtx(0, cookie); - - DeleteFileA(manifest_name); -} - static BOOL load_v6_module(ULONG_PTR *pcookie) { HANDLE hKernel32; @@ -3657,7 +3419,6 @@ static BOOL load_v6_module(ULONG_PTR *pcookie) BOOL ret; HANDLE file; DWORD written; - HWND hwnd; hKernel32 = GetModuleHandleA("kernel32.dll"); pCreateActCtxA = (void*)GetProcAddress(hKernel32, "CreateActCtxA"); @@ -3702,28 +3463,29 @@ static BOOL load_v6_module(ULONG_PTR *pcookie) if (!ret) { - win_skip("A problem during context activation occurred.\n"); + win_skip("A problem during context activation occured.\n"); DeleteFileA(manifest_name); } - else + return ret; +} + +static void unload_v6_module(ULONG_PTR cookie) +{ + HANDLE hKernel32; + BOOL (WINAPI *pDeactivateActCtx)(DWORD, ULONG_PTR); + + hKernel32 = GetModuleHandleA("kernel32.dll"); + pDeactivateActCtx = (void*)GetProcAddress(hKernel32, "DeactivateActCtx"); + if (!pDeactivateActCtx) { - /* this is a XP SP3 failure workaround */ - hwnd = CreateWindowExA(0, WC_LISTVIEW, "foo", - WS_CHILD | WS_BORDER | WS_VISIBLE | LVS_REPORT, - 0, 0, 100, 100, - hwndparent, NULL, GetModuleHandleA(NULL), NULL); - if (!IsWindow(hwnd)) - { - win_skip("FIXME: failed to create ListView window.\n"); - unload_v6_module(*pcookie); - return FALSE; - } - else - DestroyWindow(hwnd); + win_skip("Activation contexts unsupported\n"); + return; } - return ret; + pDeactivateActCtx(0, cookie); + + DeleteFileA(manifest_name); } static void test_get_set_view(void) @@ -3772,241 +3534,6 @@ static void test_get_set_view(void) DestroyWindow(hwnd); } -static void test_canceleditlabel(void) -{ - HWND hwnd, hwndedit; - DWORD ret; - CHAR buff[10]; - LVITEMA itema; - static CHAR test[] = "test"; - static const CHAR test1[] = "test1"; - - hwnd = create_listview_control(LVS_EDITLABELS); - ok(hwnd != NULL, "failed to create a listview window\n"); - - insert_item(hwnd, 0); - - /* try without edit created */ - ret = SendMessage(hwnd, LVM_CANCELEDITLABEL, 0, 0); - expect(TRUE, ret); - - /* cancel without data change */ - SetFocus(hwnd); - hwndedit = (HWND)SendMessage(hwnd, LVM_EDITLABEL, 0, 0); - ok(IsWindow(hwndedit), "Expected edit control to be created\n"); - ret = SendMessage(hwnd, LVM_CANCELEDITLABEL, 0, 0); - expect(TRUE, ret); - ok(!IsWindow(hwndedit), "Expected edit control to be destroyed\n"); - - /* cancel after data change */ - memset(&itema, 0, sizeof(itema)); - itema.pszText = test; - ret = SendMessage(hwnd, LVM_SETITEMTEXT, 0, (LPARAM)&itema); - expect(TRUE, ret); - SetFocus(hwnd); - hwndedit = (HWND)SendMessage(hwnd, LVM_EDITLABEL, 0, 0); - ok(IsWindow(hwndedit), "Expected edit control to be created\n"); - ret = SetWindowText(hwndedit, test1); - ok(ret != 0, "Expected edit text to change\n"); - ret = SendMessage(hwnd, LVM_CANCELEDITLABEL, 0, 0); - expect(TRUE, ret); - ok(!IsWindow(hwndedit), "Expected edit control to be destroyed\n"); - memset(&itema, 0, sizeof(itema)); - itema.pszText = buff; - itema.cchTextMax = sizeof(buff)/sizeof(CHAR); - ret = SendMessage(hwnd, LVM_GETITEMTEXT, 0, (LPARAM)&itema); - expect(5, ret); - ok(strcmp(buff, test1) == 0, "Expected label text not to change\n"); - - DestroyWindow(hwnd); -} - -static void test_mapidindex(void) -{ - HWND hwnd; - DWORD ret; - - /* LVM_MAPINDEXTOID unsupported with LVS_OWNERDATA */ - hwnd = create_listview_control(LVS_OWNERDATA); - ok(hwnd != NULL, "failed to create a listview window\n"); - insert_item(hwnd, 0); - ret = SendMessage(hwnd, LVM_MAPINDEXTOID, 0, 0); - expect(-1, ret); - DestroyWindow(hwnd); - - hwnd = create_listview_control(0); - ok(hwnd != NULL, "failed to create a listview window\n"); - - /* LVM_MAPINDEXTOID with invalid index */ - ret = SendMessage(hwnd, LVM_MAPINDEXTOID, 0, 0); - expect(-1, ret); - - insert_item(hwnd, 0); - insert_item(hwnd, 1); - - ret = SendMessage(hwnd, LVM_MAPINDEXTOID, -1, 0); - expect(-1, ret); - ret = SendMessage(hwnd, LVM_MAPINDEXTOID, 2, 0); - expect(-1, ret); - - ret = SendMessage(hwnd, LVM_MAPINDEXTOID, 0, 0); - expect(0, ret); - ret = SendMessage(hwnd, LVM_MAPINDEXTOID, 1, 0); - expect(1, ret); - /* remove 0 indexed item, id retained */ - SendMessage(hwnd, LVM_DELETEITEM, 0, 0); - ret = SendMessage(hwnd, LVM_MAPINDEXTOID, 0, 0); - expect(1, ret); - /* new id starts from previous value */ - insert_item(hwnd, 1); - ret = SendMessage(hwnd, LVM_MAPINDEXTOID, 1, 0); - expect(2, ret); - - /* get index by id */ - ret = SendMessage(hwnd, LVM_MAPIDTOINDEX, -1, 0); - expect(-1, ret); - ret = SendMessage(hwnd, LVM_MAPIDTOINDEX, 0, 0); - expect(-1, ret); - ret = SendMessage(hwnd, LVM_MAPIDTOINDEX, 1, 0); - expect(0, ret); - ret = SendMessage(hwnd, LVM_MAPIDTOINDEX, 2, 0); - expect(1, ret); - - DestroyWindow(hwnd); -} - -static void test_getitemspacing(void) -{ - HWND hwnd; - DWORD ret; - INT cx, cy; - HIMAGELIST himl; - HBITMAP hbmp; - LVITEMA itema; - - cx = GetSystemMetrics(SM_CXICONSPACING) - GetSystemMetrics(SM_CXICON); - cy = GetSystemMetrics(SM_CYICONSPACING) - GetSystemMetrics(SM_CYICON); - - /* LVS_ICON */ - hwnd = create_custom_listview_control(0); - ret = SendMessage(hwnd, LVM_GETITEMSPACING, FALSE, 0); -todo_wine { - expect(cx, LOWORD(ret)); - expect(cy, HIWORD(ret)); -} - /* now try with icons */ - himl = ImageList_Create(40, 40, 0, 4, 4); - ok(himl != NULL, "failed to create imagelist\n"); - hbmp = CreateBitmap(40, 40, 1, 1, NULL); - ok(hbmp != NULL, "failed to create bitmap\n"); - ret = ImageList_Add(himl, hbmp, 0); - expect(0, ret); - ret = SendMessage(hwnd, LVM_SETIMAGELIST, 0, (LPARAM)himl); - expect(0, ret); - - itema.mask = LVIF_IMAGE; - itema.iImage = 0; - itema.iItem = 0; - itema.iSubItem = 0; - ret = SendMessage(hwnd, LVM_INSERTITEM, 0, (LPARAM)&itema); - expect(0, ret); - ret = SendMessage(hwnd, LVM_GETITEMSPACING, FALSE, 0); -todo_wine { - /* spacing + icon size returned */ - expect(cx + 40, LOWORD(ret)); - expect(cy + 40, HIWORD(ret)); -} - DestroyWindow(hwnd); - /* LVS_SMALLICON */ - hwnd = create_custom_listview_control(LVS_SMALLICON); - ret = SendMessage(hwnd, LVM_GETITEMSPACING, FALSE, 0); -todo_wine { - expect(cx, LOWORD(ret)); - expect(cy, HIWORD(ret)); -} - DestroyWindow(hwnd); - /* LVS_REPORT */ - hwnd = create_custom_listview_control(LVS_REPORT); - ret = SendMessage(hwnd, LVM_GETITEMSPACING, FALSE, 0); -todo_wine { - expect(cx, LOWORD(ret)); - expect(cy, HIWORD(ret)); -} - DestroyWindow(hwnd); - /* LVS_LIST */ - hwnd = create_custom_listview_control(LVS_LIST); - ret = SendMessage(hwnd, LVM_GETITEMSPACING, FALSE, 0); -todo_wine { - expect(cx, LOWORD(ret)); - expect(cy, HIWORD(ret)); -} - DestroyWindow(hwnd); -} - -static void test_getcolumnwidth(void) -{ - HWND hwnd; - DWORD ret; - DWORD_PTR style; - LVCOLUMNA col; - - /* default column width */ - hwnd = create_custom_listview_control(0); - ret = SendMessage(hwnd, LVM_GETCOLUMNWIDTH, 0, 0); - expect(0, ret); - style = GetWindowLong(hwnd, GWL_STYLE); - SetWindowLong(hwnd, GWL_STYLE, style | LVS_LIST); - ret = SendMessage(hwnd, LVM_GETCOLUMNWIDTH, 0, 0); - todo_wine expect(8, ret); - style = GetWindowLong(hwnd, GWL_STYLE) & ~LVS_LIST; - SetWindowLong(hwnd, GWL_STYLE, style | LVS_REPORT); - col.mask = 0; - ret = SendMessage(hwnd, LVM_INSERTCOLUMNA, 0, (LPARAM)&col); - expect(0, ret); - ret = SendMessage(hwnd, LVM_GETCOLUMNWIDTH, 0, 0); - expect(10, ret); - DestroyWindow(hwnd); -} - -static void test_scrollnotify(void) -{ - HWND hwnd; - DWORD ret; - - hwnd = create_listview_control(0); - - insert_column(hwnd, 0); - insert_column(hwnd, 1); - insert_item(hwnd, 0); - - /* make it scrollable - resize */ - ret = SendMessage(hwnd, LVM_SETCOLUMNWIDTH, 0, MAKELPARAM(100, 0)); - expect(TRUE, ret); - ret = SendMessage(hwnd, LVM_SETCOLUMNWIDTH, 1, MAKELPARAM(100, 0)); - expect(TRUE, ret); - - /* try with dummy call */ - flush_sequences(sequences, NUM_MSG_SEQUENCES); - ret = SendMessage(hwnd, LVM_SCROLL, 0, 0); - expect(TRUE, ret); - ok_sequence(sequences, PARENT_SEQ_INDEX, scroll_parent_seq, - "scroll notify 1", TRUE); - - flush_sequences(sequences, NUM_MSG_SEQUENCES); - ret = SendMessage(hwnd, LVM_SCROLL, 1, 0); - expect(TRUE, ret); - ok_sequence(sequences, PARENT_SEQ_INDEX, scroll_parent_seq, - "scroll notify 2", TRUE); - - flush_sequences(sequences, NUM_MSG_SEQUENCES); - ret = SendMessage(hwnd, LVM_SCROLL, 1, 1); - expect(TRUE, ret); - ok_sequence(sequences, PARENT_SEQ_INDEX, scroll_parent_seq, - "scroll notify 3", TRUE); - - DestroyWindow(hwnd); -} - START_TEST(listview) { HMODULE hComctl32; @@ -4028,7 +3555,9 @@ START_TEST(listview) init_msg_sequences(sequences, NUM_MSG_SEQUENCES); + flush_sequences(sequences, NUM_MSG_SEQUENCES); hwndparent = create_parent_window(FALSE); + ok_sequence(sequences, PARENT_SEQ_INDEX, create_parent_wnd_seq, "create parent window", TRUE); flush_sequences(sequences, NUM_MSG_SEQUENCES); g_is_below_5 = is_below_comctl_5(); @@ -4060,8 +3589,6 @@ START_TEST(listview) test_editbox(); test_notifyformat(); test_indentation(); - test_getitemspacing(); - test_getcolumnwidth(); if (!load_v6_module(&ctx_cookie)) { @@ -4071,9 +3598,6 @@ START_TEST(listview) /* comctl32 version 6 tests start here */ test_get_set_view(); - test_canceleditlabel(); - test_mapidindex(); - test_scrollnotify(); unload_v6_module(ctx_cookie); diff --git a/dlls/comctl32/tests/rebar.c b/dlls/comctl32/tests/rebar.c index 2af9ab13a5f..c819bc78f9b 100644 --- a/dlls/comctl32/tests/rebar.c +++ b/dlls/comctl32/tests/rebar.c @@ -150,7 +150,7 @@ static void dump_sizes(HWND hRebar) for (i=0; ibands[i].fStyle & RBBS_HIDDEN)) \ check_rect("band", rc, res->bands[i].rc); \ - rbi.cbSize = REBARBANDINFOA_V6_SIZE; \ + rbi.cbSize = sizeof(REBARBANDINFO); \ rbi.fMask = RBBIM_STYLE | RBBIM_SIZE; \ ok(SendMessageA(hRebar, RB_GETBANDINFO, i, (LPARAM)&rbi) == 1, "RB_GETBANDINFO\n"); \ compare(rbi.fStyle, res->bands[i].fStyle, "%x"); \ @@ -329,11 +329,11 @@ static int rbsize_numtests = 0; static void add_band_w(HWND hRebar, LPCSTR lpszText, int cxMinChild, int cx, int cxIdeal) { CHAR buffer[MAX_PATH]; - REBARBANDINFOA rbi; + REBARBANDINFO rbi; if (lpszText != NULL) strcpy(buffer, lpszText); - rbi.cbSize = REBARBANDINFOA_V6_SIZE; + rbi.cbSize = sizeof(rbi); rbi.fMask = RBBIM_SIZE | RBBIM_CHILDSIZE | RBBIM_CHILD | RBBIM_IDEALSIZE | RBBIM_TEXT; rbi.cx = cx; rbi.cxMinChild = cxMinChild; @@ -353,7 +353,7 @@ static void layout_test(void) rebuild_rebar(&hRebar); check_sizes(); - rbi.cbSize = REBARBANDINFOA_V6_SIZE; + rbi.cbSize = sizeof(rbi); rbi.fMask = RBBIM_SIZE | RBBIM_CHILDSIZE | RBBIM_CHILD; rbi.cx = 200; rbi.cxMinChild = 100; @@ -742,10 +742,10 @@ static void expect_band_content(UINT uBand, INT fStyle, COLORREF clrFore, INT cxHeader) { CHAR buf[MAX_PATH] = "abc"; - REBARBANDINFOA rb; + REBARBANDINFO rb; memset(&rb, 0xdd, sizeof(rb)); - rb.cbSize = REBARBANDINFOA_V6_SIZE; + rb.cbSize = sizeof(rb); rb.fMask = RBBIM_BACKGROUND | RBBIM_CHILD | RBBIM_CHILDSIZE | RBBIM_COLORS | RBBIM_HEADERSIZE | RBBIM_ID | RBBIM_IDEALSIZE | RBBIM_IMAGE | RBBIM_LPARAM | RBBIM_SIZE | RBBIM_STYLE | RBBIM_TEXT; @@ -779,7 +779,7 @@ static void bandinfo_test(void) CHAR szABCD[] = "ABCD"; rebuild_rebar(&hRebar); - rb.cbSize = REBARBANDINFOA_V6_SIZE; + rb.cbSize = sizeof(REBARBANDINFO); rb.fMask = 0; ok(SendMessageA(hRebar, RB_INSERTBANDA, 0, (LPARAM)&rb), "RB_INSERTBAND failed\n"); expect_band_content(0, 0, 0, GetSysColor(COLOR_3DFACE), "", -1, NULL, 0, 0, 0, NULL, 0, 0xdddddddd, 0xdddddddd, 0xdddddddd, 0, 0, 0); @@ -798,7 +798,7 @@ static void bandinfo_test(void) ok(SendMessageA(hRebar, RB_SETBANDINFOA, 0, (LPARAM)&rb), "RB_SETBANDINFO failed\n"); expect_band_content(0, 0, 0, GetSysColor(COLOR_3DFACE), "ABC", -1, NULL, 15, 20, 0, NULL, 0, 0xdddddddd, 0xdddddddd, 0xdddddddd, 0, 0, 35); - rb.cbSize = REBARBANDINFOA_V6_SIZE; + rb.cbSize = sizeof(REBARBANDINFO); rb.fMask = 0; ok(SendMessageA(hRebar, RB_INSERTBANDA, 1, (LPARAM)&rb), "RB_INSERTBAND failed\n"); expect_band_content(1, 0, 0, GetSysColor(COLOR_3DFACE), "", -1, NULL, 0, 0, 0, NULL, 0, 0xdddddddd, 0xdddddddd, 0xdddddddd, 0, 0, 9); diff --git a/dlls/comctl32/tests/toolbar.c b/dlls/comctl32/tests/toolbar.c index 9827b147823..19460952349 100644 --- a/dlls/comctl32/tests/toolbar.c +++ b/dlls/comctl32/tests/toolbar.c @@ -415,7 +415,7 @@ static void test_add_bitmap(void) ok(strcmp(_buf, (tab)[_i]) == 0, "Invalid string #%d - '%s' vs '%s'\n", _i, (tab)[_i], _buf); \ } \ ok(SendMessageA(hToolbar, TB_GETSTRING, MAKEWPARAM(260, (count)), (LPARAM)_buf) == -1, \ - "Too many strings in table\n"); \ + "Too many string in table\n"); \ } static void test_add_string(void) @@ -432,17 +432,10 @@ static void test_add_string(void) HWND hToolbar = NULL; TBBUTTON button; int ret; - CHAR buf[260]; rebuild_toolbar(&hToolbar); ret = SendMessageA(hToolbar, TB_ADDSTRINGA, 0, (LPARAM)test1); ok(ret == 0, "TB_ADDSTRINGA - unexpected return %d\n", ret); - ret = SendMessageA(hToolbar, TB_GETSTRING, MAKEWPARAM(260, 1), (LPARAM)buf); - if (ret == 0) - { - win_skip("TB_GETSTRING needs 5.80\n"); - return; - } CHECK_STRING_TABLE(2, ret1); ret = SendMessageA(hToolbar, TB_ADDSTRINGA, 0, (LPARAM)test2); ok(ret == 2, "TB_ADDSTRINGA - unexpected return %d\n", ret); @@ -1288,12 +1281,6 @@ static void test_getstring(void) ok(hToolbar != NULL, "Toolbar creation problem\n"); r = SendMessage(hToolbar, TB_GETSTRING, MAKEWPARAM(0, 0), 0); - if (r == 0) - { - win_skip("TB_GETSTRING and TB_GETSTRINGW need 5.80\n"); - DestroyWindow(hToolbar); - return; - } expect(-1, r); r = SendMessage(hToolbar, TB_GETSTRINGW, MAKEWPARAM(0, 0), 0); expect(-1, r); diff --git a/dlls/comctl32/tests/updown.c b/dlls/comctl32/tests/updown.c index f2b3cc28c07..433c190ae97 100644 --- a/dlls/comctl32/tests/updown.c +++ b/dlls/comctl32/tests/updown.c @@ -426,14 +426,8 @@ static void test_updown_pos32(void) expect(0,low); expect(1000,high); - /* Set position to 500 */ - r = SendMessage(updown, UDM_SETPOS32, 0 , 500 ); - if (!r) - { - win_skip("UDM_SETPOS32 and UDM_GETPOS32 need 5.80\n"); - return; - } - expect(100,r); /* As set by test_updown_pos() */ + /* Set position to 500, don't check return since it is unset*/ + SendMessage(updown, UDM_SETPOS32, 0 , 500 ); /* Since UDM_SETBUDDYINT was not set at creation bRet will always be true as a return from UDM_GETPOS32 */ diff --git a/dlls/comctl32/toolbar.c b/dlls/comctl32/toolbar.c index 0d11b2b65a8..9bbac21edb4 100644 --- a/dlls/comctl32/toolbar.c +++ b/dlls/comctl32/toolbar.c @@ -1801,7 +1801,7 @@ TOOLBAR_InternalHitTest (const TOOLBAR_INFO *infoPtr, const POINT *lpPt) /* worker for TB_ADDBUTTONS and TB_INSERTBUTTON */ static BOOL -TOOLBAR_InternalInsertButtonsT(TOOLBAR_INFO *infoPtr, INT iIndex, UINT nAddButtons, const TBBUTTON *lpTbb, BOOL fUnicode) +TOOLBAR_InternalInsertButtonsT(TOOLBAR_INFO *infoPtr, INT iIndex, UINT nAddButtons, TBBUTTON *lpTbb, BOOL fUnicode) { INT nOldButtons, nNewButtons, iButton; BOOL fHasString = FALSE; @@ -2767,13 +2767,14 @@ TOOLBAR_CheckImageListIconSize(TOOLBAR_INFO *infoPtr) * */ static LRESULT -TOOLBAR_AddBitmap (TOOLBAR_INFO *infoPtr, INT count, const TBADDBITMAP *lpAddBmp) +TOOLBAR_AddBitmap (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { + LPTBADDBITMAP lpAddBmp = (LPTBADDBITMAP)lParam; TBITMAP_INFO info; INT iSumButtons, i; HIMAGELIST himlDef; - TRACE("hwnd=%p count=%d lpAddBmp=%p\n", infoPtr->hwndSelf, count, lpAddBmp); + TRACE("hwnd=%p wParam=%lx lParam=%lx\n", infoPtr->hwndSelf, wParam, lParam); if (!lpAddBmp) return -1; @@ -2828,7 +2829,7 @@ TOOLBAR_AddBitmap (TOOLBAR_INFO *infoPtr, INT count, const TBADDBITMAP *lpAddBmp } else { - info.nButtons = count; + info.nButtons = (INT)wParam; info.hInst = lpAddBmp->hInst; info.nID = lpAddBmp->nID; TRACE("adding %d bitmaps!\n", info.nButtons); @@ -2877,22 +2878,25 @@ TOOLBAR_AddBitmap (TOOLBAR_INFO *infoPtr, INT count, const TBADDBITMAP *lpAddBmp static LRESULT -TOOLBAR_AddButtonsT(TOOLBAR_INFO *infoPtr, INT nAddButtons, const TBBUTTON* lpTbb, BOOL fUnicode) +TOOLBAR_AddButtonsT(TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam, BOOL fUnicode) { - TRACE("adding %d buttons (unicode=%d)!\n", nAddButtons, fUnicode); + LPTBBUTTON lpTbb = (LPTBBUTTON)lParam; + INT nAddButtons = (UINT)wParam; + + TRACE("adding %ld buttons (unicode=%d)!\n", wParam, fUnicode); return TOOLBAR_InternalInsertButtonsT(infoPtr, -1, nAddButtons, lpTbb, fUnicode); } static LRESULT -TOOLBAR_AddStringW (TOOLBAR_INFO *infoPtr, HINSTANCE hInstance, LPARAM lParam) +TOOLBAR_AddStringW (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { #define MAX_RESOURCE_STRING_LENGTH 512 BOOL fFirstString = (infoPtr->nNumStrings == 0); INT nIndex = infoPtr->nNumStrings; - if (hInstance && (HIWORD(lParam) == 0)) { + if ((wParam) && (HIWORD(lParam) == 0)) { WCHAR szString[MAX_RESOURCE_STRING_LENGTH]; WCHAR delimiter; WCHAR *next_delim; @@ -2900,7 +2904,7 @@ TOOLBAR_AddStringW (TOOLBAR_INFO *infoPtr, HINSTANCE hInstance, LPARAM lParam) INT len; TRACE("adding string from resource!\n"); - len = LoadStringW (hInstance, (UINT)lParam, + len = LoadStringW ((HINSTANCE)wParam, (UINT)lParam, szString, MAX_RESOURCE_STRING_LENGTH); TRACE("len=%d %s\n", len, debugstr_w(szString)); @@ -2953,15 +2957,15 @@ TOOLBAR_AddStringW (TOOLBAR_INFO *infoPtr, HINSTANCE hInstance, LPARAM lParam) static LRESULT -TOOLBAR_AddStringA (TOOLBAR_INFO *infoPtr, HINSTANCE hInstance, LPARAM lParam) +TOOLBAR_AddStringA (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { BOOL fFirstString = (infoPtr->nNumStrings == 0); LPSTR p; INT nIndex; INT len; - if (hInstance && (HIWORD(lParam) == 0)) /* load from resources */ - return TOOLBAR_AddStringW(infoPtr, hInstance, lParam); + if ((wParam) && (HIWORD(lParam) == 0)) /* load from resources */ + return TOOLBAR_AddStringW(infoPtr, wParam, lParam); p = (LPSTR)lParam; if (p == NULL) @@ -3054,36 +3058,36 @@ TOOLBAR_AutoSize (TOOLBAR_INFO *infoPtr) } -static inline LRESULT +static LRESULT TOOLBAR_ButtonCount (const TOOLBAR_INFO *infoPtr) { return infoPtr->nNumButtons; } -static inline LRESULT -TOOLBAR_ButtonStructSize (TOOLBAR_INFO *infoPtr, DWORD Size) +static LRESULT +TOOLBAR_ButtonStructSize (TOOLBAR_INFO *infoPtr, WPARAM wParam) { - infoPtr->dwStructSize = Size; + infoPtr->dwStructSize = (DWORD)wParam; return 0; } static LRESULT -TOOLBAR_ChangeBitmap (TOOLBAR_INFO *infoPtr, INT Id, INT Index) +TOOLBAR_ChangeBitmap (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { TBUTTON_INFO *btnPtr; INT nIndex; - TRACE("button %d, iBitmap now %d\n", Id, Index); + TRACE("button %ld, iBitmap now %d\n", wParam, LOWORD(lParam)); - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return FALSE; btnPtr = &infoPtr->buttons[nIndex]; - btnPtr->iBitmap = Index; + btnPtr->iBitmap = LOWORD(lParam); /* we HAVE to erase the background, the new bitmap could be */ /* transparent */ @@ -3094,14 +3098,14 @@ TOOLBAR_ChangeBitmap (TOOLBAR_INFO *infoPtr, INT Id, INT Index) static LRESULT -TOOLBAR_CheckButton (TOOLBAR_INFO *infoPtr, INT Id, LPARAM lParam) +TOOLBAR_CheckButton (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { TBUTTON_INFO *btnPtr; INT nIndex; INT nOldIndex = -1; BOOL bChecked = FALSE; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); TRACE("hwnd=%p, btn index=%d, lParam=0x%08lx\n", infoPtr->hwndSelf, nIndex, lParam); @@ -3140,9 +3144,9 @@ TOOLBAR_CheckButton (TOOLBAR_INFO *infoPtr, INT Id, LPARAM lParam) static LRESULT -TOOLBAR_CommandToIndex (const TOOLBAR_INFO *infoPtr, INT Id) +TOOLBAR_CommandToIndex (const TOOLBAR_INFO *infoPtr, WPARAM wParam) { - return TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + return TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); } @@ -3181,8 +3185,9 @@ TOOLBAR_Customize (TOOLBAR_INFO *infoPtr) static LRESULT -TOOLBAR_DeleteButton (TOOLBAR_INFO *infoPtr, INT nIndex) +TOOLBAR_DeleteButton (TOOLBAR_INFO *infoPtr, WPARAM wParam) { + INT nIndex = (INT)wParam; NMTOOLBARW nmtb; TBUTTON_INFO *btnPtr = &infoPtr->buttons[nIndex]; @@ -3235,15 +3240,15 @@ TOOLBAR_DeleteButton (TOOLBAR_INFO *infoPtr, INT nIndex) static LRESULT -TOOLBAR_EnableButton (TOOLBAR_INFO *infoPtr, INT Id, LPARAM lParam) +TOOLBAR_EnableButton (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { TBUTTON_INFO *btnPtr; INT nIndex; DWORD bState; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); - TRACE("hwnd=%p, btn id=%d, lParam=0x%08lx\n", infoPtr->hwndSelf, Id, lParam); + TRACE("hwnd=%p, btn index=%ld, lParam=0x%08lx\n", infoPtr->hwndSelf, wParam, lParam); if (nIndex == -1) return FALSE; @@ -3275,11 +3280,11 @@ TOOLBAR_GetAnchorHighlight (const TOOLBAR_INFO *infoPtr) static LRESULT -TOOLBAR_GetBitmap (const TOOLBAR_INFO *infoPtr, INT Id) +TOOLBAR_GetBitmap (const TOOLBAR_INFO *infoPtr, WPARAM wParam) { INT nIndex; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return -1; @@ -3295,8 +3300,10 @@ TOOLBAR_GetBitmapFlags (void) static LRESULT -TOOLBAR_GetButton (const TOOLBAR_INFO *infoPtr, INT nIndex, TBBUTTON *lpTbb) +TOOLBAR_GetButton (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { + LPTBBUTTON lpTbb = (LPTBBUTTON)lParam; + INT nIndex = (INT)wParam; TBUTTON_INFO *btnPtr; if (lpTbb == NULL) @@ -3320,9 +3327,10 @@ TOOLBAR_GetButton (const TOOLBAR_INFO *infoPtr, INT nIndex, TBBUTTON *lpTbb) static LRESULT -TOOLBAR_GetButtonInfoT(const TOOLBAR_INFO *infoPtr, INT Id, LPTBBUTTONINFOW lpTbInfo, BOOL bUnicode) +TOOLBAR_GetButtonInfoT(const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam, BOOL bUnicode) { /* TBBUTTONINFOW and TBBUTTONINFOA have the same layout*/ + LPTBBUTTONINFOW lpTbInfo = (LPTBBUTTONINFOW)lParam; TBUTTON_INFO *btnPtr; INT nIndex; @@ -3339,7 +3347,8 @@ TOOLBAR_GetButtonInfoT(const TOOLBAR_INFO *infoPtr, INT Id, LPTBBUTTONINFOW lpTb return -1; } - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, lpTbInfo->dwMask & TBIF_BYINDEX); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, + lpTbInfo->dwMask & 0x80000000); if (nIndex == -1) return -1; @@ -3377,7 +3386,7 @@ TOOLBAR_GetButtonInfoT(const TOOLBAR_INFO *infoPtr, INT Id, LPTBBUTTONINFOW lpTb } -static inline LRESULT +static LRESULT TOOLBAR_GetButtonSize (const TOOLBAR_INFO *infoPtr) { return MAKELONG((WORD)infoPtr->nButtonWidth, @@ -3386,30 +3395,30 @@ TOOLBAR_GetButtonSize (const TOOLBAR_INFO *infoPtr) static LRESULT -TOOLBAR_GetButtonTextA (const TOOLBAR_INFO *infoPtr, INT Id, LPSTR lpText) +TOOLBAR_GetButtonTextA (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { INT nIndex; - LPWSTR lpTextW; + LPWSTR lpText; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return -1; - lpTextW = TOOLBAR_GetText(infoPtr,&infoPtr->buttons[nIndex]); + lpText = TOOLBAR_GetText(infoPtr,&infoPtr->buttons[nIndex]); - return WideCharToMultiByte( CP_ACP, 0, lpTextW, -1, - lpText, lpText ? 0x7fffffff : 0, NULL, NULL ) - 1; + return WideCharToMultiByte( CP_ACP, 0, lpText, -1, + (LPSTR)lParam, lParam ? 0x7fffffff : 0, NULL, NULL ) - 1; } static LRESULT -TOOLBAR_GetButtonTextW (const TOOLBAR_INFO *infoPtr, INT Id, LPWSTR lpStr) +TOOLBAR_GetButtonTextW (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { INT nIndex; LPWSTR lpText; LRESULT ret = 0; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return -1; @@ -3419,8 +3428,8 @@ TOOLBAR_GetButtonTextW (const TOOLBAR_INFO *infoPtr, INT Id, LPWSTR lpStr) { ret = strlenW (lpText); - if (lpStr) - strcpyW (lpStr, lpText); + if (lParam) + strcpyW ((LPWSTR)lParam, lpText); } return ret; @@ -3428,9 +3437,9 @@ TOOLBAR_GetButtonTextW (const TOOLBAR_INFO *infoPtr, INT Id, LPWSTR lpStr) static LRESULT -TOOLBAR_GetDisabledImageList (const TOOLBAR_INFO *infoPtr, WPARAM wParam) +TOOLBAR_GetDisabledImageList (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { - TRACE("hwnd=%p, wParam=%ld\n", infoPtr->hwndSelf, wParam); + TRACE("hwnd=%p, wParam=%ld, lParam=0x%lx\n", infoPtr->hwndSelf, wParam, lParam); /* UNDOCUMENTED: wParam is actually the ID of the image list to return */ return (LRESULT)GETDISIMAGELIST(infoPtr, wParam); } @@ -3446,9 +3455,9 @@ TOOLBAR_GetExtendedStyle (const TOOLBAR_INFO *infoPtr) static LRESULT -TOOLBAR_GetHotImageList (const TOOLBAR_INFO *infoPtr, WPARAM wParam) +TOOLBAR_GetHotImageList (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { - TRACE("hwnd=%p, wParam=%ld\n", infoPtr->hwndSelf, wParam); + TRACE("hwnd=%p, wParam=%ld, lParam=0x%lx\n", infoPtr->hwndSelf, wParam, lParam); /* UNDOCUMENTED: wParam is actually the ID of the image list to return */ return (LRESULT)GETHOTIMAGELIST(infoPtr, wParam); } @@ -3468,17 +3477,19 @@ TOOLBAR_GetHotItem (const TOOLBAR_INFO *infoPtr) static LRESULT -TOOLBAR_GetDefImageList (const TOOLBAR_INFO *infoPtr, WPARAM wParam) +TOOLBAR_GetDefImageList (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { - TRACE("hwnd=%p, wParam=%ld\n", infoPtr->hwndSelf, wParam); + TRACE("hwnd=%p, wParam=%ld, lParam=0x%lx\n", infoPtr->hwndSelf, wParam, lParam); /* UNDOCUMENTED: wParam is actually the ID of the image list to return */ return (LRESULT) GETDEFIMAGELIST(infoPtr, wParam); } static LRESULT -TOOLBAR_GetInsertMark (const TOOLBAR_INFO *infoPtr, TBINSERTMARK *lptbim) +TOOLBAR_GetInsertMark (const TOOLBAR_INFO *infoPtr, LPARAM lParam) { + TBINSERTMARK *lptbim = (TBINSERTMARK*)lParam; + TRACE("hwnd = %p, lptbim = %p\n", infoPtr->hwndSelf, lptbim); *lptbim = infoPtr->tbim; @@ -3487,7 +3498,7 @@ TOOLBAR_GetInsertMark (const TOOLBAR_INFO *infoPtr, TBINSERTMARK *lptbim) } -static inline LRESULT +static LRESULT TOOLBAR_GetInsertMarkColor (const TOOLBAR_INFO *infoPtr) { TRACE("hwnd = %p\n", infoPtr->hwndSelf); @@ -3497,14 +3508,17 @@ TOOLBAR_GetInsertMarkColor (const TOOLBAR_INFO *infoPtr) static LRESULT -TOOLBAR_GetItemRect (const TOOLBAR_INFO *infoPtr, INT nIndex, LPRECT lpRect) +TOOLBAR_GetItemRect (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { TBUTTON_INFO *btnPtr; + LPRECT lpRect; + INT nIndex; + nIndex = (INT)wParam; btnPtr = &infoPtr->buttons[nIndex]; if ((nIndex < 0) || (nIndex >= infoPtr->nNumButtons)) return FALSE; - + lpRect = (LPRECT)lParam; if (lpRect == NULL) return FALSE; if (btnPtr->fsState & TBSTATE_HIDDEN) @@ -3520,8 +3534,10 @@ TOOLBAR_GetItemRect (const TOOLBAR_INFO *infoPtr, INT nIndex, LPRECT lpRect) static LRESULT -TOOLBAR_GetMaxSize (const TOOLBAR_INFO *infoPtr, LPSIZE lpSize) +TOOLBAR_GetMaxSize (const TOOLBAR_INFO *infoPtr, LPARAM lParam) { + LPSIZE lpSize = (LPSIZE)lParam; + if (lpSize == NULL) return FALSE; @@ -3539,24 +3555,28 @@ TOOLBAR_GetMaxSize (const TOOLBAR_INFO *infoPtr, LPSIZE lpSize) /* << TOOLBAR_GetObject >> */ -static inline LRESULT +static LRESULT TOOLBAR_GetPadding (const TOOLBAR_INFO *infoPtr) { - return MAKELONG(infoPtr->szPadding.cx, infoPtr->szPadding.cy); + DWORD oldPad; + + oldPad = MAKELONG(infoPtr->szPadding.cx, infoPtr->szPadding.cy); + return (LRESULT) oldPad; } static LRESULT -TOOLBAR_GetRect (const TOOLBAR_INFO *infoPtr, INT Id, LPRECT lpRect) +TOOLBAR_GetRect (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { TBUTTON_INFO *btnPtr; + LPRECT lpRect; INT nIndex; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); btnPtr = &infoPtr->buttons[nIndex]; if ((nIndex < 0) || (nIndex >= infoPtr->nNumButtons)) return FALSE; - + lpRect = (LPRECT)lParam; if (lpRect == NULL) return FALSE; @@ -3569,7 +3589,7 @@ TOOLBAR_GetRect (const TOOLBAR_INFO *infoPtr, INT Id, LPRECT lpRect) } -static inline LRESULT +static LRESULT TOOLBAR_GetRows (const TOOLBAR_INFO *infoPtr) { return infoPtr->nRows; @@ -3577,11 +3597,11 @@ TOOLBAR_GetRows (const TOOLBAR_INFO *infoPtr) static LRESULT -TOOLBAR_GetState (const TOOLBAR_INFO *infoPtr, INT Id) +TOOLBAR_GetState (const TOOLBAR_INFO *infoPtr, WPARAM wParam) { INT nIndex; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return -1; @@ -3589,14 +3609,14 @@ TOOLBAR_GetState (const TOOLBAR_INFO *infoPtr, INT Id) } -static inline LRESULT +static LRESULT TOOLBAR_GetStyle (const TOOLBAR_INFO *infoPtr) { return infoPtr->dwStyle; } -static inline LRESULT +static LRESULT TOOLBAR_GetTextRows (const TOOLBAR_INFO *infoPtr) { return infoPtr->nMaxTextRows; @@ -3630,23 +3650,22 @@ TOOLBAR_GetVersion (const TOOLBAR_INFO *infoPtr) static LRESULT -TOOLBAR_HideButton (TOOLBAR_INFO *infoPtr, INT Id, BOOL fHide) +TOOLBAR_HideButton (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { TBUTTON_INFO *btnPtr; INT nIndex; TRACE("\n"); - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return FALSE; btnPtr = &infoPtr->buttons[nIndex]; - - if (fHide) - btnPtr->fsState |= TBSTATE_HIDDEN; - else + if (LOWORD(lParam) == FALSE) btnPtr->fsState &= ~TBSTATE_HIDDEN; + else + btnPtr->fsState |= TBSTATE_HIDDEN; TOOLBAR_LayoutToolbar (infoPtr); @@ -3657,30 +3676,29 @@ TOOLBAR_HideButton (TOOLBAR_INFO *infoPtr, INT Id, BOOL fHide) static inline LRESULT -TOOLBAR_HitTest (const TOOLBAR_INFO *infoPtr, const POINT* lpPt) +TOOLBAR_HitTest (const TOOLBAR_INFO *infoPtr, LPARAM lParam) { - return TOOLBAR_InternalHitTest (infoPtr, lpPt); + return TOOLBAR_InternalHitTest (infoPtr, (LPPOINT)lParam); } static LRESULT -TOOLBAR_Indeterminate (const TOOLBAR_INFO *infoPtr, INT Id, BOOL fIndeterminate) +TOOLBAR_Indeterminate (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { TBUTTON_INFO *btnPtr; INT nIndex; DWORD oldState; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return FALSE; btnPtr = &infoPtr->buttons[nIndex]; oldState = btnPtr->fsState; - - if (fIndeterminate) - btnPtr->fsState |= TBSTATE_INDETERMINATE; - else + if (LOWORD(lParam) == FALSE) btnPtr->fsState &= ~TBSTATE_INDETERMINATE; + else + btnPtr->fsState |= TBSTATE_INDETERMINATE; if(oldState != btnPtr->fsState) InvalidateRect(infoPtr->hwndSelf, &btnPtr->rect, TRUE); @@ -3690,8 +3708,11 @@ TOOLBAR_Indeterminate (const TOOLBAR_INFO *infoPtr, INT Id, BOOL fIndeterminate) static LRESULT -TOOLBAR_InsertButtonT(TOOLBAR_INFO *infoPtr, INT nIndex, const TBBUTTON *lpTbb, BOOL fUnicode) +TOOLBAR_InsertButtonT(TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam, BOOL fUnicode) { + LPTBBUTTON lpTbb = (LPTBBUTTON)lParam; + INT nIndex = (INT)wParam; + if (lpTbb == NULL) return FALSE; @@ -3720,11 +3741,11 @@ TOOLBAR_InsertButtonT(TOOLBAR_INFO *infoPtr, INT nIndex, const TBBUTTON *lpTbb, static LRESULT -TOOLBAR_IsButtonChecked (const TOOLBAR_INFO *infoPtr, INT Id) +TOOLBAR_IsButtonChecked (const TOOLBAR_INFO *infoPtr, WPARAM wParam) { INT nIndex; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return -1; @@ -3733,11 +3754,11 @@ TOOLBAR_IsButtonChecked (const TOOLBAR_INFO *infoPtr, INT Id) static LRESULT -TOOLBAR_IsButtonEnabled (const TOOLBAR_INFO *infoPtr, INT Id) +TOOLBAR_IsButtonEnabled (const TOOLBAR_INFO *infoPtr, WPARAM wParam) { INT nIndex; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return -1; @@ -3746,11 +3767,11 @@ TOOLBAR_IsButtonEnabled (const TOOLBAR_INFO *infoPtr, INT Id) static LRESULT -TOOLBAR_IsButtonHidden (const TOOLBAR_INFO *infoPtr, INT Id) +TOOLBAR_IsButtonHidden (const TOOLBAR_INFO *infoPtr, WPARAM wParam) { INT nIndex; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return -1; @@ -3759,11 +3780,11 @@ TOOLBAR_IsButtonHidden (const TOOLBAR_INFO *infoPtr, INT Id) static LRESULT -TOOLBAR_IsButtonHighlighted (const TOOLBAR_INFO *infoPtr, INT Id) +TOOLBAR_IsButtonHighlighted (const TOOLBAR_INFO *infoPtr, WPARAM wParam) { INT nIndex; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return -1; @@ -3772,11 +3793,11 @@ TOOLBAR_IsButtonHighlighted (const TOOLBAR_INFO *infoPtr, INT Id) static LRESULT -TOOLBAR_IsButtonIndeterminate (const TOOLBAR_INFO *infoPtr, INT Id) +TOOLBAR_IsButtonIndeterminate (const TOOLBAR_INFO *infoPtr, WPARAM wParam) { INT nIndex; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return -1; @@ -3785,11 +3806,11 @@ TOOLBAR_IsButtonIndeterminate (const TOOLBAR_INFO *infoPtr, INT Id) static LRESULT -TOOLBAR_IsButtonPressed (const TOOLBAR_INFO *infoPtr, INT Id) +TOOLBAR_IsButtonPressed (const TOOLBAR_INFO *infoPtr, WPARAM wParam) { INT nIndex; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return -1; @@ -3798,21 +3819,23 @@ TOOLBAR_IsButtonPressed (const TOOLBAR_INFO *infoPtr, INT Id) static LRESULT -TOOLBAR_LoadImages (TOOLBAR_INFO *infoPtr, WPARAM wParam, HINSTANCE hInstance) +TOOLBAR_LoadImages (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { TBADDBITMAP tbab; - tbab.hInst = hInstance; + tbab.hInst = (HINSTANCE)lParam; tbab.nID = wParam; TRACE("hwnd = %p, hInst = %p, nID = %lu\n", infoPtr->hwndSelf, tbab.hInst, tbab.nID); - return TOOLBAR_AddBitmap(infoPtr, 0, &tbab); + return TOOLBAR_AddBitmap(infoPtr, 0, (LPARAM)&tbab); } static LRESULT -TOOLBAR_MapAccelerator (const TOOLBAR_INFO *infoPtr, WCHAR wAccel, UINT *pIDButton) +TOOLBAR_MapAccelerator (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { + WCHAR wAccel = (WCHAR)wParam; + UINT* pIDButton = (UINT*)lParam; WCHAR wszAccel[] = {'&',wAccel,0}; int i; @@ -3852,22 +3875,22 @@ TOOLBAR_MapAccelerator (const TOOLBAR_INFO *infoPtr, WCHAR wAccel, UINT *pIDButt static LRESULT -TOOLBAR_MarkButton (const TOOLBAR_INFO *infoPtr, INT Id, BOOL fMark) +TOOLBAR_MarkButton (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { INT nIndex; DWORD oldState; TBUTTON_INFO *btnPtr; - TRACE("hwnd = %p, Id = %d, fMark = 0%d\n", infoPtr->hwndSelf, Id, fMark); + TRACE("hwnd = %p, wParam = %ld, lParam = 0x%08lx\n", infoPtr->hwndSelf, wParam, lParam); - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return FALSE; btnPtr = &infoPtr->buttons[nIndex]; oldState = btnPtr->fsState; - if (fMark) + if (LOWORD(lParam)) btnPtr->fsState |= TBSTATE_MARKED; else btnPtr->fsState &= ~TBSTATE_MARKED; @@ -3900,15 +3923,16 @@ static inline void TOOLBAR_MoveFixupIndex(INT* pIndex, INT nIndex, INT nMoveInde static LRESULT -TOOLBAR_MoveButton (TOOLBAR_INFO *infoPtr, INT Id, INT nMoveIndex) +TOOLBAR_MoveButton (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { INT nIndex; INT nCount; + INT nMoveIndex = (INT)lParam; TBUTTON_INFO button; - TRACE("hwnd=%p, Id=%d, nMoveIndex=%d\n", infoPtr->hwndSelf, Id, nMoveIndex); + TRACE("hwnd=%p, wParam=%ld, lParam=%ld\n", infoPtr->hwndSelf, wParam, lParam); - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, TRUE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, TRUE); if ((nIndex == -1) || (nMoveIndex < 0)) return FALSE; @@ -3950,23 +3974,22 @@ TOOLBAR_MoveButton (TOOLBAR_INFO *infoPtr, INT Id, INT nMoveIndex) static LRESULT -TOOLBAR_PressButton (const TOOLBAR_INFO *infoPtr, INT Id, BOOL fPress) +TOOLBAR_PressButton (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { TBUTTON_INFO *btnPtr; INT nIndex; DWORD oldState; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return FALSE; btnPtr = &infoPtr->buttons[nIndex]; oldState = btnPtr->fsState; - - if (fPress) - btnPtr->fsState |= TBSTATE_PRESSED; - else + if (LOWORD(lParam) == FALSE) btnPtr->fsState &= ~TBSTATE_PRESSED; + else + btnPtr->fsState |= TBSTATE_PRESSED; if(oldState != btnPtr->fsState) InvalidateRect(infoPtr->hwndSelf, &btnPtr->rect, TRUE); @@ -3977,8 +4000,9 @@ TOOLBAR_PressButton (const TOOLBAR_INFO *infoPtr, INT Id, BOOL fPress) /* FIXME: there might still be some confusion her between number of buttons * and number of bitmaps */ static LRESULT -TOOLBAR_ReplaceBitmap (TOOLBAR_INFO *infoPtr, const TBREPLACEBITMAP *lpReplace) +TOOLBAR_ReplaceBitmap (TOOLBAR_INFO *infoPtr, LPARAM lParam) { + LPTBREPLACEBITMAP lpReplace = (LPTBREPLACEBITMAP) lParam; HBITMAP hBitmap; int i = 0, nOldButtons = 0, pos = 0; int nOldBitmaps, nNewBitmaps = 0; @@ -4158,7 +4182,7 @@ TOOLBAR_Restore(TOOLBAR_INFO *infoPtr, const TBSAVEPARAMSW *lpSave) if (HIWORD(nmtbr.tbButton.iString)) nmtbr.tbButton.iString = 0; - TOOLBAR_InsertButtonT(infoPtr, -1, &nmtbr.tbButton, TRUE); + TOOLBAR_InsertButtonT(infoPtr, -1, (LPARAM)&nmtbr.tbButton, TRUE); } /* do legacy notifications */ @@ -4233,13 +4257,13 @@ exit: static LRESULT -TOOLBAR_SetAnchorHighlight (TOOLBAR_INFO *infoPtr, BOOL bAnchor) +TOOLBAR_SetAnchorHighlight (TOOLBAR_INFO *infoPtr, WPARAM wParam) { BOOL bOldAnchor = infoPtr->bAnchor; - TRACE("hwnd=%p, bAnchor = %s\n", infoPtr->hwndSelf, bAnchor ? "TRUE" : "FALSE"); + TRACE("hwnd=%p, bAnchor = %s\n", infoPtr->hwndSelf, wParam ? "TRUE" : "FALSE"); - infoPtr->bAnchor = bAnchor; + infoPtr->bAnchor = (BOOL)wParam; /* Native does not remove the hot effect from an already hot button */ @@ -4298,8 +4322,9 @@ TOOLBAR_SetBitmapSize (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) static LRESULT -TOOLBAR_SetButtonInfoA (TOOLBAR_INFO *infoPtr, INT Id, const TBBUTTONINFOA *lptbbi) +TOOLBAR_SetButtonInfoA (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { + LPTBBUTTONINFOA lptbbi = (LPTBBUTTONINFOA)lParam; TBUTTON_INFO *btnPtr; INT nIndex; RECT oldBtnRect; @@ -4309,7 +4334,8 @@ TOOLBAR_SetButtonInfoA (TOOLBAR_INFO *infoPtr, INT Id, const TBBUTTONINFOA *lptb if (lptbbi->cbSize < sizeof(TBBUTTONINFOA)) return FALSE; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, lptbbi->dwMask & TBIF_BYINDEX); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, + lptbbi->dwMask & 0x80000000); if (nIndex == -1) return FALSE; @@ -4349,8 +4375,9 @@ TOOLBAR_SetButtonInfoA (TOOLBAR_INFO *infoPtr, INT Id, const TBBUTTONINFOA *lptb static LRESULT -TOOLBAR_SetButtonInfoW (TOOLBAR_INFO *infoPtr, INT Id, const TBBUTTONINFOW *lptbbi) +TOOLBAR_SetButtonInfoW (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { + LPTBBUTTONINFOW lptbbi = (LPTBBUTTONINFOW)lParam; TBUTTON_INFO *btnPtr; INT nIndex; RECT oldBtnRect; @@ -4360,7 +4387,8 @@ TOOLBAR_SetButtonInfoW (TOOLBAR_INFO *infoPtr, INT Id, const TBBUTTONINFOW *lptb if (lptbbi->cbSize < sizeof(TBBUTTONINFOW)) return FALSE; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, lptbbi->dwMask & TBIF_BYINDEX); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, + lptbbi->dwMask & 0x80000000); if (nIndex == -1) return FALSE; @@ -4467,12 +4495,14 @@ TOOLBAR_SetButtonWidth (TOOLBAR_INFO *infoPtr, LPARAM lParam) static LRESULT -TOOLBAR_SetCmdId (TOOLBAR_INFO *infoPtr, INT nIndex, INT nId) +TOOLBAR_SetCmdId (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { + INT nIndex = (INT)wParam; + if ((nIndex < 0) || (nIndex >= infoPtr->nNumButtons)) return FALSE; - infoPtr->buttons[nIndex].idCommand = nId; + infoPtr->buttons[nIndex].idCommand = (INT)lParam; if (infoPtr->hwndToolTip) { @@ -4485,8 +4515,9 @@ TOOLBAR_SetCmdId (TOOLBAR_INFO *infoPtr, INT nIndex, INT nId) static LRESULT -TOOLBAR_SetDisabledImageList (TOOLBAR_INFO *infoPtr, WPARAM wParam, HIMAGELIST himl) +TOOLBAR_SetDisabledImageList (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { + HIMAGELIST himl = (HIMAGELIST)lParam; HIMAGELIST himlTemp; INT id = 0; @@ -4549,9 +4580,10 @@ TOOLBAR_SetExtendedStyle (TOOLBAR_INFO *infoPtr, LPARAM lParam) static LRESULT -TOOLBAR_SetHotImageList (TOOLBAR_INFO *infoPtr, WPARAM wParam, HIMAGELIST himl) +TOOLBAR_SetHotImageList (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { HIMAGELIST himlTemp; + HIMAGELIST himl = (HIMAGELIST)lParam; INT id = 0; if (infoPtr->iVersion >= 5) @@ -4626,22 +4658,22 @@ TOOLBAR_SetHotItemEx (TOOLBAR_INFO *infoPtr, INT nHit, DWORD dwReason) } static LRESULT -TOOLBAR_SetHotItem (TOOLBAR_INFO *infoPtr, INT nHotItem) +TOOLBAR_SetHotItem (TOOLBAR_INFO *infoPtr, WPARAM wParam) { INT nOldHotItem = infoPtr->nHotItem; - TRACE("hwnd = %p, nHotItem = %d\n", infoPtr->hwndSelf, nHotItem); + TRACE("hwnd = %p, nHit = %d\n", infoPtr->hwndSelf, (INT)wParam); - if (nHotItem >= infoPtr->nNumButtons) + if ((INT)wParam >= infoPtr->nNumButtons) return infoPtr->nHotItem; - if (nHotItem < 0) - nHotItem = -1; + if ((INT)wParam < 0) + wParam = -1; /* NOTE: an application can still remove the hot item even if anchor * highlighting is enabled */ - TOOLBAR_SetHotItemEx(infoPtr, nHotItem, HICF_OTHER); + TOOLBAR_SetHotItemEx(infoPtr, wParam, HICF_OTHER); if (nOldHotItem < 0) return -1; @@ -4651,9 +4683,10 @@ TOOLBAR_SetHotItem (TOOLBAR_INFO *infoPtr, INT nHotItem) static LRESULT -TOOLBAR_SetImageList (TOOLBAR_INFO *infoPtr, WPARAM wParam, HIMAGELIST himl) +TOOLBAR_SetImageList (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { HIMAGELIST himlTemp; + HIMAGELIST himl = (HIMAGELIST)lParam; INT oldButtonWidth = infoPtr->nButtonWidth; INT oldBitmapWidth = infoPtr->nBitmapWidth; INT oldBitmapHeight = infoPtr->nBitmapHeight; @@ -4693,16 +4726,16 @@ TOOLBAR_SetImageList (TOOLBAR_INFO *infoPtr, WPARAM wParam, HIMAGELIST himl) static LRESULT -TOOLBAR_SetIndent (TOOLBAR_INFO *infoPtr, INT nIndent) +TOOLBAR_SetIndent (TOOLBAR_INFO *infoPtr, WPARAM wParam) { - infoPtr->nIndent = nIndent; + infoPtr->nIndent = (INT)wParam; TRACE("\n"); /* process only on indent changing */ - if(infoPtr->nIndent != nIndent) + if(infoPtr->nIndent != (INT)wParam) { - infoPtr->nIndent = nIndent; + infoPtr->nIndent = (INT)wParam; TOOLBAR_CalcToolbar (infoPtr); InvalidateRect(infoPtr->hwndSelf, NULL, FALSE); } @@ -4712,8 +4745,10 @@ TOOLBAR_SetIndent (TOOLBAR_INFO *infoPtr, INT nIndent) static LRESULT -TOOLBAR_SetInsertMark (TOOLBAR_INFO *infoPtr, const TBINSERTMARK *lptbim) +TOOLBAR_SetInsertMark (TOOLBAR_INFO *infoPtr, LPARAM lParam) { + TBINSERTMARK *lptbim = (TBINSERTMARK*)lParam; + TRACE("hwnd = %p, lptbim = { %d, 0x%08x}\n", infoPtr->hwndSelf, lptbim->iButton, lptbim->dwFlags); if ((lptbim->dwFlags & ~TBIMHT_AFTER) != 0) @@ -4738,9 +4773,9 @@ TOOLBAR_SetInsertMark (TOOLBAR_INFO *infoPtr, const TBINSERTMARK *lptbim) static LRESULT -TOOLBAR_SetInsertMarkColor (TOOLBAR_INFO *infoPtr, COLORREF clr) +TOOLBAR_SetInsertMarkColor (TOOLBAR_INFO *infoPtr, LPARAM lParam) { - infoPtr->clrInsertMark = clr; + infoPtr->clrInsertMark = (COLORREF)lParam; /* FIXME: don't need to update entire toolbar */ InvalidateRect(infoPtr->hwndSelf, NULL, TRUE); @@ -4750,9 +4785,9 @@ TOOLBAR_SetInsertMarkColor (TOOLBAR_INFO *infoPtr, COLORREF clr) static LRESULT -TOOLBAR_SetMaxTextRows (TOOLBAR_INFO *infoPtr, INT nMaxRows) +TOOLBAR_SetMaxTextRows (TOOLBAR_INFO *infoPtr, WPARAM wParam) { - infoPtr->nMaxTextRows = nMaxRows; + infoPtr->nMaxTextRows = (INT)wParam; TOOLBAR_CalcToolbar(infoPtr); return TRUE; @@ -4785,22 +4820,23 @@ TOOLBAR_SetPadding (TOOLBAR_INFO *infoPtr, LPARAM lParam) static LRESULT -TOOLBAR_SetParent (TOOLBAR_INFO *infoPtr, HWND hParent) +TOOLBAR_SetParent (TOOLBAR_INFO *infoPtr, WPARAM wParam) { HWND hwndOldNotify; TRACE("\n"); hwndOldNotify = infoPtr->hwndNotify; - infoPtr->hwndNotify = hParent; + infoPtr->hwndNotify = (HWND)wParam; return (LRESULT)hwndOldNotify; } static LRESULT -TOOLBAR_SetRows (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPRECT lprc) +TOOLBAR_SetRows (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { + LPRECT lprc = (LPRECT)lParam; int rows = LOWORD(wParam); BOOL bLarger = HIWORD(wParam); @@ -4846,7 +4882,7 @@ TOOLBAR_SetRows (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPRECT lprc) if (seps) FIXME("Separators unhandled\n"); /* Round up so more per line, i.e., less rows */ - idealWrap = (infoPtr->nNumButtons - hidden + (rows-1)) / (rows ? rows : 1); + idealWrap = (infoPtr->nNumButtons - hidden + (rows-1)) / rows; /* Calculate ideal wrap point if we are allowed to grow, but cannot achieve the requested number of rows. */ @@ -4919,12 +4955,12 @@ TOOLBAR_SetRows (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPRECT lprc) static LRESULT -TOOLBAR_SetState (TOOLBAR_INFO *infoPtr, INT Id, LPARAM lParam) +TOOLBAR_SetState (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { TBUTTON_INFO *btnPtr; INT nIndex; - nIndex = TOOLBAR_GetButtonIndex (infoPtr, Id, FALSE); + nIndex = TOOLBAR_GetButtonIndex (infoPtr, (INT)wParam, FALSE); if (nIndex == -1) return FALSE; @@ -4959,11 +4995,11 @@ TOOLBAR_SetStyle (TOOLBAR_INFO *infoPtr, LPARAM lParam) static inline LRESULT -TOOLBAR_SetToolTips (TOOLBAR_INFO *infoPtr, HWND hwndTooltip) +TOOLBAR_SetToolTips (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { - TRACE("hwnd=%p, hwndTooltip=%p\n", infoPtr->hwndSelf, hwndTooltip); + TRACE("hwnd=%p, hwndTooltip=%p, lParam=0x%lx\n", infoPtr->hwndSelf, (HWND)wParam, lParam); - infoPtr->hwndToolTip = hwndTooltip; + infoPtr->hwndToolTip = (HWND)wParam; return 0; } @@ -5024,10 +5060,11 @@ TOOLBAR_SetVersion (TOOLBAR_INFO *infoPtr, INT iVersion) static LRESULT -TOOLBAR_GetStringA (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPSTR str) +TOOLBAR_GetStringA (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { WORD iString = HIWORD(wParam); WORD buffersize = LOWORD(wParam); + LPSTR str = (LPSTR)lParam; LRESULT ret = -1; TRACE("hwnd=%p, iString=%d, buffersize=%d, string=%p\n", infoPtr->hwndSelf, iString, buffersize, str); @@ -5047,10 +5084,11 @@ TOOLBAR_GetStringA (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPSTR str) static LRESULT -TOOLBAR_GetStringW (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPWSTR str) +TOOLBAR_GetStringW (const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { WORD iString = HIWORD(wParam); WORD len = LOWORD(wParam)/sizeof(WCHAR) - 1; + LPWSTR str = (LPWSTR)lParam; LRESULT ret = -1; TRACE("hwnd=%p, iString=%d, buffersize=%d, string=%p\n", infoPtr->hwndSelf, iString, LOWORD(wParam), str); @@ -5088,20 +5126,20 @@ static LRESULT TOOLBAR_Unkwn45D(HWND hwnd, WPARAM wParam, LPARAM lParam) * caller to specify a reason why the hot item changed (rather than just the * HICF_OTHER that TB_SETHOTITEM sends). */ static LRESULT -TOOLBAR_SetHotItem2 (TOOLBAR_INFO *infoPtr, INT nHotItem, LPARAM lParam) +TOOLBAR_SetHotItem2 (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { INT nOldHotItem = infoPtr->nHotItem; TRACE("old item=%d, new item=%d, flags=%08x\n", - nOldHotItem, nHotItem, (DWORD)lParam); + nOldHotItem, infoPtr->nHotItem, (DWORD)lParam); - if (nHotItem < 0 || nHotItem > infoPtr->nNumButtons) - nHotItem = -1; + if ((INT) wParam < 0 || (INT)wParam > infoPtr->nNumButtons) + wParam = -1; /* NOTE: an application can still remove the hot item even if anchor * highlighting is enabled */ - TOOLBAR_SetHotItemEx(infoPtr, nHotItem, lParam); + TOOLBAR_SetHotItemEx(infoPtr, wParam, lParam); GetFocus(); @@ -5111,11 +5149,11 @@ TOOLBAR_SetHotItem2 (TOOLBAR_INFO *infoPtr, INT nHotItem, LPARAM lParam) /* Sets the toolbar global iListGap parameter which controls the amount of * spacing between the image and the text of buttons for TBSTYLE_LIST * toolbars. */ -static LRESULT TOOLBAR_SetListGap(TOOLBAR_INFO *infoPtr, INT iListGap) +static LRESULT TOOLBAR_SetListGap(TOOLBAR_INFO *infoPtr, WPARAM wParam) { - TRACE("hwnd=%p iListGap=%d\n", infoPtr->hwndSelf, iListGap); + TRACE("hwnd=%p iListGap=%ld\n", infoPtr->hwndSelf, wParam); - infoPtr->iListGap = iListGap; + infoPtr->iListGap = (INT)wParam; InvalidateRect(infoPtr->hwndSelf, NULL, TRUE); @@ -5124,9 +5162,9 @@ static LRESULT TOOLBAR_SetListGap(TOOLBAR_INFO *infoPtr, INT iListGap) /* Returns the number of maximum number of image lists associated with the * various states. */ -static LRESULT TOOLBAR_GetImageListCount(const TOOLBAR_INFO *infoPtr) +static LRESULT TOOLBAR_GetImageListCount(const TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { - TRACE("hwnd=%p\n", infoPtr->hwndSelf); + TRACE("hwnd=%p wParam %08lx lParam %08lx\n", infoPtr->hwndSelf, wParam, lParam); return max(infoPtr->cimlDef, max(infoPtr->cimlHot, infoPtr->cimlDis)); } @@ -5191,7 +5229,7 @@ static LRESULT TOOLBAR_Unkwn464(HWND hwnd, WPARAM wParam, LPARAM lParam) static LRESULT -TOOLBAR_Create (HWND hwnd, const CREATESTRUCTW *lpcs) +TOOLBAR_Create (HWND hwnd, LPARAM lParam) { TOOLBAR_INFO *infoPtr = (TOOLBAR_INFO *)GetWindowLongPtrW(hwnd, 0); DWORD dwStyle = GetWindowLongW (hwnd, GWL_STYLE); @@ -5199,7 +5237,38 @@ TOOLBAR_Create (HWND hwnd, const CREATESTRUCTW *lpcs) TRACE("hwnd = %p\n", hwnd); + /* initialize info structure */ + infoPtr->nButtonWidth = 23; + infoPtr->nButtonHeight = 22; + infoPtr->nBitmapHeight = 16; + infoPtr->nBitmapWidth = 16; + + infoPtr->nMaxTextRows = 1; + infoPtr->cxMin = -1; + infoPtr->cxMax = -1; + infoPtr->nNumBitmaps = 0; + infoPtr->nNumStrings = 0; + + infoPtr->bCaptured = FALSE; + infoPtr->nButtonDown = -1; + infoPtr->nButtonDrag = -1; + infoPtr->nOldHit = -1; + infoPtr->nHotItem = -1; + infoPtr->hwndNotify = ((LPCREATESTRUCTW)lParam)->hwndParent; + infoPtr->dwDTFlags = (dwStyle & TBSTYLE_LIST) ? DT_LEFT | DT_VCENTER | DT_SINGLELINE | DT_END_ELLIPSIS: DT_CENTER | DT_END_ELLIPSIS; + infoPtr->bAnchor = FALSE; /* no anchor highlighting */ + infoPtr->bDragOutSent = FALSE; + infoPtr->iVersion = 0; + infoPtr->hwndSelf = hwnd; + infoPtr->bDoRedraw = TRUE; + infoPtr->clrBtnHighlight = CLR_DEFAULT; + infoPtr->clrBtnShadow = CLR_DEFAULT; + infoPtr->szPadding.cx = DEFPAD_CX; + infoPtr->szPadding.cy = DEFPAD_CY; + infoPtr->iListGap = DEFLISTGAP; + infoPtr->iTopMargin = default_top_margin(infoPtr); infoPtr->dwStyle = dwStyle; + infoPtr->tbim.iButton = -1; GetClientRect(hwnd, &infoPtr->client_rect); infoPtr->bUnicode = infoPtr->hwndNotify && (NFR_UNICODE == SendMessageW(hwnd, WM_NOTIFYFORMAT, (WPARAM)hwnd, (LPARAM)NF_REQUERY)); @@ -5333,7 +5402,7 @@ TOOLBAR_EraseBackground (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) } -static inline LRESULT +static LRESULT TOOLBAR_GetFont (const TOOLBAR_INFO *infoPtr) { return (LRESULT)infoPtr->hFont; @@ -5626,7 +5695,7 @@ TOOLBAR_LButtonUp (TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) memset(&tbb, 0, sizeof(tbb)); tbb.fsStyle = BTNS_SEP; tbb.iString = -1; - TOOLBAR_InsertButtonT(infoPtr, nButton, &tbb, TRUE); + TOOLBAR_InsertButtonT(infoPtr, nButton, (LPARAM)&tbb, TRUE); } } else @@ -5930,9 +5999,10 @@ TOOLBAR_NCCalcSize (HWND hwnd, WPARAM wParam, LPARAM lParam) static LRESULT -TOOLBAR_NCCreate (HWND hwnd, WPARAM wParam, const CREATESTRUCTW *lpcs) +TOOLBAR_NCCreate (HWND hwnd, WPARAM wParam, LPARAM lParam) { TOOLBAR_INFO *infoPtr; + LPCREATESTRUCTA cs = (LPCREATESTRUCTA)lParam; DWORD styleadd = 0; /* allocate memory for info structure */ @@ -5944,39 +6014,6 @@ TOOLBAR_NCCreate (HWND hwnd, WPARAM wParam, const CREATESTRUCTW *lpcs) infoPtr->nRows = 1; infoPtr->nWidth = 0; - /* initialize info structure */ - infoPtr->nButtonWidth = 23; - infoPtr->nButtonHeight = 22; - infoPtr->nBitmapHeight = 16; - infoPtr->nBitmapWidth = 16; - - infoPtr->nMaxTextRows = 1; - infoPtr->cxMin = -1; - infoPtr->cxMax = -1; - infoPtr->nNumBitmaps = 0; - infoPtr->nNumStrings = 0; - - infoPtr->bCaptured = FALSE; - infoPtr->nButtonDown = -1; - infoPtr->nButtonDrag = -1; - infoPtr->nOldHit = -1; - infoPtr->nHotItem = -1; - infoPtr->hwndNotify = lpcs->hwndParent; - infoPtr->dwDTFlags = (lpcs->style & TBSTYLE_LIST) ? DT_LEFT | DT_VCENTER | DT_SINGLELINE | DT_END_ELLIPSIS: DT_CENTER | DT_END_ELLIPSIS; - infoPtr->bAnchor = FALSE; /* no anchor highlighting */ - infoPtr->bDragOutSent = FALSE; - infoPtr->iVersion = 0; - infoPtr->hwndSelf = hwnd; - infoPtr->bDoRedraw = TRUE; - infoPtr->clrBtnHighlight = CLR_DEFAULT; - infoPtr->clrBtnShadow = CLR_DEFAULT; - infoPtr->szPadding.cx = DEFPAD_CX; - infoPtr->szPadding.cy = DEFPAD_CY; - infoPtr->iListGap = DEFLISTGAP; - infoPtr->iTopMargin = default_top_margin(infoPtr); - infoPtr->dwStyle = lpcs->style; - infoPtr->tbim.iButton = -1; - /* fix instance handle, if the toolbar was created by CreateToolbarEx() */ if (!GetWindowLongPtrW (hwnd, GWLP_HINSTANCE)) { HINSTANCE hInst = (HINSTANCE)GetWindowLongPtrW (GetParent (hwnd), GWLP_HINSTANCE); @@ -6029,14 +6066,14 @@ TOOLBAR_NCCreate (HWND hwnd, WPARAM wParam, const CREATESTRUCTW *lpcs) * */ if (((infoPtr->dwStyle & TBSTYLE_FLAT) || GetWindowTheme (infoPtr->hwndSelf)) - && !(lpcs->style & TBSTYLE_TRANSPARENT)) + && !(cs->style & TBSTYLE_TRANSPARENT)) styleadd |= TBSTYLE_TRANSPARENT; - if (!(lpcs->style & (CCS_TOP | CCS_NOMOVEY))) { + if (!(cs->style & (CCS_TOP | CCS_NOMOVEY))) { styleadd |= CCS_TOP; /* default to top */ - SetWindowLongW (hwnd, GWL_STYLE, lpcs->style | styleadd); + SetWindowLongW (hwnd, GWL_STYLE, cs->style | styleadd); } - return DefWindowProcW (hwnd, WM_NCCREATE, wParam, (LPARAM)lpcs); + return DefWindowProcW (hwnd, WM_NCCREATE, wParam, lParam); } @@ -6200,13 +6237,15 @@ static LRESULT TOOLBAR_TTGetDispInfo (TOOLBAR_INFO *infoPtr, NMTTDISPINFOW *lpnm static inline LRESULT -TOOLBAR_Notify (TOOLBAR_INFO *infoPtr, LPNMHDR lpnmh) +TOOLBAR_Notify (TOOLBAR_INFO *infoPtr, LPARAM lParam) { + LPNMHDR lpnmh = (LPNMHDR)lParam; + switch (lpnmh->code) { case PGN_CALCSIZE: { - LPNMPGCALCSIZE lppgc = (LPNMPGCALCSIZE)lpnmh; + LPNMPGCALCSIZE lppgc = (LPNMPGCALCSIZE)lParam; if (lppgc->dwFlag == PGF_CALCWIDTH) { lppgc->iWidth = infoPtr->rcBound.right - infoPtr->rcBound.left; @@ -6223,7 +6262,7 @@ TOOLBAR_Notify (TOOLBAR_INFO *infoPtr, LPNMHDR lpnmh) case PGN_SCROLL: { - LPNMPGSCROLL lppgs = (LPNMPGSCROLL)lpnmh; + LPNMPGSCROLL lppgs = (LPNMPGSCROLL)lParam; lppgs->iScroll = (lppgs->iDir & (PGF_SCROLLLEFT | PGF_SCROLLRIGHT)) ? infoPtr->nButtonWidth : infoPtr->nButtonHeight; @@ -6233,7 +6272,7 @@ TOOLBAR_Notify (TOOLBAR_INFO *infoPtr, LPNMHDR lpnmh) } case TTN_GETDISPINFOW: - return TOOLBAR_TTGetDispInfo(infoPtr, (LPNMTTDISPINFOW)lpnmh); + return TOOLBAR_TTGetDispInfo(infoPtr, (LPNMTTDISPINFOW)lParam); case TTN_GETDISPINFOA: FIXME("TTN_GETDISPINFOA - should not be received; please report\n"); @@ -6302,18 +6341,18 @@ TOOLBAR_SetFocus (TOOLBAR_INFO *infoPtr) } static LRESULT -TOOLBAR_SetFont(TOOLBAR_INFO *infoPtr, HFONT hFont, WORD Redraw) +TOOLBAR_SetFont(TOOLBAR_INFO *infoPtr, WPARAM wParam, LPARAM lParam) { - TRACE("font=%p redraw=%d\n", hFont, Redraw); + TRACE("font=%p redraw=%ld\n", (HFONT)wParam, lParam); - if (hFont == 0) + if (wParam == 0) infoPtr->hFont = infoPtr->hDefaultFont; else - infoPtr->hFont = hFont; + infoPtr->hFont = (HFONT)wParam; TOOLBAR_CalcToolbar(infoPtr); - if (Redraw) + if (lParam) InvalidateRect(infoPtr->hwndSelf, NULL, TRUE); return 1; } @@ -6463,19 +6502,19 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) switch (uMsg) { case TB_ADDBITMAP: - return TOOLBAR_AddBitmap (infoPtr, (INT)wParam, (TBADDBITMAP*)lParam); + return TOOLBAR_AddBitmap (infoPtr, wParam, lParam); case TB_ADDBUTTONSA: - return TOOLBAR_AddButtonsT(infoPtr, wParam, (LPTBBUTTON)lParam, FALSE); + return TOOLBAR_AddButtonsT(infoPtr, wParam, lParam, FALSE); case TB_ADDBUTTONSW: - return TOOLBAR_AddButtonsT(infoPtr, wParam, (LPTBBUTTON)lParam, TRUE); + return TOOLBAR_AddButtonsT(infoPtr, wParam, lParam, TRUE); case TB_ADDSTRINGA: - return TOOLBAR_AddStringA (infoPtr, (HINSTANCE)wParam, lParam); + return TOOLBAR_AddStringA (infoPtr, wParam, lParam); case TB_ADDSTRINGW: - return TOOLBAR_AddStringW (infoPtr, (HINSTANCE)wParam, lParam); + return TOOLBAR_AddStringW (infoPtr, wParam, lParam); case TB_AUTOSIZE: return TOOLBAR_AutoSize (infoPtr); @@ -6487,7 +6526,7 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_ButtonStructSize (infoPtr, wParam); case TB_CHANGEBITMAP: - return TOOLBAR_ChangeBitmap (infoPtr, wParam, LOWORD(lParam)); + return TOOLBAR_ChangeBitmap (infoPtr, wParam, lParam); case TB_CHECKBUTTON: return TOOLBAR_CheckButton (infoPtr, wParam, lParam); @@ -6514,49 +6553,49 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_GetBitmapFlags (); case TB_GETBUTTON: - return TOOLBAR_GetButton (infoPtr, wParam, (TBBUTTON*)lParam); + return TOOLBAR_GetButton (infoPtr, wParam, lParam); case TB_GETBUTTONINFOA: - return TOOLBAR_GetButtonInfoT(infoPtr, wParam, (LPTBBUTTONINFOW)lParam, FALSE); + return TOOLBAR_GetButtonInfoT(infoPtr, wParam, lParam, FALSE); case TB_GETBUTTONINFOW: - return TOOLBAR_GetButtonInfoT(infoPtr, wParam, (LPTBBUTTONINFOW)lParam, TRUE); + return TOOLBAR_GetButtonInfoT(infoPtr, wParam, lParam, TRUE); case TB_GETBUTTONSIZE: return TOOLBAR_GetButtonSize (infoPtr); case TB_GETBUTTONTEXTA: - return TOOLBAR_GetButtonTextA (infoPtr, wParam, (LPSTR)lParam); + return TOOLBAR_GetButtonTextA (infoPtr, wParam, lParam); case TB_GETBUTTONTEXTW: - return TOOLBAR_GetButtonTextW (infoPtr, wParam, (LPWSTR)lParam); + return TOOLBAR_GetButtonTextW (infoPtr, wParam, lParam); case TB_GETDISABLEDIMAGELIST: - return TOOLBAR_GetDisabledImageList (infoPtr, wParam); + return TOOLBAR_GetDisabledImageList (infoPtr, wParam, lParam); case TB_GETEXTENDEDSTYLE: return TOOLBAR_GetExtendedStyle (infoPtr); case TB_GETHOTIMAGELIST: - return TOOLBAR_GetHotImageList (infoPtr, wParam); + return TOOLBAR_GetHotImageList (infoPtr, wParam, lParam); case TB_GETHOTITEM: return TOOLBAR_GetHotItem (infoPtr); case TB_GETIMAGELIST: - return TOOLBAR_GetDefImageList (infoPtr, wParam); + return TOOLBAR_GetDefImageList (infoPtr, wParam, lParam); case TB_GETINSERTMARK: - return TOOLBAR_GetInsertMark (infoPtr, (TBINSERTMARK*)lParam); + return TOOLBAR_GetInsertMark (infoPtr, lParam); case TB_GETINSERTMARKCOLOR: return TOOLBAR_GetInsertMarkColor (infoPtr); case TB_GETITEMRECT: - return TOOLBAR_GetItemRect (infoPtr, wParam, (LPRECT)lParam); + return TOOLBAR_GetItemRect (infoPtr, wParam, lParam); case TB_GETMAXSIZE: - return TOOLBAR_GetMaxSize (infoPtr, (LPSIZE)lParam); + return TOOLBAR_GetMaxSize (infoPtr, lParam); /* case TB_GETOBJECT: */ /* 4.71 */ @@ -6564,7 +6603,7 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_GetPadding (infoPtr); case TB_GETRECT: - return TOOLBAR_GetRect (infoPtr, wParam, (LPRECT)lParam); + return TOOLBAR_GetRect (infoPtr, wParam, lParam); case TB_GETROWS: return TOOLBAR_GetRows (infoPtr); @@ -6573,10 +6612,10 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_GetState (infoPtr, wParam); case TB_GETSTRINGA: - return TOOLBAR_GetStringA (infoPtr, wParam, (LPSTR)lParam); + return TOOLBAR_GetStringA (infoPtr, wParam, lParam); case TB_GETSTRINGW: - return TOOLBAR_GetStringW (infoPtr, wParam, (LPWSTR)lParam); + return TOOLBAR_GetStringW (infoPtr, wParam, lParam); case TB_GETSTYLE: return TOOLBAR_GetStyle (infoPtr); @@ -6591,19 +6630,19 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_GetUnicodeFormat (infoPtr); case TB_HIDEBUTTON: - return TOOLBAR_HideButton (infoPtr, wParam, LOWORD(lParam)); + return TOOLBAR_HideButton (infoPtr, wParam, lParam); case TB_HITTEST: - return TOOLBAR_HitTest (infoPtr, (LPPOINT)lParam); + return TOOLBAR_HitTest (infoPtr, lParam); case TB_INDETERMINATE: - return TOOLBAR_Indeterminate (infoPtr, wParam, LOWORD(lParam)); + return TOOLBAR_Indeterminate (infoPtr, wParam, lParam); case TB_INSERTBUTTONA: - return TOOLBAR_InsertButtonT(infoPtr, wParam, (TBBUTTON*)lParam, FALSE); + return TOOLBAR_InsertButtonT(infoPtr, wParam, lParam, FALSE); case TB_INSERTBUTTONW: - return TOOLBAR_InsertButtonT(infoPtr, wParam, (TBBUTTON*)lParam, TRUE); + return TOOLBAR_InsertButtonT(infoPtr, wParam, lParam, TRUE); /* case TB_INSERTMARKHITTEST: */ /* 4.71 */ @@ -6626,23 +6665,23 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_IsButtonPressed (infoPtr, wParam); case TB_LOADIMAGES: - return TOOLBAR_LoadImages (infoPtr, wParam, (HINSTANCE)lParam); + return TOOLBAR_LoadImages (infoPtr, wParam, lParam); case TB_MAPACCELERATORA: case TB_MAPACCELERATORW: - return TOOLBAR_MapAccelerator (infoPtr, wParam, (UINT*)lParam); + return TOOLBAR_MapAccelerator (infoPtr, wParam, lParam); case TB_MARKBUTTON: - return TOOLBAR_MarkButton (infoPtr, wParam, LOWORD(lParam)); + return TOOLBAR_MarkButton (infoPtr, wParam, lParam); case TB_MOVEBUTTON: return TOOLBAR_MoveButton (infoPtr, wParam, lParam); case TB_PRESSBUTTON: - return TOOLBAR_PressButton (infoPtr, wParam, LOWORD(lParam)); + return TOOLBAR_PressButton (infoPtr, wParam, lParam); case TB_REPLACEBITMAP: - return TOOLBAR_ReplaceBitmap (infoPtr, (LPTBREPLACEBITMAP)lParam); + return TOOLBAR_ReplaceBitmap (infoPtr, lParam); case TB_SAVERESTOREA: return TOOLBAR_SaveRestoreA (infoPtr, wParam, (LPTBSAVEPARAMSA)lParam); @@ -6651,16 +6690,16 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_SaveRestoreW (infoPtr, wParam, (LPTBSAVEPARAMSW)lParam); case TB_SETANCHORHIGHLIGHT: - return TOOLBAR_SetAnchorHighlight (infoPtr, (BOOL)wParam); + return TOOLBAR_SetAnchorHighlight (infoPtr, wParam); case TB_SETBITMAPSIZE: return TOOLBAR_SetBitmapSize (infoPtr, wParam, lParam); case TB_SETBUTTONINFOA: - return TOOLBAR_SetButtonInfoA (infoPtr, wParam, (LPTBBUTTONINFOA)lParam); + return TOOLBAR_SetButtonInfoA (infoPtr, wParam, lParam); case TB_SETBUTTONINFOW: - return TOOLBAR_SetButtonInfoW (infoPtr, wParam, (LPTBBUTTONINFOW)lParam); + return TOOLBAR_SetButtonInfoW (infoPtr, wParam, lParam); case TB_SETBUTTONSIZE: return TOOLBAR_SetButtonSize (infoPtr, lParam); @@ -6672,7 +6711,7 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_SetCmdId (infoPtr, wParam, lParam); case TB_SETDISABLEDIMAGELIST: - return TOOLBAR_SetDisabledImageList (infoPtr, wParam, (HIMAGELIST)lParam); + return TOOLBAR_SetDisabledImageList (infoPtr, wParam, lParam); case TB_SETDRAWTEXTFLAGS: return TOOLBAR_SetDrawTextFlags (infoPtr, wParam, lParam); @@ -6681,19 +6720,19 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_SetExtendedStyle (infoPtr, lParam); case TB_SETHOTIMAGELIST: - return TOOLBAR_SetHotImageList (infoPtr, wParam, (HIMAGELIST)lParam); + return TOOLBAR_SetHotImageList (infoPtr, wParam, lParam); case TB_SETHOTITEM: return TOOLBAR_SetHotItem (infoPtr, wParam); case TB_SETIMAGELIST: - return TOOLBAR_SetImageList (infoPtr, wParam, (HIMAGELIST)lParam); + return TOOLBAR_SetImageList (infoPtr, wParam, lParam); case TB_SETINDENT: return TOOLBAR_SetIndent (infoPtr, wParam); case TB_SETINSERTMARK: - return TOOLBAR_SetInsertMark (infoPtr, (TBINSERTMARK*)lParam); + return TOOLBAR_SetInsertMark (infoPtr, lParam); case TB_SETINSERTMARKCOLOR: return TOOLBAR_SetInsertMarkColor (infoPtr, lParam); @@ -6705,10 +6744,10 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_SetPadding (infoPtr, lParam); case TB_SETPARENT: - return TOOLBAR_SetParent (infoPtr, (HWND)wParam); + return TOOLBAR_SetParent (infoPtr, wParam); case TB_SETROWS: - return TOOLBAR_SetRows (infoPtr, wParam, (LPRECT)lParam); + return TOOLBAR_SetRows (infoPtr, wParam, lParam); case TB_SETSTATE: return TOOLBAR_SetState (infoPtr, wParam, lParam); @@ -6717,7 +6756,7 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_SetStyle (infoPtr, lParam); case TB_SETTOOLTIPS: - return TOOLBAR_SetToolTips (infoPtr, (HWND)wParam); + return TOOLBAR_SetToolTips (infoPtr, wParam, lParam); case TB_SETUNICODEFORMAT: return TOOLBAR_SetUnicodeFormat (infoPtr, wParam); @@ -6732,7 +6771,7 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_SetListGap(infoPtr, wParam); case TB_GETIMAGELISTCOUNT: - return TOOLBAR_GetImageListCount(infoPtr); + return TOOLBAR_GetImageListCount(infoPtr, wParam, lParam); case TB_GETIDEALSIZE: return TOOLBAR_GetIdealSize (infoPtr, wParam, lParam); @@ -6760,7 +6799,7 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) /* case WM_CHAR: */ case WM_CREATE: - return TOOLBAR_Create (hwnd, (CREATESTRUCTW*)lParam); + return TOOLBAR_Create (hwnd, lParam); case WM_DESTROY: return TOOLBAR_Destroy (infoPtr); @@ -6807,13 +6846,13 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_NCCalcSize (hwnd, wParam, lParam); case WM_NCCREATE: - return TOOLBAR_NCCreate (hwnd, wParam, (CREATESTRUCTW*)lParam); + return TOOLBAR_NCCreate (hwnd, wParam, lParam); case WM_NCPAINT: return TOOLBAR_NCPaint (hwnd, wParam, lParam); case WM_NOTIFY: - return TOOLBAR_Notify (infoPtr, (LPNMHDR)lParam); + return TOOLBAR_Notify (infoPtr, lParam); case WM_NOTIFYFORMAT: return TOOLBAR_NotifyFormat (infoPtr, wParam, lParam); @@ -6826,7 +6865,7 @@ ToolbarWindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) return TOOLBAR_SetFocus (infoPtr); case WM_SETFONT: - return TOOLBAR_SetFont(infoPtr, (HFONT)wParam, (WORD)lParam); + return TOOLBAR_SetFont(infoPtr, wParam, lParam); case WM_SETREDRAW: return TOOLBAR_SetRedraw (infoPtr, wParam); diff --git a/dlls/comctl32/treeview.c b/dlls/comctl32/treeview.c index 8155aab6a75..8bea9738a2b 100644 --- a/dlls/comctl32/treeview.c +++ b/dlls/comctl32/treeview.c @@ -1255,7 +1255,6 @@ TREEVIEW_InsertItemT(TREEVIEW_INFO *infoPtr, const TVINSERTSTRUCTW *ptdi, BOOL i newItem->parent = parentItem; newItem->iIntegral = 1; - newItem->visibleOrder = -1; if (!TREEVIEW_DoSetItemT(infoPtr, newItem, tvItem, isW)) return 0; @@ -1368,8 +1367,6 @@ TREEVIEW_InsertItemT(TREEVIEW_INFO *infoPtr, const TVINSERTSTRUCTW *ptdi, BOOL i TREEVIEW_VerifyTree(infoPtr); - if (!infoPtr->bRedraw) return (LRESULT)newItem; - if (parentItem == infoPtr->root || (ISVISIBLE(parentItem) && parentItem->state & TVIS_EXPANDED)) { @@ -1395,6 +1392,8 @@ TREEVIEW_InsertItemT(TREEVIEW_INFO *infoPtr, const TVINSERTSTRUCTW *ptdi, BOOL i } else { + newItem->visibleOrder = -1; + /* refresh treeview if newItem is the first item inserted under parentItem */ if (ISVISIBLE(parentItem) && newItem->prevSibling == newItem->nextSibling) { @@ -1565,7 +1564,6 @@ TREEVIEW_DeleteItem(TREEVIEW_INFO *infoPtr, HTREEITEM wineItem) TREEVIEW_VerifyTree(infoPtr); - if (!infoPtr->bRedraw) return TRUE; if (visible) { @@ -1588,16 +1586,12 @@ TREEVIEW_DeleteItem(TREEVIEW_INFO *infoPtr, HTREEITEM wineItem) static LRESULT TREEVIEW_SetRedraw(TREEVIEW_INFO* infoPtr, WPARAM wParam) { - infoPtr->bRedraw = wParam ? TRUE : FALSE; + if(wParam) + infoPtr->bRedraw = TRUE; + else + infoPtr->bRedraw = FALSE; - if (infoPtr->bRedraw) - { - TREEVIEW_UpdateSubTree(infoPtr, infoPtr->root); - TREEVIEW_RecalculateVisibleOrder(infoPtr, NULL); - TREEVIEW_UpdateScrollBars(infoPtr); - TREEVIEW_Invalidate(infoPtr, NULL); - } - return 0; + return 0; } static LRESULT diff --git a/dlls/comdlg32/Makefile.in b/dlls/comdlg32/Makefile.in index d250bbad879..f63260a60b4 100644 --- a/dlls/comdlg32/Makefile.in +++ b/dlls/comdlg32/Makefile.in @@ -26,38 +26,7 @@ C_SRCS16 = \ SPEC_SRCS16 = commdlg.spec -RC_SRCS = \ - cdlg_Bg.rc \ - cdlg_Ca.rc \ - cdlg_Cs.rc \ - cdlg_Da.rc \ - cdlg_De.rc \ - cdlg_El.rc \ - cdlg_En.rc \ - cdlg_Eo.rc \ - cdlg_Es.rc \ - cdlg_Fi.rc \ - cdlg_Fr.rc \ - cdlg_Hu.rc \ - cdlg_It.rc \ - cdlg_Ja.rc \ - cdlg_Ko.rc \ - cdlg_Lt.rc \ - cdlg_Nl.rc \ - cdlg_No.rc \ - cdlg_Pl.rc \ - cdlg_Pt.rc \ - cdlg_Ro.rc \ - cdlg_Ru.rc \ - cdlg_Si.rc \ - cdlg_Sk.rc \ - cdlg_Sv.rc \ - cdlg_Th.rc \ - cdlg_Tr.rc \ - cdlg_Uk.rc \ - cdlg_Wa.rc \ - cdlg_Zh.rc \ - cdlg_xx.rc +RC_SRCS = rsrc.rc @MAKE_DLL_RULES@ diff --git a/dlls/comdlg32/cdlg_Bg.rc b/dlls/comdlg32/cdlg_Bg.rc index 5b0865a7c24..746b942fa70 100644 --- a/dlls/comdlg32/cdlg_Bg.rc +++ b/dlls/comdlg32/cdlg_Bg.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * Òóê èçðè÷íî ïèøåøå äà íå ïèïàì íåùî, àìà àç ãî ïèïíàõ. * Àêî èìà ïðîáëåìè íÿêîé äà ãè îïðàâè. diff --git a/dlls/comdlg32/cdlg_Ca.rc b/dlls/comdlg32/cdlg_Ca.rc index 59cffb12fa3..b76f412841d 100644 --- a/dlls/comdlg32/cdlg_Ca.rc +++ b/dlls/comdlg32/cdlg_Ca.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Cs.rc b/dlls/comdlg32/cdlg_Cs.rc index e3acb801f68..64e9f892757 100644 --- a/dlls/comdlg32/cdlg_Cs.rc +++ b/dlls/comdlg32/cdlg_Cs.rc @@ -18,9 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Da.rc b/dlls/comdlg32/cdlg_Da.rc index 951cb6c5271..839a1a46c7b 100644 --- a/dlls/comdlg32/cdlg_Da.rc +++ b/dlls/comdlg32/cdlg_Da.rc @@ -17,9 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_De.rc b/dlls/comdlg32/cdlg_De.rc index 6bc8ed974d7..8e6432e83c4 100644 --- a/dlls/comdlg32/cdlg_De.rc +++ b/dlls/comdlg32/cdlg_De.rc @@ -17,11 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - -#pragma code_page(65001) - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ @@ -30,7 +25,7 @@ LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL OPEN_FILE DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 275, 134 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Öffnen" +CAPTION "Öffnen" FONT 8, "MS Shell Dlg" { LTEXT "Datei&name:", 1090, 6, 6, 76, 9 @@ -43,10 +38,10 @@ FONT 8, "MS Shell Dlg" COMBOBOX 1136, 6, 114, 90, 36, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_BORDER | WS_VSCROLL | WS_TABSTOP LTEXT "&Laufwerke:", 1091, 110, 104, 92, 9 COMBOBOX 1137, 110, 114, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "Öffnen", IDOK, 208, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + DEFPUSHBUTTON "Öffnen", IDOK, 208, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Abbrechen", IDCANCEL, 208, 24, 56, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Hilfe", pshHelp, 208, 46, 56, 14, WS_GROUP | WS_TABSTOP - CHECKBOX "&Schreibgeschützt", 1040, 208, 68, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + CHECKBOX "&Schreibgeschützt", 1040, 208, 68, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP } @@ -68,7 +63,7 @@ FONT 8, "MS Shell Dlg" DEFPUSHBUTTON "Speichern als", IDOK, 208, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Abbrechen", IDCANCEL, 208, 24, 56, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Hilfe", pshHelp, 208, 46, 56, 14, WS_GROUP | WS_TABSTOP - CHECKBOX "&Schreibgeschützt", 1040, 208, 68, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + CHECKBOX "&Schreibgeschützt", 1040, 208, 68, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP } @@ -88,7 +83,7 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "&Einrichten", psh1, 206, 46, 56, 14, WS_GROUP | WS_TABSTOP LTEXT "&Von:", 1090, 60, 80, 30, 9 LTEXT "&Bis:", 1091, 120, 80, 30, 9 - LTEXT "Druck&qualität:", 1092, 6, 100, 76, 9 + LTEXT "Druck&qualität:", 1092, 6, 100, 76, 9 COMBOBOX 1136, 80, 100, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP CHECKBOX "In &Datei drucken", 1040, 20, 100, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP CHECKBOX "Verdichtet", 1041, 160, 100, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP @@ -114,7 +109,7 @@ FONT 8, "MS Shell Dlg" ICON "LANDSCAP", 1097, 10, 95, 32, 32 ICON "PORTRAIT", 1098, 10, 95, 32, 32 GROUPBOX "Paper", 1074, 120, 85, 180, 50, BS_GROUPBOX - LTEXT "&Größe", 1089, 130, 95, 30, 9 + LTEXT "&Größe", 1089, 130, 95, 30, 9 LTEXT "P&apierquelle", 1090, 130, 110, 30, 9 COMBOBOX 1137, 155, 95, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP COMBOBOX 1138, 155, 110, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP @@ -129,14 +124,14 @@ BEGIN CONTROL "", rct2, "Static", SS_GRAYRECT, 160, 12, 4, 80 CONTROL "", rct3, "Static", SS_GRAYRECT, 84, 88, 80, 4 GROUPBOX "Papier", grp2, 8, 96, 224, 56, BS_GROUPBOX - LTEXT "&Größe:", stc2, 16, 112, 36, 8 + LTEXT "&Größe:", stc2, 16, 112, 36, 8 COMBOBOX cmb2, 64, 110, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL LTEXT "&Zufuhr:", stc3, 16, 132, 36, 8 COMBOBOX cmb3, 64, 130, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL GROUPBOX "Format", grp1, 8, 156, 64, 56, BS_GROUPBOX AUTORADIOBUTTON "&Hochformat", rad1, 16, 170, 52, 12, BS_AUTORADIOBUTTON AUTORADIOBUTTON "&Querformat", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON - GROUPBOX "Ränder", grp4, 80, 156, 152, 56, BS_GROUPBOX + GROUPBOX "Ränder", grp4, 80, 156, 152, 56, BS_GROUPBOX LTEXT "&Links:", stc15, 88, 172, 21, 8 EDITTEXT edt4, 111, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER LTEXT "&Rechts:", stc16, 159, 172, 27, 8 @@ -162,7 +157,7 @@ FONT 8, "MS Shell Dlg" LTEXT "Schrift&stil:",1089 ,108,3,44,9 COMBOBOX 1137,108,13,64,54, CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | CBS_DISABLENOSCROLL | WS_VSCROLL | WS_TABSTOP | CBS_SIMPLE - LTEXT "Schrift&größe:",1090,179,3,30,9 + LTEXT "Schrift&größe:",1090,179,3,30,9 COMBOBOX 1138,179,13,32,54, CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | CBS_DISABLENOSCROLL | WS_VSCROLL | WS_TABSTOP | CBS_SIMPLE | CBS_SORT DEFPUSHBUTTON "OK",IDOK,218,6,40,14,WS_GROUP @@ -193,13 +188,13 @@ FONT 8, "MS Shell Dlg" LTEXT "Farbe | B&asis", 1090, 150, 151, 48, 10 LTEXT "&Rot:", 726 ,249,126,24,10 EDITTEXT 706, 275,124,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "&Grün:",727/*1095*/,249,140,24,10 + LTEXT "&Grün:",727/*1095*/,249,140,24,10 EDITTEXT 707, 275,138,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP LTEXT "&Blau:",728 /*1096*/,249,154,24,10 EDITTEXT 708, 275,152,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP LTEXT "&Farbe:" ,723 /*1091*/,202,126,22,10 EDITTEXT 703, 226,124,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "&Sätt:" ,724 /*1092*/,202,140,22,10 + LTEXT "&Sätt:" ,724 /*1092*/,202,140,22,10 EDITTEXT 704, 226,138,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP LTEXT "H&ell:" ,725 /*1093*/,202,154,22,10 EDITTEXT 705, 226,152,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP @@ -211,7 +206,7 @@ FONT 8, "MS Shell Dlg" DEFPUSHBUTTON "Ok", IDOK, 4, 166, 44, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Abbrechen", IDCANCEL, 52, 166, 44, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Hilfe", pshHelp,100,166, 44, 14 - PUSHBUTTON "Farbe hin&zufügen", 712/*1024*/, 152, 166, 142, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Farbe hin&zufügen", 712/*1024*/, 152, 166, 142, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "Farben &definieren >>", 719/*1025*/, 4, 150, 142, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&a",713,300,200,4,14 /* just a dummy: 'a' is like &a in "B&asis" */ } @@ -225,7 +220,7 @@ FONT 8, "MS Shell Dlg" LTEXT "S&uchen nach:", -1, 4, 8, 45, 8 EDITTEXT 1152, 53, 7, 128, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP CHECKBOX "Nu&r ganzes Wort suchen", 1040, 4, 26, 100, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - CHECKBOX "Groß-/Klein&schreibung", 1041, 4, 42, 84, 12, BS_AUTOCHECKBOX | WS_TABSTOP + CHECKBOX "Groß-/Klein&schreibung", 1041, 4, 42, 84, 12, BS_AUTOCHECKBOX | WS_TABSTOP GROUPBOX "Suchrichtung", 1072, 113, 23, 68, 37 CONTROL "Nach &oben", rad1, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_GROUP | WS_TABSTOP, 117, 34, 50, 10 CONTROL "Nach &unten", rad2, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 117, 47, 50, 10 @@ -245,7 +240,7 @@ FONT 8, "MS Shell Dlg" LTEXT "Ersetzen &durch:", -1, 4, 26, 52, 8 EDITTEXT 1153, 56, 24, 112, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP CHECKBOX "Nu&r ganzes Wort", 1040, 5, 46, 104, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - CHECKBOX "Groß-/Kleins&chreibung", 1041, 5, 62, 86, 12, BS_AUTOCHECKBOX | WS_TABSTOP + CHECKBOX "Groß-/Kleins&chreibung", 1041, 5, 62, 86, 12, BS_AUTOCHECKBOX | WS_TABSTOP DEFPUSHBUTTON "&Weitersuchen", IDOK, 175, 6, 60, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "&Ersetzen", psh1, 175, 23, 60, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "A&lles ersetzen", psh2, 175, 40, 60, 14, WS_GROUP | WS_TABSTOP @@ -255,7 +250,7 @@ FONT 8, "MS Shell Dlg" NEWFILEOPENORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 0, 0, 280, 164 STYLE DS_MODALFRAME | DS_CONTEXTHELP | WS_VISIBLE | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_CLIPCHILDREN -CAPTION "Öffnen" +CAPTION "Öffnen" FONT 8, "MS Shell Dlg" { LTEXT "&Suche in",IDC_LOOKINSTATIC,4,6,43,8, SS_NOTIFY @@ -270,9 +265,9 @@ FONT 8, "MS Shell Dlg" LTEXT "Datei&typen",IDC_FILETYPESTATIC,5,128,42,8, SS_NOTIFY COMBOBOX IDC_FILETYPE,54,126,155,53,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - CONTROL "&Schreibgeschützt",IDC_OPENREADONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,54,145,100,10 + CONTROL "&Schreibgeschützt",IDC_OPENREADONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,54,145,100,10 - DEFPUSHBUTTON "Ö&ffnen", IDOK,222,110,50,14 + DEFPUSHBUTTON "Ö&ffnen", IDOK,222,110,50,14 PUSHBUTTON "Abbrechen", IDCANCEL,222,128,50,14 PUSHBUTTON "&Hilfe", pshHelp,222,145,50,14 } @@ -341,7 +336,7 @@ BEGIN LTEXT "[keiner]", stc13, 52, 72, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP GROUPBOX "Papier", grp2, 8, 92, 164,56, WS_GROUP - LTEXT "&Größe:", stc2, 16,108, 36, 8 + LTEXT "&Größe:", stc2, 16,108, 36, 8 COMBOBOX cmb2, 52,106, 112,112,CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP LTEXT "&Zufuhr:", stc3, 16,128, 36, 8 COMBOBOX cmb3, 52,126, 112,112,CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP @@ -354,7 +349,7 @@ END STRINGTABLE DISCARDABLE { - IDS_ABOUTBOX "Ü&ber den Folderpicker" + IDS_ABOUTBOX "Ü&ber den Folderpicker" IDS_DOCUMENTFOLDERS "Dokumenten Ordner" IDS_PERSONAL "Meine Dokumente" IDS_FAVORITES "Meine Favoriten" @@ -369,10 +364,10 @@ STRINGTABLE DISCARDABLE IDS_SYSTEMFOLDERS "System Ordner" IDS_LOCALHARDRIVES "Lokale Festplatten" IDS_FILENOTFOUND "Datei nicht gefunden" - IDS_VERIFYFILE "Bitte überprüfen sie, ob der korrekte Dateiname angegeben wurde" + IDS_VERIFYFILE "Bitte überprüfen sie, ob der korrekte Dateiname angegeben wurde" IDS_CREATEFILE "Die Datei existiert nicht.\nWollen Sie sie neu anlegen?" - IDS_OVERWRITEFILE "Die Datei existiert bereits.\nWollen Sie sie überschreiben?" - IDS_INVALID_FILENAME_TITLE "Unzulässige Zeichen im Pfad" + IDS_OVERWRITEFILE "Die Datei existiert bereits.\nWollen Sie sie überschreiben?" + IDS_INVALID_FILENAME_TITLE "Unzulässige Zeichen im Pfad" IDS_INVALID_FILENAME "Ein Dateiname darf folgende Zeichen nicht enthalten:\n / : < > |" IDS_PATHNOTEXISTING "Der Pfad existiert nicht" IDS_FILENOTEXISTING "Die Datei existiert nicht" @@ -380,7 +375,7 @@ STRINGTABLE DISCARDABLE STRINGTABLE DISCARDABLE { - IDS_UPFOLDER "Eine Verzeichnisebene höher" + IDS_UPFOLDER "Eine Verzeichnisebene höher" IDS_NEWFOLDER "Neuen Ordner anlegen" IDS_LISTVIEW "Liste" IDS_REPORTVIEW "Details" @@ -394,50 +389,50 @@ STRINGTABLE DISCARDABLE PD32_VALUE_UREADABLE "Unlesbarer Eintrag" PD32_INVALID_PAGE_RANGE "Dieser Wert liegt nicht auf der Seite.\n\ Bitte geben sie einen Wert zwischen %d und %d an." - PD32_FROM_NOT_ABOVE_TO "Der 'von' Eintrag kann nicht größer sein als der 'bis' Eintrag." - PD32_MARGINS_OVERLAP "Die Ränder überlappen oder sind außerhalb des Papiers.\nBitte die Ränder neu eingeben." + PD32_FROM_NOT_ABOVE_TO "Der 'von' Eintrag kann nicht größer sein als der 'bis' Eintrag." + PD32_MARGINS_OVERLAP "Die Ränder überlappen oder sind außerhalb des Papiers.\nBitte die Ränder neu eingeben." PD32_NR_OF_COPIES_EMPTY "Es muss ein Wert bei der Anzahl der Kopien angegeben werden." - PD32_TOO_LARGE_COPIES "Ihr Drucker unterstützt so viele Kopien nicht.\nBitte verwenden Sie eine Kopienzahl zwischen 1 und %d." + PD32_TOO_LARGE_COPIES "Ihr Drucker unterstützt so viele Kopien nicht.\nBitte verwenden Sie eine Kopienzahl zwischen 1 und %d." PD32_PRINT_ERROR "Ein Druckerfehler ist aufgetreten." PD32_NO_DEFAULT_PRINTER "Es ist kein Standarddrucker eingestellt." PD32_CANT_FIND_PRINTER "Kann den Drucker nicht finden." PD32_OUT_OF_MEMORY "Kein freier Speicher mehr." PD32_GENERIC_ERROR "Ein unbekannter Fehler ist aufgetreten." PD32_DRIVER_UNKNOWN "Unbekannter Druckertreiber." - PD32_NO_DEVICES "Bevor Sie drucker-relevante Aufgaben ausführen können, \ + PD32_NO_DEVICES "Bevor Sie drucker-relevante Aufgaben ausführen können, \ wie die Seiteneinrichtung oder ein Dokument zu drucken, \ - müssen Sie einen Drucker installieren. Bitte führen Sie dies zuerst aus und versuchen Sie es erneut." + müssen Sie einen Drucker installieren. Bitte führen Sie dies zuerst aus und versuchen Sie es erneut." PD32_DEFAULT_PRINTER "Standard Drucker; " PD32_NR_OF_DOCUMENTS_IN_QUEUE "Es sind %d Dokumente in der Queue" - PD32_MARGINS_IN_INCHES "Ränder [inches/zoll]" - PD32_MARGINS_IN_MILLIMETERS "Ränder [mm]" + PD32_MARGINS_IN_INCHES "Ränder [inches/zoll]" + PD32_MARGINS_IN_MILLIMETERS "Ränder [mm]" PD32_MILLIMETERS "mm" PD32_PRINTER_STATUS_READY "Bereit" PD32_PRINTER_STATUS_PAUSED "Gestoppt; " PD32_PRINTER_STATUS_ERROR "Fehler; " - PD32_PRINTER_STATUS_PENDING_DELETION "Wartet auf Löschung; " + PD32_PRINTER_STATUS_PENDING_DELETION "Wartet auf Löschung; " PD32_PRINTER_STATUS_PAPER_JAM "Papierstau; " PD32_PRINTER_STATUS_PAPER_OUT "Papierfach leer; " - PD32_PRINTER_STATUS_MANUAL_FEED "Papier manuell zuführen; " + PD32_PRINTER_STATUS_MANUAL_FEED "Papier manuell zuführen; " PD32_PRINTER_STATUS_PAPER_PROBLEM "Papierproblem; " PD32_PRINTER_STATUS_OFFLINE "Printer ist offline; " - PD32_PRINTER_STATUS_IO_ACTIVE "Datenübertragung; " - PD32_PRINTER_STATUS_BUSY "Beschäftigt; " + PD32_PRINTER_STATUS_IO_ACTIVE "Datenübertragung; " + PD32_PRINTER_STATUS_BUSY "Beschäftigt; " PD32_PRINTER_STATUS_PRINTING "Druckend; " PD32_PRINTER_STATUS_OUTPUT_BIN_FULL "Ausgabe Fach ist voll; " PD32_PRINTER_STATUS_NOT_AVAILABLE "Nicht vorhanden; " PD32_PRINTER_STATUS_WAITING "Wartend; " PD32_PRINTER_STATUS_PROCESSING "In Bearbeitung; " PD32_PRINTER_STATUS_INITIALIZING "Initialisierend; " - PD32_PRINTER_STATUS_WARMING_UP "Aufwärmend; " + PD32_PRINTER_STATUS_WARMING_UP "Aufwärmend; " PD32_PRINTER_STATUS_TONER_LOW "Tonerstand niedrig; " PD32_PRINTER_STATUS_NO_TONER "Kein Toner mehr; " PD32_PRINTER_STATUS_PAGE_PUNT "Page punt; " PD32_PRINTER_STATUS_USER_INTERVENTION "Durch Benutzer unterbrochen; " PD32_PRINTER_STATUS_OUT_OF_MEMORY "Kein Speicher mehr; " - PD32_PRINTER_STATUS_DOOR_OPEN "Druckergehäuse ist offen; " + PD32_PRINTER_STATUS_DOOR_OPEN "Druckergehäuse ist offen; " PD32_PRINTER_STATUS_SERVER_UNKNOWN "Druckserver unbekannt; " PD32_PRINTER_STATUS_POWER_SAVE "Stromsparmodus; " } @@ -454,28 +449,28 @@ STRINGTABLE DISCARDABLE /* Color names */ { IDS_COLOR_BLACK "Schwarz" IDS_COLOR_MAROON "Kastanienbraun" - IDS_COLOR_GREEN "Grün" - IDS_COLOR_OLIVE "Olivgrün" + IDS_COLOR_GREEN "Grün" + IDS_COLOR_OLIVE "Olivgrün" IDS_COLOR_NAVY "Dunkelblau" IDS_COLOR_PURPLE "Lila" - IDS_COLOR_TEAL "Blaugrün" + IDS_COLOR_TEAL "Blaugrün" IDS_COLOR_GRAY "Grau" IDS_COLOR_SILVER "Silber" IDS_COLOR_RED "Rot" - IDS_COLOR_LIME "Hellgrün" + IDS_COLOR_LIME "Hellgrün" IDS_COLOR_YELLOW "Gelb" IDS_COLOR_BLUE "Blau" IDS_COLOR_FUCHSIA "Pink" IDS_COLOR_AQUA "Aquamarin" - IDS_COLOR_WHITE "Weiß" + IDS_COLOR_WHITE "Weiß" } STRINGTABLE DISCARDABLE { - IDS_FONT_SIZE "Wählen Sie eine Schriftgröße zwischen %d und %d Punkten aus." + IDS_FONT_SIZE "Wählen Sie eine Schriftgröße zwischen %d und %d Punkten aus." IDS_SAVE_BUTTON "&Speichern" IDS_SAVE_IN "Speichern &unter:" IDS_SAVE "Speichern" IDS_SAVE_AS "Speichern als" - IDS_OPEN_FILE "Öffne Datei" + IDS_OPEN_FILE "Öffne Datei" } diff --git a/dlls/comdlg32/cdlg_El.rc b/dlls/comdlg32/cdlg_El.rc index 309cda955c2..9fa64dde42a 100644 --- a/dlls/comdlg32/cdlg_El.rc +++ b/dlls/comdlg32/cdlg_El.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_En.rc b/dlls/comdlg32/cdlg_En.rc index c6889b41947..962c1891152 100644 --- a/dlls/comdlg32/cdlg_En.rc +++ b/dlls/comdlg32/cdlg_En.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Eo.rc b/dlls/comdlg32/cdlg_Eo.rc index c6471bed1b0..b9573f455a5 100644 --- a/dlls/comdlg32/cdlg_Eo.rc +++ b/dlls/comdlg32/cdlg_Eo.rc @@ -17,9 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Es.rc b/dlls/comdlg32/cdlg_Es.rc index 8327e6ab015..1f6226a0fb0 100644 --- a/dlls/comdlg32/cdlg_Es.rc +++ b/dlls/comdlg32/cdlg_Es.rc @@ -17,9 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Fi.rc b/dlls/comdlg32/cdlg_Fi.rc index dbe273f9fb6..8e732df21a7 100644 --- a/dlls/comdlg32/cdlg_Fi.rc +++ b/dlls/comdlg32/cdlg_Fi.rc @@ -17,9 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Fr.rc b/dlls/comdlg32/cdlg_Fr.rc index de87186d9cf..bd93a10b9bf 100644 --- a/dlls/comdlg32/cdlg_Fr.rc +++ b/dlls/comdlg32/cdlg_Fr.rc @@ -4,7 +4,6 @@ * * Copyright 1995 Alexandre Julliard * Copyright 2005-2008 Jonathan Ernst - * Copyright 2009 Frédéric Delanoy * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -21,12 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - -/* UTF-8 */ -#pragma code_page(65001) - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ @@ -38,20 +31,20 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Ouvrir" FONT 8, "MS Shell Dlg" { - LTEXT "&Nom de fichier :", 1090, 6, 6, 76, 9 + LTEXT "&Nom de fichier :", 1090, 6, 6, 76, 9 EDITTEXT edt1, 6, 16, 90, 12, ES_AUTOHSCROLL | ES_OEMCONVERT | WS_BORDER | WS_TABSTOP LISTBOX 1120, 6, 32, 90, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP - LTEXT "&Répertoires", -1, 110, 6, 92, 9 + LTEXT "&Répertoires", -1, 110, 6, 92, 9 LTEXT "", 1088, 110, 18, 92, 9, SS_NOPREFIX | WS_GROUP LISTBOX 1121, 110, 32, 92, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP - LTEXT "Liste des fichiers de &type :", 1089, 6, 104, 90, 9 - COMBOBOX cmb1, 6, 114, 90, 15, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_BORDER | WS_VSCROLL | WS_TABSTOP - LTEXT "&Lecteurs :", 1091, 110, 104, 92, 9 - COMBOBOX cmb2, 110, 114, 92, 15, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "Ouvrir", 1, 208, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + LTEXT "Liste des fichiers de &type :", 1089, 6, 104, 90, 9 + COMBOBOX cmb1, 6, 114, 90, 36, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_BORDER | WS_VSCROLL | WS_TABSTOP + LTEXT "&Lecteurs :", 1091, 110, 104, 92, 9 + COMBOBOX cmb2, 110, 114, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP + DEFPUSHBUTTON "OK", 1, 208, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Annuler", 2, 208, 24, 56, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "Aid&e", pshHelp, 208, 46, 56, 14, WS_GROUP | WS_TABSTOP - CHECKBOX "&Lecture seule", chx1, 208, 68, 55, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + CHECKBOX "Lecture seule", chx1, 208, 68, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP } @@ -60,84 +53,84 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Enregistrer sous..." FONT 8, "MS Shell Dlg" { - LTEXT "&Nom de fichier :", 1090, 6, 6, 76, 9 + LTEXT "&Nom de fichier :", 1090, 6, 6, 76, 9 EDITTEXT edt1, 6, 16, 90, 12, ES_AUTOHSCROLL | ES_OEMCONVERT | WS_BORDER | WS_TABSTOP LISTBOX 1120, 6, 32, 90, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP - LTEXT "&Répertoires :", -1, 110, 6, 92, 9 + LTEXT "&Répertoires :", -1, 110, 6, 92, 9 LTEXT "", 1088, 110, 18, 92, 9, SS_NOPREFIX | WS_GROUP LISTBOX 1121, 110, 32, 92, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP - LTEXT "Lister les fichiers de &type :", 1089, 6, 104, 90, 9 + LTEXT "Liste des fichiers de &type :", 1089, 6, 104, 90, 9 COMBOBOX cmb1, 6, 114, 90, 36, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_BORDER | WS_VSCROLL | WS_TABSTOP LTEXT "&Lecteurs:", 1091, 110, 104, 92, 9 COMBOBOX cmb2, 110, 114, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "Enregistrer", 1, 208, 6, 60, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Annuler", 2, 208, 24, 60, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "Aid&e", pshHelp, 208, 46, 60, 14, WS_GROUP | WS_TABSTOP - CHECKBOX "Lecture seule", chx1, 208, 68, 55, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + DEFPUSHBUTTON "OK", 1, 208, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Annuler", 2, 208, 24, 56, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Aid&e", pshHelp, 208, 46, 56, 14, WS_GROUP | WS_TABSTOP + CHECKBOX "Lecture seule", chx1, 208, 68, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP } -PRINT DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 237, 134 +PRINT DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 264, 134 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Imprimer" FONT 8, "MS Shell Dlg" { - LTEXT "Imprimante :", 1088, 6, 6, 40, 9 + LTEXT "Imprimante :", 1088, 6, 6, 40, 9 LTEXT "", 1089, 60, 6, 150, 9 - GROUPBOX "Zone d'impression", grp1, 6, 30, 160, 65, BS_GROUPBOX + GROUPBOX "Étendue", grp1, 6, 30, 160, 65, BS_GROUPBOX RADIOBUTTON "&Tout", rad1, 16, 45, 60, 12 - RADIOBUTTON "&Sélection", rad2, 16, 60, 60, 12 - RADIOBUTTON "&Pages", rad3, 16, 75, 41, 12 - DEFPUSHBUTTON "Imprimer", 1, 173, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Annuler", 2, 173, 24, 56, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Configurer...", psh1, 173, 46, 56, 14, WS_GROUP | WS_TABSTOP - LTEXT "&De:", 1090, 64, 77, 30, 9 - LTEXT "&à:", 1091, 120, 77, 30, 9 - LTEXT "&Qualité d'impression:", 1092, 7, 102, 69, 9 - COMBOBOX cmb1, 78, 100, 88, 13, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP - CHECKBOX "Imprimer dans un &fichier", chx1, 7, 117, 93, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - CHECKBOX "Copies t&riées", chx2, 106, 118, 63, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + RADIOBUTTON "&Sélection", rad2, 16, 60, 60, 12 + RADIOBUTTON "&Pages", rad3, 16, 75, 60, 12 + DEFPUSHBUTTON "OK", 1, 206, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Annuler", 2, 206, 24, 56, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Configurer...", psh1, 206, 46, 56, 14, WS_GROUP | WS_TABSTOP + LTEXT "&De:", 1090, 60, 80, 30, 9 + LTEXT "&A:", 1091, 120, 80, 30, 9 + LTEXT "&Qualité d'impression:", 1092, 6, 100, 76, 9 + COMBOBOX cmb1, 80, 100, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP + CHECKBOX "&Fichier d'impression", chx1, 20, 100, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + CHECKBOX "Copies t&riées", chx2, 160, 100, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP } -PRINT_SETUP DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 264, 151 +PRINT_SETUP DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 264, 134 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Configuration de l'impression" FONT 8, "MS Shell Dlg" { - GROUPBOX "Imprimante", grp1, 6, 6, 180, 74, BS_GROUPBOX - RADIOBUTTON "&Imprimante par défaut", rad1, 16, 22, 90, 12 + GROUPBOX "Imprimante", grp1, 6, 10, 180, 65, BS_GROUPBOX + RADIOBUTTON "&Imprimante par défaut", rad1, 16, 20, 80, 12 LTEXT "[aucune]", 1088, 35, 35, 120, 9 - RADIOBUTTON "Imprimante &spécifique", rad2, 16, 46, 90, 12 - COMBOBOX cmb1, 35, 60, 146, 17, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP + RADIOBUTTON "Imprimante &spécifique", rad2, 16, 50, 80, 12 + COMBOBOX cmb1, 35, 65, 149, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP DEFPUSHBUTTON "OK", 1, 206, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Annuler", 2, 206, 24, 56, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Options...", psh1, 206, 46, 56, 14, WS_GROUP | WS_TABSTOP - GROUPBOX "Orientation", grp2, 6, 90, 100, 50, BS_GROUPBOX - RADIOBUTTON "&Portrait", rad3, 50, 105, 40, 12 - RADIOBUTTON "Pa&ysage", rad4, 50, 120, 40, 12 - ICON "LANDSCAP", stc10, 10, 100, 21, 20 - ICON "PORTRAIT", stc11, 10, 100, 21, 20 - GROUPBOX "Papier", grp3, 120, 90, 135, 50, BS_GROUPBOX - LTEXT "&Taille :", 1089, 125, 103, 30, 9 - LTEXT "&Source :", 1090, 125, 121, 30, 9 - COMBOBOX cmb2, 155, 100, 92, 17, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP - COMBOBOX cmb3, 155, 118, 92, 17, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP + GROUPBOX "Orientation", grp2, 6, 85, 100, 50, BS_GROUPBOX + RADIOBUTTON "&Portrait", rad3, 50, 100, 40, 12 + RADIOBUTTON "Paysag&e", rad4, 50, 115, 40, 12 + ICON "LANDSCAP", stc10, 10, 95, 32, 32 + ICON "PORTRAIT", stc11, 10, 95, 32, 32 + GROUPBOX "Papier", grp3, 120, 85, 180, 50, BS_GROUPBOX + LTEXT "&Taille :", 1089, 130, 95, 30, 9 + LTEXT "&Source :", 1090, 130, 110, 30, 9 + COMBOBOX cmb2, 155, 95, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP + COMBOBOX cmb3, 155, 110, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP } CHOOSE_FONT DIALOG DISCARDABLE 13, 54, 264, 147 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Police" +CAPTION "Polices" FONT 8, "MS Shell Dlg" { - LTEXT "&Police :",stc1 ,6,3,40,9 + LTEXT "&Police:",stc1 ,6,3,40,9 COMBOBOX cmb1 ,6,13,94,54, CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | CBS_DISABLENOSCROLL | CBS_AUTOHSCROLL | CBS_SORT | WS_VSCROLL | WS_TABSTOP | CBS_SIMPLE - LTEXT "St&yle :",stc2 ,108,3,44,9 + LTEXT "St&yle de police:",stc2 ,108,3,44,9 COMBOBOX cmb2,108,13,64,54, CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | CBS_DISABLENOSCROLL | WS_VSCROLL | WS_TABSTOP | CBS_SIMPLE - LTEXT "&Taille :",stc3,179,3,30,9 + LTEXT "&Taille:",stc3,179,3,30,9 COMBOBOX cmb3,179,13,32,54, CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | CBS_DISABLENOSCROLL | WS_VSCROLL | WS_TABSTOP | CBS_SIMPLE | CBS_SORT DEFPUSHBUTTON "OK",IDOK,218,6,40,14,WS_GROUP @@ -145,15 +138,15 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "A&ppliquer", psh3,218,40,40,14,WS_GROUP PUSHBUTTON "Aid&e" , pshHelp,218,57,40,14,WS_GROUP GROUPBOX "Effets",grp1,6,72,84,34,WS_GROUP - CHECKBOX "&Barré", chx1, 10,82,50,10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "&Souligné", chx2, 10,94,50,10, BS_AUTOCHECKBOX - LTEXT "&Couleur :", stc4 ,6,110,30,9 + CHECKBOX "&Barré", chx1, 10,82,50,10, BS_AUTOCHECKBOX | WS_TABSTOP + CHECKBOX "&Souligné", chx2, 10,94,50,10, BS_AUTOCHECKBOX + LTEXT "&Couleur:", stc4 ,6,110,30,9 COMBOBOX cmb4,6,120,84,100,CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | CBS_AUTOHSCROLL | WS_BORDER | WS_VSCROLL | WS_TABSTOP - GROUPBOX "Aperçu",grp2,98,72,120,36,WS_GROUP - CTEXT "\nÀàCcÇçEeÉéÈèÊêIiÏïÎîLlUuÙù12",stc5,103,80,109,24,SS_NOPREFIX | NOT WS_VISIBLE - LTEXT "Sc&ript :",stc7 ,98,110,80,9 - COMBOBOX cmb5,98,120,120,90,CBS_DROPDOWNLIST | CBS_HASSTRINGS | + GROUPBOX "Exemple",grp2,98,72,120,36,WS_GROUP + CTEXT "AaBbYyZz",stc5,103,80,109,24,SS_NOPREFIX | NOT WS_VISIBLE + LTEXT "Scr&ipt (translate):",stc7 ,98,114,80,9 + COMBOBOX cmb5,98,124,120,90,CBS_DROPDOWNLIST | CBS_HASSTRINGS | CBS_AUTOHSCROLL | WS_VSCROLL | WS_TABSTOP } @@ -163,31 +156,31 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Couleurs" FONT 8, "MS Shell Dlg" { - LTEXT "Couleurs de base :", 1088, 4, 4, 140, 10 - LTEXT "Couleurs personnalisées :", 1089, 4, 106, 140, 10 - LTEXT "Couleur | &Uni", 1090, 150, 151, 48, 10 - LTEXT "&Rouge :", 726 /*1094*/,249,126,24,10 + LTEXT "Couleurs de &base :", 1088, 4, 4, 140, 10 + LTEXT "&Couleurs personnalisées :", 1089, 4, 106, 140, 10 + LTEXT "Couleur | &Uni", 1090, 150, 151, 48, 10 + LTEXT "&Rouge :", 726 /*1094*/,249,126,24,10 EDITTEXT 706, 275,124,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "&Vert :",727/*1095*/,249,140,24,10 + LTEXT "&Vert :",727/*1095*/,249,140,24,10 EDITTEXT 707, 275,138,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "Bl&eu :",728 /*1096*/,249,154,24,10 + LTEXT "Bl&eu :",728 /*1096*/,249,154,24,10 EDITTEXT 708, 275,152,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "&Teinte :" ,723 /*1091*/,202,126,22,10 + LTEXT "&Teinte :" ,723 /*1091*/,202,126,22,10 EDITTEXT 703, 226,124,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "&Satur. :" ,724 /*1092*/,202,140,22,10 + LTEXT "&Sat. :" ,724 /*1092*/,202,140,22,10 EDITTEXT 704, 226,138,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "&Lum. :" ,725 /*1093*/,202,154,22,10 + LTEXT "&Lum. :" ,725 /*1093*/,202,154,22,10 EDITTEXT 705, 226,152,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP CONTROL "" ,720,"STATIC",SS_SIMPLE|WS_TABSTOP|WS_GROUP,4,14,140,86 CONTROL "" ,721,"STATIC",SS_SIMPLE|WS_TABSTOP|WS_GROUP,4,116,140,28 CONTROL "" ,710,"STATIC",WS_BORDER|SS_SIMPLE|WS_TABSTOP|WS_GROUP, 152,4,118,116 CONTROL "" ,702,"STATIC",SS_SIMPLE|WS_TABSTOP|WS_GROUP, 278,4,8,116 CONTROL "" ,709,"STATIC",SS_SIMPLE|WS_TABSTOP|WS_GROUP, 152,124,40,26 - DEFPUSHBUTTON "OK", 1, 4, 166, 44, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + DEFPUSHBUTTON "Ok", 1, 4, 166, 44, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Annuler", 2, 52, 166, 44, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "Aid&e", pshHelp,100,166, 44, 14 - PUSHBUTTON "&Ajouter aux couleurs personnalisées", 712/*1024*/, 152, 166, 142, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Définir les couleurs personnalisées >>", 719/*1025*/, 4, 149, 142, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "A&jouter couleur personnalisées", 712/*1024*/, 152, 166, 142, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Définir couleurs personnalisées >>", 719/*1025*/, 4, 150, 142, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&i",713,300,200,4,14 /* just a dummy: 'i' is like &i in "sol&id" */ } @@ -197,15 +190,15 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Rechercher" FONT 8, "MS Shell Dlg" { - LTEXT "&Rechercher :", -1, 4, 8, 42, 8 + LTEXT "&Rechercher :", -1, 4, 8, 42, 8 EDITTEXT edt1, 47, 7, 128, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - CHECKBOX "Mots &entiers seulement", chx1, 4, 26, 100, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - CHECKBOX "Respecter la &casse", chx2, 4, 42, 74, 12, BS_AUTOCHECKBOX | WS_TABSTOP - GROUPBOX "Direction", grp1, 103, 26, 72, 28 - CONTROL "&Haut", rad1, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_GROUP | WS_TABSTOP, 108, 38, 30, 12 - CONTROL "&Bas", rad2, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 140, 38, 30, 12 + CHECKBOX "M&ot seulement", chx1, 4, 26, 100, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + CHECKBOX "Respect des &majuscules/minuscules", chx2, 4, 42, 64, 12, BS_AUTOCHECKBOX | WS_TABSTOP + GROUPBOX "Direction", grp1, 107, 26, 68, 28 + CONTROL "&Haut", rad1, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_GROUP | WS_TABSTOP, 111, 38, 20, 12 + CONTROL "&Bas", rad2, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 138, 38, 30, 12 - DEFPUSHBUTTON "&Suivant", 1, 182, 5, 50, 14, WS_GROUP | WS_TABSTOP + DEFPUSHBUTTON "&Poursuivre", 1, 182, 5, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "Annuler", 2, 182, 23, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "Aid&e", pshHelp, 182, 45, 50, 14, WS_GROUP | WS_TABSTOP } @@ -216,59 +209,59 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Remplacer" FONT 8, "MS Shell Dlg" { - LTEXT "&Rechercher :", -1, 4, 9, 48, 8 - EDITTEXT edt1, 54, 7, 108, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "R&emplacer par :", -1, 4, 26, 48, 8 - EDITTEXT edt2, 54, 24, 108, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - CHECKBOX "Mots &entiers uniquement", chx1, 5, 46, 104, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - CHECKBOX "Respecter la &casse", chx2, 5, 62, 74, 12, BS_AUTOCHECKBOX | WS_TABSTOP - - DEFPUSHBUTTON "&Suivant", 1, 168, 4, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Remplacer", psh1, 168, 21, 56, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "Remplacer &tout", psh2, 168, 38, 56, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Annuler", IDCANCEL, 168, 55, 56, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "Aid&e", pshHelp, 168, 75, 56, 14, WS_GROUP | WS_TABSTOP + LTEXT "&Rechercher :", -1, 4, 9, 48, 8 + EDITTEXT edt1, 54, 7, 114, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP + LTEXT "R&emplacer par :", -1, 4, 26, 48, 8 + EDITTEXT edt2, 54, 24, 114, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP + CHECKBOX "M&ot seulement", chx1, 5, 46, 104, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + CHECKBOX "Respect des &majuscules/minuscules", chx2, 5, 62, 59, 12, BS_AUTOCHECKBOX | WS_TABSTOP + + DEFPUSHBUTTON "&Poursuivre", 1, 174, 4, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Rempla&cer", psh1, 174, 21, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Remplacer &tout", psh2, 174, 38, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Annuler", IDCANCEL, 174, 55, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Aid&e", pshHelp, 174, 75, 50, 14, WS_GROUP | WS_TABSTOP } -PRINT32 DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 288, 196 +PRINT32 DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 288, 186 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | DS_CONTEXTHELP | DS_3DLOOK CAPTION "Impression" FONT 8, "MS Shell Dlg" { - DEFPUSHBUTTON "OK", IDOK, 178,176, 48,14, WS_GROUP | BS_DEFPUSHBUTTON - PUSHBUTTON "Annuler", IDCANCEL, 231,176, 48,14, WS_GROUP - PUSHBUTTON "Aid&e", pshHelp, 55, 176, 48,14, WS_GROUP + DEFPUSHBUTTON "OK", IDOK, 180,164, 48,14, WS_GROUP | BS_DEFPUSHBUTTON + PUSHBUTTON "Annuler", IDCANCEL, 232,164, 48,14, WS_GROUP + PUSHBUTTON "Aid&e", pshHelp, 50, 161, 48,14, WS_GROUP GROUPBOX "Imprimante", grp4, 8, 4, 272,84, WS_GROUP - CONTROL "Imprimer dans un fichier", chx1, "Button",BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP,185,44,93,14 - PUSHBUTTON "&Propriétés", psh2, 214, 17, 60,14, WS_GROUP - LTEXT "&Nom :", stc6, 16, 20, 36,8 - COMBOBOX cmb4, 65, 18, 145, 15, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP - LTEXT "État :", stc8, 16, 36, 36,10, SS_NOPREFIX - LTEXT "État fictif", stc12, 65, 36, 112,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Type :", stc7, 16, 48, 36,10, SS_NOPREFIX - LTEXT "Type fictif", stc11, 65, 48, 111,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Emplacement :", stc10, 16, 60, 47,10, SS_NOPREFIX - LTEXT "Emplacement fictif", stc14, 65, 60, 211,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Commentaire:", stc9, 16, 72, 47, 10, SS_NOPREFIX - LTEXT "Remarque fictive", stc13, 65, 72, 144, 10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - - GROUPBOX "Copies", grp2, 160, 92, 120,73, WS_GROUP + CONTROL "Imprimer dans un fichier", chx1, "Button",BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP,212,70,64,12 + PUSHBUTTON "Propriétés", psh2, 212, 17, 60,14, WS_GROUP + LTEXT "&Nom :", stc6, 16, 20, 36,8 + COMBOBOX cmb4, 52, 18, 152,152,CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP + LTEXT "État :", stc8, 16, 36, 36,10, SS_NOPREFIX + LTEXT "Dummy State", stc12, 52, 36, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Type :", stc7, 16, 48, 36,10, SS_NOPREFIX + LTEXT "Dummy Type", stc11, 52, 48, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Emplacement :", stc10, 16, 60, 36,10, SS_NOPREFIX + LTEXT "Dummy Location", stc14, 52, 60, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Commentaire:", stc9, 16, 72, 36,10, SS_NOPREFIX + LTEXT "Dummy Remark", stc13, 52, 72, 152,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + + GROUPBOX "Copies", grp2, 160, 92, 120,64, WS_GROUP LTEXT "Nombre de copies:",stc5,168,108,68,8 - ICON "", ico3, 183,121,76,24, WS_GROUP | SS_CENTERIMAGE - CONTROL "Copies assemblées",chx2,"Button",BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP,167,148,77,12 + ICON "", ico3, 162,124, 76,24, WS_GROUP | SS_CENTERIMAGE + CONTROL "Copies assemblées",chx2,"Button",BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP,240,130,36,12 EDITTEXT edt3, 240,106, 32,12, WS_GROUP | ES_NUMBER - GROUPBOX "Zone d'impression", grp1, 8,92, 144,73, WS_GROUP - CONTROL "&Tout", rad1,"Button",BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,16,108,64,12 - CONTROL "&Pages", rad3,"Button",BS_AUTORADIOBUTTON,16,124,36,12 - CONTROL "&Sélection", rad2,"Button",BS_AUTORADIOBUTTON,16,140,64,12 - EDITTEXT edt1, 74,124, 26,12, WS_GROUP | ES_NUMBER - EDITTEXT edt2, 118,124, 26,12, WS_GROUP | ES_NUMBER - RTEXT "&de :", stc2, 52,127, 20,8 - RTEXT "&à :", stc3, 100,127, 16,8 + GROUPBOX "Etendue de pages", grp1, 8,92, 144,64, WS_GROUP + CONTROL "Toutes", rad1,"Button",BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,16,106,64,12 + CONTROL "Pages", rad3,"Button",BS_AUTORADIOBUTTON,16,122,36,12 + CONTROL "Selection", rad2,"Button",BS_AUTORADIOBUTTON,16,138,64,12 + EDITTEXT edt1, 74,122, 26,12, WS_GROUP | ES_NUMBER + EDITTEXT edt2, 118,122, 26,12, WS_GROUP | ES_NUMBER + RTEXT "&de :", stc2, 52,124, 20,8 + RTEXT "&à :", stc3, 100,124, 16,8 } PRINT32_SETUP DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 288, 178 @@ -279,20 +272,20 @@ FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "OK",IDOK,180,156,48,14,WS_GROUP PUSHBUTTON "Annuler",IDCANCEL,232,156,48,14 -/* PUSHBUTTON "Réseau...", psh5, 284,156,48,14 */ +/* PUSHBUTTON "Réseau...", psh5, 284,156,48,14 */ GROUPBOX "Imprimante", grp4, 8, 4, 272,84, WS_GROUP - PUSHBUTTON "&Propriétés", psh2, 214, 17, 60,14, WS_GROUP - LTEXT "&Nom :", stc6, 16, 20, 36,8 - COMBOBOX cmb1, 65, 18, 145,15,CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP - LTEXT "État:", stc8, 16, 36, 36,10, SS_NOPREFIX - LTEXT "État fictif", stc12, 65, 36, 210,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + PUSHBUTTON "&Propriétés", psh2, 212, 17, 60,14, WS_GROUP + LTEXT "&Nom :", stc6, 16, 20, 36,8 + COMBOBOX cmb1, 52, 18, 152,152,CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP + LTEXT "État:", stc8, 16, 36, 36,10, SS_NOPREFIX + LTEXT "[aucun]", stc12, 60, 36, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP LTEXT "Type:", stc7, 16, 48, 36,10, SS_NOPREFIX - LTEXT "Type fictif", stc11, 65, 48, 210,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Emplacement :", stc10, 16, 60, 47,10, SS_NOPREFIX - LTEXT "Emplacement fictif", stc14, 65, 60, 210,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Commentaire :", stc9, 16, 72, 47,10, SS_NOPREFIX - LTEXT "Commentaire fictif", stc13, 65, 72, 210,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "[aucun]", stc11, 60, 48, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Emplacement :", stc10, 16, 60, 36,10, SS_NOPREFIX + LTEXT "[aucun]", stc14, 60, 60, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Commentaire :", stc9, 16, 72, 36,10, SS_NOPREFIX + LTEXT "[aucun]", stc13, 60, 72, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP GROUPBOX "Papier", grp2, 8, 92, 164,56, WS_GROUP LTEXT "&Taille:", stc2, 16,108, 36, 8 @@ -303,10 +296,10 @@ BEGIN GROUPBOX "Orientation", grp1, 180, 92, 100,56, WS_GROUP ICON "", ico1, 195,112, 18,20, WS_GROUP CONTROL "&Portrait", rad1,"Button",BS_AUTORADIOBUTTON | WS_GROUP |WS_TABSTOP,224,106,52,12 - CONTROL "Pa&ysage", rad2,"Button",BS_AUTORADIOBUTTON,224,126,52,12 + CONTROL "&Paysage", rad2,"Button",BS_AUTORADIOBUTTON,224,126,52,12 END -PAGESETUPDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 242, 240 +PAGESETUPDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 240, 240 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Mise en page" FONT 8, "MS Shell Dlg" @@ -314,26 +307,26 @@ BEGIN CONTROL "", rct1, "Static", SS_WHITERECT, 80, 8, 80, 80 CONTROL "", rct2, "Static", SS_GRAYRECT, 160, 12, 4, 80 CONTROL "", rct3, "Static", SS_GRAYRECT, 84, 88, 80, 4 - GROUPBOX "Papier", grp2, 8, 96, 228, 56, BS_GROUPBOX - LTEXT "&Taille :", stc2, 16, 112, 36, 8 - COMBOBOX cmb2, 64, 110, 167, 15, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - LTEXT "&Bac :", stc3, 16, 132, 36, 8 - COMBOBOX cmb3, 64, 130, 167, 15, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL + GROUPBOX "Papier", grp2, 8, 96, 224, 56, BS_GROUPBOX + LTEXT "&Taille :", stc2, 16, 112, 36, 8 + COMBOBOX cmb2, 64, 110, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL + LTEXT "&Source :", stc3, 16, 132, 36, 8 + COMBOBOX cmb3, 64, 130, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL GROUPBOX "Orientation", grp1, 8, 156, 64, 56, BS_GROUPBOX AUTORADIOBUTTON "&Portrait", rad1, 16, 170, 52, 12, BS_AUTORADIOBUTTON - AUTORADIOBUTTON "Pa&ysage", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON - GROUPBOX "Marges", grp4, 80, 156, 156, 56, BS_GROUPBOX - LTEXT "&Gauche :", stc15, 88, 172, 29, 8 - EDITTEXT edt4, 119, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "&Droite :", stc16, 163, 172, 27, 8 - EDITTEXT edt6, 190, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "&Haut :", stc17, 88, 192, 21, 8 - EDITTEXT edt5, 119, 190, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "&Bas :", stc18, 163, 192, 23, 8 - EDITTEXT edt7, 190, 190, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - DEFPUSHBUTTON "OK", IDOK, 70, 220, 51, 14, BS_PUSHBUTTON - PUSHBUTTON "Annuler", IDCANCEL, 125, 220, 51, 14 - PUSHBUTTON "&Imprimante...", psh3, 184, 220, 51, 14 + AUTORADIOBUTTON "P&aysage", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON + GROUPBOX "Marges", grp4, 80, 156, 152, 56, BS_GROUPBOX + LTEXT "&Droite :", stc15, 88, 172, 21, 8 + EDITTEXT edt4, 111, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER + LTEXT "&Gauche :", stc16, 159, 172, 27, 8 + EDITTEXT edt6, 187, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER + LTEXT "&Haut :", stc17, 88, 192, 21, 8 + EDITTEXT edt5, 111, 190, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER + LTEXT "&Bas :", stc18, 159, 192, 23, 8 + EDITTEXT edt7, 187, 190, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER + DEFPUSHBUTTON "OK", IDOK, 71, 220, 50, 14, BS_PUSHBUTTON + PUSHBUTTON "Annuler", IDCANCEL, 126, 220, 50, 14 + PUSHBUTTON "&Imprimante...", psh3, 184, 220, 48, 14 END NEWFILEOPENORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 0, 0, 280, 164 @@ -347,13 +340,13 @@ FONT 8, "MS Shell Dlg" LTEXT "" , IDC_TOOLBARSTATIC, 181, 2, 102, 17, NOT WS_GROUP | NOT WS_VISIBLE LISTBOX IDC_SHELLSTATIC,4,20,272,85, LBS_SORT | LBS_NOINTEGRALHEIGHT | LBS_MULTICOLUMN | WS_HSCROLL | NOT WS_VISIBLE - LTEXT "&Nom du fichier",IDC_FILENAMESTATIC,5,112,50,8, SS_NOTIFY - EDITTEXT IDC_FILENAME,59,110,155,12,ES_AUTOHSCROLL + LTEXT "&Nom du fichier :",IDC_FILENAMESTATIC,5,112,46,8, SS_NOTIFY + EDITTEXT IDC_FILENAME,54,110,155,12,ES_AUTOHSCROLL - LTEXT "Fichiers de &type",IDC_FILETYPESTATIC,5,128,52,8, SS_NOTIFY - COMBOBOX IDC_FILETYPE,59,126,155,53,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + LTEXT "&Type du fichier",IDC_FILETYPESTATIC,5,128,42,8, SS_NOTIFY + COMBOBOX IDC_FILETYPE,54,126,155,53,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - CONTROL "&Lecture seule",IDC_OPENREADONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,59,145,100,10 + CONTROL "&Protection écriture",IDC_OPENREADONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,54,145,100,10 DEFPUSHBUTTON "Ouvrir", IDOK,222,110,50,14 PUSHBUTTON "Annuler", IDCANCEL,222,128,50,14 @@ -362,11 +355,11 @@ FONT 8, "MS Shell Dlg" STRINGTABLE DISCARDABLE { - IDS_ABOUTBOX "À propos du XXX choix de répertoires" - IDS_DOCUMENTFOLDERS "Répertoires des documents" + IDS_ABOUTBOX "À propos du choix de répertoires" + IDS_DOCUMENTFOLDERS "Répertoire documents" IDS_PERSONAL "Mes documents" IDS_FAVORITES "Mes favoris" - IDS_PATH "Chemin système (path)" + IDS_PATH "Répertoire système" IDS_DESKTOP "Bureau" IDS_FONTS "Polices" IDS_MYCOMPUTER "Poste de travail" @@ -374,24 +367,24 @@ STRINGTABLE DISCARDABLE STRINGTABLE DISCARDABLE { - IDS_SYSTEMFOLDERS "Répertoires système" + IDS_SYSTEMFOLDERS "Répertoires système" IDS_LOCALHARDRIVES "Disques locaux" - IDS_FILENOTFOUND "Fichier non trouvé" - IDS_VERIFYFILE "Veuillez vérifier que le nom de fichier indiqué est correct" - IDS_CREATEFILE "Ce fichier n'existe pas.\nSouhaitez-vous le créer ?" - IDS_OVERWRITEFILE "Ce fichier existe déjà.\nVoulez-vous le remplacer ?" - IDS_INVALID_FILENAME_TITLE "Le chemin d'accès contient des caractères invalides" - IDS_INVALID_FILENAME "Un nom de fichier ne peut contenir aucun des caractères suivants :\n / : < > |" - IDS_PATHNOTEXISTING "Le chemin d'accès n'existe pas" + IDS_FILENOTFOUND "Fichier non trouvé" + IDS_VERIFYFILE "Prière de vérifier que le nom de fichier indiqué est correct" + IDS_CREATEFILE "Ce fichier n'existe pas.\nSouhaitez-vous le créer ?" + IDS_OVERWRITEFILE "Ce fichier existe déjà.\nVoulez-vous le remplacer ?" + IDS_INVALID_FILENAME_TITLE "Le chemin d'accès contient des caractères invalides" + IDS_INVALID_FILENAME "Un nom de fichier ne peut contenir un des caractères suivants :\n / : < > |" + IDS_PATHNOTEXISTING "Le chemin d'accès n'existe pas" IDS_FILENOTEXISTING "Le fichier n'existe pas" } STRINGTABLE DISCARDABLE { IDS_UPFOLDER "Remonter d'un niveau" - IDS_NEWFOLDER "Créer un nouveau dossier" + IDS_NEWFOLDER "Créer un nouveau dossier" IDS_LISTVIEW "Liste" - IDS_REPORTVIEW "Détails" + IDS_REPORTVIEW "Détails" IDS_TODESKTOP "Voir le bureau" } @@ -399,59 +392,59 @@ STRINGTABLE DISCARDABLE { PD32_PRINT_TITLE "Imprimer" - PD32_VALUE_UREADABLE "Entrée illisible" - PD32_INVALID_PAGE_RANGE "Cette valeur n'est pas dans l'étendue de pages\n\ + PD32_VALUE_UREADABLE "Entrée illisible" + PD32_INVALID_PAGE_RANGE "Cette valeur n'est pas dans l'intervalle de pages\n\ Veuillez indiquer une valeur entre %d et %d." - PD32_FROM_NOT_ABOVE_TO "Le champ « de » ne peut être plus grand \ -que le champ « à »." - PD32_MARGINS_OVERLAP "Les marges se chevauchent ou dépassent du papier\n\ + PD32_FROM_NOT_ABOVE_TO "Le champ « de » ne peut être plus grand \ +que le champ « à »." + PD32_MARGINS_OVERLAP "Les marges se recouvrent ou dépassent du papier\n\ Veuillez indiquer de nouvelles valeurs." - PD32_NR_OF_COPIES_EMPTY "Le champ « Nombre de copies » est vide.\n\ + PD32_NR_OF_COPIES_EMPTY "Le champ « Copies » est vide.\n\ Veuillez entrer un nombre et r&essayer." - PD32_TOO_LARGE_COPIES "Votre imprimante ne peut gérer autant de copies.\n\ + PD32_TOO_LARGE_COPIES "Votre imprimante ne peut gérer autant de copies.\n\ Veuillez indiquer un nombre de copies entre 1 et %d." - PD32_PRINT_ERROR "Une erreur d'impression s'est produite." - PD32_NO_DEFAULT_PRINTER "Imprimante par défaut non définie." + PD32_PRINT_ERROR "Une erreur d'impression est intervenue." + PD32_NO_DEFAULT_PRINTER "Pas d'imprimante par défaut." PD32_CANT_FIND_PRINTER "Impossible de trouver l'imprimante." - PD32_OUT_OF_MEMORY "Pas assez de mémoire." - PD32_GENERIC_ERROR "Une erreur s'est produite." + PD32_OUT_OF_MEMORY "Pas assez de mémoire." + PD32_GENERIC_ERROR "Une erreur est intervenue." PD32_DRIVER_UNKNOWN "Pilote d'imprimante inconnu." - PD32_NO_DEVICES "Avant de pouvoir effectuer des opérations en relation avec l'impression \ + PD32_NO_DEVICES "Avant de pouvoir effectuer des opérations en relation avec l'impression \ comme la configuration de l'imprimante ou l'impression d'un document, vous devez installer une imprimante. \ -Veuillez en installer une et réessayez." +Veuillez en installer une et réessayez." - PD32_DEFAULT_PRINTER "Imprimante par défaut ; " + PD32_DEFAULT_PRINTER "Imprimante par défaut ; " PD32_NR_OF_DOCUMENTS_IN_QUEUE "Il y a %d documents dans la file d'attente" - PD32_MARGINS_IN_INCHES "Marges (pouces]" - PD32_MARGINS_IN_MILLIMETERS "Marges (mm)" + PD32_MARGINS_IN_INCHES "Marges [pouces]" + PD32_MARGINS_IN_MILLIMETERS "Marges [mm]" PD32_MILLIMETERS "mm" - PD32_PRINTER_STATUS_READY "Prêt" - PD32_PRINTER_STATUS_PAUSED "Suspendu ; " - PD32_PRINTER_STATUS_ERROR "Erreur ; " - PD32_PRINTER_STATUS_PENDING_DELETION "En attente de suppression ; " - PD32_PRINTER_STATUS_PAPER_JAM "Bourrage papier ; " - PD32_PRINTER_STATUS_PAPER_OUT "Plus de papier ; " - PD32_PRINTER_STATUS_MANUAL_FEED "Insertion manuelle du papier ; " - PD32_PRINTER_STATUS_PAPER_PROBLEM "Problème de papier ; " - PD32_PRINTER_STATUS_OFFLINE "L'imprimante n'est pas en ligne ; " - PD32_PRINTER_STATUS_IO_ACTIVE "E/S Active ; " - PD32_PRINTER_STATUS_BUSY "Occupée ; " - PD32_PRINTER_STATUS_PRINTING "En cours d'impression ; " - PD32_PRINTER_STATUS_OUTPUT_BIN_FULL "Le bac de sortie est plein ; " - PD32_PRINTER_STATUS_NOT_AVAILABLE "Non disponible ; " - PD32_PRINTER_STATUS_WAITING "En attente ; " - PD32_PRINTER_STATUS_PROCESSING "Traitement en cours ; " - PD32_PRINTER_STATUS_INITIALIZING "Démarrage en cours ; " - PD32_PRINTER_STATUS_WARMING_UP "Préchauffage ; " - PD32_PRINTER_STATUS_TONER_LOW "Toner presque vide ; " - PD32_PRINTER_STATUS_NO_TONER "Pas de toner ; " - PD32_PRINTER_STATUS_PAGE_PUNT "Abandon de page ; " - PD32_PRINTER_STATUS_USER_INTERVENTION "Interrompu par utilisateur ; " - PD32_PRINTER_STATUS_OUT_OF_MEMORY "Plus assez de mémoire ; " - PD32_PRINTER_STATUS_DOOR_OPEN "La porte de l'imprimante est ouverte ; " - PD32_PRINTER_STATUS_SERVER_UNKNOWN "Serveur d'impression inconnu ; " - PD32_PRINTER_STATUS_POWER_SAVE "Mode économie d'énergie ; " + PD32_PRINTER_STATUS_READY "Prêt" + PD32_PRINTER_STATUS_PAUSED "Suspendu ; " + PD32_PRINTER_STATUS_ERROR "Erreur ; " + PD32_PRINTER_STATUS_PENDING_DELETION "En attente de suppression ; " + PD32_PRINTER_STATUS_PAPER_JAM "Bourrage papier ; " + PD32_PRINTER_STATUS_PAPER_OUT "Plus de papier ; " + PD32_PRINTER_STATUS_MANUAL_FEED "Insertion manuelle du papier ; " + PD32_PRINTER_STATUS_PAPER_PROBLEM "Problème de papier; " + PD32_PRINTER_STATUS_OFFLINE "L'imprimante n'est pas en ligne; " + PD32_PRINTER_STATUS_IO_ACTIVE "IO Active; " + PD32_PRINTER_STATUS_BUSY "Occupée; " + PD32_PRINTER_STATUS_PRINTING "En cours d'impression; " + PD32_PRINTER_STATUS_OUTPUT_BIN_FULL "Le bac de sortie est plein; " + PD32_PRINTER_STATUS_NOT_AVAILABLE "Non disponible ; " + PD32_PRINTER_STATUS_WAITING "En attente ; " + PD32_PRINTER_STATUS_PROCESSING "Traitement en cours ; " + PD32_PRINTER_STATUS_INITIALIZING "Démarrage en cours ; " + PD32_PRINTER_STATUS_WARMING_UP "Préchauffage ; " + PD32_PRINTER_STATUS_TONER_LOW "Toner presque vide ; " + PD32_PRINTER_STATUS_NO_TONER "Pas de toner ; " + PD32_PRINTER_STATUS_PAGE_PUNT "Abandon de page ; " + PD32_PRINTER_STATUS_USER_INTERVENTION "Annulé par utilisateur ; " + PD32_PRINTER_STATUS_OUT_OF_MEMORY "Plus assez de mémoire ; " + PD32_PRINTER_STATUS_DOOR_OPEN "La porte de l'imprimante est ouverte ; " + PD32_PRINTER_STATUS_SERVER_UNKNOWN "Serveur d'impression inconnu ; " + PD32_PRINTER_STATUS_POWER_SAVE "Mode économie d'énergie ; " } STRINGTABLE DISCARDABLE /* Font styles */ @@ -471,24 +464,24 @@ STRINGTABLE DISCARDABLE /* Color names */ IDS_COLOR_OLIVE "Olive" IDS_COLOR_NAVY "Bleu marine" IDS_COLOR_PURPLE "Pourpre" - IDS_COLOR_TEAL "Sarcelle" + IDS_COLOR_TEAL "Turquoise" IDS_COLOR_GRAY "Gris" IDS_COLOR_SILVER "Argent" IDS_COLOR_RED "Rouge" - IDS_COLOR_LIME "Citron vert" + IDS_COLOR_LIME "Lime" IDS_COLOR_YELLOW "Jaune" IDS_COLOR_BLUE "Bleu" IDS_COLOR_FUCHSIA "Fuchsia" - IDS_COLOR_AQUA "Eau" + IDS_COLOR_AQUA "Aqua" IDS_COLOR_WHITE "Blanc" } STRINGTABLE DISCARDABLE { - IDS_FONT_SIZE "Sélectionnez une taille de police entre %d et %d points." - IDS_SAVE_BUTTON "&Enregistrer" - IDS_SAVE_IN "Enregistrer &dans :" + IDS_FONT_SIZE "Sélectionnez une taille de police entre %d et %d points." + IDS_SAVE_BUTTON "&Sauver" + IDS_SAVE_IN "Sauver &dans :" IDS_SAVE "Enregistrer" IDS_SAVE_AS "Enregistrer sous" - IDS_OPEN_FILE "Ouvrir fichier" + IDS_OPEN_FILE "Ouvrir Fichier" } diff --git a/dlls/comdlg32/cdlg_Hu.rc b/dlls/comdlg32/cdlg_Hu.rc index 3bf7104c91b..3df3b2a4e70 100644 --- a/dlls/comdlg32/cdlg_Hu.rc +++ b/dlls/comdlg32/cdlg_Hu.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_It.rc b/dlls/comdlg32/cdlg_It.rc index beb9bd77849..f48b403f83d 100644 --- a/dlls/comdlg32/cdlg_It.rc +++ b/dlls/comdlg32/cdlg_It.rc @@ -18,9 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Ja.rc b/dlls/comdlg32/cdlg_Ja.rc index 0e0358f1f01..e29f2624d81 100644 --- a/dlls/comdlg32/cdlg_Ja.rc +++ b/dlls/comdlg32/cdlg_Ja.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ @@ -486,3 +483,5 @@ STRINGTABLE DISCARDABLE IDS_SAVE_AS "名前を付けて保存" IDS_OPEN_FILE "ファイルを開く" } + +#pragma code_page(default) diff --git a/dlls/comdlg32/cdlg_Ko.rc b/dlls/comdlg32/cdlg_Ko.rc index 1fc97981b71..74467935fdd 100644 --- a/dlls/comdlg32/cdlg_Ko.rc +++ b/dlls/comdlg32/cdlg_Ko.rc @@ -18,9 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Lt.rc b/dlls/comdlg32/cdlg_Lt.rc index c4bbf982d6d..1610413ce7a 100644 --- a/dlls/comdlg32/cdlg_Lt.rc +++ b/dlls/comdlg32/cdlg_Lt.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ @@ -79,14 +76,14 @@ FONT 8, "MS Shell Dlg" { LTEXT "Spausdintuvas:", 1088, 6, 6, 50, 9 LTEXT "", 1089, 60, 6, 150, 9 - GROUPBOX "Spausdinimo rėžis", grp1, 6, 30, 160, 65, BS_GROUPBOX + GROUPBOX "Spausdinimo intervalas", grp1, 6, 30, 160, 65, BS_GROUPBOX RADIOBUTTON "&Viskas", rad1, 16, 45, 60, 12 RADIOBUTTON "Pažymėtas &tekstas", rad2, 16, 60, 76, 12 RADIOBUTTON "&Puslapiai", rad3, 16, 75, 60, 12 DEFPUSHBUTTON "Spausdinti", 1, 206, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Atsisakyti", 2, 206, 24, 56, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Nuostatos", psh1, 206, 46, 56, 14, WS_GROUP | WS_TABSTOP - LTEXT "n&uo:", 1090, 60, 80, 30, 9 + LTEXT "&nuo:", 1090, 60, 80, 30, 9 LTEXT "&iki:", 1091, 120, 80, 30, 9 LTEXT "Spausdinimo &kokybė:", 1092, 6, 100, 76, 9 COMBOBOX cmb1, 80, 100, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP @@ -147,7 +144,7 @@ FONT 8, "MS Shell Dlg" CBS_AUTOHSCROLL | WS_BORDER | WS_VSCROLL | WS_TABSTOP GROUPBOX "Pavyzdys",grp2,98,72,120,36,WS_GROUP CTEXT "AaĄąZzŽž",stc5,103,80,109,24,SS_NOPREFIX | NOT WS_VISIBLE - LTEXT "Si&mbolių rinkinys:",stc7 ,98,114,60,9 + LTEXT "Sim&bolių rinkinys:",stc7 ,98,114,60,9 COMBOBOX cmb5,98,124,120,90,CBS_DROPDOWNLIST | CBS_HASSTRINGS | CBS_AUTOHSCROLL | WS_VSCROLL | WS_TABSTOP } @@ -159,11 +156,11 @@ CAPTION "Spalva" FONT 8, "MS Shell Dlg" { LTEXT "&Pagrindinės spalvos:", 1088, 4, 4, 140, 10 - LTEXT "Pr&itaikytos spalvos:", 1089, 4, 106, 140, 10 + LTEXT "&Individualios spalvos:", 1089, 4, 106, 140, 10 LTEXT "Spal. | Vient.", 1090, 150, 151, 48, 10 LTEXT "&Raudona:", 726 /*1094*/,243,126,32,10 EDITTEXT 706, 275,124,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "Ža&lia:",727/*1095*/,243,140,24,10 + LTEXT "&Žalia:",727/*1095*/,243,140,24,10 EDITTEXT 707, 275,138,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP LTEXT "&Mėlyna:",728 /*1096*/,243,154,24,10 EDITTEXT 708, 275,152,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP @@ -181,8 +178,8 @@ FONT 8, "MS Shell Dlg" DEFPUSHBUTTON "Gerai", 1, 4, 166, 44, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Atsisakyti", 2, 52, 166, 44, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Žinynas", pshHelp,100,166, 44, 14 - PUSHBUTTON "&Įdėti prie pritaikytų spalvų", 712/*1024*/, 152, 166, 142, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "Api&brėžti pritaikytas spalvas >>", 719/*1025*/, 4, 150, 142, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Įdėti prie individualių spalvų", 712/*1024*/, 152, 166, 142, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "A&pibrėžti individualias spalvas >>", 719/*1025*/, 4, 150, 142, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&i",713,300,200,4,14 /* just a dummy: 'i' is like &i in "sol&id" */ } @@ -198,7 +195,7 @@ FONT 8, "MS Shell Dlg" CHECKBOX "Skirti raidžių &dydį", chx2, 4, 42, 70, 12, BS_AUTOCHECKBOX | WS_TABSTOP GROUPBOX "Kryptis", grp1, 89, 26, 86, 28 CONTROL "&Aukštyn", rad1, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_GROUP | WS_TABSTOP, 93, 38, 40, 12 - CONTROL "Ž&emyn", rad2, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 134, 38, 36, 12 + CONTROL "&Žemyn", rad2, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 134, 38, 36, 12 DEFPUSHBUTTON "Ieškoti &kito", IDOK, 182, 5, 50, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON PUSHBUTTON "Atsisakyti", IDCANCEL , 182, 23, 50, 14, WS_GROUP | WS_TABSTOP @@ -213,7 +210,7 @@ FONT 8, "MS Shell Dlg" { LTEXT "Ko &ieškoti:", -1, 4, 9, 48, 8 EDITTEXT edt1, 54, 7, 114, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "Kuo pak&eisti:", -1, 4, 26, 48, 8 + LTEXT "Kuo pa&keisti:", -1, 4, 26, 48, 8 EDITTEXT edt2, 54, 24, 114, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP CHECKBOX "Tenkina tik &visas žodis", chx1, 5, 46, 104, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP CHECKBOX "Skirti raidžių &dydį", chx2, 5, 62, 70, 12, BS_AUTOCHECKBOX | WS_TABSTOP @@ -256,7 +253,7 @@ FONT 8, "MS Shell Dlg" CONTROL "Su&dėst.", chx2,"Button",BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP,240,130,36,12 EDITTEXT edt3, 240,106, 32,12, WS_GROUP | ES_NUMBER - GROUPBOX "Rėžis", grp1, 8,92, 144,64, WS_GROUP + GROUPBOX "Intervalas", grp1, 8,92, 144,64, WS_GROUP CONTROL "V&isi puslapiai", rad1,"Button",BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,16,106,64,12 CONTROL "Pu&slapiai", rad3,"Button",BS_AUTORADIOBUTTON,16,122,40,12 CONTROL "Pažymėtas &tekstas", rad2,"Button",BS_AUTORADIOBUTTON,16,138,72,12 @@ -312,7 +309,7 @@ BEGIN GROUPBOX "Popierius", grp2, 8, 96, 224, 56, BS_GROUPBOX LTEXT "&Dydis:", stc2, 16, 112, 36, 8 COMBOBOX cmb2, 64, 110, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - LTEXT "Dėk&las:", stc3, 16, 132, 36, 8 + LTEXT "Dė&klas:", stc3, 16, 132, 36, 8 COMBOBOX cmb3, 64, 130, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL GROUPBOX "Padėtis", grp1, 8, 156, 64, 56, BS_GROUPBOX AUTORADIOBUTTON "&Stačias", rad1, 16, 170, 52, 12, BS_AUTORADIOBUTTON @@ -342,7 +339,7 @@ FONT 8, "MS Shell Dlg" LTEXT "" , IDC_TOOLBARSTATIC, 181, 2, 102, 17, NOT WS_GROUP | NOT WS_VISIBLE LISTBOX IDC_SHELLSTATIC,4,20,272,85, LBS_SORT | LBS_NOINTEGRALHEIGHT | LBS_MULTICOLUMN | WS_HSCROLL | NOT WS_VISIBLE - LTEXT "&Failo vardas:",IDC_FILENAMESTATIC,5,112,46,8, SS_NOTIFY + LTEXT "Failo &vardas:",IDC_FILENAMESTATIC,5,112,46,8, SS_NOTIFY EDITTEXT IDC_FILENAME,54,110,155,12,ES_AUTOHSCROLL LTEXT "Failų &tipai:",IDC_FILETYPESTATIC,5,128,42,8, SS_NOTIFY @@ -395,23 +392,25 @@ STRINGTABLE DISCARDABLE PD32_PRINT_TITLE "Spausdinti" PD32_VALUE_UREADABLE "Neperskaitomas įrašas" - PD32_INVALID_PAGE_RANGE "Ši reikšmė nepatenka į puslapių rėžį.\n\ - Prašome įvesti reikšmę tarp %d ir %d." - PD32_FROM_NOT_ABOVE_TO "„Nuo“ reikšmė negali viršyti „iki“ reikšmės." - PD32_MARGINS_OVERLAP "Paraštės persidengia arba išeina už popieriaus ribų.\n\ - Prašome įvesti paraštes iš naujo." - PD32_NR_OF_COPIES_EMPTY "Skaitinė „kopijų skaičius“ reikšmė negali būti tuščia." - PD32_TOO_LARGE_COPIES "Toks didelis kopijų skaičius yra nepalaikomas jūsų spausdintuvo.\n\ - Prašome įvesti reikšmę tarp 1 ir %d." + PD32_INVALID_PAGE_RANGE "Ši reikšmė nepatenka į puslapių intervalą.\n\ +Prašome įvesti reikšmę tarp %d ir %d." + PD32_FROM_NOT_ABOVE_TO "'Nuo' reikšmė negali viršyti \ +'iki' reikšmės." + PD32_MARGINS_OVERLAP "Paraštės persidengia arba išeina už \ +popieriaus ribų.\nPrašome įvesti paraštes iš naujo." + PD32_NR_OF_COPIES_EMPTY "Skaitinė 'Kopijų skaičius' \ +reikšmė negali būti tuščia." + PD32_TOO_LARGE_COPIES "Toks didelis kopijų skaičius yra \ +nepalaikomas jūsų spausdintuvo.\nPrašome įvesti reikšmę tarp 1 ir %d." PD32_PRINT_ERROR "Įvyko spausdintuvo klaida." PD32_NO_DEFAULT_PRINTER "Nenurodytas pagrindinis spausdintuvas." PD32_CANT_FIND_PRINTER "Nepavyko rasti spausdintuvo." - PD32_OUT_OF_MEMORY "Trūksta atminties." + PD32_OUT_OF_MEMORY "Baigėsi atmintis." PD32_GENERIC_ERROR "Įvyko klaida." PD32_DRIVER_UNKNOWN "Nežinoma spausdintuvo tvarkyklė." PD32_NO_DEVICES "Prieš atlikdami su spausdintuvu susijusius veiksmus, \ tokius kaip puslapio nuostatų keitimas ar dokumento spausdinimas, turite įdiegti spausdintuvą. \ -Prašome įdiegti spausdintuvą ir pakartoti." +Prašome įdeigti spausdintuvą ir pakartoti." PD32_DEFAULT_PRINTER "Pagrindinis spausdintuvas; " PD32_NR_OF_DOCUMENTS_IN_QUEUE "Eilėje yra %d dokumentų" @@ -441,7 +440,7 @@ Prašome įdiegti spausdintuvą ir pakartoti." PD32_PRINTER_STATUS_NO_TONER "Nėra dažų; " PD32_PRINTER_STATUS_PAGE_PUNT "Puslapis perkrautas; " PD32_PRINTER_STATUS_USER_INTERVENTION "Pertraukta naudotojo; " - PD32_PRINTER_STATUS_OUT_OF_MEMORY "Trūksta atminties; " + PD32_PRINTER_STATUS_OUT_OF_MEMORY "Baigėsi atmintis; " PD32_PRINTER_STATUS_DOOR_OPEN "Spausdintuvo durelės atidarytos; " PD32_PRINTER_STATUS_SERVER_UNKNOWN "Spausdinimo serveris nežinomas; " PD32_PRINTER_STATUS_POWER_SAVE "Energijos taupymo režimas; " @@ -471,7 +470,7 @@ STRINGTABLE DISCARDABLE /* Color names */ IDS_COLOR_YELLOW "Geltona" IDS_COLOR_BLUE "Mėlyna" IDS_COLOR_FUCHSIA "Fuksija" - IDS_COLOR_AQUA "Žydra" + IDS_COLOR_AQUA "Akvarelinis cianas" IDS_COLOR_WHITE "Balta" } @@ -484,3 +483,4 @@ STRINGTABLE DISCARDABLE IDS_SAVE_AS "Išsaugoti kaip" IDS_OPEN_FILE "Atverti failą" } +#pragma code_page(default) diff --git a/dlls/comdlg32/cdlg_Nl.rc b/dlls/comdlg32/cdlg_Nl.rc index 340c2db8691..6910405154e 100644 --- a/dlls/comdlg32/cdlg_Nl.rc +++ b/dlls/comdlg32/cdlg_Nl.rc @@ -17,9 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ @@ -240,7 +237,7 @@ FONT 8, "MS Shell Dlg" LTEXT "Bestands&typen:",IDC_FILETYPESTATIC,5,128,48,8, SS_NOTIFY COMBOBOX IDC_FILETYPE,54,126,155,53,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - CONTROL "Openen met als kenmerk &Alleen-lezen",IDC_OPENREADONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,54,145,140,10 + CONTROL "Openen met als kenmerk &Alleen-lezen",IDC_OPENREADONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,54,145,100,10 DEFPUSHBUTTON "&Openen", IDOK,222,110,50,14 PUSHBUTTON "Annuleren", IDCANCEL,222,128,50,14 diff --git a/dlls/comdlg32/cdlg_No.rc b/dlls/comdlg32/cdlg_No.rc index 75e8f792405..e1d35f5416a 100644 --- a/dlls/comdlg32/cdlg_No.rc +++ b/dlls/comdlg32/cdlg_No.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Pl.rc b/dlls/comdlg32/cdlg_Pl.rc index 71c1afebe5f..796054b6db3 100644 --- a/dlls/comdlg32/cdlg_Pl.rc +++ b/dlls/comdlg32/cdlg_Pl.rc @@ -18,9 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Pt.rc b/dlls/comdlg32/cdlg_Pt.rc index b061f613146..2da9de53fdf 100644 --- a/dlls/comdlg32/cdlg_Pt.rc +++ b/dlls/comdlg32/cdlg_Pt.rc @@ -1,8 +1,7 @@ /* * Copyright 1997 Ricardo R. Massaro * Copyright 2003 Marcelo Duarte - * Copyright 2006-2007 Américo José Melo - * Copyright 2009 Ricardo Filipe + * Copyright 2006-2007 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 @@ -19,15 +18,10 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ -#pragma code_page(65001) - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN OPEN_FILE DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 275, 134 @@ -38,7 +32,7 @@ FONT 8, "MS Shell Dlg" LTEXT "Nome do &Arquivo:", 1090, 6, 6, 76, 9 EDITTEXT 1152, 6, 16, 90, 12, ES_AUTOHSCROLL | ES_OEMCONVERT | WS_BORDER | WS_TABSTOP LISTBOX 1120, 6, 32, 90, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP - LTEXT "&Diretórios:", -1, 110, 6, 92, 9 + LTEXT "&Diretórios:", -1, 110, 6, 92, 9 LTEXT "", 1088, 110, 18, 92, 9, SS_NOPREFIX | WS_GROUP LISTBOX 1121, 110, 32, 92, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP LTEXT "Listar Arquivos do &Tipo:", 1089, 6, 104, 90, 9 @@ -61,7 +55,7 @@ FONT 8, "MS Shell Dlg" LTEXT "Nome do &Ficheiro:", 1090, 6, 6, 76, 9 EDITTEXT 1152, 6, 16, 90, 12, ES_AUTOHSCROLL | ES_OEMCONVERT | WS_BORDER | WS_TABSTOP LISTBOX 1120, 6, 32, 90, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP - LTEXT "&Directórios:", -1, 110, 6, 92, 9 + LTEXT "&Directórios:", -1, 110, 6, 92, 9 LTEXT "", 1088, 110, 18, 92, 9, SS_NOPREFIX | WS_GROUP LISTBOX 1121, 110, 32, 92, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP LTEXT "Listar Ficheiros do &Tipo:", 1089, 6, 104, 90, 9 @@ -85,7 +79,7 @@ FONT 8, "MS Shell Dlg" LTEXT "Nome do &Arquivo:", 1090, 6, 6, 76, 9 EDITTEXT 1152, 6, 16, 90, 12, ES_AUTOHSCROLL | ES_OEMCONVERT | WS_BORDER | WS_TABSTOP LISTBOX 1120, 6, 32, 90, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP - LTEXT "&Diretórios:", -1, 110, 6, 92, 9 + LTEXT "&Diretórios:", -1, 110, 6, 92, 9 LTEXT "", 1088, 110, 18, 92, 9, SS_NOPREFIX | WS_GROUP LISTBOX 1121, 110, 32, 92, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP LTEXT "Listar Arquivos do &Tipo:", 1089, 6, 104, 90, 9 @@ -108,7 +102,7 @@ FONT 8, "MS Shell Dlg" LTEXT "Nome do &Ficheiro:", 1090, 6, 6, 76, 9 EDITTEXT 1152, 6, 16, 90, 12, ES_AUTOHSCROLL | ES_OEMCONVERT | WS_BORDER | WS_TABSTOP LISTBOX 1120, 6, 32, 90, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP - LTEXT "&Directórios:", -1, 110, 6, 92, 9 + LTEXT "&Directórios:", -1, 110, 6, 92, 9 LTEXT "", 1088, 110, 18, 92, 9, SS_NOPREFIX | WS_GROUP LISTBOX 1121, 110, 32, 92, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP LTEXT "Listar Ficheiros do &Tipo:", 1089, 6, 104, 90, 9 @@ -131,16 +125,16 @@ FONT 8, "MS Shell Dlg" { LTEXT "Impressora:", 1088, 6, 6, 40, 9 LTEXT "", 1089, 60, 6, 150, 9 - GROUPBOX "Faixa de Impressão", 1072, 6, 30, 160, 65, BS_GROUPBOX + GROUPBOX "Faixa de Impressão", 1072, 6, 30, 160, 65, BS_GROUPBOX RADIOBUTTON "&Tudo", 1056, 16, 45, 60, 12 - RADIOBUTTON "S&eleção", 1057, 16, 60, 60, 12 - RADIOBUTTON "&Páginas", 1058, 16, 75, 60, 12 + RADIOBUTTON "S&eleção", 1057, 16, 60, 60, 12 + RADIOBUTTON "&Páginas", 1058, 16, 75, 60, 12 DEFPUSHBUTTON "Imprimir", IDOK, 206, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Cancelar", IDCANCEL, 206, 24, 56, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Configurar", 1024, 206, 46, 56, 14, WS_GROUP | WS_TABSTOP LTEXT "&De:", 1090, 60, 80, 30, 9 LTEXT "&Ate:", 1091, 120, 80, 30, 9 - LTEXT "&Qualidade de Impressão:", 1092, 6, 100, 76, 9 + LTEXT "&Qualidade de Impressão:", 1092, 6, 100, 76, 9 COMBOBOX 1136, 80, 100, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP CHECKBOX "Imprimir para Arquivo", 1040, 20, 100, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP CHECKBOX "C&ondensado", 1041, 160, 100, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP @@ -155,16 +149,16 @@ FONT 8, "MS Shell Dlg" { LTEXT "Impressora:", 1088, 6, 6, 40, 9 LTEXT "", 1089, 60, 6, 150, 9 - GROUPBOX "Faixa de Impressão", 1072, 6, 30, 160, 65, BS_GROUPBOX + GROUPBOX "Faixa de Impressão", 1072, 6, 30, 160, 65, BS_GROUPBOX RADIOBUTTON "&Tudo", 1056, 16, 45, 60, 12 - RADIOBUTTON "S&elecção", 1057, 16, 60, 60, 12 - RADIOBUTTON "&Páginas", 1058, 16, 75, 60, 12 + RADIOBUTTON "S&elecção", 1057, 16, 60, 60, 12 + RADIOBUTTON "&Páginas", 1058, 16, 75, 60, 12 DEFPUSHBUTTON "Imprimir", IDOK, 206, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Cancelar", IDCANCEL, 206, 24, 56, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Configurar", 1024, 206, 46, 56, 14, WS_GROUP | WS_TABSTOP LTEXT "&De:", 1090, 60, 80, 30, 9 - LTEXT "&Até:", 1091, 120, 80, 30, 9 - LTEXT "&Qualidade de Impressão:", 1092, 6, 100, 76, 9 + LTEXT "&Até:", 1091, 120, 80, 30, 9 + LTEXT "&Qualidade de Impressão:", 1092, 6, 100, 76, 9 COMBOBOX 1136, 80, 100, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP CHECKBOX "Imprimir para Ficheiro", 1040, 20, 100, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP CHECKBOX "C&ondensado", 1041, 160, 100, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP @@ -175,25 +169,25 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN PRINT_SETUP DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 264, 134 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Configurações de Impressão" +CAPTION "Configurações de Impressão" FONT 8, "MS Shell Dlg" { GROUPBOX "Impressora", 1072, 6, 10, 180, 65, BS_GROUPBOX - RADIOBUTTON "&Impressora Padrão", 1056, 16, 20, 80, 12 + RADIOBUTTON "&Impressora Padrão", 1056, 16, 20, 80, 12 LTEXT "[none]", 1088, 35, 35, 120, 9 - RADIOBUTTON "Impressora &Específica", 1057, 16, 50, 80, 12 + RADIOBUTTON "Impressora &Específica", 1057, 16, 50, 80, 12 COMBOBOX 1136, 35, 65, 149, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP DEFPUSHBUTTON "OK", IDOK, 206, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Cancelar", IDCANCEL, 206, 24, 56, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Configurar", 1024, 206, 46, 56, 14, WS_GROUP | WS_TABSTOP - GROUPBOX "Orientação", 1073, 6, 85, 100, 50, BS_GROUPBOX + GROUPBOX "Orientação", 1073, 6, 85, 100, 50, BS_GROUPBOX RADIOBUTTON "&Retrato", 1058, 50, 100, 40, 12 RADIOBUTTON "&Paisagem", 1059, 50, 115, 40, 12 ICON "LANDSCAP", 1097, 10, 95, 32, 32 ICON "PORTRAIT", 1098, 10, 95, 32, 32 GROUPBOX "Papel", 1074, 120, 85, 180, 50, BS_GROUPBOX LTEXT "&Tamanho", 1089, 130, 95, 30, 9 - LTEXT "&Fonte de Alimentação", 1090, 130, 110, 30, 9 + LTEXT "&Fonte de Alimentação", 1090, 130, 110, 30, 9 COMBOBOX 1137, 155, 95, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP COMBOBOX 1138, 155, 110, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP } @@ -202,25 +196,25 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE PRINT_SETUP DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 264, 134 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Configurações de Impressão" +CAPTION "Configurações de Impressão" FONT 8, "MS Shell Dlg" { GROUPBOX "Impressora", 1072, 6, 10, 180, 65, BS_GROUPBOX RADIOBUTTON "&Impressora Predefinida", 1056, 16, 20, 80, 12 LTEXT "[none]", 1088, 35, 35, 120, 9 - RADIOBUTTON "Impressora &Específica", 1057, 16, 50, 80, 12 + RADIOBUTTON "Impressora &Específica", 1057, 16, 50, 80, 12 COMBOBOX 1136, 35, 65, 149, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP DEFPUSHBUTTON "OK", IDOK, 206, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Cancelar", IDCANCEL, 206, 24, 56, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Configurar", 1024, 206, 46, 56, 14, WS_GROUP | WS_TABSTOP - GROUPBOX "Orientação", 1073, 6, 85, 100, 50, BS_GROUPBOX + GROUPBOX "Orientação", 1073, 6, 85, 100, 50, BS_GROUPBOX RADIOBUTTON "&Retrato", 1058, 50, 100, 40, 12 RADIOBUTTON "&Paisagem", 1059, 50, 115, 40, 12 ICON "LANDSCAP", 1097, 10, 95, 32, 32 ICON "PORTRAIT", 1098, 10, 95, 32, 32 GROUPBOX "Papel", 1074, 120, 85, 180, 50, BS_GROUPBOX LTEXT "&Tamanho", 1089, 130, 95, 30, 9 - LTEXT "&Fonte de Alimentação", 1090, 130, 110, 30, 9 + LTEXT "&Fonte de Alimentação", 1090, 130, 110, 30, 9 COMBOBOX 1137, 155, 95, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP COMBOBOX 1138, 155, 110, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP } @@ -301,9 +295,9 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Cor" FONT 8, "MS Shell Dlg" { - LTEXT "Cores &Básicas:", 1088, 4, 4, 140, 10 - LTEXT "&Cores do Usuário:", 1089, 4, 106, 140, 10 - LTEXT "Colorido|Sólid&o", 1090, 150, 151, 48, 10 + LTEXT "Cores &Básicas:", 1088, 4, 4, 140, 10 + LTEXT "&Cores do Usuário:", 1089, 4, 106, 140, 10 + LTEXT "Colorido|Sólid&o", 1090, 150, 151, 48, 10 LTEXT "Ver&melho:", 726 /*1094*/,249,126,24,10 EDITTEXT 706, 275,124,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP LTEXT "&Verde:",727/*1095*/,249,140,24,10 @@ -336,9 +330,9 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Cor" FONT 8, "MS Shell Dlg" { -LTEXT "Cores &Básicas:", 1088, 4, 4, 140, 10 +LTEXT "Cores &Básicas:", 1088, 4, 4, 140, 10 LTEXT "&Cores do Utilizador:", 1089, 4, 106, 140, 10 -LTEXT "Colorido|Sólid&o", 1090, 150, 151, 48, 10 +LTEXT "Colorido|Sólid&o", 1090, 150, 151, 48, 10 LTEXT "Ver&melho:", 726 /*1094*/,249,126,24,10 EDITTEXT 706, 275,124,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP LTEXT "&Verde:",727/*1095*/,249,140,24,10 @@ -374,12 +368,12 @@ FONT 8, "MS Shell Dlg" LTEXT "&Procurar:", -1, 4, 8, 42, 8 EDITTEXT 1152, 47, 7, 128, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP CHECKBOX "Palavra &Inteira", 1040, 4, 26, 100, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - CHECKBOX "&Maiúsculas/minusculas", 1041, 4, 42, 64, 12, BS_AUTOCHECKBOX | WS_TABSTOP - GROUPBOX "Direção", 1072, 107, 26, 68, 28 + CHECKBOX "&Maiúsculas/minusculas", 1041, 4, 42, 64, 12, BS_AUTOCHECKBOX | WS_TABSTOP + GROUPBOX "Direção", 1072, 107, 26, 68, 28 CONTROL "A&cima", 1056, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_GROUP | WS_TABSTOP, 111, 38, 20, 12 CONTROL "A&baixo", 1057, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 138, 38, 30, 12 - DEFPUSHBUTTON "Procurar a Pró&xima", IDOK, 182, 5, 50, 14, WS_GROUP | WS_TABSTOP + DEFPUSHBUTTON "Procurar a Pró&xima", IDOK, 182, 5, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "Cancelar", IDCANCEL, 182, 23, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "A&juda", 1038, 182, 45, 50, 14, WS_GROUP | WS_TABSTOP } @@ -394,12 +388,12 @@ FONT 8, "MS Shell Dlg" LTEXT "&Procurar:", -1, 4, 8, 42, 8 EDITTEXT 1152, 47, 7, 128, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP CHECKBOX "Palavra &Inteira", 1040, 4, 26, 100, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - CHECKBOX "&Maiúsculas/minúsculas", 1041, 4, 42, 64, 12, BS_AUTOCHECKBOX | WS_TABSTOP - GROUPBOX "Direcção", 1072, 107, 26, 68, 28 + CHECKBOX "&Maiúsculas/minúsculas", 1041, 4, 42, 64, 12, BS_AUTOCHECKBOX | WS_TABSTOP + GROUPBOX "Direcção", 1072, 107, 26, 68, 28 CONTROL "A&cima", 1056, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_GROUP | WS_TABSTOP, 111, 38, 20, 12 CONTROL "A&baixo", 1057, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 138, 38, 30, 12 - DEFPUSHBUTTON "&Procurar Próximo", IDOK, 182, 5, 50, 14, WS_GROUP | WS_TABSTOP + DEFPUSHBUTTON "&Procurar Próximo", IDOK, 182, 5, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "Cancelar", IDCANCEL, 182, 23, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "A&juda", 1038, 182, 45, 50, 14, WS_GROUP | WS_TABSTOP } @@ -417,9 +411,9 @@ FONT 8, "MS Shell Dlg" LTEXT "Substituir Pa&ra:", -1, 4, 26, 48, 8 EDITTEXT 1153, 54, 24, 114, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP CHECKBOX "Palavra &inteira", 1040, 5, 46, 104, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - CHECKBOX "&Maiúsculas/minúsculas", 1041, 5, 62, 59, 12, BS_AUTOCHECKBOX | WS_TABSTOP + CHECKBOX "&Maiúsculas/minúsculas", 1041, 5, 62, 59, 12, BS_AUTOCHECKBOX | WS_TABSTOP - DEFPUSHBUTTON "Procurar a Pró&xima", IDOK, 174, 4, 50, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON + DEFPUSHBUTTON "Procurar a Pró&xima", IDOK, 174, 4, 50, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON PUSHBUTTON "&Substituir", psh1, 174, 21, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "Substituir &Todas", psh2, 174, 38, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "Cancelar", IDCANCEL, 174, 55, 50, 14, WS_GROUP | WS_TABSTOP @@ -438,9 +432,9 @@ FONT 8, "MS Shell Dlg" LTEXT "Substituir Pa&ra:", -1, 4, 26, 48, 8 EDITTEXT 1153, 54, 24, 114, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP CHECKBOX "Palavra &inteira", 1040, 5, 46, 104, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - CHECKBOX "&Maiúsculas/minúsculas", 1041, 5, 62, 59, 12, BS_AUTOCHECKBOX | WS_TABSTOP + CHECKBOX "&Maiúsculas/minúsculas", 1041, 5, 62, 59, 12, BS_AUTOCHECKBOX | WS_TABSTOP - DEFPUSHBUTTON "Procurar Próxima", IDOK, 174, 4, 50, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON + DEFPUSHBUTTON "Procurar Próxima", IDOK, 174, 4, 50, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON PUSHBUTTON "&Substituir", psh1, 174, 21, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "Substituir &Todas", psh2, 174, 38, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "Cancelar", IDCANCEL, 174, 55, 50, 14, WS_GROUP | WS_TABSTOP @@ -471,23 +465,23 @@ FONT 8, "MS Shell Dlg" LTEXT "Dummy Type", stc11, 52, 48, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP LTEXT "Onde:", stc10, 16, 60, 36,10, SS_NOPREFIX LTEXT "Dummy Location", stc14, 52, 60, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Comentário:", stc9, 16, 72, 36,10, SS_NOPREFIX + LTEXT "Comentário:", stc9, 16, 72, 36,10, SS_NOPREFIX LTEXT "Dummy Remark", stc13, 52, 72, 152,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - GROUPBOX "Cópias", grp2, 160, 92, 120,64, WS_GROUP - LTEXT "Número de &cópias:", stc5, 168,108, 68, 8 + GROUPBOX "Cópias", grp2, 160, 92, 120,64, WS_GROUP + LTEXT "Número de &cópias:", stc5, 168,108, 68, 8 ICON "", ico3, 162,124, 76,24, WS_GROUP | SS_CENTERIMAGE CONTROL "&Agrupar", chx2,"Button",BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP,240,130,36,12 EDITTEXT edt3, 240,106, 32,12, WS_GROUP | ES_NUMBER - GROUPBOX "Faixa de impressão", grp1, 8,92, 144,64, WS_GROUP + GROUPBOX "Faixa de impressão", grp1, 8,92, 144,64, WS_GROUP CONTROL "&Todos", rad1,"Button",BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,16,106,64,12 - CONTROL "Pá&ginas", rad3,"Button",BS_AUTORADIOBUTTON,16,122,36,12 - CONTROL "Seleção", rad2,"Button",BS_AUTORADIOBUTTON,16,138,64,12 + CONTROL "Pá&ginas", rad3,"Button",BS_AUTORADIOBUTTON,16,122,36,12 + CONTROL "Seleção", rad2,"Button",BS_AUTORADIOBUTTON,16,138,64,12 EDITTEXT edt1, 74,122, 26,12, WS_GROUP | ES_NUMBER EDITTEXT edt2, 118,122, 26,12, WS_GROUP | ES_NUMBER RTEXT "&de:", stc2, 52,124, 20,8 - RTEXT "&até:", stc3, 100,124, 16,8 + RTEXT "&até:", stc3, 100,124, 16,8 } LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE @@ -511,25 +505,25 @@ FONT 8, "MS Shell Dlg" LTEXT "Estado 'Dummy'", stc12, 52, 36, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP LTEXT "Tipo:", stc7, 16, 48, 36,10, SS_NOPREFIX LTEXT "Tipo 'Dummy'", stc11, 52, 48, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Localizaça:", stc10, 16, 60, 36,10, SS_NOPREFIX - LTEXT "Localizaçao 'Dummy'", stc14, 52, 60, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Comentário:", stc9, 16, 72, 36,10, SS_NOPREFIX - LTEXT "Comentário 'Dummy'", stc13, 52, 72, 152,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Localizaça:", stc10, 16, 60, 36,10, SS_NOPREFIX + LTEXT "Localizaçao 'Dummy'", stc14, 52, 60, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Comentário:", stc9, 16, 72, 36,10, SS_NOPREFIX + LTEXT "Comentário 'Dummy'", stc13, 52, 72, 152,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - GROUPBOX "Cópias", grp2, 160, 92, 120,64, WS_GROUP - LTEXT "Número de &cópias:", stc5, 168,108, 68, 8 + GROUPBOX "Cópias", grp2, 160, 92, 120,64, WS_GROUP + LTEXT "Número de &cópias:", stc5, 168,108, 68, 8 ICON "", ico3, 162,124, 76,24, WS_GROUP | SS_CENTERIMAGE CONTROL "&Agrupar", chx2,"Button",BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP,240,130,36,12 EDITTEXT edt3, 240,106, 32,12, WS_GROUP | ES_NUMBER - GROUPBOX "Faixa de impressão", grp1, 8,92, 144,64, WS_GROUP + GROUPBOX "Faixa de impressão", grp1, 8,92, 144,64, WS_GROUP CONTROL "&Todos", rad1,"Button",BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,16,106,64,12 - CONTROL "Páginas", rad3,"Button",BS_AUTORADIOBUTTON,16,122,36,12 - CONTROL "Selecção", rad2,"Button",BS_AUTORADIOBUTTON,16,138,64,12 + CONTROL "Páginas", rad3,"Button",BS_AUTORADIOBUTTON,16,122,36,12 + CONTROL "Selecção", rad2,"Button",BS_AUTORADIOBUTTON,16,138,64,12 EDITTEXT edt1, 74,122, 26,12, WS_GROUP | ES_NUMBER EDITTEXT edt2, 118,122, 26,12, WS_GROUP | ES_NUMBER RTEXT "&de:", stc2, 52,124, 20,8 - RTEXT "&até", stc3, 100,124, 16,8 + RTEXT "&até", stc3, 100,124, 16,8 } @@ -538,7 +532,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN PRINT32_SETUP DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 288, 178 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | DS_CONTEXTHELP | DS_3DLOOK -CAPTION "Configurações de Impressão" +CAPTION "Configurações de Impressão" FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "OK", IDOK,180,156,50,14,WS_GROUP @@ -555,7 +549,7 @@ BEGIN LTEXT "Dummy Type", stc11, 52, 48, 224, 10, SS_NOPREFIX | SS_LEFTNOWORDWRAP LTEXT "Onde:", stc10, 16, 60, 36, 10, SS_NOPREFIX LTEXT "Dummy Location", stc14, 52, 60, 224, 10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Comentário", stc9, 16, 72, 36, 10, SS_NOPREFIX + LTEXT "Comentário", stc9, 16, 72, 36, 10, SS_NOPREFIX LTEXT "Dummy Remark", stc13, 52, 72, 224, 10, SS_NOPREFIX | SS_LEFTNOWORDWRAP GROUPBOX "Papel", grp2, 8, 92, 164, 56, WS_GROUP @@ -564,7 +558,7 @@ BEGIN LTEXT "&Origem:", stc3, 16, 128, 36, 8 COMBOBOX cmb3, 52, 126, 112, 112, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP - GROUPBOX "Orientação", grp1, 180, 92, 100, 56, WS_GROUP + GROUPBOX "Orientação", grp1, 180, 92, 100, 56, WS_GROUP ICON "", ico1, 195, 112, 18, 20, WS_GROUP CONTROL "&Retrato", rad1, "Button", BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP, 224, 106, 52, 12 CONTROL "&Paisagem", rad2, "Button", BS_AUTORADIOBUTTON, 224, 126, 52, 12 @@ -575,7 +569,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE PRINT32_SETUP DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 288, 178 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | DS_CONTEXTHELP | DS_3DLOOK -CAPTION "Configuração de Impressão" +CAPTION "Configuração de Impressão" FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "OK", IDOK,180,156,50,14,WS_GROUP @@ -590,10 +584,10 @@ BEGIN LTEXT "EStado 'Dummy'", stc12, 52, 36, 224, 10, SS_NOPREFIX | SS_LEFTNOWORDWRAP LTEXT "Tipo:", stc7, 16, 48, 36, 10, SS_NOPREFIX LTEXT "Tipo 'Dummy'", stc11, 52, 48, 224, 10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Localização:", stc10, 16, 60, 36, 10, SS_NOPREFIX - LTEXT "Localização 'Dummy'", stc14, 52, 60, 224, 10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Comentário", stc9, 16, 72, 36, 10, SS_NOPREFIX - LTEXT "Comentário 'Dummy'", stc13, 52, 72, 224, 10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Localização:", stc10, 16, 60, 36, 10, SS_NOPREFIX + LTEXT "Localização 'Dummy'", stc14, 52, 60, 224, 10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Comentário", stc9, 16, 72, 36, 10, SS_NOPREFIX + LTEXT "Comentário 'Dummy'", stc13, 52, 72, 224, 10, SS_NOPREFIX | SS_LEFTNOWORDWRAP GROUPBOX "Papel", grp2, 8, 92, 164, 56, WS_GROUP LTEXT "&Tamanho:", stc2, 16, 108, 36, 8 @@ -601,7 +595,7 @@ BEGIN LTEXT "&Origem:", stc3, 16, 128, 36, 8 COMBOBOX cmb3, 52, 126, 112, 112, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP - GROUPBOX "Orientação", grp1, 180, 92, 100, 56, WS_GROUP + GROUPBOX "Orientação", grp1, 180, 92, 100, 56, WS_GROUP ICON "", ico1, 195, 112, 18, 20, WS_GROUP CONTROL "&Retrato", rad1, "Button", BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP, 224, 106, 52, 12 CONTROL "&Paisagem", rad2, "Button", BS_AUTORADIOBUTTON, 224, 126, 52, 12 @@ -612,7 +606,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN PAGESETUPDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 240, 240 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Configurações de Página" +CAPTION "Configurações de Página" FONT 8, "MS Shell Dlg" BEGIN CONTROL "", rct1, "Static", SS_WHITERECT, 80, 8, 80, 80 @@ -623,7 +617,7 @@ BEGIN COMBOBOX cmb2, 64, 110, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL LTEXT "&Bandeja:", stc3, 16, 132, 36, 8 COMBOBOX cmb3, 64, 130, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - GROUPBOX "Orientação", grp1, 8, 156, 64, 56, BS_GROUPBOX + GROUPBOX "Orientação", grp1, 8, 156, 64, 56, BS_GROUPBOX AUTORADIOBUTTON "&Retrato", rad1, 16, 170, 52, 12, BS_AUTORADIOBUTTON AUTORADIOBUTTON "&Paisagem", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON GROUPBOX "Bordas", grp4, 80, 156, 152, 56, BS_GROUPBOX @@ -644,7 +638,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE PAGESETUPDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 240, 240 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Configurações de Página" +CAPTION "Configurações de Página" FONT 8, "MS Shell Dlg" BEGIN CONTROL "", rct1, "Static", SS_WHITERECT, 80, 8, 80, 80 @@ -655,7 +649,7 @@ BEGIN COMBOBOX cmb2, 64, 110, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL LTEXT "&Bandeja:", stc3, 16, 132, 36, 8 COMBOBOX cmb3, 64, 130, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - GROUPBOX "Orientação", grp1, 8, 156, 64, 56, BS_GROUPBOX + GROUPBOX "Orientação", grp1, 8, 156, 64, 56, BS_GROUPBOX AUTORADIOBUTTON "&Retrato", rad1, 16, 170, 52, 12, BS_AUTORADIOBUTTON AUTORADIOBUTTON "&Paisagem", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON GROUPBOX "Bordas", grp4, 80, 156, 152, 56, BS_GROUPBOX @@ -735,7 +729,7 @@ STRINGTABLE DISCARDABLE IDS_PERSONAL "Meus Documentos" IDS_FAVORITES "Favoritos" IDS_PATH "Caminho do Sistema" - IDS_DESKTOP "Área de Trabalho" + IDS_DESKTOP "Área de Trabalho" IDS_FONTS "Fontes" IDS_MYCOMPUTER "Meu Computador" } @@ -748,8 +742,8 @@ STRINGTABLE DISCARDABLE IDS_DOCUMENTFOLDERS "Pastas de Documentos" IDS_PERSONAL "Os Meus Documentos" IDS_FAVORITES "Favoritos" - IDS_PATH "Localização do Sistema" - IDS_DESKTOP "Ecrã" + IDS_PATH "Localização do Sistema" + IDS_DESKTOP "Ecrã" IDS_FONTS "Tipos de Letra" IDS_MYCOMPUTER "O Meu Computador" } @@ -760,15 +754,15 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE DISCARDABLE { IDS_SYSTEMFOLDERS "Pastas do Sistema" - IDS_LOCALHARDRIVES "Discos Rígidos Locais" - IDS_FILENOTFOUND "Arquivo não encontrado" + IDS_LOCALHARDRIVES "Discos Rígidos Locais" + IDS_FILENOTFOUND "Arquivo não encontrado" IDS_VERIFYFILE "Por favor verifique se foi fornecido o nome correto do arquivo" - IDS_CREATEFILE "Arquivo não existe\nVocê gostaria de cria-lo" - IDS_OVERWRITEFILE "Arquivo já existe.\nGostaria de substituí-lo?" - IDS_INVALID_FILENAME_TITLE "Caracter(es) inválidos no caminho" - IDS_INVALID_FILENAME "Um nome de arquivo não pode conter quaisquer dos seguintes caracteres:\n / : < > |" - IDS_PATHNOTEXISTING "Caminho não existe" - IDS_FILENOTEXISTING "Arquivo não existe" + IDS_CREATEFILE "Arquivo não existe\nVocê gostaria de cria-lo" + IDS_OVERWRITEFILE "Arquivo já existe.\nGostaria de substituí-lo?" + IDS_INVALID_FILENAME_TITLE "Caracter(es) inválidos no caminho" + IDS_INVALID_FILENAME "Um nome de arquivo não pode conter quaisquer dos seguintes caracteres:\n / : < > |" + IDS_PATHNOTEXISTING "Caminho não existe" + IDS_FILENOTEXISTING "Arquivo não existe" } LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE @@ -776,15 +770,15 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE DISCARDABLE { IDS_SYSTEMFOLDERS "Pastas do Sistema" - IDS_LOCALHARDRIVES "Discos Rígidos Locais" - IDS_FILENOTFOUND "Ficheiro não encontrado" + IDS_LOCALHARDRIVES "Discos Rígidos Locais" + IDS_FILENOTFOUND "Ficheiro não encontrado" IDS_VERIFYFILE "Por favor verifique se foi fornecido o nome correcto do ficheiro" - IDS_CREATEFILE "O ficheiro não existe\nGostaria de o criar" - IDS_OVERWRITEFILE "O ficheiro já existe.\nGostaria de o substituir?" - IDS_INVALID_FILENAME_TITLE "Caracter(es) inválidos na localização" - IDS_INVALID_FILENAME "Um nome de ficheiro não pode conter quaisquer dos seguintes caracteres:\n / : < > |" - IDS_PATHNOTEXISTING "A localização não existe" - IDS_FILENOTEXISTING "O ficheiro não existe" + IDS_CREATEFILE "O ficheiro não existe\nGostaria de o criar" + IDS_OVERWRITEFILE "O ficheiro já existe.\nGostaria de o substituir?" + IDS_INVALID_FILENAME_TITLE "Caracter(es) inválidos na localização" + IDS_INVALID_FILENAME "Um nome de ficheiro não pode conter quaisquer dos seguintes caracteres:\n / : < > |" + IDS_PATHNOTEXISTING "A localização não existe" + IDS_FILENOTEXISTING "O ficheiro não existe" } @@ -792,22 +786,22 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE DISCARDABLE { - IDS_UPFOLDER "Um Nível Acima" + IDS_UPFOLDER "Um Nível Acima" IDS_NEWFOLDER "Criar Nova Pasta" IDS_LISTVIEW "Lista" IDS_REPORTVIEW "Detalhes" - IDS_TODESKTOP "Área de Trabalho" + IDS_TODESKTOP "Área de Trabalho" } LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE DISCARDABLE { - IDS_UPFOLDER "Um Nível Acima" + IDS_UPFOLDER "Um Nível Acima" IDS_NEWFOLDER "Criar Nova Pasta" IDS_LISTVIEW "Lista" IDS_REPORTVIEW "Detalhes" - IDS_TODESKTOP "Ecrã" + IDS_TODESKTOP "Ecrã" } @@ -817,26 +811,26 @@ STRINGTABLE DISCARDABLE { PD32_PRINT_TITLE "Imprimir" - PD32_VALUE_UREADABLE "Entrada Ilegível" - PD32_INVALID_PAGE_RANGE "Este valor não se encaixa na faixa de páginas\n\ + PD32_VALUE_UREADABLE "Entrada Ilegível" + PD32_INVALID_PAGE_RANGE "Este valor não se encaixa na faixa de páginas\n\ Por favor entre um valor entre %d e %d." - PD32_FROM_NOT_ABOVE_TO "A entrada DE não pode exceder ATÉ." - PD32_MARGINS_OVERLAP "As margens estão fora das medidas \ + PD32_FROM_NOT_ABOVE_TO "A entrada DE não pode exceder ATÉ." + PD32_MARGINS_OVERLAP "As margens estão fora das medidas \ do papel.\nPor favor reentre as margens." - PD32_NR_OF_COPIES_EMPTY "O número de cópias não pode ter valor vazio." - PD32_TOO_LARGE_COPIES "Esta grande quantidade de cópias não é suportada \ + PD32_NR_OF_COPIES_EMPTY "O número de cópias não pode ter valor vazio." + PD32_TOO_LARGE_COPIES "Esta grande quantidade de cópias não é suportada \ pela sua impressora.\nPor favor entre um valor entre 1 e %d." - PD32_PRINT_ERROR "Ocorreu um erro de impressão." - PD32_NO_DEFAULT_PRINTER "Não existe uma impressora padrão." - PD32_CANT_FIND_PRINTER "Não é possível encontrar uma impressora." - PD32_OUT_OF_MEMORY "Memória insuficiente." + PD32_PRINT_ERROR "Ocorreu um erro de impressão." + PD32_NO_DEFAULT_PRINTER "Não existe uma impressora padrão." + PD32_CANT_FIND_PRINTER "Não é possível encontrar uma impressora." + PD32_OUT_OF_MEMORY "Memória insuficiente." PD32_GENERIC_ERROR "Ocorreu algum erro." PD32_DRIVER_UNKNOWN "Driver de impressora desconhecido." PD32_NO_DEVICES "Before you can perform printer-related tasks \ such as page setup or printing a document, you need to install a printer. \ Please install one and retry." - PD32_DEFAULT_PRINTER "Impressora Padrão; " + PD32_DEFAULT_PRINTER "Impressora Padrão; " PD32_NR_OF_DOCUMENTS_IN_QUEUE "Existem %d documentos na fila" PD32_MARGINS_IN_INCHES "Margens [polegadas]" PD32_MARGINS_IN_MILLIMETERS "Margens [mm]" @@ -845,29 +839,29 @@ Please install one and retry." PD32_PRINTER_STATUS_READY "Pronto" PD32_PRINTER_STATUS_PAUSED "Pausada; " PD32_PRINTER_STATUS_ERROR "Erro; " - PD32_PRINTER_STATUS_PENDING_DELETION "Exclusão pendente; " + PD32_PRINTER_STATUS_PENDING_DELETION "Exclusão pendente; " PD32_PRINTER_STATUS_PAPER_JAM "Papel atolado; " PD32_PRINTER_STATUS_PAPER_OUT "Sem papel; " - PD32_PRINTER_STATUS_MANUAL_FEED "Alimentação manual; " + PD32_PRINTER_STATUS_MANUAL_FEED "Alimentação manual; " PD32_PRINTER_STATUS_PAPER_PROBLEM "Problemas com o papel; " PD32_PRINTER_STATUS_OFFLINE "Impressora desligada; " PD32_PRINTER_STATUS_IO_ACTIVE "E/S Ativa; " PD32_PRINTER_STATUS_BUSY "Ocupada; " PD32_PRINTER_STATUS_PRINTING "Imprimindo; " - PD32_PRINTER_STATUS_OUTPUT_BIN_FULL "Bandeja de saída está cheia; " - PD32_PRINTER_STATUS_NOT_AVAILABLE "Não disponível; " + PD32_PRINTER_STATUS_OUTPUT_BIN_FULL "Bandeja de saída está cheia; " + PD32_PRINTER_STATUS_NOT_AVAILABLE "Não disponível; " PD32_PRINTER_STATUS_WAITING "Esperando; " PD32_PRINTER_STATUS_PROCESSING "Processando; " PD32_PRINTER_STATUS_INITIALIZING "Inicializando; " PD32_PRINTER_STATUS_WARMING_UP "Aquecendo; " PD32_PRINTER_STATUS_TONER_LOW "Pouco toner; " PD32_PRINTER_STATUS_NO_TONER "Sem toner; " - PD32_PRINTER_STATUS_PAGE_PUNT "Lançar página; " - PD32_PRINTER_STATUS_USER_INTERVENTION "Intervenção do usuário; " - PD32_PRINTER_STATUS_OUT_OF_MEMORY "Memória insuficiente; " - PD32_PRINTER_STATUS_DOOR_OPEN "A impressora está aberta; " - PD32_PRINTER_STATUS_SERVER_UNKNOWN "Servidor de impressão desconhecido; " - PD32_PRINTER_STATUS_POWER_SAVE "Modo econômico; " + PD32_PRINTER_STATUS_PAGE_PUNT "Lançar página; " + PD32_PRINTER_STATUS_USER_INTERVENTION "Intervenção do usuário; " + PD32_PRINTER_STATUS_OUT_OF_MEMORY "Memória insuficiente; " + PD32_PRINTER_STATUS_DOOR_OPEN "A impressora está aberta; " + PD32_PRINTER_STATUS_SERVER_UNKNOWN "Servidor de impressão desconhecido; " + PD32_PRINTER_STATUS_POWER_SAVE "Modo econômico; " } LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE @@ -876,23 +870,23 @@ STRINGTABLE DISCARDABLE { PD32_PRINT_TITLE "Imprimir" - PD32_VALUE_UREADABLE "Entrada Ilegível" - PD32_INVALID_PAGE_RANGE "Este valor não se encaixa na faixa de páginas\n\ + PD32_VALUE_UREADABLE "Entrada Ilegível" + PD32_INVALID_PAGE_RANGE "Este valor não se encaixa na faixa de páginas\n\ Por favor indique um valor entre %d e %d." - PD32_FROM_NOT_ABOVE_TO "A entrada DE não pode exceder ATÉ" - PD32_MARGINS_OVERLAP "As margens estão fora das medidas \ + PD32_FROM_NOT_ABOVE_TO "A entrada DE não pode exceder ATÉ" + PD32_MARGINS_OVERLAP "As margens estão fora das medidas \ do papel.\nPor favor indique as margens." - PD32_NR_OF_COPIES_EMPTY "O número de cópias não pode ter valor vazio." - PD32_TOO_LARGE_COPIES "Esta grande quantidade de cópias não é suportada \ + PD32_NR_OF_COPIES_EMPTY "O número de cópias não pode ter valor vazio." + PD32_TOO_LARGE_COPIES "Esta grande quantidade de cópias não é suportada \ pela sua impressora.\nPor favor indique um valor entre 1 e %d." - PD32_PRINT_ERROR "Ocorreu um erro de impressão." - PD32_NO_DEFAULT_PRINTER "Não existe uma impressora predefinida." - PD32_CANT_FIND_PRINTER "Não é possível encontrar uma impressora." - PD32_OUT_OF_MEMORY "Memória insuficiente." + PD32_PRINT_ERROR "Ocorreu um erro de impressão." + PD32_NO_DEFAULT_PRINTER "Não existe uma impressora predefinida." + PD32_CANT_FIND_PRINTER "Não é possível encontrar uma impressora." + PD32_OUT_OF_MEMORY "Memória insuficiente." PD32_GENERIC_ERROR "Ocorreu algum erro." PD32_DRIVER_UNKNOWN "Controlador de impressora desconhecido." PD32_NO_DEVICES "Antes de realizar tarefas relacionadas com a impressora \ -tais como configuração de páginas ou imprimir um documento, precisa instalar uma impressora. \ +tais como configuração de páginas ou imprimir um documento, precisa instalar uma impressora. \ Por favor instale uma e tente novamente." PD32_DEFAULT_PRINTER "Impressora Predefinida; " @@ -904,40 +898,31 @@ Por favor instale uma e tente novamente." PD32_PRINTER_STATUS_READY "Pronto" PD32_PRINTER_STATUS_PAUSED "Pausada; " PD32_PRINTER_STATUS_ERROR "Erro; " - PD32_PRINTER_STATUS_PENDING_DELETION "Exclusão pendente; " + PD32_PRINTER_STATUS_PENDING_DELETION "Exclusão pendente; " PD32_PRINTER_STATUS_PAPER_JAM "Papel atolado; " PD32_PRINTER_STATUS_PAPER_OUT "Sem papel; " - PD32_PRINTER_STATUS_MANUAL_FEED "Alimentação manual; " + PD32_PRINTER_STATUS_MANUAL_FEED "Alimentação manual; " PD32_PRINTER_STATUS_PAPER_PROBLEM "Problemas com o papel; " PD32_PRINTER_STATUS_OFFLINE "Impressora desligada; " PD32_PRINTER_STATUS_IO_ACTIVE "E/S Activa; " PD32_PRINTER_STATUS_BUSY "Ocupada; " PD32_PRINTER_STATUS_PRINTING "A imprimir; " PD32_PRINTER_STATUS_OUTPUT_BIN_FULL "A bandeja de saida encontra-se cheia; " - PD32_PRINTER_STATUS_NOT_AVAILABLE "Não disponível; " + PD32_PRINTER_STATUS_NOT_AVAILABLE "Não disponível; " PD32_PRINTER_STATUS_WAITING "A esperar; " PD32_PRINTER_STATUS_PROCESSING "A processar; " PD32_PRINTER_STATUS_INITIALIZING "A inicializar; " PD32_PRINTER_STATUS_WARMING_UP "A aquecer; " PD32_PRINTER_STATUS_TONER_LOW "Pouco toner; " PD32_PRINTER_STATUS_NO_TONER "Sem toner; " - PD32_PRINTER_STATUS_PAGE_PUNT "Lançar página; " - PD32_PRINTER_STATUS_USER_INTERVENTION "Intervenção do utilizador; " - PD32_PRINTER_STATUS_OUT_OF_MEMORY "Memória insuficiente; " - PD32_PRINTER_STATUS_DOOR_OPEN "A impressora está aberta; " - PD32_PRINTER_STATUS_SERVER_UNKNOWN "Servidor de impressão desconhecido; " - PD32_PRINTER_STATUS_POWER_SAVE "Modo económico; " + PD32_PRINTER_STATUS_PAGE_PUNT "Lançar página; " + PD32_PRINTER_STATUS_USER_INTERVENTION "Intervenção do utilizador; " + PD32_PRINTER_STATUS_OUT_OF_MEMORY "Memória insuficiente; " + PD32_PRINTER_STATUS_DOOR_OPEN "A impressora está aberta; " + PD32_PRINTER_STATUS_SERVER_UNKNOWN "Servidor de impressão desconhecido; " + PD32_PRINTER_STATUS_POWER_SAVE "Modo económico; " } -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE - -STRINGTABLE DISCARDABLE /* Estilos de tipos de letra */ -{ - IDS_FONT_REGULAR "Normal" - IDS_FONT_BOLD "Negrito" - IDS_FONT_ITALIC "Itálico" - IDS_FONT_BOLD_ITALIC "Negrito Itálico" -} LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN @@ -949,14 +934,14 @@ STRINGTABLE DISCARDABLE /* Nomes de cores */ IDS_COLOR_OLIVE "Verde-oliva" IDS_COLOR_NAVY "Azul-marinho" IDS_COLOR_PURPLE "Roxo" - IDS_COLOR_TEAL "Azul-petróleo" + IDS_COLOR_TEAL "Azul-petróleo" IDS_COLOR_GRAY "Cinza" IDS_COLOR_SILVER "Prateado" IDS_COLOR_RED "Vermelho" - IDS_COLOR_LIME "Verde-limão" + IDS_COLOR_LIME "Verde-limão" IDS_COLOR_YELLOW "Amarelo" IDS_COLOR_BLUE "Azul" - IDS_COLOR_FUCHSIA "Fúcsia" + IDS_COLOR_FUCHSIA "Fúcsia" IDS_COLOR_AQUA "Azul-piscina" IDS_COLOR_WHITE "Branco" } @@ -971,7 +956,7 @@ STRINGTABLE DISCARDABLE /* Nomes de cores */ IDS_COLOR_OLIVE "Verde-oliveira" IDS_COLOR_NAVY "Azul-marinho" IDS_COLOR_PURPLE "Roxo" - IDS_COLOR_TEAL "Azul-petróleo" + IDS_COLOR_TEAL "Azul-petróleo" IDS_COLOR_GRAY "Cinza" IDS_COLOR_SILVER "Prateado" IDS_COLOR_RED "Vermelho" diff --git a/dlls/comdlg32/cdlg_Ro.rc b/dlls/comdlg32/cdlg_Ro.rc index 0c1b304c29e..45a6889d860 100644 --- a/dlls/comdlg32/cdlg_Ro.rc +++ b/dlls/comdlg32/cdlg_Ro.rc @@ -17,9 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ @@ -479,3 +476,5 @@ STRINGTABLE DISCARDABLE IDS_SAVE_AS "Salvează ca" IDS_OPEN_FILE "Deschide fișier" } + +#pragma code_page(default) diff --git a/dlls/comdlg32/cdlg_Ru.rc b/dlls/comdlg32/cdlg_Ru.rc dissimilarity index 65% index b3904cfe6d4..c5af92cb009 100644 --- a/dlls/comdlg32/cdlg_Ru.rc +++ b/dlls/comdlg32/cdlg_Ru.rc @@ -1,487 +1,481 @@ -/* - * Copyright 1999 Alexander Kanavin - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "cdlg.h" -#include "filedlgbrowser.h" - -/* - * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. - */ - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT - -OPEN_FILE DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 275, 134 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Открыть" -FONT 8, "MS Shell Dlg" -{ - LTEXT "&Имя файла:", 1090, 6, 6, 76, 9 - EDITTEXT 1152, 6, 16, 90, 12, ES_AUTOHSCROLL | ES_OEMCONVERT | WS_BORDER | WS_TABSTOP - LISTBOX 1120, 6, 32, 90, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP - LTEXT "&Каталоги:", -1, 110, 6, 92, 9 - LTEXT "", 1088, 110, 18, 92, 9, SS_NOPREFIX | WS_GROUP - LISTBOX 1121, 110, 32, 92, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP - LTEXT "Показывать файлы &типа:", 1089, 6, 104, 90, 9 - COMBOBOX 1136, 6, 114, 90, 36, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_BORDER | WS_VSCROLL | WS_TABSTOP - LTEXT "&Диски:", 1091, 110, 104, 92, 9 - COMBOBOX 1137, 110, 114, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "Открыть", IDOK, 208, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Отмена", IDCANCEL, 208, 24, 56, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Справка", 1038, 208, 46, 56, 14, WS_GROUP | WS_TABSTOP - CHECKBOX "Т&олько для чтения", 1040, 208, 68, 54, 24, BS_AUTOCHECKBOX | BS_MULTILINE | WS_GROUP | WS_TABSTOP -} - - -SAVE_FILE DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 275, 134 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Сохранить как..." -FONT 8, "MS Shell Dlg" -{ - LTEXT "&Имя файла:", 1090, 6, 6, 76, 9 - EDITTEXT 1152, 6, 16, 90, 12, ES_AUTOHSCROLL | ES_OEMCONVERT | WS_BORDER | WS_TABSTOP - LISTBOX 1120, 6, 32, 90, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP - LTEXT "&Каталоги:", -1, 110, 6, 92, 9 - LTEXT "", 1088, 110, 18, 92, 9, SS_NOPREFIX | WS_GROUP - LISTBOX 1121, 110, 32, 92, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP - LTEXT "Показывать файлы &типа:", 1089, 6, 104, 90, 9 - COMBOBOX 1136, 6, 114, 90, 36, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_BORDER | WS_VSCROLL | WS_TABSTOP - LTEXT "&Диски:", 1091, 110, 104, 92, 9 - COMBOBOX 1137, 110, 114, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "Сохранить как", IDOK, 208, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Отмена", IDCANCEL, 208, 24, 56, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Справка", 1038, 208, 46, 56, 14, WS_GROUP | WS_TABSTOP - CHECKBOX "&Только для чтения", 1040, 208, 68, 54, 24, BS_AUTOCHECKBOX | BS_MULTILINE | WS_GROUP | WS_TABSTOP -} - - -PRINT DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 264, 134 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Печать" -FONT 8, "MS Shell Dlg" -{ - LTEXT "Принтер:", 1088, 6, 6, 40, 9 - LTEXT "", 1089, 60, 6, 150, 9 - GROUPBOX "Печатать", 1072, 6, 30, 160, 65, BS_GROUPBOX - RADIOBUTTON "&Все", 1056, 16, 45, 60, 12 - RADIOBUTTON "В&ыделенный фрагмент", 1057, 16, 60, 60, 12 - RADIOBUTTON "&Страницы", 1058, 16, 75, 60, 12 - DEFPUSHBUTTON "Печать", IDOK, 206, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Отмена", IDCANCEL, 206, 24, 56, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "Сво&йства", 1024, 206, 46, 56, 14, WS_GROUP | WS_TABSTOP - LTEXT "&с:", 1090, 60, 80, 30, 9 - LTEXT "&по:", 1091, 120, 80, 30, 9 - LTEXT "&Качество печати:", 1092, 6, 100, 76, 9 - COMBOBOX 1136, 80, 100, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP - CHECKBOX "П&ечать в файл", 1040, 20, 100, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - CHECKBOX "Сжато", 1041, 160, 100, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP -} - - -PRINT_SETUP DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 264, 134 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Настройка принтера" -FONT 8, "MS Shell Dlg" -{ - GROUPBOX "Принтер", 1072, 6, 10, 180, 65, BS_GROUPBOX - RADIOBUTTON "Принтер по &умолчанию", 1056, 16, 20, 80, 12 - LTEXT "[нет]", 1088, 35, 35, 120, 9 - RADIOBUTTON "&Другой принтер", 1057, 16, 50, 80, 12 - COMBOBOX 1136, 35, 65, 149, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 206, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Отмена", IDCANCEL, 206, 24, 56, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Настройка", 1024, 206, 46, 56, 14, WS_GROUP | WS_TABSTOP - GROUPBOX "Ориентация", 1073, 6, 85, 100, 50, BS_GROUPBOX - RADIOBUTTON "&Книжная", 1058, 50, 100, 40, 12 - RADIOBUTTON "&Альбомная", 1059, 50, 115, 40, 12 - ICON "LANDSCAP", 1097, 10, 95, 32, 32 - ICON "PORTRAIT", 1098, 10, 95, 32, 32 - GROUPBOX "Бумага", 1074, 120, 85, 180, 50, BS_GROUPBOX - LTEXT "Ра&змер", 1089, 130, 95, 30, 9 - LTEXT "&Источник", 1090, 130, 110, 30, 9 - COMBOBOX 1137, 155, 95, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP - COMBOBOX 1138, 155, 110, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP -} - - -CHOOSE_FONT DIALOG DISCARDABLE 13, 54, 264, 147 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Шрифт" -FONT 8, "MS Shell Dlg" -{ - LTEXT "&Шрифт:",1088 ,6,3,40,9 - COMBOBOX 1136 ,6,13,94,54, CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | CBS_DISABLENOSCROLL | - CBS_AUTOHSCROLL | CBS_SORT | WS_VSCROLL | WS_TABSTOP | CBS_SIMPLE - LTEXT "&Начертание:",1089 ,108,3,44,9 - COMBOBOX 1137,108,13,64,54, CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | CBS_DISABLENOSCROLL | - WS_VSCROLL | WS_TABSTOP | CBS_SIMPLE - LTEXT "&Размер:",1090,179,3,30,9 - COMBOBOX 1138,179,13,32,54, CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | CBS_DISABLENOSCROLL | - WS_VSCROLL | WS_TABSTOP | CBS_SIMPLE | CBS_SORT - DEFPUSHBUTTON "OK",IDOK,218,6,40,14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON - PUSHBUTTON "Отмена",IDCANCEL,218,23,40,14,WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Применить", 1026,218,40,40,14,WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Справка" , 1038,218,57,40,14,WS_GROUP | WS_TABSTOP - GROUPBOX "Атрибуты",1072,6,72,84,34,WS_GROUP - CHECKBOX "&Зачеркнутый", 1040, 10,82,75,10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "Под&черкнутый", 1041, 10,94,75,10, BS_AUTOCHECKBOX - LTEXT "Ц&вет:", 1091 ,6,110,30,9 - COMBOBOX 1139,6,120,84,100,CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | - CBS_AUTOHSCROLL | WS_BORDER | WS_VSCROLL | WS_TABSTOP - GROUPBOX "Образец",grp2,98,72,120,36,WS_GROUP - CTEXT "АаБбAaBb",stc5,103,80,109,24,SS_NOPREFIX | NOT WS_VISIBLE - LTEXT "На&бор символов:",stc7 ,98,114,80,9 - COMBOBOX cmb5,98,124,120,90,CBS_DROPDOWNLIST | CBS_HASSTRINGS | - CBS_AUTOHSCROLL | WS_VSCROLL | WS_TABSTOP -} - - -CHOOSE_COLOR DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 310, 185 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Изменение палитры" -FONT 8, "MS Shell Dlg" -{ - LTEXT "&Базовая палитра:", 1088, 4, 4, 140, 10 - LTEXT "До&полнительные цвета:", 1089, 4, 106, 140, 10 - LTEXT "Цвет|За&ливка", 1090, 150, 151, 48, 10 - LTEXT "Крас&ный:", 726 /*1094*/,254,126,32,10 - EDITTEXT 706, 288,124,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "&Зелёный:",727/*1095*/,254,140,32,10 - EDITTEXT 707, 288,138,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "С&иний:",728 /*1096*/,264,154,24,10 - EDITTEXT 708, 288,152,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "О&ттенок:" ,723 /*1091*/,202,126,30,10 - EDITTEXT 703, 234,124,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "&Контраст:" ,724 /*1092*/,199,140,34,10 - EDITTEXT 704, 234,138,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "&Яркость:" ,725 /*1093*/,202,154,30,10 - EDITTEXT 705, 234,152,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP - CONTROL "" ,720,"STATIC",SS_SIMPLE|WS_TABSTOP|WS_GROUP,4,14,140,86 - CONTROL "" ,721,"STATIC",SS_SIMPLE|WS_TABSTOP|WS_GROUP,4,116,140,28 - CONTROL "" ,710,"STATIC",WS_BORDER|SS_SIMPLE|WS_TABSTOP|WS_GROUP, 152,4,118,116 - CONTROL "" ,702,"STATIC",SS_SIMPLE|WS_TABSTOP|WS_GROUP, 278,4,8,116 - CONTROL "" ,709,"STATIC",SS_SIMPLE|WS_TABSTOP|WS_GROUP, 152,124,40,26 - DEFPUSHBUTTON "OK", IDOK, 4, 166, 44, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Отмена", IDCANCEL, 52, 166, 44, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "Cправка", 1038,100,166, 44, 14 - PUSHBUTTON "&Добавить в набор", 712/*1024*/, 152, 166, 142, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Определить цвет >>", 719/*1025*/, 4, 150, 142, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "&i",713,300,200,4,14 /* just a dummy: 'i' is like &i in "sol&id" */ -} - - -FINDDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 245, 62 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Поиск" -FONT 8, "MS Shell Dlg" -{ - LTEXT "&Образец:", -1, 4, 8, 42, 8 - EDITTEXT 1152, 47, 7, 138, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - CHECKBOX "&Только слово целиком", 1040, 4, 26, 100, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - CHECKBOX "C &учетом регистра", 1041, 4, 42, 100, 12, BS_AUTOCHECKBOX | WS_TABSTOP - GROUPBOX "Направление", 1072, 107, 26, 78, 28 - CONTROL "&Вверх", 1056, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_GROUP | WS_TABSTOP, 111, 38, 40, 12 - CONTROL "В&низ", 1057, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 152, 38, 30, 12 - - DEFPUSHBUTTON "&Найти далее", IDOK, 190, 5, 50, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON - PUSHBUTTON "Отмена", IDCANCEL , 190, 23, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Справка", pshHelp , 190, 45, 50, 14, WS_GROUP | WS_TABSTOP -} - - -REPLACEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 230, 94 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Замена" -FONT 8, "MS Shell Dlg" -{ - LTEXT "&Образец:", -1, 4, 9, 48, 8 - EDITTEXT 1152, 54, 7, 114, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - LTEXT "З&аменить на:", -1, 4, 26, 48, 8 - EDITTEXT 1153, 54, 24, 114, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - CHECKBOX "&Только слово целиком", 1040, 5, 46, 104, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - CHECKBOX "С &учётом регистра", 1041, 5, 62, 104, 12, BS_AUTOCHECKBOX | WS_TABSTOP - - DEFPUSHBUTTON "&Найти далее", IDOK, 174, 4, 50, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON - PUSHBUTTON "&Заменить", psh1 , 174, 21, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "Заменить &все", psh2 , 174, 38, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "Отмена", IDCANCEL , 174, 55, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Справка", pshHelp , 174, 75, 50, 14, WS_GROUP | WS_TABSTOP -} - -PRINT32 DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 288, 186 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | - DS_CONTEXTHELP | DS_3DLOOK -CAPTION "Печать" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK", IDOK, 180,164, 48,14, WS_GROUP | BS_DEFPUSHBUTTON - PUSHBUTTON "Отмена", IDCANCEL, 232,164, 48,14, WS_GROUP - PUSHBUTTON "&Справка", pshHelp, 50, 161, 48,14, WS_GROUP - - GROUPBOX "Принтер", grp4, 8, 4, 272,84, WS_GROUP - CONTROL "Печать в фай&л", chx1, "Button",BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP,212,70,64,12 - PUSHBUTTON "&Свойства", psh2, 212, 17, 60,14, WS_GROUP - LTEXT "&Имя:", stc6, 16, 20, 46,8 - COMBOBOX cmb4, 64, 18, 140,152,CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP - LTEXT "Статус:", stc8, 16, 36, 46,10, SS_NOPREFIX - LTEXT "Эмулирован", stc12, 64, 36, 100,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Тип:", stc7, 16, 48, 46,10, SS_NOPREFIX - LTEXT "Эмулирован", stc11, 64, 48, 100,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Место:", stc10, 16, 60, 46,10, SS_NOPREFIX - LTEXT "Эмулировано", stc14, 64, 60, 100,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Примечание:", stc9, 16, 72, 46,10, SS_NOPREFIX - LTEXT "Эмулировано", stc13, 64, 72, 100,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - - GROUPBOX "Копии", grp2, 160, 92, 120,64, WS_GROUP - LTEXT "Число &копий:",stc5,168,108,68,8 - ICON "", ico3, 162,124, 60,24, WS_GROUP | SS_CENTERIMAGE - CONTROL "&Разбить", chx2,"Button",BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP,230,130,42,12 - EDITTEXT edt3, 230,106, 42,12, WS_GROUP | ES_NUMBER - - GROUPBOX "Печатать", grp1, 8,92, 144,64, WS_GROUP - CONTROL "&Все", rad1,"Button",BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,16,106,64,12 - CONTROL "&Страницы", rad3,"Button",BS_AUTORADIOBUTTON,16,122,50,12 - CONTROL "&Выделение", rad2,"Button",BS_AUTORADIOBUTTON,16,138,64,12 - EDITTEXT edt1, 85,122, 20,12, WS_GROUP | ES_NUMBER - EDITTEXT edt2, 120,122, 20,12, WS_GROUP | ES_NUMBER - RTEXT "&от:", stc2, 70,124, 10,8 - RTEXT "&до:", stc3, 106,124, 10,8 -} - -PRINT32_SETUP DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 288, 178 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | - DS_CONTEXTHELP | DS_3DLOOK -CAPTION "Установки принтера" -FONT 8, "MS Shell Dlg" -BEGIN - DEFPUSHBUTTON "OK",IDOK,180,156,48,14,WS_GROUP - PUSHBUTTON "Отмена",IDCANCEL,232,156,48,14 -/* PUSHBUTTON "Сеть...", psh5, 284,156,48,14 */ - - GROUPBOX "Принтер", grp4, 8, 4, 272,84, WS_GROUP - PUSHBUTTON "&Свойства", psh2, 212, 17, 60,14, WS_GROUP - LTEXT "&Имя:", stc6, 16, 20, 36,8 - COMBOBOX cmb1, 52, 18, 152,152,CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP - LTEXT "Статус:", stc8, 16, 36, 36,10, SS_NOPREFIX - LTEXT "Эмулирован", stc12, 52, 36, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Тип:", stc7, 16, 48, 36,10, SS_NOPREFIX - LTEXT "Эмулирован", stc11, 52, 48, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Место:", stc10, 16, 60, 36,10, SS_NOPREFIX - LTEXT "Эмулировано", stc14, 52, 60, 36,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - LTEXT "Заметки:", stc9, 16, 72, 36,10, SS_NOPREFIX - LTEXT "Эмулированы", stc13, 52, 72, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP - - GROUPBOX "Бумага", grp2, 8, 92, 164,56, WS_GROUP - LTEXT "Раз&мер:", stc2, 16,108, 36, 8 - COMBOBOX cmb2, 52,106, 112,112,CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP - LTEXT "&Источник:", stc3, 16,128, 36, 8 - COMBOBOX cmb3, 52,126, 112,112,CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP - - GROUPBOX "Ориентация", grp1, 180, 92, 100,56, WS_GROUP - ICON "", ico1, 195,112, 18,20, WS_GROUP - CONTROL "&Портрет", rad1,"Button",BS_AUTORADIOBUTTON | WS_GROUP |WS_TABSTOP,224,106,52,12 - CONTROL "Л&андшафт", rad2,"Button",BS_AUTORADIOBUTTON,224,126,52,12 -END - -PAGESETUPDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 240, 240 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Параметры страницы" -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "", rct1, "Static", SS_WHITERECT, 80, 8, 80, 80 - CONTROL "", rct2, "Static", SS_GRAYRECT, 160, 12, 4, 80 - CONTROL "", rct3, "Static", SS_GRAYRECT, 84, 88, 80, 4 - GROUPBOX "Бумага", grp2, 8, 96, 224, 56, BS_GROUPBOX - LTEXT "&Размер:", stc2, 16, 112, 36, 8 - COMBOBOX cmb2, 64, 110, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - LTEXT "Пода&ча:", stc3, 16, 132, 36, 8 - COMBOBOX cmb3, 64, 130, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - GROUPBOX "Ориентация", grp1, 8, 156, 64, 56, BS_GROUPBOX - AUTORADIOBUTTON "К&нижная", rad1, 16, 170, 52, 12, BS_AUTORADIOBUTTON - AUTORADIOBUTTON "Аль&бомная", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON - GROUPBOX "Поля", grp4, 80, 156, 152, 56, BS_GROUPBOX - LTEXT "&Слева:", stc15, 88, 172, 31, 8 - EDITTEXT edt4, 121, 170, 29, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "С&верху:", stc16, 159, 172, 27, 8 - EDITTEXT edt6, 187, 170, 29, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "Спр&ава:", stc17, 88, 192, 31, 8 - EDITTEXT edt5, 121, 190, 29, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "Сни&зу:", stc18, 159, 192, 23, 8 - EDITTEXT edt7, 187, 190, 29, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - DEFPUSHBUTTON "ОК", IDOK, 71, 220, 50, 14, BS_PUSHBUTTON - PUSHBUTTON "Отмена", IDCANCEL, 126, 220, 50, 14 - PUSHBUTTON "&Принтер...", psh3, 184, 220, 48, 14 -END - - -NEWFILEOPENORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 0, 0, 280, 164 -STYLE DS_MODALFRAME | DS_CONTEXTHELP | WS_VISIBLE | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_CLIPCHILDREN -CAPTION "Открыть" -FONT 8, "MS Shell Dlg" -{ - LTEXT "Искать &в",IDC_LOOKINSTATIC,4,6,43,8, SS_NOTIFY - COMBOBOX IDC_LOOKIN,49,3,132,100,CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | WS_VSCROLL | WS_TABSTOP - - LTEXT "" , IDC_TOOLBARSTATIC, 181, 2, 102, 17, NOT WS_GROUP | NOT WS_VISIBLE - LISTBOX IDC_SHELLSTATIC,4,20,272,85, LBS_SORT | LBS_NOINTEGRALHEIGHT | LBS_MULTICOLUMN | WS_HSCROLL | NOT WS_VISIBLE - - LTEXT "Имя &файла:",IDC_FILENAMESTATIC,5,112,46,8, SS_NOTIFY - EDITTEXT IDC_FILENAME,54,110,155,12,ES_AUTOHSCROLL - - LTEXT "&Тип файлов:",IDC_FILETYPESTATIC,5,128,42,8, SS_NOTIFY - COMBOBOX IDC_FILETYPE,54,126,155,53,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - - CONTROL "Только для &чтения",IDC_OPENREADONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,54,145,100,10 - - DEFPUSHBUTTON "&Открыть", IDOK,222,110,50,14 - PUSHBUTTON "Отмена", IDCANCEL,222,128,50,14 - PUSHBUTTON "&Справка", pshHelp,222,145,50,14 -} - -STRINGTABLE DISCARDABLE -{ - IDS_ABOUTBOX "&О тесте ВыборПапки" - IDS_DOCUMENTFOLDERS "Папки документов" - IDS_PERSONAL "Мои документы" - IDS_FAVORITES "Избранное" - IDS_PATH "Системный путь" - IDS_DESKTOP "Рабочий стол" - IDS_FONTS "Шрифты" - IDS_MYCOMPUTER "Мой компьютер" -} - -STRINGTABLE DISCARDABLE -{ - IDS_SYSTEMFOLDERS "Системные папки" - IDS_LOCALHARDRIVES "Локальные жесткие диски" - IDS_FILENOTFOUND "Файл не найден" - IDS_VERIFYFILE "Проверьте, правильно ли указано имя файла" - IDS_CREATEFILE "Файла не существует\nХотите ли Вы его создать?" - IDS_OVERWRITEFILE "Файл уже существует.\nЗаменить его?" - IDS_INVALID_FILENAME_TITLE "Некорректный символ в записи пути" - IDS_INVALID_FILENAME "Имя файла не может содержать следующие символы:\n / : < > |" - IDS_PATHNOTEXISTING "Путь не существует" - IDS_FILENOTEXISTING "Файл не существует" -} - -STRINGTABLE DISCARDABLE -{ - IDS_UPFOLDER "Вверх на один уровень" - IDS_NEWFOLDER "Создать новую папку" - IDS_LISTVIEW "Список" - IDS_REPORTVIEW "Подробности" - IDS_TODESKTOP "Переход на рабочий стол" -} - -STRINGTABLE DISCARDABLE -{ - PD32_PRINT_TITLE "Печать" - - PD32_VALUE_UREADABLE "Нечитаемый элемент" - PD32_INVALID_PAGE_RANGE "Это значение не лежит внутри диапазона страниц\n\ -Введите значение между %d и %d" - PD32_FROM_NOT_ABOVE_TO "Значение ОТ не должно превышать ДО:" - PD32_MARGINS_OVERLAP "Границы перекрывают или превышают \ -размеры бумаги.\nВведите их заново" - PD32_NR_OF_COPIES_EMPTY "Значение Числа Копий не может быть \ -пустым" - PD32_TOO_LARGE_COPIES "Такое большое количество копий не \ -может быть напечатано Вашим принтером.\nВведите значение между 1 и %d" - PD32_PRINT_ERROR "Произошла ошибка принтера" - PD32_NO_DEFAULT_PRINTER "Нет принтера, установленного по умолчанию" - PD32_CANT_FIND_PRINTER "Не удалось найти принтер" - PD32_OUT_OF_MEMORY "Мало памяти" - PD32_GENERIC_ERROR "Произошла(и) ошибка(и)" - PD32_DRIVER_UNKNOWN "Неизвестный драйвер принтера" - PD32_NO_DEVICES "Отсутствуют принтеры в системе. \ -Проверьте, что хотя бы один принтер установлен и система печати запущена. \ -" - - PD32_DEFAULT_PRINTER "Принтер по умолчанию; " - PD32_NR_OF_DOCUMENTS_IN_QUEUE "%d документов в очереди" - PD32_MARGINS_IN_INCHES "Границы [дюймы)" - PD32_MARGINS_IN_MILLIMETERS "Границы [мм]" - PD32_MILLIMETERS "мм" - - PD32_PRINTER_STATUS_READY "Готово" - PD32_PRINTER_STATUS_PAUSED "Приостановлено; " - PD32_PRINTER_STATUS_ERROR "Ошибка; " - PD32_PRINTER_STATUS_PENDING_DELETION "Ожидание удаления; " - PD32_PRINTER_STATUS_PAPER_JAM "Бумага застряла; " - PD32_PRINTER_STATUS_PAPER_OUT "Не хватает бумаги; " - PD32_PRINTER_STATUS_MANUAL_FEED "Вставьте бумагу вручную; " - PD32_PRINTER_STATUS_PAPER_PROBLEM "Проблема с бумагой; " - PD32_PRINTER_STATUS_OFFLINE "Принтер в режиме offline; " - PD32_PRINTER_STATUS_IO_ACTIVE "Ввод/Вывод активен; " - PD32_PRINTER_STATUS_BUSY "Занят; " - PD32_PRINTER_STATUS_PRINTING "Идет печать; " - PD32_PRINTER_STATUS_OUTPUT_BIN_FULL "Лоток переполнен бумагой; " - PD32_PRINTER_STATUS_NOT_AVAILABLE "Не доступен; " - PD32_PRINTER_STATUS_WAITING "Ожидание; " - PD32_PRINTER_STATUS_PROCESSING "Обработка; " - PD32_PRINTER_STATUS_INITIALIZING "Подготовка; " - PD32_PRINTER_STATUS_WARMING_UP "Прогрев; " - PD32_PRINTER_STATUS_TONER_LOW "Тонер на исходе; " - PD32_PRINTER_STATUS_NO_TONER "Нет тонера; " - PD32_PRINTER_STATUS_PAGE_PUNT "Page punt; " - PD32_PRINTER_STATUS_USER_INTERVENTION "Прервано пользователем; " - PD32_PRINTER_STATUS_OUT_OF_MEMORY "Мало памяти; " - PD32_PRINTER_STATUS_DOOR_OPEN "Крышка принтера открыта; " - PD32_PRINTER_STATUS_SERVER_UNKNOWN "Неизвестный сервер принтера; " - PD32_PRINTER_STATUS_POWER_SAVE "Питание в безопасном режиме; " -} - -STRINGTABLE DISCARDABLE /* Font styles */ -{ - IDS_FONT_REGULAR "Нормальный" - IDS_FONT_BOLD "Жирный" - IDS_FONT_ITALIC "Курсив" - IDS_FONT_BOLD_ITALIC "Жирный курсив" -} - -STRINGTABLE DISCARDABLE /* Color names */ -{ - IDS_COLOR_BLACK "Чёрный" - IDS_COLOR_MAROON "Тёмно-бордовый" - IDS_COLOR_GREEN "Зелёный" - IDS_COLOR_OLIVE "Оливковый" - IDS_COLOR_NAVY "Тёмно-синий" - IDS_COLOR_PURPLE "Пурпурный" - IDS_COLOR_TEAL "Морской волны" - IDS_COLOR_GRAY "Серый" - IDS_COLOR_SILVER "Серебряный" - IDS_COLOR_RED "Красный" - IDS_COLOR_LIME "Лимонный" - IDS_COLOR_YELLOW "Жёлтый" - IDS_COLOR_BLUE "Синий" - IDS_COLOR_FUCHSIA "Ярко-розовый" - IDS_COLOR_AQUA "Голубой" - IDS_COLOR_WHITE "Белый" -} - -STRINGTABLE DISCARDABLE -{ - IDS_FONT_SIZE "Выберите шрифт размером %d - %d пунктов." - IDS_SAVE_BUTTON "&Сохранить" - IDS_SAVE_IN "Сохранить &в:" - IDS_SAVE "Сохранить" - IDS_SAVE_AS "Сохранить как" - IDS_OPEN_FILE "Открыть файл" -} +/* + * Copyright 1999 Alexander Kanavin + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +/* + * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. + */ + +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT + +OPEN_FILE DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 275, 134 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Îòêðûòü" +FONT 8, "MS Shell Dlg" +{ + LTEXT "&Èìÿ ôàéëà:", 1090, 6, 6, 76, 9 + EDITTEXT 1152, 6, 16, 90, 12, ES_AUTOHSCROLL | ES_OEMCONVERT | WS_BORDER | WS_TABSTOP + LISTBOX 1120, 6, 32, 90, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP + LTEXT "&Êàòàëîãè:", -1, 110, 6, 92, 9 + LTEXT "", 1088, 110, 18, 92, 9, SS_NOPREFIX | WS_GROUP + LISTBOX 1121, 110, 32, 92, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP + LTEXT "Ïîêàçûâàòü ôàéëû &òèïà:", 1089, 6, 104, 90, 9 + COMBOBOX 1136, 6, 114, 90, 36, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_BORDER | WS_VSCROLL | WS_TABSTOP + LTEXT "&Äèñêè:", 1091, 110, 104, 92, 9 + COMBOBOX 1137, 110, 114, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP + DEFPUSHBUTTON "Îòêðûòü", IDOK, 208, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Îòìåíà", IDCANCEL, 208, 24, 56, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Ñïðàâêà", 1038, 208, 46, 56, 14, WS_GROUP | WS_TABSTOP + CHECKBOX "Ò&îëüêî äëÿ ÷òåíèÿ", 1040, 208, 68, 54, 24, BS_AUTOCHECKBOX | BS_MULTILINE | WS_GROUP | WS_TABSTOP +} + + +SAVE_FILE DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 275, 134 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Ñîõðàíèòü êàê..." +FONT 8, "MS Shell Dlg" +{ + LTEXT "&Èìÿ ôàéëà:", 1090, 6, 6, 76, 9 + EDITTEXT 1152, 6, 16, 90, 12, ES_AUTOHSCROLL | ES_OEMCONVERT | WS_BORDER | WS_TABSTOP + LISTBOX 1120, 6, 32, 90, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP + LTEXT "&Êàòàëîãè:", -1, 110, 6, 92, 9 + LTEXT "", 1088, 110, 18, 92, 9, SS_NOPREFIX | WS_GROUP + LISTBOX 1121, 110, 32, 92, 68, LBS_STANDARD | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_TABSTOP + LTEXT "Ïîêàçûâàòü ôàéëû &òèïà:", 1089, 6, 104, 90, 9 + COMBOBOX 1136, 6, 114, 90, 36, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_BORDER | WS_VSCROLL | WS_TABSTOP + LTEXT "&Äèñêè:", 1091, 110, 104, 92, 9 + COMBOBOX 1137, 110, 114, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP + DEFPUSHBUTTON "Ñîõðàíèòü êàê", IDOK, 208, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Îòìåíà", IDCANCEL, 208, 24, 56, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Ñïðàâêà", 1038, 208, 46, 56, 14, WS_GROUP | WS_TABSTOP + CHECKBOX "&Òîëüêî äëÿ ÷òåíèÿ", 1040, 208, 68, 54, 24, BS_AUTOCHECKBOX | BS_MULTILINE | WS_GROUP | WS_TABSTOP +} + + +PRINT DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 264, 134 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Ïå÷àòü" +FONT 8, "MS Shell Dlg" +{ + LTEXT "Ïðèíòåð:", 1088, 6, 6, 40, 9 + LTEXT "", 1089, 60, 6, 150, 9 + GROUPBOX "Ïå÷àòàòü", 1072, 6, 30, 160, 65, BS_GROUPBOX + RADIOBUTTON "&Âñå", 1056, 16, 45, 60, 12 + RADIOBUTTON "Â&ûäåëåííûé ôðàãìåíò", 1057, 16, 60, 60, 12 + RADIOBUTTON "&Ñòðàíèöû", 1058, 16, 75, 60, 12 + DEFPUSHBUTTON "Ïå÷àòü", IDOK, 206, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Îòìåíà", IDCANCEL, 206, 24, 56, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Ñâî&éñòâà", 1024, 206, 46, 56, 14, WS_GROUP | WS_TABSTOP + LTEXT "&ñ:", 1090, 60, 80, 30, 9 + LTEXT "&ïî:", 1091, 120, 80, 30, 9 + LTEXT "&Êà÷åñòâî ïå÷àòè:", 1092, 6, 100, 76, 9 + COMBOBOX 1136, 80, 100, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP + CHECKBOX "Ï&å÷àòü â ôàéë", 1040, 20, 100, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + CHECKBOX "Ñæàòî", 1041, 160, 100, 50, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP +} + + +PRINT_SETUP DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 264, 134 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Íàñòðîéêà ïðèíòåðà" +FONT 8, "MS Shell Dlg" +{ + GROUPBOX "Ïðèíòåð", 1072, 6, 10, 180, 65, BS_GROUPBOX + RADIOBUTTON "Ïðèíòåð ïî &óìîë÷àíèþ", 1056, 16, 20, 80, 12 + LTEXT "[íåò]", 1088, 35, 35, 120, 9 + RADIOBUTTON "&Äðóãîé ïðèíòåð", 1057, 16, 50, 80, 12 + COMBOBOX 1136, 35, 65, 149, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP + DEFPUSHBUTTON "OK", IDOK, 206, 6, 56, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Îòìåíà", IDCANCEL, 206, 24, 56, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Íàñòðîéêà", 1024, 206, 46, 56, 14, WS_GROUP | WS_TABSTOP + GROUPBOX "Îðèåíòàöèÿ", 1073, 6, 85, 100, 50, BS_GROUPBOX + RADIOBUTTON "&Êíèæíàÿ", 1058, 50, 100, 40, 12 + RADIOBUTTON "&Àëüáîìíàÿ", 1059, 50, 115, 40, 12 + ICON "LANDSCAP", 1097, 10, 95, 32, 32 + ICON "PORTRAIT", 1098, 10, 95, 32, 32 + GROUPBOX "Áóìàãà", 1074, 120, 85, 180, 50, BS_GROUPBOX + LTEXT "Ðà&çìåð", 1089, 130, 95, 30, 9 + LTEXT "&Èñòî÷íèê", 1090, 130, 110, 30, 9 + COMBOBOX 1137, 155, 95, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP + COMBOBOX 1138, 155, 110, 92, 68, CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_BORDER | WS_VSCROLL | WS_TABSTOP +} + + +CHOOSE_FONT DIALOG DISCARDABLE 13, 54, 264, 147 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Øðèôò" +FONT 8, "MS Shell Dlg" +{ + LTEXT "&Øðèôò:",1088 ,6,3,40,9 + COMBOBOX 1136 ,6,13,94,54, CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | CBS_DISABLENOSCROLL | + CBS_AUTOHSCROLL | CBS_SORT | WS_VSCROLL | WS_TABSTOP | CBS_SIMPLE + LTEXT "&Íà÷åðòàíèå:",1089 ,108,3,44,9 + COMBOBOX 1137,108,13,64,54, CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | CBS_DISABLENOSCROLL | + WS_VSCROLL | WS_TABSTOP | CBS_SIMPLE + LTEXT "&Ðàçìåð:",1090,179,3,30,9 + COMBOBOX 1138,179,13,32,54, CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | CBS_DISABLENOSCROLL | + WS_VSCROLL | WS_TABSTOP | CBS_SIMPLE | CBS_SORT + DEFPUSHBUTTON "OK",IDOK,218,6,40,14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON + PUSHBUTTON "Îòìåíà",IDCANCEL,218,23,40,14,WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Ïðèìåíèòü", 1026,218,40,40,14,WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Ñïðàâêà" , 1038,218,57,40,14,WS_GROUP | WS_TABSTOP + GROUPBOX "Àòðèáóòû",1072,6,72,84,34,WS_GROUP + CHECKBOX "&Çà÷åðêíóòûé", 1040, 10,82,75,10, BS_AUTOCHECKBOX | WS_TABSTOP + CHECKBOX "Ïîä&÷åðêíóòûé", 1041, 10,94,75,10, BS_AUTOCHECKBOX + LTEXT "Ö&âåò:", 1091 ,6,110,30,9 + COMBOBOX 1139,6,120,84,100,CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | + CBS_AUTOHSCROLL | WS_BORDER | WS_VSCROLL | WS_TABSTOP + GROUPBOX "Îáðàçåö",grp2,98,72,120,36,WS_GROUP + CTEXT "ÀàÁáAaBb",stc5,103,80,109,24,SS_NOPREFIX | NOT WS_VISIBLE + LTEXT "Íà&áîð ñèìâîëîâ:",stc7 ,98,114,80,9 + COMBOBOX cmb5,98,124,120,90,CBS_DROPDOWNLIST | CBS_HASSTRINGS | + CBS_AUTOHSCROLL | WS_VSCROLL | WS_TABSTOP +} + + +CHOOSE_COLOR DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 310, 185 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Èçìåíåíèå ïàëèòðû" +FONT 8, "MS Shell Dlg" +{ + LTEXT "&Áàçîâàÿ ïàëèòðà:", 1088, 4, 4, 140, 10 + LTEXT "Äî&ïîëíèòåëüíûå öâåòà:", 1089, 4, 106, 140, 10 + LTEXT "Öâåò|Çà&ëèâêà", 1090, 150, 151, 48, 10 + LTEXT "Êðàñ&íûé:", 726 /*1094*/,254,126,32,10 + EDITTEXT 706, 288,124,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP + LTEXT "&Çåë¸íûé:",727/*1095*/,254,140,32,10 + EDITTEXT 707, 288,138,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP + LTEXT "Ñ&èíèé:",728 /*1096*/,264,154,24,10 + EDITTEXT 708, 288,152,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP + LTEXT "Î&òòåíîê:" ,723 /*1091*/,202,126,30,10 + EDITTEXT 703, 234,124,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP + LTEXT "&Êîíòðàñò:" ,724 /*1092*/,199,140,34,10 + EDITTEXT 704, 234,138,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP + LTEXT "&ßðêîñòü:" ,725 /*1093*/,202,154,30,10 + EDITTEXT 705, 234,152,21,12, WS_BORDER | WS_GROUP | WS_TABSTOP + CONTROL "" ,720,"STATIC",SS_SIMPLE|WS_TABSTOP|WS_GROUP,4,14,140,86 + CONTROL "" ,721,"STATIC",SS_SIMPLE|WS_TABSTOP|WS_GROUP,4,116,140,28 + CONTROL "" ,710,"STATIC",WS_BORDER|SS_SIMPLE|WS_TABSTOP|WS_GROUP, 152,4,118,116 + CONTROL "" ,702,"STATIC",SS_SIMPLE|WS_TABSTOP|WS_GROUP, 278,4,8,116 + CONTROL "" ,709,"STATIC",SS_SIMPLE|WS_TABSTOP|WS_GROUP, 152,124,40,26 + DEFPUSHBUTTON "OK", IDOK, 4, 166, 44, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Îòìåíà", IDCANCEL, 52, 166, 44, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Cïðàâêà", 1038,100,166, 44, 14 + PUSHBUTTON "&Äîáàâèòü â íàáîð", 712/*1024*/, 152, 166, 142, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Îïðåäåëèòü öâåò >>", 719/*1025*/, 4, 150, 142, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&i",713,300,200,4,14 /* just a dummy: 'i' is like &i in "sol&id" */ +} + + +FINDDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 245, 62 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Ïîèñê" +FONT 8, "MS Shell Dlg" +{ + LTEXT "&Îáðàçåö:", -1, 4, 8, 42, 8 + EDITTEXT 1152, 47, 7, 138, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP + CHECKBOX "&Òîëüêî ñëîâî öåëèêîì", 1040, 4, 26, 100, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + CHECKBOX "C &ó÷åòîì ðåãèñòðà", 1041, 4, 42, 100, 12, BS_AUTOCHECKBOX | WS_TABSTOP + GROUPBOX "Íàïðàâëåíèå", 1072, 107, 26, 78, 28 + CONTROL "&Ââåðõ", 1056, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_GROUP | WS_TABSTOP, 111, 38, 40, 12 + CONTROL "Â&íèç", 1057, "BUTTON", BS_AUTORADIOBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 152, 38, 30, 12 + + DEFPUSHBUTTON "&Íàéòè äàëåå", IDOK, 190, 5, 50, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON + PUSHBUTTON "Îòìåíà", IDCANCEL , 190, 23, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Ñïðàâêà", pshHelp , 190, 45, 50, 14, WS_GROUP | WS_TABSTOP +} + + +REPLACEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 230, 94 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Çàìåíà" +FONT 8, "MS Shell Dlg" +{ + LTEXT "&Îáðàçåö:", -1, 4, 9, 48, 8 + EDITTEXT 1152, 54, 7, 114, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP + LTEXT "Ç&àìåíèòü íà:", -1, 4, 26, 48, 8 + EDITTEXT 1153, 54, 24, 114, 12, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP + CHECKBOX "&Òîëüêî ñëîâî öåëèêîì", 1040, 5, 46, 104, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + CHECKBOX "Ñ &ó÷¸òîì ðåãèñòðà", 1041, 5, 62, 104, 12, BS_AUTOCHECKBOX | WS_TABSTOP + + DEFPUSHBUTTON "&Íàéòè äàëåå", IDOK, 174, 4, 50, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON + PUSHBUTTON "&Çàìåíèòü", psh1 , 174, 21, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Çàìåíèòü &âñå", psh2 , 174, 38, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Îòìåíà", IDCANCEL , 174, 55, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Ñïðàâêà", pshHelp , 174, 75, 50, 14, WS_GROUP | WS_TABSTOP +} + +PRINT32 DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 288, 186 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | + DS_CONTEXTHELP | DS_3DLOOK +CAPTION "Ïå÷àòü" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK", IDOK, 180,164, 48,14, WS_GROUP | BS_DEFPUSHBUTTON + PUSHBUTTON "Îòìåíà", IDCANCEL, 232,164, 48,14, WS_GROUP + PUSHBUTTON "&Ñïðàâêà", pshHelp, 50, 161, 48,14, WS_GROUP + + GROUPBOX "Ïðèíòåð", grp4, 8, 4, 272,84, WS_GROUP + CONTROL "Ïå÷àòü â ôàé&ë", chx1, "Button",BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP,212,70,64,12 + PUSHBUTTON "&Ñâîéñòâà", psh2, 212, 17, 60,14, WS_GROUP + LTEXT "&Èìÿ:", stc6, 16, 20, 46,8 + COMBOBOX cmb4, 64, 18, 140,152,CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP + LTEXT "Ñòàòóñ:", stc8, 16, 36, 46,10, SS_NOPREFIX + LTEXT "Ýìóëèðîâàí", stc12, 64, 36, 100,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Òèï:", stc7, 16, 48, 46,10, SS_NOPREFIX + LTEXT "Ýìóëèðîâàí", stc11, 64, 48, 100,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Ìåñòî:", stc10, 16, 60, 46,10, SS_NOPREFIX + LTEXT "Ýìóëèðîâàíî", stc14, 64, 60, 100,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Ïðèìå÷àíèå:", stc9, 16, 72, 46,10, SS_NOPREFIX + LTEXT "Ýìóëèðîâàíî", stc13, 64, 72, 100,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + + GROUPBOX "Êîïèè", grp2, 160, 92, 120,64, WS_GROUP + LTEXT "×èñëî &êîïèé:",stc5,168,108,68,8 + ICON "", ico3, 162,124, 60,24, WS_GROUP | SS_CENTERIMAGE + CONTROL "&Ðàçáèòü", chx2,"Button",BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP,230,130,42,12 + EDITTEXT edt3, 230,106, 42,12, WS_GROUP | ES_NUMBER + + GROUPBOX "Ïå÷àòàòü", grp1, 8,92, 144,64, WS_GROUP + CONTROL "&Âñå", rad1,"Button",BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,16,106,64,12 + CONTROL "&Ñòðàíèöû", rad3,"Button",BS_AUTORADIOBUTTON,16,122,50,12 + CONTROL "&Âûäåëåíèå", rad2,"Button",BS_AUTORADIOBUTTON,16,138,64,12 + EDITTEXT edt1, 85,122, 20,12, WS_GROUP | ES_NUMBER + EDITTEXT edt2, 120,122, 20,12, WS_GROUP | ES_NUMBER + RTEXT "&îò:", stc2, 70,124, 10,8 + RTEXT "&äî:", stc3, 106,124, 10,8 +} + +PRINT32_SETUP DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 288, 178 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | + DS_CONTEXTHELP | DS_3DLOOK +CAPTION "Óñòàíîâêè ïðèíòåðà" +FONT 8, "MS Shell Dlg" +BEGIN + DEFPUSHBUTTON "OK",IDOK,180,156,48,14,WS_GROUP + PUSHBUTTON "Îòìåíà",IDCANCEL,232,156,48,14 +/* PUSHBUTTON "Ñåòü...", psh5, 284,156,48,14 */ + + GROUPBOX "Ïðèíòåð", grp4, 8, 4, 272,84, WS_GROUP + PUSHBUTTON "&Ñâîéñòâà", psh2, 212, 17, 60,14, WS_GROUP + LTEXT "&Èìÿ:", stc6, 16, 20, 36,8 + COMBOBOX cmb1, 52, 18, 152,152,CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP + LTEXT "Ñòàòóñ:", stc8, 16, 36, 36,10, SS_NOPREFIX + LTEXT "Ýìóëèðîâàí", stc12, 52, 36, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Òèï:", stc7, 16, 48, 36,10, SS_NOPREFIX + LTEXT "Ýìóëèðîâàí", stc11, 52, 48, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Ìåñòî:", stc10, 16, 60, 36,10, SS_NOPREFIX + LTEXT "Ýìóëèðîâàíî", stc14, 52, 60, 36,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + LTEXT "Çàìåòêè:", stc9, 16, 72, 36,10, SS_NOPREFIX + LTEXT "Ýìóëèðîâàíû", stc13, 52, 72, 224,10, SS_NOPREFIX | SS_LEFTNOWORDWRAP + + GROUPBOX "Áóìàãà", grp2, 8, 92, 164,56, WS_GROUP + LTEXT "Ðàç&ìåð:", stc2, 16,108, 36, 8 + COMBOBOX cmb2, 52,106, 112,112,CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP + LTEXT "&Èñòî÷íèê:", stc3, 16,128, 36, 8 + COMBOBOX cmb3, 52,126, 112,112,CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_GROUP | WS_TABSTOP + + GROUPBOX "Îðèåíòàöèÿ", grp1, 180, 92, 100,56, WS_GROUP + ICON "", ico1, 195,112, 18,20, WS_GROUP + CONTROL "&Ïîðòðåò", rad1,"Button",BS_AUTORADIOBUTTON | WS_GROUP |WS_TABSTOP,224,106,52,12 + CONTROL "Ë&àíäøàôò", rad2,"Button",BS_AUTORADIOBUTTON,224,126,52,12 +END + +PAGESETUPDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 240, 240 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Ïàðàìåòðû ñòðàíèöû" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL "", rct1, "Static", SS_WHITERECT, 80, 8, 80, 80 + CONTROL "", rct2, "Static", SS_GRAYRECT, 160, 12, 4, 80 + CONTROL "", rct3, "Static", SS_GRAYRECT, 84, 88, 80, 4 + GROUPBOX "Áóìàãà", grp2, 8, 96, 224, 56, BS_GROUPBOX + LTEXT "&Ðàçìåð:", stc2, 16, 112, 36, 8 + COMBOBOX cmb2, 64, 110, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL + LTEXT "Ïîäà&÷à:", stc3, 16, 132, 36, 8 + COMBOBOX cmb3, 64, 130, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL + GROUPBOX "Îðèåíòàöèÿ", grp1, 8, 156, 64, 56, BS_GROUPBOX + AUTORADIOBUTTON "Ê&íèæíàÿ", rad1, 16, 170, 52, 12, BS_AUTORADIOBUTTON + AUTORADIOBUTTON "Àëü&áîìíàÿ", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON + GROUPBOX "Ïîëÿ", grp4, 80, 156, 152, 56, BS_GROUPBOX + LTEXT "&Ñëåâà:", stc15, 88, 172, 31, 8 + EDITTEXT edt4, 121, 170, 29, 12, WS_TABSTOP|WS_GROUP|WS_BORDER + LTEXT "Ñ&âåðõó:", stc16, 159, 172, 27, 8 + EDITTEXT edt6, 187, 170, 29, 12, WS_TABSTOP|WS_GROUP|WS_BORDER + LTEXT "Ñïð&àâà:", stc17, 88, 192, 31, 8 + EDITTEXT edt5, 121, 190, 29, 12, WS_TABSTOP|WS_GROUP|WS_BORDER + LTEXT "Ñíè&çó:", stc18, 159, 192, 23, 8 + EDITTEXT edt7, 187, 190, 29, 12, WS_TABSTOP|WS_GROUP|WS_BORDER + DEFPUSHBUTTON "ÎÊ", IDOK, 71, 220, 50, 14, BS_PUSHBUTTON + PUSHBUTTON "Îòìåíà", IDCANCEL, 126, 220, 50, 14 + PUSHBUTTON "&Ïðèíòåð...", psh3, 184, 220, 48, 14 +END + + +NEWFILEOPENORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 0, 0, 280, 164 +STYLE DS_MODALFRAME | DS_CONTEXTHELP | WS_VISIBLE | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_CLIPCHILDREN +CAPTION "Îòêðûòü" +FONT 8, "MS Shell Dlg" +{ + LTEXT "Èñêàòü &â",IDC_LOOKINSTATIC,4,6,43,8, SS_NOTIFY + COMBOBOX IDC_LOOKIN,49,3,132,100,CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | WS_VSCROLL | WS_TABSTOP + + LTEXT "" , IDC_TOOLBARSTATIC, 181, 2, 102, 17, NOT WS_GROUP | NOT WS_VISIBLE + LISTBOX IDC_SHELLSTATIC,4,20,272,85, LBS_SORT | LBS_NOINTEGRALHEIGHT | LBS_MULTICOLUMN | WS_HSCROLL | NOT WS_VISIBLE + + LTEXT "Èìÿ &ôàéëà:",IDC_FILENAMESTATIC,5,112,46,8, SS_NOTIFY + EDITTEXT IDC_FILENAME,54,110,155,12,ES_AUTOHSCROLL + + LTEXT "&Òèï ôàéëîâ:",IDC_FILETYPESTATIC,5,128,42,8, SS_NOTIFY + COMBOBOX IDC_FILETYPE,54,126,155,53,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + + CONTROL "Òîëüêî äëÿ &÷òåíèÿ",IDC_OPENREADONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,54,145,100,10 + + DEFPUSHBUTTON "&Îòêðûòü", IDOK,222,110,50,14 + PUSHBUTTON "Îòìåíà", IDCANCEL,222,128,50,14 + PUSHBUTTON "&Ñïðàâêà", pshHelp,222,145,50,14 +} + +STRINGTABLE DISCARDABLE +{ + IDS_ABOUTBOX "&Î òåñòå ÂûáîðÏàïêè" + IDS_DOCUMENTFOLDERS "Ïàïêè äîêóìåíòîâ" + IDS_PERSONAL "Ìîè äîêóìåíòû" + IDS_FAVORITES "Èçáðàííîå" + IDS_PATH "Ñèñòåìíûé ïóòü" + IDS_DESKTOP "Ðàáî÷èé ñòîë" + IDS_FONTS "Øðèôòû" + IDS_MYCOMPUTER "Ìîé êîìïüþòåð" +} + +STRINGTABLE DISCARDABLE +{ + IDS_SYSTEMFOLDERS "Ñèñòåìíûå ïàïêè" + IDS_LOCALHARDRIVES "Ëîêàëüíûå æåñòêèå äèñêè" + IDS_FILENOTFOUND "Ôàéë íå íàéäåí" + IDS_VERIFYFILE "Ïðîâåðüòå, ïðàâèëüíî ëè óêàçàíî èìÿ ôàéëà" + IDS_CREATEFILE "Ôàéëà íå ñóùåñòâóåò\nÕîòèòå ëè Âû åãî ñîçäàòü?" + IDS_OVERWRITEFILE "Ôàéë óæå ñóùåñòâóåò.\nÇàìåíèòü åãî?" + IDS_INVALID_FILENAME_TITLE "Íåêîððåêòíûé ñèìâîë â çàïèñè ïóòè" + IDS_INVALID_FILENAME "Èìÿ ôàéëà íå ìîæåò ñîäåðæàòü ñëåäóþùèå ñèìâîëû:\n / : < > |" + IDS_PATHNOTEXISTING "Ïóòü íå ñóùåñòâóåò" + IDS_FILENOTEXISTING "Ôàéë íå ñóùåñòâóåò" +} + +STRINGTABLE DISCARDABLE +{ + IDS_UPFOLDER "Ââåðõ íà îäèí óðîâåíü" + IDS_NEWFOLDER "Ñîçäàòü íîâóþ ïàïêó" + IDS_LISTVIEW "Ñïèñîê" + IDS_REPORTVIEW "Ïîäðîáíîñòè" + IDS_TODESKTOP "Ïåðåõîä íà ðàáî÷èé ñòîë" +} + +STRINGTABLE DISCARDABLE +{ + PD32_PRINT_TITLE "Ïå÷àòü" + + PD32_VALUE_UREADABLE "Íå÷èòàåìûé ýëåìåíò" + PD32_INVALID_PAGE_RANGE "Ýòî çíà÷åíèå íå ëåæèò âíóòðè äèàïàçîíà ñòðàíèö\n\ +Ââåäèòå çíà÷åíèå ìåæäó %d è %d" + PD32_FROM_NOT_ABOVE_TO "Çíà÷åíèå ÎÒ íå äîëæíî ïðåâûøàòü ÄÎ:" + PD32_MARGINS_OVERLAP "Ãðàíèöû ïåðåêðûâàþò èëè ïðåâûøàþò \ +ðàçìåðû áóìàãè.\nÂâåäèòå èõ çàíîâî" + PD32_NR_OF_COPIES_EMPTY "Çíà÷åíèå ×èñëà Êîïèé íå ìîæåò áûòü \ +ïóñòûì" + PD32_TOO_LARGE_COPIES "Òàêîå áîëüøîå êîëè÷åñòâî êîïèé íå \ +ìîæåò áûòü íàïå÷àòàíî Âàøèì ïðèíòåðîì.\nÂâåäèòå çíà÷åíèå ìåæäó 1 è %d" + PD32_PRINT_ERROR "Ïðîèçîøëà îøèáêà ïðèíòåðà" + PD32_NO_DEFAULT_PRINTER "Íåò ïðèíòåðà, óñòàíîâëåííîãî ïî óìîë÷àíèþ" + PD32_CANT_FIND_PRINTER "Íå óäàëîñü íàéòè ïðèíòåð" + PD32_OUT_OF_MEMORY "Ìàëî ïàìÿòè" + PD32_GENERIC_ERROR "Ïðîèçîøëà(è) îøèáêà(è)" + PD32_DRIVER_UNKNOWN "Íåèçâåñòíûé äðàéâåð ïðèíòåðà" + PD32_NO_DEVICES "Îòñóòñòâóþò ïðèíòåðû â ñèñòåìå. \ +Ïðîâåðüòå, ÷òî õîòÿ áû îäèí ïðèíòåð óñòàíîâëåí è ñèñòåìà ïå÷àòè çàïóùåíà. \ +" + + PD32_DEFAULT_PRINTER "Ïðèíòåð ïî óìîë÷àíèþ; " + PD32_NR_OF_DOCUMENTS_IN_QUEUE "%d äîêóìåíòîâ â î÷åðåäè" + PD32_MARGINS_IN_INCHES "Ãðàíèöû [äþéìû)" + PD32_MARGINS_IN_MILLIMETERS "Ãðàíèöû [ìì]" + PD32_MILLIMETERS "ìì" + + PD32_PRINTER_STATUS_READY "Ãîòîâî" + PD32_PRINTER_STATUS_PAUSED "Ïðèîñòàíîâëåíî; " + PD32_PRINTER_STATUS_ERROR "Îøèáêà; " + PD32_PRINTER_STATUS_PENDING_DELETION "Îæèäàíèå óäàëåíèÿ; " + PD32_PRINTER_STATUS_PAPER_JAM "Áóìàãà çàñòðÿëà; " + PD32_PRINTER_STATUS_PAPER_OUT "Íå õâàòàåò áóìàãè; " + PD32_PRINTER_STATUS_MANUAL_FEED "Âñòàâüòå áóìàãó âðó÷íóþ; " + PD32_PRINTER_STATUS_PAPER_PROBLEM "Ïðîáëåìà ñ áóìàãîé; " + PD32_PRINTER_STATUS_OFFLINE "Ïðèíòåð â ðåæèìå offline; " + PD32_PRINTER_STATUS_IO_ACTIVE "Ââîä/Âûâîä àêòèâåí; " + PD32_PRINTER_STATUS_BUSY "Çàíÿò; " + PD32_PRINTER_STATUS_PRINTING "Èäåò ïå÷àòü; " + PD32_PRINTER_STATUS_OUTPUT_BIN_FULL "Ëîòîê ïåðåïîëíåí áóìàãîé; " + PD32_PRINTER_STATUS_NOT_AVAILABLE "Íå äîñòóïåí; " + PD32_PRINTER_STATUS_WAITING "Îæèäàíèå; " + PD32_PRINTER_STATUS_PROCESSING "Îáðàáîòêà; " + PD32_PRINTER_STATUS_INITIALIZING "Ïîäãîòîâêà; " + PD32_PRINTER_STATUS_WARMING_UP "Ïðîãðåâ; " + PD32_PRINTER_STATUS_TONER_LOW "Òîíåð íà èñõîäå; " + PD32_PRINTER_STATUS_NO_TONER "Íåò òîíåðà; " + PD32_PRINTER_STATUS_PAGE_PUNT "Page punt; " + PD32_PRINTER_STATUS_USER_INTERVENTION "Ïðåðâàíî ïîëüçîâàòåëåì; " + PD32_PRINTER_STATUS_OUT_OF_MEMORY "Ìàëî ïàìÿòè; " + PD32_PRINTER_STATUS_DOOR_OPEN "Êðûøêà ïðèíòåðà îòêðûòà; " + PD32_PRINTER_STATUS_SERVER_UNKNOWN "Íåèçâåñòíûé ñåðâåð ïðèíòåðà; " + PD32_PRINTER_STATUS_POWER_SAVE "Ïèòàíèå â áåçîïàñíîì ðåæèìå; " +} + +STRINGTABLE DISCARDABLE /* Font styles */ +{ + IDS_FONT_REGULAR "Íîðìàëüíûé" + IDS_FONT_BOLD "Æèðíûé" + IDS_FONT_ITALIC "Êóðñèâ" + IDS_FONT_BOLD_ITALIC "Æèðíûé êóðñèâ" +} + +STRINGTABLE DISCARDABLE /* Color names */ +{ + IDS_COLOR_BLACK "׸ðíûé" + IDS_COLOR_MAROON "Ò¸ìíî-áîðäîâûé" + IDS_COLOR_GREEN "Çåë¸íûé" + IDS_COLOR_OLIVE "Îëèâêîâûé" + IDS_COLOR_NAVY "Ò¸ìíî-ñèíèé" + IDS_COLOR_PURPLE "Ïóðïóðíûé" + IDS_COLOR_TEAL "Ìîðñêîé âîëíû" + IDS_COLOR_GRAY "Ñåðûé" + IDS_COLOR_SILVER "Ñåðåáðÿíûé" + IDS_COLOR_RED "Êðàñíûé" + IDS_COLOR_LIME "Ëèìîííûé" + IDS_COLOR_YELLOW "Ƹëòûé" + IDS_COLOR_BLUE "Ñèíèé" + IDS_COLOR_FUCHSIA "ßðêî-ðîçîâûé" + IDS_COLOR_AQUA "Ãîëóáîé" + IDS_COLOR_WHITE "Áåëûé" +} + +STRINGTABLE DISCARDABLE +{ + IDS_FONT_SIZE "Âûáåðèòå øðèôò ðàçìåðîì %d - %d ïóíêòîâ." + IDS_SAVE_BUTTON "&Ñîõðàíèòü" + IDS_SAVE_IN "Ñîõðàíèòü &â:" + IDS_SAVE "Ñîõðàíèòü" + IDS_SAVE_AS "Ñîõðàíèòü êàê" + IDS_OPEN_FILE "Îòêðûòü ôàéë" +} diff --git a/dlls/comdlg32/cdlg_Si.rc b/dlls/comdlg32/cdlg_Si.rc index e3d37e93055..0650f535920 100644 --- a/dlls/comdlg32/cdlg_Si.rc +++ b/dlls/comdlg32/cdlg_Si.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ @@ -484,3 +481,5 @@ STRINGTABLE DISCARDABLE IDS_SAVE_AS "Shrani kot" IDS_OPEN_FILE "Odpri datoteko" } + +#pragma code_page(default) diff --git a/dlls/comdlg32/cdlg_Sk.rc b/dlls/comdlg32/cdlg_Sk.rc index 4a2ef2745aa..7fbc5a9c66e 100644 --- a/dlls/comdlg32/cdlg_Sk.rc +++ b/dlls/comdlg32/cdlg_Sk.rc @@ -17,9 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Sv.rc b/dlls/comdlg32/cdlg_Sv.rc index 21d2ac2c1fe..ed763b481fa 100644 --- a/dlls/comdlg32/cdlg_Sv.rc +++ b/dlls/comdlg32/cdlg_Sv.rc @@ -17,9 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Th.rc b/dlls/comdlg32/cdlg_Th.rc index 34ef5200ece..2e7131fd90d 100644 --- a/dlls/comdlg32/cdlg_Th.rc +++ b/dlls/comdlg32/cdlg_Th.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Tr.rc b/dlls/comdlg32/cdlg_Tr.rc index 52e71ba52b8..ba95000e53a 100644 --- a/dlls/comdlg32/cdlg_Tr.rc +++ b/dlls/comdlg32/cdlg_Tr.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Uk.rc b/dlls/comdlg32/cdlg_Uk.rc index 730d610e4bf..bb23fe93742 100644 --- a/dlls/comdlg32/cdlg_Uk.rc +++ b/dlls/comdlg32/cdlg_Uk.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Wa.rc b/dlls/comdlg32/cdlg_Wa.rc index ea7e23484ec..7eaf41731c3 100644 --- a/dlls/comdlg32/cdlg_Wa.rc +++ b/dlls/comdlg32/cdlg_Wa.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ diff --git a/dlls/comdlg32/cdlg_Zh.rc b/dlls/comdlg32/cdlg_Zh.rc index fee8bda01d5..d17896edc76 100644 --- a/dlls/comdlg32/cdlg_Zh.rc +++ b/dlls/comdlg32/cdlg_Zh.rc @@ -20,9 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" -#include "filedlgbrowser.h" - /* * WARNING: DO NOT CHANGE THE SIZE OF THE STANDARD DIALOG TEMPLATES. */ @@ -712,3 +709,5 @@ STRINGTABLE DISCARDABLE PD32_PRINTER_STATUS_SERVER_UNKNOWN "找不到列印服務器; " PD32_PRINTER_STATUS_POWER_SAVE "省電狀態; " } + +#pragma code_page(default) diff --git a/dlls/comdlg32/cdlg_xx.rc b/dlls/comdlg32/cdlg_xx.rc index 07978971c4f..dcc3ef328db 100644 --- a/dlls/comdlg32/cdlg_xx.rc +++ b/dlls/comdlg32/cdlg_xx.rc @@ -19,7 +19,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cdlg.h" +#include "windef.h" +#include "winbase.h" +#include "winver.h" LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL diff --git a/dlls/comdlg32/filedlg.c b/dlls/comdlg32/filedlg.c index 041d75c2831..6e7f985dbc9 100644 --- a/dlls/comdlg32/filedlg.c +++ b/dlls/comdlg32/filedlg.c @@ -172,7 +172,6 @@ typedef struct tagFD32_PRIVATE const char FileOpenDlgInfosStr[] = "FileOpenDlgInfos"; /* windows property description string */ static const char LookInInfosStr[] = "LookInInfos"; /* LOOKIN combo box property */ -static SIZE MemDialogSize = { 0, 0}; /* keep size of the (resizable) dialog */ /*********************************************************************** * Prototypes @@ -790,7 +789,11 @@ static HWND CreateTemplateDialog(FileOpenDlgInfos *fodInfos, HWND hwnd) hChildDlg = CreateDialogIndirectParamA(hinst, template, hwnd, IsHooked(fodInfos) ? (DLGPROC)fodInfos->ofnInfos->lpfnHook : FileOpenDlgProcUserTemplate, (LPARAM)fodInfos->ofnInfos); - return hChildDlg; + if(hChildDlg) + { + ShowWindow(hChildDlg,SW_SHOW); + return hChildDlg; + } } else if( IsHooked(fodInfos)) { @@ -1020,8 +1023,6 @@ static LRESULT FILEDLG95_OnWMSize(HWND hwnd, WPARAM wParam, LPARAM lParam) if( !(fodInfos->ofnInfos->Flags & OFN_ENABLESIZING)) return FALSE; /* get the new dialog rectangle */ GetWindowRect( hwnd, &rc); - TRACE("Size from %d,%d to %d,%d\n", fodInfos->sizedlg.cx, fodInfos->sizedlg.cy, - rc.right -rc.left, rc.bottom -rc.top); /* not initialized yet */ if( (fodInfos->sizedlg.cx == 0 && fodInfos->sizedlg.cy == 0) || ((fodInfos->sizedlg.cx == rc.right -rc.left) && /* no change */ @@ -1042,7 +1043,6 @@ static LRESULT FILEDLG95_OnWMSize(HWND hwnd, WPARAM wParam, LPARAM lParam) /* change position and sizes of the controls */ for( ctrl = GetWindow( hwnd, GW_CHILD); ctrl ; ctrl = GetWindow( ctrl, GW_HWNDNEXT)) { - int ctrlid = GetDlgCtrlID( ctrl); GetWindowRect( ctrl, &rc); MapWindowPoints( NULL, hwnd, (LPPOINT) &rc, 2); if( ctrl == fodInfos->DlgInfos.hwndGrip) @@ -1055,69 +1055,25 @@ static LRESULT FILEDLG95_OnWMSize(HWND hwnd, WPARAM wParam, LPARAM lParam) { /* if it was below the shell view * move to bottom */ - switch( ctrlid) - { - /* file name box and file types combo change also width */ - case edt1: - case cmb1: - DeferWindowPos( hdwp, ctrl, NULL, rc.left, rc.top + chgy, - rc.right - rc.left + chgx, rc.bottom - rc.top, - SWP_NOACTIVATE | SWP_NOZORDER); - break; - /* then these buttons must move out of the way */ - case IDOK: - case IDCANCEL: - case pshHelp: - DeferWindowPos( hdwp, ctrl, NULL, rc.left + chgx, rc.top + chgy, - 0, 0, - SWP_NOSIZE | SWP_NOACTIVATE | SWP_NOZORDER); - break; - default: - DeferWindowPos( hdwp, ctrl, NULL, rc.left, rc.top + chgy, - 0, 0, - SWP_NOSIZE | SWP_NOACTIVATE | SWP_NOZORDER); - } + DeferWindowPos( hdwp, ctrl, NULL, rc.left, rc.top + chgy, + rc.right - rc.left, rc.bottom - rc.top, + SWP_NOSIZE | SWP_NOACTIVATE | SWP_NOZORDER); } else if( rc.left > rcview.right) { /* if it was to the right of the shell view * move to right */ DeferWindowPos( hdwp, ctrl, NULL, rc.left + chgx, rc.top, - 0, 0, + rc.right - rc.left, rc.bottom - rc.top, SWP_NOSIZE | SWP_NOACTIVATE | SWP_NOZORDER); } - else - /* special cases */ - { - switch( ctrlid) - { -#if 0 /* this is Win2k, Win XP. Vista and Higher don't move/size these controls */ - case IDC_LOOKIN: - DeferWindowPos( hdwp, ctrl, NULL, 0, 0, - rc.right - rc.left + chgx, rc.bottom - rc.top, - SWP_NOMOVE | SWP_NOACTIVATE | SWP_NOZORDER); - break; - case IDC_TOOLBARSTATIC: - case IDC_TOOLBAR: - DeferWindowPos( hdwp, ctrl, NULL, rc.left + chgx, rc.top, - 0, 0, - SWP_NOSIZE | SWP_NOACTIVATE | SWP_NOZORDER); - break; -#endif - /* not resized in windows. Since wine uses this invisible control - * to size the browser view it needs to be resized */ - case IDC_SHELLSTATIC: - DeferWindowPos( hdwp, ctrl, NULL, 0, 0, - rc.right - rc.left + chgx, - rc.bottom - rc.top + chgy, - SWP_NOMOVE | SWP_NOACTIVATE | SWP_NOZORDER); - break; - } - } } if(fodInfos->DlgInfos.hwndCustomDlg && (fodInfos->ofnInfos->Flags & (OFN_ENABLETEMPLATE | OFN_ENABLETEMPLATEHANDLE))) { + GetClientRect(hwnd, &rc); + DeferWindowPos( hdwp,fodInfos->DlgInfos.hwndCustomDlg, NULL, + 0, 0, rc.right, rc.bottom, SWP_NOMOVE | SWP_NOACTIVATE | SWP_NOZORDER); for( ctrl = GetWindow( fodInfos->DlgInfos.hwndCustomDlg, GW_CHILD); ctrl ; ctrl = GetWindow( ctrl, GW_HWNDNEXT)) { @@ -1140,11 +1096,6 @@ static LRESULT FILEDLG95_OnWMSize(HWND hwnd, WPARAM wParam, LPARAM lParam) SWP_NOSIZE | SWP_NOACTIVATE | SWP_NOZORDER); } } - /* size the custom dialog at the end: some applications do some - * control re-arranging at this point */ - GetClientRect(hwnd, &rc); - DeferWindowPos( hdwp,fodInfos->DlgInfos.hwndCustomDlg, NULL, - 0, 0, rc.right, rc.bottom, SWP_NOMOVE | SWP_NOACTIVATE | SWP_NOZORDER); } EndDeferWindowPos( hdwp); /* should not be needed */ @@ -1195,17 +1146,13 @@ INT_PTR CALLBACK FileOpenDlgProc95(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM l FILEDLG95_ResizeControls(hwnd, wParam, lParam); FILEDLG95_FillControls(hwnd, wParam, lParam); - if( fodInfos->DlgInfos.hwndCustomDlg) - ShowWindow( fodInfos->DlgInfos.hwndCustomDlg, SW_SHOW); - - if(fodInfos->ofnInfos->Flags & OFN_EXPLORER) { + if(fodInfos->ofnInfos->Flags & OFN_EXPLORER) SendCustomDlgNotificationMessage(hwnd,CDN_INITDONE); - SendCustomDlgNotificationMessage(hwnd,CDN_FOLDERCHANGE); - } if (fodInfos->ofnInfos->Flags & OFN_ENABLESIZING) { GetWindowRect( hwnd, &rc); + /* FIXME: should remember sizes of last invocation */ fodInfos->sizedlg.cx = rc.right - rc.left; fodInfos->sizedlg.cy = rc.bottom - rc.top; fodInfos->initial_size.x = fodInfos->sizedlg.cx; @@ -1214,16 +1161,13 @@ INT_PTR CALLBACK FileOpenDlgProc95(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM l SetWindowPos( fodInfos->DlgInfos.hwndGrip, NULL, rc.right - gripx, rc.bottom - gripy, 0, 0, SWP_NOSIZE | SWP_NOACTIVATE | SWP_NOZORDER); - /* resize the dialog to the previous invocation */ - if( MemDialogSize.cx && MemDialogSize.cy) - SetWindowPos( hwnd, NULL, - 0, 0, MemDialogSize.cx, MemDialogSize.cy, - SWP_NOMOVE | SWP_NOACTIVATE | SWP_NOZORDER); } if(fodInfos->ofnInfos->Flags & OFN_EXPLORER) + { + SendCustomDlgNotificationMessage(hwnd,CDN_FOLDERCHANGE); SendCustomDlgNotificationMessage(hwnd,CDN_SELCHANGE); - + } return 0; } case WM_SIZE: @@ -1247,13 +1191,9 @@ INT_PTR CALLBACK FileOpenDlgProc95(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM l return FILEDLG95_OnWMGetIShellBrowser(hwnd); case WM_DESTROY: - { - FileOpenDlgInfos * fodInfos = GetPropA(hwnd,FileOpenDlgInfosStr); - if (fodInfos && fodInfos->ofnInfos->Flags & OFN_ENABLESIZING) - MemDialogSize = fodInfos->sizedlg; - RemovePropA(hwnd, FileOpenDlgInfosStr); - return FALSE; - } + RemovePropA(hwnd, FileOpenDlgInfosStr); + return FALSE; + case WM_NOTIFY: { LPNMHDR lpnmh = (LPNMHDR)lParam; @@ -1820,19 +1760,19 @@ static BOOL FILEDLG95_SendFileOK( HWND hwnd, FileOpenDlgInfos *fodInfos ) /* First send CDN_FILEOK as MSDN doc says */ if(fodInfos->ofnInfos->Flags & OFN_EXPLORER) retval = SendCustomDlgNotificationMessage(hwnd,CDN_FILEOK); - if( retval) + if (GetWindowLongPtrW(fodInfos->DlgInfos.hwndCustomDlg, DWLP_MSGRESULT)) { TRACE("canceled\n"); - return FALSE; + return (retval == 0); } /* fodInfos->ofnInfos points to an ASCII or UNICODE structure as appropriate */ retval = SendMessageW(fodInfos->DlgInfos.hwndCustomDlg, fodInfos->HookMsg.fileokstring, 0, (LPARAM)fodInfos->ofnInfos); - if( retval) + if (GetWindowLongPtrW(fodInfos->DlgInfos.hwndCustomDlg, DWLP_MSGRESULT)) { TRACE("canceled\n"); - return FALSE; + return (retval == 0); } } return TRUE; diff --git a/dlls/comdlg32/rsrc.rc b/dlls/comdlg32/rsrc.rc new file mode 100644 index 00000000000..d6f160de2ae --- /dev/null +++ b/dlls/comdlg32/rsrc.rc @@ -0,0 +1,73 @@ +/* + * Top level resource file for Common Dialogs + * + * Copyright 1999 Bertho Stultiens + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winnls.h" +#include "cdlg.h" +#include "winspool.h" +#include "filedlgbrowser.h" + +/* + * Everything that does not depend on language, + * like textless bitmaps etc, go into the + * neutral language. This will prevent them from + * being duplicated for each language. + */ +#include "cdlg_xx.rc" + +/* + * Everything specific to any language goes + * in one of the specific files. + * Note that you can and may override resources + * which also have a neutral version. This is to + * get localized bitmaps for example. + */ +#include "cdlg_Bg.rc" +#include "cdlg_Ca.rc" +#include "cdlg_Cs.rc" +#include "cdlg_Da.rc" +#include "cdlg_De.rc" +#include "cdlg_El.rc" +#include "cdlg_En.rc" +#include "cdlg_Eo.rc" +#include "cdlg_Es.rc" +#include "cdlg_Fi.rc" +#include "cdlg_Fr.rc" +#include "cdlg_Hu.rc" +#include "cdlg_It.rc" +#include "cdlg_Ja.rc" +#include "cdlg_Ko.rc" +#include "cdlg_Lt.rc" +#include "cdlg_Nl.rc" +#include "cdlg_No.rc" +#include "cdlg_Pl.rc" +#include "cdlg_Pt.rc" +#include "cdlg_Ro.rc" +#include "cdlg_Ru.rc" +#include "cdlg_Si.rc" +#include "cdlg_Sk.rc" +#include "cdlg_Sv.rc" +#include "cdlg_Th.rc" +#include "cdlg_Tr.rc" +#include "cdlg_Uk.rc" +#include "cdlg_Wa.rc" +#include "cdlg_Zh.rc" diff --git a/dlls/comdlg32/tests/filedlg.c b/dlls/comdlg32/tests/filedlg.c index 2bef8cefb45..0cd1e634e7a 100644 --- a/dlls/comdlg32/tests/filedlg.c +++ b/dlls/comdlg32/tests/filedlg.c @@ -273,20 +273,21 @@ static void test_create_view_template(void) /* test cases for resizing of the file dialog */ struct { DWORD flags; - int resize_folderchange;/* change in CDN_FOLDERCHANGE handler */ - int resize_timer1; /* change in first WM_TIMER handler */ - int resize_check; /* expected change (in second WM_TIMER handler) */ - BOOL todo; /* mark that test todo_wine */ - BOOL testcontrols; /* test resizing and moving of the controls */ + int resize_init; /* change in CDN_INITDONE handler */ + int resize_folderchg; /* change in CDN_FOLDERCHANGE handler */ + int resize_timer1; /* change in first WM_TIMER handler */ + int resize_check; /* expected change (in second WM_TIMER handler) */ + BOOL todo; /* mark that test todo_wine */ } resize_testcases[] = { - { 0 , 10, 10, 20,FALSE,FALSE}, /* 0 */ - { 0 ,-10,-10,-20,FALSE,FALSE}, - { OFN_ENABLESIZING , 0, 0, 0,FALSE,FALSE}, - { OFN_ENABLESIZING , 0,-10, 0,FALSE,FALSE}, - { OFN_ENABLESIZING , 0, 10, 10,FALSE, TRUE}, - { OFN_ENABLESIZING ,-10, 0, 10,FALSE,FALSE}, /* 5 */ - { OFN_ENABLESIZING , 10, 0, 10,FALSE,FALSE}, - { OFN_ENABLESIZING , 0, 10, 20,FALSE,FALSE}, + { 0 , 10, 10, 10, 30,FALSE}, /* 0 */ + { 0 ,-10,-10,-10,-30,FALSE}, + { OFN_ENABLESIZING , 0, 0, 0, 0,FALSE}, + { OFN_ENABLESIZING , 0, 0,-10, 0,FALSE}, + { OFN_ENABLESIZING , 0, 0, 10, 10,FALSE}, + { OFN_ENABLESIZING , 0,-10, 0, 10, TRUE}, /* 5 */ + { OFN_ENABLESIZING , 0, 10, 0, 10,FALSE}, + { OFN_ENABLESIZING ,-10, 0, 0, 10, TRUE}, + { OFN_ENABLESIZING , 10, 0, 0, 10,FALSE}, /* mark the end */ { 0xffffffff } }; @@ -295,15 +296,8 @@ static LONG_PTR WINAPI resize_template_hook(HWND dlg, UINT msg, WPARAM wParam, L { static RECT initrc, rc; static int index, count; - static int gotSWP_bottom, gotShowWindow; HWND parent = GetParent( dlg); int resize; -#define MAXNRCTRLS 30 - static RECT ctrlrcs[MAXNRCTRLS]; - static int ctrlids[MAXNRCTRLS]; - static HWND ctrls[MAXNRCTRLS]; - static int nrctrls; - switch( msg) { case WM_INITDIALOG: @@ -312,7 +306,6 @@ static LONG_PTR WINAPI resize_template_hook(HWND dlg, UINT msg, WPARAM wParam, L index = ((OPENFILENAME*)lParam)->lCustData; count = 0; - gotSWP_bottom = gotShowWindow = 0; /* test style */ style = GetWindowLong( parent, GWL_STYLE); if( resize_testcases[index].flags & OFN_ENABLESIZING) @@ -329,12 +322,18 @@ static LONG_PTR WINAPI resize_template_hook(HWND dlg, UINT msg, WPARAM wParam, L } case WM_NOTIFY: { - if(( (LPNMHDR)lParam)->code == CDN_FOLDERCHANGE){ + if(( (LPNMHDR)lParam)->code == CDN_INITDONE){ GetWindowRect( parent, &initrc); - if( (resize = resize_testcases[index].resize_folderchange)){ + if( (resize = resize_testcases[index].resize_init)){ MoveWindow( parent, initrc.left,initrc.top, initrc.right - initrc.left + resize, initrc.bottom - initrc.top + resize, TRUE); } + } else if(( (LPNMHDR)lParam)->code == CDN_FOLDERCHANGE){ + if( (resize = resize_testcases[index].resize_folderchg)){ + GetWindowRect( parent, &rc); + MoveWindow( parent, rc.left,rc.top, rc.right - rc.left + resize, + rc.bottom - rc.top + resize, TRUE); + } SetTimer( dlg, 0, 100, 0); } break; @@ -342,20 +341,6 @@ static LONG_PTR WINAPI resize_template_hook(HWND dlg, UINT msg, WPARAM wParam, L case WM_TIMER: { if( count == 0){ - /* store the control rectangles */ - if( resize_testcases[index].testcontrols) { - HWND ctrl; - int i; - for( i = 0, ctrl = GetWindow( parent, GW_CHILD); - i < MAXNRCTRLS && ctrl; - i++, ctrl = GetWindow( ctrl, GW_HWNDNEXT)) { - ctrlids[i] = GetDlgCtrlID( ctrl); - GetWindowRect( ctrl, &ctrlrcs[i]); - MapWindowPoints( NULL, parent, (LPPOINT) &ctrlrcs[i], 2); - ctrls[i] = ctrl; - } - nrctrls = i; - } if( (resize = resize_testcases[index].resize_timer1)){ GetWindowRect( parent, &rc); MoveWindow( parent, rc.left,rc.top, rc.right - rc.left + resize, @@ -381,124 +366,12 @@ static LONG_PTR WINAPI resize_template_hook(HWND dlg, UINT msg, WPARAM wParam, L "testid %d size-y change %d expected %d\n", index, rc.bottom - rc.top - initrc.bottom + initrc.top, resize); } - if( resize_testcases[index].testcontrols) { - int i; - RECT rc; - for( i = 0; i < nrctrls; i++) { - GetWindowRect( ctrls[i], &rc); - MapWindowPoints( NULL, parent, (LPPOINT) &rc, 2); - switch( ctrlids[i]){ - -/* test if RECT R1, moved and sized result in R2 */ -#define TESTRECTS( R1, R2, Mx, My, Sx, Sy) \ - ((R1).left + (Mx) ==(R2).left \ - &&(R1).top + (My) ==(R2).top \ - &&(R1).right + (Mx) + (Sx) == (R2).right \ - &&(R1).bottom + (My) + (Sy) ==(R2).bottom) - - /* sized horizontal and moved vertical */ - case cmb1: - case edt1: - ok( TESTRECTS( ctrlrcs[i], rc, 0, 10, 10, 0) || - broken(TESTRECTS( ctrlrcs[i], rc, 0, 10, 0, 0)),/*win98*/ - "control id %03x should have sized horizontally and moved vertically, before %d,%d-%d,%d after %d,%d-%d,%d\n", - ctrlids[i], ctrlrcs[i].left, ctrlrcs[i].top, - ctrlrcs[i].right, ctrlrcs[i].bottom, - rc.left, rc.top, rc.right, rc.bottom); - break; - /* sized horizontal and vertical */ - case lst2: - ok( TESTRECTS( ctrlrcs[i], rc, 0, 0, 10, 10), - "control id %03x should have sized horizontally and vertically, before %d,%d-%d,%d after %d,%d-%d,%d\n", - ctrlids[i], ctrlrcs[i].left, ctrlrcs[i].top, - ctrlrcs[i].right, ctrlrcs[i].bottom, - rc.left, rc.top, rc.right, rc.bottom); - break; - /* moved horizontal and vertical */ - case IDCANCEL: - case pshHelp: - ok( TESTRECTS( ctrlrcs[i], rc, 10, 10, 0, 0) || - broken(TESTRECTS( ctrlrcs[i], rc, 0, 10, 0, 0)),/*win98*/ - "control id %03x should have moved horizontally and vertically, before %d,%d-%d,%d after %d,%d-%d,%d\n", - ctrlids[i], ctrlrcs[i].left, ctrlrcs[i].top, - ctrlrcs[i].right, ctrlrcs[i].bottom, - rc.left, rc.top, rc.right, rc.bottom); - break; - /* moved vertically */ - case chx1: - case stc2: - case stc3: - ok( TESTRECTS( ctrlrcs[i], rc, 0, 10, 0, 0), - "control id %03x should have moved vertically, before %d,%d-%d,%d after %d,%d-%d,%d\n", - ctrlids[i], ctrlrcs[i].left, ctrlrcs[i].top, - ctrlrcs[i].right, ctrlrcs[i].bottom, - rc.left, rc.top, rc.right, rc.bottom); - break; - /* resized horizontal */ - case cmb2: /* aka IDC_LOOKIN */ - ok( TESTRECTS( ctrlrcs[i], rc, 0, 0, 10, 0)|| - TESTRECTS( ctrlrcs[i], rc, 0, 0, 0, 0), /* Vista and higher */ - "control id %03x should have resized horizontally, before %d,%d-%d,%d after %d,%d-%d,%d\n", - ctrlids[i], ctrlrcs[i].left, ctrlrcs[i].top, - ctrlrcs[i].right, ctrlrcs[i].bottom, - rc.left, rc.top, rc.right, rc.bottom); - break; - /* non moving non sizing controls */ - case stc4: - ok( TESTRECTS( rc, ctrlrcs[i], 0, 0, 0, 0), - "control id %03x was moved/resized, before %d,%d-%d,%d after %d,%d-%d,%d\n", - ctrlids[i], ctrlrcs[i].left, ctrlrcs[i].top, - ctrlrcs[i].right, ctrlrcs[i].bottom, - rc.left, rc.top, rc.right, rc.bottom); - break; - /* todo_wine: non moving non sizing controls */ - case lst1: -todo_wine - ok( TESTRECTS( rc, ctrlrcs[i], 0, 0, 0, 0), - "control id %03x was moved/resized, before %d,%d-%d,%d after %d,%d-%d,%d\n", - ctrlids[i], ctrlrcs[i].left, ctrlrcs[i].top, - ctrlrcs[i].right, ctrlrcs[i].bottom, - rc.left, rc.top, rc.right, rc.bottom); - break; - /* don't test: id is not unique */ - case IDOK: - case stc1: - case 0: - case -1: - break; - default: - trace("untested control id %03x before %d,%d-%d,%d after %d,%d-%d,%d\n", - ctrlids[i], ctrlrcs[i].left, ctrlrcs[i].top, - ctrlrcs[i].right, ctrlrcs[i].bottom, - rc.left, rc.top, rc.right, rc.bottom); -#undef TESTRECTS -#undef MAXNRCTRLS - } - } - } KillTimer( dlg, 0); PostMessage( parent, WM_COMMAND, IDCANCEL, 0); } count++; } break; - case WM_WINDOWPOSCHANGING: - { - WINDOWPOS *pwp = (WINDOWPOS *)lParam; - if( !index && pwp->hwndInsertAfter == HWND_BOTTOM){ - gotSWP_bottom = 1; - ok( gotShowWindow == 0, "The WM_WINDOWPOSCHANGING message came after a WM_SHOWWINDOW message\n"); - } - } - break; - case WM_SHOWWINDOW: - { - if( !index){ - gotShowWindow = 1; - ok( gotSWP_bottom == 1, "No WM_WINDOWPOSCHANGING message came before a WM_SHOWWINDOW message\n"); - } - } - break; } return 0; } @@ -518,7 +391,7 @@ static void test_resize(void) for( i = 0; resize_testcases[i].flags != 0xffffffff; i++) { ofn.lCustData = i; ofn.Flags = resize_testcases[i].flags | - OFN_ENABLEHOOK | OFN_EXPLORER| OFN_ENABLETEMPLATE | OFN_SHOWHELP ; + OFN_ENABLEHOOK | OFN_EXPLORER| OFN_ENABLETEMPLATE ; ret = GetOpenFileName(&ofn); ok(!ret, "GetOpenFileName returned %#x\n", ret); ret = CommDlgExtendedError(); @@ -526,123 +399,10 @@ static void test_resize(void) } } -/* test cases for control message IDOK */ -/* Show case for bug #19079 */ -static struct { - int retval; /* return code of the message handler */ - BOOL setmsgresult; /* set the result in the DWLP_MSGRESULT */ - BOOL usemsgokstr; /* use the FILEOKSTRING message instead of WM_NOTIFY:CDN_FILEOK */ - BOOL do_subclass; /* subclass the dialog hook procedure */ - BOOL expclose; /* is the dialog expected to close ? */ - BOOL actclose; /* has the dialog actually closed ? */ -} ok_testcases[] = { - { 0, FALSE, FALSE, FALSE, TRUE}, - { 0, TRUE, FALSE, FALSE, TRUE}, - { 0, FALSE, FALSE, TRUE, TRUE}, - { 0, TRUE, FALSE, TRUE, TRUE}, - { 1, FALSE, FALSE, FALSE, TRUE}, - { 1, TRUE, FALSE, FALSE, FALSE}, - { 1, FALSE, FALSE, TRUE, FALSE}, - { 1, TRUE, FALSE, TRUE, FALSE}, - /* FILEOKSTRING tests */ - { 1, TRUE, TRUE, FALSE, FALSE}, - { 1, FALSE, TRUE, TRUE, FALSE}, - /* mark the end */ - { -1 } -}; - -/* test_ok_wndproc can be used as hook procedure or a subclass - * window proc for the file dialog */ -static LONG_PTR WINAPI test_ok_wndproc(HWND dlg, UINT msg, WPARAM wParam, LPARAM lParam) -{ - HWND parent = GetParent( dlg); - static int index; - static UINT msgFILEOKSTRING; - if (msg == WM_INITDIALOG) - { - index = ((OPENFILENAME*)lParam)->lCustData; - ok_testcases[index].actclose = TRUE; - msgFILEOKSTRING = RegisterWindowMessageA( FILEOKSTRING); - } - if( msg == WM_NOTIFY) { - if(((LPNMHDR)lParam)->code == CDN_FOLDERCHANGE) { - SetTimer( dlg, 0, 100, 0); - PostMessage( parent, WM_COMMAND, IDOK, 0); - return FALSE; - } else if(((LPNMHDR)lParam)->code == CDN_FILEOK) { - if( ok_testcases[index].usemsgokstr) - return FALSE; - if( ok_testcases[index].setmsgresult) - SetWindowLongPtrA( dlg, DWLP_MSGRESULT, ok_testcases[index].retval); - return ok_testcases[index].retval; - } - } - if( msg == msgFILEOKSTRING) { - if( !ok_testcases[index].usemsgokstr) - return FALSE; - if( ok_testcases[index].setmsgresult) - SetWindowLongPtrA( dlg, DWLP_MSGRESULT, ok_testcases[index].retval); - return ok_testcases[index].retval; - } - if( msg == WM_TIMER) { - /* the dialog did not close automatically */ - ok_testcases[index].actclose = FALSE; - KillTimer( dlg, 0); - PostMessage( parent, WM_COMMAND, IDCANCEL, 0); - return FALSE; - } - if( ok_testcases[index].do_subclass) - return DefWindowProc( dlg, msg, wParam, lParam); - return FALSE; -} - -static LONG_PTR WINAPI ok_template_hook(HWND dlg, UINT msg, WPARAM wParam, LPARAM lParam) -{ - if (msg == WM_SETFONT) - SetWindowLongPtrA( dlg, GWLP_WNDPROC, (LONG_PTR) test_ok_wndproc); - return FALSE; -} - -static void test_ok(void) -{ - OPENFILENAME ofn = { sizeof(OPENFILENAME)}; - char filename[1024] = {0}; - char tmpfilename[ MAX_PATH]; - int i; - DWORD ret; - - if (!GetTempFileNameA(".", "txt", 0, tmpfilename)) { - skip("Failed to create a temporary file name\n"); - return; - } - ofn.lpstrFile = filename; - ofn.nMaxFile = 1024; - ofn.hInstance = GetModuleHandle(NULL); - ofn.lpTemplateName = "template1"; - ofn.Flags = OFN_ENABLEHOOK | OFN_EXPLORER| OFN_ENABLETEMPLATE ; - for( i = 0; ok_testcases[i].retval != -1; i++) { - strcpy( filename, tmpfilename); - ofn.lCustData = i; - ofn.lpfnHook = ok_testcases[i].do_subclass - ? (LPOFNHOOKPROC) ok_template_hook - : (LPOFNHOOKPROC) test_ok_wndproc; - ret = GetOpenFileNameA(&ofn); - ok( ok_testcases[i].expclose == ok_testcases[i].actclose, - "testid %d: Open File dialog should %shave closed.\n", i, - ok_testcases[i].expclose ? "" : "NOT "); - ok(ret == ok_testcases[i].expclose, "testid %d: GetOpenFileName returned %#x\n", i, ret); - ret = CommDlgExtendedError(); - ok(!ret, "CommDlgExtendedError returned %#x\n", ret); - } - ret = DeleteFileA( tmpfilename); - ok( ret, "Failed to delete temporary file %s err %d\n", tmpfilename, GetLastError()); -} - START_TEST(filedlg) { test_DialogCancel(); test_create_view_window2(); test_create_view_template(); test_resize(); - test_ok(); } diff --git a/dlls/comdlg32/tests/rsrc.rc b/dlls/comdlg32/tests/rsrc.rc index ffd30f99d6f..9600d85f14f 100644 --- a/dlls/comdlg32/tests/rsrc.rc +++ b/dlls/comdlg32/tests/rsrc.rc @@ -39,7 +39,7 @@ FONT 8, "MS Shell Dlg" * This will work with 640x480 pixels */ TEMPLATE_SZ DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 300, 40 -STYLE WS_CHILD | WS_CLIPSIBLINGS +STYLE WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS FONT 8, "MS Shell Dlg" { LTEXT "Path:",-1,28,4,36,8 diff --git a/dlls/comm.drv16/Makefile.in b/dlls/comm.drv16/Makefile.in index b8275038774..481b9332d37 100644 --- a/dlls/comm.drv16/Makefile.in +++ b/dlls/comm.drv16/Makefile.in @@ -6,6 +6,8 @@ MODULE = comm.drv16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16 +SPEC_SRCS = comm.drv16.spec + @MAKE_DLL_RULES@ @DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/compobj.dll16/Makefile.in b/dlls/compobj.dll16/Makefile.in index b1d8da207eb..8fd49fb6fd9 100644 --- a/dlls/compobj.dll16/Makefile.in +++ b/dlls/compobj.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = compobj.dll16 IMPORTS = uuid ole32 advapi32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,ole32.dll +SPEC_SRCS = compobj.dll16.spec + C_SRCS = compobj.c @MAKE_DLL_RULES@ diff --git a/dlls/credui/Makefile.in b/dlls/credui/Makefile.in index f29278c571b..c9d574fefd2 100644 --- a/dlls/credui/Makefile.in +++ b/dlls/credui/Makefile.in @@ -9,24 +9,7 @@ IMPORTS = comctl32 user32 advapi32 kernel32 C_SRCS = \ credui_main.c -RC_SRCS = \ - credui.rc \ - credui_Da.rc \ - credui_De.rc \ - credui_En.rc \ - credui_Es.rc \ - credui_Fr.rc \ - credui_Ko.rc \ - credui_Lt.rc \ - credui_Nl.rc \ - credui_No.rc \ - credui_Pl.rc \ - credui_Pt.rc \ - credui_Ro.rc \ - credui_Ru.rc \ - credui_Si.rc \ - credui_Sv.rc \ - credui_Zh.rc +RC_SRCS = credui.rc @MAKE_DLL_RULES@ diff --git a/dlls/credui/credui.rc b/dlls/credui/credui.rc index 0f16f0065b5..f66a9428043 100644 --- a/dlls/credui/credui.rc +++ b/dlls/credui/credui.rc @@ -18,7 +18,28 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winnls.h" #include "credui_resources.h" /* @makedep: banner.bmp */ IDB_BANNER BITMAP LOADONCALL DISCARDABLE banner.bmp + +#include "credui_Da.rc" +#include "credui_De.rc" +#include "credui_En.rc" +#include "credui_Es.rc" +#include "credui_Fr.rc" +#include "credui_Ko.rc" +#include "credui_Lt.rc" +#include "credui_Nl.rc" +#include "credui_No.rc" +#include "credui_Pl.rc" +#include "credui_Pt.rc" +#include "credui_Ro.rc" +#include "credui_Ru.rc" +#include "credui_Si.rc" +#include "credui_Sv.rc" +#include "credui_Zh.rc" diff --git a/dlls/credui/credui_Da.rc b/dlls/credui/credui_Da.rc index 26ef9914c5d..d5e7608e874 100644 --- a/dlls/credui/credui_Da.rc +++ b/dlls/credui/credui_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT IDD_CREDDIALOG DIALOG DISCARDABLE 0, 0, 213, 149 diff --git a/dlls/credui/credui_De.rc b/dlls/credui/credui_De.rc index 9cbedd2dd60..7c197d6790f 100644 --- a/dlls/credui/credui_De.rc +++ b/dlls/credui/credui_De.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL IDD_CREDDIALOG DIALOG DISCARDABLE 0, 0, 213, 149 @@ -48,7 +44,7 @@ STRINGTABLE DISCARDABLE IDS_TITLEFORMAT "Mit %s verbinden" IDS_MESSAGEFORMAT "Verbindung mit %s wird hergestellt" IDS_INCORRECTPASSWORDTITLE "Anmeldung fehlgeschlagen" - IDS_INCORRECTPASSWORD "Bitte überprüfen Sie Ihren Benutzernamen\nund geben Sie das Kennwort neu ein." + IDS_INCORRECTPASSWORD "Bitte überprüfen Sie Ihren Benutzernamen\nund geben Sie das Kennwort neu ein." IDS_CAPSLOCKONTITLE "Die Feststelltaste ist aktiviert" - IDS_CAPSLOCKON "Mit aktivierter Feststelltaste könnte das Kennwort falsch eingeben werden.\n\nVor der Eingabe des Kennworts sollten Sie die Feststelltaste deaktivieren." + IDS_CAPSLOCKON "Mit aktivierter Feststelltaste könnte das Kennwort falsch eingeben werden.\n\nVor der Eingabe des Kennworts sollten Sie die Feststelltaste deaktivieren." } diff --git a/dlls/credui/credui_En.rc b/dlls/credui/credui_En.rc index feb4afc4b02..8e475bb60ac 100644 --- a/dlls/credui/credui_En.rc +++ b/dlls/credui/credui_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT IDD_CREDDIALOG DIALOG DISCARDABLE 0, 0, 213, 149 diff --git a/dlls/credui/credui_Es.rc b/dlls/credui/credui_Es.rc index 8f71d5ff4c5..0a48b3ff963 100644 --- a/dlls/credui/credui_Es.rc +++ b/dlls/credui/credui_Es.rc @@ -18,9 +18,6 @@ * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ - -#include "credui_resources.h" - #pragma code_page(65001) LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL @@ -53,3 +50,5 @@ STRINGTABLE DISCARDABLE IDS_CAPSLOCKONTITLE "Bloq Mayus está activado" IDS_CAPSLOCKON "El Bloq Mayus activado puede hacer que entre su contraseña incorrectamente.\n\nPulse la tecla Bloq Mayus de su teclado para desactivar Bloq Mayus antes\n de introducir su contraseña." } + +#pragma code_page(default) diff --git a/dlls/credui/credui_Fr.rc b/dlls/credui/credui_Fr.rc index 387a86d39a1..fb7cd126fbe 100644 --- a/dlls/credui/credui_Fr.rc +++ b/dlls/credui/credui_Fr.rc @@ -17,9 +17,6 @@ * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ - -#include "credui_resources.h" - #pragma code_page(65001) LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL @@ -52,3 +49,5 @@ STRINGTABLE DISCARDABLE IDS_CAPSLOCKONTITLE "VERR.MAJ est activé" IDS_CAPSLOCKON "Le verrouillage majuscule étant activé, cela pourrait provoquer une erreur lors de la saisie de votre mot de passe.\n\nAppuyez sur la touche VERR.MAJ de votre clavier afin de désactiver le verrouilage majuscule avant\nde saisir votre mot de passe." } + +#pragma code_page(default) diff --git a/dlls/credui/credui_Ko.rc b/dlls/credui/credui_Ko.rc index ab1f1ec853f..62bd1355d30 100644 --- a/dlls/credui/credui_Ko.rc +++ b/dlls/credui/credui_Ko.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT IDD_CREDDIALOG DIALOG DISCARDABLE 0, 0, 213, 149 diff --git a/dlls/credui/credui_Lt.rc b/dlls/credui/credui_Lt.rc index 4eb6ebaf9b4..9ad3e4bc4ba 100644 --- a/dlls/credui/credui_Lt.rc +++ b/dlls/credui/credui_Lt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - /* UTF-8 */ #pragma code_page(65001) @@ -53,3 +51,5 @@ STRINGTABLE DISCARDABLE IDS_CAPSLOCKONTITLE "Didžiųjų raidžių būsena įjungta" IDS_CAPSLOCKON "Kai įjungta didžiųjų raidžių būsena, savo slaptažodį galite įvesti neteisingai.\n\nPaspauskite didžiųjų raidžių klaviatūros klavišą didžiųjų raidžių būsenai išjungti\nprieš rinkdami savo slaptažodį." } + +#pragma code_page(default) diff --git a/dlls/credui/credui_Nl.rc b/dlls/credui/credui_Nl.rc index 575496ccf33..ed5c41e4b72 100644 --- a/dlls/credui/credui_Nl.rc +++ b/dlls/credui/credui_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL IDD_CREDDIALOG DIALOG DISCARDABLE 0, 0, 213, 149 diff --git a/dlls/credui/credui_No.rc b/dlls/credui/credui_No.rc index c47fec1bf74..cc09cd8351d 100644 --- a/dlls/credui/credui_No.rc +++ b/dlls/credui/credui_No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL IDD_CREDDIALOG DIALOG DISCARDABLE 0, 0, 213, 149 diff --git a/dlls/credui/credui_Pl.rc b/dlls/credui/credui_Pl.rc index e2fab5ce42e..902ced6a4d4 100644 --- a/dlls/credui/credui_Pl.rc +++ b/dlls/credui/credui_Pl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT IDD_CREDDIALOG DIALOG DISCARDABLE 0, 0, 213, 149 diff --git a/dlls/credui/credui_Pt.rc b/dlls/credui/credui_Pt.rc index 2283e43bfda..930fb4336a7 100644 --- a/dlls/credui/credui_Pt.rc +++ b/dlls/credui/credui_Pt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL IDD_CREDDIALOG DIALOG DISCARDABLE 0, 0, 213, 149 diff --git a/dlls/credui/credui_Ro.rc b/dlls/credui/credui_Ro.rc index 29e98991983..3d3367e7473 100644 --- a/dlls/credui/credui_Ro.rc +++ b/dlls/credui/credui_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -51,3 +49,5 @@ STRINGTABLE DISCARDABLE IDS_CAPSLOCKONTITLE "Tasta Caps Lock este activată" IDS_CAPSLOCKON "Cu tasta Caps Lock activată este foarte probabil că veți introduce parola greșit.\n\nInainte de a introduce parola apăsați tasta Caps Lock pentru a dezactiva scrierea cu majuscule." } + +#pragma code_page(default) diff --git a/dlls/credui/credui_Ru.rc b/dlls/credui/credui_Ru.rc index 9e0a2d2bbed..fce2c5f055b 100644 --- a/dlls/credui/credui_Ru.rc +++ b/dlls/credui/credui_Ru.rc @@ -18,11 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT IDD_CREDDIALOG DIALOG DISCARDABLE 0, 0, 213, 149 @@ -33,23 +28,23 @@ BEGIN CONTROL IDB_BANNER,-1,"Static",SS_BITMAP | SS_CENTERIMAGE,0, 0,213,37 LTEXT "IDS_MESSAGEFORMAT",IDC_MESSAGE,8,48,199,8,NOT WS_GROUP - LTEXT "По&льзователь:",-1,8,62,72,12,SS_CENTERIMAGE + LTEXT "Ïî&ëüçîâàòåëü:",-1,8,62,72,12,SS_CENTERIMAGE CONTROL "",IDC_USERNAME,"ComboBoxEx32",CBS_DROPDOWN | CBS_NOINTEGRALHEIGHT | WS_TABSTOP,80,62,126,87 - LTEXT "&Пароль:",-1,8,80,72,12,SS_CENTERIMAGE + LTEXT "&Ïàðîëü:",-1,8,80,72,12,SS_CENTERIMAGE EDITTEXT IDC_PASSWORD,80,80,126,12,ES_PASSWORD | ES_AUTOHSCROLL - CONTROL "Со&хранить пароль",IDC_SAVE,"Button", + CONTROL "Ñî&õðàíèòü ïàðîëü",IDC_SAVE,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,80,98,126,12 - DEFPUSHBUTTON "ОК",IDOK,97,128,50,14 - PUSHBUTTON "Отмена",IDCANCEL,156,128,50,14 + DEFPUSHBUTTON "ÎÊ",IDOK,97,128,50,14 + PUSHBUTTON "Îòìåíà",IDCANCEL,156,128,50,14 END STRINGTABLE DISCARDABLE { - IDS_TITLEFORMAT "Подключение к %s" - IDS_MESSAGEFORMAT "Подключение к %s" - IDS_INCORRECTPASSWORDTITLE "Вход не был произведён" - IDS_INCORRECTPASSWORD "Убедитесь, что имя пользователя\nи пароль верны." - IDS_CAPSLOCKONTITLE "Caps Lock включен" - IDS_CAPSLOCKON "Пароль может быть введён неправильно из-за нажатой клавиши Caps Lock.\n\nОтключите Caps Lock перед тем, как вводить пароль." + IDS_TITLEFORMAT "Ïîäêëþ÷åíèå ê %s" + IDS_MESSAGEFORMAT "Ïîäêëþ÷åíèå ê %s" + IDS_INCORRECTPASSWORDTITLE "Âõîä íå áûë ïðîèçâåä¸í" + IDS_INCORRECTPASSWORD "Óáåäèòåñü, ÷òî èìÿ ïîëüçîâàòåëÿ\nè ïàðîëü âåðíû." + IDS_CAPSLOCKONTITLE "Caps Lock âêëþ÷åí" + IDS_CAPSLOCKON "Ïàðîëü ìîæåò áûòü ââåä¸í íåïðàâèëüíî èç-çà íàæàòîé êëàâèøè Caps Lock.\n\nÎòêëþ÷èòå Caps Lock ïåðåä òåì, êàê ââîäèòü ïàðîëü." } diff --git a/dlls/credui/credui_Si.rc b/dlls/credui/credui_Si.rc index 34915e668b5..d2152adf1cf 100644 --- a/dlls/credui/credui_Si.rc +++ b/dlls/credui/credui_Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -52,3 +50,5 @@ STRINGTABLE DISCARDABLE IDS_CAPSLOCKONTITLE "Caps Lock je vključen" IDS_CAPSLOCKON "Vključen Caps Lock je lahko vzrok nepravilnega vnosa gesla.\n\nPritisnite tipko Caps Lock, s čimer ga izklopite\nin ponovno vnesite geslo." } + +#pragma code_page(default) diff --git a/dlls/credui/credui_Sv.rc b/dlls/credui/credui_Sv.rc index a43c216b227..453b7a38934 100644 --- a/dlls/credui/credui_Sv.rc +++ b/dlls/credui/credui_Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL IDD_CREDDIALOG DIALOG DISCARDABLE 0, 0, 213, 149 diff --git a/dlls/credui/credui_Zh.rc b/dlls/credui/credui_Zh.rc index 041aecdaaa0..99294c71a95 100644 --- a/dlls/credui/credui_Zh.rc +++ b/dlls/credui/credui_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "credui_resources.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -84,3 +82,5 @@ STRINGTABLE DISCARDABLE IDS_CAPSLOCKONTITLE "大寫鎖定開著" IDS_CAPSLOCKON "開著大寫鎖定可能導致你輸入錯誤的密碼." } + +#pragma code_page(default) diff --git a/dlls/credui/credui_resources.h b/dlls/credui/credui_resources.h index 0a6ab72b092..e5bd8ee9335 100644 --- a/dlls/credui/credui_resources.h +++ b/dlls/credui/credui_resources.h @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include - #define IDD_CREDDIALOG 100 #define IDC_USERNAME 101 #define IDC_PASSWORD 102 diff --git a/dlls/crypt32/Makefile.in b/dlls/crypt32/Makefile.in index c2284b743f7..10ffda94463 100644 --- a/dlls/crypt32/Makefile.in +++ b/dlls/crypt32/Makefile.in @@ -33,18 +33,7 @@ C_SRCS = \ store.c \ str.c -RC_SRCS = \ - crypt32_De.rc \ - crypt32_En.rc \ - crypt32_Fr.rc \ - crypt32_Ko.rc \ - crypt32_Lt.rc \ - crypt32_Nl.rc \ - crypt32_No.rc \ - crypt32_Pt.rc \ - crypt32_Ro.rc \ - crypt32_Sv.rc \ - version.rc +RC_SRCS = crypt32.rc @MAKE_DLL_RULES@ diff --git a/dlls/crypt32/cert.c b/dlls/crypt32/cert.c index 1c0c74ecd14..2b43d3e59a8 100644 --- a/dlls/crypt32/cert.c +++ b/dlls/crypt32/cert.c @@ -2951,35 +2951,3 @@ BOOL WINAPI CertVerifyCTLUsage(DWORD dwEncodingType, DWORD dwSubjectType, SetLastError(ERROR_CALL_NOT_IMPLEMENTED); return FALSE; } - -const void * WINAPI CertCreateContext(DWORD dwContextType, DWORD dwEncodingType, - const BYTE *pbEncoded, DWORD cbEncoded, - DWORD dwFlags, PCERT_CREATE_CONTEXT_PARA pCreatePara) -{ - TRACE("(0x%x, 0x%x, %p, %d, 0x%08x, %p)\n", dwContextType, dwEncodingType, - pbEncoded, cbEncoded, dwFlags, pCreatePara); - - if (dwFlags) - { - FIXME("dwFlags 0x%08x not handled\n", dwFlags); - return NULL; - } - if (pCreatePara) - { - FIXME("pCreatePara not handled\n"); - return NULL; - } - - switch (dwContextType) - { - case CERT_STORE_CERTIFICATE_CONTEXT: - return CertCreateCertificateContext(dwEncodingType, pbEncoded, cbEncoded); - case CERT_STORE_CRL_CONTEXT: - return CertCreateCRLContext(dwEncodingType, pbEncoded, cbEncoded); - case CERT_STORE_CTL_CONTEXT: - return CertCreateCTLContext(dwEncodingType, pbEncoded, cbEncoded); - default: - WARN("unknown context type: 0x%x\n", dwContextType); - return NULL; - } -} diff --git a/dlls/crypt32/crypt32.rc b/dlls/crypt32/crypt32.rc new file mode 100644 index 00000000000..1afa8a75296 --- /dev/null +++ b/dlls/crypt32/crypt32.rc @@ -0,0 +1,34 @@ +/* + * crypt32 dll resources + * + * Copyright (C) 2006 Juan Lang + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "cryptres.h" + +#include "version.rc" + +#include "crypt32_De.rc" +#include "crypt32_En.rc" +#include "crypt32_Fr.rc" +#include "crypt32_Ko.rc" +#include "crypt32_Nl.rc" +#include "crypt32_No.rc" +#include "crypt32_Pt.rc" +#include "crypt32_Sv.rc" diff --git a/dlls/crypt32/crypt32.spec b/dlls/crypt32/crypt32.spec index 534bee7319f..3591d17d234 100644 --- a/dlls/crypt32/crypt32.spec +++ b/dlls/crypt32/crypt32.spec @@ -20,7 +20,6 @@ @ stdcall CertCreateCTLContext(long ptr long) @ stdcall CertCreateCertificateChainEngine(ptr ptr) @ stdcall CertCreateCertificateContext(long ptr long) -@ stdcall CertCreateContext(long long ptr long long ptr) @ stdcall CertCreateSelfSignCertificate(long ptr long ptr ptr ptr ptr ptr) @ stdcall CertDeleteCRLFromStore(ptr) @ stdcall CertDeleteCTLFromStore(ptr) @@ -163,7 +162,7 @@ @ stdcall CryptQueryObject(long ptr long long long ptr ptr ptr ptr ptr ptr) @ stdcall CryptRegisterDefaultOIDFunction(long str long wstr) @ stdcall CryptRegisterOIDFunction(long str str wstr str) -@ stdcall CryptRegisterOIDInfo(ptr long) +@ stub CryptRegisterOIDInfo @ stdcall CryptSIPAddProvider(ptr) @ stdcall CryptSIPCreateIndirectData(ptr ptr ptr) @ stdcall CryptSIPGetSignedDataMsg(ptr ptr long ptr ptr) diff --git a/dlls/crypt32/crypt32_De.rc b/dlls/crypt32/crypt32_De.rc index aa3a4562c70..1d9cbb790e0 100644 --- a/dlls/crypt32/crypt32_De.rc +++ b/dlls/crypt32/crypt32_De.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptres.h" - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -177,7 +175,6 @@ STRINGTABLE DISCARDABLE IDS_LOCALIZEDNAME_CA "Zwischenzertifizierungsstellen" IDS_LOCALIZEDNAME_ADDRESSBOOK "Andere Personen" IDS_LOCALIZEDNAME_TRUSTEDPUBLISHER "Vertrauenswürdige Herausgeber" - IDS_LOCALIZEDNAME_DISALLOWED "Nicht Vertrauenswürdige Zertifikate" } STRINGTABLE DISCARDABLE @@ -242,3 +239,5 @@ STRINGTABLE DISCARDABLE IDS_NETSCAPE_SMIME_CA "S/MIME Zertifikationsautorität" IDS_NETSCAPE_SIGN_CA "Zertifikationsautorität der Signatur" } + +#pragma code_page(default) diff --git a/dlls/crypt32/crypt32_En.rc b/dlls/crypt32/crypt32_En.rc index be068451813..e24ce860f67 100644 --- a/dlls/crypt32/crypt32_En.rc +++ b/dlls/crypt32/crypt32_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptres.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE @@ -174,7 +172,6 @@ STRINGTABLE DISCARDABLE IDS_LOCALIZEDNAME_CA "Intermediate Certification Authorities" IDS_LOCALIZEDNAME_ADDRESSBOOK "Other People" IDS_LOCALIZEDNAME_TRUSTEDPUBLISHER "Trusted Publishers" - IDS_LOCALIZEDNAME_DISALLOWED "Untrusted Certificates" } STRINGTABLE DISCARDABLE diff --git a/dlls/crypt32/crypt32_Fr.rc b/dlls/crypt32/crypt32_Fr.rc dissimilarity index 79% index b98636dee82..35ade1e1a9e 100644 --- a/dlls/crypt32/crypt32_Fr.rc +++ b/dlls/crypt32/crypt32_Fr.rc @@ -1,244 +1,238 @@ -/* - * crypt32 dll French resources - * - * Copyright 2006-2009 Jonathan Ernst - * Copyright 2009 Frédéric Delanoy - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "cryptres.h" - -#pragma code_page(65001) - -LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_AUTHORITY_KEY_ID "Identifiant de l'autorité de la clé" - IDS_KEY_ATTRIBUTES "Attributs de la clé" - IDS_KEY_USAGE_RESTRICTION "Restrictions de l'utilisation de la clé" - IDS_SUBJECT_ALT_NAME "Nom alternatif du sujet" - IDS_ISSUER_ALT_NAME "Nom alternatif de l'émetteur" - IDS_BASIC_CONSTRAINTS "Contraintes de base" - IDS_KEY_USAGE "Utilisation de la clé" - IDS_CERT_POLICIES "Politiques de certificats" - IDS_SUBJECT_KEY_IDENTIFIER "Identifiant de clé du sujet" - IDS_CRL_REASON_CODE "Code de raison pour la LRC" - IDS_CRL_DIST_POINTS "Points de distribution de LRC" - IDS_ENHANCED_KEY_USAGE "Utilisation complémentaire de la clé" - IDS_AUTHORITY_INFO_ACCESS "Accès aux informations de l'autorité" - IDS_CERT_EXTENSIONS "Extensions de certificats" - IDS_NEXT_UPDATE_LOCATION "Emplacement de la mise à jour suivante" - IDS_YES_OR_NO_TRUST "Confiance Oui ou Non" - IDS_EMAIL_ADDRESS "Adresse électronique" - IDS_UNSTRUCTURED_NAME "Nom non structuré" - IDS_CONTENT_TYPE "Type de contenu" - IDS_MESSAGE_DIGEST "Empreinte du message" - IDS_SIGNING_TIME "Heure de la signature" - IDS_COUNTER_SIGN "Contresignature" - IDS_CHALLENGE_PASSWORD "Mot de passe défi" - IDS_UNSTRUCTURED_ADDRESS "Adresse non structurée" - IDS_SMIME_CAPABILITIES "Aptitudes SMIME" - IDS_PREFER_SIGNED_DATA "Préférer les données signées" - IDS_CPS "Énoncé des pratiques de certification (CPS)" - IDS_USER_NOTICE "Notice utilisateur" - IDS_OCSP "Protocole de vérification en ligne de certificat" - IDS_CA_ISSUER "Émetteur de l'autorité de certification" - IDS_CERT_TEMPLATE_NAME "Nom de modèle de certification" - IDS_CERT_TYPE "Type de certificat" - IDS_CERT_MANIFOLD "Certificate Manifold" - IDS_NETSCAPE_CERT_TYPE "Type de certificat Netscape" - IDS_NETSCAPE_BASE_URL "URL Netscape de base" - IDS_NETSCAPE_REVOCATION_URL "URL Netscape de révocation" - IDS_NETSCAPE_CA_REVOCATION_URL "URL Netscape de révocation de l'AC" - IDS_NETSCAPE_CERT_RENEWAL_URL "URL Netscape de renouvellement du certificat" - IDS_NETSCAPE_CA_POLICY_URL "URL Netscape des stratégies d'ACL" - IDS_NETSCAPE_SSL_SERVER_NAME "Nom du serveur SSL de Netscape" - IDS_NETSCAPE_COMMENT "Commentaire Netscape" - IDS_SPC_SP_AGENCY_INFO "SpcSpAgencyInfo" - IDS_SPC_FINANCIAL_CRITERIA "SpcFinancialCriteria" - IDS_SPC_MINIMAL_CRITERIA "SpcMinimalCriteria" - IDS_COUNTRY "Pays/Région" - IDS_ORGANIZATION "Organisation" - IDS_ORGANIZATIONAL_UNIT "Unité d'organisation" - IDS_COMMON_NAME "Nom commun" - IDS_LOCALITY "Localité" - IDS_STATE_OR_PROVINCE "État ou province" - IDS_TITLE "Titre" - IDS_GIVEN_NAME "Nom donné" - IDS_INITIALS "Initiales" - IDS_SUR_NAME "Nom de famille" - IDS_DOMAIN_COMPONENT "Composant de domaine" - IDS_STREET_ADDRESS "Adresse" - IDS_SERIAL_NUMBER "Numéro de série" - IDS_CA_VERSION "Version du CA" - IDS_CROSS_CA_VERSION "Version de certification croisées d'AC" - IDS_SERIALIZED_SIG_SERIAL_NUMBER "Numéro de série de signature sérialisée" - IDS_PRINCIPAL_NAME "Nom principal" - IDS_WINDOWS_PRODUCT_UPDATE "Mise à jour de Windows" - IDS_ENROLLMENT_NAME_VALUE_PAIR "Paire nom/value d'enrôlement" - IDS_OS_VERSION "Version du système d'exploitation" - IDS_ENROLLMENT_CSP "Fournisseur de service cryptographique (CSP) d'enrôlement" - IDS_CRL_NUMBER "Numéro de la LRC" - IDS_DELTA_CRL_INDICATOR "Indicateur de delta-LRC" - IDS_ISSUING_DIST_POINT "Point de distribution d'émission" - IDS_FRESHEST_CRL "LRC la plus récente" - IDS_NAME_CONSTRAINTS "Contraintes de nom" - IDS_POLICY_MAPPINGS "Mappings de politiques" - IDS_POLICY_CONSTRAINTS "Contraintes de politiques" - IDS_CROSS_CERT_DIST_POINTS "Points de distribution de certificats croisés" - IDS_APPLICATION_POLICIES "Politiques applicatives" - IDS_APPLICATION_POLICY_MAPPINGS "Mappings de politiques applicatives" - IDS_APPLICATION_POLICY_CONSTRAINTS "Contraintes de politiques applicatives" - IDS_CMC_DATA "Données CMC" - IDS_CMC_RESPONSE "Réponse CMC" - IDS_UNSIGNED_CMC_REQUEST "Requête CMC non signée" - IDS_CMC_STATUS_INFO "Informations sur le statut CMC" - IDS_CMC_EXTENSIONS "Extensions CMC" - IDS_CMC_ATTRIBUTES "Attributs CMC" - IDS_PKCS_7_DATA "Données PKCS 7" - IDS_PKCS_7_SIGNED "Signé avec PKCS 7" - IDS_PKCS_7_ENVELOPED "Enveloppé avec PKCS 7" - IDS_PKCS_7_SIGNED_ENVELOPED "Enveloppé et signé avec PKCS 7" - IDS_PKCS_7_DIGESTED "Haché avec PKCS 7" - IDS_PKCS_7_ENCRYPTED "Chiffré avec PKCS 7" - IDS_PREVIOUS_CA_CERT_HASH "Empreinte précédente du certificat de l'AC" - IDS_CRL_VIRTUAL_BASE "Numéro de LRC de base virtuelle" - IDS_CRL_NEXT_PUBLISH "Prochaine publication de LRC" - IDS_CA_EXCHANGE "Certificat de chiffrement CA" - IDS_KEY_RECOVERY_AGENT "Agent de recouvrement de clé" - IDS_CERTIFICATE_TEMPLATE "Informations sur le modèle de certificats" - IDS_ENTERPRISE_ROOT_OID "OID racine de l'entreprise" - IDS_RDN_DUMMY_SIGNER "Signataire factice" - IDS_ARCHIVED_KEY_ATTR "Clé de chiffrement privée" - IDS_CRL_SELF_CDP "Emplacement des LRC publiées" - IDS_REQUIRE_CERT_CHAIN_POLICY "Requérir une polique de chaîne de certification" - IDS_TRANSACTION_ID "Identifiant de transaction" - IDS_SENDER_NONCE "Nonce de l'émetteur" - IDS_RECIPIENT_NONCE "Nonce du récepteur" - IDS_REG_INFO "Informations d'enregistrement" - IDS_GET_CERTIFICATE "Obtenir un certificat" - IDS_GET_CRL "Obtenir une LRC" - IDS_REVOKE_REQUEST "Révoquer une requête" - IDS_QUERY_PENDING "Requête en attente" - IDS_SORTED_CTL "Liste de certificats de confiance" - IDS_ARCHIVED_KEY_CERT_HASH "Empreinte du certificat de clé archivée" - IDS_PRIVATE_KEY_USAGE_PERIOD "Période d'utilisation de la clé privée" - IDS_CLIENT_INFORMATION "Informations sur le client" - IDS_SERVER_AUTHENTICATION "Authentification du serveur" - IDS_CLIENT_AUTHENTICATION "Authentification du client" - IDS_CODE_SIGNING "Signature de code" - IDS_SECURE_EMAIL "Messagerie sécurisé" - IDS_TIME_STAMPING "Horodatage" - IDS_MICROSOFT_TRUST_LIST_SIGNING "Signature de la liste de confiance Microsoft" - IDS_MICROSOFT_TIME_STAMPING "Horodatage Microsoft" - IDS_IPSEC_END_SYSTEM "Système terminal IPsec" - IDS_IPSEC_TUNNEL "Terminaison du tunnel IPsec" - IDS_IPSEC_USER "Utilisateur IPsec" - IDS_EFS "Système de fichiers chiffré (EFS)" - IDS_WHQL_CRYPTO "Vérification des pilotes matériels de Windows" - IDS_NT5_CRYPTO "Vérification des composants système de Windows" - IDS_OEM_WHQL_CRYPTO "Vérification des composants système de Windows OEM" - IDS_EMBEDDED_NT_CRYPTO "Vérification des composants système de Windows embarqué" - IDS_KEY_PACK_LICENSES "Licences de jeux de clés" - IDS_LICENSE_SERVER "Vérification du serveur de licence" - IDS_SMART_CARD_LOGON "Connexion avec carte à puce" - IDS_DIGITAL_RIGHTS "Droits numériques" - IDS_QUALIFIED_SUBORDINATION "Subordination conditionnelle" - IDS_KEY_RECOVERY "Recouvrement de clé" - IDS_DOCUMENT_SIGNING "Signature de document" - IDS_IPSEC_IKE_INTERMEDIATE "Intermédiaire IKE IPsec" - IDS_FILE_RECOVERY "Restauration de fichier" - IDS_ROOT_LIST_SIGNER "Signataires de la liste racine" - IDS_ANY_APPLICATION_POLICIES "Toutes les politiques applicatives" - IDS_DS_EMAIL_REPLICATION "Réplication de courriers électroniques du service d'annuaire" - IDS_ENROLLMENT_AGENT "Agent de demande de certificat" - IDS_LIFETIME_SIGNING "Signature à vie" - IDS_ANY_CERT_POLICY "Toutes les politiques d'émission" -} - -STRINGTABLE DISCARDABLE -{ - IDS_LOCALIZEDNAME_ROOT "Autorités de certification de confiance" - IDS_LOCALIZEDNAME_MY "Personnel" - IDS_LOCALIZEDNAME_CA "Autorités intermédiaires" - IDS_LOCALIZEDNAME_ADDRESSBOOK "Autres personnes" - IDS_LOCALIZEDNAME_TRUSTEDPUBLISHER "Éditeurs de confiance" - IDS_LOCALIZEDNAME_DISALLOWED "Certificats non autorisés" -} - -STRINGTABLE DISCARDABLE -{ - IDS_KEY_ID "ID de clé =" - IDS_CERT_ISSUER "Émetteur du certificat" - IDS_CERT_SERIAL_NUMBER "Numéro de série du certificat =" - IDS_ALT_NAME_OTHER_NAME "Autre nom =" - IDS_ALT_NAME_RFC822_NAME "Adresse électronique =" - IDS_ALT_NAME_DNS_NAME "Nom DNS =" - IDS_ALT_NAME_DIRECTORY_NAME "Adresse du répertoire" - IDS_ALT_NAME_URL "URL=" - IDS_ALT_NAME_IP_ADDRESS "Adresse IP =" - IDS_ALT_NAME_MASK "Masque =" - IDS_ALT_NAME_REGISTERED_ID "ID enregistré =" - IDS_USAGE_UNKNOWN "Utilisation de la clé inconnue" - IDS_SUBJECT_TYPE "Type de sujet =" - IDS_SUBJECT_TYPE_CA "AC" - IDS_SUBJECT_TYPE_END_CERT "Entité terminale" - IDS_PATH_LENGTH "Contrainte de longueur de chemin =" - IDS_PATH_LENGTH_NONE "Aucune" - IDS_INFO_NOT_AVAILABLE "Informations non disponibles" - IDS_AIA "Accès aux informations de l'autorité" - IDS_ACCESS_METHOD "Méthode d'accès =" - IDS_ACCESS_METHOD_OCSP "OCSP" - IDS_ACCESS_METHOD_CA_ISSUERS "Émetteurs de l'AC" - IDS_ACCESS_METHOD_UNKNOWN "Méthode d'accès inconnue" - IDS_ACCESS_LOCATION "Nom alternatif" - IDS_CRL_DIST_POINT "Point de distribution de LRC" - IDS_CRL_DIST_POINT_NAME "Nom du point de distribution" - IDS_CRL_DIST_POINT_FULL_NAME "Nom complet" - IDS_CRL_DIST_POINT_RDN_NAME "Nom distingué relatif (RDN)" - IDS_CRL_DIST_POINT_REASON "Raison de la LRC =" - IDS_CRL_DIST_POINT_ISSUER "Émetteur de la LRC" - IDS_REASON_KEY_COMPROMISE "Clé compromise" - IDS_REASON_CA_COMPROMISE "AC compromise" - IDS_REASON_AFFILIATION_CHANGED "Affiliation modifiée" - IDS_REASON_SUPERSEDED "Supplanté" - IDS_REASON_CESSATION_OF_OPERATION "Cessation de opérations" - IDS_REASON_CERTIFICATE_HOLD "Certificat suspendu" - IDS_FINANCIAL_CRITERIA "Informations financières =" - IDS_FINANCIAL_CRITERIA_AVAILABLE "Disponible" - IDS_FINANCIAL_CRITERIA_NOT_AVAILABLE "Non disponible" - IDS_FINANCIAL_CRITERIA_MEETS_CRITERIA "Respecte les critères =" - IDS_YES "Oui" - IDS_NO "Non" - IDS_DIGITAL_SIGNATURE "Signature numérique" - IDS_NON_REPUDIATION "Non-répudiation" - IDS_KEY_ENCIPHERMENT "Chiffrement de la clé" - IDS_DATA_ENCIPHERMENT "Chiffrement de données" - IDS_KEY_AGREEMENT "Accord sur la clé" - IDS_CERT_SIGN "Signature de certificat" - IDS_OFFLINE_CRL_SIGN "Signature de LRC hors-ligne" - IDS_CRL_SIGN "Signature de LRC" - IDS_ENCIPHER_ONLY "Chiffrement seul" - IDS_DECIPHER_ONLY "Déchiffrement seul" - IDS_NETSCAPE_SSL_CLIENT "Authentification de client SSL" - IDS_NETSCAPE_SSL_SERVER "Authentification de serveur SSL" - IDS_NETSCAPE_SMIME "S/MIME" - IDS_NETSCAPE_SIGN "Signature" - IDS_NETSCAPE_SSL_CA "AC SSL" - IDS_NETSCAPE_SMIME_CA "AC S/MIME" - IDS_NETSCAPE_SIGN_CA "Signature CA" -} +/* + * crypt32 dll French resources + * + * Copyright 2006-2009 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL + +STRINGTABLE DISCARDABLE +{ + IDS_AUTHORITY_KEY_ID "Identifiant de l'authorité de la clé" + IDS_KEY_ATTRIBUTES "Attributs de la clé" + IDS_KEY_USAGE_RESTRICTION "Restrictions de l'utilisation de la clé" + IDS_SUBJECT_ALT_NAME "Subject Alternative Name" + IDS_ISSUER_ALT_NAME "Issuer Alternative Name" + IDS_BASIC_CONSTRAINTS "Basic Constraints" + IDS_KEY_USAGE "Utilisation de la clé" + IDS_CERT_POLICIES "Certificate Policies" + IDS_SUBJECT_KEY_IDENTIFIER "Subject Key Identifier" + IDS_CRL_REASON_CODE "CRL Reason Code" + IDS_CRL_DIST_POINTS "CRL Distribution Points" + IDS_ENHANCED_KEY_USAGE "Enhanced Key Usage" + IDS_AUTHORITY_INFO_ACCESS "Authority Information Access" + IDS_CERT_EXTENSIONS "Certificate Extensions" + IDS_NEXT_UPDATE_LOCATION "Next Update Location" + IDS_YES_OR_NO_TRUST "Yes or No Trust" + IDS_EMAIL_ADDRESS "Email Address" + IDS_UNSTRUCTURED_NAME "Unstructured Name" + IDS_CONTENT_TYPE "Content Type" + IDS_MESSAGE_DIGEST "Message Digest" + IDS_SIGNING_TIME "Signing Time" + IDS_COUNTER_SIGN "Counter Sign" + IDS_CHALLENGE_PASSWORD "Challenge Password" + IDS_UNSTRUCTURED_ADDRESS "Unstructured Address" + IDS_SMIME_CAPABILITIES "SMIME Capabilities" + IDS_PREFER_SIGNED_DATA "Prefer Signed Data" + IDS_CPS "CPS" + IDS_USER_NOTICE "Notice utilisateur" + IDS_OCSP "On-line Certificate Status Protocol" + IDS_CA_ISSUER "Certification Authority Issuer" + IDS_CERT_TEMPLATE_NAME "Certification Template Name" + IDS_CERT_TYPE "Certificate Type" + IDS_CERT_MANIFOLD "Certificate Manifold" + IDS_NETSCAPE_CERT_TYPE "Type de certificat Netscape" + IDS_NETSCAPE_BASE_URL "URL Netscape de base" + IDS_NETSCAPE_REVOCATION_URL "URL Netscape de révocation" + IDS_NETSCAPE_CA_REVOCATION_URL "URL Netscape de révocation du certificat" + IDS_NETSCAPE_CERT_RENEWAL_URL "URL Netscape de renouvellement du certificat" + IDS_NETSCAPE_CA_POLICY_URL "Netscape CA Policy URL" + IDS_NETSCAPE_SSL_SERVER_NAME "Netscape SSL ServerName" + IDS_NETSCAPE_COMMENT "Commentaire Netscape" + IDS_SPC_SP_AGENCY_INFO "SpcSpAgencyInfo" + IDS_SPC_FINANCIAL_CRITERIA "SpcFinancialCriteria" + IDS_SPC_MINIMAL_CRITERIA "SpcMinimalCriteria" + IDS_COUNTRY "Pays/Région" + IDS_ORGANIZATION "Organisation" + IDS_ORGANIZATIONAL_UNIT "Unité d'organisation" + IDS_COMMON_NAME "Nom commun" + IDS_LOCALITY "Locality" + IDS_STATE_OR_PROVINCE "État ou province" + IDS_TITLE "Titre" + IDS_GIVEN_NAME "Nom donné" + IDS_INITIALS "Initiales" + IDS_SUR_NAME "Nom de famille" + IDS_DOMAIN_COMPONENT "Domain Component" + IDS_STREET_ADDRESS "Adresse" + IDS_SERIAL_NUMBER "Numéro de série" + IDS_CA_VERSION "Version du CA" + IDS_CROSS_CA_VERSION "Cross CA Version" + IDS_SERIALIZED_SIG_SERIAL_NUMBER "Serialized Signature Serial Number" + IDS_PRINCIPAL_NAME "Nom principal" + IDS_WINDOWS_PRODUCT_UPDATE "Mise à jour de Windows" + IDS_ENROLLMENT_NAME_VALUE_PAIR "Enrollment Name Value Pair" + IDS_OS_VERSION "Version du système d'exploitation" + IDS_ENROLLMENT_CSP "Enrollment CSP" + IDS_CRL_NUMBER "Numéro CRL" + IDS_DELTA_CRL_INDICATOR "Delta CRL Indicator" + IDS_ISSUING_DIST_POINT "Issuing Distribution Point" + IDS_FRESHEST_CRL "Freshest CRL" + IDS_NAME_CONSTRAINTS "Contraintes de nom" + IDS_POLICY_MAPPINGS "Policy Mappings" + IDS_POLICY_CONSTRAINTS "Policy Constraints" + IDS_CROSS_CERT_DIST_POINTS "Cross-Certificate Distribution Points" + IDS_APPLICATION_POLICIES "Application Policies" + IDS_APPLICATION_POLICY_MAPPINGS "Application Policy Mappings" + IDS_APPLICATION_POLICY_CONSTRAINTS "Application Policy Constraints" + IDS_CMC_DATA "Données CMC" + IDS_CMC_RESPONSE "Réponse CMC" + IDS_UNSIGNED_CMC_REQUEST "Unsigned CMC Request" + IDS_CMC_STATUS_INFO "CMC Status Info" + IDS_CMC_EXTENSIONS "CMC Extensions" + IDS_CMC_ATTRIBUTES "CMC Attributes" + IDS_PKCS_7_DATA "Données PKCS 7" + IDS_PKCS_7_SIGNED "Signé avec PKCS 7" + IDS_PKCS_7_ENVELOPED "Enveloppé avec PKCS 7" + IDS_PKCS_7_SIGNED_ENVELOPED "Enveloppé et signé avec PKCS 7" + IDS_PKCS_7_DIGESTED "Haché avec PKCS 7" + IDS_PKCS_7_ENCRYPTED "Chiffré avec PKCS 7" + IDS_PREVIOUS_CA_CERT_HASH "Previous CA Certificate Hash" + IDS_CRL_VIRTUAL_BASE "Virtual Base CRL Number" + IDS_CRL_NEXT_PUBLISH "Next CRL Publish" + IDS_CA_EXCHANGE "Certificat de chiffrement CA" + IDS_KEY_RECOVERY_AGENT "Key Recovery Agent" + IDS_CERTIFICATE_TEMPLATE "Certificate Template Information" + IDS_ENTERPRISE_ROOT_OID "Enterprise Root OID" + IDS_RDN_DUMMY_SIGNER "Signataire factice" + IDS_ARCHIVED_KEY_ATTR "Clé de chiffrement privée" + IDS_CRL_SELF_CDP "Published CRL Locations" + IDS_REQUIRE_CERT_CHAIN_POLICY "Enforce Certificate Chain Policy" + IDS_TRANSACTION_ID "Transaction Id" + IDS_SENDER_NONCE "Sender Nonce" + IDS_RECIPIENT_NONCE "Recipient Nonce" + IDS_REG_INFO "Reg Info" + IDS_GET_CERTIFICATE "Get Certificate" + IDS_GET_CRL "Get CRL" + IDS_REVOKE_REQUEST "Revoke Request" + IDS_QUERY_PENDING "Query Pending" + IDS_SORTED_CTL "Certificate Trust List" + IDS_ARCHIVED_KEY_CERT_HASH "Archived Key Certificate Hash" + IDS_PRIVATE_KEY_USAGE_PERIOD "Private Key Usage Period" + IDS_CLIENT_INFORMATION "Client Information" + IDS_SERVER_AUTHENTICATION "Server Authentication" + IDS_CLIENT_AUTHENTICATION "Client Authentication" + IDS_CODE_SIGNING "Code Signing" + IDS_SECURE_EMAIL "Secure Email" + IDS_TIME_STAMPING "Time Stamping" + IDS_MICROSOFT_TRUST_LIST_SIGNING "Microsoft Trust List Signing" + IDS_MICROSOFT_TIME_STAMPING "Microsoft Time Stamping" + IDS_IPSEC_END_SYSTEM "IP security end system" + IDS_IPSEC_TUNNEL "IP security tunnel termination" + IDS_IPSEC_USER "IP security user" + IDS_EFS "Encrypting File System" + IDS_WHQL_CRYPTO "Windows Hardware Driver Verification" + IDS_NT5_CRYPTO "Windows System Component Verification" + IDS_OEM_WHQL_CRYPTO "OEM Windows System Component Verification" + IDS_EMBEDDED_NT_CRYPTO "Embedded Windows System Component Verification" + IDS_KEY_PACK_LICENSES "Key Pack Licenses" + IDS_LICENSE_SERVER "License Server Verification" + IDS_SMART_CARD_LOGON "Smart Card Logon" + IDS_DIGITAL_RIGHTS "Digital Rights" + IDS_QUALIFIED_SUBORDINATION "Qualified Subordination" + IDS_KEY_RECOVERY "Récupération de clé" + IDS_DOCUMENT_SIGNING "Signature de document" + IDS_IPSEC_IKE_INTERMEDIATE "IP security IKE intermediate" + IDS_FILE_RECOVERY "Récupération de fichier" + IDS_ROOT_LIST_SIGNER "Signataires de la liste racine" + IDS_ANY_APPLICATION_POLICIES "All application policies" + IDS_DS_EMAIL_REPLICATION "Directory Service Email Replication" + IDS_ENROLLMENT_AGENT "Certificate Request Agent" + IDS_LIFETIME_SIGNING "Lifetime Signing" + IDS_ANY_CERT_POLICY "All issuance policies" +} + +STRINGTABLE DISCARDABLE +{ + IDS_LOCALIZEDNAME_ROOT "Autorités de certification de confiance" + IDS_LOCALIZEDNAME_MY "Personnel" + IDS_LOCALIZEDNAME_CA "Autorités intermédiaires" + IDS_LOCALIZEDNAME_ADDRESSBOOK "Autres personnes" + IDS_LOCALIZEDNAME_TRUSTEDPUBLISHER "Éditeurs de confiance" +} + +STRINGTABLE DISCARDABLE +{ + IDS_KEY_ID "KeyID=" + IDS_CERT_ISSUER "Certificate Issuer" + IDS_CERT_SERIAL_NUMBER "Certificate Serial Number=" + IDS_ALT_NAME_OTHER_NAME "Other Name=" + IDS_ALT_NAME_RFC822_NAME "Email Address=" + IDS_ALT_NAME_DNS_NAME "DNS Name=" + IDS_ALT_NAME_DIRECTORY_NAME "Directory Address" + IDS_ALT_NAME_URL "URL=" + IDS_ALT_NAME_IP_ADDRESS "Adresse IP=" + IDS_ALT_NAME_MASK "Mask=" + IDS_ALT_NAME_REGISTERED_ID "Registered ID=" + IDS_USAGE_UNKNOWN "Unknown Key Usage" + IDS_SUBJECT_TYPE "Subject Type=" + IDS_SUBJECT_TYPE_CA "CA" + IDS_SUBJECT_TYPE_END_CERT "End Entity" + IDS_PATH_LENGTH "Path Length Constraint=" + IDS_PATH_LENGTH_NONE "Aucune" + IDS_INFO_NOT_AVAILABLE "Information Not Available" + IDS_AIA "Authority Info Access" + IDS_ACCESS_METHOD "Access Method=" + IDS_ACCESS_METHOD_OCSP "OCSP" + IDS_ACCESS_METHOD_CA_ISSUERS "CA Issuers" + IDS_ACCESS_METHOD_UNKNOWN "Unknown Access Method" + IDS_ACCESS_LOCATION "Alternative Name" + IDS_CRL_DIST_POINT "CRL Distribution Point" + IDS_CRL_DIST_POINT_NAME "Distribution Point Name" + IDS_CRL_DIST_POINT_FULL_NAME "Full Name" + IDS_CRL_DIST_POINT_RDN_NAME "RDN Name" + IDS_CRL_DIST_POINT_REASON "CRL Reason=" + IDS_CRL_DIST_POINT_ISSUER "CRL Issuer" + IDS_REASON_KEY_COMPROMISE "Key Compromise" + IDS_REASON_CA_COMPROMISE "CA Compromise" + IDS_REASON_AFFILIATION_CHANGED "Affiliation Changed" + IDS_REASON_SUPERSEDED "Superseded" + IDS_REASON_CESSATION_OF_OPERATION "Operation Ceased" + IDS_REASON_CERTIFICATE_HOLD "Certificate Hold" + IDS_FINANCIAL_CRITERIA "Financial Information=" + IDS_FINANCIAL_CRITERIA_AVAILABLE "Available" + IDS_FINANCIAL_CRITERIA_NOT_AVAILABLE "Not Available" + IDS_FINANCIAL_CRITERIA_MEETS_CRITERIA "Meets Criteria=" + IDS_YES "Oui" + IDS_NO "Non" + IDS_DIGITAL_SIGNATURE "Signature numérique" + IDS_NON_REPUDIATION "Non-répudiation" + IDS_KEY_ENCIPHERMENT "Key Encipherment" + IDS_DATA_ENCIPHERMENT "Data Encipherment" + IDS_KEY_AGREEMENT "Key Agreement" + IDS_CERT_SIGN "Certificate Signing" + IDS_OFFLINE_CRL_SIGN "Off-line CRL Signing" + IDS_CRL_SIGN "CRL Signing" + IDS_ENCIPHER_ONLY "Chiffrement seul" + IDS_DECIPHER_ONLY "Déchiffrement seul" + IDS_NETSCAPE_SSL_CLIENT "SSL Client Authentication" + IDS_NETSCAPE_SSL_SERVER "SSL Server Authentication" + IDS_NETSCAPE_SMIME "S/MIME" + IDS_NETSCAPE_SIGN "Signature" + IDS_NETSCAPE_SSL_CA "SSL CA" + IDS_NETSCAPE_SMIME_CA "S/MIME CA" + IDS_NETSCAPE_SIGN_CA "Signature CA" +} diff --git a/dlls/crypt32/crypt32_Ko.rc b/dlls/crypt32/crypt32_Ko.rc index 0d83815c3ff..51e3fc32f67 100644 --- a/dlls/crypt32/crypt32_Ko.rc +++ b/dlls/crypt32/crypt32_Ko.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptres.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE @@ -175,7 +173,6 @@ STRINGTABLE DISCARDABLE IDS_LOCALIZEDNAME_CA "Áß°³ °ËÁõ ±â°ü" IDS_LOCALIZEDNAME_ADDRESSBOOK "´Ù¸¥ »ç¶÷" IDS_LOCALIZEDNAME_TRUSTEDPUBLISHER "½Å·ÚÇÒ ¼ö ÀÖ´Â ¹ßÇàÀÚ" - IDS_LOCALIZEDNAME_DISALLOWED "½Å·Ú ÇÒ ¼ö ¾ø´Â ÀÎÁõ¼­" } STRINGTABLE DISCARDABLE diff --git a/dlls/crypt32/crypt32_Lt.rc b/dlls/crypt32/crypt32_Lt.rc deleted file mode 100644 index 9ed21510372..00000000000 --- a/dlls/crypt32/crypt32_Lt.rc +++ /dev/null @@ -1,244 +0,0 @@ -/* - * crypt32 dll resources - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "cryptres.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_AUTHORITY_KEY_ID "Įstaigos rakto identifikatorius" - IDS_KEY_ATTRIBUTES "Rakto atributai" - IDS_KEY_USAGE_RESTRICTION "Rakto naudojimo ribojimai" - IDS_SUBJECT_ALT_NAME "Subjekto alternatyvus vardas" - IDS_ISSUER_ALT_NAME "Išdavėjo alternatyvus vardas" - IDS_BASIC_CONSTRAINTS "Pagrindiniai ribojimai" - IDS_KEY_USAGE "Rakto naudojimas" - IDS_CERT_POLICIES "Liudijimo politika" - IDS_SUBJECT_KEY_IDENTIFIER "Subjekto rakto identifikatorius" - IDS_CRL_REASON_CODE "ALS priežasties kodas" /* Atšauktų Liudijimų Sąrašas */ - IDS_CRL_DIST_POINTS "ALS platinimo vietos" - IDS_ENHANCED_KEY_USAGE "Išplėstas rakto naudojimas" - IDS_AUTHORITY_INFO_ACCESS "Išdavėjo informacijos prieiga" - IDS_CERT_EXTENSIONS "Liudijimo plėtiniai" - IDS_NEXT_UPDATE_LOCATION "Kito atnaujinimo vieta" - IDS_YES_OR_NO_TRUST "Yra ar nėra patikėjimas" - IDS_EMAIL_ADDRESS "Elektroninio pašto adresas" - IDS_UNSTRUCTURED_NAME "Nestruktūrinis vardas" - IDS_CONTENT_TYPE "Turinio tipas" - IDS_MESSAGE_DIGEST "Pranešimo maišos reikšmė" - IDS_SIGNING_TIME "Pasirašymo laikas" - IDS_COUNTER_SIGN "Paliudijantis parašas" - IDS_CHALLENGE_PASSWORD "Iššūkio slaptažodis" - IDS_UNSTRUCTURED_ADDRESS "Nestruktūrinis adresas" - IDS_SMIME_CAPABILITIES "SMIME gebėjimai" - IDS_PREFER_SIGNED_DATA "Teikti pirmenybę pasirašytiems duomenims" - IDS_CPS "Sertifikavimo Veiklos Nuostatos (CPS)" - IDS_USER_NOTICE "Naudotojo pastaba" - IDS_OCSP "Būsenos paliudijimo tinklu protokolas (OCSP)" - IDS_CA_ISSUER "Liudijimo įstaigos steigėjai" - IDS_CERT_TEMPLATE_NAME "Liudijimo šablono pavadinimas" - IDS_CERT_TYPE "Liudijimo tipas" - IDS_CERT_MANIFOLD "Liudijimo kopija" - IDS_NETSCAPE_CERT_TYPE "Netscape liudijimo tipas" - IDS_NETSCAPE_BASE_URL "Netscape bazės URL" - IDS_NETSCAPE_REVOCATION_URL "Netscape atšaukimų URL" - IDS_NETSCAPE_CA_REVOCATION_URL "Netscape LĮ atšaukimų URL" - IDS_NETSCAPE_CERT_RENEWAL_URL "Netscape liudijimų atnaujinimo URL" - IDS_NETSCAPE_CA_POLICY_URL "Netscape LĮ politikos URL" - IDS_NETSCAPE_SSL_SERVER_NAME "Netscape SSL serverio vardas" - IDS_NETSCAPE_COMMENT "Netscape komentaras" - IDS_SPC_SP_AGENCY_INFO "SpcSpAgencyInfo" - IDS_SPC_FINANCIAL_CRITERIA "SpcFinancialCriteria" - IDS_SPC_MINIMAL_CRITERIA "SpcMinimalCriteria" - IDS_COUNTRY "Valstybė/regionas" - IDS_ORGANIZATION "Įstaiga" - IDS_ORGANIZATIONAL_UNIT "Įstaigos padalinys" - IDS_COMMON_NAME "Vardas, pavardė" - IDS_LOCALITY "Vietovė" - IDS_STATE_OR_PROVINCE "Valstija, sritis, gubernija" - IDS_TITLE "Titulas" - IDS_GIVEN_NAME "Vardas" - IDS_INITIALS "Inicialai" - IDS_SUR_NAME "Pavardė" - IDS_DOMAIN_COMPONENT "Srities komponentas" - IDS_STREET_ADDRESS "Adresas" - IDS_SERIAL_NUMBER "Numeris" - IDS_CA_VERSION "LĮ versija" - IDS_CROSS_CA_VERSION "Kryžminės LĮ versija" - IDS_SERIALIZED_SIG_SERIAL_NUMBER "Išdėstyto serijomis parašo numeris" - IDS_PRINCIPAL_NAME "Pagrindinis pavadinimas" - IDS_WINDOWS_PRODUCT_UPDATE "Windows produktų naujinimas" - IDS_ENROLLMENT_NAME_VALUE_PAIR "Registravimo vardo reikšmių pora" - IDS_OS_VERSION "OS versija" - IDS_ENROLLMENT_CSP "Registravimo CSP" - IDS_CRL_NUMBER "ALS numeris" - IDS_DELTA_CRL_INDICATOR "ALS pokyčių indikatorius" - IDS_ISSUING_DIST_POINT "Išdavimo platinimo vieta" - IDS_FRESHEST_CRL "Naujausias ALS" - IDS_NAME_CONSTRAINTS "Vardo ribojimai" - IDS_POLICY_MAPPINGS "Politikos atvaizdavimas" - IDS_POLICY_CONSTRAINTS "Politikos ribojimai" - IDS_CROSS_CERT_DIST_POINTS "Kryžminio liudijimo platinimo vietos" - IDS_APPLICATION_POLICIES "Programos politika" - IDS_APPLICATION_POLICY_MAPPINGS "Programos politikos atvaizdavimas" - IDS_APPLICATION_POLICY_CONSTRAINTS "Programos politikos ribojimai" - IDS_CMC_DATA "CMC duomenys" - IDS_CMC_RESPONSE "CMC atsakymas" - IDS_UNSIGNED_CMC_REQUEST "Nepasirašyta CMC užklausa" - IDS_CMC_STATUS_INFO "CMC būsenos informacija" - IDS_CMC_EXTENSIONS "CMC plėtiniai" - IDS_CMC_ATTRIBUTES "CMC atributai" - IDS_PKCS_7_DATA "PKCS 7 duomenys" - IDS_PKCS_7_SIGNED "PKCS 7 pasirašytas" - IDS_PKCS_7_ENVELOPED "PKCS 7 voke" - IDS_PKCS_7_SIGNED_ENVELOPED "PKCS 7 pasirašytas, voke" - IDS_PKCS_7_DIGESTED "PKCS 7 apskaičiuota maišos reikšmė" - IDS_PKCS_7_ENCRYPTED "PKCS 7 užšifruotas" - IDS_PREVIOUS_CA_CERT_HASH "Ankstesnė LĮ liudijimo maišos reikšmė" - IDS_CRL_VIRTUAL_BASE "Virtualus bazinis ALS numeris" - IDS_CRL_NEXT_PUBLISH "Kitas ALS publikavimas" - IDS_CA_EXCHANGE "LĮ užšifravimo liudijimas" - IDS_KEY_RECOVERY_AGENT "Rakto atkūrimo priemonė" - IDS_CERTIFICATE_TEMPLATE "Liudijimo šablono informacija" - IDS_ENTERPRISE_ROOT_OID "Organizacijos pagrindinis objekto identifikatorius" - IDS_RDN_DUMMY_SIGNER "Fiktyvus pasirašytojas" - IDS_ARCHIVED_KEY_ATTR "Užšifruotas privatusis raktas" - IDS_CRL_SELF_CDP "Publikuotos ALS vietos" - IDS_REQUIRE_CERT_CHAIN_POLICY "Priverstinai vykdyti liudijimų grandinės politiką" - IDS_TRANSACTION_ID "Operacijos identifikatorius" - IDS_SENDER_NONCE "Siuntėjas tam kartui" - IDS_RECIPIENT_NONCE "Gavėjas tam kartui" - IDS_REG_INFO "Registracijos informacija" - IDS_GET_CERTIFICATE "Gauti liudijimą" - IDS_GET_CRL "Gauti ALS" - IDS_REVOKE_REQUEST "Atšaukti užklausą" - IDS_QUERY_PENDING "Laukia užklausa" - IDS_SORTED_CTL "Patikintų liudijimų sąrašas" - IDS_ARCHIVED_KEY_CERT_HASH "Atsarginės rakto kopijos liudijimo maišos reikšmė" - IDS_PRIVATE_KEY_USAGE_PERIOD "Privačiojo rakto naudojimo periodas" - IDS_CLIENT_INFORMATION "Kliento informacija" - IDS_SERVER_AUTHENTICATION "Serverio tapatumo nustatymas" - IDS_CLIENT_AUTHENTICATION "Kliento tapatumo nustatymas" - IDS_CODE_SIGNING "Programos kodo pasirašymas" - IDS_SECURE_EMAIL "Saugus elektroninis paštas" - IDS_TIME_STAMPING "Laiko žymos įterpimas" - IDS_MICROSOFT_TRUST_LIST_SIGNING "Microsoft patikintų liudijimų sąrašo pasirašymas" - IDS_MICROSOFT_TIME_STAMPING "Microsoft laiko žymos įterpimas" - IDS_IPSEC_END_SYSTEM "IP saugumo galinė sistema" - IDS_IPSEC_TUNNEL "IP saugumo tunelio baigimas" - IDS_IPSEC_USER "IP saugumo naudotojas" - IDS_EFS "Failų šifravimo sistema" - IDS_WHQL_CRYPTO "Windows tvarkyklių patikra" - IDS_NT5_CRYPTO "Windows sistemos komponentų patikra" - IDS_OEM_WHQL_CRYPTO "OEM Windows sistemos komponentų patikra" - IDS_EMBEDDED_NT_CRYPTO "Įtaisytų Windows sistemos komponentų patikra" - IDS_KEY_PACK_LICENSES "Kodų pako licencijos" - IDS_LICENSE_SERVER "Licencijų serverio patikra" - IDS_SMART_CARD_LOGON "Lustinių kortelių įvedimas" - IDS_DIGITAL_RIGHTS "Skaitmeninės teisės" - IDS_QUALIFIED_SUBORDINATION "Patikslintoji hierarchija" - IDS_KEY_RECOVERY "Rakto atkūrimas" - IDS_DOCUMENT_SIGNING "Dokumentų pasirašymas" - IDS_IPSEC_IKE_INTERMEDIATE "IP saugumo IKE tarpininkas" - IDS_FILE_RECOVERY "Failo atkūrimas" - IDS_ROOT_LIST_SIGNER "Pagrindinio sąrašo pasirašytojas" - IDS_ANY_APPLICATION_POLICIES "Visos programų politikos" - IDS_DS_EMAIL_REPLICATION "Katalogų serverio el. pašto dauginimas" - IDS_ENROLLMENT_AGENT "Liudijimo užklausos priemonė" - IDS_LIFETIME_SIGNING "Gyvavimo ciklo pasirašymas" - IDS_ANY_CERT_POLICY "Visos išdavimo politikos" -} - -STRINGTABLE DISCARDABLE -{ - IDS_LOCALIZEDNAME_ROOT "Patikimos vyriausiosios liudijimų įstaigos" - IDS_LOCALIZEDNAME_MY "Asmeniniai" - IDS_LOCALIZEDNAME_CA "Tarpinės liudijimų įstaigos" - IDS_LOCALIZEDNAME_ADDRESSBOOK "Kiti žmonės" - IDS_LOCALIZEDNAME_TRUSTEDPUBLISHER "Patikimi publikuotojai" - IDS_LOCALIZEDNAME_DISALLOWED "Nepatikimi liudijimai" -} - -STRINGTABLE DISCARDABLE -{ - IDS_KEY_ID "Rakto identifikatorius=" - IDS_CERT_ISSUER "Liudijimo išdavėjas" - IDS_CERT_SERIAL_NUMBER "Liudijimo numeris=" - IDS_ALT_NAME_OTHER_NAME "Kitas vardas=" - IDS_ALT_NAME_RFC822_NAME "Elektroninio pašto adresas=" - IDS_ALT_NAME_DNS_NAME "DNS vardas=" - IDS_ALT_NAME_DIRECTORY_NAME "Katalogo adresas" - IDS_ALT_NAME_URL "URL=" - IDS_ALT_NAME_IP_ADDRESS "IP adresas=" - IDS_ALT_NAME_MASK "Kaukė=" - IDS_ALT_NAME_REGISTERED_ID "Registracijos identifikatorius=" - IDS_USAGE_UNKNOWN "Nežinomas rakto naudojimas" - IDS_SUBJECT_TYPE "Subjekto tipas=" - IDS_SUBJECT_TYPE_CA "LĮ" /* Liudijimo įstaiga */ - IDS_SUBJECT_TYPE_END_CERT "Esybės pabaiga" - IDS_PATH_LENGTH "Kelio ilgio ribojimas=" - IDS_PATH_LENGTH_NONE "Nėra" - IDS_INFO_NOT_AVAILABLE "Informacija neprieinama" - IDS_AIA "Įstaigos informacijos prieiga" - IDS_ACCESS_METHOD "Prieigos metodas=" - IDS_ACCESS_METHOD_OCSP "OCSP" - IDS_ACCESS_METHOD_CA_ISSUERS "LĮ išdavėjai" - IDS_ACCESS_METHOD_UNKNOWN "Nežinomas prieigos metodas" - IDS_ACCESS_LOCATION "Alternatyvus vardas" - IDS_CRL_DIST_POINT "ALS platinimo vieta" - IDS_CRL_DIST_POINT_NAME "Platinimo vietos pavadinimas" - IDS_CRL_DIST_POINT_FULL_NAME "Asmenvardis" - IDS_CRL_DIST_POINT_RDN_NAME "RDN vardas" - IDS_CRL_DIST_POINT_REASON "ALS priežastis=" - IDS_CRL_DIST_POINT_ISSUER "ALS išdavėjas" - IDS_REASON_KEY_COMPROMISE "Pasitikėjimo raktu praradimas" - IDS_REASON_CA_COMPROMISE "Pasitikėjimo LĮ praradimas" - IDS_REASON_AFFILIATION_CHANGED "Priklausomybės pasikeitimas" - IDS_REASON_SUPERSEDED "Išstūmimas" - IDS_REASON_CESSATION_OF_OPERATION "Operacijos nutraukimas" - IDS_REASON_CERTIFICATE_HOLD "Liudijimo įšaldymas" - IDS_FINANCIAL_CRITERIA "Finansinė informacija=" - IDS_FINANCIAL_CRITERIA_AVAILABLE "Prieinama" - IDS_FINANCIAL_CRITERIA_NOT_AVAILABLE "Neprieinama" - IDS_FINANCIAL_CRITERIA_MEETS_CRITERIA "Atitinka kriterijus=" - IDS_YES "Taip" - IDS_NO "Ne" - IDS_DIGITAL_SIGNATURE "Skaitmeninis parašas" - IDS_NON_REPUDIATION "Negalėjimas išsižadėti" - IDS_KEY_ENCIPHERMENT "Rakto užšifravimas" - IDS_DATA_ENCIPHERMENT "Duomenų užšifravimas" - IDS_KEY_AGREEMENT "Rakto susitarimas" - IDS_CERT_SIGN "Liudijimo pasirašymas" - IDS_OFFLINE_CRL_SIGN "ALS pasirašymas atsijungus" - IDS_CRL_SIGN "ALS pasirašymas" - IDS_ENCIPHER_ONLY "Tik užšifravimas" - IDS_DECIPHER_ONLY "Tik dešifravimas" - IDS_NETSCAPE_SSL_CLIENT "SSL kliento tapatumo nustatymas" - IDS_NETSCAPE_SSL_SERVER "SSL serverio tapatumo nustatymas" - IDS_NETSCAPE_SMIME "S/MIME" - IDS_NETSCAPE_SIGN "Parašas" - IDS_NETSCAPE_SSL_CA "SSL LĮ" - IDS_NETSCAPE_SMIME_CA "S/MIME LĮ" - IDS_NETSCAPE_SIGN_CA "Parašo LĮ" -} diff --git a/dlls/crypt32/crypt32_Nl.rc b/dlls/crypt32/crypt32_Nl.rc index bc5cda87c50..70ea2bac05d 100644 --- a/dlls/crypt32/crypt32_Nl.rc +++ b/dlls/crypt32/crypt32_Nl.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptres.h" - -#pragma code_page(65001) - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE @@ -176,7 +172,6 @@ STRINGTABLE DISCARDABLE IDS_LOCALIZEDNAME_CA "Certificatie Tussen-Autoriteiten" IDS_LOCALIZEDNAME_ADDRESSBOOK "Overige Personen" IDS_LOCALIZEDNAME_TRUSTEDPUBLISHER "Vertrouwde uitgevers" - IDS_LOCALIZEDNAME_DISALLOWED "Niet-vertrouwde certificaten" } STRINGTABLE DISCARDABLE diff --git a/dlls/crypt32/crypt32_No.rc b/dlls/crypt32/crypt32_No.rc index b9edbff2837..18de84b8c4b 100644 --- a/dlls/crypt32/crypt32_No.rc +++ b/dlls/crypt32/crypt32_No.rc @@ -1,7 +1,7 @@ /* * crypt32 dll resources * - * Copyright (C) 2006-2009 Alexander N. Sørnes + * Copyright (C) 2006 Alexander N. Sørnes * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -18,26 +18,22 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptres.h" - -#pragma code_page(65001) - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE DISCARDABLE { - IDS_AUTHORITY_KEY_ID "Identifiserer for autentiseringsnøkkel" - IDS_KEY_ATTRIBUTES "Nøkkelegenskaper" - IDS_KEY_USAGE_RESTRICTION "Begrensning av nøkkelbruk" + IDS_AUTHORITY_KEY_ID "Identifiserer for autentiseringsnøkkel" + IDS_KEY_ATTRIBUTES "Nøkkelegenskaper" + IDS_KEY_USAGE_RESTRICTION "Begrensning av nøkkelbruk" IDS_SUBJECT_ALT_NAME "Alternativt navn for emne" IDS_ISSUER_ALT_NAME "Alternativt navn for utsteder" IDS_BASIC_CONSTRAINTS "Basisbegrensninger" - IDS_KEY_USAGE "Nøkkelbruk" + IDS_KEY_USAGE "Nøkkelbruk" IDS_CERT_POLICIES "Sertifikatholdninger" - IDS_SUBJECT_KEY_IDENTIFIER "Identifiserer for emnenøkkel" + IDS_SUBJECT_KEY_IDENTIFIER "Identifiserer for emnenøkkel" IDS_CRL_REASON_CODE "CRL-grunnkode" IDS_CRL_DIST_POINTS "CRL-distribusjonspunkter" - IDS_ENHANCED_KEY_USAGE "Forbedret nøkkelbruk" + IDS_ENHANCED_KEY_USAGE "Forbedret nøkkelbruk" IDS_AUTHORITY_INFO_ACCESS "Myndighet-informasjonstilgang" IDS_CERT_EXTENSIONS "Sertifikatutvidelser" IDS_NEXT_UPDATE_LOCATION "Neste oppdateringsplassering" @@ -56,7 +52,7 @@ STRINGTABLE DISCARDABLE IDS_USER_NOTICE "Brukervarsel" IDS_OCSP "On-line Certificate Status Protocol" IDS_CA_ISSUER "Utsteder for sertifiseringsautoritet" - IDS_CERT_TEMPLATE_NAME "Navn på sertifiseringsmal" + IDS_CERT_TEMPLATE_NAME "Navn på sertifiseringsmal" IDS_CERT_TYPE "Sertifikattype" IDS_CERT_MANIFOLD "Sertifikatmangfold" IDS_NETSCAPE_CERT_TYPE "Netscape-sertifikattype" @@ -96,15 +92,15 @@ STRINGTABLE DISCARDABLE IDS_ISSUING_DIST_POINT "Utsteder distribusjonspunkt" IDS_FRESHEST_CRL "Nyeste CRL" IDS_NAME_CONSTRAINTS "Navnebegrensninger" - IDS_POLICY_MAPPINGS "Framgangsmåtekartlegginger" - IDS_POLICY_CONSTRAINTS "Framgangsmåtebegresninger" + IDS_POLICY_MAPPINGS "Framgangsmåtekartlegginger" + IDS_POLICY_CONSTRAINTS "Framgangsmåtebegresninger" IDS_CROSS_CERT_DIST_POINTS "Distribusjonspunkter for kryss-sertifikat" - IDS_APPLICATION_POLICIES "Framgangsmåter for programmers" - IDS_APPLICATION_POLICY_MAPPINGS "Framgangsmåtekartlegginger for programmer" - IDS_APPLICATION_POLICY_CONSTRAINTS "Framgangsmåtebegrensninger for programmer" + IDS_APPLICATION_POLICIES "Framgangsmåter for programmers" + IDS_APPLICATION_POLICY_MAPPINGS "Framgangsmåtekartlegginger for programmer" + IDS_APPLICATION_POLICY_CONSTRAINTS "Framgangsmåtebegrensninger for programmer" IDS_CMC_DATA "CMC-data" IDS_CMC_RESPONSE "CMS-svar" - IDS_UNSIGNED_CMC_REQUEST "Usignert CMC-forespørsel" + IDS_UNSIGNED_CMC_REQUEST "Usignert CMC-forespørsel" IDS_CMC_STATUS_INFO "CMC-statusinformasjon" IDS_CMC_EXTENSIONS "CMC-utvidelser" IDS_CMC_ATTRIBUTES "CMC-egenskaper" @@ -112,30 +108,30 @@ STRINGTABLE DISCARDABLE IDS_PKCS_7_SIGNED "PKCS 7 Signert" IDS_PKCS_7_ENVELOPED "PKCS 7 Innpakket" IDS_PKCS_7_SIGNED_ENVELOPED "PKCS 7 Signert Innpakket" - IDS_PKCS_7_DIGESTED "PKCS 7 Fordøyet" + IDS_PKCS_7_DIGESTED "PKCS 7 Fordøyet" IDS_PKCS_7_ENCRYPTED "PKCS 7 Kryptert" IDS_PREVIOUS_CA_CERT_HASH "Forrige CA-sertifikatlappskaus" IDS_CRL_VIRTUAL_BASE "Virtuelt basis-CRL-nummer" IDS_CRL_NEXT_PUBLISH "Neste CRL-utgiving" IDS_CA_EXCHANGE "CA-krypteringssertifikat" - IDS_KEY_RECOVERY_AGENT "Agent for nøkkelgjenoppretting" + IDS_KEY_RECOVERY_AGENT "Agent for nøkkelgjenoppretting" IDS_CERTIFICATE_TEMPLATE "Informasjon om sertifikatmal" IDS_ENTERPRISE_ROOT_OID "Storselskap-rot-OID" IDS_RDN_DUMMY_SIGNER "Tullesignerer" - IDS_ARCHIVED_KEY_ATTR "Kryptert privat nøkkel" + IDS_ARCHIVED_KEY_ATTR "Kryptert privat nøkkel" IDS_CRL_SELF_CDP "Publisert CRL-plasseringer" - IDS_REQUIRE_CERT_CHAIN_POLICY "Håndhev sertifikatlenkepolitikk" + IDS_REQUIRE_CERT_CHAIN_POLICY "Håndhev sertifikatlenkepolitikk" IDS_TRANSACTION_ID "Transaksjons-id" IDS_SENDER_NONCE "Gjeldende sender" IDS_RECIPIENT_NONCE "Gjeldende mottaker" IDS_REG_INFO "Reg info" IDS_GET_CERTIFICATE "Hent sertifikat" IDS_GET_CRL "Hent CRL" - IDS_REVOKE_REQUEST "Gjenoppliv forespørsel" - IDS_QUERY_PENDING "Spørring venter" + IDS_REVOKE_REQUEST "Gjenoppliv forespørsel" + IDS_QUERY_PENDING "Spørring venter" IDS_SORTED_CTL "Tillitsliste for sertifikater" - IDS_ARCHIVED_KEY_CERT_HASH "Arkivert nøkkelsertifikatlappskaus" - IDS_PRIVATE_KEY_USAGE_PERIOD "Privat nøkkelbrukperiode" + IDS_ARCHIVED_KEY_CERT_HASH "Arkivert nøkkelsertifikatlappskaus" + IDS_PRIVATE_KEY_USAGE_PERIOD "Privat nøkkelbrukperiode" IDS_CLIENT_INFORMATION "Klientinformasjon" IDS_SERVER_AUTHENTICATION "Tjenerautentisering" IDS_CLIENT_AUTHENTICATION "Klientautentisering" @@ -152,21 +148,21 @@ STRINGTABLE DISCARDABLE IDS_NT5_CRYPTO "Windows sytemkomponent-godkjenning" IDS_OEM_WHQL_CRYPTO "OEM Windows systemkomponent-godkjenning" IDS_EMBEDDED_NT_CRYPTO "Innebygget Windows systemkomponent-godkjenning" - IDS_KEY_PACK_LICENSES "Nøkkelpakkelisenser" + IDS_KEY_PACK_LICENSES "Nøkkelpakkelisenser" IDS_LICENSE_SERVER "Lisenstjener-verifisering" - IDS_SMART_CARD_LOGON "Smart Card-pålogging" + IDS_SMART_CARD_LOGON "Smart Card-pålogging" IDS_DIGITAL_RIGHTS "Digitale rettigheter" IDS_QUALIFIED_SUBORDINATION "Kvalifisert underordinering" - IDS_KEY_RECOVERY "Nøkkelgjenoppretting" + IDS_KEY_RECOVERY "Nøkkelgjenoppretting" IDS_DOCUMENT_SIGNING "Dokumentsignering" IDS_IPSEC_IKE_INTERMEDIATE "IP-sikkerhet IKE viderekommen" IDS_FILE_RECOVERY "Filgjenoppretting" IDS_ROOT_LIST_SIGNER "Rotlistesignerer" - IDS_ANY_APPLICATION_POLICIES "Alle framgangsmåter for programmer" + IDS_ANY_APPLICATION_POLICIES "Alle framgangsmåter for programmer" IDS_DS_EMAIL_REPLICATION "Katalogtjeneste e-postreplikering" - IDS_ENROLLMENT_AGENT "Agent for sertifikatforespørsler" + IDS_ENROLLMENT_AGENT "Agent for sertifikatforespørsler" IDS_LIFETIME_SIGNING "Livstidsignering" - IDS_ANY_CERT_POLICY "Alle framgangsmåter for utsteding" + IDS_ANY_CERT_POLICY "Alle framgangsmåter for utsteding" } STRINGTABLE DISCARDABLE @@ -175,69 +171,4 @@ STRINGTABLE DISCARDABLE IDS_LOCALIZEDNAME_MY "Personlig" IDS_LOCALIZEDNAME_CA "Mellomliggende sertifiseringsinstanser" IDS_LOCALIZEDNAME_ADDRESSBOOK "Andre personer" - IDS_LOCALIZEDNAME_TRUSTEDPUBLISHER "Betrodde utgivere" - IDS_LOCALIZEDNAME_DISALLOWED "Mistrodde sertifikater" -} - -STRINGTABLE DISCARDABLE -{ - IDS_KEY_ID "NøkkelID=" - IDS_CERT_ISSUER "Utsteder" - IDS_CERT_SERIAL_NUMBER "Serienummer=" - IDS_ALT_NAME_OTHER_NAME "Annet navn=" - IDS_ALT_NAME_RFC822_NAME "E-postadresse=" - IDS_ALT_NAME_DNS_NAME "DNS-navn=" - IDS_ALT_NAME_DIRECTORY_NAME "Katalogadresse" - IDS_ALT_NAME_URL "URL=" - IDS_ALT_NAME_IP_ADDRESS "IP-adresse=" - IDS_ALT_NAME_MASK "Mask=" - IDS_ALT_NAME_REGISTERED_ID "Registrert ID=" - IDS_USAGE_UNKNOWN "Ukjent nøkkelbruk" - IDS_SUBJECT_TYPE "Emnetype=" - IDS_SUBJECT_TYPE_CA "CA" - IDS_SUBJECT_TYPE_END_CERT "Sluttenhet" - IDS_PATH_LENGTH "Begrensning på stilengde=" - IDS_PATH_LENGTH_NONE "Ingen" - IDS_INFO_NOT_AVAILABLE "Informasjonen er utilgjengelig" - IDS_AIA "Tilgang til autoritetsinfo" - IDS_ACCESS_METHOD "Tilgangsmetode=" - IDS_ACCESS_METHOD_OCSP "OCSP" - IDS_ACCESS_METHOD_CA_ISSUERS "CA-utstedere" - IDS_ACCESS_METHOD_UNKNOWN "Ukjent tilgangsmetode" - IDS_ACCESS_LOCATION "Alternativt navn" - IDS_CRL_DIST_POINT "Distribusjonspunkt for CRL" - IDS_CRL_DIST_POINT_NAME "Navn på distribusjonspunkt" - IDS_CRL_DIST_POINT_FULL_NAME "Fult navn" - IDS_CRL_DIST_POINT_RDN_NAME "RDN-navn" - IDS_CRL_DIST_POINT_REASON "CRL-årsak=" - IDS_CRL_DIST_POINT_ISSUER "CRL-utsteder" - IDS_REASON_KEY_COMPROMISE "Nøkellkompromiss" - IDS_REASON_CA_COMPROMISE "CA-kompromiss" - IDS_REASON_AFFILIATION_CHANGED "Tilslutning endret" - IDS_REASON_SUPERSEDED "Erstattet" - IDS_REASON_CESSATION_OF_OPERATION "Operasjonen opphørte" - IDS_REASON_CERTIFICATE_HOLD "Sertifikatet er holdt tilbake" - IDS_FINANCIAL_CRITERIA "Finansiell informasjon=" - IDS_FINANCIAL_CRITERIA_AVAILABLE "Tilgjengelig" - IDS_FINANCIAL_CRITERIA_NOT_AVAILABLE "Ikke tilgjengelig" - IDS_FINANCIAL_CRITERIA_MEETS_CRITERIA "Møter kriterier=" - IDS_YES "Ja" - IDS_NO "Nei" - IDS_DIGITAL_SIGNATURE "Digital signatur" - IDS_NON_REPUDIATION "Kan ikke tilbakekalles" - IDS_KEY_ENCIPHERMENT "Nøkkelkryptering" - IDS_DATA_ENCIPHERMENT "Datakryptering" - IDS_KEY_AGREEMENT "Nøkkel-avtale" - IDS_CERT_SIGN "Sertifikatsignering" - IDS_OFFLINE_CRL_SIGN "Lokal CRL-signering" - IDS_CRL_SIGN "CRL-signering" - IDS_ENCIPHER_ONLY "Kun kryptering" - IDS_DECIPHER_ONLY "Kun dekryptering" - IDS_NETSCAPE_SSL_CLIENT "Autentisering av SSL-klient" - IDS_NETSCAPE_SSL_SERVER "Autentisering av SSL-tjener" - IDS_NETSCAPE_SMIME "S/MIME" - IDS_NETSCAPE_SIGN "Signatur" - IDS_NETSCAPE_SSL_CA "SSL CA" - IDS_NETSCAPE_SMIME_CA "S/MIME CA" - IDS_NETSCAPE_SIGN_CA "Signatur CA" } diff --git a/dlls/crypt32/crypt32_Pt.rc b/dlls/crypt32/crypt32_Pt.rc index dcce8097a01..424f8ea7aee 100644 --- a/dlls/crypt32/crypt32_Pt.rc +++ b/dlls/crypt32/crypt32_Pt.rc @@ -18,11 +18,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptres.h" - -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE +LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { @@ -110,11 +106,11 @@ STRINGTABLE DISCARDABLE IDS_CMC_ATTRIBUTES "Atributos CMC" IDS_PKCS_7_DATA "Dados PKCS 7" IDS_PKCS_7_SIGNED "Assinado PKCS 7" - IDS_PKCS_7_ENVELOPED "PKCS 7 Envolvido" - IDS_PKCS_7_SIGNED_ENVELOPED "PKCS 7 Assinado Envolvido" + IDS_PKCS_7_ENVELOPED "PKCS 7 Enveloped" + IDS_PKCS_7_SIGNED_ENVELOPED "PKCS 7 Signed Enveloped" IDS_PKCS_7_DIGESTED "PKCS 7 Resumido" IDS_PKCS_7_ENCRYPTED "PKCS 7 Cifrado" - IDS_PREVIOUS_CA_CERT_HASH "Hash anterior de Certificado CA" + IDS_PREVIOUS_CA_CERT_HASH "Hash Certificado CA prévio" IDS_CRL_VIRTUAL_BASE "Número CRL de Base Virtual" IDS_CRL_NEXT_PUBLISH "Próxima Publicação CRL" IDS_CA_EXCHANGE "Certificado de Cifra CA" @@ -175,8 +171,6 @@ STRINGTABLE DISCARDABLE IDS_LOCALIZEDNAME_MY "Pessoal" IDS_LOCALIZEDNAME_CA "Autoridades de Certificação Intermédias" IDS_LOCALIZEDNAME_ADDRESSBOOK "Outras pessoas" - IDS_LOCALIZEDNAME_TRUSTEDPUBLISHER "Publicadores Confiáveis" - IDS_LOCALIZEDNAME_DISALLOWED "Certificados Desconfiáveis" } STRINGTABLE DISCARDABLE @@ -223,21 +217,4 @@ STRINGTABLE DISCARDABLE IDS_FINANCIAL_CRITERIA_MEETS_CRITERIA "Conforme os Critérios=" IDS_YES "Sim" IDS_NO "Não" - IDS_DIGITAL_SIGNATURE "Assinatura Digital" - IDS_NON_REPUDIATION "Não-Repudiação" - IDS_KEY_ENCIPHERMENT "Ciframento de Chaves" - IDS_DATA_ENCIPHERMENT "Ciframento de Dados" - IDS_KEY_AGREEMENT "Acordo de Chaves" - IDS_CERT_SIGN "Assinatura de Certificados" - IDS_OFFLINE_CRL_SIGN "Assinatura CRL Off-line" - IDS_CRL_SIGN "Assinatura CRL" - IDS_ENCIPHER_ONLY "Cifrar apenas" - IDS_DECIPHER_ONLY "Decifrar apenas" - IDS_NETSCAPE_SSL_CLIENT "Autenticação de Cliente SSL" - IDS_NETSCAPE_SSL_SERVER "Autenticação de Servidor SSL" - IDS_NETSCAPE_SMIME "S/MIME" - IDS_NETSCAPE_SIGN "Assinatura" - IDS_NETSCAPE_SSL_CA "SSL CA" - IDS_NETSCAPE_SMIME_CA "S/MIME CA" - IDS_NETSCAPE_SIGN_CA "CA de Assinatura" } diff --git a/dlls/crypt32/crypt32_Ro.rc b/dlls/crypt32/crypt32_Ro.rc deleted file mode 100644 index 10e33ea4794..00000000000 --- a/dlls/crypt32/crypt32_Ro.rc +++ /dev/null @@ -1,244 +0,0 @@ -/* - * crypt32 dll Romanian resources - * - * Copyright (C) 2009 Paul Chitescu - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "cryptres.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_AUTHORITY_KEY_ID "Identificatorul cheii autorității" - IDS_KEY_ATTRIBUTES "Atributele cheii" - IDS_KEY_USAGE_RESTRICTION "Restricții de folosire a cheii" - IDS_SUBJECT_ALT_NAME "Nume alternativ al subiectului" - IDS_ISSUER_ALT_NAME "Nume alternativ al emitentului" - IDS_BASIC_CONSTRAINTS "Constrângeri de bază" - IDS_KEY_USAGE "Folosirea cheii" - IDS_CERT_POLICIES "Politicile certificatului" - IDS_SUBJECT_KEY_IDENTIFIER "Identificatorul subiectului cheii" - IDS_CRL_REASON_CODE "Codul motivului CRL" - IDS_CRL_DIST_POINTS "Puncte de distribuire CRL" - IDS_ENHANCED_KEY_USAGE "Extensii de folosirea a cheii" - IDS_AUTHORITY_INFO_ACCESS "Acces la informațiile de autoritate" - IDS_CERT_EXTENSIONS "Extensiile certificatului" - IDS_NEXT_UPDATE_LOCATION "Următoarea locație de actualizare" - IDS_YES_OR_NO_TRUST "Încredere Da sau Nu" - IDS_EMAIL_ADDRESS "Adresă de e-mail" - IDS_UNSTRUCTURED_NAME "Nume nestructurat" - IDS_CONTENT_TYPE "Tipul conținutului" - IDS_MESSAGE_DIGEST "Rezumatul mesajului" - IDS_SIGNING_TIME "Momentul semnării" - IDS_COUNTER_SIGN "Contrasemnat" - IDS_CHALLENGE_PASSWORD "Parola de provocare" - IDS_UNSTRUCTURED_ADDRESS "Adresă nestructurată" - IDS_SMIME_CAPABILITIES "Capabilități S/MIME" - IDS_PREFER_SIGNED_DATA "Preferă datele semnate" - IDS_CPS "CPS" - IDS_USER_NOTICE "Notiță utilizator" - IDS_OCSP "Protocol online de verificare a stării certificatului" - IDS_CA_ISSUER "Autoritatea de certificare emitentă" - IDS_CERT_TEMPLATE_NAME "Numele șablonului de certificat" - IDS_CERT_TYPE "Tipul certificatului" - IDS_CERT_MANIFOLD "Ramurile certificatului" - IDS_NETSCAPE_CERT_TYPE "Tipul certificatului Netscape" - IDS_NETSCAPE_BASE_URL "URL-ul de bază Netscape" - IDS_NETSCAPE_REVOCATION_URL "URL-ul de revocare Netscape" - IDS_NETSCAPE_CA_REVOCATION_URL "URL-ul de revocare a CA Netscape" - IDS_NETSCAPE_CERT_RENEWAL_URL "URL-ul de înnoire a certificatului Netscape" - IDS_NETSCAPE_CA_POLICY_URL "URL-ul politicii CA Netscape" - IDS_NETSCAPE_SSL_SERVER_NAME "Nume server SSL Netscape" - IDS_NETSCAPE_COMMENT "Comentariul Netscape" - IDS_SPC_SP_AGENCY_INFO "InformațiiAgențieSpcSp" - IDS_SPC_FINANCIAL_CRITERIA "CriteriiFinanciareSpc" - IDS_SPC_MINIMAL_CRITERIA "CriteriiMinimaleSpc" - IDS_COUNTRY "Țara/regiunea" - IDS_ORGANIZATION "Organizația" - IDS_ORGANIZATIONAL_UNIT "Unitatea organizațională" - IDS_COMMON_NAME "Nume uzual" - IDS_LOCALITY "Localitatea" - IDS_STATE_OR_PROVINCE "Statul sau provincia" - IDS_TITLE "Titlul" - IDS_GIVEN_NAME "Prenume" - IDS_INITIALS "Inițiale" - IDS_SUR_NAME "Nume" - IDS_DOMAIN_COMPONENT "Componentă de domeniu" - IDS_STREET_ADDRESS "Adresa" - IDS_SERIAL_NUMBER "Număr de serie" - IDS_CA_VERSION "Versiunea CA" - IDS_CROSS_CA_VERSION "Versiunea încrucișată CA" - IDS_SERIALIZED_SIG_SERIAL_NUMBER "Număr de serie al semnăturii serializate" - IDS_PRINCIPAL_NAME "Nume principal" - IDS_WINDOWS_PRODUCT_UPDATE "Actualizarea produsului Windows" - IDS_ENROLLMENT_NAME_VALUE_PAIR "Pereche nume-valoare de înscriere" - IDS_OS_VERSION "Versiunea sistemului de operare" - IDS_ENROLLMENT_CSP "CSP de înscriere" - IDS_CRL_NUMBER "Numărul CRL" - IDS_DELTA_CRL_INDICATOR "Indicator diferență CRL" - IDS_ISSUING_DIST_POINT "Punct de distribuție emitent" - IDS_FRESHEST_CRL "Cel mai proaspăt CRL" - IDS_NAME_CONSTRAINTS "Constrângeri de nume" - IDS_POLICY_MAPPINGS "Mapări de politică" - IDS_POLICY_CONSTRAINTS "Constrângeri de politică" - IDS_CROSS_CERT_DIST_POINTS "Puncte încrucișate de distribuție certificate" - IDS_APPLICATION_POLICIES "Politici de aplicație" - IDS_APPLICATION_POLICY_MAPPINGS "Mapări de politică aplicație" - IDS_APPLICATION_POLICY_CONSTRAINTS "Constrângeri de politică aplicație" - IDS_CMC_DATA "Date CMC" - IDS_CMC_RESPONSE "Răspuns CMC" - IDS_UNSIGNED_CMC_REQUEST "Cerere CMC nesemnată" - IDS_CMC_STATUS_INFO "Informații de stare CMC" - IDS_CMC_EXTENSIONS "Extensii CMC" - IDS_CMC_ATTRIBUTES "Atribute CMC" - IDS_PKCS_7_DATA "Date PKCS 7" - IDS_PKCS_7_SIGNED "PKCS 7 semnat" - IDS_PKCS_7_ENVELOPED "PKCS 7 încapsulat" - IDS_PKCS_7_SIGNED_ENVELOPED "PKCS 7 semnat și încapsulat" - IDS_PKCS_7_DIGESTED "PKCS 7 rezumat" - IDS_PKCS_7_ENCRYPTED "PKCS 7 criptat" - IDS_PREVIOUS_CA_CERT_HASH "Rezumatul certificatului CA anterior" - IDS_CRL_VIRTUAL_BASE "Baza virtuală a numerelor CRL" - IDS_CRL_NEXT_PUBLISH "Următorul editor CRL" - IDS_CA_EXCHANGE "Certificat de criptare CA" - IDS_KEY_RECOVERY_AGENT "Agent de recuperare a cheilor" - IDS_CERTIFICATE_TEMPLATE "Șablon de informații de certificat" - IDS_ENTERPRISE_ROOT_OID "OID rădăcină al întreprinderii" - IDS_RDN_DUMMY_SIGNER "Semnatar implicit" - IDS_ARCHIVED_KEY_ATTR "Cheie privată criptată" - IDS_CRL_SELF_CDP "Locații CRL publicate" - IDS_REQUIRE_CERT_CHAIN_POLICY "Impune politica de certificare în lanț" - IDS_TRANSACTION_ID "Identificator de tranzacție" - IDS_SENDER_NONCE "Identificator unic al expeditorului" - IDS_RECIPIENT_NONCE "Identificator unic al destinatarului" - IDS_REG_INFO "Informații de înregistrare" - IDS_GET_CERTIFICATE "Obținere certificat" - IDS_GET_CRL "Obținere CRL" - IDS_REVOKE_REQUEST "Cerere de revocare" - IDS_QUERY_PENDING "Interogare în curs" - IDS_SORTED_CTL "Lista certificatelor de încredere" - IDS_ARCHIVED_KEY_CERT_HASH "Rezumatul certificatului cheii arhivate" - IDS_PRIVATE_KEY_USAGE_PERIOD "Perioada de folosire a cheii private" - IDS_CLIENT_INFORMATION "Informații client" - IDS_SERVER_AUTHENTICATION "Autentificare server" - IDS_CLIENT_AUTHENTICATION "Autentificare client" - IDS_CODE_SIGNING "Semnarea codului" - IDS_SECURE_EMAIL "E-mail securizat" - IDS_TIME_STAMPING "Marcare temporală" - IDS_MICROSOFT_TRUST_LIST_SIGNING "Semnare listă de încredere Microsoft" - IDS_MICROSOFT_TIME_STAMPING "Marcare temporală Microsoft" - IDS_IPSEC_END_SYSTEM "Sistem terminal de securitate IP" - IDS_IPSEC_TUNNEL "Capăt de tunel de securitate IP" - IDS_IPSEC_USER "Utilizator de securitate IP" - IDS_EFS "Sistem de fișiere criptat" - IDS_WHQL_CRYPTO "Verificarea driverelor hardware Windows" - IDS_NT5_CRYPTO "Verificarea componentelor sistem Windows" - IDS_OEM_WHQL_CRYPTO "Verificarea componentelor sistem Windows OEM" - IDS_EMBEDDED_NT_CRYPTO "Verificarea componentelor sistem Windows Embedded" - IDS_KEY_PACK_LICENSES "Licențiere pachet de chei" - IDS_LICENSE_SERVER "Verificarea serverului de licență" - IDS_SMART_CARD_LOGON "Log on cu Smart Card" - IDS_DIGITAL_RIGHTS "Drepturi digitale" - IDS_QUALIFIED_SUBORDINATION "Subordonare calificată" - IDS_KEY_RECOVERY "Recuperare de chei" - IDS_DOCUMENT_SIGNING "Semnare de documente" - IDS_IPSEC_IKE_INTERMEDIATE "Intermediar IKE de securitate IP" - IDS_FILE_RECOVERY "Recuperare de fișiere" - IDS_ROOT_LIST_SIGNER "Semnatarul listei rădăcină" - IDS_ANY_APPLICATION_POLICIES "Toate politicile de aplicație" - IDS_DS_EMAIL_REPLICATION "Replicarea serviciilor repertoar de e-mail" - IDS_ENROLLMENT_AGENT "Agent de cerere de certificate" - IDS_LIFETIME_SIGNING "Semnare pe toată durata vieții" - IDS_ANY_CERT_POLICY "Toate politicile de emitere" -} - -STRINGTABLE DISCARDABLE -{ - IDS_LOCALIZEDNAME_ROOT "Autorități de încredere de bază de certificare" - IDS_LOCALIZEDNAME_MY "Personale" - IDS_LOCALIZEDNAME_CA "Autorități intermediare de certificare" - IDS_LOCALIZEDNAME_ADDRESSBOOK "Alte persoane" - IDS_LOCALIZEDNAME_TRUSTEDPUBLISHER "Editor de încredere" - IDS_LOCALIZEDNAME_DISALLOWED "Lipsite de încredere" -} - -STRINGTABLE DISCARDABLE -{ - IDS_KEY_ID "KeyID=" - IDS_CERT_ISSUER "Emitentul certificatului" - IDS_CERT_SERIAL_NUMBER "Numărul de serie al certificatului=" - IDS_ALT_NAME_OTHER_NAME "Nume alternativ=" - IDS_ALT_NAME_RFC822_NAME "Addresa de e-mail=" - IDS_ALT_NAME_DNS_NAME "Nume de DNS=" - IDS_ALT_NAME_DIRECTORY_NAME "Adresa de repertoar" - IDS_ALT_NAME_URL "URL=" - IDS_ALT_NAME_IP_ADDRESS "Adresa IP=" - IDS_ALT_NAME_MASK "Masca=" - IDS_ALT_NAME_REGISTERED_ID "Identificator înregistrat=" - IDS_USAGE_UNKNOWN "Folosire necunoscută a cheii" - IDS_SUBJECT_TYPE "Tipul subiectului=" - IDS_SUBJECT_TYPE_CA "CA" - IDS_SUBJECT_TYPE_END_CERT "Entitate finală" - IDS_PATH_LENGTH "Constrângere de lungime a căii=" - IDS_PATH_LENGTH_NONE "Fără" - IDS_INFO_NOT_AVAILABLE "Informație indisponibilă" - IDS_AIA "Acces la informațiile de autoritate" - IDS_ACCESS_METHOD "Metoda de acces=" - IDS_ACCESS_METHOD_OCSP "OCSP" - IDS_ACCESS_METHOD_CA_ISSUERS "Emitenți CA" - IDS_ACCESS_METHOD_UNKNOWN "Metodă de acces necunoscută" - IDS_ACCESS_LOCATION "Nume alternativ" - IDS_CRL_DIST_POINT "Punct de distribuție CRL" - IDS_CRL_DIST_POINT_NAME "Numele punctului de distribuție" - IDS_CRL_DIST_POINT_FULL_NAME "Nume complet" - IDS_CRL_DIST_POINT_RDN_NAME "Nume RDN" - IDS_CRL_DIST_POINT_REASON "Motiv CRL=" - IDS_CRL_DIST_POINT_ISSUER "Emitent CRL" - IDS_REASON_KEY_COMPROMISE "Cheia compromisă" - IDS_REASON_CA_COMPROMISE "CA compromisă" - IDS_REASON_AFFILIATION_CHANGED "Afiliere schimbată" - IDS_REASON_SUPERSEDED "Înlocuit" - IDS_REASON_CESSATION_OF_OPERATION "Încetarea operațiunilor" - IDS_REASON_CERTIFICATE_HOLD "Certificat reținut" - IDS_FINANCIAL_CRITERIA "Informația financiară=" - IDS_FINANCIAL_CRITERIA_AVAILABLE "Disponibilă" - IDS_FINANCIAL_CRITERIA_NOT_AVAILABLE "Indisponibilă" - IDS_FINANCIAL_CRITERIA_MEETS_CRITERIA "Îndeplinește criteriul=" - IDS_YES "Da" - IDS_NO "Nu" - IDS_DIGITAL_SIGNATURE "Semnătură digitală" - IDS_NON_REPUDIATION "Non-repudiere" - IDS_KEY_ENCIPHERMENT "Cifrare cheie" - IDS_DATA_ENCIPHERMENT "Cifrare date" - IDS_KEY_AGREEMENT "Înțelegere la cheie" - IDS_CERT_SIGN "Semnare certificat" - IDS_OFFLINE_CRL_SIGN "Semnare CRL offline" - IDS_CRL_SIGN "Semnare CRL" - IDS_ENCIPHER_ONLY "Doar cifrează" - IDS_DECIPHER_ONLY "Doar descifrează" - IDS_NETSCAPE_SSL_CLIENT "Autentificare client SSL" - IDS_NETSCAPE_SSL_SERVER "Autentificare server SSL" - IDS_NETSCAPE_SMIME "S/MIME" - IDS_NETSCAPE_SIGN "Semnătură" - IDS_NETSCAPE_SSL_CA "SSL CA" - IDS_NETSCAPE_SMIME_CA "S/MIME CA" - IDS_NETSCAPE_SIGN_CA "Semnătură CA" -} diff --git a/dlls/crypt32/crypt32_Sv.rc b/dlls/crypt32/crypt32_Sv.rc index 4a242fe10a6..a0e9df5a011 100644 --- a/dlls/crypt32/crypt32_Sv.rc +++ b/dlls/crypt32/crypt32_Sv.rc @@ -17,9 +17,6 @@ * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ - -#include "cryptres.h" - #pragma code_page(65001) LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL @@ -163,3 +160,5 @@ STRINGTABLE DISCARDABLE IDS_FILE_RECOVERY "File Recovery" IDS_ROOT_LIST_SIGNER "Root List Signer" } + +#pragma code_page(default) diff --git a/dlls/crypt32/cryptres.h b/dlls/crypt32/cryptres.h index 0bbffcc58f1..fe2fd91b580 100644 --- a/dlls/crypt32/cryptres.h +++ b/dlls/crypt32/cryptres.h @@ -18,8 +18,6 @@ #ifndef __WINE_CRYPTRES_H__ #define __WINE_CRYPTRES_H__ -#include - #define IDS_AUTHORITY_KEY_ID 1000 #define IDS_KEY_ATTRIBUTES 1001 #define IDS_KEY_USAGE_RESTRICTION 1002 @@ -167,7 +165,6 @@ #define IDS_LOCALIZEDNAME_CA 1143 #define IDS_LOCALIZEDNAME_ADDRESSBOOK 1144 #define IDS_LOCALIZEDNAME_TRUSTEDPUBLISHER 1145 -#define IDS_LOCALIZEDNAME_DISALLOWED 1146 #define IDS_KEY_ID 1200 #define IDS_CERT_ISSUER 1201 diff --git a/dlls/crypt32/decode.c b/dlls/crypt32/decode.c index 7a33e6afa5e..2c2b543e852 100644 --- a/dlls/crypt32/decode.c +++ b/dlls/crypt32/decode.c @@ -523,7 +523,7 @@ static BOOL CRYPT_AsnDecodeSequence(struct AsnDecodeSequenceItem items[], for (i = 0; i < cItem; i++) { bytesNeeded += items[i].size; - structSize = max( structSize, items[i].offset + items[i].minSize ); + structSize += items[i].minSize; } if (pcbDecoded) *pcbDecoded = 1 + lenBytes + cbDecoded; diff --git a/dlls/crypt32/encode.c b/dlls/crypt32/encode.c index 258384c7318..67a0155e584 100644 --- a/dlls/crypt32/encode.c +++ b/dlls/crypt32/encode.c @@ -564,12 +564,13 @@ static BOOL WINAPI CRYPT_AsnEncodeCRLEntries(DWORD dwCertEncodingType, LPCSTR lpszStructType, const void *pvStructInfo, DWORD dwFlags, PCRYPT_ENCODE_PARA pEncodePara, BYTE *pbEncoded, DWORD *pcbEncoded) { + DWORD cCRLEntry = *(const DWORD *)pvStructInfo; DWORD bytesNeeded, dataLen, lenBytes, i; - const CRL_INFO *info = pvStructInfo; - const CRL_ENTRY *rgCRLEntry = info->rgCRLEntry; + const CRL_ENTRY *rgCRLEntry = *(const CRL_ENTRY *const *) + ((const BYTE *)pvStructInfo + sizeof(DWORD)); BOOL ret = TRUE; - for (i = 0, dataLen = 0; ret && i < info->cCRLEntry; i++) + for (i = 0, dataLen = 0; ret && i < cCRLEntry; i++) { DWORD size; @@ -593,7 +594,7 @@ static BOOL WINAPI CRYPT_AsnEncodeCRLEntries(DWORD dwCertEncodingType, *pbEncoded++ = ASN_SEQUENCEOF; CRYPT_EncodeLen(dataLen, pbEncoded, &lenBytes); pbEncoded += lenBytes; - for (i = 0; i < info->cCRLEntry; i++) + for (i = 0; i < cCRLEntry; i++) { DWORD size = dataLen; @@ -658,7 +659,7 @@ static BOOL WINAPI CRYPT_AsnEncodeCRLInfo(DWORD dwCertEncodingType, } if (info->cCRLEntry) { - items[cItem].pvStructInfo = info; + items[cItem].pvStructInfo = &info->cCRLEntry; items[cItem].encodeFunc = CRYPT_AsnEncodeCRLEntries; cItem++; } diff --git a/dlls/crypt32/oid.c b/dlls/crypt32/oid.c index ddc6efc7655..927481ff256 100644 --- a/dlls/crypt32/oid.c +++ b/dlls/crypt32/oid.c @@ -82,8 +82,7 @@ static const WCHAR MY[] = {'M','Y',0}; static const WCHAR CA[] = {'C','A',0}; static const WCHAR ADDRESSBOOK[] = {'A','D','D','R','E','S','S','B','O','O','K',0}; static const WCHAR TRUSTEDPUBLISHER[] = {'T','r','u','s','t','e','d','P','u','b','l','i','s','h','e','r',0}; -static const WCHAR DISALLOWED[] = {'D','i','s','a','l','l','o','w','e','d',0}; -static const LPCWSTR LocalizedKeys[] = {ROOT,MY,CA,ADDRESSBOOK,TRUSTEDPUBLISHER,DISALLOWED}; +static const LPCWSTR LocalizedKeys[] = {ROOT,MY,CA,ADDRESSBOOK,TRUSTEDPUBLISHER}; static WCHAR LocalizedNames[sizeof(LocalizedKeys)/sizeof(LocalizedKeys[0])][256]; static void free_function_sets(void) @@ -666,16 +665,6 @@ error_close_key: } /*********************************************************************** - * CryptRegisterOIDInfo (CRYPT32.@) - */ -BOOL WINAPI CryptRegisterOIDInfo(PCCRYPT_OID_INFO pInfo, DWORD dwFlags) -{ - FIXME("(%p, %x): stub\n", pInfo, dwFlags ); - SetLastError(ERROR_CALL_NOT_IMPLEMENTED); - return FALSE; -} - -/*********************************************************************** * CryptUnregisterOIDFunction (CRYPT32.@) */ BOOL WINAPI CryptUnregisterOIDFunction(DWORD dwEncodingType, LPCSTR pszFuncName, diff --git a/dlls/crypt32/tests/cert.c b/dlls/crypt32/tests/cert.c index 415f9c78dd4..322fa2f92d9 100644 --- a/dlls/crypt32/tests/cert.c +++ b/dlls/crypt32/tests/cert.c @@ -1624,14 +1624,12 @@ static void testSignCert(HCRYPTPROV csp, const CRYPT_DATA_BLOB *toBeSigned, algoID.pszObjId = (LPSTR)sigOID; ret = CryptSignCertificate(0, 0, 0, toBeSigned->pbData, toBeSigned->cbData, &algoID, NULL, NULL, &size); - ok(!ret && - (GetLastError() == ERROR_INVALID_PARAMETER || GetLastError() == NTE_BAD_ALGID), + ok(!ret && (GetLastError() == ERROR_INVALID_PARAMETER || NTE_BAD_ALGID), "Expected ERROR_INVALID_PARAMETER or NTE_BAD_ALGID, got %08x\n", GetLastError()); ret = CryptSignCertificate(0, AT_SIGNATURE, 0, toBeSigned->pbData, toBeSigned->cbData, &algoID, NULL, NULL, &size); - ok(!ret && - (GetLastError() == ERROR_INVALID_PARAMETER || GetLastError() == NTE_BAD_ALGID), + ok(!ret && (GetLastError() == ERROR_INVALID_PARAMETER || NTE_BAD_ALGID), "Expected ERROR_INVALID_PARAMETER or NTE_BAD_ALGID, got %08x\n", GetLastError()); @@ -1853,10 +1851,7 @@ static void testSignAndEncodeCert(void) algID.pszObjId = oid_rsa_md5rsa; ret = CryptSignAndEncodeCertificate(0, 0, X509_ASN_ENCODING, X509_CERT_TO_BE_SIGNED, &info, &algID, NULL, NULL, &size); - ok(!ret && - (GetLastError() == ERROR_INVALID_PARAMETER || - GetLastError() == NTE_BAD_ALGID || - GetLastError() == OSS_BAD_PTR), /* Win9x */ + ok(!ret && (GetLastError() == ERROR_INVALID_PARAMETER || NTE_BAD_ALGID), "Expected ERROR_INVALID_PARAMETER or NTE_BAD_ALGID, got %08x\n", GetLastError()); algID.pszObjId = oid_rsa_md5; diff --git a/dlls/crypt32/tests/encode.c b/dlls/crypt32/tests/encode.c index 9babafd59a8..3e99800638c 100644 --- a/dlls/crypt32/tests/encode.c +++ b/dlls/crypt32/tests/encode.c @@ -5520,10 +5520,7 @@ static void test_decodeCTL(DWORD dwEncoding) SetLastError(0xdeadbeef); ret = pCryptDecodeObjectEx(dwEncoding, PKCS_CTL, ctlWithBogusEntry, sizeof(ctlWithBogusEntry), CRYPT_DECODE_ALLOC_FLAG, NULL, &buf, &size); - ok(!ret && - (GetLastError() == CRYPT_E_ASN1_EOD || - GetLastError() == CRYPT_E_ASN1_CORRUPT || - GetLastError() == OSS_MORE_INPUT), /* Win9x */ + ok(!ret && (GetLastError() == CRYPT_E_ASN1_EOD || CRYPT_E_ASN1_CORRUPT), "expected CRYPT_E_ASN1_EOD or CRYPT_E_ASN1_CORRUPT, got %08x\n", GetLastError()); info.SubjectAlgorithm.Parameters.cbData = 0; diff --git a/dlls/cryptdlg/Makefile.in b/dlls/cryptdlg/Makefile.in index 0cc2d3f9f75..dd5a8155860 100644 --- a/dlls/cryptdlg/Makefile.in +++ b/dlls/cryptdlg/Makefile.in @@ -8,15 +8,7 @@ IMPORTS = cryptui crypt32 wintrust user32 advapi32 kernel32 C_SRCS = \ main.c -RC_SRCS = \ - cryptdlg_De.rc \ - cryptdlg_En.rc \ - cryptdlg_Fr.rc \ - cryptdlg_Ko.rc \ - cryptdlg_Lt.rc \ - cryptdlg_Nl.rc \ - cryptdlg_Pt.rc \ - cryptdlg_Ro.rc +RC_SRCS = cryptdlg.rc @MAKE_DLL_RULES@ diff --git a/dlls/cryptdlg/cryptdlg.rc b/dlls/cryptdlg/cryptdlg.rc new file mode 100644 index 00000000000..a4946529a14 --- /dev/null +++ b/dlls/cryptdlg/cryptdlg.rc @@ -0,0 +1,29 @@ +/* + * cryptdlg dll resources + * + * Copyright 2008 Juan Lang + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "cryptres.h" + +#include "cryptdlg_De.rc" +#include "cryptdlg_En.rc" +#include "cryptdlg_Fr.rc" +#include "cryptdlg_Ko.rc" +#include "cryptdlg_Nl.rc" diff --git a/dlls/cryptdlg/cryptdlg_De.rc b/dlls/cryptdlg/cryptdlg_De.rc index cd3fa96c013..647171d8983 100644 --- a/dlls/cryptdlg/cryptdlg_De.rc +++ b/dlls/cryptdlg/cryptdlg_De.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptres.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/cryptdlg/cryptdlg_En.rc b/dlls/cryptdlg/cryptdlg_En.rc index 72ceecddc9f..99126c42898 100644 --- a/dlls/cryptdlg/cryptdlg_En.rc +++ b/dlls/cryptdlg/cryptdlg_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptres.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE @@ -28,7 +26,7 @@ STRINGTABLE DISCARDABLE IDS_POLICY_ID "Policy Identifier: " IDS_POLICY_QUALIFIER_INFO "Policy Qualifier Info" IDS_POLICY_QUALIFIER_ID "Policy Qualifier Id=" - IDS_CPS "CPS" /* Certification Practice Statement */ + IDS_CPS "CPS" IDS_USER_NOTICE "User Notice" IDS_QUALIFIER "Qualifier" IDS_NOTICE_REF "Notice Reference" diff --git a/dlls/cryptdlg/cryptdlg_Fr.rc b/dlls/cryptdlg/cryptdlg_Fr.rc index 25d8a644ecf..23de9ebd572 100644 --- a/dlls/cryptdlg/cryptdlg_Fr.rc +++ b/dlls/cryptdlg/cryptdlg_Fr.rc @@ -1,8 +1,7 @@ /* * cryptdlg dll French resources * - * Copyright 2008 Jonathan Ernst - * Copyright 2009 Frédéric Delanoy + * Copyright 2008 Jonathan Ernst * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -19,24 +18,19 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptres.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { IDS_CERT_POLICY "Politique de certificat" IDS_POLICY_ID "Identifiant de politique : " - IDS_POLICY_QUALIFIER_INFO "Informations sur le qualificateur de politique" - IDS_POLICY_QUALIFIER_ID "Id de qualificateur de politique =" - IDS_CPS "Énoncé des pratiques de certification (CPS)" - IDS_USER_NOTICE "Avis utilisateur" - IDS_QUALIFIER "Qualificateur" - IDS_NOTICE_REF "Référence à l'avis" - IDS_ORGANIZATION "Organisation =" - IDS_NOTICE_NUM "Numéro de l'avis =" - IDS_NOTICE_TEXT "Texte de l'avis =" + IDS_POLICY_QUALIFIER_INFO "Policy Qualifier Info" + IDS_POLICY_QUALIFIER_ID "Policy Qualifier Id=" + IDS_CPS "CPS" + IDS_USER_NOTICE "User Notice" + IDS_QUALIFIER "Qualifier" + IDS_NOTICE_REF "Notice Reference" + IDS_ORGANIZATION "Organisation=" + IDS_NOTICE_NUM "Notice Number=" + IDS_NOTICE_TEXT "Notice Text=" } diff --git a/dlls/cryptdlg/cryptdlg_Ko.rc b/dlls/cryptdlg/cryptdlg_Ko.rc index e9a6d9d8e97..3778a57b71d 100644 --- a/dlls/cryptdlg/cryptdlg_Ko.rc +++ b/dlls/cryptdlg/cryptdlg_Ko.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptres.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE @@ -29,7 +27,7 @@ STRINGTABLE DISCARDABLE IDS_POLICY_ID "Á¤Ã¥ ½Äº°ÀÚ: " IDS_POLICY_QUALIFIER_INFO "Á¤Ã¥ ±¸º°ÀÚ Á¤º¸" IDS_POLICY_QUALIFIER_ID "Á¤Ã¥ ±¸º°ÀÚ ¾ÆÀ̵ð=" - IDS_CPS "CPS"/*ÀÎÁõ ½ÇÇö ¼±¾ð */ + IDS_CPS "CPS" IDS_USER_NOTICE "»ç¿ëÀÚ ÅëÁö" IDS_QUALIFIER "±¸º°ÀÚ" IDS_NOTICE_REF "ÅëÁö ÂüÁ¶" diff --git a/dlls/cryptdlg/cryptdlg_Lt.rc b/dlls/cryptdlg/cryptdlg_Lt.rc deleted file mode 100644 index 74ef2937baf..00000000000 --- a/dlls/cryptdlg/cryptdlg_Lt.rc +++ /dev/null @@ -1,41 +0,0 @@ -/* - * cryptdlg dll Lithuanian resources - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "cryptres.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_CERT_POLICY "Liudijimo politika" - IDS_POLICY_ID "Politikos identifikatorius: " - IDS_POLICY_QUALIFIER_INFO "Politikos kvalifikatoriaus informacija" - IDS_POLICY_QUALIFIER_ID "Politikos kvalifikatoriaus identifikatorius=" - IDS_CPS "Sertifikavimo Veiklos Nuostatos (CPS)" - IDS_USER_NOTICE "Naudotojo pranešimas" - IDS_QUALIFIER "Kvalifikatorius" - IDS_NOTICE_REF "Pranešimo nuoroda" - IDS_ORGANIZATION "Organizacija=" - IDS_NOTICE_NUM "Pranešimo numeris=" - IDS_NOTICE_TEXT "Pranešimo tekstas=" -} diff --git a/dlls/cryptdlg/cryptdlg_Nl.rc b/dlls/cryptdlg/cryptdlg_Nl.rc index 3e8aca0d11a..27b09357eb0 100644 --- a/dlls/cryptdlg/cryptdlg_Nl.rc +++ b/dlls/cryptdlg/cryptdlg_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptres.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/cryptdlg/cryptdlg_Pt.rc b/dlls/cryptdlg/cryptdlg_Pt.rc deleted file mode 100644 index 92d179cd5cd..00000000000 --- a/dlls/cryptdlg/cryptdlg_Pt.rc +++ /dev/null @@ -1,40 +0,0 @@ -/* - * cryptdlg dll Portuguese resources - * - * Copyright 2008 Ricardo Filipe - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "cryptres.h" - -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE - -STRINGTABLE DISCARDABLE -{ - IDS_CERT_POLICY "Política de Certificados" - IDS_POLICY_ID "Identificador da Política: " - IDS_POLICY_QUALIFIER_INFO "Informação do Qualificador da Política" - IDS_POLICY_QUALIFIER_ID "ID do Qualificador da Política=" - IDS_CPS "CPS" /* Certification Practice Statement */ - IDS_USER_NOTICE "Aviso ao Utilizador" - IDS_QUALIFIER "Qualificador" - IDS_NOTICE_REF "Referência do Aviso" - IDS_ORGANIZATION "Organização=" - IDS_NOTICE_NUM "Número do Aviso=" - IDS_NOTICE_TEXT "Texto do Aviso=" -} diff --git a/dlls/cryptdlg/cryptdlg_Ro.rc b/dlls/cryptdlg/cryptdlg_Ro.rc deleted file mode 100644 index 17b60e0ef5c..00000000000 --- a/dlls/cryptdlg/cryptdlg_Ro.rc +++ /dev/null @@ -1,41 +0,0 @@ -/* - * cryptdlg dll Romanian resources - * - * Copyright 2009 Paul Chitescu - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "cryptres.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_CERT_POLICY "Politica certificatului" - IDS_POLICY_ID "Identificatorul politicii: " - IDS_POLICY_QUALIFIER_INFO "Informația calificatorului politicii" - IDS_POLICY_QUALIFIER_ID "Identificatorul calificatorului politicii=" - IDS_CPS "CPS" - IDS_USER_NOTICE "Notiță utilizator" - IDS_QUALIFIER "Calificator" - IDS_NOTICE_REF "Referința notiței" - IDS_ORGANIZATION "Organizația=" - IDS_NOTICE_NUM "Numărul notiței=" - IDS_NOTICE_TEXT "Textul notiței=" -} diff --git a/dlls/cryptdlg/cryptres.h b/dlls/cryptdlg/cryptres.h index 4d3c2d2ffb3..b64459aca78 100644 --- a/dlls/cryptdlg/cryptres.h +++ b/dlls/cryptdlg/cryptres.h @@ -18,8 +18,6 @@ #ifndef __CRYPTRES_H__ #define __CRYPTRES_H__ -#include - #define IDS_CERT_POLICY 100 #define IDS_POLICY_ID 101 #define IDS_POLICY_QUALIFIER_INFO 102 diff --git a/dlls/cryptnet/cryptnet_main.c b/dlls/cryptnet/cryptnet_main.c index 9301a56733b..83346a0bbd2 100644 --- a/dlls/cryptnet/cryptnet_main.c +++ b/dlls/cryptnet/cryptnet_main.c @@ -608,7 +608,7 @@ static BOOL CRYPT_DownloadObject(DWORD dwRetrievalFlags, HINTERNET hHttp, * creates a new cache entry for the object and writes the object to it. * Sets the expiration time of the cache entry to expires. */ -static void CRYPT_CacheURL(LPCWSTR pszURL, const CRYPT_BLOB_ARRAY *pObject, +static void CRYPT_CacheURL(LPCWSTR pszURL, PCRYPT_BLOB_ARRAY pObject, DWORD dwRetrievalFlags, FILETIME expires) { WCHAR cacheFileName[MAX_PATH]; @@ -692,7 +692,7 @@ static void CALLBACK CRYPT_InetStatusCallback(HINTERNET hInt, } } -static BOOL CRYPT_Connect(const URL_COMPONENTSW *components, +static BOOL CRYPT_Connect(URL_COMPONENTSW *components, struct InetContext *context, PCRYPT_CREDENTIALS pCredentials, HINTERNET *phInt, HINTERNET *phHost) { @@ -1049,7 +1049,7 @@ static BOOL CRYPT_GetRetrieveFunction(LPCWSTR pszURL, } static BOOL WINAPI CRYPT_CreateBlob(LPCSTR pszObjectOid, - DWORD dwRetrievalFlags, const CRYPT_BLOB_ARRAY *pObject, void **ppvContext) + DWORD dwRetrievalFlags, PCRYPT_BLOB_ARRAY pObject, void **ppvContext) { DWORD size, i; CRYPT_BLOB_ARRAY *context; @@ -1086,7 +1086,7 @@ static BOOL WINAPI CRYPT_CreateBlob(LPCSTR pszObjectOid, typedef BOOL (WINAPI *AddContextToStore)(HCERTSTORE hCertStore, const void *pContext, DWORD dwAddDisposition, const void **ppStoreContext); -static BOOL CRYPT_CreateContext(const CRYPT_BLOB_ARRAY *pObject, +static BOOL CRYPT_CreateContext(PCRYPT_BLOB_ARRAY pObject, DWORD dwExpectedContentTypeFlags, AddContextToStore addFunc, void **ppvContext) { BOOL ret = TRUE; @@ -1142,28 +1142,28 @@ static BOOL CRYPT_CreateContext(const CRYPT_BLOB_ARRAY *pObject, } static BOOL WINAPI CRYPT_CreateCert(LPCSTR pszObjectOid, - DWORD dwRetrievalFlags, const CRYPT_BLOB_ARRAY *pObject, void **ppvContext) + DWORD dwRetrievalFlags, PCRYPT_BLOB_ARRAY pObject, void **ppvContext) { return CRYPT_CreateContext(pObject, CERT_QUERY_CONTENT_FLAG_CERT, (AddContextToStore)CertAddCertificateContextToStore, ppvContext); } static BOOL WINAPI CRYPT_CreateCRL(LPCSTR pszObjectOid, - DWORD dwRetrievalFlags, const CRYPT_BLOB_ARRAY *pObject, void **ppvContext) + DWORD dwRetrievalFlags, PCRYPT_BLOB_ARRAY pObject, void **ppvContext) { return CRYPT_CreateContext(pObject, CERT_QUERY_CONTENT_FLAG_CRL, (AddContextToStore)CertAddCRLContextToStore, ppvContext); } static BOOL WINAPI CRYPT_CreateCTL(LPCSTR pszObjectOid, - DWORD dwRetrievalFlags, const CRYPT_BLOB_ARRAY *pObject, void **ppvContext) + DWORD dwRetrievalFlags, PCRYPT_BLOB_ARRAY pObject, void **ppvContext) { return CRYPT_CreateContext(pObject, CERT_QUERY_CONTENT_FLAG_CTL, (AddContextToStore)CertAddCTLContextToStore, ppvContext); } static BOOL WINAPI CRYPT_CreatePKCS7(LPCSTR pszObjectOid, - DWORD dwRetrievalFlags, const CRYPT_BLOB_ARRAY *pObject, void **ppvContext) + DWORD dwRetrievalFlags, PCRYPT_BLOB_ARRAY pObject, void **ppvContext) { BOOL ret; @@ -1187,7 +1187,7 @@ static BOOL WINAPI CRYPT_CreatePKCS7(LPCSTR pszObjectOid, } static BOOL WINAPI CRYPT_CreateAny(LPCSTR pszObjectOid, - DWORD dwRetrievalFlags, const CRYPT_BLOB_ARRAY *pObject, void **ppvContext) + DWORD dwRetrievalFlags, PCRYPT_BLOB_ARRAY pObject, void **ppvContext) { BOOL ret; @@ -1273,7 +1273,7 @@ static BOOL WINAPI CRYPT_CreateAny(LPCSTR pszObjectOid, } typedef BOOL (WINAPI *ContextDllCreateObjectContext)(LPCSTR pszObjectOid, - DWORD dwRetrievalFlags, const CRYPT_BLOB_ARRAY *pObject, void **ppvContext); + DWORD dwRetrievalFlags, PCRYPT_BLOB_ARRAY pObject, void **ppvContext); static BOOL CRYPT_GetCreateFunction(LPCSTR pszObjectOid, ContextDllCreateObjectContext *pFunc, HCRYPTOIDFUNCADDR *phFunc) @@ -1322,10 +1322,10 @@ static BOOL CRYPT_GetCreateFunction(LPCSTR pszObjectOid, return ret; } -typedef BOOL (*get_object_expiration_func)(const void *pvContext, +typedef BOOL (*get_object_expiration_func)(void *pvContext, FILETIME *expiration); -static BOOL CRYPT_GetExpirationFromCert(const void *pvObject, FILETIME *expiration) +static BOOL CRYPT_GetExpirationFromCert(void *pvObject, FILETIME *expiration) { PCCERT_CONTEXT cert = pvObject; @@ -1333,7 +1333,7 @@ static BOOL CRYPT_GetExpirationFromCert(const void *pvObject, FILETIME *expirati return TRUE; } -static BOOL CRYPT_GetExpirationFromCRL(const void *pvObject, FILETIME *expiration) +static BOOL CRYPT_GetExpirationFromCRL(void *pvObject, FILETIME *expiration) { PCCRL_CONTEXT cert = pvObject; @@ -1341,7 +1341,7 @@ static BOOL CRYPT_GetExpirationFromCRL(const void *pvObject, FILETIME *expiratio return TRUE; } -static BOOL CRYPT_GetExpirationFromCTL(const void *pvObject, FILETIME *expiration) +static BOOL CRYPT_GetExpirationFromCTL(void *pvObject, FILETIME *expiration) { PCCTL_CONTEXT cert = pvObject; diff --git a/dlls/cryptui/Makefile.in b/dlls/cryptui/Makefile.in index d859f46db08..ca01d354c34 100644 --- a/dlls/cryptui/Makefile.in +++ b/dlls/cryptui/Makefile.in @@ -10,15 +10,7 @@ IMPORTLIB = cryptui C_SRCS = \ main.c -RC_SRCS = \ - cryptui.rc \ - cryptui_De.rc \ - cryptui_En.rc \ - cryptui_Fr.rc \ - cryptui_Ko.rc \ - cryptui_Lt.rc \ - cryptui_Nl.rc \ - cryptui_Pt.rc +RC_SRCS = cryptui.rc @MAKE_DLL_RULES@ diff --git a/dlls/cryptui/cryptui.rc b/dlls/cryptui/cryptui.rc index 00d490273ef..ef998f883e9 100644 --- a/dlls/cryptui/cryptui.rc +++ b/dlls/cryptui/cryptui.rc @@ -17,6 +17,11 @@ * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "commctrl.h" +#include "dlgs.h" #include "cryptuires.h" @@ -40,3 +45,8 @@ IDB_CERT_WATERMARK BITMAP LOADONCALL DISCARDABLE certwatermark.bmp /* @makedep: certheader.bmp */ IDB_CERT_HEADER BITMAP LOADONCALL DISCARDABLE certheader.bmp + +#include "cryptui_De.rc" +#include "cryptui_En.rc" +#include "cryptui_Ko.rc" +#include "cryptui_Nl.rc" diff --git a/dlls/cryptui/cryptui_De.rc b/dlls/cryptui/cryptui_De.rc index d34d88332cc..dcd7ac8e443 100644 --- a/dlls/cryptui/cryptui_De.rc +++ b/dlls/cryptui/cryptui_De.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptuires.h" - #pragma code_page(65001) LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL @@ -463,3 +461,5 @@ BEGIN LVS_REPORT|LVS_NOCOLUMNHEADER|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, 115,67,174,100 END + +#pragma code_page(default) diff --git a/dlls/cryptui/cryptui_En.rc b/dlls/cryptui/cryptui_En.rc index 5aee197a5f0..b10e1015522 100644 --- a/dlls/cryptui/cryptui_En.rc +++ b/dlls/cryptui/cryptui_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptuires.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE @@ -285,16 +283,16 @@ CAPTION "Certificate Import Wizard" FONT 8, "MS Shell Dlg" BEGIN LTEXT "Welcome to the Certificate Import Wizard", IDC_IMPORT_TITLE, - 115,7,195,12 + 115,1,195,40 LTEXT "This wizard helps you import certificates, certificate revocation lists, and certificate trust lists from a file to a certificate store.", - -1, 115,26,195,25 + -1, 115,33,195,16 LTEXT "A certificate can be used to identify you or the computer with which you are communicating. It can also be used for authentication, and to sign messages. Certificate stores are collections of certificates, certificate revocation lists, and certificate trust lists.", -1, 115,56,195,40 LTEXT "To continue, click Next.", -1, 115,103,195,8 END -IDD_IMPORT_FILE DIALOG DISCARDABLE 0,0,317,178 +IDD_IMPORT_FILE DIALOG DISCARDABLE 0,0,317,143 CAPTION "Certificate Import Wizard" FONT 8, "MS Shell Dlg" BEGIN @@ -325,7 +323,7 @@ BEGIN PUSHBUTTON "B&rowse...", IDC_IMPORT_BROWSE_STORE, 236,49,60,14 END -IDD_IMPORT_FINISH DIALOG DISCARDABLE 0,0,317,178 +IDD_IMPORT_FINISH DIALOG DISCARDABLE 0,0,317,143 CAPTION "Certificate Import Wizard" FONT 8, "MS Shell Dlg" BEGIN @@ -381,9 +379,9 @@ CAPTION "Certificate Export Wizard" FONT 8, "MS Shell Dlg" BEGIN LTEXT "Welcome to the Certificate Export Wizard", IDC_EXPORT_TITLE, - 115,7,195,12 + 115,1,195,40 LTEXT "This wizard helps you export certificates, certificate revocation lists, and certificate trust lists from a certificate store to a file.", - -1, 115,26,195,25 + -1, 115,33,195,16 LTEXT "A certificate can be used to identify you or the computer with which you are communicating. It can also be used for authentication, and to sign messages. Certificate stores are collections of certificates, certificate revocation lists, and certificate trust lists.", -1, 115,56,195,40 LTEXT "To continue, click Next.", @@ -394,8 +392,8 @@ IDD_EXPORT_PRIVATE_KEY DIALOG DISCARDABLE 0,0,317,143 CAPTION "Certificate Export Wizard" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "If you choose to export the private key, you will be prompted for a password to protect the private key on a later page.", -1, 21,1,195,25 - LTEXT "Do you wish to export the private key?", -1, 21,27,195,10 + LTEXT "If you choose to export the private key, you will be prompted for a password to protect the private key on a later page.", -1, 21,1,195,23 + LTEXT "Do you wish to export the private key?", -1, 21,24,195,15 AUTORADIOBUTTON "&Yes, export the private key", IDC_EXPORT_PRIVATE_KEY_YES, 31,36,200,12, BS_AUTORADIOBUTTON|WS_TABSTOP AUTORADIOBUTTON "N&o, do not export the private key", @@ -419,22 +417,22 @@ FONT 8, "MS Shell Dlg" BEGIN LTEXT "Select the format you want to use:", -1, 21,1,195,10 AUTORADIOBUTTON "&DER-encoded X.509 (.cer)", - IDC_EXPORT_FORMAT_DER, 31,18,240,12, BS_AUTORADIOBUTTON|WS_TABSTOP + IDC_EXPORT_FORMAT_DER, 31,18,200,12, BS_AUTORADIOBUTTON|WS_TABSTOP AUTORADIOBUTTON "Ba&se64-encoded X.509 (.cer):", - IDC_EXPORT_FORMAT_BASE64, 31,30,240,12, BS_AUTORADIOBUTTON + IDC_EXPORT_FORMAT_BASE64, 31,30,200,12, BS_AUTORADIOBUTTON AUTORADIOBUTTON "&Cryptographic Message Syntax Standard/PKCS #7 Message (.p7b)", - IDC_EXPORT_FORMAT_CMS, 31,42,240,12, BS_AUTORADIOBUTTON + IDC_EXPORT_FORMAT_CMS, 31,42,200,12, BS_AUTORADIOBUTTON CHECKBOX "&Include all certificates in the certification path if possible", - IDC_EXPORT_CMS_INCLUDE_CHAIN, 44,57,240,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED + IDC_EXPORT_CMS_INCLUDE_CHAIN, 44,57,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED AUTORADIOBUTTON "&Personal Information Exchange/PKCS #12 (.pfx)", - IDC_EXPORT_FORMAT_PFX, 31,72,240,12, BS_AUTORADIOBUTTON|WS_DISABLED + IDC_EXPORT_FORMAT_PFX, 31,72,200,12, BS_AUTORADIOBUTTON|WS_DISABLED CHECKBOX "Incl&ude all certificates in the certification path if possible", - IDC_EXPORT_PFX_INCLUDE_CHAIN, 44,87,240,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED + IDC_EXPORT_PFX_INCLUDE_CHAIN, 44,87,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED CHECKBOX "&Enable strong encryption", - IDC_EXPORT_PFX_STRONG_ENCRYPTION, 44,102,240,8, + IDC_EXPORT_PFX_STRONG_ENCRYPTION, 44,102,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED CHECKBOX "Delete the private &key if the export is successful", - IDC_EXPORT_PFX_DELETE_PRIVATE_KEY, 44,117,240,8, + IDC_EXPORT_PFX_DELETE_PRIVATE_KEY, 44,117,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED END @@ -447,7 +445,7 @@ BEGIN PUSHBUTTON "B&rowse...", IDC_EXPORT_BROWSE_FILE, 236,11,60,14 END -IDD_EXPORT_FINISH DIALOG DISCARDABLE 0,0,317,178 +IDD_EXPORT_FINISH DIALOG DISCARDABLE 0,0,317,143 CAPTION "Certificate Export Wizard" FONT 8, "MS Shell Dlg" BEGIN diff --git a/dlls/cryptui/cryptui_Fr.rc b/dlls/cryptui/cryptui_Fr.rc deleted file mode 100644 index 457aae82cd5..00000000000 --- a/dlls/cryptui/cryptui_Fr.rc +++ /dev/null @@ -1,466 +0,0 @@ -/* - * cryptui dll French resources - * - * Copyright 2009 Frédéric Delanoy - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "cryptuires.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_CERTIFICATE "Certificat" - IDS_CERTIFICATEINFORMATION "Informations sur le certificat" - IDS_CERT_INFO_BAD_SIG "Ce certificat a une signature invalide. Le certificat peut avoir été modifié ou corrompu." - IDS_CERT_INFO_UNTRUSTED_CA "Ce certificat racine n'est pas approuvé. Pour lui faire confiance, ajoutez-le au magasin de certificats racine de confiance de votre système." - IDS_CERT_INFO_UNTRUSTED_ROOT "Ce certificat n'a pu être validé par un certificat racine de confiance." - IDS_CERT_INFO_PARTIAL_CHAIN "L'émetteur de ce certificat n'a pas été trouvé." - IDS_CERT_INFO_BAD_PURPOSES "Impossible de vérifier tous les rôles prévus pour ce certificat." - IDS_CERT_INFO_PURPOSES "Ce certificat n'est prévu que pour les rôles suivants :" - IDS_SUBJECT_HEADING "Émis pour : " - IDS_ISSUER_HEADING "Émis par : " - IDS_VALID_FROM "Valide à partir du " - IDS_VALID_TO " jusqu'au " - IDS_CERTIFICATE_BAD_SIGNATURE "Ce certificat a une signature invalide." - IDS_CERTIFICATE_BAD_TIME "Ce certificat a expiré ou n'est pas encore valable." - IDS_CERTIFICATE_BAD_TIMENEST "La période de validité de ce certificat dépasse celle de son émetteur." - IDS_CERTIFICATE_REVOKED "Ce certificat a été révoqué par son émetteur." - IDS_CERTIFICATE_VALID "Ce certificat est valide." - IDS_FIELD "Champ" - IDS_VALUE "Valeur" - IDS_FIELDS_ALL "" - IDS_FIELDS_V1 "Champs de version 1 uniquement" - IDS_FIELDS_EXTENSIONS "Extensions uniquement" - IDS_FIELDS_CRITICAL_EXTENSIONS "Extensions critiques uniquement" - IDS_FIELDS_PROPERTIES "Propriétés uniquement" - IDS_FIELD_VERSION "Version" - IDS_FIELD_SERIAL_NUMBER "Numéro de série" - IDS_FIELD_ISSUER "Émetteur" - IDS_FIELD_VALID_FROM "Valide à partir du" - IDS_FIELD_VALID_TO "Valide jusqu'au" - IDS_FIELD_SUBJECT "Sujet" - IDS_FIELD_PUBLIC_KEY "Clé publique" - IDS_FIELD_PUBLIC_KEY_FORMAT "%s (%d bits)" - IDS_PROP_HASH "Empreinte SHA1" - IDS_PROP_ENHKEY_USAGE "Utilisation complémentaire de la clé (propriété)" - IDS_PROP_FRIENDLY_NAME "Nom convivial" - IDS_PROP_DESCRIPTION "Description" - IDS_CERTIFICATE_PROPERTIES "Propriétés du certificat" - IDS_CERTIFICATE_PURPOSE_ERROR "Veuillez entrer l'OID sous la forme 1.2.3.4" - IDS_CERTIFICATE_PURPOSE_EXISTS "L'OID que vous avez entré existe déjà." - IDS_SELECT_STORE_TITLE "Sélectionnez le magasin de certificats" - IDS_SELECT_STORE "Veuillez sélectionner un magasin de certificats." - IDS_IMPORT_WIZARD "Assistant d'importation de certificats" - IDS_IMPORT_TYPE_MISMATCH "Le fichier contient des objets ne satisfaisant pas aux critères spécifiés. Veuillez sélectionner un autre fichier." - IDS_IMPORT_FILE_TITLE "Fichier à importer" - IDS_IMPORT_FILE_SUBTITLE "Spécifiez le fichier à importer." - IDS_IMPORT_STORE_TITLE "Magasin de certificats" - IDS_IMPORT_STORE_SUBTITLE "Les magasins de certificats sont des collections de certificats, de listes de révocation de certificats et de listes de certificats de confiance." - IDS_IMPORT_FILTER_CERT "Certificat X.509 (*.cer ; *.crt)" - IDS_IMPORT_FILTER_PFX "Échange d'informations personnelles (*.pfx ; *.p12)" - IDS_IMPORT_FILTER_CRL "Liste de révocation de certificats (*.crl)" - IDS_IMPORT_FILTER_CTL "Liste de certificats de confiance (*.stl)" - IDS_IMPORT_FILTER_SERIALIZED_STORE "Magasin de certificats sérialisés Microsoft (*.sst)" - IDS_IMPORT_FILTER_CMS "Messages CMS/PKCS #7 (*.spc ; *.p7b)" - IDS_IMPORT_FILTER_ALL "Tous les fichiers (*.*)" - IDS_IMPORT_EMPTY_FILE "Sélectionnez un fichier." - IDS_IMPORT_BAD_FORMAT "Le format du fichier n'est pas reconnu. Sélectionnez un autre fichier." - IDS_IMPORT_OPEN_FAILED "N'a pu ouvrir " - IDS_IMPORT_DEST_DETERMINED "Déterminé par le programme" - IDS_IMPORT_SELECT_STORE "Veuillez sélectionner un magasin" - IDS_IMPORT_STORE_SELECTION "Magasin de certificats sélectionné" - IDS_IMPORT_DEST_AUTOMATIC "Déterminé automatiquement par le programme" - IDS_IMPORT_FILE "Fichier" - IDS_IMPORT_CONTENT "Contenu" - IDS_IMPORT_CONTENT_CERT "Certificat" - IDS_IMPORT_CONTENT_CRL "Liste de révocation de certificats" - IDS_IMPORT_CONTENT_CTL "Liste de certificats de confiance" - IDS_IMPORT_CONTENT_CMS "Message CMS/PKCS #7" - IDS_IMPORT_CONTENT_PFX "Échange d'informations personnelles" - IDS_IMPORT_CONTENT_STORE "Magasin de certificats" - IDS_IMPORT_SUCCEEDED "L'importation a réussi." - IDS_IMPORT_FAILED "L'importation a échoué." - IDS_WIZARD_TITLE_FONT "Arial" - IDS_PURPOSE_ALL "" - IDS_PURPOSE_ADVANCED "" - IDS_SUBJECT_COLUMN "Émis pour" - IDS_ISSUER_COLUMN "Émis par" - IDS_EXPIRATION_COLUMN "Date d'expiration" - IDS_FRIENDLY_NAME_COLUMN "Nom convivial" - IDS_ALLOWED_PURPOSE_ALL "" - IDS_ALLOWED_PURPOSE_NONE "" - IDS_WARN_REMOVE_MY "Vous ne pourrez plus déchiffrer ou signer de messages avec ce certificat.\nVoulez-vous réellement supprimer ce certificat ?" - IDS_WARN_REMOVE_PLURAL_MY "Vous ne pourrez plus déchiffrer ou signer de messages avec ces certificats.\nVoulez-vous réellement supprimer ces certificats ?" - IDS_WARN_REMOVE_ADDRESSBOOK "Vous ne pourrez plus chiffrer ou vérifier de signature de messages avec ce certificat.\nVoulez-vous réellement supprimer ce certificat ?" - IDS_WARN_REMOVE_PLURAL_ADDRESSBOOK "Vous ne pourrez plus chiffrer ou vérifier de signature de messages avec ces certificats.\nVoulez-vous réellement supprimer ces certificats ?" - IDS_WARN_REMOVE_CA "Les certificats émis par cette autorité de certification ne seront plus considérés comme valables.\nVoulez-vous réellement supprimer ce certificat ?" - IDS_WARN_REMOVE_PLURAL_CA "Les certificats émis par cette autorité de certification ne seront plus considérés comme valables.\nVoulez-vous réellement supprimer ces certificats ?" - IDS_WARN_REMOVE_ROOT "Les certificats émis par cette autorité de certification racine, ou par toute autorité de certification qu'elle valide, ne seront plus considérés comme valables.\nVoulez-vous réellement supprimer ce certificat racine de confiance ?" - IDS_WARN_REMOVE_PLURAL_ROOT "Les certificats émis par ces autorités de certification racines, ou par toute autorité de certification qu'elles valident, ne seront plus considérés comme valables.\nVoulez-vous réellement supprimer ces certificats racines de confiance ?" - IDS_WARN_REMOVE_TRUSTEDPUBLISHER "Les logiciels signés par cet éditeur ne seront plus considérés comme valables.\nVoulez-vous réellement supprimer ce certificat ?" - IDS_WARN_REMOVE_PLURAL_TRUSTEDPUBLISHER "Les logiciels signés par ces éditeurs ne seront plus considérés comme valables.\nVoulez-vous réellement supprimer ces certificats ?" - IDS_WARN_REMOVE_DEFAULT "Voulez-vous réellement supprimer ce certificat ?" - IDS_WARN_REMOVE_PLURAL_DEFAULT "Voulez-vous réellement supprimer ces certificats ?" - IDS_CERT_MGR "Certificats" - IDS_PURPOSE_SERVER_AUTH "Prouve l'identité d'un ordinateur distant" - IDS_PURPOSE_CLIENT_AUTH "Prouve votre identité à un ordinateur distant" - IDS_PURPOSE_CODE_SIGNING "Garantit que des logiciels proviennent bien d'un éditeur de logiciels donné\nProtège le logiciel contre toute altération après publication" - IDS_PURPOSE_EMAIL_PROTECTION "Protège les courriers électroniques" - IDS_PURPOSE_IPSEC "Permet des communications sécurisées sur Internet" - IDS_PURPOSE_TIMESTAMP_SIGNING "Permet de signer des données avec l'heure courante" - IDS_PURPOSE_CTL_USAGE_SIGNING "Permet de signer numériquement une liste de certificats de confiance" - IDS_PURPOSE_EFS "Permet le chiffrement de données sur disque" - IDS_PURPOSE_EFS_RECOVERY "Restauration de fichier" - IDS_PURPOSE_WHQL "Vérification des pilotes matériels de Windows" - IDS_PURPOSE_NT5 "Vérification des composants système de Windows" - IDS_PURPOSE_OEM_WHQL "Vérification des composants système de Windows OEM" - IDS_PURPOSE_EMBEDDED_NT "Vérification des composants système de Windows embarqué" - IDS_PURPOSE_ROOT_LIST_SIGNER "Signataire de la liste racine" - IDS_PURPOSE_QUALIFIED_SUBORDINATION "Subordination conditionnelle" - IDS_PURPOSE_KEY_RECOVERY "Recouvrement de clé" - IDS_PURPOSE_DOCUMENT_SIGNING "Signature de documents" - IDS_PURPOSE_LIFETIME_SIGNING "Signature à vie" - IDS_PURPOSE_DRM "Droits numériques" - IDS_PURPOSE_LICENSES "Licences de jeux de clés" - IDS_PURPOSE_LICENSE_SERVER "Vérification du serveur de licences" - IDS_PURPOSE_ENROLLMENT_AGENT "Agent de demande de certificat" - IDS_PURPOSE_SMARTCARD_LOGON "Connexion avec carte à puce" - IDS_PURPOSE_CA_EXCHANGE "Archivage de clé privée" - IDS_PURPOSE_KEY_RECOVERY_AGENT "Agent de recouvrement de clé" - IDS_PURPOSE_DS_EMAIL_REPLICATION "Réplication de courriers électroniques du service d'annuaire" - IDS_EXPORT_WIZARD "Assistant Exportation de certificats" - IDS_EXPORT_FORMAT_TITLE "Format d'export" - IDS_EXPORT_FORMAT_SUBTITLE "Choisissez le format dans lequel le contenu sera sauvé." - IDS_EXPORT_FILE_TITLE "Nom du fichier à exporter" - IDS_EXPORT_FILE_SUBTITLE "Choisissez le nom du fichier dans lequel le contenu sera sauvé." - IDS_EXPORT_FILE_EXISTS "Le fichier spécifié existe déjà. Voulez-vous le remplacer ?" - IDS_EXPORT_FILTER_CERT "Binaire codé DER X.509 (*.cer)" - IDS_EXPORT_FILTER_BASE64_CERT "Binaire codé Base64 X.509 (*.cer)" - IDS_EXPORT_FILTER_CRL "Liste de révocation de certificats (*.crl)" - IDS_EXPORT_FILTER_CTL "Liste de certificats de confiance (*.stl)" - IDS_EXPORT_FILTER_CMS "Messages CMS/PKCS #7 (*.p7b)" - IDS_EXPORT_FILTER_PFX "Échange d'informations personnelles (*.pfx)" - IDS_EXPORT_FILTER_SERIALIZED_CERT_STORE "Magasin de certificats sérialisés (*.sst)" - IDS_EXPORT_FORMAT "Format de fichier" - IDS_EXPORT_INCLUDE_CHAIN "Inclure tous les certificats dans le chemin de certification" - IDS_EXPORT_KEYS "Exporter des clés" - IDS_YES "Oui" - IDS_NO "Non" - IDS_EXPORT_SUCCEEDED "L'export a réussi." - IDS_EXPORT_FAILED "L'export a échoué." - IDS_EXPORT_PRIVATE_KEY_TITLE "Exporter la clé privée" - IDS_EXPORT_PRIVATE_KEY_SUBTITLE "Le certificat contient une clé privée qui peut être exportée avec le certificat." - IDS_EXPORT_PASSWORD_TITLE "Entrez le mot de passe" - IDS_EXPORT_PASSWORD_SUBTITLE "Vous pouvez protéger une clé privée par un mot de passe." - IDS_EXPORT_PASSWORD_MISMATCH "Les mots de passe ne correspondent pas." - IDS_EXPORT_PRIVATE_KEY_UNAVAILABLE "Note : la clé privée de ce certificat n'a pu être ouverte." - IDS_EXPORT_PRIVATE_KEY_NON_EXPORTABLE "Note : la clé privée de ce certificat n'est pas exportable." -} - -IDD_GENERAL DIALOG DISCARDABLE 0, 0, 255, 236 -CAPTION "Général" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "", -1, "Static", WS_BORDER|SS_WHITERECT, 6,10,241,200 - CONTROL "", IDC_CERTIFICATE_ICON,"RichEdit20W", - ES_READONLY|WS_DISABLED,8,11,26,26 - CONTROL "", IDC_CERTIFICATE_INFO,"RichEdit20W", - ES_READONLY|WS_DISABLED,34,11,212,26 - CONTROL "", -1, "Static", SS_BLACKFRAME, 16,37,222,1 - CONTROL "", IDC_CERTIFICATE_STATUS,"RichEdit20W", - ES_READONLY|ES_MULTILINE,8,38,238,78 - CONTROL "", -1, "Static", SS_BLACKFRAME, 16,116,222,1 - CONTROL "", IDC_CERTIFICATE_NAMES,"RichEdit20W", - ES_READONLY|ES_MULTILINE|WS_DISABLED,8,118,238,90 - PUSHBUTTON "&Installer un certificat...", IDC_ADDTOSTORE,73,216,86,14 - PUSHBUTTON "&Déclaration de l'émetteur", IDC_ISSUERSTATEMENT,161,216,86,14 -END - -IDD_DETAIL DIALOG DISCARDABLE 0, 0, 255, 236 -CAPTION "Détails" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Afficher :", -1, 6,11,33,14 - COMBOBOX IDC_DETAIL_SELECT, 39,10,100,14, - CBS_DROPDOWNLIST|WS_BORDER|WS_VSCROLL|WS_TABSTOP - CONTROL "", IDC_DETAIL_LIST, "SysListView32", - LVS_REPORT|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 6,28,241,100 - CONTROL "", IDC_DETAIL_VALUE, "RichEdit20W", - ES_READONLY|ES_MULTILINE|WS_TABSTOP, 6,136,241,70 - PUSHBUTTON "É&diter les propriétés...", IDC_EDITPROPERTIES,83,216,80,14 - PUSHBUTTON "&Copier dans le fichier...", IDC_EXPORT,167,216,80,14 -END - -IDD_HIERARCHY DIALOG DISCARDABLE 0, 0, 255, 236 -CAPTION "Chemin de certification" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "Chemin de &certification", -1,6,10,245,165, BS_GROUPBOX - CONTROL "",IDC_CERTPATH, "SysTreeView32", TVS_HASLINES|WS_BORDER, - 13,22,231,130 - PUSHBUTTON "&Voir le certificat", IDC_VIEWCERTIFICATE,175,156,70,14 - LTEXT "É&tat du certificat :", IDC_CERTIFICATESTATUS,6,183,70,14 - CONTROL "", IDC_CERTIFICATESTATUSTEXT,"RichEdit20W", - WS_BORDER|ES_READONLY|ES_MULTILINE|WS_DISABLED,6,195,245,36 -END - -IDD_USERNOTICE DIALOG DISCARDABLE 0, 0, 255, 256 -CAPTION "Avis de non-responsabilité" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "", IDC_USERNOTICE,"RichEdit20W", - WS_BORDER|ES_READONLY|ES_MULTILINE|WS_DISABLED,6,10,241,200 - PUSHBUTTON "Fermer", IDOK,77,216,83,14 - PUSHBUTTON "&Infos complémentaires", IDC_CPS,164,216,83,14 -END - -IDD_CERT_PROPERTIES_GENERAL DIALOG DISCARDABLE 0, 0, 255, 236 -CAPTION "Général" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Nom convivial :", -1, 6,14,60,14 - EDITTEXT IDC_FRIENDLY_NAME, 60,12,191,14, ES_AUTOHSCROLL|WS_TABSTOP - LTEXT "&Description :", -1, 6,32,60,14 - EDITTEXT IDC_DESCRIPTION, 60,30,191,14, ES_AUTOVSCROLL|ES_MULTILINE|WS_TABSTOP|WS_VSCROLL - GROUPBOX "Rôles du certificat", -1,6,48,245,165, BS_GROUPBOX - AUTORADIOBUTTON "Activer &tous les rôles prévus pour ce certificat", - IDC_ENABLE_ALL_PURPOSES, 12,58,180,14, BS_AUTORADIOBUTTON|WS_TABSTOP - AUTORADIOBUTTON "&Désactiver tous les rôles prévus pour ce certificat", - IDC_DISABLE_ALL_PURPOSES, 12,70,180,14, BS_AUTORADIOBUTTON - AUTORADIOBUTTON "N'activer &que les rôles suivants pour ce certificat :", - IDC_ENABLE_SELECTED_PURPOSES, 12,82,180,14, BS_AUTORADIOBUTTON - CONTROL "", IDC_CERTIFICATE_USAGES,"SysListView32", - LVS_REPORT|LVS_NOCOLUMNHEADER|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 24,100,220,90 - PUSHBUTTON "&Ajouter un rôle...", IDC_ADD_PURPOSE,180,194,64,14 -END - -IDD_ADD_CERT_PURPOSE DIALOG DISCARDABLE 0,0,200,68 -CAPTION "Ajouter un rôle" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Adjoindre l'identifiant d'objet (OIS) au rôle de certificat à ajouter :", - -1, 6,6,190,28 - EDITTEXT IDC_NEW_PURPOSE, 6,28,190,14, ES_AUTOVSCROLL|ES_MULTILINE|WS_TABSTOP|WS_VSCROLL - PUSHBUTTON "OK", IDOK, 33,48,60,14 - PUSHBUTTON "Annuler", IDCANCEL, 100,48,60,14 -END - -IDD_SELECT_STORE DIALOG DISCARDABLE 0,0,200,136 -CAPTION "Sélectionner un magasin de certificats" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Sélectionnez le magasin de certificats à utiliser :", IDC_STORE_TEXT, 6,6,190,28 - CONTROL "",IDC_STORE_LIST, "SysTreeView32", TVS_HASLINES|WS_BORDER|WS_TABSTOP, - 6,28,188,70 - CHECKBOX "&Montrer les magasins physiques", IDC_SHOW_PHYSICAL_STORES, 6,102,117,14, - BS_AUTOCHECKBOX|WS_TABSTOP - PUSHBUTTON "OK", IDOK, 90,118,50,14, BS_DEFPUSHBUTTON - PUSHBUTTON "Annuler", IDCANCEL, 144,118,50,14 -END - -IDD_IMPORT_WELCOME DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistant d'importation de certificats" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Bienvenue dans l'assistant d'importation de certificats", IDC_IMPORT_TITLE, - 115,6,195,12 - LTEXT "Cet assistant vous aide à importer des certificats, des listes de révocation de certificats et des listes de certificats de confiance dans un magasin de certificats à partir d'un fichier.", - -1, 115,22,195,25 - LTEXT "Un certificat peut être utilisé pour vous identifier, ou pour identifier l'ordinateur avec lequel vous communiquez. Il peut également être utilisé à des fins d'authentification ou de signature de messages. Les magasins de certificats sont des collections de certificats, de listes de révocation de certificats et de listes de certificats de confiance.", - -1, 115,56,195,49 - LTEXT "Pour continuer, cliquez sur Suivant.", - -1, 115,114,195,8 -END - -IDD_IMPORT_FILE DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistant Importation de certificats" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Nom du fichier :", -1, 21,1,195,10 - EDITTEXT IDC_IMPORT_FILENAME, 21,11,208,14, ES_AUTOHSCROLL|WS_TABSTOP - PUSHBUTTON "Parco&urir...", IDC_IMPORT_BROWSE_FILE, 236,11,60,14 - LTEXT "Remarque : les formats de fichiers suivants peuvent contenir plus d'un certificat, liste de révocation de certificats ou liste de certificats de confiance :", - -1, 21,26,265,16 - LTEXT "Standard de syntaxe de message cryptographique - Messages PKCS #7 (.p7b)", - -1, 31,49,265,10 - LTEXT "Échange d'informations personnelles - PKCS #12 (.pfx, .p12)", - -1, 31,64,265,10 - LTEXT "Magasin de certificats sérialisés Microsoft (.sst)", - -1, 31,79,265,10 -END - -IDD_IMPORT_STORE DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistant Importation de certificats" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Wine peut sélectionner automatiquement un magasin de certificats, ou vous pouvez spécifier l'emplacement des certificats.", - -1, 21,1,212,18 - AUTORADIOBUTTON "Sélectionner &automatiquement un magasin de certificats", - IDC_IMPORT_AUTO_STORE, 31,18,194,12, BS_AUTORADIOBUTTON|WS_TABSTOP - AUTORADIOBUTTON "Placer tous les certificats dans le &magasin suivant :", - IDC_IMPORT_SPECIFY_STORE, 31,30,194,12, BS_AUTORADIOBUTTON - EDITTEXT IDC_IMPORT_STORE, 44,49,185,14, ES_READONLY - PUSHBUTTON "&Parcourir...", IDC_IMPORT_BROWSE_STORE, 236,49,60,14 -END - -IDD_IMPORT_FINISH DIALOG DISCARDABLE 0,0,317,179 -CAPTION "Assistant Importation de certificats" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Clôture de l'assistant d'importation de certificats", IDC_IMPORT_TITLE, - 115,10,195,12 - LTEXT "Vous avez terminé avec succès l'assistant d'importation de certificats.", - -1, 115,31,195,18 - LTEXT "Vous avez spécifié les paramètres suivants :", - -1, 115,57,195,12 - CONTROL "", IDC_IMPORT_SETTINGS, "SysListView32", - LVS_REPORT|LVS_NOCOLUMNHEADER|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 115,67,174,100 -END - -IDD_CERT_MGR DIALOG DISCARDABLE 0,0,335,270 -CAPTION "Certificats" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Rôle prévu :", -1, 7,9,100,12 - COMBOBOX IDC_MGR_PURPOSE_SELECTION, 83,7,245,14, - CBS_DROPDOWNLIST|WS_BORDER|WS_VSCROLL|WS_TABSTOP - CONTROL "", IDC_MGR_STORES, "SysTabControl32", - WS_CLIPSIBLINGS|WS_TABSTOP, 7,25,321,140 - CONTROL "", IDC_MGR_CERTS, "SysListView32", - LVS_REPORT|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, 15,46,305,111 - PUSHBUTTON "&Importer...", IDC_MGR_IMPORT, 7,172,51,14 - PUSHBUTTON "&Exporter...", IDC_MGR_EXPORT, 62,172,51,14, WS_DISABLED - PUSHBUTTON "&Supprimer", IDC_MGR_REMOVE, 117,172,51,14, WS_DISABLED - PUSHBUTTON "&Avancé...", IDC_MGR_ADVANCED, 277,172,51,14 - GROUPBOX "Rôles prévus pour le certificat", -1,7,194,321,47, BS_GROUPBOX - LTEXT "", IDC_MGR_PURPOSES, 13,208,252,30 - PUSHBUTTON "&Détails...", IDC_MGR_VIEW, 269,218,51,14, WS_DISABLED - PUSHBUTTON "&Fermer", IDCANCEL, 277,249,51,14, BS_DEFPUSHBUTTON -END - -IDD_CERT_MGR_ADVANCED DIALOG DISCARDABLE 0,0,248,176 -CAPTION "Options avancées" -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "Rôle du certificat", -1, 7,7,234,141, BS_GROUPBOX - LTEXT "Sélectionnez un ou plusieurs rôles à afficher quand les options avancées sont sélectionnées.", - -1, 14,18,220,16 - LTEXT "&Rôles du certificat :", -1, 14,41,90,12, WS_TABSTOP - CONTROL "", IDC_CERTIFICATE_USAGES,"SysListView32", - LVS_REPORT|LVS_NOCOLUMNHEADER|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 14,51,220,90 - PUSHBUTTON "OK", IDOK, 132,155,51,14, BS_DEFPUSHBUTTON - PUSHBUTTON "Annuler", IDCANCEL, 190,155,51,14 -END - -IDD_EXPORT_WELCOME DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistant d'exportation de certificats" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Bienvenue dans l'assistant d'exportation de certificats", IDC_EXPORT_TITLE, - 115,6,195,12 - LTEXT "Cet assistant vous aide à exporter des certificats, des listes de révocation de certificats et des listes de certificats de confiance dans un fichier à partir d'un magasin de certificats.", - -1, 115,22,195,25 - LTEXT "Un certificat peut être utilisé pour vous identifier, ou pour identifier l'ordinateur avec lequel vous communiquez. Il peut également être utilisé à des fins d'authentification ou de signature de messages. Les magasins de certificats sont des collections de certificats, de listes de révocation de certificats et de listes de certificats de confiance.", - -1, 115,56,195,49 - LTEXT "Pour continuer, cliquez sur Suivant.", - -1, 115,114,195,8 -END - -IDD_EXPORT_PRIVATE_KEY DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistant Exportation de certificats" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Si vous choisissez d'exporter la clé privée, on vous demandera un mot de passe pour protéger la clé privée dans une page ultérieure.", -1, 21,1,195,25 - LTEXT "Voulez-vous exporter la clé privée ?", -1, 21,27,195,10 - AUTORADIOBUTTON "&Oui, exporter la clé privée", - IDC_EXPORT_PRIVATE_KEY_YES, 31,36,200,12, BS_AUTORADIOBUTTON|WS_TABSTOP - AUTORADIOBUTTON "&Non, ne pas exporter la clé privée", - IDC_EXPORT_PRIVATE_KEY_NO, 31,48,200,12, BS_AUTORADIOBUTTON - LTEXT "", IDC_EXPORT_PRIVATE_KEY_UNAVAILABLE, 21,60,200,24 -END - -IDD_EXPORT_PASSWORD DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistant Exportation de certificats" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Mot de passe :", -1, 21,1,195,10 - EDITTEXT IDC_EXPORT_PASSWORD, 21,11,208,14, ES_AUTOHSCROLL|WS_TABSTOP - LTEXT "&Confirmez le mot de passe :", -1, 21,35,195,10 - EDITTEXT IDC_EXPORT_PASSWORD_CONFIRM, 21,45,208,14, ES_AUTOHSCROLL|WS_TABSTOP -END - -IDD_EXPORT_FORMAT DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistant Exportation de certificats" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Sélectionnez le format à utiliser :", -1, 21,1,195,10 - AUTORADIOBUTTON "Binaire codé &DER X.509 (*.cer)", - IDC_EXPORT_FORMAT_DER, 31,18,200,12, BS_AUTORADIOBUTTON|WS_TABSTOP - AUTORADIOBUTTON "Binaire codé Ba&se64 X.509 (.cer) :", - IDC_EXPORT_FORMAT_BASE64, 31,30,200,12, BS_AUTORADIOBUTTON - AUTORADIOBUTTON "Standard de syntaxe de message cryptographique - Messages PKCS #7 (.p7b)", - IDC_EXPORT_FORMAT_CMS, 31,42,200,12, BS_AUTORADIOBUTTON - CHECKBOX "&Inclure tous les certificats dans le chemin de certification si possible" - IDC_EXPORT_CMS_INCLUDE_CHAIN, 44,57,230,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED - AUTORADIOBUTTON "Échange d'informations &Personnelles - PKCS #12 (.pfx)", - IDC_EXPORT_FORMAT_PFX, 31,72,200,12, BS_AUTORADIOBUTTON|WS_DISABLED - CHECKBOX "Inclure &tous les certificats dans le chemin de certification si possible", - IDC_EXPORT_PFX_INCLUDE_CHAIN, 44,87,230,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED - CHECKBOX "&Activer le chiffrement fort", - IDC_EXPORT_PFX_STRONG_ENCRYPTION, 44,102,200,8, - BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED - CHECKBOX "&Effacer la clé privée si l'export a réussi", - IDC_EXPORT_PFX_DELETE_PRIVATE_KEY, 44,117,200,8, - BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED -END - -IDD_EXPORT_FILE DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistant Exportation de certificats" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Nom du fichier :", -1, 21,1,195,10 - EDITTEXT IDC_EXPORT_FILENAME, 21,11,208,14, ES_AUTOHSCROLL|WS_TABSTOP - PUSHBUTTON "Parco&urir...", IDC_EXPORT_BROWSE_FILE, 236,11,60,14 -END - -IDD_EXPORT_FINISH DIALOG DISCARDABLE 0,0,317,179 -CAPTION "Assistant Exportation de certificats" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Clôture de l'assistant d'exportation de certificats", IDC_EXPORT_TITLE, - 115,10,195,12 - LTEXT "Vous avez terminé avec succès l'assistant d'exportation de certificats.", - -1, 115,31,195,18 - LTEXT "Vous avez spécifié les paramètres suivants :", - -1, 115,57,195,12 - CONTROL "", IDC_EXPORT_SETTINGS, "SysListView32", - LVS_REPORT|LVS_NOCOLUMNHEADER|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 115,67,174,100 -END diff --git a/dlls/cryptui/cryptui_Ko.rc b/dlls/cryptui/cryptui_Ko.rc index 2533a4edd01..57e91386bd8 100644 --- a/dlls/cryptui/cryptui_Ko.rc +++ b/dlls/cryptui/cryptui_Ko.rc @@ -19,7 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptuires.h" LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT @@ -404,22 +403,22 @@ FONT 8, "MS Shell Dlg" BEGIN LTEXT "»ç¿ëÇÒ ÆÄÀÏ Çü½Ä ¼±ÅÃ:", -1, 21,1,195,10 AUTORADIOBUTTON "&DER-¾ÏȣȭµÈ X.509 (.cer)", - IDC_EXPORT_FORMAT_DER, 31,18,240,12, BS_AUTORADIOBUTTON|WS_TABSTOP + IDC_EXPORT_FORMAT_DER, 31,18,200,12, BS_AUTORADIOBUTTON|WS_TABSTOP AUTORADIOBUTTON "Ba&se64-¾ÏȣȭµÈ X.509 (.cer):", - IDC_EXPORT_FORMAT_BASE64, 31,30,240,12, BS_AUTORADIOBUTTON + IDC_EXPORT_FORMAT_BASE64, 31,30,200,12, BS_AUTORADIOBUTTON AUTORADIOBUTTON "¾ÏÈ£ ¸Þ½ÃÁö ¹®¹ý Ç¥ÁØ/PKCS #7 ¸Þ½ÃÁö(&C) (.p7b)", - IDC_EXPORT_FORMAT_CMS, 31,42,240,12, BS_AUTORADIOBUTTON + IDC_EXPORT_FORMAT_CMS, 31,42,200,12, BS_AUTORADIOBUTTON CHECKBOX "°¡´ÉÇÑ ÀÎÁõ¼­ °æ·Î¿¡ ÀÖ´Â ¸ðµç ÀÎÁõ¼­ Æ÷ÇÔ(&I)", - IDC_EXPORT_CMS_INCLUDE_CHAIN, 44,57,240,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED + IDC_EXPORT_CMS_INCLUDE_CHAIN, 44,57,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED AUTORADIOBUTTON "°³ÀÎ Á¤º¸ ±³È¯(&P)/PKCS #12 (.pfx)", - IDC_EXPORT_FORMAT_PFX, 31,72,240,12, BS_AUTORADIOBUTTON|WS_DISABLED + IDC_EXPORT_FORMAT_PFX, 31,72,200,12, BS_AUTORADIOBUTTON|WS_DISABLED CHECKBOX "°¡´ÉÇÑ ÀÎÁõ¼­ °æ·Î¿¡ ÀÖ´Â ¸ðµç ÀÎÁõ¼­ Æ÷ÇÔ(&U)", - IDC_EXPORT_PFX_INCLUDE_CHAIN, 44,87,240,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED + IDC_EXPORT_PFX_INCLUDE_CHAIN, 44,87,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED CHECKBOX "°­ÇÑ ¾Ïȣȭ °¡´É(&E)", - IDC_EXPORT_PFX_STRONG_ENCRYPTION, 44,102,240,8, + IDC_EXPORT_PFX_STRONG_ENCRYPTION, 44,102,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED CHECKBOX "³»º¸³»±â°¡ ¼º°øÇÏ¸é °³ÀÎ Å° Áö¿ì±â(&K)", - IDC_EXPORT_PFX_DELETE_PRIVATE_KEY, 44,117,240,8, + IDC_EXPORT_PFX_DELETE_PRIVATE_KEY, 44,117,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED END diff --git a/dlls/cryptui/cryptui_Lt.rc b/dlls/cryptui/cryptui_Lt.rc deleted file mode 100644 index d4ba0eb2608..00000000000 --- a/dlls/cryptui/cryptui_Lt.rc +++ /dev/null @@ -1,466 +0,0 @@ -/* - * cryptui dll resources - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "cryptuires.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_CERTIFICATE "Liudijimas" - IDS_CERTIFICATEINFORMATION "Liudijimo informacija" - IDS_CERT_INFO_BAD_SIG "Šis liudijimas turi neteisingą parašą. Liudijimas galėjo būti pakeistas ar pažeistas." - IDS_CERT_INFO_UNTRUSTED_CA "Šis vyriausiasis liudijimas yra nepatikimas. Norėdami juo pasitikėti įtraukite jį į sistemos patikimų vyriausiųjų liudijimų saugyklą." - IDS_CERT_INFO_UNTRUSTED_ROOT "Nepavyko patvirtinti šio liudijimo pagal patikimą vyriausiąjį liudijimą." - IDS_CERT_INFO_PARTIAL_CHAIN "Nepavyko rasti liudijimo išdavėjo." - IDS_CERT_INFO_BAD_PURPOSES "Nepavyko patikrinti visų šio liudijimo paskirties tikslų." - IDS_CERT_INFO_PURPOSES "Šis liudijimas yra skirtas šiems tikslams:" - IDS_SUBJECT_HEADING "Kam išduota: " - IDS_ISSUER_HEADING "Išdavė: " - IDS_VALID_FROM "Galioja nuo " - IDS_VALID_TO " iki " - IDS_CERTIFICATE_BAD_SIGNATURE "Šis liudijimas turi neteisingą parašą." - IDS_CERTIFICATE_BAD_TIME "Šis liudijimas jau nebegalioja arba dar negalioja." - IDS_CERTIFICATE_BAD_TIMENEST "Šio liudijimo galiojimo periodas yra didesnis už išdavėjo." - IDS_CERTIFICATE_REVOKED "Šis liudijimas buvo panaikintas išdavėjo." - IDS_CERTIFICATE_VALID "Šis liudijimas yra geras." - IDS_FIELD "Laukas" - IDS_VALUE "Reikšmė" - IDS_FIELDS_ALL "" - IDS_FIELDS_V1 "Tik pirmos versijos laukai" - IDS_FIELDS_EXTENSIONS "Tik plėtiniai" - IDS_FIELDS_CRITICAL_EXTENSIONS "Tik būtini plėtiniai" - IDS_FIELDS_PROPERTIES "Tik savybės" - IDS_FIELD_VERSION "Versija" - IDS_FIELD_SERIAL_NUMBER "Numeris" - IDS_FIELD_ISSUER "Išdavėjas" - IDS_FIELD_VALID_FROM "Galioja nuo" - IDS_FIELD_VALID_TO "Galioja iki" - IDS_FIELD_SUBJECT "Subjektas" - IDS_FIELD_PUBLIC_KEY "Viešasis raktas" - IDS_FIELD_PUBLIC_KEY_FORMAT "%s (%d bitai)" - IDS_PROP_HASH "maiša SHA1" - IDS_PROP_ENHKEY_USAGE "Ypatingas rakto naudojimas (savybė)" - IDS_PROP_FRIENDLY_NAME "Draugiškas vardas" - IDS_PROP_DESCRIPTION "Aprašas" - IDS_CERTIFICATE_PROPERTIES "Liudijimo savybės" - IDS_CERTIFICATE_PURPOSE_ERROR "Prašau įveskite organizacijos identifikatorių tokia forma: 1.2.3.4" - IDS_CERTIFICATE_PURPOSE_EXISTS "Įvestas organizacijos identifikatorius jau egzistuoja." - IDS_SELECT_STORE_TITLE "Išrinkite liudijimų saugyklą" - IDS_SELECT_STORE "Prašau išrinkite liudijimų saugyklą." - IDS_IMPORT_WIZARD "Liudijimo importo vediklis" - IDS_IMPORT_TYPE_MISMATCH "Faile yra objektų, kurie neatitinka nustatytų kriterijų. Prašau išrinkite kitą failą." - IDS_IMPORT_FILE_TITLE "Importo failas" - IDS_IMPORT_FILE_SUBTITLE "Nurodykite failą importui." - IDS_IMPORT_STORE_TITLE "Liudijimų saugykla" - IDS_IMPORT_STORE_SUBTITLE "Liudijimų saugyklos yra liudijimų rinkiniai, atšauktų liudijimų sąrašai ir patikintų liudijimų sąrašai." - IDS_IMPORT_FILTER_CERT "X.509 liudijimas (*.cer; *.crt)" - IDS_IMPORT_FILTER_PFX "Asmeninės informacijos mainai (*.pfx; *.p12)" - IDS_IMPORT_FILTER_CRL "Atšauktų liudijimų sąrašas (*.crl)" - IDS_IMPORT_FILTER_CTL "Patikintų liudijimų sąrašas (*.stl)" - IDS_IMPORT_FILTER_SERIALIZED_STORE "Išdėstyta serijomis liudijimų saugykla (*.sst)" - IDS_IMPORT_FILTER_CMS "CMS/PKCS #7 pranešimai (*.spc; *.p7b)" - IDS_IMPORT_FILTER_ALL "Visi failai (*.*)" - IDS_IMPORT_EMPTY_FILE "Prašau išrinkite failą." - IDS_IMPORT_BAD_FORMAT "Neatpažintas failo formatas. Prašau išrinkite kitą failą." - IDS_IMPORT_OPEN_FAILED "Nepavyko atverti " - IDS_IMPORT_DEST_DETERMINED "Nustatyta programos" - IDS_IMPORT_SELECT_STORE "Prašau išrinkite saugyklą" - IDS_IMPORT_STORE_SELECTION "Išrinkta liudijimų saugykla" - IDS_IMPORT_DEST_AUTOMATIC "Automatiškai nustatyta programos" - IDS_IMPORT_FILE "Failas" - IDS_IMPORT_CONTENT "Turinys" - IDS_IMPORT_CONTENT_CERT "Liudijimas" - IDS_IMPORT_CONTENT_CRL "Atšauktų liudijimų sąrašas" - IDS_IMPORT_CONTENT_CTL "Patikintų liudijimų sąrašas" - IDS_IMPORT_CONTENT_CMS "CMS/PKCS #7 pranešimas" - IDS_IMPORT_CONTENT_PFX "Asmeninės informacijos mainai" - IDS_IMPORT_CONTENT_STORE "Liudijimų saugykla" - IDS_IMPORT_SUCCEEDED "Importas sėkmingas." - IDS_IMPORT_FAILED "Importas nepavyko." - IDS_WIZARD_TITLE_FONT "Arial" - IDS_PURPOSE_ALL "" - IDS_PURPOSE_ADVANCED "" - IDS_SUBJECT_COLUMN "Kam išduotas" - IDS_ISSUER_COLUMN "Išdavė" - IDS_EXPIRATION_COLUMN "Galiojimo data" - IDS_FRIENDLY_NAME_COLUMN "Draugiškas vardas" - IDS_ALLOWED_PURPOSE_ALL "" - IDS_ALLOWED_PURPOSE_NONE "" - IDS_WARN_REMOVE_MY "Su šiuo liudijimu jūs daugiau nebegalėsite iššifruoti pranešimų ar pasirašyti pranešimų.\nAr tikrai norite pašalinti šį liudijimą?" - IDS_WARN_REMOVE_PLURAL_MY "Su šiuo liudijimu jūs daugiau nebegalėsite iššifruoti pranešimų ar pasirašyti pranešimų.\nAr tikrai norite pašalinti šiuos liudijimus?" - IDS_WARN_REMOVE_ADDRESSBOOK "Su šiuo liudijimu jūs daugiau nebegalėsite iššifruoti pranešimų ar patikrinti pasirašytų pranešimų.\nAr tikrai norite pašalinti šį liudijimą?" - IDS_WARN_REMOVE_PLURAL_ADDRESSBOOK "Su šiuo liudijimu jūs daugiau nebegalėsite iššifruoti pranešimų ar patikrinti pasirašytų pranešimų.\nAr tikrai norite pašalinti šiuos liudijimus?" - IDS_WARN_REMOVE_CA "Liudijimais, išduotais šios liudijimo įstaigos, nebebus pasitikima.\nAr tikrai norite pašalinti šį liudijimą?" - IDS_WARN_REMOVE_PLURAL_CA "Liudijimais, išduotais šių liudijimo įstaigų, nebebus pasitikima.\nAr tikrai norite pašalinti šiuos liudijimus?" - IDS_WARN_REMOVE_ROOT "Liudijimais, išduotais šios vyriausiosios liudijimo įstaigos, ar bet kurios jos išduotos liudijimų įstaigos liudijimais, nebebus pasitikima.\nAr tikrai norite pašalinti šį patikimą vyriausiąjį liudijimą?" - IDS_WARN_REMOVE_PLURAL_ROOT "Liudijimais, išduotais šių vyriausiųjų liudijimo įstaigų, ar bet kurių jų išduotų liudijimų įstaigų liudijimais, nebebus pasitikima.\nAr tikrai norite pašalinti šiuos patikimus vyriausiuosius liudijimus?" - IDS_WARN_REMOVE_TRUSTEDPUBLISHER "Nebebus pasitikima programine įranga pasirašyta šio leidėjo.\nAr tikrai norite pašalinti šį liudijimą?" - IDS_WARN_REMOVE_PLURAL_TRUSTEDPUBLISHER "Nebebus pasitikima programine įranga pasirašyta šių leidėjų.\nAr tikrai norite pašalinti šiuos liudijimus?" - IDS_WARN_REMOVE_DEFAULT "Ar tikrai norite pašalinti šį liudijimą?" - IDS_WARN_REMOVE_PLURAL_DEFAULT "Ar tikrai norite pašalinti šiuos liudijimus?" - IDS_CERT_MGR "Liudijimai" - IDS_PURPOSE_SERVER_AUTH "Garantuoja nutolusio kompiuterio tapatumą" - IDS_PURPOSE_CLIENT_AUTH "Įrodo jūsų tapatumą nutolusiam kompiuteriui" - IDS_PURPOSE_CODE_SIGNING "Garantuoja, kad programinė įranga yra iš šio leidėjo\nApsaugo programinę įrangą nuo pakeitimų po išleidimo" - IDS_PURPOSE_EMAIL_PROTECTION "Apsaugo el. pašto pranešimus" - IDS_PURPOSE_IPSEC "Leidžia saugu ryšį internete" - IDS_PURPOSE_TIMESTAMP_SIGNING "Leidžia pasirašyti duomenis dabartiniu laiku" - IDS_PURPOSE_CTL_USAGE_SIGNING "Leidžia skaitmeniškai pasirašyti patikintų liudijimų sąrašą" - IDS_PURPOSE_EFS "Leidžia užšifruoti duomenis diske" - IDS_PURPOSE_EFS_RECOVERY "Failų atkūrimas" - IDS_PURPOSE_WHQL "Windows tvarkyklių patikra" - IDS_PURPOSE_NT5 "Windows sistemos komponentų patikra" - IDS_PURPOSE_OEM_WHQL "OEM Windows sistemos komponentų patikra" - IDS_PURPOSE_EMBEDDED_NT "Įtaisytų Windows sistemos komponentų patikra" - IDS_PURPOSE_ROOT_LIST_SIGNER "Pagrindinio sąrašo pasirašytojas" - IDS_PURPOSE_QUALIFIED_SUBORDINATION "Patikslintoji hierarchija" - IDS_PURPOSE_KEY_RECOVERY "Rakto atkūrimas" - IDS_PURPOSE_DOCUMENT_SIGNING "Dokumentų pasirašymas" - IDS_PURPOSE_LIFETIME_SIGNING "Gyvavimo ciklo pasirašymas" - IDS_PURPOSE_DRM "Skaitmeninės teisės" - IDS_PURPOSE_LICENSES "Kodų pako licencijos" - IDS_PURPOSE_LICENSE_SERVER "Licencijų serverio patikra" - IDS_PURPOSE_ENROLLMENT_AGENT "Liudijimo užklausos priemonė" - IDS_PURPOSE_SMARTCARD_LOGON "Lustinių kortelių įvedimas" - IDS_PURPOSE_CA_EXCHANGE "Privačiojo rakto archyvavimas" - IDS_PURPOSE_KEY_RECOVERY_AGENT "Rakto atkūrimo priemonė" - IDS_PURPOSE_DS_EMAIL_REPLICATION "Katalogų serverio el. pašto dauginimas" - IDS_EXPORT_WIZARD "Liudijimo eksporto vediklis" - IDS_EXPORT_FORMAT_TITLE "Eksporto formatas" - IDS_EXPORT_FORMAT_SUBTITLE "Išsirinkite formatą duomenims išsaugoti." - IDS_EXPORT_FILE_TITLE "Eksporto failas" - IDS_EXPORT_FILE_SUBTITLE "Nurodykite failą, kuriame bus išsaugoti duomenys." - IDS_EXPORT_FILE_EXISTS "Nurodytas failas egzistuoja. Ar norite jį perrašyti?" - IDS_EXPORT_FILTER_CERT "DER-užkoduotas dvejetainis X.509 (*.cer)" - IDS_EXPORT_FILTER_BASE64_CERT "Base64-užkoduotas X.509 (*.cer)" - IDS_EXPORT_FILTER_CRL "Atšauktų liudijimų sąrašas (*.crl)" - IDS_EXPORT_FILTER_CTL "Patikintų liudijimų sąrašas (*.stl)" - IDS_EXPORT_FILTER_CMS "CMS/PKCS #7 pranešimai (*.p7b)" - IDS_EXPORT_FILTER_PFX "Asmeninės informacijos mainai (*.pfx)" - IDS_EXPORT_FILTER_SERIALIZED_CERT_STORE "Išdėstyta serijomis liudijimų saugykla (*.sst)" - IDS_EXPORT_FORMAT "Failo formatas" - IDS_EXPORT_INCLUDE_CHAIN "Apimti visus liudijimus liudijimų kelyje" - IDS_EXPORT_KEYS "Eksportuoti raktus" - IDS_YES "Taip" - IDS_NO "Ne" - IDS_EXPORT_SUCCEEDED "Eksportas sėkmingas." - IDS_EXPORT_FAILED "Eksportas nepavyko." - IDS_EXPORT_PRIVATE_KEY_TITLE "Eksportuoti privatųjį raktą" - IDS_EXPORT_PRIVATE_KEY_SUBTITLE "Liudijimas turi privatųjį raktą, kuris gali būti išeksportuotas kartu su liudijimu." - IDS_EXPORT_PASSWORD_TITLE "Įveskite slaptažodį" - IDS_EXPORT_PASSWORD_SUBTITLE "Jūs galite apsaugoti privatųjį raktą slaptažodžiu." - IDS_EXPORT_PASSWORD_MISMATCH "Slaptažodžiai nesutampa." - IDS_EXPORT_PRIVATE_KEY_UNAVAILABLE "Pastaba: nepavyko atverti privačiojo rakto šiam liudijimui." - IDS_EXPORT_PRIVATE_KEY_NON_EXPORTABLE "Pastaba: šio liudijimo privatusis raktas neišeksportuojamas." -} - -IDD_GENERAL DIALOG DISCARDABLE 0, 0, 255, 236 -CAPTION "Bendras" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "", -1, "Static", WS_BORDER|SS_WHITERECT, 6,10,241,200 - CONTROL "", IDC_CERTIFICATE_ICON,"RichEdit20W", - ES_READONLY|WS_DISABLED,8,11,26,26 - CONTROL "", IDC_CERTIFICATE_INFO,"RichEdit20W", - ES_READONLY|WS_DISABLED,34,11,212,26 - CONTROL "", -1, "Static", SS_BLACKFRAME, 16,37,222,1 - CONTROL "", IDC_CERTIFICATE_STATUS,"RichEdit20W", - ES_READONLY|ES_MULTILINE,8,38,238,78 - CONTROL "", -1, "Static", SS_BLACKFRAME, 16,116,222,1 - CONTROL "", IDC_CERTIFICATE_NAMES,"RichEdit20W", - ES_READONLY|ES_MULTILINE|WS_DISABLED,8,118,238,90 - PUSHBUTTON "&Įdiegti liudijimą...", IDC_ADDTOSTORE,103,216,70,14 - PUSHBUTTON "Išdavėjo &teiginys", IDC_ISSUERSTATEMENT,177,216,70,14 -END - -IDD_DETAIL DIALOG DISCARDABLE 0, 0, 255, 236 -CAPTION "Išsamiau" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Rodyti:", -1, 6,12,40,14 - COMBOBOX IDC_DETAIL_SELECT, 33,10,100,14, - CBS_DROPDOWNLIST|WS_BORDER|WS_VSCROLL|WS_TABSTOP - CONTROL "", IDC_DETAIL_LIST, "SysListView32", - LVS_REPORT|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 6,28,241,100 - CONTROL "", IDC_DETAIL_VALUE, "RichEdit20W", - ES_READONLY|ES_MULTILINE|WS_TABSTOP, 6,136,241,70 - PUSHBUTTON "Redaguoti &savybes...", IDC_EDITPROPERTIES,83,216,80,14 - PUSHBUTTON "&Kopijuoti į failą...", IDC_EXPORT,167,216,80,14 -END - -IDD_HIERARCHY DIALOG DISCARDABLE 0, 0, 255, 236 -CAPTION "Liudijimo kelias" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "Liudijimo &kelias", -1,6,10,245,165, BS_GROUPBOX - CONTROL "",IDC_CERTPATH, "SysTreeView32", TVS_HASLINES|WS_BORDER, - 13,22,231,130 - PUSHBUTTON "&Peržiūrėti liudijimą", IDC_VIEWCERTIFICATE,175,156,70,14 - LTEXT "Liudijimo &būsena:", IDC_CERTIFICATESTATUS,6,183,70,14 - CONTROL "", IDC_CERTIFICATESTATUSTEXT,"RichEdit20W", - WS_BORDER|ES_READONLY|ES_MULTILINE|WS_DISABLED,6,195,245,36 -END - -IDD_USERNOTICE DIALOG DISCARDABLE 0, 0, 255, 256 -CAPTION "Garantijų nedavimas" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "", IDC_USERNOTICE,"RichEdit20W", - WS_BORDER|ES_READONLY|ES_MULTILINE|WS_DISABLED,6,10,241,200 - PUSHBUTTON "Užverti", IDOK,93,216,75,14 - PUSHBUTTON "Daugiau &informacijos", IDC_CPS,172,216,75,14 -END - -IDD_CERT_PROPERTIES_GENERAL DIALOG DISCARDABLE 0, 0, 255, 236 -CAPTION "Bendras" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Draugiškas vardas:", -1, 6,14,70,14 - EDITTEXT IDC_FRIENDLY_NAME, 70,12,181,14, ES_AUTOHSCROLL|WS_TABSTOP - LTEXT "&Aprašas:", -1, 6,32,70,14 - EDITTEXT IDC_DESCRIPTION, 70,30,181,14, ES_AUTOVSCROLL|ES_MULTILINE|WS_TABSTOP|WS_VSCROLL - GROUPBOX "Liudijimo paskirtys", -1,6,48,245,165, BS_GROUPBOX - AUTORADIOBUTTON "&Įjungti visas šio liudijimo paskirtis", - IDC_ENABLE_ALL_PURPOSES, 12,58,180,14, BS_AUTORADIOBUTTON|WS_TABSTOP - AUTORADIOBUTTON "Išj&ungti visas šio liudijimo paskirtis", - IDC_DISABLE_ALL_PURPOSES, 12,70,180,14, BS_AUTORADIOBUTTON - AUTORADIOBUTTON "Įjungti &tik šias šio liudijimo paskirtis:", - IDC_ENABLE_SELECTED_PURPOSES, 12,82,180,14, BS_AUTORADIOBUTTON - CONTROL "", IDC_CERTIFICATE_USAGES,"SysListView32", - LVS_REPORT|LVS_NOCOLUMNHEADER|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 24,100,220,90 - PUSHBUTTON "Pridėti &paskirtį...", IDC_ADD_PURPOSE,184,194,60,14 -END - -IDD_ADD_CERT_PURPOSE DIALOG DISCARDABLE 0,0,200,68 -CAPTION "Pridėti paskirtį" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Pridėkite objekto identifikatorių (OID) liudijimo paskirčiai, kurią norite pridėti:", - -1, 6,6,190,28 - EDITTEXT IDC_NEW_PURPOSE, 6,28,190,14, ES_AUTOVSCROLL|ES_MULTILINE|WS_TABSTOP|WS_VSCROLL - PUSHBUTTON "Gerai", IDOK, 33,48,60,14 - PUSHBUTTON "Atsisakyti", IDCANCEL, 100,48,60,14 -END - -IDD_SELECT_STORE DIALOG DISCARDABLE 0,0,200,136 -CAPTION "Išrinkite liudijimų saugyklą" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Išrinkite liudijimų saugyklą, kurią norite naudoti:", IDC_STORE_TEXT, 6,6,190,28 - CONTROL "",IDC_STORE_LIST, "SysTreeView32", TVS_HASLINES|WS_BORDER|WS_TABSTOP, - 6,28,188,70 - CHECKBOX "&Rodyti fizines saugyklas", IDC_SHOW_PHYSICAL_STORES, 6,102,90,14, - BS_AUTOCHECKBOX|WS_TABSTOP - PUSHBUTTON "Gerai", IDOK, 90,118,50,14, BS_DEFPUSHBUTTON - PUSHBUTTON "Atsisakyti", IDCANCEL, 144,118,50,14 -END - -IDD_IMPORT_WELCOME DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Liudijimo importo vediklis" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Sveiki atvėrę liudijimo importo vediklį", IDC_IMPORT_TITLE, - 115,1,195,32 - LTEXT "Šis vediklis padės jums importuoti liudijimus, atšauktų liudijimų sąrašus ir patikintų liudijimų sąrašus iš failo į liudijimų saugyklą.", - -1, 115,25,195,24 - LTEXT "Liudijimas gali būti naudojamas nustatyti jūsų ar kompiuterio su kuriuo esate užmezgę ryšį tapatumą. Jis taip pat gali būti naudojamas pranešimų pasirašymui. Liudijimų saugyklos yra liudijimų rinkiniai, atšauktų liudijimų sąrašai ir patikintų liudijimų sąrašai.", - -1, 115,56,195,40 - LTEXT "Norėdami tęsti, spauskite „Toliau“.", - -1, 115,103,195,8 -END - -IDD_IMPORT_FILE DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Liudijimo importo vediklis" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Failas:", -1, 21,1,195,10 - EDITTEXT IDC_IMPORT_FILENAME, 21,11,208,14, ES_AUTOHSCROLL|WS_TABSTOP - PUSHBUTTON "&Parinkti...", IDC_IMPORT_BROWSE_FILE, 236,11,60,14 - LTEXT "Pastaba: Šie failų formatai gali turėti daugiau negu vieną liudijimą, atšauktų liudijimų sąrašą ar patikintų liudijimų sąrašą:", - -1, 21,26,265,16 - LTEXT "Kriptografinio pranešimo sintaksės standarto/PKCS #7 pranešimai (.p7b)", - -1, 31,49,265,10 - LTEXT "Asmeninės informacijos mainai/PKCS #12 (.pfx, .p12)", - -1, 31,64,265,10 - LTEXT "Microsoft išdėstyta serijomis liudijimų saugykla (.sst)", - -1, 31,79,265,10 -END - -IDD_IMPORT_STORE DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Liudijimo importo vediklis" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Wine gali automatiškai parinkti liudijimų saugyklą arba jūs galite nurodyti vietą liudijimams.", - -1, 21,1,195,20 - AUTORADIOBUTTON "Automatiškai pa&rinkti liudijimų saugyklą", - IDC_IMPORT_AUTO_STORE, 31,18,180,12, BS_AUTORADIOBUTTON|WS_TABSTOP - AUTORADIOBUTTON "Patalpinti &visus liudijimus į šią saugyklą:", - IDC_IMPORT_SPECIFY_STORE, 31,30,180,12, BS_AUTORADIOBUTTON - EDITTEXT IDC_IMPORT_STORE, 44,49,185,14, ES_READONLY - PUSHBUTTON "&Parinkti...", IDC_IMPORT_BROWSE_STORE, 236,49,60,14 -END - -IDD_IMPORT_FINISH DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Liudijimo importo vediklis" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Liudijimo importo vediklio pabaiga", IDC_IMPORT_TITLE, - 115,1,195,40 - LTEXT "Jūs sėkmingai baigėte liudijimo importo vediklį.", - -1, 115,33,195,24 - LTEXT "Jūs nurodėte šias nuostatas:", - -1, 115,57,195,12 - CONTROL "", IDC_IMPORT_SETTINGS, "SysListView32", - LVS_REPORT|LVS_NOCOLUMNHEADER|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 115,67,174,100 -END - -IDD_CERT_MGR DIALOG DISCARDABLE 0,0,335,270 -CAPTION "Liudijimai" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Numatytos paskirtys:", -1, 7,9,100,12 - COMBOBOX IDC_MGR_PURPOSE_SELECTION, 83,7,245,14, - CBS_DROPDOWNLIST|WS_BORDER|WS_VSCROLL|WS_TABSTOP - CONTROL "", IDC_MGR_STORES, "SysTabControl32", - WS_CLIPSIBLINGS|WS_TABSTOP, 7,25,321,140 - CONTROL "", IDC_MGR_CERTS, "SysListView32", - LVS_REPORT|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, 15,46,305,111 - PUSHBUTTON "&Importuoti...", IDC_MGR_IMPORT, 7,172,51,14 - PUSHBUTTON "&Eksportuoti...", IDC_MGR_EXPORT, 62,172,51,14, WS_DISABLED - PUSHBUTTON "&Šalinti", IDC_MGR_REMOVE, 117,172,51,14, WS_DISABLED - PUSHBUTTON "Išs&amiau...", IDC_MGR_ADVANCED, 277,172,51,14 - GROUPBOX "Liudijimo numatytos paskirtys", -1,7,194,321,47, BS_GROUPBOX - LTEXT "", IDC_MGR_PURPOSES, 13,204,252,32 - PUSHBUTTON "&Peržiūrėti...", IDC_MGR_VIEW, 269,218,51,14, WS_DISABLED - PUSHBUTTON "&Užverti", IDCANCEL, 277,249,51,14, BS_DEFPUSHBUTTON -END - -IDD_CERT_MGR_ADVANCED DIALOG DISCARDABLE 0,0,248,176 -CAPTION "Išsamios parinktys" -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "Liudijimo paskirtis", -1, 7,7,234,141, BS_GROUPBOX - LTEXT "Išrinkite vieną ar daugiau paskirčių rodymui, kai yra pasirinkta „papildomos paskirtys“.", - -1, 14,18,220,16 - LTEXT "&Liudijimo paskirtys:", -1, 14,41,90,12, WS_TABSTOP - CONTROL "", IDC_CERTIFICATE_USAGES,"SysListView32", - LVS_REPORT|LVS_NOCOLUMNHEADER|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 14,51,220,90 - PUSHBUTTON "Gerai", IDOK, 132,155,51,14, BS_DEFPUSHBUTTON - PUSHBUTTON "Atsisakyti", IDCANCEL, 190,155,51,14 -END - -IDD_EXPORT_WELCOME DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Liudijimo eksporto vediklis" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Sveiki atvėrę liudijimo eksporto vediklį", IDC_EXPORT_TITLE, - 115,1,195,32 - LTEXT "Šis valdiklis padės jums eksportuoti liudijimus, atšauktų liudijimų sąrašus ir patikintų liudijimų sąrašus iš liudijimų saugyklos į failą.", - -1, 115,25,195,24 - LTEXT "Liudijimas gali būti naudojamas nustatyti jūsų ar kompiuterio su kuriuo esate užmezgę ryšį tapatumą. Jis taip pat gali būti naudojamas pranešimų pasirašymui. Liudijimų saugyklos yra liudijimų rinkiniai, atšauktų liudijimų sąrašai ir patikintų liudijimų sąrašai.", - -1, 115,56,195,40 - LTEXT "Norėdami tęsti, spauskite „Toliau“.", - -1, 115,103,195,8 -END - -IDD_EXPORT_PRIVATE_KEY DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Liudijimo eksporto vediklis" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Jei pasirinksite eksportuoti privatųjį raktą, kitame lape būsite paklausti įvesti slaptažodį raktui apsaugoti.", -1, 21,1,195,23 - LTEXT "Ar norite eksportuoti privatųjį raktą?", -1, 21,24,195,15 - AUTORADIOBUTTON "&Taip, eksportuoti privatųjį raktą", - IDC_EXPORT_PRIVATE_KEY_YES, 31,36,200,12, BS_AUTORADIOBUTTON|WS_TABSTOP - AUTORADIOBUTTON "&Ne, neeksportuoti privačiojo rakto", - IDC_EXPORT_PRIVATE_KEY_NO, 31,48,200,12, BS_AUTORADIOBUTTON - LTEXT "", IDC_EXPORT_PRIVATE_KEY_UNAVAILABLE, 21,60,200,24 -END - -IDD_EXPORT_PASSWORD DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Liudijimo eksporto vediklis" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Slaptažodis:", -1, 21,1,195,10 - EDITTEXT IDC_EXPORT_PASSWORD, 21,11,208,14, ES_AUTOHSCROLL|WS_TABSTOP - LTEXT "&Patvirtinti slaptažodį:", -1, 21,35,195,10 - EDITTEXT IDC_EXPORT_PASSWORD_CONFIRM, 21,45,208,14, ES_AUTOHSCROLL|WS_TABSTOP -END - -IDD_EXPORT_FORMAT DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Liudijimo eksporto vediklis" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Išrinkite formatą, kurį norite naudoti:", -1, 21,1,195,10 - AUTORADIOBUTTON "&DER-užkoduotas X.509 (.cer)", - IDC_EXPORT_FORMAT_DER, 31,18,260,12, BS_AUTORADIOBUTTON|WS_TABSTOP - AUTORADIOBUTTON "Ba&se64-užkoduotas X.509 (.cer)", - IDC_EXPORT_FORMAT_BASE64, 31,30,260,12, BS_AUTORADIOBUTTON - AUTORADIOBUTTON "&Kriptografinio pranešimo sintaksės standarto/PKCS #7 pranešimas (.p7b):", - IDC_EXPORT_FORMAT_CMS, 31,42,260,12, BS_AUTORADIOBUTTON - CHECKBOX "&Jei įmanoma, apimti visus liudijimus liudijimų kelyje", - IDC_EXPORT_CMS_INCLUDE_CHAIN, 44,57,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED - AUTORADIOBUTTON "&Asmeninės informacijos mainai/PKCS #12 (.pfx)", - IDC_EXPORT_FORMAT_PFX, 31,72,260,12, BS_AUTORADIOBUTTON|WS_DISABLED - CHECKBOX "A&pimti visus liudijimus liudijimų kelyje", - IDC_EXPORT_PFX_INCLUDE_CHAIN, 44,87,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED - CHECKBOX "Įjungti stiprų &šifravimą", - IDC_EXPORT_PFX_STRONG_ENCRYPTION, 44,102,200,8, - BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED - CHECKBOX "Iš&trinti privatųjį raktą, kai eksportas sėkmingas", - IDC_EXPORT_PFX_DELETE_PRIVATE_KEY, 44,117,200,8, - BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED -END - -IDD_EXPORT_FILE DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Liudijimo eksporto vediklis" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Failas:", -1, 21,1,195,10 - EDITTEXT IDC_EXPORT_FILENAME, 21,11,208,14, ES_AUTOHSCROLL|WS_TABSTOP - PUSHBUTTON "&Parinkti...", IDC_EXPORT_BROWSE_FILE, 236,11,60,14 -END - -IDD_EXPORT_FINISH DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Liudijimo eksporto vediklis" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Liudijimo eksporto vediklio pabaiga", IDC_EXPORT_TITLE, - 115,1,195,40 - LTEXT "Jūs sėkmingai baigėte liudijimo eksporto vediklį.", - -1, 115,33,195,24 - LTEXT "Jūs nurodėte šias nuostatas:", - -1, 115,57,195,12 - CONTROL "", IDC_EXPORT_SETTINGS, "SysListView32", - LVS_REPORT|LVS_NOCOLUMNHEADER|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 115,67,174,100 -END diff --git a/dlls/cryptui/cryptui_Nl.rc b/dlls/cryptui/cryptui_Nl.rc index faa32108eeb..d046d376b8a 100644 --- a/dlls/cryptui/cryptui_Nl.rc +++ b/dlls/cryptui/cryptui_Nl.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cryptuires.h" - -#pragma code_page(65001) - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE @@ -77,7 +73,7 @@ STRINGTABLE DISCARDABLE IDS_IMPORT_FILTER_PFX "Persoonlijke informatie uitwisseling (*.pfx; *.p12)" IDS_IMPORT_FILTER_CRL "Certificaat terugroeplijst (*.crl)" IDS_IMPORT_FILTER_CTL "Certificaat vertrouwenslijst (*.stl)" - IDS_IMPORT_FILTER_SERIALIZED_STORE "Microsoft seriële certificatenopslag (*.sst)" + IDS_IMPORT_FILTER_SERIALIZED_STORE "Microsoft seriële certificatenopslag (*.sst)" IDS_IMPORT_FILTER_CMS "CMS/PKCS #7 berichten (*.spc; *.p7b)" IDS_IMPORT_FILTER_ALL "Alle bestanden (*.*)" IDS_IMPORT_EMPTY_FILE "Selecteer een bestand." @@ -99,7 +95,7 @@ STRINGTABLE DISCARDABLE IDS_IMPORT_FAILED "Het importeren is mislukt." IDS_WIZARD_TITLE_FONT "Arial" IDS_PURPOSE_ALL "" - IDS_PURPOSE_ADVANCED "" + IDS_PURPOSE_ADVANCED "" IDS_SUBJECT_COLUMN "Verstrekt aan" IDS_ISSUER_COLUMN "Uitgegeven door" IDS_EXPIRATION_COLUMN "Verloop datum" @@ -108,8 +104,8 @@ STRINGTABLE DISCARDABLE IDS_ALLOWED_PURPOSE_NONE "" IDS_WARN_REMOVE_MY "U kunt niet langer berichten ontcijferen of ondertekenen met dit certificaat.\nWeet u zeker dat u dit certificaat wilt verwijderen?" IDS_WARN_REMOVE_PLURAL_MY "U kunt niet langer berichten ontcijferen of ondertekenen met deze certificaten.\nWeet u zeker dat u deze certificaten wilt verwijderen?" - IDS_WARN_REMOVE_ADDRESSBOOK "U kunt niet langer berichten coderen of verifiëren met dit certificaat.\nWeet u zeker dat u dit certificaat wilt verwijderen?" - IDS_WARN_REMOVE_PLURAL_ADDRESSBOOK "U kunt niet langer berichten coderen of verifiëren met deze certificaten.\nWeet u zeker dat u deze certificaten wilt verwijderen?" + IDS_WARN_REMOVE_ADDRESSBOOK "U kunt niet langer berichten coderen of verifiëren met dit certificaat.\nWeet u zeker dat u dit certificaat wilt verwijderen?" + IDS_WARN_REMOVE_PLURAL_ADDRESSBOOK "U kunt niet langer berichten coderen of verifiëren met deze certificaten.\nWeet u zeker dat u deze certificaten wilt verwijderen?" IDS_WARN_REMOVE_CA "Certificaten uitgegeven door deze certificaten autoriteit zullen niet meer vertrouwd worden.\nWeet u zeker dat u dit certificaat wilt verwijderen?" IDS_WARN_REMOVE_PLURAL_CA "Certificaten uitgegeven door deze certificaten autoriteiten zullen niet meer vertrouwd worden.\nWeet u zeker dat u deze certificaten wilt verwijderen?" IDS_WARN_REMOVE_ROOT "Certificaten uitgegeven door deze basic certificaten autoriteit, alsmede enige certificatie autoriteit die hij verstrekt, zullen niet meer vertrouwd worden.\nWeet u zeker dat u dit vertrouwde basic certificaat wilt verwijderen?" @@ -152,12 +148,12 @@ STRINGTABLE DISCARDABLE IDS_EXPORT_FILE_SUBTITLE "Geef de naam van het bestand waarin de inhoud zal worden opgeslagen." IDS_EXPORT_FILE_EXISTS "Het gekozen bestand bestaat reeds. Wilt u het overschrijven?" IDS_EXPORT_FILTER_CERT "DER-Encoded Binary X.509 (*.cer)" - IDS_EXPORT_FILTER_BASE64_CERT "Base64-geëncodeerd X.509 (*.cer)" + IDS_EXPORT_FILTER_BASE64_CERT "Base64-geëncodeerd X.509 (*.cer)" IDS_EXPORT_FILTER_CRL "Certificaat terugroeplijst (*.crl)" IDS_EXPORT_FILTER_CTL "Certificaat vertrouwenslijst (*.stl)" IDS_EXPORT_FILTER_CMS "CMS/PKCS #7 berichten (*.p7b)" IDS_EXPORT_FILTER_PFX "Persoonlijke informatie uitwisseling (*.pfx)" - IDS_EXPORT_FILTER_SERIALIZED_CERT_STORE "Seriële certificatenopslag (*.sst)" + IDS_EXPORT_FILTER_SERIALIZED_CERT_STORE "Seriële certificatenopslag (*.sst)" IDS_EXPORT_FORMAT "Bestandsformaat" IDS_EXPORT_INCLUDE_CHAIN "Neem alle certificaten in het certificatiepad op" IDS_EXPORT_KEYS "Exporteer sleutels" @@ -166,12 +162,12 @@ STRINGTABLE DISCARDABLE IDS_EXPORT_SUCCEEDED "Het exporteren is gelukt." IDS_EXPORT_FAILED "Het exporteren is mislukt." IDS_EXPORT_PRIVATE_KEY_TITLE "Exporteer persoonlijke sleutel" - IDS_EXPORT_PRIVATE_KEY_SUBTITLE "Het certificaat bevat een persoonlijke sleutel die mee kan worden geëxporteerd met het certificaat." + IDS_EXPORT_PRIVATE_KEY_SUBTITLE "Het certificaat bevat een persoonlijke sleutel die mee kan worden geëxporteerd met het certificaat." IDS_EXPORT_PASSWORD_TITLE "Voer wachtwoord in" IDS_EXPORT_PASSWORD_SUBTITLE "U kunt een persoonlijke sleutel beveiligen met een wachtwoord." IDS_EXPORT_PASSWORD_MISMATCH "De wachtwoorden zijn niet gelijk." IDS_EXPORT_PRIVATE_KEY_UNAVAILABLE "NB: De persoonlijke sleutel voor dit certificaat kon niet geopend worden." - IDS_EXPORT_PRIVATE_KEY_NON_EXPORTABLE "Note: De persoonlijke sleutel voor dit certificaat kan niet geëxporteerd worden." + IDS_EXPORT_PRIVATE_KEY_NON_EXPORTABLE "Note: De persoonlijke sleutel voor dit certificaat kan niet geëxporteerd worden." } IDD_GENERAL DIALOG DISCARDABLE 0, 0, 255, 236 @@ -288,12 +284,12 @@ FONT 8, "MS Shell Dlg" BEGIN LTEXT "Welkom bij de certificaat importeerhulp", IDC_IMPORT_TITLE, 115,1,195,40 - LTEXT "Deze hulp assisteert u met het importeren van certificaten, certificaat terugroeplijsten en certificaat vertrouwenslijsten uit een bestand naar een certificatenopslag.", - -1, 115,33,195,24 + LTEXT "Deze hulp helps u met het importeren van certificaten, certificaat terugroeplijsten en certificaat vertrouwenslijsten uit een bestand naar een certificatenopslag.", + -1, 115,33,195,16 LTEXT "Een certificaat kan gebruikt worden om u of de computer waarmee u werkt te identificeren. Het kan ook gebruikt worden voor authenticatie en om berichten te ondertekenen. Certificatenopslagen zijn verzamelingen van certificaten, certificaat terugroeplijsten en certificaat vertrouwenslijsten.", - -1, 115,64,195,48 - LTEXT "Klik op Volgende om verder te gaan.", - -1, 115,119,195,8 + -1, 115,56,195,40 + LTEXT "Om verder te gaan, click op Volgende.", + -1, 115,103,195,8 END IDD_IMPORT_FILE DIALOG DISCARDABLE 0,0,317,143 @@ -303,13 +299,13 @@ BEGIN LTEXT "Bestands&naam:", -1, 21,1,195,10 EDITTEXT IDC_IMPORT_FILENAME, 21,11,208,14, ES_AUTOHSCROLL|WS_TABSTOP PUSHBUTTON "B&laderen...", IDC_IMPORT_BROWSE_FILE, 236,11,60,14 - LTEXT "NB: De volgende bestandsformaten kunnen meer dan één certificaat, certificaat terugroeplijst of certificaat vertrouwenslijst bevatten:", + LTEXT "NB: De volgende bestandsformaten kunnen meer dan één certificaat, certificaat terugroeplijst of certificaat vertrouwenslijst bevatten:", -1, 21,26,265,16 LTEXT "Cryptographisch berichtsyntaxis standaard/PKCS #7 berichten (.p7b)", -1, 31,49,265,10 LTEXT "Persoonlijke informatie uitwisseling/PKCS #12 (.pfx, .p12)", -1, 31,64,265,10 - LTEXT "Microsoft seriële certificatenopslag (.sst)", + LTEXT "Microsoft seriële certificatenopslag (.sst)", -1, 31,79,265,10 END @@ -356,7 +352,7 @@ BEGIN PUSHBUTTON "&Importeer...", IDC_MGR_IMPORT, 7,172,51,14 PUSHBUTTON "&Exporteer...", IDC_MGR_EXPORT, 62,172,51,14, WS_DISABLED PUSHBUTTON "&Verwijder", IDC_MGR_REMOVE, 117,172,51,14, WS_DISABLED - PUSHBUTTON "Ge&avanceerd...", IDC_MGR_ADVANCED, 271,172,57,14 + PUSHBUTTON "Ge&avanceerd...", IDC_MGR_ADVANCED, 277,172,51,14 GROUPBOX "Certificaat doeleinden", -1,7,194,321,47, BS_GROUPBOX LTEXT "", IDC_MGR_PURPOSES, 13,208,252,30 PUSHBUTTON "&Bekijken...", IDC_MGR_VIEW, 269,218,51,14, WS_DISABLED @@ -384,12 +380,12 @@ FONT 8, "MS Shell Dlg" BEGIN LTEXT "Welkom bij de Certificaat exporteerhulp", IDC_EXPORT_TITLE, 115,1,195,40 - LTEXT "Deze hulp assisteert u bij het exporteren van certificaten, certificaat terugroeplijsten en certificaat vertrouwenslijsten vanuit een certificatenopslag naar een bestand.", - -1, 115,33,195,24 + LTEXT "Deze hulp assisteerd u bij het exporteren van certificaten, certificaat terugroeplijsten en certificaat vertrouwenslijsten vanuit een certificatenopslag naar een bestand.", + -1, 115,33,195,16 LTEXT "Een certificaat kan gebruikt worden om u of de computer waarmee u werkt te identificeren. Het kan ook gebruikt worden voor authenticatie en om berichten te ondertekenen. Certificatenopslagen zijn verzamelingen van certificaten, certificaat terugroeplijsten en certificaat vertrouwenslijsten.", - -1, 115,64,195,48 - LTEXT "Klik op Volgende om verder te gaan.", - -1, 115,119,195,8 + -1, 115,56,195,40 + LTEXT "Om verder te gaan, click op Volgende.", + -1, 115,103,195,8 END IDD_EXPORT_PRIVATE_KEY DIALOG DISCARDABLE 0,0,317,143 @@ -421,22 +417,22 @@ FONT 8, "MS Shell Dlg" BEGIN LTEXT "Selecteer het formaat dat u wilt gebruiken:", -1, 21,1,195,10 AUTORADIOBUTTON "&DER-encoded X.509 (.cer)", - IDC_EXPORT_FORMAT_DER, 31,18,240,12, BS_AUTORADIOBUTTON|WS_TABSTOP - AUTORADIOBUTTON "Ba&se64-encoded X.509 (.cer)", - IDC_EXPORT_FORMAT_BASE64, 31,30,240,12, BS_AUTORADIOBUTTON + IDC_EXPORT_FORMAT_DER, 31,18,200,12, BS_AUTORADIOBUTTON|WS_TABSTOP + AUTORADIOBUTTON "Ba&se64-encoded X.509 (.cer):", + IDC_EXPORT_FORMAT_BASE64, 31,30,200,12, BS_AUTORADIOBUTTON AUTORADIOBUTTON "&Cryptographisch berichtsyntaxis standaard/PKCS #7 berichten (.p7b)", - IDC_EXPORT_FORMAT_CMS, 31,42,240,12, BS_AUTORADIOBUTTON + IDC_EXPORT_FORMAT_CMS, 31,42,200,12, BS_AUTORADIOBUTTON CHECKBOX "Neem &alle certificaten in het certificatiepad op indien mogelijk", - IDC_EXPORT_CMS_INCLUDE_CHAIN, 44,57,240,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED + IDC_EXPORT_CMS_INCLUDE_CHAIN, 44,57,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED AUTORADIOBUTTON "&Persoonlijke informatie uitwisseling/PKCS #12 (.pfx)", - IDC_EXPORT_FORMAT_PFX, 31,72,240,12, BS_AUTORADIOBUTTON|WS_DISABLED + IDC_EXPORT_FORMAT_PFX, 31,72,200,12, BS_AUTORADIOBUTTON|WS_DISABLED CHECKBOX "Nee&m alle certificaten in het certificatiepad op indien mogelijk", - IDC_EXPORT_PFX_INCLUDE_CHAIN, 44,87,240,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED + IDC_EXPORT_PFX_INCLUDE_CHAIN, 44,87,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED CHECKBOX "&Gebruikt sterke encryptie", - IDC_EXPORT_PFX_STRONG_ENCRYPTION, 44,102,240,8, + IDC_EXPORT_PFX_STRONG_ENCRYPTION, 44,102,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED CHECKBOX "Verwijder de persoonlijke s&leutel als de export succesvol is", - IDC_EXPORT_PFX_DELETE_PRIVATE_KEY, 44,117,240,8, + IDC_EXPORT_PFX_DELETE_PRIVATE_KEY, 44,117,200,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED END diff --git a/dlls/cryptui/cryptui_Pt.rc b/dlls/cryptui/cryptui_Pt.rc deleted file mode 100644 index f8795293d9f..00000000000 --- a/dlls/cryptui/cryptui_Pt.rc +++ /dev/null @@ -1,465 +0,0 @@ -/* - * cryptui dll Portuguese resources - * - * Copyright 2009 Ricardo Filipe - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "cryptuires.h" - -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE - -STRINGTABLE DISCARDABLE -{ - IDS_CERTIFICATE "Certificado" - IDS_CERTIFICATEINFORMATION "Informação do Certificado" - IDS_CERT_INFO_BAD_SIG "Este certificado tem uma assinatura inválida. O certificado pode ter sido alterado ou corrompido." - IDS_CERT_INFO_UNTRUSTED_CA "Este certificado raíz não é confiável. Para ficar confiável, adicione-o ao conjunto de certificados raíz confiáveis do seu sistema." - IDS_CERT_INFO_UNTRUSTED_ROOT "Este certificado não foi validado num certificado raíz confiável." - IDS_CERT_INFO_PARTIAL_CHAIN "O emissor deste certificado não foi encontrado." - IDS_CERT_INFO_BAD_PURPOSES "Todos os propósitos deste certificado não foram verificados." - IDS_CERT_INFO_PURPOSES "Este certificado é intencionado com os seguintes propósitos::" - IDS_SUBJECT_HEADING "Emitido a: " - IDS_ISSUER_HEADING "Emitido por: " - IDS_VALID_FROM "Válido de " - IDS_VALID_TO " para " - IDS_CERTIFICATE_BAD_SIGNATURE "Este certificado tem uma assinatura inválida." - IDS_CERTIFICATE_BAD_TIME "Este certificado expirou ou ainda não é válido." - IDS_CERTIFICATE_BAD_TIMENEST "O período de validade deste certificado excede o do seu emissor." - IDS_CERTIFICATE_REVOKED "Este certificado foi revogado pelo seu emissor." - IDS_CERTIFICATE_VALID "Este certificado está OK." - IDS_FIELD "Campo" - IDS_VALUE "Valor" - IDS_FIELDS_ALL "" - IDS_FIELDS_V1 "Campos da Versão 1 Apenas" - IDS_FIELDS_EXTENSIONS "Extensões Apenas" - IDS_FIELDS_CRITICAL_EXTENSIONS "Extensões Críticas Apenas" - IDS_FIELDS_PROPERTIES "Propriedades Apenas" - IDS_FIELD_VERSION "Versão" - IDS_FIELD_SERIAL_NUMBER "Número de Série" - IDS_FIELD_ISSUER "Emissor" - IDS_FIELD_VALID_FROM "Válido desde" - IDS_FIELD_VALID_TO "Válido até" - IDS_FIELD_SUBJECT "Sujeito" - IDS_FIELD_PUBLIC_KEY "Chave Pública" - IDS_FIELD_PUBLIC_KEY_FORMAT "%s (%d bits)" - IDS_PROP_HASH "SHA1 hash" - IDS_PROP_ENHKEY_USAGE "Uso de chave avançado (propriedade)" - IDS_PROP_FRIENDLY_NAME "Nome amigável" - IDS_PROP_DESCRIPTION "Descrição" - IDS_CERTIFICATE_PROPERTIES "Propriedades do Certificado" - IDS_CERTIFICATE_PURPOSE_ERROR "Por favor insira um OID na forma 1.2.3.4" - IDS_CERTIFICATE_PURPOSE_EXISTS "O OID inserido já existe." - IDS_SELECT_STORE_TITLE "Seleccione o Conjunto de Certificados" - IDS_SELECT_STORE "Por favor seleccione um conjunto de certificados." - IDS_IMPORT_WIZARD "Assistente de Importação de Certificados" - IDS_IMPORT_TYPE_MISMATCH "O ficheiro contém objectos que não correspondem ao critério dado. Por favor seleccione outro ficheiro." - IDS_IMPORT_FILE_TITLE "Ficheiro a Importar" - IDS_IMPORT_FILE_SUBTITLE "Especifique o ficheiro que deseja Importar." - IDS_IMPORT_STORE_TITLE "Conjunto de Certificados" - IDS_IMPORT_STORE_SUBTITLE "Os Conjuntos de Certificados são coleccões de certificados, listas de revogação de certificados e listas de certificados confiáveis." - IDS_IMPORT_FILTER_CERT "Certificado X.509 (*.cer; *.crt)" - IDS_IMPORT_FILTER_PFX "Troca de Informações Pessoais (*.pfx; *.p12)" - IDS_IMPORT_FILTER_CRL "Lista de Revogação de Certificados (*.crl)" - IDS_IMPORT_FILTER_CTL "Lista de Certificados Confiáveis (*.stl)" - IDS_IMPORT_FILTER_SERIALIZED_STORE "Conjunto de Certificados Serializados da Microsoft (*.sst)" - IDS_IMPORT_FILTER_CMS "Mensagens CMS/PKCS #7 (*.spc; *.p7b)" - IDS_IMPORT_FILTER_ALL "Todos os Ficheiros (*.*)" - IDS_IMPORT_EMPTY_FILE "Por favor seleccione um ficheiro." - IDS_IMPORT_BAD_FORMAT "O formato do ficheiro não é reconhecido. Por favor seleccione outro ficheiro." - IDS_IMPORT_OPEN_FAILED "Não consegui abrir " - IDS_IMPORT_DEST_DETERMINED "Determinado pelo programa" - IDS_IMPORT_SELECT_STORE "Por favor seleccione um conjunto" - IDS_IMPORT_STORE_SELECTION "Conjunto de certificados seleccionado" - IDS_IMPORT_DEST_AUTOMATIC "Determinado automaticamente pelo programa" - IDS_IMPORT_FILE "Ficheiro" - IDS_IMPORT_CONTENT "Conteúdo" - IDS_IMPORT_CONTENT_CERT "Certificado" - IDS_IMPORT_CONTENT_CRL "Lista de Revogação de Certificados" - IDS_IMPORT_CONTENT_CTL "Lista de Certificados Confiáveis" - IDS_IMPORT_CONTENT_CMS "Mensagem CMS/PKCS #7" - IDS_IMPORT_CONTENT_PFX "Troca de Informações Pessoais" - IDS_IMPORT_CONTENT_STORE "Conjunto de Certificados" - IDS_IMPORT_SUCCEEDED "A importação foi bem sucedida." - IDS_IMPORT_FAILED "A importação falhou." - IDS_WIZARD_TITLE_FONT "Arial" - IDS_PURPOSE_ALL "" - IDS_PURPOSE_ADVANCED "" - IDS_SUBJECT_COLUMN "Emitido para" - IDS_ISSUER_COLUMN "Emitido por" - IDS_EXPIRATION_COLUMN "Data de Expiração" - IDS_FRIENDLY_NAME_COLUMN "Nome Amigável" - IDS_ALLOWED_PURPOSE_ALL "" - IDS_ALLOWED_PURPOSE_NONE "" - IDS_WARN_REMOVE_MY "Não vai poder continuar a decifrar ou assinar mensagens com este certificado.\nTem a certeza que deseja remover este certificado?" - IDS_WARN_REMOVE_PLURAL_MY "Não vai poder continuar a decifrar ou assinar mensagens com estes certificados.\nTem a certeza que deseja remover estes certificados?" - IDS_WARN_REMOVE_ADDRESSBOOK "Não vai poder continuar a cifrar ou verificar mensagens com este certificado.\nTem a certeza que deseja remover este certificado?" - IDS_WARN_REMOVE_PLURAL_ADDRESSBOOK "Não vai poder continuar a cifrar ou verificar mensagens com estes certificados.\nTem a certeza que deseja remover estes certificados?" - IDS_WARN_REMOVE_CA "Os certificados emitidos por esta autoridade de certificação não continuarão a ser confiáveis.\nTem a certeza que deseja remover este certificado?" - IDS_WARN_REMOVE_PLURAL_CA "Os certificados emitidos por estas autoridades de certificação não continuarão a ser confiáveis.\nTem a certeza que deseja remover estes certificados?" - IDS_WARN_REMOVE_ROOT "Os certificados emitidos por esta autoridade de certificação raíz ou quaisquer autoridades de certificação por ela emitidas não continuarão a ser confiáveis.\nTem a certeza que deseja remover este certificado raíz confiável?" - IDS_WARN_REMOVE_PLURAL_ROOT "Os certificados emitidos por estas autoridades de certificação raíz ou quaisquer autoridades de certificação por elas emitidas não continuarão a ser confiáveis.\nTem a certeza que deseja remover estes certificados raíz confiáveis?" - IDS_WARN_REMOVE_TRUSTEDPUBLISHER "Software assinado por este editor não continuará a ser confiável.\nTem a certeza que deseja remover este certificado?" - IDS_WARN_REMOVE_PLURAL_TRUSTEDPUBLISHER "Software assinado por estes editores não continuará a ser confiável.\nTem a certeza que deseja remover estes certificados?" - IDS_WARN_REMOVE_DEFAULT "Tem a certeza que deseja remover este certificado?" - IDS_WARN_REMOVE_PLURAL_DEFAULT "Tem a certeza que deseja remover estes certificados?" - IDS_CERT_MGR "Certificados" - IDS_PURPOSE_SERVER_AUTH "Assegura a identidade de um computador remoto" - IDS_PURPOSE_CLIENT_AUTH "Prova a sua identidade a um computador remoto" - IDS_PURPOSE_CODE_SIGNING "Assegura que o software veio de uma editora de software\nProtege o software de alterações após publicação" - IDS_PURPOSE_EMAIL_PROTECTION "Protege mensagens de e-mail" - IDS_PURPOSE_IPSEC "Permite comunicação segura pela Internet" - IDS_PURPOSE_TIMESTAMP_SIGNING "Permite que os dados sejam assinados com o tempo actual" - IDS_PURPOSE_CTL_USAGE_SIGNING "Permite que assine digitalmente uma lista de certificados confiáveis" - IDS_PURPOSE_EFS "Permite que os dados em disco sejam cifrados" - IDS_PURPOSE_EFS_RECOVERY "Recuperação de Ficheiros" - IDS_PURPOSE_WHQL "Windows Hardware Driver Verification" - IDS_PURPOSE_NT5 "Windows System Component Verification" - IDS_PURPOSE_OEM_WHQL "OEM Windows System Component Verification" - IDS_PURPOSE_EMBEDDED_NT "Embedded Windows System Component Verification" - IDS_PURPOSE_ROOT_LIST_SIGNER "Root List Signer" - IDS_PURPOSE_QUALIFIED_SUBORDINATION "Qualified Subordination" - IDS_PURPOSE_KEY_RECOVERY "Key Recovery" - IDS_PURPOSE_DOCUMENT_SIGNING "Document Signing" - IDS_PURPOSE_LIFETIME_SIGNING "Lifetime Signing" - IDS_PURPOSE_DRM "Digital Rights" - IDS_PURPOSE_LICENSES "Key Pack Licenses" - IDS_PURPOSE_LICENSE_SERVER "License Server Verification" - IDS_PURPOSE_ENROLLMENT_AGENT "Certificate Request Agent" - IDS_PURPOSE_SMARTCARD_LOGON "Smart Card Logon" - IDS_PURPOSE_CA_EXCHANGE "Private Key Archival" - IDS_PURPOSE_KEY_RECOVERY_AGENT "Key Recovery Agent" - IDS_PURPOSE_DS_EMAIL_REPLICATION "Directory Service Email Replication" - IDS_EXPORT_WIZARD "Assistente de Exportação de Certificados" - IDS_EXPORT_FORMAT_TITLE "Formato de Exportação" - IDS_EXPORT_FORMAT_SUBTITLE "Escolha o formato em que o conteúdo será guardado." - IDS_EXPORT_FILE_TITLE "Exportar Ficheiro" - IDS_EXPORT_FILE_SUBTITLE "Especifique o nome do ficheiro em que o conteúdo será guardado." - IDS_EXPORT_FILE_EXISTS "O ficheiro especificado já existe. Deseja substituí-lo?" - IDS_EXPORT_FILTER_CERT "DER-Encoded Binary X.509 (*.cer)" - IDS_EXPORT_FILTER_BASE64_CERT "Base64-Encoded X.509 (*.cer)" - IDS_EXPORT_FILTER_CRL "Certificate Revocation List (*.crl)" - IDS_EXPORT_FILTER_CTL "Certificate Trust List (*.stl)" - IDS_EXPORT_FILTER_CMS "CMS/PKCS #7 Messages (*.p7b)" - IDS_EXPORT_FILTER_PFX "Personal Information Exchange (*.pfx)" - IDS_EXPORT_FILTER_SERIALIZED_CERT_STORE "Serialized Certificate Store (*.sst)" - IDS_EXPORT_FORMAT "Formato do Ficheiro" - IDS_EXPORT_INCLUDE_CHAIN "Incluir todos os certificados no caminho do certificado" - IDS_EXPORT_KEYS "Exportar Chaves" - IDS_YES "Sim" - IDS_NO "Não" - IDS_EXPORT_SUCCEEDED "A exportação foi bem sucedida." - IDS_EXPORT_FAILED "A exportação falhou." - IDS_EXPORT_PRIVATE_KEY_TITLE "Exportar Chave Privada" - IDS_EXPORT_PRIVATE_KEY_SUBTITLE "O certificado contém uma chave privada que pode ser exportada em conjunto com o certificado." - IDS_EXPORT_PASSWORD_TITLE "Digite Palavra Chave" - IDS_EXPORT_PASSWORD_SUBTITLE "Pode proteger uma chave privada com uma palavra chave." - IDS_EXPORT_PASSWORD_MISMATCH "As palavras chave não coincidem." - IDS_EXPORT_PRIVATE_KEY_UNAVAILABLE "Nota: A chave privada para este certificado não conseguiu ser aberta." - IDS_EXPORT_PRIVATE_KEY_NON_EXPORTABLE "Nota: A chave privada para este certificado não é exportável." -} - -IDD_GENERAL DIALOG DISCARDABLE 0, 0, 255, 236 -CAPTION "Geral" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "", -1, "Static", WS_BORDER|SS_WHITERECT, 6,10,241,200 - CONTROL "", IDC_CERTIFICATE_ICON,"RichEdit20W", - ES_READONLY|WS_DISABLED,8,11,26,26 - CONTROL "", IDC_CERTIFICATE_INFO,"RichEdit20W", - ES_READONLY|WS_DISABLED,34,11,212,26 - CONTROL "", -1, "Static", SS_BLACKFRAME, 16,37,222,1 - CONTROL "", IDC_CERTIFICATE_STATUS,"RichEdit20W", - ES_READONLY|ES_MULTILINE,8,38,238,78 - CONTROL "", -1, "Static", SS_BLACKFRAME, 16,116,222,1 - CONTROL "", IDC_CERTIFICATE_NAMES,"RichEdit20W", - ES_READONLY|ES_MULTILINE|WS_DISABLED,8,118,238,90 - PUSHBUTTON "&Instalar Certificado...", IDC_ADDTOSTORE,103,216,70,14 - PUSHBUTTON "&Declaração do Emissor", IDC_ISSUERSTATEMENT,177,216,70,14 -END - -IDD_DETAIL DIALOG DISCARDABLE 0, 0, 255, 236 -CAPTION "Detalhes" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Mostrar:", -1, 6,12,40,14 - COMBOBOX IDC_DETAIL_SELECT, 28,10,100,14, - CBS_DROPDOWNLIST|WS_BORDER|WS_VSCROLL|WS_TABSTOP - CONTROL "", IDC_DETAIL_LIST, "SysListView32", - LVS_REPORT|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 6,28,241,100 - CONTROL "", IDC_DETAIL_VALUE, "RichEdit20W", - ES_READONLY|ES_MULTILINE|WS_TABSTOP, 6,136,241,70 - PUSHBUTTON "&Editar Propriedades...", IDC_EDITPROPERTIES,103,216,70,14 - PUSHBUTTON "&Copiar para Ficheiro...", IDC_EXPORT,177,216,70,14 -END - -IDD_HIERARCHY DIALOG DISCARDABLE 0, 0, 255, 236 -CAPTION "Caminho de Certificação" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "&Caminho de Certificação", -1,6,10,245,165, BS_GROUPBOX - CONTROL "",IDC_CERTPATH, "SysTreeView32", TVS_HASLINES|WS_BORDER, - 13,22,231,130 - PUSHBUTTON "&Ver Certificado", IDC_VIEWCERTIFICATE,175,156,70,14 - LTEXT "&Estado do Certificado:", IDC_CERTIFICATESTATUS,6,183,70,14 - CONTROL "", IDC_CERTIFICATESTATUSTEXT,"RichEdit20W", - WS_BORDER|ES_READONLY|ES_MULTILINE|WS_DISABLED,6,195,245,36 -END - -IDD_USERNOTICE DIALOG DISCARDABLE 0, 0, 255, 256 -CAPTION "Declaração" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "", IDC_USERNOTICE,"RichEdit20W", - WS_BORDER|ES_READONLY|ES_MULTILINE|WS_DISABLED,6,10,241,200 - PUSHBUTTON "&Fechar", IDOK,103,216,70,14 - PUSHBUTTON "&Mais Informação", IDC_CPS,177,216,70,14 -END - -IDD_CERT_PROPERTIES_GENERAL DIALOG DISCARDABLE 0, 0, 255, 236 -CAPTION "Geral" -STYLE WS_VISIBLE -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Nome amigável:", -1, 6,14,60,14 - EDITTEXT IDC_FRIENDLY_NAME, 60,12,191,14, ES_AUTOHSCROLL|WS_TABSTOP - LTEXT "&Descrição:", -1, 6,32,60,14 - EDITTEXT IDC_DESCRIPTION, 60,30,191,14, ES_AUTOVSCROLL|ES_MULTILINE|WS_TABSTOP|WS_VSCROLL - GROUPBOX "Propósitos do Certificado", -1,6,48,245,165, BS_GROUPBOX - AUTORADIOBUTTON "&Activar todos os propósitos para este certificado", - IDC_ENABLE_ALL_PURPOSES, 12,58,180,14, BS_AUTORADIOBUTTON|WS_TABSTOP - AUTORADIOBUTTON "D&esactivar todos os propósitos para este certificado", - IDC_DISABLE_ALL_PURPOSES, 12,70,180,14, BS_AUTORADIOBUTTON - AUTORADIOBUTTON "A&ctivar apenas os seguintes propósitos para este certificado:", - IDC_ENABLE_SELECTED_PURPOSES, 12,82,180,14, BS_AUTORADIOBUTTON - CONTROL "", IDC_CERTIFICATE_USAGES,"SysListView32", - LVS_REPORT|LVS_NOCOLUMNHEADER|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 24,100,220,90 - PUSHBUTTON "Adicionar &Propósito...", IDC_ADD_PURPOSE,184,194,60,14 -END - -IDD_ADD_CERT_PURPOSE DIALOG DISCARDABLE 0,0,200,68 -CAPTION "Adicionar Propósito" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Adicione o identificador de objecto (OID) para o propósito que deseja adicionar:", - -1, 6,6,190,28 - EDITTEXT IDC_NEW_PURPOSE, 6,28,190,14, ES_AUTOVSCROLL|ES_MULTILINE|WS_TABSTOP|WS_VSCROLL - PUSHBUTTON "OK", IDOK, 33,48,60,14 - PUSHBUTTON "Cancelar", IDCANCEL, 100,48,60,14 -END - -IDD_SELECT_STORE DIALOG DISCARDABLE 0,0,200,136 -CAPTION "Seleccione Conjunto de Certificados" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Seleccione o conjunto de certificados que deseja usar:", IDC_STORE_TEXT, 6,6,190,28 - CONTROL "",IDC_STORE_LIST, "SysTreeView32", TVS_HASLINES|WS_BORDER|WS_TABSTOP, - 6,28,188,70 - CHECKBOX "&Mostrar conjuntos físicos", IDC_SHOW_PHYSICAL_STORES, 6,102,90,14, - BS_AUTOCHECKBOX|WS_TABSTOP - PUSHBUTTON "OK", IDOK, 90,118,50,14, BS_DEFPUSHBUTTON - PUSHBUTTON "Cancelar", IDCANCEL, 144,118,50,14 -END - -IDD_IMPORT_WELCOME DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistente de Importação de Certificados" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Benvindo ao Assistente de Importação de Certificados", IDC_IMPORT_TITLE, - 115,7,195,12 - LTEXT "Este assistente vai ajudá-lo a importar certificados, listas de revogação de certificados e listas de certificados confiáveis a partir de um ficheiro para um conjunto de certificados.", - -1, 115,26,195,25 - LTEXT "Um certificado pode ser usado para identificá-lo ou ao computador do qual está a comunicar. Também pode ser usado para autenticação e para assinar mensagens. Conjuntos de certificados são colecções de certificados, listas de revogação de certificados e listas de certificados confiáveis.", - -1, 115,56,195,40 - LTEXT "Para continuar clique em Seguinte.", - -1, 115,103,195,8 -END - -IDD_IMPORT_FILE DIALOG DISCARDABLE 0,0,317,178 -CAPTION "Assistente de Importação de Certificados" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Nome do ficheiro:", -1, 21,1,195,10 - EDITTEXT IDC_IMPORT_FILENAME, 21,11,208,14, ES_AUTOHSCROLL|WS_TABSTOP - PUSHBUTTON "&Procurar...", IDC_IMPORT_BROWSE_FILE, 236,11,60,14 - LTEXT "Nota: os seguintes formatos de ficheiro podem conter mais que um certificado, lista de revogação de certificados ou lista de certificados confiáveis:", - -1, 21,26,265,16 - LTEXT "Cryptographic Message Syntax Standard/PKCS #7 Messages (.p7b)", - -1, 31,49,265,10 - LTEXT "Personal Information Exchange/PKCS #12 (.pfx, .p12)", - -1, 31,64,265,10 - LTEXT "Microsoft Serialized Certificate Store (.sst)", - -1, 31,79,265,10 -END - -IDD_IMPORT_STORE DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistente de Importação de Certificados" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "O Wine pode automaticamente seleccionar o conjunto de certificados ou você pode especificar a localização para os certificados.", - -1, 21,1,195,20 - AUTORADIOBUTTON "&Seleccionar conjunto de certificados automaticamente", - IDC_IMPORT_AUTO_STORE, 31,18,180,12, BS_AUTORADIOBUTTON|WS_TABSTOP - AUTORADIOBUTTON "&Colocar todos os certificados no seguinte conjunto:", - IDC_IMPORT_SPECIFY_STORE, 31,30,180,12, BS_AUTORADIOBUTTON - EDITTEXT IDC_IMPORT_STORE, 44,49,185,14, ES_READONLY - PUSHBUTTON "&Procurar...", IDC_IMPORT_BROWSE_STORE, 236,49,60,14 -END - -IDD_IMPORT_FINISH DIALOG DISCARDABLE 0,0,317,178 -CAPTION "Assistente de Importação de Certificados" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "A completar o Assistente de Importação de Certificados", IDC_IMPORT_TITLE, - 115,1,195,40 - LTEXT "Completou com sucesso o Assistente de Importação de Certificados.", - -1, 115,33,195,24 - LTEXT "Especificou as seguintes configurações:", - -1, 115,57,195,12 - CONTROL "", IDC_IMPORT_SETTINGS, "SysListView32", - LVS_REPORT|LVS_NOCOLUMNHEADER|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 115,67,174,100 -END - -IDD_CERT_MGR DIALOG DISCARDABLE 0,0,335,270 -CAPTION "Certificados" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Com o propósito:", -1, 7,9,100,12 - COMBOBOX IDC_MGR_PURPOSE_SELECTION, 83,7,245,14, - CBS_DROPDOWNLIST|WS_BORDER|WS_VSCROLL|WS_TABSTOP - CONTROL "", IDC_MGR_STORES, "SysTabControl32", - WS_CLIPSIBLINGS|WS_TABSTOP, 7,25,321,140 - CONTROL "", IDC_MGR_CERTS, "SysListView32", - LVS_REPORT|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, 15,46,305,111 - PUSHBUTTON "&Importar...", IDC_MGR_IMPORT, 7,172,51,14 - PUSHBUTTON "&Exportar...", IDC_MGR_EXPORT, 62,172,51,14, WS_DISABLED - PUSHBUTTON "&Remover", IDC_MGR_REMOVE, 117,172,51,14, WS_DISABLED - PUSHBUTTON "&Avançadas...", IDC_MGR_ADVANCED, 277,172,51,14 - GROUPBOX "Propósitos do Certificado", -1,7,194,321,47, BS_GROUPBOX - LTEXT "", IDC_MGR_PURPOSES, 13,208,252,30 - PUSHBUTTON "&Ver...", IDC_MGR_VIEW, 269,218,51,14, WS_DISABLED - PUSHBUTTON "&Fechar", IDCANCEL, 277,249,51,14, BS_DEFPUSHBUTTON -END - -IDD_CERT_MGR_ADVANCED DIALOG DISCARDABLE 0,0,248,176 -CAPTION "Opções Avançadas" -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "Propósito do certificado", -1, 7,7,234,141, BS_GROUPBOX - LTEXT "Seleccione um ou mais propósitos a serem listados quando Propósitos Avançados estiver seleccionado.", - -1, 14,18,220,16 - LTEXT "&Propósitos de Certificados:", -1, 14,41,90,12, WS_TABSTOP - CONTROL "", IDC_CERTIFICATE_USAGES,"SysListView32", - LVS_REPORT|LVS_NOCOLUMNHEADER|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 14,51,220,90 - PUSHBUTTON "OK", IDOK, 132,155,51,14, BS_DEFPUSHBUTTON - PUSHBUTTON "Cancelar", IDCANCEL, 190,155,51,14 -END - -IDD_EXPORT_WELCOME DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistente de Exportação de Certificados" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Benvindo ao Assistente de Exportação de Certificados", IDC_EXPORT_TITLE, - 115,7,195,12 - LTEXT "Este assostente vai ajudá-lo a exportar certificados, listas de revogação de certificados e listas de certificados confiáveis a partir de um conjunto de certificados para um ficheiro.", - -1, 115,26,195,25 - LTEXT "Um certificado pode ser usado para identificá-lo ou ao computador de onde está a comunicar. Pode também ser usado para autenticação e para assinar mensagens. Conjuntos de certificados são colecções de certificados, listas de revogação de certificados e listas de certificados confiáveis.", - -1, 115,56,195,40 - LTEXT "Para continuar clique em Seguinte.", - -1, 115,103,195,8 -END - -IDD_EXPORT_PRIVATE_KEY DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistente de Exportação de Certificados" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Se escolher exportar a chave privada será pedida uma palavra-passe para proteger a chave privada mais à frente.", -1, 21,1,195,25 - LTEXT "Deseja exportar a chave privada?", -1, 21,27,195,10 - AUTORADIOBUTTON "&Sim, exportar a chave privada", - IDC_EXPORT_PRIVATE_KEY_YES, 31,36,200,12, BS_AUTORADIOBUTTON|WS_TABSTOP - AUTORADIOBUTTON "&Não exportar a chave privada", - IDC_EXPORT_PRIVATE_KEY_NO, 31,48,200,12, BS_AUTORADIOBUTTON - LTEXT "", IDC_EXPORT_PRIVATE_KEY_UNAVAILABLE, 21,60,200,24 -END - -IDD_EXPORT_PASSWORD DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistente de Exportação de Certificados" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Palavra-passe:", -1, 21,1,195,10 - EDITTEXT IDC_EXPORT_PASSWORD, 21,11,208,14, ES_AUTOHSCROLL|WS_TABSTOP - LTEXT "&Confirmar palavra-passe:", -1, 21,35,195,10 - EDITTEXT IDC_EXPORT_PASSWORD_CONFIRM, 21,45,208,14, ES_AUTOHSCROLL|WS_TABSTOP -END - -IDD_EXPORT_FORMAT DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistente de Exportação de Certificados" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Seleccione o formato que deseja utilizar:", -1, 21,1,195,10 - AUTORADIOBUTTON "&DER-encoded X.509 (.cer)", - IDC_EXPORT_FORMAT_DER, 31,18,240,12, BS_AUTORADIOBUTTON|WS_TABSTOP - AUTORADIOBUTTON "Ba&se64-encoded X.509 (.cer):", - IDC_EXPORT_FORMAT_BASE64, 31,30,240,12, BS_AUTORADIOBUTTON - AUTORADIOBUTTON "&Cryptographic Message Syntax Standard/PKCS #7 Message (.p7b)", - IDC_EXPORT_FORMAT_CMS, 31,42,240,12, BS_AUTORADIOBUTTON - CHECKBOX "&Include all certificates in the certification path if possible", - IDC_EXPORT_CMS_INCLUDE_CHAIN, 44,57,240,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED - AUTORADIOBUTTON "&Personal Information Exchange/PKCS #12 (.pfx)", - IDC_EXPORT_FORMAT_PFX, 31,72,240,12, BS_AUTORADIOBUTTON|WS_DISABLED - CHECKBOX "&Incluir todos os certificados no caminho de certificação se possível", - IDC_EXPORT_PFX_INCLUDE_CHAIN, 44,87,240,8, BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED - CHECKBOX "&Activar cifra forte", - IDC_EXPORT_PFX_STRONG_ENCRYPTION, 44,102,240,8, - BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED - CHECKBOX "&Apagar a chave privada se a exportação for bem sucedida", - IDC_EXPORT_PFX_DELETE_PRIVATE_KEY, 44,117,240,8, - BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED -END - -IDD_EXPORT_FILE DIALOG DISCARDABLE 0,0,317,143 -CAPTION "Assistente de Exportação de Certificados" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Nome do ficheiro:", -1, 21,1,195,10 - EDITTEXT IDC_EXPORT_FILENAME, 21,11,208,14, ES_AUTOHSCROLL|WS_TABSTOP - PUSHBUTTON "&Procurar...", IDC_EXPORT_BROWSE_FILE, 236,11,60,14 -END - -IDD_EXPORT_FINISH DIALOG DISCARDABLE 0,0,317,178 -CAPTION "Assistente de Exportação de Certificados" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "A completar o Assistente de Exportação de Certificados", IDC_EXPORT_TITLE, - 115,1,195,40 - LTEXT "Completou com sucesso o Assistente de Exportação de Certificados.", - -1, 115,33,195,24 - LTEXT "Especificou as seguintes configurações:", - -1, 115,57,195,12 - CONTROL "", IDC_EXPORT_SETTINGS, "SysListView32", - LVS_REPORT|LVS_NOCOLUMNHEADER|LVS_SINGLESEL|WS_CHILD|WS_VISIBLE|WS_TABSTOP|WS_BORDER, - 115,67,174,100 -END diff --git a/dlls/cryptui/cryptuires.h b/dlls/cryptui/cryptuires.h index 716dba5e3a6..b46ea4e128e 100644 --- a/dlls/cryptui/cryptuires.h +++ b/dlls/cryptui/cryptuires.h @@ -18,10 +18,6 @@ #ifndef __CRYPTUIRES_H_ #define __CRYPTUIRES_H_ -#include -#include -#include - #define IDS_CERTIFICATE 1000 #define IDS_CERTIFICATEINFORMATION 1001 #define IDS_CERT_INFO_BAD_SIG 1002 diff --git a/dlls/cryptui/main.c b/dlls/cryptui/main.c index 980706434a1..f15420b4bca 100644 --- a/dlls/cryptui/main.c +++ b/dlls/cryptui/main.c @@ -2146,7 +2146,7 @@ static CRYPT_OBJID_BLOB *find_policy_qualifier(CERT_POLICIES_INFO *policies, return ret; } -static WCHAR *get_cps_str_from_qualifier(const CRYPT_OBJID_BLOB *qualifier) +static WCHAR *get_cps_str_from_qualifier(CRYPT_OBJID_BLOB *qualifier) { LPWSTR qualifierStr = NULL; CERT_NAME_VALUE *qualifierValue; @@ -2167,7 +2167,7 @@ static WCHAR *get_cps_str_from_qualifier(const CRYPT_OBJID_BLOB *qualifier) return qualifierStr; } -static WCHAR *get_user_notice_from_qualifier(const CRYPT_OBJID_BLOB *qualifier) +static WCHAR *get_user_notice_from_qualifier(CRYPT_OBJID_BLOB *qualifier) { LPWSTR str = NULL; CERT_POLICY_QUALIFIER_USER_NOTICE *qualifierValue; @@ -2773,7 +2773,7 @@ static void add_v1_fields(HWND hwnd, struct detail_data *data) add_v1_field(hwnd, data, &v1_fields[i]); } -static WCHAR *crypt_format_extension(const CERT_EXTENSION *ext, DWORD formatStrType) +static WCHAR *crypt_format_extension(PCERT_EXTENSION ext, DWORD formatStrType) { WCHAR *str = NULL; DWORD size; @@ -2788,7 +2788,7 @@ static WCHAR *crypt_format_extension(const CERT_EXTENSION *ext, DWORD formatStrT return str; } -static WCHAR *field_format_extension_hex_with_ascii(const CERT_EXTENSION *ext) +static WCHAR *field_format_extension_hex_with_ascii(PCERT_EXTENSION ext) { WCHAR *str = NULL; @@ -3986,7 +3986,7 @@ static void show_cert_chain(HWND hwnd, struct hierarchy_data *data) } } -static void set_certificate_status(HWND hwnd, const CRYPT_PROVIDER_CERT *cert) +static void set_certificate_status(HWND hwnd, CRYPT_PROVIDER_CERT *cert) { /* Select all the text in the control, the next update will replace it */ SendMessageW(hwnd, EM_SETSEL, 0, -1); @@ -5171,7 +5171,6 @@ static LRESULT CALLBACK import_store_dlg_proc(HWND hwnd, UINT msg, WPARAM wp, selectInfo.parent = hwnd; selectInfo.dwFlags = CRYPTUI_ENABLE_SHOW_PHYSICAL_STORE; selectInfo.pwszTitle = NULL; - selectInfo.pwszText = NULL; selectInfo.pEnumData = &enumData; selectInfo.pfnSelectedStoreCallback = NULL; if ((store = CryptUIDlgSelectStoreW(&selectInfo))) @@ -5603,7 +5602,7 @@ static PCRYPT_KEY_PROV_INFO export_get_private_key_info(PCCERT_CONTEXT cert) return info; } -static BOOL export_acquire_private_key(const CRYPT_KEY_PROV_INFO *info, +static BOOL export_acquire_private_key(PCRYPT_KEY_PROV_INFO info, HCRYPTPROV *phProv) { BOOL ret; @@ -5734,7 +5733,7 @@ static BOOL export_info_has_private_key(PCCRYPTUI_WIZ_EXPORT_INFO pExportInfo) return ret; } -static void export_format_enable_controls(HWND hwnd, const struct ExportWizData *data) +static void export_format_enable_controls(HWND hwnd, struct ExportWizData *data) { int defaultFormatID; @@ -5875,7 +5874,7 @@ static LRESULT CALLBACK export_format_dlg_proc(HWND hwnd, UINT msg, WPARAM wp, return ret; } -static void export_password_mismatch(HWND hwnd, const struct ExportWizData *data) +static void export_password_mismatch(HWND hwnd, struct ExportWizData *data) { WCHAR title[MAX_STRING_LEN], error[MAX_STRING_LEN]; LPCWSTR pTitle; @@ -5980,7 +5979,7 @@ static LRESULT CALLBACK export_password_dlg_proc(HWND hwnd, UINT msg, return ret; } -static LPWSTR export_append_extension(const struct ExportWizData *data, +static LPWSTR export_append_extension(struct ExportWizData *data, LPWSTR fileName) { static const WCHAR cer[] = { '.','c','e','r',0 }; @@ -6306,7 +6305,7 @@ static LRESULT CALLBACK export_file_dlg_proc(HWND hwnd, UINT msg, WPARAM wp, return ret; } -static void show_export_details(HWND lv, const struct ExportWizData *data) +static void show_export_details(HWND lv, struct ExportWizData *data) { WCHAR text[MAX_STRING_LEN]; LVITEMW item; @@ -6784,7 +6783,7 @@ static LRESULT CALLBACK export_finish_dlg_proc(HWND hwnd, UINT msg, WPARAM wp, } static BOOL show_export_ui(DWORD dwFlags, HWND hwndParent, - LPCWSTR pwszWizardTitle, PCCRYPTUI_WIZ_EXPORT_INFO pExportInfo, const void *pvoid) + LPCWSTR pwszWizardTitle, PCCRYPTUI_WIZ_EXPORT_INFO pExportInfo, void *pvoid) { PROPSHEETHEADERW hdr; PROPSHEETPAGEW pages[6]; diff --git a/dlls/ctl3d.dll16/Makefile.in b/dlls/ctl3d.dll16/Makefile.in index 7c9726b8c86..fa371d35238 100644 --- a/dlls/ctl3d.dll16/Makefile.in +++ b/dlls/ctl3d.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = ctl3d.dll16 IMPORTS = user32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,ctl3d32.dll +SPEC_SRCS = ctl3d.dll16.spec + C_SRCS = ctl3d.c @MAKE_DLL_RULES@ diff --git a/dlls/ctl3dv2.dll16/Makefile.in b/dlls/ctl3dv2.dll16/Makefile.in index 99fc9195309..a9bc16350a9 100644 --- a/dlls/ctl3dv2.dll16/Makefile.in +++ b/dlls/ctl3dv2.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = ctl3dv2.dll16 IMPORTS = user32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,ctl3d32.dll +SPEC_SRCS = ctl3dv2.dll16.spec + C_SRCS = ctl3d.c @MAKE_DLL_RULES@ diff --git a/dlls/d3d10/d3d10_private.h b/dlls/d3d10/d3d10_private.h index 60f2aa0198e..c5a74aa54a3 100644 --- a/dlls/d3d10/d3d10_private.h +++ b/dlls/d3d10/d3d10_private.h @@ -31,17 +31,17 @@ /* TRACE helper functions */ const char *debug_d3d10_driver_type(D3D10_DRIVER_TYPE driver_type); -enum d3d10_effect_object_type +enum d3d10_effect_variable_type { - D3D10_EOT_VERTEXSHADER = 6, - D3D10_EOT_PIXELSHADER = 7, - D3D10_EOT_GEOMETRYSHADER = 8, + D3D10_EVT_VERTEXSHADER = 6, + D3D10_EVT_PIXELSHADER = 7, + D3D10_EVT_GEOMETRYSHADER = 8, }; -struct d3d10_effect_object +struct d3d10_effect_variable { struct d3d10_effect_pass *pass; - enum d3d10_effect_object_type type; + enum d3d10_effect_variable_type type; DWORD idx_offset; void *data; }; @@ -58,23 +58,6 @@ struct d3d10_effect_shader_variable } shader; }; -/* ID3D10EffectVariable */ -struct d3d10_effect_variable -{ - const struct ID3D10EffectVariableVtbl *vtbl; - - char *name; - DWORD buffer_offset; -}; - -struct d3d10_effect_local_buffer -{ - char *name; - DWORD data_size; - DWORD variable_count; - struct d3d10_effect_variable *variables; -}; - /* ID3D10EffectPass */ struct d3d10_effect_pass { @@ -83,8 +66,8 @@ struct d3d10_effect_pass struct d3d10_effect_technique *technique; char *name; DWORD start; - DWORD object_count; - struct d3d10_effect_object *objects; + DWORD variable_count; + struct d3d10_effect_variable *variables; }; /* ID3D10EffectTechnique */ @@ -94,6 +77,7 @@ struct d3d10_effect_technique struct d3d10_effect *effect; char *name; + DWORD start; DWORD pass_count; struct d3d10_effect_pass *passes; }; @@ -107,7 +91,7 @@ struct d3d10_effect ID3D10Device *device; DWORD version; - DWORD local_buffer_count; + DWORD localbuffers_count; DWORD localobjects_count; DWORD sharedbuffers_count; DWORD sharedobjects_count; @@ -117,8 +101,6 @@ struct d3d10_effect DWORD blendstate_count; DWORD rasterizerstate_count; DWORD samplerstate_count; - - struct d3d10_effect_local_buffer *local_buffers; struct d3d10_effect_technique *techniques; }; diff --git a/dlls/d3d10/effect.c b/dlls/d3d10/effect.c index 37d2dcb9fbf..8316db8f9b8 100644 --- a/dlls/d3d10/effect.c +++ b/dlls/d3d10/effect.c @@ -33,7 +33,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3d10); static const struct ID3D10EffectTechniqueVtbl d3d10_effect_technique_vtbl; static const struct ID3D10EffectPassVtbl d3d10_effect_pass_vtbl; -static const struct ID3D10EffectVariableVtbl d3d10_effect_variable_vtbl; static inline void read_dword(const char **ptr, DWORD *d) { @@ -125,22 +124,75 @@ static HRESULT parse_dxbc(const char *data, SIZE_T data_size, return hr; } -static char *copy_name(const char *ptr) +static HRESULT parse_fx10_pass_index(struct d3d10_effect_pass *p, const char **ptr) { - size_t name_len; - char *name; + unsigned int i; - name_len = strlen(ptr) + 1; - name = HeapAlloc(GetProcessHeap(), 0, name_len); - if (!name) + read_dword(ptr, &p->start); + TRACE("Pass starts at offset %#x\n", p->start); + + read_dword(ptr, &p->variable_count); + TRACE("Pass has %u variables\n", p->variable_count); + + skip_dword_unknown(ptr, 1); + + p->variables = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, p->variable_count * sizeof(*p->variables)); + if (!p->variables) { - ERR("Failed to allocate name memory.\n"); - return NULL; + ERR("Failed to allocate variables memory\n"); + return E_OUTOFMEMORY; } - memcpy(name, ptr, name_len); + for (i = 0; i < p->variable_count; ++i) + { + struct d3d10_effect_variable *v = &p->variables[i]; + + v->pass = p; + + read_dword(ptr, &v->type); + TRACE("Variable %u is of type %#x\n", i, v->type); + + skip_dword_unknown(ptr, 2); + + read_dword(ptr, &v->idx_offset); + TRACE("Variable %u idx is at offset %#x\n", i, v->idx_offset); + } + + return S_OK; +} + +static HRESULT parse_fx10_technique_index(struct d3d10_effect_technique *t, const char **ptr) +{ + HRESULT hr = S_OK; + unsigned int i; + + read_dword(ptr, &t->start); + TRACE("Technique starts at offset %#x\n", t->start); + + read_dword(ptr, &t->pass_count); + TRACE("Technique has %u passes\n", t->pass_count); + + skip_dword_unknown(ptr, 1); + + t->passes = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, t->pass_count * sizeof(*t->passes)); + if (!t->passes) + { + ERR("Failed to allocate passes memory\n"); + return E_OUTOFMEMORY; + } + + for (i = 0; i < t->pass_count; ++i) + { + struct d3d10_effect_pass *p = &t->passes[i]; + + p->vtbl = &d3d10_effect_pass_vtbl; + p->technique = t; + + hr = parse_fx10_pass_index(p, ptr); + if (FAILED(hr)) break; + } - return name; + return hr; } static HRESULT shader_chunk_handler(const char *data, DWORD data_size, DWORD tag, void *ctx) @@ -207,16 +259,16 @@ static HRESULT shader_chunk_handler(const char *data, DWORD data_size, DWORD tag return S_OK; } -static HRESULT parse_shader(struct d3d10_effect_object *o, const char *data) +static HRESULT parse_shader(struct d3d10_effect_variable *v, const char *data) { - ID3D10Device *device = o->pass->technique->effect->device; + ID3D10Device *device = v->pass->technique->effect->device; struct d3d10_effect_shader_variable *s; const char *ptr = data; DWORD dxbc_size; HRESULT hr; - o->data = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(struct d3d10_effect_shader_variable)); - if (!o->data) + v->data = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(struct d3d10_effect_shader_variable)); + if (!v->data) { ERR("Failed to allocate shader variable memory\n"); return E_OUTOFMEMORY; @@ -224,23 +276,23 @@ static HRESULT parse_shader(struct d3d10_effect_object *o, const char *data) if (!ptr) return S_OK; - s = o->data; + s = v->data; read_dword(&ptr, &dxbc_size); TRACE("dxbc size: %#x\n", dxbc_size); - switch (o->type) + switch (v->type) { - case D3D10_EOT_VERTEXSHADER: + case D3D10_EVT_VERTEXSHADER: hr = ID3D10Device_CreateVertexShader(device, ptr, dxbc_size, &s->shader.vs); if (FAILED(hr)) return hr; break; - case D3D10_EOT_PIXELSHADER: + case D3D10_EVT_PIXELSHADER: hr = ID3D10Device_CreatePixelShader(device, ptr, dxbc_size, &s->shader.ps); if (FAILED(hr)) return hr; break; - case D3D10_EOT_GEOMETRYSHADER: + case D3D10_EVT_GEOMETRYSHADER: hr = ID3D10Device_CreateGeometryShader(device, ptr, dxbc_size, &s->shader.gs); if (FAILED(hr)) return hr; break; @@ -249,55 +301,47 @@ static HRESULT parse_shader(struct d3d10_effect_object *o, const char *data) return parse_dxbc(ptr, dxbc_size, shader_chunk_handler, s); } -static HRESULT parse_fx10_object(struct d3d10_effect_object *o, const char **ptr, const char *data) +static HRESULT parse_fx10_variable(struct d3d10_effect_variable *v, const char *data) { - const char *data_ptr; + const char *ptr; DWORD offset; HRESULT hr; - read_dword(ptr, &o->type); - TRACE("Effect object is of type %#x.\n", o->type); - - skip_dword_unknown(ptr, 2); + ptr = data + v->idx_offset; + read_dword(&ptr, &offset); - read_dword(ptr, &offset); - TRACE("Effect object idx is at offset %#x.\n", offset); - - data_ptr = data + offset; - read_dword(&data_ptr, &offset); - - TRACE("Effect object starts at offset %#x.\n", offset); + TRACE("Variable of type %#x starts at offset %#x\n", v->type, offset); /* FIXME: This probably isn't completely correct. */ if (offset == 1) { - WARN("Skipping effect object.\n"); - data_ptr = NULL; + WARN("Skipping variable\n"); + ptr = NULL; } else { - data_ptr = data + offset; + ptr = data + offset; } - switch (o->type) + switch (v->type) { - case D3D10_EOT_VERTEXSHADER: + case D3D10_EVT_VERTEXSHADER: TRACE("Vertex shader\n"); - hr = parse_shader(o, data_ptr); + hr = parse_shader(v, ptr); break; - case D3D10_EOT_PIXELSHADER: + case D3D10_EVT_PIXELSHADER: TRACE("Pixel shader\n"); - hr = parse_shader(o, data_ptr); + hr = parse_shader(v, ptr); break; - case D3D10_EOT_GEOMETRYSHADER: + case D3D10_EVT_GEOMETRYSHADER: TRACE("Geometry shader\n"); - hr = parse_shader(o, data_ptr); + hr = parse_shader(v, ptr); break; default: - FIXME("Unhandled object type %#x\n", o->type); + FIXME("Unhandled variable type %#x\n", v->type); hr = E_FAIL; break; } @@ -305,178 +349,75 @@ static HRESULT parse_fx10_object(struct d3d10_effect_object *o, const char **ptr return hr; } -static HRESULT parse_fx10_pass(struct d3d10_effect_pass *p, const char **ptr, const char *data) +static HRESULT parse_fx10_pass(struct d3d10_effect_pass *p, const char *data) { HRESULT hr = S_OK; + const char *ptr; + size_t name_len; unsigned int i; - DWORD offset; - read_dword(ptr, &offset); - TRACE("Pass name at offset %#x.\n", offset); + ptr = data + p->start; - p->name = copy_name(data + offset); + name_len = strlen(ptr) + 1; + p->name = HeapAlloc(GetProcessHeap(), 0, name_len); if (!p->name) { - ERR("Failed to copy name.\n"); + ERR("Failed to allocate name memory\n"); return E_OUTOFMEMORY; } - TRACE("Pass name: %s.\n", p->name); - read_dword(ptr, &p->object_count); - TRACE("Pass has %u effect objects.\n", p->object_count); + memcpy(p->name, ptr, name_len); + ptr += name_len; - skip_dword_unknown(ptr, 1); - - p->objects = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, p->object_count * sizeof(*p->objects)); - if (!p->objects) - { - ERR("Failed to allocate effect objects memory.\n"); - return E_OUTOFMEMORY; - } + TRACE("pass name: %s\n", p->name); - for (i = 0; i < p->object_count; ++i) + for (i = 0; i < p->variable_count; ++i) { - struct d3d10_effect_object *o = &p->objects[i]; - - o->pass = p; - - hr = parse_fx10_object(o, ptr, data); - if (FAILED(hr)) return hr; + hr = parse_fx10_variable(&p->variables[i], data); + if (FAILED(hr)) break; } return hr; } -static HRESULT parse_fx10_technique(struct d3d10_effect_technique *t, const char **ptr, const char *data) +static HRESULT parse_fx10_technique(struct d3d10_effect_technique *t, const char *data) { + HRESULT hr = S_OK; + const char *ptr; + size_t name_len; unsigned int i; - DWORD offset; - read_dword(ptr, &offset); - TRACE("Technique name at offset %#x.\n", offset); + ptr = data + t->start; - t->name = copy_name(data + offset); + name_len = strlen(ptr) + 1; + t->name = HeapAlloc(GetProcessHeap(), 0, name_len); if (!t->name) { - ERR("Failed to copy name.\n"); + ERR("Failed to allocate name memory\n"); return E_OUTOFMEMORY; } - TRACE("Technique name: %s.\n", t->name); - - read_dword(ptr, &t->pass_count); - TRACE("Technique has %u passes\n", t->pass_count); - skip_dword_unknown(ptr, 1); + memcpy(t->name, ptr, name_len); + ptr += name_len; - t->passes = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, t->pass_count * sizeof(*t->passes)); - if (!t->passes) - { - ERR("Failed to allocate passes memory\n"); - return E_OUTOFMEMORY; - } + TRACE("technique name: %s\n", t->name); for (i = 0; i < t->pass_count; ++i) { - struct d3d10_effect_pass *p = &t->passes[i]; - HRESULT hr; - - p->vtbl = &d3d10_effect_pass_vtbl; - p->technique = t; - - hr = parse_fx10_pass(p, ptr, data); - if (FAILED(hr)) return hr; - } - - return S_OK; -} - -static HRESULT parse_fx10_variable(struct d3d10_effect_variable *v, const char **ptr, const char *data) -{ - DWORD offset; - - read_dword(ptr, &offset); - TRACE("Variable name at offset %#x.\n", offset); - - v->name = copy_name(data + offset); - if (!v->name) - { - ERR("Failed to copy name.\n"); - return E_OUTOFMEMORY; - } - TRACE("Variable name: %s.\n", v->name); - - read_dword(ptr, &offset); - TRACE("Variable type info at offset %#x.\n", offset); - - skip_dword_unknown(ptr, 1); - - read_dword(ptr, &v->buffer_offset); - TRACE("Variable offset in buffer: %#x.\n", v->buffer_offset); - - skip_dword_unknown(ptr, 3); - - return S_OK; -} - -static HRESULT parse_fx10_local_buffer(struct d3d10_effect_local_buffer *l, const char **ptr, const char *data) -{ - unsigned int i; - DWORD offset; - - read_dword(ptr, &offset); - TRACE("Local buffer name at offset %#x.\n", offset); - - l->name = copy_name(data + offset); - if (!l->name) - { - ERR("Failed to copy name.\n"); - return E_OUTOFMEMORY; - } - TRACE("Local buffer name: %s.\n", l->name); - - read_dword(ptr, &l->data_size); - TRACE("Local buffer data size: %#x.\n", l->data_size); - - skip_dword_unknown(ptr, 1); - - read_dword(ptr, &l->variable_count); - TRACE("Local buffer variable count: %#x.\n", l->variable_count); - - skip_dword_unknown(ptr, 2); - - l->variables = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, l->variable_count * sizeof(*l->variables)); - if (!l->variables) - { - ERR("Failed to allocate variables memory.\n"); - return E_OUTOFMEMORY; - } - - for (i = 0; i < l->variable_count; ++i) - { - struct d3d10_effect_variable *v = &l->variables[i]; - HRESULT hr; - - v->vtbl = &d3d10_effect_variable_vtbl; - - hr = parse_fx10_variable(v, ptr, data); - if (FAILED(hr)) return hr; + hr = parse_fx10_pass(&t->passes[i], data); + if (FAILED(hr)) break; } - return S_OK; + return hr; } static HRESULT parse_fx10_body(struct d3d10_effect *e, const char *data, DWORD data_size) { const char *ptr = data + e->index_offset; + HRESULT hr = S_OK; unsigned int i; - HRESULT hr; - e->local_buffers = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, e->local_buffer_count * sizeof(*e->local_buffers)); - if (!e->local_buffers) - { - ERR("Failed to allocate local buffer memory.\n"); - return E_OUTOFMEMORY; - } + skip_dword_unknown(&ptr, 6); e->techniques = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, e->technique_count * sizeof(*e->techniques)); if (!e->techniques) @@ -485,14 +426,6 @@ static HRESULT parse_fx10_body(struct d3d10_effect *e, const char *data, DWORD d return E_OUTOFMEMORY; } - for (i = 0; i < e->local_buffer_count; ++i) - { - struct d3d10_effect_local_buffer *l = &e->local_buffers[i]; - - hr = parse_fx10_local_buffer(l, &ptr, data); - if (FAILED(hr)) return hr; - } - for (i = 0; i < e->technique_count; ++i) { struct d3d10_effect_technique *t = &e->techniques[i]; @@ -500,11 +433,14 @@ static HRESULT parse_fx10_body(struct d3d10_effect *e, const char *data, DWORD d t->vtbl = &d3d10_effect_technique_vtbl; t->effect = e; - hr = parse_fx10_technique(t, &ptr, data); - if (FAILED(hr)) return hr; + hr = parse_fx10_technique_index(t, &ptr); + if (FAILED(hr)) break; + + hr = parse_fx10_technique(t, data); + if (FAILED(hr)) break; } - return S_OK; + return hr; } static HRESULT parse_fx10(struct d3d10_effect *e, const char *data, DWORD data_size) @@ -516,8 +452,8 @@ static HRESULT parse_fx10(struct d3d10_effect *e, const char *data, DWORD data_s read_dword(&ptr, &e->version); TRACE("Target: %#x\n", e->version); - read_dword(&ptr, &e->local_buffer_count); - TRACE("Local buffer count: %u.\n", e->local_buffer_count); + read_dword(&ptr, &e->localbuffers_count); + TRACE("Localbuffers count: %u\n", e->localbuffers_count); /* Number of variables in local buffers? */ read_dword(&ptr, &unknown); @@ -600,46 +536,46 @@ HRESULT d3d10_effect_parse(struct d3d10_effect *This, const void *data, SIZE_T d return parse_dxbc(data, data_size, fx10_chunk_handler, This); } -static void d3d10_effect_object_destroy(struct d3d10_effect_object *o) +static void d3d10_effect_variable_destroy(struct d3d10_effect_variable *v) { - TRACE("effect object %p.\n", o); + TRACE("variable %p\n", v); - switch(o->type) + switch(v->type) { - case D3D10_EOT_VERTEXSHADER: - case D3D10_EOT_PIXELSHADER: - case D3D10_EOT_GEOMETRYSHADER: - HeapFree(GetProcessHeap(), 0, ((struct d3d10_effect_shader_variable *)o->data)->input_signature); + case D3D10_EVT_VERTEXSHADER: + case D3D10_EVT_PIXELSHADER: + case D3D10_EVT_GEOMETRYSHADER: + HeapFree(GetProcessHeap(), 0, ((struct d3d10_effect_shader_variable *)v->data)->input_signature); break; default: break; } - HeapFree(GetProcessHeap(), 0, o->data); + HeapFree(GetProcessHeap(), 0, v->data); } -static HRESULT d3d10_effect_object_apply(struct d3d10_effect_object *o) +static HRESULT d3d10_effect_variable_apply(struct d3d10_effect_variable *v) { - ID3D10Device *device = o->pass->technique->effect->device; + ID3D10Device *device = v->pass->technique->effect->device; - TRACE("effect object %p, type %#x.\n", o, o->type); + TRACE("variable %p, type %#x\n", v, v->type); - switch(o->type) + switch(v->type) { - case D3D10_EOT_VERTEXSHADER: - ID3D10Device_VSSetShader(device, ((struct d3d10_effect_shader_variable *)o->data)->shader.vs); + case D3D10_EVT_VERTEXSHADER: + ID3D10Device_VSSetShader(device, ((struct d3d10_effect_shader_variable *)v->data)->shader.vs); return S_OK; - case D3D10_EOT_PIXELSHADER: - ID3D10Device_PSSetShader(device, ((struct d3d10_effect_shader_variable *)o->data)->shader.ps); + case D3D10_EVT_PIXELSHADER: + ID3D10Device_PSSetShader(device, ((struct d3d10_effect_shader_variable *)v->data)->shader.ps); return S_OK; - case D3D10_EOT_GEOMETRYSHADER: - ID3D10Device_GSSetShader(device, ((struct d3d10_effect_shader_variable *)o->data)->shader.gs); + case D3D10_EVT_GEOMETRYSHADER: + ID3D10Device_GSSetShader(device, ((struct d3d10_effect_shader_variable *)v->data)->shader.gs); return S_OK; default: - FIXME("Unhandled effect object type %#x.\n", o->type); + FIXME("Unhandled variable type %#x\n", v->type); return E_FAIL; } } @@ -649,14 +585,14 @@ static void d3d10_effect_pass_destroy(struct d3d10_effect_pass *p) TRACE("pass %p\n", p); HeapFree(GetProcessHeap(), 0, p->name); - if (p->objects) + if (p->variables) { unsigned int i; - for (i = 0; i < p->object_count; ++i) + for (i = 0; i < p->variable_count; ++i) { - d3d10_effect_object_destroy(&p->objects[i]); + d3d10_effect_variable_destroy(&p->variables[i]); } - HeapFree(GetProcessHeap(), 0, p->objects); + HeapFree(GetProcessHeap(), 0, p->variables); } } @@ -676,29 +612,6 @@ static void d3d10_effect_technique_destroy(struct d3d10_effect_technique *t) } } -static void d3d10_effect_variable_destroy(struct d3d10_effect_variable *v) -{ - TRACE("variable %p.\n", v); - - HeapFree(GetProcessHeap(), 0, v->name); -} - -static void d3d10_effect_local_buffer_destroy(struct d3d10_effect_local_buffer *l) -{ - TRACE("local buffer %p.\n", l); - - HeapFree(GetProcessHeap(), 0, l->name); - if (l->variables) - { - unsigned int i; - for (i = 0; i < l->variable_count; ++i) - { - d3d10_effect_variable_destroy(&l->variables[i]); - } - HeapFree(GetProcessHeap(), 0, l->variables); - } -} - /* IUnknown methods */ static HRESULT STDMETHODCALLTYPE d3d10_effect_QueryInterface(ID3D10Effect *iface, REFIID riid, void **object) @@ -738,26 +651,15 @@ static ULONG STDMETHODCALLTYPE d3d10_effect_Release(ID3D10Effect *iface) if (!refcount) { - unsigned int i; - if (This->techniques) { + unsigned int i; for (i = 0; i < This->technique_count; ++i) { d3d10_effect_technique_destroy(&This->techniques[i]); } HeapFree(GetProcessHeap(), 0, This->techniques); } - - if (This->local_buffers) - { - for (i = 0; i < This->local_buffer_count; ++i) - { - d3d10_effect_local_buffer_destroy(&This->local_buffers[i]); - } - HeapFree(GetProcessHeap(), 0, This->local_buffers); - } - ID3D10Device_Release(This->device); HeapFree(GetProcessHeap(), 0, This); } @@ -825,27 +727,7 @@ static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_GetVariableB static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_GetVariableByName(ID3D10Effect *iface, LPCSTR name) { - struct d3d10_effect *This = (struct d3d10_effect *)iface; - unsigned int i; - - TRACE("iface %p, name \"%s\"\n", iface, name); - - for (i = 0; i < This->local_buffer_count; ++i) - { - struct d3d10_effect_local_buffer *l = &This->local_buffers[i]; - unsigned int j; - - for (j = 0; j < l->variable_count; ++j) - { - struct d3d10_effect_variable *v = &l->variables[j]; - - if (!strcmp(v->name, name)) - { - TRACE("Returning variable %p.\n", v); - return (ID3D10EffectVariable *)v; - } - } - } + FIXME("iface %p, name \"%s\" stub!\n", iface, name); return NULL; } @@ -1056,12 +938,12 @@ static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_GetDesc(ID3D10EffectPass *ifa memset(desc, 0, sizeof(*desc)); desc->Name = This->name; - for (i = 0; i < This->object_count; ++i) + for (i = 0; i < This->variable_count; ++i) { - struct d3d10_effect_object *o = &This->objects[i]; - if (o->type == D3D10_EOT_VERTEXSHADER) + struct d3d10_effect_variable *v = &This->variables[i]; + if (v->type == D3D10_EVT_VERTEXSHADER) { - struct d3d10_effect_shader_variable *s = o->data; + struct d3d10_effect_shader_variable *s = v->data; desc->pIAInputSignature = (BYTE *)s->input_signature; desc->IAInputSignatureSize = s->input_signature_size; break; @@ -1121,9 +1003,9 @@ static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_Apply(ID3D10EffectPass *iface if (flags) FIXME("Ignoring flags (%#x)\n", flags); - for (i = 0; i < This->object_count; ++i) + for (i = 0; i < This->variable_count; ++i) { - hr = d3d10_effect_object_apply(&This->objects[i]); + hr = d3d10_effect_variable_apply(&This->variables[i]); if (FAILED(hr)) break; } @@ -1151,232 +1033,3 @@ static const struct ID3D10EffectPassVtbl d3d10_effect_pass_vtbl = d3d10_effect_pass_Apply, d3d10_effect_pass_ComputeStateBlockMask, }; - -/* ID3D10EffectVariable methods */ - -static BOOL STDMETHODCALLTYPE d3d10_effect_variable_IsValid(ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return FALSE; -} - -static struct ID3D10EffectType * STDMETHODCALLTYPE d3d10_effect_variable_GetType(ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static HRESULT STDMETHODCALLTYPE d3d10_effect_variable_GetDesc(ID3D10EffectVariable *iface, - D3D10_EFFECT_VARIABLE_DESC *desc) -{ - FIXME("iface %p, desc %p stub!\n", iface, desc); - - return E_NOTIMPL; -} - -static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_variable_GetAnnotationByIndex( - ID3D10EffectVariable *iface, UINT index) -{ - FIXME("iface %p, index %u stub!\n", iface, index); - - return NULL; -} - -static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_variable_GetAnnotationByName( - ID3D10EffectVariable *iface, LPCSTR name) -{ - FIXME("iface %p, name \"%s\" stub!\n", iface, name); - - return NULL; -} - -static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_variable_GetMemberByIndex( - ID3D10EffectVariable *iface, UINT index) -{ - FIXME("iface %p, index %u stub!\n", iface, index); - - return NULL; -} - -static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_variable_GetMemberByName( - ID3D10EffectVariable *iface, LPCSTR name) -{ - FIXME("iface %p, name \"%s\" stub!\n", iface, name); - - return NULL; -} - -static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_variable_GetMemberBySemantic( - ID3D10EffectVariable *iface, LPCSTR semantic) -{ - FIXME("iface %p, semantic \"%s\" stub!\n", iface, semantic); - - return NULL; -} - -static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_variable_GetElement( - ID3D10EffectVariable *iface, UINT index) -{ - FIXME("iface %p, index %u stub!\n", iface, index); - - return NULL; -} - -static struct ID3D10EffectConstantBuffer * STDMETHODCALLTYPE d3d10_effect_variable_GetParentConstantBuffer( - ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static struct ID3D10EffectScalarVariable * STDMETHODCALLTYPE d3d10_effect_variable_AsScalar( - ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static struct ID3D10EffectVectorVariable * STDMETHODCALLTYPE d3d10_effect_variable_AsVector( - ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static struct ID3D10EffectMatrixVariable * STDMETHODCALLTYPE d3d10_effect_variable_AsMatrix( - ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static struct ID3D10EffectStringVariable * STDMETHODCALLTYPE d3d10_effect_variable_AsString( - ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static struct ID3D10EffectShaderResourceVariable * STDMETHODCALLTYPE d3d10_effect_variable_AsShaderResource( - ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static struct ID3D10EffectRenderTargetViewVariable * STDMETHODCALLTYPE d3d10_effect_variable_AsRenderTargetView( - ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static struct ID3D10EffectDepthStencilViewVariable * STDMETHODCALLTYPE d3d10_effect_variable_AsDepthStencilView( - ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static struct ID3D10EffectConstantBuffer * STDMETHODCALLTYPE d3d10_effect_variable_AsConstantBuffer( - ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static struct ID3D10EffectShaderVariable * STDMETHODCALLTYPE d3d10_effect_variable_AsShader( - ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static struct ID3D10EffectBlendVariable * STDMETHODCALLTYPE d3d10_effect_variable_AsBlend(ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static struct ID3D10EffectDepthStencilVariable * STDMETHODCALLTYPE d3d10_effect_variable_AsDepthStencil( - ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static struct ID3D10EffectRasterizerVariable * STDMETHODCALLTYPE d3d10_effect_variable_AsRasterizer( - ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static struct ID3D10EffectSamplerVariable * STDMETHODCALLTYPE d3d10_effect_variable_AsSampler( - ID3D10EffectVariable *iface) -{ - FIXME("iface %p stub!\n", iface); - - return NULL; -} - -static HRESULT STDMETHODCALLTYPE d3d10_effect_variable_SetRawValue(ID3D10EffectVariable *iface, - void *data, UINT offset, UINT count) -{ - FIXME("iface %p, data %p, offset %u, count %u stub!\n", iface, data, offset, count); - - return E_NOTIMPL; -} - -static HRESULT STDMETHODCALLTYPE d3d10_effect_variable_GetRawValue(ID3D10EffectVariable *iface, - void *data, UINT offset, UINT count) -{ - FIXME("iface %p, data %p, offset %u, count %u stub!\n", iface, data, offset, count); - - return E_NOTIMPL; -} - -static const struct ID3D10EffectVariableVtbl d3d10_effect_variable_vtbl = -{ - /* ID3D10EffectVariable methods */ - d3d10_effect_variable_IsValid, - d3d10_effect_variable_GetType, - d3d10_effect_variable_GetDesc, - d3d10_effect_variable_GetAnnotationByIndex, - d3d10_effect_variable_GetAnnotationByName, - d3d10_effect_variable_GetMemberByIndex, - d3d10_effect_variable_GetMemberByName, - d3d10_effect_variable_GetMemberBySemantic, - d3d10_effect_variable_GetElement, - d3d10_effect_variable_GetParentConstantBuffer, - d3d10_effect_variable_AsScalar, - d3d10_effect_variable_AsVector, - d3d10_effect_variable_AsMatrix, - d3d10_effect_variable_AsString, - d3d10_effect_variable_AsShaderResource, - d3d10_effect_variable_AsRenderTargetView, - d3d10_effect_variable_AsDepthStencilView, - d3d10_effect_variable_AsConstantBuffer, - d3d10_effect_variable_AsShader, - d3d10_effect_variable_AsBlend, - d3d10_effect_variable_AsDepthStencil, - d3d10_effect_variable_AsRasterizer, - d3d10_effect_variable_AsSampler, - d3d10_effect_variable_SetRawValue, - d3d10_effect_variable_GetRawValue, -}; diff --git a/dlls/d3d8/directx.c b/dlls/d3d8/directx.c index 33abe8468ad..d39d3d64768 100644 --- a/dlls/d3d8/directx.c +++ b/dlls/d3d8/directx.c @@ -103,34 +103,30 @@ static UINT WINAPI IDirect3D8Impl_GetAdapterCount (LPDIRECT3D8 iface) { return hr; } -static HRESULT WINAPI IDirect3D8Impl_GetAdapterIdentifier(LPDIRECT3D8 iface, - UINT Adapter, DWORD Flags, D3DADAPTER_IDENTIFIER8 *pIdentifier) -{ +static HRESULT WINAPI IDirect3D8Impl_GetAdapterIdentifier (LPDIRECT3D8 iface, + UINT Adapter, DWORD Flags, D3DADAPTER_IDENTIFIER8* pIdentifier) { IDirect3D8Impl *This = (IDirect3D8Impl *)iface; WINED3DADAPTER_IDENTIFIER adapter_id; HRESULT hr; TRACE("(%p)->(%d,%08x, %p\n", This, Adapter, Flags, pIdentifier); - - adapter_id.driver = pIdentifier->Driver; - adapter_id.driver_size = sizeof(pIdentifier->Driver); - adapter_id.description = pIdentifier->Description; - adapter_id.description_size = sizeof(pIdentifier->Description); - adapter_id.device_name = NULL; /* d3d9 only */ - adapter_id.device_name_size = 0; /* d3d9 only */ - EnterCriticalSection(&d3d8_cs); + /* dx8 and dx9 have different structures to be filled in, with incompatible + layouts so pass in pointers to the places to be filled via an internal + structure */ + adapter_id.Driver = pIdentifier->Driver; + adapter_id.Description = pIdentifier->Description; + adapter_id.DeviceName = NULL; /* d3d9 only */ + adapter_id.DriverVersion = &pIdentifier->DriverVersion; + adapter_id.VendorId = &pIdentifier->VendorId; + adapter_id.DeviceId = &pIdentifier->DeviceId; + adapter_id.SubSysId = &pIdentifier->SubSysId; + adapter_id.Revision = &pIdentifier->Revision; + adapter_id.DeviceIdentifier = &pIdentifier->DeviceIdentifier; + adapter_id.WHQLLevel = &pIdentifier->WHQLLevel; + hr = IWineD3D_GetAdapterIdentifier(This->WineD3D, Adapter, Flags, &adapter_id); LeaveCriticalSection(&d3d8_cs); - - pIdentifier->DriverVersion = adapter_id.driver_version; - pIdentifier->VendorId = adapter_id.vendor_id; - pIdentifier->DeviceId = adapter_id.device_id; - pIdentifier->SubSysId = adapter_id.subsystem_id; - pIdentifier->Revision = adapter_id.revision; - memcpy(&pIdentifier->DeviceIdentifier, &adapter_id.device_identifier, sizeof(pIdentifier->DeviceIdentifier)); - pIdentifier->WHQLLevel = adapter_id.whql_level; - return hr; } diff --git a/dlls/d3d8/tests/device.c b/dlls/d3d8/tests/device.c index 97f64a1b8ea..f039a1b102f 100644 --- a/dlls/d3d8/tests/device.c +++ b/dlls/d3d8/tests/device.c @@ -144,13 +144,9 @@ static void test_mipmap_levels(void) check_mipmap_levels(pDevice, 1, 256, 9); check_mipmap_levels(pDevice, 1, 1, 1); -cleanup: - if (pDevice) - { - UINT refcount = IUnknown_Release( pDevice ); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IUnknown_Release( pD3d ); + cleanup: + if (pD3d) IUnknown_Release( pD3d ); + if (pDevice) IUnknown_Release( pDevice ); DestroyWindow( hwnd ); } @@ -263,16 +259,12 @@ static void test_swapchain(void) ok(backbuffer == (void *) 0xdeadbeef, "The back buffer pointer was modified (%p)\n", backbuffer); if(backbuffer && backbuffer != (void *) 0xdeadbeef) IDirect3DSurface8_Release(backbuffer); -cleanup: + cleanup: if(swapchain1) IDirect3DSwapChain8_Release(swapchain1); if(swapchain2) IDirect3DSwapChain8_Release(swapchain2); if(swapchain3) IDirect3DSwapChain8_Release(swapchain3); - if (pDevice) - { - UINT refcount = IDirect3DDevice8_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IDirect3D8_Release(pD3d); + if(pDevice) IDirect3DDevice8_Release(pDevice); + if(pD3d) IDirect3DDevice8_Release(pD3d); DestroyWindow( hwnd ); } @@ -699,12 +691,8 @@ static void test_cursor(void) ok(info.hCursor == cur, "The cursor handle is %p\n", info.hCursor); /* unchanged */ cleanup: - if (pDevice) - { - UINT refcount = IDirect3DDevice8_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IDirect3D8_Release(pD3d); + if(pD3d) IDirect3D8_Release(pD3d); + if(pDevice) IDirect3D8_Release(pDevice); } static void test_states(void) @@ -744,12 +732,8 @@ static void test_states(void) ok(hr == D3D_OK, "IDirect3DDevice8_SetRenderState(D3DRS_ZVISIBLE, FALSE) returned %#08x\n", hr); cleanup: - if (pDevice) - { - UINT refcount = IDirect3DDevice8_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IDirect3D8_Release(pD3d); + if(pD3d) IDirect3D8_Release(pD3d); + if(pDevice) IDirect3D8_Release(pDevice); } static void test_shader_versions(void) @@ -867,12 +851,8 @@ static void test_scene(void) /* StretchRect does not exit in Direct3D8, so no equivalent to the d3d9 stretchrect tests */ cleanup: - if (pDevice) - { - UINT refcount = IDirect3DDevice8_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IDirect3D8_Release(pD3d); + if(pD3d) IDirect3D8_Release(pD3d); + if(pDevice) IDirect3D8_Release(pDevice); if(hwnd) DestroyWindow(hwnd); } @@ -1116,12 +1096,8 @@ static void test_shader(void) ok(hr == D3DERR_INVALIDCALL, "IDirect3DDevice8_DeleteVertexShader returned %#08x\n", hr); cleanup: - if (pDevice) - { - UINT refcount = IDirect3DDevice8_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IDirect3D8_Release(pD3d); + if(pD3d) IDirect3D8_Release(pD3d); + if(pDevice) IDirect3D8_Release(pDevice); if(hwnd) DestroyWindow(hwnd); } @@ -1182,12 +1158,8 @@ static void test_limits(void) cleanup: if(pTexture) IDirect3DTexture8_Release(pTexture); - if (pDevice) - { - UINT refcount = IDirect3DDevice8_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IDirect3D8_Release(pD3d); + if(pD3d) IDirect3D8_Release(pD3d); + if(pDevice) IDirect3D8_Release(pDevice); if(hwnd) DestroyWindow(hwnd); } @@ -1258,13 +1230,9 @@ static void test_lights(void) ok(hr == D3D_OK, "Disabling light %u failed with %08x\n", i, hr); } -cleanup: - if (device) - { - UINT refcount = IDirect3DDevice8_Release(device); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (d3d8) IDirect3D8_Release(d3d8); + cleanup: + if(device) IDirect3DDevice8_Release(device); + if(d3d8) IDirect3D8_Release(d3d8); } static void test_render_zero_triangles(void) @@ -1332,13 +1300,9 @@ static void test_render_zero_triangles(void) IDirect3DDevice8_Present(device, NULL, NULL, NULL, NULL); -cleanup: - if (device) - { - UINT refcount = IDirect3DDevice8_Release(device); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (d3d8) IDirect3D8_Release(d3d8); + cleanup: + if(device) IDirect3DDevice8_Release(device); + if(d3d8) IDirect3D8_Release(d3d8); } static void test_depth_stencil_reset(void) @@ -1446,12 +1410,8 @@ static void test_depth_stencil_reset(void) if (surface) IDirect3DSurface8_Release(surface); cleanup: - if (device) - { - UINT refcount = IDirect3DDevice8_Release(device); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (d3d8) IDirect3D8_Release(d3d8); + if(d3d8) IDirect3D8_Release(d3d8); + if(device) IDirect3D8_Release(device); } START_TEST(device) diff --git a/dlls/d3d8/tests/visual.c b/dlls/d3d8/tests/visual.c index 07b8810aa93..1850b838db3 100644 --- a/dlls/d3d8/tests/visual.c +++ b/dlls/d3d8/tests/visual.c @@ -1348,8 +1348,8 @@ cleanup: ULONG refcount; IDirect3DDevice8_GetCreationParameters(device_ptr, &creation_parameters); - DestroyWindow(creation_parameters.hFocusWindow); refcount = IDirect3DDevice8_Release(device_ptr); ok(!refcount, "Device has %u references left\n", refcount); + DestroyWindow(creation_parameters.hFocusWindow); } } diff --git a/dlls/d3d9/device.c b/dlls/d3d9/device.c index 14885de55cb..9d1c72e36f0 100644 --- a/dlls/d3d9/device.c +++ b/dlls/d3d9/device.c @@ -424,7 +424,7 @@ static BOOL WINAPI IDirect3DDevice9Impl_ShowCursor(LPDIRECT3DDEVICE9EX ifac static HRESULT WINAPI reset_enum_callback(IWineD3DResource *resource, void *data) { BOOL *resources_ok = data; - D3DRESOURCETYPE type; + WINED3DRESOURCETYPE type; HRESULT ret = S_OK; WINED3DSURFACE_DESC surface_desc; WINED3DVOLUME_DESC volume_desc; diff --git a/dlls/d3d9/directx.c b/dlls/d3d9/directx.c index bee2e4f6510..e9547a764e4 100644 --- a/dlls/d3d9/directx.c +++ b/dlls/d3d9/directx.c @@ -106,25 +106,23 @@ static HRESULT WINAPI IDirect3D9Impl_GetAdapterIdentifier(LPDIRECT3D9EX iface, U WINED3DADAPTER_IDENTIFIER adapter_id; HRESULT hr; - adapter_id.driver = pIdentifier->Driver; - adapter_id.driver_size = sizeof(pIdentifier->Driver); - adapter_id.description = pIdentifier->Description; - adapter_id.description_size = sizeof(pIdentifier->Description); - adapter_id.device_name = pIdentifier->DeviceName; - adapter_id.device_name_size = sizeof(pIdentifier->DeviceName); + /* dx8 and dx9 have different structures to be filled in, with incompatible + layouts so pass in pointers to the places to be filled via an internal + structure */ + adapter_id.Driver = pIdentifier->Driver; + adapter_id.Description = pIdentifier->Description; + adapter_id.DeviceName = pIdentifier->DeviceName; + adapter_id.DriverVersion = &pIdentifier->DriverVersion; + adapter_id.VendorId = &pIdentifier->VendorId; + adapter_id.DeviceId = &pIdentifier->DeviceId; + adapter_id.SubSysId = &pIdentifier->SubSysId; + adapter_id.Revision = &pIdentifier->Revision; + adapter_id.DeviceIdentifier = &pIdentifier->DeviceIdentifier; + adapter_id.WHQLLevel = &pIdentifier->WHQLLevel; EnterCriticalSection(&d3d9_cs); hr = IWineD3D_GetAdapterIdentifier(This->WineD3D, Adapter, Flags, &adapter_id); LeaveCriticalSection(&d3d9_cs); - - pIdentifier->DriverVersion = adapter_id.driver_version; - pIdentifier->VendorId = adapter_id.vendor_id; - pIdentifier->DeviceId = adapter_id.device_id; - pIdentifier->SubSysId = adapter_id.subsystem_id; - pIdentifier->Revision = adapter_id.revision; - memcpy(&pIdentifier->DeviceIdentifier, &adapter_id.device_identifier, sizeof(pIdentifier->DeviceIdentifier)); - pIdentifier->WHQLLevel = adapter_id.whql_level; - return hr; } diff --git a/dlls/d3d9/tests/device.c b/dlls/d3d9/tests/device.c index f56e05e7139..5610a711286 100644 --- a/dlls/d3d9/tests/device.c +++ b/dlls/d3d9/tests/device.c @@ -130,13 +130,9 @@ static void test_mipmap_levels(void) check_mipmap_levels(pDevice, 1, 256, 9); check_mipmap_levels(pDevice, 1, 1, 1); -cleanup: - if (pDevice) - { - UINT refcount = IUnknown_Release( pDevice ); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IUnknown_Release( pD3d ); + cleanup: + if (pD3d) IUnknown_Release( pD3d ); + if (pDevice) IUnknown_Release( pDevice ); DestroyWindow( hwnd ); } @@ -190,12 +186,8 @@ static void test_checkdevicemultisampletype(void) ok(qualityLevels == 1,"qualitylevel is not 1 but %d\n",qualityLevels); cleanup: - if (pDevice) - { - UINT refcount = IUnknown_Release( pDevice ); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IUnknown_Release( pD3d ); + if (pD3d) IUnknown_Release( pD3d ); + if (pDevice) IUnknown_Release( pDevice ); DestroyWindow( hwnd ); } @@ -334,16 +326,12 @@ static void test_swapchain(void) ok(swapchainX == NULL, "The swapchain pointer is %p\n", swapchainX); if(swapchainX && swapchainX != (void *) 0xdeadbeef ) IDirect3DSwapChain9_Release(swapchainX); -cleanup: + cleanup: if(swapchain1) IDirect3DSwapChain9_Release(swapchain1); if(swapchain2) IDirect3DSwapChain9_Release(swapchain2); if(swapchain3) IDirect3DSwapChain9_Release(swapchain3); - if (pDevice) - { - UINT refcount = IDirect3DDevice9_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IDirect3D9_Release(pD3d); + if(pDevice) IDirect3DDevice9_Release(pDevice); + if(pD3d) IDirect3DDevice9_Release(pD3d); DestroyWindow( hwnd ); } @@ -772,12 +760,8 @@ static void test_cursor(void) ok(info.hCursor == cur, "The cursor handle is %p\n", info.hCursor); /* unchanged */ cleanup: - if (pDevice) - { - UINT refcount = IDirect3DDevice9_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IDirect3D9_Release(pD3d); + if(pDevice) IDirect3D9_Release(pDevice); + if(pD3d) IDirect3D9_Release(pD3d); DestroyWindow( hwnd ); } @@ -1161,12 +1145,8 @@ static void test_reset(void) cleanup: HeapFree(GetProcessHeap(), 0, modes); - if (pDevice) - { - UINT refcount = IDirect3DDevice9_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IDirect3D9_Release(pD3d); + if(pD3d) IDirect3D9_Release(pD3d); + if(pDevice) IDirect3D9_Release(pDevice); } /* Test adapter display modes */ @@ -1409,12 +1389,8 @@ cleanup: if(pSurface1) IDirect3DSurface9_Release(pSurface1); if(pSurface2) IDirect3DSurface9_Release(pSurface2); if(pSurface3) IDirect3DSurface9_Release(pSurface3); - if (pDevice) - { - UINT refcount = IDirect3DDevice9_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IDirect3D9_Release(pD3d); + if(pD3d) IDirect3D9_Release(pD3d); + if(pDevice) IDirect3D9_Release(pDevice); if(hwnd) DestroyWindow(hwnd); } @@ -1480,12 +1456,8 @@ static void test_limits(void) */ cleanup: if(pTexture) IDirect3DTexture9_Release(pTexture); - if (pDevice) - { - UINT refcount = IDirect3D9_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IDirect3D9_Release(pD3d); + if(pD3d) IDirect3D9_Release(pD3d); + if(pDevice) IDirect3D9_Release(pDevice); if(hwnd) DestroyWindow(hwnd); } @@ -1643,12 +1615,8 @@ static void test_depthstenciltest(void) cleanup: if(pDepthStencil) IDirect3DSurface9_Release(pDepthStencil); - if (pDevice) - { - UINT refcount = IDirect3D9_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (pD3d) IDirect3D9_Release(pD3d); + if(pD3d) IDirect3D9_Release(pD3d); + if(pDevice) IDirect3D9_Release(pDevice); if(hwnd) DestroyWindow(hwnd); } @@ -1771,12 +1739,8 @@ static void test_draw_indexed(void) IDirect3DVertexDeclaration9_Release(vertex_declaration); cleanup: - if (device) - { - UINT refcount = IDirect3DDevice9_Release(device); - ok(!refcount, "Device has %u references left.\n", refcount); - } if (d3d9) IDirect3D9_Release(d3d9); + if (device) IDirect3DDevice9_Release(device); if (hwnd) DestroyWindow(hwnd); } @@ -1864,14 +1828,9 @@ static void test_null_stream(void) IDirect3DDevice9_SetVertexDeclaration(device, NULL); cleanup: - if (buffer) IDirect3DVertexBuffer9_Release(buffer); if(decl) IDirect3DVertexDeclaration9_Release(decl); if(shader) IDirect3DVertexShader9_Release(shader); - if (device) - { - UINT refcount = IDirect3DDevice9_Release(device); - ok(!refcount, "Device has %u references left.\n", refcount); - } + if(device) IDirect3DDevice9_Release(device); if(d3d9) IDirect3D9_Release(d3d9); } @@ -1941,13 +1900,8 @@ static void test_vertex_buffer_alignment(void) } } -cleanup: - if (device) - { - UINT refcount = IDirect3DDevice9_Release(device); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (d3d9) IDirect3D9_Release(d3d9); + cleanup: + if(d3d9) IDirect3D9_Release(d3d9); } static void test_lights(void) @@ -2008,12 +1962,8 @@ static void test_lights(void) ok(hr == D3D_OK, "Disabling light %u failed with %08x\n", i, hr); } -cleanup: - if (device) - { - UINT refcount = IDirect3DDevice9_Release(device); - ok(!refcount, "Device has %u references left.\n", refcount); - } + cleanup: + if(device) IDirect3DDevice9_Release(device); if(d3d9) IDirect3D9_Release(d3d9); } @@ -2086,13 +2036,9 @@ static void test_set_stream_source(void) hr = IDirect3DDevice9_SetStreamSource(device, 0, NULL, 0, 0); ok(hr == D3D_OK, "Failed to set the stream source, offset 4, hr = %08x\n", hr); + if(pVertexBuffer) IDirect3DDevice9_Release(pVertexBuffer); cleanup: - if (pVertexBuffer) IDirect3DVertexBuffer9_Release(pVertexBuffer); - if (device) - { - UINT refcount = IDirect3DDevice9_Release(device); - ok(!refcount, "Device has %u references left.\n", refcount); - } + if(device) IDirect3DDevice9_Release(device); if(d3d9) IDirect3D9_Release(d3d9); } @@ -2312,72 +2258,6 @@ err_out: return; } -static void test_multi_device(void) -{ - IDirect3DDevice9 *device1 = NULL, *device2 = NULL; - D3DPRESENT_PARAMETERS present_parameters; - HWND hwnd1 = NULL, hwnd2 = NULL; - IDirect3D9 *d3d9; - ULONG refcount; - HRESULT hr; - - d3d9 = pDirect3DCreate9(D3D_SDK_VERSION); - ok(d3d9 != NULL, "Failed to create a d3d9 object.\n"); - if (!d3d9) goto fail; - - hwnd1 = CreateWindow("static", "d3d9_test", WS_OVERLAPPEDWINDOW, 100, 100, 160, 160, NULL, NULL, NULL, NULL); - ok(hwnd1 != NULL, "Failed to create a window.\n"); - if (!hwnd1) goto fail; - - memset(&present_parameters, 0, sizeof(present_parameters)); - present_parameters.Windowed = TRUE; - present_parameters.hDeviceWindow = hwnd1; - present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; - - hr = IDirect3D9_CreateDevice(d3d9, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, hwnd1, - D3DCREATE_SOFTWARE_VERTEXPROCESSING, &present_parameters, &device1); - IDirect3D9_Release(d3d9); - d3d9 = NULL; - if (FAILED(hr)) { - skip("Failed to create a device\n"); - goto fail; - } - - d3d9 = pDirect3DCreate9(D3D_SDK_VERSION); - ok(d3d9 != NULL, "Failed to create a d3d9 object.\n"); - if (!d3d9) goto fail; - - hwnd2 = CreateWindow("static", "d3d9_test", WS_OVERLAPPEDWINDOW, 100, 100, 160, 160, NULL, NULL, NULL, NULL); - ok(hwnd2 != NULL, "Failed to create a window.\n"); - if (!hwnd2) goto fail; - - memset(&present_parameters, 0, sizeof(present_parameters)); - present_parameters.Windowed = TRUE; - present_parameters.hDeviceWindow = hwnd2; - present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; - - hr = IDirect3D9_CreateDevice(d3d9, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, hwnd2, - D3DCREATE_SOFTWARE_VERTEXPROCESSING, &present_parameters, &device2); - ok(SUCCEEDED(hr), "Failed to create a device, hr %#x\n", hr); - IDirect3D9_Release(d3d9); - d3d9 = NULL; - if (FAILED(hr)) goto fail; - -fail: - if (d3d9) IDirect3D9_Release(d3d9); - if (device1) - { - refcount = IDirect3DDevice9_Release(device1); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (device2) - { - refcount = IDirect3DDevice9_Release(device2); - ok(!refcount, "Device has %u references left.\n", refcount); - } - if (hwnd1) DestroyWindow(hwnd1); - if (hwnd2) DestroyWindow(hwnd2); -} START_TEST(device) { @@ -2400,7 +2280,6 @@ START_TEST(device) } IDirect3D9_Release(d3d9); - test_multi_device(); test_display_formats(); test_display_modes(); test_swapchain(); diff --git a/dlls/d3d9/tests/query.c b/dlls/d3d9/tests/query.c index d01535319c7..51a86686395 100644 --- a/dlls/d3d9/tests/query.c +++ b/dlls/d3d9/tests/query.c @@ -105,7 +105,7 @@ static void test_query_support(IDirect3D9 *pD3d, HWND hwnd) for(i = 0; i < sizeof(queries) / sizeof(queries[0]); i++) { hr = IDirect3DDevice9_CreateQuery(pDevice, queries[i].type, NULL); - ok(hr == D3D_OK || hr == D3DERR_NOTAVAILABLE, + ok(hr == D3D_OK || D3DERR_NOTAVAILABLE, "IDirect3DDevice9_CreateQuery returned unexpected return value %08x for query %s\n", hr, queryName(queries[i].type)); supported = (hr == D3D_OK ? TRUE : FALSE); @@ -119,7 +119,7 @@ static void test_query_support(IDirect3D9 *pD3d, HWND hwnd) queryName(queries[i].type)); hr = IDirect3DDevice9_CreateQuery(pDevice, queries[i].type, &pQuery); - ok(hr == D3D_OK || hr == D3DERR_NOTAVAILABLE, + ok(hr == D3D_OK || D3DERR_NOTAVAILABLE, "IDirect3DDevice9_CreateQuery returned unexpected return value %08x for query %s\n", hr, queryName(queries[i].type)); ok(!(supported && !pQuery), "Query %s was claimed to be supported, but can't be created\n", queryName(queries[i].type)); ok(!(!supported && pQuery), "Query %s was claimed not to be supported, but can be created\n", queryName(queries[i].type)); @@ -130,12 +130,8 @@ static void test_query_support(IDirect3D9 *pD3d, HWND hwnd) } } -cleanup: - if (pDevice) - { - UINT refcount = IDirect3DDevice9_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } + cleanup: + if(pDevice) IDirect3DDevice9_Release(pDevice); } static void test_occlusion_query_states(IDirect3D9 *pD3d, HWND hwnd) @@ -167,7 +163,7 @@ static void test_occlusion_query_states(IDirect3D9 *pD3d, HWND hwnd) } hr = IDirect3DDevice9_CreateQuery(pDevice, D3DQUERYTYPE_OCCLUSION, &pQuery); - ok(hr == D3D_OK || hr == D3DERR_NOTAVAILABLE, + ok(hr == D3D_OK || D3DERR_NOTAVAILABLE, "IDirect3DDevice9_CreateQuery returned unexpected return value %08x\n", hr); if(!pQuery) { skip("Occlusion queries not supported\n"); @@ -230,14 +226,9 @@ static void test_occlusion_query_states(IDirect3D9 *pD3d, HWND hwnd) hr = IDirect3DQuery9_Issue(pQuery, D3DISSUE_END); ok(hr == D3D_OK, "IDirect3DQuery9_Issue(D3DISSUE_END) on a ended query returned %08x\n", hr); -cleanup: + cleanup: HeapFree(GetProcessHeap(), 0, data); - if (pQuery) IDirect3DQuery9_Release(pQuery); - if (pDevice) - { - UINT refcount = IDirect3DDevice9_Release(pDevice); - ok(!refcount, "Device has %u references left.\n", refcount); - } + if(pDevice) IDirect3DDevice9_Release(pDevice); } START_TEST(query) diff --git a/dlls/d3d9/tests/visual.c b/dlls/d3d9/tests/visual.c index 2a86be8aadb..44ae50e2a7c 100644 --- a/dlls/d3d9/tests/visual.c +++ b/dlls/d3d9/tests/visual.c @@ -3004,7 +3004,7 @@ static void g16r16_texture_test(IDirect3DDevice9 *device) IDirect3DTexture9 *texture = NULL; D3DLOCKED_RECT lr; DWORD *data; - DWORD color; + DWORD color, red, green, blue; float quad[] = { -1.0, -1.0, 0.1, 0.0, 0.0, -1.0, 1.0, 0.1, 0.0, 1.0, @@ -3058,8 +3058,11 @@ static void g16r16_texture_test(IDirect3DDevice9 *device) ok(hr == D3D_OK, "IDirect3DDevice9_Present failed with %08x\n", hr); color = getPixelColor(device, 240, 320); - ok(color_match(color, D3DCOLOR_ARGB(0x00, 0xf0, 0x0f, 0xff), 1), - "D3DFMT_G16R16 with value 0x00ffff00 has color %08x, expected 0x00f00fff\n", color); + red = (color & 0x00ff0000) >> 16; + green = (color & 0x0000ff00) >> 8; + blue = (color & 0x000000ff) >> 0; + ok(blue == 0xff && red >= 0xef && red <= 0xf1 && green >= 0x0e && green <= 0x10, + "D3DFMT_G16R16 with value 0x00ffff00 has color %08x, expected 0x00F00FFF\n", color); out: if(texture) IDirect3DTexture9_Release(texture); @@ -3262,13 +3265,13 @@ static void texture_transform_flags_test(IDirect3DDevice9 *device) hr = IDirect3DDevice9_Present(device, NULL, NULL, NULL, NULL); ok(hr == D3D_OK, "IDirect3DDevice9_Present failed with %08x\n", hr); color = getPixelColor(device, 160, 360); - ok(color_match(color, 0x00FFFF00, 1), "quad 1 has color %08x, expected 0x00FFFF00\n", color); + ok(color == 0x00FFFF00 || color == 0x00FEFE00, "quad 1 has color %08x, expected 0x00FFFF00\n", color); color = getPixelColor(device, 160, 120); ok(color == 0x00000000, "quad 2 has color %08x, expected 0x0000000\n", color); color = getPixelColor(device, 480, 120); - ok(color_match(color, 0x0000FF00, 1), "quad 3 has color %08x, expected 0x0000FF00\n", color); + ok(color == 0x0000FF00 || color == 0x0000FE00, "quad 3 has color %08x, expected 0x0000FF00\n", color); color = getPixelColor(device, 480, 360); - ok(color_match(color, 0x00FF0000, 1), "quad 4 has color %08x, expected 0x00FF0000\n", color); + ok(color == 0x00FF0000 || 0x00FE0000, "quad 4 has color %08x, expected 0x00FF0000\n", color); hr = IDirect3DDevice9_Clear(device, 0, NULL, D3DCLEAR_TARGET, 0xff0000ff, 0.0, 0); ok(hr == D3D_OK, "IDirect3DDevice9_Clear returned %08x\n", hr); @@ -3349,14 +3352,14 @@ static void texture_transform_flags_test(IDirect3DDevice9 *device) hr = IDirect3DDevice9_Present(device, NULL, NULL, NULL, NULL); ok(hr == D3D_OK, "IDirect3DDevice9_Present failed with %08x\n", hr); color = getPixelColor(device, 160, 360); - ok(color_match(color, 0x00FF0000, 1), "quad 1 has color %08x, expected 0x00FF0000\n", color); + ok(color == 0x00FF0000 || color == 0x00FE0000, "quad 1 has color %08x, expected 0x00FF0000\n", color); color = getPixelColor(device, 160, 120); ok(color == 0x00000000, "quad 2 has color %08x, expected 0x0000000\n", color); color = getPixelColor(device, 480, 120); - ok(color_match(color, 0x00ff8000, 1) || color == 0x00000000, + ok(color == 0x00ff8000 || color == 0x00fe7f00 || color == 0x00000000, "quad 3 has color %08x, expected 0x00ff8000\n", color); color = getPixelColor(device, 480, 360); - ok(color_match(color, 0x0033cc00, 1) || color_match(color, 0x00FF0000, 1), + ok(color == 0x0033cc00 || color == 0x0032cb00 || color == 0x00FF0000 || color == 0x00FE0000, "quad 4 has color %08x, expected 0x0033cc00\n", color); IDirect3DTexture9_Release(texture); @@ -4160,7 +4163,7 @@ static void x8l8v8u8_test(IDirect3DDevice9 *device) hr = IDirect3DDevice9_Present(device, NULL, NULL, NULL, NULL); ok(hr == D3D_OK, "IDirect3DDevice9_Present failed with %08x\n", hr); color = getPixelColor(device, 578, 430); - ok(color_match(color, D3DCOLOR_ARGB(0x00, 0x82, 0x62, 0xca), 1), + ok(color == 0x008262ca || color == 0x008363ca || color == 0x008362ca, "D3DFMT_X8L8V8U8 = 0x112131ca returns color %08x, expected 0x008262ca\n", color); hr = IDirect3DDevice9_SetPixelShader(device, shader2); @@ -4432,19 +4435,19 @@ static void test_constant_clamp_vs(IDirect3DDevice9 *device) ok(hr == D3D_OK, "IDirect3DDevice9_SetVertexDeclaration returned %08x\n", hr); color = getPixelColor(device, 160, 360); - ok(color_match(color, D3DCOLOR_ARGB(0x00, 0xbf, 0xbf, 0x80), 1), + ok(color == 0x00bfbf80 || color == 0x00bfbf7f || color == 0x00bfbf81, "quad 1 has color %08x, expected 0x00bfbf80\n", color); color = getPixelColor(device, 480, 360); - ok(color_match(color, D3DCOLOR_ARGB(0x00, 0xbf, 0xbf, 0x80), 1), + ok(color == 0x00bfbf80 || color == 0x00bfbf7f || color == 0x00bfbf81, "quad 2 has color %08x, expected 0x00bfbf80\n", color); if(shader_20) { color = getPixelColor(device, 160, 120); - ok(color_match(color, D3DCOLOR_ARGB(0x00, 0xbf, 0xbf, 0x80), 1), + ok(color == 0x00bfbf80 || color == 0x00bfbf7f || color == 0x00bfbf81, "quad 3 has color %08x, expected 0x00bfbf80\n", color); } if(shader_20_2) { color = getPixelColor(device, 480, 120); - ok(color_match(color, D3DCOLOR_ARGB(0x00, 0xbf, 0xbf, 0x80), 1), + ok(color == 0x00bfbf80 || color == 0x00bfbf7f || color == 0x00bfbf81, "quad 4 has color %08x, expected 0x00bfbf80\n", color); } @@ -4575,17 +4578,17 @@ static void constant_clamp_ps_test(IDirect3DDevice9 *device) ok(hr == D3D_OK, "IDirect3DDevice9_SetVertexShader returned %08x\n", hr); color = getPixelColor(device, 160, 360); - ok(color_match(color, D3DCOLOR_ARGB(0x00, 0x80, 0x80, 0x00), 1), + ok(color == 0x00808000 || color == 0x007f7f00 || color == 0x00818100, "quad 1 has color %08x, expected 0x00808000\n", color); color = getPixelColor(device, 480, 360); - ok(color_match(color, D3DCOLOR_ARGB(0x00, 0x80, 0x80, 0x00), 1), + ok(color == 0x00808000 || color == 0x007f7f00 || color == 0x00818100, "quad 2 has color %08x, expected 0x00808000\n", color); color = getPixelColor(device, 480, 120); - ok(color_match(color, D3DCOLOR_ARGB(0x00, 0x80, 0x80, 0x00), 1), + ok(color == 0x00808000 || color == 0x007f7f00 || color == 0x00818100, "quad 3 has color %08x, expected 0x00808000\n", color); if(shader_20) { color = getPixelColor(device, 160, 120); - ok(color_match(color, D3DCOLOR_ARGB(0x00, 0xbf, 0xbf, 0x80), 1), + ok(color == 0x00bfbf80 || color == 0x00bfbf7f || color == 0x00bfbf81, "quad 4 has color %08x, expected 0x00bfbf80\n", color); } @@ -4677,8 +4680,7 @@ static void dp2add_ps_test(IDirect3DDevice9 *device) ok(hr == D3D_OK, "IDirect3DDevice9_Present failed with %08x\n", hr); color = getPixelColor(device, 360, 240); - ok(color_match(color, D3DCOLOR_ARGB(0x00, 0x7f, 0x7f, 0x7f), 1), - "dp2add pixel has color %08x, expected ~0x007f7f7f\n", color); + ok(color == 0x007f7f7f || color == 0x00808080, "dp2add pixel has color %08x, expected ~0x007f7f7f\n", color); IDirect3DPixelShader9_Release(shader_dp2add); } else { @@ -4704,8 +4706,7 @@ static void dp2add_ps_test(IDirect3DDevice9 *device) ok(hr == D3D_OK, "IDirect3DDevice9_Present failed with %08x\n", hr); color = getPixelColor(device, 360, 240); - ok(color_match(color, D3DCOLOR_ARGB(0x00, 0x7f, 0x7f, 0x7f), 1), - "dp2add pixel has color %08x, expected ~0x007f7f7f\n", color); + ok(color == 0x007f7f7f || color == 0x00808080, "dp2add pixel has color %08x, expected ~0x007f7f7f\n", color); IDirect3DPixelShader9_Release(shader_dp2add_sat); } else { @@ -10193,141 +10194,6 @@ static void sincos_test(IDirect3DDevice9 *device) { IDirect3DVertexShader9_Release(cos_shader); } -static void loop_index_test(IDirect3DDevice9 *device) { - const DWORD shader_code[] = { - 0xfffe0200, /* vs_2_0 */ - 0x0200001f, 0x80000000, 0x900f0000, /* dcl_position v0 */ - 0x02000001, 0x800f0000, 0xa0e40000, /* mov r0, c0 */ - 0x0200001b, 0xf0e40800, 0xf0e40000, /* loop aL, i0 */ - 0x04000002, 0x800f0000, 0x80e40000, 0xa0e42001, 0xf0e40800, /* add r0, r0, c[aL + 1] */ - 0x0000001d, /* endloop */ - 0x02000001, 0xc00f0000, 0x90e40000, /* mov oPos, v0 */ - 0x02000001, 0xd00f0000, 0x80e40000, /* mov oD0, r0 */ - 0x0000ffff /* END */ - }; - IDirect3DVertexShader9 *shader; - HRESULT hr; - DWORD color; - const float quad[] = { - -1.0, -1.0, 0.1, - 1.0, -1.0, 0.1, - -1.0, 1.0, 0.1, - 1.0, 1.0, 0.1 - }; - const float zero[4] = {0, 0, 0, 0}; - const float one[4] = {1, 1, 1, 1}; - int i0[4] = {2, 10, -3, 0}; - float values[4]; - - hr = IDirect3DDevice9_CreateVertexShader(device, shader_code, &shader); - ok(hr == D3D_OK, "IDirect3DDevice9_CreateVertexShader failed with %08x\n", hr); - hr = IDirect3DDevice9_SetVertexShader(device, shader); - ok(hr == D3D_OK, "IDirect3DDevice9_SetVertexShader failed with %08x\n", hr); - hr = IDirect3DDevice9_SetFVF(device, D3DFVF_XYZ); - ok(hr == D3D_OK, "IDirect3DDevice9_SetFVF failed with %08x\n", hr); - hr = IDirect3DDevice9_Clear(device, 0, NULL, D3DCLEAR_TARGET, 0x00ff0000, 0.0, 0); - ok(hr == D3D_OK, "IDirect3DDevice9_Clear returned %08x\n", hr); - - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 0, zero, 1); - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 1, one, 1); - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 2, one, 1); - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 3, one, 1); - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 4, one, 1); - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 5, one, 1); - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 6, one, 1); - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 7, one, 1); - values[0] = 1.0; - values[1] = 1.0; - values[2] = 0.0; - values[3] = 0.0; - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 8, values, 1); - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 9, one, 1); - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 10, one, 1); - values[0] = -1.0; - values[1] = 0.0; - values[2] = 0.0; - values[3] = 0.0; - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 11, values, 1); - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 12, one, 1); - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 13, one, 1); - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 14, one, 1); - hr = IDirect3DDevice9_SetVertexShaderConstantF(device, 15, one, 1); - - hr = IDirect3DDevice9_SetVertexShaderConstantI(device, 0, i0, 1); - - hr = IDirect3DDevice9_BeginScene(device); - ok(hr == D3D_OK, "IDirect3DDevice9_BeginScene returned %08x\n", hr); - if(SUCCEEDED(hr)) - { - trace("going to draw index\n"); - hr = IDirect3DDevice9_DrawPrimitiveUP(device, D3DPT_TRIANGLESTRIP, 2, quad, 3 * sizeof(float)); - ok(hr == D3D_OK, "DrawPrimitiveUP failed (%08x)\n", hr); - hr = IDirect3DDevice9_EndScene(device); - ok(hr == D3D_OK, "IDirect3DDevice9_EndScene returned %08x\n", hr); - } - hr = IDirect3DDevice9_Present(device, NULL, NULL, NULL, NULL); - ok(hr == D3D_OK, "IDirect3DDevice9_Present failed with %08x\n", hr); - - color = getPixelColor(device, 320, 240); - ok(color_match(color, 0x0000ff00, 1), - "aL indexing test returned color 0x%08x, expected 0x0000ff00\n", color); - - hr = IDirect3DDevice9_SetVertexShader(device, NULL); - ok(hr == D3D_OK, "IDirect3DDevice9_SetVertexShader failed with %08x\n", hr); - IDirect3DVertexShader9_Release(shader); -} - -static void sgn_test(IDirect3DDevice9 *device) { - const DWORD shader_code[] = { - 0xfffe0200, /* vs_2_0 */ - 0x0200001f, 0x80000000, 0x900f0000, /* dcl_position o0 */ - 0x05000051, 0xa00f0000, 0xbf000000, 0x00000000, 0x3f000000, 0x41400000, /* def c0, -0.5, 0.0, 0.5, 12.0 */ - 0x05000051, 0xa00f0001, 0x3fc00000, 0x00000000, 0x00000000, 0x00000000, /* def c1, 1.5, 0.0, 0.0, 0.0 */ - 0x02000001, 0xc00f0000, 0x90e40000, /* mov oPos, v0 */ - 0x02000022, 0x800f0000, 0xa0e40000, /* sgn r0, c0 */ - 0x03000002, 0xd00f0000, 0x80e40000, 0xa0e40001, /* add oD0, r0, c1 */ - 0x0000ffff /* end */ - }; - IDirect3DVertexShader9 *shader; - HRESULT hr; - DWORD color; - const float quad[] = { - -1.0, -1.0, 0.1, - 1.0, -1.0, 0.1, - -1.0, 1.0, 0.1, - 1.0, 1.0, 0.1 - }; - - hr = IDirect3DDevice9_CreateVertexShader(device, shader_code, &shader); - ok(hr == D3D_OK, "IDirect3DDevice9_CreateVertexShader failed with %08x\n", hr); - hr = IDirect3DDevice9_SetVertexShader(device, shader); - ok(hr == D3D_OK, "IDirect3DDevice9_SetVertexShader failed with %08x\n", hr); - hr = IDirect3DDevice9_SetFVF(device, D3DFVF_XYZ); - ok(hr == D3D_OK, "IDirect3DDevice9_SetFVF failed with %08x\n", hr); - hr = IDirect3DDevice9_Clear(device, 0, NULL, D3DCLEAR_TARGET, 0x00ff0000, 0.0, 0); - ok(hr == D3D_OK, "IDirect3DDevice9_Clear returned %08x\n", hr); - - hr = IDirect3DDevice9_BeginScene(device); - ok(hr == D3D_OK, "IDirect3DDevice9_BeginScene returned %08x\n", hr); - if(SUCCEEDED(hr)) - { - hr = IDirect3DDevice9_DrawPrimitiveUP(device, D3DPT_TRIANGLESTRIP, 2, quad, 3 * sizeof(float)); - ok(hr == D3D_OK, "DrawPrimitiveUP failed (%08x)\n", hr); - hr = IDirect3DDevice9_EndScene(device); - ok(hr == D3D_OK, "IDirect3DDevice9_EndScene returned %08x\n", hr); - } - hr = IDirect3DDevice9_Present(device, NULL, NULL, NULL, NULL); - ok(hr == D3D_OK, "IDirect3DDevice9_Present failed with %08x\n", hr); - - color = getPixelColor(device, 320, 240); - ok(color_match(color, 0x008000ff, 1), - "sgn test returned color 0x%08x, expected 0x008000ff\n", color); - - hr = IDirect3DDevice9_SetVertexShader(device, NULL); - ok(hr == D3D_OK, "IDirect3DDevice9_SetVertexShader failed with %08x\n", hr); - IDirect3DVertexShader9_Release(shader); -} - START_TEST(visual) { IDirect3DDevice9 *device_ptr; @@ -10437,9 +10303,7 @@ START_TEST(visual) if (caps.VertexShaderVersion >= D3DVS_VERSION(2, 0)) { test_mova(device_ptr); - loop_index_test(device_ptr); sincos_test(device_ptr); - sgn_test(device_ptr); if (caps.VertexShaderVersion >= D3DVS_VERSION(3, 0)) { test_vshader_input(device_ptr); test_vshader_float16(device_ptr); @@ -10497,15 +10361,15 @@ START_TEST(visual) cleanup: if(device_ptr) { - D3DPRESENT_PARAMETERS present_parameters; - IDirect3DSwapChain9 *swapchain; ULONG ref; + D3DPRESENT_PARAMETERS present_parameters; + IDirect3DSwapChain9 *swapchain; IDirect3DDevice9_GetSwapChain(device_ptr, 0, &swapchain); IDirect3DSwapChain9_GetPresentParameters(swapchain, &present_parameters); - DestroyWindow(present_parameters.hDeviceWindow); IDirect3DSwapChain9_Release(swapchain); ref = IDirect3DDevice9_Release(device_ptr); + DestroyWindow(present_parameters.hDeviceWindow); ok(ref == 0, "The device was not properly freed: refcount %u\n", ref); } } diff --git a/dlls/d3dx8/Makefile.in b/dlls/d3dx8/Makefile.in new file mode 100644 index 00000000000..a6edd23f9cb --- /dev/null +++ b/dlls/d3dx8/Makefile.in @@ -0,0 +1,17 @@ +TOPSRCDIR = @top_srcdir@ +TOPOBJDIR = ../.. +SRCDIR = @srcdir@ +VPATH = @srcdir@ +MODULE = d3dx8.dll +IMPORTLIB = d3dx8 +IMPORTS = dxguid uuid kernel32 + +C_SRCS = \ + core.c \ + d3dx8_main.c \ + math.c \ + mesh.c + +@MAKE_DLL_RULES@ + +@DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/d3dx8/core.c b/dlls/d3dx8/core.c new file mode 100644 index 00000000000..da821fc9d35 --- /dev/null +++ b/dlls/d3dx8/core.c @@ -0,0 +1,148 @@ +/* + * + * Copyright 2002 Raphael Junqueira + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include + +#define COBJMACROS +#include "windef.h" +#include "winbase.h" +#include "wingdi.h" +#include "wine/debug.h" +#include "wine/unicode.h" + +#include "d3dx8_private.h" + +WINE_DEFAULT_DEBUG_CHANNEL(d3dx); + +/* ID3DXBuffer IUnknown parts follow: */ +static HRESULT WINAPI ID3DXBufferImpl_QueryInterface(LPD3DXBUFFER iface, REFIID riid, LPVOID* ppobj) { + ID3DXBufferImpl *This = (ID3DXBufferImpl *)iface; + + if (IsEqualGUID(riid, &IID_IUnknown) + || IsEqualGUID(riid, &IID_ID3DXBuffer)) { + IUnknown_AddRef(iface); + *ppobj = This; + return D3D_OK; + } + + WARN("(%p)->(%s,%p),not found\n",This,debugstr_guid(riid),ppobj); + return E_NOINTERFACE; +} + +static ULONG WINAPI ID3DXBufferImpl_AddRef(LPD3DXBUFFER iface) { + ID3DXBufferImpl *This = (ID3DXBufferImpl *)iface; + ULONG ref = InterlockedIncrement(&This->ref); + + TRACE("(%p) : AddRef from %d\n", This, ref - 1); + + return ref; +} + +static ULONG WINAPI ID3DXBufferImpl_Release(LPD3DXBUFFER iface) { + ID3DXBufferImpl *This = (ID3DXBufferImpl *)iface; + ULONG ref = InterlockedDecrement(&This->ref); + + TRACE("(%p) : ReleaseRef to %d\n", This, ref); + + if (ref == 0) { + HeapFree(GetProcessHeap(), 0, This->buffer); + HeapFree(GetProcessHeap(), 0, This); + } + return ref; +} + +/* ID3DXBuffer Interface follow: */ +static LPVOID WINAPI ID3DXBufferImpl_GetBufferPointer(LPD3DXBUFFER iface) { + ID3DXBufferImpl *This = (ID3DXBufferImpl *)iface; + return This->buffer; +} + +static DWORD WINAPI ID3DXBufferImpl_GetBufferSize(LPD3DXBUFFER iface) { + ID3DXBufferImpl *This = (ID3DXBufferImpl *)iface; + return This->bufferSize; +} + +const ID3DXBufferVtbl D3DXBuffer_Vtbl = +{ + ID3DXBufferImpl_QueryInterface, + ID3DXBufferImpl_AddRef, + ID3DXBufferImpl_Release, + ID3DXBufferImpl_GetBufferPointer, + ID3DXBufferImpl_GetBufferSize +}; + +HRESULT WINAPI D3DXCreateBuffer(DWORD NumBytes, LPD3DXBUFFER* ppBuffer) { + ID3DXBufferImpl *object; + + object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(ID3DXBufferImpl)); + if (NULL == object) { + *ppBuffer = NULL; + return E_OUTOFMEMORY; + } + object->lpVtbl = &D3DXBuffer_Vtbl; + object->ref = 1; + object->bufferSize = NumBytes; + object->buffer = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, NumBytes); + if (NULL == object->buffer) { + HeapFree(GetProcessHeap(), 0, object); + *ppBuffer = NULL; + return E_OUTOFMEMORY; + } + *ppBuffer = (LPD3DXBUFFER)object; + return D3D_OK; +} + +HRESULT WINAPI D3DXAssembleShader(LPCVOID pSrcData, UINT SrcDataLen, DWORD Flags, + LPD3DXBUFFER* ppConstants, + LPD3DXBUFFER* ppCompiledShader, + LPD3DXBUFFER* ppCompilationErrors) { + FIXME("(void): stub\n"); + return D3D_OK; +} + +HRESULT WINAPI D3DXAssembleShaderFromFileA(LPCSTR pSrcFile, DWORD Flags, + LPD3DXBUFFER* ppConstants, + LPD3DXBUFFER* ppCompiledShader, + LPD3DXBUFFER* ppCompilationErrors) { + LPWSTR pSrcFileW = NULL; + DWORD len; + HRESULT ret; + + if (!pSrcFile) return D3DXERR_INVALIDDATA; + + len = MultiByteToWideChar( CP_ACP, 0, pSrcFile, -1, NULL, 0 ); + pSrcFileW = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) ); + MultiByteToWideChar( CP_ACP, 0, pSrcFile, -1, pSrcFileW, len ); + ret=D3DXAssembleShaderFromFileW(pSrcFileW, Flags, ppConstants, ppCompiledShader, ppCompilationErrors); + HeapFree( GetProcessHeap(), 0, pSrcFileW ); + return ret; +} + +HRESULT WINAPI D3DXAssembleShaderFromFileW(LPCWSTR pSrcFile, DWORD Flags, + LPD3DXBUFFER* ppConstants, + LPD3DXBUFFER* ppCompiledShader, + LPD3DXBUFFER* ppCompilationErrors) { + FIXME("(void): stub\n"); + return D3D_OK; +} + +HRESULT WINAPI D3DXCreateFont(LPDIRECT3DDEVICE8 pDevice, HFONT hFont, LPD3DXFONT* ppFont) { + FIXME("(void): stub\n"); + return D3D_OK; +} diff --git a/dlls/d3dx8/d3dx8.spec b/dlls/d3dx8/d3dx8.spec new file mode 100644 index 00000000000..88666f7dec5 --- /dev/null +++ b/dlls/d3dx8/d3dx8.spec @@ -0,0 +1,156 @@ +@ stdcall D3DXVec2Normalize(ptr ptr) +@ stdcall D3DXVec2Hermite(ptr ptr ptr ptr ptr long) +@ stdcall D3DXVec2CatmullRom(ptr ptr ptr ptr ptr long) +@ stdcall D3DXVec2BaryCentric(ptr ptr ptr ptr long long) +@ stdcall D3DXVec2Transform(ptr ptr ptr) +@ stdcall D3DXVec2TransformCoord(ptr ptr ptr) +@ stdcall D3DXVec2TransformNormal(ptr ptr ptr) +@ stdcall D3DXVec3Normalize(ptr ptr) +@ stdcall D3DXVec3Hermite(ptr ptr ptr ptr ptr long) +@ stdcall D3DXVec3CatmullRom(ptr ptr ptr ptr ptr long) +@ stdcall D3DXVec3BaryCentric(ptr ptr ptr ptr long long) +@ stdcall D3DXVec3Transform(ptr ptr ptr) +@ stdcall D3DXVec3TransformCoord(ptr ptr ptr) +@ stdcall D3DXVec3TransformNormal(ptr ptr ptr) +@ stdcall D3DXVec3Project(ptr ptr ptr ptr ptr ptr) +@ stdcall D3DXVec3Unproject(ptr ptr ptr ptr ptr ptr) +@ stdcall D3DXVec4Cross(ptr ptr ptr ptr) +@ stdcall D3DXVec4Normalize(ptr ptr) +@ stdcall D3DXVec4Hermite(ptr ptr ptr ptr ptr long) +@ stdcall D3DXVec4CatmullRom(ptr ptr ptr ptr ptr long) +@ stdcall D3DXVec4BaryCentric(ptr ptr ptr ptr long long) +@ stdcall D3DXVec4Transform(ptr ptr ptr) +@ stdcall D3DXMatrixfDeterminant(ptr) +@ stdcall D3DXMatrixMultiply(ptr ptr ptr) +@ stdcall D3DXMatrixMultiplyTranspose(ptr ptr ptr) +@ stdcall D3DXMatrixTranspose(ptr ptr) +@ stdcall D3DXMatrixInverse(ptr ptr ptr) +@ stdcall D3DXMatrixScaling(ptr long long long) +@ stdcall D3DXMatrixTranslation(ptr long long long) +@ stdcall D3DXMatrixRotationX(ptr long) +@ stdcall D3DXMatrixRotationY(ptr long) +@ stdcall D3DXMatrixRotationZ(ptr long) +@ stdcall D3DXMatrixRotationAxis(ptr ptr long) +@ stdcall D3DXMatrixRotationQuaternion(ptr ptr) +@ stdcall D3DXMatrixRotationYawPitchRoll(ptr long long long) +@ stdcall D3DXMatrixTransformation(ptr ptr ptr ptr ptr ptr ptr) +@ stdcall D3DXMatrixAffineTransformation(ptr long ptr ptr ptr) +@ stdcall D3DXMatrixLookAtRH(ptr ptr ptr ptr) +@ stdcall D3DXMatrixLookAtLH(ptr ptr ptr ptr) +@ stdcall D3DXMatrixPerspectiveRH(ptr long long long long) +@ stdcall D3DXMatrixPerspectiveLH(ptr long long long long) +@ stdcall D3DXMatrixPerspectiveFovRH(ptr long long long long) +@ stdcall D3DXMatrixPerspectiveFovLH(ptr long long long long) +@ stdcall D3DXMatrixPerspectiveOffCenterRH(ptr long long long long long long) +@ stdcall D3DXMatrixPerspectiveOffCenterLH(ptr long long long long long long) +@ stdcall D3DXMatrixOrthoRH(ptr long long long long) +@ stdcall D3DXMatrixOrthoLH(ptr long long long long) +@ stdcall D3DXMatrixOrthoOffCenterRH(ptr long long long long long long) +@ stdcall D3DXMatrixOrthoOffCenterLH(ptr long long long long long long) +@ stdcall D3DXMatrixShadow(ptr ptr ptr) +@ stdcall D3DXMatrixReflect(ptr ptr) +@ stdcall D3DXQuaternionToAxisAngle(ptr ptr ptr) +@ stdcall D3DXQuaternionRotationMatrix(ptr ptr) +@ stdcall D3DXQuaternionRotationAxis(ptr ptr long) +@ stdcall D3DXQuaternionRotationYawPitchRoll(ptr long long long) +@ stdcall D3DXQuaternionMultiply(ptr ptr ptr) +@ stdcall D3DXQuaternionNormalize(ptr ptr) +@ stdcall D3DXQuaternionInverse(ptr ptr) +@ stdcall D3DXQuaternionLn(ptr ptr) +@ stdcall D3DXQuaternionExp(ptr ptr) +@ stdcall D3DXQuaternionSlerp(ptr ptr ptr long) +@ stdcall D3DXQuaternionSquad(ptr ptr ptr ptr ptr long) +@ stdcall D3DXQuaternionBaryCentric(ptr ptr ptr ptr long long) +@ stdcall D3DXPlaneNormalize(ptr ptr) +@ stdcall D3DXPlaneIntersectLine(ptr ptr ptr ptr) +@ stdcall D3DXPlaneFromPointNormal(ptr ptr ptr) +@ stdcall D3DXPlaneFromPoints(ptr ptr ptr ptr) +@ stdcall D3DXPlaneTransform(ptr ptr ptr) +@ stdcall D3DXColorAdjustSaturation(ptr ptr long) +@ stdcall D3DXColorAdjustContrast(ptr ptr long) +@ stdcall D3DXFresnelTerm(long long) +@ stdcall D3DXCreateMatrixStack(long ptr) +@ stdcall D3DXCreateFont(ptr ptr ptr) +@ stub D3DXCreateFontIndirect +@ stub D3DXCreateSprite +@ stub D3DXCreateRenderToSurface +@ stub D3DXCreateRenderToEnvMap +@ stdcall D3DXAssembleShaderFromFileA(ptr long ptr ptr ptr) +@ stdcall D3DXAssembleShaderFromFileW(ptr long ptr ptr ptr) +@ stdcall D3DXGetFVFVertexSize(long) +@ stub D3DXGetErrorStringA +@ stub D3DXGetErrorStringW +@ stdcall D3DXAssembleShader(ptr long long ptr ptr ptr) +@ stub D3DXCompileEffectFromFileA +@ stub D3DXCompileEffectFromFileW +@ stub D3DXCompileEffect +@ stub D3DXCreateEffect +@ stub D3DXCreateMesh +@ stub D3DXCreateMeshFVF +@ stub D3DXCreateSPMesh +@ stub D3DXCleanMesh +@ stub D3DXValidMesh +@ stub D3DXGeneratePMesh +@ stub D3DXSimplifyMesh +@ stdcall D3DXComputeBoundingSphere(ptr long long ptr ptr) +@ stdcall D3DXComputeBoundingBox(ptr long long ptr ptr) +@ stub D3DXComputeNormals +@ stdcall D3DXCreateBuffer(long ptr) +@ stub D3DXLoadMeshFromX +@ stub D3DXSaveMeshToX +@ stub D3DXCreatePMeshFromStream +@ stub D3DXCreateSkinMesh +@ stub D3DXCreateSkinMeshFVF +@ stub D3DXCreateSkinMeshFromMesh +@ stub D3DXLoadMeshFromXof +@ stub D3DXLoadSkinMeshFromXof +@ stub D3DXTesselateMesh +@ stub D3DXDeclaratorFromFVF +@ stub D3DXFVFFromDeclarator +@ stub D3DXWeldVertices +@ stub D3DXIntersect +@ cdecl D3DXIntersectTri(ptr ptr ptr ptr ptr ptr ptr ptr) +@ stdcall D3DXSphereBoundProbe(ptr long ptr ptr) +@ stdcall D3DXBoxBoundProbe(ptr ptr ptr ptr) +@ stub D3DXCreatePolygon +@ stub D3DXCreateBox +@ stub D3DXCreateCylinder +@ stub D3DXCreateSphere +@ stub D3DXCreateTorus +@ stub D3DXCreateTeapot +@ stub D3DXCreateTextA +@ stub D3DXCreateTextW +@ stub D3DXLoadSurfaceFromFileA +@ stub D3DXLoadSurfaceFromFileW +@ stub D3DXLoadSurfaceFromResourceA +@ stub D3DXLoadSurfaceFromResourceW +@ stub D3DXLoadSurfaceFromFileInMemory +@ stub D3DXLoadSurfaceFromSurface +@ stub D3DXLoadSurfaceFromMemory +@ stub D3DXLoadVolumeFromVolume +@ stub D3DXLoadVolumeFromMemory +@ stub D3DXCheckTextureRequirements +@ stub D3DXCreateTexture +@ stub D3DXCreateTextureFromFileA +@ stub D3DXCreateTextureFromFileW +@ stub D3DXCreateTextureFromResourceA +@ stub D3DXCreateTextureFromResourceW +@ stub D3DXCreateTextureFromFileExA +@ stub D3DXCreateTextureFromFileExW +@ stub D3DXCreateTextureFromResourceExA +@ stub D3DXCreateTextureFromResourceExW +@ stub D3DXCreateTextureFromFileInMemory +@ stub D3DXCreateTextureFromFileInMemoryEx +@ stub D3DXFilterTexture +@ stub D3DXCheckCubeTextureRequirements +@ stub D3DXCreateCubeTexture +@ stub D3DXCreateCubeTextureFromFileA +@ stub D3DXCreateCubeTextureFromFileW +@ stub D3DXCreateCubeTextureFromFileExA +@ stub D3DXCreateCubeTextureFromFileExW +@ stub D3DXCreateCubeTextureFromFileInMemory +@ stub D3DXCreateCubeTextureFromFileInMemoryEx +@ stub D3DXFilterCubeTexture +@ stub D3DXCheckVolumeTextureRequirements +@ stub D3DXCreateVolumeTexture +@ stub D3DXFilterVolumeTexture diff --git a/dlls/d3dx8/d3dx8_main.c b/dlls/d3dx8/d3dx8_main.c new file mode 100644 index 00000000000..4fb860a7313 --- /dev/null +++ b/dlls/d3dx8/d3dx8_main.c @@ -0,0 +1,43 @@ +/* + * Direct3D X 8 main file + * + * Copyright (C) 2002 Raphael Junqueira + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + * + */ + +#include + +#include "windef.h" +#include "winbase.h" + +/*********************************************************************** + * DllMain. + */ +BOOL WINAPI DllMain(HINSTANCE inst, DWORD reason, LPVOID reserved) +{ + switch(reason) + { + case DLL_WINE_PREATTACH: + return FALSE; /* prefer native version */ + case DLL_PROCESS_ATTACH: + DisableThreadLibraryCalls(inst); + break; + case DLL_PROCESS_DETACH: + break; + } + return TRUE; +} diff --git a/dlls/d3dx8/d3dx8_private.h b/dlls/d3dx8/d3dx8_private.h new file mode 100644 index 00000000000..01174dcc671 --- /dev/null +++ b/dlls/d3dx8/d3dx8_private.h @@ -0,0 +1,94 @@ +/* + * Direct3D X 8 private include file + * + * Copyright 2002 Raphael Junqueira + * Copyright 2007 David Adam + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#ifndef __WINE_D3DX8_PRIVATE_H +#define __WINE_D3DX8_PRIVATE_H + +#include + +#include "windef.h" +#include "winbase.h" +#include "d3dx8.h" + +/* Interfaces */ +typedef struct ID3DXBufferImpl ID3DXBufferImpl; +typedef struct ID3DXFontImpl ID3DXFontImpl; +typedef struct ID3DXMatrixStackImpl ID3DXMatrixStackImpl; + +/* ----------- */ +/* ID3DXBuffer */ +/* ----------- */ + +/***************************************************************************** + * Predeclare the interface implementation structures + */ +extern const ID3DXBufferVtbl D3DXBuffer_Vtbl; + +/***************************************************************************** + * ID3DXBufferImpl implementation structure + */ +struct ID3DXBufferImpl +{ + /* IUnknown fields */ + const ID3DXBufferVtbl *lpVtbl; + LONG ref; + + /* ID3DXBuffer fields */ + DWORD *buffer; + DWORD bufferSize; +}; + +/* --------- */ +/* ID3DXFont */ +/* --------- */ + +/***************************************************************************** + * ID3DXFontImpl implementation structure + */ +struct ID3DXFontImpl +{ + /* IUnknown fields */ + const ID3DXFontVtbl *lpVtbl; + LONG ref; + + /* ID3DXFont fields */ +}; + +/* ----------- */ +/* ID3DXMatrix */ +/* ----------- */ + +/***************************************************************************** + * ID3DXMatrixStackImpl implementation structure + */ +struct ID3DXMatrixStackImpl +{ + /* IUnknown fields */ + const ID3DXMatrixStackVtbl *lpVtbl; + LONG ref; + + /* ID3DXMatrixStack fields */ + unsigned int current; + unsigned int stack_size; + D3DXMATRIX *stack; +}; + +#endif /*__WINE_D3DX8_PRIVATE_H */ diff --git a/dlls/d3dx8/math.c b/dlls/d3dx8/math.c new file mode 100644 index 00000000000..34f6fed04d7 --- /dev/null +++ b/dlls/d3dx8/math.c @@ -0,0 +1,1524 @@ +/* + * Copyright 2007 David Adam + * Copyright 2008 Jérôme Gardou + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include + +#define NONAMELESSUNION + +#include "windef.h" +#include "winbase.h" +#include "wingdi.h" +#include "d3dx8_private.h" + +#include "wine/debug.h" + +WINE_DEFAULT_DEBUG_CHANNEL(d3dx); + +static const ID3DXMatrixStackVtbl ID3DXMatrixStack_Vtbl; + +/*_________________D3DXColor____________________*/ + +D3DXCOLOR* WINAPI D3DXColorAdjustContrast(D3DXCOLOR *pout, CONST D3DXCOLOR *pc, FLOAT s) +{ + pout->r = 0.5f + s * (pc->r - 0.5f); + pout->g = 0.5f + s * (pc->g - 0.5f); + pout->b = 0.5f + s * (pc->b - 0.5f); + pout->a = pc->a; + return pout; +} + +D3DXCOLOR* WINAPI D3DXColorAdjustSaturation(D3DXCOLOR *pout, CONST D3DXCOLOR *pc, FLOAT s) +{ + FLOAT grey; + + grey = pc->r * 0.2125f + pc->g * 0.7154f + pc->b * 0.0721f; + pout->r = grey + s * (pc->r - grey); + pout->g = grey + s * (pc->g - grey); + pout->b = grey + s * (pc->b - grey); + pout->a = pc->a; + return pout; +} + +/*_________________Misc__________________________*/ + +FLOAT WINAPI D3DXFresnelTerm(FLOAT costheta, FLOAT refractionindex) +{ + FLOAT a, d, g, result; + + g = sqrt(refractionindex * refractionindex + costheta * costheta - 1.0f); + a = g + costheta; + d = g - costheta; + result = ( costheta * a - 1.0f ) * ( costheta * a - 1.0f ) / ( ( costheta * d + 1.0f ) * ( costheta * d + 1.0f ) ) + 1.0f; + result = result * 0.5f * d * d / ( a * a ); + return result; +} + +/*_________________D3DXMatrix____________________*/ + +D3DXMATRIX* WINAPI D3DXMatrixAffineTransformation(D3DXMATRIX *pout, FLOAT scaling, CONST D3DXVECTOR3 *rotationcenter, CONST D3DXQUATERNION *rotation, CONST D3DXVECTOR3 *translation) +{ + D3DXMATRIX m1, m2, m3, m4, m5; + + D3DXMatrixScaling(&m1, scaling, scaling, scaling); + if ( !rotationcenter ) + { + D3DXMatrixIdentity(&m2); + D3DXMatrixIdentity(&m4); + } + else + { + D3DXMatrixTranslation(&m2, -rotationcenter->x, -rotationcenter->y, -rotationcenter->z); + D3DXMatrixTranslation(&m4, rotationcenter->x, rotationcenter->y, rotationcenter->z); + } + if ( !rotation ) + { + D3DXMatrixIdentity(&m3); + } + else + { + D3DXMatrixRotationQuaternion(&m3, rotation); + } + if ( !translation ) + { + D3DXMatrixIdentity(&m5); + } + else + { + D3DXMatrixTranslation(&m5, translation->x, translation->y, translation->z); + } + D3DXMatrixMultiply(&m1, &m1, &m2); + D3DXMatrixMultiply(&m1, &m1, &m3); + D3DXMatrixMultiply(&m1, &m1, &m4); + D3DXMatrixMultiply(pout, &m1, &m5); + return pout; +} + +FLOAT WINAPI D3DXMatrixfDeterminant(CONST D3DXMATRIX *pm) +{ + D3DXVECTOR4 minor, v1, v2, v3; + FLOAT det; + + v1.x = pm->u.m[0][0]; v1.y = pm->u.m[1][0]; v1.z = pm->u.m[2][0]; v1.w = pm->u.m[3][0]; + v2.x = pm->u.m[0][1]; v2.y = pm->u.m[1][1]; v2.z = pm->u.m[2][1]; v2.w = pm->u.m[3][1]; + v3.x = pm->u.m[0][2]; v3.y = pm->u.m[1][2]; v3.z = pm->u.m[2][2]; v3.w = pm->u.m[3][2]; + D3DXVec4Cross(&minor, &v1, &v2, &v3); + det = - (pm->u.m[0][3] * minor.x + pm->u.m[1][3] * minor.y + pm->u.m[2][3] * minor.z + pm->u.m[3][3] * minor.w); + return det; +} + +D3DXMATRIX* WINAPI D3DXMatrixInverse(D3DXMATRIX *pout, FLOAT *pdeterminant, CONST D3DXMATRIX *pm) +{ + int a, i, j; + D3DXMATRIX out; + D3DXVECTOR4 v, vec[3]; + FLOAT det; + + det = D3DXMatrixfDeterminant(pm); + if ( !det ) return NULL; + if ( pdeterminant ) *pdeterminant = det; + for (i=0; i<4; i++) + { + for (j=0; j<4; j++) + { + if (j != i ) + { + a = j; + if ( j > i ) a = a-1; + vec[a].x = pm->u.m[j][0]; + vec[a].y = pm->u.m[j][1]; + vec[a].z = pm->u.m[j][2]; + vec[a].w = pm->u.m[j][3]; + } + } + D3DXVec4Cross(&v, &vec[0], &vec[1], &vec[2]); + out.u.m[0][i] = pow(-1.0f, i) * v.x / det; + out.u.m[1][i] = pow(-1.0f, i) * v.y / det; + out.u.m[2][i] = pow(-1.0f, i) * v.z / det; + out.u.m[3][i] = pow(-1.0f, i) * v.w / det; + } + *pout = out; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixLookAtLH(D3DXMATRIX *pout, CONST D3DXVECTOR3 *peye, CONST D3DXVECTOR3 *pat, CONST D3DXVECTOR3 *pup) +{ + D3DXVECTOR3 right, rightn, up, upn, vec, vec2; + + D3DXVec3Subtract(&vec2, pat, peye); + D3DXVec3Normalize(&vec, &vec2); + D3DXVec3Cross(&right, pup, &vec); + D3DXVec3Cross(&up, &vec, &right); + D3DXVec3Normalize(&rightn, &right); + D3DXVec3Normalize(&upn, &up); + pout->u.m[0][0] = rightn.x; + pout->u.m[1][0] = rightn.y; + pout->u.m[2][0] = rightn.z; + pout->u.m[3][0] = -D3DXVec3Dot(&rightn,peye); + pout->u.m[0][1] = upn.x; + pout->u.m[1][1] = upn.y; + pout->u.m[2][1] = upn.z; + pout->u.m[3][1] = -D3DXVec3Dot(&upn, peye); + pout->u.m[0][2] = vec.x; + pout->u.m[1][2] = vec.y; + pout->u.m[2][2] = vec.z; + pout->u.m[3][2] = -D3DXVec3Dot(&vec, peye); + pout->u.m[0][3] = 0.0f; + pout->u.m[1][3] = 0.0f; + pout->u.m[2][3] = 0.0f; + pout->u.m[3][3] = 1.0f; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixLookAtRH(D3DXMATRIX *pout, CONST D3DXVECTOR3 *peye, CONST D3DXVECTOR3 *pat, CONST D3DXVECTOR3 *pup) +{ + D3DXVECTOR3 right, rightn, up, upn, vec, vec2; + + D3DXVec3Subtract(&vec2, pat, peye); + D3DXVec3Normalize(&vec, &vec2); + D3DXVec3Cross(&right, pup, &vec); + D3DXVec3Cross(&up, &vec, &right); + D3DXVec3Normalize(&rightn, &right); + D3DXVec3Normalize(&upn, &up); + pout->u.m[0][0] = -rightn.x; + pout->u.m[1][0] = -rightn.y; + pout->u.m[2][0] = -rightn.z; + pout->u.m[3][0] = D3DXVec3Dot(&rightn,peye); + pout->u.m[0][1] = upn.x; + pout->u.m[1][1] = upn.y; + pout->u.m[2][1] = upn.z; + pout->u.m[3][1] = -D3DXVec3Dot(&upn, peye); + pout->u.m[0][2] = -vec.x; + pout->u.m[1][2] = -vec.y; + pout->u.m[2][2] = -vec.z; + pout->u.m[3][2] = D3DXVec3Dot(&vec, peye); + pout->u.m[0][3] = 0.0f; + pout->u.m[1][3] = 0.0f; + pout->u.m[2][3] = 0.0f; + pout->u.m[3][3] = 1.0f; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixMultiply(D3DXMATRIX *pout, CONST D3DXMATRIX *pm1, CONST D3DXMATRIX *pm2) +{ + D3DXMATRIX out; + int i,j; + + for (i=0; i<4; i++) + { + for (j=0; j<4; j++) + { + out.u.m[i][j] = pm1->u.m[i][0] * pm2->u.m[0][j] + pm1->u.m[i][1] * pm2->u.m[1][j] + pm1->u.m[i][2] * pm2->u.m[2][j] + pm1->u.m[i][3] * pm2->u.m[3][j]; + } + } + *pout = out; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixMultiplyTranspose(D3DXMATRIX *pout, CONST D3DXMATRIX *pm1, CONST D3DXMATRIX *pm2) +{ + D3DXMatrixMultiply(pout, pm1, pm2); + D3DXMatrixTranspose(pout, pout); + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixOrthoLH(D3DXMATRIX *pout, FLOAT w, FLOAT h, FLOAT zn, FLOAT zf) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = 2.0f / w; + pout->u.m[1][1] = 2.0f / h; + pout->u.m[2][2] = 1.0f / (zf - zn); + pout->u.m[3][2] = zn / (zn - zf); + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixOrthoOffCenterLH(D3DXMATRIX *pout, FLOAT l, FLOAT r, FLOAT b, FLOAT t, FLOAT zn, FLOAT zf) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = 2.0f / (r - l); + pout->u.m[1][1] = 2.0f / (t - b); + pout->u.m[2][2] = 1.0f / (zf -zn); + pout->u.m[3][0] = -1.0f -2.0f *l / (r - l); + pout->u.m[3][1] = 1.0f + 2.0f * t / (b - t); + pout->u.m[3][2] = zn / (zn -zf); + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixOrthoOffCenterRH(D3DXMATRIX *pout, FLOAT l, FLOAT r, FLOAT b, FLOAT t, FLOAT zn, FLOAT zf) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = 2.0f / (r - l); + pout->u.m[1][1] = 2.0f / (t - b); + pout->u.m[2][2] = 1.0f / (zn -zf); + pout->u.m[3][0] = -1.0f -2.0f *l / (r - l); + pout->u.m[3][1] = 1.0f + 2.0f * t / (b - t); + pout->u.m[3][2] = zn / (zn -zf); + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixOrthoRH(D3DXMATRIX *pout, FLOAT w, FLOAT h, FLOAT zn, FLOAT zf) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = 2.0f / w; + pout->u.m[1][1] = 2.0f / h; + pout->u.m[2][2] = 1.0f / (zn - zf); + pout->u.m[3][2] = zn / (zn - zf); + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixPerspectiveFovLH(D3DXMATRIX *pout, FLOAT fovy, FLOAT aspect, FLOAT zn, FLOAT zf) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = 1.0f / (aspect * tan(fovy/2.0f)); + pout->u.m[1][1] = 1.0f / tan(fovy/2.0f); + pout->u.m[2][2] = zf / (zf - zn); + pout->u.m[2][3] = 1.0f; + pout->u.m[3][2] = (zf * zn) / (zn - zf); + pout->u.m[3][3] = 0.0f; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixPerspectiveFovRH(D3DXMATRIX *pout, FLOAT fovy, FLOAT aspect, FLOAT zn, FLOAT zf) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = 1.0f / (aspect * tan(fovy/2.0f)); + pout->u.m[1][1] = 1.0f / tan(fovy/2.0f); + pout->u.m[2][2] = zf / (zn - zf); + pout->u.m[2][3] = -1.0f; + pout->u.m[3][2] = (zf * zn) / (zn - zf); + pout->u.m[3][3] = 0.0f; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixPerspectiveLH(D3DXMATRIX *pout, FLOAT w, FLOAT h, FLOAT zn, FLOAT zf) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = 2.0f * zn / w; + pout->u.m[1][1] = 2.0f * zn / h; + pout->u.m[2][2] = zf / (zf - zn); + pout->u.m[3][2] = (zn * zf) / (zn - zf); + pout->u.m[2][3] = 1.0f; + pout->u.m[3][3] = 0.0f; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixPerspectiveOffCenterLH(D3DXMATRIX *pout, FLOAT l, FLOAT r, FLOAT b, FLOAT t, FLOAT zn, FLOAT zf) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = 2.0f * zn / (r - l); + pout->u.m[1][1] = -2.0f * zn / (b - t); + pout->u.m[2][0] = -1.0f - 2.0f * l / (r - l); + pout->u.m[2][1] = 1.0f + 2.0f * t / (b - t); + pout->u.m[2][2] = - zf / (zn - zf); + pout->u.m[3][2] = (zn * zf) / (zn -zf); + pout->u.m[2][3] = 1.0f; + pout->u.m[3][3] = 0.0f; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixPerspectiveOffCenterRH(D3DXMATRIX *pout, FLOAT l, FLOAT r, FLOAT b, FLOAT t, FLOAT zn, FLOAT zf) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = 2.0f * zn / (r - l); + pout->u.m[1][1] = -2.0f * zn / (b - t); + pout->u.m[2][0] = 1.0f + 2.0f * l / (r - l); + pout->u.m[2][1] = -1.0f -2.0f * t / (b - t); + pout->u.m[2][2] = zf / (zn - zf); + pout->u.m[3][2] = (zn * zf) / (zn -zf); + pout->u.m[2][3] = -1.0f; + pout->u.m[3][3] = 0.0f; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixPerspectiveRH(D3DXMATRIX *pout, FLOAT w, FLOAT h, FLOAT zn, FLOAT zf) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = 2.0f * zn / w; + pout->u.m[1][1] = 2.0f * zn / h; + pout->u.m[2][2] = zf / (zn - zf); + pout->u.m[3][2] = (zn * zf) / (zn - zf); + pout->u.m[2][3] = -1.0f; + pout->u.m[3][3] = 0.0f; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixReflect(D3DXMATRIX *pout, CONST D3DXPLANE *pplane) +{ + D3DXPLANE Nplane; + + D3DXPlaneNormalize(&Nplane, pplane); + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = 1.0f - 2.0f * Nplane.a * Nplane.a; + pout->u.m[0][1] = -2.0f * Nplane.a * Nplane.b; + pout->u.m[0][2] = -2.0f * Nplane.a * Nplane.c; + pout->u.m[1][0] = -2.0f * Nplane.a * Nplane.b; + pout->u.m[1][1] = 1.0f - 2.0f * Nplane.b * Nplane.b; + pout->u.m[1][2] = -2.0f * Nplane.b * Nplane.c; + pout->u.m[2][0] = -2.0f * Nplane.c * Nplane.a; + pout->u.m[2][1] = -2.0f * Nplane.c * Nplane.b; + pout->u.m[2][2] = 1.0f - 2.0f * Nplane.c * Nplane.c; + pout->u.m[3][0] = -2.0f * Nplane.d * Nplane.a; + pout->u.m[3][1] = -2.0f * Nplane.d * Nplane.b; + pout->u.m[3][2] = -2.0f * Nplane.d * Nplane.c; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixRotationAxis(D3DXMATRIX *pout, CONST D3DXVECTOR3 *pv, FLOAT angle) +{ + D3DXVECTOR3 v; + + D3DXVec3Normalize(&v,pv); + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = (1.0f - cos(angle)) * v.x * v.x + cos(angle); + pout->u.m[1][0] = (1.0f - cos(angle)) * v.x * v.y - sin(angle) * v.z; + pout->u.m[2][0] = (1.0f - cos(angle)) * v.x * v.z + sin(angle) * v.y; + pout->u.m[0][1] = (1.0f - cos(angle)) * v.y * v.x + sin(angle) * v.z; + pout->u.m[1][1] = (1.0f - cos(angle)) * v.y * v.y + cos(angle); + pout->u.m[2][1] = (1.0f - cos(angle)) * v.y * v.z - sin(angle) * v.x; + pout->u.m[0][2] = (1.0f - cos(angle)) * v.z * v.x - sin(angle) * v.y; + pout->u.m[1][2] = (1.0f - cos(angle)) * v.z * v.y + sin(angle) * v.x; + pout->u.m[2][2] = (1.0f - cos(angle)) * v.z * v.z + cos(angle); + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixRotationQuaternion(D3DXMATRIX *pout, CONST D3DXQUATERNION *pq) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = 1.0f - 2.0f * (pq->y * pq->y + pq->z * pq->z); + pout->u.m[0][1] = 2.0f * (pq->x *pq->y + pq->z * pq->w); + pout->u.m[0][2] = 2.0f * (pq->x * pq->z - pq->y * pq->w); + pout->u.m[1][0] = 2.0f * (pq->x * pq->y - pq->z * pq->w); + pout->u.m[1][1] = 1.0f - 2.0f * (pq->x * pq->x + pq->z * pq->z); + pout->u.m[1][2] = 2.0f * (pq->y *pq->z + pq->x *pq->w); + pout->u.m[2][0] = 2.0f * (pq->x * pq->z + pq->y * pq->w); + pout->u.m[2][1] = 2.0f * (pq->y *pq->z - pq->x *pq->w); + pout->u.m[2][2] = 1.0f - 2.0f * (pq->x * pq->x + pq->y * pq->y); + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixRotationX(D3DXMATRIX *pout, FLOAT angle) +{ + D3DXMatrixIdentity(pout); + pout->u.m[1][1] = cos(angle); + pout->u.m[2][2] = cos(angle); + pout->u.m[1][2] = sin(angle); + pout->u.m[2][1] = -sin(angle); + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixRotationY(D3DXMATRIX *pout, FLOAT angle) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = cos(angle); + pout->u.m[2][2] = cos(angle); + pout->u.m[0][2] = -sin(angle); + pout->u.m[2][0] = sin(angle); + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixRotationYawPitchRoll(D3DXMATRIX *pout, FLOAT yaw, FLOAT pitch, FLOAT roll) +{ + D3DXMATRIX m; + + D3DXMatrixIdentity(pout); + D3DXMatrixRotationZ(&m, roll); + D3DXMatrixMultiply(pout, pout, &m); + D3DXMatrixRotationX(&m, pitch); + D3DXMatrixMultiply(pout, pout, &m); + D3DXMatrixRotationY(&m, yaw); + D3DXMatrixMultiply(pout, pout, &m); + return pout; +} +D3DXMATRIX* WINAPI D3DXMatrixRotationZ(D3DXMATRIX *pout, FLOAT angle) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = cos(angle); + pout->u.m[1][1] = cos(angle); + pout->u.m[0][1] = sin(angle); + pout->u.m[1][0] = -sin(angle); + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixScaling(D3DXMATRIX *pout, FLOAT sx, FLOAT sy, FLOAT sz) +{ + D3DXMatrixIdentity(pout); + pout->u.m[0][0] = sx; + pout->u.m[1][1] = sy; + pout->u.m[2][2] = sz; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixShadow(D3DXMATRIX *pout, CONST D3DXVECTOR4 *plight, CONST D3DXPLANE *pplane) +{ + D3DXPLANE Nplane; + FLOAT dot; + + D3DXPlaneNormalize(&Nplane, pplane); + dot = D3DXPlaneDot(&Nplane, plight); + pout->u.m[0][0] = dot - Nplane.a * plight->x; + pout->u.m[0][1] = -Nplane.a * plight->y; + pout->u.m[0][2] = -Nplane.a * plight->z; + pout->u.m[0][3] = -Nplane.a * plight->w; + pout->u.m[1][0] = -Nplane.b * plight->x; + pout->u.m[1][1] = dot - Nplane.b * plight->y; + pout->u.m[1][2] = -Nplane.b * plight->z; + pout->u.m[1][3] = -Nplane.b * plight->w; + pout->u.m[2][0] = -Nplane.c * plight->x; + pout->u.m[2][1] = -Nplane.c * plight->y; + pout->u.m[2][2] = dot - Nplane.c * plight->z; + pout->u.m[2][3] = -Nplane.c * plight->w; + pout->u.m[3][0] = -Nplane.d * plight->x; + pout->u.m[3][1] = -Nplane.d * plight->y; + pout->u.m[3][2] = -Nplane.d * plight->z; + pout->u.m[3][3] = dot - Nplane.d * plight->w; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixTransformation(D3DXMATRIX *pout, CONST D3DXVECTOR3 *pscalingcenter, CONST D3DXQUATERNION *pscalingrotation, CONST D3DXVECTOR3 *pscaling, CONST D3DXVECTOR3 *protationcenter, CONST D3DXQUATERNION *protation, CONST D3DXVECTOR3 *ptranslation) +{ + D3DXMATRIX m1, m2, m3, m4, m5, m6, m7; + D3DXQUATERNION prc; + D3DXVECTOR3 psc, pt; + + if ( !pscalingcenter ) + { + psc.x = 0.0f; + psc.y = 0.0f; + psc.z = 0.0f; + } + else + { + psc.x = pscalingcenter->x; + psc.y = pscalingcenter->y; + psc.z = pscalingcenter->z; + } + if ( !protationcenter ) + { + prc.x = 0.0f; + prc.y = 0.0f; + prc.z = 0.0f; + } + else + { + prc.x = protationcenter->x; + prc.y = protationcenter->y; + prc.z = protationcenter->z; + } + if ( !ptranslation ) + { + pt.x = 0.0f; + pt.y = 0.0f; + pt.z = 0.0f; + } + else + { + pt.x = ptranslation->x; + pt.y = ptranslation->y; + pt.z = ptranslation->z; + } + D3DXMatrixTranslation(&m1, -psc.x, -psc.y, -psc.z); + if ( !pscalingrotation ) + { + D3DXMatrixIdentity(&m2); + D3DXMatrixIdentity(&m4); + } + else + { + D3DXMatrixRotationQuaternion(&m4, pscalingrotation); + D3DXMatrixInverse(&m2, NULL, &m4); + } + if ( !pscaling ) + { + D3DXMatrixIdentity(&m3); + } + else + { + D3DXMatrixScaling(&m3, pscaling->x, pscaling->y, pscaling->z); + } + if ( !protation ) + { + D3DXMatrixIdentity(&m6); + } + else + { + D3DXMatrixRotationQuaternion(&m6, protation); + } + D3DXMatrixTranslation(&m5, psc.x - prc.x, psc.y - prc.y, psc.z - prc.z); + D3DXMatrixTranslation(&m7, prc.x + pt.x, prc.y + pt.y, prc.z + pt.z); + D3DXMatrixMultiply(&m1, &m1, &m2); + D3DXMatrixMultiply(&m1, &m1, &m3); + D3DXMatrixMultiply(&m1, &m1, &m4); + D3DXMatrixMultiply(&m1, &m1, &m5); + D3DXMatrixMultiply(&m1, &m1, &m6); + D3DXMatrixMultiply(pout, &m1, &m7); + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixTranslation(D3DXMATRIX *pout, FLOAT x, FLOAT y, FLOAT z) +{ + D3DXMatrixIdentity(pout); + pout->u.m[3][0] = x; + pout->u.m[3][1] = y; + pout->u.m[3][2] = z; + return pout; +} + +D3DXMATRIX* WINAPI D3DXMatrixTranspose(D3DXMATRIX *pout, CONST D3DXMATRIX *pm) +{ + CONST D3DXMATRIX m = *pm; + int i,j; + + for (i=0; i<4; i++) + { + for (j=0; j<4; j++) + { + pout->u.m[i][j] = m.u.m[j][i]; + } + } + return pout; +} + +/*_________________D3DXMatrixStack____________________*/ + +static const unsigned int INITIAL_STACK_SIZE = 32; + +HRESULT WINAPI D3DXCreateMatrixStack(DWORD flags, LPD3DXMATRIXSTACK* ppstack) +{ + ID3DXMatrixStackImpl* object; + + TRACE("flags %#x, ppstack %p\n", flags, ppstack); + + object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(ID3DXMatrixStackImpl)); + if ( object == NULL ) + { + *ppstack = NULL; + return E_OUTOFMEMORY; + } + object->lpVtbl = &ID3DXMatrixStack_Vtbl; + object->ref = 1; + + object->stack = HeapAlloc(GetProcessHeap(), 0, INITIAL_STACK_SIZE * sizeof(D3DXMATRIX)); + if (!object->stack) + { + HeapFree(GetProcessHeap(), 0, object); + *ppstack = NULL; + return E_OUTOFMEMORY; + } + + object->current = 0; + object->stack_size = INITIAL_STACK_SIZE; + D3DXMatrixIdentity(&object->stack[0]); + + TRACE("Created matrix stack %p\n", object); + + *ppstack = (LPD3DXMATRIXSTACK)object; + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_QueryInterface(ID3DXMatrixStack *iface, REFIID riid, void **ppobj) +{ + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + if (IsEqualGUID(riid, &IID_IUnknown) || IsEqualGUID(riid, &IID_ID3DXMatrixStack)) + { + ID3DXMatrixStack_AddRef(iface); + *ppobj = This; + return S_OK; + } + *ppobj = NULL; + ERR("(%p)->(%s,%p),not found\n",This,debugstr_guid(riid),ppobj); + return E_NOINTERFACE; +} + +static ULONG WINAPI ID3DXMatrixStackImpl_AddRef(ID3DXMatrixStack *iface) +{ + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + ULONG ref = InterlockedIncrement(&This->ref); + TRACE("(%p) : AddRef from %d\n", This, ref - 1); + return ref; +} + +static ULONG WINAPI ID3DXMatrixStackImpl_Release(ID3DXMatrixStack* iface) +{ + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + ULONG ref = InterlockedDecrement(&This->ref); + if (!ref) + { + HeapFree(GetProcessHeap(), 0, This->stack); + HeapFree(GetProcessHeap(), 0, This); + } + TRACE("(%p) : ReleaseRef to %d\n", This, ref); + return ref; +} + +static D3DXMATRIX* WINAPI ID3DXMatrixStackImpl_GetTop(ID3DXMatrixStack *iface) +{ + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + return &This->stack[This->current]; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_LoadIdentity(ID3DXMatrixStack *iface) +{ + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + D3DXMatrixIdentity(&This->stack[This->current]); + + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_LoadMatrix(ID3DXMatrixStack *iface, CONST D3DXMATRIX *pm) +{ + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + if (!pm) return D3DERR_INVALIDCALL; + This->stack[This->current] = *pm; + + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_MultMatrix(ID3DXMatrixStack *iface, CONST D3DXMATRIX *pm) +{ + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + if (!pm) return D3DERR_INVALIDCALL; + D3DXMatrixMultiply(&This->stack[This->current], &This->stack[This->current], pm); + + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_MultMatrixLocal(ID3DXMatrixStack *iface, CONST D3DXMATRIX *pm) +{ + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + if (!pm) return D3DERR_INVALIDCALL; + D3DXMatrixMultiply(&This->stack[This->current], pm, &This->stack[This->current]); + + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_Pop(ID3DXMatrixStack *iface) +{ + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + /* Popping the last element on the stack returns D3D_OK, but does nothing. */ + if (!This->current) return D3D_OK; + + if (This->current <= This->stack_size / 4 && This->stack_size >= INITIAL_STACK_SIZE * 2) + { + unsigned int new_size; + D3DXMATRIX *new_stack; + + new_size = This->stack_size / 2; + new_stack = HeapReAlloc(GetProcessHeap(), 0, This->stack, new_size * sizeof(D3DXMATRIX)); + if (new_stack) + { + This->stack_size = new_size; + This->stack = new_stack; + } + } + + --This->current; + + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_Push(ID3DXMatrixStack *iface) +{ + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + if (This->current == This->stack_size - 1) + { + unsigned int new_size; + D3DXMATRIX *new_stack; + + if (This->stack_size > UINT_MAX / 2) return E_OUTOFMEMORY; + + new_size = This->stack_size * 2; + new_stack = HeapReAlloc(GetProcessHeap(), 0, This->stack, new_size * sizeof(D3DXMATRIX)); + if (!new_stack) return E_OUTOFMEMORY; + + This->stack_size = new_size; + This->stack = new_stack; + } + + ++This->current; + This->stack[This->current] = This->stack[This->current - 1]; + + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_RotateAxis(ID3DXMatrixStack *iface, CONST D3DXVECTOR3 *pv, FLOAT angle) +{ + D3DXMATRIX temp; + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + if (!pv) return D3DERR_INVALIDCALL; + D3DXMatrixRotationAxis(&temp, pv, angle); + D3DXMatrixMultiply(&This->stack[This->current], &This->stack[This->current], &temp); + + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_RotateAxisLocal(ID3DXMatrixStack *iface, CONST D3DXVECTOR3 *pv, FLOAT angle) +{ + D3DXMATRIX temp; + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + if (!pv) return D3DERR_INVALIDCALL; + D3DXMatrixRotationAxis(&temp, pv, angle); + D3DXMatrixMultiply(&This->stack[This->current], &temp, &This->stack[This->current]); + + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_RotateYawPitchRoll(ID3DXMatrixStack *iface, FLOAT x, FLOAT y, FLOAT z) +{ + D3DXMATRIX temp; + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + D3DXMatrixRotationYawPitchRoll(&temp, x, y, z); + D3DXMatrixMultiply(&This->stack[This->current], &This->stack[This->current], &temp); + + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_RotateYawPitchRollLocal(ID3DXMatrixStack *iface, FLOAT x, FLOAT y, FLOAT z) +{ + D3DXMATRIX temp; + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + D3DXMatrixRotationYawPitchRoll(&temp, x, y, z); + D3DXMatrixMultiply(&This->stack[This->current], &temp, &This->stack[This->current]); + + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_Scale(ID3DXMatrixStack *iface, FLOAT x, FLOAT y, FLOAT z) +{ + D3DXMATRIX temp; + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + D3DXMatrixScaling(&temp, x, y, z); + D3DXMatrixMultiply(&This->stack[This->current], &This->stack[This->current], &temp); + + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_ScaleLocal(ID3DXMatrixStack *iface, FLOAT x, FLOAT y, FLOAT z) +{ + D3DXMATRIX temp; + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + D3DXMatrixScaling(&temp, x, y, z); + D3DXMatrixMultiply(&This->stack[This->current], &temp, &This->stack[This->current]); + + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_Translate(ID3DXMatrixStack *iface, FLOAT x, FLOAT y, FLOAT z) +{ + D3DXMATRIX temp; + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + D3DXMatrixTranslation(&temp, x, y, z); + D3DXMatrixMultiply(&This->stack[This->current], &This->stack[This->current], &temp); + + return D3D_OK; +} + +static HRESULT WINAPI ID3DXMatrixStackImpl_TranslateLocal(ID3DXMatrixStack *iface, FLOAT x, FLOAT y, FLOAT z) +{ + D3DXMATRIX temp; + ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; + + TRACE("iface %p\n", iface); + + D3DXMatrixTranslation(&temp, x, y, z); + D3DXMatrixMultiply(&This->stack[This->current], &temp,&This->stack[This->current]); + + return D3D_OK; +} + +static const ID3DXMatrixStackVtbl ID3DXMatrixStack_Vtbl = +{ + ID3DXMatrixStackImpl_QueryInterface, + ID3DXMatrixStackImpl_AddRef, + ID3DXMatrixStackImpl_Release, + ID3DXMatrixStackImpl_Pop, + ID3DXMatrixStackImpl_Push, + ID3DXMatrixStackImpl_LoadIdentity, + ID3DXMatrixStackImpl_LoadMatrix, + ID3DXMatrixStackImpl_MultMatrix, + ID3DXMatrixStackImpl_MultMatrixLocal, + ID3DXMatrixStackImpl_RotateAxis, + ID3DXMatrixStackImpl_RotateAxisLocal, + ID3DXMatrixStackImpl_RotateYawPitchRoll, + ID3DXMatrixStackImpl_RotateYawPitchRollLocal, + ID3DXMatrixStackImpl_Scale, + ID3DXMatrixStackImpl_ScaleLocal, + ID3DXMatrixStackImpl_Translate, + ID3DXMatrixStackImpl_TranslateLocal, + ID3DXMatrixStackImpl_GetTop +}; + +/*_________________D3DXPLANE________________*/ + +D3DXPLANE* WINAPI D3DXPlaneFromPointNormal(D3DXPLANE *pout, CONST D3DXVECTOR3 *pvpoint, CONST D3DXVECTOR3 *pvnormal) +{ + pout->a = pvnormal->x; + pout->b = pvnormal->y; + pout->c = pvnormal->z; + pout->d = -D3DXVec3Dot(pvpoint, pvnormal); + return pout; +} + +D3DXPLANE* WINAPI D3DXPlaneFromPoints(D3DXPLANE *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2, CONST D3DXVECTOR3 *pv3) +{ + D3DXVECTOR3 edge1, edge2, normal, Nnormal; + + edge1.x = 0.0f; edge1.y = 0.0f; edge1.z = 0.0f; + edge2.x = 0.0f; edge2.y = 0.0f; edge2.z = 0.0f; + D3DXVec3Subtract(&edge1, pv2, pv1); + D3DXVec3Subtract(&edge2, pv3, pv1); + D3DXVec3Cross(&normal, &edge1, &edge2); + D3DXVec3Normalize(&Nnormal, &normal); + D3DXPlaneFromPointNormal(pout, pv1, &Nnormal); + return pout; +} + +D3DXVECTOR3* WINAPI D3DXPlaneIntersectLine(D3DXVECTOR3 *pout, CONST D3DXPLANE *pp, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2) +{ + D3DXVECTOR3 direction, normal; + FLOAT dot, temp; + + normal.x = pp->a; + normal.y = pp->b; + normal.z = pp->c; + direction.x = pv2->x - pv1->x; + direction.y = pv2->y - pv1->y; + direction.z = pv2->z - pv1->z; + dot = D3DXVec3Dot(&normal, &direction); + if ( !dot ) return NULL; + temp = ( pp->d + D3DXVec3Dot(&normal, pv1) ) / dot; + pout->x = pv1->x - temp * direction.x; + pout->y = pv1->y - temp * direction.y; + pout->z = pv1->z - temp * direction.z; + return pout; +} + +D3DXPLANE* WINAPI D3DXPlaneNormalize(D3DXPLANE *pout, CONST D3DXPLANE *pp) +{ + D3DXPLANE out; + FLOAT norm; + + norm = sqrt(pp->a * pp->a + pp->b * pp->b + pp->c * pp->c); + if ( norm ) + { + out.a = pp->a / norm; + out.b = pp->b / norm; + out.c = pp->c / norm; + out.d = pp->d / norm; + } + else + { + out.a = 0.0f; + out.b = 0.0f; + out.c = 0.0f; + out.d = 0.0f; + } + *pout = out; + return pout; +} + +D3DXPLANE* WINAPI D3DXPlaneTransform(D3DXPLANE *pout, CONST D3DXPLANE *pplane, CONST D3DXMATRIX *pm) +{ + CONST D3DXPLANE plane = *pplane; + pout->a = pm->u.m[0][0] * plane.a + pm->u.m[1][0] * plane.b + pm->u.m[2][0] * plane.c + pm->u.m[3][0] * plane.d; + pout->b = pm->u.m[0][1] * plane.a + pm->u.m[1][1] * plane.b + pm->u.m[2][1] * plane.c + pm->u.m[3][1] * plane.d; + pout->c = pm->u.m[0][2] * plane.a + pm->u.m[1][2] * plane.b + pm->u.m[2][2] * plane.c + pm->u.m[3][2] * plane.d; + pout->d = pm->u.m[0][3] * plane.a + pm->u.m[1][3] * plane.b + pm->u.m[2][3] * plane.c + pm->u.m[3][3] * plane.d; + return pout; +} + +/*_________________D3DXQUATERNION________________*/ + +D3DXQUATERNION* WINAPI D3DXQuaternionBaryCentric(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq1, CONST D3DXQUATERNION *pq2, CONST D3DXQUATERNION *pq3, FLOAT f, FLOAT g) +{ + D3DXQUATERNION temp1, temp2; + D3DXQuaternionSlerp(pout, D3DXQuaternionSlerp(&temp1, pq1, pq2, f + g), D3DXQuaternionSlerp(&temp2, pq1, pq3, f+g), g / (f + g)); + return pout; +} + +D3DXQUATERNION* WINAPI D3DXQuaternionExp(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq) +{ + FLOAT norm; + + norm = sqrt(pq->x * pq->x + pq->y * pq->y + pq->z * pq->z); + if (norm ) + { + pout->x = sin(norm) * pq->x / norm; + pout->y = sin(norm) * pq->y / norm; + pout->z = sin(norm) * pq->z / norm; + pout->w = cos(norm); + } + else + { + pout->x = 0.0f; + pout->y = 0.0f; + pout->z = 0.0f; + pout->w = 1.0f; + } + return pout; +} + +D3DXQUATERNION* WINAPI D3DXQuaternionInverse(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq) +{ + FLOAT norm; + + norm = D3DXQuaternionLengthSq(pq); + if ( !norm ) + { + pout->x = 0.0f; + pout->y = 0.0f; + pout->z = 0.0f; + pout->w = 0.0f; + } + else + { + pout->x = -pq->x / norm; + pout->y = -pq->y / norm; + pout->z = -pq->z / norm; + pout->w = pq->w / norm; + } + return pout; +} + +D3DXQUATERNION* WINAPI D3DXQuaternionLn(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq) +{ + FLOAT norm, normvec, theta; + + norm = D3DXQuaternionLengthSq(pq); + if ( norm > 1.0001f ) + { + pout->x = pq->x; + pout->y = pq->y; + pout->z = pq->z; + pout->w = 0.0f; + } + else if( norm > 0.99999f) + { + normvec = sqrt( pq->x * pq->x + pq->y * pq->y + pq->z * pq->z ); + theta = atan2(normvec, pq->w) / normvec; + pout->x = theta * pq->x; + pout->y = theta * pq->y; + pout->z = theta * pq->z; + pout->w = 0.0f; + } + else + { + FIXME("The quaternion (%f, %f, %f, %f) has a norm <1. This should not happen. Windows returns a result anyway. This case is not implemented yet.\n", pq->x, pq->y, pq->z, pq->w); + } + return pout; +} + +D3DXQUATERNION* WINAPI D3DXQuaternionMultiply(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq1, CONST D3DXQUATERNION *pq2) +{ + D3DXQUATERNION out; + out.x = pq2->w * pq1->x + pq2->x * pq1->w + pq2->y * pq1->z - pq2->z * pq1->y; + out.y = pq2->w * pq1->y - pq2->x * pq1->z + pq2->y * pq1->w + pq2->z * pq1->x; + out.z = pq2->w * pq1->z + pq2->x * pq1->y - pq2->y * pq1->x + pq2->z * pq1->w; + out.w = pq2->w * pq1->w - pq2->x * pq1->x - pq2->y * pq1->y - pq2->z * pq1->z; + *pout = out; + return pout; +} + +D3DXQUATERNION* WINAPI D3DXQuaternionNormalize(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq) +{ + D3DXQUATERNION out; + FLOAT norm; + + norm = D3DXQuaternionLength(pq); + if ( !norm ) + { + out.x = 0.0f; + out.y = 0.0f; + out.z = 0.0f; + out.w = 0.0f; + } + else + { + out.x = pq->x / norm; + out.y = pq->y / norm; + out.z = pq->z / norm; + out.w = pq->w / norm; + } + *pout=out; + return pout; +} + +D3DXQUATERNION* WINAPI D3DXQuaternionRotationAxis(D3DXQUATERNION *pout, CONST D3DXVECTOR3 *pv, FLOAT angle) +{ + D3DXVECTOR3 temp; + + D3DXVec3Normalize(&temp, pv); + pout->x = sin( angle / 2.0f ) * temp.x; + pout->y = sin( angle / 2.0f ) * temp.y; + pout->z = sin( angle / 2.0f ) * temp.z; + pout->w = cos( angle / 2.0f ); + return pout; +} + +D3DXQUATERNION* WINAPI D3DXQuaternionRotationMatrix(D3DXQUATERNION *pout, CONST D3DXMATRIX *pm) +{ + int i, maxi; + FLOAT maxdiag, S, trace; + + trace = pm->u.m[0][0] + pm->u.m[1][1] + pm->u.m[2][2] + 1.0f; + if ( trace > 1.0f) + { + pout->x = ( pm->u.m[1][2] - pm->u.m[2][1] ) / ( 2.0f * sqrt(trace) ); + pout->y = ( pm->u.m[2][0] - pm->u.m[0][2] ) / ( 2.0f * sqrt(trace) ); + pout->z = ( pm->u.m[0][1] - pm->u.m[1][0] ) / ( 2.0f * sqrt(trace) ); + pout->w = sqrt(trace) / 2.0f; + return pout; + } + maxi = 0; + maxdiag = pm->u.m[0][0]; + for (i=1; i<3; i++) + { + if ( pm->u.m[i][i] > maxdiag ) + { + maxi = i; + maxdiag = pm->u.m[i][i]; + } + } + switch( maxi ) + { + case 0: + S = 2.0f * sqrt(1.0f + pm->u.m[0][0] - pm->u.m[1][1] - pm->u.m[2][2]); + pout->x = 0.25f * S; + pout->y = ( pm->u.m[0][1] + pm->u.m[1][0] ) / S; + pout->z = ( pm->u.m[0][2] + pm->u.m[2][0] ) / S; + pout->w = ( pm->u.m[1][2] - pm->u.m[2][1] ) / S; + break; + case 1: + S = 2.0f * sqrt(1.0f + pm->u.m[1][1] - pm->u.m[0][0] - pm->u.m[2][2]); + pout->x = ( pm->u.m[0][1] + pm->u.m[1][0] ) / S; + pout->y = 0.25f * S; + pout->z = ( pm->u.m[1][2] + pm->u.m[2][1] ) / S; + pout->w = ( pm->u.m[2][0] - pm->u.m[0][2] ) / S; + break; + case 2: + S = 2.0f * sqrt(1.0f + pm->u.m[2][2] - pm->u.m[0][0] - pm->u.m[1][1]); + pout->x = ( pm->u.m[0][2] + pm->u.m[2][0] ) / S; + pout->y = ( pm->u.m[1][2] + pm->u.m[2][1] ) / S; + pout->z = 0.25f * S; + pout->w = ( pm->u.m[0][1] - pm->u.m[1][0] ) / S; + break; + } + return pout; +} + +D3DXQUATERNION* WINAPI D3DXQuaternionRotationYawPitchRoll(D3DXQUATERNION *pout, FLOAT yaw, FLOAT pitch, FLOAT roll) +{ + pout->x = sin( yaw / 2.0f) * cos(pitch / 2.0f) * sin(roll / 2.0f) + cos(yaw / 2.0f) * sin(pitch / 2.0f) * cos(roll / 2.0f); + pout->y = sin( yaw / 2.0f) * cos(pitch / 2.0f) * cos(roll / 2.0f) - cos(yaw / 2.0f) * sin(pitch / 2.0f) * sin(roll / 2.0f); + pout->z = cos(yaw / 2.0f) * cos(pitch / 2.0f) * sin(roll / 2.0f) - sin( yaw / 2.0f) * sin(pitch / 2.0f) * cos(roll / 2.0f); + pout->w = cos( yaw / 2.0f) * cos(pitch / 2.0f) * cos(roll / 2.0f) + sin(yaw / 2.0f) * sin(pitch / 2.0f) * sin(roll / 2.0f); + return pout; +} + +D3DXQUATERNION* WINAPI D3DXQuaternionSlerp(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq1, CONST D3DXQUATERNION *pq2, FLOAT t) +{ + FLOAT dot, epsilon, temp, theta, u; + + epsilon = 1.0f; + temp = 1.0f - t; + u = t; + dot = D3DXQuaternionDot(pq1, pq2); + if ( dot < 0.0f ) + { + epsilon = -1.0f; + dot = -dot; + } + if( 1.0f - dot > 0.001f ) + { + theta = acos(dot); + temp = sin(theta * temp) / sin(theta); + u = sin(theta * u) / sin(theta); + } + pout->x = temp * pq1->x + epsilon * u * pq2->x; + pout->y = temp * pq1->y + epsilon * u * pq2->y; + pout->z = temp * pq1->z + epsilon * u * pq2->z; + pout->w = temp * pq1->w + epsilon * u * pq2->w; + return pout; +} + +D3DXQUATERNION* WINAPI D3DXQuaternionSquad(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq1, CONST D3DXQUATERNION *pq2, CONST D3DXQUATERNION *pq3, CONST D3DXQUATERNION *pq4, FLOAT t) +{ + D3DXQUATERNION temp1, temp2; + + D3DXQuaternionSlerp(pout, D3DXQuaternionSlerp(&temp1, pq1, pq4, t), D3DXQuaternionSlerp(&temp2, pq2, pq3, t), 2.0f * t * (1.0f - t)); + return pout; +} + +void WINAPI D3DXQuaternionToAxisAngle(CONST D3DXQUATERNION *pq, D3DXVECTOR3 *paxis, FLOAT *pangle) +{ + FLOAT norm; + + *pangle = 0.0f; + norm = D3DXQuaternionLength(pq); + if ( norm ) + { + paxis->x = pq->x / norm; + paxis->y = pq->y / norm; + paxis->z = pq->z / norm; + if ( fabs( pq->w ) <= 1.0f ) *pangle = 2.0f * acos(pq->w); + } + else + { + paxis->x = 1.0f; + paxis->y = 0.0f; + paxis->z = 0.0f; + } +} + +/*_________________D3DXVec2_____________________*/ + +D3DXVECTOR2* WINAPI D3DXVec2BaryCentric(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pv2, CONST D3DXVECTOR2 *pv3, FLOAT f, FLOAT g) +{ + pout->x = (1.0f-f-g) * (pv1->x) + f * (pv2->x) + g * (pv3->x); + pout->y = (1.0f-f-g) * (pv1->y) + f * (pv2->y) + g * (pv3->y); + return pout; +} + +D3DXVECTOR2* WINAPI D3DXVec2CatmullRom(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv0, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pv2, CONST D3DXVECTOR2 *pv3, FLOAT s) +{ + pout->x = 0.5f * (2.0f * pv1->x + (pv2->x - pv0->x) *s + (2.0f *pv0->x - 5.0f * pv1->x + 4.0f * pv2->x - pv3->x) * s * s + (pv3->x -3.0f * pv2->x + 3.0f * pv1->x - pv0->x) * s * s * s); + pout->y = 0.5f * (2.0f * pv1->y + (pv2->y - pv0->y) *s + (2.0f *pv0->y - 5.0f * pv1->y + 4.0f * pv2->y - pv3->y) * s * s + (pv3->y -3.0f * pv2->y + 3.0f * pv1->y - pv0->y) * s * s * s); + return pout; +} + +D3DXVECTOR2* WINAPI D3DXVec2Hermite(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pt1, CONST D3DXVECTOR2 *pv2, CONST D3DXVECTOR2 *pt2, FLOAT s) +{ + FLOAT h1, h2, h3, h4; + + h1 = 2.0f * s * s * s - 3.0f * s * s + 1.0f; + h2 = s * s * s - 2.0f * s * s + s; + h3 = -2.0f * s * s * s + 3.0f * s * s; + h4 = s * s * s - s * s; + + pout->x = h1 * (pv1->x) + h2 * (pt1->x) + h3 * (pv2->x) + h4 * (pt2->x); + pout->y = h1 * (pv1->y) + h2 * (pt1->y) + h3 * (pv2->y) + h4 * (pt2->y); + return pout; +} + +D3DXVECTOR2* WINAPI D3DXVec2Normalize(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv) +{ + D3DXVECTOR2 out; + FLOAT norm; + + norm = D3DXVec2Length(pv); + if ( !norm ) + { + out.x = 0.0f; + out.y = 0.0f; + } + else + { + out.x = pv->x / norm; + out.y = pv->y / norm; + } + *pout=out; + return pout; +} + +D3DXVECTOR4* WINAPI D3DXVec2Transform(D3DXVECTOR4 *pout, CONST D3DXVECTOR2 *pv, CONST D3DXMATRIX *pm) +{ + pout->x = pm->u.m[0][0] * pv->x + pm->u.m[1][0] * pv->y + pm->u.m[3][0]; + pout->y = pm->u.m[0][1] * pv->x + pm->u.m[1][1] * pv->y + pm->u.m[3][1]; + pout->z = pm->u.m[0][2] * pv->x + pm->u.m[1][2] * pv->y + pm->u.m[3][2]; + pout->w = pm->u.m[0][3] * pv->x + pm->u.m[1][3] * pv->y + pm->u.m[3][3]; + return pout; +} + +D3DXVECTOR2* WINAPI D3DXVec2TransformCoord(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv, CONST D3DXMATRIX *pm) +{ + FLOAT norm; + + norm = pm->u.m[0][3] * pv->x + pm->u.m[1][3] * pv->y + pm->u.m[3][3]; + if ( norm ) + { + CONST D3DXVECTOR2 v = *pv; + pout->x = (pm->u.m[0][0] * v.x + pm->u.m[1][0] * v.y + pm->u.m[3][0]) / norm; + pout->y = (pm->u.m[0][1] * v.x + pm->u.m[1][1] * v.y + pm->u.m[3][1]) / norm; + } + else + { + pout->x = 0.0f; + pout->y = 0.0f; + } + return pout; +} + +D3DXVECTOR2* WINAPI D3DXVec2TransformNormal(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv, CONST D3DXMATRIX *pm) +{ + CONST D3DXVECTOR2 v = *pv; + pout->x = pm->u.m[0][0] * v.x + pm->u.m[1][0] * v.y; + pout->y = pm->u.m[0][1] * v.x + pm->u.m[1][1] * v.y; + return pout; +} + +/*_________________D3DXVec3_____________________*/ + +D3DXVECTOR3* WINAPI D3DXVec3BaryCentric(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2, CONST D3DXVECTOR3 *pv3, FLOAT f, FLOAT g) +{ + pout->x = (1.0f-f-g) * (pv1->x) + f * (pv2->x) + g * (pv3->x); + pout->y = (1.0f-f-g) * (pv1->y) + f * (pv2->y) + g * (pv3->y); + pout->z = (1.0f-f-g) * (pv1->z) + f * (pv2->z) + g * (pv3->z); + return pout; +} + +D3DXVECTOR3* WINAPI D3DXVec3CatmullRom( D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv0, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2, CONST D3DXVECTOR3 *pv3, FLOAT s) +{ + pout->x = 0.5f * (2.0f * pv1->x + (pv2->x - pv0->x) *s + (2.0f *pv0->x - 5.0f * pv1->x + 4.0f * pv2->x - pv3->x) * s * s + (pv3->x -3.0f * pv2->x + 3.0f * pv1->x - pv0->x) * s * s * s); + pout->y = 0.5f * (2.0f * pv1->y + (pv2->y - pv0->y) *s + (2.0f *pv0->y - 5.0f * pv1->y + 4.0f * pv2->y - pv3->y) * s * s + (pv3->y -3.0f * pv2->y + 3.0f * pv1->y - pv0->y) * s * s * s); + pout->z = 0.5f * (2.0f * pv1->z + (pv2->z - pv0->z) *s + (2.0f *pv0->z - 5.0f * pv1->z + 4.0f * pv2->z - pv3->z) * s * s + (pv3->z -3.0f * pv2->z + 3.0f * pv1->z - pv0->z) * s * s * s); + return pout; +} + +D3DXVECTOR3* WINAPI D3DXVec3Hermite(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pt1, CONST D3DXVECTOR3 *pv2, CONST D3DXVECTOR3 *pt2, FLOAT s) +{ + FLOAT h1, h2, h3, h4; + + h1 = 2.0f * s * s * s - 3.0f * s * s + 1.0f; + h2 = s * s * s - 2.0f * s * s + s; + h3 = -2.0f * s * s * s + 3.0f * s * s; + h4 = s * s * s - s * s; + + pout->x = h1 * (pv1->x) + h2 * (pt1->x) + h3 * (pv2->x) + h4 * (pt2->x); + pout->y = h1 * (pv1->y) + h2 * (pt1->y) + h3 * (pv2->y) + h4 * (pt2->y); + pout->z = h1 * (pv1->z) + h2 * (pt1->z) + h3 * (pv2->z) + h4 * (pt2->z); + return pout; +} + +D3DXVECTOR3* WINAPI D3DXVec3Normalize(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv) +{ + D3DXVECTOR3 out; + FLOAT norm; + + norm = D3DXVec3Length(pv); + if ( !norm ) + { + out.x = 0.0f; + out.y = 0.0f; + out.z = 0.0f; + } + else + { + out.x = pv->x / norm; + out.y = pv->y / norm; + out.z = pv->z / norm; + } + *pout = out; + return pout; +} + +D3DXVECTOR3* WINAPI D3DXVec3Project(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv, CONST D3DVIEWPORT8 *pviewport, CONST D3DXMATRIX *pprojection, CONST D3DXMATRIX *pview, CONST D3DXMATRIX *pworld) +{ + D3DXMATRIX m; + D3DXVECTOR3 out; + + D3DXMatrixMultiply(&m, pworld, pview); + D3DXMatrixMultiply(&m, &m, pprojection); + D3DXVec3TransformCoord(&out, pv, &m); + out.x = pviewport->X + ( 1.0f + out.x ) * pviewport->Width / 2.0f; + out.y = pviewport->Y + ( 1.0f - out.y ) * pviewport->Height / 2.0f; + out.z = pviewport->MinZ + out.z * ( pviewport->MaxZ - pviewport->MinZ ); + *pout = out; + return pout; +} + +D3DXVECTOR4* WINAPI D3DXVec3Transform(D3DXVECTOR4 *pout, CONST D3DXVECTOR3 *pv, CONST D3DXMATRIX *pm) +{ + pout->x = pm->u.m[0][0] * pv->x + pm->u.m[1][0] * pv->y + pm->u.m[2][0] * pv->z + pm->u.m[3][0]; + pout->y = pm->u.m[0][1] * pv->x + pm->u.m[1][1] * pv->y + pm->u.m[2][1] * pv->z + pm->u.m[3][1]; + pout->z = pm->u.m[0][2] * pv->x + pm->u.m[1][2] * pv->y + pm->u.m[2][2] * pv->z + pm->u.m[3][2]; + pout->w = pm->u.m[0][3] * pv->x + pm->u.m[1][3] * pv->y + pm->u.m[2][3] * pv->z + pm->u.m[3][3]; + return pout; +} + +D3DXVECTOR3* WINAPI D3DXVec3TransformCoord(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv, CONST D3DXMATRIX *pm) +{ + D3DXVECTOR3 out; + FLOAT norm; + + norm = pm->u.m[0][3] * pv->x + pm->u.m[1][3] * pv->y + pm->u.m[2][3] *pv->z + pm->u.m[3][3]; + + if ( norm ) + { + CONST D3DXVECTOR3 v = *pv; + out.x = (pm->u.m[0][0] * v.x + pm->u.m[1][0] * v.y + pm->u.m[2][0] * v.z + pm->u.m[3][0]) / norm; + out.y = (pm->u.m[0][1] * v.x + pm->u.m[1][1] * v.y + pm->u.m[2][1] * v.z + pm->u.m[3][1]) / norm; + out.z = (pm->u.m[0][2] * v.x + pm->u.m[1][2] * v.y + pm->u.m[2][2] * v.z + pm->u.m[3][2]) / norm; + } + else + { + out.x = 0.0f; + out.y = 0.0f; + out.z = 0.0f; + } + *pout = out; + return pout; +} + +D3DXVECTOR3* WINAPI D3DXVec3TransformNormal(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv, CONST D3DXMATRIX *pm) +{ + CONST D3DXVECTOR3 v = *pv; + pout->x = pm->u.m[0][0] * v.x + pm->u.m[1][0] * v.y + pm->u.m[2][0] * v.z; + pout->y = pm->u.m[0][1] * v.x + pm->u.m[1][1] * v.y + pm->u.m[2][1] * v.z; + pout->z = pm->u.m[0][2] * v.x + pm->u.m[1][2] * v.y + pm->u.m[2][2] * v.z; + return pout; + +} + +D3DXVECTOR3* WINAPI D3DXVec3Unproject(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv, CONST D3DVIEWPORT8 *pviewport, CONST D3DXMATRIX *pprojection, CONST D3DXMATRIX *pview, CONST D3DXMATRIX *pworld) +{ + D3DXMATRIX m; + D3DXVECTOR3 out; + + D3DXMatrixMultiply(&m, pworld, pview); + D3DXMatrixMultiply(&m, &m, pprojection); + D3DXMatrixInverse(&m, NULL, &m); + out.x = 2.0f * ( pv->x - pviewport->X ) / pviewport->Width - 1.0f; + out.y = 1.0f - 2.0f * ( pv->y - pviewport->Y ) / pviewport->Height; + out.z = ( pv->z - pviewport->MinZ) / ( pviewport->MaxZ - pviewport->MinZ ); + D3DXVec3TransformCoord(&out, &out, &m); + *pout = out; + return pout; +} + +/*_________________D3DXVec4_____________________*/ + +D3DXVECTOR4* WINAPI D3DXVec4BaryCentric(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2, CONST D3DXVECTOR4 *pv3, FLOAT f, FLOAT g) +{ + pout->x = (1.0f-f-g) * (pv1->x) + f * (pv2->x) + g * (pv3->x); + pout->y = (1.0f-f-g) * (pv1->y) + f * (pv2->y) + g * (pv3->y); + pout->z = (1.0f-f-g) * (pv1->z) + f * (pv2->z) + g * (pv3->z); + pout->w = (1.0f-f-g) * (pv1->w) + f * (pv2->w) + g * (pv3->w); + return pout; +} + +D3DXVECTOR4* WINAPI D3DXVec4CatmullRom(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv0, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2, CONST D3DXVECTOR4 *pv3, FLOAT s) +{ + pout->x = 0.5f * (2.0f * pv1->x + (pv2->x - pv0->x) *s + (2.0f *pv0->x - 5.0f * pv1->x + 4.0f * pv2->x - pv3->x) * s * s + (pv3->x -3.0f * pv2->x + 3.0f * pv1->x - pv0->x) * s * s * s); + pout->y = 0.5f * (2.0f * pv1->y + (pv2->y - pv0->y) *s + (2.0f *pv0->y - 5.0f * pv1->y + 4.0f * pv2->y - pv3->y) * s * s + (pv3->y -3.0f * pv2->y + 3.0f * pv1->y - pv0->y) * s * s * s); + pout->z = 0.5f * (2.0f * pv1->z + (pv2->z - pv0->z) *s + (2.0f *pv0->z - 5.0f * pv1->z + 4.0f * pv2->z - pv3->z) * s * s + (pv3->z -3.0f * pv2->z + 3.0f * pv1->z - pv0->z) * s * s * s); + pout->w = 0.5f * (2.0f * pv1->w + (pv2->w - pv0->w) *s + (2.0f *pv0->w - 5.0f * pv1->w + 4.0f * pv2->w - pv3->w) * s * s + (pv3->w -3.0f * pv2->w + 3.0f * pv1->w - pv0->w) * s * s * s); + return pout; +} + +D3DXVECTOR4* WINAPI D3DXVec4Cross(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2, CONST D3DXVECTOR4 *pv3) +{ + D3DXVECTOR4 out; + out.x = pv1->y * (pv2->z * pv3->w - pv3->z * pv2->w) - pv1->z * (pv2->y * pv3->w - pv3->y * pv2->w) + pv1->w * (pv2->y * pv3->z - pv2->z *pv3->y); + out.y = -(pv1->x * (pv2->z * pv3->w - pv3->z * pv2->w) - pv1->z * (pv2->x * pv3->w - pv3->x * pv2->w) + pv1->w * (pv2->x * pv3->z - pv3->x * pv2->z)); + out.z = pv1->x * (pv2->y * pv3->w - pv3->y * pv2->w) - pv1->y * (pv2->x *pv3->w - pv3->x * pv2->w) + pv1->w * (pv2->x * pv3->y - pv3->x * pv2->y); + out.w = -(pv1->x * (pv2->y * pv3->z - pv3->y * pv2->z) - pv1->y * (pv2->x * pv3->z - pv3->x *pv2->z) + pv1->z * (pv2->x * pv3->y - pv3->x * pv2->y)); + *pout = out; + return pout; +} + +D3DXVECTOR4* WINAPI D3DXVec4Hermite(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pt1, CONST D3DXVECTOR4 *pv2, CONST D3DXVECTOR4 *pt2, FLOAT s) +{ + FLOAT h1, h2, h3, h4; + + h1 = 2.0f * s * s * s - 3.0f * s * s + 1.0f; + h2 = s * s * s - 2.0f * s * s + s; + h3 = -2.0f * s * s * s + 3.0f * s * s; + h4 = s * s * s - s * s; + + pout->x = h1 * (pv1->x) + h2 * (pt1->x) + h3 * (pv2->x) + h4 * (pt2->x); + pout->y = h1 * (pv1->y) + h2 * (pt1->y) + h3 * (pv2->y) + h4 * (pt2->y); + pout->z = h1 * (pv1->z) + h2 * (pt1->z) + h3 * (pv2->z) + h4 * (pt2->z); + pout->w = h1 * (pv1->w) + h2 * (pt1->w) + h3 * (pv2->w) + h4 * (pt2->w); + return pout; +} + +D3DXVECTOR4* WINAPI D3DXVec4Normalize(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv) +{ + D3DXVECTOR4 out; + FLOAT norm; + + norm = D3DXVec4Length(pv); + if ( !norm ) + { + out.x = 0.0f; + out.y = 0.0f; + out.z = 0.0f; + out.w = 0.0f; + } + else + { + out.x = pv->x / norm; + out.y = pv->y / norm; + out.z = pv->z / norm; + out.w = pv->w / norm; + } + *pout = out; + return pout; +} + +D3DXVECTOR4* WINAPI D3DXVec4Transform(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv, CONST D3DXMATRIX *pm) +{ + D3DXVECTOR4 out; + out.x = pm->u.m[0][0] * pv->x + pm->u.m[1][0] * pv->y + pm->u.m[2][0] * pv->z + pm->u.m[3][0] * pv->w; + out.y = pm->u.m[0][1] * pv->x + pm->u.m[1][1] * pv->y + pm->u.m[2][1] * pv->z + pm->u.m[3][1] * pv->w; + out.z = pm->u.m[0][2] * pv->x + pm->u.m[1][2] * pv->y + pm->u.m[2][2] * pv->z + pm->u.m[3][2] * pv->w; + out.w = pm->u.m[0][3] * pv->x + pm->u.m[1][3] * pv->y + pm->u.m[2][3] * pv->z + pm->u.m[3][3] * pv->w; + *pout = out; + return pout; +} diff --git a/dlls/d3dx8/mesh.c b/dlls/d3dx8/mesh.c new file mode 100644 index 00000000000..b0562c7401e --- /dev/null +++ b/dlls/d3dx8/mesh.c @@ -0,0 +1,247 @@ +/* + * Copyright 2008 David Adam + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include + +#include "windef.h" +#include "winbase.h" +#include "wingdi.h" + +#include "d3dx8_private.h" + + +BOOL WINAPI D3DXBoxBoundProbe(CONST D3DXVECTOR3 *pmin, CONST D3DXVECTOR3 *pmax, CONST D3DXVECTOR3 *prayposition, CONST D3DXVECTOR3 *praydirection) + +/* Algorithm taken from the article: An Efficient and Robust Ray-Box Intersection Algoritm +Amy Williams University of Utah +Steve Barrus University of Utah +R. Keith Morley University of Utah +Peter Shirley University of Utah + +International Conference on Computer Graphics and Interactive Techniques archive +ACM SIGGRAPH 2005 Courses +Los Angeles, California + +This algorithm is free of patents or of copyrights, as confirmed by Peter Shirley himself. + +Algorithm: Consider the box as the intersection of three slabs. Clip the ray +against each slab, if there's anything left of the ray after we're +done we've got an intersection of the ray with the box. +*/ + +{ + FLOAT div, tmin, tmax, tymin, tymax, tzmin, tzmax; + + div = 1.0f / praydirection->x; + if ( div >= 0.0f ) + { + tmin = ( pmin->x - prayposition->x ) * div; + tmax = ( pmax->x - prayposition->x ) * div; + } + else + { + tmin = ( pmax->x - prayposition->x ) * div; + tmax = ( pmin->x - prayposition->x ) * div; + } + + if ( tmax < 0.0f ) return FALSE; + + div = 1.0f / praydirection->y; + if ( div >= 0.0f ) + { + tymin = ( pmin->y - prayposition->y ) * div; + tymax = ( pmax->y - prayposition->y ) * div; + } + else + { + tymin = ( pmax->y - prayposition->y ) * div; + tymax = ( pmin->y - prayposition->y ) * div; + } + + if ( ( tymax < 0.0f ) || ( tmin > tymax ) || ( tymin > tmax ) ) return FALSE; + + if ( tymin > tmin ) tmin = tymin; + if ( tymax < tmax ) tmax = tymax; + + div = 1.0f / praydirection->z; + if ( div >= 0.0f ) + { + tzmin = ( pmin->z - prayposition->z ) * div; + tzmax = ( pmax->z - prayposition->z ) * div; + } + else + { + tzmin = ( pmax->z - prayposition->z ) * div; + tzmax = ( pmin->z - prayposition->z ) * div; + } + + if ( (tzmax < 0.0f ) || ( tmin > tzmax ) || ( tzmin > tmax ) ) return FALSE; + + return TRUE; +} + +HRESULT WINAPI D3DXComputeBoundingBox(PVOID ppointsFVF, DWORD numvertices, DWORD FVF, D3DXVECTOR3 *pmin, D3DXVECTOR3 *pmax) +{ + D3DXVECTOR3 vec; + unsigned int i; + + if( !ppointsFVF || !pmin || !pmax ) return D3DERR_INVALIDCALL; + + *pmin = *(D3DXVECTOR3*)((char*)ppointsFVF); + *pmax = *pmin; + +/* It looks like that D3DXComputeBoundingBox does not take in account the last vertex. */ + for(i=0; ix ) pmin->x = vec.x; + if ( vec.x > pmax->x ) pmax->x = vec.x; + + if ( vec.y < pmin->y ) pmin->y = vec.y; + if ( vec.y > pmax->y ) pmax->y = vec.y; + + if ( vec.z < pmin->z ) pmin->z = vec.z; + if ( vec.z > pmax->z ) pmax->z = vec.z; + } + + return D3D_OK; +} + +HRESULT WINAPI D3DXComputeBoundingSphere(PVOID ppointsFVF, DWORD numvertices, DWORD FVF, D3DXVECTOR3 *pcenter, FLOAT *pradius) +{ + D3DXVECTOR3 temp, temp1; + FLOAT d; + unsigned int i; + + if( !ppointsFVF || !pcenter || !pradius ) return D3DERR_INVALIDCALL; + + temp.x = 0.0f; + temp.y = 0.0f; + temp.z = 0.0f; + temp1 = temp; + d = 0.0f; + *pradius = 0.0f; + + for(i=0; i *pradius ) *pradius = d; + } + return D3D_OK; +} + +static UINT Get_TexCoord_Size_From_FVF(DWORD FVF, int tex_num) +{ + return (((((FVF) >> (16 + (2 * (tex_num)))) + 1) & 0x03) + 1); +} + +UINT WINAPI D3DXGetFVFVertexSize(DWORD FVF) +{ + DWORD size = 0; + UINT i; + UINT numTextures = (FVF & D3DFVF_TEXCOUNT_MASK) >> D3DFVF_TEXCOUNT_SHIFT; + + if (FVF & D3DFVF_NORMAL) size += sizeof(D3DXVECTOR3); + if (FVF & D3DFVF_DIFFUSE) size += sizeof(DWORD); + if (FVF & D3DFVF_SPECULAR) size += sizeof(DWORD); + if (FVF & D3DFVF_PSIZE) size += sizeof(DWORD); + + switch (FVF & D3DFVF_POSITION_MASK) + { + case D3DFVF_XYZ: size += sizeof(D3DXVECTOR3); break; + case D3DFVF_XYZRHW: size += 4 * sizeof(FLOAT); break; + case D3DFVF_XYZB1: size += 4 * sizeof(FLOAT); break; + case D3DFVF_XYZB2: size += 5 * sizeof(FLOAT); break; + case D3DFVF_XYZB3: size += 6 * sizeof(FLOAT); break; + case D3DFVF_XYZB4: size += 7 * sizeof(FLOAT); break; + case D3DFVF_XYZB5: size += 8 * sizeof(FLOAT); break; + } + + for (i = 0; i < numTextures; i++) + { + size += Get_TexCoord_Size_From_FVF(FVF, i) * sizeof(FLOAT); + } + + return size; +} + +BOOL CDECL D3DXIntersectTri(CONST D3DXVECTOR3 *p0, CONST D3DXVECTOR3 *p1, CONST D3DXVECTOR3 *p2, CONST D3DXVECTOR3 *praypos, CONST D3DXVECTOR3 *praydir, FLOAT *pu, FLOAT *pv, FLOAT *pdist) +{ + D3DXMATRIX m; + D3DXVECTOR4 vec; + + m.m[0][0] = p1->x - p0->x; + m.m[1][0] = p2->x - p0->x; + m.m[2][0] = -praydir->x; + m.m[3][0] = 0.0f; + m.m[0][1] = p1->y - p0->z; + m.m[1][1] = p2->y - p0->z; + m.m[2][1] = -praydir->y; + m.m[3][1] = 0.0f; + m.m[0][2] = p1->z - p0->z; + m.m[1][2] = p2->z - p0->z; + m.m[2][2] = -praydir->z; + m.m[3][2] = 0.0f; + m.m[0][3] = 0.0f; + m.m[1][3] = 0.0f; + m.m[2][3] = 0.0f; + m.m[3][3] = 1.0f; + + vec.x = praypos->x - p0->x; + vec.y = praypos->y - p0->y; + vec.z = praypos->z - p0->z; + vec.w = 0.0f; + + if ( D3DXMatrixInverse(&m, NULL, &m) ) + { + D3DXVec4Transform(&vec, &vec, &m); + if ( (vec.x >= 0.0f) && (vec.y >= 0.0f) && (vec.x + vec.y <= 1.0f) && (vec.z >= 0.0f) ) + { + *pu = vec.x; + *pv = vec.y; + *pdist = fabs( vec.z ); + return TRUE; + } + } + +return FALSE; +} + +BOOL WINAPI D3DXSphereBoundProbe(CONST D3DXVECTOR3 *pcenter, FLOAT radius, CONST D3DXVECTOR3 *prayposition, CONST D3DXVECTOR3 *praydirection) +{ + D3DXVECTOR3 difference; + FLOAT a, b, c, d; + + a = D3DXVec3LengthSq(praydirection); + if (!D3DXVec3Subtract(&difference, prayposition, pcenter)) return FALSE; + b = D3DXVec3Dot(&difference, praydirection); + c = D3DXVec3LengthSq(&difference) - radius * radius; + d = b * b - a * c; + + if ( ( d <= 0.0f ) || ( sqrt(d) <= b ) ) return FALSE; + return TRUE; +} diff --git a/dlls/d3dx8/tests/Makefile.in b/dlls/d3dx8/tests/Makefile.in new file mode 100644 index 00000000000..8869d711d58 --- /dev/null +++ b/dlls/d3dx8/tests/Makefile.in @@ -0,0 +1,14 @@ +TOPSRCDIR = @top_srcdir@ +TOPOBJDIR = ../../.. +SRCDIR = @srcdir@ +VPATH = @srcdir@ +TESTDLL = d3dx8.dll +IMPORTS = d3dx8 kernel32 + +CTESTS = \ + math.c \ + mesh.c + +@MAKE_TEST_RULES@ + +@DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/d3dx8/tests/math.c b/dlls/d3dx8/tests/math.c new file mode 100644 index 00000000000..12236bc0a94 --- /dev/null +++ b/dlls/d3dx8/tests/math.c @@ -0,0 +1,1523 @@ +/* + * Copyright 2007 David Adam + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include +#include "d3dx8.h" + +#include "wine/test.h" + +#define admitted_error 0.0001f + +#define expect_color(expectedcolor,gotcolor) ok((fabs(expectedcolor.r-gotcolor.r) admitted_error) + return FALSE; + } + } + + return TRUE; +} + +#define expect_mat(expectedmat, gotmat) \ +do { \ + const D3DXMATRIX *__m1 = (expectedmat); \ + const D3DXMATRIX *__m2 = (gotmat); \ + ok(compare_matrix(__m1, __m2), "Expected matrix=\n(%f,%f,%f,%f\n %f,%f,%f,%f\n %f,%f,%f,%f\n %f,%f,%f,%f\n)\n\n" \ + "Got matrix=\n(%f,%f,%f,%f\n %f,%f,%f,%f\n %f,%f,%f,%f\n %f,%f,%f,%f)\n", \ + U(*__m1).m[0][0], U(*__m1).m[0][1], U(*__m1).m[0][2], U(*__m1).m[0][3], \ + U(*__m1).m[1][0], U(*__m1).m[1][1], U(*__m1).m[1][2], U(*__m1).m[1][3], \ + U(*__m1).m[2][0], U(*__m1).m[2][1], U(*__m1).m[2][2], U(*__m1).m[2][3], \ + U(*__m1).m[3][0], U(*__m1).m[3][1], U(*__m1).m[3][2], U(*__m1).m[3][3], \ + U(*__m2).m[0][0], U(*__m2).m[0][1], U(*__m2).m[0][2], U(*__m2).m[0][3], \ + U(*__m2).m[1][0], U(*__m2).m[1][1], U(*__m2).m[1][2], U(*__m2).m[1][3], \ + U(*__m2).m[2][0], U(*__m2).m[2][1], U(*__m2).m[2][2], U(*__m2).m[2][3], \ + U(*__m2).m[3][0], U(*__m2).m[3][1], U(*__m2).m[3][2], U(*__m2).m[3][3]); \ +} while(0) + +#define expect_plane(expectedplane,gotplane) ok((fabs(expectedplane.a-gotplane.a)0 */ + U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; + U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; + U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; + U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; + U(mat).m[0][0] = 10.0f; U(mat).m[1][1] = 20.0f; U(mat).m[2][2] = 30.0f; + U(mat).m[3][3] = 48.0f; + expectedquat.x = 2.368682f; expectedquat.y = 0.768221f; expectedquat.z = -0.384111f; expectedquat.w = 3.905125f; + D3DXQuaternionRotationMatrix(&gotquat,&mat); + expect_vec4(expectedquat,gotquat); + /* test the case when the greater element is (2,2) */ + U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; + U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; + U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; + U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; + U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = -60.0f; U(mat).m[2][2] = 40.0f; + U(mat).m[3][3] = 48.0f; + expectedquat.x = 1.233905f; expectedquat.y = -0.237290f; expectedquat.z = 5.267827f; expectedquat.w = -0.284747f; + D3DXQuaternionRotationMatrix(&gotquat,&mat); + expect_vec4(expectedquat,gotquat); + /* test the case when the greater element is (1,1) */ + U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; + U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; + U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; + U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; + U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 60.0f; U(mat).m[2][2] = -80.0f; + U(mat).m[3][3] = 48.0f; + expectedquat.x = 0.651031f; expectedquat.y = 6.144103f; expectedquat.z = -0.203447f; expectedquat.w = 0.488273f; + D3DXQuaternionRotationMatrix(&gotquat,&mat); + expect_vec4(expectedquat,gotquat); + /* test the case when the trace is near 0 in a matrix which is not a rotation */ + U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; + U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; + U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; + U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; + U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = -0.9f; + U(mat).m[3][3] = 48.0f; + expectedquat.x = 1.709495f; expectedquat.y = 2.339872f; expectedquat.z = -0.534217f; expectedquat.w = 1.282122f; + D3DXQuaternionRotationMatrix(&gotquat,&mat); + expect_vec4(expectedquat,gotquat); + /* test the case when the trace is 0.49 in a matrix which is not a rotation */ + U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; + U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; + U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; + U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; + U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = -0.51f; + U(mat).m[3][3] = 48.0f; + expectedquat.x = 1.724923f; expectedquat.y = 2.318944f; expectedquat.z = -0.539039f; expectedquat.w = 1.293692f; + D3DXQuaternionRotationMatrix(&gotquat,&mat); + expect_vec4(expectedquat,gotquat); + /* test the case when the trace is 0.51 in a matrix which is not a rotation */ + U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; + U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; + U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; + U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; + U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = -0.49f; + U(mat).m[3][3] = 48.0f; + expectedquat.x = 1.725726f; expectedquat.y = 2.317865f; expectedquat.z = -0.539289f; expectedquat.w = 1.294294f; + D3DXQuaternionRotationMatrix(&gotquat,&mat); + expect_vec4(expectedquat,gotquat); + /* test the case when the trace is 0.99 in a matrix which is not a rotation */ + U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; + U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; + U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; + U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; + U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = -0.01f; + U(mat).m[3][3] = 48.0f; + expectedquat.x = 1.745328f; expectedquat.y = 2.291833f; expectedquat.z = -0.545415f; expectedquat.w = 1.308996f; + D3DXQuaternionRotationMatrix(&gotquat,&mat); + expect_vec4(expectedquat,gotquat); + /* test the case when the trace is 1.0 in a matrix which is not a rotation */ + U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; + U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; + U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; + U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; + U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = 0.0f; + U(mat).m[3][3] = 48.0f; + expectedquat.x = 1.745743f; expectedquat.y = 2.291288f; expectedquat.z = -0.545545f; expectedquat.w = 1.309307f; + D3DXQuaternionRotationMatrix(&gotquat,&mat); + expect_vec4(expectedquat,gotquat); + /* test the case when the trace is 1.01 in a matrix which is not a rotation */ + U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; + U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; + U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; + U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; + U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = 0.01f; + U(mat).m[3][3] = 48.0f; + expectedquat.x = 18.408188f; expectedquat.y = 5.970223f; expectedquat.z = -2.985111f; expectedquat.w = 0.502494f; + D3DXQuaternionRotationMatrix(&gotquat,&mat); + expect_vec4(expectedquat,gotquat); + /* test the case when the trace is 1.5 in a matrix which is not a rotation */ + U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; + U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; + U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; + U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; + U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = 0.5f; + U(mat).m[3][3] = 48.0f; + expectedquat.x = 15.105186f; expectedquat.y = 4.898980f; expectedquat.z = -2.449490f; expectedquat.w = 0.612372f; + D3DXQuaternionRotationMatrix(&gotquat,&mat); + expect_vec4(expectedquat,gotquat); + /* test the case when the trace is 1.7 in a matrix which is not a rotation */ + U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; + U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; + U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; + U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; + U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = 0.70f; + U(mat).m[3][3] = 48.0f; + expectedquat.x = 14.188852f; expectedquat.y = 4.601790f; expectedquat.z = -2.300895f; expectedquat.w = 0.651920f; + D3DXQuaternionRotationMatrix(&gotquat,&mat); + expect_vec4(expectedquat,gotquat); + /* test the case when the trace is 1.99 in a matrix which is not a rotation */ + U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; + U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; + U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; + U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; + U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = 0.99f; + U(mat).m[3][3] = 48.0f; + expectedquat.x = 13.114303f; expectedquat.y = 4.253287f; expectedquat.z = -2.126644f; expectedquat.w = 0.705337f; + D3DXQuaternionRotationMatrix(&gotquat,&mat); + expect_vec4(expectedquat,gotquat); + /* test the case when the trace is 2.0 in a matrix which is not a rotation */ + U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; + U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; + U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; + U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; + U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = 2.0f; + U(mat).m[3][3] = 48.0f; + expectedquat.x = 10.680980f; expectedquat.y = 3.464102f; expectedquat.z = -1.732051f; expectedquat.w = 0.866025f; + D3DXQuaternionRotationMatrix(&gotquat,&mat); + expect_vec4(expectedquat,gotquat); + +/*_______________D3DXQuaternionRotationYawPitchRoll__________*/ + expectedquat.x = 0.303261f; expectedquat.y = 0.262299f; expectedquat.z = 0.410073f; expectedquat.w = 0.819190f; + D3DXQuaternionRotationYawPitchRoll(&gotquat,D3DX_PI/4.0f,D3DX_PI/11.0f,D3DX_PI/3.0f); + expect_vec4(expectedquat,gotquat); + +/*_______________D3DXQuaternionSlerp________________________*/ + expectedquat.x = -0.2f; expectedquat.y = 2.6f; expectedquat.z = 1.3f; expectedquat.w = 9.1f; + D3DXQuaternionSlerp(&gotquat,&q,&r,scale); + expect_vec4(expectedquat,gotquat); + expectedquat.x = 334.0f; expectedquat.y = -31.9f; expectedquat.z = 6.1f; expectedquat.w = 6.7f; + D3DXQuaternionSlerp(&gotquat,&q,&t,scale); + expect_vec4(expectedquat,gotquat); + expectedquat.x = 0.239485f; expectedquat.y = 0.346580f; expectedquat.z = 0.453676f; expectedquat.w = 0.560772f; + D3DXQuaternionSlerp(&gotquat,&smallq,&smallr,scale); + expect_vec4(expectedquat,gotquat); + +/*_______________D3DXQuaternionSquad________________________*/ + expectedquat.x = -156.296f; expectedquat.y = 30.242f; expectedquat.z = -2.5022f; expectedquat.w = 7.3576f; + D3DXQuaternionSquad(&gotquat,&q,&r,&t,&u,scale); + expect_vec4(expectedquat,gotquat); + +/*_______________D3DXQuaternionToAxisAngle__________________*/ + Nq.x = 1.0f/22.0f; Nq.y = 2.0f/22.0f; Nq.z = 4.0f/22.0f; Nq.w = 10.0f/22.0f; + expectedvec.x = 1.0f/11.0f; expectedvec.y = 2.0f/11.0f; expectedvec.z = 4.0f/11.0f; + expected = 2.197869f; + D3DXQuaternionToAxisAngle(&Nq,&axis,&angle); + expect_vec3(expectedvec,axis); + ok(fabs( angle - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, angle); + /* Test if |w|>1.0f */ + expectedvec.x = 1.0f/11.0f; expectedvec.y = 2.0f/11.0f; expectedvec.z = 4.0f/11.0f; + expected = 0.0f; + D3DXQuaternionToAxisAngle(&q,&axis,&angle); + expect_vec3(expectedvec,axis); + ok(fabs( angle - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, angle); + /* Test the null quaternion */ + expectedvec.x = 1.0f; expectedvec.y = 0.0f; expectedvec.z = 0.0f; + expected = 0.0f; + D3DXQuaternionToAxisAngle(&nul,&axis,&angle); + expect_vec3(expectedvec,axis); + ok(fabs( angle - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, angle); +} + +static void D3X8Vector2Test(void) +{ + D3DXVECTOR2 expectedvec, gotvec, nul, nulproj, u, v, w, x; + LPD3DXVECTOR2 funcpointer; + D3DXVECTOR4 expectedtrans, gottrans; + D3DXMATRIX mat; + FLOAT coeff1, coeff2, expected, got, scale; + + nul.x = 0.0f; nul.y = 0.0f; + u.x = 3.0f; u.y = 4.0f; + v.x = -7.0f; v.y = 9.0f; + w.x = 4.0f; w.y = -3.0f; + x.x = 2.0f; x.y = -11.0f; + + U(mat).m[0][0] = 1.0f; U(mat).m[0][1] = 2.0f; U(mat).m[0][2] = 3.0f; U(mat).m[0][3] = 4.0f; + U(mat).m[1][0] = 5.0f; U(mat).m[1][1] = 6.0f; U(mat).m[1][2] = 7.0f; U(mat).m[1][3] = 8.0f; + U(mat).m[2][0] = 9.0f; U(mat).m[2][1] = 10.0f; U(mat).m[2][2] = 11.0f; U(mat).m[2][3] = 12.0f; + U(mat).m[3][0] = 13.0f; U(mat).m[3][1] = 14.0f; U(mat).m[3][2] = 15.0f; U(mat).m[3][3] = 16.0f; + + coeff1 = 2.0f; coeff2 = 5.0f; + scale = -6.5f; + +/*_______________D3DXVec2Add__________________________*/ + expectedvec.x = -4.0f; expectedvec.y = 13.0f; + D3DXVec2Add(&gotvec,&u,&v); + expect_vec(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec2Add(&gotvec,NULL,&v); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec2Add(NULL,NULL,NULL); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec2BaryCentric___________________*/ + expectedvec.x = -12.0f; expectedvec.y = -21.0f; + D3DXVec2BaryCentric(&gotvec,&u,&v,&w,coeff1,coeff2); + expect_vec(expectedvec,gotvec); + +/*_______________D3DXVec2CatmullRom____________________*/ + expectedvec.x = 5820.25f; expectedvec.y = -3654.5625f; + D3DXVec2CatmullRom(&gotvec,&u,&v,&w,&x,scale); + expect_vec(expectedvec,gotvec); + +/*_______________D3DXVec2CCW__________________________*/ + expected = 55.0f; + got = D3DXVec2CCW(&u,&v); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + /* Tests the case NULL */ + expected=0.0f; + got = D3DXVec2CCW(NULL,&v); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + expected=0.0f; + got = D3DXVec2CCW(NULL,NULL); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + +/*_______________D3DXVec2Dot__________________________*/ + expected = 15.0f; + got = D3DXVec2Dot(&u,&v); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + /* Tests the case NULL */ + expected=0.0f; + got = D3DXVec2Dot(NULL,&v); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + expected=0.0f; + got = D3DXVec2Dot(NULL,NULL); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + +/*_______________D3DXVec2Hermite__________________________*/ + expectedvec.x = 2604.625f; expectedvec.y = -4533.0f; + D3DXVec2Hermite(&gotvec,&u,&v,&w,&x,scale); + expect_vec(expectedvec,gotvec); + +/*_______________D3DXVec2Length__________________________*/ + expected = 5.0f; + got = D3DXVec2Length(&u); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + /* Tests the case NULL */ + expected=0.0f; + got = D3DXVec2Length(NULL); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + +/*_______________D3DXVec2LengthSq________________________*/ + expected = 25.0f; + got = D3DXVec2LengthSq(&u); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + /* Tests the case NULL */ + expected=0.0f; + got = D3DXVec2LengthSq(NULL); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + +/*_______________D3DXVec2Lerp__________________________*/ + expectedvec.x = 68.0f; expectedvec.y = -28.5f; + D3DXVec2Lerp(&gotvec,&u,&v,scale); + expect_vec(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec2Lerp(&gotvec,NULL,&v,scale); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec2Lerp(NULL,NULL,NULL,scale); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec2Maximize__________________________*/ + expectedvec.x = 3.0f; expectedvec.y = 9.0f; + D3DXVec2Maximize(&gotvec,&u,&v); + expect_vec(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec2Maximize(&gotvec,NULL,&v); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec2Maximize(NULL,NULL,NULL); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec2Minimize__________________________*/ + expectedvec.x = -7.0f; expectedvec.y = 4.0f; + D3DXVec2Minimize(&gotvec,&u,&v); + expect_vec(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec2Minimize(&gotvec,NULL,&v); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec2Minimize(NULL,NULL,NULL); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec2Normalize_________________________*/ + expectedvec.x = 0.6f; expectedvec.y = 0.8f; + D3DXVec2Normalize(&gotvec,&u); + expect_vec(expectedvec,gotvec); + /* Test the nul vector */ + expectedvec.x = 0.0f; expectedvec.y = 0.0f; + D3DXVec2Normalize(&gotvec,&nul); + expect_vec(expectedvec,gotvec); + +/*_______________D3DXVec2Scale____________________________*/ + expectedvec.x = -19.5f; expectedvec.y = -26.0f; + D3DXVec2Scale(&gotvec,&u,scale); + expect_vec(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec2Scale(&gotvec,NULL,scale); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec2Scale(NULL,NULL,scale); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec2Subtract__________________________*/ + expectedvec.x = 10.0f; expectedvec.y = -5.0f; + D3DXVec2Subtract(&gotvec,&u,&v); + expect_vec(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec2Subtract(&gotvec,NULL,&v); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec2Subtract(NULL,NULL,NULL); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec2Transform_______________________*/ + expectedtrans.x = 36.0f; expectedtrans.y = 44.0f; expectedtrans.z = 52.0f; expectedtrans.w = 60.0f; + D3DXVec2Transform(&gottrans,&u,&mat); + expect_vec4(expectedtrans,gottrans); + +/*_______________D3DXVec2TransformCoord_______________________*/ + expectedvec.x = 0.6f; expectedvec.y = 11.0f/15.0f; + D3DXVec2TransformCoord(&gotvec,&u,&mat); + expect_vec(expectedvec,gotvec); + /* Test the nul projected vector */ + nulproj.x = -2.0f; nulproj.y = -1.0f; + expectedvec.x = 0.0f; expectedvec.y = 0.0f; + D3DXVec2TransformCoord(&gotvec,&nulproj,&mat); + expect_vec(expectedvec,gotvec); + + /*_______________D3DXVec2TransformNormal______________________*/ + expectedvec.x = 23.0f; expectedvec.y = 30.0f; + D3DXVec2TransformNormal(&gotvec,&u,&mat); + expect_vec(expectedvec,gotvec); +} + +static void D3X8Vector3Test(void) +{ + D3DVIEWPORT8 viewport; + D3DXVECTOR3 expectedvec, gotvec, nul, nulproj, u, v, w, x; + LPD3DXVECTOR3 funcpointer; + D3DXVECTOR4 expectedtrans, gottrans; + D3DXMATRIX mat, projection, view, world; + FLOAT coeff1, coeff2, expected, got, scale; + + nul.x = 0.0f; nul.y = 0.0f; nul.z = 0.0f; + u.x = 9.0f; u.y = 6.0f; u.z = 2.0f; + v.x = 2.0f; v.y = -3.0f; v.z = -4.0; + w.x = 3.0f; w.y = -5.0f; w.z = 7.0f; + x.x = 4.0f; x.y = 1.0f; x.z = 11.0f; + + viewport.Width = 800; viewport.MinZ = 0.2f; viewport.X = 10; + viewport.Height = 680; viewport.MaxZ = 0.9f; viewport.Y = 5; + + U(mat).m[0][0] = 1.0f; U(mat).m[0][1] = 2.0f; U(mat).m[0][2] = 3.0f; U(mat).m[0][3] = 4.0f; + U(mat).m[1][0] = 5.0f; U(mat).m[1][1] = 6.0f; U(mat).m[1][2] = 7.0f; U(mat).m[1][3] = 8.0f; + U(mat).m[2][0] = 9.0f; U(mat).m[2][1] = 10.0f; U(mat).m[2][2] = 11.0f; U(mat).m[2][3] = 12.0f; + U(mat).m[3][0] = 13.0f; U(mat).m[3][1] = 14.0f; U(mat).m[3][2] = 15.0f; U(mat).m[3][3] = 16.0f; + + U(view).m[0][1] = 5.0f; U(view).m[0][2] = 7.0f; U(view).m[0][3] = 8.0f; + U(view).m[1][0] = 11.0f; U(view).m[1][2] = 16.0f; U(view).m[1][3] = 33.0f; + U(view).m[2][0] = 19.0f; U(view).m[2][1] = -21.0f; U(view).m[2][3] = 43.0f; + U(view).m[3][0] = 2.0f; U(view).m[3][1] = 3.0f; U(view).m[3][2] = -4.0f; + U(view).m[0][0] = 10.0f; U(view).m[1][1] = 20.0f; U(view).m[2][2] = 30.0f; + U(view).m[3][3] = -40.0f; + + U(world).m[0][0] = 21.0f; U(world).m[0][1] = 2.0f; U(world).m[0][2] = 3.0f; U(world).m[0][3] = 4.0; + U(world).m[1][0] = 5.0f; U(world).m[1][1] = 23.0f; U(world).m[1][2] = 7.0f; U(world).m[1][3] = 8.0f; + U(world).m[2][0] = -8.0f; U(world).m[2][1] = -7.0f; U(world).m[2][2] = 25.0f; U(world).m[2][3] = -5.0f; + U(world).m[3][0] = -4.0f; U(world).m[3][1] = -3.0f; U(world).m[3][2] = -2.0f; U(world).m[3][3] = 27.0f; + + coeff1 = 2.0f; coeff2 = 5.0f; + scale = -6.5f; + +/*_______________D3DXVec3Add__________________________*/ + expectedvec.x = 11.0f; expectedvec.y = 3.0f; expectedvec.z = -2.0f; + D3DXVec3Add(&gotvec,&u,&v); + expect_vec3(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec3Add(&gotvec,NULL,&v); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec3Add(NULL,NULL,NULL); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec3BaryCentric___________________*/ + expectedvec.x = -35.0f; expectedvec.y = -67.0; expectedvec.z = 15.0f; + D3DXVec3BaryCentric(&gotvec,&u,&v,&w,coeff1,coeff2); + + expect_vec3(expectedvec,gotvec); + +/*_______________D3DXVec3CatmullRom____________________*/ + expectedvec.x = 1458.0f; expectedvec.y = 22.1875f; expectedvec.z = 4141.375f; + D3DXVec3CatmullRom(&gotvec,&u,&v,&w,&x,scale); + expect_vec3(expectedvec,gotvec); + +/*_______________D3DXVec3Cross________________________*/ + expectedvec.x = -18.0f; expectedvec.y = 40.0f; expectedvec.z = -39.0f; + D3DXVec3Cross(&gotvec,&u,&v); + expect_vec3(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec3Cross(&gotvec,NULL,&v); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec3Cross(NULL,NULL,NULL); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec3Dot__________________________*/ + expected = -8.0f; + got = D3DXVec3Dot(&u,&v); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + /* Tests the case NULL */ + expected=0.0f; + got = D3DXVec3Dot(NULL,&v); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + expected=0.0f; + got = D3DXVec3Dot(NULL,NULL); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + +/*_______________D3DXVec3Hermite__________________________*/ + expectedvec.x = -6045.75f; expectedvec.y = -6650.0f; expectedvec.z = 1358.875f; + D3DXVec3Hermite(&gotvec,&u,&v,&w,&x,scale); + expect_vec3(expectedvec,gotvec); + +/*_______________D3DXVec3Length__________________________*/ + expected = 11.0f; + got = D3DXVec3Length(&u); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + /* Tests the case NULL */ + expected=0.0f; + got = D3DXVec3Length(NULL); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + +/*_______________D3DXVec3LengthSq________________________*/ + expected = 121.0f; + got = D3DXVec3LengthSq(&u); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + /* Tests the case NULL */ + expected=0.0f; + got = D3DXVec3LengthSq(NULL); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + +/*_______________D3DXVec3Lerp__________________________*/ + expectedvec.x = 54.5f; expectedvec.y = 64.5f, expectedvec.z = 41.0f ; + D3DXVec3Lerp(&gotvec,&u,&v,scale); + expect_vec3(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec3Lerp(&gotvec,NULL,&v,scale); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec3Lerp(NULL,NULL,NULL,scale); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec3Maximize__________________________*/ + expectedvec.x = 9.0f; expectedvec.y = 6.0f; expectedvec.z = 2.0f; + D3DXVec3Maximize(&gotvec,&u,&v); + expect_vec3(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec3Maximize(&gotvec,NULL,&v); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec3Maximize(NULL,NULL,NULL); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec3Minimize__________________________*/ + expectedvec.x = 2.0f; expectedvec.y = -3.0f; expectedvec.z = -4.0f; + D3DXVec3Minimize(&gotvec,&u,&v); + expect_vec3(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec3Minimize(&gotvec,NULL,&v); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec3Minimize(NULL,NULL,NULL); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec3Normalize_________________________*/ + expectedvec.x = 9.0f/11.0f; expectedvec.y = 6.0f/11.0f; expectedvec.z = 2.0f/11.0f; + D3DXVec3Normalize(&gotvec,&u); + expect_vec3(expectedvec,gotvec); + /* Test the nul vector */ + expectedvec.x = 0.0f; expectedvec.y = 0.0f; expectedvec.z = 0.0f; + D3DXVec3Normalize(&gotvec,&nul); + expect_vec3(expectedvec,gotvec); + +/*_______________D3DXVec3Project_________________________*/ + expectedvec.x = 1135.721924f; expectedvec.y = 147.086914f; expectedvec.z = 0.153412f; + D3DXMatrixPerspectiveFovLH(&projection,D3DX_PI/4.0f,20.0f/17.0f,1.0f,1000.0f); + D3DXVec3Project(&gotvec,&u,&viewport,&projection,&view,&world); + expect_vec3(expectedvec,gotvec); + +/*_______________D3DXVec3Scale____________________________*/ + expectedvec.x = -58.5f; expectedvec.y = -39.0f; expectedvec.z = -13.0f; + D3DXVec3Scale(&gotvec,&u,scale); + expect_vec3(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec3Scale(&gotvec,NULL,scale); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec3Scale(NULL,NULL,scale); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec3Subtract_______________________*/ + expectedvec.x = 7.0f; expectedvec.y = 9.0f; expectedvec.z = 6.0f; + D3DXVec3Subtract(&gotvec,&u,&v); + expect_vec3(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec3Subtract(&gotvec,NULL,&v); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec3Subtract(NULL,NULL,NULL); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec3Transform_______________________*/ + expectedtrans.x = 70.0f; expectedtrans.y = 88.0f; expectedtrans.z = 106.0f; expectedtrans.w = 124.0f; + D3DXVec3Transform(&gottrans,&u,&mat); + expect_vec4(expectedtrans,gottrans); + +/*_______________D3DXVec3TransformCoord_______________________*/ + expectedvec.x = 70.0f/124.0f; expectedvec.y = 88.0f/124.0f; expectedvec.z = 106.0f/124.0f; + D3DXVec3TransformCoord(&gotvec,&u,&mat); + expect_vec3(expectedvec,gotvec); + /* Test the nul projected vector */ + nulproj.x = 1.0f; nulproj.y = -1.0f, nulproj.z = -1.0f; + expectedvec.x = 0.0f; expectedvec.y = 0.0f; expectedvec.z = 0.0f; + D3DXVec3TransformCoord(&gotvec,&nulproj,&mat); + expect_vec3(expectedvec,gotvec); + +/*_______________D3DXVec3TransformNormal______________________*/ + expectedvec.x = 57.0f; expectedvec.y = 74.0f; expectedvec.z = 91.0f; + D3DXVec3TransformNormal(&gotvec,&u,&mat); + expect_vec3(expectedvec,gotvec); + +/*_______________D3DXVec3Unproject_________________________*/ + expectedvec.x = -2.913411f; expectedvec.y = 1.593215f; expectedvec.z = 0.380724f; + D3DXMatrixPerspectiveFovLH(&projection,D3DX_PI/4.0f,20.0f/17.0f,1.0f,1000.0f); + D3DXVec3Unproject(&gotvec,&u,&viewport,&projection,&view,&world); + expect_vec3(expectedvec,gotvec); +} + +static void D3X8Vector4Test(void) +{ + D3DXVECTOR4 expectedvec, gotvec, nul, u, v, w, x; + LPD3DXVECTOR4 funcpointer; + D3DXVECTOR4 expectedtrans, gottrans; + D3DXMATRIX mat; + FLOAT coeff1, coeff2, expected, got, scale; + + nul.x = 0.0f; nul.y = 0.0f; nul.z = 0.0f; nul.w = 0.0f; + u.x = 1.0f; u.y = 2.0f; u.z = 4.0f; u.w = 10.0; + v.x = -3.0f; v.y = 4.0f; v.z = -5.0f; v.w = 7.0; + w.x = 4.0f; w.y =6.0f; w.z = -2.0f; w.w = 1.0f; + x.x = 6.0f; x.y = -7.0f; x.z =8.0f; x.w = -9.0f; + + U(mat).m[0][0] = 1.0f; U(mat).m[0][1] = 2.0f; U(mat).m[0][2] = 3.0f; U(mat).m[0][3] = 4.0f; + U(mat).m[1][0] = 5.0f; U(mat).m[1][1] = 6.0f; U(mat).m[1][2] = 7.0f; U(mat).m[1][3] = 8.0f; + U(mat).m[2][0] = 9.0f; U(mat).m[2][1] = 10.0f; U(mat).m[2][2] = 11.0f; U(mat).m[2][3] = 12.0f; + U(mat).m[3][0] = 13.0f; U(mat).m[3][1] = 14.0f; U(mat).m[3][2] = 15.0f; U(mat).m[3][3] = 16.0f; + + coeff1 = 2.0f; coeff2 = 5.0; + scale = -6.5f; + +/*_______________D3DXVec4Add__________________________*/ + expectedvec.x = -2.0f; expectedvec.y = 6.0f; expectedvec.z = -1.0f; expectedvec.w = 17.0f; + D3DXVec4Add(&gotvec,&u,&v); + expect_vec4(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec4Add(&gotvec,NULL,&v); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec4Add(NULL,NULL,NULL); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec4BaryCentric____________________*/ + expectedvec.x = 8.0f; expectedvec.y = 26.0; expectedvec.z = -44.0f; expectedvec.w = -41.0f; + D3DXVec4BaryCentric(&gotvec,&u,&v,&w,coeff1,coeff2); + expect_vec4(expectedvec,gotvec); + +/*_______________D3DXVec4CatmullRom____________________*/ + expectedvec.x = 2754.625f; expectedvec.y = 2367.5625f; expectedvec.z = 1060.1875f; expectedvec.w = 131.3125f; + D3DXVec4CatmullRom(&gotvec,&u,&v,&w,&x,scale); + expect_vec4(expectedvec,gotvec); + +/*_______________D3DXVec4Cross_________________________*/ + expectedvec.x = 390.0f; expectedvec.y = -393.0f; expectedvec.z = -316.0f; expectedvec.w = 166.0f; + D3DXVec4Cross(&gotvec,&u,&v,&w); + expect_vec4(expectedvec,gotvec); + +/*_______________D3DXVec4Dot__________________________*/ + expected = 55.0f; + got = D3DXVec4Dot(&u,&v); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + /* Tests the case NULL */ + expected=0.0f; + got = D3DXVec4Dot(NULL,&v); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + expected=0.0f; + got = D3DXVec4Dot(NULL,NULL); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + +/*_______________D3DXVec4Hermite_________________________*/ + expectedvec.x = 1224.625f; expectedvec.y = 3461.625f; expectedvec.z = -4758.875f; expectedvec.w = -5781.5f; + D3DXVec4Hermite(&gotvec,&u,&v,&w,&x,scale); + expect_vec4(expectedvec,gotvec); + +/*_______________D3DXVec4Length__________________________*/ + expected = 11.0f; + got = D3DXVec4Length(&u); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + /* Tests the case NULL */ + expected=0.0f; + got = D3DXVec4Length(NULL); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + +/*_______________D3DXVec4LengthSq________________________*/ + expected = 121.0f; + got = D3DXVec4LengthSq(&u); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + /* Tests the case NULL */ + expected=0.0f; + got = D3DXVec4LengthSq(NULL); + ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); + +/*_______________D3DXVec4Lerp__________________________*/ + expectedvec.x = 27.0f; expectedvec.y = -11.0f; expectedvec.z = 62.5; expectedvec.w = 29.5; + D3DXVec4Lerp(&gotvec,&u,&v,scale); + expect_vec4(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec4Lerp(&gotvec,NULL,&v,scale); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec4Lerp(NULL,NULL,NULL,scale); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec4Maximize__________________________*/ + expectedvec.x = 1.0f; expectedvec.y = 4.0f; expectedvec.z = 4.0f; expectedvec.w = 10.0; + D3DXVec4Maximize(&gotvec,&u,&v); + expect_vec4(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec4Maximize(&gotvec,NULL,&v); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec4Maximize(NULL,NULL,NULL); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec4Minimize__________________________*/ + expectedvec.x = -3.0f; expectedvec.y = 2.0f; expectedvec.z = -5.0f; expectedvec.w = 7.0; + D3DXVec4Minimize(&gotvec,&u,&v); + expect_vec4(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec4Minimize(&gotvec,NULL,&v); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec4Minimize(NULL,NULL,NULL); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec4Normalize_________________________*/ + expectedvec.x = 1.0f/11.0f; expectedvec.y = 2.0f/11.0f; expectedvec.z = 4.0f/11.0f; expectedvec.w = 10.0f/11.0f; + D3DXVec4Normalize(&gotvec,&u); + expect_vec4(expectedvec,gotvec); + /* Test the nul vector */ + expectedvec.x = 0.0f; expectedvec.y = 0.0f; expectedvec.z = 0.0f; expectedvec.w = 0.0f; + D3DXVec4Normalize(&gotvec,&nul); + expect_vec4(expectedvec,gotvec); + +/*_______________D3DXVec4Scale____________________________*/ + expectedvec.x = -6.5f; expectedvec.y = -13.0f; expectedvec.z = -26.0f; expectedvec.w = -65.0f; + D3DXVec4Scale(&gotvec,&u,scale); + expect_vec4(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec4Scale(&gotvec,NULL,scale); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec4Scale(NULL,NULL,scale); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec4Subtract__________________________*/ + expectedvec.x = 4.0f; expectedvec.y = -2.0f; expectedvec.z = 9.0f; expectedvec.w = 3.0f; + D3DXVec4Subtract(&gotvec,&u,&v); + expect_vec4(expectedvec,gotvec); + /* Tests the case NULL */ + funcpointer = D3DXVec4Subtract(&gotvec,NULL,&v); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + funcpointer = D3DXVec4Subtract(NULL,NULL,NULL); + ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); + +/*_______________D3DXVec4Transform_______________________*/ + expectedtrans.x = 177.0f; expectedtrans.y = 194.0f; expectedtrans.z = 211.0f; expectedtrans.w = 228.0f; + D3DXVec4Transform(&gottrans,&u,&mat); + expect_vec4(expectedtrans,gottrans); +} + +static void test_matrix_stack(void) +{ + ID3DXMatrixStack *stack; + ULONG refcount; + HRESULT hr; + + const D3DXMATRIX mat1 = {{{ + 1.0f, 2.0f, 3.0f, 4.0f, + 5.0f, 6.0f, 7.0f, 8.0f, + 9.0f, 10.0f, 11.0f, 12.0f, + 13.0f, 14.0f, 15.0f, 16.0f + }}}; + + const D3DXMATRIX mat2 = {{{ + 17.0f, 18.0f, 19.0f, 20.0f, + 21.0f, 22.0f, 23.0f, 24.0f, + 25.0f, 26.0f, 27.0f, 28.0f, + 29.0f, 30.0f, 31.0f, 32.0f + }}}; + + hr = D3DXCreateMatrixStack(0, &stack); + ok(SUCCEEDED(hr), "Failed to create a matrix stack, hr %#x\n", hr); + if (FAILED(hr)) return; + + ok(D3DXMatrixIsIdentity(ID3DXMatrixStack_GetTop(stack)), + "The top of an empty matrix stack should be an identity matrix\n"); + + hr = ID3DXMatrixStack_Pop(stack); + ok(SUCCEEDED(hr), "Pop failed, hr %#x\n", hr); + + hr = ID3DXMatrixStack_Push(stack); + ok(SUCCEEDED(hr), "Push failed, hr %#x\n", hr); + ok(D3DXMatrixIsIdentity(ID3DXMatrixStack_GetTop(stack)), "The top should be an identity matrix\n"); + + hr = ID3DXMatrixStack_Push(stack); + ok(SUCCEEDED(hr), "Push failed, hr %#x\n", hr); + + hr = ID3DXMatrixStack_LoadMatrix(stack, NULL); + ok(hr == D3DERR_INVALIDCALL, "LoadMatrix returned %#x, expected D3DERR_INVALIDCALL\n", hr); + + hr = ID3DXMatrixStack_LoadMatrix(stack, &mat1); + ok(SUCCEEDED(hr), "LoadMatrix failed, hr %#x\n", hr); + expect_mat(&mat1, ID3DXMatrixStack_GetTop(stack)); + + hr = ID3DXMatrixStack_Push(stack); + ok(SUCCEEDED(hr), "Push failed, hr %#x\n", hr); + expect_mat(&mat1, ID3DXMatrixStack_GetTop(stack)); + + hr = ID3DXMatrixStack_LoadMatrix(stack, &mat2); + ok(SUCCEEDED(hr), "LoadMatrix failed, hr %#x\n", hr); + expect_mat(&mat2, ID3DXMatrixStack_GetTop(stack)); + + hr = ID3DXMatrixStack_Push(stack); + ok(SUCCEEDED(hr), "Push failed, hr %#x\n", hr); + expect_mat(&mat2, ID3DXMatrixStack_GetTop(stack)); + + hr = ID3DXMatrixStack_LoadIdentity(stack); + ok(SUCCEEDED(hr), "LoadIdentity failed, hr %#x\n", hr); + ok(D3DXMatrixIsIdentity(ID3DXMatrixStack_GetTop(stack)), "The top should be an identity matrix\n"); + + hr = ID3DXMatrixStack_Pop(stack); + ok(SUCCEEDED(hr), "Pop failed, hr %#x\n", hr); + expect_mat(&mat2, ID3DXMatrixStack_GetTop(stack)); + + hr = ID3DXMatrixStack_Pop(stack); + ok(SUCCEEDED(hr), "Pop failed, hr %#x\n", hr); + expect_mat(&mat1, ID3DXMatrixStack_GetTop(stack)); + + hr = ID3DXMatrixStack_Pop(stack); + ok(SUCCEEDED(hr), "Pop failed, hr %#x\n", hr); + ok(D3DXMatrixIsIdentity(ID3DXMatrixStack_GetTop(stack)), "The top should be an identity matrix\n"); + + hr = ID3DXMatrixStack_Pop(stack); + ok(SUCCEEDED(hr), "Pop failed, hr %#x\n", hr); + ok(D3DXMatrixIsIdentity(ID3DXMatrixStack_GetTop(stack)), "The top should be an identity matrix\n"); + + hr = ID3DXMatrixStack_MultMatrix(stack, NULL); + ok(hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); + + hr = ID3DXMatrixStack_MultMatrixLocal(stack, NULL); + ok(hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); + + hr = ID3DXMatrixStack_RotateAxis(stack, NULL, 2.0f); + ok(hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); + + hr = ID3DXMatrixStack_RotateAxisLocal(stack, NULL, 2.0f); + ok(hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); + + refcount = ID3DXMatrixStack_Release(stack); + ok(!refcount, "Matrix stack has %u references left.\n", refcount); +} + +START_TEST(math) +{ + D3DXColorTest(); + D3DXFresnelTest(); + D3DXMatrixTest(); + D3DXPlaneTest(); + D3X8QuaternionTest(); + D3X8Vector2Test(); + D3X8Vector3Test(); + D3X8Vector4Test(); + test_matrix_stack(); +} diff --git a/dlls/d3dx8/tests/mesh.c b/dlls/d3dx8/tests/mesh.c new file mode 100644 index 00000000000..04e8bf2e325 --- /dev/null +++ b/dlls/d3dx8/tests/mesh.c @@ -0,0 +1,396 @@ +/* + * Copyright 2008 David Adam + * Copyright 2008 Luis Busquets + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "d3dx8.h" + +#include "wine/test.h" + +#define admitted_error 0.0001f + +#define compare_vertex_sizes(type, exp) \ + got=D3DXGetFVFVertexSize(type); \ + ok(got==exp, "Expected: %d, Got: %d\n", exp, got); + +static BOOL compare(FLOAT u, FLOAT v) +{ + return (fabs(u-v) < admitted_error); +} + +static BOOL compare_vec3(D3DXVECTOR3 u, D3DXVECTOR3 v) +{ + return ( compare(u.x, v.x) && compare(u.y, v.y) && compare(u.z, v.z) ); +} + +static void D3DXBoundProbeTest(void) +{ + BOOL result; + D3DXVECTOR3 bottom_point, center, top_point, raydirection, rayposition; + FLOAT radius; + +/*____________Test the Box case___________________________*/ + bottom_point.x = -3.0f; bottom_point.y = -2.0f; bottom_point.z = -1.0f; + top_point.x = 7.0f; top_point.y = 8.0f; top_point.z = 9.0f; + + raydirection.x = -4.0f; raydirection.y = -5.0f; raydirection.z = -6.0f; + rayposition.x = 5.0f; rayposition.y = 5.0f; rayposition.z = 11.0f; + result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); + ok(result == TRUE, "expected TRUE, received FALSE\n"); + + raydirection.x = 4.0f; raydirection.y = 5.0f; raydirection.z = 6.0f; + rayposition.x = 5.0f; rayposition.y = 5.0f; rayposition.z = 11.0f; + result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); + ok(result == FALSE, "expected FALSE, received TRUE\n"); + + rayposition.x = -4.0f; rayposition.y = 1.0f; rayposition.z = -2.0f; + result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); + ok(result == TRUE, "expected TRUE, received FALSE\n"); + + bottom_point.x = 1.0f; bottom_point.y = 0.0f; bottom_point.z = 0.0f; + top_point.x = 1.0f; top_point.y = 0.0f; top_point.z = 0.0f; + rayposition.x = 0.0f; rayposition.y = 1.0f; rayposition.z = 0.0f; + raydirection.x = 0.0f; raydirection.y = 3.0f; raydirection.z = 0.0f; + result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); + ok(result == FALSE, "expected FALSE, received TRUE\n"); + + bottom_point.x = 1.0f; bottom_point.y = 2.0f; bottom_point.z = 3.0f; + top_point.x = 10.0f; top_point.y = 15.0f; top_point.z = 20.0f; + + raydirection.x = 7.0f; raydirection.y = 8.0f; raydirection.z = 9.0f; + rayposition.x = 3.0f; rayposition.y = 7.0f; rayposition.z = -6.0f; + result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); + ok(result == TRUE, "expected TRUE, received FALSE\n"); + + bottom_point.x = 0.0f; bottom_point.y = 0.0f; bottom_point.z = 0.0f; + top_point.x = 1.0f; top_point.y = 1.0f; top_point.z = 1.0f; + + raydirection.x = 0.0f; raydirection.y = 1.0f; raydirection.z = .0f; + rayposition.x = -3.0f; rayposition.y = 0.0f; rayposition.z = 0.0f; + result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); + ok(result == FALSE, "expected FALSE, received TRUE\n"); + + raydirection.x = 1.0f; raydirection.y = 0.0f; raydirection.z = .0f; + rayposition.x = -3.0f; rayposition.y = 0.0f; rayposition.z = 0.0f; + result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); + ok(result == TRUE, "expected TRUE, received FALSE\n"); + +/*____________Test the Sphere case________________________*/ + radius = sqrt(77.0f); + center.x = 1.0f; center.y = 2.0f; center.z = 3.0f; + raydirection.x = 2.0f; raydirection.y = -4.0f; raydirection.z = 2.0f; + + rayposition.x = 5.0f; rayposition.y = 5.0f; rayposition.z = 9.0f; + result = D3DXSphereBoundProbe(¢er, radius, &rayposition, &raydirection); + ok(result == TRUE, "expected TRUE, received FALSE\n"); + + rayposition.x = 45.0f; rayposition.y = -75.0f; rayposition.z = 49.0f; + result = D3DXSphereBoundProbe(¢er, radius, &rayposition, &raydirection); + ok(result == FALSE, "expected FALSE, received TRUE\n"); + + rayposition.x = 5.0f; rayposition.y = 7.0f; rayposition.z = 9.0f; + result = D3DXSphereBoundProbe(¢er, radius, &rayposition, &raydirection); + ok(result == FALSE, "expected FALSE, received TRUE\n"); + + rayposition.x = 5.0f; rayposition.y = 11.0f; rayposition.z = 9.0f; + result = D3DXSphereBoundProbe(¢er, radius, &rayposition, &raydirection); + ok(result == FALSE, "expected FALSE, received TRUE\n"); +} + +static void D3DXComputeBoundingBoxTest(void) +{ + D3DXVECTOR3 exp_max, exp_min, got_max, got_min, vertex[5]; + HRESULT hr; + + vertex[0].x = 1.0f; vertex[0].y = 1.0f; vertex[0].z = 1.0f; + vertex[1].x = 1.0f; vertex[1].y = 1.0f; vertex[1].z = 1.0f; + vertex[2].x = 1.0f; vertex[2].y = 1.0f; vertex[2].z = 1.0f; + vertex[3].x = 1.0f; vertex[3].y = 1.0f; vertex[3].z = 1.0f; + vertex[4].x = 9.0f; vertex[4].y = 9.0f; vertex[4].z = 9.0f; + + exp_min.x = 1.0f; exp_min.y = 1.0f; exp_min.z = 1.0f; + exp_max.x = 1.0f; exp_max.y = 1.0f; exp_max.z = 1.0f; + + hr = D3DXComputeBoundingBox(&vertex[3],2,D3DFVF_XYZ,&got_min,&got_max); + + ok( hr == D3D_OK, "Expected D3D_OK, got %#x\n", hr); + ok( compare_vec3(exp_min,got_min), "Expected min: (%f, %f, %f), got: (%f, %f, %f)\n", exp_min.x,exp_min.y,exp_min.z,got_min.x,got_min.y,got_min.z); + ok( compare_vec3(exp_max,got_max), "Expected max: (%f, %f, %f), got: (%f, %f, %f)\n", exp_max.x,exp_max.y,exp_max.z,got_max.x,got_max.y,got_max.z); + +/*________________________*/ + + vertex[0].x = 2.0f; vertex[0].y = 5.9f; vertex[0].z = -1.2f; + vertex[1].x = -1.87f; vertex[1].y = 7.9f; vertex[1].z = 7.4f; + vertex[2].x = 7.43f; vertex[2].y = -0.9f; vertex[2].z = 11.9f; + vertex[3].x = -6.92f; vertex[3].y = 6.3f; vertex[3].z = -3.8f; + vertex[4].x = 11.4f; vertex[4].y = -8.1f; vertex[4].z = 4.5f; + + exp_min.x = -6.92f; exp_min.y = -0.90f; exp_min.z = -3.80f; + exp_max.x = 7.43f; exp_max.y = 7.90f; exp_max.z = 11.9f; + + hr = D3DXComputeBoundingBox(&vertex[0],5,D3DFVF_XYZ,&got_min,&got_max); + + ok( hr == D3D_OK, "Expected D3D_OK, got %#x\n", hr); + ok( compare_vec3(exp_min,got_min), "Expected min: (%f, %f, %f), got: (%f, %f, %f)\n", exp_min.x,exp_min.y,exp_min.z,got_min.x,got_min.y,got_min.z); + ok( compare_vec3(exp_max,got_max), "Expected max: (%f, %f, %f), got: (%f, %f, %f)\n", exp_max.x,exp_max.y,exp_max.z,got_max.x,got_max.y,got_max.z); + +/*________________________*/ + + vertex[0].x = 2.0f; vertex[0].y = 5.9f; vertex[0].z = -1.2f; + vertex[1].x = -1.87f; vertex[1].y = 7.9f; vertex[1].z = 7.4f; + vertex[2].x = 7.43f; vertex[2].y = -0.9f; vertex[2].z = 11.9f; + vertex[3].x = -6.92f; vertex[3].y = 6.3f; vertex[3].z = -3.8f; + vertex[4].x = 11.4f; vertex[4].y = -8.1f; vertex[4].z = 4.5f; + + exp_min.x = -1.87f; exp_min.y = -0.90f; exp_min.z = -1.20f; + exp_max.x = 7.43f; exp_max.y = 7.90f; exp_max.z = 11.9f; + + hr = D3DXComputeBoundingBox(&vertex[0],4,D3DFVF_XYZ,&got_min,&got_max); + + ok( hr == D3D_OK, "Expected D3D_OK, got %#x\n", hr); + ok( compare_vec3(exp_min,got_min), "Expected min: (%f, %f, %f), got: (%f, %f, %f)\n", exp_min.x,exp_min.y,exp_min.z,got_min.x,got_min.y,got_min.z); + ok( compare_vec3(exp_max,got_max), "Expected max: (%f, %f, %f), got: (%f, %f, %f)\n", exp_max.x,exp_max.y,exp_max.z,got_max.x,got_max.y,got_max.z); + +/*________________________*/ + hr = D3DXComputeBoundingBox(NULL,5,D3DFVF_XYZ,&got_min,&got_max); + ok( hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); + +/*________________________*/ + hr = D3DXComputeBoundingBox(&vertex[3],5,D3DFVF_XYZ,NULL,&got_max); + ok( hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); + +/*________________________*/ + hr = D3DXComputeBoundingBox(&vertex[3],5,D3DFVF_XYZ,&got_min,NULL); + ok( hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); +} + +static void D3DXComputeBoundingSphereTest(void) +{ + D3DXVECTOR3 exp_cen, got_cen, vertex[5]; + FLOAT exp_rad, got_rad; + HRESULT hr; + + vertex[0].x = 1.0f; vertex[0].y = 1.0f; vertex[0].z = 1.0f; + vertex[1].x = 1.0f; vertex[1].y = 1.0f; vertex[1].z = 1.0f; + vertex[2].x = 1.0f; vertex[2].y = 1.0f; vertex[2].z = 1.0f; + vertex[3].x = 1.0f; vertex[3].y = 1.0f; vertex[3].z = 1.0f; + vertex[4].x = 9.0f; vertex[4].y = 9.0f; vertex[4].z = 9.0f; + + exp_rad = 6.928203f; + exp_cen.x = 5.0; exp_cen.y = 5.0; exp_cen.z = 5.0; + + hr = D3DXComputeBoundingSphere(&vertex[3],2,D3DFVF_XYZ,&got_cen,&got_rad); + + ok( hr == D3D_OK, "Expected D3D_OK, got %#x\n", hr); + ok( compare(exp_rad, got_rad), "Expected radius: %f, got radius: %f\n", exp_rad, got_rad); + ok( compare_vec3(exp_cen,got_cen), "Expected center: (%f, %f, %f), got center: (%f, %f, %f)\n", exp_cen.x,exp_cen.y,exp_cen.z,got_cen.x,got_cen.y,got_cen.z); + +/*________________________*/ + + vertex[0].x = 2.0f; vertex[0].y = 5.9f; vertex[0].z = -1.2f; + vertex[1].x = -1.87f; vertex[1].y = 7.9f; vertex[1].z = 7.4f; + vertex[2].x = 7.43f; vertex[2].y = -0.9f; vertex[2].z = 11.9f; + vertex[3].x = -6.92f; vertex[3].y = 6.3f; vertex[3].z = -3.8f; + vertex[4].x = 11.4f; vertex[4].y = -8.1f; vertex[4].z = 4.5f; + + exp_rad = 13.707883f; + exp_cen.x = 2.408f; exp_cen.y = 2.22f; exp_cen.z = 3.76f; + + hr = D3DXComputeBoundingSphere(&vertex[0],5,D3DFVF_XYZ,&got_cen,&got_rad); + + ok( hr == D3D_OK, "Expected D3D_OK, got %#x\n", hr); + ok( compare(exp_rad, got_rad), "Expected radius: %f, got radius: %f\n", exp_rad, got_rad); + ok( compare_vec3(exp_cen,got_cen), "Expected center: (%f, %f, %f), got center: (%f, %f, %f)\n", exp_cen.x,exp_cen.y,exp_cen.z,got_cen.x,got_cen.y,got_cen.z); + +/*________________________*/ + hr = D3DXComputeBoundingSphere(NULL,5,D3DFVF_XYZ,&got_cen,&got_rad); + ok( hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); + +/*________________________*/ + hr = D3DXComputeBoundingSphere(&vertex[3],5,D3DFVF_XYZ,NULL,&got_rad); + ok( hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); + +/*________________________*/ + hr = D3DXComputeBoundingSphere(&vertex[3],5,D3DFVF_XYZ,&got_cen,NULL); + ok( hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); +} + +static void D3DXGetFVFVertexSizeTest(void) +{ + UINT got; + + compare_vertex_sizes (D3DFVF_XYZ, 12); + + compare_vertex_sizes (D3DFVF_XYZB3, 24); + + compare_vertex_sizes (D3DFVF_XYZB5, 32); + + compare_vertex_sizes (D3DFVF_XYZ | D3DFVF_NORMAL, 24); + + compare_vertex_sizes (D3DFVF_XYZ | D3DFVF_DIFFUSE, 16); + + compare_vertex_sizes ( + D3DFVF_XYZ | + D3DFVF_TEX1 | + D3DFVF_TEXCOORDSIZE1(0), 16); + compare_vertex_sizes ( + D3DFVF_XYZ | + D3DFVF_TEX2 | + D3DFVF_TEXCOORDSIZE1(0) | + D3DFVF_TEXCOORDSIZE1(1), 20); + + compare_vertex_sizes ( + D3DFVF_XYZ | + D3DFVF_TEX1 | + D3DFVF_TEXCOORDSIZE2(0), 20); + + compare_vertex_sizes ( + D3DFVF_XYZ | + D3DFVF_TEX2 | + D3DFVF_TEXCOORDSIZE2(0) | + D3DFVF_TEXCOORDSIZE2(1), 28); + + compare_vertex_sizes ( + D3DFVF_XYZ | + D3DFVF_TEX6 | + D3DFVF_TEXCOORDSIZE2(0) | + D3DFVF_TEXCOORDSIZE2(1) | + D3DFVF_TEXCOORDSIZE2(2) | + D3DFVF_TEXCOORDSIZE2(3) | + D3DFVF_TEXCOORDSIZE2(4) | + D3DFVF_TEXCOORDSIZE2(5), 60); + + compare_vertex_sizes ( + D3DFVF_XYZ | + D3DFVF_TEX8 | + D3DFVF_TEXCOORDSIZE2(0) | + D3DFVF_TEXCOORDSIZE2(1) | + D3DFVF_TEXCOORDSIZE2(2) | + D3DFVF_TEXCOORDSIZE2(3) | + D3DFVF_TEXCOORDSIZE2(4) | + D3DFVF_TEXCOORDSIZE2(5) | + D3DFVF_TEXCOORDSIZE2(6) | + D3DFVF_TEXCOORDSIZE2(7), 76); + + compare_vertex_sizes ( + D3DFVF_XYZ | + D3DFVF_TEX1 | + D3DFVF_TEXCOORDSIZE3(0), 24); + + compare_vertex_sizes ( + D3DFVF_XYZ | + D3DFVF_TEX4 | + D3DFVF_TEXCOORDSIZE3(0) | + D3DFVF_TEXCOORDSIZE3(1) | + D3DFVF_TEXCOORDSIZE3(2) | + D3DFVF_TEXCOORDSIZE3(3), 60); + + compare_vertex_sizes ( + D3DFVF_XYZ | + D3DFVF_TEX1 | + D3DFVF_TEXCOORDSIZE4(0), 28); + + compare_vertex_sizes ( + D3DFVF_XYZ | + D3DFVF_TEX2 | + D3DFVF_TEXCOORDSIZE4(0) | + D3DFVF_TEXCOORDSIZE4(1), 44); + + compare_vertex_sizes ( + D3DFVF_XYZ | + D3DFVF_TEX3 | + D3DFVF_TEXCOORDSIZE4(0) | + D3DFVF_TEXCOORDSIZE4(1) | + D3DFVF_TEXCOORDSIZE4(2), 60); + + compare_vertex_sizes ( + D3DFVF_XYZB5 | + D3DFVF_NORMAL | + D3DFVF_DIFFUSE | + D3DFVF_SPECULAR | + D3DFVF_TEX8 | + D3DFVF_TEXCOORDSIZE4(0) | + D3DFVF_TEXCOORDSIZE4(1) | + D3DFVF_TEXCOORDSIZE4(2) | + D3DFVF_TEXCOORDSIZE4(3) | + D3DFVF_TEXCOORDSIZE4(4) | + D3DFVF_TEXCOORDSIZE4(5) | + D3DFVF_TEXCOORDSIZE4(6) | + D3DFVF_TEXCOORDSIZE4(7), 180); +} + +static void D3DXIntersectTriTest(void) +{ + BOOL exp_res, got_res; + D3DXVECTOR3 position, ray, vertex[3]; + FLOAT exp_dist, got_dist, exp_u, got_u, exp_v, got_v; + + vertex[0].x = 1.0f; vertex[0].y = 0.0f; vertex[0].z = 0.0f; + vertex[1].x = 2.0f; vertex[1].y = 0.0f; vertex[1].z = 0.0f; + vertex[2].x = 1.0f; vertex[2].y = 1.0f; vertex[2].z = 0.0f; + + position.x = -14.5f; position.y = -23.75f; position.z = -32.0f; + + ray.x = 2.0f; ray.y = 3.0f; ray.z = 4.0f; + + exp_res = TRUE; exp_u = 0.5f; exp_v = 0.25f; exp_dist = 8.0f; + + got_res = D3DXIntersectTri(&vertex[0],&vertex[1],&vertex[2],&position,&ray,&got_u,&got_v,&got_dist); + ok( got_res == exp_res, "Expected result = %d, got %d\n",exp_res,got_res); + ok( compare(exp_u,got_u), "Expected u = %f, got %f\n",exp_u,got_u); + ok( compare(exp_v,got_v), "Expected v = %f, got %f\n",exp_v,got_v); + ok( compare(exp_dist,got_dist), "Expected distance = %f, got %f\n",exp_dist,got_dist); + +/*Only positive ray is taken in account*/ + + vertex[0].x = 1.0f; vertex[0].y = 0.0f; vertex[0].z = 0.0f; + vertex[1].x = 2.0f; vertex[1].y = 0.0f; vertex[1].z = 0.0f; + vertex[2].x = 1.0f; vertex[2].y = 1.0f; vertex[2].z = 0.0f; + + position.x = 17.5f; position.y = 24.25f; position.z = 32.0f; + + ray.x = 2.0f; ray.y = 3.0f; ray.z = 4.0f; + + exp_res = FALSE; + + got_res = D3DXIntersectTri(&vertex[0],&vertex[1],&vertex[2],&position,&ray,&got_u,&got_v,&got_dist); + ok( got_res == exp_res, "Expected result = %d, got %d\n",exp_res,got_res); + +/*Intersection between ray and triangle in a same plane is considered as empty*/ + + vertex[0].x = 4.0f; vertex[0].y = 0.0f; vertex[0].z = 0.0f; + vertex[1].x = 6.0f; vertex[1].y = 0.0f; vertex[1].z = 0.0f; + vertex[2].x = 4.0f; vertex[2].y = 2.0f; vertex[2].z = 0.0f; + + position.x = 1.0f; position.y = 1.0f; position.z = 0.0f; + + ray.x = 1.0f; ray.y = 0.0f; ray.z = 0.0f; + + exp_res = FALSE; + + got_res = D3DXIntersectTri(&vertex[0],&vertex[1],&vertex[2],&position,&ray,&got_u,&got_v,&got_dist); + ok( got_res == exp_res, "Expected result = %d, got %d\n",exp_res,got_res); +} + +START_TEST(mesh) +{ + D3DXBoundProbeTest(); + D3DXComputeBoundingBoxTest(); + D3DXComputeBoundingSphereTest(); + D3DXGetFVFVertexSizeTest(); + D3DXIntersectTriTest(); +} diff --git a/dlls/d3dx9_36/Makefile.in b/dlls/d3dx9_36/Makefile.in index 88ac1d70739..c094071836d 100644 --- a/dlls/d3dx9_36/Makefile.in +++ b/dlls/d3dx9_36/Makefile.in @@ -4,10 +4,9 @@ SRCDIR = @srcdir@ VPATH = @srcdir@ MODULE = d3dx9_36.dll IMPORTLIB = d3dx9 -IMPORTS = d3d9 gdi32 user32 kernel32 +IMPORTS = d3d9 d3dx8 kernel32 C_SRCS = \ - core.c \ d3dx9_36_main.c \ font.c \ math.c \ diff --git a/dlls/d3dx9_36/core.c b/dlls/d3dx9_36/core.c deleted file mode 100644 index 3b63e9e4688..00000000000 --- a/dlls/d3dx9_36/core.c +++ /dev/null @@ -1,120 +0,0 @@ -/* - * - * Copyright 2002 Raphael Junqueira - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include - -#define COBJMACROS -#include "windef.h" -#include "winbase.h" -#include "wingdi.h" -#include "wine/debug.h" -#include "wine/unicode.h" - -#include "d3dx9_36_private.h" - -WINE_DEFAULT_DEBUG_CHANNEL(d3dx); - -/* ID3DXBuffer IUnknown parts follow: */ -static HRESULT WINAPI ID3DXBufferImpl_QueryInterface(LPD3DXBUFFER iface, REFIID riid, LPVOID* ppobj) -{ - ID3DXBufferImpl *This = (ID3DXBufferImpl *)iface; - - if (IsEqualGUID(riid, &IID_IUnknown) - || IsEqualGUID(riid, &IID_ID3DXBuffer)) - { - IUnknown_AddRef(iface); - *ppobj = This; - return D3D_OK; - } - - WARN("(%p)->(%s,%p),not found\n",This,debugstr_guid(riid),ppobj); - return E_NOINTERFACE; -} - -static ULONG WINAPI ID3DXBufferImpl_AddRef(LPD3DXBUFFER iface) -{ - ID3DXBufferImpl *This = (ID3DXBufferImpl *)iface; - ULONG ref = InterlockedIncrement(&This->ref); - - TRACE("(%p) : AddRef from %d\n", This, ref - 1); - - return ref; -} - -static ULONG WINAPI ID3DXBufferImpl_Release(LPD3DXBUFFER iface) -{ - ID3DXBufferImpl *This = (ID3DXBufferImpl *)iface; - ULONG ref = InterlockedDecrement(&This->ref); - - TRACE("(%p) : ReleaseRef to %d\n", This, ref); - - if (ref == 0) - { - HeapFree(GetProcessHeap(), 0, This->buffer); - HeapFree(GetProcessHeap(), 0, This); - } - return ref; -} - -/* ID3DXBuffer Interface follow: */ -static LPVOID WINAPI ID3DXBufferImpl_GetBufferPointer(LPD3DXBUFFER iface) -{ - ID3DXBufferImpl *This = (ID3DXBufferImpl *)iface; - return This->buffer; -} - -static DWORD WINAPI ID3DXBufferImpl_GetBufferSize(LPD3DXBUFFER iface) -{ - ID3DXBufferImpl *This = (ID3DXBufferImpl *)iface; - return This->bufferSize; -} - -const ID3DXBufferVtbl D3DXBuffer_Vtbl = -{ - ID3DXBufferImpl_QueryInterface, - ID3DXBufferImpl_AddRef, - ID3DXBufferImpl_Release, - ID3DXBufferImpl_GetBufferPointer, - ID3DXBufferImpl_GetBufferSize -}; - -HRESULT WINAPI D3DXCreateBuffer(DWORD NumBytes, LPD3DXBUFFER* ppBuffer) -{ - ID3DXBufferImpl *object; - - object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(ID3DXBufferImpl)); - if (object == NULL) - { - *ppBuffer = NULL; - return E_OUTOFMEMORY; - } - object->lpVtbl = &D3DXBuffer_Vtbl; - object->ref = 1; - object->bufferSize = NumBytes; - object->buffer = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, NumBytes); - if (object->buffer == NULL) - { - HeapFree(GetProcessHeap(), 0, object); - *ppBuffer = NULL; - return E_OUTOFMEMORY; - } - - *ppBuffer = (LPD3DXBUFFER)object; - return D3D_OK; -} diff --git a/dlls/d3dx9_36/d3dx9_36.spec b/dlls/d3dx9_36/d3dx9_36.spec index d3fe3acad7c..9721fc4141e 100644 --- a/dlls/d3dx9_36/d3dx9_36.spec +++ b/dlls/d3dx9_36/d3dx9_36.spec @@ -3,14 +3,14 @@ @ stub D3DXAssembleShaderFromFileW @ stub D3DXAssembleShaderFromResourceA @ stub D3DXAssembleShaderFromResourceW -@ stdcall D3DXBoxBoundProbe(ptr ptr ptr ptr) +@ stdcall D3DXBoxBoundProbe(ptr ptr ptr ptr) d3dx8.D3DXBoxBoundProbe @ stub D3DXCheckCubeTextureRequirements @ stub D3DXCheckTextureRequirements @ stdcall D3DXCheckVersion(long long) @ stub D3DXCheckVolumeTextureRequirements @ stub D3DXCleanMesh -@ stdcall D3DXColorAdjustContrast(ptr ptr long) -@ stdcall D3DXColorAdjustSaturation(ptr ptr long) +@ stdcall D3DXColorAdjustContrast(ptr ptr long) d3dx8.D3DXColorAdjustContrast +@ stdcall D3DXColorAdjustSaturation(ptr ptr long) d3dx8.D3DXColorAdjustSaturation @ stub D3DXCompileShader @ stub D3DXCompileShaderFromFileA @ stub D3DXCompileShaderFromFileW @@ -23,7 +23,7 @@ @ stub D3DXComputeIMTFromSignal @ stub D3DXComputeIMTFromTexture @ stub D3DXComputeNormalMap -@ stub D3DXComputeNormals +@ stdcall D3DXComputeNormals(ptr ptr) d3dx8.D3DXComputeNormals @ stub D3DXComputeTangent @ stub D3DXComputeTangentFrame @ stub D3DXComputeTangentFrameEx @@ -32,7 +32,7 @@ @ stub D3DXConvertMeshSubsetToStrips @ stub D3DXCreateAnimationController @ stub D3DXCreateBox -@ stdcall D3DXCreateBuffer(long ptr) +@ stdcall D3DXCreateBuffer(long ptr) d3dx8.D3DXCreateBuffer @ stub D3DXCreateCompressedAnimationSet @ stub D3DXCreateCubeTexture @ stub D3DXCreateCubeTextureFromFileA @@ -70,7 +70,7 @@ @ stub D3DXCreateFragmentLinkerEx @ stub D3DXCreateKeyframedAnimationSet @ stub D3DXCreateLine -@ stdcall D3DXCreateMatrixStack(long ptr) +@ stdcall D3DXCreateMatrixStack(long ptr) d3dx8.D3DXCreateMatrixStack @ stub D3DXCreateMesh @ stub D3DXCreateMeshFVF @ stub D3DXCreateNPatchMesh @@ -83,7 +83,7 @@ @ stub D3DXCreatePRTEngine @ stub D3DXCreateRenderToEnvMap @ stub D3DXCreateRenderToSurface -@ stub D3DXCreateSPMesh +@ stdcall D3DXCreateSPMesh(ptr ptr ptr ptr ptr) d3dx8.D3DXCreateSPMesh @ stub D3DXCreateSkinInfo @ stub D3DXCreateSkinInfoFromBlendedMesh @ stub D3DXCreateSkinInfoFVF @@ -138,7 +138,7 @@ @ stub D3DXFrameFind @ stub D3DXFrameNumNamedMatrices @ stub D3DXFrameRegisterNamedMatrices -@ stdcall D3DXFresnelTerm(long long) +@ stdcall D3DXFresnelTerm(long long) d3dx8.D3DXFresnelTerm @ stub D3DXFVFFromDeclarator @ stub D3DXGatherFragments @ stub D3DXGatherFragmentsFromFileA @@ -146,7 +146,7 @@ @ stub D3DXGatherFragmentsFromResourceA @ stub D3DXGatherFragmentsFromResourceW @ stub D3DXGenerateOutputDecl -@ stub D3DXGeneratePMesh +@ stdcall D3DXGeneratePMesh(ptr ptr ptr ptr long long ptr) d3dx8.D3DXGeneratePMesh @ stub D3DXGetDeclLength @ stdcall D3DXGetDeclVertexSize(ptr long) @ stdcall D3DXGetDriverLevel(ptr) @@ -165,8 +165,8 @@ @ stdcall D3DXGetShaderSize(ptr) @ stdcall D3DXGetShaderVersion(ptr) @ stdcall D3DXGetVertexShaderProfile(ptr) -@ stub D3DXIntersect -@ stub D3DXIntersectSubset +@ stdcall D3DXIntersect(ptr ptr ptr ptr ptr ptr ptr ptr ptr ptr) d3dx8.D3DXIntersect +@ stdcall D3DXIntersectSubset(ptr long ptr ptr ptr ptr ptr ptr ptr ptr ptr) d3dx8.D3DXIntersectSubset @ stdcall D3DXIntersectTri(ptr ptr ptr ptr ptr ptr ptr ptr) @ stub D3DXLoadMeshFromXA @ stub D3DXLoadMeshFromXInMemory @@ -182,13 +182,13 @@ @ stub D3DXLoadPRTCompBufferFromFileA @ stub D3DXLoadPRTCompBufferFromFileW @ stub D3DXLoadSkinMeshFromXof -@ stdcall D3DXLoadSurfaceFromFileA(ptr ptr ptr str ptr long long ptr) -@ stdcall D3DXLoadSurfaceFromFileInMemory(ptr ptr ptr ptr long ptr long long ptr) -@ stdcall D3DXLoadSurfaceFromFileW(ptr ptr ptr wstr ptr long long ptr) -@ stdcall D3DXLoadSurfaceFromMemory(ptr ptr ptr ptr long long ptr ptr long long) -@ stdcall D3DXLoadSurfaceFromResourceA(ptr ptr ptr ptr str ptr long long ptr) -@ stdcall D3DXLoadSurfaceFromResourceW(ptr ptr ptr ptr wstr ptr long long ptr) -@ stdcall D3DXLoadSurfaceFromSurface(ptr ptr ptr ptr ptr ptr long long) +@ stub D3DXLoadSurfaceFromFileA +@ stub D3DXLoadSurfaceFromFileInMemory +@ stub D3DXLoadSurfaceFromFileW +@ stub D3DXLoadSurfaceFromMemory +@ stub D3DXLoadSurfaceFromResourceA +@ stub D3DXLoadSurfaceFromResourceW +@ stub D3DXLoadSurfaceFromSurface @ stub D3DXLoadVolumeFromFileA @ stub D3DXLoadVolumeFromFileInMemory @ stub D3DXLoadVolumeFromFileW @@ -196,64 +196,64 @@ @ stub D3DXLoadVolumeFromResourceA @ stub D3DXLoadVolumeFromResourceW @ stub D3DXLoadVolumeFromVolume -@ stdcall D3DXMatrixAffineTransformation(ptr long ptr ptr ptr) +@ stdcall D3DXMatrixAffineTransformation(ptr long ptr ptr ptr) d3dx8.D3DXMatrixAffineTransformation @ stdcall D3DXMatrixAffineTransformation2D(ptr long ptr long ptr) @ stdcall D3DXMatrixDecompose(ptr ptr ptr ptr) -@ stdcall D3DXMatrixDeterminant(ptr) -@ stdcall D3DXMatrixInverse(ptr ptr ptr) -@ stdcall D3DXMatrixLookAtLH(ptr ptr ptr ptr) -@ stdcall D3DXMatrixLookAtRH(ptr ptr ptr ptr) -@ stdcall D3DXMatrixMultiply(ptr ptr ptr) -@ stdcall D3DXMatrixMultiplyTranspose(ptr ptr ptr) -@ stdcall D3DXMatrixOrthoLH(ptr long long long long) -@ stdcall D3DXMatrixOrthoOffCenterLH(ptr long long long long long long) -@ stdcall D3DXMatrixOrthoOffCenterRH(ptr long long long long long long) -@ stdcall D3DXMatrixOrthoRH(ptr long long long long) -@ stdcall D3DXMatrixPerspectiveFovLH(ptr long long long long) -@ stdcall D3DXMatrixPerspectiveFovRH(ptr long long long long) -@ stdcall D3DXMatrixPerspectiveLH(ptr long long long long) -@ stdcall D3DXMatrixPerspectiveOffCenterLH(ptr long long long long long long) -@ stdcall D3DXMatrixPerspectiveOffCenterRH(ptr long long long long long long) -@ stdcall D3DXMatrixPerspectiveRH(ptr long long long long) -@ stdcall D3DXMatrixReflect(ptr ptr) -@ stdcall D3DXMatrixRotationAxis(ptr ptr long) -@ stdcall D3DXMatrixRotationQuaternion(ptr ptr) -@ stdcall D3DXMatrixRotationX(ptr long) -@ stdcall D3DXMatrixRotationY(ptr long) -@ stdcall D3DXMatrixRotationYawPitchRoll(ptr long long long) -@ stdcall D3DXMatrixRotationZ(ptr long) -@ stdcall D3DXMatrixScaling(ptr long long long) -@ stdcall D3DXMatrixShadow(ptr ptr ptr) -@ stdcall D3DXMatrixTransformation(ptr ptr ptr ptr ptr ptr ptr) +@ stdcall D3DXMatrixDeterminant(ptr) d3dx8.D3DXMatrixfDeterminant +@ stdcall D3DXMatrixInverse(ptr ptr ptr) d3dx8.D3DXMatrixInverse +@ stdcall D3DXMatrixLookAtLH(ptr ptr ptr ptr) d3dx8.D3DXMatrixLookAtLH +@ stdcall D3DXMatrixLookAtRH(ptr ptr ptr ptr) d3dx8.D3DXMatrixLookAtRH +@ stdcall D3DXMatrixMultiply(ptr ptr ptr) d3dx8.D3DXMatrixMultiply +@ stdcall D3DXMatrixMultiplyTranspose(ptr ptr ptr) d3dx8.D3DXMatrixMultiplyTranspose +@ stdcall D3DXMatrixOrthoLH(ptr long long long long) d3dx8.D3DXMatrixOrthoLH +@ stdcall D3DXMatrixOrthoOffCenterLH(ptr long long long long long long) d3dx8.D3DXMatrixOrthoOffCenterLH +@ stdcall D3DXMatrixOrthoOffCenterRH(ptr long long long long long long) d3dx8.D3DXMatrixOrthoOffCenterRH +@ stdcall D3DXMatrixOrthoRH(ptr long long long long) d3dx8.D3DXMatrixOrthoRH +@ stdcall D3DXMatrixPerspectiveFovLH(ptr long long long long) d3dx8.D3DXMatrixPerspectiveFovLH +@ stdcall D3DXMatrixPerspectiveFovRH(ptr long long long long) d3dx8.D3DXMatrixPerspectiveFovRH +@ stdcall D3DXMatrixPerspectiveLH(ptr long long long long) d3dx8.D3DXMatrixPerspectiveLH +@ stdcall D3DXMatrixPerspectiveOffCenterLH(ptr long long long long long long) d3dx8.D3DXMatrixPerspectiveOffCenterLH +@ stdcall D3DXMatrixPerspectiveOffCenterRH(ptr long long long long long long) d3dx8.D3DXMatrixPerspectiveOffCenterRH +@ stdcall D3DXMatrixPerspectiveRH(ptr long long long long) d3dx8.D3DXMatrixPerspectiveRH +@ stdcall D3DXMatrixReflect(ptr ptr) d3dx8.D3DXMatrixReflect +@ stdcall D3DXMatrixRotationAxis(ptr ptr long) d3dx8.D3DXMatrixRotationAxis +@ stdcall D3DXMatrixRotationQuaternion(ptr ptr) d3dx8.D3DXMatrixRotationQuaternion +@ stdcall D3DXMatrixRotationX(ptr long) d3dx8.D3DXMatrixRotationX +@ stdcall D3DXMatrixRotationY(ptr long) d3dx8.D3DXMatrixRotationY +@ stdcall D3DXMatrixRotationYawPitchRoll(ptr long long long) d3dx8.D3DXMatrixRotationYawPitchRoll +@ stdcall D3DXMatrixRotationZ(ptr long) d3dx8.D3DXMatrixRotationZ +@ stdcall D3DXMatrixScaling(ptr long long long) d3dx8.D3DXMatrixScaling +@ stdcall D3DXMatrixShadow(ptr ptr ptr) d3dx8.D3DXMatrixShadow +@ stdcall D3DXMatrixTransformation(ptr ptr ptr ptr ptr ptr ptr) d3dx8.D3DXMatrixTransformation @ stdcall D3DXMatrixTransformation2D(ptr ptr long ptr ptr long ptr) -@ stdcall D3DXMatrixTranslation(ptr long long long) -@ stdcall D3DXMatrixTranspose(ptr ptr) +@ stdcall D3DXMatrixTranslation(ptr long long long) d3dx8.D3DXMatrixTranslation +@ stdcall D3DXMatrixTranspose(ptr ptr) d3dx8.D3DXMatrixTranspose @ stub D3DXOptimizeFaces @ stub D3DXOptimizeVertices -@ stdcall D3DXPlaneFromPointNormal(ptr ptr ptr) -@ stdcall D3DXPlaneFromPoints(ptr ptr ptr ptr) -@ stdcall D3DXPlaneIntersectLine(ptr ptr ptr ptr) -@ stdcall D3DXPlaneNormalize(ptr ptr) -@ stdcall D3DXPlaneTransform(ptr ptr ptr) +@ stdcall D3DXPlaneFromPointNormal(ptr ptr ptr) d3dx8.D3DXPlaneFromPointNormal +@ stdcall D3DXPlaneFromPoints(ptr ptr ptr ptr) d3dx8.D3DXPlaneFromPoints +@ stdcall D3DXPlaneIntersectLine(ptr ptr ptr ptr) d3dx8.D3DXPlaneIntersectLine +@ stdcall D3DXPlaneNormalize(ptr ptr) d3dx8.D3DXPlaneNormalize +@ stdcall D3DXPlaneTransform(ptr ptr ptr) d3dx8.D3DXPlaneTransform @ stdcall D3DXPlaneTransformArray(ptr long ptr long ptr long) @ stub D3DXPreprocessShader @ stub D3DXPreprocessShaderFromFileA @ stub D3DXPreprocessShaderFromFileW @ stub D3DXPreprocessShaderFromResourceA @ stub D3DXPreprocessShaderFromResourceW -@ stdcall D3DXQuaternionBaryCentric(ptr ptr ptr ptr long long) -@ stdcall D3DXQuaternionExp(ptr ptr) -@ stdcall D3DXQuaternionInverse(ptr ptr) -@ stdcall D3DXQuaternionLn(ptr ptr) -@ stdcall D3DXQuaternionMultiply(ptr ptr ptr) -@ stdcall D3DXQuaternionNormalize(ptr ptr) -@ stdcall D3DXQuaternionRotationAxis(ptr ptr long) -@ stdcall D3DXQuaternionRotationMatrix(ptr ptr) -@ stdcall D3DXQuaternionRotationYawPitchRoll(ptr long long long) -@ stdcall D3DXQuaternionSlerp(ptr ptr ptr long) -@ stdcall D3DXQuaternionSquad(ptr ptr ptr ptr ptr long) -@ stub D3DXQuaternionSquadSetup -@ stdcall D3DXQuaternionToAxisAngle(ptr ptr ptr) +@ stdcall D3DXQuaternionBaryCentric(ptr ptr ptr ptr long long) d3dx8.D3DXQuaternionBaryCentric +@ stdcall D3DXQuaternionExp(ptr ptr) d3dx8.D3DXQuaternionExp +@ stdcall D3DXQuaternionInverse(ptr ptr) d3dx8.D3DXQuaternionInverse +@ stdcall D3DXQuaternionLn(ptr ptr) d3dx8.D3DXQuaternionLn +@ stdcall D3DXQuaternionMultiply(ptr ptr ptr) d3dx8.D3DXQuaternionMultiply +@ stdcall D3DXQuaternionNormalize(ptr ptr) d3dx8.D3DXQuaternionNormalize +@ stdcall D3DXQuaternionRotationAxis(ptr ptr long) d3dx8.D3DXQuaternionRotationAxis +@ stdcall D3DXQuaternionRotationMatrix(ptr ptr) d3dx8.D3DXQuaternionRotationMatrix +@ stdcall D3DXQuaternionRotationYawPitchRoll(ptr long long long) d3dx8.D3DXQuaternionRotationYawPitchRoll +@ stdcall D3DXQuaternionSlerp(ptr ptr ptr long) d3dx8.D3DXQuaternionSlerp +@ stdcall D3DXQuaternionSquad(ptr ptr ptr ptr ptr long) d3dx8.D3DXQuaternionSquad +@ stdcall D3DXQuaternionSquadSetup(ptr ptr ptr ptr ptr ptr ptr) d3dx8.D3DXQuaternionSquadSetup +@ stdcall D3DXQuaternionToAxisAngle(ptr ptr ptr) d3dx8.D3DXQuaternionToAxisAngle @ stub D3DXRectPatchSize @ stub D3DXSaveMeshHierarchyToFileA @ stub D3DXSaveMeshHierarchyToFileW @@ -290,47 +290,47 @@ @ stub D3DXSHRotate @ stub D3DXSHRotateZ @ stub D3DXSHScale -@ stub D3DXSimplifyMesh -@ stdcall D3DXSphereBoundProbe(ptr long ptr ptr) -@ stub D3DXSplitMesh -@ stub D3DXTessellateNPatches +@ stdcall D3DXSimplifyMesh(ptr ptr ptr ptr long long ptr) d3dx8.D3DXSimplifyMesh +@ stdcall D3DXSphereBoundProbe(ptr long ptr ptr) d3dx8.D3DXSphereBoundProbe +@ stdcall D3DXSplitMesh(ptr ptr long long ptr ptr ptr ptr ptr) d3dx8.D3DXSplitMesh +@ stdcall D3DXTessellateNPatches(ptr ptr long long ptr ptr) d3dx8.D3DXTessellateNPatches @ stub D3DXTessellateRectPatch @ stub D3DXTessellateTriPatch @ stub D3DXTriPatchSize @ stub D3DXUVAtlasCreate @ stub D3DXUVAtlasPack @ stub D3DXUVAtlasPartition -@ stub D3DXValidMesh +@ stdcall D3DXValidMesh(ptr ptr ptr) d3dx8.D3DXValidMesh @ stub D3DXValidPatchMesh -@ stdcall D3DXVec2BaryCentric(ptr ptr ptr ptr long long) -@ stdcall D3DXVec2CatmullRom(ptr ptr ptr ptr ptr long) -@ stdcall D3DXVec2Hermite(ptr ptr ptr ptr ptr long) -@ stdcall D3DXVec2Normalize(ptr ptr) -@ stdcall D3DXVec2Transform(ptr ptr ptr) +@ stdcall D3DXVec2BaryCentric(ptr ptr ptr ptr long long) d3dx8.D3DXVec2BaryCentric +@ stdcall D3DXVec2CatmullRom(ptr ptr ptr ptr ptr long) d3dx8.D3DXVec2CatmullRom +@ stdcall D3DXVec2Hermite(ptr ptr ptr ptr ptr long) d3dx8.D3DXVec2Hermite +@ stdcall D3DXVec2Normalize(ptr ptr) d3dx8.D3DXVec2Normalize +@ stdcall D3DXVec2Transform(ptr ptr ptr) d3dx8.D3DXVec2Transform @ stdcall D3DXVec2TransformArray(ptr long ptr long ptr long) -@ stdcall D3DXVec2TransformCoord(ptr ptr ptr) +@ stdcall D3DXVec2TransformCoord(ptr ptr ptr) d3dx8.D3DXVec2TransformCoord @ stdcall D3DXVec2TransformCoordArray(ptr long ptr long ptr long) -@ stdcall D3DXVec2TransformNormal(ptr ptr ptr) +@ stdcall D3DXVec2TransformNormal(ptr ptr ptr) d3dx8.D3DXVec2TransformNormal @ stdcall D3DXVec2TransformNormalArray(ptr long ptr long ptr long) -@ stdcall D3DXVec3BaryCentric(ptr ptr ptr ptr long long) -@ stdcall D3DXVec3CatmullRom(ptr ptr ptr ptr ptr long) -@ stdcall D3DXVec3Hermite(ptr ptr ptr ptr ptr long) -@ stdcall D3DXVec3Normalize(ptr ptr) -@ stdcall D3DXVec3Project(ptr ptr ptr ptr ptr ptr) +@ stdcall D3DXVec3BaryCentric(ptr ptr ptr ptr long long) d3dx8.D3DXVec3BaryCentric +@ stdcall D3DXVec3CatmullRom(ptr ptr ptr ptr ptr long) d3dx8.D3DXVec3CatmullRom +@ stdcall D3DXVec3Hermite(ptr ptr ptr ptr ptr long) d3dx8.D3DXVec3Hermite +@ stdcall D3DXVec3Normalize(ptr ptr) d3dx8.D3DXVec3Normalize +@ stdcall D3DXVec3Project(ptr ptr ptr ptr ptr ptr) d3dx8.D3DXVec3Project @ stdcall D3DXVec3ProjectArray(ptr long ptr long ptr ptr ptr ptr long) -@ stdcall D3DXVec3Transform(ptr ptr ptr) +@ stdcall D3DXVec3Transform(ptr ptr ptr) d3dx8.D3DXVec3Transform @ stdcall D3DXVec3TransformArray(ptr long ptr long ptr long) -@ stdcall D3DXVec3TransformCoord(ptr ptr ptr) +@ stdcall D3DXVec3TransformCoord(ptr ptr ptr) d3dx8.D3DXVec3TransformCoord @ stdcall D3DXVec3TransformCoordArray(ptr long ptr long ptr long) -@ stdcall D3DXVec3TransformNormal(ptr ptr ptr) +@ stdcall D3DXVec3TransformNormal(ptr ptr ptr) d3dx8.D3DXVec3TransformNormal @ stdcall D3DXVec3TransformNormalArray(ptr long ptr long ptr long) -@ stdcall D3DXVec3Unproject(ptr ptr ptr ptr ptr ptr) +@ stdcall D3DXVec3Unproject(ptr ptr ptr ptr ptr ptr) d3dx8.D3DXVec3Unproject @ stdcall D3DXVec3UnprojectArray(ptr long ptr long ptr ptr ptr ptr long) -@ stdcall D3DXVec4BaryCentric(ptr ptr ptr ptr long long) -@ stdcall D3DXVec4CatmullRom(ptr ptr ptr ptr ptr long) -@ stdcall D3DXVec4Cross(ptr ptr ptr ptr) -@ stdcall D3DXVec4Hermite(ptr ptr ptr ptr ptr long) -@ stdcall D3DXVec4Normalize(ptr ptr) -@ stdcall D3DXVec4Transform(ptr ptr ptr) +@ stdcall D3DXVec4BaryCentric(ptr ptr ptr ptr long long) d3dx8.D3DXVec4BaryCentric +@ stdcall D3DXVec4CatmullRom(ptr ptr ptr ptr ptr long) d3dx8.D3DXVec4CatmullRom +@ stdcall D3DXVec4Cross(ptr ptr ptr ptr) d3dx8.D3DXVec4Cross +@ stdcall D3DXVec4Hermite(ptr ptr ptr ptr ptr long) d3dx8.D3DXVec4Hermite +@ stdcall D3DXVec4Normalize(ptr ptr) d3dx8.D3DXVec4Normalize +@ stdcall D3DXVec4Transform(ptr ptr ptr) d3dx8.D3DXVec4Transform @ stdcall D3DXVec4TransformArray(ptr long ptr long ptr long) @ stub D3DXWeldVertices diff --git a/dlls/d3dx9_36/d3dx9_36_private.h b/dlls/d3dx9_36/d3dx9_36_private.h index 8568366d277..a2b0698e488 100644 --- a/dlls/d3dx9_36/d3dx9_36_private.h +++ b/dlls/d3dx9_36/d3dx9_36_private.h @@ -1,6 +1,4 @@ /* - * Copyright (C) 2002 Raphael Junqueira - * Copyright (C) 2008 David Adam * Copyright (C) 2008 Tony Wasserka * * This library is free software; you can redistribute it and/or @@ -34,20 +32,6 @@ HRESULT map_view_of_file(LPCWSTR filename, LPVOID *buffer, DWORD *length); HRESULT load_resource_into_memory(HMODULE module, HRSRC resinfo, LPVOID *buffer, DWORD *length); -extern const ID3DXBufferVtbl D3DXBuffer_Vtbl; - -/* ID3DXBUFFER */ -typedef struct ID3DXBufferImpl -{ - /* IUnknown fields */ - const ID3DXBufferVtbl *lpVtbl; - LONG ref; - - /* ID3DXBuffer fields */ - DWORD *buffer; - DWORD bufferSize; -} ID3DXBufferImpl; - /* ID3DXFont */ typedef struct ID3DXFontImpl @@ -57,25 +41,8 @@ typedef struct ID3DXFontImpl LONG ref; /* ID3DXFont fields */ - IDirect3DDevice9 *device; - D3DXFONT_DESCW desc; - - HDC hdc; - HFONT hfont; } ID3DXFontImpl; -/* ID3DXMatrixStack */ -typedef struct ID3DXMatrixStackImpl -{ - /* IUnknown fields */ - const ID3DXMatrixStackVtbl *lpVtbl; - LONG ref; - - /* ID3DXMatrixStack fields */ - unsigned int current; - unsigned int stack_size; - D3DXMATRIX *stack; -} ID3DXMatrixStackImpl; /*ID3DXSprite */ typedef struct _SPRITE { diff --git a/dlls/d3dx9_36/font.c b/dlls/d3dx9_36/font.c index 98b4fe9557f..46d0fde3119 100644 --- a/dlls/d3dx9_36/font.c +++ b/dlls/d3dx9_36/font.c @@ -55,9 +55,6 @@ static ULONG WINAPI ID3DXFontImpl_Release(LPD3DXFONT iface) TRACE("(%p): ReleaseRef to %d\n", This, ref); if(ref==0) { - DeleteObject(This->hfont); - DeleteDC(This->hdc); - IDirect3DDevice9_Release(This->device); HeapFree(GetProcessHeap(), 0, This); } return ref; @@ -66,57 +63,43 @@ static ULONG WINAPI ID3DXFontImpl_Release(LPD3DXFONT iface) static HRESULT WINAPI ID3DXFontImpl_GetDevice(LPD3DXFONT iface, LPDIRECT3DDEVICE9 *device) { ID3DXFontImpl *This=(ID3DXFontImpl*)iface; - TRACE("(%p)\n", This); - - if( !device ) return D3DERR_INVALIDCALL; - *device = This->device; - IDirect3DDevice9_AddRef(This->device); - + FIXME("(%p): stub\n", This); return D3D_OK; } static HRESULT WINAPI ID3DXFontImpl_GetDescA(LPD3DXFONT iface, D3DXFONT_DESCA *desc) { ID3DXFontImpl *This=(ID3DXFontImpl*)iface; - TRACE("(%p)\n", This); - - if( !desc ) return D3DERR_INVALIDCALL; - memcpy(desc, &This->desc, FIELD_OFFSET(D3DXFONT_DESCA, FaceName)); - WideCharToMultiByte(CP_ACP, 0, This->desc.FaceName, -1, desc->FaceName, sizeof(desc->FaceName) / sizeof(CHAR), NULL, NULL); - + FIXME("(%p): stub\n", This); return D3D_OK; } static HRESULT WINAPI ID3DXFontImpl_GetDescW(LPD3DXFONT iface, D3DXFONT_DESCW *desc) { ID3DXFontImpl *This=(ID3DXFontImpl*)iface; - TRACE("(%p)\n", This); - - if( !desc ) return D3DERR_INVALIDCALL; - *desc = This->desc; - + FIXME("(%p): stub\n", This); return D3D_OK; } static BOOL WINAPI ID3DXFontImpl_GetTextMetricsA(LPD3DXFONT iface, TEXTMETRICA *metrics) { ID3DXFontImpl *This=(ID3DXFontImpl*)iface; - TRACE("(%p)\n", This); - return GetTextMetricsA(This->hdc, metrics); + FIXME("(%p): stub\n", This); + return FALSE; } static BOOL WINAPI ID3DXFontImpl_GetTextMetricsW(LPD3DXFONT iface, TEXTMETRICW *metrics) { ID3DXFontImpl *This=(ID3DXFontImpl*)iface; - TRACE("(%p)\n", This); - return GetTextMetricsW(This->hdc, metrics); + FIXME("(%p): stub\n", This); + return FALSE; } static HDC WINAPI ID3DXFontImpl_GetDC(LPD3DXFONT iface) { ID3DXFontImpl *This=(ID3DXFontImpl*)iface; - TRACE("(%p)\n", This); - return This->hdc; + FIXME("(%p): stub\n", This); + return NULL; } static HRESULT WINAPI ID3DXFontImpl_GetGlyphData(LPD3DXFONT iface, UINT glyph, LPDIRECT3DTEXTURE9 *texture, RECT *blackbox, POINT *cellinc) @@ -211,7 +194,7 @@ HRESULT WINAPI D3DXCreateFontA(LPDIRECT3DDEVICE9 device, INT height, UINT width, { D3DXFONT_DESCA desc; - if( !device || !font ) return D3DERR_INVALIDCALL; + if(!facename) return D3DXERR_INVALIDDATA; desc.Height=height; desc.Width=width; @@ -222,8 +205,7 @@ HRESULT WINAPI D3DXCreateFontA(LPDIRECT3DDEVICE9 device, INT height, UINT width, desc.OutputPrecision=precision; desc.Quality=quality; desc.PitchAndFamily=pitchandfamily; - if(facename != NULL) lstrcpyA(desc.FaceName, facename); - else desc.FaceName[0] = '\0'; + lstrcpyA(desc.FaceName, facename); return D3DXCreateFontIndirectA(device, &desc, font); } @@ -233,7 +215,7 @@ HRESULT WINAPI D3DXCreateFontW(LPDIRECT3DDEVICE9 device, INT height, UINT width, { D3DXFONT_DESCW desc; - if( !device || !font ) return D3DERR_INVALIDCALL; + if(!facename) return D3DXERR_INVALIDDATA; desc.Height=height; desc.Width=width; @@ -244,8 +226,7 @@ HRESULT WINAPI D3DXCreateFontW(LPDIRECT3DDEVICE9 device, INT height, UINT width, desc.OutputPrecision=precision; desc.Quality=quality; desc.PitchAndFamily=pitchandfamily; - if(facename != NULL) strcpyW(desc.FaceName, facename); - else desc.FaceName[0] = '\0'; + strcpyW(desc.FaceName, facename); return D3DXCreateFontIndirectW(device, &desc, font); } @@ -257,7 +238,8 @@ HRESULT WINAPI D3DXCreateFontIndirectA(LPDIRECT3DDEVICE9 device, CONST D3DXFONT_ { D3DXFONT_DESCW widedesc; - if( !device || !desc || !font ) return D3DERR_INVALIDCALL; + if(!desc) return D3DERR_INVALIDCALL; + if(!desc->FaceName) return D3DERR_INVALIDCALL; /* Copy everything but the last structure member. This requires the two D3DXFONT_DESC structures to be equal until the FaceName member */ @@ -272,25 +254,11 @@ HRESULT WINAPI D3DXCreateFontIndirectA(LPDIRECT3DDEVICE9 device, CONST D3DXFONT_ */ HRESULT WINAPI D3DXCreateFontIndirectW(LPDIRECT3DDEVICE9 device, CONST D3DXFONT_DESCW *desc, LPD3DXFONT *font) { - D3DDEVICE_CREATION_PARAMETERS cpars; - D3DDISPLAYMODE mode; ID3DXFontImpl *object; - IDirect3D9 *d3d; - HRESULT hr; - FIXME("stub\n"); - if( !device || !desc || !font ) return D3DERR_INVALIDCALL; + FIXME("stub\n"); - /* the device MUST support D3DFMT_A8R8G8B8 */ - IDirect3DDevice9_GetDirect3D(device, &d3d); - IDirect3DDevice9_GetCreationParameters(device, &cpars); - IDirect3DDevice9_GetDisplayMode(device, 0, &mode); - hr = IDirect3D9_CheckDeviceFormat(d3d, cpars.AdapterOrdinal, cpars.DeviceType, mode.Format, 0, D3DRTYPE_TEXTURE, D3DFMT_A8R8G8B8); - if(FAILED(hr)) { - IDirect3D9_Release(d3d); - return D3DXERR_INVALIDDATA; - } - IDirect3D9_Release(d3d); + if(!desc) return D3DERR_INVALIDCALL; object=HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(ID3DXFontImpl)); if(object==NULL) { @@ -299,25 +267,7 @@ HRESULT WINAPI D3DXCreateFontIndirectW(LPDIRECT3DDEVICE9 device, CONST D3DXFONT_ } object->lpVtbl=&D3DXFont_Vtbl; object->ref=1; - object->device=device; - object->desc=*desc; - - object->hdc = CreateCompatibleDC(NULL); - if( !object->hdc ) { - HeapFree(GetProcessHeap(), 0, object); - return D3DXERR_INVALIDDATA; - } - - object->hfont = CreateFontW(desc->Height, desc->Width, 0, 0, desc->Weight, desc->Italic, FALSE, FALSE, desc->CharSet, - desc->OutputPrecision, CLIP_DEFAULT_PRECIS, desc->Quality, desc->PitchAndFamily, desc->FaceName); - if( !object->hfont ) { - DeleteDC(object->hdc); - HeapFree(GetProcessHeap(), 0, object); - return D3DXERR_INVALIDDATA; - } - SelectObject(object->hdc, object->hfont); - IDirect3DDevice9_AddRef(device); *font=(LPD3DXFONT)object; return D3D_OK; diff --git a/dlls/d3dx9_36/math.c b/dlls/d3dx9_36/math.c dissimilarity index 87% index c2193c83eba..e73530376be 100644 --- a/dlls/d3dx9_36/math.c +++ b/dlls/d3dx9_36/math.c @@ -1,1755 +1,399 @@ -/* - * Mathematical operations specific to D3DX9. - * - * Copyright (C) 2008 David Adam - * Copyright (C) 2008 Luis Busquets - * Copyright (C) 2008 Jérôme Gardou - * Copyright (C) 2008 Philip Nilsson - * Copyright (C) 2008 Henri Verbeet - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#define NONAMELESSUNION - -#include "config.h" -#include "windef.h" -#include "wingdi.h" -#include "d3dx9_36_private.h" - -#include "wine/debug.h" - -WINE_DEFAULT_DEBUG_CHANNEL(d3dx); - -static const ID3DXMatrixStackVtbl ID3DXMatrixStack_Vtbl; - -/*_________________D3DXColor____________________*/ - -D3DXCOLOR* WINAPI D3DXColorAdjustContrast(D3DXCOLOR *pout, CONST D3DXCOLOR *pc, FLOAT s) -{ - pout->r = 0.5f + s * (pc->r - 0.5f); - pout->g = 0.5f + s * (pc->g - 0.5f); - pout->b = 0.5f + s * (pc->b - 0.5f); - pout->a = pc->a; - return pout; -} - -D3DXCOLOR* WINAPI D3DXColorAdjustSaturation(D3DXCOLOR *pout, CONST D3DXCOLOR *pc, FLOAT s) -{ - FLOAT grey; - - grey = pc->r * 0.2125f + pc->g * 0.7154f + pc->b * 0.0721f; - pout->r = grey + s * (pc->r - grey); - pout->g = grey + s * (pc->g - grey); - pout->b = grey + s * (pc->b - grey); - pout->a = pc->a; - return pout; -} - -/*_________________Misc__________________________*/ - -FLOAT WINAPI D3DXFresnelTerm(FLOAT costheta, FLOAT refractionindex) -{ - FLOAT a, d, g, result; - - g = sqrt(refractionindex * refractionindex + costheta * costheta - 1.0f); - a = g + costheta; - d = g - costheta; - result = ( costheta * a - 1.0f ) * ( costheta * a - 1.0f ) / ( ( costheta * d + 1.0f ) * ( costheta * d + 1.0f ) ) + 1.0f; - result = result * 0.5f * d * d / ( a * a ); - return result; -} - -/*_________________D3DXMatrix____________________*/ - -D3DXMATRIX* WINAPI D3DXMatrixAffineTransformation(D3DXMATRIX *pout, FLOAT scaling, CONST D3DXVECTOR3 *rotationcenter, CONST D3DXQUATERNION *rotation, CONST D3DXVECTOR3 *translation) -{ - D3DXMATRIX m1, m2, m3, m4, m5; - - D3DXMatrixScaling(&m1, scaling, scaling, scaling); - - if ( !rotationcenter ) - { - D3DXMatrixIdentity(&m2); - D3DXMatrixIdentity(&m4); - } - else - { - D3DXMatrixTranslation(&m2, -rotationcenter->x, -rotationcenter->y, -rotationcenter->z); - D3DXMatrixTranslation(&m4, rotationcenter->x, rotationcenter->y, rotationcenter->z); - } - - if ( !rotation ) D3DXMatrixIdentity(&m3); - else D3DXMatrixRotationQuaternion(&m3, rotation); - - if ( !translation ) D3DXMatrixIdentity(&m5); - else D3DXMatrixTranslation(&m5, translation->x, translation->y, translation->z); - - D3DXMatrixMultiply(&m1, &m1, &m2); - D3DXMatrixMultiply(&m1, &m1, &m3); - D3DXMatrixMultiply(&m1, &m1, &m4); - D3DXMatrixMultiply(pout, &m1, &m5); - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixAffineTransformation2D(D3DXMATRIX *pout, FLOAT scaling, CONST D3DXVECTOR2 *protationcenter, FLOAT rotation, CONST D3DXVECTOR2 *ptranslation) -{ - D3DXMATRIX m1, m2, m3, m4, m5; - D3DXQUATERNION rot; - D3DXVECTOR3 rot_center, trans; - - rot.w=cos(rotation/2.0f); - rot.x=0.0f; - rot.y=0.0f; - rot.z=sin(rotation/2.0f); - - if ( protationcenter ) - { - rot_center.x=protationcenter->x; - rot_center.y=protationcenter->y; - rot_center.z=0.0f; - } - else - { - rot_center.x=0.0f; - rot_center.y=0.0f; - rot_center.z=0.0f; - } - - if ( ptranslation ) - { - trans.x=ptranslation->x; - trans.y=ptranslation->y; - trans.z=0.0f; - } - else - { - trans.x=0.0f; - trans.y=0.0f; - trans.z=0.0f; - } - - D3DXMatrixScaling(&m1, scaling, scaling, 1.0f); - D3DXMatrixTranslation(&m2, -rot_center.x, -rot_center.y, -rot_center.z); - D3DXMatrixTranslation(&m4, rot_center.x, rot_center.y, rot_center.z); - D3DXMatrixRotationQuaternion(&m3, &rot); - D3DXMatrixTranslation(&m5, trans.x, trans.y, trans.z); - - D3DXMatrixMultiply(&m1, &m1, &m2); - D3DXMatrixMultiply(&m1, &m1, &m3); - D3DXMatrixMultiply(&m1, &m1, &m4); - D3DXMatrixMultiply(pout, &m1, &m5); - - return pout; -} - -HRESULT WINAPI D3DXMatrixDecompose(D3DXVECTOR3 *poutscale, D3DXQUATERNION *poutrotation, D3DXVECTOR3 *pouttranslation, CONST D3DXMATRIX *pm) -{ - D3DXMATRIX normalized; - D3DXVECTOR3 vec; - - /*Compute the scaling part.*/ - vec.x=pm->u.m[0][0]; - vec.y=pm->u.m[0][1]; - vec.z=pm->u.m[0][2]; - poutscale->x=D3DXVec3Length(&vec); - - vec.x=pm->u.m[1][0]; - vec.y=pm->u.m[1][1]; - vec.z=pm->u.m[1][2]; - poutscale->y=D3DXVec3Length(&vec); - - vec.x=pm->u.m[2][0]; - vec.y=pm->u.m[2][1]; - vec.z=pm->u.m[2][2]; - poutscale->z=D3DXVec3Length(&vec); - - /*Compute the translation part.*/ - pouttranslation->x=pm->u.m[3][0]; - pouttranslation->y=pm->u.m[3][1]; - pouttranslation->z=pm->u.m[3][2]; - - /*Let's calculate the rotation now*/ - if ( (poutscale->x == 0.0f) || (poutscale->y == 0.0f) || (poutscale->z == 0.0f) ) return D3DERR_INVALIDCALL; - - normalized.u.m[0][0]=pm->u.m[0][0]/poutscale->x; - normalized.u.m[0][1]=pm->u.m[0][1]/poutscale->x; - normalized.u.m[0][2]=pm->u.m[0][2]/poutscale->x; - normalized.u.m[1][0]=pm->u.m[1][0]/poutscale->y; - normalized.u.m[1][1]=pm->u.m[1][1]/poutscale->y; - normalized.u.m[1][2]=pm->u.m[1][2]/poutscale->y; - normalized.u.m[2][0]=pm->u.m[2][0]/poutscale->z; - normalized.u.m[2][1]=pm->u.m[2][1]/poutscale->z; - normalized.u.m[2][2]=pm->u.m[2][2]/poutscale->z; - - D3DXQuaternionRotationMatrix(poutrotation,&normalized); - return S_OK; -} - -FLOAT WINAPI D3DXMatrixDeterminant(CONST D3DXMATRIX *pm) -{ - D3DXVECTOR4 minor, v1, v2, v3; - FLOAT det; - - v1.x = pm->u.m[0][0]; v1.y = pm->u.m[1][0]; v1.z = pm->u.m[2][0]; v1.w = pm->u.m[3][0]; - v2.x = pm->u.m[0][1]; v2.y = pm->u.m[1][1]; v2.z = pm->u.m[2][1]; v2.w = pm->u.m[3][1]; - v3.x = pm->u.m[0][2]; v3.y = pm->u.m[1][2]; v3.z = pm->u.m[2][2]; v3.w = pm->u.m[3][2]; - D3DXVec4Cross(&minor, &v1, &v2, &v3); - det = - (pm->u.m[0][3] * minor.x + pm->u.m[1][3] * minor.y + pm->u.m[2][3] * minor.z + pm->u.m[3][3] * minor.w); - return det; -} - -D3DXMATRIX* WINAPI D3DXMatrixInverse(D3DXMATRIX *pout, FLOAT *pdeterminant, CONST D3DXMATRIX *pm) -{ - int a, i, j; - D3DXMATRIX out; - D3DXVECTOR4 v, vec[3]; - FLOAT det; - - det = D3DXMatrixDeterminant(pm); - if ( !det ) return NULL; - if ( pdeterminant ) *pdeterminant = det; - for (i=0; i<4; i++) - { - for (j=0; j<4; j++) - { - if (j != i ) - { - a = j; - if ( j > i ) a = a-1; - vec[a].x = pm->u.m[j][0]; - vec[a].y = pm->u.m[j][1]; - vec[a].z = pm->u.m[j][2]; - vec[a].w = pm->u.m[j][3]; - } - } - D3DXVec4Cross(&v, &vec[0], &vec[1], &vec[2]); - out.u.m[0][i] = pow(-1.0f, i) * v.x / det; - out.u.m[1][i] = pow(-1.0f, i) * v.y / det; - out.u.m[2][i] = pow(-1.0f, i) * v.z / det; - out.u.m[3][i] = pow(-1.0f, i) * v.w / det; - } - - *pout = out; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixLookAtLH(D3DXMATRIX *pout, CONST D3DXVECTOR3 *peye, CONST D3DXVECTOR3 *pat, CONST D3DXVECTOR3 *pup) -{ - D3DXVECTOR3 right, rightn, up, upn, vec, vec2; - - D3DXVec3Subtract(&vec2, pat, peye); - D3DXVec3Normalize(&vec, &vec2); - D3DXVec3Cross(&right, pup, &vec); - D3DXVec3Cross(&up, &vec, &right); - D3DXVec3Normalize(&rightn, &right); - D3DXVec3Normalize(&upn, &up); - pout->u.m[0][0] = rightn.x; - pout->u.m[1][0] = rightn.y; - pout->u.m[2][0] = rightn.z; - pout->u.m[3][0] = -D3DXVec3Dot(&rightn,peye); - pout->u.m[0][1] = upn.x; - pout->u.m[1][1] = upn.y; - pout->u.m[2][1] = upn.z; - pout->u.m[3][1] = -D3DXVec3Dot(&upn, peye); - pout->u.m[0][2] = vec.x; - pout->u.m[1][2] = vec.y; - pout->u.m[2][2] = vec.z; - pout->u.m[3][2] = -D3DXVec3Dot(&vec, peye); - pout->u.m[0][3] = 0.0f; - pout->u.m[1][3] = 0.0f; - pout->u.m[2][3] = 0.0f; - pout->u.m[3][3] = 1.0f; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixLookAtRH(D3DXMATRIX *pout, CONST D3DXVECTOR3 *peye, CONST D3DXVECTOR3 *pat, CONST D3DXVECTOR3 *pup) -{ - D3DXVECTOR3 right, rightn, up, upn, vec, vec2; - - D3DXVec3Subtract(&vec2, pat, peye); - D3DXVec3Normalize(&vec, &vec2); - D3DXVec3Cross(&right, pup, &vec); - D3DXVec3Cross(&up, &vec, &right); - D3DXVec3Normalize(&rightn, &right); - D3DXVec3Normalize(&upn, &up); - pout->u.m[0][0] = -rightn.x; - pout->u.m[1][0] = -rightn.y; - pout->u.m[2][0] = -rightn.z; - pout->u.m[3][0] = D3DXVec3Dot(&rightn,peye); - pout->u.m[0][1] = upn.x; - pout->u.m[1][1] = upn.y; - pout->u.m[2][1] = upn.z; - pout->u.m[3][1] = -D3DXVec3Dot(&upn, peye); - pout->u.m[0][2] = -vec.x; - pout->u.m[1][2] = -vec.y; - pout->u.m[2][2] = -vec.z; - pout->u.m[3][2] = D3DXVec3Dot(&vec, peye); - pout->u.m[0][3] = 0.0f; - pout->u.m[1][3] = 0.0f; - pout->u.m[2][3] = 0.0f; - pout->u.m[3][3] = 1.0f; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixMultiply(D3DXMATRIX *pout, CONST D3DXMATRIX *pm1, CONST D3DXMATRIX *pm2) -{ - D3DXMATRIX out; - int i,j; - - for (i=0; i<4; i++) - { - for (j=0; j<4; j++) - { - out.u.m[i][j] = pm1->u.m[i][0] * pm2->u.m[0][j] + pm1->u.m[i][1] * pm2->u.m[1][j] + pm1->u.m[i][2] * pm2->u.m[2][j] + pm1->u.m[i][3] * pm2->u.m[3][j]; - } - } - - *pout = out; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixMultiplyTranspose(D3DXMATRIX *pout, CONST D3DXMATRIX *pm1, CONST D3DXMATRIX *pm2) -{ - D3DXMatrixMultiply(pout, pm1, pm2); - D3DXMatrixTranspose(pout, pout); - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixOrthoLH(D3DXMATRIX *pout, FLOAT w, FLOAT h, FLOAT zn, FLOAT zf) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = 2.0f / w; - pout->u.m[1][1] = 2.0f / h; - pout->u.m[2][2] = 1.0f / (zf - zn); - pout->u.m[3][2] = zn / (zn - zf); - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixOrthoOffCenterLH(D3DXMATRIX *pout, FLOAT l, FLOAT r, FLOAT b, FLOAT t, FLOAT zn, FLOAT zf) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = 2.0f / (r - l); - pout->u.m[1][1] = 2.0f / (t - b); - pout->u.m[2][2] = 1.0f / (zf -zn); - pout->u.m[3][0] = -1.0f -2.0f *l / (r - l); - pout->u.m[3][1] = 1.0f + 2.0f * t / (b - t); - pout->u.m[3][2] = zn / (zn -zf); - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixOrthoOffCenterRH(D3DXMATRIX *pout, FLOAT l, FLOAT r, FLOAT b, FLOAT t, FLOAT zn, FLOAT zf) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = 2.0f / (r - l); - pout->u.m[1][1] = 2.0f / (t - b); - pout->u.m[2][2] = 1.0f / (zn -zf); - pout->u.m[3][0] = -1.0f -2.0f *l / (r - l); - pout->u.m[3][1] = 1.0f + 2.0f * t / (b - t); - pout->u.m[3][2] = zn / (zn -zf); - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixOrthoRH(D3DXMATRIX *pout, FLOAT w, FLOAT h, FLOAT zn, FLOAT zf) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = 2.0f / w; - pout->u.m[1][1] = 2.0f / h; - pout->u.m[2][2] = 1.0f / (zn - zf); - pout->u.m[3][2] = zn / (zn - zf); - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixPerspectiveFovLH(D3DXMATRIX *pout, FLOAT fovy, FLOAT aspect, FLOAT zn, FLOAT zf) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = 1.0f / (aspect * tan(fovy/2.0f)); - pout->u.m[1][1] = 1.0f / tan(fovy/2.0f); - pout->u.m[2][2] = zf / (zf - zn); - pout->u.m[2][3] = 1.0f; - pout->u.m[3][2] = (zf * zn) / (zn - zf); - pout->u.m[3][3] = 0.0f; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixPerspectiveFovRH(D3DXMATRIX *pout, FLOAT fovy, FLOAT aspect, FLOAT zn, FLOAT zf) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = 1.0f / (aspect * tan(fovy/2.0f)); - pout->u.m[1][1] = 1.0f / tan(fovy/2.0f); - pout->u.m[2][2] = zf / (zn - zf); - pout->u.m[2][3] = -1.0f; - pout->u.m[3][2] = (zf * zn) / (zn - zf); - pout->u.m[3][3] = 0.0f; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixPerspectiveLH(D3DXMATRIX *pout, FLOAT w, FLOAT h, FLOAT zn, FLOAT zf) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = 2.0f * zn / w; - pout->u.m[1][1] = 2.0f * zn / h; - pout->u.m[2][2] = zf / (zf - zn); - pout->u.m[3][2] = (zn * zf) / (zn - zf); - pout->u.m[2][3] = 1.0f; - pout->u.m[3][3] = 0.0f; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixPerspectiveOffCenterLH(D3DXMATRIX *pout, FLOAT l, FLOAT r, FLOAT b, FLOAT t, FLOAT zn, FLOAT zf) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = 2.0f * zn / (r - l); - pout->u.m[1][1] = -2.0f * zn / (b - t); - pout->u.m[2][0] = -1.0f - 2.0f * l / (r - l); - pout->u.m[2][1] = 1.0f + 2.0f * t / (b - t); - pout->u.m[2][2] = - zf / (zn - zf); - pout->u.m[3][2] = (zn * zf) / (zn -zf); - pout->u.m[2][3] = 1.0f; - pout->u.m[3][3] = 0.0f; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixPerspectiveOffCenterRH(D3DXMATRIX *pout, FLOAT l, FLOAT r, FLOAT b, FLOAT t, FLOAT zn, FLOAT zf) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = 2.0f * zn / (r - l); - pout->u.m[1][1] = -2.0f * zn / (b - t); - pout->u.m[2][0] = 1.0f + 2.0f * l / (r - l); - pout->u.m[2][1] = -1.0f -2.0f * t / (b - t); - pout->u.m[2][2] = zf / (zn - zf); - pout->u.m[3][2] = (zn * zf) / (zn -zf); - pout->u.m[2][3] = -1.0f; - pout->u.m[3][3] = 0.0f; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixPerspectiveRH(D3DXMATRIX *pout, FLOAT w, FLOAT h, FLOAT zn, FLOAT zf) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = 2.0f * zn / w; - pout->u.m[1][1] = 2.0f * zn / h; - pout->u.m[2][2] = zf / (zn - zf); - pout->u.m[3][2] = (zn * zf) / (zn - zf); - pout->u.m[2][3] = -1.0f; - pout->u.m[3][3] = 0.0f; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixReflect(D3DXMATRIX *pout, CONST D3DXPLANE *pplane) -{ - D3DXPLANE Nplane; - - D3DXPlaneNormalize(&Nplane, pplane); - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = 1.0f - 2.0f * Nplane.a * Nplane.a; - pout->u.m[0][1] = -2.0f * Nplane.a * Nplane.b; - pout->u.m[0][2] = -2.0f * Nplane.a * Nplane.c; - pout->u.m[1][0] = -2.0f * Nplane.a * Nplane.b; - pout->u.m[1][1] = 1.0f - 2.0f * Nplane.b * Nplane.b; - pout->u.m[1][2] = -2.0f * Nplane.b * Nplane.c; - pout->u.m[2][0] = -2.0f * Nplane.c * Nplane.a; - pout->u.m[2][1] = -2.0f * Nplane.c * Nplane.b; - pout->u.m[2][2] = 1.0f - 2.0f * Nplane.c * Nplane.c; - pout->u.m[3][0] = -2.0f * Nplane.d * Nplane.a; - pout->u.m[3][1] = -2.0f * Nplane.d * Nplane.b; - pout->u.m[3][2] = -2.0f * Nplane.d * Nplane.c; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixRotationAxis(D3DXMATRIX *pout, CONST D3DXVECTOR3 *pv, FLOAT angle) -{ - D3DXVECTOR3 v; - - D3DXVec3Normalize(&v,pv); - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = (1.0f - cos(angle)) * v.x * v.x + cos(angle); - pout->u.m[1][0] = (1.0f - cos(angle)) * v.x * v.y - sin(angle) * v.z; - pout->u.m[2][0] = (1.0f - cos(angle)) * v.x * v.z + sin(angle) * v.y; - pout->u.m[0][1] = (1.0f - cos(angle)) * v.y * v.x + sin(angle) * v.z; - pout->u.m[1][1] = (1.0f - cos(angle)) * v.y * v.y + cos(angle); - pout->u.m[2][1] = (1.0f - cos(angle)) * v.y * v.z - sin(angle) * v.x; - pout->u.m[0][2] = (1.0f - cos(angle)) * v.z * v.x - sin(angle) * v.y; - pout->u.m[1][2] = (1.0f - cos(angle)) * v.z * v.y + sin(angle) * v.x; - pout->u.m[2][2] = (1.0f - cos(angle)) * v.z * v.z + cos(angle); - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixRotationQuaternion(D3DXMATRIX *pout, CONST D3DXQUATERNION *pq) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = 1.0f - 2.0f * (pq->y * pq->y + pq->z * pq->z); - pout->u.m[0][1] = 2.0f * (pq->x *pq->y + pq->z * pq->w); - pout->u.m[0][2] = 2.0f * (pq->x * pq->z - pq->y * pq->w); - pout->u.m[1][0] = 2.0f * (pq->x * pq->y - pq->z * pq->w); - pout->u.m[1][1] = 1.0f - 2.0f * (pq->x * pq->x + pq->z * pq->z); - pout->u.m[1][2] = 2.0f * (pq->y *pq->z + pq->x *pq->w); - pout->u.m[2][0] = 2.0f * (pq->x * pq->z + pq->y * pq->w); - pout->u.m[2][1] = 2.0f * (pq->y *pq->z - pq->x *pq->w); - pout->u.m[2][2] = 1.0f - 2.0f * (pq->x * pq->x + pq->y * pq->y); - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixRotationX(D3DXMATRIX *pout, FLOAT angle) -{ - D3DXMatrixIdentity(pout); - pout->u.m[1][1] = cos(angle); - pout->u.m[2][2] = cos(angle); - pout->u.m[1][2] = sin(angle); - pout->u.m[2][1] = -sin(angle); - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixRotationY(D3DXMATRIX *pout, FLOAT angle) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = cos(angle); - pout->u.m[2][2] = cos(angle); - pout->u.m[0][2] = -sin(angle); - pout->u.m[2][0] = sin(angle); - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixRotationYawPitchRoll(D3DXMATRIX *pout, FLOAT yaw, FLOAT pitch, FLOAT roll) -{ - D3DXMATRIX m; - - D3DXMatrixIdentity(pout); - D3DXMatrixRotationZ(&m, roll); - D3DXMatrixMultiply(pout, pout, &m); - D3DXMatrixRotationX(&m, pitch); - D3DXMatrixMultiply(pout, pout, &m); - D3DXMatrixRotationY(&m, yaw); - D3DXMatrixMultiply(pout, pout, &m); - return pout; -} -D3DXMATRIX* WINAPI D3DXMatrixRotationZ(D3DXMATRIX *pout, FLOAT angle) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = cos(angle); - pout->u.m[1][1] = cos(angle); - pout->u.m[0][1] = sin(angle); - pout->u.m[1][0] = -sin(angle); - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixScaling(D3DXMATRIX *pout, FLOAT sx, FLOAT sy, FLOAT sz) -{ - D3DXMatrixIdentity(pout); - pout->u.m[0][0] = sx; - pout->u.m[1][1] = sy; - pout->u.m[2][2] = sz; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixShadow(D3DXMATRIX *pout, CONST D3DXVECTOR4 *plight, CONST D3DXPLANE *pplane) -{ - D3DXPLANE Nplane; - FLOAT dot; - - D3DXPlaneNormalize(&Nplane, pplane); - dot = D3DXPlaneDot(&Nplane, plight); - pout->u.m[0][0] = dot - Nplane.a * plight->x; - pout->u.m[0][1] = -Nplane.a * plight->y; - pout->u.m[0][2] = -Nplane.a * plight->z; - pout->u.m[0][3] = -Nplane.a * plight->w; - pout->u.m[1][0] = -Nplane.b * plight->x; - pout->u.m[1][1] = dot - Nplane.b * plight->y; - pout->u.m[1][2] = -Nplane.b * plight->z; - pout->u.m[1][3] = -Nplane.b * plight->w; - pout->u.m[2][0] = -Nplane.c * plight->x; - pout->u.m[2][1] = -Nplane.c * plight->y; - pout->u.m[2][2] = dot - Nplane.c * plight->z; - pout->u.m[2][3] = -Nplane.c * plight->w; - pout->u.m[3][0] = -Nplane.d * plight->x; - pout->u.m[3][1] = -Nplane.d * plight->y; - pout->u.m[3][2] = -Nplane.d * plight->z; - pout->u.m[3][3] = dot - Nplane.d * plight->w; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixTransformation(D3DXMATRIX *pout, CONST D3DXVECTOR3 *pscalingcenter, CONST D3DXQUATERNION *pscalingrotation, CONST D3DXVECTOR3 *pscaling, CONST D3DXVECTOR3 *protationcenter, CONST D3DXQUATERNION *protation, CONST D3DXVECTOR3 *ptranslation) -{ - D3DXMATRIX m1, m2, m3, m4, m5, m6, m7; - D3DXQUATERNION prc; - D3DXVECTOR3 psc, pt; - - if ( !pscalingcenter ) - { - psc.x = 0.0f; - psc.y = 0.0f; - psc.z = 0.0f; - } - else - { - psc.x = pscalingcenter->x; - psc.y = pscalingcenter->y; - psc.z = pscalingcenter->z; - } - - if ( !protationcenter ) - { - prc.x = 0.0f; - prc.y = 0.0f; - prc.z = 0.0f; - } - else - { - prc.x = protationcenter->x; - prc.y = protationcenter->y; - prc.z = protationcenter->z; - } - - if ( !ptranslation ) - { - pt.x = 0.0f; - pt.y = 0.0f; - pt.z = 0.0f; - } - else - { - pt.x = ptranslation->x; - pt.y = ptranslation->y; - pt.z = ptranslation->z; - } - - D3DXMatrixTranslation(&m1, -psc.x, -psc.y, -psc.z); - - if ( !pscalingrotation ) - { - D3DXMatrixIdentity(&m2); - D3DXMatrixIdentity(&m4); - } - else - { - D3DXMatrixRotationQuaternion(&m4, pscalingrotation); - D3DXMatrixInverse(&m2, NULL, &m4); - } - - if ( !pscaling ) D3DXMatrixIdentity(&m3); - else D3DXMatrixScaling(&m3, pscaling->x, pscaling->y, pscaling->z); - - if ( !protation ) D3DXMatrixIdentity(&m6); - else D3DXMatrixRotationQuaternion(&m6, protation); - - D3DXMatrixTranslation(&m5, psc.x - prc.x, psc.y - prc.y, psc.z - prc.z); - D3DXMatrixTranslation(&m7, prc.x + pt.x, prc.y + pt.y, prc.z + pt.z); - D3DXMatrixMultiply(&m1, &m1, &m2); - D3DXMatrixMultiply(&m1, &m1, &m3); - D3DXMatrixMultiply(&m1, &m1, &m4); - D3DXMatrixMultiply(&m1, &m1, &m5); - D3DXMatrixMultiply(&m1, &m1, &m6); - D3DXMatrixMultiply(pout, &m1, &m7); - return pout; -} -D3DXMATRIX* WINAPI D3DXMatrixTransformation2D(D3DXMATRIX *pout, CONST D3DXVECTOR2 *pscalingcenter, FLOAT scalingrotation, CONST D3DXVECTOR2 *pscaling, CONST D3DXVECTOR2 *protationcenter, FLOAT rotation, CONST D3DXVECTOR2 *ptranslation) -{ - D3DXQUATERNION rot, sca_rot; - D3DXVECTOR3 rot_center, sca, sca_center, trans; - - if ( pscalingcenter ) - { - sca_center.x=pscalingcenter->x; - sca_center.y=pscalingcenter->y; - sca_center.z=0.0f; - } - else - { - sca_center.x=0.0f; - sca_center.y=0.0f; - sca_center.z=0.0f; - } - - if ( pscaling ) - { - sca.x=pscaling->x; - sca.y=pscaling->y; - sca.z=1.0f; - } - else - { - sca.x=1.0f; - sca.y=1.0f; - sca.z=1.0f; - } - - if ( protationcenter ) - { - rot_center.x=protationcenter->x; - rot_center.y=protationcenter->y; - rot_center.z=0.0f; - } - else - { - rot_center.x=0.0f; - rot_center.y=0.0f; - rot_center.z=0.0f; - } - - if ( ptranslation ) - { - trans.x=ptranslation->x; - trans.y=ptranslation->y; - trans.z=0.0f; - } - else - { - trans.x=0.0f; - trans.y=0.0f; - trans.z=0.0f; - } - - rot.w=cos(rotation/2.0f); - rot.x=0.0f; - rot.y=0.0f; - rot.z=sin(rotation/2.0f); - - sca_rot.w=cos(scalingrotation/2.0f); - sca_rot.x=0.0f; - sca_rot.y=0.0f; - sca_rot.z=sin(scalingrotation/2.0f); - - D3DXMatrixTransformation(pout, &sca_center, &sca_rot, &sca, &rot_center, &rot, &trans); - - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixTranslation(D3DXMATRIX *pout, FLOAT x, FLOAT y, FLOAT z) -{ - D3DXMatrixIdentity(pout); - pout->u.m[3][0] = x; - pout->u.m[3][1] = y; - pout->u.m[3][2] = z; - return pout; -} - -D3DXMATRIX* WINAPI D3DXMatrixTranspose(D3DXMATRIX *pout, CONST D3DXMATRIX *pm) -{ - CONST D3DXMATRIX m = *pm; - int i,j; - - for (i=0; i<4; i++) - for (j=0; j<4; j++) pout->u.m[i][j] = m.u.m[j][i]; - - return pout; -} - -/*_________________D3DXMatrixStack____________________*/ - -static const unsigned int INITIAL_STACK_SIZE = 32; - -HRESULT WINAPI D3DXCreateMatrixStack(DWORD flags, LPD3DXMATRIXSTACK* ppstack) -{ - ID3DXMatrixStackImpl* object; - - TRACE("flags %#x, ppstack %p\n", flags, ppstack); - - object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(ID3DXMatrixStackImpl)); - if ( object == NULL ) - { - *ppstack = NULL; - return E_OUTOFMEMORY; - } - object->lpVtbl = &ID3DXMatrixStack_Vtbl; - object->ref = 1; - - object->stack = HeapAlloc(GetProcessHeap(), 0, INITIAL_STACK_SIZE * sizeof(D3DXMATRIX)); - if (!object->stack) - { - HeapFree(GetProcessHeap(), 0, object); - *ppstack = NULL; - return E_OUTOFMEMORY; - } - - object->current = 0; - object->stack_size = INITIAL_STACK_SIZE; - D3DXMatrixIdentity(&object->stack[0]); - - TRACE("Created matrix stack %p\n", object); - - *ppstack = (LPD3DXMATRIXSTACK)object; - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_QueryInterface(ID3DXMatrixStack *iface, REFIID riid, void **ppobj) -{ - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - if (IsEqualGUID(riid, &IID_IUnknown) || IsEqualGUID(riid, &IID_ID3DXMatrixStack)) - { - ID3DXMatrixStack_AddRef(iface); - *ppobj = This; - return S_OK; - } - *ppobj = NULL; - ERR("(%p)->(%s,%p),not found\n",This,debugstr_guid(riid),ppobj); - return E_NOINTERFACE; -} - -static ULONG WINAPI ID3DXMatrixStackImpl_AddRef(ID3DXMatrixStack *iface) -{ - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - ULONG ref = InterlockedIncrement(&This->ref); - TRACE("(%p) : AddRef from %d\n", This, ref - 1); - return ref; -} - -static ULONG WINAPI ID3DXMatrixStackImpl_Release(ID3DXMatrixStack* iface) -{ - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - ULONG ref = InterlockedDecrement(&This->ref); - if (!ref) - { - HeapFree(GetProcessHeap(), 0, This->stack); - HeapFree(GetProcessHeap(), 0, This); - } - TRACE("(%p) : ReleaseRef to %d\n", This, ref); - return ref; -} - -static D3DXMATRIX* WINAPI ID3DXMatrixStackImpl_GetTop(ID3DXMatrixStack *iface) -{ - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - return &This->stack[This->current]; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_LoadIdentity(ID3DXMatrixStack *iface) -{ - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - D3DXMatrixIdentity(&This->stack[This->current]); - - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_LoadMatrix(ID3DXMatrixStack *iface, CONST D3DXMATRIX *pm) -{ - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - This->stack[This->current] = *pm; - - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_MultMatrix(ID3DXMatrixStack *iface, CONST D3DXMATRIX *pm) -{ - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - D3DXMatrixMultiply(&This->stack[This->current], &This->stack[This->current], pm); - - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_MultMatrixLocal(ID3DXMatrixStack *iface, CONST D3DXMATRIX *pm) -{ - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - D3DXMatrixMultiply(&This->stack[This->current], pm, &This->stack[This->current]); - - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_Pop(ID3DXMatrixStack *iface) -{ - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - /* Popping the last element on the stack returns D3D_OK, but does nothing. */ - if (!This->current) return D3D_OK; - - if (This->current <= This->stack_size / 4 && This->stack_size >= INITIAL_STACK_SIZE * 2) - { - unsigned int new_size; - D3DXMATRIX *new_stack; - - new_size = This->stack_size / 2; - new_stack = HeapReAlloc(GetProcessHeap(), 0, This->stack, new_size * sizeof(D3DXMATRIX)); - if (new_stack) - { - This->stack_size = new_size; - This->stack = new_stack; - } - } - - --This->current; - - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_Push(ID3DXMatrixStack *iface) -{ - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - if (This->current == This->stack_size - 1) - { - unsigned int new_size; - D3DXMATRIX *new_stack; - - if (This->stack_size > UINT_MAX / 2) return E_OUTOFMEMORY; - - new_size = This->stack_size * 2; - new_stack = HeapReAlloc(GetProcessHeap(), 0, This->stack, new_size * sizeof(D3DXMATRIX)); - if (!new_stack) return E_OUTOFMEMORY; - - This->stack_size = new_size; - This->stack = new_stack; - } - - ++This->current; - This->stack[This->current] = This->stack[This->current - 1]; - - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_RotateAxis(ID3DXMatrixStack *iface, CONST D3DXVECTOR3 *pv, FLOAT angle) -{ - D3DXMATRIX temp; - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - D3DXMatrixRotationAxis(&temp, pv, angle); - D3DXMatrixMultiply(&This->stack[This->current], &This->stack[This->current], &temp); - - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_RotateAxisLocal(ID3DXMatrixStack *iface, CONST D3DXVECTOR3 *pv, FLOAT angle) -{ - D3DXMATRIX temp; - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - D3DXMatrixRotationAxis(&temp, pv, angle); - D3DXMatrixMultiply(&This->stack[This->current], &temp, &This->stack[This->current]); - - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_RotateYawPitchRoll(ID3DXMatrixStack *iface, FLOAT x, FLOAT y, FLOAT z) -{ - D3DXMATRIX temp; - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - D3DXMatrixRotationYawPitchRoll(&temp, x, y, z); - D3DXMatrixMultiply(&This->stack[This->current], &This->stack[This->current], &temp); - - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_RotateYawPitchRollLocal(ID3DXMatrixStack *iface, FLOAT x, FLOAT y, FLOAT z) -{ - D3DXMATRIX temp; - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - D3DXMatrixRotationYawPitchRoll(&temp, x, y, z); - D3DXMatrixMultiply(&This->stack[This->current], &temp, &This->stack[This->current]); - - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_Scale(ID3DXMatrixStack *iface, FLOAT x, FLOAT y, FLOAT z) -{ - D3DXMATRIX temp; - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - D3DXMatrixScaling(&temp, x, y, z); - D3DXMatrixMultiply(&This->stack[This->current], &This->stack[This->current], &temp); - - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_ScaleLocal(ID3DXMatrixStack *iface, FLOAT x, FLOAT y, FLOAT z) -{ - D3DXMATRIX temp; - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - D3DXMatrixScaling(&temp, x, y, z); - D3DXMatrixMultiply(&This->stack[This->current], &temp, &This->stack[This->current]); - - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_Translate(ID3DXMatrixStack *iface, FLOAT x, FLOAT y, FLOAT z) -{ - D3DXMATRIX temp; - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - D3DXMatrixTranslation(&temp, x, y, z); - D3DXMatrixMultiply(&This->stack[This->current], &This->stack[This->current], &temp); - - return D3D_OK; -} - -static HRESULT WINAPI ID3DXMatrixStackImpl_TranslateLocal(ID3DXMatrixStack *iface, FLOAT x, FLOAT y, FLOAT z) -{ - D3DXMATRIX temp; - ID3DXMatrixStackImpl *This = (ID3DXMatrixStackImpl *)iface; - - TRACE("iface %p\n", iface); - - D3DXMatrixTranslation(&temp, x, y, z); - D3DXMatrixMultiply(&This->stack[This->current], &temp,&This->stack[This->current]); - - return D3D_OK; -} - -static const ID3DXMatrixStackVtbl ID3DXMatrixStack_Vtbl = -{ - ID3DXMatrixStackImpl_QueryInterface, - ID3DXMatrixStackImpl_AddRef, - ID3DXMatrixStackImpl_Release, - ID3DXMatrixStackImpl_Pop, - ID3DXMatrixStackImpl_Push, - ID3DXMatrixStackImpl_LoadIdentity, - ID3DXMatrixStackImpl_LoadMatrix, - ID3DXMatrixStackImpl_MultMatrix, - ID3DXMatrixStackImpl_MultMatrixLocal, - ID3DXMatrixStackImpl_RotateAxis, - ID3DXMatrixStackImpl_RotateAxisLocal, - ID3DXMatrixStackImpl_RotateYawPitchRoll, - ID3DXMatrixStackImpl_RotateYawPitchRollLocal, - ID3DXMatrixStackImpl_Scale, - ID3DXMatrixStackImpl_ScaleLocal, - ID3DXMatrixStackImpl_Translate, - ID3DXMatrixStackImpl_TranslateLocal, - ID3DXMatrixStackImpl_GetTop -}; - -/*_________________D3DXPLANE________________*/ - -D3DXPLANE* WINAPI D3DXPlaneFromPointNormal(D3DXPLANE *pout, CONST D3DXVECTOR3 *pvpoint, CONST D3DXVECTOR3 *pvnormal) -{ - pout->a = pvnormal->x; - pout->b = pvnormal->y; - pout->c = pvnormal->z; - pout->d = -D3DXVec3Dot(pvpoint, pvnormal); - return pout; -} - -D3DXPLANE* WINAPI D3DXPlaneFromPoints(D3DXPLANE *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2, CONST D3DXVECTOR3 *pv3) -{ - D3DXVECTOR3 edge1, edge2, normal, Nnormal; - - edge1.x = 0.0f; edge1.y = 0.0f; edge1.z = 0.0f; - edge2.x = 0.0f; edge2.y = 0.0f; edge2.z = 0.0f; - D3DXVec3Subtract(&edge1, pv2, pv1); - D3DXVec3Subtract(&edge2, pv3, pv1); - D3DXVec3Cross(&normal, &edge1, &edge2); - D3DXVec3Normalize(&Nnormal, &normal); - D3DXPlaneFromPointNormal(pout, pv1, &Nnormal); - return pout; -} - -D3DXVECTOR3* WINAPI D3DXPlaneIntersectLine(D3DXVECTOR3 *pout, CONST D3DXPLANE *pp, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2) -{ - D3DXVECTOR3 direction, normal; - FLOAT dot, temp; - - normal.x = pp->a; - normal.y = pp->b; - normal.z = pp->c; - direction.x = pv2->x - pv1->x; - direction.y = pv2->y - pv1->y; - direction.z = pv2->z - pv1->z; - dot = D3DXVec3Dot(&normal, &direction); - if ( !dot ) return NULL; - temp = ( pp->d + D3DXVec3Dot(&normal, pv1) ) / dot; - pout->x = pv1->x - temp * direction.x; - pout->y = pv1->y - temp * direction.y; - pout->z = pv1->z - temp * direction.z; - return pout; -} - -D3DXPLANE* WINAPI D3DXPlaneNormalize(D3DXPLANE *pout, CONST D3DXPLANE *pp) -{ - D3DXPLANE out; - FLOAT norm; - - norm = sqrt(pp->a * pp->a + pp->b * pp->b + pp->c * pp->c); - if ( norm ) - { - out.a = pp->a / norm; - out.b = pp->b / norm; - out.c = pp->c / norm; - out.d = pp->d / norm; - } - else - { - out.a = 0.0f; - out.b = 0.0f; - out.c = 0.0f; - out.d = 0.0f; - } - *pout = out; - return pout; -} - -D3DXPLANE* WINAPI D3DXPlaneTransform(D3DXPLANE *pout, CONST D3DXPLANE *pplane, CONST D3DXMATRIX *pm) -{ - CONST D3DXPLANE plane = *pplane; - pout->a = pm->u.m[0][0] * plane.a + pm->u.m[1][0] * plane.b + pm->u.m[2][0] * plane.c + pm->u.m[3][0] * plane.d; - pout->b = pm->u.m[0][1] * plane.a + pm->u.m[1][1] * plane.b + pm->u.m[2][1] * plane.c + pm->u.m[3][1] * plane.d; - pout->c = pm->u.m[0][2] * plane.a + pm->u.m[1][2] * plane.b + pm->u.m[2][2] * plane.c + pm->u.m[3][2] * plane.d; - pout->d = pm->u.m[0][3] * plane.a + pm->u.m[1][3] * plane.b + pm->u.m[2][3] * plane.c + pm->u.m[3][3] * plane.d; - return pout; -} - -D3DXPLANE* WINAPI D3DXPlaneTransformArray(D3DXPLANE* out, UINT outstride, CONST D3DXPLANE* in, UINT instride, CONST D3DXMATRIX* matrix, UINT elements) -{ - UINT i; - - for (i = 0; i < elements; ++i) { - D3DXPlaneTransform( - (D3DXPLANE*)((char*)out + outstride * i), - (CONST D3DXPLANE*)((const char*)in + instride * i), - matrix); - } - return out; -} - -/*_________________D3DXQUATERNION________________*/ - -D3DXQUATERNION* WINAPI D3DXQuaternionBaryCentric(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq1, CONST D3DXQUATERNION *pq2, CONST D3DXQUATERNION *pq3, FLOAT f, FLOAT g) -{ - D3DXQUATERNION temp1, temp2; - D3DXQuaternionSlerp(pout, D3DXQuaternionSlerp(&temp1, pq1, pq2, f + g), D3DXQuaternionSlerp(&temp2, pq1, pq3, f+g), g / (f + g)); - return pout; -} - -D3DXQUATERNION* WINAPI D3DXQuaternionExp(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq) -{ - FLOAT norm; - - norm = sqrt(pq->x * pq->x + pq->y * pq->y + pq->z * pq->z); - if (norm ) - { - pout->x = sin(norm) * pq->x / norm; - pout->y = sin(norm) * pq->y / norm; - pout->z = sin(norm) * pq->z / norm; - pout->w = cos(norm); - } - else - { - pout->x = 0.0f; - pout->y = 0.0f; - pout->z = 0.0f; - pout->w = 1.0f; - } - return pout; -} - -D3DXQUATERNION* WINAPI D3DXQuaternionInverse(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq) -{ - D3DXQUATERNION out; - FLOAT norm; - - norm = D3DXQuaternionLengthSq(pq); - - out.x = -pq->x / norm; - out.y = -pq->y / norm; - out.z = -pq->z / norm; - out.w = pq->w / norm; - - *pout =out; - return pout; -} - -D3DXQUATERNION* WINAPI D3DXQuaternionLn(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq) -{ - FLOAT norm, normvec, theta; - - norm = D3DXQuaternionLengthSq(pq); - if ( norm > 1.0001f ) - { - pout->x = pq->x; - pout->y = pq->y; - pout->z = pq->z; - pout->w = 0.0f; - } - else if( norm > 0.99999f) - { - normvec = sqrt( pq->x * pq->x + pq->y * pq->y + pq->z * pq->z ); - theta = atan2(normvec, pq->w) / normvec; - pout->x = theta * pq->x; - pout->y = theta * pq->y; - pout->z = theta * pq->z; - pout->w = 0.0f; - } - else - { - FIXME("The quaternion (%f, %f, %f, %f) has a norm <1. This should not happen. Windows returns a result anyway. This case is not implemented yet.\n", pq->x, pq->y, pq->z, pq->w); - } - return pout; -} - -D3DXQUATERNION* WINAPI D3DXQuaternionMultiply(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq1, CONST D3DXQUATERNION *pq2) -{ - D3DXQUATERNION out; - out.x = pq2->w * pq1->x + pq2->x * pq1->w + pq2->y * pq1->z - pq2->z * pq1->y; - out.y = pq2->w * pq1->y - pq2->x * pq1->z + pq2->y * pq1->w + pq2->z * pq1->x; - out.z = pq2->w * pq1->z + pq2->x * pq1->y - pq2->y * pq1->x + pq2->z * pq1->w; - out.w = pq2->w * pq1->w - pq2->x * pq1->x - pq2->y * pq1->y - pq2->z * pq1->z; - *pout = out; - return pout; -} - -D3DXQUATERNION* WINAPI D3DXQuaternionNormalize(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq) -{ - D3DXQUATERNION out; - FLOAT norm; - - norm = D3DXQuaternionLength(pq); - - out.x = pq->x / norm; - out.y = pq->y / norm; - out.z = pq->z / norm; - out.w = pq->w / norm; - - *pout=out; - - return pout; -} - -D3DXQUATERNION* WINAPI D3DXQuaternionRotationAxis(D3DXQUATERNION *pout, CONST D3DXVECTOR3 *pv, FLOAT angle) -{ - D3DXVECTOR3 temp; - - D3DXVec3Normalize(&temp, pv); - pout->x = sin( angle / 2.0f ) * temp.x; - pout->y = sin( angle / 2.0f ) * temp.y; - pout->z = sin( angle / 2.0f ) * temp.z; - pout->w = cos( angle / 2.0f ); - return pout; -} - -D3DXQUATERNION* WINAPI D3DXQuaternionRotationMatrix(D3DXQUATERNION *pout, CONST D3DXMATRIX *pm) -{ - int i, maxi; - FLOAT maxdiag, S, trace; - - trace = pm->u.m[0][0] + pm->u.m[1][1] + pm->u.m[2][2] + 1.0f; - if ( trace > 1.0f) - { - pout->x = ( pm->u.m[1][2] - pm->u.m[2][1] ) / ( 2.0f * sqrt(trace) ); - pout->y = ( pm->u.m[2][0] - pm->u.m[0][2] ) / ( 2.0f * sqrt(trace) ); - pout->z = ( pm->u.m[0][1] - pm->u.m[1][0] ) / ( 2.0f * sqrt(trace) ); - pout->w = sqrt(trace) / 2.0f; - return pout; - } - maxi = 0; - maxdiag = pm->u.m[0][0]; - for (i=1; i<3; i++) - { - if ( pm->u.m[i][i] > maxdiag ) - { - maxi = i; - maxdiag = pm->u.m[i][i]; - } - } - switch( maxi ) - { - case 0: - S = 2.0f * sqrt(1.0f + pm->u.m[0][0] - pm->u.m[1][1] - pm->u.m[2][2]); - pout->x = 0.25f * S; - pout->y = ( pm->u.m[0][1] + pm->u.m[1][0] ) / S; - pout->z = ( pm->u.m[0][2] + pm->u.m[2][0] ) / S; - pout->w = ( pm->u.m[1][2] - pm->u.m[2][1] ) / S; - break; - case 1: - S = 2.0f * sqrt(1.0f + pm->u.m[1][1] - pm->u.m[0][0] - pm->u.m[2][2]); - pout->x = ( pm->u.m[0][1] + pm->u.m[1][0] ) / S; - pout->y = 0.25f * S; - pout->z = ( pm->u.m[1][2] + pm->u.m[2][1] ) / S; - pout->w = ( pm->u.m[2][0] - pm->u.m[0][2] ) / S; - break; - case 2: - S = 2.0f * sqrt(1.0f + pm->u.m[2][2] - pm->u.m[0][0] - pm->u.m[1][1]); - pout->x = ( pm->u.m[0][2] + pm->u.m[2][0] ) / S; - pout->y = ( pm->u.m[1][2] + pm->u.m[2][1] ) / S; - pout->z = 0.25f * S; - pout->w = ( pm->u.m[0][1] - pm->u.m[1][0] ) / S; - break; - } - return pout; -} - -D3DXQUATERNION* WINAPI D3DXQuaternionRotationYawPitchRoll(D3DXQUATERNION *pout, FLOAT yaw, FLOAT pitch, FLOAT roll) -{ - pout->x = sin( yaw / 2.0f) * cos(pitch / 2.0f) * sin(roll / 2.0f) + cos(yaw / 2.0f) * sin(pitch / 2.0f) * cos(roll / 2.0f); - pout->y = sin( yaw / 2.0f) * cos(pitch / 2.0f) * cos(roll / 2.0f) - cos(yaw / 2.0f) * sin(pitch / 2.0f) * sin(roll / 2.0f); - pout->z = cos(yaw / 2.0f) * cos(pitch / 2.0f) * sin(roll / 2.0f) - sin( yaw / 2.0f) * sin(pitch / 2.0f) * cos(roll / 2.0f); - pout->w = cos( yaw / 2.0f) * cos(pitch / 2.0f) * cos(roll / 2.0f) + sin(yaw / 2.0f) * sin(pitch / 2.0f) * sin(roll / 2.0f); - return pout; -} - -D3DXQUATERNION* WINAPI D3DXQuaternionSlerp(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq1, CONST D3DXQUATERNION *pq2, FLOAT t) -{ - FLOAT dot, epsilon, temp, theta, u; - - epsilon = 1.0f; - temp = 1.0f - t; - u = t; - dot = D3DXQuaternionDot(pq1, pq2); - if ( dot < 0.0f ) - { - epsilon = -1.0f; - dot = -dot; - } - if( 1.0f - dot > 0.001f ) - { - theta = acos(dot); - temp = sin(theta * temp) / sin(theta); - u = sin(theta * u) / sin(theta); - } - pout->x = temp * pq1->x + epsilon * u * pq2->x; - pout->y = temp * pq1->y + epsilon * u * pq2->y; - pout->z = temp * pq1->z + epsilon * u * pq2->z; - pout->w = temp * pq1->w + epsilon * u * pq2->w; - return pout; -} - -D3DXQUATERNION* WINAPI D3DXQuaternionSquad(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq1, CONST D3DXQUATERNION *pq2, CONST D3DXQUATERNION *pq3, CONST D3DXQUATERNION *pq4, FLOAT t) -{ - D3DXQUATERNION temp1, temp2; - - D3DXQuaternionSlerp(pout, D3DXQuaternionSlerp(&temp1, pq1, pq4, t), D3DXQuaternionSlerp(&temp2, pq2, pq3, t), 2.0f * t * (1.0f - t)); - return pout; -} - -void WINAPI D3DXQuaternionToAxisAngle(CONST D3DXQUATERNION *pq, D3DXVECTOR3 *paxis, FLOAT *pangle) -{ - paxis->x = pq->x; - paxis->y = pq->y; - paxis->z = pq->z; - *pangle = 2.0f * acos(pq->w); -} - -/*_________________D3DXVec2_____________________*/ - -D3DXVECTOR2* WINAPI D3DXVec2BaryCentric(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pv2, CONST D3DXVECTOR2 *pv3, FLOAT f, FLOAT g) -{ - pout->x = (1.0f-f-g) * (pv1->x) + f * (pv2->x) + g * (pv3->x); - pout->y = (1.0f-f-g) * (pv1->y) + f * (pv2->y) + g * (pv3->y); - return pout; -} - -D3DXVECTOR2* WINAPI D3DXVec2CatmullRom(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv0, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pv2, CONST D3DXVECTOR2 *pv3, FLOAT s) -{ - pout->x = 0.5f * (2.0f * pv1->x + (pv2->x - pv0->x) *s + (2.0f *pv0->x - 5.0f * pv1->x + 4.0f * pv2->x - pv3->x) * s * s + (pv3->x -3.0f * pv2->x + 3.0f * pv1->x - pv0->x) * s * s * s); - pout->y = 0.5f * (2.0f * pv1->y + (pv2->y - pv0->y) *s + (2.0f *pv0->y - 5.0f * pv1->y + 4.0f * pv2->y - pv3->y) * s * s + (pv3->y -3.0f * pv2->y + 3.0f * pv1->y - pv0->y) * s * s * s); - return pout; -} - -D3DXVECTOR2* WINAPI D3DXVec2Hermite(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pt1, CONST D3DXVECTOR2 *pv2, CONST D3DXVECTOR2 *pt2, FLOAT s) -{ - FLOAT h1, h2, h3, h4; - - h1 = 2.0f * s * s * s - 3.0f * s * s + 1.0f; - h2 = s * s * s - 2.0f * s * s + s; - h3 = -2.0f * s * s * s + 3.0f * s * s; - h4 = s * s * s - s * s; - - pout->x = h1 * (pv1->x) + h2 * (pt1->x) + h3 * (pv2->x) + h4 * (pt2->x); - pout->y = h1 * (pv1->y) + h2 * (pt1->y) + h3 * (pv2->y) + h4 * (pt2->y); - return pout; -} - -D3DXVECTOR2* WINAPI D3DXVec2Normalize(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv) -{ - D3DXVECTOR2 out; - FLOAT norm; - - norm = D3DXVec2Length(pv); - if ( !norm ) - { - out.x = 0.0f; - out.y = 0.0f; - } - else - { - out.x = pv->x / norm; - out.y = pv->y / norm; - } - *pout=out; - return pout; -} - -D3DXVECTOR4* WINAPI D3DXVec2Transform(D3DXVECTOR4 *pout, CONST D3DXVECTOR2 *pv, CONST D3DXMATRIX *pm) -{ - pout->x = pm->u.m[0][0] * pv->x + pm->u.m[1][0] * pv->y + pm->u.m[3][0]; - pout->y = pm->u.m[0][1] * pv->x + pm->u.m[1][1] * pv->y + pm->u.m[3][1]; - pout->z = pm->u.m[0][2] * pv->x + pm->u.m[1][2] * pv->y + pm->u.m[3][2]; - pout->w = pm->u.m[0][3] * pv->x + pm->u.m[1][3] * pv->y + pm->u.m[3][3]; - return pout; -} - -D3DXVECTOR4* WINAPI D3DXVec2TransformArray(D3DXVECTOR4* out, UINT outstride, CONST D3DXVECTOR2* in, UINT instride, CONST D3DXMATRIX* matrix, UINT elements) -{ - UINT i; - - for (i = 0; i < elements; ++i) { - D3DXVec2Transform( - (D3DXVECTOR4*)((char*)out + outstride * i), - (CONST D3DXVECTOR2*)((const char*)in + instride * i), - matrix); - } - return out; -} - -D3DXVECTOR2* WINAPI D3DXVec2TransformCoord(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv, CONST D3DXMATRIX *pm) -{ - D3DXVECTOR2 v; - FLOAT norm; - - v = *pv; - norm = pm->u.m[0][3] * pv->x + pm->u.m[1][3] * pv->y + pm->u.m[3][3]; - - pout->x = (pm->u.m[0][0] * v.x + pm->u.m[1][0] * v.y + pm->u.m[3][0]) / norm; - pout->y = (pm->u.m[0][1] * v.x + pm->u.m[1][1] * v.y + pm->u.m[3][1]) / norm; - - return pout; -} - -D3DXVECTOR2* WINAPI D3DXVec2TransformCoordArray(D3DXVECTOR2* out, UINT outstride, CONST D3DXVECTOR2* in, UINT instride, CONST D3DXMATRIX* matrix, UINT elements) -{ - UINT i; - - for (i = 0; i < elements; ++i) { - D3DXVec2TransformCoord( - (D3DXVECTOR2*)((char*)out + outstride * i), - (CONST D3DXVECTOR2*)((const char*)in + instride * i), - matrix); - } - return out; -} - -D3DXVECTOR2* WINAPI D3DXVec2TransformNormal(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv, CONST D3DXMATRIX *pm) -{ - CONST D3DXVECTOR2 v = *pv; - pout->x = pm->u.m[0][0] * v.x + pm->u.m[1][0] * v.y; - pout->y = pm->u.m[0][1] * v.x + pm->u.m[1][1] * v.y; - return pout; -} - -D3DXVECTOR2* WINAPI D3DXVec2TransformNormalArray(D3DXVECTOR2* out, UINT outstride, CONST D3DXVECTOR2 *in, UINT instride, CONST D3DXMATRIX *matrix, UINT elements) -{ - UINT i; - - for (i = 0; i < elements; ++i) { - D3DXVec2TransformNormal( - (D3DXVECTOR2*)((char*)out + outstride * i), - (CONST D3DXVECTOR2*)((const char*)in + instride * i), - matrix); - } - return out; -} - -/*_________________D3DXVec3_____________________*/ - -D3DXVECTOR3* WINAPI D3DXVec3BaryCentric(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2, CONST D3DXVECTOR3 *pv3, FLOAT f, FLOAT g) -{ - pout->x = (1.0f-f-g) * (pv1->x) + f * (pv2->x) + g * (pv3->x); - pout->y = (1.0f-f-g) * (pv1->y) + f * (pv2->y) + g * (pv3->y); - pout->z = (1.0f-f-g) * (pv1->z) + f * (pv2->z) + g * (pv3->z); - return pout; -} - -D3DXVECTOR3* WINAPI D3DXVec3CatmullRom( D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv0, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2, CONST D3DXVECTOR3 *pv3, FLOAT s) -{ - pout->x = 0.5f * (2.0f * pv1->x + (pv2->x - pv0->x) *s + (2.0f *pv0->x - 5.0f * pv1->x + 4.0f * pv2->x - pv3->x) * s * s + (pv3->x -3.0f * pv2->x + 3.0f * pv1->x - pv0->x) * s * s * s); - pout->y = 0.5f * (2.0f * pv1->y + (pv2->y - pv0->y) *s + (2.0f *pv0->y - 5.0f * pv1->y + 4.0f * pv2->y - pv3->y) * s * s + (pv3->y -3.0f * pv2->y + 3.0f * pv1->y - pv0->y) * s * s * s); - pout->z = 0.5f * (2.0f * pv1->z + (pv2->z - pv0->z) *s + (2.0f *pv0->z - 5.0f * pv1->z + 4.0f * pv2->z - pv3->z) * s * s + (pv3->z -3.0f * pv2->z + 3.0f * pv1->z - pv0->z) * s * s * s); - return pout; -} - -D3DXVECTOR3* WINAPI D3DXVec3Hermite(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pt1, CONST D3DXVECTOR3 *pv2, CONST D3DXVECTOR3 *pt2, FLOAT s) -{ - FLOAT h1, h2, h3, h4; - - h1 = 2.0f * s * s * s - 3.0f * s * s + 1.0f; - h2 = s * s * s - 2.0f * s * s + s; - h3 = -2.0f * s * s * s + 3.0f * s * s; - h4 = s * s * s - s * s; - - pout->x = h1 * (pv1->x) + h2 * (pt1->x) + h3 * (pv2->x) + h4 * (pt2->x); - pout->y = h1 * (pv1->y) + h2 * (pt1->y) + h3 * (pv2->y) + h4 * (pt2->y); - pout->z = h1 * (pv1->z) + h2 * (pt1->z) + h3 * (pv2->z) + h4 * (pt2->z); - return pout; -} - -D3DXVECTOR3* WINAPI D3DXVec3Normalize(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv) -{ - D3DXVECTOR3 out; - FLOAT norm; - - norm = D3DXVec3Length(pv); - if ( !norm ) - { - out.x = 0.0f; - out.y = 0.0f; - out.z = 0.0f; - } - else - { - out.x = pv->x / norm; - out.y = pv->y / norm; - out.z = pv->z / norm; - } - *pout = out; - return pout; -} - -D3DXVECTOR3* WINAPI D3DXVec3Project(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv, CONST D3DVIEWPORT9 *pviewport, CONST D3DXMATRIX *pprojection, CONST D3DXMATRIX *pview, CONST D3DXMATRIX *pworld) -{ - D3DXMATRIX m; - D3DXVECTOR3 out; - - D3DXMatrixMultiply(&m, pworld, pview); - D3DXMatrixMultiply(&m, &m, pprojection); - D3DXVec3TransformCoord(&out, pv, &m); - out.x = pviewport->X + ( 1.0f + out.x ) * pviewport->Width / 2.0f; - out.y = pviewport->Y + ( 1.0f - out.y ) * pviewport->Height / 2.0f; - out.z = pviewport->MinZ + out.z * ( pviewport->MaxZ - pviewport->MinZ ); - *pout = out; - return pout; -} - -D3DXVECTOR3* WINAPI D3DXVec3ProjectArray(D3DXVECTOR3* out, UINT outstride, CONST D3DXVECTOR3* in, UINT instride, CONST D3DVIEWPORT9* viewport, CONST D3DXMATRIX* projection, CONST D3DXMATRIX* view, CONST D3DXMATRIX* world, UINT elements) -{ - UINT i; - - for (i = 0; i < elements; ++i) { - D3DXVec3Project( - (D3DXVECTOR3*)((char*)out + outstride * i), - (CONST D3DXVECTOR3*)((const char*)in + instride * i), - viewport, projection, view, world); - } - return out; -} - -D3DXVECTOR4* WINAPI D3DXVec3Transform(D3DXVECTOR4 *pout, CONST D3DXVECTOR3 *pv, CONST D3DXMATRIX *pm) -{ - pout->x = pm->u.m[0][0] * pv->x + pm->u.m[1][0] * pv->y + pm->u.m[2][0] * pv->z + pm->u.m[3][0]; - pout->y = pm->u.m[0][1] * pv->x + pm->u.m[1][1] * pv->y + pm->u.m[2][1] * pv->z + pm->u.m[3][1]; - pout->z = pm->u.m[0][2] * pv->x + pm->u.m[1][2] * pv->y + pm->u.m[2][2] * pv->z + pm->u.m[3][2]; - pout->w = pm->u.m[0][3] * pv->x + pm->u.m[1][3] * pv->y + pm->u.m[2][3] * pv->z + pm->u.m[3][3]; - return pout; -} - -D3DXVECTOR4* WINAPI D3DXVec3TransformArray(D3DXVECTOR4* out, UINT outstride, CONST D3DXVECTOR3* in, UINT instride, CONST D3DXMATRIX* matrix, UINT elements) -{ - UINT i; - - for (i = 0; i < elements; ++i) { - D3DXVec3Transform( - (D3DXVECTOR4*)((char*)out + outstride * i), - (CONST D3DXVECTOR3*)((const char*)in + instride * i), - matrix); - } - return out; -} - -D3DXVECTOR3* WINAPI D3DXVec3TransformCoord(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv, CONST D3DXMATRIX *pm) -{ - D3DXVECTOR3 out; - FLOAT norm; - - norm = pm->u.m[0][3] * pv->x + pm->u.m[1][3] * pv->y + pm->u.m[2][3] *pv->z + pm->u.m[3][3]; - - out.x = (pm->u.m[0][0] * pv->x + pm->u.m[1][0] * pv->y + pm->u.m[2][0] * pv->z + pm->u.m[3][0]) / norm; - out.y = (pm->u.m[0][1] * pv->x + pm->u.m[1][1] * pv->y + pm->u.m[2][1] * pv->z + pm->u.m[3][1]) / norm; - out.z = (pm->u.m[0][2] * pv->x + pm->u.m[1][2] * pv->y + pm->u.m[2][2] * pv->z + pm->u.m[3][2]) / norm; - - *pout = out; - - return pout; -} - -D3DXVECTOR3* WINAPI D3DXVec3TransformCoordArray(D3DXVECTOR3* out, UINT outstride, CONST D3DXVECTOR3* in, UINT instride, CONST D3DXMATRIX* matrix, UINT elements) -{ - UINT i; - - for (i = 0; i < elements; ++i) { - D3DXVec3TransformCoord( - (D3DXVECTOR3*)((char*)out + outstride * i), - (CONST D3DXVECTOR3*)((const char*)in + instride * i), - matrix); - } - return out; -} - -D3DXVECTOR3* WINAPI D3DXVec3TransformNormal(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv, CONST D3DXMATRIX *pm) -{ - CONST D3DXVECTOR3 v = *pv; - pout->x = pm->u.m[0][0] * v.x + pm->u.m[1][0] * v.y + pm->u.m[2][0] * v.z; - pout->y = pm->u.m[0][1] * v.x + pm->u.m[1][1] * v.y + pm->u.m[2][1] * v.z; - pout->z = pm->u.m[0][2] * v.x + pm->u.m[1][2] * v.y + pm->u.m[2][2] * v.z; - return pout; - -} - -D3DXVECTOR3* WINAPI D3DXVec3TransformNormalArray(D3DXVECTOR3* out, UINT outstride, CONST D3DXVECTOR3* in, UINT instride, CONST D3DXMATRIX* matrix, UINT elements) -{ - UINT i; - - for (i = 0; i < elements; ++i) { - D3DXVec3TransformNormal( - (D3DXVECTOR3*)((char*)out + outstride * i), - (CONST D3DXVECTOR3*)((const char*)in + instride * i), - matrix); - } - return out; -} - -D3DXVECTOR3* WINAPI D3DXVec3Unproject(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv, CONST D3DVIEWPORT9 *pviewport, CONST D3DXMATRIX *pprojection, CONST D3DXMATRIX *pview, CONST D3DXMATRIX *pworld) -{ - D3DXMATRIX m; - D3DXVECTOR3 out; - - D3DXMatrixMultiply(&m, pworld, pview); - D3DXMatrixMultiply(&m, &m, pprojection); - D3DXMatrixInverse(&m, NULL, &m); - out.x = 2.0f * ( pv->x - pviewport->X ) / pviewport->Width - 1.0f; - out.y = 1.0f - 2.0f * ( pv->y - pviewport->Y ) / pviewport->Height; - out.z = ( pv->z - pviewport->MinZ) / ( pviewport->MaxZ - pviewport->MinZ ); - D3DXVec3TransformCoord(&out, &out, &m); - *pout = out; - return pout; -} - -D3DXVECTOR3* WINAPI D3DXVec3UnprojectArray(D3DXVECTOR3* out, UINT outstride, CONST D3DXVECTOR3* in, UINT instride, CONST D3DVIEWPORT9* viewport, CONST D3DXMATRIX* projection, CONST D3DXMATRIX* view, CONST D3DXMATRIX* world, UINT elements) -{ - UINT i; - - for (i = 0; i < elements; ++i) { - D3DXVec3Unproject( - (D3DXVECTOR3*)((char*)out + outstride * i), - (CONST D3DXVECTOR3*)((const char*)in + instride * i), - viewport, projection, view, world); - } - return out; -} - -/*_________________D3DXVec4_____________________*/ - -D3DXVECTOR4* WINAPI D3DXVec4BaryCentric(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2, CONST D3DXVECTOR4 *pv3, FLOAT f, FLOAT g) -{ - pout->x = (1.0f-f-g) * (pv1->x) + f * (pv2->x) + g * (pv3->x); - pout->y = (1.0f-f-g) * (pv1->y) + f * (pv2->y) + g * (pv3->y); - pout->z = (1.0f-f-g) * (pv1->z) + f * (pv2->z) + g * (pv3->z); - pout->w = (1.0f-f-g) * (pv1->w) + f * (pv2->w) + g * (pv3->w); - return pout; -} - -D3DXVECTOR4* WINAPI D3DXVec4CatmullRom(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv0, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2, CONST D3DXVECTOR4 *pv3, FLOAT s) -{ - pout->x = 0.5f * (2.0f * pv1->x + (pv2->x - pv0->x) *s + (2.0f *pv0->x - 5.0f * pv1->x + 4.0f * pv2->x - pv3->x) * s * s + (pv3->x -3.0f * pv2->x + 3.0f * pv1->x - pv0->x) * s * s * s); - pout->y = 0.5f * (2.0f * pv1->y + (pv2->y - pv0->y) *s + (2.0f *pv0->y - 5.0f * pv1->y + 4.0f * pv2->y - pv3->y) * s * s + (pv3->y -3.0f * pv2->y + 3.0f * pv1->y - pv0->y) * s * s * s); - pout->z = 0.5f * (2.0f * pv1->z + (pv2->z - pv0->z) *s + (2.0f *pv0->z - 5.0f * pv1->z + 4.0f * pv2->z - pv3->z) * s * s + (pv3->z -3.0f * pv2->z + 3.0f * pv1->z - pv0->z) * s * s * s); - pout->w = 0.5f * (2.0f * pv1->w + (pv2->w - pv0->w) *s + (2.0f *pv0->w - 5.0f * pv1->w + 4.0f * pv2->w - pv3->w) * s * s + (pv3->w -3.0f * pv2->w + 3.0f * pv1->w - pv0->w) * s * s * s); - return pout; -} - -D3DXVECTOR4* WINAPI D3DXVec4Cross(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2, CONST D3DXVECTOR4 *pv3) -{ - D3DXVECTOR4 out; - out.x = pv1->y * (pv2->z * pv3->w - pv3->z * pv2->w) - pv1->z * (pv2->y * pv3->w - pv3->y * pv2->w) + pv1->w * (pv2->y * pv3->z - pv2->z *pv3->y); - out.y = -(pv1->x * (pv2->z * pv3->w - pv3->z * pv2->w) - pv1->z * (pv2->x * pv3->w - pv3->x * pv2->w) + pv1->w * (pv2->x * pv3->z - pv3->x * pv2->z)); - out.z = pv1->x * (pv2->y * pv3->w - pv3->y * pv2->w) - pv1->y * (pv2->x *pv3->w - pv3->x * pv2->w) + pv1->w * (pv2->x * pv3->y - pv3->x * pv2->y); - out.w = -(pv1->x * (pv2->y * pv3->z - pv3->y * pv2->z) - pv1->y * (pv2->x * pv3->z - pv3->x *pv2->z) + pv1->z * (pv2->x * pv3->y - pv3->x * pv2->y)); - *pout = out; - return pout; -} - -D3DXVECTOR4* WINAPI D3DXVec4Hermite(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pt1, CONST D3DXVECTOR4 *pv2, CONST D3DXVECTOR4 *pt2, FLOAT s) -{ - FLOAT h1, h2, h3, h4; - - h1 = 2.0f * s * s * s - 3.0f * s * s + 1.0f; - h2 = s * s * s - 2.0f * s * s + s; - h3 = -2.0f * s * s * s + 3.0f * s * s; - h4 = s * s * s - s * s; - - pout->x = h1 * (pv1->x) + h2 * (pt1->x) + h3 * (pv2->x) + h4 * (pt2->x); - pout->y = h1 * (pv1->y) + h2 * (pt1->y) + h3 * (pv2->y) + h4 * (pt2->y); - pout->z = h1 * (pv1->z) + h2 * (pt1->z) + h3 * (pv2->z) + h4 * (pt2->z); - pout->w = h1 * (pv1->w) + h2 * (pt1->w) + h3 * (pv2->w) + h4 * (pt2->w); - return pout; -} - -D3DXVECTOR4* WINAPI D3DXVec4Normalize(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv) -{ - D3DXVECTOR4 out; - FLOAT norm; - - norm = D3DXVec4Length(pv); - - out.x = pv->x / norm; - out.y = pv->y / norm; - out.z = pv->z / norm; - out.w = pv->w / norm; - - *pout = out; - return pout; -} - -D3DXVECTOR4* WINAPI D3DXVec4Transform(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv, CONST D3DXMATRIX *pm) -{ - D3DXVECTOR4 out; - out.x = pm->u.m[0][0] * pv->x + pm->u.m[1][0] * pv->y + pm->u.m[2][0] * pv->z + pm->u.m[3][0] * pv->w; - out.y = pm->u.m[0][1] * pv->x + pm->u.m[1][1] * pv->y + pm->u.m[2][1] * pv->z + pm->u.m[3][1] * pv->w; - out.z = pm->u.m[0][2] * pv->x + pm->u.m[1][2] * pv->y + pm->u.m[2][2] * pv->z + pm->u.m[3][2] * pv->w; - out.w = pm->u.m[0][3] * pv->x + pm->u.m[1][3] * pv->y + pm->u.m[2][3] * pv->z + pm->u.m[3][3] * pv->w; - *pout = out; - return pout; -} - -D3DXVECTOR4* WINAPI D3DXVec4TransformArray(D3DXVECTOR4* out, UINT outstride, CONST D3DXVECTOR4* in, UINT instride, CONST D3DXMATRIX* matrix, UINT elements) -{ - UINT i; - - for (i = 0; i < elements; ++i) { - D3DXVec4Transform( - (D3DXVECTOR4*)((char*)out + outstride * i), - (CONST D3DXVECTOR4*)((const char*)in + instride * i), - matrix); - } - return out; -} +/* + * Mathematical operations specific to D3DX9. + * + * Copyright (C) 2008 David Adam + * Copyright (C) 2008 Philip Nilsson + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#define NONAMELESSUNION + +#include "config.h" +#include "windef.h" +#include "wingdi.h" +#include "d3dx9.h" + + +/************************************************************************* + * D3DXMatrixAffineTransformation2D + */ +D3DXMATRIX* WINAPI D3DXMatrixAffineTransformation2D( + D3DXMATRIX *pout, FLOAT scaling, + CONST D3DXVECTOR2 *protationcenter, FLOAT rotation, + CONST D3DXVECTOR2 *ptranslation) +{ + D3DXMATRIX m1, m2, m3, m4, m5; + D3DXQUATERNION rot; + D3DXVECTOR3 rot_center, trans; + + rot.w=cos(rotation/2.0f); + rot.x=0.0f; + rot.y=0.0f; + rot.z=sin(rotation/2.0f); + + if ( protationcenter ) + { + rot_center.x=protationcenter->x; + rot_center.y=protationcenter->y; + rot_center.z=0.0f; + } + else + { + rot_center.x=0.0f; + rot_center.y=0.0f; + rot_center.z=0.0f; + } + + if ( ptranslation ) + { + trans.x=ptranslation->x; + trans.y=ptranslation->y; + trans.z=0.0f; + } + else + { + trans.x=0.0f; + trans.y=0.0f; + trans.z=0.0f; + } + + D3DXMatrixScaling(&m1, scaling, scaling, 1.0f); + D3DXMatrixTranslation(&m2, -rot_center.x, -rot_center.y, -rot_center.z); + D3DXMatrixTranslation(&m4, rot_center.x, rot_center.y, rot_center.z); + D3DXMatrixRotationQuaternion(&m3, &rot); + D3DXMatrixTranslation(&m5, trans.x, trans.y, trans.z); + + D3DXMatrixMultiply(&m1, &m1, &m2); + D3DXMatrixMultiply(&m1, &m1, &m3); + D3DXMatrixMultiply(&m1, &m1, &m4); + D3DXMatrixMultiply(pout, &m1, &m5); + + return pout; +} + +/************************************************************************* + * D3DXMatrixDecompose + */ +HRESULT WINAPI D3DXMatrixDecompose(D3DXVECTOR3 *poutscale, D3DXQUATERNION *poutrotation, D3DXVECTOR3 *pouttranslation, D3DXMATRIX *pm) +{ + D3DXMATRIX normalized; + D3DXVECTOR3 vec; + + /*Compute the scaling part.*/ + vec.x=pm->u.m[0][0]; + vec.y=pm->u.m[0][1]; + vec.z=pm->u.m[0][2]; + poutscale->x=D3DXVec3Length(&vec); + + vec.x=pm->u.m[1][0]; + vec.y=pm->u.m[1][1]; + vec.z=pm->u.m[1][2]; + poutscale->y=D3DXVec3Length(&vec); + + vec.x=pm->u.m[2][0]; + vec.y=pm->u.m[2][1]; + vec.z=pm->u.m[2][2]; + poutscale->z=D3DXVec3Length(&vec); + + /*Compute the translation part.*/ + pouttranslation->x=pm->u.m[3][0]; + pouttranslation->y=pm->u.m[3][1]; + pouttranslation->z=pm->u.m[3][2]; + + /*Let's calculate the rotation now*/ + if ( (poutscale->x == 0.0f) || (poutscale->y == 0.0f) || (poutscale->z == 0.0f) ) + { + return D3DERR_INVALIDCALL; + } + + normalized.u.m[0][0]=pm->u.m[0][0]/poutscale->x; + normalized.u.m[0][1]=pm->u.m[0][1]/poutscale->x; + normalized.u.m[0][2]=pm->u.m[0][2]/poutscale->x; + normalized.u.m[1][0]=pm->u.m[1][0]/poutscale->y; + normalized.u.m[1][1]=pm->u.m[1][1]/poutscale->y; + normalized.u.m[1][2]=pm->u.m[1][2]/poutscale->y; + normalized.u.m[2][0]=pm->u.m[2][0]/poutscale->z; + normalized.u.m[2][1]=pm->u.m[2][1]/poutscale->z; + normalized.u.m[2][2]=pm->u.m[2][2]/poutscale->z; + + D3DXQuaternionRotationMatrix(poutrotation,&normalized); + return S_OK; +} + +/************************************************************************* + * D3DXMatrixTransformation2D + */ +D3DXMATRIX* WINAPI D3DXMatrixTransformation2D( + D3DXMATRIX *pout, CONST D3DXVECTOR2 *pscalingcenter, + FLOAT scalingrotation, CONST D3DXVECTOR2 *pscaling, + CONST D3DXVECTOR2 *protationcenter, FLOAT rotation, + CONST D3DXVECTOR2 *ptranslation) +{ + D3DXQUATERNION rot, sca_rot; + D3DXVECTOR3 rot_center, sca, sca_center, trans; + + if ( pscalingcenter ) + { + sca_center.x=pscalingcenter->x; + sca_center.y=pscalingcenter->y; + sca_center.z=0.0f; + } + else + { + sca_center.x=0.0f; + sca_center.y=0.0f; + sca_center.z=0.0f; + } + + if ( pscaling ) + { + sca.x=pscaling->x; + sca.y=pscaling->y; + sca.z=1.0f; + } + else + { + sca.x=1.0f; + sca.y=1.0f; + sca.z=1.0f; + } + + if ( protationcenter ) + { + rot_center.x=protationcenter->x; + rot_center.y=protationcenter->y; + rot_center.z=0.0f; + } + else + { + rot_center.x=0.0f; + rot_center.y=0.0f; + rot_center.z=0.0f; + } + + if ( ptranslation ) + { + trans.x=ptranslation->x; + trans.y=ptranslation->y; + trans.z=0.0f; + } + else + { + trans.x=0.0f; + trans.y=0.0f; + trans.z=0.0f; + } + + rot.w=cos(rotation/2.0f); + rot.x=0.0f; + rot.y=0.0f; + rot.z=sin(rotation/2.0f); + + sca_rot.w=cos(scalingrotation/2.0f); + sca_rot.x=0.0f; + sca_rot.y=0.0f; + sca_rot.z=sin(scalingrotation/2.0f); + + D3DXMatrixTransformation(pout, &sca_center, &sca_rot, &sca, &rot_center, &rot, &trans); + + return pout; +} + +/************************************************************************* + * D3DXPlaneTransformArray + */ +D3DXPLANE* WINAPI D3DXPlaneTransformArray( + D3DXPLANE* out, UINT outstride, CONST D3DXPLANE* in, UINT instride, + CONST D3DXMATRIX* matrix, UINT elements) +{ + UINT i; + + for (i = 0; i < elements; ++i) { + D3DXPlaneTransform( + (D3DXPLANE*)((char*)out + outstride * i), + (CONST D3DXPLANE*)((const char*)in + instride * i), + matrix); + } + return out; +} + +/************************************************************************* + * D3DXVec2TransformArray + * + * Transform an array of vectors by a matrix. + */ +D3DXVECTOR4* WINAPI D3DXVec2TransformArray( + D3DXVECTOR4* out, UINT outstride, CONST D3DXVECTOR2* in, UINT instride, + CONST D3DXMATRIX* matrix, UINT elements) +{ + UINT i; + + for (i = 0; i < elements; ++i) { + D3DXVec2Transform( + (D3DXVECTOR4*)((char*)out + outstride * i), + (CONST D3DXVECTOR2*)((const char*)in + instride * i), + matrix); + } + return out; +} + +/************************************************************************* + * D3DXVec2TransformCoordArray + */ +D3DXVECTOR2* WINAPI D3DXVec2TransformCoordArray( + D3DXVECTOR2* out, UINT outstride, CONST D3DXVECTOR2* in, UINT instride, + CONST D3DXMATRIX* matrix, UINT elements) +{ + UINT i; + + for (i = 0; i < elements; ++i) { + D3DXVec2TransformCoord( + (D3DXVECTOR2*)((char*)out + outstride * i), + (CONST D3DXVECTOR2*)((const char*)in + instride * i), + matrix); + } + return out; +} + +/************************************************************************* + * D3DXVec2TransformNormalArray + */ +D3DXVECTOR2* WINAPI D3DXVec2TransformNormalArray( + D3DXVECTOR2* out, UINT outstride, CONST D3DXVECTOR2 *in, UINT instride, + CONST D3DXMATRIX *matrix, UINT elements) +{ + UINT i; + + for (i = 0; i < elements; ++i) { + D3DXVec2TransformNormal( + (D3DXVECTOR2*)((char*)out + outstride * i), + (CONST D3DXVECTOR2*)((const char*)in + instride * i), + matrix); + } + return out; +} + +/************************************************************************* + * D3DXVec3ProjectArray + * + * Projects an array of vectors to the screen. + */ +D3DXVECTOR3* WINAPI D3DXVec3ProjectArray( + D3DXVECTOR3* out, UINT outstride, CONST D3DXVECTOR3* in, UINT instride, + CONST D3DVIEWPORT9* viewport, CONST D3DXMATRIX* projection, + CONST D3DXMATRIX* view, CONST D3DXMATRIX* world, UINT elements) +{ + UINT i; + + for (i = 0; i < elements; ++i) { + D3DXVec3Project( + (D3DXVECTOR3*)((char*)out + outstride * i), + (CONST D3DXVECTOR3*)((const char*)in + instride * i), + viewport, projection, view, world); + } + return out; +} + +/************************************************************************* + * D3DXVec3TransformArray + */ +D3DXVECTOR4* WINAPI D3DXVec3TransformArray( + D3DXVECTOR4* out, UINT outstride, CONST D3DXVECTOR3* in, UINT instride, + CONST D3DXMATRIX* matrix, UINT elements) +{ + UINT i; + + for (i = 0; i < elements; ++i) { + D3DXVec3Transform( + (D3DXVECTOR4*)((char*)out + outstride * i), + (CONST D3DXVECTOR3*)((const char*)in + instride * i), + matrix); + } + return out; +} + +/************************************************************************* + * D3DXVec3TransformCoordArray + */ +D3DXVECTOR3* WINAPI D3DXVec3TransformCoordArray( + D3DXVECTOR3* out, UINT outstride, CONST D3DXVECTOR3* in, UINT instride, + CONST D3DXMATRIX* matrix, UINT elements) +{ + UINT i; + + for (i = 0; i < elements; ++i) { + D3DXVec3TransformCoord( + (D3DXVECTOR3*)((char*)out + outstride * i), + (CONST D3DXVECTOR3*)((const char*)in + instride * i), + matrix); + } + return out; +} + +/************************************************************************* + * D3DXVec3TransformNormalArray + */ +D3DXVECTOR3* WINAPI D3DXVec3TransformNormalArray( + D3DXVECTOR3* out, UINT outstride, CONST D3DXVECTOR3* in, UINT instride, + CONST D3DXMATRIX* matrix, UINT elements) +{ + UINT i; + + for (i = 0; i < elements; ++i) { + D3DXVec3TransformNormal( + (D3DXVECTOR3*)((char*)out + outstride * i), + (CONST D3DXVECTOR3*)((const char*)in + instride * i), + matrix); + } + return out; +} + +/************************************************************************* + * D3DXVec3UnprojectArray + */ +D3DXVECTOR3* WINAPI D3DXVec3UnprojectArray( + D3DXVECTOR3* out, UINT outstride, CONST D3DXVECTOR3* in, UINT instride, + CONST D3DVIEWPORT9* viewport, CONST D3DXMATRIX* projection, + CONST D3DXMATRIX* view, CONST D3DXMATRIX* world, UINT elements) +{ + UINT i; + + for (i = 0; i < elements; ++i) { + D3DXVec3Unproject( + (D3DXVECTOR3*)((char*)out + outstride * i), + (CONST D3DXVECTOR3*)((const char*)in + instride * i), + viewport, projection, view, world); + } + return out; +} + +/************************************************************************* + * D3DXVec4TransformArray + */ +D3DXVECTOR4* WINAPI D3DXVec4TransformArray( + D3DXVECTOR4* out, UINT outstride, CONST D3DXVECTOR4* in, UINT instride, + CONST D3DXMATRIX* matrix, UINT elements) +{ + UINT i; + + for (i = 0; i < elements; ++i) { + D3DXVec4Transform( + (D3DXVECTOR4*)((char*)out + outstride * i), + (CONST D3DXVECTOR4*)((const char*)in + instride * i), + matrix); + } + return out; +} diff --git a/dlls/d3dx9_36/mesh.c b/dlls/d3dx9_36/mesh.c index 251bb40f9fc..9b54ce03492 100644 --- a/dlls/d3dx9_36/mesh.c +++ b/dlls/d3dx9_36/mesh.c @@ -28,79 +28,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3dx); /************************************************************************* - * D3DXBoxBoundProbe - */ -BOOL WINAPI D3DXBoxBoundProbe(CONST D3DXVECTOR3 *pmin, CONST D3DXVECTOR3 *pmax, CONST D3DXVECTOR3 *prayposition, CONST D3DXVECTOR3 *praydirection) - -/* Algorithm taken from the article: An Efficient and Robust Ray-Box Intersection Algoritm -Amy Williams University of Utah -Steve Barrus University of Utah -R. Keith Morley University of Utah -Peter Shirley University of Utah - -International Conference on Computer Graphics and Interactive Techniques archive -ACM SIGGRAPH 2005 Courses -Los Angeles, California - -This algorithm is free of patents or of copyrights, as confirmed by Peter Shirley himself. - -Algorithm: Consider the box as the intersection of three slabs. Clip the ray -against each slab, if there's anything left of the ray after we're -done we've got an intersection of the ray with the box. -*/ - -{ - FLOAT div, tmin, tmax, tymin, tymax, tzmin, tzmax; - - div = 1.0f / praydirection->x; - if ( div >= 0.0f ) - { - tmin = ( pmin->x - prayposition->x ) * div; - tmax = ( pmax->x - prayposition->x ) * div; - } - else - { - tmin = ( pmax->x - prayposition->x ) * div; - tmax = ( pmin->x - prayposition->x ) * div; - } - - if ( tmax < 0.0f ) return FALSE; - - div = 1.0f / praydirection->y; - if ( div >= 0.0f ) - { - tymin = ( pmin->y - prayposition->y ) * div; - tymax = ( pmax->y - prayposition->y ) * div; - } - else - { - tymin = ( pmax->y - prayposition->y ) * div; - tymax = ( pmin->y - prayposition->y ) * div; - } - - if ( ( tymax < 0.0f ) || ( tmin > tymax ) || ( tymin > tmax ) ) return FALSE; - - if ( tymin > tmin ) tmin = tymin; - if ( tymax < tmax ) tmax = tymax; - - div = 1.0f / praydirection->z; - if ( div >= 0.0f ) - { - tzmin = ( pmin->z - prayposition->z ) * div; - tzmax = ( pmax->z - prayposition->z ) * div; - } - else - { - tzmin = ( pmax->z - prayposition->z ) * div; - tzmax = ( pmin->z - prayposition->z ) * div; - } - - if ( (tzmax < 0.0f ) || ( tmin > tzmax ) || ( tzmin > tmax ) ) return FALSE; - - return TRUE; -} - -/************************************************************************* * D3DXComputeBoundingBox */ HRESULT WINAPI D3DXComputeBoundingBox(CONST D3DXVECTOR3 *pfirstposition, DWORD numvertices, DWORD dwstride, D3DXVECTOR3 *pmin, D3DXVECTOR3 *pmax) @@ -204,7 +131,7 @@ UINT WINAPI D3DXGetFVFVertexSize(DWORD FVF) } /************************************************************************* - * D3DXGetDeclVertexSize + * D3DXGetFVFVertexSize */ UINT WINAPI D3DXGetDeclVertexSize(const D3DVERTEXELEMENT9 *decl, DWORD stream_idx) { @@ -296,21 +223,3 @@ BOOL WINAPI D3DXIntersectTri(CONST D3DXVECTOR3 *p0, CONST D3DXVECTOR3 *p1, CONST return FALSE; } - -/************************************************************************* - * D3DXSphereBoundProbe - */ -BOOL WINAPI D3DXSphereBoundProbe(CONST D3DXVECTOR3 *pcenter, FLOAT radius, CONST D3DXVECTOR3 *prayposition, CONST D3DXVECTOR3 *praydirection) -{ - D3DXVECTOR3 difference; - FLOAT a, b, c, d; - - a = D3DXVec3LengthSq(praydirection); - if (!D3DXVec3Subtract(&difference, prayposition, pcenter)) return FALSE; - b = D3DXVec3Dot(&difference, praydirection); - c = D3DXVec3LengthSq(&difference) - radius * radius; - d = b * b - a * c; - - if ( ( d <= 0.0f ) || ( sqrt(d) <= b ) ) return FALSE; - return TRUE; -} diff --git a/dlls/d3dx9_36/surface.c b/dlls/d3dx9_36/surface.c dissimilarity index 68% index 0bee7c8cde9..1614e448681 100644 --- a/dlls/d3dx9_36/surface.c +++ b/dlls/d3dx9_36/surface.c @@ -1,427 +1,161 @@ -/* - * Copyright (C) 2009 Tony Wasserka - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - * - */ - -#include "wine/debug.h" -#include "wine/unicode.h" -#include "d3dx9_36_private.h" - -WINE_DEFAULT_DEBUG_CHANNEL(d3dx); - - -/************************************************************ - * D3DXGetImageInfoFromFileInMemory - * - * Fills a D3DXIMAGE_INFO structure with info about an image - * - * PARAMS - * data [I] pointer to the image file data - * datasize [I] size of the passed data - * info [O] pointer to the destination structure - * - * RETURNS - * Success: D3D_OK, if info is not NULL and data and datasize make up a valid image file or - * if info is NULL and data and datasize are not NULL - * Failure: D3DXERR_INVALIDDATA, if data is no valid image file and datasize and info are not NULL - * D3DERR_INVALIDCALL, if data is NULL or - * if datasize is 0 - * - * NOTES - * datasize may be bigger than the actual file size - * - */ -HRESULT WINAPI D3DXGetImageInfoFromFileInMemory(LPCVOID data, UINT datasize, D3DXIMAGE_INFO *info) -{ - FIXME("stub\n"); - - if(data && datasize && !info) return D3D_OK; - if( !data || !datasize ) return D3DERR_INVALIDCALL; - - return E_NOTIMPL; -} - -/************************************************************ - * D3DXGetImageInfoFromFile - * - * RETURNS - * Success: D3D_OK, if we successfully load a valid image file or - * if we successfully load a file which is no valid image and info is NULL - * Failure: D3DXERR_INVALIDDATA, if we fail to load file or - * if file is not a valid image file and info is not NULL - * D3DERR_INVALIDCALL, if file is NULL - * - */ -HRESULT WINAPI D3DXGetImageInfoFromFileA(LPCSTR file, D3DXIMAGE_INFO *info) -{ - LPWSTR widename; - HRESULT hr; - int strlength; - TRACE("(void): relay\n"); - - if( !file ) return D3DERR_INVALIDCALL; - - strlength = MultiByteToWideChar(CP_ACP, 0, file, -1, NULL, 0); - widename = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, strlength * sizeof(WCHAR)); - MultiByteToWideChar(CP_ACP, 0, file, -1, widename, strlength); - - hr = D3DXGetImageInfoFromFileW(widename, info); - HeapFree(GetProcessHeap(), 0, widename); - - return hr; -} - -HRESULT WINAPI D3DXGetImageInfoFromFileW(LPCWSTR file, D3DXIMAGE_INFO *info) -{ - HRESULT hr; - DWORD size; - LPVOID buffer; - TRACE("(void): relay\n"); - - if( !file ) return D3DERR_INVALIDCALL; - - hr = map_view_of_file(file, &buffer, &size); - if(FAILED(hr)) return D3DXERR_INVALIDDATA; - - hr = D3DXGetImageInfoFromFileInMemory(buffer, size, info); - UnmapViewOfFile(buffer); - - return hr; -} - -/************************************************************ - * D3DXGetImageInfoFromResource - * - * RETURNS - * Success: D3D_OK, if resource is a valid image file - * Failure: D3DXERR_INVALIDDATA, if resource is no valid image file or NULL or - * if we fail to load resource - * - */ -HRESULT WINAPI D3DXGetImageInfoFromResourceA(HMODULE module, LPCSTR resource, D3DXIMAGE_INFO *info) -{ - HRSRC resinfo; - TRACE("(void)\n"); - - resinfo = FindResourceA(module, resource, (LPCSTR)RT_RCDATA); - if(resinfo) { - LPVOID buffer; - HRESULT hr; - DWORD size; - - hr = load_resource_into_memory(module, resinfo, &buffer, &size); - if(FAILED(hr)) return D3DXERR_INVALIDDATA; - return D3DXGetImageInfoFromFileInMemory(buffer, size, info); - } - - resinfo = FindResourceA(module, resource, (LPCSTR)RT_BITMAP); - if(resinfo) { - FIXME("Implement loading bitmaps from resource type RT_BITMAP\n"); - return E_NOTIMPL; - } - return D3DXERR_INVALIDDATA; -} - -HRESULT WINAPI D3DXGetImageInfoFromResourceW(HMODULE module, LPCWSTR resource, D3DXIMAGE_INFO *info) -{ - HRSRC resinfo; - TRACE("(void)\n"); - - resinfo = FindResourceW(module, resource, (LPCWSTR)RT_RCDATA); - if(resinfo) { - LPVOID buffer; - HRESULT hr; - DWORD size; - - hr = load_resource_into_memory(module, resinfo, &buffer, &size); - if(FAILED(hr)) return D3DXERR_INVALIDDATA; - return D3DXGetImageInfoFromFileInMemory(buffer, size, info); - } - - resinfo = FindResourceW(module, resource, (LPCWSTR)RT_BITMAP); - if(resinfo) { - FIXME("Implement loading bitmaps from resource type RT_BITMAP\n"); - return E_NOTIMPL; - } - return D3DXERR_INVALIDDATA; -} - -/************************************************************ - * D3DXLoadSurfaceFromFileInMemory - * - * Loads data from a given buffer into a surface and fills a given - * D3DXIMAGE_INFO structure with info about the source data. - * - * PARAMS - * pDestSurface [I] pointer to the surface - * pDestPalette [I] palette to use - * pDestRect [I] to be filled area of the surface - * pSrcData [I] pointer to the source data - * SrcDataSize [I] size of the source data in bytes - * pSrcRect [I] area of the source data to load - * dwFilter [I] filter to apply on stretching - * Colorkey [I] colorkey - * pSrcInfo [O] pointer to a D3DXIMAGE_INFO structure - * - * RETURNS - * Success: D3D_OK - * Failure: D3DERR_INVALIDCALL, if pDestSurface or pSrcData or SrcDataSize are NULL - * D3DXERR_INVALIDDATA, if pSrcData is no valid image file - * - */ -HRESULT WINAPI D3DXLoadSurfaceFromFileInMemory(LPDIRECT3DSURFACE9 pDestSurface, - CONST PALETTEENTRY *pDestPalette, - CONST RECT *pDestRect, - LPCVOID pSrcData, - UINT SrcDataSize, - CONST RECT *pSrcRect, - DWORD dwFilter, - D3DCOLOR Colorkey, - D3DXIMAGE_INFO *pSrcInfo) -{ - FIXME("stub\n"); - if( !pDestSurface || !pSrcData | !SrcDataSize ) return D3DERR_INVALIDCALL; - return E_NOTIMPL; -} - -/************************************************************ - * D3DXLoadSurfaceFromFile - */ -HRESULT WINAPI D3DXLoadSurfaceFromFileA(LPDIRECT3DSURFACE9 pDestSurface, - CONST PALETTEENTRY *pDestPalette, - CONST RECT *pDestRect, - LPCSTR pSrcFile, - CONST RECT *pSrcRect, - DWORD dwFilter, - D3DCOLOR Colorkey, - D3DXIMAGE_INFO *pSrcInfo) -{ - LPWSTR pWidename; - HRESULT hr; - int strlength; - TRACE("(void): relay\n"); - - if( !pSrcFile || !pDestSurface ) return D3DERR_INVALIDCALL; - - strlength = MultiByteToWideChar(CP_ACP, 0, pSrcFile, -1, NULL, 0); - pWidename = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, strlength * sizeof(WCHAR)); - MultiByteToWideChar(CP_ACP, 0, pSrcFile, -1, pWidename, strlength); - - hr = D3DXLoadSurfaceFromFileW(pDestSurface, pDestPalette, pDestRect, pWidename, pSrcRect, dwFilter, Colorkey, pSrcInfo); - HeapFree(GetProcessHeap(), 0, pWidename); - - return hr; -} - -HRESULT WINAPI D3DXLoadSurfaceFromFileW(LPDIRECT3DSURFACE9 pDestSurface, - CONST PALETTEENTRY *pDestPalette, - CONST RECT *pDestRect, - LPCWSTR pSrcFile, - CONST RECT *pSrcRect, - DWORD Filter, - D3DCOLOR Colorkey, - D3DXIMAGE_INFO *pSrcInfo) -{ - HRESULT hr; - DWORD dwSize; - LPVOID pBuffer; - TRACE("(void): relay\n"); - - if( !pSrcFile || !pDestSurface ) return D3DERR_INVALIDCALL; - - hr = map_view_of_file(pSrcFile, &pBuffer, &dwSize); - if(FAILED(hr)) return D3DXERR_INVALIDDATA; - - hr = D3DXLoadSurfaceFromFileInMemory(pDestSurface, pDestPalette, pDestRect, pBuffer, dwSize, pSrcRect, Filter, Colorkey, pSrcInfo); - UnmapViewOfFile(pBuffer); - - return hr; -} - -/************************************************************ - * D3DXLoadSurfaceFromResource - */ -HRESULT WINAPI D3DXLoadSurfaceFromResourceA(LPDIRECT3DSURFACE9 pDestSurface, - CONST PALETTEENTRY *pDestPalette, - CONST RECT *pDestRect, - HMODULE hSrcModule, - LPCSTR pResource, - CONST RECT *pSrcRect, - DWORD dwFilter, - D3DCOLOR Colorkey, - D3DXIMAGE_INFO *pSrcInfo) -{ - HRSRC hResInfo; - TRACE("(void): relay\n"); - - if( !pDestSurface ) return D3DERR_INVALIDCALL; - - hResInfo = FindResourceA(hSrcModule, pResource, (LPCSTR)RT_RCDATA); - if(hResInfo) { - LPVOID pBuffer; - HRESULT hr; - DWORD dwSize; - - hr = load_resource_into_memory(hSrcModule, hResInfo, &pBuffer, &dwSize); - if(FAILED(hr)) return D3DXERR_INVALIDDATA; - return D3DXLoadSurfaceFromFileInMemory(pDestSurface, pDestPalette, pDestRect, pBuffer, dwSize, pSrcRect, dwFilter, Colorkey, pSrcInfo); - } - - hResInfo = FindResourceA(hSrcModule, pResource, (LPCSTR)RT_BITMAP); - if(hResInfo) { - FIXME("Implement loading bitmaps from resource type RT_BITMAP\n"); - return E_NOTIMPL; - } - return D3DXERR_INVALIDDATA; -} - -HRESULT WINAPI D3DXLoadSurfaceFromResourceW(LPDIRECT3DSURFACE9 pDestSurface, - CONST PALETTEENTRY *pDestPalette, - CONST RECT *pDestRect, - HMODULE hSrcModule, - LPCWSTR pResource, - CONST RECT *pSrcRect, - DWORD dwFilter, - D3DCOLOR Colorkey, - D3DXIMAGE_INFO *pSrcInfo) -{ - HRSRC hResInfo; - TRACE("(void): relay\n"); - - if( !pDestSurface ) return D3DERR_INVALIDCALL; - - hResInfo = FindResourceW(hSrcModule, pResource, (LPCWSTR)RT_RCDATA); - if(hResInfo) { - LPVOID pBuffer; - HRESULT hr; - DWORD dwSize; - - hr = load_resource_into_memory(hSrcModule, hResInfo, &pBuffer, &dwSize); - if(FAILED(hr)) return D3DXERR_INVALIDDATA; - return D3DXLoadSurfaceFromFileInMemory(pDestSurface, pDestPalette, pDestRect, pBuffer, dwSize, pSrcRect, dwFilter, Colorkey, pSrcInfo); - } - - hResInfo = FindResourceW(hSrcModule, pResource, (LPCWSTR)RT_BITMAP); - if(hResInfo) { - FIXME("Implement loading bitmaps from resource type RT_BITMAP\n"); - return E_NOTIMPL; - } - return D3DXERR_INVALIDDATA; -} - -/************************************************************ - * D3DXLoadSurfaceFromMemory - * - * Loads data from a given memory chunk into a surface, - * applying any of the specified filters. - * - * PARAMS - * pDestSurface [I] pointer to the surface - * pDestPalette [I] palette to use - * pDestRect [I] to be filled area of the surface - * pSrcMemory [I] pointer to the source data - * SrcFormat [I] format of the source pixel data - * SrcPitch [I] number of bytes in a row - * pSrcPalette [I] palette used in the source image - * pSrcRect [I] area of the source data to load - * dwFilter [I] filter to apply on stretching - * Colorkey [I] colorkey - * - * RETURNS - * Success: D3D_OK, if we successfully load the pixel data into our surface or - * if pSrcMemory is NULL but the other parameters are valid - * Failure: D3DERR_INVALIDCALL, if pDestSurface, SrcPitch or pSrcRect are NULL or - * if SrcFormat is an invalid format (other than D3DFMT_UNKNOWN) - * D3DXERR_INVALIDDATA, if we fail to lock pDestSurface - * E_FAIL, if SrcFormat is D3DFMT_UNKNOWN or the dimensions of pSrcRect are invalid - * - * NOTES - * pSrcRect specifies the dimensions of the source data - * - */ -HRESULT WINAPI D3DXLoadSurfaceFromMemory(LPDIRECT3DSURFACE9 pDestSurface, - CONST PALETTEENTRY *pDestPalette, - CONST RECT *pDestRect, - LPCVOID pSrcMemory, - D3DFORMAT SrcFormat, - UINT SrcPitch, - CONST PALETTEENTRY *pSrcPalette, - CONST RECT *pSrcRect, - DWORD dwFilter, - D3DCOLOR Colorkey) -{ - TRACE("stub\n"); - - if( !pDestSurface || !pSrcMemory || !pSrcRect ) return D3DERR_INVALIDCALL; - if(SrcFormat == D3DFMT_UNKNOWN || pSrcRect->left >= pSrcRect->right || pSrcRect->top >= pSrcRect->bottom) return E_FAIL; - return E_NOTIMPL; -} - -/************************************************************ - * D3DXLoadSurfaceFromSurface - * - * Copies the contents from one surface to another, performing any required - * format conversion, resizing or filtering. - * - * PARAMS - * pDestSurface [I] pointer to the destination surface - * pDestPalette [I] palette to use - * pDestRect [I] to be filled area of the surface - * pSrcSurface [I] pointer to the source surface - * pSrcPalette [I] palette used for the source surface - * pSrcRect [I] area of the source data to load - * dwFilter [I] filter to apply on resizing - * Colorkey [I] any ARGB value or 0 to disable color-keying - * - * RETURNS - * Success: D3D_OK - * Failure: D3DERR_INVALIDCALL, if pDestSurface or pSrcSurface are NULL - * D3DXERR_INVALIDDATA, if one of the surfaces is not lockable - * - */ -HRESULT WINAPI D3DXLoadSurfaceFromSurface(LPDIRECT3DSURFACE9 pDestSurface, - CONST PALETTEENTRY *pDestPalette, - CONST RECT *pDestRect, - LPDIRECT3DSURFACE9 pSrcSurface, - CONST PALETTEENTRY *pSrcPalette, - CONST RECT *pSrcRect, - DWORD dwFilter, - D3DCOLOR Colorkey) -{ - RECT rect; - D3DLOCKED_RECT lock; - D3DSURFACE_DESC SrcDesc; - HRESULT hr; - TRACE("(void): relay\n"); - - if( !pDestSurface || !pSrcSurface ) return D3DERR_INVALIDCALL; - - IDirect3DSurface9_GetDesc(pSrcSurface, &SrcDesc); - - if( !pSrcRect ) SetRect(&rect, 0, 0, SrcDesc.Width, SrcDesc.Height); - else rect = *pSrcRect; - - hr = IDirect3DSurface9_LockRect(pSrcSurface, &lock, NULL, D3DLOCK_READONLY); - if(FAILED(hr)) return D3DXERR_INVALIDDATA; - - hr = D3DXLoadSurfaceFromMemory(pDestSurface, pDestPalette, pDestRect, - lock.pBits, SrcDesc.Format, lock.Pitch, - pSrcPalette, &rect, dwFilter, Colorkey); - - IDirect3DSurface9_UnlockRect(pSrcSurface); - return hr; -} +/* + * Copyright (C) 2009 Tony Wasserka + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + * + */ + +#include "wine/debug.h" +#include "wine/unicode.h" +#include "d3dx9_36_private.h" + +WINE_DEFAULT_DEBUG_CHANNEL(d3dx); + + +/************************************************************ + * D3DXGetImageInfoFromFileInMemory + * + * Fills a D3DXIMAGE_INFO structure with info about an image + * + * PARAMS + * data [I] pointer to the image file data + * datasize [I] size of the passed data + * info [O] pointer to the destination structure + * + * RETURNS + * Success: D3D_OK, if info is not NULL and data and datasize make up a valid image file or + * if info is NULL and data and datasize are not NULL + * Failure: D3DXERR_INVALIDDATA, if data is no valid image file and datasize and info are not NULL + * D3DERR_INVALIDCALL, if data is NULL or + * if datasize is 0 + * + * NOTES + * datasize may be bigger than the actual file size + * + */ +HRESULT WINAPI D3DXGetImageInfoFromFileInMemory(LPCVOID data, UINT datasize, D3DXIMAGE_INFO *info) +{ + FIXME("stub\n"); + + if(data && datasize && !info) return D3D_OK; + if( !data || !datasize ) return D3DERR_INVALIDCALL; + + return E_NOTIMPL; +} + +/************************************************************ + * D3DXGetImageInfoFromFile + * + * RETURNS + * Success: D3D_OK, if we successfully load a valid image file or + * if we successfully load a file which is no valid image and info is NULL + * Failure: D3DXERR_INVALIDDATA, if we fail to load file or + * if file is not a valid image file and info is not NULL + * D3DERR_INVALIDCALL, if file is NULL + * + */ +HRESULT WINAPI D3DXGetImageInfoFromFileA(LPCSTR file, D3DXIMAGE_INFO *info) +{ + LPWSTR widename; + HRESULT hr; + int strlength; + TRACE("(void): relay\n"); + + if( !file ) return D3DERR_INVALIDCALL; + + strlength = MultiByteToWideChar(CP_ACP, 0, file, -1, NULL, 0); + widename = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, strlength * sizeof(WCHAR)); + MultiByteToWideChar(CP_ACP, 0, file, -1, widename, strlength); + + hr = D3DXGetImageInfoFromFileW(widename, info); + HeapFree(GetProcessHeap(), 0, widename); + + return hr; +} + +HRESULT WINAPI D3DXGetImageInfoFromFileW(LPCWSTR file, D3DXIMAGE_INFO *info) +{ + HRESULT hr; + DWORD size; + LPVOID buffer; + TRACE("(void): relay\n"); + + if( !file ) return D3DERR_INVALIDCALL; + + hr = map_view_of_file(file, &buffer, &size); + if(FAILED(hr)) return D3DXERR_INVALIDDATA; + + hr = D3DXGetImageInfoFromFileInMemory(buffer, size, info); + UnmapViewOfFile(buffer); + + return hr; +} + +/************************************************************ + * D3DXGetImageInfoFromResource + * + * RETURNS + * Success: D3D_OK, if resource is a valid image file + * Failure: D3DXERR_INVALIDDATA, if resource is no valid image file or NULL or + * if we fail to load resource + * + */ +HRESULT WINAPI D3DXGetImageInfoFromResourceA(HMODULE module, LPCSTR resource, D3DXIMAGE_INFO *info) +{ + HRSRC resinfo; + TRACE("(void)\n"); + + resinfo = FindResourceA(module, resource, (LPCSTR)RT_RCDATA); + if(resinfo) { + LPVOID buffer; + HRESULT hr; + DWORD size; + + hr = load_resource_into_memory(module, resinfo, &buffer, &size); + if(FAILED(hr)) return D3DXERR_INVALIDDATA; + return D3DXGetImageInfoFromFileInMemory(buffer, size, info); + } + + resinfo = FindResourceA(module, resource, (LPCSTR)RT_BITMAP); + if(resinfo) { + FIXME("Implement loading bitmaps from resource type RT_BITMAP\n"); + return E_NOTIMPL; + } + return D3DXERR_INVALIDDATA; +} + +HRESULT WINAPI D3DXGetImageInfoFromResourceW(HMODULE module, LPCWSTR resource, D3DXIMAGE_INFO *info) +{ + HRSRC resinfo; + TRACE("(void)\n"); + + resinfo = FindResourceW(module, resource, (LPCWSTR)RT_RCDATA); + if(resinfo) { + LPVOID buffer; + HRESULT hr; + DWORD size; + + hr = load_resource_into_memory(module, resinfo, &buffer, &size); + if(FAILED(hr)) return D3DXERR_INVALIDDATA; + return D3DXGetImageInfoFromFileInMemory(buffer, size, info); + } + + resinfo = FindResourceW(module, resource, (LPCWSTR)RT_BITMAP); + if(resinfo) { + FIXME("Implement loading bitmaps from resource type RT_BITMAP\n"); + return E_NOTIMPL; + } + return D3DXERR_INVALIDDATA; +} diff --git a/dlls/d3dx9_36/tests/Makefile.in b/dlls/d3dx9_36/tests/Makefile.in index 9b882808e4d..708287b31d8 100644 --- a/dlls/d3dx9_36/tests/Makefile.in +++ b/dlls/d3dx9_36/tests/Makefile.in @@ -3,7 +3,7 @@ TOPOBJDIR = ../../.. SRCDIR = @srcdir@ VPATH = @srcdir@ TESTDLL = d3dx9_36.dll -IMPORTS = d3dx9 d3d9 user32 gdi32 kernel32 +IMPORTS = d3dx9 d3d9 user32 kernel32 CTESTS = \ core.c \ diff --git a/dlls/d3dx9_36/tests/core.c b/dlls/d3dx9_36/tests/core.c index b1379ef85fb..99ca08a0226 100644 --- a/dlls/d3dx9_36/tests/core.c +++ b/dlls/d3dx9_36/tests/core.c @@ -75,7 +75,7 @@ static void test_ID3DXSprite(IDirect3DDevice9 *device) HRESULT hr; IDirect3DDevice9_GetDirect3D(device, &d3d); - hr = IDirect3D9_CheckDeviceFormat(d3d, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, D3DFMT_X8R8G8B8, D3DUSAGE_DYNAMIC, D3DRTYPE_TEXTURE, D3DFMT_A8R8G8B8); + hr = IDirect3D9_CheckDeviceFormat(d3d, 0, D3DDEVTYPE_HAL, D3DFMT_UNKNOWN, 0, D3DRTYPE_TEXTURE, D3DFMT_A8R8G8B8); IDirect3D9_Release(d3d); ok (hr == D3D_OK, "D3DFMT_A8R8G8B8 not supported\n"); if (FAILED(hr)) return; @@ -272,151 +272,6 @@ static void test_ID3DXSprite(IDirect3DDevice9 *device) check_release((IUnknown*)tex1, 0); } -static void test_ID3DXFont(IDirect3DDevice9 *device) -{ - D3DXFONT_DESC desc; - ID3DXFont *font; - HRESULT hr; - int ref; - - - /* D3DXCreateFont */ - ref = get_ref((IUnknown*)device); - hr = D3DXCreateFontA(device, 12, 0, FW_DONTCARE, 0, FALSE, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH, "Arial", &font); - ok(hr == D3D_OK, "D3DXCreateFont returned %#x, expected %#x\n", hr, D3D_OK); - check_ref((IUnknown*)device, ref + 1); - check_release((IUnknown*)font, 0); - check_ref((IUnknown*)device, ref); - - hr = D3DXCreateFontA(device, 0, 0, FW_DONTCARE, 0, FALSE, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH, "Arial", &font); - ok(hr == D3D_OK, "D3DXCreateFont returned %#x, expected %#x\n", hr, D3D_OK); - ID3DXFont_Release(font); - - hr = D3DXCreateFontA(device, 12, 0, FW_DONTCARE, 0, FALSE, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH, NULL, &font); - ok(hr == D3D_OK, "D3DXCreateFont returned %#x, expected %#x\n", hr, D3D_OK); - ID3DXFont_Release(font); - - hr = D3DXCreateFontA(device, 12, 0, FW_DONTCARE, 0, FALSE, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH, "", &font); - ok(hr == D3D_OK, "D3DXCreateFont returned %#x, expected %#x\n", hr, D3D_OK); - ID3DXFont_Release(font); - - hr = D3DXCreateFontA(NULL, 12, 0, FW_DONTCARE, 0, FALSE, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH, "Arial", &font); - ok(hr == D3DERR_INVALIDCALL, "D3DXCreateFont returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXCreateFontA(device, 12, 0, FW_DONTCARE, 0, FALSE, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH, "Arial", NULL); - ok(hr == D3DERR_INVALIDCALL, "D3DXCreateFont returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXCreateFontA(NULL, 12, 0, FW_DONTCARE, 0, FALSE, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH, "Arial", NULL); - ok(hr == D3DERR_INVALIDCALL, "D3DXCreateFont returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - - /* D3DXCreateFontIndirect */ - desc.Height = 12; - desc.Width = 0; - desc.Weight = FW_DONTCARE; - desc.MipLevels = 0; - desc.Italic = FALSE; - desc.CharSet = DEFAULT_CHARSET; - desc.OutputPrecision = OUT_DEFAULT_PRECIS; - desc.Quality = DEFAULT_QUALITY; - desc.PitchAndFamily = DEFAULT_PITCH; - strcpy(desc.FaceName, "Arial"); - hr = D3DXCreateFontIndirectA(device, &desc, &font); - ok(hr == D3D_OK, "D3DXCreateFontIndirect returned %#x, expected %#x\n", hr, D3D_OK); - ID3DXFont_Release(font); - - hr = D3DXCreateFontIndirectA(NULL, &desc, &font); - ok(hr == D3DERR_INVALIDCALL, "D3DXCreateFontIndirect returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXCreateFontIndirectA(device, NULL, &font); - ok(hr == D3DERR_INVALIDCALL, "D3DXCreateFontIndirect returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXCreateFontIndirectA(device, &desc, NULL); - ok(hr == D3DERR_INVALIDCALL, "D3DXCreateFontIndirect returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - - /* ID3DXFont_GetDevice */ - hr = D3DXCreateFontA(device, 12, 0, FW_DONTCARE, 0, FALSE, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH, "Arial", &font); - if(SUCCEEDED(hr)) { - IDirect3DDevice9 *bufdev; - - hr = ID3DXFont_GetDevice(font, NULL); - ok(hr == D3DERR_INVALIDCALL, "ID3DXFont_GetDevice returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - ref = get_ref((IUnknown*)device); - hr = ID3DXFont_GetDevice(font, &bufdev); - ok(hr == D3D_OK, "ID3DXFont_GetDevice returned %#x, expected %#x\n", hr, D3D_OK); - check_release((IUnknown*)bufdev, ref); - - ID3DXFont_Release(font); - } else skip("Failed to create a ID3DXFont object\n"); - - - /* ID3DXFont_GetDesc */ - hr = D3DXCreateFontA(device, 12, 8, FW_BOLD, 2, TRUE, ANSI_CHARSET, OUT_RASTER_PRECIS, ANTIALIASED_QUALITY, VARIABLE_PITCH, "Arial", &font); - if(SUCCEEDED(hr)) { - hr = ID3DXFont_GetDescA(font, NULL); - ok(hr == D3DERR_INVALIDCALL, "ID3DXFont_GetDevice returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = ID3DXFont_GetDescA(font, &desc); - ok(hr == D3D_OK, "ID3DXFont_GetDevice returned %#x, expected %#x\n", hr, D3D_OK); - - ok(desc.Height == 12, "ID3DXFont_GetDesc returned font height %d, expected %d\n", desc.Height, 12); - ok(desc.Width == 8, "ID3DXFont_GetDesc returned font width %d, expected %d\n", desc.Width, 8); - ok(desc.Weight == FW_BOLD, "ID3DXFont_GetDesc returned font weight %d, expected %d\n", desc.Weight, FW_BOLD); - ok(desc.MipLevels == 2, "ID3DXFont_GetDesc returned font miplevels %d, expected %d\n", desc.MipLevels, 2); - ok(desc.Italic == TRUE, "ID3DXFont_GetDesc says Italic was %d, but Italic should be %d\n", desc.Italic, TRUE); - ok(desc.CharSet == ANSI_CHARSET, "ID3DXFont_GetDesc returned font charset %d, expected %d\n", desc.CharSet, ANSI_CHARSET); - ok(desc.OutputPrecision == OUT_RASTER_PRECIS, "ID3DXFont_GetDesc returned an output precision of %d, expected %d\n", desc.OutputPrecision, OUT_RASTER_PRECIS); - ok(desc.Quality == ANTIALIASED_QUALITY, "ID3DXFont_GetDesc returned font quality %d, expected %d\n", desc.Quality, ANTIALIASED_QUALITY); - ok(desc.PitchAndFamily == VARIABLE_PITCH, "ID3DXFont_GetDesc returned pitch and family %d, expected %d\n", desc.PitchAndFamily, VARIABLE_PITCH); - ok(strcmp(desc.FaceName, "Arial") == 0, "ID3DXFont_GetDesc returned facename \"%s\", expected \"%s\"\n", desc.FaceName, "Arial"); - - ID3DXFont_Release(font); - } else skip("Failed to create a ID3DXFont object\n"); - - - /* ID3DXFont_GetDC + ID3DXFont_GetTextMetrics */ - hr = D3DXCreateFontA(device, 12, 0, FW_DONTCARE, 0, FALSE, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH, "Arial", &font); - if(SUCCEEDED(hr)) { - HDC hdc; - - hdc = ID3DXFont_GetDC(font); - ok(hdc != NULL, "ID3DXFont_GetDC returned an invalid handle\n"); - if(hdc) { - TEXTMETRICA metrics, expmetrics; - BOOL ret; - - ret = ID3DXFont_GetTextMetricsA(font, &metrics); - ok(ret, "ID3DXFont_GetTextMetricsA failed\n"); - ret = GetTextMetricsA(hdc, &expmetrics); - ok(ret, "GetTextMetricsA failed\n"); - - ok(metrics.tmHeight == expmetrics.tmHeight, "Returned height %d, expected %d\n", metrics.tmHeight, expmetrics.tmHeight); - ok(metrics.tmAscent == expmetrics.tmAscent, "Returned ascent %d, expected %d\n", metrics.tmAscent, expmetrics.tmAscent); - ok(metrics.tmDescent == expmetrics.tmDescent, "Returned descent %d, expected %d\n", metrics.tmDescent, expmetrics.tmDescent); - ok(metrics.tmInternalLeading == expmetrics.tmInternalLeading, "Returned internal leading %d, expected %d\n", metrics.tmInternalLeading, expmetrics.tmInternalLeading); - ok(metrics.tmExternalLeading == expmetrics.tmExternalLeading, "Returned external leading %d, expected %d\n", metrics.tmExternalLeading, expmetrics.tmExternalLeading); - ok(metrics.tmAveCharWidth == expmetrics.tmAveCharWidth, "Returned average char width %d, expected %d\n", metrics.tmAveCharWidth, expmetrics.tmAveCharWidth); - ok(metrics.tmMaxCharWidth == expmetrics.tmMaxCharWidth, "Returned maximum char width %d, expected %d\n", metrics.tmMaxCharWidth, expmetrics.tmMaxCharWidth); - ok(metrics.tmWeight == expmetrics.tmWeight, "Returned weight %d, expected %d\n", metrics.tmWeight, expmetrics.tmWeight); - ok(metrics.tmOverhang == expmetrics.tmOverhang, "Returned overhang %d, expected %d\n", metrics.tmOverhang, expmetrics.tmOverhang); - ok(metrics.tmDigitizedAspectX == expmetrics.tmDigitizedAspectX, "Returned digitized x aspect %d, expected %d\n", metrics.tmDigitizedAspectX, expmetrics.tmDigitizedAspectX); - ok(metrics.tmDigitizedAspectY == expmetrics.tmDigitizedAspectY, "Returned digitized y aspect %d, expected %d\n", metrics.tmDigitizedAspectY, expmetrics.tmDigitizedAspectY); - ok(metrics.tmFirstChar == expmetrics.tmFirstChar, "Returned first char %d, expected %d\n", metrics.tmFirstChar, expmetrics.tmFirstChar); - ok(metrics.tmLastChar == expmetrics.tmLastChar, "Returned last char %d, expected %d\n", metrics.tmLastChar, expmetrics.tmLastChar); - ok(metrics.tmDefaultChar == expmetrics.tmDefaultChar, "Returned default char %d, expected %d\n", metrics.tmDefaultChar, expmetrics.tmDefaultChar); - ok(metrics.tmBreakChar == expmetrics.tmBreakChar, "Returned break char %d, expected %d\n", metrics.tmBreakChar, expmetrics.tmBreakChar); - ok(metrics.tmItalic == expmetrics.tmItalic, "Returned italic %d, expected %d\n", metrics.tmItalic, expmetrics.tmItalic); - ok(metrics.tmUnderlined == expmetrics.tmUnderlined, "Returned underlined %d, expected %d\n", metrics.tmUnderlined, expmetrics.tmUnderlined); - ok(metrics.tmStruckOut == expmetrics.tmStruckOut, "Returned struck out %d, expected %d\n", metrics.tmStruckOut, expmetrics.tmStruckOut); - ok(metrics.tmPitchAndFamily == expmetrics.tmPitchAndFamily, "Returned pitch and family %d, expected %d\n", metrics.tmPitchAndFamily, expmetrics.tmPitchAndFamily); - ok(metrics.tmCharSet == expmetrics.tmCharSet, "Returned charset %d, expected %d\n", metrics.tmCharSet, expmetrics.tmCharSet); - } - ID3DXFont_Release(font); - } else skip("Failed to create a ID3DXFont object\n"); -} - START_TEST(core) { HWND wnd; @@ -449,7 +304,6 @@ START_TEST(core) } test_ID3DXSprite(device); - test_ID3DXFont(device); check_release((IUnknown*)device, 0); check_release((IUnknown*)d3d, 0); diff --git a/dlls/d3dx9_36/tests/math.c b/dlls/d3dx9_36/tests/math.c dissimilarity index 74% index 60d71939f35..8a9c3e2b8ac 100644 --- a/dlls/d3dx9_36/tests/math.c +++ b/dlls/d3dx9_36/tests/math.c @@ -1,2239 +1,826 @@ -/* - * Copyright 2008 David Adam - * Copyright 2008 Luis Busquets - * Copyright 2008 Philip Nilsson - * Copyright 2008 Henri Verbeet - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "wine/test.h" -#include "d3dx9.h" - -#define ARRAY_SIZE 5 - -#define admitted_error 0.0001f - -#define relative_error(exp, out) ((exp == out) ? 0.0f : (fabs(out - exp) / fabs(exp))) - -#define expect_color(expectedcolor,gotcolor) ok((fabs(expectedcolor.r-gotcolor.r) admitted_error) - return FALSE; - } - } - - return TRUE; -} - -#define expect_mat(expectedmat, gotmat) \ -do { \ - const D3DXMATRIX *__m1 = (expectedmat); \ - const D3DXMATRIX *__m2 = (gotmat); \ - ok(compare_matrix(__m1, __m2), "Expected matrix=\n(%f,%f,%f,%f\n %f,%f,%f,%f\n %f,%f,%f,%f\n %f,%f,%f,%f\n)\n\n" \ - "Got matrix=\n(%f,%f,%f,%f\n %f,%f,%f,%f\n %f,%f,%f,%f\n %f,%f,%f,%f)\n", \ - U(*__m1).m[0][0], U(*__m1).m[0][1], U(*__m1).m[0][2], U(*__m1).m[0][3], \ - U(*__m1).m[1][0], U(*__m1).m[1][1], U(*__m1).m[1][2], U(*__m1).m[1][3], \ - U(*__m1).m[2][0], U(*__m1).m[2][1], U(*__m1).m[2][2], U(*__m1).m[2][3], \ - U(*__m1).m[3][0], U(*__m1).m[3][1], U(*__m1).m[3][2], U(*__m1).m[3][3], \ - U(*__m2).m[0][0], U(*__m2).m[0][1], U(*__m2).m[0][2], U(*__m2).m[0][3], \ - U(*__m2).m[1][0], U(*__m2).m[1][1], U(*__m2).m[1][2], U(*__m2).m[1][3], \ - U(*__m2).m[2][0], U(*__m2).m[2][1], U(*__m2).m[2][2], U(*__m2).m[2][3], \ - U(*__m2).m[3][0], U(*__m2).m[3][1], U(*__m2).m[3][2], U(*__m2).m[3][3]); \ -} while(0) - -#define compare_rotation(exp, got) \ - ok(fabs(exp.w - got.w) < admitted_error && \ - fabs(exp.x - got.x) < admitted_error && \ - fabs(exp.y - got.y) < admitted_error && \ - fabs(exp.z - got.z) < admitted_error, \ - "Expected rotation = (%f, %f, %f, %f), \ - got rotation = (%f, %f, %f, %f)\n", \ - exp.w, exp.x, exp.y, exp.z, got.w, got.x, got.y, got.z) - -#define compare_scale(exp, got) \ - ok(fabs(exp.x - got.x) < admitted_error && \ - fabs(exp.y - got.y) < admitted_error && \ - fabs(exp.z - got.z) < admitted_error, \ - "Expected scale = (%f, %f, %f), \ - got scale = (%f, %f, %f)\n", \ - exp.x, exp.y, exp.z, got.x, got.y, got.z) - -#define compare_translation(exp, got) \ - ok(fabs(exp.x - got.x) < admitted_error && \ - fabs(exp.y - got.y) < admitted_error && \ - fabs(exp.z - got.z) < admitted_error, \ - "Expected translation = (%f, %f, %f), \ - got translation = (%f, %f, %f)\n", \ - exp.x, exp.y, exp.z, got.x, got.y, got.z) - -#define compare_vectors(exp, out) \ - for (i = 0; i < ARRAY_SIZE + 2; ++i) { \ - ok(relative_error(exp[i].x, out[i].x) < admitted_error && \ - relative_error(exp[i].y, out[i].y) < admitted_error && \ - relative_error(exp[i].z, out[i].z) < admitted_error && \ - relative_error(exp[i].w, out[i].w) < admitted_error, \ - "Got (%f, %f, %f, %f), expected (%f, %f, %f, %f) for index %d.\n", \ - out[i].x, out[i].y, out[i].z, out[i].w, \ - exp[i].x, exp[i].y, exp[i].z, exp[i].w, \ - i); \ - } - -#define compare_planes(exp, out) \ - for (i = 0; i < ARRAY_SIZE + 2; ++i) { \ - ok(relative_error(exp[i].a, out[i].a) < admitted_error && \ - relative_error(exp[i].b, out[i].b) < admitted_error && \ - relative_error(exp[i].c, out[i].c) < admitted_error && \ - relative_error(exp[i].d, out[i].d) < admitted_error, \ - "Got (%f, %f, %f, %f), expected (%f, %f, %f, %f) for index %d.\n", \ - out[i].a, out[i].b, out[i].c, out[i].d, \ - exp[i].a, exp[i].b, exp[i].c, exp[i].d, \ - i); \ - } -#define expect_plane(expectedplane,gotplane) ok((fabs(expectedplane.a-gotplane.a)0 */ - U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; - U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; - U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; - U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; - U(mat).m[0][0] = 10.0f; U(mat).m[1][1] = 20.0f; U(mat).m[2][2] = 30.0f; - U(mat).m[3][3] = 48.0f; - expectedquat.x = 2.368682f; expectedquat.y = 0.768221f; expectedquat.z = -0.384111f; expectedquat.w = 3.905125f; - D3DXQuaternionRotationMatrix(&gotquat,&mat); - expect_vec4(expectedquat,gotquat); - /* test the case when the greater element is (2,2) */ - U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; - U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; - U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; - U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; - U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = -60.0f; U(mat).m[2][2] = 40.0f; - U(mat).m[3][3] = 48.0f; - expectedquat.x = 1.233905f; expectedquat.y = -0.237290f; expectedquat.z = 5.267827f; expectedquat.w = -0.284747f; - D3DXQuaternionRotationMatrix(&gotquat,&mat); - expect_vec4(expectedquat,gotquat); - /* test the case when the greater element is (1,1) */ - U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; - U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; - U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; - U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; - U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 60.0f; U(mat).m[2][2] = -80.0f; - U(mat).m[3][3] = 48.0f; - expectedquat.x = 0.651031f; expectedquat.y = 6.144103f; expectedquat.z = -0.203447f; expectedquat.w = 0.488273f; - D3DXQuaternionRotationMatrix(&gotquat,&mat); - expect_vec4(expectedquat,gotquat); - /* test the case when the trace is near 0 in a matrix which is not a rotation */ - U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; - U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; - U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; - U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; - U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = -0.9f; - U(mat).m[3][3] = 48.0f; - expectedquat.x = 1.709495f; expectedquat.y = 2.339872f; expectedquat.z = -0.534217f; expectedquat.w = 1.282122f; - D3DXQuaternionRotationMatrix(&gotquat,&mat); - expect_vec4(expectedquat,gotquat); - /* test the case when the trace is 0.49 in a matrix which is not a rotation */ - U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; - U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; - U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; - U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; - U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = -0.51f; - U(mat).m[3][3] = 48.0f; - expectedquat.x = 1.724923f; expectedquat.y = 2.318944f; expectedquat.z = -0.539039f; expectedquat.w = 1.293692f; - D3DXQuaternionRotationMatrix(&gotquat,&mat); - expect_vec4(expectedquat,gotquat); - /* test the case when the trace is 0.51 in a matrix which is not a rotation */ - U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; - U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; - U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; - U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; - U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = -0.49f; - U(mat).m[3][3] = 48.0f; - expectedquat.x = 1.725726f; expectedquat.y = 2.317865f; expectedquat.z = -0.539289f; expectedquat.w = 1.294294f; - D3DXQuaternionRotationMatrix(&gotquat,&mat); - expect_vec4(expectedquat,gotquat); - /* test the case when the trace is 0.99 in a matrix which is not a rotation */ - U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; - U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; - U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; - U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; - U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = -0.01f; - U(mat).m[3][3] = 48.0f; - expectedquat.x = 1.745328f; expectedquat.y = 2.291833f; expectedquat.z = -0.545415f; expectedquat.w = 1.308996f; - D3DXQuaternionRotationMatrix(&gotquat,&mat); - expect_vec4(expectedquat,gotquat); - /* test the case when the trace is 1.0 in a matrix which is not a rotation */ - U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; - U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; - U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; - U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; - U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = 0.0f; - U(mat).m[3][3] = 48.0f; - expectedquat.x = 1.745743f; expectedquat.y = 2.291288f; expectedquat.z = -0.545545f; expectedquat.w = 1.309307f; - D3DXQuaternionRotationMatrix(&gotquat,&mat); - expect_vec4(expectedquat,gotquat); - /* test the case when the trace is 1.01 in a matrix which is not a rotation */ - U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; - U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; - U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; - U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; - U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = 0.01f; - U(mat).m[3][3] = 48.0f; - expectedquat.x = 18.408188f; expectedquat.y = 5.970223f; expectedquat.z = -2.985111f; expectedquat.w = 0.502494f; - D3DXQuaternionRotationMatrix(&gotquat,&mat); - expect_vec4(expectedquat,gotquat); - /* test the case when the trace is 1.5 in a matrix which is not a rotation */ - U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; - U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; - U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; - U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; - U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = 0.5f; - U(mat).m[3][3] = 48.0f; - expectedquat.x = 15.105186f; expectedquat.y = 4.898980f; expectedquat.z = -2.449490f; expectedquat.w = 0.612372f; - D3DXQuaternionRotationMatrix(&gotquat,&mat); - expect_vec4(expectedquat,gotquat); - /* test the case when the trace is 1.7 in a matrix which is not a rotation */ - U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; - U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; - U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; - U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; - U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = 0.70f; - U(mat).m[3][3] = 48.0f; - expectedquat.x = 14.188852f; expectedquat.y = 4.601790f; expectedquat.z = -2.300895f; expectedquat.w = 0.651920f; - D3DXQuaternionRotationMatrix(&gotquat,&mat); - expect_vec4(expectedquat,gotquat); - /* test the case when the trace is 1.99 in a matrix which is not a rotation */ - U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; - U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; - U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; - U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; - U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = 0.99f; - U(mat).m[3][3] = 48.0f; - expectedquat.x = 13.114303f; expectedquat.y = 4.253287f; expectedquat.z = -2.126644f; expectedquat.w = 0.705337f; - D3DXQuaternionRotationMatrix(&gotquat,&mat); - expect_vec4(expectedquat,gotquat); - /* test the case when the trace is 2.0 in a matrix which is not a rotation */ - U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f; - U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f; - U(mat).m[2][0] = 19.0f; U(mat).m[2][1] = -21.0f; U(mat).m[2][3] = 43.0f; - U(mat).m[3][0] = 2.0f; U(mat).m[3][1] = 3.0f; U(mat).m[3][2] = -4.0f; - U(mat).m[0][0] = -10.0f; U(mat).m[1][1] = 10.0f; U(mat).m[2][2] = 2.0f; - U(mat).m[3][3] = 48.0f; - expectedquat.x = 10.680980f; expectedquat.y = 3.464102f; expectedquat.z = -1.732051f; expectedquat.w = 0.866025f; - D3DXQuaternionRotationMatrix(&gotquat,&mat); - expect_vec4(expectedquat,gotquat); - -/*_______________D3DXQuaternionRotationYawPitchRoll__________*/ - expectedquat.x = 0.303261f; expectedquat.y = 0.262299f; expectedquat.z = 0.410073f; expectedquat.w = 0.819190f; - D3DXQuaternionRotationYawPitchRoll(&gotquat,D3DX_PI/4.0f,D3DX_PI/11.0f,D3DX_PI/3.0f); - expect_vec4(expectedquat,gotquat); - -/*_______________D3DXQuaternionSlerp________________________*/ - expectedquat.x = -0.2f; expectedquat.y = 2.6f; expectedquat.z = 1.3f; expectedquat.w = 9.1f; - D3DXQuaternionSlerp(&gotquat,&q,&r,scale); - expect_vec4(expectedquat,gotquat); - expectedquat.x = 334.0f; expectedquat.y = -31.9f; expectedquat.z = 6.1f; expectedquat.w = 6.7f; - D3DXQuaternionSlerp(&gotquat,&q,&t,scale); - expect_vec4(expectedquat,gotquat); - expectedquat.x = 0.239485f; expectedquat.y = 0.346580f; expectedquat.z = 0.453676f; expectedquat.w = 0.560772f; - D3DXQuaternionSlerp(&gotquat,&smallq,&smallr,scale); - expect_vec4(expectedquat,gotquat); - -/*_______________D3DXQuaternionSquad________________________*/ - expectedquat.x = -156.296f; expectedquat.y = 30.242f; expectedquat.z = -2.5022f; expectedquat.w = 7.3576f; - D3DXQuaternionSquad(&gotquat,&q,&r,&t,&u,scale); - expect_vec4(expectedquat,gotquat); - -/*_______________D3DXQuaternionToAxisAngle__________________*/ - Nq.x = 1.0f/22.0f; Nq.y = 2.0f/22.0f; Nq.z = 4.0f/22.0f; Nq.w = 10.0f/22.0f; - expectedvec.x = 1.0f/22.0f; expectedvec.y = 2.0f/22.0f; expectedvec.z = 4.0f/22.0f; - expected = 2.197869f; - D3DXQuaternionToAxisAngle(&Nq,&axis,&angle); - expect_vec3(expectedvec,axis); - ok(fabs( angle - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, angle); - /* Test if |w|>1.0f */ - expectedvec.x = 1.0f; expectedvec.y = 2.0f; expectedvec.z = 4.0f; - expected = 0.0f; - D3DXQuaternionToAxisAngle(&q,&axis,&angle); - expect_vec3(expectedvec,axis); - /* Test the null quaternion */ - expectedvec.x = 0.0f; expectedvec.y = 0.0f; expectedvec.z = 0.0f; - expected = 3.141593f; - D3DXQuaternionToAxisAngle(&nul,&axis,&angle); - expect_vec3(expectedvec,axis); - ok(fabs( angle - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, angle); -} - -static void D3DXVector2Test(void) -{ - D3DXVECTOR2 expectedvec, gotvec, nul, u, v, w, x; - LPD3DXVECTOR2 funcpointer; - D3DXVECTOR4 expectedtrans, gottrans; - D3DXMATRIX mat; - FLOAT coeff1, coeff2, expected, got, scale; - - nul.x = 0.0f; nul.y = 0.0f; - u.x = 3.0f; u.y = 4.0f; - v.x = -7.0f; v.y = 9.0f; - w.x = 4.0f; w.y = -3.0f; - x.x = 2.0f; x.y = -11.0f; - - U(mat).m[0][0] = 1.0f; U(mat).m[0][1] = 2.0f; U(mat).m[0][2] = 3.0f; U(mat).m[0][3] = 4.0f; - U(mat).m[1][0] = 5.0f; U(mat).m[1][1] = 6.0f; U(mat).m[1][2] = 7.0f; U(mat).m[1][3] = 8.0f; - U(mat).m[2][0] = 9.0f; U(mat).m[2][1] = 10.0f; U(mat).m[2][2] = 11.0f; U(mat).m[2][3] = 12.0f; - U(mat).m[3][0] = 13.0f; U(mat).m[3][1] = 14.0f; U(mat).m[3][2] = 15.0f; U(mat).m[3][3] = 16.0f; - - coeff1 = 2.0f; coeff2 = 5.0f; - scale = -6.5f; - -/*_______________D3DXVec2Add__________________________*/ - expectedvec.x = -4.0f; expectedvec.y = 13.0f; - D3DXVec2Add(&gotvec,&u,&v); - expect_vec(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec2Add(&gotvec,NULL,&v); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec2Add(NULL,NULL,NULL); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec2BaryCentric___________________*/ - expectedvec.x = -12.0f; expectedvec.y = -21.0f; - D3DXVec2BaryCentric(&gotvec,&u,&v,&w,coeff1,coeff2); - expect_vec(expectedvec,gotvec); - -/*_______________D3DXVec2CatmullRom____________________*/ - expectedvec.x = 5820.25f; expectedvec.y = -3654.5625f; - D3DXVec2CatmullRom(&gotvec,&u,&v,&w,&x,scale); - expect_vec(expectedvec,gotvec); - -/*_______________D3DXVec2CCW__________________________*/ - expected = 55.0f; - got = D3DXVec2CCW(&u,&v); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - /* Tests the case NULL */ - expected=0.0f; - got = D3DXVec2CCW(NULL,&v); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - expected=0.0f; - got = D3DXVec2CCW(NULL,NULL); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - -/*_______________D3DXVec2Dot__________________________*/ - expected = 15.0f; - got = D3DXVec2Dot(&u,&v); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - /* Tests the case NULL */ - expected=0.0f; - got = D3DXVec2Dot(NULL,&v); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - expected=0.0f; - got = D3DXVec2Dot(NULL,NULL); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - -/*_______________D3DXVec2Hermite__________________________*/ - expectedvec.x = 2604.625f; expectedvec.y = -4533.0f; - D3DXVec2Hermite(&gotvec,&u,&v,&w,&x,scale); - expect_vec(expectedvec,gotvec); - -/*_______________D3DXVec2Length__________________________*/ - expected = 5.0f; - got = D3DXVec2Length(&u); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - /* Tests the case NULL */ - expected=0.0f; - got = D3DXVec2Length(NULL); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - -/*_______________D3DXVec2LengthSq________________________*/ - expected = 25.0f; - got = D3DXVec2LengthSq(&u); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - /* Tests the case NULL */ - expected=0.0f; - got = D3DXVec2LengthSq(NULL); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - -/*_______________D3DXVec2Lerp__________________________*/ - expectedvec.x = 68.0f; expectedvec.y = -28.5f; - D3DXVec2Lerp(&gotvec,&u,&v,scale); - expect_vec(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec2Lerp(&gotvec,NULL,&v,scale); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec2Lerp(NULL,NULL,NULL,scale); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec2Maximize__________________________*/ - expectedvec.x = 3.0f; expectedvec.y = 9.0f; - D3DXVec2Maximize(&gotvec,&u,&v); - expect_vec(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec2Maximize(&gotvec,NULL,&v); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec2Maximize(NULL,NULL,NULL); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec2Minimize__________________________*/ - expectedvec.x = -7.0f; expectedvec.y = 4.0f; - D3DXVec2Minimize(&gotvec,&u,&v); - expect_vec(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec2Minimize(&gotvec,NULL,&v); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec2Minimize(NULL,NULL,NULL); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec2Normalize_________________________*/ - expectedvec.x = 0.6f; expectedvec.y = 0.8f; - D3DXVec2Normalize(&gotvec,&u); - expect_vec(expectedvec,gotvec); - /* Test the nul vector */ - expectedvec.x = 0.0f; expectedvec.y = 0.0f; - D3DXVec2Normalize(&gotvec,&nul); - expect_vec(expectedvec,gotvec); - -/*_______________D3DXVec2Scale____________________________*/ - expectedvec.x = -19.5f; expectedvec.y = -26.0f; - D3DXVec2Scale(&gotvec,&u,scale); - expect_vec(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec2Scale(&gotvec,NULL,scale); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec2Scale(NULL,NULL,scale); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec2Subtract__________________________*/ - expectedvec.x = 10.0f; expectedvec.y = -5.0f; - D3DXVec2Subtract(&gotvec,&u,&v); - expect_vec(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec2Subtract(&gotvec,NULL,&v); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec2Subtract(NULL,NULL,NULL); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec2Transform_______________________*/ - expectedtrans.x = 36.0f; expectedtrans.y = 44.0f; expectedtrans.z = 52.0f; expectedtrans.w = 60.0f; - D3DXVec2Transform(&gottrans,&u,&mat); - expect_vec4(expectedtrans,gottrans); - -/*_______________D3DXVec2TransformCoord_______________________*/ - expectedvec.x = 0.6f; expectedvec.y = 11.0f/15.0f; - D3DXVec2TransformCoord(&gotvec,&u,&mat); - expect_vec(expectedvec,gotvec); - - /*_______________D3DXVec2TransformNormal______________________*/ - expectedvec.x = 23.0f; expectedvec.y = 30.0f; - D3DXVec2TransformNormal(&gotvec,&u,&mat); - expect_vec(expectedvec,gotvec); -} - -static void D3DXVector3Test(void) -{ - D3DVIEWPORT9 viewport; - D3DXVECTOR3 expectedvec, gotvec, nul, u, v, w, x; - LPD3DXVECTOR3 funcpointer; - D3DXVECTOR4 expectedtrans, gottrans; - D3DXMATRIX mat, projection, view, world; - FLOAT coeff1, coeff2, expected, got, scale; - - nul.x = 0.0f; nul.y = 0.0f; nul.z = 0.0f; - u.x = 9.0f; u.y = 6.0f; u.z = 2.0f; - v.x = 2.0f; v.y = -3.0f; v.z = -4.0; - w.x = 3.0f; w.y = -5.0f; w.z = 7.0f; - x.x = 4.0f; x.y = 1.0f; x.z = 11.0f; - - viewport.Width = 800; viewport.MinZ = 0.2f; viewport.X = 10; - viewport.Height = 680; viewport.MaxZ = 0.9f; viewport.Y = 5; - - U(mat).m[0][0] = 1.0f; U(mat).m[0][1] = 2.0f; U(mat).m[0][2] = 3.0f; U(mat).m[0][3] = 4.0f; - U(mat).m[1][0] = 5.0f; U(mat).m[1][1] = 6.0f; U(mat).m[1][2] = 7.0f; U(mat).m[1][3] = 8.0f; - U(mat).m[2][0] = 9.0f; U(mat).m[2][1] = 10.0f; U(mat).m[2][2] = 11.0f; U(mat).m[2][3] = 12.0f; - U(mat).m[3][0] = 13.0f; U(mat).m[3][1] = 14.0f; U(mat).m[3][2] = 15.0f; U(mat).m[3][3] = 16.0f; - - U(view).m[0][1] = 5.0f; U(view).m[0][2] = 7.0f; U(view).m[0][3] = 8.0f; - U(view).m[1][0] = 11.0f; U(view).m[1][2] = 16.0f; U(view).m[1][3] = 33.0f; - U(view).m[2][0] = 19.0f; U(view).m[2][1] = -21.0f; U(view).m[2][3] = 43.0f; - U(view).m[3][0] = 2.0f; U(view).m[3][1] = 3.0f; U(view).m[3][2] = -4.0f; - U(view).m[0][0] = 10.0f; U(view).m[1][1] = 20.0f; U(view).m[2][2] = 30.0f; - U(view).m[3][3] = -40.0f; - - U(world).m[0][0] = 21.0f; U(world).m[0][1] = 2.0f; U(world).m[0][2] = 3.0f; U(world).m[0][3] = 4.0; - U(world).m[1][0] = 5.0f; U(world).m[1][1] = 23.0f; U(world).m[1][2] = 7.0f; U(world).m[1][3] = 8.0f; - U(world).m[2][0] = -8.0f; U(world).m[2][1] = -7.0f; U(world).m[2][2] = 25.0f; U(world).m[2][3] = -5.0f; - U(world).m[3][0] = -4.0f; U(world).m[3][1] = -3.0f; U(world).m[3][2] = -2.0f; U(world).m[3][3] = 27.0f; - - coeff1 = 2.0f; coeff2 = 5.0f; - scale = -6.5f; - -/*_______________D3DXVec3Add__________________________*/ - expectedvec.x = 11.0f; expectedvec.y = 3.0f; expectedvec.z = -2.0f; - D3DXVec3Add(&gotvec,&u,&v); - expect_vec3(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec3Add(&gotvec,NULL,&v); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec3Add(NULL,NULL,NULL); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec3BaryCentric___________________*/ - expectedvec.x = -35.0f; expectedvec.y = -67.0; expectedvec.z = 15.0f; - D3DXVec3BaryCentric(&gotvec,&u,&v,&w,coeff1,coeff2); - - expect_vec3(expectedvec,gotvec); - -/*_______________D3DXVec3CatmullRom____________________*/ - expectedvec.x = 1458.0f; expectedvec.y = 22.1875f; expectedvec.z = 4141.375f; - D3DXVec3CatmullRom(&gotvec,&u,&v,&w,&x,scale); - expect_vec3(expectedvec,gotvec); - -/*_______________D3DXVec3Cross________________________*/ - expectedvec.x = -18.0f; expectedvec.y = 40.0f; expectedvec.z = -39.0f; - D3DXVec3Cross(&gotvec,&u,&v); - expect_vec3(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec3Cross(&gotvec,NULL,&v); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec3Cross(NULL,NULL,NULL); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec3Dot__________________________*/ - expected = -8.0f; - got = D3DXVec3Dot(&u,&v); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - /* Tests the case NULL */ - expected=0.0f; - got = D3DXVec3Dot(NULL,&v); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - expected=0.0f; - got = D3DXVec3Dot(NULL,NULL); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - -/*_______________D3DXVec3Hermite__________________________*/ - expectedvec.x = -6045.75f; expectedvec.y = -6650.0f; expectedvec.z = 1358.875f; - D3DXVec3Hermite(&gotvec,&u,&v,&w,&x,scale); - expect_vec3(expectedvec,gotvec); - -/*_______________D3DXVec3Length__________________________*/ - expected = 11.0f; - got = D3DXVec3Length(&u); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - /* Tests the case NULL */ - expected=0.0f; - got = D3DXVec3Length(NULL); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - -/*_______________D3DXVec3LengthSq________________________*/ - expected = 121.0f; - got = D3DXVec3LengthSq(&u); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - /* Tests the case NULL */ - expected=0.0f; - got = D3DXVec3LengthSq(NULL); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - -/*_______________D3DXVec3Lerp__________________________*/ - expectedvec.x = 54.5f; expectedvec.y = 64.5f, expectedvec.z = 41.0f ; - D3DXVec3Lerp(&gotvec,&u,&v,scale); - expect_vec3(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec3Lerp(&gotvec,NULL,&v,scale); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec3Lerp(NULL,NULL,NULL,scale); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec3Maximize__________________________*/ - expectedvec.x = 9.0f; expectedvec.y = 6.0f; expectedvec.z = 2.0f; - D3DXVec3Maximize(&gotvec,&u,&v); - expect_vec3(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec3Maximize(&gotvec,NULL,&v); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec3Maximize(NULL,NULL,NULL); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec3Minimize__________________________*/ - expectedvec.x = 2.0f; expectedvec.y = -3.0f; expectedvec.z = -4.0f; - D3DXVec3Minimize(&gotvec,&u,&v); - expect_vec3(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec3Minimize(&gotvec,NULL,&v); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec3Minimize(NULL,NULL,NULL); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec3Normalize_________________________*/ - expectedvec.x = 9.0f/11.0f; expectedvec.y = 6.0f/11.0f; expectedvec.z = 2.0f/11.0f; - D3DXVec3Normalize(&gotvec,&u); - expect_vec3(expectedvec,gotvec); - /* Test the nul vector */ - expectedvec.x = 0.0f; expectedvec.y = 0.0f; expectedvec.z = 0.0f; - D3DXVec3Normalize(&gotvec,&nul); - expect_vec3(expectedvec,gotvec); - -/*_______________D3DXVec3Project_________________________*/ - expectedvec.x = 1135.721924f; expectedvec.y = 147.086914f; expectedvec.z = 0.153412f; - D3DXMatrixPerspectiveFovLH(&projection,D3DX_PI/4.0f,20.0f/17.0f,1.0f,1000.0f); - D3DXVec3Project(&gotvec,&u,&viewport,&projection,&view,&world); - expect_vec3(expectedvec,gotvec); - -/*_______________D3DXVec3Scale____________________________*/ - expectedvec.x = -58.5f; expectedvec.y = -39.0f; expectedvec.z = -13.0f; - D3DXVec3Scale(&gotvec,&u,scale); - expect_vec3(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec3Scale(&gotvec,NULL,scale); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec3Scale(NULL,NULL,scale); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec3Subtract_______________________*/ - expectedvec.x = 7.0f; expectedvec.y = 9.0f; expectedvec.z = 6.0f; - D3DXVec3Subtract(&gotvec,&u,&v); - expect_vec3(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec3Subtract(&gotvec,NULL,&v); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec3Subtract(NULL,NULL,NULL); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec3Transform_______________________*/ - expectedtrans.x = 70.0f; expectedtrans.y = 88.0f; expectedtrans.z = 106.0f; expectedtrans.w = 124.0f; - D3DXVec3Transform(&gottrans,&u,&mat); - expect_vec4(expectedtrans,gottrans); - -/*_______________D3DXVec3TransformCoord_______________________*/ - expectedvec.x = 70.0f/124.0f; expectedvec.y = 88.0f/124.0f; expectedvec.z = 106.0f/124.0f; - D3DXVec3TransformCoord(&gotvec,&u,&mat); - expect_vec3(expectedvec,gotvec); - -/*_______________D3DXVec3TransformNormal______________________*/ - expectedvec.x = 57.0f; expectedvec.y = 74.0f; expectedvec.z = 91.0f; - D3DXVec3TransformNormal(&gotvec,&u,&mat); - expect_vec3(expectedvec,gotvec); - -/*_______________D3DXVec3Unproject_________________________*/ - expectedvec.x = -2.913411f; expectedvec.y = 1.593215f; expectedvec.z = 0.380724f; - D3DXMatrixPerspectiveFovLH(&projection,D3DX_PI/4.0f,20.0f/17.0f,1.0f,1000.0f); - D3DXVec3Unproject(&gotvec,&u,&viewport,&projection,&view,&world); - expect_vec3(expectedvec,gotvec); -} - -static void D3DXVector4Test(void) -{ - D3DXVECTOR4 expectedvec, gotvec, nul, u, v, w, x; - LPD3DXVECTOR4 funcpointer; - D3DXVECTOR4 expectedtrans, gottrans; - D3DXMATRIX mat; - FLOAT coeff1, coeff2, expected, got, scale; - - nul.x = 0.0f; nul.y = 0.0f; nul.z = 0.0f; nul.w = 0.0f; - u.x = 1.0f; u.y = 2.0f; u.z = 4.0f; u.w = 10.0; - v.x = -3.0f; v.y = 4.0f; v.z = -5.0f; v.w = 7.0; - w.x = 4.0f; w.y =6.0f; w.z = -2.0f; w.w = 1.0f; - x.x = 6.0f; x.y = -7.0f; x.z =8.0f; x.w = -9.0f; - - U(mat).m[0][0] = 1.0f; U(mat).m[0][1] = 2.0f; U(mat).m[0][2] = 3.0f; U(mat).m[0][3] = 4.0f; - U(mat).m[1][0] = 5.0f; U(mat).m[1][1] = 6.0f; U(mat).m[1][2] = 7.0f; U(mat).m[1][3] = 8.0f; - U(mat).m[2][0] = 9.0f; U(mat).m[2][1] = 10.0f; U(mat).m[2][2] = 11.0f; U(mat).m[2][3] = 12.0f; - U(mat).m[3][0] = 13.0f; U(mat).m[3][1] = 14.0f; U(mat).m[3][2] = 15.0f; U(mat).m[3][3] = 16.0f; - - coeff1 = 2.0f; coeff2 = 5.0; - scale = -6.5f; - -/*_______________D3DXVec4Add__________________________*/ - expectedvec.x = -2.0f; expectedvec.y = 6.0f; expectedvec.z = -1.0f; expectedvec.w = 17.0f; - D3DXVec4Add(&gotvec,&u,&v); - expect_vec4(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec4Add(&gotvec,NULL,&v); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec4Add(NULL,NULL,NULL); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec4BaryCentric____________________*/ - expectedvec.x = 8.0f; expectedvec.y = 26.0; expectedvec.z = -44.0f; expectedvec.w = -41.0f; - D3DXVec4BaryCentric(&gotvec,&u,&v,&w,coeff1,coeff2); - expect_vec4(expectedvec,gotvec); - -/*_______________D3DXVec4CatmullRom____________________*/ - expectedvec.x = 2754.625f; expectedvec.y = 2367.5625f; expectedvec.z = 1060.1875f; expectedvec.w = 131.3125f; - D3DXVec4CatmullRom(&gotvec,&u,&v,&w,&x,scale); - expect_vec4(expectedvec,gotvec); - -/*_______________D3DXVec4Cross_________________________*/ - expectedvec.x = 390.0f; expectedvec.y = -393.0f; expectedvec.z = -316.0f; expectedvec.w = 166.0f; - D3DXVec4Cross(&gotvec,&u,&v,&w); - expect_vec4(expectedvec,gotvec); - -/*_______________D3DXVec4Dot__________________________*/ - expected = 55.0f; - got = D3DXVec4Dot(&u,&v); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - /* Tests the case NULL */ - expected=0.0f; - got = D3DXVec4Dot(NULL,&v); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - expected=0.0f; - got = D3DXVec4Dot(NULL,NULL); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - -/*_______________D3DXVec4Hermite_________________________*/ - expectedvec.x = 1224.625f; expectedvec.y = 3461.625f; expectedvec.z = -4758.875f; expectedvec.w = -5781.5f; - D3DXVec4Hermite(&gotvec,&u,&v,&w,&x,scale); - expect_vec4(expectedvec,gotvec); - -/*_______________D3DXVec4Length__________________________*/ - expected = 11.0f; - got = D3DXVec4Length(&u); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - /* Tests the case NULL */ - expected=0.0f; - got = D3DXVec4Length(NULL); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - -/*_______________D3DXVec4LengthSq________________________*/ - expected = 121.0f; - got = D3DXVec4LengthSq(&u); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - /* Tests the case NULL */ - expected=0.0f; - got = D3DXVec4LengthSq(NULL); - ok(fabs( got - expected ) < admitted_error, "Expected: %f, Got: %f\n", expected, got); - -/*_______________D3DXVec4Lerp__________________________*/ - expectedvec.x = 27.0f; expectedvec.y = -11.0f; expectedvec.z = 62.5; expectedvec.w = 29.5; - D3DXVec4Lerp(&gotvec,&u,&v,scale); - expect_vec4(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec4Lerp(&gotvec,NULL,&v,scale); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec4Lerp(NULL,NULL,NULL,scale); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec4Maximize__________________________*/ - expectedvec.x = 1.0f; expectedvec.y = 4.0f; expectedvec.z = 4.0f; expectedvec.w = 10.0; - D3DXVec4Maximize(&gotvec,&u,&v); - expect_vec4(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec4Maximize(&gotvec,NULL,&v); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec4Maximize(NULL,NULL,NULL); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec4Minimize__________________________*/ - expectedvec.x = -3.0f; expectedvec.y = 2.0f; expectedvec.z = -5.0f; expectedvec.w = 7.0; - D3DXVec4Minimize(&gotvec,&u,&v); - expect_vec4(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec4Minimize(&gotvec,NULL,&v); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec4Minimize(NULL,NULL,NULL); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec4Normalize_________________________*/ - expectedvec.x = 1.0f/11.0f; expectedvec.y = 2.0f/11.0f; expectedvec.z = 4.0f/11.0f; expectedvec.w = 10.0f/11.0f; - D3DXVec4Normalize(&gotvec,&u); - expect_vec4(expectedvec,gotvec); - -/*_______________D3DXVec4Scale____________________________*/ - expectedvec.x = -6.5f; expectedvec.y = -13.0f; expectedvec.z = -26.0f; expectedvec.w = -65.0f; - D3DXVec4Scale(&gotvec,&u,scale); - expect_vec4(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec4Scale(&gotvec,NULL,scale); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec4Scale(NULL,NULL,scale); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec4Subtract__________________________*/ - expectedvec.x = 4.0f; expectedvec.y = -2.0f; expectedvec.z = 9.0f; expectedvec.w = 3.0f; - D3DXVec4Subtract(&gotvec,&u,&v); - expect_vec4(expectedvec,gotvec); - /* Tests the case NULL */ - funcpointer = D3DXVec4Subtract(&gotvec,NULL,&v); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - funcpointer = D3DXVec4Subtract(NULL,NULL,NULL); - ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer); - -/*_______________D3DXVec4Transform_______________________*/ - expectedtrans.x = 177.0f; expectedtrans.y = 194.0f; expectedtrans.z = 211.0f; expectedtrans.w = 228.0f; - D3DXVec4Transform(&gottrans,&u,&mat); - expect_vec4(expectedtrans,gottrans); -} - -static void test_matrix_stack(void) -{ - ID3DXMatrixStack *stack; - ULONG refcount; - HRESULT hr; - - const D3DXMATRIX mat1 = {{{ - 1.0f, 2.0f, 3.0f, 4.0f, - 5.0f, 6.0f, 7.0f, 8.0f, - 9.0f, 10.0f, 11.0f, 12.0f, - 13.0f, 14.0f, 15.0f, 16.0f - }}}; - - const D3DXMATRIX mat2 = {{{ - 17.0f, 18.0f, 19.0f, 20.0f, - 21.0f, 22.0f, 23.0f, 24.0f, - 25.0f, 26.0f, 27.0f, 28.0f, - 29.0f, 30.0f, 31.0f, 32.0f - }}}; - - hr = D3DXCreateMatrixStack(0, &stack); - ok(SUCCEEDED(hr), "Failed to create a matrix stack, hr %#x\n", hr); - if (FAILED(hr)) return; - - ok(D3DXMatrixIsIdentity(ID3DXMatrixStack_GetTop(stack)), - "The top of an empty matrix stack should be an identity matrix\n"); - - hr = ID3DXMatrixStack_Pop(stack); - ok(SUCCEEDED(hr), "Pop failed, hr %#x\n", hr); - - hr = ID3DXMatrixStack_Push(stack); - ok(SUCCEEDED(hr), "Push failed, hr %#x\n", hr); - ok(D3DXMatrixIsIdentity(ID3DXMatrixStack_GetTop(stack)), "The top should be an identity matrix\n"); - - hr = ID3DXMatrixStack_Push(stack); - ok(SUCCEEDED(hr), "Push failed, hr %#x\n", hr); - - hr = ID3DXMatrixStack_LoadMatrix(stack, &mat1); - ok(SUCCEEDED(hr), "LoadMatrix failed, hr %#x\n", hr); - expect_mat(&mat1, ID3DXMatrixStack_GetTop(stack)); - - hr = ID3DXMatrixStack_Push(stack); - ok(SUCCEEDED(hr), "Push failed, hr %#x\n", hr); - expect_mat(&mat1, ID3DXMatrixStack_GetTop(stack)); - - hr = ID3DXMatrixStack_LoadMatrix(stack, &mat2); - ok(SUCCEEDED(hr), "LoadMatrix failed, hr %#x\n", hr); - expect_mat(&mat2, ID3DXMatrixStack_GetTop(stack)); - - hr = ID3DXMatrixStack_Push(stack); - ok(SUCCEEDED(hr), "Push failed, hr %#x\n", hr); - expect_mat(&mat2, ID3DXMatrixStack_GetTop(stack)); - - hr = ID3DXMatrixStack_LoadIdentity(stack); - ok(SUCCEEDED(hr), "LoadIdentity failed, hr %#x\n", hr); - ok(D3DXMatrixIsIdentity(ID3DXMatrixStack_GetTop(stack)), "The top should be an identity matrix\n"); - - hr = ID3DXMatrixStack_Pop(stack); - ok(SUCCEEDED(hr), "Pop failed, hr %#x\n", hr); - expect_mat(&mat2, ID3DXMatrixStack_GetTop(stack)); - - hr = ID3DXMatrixStack_Pop(stack); - ok(SUCCEEDED(hr), "Pop failed, hr %#x\n", hr); - expect_mat(&mat1, ID3DXMatrixStack_GetTop(stack)); - - hr = ID3DXMatrixStack_Pop(stack); - ok(SUCCEEDED(hr), "Pop failed, hr %#x\n", hr); - ok(D3DXMatrixIsIdentity(ID3DXMatrixStack_GetTop(stack)), "The top should be an identity matrix\n"); - - hr = ID3DXMatrixStack_Pop(stack); - ok(SUCCEEDED(hr), "Pop failed, hr %#x\n", hr); - ok(D3DXMatrixIsIdentity(ID3DXMatrixStack_GetTop(stack)), "The top should be an identity matrix\n"); - - refcount = ID3DXMatrixStack_Release(stack); - ok(!refcount, "Matrix stack has %u references left.\n", refcount); -} - -static void test_Matrix_AffineTransformation2D(void) -{ - D3DXMATRIX exp_mat, got_mat; - D3DXVECTOR2 center, position; - FLOAT angle, scale; - - center.x = 3.0f; - center.y = 4.0f; - - position.x = -6.0f; - position.y = 7.0f; - - angle = D3DX_PI/3.0f; - - scale = 20.0f; - - U(exp_mat).m[0][0] = 10.0f; - U(exp_mat).m[1][0] = -17.320507f; - U(exp_mat).m[2][0] = 0.0f; - U(exp_mat).m[3][0] = -1.035898f; - U(exp_mat).m[0][1] = 17.320507f; - U(exp_mat).m[1][1] = 10.0f; - U(exp_mat).m[2][1] = 0.0f; - U(exp_mat).m[3][1] = 6.401924f; - U(exp_mat).m[0][2] = 0.0f; - U(exp_mat).m[1][2] = 0.0f; - U(exp_mat).m[2][2] = 1.0f; - U(exp_mat).m[3][2] = 0.0f; - U(exp_mat).m[0][3] = 0.0f; - U(exp_mat).m[1][3] = 0.0f; - U(exp_mat).m[2][3] = 0.0f; - U(exp_mat).m[3][3] = 1.0f; - - D3DXMatrixAffineTransformation2D(&got_mat, scale, ¢er, angle, &position); - - expect_mat(&exp_mat, &got_mat); - -/*______________*/ - - center.x = 3.0f; - center.y = 4.0f; - - angle = D3DX_PI/3.0f; - - scale = 20.0f; - - U(exp_mat).m[0][0] = 10.0f; - U(exp_mat).m[1][0] = -17.320507f; - U(exp_mat).m[2][0] = 0.0f; - U(exp_mat).m[3][0] = 4.964102f; - U(exp_mat).m[0][1] = 17.320507f; - U(exp_mat).m[1][1] = 10.0f; - U(exp_mat).m[2][1] = 0.0f; - U(exp_mat).m[3][1] = -0.598076f; - U(exp_mat).m[0][2] = 0.0f; - U(exp_mat).m[1][2] = 0.0f; - U(exp_mat).m[2][2] = 1.0f; - U(exp_mat).m[3][2] = 0.0f; - U(exp_mat).m[0][3] = 0.0f; - U(exp_mat).m[1][3] = 0.0f; - U(exp_mat).m[2][3] = 0.0f; - U(exp_mat).m[3][3] = 1.0f; - - D3DXMatrixAffineTransformation2D(&got_mat, scale, ¢er, angle, NULL); - - expect_mat(&exp_mat, &got_mat); - -/*______________*/ - - position.x = -6.0f; - position.y = 7.0f; - - angle = D3DX_PI/3.0f; - - scale = 20.0f; - - U(exp_mat).m[0][0] = 10.0f; - U(exp_mat).m[1][0] = -17.320507f; - U(exp_mat).m[2][0] = 0.0f; - U(exp_mat).m[3][0] = -6.0f; - U(exp_mat).m[0][1] = 17.320507f; - U(exp_mat).m[1][1] = 10.0f; - U(exp_mat).m[2][1] = 0.0f; - U(exp_mat).m[3][1] = 7.0f; - U(exp_mat).m[0][2] = 0.0f; - U(exp_mat).m[1][2] = 0.0f; - U(exp_mat).m[2][2] = 1.0f; - U(exp_mat).m[3][2] = 0.0f; - U(exp_mat).m[0][3] = 0.0f; - U(exp_mat).m[1][3] = 0.0f; - U(exp_mat).m[2][3] = 0.0f; - U(exp_mat).m[3][3] = 1.0f; - - D3DXMatrixAffineTransformation2D(&got_mat, scale, NULL, angle, &position); - - expect_mat(&exp_mat, &got_mat); - -/*______________*/ - - angle = 5.0f * D3DX_PI/4.0f; - - scale = -20.0f; - - U(exp_mat).m[0][0] = 14.142133f; - U(exp_mat).m[1][0] = -14.142133f; - U(exp_mat).m[2][0] = 0.0f; - U(exp_mat).m[3][0] = 0.0f; - U(exp_mat).m[0][1] = 14.142133; - U(exp_mat).m[1][1] = 14.142133f; - U(exp_mat).m[2][1] = 0.0f; - U(exp_mat).m[3][1] = 0.0f; - U(exp_mat).m[0][2] = 0.0f; - U(exp_mat).m[1][2] = 0.0f; - U(exp_mat).m[2][2] = 1.0f; - U(exp_mat).m[3][2] = 0.0f; - U(exp_mat).m[0][3] = 0.0f; - U(exp_mat).m[1][3] = 0.0f; - U(exp_mat).m[2][3] = 0.0f; - U(exp_mat).m[3][3] = 1.0f; - - D3DXMatrixAffineTransformation2D(&got_mat, scale, NULL, angle, NULL); - - expect_mat(&exp_mat, &got_mat); -} - -static void test_Matrix_Decompose(void) -{ - D3DXMATRIX pm; - D3DXQUATERNION exp_rotation, got_rotation; - D3DXVECTOR3 exp_scale, got_scale, exp_translation, got_translation; - HRESULT hr; - -/*___________*/ - - U(pm).m[0][0] = -0.9238790f; - U(pm).m[1][0] = -0.2705984f; - U(pm).m[2][0] = 0.2705984f; - U(pm).m[3][0] = -5.0f; - U(pm).m[0][1] = 0.2705984f; - U(pm).m[1][1] = 0.03806049f; - U(pm).m[2][1] = 0.9619395f; - U(pm).m[3][1] = 0.0f; - U(pm).m[0][2] = -0.2705984f; - U(pm).m[1][2] = 0.9619395f; - U(pm).m[2][2] = 0.03806049f; - U(pm).m[3][2] = 10.0f; - U(pm).m[0][3] = 0.0f; - U(pm).m[1][3] = 0.0f; - U(pm).m[2][3] = 0.0f; - U(pm).m[3][3] = 1.0f; - - exp_scale.x = 1.0f; - exp_scale.y = 1.0f; - exp_scale.z = 1.0f; - - exp_rotation.w = 0.195091f; - exp_rotation.x = 0.0f; - exp_rotation.y = 0.693520f; - exp_rotation.z = 0.693520f; - - exp_translation.x = -5.0f; - exp_translation.y = 0.0f; - exp_translation.z = 10.0f; - - D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); - - compare_scale(exp_scale, got_scale); - compare_rotation(exp_rotation, got_rotation); - compare_translation(exp_translation, got_translation); - -/*_________*/ - - U(pm).m[0][0] = -2.255813f; - U(pm).m[1][0] = 1.302324f; - U(pm).m[2][0] = 1.488373f; - U(pm).m[3][0] = 1.0f; - U(pm).m[0][1] = 1.302327f; - U(pm).m[1][1] = -0.7209296f; - U(pm).m[2][1] = 2.60465f; - U(pm).m[3][1] = 2.0f; - U(pm).m[0][2] = 1.488371f; - U(pm).m[1][2] = 2.604651f; - U(pm).m[2][2] = -0.02325551f; - U(pm).m[3][2] = 3.0f; - U(pm).m[0][3] = 0.0f; - U(pm).m[1][3] = 0.0f; - U(pm).m[2][3] = 0.0f; - U(pm).m[3][3] = 1.0f; - - exp_scale.x = 3.0f; - exp_scale.y = 3.0f; - exp_scale.z = 3.0f; - - exp_rotation.w = 0.0; - exp_rotation.x = 0.352180f; - exp_rotation.y = 0.616316f; - exp_rotation.z = 0.704361f; - - exp_translation.x = 1.0f; - exp_translation.y = 2.0f; - exp_translation.z = 3.0f; - - D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); - - compare_scale(exp_scale, got_scale); - compare_rotation(exp_rotation, got_rotation); - compare_translation(exp_translation, got_translation); - -/*_____________*/ - - U(pm).m[0][0] = 2.427051f; - U(pm).m[1][0] = 0.0f; - U(pm).m[2][0] = 1.763355f; - U(pm).m[3][0] = 5.0f; - U(pm).m[0][1] = 0.0f; - U(pm).m[1][1] = 3.0f; - U(pm).m[2][1] = 0.0f; - U(pm).m[3][1] = 5.0f; - U(pm).m[0][2] = -1.763355f; - U(pm).m[1][2] = 0.0f; - U(pm).m[2][2] = 2.427051f; - U(pm).m[3][2] = 5.0f; - U(pm).m[0][3] = 0.0f; - U(pm).m[1][3] = 0.0f; - U(pm).m[2][3] = 0.0f; - U(pm).m[3][3] = 1.0f; - - exp_scale.x = 3.0f; - exp_scale.y = 3.0f; - exp_scale.z = 3.0f; - - exp_rotation.w = 0.951057f; - exp_rotation.x = 0.0f; - exp_rotation.y = 0.309017f; - exp_rotation.z = 0.0f; - - exp_translation.x = 5.0f; - exp_translation.y = 5.0f; - exp_translation.z = 5.0f; - - D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); - - compare_scale(exp_scale, got_scale); - compare_rotation(exp_rotation, got_rotation); - compare_translation(exp_translation, got_translation); - -/*_____________*/ - - U(pm).m[0][0] = -0.9238790f; - U(pm).m[1][0] = -0.2705984f; - U(pm).m[2][0] = 0.2705984f; - U(pm).m[3][0] = -5.0f; - U(pm).m[0][1] = 0.2705984f; - U(pm).m[1][1] = 0.03806049f; - U(pm).m[2][1] = 0.9619395f; - U(pm).m[3][1] = 0.0f; - U(pm).m[0][2] = -0.2705984f; - U(pm).m[1][2] = 0.9619395f; - U(pm).m[2][2] = 0.03806049f; - U(pm).m[3][2] = 10.0f; - U(pm).m[0][3] = 0.0f; - U(pm).m[1][3] = 0.0f; - U(pm).m[2][3] = 0.0f; - U(pm).m[3][3] = 1.0f; - - exp_scale.x = 1.0f; - exp_scale.y = 1.0f; - exp_scale.z = 1.0f; - - exp_rotation.w = 0.195091f; - exp_rotation.x = 0.0f; - exp_rotation.y = 0.693520f; - exp_rotation.z = 0.693520f; - - exp_translation.x = -5.0f; - exp_translation.y = 0.0f; - exp_translation.z = 10.0f; - - D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); - - compare_scale(exp_scale, got_scale); - compare_rotation(exp_rotation, got_rotation); - compare_translation(exp_translation, got_translation); - -/*__________*/ - - U(pm).m[0][0] = -0.9238790f; - U(pm).m[1][0] = -0.5411968f; - U(pm).m[2][0] = 0.8117952f; - U(pm).m[3][0] = -5.0f; - U(pm).m[0][1] = 0.2705984f; - U(pm).m[1][1] = 0.07612098f; - U(pm).m[2][1] = 2.8858185f; - U(pm).m[3][1] = 0.0f; - U(pm).m[0][2] = -0.2705984f; - U(pm).m[1][2] = 1.9238790f; - U(pm).m[2][2] = 0.11418147f; - U(pm).m[3][2] = 10.0f; - U(pm).m[0][3] = 0.0f; - U(pm).m[1][3] = 0.0f; - U(pm).m[2][3] = 0.0f; - U(pm).m[3][3] = 1.0f; - - exp_scale.x = 1.0f; - exp_scale.y = 2.0f; - exp_scale.z = 3.0f; - - exp_rotation.w = 0.195091f; - exp_rotation.x = 0.0f; - exp_rotation.y = 0.693520f; - exp_rotation.z = 0.693520f; - - exp_translation.x = -5.0f; - exp_translation.y = 0.0f; - exp_translation.z = 10.0f; - - D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); - - compare_scale(exp_scale, got_scale); - compare_rotation(exp_rotation, got_rotation); - compare_translation(exp_translation, got_translation); - -/*__________*/ - - U(pm).m[0][0] = 0.7156004f; - U(pm).m[1][0] = -0.5098283f; - U(pm).m[2][0] = -0.4774843f; - U(pm).m[3][0] = -5.0f; - U(pm).m[0][1] = -0.6612288f; - U(pm).m[1][1] = -0.7147621f; - U(pm).m[2][1] = -0.2277977f; - U(pm).m[3][1] = 0.0f; - U(pm).m[0][2] = -0.2251499f; - U(pm).m[1][2] = 0.4787385f; - U(pm).m[2][2] = -0.8485972f; - U(pm).m[3][2] = 10.0f; - U(pm).m[0][3] = 0.0f; - U(pm).m[1][3] = 0.0f; - U(pm).m[2][3] = 0.0f; - U(pm).m[3][3] = 1.0f; - - exp_scale.x = 1.0f; - exp_scale.y = 1.0f; - exp_scale.z = 1.0f; - - exp_rotation.w = 0.195091f; - exp_rotation.x = 0.905395f; - exp_rotation.y = -0.323355f; - exp_rotation.z = -0.194013f; - - exp_translation.x = -5.0f; - exp_translation.y = 0.0f; - exp_translation.z = 10.0f; - - D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); - - compare_scale(exp_scale, got_scale); - compare_rotation(exp_rotation, got_rotation); - compare_translation(exp_translation, got_translation); - -/*_____________*/ - - U(pm).m[0][0] = 0.06554436f; - U(pm).m[1][0] = -0.6873012f; - U(pm).m[2][0] = 0.7234092f; - U(pm).m[3][0] = -5.0f; - U(pm).m[0][1] = -0.9617381f; - U(pm).m[1][1] = -0.2367795f; - U(pm).m[2][1] = -0.1378230f; - U(pm).m[3][1] = 0.0f; - U(pm).m[0][2] = 0.2660144f; - U(pm).m[1][2] = -0.6866967f; - U(pm).m[2][2] = -0.6765233f; - U(pm).m[3][2] = 10.0f; - U(pm).m[0][3] = 0.0f; - U(pm).m[1][3] = 0.0f; - U(pm).m[2][3] = 0.0f; - U(pm).m[3][3] = 1.0f; - - exp_scale.x = 1.0f; - exp_scale.y = 1.0f; - exp_scale.z = 1.0f; - - exp_rotation.w = -0.195091f; - exp_rotation.x = 0.703358f; - exp_rotation.y = -0.586131f; - exp_rotation.z = 0.351679f; - - exp_translation.x = -5.0f; - exp_translation.y = 0.0f; - exp_translation.z = 10.0f; - - D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); - - compare_scale(exp_scale, got_scale); - compare_rotation(exp_rotation, got_rotation); - compare_translation(exp_translation, got_translation); - -/*_________*/ - - U(pm).m[0][0] = 7.121047f; - U(pm).m[1][0] = -5.883487f; - U(pm).m[2][0] = 11.81843f; - U(pm).m[3][0] = -5.0f; - U(pm).m[0][1] = 5.883487f; - U(pm).m[1][1] = -10.60660f; - U(pm).m[2][1] = -8.825232f; - U(pm).m[3][1] = 0.0f; - U(pm).m[0][2] = 11.81843f; - U(pm).m[1][2] = 8.8252320f; - U(pm).m[2][2] = -2.727645f; - U(pm).m[3][2] = 2.0f; - U(pm).m[0][3] = 0.0f; - U(pm).m[1][3] = 0.0f; - U(pm).m[2][3] = 0.0f; - U(pm).m[3][3] = 1.0f; - - exp_scale.x = 15.0f; - exp_scale.y = 15.0f; - exp_scale.z = 15.0f; - - exp_rotation.w = 0.382684f; - exp_rotation.x = 0.768714f; - exp_rotation.y = 0.0f; - exp_rotation.z = 0.512476f; - - exp_translation.x = -5.0f; - exp_translation.y = 0.0f; - exp_translation.z = 2.0f; - - D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); - - compare_scale(exp_scale, got_scale); - compare_rotation(exp_rotation, got_rotation); - compare_translation(exp_translation, got_translation); - -/*__________*/ - - U(pm).m[0][0] = 0.0f; - U(pm).m[1][0] = 4.0f; - U(pm).m[2][0] = 5.0f; - U(pm).m[3][0] = -5.0f; - U(pm).m[0][1] = 0.0f; - U(pm).m[1][1] = -10.60660f; - U(pm).m[2][1] = -8.825232f; - U(pm).m[3][1] = 6.0f; - U(pm).m[0][2] = 0.0f; - U(pm).m[1][2] = 8.8252320f; - U(pm).m[2][2] = 2.727645; - U(pm).m[3][2] = 3.0f; - U(pm).m[0][3] = 0.0f; - U(pm).m[1][3] = 0.0f; - U(pm).m[2][3] = 0.0f; - U(pm).m[3][3] = 1.0f; - - hr = D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); - ok(hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %x\n", hr); -} - -static void test_Matrix_Transformation2D(void) -{ - D3DXMATRIX exp_mat, got_mat; - D3DXVECTOR2 rot_center, sca, sca_center, trans; - FLOAT rot, sca_rot; - - rot_center.x = 3.0f; - rot_center.y = 4.0f; - - sca.x = 12.0f; - sca.y = -3.0f; - - sca_center.x = 9.0f; - sca_center.y = -5.0f; - - trans.x = -6.0f; - trans.y = 7.0f; - - rot = D3DX_PI/3.0f; - - sca_rot = 5.0f*D3DX_PI/4.0f; - - U(exp_mat).m[0][0] = -4.245192f; - U(exp_mat).m[1][0] = -0.147116f; - U(exp_mat).m[2][0] = 0.0f; - U(exp_mat).m[3][0] = 45.265373f; - U(exp_mat).m[0][1] = 7.647113f; - U(exp_mat).m[1][1] = 8.745192f; - U(exp_mat).m[2][1] = 0.0f; - U(exp_mat).m[3][1] = -13.401899f; - U(exp_mat).m[0][2] = 0.0f; - U(exp_mat).m[1][2] = 0.0f; - U(exp_mat).m[2][2] = 1.0f; - U(exp_mat).m[3][2] = 0.0f; - U(exp_mat).m[0][3] = 0.0f; - U(exp_mat).m[1][3] = 0.0f; - U(exp_mat).m[2][3] = 0.0f; - U(exp_mat).m[3][3] = 1.0f; - - D3DXMatrixTransformation2D(&got_mat, &sca_center, sca_rot, &sca, &rot_center, rot, &trans); - - expect_mat(&exp_mat, &got_mat); - -/*_________*/ - - sca_center.x = 9.0f; - sca_center.y = -5.0f; - - trans.x = -6.0f; - trans.y = 7.0f; - - rot = D3DX_PI/3.0f; - - sca_rot = 5.0f*D3DX_PI/4.0f; - - U(exp_mat).m[0][0] = 0.50f; - U(exp_mat).m[1][0] = -0.866025f; - U(exp_mat).m[2][0] = 0.0f; - U(exp_mat).m[3][0] = -6.0f; - U(exp_mat).m[0][1] = 0.866025f; - U(exp_mat).m[1][1] = 0.50f; - U(exp_mat).m[2][1] = 0.0f; - U(exp_mat).m[3][1] = 7.0f; - U(exp_mat).m[0][2] = 0.0f; - U(exp_mat).m[1][2] = 0.0f; - U(exp_mat).m[2][2] = 1.0f; - U(exp_mat).m[3][2] = 0.0f; - U(exp_mat).m[0][3] = 0.0f; - U(exp_mat).m[1][3] = 0.0f; - U(exp_mat).m[2][3] = 0.0f; - U(exp_mat).m[3][3] = 1.0f; - - D3DXMatrixTransformation2D(&got_mat, &sca_center, sca_rot, NULL, NULL, rot, &trans); - - expect_mat(&exp_mat, &got_mat); - -/*_________*/ - - U(exp_mat).m[0][0] = 0.50f; - U(exp_mat).m[1][0] = -0.866025f; - U(exp_mat).m[2][0] = 0.0f; - U(exp_mat).m[3][0] = 0.0f; - U(exp_mat).m[0][1] = 0.866025f; - U(exp_mat).m[1][1] = 0.50f; - U(exp_mat).m[2][1] = 0.0f; - U(exp_mat).m[3][1] = 0.0f; - U(exp_mat).m[0][2] = 0.0f; - U(exp_mat).m[1][2] = 0.0f; - U(exp_mat).m[2][2] = 1.0f; - U(exp_mat).m[3][2] = 0.0f; - U(exp_mat).m[0][3] = 0.0f; - U(exp_mat).m[1][3] = 0.0f; - U(exp_mat).m[2][3] = 0.0f; - U(exp_mat).m[3][3] = 1.0f; - - D3DXMatrixTransformation2D(&got_mat, NULL, sca_rot, NULL, NULL, rot, NULL); - - expect_mat(&exp_mat, &got_mat); -} - -static void test_D3DXVec_Array(void) -{ - unsigned int i; - D3DVIEWPORT9 viewport; - D3DXMATRIX mat, projection, view, world; - D3DXVECTOR4 inp_vec[ARRAY_SIZE]; - D3DXVECTOR4 out_vec[ARRAY_SIZE + 2]; - D3DXVECTOR4 exp_vec[ARRAY_SIZE + 2]; - D3DXPLANE inp_plane[ARRAY_SIZE]; - D3DXPLANE out_plane[ARRAY_SIZE + 2]; - D3DXPLANE exp_plane[ARRAY_SIZE + 2]; - - viewport.Width = 800; viewport.MinZ = 0.2f; viewport.X = 10; - viewport.Height = 680; viewport.MaxZ = 0.9f; viewport.Y = 5; - - for (i = 0; i < ARRAY_SIZE + 2; ++i) { - out_vec[i].x = out_vec[i].y = out_vec[i].z = out_vec[i].w = 0.0f; - exp_vec[i].x = exp_vec[i].y = exp_vec[i].z = exp_vec[i].w = 0.0f; - out_plane[i].a = out_plane[i].b = out_plane[i].c = out_plane[i].d = 0.0f; - exp_plane[i].a = exp_plane[i].b = exp_plane[i].c = exp_plane[i].d = 0.0f; - } - - for (i = 0; i < ARRAY_SIZE; ++i) { - inp_plane[i].a = inp_plane[i].c = inp_vec[i].x = inp_vec[i].z = i; - inp_plane[i].b = inp_plane[i].d = inp_vec[i].y = inp_vec[i].w = ARRAY_SIZE - i; - } - - U(mat).m[0][0] = 1.0f; U(mat).m[0][1] = 2.0f; U(mat).m[0][2] = 3.0f; U(mat).m[0][3] = 4.0f; - U(mat).m[1][0] = 5.0f; U(mat).m[1][1] = 6.0f; U(mat).m[1][2] = 7.0f; U(mat).m[1][3] = 8.0f; - U(mat).m[2][0] = 9.0f; U(mat).m[2][1] = 10.0f; U(mat).m[2][2] = 11.0f; U(mat).m[2][3] = 12.0f; - U(mat).m[3][0] = 13.0f; U(mat).m[3][1] = 14.0f; U(mat).m[3][2] = 15.0f; U(mat).m[3][3] = 16.0f; - - D3DXMatrixPerspectiveFovLH(&projection,D3DX_PI/4.0f,20.0f/17.0f,1.0f,1000.0f); - - U(view).m[0][1] = 5.0f; U(view).m[0][2] = 7.0f; U(view).m[0][3] = 8.0f; - U(view).m[1][0] = 11.0f; U(view).m[1][2] = 16.0f; U(view).m[1][3] = 33.0f; - U(view).m[2][0] = 19.0f; U(view).m[2][1] = -21.0f; U(view).m[2][3] = 43.0f; - U(view).m[3][0] = 2.0f; U(view).m[3][1] = 3.0f; U(view).m[3][2] = -4.0f; - U(view).m[0][0] = 10.0f; U(view).m[1][1] = 20.0f; U(view).m[2][2] = 30.0f; - U(view).m[3][3] = -40.0f; - - U(world).m[0][0] = 21.0f; U(world).m[0][1] = 2.0f; U(world).m[0][2] = 3.0f; U(world).m[0][3] = 4.0; - U(world).m[1][0] = 5.0f; U(world).m[1][1] = 23.0f; U(world).m[1][2] = 7.0f; U(world).m[1][3] = 8.0f; - U(world).m[2][0] = -8.0f; U(world).m[2][1] = -7.0f; U(world).m[2][2] = 25.0f; U(world).m[2][3] = -5.0f; - U(world).m[3][0] = -4.0f; U(world).m[3][1] = -3.0f; U(world).m[3][2] = -2.0f; U(world).m[3][3] = 27.0f; - - /* D3DXVec2TransformCoordArray */ - exp_vec[1].x = 0.678571f; exp_vec[1].y = 0.785714f; - exp_vec[2].x = 0.653846f; exp_vec[2].y = 0.769231f; - exp_vec[3].x = 0.625f; exp_vec[3].y = 0.75f; - exp_vec[4].x = 0.590909f; exp_vec[4].y = 8.0f/11.0f; - exp_vec[5].x = 0.55f; exp_vec[5].y = 0.7f; - D3DXVec2TransformCoordArray((D3DXVECTOR2*)(out_vec + 1), sizeof(D3DXVECTOR4), (D3DXVECTOR2*)inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); - compare_vectors(exp_vec, out_vec); - - /* D3DXVec2TransformNormalArray */ - exp_vec[1].x = 25.0f; exp_vec[1].y = 30.0f; - exp_vec[2].x = 21.0f; exp_vec[2].y = 26.0f; - exp_vec[3].x = 17.0f; exp_vec[3].y = 22.0f; - exp_vec[4].x = 13.0f; exp_vec[4].y = 18.0f; - exp_vec[5].x = 9.0f; exp_vec[5].y = 14.0f; - D3DXVec2TransformNormalArray((D3DXVECTOR2*)(out_vec + 1), sizeof(D3DXVECTOR4), (D3DXVECTOR2*)inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); - compare_vectors(exp_vec, out_vec); - - /* D3DXVec3TransformCoordArray */ - exp_vec[1].x = 0.678571f; exp_vec[1].y = 0.785714f; exp_vec[1].z = 0.892857f; - exp_vec[2].x = 0.671875f; exp_vec[2].y = 0.78125f; exp_vec[2].z = 0.890625f; - exp_vec[3].x = 6.0f/9.0f; exp_vec[3].y = 7.0f/9.0f; exp_vec[3].z = 8.0f/9.0f; - exp_vec[4].x = 0.6625f; exp_vec[4].y = 0.775f; exp_vec[4].z = 0.8875f; - exp_vec[5].x = 0.659091f; exp_vec[5].y = 0.772727f; exp_vec[5].z = 0.886364f; - D3DXVec3TransformCoordArray((D3DXVECTOR3*)(out_vec + 1), sizeof(D3DXVECTOR4), (D3DXVECTOR3*)inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); - compare_vectors(exp_vec, out_vec); - - /* D3DXVec3TransformNormalArray */ - exp_vec[1].x = 25.0f; exp_vec[1].y = 30.0f; exp_vec[1].z = 35.0f; - exp_vec[2].x = 30.0f; exp_vec[2].y = 36.0f; exp_vec[2].z = 42.0f; - exp_vec[3].x = 35.0f; exp_vec[3].y = 42.0f; exp_vec[3].z = 49.0f; - exp_vec[4].x = 40.0f; exp_vec[4].y = 48.0f; exp_vec[4].z = 56.0f; - exp_vec[5].x = 45.0f; exp_vec[5].y = 54.0f; exp_vec[5].z = 63.0f; - D3DXVec3TransformNormalArray((D3DXVECTOR3*)(out_vec + 1), sizeof(D3DXVECTOR4), (D3DXVECTOR3*)inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); - compare_vectors(exp_vec, out_vec); - - /* D3DXVec3ProjectArray */ - exp_vec[1].x = 1089.554199f; exp_vec[1].y = -226.590622f; exp_vec[1].z = 0.215273f; - exp_vec[2].x = 1068.903320f; exp_vec[2].y = 103.085129f; exp_vec[2].z = 0.183050f; - exp_vec[3].x = 1051.778931f; exp_vec[3].y = 376.462250f; exp_vec[3].z = 0.156329f; - exp_vec[4].x = 1037.348877f; exp_vec[4].y = 606.827393f; exp_vec[4].z = 0.133813f; - exp_vec[5].x = 1025.023560f; exp_vec[5].y = 803.591248f; exp_vec[5].z = 0.114581f; - D3DXVec3ProjectArray((D3DXVECTOR3*)(out_vec + 1), sizeof(D3DXVECTOR4), (CONST D3DXVECTOR3*)inp_vec, sizeof(D3DXVECTOR4), &viewport, &projection, &view, &world, ARRAY_SIZE); - compare_vectors(exp_vec, out_vec); - - /* D3DXVec3UnprojectArray */ - exp_vec[1].x = -6.124031f; exp_vec[1].y = 3.225360f; exp_vec[1].z = 0.620571f; - exp_vec[2].x = -3.807109f; exp_vec[2].y = 2.046579f; exp_vec[2].z = 0.446894f; - exp_vec[3].x = -2.922839f; exp_vec[3].y = 1.596689f; exp_vec[3].z = 0.380609f; - exp_vec[4].x = -2.456225f; exp_vec[4].y = 1.359290f; exp_vec[4].z = 0.345632f; - exp_vec[5].x = -2.167897f; exp_vec[5].y = 1.212597f; exp_vec[5].z = 0.324019f; - D3DXVec3UnprojectArray((D3DXVECTOR3*)(out_vec + 1), sizeof(D3DXVECTOR4), (CONST D3DXVECTOR3*)inp_vec, sizeof(D3DXVECTOR4), &viewport, &projection, &view, &world, ARRAY_SIZE); - compare_vectors(exp_vec, out_vec); - - /* D3DXVec2TransformArray */ - exp_vec[1].x = 38.0f; exp_vec[1].y = 44.0f; exp_vec[1].z = 50.0f; exp_vec[1].w = 56.0f; - exp_vec[2].x = 34.0f; exp_vec[2].y = 40.0f; exp_vec[2].z = 46.0f; exp_vec[2].w = 52.0f; - exp_vec[3].x = 30.0f; exp_vec[3].y = 36.0f; exp_vec[3].z = 42.0f; exp_vec[3].w = 48.0f; - exp_vec[4].x = 26.0f; exp_vec[4].y = 32.0f; exp_vec[4].z = 38.0f; exp_vec[4].w = 44.0f; - exp_vec[5].x = 22.0f; exp_vec[5].y = 28.0f; exp_vec[5].z = 34.0f; exp_vec[5].w = 40.0f; - D3DXVec2TransformArray(out_vec + 1, sizeof(D3DXVECTOR4), (D3DXVECTOR2*)inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); - compare_vectors(exp_vec, out_vec); - - /* D3DXVec3TransformArray */ - exp_vec[1].x = 38.0f; exp_vec[1].y = 44.0f; exp_vec[1].z = 50.0f; exp_vec[1].w = 56.0f; - exp_vec[2].x = 43.0f; exp_vec[2].y = 50.0f; exp_vec[2].z = 57.0f; exp_vec[2].w = 64.0f; - exp_vec[3].x = 48.0f; exp_vec[3].y = 56.0f; exp_vec[3].z = 64.0f; exp_vec[3].w = 72.0f; - exp_vec[4].x = 53.0f; exp_vec[4].y = 62.0f; exp_vec[4].z = 71.0f; exp_vec[4].w = 80.0f; - exp_vec[5].x = 58.0f; exp_vec[5].y = 68.0f; exp_vec[5].z = 78.0f; exp_vec[5].w = 88.0f; - D3DXVec3TransformArray(out_vec + 1, sizeof(D3DXVECTOR4), (D3DXVECTOR3*)inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); - compare_vectors(exp_vec, out_vec); - - /* D3DXVec4TransformArray */ - exp_vec[1].x = 90.0f; exp_vec[1].y = 100.0f; exp_vec[1].z = 110.0f; exp_vec[1].w = 120.0f; - exp_vec[2].x = 82.0f; exp_vec[2].y = 92.0f; exp_vec[2].z = 102.0f; exp_vec[2].w = 112.0f; - exp_vec[3].x = 74.0f; exp_vec[3].y = 84.0f; exp_vec[3].z = 94.0f; exp_vec[3].w = 104.0f; - exp_vec[4].x = 66.0f; exp_vec[4].y = 76.0f; exp_vec[4].z = 86.0f; exp_vec[4].w = 96.0f; - exp_vec[5].x = 58.0f; exp_vec[5].y = 68.0f; exp_vec[5].z = 78.0f; exp_vec[5].w = 88.0f; - D3DXVec4TransformArray(out_vec + 1, sizeof(D3DXVECTOR4), inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); - compare_vectors(exp_vec, out_vec); - - /* D3DXPlaneTransformArray */ - exp_plane[1].a = 90.0f; exp_plane[1].b = 100.0f; exp_plane[1].c = 110.0f; exp_plane[1].d = 120.0f; - exp_plane[2].a = 82.0f; exp_plane[2].b = 92.0f; exp_plane[2].c = 102.0f; exp_plane[2].d = 112.0f; - exp_plane[3].a = 74.0f; exp_plane[3].b = 84.0f; exp_plane[3].c = 94.0f; exp_plane[3].d = 104.0f; - exp_plane[4].a = 66.0f; exp_plane[4].b = 76.0f; exp_plane[4].c = 86.0f; exp_plane[4].d = 96.0f; - exp_plane[5].a = 58.0f; exp_plane[5].b = 68.0f; exp_plane[5].c = 78.0f; exp_plane[5].d = 88.0f; - D3DXPlaneTransformArray(out_plane + 1, sizeof(D3DXPLANE), inp_plane, sizeof(D3DXPLANE), &mat, ARRAY_SIZE); - compare_planes(exp_plane, out_plane); -} - -START_TEST(math) -{ - D3DXColorTest(); - D3DXFresnelTest(); - D3DXMatrixTest(); - D3DXPlaneTest(); - D3DXQuaternionTest(); - D3DXVector2Test(); - D3DXVector3Test(); - D3DXVector4Test(); - test_matrix_stack(); - test_Matrix_AffineTransformation2D(); - test_Matrix_Decompose(); - test_Matrix_Transformation2D(); - test_D3DXVec_Array(); -} +/* + * Copyright 2008 David Adam + * Copyright 2008 Philip Nilsson + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "wine/test.h" +#include "d3dx9.h" + +#define ARRAY_SIZE 5 + +#define admitted_error 0.0001f + +#define relative_error(exp, out) ((exp == out) ? 0.0f : (fabs(out - exp) / fabs(exp))) + +static inline BOOL compare_matrix(const D3DXMATRIX *m1, const D3DXMATRIX *m2) +{ + int i, j; + + for (i = 0; i < 4; ++i) + { + for (j = 0; j < 4; ++j) + { + if (fabs(U(*m1).m[i][j] - U(*m2).m[i][j]) > admitted_error) + return FALSE; + } + } + + return TRUE; +} + +#define expect_mat(expectedmat, gotmat) \ +do { \ + const D3DXMATRIX *__m1 = (expectedmat); \ + const D3DXMATRIX *__m2 = (gotmat); \ + ok(compare_matrix(__m1, __m2), "Expected matrix=\n(%f,%f,%f,%f\n %f,%f,%f,%f\n %f,%f,%f,%f\n %f,%f,%f,%f\n)\n\n" \ + "Got matrix=\n(%f,%f,%f,%f\n %f,%f,%f,%f\n %f,%f,%f,%f\n %f,%f,%f,%f)\n", \ + U(*__m1).m[0][0], U(*__m1).m[0][1], U(*__m1).m[0][2], U(*__m1).m[0][3], \ + U(*__m1).m[1][0], U(*__m1).m[1][1], U(*__m1).m[1][2], U(*__m1).m[1][3], \ + U(*__m1).m[2][0], U(*__m1).m[2][1], U(*__m1).m[2][2], U(*__m1).m[2][3], \ + U(*__m1).m[3][0], U(*__m1).m[3][1], U(*__m1).m[3][2], U(*__m1).m[3][3], \ + U(*__m2).m[0][0], U(*__m2).m[0][1], U(*__m2).m[0][2], U(*__m2).m[0][3], \ + U(*__m2).m[1][0], U(*__m2).m[1][1], U(*__m2).m[1][2], U(*__m2).m[1][3], \ + U(*__m2).m[2][0], U(*__m2).m[2][1], U(*__m2).m[2][2], U(*__m2).m[2][3], \ + U(*__m2).m[3][0], U(*__m2).m[3][1], U(*__m2).m[3][2], U(*__m2).m[3][3]); \ +} while(0) + +#define compare_rotation(exp, got) \ + ok(fabs(exp.w - got.w) < admitted_error && \ + fabs(exp.x - got.x) < admitted_error && \ + fabs(exp.y - got.y) < admitted_error && \ + fabs(exp.z - got.z) < admitted_error, \ + "Expected rotation = (%f, %f, %f, %f), \ + got rotation = (%f, %f, %f, %f)\n", \ + exp.w, exp.x, exp.y, exp.z, got.w, got.x, got.y, got.z) + +#define compare_scale(exp, got) \ + ok(fabs(exp.x - got.x) < admitted_error && \ + fabs(exp.y - got.y) < admitted_error && \ + fabs(exp.z - got.z) < admitted_error, \ + "Expected scale = (%f, %f, %f), \ + got scale = (%f, %f, %f)\n", \ + exp.x, exp.y, exp.z, got.x, got.y, got.z) + +#define compare_translation(exp, got) \ + ok(fabs(exp.x - got.x) < admitted_error && \ + fabs(exp.y - got.y) < admitted_error && \ + fabs(exp.z - got.z) < admitted_error, \ + "Expected translation = (%f, %f, %f), \ + got translation = (%f, %f, %f)\n", \ + exp.x, exp.y, exp.z, got.x, got.y, got.z) + +#define compare_vectors(exp, out) \ + for (i = 0; i < ARRAY_SIZE + 2; ++i) { \ + ok(relative_error(exp[i].x, out[i].x) < admitted_error && \ + relative_error(exp[i].y, out[i].y) < admitted_error && \ + relative_error(exp[i].z, out[i].z) < admitted_error && \ + relative_error(exp[i].w, out[i].w) < admitted_error, \ + "Got (%f, %f, %f, %f), expected (%f, %f, %f, %f) for index %d.\n", \ + out[i].x, out[i].y, out[i].z, out[i].w, \ + exp[i].x, exp[i].y, exp[i].z, exp[i].w, \ + i); \ + } + +#define compare_planes(exp, out) \ + for (i = 0; i < ARRAY_SIZE + 2; ++i) { \ + ok(relative_error(exp[i].a, out[i].a) < admitted_error && \ + relative_error(exp[i].b, out[i].b) < admitted_error && \ + relative_error(exp[i].c, out[i].c) < admitted_error && \ + relative_error(exp[i].d, out[i].d) < admitted_error, \ + "Got (%f, %f, %f, %f), expected (%f, %f, %f, %f) for index %d.\n", \ + out[i].a, out[i].b, out[i].c, out[i].d, \ + exp[i].a, exp[i].b, exp[i].c, exp[i].d, \ + i); \ + } + +/* The mathematical properties are checked in the d3dx8 testsuite. + * + * These tests check: + * That the functions work. + * That the stride functionality works. + * That nothing is written where it should not be. + * + * These tests should check: + * That inp_vec is not modified. + * That the input and output arrays can be the same (MSDN + * says they can, and some testing with a native DLL + * says so too). + */ + +static void test_Matrix_AffineTransformation2D(void) +{ + D3DXMATRIX exp_mat, got_mat; + D3DXVECTOR2 center, position; + FLOAT angle, scale; + + center.x = 3.0f; + center.y = 4.0f; + + position.x = -6.0f; + position.y = 7.0f; + + angle = D3DX_PI/3.0f; + + scale = 20.0f; + + U(exp_mat).m[0][0] = 10.0f; + U(exp_mat).m[1][0] = -17.320507f; + U(exp_mat).m[2][0] = 0.0f; + U(exp_mat).m[3][0] = -1.035898f; + U(exp_mat).m[0][1] = 17.320507f; + U(exp_mat).m[1][1] = 10.0f; + U(exp_mat).m[2][1] = 0.0f; + U(exp_mat).m[3][1] = 6.401924f; + U(exp_mat).m[0][2] = 0.0f; + U(exp_mat).m[1][2] = 0.0f; + U(exp_mat).m[2][2] = 1.0f; + U(exp_mat).m[3][2] = 0.0f; + U(exp_mat).m[0][3] = 0.0f; + U(exp_mat).m[1][3] = 0.0f; + U(exp_mat).m[2][3] = 0.0f; + U(exp_mat).m[3][3] = 1.0f; + + D3DXMatrixAffineTransformation2D(&got_mat, scale, ¢er, angle, &position); + + expect_mat(&exp_mat, &got_mat); + +/*______________*/ + + center.x = 3.0f; + center.y = 4.0f; + + angle = D3DX_PI/3.0f; + + scale = 20.0f; + + U(exp_mat).m[0][0] = 10.0f; + U(exp_mat).m[1][0] = -17.320507f; + U(exp_mat).m[2][0] = 0.0f; + U(exp_mat).m[3][0] = 4.964102f; + U(exp_mat).m[0][1] = 17.320507f; + U(exp_mat).m[1][1] = 10.0f; + U(exp_mat).m[2][1] = 0.0f; + U(exp_mat).m[3][1] = -0.598076f; + U(exp_mat).m[0][2] = 0.0f; + U(exp_mat).m[1][2] = 0.0f; + U(exp_mat).m[2][2] = 1.0f; + U(exp_mat).m[3][2] = 0.0f; + U(exp_mat).m[0][3] = 0.0f; + U(exp_mat).m[1][3] = 0.0f; + U(exp_mat).m[2][3] = 0.0f; + U(exp_mat).m[3][3] = 1.0f; + + D3DXMatrixAffineTransformation2D(&got_mat, scale, ¢er, angle, NULL); + + expect_mat(&exp_mat, &got_mat); + +/*______________*/ + + position.x = -6.0f; + position.y = 7.0f; + + angle = D3DX_PI/3.0f; + + scale = 20.0f; + + U(exp_mat).m[0][0] = 10.0f; + U(exp_mat).m[1][0] = -17.320507f; + U(exp_mat).m[2][0] = 0.0f; + U(exp_mat).m[3][0] = -6.0f; + U(exp_mat).m[0][1] = 17.320507f; + U(exp_mat).m[1][1] = 10.0f; + U(exp_mat).m[2][1] = 0.0f; + U(exp_mat).m[3][1] = 7.0f; + U(exp_mat).m[0][2] = 0.0f; + U(exp_mat).m[1][2] = 0.0f; + U(exp_mat).m[2][2] = 1.0f; + U(exp_mat).m[3][2] = 0.0f; + U(exp_mat).m[0][3] = 0.0f; + U(exp_mat).m[1][3] = 0.0f; + U(exp_mat).m[2][3] = 0.0f; + U(exp_mat).m[3][3] = 1.0f; + + D3DXMatrixAffineTransformation2D(&got_mat, scale, NULL, angle, &position); + + expect_mat(&exp_mat, &got_mat); + +/*______________*/ + + angle = 5.0f * D3DX_PI/4.0f; + + scale = -20.0f; + + U(exp_mat).m[0][0] = 14.142133f; + U(exp_mat).m[1][0] = -14.142133f; + U(exp_mat).m[2][0] = 0.0f; + U(exp_mat).m[3][0] = 0.0f; + U(exp_mat).m[0][1] = 14.142133; + U(exp_mat).m[1][1] = 14.142133f; + U(exp_mat).m[2][1] = 0.0f; + U(exp_mat).m[3][1] = 0.0f; + U(exp_mat).m[0][2] = 0.0f; + U(exp_mat).m[1][2] = 0.0f; + U(exp_mat).m[2][2] = 1.0f; + U(exp_mat).m[3][2] = 0.0f; + U(exp_mat).m[0][3] = 0.0f; + U(exp_mat).m[1][3] = 0.0f; + U(exp_mat).m[2][3] = 0.0f; + U(exp_mat).m[3][3] = 1.0f; + + D3DXMatrixAffineTransformation2D(&got_mat, scale, NULL, angle, NULL); + + expect_mat(&exp_mat, &got_mat); +} + +static void test_Matrix_Decompose(void) +{ + D3DXMATRIX pm; + D3DXQUATERNION exp_rotation, got_rotation; + D3DXVECTOR3 exp_scale, got_scale, exp_translation, got_translation; + HRESULT hr; + +/*___________*/ + + U(pm).m[0][0] = -0.9238790f; + U(pm).m[1][0] = -0.2705984f; + U(pm).m[2][0] = 0.2705984f; + U(pm).m[3][0] = -5.0f; + U(pm).m[0][1] = 0.2705984f; + U(pm).m[1][1] = 0.03806049f; + U(pm).m[2][1] = 0.9619395f; + U(pm).m[3][1] = 0.0f; + U(pm).m[0][2] = -0.2705984f; + U(pm).m[1][2] = 0.9619395f; + U(pm).m[2][2] = 0.03806049f; + U(pm).m[3][2] = 10.0f; + U(pm).m[0][3] = 0.0f; + U(pm).m[1][3] = 0.0f; + U(pm).m[2][3] = 0.0f; + U(pm).m[3][3] = 1.0f; + + exp_scale.x = 1.0f; + exp_scale.y = 1.0f; + exp_scale.z = 1.0f; + + exp_rotation.w = 0.195091f; + exp_rotation.x = 0.0f; + exp_rotation.y = 0.693520f; + exp_rotation.z = 0.693520f; + + exp_translation.x = -5.0f; + exp_translation.y = 0.0f; + exp_translation.z = 10.0f; + + D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); + + compare_scale(exp_scale, got_scale); + compare_rotation(exp_rotation, got_rotation); + compare_translation(exp_translation, got_translation); + +/*_________*/ + + U(pm).m[0][0] = -2.255813f; + U(pm).m[1][0] = 1.302324f; + U(pm).m[2][0] = 1.488373f; + U(pm).m[3][0] = 1.0f; + U(pm).m[0][1] = 1.302327f; + U(pm).m[1][1] = -0.7209296f; + U(pm).m[2][1] = 2.60465f; + U(pm).m[3][1] = 2.0f; + U(pm).m[0][2] = 1.488371f; + U(pm).m[1][2] = 2.604651f; + U(pm).m[2][2] = -0.02325551f; + U(pm).m[3][2] = 3.0f; + U(pm).m[0][3] = 0.0f; + U(pm).m[1][3] = 0.0f; + U(pm).m[2][3] = 0.0f; + U(pm).m[3][3] = 1.0f; + + exp_scale.x = 3.0f; + exp_scale.y = 3.0f; + exp_scale.z = 3.0f; + + exp_rotation.w = 0.0; + exp_rotation.x = 0.352180f; + exp_rotation.y = 0.616316f; + exp_rotation.z = 0.704361f; + + exp_translation.x = 1.0f; + exp_translation.y = 2.0f; + exp_translation.z = 3.0f; + + D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); + + compare_scale(exp_scale, got_scale); + compare_rotation(exp_rotation, got_rotation); + compare_translation(exp_translation, got_translation); + +/*_____________*/ + + U(pm).m[0][0] = 2.427051f; + U(pm).m[1][0] = 0.0f; + U(pm).m[2][0] = 1.763355f; + U(pm).m[3][0] = 5.0f; + U(pm).m[0][1] = 0.0f; + U(pm).m[1][1] = 3.0f; + U(pm).m[2][1] = 0.0f; + U(pm).m[3][1] = 5.0f; + U(pm).m[0][2] = -1.763355f; + U(pm).m[1][2] = 0.0f; + U(pm).m[2][2] = 2.427051f; + U(pm).m[3][2] = 5.0f; + U(pm).m[0][3] = 0.0f; + U(pm).m[1][3] = 0.0f; + U(pm).m[2][3] = 0.0f; + U(pm).m[3][3] = 1.0f; + + exp_scale.x = 3.0f; + exp_scale.y = 3.0f; + exp_scale.z = 3.0f; + + exp_rotation.w = 0.951057f; + exp_rotation.x = 0.0f; + exp_rotation.y = 0.309017f; + exp_rotation.z = 0.0f; + + exp_translation.x = 5.0f; + exp_translation.y = 5.0f; + exp_translation.z = 5.0f; + + D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); + + compare_scale(exp_scale, got_scale); + compare_rotation(exp_rotation, got_rotation); + compare_translation(exp_translation, got_translation); + +/*_____________*/ + + U(pm).m[0][0] = -0.9238790f; + U(pm).m[1][0] = -0.2705984f; + U(pm).m[2][0] = 0.2705984f; + U(pm).m[3][0] = -5.0f; + U(pm).m[0][1] = 0.2705984f; + U(pm).m[1][1] = 0.03806049f; + U(pm).m[2][1] = 0.9619395f; + U(pm).m[3][1] = 0.0f; + U(pm).m[0][2] = -0.2705984f; + U(pm).m[1][2] = 0.9619395f; + U(pm).m[2][2] = 0.03806049f; + U(pm).m[3][2] = 10.0f; + U(pm).m[0][3] = 0.0f; + U(pm).m[1][3] = 0.0f; + U(pm).m[2][3] = 0.0f; + U(pm).m[3][3] = 1.0f; + + exp_scale.x = 1.0f; + exp_scale.y = 1.0f; + exp_scale.z = 1.0f; + + exp_rotation.w = 0.195091f; + exp_rotation.x = 0.0f; + exp_rotation.y = 0.693520f; + exp_rotation.z = 0.693520f; + + exp_translation.x = -5.0f; + exp_translation.y = 0.0f; + exp_translation.z = 10.0f; + + D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); + + compare_scale(exp_scale, got_scale); + compare_rotation(exp_rotation, got_rotation); + compare_translation(exp_translation, got_translation); + +/*__________*/ + + U(pm).m[0][0] = -0.9238790f; + U(pm).m[1][0] = -0.5411968f; + U(pm).m[2][0] = 0.8117952f; + U(pm).m[3][0] = -5.0f; + U(pm).m[0][1] = 0.2705984f; + U(pm).m[1][1] = 0.07612098f; + U(pm).m[2][1] = 2.8858185f; + U(pm).m[3][1] = 0.0f; + U(pm).m[0][2] = -0.2705984f; + U(pm).m[1][2] = 1.9238790f; + U(pm).m[2][2] = 0.11418147f; + U(pm).m[3][2] = 10.0f; + U(pm).m[0][3] = 0.0f; + U(pm).m[1][3] = 0.0f; + U(pm).m[2][3] = 0.0f; + U(pm).m[3][3] = 1.0f; + + exp_scale.x = 1.0f; + exp_scale.y = 2.0f; + exp_scale.z = 3.0f; + + exp_rotation.w = 0.195091f; + exp_rotation.x = 0.0f; + exp_rotation.y = 0.693520f; + exp_rotation.z = 0.693520f; + + exp_translation.x = -5.0f; + exp_translation.y = 0.0f; + exp_translation.z = 10.0f; + + D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); + + compare_scale(exp_scale, got_scale); + compare_rotation(exp_rotation, got_rotation); + compare_translation(exp_translation, got_translation); + +/*__________*/ + + U(pm).m[0][0] = 0.7156004f; + U(pm).m[1][0] = -0.5098283f; + U(pm).m[2][0] = -0.4774843f; + U(pm).m[3][0] = -5.0f; + U(pm).m[0][1] = -0.6612288f; + U(pm).m[1][1] = -0.7147621f; + U(pm).m[2][1] = -0.2277977f; + U(pm).m[3][1] = 0.0f; + U(pm).m[0][2] = -0.2251499f; + U(pm).m[1][2] = 0.4787385f; + U(pm).m[2][2] = -0.8485972f; + U(pm).m[3][2] = 10.0f; + U(pm).m[0][3] = 0.0f; + U(pm).m[1][3] = 0.0f; + U(pm).m[2][3] = 0.0f; + U(pm).m[3][3] = 1.0f; + + exp_scale.x = 1.0f; + exp_scale.y = 1.0f; + exp_scale.z = 1.0f; + + exp_rotation.w = 0.195091f; + exp_rotation.x = 0.905395f; + exp_rotation.y = -0.323355f; + exp_rotation.z = -0.194013f; + + exp_translation.x = -5.0f; + exp_translation.y = 0.0f; + exp_translation.z = 10.0f; + + D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); + + compare_scale(exp_scale, got_scale); + compare_rotation(exp_rotation, got_rotation); + compare_translation(exp_translation, got_translation); + +/*_____________*/ + + U(pm).m[0][0] = 0.06554436f; + U(pm).m[1][0] = -0.6873012f; + U(pm).m[2][0] = 0.7234092f; + U(pm).m[3][0] = -5.0f; + U(pm).m[0][1] = -0.9617381f; + U(pm).m[1][1] = -0.2367795f; + U(pm).m[2][1] = -0.1378230f; + U(pm).m[3][1] = 0.0f; + U(pm).m[0][2] = 0.2660144f; + U(pm).m[1][2] = -0.6866967f; + U(pm).m[2][2] = -0.6765233f; + U(pm).m[3][2] = 10.0f; + U(pm).m[0][3] = 0.0f; + U(pm).m[1][3] = 0.0f; + U(pm).m[2][3] = 0.0f; + U(pm).m[3][3] = 1.0f; + + exp_scale.x = 1.0f; + exp_scale.y = 1.0f; + exp_scale.z = 1.0f; + + exp_rotation.w = -0.195091f; + exp_rotation.x = 0.703358f; + exp_rotation.y = -0.586131f; + exp_rotation.z = 0.351679f; + + exp_translation.x = -5.0f; + exp_translation.y = 0.0f; + exp_translation.z = 10.0f; + + D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); + + compare_scale(exp_scale, got_scale); + compare_rotation(exp_rotation, got_rotation); + compare_translation(exp_translation, got_translation); + +/*_________*/ + + U(pm).m[0][0] = 7.121047f; + U(pm).m[1][0] = -5.883487f; + U(pm).m[2][0] = 11.81843f; + U(pm).m[3][0] = -5.0f; + U(pm).m[0][1] = 5.883487f; + U(pm).m[1][1] = -10.60660f; + U(pm).m[2][1] = -8.825232f; + U(pm).m[3][1] = 0.0f; + U(pm).m[0][2] = 11.81843f; + U(pm).m[1][2] = 8.8252320f; + U(pm).m[2][2] = -2.727645f; + U(pm).m[3][2] = 2.0f; + U(pm).m[0][3] = 0.0f; + U(pm).m[1][3] = 0.0f; + U(pm).m[2][3] = 0.0f; + U(pm).m[3][3] = 1.0f; + + exp_scale.x = 15.0f; + exp_scale.y = 15.0f; + exp_scale.z = 15.0f; + + exp_rotation.w = 0.382684f; + exp_rotation.x = 0.768714f; + exp_rotation.y = 0.0f; + exp_rotation.z = 0.512476f; + + exp_translation.x = -5.0f; + exp_translation.y = 0.0f; + exp_translation.z = 2.0f; + + D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); + + compare_scale(exp_scale, got_scale); + compare_rotation(exp_rotation, got_rotation); + compare_translation(exp_translation, got_translation); + +/*__________*/ + + U(pm).m[0][0] = 0.0f; + U(pm).m[1][0] = 4.0f; + U(pm).m[2][0] = 5.0f; + U(pm).m[3][0] = -5.0f; + U(pm).m[0][1] = 0.0f; + U(pm).m[1][1] = -10.60660f; + U(pm).m[2][1] = -8.825232f; + U(pm).m[3][1] = 6.0f; + U(pm).m[0][2] = 0.0f; + U(pm).m[1][2] = 8.8252320f; + U(pm).m[2][2] = 2.727645; + U(pm).m[3][2] = 3.0f; + U(pm).m[0][3] = 0.0f; + U(pm).m[1][3] = 0.0f; + U(pm).m[2][3] = 0.0f; + U(pm).m[3][3] = 1.0f; + + hr = D3DXMatrixDecompose(&got_scale, &got_rotation, &got_translation, &pm); + ok(hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %x\n", hr); +} + +static void test_Matrix_Transformation2D(void) +{ + D3DXMATRIX exp_mat, got_mat; + D3DXVECTOR2 rot_center, sca, sca_center, trans; + FLOAT rot, sca_rot; + + rot_center.x = 3.0f; + rot_center.y = 4.0f; + + sca.x = 12.0f; + sca.y = -3.0f; + + sca_center.x = 9.0f; + sca_center.y = -5.0f; + + trans.x = -6.0f; + trans.y = 7.0f; + + rot = D3DX_PI/3.0f; + + sca_rot = 5.0f*D3DX_PI/4.0f; + + U(exp_mat).m[0][0] = -4.245192f; + U(exp_mat).m[1][0] = -0.147116f; + U(exp_mat).m[2][0] = 0.0f; + U(exp_mat).m[3][0] = 45.265373f; + U(exp_mat).m[0][1] = 7.647113f; + U(exp_mat).m[1][1] = 8.745192f; + U(exp_mat).m[2][1] = 0.0f; + U(exp_mat).m[3][1] = -13.401899f; + U(exp_mat).m[0][2] = 0.0f; + U(exp_mat).m[1][2] = 0.0f; + U(exp_mat).m[2][2] = 1.0f; + U(exp_mat).m[3][2] = 0.0f; + U(exp_mat).m[0][3] = 0.0f; + U(exp_mat).m[1][3] = 0.0f; + U(exp_mat).m[2][3] = 0.0f; + U(exp_mat).m[3][3] = 1.0f; + + D3DXMatrixTransformation2D(&got_mat, &sca_center, sca_rot, &sca, &rot_center, rot, &trans); + + expect_mat(&exp_mat, &got_mat); + +/*_________*/ + + sca_center.x = 9.0f; + sca_center.y = -5.0f; + + trans.x = -6.0f; + trans.y = 7.0f; + + rot = D3DX_PI/3.0f; + + sca_rot = 5.0f*D3DX_PI/4.0f; + + U(exp_mat).m[0][0] = 0.50f; + U(exp_mat).m[1][0] = -0.866025f; + U(exp_mat).m[2][0] = 0.0f; + U(exp_mat).m[3][0] = -6.0f; + U(exp_mat).m[0][1] = 0.866025f; + U(exp_mat).m[1][1] = 0.50f; + U(exp_mat).m[2][1] = 0.0f; + U(exp_mat).m[3][1] = 7.0f; + U(exp_mat).m[0][2] = 0.0f; + U(exp_mat).m[1][2] = 0.0f; + U(exp_mat).m[2][2] = 1.0f; + U(exp_mat).m[3][2] = 0.0f; + U(exp_mat).m[0][3] = 0.0f; + U(exp_mat).m[1][3] = 0.0f; + U(exp_mat).m[2][3] = 0.0f; + U(exp_mat).m[3][3] = 1.0f; + + D3DXMatrixTransformation2D(&got_mat, &sca_center, sca_rot, NULL, NULL, rot, &trans); + + expect_mat(&exp_mat, &got_mat); + +/*_________*/ + + U(exp_mat).m[0][0] = 0.50f; + U(exp_mat).m[1][0] = -0.866025f; + U(exp_mat).m[2][0] = 0.0f; + U(exp_mat).m[3][0] = 0.0f; + U(exp_mat).m[0][1] = 0.866025f; + U(exp_mat).m[1][1] = 0.50f; + U(exp_mat).m[2][1] = 0.0f; + U(exp_mat).m[3][1] = 0.0f; + U(exp_mat).m[0][2] = 0.0f; + U(exp_mat).m[1][2] = 0.0f; + U(exp_mat).m[2][2] = 1.0f; + U(exp_mat).m[3][2] = 0.0f; + U(exp_mat).m[0][3] = 0.0f; + U(exp_mat).m[1][3] = 0.0f; + U(exp_mat).m[2][3] = 0.0f; + U(exp_mat).m[3][3] = 1.0f; + + D3DXMatrixTransformation2D(&got_mat, NULL, sca_rot, NULL, NULL, rot, NULL); + + expect_mat(&exp_mat, &got_mat); +} + +static void test_D3DXVec_Array(void) +{ + unsigned int i; + D3DVIEWPORT9 viewport; + D3DXMATRIX mat, projection, view, world; + D3DXVECTOR4 inp_vec[ARRAY_SIZE]; + D3DXVECTOR4 out_vec[ARRAY_SIZE + 2]; + D3DXVECTOR4 exp_vec[ARRAY_SIZE + 2]; + D3DXPLANE inp_plane[ARRAY_SIZE]; + D3DXPLANE out_plane[ARRAY_SIZE + 2]; + D3DXPLANE exp_plane[ARRAY_SIZE + 2]; + + viewport.Width = 800; viewport.MinZ = 0.2f; viewport.X = 10; + viewport.Height = 680; viewport.MaxZ = 0.9f; viewport.Y = 5; + + for (i = 0; i < ARRAY_SIZE + 2; ++i) { + out_vec[i].x = out_vec[i].y = out_vec[i].z = out_vec[i].w = 0.0f; + exp_vec[i].x = exp_vec[i].y = exp_vec[i].z = exp_vec[i].w = 0.0f; + out_plane[i].a = out_plane[i].b = out_plane[i].c = out_plane[i].d = 0.0f; + exp_plane[i].a = exp_plane[i].b = exp_plane[i].c = exp_plane[i].d = 0.0f; + } + + for (i = 0; i < ARRAY_SIZE; ++i) { + inp_plane[i].a = inp_plane[i].c = inp_vec[i].x = inp_vec[i].z = i; + inp_plane[i].b = inp_plane[i].d = inp_vec[i].y = inp_vec[i].w = ARRAY_SIZE - i; + } + + U(mat).m[0][0] = 1.0f; U(mat).m[0][1] = 2.0f; U(mat).m[0][2] = 3.0f; U(mat).m[0][3] = 4.0f; + U(mat).m[1][0] = 5.0f; U(mat).m[1][1] = 6.0f; U(mat).m[1][2] = 7.0f; U(mat).m[1][3] = 8.0f; + U(mat).m[2][0] = 9.0f; U(mat).m[2][1] = 10.0f; U(mat).m[2][2] = 11.0f; U(mat).m[2][3] = 12.0f; + U(mat).m[3][0] = 13.0f; U(mat).m[3][1] = 14.0f; U(mat).m[3][2] = 15.0f; U(mat).m[3][3] = 16.0f; + + D3DXMatrixPerspectiveFovLH(&projection,D3DX_PI/4.0f,20.0f/17.0f,1.0f,1000.0f); + + U(view).m[0][1] = 5.0f; U(view).m[0][2] = 7.0f; U(view).m[0][3] = 8.0f; + U(view).m[1][0] = 11.0f; U(view).m[1][2] = 16.0f; U(view).m[1][3] = 33.0f; + U(view).m[2][0] = 19.0f; U(view).m[2][1] = -21.0f; U(view).m[2][3] = 43.0f; + U(view).m[3][0] = 2.0f; U(view).m[3][1] = 3.0f; U(view).m[3][2] = -4.0f; + U(view).m[0][0] = 10.0f; U(view).m[1][1] = 20.0f; U(view).m[2][2] = 30.0f; + U(view).m[3][3] = -40.0f; + + U(world).m[0][0] = 21.0f; U(world).m[0][1] = 2.0f; U(world).m[0][2] = 3.0f; U(world).m[0][3] = 4.0; + U(world).m[1][0] = 5.0f; U(world).m[1][1] = 23.0f; U(world).m[1][2] = 7.0f; U(world).m[1][3] = 8.0f; + U(world).m[2][0] = -8.0f; U(world).m[2][1] = -7.0f; U(world).m[2][2] = 25.0f; U(world).m[2][3] = -5.0f; + U(world).m[3][0] = -4.0f; U(world).m[3][1] = -3.0f; U(world).m[3][2] = -2.0f; U(world).m[3][3] = 27.0f; + + /* D3DXVec2TransformCoordArray */ + exp_vec[1].x = 0.678571f; exp_vec[1].y = 0.785714f; + exp_vec[2].x = 0.653846f; exp_vec[2].y = 0.769231f; + exp_vec[3].x = 0.625f; exp_vec[3].y = 0.75f; + exp_vec[4].x = 0.590909f; exp_vec[4].y = 8.0f/11.0f; + exp_vec[5].x = 0.55f; exp_vec[5].y = 0.7f; + D3DXVec2TransformCoordArray((D3DXVECTOR2*)(out_vec + 1), sizeof(D3DXVECTOR4), (D3DXVECTOR2*)inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); + compare_vectors(exp_vec, out_vec); + + /* D3DXVec2TransformNormalArray */ + exp_vec[1].x = 25.0f; exp_vec[1].y = 30.0f; + exp_vec[2].x = 21.0f; exp_vec[2].y = 26.0f; + exp_vec[3].x = 17.0f; exp_vec[3].y = 22.0f; + exp_vec[4].x = 13.0f; exp_vec[4].y = 18.0f; + exp_vec[5].x = 9.0f; exp_vec[5].y = 14.0f; + D3DXVec2TransformNormalArray((D3DXVECTOR2*)(out_vec + 1), sizeof(D3DXVECTOR4), (D3DXVECTOR2*)inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); + compare_vectors(exp_vec, out_vec); + + /* D3DXVec3TransformCoordArray */ + exp_vec[1].x = 0.678571f; exp_vec[1].y = 0.785714f; exp_vec[1].z = 0.892857f; + exp_vec[2].x = 0.671875f; exp_vec[2].y = 0.78125f; exp_vec[2].z = 0.890625f; + exp_vec[3].x = 6.0f/9.0f; exp_vec[3].y = 7.0f/9.0f; exp_vec[3].z = 8.0f/9.0f; + exp_vec[4].x = 0.6625f; exp_vec[4].y = 0.775f; exp_vec[4].z = 0.8875f; + exp_vec[5].x = 0.659091f; exp_vec[5].y = 0.772727f; exp_vec[5].z = 0.886364f; + D3DXVec3TransformCoordArray((D3DXVECTOR3*)(out_vec + 1), sizeof(D3DXVECTOR4), (D3DXVECTOR3*)inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); + compare_vectors(exp_vec, out_vec); + + /* D3DXVec3TransformNormalArray */ + exp_vec[1].x = 25.0f; exp_vec[1].y = 30.0f; exp_vec[1].z = 35.0f; + exp_vec[2].x = 30.0f; exp_vec[2].y = 36.0f; exp_vec[2].z = 42.0f; + exp_vec[3].x = 35.0f; exp_vec[3].y = 42.0f; exp_vec[3].z = 49.0f; + exp_vec[4].x = 40.0f; exp_vec[4].y = 48.0f; exp_vec[4].z = 56.0f; + exp_vec[5].x = 45.0f; exp_vec[5].y = 54.0f; exp_vec[5].z = 63.0f; + D3DXVec3TransformNormalArray((D3DXVECTOR3*)(out_vec + 1), sizeof(D3DXVECTOR4), (D3DXVECTOR3*)inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); + compare_vectors(exp_vec, out_vec); + + /* D3DXVec3ProjectArray */ + exp_vec[1].x = 1089.554199f; exp_vec[1].y = -226.590622f; exp_vec[1].z = 0.215273f; + exp_vec[2].x = 1068.903320f; exp_vec[2].y = 103.085129f; exp_vec[2].z = 0.183050f; + exp_vec[3].x = 1051.778931f; exp_vec[3].y = 376.462250f; exp_vec[3].z = 0.156329f; + exp_vec[4].x = 1037.348877f; exp_vec[4].y = 606.827393f; exp_vec[4].z = 0.133813f; + exp_vec[5].x = 1025.023560f; exp_vec[5].y = 803.591248f; exp_vec[5].z = 0.114581f; + D3DXVec3ProjectArray((D3DXVECTOR3*)(out_vec + 1), sizeof(D3DXVECTOR4), (CONST D3DXVECTOR3*)inp_vec, sizeof(D3DXVECTOR4), &viewport, &projection, &view, &world, ARRAY_SIZE); + compare_vectors(exp_vec, out_vec); + + /* D3DXVec3UnprojectArray */ + exp_vec[1].x = -6.124031f; exp_vec[1].y = 3.225360f; exp_vec[1].z = 0.620571f; + exp_vec[2].x = -3.807109f; exp_vec[2].y = 2.046579f; exp_vec[2].z = 0.446894f; + exp_vec[3].x = -2.922839f; exp_vec[3].y = 1.596689f; exp_vec[3].z = 0.380609f; + exp_vec[4].x = -2.456225f; exp_vec[4].y = 1.359290f; exp_vec[4].z = 0.345632f; + exp_vec[5].x = -2.167897f; exp_vec[5].y = 1.212597f; exp_vec[5].z = 0.324019f; + D3DXVec3UnprojectArray((D3DXVECTOR3*)(out_vec + 1), sizeof(D3DXVECTOR4), (CONST D3DXVECTOR3*)inp_vec, sizeof(D3DXVECTOR4), &viewport, &projection, &view, &world, ARRAY_SIZE); + compare_vectors(exp_vec, out_vec); + + /* D3DXVec2TransformArray */ + exp_vec[1].x = 38.0f; exp_vec[1].y = 44.0f; exp_vec[1].z = 50.0f; exp_vec[1].w = 56.0f; + exp_vec[2].x = 34.0f; exp_vec[2].y = 40.0f; exp_vec[2].z = 46.0f; exp_vec[2].w = 52.0f; + exp_vec[3].x = 30.0f; exp_vec[3].y = 36.0f; exp_vec[3].z = 42.0f; exp_vec[3].w = 48.0f; + exp_vec[4].x = 26.0f; exp_vec[4].y = 32.0f; exp_vec[4].z = 38.0f; exp_vec[4].w = 44.0f; + exp_vec[5].x = 22.0f; exp_vec[5].y = 28.0f; exp_vec[5].z = 34.0f; exp_vec[5].w = 40.0f; + D3DXVec2TransformArray(out_vec + 1, sizeof(D3DXVECTOR4), (D3DXVECTOR2*)inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); + compare_vectors(exp_vec, out_vec); + + /* D3DXVec3TransformArray */ + exp_vec[1].x = 38.0f; exp_vec[1].y = 44.0f; exp_vec[1].z = 50.0f; exp_vec[1].w = 56.0f; + exp_vec[2].x = 43.0f; exp_vec[2].y = 50.0f; exp_vec[2].z = 57.0f; exp_vec[2].w = 64.0f; + exp_vec[3].x = 48.0f; exp_vec[3].y = 56.0f; exp_vec[3].z = 64.0f; exp_vec[3].w = 72.0f; + exp_vec[4].x = 53.0f; exp_vec[4].y = 62.0f; exp_vec[4].z = 71.0f; exp_vec[4].w = 80.0f; + exp_vec[5].x = 58.0f; exp_vec[5].y = 68.0f; exp_vec[5].z = 78.0f; exp_vec[5].w = 88.0f; + D3DXVec3TransformArray(out_vec + 1, sizeof(D3DXVECTOR4), (D3DXVECTOR3*)inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); + compare_vectors(exp_vec, out_vec); + + /* D3DXVec4TransformArray */ + exp_vec[1].x = 90.0f; exp_vec[1].y = 100.0f; exp_vec[1].z = 110.0f; exp_vec[1].w = 120.0f; + exp_vec[2].x = 82.0f; exp_vec[2].y = 92.0f; exp_vec[2].z = 102.0f; exp_vec[2].w = 112.0f; + exp_vec[3].x = 74.0f; exp_vec[3].y = 84.0f; exp_vec[3].z = 94.0f; exp_vec[3].w = 104.0f; + exp_vec[4].x = 66.0f; exp_vec[4].y = 76.0f; exp_vec[4].z = 86.0f; exp_vec[4].w = 96.0f; + exp_vec[5].x = 58.0f; exp_vec[5].y = 68.0f; exp_vec[5].z = 78.0f; exp_vec[5].w = 88.0f; + D3DXVec4TransformArray(out_vec + 1, sizeof(D3DXVECTOR4), inp_vec, sizeof(D3DXVECTOR4), &mat, ARRAY_SIZE); + compare_vectors(exp_vec, out_vec); + + /* D3DXPlaneTransformArray */ + exp_plane[1].a = 90.0f; exp_plane[1].b = 100.0f; exp_plane[1].c = 110.0f; exp_plane[1].d = 120.0f; + exp_plane[2].a = 82.0f; exp_plane[2].b = 92.0f; exp_plane[2].c = 102.0f; exp_plane[2].d = 112.0f; + exp_plane[3].a = 74.0f; exp_plane[3].b = 84.0f; exp_plane[3].c = 94.0f; exp_plane[3].d = 104.0f; + exp_plane[4].a = 66.0f; exp_plane[4].b = 76.0f; exp_plane[4].c = 86.0f; exp_plane[4].d = 96.0f; + exp_plane[5].a = 58.0f; exp_plane[5].b = 68.0f; exp_plane[5].c = 78.0f; exp_plane[5].d = 88.0f; + D3DXPlaneTransformArray(out_plane + 1, sizeof(D3DXPLANE), inp_plane, sizeof(D3DXPLANE), &mat, ARRAY_SIZE); + compare_planes(exp_plane, out_plane); +} + +START_TEST(math) +{ + test_Matrix_AffineTransformation2D(); + test_Matrix_Decompose(); + test_Matrix_Transformation2D(); + test_D3DXVec_Array(); +} diff --git a/dlls/d3dx9_36/tests/mesh.c b/dlls/d3dx9_36/tests/mesh.c dissimilarity index 76% index 0f451a2501c..d3d69943d1d 100644 --- a/dlls/d3dx9_36/tests/mesh.c +++ b/dlls/d3dx9_36/tests/mesh.c @@ -1,465 +1,97 @@ -/* - * Copyright 2008 David Adam - * Copyright 2008 Luis Busquets - * Copyright 2009 Henri Verbeet for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "wine/test.h" -#include "d3dx9.h" - -#define admitted_error 0.0001f - -#define compare_vertex_sizes(type, exp) \ - got=D3DXGetFVFVertexSize(type); \ - ok(got==exp, "Expected: %d, Got: %d\n", exp, got); - -static BOOL compare(FLOAT u, FLOAT v) -{ - return (fabs(u-v) < admitted_error); -} - -static BOOL compare_vec3(D3DXVECTOR3 u, D3DXVECTOR3 v) -{ - return ( compare(u.x, v.x) && compare(u.y, v.y) && compare(u.z, v.z) ); -} - -static void D3DXBoundProbeTest(void) -{ - BOOL result; - D3DXVECTOR3 bottom_point, center, top_point, raydirection, rayposition; - FLOAT radius; - -/*____________Test the Box case___________________________*/ - bottom_point.x = -3.0f; bottom_point.y = -2.0f; bottom_point.z = -1.0f; - top_point.x = 7.0f; top_point.y = 8.0f; top_point.z = 9.0f; - - raydirection.x = -4.0f; raydirection.y = -5.0f; raydirection.z = -6.0f; - rayposition.x = 5.0f; rayposition.y = 5.0f; rayposition.z = 11.0f; - result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); - ok(result == TRUE, "expected TRUE, received FALSE\n"); - - raydirection.x = 4.0f; raydirection.y = 5.0f; raydirection.z = 6.0f; - rayposition.x = 5.0f; rayposition.y = 5.0f; rayposition.z = 11.0f; - result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); - ok(result == FALSE, "expected FALSE, received TRUE\n"); - - rayposition.x = -4.0f; rayposition.y = 1.0f; rayposition.z = -2.0f; - result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); - ok(result == TRUE, "expected TRUE, received FALSE\n"); - - bottom_point.x = 1.0f; bottom_point.y = 0.0f; bottom_point.z = 0.0f; - top_point.x = 1.0f; top_point.y = 0.0f; top_point.z = 0.0f; - rayposition.x = 0.0f; rayposition.y = 1.0f; rayposition.z = 0.0f; - raydirection.x = 0.0f; raydirection.y = 3.0f; raydirection.z = 0.0f; - result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); - ok(result == FALSE, "expected FALSE, received TRUE\n"); - - bottom_point.x = 1.0f; bottom_point.y = 2.0f; bottom_point.z = 3.0f; - top_point.x = 10.0f; top_point.y = 15.0f; top_point.z = 20.0f; - - raydirection.x = 7.0f; raydirection.y = 8.0f; raydirection.z = 9.0f; - rayposition.x = 3.0f; rayposition.y = 7.0f; rayposition.z = -6.0f; - result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); - ok(result == TRUE, "expected TRUE, received FALSE\n"); - - bottom_point.x = 0.0f; bottom_point.y = 0.0f; bottom_point.z = 0.0f; - top_point.x = 1.0f; top_point.y = 1.0f; top_point.z = 1.0f; - - raydirection.x = 0.0f; raydirection.y = 1.0f; raydirection.z = .0f; - rayposition.x = -3.0f; rayposition.y = 0.0f; rayposition.z = 0.0f; - result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); - ok(result == FALSE, "expected FALSE, received TRUE\n"); - - raydirection.x = 1.0f; raydirection.y = 0.0f; raydirection.z = .0f; - rayposition.x = -3.0f; rayposition.y = 0.0f; rayposition.z = 0.0f; - result = D3DXBoxBoundProbe(&bottom_point, &top_point, &rayposition, &raydirection); - ok(result == TRUE, "expected TRUE, received FALSE\n"); - -/*____________Test the Sphere case________________________*/ - radius = sqrt(77.0f); - center.x = 1.0f; center.y = 2.0f; center.z = 3.0f; - raydirection.x = 2.0f; raydirection.y = -4.0f; raydirection.z = 2.0f; - - rayposition.x = 5.0f; rayposition.y = 5.0f; rayposition.z = 9.0f; - result = D3DXSphereBoundProbe(¢er, radius, &rayposition, &raydirection); - ok(result == TRUE, "expected TRUE, received FALSE\n"); - - rayposition.x = 45.0f; rayposition.y = -75.0f; rayposition.z = 49.0f; - result = D3DXSphereBoundProbe(¢er, radius, &rayposition, &raydirection); - ok(result == FALSE, "expected FALSE, received TRUE\n"); - - rayposition.x = 5.0f; rayposition.y = 11.0f; rayposition.z = 9.0f; - result = D3DXSphereBoundProbe(¢er, radius, &rayposition, &raydirection); - ok(result == FALSE, "expected FALSE, received TRUE\n"); -} - -static void D3DXComputeBoundingBoxTest(void) -{ - D3DXVECTOR3 exp_max, exp_min, got_max, got_min, vertex[5]; - HRESULT hr; - - vertex[0].x = 1.0f; vertex[0].y = 1.0f; vertex[0].z = 1.0f; - vertex[1].x = 1.0f; vertex[1].y = 1.0f; vertex[1].z = 1.0f; - vertex[2].x = 1.0f; vertex[2].y = 1.0f; vertex[2].z = 1.0f; - vertex[3].x = 1.0f; vertex[3].y = 1.0f; vertex[3].z = 1.0f; - vertex[4].x = 9.0f; vertex[4].y = 9.0f; vertex[4].z = 9.0f; - - exp_min.x = 1.0f; exp_min.y = 1.0f; exp_min.z = 1.0f; - exp_max.x = 9.0f; exp_max.y = 9.0f; exp_max.z = 9.0f; - - hr = D3DXComputeBoundingBox(&vertex[3],2,D3DXGetFVFVertexSize(D3DFVF_XYZ),&got_min,&got_max); - - ok( hr == D3D_OK, "Expected D3D_OK, got %#x\n", hr); - ok( compare_vec3(exp_min,got_min), "Expected min: (%f, %f, %f), got: (%f, %f, %f)\n", exp_min.x,exp_min.y,exp_min.z,got_min.x,got_min.y,got_min.z); - ok( compare_vec3(exp_max,got_max), "Expected max: (%f, %f, %f), got: (%f, %f, %f)\n", exp_max.x,exp_max.y,exp_max.z,got_max.x,got_max.y,got_max.z); - -/*________________________*/ - - vertex[0].x = 2.0f; vertex[0].y = 5.9f; vertex[0].z = -1.2f; - vertex[1].x = -1.87f; vertex[1].y = 7.9f; vertex[1].z = 7.4f; - vertex[2].x = 7.43f; vertex[2].y = -0.9f; vertex[2].z = 11.9f; - vertex[3].x = -6.92f; vertex[3].y = 6.3f; vertex[3].z = -3.8f; - vertex[4].x = 11.4f; vertex[4].y = -8.1f; vertex[4].z = 4.5f; - - exp_min.x = -6.92f; exp_min.y = -8.1f; exp_min.z = -3.80f; - exp_max.x = 11.4f; exp_max.y = 7.90f; exp_max.z = 11.9f; - - hr = D3DXComputeBoundingBox(&vertex[0],5,D3DXGetFVFVertexSize(D3DFVF_XYZ),&got_min,&got_max); - - ok( hr == D3D_OK, "Expected D3D_OK, got %#x\n", hr); - ok( compare_vec3(exp_min,got_min), "Expected min: (%f, %f, %f), got: (%f, %f, %f)\n", exp_min.x,exp_min.y,exp_min.z,got_min.x,got_min.y,got_min.z); - ok( compare_vec3(exp_max,got_max), "Expected max: (%f, %f, %f), got: (%f, %f, %f)\n", exp_max.x,exp_max.y,exp_max.z,got_max.x,got_max.y,got_max.z); - -/*________________________*/ - - vertex[0].x = 2.0f; vertex[0].y = 5.9f; vertex[0].z = -1.2f; - vertex[1].x = -1.87f; vertex[1].y = 7.9f; vertex[1].z = 7.4f; - vertex[2].x = 7.43f; vertex[2].y = -0.9f; vertex[2].z = 11.9f; - vertex[3].x = -6.92f; vertex[3].y = 6.3f; vertex[3].z = -3.8f; - vertex[4].x = 11.4f; vertex[4].y = -8.1f; vertex[4].z = 4.5f; - - exp_min.x = -6.92f; exp_min.y = -0.9f; exp_min.z = -3.8f; - exp_max.x = 7.43f; exp_max.y = 7.90f; exp_max.z = 11.9f; - - hr = D3DXComputeBoundingBox(&vertex[0],4,D3DXGetFVFVertexSize(D3DFVF_XYZ),&got_min,&got_max); - - ok( hr == D3D_OK, "Expected D3D_OK, got %#x\n", hr); - ok( compare_vec3(exp_min,got_min), "Expected min: (%f, %f, %f), got: (%f, %f, %f)\n", exp_min.x,exp_min.y,exp_min.z,got_min.x,got_min.y,got_min.z); - ok( compare_vec3(exp_max,got_max), "Expected max: (%f, %f, %f), got: (%f, %f, %f)\n", exp_max.x,exp_max.y,exp_max.z,got_max.x,got_max.y,got_max.z); - -/*________________________*/ - hr = D3DXComputeBoundingBox(NULL,5,D3DXGetFVFVertexSize(D3DFVF_XYZ),&got_min,&got_max); - ok( hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); - -/*________________________*/ - hr = D3DXComputeBoundingBox(&vertex[3],5,D3DXGetFVFVertexSize(D3DFVF_XYZ),NULL,&got_max); - ok( hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); - -/*________________________*/ - hr = D3DXComputeBoundingBox(&vertex[3],5,D3DXGetFVFVertexSize(D3DFVF_XYZ),&got_min,NULL); - ok( hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); -} - -static void D3DXComputeBoundingSphereTest(void) -{ - D3DXVECTOR3 exp_cen, got_cen, vertex[5]; - FLOAT exp_rad, got_rad; - HRESULT hr; - - vertex[0].x = 1.0f; vertex[0].y = 1.0f; vertex[0].z = 1.0f; - vertex[1].x = 1.0f; vertex[1].y = 1.0f; vertex[1].z = 1.0f; - vertex[2].x = 1.0f; vertex[2].y = 1.0f; vertex[2].z = 1.0f; - vertex[3].x = 1.0f; vertex[3].y = 1.0f; vertex[3].z = 1.0f; - vertex[4].x = 9.0f; vertex[4].y = 9.0f; vertex[4].z = 9.0f; - - exp_rad = 6.928203f; - exp_cen.x = 5.0; exp_cen.y = 5.0; exp_cen.z = 5.0; - - hr = D3DXComputeBoundingSphere(&vertex[3],2,D3DXGetFVFVertexSize(D3DFVF_XYZ),&got_cen,&got_rad); - - ok( hr == D3D_OK, "Expected D3D_OK, got %#x\n", hr); - ok( compare(exp_rad, got_rad), "Expected radius: %f, got radius: %f\n", exp_rad, got_rad); - ok( compare_vec3(exp_cen,got_cen), "Expected center: (%f, %f, %f), got center: (%f, %f, %f)\n", exp_cen.x,exp_cen.y,exp_cen.z,got_cen.x,got_cen.y,got_cen.z); - -/*________________________*/ - - vertex[0].x = 2.0f; vertex[0].y = 5.9f; vertex[0].z = -1.2f; - vertex[1].x = -1.87f; vertex[1].y = 7.9f; vertex[1].z = 7.4f; - vertex[2].x = 7.43f; vertex[2].y = -0.9f; vertex[2].z = 11.9f; - vertex[3].x = -6.92f; vertex[3].y = 6.3f; vertex[3].z = -3.8f; - vertex[4].x = 11.4f; vertex[4].y = -8.1f; vertex[4].z = 4.5f; - - exp_rad = 13.707883f; - exp_cen.x = 2.408f; exp_cen.y = 2.22f; exp_cen.z = 3.76f; - - hr = D3DXComputeBoundingSphere(&vertex[0],5,D3DXGetFVFVertexSize(D3DFVF_XYZ),&got_cen,&got_rad); - - ok( hr == D3D_OK, "Expected D3D_OK, got %#x\n", hr); - ok( compare(exp_rad, got_rad), "Expected radius: %f, got radius: %f\n", exp_rad, got_rad); - ok( compare_vec3(exp_cen,got_cen), "Expected center: (%f, %f, %f), got center: (%f, %f, %f)\n", exp_cen.x,exp_cen.y,exp_cen.z,got_cen.x,got_cen.y,got_cen.z); - -/*________________________*/ - hr = D3DXComputeBoundingSphere(NULL,5,D3DXGetFVFVertexSize(D3DFVF_XYZ),&got_cen,&got_rad); - ok( hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); - -/*________________________*/ - hr = D3DXComputeBoundingSphere(&vertex[3],5,D3DXGetFVFVertexSize(D3DFVF_XYZ),NULL,&got_rad); - ok( hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); - -/*________________________*/ - hr = D3DXComputeBoundingSphere(&vertex[3],5,D3DXGetFVFVertexSize(D3DFVF_XYZ),&got_cen,NULL); - ok( hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, got %#x\n", hr); -} - -static void D3DXGetFVFVertexSizeTest(void) -{ - UINT got; - - compare_vertex_sizes (D3DFVF_XYZ, 12); - - compare_vertex_sizes (D3DFVF_XYZB3, 24); - - compare_vertex_sizes (D3DFVF_XYZB5, 32); - - compare_vertex_sizes (D3DFVF_XYZ | D3DFVF_NORMAL, 24); - - compare_vertex_sizes (D3DFVF_XYZ | D3DFVF_DIFFUSE, 16); - - compare_vertex_sizes ( - D3DFVF_XYZ | - D3DFVF_TEX1 | - D3DFVF_TEXCOORDSIZE1(0), 16); - compare_vertex_sizes ( - D3DFVF_XYZ | - D3DFVF_TEX2 | - D3DFVF_TEXCOORDSIZE1(0) | - D3DFVF_TEXCOORDSIZE1(1), 20); - - compare_vertex_sizes ( - D3DFVF_XYZ | - D3DFVF_TEX1 | - D3DFVF_TEXCOORDSIZE2(0), 20); - - compare_vertex_sizes ( - D3DFVF_XYZ | - D3DFVF_TEX2 | - D3DFVF_TEXCOORDSIZE2(0) | - D3DFVF_TEXCOORDSIZE2(1), 28); - - compare_vertex_sizes ( - D3DFVF_XYZ | - D3DFVF_TEX6 | - D3DFVF_TEXCOORDSIZE2(0) | - D3DFVF_TEXCOORDSIZE2(1) | - D3DFVF_TEXCOORDSIZE2(2) | - D3DFVF_TEXCOORDSIZE2(3) | - D3DFVF_TEXCOORDSIZE2(4) | - D3DFVF_TEXCOORDSIZE2(5), 60); - - compare_vertex_sizes ( - D3DFVF_XYZ | - D3DFVF_TEX8 | - D3DFVF_TEXCOORDSIZE2(0) | - D3DFVF_TEXCOORDSIZE2(1) | - D3DFVF_TEXCOORDSIZE2(2) | - D3DFVF_TEXCOORDSIZE2(3) | - D3DFVF_TEXCOORDSIZE2(4) | - D3DFVF_TEXCOORDSIZE2(5) | - D3DFVF_TEXCOORDSIZE2(6) | - D3DFVF_TEXCOORDSIZE2(7), 76); - - compare_vertex_sizes ( - D3DFVF_XYZ | - D3DFVF_TEX1 | - D3DFVF_TEXCOORDSIZE3(0), 24); - - compare_vertex_sizes ( - D3DFVF_XYZ | - D3DFVF_TEX4 | - D3DFVF_TEXCOORDSIZE3(0) | - D3DFVF_TEXCOORDSIZE3(1) | - D3DFVF_TEXCOORDSIZE3(2) | - D3DFVF_TEXCOORDSIZE3(3), 60); - - compare_vertex_sizes ( - D3DFVF_XYZ | - D3DFVF_TEX1 | - D3DFVF_TEXCOORDSIZE4(0), 28); - - compare_vertex_sizes ( - D3DFVF_XYZ | - D3DFVF_TEX2 | - D3DFVF_TEXCOORDSIZE4(0) | - D3DFVF_TEXCOORDSIZE4(1), 44); - - compare_vertex_sizes ( - D3DFVF_XYZ | - D3DFVF_TEX3 | - D3DFVF_TEXCOORDSIZE4(0) | - D3DFVF_TEXCOORDSIZE4(1) | - D3DFVF_TEXCOORDSIZE4(2), 60); - - compare_vertex_sizes ( - D3DFVF_XYZB5 | - D3DFVF_NORMAL | - D3DFVF_DIFFUSE | - D3DFVF_SPECULAR | - D3DFVF_TEX8 | - D3DFVF_TEXCOORDSIZE4(0) | - D3DFVF_TEXCOORDSIZE4(1) | - D3DFVF_TEXCOORDSIZE4(2) | - D3DFVF_TEXCOORDSIZE4(3) | - D3DFVF_TEXCOORDSIZE4(4) | - D3DFVF_TEXCOORDSIZE4(5) | - D3DFVF_TEXCOORDSIZE4(6) | - D3DFVF_TEXCOORDSIZE4(7), 180); -} - -static void D3DXIntersectTriTest(void) -{ - BOOL exp_res, got_res; - D3DXVECTOR3 position, ray, vertex[3]; - FLOAT exp_dist, got_dist, exp_u, got_u, exp_v, got_v; - - vertex[0].x = 1.0f; vertex[0].y = 0.0f; vertex[0].z = 0.0f; - vertex[1].x = 2.0f; vertex[1].y = 0.0f; vertex[1].z = 0.0f; - vertex[2].x = 1.0f; vertex[2].y = 1.0f; vertex[2].z = 0.0f; - - position.x = -14.5f; position.y = -23.75f; position.z = -32.0f; - - ray.x = 2.0f; ray.y = 3.0f; ray.z = 4.0f; - - exp_res = TRUE; exp_u = 0.5f; exp_v = 0.25f; exp_dist = 8.0f; - - got_res = D3DXIntersectTri(&vertex[0],&vertex[1],&vertex[2],&position,&ray,&got_u,&got_v,&got_dist); - ok( got_res == exp_res, "Expected result = %d, got %d\n",exp_res,got_res); - ok( compare(exp_u,got_u), "Expected u = %f, got %f\n",exp_u,got_u); - ok( compare(exp_v,got_v), "Expected v = %f, got %f\n",exp_v,got_v); - ok( compare(exp_dist,got_dist), "Expected distance = %f, got %f\n",exp_dist,got_dist); - -/*Only positive ray is taken in account*/ - - vertex[0].x = 1.0f; vertex[0].y = 0.0f; vertex[0].z = 0.0f; - vertex[1].x = 2.0f; vertex[1].y = 0.0f; vertex[1].z = 0.0f; - vertex[2].x = 1.0f; vertex[2].y = 1.0f; vertex[2].z = 0.0f; - - position.x = 17.5f; position.y = 24.25f; position.z = 32.0f; - - ray.x = 2.0f; ray.y = 3.0f; ray.z = 4.0f; - - exp_res = FALSE; - - got_res = D3DXIntersectTri(&vertex[0],&vertex[1],&vertex[2],&position,&ray,&got_u,&got_v,&got_dist); - ok( got_res == exp_res, "Expected result = %d, got %d\n",exp_res,got_res); - -/*Intersection between ray and triangle in a same plane is considered as empty*/ - - vertex[0].x = 4.0f; vertex[0].y = 0.0f; vertex[0].z = 0.0f; - vertex[1].x = 6.0f; vertex[1].y = 0.0f; vertex[1].z = 0.0f; - vertex[2].x = 4.0f; vertex[2].y = 2.0f; vertex[2].z = 0.0f; - - position.x = 1.0f; position.y = 1.0f; position.z = 0.0f; - - ray.x = 1.0f; ray.y = 0.0f; ray.z = 0.0f; - - exp_res = FALSE; - - got_res = D3DXIntersectTri(&vertex[0],&vertex[1],&vertex[2],&position,&ray,&got_u,&got_v,&got_dist); - ok( got_res == exp_res, "Expected result = %d, got %d\n",exp_res,got_res); -} - -static void test_get_decl_vertex_size(void) -{ - static const D3DVERTEXELEMENT9 declaration1[] = - { - {0, 0, D3DDECLTYPE_FLOAT1, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {1, 0, D3DDECLTYPE_FLOAT2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {2, 0, D3DDECLTYPE_FLOAT3, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {3, 0, D3DDECLTYPE_FLOAT4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {4, 0, D3DDECLTYPE_D3DCOLOR, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {5, 0, D3DDECLTYPE_UBYTE4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {6, 0, D3DDECLTYPE_SHORT2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {7, 0, D3DDECLTYPE_SHORT4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {8, 0, D3DDECLTYPE_UBYTE4N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {9, 0, D3DDECLTYPE_SHORT2N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {10, 0, D3DDECLTYPE_SHORT4N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {11, 0, D3DDECLTYPE_UDEC3, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {12, 0, D3DDECLTYPE_DEC3N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {13, 0, D3DDECLTYPE_FLOAT16_2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {14, 0, D3DDECLTYPE_FLOAT16_4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - D3DDECL_END(), - }; - static const D3DVERTEXELEMENT9 declaration2[] = - { - {0, 8, D3DDECLTYPE_FLOAT1, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {1, 8, D3DDECLTYPE_FLOAT2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {2, 8, D3DDECLTYPE_FLOAT3, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {3, 8, D3DDECLTYPE_FLOAT4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {4, 8, D3DDECLTYPE_D3DCOLOR, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {5, 8, D3DDECLTYPE_UBYTE4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {6, 8, D3DDECLTYPE_SHORT2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {7, 8, D3DDECLTYPE_SHORT4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {0, 8, D3DDECLTYPE_UBYTE4N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {1, 8, D3DDECLTYPE_SHORT2N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {2, 8, D3DDECLTYPE_SHORT4N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {3, 8, D3DDECLTYPE_UDEC3, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {4, 8, D3DDECLTYPE_DEC3N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {5, 8, D3DDECLTYPE_FLOAT16_2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {6, 8, D3DDECLTYPE_FLOAT16_4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - {7, 8, D3DDECLTYPE_FLOAT1, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, - D3DDECL_END(), - }; - static const UINT sizes1[] = - { - 4, 8, 12, 16, - 4, 4, 4, 8, - 4, 4, 8, 4, - 4, 4, 8, 0, - }; - static const UINT sizes2[] = - { - 12, 16, 20, 24, - 12, 12, 16, 16, - }; - unsigned int i; - UINT size; - - size = D3DXGetDeclVertexSize(NULL, 0); - ok(size == 0, "Got size %#x, expected 0.\n", size); - - for (i = 0; i < 16; ++i) - { - size = D3DXGetDeclVertexSize(declaration1, i); - ok(size == sizes1[i], "Got size %u for stream %u, expected %u.\n", size, i, sizes1[i]); - } - - for (i = 0; i < 8; ++i) - { - size = D3DXGetDeclVertexSize(declaration2, i); - ok(size == sizes2[i], "Got size %u for stream %u, expected %u.\n", size, i, sizes2[i]); - } -} - -START_TEST(mesh) -{ - D3DXBoundProbeTest(); - D3DXComputeBoundingBoxTest(); - D3DXComputeBoundingSphereTest(); - D3DXGetFVFVertexSizeTest(); - D3DXIntersectTriTest(); - test_get_decl_vertex_size(); -} +/* + * Copyright 2009 Henri Verbeet for CodeWeavers + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "wine/test.h" +#include "d3dx9.h" + +static void test_get_decl_vertex_size(void) +{ + static const D3DVERTEXELEMENT9 declaration1[] = + { + {0, 0, D3DDECLTYPE_FLOAT1, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {1, 0, D3DDECLTYPE_FLOAT2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {2, 0, D3DDECLTYPE_FLOAT3, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {3, 0, D3DDECLTYPE_FLOAT4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {4, 0, D3DDECLTYPE_D3DCOLOR, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {5, 0, D3DDECLTYPE_UBYTE4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {6, 0, D3DDECLTYPE_SHORT2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {7, 0, D3DDECLTYPE_SHORT4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {8, 0, D3DDECLTYPE_UBYTE4N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {9, 0, D3DDECLTYPE_SHORT2N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {10, 0, D3DDECLTYPE_SHORT4N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {11, 0, D3DDECLTYPE_UDEC3, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {12, 0, D3DDECLTYPE_DEC3N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {13, 0, D3DDECLTYPE_FLOAT16_2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {14, 0, D3DDECLTYPE_FLOAT16_4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + D3DDECL_END(), + }; + static const D3DVERTEXELEMENT9 declaration2[] = + { + {0, 8, D3DDECLTYPE_FLOAT1, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {1, 8, D3DDECLTYPE_FLOAT2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {2, 8, D3DDECLTYPE_FLOAT3, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {3, 8, D3DDECLTYPE_FLOAT4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {4, 8, D3DDECLTYPE_D3DCOLOR, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {5, 8, D3DDECLTYPE_UBYTE4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {6, 8, D3DDECLTYPE_SHORT2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {7, 8, D3DDECLTYPE_SHORT4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {0, 8, D3DDECLTYPE_UBYTE4N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {1, 8, D3DDECLTYPE_SHORT2N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {2, 8, D3DDECLTYPE_SHORT4N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {3, 8, D3DDECLTYPE_UDEC3, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {4, 8, D3DDECLTYPE_DEC3N, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {5, 8, D3DDECLTYPE_FLOAT16_2, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {6, 8, D3DDECLTYPE_FLOAT16_4, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + {7, 8, D3DDECLTYPE_FLOAT1, D3DDECLMETHOD_DEFAULT, D3DDECLUSAGE_POSITION, 0}, + D3DDECL_END(), + }; + static const UINT sizes1[] = + { + 4, 8, 12, 16, + 4, 4, 4, 8, + 4, 4, 8, 4, + 4, 4, 8, 0, + }; + static const UINT sizes2[] = + { + 12, 16, 20, 24, + 12, 12, 16, 16, + }; + unsigned int i; + UINT size; + + size = D3DXGetDeclVertexSize(NULL, 0); + ok(size == 0, "Got size %#x, expected 0.\n", size); + + for (i = 0; i < 16; ++i) + { + size = D3DXGetDeclVertexSize(declaration1, i); + ok(size == sizes1[i], "Got size %u for stream %u, expected %u.\n", size, i, sizes1[i]); + } + + for (i = 0; i < 8; ++i) + { + size = D3DXGetDeclVertexSize(declaration2, i); + ok(size == sizes2[i], "Got size %u for stream %u, expected %u.\n", size, i, sizes2[i]); + } +} + +START_TEST(mesh) +{ + test_get_decl_vertex_size(); +} diff --git a/dlls/d3dx9_36/tests/texture.c b/dlls/d3dx9_36/tests/texture.c index 7f10e2d09f6..4d7c9dcc527 100644 --- a/dlls/d3dx9_36/tests/texture.c +++ b/dlls/d3dx9_36/tests/texture.c @@ -18,29 +18,10 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#define COBJMACROS #include "wine/test.h" #include "d3dx9tex.h" #include "resources.h" -static inline int get_ref(IUnknown *obj) -{ - IUnknown_AddRef(obj); - return IUnknown_Release(obj); -} - -static inline void check_ref(IUnknown *obj, int exp) -{ - int ref = get_ref(obj); - ok (exp == ref, "Invalid refcount. Expected %d, got %d\n", exp, ref); -} - -static inline void check_release(IUnknown *obj, int exp) -{ - int ref = IUnknown_Release(obj); - ok (ref == exp, "Invalid refcount. Expected %d, got %d\n", exp, ref); -} - /* 1x1 bmp (1 bpp) */ static const unsigned char bmp01[66] = { 0x42,0x4d,0x42,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3e,0x00,0x00,0x00,0x28,0x00, @@ -50,11 +31,6 @@ static const unsigned char bmp01[66] = { 0x00,0x00 }; -/* 2x2 A8R8G8B8 pixel data */ -static const unsigned char pixdata[] = { -0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff -}; - /* invalid image file */ static const unsigned char noimage[4] = { 0x11,0x22,0x33,0x44 @@ -62,20 +38,15 @@ static const unsigned char noimage[4] = { static HRESULT create_file(const char *filename, const unsigned char *data, const unsigned int size) { - DWORD received; HANDLE hfile; - hfile = CreateFileA(filename, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, 0); + hfile = CreateFileA(filename, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, 0, NULL); if(hfile == INVALID_HANDLE_VALUE) return HRESULT_FROM_WIN32(GetLastError()); - if(WriteFile(hfile, data, size, &received, NULL)) - { - CloseHandle(hfile); - return D3D_OK; - } - + WriteFile(hfile, data, size, NULL, NULL); CloseHandle(hfile); - return D3DERR_INVALIDCALL; + + return D3D_OK; } static void test_D3DXGetImageInfo() @@ -210,179 +181,7 @@ static void test_D3DXGetImageInfo() if(testbitmap_ok) DeleteFileA("testbitmap.bmp"); } -static void test_D3DXLoadSurface(IDirect3DDevice9 *device) -{ - HRESULT hr; - BOOL testdummy_ok, testbitmap_ok; - IDirect3DSurface9 *surf, *newsurf; - RECT rect; - - hr = create_file("testdummy.bmp", noimage, sizeof(noimage)); /* invalid image */ - testdummy_ok = SUCCEEDED(hr); - - hr = create_file("testbitmap.bmp", bmp01, sizeof(bmp01)); /* valid image */ - testbitmap_ok = SUCCEEDED(hr); - - hr = IDirect3DDevice9_CreateOffscreenPlainSurface(device, 256, 256, D3DFMT_A8R8G8B8, D3DPOOL_DEFAULT, &surf, NULL); - if(FAILED(hr)) { - skip("Failed to create a surface (%#x)\n", hr); - if(testdummy_ok) DeleteFileA("testdummy.bmp"); - if(testbitmap_ok) DeleteFileA("testbitmap.bmp"); - return; - } - - /* D3DXLoadSurfaceFromFile */ - if(testbitmap_ok) { - todo_wine { - hr = D3DXLoadSurfaceFromFileA(surf, NULL, NULL, "testbitmap.bmp", NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3D_OK, "D3DXLoadSurfaceFromFile returned %#x, expected %#x\n", hr, D3D_OK); - } - - hr = D3DXLoadSurfaceFromFileA(NULL, NULL, NULL, "testbitmap.bmp", NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromFile returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - } else skip("Couldn't create \"testbitmap.bmp\"\n"); - - if(testdummy_ok) { - todo_wine { - hr = D3DXLoadSurfaceFromFileA(surf, NULL, NULL, "testdummy.bmp", NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3DXERR_INVALIDDATA, "D3DXLoadSurfaceFromFile returned %#x, expected %#x\n", hr, D3DXERR_INVALIDDATA); - } - } else skip("Couldn't create \"testdummy.bmp\"\n"); - - hr = D3DXLoadSurfaceFromFileA(surf, NULL, NULL, NULL, NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromFile returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXLoadSurfaceFromFileA(surf, NULL, NULL, "", NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3DXERR_INVALIDDATA, "D3DXLoadSurfaceFromFile returned %#x, expected %#x\n", hr, D3DXERR_INVALIDDATA); - - - /* D3DXLoadSurfaceFromResource */ - todo_wine { - hr = D3DXLoadSurfaceFromResourceA(surf, NULL, NULL, NULL, MAKEINTRESOURCE(IDB_BITMAP_1x1), NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3D_OK, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3D_OK); - - hr = D3DXLoadSurfaceFromResourceA(surf, NULL, NULL, NULL, MAKEINTRESOURCE(IDD_BITMAPDATA_1x1), NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3D_OK, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3D_OK); - } - - hr = D3DXLoadSurfaceFromResourceA(surf, NULL, NULL, NULL, NULL, NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3DXERR_INVALIDDATA, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3DXERR_INVALIDDATA); - - hr = D3DXLoadSurfaceFromResourceA(NULL, NULL, NULL, NULL, MAKEINTRESOURCE(IDB_BITMAP_1x1), NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXLoadSurfaceFromResourceA(surf, NULL, NULL, NULL, MAKEINTRESOURCE(IDS_STRING), NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3DXERR_INVALIDDATA, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3DXERR_INVALIDDATA); - - - /* D3DXLoadSurfaceFromFileInMemory */ - todo_wine { - hr = D3DXLoadSurfaceFromFileInMemory(surf, NULL, NULL, bmp01, sizeof(bmp01), NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3D_OK, "D3DXLoadSurfaceFromFileInMemory returned %#x, expected %#x\n", hr, D3D_OK); - - hr = D3DXLoadSurfaceFromFileInMemory(surf, NULL, NULL, noimage, sizeof(noimage), NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3DXERR_INVALIDDATA, "D3DXLoadSurfaceFromFileInMemory returned %#x, expected %#x\n", hr, D3DXERR_INVALIDDATA); - } - - hr = D3DXLoadSurfaceFromFileInMemory(surf, NULL, NULL, bmp01, 0, NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromFileInMemory returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXLoadSurfaceFromFileInMemory(NULL, NULL, NULL, bmp01, sizeof(bmp01), NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromFileInMemory returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXLoadSurfaceFromFileInMemory(surf, NULL, NULL, NULL, 8, NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromFileInMemory returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXLoadSurfaceFromFileInMemory(surf, NULL, NULL, NULL, 0, NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromFileInMemory returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXLoadSurfaceFromFileInMemory(NULL, NULL, NULL, NULL, 0, NULL, D3DX_DEFAULT, 0, NULL); - ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromFileInMemory returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - - /* D3DXLoadSurfaceFromMemory */ - SetRect(&rect, 0, 0, 2, 2); - - todo_wine { - hr = D3DXLoadSurfaceFromMemory(surf, NULL, NULL, pixdata, D3DFMT_A8R8G8B8, sizeof(pixdata), NULL, &rect, D3DX_DEFAULT, 0); - ok(hr == D3D_OK, "D3DXLoadSurfaceFromMemory returned %#x, expected %#x\n", hr, D3D_OK); - - hr = D3DXLoadSurfaceFromMemory(surf, NULL, NULL, pixdata, D3DFMT_A8R8G8B8, 0, NULL, &rect, D3DX_DEFAULT, 0); - ok(hr == D3D_OK, "D3DXLoadSurfaceFromMemory returned %#x, expected %#x\n", hr, D3D_OK); - } - - hr = D3DXLoadSurfaceFromMemory(surf, NULL, NULL, NULL, D3DFMT_A8R8G8B8, sizeof(pixdata), NULL, &rect, D3DX_DEFAULT, 0); - ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromMemory returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXLoadSurfaceFromMemory(NULL, NULL, NULL, pixdata, D3DFMT_A8R8G8B8, sizeof(pixdata), NULL, &rect, D3DX_DEFAULT, 0); - ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromMemory returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXLoadSurfaceFromMemory(surf, NULL, NULL, pixdata, D3DFMT_A8R8G8B8, sizeof(pixdata), NULL, NULL, D3DX_DEFAULT, 0); - ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromMemory returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXLoadSurfaceFromMemory(surf, NULL, NULL, pixdata, D3DFMT_UNKNOWN, sizeof(pixdata), NULL, &rect, D3DX_DEFAULT, 0); - ok(hr == E_FAIL, "D3DXLoadSurfaceFromMemory returned %#x, expected %#x\n", hr, E_FAIL); - - - /* D3DXLoadSurfaceFromSurface */ - hr = IDirect3DDevice9_CreateOffscreenPlainSurface(device, 256, 256, D3DFMT_A8R8G8B8, D3DPOOL_DEFAULT, &newsurf, NULL); - if(SUCCEEDED(hr)) { - todo_wine { - hr = D3DXLoadSurfaceFromSurface(newsurf, NULL, NULL, surf, NULL, NULL, D3DX_DEFAULT, 0); - ok(hr == D3D_OK, "D3DXLoadSurfaceFromSurface returned %#x, expected %#x\n", hr, D3D_OK); - } - - hr = D3DXLoadSurfaceFromSurface(NULL, NULL, NULL, surf, NULL, NULL, D3DX_DEFAULT, 0); - ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromSurface returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - - hr = D3DXLoadSurfaceFromSurface(newsurf, NULL, NULL, NULL, NULL, NULL, D3DX_DEFAULT, 0); - ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromSurface returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); - } else skip("Failed to create a second surface\n"); - check_release((IUnknown*)newsurf, 0); - - - /* cleanup */ - check_release((IUnknown*)surf, 0); - - if(testdummy_ok) DeleteFileA("testdummy.bmp"); - if(testbitmap_ok) DeleteFileA("testbitmap.bmp"); -} - START_TEST(texture) { - HWND wnd; - IDirect3D9 *d3d; - IDirect3DDevice9 *device; - D3DPRESENT_PARAMETERS d3dpp; - HRESULT hr; - - wnd = CreateWindow("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL); - d3d = Direct3DCreate9(D3D_SDK_VERSION); - if (!wnd) { - skip("Couldn't create application window\n"); - return; - } - if (!d3d) { - skip("Couldn't create IDirect3D9 object\n"); - DestroyWindow(wnd); - return; - } - - ZeroMemory(&d3dpp, sizeof(d3dpp)); - d3dpp.Windowed = TRUE; - d3dpp.SwapEffect = D3DSWAPEFFECT_DISCARD; - hr = IDirect3D9_CreateDevice(d3d, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, wnd, D3DCREATE_MIXED_VERTEXPROCESSING, &d3dpp, &device); - if(FAILED(hr)) { - skip("Failed to create IDirect3DDevice9 object %#x\n", hr); - IDirect3D9_Release(d3d); - DestroyWindow(wnd); - return; - } - test_D3DXGetImageInfo(); - test_D3DXLoadSurface(device); - - check_release((IUnknown*)device, 0); - check_release((IUnknown*)d3d, 0); - if (wnd) DestroyWindow(wnd); } diff --git a/dlls/d3dxof/Makefile.in b/dlls/d3dxof/Makefile.in index 9ea555585e8..d3566dda917 100644 --- a/dlls/d3dxof/Makefile.in +++ b/dlls/d3dxof/Makefile.in @@ -7,8 +7,8 @@ IMPORTLIB = d3dxof IMPORTS = dxguid uuid ole32 advapi32 kernel32 C_SRCS = \ - d3dxof.c \ main.c \ + d3dxof.c \ parsing.c \ regsvr.c diff --git a/dlls/dbghelp/coff.c b/dlls/dbghelp/coff.c index 8a01ced6863..ef8632b0f09 100644 --- a/dlls/dbghelp/coff.c +++ b/dlls/dbghelp/coff.c @@ -108,18 +108,12 @@ static int coff_add_file(struct CoffFileSet* coff_files, struct module* module, if (coff_files->nfiles + 1 >= coff_files->nfiles_alloc) { - if (coff_files->files) - { - coff_files->nfiles_alloc *= 2; - coff_files->files = HeapReAlloc(GetProcessHeap(), 0, coff_files->files, - coff_files->nfiles_alloc * sizeof(struct CoffFile)); - } - else - { - coff_files->nfiles_alloc = 16; - coff_files->files = HeapAlloc(GetProcessHeap(), 0, - coff_files->nfiles_alloc * sizeof(struct CoffFile)); - } + coff_files->nfiles_alloc += 10; + coff_files->files = (coff_files->files) ? + HeapReAlloc(GetProcessHeap(), 0, coff_files->files, + coff_files->nfiles_alloc * sizeof(struct CoffFile)) : + HeapAlloc(GetProcessHeap(), 0, + coff_files->nfiles_alloc * sizeof(struct CoffFile)); } file = coff_files->files + coff_files->nfiles; file->startaddr = 0xffffffff; @@ -138,7 +132,7 @@ static void coff_add_symbol(struct CoffFile* coff_file, struct symt* sym) { if (coff_file->neps + 1 >= coff_file->neps_alloc) { - coff_file->neps_alloc *= 2; + coff_file->neps_alloc += 10; coff_file->entries = (coff_file->entries) ? HeapReAlloc(GetProcessHeap(), 0, coff_file->entries, coff_file->neps_alloc * sizeof(struct symt*)) : diff --git a/dlls/dbghelp/dbghelp_private.h b/dlls/dbghelp/dbghelp_private.h index 0a014095b84..9f8a612c374 100644 --- a/dlls/dbghelp/dbghelp_private.h +++ b/dlls/dbghelp/dbghelp_private.h @@ -337,8 +337,6 @@ struct module /* symbols & symbol tables */ int sortlist_valid; unsigned num_sorttab; /* number of symbols with addresses */ - unsigned num_symbols; - unsigned sorttab_size; struct symt_ht** addr_sorttab; struct hash_table ht_symbols; void (*loc_compute)(struct process* pcs, @@ -559,7 +557,7 @@ extern struct symt_function* unsigned long addr, unsigned long size, struct symt* type); extern BOOL symt_normalize_function(struct module* module, - const struct symt_function* func); + struct symt_function* func); extern void symt_add_func_line(struct module* module, struct symt_function* func, unsigned source_idx, int line_num, @@ -577,7 +575,7 @@ extern struct symt_block* unsigned pc, unsigned len); extern struct symt_block* symt_close_func_block(struct module* module, - const struct symt_function* func, + struct symt_function* func, struct symt_block* block, unsigned pc); extern struct symt_hierarchy_point* symt_add_function_point(struct module* module, diff --git a/dlls/dbghelp/dwarf.c b/dlls/dbghelp/dwarf.c index 7843e679330..82e836f2963 100644 --- a/dlls/dbghelp/dwarf.c +++ b/dlls/dbghelp/dwarf.c @@ -781,9 +781,7 @@ compute_location(dwarf2_traverse_context_t* ctx, struct location* loc, } break; default: - if (op < DW_OP_lo_user) /* as DW_OP_hi_user is 0xFF, we don't need to test against it */ - FIXME("Unhandled attr op: %x\n", op); - /* FIXME else unhandled extension */ + FIXME("Unhandled attr op: %x\n", op); return loc_err_internal; } } diff --git a/dlls/dbghelp/dwarf.h b/dlls/dbghelp/dwarf.h index a590df2c9f0..e7a0a7e4824 100644 --- a/dlls/dbghelp/dwarf.h +++ b/dlls/dbghelp/dwarf.h @@ -376,18 +376,6 @@ typedef enum dwarf_operation_e DW_OP_call2 = 0x98, DW_OP_call4 = 0x99, DW_OP_call_ref = 0x9a, - DW_OP_form_tls_address = 0x9b, - DW_OP_call_frame_cfa = 0x9c, - DW_OP_bit_piece = 0x9d, - - /* Implementation defined extensions */ - DW_OP_lo_user = 0xe0, - DW_OP_hi_user = 0xff, - - /* GNU extensions */ - DW_OP_GNU_push_tls_address = 0xe0, - DW_OP_GNU_uninit = 0xf0, - DW_OP_GNU_encoded_addr = 0xf1, } dwarf_operation_t; enum dwarf_calling_convention diff --git a/dlls/dbghelp/elf_module.c b/dlls/dbghelp/elf_module.c index 6c79c8b690a..b6727887937 100644 --- a/dlls/dbghelp/elf_module.c +++ b/dlls/dbghelp/elf_module.c @@ -237,7 +237,7 @@ static void elf_end_find(struct elf_file_map* fmap) * * Get the size of an ELF section */ -static inline unsigned elf_get_map_size(const struct elf_section_map* esm) +static inline unsigned elf_get_map_size(struct elf_section_map* esm) { if (esm->sidx < 0 || esm->sidx >= esm->fmap->elfhdr.e_shnum) return 0; @@ -473,7 +473,7 @@ static void elf_hash_symtab(struct module* module, struct pool* pool, */ static const Elf32_Sym* elf_lookup_symtab(const struct module* module, const struct hash_table* ht_symtab, - const char* name, const struct symt* compiland) + const char* name, struct symt* compiland) { struct symtab_elt* weak_result = NULL; /* without compiland name */ struct symtab_elt* result = NULL; @@ -490,7 +490,7 @@ static const Elf32_Sym* elf_lookup_symtab(const struct module* module, if (compiland) { compiland_name = source_get(module, - ((const struct symt_compiland*)compiland)->source); + ((struct symt_compiland*)compiland)->source); compiland_basename = strrchr(compiland_name, '/'); if (!compiland_basename++) compiland_basename = compiland_name; } @@ -542,7 +542,7 @@ static const Elf32_Sym* elf_lookup_symtab(const struct module* module, * - get any relevant information (address & size) from the bits we got from the * stabs debugging information */ -static void elf_finish_stabs_info(struct module* module, const struct hash_table* symtab) +static void elf_finish_stabs_info(struct module* module, struct hash_table* symtab) { struct hash_table_iter hti; void* ptr; @@ -623,7 +623,7 @@ static void elf_finish_stabs_info(struct module* module, const struct hash_table * * creating the thunk objects for a wine native DLL */ -static int elf_new_wine_thunks(struct module* module, const struct hash_table* ht_symtab, +static int elf_new_wine_thunks(struct module* module, struct hash_table* ht_symtab, const struct elf_thunk_area* thunks) { int j; @@ -650,8 +650,8 @@ static int elf_new_wine_thunks(struct module* module, const struct hash_table* h ULONG64 ref_addr; symt = symt_find_nearest(module, addr); - if (symt && !symt_get_info(&symt->symt, TI_GET_ADDRESS, &ref_addr)) - ref_addr = addr; + if (symt) + symt_get_info(&symt->symt, TI_GET_ADDRESS, &ref_addr); if (!symt || addr != ref_addr) { /* creating public symbols for all the ELF symbols which haven't been @@ -716,7 +716,7 @@ static int elf_new_wine_thunks(struct module* module, const struct hash_table* h * * Creates a set of public symbols from an ELF symtab */ -static int elf_new_public_symbols(struct module* module, const struct hash_table* symtab) +static int elf_new_public_symbols(struct module* module, struct hash_table* symtab) { struct hash_table_iter hti; struct symtab_elt* ste; @@ -830,7 +830,7 @@ found: * Parses a .gnu_debuglink section and loads the debug info from * the external file specified there. */ -static BOOL elf_debuglink_parse(struct elf_file_map* fmap, const struct module* module, +static BOOL elf_debuglink_parse(struct elf_file_map* fmap, struct module* module, const BYTE* debuglink) { /* The content of a debug link section is: diff --git a/dlls/dbghelp/macho_module.c b/dlls/dbghelp/macho_module.c index 4210d1f914e..c0458c60bb2 100644 --- a/dlls/dbghelp/macho_module.c +++ b/dlls/dbghelp/macho_module.c @@ -390,7 +390,9 @@ static int macho_accum_segs_range(struct macho_file_map* fmap, TRACE("Segment command vm: 0x%08x - 0x%08x\n", (unsigned)sc->vmaddr, (unsigned)sc->vmaddr + sc->vmsize); - if (!strncmp(sc->segname, "WINE_", 5)) + if (!strncmp(sc->segname, "WINE_DOS", sizeof(sc->segname)) || + !strncmp(sc->segname, "WINE_OLE32", sizeof(sc->segname)) || + !strncmp(sc->segname, "WINE_SHARED_HEAP", sizeof(sc->segname))) { TRACE("Ignoring special Wine segment %s\n", debugstr_an(sc->segname, sizeof(sc->segname))); return 0; diff --git a/dlls/dbghelp/minidump.c b/dlls/dbghelp/minidump.c index 4108ef43784..6bc8070c67b 100644 --- a/dlls/dbghelp/minidump.c +++ b/dlls/dbghelp/minidump.c @@ -59,7 +59,6 @@ struct dump_context /* module information */ struct dump_module* modules; unsigned num_modules; - unsigned alloc_modules; /* exception information */ /* output information */ MINIDUMP_TYPE type; @@ -67,7 +66,6 @@ struct dump_context RVA rva; struct dump_memory* mem; unsigned num_mem; - unsigned alloc_mem; /* callback information */ MINIDUMP_CALLBACK_INFORMATION* cb; }; @@ -255,34 +253,23 @@ static BOOL add_module(struct dump_context* dc, const WCHAR* name, BOOL is_elf) { if (!dc->modules) - { - dc->alloc_modules = 32; dc->modules = HeapAlloc(GetProcessHeap(), 0, - dc->alloc_modules * sizeof(*dc->modules)); - } + ++dc->num_modules * sizeof(*dc->modules)); else - { - dc->alloc_modules *= 2; dc->modules = HeapReAlloc(GetProcessHeap(), 0, dc->modules, - dc->alloc_modules * sizeof(*dc->modules)); - } - if (!dc->modules) - { - dc->alloc_modules = dc->num_modules = 0; - return FALSE; - } + ++dc->num_modules * sizeof(*dc->modules)); + if (!dc->modules) return FALSE; if (is_elf || !GetModuleFileNameExW(dc->hProcess, (HMODULE)base, - dc->modules[dc->num_modules].name, - sizeof(dc->modules[dc->num_modules].name) / sizeof(WCHAR))) - lstrcpynW(dc->modules[dc->num_modules].name, name, - sizeof(dc->modules[dc->num_modules].name) / sizeof(WCHAR)); - dc->modules[dc->num_modules].base = base; - dc->modules[dc->num_modules].size = size; - dc->modules[dc->num_modules].timestamp = timestamp; - dc->modules[dc->num_modules].checksum = checksum; - dc->modules[dc->num_modules].is_elf = is_elf; - dc->num_modules++; + dc->modules[dc->num_modules - 1].name, + sizeof(dc->modules[dc->num_modules - 1].name) / sizeof(WCHAR))) + lstrcpynW(dc->modules[dc->num_modules - 1].name, name, + sizeof(dc->modules[dc->num_modules - 1].name) / sizeof(WCHAR)); + dc->modules[dc->num_modules - 1].base = base; + dc->modules[dc->num_modules - 1].size = size; + dc->modules[dc->num_modules - 1].timestamp = timestamp; + dc->modules[dc->num_modules - 1].checksum = checksum; + dc->modules[dc->num_modules - 1].is_elf = is_elf; return TRUE; } @@ -395,24 +382,17 @@ static void fetch_module_versioninfo(LPCWSTR filename, VS_FIXEDFILEINFO* ffi) static void add_memory_block(struct dump_context* dc, ULONG64 base, ULONG size, ULONG rva) { if (dc->mem) - { - dc->alloc_mem *= 2; - dc->mem = HeapReAlloc(GetProcessHeap(), 0, dc->mem, - dc->alloc_mem * sizeof(*dc->mem)); - } + dc->mem = HeapReAlloc(GetProcessHeap(), 0, dc->mem, + ++dc->num_mem * sizeof(*dc->mem)); else - { - dc->alloc_mem = 32; - dc->mem = HeapAlloc(GetProcessHeap(), 0, dc->alloc_mem * sizeof(*dc->mem)); - } + dc->mem = HeapAlloc(GetProcessHeap(), 0, ++dc->num_mem * sizeof(*dc->mem)); if (dc->mem) { - dc->mem[dc->num_mem].base = base; - dc->mem[dc->num_mem].size = size; - dc->mem[dc->num_mem].rva = rva; - dc->num_mem++; + dc->mem[dc->num_mem - 1].base = base; + dc->mem[dc->num_mem - 1].size = size; + dc->mem[dc->num_mem - 1].rva = rva; } - else dc->num_mem = dc->alloc_mem = 0; + else dc->num_mem = 0; } /****************************************************************** @@ -434,7 +414,7 @@ static void writeat(struct dump_context* dc, RVA rva, const void* data, unsigned * writes a new chunk of data to the minidump, increasing the current * rva in dc */ -static void append(struct dump_context* dc, const void* data, unsigned size) +static void append(struct dump_context* dc, void* data, unsigned size) { writeat(dc, dc->rva, data, size); dc->rva += size; @@ -887,12 +867,10 @@ BOOL WINAPI MiniDumpWriteDump(HANDLE hProcess, DWORD pid, HANDLE hFile, dc.pid = pid; dc.modules = NULL; dc.num_modules = 0; - dc.alloc_modules = 0; dc.cb = CallbackParam; dc.type = DumpType; dc.mem = NULL; dc.num_mem = 0; - dc.alloc_mem = 0; dc.rva = 0; if (!fetch_processes_info(&dc)) return FALSE; diff --git a/dlls/dbghelp/module.c b/dlls/dbghelp/module.c index 6199b5827ce..1a3d94e316d 100644 --- a/dlls/dbghelp/module.c +++ b/dlls/dbghelp/module.c @@ -168,10 +168,7 @@ struct module* module_new(struct process* pcs, const WCHAR* name, module->type = type; module->is_virtual = virtual ? TRUE : FALSE; module->sortlist_valid = FALSE; - module->sorttab_size = 0; module->addr_sorttab = NULL; - module->num_sorttab = 0; - module->num_symbols = 0; /* FIXME: this seems a bit too high (on a per module basis) * need some statistics about this */ @@ -1038,9 +1035,7 @@ DWORD64 WINAPI SymGetModuleBase64(HANDLE hProcess, DWORD64 dwAddr) void module_reset_debug_info(struct module* module) { module->sortlist_valid = TRUE; - module->sorttab_size = 0; module->addr_sorttab = NULL; - module->num_sorttab = module->num_symbols = 0; hash_table_destroy(&module->ht_symbols); module->ht_symbols.num_buckets = 0; module->ht_symbols.buckets = NULL; diff --git a/dlls/dbghelp/msc.c b/dlls/dbghelp/msc.c index 2932d2690f7..99de03743fd 100644 --- a/dlls/dbghelp/msc.c +++ b/dlls/dbghelp/msc.c @@ -486,23 +486,18 @@ static int codeview_add_type(unsigned int typeno, struct symt* dt) if ((typeno >> 24) != 0) FIXME("No module index while inserting type-id assumption is wrong %x\n", typeno); - if (typeno - FIRST_DEFINABLE_TYPE >= cv_current_module->num_defined_types) + while (typeno - FIRST_DEFINABLE_TYPE >= cv_current_module->num_defined_types) { + cv_current_module->num_defined_types += 0x100; if (cv_current_module->defined_types) - { - cv_current_module->num_defined_types = max( cv_current_module->num_defined_types * 2, - typeno - FIRST_DEFINABLE_TYPE + 1 ); cv_current_module->defined_types = HeapReAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, cv_current_module->defined_types, cv_current_module->num_defined_types * sizeof(struct symt*)); - } else - { - cv_current_module->num_defined_types = max( 256, typeno - FIRST_DEFINABLE_TYPE + 1 ); cv_current_module->defined_types = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, cv_current_module->num_defined_types * sizeof(struct symt*)); - } + if (cv_current_module->defined_types == NULL) return FALSE; } if (cv_current_module->defined_types[typeno - FIRST_DEFINABLE_TYPE]) @@ -2222,8 +2217,7 @@ static void pdb_process_types(const struct msc_debug_info* msc_dbg, case 19950410: /* VC 4.0 */ case 19951122: case 19961031: /* VC 5.0 / 6.0 */ - case 19990903: /* VC 7.0 */ - case 20040203: /* VC 8.0 */ + case 19990903: break; default: ERR("-Unknown type info version %d\n", types.version); diff --git a/dlls/dbghelp/pe_module.c b/dlls/dbghelp/pe_module.c index 44a4d6a14b2..91c7d801e1a 100644 --- a/dlls/dbghelp/pe_module.c +++ b/dlls/dbghelp/pe_module.c @@ -134,7 +134,7 @@ static BOOL pe_load_dbg_file(const struct process* pcs, struct module* module, */ static BOOL pe_load_msc_debug_info(const struct process* pcs, struct module* module, - void* mapping, const IMAGE_NT_HEADERS* nth) + void* mapping, IMAGE_NT_HEADERS* nth) { BOOL ret = FALSE; const IMAGE_DATA_DIRECTORY* dir; @@ -182,7 +182,7 @@ static BOOL pe_load_msc_debug_info(const struct process* pcs, */ static BOOL pe_load_export_debug_info(const struct process* pcs, struct module* module, - void* mapping, const IMAGE_NT_HEADERS* nth) + void* mapping, IMAGE_NT_HEADERS* nth) { unsigned int i; const IMAGE_EXPORT_DIRECTORY* exports; diff --git a/dlls/dbghelp/source.c b/dlls/dbghelp/source.c index c8ecf26c9fc..dd8fc6e876a 100644 --- a/dlls/dbghelp/source.c +++ b/dlls/dbghelp/source.c @@ -76,18 +76,13 @@ unsigned source_new(struct module* module, const char* base, const char* name) int len = strlen(full) + 1; if (module->sources_used + len + 1 > module->sources_alloc) { + /* Alloc by block of 256 bytes */ + module->sources_alloc = (module->sources_used + len + 1 + 255) & ~255; if (!module->sources) - { - module->sources_alloc = (module->sources_used + len + 1 + 255) & ~255; module->sources = HeapAlloc(GetProcessHeap(), 0, module->sources_alloc); - } else - { - module->sources_alloc = max( module->sources_alloc * 2, - (module->sources_used + len + 1 + 255) & ~255 ); module->sources = HeapReAlloc(GetProcessHeap(), 0, module->sources, module->sources_alloc); - } } ret = module->sources_used; memcpy(module->sources + module->sources_used, full, len); diff --git a/dlls/dbghelp/stabs.c b/dlls/dbghelp/stabs.c index 348a7aac376..f6199f3cea8 100644 --- a/dlls/dbghelp/stabs.c +++ b/dlls/dbghelp/stabs.c @@ -180,18 +180,14 @@ static int stabs_new_include(const char* file, unsigned long val) { if (num_include_def == num_alloc_include_def) { + num_alloc_include_def += 256; if (!include_defs) - { - num_alloc_include_def = 256; - include_defs = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, + include_defs = HeapAlloc(GetProcessHeap(), 0, sizeof(include_defs[0]) * num_alloc_include_def); - } else - { - num_alloc_include_def *= 2; - include_defs = HeapReAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, include_defs, + include_defs = HeapReAlloc(GetProcessHeap(), 0, include_defs, sizeof(include_defs[0]) * num_alloc_include_def); - } + memset(include_defs + num_include_def, 0, sizeof(include_defs[0]) * 256); } include_defs[num_include_def].name = strcpy(HeapAlloc(GetProcessHeap(), 0, strlen(file) + 1), file); include_defs[num_include_def].value = val; @@ -266,13 +262,13 @@ static struct symt** stabs_find_ref(long filenr, long subnr) { if (cu_nrofentries <= subnr) { - cu_nrofentries = max( cu_nrofentries * 2, subnr + 1 ); if (!cu_vector) - cu_vector = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, - sizeof(cu_vector[0]) * cu_nrofentries); + cu_vector = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, + sizeof(cu_vector[0]) * (subnr+1)); else - cu_vector = HeapReAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, - cu_vector, sizeof(cu_vector[0]) * cu_nrofentries); + cu_vector = HeapReAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, + cu_vector, sizeof(cu_vector[0]) * (subnr+1)); + cu_nrofentries = subnr + 1; } ret = &cu_vector[subnr]; } @@ -285,13 +281,13 @@ static struct symt** stabs_find_ref(long filenr, long subnr) if (idef->nrofentries <= subnr) { - idef->nrofentries = max( idef->nrofentries * 2, subnr + 1 ); if (!idef->vector) - idef->vector = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, - sizeof(idef->vector[0]) * idef->nrofentries); + idef->vector = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, + sizeof(idef->vector[0]) * (subnr+1)); else - idef->vector = HeapReAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, - idef->vector, sizeof(idef->vector[0]) * idef->nrofentries); + idef->vector = HeapReAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, + idef->vector, sizeof(idef->vector[0]) * (subnr+1)); + idef->nrofentries = subnr + 1; } ret = &idef->vector[subnr]; } @@ -1158,18 +1154,13 @@ static inline void pending_make_room(struct pending_list* pending) { if (pending->num == pending->allocated) { + pending->allocated += 8; if (!pending->objs) - { - pending->allocated = 8; pending->objs = HeapAlloc(GetProcessHeap(), 0, pending->allocated * sizeof(pending->objs[0])); - } - else - { - pending->allocated *= 2; + else pending->objs = HeapReAlloc(GetProcessHeap(), 0, pending->objs, pending->allocated * sizeof(pending->objs[0])); - } } } @@ -1320,7 +1311,7 @@ BOOL stabs_parse(struct module* module, unsigned long load_offset, unsigned len = strlen(ptr); if (strlen(stabbuff) + len > stabbufflen) { - stabbufflen *= 2; + stabbufflen += 65536; stabbuff = HeapReAlloc(GetProcessHeap(), 0, stabbuff, stabbufflen); } strncat(stabbuff, ptr, len - 1); diff --git a/dlls/dbghelp/symbol.c b/dlls/dbghelp/symbol.c index 34d00b2a021..3e70e85f4ae 100644 --- a/dlls/dbghelp/symbol.c +++ b/dlls/dbghelp/symbol.c @@ -67,45 +67,6 @@ int symt_cmp_addr(const void* p1, const void* p2) return cmp_addr(a1, a2); } -static BOOL symt_grow_sorttab(struct module* module, unsigned sz) -{ - struct symt_ht** new; - unsigned int size; - - if (sz <= module->sorttab_size) return TRUE; - if (module->addr_sorttab) - { - size = module->sorttab_size * 2; - new = HeapReAlloc(GetProcessHeap(), 0, module->addr_sorttab, - size * sizeof(struct symt_ht*)); - } - else - { - size = 64; - new = HeapAlloc(GetProcessHeap(), 0, size * sizeof(struct symt_ht*)); - } - if (!new) return FALSE; - module->sorttab_size = size; - module->addr_sorttab = new; - return TRUE; -} - -static void symt_add_module_ht(struct module* module, struct symt_ht* ht) -{ - ULONG64 addr; - - hash_table_add(&module->ht_symbols, &ht->hash_elt); - /* Don't store in sorttab a symbol without address, they are of - * no use here (e.g. constant values) - */ - if (symt_get_info(&ht->symt, TI_GET_ADDRESS, &addr) && - symt_grow_sorttab(module, module->num_symbols + 1)) - { - module->addr_sorttab[module->num_symbols++] = ht; - module->sortlist_valid = FALSE; - } -} - #ifdef HAVE_REGEX_H /* transforms a dbghelp's regular expression into a POSIX one @@ -286,12 +247,13 @@ struct symt_public* symt_new_public(struct module* module, { sym->symt.tag = SymTagPublicSymbol; sym->hash_elt.name = pool_strdup(&module->pool, name); + hash_table_add(&module->ht_symbols, &sym->hash_elt); + module->sortlist_valid = FALSE; sym->container = compiland ? &compiland->symt : NULL; sym->address = address; sym->size = size; sym->in_code = in_code; sym->is_function = is_func; - symt_add_module_ht(module, (struct symt_ht*)sym); if (compiland) { p = vector_add(&compiland->vchildren, &module->pool); @@ -317,6 +279,8 @@ struct symt_data* symt_new_global_variable(struct module* module, { sym->symt.tag = SymTagData; sym->hash_elt.name = pool_strdup(&module->pool, name); + hash_table_add(&module->ht_symbols, &sym->hash_elt); + module->sortlist_valid = FALSE; sym->kind = is_static ? DataIsFileStatic : DataIsGlobal; sym->container = compiland ? &compiland->symt : NULL; sym->type = type; @@ -328,7 +292,6 @@ struct symt_data* symt_new_global_variable(struct module* module, debugstr_w(module->module.ModuleName), name, wine_dbgstr_longlong(tsz), size); } - symt_add_module_ht(module, (struct symt_ht*)sym); if (compiland) { p = vector_add(&compiland->vchildren, &module->pool); @@ -355,13 +318,14 @@ struct symt_function* symt_new_function(struct module* module, { sym->symt.tag = SymTagFunction; sym->hash_elt.name = pool_strdup(&module->pool, name); + hash_table_add(&module->ht_symbols, &sym->hash_elt); + module->sortlist_valid = FALSE; sym->container = &compiland->symt; sym->address = addr; sym->type = sig_type; sym->size = size; vector_init(&sym->vlines, sizeof(struct line_info), 64); vector_init(&sym->vchildren, sizeof(struct symt*), 8); - symt_add_module_ht(module, (struct symt_ht*)sym); if (compiland) { p = vector_add(&compiland->vchildren, &module->pool); @@ -486,7 +450,7 @@ struct symt_block* symt_open_func_block(struct module* module, } struct symt_block* symt_close_func_block(struct module* module, - const struct symt_function* func, + struct symt_function* func, struct symt_block* block, unsigned pc) { assert(func); @@ -518,7 +482,7 @@ struct symt_hierarchy_point* symt_add_function_point(struct module* module, return sym; } -BOOL symt_normalize_function(struct module* module, const struct symt_function* func) +BOOL symt_normalize_function(struct module* module, struct symt_function* func) { unsigned len; struct line_info* dli; @@ -555,11 +519,12 @@ struct symt_thunk* symt_new_thunk(struct module* module, { sym->symt.tag = SymTagThunk; sym->hash_elt.name = pool_strdup(&module->pool, name); + hash_table_add(&module->ht_symbols, &sym->hash_elt); + module->sortlist_valid = FALSE; sym->container = &compiland->symt; sym->address = addr; sym->size = size; sym->ordinal = ord; - symt_add_module_ht(module, (struct symt_ht*)sym); if (compiland) { struct symt** p; @@ -584,11 +549,12 @@ struct symt_data* symt_new_constant(struct module* module, { sym->symt.tag = SymTagData; sym->hash_elt.name = pool_strdup(&module->pool, name); + hash_table_add(&module->ht_symbols, &sym->hash_elt); + module->sortlist_valid = FALSE; sym->kind = DataIsConstant; sym->container = compiland ? &compiland->symt : NULL; sym->type = type; sym->u.value = *v; - symt_add_module_ht(module, (struct symt_ht*)sym); if (compiland) { struct symt** p; @@ -612,10 +578,11 @@ struct symt_hierarchy_point* symt_new_label(struct module* module, { sym->symt.tag = SymTagLabel; sym->hash_elt.name = pool_strdup(&module->pool, name); + hash_table_add(&module->ht_symbols, &sym->hash_elt); + module->sortlist_valid = FALSE; sym->loc.kind = loc_absolute; sym->loc.offset = address; sym->parent = compiland ? &compiland->symt : NULL; - symt_add_module_ht(module, (struct symt_ht*)sym); if (compiland) { struct symt** p; @@ -771,7 +738,7 @@ static BOOL send_symbol(const struct sym_enum* se, const struct module_pair* pai return !se->cb(se->sym_info, se->sym_info->Size, se->user); } -static BOOL symt_enum_module(const struct module_pair* pair, const regex_t* regex, +static BOOL symt_enum_module(struct module_pair* pair, const regex_t* regex, const struct sym_enum* se) { void* ptr; @@ -792,26 +759,6 @@ static BOOL symt_enum_module(const struct module_pair* pair, const regex_t* rege return FALSE; } -static inline unsigned where_to_insert(const struct module* module, unsigned high, const struct symt_ht* elt) -{ - unsigned low = 0, mid = high / 2; - ULONG64 addr; - - if (!high) return 0; - symt_get_info(&elt->symt, TI_GET_ADDRESS, &addr); - do - { - switch (cmp_sorttab_addr(module, mid, addr)) - { - case 0: return mid; - case -1: low = mid + 1; break; - case 1: high = mid; break; - } - mid = low + (high - low) / 2; - } while (low < high); - return mid; -} - /*********************************************************************** * resort_symbols * @@ -819,36 +766,42 @@ static inline unsigned where_to_insert(const struct module* module, unsigned hig */ static BOOL resort_symbols(struct module* module) { - if (!(module->module.NumSyms = module->num_symbols)) + void* ptr; + struct symt_ht* sym; + struct hash_table_iter hti; + ULONG64 addr; + + if (!(module->module.NumSyms = module->ht_symbols.num_elts)) return FALSE; + + if (module->addr_sorttab) + module->addr_sorttab = HeapReAlloc(GetProcessHeap(), 0, + module->addr_sorttab, + module->module.NumSyms * sizeof(struct symt_ht*)); + else + module->addr_sorttab = HeapAlloc(GetProcessHeap(), 0, + module->module.NumSyms * sizeof(struct symt_ht*)); + if (!module->addr_sorttab) return FALSE; - /* FIXME: what's the optimal value here ??? */ - if (module->num_sorttab && module->num_symbols <= module->num_sorttab + 30) + module->num_sorttab = 0; + hash_table_iter_init(&module->ht_symbols, &hti, NULL); + while ((ptr = hash_table_iter_up(&hti))) { - int i, delta, ins_idx = module->num_sorttab, prev_ins_idx; - struct symt_ht* tmp[30]; - - delta = module->num_symbols - module->num_sorttab; - memcpy(tmp, &module->addr_sorttab[module->num_sorttab], delta * sizeof(struct symt_ht*)); - qsort(tmp, delta, sizeof(struct symt_ht*), symt_cmp_addr); - - for (i = delta - 1; i >= 0; i--) - { - prev_ins_idx = ins_idx; - ins_idx = where_to_insert(module, prev_ins_idx = ins_idx, tmp[i]); - memmove(&module->addr_sorttab[ins_idx + i + 1], - &module->addr_sorttab[ins_idx], - (prev_ins_idx - ins_idx) * sizeof(struct symt_ht*)); - module->addr_sorttab[ins_idx + i] = tmp[i]; - } + sym = GET_ENTRY(ptr, struct symt_ht, hash_elt); + assert(sym); + /* Don't store in sorttab symbol without address, they are of + * no use here (e.g. constant values) + * As the number of those symbols is very couple (a couple per module) + * we don't bother for the unused spots at the end of addr_sorttab + */ + if (symt_get_info(&sym->symt, TI_GET_ADDRESS, &addr)) + module->addr_sorttab[module->num_sorttab++] = sym; } - else - qsort(module->addr_sorttab, module->num_symbols, sizeof(struct symt_ht*), symt_cmp_addr); - module->num_sorttab = module->num_symbols; + qsort(module->addr_sorttab, module->num_sorttab, sizeof(struct symt_ht*), symt_cmp_addr); return module->sortlist_valid = TRUE; } -static void symt_get_length(const struct symt* symt, ULONG64* size) +static void symt_get_length(struct symt* symt, ULONG64* size) { DWORD type_index; diff --git a/dlls/ddeml.dll16/Makefile.in b/dlls/ddeml.dll16/Makefile.in index fd4a2b511f5..b1eb6c92240 100644 --- a/dlls/ddeml.dll16/Makefile.in +++ b/dlls/ddeml.dll16/Makefile.in @@ -7,6 +7,8 @@ IMPORTS = user32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16 +SPEC_SRCS = ddeml.dll16.spec + C_SRCS = ddeml.c @MAKE_DLL_RULES@ diff --git a/dlls/ddraw/device.c b/dlls/ddraw/device.c index 360604e83eb..261d6e399da 100644 --- a/dlls/ddraw/device.c +++ b/dlls/ddraw/device.c @@ -2956,7 +2956,7 @@ IDirect3DDeviceImpl_3_SetLightState(IDirect3DDevice3 *iface, TRACE("(%p)->(%08x,%08x)\n", This, LightStateType, Value); - if (!LightStateType || (LightStateType > D3DLIGHTSTATE_COLORVERTEX)) + if (!LightStateType && (LightStateType > D3DLIGHTSTATE_COLORVERTEX)) { TRACE("Unexpected Light State Type\n"); return DDERR_INVALIDPARAMS; @@ -3089,7 +3089,7 @@ IDirect3DDeviceImpl_3_GetLightState(IDirect3DDevice3 *iface, TRACE("(%p)->(%08x,%p)\n", This, LightStateType, Value); - if (!LightStateType || (LightStateType > D3DLIGHTSTATE_COLORVERTEX)) + if (!LightStateType && (LightStateType > D3DLIGHTSTATE_COLORVERTEX)) { TRACE("Unexpected Light State Type\n"); return DDERR_INVALIDPARAMS; @@ -5937,8 +5937,8 @@ static BOOL is_mip_level_subset(IDirectDrawSurfaceImpl *dest, static void copy_mipmap_chain(IDirect3DDeviceImpl *device, IDirectDrawSurfaceImpl *dest, IDirectDrawSurfaceImpl *src, - const POINT *DestPoint, - const RECT *SrcRect) + POINT *DestPoint, + RECT *SrcRect) { IDirectDrawSurfaceImpl *src_level, *dest_level; IDirectDrawSurface7 *temp; diff --git a/dlls/ddraw/executebuffer.c b/dlls/ddraw/executebuffer.c index 6d6d30418c5..73e06579871 100644 --- a/dlls/ddraw/executebuffer.c +++ b/dlls/ddraw/executebuffer.c @@ -249,7 +249,7 @@ IDirect3DExecuteBufferImpl_Execute(IDirect3DExecuteBufferImpl *This, TRACE("(%08x,%08x)\n", ci->u1.dlstLightStateType, ci->u2.dwArg[0]); - if (!ci->u1.dlstLightStateType || (ci->u1.dlstLightStateType > D3DLIGHTSTATE_COLORVERTEX)) + if (!ci->u1.dlstLightStateType && (ci->u1.dlstLightStateType > D3DLIGHTSTATE_COLORVERTEX)) ERR("Unexpected Light State Type\n"); else if (ci->u1.dlstLightStateType == D3DLIGHTSTATE_MATERIAL /* 1 */) { DWORD matHandle = ci->u2.dwArg[0]; diff --git a/dlls/ddraw/tests/d3d.c b/dlls/ddraw/tests/d3d.c index f4cd07b3fa0..57e1da002d6 100644 --- a/dlls/ddraw/tests/d3d.c +++ b/dlls/ddraw/tests/d3d.c @@ -951,7 +951,6 @@ static BOOL D3D1_createObjects(void) ok(hr==DD_OK, "SetCooperativeLevel returned: %x\n", hr); hr = IDirectDraw_QueryInterface(DirectDraw1, &IID_IDirect3D, (void**) &Direct3D1); - if (hr == E_NOINTERFACE) return FALSE; ok(hr==DD_OK, "QueryInterface returned: %x\n", hr); if (!Direct3D1) { return FALSE; diff --git a/dlls/ddraw/tests/dsurface.c b/dlls/ddraw/tests/dsurface.c index 28fc0f55937..c3280fb5880 100644 --- a/dlls/ddraw/tests/dsurface.c +++ b/dlls/ddraw/tests/dsurface.c @@ -1029,39 +1029,36 @@ static void IFaceRefCount(void) todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); /* IDirect3DTexture interface (unlike the others) alters the original IDirectDrawSurface ref count */ - ret = IDirectDrawSurface_QueryInterface(surf, &IID_IDirect3DTexture, (void **) &tex); - if (SUCCEEDED(ret)) - { - ref = getRefcount((IUnknown *) tex); - todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); - ref = getRefcount((IUnknown *) surf); - todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); - - IDirectDrawSurface_QueryInterface(surf, &IID_IDirect3DTexture2, (void **) &tex2); - ref = getRefcount((IUnknown *) tex); - todo_wine ok(ref == 3, "Refcount is %u, expected 3\n", ref); - ref = getRefcount((IUnknown *) tex2); - todo_wine ok(ref == 3, "Refcount is %u, expected 3\n", ref); - ref = getRefcount((IUnknown *) surf); - todo_wine ok(ref == 3, "Refcount is %u, expected 3\n", ref); - - IDirectDrawSurface_QueryInterface(surf, &IID_IDirectDrawGammaControl, (void **) &gamma); - ref = getRefcount((IUnknown *) gamma); - todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref); - - ref = IDirect3DTexture2_Release(tex2); /* Release the texture */ - todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); - ref = getRefcount((IUnknown *) surf); - todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); - - ref = IDirect3DTexture_Release(tex); /* Release the texture */ - todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref); - ref = getRefcount((IUnknown *) surf); - todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref); - - ref = IDirectDrawGammaControl_Release(gamma); /* Release the gamma control */ - todo_wine ok(ref == 0, "Refcount is %u, expected 0\n", ref); - } + IDirectDrawSurface_QueryInterface(surf, &IID_IDirect3DTexture, (void **) &tex); + ref = getRefcount((IUnknown *) tex); + todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); + ref = getRefcount((IUnknown *) surf); + todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); + + IDirectDrawSurface_QueryInterface(surf, &IID_IDirect3DTexture2, (void **) &tex2); + ref = getRefcount((IUnknown *) tex); + todo_wine ok(ref == 3, "Refcount is %u, expected 3\n", ref); + ref = getRefcount((IUnknown *) tex2); + todo_wine ok(ref == 3, "Refcount is %u, expected 3\n", ref); + ref = getRefcount((IUnknown *) surf); + todo_wine ok(ref == 3, "Refcount is %u, expected 3\n", ref); + + IDirectDrawSurface_QueryInterface(surf, &IID_IDirectDrawGammaControl, (void **) &gamma); + ref = getRefcount((IUnknown *) gamma); + todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref); + + ref = IDirect3DTexture2_Release(tex2); /* Release the texture */ + todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); + ref = getRefcount((IUnknown *) surf); + todo_wine ok(ref == 2, "Refcount is %u, expected 2\n", ref); + + ref = IDirect3DTexture_Release(tex); /* Release the texture */ + todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref); + ref = getRefcount((IUnknown *) surf); + todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref); + + ref = IDirectDrawGammaControl_Release(gamma); /* Release the gamma control */ + todo_wine ok(ref == 0, "Refcount is %u, expected 0\n", ref); ref = IDirectDrawSurface2_Release(surf2); /* Release one of the 2 surf2 interfaces */ todo_wine ok(ref == 1, "Refcount is %u, expected 1\n", ref); diff --git a/dlls/ddraw/tests/overlay.c b/dlls/ddraw/tests/overlay.c index 55c4989b9ba..d1edc1d8d29 100644 --- a/dlls/ddraw/tests/overlay.c +++ b/dlls/ddraw/tests/overlay.c @@ -200,8 +200,7 @@ static void yv12_test(void) ok(desc.dwFlags == (DDSD_WIDTH | DDSD_HEIGHT | DDSD_PIXELFORMAT | DDSD_CAPS | DDSD_PITCH), "Unexpected desc.dwFlags 0x%08x\n", desc.dwFlags); - ok(desc.ddsCaps.dwCaps == (DDSCAPS_OVERLAY | DDSCAPS_VIDEOMEMORY | DDSCAPS_LOCALVIDMEM) || - desc.ddsCaps.dwCaps == (DDSCAPS_OVERLAY | DDSCAPS_VIDEOMEMORY | DDSCAPS_LOCALVIDMEM | DDSCAPS_HWCODEC), + ok(desc.ddsCaps.dwCaps == (DDSCAPS_OVERLAY | DDSCAPS_VIDEOMEMORY | DDSCAPS_LOCALVIDMEM), "Unexpected desc.ddsCaps.dwCaps 0x%08x\n", desc.ddsCaps.dwCaps); ok(desc.dwWidth == 256 && desc.dwHeight == 256, "Expected size 64x64, got %ux%u\n", desc.dwWidth, desc.dwHeight); diff --git a/dlls/ddraw/tests/refcount.c b/dlls/ddraw/tests/refcount.c index 9ad560bf50e..bfff64afbd3 100644 --- a/dlls/ddraw/tests/refcount.c +++ b/dlls/ddraw/tests/refcount.c @@ -237,17 +237,7 @@ static void test_iface_refcnt(void) ok(ref == 1, "IDirectDraw reference count is %ld\n", ref); hr = IDirectDraw7_QueryInterface(DDraw7, &IID_IDirect3D7, (void **) &D3D7); - ok(hr == DD_OK || hr == E_NOINTERFACE, /* win64 */ - "IDirectDraw7_QueryInterface returned %08x\n", hr); - if (FAILED(hr)) - { - IDirectDraw7_Release(DDraw7); - IDirectDraw4_Release(DDraw4); - IDirectDraw2_Release(DDraw2); - IDirectDraw_Release(DDraw1); - skip( "no IDirect3D7 support\n" ); - return; - } + ok(hr == DD_OK, "IDirectDraw7_QueryInterface returned %08x\n", hr); /* Apparently IDirectDrawX and IDirect3DX are linked together */ ref = getRefcount( (IUnknown *) D3D7); @@ -358,14 +348,6 @@ static void test_d3d_ifaces(void) ok(ref == 1, "IDirectDraw reference count is %ld\n", ref); hr = IDirectDraw_QueryInterface(DDraw1, &IID_IDirect3D, (void **) &D3D1); - if (hr == E_NOINTERFACE) /* win64 */ - { - IDirectDraw4_Release(DDraw4); - IDirectDraw2_Release(DDraw2); - IDirectDraw_Release(DDraw1); - skip( "no IDirect3D support\n" ); - return; - } ok(hr == DD_OK, "IDirectDraw_QueryInterface returned %08x\n", hr); ref = getRefcount( (IUnknown *) DDraw4); ok(ref == 1, "IDirectDraw4 reference count is %ld\n", ref); diff --git a/dlls/devenum/devenum.rc b/dlls/devenum/devenum.rc index 01f76b4c603..b9ff4a5d292 100644 --- a/dlls/devenum/devenum.rc +++ b/dlls/devenum/devenum.rc @@ -72,7 +72,7 @@ LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL } STRINGTABLE DISCARDABLE -LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN { 7 "DirectSound padrão" 8 "DirectSound: %s" @@ -170,12 +170,3 @@ LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL 9 "Numatytasis WaveOut įrenginys" 10 "Numatytasis MidiOut įrenginys" } - -STRINGTABLE DISCARDABLE -LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT -{ - 7 "デフォルト DirectSound" - 8 "DirectSound: %s" - 9 "デフォルト WaveOut デバイス" - 10 "デフォルト MidiOut デバイス" -} diff --git a/dlls/dispdib.dll16/Makefile.in b/dlls/dispdib.dll16/Makefile.in index 6f461381eeb..9671dd3d00e 100644 --- a/dlls/dispdib.dll16/Makefile.in +++ b/dlls/dispdib.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = dispdib.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16 +SPEC_SRCS = dispdib.dll16.spec + C_SRCS = dispdib.c @MAKE_DLL_RULES@ diff --git a/dlls/display.drv16/Makefile.in b/dlls/display.drv16/Makefile.in index 96194c61103..06c053130a1 100644 --- a/dlls/display.drv16/Makefile.in +++ b/dlls/display.drv16/Makefile.in @@ -8,6 +8,8 @@ IMPORTS = user32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16 EXTRARCFLAGS = -O res16 +SPEC_SRCS = display.drv16.spec + C_SRCS = display.c RC_SRCS = display.rc diff --git a/dlls/dmband/Makefile.in b/dlls/dmband/Makefile.in index f749373f914..157ba5ed571 100644 --- a/dlls/dmband/Makefile.in +++ b/dlls/dmband/Makefile.in @@ -8,8 +8,8 @@ IMPORTS = dxguid uuid ole32 advapi32 kernel32 C_SRCS = \ band.c \ bandtrack.c \ - dmband_main.c \ dmutils.c \ + dmband_main.c \ regsvr.c RC_SRCS = version.rc diff --git a/dlls/dplayx/tests/dplayx.c b/dlls/dplayx/tests/dplayx.c index 3eba14702ef..2d14584359f 100644 --- a/dlls/dplayx/tests/dplayx.c +++ b/dlls/dplayx/tests/dplayx.c @@ -6132,138 +6132,6 @@ static void test_remote_data_replication(void) } -/* Host migration */ - -static void test_host_migration(void) -{ - - LPDIRECTPLAY4 pDP[2]; - DPSESSIONDESC2 dpsd; - DPID dpid[2], idFrom, idTo; - HRESULT hr; - UINT i; - DWORD dwCount; - - DWORD dwDataSize = 1024; - LPDPMSG_DESTROYPLAYERORGROUP lpData = HeapAlloc( GetProcessHeap(), - HEAP_ZERO_MEMORY, - dwDataSize ); - - - for (i=0; i<2; i++) - { - CoCreateInstance( &CLSID_DirectPlay, NULL, CLSCTX_ALL, - &IID_IDirectPlay4A, (LPVOID*) &pDP[i] ); - init_TCPIP_provider( pDP[i], "127.0.0.1", 0 ); - } - ZeroMemory( &dpsd, sizeof(DPSESSIONDESC2) ); - dpsd.dwSize = sizeof(DPSESSIONDESC2); - dpsd.guidApplication = appGuid; - dpsd.dwMaxPlayers = 10; - dpsd.dwFlags = DPSESSION_MIGRATEHOST; - - /* Host */ - hr = IDirectPlayX_Open( pDP[0], &dpsd, DPOPEN_CREATE ); - todo_wine checkHR( DP_OK, hr ); - - if ( hr != DP_OK ) - { - todo_wine win_skip( "dplay not implemented enough for this test yet\n" ); - return; - } - - hr = IDirectPlayX_CreatePlayer( pDP[0], &dpid[0], NULL, NULL, NULL, 0, 0 ); - checkHR( DP_OK, hr ); - - /* Peer */ - hr = IDirectPlayX_EnumSessions( pDP[1], &dpsd, 0, EnumSessions_cb_join, - pDP[1], 0 ); - checkHR( DP_OK, hr ); - - hr = IDirectPlayX_CreatePlayer( pDP[1], &dpid[1], NULL, NULL, NULL, 0, 0 ); - checkHR( DP_OK, hr ); - - - /* Host: One message in queue */ - IDirectPlayX_GetMessageCount( pDP[0], dpid[0], &dwCount ); - check( 1, dwCount ); - dwDataSize = 1024; - hr = IDirectPlayX_Receive( pDP[0], &idFrom, &idTo, DPRECEIVE_PEEK, - lpData, &dwDataSize ); - checkHR( DP_OK, hr ); - checkConv( DPSYS_CREATEPLAYERORGROUP, lpData->dwType, dpMsgType2str ); - - /* Peer: No messages */ - IDirectPlayX_GetMessageCount( pDP[1], dpid[1], &dwCount ); - check( 0, dwCount ); - hr = IDirectPlayX_Receive( pDP[1], &idFrom, &idTo, DPRECEIVE_PEEK, - lpData, &dwDataSize ); - checkHR( DPERR_NOMESSAGES, hr ); - - - /* Closing host */ - IDirectPlayX_Close( pDP[0] ); - - - /* Host: Queue is cleaned */ - IDirectPlayX_GetMessageCount( pDP[0], dpid[0], &dwCount ); - check( 0, dwCount ); - hr = IDirectPlayX_Receive( pDP[0], &idFrom, &idTo, DPRECEIVE_PEEK, - lpData, &dwDataSize ); - checkHR( DPERR_NOMESSAGES, hr ); - - /* Peer: gets message of player destruction */ - IDirectPlayX_GetMessageCount( pDP[1], dpid[1], &dwCount ); - check( 2, dwCount ); - dwDataSize = 1024; - hr = IDirectPlayX_Receive( pDP[1], &idFrom, &idTo, DPRECEIVE_PEEK, - lpData, &dwDataSize ); - checkHR( DP_OK, hr ); - checkConv( DPSYS_DESTROYPLAYERORGROUP, lpData->dwType, dpMsgType2str ); - - - /* Message analysis */ - for (i=0; i<2; i++) - { - hr = IDirectPlayX_Receive( pDP[1], &idFrom, &idTo, 0, - lpData, &dwDataSize ); - checkHR( DP_OK, hr ); - check( DPID_SYSMSG, idFrom ); - check( dpid[1], idTo ); /* Peer player id */ - switch(i) - { - case 0: - checkConv( DPSYS_DESTROYPLAYERORGROUP, lpData->dwType, - dpMsgType2str ); - check( DPPLAYERTYPE_PLAYER, lpData->dwPlayerType ); - check( dpid[0], lpData->dpId ); /* Host player id */ - checkLP( NULL, lpData->lpLocalData ); - check( 0, lpData->dwLocalDataSize ); - checkLP( NULL, lpData->lpRemoteData ); - check( 0, lpData->dwRemoteDataSize ); - checkLP( NULL, lpData->dpnName.lpszShortNameA ); - check( 0, lpData->dpIdParent ); - checkFlags( 0, lpData->dwFlags, - FLAGS_DPPLAYER | FLAGS_DPGROUP ); - break; - case 1: - checkConv( DPSYS_HOST, lpData->dwType, dpMsgType2str ); - break; - default: - break; - } - dwDataSize = 1024; - } - hr = IDirectPlayX_Receive( pDP[1], &idFrom, &idTo, 0, lpData, &dwDataSize ); - checkHR( DPERR_NOMESSAGES, hr ); - - - HeapFree( GetProcessHeap(), 0, lpData ); - IDirectPlayX_Release( pDP[0] ); - IDirectPlayX_Release( pDP[1] ); - -} - START_TEST(dplayx) { @@ -6315,7 +6183,6 @@ START_TEST(dplayx) test_GetMessageQueue(); test_remote_data_replication(); - test_host_migration(); CoUninitialize(); } diff --git a/dlls/drmclien/Makefile.in b/dlls/drmclien/Makefile.in deleted file mode 100644 index 86dcc389784..00000000000 --- a/dlls/drmclien/Makefile.in +++ /dev/null @@ -1,13 +0,0 @@ -TOPSRCDIR = @top_srcdir@ -TOPOBJDIR = ../.. -SRCDIR = @srcdir@ -VPATH = @srcdir@ -MODULE = drmclien.dll -IMPORTS = kernel32 - -C_SRCS = \ - main.c - -@MAKE_DLL_RULES@ - -@DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/drmclien/drmclien.spec b/dlls/drmclien/drmclien.spec deleted file mode 100644 index b93472b5d5e..00000000000 --- a/dlls/drmclien/drmclien.spec +++ /dev/null @@ -1,31 +0,0 @@ -@ stub DllMain -@ stub CanDecrypt -@ stub Decrypt -@ stub RequestLicense -@ stub ProcessResponse -@ stub Bind -@ stub KeyExchange -@ stub GetVersion -@ stub CanDecryptEx -@ stub BindEx -@ stub ??0CDRMLiteCrypto@@QAE@XZ -@ stub ??1CDRMLiteCrypto@@QAE@XZ -@ stub SetAppSec -@ stub SetLicenseStore -@ stub GetPMLicenseFileName -@ stub GetPMLicenseSize -@ stub CreatePMLicense -@ stub GenerateNewLicense -@ stub Encrypt -@ stub InitAppCerts -@ stub QueryXferToPM -@ stub ?BackupLicenses@CDRMLiteCrypto@@QAEJKPAGPAUIUnknown@@PAHPAX@Z -@ stub ?EncryptFast@CDRMLiteCrypto@@QAEJPBDKPAE1@Z -@ stub ?EncryptIndirectFast@CDRMLiteCrypto@@QAEJPBDKPAE1@Z -@ stub ?GenerateNewLicenseEx@CDRMLiteCrypto@@QAEJKPAE00PAPAD10@Z -@ stub ?GetLicenses@CDRMLiteCrypto@@QAEJPBDPAUPMLICENSE@@PAKKPAX2PAE@Z -@ stub ?GetPublicKey@CDRMLiteCrypto@@QAEJPAUPKCERT@@@Z -@ stub ?QueryXferToPMEx@CDRMLiteCrypto@@QAEJPBDKPAKPAEK2K12@Z -@ stub ?RestoreLicenses@CDRMLiteCrypto@@QAEJKPAEPAGPAUIUnknown@@PAHPAX@Z -@ stub DllRegisterServer -@ stub DllUnregisterServer diff --git a/dlls/drmclien/main.c b/dlls/drmclien/main.c deleted file mode 100644 index c18ddada0e9..00000000000 --- a/dlls/drmclien/main.c +++ /dev/null @@ -1,42 +0,0 @@ -/* - * - * Copyright 2009 Austin English - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "config.h" - -#include - -#include "windef.h" -#include "winbase.h" -#include "wine/debug.h" - -BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) -{ - switch (fdwReason) - { - case DLL_WINE_PREATTACH: - return FALSE; /* prefer native version */ - case DLL_PROCESS_ATTACH: - DisableThreadLibraryCalls(hinstDLL); - break; - case DLL_PROCESS_DETACH: - break; - } - - return TRUE; -} diff --git a/dlls/dsound/tests/dsound8.c b/dlls/dsound/tests/dsound8.c index a2b16d85bbb..a52f65374d2 100644 --- a/dlls/dsound/tests/dsound8.c +++ b/dlls/dsound/tests/dsound8.c @@ -759,7 +759,7 @@ static HRESULT test_secondary8(LPGUID lpGuid) wfxe.Format.cbSize = sizeof(wfxe) - sizeof(wfx) + 1; rc=IDirectSound_CreateSoundBuffer(dso,&bufdesc,&secondary,NULL); - ok(((rc==DSERR_CONTROLUNAVAIL || rc==DSERR_INVALIDCALL /* 2003 */) && !secondary) + ok(((rc==DSERR_CONTROLUNAVAIL || DSERR_INVALIDCALL /* 2003 */) && !secondary) || rc==DS_OK /* driver dependent? */, "IDirectSound_CreateSoundBuffer() returned: %08x %p\n", rc, secondary); @@ -805,7 +805,7 @@ static HRESULT test_secondary8(LPGUID lpGuid) wfxe.Format.cbSize = sizeof(wfxe) + 1; rc=IDirectSound_CreateSoundBuffer(dso,&bufdesc,&secondary,NULL); - ok(((rc==DSERR_CONTROLUNAVAIL || rc==DSERR_INVALIDCALL /* 2003 */) && !secondary) + ok(((rc==DSERR_CONTROLUNAVAIL || DSERR_INVALIDCALL /* 2003 */) && !secondary) || rc==DS_OK /* driver dependent? */, "IDirectSound_CreateSoundBuffer() returned: %08x %p\n", rc, secondary); diff --git a/dlls/dxdiagn/Makefile.in b/dlls/dxdiagn/Makefile.in index c69df4e2f7f..56ca6569a34 100644 --- a/dlls/dxdiagn/Makefile.in +++ b/dlls/dxdiagn/Makefile.in @@ -13,8 +13,6 @@ C_SRCS = \ RC_SRCS = version.rc -IDL_H_SRCS = fil_data.idl - @MAKE_DLL_RULES@ @DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/dxdiagn/fil_data.idl b/dlls/dxdiagn/fil_data.idl deleted file mode 100644 index 806c053429f..00000000000 --- a/dlls/dxdiagn/fil_data.idl +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Copyright (C) 2009 Vitaliy Margolen - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -import "objidl.idl"; -import "strmif.idl"; -import "unknwn.idl"; - - -/***************************************************************************** - * IAMFilterData interface - */ -[ - object, - uuid(97f7c4d4-547b-4a5f-8332-536430ad2e4d), - pointer_default(unique) -] -interface IAMFilterData : IUnknown -{ - typedef [unique] IAMFilterData *LPIAMFILTERDATA; - - HRESULT ParseFilterData( - [in] BYTE * rgbFilterData, - [in] ULONG cb, - [out] BYTE ** prgbRegFilter2); - - HRESULT CreateFilterData( - [in] REGFILTER2 * prf2, - [out] BYTE ** prgbFilterData, - [out] ULONG * pcb); -} diff --git a/dlls/dxdiagn/provider.c b/dlls/dxdiagn/provider.c index fb13033256d..d3f0a26b7de 100644 --- a/dlls/dxdiagn/provider.c +++ b/dlls/dxdiagn/provider.c @@ -23,7 +23,6 @@ #define COBJMACROS #define NONAMELESSUNION -#define NONAMELESSSTRUCT #include "dxdiag_private.h" #include "wine/unicode.h" #include "winver.h" @@ -34,9 +33,6 @@ #include "mmddk.h" #include "ddraw.h" #include "d3d9.h" -#include "strmif.h" -#include "initguid.h" -#include "fil_data.h" #include "wine/debug.h" @@ -576,6 +572,28 @@ static HRESULT DXDiag_InitDXDiagDirectPlayContainer(IDxDiagContainer* pSubCont) return hr; } +struct REG_RF { + DWORD dwVersion; + DWORD dwMerit; + DWORD dwPins; + DWORD dwUnused; +}; +struct REG_RFP { + BYTE signature[4]; /* e.g. "0pi3" */ + DWORD dwFlags; + DWORD dwInstances; + DWORD dwMediaTypes; + DWORD dwMediums; + DWORD bCategory; /* is there a category clsid? */ + /* optional: dwOffsetCategoryClsid */ +}; +struct REG_TYPE { + BYTE signature[4]; /* e.g. "0ty3" */ + DWORD dwUnused; + DWORD dwOffsetMajor; + DWORD dwOffsetMinor; +}; + static HRESULT DXDiag_InitDXDiagDirectShowFiltersContainer(IDxDiagContainer* pSubCont) { HRESULT hr = S_OK; static const WCHAR szName[] = {'s','z','N','a','m','e',0}; @@ -585,7 +603,7 @@ static HRESULT DXDiag_InitDXDiagDirectShowFiltersContainer(IDxDiagContainer* pSu static const WCHAR ClsidFilterW[] = {'C','l','s','i','d','F','i','l','t','e','r',0}; static const WCHAR dwInputs[] = {'d','w','I','n','p','u','t','s',0}; static const WCHAR dwOutputs[] = {'d','w','O','u','t','p','u','t','s',0}; - static const WCHAR dwMeritW[] = {'d','w','M','e','r','i','t',0}; + static const WCHAR dwMerit[] = {'d','w','M','e','r','i','t',0}; /* static const WCHAR szFileName[] = {'s','z','F','i','l','e','N','a','m','e',0}; static const WCHAR szFileVersion[] = {'s','z','F','i','l','e','V','e','r','s','i','o','n',0}; @@ -654,13 +672,13 @@ static HRESULT DXDiag_InitDXDiagDirectShowFiltersContainer(IDxDiagContainer* pSu hr = IMoniker_BindToStorage(pMoniker, NULL, NULL, &IID_IPropertyBag, (void**) &pPropFilterBag); if (SUCCEEDED(hr)) { LPBYTE pData = NULL; + LPBYTE pCurrent = NULL; + struct REG_RF* prrf = NULL; + DWORD it; DWORD dwNOutputs = 0; DWORD dwNInputs = 0; - DWORD dwMerit = 0; WCHAR bufferW[10]; IDxDiagContainer *pDShowSubCont = NULL; - IFilterMapper2 *pFileMapper = NULL; - IAMFilterData *pFilterData = NULL; snprintfW(bufferW, sizeof(bufferW)/sizeof(bufferW[0]), szIdFormat, i); if (FAILED(DXDiag_CreateDXDiagContainer(&IID_IDxDiagContainer, (void**) &pDShowSubCont)) || @@ -671,7 +689,6 @@ static HRESULT DXDiag_InitDXDiagDirectShowFiltersContainer(IDxDiagContainer* pSu continue; } - bufferW[0] = 0; hr = IPropertyBag_Read(pPropFilterBag, wszFriendlyName, &v, 0); hr = IDxDiagContainerImpl_AddProp(pDShowSubCont, szName, &v); TRACE("\tName:%s\n", debugstr_w(V_BSTR(&v))); @@ -682,61 +699,45 @@ static HRESULT DXDiag_InitDXDiagDirectShowFiltersContainer(IDxDiagContainer* pSu hr = IDxDiagContainerImpl_AddProp(pDShowSubCont, ClsidFilterW, &v); VariantClear(&v); - hr = CoCreateInstance(&CLSID_FilterMapper2, NULL, CLSCTX_INPROC, &IID_IFilterMapper2, - (LPVOID*)&pFileMapper); - if (SUCCEEDED(hr) && - SUCCEEDED(IFilterMapper2_QueryInterface(pFileMapper, &IID_IAMFilterData, (void **)&pFilterData))) - { - DWORD array_size; - BYTE *tmp; - REGFILTER2 *pRF = NULL; - - if (SUCCEEDED(IPropertyBag_Read(pPropFilterBag, wszFilterDataName, &v, NULL)) && - SUCCEEDED(SafeArrayAccessData(V_UNION(&v, parray), (LPVOID*) &pData))) - { - ULONG j; - array_size = V_UNION(&v, parray)->rgsabound->cElements; - - if (SUCCEEDED(IAMFilterData_ParseFilterData(pFilterData, pData, array_size, &tmp))) - { - pRF = ((REGFILTER2 **)tmp)[0]; - - snprintfW(bufferW, sizeof(bufferW)/sizeof(bufferW[0]), szVersionFormat, pRF->dwVersion); - if (pRF->dwVersion == 1) - { - for (j = 0; j < pRF->u.s.cPins; j++) - if (pRF->u.s.rgPins[j].bOutput) - dwNOutputs++; - else - dwNInputs++; - } - else if (pRF->dwVersion == 2) - { - for (j = 0; j < pRF->u.s1.cPins2; j++) - if (pRF->u.s1.rgPins2[j].dwFlags & REG_PINFLAG_B_OUTPUT) - dwNOutputs++; - else - dwNInputs++; - } - - dwMerit = pRF->dwMerit; - CoTaskMemFree(tmp); - } - - SafeArrayUnaccessData(V_UNION(&v, parray)); - VariantClear(&v); - } - IFilterMapper2_Release(pFilterData); - } - if (pFileMapper) IFilterMapper2_Release(pFileMapper); - - add_prop_str(pDShowSubCont, szVersionW, bufferW); add_prop_str(pDShowSubCont, szCatName, wszCatName); add_prop_str(pDShowSubCont, ClsidCatW, wszCatClsid); + + hr = IPropertyBag_Read(pPropFilterBag, wszFilterDataName, &v, NULL); + hr = SafeArrayAccessData(V_UNION(&v, parray), (LPVOID*) &pData); + prrf = (struct REG_RF*) pData; + pCurrent = pData; + + snprintfW(bufferW, sizeof(bufferW)/sizeof(bufferW[0]), szVersionFormat, prrf->dwVersion); + add_prop_str(pDShowSubCont, szVersionW, bufferW); + + pCurrent += sizeof(struct REG_RF); + for (it = 0; it < prrf->dwPins; ++it) { + struct REG_RFP* prrfp = (struct REG_RFP*) pCurrent; + UINT j; + + if (prrfp->dwFlags & REG_PINFLAG_B_OUTPUT) ++dwNOutputs; + else ++dwNInputs; + + pCurrent += sizeof(struct REG_RFP); + if (prrfp->bCategory) { + pCurrent += sizeof(DWORD); + } + for (j = 0; j < prrfp->dwMediaTypes; ++j) { + struct REG_TYPE* prt = (struct REG_TYPE *)pCurrent; + pCurrent += sizeof(*prt); + } + for (j = 0; j < prrfp->dwMediums; ++j) { + DWORD dwOffset = *(DWORD*) pCurrent; + pCurrent += sizeof(dwOffset); + } + } + add_prop_ui4(pDShowSubCont, dwInputs, dwNInputs); add_prop_ui4(pDShowSubCont, dwOutputs, dwNOutputs); - add_prop_ui4(pDShowSubCont, dwMeritW, dwMerit); + add_prop_ui4(pDShowSubCont, dwMerit, prrf->dwMerit); + SafeArrayUnaccessData(V_UNION(&v, parray)); + VariantClear(&v); i++; } IPropertyBag_Release(pPropFilterBag); pPropFilterBag = NULL; diff --git a/dlls/dxgi/Makefile.in b/dlls/dxgi/Makefile.in index f30910dc3e0..d340b6f4f26 100644 --- a/dlls/dxgi/Makefile.in +++ b/dlls/dxgi/Makefile.in @@ -11,9 +11,9 @@ C_SRCS = \ device.c \ dxgi_main.c \ factory.c \ + utils.c \ surface.c \ - swapchain.c \ - utils.c + swapchain.c RC_SRCS = version.rc diff --git a/dlls/dxguid/Makefile.in b/dlls/dxguid/Makefile.in index e202d3b21b4..e3806acc96d 100644 --- a/dlls/dxguid/Makefile.in +++ b/dlls/dxguid/Makefile.in @@ -5,9 +5,9 @@ VPATH = @srcdir@ MODULE = dxguid C_SRCS = \ + dx8guid.c \ + dx9guid.c \ dx10guid.c \ - dx8guid.c \ - dx9guid.c \ dxguid.c @MAKE_IMPLIB_RULES@ diff --git a/dlls/dxguid/dx8guid.c b/dlls/dxguid/dx8guid.c index 76d8cd1fe0f..6b51c9e6749 100644 --- a/dlls/dxguid/dx8guid.c +++ b/dlls/dxguid/dx8guid.c @@ -31,3 +31,4 @@ #include "initguid.h" #include "d3d8.h" +#include "d3dx8.h" diff --git a/dlls/dxguid/dx9guid.c b/dlls/dxguid/dx9guid.c index d64e6906cfc..2ab60ad8e69 100644 --- a/dlls/dxguid/dx9guid.c +++ b/dlls/dxguid/dx9guid.c @@ -31,4 +31,4 @@ #include "olectl.h" #include "initguid.h" -#include "d3dx9.h" +#include "d3d9.h" diff --git a/dlls/fusion/tests/asmname.c b/dlls/fusion/tests/asmname.c index 864ded51906..442f00f7c45 100644 --- a/dlls/fusion/tests/asmname.c +++ b/dlls/fusion/tests/asmname.c @@ -726,7 +726,6 @@ static void test_CreateAssemblyNameObject(void) ok(name != NULL, "Expected non-NULL name\n"); size = MAX_PATH; - str[0] = '\0'; hr = IAssemblyName_GetDisplayName(name, str, &size, ASM_DISPLAYF_FULL); ok(hr == S_OK, "Expected S_OK, got %08x\n", hr); todo_wine diff --git a/dlls/gdi32/dc.c b/dlls/gdi32/dc.c index db8a91bab74..04e4942fbc9 100644 --- a/dlls/gdi32/dc.c +++ b/dlls/gdi32/dc.c @@ -252,7 +252,6 @@ void DC_InitDC( DC* dc ) SelectObject( dc->hSelf, dc->hBrush ); SelectObject( dc->hSelf, dc->hFont ); CLIPPING_UpdateGCRegion( dc ); - SetVirtualResolution( dc->hSelf, 0, 0, 0, 0 ); } @@ -284,20 +283,6 @@ static BOOL DC_InvertXform( const XFORM *xformSrc, XFORM *xformDest ) return TRUE; } -/* Construct a transformation to do the window-to-viewport conversion */ -static void construct_window_to_viewport(DC *dc, XFORM *xform) -{ - double scaleX, scaleY; - scaleX = (double)dc->vportExtX / (double)dc->wndExtX; - scaleY = (double)dc->vportExtY / (double)dc->wndExtY; - - xform->eM11 = scaleX; - xform->eM12 = 0.0; - xform->eM21 = 0.0; - xform->eM22 = scaleY; - xform->eDx = (double)dc->vportOrgX - scaleX * (double)dc->wndOrgX; - xform->eDy = (double)dc->vportOrgY - scaleY * (double)dc->wndOrgY; -} /*********************************************************************** * DC_UpdateXforms @@ -312,8 +297,19 @@ static void construct_window_to_viewport(DC *dc, XFORM *xform) void DC_UpdateXforms( DC *dc ) { XFORM xformWnd2Vport, oldworld2vport; + double scaleX, scaleY; - construct_window_to_viewport(dc, &xformWnd2Vport); + /* Construct a transformation to do the window-to-viewport conversion */ + scaleX = (double)dc->vportExtX / (double)dc->wndExtX; + scaleY = (double)dc->vportExtY / (double)dc->wndExtY; + xformWnd2Vport.eM11 = scaleX; + xformWnd2Vport.eM12 = 0.0; + xformWnd2Vport.eM21 = 0.0; + xformWnd2Vport.eM22 = scaleY; + xformWnd2Vport.eDx = (double)dc->vportOrgX - + scaleX * (double)dc->wndOrgX; + xformWnd2Vport.eDy = (double)dc->vportOrgY - + scaleY * (double)dc->wndOrgY; oldworld2vport = dc->xformWorld2Vport; /* Combine with the world transformation */ @@ -390,8 +386,6 @@ INT save_dc_state( HDC hdc ) newdc->vportOrgY = dc->vportOrgY; newdc->vportExtX = dc->vportExtX; newdc->vportExtY = dc->vportExtY; - newdc->virtual_res = dc->virtual_res; - newdc->virtual_size = dc->virtual_size; newdc->BoundsRect = dc->BoundsRect; newdc->gdiFont = dc->gdiFont; @@ -530,8 +524,6 @@ BOOL restore_dc_state( HDC hdc, INT level ) dc->vportOrgY = dcs->vportOrgY; dc->vportExtX = dcs->vportExtX; dc->vportExtY = dcs->vportExtY; - dc->virtual_res = dcs->virtual_res; - dc->virtual_size = dcs->virtual_size; if (dcs->hClipRgn) { @@ -1167,52 +1159,12 @@ BOOL WINAPI GetWorldTransform( HDC hdc, LPXFORM xform ) /*********************************************************************** * GetTransform (GDI32.@) - * - * Undocumented - * - * Returns one of the co-ordinate space transforms - * - * PARAMS - * hdc [I] Device context. - * which [I] Which xform to return: - * 0x203 World -> Page transform (that set by SetWorldTransform). - * 0x304 Page -> Device transform (the mapping mode transform). - * 0x204 World -> Device transform (the combination of the above two). - * 0x402 Device -> World transform (the inversion of the above). - * xform [O] The xform. - * */ -BOOL WINAPI GetTransform( HDC hdc, DWORD which, XFORM *xform ) +BOOL WINAPI GetTransform( HDC hdc, DWORD unknown, LPXFORM xform ) { - BOOL ret = TRUE; - DC *dc = get_dc_ptr( hdc ); - if (!dc) return FALSE; - - switch(which) - { - case 0x203: - *xform = dc->xformWorld2Wnd; - break; - - case 0x304: - construct_window_to_viewport(dc, xform); - break; - - case 0x204: - *xform = dc->xformWorld2Vport; - break; - - case 0x402: - *xform = dc->xformVport2World; - break; - - default: - FIXME("Unknown code %x\n", which); - ret = FALSE; - } - - release_dc_ptr( dc ); - return ret; + if (unknown == 0x0203) return GetWorldTransform( hdc, xform ); + FIXME("stub: don't know what to do for code %x\n", unknown ); + return FALSE; } @@ -2151,6 +2103,17 @@ BOOL WINAPI CancelDC(HDC hdc) return TRUE; } +/*********************************************************************** + * SetVirtualResolution (GDI32.@) + * + * Undocumented on msdn. Called when PowerPoint XP saves a file. + */ +DWORD WINAPI SetVirtualResolution(HDC hdc, DWORD dw2, DWORD dw3, DWORD dw4, DWORD dw5) +{ + FIXME("(%p %08x %08x %08x %08x): stub!\n", hdc, dw2, dw3, dw4, dw5); + return FALSE; +} + /******************************************************************* * GetMiterLimit [GDI32.@] * diff --git a/dlls/gdi32/dib.c b/dlls/gdi32/dib.c index 3b1ba92a5ea..086eaaea0ad 100644 --- a/dlls/gdi32/dib.c +++ b/dlls/gdi32/dib.c @@ -1120,7 +1120,7 @@ HBITMAP WINAPI CreateDIBitmap( HDC hdc, const BITMAPINFOHEADER *header, if (handle) { - if (init & CBM_INIT) + if (init == CBM_INIT) { if (SetDIBits( hdc, handle, 0, height, bits, data, coloruse ) == 0) { diff --git a/dlls/gdi32/enhmfdrv/init.c b/dlls/gdi32/enhmfdrv/init.c index dd0b89e4980..5d2453aa99a 100644 --- a/dlls/gdi32/enhmfdrv/init.c +++ b/dlls/gdi32/enhmfdrv/init.c @@ -358,8 +358,6 @@ HDC WINAPI CreateEnhMetaFileW( physDev->numcolors = GetDeviceCaps(hRefDC, NUMCOLORS); physDev->restoring = 0; - SetVirtualResolution(dc->hSelf, 0, 0, 0, 0); - physDev->emh->iType = EMR_HEADER; physDev->emh->nSize = size; diff --git a/dlls/gdi32/freetype.c b/dlls/gdi32/freetype.c index 96b197aeab6..ef934025fa3 100644 --- a/dlls/gdi32/freetype.c +++ b/dlls/gdi32/freetype.c @@ -109,6 +109,10 @@ WINE_DEFAULT_DEBUG_CHANNEL(font); #endif #ifdef HAVE_FREETYPE_FTSNAMES_H #include +#else +# ifdef HAVE_FREETYPE_FTNAMES_H +# include +# endif #endif #ifdef HAVE_FREETYPE_TTNAMEID_H #include @@ -1663,7 +1667,7 @@ static BOOL init_system_links(void) if(psub) { TRACE("%s: SystemLink entry for substituted font, ignoring\n", debugstr_w(value)); - goto next; + continue; } font_link = HeapAlloc(GetProcessHeap(), 0, sizeof(*font_link)); font_link->font_name = strdupW(value); @@ -1712,7 +1716,6 @@ static BOOL init_system_links(void) } } list_add_tail(&system_links, &font_link->entry); - next: val_len = max_val + 1; data_len = max_data; } diff --git a/dlls/gdi32/gdi_private.h b/dlls/gdi32/gdi_private.h index d7f1d9104a0..da66adee32d 100644 --- a/dlls/gdi32/gdi_private.h +++ b/dlls/gdi32/gdi_private.h @@ -263,8 +263,6 @@ typedef struct tagDC INT vportOrgY; INT vportExtX; /* Viewport extent */ INT vportExtY; - SIZE virtual_res; /* Initially HORZRES,VERTRES. Changed by SetVirtualResolution */ - SIZE virtual_size; /* Initially HORZSIZE,VERTSIZE. Changed by SetVirtualResolution */ FLOAT miterLimit; int flags; @@ -513,6 +511,4 @@ extern BOOL REGION_FrameRgn( HRGN dest, HRGN src, INT x, INT y ) DECLSPEC_HIDDEN BOOL WINAPI FontIsLinked(HDC); -BOOL WINAPI SetVirtualResolution(HDC hdc, DWORD horz_res, DWORD vert_res, DWORD horz_size, DWORD vert_size); - #endif /* __WINE_GDI_PRIVATE_H */ diff --git a/dlls/gdi32/mapping.c b/dlls/gdi32/mapping.c index e199dd3cd39..c802a102f98 100644 --- a/dlls/gdi32/mapping.c +++ b/dlls/gdi32/mapping.c @@ -37,10 +37,10 @@ WINE_DEFAULT_DEBUG_CHANNEL(dc); */ static void MAPPING_FixIsotropic( DC * dc ) { - double xdim = fabs((double)dc->vportExtX * dc->virtual_size.cx / - (dc->virtual_res.cx * dc->wndExtX)); - double ydim = fabs((double)dc->vportExtY * dc->virtual_size.cy / - (dc->virtual_res.cy * dc->wndExtY)); + double xdim = fabs((double)dc->vportExtX * GetDeviceCaps( dc->hSelf, HORZSIZE ) / + (GetDeviceCaps( dc->hSelf, HORZRES ) * dc->wndExtX)); + double ydim = fabs((double)dc->vportExtY * GetDeviceCaps( dc->hSelf, VERTSIZE ) / + (GetDeviceCaps( dc->hSelf, VERTRES ) * dc->wndExtY)); if (xdim > ydim) { @@ -137,10 +137,10 @@ INT WINAPI SetMapMode( HDC hdc, INT mode ) if (mode == dc->MapMode && (mode == MM_ISOTROPIC || mode == MM_ANISOTROPIC)) goto done; - horzSize = dc->virtual_size.cx; - vertSize = dc->virtual_size.cy; - horzRes = dc->virtual_res.cx; - vertRes = dc->virtual_res.cy; + horzSize = GetDeviceCaps( hdc, HORZSIZE ); + vertSize = GetDeviceCaps( hdc, VERTSIZE ); + horzRes = GetDeviceCaps( hdc, HORZRES ); + vertRes = GetDeviceCaps( hdc, VERTRES ); switch(mode) { case MM_TEXT: @@ -481,57 +481,3 @@ BOOL WINAPI ScaleWindowExtEx( HDC hdc, INT xNum, INT xDenom, release_dc_ptr( dc ); return ret; } - -/*********************************************************************** - * SetVirtualResolution (GDI32.@) - * - * Undocumented on msdn. - * - * Changes the values of screen size in pixels and millimeters used by - * the mapping mode functions. - * - * PARAMS - * hdc [I] Device context - * horz_res [I] Width in pixels (equivalent to HORZRES device cap). - * vert_res [I] Height in pixels (equivalent to VERTRES device cap). - * horz_size [I] Width in mm (equivalent to HORZSIZE device cap). - * vert_size [I] Height in mm (equivalent to VERTSIZE device cap). - * - * RETURNS - * TRUE if successful. - * FALSE if any (but not all) of the last four params are zero. - * - * NOTES - * This doesn't change the values returned by GetDeviceCaps, just the - * scaling of the mapping modes. - * - * Calling with the last four params equal to zero sets the values - * back to their defaults obtained by calls to GetDeviceCaps. - */ -BOOL WINAPI SetVirtualResolution(HDC hdc, DWORD horz_res, DWORD vert_res, - DWORD horz_size, DWORD vert_size) -{ - DC * dc; - TRACE("(%p %d %d %d %d)\n", hdc, horz_res, vert_res, horz_size, vert_size); - - if(horz_res == 0 && vert_res == 0 && horz_size == 0 && vert_size == 0) - { - horz_res = GetDeviceCaps(hdc, HORZRES); - vert_res = GetDeviceCaps(hdc, VERTRES); - horz_size = GetDeviceCaps(hdc, HORZSIZE); - vert_size = GetDeviceCaps(hdc, VERTSIZE); - } - else if(horz_res == 0 || vert_res == 0 || horz_size == 0 || vert_size == 0) - return FALSE; - - dc = get_dc_ptr( hdc ); - if (!dc) return FALSE; - - dc->virtual_res.cx = horz_res; - dc->virtual_res.cy = vert_res; - dc->virtual_size.cx = horz_size; - dc->virtual_size.cy = vert_size; - - release_dc_ptr( dc ); - return TRUE; -} diff --git a/dlls/gdi32/metafile.c b/dlls/gdi32/metafile.c index a14928c9832..ea75ae85183 100644 --- a/dlls/gdi32/metafile.c +++ b/dlls/gdi32/metafile.c @@ -1147,206 +1147,34 @@ UINT WINAPI GetMetaFileBitsEx( HMETAFILE hmf, UINT nSize, LPVOID buf ) return mfSize; } -#include -typedef struct -{ - DWORD magic; /* WMFC */ - WORD unk04; /* 1 */ - WORD unk06; /* 0 */ - WORD unk08; /* 0 */ - WORD unk0a; /* 1 */ - WORD checksum; - DWORD unk0e; /* 0 */ - DWORD num_chunks; - DWORD chunk_size; - DWORD remaining_size; - DWORD emf_size; - BYTE *emf_data; -} mf_comment_chunk; -#include - -static const DWORD wmfc_magic = 0x43464d57; - -/****************************************************************** - * add_mf_comment - * - * Helper for GetWinMetaFileBits - * - * Add the MFCOMMENT record[s] which is essentially a copy - * of the original emf. - */ -static BOOL add_mf_comment(HDC hdc, HENHMETAFILE emf) -{ - DWORD size = GetEnhMetaFileBits(emf, 0, NULL), i; - BYTE *bits, *chunk_data; - mf_comment_chunk *chunk = NULL; - BOOL ret = FALSE; - static const DWORD max_chunk_size = 0x2000; - - if(!size) return FALSE; - chunk_data = bits = HeapAlloc(GetProcessHeap(), 0, size); - if(!bits) return FALSE; - if(!GetEnhMetaFileBits(emf, size, bits)) goto end; - - chunk = HeapAlloc(GetProcessHeap(), 0, max_chunk_size + FIELD_OFFSET(mf_comment_chunk, emf_data)); - if(!chunk) goto end; - - chunk->magic = wmfc_magic; - chunk->unk04 = 1; - chunk->unk06 = 0; - chunk->unk08 = 0; - chunk->unk0a = 1; - chunk->checksum = 0; /* We fixup the first chunk's checksum before returning from GetWinMetaFileBits */ - chunk->unk0e = 0; - chunk->num_chunks = (size + max_chunk_size - 1) / max_chunk_size; - chunk->chunk_size = max_chunk_size; - chunk->remaining_size = size; - chunk->emf_size = size; - - for(i = 0; i < chunk->num_chunks; i++) - { - if(i == chunk->num_chunks - 1) /* last chunk */ - chunk->chunk_size = chunk->remaining_size; - - chunk->remaining_size -= chunk->chunk_size; - memcpy(&chunk->emf_data, chunk_data, chunk->chunk_size); - chunk_data += chunk->chunk_size; - - if(!Escape(hdc, MFCOMMENT, chunk->chunk_size + FIELD_OFFSET(mf_comment_chunk, emf_data), (char*)chunk, NULL)) - goto end; - } - ret = TRUE; -end: - HeapFree(GetProcessHeap(), 0, chunk); - HeapFree(GetProcessHeap(), 0, bits); - return ret; -} - -/******************************************************************* - * muldiv - * - * Behaves somewhat differently to MulDiv when the answer is -ve - * and also rounds n.5 towards zero - */ -static INT muldiv(INT m1, INT m2, INT d) -{ - LONGLONG ret; - - ret = ((LONGLONG)m1 * m2 + d/2) / d; /* Always add d/2 even if ret will be -ve */ - - if((LONGLONG)m1 * m2 * 2 == (2 * ret - 1) * d) /* If the answer is exactly n.5 round towards zero */ - { - if(ret > 0) ret--; - else ret++; - } - return ret; -} - -/****************************************************************** - * set_window - * - * Helper for GetWinMetaFileBits - * - * Add the SetWindowOrg and SetWindowExt records - */ -static BOOL set_window(HDC hdc, HENHMETAFILE emf, HDC ref_dc, INT map_mode) -{ - ENHMETAHEADER header; - INT horz_res, vert_res, horz_size, vert_size; - POINT pt; - - if(!GetEnhMetaFileHeader(emf, sizeof(header), &header)) return FALSE; - - horz_res = GetDeviceCaps(ref_dc, HORZRES); - vert_res = GetDeviceCaps(ref_dc, VERTRES); - horz_size = GetDeviceCaps(ref_dc, HORZSIZE); - vert_size = GetDeviceCaps(ref_dc, VERTSIZE); - - switch(map_mode) - { - case MM_TEXT: - case MM_ISOTROPIC: - case MM_ANISOTROPIC: - pt.y = muldiv(header.rclFrame.top, vert_res, vert_size * 100); - pt.x = muldiv(header.rclFrame.left, horz_res, horz_size * 100); - break; - case MM_LOMETRIC: - pt.y = muldiv(-header.rclFrame.top, 1, 10) + 1; - pt.x = muldiv( header.rclFrame.left, 1, 10); - break; - case MM_HIMETRIC: - pt.y = -header.rclFrame.top + 1; - pt.x = (header.rclFrame.left >= 0) ? header.rclFrame.left : header.rclFrame.left + 1; /* See the tests */ - break; - case MM_LOENGLISH: - pt.y = muldiv(-header.rclFrame.top, 10, 254) + 1; - pt.x = muldiv( header.rclFrame.left, 10, 254); - break; - case MM_HIENGLISH: - pt.y = muldiv(-header.rclFrame.top, 100, 254) + 1; - pt.x = muldiv( header.rclFrame.left, 100, 254); - break; - case MM_TWIPS: - pt.y = muldiv(-header.rclFrame.top, 72 * 20, 2540) + 1; - pt.x = muldiv( header.rclFrame.left, 72 * 20, 2540); - break; - default: - WARN("Unknown map mode %d\n", map_mode); - return FALSE; - } - SetWindowOrgEx(hdc, pt.x, pt.y, NULL); - - pt.x = muldiv(header.rclFrame.right - header.rclFrame.left, horz_res, horz_size * 100); - pt.y = muldiv(header.rclFrame.bottom - header.rclFrame.top, vert_res, vert_size * 100); - SetWindowExtEx(hdc, pt.x, pt.y, NULL); - return TRUE; -} - /****************************************************************** * GetWinMetaFileBits [GDI32.@] */ UINT WINAPI GetWinMetaFileBits(HENHMETAFILE hemf, UINT cbBuffer, LPBYTE lpbBuffer, - INT map_mode, HDC hdcRef) + INT fnMapMode, HDC hdcRef) { HDC hdcmf; HMETAFILE hmf; - UINT ret, full_size; + UINT ret; RECT rc; + INT oldMapMode; GetClipBox(hdcRef, &rc); + oldMapMode = SetMapMode(hdcRef, fnMapMode); TRACE("(%p,%d,%p,%d,%p) rc=%s\n", hemf, cbBuffer, lpbBuffer, - map_mode, hdcRef, wine_dbgstr_rect(&rc)); - - hdcmf = CreateMetaFileW(NULL); - - add_mf_comment(hdcmf, hemf); - SetMapMode(hdcmf, map_mode); - if(!set_window(hdcmf, hemf, hdcRef, map_mode)) - goto error; + fnMapMode, hdcRef, wine_dbgstr_rect(&rc)); + hdcmf = CreateMetaFileA(NULL); PlayEnhMetaFile(hdcmf, hemf, &rc); hmf = CloseMetaFile(hdcmf); - full_size = GetMetaFileBitsEx(hmf, 0, NULL); ret = GetMetaFileBitsEx(hmf, cbBuffer, lpbBuffer); DeleteMetaFile(hmf); - if(ret && ret == full_size && lpbBuffer) /* fixup checksum, but only if retrieving all of the bits */ - { - WORD checksum = 0; - METARECORD *comment_rec = (METARECORD*)(lpbBuffer + sizeof(METAHEADER)); - UINT i; + SetMapMode(hdcRef, oldMapMode); - for(i = 0; i < full_size / 2; i++) - checksum += ((WORD*)lpbBuffer)[i]; - comment_rec->rdParm[8] = ~checksum + 1; - } return ret; - -error: - DeleteMetaFile(CloseMetaFile(hdcmf)); - return 0; } /****************************************************************** diff --git a/dlls/gdi32/mfdrv/init.c b/dlls/gdi32/mfdrv/init.c index a5b18d357fc..ad29cb0cdf8 100644 --- a/dlls/gdi32/mfdrv/init.c +++ b/dlls/gdi32/mfdrv/init.c @@ -197,8 +197,6 @@ static DC *MFDRV_AllocMetaFile(void) physDev->mh->mtMaxRecord = 0; physDev->mh->mtNoParameters = 0; - SetVirtualResolution(dc->hSelf, 0, 0, 0, 0); - return dc; } diff --git a/dlls/gdi32/tests/bitmap.c b/dlls/gdi32/tests/bitmap.c index 8666da229b0..a0e767d00ac 100644 --- a/dlls/gdi32/tests/bitmap.c +++ b/dlls/gdi32/tests/bitmap.c @@ -780,9 +780,7 @@ static void test_dibsections(void) BitBlt(hdcmem2, 0, 0, 16,16, hdcmem, 0, 0, SRCCOPY); ok(bits32[0] == 0xff00, "lower left pixel is %08x\n", bits32[0]); - ok(bits32[17] == 0xff00ff || - broken(bits32[17] == 0x00ff00), /* Intermittent on Win9x/ME */ - "bottom but one, left pixel is %08x\n", bits32[17]); + ok(bits32[17] == 0xff00ff, "bottom but one, left pixel is %08x\n", bits32[17]); SelectObject(hdcmem2, oldbm2); test_dib_info(hdib2, bits32, &pbmi->bmiHeader); @@ -2252,84 +2250,6 @@ static void test_get16dibits(void) ReleaseDC(NULL, screen_dc); } -static void check_BitBlt_pixel(HDC hdcDst, HDC hdcSrc, UINT32 *dstBuffer, UINT32 *srcBuffer, - DWORD dwRop, UINT32 expected, int line) -{ - *srcBuffer = 0xFEDCBA98; - *dstBuffer = 0x89ABCDEF; - Rectangle(hdcSrc, 0, 0, 1, 1); /* A null operation to ensure dibs are coerced to X11 */ - BitBlt(hdcDst, 0, 0, 1, 1, hdcSrc, 0, 0, dwRop); - ok(expected == *dstBuffer, - "BitBlt with dwRop %06X. Expected 0x%08X, got 0x%08X from line %d\n", - dwRop, expected, *dstBuffer, line); -} - -static void test_BitBlt(void) -{ - HBITMAP bmpDst, bmpSrc; - HBITMAP oldDst, oldSrc; - HDC hdcScreen, hdcDst, hdcSrc; - UINT32 *dstBuffer, *srcBuffer; - HBRUSH hBrush, hOldBrush; - BITMAPINFO bitmapInfo; - - memset(&bitmapInfo, 0, sizeof(BITMAPINFO)); - bitmapInfo.bmiHeader.biSize = sizeof(BITMAPINFOHEADER); - bitmapInfo.bmiHeader.biWidth = 1; - bitmapInfo.bmiHeader.biHeight = 1; - bitmapInfo.bmiHeader.biPlanes = 1; - bitmapInfo.bmiHeader.biBitCount = 32; - bitmapInfo.bmiHeader.biCompression = BI_RGB; - bitmapInfo.bmiHeader.biSizeImage = sizeof(UINT32); - - hdcScreen = CreateCompatibleDC(0); - hdcDst = CreateCompatibleDC(hdcScreen); - hdcSrc = CreateCompatibleDC(hdcDst); - - /* Setup the destination dib section */ - bmpDst = CreateDIBSection(hdcScreen, &bitmapInfo, DIB_RGB_COLORS, (void**)&dstBuffer, - NULL, 0); - oldDst = SelectObject(hdcDst, bmpDst); - - hBrush = CreateSolidBrush(0x012345678); - hOldBrush = SelectObject(hdcDst, hBrush); - - /* Setup the source dib section */ - bmpSrc = CreateDIBSection(hdcScreen, &bitmapInfo, DIB_RGB_COLORS, (void**)&srcBuffer, - NULL, 0); - oldSrc = SelectObject(hdcSrc, bmpSrc); - - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, SRCCOPY, 0xFEDCBA98, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, SRCPAINT, 0xFFFFFFFF, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, SRCAND, 0x88888888, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, SRCINVERT, 0x77777777, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, SRCERASE, 0x76543210, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, NOTSRCCOPY, 0x01234567, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, NOTSRCERASE, 0x00000000, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, MERGECOPY, 0x00581210, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, MERGEPAINT, 0x89ABCDEF, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, PATCOPY, 0x00785634, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, PATPAINT, 0x89FBDFFF, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, PATINVERT, 0x89D39BDB, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, DSTINVERT, 0x76543210, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, BLACKNESS, 0x00000000, __LINE__); - check_BitBlt_pixel(hdcDst, hdcSrc, dstBuffer, srcBuffer, WHITENESS, 0xFFFFFFFF, __LINE__); - - /* Tidy up */ - SelectObject(hdcSrc, oldSrc); - DeleteObject(bmpSrc); - DeleteDC(hdcSrc); - - SelectObject(hdcDst, hOldBrush); - DeleteObject(hBrush); - SelectObject(hdcDst, oldDst); - DeleteObject(bmpDst); - DeleteDC(hdcDst); - - - DeleteDC(hdcScreen); -} - static void test_GdiAlphaBlend(void) { /* test out-of-bound parameters for GdiAlphaBlend */ @@ -2471,7 +2391,6 @@ START_TEST(bitmap) test_GetDIBits_BI_BITFIELDS(); test_select_object(); test_CreateBitmap(); - test_BitBlt(); test_GdiAlphaBlend(); test_bitmapinfoheadersize(); test_get16dibits(); diff --git a/dlls/gdi32/tests/font.c b/dlls/gdi32/tests/font.c index 6950503d1f4..88e1797bacc 100644 --- a/dlls/gdi32/tests/font.c +++ b/dlls/gdi32/tests/font.c @@ -2911,82 +2911,10 @@ static void test_GetGlyphOutline(void) DeleteDC(hdc); } -/* bug #9995: there is a limit to the character width that can be specified */ -static void test_GetTextMetrics2( const char *fontname) -{ - HFONT of, hf; - HDC hdc; - TEXTMETRICA tm; - LOGFONTA lf; - BOOL ret; - int avecharw[3], maxcharw[3]; - - if (!is_truetype_font_installed( fontname)) { - skip("%s is not installed\n", fontname); - return; - } - hdc = CreateCompatibleDC(0); - ok( hdc != NULL, "CreateCompatibleDC failed\n"); - /* select width = 0 */ - hf = CreateFontA( -11, 0, 0, 0, FW_REGULAR, FALSE, FALSE, FALSE, - DEFAULT_CHARSET, OUT_TT_PRECIS, CLIP_LH_ANGLES, - DEFAULT_QUALITY, VARIABLE_PITCH, - fontname); - ok( hf != NULL, "CreateFontA failed\n"); - of = SelectObject( hdc, hf); - ret = GetObjectA( hf, sizeof( lf), &lf); - ret = GetTextMetricsA( hdc, &tm); - ok(ret, "GetTextMetricsA error %u\n", GetLastError()); - avecharw[0] =tm.tmAveCharWidth; - maxcharw[0] =tm.tmMaxCharWidth; - SelectObject( hdc, of); - DeleteObject( hf); - /* select LARGE width = 1023 */ - hf = CreateFontA( -11, 1023, 0, 0, FW_REGULAR, FALSE, FALSE, FALSE, - DEFAULT_CHARSET, OUT_TT_PRECIS, CLIP_LH_ANGLES, - DEFAULT_QUALITY, VARIABLE_PITCH, - fontname); - ok( hf != NULL, "CreateFontA failed\n"); - of = SelectObject( hdc, hf); - ret = GetObjectA( hf, sizeof( lf), &lf); - ret = GetTextMetricsA( hdc, &tm); - ok(ret, "GetTextMetricsA error %u\n", GetLastError()); - avecharw[1] =tm.tmAveCharWidth; - maxcharw[1] =tm.tmMaxCharWidth; - SelectObject( hdc, of); - DeleteObject( hf); - /* select TOOLARGE width = 1536 */ - hf = CreateFontA( -11, 1536, 0, 0, FW_REGULAR, FALSE, FALSE, FALSE, - DEFAULT_CHARSET, OUT_TT_PRECIS, CLIP_LH_ANGLES, - DEFAULT_QUALITY, VARIABLE_PITCH, - fontname); - ok( hf != NULL, "CreateFontA failed\n"); - of = SelectObject( hdc, hf); - ret = GetObjectA( hf, sizeof( lf), &lf); - ret = GetTextMetricsA( hdc, &tm); - ok(ret, "GetTextMetricsA error %u\n", GetLastError()); - avecharw[2] =tm.tmAveCharWidth; - maxcharw[2] =tm.tmMaxCharWidth; - SelectObject( hdc, of); - DeleteObject( hf); - /* tests */ - ok( avecharw[1] > 10 * avecharw[0], "Av. charwidth not large ( %d cmp.to %d)\n", - avecharw[1], avecharw[0]); - ok( maxcharw[1] > 10 * maxcharw[0], "Max charwidth not large ( %d cmp.to %d)\n", - maxcharw[1], maxcharw[0]); -todo_wine { - ok( avecharw[2] == avecharw[0], "Unexpected Av. charwidth ( %d cmp.to %d)\n", - avecharw[2], avecharw[0]); - ok( maxcharw[2] == maxcharw[0], "Unexpected Max charwidth ( %d cmp.to %d)\n", - maxcharw[2], maxcharw[0]); -} - /* clean up */ - DeleteDC(hdc); -} - START_TEST(font) { init(); + test_logfont(); test_bitmap_font(); test_outline_font(); @@ -3021,6 +2949,4 @@ START_TEST(font) test_GdiRealizationInfo(); test_GetTextFace(); test_GetGlyphOutline(); - test_GetTextMetrics2( "Tahoma"); - test_GetTextMetrics2( "Arial"); } diff --git a/dlls/gdi32/tests/mapping.c b/dlls/gdi32/tests/mapping.c index 8c53e2fea87..03428174617 100644 --- a/dlls/gdi32/tests/mapping.c +++ b/dlls/gdi32/tests/mapping.c @@ -342,227 +342,9 @@ static void test_isotropic_mapping(void) ReleaseDC(0, hdc); } -static void test_setvirtualresolution(void) -{ - HDC hdc = CreateICA("DISPLAY", NULL, NULL, NULL); - DWORD r; - DWORD (WINAPI *pSetVirtualResolution)(HDC, DWORD, DWORD, DWORD, DWORD); - INT horz_res = GetDeviceCaps(hdc, HORZRES); - INT horz_size = GetDeviceCaps(hdc, HORZSIZE); - INT log_pixels_x = GetDeviceCaps(hdc, LOGPIXELSX); - SIZE orig_lometric_vp, orig_lometric_wnd; - - pSetVirtualResolution = (void *)GetProcAddress(GetModuleHandleA("gdi32.dll"), "SetVirtualResolution"); - - if(!pSetVirtualResolution) - { - win_skip("Don't have SetVirtualResolution\n"); - return; - } - - /* Get the true resolution limits */ - SetMapMode(hdc, MM_LOMETRIC); - GetViewportExtEx(hdc, &orig_lometric_vp); - GetWindowExtEx(hdc, &orig_lometric_wnd); - SetMapMode(hdc, MM_TEXT); - - r = pSetVirtualResolution(hdc, 4000, 1000, 400, 200); /* 10 pix/mm x 5 pix/mm */ - ok(r == TRUE, "got %d\n", r); - expect_LPtoDP(hdc, 1000, 1000); - expect_viewport_ext(hdc, 1, 1); - expect_window_ext(hdc, 1, 1); - - SetMapMode(hdc, MM_LOMETRIC); - expect_LPtoDP(hdc, 1000, -500); - expect_viewport_ext(hdc, 4000, -1000); - expect_window_ext(hdc, 4000, 2000); - - /* Doesn't change the device caps */ - ok(horz_res == GetDeviceCaps(hdc, HORZRES), "horz_res changed\n"); - ok(horz_size == GetDeviceCaps(hdc, HORZSIZE), "horz_size changed\n"); - ok(log_pixels_x == GetDeviceCaps(hdc, LOGPIXELSX), "log_pixels_x changed\n"); - - r = pSetVirtualResolution(hdc, 8000, 1000, 400, 200); /* 20 pix/mm x 5 pix/mm */ - ok(r == TRUE, "got %d\n", r); - expect_LPtoDP(hdc, 1000, -500); /* No change, need to re-set the mapping mode */ - SetMapMode(hdc, MM_TEXT); - SetMapMode(hdc, MM_LOMETRIC); - expect_LPtoDP(hdc, 2000, -500); - expect_viewport_ext(hdc, 8000, -1000); - expect_window_ext(hdc, 4000, 2000); - - r = pSetVirtualResolution(hdc, 8000, 1000, 200, 200); /* 40 pix/mm x 5 pix/mm */ - ok(r == TRUE, "got %d\n", r); - SetMapMode(hdc, MM_TEXT); - SetMapMode(hdc, MM_LOMETRIC); - expect_LPtoDP(hdc, 4000, -500); - expect_viewport_ext(hdc, 8000, -1000); - expect_window_ext(hdc, 2000, 2000); - - r = pSetVirtualResolution(hdc, 8000, 1000, 200, 200); /* 40 pix/mm x 5 pix/mm */ - ok(r == TRUE, "got %d\n", r); - SetMapMode(hdc, MM_TEXT); - SetMapMode(hdc, MM_LOMETRIC); - expect_LPtoDP(hdc, 4000, -500); - expect_viewport_ext(hdc, 8000, -1000); - expect_window_ext(hdc, 2000, 2000); - - r = pSetVirtualResolution(hdc, 8000, 2000, 200, 200); /* 40 pix/mm x 10 pix/mm */ - ok(r == TRUE, "got %d\n", r); - SetMapMode(hdc, MM_TEXT); - SetMapMode(hdc, MM_LOMETRIC); - expect_LPtoDP(hdc, 4000, -1000); - expect_viewport_ext(hdc, 8000, -2000); - expect_window_ext(hdc, 2000, 2000); - - r = pSetVirtualResolution(hdc, 0, 0, 10, 0); /* Error */ - ok(r == FALSE, "got %d\n", r); - SetMapMode(hdc, MM_TEXT); - SetMapMode(hdc, MM_LOMETRIC); - expect_LPtoDP(hdc, 4000, -1000); - expect_viewport_ext(hdc, 8000, -2000); - expect_window_ext(hdc, 2000, 2000); - - r = pSetVirtualResolution(hdc, 0, 0, 0, 0); /* Reset to true resolution */ - ok(r == TRUE, "got %d\n", r); - SetMapMode(hdc, MM_TEXT); - SetMapMode(hdc, MM_LOMETRIC); - expect_viewport_ext(hdc, orig_lometric_vp.cx, orig_lometric_vp.cy); - expect_window_ext(hdc, orig_lometric_wnd.cx, orig_lometric_wnd.cy); - - DeleteDC(hdc); -} - - -static inline void expect_identity(int line, XFORM *xf) -{ - ok(xf->eM11 == 1.0, "%d: got %f\n", line, xf->eM11); - ok(xf->eM12 == 0.0, "%d: got %f\n", line, xf->eM12); - ok(xf->eM21 == 0.0, "%d: got %f\n", line, xf->eM21); - ok(xf->eM22 == 1.0, "%d: got %f\n", line, xf->eM22); - ok(xf->eDx == 0.0, "%d: got %f\n", line, xf->eDx); - ok(xf->eDy == 0.0, "%d: got %f\n", line, xf->eDy); -} - -static inline void xform_near_match(int line, XFORM *got, XFORM *expect) -{ - ok(fabs(got->eM11 - expect->eM11) < 0.001, "%d: got %f expect %f\n", line, got->eM11, expect->eM11); - ok(fabs(got->eM12 - expect->eM12) < 0.001, "%d: got %f expect %f\n", line, got->eM12, expect->eM12); - ok(fabs(got->eM21 - expect->eM21) < 0.001, "%d: got %f expect %f\n", line, got->eM21, expect->eM21); - ok(fabs(got->eM22 - expect->eM22) < 0.001, "%d: got %f expect %f\n", line, got->eM22, expect->eM22); - ok(fabs(got->eDx - expect->eDx) < 0.001, "%d: got %f expect %f\n", line, got->eDx, expect->eDx); - ok(fabs(got->eDy - expect->eDy) < 0.001, "%d: got %f expect %f\n", line, got->eDy, expect->eDy); -} - - -static void test_gettransform(void) -{ - HDC hdc = CreateICA("DISPLAY", NULL, NULL, NULL); - BOOL (WINAPI *pGetTransform)(HDC, DWORD, XFORM *); - XFORM xform, expect; - BOOL r; - SIZE lometric_vp, lometric_wnd; - - pGetTransform = (void *)GetProcAddress(GetModuleHandleA("gdi32.dll"), "GetTransform"); - - if(!pGetTransform) - { - win_skip("Don't have GetTransform\n"); - return; - } - - r = pGetTransform(hdc, 0x203, &xform); /* World -> Page */ - ok(r == TRUE, "got %d\n", r); - expect_identity(__LINE__, &xform); - r = pGetTransform(hdc, 0x304, &xform); /* Page -> Device */ - ok(r == TRUE, "got %d\n", r); - expect_identity(__LINE__, &xform); - r = pGetTransform(hdc, 0x204, &xform); /* World -> Device */ - ok(r == TRUE, "got %d\n", r); - expect_identity(__LINE__, &xform); - r = pGetTransform(hdc, 0x402, &xform); /* Device -> World */ - ok(r == TRUE, "got %d\n", r); - expect_identity(__LINE__, &xform); - - SetMapMode(hdc, MM_LOMETRIC); - GetViewportExtEx(hdc, &lometric_vp); - GetWindowExtEx(hdc, &lometric_wnd); - - r = pGetTransform(hdc, 0x203, &xform); /* World -> Page */ - ok(r == TRUE, "got %d\n", r); - expect_identity(__LINE__, &xform); - - r = pGetTransform(hdc, 0x304, &xform); /* Page -> Device */ - ok(r == TRUE, "got %d\n", r); - expect.eM11 = (FLOAT) lometric_vp.cx / lometric_wnd.cx; - expect.eM12 = expect.eM21 = 0.0; - expect.eM22 = (FLOAT) lometric_vp.cy / lometric_wnd.cy; - expect.eDx = expect.eDy = 0.0; - xform_near_match(__LINE__, &xform, &expect); - - r = pGetTransform(hdc, 0x204, &xform); /* World -> Device */ - ok(r == TRUE, "got %d\n", r); - xform_near_match(__LINE__, &xform, &expect); - - r = pGetTransform(hdc, 0x402, &xform); /* Device -> World */ - ok(r == TRUE, "got %d\n", r); - expect.eM11 = (FLOAT) lometric_wnd.cx / lometric_vp.cx; - expect.eM22 = (FLOAT) lometric_wnd.cy / lometric_vp.cy; - xform_near_match(__LINE__, &xform, &expect); - - - SetGraphicsMode(hdc, GM_ADVANCED); - - expect.eM11 = 10.0; - expect.eM22 = 20.0; - SetWorldTransform(hdc, &expect); - r = pGetTransform(hdc, 0x203, &xform); /* World -> Page */ - ok(r == TRUE, "got %d\n", r); - xform_near_match(__LINE__, &xform, &expect); - - r = pGetTransform(hdc, 0x304, &xform); /* Page -> Device */ - ok(r == TRUE, "got %d\n", r); - expect.eM11 = (FLOAT) lometric_vp.cx / lometric_wnd.cx; - expect.eM22 = (FLOAT) lometric_vp.cy / lometric_wnd.cy; - xform_near_match(__LINE__, &xform, &expect); - - r = pGetTransform(hdc, 0x204, &xform); /* World -> Device */ - ok(r == TRUE, "got %d\n", r); - expect.eM11 *= 10.0; - expect.eM22 *= 20.0; - xform_near_match(__LINE__, &xform, &expect); - - r = pGetTransform(hdc, 0x402, &xform); /* Device -> World */ - ok(r == TRUE, "got %d\n", r); - expect.eM11 = 1 / expect.eM11; - expect.eM22 = 1 / expect.eM22; - xform_near_match(__LINE__, &xform, &expect); - - r = pGetTransform(hdc, 0x102, &xform); - ok(r == FALSE, "got %d\n", r); - r = pGetTransform(hdc, 0x103, &xform); - ok(r == FALSE, "got %d\n", r); - r = pGetTransform(hdc, 0x104, &xform); - ok(r == FALSE, "got %d\n", r); - r = pGetTransform(hdc, 0x202, &xform); - ok(r == FALSE, "got %d\n", r); - r = pGetTransform(hdc, 0x302, &xform); - ok(r == FALSE, "got %d\n", r); - r = pGetTransform(hdc, 0x303, &xform); - ok(r == FALSE, "got %d\n", r); - r = pGetTransform(hdc, 0x403, &xform); - ok(r == FALSE, "got %d\n", r); - r = pGetTransform(hdc, 0x404, &xform); - ok(r == FALSE, "got %d\n", r); - r = pGetTransform(hdc, 0xffff, &xform); - ok(r == FALSE, "got %d\n", r); -} - START_TEST(mapping) { test_modify_world_transform(); test_world_transform(); test_isotropic_mapping(); - test_setvirtualresolution(); - test_gettransform(); } diff --git a/dlls/gdi32/tests/metafile.c b/dlls/gdi32/tests/metafile.c index 15a2c631e6b..6164050cbb4 100644 --- a/dlls/gdi32/tests/metafile.c +++ b/dlls/gdi32/tests/metafile.c @@ -1457,8 +1457,8 @@ static void test_CopyMetaFile(void) if (compare_mf_disk_bits(mf_name, MF_BLANK_BITS, sizeof(MF_BLANK_BITS), "mf_blank") != 0) { - dump_mf_bits(hmf_copy, "mf_Blank"); - EnumMetaFile(0, hmf_copy, mf_enum_proc, 0); + dump_mf_bits(hMetafile, "mf_Blank"); + EnumMetaFile(0, hMetafile, mf_enum_proc, 0); } ret = DeleteMetaFile(hmf_copy); @@ -1476,7 +1476,6 @@ static void test_SetMetaFileBits(void) METAHEADER *mh; hmf = SetMetaFileBitsEx(sizeof(MF_GRAPHICS_BITS), MF_GRAPHICS_BITS); - trace("hmf %p\n", hmf); ok(hmf != 0, "SetMetaFileBitsEx error %d\n", GetLastError()); type = GetObjectType(hmf); ok(type == OBJ_METAFILE, "SetMetaFileBitsEx created object with type %d\n", type); @@ -1493,23 +1492,21 @@ static void test_SetMetaFileBits(void) /* NULL data crashes XP SP1 */ /*hmf = SetMetaFileBitsEx(sizeof(MF_GRAPHICS_BITS), NULL);*/ - /* Now with zero size */ + /* Now with not zero size */ SetLastError(0xdeadbeef); hmf = SetMetaFileBitsEx(0, MF_GRAPHICS_BITS); - trace("hmf %p\n", hmf); ok(!hmf, "SetMetaFileBitsEx should fail\n"); ok(GetLastError() == ERROR_INVALID_DATA || broken(GetLastError() == ERROR_INVALID_PARAMETER), /* Win9x */ "wrong error %d\n", GetLastError()); - /* Now with odd size */ + /* Now with not even size */ SetLastError(0xdeadbeef); hmf = SetMetaFileBitsEx(sizeof(MF_GRAPHICS_BITS) - 1, MF_GRAPHICS_BITS); - trace("hmf %p\n", hmf); ok(!hmf, "SetMetaFileBitsEx should fail\n"); ok(GetLastError() == 0xdeadbeef /* XP SP1 */, "wrong error %d\n", GetLastError()); - /* Now with zeroed out header fields */ + /* Now with zeroed out or faked some header fields */ assert(sizeof(buf) >= sizeof(MF_GRAPHICS_BITS)); memcpy(buf, MF_GRAPHICS_BITS, sizeof(MF_GRAPHICS_BITS)); mh = (METAHEADER *)buf; @@ -1519,7 +1516,6 @@ static void test_SetMetaFileBits(void) mh->mtHeaderSize = 0; SetLastError(0xdeadbeef); hmf = SetMetaFileBitsEx(sizeof(MF_GRAPHICS_BITS), buf); - trace("hmf %p\n", hmf); ok(!hmf, "SetMetaFileBitsEx should fail\n"); ok(GetLastError() == ERROR_INVALID_DATA || broken(GetLastError() == ERROR_INVALID_PARAMETER), /* Win9x */ @@ -1531,7 +1527,6 @@ static void test_SetMetaFileBits(void) /* corruption of mtSize doesn't lead to a failure */ mh->mtSize *= 2; hmf = SetMetaFileBitsEx(sizeof(MF_GRAPHICS_BITS), buf); - trace("hmf %p\n", hmf); ok(hmf != 0, "SetMetaFileBitsEx error %d\n", GetLastError()); if (compare_mf_bits(hmf, MF_GRAPHICS_BITS, sizeof(MF_GRAPHICS_BITS), "mf_Graphics") != 0) @@ -1549,7 +1544,6 @@ static void test_SetMetaFileBits(void) /* zeroing mtSize doesn't lead to a failure */ mh->mtSize = 0; hmf = SetMetaFileBitsEx(sizeof(MF_GRAPHICS_BITS), buf); - trace("hmf %p\n", hmf); ok(hmf != 0, "SetMetaFileBitsEx error %d\n", GetLastError()); if (compare_mf_bits(hmf, MF_GRAPHICS_BITS, sizeof(MF_GRAPHICS_BITS), "mf_Graphics") != 0) @@ -2308,198 +2302,6 @@ static void test_SetWinMetaFileBits(void) HeapFree(GetProcessHeap(), 0, buffer); } -static BOOL near_match(int x, int y) -{ - int epsilon = min(abs(x), abs(y)); - - epsilon = max(epsilon/100, 2); - - if(x < y - epsilon || x > y + epsilon) return FALSE; - return TRUE; -} - -static void getwinmetafilebits(UINT mode, int scale, RECT *rc) -{ - HENHMETAFILE emf; - HDC display_dc, emf_dc; - ENHMETAHEADER *enh_header; - UINT size, emf_size, i; - WORD check = 0; - DWORD rec_num = 0; - METAHEADER *mh = NULL; - METARECORD *rec; - INT horz_res, vert_res, horz_size, vert_size; - - display_dc = GetDC(NULL); - ok(display_dc != NULL, "display_dc is NULL\n"); - - horz_res = GetDeviceCaps(display_dc, HORZRES); - vert_res = GetDeviceCaps(display_dc, VERTRES); - horz_size = GetDeviceCaps(display_dc, HORZSIZE); - vert_size = GetDeviceCaps(display_dc, VERTSIZE); - - emf_dc = CreateEnhMetaFileA(display_dc, NULL, rc, NULL); - ok(emf_dc != NULL, "emf_dc is NULL\n"); - for(i = 0; i < 3000; i++) /* This is enough to take emf_size > 0xffff */ - Rectangle(emf_dc, 0, 0, 1000, 20); - emf = CloseEnhMetaFile(emf_dc); - ok(emf != NULL, "emf is NULL\n"); - - emf_size = GetEnhMetaFileBits(emf, 0, NULL); - enh_header = HeapAlloc(GetProcessHeap(), 0, emf_size); - emf_size = GetEnhMetaFileBits(emf, emf_size, (BYTE*)enh_header); - DeleteEnhMetaFile(emf); - /* multiply szlDevice.cx by scale, when scale != 1 the recording and playback dcs - have different resolutions */ - enh_header->szlDevice.cx *= scale; - emf = SetEnhMetaFileBits(emf_size, (BYTE*)enh_header); - ok(emf != NULL, "emf is NULL\n"); - ok(EqualRect((RECT*)&enh_header->rclFrame, rc), "Frame rectangles differ\n"); - - size = GetWinMetaFileBits(emf, 0, NULL, mode, display_dc); - ok(size || - broken(size == 0), /* some versions of winxp fail for some reason */ - "GetWinMetaFileBits returns 0\n"); - if(!size) goto end; - mh = HeapAlloc(GetProcessHeap(), 0, size); - GetWinMetaFileBits(emf, size, (BYTE*)mh, mode, display_dc); - - for(i = 0; i < size / 2; i++) check += ((WORD*)mh)[i]; - ok(check == 0, "check %04x\n", check); - - rec = (METARECORD*)(mh + 1); - - while(rec->rdSize && rec->rdFunction) - { - const DWORD chunk_size = 0x2000; - DWORD mfcomment_chunks = (emf_size + chunk_size - 1) / chunk_size; - - if(rec_num < mfcomment_chunks) - { - DWORD this_chunk_size = chunk_size; - - if(rec_num == mfcomment_chunks - 1) - this_chunk_size = emf_size - rec_num * chunk_size; - - ok(rec->rdSize == (this_chunk_size + 44) / 2, "%04x: got %04x expected %04x\n", rec_num, rec->rdSize, (this_chunk_size + 44) / 2); - ok(rec->rdFunction == META_ESCAPE, "%04x: got %04x\n", rec_num, rec->rdFunction); - if(rec->rdSize < (this_chunk_size + 44) / 2) break; - ok(rec->rdParm[0] == MFCOMMENT, "got %04x\n", rec->rdParm[0]); - ok(rec->rdParm[1] == this_chunk_size + 34, "got %04x %x\n", rec->rdParm[1], emf_size + 34); - ok(rec->rdParm[2] == 0x4d57, "got %04x\n", rec->rdParm[2]); /* WMFC */ - ok(rec->rdParm[3] == 0x4346, "got %04x\n", rec->rdParm[3]); /* " */ - ok(rec->rdParm[4] == 1, "got %04x\n", rec->rdParm[4]); - ok(rec->rdParm[5] == 0, "got %04x\n", rec->rdParm[5]); - ok(rec->rdParm[6] == 0, "got %04x\n", rec->rdParm[6]); - ok(rec->rdParm[7] == 1, "got %04x\n", rec->rdParm[7]); - /* parm[8] is the checksum, tested above */ - if(rec_num > 0) ok(rec->rdParm[8] == 0, "got %04x\n", rec->rdParm[8]); - ok(rec->rdParm[9] == 0, "got %04x\n", rec->rdParm[9]); - ok(rec->rdParm[10] == 0, "got %04x\n", rec->rdParm[10]); - ok(rec->rdParm[11] == mfcomment_chunks, "got %04x\n", rec->rdParm[11]); /* num chunks */ - ok(rec->rdParm[12] == 0, "got %04x\n", rec->rdParm[12]); - ok(rec->rdParm[13] == this_chunk_size, "got %04x expected %04x\n", rec->rdParm[13], this_chunk_size); - ok(rec->rdParm[14] == 0, "got %04x\n", rec->rdParm[14]); - ok(*(DWORD*)(rec->rdParm + 15) == emf_size - this_chunk_size - rec_num * chunk_size, "got %08x\n", *(DWORD*)(rec->rdParm + 15)); /* DWORD size remaining after current chunk */ - ok(*(DWORD*)(rec->rdParm + 17) == emf_size, "got %08x emf_size %08x\n", *(DWORD*)(rec->rdParm + 17), emf_size); - ok(!memcmp(rec->rdParm + 19, (char*)enh_header + rec_num * chunk_size, this_chunk_size), "bits mismatch\n"); - } - - else if(rec_num == mfcomment_chunks) - { - ok(rec->rdFunction == META_SETMAPMODE, "got %04x\n", rec->rdFunction); - ok(rec->rdParm[0] == mode, "got %04x\n", rec->rdParm[0]); - } - else if(rec_num == mfcomment_chunks + 1) - { - POINT pt; - ok(rec->rdFunction == META_SETWINDOWORG, "got %04x\n", rec->rdFunction); - switch(mode) - { - case MM_TEXT: - case MM_ISOTROPIC: - case MM_ANISOTROPIC: - pt.y = MulDiv(rc->top, vert_res, vert_size * 100) + 1; - pt.x = MulDiv(rc->left, horz_res, horz_size * 100); - break; - case MM_LOMETRIC: - pt.y = MulDiv(-rc->top, 1, 10) + 1; - pt.x = MulDiv( rc->left, 1, 10); - break; - case MM_HIMETRIC: - pt.y = -rc->top + 1; - pt.x = (rc->left >= 0) ? rc->left : rc->left + 1; /* strange but true */ - break; - case MM_LOENGLISH: - pt.y = MulDiv(-rc->top, 10, 254) + 1; - pt.x = MulDiv( rc->left, 10, 254); - break; - case MM_HIENGLISH: - pt.y = MulDiv(-rc->top, 100, 254) + 1; - pt.x = MulDiv( rc->left, 100, 254); - break; - case MM_TWIPS: - pt.y = MulDiv(-rc->top, 72 * 20, 2540) + 1; - pt.x = MulDiv( rc->left, 72 * 20, 2540); - break; - default: - pt.x = pt.y = 0; - } - ok(near_match((short)rec->rdParm[0], pt.y), "got %d expect %d\n", (short)rec->rdParm[0], pt.y); - ok(near_match((short)rec->rdParm[1], pt.x), "got %d expect %d\n", (short)rec->rdParm[1], pt.x); - } - if(rec_num == mfcomment_chunks + 2) - { - ok(rec->rdFunction == META_SETWINDOWEXT, "got %04x\n", rec->rdFunction); - ok(near_match((short)rec->rdParm[0], MulDiv(rc->bottom - rc->top, vert_res, vert_size * 100)), - "got %d\n", (short)rec->rdParm[0]); - ok(near_match((short)rec->rdParm[1], MulDiv(rc->right - rc->left, horz_res, horz_size * 100)), - "got %d\n", (short)rec->rdParm[1]); - } - - rec_num++; - rec = (METARECORD*)((WORD*)rec + rec->rdSize); - } - -end: - HeapFree(GetProcessHeap(), 0, mh); - HeapFree(GetProcessHeap(), 0, enh_header); - DeleteEnhMetaFile(emf); - - ReleaseDC(NULL, display_dc); -} - -static void test_GetWinMetaFileBits(void) -{ - UINT mode; - RECT frames[] = - { - { 1000, 2000, 3000, 6000}, - {-1000, 2000, 3000, 6000}, - { 1000, -2000, 3000, 6000}, - { 1005, 2005, 3000, 6000}, - {-1005, -2005, 3000, 6000}, - {-1005, -2010, 3000, 6000}, - {-1005, 2010, 3000, 6000}, - { 0, 0, 1, 1}, - { -1, -1, 1, 1}, - { 0, 0, 0, 0} - }; - - for(mode = MM_MIN; mode <= MM_MAX; mode++) - { - RECT *rc; - trace("mode %d\n", mode); - - for(rc = frames; rc->right - rc->left > 0; rc++) - { - trace("frame %d,%d - %d,%d\n", rc->left, rc->top, rc->right, rc->bottom); - getwinmetafilebits(mode, 1, rc); - getwinmetafilebits(mode, 2, rc); - } - } -} - static BOOL (WINAPI *pGdiIsMetaPrintDC)(HDC); static BOOL (WINAPI *pGdiIsMetaFileDC)(HDC); static BOOL (WINAPI *pGdiIsPlayMetafileDC)(HDC); @@ -2623,7 +2425,6 @@ START_TEST(metafile) /* For metafile conversions */ test_mf_conversions(); test_SetWinMetaFileBits(); - test_GetWinMetaFileBits(); test_gdiis(); test_SetEnhMetaFileBits(); diff --git a/dlls/gdiplus/brush.c b/dlls/gdiplus/brush.c index bb19e4399c2..824ece0fc85 100644 --- a/dlls/gdiplus/brush.c +++ b/dlls/gdiplus/brush.c @@ -1531,33 +1531,12 @@ GpStatus WINGDIPAPI GdipRotateTextureTransform(GpTexture* brush, REAL angle, GpStatus WINGDIPAPI GdipSetLineLinearBlend(GpLineGradient *brush, REAL focus, REAL scale) { - REAL factors[3]; - REAL positions[3]; - int num_points = 0; - - TRACE("(%p,%.2f,%.2f)\n", brush, focus, scale); - - if (!brush) return InvalidParameter; - - if (focus != 0.0) - { - factors[num_points] = 0.0; - positions[num_points] = 0.0; - num_points++; - } - - factors[num_points] = scale; - positions[num_points] = focus; - num_points++; + static int calls; - if (focus != 1.0) - { - factors[num_points] = 0.0; - positions[num_points] = 1.0; - num_points++; - } + if(!(calls++)) + FIXME("not implemented\n"); - return GdipSetLineBlend(brush, factors, positions, num_points); + return NotImplemented; } GpStatus WINGDIPAPI GdipSetLinePresetBlend(GpLineGradient *brush, diff --git a/dlls/gdiplus/gdiplus.spec b/dlls/gdiplus/gdiplus.spec index 008841d867e..03c9629d2d8 100644 --- a/dlls/gdiplus/gdiplus.spec +++ b/dlls/gdiplus/gdiplus.spec @@ -165,8 +165,8 @@ @ stdcall GdipDrawClosedCurveI(ptr ptr ptr long) @ stdcall GdipDrawCurve2(ptr ptr ptr long long) @ stdcall GdipDrawCurve2I(ptr ptr ptr long long) -@ stdcall GdipDrawCurve3(ptr ptr ptr long long long long) -@ stdcall GdipDrawCurve3I(ptr ptr ptr long long long long) +@ stub GdipDrawCurve3 +@ stub GdipDrawCurve3I @ stdcall GdipDrawCurve(ptr ptr ptr long) @ stdcall GdipDrawCurveI(ptr ptr ptr long) @ stdcall GdipDrawDriverString(ptr ptr long ptr ptr ptr long ptr) @@ -432,7 +432,7 @@ @ stub GdipIsVisibleRect @ stub GdipIsVisibleRectI @ stub GdipIsVisibleRegionPoint -@ stdcall GdipIsVisibleRegionPointI(ptr long long ptr ptr) +@ stub GdipIsVisibleRegionPointI @ stub GdipIsVisibleRegionRect @ stub GdipIsVisibleRegionRectI @ stdcall GdipLoadImageFromFile(wstr ptr) diff --git a/dlls/gdiplus/gdiplus_private.h b/dlls/gdiplus/gdiplus_private.h index be881c71dc8..95133ca2d88 100644 --- a/dlls/gdiplus/gdiplus_private.h +++ b/dlls/gdiplus/gdiplus_private.h @@ -29,7 +29,6 @@ #include "objbase.h" #include "ocidl.h" -#include "wine/list.h" #include "gdiplus.h" @@ -110,8 +109,6 @@ struct GpGraphics{ BOOL busy; /* hdc handle obtained by GdipGetDC */ GpRegion *clip; UINT textcontrast; /* not used yet. get/set only */ - struct list containers; - GraphicsContainer contid; /* last-issued container ID */ }; struct GpBrush{ diff --git a/dlls/gdiplus/graphics.c b/dlls/gdiplus/graphics.c index 58ca2e6eeb2..a9adac1637d 100644 --- a/dlls/gdiplus/graphics.c +++ b/dlls/gdiplus/graphics.c @@ -38,7 +38,6 @@ #include "gdiplus.h" #include "gdiplus_private.h" #include "wine/debug.h" -#include "wine/list.h" WINE_DEFAULT_DEBUG_CHANNEL(gdiplus); @@ -942,104 +941,6 @@ GpStatus trace_path(GpGraphics *graphics, GpPath *path) return result; } -typedef struct _GraphicsContainerItem { - struct list entry; - GraphicsContainer contid; - - SmoothingMode smoothing; - CompositingQuality compqual; - InterpolationMode interpolation; - CompositingMode compmode; - TextRenderingHint texthint; - REAL scale; - GpUnit unit; - PixelOffsetMode pixeloffset; - UINT textcontrast; - GpMatrix* worldtrans; - GpRegion* clip; -} GraphicsContainerItem; - -static GpStatus init_container(GraphicsContainerItem** container, - GDIPCONST GpGraphics* graphics){ - GpStatus sts; - - *container = GdipAlloc(sizeof(GraphicsContainerItem)); - if(!(*container)) - return OutOfMemory; - - (*container)->contid = graphics->contid + 1; - - (*container)->smoothing = graphics->smoothing; - (*container)->compqual = graphics->compqual; - (*container)->interpolation = graphics->interpolation; - (*container)->compmode = graphics->compmode; - (*container)->texthint = graphics->texthint; - (*container)->scale = graphics->scale; - (*container)->unit = graphics->unit; - (*container)->textcontrast = graphics->textcontrast; - (*container)->pixeloffset = graphics->pixeloffset; - - sts = GdipCloneMatrix(graphics->worldtrans, &(*container)->worldtrans); - if(sts != Ok){ - GdipFree(*container); - *container = NULL; - return sts; - } - - sts = GdipCloneRegion(graphics->clip, &(*container)->clip); - if(sts != Ok){ - GdipDeleteMatrix((*container)->worldtrans); - GdipFree(*container); - *container = NULL; - return sts; - } - - return Ok; -} - -static void delete_container(GraphicsContainerItem* container){ - GdipDeleteMatrix(container->worldtrans); - GdipDeleteRegion(container->clip); - GdipFree(container); -} - -static GpStatus restore_container(GpGraphics* graphics, - GDIPCONST GraphicsContainerItem* container){ - GpStatus sts; - GpMatrix *newTrans; - GpRegion *newClip; - - sts = GdipCloneMatrix(container->worldtrans, &newTrans); - if(sts != Ok) - return sts; - - sts = GdipCloneRegion(container->clip, &newClip); - if(sts != Ok){ - GdipDeleteMatrix(newTrans); - return sts; - } - - GdipDeleteMatrix(graphics->worldtrans); - graphics->worldtrans = newTrans; - - GdipDeleteRegion(graphics->clip); - graphics->clip = newClip; - - graphics->contid = container->contid - 1; - - graphics->smoothing = container->smoothing; - graphics->compqual = container->compqual; - graphics->interpolation = container->interpolation; - graphics->compmode = container->compmode; - graphics->texthint = container->texthint; - graphics->scale = container->scale; - graphics->unit = container->unit; - graphics->textcontrast = container->textcontrast; - graphics->pixeloffset = container->pixeloffset; - - return Ok; -} - GpStatus WINGDIPAPI GdipCreateFromHDC(HDC hdc, GpGraphics **graphics) { TRACE("(%p, %p)\n", hdc, graphics); @@ -1090,8 +991,6 @@ GpStatus WINGDIPAPI GdipCreateFromHDC2(HDC hdc, HANDLE hDevice, GpGraphics **gra (*graphics)->scale = 1.0; (*graphics)->busy = FALSE; (*graphics)->textcontrast = 4; - list_init(&(*graphics)->containers); - (*graphics)->contid = 0; return Ok; } @@ -1256,7 +1155,6 @@ GpStatus WINGDIPAPI GdipCreateStreamOnFile(GDIPCONST WCHAR * filename, GpStatus WINGDIPAPI GdipDeleteGraphics(GpGraphics *graphics) { - GraphicsContainerItem *cont, *next; TRACE("(%p)\n", graphics); if(!graphics) return InvalidParameter; @@ -1265,11 +1163,6 @@ GpStatus WINGDIPAPI GdipDeleteGraphics(GpGraphics *graphics) if(graphics->owndc) ReleaseDC(graphics->hwnd, graphics->hdc); - LIST_FOR_EACH_ENTRY_SAFE(cont, next, &graphics->containers, GraphicsContainerItem, entry){ - list_remove(&cont->entry); - delete_container(cont); - } - GdipDeleteRegion(graphics->clip); GdipDeleteMatrix(graphics->worldtrans); GdipFree(graphics); @@ -1530,7 +1423,7 @@ GpStatus WINGDIPAPI GdipDrawCurveI(GpGraphics *graphics, GpPen *pen, TRACE("(%p, %p, %p, %d)\n", graphics, pen, points, count); - if(!points) + if(!points || count <= 0) return InvalidParameter; pointsF = GdipAlloc(sizeof(GpPointF)*count); @@ -1621,7 +1514,7 @@ GpStatus WINGDIPAPI GdipDrawCurve2I(GpGraphics *graphics, GpPen *pen, TRACE("(%p, %p, %p, %d, %.2f)\n", graphics, pen, points, count, tension); - if(!points) + if(!points || count <= 0) return InvalidParameter; pointsF = GdipAlloc(sizeof(GpPointF)*count); @@ -1639,36 +1532,6 @@ GpStatus WINGDIPAPI GdipDrawCurve2I(GpGraphics *graphics, GpPen *pen, return ret; } -GpStatus WINGDIPAPI GdipDrawCurve3(GpGraphics *graphics, GpPen *pen, - GDIPCONST GpPointF *points, INT count, INT offset, INT numberOfSegments, - REAL tension) -{ - TRACE("(%p, %p, %p, %d, %d, %d, %.2f)\n", graphics, pen, points, count, offset, numberOfSegments, tension); - - if(offset >= count || numberOfSegments > count - offset - 1 || numberOfSegments <= 0){ - return InvalidParameter; - } - - return GdipDrawCurve2(graphics, pen, points + offset, numberOfSegments + 1, tension); -} - -GpStatus WINGDIPAPI GdipDrawCurve3I(GpGraphics *graphics, GpPen *pen, - GDIPCONST GpPoint *points, INT count, INT offset, INT numberOfSegments, - REAL tension) -{ - TRACE("(%p, %p, %p, %d, %d, %d, %.2f)\n", graphics, pen, points, count, offset, numberOfSegments, tension); - - if(count < 0){ - return OutOfMemory; - } - - if(offset >= count || numberOfSegments > count - offset - 1 || numberOfSegments <= 0){ - return InvalidParameter; - } - - return GdipDrawCurve2I(graphics, pen, points + offset, numberOfSegments + 1, tension); -} - GpStatus WINGDIPAPI GdipDrawEllipse(GpGraphics *graphics, GpPen *pen, REAL x, REAL y, REAL width, REAL height) { @@ -2235,8 +2098,6 @@ GpStatus WINGDIPAPI GdipDrawString(GpGraphics *graphics, GDIPCONST WCHAR *string INT sum = 0, height = 0, offsety = 0, fit, fitcpy, save_state, i, j, lret, nwidth, nheight; SIZE size; - POINT drawbase; - UINT drawflags; RECT drawcoord; TRACE("(%p, %s, %i, %p, %s, %p, %p)\n", graphics, debugstr_wn(string, length), @@ -2346,35 +2207,17 @@ GpStatus WINGDIPAPI GdipDrawString(GpGraphics *graphics, GDIPCONST WCHAR *string length = j; - if (!format || format->align == StringAlignmentNear) - { - drawbase.x = corners[0].x; - drawbase.y = corners[0].y; - drawflags = DT_NOCLIP | DT_EXPANDTABS; - } - else if (format->align == StringAlignmentCenter) - { - drawbase.x = (corners[0].x + corners[1].x)/2; - drawbase.y = (corners[0].y + corners[1].y)/2; - drawflags = DT_NOCLIP | DT_EXPANDTABS | DT_CENTER; - } - else /* (format->align == StringAlignmentFar) */ - { - drawbase.x = corners[1].x; - drawbase.y = corners[1].y; - drawflags = DT_NOCLIP | DT_EXPANDTABS | DT_RIGHT; - } - while(sum < length){ - drawcoord.left = drawcoord.right = drawbase.x + roundr(ang_sin * (REAL) height); - drawcoord.top = drawcoord.bottom = drawbase.y + roundr(ang_cos * (REAL) height); + drawcoord.left = corners[0].x + roundr(ang_sin * (REAL) height); + drawcoord.top = corners[0].y + roundr(ang_cos * (REAL) height); GetTextExtentExPointW(graphics->hdc, stringdup + sum, length - sum, nwidth, &fit, NULL, &size); fitcpy = fit; if(fit == 0){ - DrawTextW(graphics->hdc, stringdup + sum, 1, &drawcoord, drawflags); + DrawTextW(graphics->hdc, stringdup + sum, 1, &drawcoord, DT_NOCLIP | + DT_EXPANDTABS); break; } @@ -2403,7 +2246,7 @@ GpStatus WINGDIPAPI GdipDrawString(GpGraphics *graphics, GDIPCONST WCHAR *string } } DrawTextW(graphics->hdc, stringdup + sum, min(length - sum, fit), - &drawcoord, drawflags); + &drawcoord, DT_NOCLIP | DT_EXPANDTABS); sum += fit + (lret < fitcpy ? 1 : 0); height += size.cy; @@ -2512,14 +2355,12 @@ GpStatus WINGDIPAPI GdipFillEllipse(GpGraphics *graphics, GpBrush *brush, REAL x save_state = SaveDC(graphics->hdc); EndPath(graphics->hdc); + SelectObject(graphics->hdc, brush->gdibrush); + SelectObject(graphics->hdc, GetStockObject(NULL_PEN)); transform_and_round_points(graphics, pti, ptf, 2); - BeginPath(graphics->hdc); Ellipse(graphics->hdc, pti[0].x, pti[0].y, pti[1].x, pti[1].y); - EndPath(graphics->hdc); - - brush_fill_path(graphics, brush); RestoreDC(graphics->hdc, save_state); @@ -2586,12 +2427,10 @@ GpStatus WINGDIPAPI GdipFillPie(GpGraphics *graphics, GpBrush *brush, REAL x, save_state = SaveDC(graphics->hdc); EndPath(graphics->hdc); + SelectObject(graphics->hdc, brush->gdibrush); + SelectObject(graphics->hdc, GetStockObject(NULL_PEN)); - BeginPath(graphics->hdc); draw_pie(graphics, x, y, width, height, startAngle, sweepAngle); - EndPath(graphics->hdc); - - brush_fill_path(graphics, brush); RestoreDC(graphics->hdc, save_state); @@ -2634,16 +2473,13 @@ GpStatus WINGDIPAPI GdipFillPolygon(GpGraphics *graphics, GpBrush *brush, save_state = SaveDC(graphics->hdc); EndPath(graphics->hdc); + SelectObject(graphics->hdc, brush->gdibrush); + SelectObject(graphics->hdc, GetStockObject(NULL_PEN)); SetPolyFillMode(graphics->hdc, (fillMode == FillModeAlternate ? ALTERNATE : WINDING)); transform_and_round_points(graphics, pti, ptf, count); - - BeginPath(graphics->hdc); Polygon(graphics->hdc, pti, count); - EndPath(graphics->hdc); - - brush_fill_path(graphics, brush); RestoreDC(graphics->hdc, save_state); @@ -2684,16 +2520,13 @@ GpStatus WINGDIPAPI GdipFillPolygonI(GpGraphics *graphics, GpBrush *brush, save_state = SaveDC(graphics->hdc); EndPath(graphics->hdc); + SelectObject(graphics->hdc, brush->gdibrush); + SelectObject(graphics->hdc, GetStockObject(NULL_PEN)); SetPolyFillMode(graphics->hdc, (fillMode == FillModeAlternate ? ALTERNATE : WINDING)); transform_and_round_points(graphics, pti, ptf, count); - - BeginPath(graphics->hdc); Polygon(graphics->hdc, pti, count); - EndPath(graphics->hdc); - - brush_fill_path(graphics, brush); RestoreDC(graphics->hdc, save_state); @@ -2786,14 +2619,12 @@ GpStatus WINGDIPAPI GdipFillRectangleI(GpGraphics *graphics, GpBrush *brush, save_state = SaveDC(graphics->hdc); EndPath(graphics->hdc); + SelectObject(graphics->hdc, brush->gdibrush); + SelectObject(graphics->hdc, GetStockObject(NULL_PEN)); transform_and_round_points(graphics, pti, ptf, 4); - BeginPath(graphics->hdc); Polygon(graphics->hdc, pti, 4); - EndPath(graphics->hdc); - - brush_fill_path(graphics, brush); RestoreDC(graphics->hdc, save_state); @@ -2857,7 +2688,6 @@ GpStatus WINGDIPAPI GdipFillRegion(GpGraphics* graphics, GpBrush* brush, INT save_state; GpStatus status; HRGN hrgn; - RECT rc; TRACE("(%p, %p, %p)\n", graphics, brush, region); @@ -2873,17 +2703,9 @@ GpStatus WINGDIPAPI GdipFillRegion(GpGraphics* graphics, GpBrush* brush, save_state = SaveDC(graphics->hdc); EndPath(graphics->hdc); + SelectObject(graphics->hdc, GetStockObject(NULL_PEN)); - ExtSelectClipRgn(graphics->hdc, hrgn, RGN_AND); - - if (GetClipBox(graphics->hdc, &rc) != NULLREGION) - { - BeginPath(graphics->hdc); - Rectangle(graphics->hdc, rc.left, rc.top, rc.right, rc.bottom); - EndPath(graphics->hdc); - - brush_fill_path(graphics, brush); - } + FillRgn(graphics->hdc, hrgn, brush->gdibrush); RestoreDC(graphics->hdc, save_state); @@ -3343,7 +3165,15 @@ GpStatus WINGDIPAPI GdipResetWorldTransform(GpGraphics *graphics) GpStatus WINGDIPAPI GdipRestoreGraphics(GpGraphics *graphics, GraphicsState state) { - return GdipEndContainer(graphics, state); + static int calls; + + if(!graphics) + return InvalidParameter; + + if(!(calls++)) + FIXME("graphics state not implemented\n"); + + return Ok; } GpStatus WINGDIPAPI GdipRotateWorldTransform(GpGraphics *graphics, REAL angle, @@ -3362,27 +3192,26 @@ GpStatus WINGDIPAPI GdipRotateWorldTransform(GpGraphics *graphics, REAL angle, GpStatus WINGDIPAPI GdipSaveGraphics(GpGraphics *graphics, GraphicsState *state) { - return GdipBeginContainer2(graphics, state); + static int calls; + + if(!graphics || !state) + return InvalidParameter; + + if(!(calls++)) + FIXME("graphics state not implemented\n"); + + *state = 0xdeadbeef; + return Ok; } -GpStatus WINGDIPAPI GdipBeginContainer2(GpGraphics *graphics, - GraphicsContainer *state) +GpStatus WINGDIPAPI GdipBeginContainer2(GpGraphics *graphics, GraphicsContainer *state) { - GraphicsContainerItem *container; - GpStatus sts; - - TRACE("(%p, %p)\n", graphics, state); + FIXME("(%p, %p)\n", graphics, state); if(!graphics || !state) return InvalidParameter; - sts = init_container(&container, graphics); - if(sts != Ok) - return sts; - - list_add_head(&graphics->containers, &container->entry); - *state = graphics->contid = container->contid; - + *state = 0xdeadbeef; return Ok; } @@ -3404,40 +3233,13 @@ GpStatus WINGDIPAPI GdipComment(GpGraphics *graphics, UINT sizeData, GDIPCONST B return NotImplemented; } -GpStatus WINGDIPAPI GdipEndContainer(GpGraphics *graphics, GraphicsContainer state) +GpStatus WINGDIPAPI GdipEndContainer(GpGraphics *graphics, GraphicsState state) { - GpStatus sts; - GraphicsContainerItem *container, *container2; - - TRACE("(%p, %x)\n", graphics, state); + FIXME("(%p, 0x%x)\n", graphics, state); - if(!graphics) + if(!graphics || !state) return InvalidParameter; - LIST_FOR_EACH_ENTRY(container, &graphics->containers, GraphicsContainerItem, entry){ - if(container->contid == state) - break; - } - - /* did not find a matching container */ - if(&container->entry == &graphics->containers) - return Ok; - - sts = restore_container(graphics, container); - if(sts != Ok) - return sts; - - /* remove all of the containers on top of the found container */ - LIST_FOR_EACH_ENTRY_SAFE(container, container2, &graphics->containers, GraphicsContainerItem, entry){ - if(container->contid == state) - break; - list_remove(&container->entry); - delete_container(container); - } - - list_remove(&container->entry); - delete_container(container); - return Ok; } @@ -4076,12 +3878,3 @@ GpStatus WINGDIPAPI GdipDrawDriverString(GpGraphics *graphics, GDIPCONST UINT16 FIXME("(%p %p %d %p %p %p %d %p): stub\n", graphics, text, length, font, brush, positions, flags, matrix); return NotImplemented; } - -/***************************************************************************** - * GdipIsVisibleRegionPointI [GDIPLUS.@] - */ -GpStatus WINGDIPAPI GdipIsVisibleRegionPointI(GpRegion *region, INT x, INT y, GpGraphics *graphics, BOOL *result) -{ - FIXME("(%p %d %d %p %p): stub\n", region, x, y, graphics, result); - return NotImplemented; -} diff --git a/dlls/gdiplus/image.c b/dlls/gdiplus/image.c index a603adba223..6df104ec54f 100644 --- a/dlls/gdiplus/image.c +++ b/dlls/gdiplus/image.c @@ -449,7 +449,7 @@ GpStatus WINGDIPAPI GdipCreateHBITMAPFromBitmap(GpBitmap* bitmap, { FIXME("stub\n"); - if (hbmReturn) *hbmReturn = NULL; + hbmReturn = NULL; return NotImplemented; } diff --git a/dlls/gdiplus/tests/brush.c b/dlls/gdiplus/tests/brush.c index 7993d60cfd4..b6fbe3044ef 100644 --- a/dlls/gdiplus/tests/brush.c +++ b/dlls/gdiplus/tests/brush.c @@ -493,71 +493,6 @@ static void test_lineblend(void) expect(Ok, status); } -static void test_linelinearblend(void) -{ - GpLineGradient *brush; - GpStatus status; - GpPointF pt1, pt2; - INT count=10; - REAL res_factors[3] = {0.3f}; - REAL res_positions[3] = {0.3f}; - - status = GdipSetLineLinearBlend(NULL, 0.6, 0.8); - expect(InvalidParameter, status); - - pt1.X = pt1.Y = 1.0; - pt2.X = pt2.Y = 100.0; - status = GdipCreateLineBrush(&pt1, &pt2, 0, 0, WrapModeTile, &brush); - expect(Ok, status); - - - status = GdipSetLineLinearBlend(brush, 0.6, 0.8); - expect(Ok, status); - - status = GdipGetLineBlendCount(brush, &count); - expect(Ok, status); - expect(3, count); - - status = GdipGetLineBlend(brush, res_factors, res_positions, 3); - expect(Ok, status); - expectf(0.0, res_factors[0]); - expectf(0.0, res_positions[0]); - expectf(0.8, res_factors[1]); - expectf(0.6, res_positions[1]); - expectf(0.0, res_factors[2]); - expectf(1.0, res_positions[2]); - - - status = GdipSetLineLinearBlend(brush, 0.0, 0.8); - expect(Ok, status); - - status = GdipGetLineBlendCount(brush, &count); - expect(Ok, status); - expect(2, count); - - status = GdipGetLineBlend(brush, res_factors, res_positions, 3); - expect(Ok, status); - expectf(0.8, res_factors[0]); - expectf(0.0, res_positions[0]); - expectf(0.0, res_factors[1]); - expectf(1.0, res_positions[1]); - - - status = GdipSetLineLinearBlend(brush, 1.0, 0.8); - expect(Ok, status); - - status = GdipGetLineBlendCount(brush, &count); - expect(Ok, status); - expect(2, count); - - status = GdipGetLineBlend(brush, res_factors, res_positions, 3); - expect(Ok, status); - expectf(0.0, res_factors[0]); - expectf(0.0, res_positions[0]); - expectf(0.8, res_factors[1]); - expectf(1.0, res_positions[1]); -} - START_TEST(brush) { struct GdiplusStartupInput gdiplusStartupInput; @@ -580,7 +515,6 @@ START_TEST(brush) test_texturewrap(); test_gradientgetrect(); test_lineblend(); - test_linelinearblend(); GdiplusShutdown(gdiplusToken); } diff --git a/dlls/gdiplus/tests/graphics.c b/dlls/gdiplus/tests/graphics.c index 6fd49f73f42..668d2618e55 100644 --- a/dlls/gdiplus/tests/graphics.c +++ b/dlls/gdiplus/tests/graphics.c @@ -137,7 +137,8 @@ static void test_save_restore(void) stat = GdipRestoreGraphics(graphics1, state_a); expect(Ok, stat); GdipGetInterpolationMode(graphics1, &mode); - expect(InterpolationModeBilinear, mode); + todo_wine + expect(InterpolationModeBilinear, mode); GdipDeleteGraphics(graphics1); log_state(state_a, &state_log); @@ -153,10 +154,12 @@ static void test_save_restore(void) expect(Ok, stat); GdipRestoreGraphics(graphics1, state_b); GdipGetInterpolationMode(graphics1, &mode); - expect(InterpolationModeBicubic, mode); + todo_wine + expect(InterpolationModeBicubic, mode); GdipRestoreGraphics(graphics1, state_a); GdipGetInterpolationMode(graphics1, &mode); - expect(InterpolationModeBilinear, mode); + todo_wine + expect(InterpolationModeBilinear, mode); GdipDeleteGraphics(graphics1); log_state(state_a, &state_log); @@ -173,13 +176,16 @@ static void test_save_restore(void) GdipSetInterpolationMode(graphics1, InterpolationModeHighQualityBilinear); GdipRestoreGraphics(graphics1, state_b); GdipGetInterpolationMode(graphics1, &mode); - expect(InterpolationModeBicubic, mode); + todo_wine + expect(InterpolationModeBicubic, mode); GdipRestoreGraphics(graphics1, state_c); GdipGetInterpolationMode(graphics1, &mode); - expect(InterpolationModeBicubic, mode); + todo_wine + expect(InterpolationModeBicubic, mode); GdipRestoreGraphics(graphics1, state_a); GdipGetInterpolationMode(graphics1, &mode); - expect(InterpolationModeBilinear, mode); + todo_wine + expect(InterpolationModeBilinear, mode); GdipDeleteGraphics(graphics1); log_state(state_a, &state_log); @@ -198,10 +204,12 @@ static void test_save_restore(void) GdipSetInterpolationMode(graphics2, InterpolationModeNearestNeighbor); GdipRestoreGraphics(graphics1, state_a); GdipGetInterpolationMode(graphics1, &mode); - expect(InterpolationModeBilinear, mode); + todo_wine + expect(InterpolationModeBilinear, mode); GdipRestoreGraphics(graphics2, state_b); GdipGetInterpolationMode(graphics2, &mode); - expect(InterpolationModeBicubic, mode); + todo_wine + expect(InterpolationModeBicubic, mode); GdipDeleteGraphics(graphics1); GdipDeleteGraphics(graphics2); @@ -235,6 +243,8 @@ static void test_GdipDrawArc(void) HDC hdc = GetDC(0); /* make a graphics object and pen object */ + status = GdipCreateFromHDC(hdc, &graphics); + expect(Ok, status); ok(hdc != NULL, "Expected HDC to be initialized\n"); status = GdipCreateFromHDC(hdc, &graphics); @@ -279,6 +289,8 @@ static void test_GdipDrawArcI(void) HDC hdc = GetDC(0); /* make a graphics object and pen object */ + status = GdipCreateFromHDC(hdc, &graphics); + expect(Ok, status); ok(hdc != NULL, "Expected HDC to be initialized\n"); status = GdipCreateFromHDC(hdc, &graphics); @@ -315,191 +327,6 @@ static void test_GdipDrawArcI(void) ReleaseDC(0, hdc); } -static void test_BeginContainer2(void) -{ - GpMatrix *transform; - GpRectF clip; - REAL defClip[] = {5, 10, 15, 20}; - REAL elems[6], defTrans[] = {1, 2, 3, 4, 5, 6}; - GraphicsContainer cont1, cont2, cont3, cont4; - CompositingQuality compqual, defCompqual = CompositingQualityHighSpeed; - CompositingMode compmode, defCompmode = CompositingModeSourceOver; - InterpolationMode interp, defInterp = InterpolationModeHighQualityBicubic; - REAL scale, defScale = 17; - GpUnit unit, defUnit = UnitPixel; - PixelOffsetMode offsetmode, defOffsetmode = PixelOffsetModeHighSpeed; - SmoothingMode smoothmode, defSmoothmode = SmoothingModeAntiAlias; - UINT contrast, defContrast = 5; - TextRenderingHint texthint, defTexthint = TextRenderingHintAntiAlias; - - GpStatus status; - GpGraphics *graphics = NULL; - HDC hdc = GetDC(0); - - ok(hdc != NULL, "Expected HDC to be initialized\n"); - - status = GdipCreateFromHDC(hdc, &graphics); - expect(Ok, status); - ok(graphics != NULL, "Expected graphics to be initialized\n"); - - /* null graphics, null container */ - status = GdipBeginContainer2(NULL, &cont1); - expect(InvalidParameter, status); - - status = GdipBeginContainer2(graphics, NULL); - expect(InvalidParameter, status); - - status = GdipEndContainer(NULL, cont1); - expect(InvalidParameter, status); - - /* test all quality-related values */ - GdipSetCompositingMode(graphics, defCompmode); - GdipSetCompositingQuality(graphics, defCompqual); - GdipSetInterpolationMode(graphics, defInterp); - GdipSetPageScale(graphics, defScale); - GdipSetPageUnit(graphics, defUnit); - GdipSetPixelOffsetMode(graphics, defOffsetmode); - GdipSetSmoothingMode(graphics, defSmoothmode); - GdipSetTextContrast(graphics, defContrast); - GdipSetTextRenderingHint(graphics, defTexthint); - - status = GdipBeginContainer2(graphics, &cont1); - expect(Ok, status); - - GdipSetCompositingMode(graphics, CompositingModeSourceCopy); - GdipSetCompositingQuality(graphics, CompositingQualityHighQuality); - GdipSetInterpolationMode(graphics, InterpolationModeBilinear); - GdipSetPageScale(graphics, 10); - GdipSetPageUnit(graphics, UnitDocument); - GdipSetPixelOffsetMode(graphics, PixelOffsetModeHalf); - GdipSetSmoothingMode(graphics, SmoothingModeNone); - GdipSetTextContrast(graphics, 7); - GdipSetTextRenderingHint(graphics, TextRenderingHintClearTypeGridFit); - - status = GdipEndContainer(graphics, cont1); - expect(Ok, status); - - GdipGetCompositingMode(graphics, &compmode); - ok(defCompmode == compmode, "Expected Compositing Mode to be restored to %d, got %d\n", defCompmode, compmode); - - GdipGetCompositingQuality(graphics, &compqual); - ok(defCompqual == compqual, "Expected Compositing Quality to be restored to %d, got %d\n", defCompqual, compqual); - - GdipGetInterpolationMode(graphics, &interp); - ok(defInterp == interp, "Expected Interpolation Mode to be restored to %d, got %d\n", defInterp, interp); - - GdipGetPageScale(graphics, &scale); - ok(fabs(defScale - scale) < 0.0001, "Expected Page Scale to be restored to %f, got %f\n", defScale, scale); - - GdipGetPageUnit(graphics, &unit); - ok(defUnit == unit, "Expected Page Unit to be restored to %d, got %d\n", defUnit, unit); - - GdipGetPixelOffsetMode(graphics, &offsetmode); - ok(defOffsetmode == offsetmode, "Expected Pixel Offset Mode to be restored to %d, got %d\n", defOffsetmode, offsetmode); - - GdipGetSmoothingMode(graphics, &smoothmode); - ok(defSmoothmode == smoothmode, "Expected Smoothing Mode to be restored to %d, got %d\n", defSmoothmode, smoothmode); - - GdipGetTextContrast(graphics, &contrast); - ok(defContrast == contrast, "Expected Text Contrast to be restored to %d, got %d\n", defContrast, contrast); - - GdipGetTextRenderingHint(graphics, &texthint); - ok(defTexthint == texthint, "Expected Text Hint to be restored to %d, got %d\n", defTexthint, texthint); - - /* test world transform */ - status = GdipBeginContainer2(graphics, &cont1); - expect(Ok, status); - - GdipCreateMatrix2(defTrans[0], defTrans[1], defTrans[2], defTrans[3], - defTrans[4], defTrans[5], &transform); - GdipSetWorldTransform(graphics, transform); - GdipDeleteMatrix(transform); - transform = NULL; - - status = GdipBeginContainer2(graphics, &cont2); - expect(Ok, status); - - GdipCreateMatrix2(10, 20, 30, 40, 50, 60, &transform); - GdipSetWorldTransform(graphics, transform); - GdipDeleteMatrix(transform); - transform = NULL; - - status = GdipEndContainer(graphics, cont2); - expect(Ok, status); - - GdipCreateMatrix(&transform); - GdipGetWorldTransform(graphics, transform); - GdipGetMatrixElements(transform, elems); - ok(fabs(defTrans[0] - elems[0]) < 0.0001 && - fabs(defTrans[1] - elems[1]) < 0.0001 && - fabs(defTrans[2] - elems[2]) < 0.0001 && - fabs(defTrans[3] - elems[3]) < 0.0001 && - fabs(defTrans[4] - elems[4]) < 0.0001 && - fabs(defTrans[5] - elems[5]) < 0.0001, - "Expected World Transform Matrix to be restored to [%f, %f, %f, %f, %f, %f], got [%f, %f, %f, %f, %f, %f]\n", - defTrans[0], defTrans[1], defTrans[2], defTrans[3], defTrans[4], defTrans[5], - elems[0], elems[1], elems[2], elems[3], elems[4], elems[5]); - GdipDeleteMatrix(transform); - transform = NULL; - - status = GdipEndContainer(graphics, cont1); - expect(Ok, status); - - /* test clipping */ - status = GdipBeginContainer2(graphics, &cont1); - expect(Ok, status); - - GdipSetClipRect(graphics, defClip[0], defClip[1], defClip[2], defClip[3], CombineModeReplace); - - status = GdipBeginContainer2(graphics, &cont2); - expect(Ok, status); - - GdipSetClipRect(graphics, 2, 4, 6, 8, CombineModeReplace); - - status = GdipEndContainer(graphics, cont2); - - GdipGetClipBounds(graphics, &clip); - todo_wine ok(fabs(defClip[0] - clip.X) < 0.0001 && - fabs(defClip[1] - clip.Y) < 0.0001 && - fabs(defClip[2] - clip.Width) < 0.0001 && - fabs(defClip[3] - clip.Height) < 0.0001, - "Expected Clipping Rectangle to be restored to [%f, %f, %f, %f], got [%f, %f, %f, %f]\n", - defClip[0], defClip[1], defClip[2], defClip[3], - clip.X, clip.Y, clip.Width, clip.Height); - - status = GdipEndContainer(graphics, cont1); - - /* nesting */ - status = GdipBeginContainer2(graphics, &cont1); - expect(Ok, status); - - status = GdipBeginContainer2(graphics, &cont2); - expect(Ok, status); - - status = GdipBeginContainer2(graphics, &cont3); - expect(Ok, status); - - status = GdipEndContainer(graphics, cont3); - expect(Ok, status); - - status = GdipBeginContainer2(graphics, &cont4); - expect(Ok, status); - - status = GdipEndContainer(graphics, cont4); - expect(Ok, status); - - /* skip cont2 */ - status = GdipEndContainer(graphics, cont1); - expect(Ok, status); - - /* end an already-ended container */ - status = GdipEndContainer(graphics, cont1); - expect(Ok, status); - - GdipDeleteGraphics(graphics); - ReleaseDC(0, hdc); -} - static void test_GdipDrawBezierI(void) { GpStatus status; @@ -508,6 +335,8 @@ static void test_GdipDrawBezierI(void) HDC hdc = GetDC(0); /* make a graphics object and pen object */ + status = GdipCreateFromHDC(hdc, &graphics); + expect(Ok, status); ok(hdc != NULL, "Expected HDC to be initialized\n"); status = GdipCreateFromHDC(hdc, &graphics); @@ -538,300 +367,6 @@ static void test_GdipDrawBezierI(void) ReleaseDC(0, hdc); } -static void test_GdipDrawCurve3(void) -{ - GpStatus status; - GpGraphics *graphics = NULL; - GpPen *pen = NULL; - HDC hdc = GetDC(0); - GpPointF points[3]; - - points[0].X = 0; - points[0].Y = 0; - - points[1].X = 40; - points[1].Y = 20; - - points[2].X = 10; - points[2].Y = 40; - - /* make a graphics object and pen object */ - ok(hdc != NULL, "Expected HDC to be initialized\n"); - - status = GdipCreateFromHDC(hdc, &graphics); - expect(Ok, status); - ok(graphics != NULL, "Expected graphics to be initialized\n"); - - status = GdipCreatePen1((ARGB)0xffff00ff, 10.0f, UnitPixel, &pen); - expect(Ok, status); - ok(pen != NULL, "Expected pen to be initialized\n"); - - /* InvalidParameter cases: null graphics, null pen */ - status = GdipDrawCurve3(NULL, NULL, points, 3, 0, 2, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve3(graphics, NULL, points, 3, 0, 2, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve3(NULL, pen, points, 3, 0, 2, 1); - expect(InvalidParameter, status); - - /* InvalidParameter cases: invalid count */ - status = GdipDrawCurve3(graphics, pen, points, -1, 0, 2, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve3(graphics, pen, points, 0, 0, 2, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve3(graphics, pen, points, 1, 0, 0, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve3(graphics, pen, points, 3, 4, 2, 1); - expect(InvalidParameter, status); - - /* InvalidParameter cases: invalid number of segments */ - status = GdipDrawCurve3(graphics, pen, points, 3, 0, -1, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve3(graphics, pen, points, 3, 1, 2, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve3(graphics, pen, points, 2, 0, 2, 1); - expect(InvalidParameter, status); - - /* Valid test cases */ - status = GdipDrawCurve3(graphics, pen, points, 2, 0, 1, 1); - expect(Ok, status); - - status = GdipDrawCurve3(graphics, pen, points, 3, 0, 2, 2); - expect(Ok, status); - - status = GdipDrawCurve3(graphics, pen, points, 2, 0, 1, -2); - expect(Ok, status); - - status = GdipDrawCurve3(graphics, pen, points, 3, 1, 1, 0); - expect(Ok, status); - - GdipDeletePen(pen); - GdipDeleteGraphics(graphics); - - ReleaseDC(0, hdc); -} - -static void test_GdipDrawCurve3I(void) -{ - GpStatus status; - GpGraphics *graphics = NULL; - GpPen *pen = NULL; - HDC hdc = GetDC(0); - GpPoint points[3]; - - points[0].X = 0; - points[0].Y = 0; - - points[1].X = 40; - points[1].Y = 20; - - points[2].X = 10; - points[2].Y = 40; - - /* make a graphics object and pen object */ - ok(hdc != NULL, "Expected HDC to be initialized\n"); - - status = GdipCreateFromHDC(hdc, &graphics); - expect(Ok, status); - ok(graphics != NULL, "Expected graphics to be initialized\n"); - - status = GdipCreatePen1((ARGB)0xffff00ff, 10.0f, UnitPixel, &pen); - expect(Ok, status); - ok(pen != NULL, "Expected pen to be initialized\n"); - - /* InvalidParameter cases: null graphics, null pen */ - status = GdipDrawCurve3I(NULL, NULL, points, 3, 0, 2, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve3I(graphics, NULL, points, 3, 0, 2, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve3I(NULL, pen, points, 3, 0, 2, 1); - expect(InvalidParameter, status); - - /* InvalidParameter cases: invalid count */ - status = GdipDrawCurve3I(graphics, pen, points, -1, -1, -1, 1); - expect(OutOfMemory, status); - - status = GdipDrawCurve3I(graphics, pen, points, 0, 0, 2, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve3I(graphics, pen, points, 1, 0, 0, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve3I(graphics, pen, points, 3, 4, 2, 1); - expect(InvalidParameter, status); - - /* InvalidParameter cases: invalid number of segments */ - status = GdipDrawCurve3I(graphics, pen, points, 3, 0, -1, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve3I(graphics, pen, points, 3, 1, 2, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve3I(graphics, pen, points, 2, 0, 2, 1); - expect(InvalidParameter, status); - - /* Valid test cases */ - status = GdipDrawCurve3I(graphics, pen, points, 2, 0, 1, 1); - expect(Ok, status); - - status = GdipDrawCurve3I(graphics, pen, points, 3, 0, 2, 2); - expect(Ok, status); - - status = GdipDrawCurve3I(graphics, pen, points, 2, 0, 1, -2); - expect(Ok, status); - - status = GdipDrawCurve3I(graphics, pen, points, 3, 1, 1, 0); - expect(Ok, status); - - GdipDeletePen(pen); - GdipDeleteGraphics(graphics); - - ReleaseDC(0, hdc); -} - -static void test_GdipDrawCurve2(void) -{ - GpStatus status; - GpGraphics *graphics = NULL; - GpPen *pen = NULL; - HDC hdc = GetDC(0); - GpPointF points[3]; - - points[0].X = 0; - points[0].Y = 0; - - points[1].X = 40; - points[1].Y = 20; - - points[2].X = 10; - points[2].Y = 40; - - /* make a graphics object and pen object */ - ok(hdc != NULL, "Expected HDC to be initialized\n"); - - status = GdipCreateFromHDC(hdc, &graphics); - expect(Ok, status); - ok(graphics != NULL, "Expected graphics to be initialized\n"); - - status = GdipCreatePen1((ARGB)0xffff00ff, 10.0f, UnitPixel, &pen); - expect(Ok, status); - ok(pen != NULL, "Expected pen to be initialized\n"); - - /* InvalidParameter cases: null graphics, null pen */ - status = GdipDrawCurve2(NULL, NULL, points, 3, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve2(graphics, NULL, points, 3, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve2(NULL, pen, points, 3, 1); - expect(InvalidParameter, status); - - /* InvalidParameter cases: invalid count */ - status = GdipDrawCurve2(graphics, pen, points, -1, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve2(graphics, pen, points, 0, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve2(graphics, pen, points, 1, 1); - expect(InvalidParameter, status); - - /* Valid test cases */ - status = GdipDrawCurve2(graphics, pen, points, 2, 1); - expect(Ok, status); - - status = GdipDrawCurve2(graphics, pen, points, 3, 2); - expect(Ok, status); - - status = GdipDrawCurve2(graphics, pen, points, 3, -2); - expect(Ok, status); - - status = GdipDrawCurve2(graphics, pen, points, 3, 0); - expect(Ok, status); - - GdipDeletePen(pen); - GdipDeleteGraphics(graphics); - - ReleaseDC(0, hdc); -} - -static void test_GdipDrawCurve2I(void) -{ - GpStatus status; - GpGraphics *graphics = NULL; - GpPen *pen = NULL; - HDC hdc = GetDC(0); - GpPoint points[3]; - - points[0].X = 0; - points[0].Y = 0; - - points[1].X = 40; - points[1].Y = 20; - - points[2].X = 10; - points[2].Y = 40; - - /* make a graphics object and pen object */ - ok(hdc != NULL, "Expected HDC to be initialized\n"); - - status = GdipCreateFromHDC(hdc, &graphics); - expect(Ok, status); - ok(graphics != NULL, "Expected graphics to be initialized\n"); - - status = GdipCreatePen1((ARGB)0xffff00ff, 10.0f, UnitPixel, &pen); - expect(Ok, status); - ok(pen != NULL, "Expected pen to be initialized\n"); - - /* InvalidParameter cases: null graphics, null pen */ - status = GdipDrawCurve2I(NULL, NULL, points, 3, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve2I(graphics, NULL, points, 3, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve2I(NULL, pen, points, 3, 1); - expect(InvalidParameter, status); - - /* InvalidParameter cases: invalid count */ - status = GdipDrawCurve2I(graphics, pen, points, -1, 1); - expect(OutOfMemory, status); - - status = GdipDrawCurve2I(graphics, pen, points, 0, 1); - expect(InvalidParameter, status); - - status = GdipDrawCurve2I(graphics, pen, points, 1, 1); - expect(InvalidParameter, status); - - /* Valid test cases */ - status = GdipDrawCurve2I(graphics, pen, points, 2, 1); - expect(Ok, status); - - status = GdipDrawCurve2I(graphics, pen, points, 3, 2); - expect(Ok, status); - - status = GdipDrawCurve2I(graphics, pen, points, 3, -2); - expect(Ok, status); - - status = GdipDrawCurve2I(graphics, pen, points, 3, 0); - expect(Ok, status); - - GdipDeletePen(pen); - GdipDeleteGraphics(graphics); - - ReleaseDC(0, hdc); -} - static void test_GdipDrawCurve(void) { GpStatus status; @@ -893,75 +428,16 @@ static void test_GdipDrawCurve(void) ReleaseDC(0, hdc); } -static void test_GdipDrawCurveI(void) +static void test_GdipDrawLineI(void) { GpStatus status; GpGraphics *graphics = NULL; GpPen *pen = NULL; HDC hdc = GetDC(0); - GpPoint points[3]; - - points[0].X = 0; - points[0].Y = 0; - - points[1].X = 40; - points[1].Y = 20; - - points[2].X = 10; - points[2].Y = 40; /* make a graphics object and pen object */ - ok(hdc != NULL, "Expected HDC to be initialized\n"); - status = GdipCreateFromHDC(hdc, &graphics); expect(Ok, status); - ok(graphics != NULL, "Expected graphics to be initialized\n"); - - status = GdipCreatePen1((ARGB)0xffff00ff, 10.0f, UnitPixel, &pen); - expect(Ok, status); - ok(pen != NULL, "Expected pen to be initialized\n"); - - /* InvalidParameter cases: null graphics, null pen */ - status = GdipDrawCurveI(NULL, NULL, points, 3); - expect(InvalidParameter, status); - - status = GdipDrawCurveI(graphics, NULL, points, 3); - expect(InvalidParameter, status); - - status = GdipDrawCurveI(NULL, pen, points, 3); - expect(InvalidParameter, status); - - /* InvalidParameter cases: invalid count */ - status = GdipDrawCurveI(graphics, pen, points, -1); - expect(OutOfMemory, status); - - status = GdipDrawCurveI(graphics, pen, points, 0); - expect(InvalidParameter, status); - - status = GdipDrawCurveI(graphics, pen, points, 1); - expect(InvalidParameter, status); - - /* Valid test cases */ - status = GdipDrawCurveI(graphics, pen, points, 2); - expect(Ok, status); - - status = GdipDrawCurveI(graphics, pen, points, 3); - expect(Ok, status); - - GdipDeletePen(pen); - GdipDeleteGraphics(graphics); - - ReleaseDC(0, hdc); -} - -static void test_GdipDrawLineI(void) -{ - GpStatus status; - GpGraphics *graphics = NULL; - GpPen *pen = NULL; - HDC hdc = GetDC(0); - - /* make a graphics object and pen object */ ok(hdc != NULL, "Expected HDC to be initialized\n"); status = GdipCreateFromHDC(hdc, &graphics); @@ -1001,6 +477,8 @@ static void test_GdipDrawLinesI(void) HDC hdc = GetDC(0); /* make a graphics object and pen object */ + status = GdipCreateFromHDC(hdc, &graphics); + expect(Ok, status); ok(hdc != NULL, "Expected HDC to be initialized\n"); status = GdipCreateFromHDC(hdc, &graphics); @@ -1679,16 +1157,10 @@ START_TEST(graphics) test_GdipDrawArc(); test_GdipDrawArcI(); test_GdipDrawCurve(); - test_GdipDrawCurveI(); - test_GdipDrawCurve2(); - test_GdipDrawCurve2I(); - test_GdipDrawCurve3(); - test_GdipDrawCurve3I(); test_GdipDrawLineI(); test_GdipDrawLinesI(); test_GdipDrawString(); test_Get_Release_DC(); - test_BeginContainer2(); test_transformpoints(); test_get_set_clip(); test_isempty(); diff --git a/dlls/gphoto2.ds/Makefile.in b/dlls/gphoto2.ds/Makefile.in index 3c1b3be75f0..5e45e8ed3ab 100644 --- a/dlls/gphoto2.ds/Makefile.in +++ b/dlls/gphoto2.ds/Makefile.in @@ -14,21 +14,7 @@ C_SRCS = \ ui.c RC_SRCS = \ - gphoto2_Da.rc \ - gphoto2_De.rc \ - gphoto2_En.rc \ - gphoto2_Es.rc \ - gphoto2_Fr.rc \ - gphoto2_Ko.rc \ - gphoto2_Lt.rc \ - gphoto2_Nl.rc \ - gphoto2_No.rc \ - gphoto2_Pl.rc \ - gphoto2_Pt.rc \ - gphoto2_Ru.rc \ - gphoto2_Si.rc \ - gphoto2_Sv.rc \ - gphoto2_Zh.rc + rsrc.rc @MAKE_DLL_RULES@ diff --git a/dlls/gphoto2.ds/gphoto2_Da.rc b/dlls/gphoto2.ds/gphoto2_Da.rc index 8859398e1cf..e8ef872b551 100644 --- a/dlls/gphoto2.ds/gphoto2_Da.rc +++ b/dlls/gphoto2.ds/gphoto2_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT IDD_CAMERAUI DIALOG DISCARDABLE 0, 0, 372, 273 diff --git a/dlls/gphoto2.ds/gphoto2_De.rc b/dlls/gphoto2.ds/gphoto2_De.rc index ab1f9d284cd..ee17d6f4a11 100644 --- a/dlls/gphoto2.ds/gphoto2_De.rc +++ b/dlls/gphoto2.ds/gphoto2_De.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL IDD_CAMERAUI DIALOG DISCARDABLE 0, 0, 372, 273 @@ -33,7 +29,7 @@ FONT 8, "MS Sans Serif" BEGIN CONTROL "List1",IDC_LIST1,"SysListView32", LVS_ICON | WS_BORDER | WS_TABSTOP,7,7,358,229 - DEFPUSHBUTTON "Gewählte importieren",IDC_IMPORT,152,252,72,14 + DEFPUSHBUTTON "Gewählte importieren",IDC_IMPORT,152,252,72,14 PUSHBUTTON "Preview",IDC_FETCH,7,252,64,14 PUSHBUTTON "Alle importieren",IDC_IMPORTALL,80,252,64,14 CONTROL "Skip This Dialog",IDC_SKIP,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,230,252,76,14 @@ -42,10 +38,10 @@ END IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE | DS_CENTER | DS_SETFOREGROUND -CAPTION "Übertragung" +CAPTION "Übertragung" FONT 8, "MS Sans Serif" BEGIN - LTEXT "Übertrage... Bitte Warten",IDC_STATIC,5,19,176,8, SS_CENTER + LTEXT "Übertrage... Bitte Warten",IDC_STATIC,5,19,176,8, SS_CENTER END IDD_CONNECTING DIALOG DISCARDABLE 0, 0, 280, 116 diff --git a/dlls/gphoto2.ds/gphoto2_En.rc b/dlls/gphoto2.ds/gphoto2_En.rc index 37577e86794..5b486500fad 100644 --- a/dlls/gphoto2.ds/gphoto2_En.rc +++ b/dlls/gphoto2.ds/gphoto2_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT IDD_CAMERAUI DIALOG DISCARDABLE 0, 0, 372, 273 diff --git a/dlls/gphoto2.ds/gphoto2_Es.rc b/dlls/gphoto2.ds/gphoto2_Es.rc index 3f377fd9c07..99fc7d88fa7 100644 --- a/dlls/gphoto2.ds/gphoto2_Es.rc +++ b/dlls/gphoto2.ds/gphoto2_Es.rc @@ -18,9 +18,6 @@ * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ - -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL @@ -58,3 +55,5 @@ BEGIN LTEXT "Conectando a la cámara... Por favor espere",IDC_STATIC,128,58, 116,8 END + +#pragma code_page(default) diff --git a/dlls/gphoto2.ds/gphoto2_Fr.rc b/dlls/gphoto2.ds/gphoto2_Fr.rc index 39267e3885a..bd52e237531 100644 --- a/dlls/gphoto2.ds/gphoto2_Fr.rc +++ b/dlls/gphoto2.ds/gphoto2_Fr.rc @@ -2,7 +2,6 @@ * French resources for Twain * * Copyright 2006 Jonathan Ernst - * Copyright 2009 Frédéric Delanoy * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -19,26 +18,21 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL IDD_CAMERAUI DIALOG DISCARDABLE 0, 0, 372, 273 STYLE DS_MODALFRAME | DS_SETFOREGROUND | DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Fichiers sur l'appareil photo" +CAPTION "Files on Camera" MENU 20545 FONT 8, "MS Sans Serif" BEGIN CONTROL "List1",IDC_LIST1,"SysListView32", LVS_ICON | WS_BORDER | WS_TABSTOP,7,7,358,229 - DEFPUSHBUTTON "Importer la sélection",IDC_IMPORT,152,252,72,14 - PUSHBUTTON "Prévisualiser",IDC_FETCH,7,252,64,14 - PUSHBUTTON "Tout importer",IDC_IMPORTALL,80,252,64,14 - CONTROL "Sauter ce dialogue",IDC_SKIP,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,230,252,76,14 + DEFPUSHBUTTON "Importer la sélection",IDC_IMPORT,152,252,72,14 + PUSHBUTTON "Preview",IDC_FETCH,7,252,64,14 + PUSHBUTTON "Importer tous",IDC_IMPORTALL,80,252,64,14 + CONTROL "Skip This Dialog",IDC_SKIP,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,230,252,76,14 PUSHBUTTON "Fermer",IDC_EXIT,315,252,50,14 END @@ -52,10 +46,10 @@ END IDD_CONNECTING DIALOG DISCARDABLE 0, 0, 280, 116 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU| WS_VISIBLE | DS_CENTER -CAPTION "Connexion à l'appareil photo" +CAPTION "Connexion à l'appareil photo" FONT 8, "MS Sans Serif" BEGIN CONTROL "",IDC_BITMAP,"Static",SS_BITMAP|SS_CENTERIMAGE,4,4,110,110 - LTEXT "Connexion à l'appareil photo... Veuillez patienter",IDC_STATIC,128,58, + LTEXT "Connexion à l'appareil photo... Veuillez patienter",IDC_STATIC,128,58, 116,8 END diff --git a/dlls/gphoto2.ds/gphoto2_Ko.rc b/dlls/gphoto2.ds/gphoto2_Ko.rc index 8ea0a190310..2a61cff371b 100644 --- a/dlls/gphoto2.ds/gphoto2_Ko.rc +++ b/dlls/gphoto2.ds/gphoto2_Ko.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT IDD_CAMERAUI DIALOG DISCARDABLE 0, 0, 372, 273 diff --git a/dlls/gphoto2.ds/gphoto2_Lt.rc b/dlls/gphoto2.ds/gphoto2_Lt.rc index c87dd77a0a4..de2a525a154 100644 --- a/dlls/gphoto2.ds/gphoto2_Lt.rc +++ b/dlls/gphoto2.ds/gphoto2_Lt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -58,3 +56,5 @@ BEGIN LTEXT "Jungiamasi prie kameros... Prašome palaukti",IDC_STATIC,124,58, 140,8 END + +#pragma code_page(default) diff --git a/dlls/gphoto2.ds/gphoto2_Nl.rc b/dlls/gphoto2.ds/gphoto2_Nl.rc index 83acb70327b..9527467b868 100644 --- a/dlls/gphoto2.ds/gphoto2_Nl.rc +++ b/dlls/gphoto2.ds/gphoto2_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL IDD_CAMERAUI DIALOG DISCARDABLE 0, 0, 372, 273 diff --git a/dlls/gphoto2.ds/gphoto2_No.rc b/dlls/gphoto2.ds/gphoto2_No.rc index 7cc01767bde..b3cb0d85280 100644 --- a/dlls/gphoto2.ds/gphoto2_No.rc +++ b/dlls/gphoto2.ds/gphoto2_No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL IDD_CAMERAUI DIALOG DISCARDABLE 0, 0, 372, 273 diff --git a/dlls/gphoto2.ds/gphoto2_Pl.rc b/dlls/gphoto2.ds/gphoto2_Pl.rc index 4177328cfbf..3c98599c952 100644 --- a/dlls/gphoto2.ds/gphoto2_Pl.rc +++ b/dlls/gphoto2.ds/gphoto2_Pl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT IDD_CAMERAUI DIALOG DISCARDABLE 0, 0, 372, 273 diff --git a/dlls/gphoto2.ds/gphoto2_Pt.rc b/dlls/gphoto2.ds/gphoto2_Pt.rc index 7e131f30f85..fc4194e4c81 100644 --- a/dlls/gphoto2.ds/gphoto2_Pt.rc +++ b/dlls/gphoto2.ds/gphoto2_Pt.rc @@ -18,42 +18,38 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE +LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL IDD_CAMERAUI DIALOG DISCARDABLE 0, 0, 372, 273 STYLE DS_MODALFRAME | DS_SETFOREGROUND | DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Ficheiros na Câmara" +CAPTION "Ficheiros na Câmara" MENU 20545 FONT 8, "MS Sans Serif" BEGIN CONTROL "List1",IDC_LIST1,"SysListView32", LVS_ICON | WS_BORDER | WS_TABSTOP,7,7,358,229 DEFPUSHBUTTON "Importar Seleccionado",IDC_IMPORT,152,252,72,14 - PUSHBUTTON "Pré-visualizar",IDC_FETCH,7,252,64,14 + PUSHBUTTON "Pré-visualizar",IDC_FETCH,7,252,64,14 PUSHBUTTON "Importar tudo",IDC_IMPORTALL,80,252,64,14 - CONTROL "Passar à frente",IDC_SKIP,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,230,252,76,14 + CONTROL "Passar à frente",IDC_SKIP,"Botão", BS_AUTOCHECKBOX | WS_TABSTOP,230,252,76,14 PUSHBUTTON "Sair",IDC_EXIT,315,252,50,14 END IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE | DS_CENTER | DS_SETFOREGROUND -CAPTION "A transferir" +CAPTION "Transferindo" FONT 8, "MS Sans Serif" BEGIN - LTEXT "A transferir... Por favor espere",IDC_STATIC,5,19,176,8, SS_CENTER + LTEXT "Transferindo... Por favor espere",IDC_STATIC,5,19,176,8, SS_CENTER END IDD_CONNECTING DIALOG DISCARDABLE 0, 0, 280, 116 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU| WS_VISIBLE | DS_CENTER -CAPTION "A ligar à câmara" +CAPTION "A ligar à câmara" FONT 8, "MS Sans Serif" BEGIN - CONTROL "",IDC_BITMAP,"Static",SS_BITMAP|SS_CENTERIMAGE,4,4,110,110 - LTEXT "A ligar à câmara... Por favor espere",IDC_STATIC,128,58, + CONTROL "",IDC_BITMAP,"Estático",SS_BITMAP|SS_CENTERIMAGE,4,4,110,110 + LTEXT "A ligar à câmara... Por favor espere",IDC_STATIC,128,58, 116,8 END diff --git a/dlls/gphoto2.ds/gphoto2_Ru.rc b/dlls/gphoto2.ds/gphoto2_Ru.rc index 563b0afa2ba..891e116cfb6 100644 --- a/dlls/gphoto2.ds/gphoto2_Ru.rc +++ b/dlls/gphoto2.ds/gphoto2_Ru.rc @@ -18,40 +18,35 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT IDD_CAMERAUI DIALOG DISCARDABLE 0, 0, 372, 273 STYLE DS_MODALFRAME | DS_SETFOREGROUND | DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Файлы в камере" +CAPTION "Ôàéëû â êàìåðå" MENU 20545 FONT 8, "MS Sans Serif" BEGIN - CONTROL "Список1",IDC_LIST1,"SysListView32", LVS_ICON | WS_BORDER | WS_TABSTOP,7,7,358,229 - DEFPUSHBUTTON "Загрузить выбранные",IDC_IMPORT,152,252,72,14 - PUSHBUTTON "Просмотр",IDC_FETCH,7,252,64,14 - PUSHBUTTON "Загрузить все",IDC_IMPORTALL,80,252,64,14 - CONTROL "Больше не спрашивать",IDC_SKIP,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,230,252,76,14 - PUSHBUTTON "Выход",IDC_EXIT,315,252,50,14 + CONTROL "Ñïèñîê1",IDC_LIST1,"SysListView32", LVS_ICON | WS_BORDER | WS_TABSTOP,7,7,358,229 + DEFPUSHBUTTON "Çàãðóçèòü âûáðàííûå",IDC_IMPORT,152,252,72,14 + PUSHBUTTON "Ïðîñìîòð",IDC_FETCH,7,252,64,14 + PUSHBUTTON "Çàãðóçèòü âñå",IDC_IMPORTALL,80,252,64,14 + CONTROL "Áîëüøå íå ñïðàøèâàòü",IDC_SKIP,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,230,252,76,14 + PUSHBUTTON "Âûõîä",IDC_EXIT,315,252,50,14 END IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE | DS_CENTER | DS_SETFOREGROUND -CAPTION "Загрузка" +CAPTION "Çàãðóçêà" FONT 8, "MS Sans Serif" BEGIN - LTEXT "Загрузка... Ждите",IDC_STATIC,5,19,176,8, SS_CENTER + LTEXT "Çàãðóçêà... Æäèòå",IDC_STATIC,5,19,176,8, SS_CENTER END IDD_CONNECTING DIALOG DISCARDABLE 0, 0, 280, 116 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU| WS_VISIBLE | DS_CENTER -CAPTION "Подключение к камере" +CAPTION "Ïîäêëþ÷åíèå ê êàìåðå" FONT 8, "MS Sans Serif" BEGIN CONTROL "",IDC_BITMAP,"Static",SS_BITMAP|SS_CENTERIMAGE,4,4,110,110 - LTEXT "Подключение к камере... Ждите",IDC_STATIC,128,58,116,8 + LTEXT "Ïîäêëþ÷åíèå ê êàìåðå... Æäèòå",IDC_STATIC,128,58,116,8 END diff --git a/dlls/gphoto2.ds/gphoto2_Si.rc b/dlls/gphoto2.ds/gphoto2_Si.rc index 2f1179d75e6..87d969f8e12 100644 --- a/dlls/gphoto2.ds/gphoto2_Si.rc +++ b/dlls/gphoto2.ds/gphoto2_Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -56,3 +54,5 @@ BEGIN LTEXT "Povezujem se s kamero ... Prosim, počakajte",IDC_STATIC,128,58, 116,8 END + +#pragma code_page(default) diff --git a/dlls/gphoto2.ds/gphoto2_Sv.rc b/dlls/gphoto2.ds/gphoto2_Sv.rc index c7a3772b5d5..6ba98274200 100644 --- a/dlls/gphoto2.ds/gphoto2_Sv.rc +++ b/dlls/gphoto2.ds/gphoto2_Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL IDD_CAMERAUI DIALOG DISCARDABLE 0, 0, 372, 273 diff --git a/dlls/gphoto2.ds/gphoto2_Zh.rc b/dlls/gphoto2.ds/gphoto2_Zh.rc index dfc758aeb48..abd0f381bbc 100644 --- a/dlls/gphoto2.ds/gphoto2_Zh.rc +++ b/dlls/gphoto2.ds/gphoto2_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -94,3 +92,5 @@ BEGIN LTEXT "正在連接照相機... 請稍候",IDC_STATIC,128,58, 116,8 END + +#pragma code_page(default) diff --git a/dlls/gphoto2.ds/resource.h b/dlls/gphoto2.ds/resource.h index 8f2fe637971..a13915a4766 100644 --- a/dlls/gphoto2.ds/resource.h +++ b/dlls/gphoto2.ds/resource.h @@ -18,11 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include -#include -#include - #define IDD_DIALOG1 0x400 #define IDD_CAMERAUI 0x401 #define IDD_CONNECTING 0x402 diff --git a/dlls/gphoto2.ds/rsrc.rc b/dlls/gphoto2.ds/rsrc.rc new file mode 100644 index 00000000000..774678574eb --- /dev/null +++ b/dlls/gphoto2.ds/rsrc.rc @@ -0,0 +1,43 @@ +/* + * Top level resource file for Twain + * + * Copyright 2006 CodeWeavers, Aric Stewart + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winnls.h" +#include "commctrl.h" + +#include "resource.h" + +#include "gphoto2_Da.rc" +#include "gphoto2_De.rc" +#include "gphoto2_En.rc" +#include "gphoto2_Es.rc" +#include "gphoto2_Fr.rc" +#include "gphoto2_Ko.rc" +#include "gphoto2_Lt.rc" +#include "gphoto2_Nl.rc" +#include "gphoto2_No.rc" +#include "gphoto2_Pl.rc" +#include "gphoto2_Pt.rc" +#include "gphoto2_Ru.rc" +#include "gphoto2_Si.rc" +#include "gphoto2_Sv.rc" +#include "gphoto2_Zh.rc" diff --git a/dlls/hal/hal.c b/dlls/hal/hal.c index e576171057b..ed38e6c39a7 100644 --- a/dlls/hal/hal.c +++ b/dlls/hal/hal.c @@ -126,9 +126,3 @@ ULONG WINAPI HalGetBusData(BUS_DATA_TYPE BusDataType, ULONG BusNumber, ULONG Slo /* Claim that there is no such bus */ return 0; } - -KIRQL WINAPI KeGetCurrentIrql(VOID) -{ - FIXME( " stub!\n"); - return 0; -} diff --git a/dlls/hal/hal.spec b/dlls/hal/hal.spec index f050ed9aacf..0824e49ec0b 100644 --- a/dlls/hal/hal.spec +++ b/dlls/hal/hal.spec @@ -70,7 +70,7 @@ @ stub KdComPortInUse @ stub KeAcquireSpinLock @ stub KeFlushWriteBuffer -@ stdcall KeGetCurrentIrql() +@ stub KeGetCurrentIrql @ stub KeLowerIrql @ stub KeQueryPerformanceCounter @ stub KeRaiseIrql diff --git a/dlls/hhctrl.ocx/Cs.rc b/dlls/hhctrl.ocx/Cs.rc index b9147627278..ec564d830d1 100644 --- a/dlls/hhctrl.ocx/Cs.rc +++ b/dlls/hhctrl.ocx/Cs.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/dlls/hhctrl.ocx/Da.rc b/dlls/hhctrl.ocx/Da.rc index 1832d71c334..e425ef0e567 100644 --- a/dlls/hhctrl.ocx/Da.rc +++ b/dlls/hhctrl.ocx/Da.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/dlls/hhctrl.ocx/De.rc b/dlls/hhctrl.ocx/De.rc index 2bd2170570f..ef6e6997bd5 100644 --- a/dlls/hhctrl.ocx/De.rc +++ b/dlls/hhctrl.ocx/De.rc @@ -19,10 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE @@ -39,12 +35,12 @@ BEGIN IDTB_CONTRACT "Verstecken" IDTB_STOP "Stop" IDTB_REFRESH "Aktualisieren" - IDTB_BACK "Zurück" + IDTB_BACK "Zurück" IDTB_HOME "Startseite" IDTB_SYNC "Synchronisieren" IDTB_PRINT "Drucken" IDTB_OPTIONS "Einstellungen" - IDTB_FORWARD "Vorwärts" + IDTB_FORWARD "Vorwärts" IDTB_NOTES "IDTB_NOTES" IDTB_BROWSE_FWD "IDTB_BROWSE_FWD" IDTB_BROWSE_BACK "IDT_BROWSE_BACK" @@ -56,7 +52,7 @@ BEGIN IDTB_JUMP1 "Sprung1" IDTB_JUMP2 "Sprung2" IDTB_CUSTOMIZE "Anpassen" - IDTB_ZOOM "Vergrößern" + IDTB_ZOOM "Vergrößern" IDTB_TOC_NEXT "IDTB_TOC_NEXT" IDTB_TOC_PREV "IDTB_TOC_PREV" END diff --git a/dlls/hhctrl.ocx/El.rc b/dlls/hhctrl.ocx/El.rc index 4fa79a2dcd8..dd81eb68da2 100644 --- a/dlls/hhctrl.ocx/El.rc +++ b/dlls/hhctrl.ocx/El.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_GREEK, SUBLANG_DEFAULT STRINGTABLE diff --git a/dlls/hhctrl.ocx/En.rc b/dlls/hhctrl.ocx/En.rc index b69383e1898..83917f6e3d6 100644 --- a/dlls/hhctrl.ocx/En.rc +++ b/dlls/hhctrl.ocx/En.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE @@ -58,13 +56,3 @@ BEGIN IDTB_TOC_NEXT "IDTB_TOC_NEXT" IDTB_TOC_PREV "IDTB_TOC_PREV" END - -LANGUAGE LANG_ENGLISH, SUBLANG_NEUTRAL - -STRINGTABLE -BEGIN - IDS_CONTENTS "&Contents" - IDS_INDEX "I&ndex" - IDS_SEARCH "&Search" - IDS_FAVORITES "Favour&ites" -END diff --git a/dlls/hhctrl.ocx/Fi.rc b/dlls/hhctrl.ocx/Fi.rc index 825422e57d6..975ce1f49aa 100644 --- a/dlls/hhctrl.ocx/Fi.rc +++ b/dlls/hhctrl.ocx/Fi.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/dlls/hhctrl.ocx/Fr.rc b/dlls/hhctrl.ocx/Fr.rc index 2146a3c7ae1..0e5dd4f9591 100644 --- a/dlls/hhctrl.ocx/Fr.rc +++ b/dlls/hhctrl.ocx/Fr.rc @@ -19,11 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE @@ -38,9 +33,9 @@ STRINGTABLE BEGIN IDTB_EXPAND "Afficher" IDTB_CONTRACT "Cacher" - IDTB_STOP "Arrêter" + IDTB_STOP "Arrêter" IDTB_REFRESH "A&ctualiser" - IDTB_BACK "Précédent" + IDTB_BACK "Précédent" IDTB_HOME "Sommaire" IDTB_SYNC "Synchroniser" IDTB_PRINT "Imprimer" @@ -54,8 +49,8 @@ BEGIN IDTB_SEARCH "IDTB_SEARCH" IDTB_HISTORY "IDTB_HISTORY" IDTB_FAVORITES "IDTB_FAVORITES" - IDTB_JUMP1 "Saut1" - IDTB_JUMP2 "Saut2" + IDTB_JUMP1 "Jump1" + IDTB_JUMP2 "Jump2" IDTB_CUSTOMIZE "Personnaliser" IDTB_ZOOM "Zoom" IDTB_TOC_NEXT "IDTB_TOC_NEXT" diff --git a/dlls/hhctrl.ocx/Hu.rc b/dlls/hhctrl.ocx/Hu.rc index 0cab8cdae81..225c04a82d7 100644 --- a/dlls/hhctrl.ocx/Hu.rc +++ b/dlls/hhctrl.ocx/Hu.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT STRINGTABLE diff --git a/dlls/hhctrl.ocx/Ko.rc b/dlls/hhctrl.ocx/Ko.rc index 37831dfcb7c..169eb70e472 100644 --- a/dlls/hhctrl.ocx/Ko.rc +++ b/dlls/hhctrl.ocx/Ko.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE diff --git a/dlls/hhctrl.ocx/Lt.rc b/dlls/hhctrl.ocx/Lt.rc index 8c813ba1ef1..fed6b40e400 100644 --- a/dlls/hhctrl.ocx/Lt.rc +++ b/dlls/hhctrl.ocx/Lt.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -61,3 +59,5 @@ BEGIN IDTB_TOC_NEXT "IDTB_TOC_NEXT" IDTB_TOC_PREV "IDTB_TOC_PREV" END + +#pragma code_page(default) diff --git a/dlls/hhctrl.ocx/Makefile.in b/dlls/hhctrl.ocx/Makefile.in index 60f2c507ba2..229bd2abaf8 100644 --- a/dlls/hhctrl.ocx/Makefile.in +++ b/dlls/hhctrl.ocx/Makefile.in @@ -13,27 +13,7 @@ C_SRCS = \ regsvr.c \ webbrowser.c -RC_SRCS = \ - Cs.rc \ - Da.rc \ - De.rc \ - El.rc \ - En.rc \ - Fi.rc \ - Fr.rc \ - Hu.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc \ - version.rc +RC_SRCS = hhctrl.rc @MAKE_DLL_RULES@ diff --git a/dlls/hhctrl.ocx/Nl.rc b/dlls/hhctrl.ocx/Nl.rc index 99c12faf10d..929ac39f6da 100644 --- a/dlls/hhctrl.ocx/Nl.rc +++ b/dlls/hhctrl.ocx/Nl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE diff --git a/dlls/hhctrl.ocx/No.rc b/dlls/hhctrl.ocx/No.rc index a76ad3147a7..5ff634d02df 100644 --- a/dlls/hhctrl.ocx/No.rc +++ b/dlls/hhctrl.ocx/No.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE diff --git a/dlls/hhctrl.ocx/Pl.rc b/dlls/hhctrl.ocx/Pl.rc index f3ce6f2c76c..40d3089af84 100644 --- a/dlls/hhctrl.ocx/Pl.rc +++ b/dlls/hhctrl.ocx/Pl.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/dlls/hhctrl.ocx/Pt.rc b/dlls/hhctrl.ocx/Pt.rc index 13476ce843f..d196ff499b9 100644 --- a/dlls/hhctrl.ocx/Pt.rc +++ b/dlls/hhctrl.ocx/Pt.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE diff --git a/dlls/hhctrl.ocx/Ru.rc b/dlls/hhctrl.ocx/Ru.rc index 0634c39da21..a530f80b637 100644 --- a/dlls/hhctrl.ocx/Ru.rc +++ b/dlls/hhctrl.ocx/Ru.rc @@ -19,45 +19,40 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE BEGIN - IDS_CONTENTS "&Содержание" - IDS_INDEX "&Оглавление" - IDS_SEARCH "&Поиск" - IDS_FAVORITES "&Избранное" + IDS_CONTENTS "&Ñîäåðæàíèå" + IDS_INDEX "&Îãëàâëåíèå" + IDS_SEARCH "&Ïîèñê" + IDS_FAVORITES "&Èçáðàííîå" END STRINGTABLE BEGIN - IDTB_EXPAND "Показать" - IDTB_CONTRACT "Спрятать" - IDTB_STOP "Остановить" - IDTB_REFRESH "Обновить" - IDTB_BACK "Назад" - IDTB_HOME "В начало" - IDTB_SYNC "Синхронизировать" - IDTB_PRINT "Печать" - IDTB_OPTIONS "Настройки" - IDTB_FORWARD "Вперёд" - IDTB_NOTES "Записки" - IDTB_BROWSE_FWD "Просмотр вперёд" - IDTB_BROWSE_BACK "Просмотр назад" - IDTB_CONTENTS "Содержание" - IDTB_INDEX "Оглавление" - IDTB_SEARCH "Поиск" - IDTB_HISTORY "История" - IDTB_FAVORITES "Избранное" - IDTB_JUMP1 "Переход 1" - IDTB_JUMP2 "Переход 2" - IDTB_CUSTOMIZE "Персонализовать" - IDTB_ZOOM "Масштаб" - IDTB_TOC_NEXT "Следующая глава" - IDTB_TOC_PREV "Предыдущая глава" + IDTB_EXPAND "Ïîêàçàòü" + IDTB_CONTRACT "Ñïðÿòàòü" + IDTB_STOP "Îñòàíîâèòü" + IDTB_REFRESH "Îáíîâèòü" + IDTB_BACK "Íàçàä" + IDTB_HOME " íà÷àëî" + IDTB_SYNC "Ñèíõðîíèçèðîâàòü" + IDTB_PRINT "Ïå÷àòü" + IDTB_OPTIONS "Íàñòðîéêè" + IDTB_FORWARD "Âïåð¸ä" + IDTB_NOTES "Çàïèñêè" + IDTB_BROWSE_FWD "Ïðîñìîòð âïåð¸ä" + IDTB_BROWSE_BACK "Ïðîñìîòð íàçàä" + IDTB_CONTENTS "Ñîäåðæàíèå" + IDTB_INDEX "Îãëàâëåíèå" + IDTB_SEARCH "Ïîèñê" + IDTB_HISTORY "Èñòîðèÿ" + IDTB_FAVORITES "Èçáðàííîå" + IDTB_JUMP1 "Ïåðåõîä 1" + IDTB_JUMP2 "Ïåðåõîä 2" + IDTB_CUSTOMIZE "Ïåðñîíàëèçîâàòü" + IDTB_ZOOM "Ìàñøòàá" + IDTB_TOC_NEXT "Ñëåäóþùàÿ ãëàâà" + IDTB_TOC_PREV "Ïðåäûäóùàÿ ãëàâà" END diff --git a/dlls/hhctrl.ocx/Si.rc b/dlls/hhctrl.ocx/Si.rc index bc8ca1d3705..c8ea447f5ed 100644 --- a/dlls/hhctrl.ocx/Si.rc +++ b/dlls/hhctrl.ocx/Si.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -60,3 +58,5 @@ BEGIN IDTB_TOC_NEXT "IDTB_TOC_NEXT" IDTB_TOC_PREV "IDTB_TOC_PREV" END + +#pragma code_page(default) diff --git a/dlls/hhctrl.ocx/Sv.rc b/dlls/hhctrl.ocx/Sv.rc index b92c63c2bbd..cb3e4e26a5d 100644 --- a/dlls/hhctrl.ocx/Sv.rc +++ b/dlls/hhctrl.ocx/Sv.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL STRINGTABLE diff --git a/dlls/hhctrl.ocx/Tr.rc b/dlls/hhctrl.ocx/Tr.rc index f1011b1dc48..748899908f7 100644 --- a/dlls/hhctrl.ocx/Tr.rc +++ b/dlls/hhctrl.ocx/Tr.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/dlls/hhctrl.ocx/Zh.rc b/dlls/hhctrl.ocx/Zh.rc index d6295a96d20..a7ccab0da74 100644 --- a/dlls/hhctrl.ocx/Zh.rc +++ b/dlls/hhctrl.ocx/Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -98,3 +96,5 @@ BEGIN IDTB_TOC_NEXT "後一項" IDTB_TOC_PREV "前一項" END + +#pragma code_page(default) diff --git a/dlls/hhctrl.ocx/chm.c b/dlls/hhctrl.ocx/chm.c index b7df8e72c7d..e8d036b67bf 100644 --- a/dlls/hhctrl.ocx/chm.c +++ b/dlls/hhctrl.ocx/chm.c @@ -362,18 +362,15 @@ IStream *GetChmStream(CHMInfo *info, LPCWSTR parent_chm, ChmPath *chm_file) /* Opens the CHM file for reading */ CHMInfo *OpenCHM(LPCWSTR szFile) { + WCHAR file[MAX_PATH] = {0}; HRESULT hres; - CHMInfo *ret; static const WCHAR wszSTRINGS[] = {'#','S','T','R','I','N','G','S',0}; - if (!(ret = heap_alloc_zero(sizeof(CHMInfo)))) - return NULL; + CHMInfo *ret = heap_alloc_zero(sizeof(CHMInfo)); - if (!(ret->szFile = strdupW(szFile))) { - heap_free(ret); - return NULL; - } + GetFullPathNameW(szFile, sizeof(file)/sizeof(file[0]), file, NULL); + ret->szFile = strdupW(file); hres = CoCreateInstance(&CLSID_ITStorage, NULL, CLSCTX_INPROC_SERVER, &IID_IITStorage, (void **) &ret->pITStorage) ; @@ -426,7 +423,6 @@ CHMInfo *CloseCHM(CHMInfo *chm) heap_free(chm->defTitle); heap_free(chm->defTopic); heap_free(chm->defToc); - heap_free(chm->szFile); heap_free(chm); return NULL; diff --git a/dlls/hhctrl.ocx/hhctrl.c b/dlls/hhctrl.ocx/hhctrl.c index 8268a21f34b..5e707b92560 100644 --- a/dlls/hhctrl.ocx/hhctrl.c +++ b/dlls/hhctrl.ocx/hhctrl.c @@ -86,27 +86,11 @@ static const char *command_to_string(UINT command) #undef X } -static BOOL resolve_filename(const WCHAR *filename, WCHAR *fullname, DWORD buflen) -{ - static const WCHAR helpW[] = {'\\','h','e','l','p','\\',0}; - - GetFullPathNameW(filename, buflen, fullname, NULL); - if (GetFileAttributesW(fullname) == INVALID_FILE_ATTRIBUTES) - { - GetWindowsDirectoryW(fullname, buflen); - strcatW(fullname, helpW); - strcatW(fullname, filename); - } - return (GetFileAttributesW(fullname) != INVALID_FILE_ATTRIBUTES); -} - /****************************************************************** * HtmlHelpW (HHCTRL.OCX.15) */ HWND WINAPI HtmlHelpW(HWND caller, LPCWSTR filename, UINT command, DWORD_PTR data) { - WCHAR fullname[MAX_PATH]; - TRACE("(%p, %s, command=%s, data=%lx)\n", caller, debugstr_w( filename ), command_to_string( command ), data); @@ -135,14 +119,13 @@ HWND WINAPI HtmlHelpW(HWND caller, LPCWSTR filename, UINT command, DWORD_PTR dat filename = chm_file; index += 2; /* advance beyond "::" for calling NavigateToChm() later */ } - - if (!resolve_filename(filename, fullname, MAX_PATH)) + else { - WARN("can't find %s\n", debugstr_w(filename)); - return 0; + if (command!=HH_DISPLAY_SEARCH) /* FIXME - use HH_FTS_QUERYW structure in data */ + index = (const WCHAR*)data; } - info = CreateHelpViewer(fullname); + info = CreateHelpViewer(filename); if(!info) return NULL; @@ -164,13 +147,7 @@ HWND WINAPI HtmlHelpW(HWND caller, LPCWSTR filename, UINT command, DWORD_PTR dat if (!filename) return NULL; - if (!resolve_filename(filename, fullname, MAX_PATH)) - { - WARN("can't find %s\n", debugstr_w(filename)); - return 0; - } - - info = CreateHelpViewer(fullname); + info = CreateHelpViewer(filename); if(!info) return NULL; diff --git a/dlls/hhctrl.ocx/hhctrl.h b/dlls/hhctrl.ocx/hhctrl.h index 83d39f5de4c..795bea4d13e 100644 --- a/dlls/hhctrl.ocx/hhctrl.h +++ b/dlls/hhctrl.ocx/hhctrl.h @@ -69,7 +69,7 @@ typedef struct CHMInfo { IITStorage *pITStorage; IStorage *pStorage; - WCHAR *szFile; + LPCWSTR szFile; IStream *strings_stream; char **strings; diff --git a/dlls/hhctrl.ocx/hhctrl.rc b/dlls/hhctrl.ocx/hhctrl.rc new file mode 100644 index 00000000000..8618819ed12 --- /dev/null +++ b/dlls/hhctrl.ocx/hhctrl.rc @@ -0,0 +1,50 @@ +/* + * HTML Help resources + * + * Copyright 2005 James Hawkins + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "wingdi.h" +#include "winnls.h" +#include "htmlhelp.h" +#include "resource.h" + +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + +#include "version.rc" + +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "El.rc" +#include "En.rc" +#include "Fr.rc" +#include "Fi.rc" +#include "Hu.rc" +#include "Ko.rc" +#include "Lt.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" diff --git a/dlls/hhctrl.ocx/resource.h b/dlls/hhctrl.ocx/resource.h index a08fdd96eb8..02df94641e9 100644 --- a/dlls/hhctrl.ocx/resource.h +++ b/dlls/hhctrl.ocx/resource.h @@ -18,11 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include -#include -#include - #define IDS_CONTENTS 1 #define IDS_INDEX 2 #define IDS_SEARCH 3 diff --git a/dlls/iccvid/Makefile.in b/dlls/iccvid/Makefile.in index 6fdf13d1bff..c81a913d0e7 100644 --- a/dlls/iccvid/Makefile.in +++ b/dlls/iccvid/Makefile.in @@ -8,24 +8,7 @@ IMPORTS = user32 kernel32 C_SRCS = \ iccvid.c -RC_SRCS = \ - iccvid_Da.rc \ - iccvid_De.rc \ - iccvid_En.rc \ - iccvid_Fr.rc \ - iccvid_Hu.rc \ - iccvid_Ja.rc \ - iccvid_Ko.rc \ - iccvid_Lt.rc \ - iccvid_Nl.rc \ - iccvid_No.rc \ - iccvid_Pl.rc \ - iccvid_Pt.rc \ - iccvid_Ro.rc \ - iccvid_Ru.rc \ - iccvid_Si.rc \ - iccvid_Sv.rc \ - iccvid_Tr.rc +RC_SRCS = rsrc.rc @MAKE_DLL_RULES@ diff --git a/dlls/iccvid/iccvid_Da.rc b/dlls/iccvid/iccvid_Da.rc index bbdc03ed4f2..185b1bb92ab 100644 --- a/dlls/iccvid/iccvid_Da.rc +++ b/dlls/iccvid/iccvid_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/iccvid/iccvid_De.rc b/dlls/iccvid/iccvid_De.rc index d1a3cef3131..c101f3ad714 100644 --- a/dlls/iccvid/iccvid_De.rc +++ b/dlls/iccvid/iccvid_De.rc @@ -17,10 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/iccvid/iccvid_En.rc b/dlls/iccvid/iccvid_En.rc index 91d848a0841..c71b0a449a0 100644 --- a/dlls/iccvid/iccvid_En.rc +++ b/dlls/iccvid/iccvid_En.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/iccvid/iccvid_Fr.rc b/dlls/iccvid/iccvid_Fr.rc index 79d9cfd23ce..4d276e68a15 100644 --- a/dlls/iccvid/iccvid_Fr.rc +++ b/dlls/iccvid/iccvid_Fr.rc @@ -16,15 +16,10 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { - IDS_NAME "Codec vidéo Cinepak" - IDS_DESCRIPTION "Codec vidéo Cinepak" + IDS_NAME "codec vidéo Cinepak" + IDS_DESCRIPTION "codec vidéo Cinepak" } diff --git a/dlls/iccvid/iccvid_Hu.rc b/dlls/iccvid/iccvid_Hu.rc index 69faccd6a0d..b24cf8eaf25 100644 --- a/dlls/iccvid/iccvid_Hu.rc +++ b/dlls/iccvid/iccvid_Hu.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/iccvid/iccvid_Ja.rc b/dlls/iccvid/iccvid_Ja.rc deleted file mode 100644 index b845af4a1c3..00000000000 --- a/dlls/iccvid/iccvid_Ja.rc +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright 2009 Aric Stewart, CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "iccvid_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT - -STRINGTABLE DISCARDABLE -{ - IDS_NAME "Cinepak ビデオコーデック" - IDS_DESCRIPTION "Cinepak ビデオコーデック" -} diff --git a/dlls/iccvid/iccvid_Ko.rc b/dlls/iccvid/iccvid_Ko.rc index f47eb8ca89a..0cfbe3ea95d 100644 --- a/dlls/iccvid/iccvid_Ko.rc +++ b/dlls/iccvid/iccvid_Ko.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/iccvid/iccvid_Lt.rc b/dlls/iccvid/iccvid_Lt.rc deleted file mode 100644 index 2e31cd398ed..00000000000 --- a/dlls/iccvid/iccvid_Lt.rc +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "iccvid_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_NAME "Cinepak vaizdo kodekas" - IDS_DESCRIPTION "Cinepak vaizdo kodekas" -} diff --git a/dlls/iccvid/iccvid_Nl.rc b/dlls/iccvid/iccvid_Nl.rc index fbc4024bf22..0c58dd16d85 100644 --- a/dlls/iccvid/iccvid_Nl.rc +++ b/dlls/iccvid/iccvid_Nl.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/iccvid/iccvid_No.rc b/dlls/iccvid/iccvid_No.rc index 4cefc0013fd..dd64108523b 100644 --- a/dlls/iccvid/iccvid_No.rc +++ b/dlls/iccvid/iccvid_No.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE DISCARDABLE diff --git a/dlls/iccvid/iccvid_Pl.rc b/dlls/iccvid/iccvid_Pl.rc index 0a4c0f51678..e276e8703a1 100644 --- a/dlls/iccvid/iccvid_Pl.rc +++ b/dlls/iccvid/iccvid_Pl.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/iccvid/iccvid_Pt.rc b/dlls/iccvid/iccvid_Pt.rc index 659224f8966..5e4ad5cabd3 100644 --- a/dlls/iccvid/iccvid_Pt.rc +++ b/dlls/iccvid/iccvid_Pt.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/iccvid/iccvid_Ro.rc b/dlls/iccvid/iccvid_Ro.rc index d99a0b2d36b..85cb1da2d38 100644 --- a/dlls/iccvid/iccvid_Ro.rc +++ b/dlls/iccvid/iccvid_Ro.rc @@ -17,10 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - -#pragma code_page(65001) - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/iccvid/iccvid_Ru.rc b/dlls/iccvid/iccvid_Ru.rc index 7a77b349eaf..c78ee72ff16 100644 --- a/dlls/iccvid/iccvid_Ru.rc +++ b/dlls/iccvid/iccvid_Ru.rc @@ -16,15 +16,10 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { - IDS_NAME "Видео кодер-декодер Cinepak" - IDS_DESCRIPTION "Видео кодер-декодер Cinepak" + IDS_NAME "Âèäåî êîäåð-äåêîäåð Cinepak" + IDS_DESCRIPTION "Âèäåî êîäåð-äåêîäåð Cinepak" } diff --git a/dlls/iccvid/iccvid_Si.rc b/dlls/iccvid/iccvid_Si.rc index 9635480e091..82bbd05fee4 100644 --- a/dlls/iccvid/iccvid_Si.rc +++ b/dlls/iccvid/iccvid_Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -27,3 +25,5 @@ STRINGTABLE DISCARDABLE IDS_NAME "Cinepak Video kodek" IDS_DESCRIPTION "Cinepak Video kodek" } + +#pragma code_page(default) diff --git a/dlls/iccvid/iccvid_Sv.rc b/dlls/iccvid/iccvid_Sv.rc index 34762d69071..55eb468125b 100644 --- a/dlls/iccvid/iccvid_Sv.rc +++ b/dlls/iccvid/iccvid_Sv.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/iccvid/iccvid_Tr.rc b/dlls/iccvid/iccvid_Tr.rc index 8eabf9f6909..929f44fcbb2 100644 --- a/dlls/iccvid/iccvid_Tr.rc +++ b/dlls/iccvid/iccvid_Tr.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "iccvid_private.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/iccvid/iccvid_private.h b/dlls/iccvid/iccvid_private.h index 56b082d844d..8400e775207 100644 --- a/dlls/iccvid/iccvid_private.h +++ b/dlls/iccvid/iccvid_private.h @@ -19,8 +19,6 @@ #ifndef __ICCVID_PRIVATE_H #define __ICCVID_PRIVATE_H -#include - #define IDS_NAME 100 #define IDS_DESCRIPTION 101 diff --git a/dlls/iccvid/rsrc.rc b/dlls/iccvid/rsrc.rc new file mode 100644 index 00000000000..e7512207c82 --- /dev/null +++ b/dlls/iccvid/rsrc.rc @@ -0,0 +1,36 @@ +/* + * Copyright 2005 Dmitry Timoshkov + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "iccvid_private.h" + +#include "iccvid_Da.rc" +#include "iccvid_De.rc" +#include "iccvid_En.rc" +#include "iccvid_Fr.rc" +#include "iccvid_Hu.rc" +#include "iccvid_Ko.rc" +#include "iccvid_Nl.rc" +#include "iccvid_No.rc" +#include "iccvid_Pl.rc" +#include "iccvid_Pt.rc" +#include "iccvid_Ro.rc" +#include "iccvid_Ru.rc" +#include "iccvid_Si.rc" +#include "iccvid_Sv.rc" +#include "iccvid_Tr.rc" diff --git a/dlls/imm.dll16/Makefile.in b/dlls/imm.dll16/Makefile.in index a832e39f390..7ea14e8bbd9 100644 --- a/dlls/imm.dll16/Makefile.in +++ b/dlls/imm.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = imm.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,imm32.dll +SPEC_SRCS = imm.dll16.spec + @MAKE_DLL_RULES@ @DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/iphlpapi/iphlpapi_main.c b/dlls/iphlpapi/iphlpapi_main.c index 16cf1b3f5c7..8490c67990c 100644 --- a/dlls/iphlpapi/iphlpapi_main.c +++ b/dlls/iphlpapi/iphlpapi_main.c @@ -611,7 +611,7 @@ static DWORD typeFromMibType(DWORD mib_type) static ULONG addressesFromIndex(DWORD index, DWORD **addrs, ULONG *num_addrs) { - ULONG ret, i, j; + ULONG ret, i; MIB_IPADDRTABLE *at; *num_addrs = 0; @@ -625,9 +625,9 @@ static ULONG addressesFromIndex(DWORD index, DWORD **addrs, ULONG *num_addrs) HeapFree(GetProcessHeap(), 0, at); return ERROR_OUTOFMEMORY; } - for (i = 0, j = 0; i < at->dwNumEntries; i++) + for (i = 0; i < at->dwNumEntries; i++) { - if (at->table[i].dwIndex == index) (*addrs)[j++] = at->table[i].dwAddr; + if (at->table[i].dwIndex == index) (*addrs)[i] = at->table[i].dwAddr; } HeapFree(GetProcessHeap(), 0, at); return ERROR_SUCCESS; diff --git a/dlls/iphlpapi/tests/iphlpapi.c b/dlls/iphlpapi/tests/iphlpapi.c index eaada075e58..f879c93a943 100644 --- a/dlls/iphlpapi/tests/iphlpapi.c +++ b/dlls/iphlpapi/tests/iphlpapi.c @@ -829,7 +829,6 @@ static void test_GetAdaptersAddresses(void) ret = gGetAdaptersAddresses(AF_UNSPEC, 0, NULL, NULL, NULL); ok(ret == ERROR_INVALID_PARAMETER, "expected ERROR_INVALID_PARAMETER got %u\n", ret); - size = 0; ret = gGetAdaptersAddresses(AF_UNSPEC, 0, NULL, NULL, &size); ok(ret == ERROR_BUFFER_OVERFLOW, "expected ERROR_BUFFER_OVERFLOW, got %u\n", ret); if (ret != ERROR_BUFFER_OVERFLOW) return; diff --git a/dlls/itss/Makefile.in b/dlls/itss/Makefile.in index 28ba67a0d84..9614ab6469c 100644 --- a/dlls/itss/Makefile.in +++ b/dlls/itss/Makefile.in @@ -8,8 +8,8 @@ EXTRADEFS = -DCOM_NO_WINDOWS_H C_SRCS = \ chm_lib.c \ - itss.c \ lzx.c \ + itss.c \ moniker.c \ protocol.c \ storage.c diff --git a/dlls/jscript/Makefile.in b/dlls/jscript/Makefile.in index 489567fc104..5d7ee696c1d 100644 --- a/dlls/jscript/Makefile.in +++ b/dlls/jscript/Makefile.in @@ -3,15 +3,9 @@ TOPOBJDIR = ../.. SRCDIR = @srcdir@ VPATH = @srcdir@ MODULE = jscript.dll -IMPORTS = oleaut32 user32 advapi32 kernel32 +IMPORTS = oleaut32 advapi32 kernel32 -RC_SRCS = \ - jscript_De.rc \ - jscript_En.rc \ - jscript_Fr.rc \ - jscript_Lt.rc \ - jscript_Nl.rc \ - rsrc.rc +RC_SRCS = rsrc.rc C_SRCS = \ array.c \ @@ -19,7 +13,6 @@ C_SRCS = \ date.c \ dispex.c \ engine.c \ - error.c \ function.c \ global.c \ jscript.c \ @@ -35,7 +28,7 @@ C_SRCS = \ IDL_TLB_SRCS = jsglobal.idl BISON_SRCS = \ - parser.y + parser.y @MAKE_DLL_RULES@ diff --git a/dlls/jscript/array.c b/dlls/jscript/array.c index b2bd5b2de48..8f0802e8e93 100644 --- a/dlls/jscript/array.c +++ b/dlls/jscript/array.c @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include - #include "jscript.h" #include "wine/debug.h" @@ -42,6 +40,7 @@ static const WCHAR sortW[] = {'s','o','r','t',0}; static const WCHAR spliceW[] = {'s','p','l','i','c','e',0}; static const WCHAR toStringW[] = {'t','o','S','t','r','i','n','g',0}; static const WCHAR toLocaleStringW[] = {'t','o','L','o','c','a','l','e','S','t','r','i','n','g',0}; +static const WCHAR valueOfW[] = {'v','a','l','u','e','O','f',0}; static const WCHAR unshiftW[] = {'u','n','s','h','i','f','t',0}; static const WCHAR hasOwnPropertyW[] = {'h','a','s','O','w','n','P','r','o','p','e','r','t','y',0}; static const WCHAR propertyIsEnumerableW[] = @@ -62,30 +61,6 @@ static HRESULT Array_length(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM V_VT(retv) = VT_I4; V_I4(retv) = This->length; break; - case DISPATCH_PROPERTYPUT: { - VARIANT num; - DOUBLE len = -1; - DWORD i; - HRESULT hres; - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &num); - if(V_VT(&num) == VT_I4) - len = V_I4(&num); - else - len = floor(V_R8(&num)); - - if(len!=(DWORD)len) - return throw_range_error(dispex->ctx, ei, IDS_INVALID_LENGTH, NULL); - - for(i=len; ilength; i++) { - hres = jsdisp_delete_idx(dispex, i); - if(FAILED(hres)) - return hres; - } - - This->length = len; - break; - } default: FIXME("unimplemented flags %x\n", flags); return E_NOTIMPL; @@ -419,81 +394,8 @@ static HRESULT Array_shift(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS static HRESULT Array_slice(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - DispatchEx *arr; - VARIANT v; - DOUBLE range; - DWORD length, start, end, idx; - HRESULT hres; - - TRACE("\n"); - - if(is_class(dispex, JSCLASS_ARRAY)) { - length = ((ArrayInstance*)dispex)->length; - }else { - FIXME("not Array this\n"); - return E_NOTIMPL; - } - - if(arg_cnt(dp)) { - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - - if(V_VT(&v) == VT_I4) - range = V_I4(&v); - else - range = floor(V_R8(&v)); - - if(-range>length || isnan(range)) start = 0; - else if(range < 0) start = range+length; - else if(range <= length) start = range; - else start = length; - } - else start = 0; - - if(arg_cnt(dp)>1) { - hres = to_number(dispex->ctx, get_arg(dp, 1), ei, &v); - if(FAILED(hres)) - return hres; - - if(V_VT(&v) == VT_I4) - range = V_I4(&v); - else - range = floor(V_R8(&v)); - - if(-range>length) end = 0; - else if(range < 0) end = range+length; - else if(range <= length) end = range; - else end = length; - } - else end = length; - - hres = create_array(dispex->ctx, (end>start)?end-start:0, &arr); - if(FAILED(hres)) - return hres; - - for(idx=start; idxctx, ei, IDS_NOT_FUNC, NULL); case INVOKE_PROPERTYGET: return array_join(dispex, lcid, ((ArrayInstance*)dispex)->length, default_separatorW, retv, ei, sp); default: @@ -825,6 +732,7 @@ static const builtin_prop_t Array_props[] = { {toLocaleStringW, Array_toLocaleString, PROPF_METHOD}, {toStringW, Array_toString, PROPF_METHOD}, {unshiftW, Array_unshift, PROPF_METHOD}, + {valueOfW, Array_valueOf, PROPF_METHOD} }; static const builtin_info_t Array_info = { @@ -847,11 +755,12 @@ static HRESULT ArrayConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, DISP TRACE("\n"); switch(flags) { - case DISPATCH_METHOD: case DISPATCH_CONSTRUCT: { if(arg_cnt(dp) == 1 && V_VT((arg_var = get_arg(dp, 0))) == VT_I4) { - if(V_I4(arg_var) < 0) - return throw_range_error(dispex->ctx, ei, IDS_INVALID_LENGTH, NULL); + if(V_I4(arg_var) < 0) { + FIXME("throw RangeError\n"); + return E_FAIL; + } hres = create_array(dispex->ctx, V_I4(arg_var), &obj); if(FAILED(hres)) @@ -900,7 +809,7 @@ static HRESULT alloc_array(script_ctx_t *ctx, BOOL use_constr, ArrayInstance **r if(use_constr) hres = init_dispex_from_constr(&array->dispex, ctx, &Array_info, ctx->array_constr); else - hres = init_dispex_from_constr(&array->dispex, ctx, &Array_info, ctx->object_constr); + hres = init_dispex(&array->dispex, ctx, &Array_info, NULL); if(FAILED(hres)) { heap_free(array); @@ -920,7 +829,7 @@ HRESULT create_array_constr(script_ctx_t *ctx, DispatchEx **ret) if(FAILED(hres)) return hres; - hres = create_builtin_function(ctx, ArrayConstr_value, NULL, PROPF_CONSTR, &array->dispex, ret); + hres = create_builtin_function(ctx, ArrayConstr_value, PROPF_CONSTR, &array->dispex, ret); IDispatchEx_Release(_IDispatchEx_(&array->dispex)); return hres; diff --git a/dlls/jscript/bool.c b/dlls/jscript/bool.c index bfacebf3ec6..1add8efb768 100644 --- a/dlls/jscript/bool.c +++ b/dlls/jscript/bool.c @@ -1,6 +1,5 @@ /* * Copyright 2008 Jacek Caban for CodeWeavers - * Copyright 2009 Piotr Caban * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -37,59 +36,25 @@ static const WCHAR propertyIsEnumerableW[] = {'p','r','o','p','e','r','t','y','I','s','E','n','u','m','e','r','a','b','l','e',0}; static const WCHAR isPrototypeOfW[] = {'i','s','P','r','o','t','o','t','y','p','e','O','f',0}; -/* ECMA-262 3rd Edition 15.6.4.2 */ static HRESULT Bool_toString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - static const WCHAR trueW[] = {'t','r','u','e',0}; - static const WCHAR falseW[] = {'f','a','l','s','e',0}; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_BOOLEAN)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_BOOL, NULL); - - if(retv) { - BoolInstance *bool = (BoolInstance*)dispex; - BSTR val; - - if(bool->val) val = SysAllocString(trueW); - else val = SysAllocString(falseW); - - if(!val) - return E_OUTOFMEMORY; - - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = val; - } - - return S_OK; + FIXME("\n"); + return E_NOTIMPL; } static HRESULT Bool_toLocaleString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - TRACE("\n"); - return Bool_toString(dispex, lcid, flags, dp, retv, ei, sp); + FIXME("\n"); + return E_NOTIMPL; } -/* ECMA-262 3rd Edition 15.6.4.3 */ static HRESULT Bool_valueOf(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_BOOLEAN)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_BOOL, NULL); - - if(retv) { - BoolInstance *bool = (BoolInstance*)dispex; - - V_VT(retv) = VT_BOOL; - V_BOOL(retv) = bool->val; - } - - return S_OK; + FIXME("\n"); + return E_NOTIMPL; } static HRESULT Bool_hasOwnProperty(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, @@ -116,18 +81,8 @@ static HRESULT Bool_isPrototypeOf(DispatchEx *dispex, LCID lcid, WORD flags, DIS static HRESULT Bool_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - TRACE("\n"); - - switch(flags) { - case INVOKE_FUNC: - return throw_type_error(dispex->ctx, ei, IDS_NOT_FUNC, NULL); - default: - FIXME("unimplemented flags %x\n", flags); - return E_NOTIMPL; - } - - return S_OK; - + FIXME("\n"); + return E_NOTIMPL; } static const builtin_prop_t Bool_props[] = { @@ -151,41 +106,8 @@ static const builtin_info_t Bool_info = { static HRESULT BoolConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - HRESULT hres; - VARIANT_BOOL value = VARIANT_FALSE; - - if(arg_cnt(dp)) { - hres = to_boolean(get_arg(dp,0), &value); - if(FAILED(hres)) - return hres; - } - - switch(flags) { - case DISPATCH_CONSTRUCT: { - DispatchEx *bool; - - hres = create_bool(dispex->ctx, value, &bool); - if(FAILED(hres)) - return hres; - - V_VT(retv) = VT_DISPATCH; - V_DISPATCH(retv) = (IDispatch*)_IDispatchEx_(bool); - return S_OK; - } - - case INVOKE_FUNC: - if(retv) { - V_VT(retv) = VT_BOOL; - V_BOOL(retv) = value; - } - return S_OK; - - default: - FIXME("unimplemented flags %x\n", flags); - return E_NOTIMPL; - } - - return S_OK; + FIXME("\n"); + return E_NOTIMPL; } static HRESULT alloc_bool(script_ctx_t *ctx, BOOL use_constr, BoolInstance **ret) @@ -220,7 +142,7 @@ HRESULT create_bool_constr(script_ctx_t *ctx, DispatchEx **ret) if(FAILED(hres)) return hres; - hres = create_builtin_function(ctx, BoolConstr_value, NULL, PROPF_CONSTR, &bool->dispex, ret); + hres = create_builtin_function(ctx, BoolConstr_value, PROPF_CONSTR, &bool->dispex, ret); jsdisp_release(&bool->dispex); return hres; diff --git a/dlls/jscript/date.c b/dlls/jscript/date.c dissimilarity index 65% index 5085f212ebe..3fd856eaebb 100644 --- a/dlls/jscript/date.c +++ b/dlls/jscript/date.c @@ -1,2636 +1,1128 @@ -/* - * Copyright 2008 Jacek Caban for CodeWeavers - * Copyright 2009 Piotr Caban - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include -#include - -#include "jscript.h" - -#include "wine/debug.h" - -WINE_DEFAULT_DEBUG_CHANNEL(jscript); - -/* 1601 to 1970 is 369 years plus 89 leap days */ -#define TIME_EPOCH ((ULONGLONG)(369 * 365 + 89) * 86400 * 1000) - -typedef struct { - DispatchEx dispex; - - /* ECMA-262 3rd Edition 15.9.1.1 */ - DOUBLE time; - - LONG bias; - SYSTEMTIME standardDate; - LONG standardBias; - SYSTEMTIME daylightDate; - LONG daylightBias; -} DateInstance; - -static const WCHAR toStringW[] = {'t','o','S','t','r','i','n','g',0}; -static const WCHAR toLocaleStringW[] = {'t','o','L','o','c','a','l','e','S','t','r','i','n','g',0}; -static const WCHAR hasOwnPropertyW[] = {'h','a','s','O','w','n','P','r','o','p','e','r','t','y',0}; -static const WCHAR propertyIsEnumerableW[] = - {'p','r','o','p','e','r','t','y','I','s','E','n','u','m','e','r','a','b','l','e',0}; -static const WCHAR isPrototypeOfW[] = {'i','s','P','r','o','t','o','t','y','p','e','O','f',0}; -static const WCHAR valueOfW[] = {'v','a','l','u','e','O','f',0}; -static const WCHAR toUTCStringW[] = {'t','o','U','T','C','S','t','r','i','n','g',0}; -static const WCHAR toDateStringW[] = {'t','o','D','a','t','e','S','t','r','i','n','g',0}; -static const WCHAR toTimeStringW[] = {'t','o','T','i','m','e','S','t','r','i','n','g',0}; -static const WCHAR toLocaleDateStringW[] = {'t','o','L','o','c','a','l','e','D','a','t','e','S','t','r','i','n','g',0}; -static const WCHAR toLocaleTimeStringW[] = {'t','o','L','o','c','a','l','e','T','i','m','e','S','t','r','i','n','g',0}; -static const WCHAR getTimeW[] = {'g','e','t','T','i','m','e',0}; -static const WCHAR getFullYearW[] = {'g','e','t','F','u','l','l','Y','e','a','r',0}; -static const WCHAR getUTCFullYearW[] = {'g','e','t','U','T','C','F','u','l','l','Y','e','a','r',0}; -static const WCHAR getMonthW[] = {'g','e','t','M','o','n','t','h',0}; -static const WCHAR getUTCMonthW[] = {'g','e','t','U','T','C','M','o','n','t','h',0}; -static const WCHAR getDateW[] = {'g','e','t','D','a','t','e',0}; -static const WCHAR getUTCDateW[] = {'g','e','t','U','T','C','D','a','t','e',0}; -static const WCHAR getDayW[] = {'g','e','t','D','a','y',0}; -static const WCHAR getUTCDayW[] = {'g','e','t','U','T','C','D','a','y',0}; -static const WCHAR getHoursW[] = {'g','e','t','H','o','u','r','s',0}; -static const WCHAR getUTCHoursW[] = {'g','e','t','U','T','C','H','o','u','r','s',0}; -static const WCHAR getMinutesW[] = {'g','e','t','M','i','n','u','t','e','s',0}; -static const WCHAR getUTCMinutesW[] = {'g','e','t','U','T','C','M','i','n','u','t','e','s',0}; -static const WCHAR getSecondsW[] = {'g','e','t','S','e','c','o','n','d','s',0}; -static const WCHAR getUTCSecondsW[] = {'g','e','t','U','T','C','S','e','c','o','n','d','s',0}; -static const WCHAR getMillisecondsW[] = {'g','e','t','M','i','l','l','i','s','e','c','o','n','d','s',0}; -static const WCHAR getUTCMillisecondsW[] = {'g','e','t','U','T','C','M','i','l','l','i','s','e','c','o','n','d','s',0}; -static const WCHAR getTimezoneOffsetW[] = {'g','e','t','T','i','m','e','z','o','n','e','O','f','f','s','e','t',0}; -static const WCHAR setTimeW[] = {'s','e','t','T','i','m','e',0}; -static const WCHAR setMillisecondsW[] = {'s','e','t','M','i','l','l','i','s','e','c','o','n','d','s',0}; -static const WCHAR setUTCMillisecondsW[] = {'s','e','t','U','T','C','M','i','l','l','i','s','e','c','o','n','d','s',0}; -static const WCHAR setSecondsW[] = {'s','e','t','S','e','c','o','n','d','s',0}; -static const WCHAR setUTCSecondsW[] = {'s','e','t','U','T','C','S','e','c','o','n','d','s',0}; -static const WCHAR setMinutesW[] = {'s','e','t','M','i','n','u','t','e','s',0}; -static const WCHAR setUTCMinutesW[] = {'s','e','t','U','T','C','M','i','n','u','t','e','s',0}; -static const WCHAR setHoursW[] = {'s','e','t','H','o','u','r','s',0}; -static const WCHAR setUTCHoursW[] = {'s','e','t','U','T','C','H','o','u','r','s',0}; -static const WCHAR setDateW[] = {'s','e','t','D','a','t','e',0}; -static const WCHAR setUTCDateW[] = {'s','e','t','U','T','C','D','a','t','e',0}; -static const WCHAR setMonthW[] = {'s','e','t','M','o','n','t','h',0}; -static const WCHAR setUTCMonthW[] = {'s','e','t','U','T','C','M','o','n','t','h',0}; -static const WCHAR setFullYearW[] = {'s','e','t','F','u','l','l','Y','e','a','r',0}; -static const WCHAR setUTCFullYearW[] = {'s','e','t','U','T','C','F','u','l','l','Y','e','a','r',0}; -static const WCHAR getYearW[] = {'g','e','t','Y','e','a','r',0}; - -static const WCHAR UTCW[] = {'U','T','C',0}; -static const WCHAR parseW[] = {'p','a','r','s','e',0}; - -/*ECMA-262 3rd Edition 15.9.1.2 */ -#define MS_PER_DAY 86400000 -#define MS_PER_HOUR 3600000 -#define MS_PER_MINUTE 60000 - -/* ECMA-262 3rd Edition 15.9.1.2 */ -static inline DOUBLE day(DOUBLE time) -{ - return floor(time / MS_PER_DAY); -} - -/* ECMA-262 3rd Edition 15.9.1.2 */ -static inline DOUBLE time_within_day(DOUBLE time) -{ - DOUBLE ret; - - ret = fmod(time, MS_PER_DAY); - if(ret < 0) - ret += MS_PER_DAY; - - return ret; -} - -/* ECMA-262 3rd Edition 15.9.1.3 */ -static inline DOUBLE days_in_year(DOUBLE year) -{ - int y; - - if(year != (int)year) - return ret_nan(); - - y = year; - if(y%4 != 0) return 365; - if(y%100 != 0) return 366; - if(y%400 != 0) return 365; - return 366; -} - -/* ECMA-262 3rd Edition 15.9.1.3 */ -static inline DOUBLE day_from_year(DOUBLE year) -{ - if(year != (int)year) - return ret_nan(); - - return floor(365.0*(year-1970) + floor((year-1969)/4) - - floor((year-1901)/100) + floor((year-1601)/400)); -} - -static inline int day_from_month(int month, int in_leap_year) -{ - switch(month) - { - case 0: - return 0; - case 1: - return 31; - case 2: - return 59+in_leap_year; - case 3: - return 90+in_leap_year; - case 4: - return 120+in_leap_year; - case 5: - return 151+in_leap_year; - case 6: - return 181+in_leap_year; - case 7: - return 212+in_leap_year; - case 8: - return 243+in_leap_year; - case 9: - return 273+in_leap_year; - case 10: - return 304+in_leap_year; - default: - return 334+in_leap_year; - } -} - -/* ECMA-262 3rd Edition 15.9.1.3 */ -static inline DOUBLE time_from_year(DOUBLE year) -{ - return MS_PER_DAY*day_from_year(year); -} - -/* ECMA-262 3rd Edition 15.9.1.3 */ -static inline DOUBLE year_from_time(DOUBLE time) -{ - int y; - - if(isnan(time)) - return ret_nan(); - - y = 1970 + time/365.25/MS_PER_DAY; - - if(time_from_year(y) > time) - while(time_from_year(y) > time) y--; - else - while(time_from_year(y+1)<=time) y++; - - return y; -} - -/* ECMA-262 3rd Edition 15.9.1.3 */ -static inline int in_leap_year(DOUBLE time) -{ - if(days_in_year(year_from_time(time))==366) - return 1; - return 0; -} - -/* ECMA-262 3rd Edition 15.9.1.4 */ -static inline int day_within_year(DOUBLE time) -{ - return day(time) - day_from_year(year_from_time(time)); -} - -/* ECMA-262 3rd Edition 15.9.1.4 */ -static inline DOUBLE month_from_time(DOUBLE time) -{ - int ily = in_leap_year(time); - int dwy = day_within_year(time); - - if(isnan(time)) - return ret_nan(); - - if(0<=dwy && dwy<31) return 0; - if(dwy < 59+ily) return 1; - if(dwy < 90+ily) return 2; - if(dwy < 120+ily) return 3; - if(dwy < 151+ily) return 4; - if(dwy < 181+ily) return 5; - if(dwy < 212+ily) return 6; - if(dwy < 243+ily) return 7; - if(dwy < 273+ily) return 8; - if(dwy < 304+ily) return 9; - if(dwy < 334+ily) return 10; - return 11; -} - -/* ECMA-262 3rd Edition 15.9.1.5 */ -static inline DOUBLE date_from_time(DOUBLE time) -{ - int dwy = day_within_year(time); - int ily = in_leap_year(time); - int mft = month_from_time(time); - - if(isnan(time)) - return ret_nan(); - - if(mft==0) return dwy+1; - if(mft==1) return dwy-30; - if(mft==2) return dwy-58-ily; - if(mft==3) return dwy-89-ily; - if(mft==4) return dwy-119-ily; - if(mft==5) return dwy-150-ily; - if(mft==6) return dwy-180-ily; - if(mft==7) return dwy-211-ily; - if(mft==8) return dwy-242-ily; - if(mft==9) return dwy-272-ily; - if(mft==10) return dwy-303-ily; - return dwy-333-ily; -} - -/* ECMA-262 3rd Edition 15.9.1.6 */ -static inline DOUBLE week_day(DOUBLE time) -{ - DOUBLE ret; - - if(isnan(time)) - return ret_nan(); - - ret = fmod(day(time)+4, 7); - if(ret<0) ret += 7; - - return ret; -} - -static inline DOUBLE convert_time(int year, SYSTEMTIME st) -{ - DOUBLE time; - int set_week_day; - - if(st.wMonth == 0) - return ret_nan(); - - if(st.wYear != 0) - year = st.wYear; - - time = time_from_year(year); - time += (DOUBLE)day_from_month(st.wMonth-1, in_leap_year(time)) * MS_PER_DAY; - - if(st.wYear == 0) { - set_week_day = st.wDayOfWeek-week_day(time); - if(set_week_day < 0) - set_week_day += 7; - time += set_week_day * MS_PER_DAY; - - time += (DOUBLE)(st.wDay-1) * 7 * MS_PER_DAY; - if(month_from_time(time) != st.wMonth-1) - time -= 7 * MS_PER_DAY; - } - else - time += st.wDay * MS_PER_DAY; - - time += st.wHour * MS_PER_HOUR; - time += st.wMinute * MS_PER_MINUTE; - - return time; -} - -/* ECMA-262 3rd Edition 15.9.1.9 */ -static inline DOUBLE daylight_saving_ta(DOUBLE time, DateInstance *date) -{ - int year = year_from_time(time); - DOUBLE standardTime, daylightTime; - - if(isnan(time)) - return 0; - - standardTime = convert_time(year, date->standardDate); - daylightTime = convert_time(year, date->daylightDate); - - if(isnan(standardTime) || isnan(daylightTime)) - return 0; - else if(standardTime > daylightTime) { - if(daylightTime <= time && time < standardTime) - return date->daylightBias; - - return date->standardBias; - } - else { - if(standardTime <= time && time < daylightTime) - return date->standardBias; - - return date->daylightBias; - } -} - -/* ECMA-262 3rd Edition 15.9.1.9 */ -static inline DOUBLE local_time(DOUBLE time, DateInstance *date) -{ - return time - (daylight_saving_ta(time, date)+date->bias)*MS_PER_MINUTE; -} - -/* ECMA-262 3rd Edition 15.9.1.9 */ -static inline DOUBLE utc(DOUBLE time, DateInstance *date) -{ - time += date->bias * MS_PER_MINUTE; - return time + daylight_saving_ta(time, date)*MS_PER_MINUTE; -} - -/* ECMA-262 3rd Edition 15.9.1.10 */ -static inline DOUBLE hour_from_time(DOUBLE time) -{ - DOUBLE ret; - - if(isnan(time)) - return ret_nan(); - - ret = fmod(floor(time/MS_PER_HOUR), 24); - if(ret<0) ret += 24; - - return ret; -} - -/* ECMA-262 3rd Edition 15.9.1.10 */ -static inline DOUBLE min_from_time(DOUBLE time) -{ - DOUBLE ret; - - if(isnan(time)) - return ret_nan(); - - ret = fmod(floor(time/MS_PER_MINUTE), 60); - if(ret<0) ret += 60; - - return ret; -} - -/* ECMA-262 3rd Edition 15.9.1.10 */ -static inline DOUBLE sec_from_time(DOUBLE time) -{ - DOUBLE ret; - - if(isnan(time)) - return ret_nan(); - - ret = fmod(floor(time/1000), 60); - if(ret<0) ret += 60; - - return ret; -} - -/* ECMA-262 3rd Edition 15.9.1.10 */ -static inline DOUBLE ms_from_time(DOUBLE time) -{ - DOUBLE ret; - - if(isnan(time)) - return ret_nan(); - - ret = fmod(time, 1000); - if(ret<0) ret += 1000; - - return ret; -} - -/* ECMA-262 3rd Edition 15.9.1.11 */ -static inline DOUBLE make_time(DOUBLE hour, DOUBLE min, DOUBLE sec, DOUBLE ms) -{ - return hour*MS_PER_HOUR + min*MS_PER_MINUTE + sec*1000 + ms; -} - -/* ECMA-262 3rd Edition 15.9.1.12 */ -static inline DOUBLE make_day(DOUBLE year, DOUBLE month, DOUBLE day) -{ - DOUBLE time; - - year += floor(month/12); - - month = fmod(month, 12); - if(month<0) month += 12; - - time = time_from_year(year); - - day += floor(time / MS_PER_DAY); - day += day_from_month(month, in_leap_year(time)); - - return day-1; -} - -/* ECMA-262 3rd Edition 15.9.1.13 */ -static inline DOUBLE make_date(DOUBLE day, DOUBLE time) -{ - return day*MS_PER_DAY + time; -} - -/* ECMA-262 3rd Edition 15.9.1.14 */ -static inline DOUBLE time_clip(DOUBLE time) -{ - if(8.64e15 < time || time < -8.64e15) { - return ret_nan(); - } - - return floor(time); -} - -static SYSTEMTIME create_systemtime(DOUBLE time) -{ - SYSTEMTIME st; - - st.wYear = year_from_time(time); - st.wMonth = month_from_time(time) + 1; - st.wDayOfWeek = week_day(time); - st.wDay = date_from_time(time); - st.wHour = hour_from_time(time); - st.wMinute = min_from_time(time); - st.wSecond = sec_from_time(time); - st.wMilliseconds = ms_from_time(time); - - return st; -} - -static inline HRESULT date_to_string(DOUBLE time, BOOL show_offset, int offset, VARIANT *retv) -{ - static const WCHAR NaNW[] = { 'N','a','N',0 }; - static const WCHAR formatW[] = { '%','s',' ','%','s',' ','%','d',' ', - '%','0','2','d',':','%','0','2','d',':','%','0','2','d',' ', - 'U','T','C','%','c','%','0','2','d','%','0','2','d',' ','%','d','%','s',0 }; - static const WCHAR formatUTCW[] = { '%','s',' ','%','s',' ','%','d',' ', - '%','0','2','d',':','%','0','2','d',':','%','0','2','d',' ', - 'U','T','C',' ','%','d','%','s',0 }; - static const WCHAR formatNoOffsetW[] = { '%','s',' ','%','s',' ', - '%','d',' ','%','0','2','d',':','%','0','2','d',':', - '%','0','2','d',' ','%','d','%','s',0 }; - static const WCHAR ADW[] = { 0 }; - static const WCHAR BCW[] = { ' ','B','.','C','.',0 }; - - static const DWORD week_ids[] = { LOCALE_SABBREVDAYNAME7, LOCALE_SABBREVDAYNAME1, - LOCALE_SABBREVDAYNAME2, LOCALE_SABBREVDAYNAME3, LOCALE_SABBREVDAYNAME4, - LOCALE_SABBREVDAYNAME5, LOCALE_SABBREVDAYNAME6 }; - static const DWORD month_ids[] = { LOCALE_SABBREVMONTHNAME1, LOCALE_SABBREVMONTHNAME2, - LOCALE_SABBREVMONTHNAME3, LOCALE_SABBREVMONTHNAME4, - LOCALE_SABBREVMONTHNAME5, LOCALE_SABBREVMONTHNAME6, - LOCALE_SABBREVMONTHNAME7, LOCALE_SABBREVMONTHNAME8, - LOCALE_SABBREVMONTHNAME9, LOCALE_SABBREVMONTHNAME10, - LOCALE_SABBREVMONTHNAME11, LOCALE_SABBREVMONTHNAME12 }; - - BOOL formatAD = TRUE; - BSTR week, month; - BSTR date_str; - int len, size, year, day; - DWORD lcid_en, week_id, month_id; - WCHAR sign = '-'; - - if(isnan(time)) { - if(retv) { - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = SysAllocString(NaNW); - if(!V_BSTR(retv)) - return E_OUTOFMEMORY; - } - return S_OK; - } - - if(retv) { - len = 21; - - lcid_en = MAKELCID(MAKELANGID(LANG_ENGLISH,SUBLANG_ENGLISH_US),SORT_DEFAULT); - - week_id = week_ids[(int)week_day(time)]; - size = GetLocaleInfoW(lcid_en, week_id, NULL, 0); - week = SysAllocStringLen(NULL, size); - if(!week) - return E_OUTOFMEMORY; - GetLocaleInfoW(lcid_en, week_id, week, size); - len += size-1; - - month_id = month_ids[(int)month_from_time(time)]; - size = GetLocaleInfoW(lcid_en, month_id, NULL, 0); - month = SysAllocStringLen(NULL, size); - if(!month) { - SysFreeString(week); - return E_OUTOFMEMORY; - } - GetLocaleInfoW(lcid_en, month_id, month, size); - len += size-1; - - year = year_from_time(time); - if(year<0) - year = -year+1; - do { - year /= 10; - len++; - } while(year); - - year = year_from_time(time); - if(year<0) { - formatAD = FALSE; - year = -year+1; - len += 5; - } - - day = date_from_time(time); - do { - day /= 10; - len++; - } while(day); - day = date_from_time(time); - - if(!show_offset) len -= 9; - else if(offset == 0) len -= 5; - else if(offset < 0) { - sign = '+'; - offset = -offset; - } - - date_str = SysAllocStringLen(NULL, len); - if(!date_str) { - SysFreeString(week); - SysFreeString(month); - return E_OUTOFMEMORY; - } - - if(!show_offset) - sprintfW(date_str, formatNoOffsetW, week, month, day, - (int)hour_from_time(time), (int)min_from_time(time), - (int)sec_from_time(time), year, formatAD?ADW:BCW); - else if(offset) - sprintfW(date_str, formatW, week, month, day, - (int)hour_from_time(time), (int)min_from_time(time), - (int)sec_from_time(time), sign, offset/60, offset%60, - year, formatAD?ADW:BCW); - else - sprintfW(date_str, formatUTCW, week, month, day, - (int)hour_from_time(time), (int)min_from_time(time), - (int)sec_from_time(time), year, formatAD?ADW:BCW); - - SysFreeString(week); - SysFreeString(month); - - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = date_str; - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.1.2 */ -static HRESULT Date_toString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - DateInstance *date; - DOUBLE time; - int offset; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - date = (DateInstance*)dispex; - time = local_time(date->time, date); - offset = date->bias + - daylight_saving_ta(time, date); - - return date_to_string(time, TRUE, offset, retv); -} - -/* ECMA-262 3rd Edition 15.9.1.5 */ -static HRESULT Date_toLocaleString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - static const WCHAR NaNW[] = { 'N','a','N',0 }; - SYSTEMTIME st; - DateInstance *date; - BSTR date_str; - int date_len, time_len; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - date = (DateInstance*)dispex; - - if(isnan(date->time)) { - if(retv) { - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = SysAllocString(NaNW); - if(!V_BSTR(retv)) - return E_OUTOFMEMORY; - } - return S_OK; - } - - st = create_systemtime(local_time(date->time, date)); - - if(st.wYear<1601 || st.wYear>9999) - return Date_toString(dispex, lcid, flags, dp, retv, ei, caller); - - if(retv) { - date_len = GetDateFormatW(lcid, DATE_LONGDATE, &st, NULL, NULL, 0); - time_len = GetTimeFormatW(lcid, 0, &st, NULL, NULL, 0); - date_str = SysAllocStringLen(NULL, date_len+time_len-1); - if(!date_str) - return E_OUTOFMEMORY; - GetDateFormatW(lcid, DATE_LONGDATE, &st, NULL, date_str, date_len); - GetTimeFormatW(lcid, 0, &st, NULL, &date_str[date_len], time_len); - date_str[date_len-1] = ' '; - - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = date_str; - } - return S_OK; -} - -static HRESULT Date_hasOwnProperty(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - FIXME("\n"); - return E_NOTIMPL; -} - -static HRESULT Date_propertyIsEnumerable(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - FIXME("\n"); - return E_NOTIMPL; -} - -static HRESULT Date_isPrototypeOf(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - FIXME("\n"); - return E_NOTIMPL; -} - -static HRESULT Date_valueOf(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - num_set_val(retv, date->time); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.42 */ -static HRESULT Date_toUTCString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - static const WCHAR NaNW[] = { 'N','a','N',0 }; - static const WCHAR formatADW[] = { '%','s',',',' ','%','d',' ','%','s',' ','%','d',' ', - '%','0','2','d',':','%','0','2','d',':','%','0','2','d',' ','U','T','C',0 }; - static const WCHAR formatBCW[] = { '%','s',',',' ','%','d',' ','%','s',' ','%','d',' ','B','.','C','.',' ', - '%','0','2','d',':','%','0','2','d',':','%','0','2','d',' ','U','T','C',0 }; - - static const DWORD week_ids[] = { LOCALE_SABBREVDAYNAME7, LOCALE_SABBREVDAYNAME1, - LOCALE_SABBREVDAYNAME2, LOCALE_SABBREVDAYNAME3, LOCALE_SABBREVDAYNAME4, - LOCALE_SABBREVDAYNAME5, LOCALE_SABBREVDAYNAME6 }; - static const DWORD month_ids[] = { LOCALE_SABBREVMONTHNAME1, LOCALE_SABBREVMONTHNAME2, - LOCALE_SABBREVMONTHNAME3, LOCALE_SABBREVMONTHNAME4, - LOCALE_SABBREVMONTHNAME5, LOCALE_SABBREVMONTHNAME6, - LOCALE_SABBREVMONTHNAME7, LOCALE_SABBREVMONTHNAME8, - LOCALE_SABBREVMONTHNAME9, LOCALE_SABBREVMONTHNAME10, - LOCALE_SABBREVMONTHNAME11, LOCALE_SABBREVMONTHNAME12 }; - - BOOL formatAD = TRUE; - BSTR week, month; - DateInstance *date; - BSTR date_str; - int len, size, year, day; - DWORD lcid_en, week_id, month_id; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - date = (DateInstance*)dispex; - - if(isnan(date->time)) { - if(retv) { - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = SysAllocString(NaNW); - if(!V_BSTR(retv)) - return E_OUTOFMEMORY; - } - return S_OK; - } - - if(retv) { - len = 17; - - lcid_en = MAKELCID(MAKELANGID(LANG_ENGLISH,SUBLANG_ENGLISH_US),SORT_DEFAULT); - - week_id = week_ids[(int)week_day(date->time)]; - size = GetLocaleInfoW(lcid_en, week_id, NULL, 0); - week = SysAllocStringLen(NULL, size); - if(!week) - return E_OUTOFMEMORY; - GetLocaleInfoW(lcid_en, week_id, week, size); - len += size-1; - - month_id = month_ids[(int)month_from_time(date->time)]; - size = GetLocaleInfoW(lcid_en, month_id, NULL, 0); - month = SysAllocStringLen(NULL, size); - if(!month) { - SysFreeString(week); - return E_OUTOFMEMORY; - } - GetLocaleInfoW(lcid_en, month_id, month, size); - len += size-1; - - year = year_from_time(date->time); - if(year<0) - year = -year+1; - do { - year /= 10; - len++; - } while(year); - - year = year_from_time(date->time); - if(year<0) { - formatAD = FALSE; - year = -year+1; - len += 5; - } - - day = date_from_time(date->time); - do { - day /= 10; - len++; - } while(day); - day = date_from_time(date->time); - - date_str = SysAllocStringLen(NULL, len); - if(!date_str) { - SysFreeString(week); - SysFreeString(month); - return E_OUTOFMEMORY; - } - sprintfW(date_str, formatAD?formatADW:formatBCW, week, day, month, year, - (int)hour_from_time(date->time), (int)min_from_time(date->time), - (int)sec_from_time(date->time)); - - SysFreeString(week); - SysFreeString(month); - - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = date_str; - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.3 */ -static HRESULT Date_toDateString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - static const WCHAR NaNW[] = { 'N','a','N',0 }; - static const WCHAR formatADW[] = { '%','s',' ','%','s',' ','%','d',' ','%','d',0 }; - static const WCHAR formatBCW[] = { '%','s',' ','%','s',' ','%','d',' ','%','d',' ','B','.','C','.',0 }; - - static const DWORD week_ids[] = { LOCALE_SABBREVDAYNAME7, LOCALE_SABBREVDAYNAME1, - LOCALE_SABBREVDAYNAME2, LOCALE_SABBREVDAYNAME3, LOCALE_SABBREVDAYNAME4, - LOCALE_SABBREVDAYNAME5, LOCALE_SABBREVDAYNAME6 }; - static const DWORD month_ids[] = { LOCALE_SABBREVMONTHNAME1, LOCALE_SABBREVMONTHNAME2, - LOCALE_SABBREVMONTHNAME3, LOCALE_SABBREVMONTHNAME4, - LOCALE_SABBREVMONTHNAME5, LOCALE_SABBREVMONTHNAME6, - LOCALE_SABBREVMONTHNAME7, LOCALE_SABBREVMONTHNAME8, - LOCALE_SABBREVMONTHNAME9, LOCALE_SABBREVMONTHNAME10, - LOCALE_SABBREVMONTHNAME11, LOCALE_SABBREVMONTHNAME12 }; - - BOOL formatAD = TRUE; - BSTR week, month; - DateInstance *date; - BSTR date_str; - DOUBLE time; - int len, size, year, day; - DWORD lcid_en, week_id, month_id; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - date = (DateInstance*)dispex; - - if(isnan(date->time)) { - if(retv) { - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = SysAllocString(NaNW); - if(!V_BSTR(retv)) - return E_OUTOFMEMORY; - } - return S_OK; - } - - time = local_time(date->time, date); - - if(retv) { - len = 5; - - lcid_en = MAKELCID(MAKELANGID(LANG_ENGLISH,SUBLANG_ENGLISH_US),SORT_DEFAULT); - - week_id = week_ids[(int)week_day(time)]; - size = GetLocaleInfoW(lcid_en, week_id, NULL, 0); - week = SysAllocStringLen(NULL, size); - if(!week) - return E_OUTOFMEMORY; - GetLocaleInfoW(lcid_en, week_id, week, size); - len += size-1; - - month_id = month_ids[(int)month_from_time(time)]; - size = GetLocaleInfoW(lcid_en, month_id, NULL, 0); - month = SysAllocStringLen(NULL, size); - if(!month) { - SysFreeString(week); - return E_OUTOFMEMORY; - } - GetLocaleInfoW(lcid_en, month_id, month, size); - len += size-1; - - year = year_from_time(time); - if(year<0) - year = -year+1; - do { - year /= 10; - len++; - } while(year); - - year = year_from_time(time); - if(year<0) { - formatAD = FALSE; - year = -year+1; - len += 5; - } - - day = date_from_time(time); - do { - day /= 10; - len++; - } while(day); - day = date_from_time(time); - - date_str = SysAllocStringLen(NULL, len); - if(!date_str) { - SysFreeString(week); - SysFreeString(month); - return E_OUTOFMEMORY; - } - sprintfW(date_str, formatAD?formatADW:formatBCW, week, month, day, year); - - SysFreeString(week); - SysFreeString(month); - - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = date_str; - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.4 */ -static HRESULT Date_toTimeString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - static const WCHAR NaNW[] = { 'N','a','N',0 }; - static const WCHAR formatW[] = { '%','0','2','d',':','%','0','2','d',':','%','0','2','d', - ' ','U','T','C','%','c','%','0','2','d','%','0','2','d',0 }; - static const WCHAR formatUTCW[] = { '%','0','2','d',':','%','0','2','d', - ':','%','0','2','d',' ','U','T','C',0 }; - DateInstance *date; - BSTR date_str; - DOUBLE time; - WCHAR sign; - int offset; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - date = (DateInstance*)dispex; - - if(isnan(date->time)) { - if(retv) { - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = SysAllocString(NaNW); - if(!V_BSTR(retv)) - return E_OUTOFMEMORY; - } - return S_OK; - } - - time = local_time(date->time, date); - - if(retv) { - date_str = SysAllocStringLen(NULL, 17); - if(!date_str) - return E_OUTOFMEMORY; - - offset = date->bias + - daylight_saving_ta(time, date); - - if(offset < 0) { - sign = '+'; - offset = -offset; - } - else sign = '-'; - - if(offset) - sprintfW(date_str, formatW, (int)hour_from_time(time), - (int)min_from_time(time), (int)sec_from_time(time), - sign, offset/60, offset%60); - else - sprintfW(date_str, formatUTCW, (int)hour_from_time(time), - (int)min_from_time(time), (int)sec_from_time(time)); - - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = date_str; - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.6 */ -static HRESULT Date_toLocaleDateString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - static const WCHAR NaNW[] = { 'N','a','N',0 }; - SYSTEMTIME st; - DateInstance *date; - BSTR date_str; - int len; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - date = (DateInstance*)dispex; - - if(isnan(date->time)) { - if(retv) { - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = SysAllocString(NaNW); - if(!V_BSTR(retv)) - return E_OUTOFMEMORY; - } - return S_OK; - } - - st = create_systemtime(local_time(date->time, date)); - - if(st.wYear<1601 || st.wYear>9999) - return Date_toDateString(dispex, lcid, flags, dp, retv, ei, caller); - - if(retv) { - len = GetDateFormatW(lcid, DATE_LONGDATE, &st, NULL, NULL, 0); - date_str = SysAllocStringLen(NULL, len); - if(!date_str) - return E_OUTOFMEMORY; - GetDateFormatW(lcid, DATE_LONGDATE, &st, NULL, date_str, len); - - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = date_str; - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.7 */ -static HRESULT Date_toLocaleTimeString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - static const WCHAR NaNW[] = { 'N','a','N',0 }; - SYSTEMTIME st; - DateInstance *date; - BSTR date_str; - int len; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - date = (DateInstance*)dispex; - - if(isnan(date->time)) { - if(retv) { - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = SysAllocString(NaNW); - if(!V_BSTR(retv)) - return E_OUTOFMEMORY; - } - return S_OK; - } - - st = create_systemtime(local_time(date->time, date)); - - if(st.wYear<1601 || st.wYear>9999) - return Date_toTimeString(dispex, lcid, flags, dp, retv, ei, caller); - - if(retv) { - len = GetTimeFormatW(lcid, 0, &st, NULL, NULL, 0); - date_str = SysAllocStringLen(NULL, len); - if(!date_str) - return E_OUTOFMEMORY; - GetTimeFormatW(lcid, 0, &st, NULL, date_str, len); - - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = date_str; - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.9 */ -static HRESULT Date_getTime(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - num_set_val(retv, date->time); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.10 */ -static HRESULT Date_getFullYear(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - DOUBLE time = local_time(date->time, date); - - num_set_val(retv, year_from_time(time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.11 */ -static HRESULT Date_getUTCFullYear(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - num_set_val(retv, year_from_time(date->time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.12 */ -static HRESULT Date_getMonth(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - DOUBLE time = local_time(date->time, date); - - num_set_val(retv, month_from_time(time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.13 */ -static HRESULT Date_getUTCMonth(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - num_set_val(retv, month_from_time(date->time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.14 */ -static HRESULT Date_getDate(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - DOUBLE time = local_time(date->time, date); - - num_set_val(retv, date_from_time(time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.15 */ -static HRESULT Date_getUTCDate(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - num_set_val(retv, date_from_time(date->time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.16 */ -static HRESULT Date_getDay(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - DOUBLE time = local_time(date->time, date); - - num_set_val(retv, week_day(time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.17 */ -static HRESULT Date_getUTCDay(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - num_set_val(retv, week_day(date->time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.18 */ -static HRESULT Date_getHours(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - DOUBLE time = local_time(date->time, date); - - num_set_val(retv, hour_from_time(time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.19 */ -static HRESULT Date_getUTCHours(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - num_set_val(retv, hour_from_time(date->time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.20 */ -static HRESULT Date_getMinutes(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - DOUBLE time = local_time(date->time, date); - - num_set_val(retv, min_from_time(time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.21 */ -static HRESULT Date_getUTCMinutes(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - num_set_val(retv, min_from_time(date->time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.22 */ -static HRESULT Date_getSeconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - DOUBLE time = local_time(date->time, date); - - num_set_val(retv, sec_from_time(time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.23 */ -static HRESULT Date_getUTCSeconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - num_set_val(retv, sec_from_time(date->time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.24 */ -static HRESULT Date_getMilliseconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - DOUBLE time = local_time(date->time, date); - - num_set_val(retv, ms_from_time(time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.25 */ -static HRESULT Date_getUTCMilliseconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - num_set_val(retv, ms_from_time(date->time)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.26 */ -static HRESULT Date_getTimezoneOffset(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(retv) { - DateInstance *date = (DateInstance*)dispex; - num_set_val(retv, floor( - (date->time-local_time(date->time, date))/MS_PER_MINUTE)); - } - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.27 */ -static HRESULT Date_setTime(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - - date = (DateInstance*)dispex; - date->time = time_clip(num_val(&v)); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.28 */ -static HRESULT Date_setMilliseconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - - date = (DateInstance*)dispex; - t = local_time(date->time, date); - t = make_date(day(t), make_time(hour_from_time(t), min_from_time(t), - sec_from_time(t), num_val(&v))); - date->time = time_clip(utc(t, date)); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.29 */ -static HRESULT Date_setUTCMilliseconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - - date = (DateInstance*)dispex; - t = date->time; - t = make_date(day(t), make_time(hour_from_time(t), min_from_time(t), - sec_from_time(t), num_val(&v))); - date->time = time_clip(t); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.30 */ -static HRESULT Date_setSeconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t, sec, ms; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - date = (DateInstance*)dispex; - t = local_time(date->time, date); - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - sec = num_val(&v); - - if(arg_cnt(dp) > 1) { - hres = to_number(dispex->ctx, get_arg(dp, 1), ei, &v); - if(FAILED(hres)) - return hres; - ms = num_val(&v); - } - else ms = ms_from_time(t); - - t = make_date(day(t), make_time(hour_from_time(t), - min_from_time(t), sec, ms)); - date->time = time_clip(utc(t, date)); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.31 */ -static HRESULT Date_setUTCSeconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t, sec, ms; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - date = (DateInstance*)dispex; - t = date->time; - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - sec = num_val(&v); - - if(arg_cnt(dp) > 1) { - hres = to_number(dispex->ctx, get_arg(dp, 1), ei, &v); - if(FAILED(hres)) - return hres; - ms = num_val(&v); - } - else ms = ms_from_time(t); - - t = make_date(day(t), make_time(hour_from_time(t), - min_from_time(t), sec, ms)); - date->time = time_clip(t); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.33 */ -static HRESULT Date_setMinutes(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t, min, sec, ms; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - date = (DateInstance*)dispex; - t = local_time(date->time, date); - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - min = num_val(&v); - - if(arg_cnt(dp) > 1) { - hres = to_number(dispex->ctx, get_arg(dp, 1), ei, &v); - if(FAILED(hres)) - return hres; - sec = num_val(&v); - } - else sec = sec_from_time(t); - - if(arg_cnt(dp) > 2) { - hres = to_number(dispex->ctx, get_arg(dp, 2), ei, &v); - if(FAILED(hres)) - return hres; - ms = num_val(&v); - } - else ms = ms_from_time(t); - - t = make_date(day(t), make_time(hour_from_time(t), - min, sec, ms)); - date->time = time_clip(utc(t, date)); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.34 */ -static HRESULT Date_setUTCMinutes(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t, min, sec, ms; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - date = (DateInstance*)dispex; - t = date->time; - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - min = num_val(&v); - - if(arg_cnt(dp) > 1) { - hres = to_number(dispex->ctx, get_arg(dp, 1), ei, &v); - if(FAILED(hres)) - return hres; - sec = num_val(&v); - } - else sec = sec_from_time(t); - - if(arg_cnt(dp) > 2) { - hres = to_number(dispex->ctx, get_arg(dp, 2), ei, &v); - if(FAILED(hres)) - return hres; - ms = num_val(&v); - } - else ms = ms_from_time(t); - - t = make_date(day(t), make_time(hour_from_time(t), - min, sec, ms)); - date->time = time_clip(t); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.35 */ -static HRESULT Date_setHours(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t, hour, min, sec, ms; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - date = (DateInstance*)dispex; - t = local_time(date->time, date); - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - hour = num_val(&v); - - if(arg_cnt(dp) > 1) { - hres = to_number(dispex->ctx, get_arg(dp, 1), ei, &v); - if(FAILED(hres)) - return hres; - min = num_val(&v); - } - else min = min_from_time(t); - - if(arg_cnt(dp) > 2) { - hres = to_number(dispex->ctx, get_arg(dp, 2), ei, &v); - if(FAILED(hres)) - return hres; - sec = num_val(&v); - } - else sec = sec_from_time(t); - - if(arg_cnt(dp) > 3) { - hres = to_number(dispex->ctx, get_arg(dp, 3), ei, &v); - if(FAILED(hres)) - return hres; - ms = num_val(&v); - } - else ms = ms_from_time(t); - - t = make_date(day(t), make_time(hour, min, sec, ms)); - date->time = time_clip(utc(t, date)); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.36 */ -static HRESULT Date_setUTCHours(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t, hour, min, sec, ms; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - date = (DateInstance*)dispex; - t = date->time; - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - hour = num_val(&v); - - if(arg_cnt(dp) > 1) { - hres = to_number(dispex->ctx, get_arg(dp, 1), ei, &v); - if(FAILED(hres)) - return hres; - min = num_val(&v); - } - else min = min_from_time(t); - - if(arg_cnt(dp) > 2) { - hres = to_number(dispex->ctx, get_arg(dp, 2), ei, &v); - if(FAILED(hres)) - return hres; - sec = num_val(&v); - } - else sec = sec_from_time(t); - - if(arg_cnt(dp) > 3) { - hres = to_number(dispex->ctx, get_arg(dp, 3), ei, &v); - if(FAILED(hres)) - return hres; - ms = num_val(&v); - } - else ms = ms_from_time(t); - - t = make_date(day(t), make_time(hour, min, sec, ms)); - date->time = time_clip(t); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.36 */ -static HRESULT Date_setDate(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - - date = (DateInstance*)dispex; - t = local_time(date->time, date); - t = make_date(make_day(year_from_time(t), month_from_time(t), - num_val(&v)), time_within_day(t)); - date->time = time_clip(utc(t, date)); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.37 */ -static HRESULT Date_setUTCDate(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - - date = (DateInstance*)dispex; - t = date->time; - t = make_date(make_day(year_from_time(t), month_from_time(t), - num_val(&v)), time_within_day(t)); - date->time = time_clip(t); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.38 */ -static HRESULT Date_setMonth(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t, month, ddate; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - date = (DateInstance*)dispex; - t = local_time(date->time, date); - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - month = num_val(&v); - - if(arg_cnt(dp) > 1) { - hres = to_number(dispex->ctx, get_arg(dp, 1), ei, &v); - if(FAILED(hres)) - return hres; - ddate = num_val(&v); - } - else ddate = date_from_time(t); - - t = make_date(make_day(year_from_time(t), month, ddate), - time_within_day(t)); - date->time = time_clip(utc(t, date)); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.39 */ -static HRESULT Date_setUTCMonth(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t, month, ddate; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - date = (DateInstance*)dispex; - t = date->time; - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - month = num_val(&v); - - if(arg_cnt(dp) > 1) { - hres = to_number(dispex->ctx, get_arg(dp, 1), ei, &v); - if(FAILED(hres)) - return hres; - ddate = num_val(&v); - } - else ddate = date_from_time(t); - - t = make_date(make_day(year_from_time(t), month, ddate), - time_within_day(t)); - date->time = time_clip(t); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.40 */ -static HRESULT Date_setFullYear(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t, year, month, ddate; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - date = (DateInstance*)dispex; - t = local_time(date->time, date); - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - year = num_val(&v); - - if(arg_cnt(dp) > 1) { - hres = to_number(dispex->ctx, get_arg(dp, 1), ei, &v); - if(FAILED(hres)) - return hres; - month = num_val(&v); - } - else month = month_from_time(t); - - if(arg_cnt(dp) > 2) { - hres = to_number(dispex->ctx, get_arg(dp, 2), ei, &v); - if(FAILED(hres)) - return hres; - ddate = num_val(&v); - } - else ddate = date_from_time(t); - - t = make_date(make_day(year, month, ddate), time_within_day(t)); - date->time = time_clip(utc(t, date)); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition 15.9.5.41 */ -static HRESULT Date_setUTCFullYear(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - VARIANT v; - HRESULT hres; - DateInstance *date; - DOUBLE t, year, month, ddate; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - if(!arg_cnt(dp)) - return throw_type_error(dispex->ctx, ei, IDS_ARG_NOT_OPT, NULL); - - date = (DateInstance*)dispex; - t = date->time; - - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) - return hres; - year = num_val(&v); - - if(arg_cnt(dp) > 1) { - hres = to_number(dispex->ctx, get_arg(dp, 1), ei, &v); - if(FAILED(hres)) - return hres; - month = num_val(&v); - } - else month = month_from_time(t); - - if(arg_cnt(dp) > 2) { - hres = to_number(dispex->ctx, get_arg(dp, 2), ei, &v); - if(FAILED(hres)) - return hres; - ddate = num_val(&v); - } - else ddate = date_from_time(t); - - t = make_date(make_day(year, month, ddate), time_within_day(t)); - date->time = time_clip(t); - - if(retv) - num_set_val(retv, date->time); - - return S_OK; -} - -/* ECMA-262 3rd Edition B2.4 */ -static HRESULT Date_getYear(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - DateInstance *date; - DOUBLE t, year; - - TRACE("\n"); - - if(!is_class(dispex, JSCLASS_DATE)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_DATE, NULL); - - date = (DateInstance*)dispex; - t = local_time(date->time, date); - - - if(isnan(t)) { - if(retv) - num_set_nan(retv); - return S_OK; - } - - year = year_from_time(t); - if(retv) - num_set_val(retv, (1900<=year && year<2000)?year-1900:year); - - return S_OK; -} - -static HRESULT Date_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) -{ - TRACE("\n"); - - switch(flags) { - case INVOKE_FUNC: - return throw_type_error(dispex->ctx, ei, IDS_NOT_FUNC, NULL); - default: - FIXME("unimplemented flags %x\n", flags); - return E_NOTIMPL; - } - - return S_OK; -} - -static const builtin_prop_t Date_props[] = { - {getDateW, Date_getDate, PROPF_METHOD}, - {getDayW, Date_getDay, PROPF_METHOD}, - {getFullYearW, Date_getFullYear, PROPF_METHOD}, - {getHoursW, Date_getHours, PROPF_METHOD}, - {getMillisecondsW, Date_getMilliseconds, PROPF_METHOD}, - {getMinutesW, Date_getMinutes, PROPF_METHOD}, - {getMonthW, Date_getMonth, PROPF_METHOD}, - {getSecondsW, Date_getSeconds, PROPF_METHOD}, - {getTimeW, Date_getTime, PROPF_METHOD}, - {getTimezoneOffsetW, Date_getTimezoneOffset, PROPF_METHOD}, - {getUTCDateW, Date_getUTCDate, PROPF_METHOD}, - {getUTCDayW, Date_getUTCDay, PROPF_METHOD}, - {getUTCFullYearW, Date_getUTCFullYear, PROPF_METHOD}, - {getUTCHoursW, Date_getUTCHours, PROPF_METHOD}, - {getUTCMillisecondsW, Date_getUTCMilliseconds, PROPF_METHOD}, - {getUTCMinutesW, Date_getUTCMinutes, PROPF_METHOD}, - {getUTCMonthW, Date_getUTCMonth, PROPF_METHOD}, - {getUTCSecondsW, Date_getUTCSeconds, PROPF_METHOD}, - {getYearW, Date_getYear, PROPF_METHOD}, - {hasOwnPropertyW, Date_hasOwnProperty, PROPF_METHOD}, - {isPrototypeOfW, Date_isPrototypeOf, PROPF_METHOD}, - {propertyIsEnumerableW, Date_propertyIsEnumerable, PROPF_METHOD}, - {setDateW, Date_setDate, PROPF_METHOD}, - {setFullYearW, Date_setFullYear, PROPF_METHOD}, - {setHoursW, Date_setHours, PROPF_METHOD}, - {setMillisecondsW, Date_setMilliseconds, PROPF_METHOD}, - {setMinutesW, Date_setMinutes, PROPF_METHOD}, - {setMonthW, Date_setMonth, PROPF_METHOD}, - {setSecondsW, Date_setSeconds, PROPF_METHOD}, - {setTimeW, Date_setTime, PROPF_METHOD}, - {setUTCDateW, Date_setUTCDate, PROPF_METHOD}, - {setUTCFullYearW, Date_setUTCFullYear, PROPF_METHOD}, - {setUTCHoursW, Date_setUTCHours, PROPF_METHOD}, - {setUTCMillisecondsW, Date_setUTCMilliseconds, PROPF_METHOD}, - {setUTCMinutesW, Date_setUTCMinutes, PROPF_METHOD}, - {setUTCMonthW, Date_setUTCMonth, PROPF_METHOD}, - {setUTCSecondsW, Date_setUTCSeconds, PROPF_METHOD}, - {toDateStringW, Date_toDateString, PROPF_METHOD}, - {toLocaleDateStringW, Date_toLocaleDateString, PROPF_METHOD}, - {toLocaleStringW, Date_toLocaleString, PROPF_METHOD}, - {toLocaleTimeStringW, Date_toLocaleTimeString, PROPF_METHOD}, - {toStringW, Date_toString, PROPF_METHOD}, - {toTimeStringW, Date_toTimeString, PROPF_METHOD}, - {toUTCStringW, Date_toUTCString, PROPF_METHOD}, - {valueOfW, Date_valueOf, PROPF_METHOD}, -}; - -static const builtin_info_t Date_info = { - JSCLASS_DATE, - {NULL, Date_value, 0}, - sizeof(Date_props)/sizeof(*Date_props), - Date_props, - NULL, - NULL -}; - -static HRESULT create_date(script_ctx_t *ctx, BOOL use_constr, DOUBLE time, DispatchEx **ret) -{ - DateInstance *date; - HRESULT hres; - TIME_ZONE_INFORMATION tzi; - - GetTimeZoneInformation(&tzi); - - date = heap_alloc_zero(sizeof(DateInstance)); - if(!date) - return E_OUTOFMEMORY; - - if(use_constr) - hres = init_dispex_from_constr(&date->dispex, ctx, &Date_info, ctx->date_constr); - else - hres = init_dispex(&date->dispex, ctx, &Date_info, NULL); - if(FAILED(hres)) { - heap_free(date); - return hres; - } - - date->time = time; - date->bias = tzi.Bias; - date->standardDate = tzi.StandardDate; - date->standardBias = tzi.StandardBias; - date->daylightDate = tzi.DaylightDate; - date->daylightBias = tzi.DaylightBias; - - *ret = &date->dispex; - return S_OK; -} - -static inline HRESULT date_parse(BSTR input, VARIANT *retv) { - static const DWORD string_ids[] = { LOCALE_SMONTHNAME12, LOCALE_SMONTHNAME11, - LOCALE_SMONTHNAME10, LOCALE_SMONTHNAME9, LOCALE_SMONTHNAME8, - LOCALE_SMONTHNAME7, LOCALE_SMONTHNAME6, LOCALE_SMONTHNAME5, - LOCALE_SMONTHNAME4, LOCALE_SMONTHNAME3, LOCALE_SMONTHNAME2, - LOCALE_SMONTHNAME1, LOCALE_SDAYNAME7, LOCALE_SDAYNAME1, - LOCALE_SDAYNAME2, LOCALE_SDAYNAME3, LOCALE_SDAYNAME4, - LOCALE_SDAYNAME5, LOCALE_SDAYNAME6 }; - BSTR strings[sizeof(string_ids)/sizeof(DWORD)]; - - BSTR parse; - int input_len, parse_len = 0, nest_level = 0, i, size; - int year = 0, month = 0, day = 0, hour = 0, min = 0, sec = 0; - int ms = 0, offset = 0, hour_adjust = 0; - BOOL set_year = FALSE, set_month = FALSE, set_day = FALSE, set_hour = FALSE; - BOOL set_offset = FALSE, set_era = FALSE, ad = TRUE, set_am = FALSE, am = TRUE; - BOOL set_hour_adjust = TRUE; - TIME_ZONE_INFORMATION tzi; - DateInstance di; - DWORD lcid_en; - - if(retv) num_set_nan(retv); - - input_len = SysStringLen(input); - for(i=0; i= 0) - SysFreeString(strings[i]); - SysFreeString(parse); - return E_OUTOFMEMORY; - } - GetLocaleInfoW(lcid_en, string_ids[i], strings[i], size); - } - - for(i=0; i='0' && parse[i]<='9') { - int tmp = atoiW(&parse[i]); - while(parse[i]>='0' && parse[i]<='9') i++; - while(isspaceW(parse[i])) i++; - - if(parse[i] == ':') { - /* Time */ - if(set_hour) break; - set_hour = TRUE; - - hour = tmp; - - while(parse[i] == ':') i++; - while(isspaceW(parse[i])) i++; - if(parse[i]>='0' && parse[i]<='9') { - min = atoiW(&parse[i]); - while(parse[i]>='0' && parse[i]<='9') i++; - } - - while(isspaceW(parse[i])) i++; - while(parse[i] == ':') i++; - while(isspaceW(parse[i])) i++; - if(parse[i]>='0' && parse[i]<='9') { - sec = atoiW(&parse[i]); - while(parse[i]>='0' && parse[i]<='9') i++; - } - } - else if(parse[i]=='-' || parse[i]=='/') { - /* Short date */ - if(set_day || set_month || set_year) break; - set_day = TRUE; - set_month = TRUE; - set_year = TRUE; - - month = tmp-1; - - while(isspaceW(parse[i])) i++; - while(parse[i]=='-' || parse[i]=='/') i++; - while(isspaceW(parse[i])) i++; - if(parse[i]<'0' || parse[i]>'9') break; - day = atoiW(&parse[i]); - while(parse[i]>='0' && parse[i]<='9') i++; - - while(parse[i]=='-' || parse[i]=='/') i++; - while(isspaceW(parse[i])) i++; - if(parse[i]<'0' || parse[i]>'9') break; - year = atoiW(&parse[i]); - while(parse[i]>='0' && parse[i]<='9') i++; - } - else if(tmp<0) break; - else if(tmp<70) { - /* Day */ - if(set_day) break; - set_day = TRUE; - day = tmp; - } - else { - /* Year */ - if(set_year) break; - set_year = TRUE; - year = tmp; - } - } - else { - if(parse[i]<'A' || parse[i]>'Z') break; - else if(parse[i]=='B' && (parse[i+1]=='C' || - (parse[i+1]=='.' && parse[i+2]=='C'))) { - /* AD/BC */ - if(set_era) break; - set_era = TRUE; - ad = FALSE; - - i++; - if(parse[i] == '.') i++; - i++; - if(parse[i] == '.') i++; - } - else if(parse[i]=='A' && (parse[i+1]=='D' || - (parse[i+1]=='.' && parse[i+2]=='D'))) { - /* AD/BC */ - if(set_era) break; - set_era = TRUE; - - i++; - if(parse[i] == '.') i++; - i++; - if(parse[i] == '.') i++; - } - else if(parse[i+1]<'A' || parse[i+1]>'Z') { - /* Timezone */ - if(set_offset) break; - set_offset = TRUE; - - if(parse[i] <= 'I') hour_adjust = parse[i]-'A'+2; - else if(parse[i] == 'J') break; - else if(parse[i] <= 'M') hour_adjust = parse[i]-'K'+11; - else if(parse[i] <= 'Y') hour_adjust = parse[i]-'N'; - else hour_adjust = 1; - - i++; - if(parse[i] == '.') i++; - } - else if(parse[i]=='A' && parse[i+1]=='M') { - /* AM/PM */ - if(set_am) break; - set_am = TRUE; - am = TRUE; - i += 2; - } - else if(parse[i]=='P' && parse[i+1]=='M') { - /* AM/PM */ - if(set_am) break; - set_am = TRUE; - am = FALSE; - i += 2; - } - else if((parse[i]=='U' && parse[i+1]=='T' && parse[i+2]=='C') - || (parse[i]=='G' && parse[i+1]=='M' && parse[i+2]=='T')) { - /* Timezone */ - BOOL positive = TRUE; - - if(set_offset) break; - set_offset = TRUE; - set_hour_adjust = FALSE; - - i += 3; - while(isspaceW(parse[i])) i++; - if(parse[i] == '-') positive = FALSE; - else if(parse[i] != '+') continue; - - i++; - while(isspaceW(parse[i])) i++; - if(parse[i]<'0' || parse[i]>'9') break; - offset = atoiW(&parse[i]); - while(parse[i]>='0' && parse[i]<='9') i++; - - if(offset<24) offset *= 60; - else offset = (offset/100)*60 + offset%100; - - if(positive) offset = -offset; - } - else { - /* Month or garbage */ - int j; - - for(size=i; parse[size]>='A' && parse[size]<='Z'; size++); - size -= i; - - for(j=0; jctx, get_arg(dp,0), ei, &parse_str); - if(FAILED(hres)) - return hres; - - hres = date_parse(parse_str, retv); - - SysFreeString(parse_str); - return hres; -} - -static HRESULT DateConstr_UTC(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - VARIANT year, month, vdate, hours, minutes, seconds, ms; - DOUBLE y; - int arg_no = arg_cnt(dp); - HRESULT hres; - - TRACE("\n"); - - if(arg_no>0) { - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &year); - if(FAILED(hres)) - return hres; - y = num_val(&year); - if(0<=y && y<=99) - y += 1900; - } - else y = 1900; - - if(arg_no>1) { - hres = to_number(dispex->ctx, get_arg(dp, 1), ei, &month); - if(FAILED(hres)) - return hres; - } - else { - V_VT(&month) = VT_R8; - V_R8(&month) = 0; - } - - if(arg_no>2) { - hres = to_number(dispex->ctx, get_arg(dp, 2), ei, &vdate); - if(FAILED(hres)) - return hres; - } - else { - V_VT(&vdate) = VT_R8; - V_R8(&vdate) = 1; - } - - if(arg_no>3) { - hres = to_number(dispex->ctx, get_arg(dp, 3), ei, &hours); - if(FAILED(hres)) - return hres; - } - else { - V_VT(&hours) = VT_R8; - V_R8(&hours) = 0; - } - - if(arg_no>4) { - hres = to_number(dispex->ctx, get_arg(dp, 4), ei, &minutes); - if(FAILED(hres)) - return hres; - } - else { - V_VT(&minutes) = VT_R8; - V_R8(&minutes) = 0; - } - - if(arg_no>5) { - hres = to_number(dispex->ctx, get_arg(dp, 5), ei, &seconds); - if(FAILED(hres)) - return hres; - } - else { - V_VT(&seconds) = VT_R8; - V_R8(&seconds) = 0; - } - - if(arg_no>6) { - hres = to_number(dispex->ctx, get_arg(dp, 6), ei, &ms); - if(FAILED(hres)) - return hres; - } - else { - V_VT(&ms) = VT_R8; - V_R8(&ms) = 0; - } - - if(retv) { - V_VT(retv) = VT_R8; - V_R8(retv) = time_clip(make_date( - make_day(y, num_val(&month), num_val(&vdate)), - make_time(num_val(&hours), num_val(&minutes), - num_val(&seconds), num_val(&ms)))); - } - - return S_OK; -} - -static HRESULT DateConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - DispatchEx *date; - HRESULT hres; - - TRACE("\n"); - - switch(flags) { - case DISPATCH_CONSTRUCT: - switch(arg_cnt(dp)) { - /* ECMA-262 3rd Edition 15.9.3.3 */ - case 0: { - FILETIME time; - LONGLONG lltime; - - GetSystemTimeAsFileTime(&time); - lltime = ((LONGLONG)time.dwHighDateTime<<32) - + time.dwLowDateTime; - - hres = create_date(dispex->ctx, TRUE, lltime/10000-TIME_EPOCH, &date); - if(FAILED(hres)) - return hres; - break; - } - - /* ECMA-262 3rd Edition 15.9.3.2 */ - case 1: { - VARIANT prim, num; - - hres = to_primitive(dispex->ctx, get_arg(dp,0), ei, &prim, NO_HINT); - if(FAILED(hres)) - return hres; - - if(V_VT(&prim) == VT_BSTR) - hres = date_parse(V_BSTR(&prim), &num); - else - hres = to_number(dispex->ctx, &prim, ei, &num); - - VariantClear(&prim); - if(FAILED(hres)) - return hres; - - hres = create_date(dispex->ctx, TRUE, time_clip(num_val(&num)), &date); - if(FAILED(hres)) - return hres; - break; - } - - /* ECMA-262 3rd Edition 15.9.3.1 */ - default: { - VARIANT ret_date; - DateInstance *di; - - DateConstr_UTC(dispex, lcid, flags, dp, &ret_date, ei, sp); - - hres = create_date(dispex->ctx, TRUE, num_val(&ret_date), &date); - if(FAILED(hres)) - return hres; - - di = (DateInstance*)date; - di->time = utc(di->time, di); - } - } - - V_VT(retv) = VT_DISPATCH; - V_DISPATCH(retv) = (IDispatch*)_IDispatchEx_(date); - return S_OK; - - case INVOKE_FUNC: { - FILETIME system_time, local_time; - LONGLONG lltime; - - GetSystemTimeAsFileTime(&system_time); - FileTimeToLocalFileTime(&system_time, &local_time); - lltime = ((LONGLONG)local_time.dwHighDateTime<<32) - + local_time.dwLowDateTime; - - return date_to_string(lltime/10000-TIME_EPOCH, FALSE, 0, retv); - } - - default: - FIXME("unimplemented flags %x\n", flags); - return E_NOTIMPL; - } - - return S_OK; -} - -static const builtin_prop_t DateConstr_props[] = { - {UTCW, DateConstr_UTC, PROPF_METHOD}, - {parseW, DateConstr_parse, PROPF_METHOD} -}; - -static const builtin_info_t DateConstr_info = { - JSCLASS_FUNCTION, - {NULL, Function_value, 0}, - sizeof(DateConstr_props)/sizeof(*DateConstr_props), - DateConstr_props, - NULL, - NULL -}; - -HRESULT create_date_constr(script_ctx_t *ctx, DispatchEx **ret) -{ - DispatchEx *date; - HRESULT hres; - - hres = create_date(ctx, FALSE, 0.0, &date); - if(FAILED(hres)) - return hres; - - hres = create_builtin_function(ctx, DateConstr_value, &DateConstr_info, PROPF_CONSTR, date, ret); - - jsdisp_release(date); - return hres; -} +/* + * Copyright 2008 Jacek Caban for CodeWeavers + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include +#include + +#include "jscript.h" + +#include "wine/debug.h" + +WINE_DEFAULT_DEBUG_CHANNEL(jscript); + +/* 1601 to 1970 is 369 years plus 89 leap days */ +#define TIME_EPOCH ((ULONGLONG)(369 * 365 + 89) * 86400 * 1000) + +typedef struct { + DispatchEx dispex; + + /* ECMA-262 3rd Edition 15.9.1.1 */ + DOUBLE time; + + LONG bias; +} DateInstance; + +static const WCHAR toStringW[] = {'t','o','S','t','r','i','n','g',0}; +static const WCHAR toLocaleStringW[] = {'t','o','L','o','c','a','l','e','S','t','r','i','n','g',0}; +static const WCHAR hasOwnPropertyW[] = {'h','a','s','O','w','n','P','r','o','p','e','r','t','y',0}; +static const WCHAR propertyIsEnumerableW[] = + {'p','r','o','p','e','r','t','y','I','s','E','n','u','m','e','r','a','b','l','e',0}; +static const WCHAR isPrototypeOfW[] = {'i','s','P','r','o','t','o','t','y','p','e','O','f',0}; +static const WCHAR valueOfW[] = {'v','a','l','u','e','O','f',0}; +static const WCHAR toUTCStringW[] = {'t','o','U','T','C','S','t','r','i','n','g',0}; +static const WCHAR toDateStringW[] = {'t','o','D','a','t','e','S','t','r','i','n','g',0}; +static const WCHAR toTimeStringW[] = {'t','o','T','i','m','e','S','t','r','i','n','g',0}; +static const WCHAR toLocaleDateStringW[] = {'t','o','L','o','c','a','l','e','D','a','t','e','S','t','r','i','n','g',0}; +static const WCHAR toLocaleTimeStringW[] = {'t','o','L','o','c','a','l','e','T','i','m','e','S','t','r','i','n','g',0}; +static const WCHAR getTimeW[] = {'g','e','t','T','i','m','e',0}; +static const WCHAR getFullYearW[] = {'g','e','t','F','u','l','l','Y','e','a','r',0}; +static const WCHAR getUTCFullYearW[] = {'g','e','t','U','T','C','F','u','l','l','Y','e','a','r',0}; +static const WCHAR getMonthW[] = {'g','e','t','M','o','n','t','h',0}; +static const WCHAR getUTCMonthW[] = {'g','e','t','U','T','C','M','o','n','t','h',0}; +static const WCHAR getDateW[] = {'g','e','t','D','a','t','e',0}; +static const WCHAR getUTCDateW[] = {'g','e','t','U','T','C','D','a','t','e',0}; +static const WCHAR getDayW[] = {'g','e','t','D','a','y',0}; +static const WCHAR getUTCDayW[] = {'g','e','t','U','T','C','D','a','y',0}; +static const WCHAR getHoursW[] = {'g','e','t','H','o','u','r','s',0}; +static const WCHAR getUTCHoursW[] = {'g','e','t','U','T','C','H','o','u','r','s',0}; +static const WCHAR getMinutesW[] = {'g','e','t','M','i','n','u','t','e','s',0}; +static const WCHAR getUTCMinutesW[] = {'g','e','t','U','T','C','M','i','n','u','t','e','s',0}; +static const WCHAR getSecondsW[] = {'g','e','t','S','e','c','o','n','d','s',0}; +static const WCHAR getUTCSecondsW[] = {'g','e','t','U','T','C','S','e','c','o','n','d','s',0}; +static const WCHAR getMillisecondsW[] = {'g','e','t','M','i','l','l','i','s','e','c','o','n','d','s',0}; +static const WCHAR getUTCMillisecondsW[] = {'g','e','t','U','T','C','M','i','l','l','i','s','e','c','o','n','d','s',0}; +static const WCHAR getTimezoneOffsetW[] = {'g','e','t','T','i','m','e','z','o','n','e','O','f','f','s','e','t',0}; +static const WCHAR setTimeW[] = {'s','e','t','T','i','m','e',0}; +static const WCHAR setMillisecondsW[] = {'s','e','t','M','i','l','l','i','s','e','c','o','n','d','s',0}; +static const WCHAR setUTCMillisecondsW[] = {'s','e','t','U','T','C','M','i','l','l','i','s','e','c','o','n','d','s',0}; +static const WCHAR setSecondsW[] = {'s','e','t','S','e','c','o','n','d','s',0}; +static const WCHAR setUTCSecondsW[] = {'s','e','t','U','T','C','S','e','c','o','n','d','s',0}; +static const WCHAR setMinutesW[] = {'s','e','t','M','i','n','u','t','e','s',0}; +static const WCHAR setUTCMinutesW[] = {'s','e','t','U','T','C','M','i','n','u','t','e','s',0}; +static const WCHAR setHoursW[] = {'s','e','t','H','o','u','r','s',0}; +static const WCHAR setUTCHoursW[] = {'s','e','t','U','T','C','H','o','u','r','s',0}; +static const WCHAR setDateW[] = {'s','e','t','D','a','t','e',0}; +static const WCHAR setUTCDateW[] = {'s','e','t','U','T','C','D','a','t','e',0}; +static const WCHAR setMonthW[] = {'s','e','t','M','o','n','t','h',0}; +static const WCHAR setUTCMonthW[] = {'s','e','t','U','T','C','M','o','n','t','h',0}; +static const WCHAR setFullYearW[] = {'s','e','t','F','u','l','l','Y','e','a','r',0}; +static const WCHAR setUTCFullYearW[] = {'s','e','t','U','T','C','F','u','l','l','Y','e','a','r',0}; + +/*ECMA-262 3th Edition 15.9.1.2 */ +#define MS_PER_DAY 86400000 +#define MS_PER_HOUR 3600000 +#define MS_PER_MINUTE 60000 + +/* ECMA-262 3th Edition 15.9.1.2 */ +static inline DOUBLE day(DOUBLE time) +{ + return floor(time / MS_PER_DAY); +} + +/* ECMA-262 3th Edition 15.9.1.3 */ +static inline DOUBLE days_in_year(DOUBLE year) +{ + int y; + + if(year != (int)year) + return ret_nan(); + + y = year; + if(y%4 != 0) return 365; + if(y%100 != 0) return 366; + if(y%400 != 0) return 365; + return 366; +} + +/* ECMA-262 3th Edition 15.9.1.3 */ +static inline DOUBLE day_from_year(DOUBLE year) +{ + int y; + + if(year != (int)year) + return ret_nan(); + + y = year; + return 365*(y-1970) + floor((y-1969)/4) + - floor((y-1901)/100) + floor((y-1601)/400); +} + +/* ECMA-262 3th Edition 15.9.1.3 */ +static inline DOUBLE time_from_year(DOUBLE year) +{ + return MS_PER_DAY*day_from_year(year); +} + +/* ECMA-262 3th Edition 15.9.1.3 */ +static inline DOUBLE year_from_time(DOUBLE time) +{ + int y; + + if(isnan(time)) + return ret_nan(); + + y = 1970 + time/365.25/MS_PER_DAY; + + if(time_from_year(y) > time) + while(time_from_year(y) > time) y--; + else + while(time_from_year(y+1)<=time) y++; + + return y; +} + +/* ECMA-262 3th Edition 15.9.1.3 */ +static inline int in_leap_year(DOUBLE time) +{ + if(days_in_year(year_from_time(time))==366) + return 1; + return 0; +} + +/* ECMA-262 3th Edition 15.9.1.4 */ +static inline int day_within_year(DOUBLE time) +{ + return day(time) - day_from_year(year_from_time(time)); +} + +/* ECMA-262 3th Edition 15.9.1.4 */ +static inline DOUBLE month_from_time(DOUBLE time) +{ + int ily = in_leap_year(time); + int dwy = day_within_year(time); + + if(isnan(time)) + return ret_nan(); + + if(0<=dwy && dwy<31) return 0; + if(dwy < 59+ily) return 1; + if(dwy < 90+ily) return 2; + if(dwy < 120+ily) return 3; + if(dwy < 151+ily) return 4; + if(dwy < 181+ily) return 5; + if(dwy < 212+ily) return 6; + if(dwy < 243+ily) return 7; + if(dwy < 273+ily) return 8; + if(dwy < 304+ily) return 9; + if(dwy < 334+ily) return 10; + return 11; +} + +/* ECMA-262 3th Edition 15.9.1.5 */ +static inline DOUBLE date_from_time(DOUBLE time) +{ + int dwy = day_within_year(time); + int ily = in_leap_year(time); + int mft = month_from_time(time); + + if(isnan(time)) + return ret_nan(); + + if(mft==0) return dwy+1; + if(mft==1) return dwy-30; + if(mft==2) return dwy-58-ily; + if(mft==3) return dwy-89-ily; + if(mft==4) return dwy-119-ily; + if(mft==5) return dwy-150-ily; + if(mft==6) return dwy-180-ily; + if(mft==7) return dwy-211-ily; + if(mft==8) return dwy-242-ily; + if(mft==9) return dwy-272-ily; + if(mft==10) return dwy-303-ily; + return dwy-333-ily; +} + +/* ECMA-262 3th Edition 15.9.1.6 */ +static inline DOUBLE week_day(DOUBLE time) +{ + DOUBLE ret; + + if(isnan(time)) + return ret_nan(); + + ret = fmod(day(time)+4, 7); + if(ret<0) ret += 7; + + return ret; +} + +/* ECMA-262 3th Edition 15.9.1.10 */ +static inline DOUBLE hour_from_time(DOUBLE time) +{ + DOUBLE ret; + + if(isnan(time)) + return ret_nan(); + + ret = fmod(floor(time/MS_PER_HOUR), 24); + if(ret<0) ret += 24; + + return ret; +} + +/* ECMA-262 3th Edition 15.9.1.10 */ +static inline DOUBLE min_from_time(DOUBLE time) +{ + DOUBLE ret; + + if(isnan(time)) + return ret_nan(); + + ret = fmod(floor(time/MS_PER_MINUTE), 60); + if(ret<0) ret += 60; + + return ret; +} + +/* ECMA-262 3th Edition 15.9.1.10 */ +static inline DOUBLE sec_from_time(DOUBLE time) +{ + DOUBLE ret; + + if(isnan(time)) + return ret_nan(); + + ret = fmod(floor(time/1000), 60); + if(ret<0) ret += 60; + + return ret; +} + +/* ECMA-262 3th Edition 15.9.1.10 */ +static inline DOUBLE ms_from_time(DOUBLE time) +{ + DOUBLE ret; + + if(isnan(time)) + return ret_nan(); + + ret = fmod(time, 1000); + if(ret<0) ret += 1000; + + return ret; +} + +/* ECMA-262 3rd Edition 15.9.1.14 */ +static inline DOUBLE time_clip(DOUBLE time) +{ + if(8.64e15 < time || time < -8.64e15) { + return ret_nan(); + } + + return floor(time); +} + +static HRESULT Date_toString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_toLocaleString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_hasOwnProperty(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_propertyIsEnumerable(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_isPrototypeOf(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_valueOf(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_toUTCString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_toDateString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_toTimeString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_toLocaleDateString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_toLocaleTimeString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +/* ECMA-262 3rd Edition 15.9.5.9 */ +static HRESULT Date_getTime(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + num_set_val(retv, date->time); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.3 */ +static HRESULT Date_getFullYear(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + DOUBLE time = date->time - date->bias*MS_PER_MINUTE; + + num_set_val(retv, year_from_time(time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.3 */ +static HRESULT Date_getUTCFullYear(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + num_set_val(retv, year_from_time(date->time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.4 */ +static HRESULT Date_getMonth(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + DOUBLE time = date->time - date->bias*MS_PER_MINUTE; + + num_set_val(retv, month_from_time(time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.4 */ +static HRESULT Date_getUTCMonth(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + num_set_val(retv, month_from_time(date->time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.5 */ +static HRESULT Date_getDate(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + DOUBLE time = date->time - date->bias*MS_PER_MINUTE; + + num_set_val(retv, date_from_time(time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.5 */ +static HRESULT Date_getUTCDate(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + num_set_val(retv, date_from_time(date->time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.6 */ +static HRESULT Date_getDay(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + DOUBLE time = date->time - date->bias*MS_PER_MINUTE; + + num_set_val(retv, week_day(time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.6 */ +static HRESULT Date_getUTCDay(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + num_set_val(retv, week_day(date->time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.10 */ +static HRESULT Date_getHours(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + DOUBLE time = date->time - date->bias*MS_PER_MINUTE; + + num_set_val(retv, hour_from_time(time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.10 */ +static HRESULT Date_getUTCHours(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + num_set_val(retv, hour_from_time(date->time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.10 */ +static HRESULT Date_getMinutes(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + DOUBLE time = date->time - date->bias*MS_PER_MINUTE; + + num_set_val(retv, min_from_time(time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.10 */ +static HRESULT Date_getUTCMinutes(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + num_set_val(retv, min_from_time(date->time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.10 */ +static HRESULT Date_getSeconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + DOUBLE time = date->time - date->bias*MS_PER_MINUTE; + + num_set_val(retv, sec_from_time(time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.10 */ +static HRESULT Date_getUTCSeconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + num_set_val(retv, sec_from_time(date->time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.10 */ +static HRESULT Date_getMilliseconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + DOUBLE time = date->time - date->bias*MS_PER_MINUTE; + + num_set_val(retv, ms_from_time(time)); + } + return S_OK; +} + +/* ECMA-262 3th Edition 15.9.1.10 */ +static HRESULT Date_getUTCMilliseconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(retv) { + DateInstance *date = (DateInstance*)dispex; + num_set_val(retv, ms_from_time(date->time)); + } + return S_OK; +} + +static HRESULT Date_getTimezoneOffset(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_setTime(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + VARIANT v; + HRESULT hres; + DateInstance *date; + + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(!arg_cnt(dp)) { + FIXME("throw ArgumentNotOptional\n"); + if(retv) num_set_nan(retv); + return S_OK; + } + + hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); + if(FAILED(hres)) + return hres; + + date = (DateInstance*)dispex; + date->time = time_clip(num_val(&v)); + + if(retv) + num_set_val(retv, date->time); + + return S_OK; +} + +static HRESULT Date_setMilliseconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + VARIANT v; + HRESULT hres; + DateInstance *date; + + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(!arg_cnt(dp)) { + FIXME("throw ArgumentNotOptional\n"); + if(retv) num_set_nan(retv); + return S_OK; + } + + hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); + if(FAILED(hres)) + return hres; + + date = (DateInstance*)dispex; + date->time = time_clip(date->time - ms_from_time(date->time) + num_val(&v)); + + if(retv) + num_set_val(retv, date->time); + + return S_OK; +} + +static HRESULT Date_setUTCMilliseconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + return Date_setMilliseconds(dispex, lcid, flags, dp, retv, ei, caller); +} + +static HRESULT Date_setSeconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + VARIANT v; + HRESULT hres; + DateInstance *date; + + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(!arg_cnt(dp)) { + FIXME("throw ArgumentNotOptional\n"); + if(retv) num_set_nan(retv); + return S_OK; + } + + hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); + if(FAILED(hres)) + return hres; + + date = (DateInstance*)dispex; + date->time = time_clip(date->time - (sec_from_time(date->time) - num_val(&v))*1000.0); + + if(retv) + num_set_val(retv, date->time); + + return S_OK; +} + +static HRESULT Date_setUTCSeconds(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + return Date_setSeconds(dispex, lcid, flags, dp, retv, ei, caller); +} + +static HRESULT Date_setMinutes(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + VARIANT v; + HRESULT hres; + DateInstance *date; + + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(!arg_cnt(dp)) { + FIXME("throw ArgumentNotOptional\n"); + if(retv) num_set_nan(retv); + return S_OK; + } + + hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); + if(FAILED(hres)) + return hres; + + date = (DateInstance*)dispex; + date->time = time_clip(date->time - (min_from_time(date->time) - num_val(&v))*MS_PER_MINUTE); + + if(retv) + num_set_val(retv, date->time); + + return S_OK; +} + +static HRESULT Date_setUTCMinutes(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + return Date_setMinutes(dispex, lcid, flags, dp, retv, ei, caller); +} + +static HRESULT Date_setHours(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + VARIANT v; + HRESULT hres; + DateInstance *date; + + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(!arg_cnt(dp)) { + FIXME("throw ArgumentNotOptional\n"); + if(retv) num_set_nan(retv); + return S_OK; + } + + hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); + if(FAILED(hres)) + return hres; + + date = (DateInstance*)dispex; + date->time = time_clip(date->time + - (hour_from_time(date->time - date->bias*MS_PER_MINUTE) + - num_val(&v))*MS_PER_HOUR); + + if(retv) + num_set_val(retv, date->time); + + return S_OK; +} + +static HRESULT Date_setUTCHours(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + VARIANT v; + HRESULT hres; + DateInstance *date; + + TRACE("\n"); + + if(!is_class(dispex, JSCLASS_DATE)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } + + if(!arg_cnt(dp)) { + FIXME("throw ArgumentNotOptional\n"); + if(retv) num_set_nan(retv); + return S_OK; + } + + hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &v); + if(FAILED(hres)) + return hres; + + date = (DateInstance*)dispex; + date->time = time_clip(date->time + - (hour_from_time(date->time) - num_val(&v))*MS_PER_HOUR); + + if(retv) + num_set_val(retv, date->time); + + return S_OK; +} + +static HRESULT Date_setDate(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_setUTCDate(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_setMonth(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_setUTCMonth(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_setFullYear(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_setUTCFullYear(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static HRESULT Date_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) +{ + FIXME("\n"); + return E_NOTIMPL; +} + +static const builtin_prop_t Date_props[] = { + {getDateW, Date_getDate, PROPF_METHOD}, + {getDayW, Date_getDay, PROPF_METHOD}, + {getFullYearW, Date_getFullYear, PROPF_METHOD}, + {getHoursW, Date_getHours, PROPF_METHOD}, + {getMillisecondsW, Date_getMilliseconds, PROPF_METHOD}, + {getMinutesW, Date_getMinutes, PROPF_METHOD}, + {getMonthW, Date_getMonth, PROPF_METHOD}, + {getSecondsW, Date_getSeconds, PROPF_METHOD}, + {getTimeW, Date_getTime, PROPF_METHOD}, + {getTimezoneOffsetW, Date_getTimezoneOffset, PROPF_METHOD}, + {getUTCDateW, Date_getUTCDate, PROPF_METHOD}, + {getUTCDayW, Date_getUTCDay, PROPF_METHOD}, + {getUTCFullYearW, Date_getUTCFullYear, PROPF_METHOD}, + {getUTCHoursW, Date_getUTCHours, PROPF_METHOD}, + {getUTCMillisecondsW, Date_getUTCMilliseconds, PROPF_METHOD}, + {getUTCMinutesW, Date_getUTCMinutes, PROPF_METHOD}, + {getUTCMonthW, Date_getUTCMonth, PROPF_METHOD}, + {getUTCSecondsW, Date_getUTCSeconds, PROPF_METHOD}, + {hasOwnPropertyW, Date_hasOwnProperty, PROPF_METHOD}, + {isPrototypeOfW, Date_isPrototypeOf, PROPF_METHOD}, + {propertyIsEnumerableW, Date_propertyIsEnumerable, PROPF_METHOD}, + {setDateW, Date_setDate, PROPF_METHOD}, + {setFullYearW, Date_setFullYear, PROPF_METHOD}, + {setHoursW, Date_setHours, PROPF_METHOD}, + {setMillisecondsW, Date_setMilliseconds, PROPF_METHOD}, + {setMinutesW, Date_setMinutes, PROPF_METHOD}, + {setMonthW, Date_setMonth, PROPF_METHOD}, + {setSecondsW, Date_setSeconds, PROPF_METHOD}, + {setTimeW, Date_setTime, PROPF_METHOD}, + {setUTCDateW, Date_setUTCDate, PROPF_METHOD}, + {setUTCFullYearW, Date_setUTCFullYear, PROPF_METHOD}, + {setUTCHoursW, Date_setUTCHours, PROPF_METHOD}, + {setUTCMillisecondsW, Date_setUTCMilliseconds, PROPF_METHOD}, + {setUTCMinutesW, Date_setUTCMinutes, PROPF_METHOD}, + {setUTCMonthW, Date_setUTCMonth, PROPF_METHOD}, + {setUTCSecondsW, Date_setUTCSeconds, PROPF_METHOD}, + {toDateStringW, Date_toDateString, PROPF_METHOD}, + {toLocaleDateStringW, Date_toLocaleDateString, PROPF_METHOD}, + {toLocaleStringW, Date_toLocaleString, PROPF_METHOD}, + {toLocaleTimeStringW, Date_toLocaleTimeString, PROPF_METHOD}, + {toStringW, Date_toString, PROPF_METHOD}, + {toTimeStringW, Date_toTimeString, PROPF_METHOD}, + {toUTCStringW, Date_toUTCString, PROPF_METHOD}, + {valueOfW, Date_valueOf, PROPF_METHOD}, +}; + +static const builtin_info_t Date_info = { + JSCLASS_DATE, + {NULL, Date_value, 0}, + sizeof(Date_props)/sizeof(*Date_props), + Date_props, + NULL, + NULL +}; + +static HRESULT create_date(script_ctx_t *ctx, BOOL use_constr, DOUBLE time, DispatchEx **ret) +{ + DateInstance *date; + HRESULT hres; + TIME_ZONE_INFORMATION tzi; + + GetTimeZoneInformation(&tzi); + + date = heap_alloc_zero(sizeof(DateInstance)); + if(!date) + return E_OUTOFMEMORY; + + if(use_constr) + hres = init_dispex_from_constr(&date->dispex, ctx, &Date_info, ctx->date_constr); + else + hres = init_dispex(&date->dispex, ctx, &Date_info, NULL); + if(FAILED(hres)) { + heap_free(date); + return hres; + } + + date->time = time; + date->bias = tzi.Bias; + + *ret = &date->dispex; + return S_OK; +} + +static HRESULT DateConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) +{ + DispatchEx *date; + HRESULT hres; + + TRACE("\n"); + + switch(flags) { + case DISPATCH_CONSTRUCT: + switch(arg_cnt(dp)) { + /* ECMA-262 3rd Edition 15.9.3.3 */ + case 0: { + FILETIME time; + LONGLONG lltime; + + GetSystemTimeAsFileTime(&time); + lltime = ((LONGLONG)time.dwHighDateTime<<32) + + time.dwLowDateTime; + + hres = create_date(dispex->ctx, TRUE, lltime/10000-TIME_EPOCH, &date); + if(FAILED(hres)) + return hres; + break; + } + + /* ECMA-262 3rd Edition 15.9.3.2 */ + case 1: { + VARIANT prim, num; + + hres = to_primitive(dispex->ctx, get_arg(dp,0), ei, &prim); + if(FAILED(hres)) + return hres; + + if(V_VT(&prim) == VT_BSTR) { + FIXME("VT_BSTR not supported\n"); + return E_NOTIMPL; + } + + hres = to_number(dispex->ctx, &prim, ei, &num); + VariantClear(&prim); + if(FAILED(hres)) + return hres; + + hres = create_date(dispex->ctx, TRUE, time_clip(num_val(&num)), &date); + if(FAILED(hres)) + return hres; + break; + } + + default: + FIXME("unimplemented argcnt %d\n", arg_cnt(dp)); + return E_NOTIMPL; + } + + V_VT(retv) = VT_DISPATCH; + V_DISPATCH(retv) = (IDispatch*)_IDispatchEx_(date); + return S_OK; + + default: + FIXME("unimplemented flags %x\n", flags); + return E_NOTIMPL; + } + + return S_OK; +} + +HRESULT create_date_constr(script_ctx_t *ctx, DispatchEx **ret) +{ + DispatchEx *date; + HRESULT hres; + + hres = create_date(ctx, FALSE, 0.0, &date); + if(FAILED(hres)) + return hres; + + hres = create_builtin_function(ctx, DateConstr_value, PROPF_CONSTR, date, ret); + + jsdisp_release(date); + return hres; +} diff --git a/dlls/jscript/dispex.c b/dlls/jscript/dispex.c index 509fb50944d..86410af4ec7 100644 --- a/dlls/jscript/dispex.c +++ b/dlls/jscript/dispex.c @@ -293,7 +293,7 @@ static HRESULT prop_get(DispatchEx *This, dispex_prop_t *prop, LCID lcid, DISPPA case PROP_BUILTIN: if(prop->u.p->flags & PROPF_METHOD) { DispatchEx *obj; - hres = create_builtin_function(This->ctx, prop->u.p->invoke, NULL, prop->u.p->flags, NULL, &obj); + hres = create_builtin_function(This->ctx, prop->u.p->invoke, prop->u.p->flags, NULL, &obj); if(FAILED(hres)) break; @@ -828,7 +828,7 @@ HRESULT jsdisp_call_value(DispatchEx *disp, LCID lcid, WORD flags, DISPPARAMS *d return disp->builtin_info->value_prop.invoke(disp, lcid, flags, dp, retv, ei, caller); } -HRESULT jsdisp_call(DispatchEx *disp, DISPID id, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, +static HRESULT jsdisp_call(DispatchEx *disp, DISPID id, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) { dispex_prop_t *prop; @@ -1010,19 +1010,3 @@ HRESULT disp_propget(IDispatch *disp, DISPID id, LCID lcid, VARIANT *val, jsexce return hres; } - -HRESULT jsdisp_delete_idx(DispatchEx *obj, DWORD idx) -{ - static const WCHAR formatW[] = {'%','d',0}; - WCHAR buf[12]; - dispex_prop_t *prop; - HRESULT hres; - - sprintfW(buf, formatW, idx); - - hres = find_prop_name(obj, buf, &prop); - if(FAILED(hres) || !prop) - return hres; - - return delete_prop(prop); -} diff --git a/dlls/jscript/engine.c b/dlls/jscript/engine.c index ff5e6a896c3..05c6225daae 100644 --- a/dlls/jscript/engine.c +++ b/dlls/jscript/engine.c @@ -179,8 +179,6 @@ HRESULT create_exec_ctx(IDispatch *this_obj, DispatchEx *var_disp, scope_chain_t if(!ctx) return E_OUTOFMEMORY; - ctx->ref = 1; - IDispatch_AddRef(this_obj); ctx->this_obj = this_obj; @@ -232,8 +230,10 @@ static HRESULT disp_get_id(IDispatch *disp, BSTR name, DWORD flags, DISPID *id) /* ECMA-262 3rd Edition 8.7.2 */ static HRESULT put_value(script_ctx_t *ctx, exprval_t *ref, VARIANT *v, jsexcept_t *ei) { - if(ref->type != EXPRVAL_IDREF) - return throw_reference_error(ctx, ei, IDS_ILLEGAL_ASSIGN, NULL); + if(ref->type != EXPRVAL_IDREF) { + FIXME("throw ReferemceError\n"); + return E_FAIL; + } return disp_propput(ref->u.idref.disp, ref->u.idref.id, ctx->lcid, v, ei, NULL/*FIXME*/); } @@ -431,7 +431,7 @@ HRESULT exec_source(exec_ctx_t *ctx, parser_ctx_t *parser, source_elements_t *so } /* ECMA-262 3rd Edition 10.1.4 */ -static HRESULT identifier_eval(exec_ctx_t *ctx, BSTR identifier, DWORD flags, jsexcept_t *ei, exprval_t *ret) +static HRESULT identifier_eval(exec_ctx_t *ctx, BSTR identifier, DWORD flags, exprval_t *ret) { scope_chain_t *scope; named_item_t *item; @@ -516,7 +516,8 @@ static HRESULT identifier_eval(exec_ctx_t *ctx, BSTR identifier, DWORD flags, js return S_OK; } - return throw_type_error(ctx->var_disp->ctx, ei, IDS_UNDEFINED, identifier); + WARN("Could not find identifier %s\n", debugstr_w(identifier)); + return E_FAIL; } /* ECMA-262 3rd Edition 12.1 */ @@ -852,7 +853,7 @@ HRESULT forin_statement_eval(exec_ctx_t *ctx, statement_t *_stat, return_type_t TRACE("iter %s\n", debugstr_w(str)); if(stat->variable) - hres = identifier_eval(ctx, identifier, 0, NULL, &exprval); + hres = identifier_eval(ctx, identifier, 0, &exprval); else hres = expr_eval(ctx, stat->expr, EXPR_NEWREF, &rt->ei, &exprval); if(SUCCEEDED(hres)) { @@ -1535,16 +1536,11 @@ HRESULT call_expression_eval(exec_ctx_t *ctx, expression_t *_expr, DWORD flags, hres = args_to_param(ctx, expr->argument_list, ei, &dp); if(SUCCEEDED(hres)) { switch(exprval.type) { - case EXPRVAL_VARIANT: - if(V_VT(&exprval.u.var) != VT_DISPATCH) - return throw_type_error(ctx->var_disp->ctx, ei, IDS_NO_PROPERTY, NULL); - - hres = disp_call(V_DISPATCH(&exprval.u.var), DISPID_VALUE, ctx->parser->script->lcid, - DISPATCH_METHOD, &dp, flags & EXPR_NOVAL ? NULL : &var, ei, NULL/*FIXME*/); - break; case EXPRVAL_IDREF: - hres = disp_call(exprval.u.idref.disp, exprval.u.idref.id, ctx->parser->script->lcid, - DISPATCH_METHOD, &dp, flags & EXPR_NOVAL ? NULL : &var, ei, NULL/*FIXME*/); + hres = disp_call(exprval.u.idref.disp, exprval.u.idref.id, ctx->parser->script->lcid, DISPATCH_METHOD, + &dp, flags & EXPR_NOVAL ? NULL : &var, ei, NULL/*FIXME*/); + if(flags & EXPR_NOVAL) + V_VT(&var) = VT_EMPTY; break; default: FIXME("unimplemented type %d\n", exprval.type); @@ -1558,13 +1554,9 @@ HRESULT call_expression_eval(exec_ctx_t *ctx, expression_t *_expr, DWORD flags, if(FAILED(hres)) return hres; + TRACE("= %s\n", debugstr_variant(&var)); ret->type = EXPRVAL_VARIANT; - if(flags & EXPR_NOVAL) { - V_VT(&ret->u.var) = VT_EMPTY; - }else { - TRACE("= %s\n", debugstr_variant(&var)); - ret->u.var = var; - } + ret->u.var = var; return S_OK; } @@ -1593,7 +1585,7 @@ HRESULT identifier_expression_eval(exec_ctx_t *ctx, expression_t *_expr, DWORD f if(!identifier) return E_OUTOFMEMORY; - hres = identifier_eval(ctx, identifier, flags, ei, ret); + hres = identifier_eval(ctx, identifier, flags, ret); SysFreeString(identifier); return hres; @@ -1939,11 +1931,11 @@ static HRESULT add_eval(exec_ctx_t *ctx, VARIANT *lval, VARIANT *rval, jsexcept_ VARIANT r, l; HRESULT hres; - hres = to_primitive(ctx->parser->script, lval, ei, &l, NO_HINT); + hres = to_primitive(ctx->parser->script, lval, ei, &l); if(FAILED(hres)) return hres; - hres = to_primitive(ctx->parser->script, rval, ei, &r, NO_HINT); + hres = to_primitive(ctx->parser->script, rval, ei, &r); if(FAILED(hres)) { VariantClear(&l); return hres; @@ -2526,7 +2518,7 @@ static HRESULT equal_values(exec_ctx_t *ctx, VARIANT *lval, VARIANT *rval, jsexc VARIANT v; HRESULT hres; - hres = to_primitive(ctx->parser->script, rval, ei, &v, NO_HINT); + hres = to_primitive(ctx->parser->script, rval, ei, &v); if(FAILED(hres)) return hres; @@ -2541,7 +2533,7 @@ static HRESULT equal_values(exec_ctx_t *ctx, VARIANT *lval, VARIANT *rval, jsexc VARIANT v; HRESULT hres; - hres = to_primitive(ctx->parser->script, lval, ei, &v, NO_HINT); + hres = to_primitive(ctx->parser->script, lval, ei, &v); if(FAILED(hres)) return hres; @@ -2646,11 +2638,11 @@ static HRESULT less_eval(exec_ctx_t *ctx, VARIANT *lval, VARIANT *rval, BOOL gre VARIANT l, r, ln, rn; HRESULT hres; - hres = to_primitive(ctx->parser->script, lval, ei, &l, NO_HINT); + hres = to_primitive(ctx->parser->script, lval, ei, &l); if(FAILED(hres)) return hres; - hres = to_primitive(ctx->parser->script, rval, ei, &r, NO_HINT); + hres = to_primitive(ctx->parser->script, rval, ei, &r); if(FAILED(hres)) { VariantClear(&l); return hres; diff --git a/dlls/jscript/error.c b/dlls/jscript/error.c deleted file mode 100644 index 25a3836cc8f..00000000000 --- a/dlls/jscript/error.c +++ /dev/null @@ -1,481 +0,0 @@ -/* - * Copyright 2009 Piotr Caban - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ -#include "config.h" -#include "wine/port.h" - -#include - -#include "jscript.h" - -#include "wine/debug.h" - -WINE_DEFAULT_DEBUG_CHANNEL(jscript); - -typedef struct { - DispatchEx dispex; - - VARIANT number; - VARIANT description; - VARIANT message; -} ErrorInstance; - -static const WCHAR descriptionW[] = {'d','e','s','c','r','i','p','t','i','o','n',0}; -static const WCHAR messageW[] = {'m','e','s','s','a','g','e',0}; -static const WCHAR numberW[] = {'n','u','m','b','e','r',0}; -static const WCHAR toStringW[] = {'t','o','S','t','r','i','n','g',0}; -static const WCHAR hasOwnPropertyW[] = {'h','a','s','O','w','n','P','r','o','p','e','r','t','y',0}; -static const WCHAR propertyIsEnumerableW[] = - {'p','r','o','p','e','r','t','y','I','s','E','n','u','m','e','r','a','b','l','e',0}; -static const WCHAR isPrototypeOfW[] = {'i','s','P','r','o','t','o','t','y','p','e','O','f',0}; - -static HRESULT Error_number(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - ErrorInstance *This = (ErrorInstance*)dispex; - - TRACE("\n"); - - switch(flags) { - case DISPATCH_PROPERTYGET: - return VariantCopy(retv, &This->number); - case DISPATCH_PROPERTYPUT: - return VariantCopy(&This->number, get_arg(dp, 0)); - default: - FIXME("unimplemented flags %x\n", flags); - return E_NOTIMPL; - } -} - -static HRESULT Error_description(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - ErrorInstance *This = (ErrorInstance*)dispex; - - TRACE("\n"); - - switch(flags) { - case DISPATCH_PROPERTYGET: - return VariantCopy(retv, &This->description); - case DISPATCH_PROPERTYPUT: - return VariantCopy(&This->description, get_arg(dp, 0)); - default: - FIXME("unimplemented flags %x\n", flags); - return E_NOTIMPL; - } -} - -/* ECMA-262 3rd Edition 15.11.4.3 */ -static HRESULT Error_message(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - ErrorInstance *This = (ErrorInstance*)dispex; - - TRACE("\n"); - - switch(flags) { - case DISPATCH_PROPERTYGET: - return VariantCopy(retv, &This->message); - case DISPATCH_PROPERTYPUT: - return VariantCopy(&This->message, get_arg(dp, 0)); - default: - FIXME("unimplemented flags %x\n", flags); - return E_NOTIMPL; - } -} - -/* ECMA-262 3rd Edition 15.11.4.4 */ -static HRESULT Error_toString(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - static const WCHAR str[] = {'[','o','b','j','e','c','t',' ','E','r','r','o','r',']',0}; - - TRACE("\n"); - - if(retv) { - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = SysAllocString(str); - if(!V_BSTR(retv)) - return E_OUTOFMEMORY; - } - - return S_OK; -} - -static HRESULT Error_hasOwnProperty(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - FIXME("\n"); - return E_NOTIMPL; -} - -static HRESULT Error_propertyIsEnumerable(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - FIXME("\n"); - return E_NOTIMPL; -} - - -static HRESULT Error_isPrototypeOf(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - FIXME("\n"); - return E_NOTIMPL; -} - -static HRESULT Error_value(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - - switch(flags) { - case INVOKE_FUNC: - return throw_type_error(dispex->ctx, ei, IDS_NOT_FUNC, NULL); - default: - FIXME("unimplemented flags %x\n", flags); - return E_NOTIMPL; - } - - return S_OK; -} - -static void Error_destructor(DispatchEx *dispex) -{ - ErrorInstance *This = (ErrorInstance*)dispex; - - VariantClear(&This->number); - VariantClear(&This->description); - VariantClear(&This->message); - heap_free(This); -} - -static const builtin_prop_t Error_props[] = { - {descriptionW, Error_description, 0}, - {hasOwnPropertyW, Error_hasOwnProperty, PROPF_METHOD}, - {isPrototypeOfW, Error_isPrototypeOf, PROPF_METHOD}, - {messageW, Error_message, 0}, - {numberW, Error_number, 0}, - {propertyIsEnumerableW, Error_propertyIsEnumerable, PROPF_METHOD}, - {toStringW, Error_toString, PROPF_METHOD} -}; - -static const builtin_info_t Error_info = { - JSCLASS_ERROR, - {NULL, Error_value, 0}, - sizeof(Error_props)/sizeof(*Error_props), - Error_props, - Error_destructor, - NULL -}; - -static const builtin_prop_t ErrorInst_props[] = { - {descriptionW, Error_description, 0}, - {hasOwnPropertyW, Error_hasOwnProperty, PROPF_METHOD}, - {isPrototypeOfW, Error_isPrototypeOf, PROPF_METHOD}, - {messageW, Error_message, 0}, - {numberW, Error_number, 0}, - {propertyIsEnumerableW, Error_propertyIsEnumerable, PROPF_METHOD} -}; - -static const builtin_info_t ErrorInst_info = { - JSCLASS_ERROR, - {NULL, Error_value, 0}, - sizeof(ErrorInst_props)/sizeof(*ErrorInst_props), - ErrorInst_props, - Error_destructor, - NULL -}; - -static HRESULT alloc_error(script_ctx_t *ctx, BOOL error_prototype, - DispatchEx *constr, ErrorInstance **ret) -{ - ErrorInstance *err; - DispatchEx *inherit; - HRESULT hres; - - err = heap_alloc_zero(sizeof(ErrorInstance)); - if(!err) - return E_OUTOFMEMORY; - - inherit = error_prototype ? ctx->object_constr : ctx->error_constr; - hres = init_dispex_from_constr(&err->dispex, ctx, - error_prototype ? &Error_info : &ErrorInst_info, - constr ? constr : inherit); - if(FAILED(hres)) { - heap_free(err); - return hres; - } - - *ret = err; - return S_OK; -} - -static HRESULT create_error(script_ctx_t *ctx, DispatchEx *constr, - const UINT *number, const WCHAR *msg, DispatchEx **ret) -{ - ErrorInstance *err; - HRESULT hres; - - hres = alloc_error(ctx, FALSE, constr, &err); - if(FAILED(hres)) - return hres; - - if(number) { - V_VT(&err->number) = VT_I4; - V_I4(&err->number) = *number; - } - - V_VT(&err->message) = VT_BSTR; - if(msg) V_BSTR(&err->message) = SysAllocString(msg); - else V_BSTR(&err->message) = SysAllocStringLen(NULL, 0); - - VariantCopy(&err->description, &err->message); - - if(!V_BSTR(&err->message)) { - heap_free(err); - return E_OUTOFMEMORY; - } - - *ret = &err->dispex; - return S_OK; -} - -static HRESULT error_constr(DispatchEx *dispex, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, DispatchEx *constr) { - DispatchEx *err; - VARIANT numv; - UINT num; - BSTR msg = NULL; - HRESULT hres; - - V_VT(&numv) = VT_NULL; - - if(arg_cnt(dp)) { - hres = to_number(dispex->ctx, get_arg(dp, 0), ei, &numv); - if(FAILED(hres) || (V_VT(&numv)==VT_R8 && isnan(V_R8(&numv)))) - hres = to_string(dispex->ctx, get_arg(dp, 0), ei, &msg); - else if(V_VT(&numv) == VT_I4) - num = V_I4(&numv); - else - num = V_R8(&numv); - - if(FAILED(hres)) - return hres; - } - - if(arg_cnt(dp)>1 && !msg) { - hres = to_string(dispex->ctx, get_arg(dp, 1), ei, &msg); - if(FAILED(hres)) - return hres; - } - - switch(flags) { - case INVOKE_FUNC: - case DISPATCH_CONSTRUCT: - if(V_VT(&numv) == VT_NULL) - hres = create_error(dispex->ctx, constr, NULL, msg, &err); - else - hres = create_error(dispex->ctx, constr, &num, msg, &err); - - if(FAILED(hres)) - return hres; - - if(retv) { - V_VT(retv) = VT_DISPATCH; - V_DISPATCH(retv) = (IDispatch*)_IDispatchEx_(err); - } - else - IDispatchEx_Release(_IDispatchEx_(err)); - - return S_OK; - - default: - FIXME("unimplemented flags %x\n", flags); - return E_NOTIMPL; - } -} - -static HRESULT ErrorConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - return error_constr(dispex, flags, dp, retv, ei, - dispex->ctx->error_constr); -} - -static HRESULT EvalErrorConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - return error_constr(dispex, flags, dp, retv, ei, - dispex->ctx->eval_error_constr); -} - -static HRESULT RangeErrorConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - return error_constr(dispex, flags, dp, retv, ei, - dispex->ctx->range_error_constr); -} - -static HRESULT ReferenceErrorConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - return error_constr(dispex, flags, dp, retv, ei, - dispex->ctx->reference_error_constr); -} - -static HRESULT SyntaxErrorConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - return error_constr(dispex, flags, dp, retv, ei, - dispex->ctx->syntax_error_constr); -} - -static HRESULT TypeErrorConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - return error_constr(dispex, flags, dp, retv, ei, - dispex->ctx->type_error_constr); -} - -static HRESULT URIErrorConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - return error_constr(dispex, flags, dp, retv, ei, - dispex->ctx->uri_error_constr); -} - -HRESULT init_error_constr(script_ctx_t *ctx) -{ - static const WCHAR nameW[] = {'n','a','m','e',0}; - static const WCHAR ErrorW[] = {'E','r','r','o','r',0}; - static const WCHAR EvalErrorW[] = {'E','v','a','l','E','r','r','o','r',0}; - static const WCHAR RangeErrorW[] = {'R','a','n','g','e','E','r','r','o','r',0}; - static const WCHAR ReferenceErrorW[] = {'R','e','f','e','r','e','n','c','e','E','r','r','o','r',0}; - static const WCHAR SyntaxErrorW[] = {'S','y','n','t','a','x','E','r','r','o','r',0}; - static const WCHAR TypeErrorW[] = {'T','y','p','e','E','r','r','o','r',0}; - static const WCHAR URIErrorW[] = {'U','R','I','E','r','r','o','r',0}; - static const WCHAR *names[] = {ErrorW, EvalErrorW, RangeErrorW, - ReferenceErrorW, SyntaxErrorW, TypeErrorW, URIErrorW}; - DispatchEx **constr_addr[] = {&ctx->error_constr, &ctx->eval_error_constr, - &ctx->range_error_constr, &ctx->reference_error_constr, - &ctx->syntax_error_constr, &ctx->type_error_constr, - &ctx->uri_error_constr}; - static builtin_invoke_t constr_val[] = {ErrorConstr_value, EvalErrorConstr_value, - RangeErrorConstr_value, ReferenceErrorConstr_value, SyntaxErrorConstr_value, - TypeErrorConstr_value, URIErrorConstr_value}; - - ErrorInstance *err; - INT i; - VARIANT v; - HRESULT hres; - - for(i=0; i<7; i++) { - hres = alloc_error(ctx, i==0, NULL, &err); - if(FAILED(hres)) - return hres; - - V_VT(&v) = VT_BSTR; - V_BSTR(&v) = SysAllocString(names[i]); - if(!V_BSTR(&v)) { - IDispatchEx_Release(_IDispatchEx_(&err->dispex)); - return E_OUTOFMEMORY; - } - - hres = jsdisp_propput_name(&err->dispex, nameW, ctx->lcid, &v, NULL/*FIXME*/, NULL/*FIXME*/); - - if(SUCCEEDED(hres)) - hres = create_builtin_function(ctx, constr_val[i], NULL, - PROPF_CONSTR, &err->dispex, constr_addr[i]); - - IDispatchEx_Release(_IDispatchEx_(&err->dispex)); - VariantClear(&v); - if(FAILED(hres)) - return hres; - } - - return S_OK; -} - -static HRESULT throw_error(script_ctx_t *ctx, jsexcept_t *ei, UINT id, const WCHAR *str, DispatchEx *constr) -{ - WCHAR buf[1024], *pos = NULL; - DispatchEx *err; - HRESULT hres; - - buf[0] = '\0'; - LoadStringW(jscript_hinstance, id&0xFFFF, buf, sizeof(buf)/sizeof(WCHAR)); - - if(str) pos = strchrW(buf, '|'); - if(pos) { - int len = strlenW(str); - memmove(pos+len, pos+1, (strlenW(pos+1)+1)*sizeof(WCHAR)); - memcpy(pos, str, len*sizeof(WCHAR)); - } - - WARN("%s\n", debugstr_w(buf)); - - id |= JSCRIPT_ERROR; - hres = create_error(ctx, constr, &id, buf, &err); - if(FAILED(hres)) - return hres; - - if(!ei) - return id; - - V_VT(&ei->var) = VT_DISPATCH; - V_DISPATCH(&ei->var) = (IDispatch*)_IDispatchEx_(err); - - return id; -} - -HRESULT throw_eval_error(script_ctx_t *ctx, jsexcept_t *ei, UINT id, const WCHAR *str) -{ - return throw_error(ctx, ei, id, str, ctx->eval_error_constr); -} - -HRESULT throw_range_error(script_ctx_t *ctx, jsexcept_t *ei, UINT id, const WCHAR *str) -{ - return throw_error(ctx, ei, id, str, ctx->range_error_constr); -} - -HRESULT throw_reference_error(script_ctx_t *ctx, jsexcept_t *ei, UINT id, const WCHAR *str) -{ - return throw_error(ctx, ei, id, str, ctx->reference_error_constr); -} - -HRESULT throw_syntax_error(script_ctx_t *ctx, jsexcept_t *ei, UINT id, const WCHAR *str) -{ - return throw_error(ctx, ei, id, str, ctx->syntax_error_constr); -} - -HRESULT throw_type_error(script_ctx_t *ctx, jsexcept_t *ei, UINT id, const WCHAR *str) -{ - return throw_error(ctx, ei, id, str, ctx->type_error_constr); -} - -HRESULT throw_uri_error(script_ctx_t *ctx, jsexcept_t *ei, UINT id, const WCHAR *str) -{ - return throw_error(ctx, ei, id, str, ctx->uri_error_constr); -} diff --git a/dlls/jscript/function.c b/dlls/jscript/function.c index 6ac668cf80a..314d58558e8 100644 --- a/dlls/jscript/function.c +++ b/dlls/jscript/function.c @@ -41,6 +41,7 @@ static const WCHAR prototypeW[] = {'p','r','o','t','o','t', 'y', 'p','e',0}; static const WCHAR lengthW[] = {'l','e','n','g','t','h',0}; static const WCHAR toStringW[] = {'t','o','S','t','r','i','n','g',0}; static const WCHAR toLocaleStringW[] = {'t','o','L','o','c','a','l','e','S','t','r','i','n','g',0}; +static const WCHAR valueOfW[] = {'v','a','l','u','e','O','f',0}; static const WCHAR applyW[] = {'a','p','p','l','y',0}; static const WCHAR callW[] = {'c','a','l','l',0}; static const WCHAR hasOwnPropertyW[] = {'h','a','s','O','w','n','P','r','o','p','e','r','t','y',0}; @@ -197,10 +198,9 @@ static HRESULT invoke_constructor(FunctionInstance *function, LCID lcid, DISPPAR return hres; hres = invoke_source(function, (IDispatch*)_IDispatchEx_(this_obj), lcid, dp, retv, ei, caller); - if(FAILED(hres)) { - jsdisp_release(this_obj); + jsdisp_release(this_obj); + if(FAILED(hres)) return hres; - } V_VT(retv) = VT_DISPATCH; V_DISPATCH(retv) = (IDispatch*)_IDispatchEx_(this_obj); @@ -272,8 +272,10 @@ static HRESULT Function_toString(DispatchEx *dispex, LCID lcid, WORD flags, DISP TRACE("\n"); - if(!is_class(dispex, JSCLASS_FUNCTION)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_FUNC, NULL); + if(!is_class(dispex, JSCLASS_FUNCTION)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } function = (FunctionInstance*)dispex; @@ -297,6 +299,13 @@ static HRESULT Function_toLocaleString(DispatchEx *dispex, LCID lcid, WORD flags return E_NOTIMPL; } +static HRESULT Function_valueOf(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, + VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) +{ + FIXME("\n"); + return E_NOTIMPL; +} + static HRESULT Function_apply(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { @@ -332,7 +341,7 @@ static HRESULT Function_isPrototypeOf(DispatchEx *dispex, LCID lcid, WORD flags, return E_NOTIMPL; } -HRESULT Function_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, +static HRESULT Function_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) { FunctionInstance *function; @@ -399,7 +408,8 @@ static const builtin_prop_t Function_props[] = { {lengthW, Function_length, 0}, {propertyIsEnumerableW, Function_propertyIsEnumerable, PROPF_METHOD}, {toLocaleStringW, Function_toLocaleString, PROPF_METHOD}, - {toStringW, Function_toString, PROPF_METHOD} + {toStringW, Function_toString, PROPF_METHOD}, + {valueOfW, Function_valueOf, PROPF_METHOD} }; static const builtin_info_t Function_info = { @@ -425,8 +435,7 @@ static HRESULT FunctionProt_value(DispatchEx *dispex, LCID lcid, WORD flags, DIS return E_NOTIMPL; } -static HRESULT create_function(script_ctx_t *ctx, const builtin_info_t *builtin_info, DWORD flags, - BOOL funcprot, DispatchEx *prototype, FunctionInstance **ret) +static HRESULT create_function(script_ctx_t *ctx, DWORD flags, BOOL funcprot, DispatchEx *prototype, FunctionInstance **ret) { FunctionInstance *function; HRESULT hres; @@ -437,8 +446,6 @@ static HRESULT create_function(script_ctx_t *ctx, const builtin_info_t *builtin_ if(funcprot) hres = init_dispex(&function->dispex, ctx, &Function_info, prototype); - else if(builtin_info) - hres = init_dispex_from_constr(&function->dispex, ctx, builtin_info, ctx->function_constr); else hres = init_dispex_from_constr(&function->dispex, ctx, &Function_info, ctx->function_constr); if(FAILED(hres)) @@ -447,38 +454,35 @@ static HRESULT create_function(script_ctx_t *ctx, const builtin_info_t *builtin_ function->flags = flags; function->length = flags & PROPF_ARGMASK; - *ret = function; - return S_OK; -} + if(prototype) { + jsexcept_t jsexcept; + VARIANT var; -static HRESULT set_prototype(script_ctx_t *ctx, DispatchEx *dispex, DispatchEx *prototype) -{ - jsexcept_t jsexcept; - VARIANT var; + V_VT(&var) = VT_DISPATCH; + V_DISPATCH(&var) = (IDispatch*)_IDispatchEx_(prototype); + memset(&jsexcept, 0, sizeof(jsexcept)); - V_VT(&var) = VT_DISPATCH; - V_DISPATCH(&var) = (IDispatch*)_IDispatchEx_(prototype); - memset(&jsexcept, 0, sizeof(jsexcept)); + hres = jsdisp_propput_name(&function->dispex, prototypeW, ctx->lcid, &var, &jsexcept, NULL/*FIXME*/); + if(FAILED(hres)) { + IDispatchEx_Release(_IDispatchEx_(&function->dispex)); + return hres; + } + } - return jsdisp_propput_name(dispex, prototypeW, ctx->lcid, &var, &jsexcept, NULL/*FIXME*/); + *ret = function; + return S_OK; } -HRESULT create_builtin_function(script_ctx_t *ctx, builtin_invoke_t value_proc, - const builtin_info_t *builtin_info, DWORD flags, DispatchEx *prototype, DispatchEx **ret) +HRESULT create_builtin_function(script_ctx_t *ctx, builtin_invoke_t value_proc, DWORD flags, + DispatchEx *prototype, DispatchEx **ret) { FunctionInstance *function; HRESULT hres; - hres = create_function(ctx, builtin_info, flags, FALSE, NULL, &function); + hres = create_function(ctx, flags, FALSE, prototype, &function); if(FAILED(hres)) return hres; - hres = set_prototype(ctx, &function->dispex, prototype); - if(FAILED(hres)) { - jsdisp_release(&function->dispex); - return hres; - } - function->value_proc = value_proc; *ret = &function->dispex; @@ -498,12 +502,7 @@ HRESULT create_source_function(parser_ctx_t *ctx, parameter_t *parameters, sourc if(FAILED(hres)) return hres; - hres = create_function(ctx->script, NULL, PROPF_CONSTR, FALSE, NULL, &function); - if(SUCCEEDED(hres)) { - hres = set_prototype(ctx->script, &function->dispex, prototype); - if(FAILED(hres)) - jsdisp_release(&function->dispex); - } + hres = create_function(ctx->script, PROPF_CONSTR, FALSE, prototype, &function); jsdisp_release(prototype); if(FAILED(hres)) return hres; @@ -530,28 +529,23 @@ HRESULT create_source_function(parser_ctx_t *ctx, parameter_t *parameters, sourc return S_OK; } -HRESULT init_function_constr(script_ctx_t *ctx, DispatchEx *object_prototype) +HRESULT init_function_constr(script_ctx_t *ctx) { FunctionInstance *prot, *constr; HRESULT hres; - hres = create_function(ctx, NULL, PROPF_CONSTR, TRUE, object_prototype, &prot); + hres = create_function(ctx, PROPF_CONSTR, TRUE, NULL, &prot); if(FAILED(hres)) return hres; prot->value_proc = FunctionProt_value; - hres = create_function(ctx, NULL, PROPF_CONSTR, TRUE, &prot->dispex, &constr); - if(SUCCEEDED(hres)) { - constr->value_proc = FunctionConstr_value; - hres = set_prototype(ctx, &constr->dispex, &prot->dispex); - if(FAILED(hres)) - jsdisp_release(&constr->dispex); - } + hres = create_function(ctx, PROPF_CONSTR, TRUE, &prot->dispex, &constr); jsdisp_release(&prot->dispex); if(FAILED(hres)) return hres; + constr->value_proc = FunctionConstr_value; ctx->function_constr = &constr->dispex; - return S_OK; + return hres; } diff --git a/dlls/jscript/global.c b/dlls/jscript/global.c index 7d59e19c9f8..a714f8ef4e4 100644 --- a/dlls/jscript/global.c +++ b/dlls/jscript/global.c @@ -33,13 +33,6 @@ static const WCHAR InfinityW[] = {'I','n','f','i','n','i','t','y',0}; static const WCHAR ArrayW[] = {'A','r','r','a','y',0}; static const WCHAR BooleanW[] = {'B','o','o','l','e','a','n',0}; static const WCHAR DateW[] = {'D','a','t','e',0}; -static const WCHAR ErrorW[] = {'E','r','r','o','r',0}; -static const WCHAR EvalErrorW[] = {'E','v','a','l','E','r','r','o','r',0}; -static const WCHAR RangeErrorW[] = {'R','a','n','g','e','E','r','r','o','r',0}; -static const WCHAR ReferenceErrorW[] = {'R','e','f','e','r','e','n','c','e','E','r','r','o','r',0}; -static const WCHAR SyntaxErrorW[] = {'S','y','n','t','a','x','E','r','r','o','r',0}; -static const WCHAR TypeErrorW[] = {'T','y','p','e','E','r','r','o','r',0}; -static const WCHAR URIErrorW[] = {'U','R','I','E','r','r','o','r',0}; static const WCHAR FunctionW[] = {'F','u','n','c','t','i','o','n',0}; static const WCHAR NumberW[] = {'N','u','m','b','e','r',0}; static const WCHAR ObjectW[] = {'O','b','j','e','c','t',0}; @@ -172,62 +165,6 @@ static HRESULT JSGlobal_Date(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARA return constructor_call(dispex->ctx->date_constr, lcid, flags, dp, retv, ei, sp); } -static HRESULT JSGlobal_Error(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - - return constructor_call(dispex->ctx->error_constr, lcid, flags, dp, retv, ei, sp); -} - -static HRESULT JSGlobal_EvalError(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - - return constructor_call(dispex->ctx->eval_error_constr, lcid, flags, dp, retv, ei, sp); -} - -static HRESULT JSGlobal_RangeError(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - - return constructor_call(dispex->ctx->range_error_constr, lcid, flags, dp, retv, ei, sp); -} - -static HRESULT JSGlobal_ReferenceError(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - - return constructor_call(dispex->ctx->reference_error_constr, lcid, flags, dp, retv, ei, sp); -} - -static HRESULT JSGlobal_SyntaxError(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - - return constructor_call(dispex->ctx->syntax_error_constr, lcid, flags, dp, retv, ei, sp); -} - -static HRESULT JSGlobal_TypeError(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - - return constructor_call(dispex->ctx->type_error_constr, lcid, flags, dp, retv, ei, sp); -} - -static HRESULT JSGlobal_URIError(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - - return constructor_call(dispex->ctx->uri_error_constr, lcid, flags, dp, retv, ei, sp); -} - static HRESULT JSGlobal_Function(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { @@ -330,7 +267,7 @@ static HRESULT JSGlobal_eval(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARA hres = script_parse(dispex->ctx, V_BSTR(arg), NULL, &parser_ctx); if(FAILED(hres)) { WARN("parse (%s) failed: %08x\n", debugstr_w(V_BSTR(arg)), hres); - return throw_syntax_error(dispex->ctx, ei, hres, NULL); + return hres; } hres = exec_source(dispex->ctx->exec_ctx, parser_ctx, parser_ctx->source, ei, retv); @@ -604,8 +541,6 @@ static const builtin_prop_t JSGlobal_props[] = { {CollectGarbageW, JSGlobal_CollectGarbage, PROPF_METHOD}, {DateW, JSGlobal_Date, PROPF_CONSTR}, {EnumeratorW, JSGlobal_Enumerator, PROPF_METHOD}, - {ErrorW, JSGlobal_Error, PROPF_CONSTR}, - {EvalErrorW, JSGlobal_EvalError, PROPF_CONSTR}, {FunctionW, JSGlobal_Function, PROPF_CONSTR}, {_GetObjectW, JSGlobal_GetObject, PROPF_METHOD}, {InfinityW, JSGlobal_Infinity, 0}, @@ -613,17 +548,12 @@ static const builtin_prop_t JSGlobal_props[] = { {NaNW, JSGlobal_NaN, 0}, {NumberW, JSGlobal_Number, PROPF_CONSTR}, {ObjectW, JSGlobal_Object, PROPF_CONSTR}, - {RangeErrorW, JSGlobal_RangeError, PROPF_CONSTR}, - {ReferenceErrorW, JSGlobal_ReferenceError, PROPF_CONSTR}, {RegExpW, JSGlobal_RegExp, PROPF_CONSTR}, {ScriptEngineW, JSGlobal_ScriptEngine, PROPF_METHOD}, {ScriptEngineBuildVersionW, JSGlobal_ScriptEngineBuildVersion, PROPF_METHOD}, {ScriptEngineMajorVersionW, JSGlobal_ScriptEngineMajorVersion, PROPF_METHOD}, {ScriptEngineMinorVersionW, JSGlobal_ScriptEngineMinorVersion, PROPF_METHOD}, {StringW, JSGlobal_String, PROPF_CONSTR}, - {SyntaxErrorW, JSGlobal_SyntaxError, PROPF_CONSTR}, - {TypeErrorW, JSGlobal_TypeError, PROPF_CONSTR}, - {URIErrorW, JSGlobal_URIError, PROPF_CONSTR}, {VBArrayW, JSGlobal_VBArray, PROPF_METHOD}, {encodeURIW, JSGlobal_encodeURI, PROPF_METHOD}, {escapeW, JSGlobal_escape, PROPF_METHOD}, @@ -644,15 +574,11 @@ static const builtin_info_t JSGlobal_info = { NULL }; -static HRESULT init_constructors(script_ctx_t *ctx, DispatchEx *object_prototype) +static HRESULT init_constructors(script_ctx_t *ctx) { HRESULT hres; - hres = init_function_constr(ctx, object_prototype); - if(FAILED(hres)) - return hres; - - hres = create_object_constr(ctx, object_prototype, &ctx->object_constr); + hres = init_function_constr(ctx); if(FAILED(hres)) return hres; @@ -668,11 +594,11 @@ static HRESULT init_constructors(script_ctx_t *ctx, DispatchEx *object_prototype if(FAILED(hres)) return hres; - hres = init_error_constr(ctx); + hres = create_number_constr(ctx, &ctx->number_constr); if(FAILED(hres)) return hres; - hres = create_number_constr(ctx, &ctx->number_constr); + hres = create_object_constr(ctx, &ctx->object_constr); if(FAILED(hres)) return hres; @@ -689,19 +615,14 @@ static HRESULT init_constructors(script_ctx_t *ctx, DispatchEx *object_prototype HRESULT init_global(script_ctx_t *ctx) { - DispatchEx *math, *object_prototype; + DispatchEx *math; VARIANT var; HRESULT hres; if(ctx->global) return S_OK; - hres = create_object_prototype(ctx, &object_prototype); - if(FAILED(hres)) - return hres; - - hres = init_constructors(ctx, object_prototype); - jsdisp_release(object_prototype); + hres = init_constructors(ctx); if(FAILED(hres)) return hres; diff --git a/dlls/jscript/jscript.h b/dlls/jscript/jscript.h index 70c9fea603a..6cf3535c92f 100644 --- a/dlls/jscript/jscript.h +++ b/dlls/jscript/jscript.h @@ -28,13 +28,9 @@ #include "dispex.h" #include "activscp.h" -#include "resource.h" - #include "wine/unicode.h" #include "wine/list.h" -#define JSCRIPT_ERROR 0x800A0000 - typedef struct _script_ctx_t script_ctx_t; typedef struct _exec_ctx_t exec_ctx_t; typedef struct _dispex_prop_t dispex_prop_t; @@ -62,8 +58,6 @@ jsheap_t *jsheap_mark(jsheap_t*); typedef struct DispatchEx DispatchEx; -extern HINSTANCE jscript_hinstance; - #define PROPF_ARGMASK 0x00ff #define PROPF_METHOD 0x0100 #define PROPF_ENUM 0x0200 @@ -74,7 +68,6 @@ typedef enum { JSCLASS_ARRAY, JSCLASS_BOOLEAN, JSCLASS_DATE, - JSCLASS_ERROR, JSCLASS_FUNCTION, JSCLASS_GLOBAL, JSCLASS_MATH, @@ -130,7 +123,6 @@ DispatchEx *iface_to_jsdisp(IUnknown*); HRESULT disp_call(IDispatch*,DISPID,LCID,WORD,DISPPARAMS*,VARIANT*,jsexcept_t*,IServiceProvider*); HRESULT jsdisp_call_value(DispatchEx*,LCID,WORD,DISPPARAMS*,VARIANT*,jsexcept_t*,IServiceProvider*); -HRESULT jsdisp_call(DispatchEx*,DISPID,LCID,WORD,DISPPARAMS*,VARIANT*,jsexcept_t*,IServiceProvider*); HRESULT disp_propget(IDispatch*,DISPID,LCID,VARIANT*,jsexcept_t*,IServiceProvider*); HRESULT disp_propput(IDispatch*,DISPID,LCID,VARIANT*,jsexcept_t*,IServiceProvider*); HRESULT jsdisp_propget(DispatchEx*,DISPID,LCID,VARIANT*,jsexcept_t*,IServiceProvider*); @@ -139,19 +131,8 @@ HRESULT jsdisp_propput_idx(DispatchEx*,DWORD,LCID,VARIANT*,jsexcept_t*,IServiceP HRESULT jsdisp_propget_name(DispatchEx*,LPCWSTR,LCID,VARIANT*,jsexcept_t*,IServiceProvider*); HRESULT jsdisp_propget_idx(DispatchEx*,DWORD,LCID,VARIANT*,jsexcept_t*,IServiceProvider*); HRESULT jsdisp_get_id(DispatchEx*,const WCHAR*,DWORD,DISPID*); -HRESULT jsdisp_delete_idx(DispatchEx*,DWORD); - -HRESULT create_builtin_function(script_ctx_t*,builtin_invoke_t,const builtin_info_t*,DWORD, - DispatchEx*,DispatchEx**); -HRESULT Function_value(DispatchEx*,LCID,WORD,DISPPARAMS*,VARIANT*,jsexcept_t*,IServiceProvider*); - -HRESULT throw_eval_error(script_ctx_t*,jsexcept_t*,UINT,const WCHAR*); -HRESULT throw_range_error(script_ctx_t*,jsexcept_t*,UINT,const WCHAR*); -HRESULT throw_reference_error(script_ctx_t*,jsexcept_t*,UINT,const WCHAR*); -HRESULT throw_syntax_error(script_ctx_t*,jsexcept_t*,UINT,const WCHAR*); -HRESULT throw_type_error(script_ctx_t*,jsexcept_t*,UINT,const WCHAR*); -HRESULT throw_uri_error(script_ctx_t*,jsexcept_t*,UINT,const WCHAR*); +HRESULT create_builtin_function(script_ctx_t*,builtin_invoke_t,DWORD,DispatchEx*,DispatchEx**); HRESULT create_object(script_ctx_t*,DispatchEx*,DispatchEx**); HRESULT create_math(script_ctx_t*,DispatchEx**); @@ -161,13 +142,7 @@ HRESULT create_string(script_ctx_t*,const WCHAR*,DWORD,DispatchEx**); HRESULT create_bool(script_ctx_t*,VARIANT_BOOL,DispatchEx**); HRESULT create_number(script_ctx_t*,VARIANT*,DispatchEx**); -typedef enum { - NO_HINT, - HINT_STRING, - HINT_NUMBER -} hint_t; - -HRESULT to_primitive(script_ctx_t*,VARIANT*,jsexcept_t*,VARIANT*, hint_t); +HRESULT to_primitive(script_ctx_t*,VARIANT*,jsexcept_t*,VARIANT*); HRESULT to_boolean(VARIANT*,VARIANT_BOOL*); HRESULT to_number(script_ctx_t*,VARIANT*,jsexcept_t*,VARIANT*); HRESULT to_integer(script_ctx_t*,VARIANT*,jsexcept_t*,VARIANT*); @@ -201,13 +176,6 @@ struct _script_ctx_t { DispatchEx *array_constr; DispatchEx *bool_constr; DispatchEx *date_constr; - DispatchEx *error_constr; - DispatchEx *eval_error_constr; - DispatchEx *range_error_constr; - DispatchEx *reference_error_constr; - DispatchEx *syntax_error_constr; - DispatchEx *type_error_constr; - DispatchEx *uri_error_constr; DispatchEx *number_constr; DispatchEx *object_constr; DispatchEx *regexp_constr; @@ -222,15 +190,13 @@ static inline void script_addref(script_ctx_t *ctx) } HRESULT init_global(script_ctx_t*); -HRESULT init_function_constr(script_ctx_t*,DispatchEx*); -HRESULT create_object_prototype(script_ctx_t*,DispatchEx**); +HRESULT init_function_constr(script_ctx_t*); HRESULT create_array_constr(script_ctx_t*,DispatchEx**); HRESULT create_bool_constr(script_ctx_t*,DispatchEx**); HRESULT create_date_constr(script_ctx_t*,DispatchEx**); -HRESULT init_error_constr(script_ctx_t*); HRESULT create_number_constr(script_ctx_t*,DispatchEx**); -HRESULT create_object_constr(script_ctx_t*,DispatchEx*,DispatchEx**); +HRESULT create_object_constr(script_ctx_t*,DispatchEx**); HRESULT create_regexp_constr(script_ctx_t*,DispatchEx**); HRESULT create_string_constr(script_ctx_t*,DispatchEx**); diff --git a/dlls/jscript/jscript_De.rc b/dlls/jscript/jscript_De.rc deleted file mode 100644 index 2a265abfe8b..00000000000 --- a/dlls/jscript/jscript_De.rc +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright 2009 André Hentschel - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -#pragma code_page(65001) - -LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_TO_PRIMITIVE "Fehler beim umwandeln des Objektes in einen Grundtyp" - IDS_INVALID_CALL_ARG "Ungültiger Funktionsaufruf oder Argument" - IDS_NO_PROPERTY "Das Objekt unterstützt diese Eigenschaft oder Methode nicht" - IDS_ARG_NOT_OPT "Argument nicht optional" - IDS_NOT_FUNC "Funktion erwarted" - IDS_NOT_DATE "'[Objekt]' ist kein Datums-Objekt" - IDS_NOT_NUM "Nummer erwartet" - IDS_UNDEFINED "'|' nicht definiert" - IDS_NOT_BOOL "Boolisches Objekt erwartet" - IDS_INVALID_LENGTH "Array-Größe muss eine endliche, positive Ganzzahl sein" -} diff --git a/dlls/jscript/jscript_En.rc b/dlls/jscript/jscript_En.rc deleted file mode 100644 index b47e9517abc..00000000000 --- a/dlls/jscript/jscript_En.rc +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright 2009 Piotr Caban - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT - -STRINGTABLE DISCARDABLE -{ - IDS_TO_PRIMITIVE "Error converting object to primitive type" - IDS_INVALID_CALL_ARG "Invalid procedure call or argument" - IDS_NO_PROPERTY "Object doesn't support this property or method" - IDS_ARG_NOT_OPT "Argument not optional" - IDS_SYNTAX_ERROR "Syntax error" - IDS_SEMICOLON "Expected ';'" - IDS_LBRACKET "Expected '('" - IDS_RBRACKET "Expected ')'" - IDS_NOT_FUNC "Function expected" - IDS_NOT_DATE "'[object]' is not a date object" - IDS_NOT_NUM "Number expected" - IDS_ILLEGAL_ASSIGN "Illegal assignment" - IDS_UNDEFINED "'|' is undefined" - IDS_NOT_BOOL "Boolean object expected" - IDS_INVALID_LENGTH "Array length must be a finite positive integer" -} diff --git a/dlls/jscript/jscript_Fr.rc b/dlls/jscript/jscript_Fr.rc deleted file mode 100644 index 3d31d51ae41..00000000000 --- a/dlls/jscript/jscript_Fr.rc +++ /dev/null @@ -1,40 +0,0 @@ -/* - * French resources for jscript - * - * Copyright 2009 Frédéric Delanoy - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_TO_PRIMITIVE "Erreur lors de la conversion de l'objet vers un type primitif" - IDS_INVALID_CALL_ARG "Appel de procédure ou argument invalide" - IDS_NO_PROPERTY "Cet objet ne supporte pas cette propriété ou méthode" - IDS_ARG_NOT_OPT "Argument non optionnel" - IDS_NOT_FUNC "Fonction attendue" - IDS_NOT_DATE "« [objet] » n'est pas un objet de type date" - IDS_NOT_NUM "Nombre attendu" - IDS_UNDEFINED "« | » n'est pas défini" - IDS_NOT_BOOL "Booléen attendu" - IDS_INVALID_LENGTH "La longueur d'un tableau doit être un entier positif" -} diff --git a/dlls/jscript/jscript_Lt.rc b/dlls/jscript/jscript_Lt.rc deleted file mode 100644 index 787fa6c9a4d..00000000000 --- a/dlls/jscript/jscript_Lt.rc +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_TO_PRIMITIVE "Klaida keičiant objektą į primityvų tipą" - IDS_INVALID_CALL_ARG "Netinkamas kreipinys į procedūrą ar argumentas" - IDS_NO_PROPERTY "Objektas nepalaiko šios savybės ar metodo" - IDS_ARG_NOT_OPT "Argumentas nėra neprivalomas" - IDS_NOT_FUNC "Tikėtasi funkcijos" - IDS_NOT_DATE "„[objektas]“ nėra datos objektas" - IDS_NOT_NUM "Tikėtasi skaičiaus" - IDS_UNDEFINED "„|“ yra neapibrėžtas" - IDS_NOT_BOOL "Tikėtasi loginio objekto" - IDS_INVALID_LENGTH "Masyvo dydis turi būti teigiamas sveikasis skaičius" -} diff --git a/dlls/jscript/jscript_Nl.rc b/dlls/jscript/jscript_Nl.rc deleted file mode 100644 index 71ba6b5517d..00000000000 --- a/dlls/jscript/jscript_Nl.rc +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright 2009 Paul Vriens - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_TO_PRIMITIVE "Fout bij het omzetten van het object naar een primitief type" - IDS_INVALID_CALL_ARG "Ongeldige procedure-aanroep of argument" - IDS_NO_PROPERTY "Dit object ondersteunt deze eigenschap of methode niet" - IDS_ARG_NOT_OPT "Argument is niet optioneel" - IDS_SYNTAX_ERROR "Syntax fout" - IDS_SEMICOLON "';' verwacht" - IDS_LBRACKET "'(' verwacht" - IDS_RBRACKET "')' verwacht" - IDS_NOT_FUNC "Functie verwacht" - IDS_NOT_DATE "'[object]' is geen datum object" - IDS_NOT_NUM "Getal verwacht" - IDS_ILLEGAL_ASSIGN "Ongeldige toekenning" - IDS_UNDEFINED "'|' is ongedefinieerd" - IDS_NOT_BOOL "Boolean object verwacht" - IDS_INVALID_LENGTH "Array lengte moet een eindig, positief geheel getal zijn" -} diff --git a/dlls/jscript/jscript_main.c b/dlls/jscript/jscript_main.c index 4f59ecbc11a..37266e5773c 100644 --- a/dlls/jscript/jscript_main.c +++ b/dlls/jscript/jscript_main.c @@ -40,7 +40,7 @@ static const CLSID CLSID_JScriptEncode = DEFINE_GUID(GUID_NULL,0,0,0,0,0,0,0,0,0,0,0); -HINSTANCE jscript_hinstance; +static HINSTANCE jscript_hinstance; static HRESULT WINAPI ClassFactory_QueryInterface(IClassFactory *iface, REFIID riid, void **ppv) { diff --git a/dlls/jscript/jsutils.c b/dlls/jscript/jsutils.c index 10d4f51b074..73bac94d7e8 100644 --- a/dlls/jscript/jsutils.c +++ b/dlls/jscript/jsutils.c @@ -175,7 +175,7 @@ jsheap_t *jsheap_mark(jsheap_t *heap) } /* ECMA-262 3rd Edition 9.1 */ -HRESULT to_primitive(script_ctx_t *ctx, VARIANT *v, jsexcept_t *ei, VARIANT *ret, hint_t hint) +HRESULT to_primitive(script_ctx_t *ctx, VARIANT *v, jsexcept_t *ei, VARIANT *ret) { switch(V_VT(v)) { case VT_EMPTY: @@ -189,61 +189,8 @@ HRESULT to_primitive(script_ctx_t *ctx, VARIANT *v, jsexcept_t *ei, VARIANT *ret V_VT(ret) = VT_BSTR; V_BSTR(ret) = SysAllocString(V_BSTR(v)); break; - case VT_DISPATCH: { - DispatchEx *jsdisp; - DISPID id; - DISPPARAMS dp = {NULL, NULL, 0, 0}; - HRESULT hres; - - static const WCHAR toStringW[] = {'t','o','S','t','r','i','n','g',0}; - static const WCHAR valueOfW[] = {'v','a','l','u','e','O','f',0}; - - jsdisp = iface_to_jsdisp((IUnknown*)V_DISPATCH(v)); - if(!jsdisp) - return disp_propget(V_DISPATCH(v), DISPID_VALUE, ctx->lcid, ret, ei, NULL /*FIXME*/); - - if(hint == NO_HINT) - hint = is_class(jsdisp, JSCLASS_DATE) ? HINT_STRING : HINT_NUMBER; - - /* Native implementation doesn't throw TypeErrors, returns strange values */ - - hres = jsdisp_get_id(jsdisp, hint == HINT_STRING ? toStringW : valueOfW, 0, &id); - if(SUCCEEDED(hres)) { - hres = jsdisp_call(jsdisp, id, ctx->lcid, DISPATCH_METHOD, &dp, ret, ei, NULL /*FIXME*/); - if(FAILED(hres)) { - WARN("call error - forwarding exception\n"); - jsdisp_release(jsdisp); - return hres; - } - else if(V_VT(ret) != VT_DISPATCH) { - jsdisp_release(jsdisp); - return S_OK; - } - else - IDispatch_Release(V_DISPATCH(ret)); - } - - hres = jsdisp_get_id(jsdisp, hint == HINT_STRING ? valueOfW : toStringW, 0, &id); - if(SUCCEEDED(hres)) { - hres = jsdisp_call(jsdisp, id, ctx->lcid, DISPATCH_METHOD, &dp, ret, ei, NULL /*FIXME*/); - if(FAILED(hres)) { - WARN("call error - forwarding exception\n"); - jsdisp_release(jsdisp); - return hres; - } - else if(V_VT(ret) != VT_DISPATCH) { - jsdisp_release(jsdisp); - return S_OK; - } - else - IDispatch_Release(V_DISPATCH(ret)); - } - - jsdisp_release(jsdisp); - - WARN("failed\n"); - return throw_type_error(ctx, ei, IDS_TO_PRIMITIVE, NULL); - } + case VT_DISPATCH: + return disp_propget(V_DISPATCH(v), DISPID_VALUE, ctx->lcid, ret, ei, NULL /*FIXME*/); default: FIXME("Unimplemented for vt %d\n", V_VT(v)); return E_NOTIMPL; @@ -264,8 +211,7 @@ HRESULT to_boolean(VARIANT *v, VARIANT_BOOL *b) *b = V_I4(v) ? VARIANT_TRUE : VARIANT_FALSE; break; case VT_R8: - if(isnan(V_R8(v))) *b = VARIANT_FALSE; - else *b = V_R8(v) ? VARIANT_TRUE : VARIANT_FALSE; + *b = V_R8(v) ? VARIANT_TRUE : VARIANT_FALSE; break; case VT_BSTR: *b = V_BSTR(v) && *V_BSTR(v) ? VARIANT_TRUE : VARIANT_FALSE; @@ -409,7 +355,7 @@ HRESULT to_number(script_ctx_t *ctx, VARIANT *v, jsexcept_t *ei, VARIANT *ret) VARIANT prim; HRESULT hres; - hres = to_primitive(ctx, v, ei, &prim, HINT_NUMBER); + hres = to_primitive(ctx, v, ei, &prim); if(FAILED(hres)) return hres; @@ -512,8 +458,6 @@ HRESULT to_string(script_ctx_t *ctx, VARIANT *v, jsexcept_t *ei, BSTR *str) const WCHAR nullW[] = {'n','u','l','l',0}; const WCHAR trueW[] = {'t','r','u','e',0}; const WCHAR falseW[] = {'f','a','l','s','e',0}; - const WCHAR NaNW[] = {'N','a','N',0}; - const WCHAR InfinityW[] = {'-','I','n','f','i','n','i','t','y',0}; switch(V_VT(v)) { case VT_EMPTY: @@ -526,23 +470,16 @@ HRESULT to_string(script_ctx_t *ctx, VARIANT *v, jsexcept_t *ei, BSTR *str) *str = int_to_bstr(V_I4(v)); break; case VT_R8: { - if(isnan(V_R8(v))) - *str = SysAllocString(NaNW); - else if(isinf(V_R8(v))) - *str = SysAllocString(V_R8(v)<0 ? InfinityW : InfinityW+1); - else { - VARIANT strv; - HRESULT hres; - - V_VT(&strv) = VT_EMPTY; - hres = VariantChangeTypeEx(&strv, v, MAKELCID(MAKELANGID(LANG_ENGLISH,SUBLANG_ENGLISH_US),SORT_DEFAULT), 0, VT_BSTR); - if(FAILED(hres)) - return hres; - - *str = V_BSTR(&strv); - return S_OK; - } - break; + VARIANT strv; + HRESULT hres; + + V_VT(&strv) = VT_EMPTY; + hres = VariantChangeTypeEx(&strv, v, MAKELCID(MAKELANGID(LANG_ENGLISH,SUBLANG_ENGLISH_US),SORT_DEFAULT), 0, VT_BSTR); + if(FAILED(hres)) + return hres; + + *str = V_BSTR(&strv); + return S_OK; } case VT_BSTR: *str = SysAllocString(V_BSTR(v)); @@ -551,7 +488,7 @@ HRESULT to_string(script_ctx_t *ctx, VARIANT *v, jsexcept_t *ei, BSTR *str) VARIANT prim; HRESULT hres; - hres = to_primitive(ctx, v, ei, &prim, HINT_STRING); + hres = to_primitive(ctx, v, ei, &prim); if(FAILED(hres)) return hres; diff --git a/dlls/jscript/math.c b/dlls/jscript/math.c index b172ffdf72d..9d609e5d8c0 100644 --- a/dlls/jscript/math.c +++ b/dlls/jscript/math.c @@ -1,6 +1,5 @@ /* * Copyright 2008 Jacek Caban for CodeWeavers - * Copyright 2009 Piotr Caban * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public diff --git a/dlls/jscript/number.c b/dlls/jscript/number.c index 0aeeab6386a..d909cdb851a 100644 --- a/dlls/jscript/number.c +++ b/dlls/jscript/number.c @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include - #include "jscript.h" #include "wine/debug.h" @@ -41,126 +39,31 @@ static const WCHAR propertyIsEnumerableW[] = {'p','r','o','p','e','r','t','y','I','s','E','n','u','m','e','r','a','b','l','e',0}; static const WCHAR isPrototypeOfW[] = {'i','s','P','r','o','t','o','t','y','p','e','O','f',0}; -#define NUMBER_TOSTRING_BUF_SIZE 64 /* ECMA-262 3rd Edition 15.7.4.2 */ static HRESULT Number_toString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { NumberInstance *number; - INT radix = 10; - DOUBLE val; BSTR str; HRESULT hres; TRACE("\n"); - if(!is_class(dispex, JSCLASS_NUMBER)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_NUM, NULL); - - number = (NumberInstance*)dispex; - - if(arg_cnt(dp)) { - hres = to_int32(dispex->ctx, get_arg(dp, 0), ei, &radix); - if(FAILED(hres)) - return hres; - - if(radix<2 || radix>36) - return throw_type_error(dispex->ctx, ei, IDS_INVALID_CALL_ARG, NULL); + if(!is_class(dispex, JSCLASS_NUMBER)) { + FIXME("throw TypeError\n"); + return E_FAIL; } - if(V_VT(&number->num) == VT_I4) - val = V_I4(&number->num); - else - val = V_R8(&number->num); + number = (NumberInstance*)dispex; - if(radix==10 || isnan(val) || isinf(val)) { - hres = to_string(dispex->ctx, &number->num, ei, &str); - if(FAILED(hres)) - return hres; + if(arg_cnt(dp) != 0) { + FIXME("unsupported args\n"); + return E_NOTIMPL; } - else { - INT idx = 0; - DOUBLE integ, frac, log_radix = 0; - WCHAR buf[NUMBER_TOSTRING_BUF_SIZE+16]; - BOOL exp = FALSE; - - if(val<0) { - val = -val; - buf[idx++] = '-'; - } - while(1) { - integ = floor(val); - frac = val-integ; - - if(integ == 0) - buf[idx++] = '0'; - while(integ>=1 && idx beg) { - wch = buf[beg]; - buf[beg++] = buf[end]; - buf[end--] = wch; - } - } - - if(idx != NUMBER_TOSTRING_BUF_SIZE) buf[idx++] = '.'; - - while(frac>0 && idxctx, &number->num, ei, &str); + if(FAILED(hres)) + return hres; if(retv) { V_VT(retv) = VT_BSTR; @@ -204,8 +107,10 @@ static HRESULT Number_valueOf(DispatchEx *dispex, LCID lcid, WORD flags, DISPPAR { TRACE("\n"); - if(!is_class(dispex, JSCLASS_NUMBER)) - return throw_type_error(dispex->ctx, ei, IDS_NOT_NUM, NULL); + if(!is_class(dispex, JSCLASS_NUMBER)) { + FIXME("throw TypeError\n"); + return E_FAIL; + } if(retv) { NumberInstance *number = (NumberInstance*)dispex; @@ -241,8 +146,6 @@ static HRESULT Number_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM NumberInstance *number = (NumberInstance*)dispex; switch(flags) { - case INVOKE_FUNC: - return throw_type_error(dispex->ctx, ei, IDS_NOT_FUNC, NULL); case DISPATCH_PROPERTYGET: *retv = number->num; break; @@ -360,7 +263,7 @@ HRESULT create_number_constr(script_ctx_t *ctx, DispatchEx **ret) return hres; V_VT(&number->num) = VT_I4; - hres = create_builtin_function(ctx, NumberConstr_value, NULL, PROPF_CONSTR, &number->dispex, ret); + hres = create_builtin_function(ctx, NumberConstr_value, PROPF_CONSTR, &number->dispex, ret); jsdisp_release(&number->dispex); return hres; diff --git a/dlls/jscript/object.c b/dlls/jscript/object.c index 737230ada85..02d80de02fd 100644 --- a/dlls/jscript/object.c +++ b/dlls/jscript/object.c @@ -35,62 +35,22 @@ static const WCHAR default_valueW[] = {'[','o','b','j','e','c','t',' ','O','b',' static HRESULT Object_toString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - static const WCHAR formatW[] = {'[','o','b','j','e','c','t',' ','%','s',']',0}; - - static const WCHAR arrayW[] = {'A','r','r','a','y',0}; - static const WCHAR booleanW[] = {'B','o','o','l','e','a','n',0}; - static const WCHAR dateW[] = {'D','a','t','e',0}; - static const WCHAR errorW[] = {'E','r','r','o','r',0}; - static const WCHAR functionW[] = {'F','u','n','c','t','i','o','n',0}; - static const WCHAR mathW[] = {'M','a','t','h',0}; - static const WCHAR numberW[] = {'N','u','m','b','e','r',0}; - static const WCHAR objectW[] = {'O','b','j','e','c','t',0}; - static const WCHAR regexpW[] = {'R','e','g','E','x','p',0}; - static const WCHAR stringW[] = {'S','t','r','i','n','g',0}; - /* Keep in sync with jsclass_t enum */ - static const WCHAR *names[] = {NULL, arrayW, booleanW, dateW, errorW, - functionW, NULL, mathW, numberW, objectW, regexpW, stringW}; - - TRACE("\n"); - - if(names[dispex->builtin_info->class] == NULL) { - ERR("dispex->builtin_info->class = %d\n", - dispex->builtin_info->class); - return E_FAIL; - } - - if(retv) { - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = SysAllocStringLen(NULL, 9+strlenW(names[dispex->builtin_info->class])); - if(!V_BSTR(retv)) - return E_OUTOFMEMORY; - - sprintfW(V_BSTR(retv), formatW, names[dispex->builtin_info->class]); - } - - return S_OK; + FIXME("\n"); + return E_NOTIMPL; } static HRESULT Object_toLocaleString(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - TRACE("\n"); - return Object_toString(dispex, lcid, flags, dp, retv, ei, sp); + FIXME("\n"); + return E_NOTIMPL; } static HRESULT Object_valueOf(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - TRACE("\n"); - - if(retv) { - IDispatchEx_AddRef(_IDispatchEx_(dispex)); - - V_VT(retv) = VT_DISPATCH; - V_DISPATCH(retv) = (IDispatch*)_IDispatchEx_(dispex); - } - - return S_OK; + FIXME("\n"); + return E_NOTIMPL; } static HRESULT Object_hasOwnProperty(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, @@ -120,8 +80,6 @@ static HRESULT Object_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM TRACE("\n"); switch(flags) { - case INVOKE_FUNC: - return throw_type_error(dispex->ctx, ei, IDS_NOT_FUNC, NULL); case DISPATCH_PROPERTYGET: V_VT(retv) = VT_BSTR; V_BSTR(retv) = SysAllocString(default_valueW); @@ -187,15 +145,19 @@ static HRESULT ObjectConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, DIS return S_OK; } -HRESULT create_object_constr(script_ctx_t *ctx, DispatchEx *object_prototype, DispatchEx **ret) +HRESULT create_object_constr(script_ctx_t *ctx, DispatchEx **ret) { - return create_builtin_function(ctx, ObjectConstr_value, NULL, PROPF_CONSTR, - object_prototype, ret); -} + DispatchEx *object; + HRESULT hres; -HRESULT create_object_prototype(script_ctx_t *ctx, DispatchEx **ret) -{ - return create_dispex(ctx, &Object_info, NULL, ret); + hres = create_dispex(ctx, &Object_info, NULL, &object); + if(FAILED(hres)) + return hres; + + hres = create_builtin_function(ctx, ObjectConstr_value, PROPF_CONSTR, object, ret); + + jsdisp_release(object); + return hres; } HRESULT create_object(script_ctx_t *ctx, DispatchEx *constr, DispatchEx **ret) diff --git a/dlls/jscript/parser.y b/dlls/jscript/parser.y index a0ae471953f..52a31c88a79 100644 --- a/dlls/jscript/parser.y +++ b/dlls/jscript/parser.y @@ -25,8 +25,6 @@ #define YYPARSE_PARAM ctx static int parser_error(const char*); -static void set_error(parser_ctx_t*,UINT); -static BOOL explicit_error(parser_ctx_t*,void*,WCHAR); static BOOL allow_auto_semicolon(parser_ctx_t*); static void program_parsed(parser_ctx_t*,source_elements_t*); static source_elements_t *function_body_parsed(parser_ctx_t*,source_elements_t*); @@ -202,7 +200,7 @@ static source_elements_t *source_elements_add_statement(source_elements_t*,state %type Finally %type StatementList StatementList_opt %type FormalParameterList FormalParameterList_opt -%type Expression Expression_opt Expression_err +%type Expression Expression_opt %type ExpressionNoIn ExpressionNoIn_opt %type FunctionExpression %type AssignmentExpression AssignmentExpressionNoIn @@ -268,7 +266,7 @@ SourceElements /* ECMA-262 3rd Edition 13 */ FunctionExpression - : KFunction Identifier_opt left_bracket FormalParameterList_opt right_bracket '{' FunctionBody '}' + : KFunction Identifier_opt '(' FormalParameterList_opt ')' '{' FunctionBody '}' { $$ = new_function_expression(ctx, $2, $4, $7, $1, $8-$1+1); } KFunction @@ -381,32 +379,24 @@ ExpressionStatement /* ECMA-262 3rd Edition 12.5 */ IfStatement - : kIF left_bracket Expression_err right_bracket Statement kELSE Statement + : kIF '(' Expression ')' Statement kELSE Statement { $$ = new_if_statement(ctx, $3, $5, $7); } - | kIF left_bracket Expression_err right_bracket Statement %prec LOWER_THAN_ELSE + | kIF '(' Expression ')' Statement %prec LOWER_THAN_ELSE { $$ = new_if_statement(ctx, $3, $5, NULL); } /* ECMA-262 3rd Edition 12.6 */ IterationStatement - : kDO Statement kWHILE left_bracket Expression_err right_bracket semicolon_opt + : kDO Statement kWHILE '(' Expression ')' ';' { $$ = new_while_statement(ctx, TRUE, $5, $2); } - | kWHILE left_bracket Expression_err right_bracket Statement + | kWHILE '(' Expression ')' Statement { $$ = new_while_statement(ctx, FALSE, $3, $5); } - | kFOR left_bracket ExpressionNoIn_opt - { if(!explicit_error(ctx, $3, ';')) YYABORT; } - semicolon Expression_opt - { if(!explicit_error(ctx, $6, ';')) YYABORT; } - semicolon Expression_opt right_bracket Statement - { $$ = new_for_statement(ctx, NULL, $3, $6, $9, $11); } - | kFOR left_bracket kVAR VariableDeclarationListNoIn - { if(!explicit_error(ctx, $4, ';')) YYABORT; } - semicolon Expression_opt - { if(!explicit_error(ctx, $7, ';')) YYABORT; } - semicolon Expression_opt right_bracket Statement - { $$ = new_for_statement(ctx, $4, NULL, $7, $10, $12); } - | kFOR left_bracket LeftHandSideExpression kIN Expression_err right_bracket Statement + | kFOR '(' ExpressionNoIn_opt ';' Expression_opt ';' Expression_opt ')' Statement + { $$ = new_for_statement(ctx, NULL, $3, $5, $7, $9); } + | kFOR '(' kVAR VariableDeclarationListNoIn ';' Expression_opt ';' Expression_opt ')' Statement + { $$ = new_for_statement(ctx, $4, NULL, $6, $8, $10); } + | kFOR '(' LeftHandSideExpression kIN Expression ')' Statement { $$ = new_forin_statement(ctx, NULL, $3, $5, $7); } - | kFOR left_bracket kVAR VariableDeclarationNoIn kIN Expression_err right_bracket Statement + | kFOR '(' kVAR VariableDeclarationNoIn kIN Expression ')' Statement { $$ = new_forin_statement(ctx, $4, NULL, $6, $8); } /* ECMA-262 3rd Edition 12.7 */ @@ -426,7 +416,7 @@ ReturnStatement /* ECMA-262 3rd Edition 12.10 */ WithStatement - : kWITH left_bracket Expression right_bracket Statement + : kWITH '(' Expression ')' Statement { $$ = new_with_statement(ctx, $3, $5); } /* ECMA-262 3rd Edition 12.12 */ @@ -436,8 +426,8 @@ LabelledStatement /* ECMA-262 3rd Edition 12.11 */ SwitchStatement - : kSWITCH left_bracket Expression right_bracket CaseBlock - { $$ = new_switch_statement(ctx, $3, $5); } + : kSWITCH '(' Expression ')' CaseBlock + { $$ = new_switch_statement(ctx, $3, $5); } /* ECMA-262 3rd Edition 12.11 */ CaseBlock @@ -481,8 +471,8 @@ TryStatement /* ECMA-262 3rd Edition 12.14 */ Catch - : kCATCH left_bracket tIdentifier right_bracket Block - { $$ = new_catch_block(ctx, $3, $5); } + : kCATCH '(' tIdentifier ')' Block + { $$ = new_catch_block(ctx, $3, $5); } /* ECMA-262 3rd Edition 12.14 */ Finally @@ -493,10 +483,6 @@ Expression_opt : /* empty */ { $$ = NULL; } | Expression { $$ = $1; } -Expression_err - : Expression { $$ = $1; } - | error { set_error(ctx, IDS_SYNTAX_ERROR); YYABORT; } - /* ECMA-262 3rd Edition 11.14 */ Expression : AssignmentExpression { $$ = $1; } @@ -810,18 +796,6 @@ semicolon_opt : ';' | error { if(!allow_auto_semicolon(ctx)) {YYABORT;} } -left_bracket - : '(' - | error { set_error(ctx, IDS_LBRACKET); YYABORT; } - -right_bracket - : ')' - | error { set_error(ctx, IDS_RBRACKET); YYABORT; } - -semicolon - : ';' - | error { set_error(ctx, IDS_SEMICOLON); YYABORT; } - %% static BOOL allow_auto_semicolon(parser_ctx_t *ctx) @@ -1460,20 +1434,6 @@ static int parser_error(const char *str) return 0; } -static void set_error(parser_ctx_t *ctx, UINT error) -{ - ctx->hres = JSCRIPT_ERROR|error; -} - -static BOOL explicit_error(parser_ctx_t *ctx, void *obj, WCHAR next) -{ - if(obj || *(ctx->ptr-1)==next) return TRUE; - - set_error(ctx, IDS_SYNTAX_ERROR); - return FALSE; -} - - static expression_t *new_identifier_expression(parser_ctx_t *ctx, const WCHAR *identifier) { identifier_expression_t *ret = parser_alloc(ctx, sizeof(identifier_expression_t)); @@ -1608,7 +1568,7 @@ HRESULT script_parse(script_ctx_t *ctx, const WCHAR *code, const WCHAR *delimite return E_OUTOFMEMORY; parser_ctx->ref = 1; - parser_ctx->hres = JSCRIPT_ERROR|IDS_SYNTAX_ERROR; + parser_ctx->hres = E_FAIL; parser_ctx->is_html = delimiter && !strcmpiW(delimiter, html_tagW); parser_ctx->begin = parser_ctx->ptr = code; diff --git a/dlls/jscript/regexp.c b/dlls/jscript/regexp.c index a4d640ef860..fe552b10778 100644 --- a/dlls/jscript/regexp.c +++ b/dlls/jscript/regexp.c @@ -96,7 +96,6 @@ static const WCHAR propertyIsEnumerableW[] = {'p','r','o','p','e','r','t','y','I','s','E','n','u','m','e','r','a','b','l','e',0}; static const WCHAR isPrototypeOfW[] = {'i','s','P','r','o','t','o','t','y','p','e','O','f',0}; static const WCHAR execW[] = {'e','x','e','c',0}; -static const WCHAR testW[] = {'t','e','s','t',0}; static const WCHAR emptyW[] = {0}; @@ -3506,29 +3505,13 @@ static HRESULT RegExp_exec(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS return E_NOTIMPL; } -static HRESULT RegExp_test(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, +static HRESULT RegExp_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { FIXME("\n"); return E_NOTIMPL; } -static HRESULT RegExp_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, - VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - TRACE("\n"); - - switch(flags) { - case INVOKE_FUNC: - return throw_type_error(dispex->ctx, ei, IDS_NOT_FUNC, NULL); - default: - FIXME("unimplemented flags %x\n", flags); - return E_NOTIMPL; - } - - return S_OK; -} - static void RegExp_destructor(DispatchEx *dispex) { RegExpInstance *This = (RegExpInstance*)dispex; @@ -3549,7 +3532,6 @@ static const builtin_prop_t RegExp_props[] = { {multilineW, RegExp_multiline, 0}, {propertyIsEnumerableW, RegExp_propertyIsEnumerable, PROPF_METHOD}, {sourceW, RegExp_source, 0}, - {testW, RegExp_test, PROPF_METHOD}, {toLocaleStringW, RegExp_toLocaleString, PROPF_METHOD}, {toStringW, RegExp_toString, PROPF_METHOD} }; @@ -3703,7 +3685,7 @@ HRESULT create_regexp_constr(script_ctx_t *ctx, DispatchEx **ret) if(FAILED(hres)) return hres; - hres = create_builtin_function(ctx, RegExpConstr_value, NULL, PROPF_CONSTR, ®exp->dispex, ret); + hres = create_builtin_function(ctx, RegExpConstr_value, PROPF_CONSTR, ®exp->dispex, ret); jsdisp_release(®exp->dispex); return hres; diff --git a/dlls/jscript/resource.h b/dlls/jscript/resource.h deleted file mode 100644 index 05039616176..00000000000 --- a/dlls/jscript/resource.h +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2009 Piotr Caban - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include - -#define IDS_TO_PRIMITIVE 0x0001 -#define IDS_INVALID_CALL_ARG 0x0005 -#define IDS_NO_PROPERTY 0x01B6 -#define IDS_ARG_NOT_OPT 0x01c1 -#define IDS_SYNTAX_ERROR 0x03EA -#define IDS_SEMICOLON 0x03EC -#define IDS_LBRACKET 0x03ED -#define IDS_RBRACKET 0x03EE -#define IDS_NOT_FUNC 0x138A -#define IDS_NOT_DATE 0x138E -#define IDS_NOT_NUM 0x1389 -#define IDS_ILLEGAL_ASSIGN 0x1390 -#define IDS_UNDEFINED 0x1391 -#define IDS_NOT_BOOL 0x1392 -#define IDS_INVALID_LENGTH 0x13A5 diff --git a/dlls/jscript/string.c b/dlls/jscript/string.c index 6695bf893cb..82c1043490e 100644 --- a/dlls/jscript/string.c +++ b/dlls/jscript/string.c @@ -66,7 +66,6 @@ static const WCHAR hasOwnPropertyW[] = {'h','a','s','O','w','n','P','r','o','p', static const WCHAR propertyIsEnumerableW[] = {'p','r','o','p','e','r','t','y','I','s','E','n','u','m','e','r','a','b','l','e',0}; static const WCHAR isPrototypeOfW[] = {'i','s','P','r','o','t','o','t','y','p','e','O','f',0}; -static const WCHAR fromCharCodeW[] = {'f','r','o','m','C','h','a','r','C','o','d','e',0}; static HRESULT String_length(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) @@ -128,123 +127,34 @@ static HRESULT do_attributeless_tag_format(DispatchEx *dispex, LCID lcid, WORD f VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp, const WCHAR *tagname) { static const WCHAR tagfmt[] = {'<','%','s','>','%','s','<','/','%','s','>',0}; - const WCHAR *str; - DWORD length; - BSTR val_str = NULL; - HRESULT hres; - - if(!is_class(dispex, JSCLASS_STRING)) { - VARIANT this; - - V_VT(&this) = VT_DISPATCH; - V_DISPATCH(&this) = (IDispatch*)_IDispatchEx_(dispex); - - hres = to_string(dispex->ctx, &this, ei, &val_str); - if(FAILED(hres)) - return hres; - - str = val_str; - length = SysStringLen(val_str); - } - else { - StringInstance *this = (StringInstance*)dispex; - - str = this->str; - length = this->length; - } - - if(retv) { - BSTR ret = SysAllocStringLen(NULL, length + 2*strlenW(tagname) + 5); - if(!ret) { - SysFreeString(val_str); - return E_OUTOFMEMORY; - } - - sprintfW(ret, tagfmt, tagname, str, tagname); - - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = ret; - } - - SysFreeString(val_str); - return S_OK; -} - -static HRESULT do_attribute_tag_format(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp, - const WCHAR *tagname, const WCHAR *attr) -{ - static const WCHAR tagfmtW[] - = {'<','%','s',' ','%','s','=','\"','%','s','\"','>','%','s','<','/','%','s','>',0}; - static const WCHAR undefinedW[] = {'u','n','d','e','f','i','n','e','d',0}; - - const WCHAR *str; - DWORD length; - BSTR attr_value, val_str = NULL; - HRESULT hres; + StringInstance *string; + BSTR ret; if(!is_class(dispex, JSCLASS_STRING)) { - VARIANT this; - - V_VT(&this) = VT_DISPATCH; - V_DISPATCH(&this) = (IDispatch*)_IDispatchEx_(dispex); - - hres = to_string(dispex->ctx, &this, ei, &val_str); - if(FAILED(hres)) - return hres; - - str = val_str; - length = SysStringLen(val_str); - } - else { - StringInstance *this = (StringInstance*)dispex; - - str = this->str; - length = this->length; + WARN("this is not a string object\n"); + return E_NOTIMPL; } - if(arg_cnt(dp)) { - hres = to_string(dispex->ctx, get_arg(dp, 0), ei, &attr_value); - if(FAILED(hres)) { - SysFreeString(val_str); - return hres; - } - } - else { - attr_value = SysAllocString(undefinedW); - if(!attr_value) { - SysFreeString(val_str); - return E_OUTOFMEMORY; - } - } + string = (StringInstance*)dispex; if(retv) { - BSTR ret = SysAllocStringLen(NULL, length + 2*strlenW(tagname) - + strlenW(attr) + SysStringLen(attr_value) + 9); - if(!ret) { - SysFreeString(attr_value); - SysFreeString(val_str); + ret = SysAllocStringLen(NULL, string->length + 2*strlenW(tagname) + 5); + if(!ret) return E_OUTOFMEMORY; - } - sprintfW(ret, tagfmtW, tagname, attr, attr_value, str, tagname); + sprintfW(ret, tagfmt, tagname, string->str, tagname); V_VT(retv) = VT_BSTR; V_BSTR(retv) = ret; } - - SysFreeString(attr_value); - SysFreeString(val_str); return S_OK; } static HRESULT String_anchor(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - static const WCHAR fontW[] = {'A',0}; - static const WCHAR colorW[] = {'N','A','M','E',0}; - - return do_attribute_tag_format(dispex, lcid, flags, dp, retv, ei, sp, fontW, colorW); + FIXME("\n"); + return E_NOTIMPL; } static HRESULT String_big(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, @@ -272,42 +182,26 @@ static HRESULT String_bold(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS static HRESULT String_charAt(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - const WCHAR *str; - DWORD length; - BSTR ret, val_str = NULL; + StringInstance *strobj; + BSTR str; INT pos = 0; HRESULT hres; TRACE("\n"); - if(!is_class(dispex, JSCLASS_STRING)) { - VARIANT this; - - V_VT(&this) = VT_DISPATCH; - V_DISPATCH(&this) = (IDispatch*)_IDispatchEx_(dispex); - - hres = to_string(dispex->ctx, &this, ei, &val_str); - if(FAILED(hres)) - return hres; - - str = val_str; - length = SysStringLen(val_str); + if(dispex->builtin_info->class != JSCLASS_STRING) { + FIXME("not string this not supported\n"); + return E_NOTIMPL; } - else { - StringInstance *this = (StringInstance*)dispex; - str = this->str; - length = this->length; - } + strobj = (StringInstance*)dispex; if(arg_cnt(dp)) { VARIANT num; hres = to_integer(dispex->ctx, get_arg(dp, 0), ei, &num); - if(FAILED(hres)) { - SysFreeString(val_str); + if(FAILED(hres)) return hres; - } if(V_VT(&num) == VT_I4) { pos = V_I4(&num); @@ -317,22 +211,18 @@ static HRESULT String_charAt(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARA } } - if(!retv) { - SysFreeString(val_str); + if(!retv) return S_OK; - } - if(0 <= pos && pos < length) - ret = SysAllocStringLen(str+pos, 1); + if(0 <= pos && pos < strobj->length) + str = SysAllocStringLen(strobj->str+pos, 1); else - ret = SysAllocStringLen(NULL, 0); - SysFreeString(val_str); - if(!ret) { + str = SysAllocStringLen(NULL, 0); + if(!str) return E_OUTOFMEMORY; - } V_VT(retv) = VT_BSTR; - V_BSTR(retv) = ret; + V_BSTR(retv) = str; return S_OK; } @@ -341,44 +231,30 @@ static HRESULT String_charCodeAt(DispatchEx *dispex, LCID lcid, WORD flags, DISP VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { const WCHAR *str; - BSTR val_str = NULL; DWORD length, idx = 0; HRESULT hres; TRACE("\n"); - if(!is_class(dispex, JSCLASS_STRING)) { - VARIANT this; - - V_VT(&this) = VT_DISPATCH; - V_DISPATCH(&this) = (IDispatch*)_IDispatchEx_(dispex); - - hres = to_string(dispex->ctx, &this, ei, &val_str); - if(FAILED(hres)) - return hres; - - str = val_str; - length = SysStringLen(val_str); - } - else { - StringInstance *this = (StringInstance*)dispex; + if(dispex->builtin_info->class == JSCLASS_STRING) { + StringInstance *string = (StringInstance*)dispex; - str = this->str; - length = this->length; + str = string->str; + length = string->length; + }else { + FIXME("not string this not supported\n"); + return E_NOTIMPL; } if(arg_cnt(dp) > 0) { VARIANT v; hres = to_integer(dispex->ctx, get_arg(dp, 0), ei, &v); - if(FAILED(hres)) { - SysFreeString(val_str); + if(FAILED(hres)) return hres; - } if(V_VT(&v) != VT_I4 || V_I4(&v) < 0 || V_I4(&v) >= length) { if(retv) num_set_nan(&v); - SysFreeString(val_str); return S_OK; } @@ -389,8 +265,6 @@ static HRESULT String_charCodeAt(DispatchEx *dispex, LCID lcid, WORD flags, DISP V_VT(retv) = VT_I4; V_I4(retv) = str[idx]; } - - SysFreeString(val_str); return S_OK; } @@ -462,19 +336,15 @@ static HRESULT String_fixed(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM static HRESULT String_fontcolor(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - static const WCHAR fontW[] = {'F','O','N','T',0}; - static const WCHAR colorW[] = {'C','O','L','O','R',0}; - - return do_attribute_tag_format(dispex, lcid, flags, dp, retv, ei, sp, fontW, colorW); + FIXME("\n"); + return E_NOTIMPL; } static HRESULT String_fontsize(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - static const WCHAR fontW[] = {'F','O','N','T',0}; - static const WCHAR colorW[] = {'S','I','Z','E',0}; - - return do_attribute_tag_format(dispex, lcid, flags, dp, retv, ei, sp, fontW, colorW); + FIXME("\n"); + return E_NOTIMPL; } static HRESULT String_indexOf(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, @@ -482,30 +352,20 @@ static HRESULT String_indexOf(DispatchEx *dispex, LCID lcid, WORD flags, DISPPAR { DWORD length, pos = 0; const WCHAR *str; - BSTR search_str, val_str = NULL; + BSTR search_str; INT ret = -1; HRESULT hres; TRACE("\n"); - if(!is_class(dispex, JSCLASS_STRING)) { - VARIANT this; - - V_VT(&this) = VT_DISPATCH; - V_DISPATCH(&this) = (IDispatch*)_IDispatchEx_(dispex); - - hres = to_string(dispex->ctx, &this, ei, &val_str); - if(FAILED(hres)) - return hres; - - str = val_str; - length = SysStringLen(val_str); - } - else { - StringInstance *this = (StringInstance*)dispex; + if(is_class(dispex, JSCLASS_STRING)) { + StringInstance *string = (StringInstance*)dispex; - str = this->str; - length = this->length; + str = string->str; + length = string->length; + }else { + FIXME("not String this\n"); + return E_NOTIMPL; } if(!arg_cnt(dp)) { @@ -513,15 +373,12 @@ static HRESULT String_indexOf(DispatchEx *dispex, LCID lcid, WORD flags, DISPPAR V_VT(retv) = VT_I4; V_I4(retv) = -1; } - SysFreeString(val_str); return S_OK; } hres = to_string(dispex->ctx, get_arg(dp,0), ei, &search_str); - if(FAILED(hres)) { - SysFreeString(val_str); + if(FAILED(hres)) return hres; - } if(arg_cnt(dp) >= 2) { VARIANT ival; @@ -548,7 +405,6 @@ static HRESULT String_indexOf(DispatchEx *dispex, LCID lcid, WORD flags, DISPPAR } SysFreeString(search_str); - SysFreeString(val_str); if(FAILED(hres)) return hres; @@ -576,33 +432,27 @@ static HRESULT String_lastIndexOf(DispatchEx *dispex, LCID lcid, WORD flags, DIS static HRESULT String_link(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - static const WCHAR fontW[] = {'A',0}; - static const WCHAR colorW[] = {'H','R','E','F',0}; - - return do_attribute_tag_format(dispex, lcid, flags, dp, retv, ei, sp, fontW, colorW); + FIXME("\n"); + return E_NOTIMPL; } /* ECMA-262 3rd Edition 15.5.4.10 */ static HRESULT String_match(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { - const WCHAR *str; + StringInstance *This = (StringInstance*)dispex; match_result_t *match_result; DispatchEx *regexp; DispatchEx *array; VARIANT var, *arg_var; - DWORD length, match_cnt, i; - BSTR val_str = NULL; + DWORD match_cnt, i; HRESULT hres = S_OK; TRACE("\n"); - if(!arg_cnt(dp)) { - if(retv) { - V_VT(retv) = VT_NULL; - } - - return S_OK; + if(arg_cnt(dp) != 1) { + FIXME("unsupported args\n"); + return E_NOTIMPL; } arg_var = get_arg(dp, 0); @@ -628,50 +478,22 @@ static HRESULT String_match(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM } } - if(!is_class(dispex, JSCLASS_STRING)) { - VARIANT this; - - V_VT(&this) = VT_DISPATCH; - V_DISPATCH(&this) = (IDispatch*)_IDispatchEx_(dispex); - - hres = to_string(dispex->ctx, &this, ei, &val_str); - if(FAILED(hres)) { - jsdisp_release(regexp); - return hres; - } - - str = val_str; - length = SysStringLen(val_str); - } - else { - StringInstance *this = (StringInstance*)dispex; - - str = this->str; - length = this->length; - } - - hres = regexp_match(regexp, str, length, FALSE, &match_result, &match_cnt); + hres = regexp_match(regexp, This->str, This->length, FALSE, &match_result, &match_cnt); jsdisp_release(regexp); - if(FAILED(hres)) { - SysFreeString(val_str); + if(FAILED(hres)) return hres; - } if(!match_cnt) { TRACE("no match\n"); if(retv) V_VT(retv) = VT_NULL; - - SysFreeString(val_str); return S_OK; } hres = create_array(dispex->ctx, match_cnt, &array); - if(FAILED(hres)) { - SysFreeString(val_str); + if(FAILED(hres)) return hres; - } V_VT(&var) = VT_BSTR; @@ -688,8 +510,6 @@ static HRESULT String_match(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM break; } - SysFreeString(val_str); - if(SUCCEEDED(hres) && retv) { V_VT(retv) = VT_DISPATCH; V_DISPATCH(retv) = (IDispatch*)_IDispatchEx_(array); @@ -798,11 +618,11 @@ static HRESULT rep_call(DispatchEx *func, const WCHAR *str, match_result_t *matc static HRESULT String_replace(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller) { - const WCHAR *str; DWORD parens_cnt = 0, parens_size=0, rep_len=0, length; - BSTR rep_str = NULL, match_str = NULL, ret_str, val_str = NULL; + BSTR rep_str = NULL, match_str = NULL, ret_str; DispatchEx *rep_func = NULL, *regexp = NULL; match_result_t *parens = NULL, match; + const WCHAR *str; strbuf_t ret = {NULL,0,0}; BOOL gcheck = FALSE; VARIANT *arg_var; @@ -810,36 +630,23 @@ static HRESULT String_replace(DispatchEx *dispex, LCID lcid, WORD flags, DISPPAR TRACE("\n"); - if(!is_class(dispex, JSCLASS_STRING)) { - VARIANT this; - - V_VT(&this) = VT_DISPATCH; - V_DISPATCH(&this) = (IDispatch*)_IDispatchEx_(dispex); - - hres = to_string(dispex->ctx, &this, ei, &val_str); - if(FAILED(hres)) - return hres; - - str = val_str; - length = SysStringLen(val_str); - } - else { - StringInstance *this = (StringInstance*)dispex; - - str = this->str; - length = this->length; + if(is_class(dispex, JSCLASS_STRING)) { + StringInstance *string = (StringInstance*)dispex; + str = string->str; + length = string->length; + }else { + FIXME("not String this\n"); + return E_NOTIMPL; } if(!arg_cnt(dp)) { if(retv) { - if(!val_str) { - val_str = SysAllocStringLen(str, length); - if(!val_str) - return E_OUTOFMEMORY; - } + ret_str = SysAllocString(str); + if(!ret_str) + return E_OUTOFMEMORY; V_VT(retv) = VT_BSTR; - V_BSTR(retv) = val_str; + V_BSTR(retv) = ret_str; } return S_OK; } @@ -859,10 +666,8 @@ static HRESULT String_replace(DispatchEx *dispex, LCID lcid, WORD flags, DISPPAR default: hres = to_string(dispex->ctx, arg_var, ei, &match_str); - if(FAILED(hres)) { - SysFreeString(val_str); + if(FAILED(hres)) return hres; - } } if(arg_cnt(dp) >= 2) { @@ -955,7 +760,6 @@ static HRESULT String_replace(DispatchEx *dispex, LCID lcid, WORD flags, DISPPAR jsdisp_release(rep_func); if(regexp) jsdisp_release(regexp); - SysFreeString(val_str); SysFreeString(rep_str); SysFreeString(match_str); heap_free(parens); @@ -986,7 +790,6 @@ static HRESULT String_slice(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { const WCHAR *str; - BSTR val_str = NULL; DWORD length; INT start=0, end; VARIANT v; @@ -994,32 +797,20 @@ static HRESULT String_slice(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM TRACE("\n"); - if(!is_class(dispex, JSCLASS_STRING)) { - VARIANT this; - - V_VT(&this) = VT_DISPATCH; - V_DISPATCH(&this) = (IDispatch*)_IDispatchEx_(dispex); - - hres = to_string(dispex->ctx, &this, ei, &val_str); - if(FAILED(hres)) - return hres; - - str = val_str; - length = SysStringLen(val_str); - } - else { - StringInstance *this = (StringInstance*)dispex; + if(is_class(dispex, JSCLASS_STRING)) { + StringInstance *string = (StringInstance*)dispex; - str = this->str; - length = this->length; + str = string->str; + length = string->length; + }else { + FIXME("this is not a string class\n"); + return E_NOTIMPL; } if(arg_cnt(dp)) { hres = to_integer(dispex->ctx, dp->rgvarg + dp->cArgs-1, ei, &v); - if(FAILED(hres)) { - SysFreeString(val_str); + if(FAILED(hres)) return hres; - } if(V_VT(&v) == VT_I4) { start = V_I4(&v); @@ -1039,10 +830,8 @@ static HRESULT String_slice(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM if(arg_cnt(dp) >= 2) { hres = to_integer(dispex->ctx, dp->rgvarg + dp->cArgs-2, ei, &v); - if(FAILED(hres)) { - SysFreeString(val_str); + if(FAILED(hres)) return hres; - } if(V_VT(&v) == VT_I4) { end = V_I4(&v); @@ -1065,16 +854,12 @@ static HRESULT String_slice(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM if(retv) { BSTR retstr = SysAllocStringLen(str+start, end-start); - if(!retstr) { - SysFreeString(val_str); + if(!str) return E_OUTOFMEMORY; - } V_VT(retv) = VT_BSTR; V_BSTR(retv) = retstr; } - - SysFreeString(val_str); return S_OK; } @@ -1089,38 +874,26 @@ static HRESULT String_split(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { match_result_t *match_result = NULL; - DWORD length, match_cnt, i, match_len = 0; - const WCHAR *str, *ptr, *ptr2; + DWORD match_cnt, i, match_len = 0; + StringInstance *string; + const WCHAR *ptr, *ptr2; VARIANT *arg, var; DispatchEx *array; - BSTR val_str = NULL, match_str = NULL; + BSTR match_str = NULL; HRESULT hres; TRACE("\n"); - if(arg_cnt(dp) != 1) { - FIXME("unsupported args\n"); + if(!is_class(dispex, JSCLASS_STRING)) { + FIXME("not String this\n"); return E_NOTIMPL; } - if(!is_class(dispex, JSCLASS_STRING)) { - VARIANT this; - - V_VT(&this) = VT_DISPATCH; - V_DISPATCH(&this) = (IDispatch*)_IDispatchEx_(dispex); - - hres = to_string(dispex->ctx, &this, ei, &val_str); - if(FAILED(hres)) - return hres; - - str = val_str; - length = SysStringLen(val_str); - } - else { - StringInstance *this = (StringInstance*)dispex; + string = (StringInstance*)dispex; - str = this->str; - length = this->length; + if(arg_cnt(dp) != 1) { + FIXME("unsupported args\n"); + return E_NOTIMPL; } arg = get_arg(dp, 0); @@ -1131,12 +904,10 @@ static HRESULT String_split(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM regexp = iface_to_jsdisp((IUnknown*)V_DISPATCH(arg)); if(regexp) { if(is_class(regexp, JSCLASS_REGEXP)) { - hres = regexp_match(regexp, str, length, TRUE, &match_result, &match_cnt); + hres = regexp_match(regexp, string->str, string->length, TRUE, &match_result, &match_cnt); jsdisp_release(regexp); - if(FAILED(hres)) { - SysFreeString(val_str); + if(FAILED(hres)) return hres; - } break; } jsdisp_release(regexp); @@ -1144,10 +915,8 @@ static HRESULT String_split(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM } default: hres = to_string(dispex->ctx, arg, ei, &match_str); - if(FAILED(hres)) { - SysFreeString(val_str); + if(FAILED(hres)) return hres; - } match_len = SysStringLen(match_str); if(!match_len) { @@ -1159,7 +928,7 @@ static HRESULT String_split(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM hres = create_array(dispex->ctx, 0, &array); if(SUCCEEDED(hres)) { - ptr = str; + ptr = string->str; for(i=0;; i++) { if(match_result) { if(i == match_cnt) @@ -1197,7 +966,7 @@ static HRESULT String_split(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM } if(SUCCEEDED(hres) && (match_str || match_result)) { - DWORD len = (str+length) - ptr; + DWORD len = (string->str+string->length) - ptr; if(len || match_str) { V_VT(&var) = VT_BSTR; @@ -1213,7 +982,6 @@ static HRESULT String_split(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM } SysFreeString(match_str); - SysFreeString(val_str); heap_free(match_result); if(SUCCEEDED(hres) && retv) { @@ -1245,7 +1013,6 @@ static HRESULT String_substring(DispatchEx *dispex, LCID lcid, WORD flags, DISPP VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { const WCHAR *str; - BSTR val_str = NULL; INT start=0, end; DWORD length; VARIANT v; @@ -1253,32 +1020,20 @@ static HRESULT String_substring(DispatchEx *dispex, LCID lcid, WORD flags, DISPP TRACE("\n"); - if(!is_class(dispex, JSCLASS_STRING)) { - VARIANT this; - - V_VT(&this) = VT_DISPATCH; - V_DISPATCH(&this) = (IDispatch*)_IDispatchEx_(dispex); - - hres = to_string(dispex->ctx, &this, ei, &val_str); - if(FAILED(hres)) - return hres; - - str = val_str; - length = SysStringLen(val_str); - } - else { - StringInstance *this = (StringInstance*)dispex; + if(is_class(dispex, JSCLASS_STRING)) { + StringInstance *string = (StringInstance*)dispex; - str = this->str; - length = this->length; + length = string->length; + str = string->str; + }else { + FIXME("not string this not supported\n"); + return E_NOTIMPL; } if(arg_cnt(dp) >= 1) { hres = to_integer(dispex->ctx, dp->rgvarg + dp->cArgs-1, ei, &v); - if(FAILED(hres)) { - SysFreeString(val_str); + if(FAILED(hres)) return hres; - } if(V_VT(&v) == VT_I4) { start = V_I4(&v); @@ -1293,10 +1048,8 @@ static HRESULT String_substring(DispatchEx *dispex, LCID lcid, WORD flags, DISPP if(arg_cnt(dp) >= 2) { hres = to_integer(dispex->ctx, dp->rgvarg + dp->cArgs-2, ei, &v); - if(FAILED(hres)) { - SysFreeString(val_str); + if(FAILED(hres)) return hres; - } if(V_VT(&v) == VT_I4) { end = V_I4(&v); @@ -1320,12 +1073,9 @@ static HRESULT String_substring(DispatchEx *dispex, LCID lcid, WORD flags, DISPP if(retv) { V_VT(retv) = VT_BSTR; V_BSTR(retv) = SysAllocStringLen(str+start, end-start); - if(!V_BSTR(retv)) { - SysFreeString(val_str); + if(!V_BSTR(retv)) return E_OUTOFMEMORY; - } } - SysFreeString(val_str); return S_OK; } @@ -1346,92 +1096,66 @@ static HRESULT String_sup(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS static HRESULT String_toLowerCase(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { + StringInstance *string; const WCHAR* str; DWORD length; - BSTR val_str = NULL; - HRESULT hres; + BSTR bstr; TRACE("\n"); - if(!is_class(dispex, JSCLASS_STRING)) { - VARIANT this; - - V_VT(&this) = VT_DISPATCH; - V_DISPATCH(&this) = (IDispatch*)_IDispatchEx_(dispex); + if(is_class(dispex, JSCLASS_STRING)) { + string = (StringInstance*)dispex; - hres = to_string(dispex->ctx, &this, ei, &val_str); - if(FAILED(hres)) - return hres; - - str = val_str; - length = SysStringLen(val_str); - } - else { - StringInstance *this = (StringInstance*)dispex; - - str = this->str; - length = this->length; + length = string->length; + str = string->str; + }else { + FIXME("not string this not supported\n"); + return E_NOTIMPL; } if(retv) { - if(!val_str) { - val_str = SysAllocStringLen(str, length); - if(!val_str) - return E_OUTOFMEMORY; - } + bstr = SysAllocStringLen(str, length); + if (!bstr) + return E_OUTOFMEMORY; - strlwrW(val_str); + strlwrW(bstr); V_VT(retv) = VT_BSTR; - V_BSTR(retv) = val_str; + V_BSTR(retv) = bstr; } - else SysFreeString(val_str); return S_OK; } static HRESULT String_toUpperCase(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { + StringInstance *string; const WCHAR* str; DWORD length; - BSTR val_str = NULL; - HRESULT hres; + BSTR bstr; TRACE("\n"); - if(!is_class(dispex, JSCLASS_STRING)) { - VARIANT this; - - V_VT(&this) = VT_DISPATCH; - V_DISPATCH(&this) = (IDispatch*)_IDispatchEx_(dispex); - - hres = to_string(dispex->ctx, &this, ei, &val_str); - if(FAILED(hres)) - return hres; - - str = val_str; - length = SysStringLen(val_str); - } - else { - StringInstance *this = (StringInstance*)dispex; + if(is_class(dispex, JSCLASS_STRING)) { + string = (StringInstance*)dispex; - str = this->str; - length = this->length; + length = string->length; + str = string->str; + }else { + FIXME("not string this not supported\n"); + return E_NOTIMPL; } if(retv) { - if(!val_str) { - val_str = SysAllocStringLen(str, length); - if(!val_str) - return E_OUTOFMEMORY; - } + bstr = SysAllocStringLen(str, length); + if (!bstr) + return E_OUTOFMEMORY; - struprW(val_str); + struprW(bstr); V_VT(retv) = VT_BSTR; - V_BSTR(retv) = val_str; + V_BSTR(retv) = bstr; } - else SysFreeString(val_str); return S_OK; } @@ -1485,8 +1209,6 @@ static HRESULT String_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAM TRACE("\n"); switch(flags) { - case INVOKE_FUNC: - return throw_type_error(dispex->ctx, ei, IDS_NOT_FUNC, NULL); case DISPATCH_PROPERTYGET: { BSTR str = SysAllocString(This->str); if(!str) @@ -1560,37 +1282,6 @@ static const builtin_info_t String_info = { NULL }; -/* ECMA-262 3rd Edition 15.5.3.2 */ -static HRESULT StringConstr_fromCharCode(DispatchEx *dispex, LCID lcid, WORD flags, - DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) -{ - DWORD i, code; - BSTR ret; - HRESULT hres; - - ret = SysAllocStringLen(NULL, arg_cnt(dp)); - if(!ret) - return E_OUTOFMEMORY; - - for(i=0; ictx, get_arg(dp, i), ei, &code); - if(FAILED(hres)) { - SysFreeString(ret); - return hres; - } - - ret[i] = code; - } - - if(retv) { - V_VT(retv) = VT_BSTR; - V_BSTR(retv) = ret; - } - else SysFreeString(ret); - - return S_OK; -} - static HRESULT StringConstr_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp) { @@ -1670,19 +1361,6 @@ static HRESULT string_alloc(script_ctx_t *ctx, BOOL use_constr, StringInstance * return S_OK; } -static const builtin_prop_t StringConstr_props[] = { - {fromCharCodeW, StringConstr_fromCharCode, PROPF_METHOD}, -}; - -static const builtin_info_t StringConstr_info = { - JSCLASS_FUNCTION, - {NULL, Function_value, 0}, - sizeof(StringConstr_props)/sizeof(*StringConstr_props), - StringConstr_props, - NULL, - NULL -}; - HRESULT create_string_constr(script_ctx_t *ctx, DispatchEx **ret) { StringInstance *string; @@ -1692,7 +1370,7 @@ HRESULT create_string_constr(script_ctx_t *ctx, DispatchEx **ret) if(FAILED(hres)) return hres; - hres = create_builtin_function(ctx, StringConstr_value, &StringConstr_info, PROPF_CONSTR, &string->dispex, ret); + hres = create_builtin_function(ctx, StringConstr_value, PROPF_CONSTR, &string->dispex, ret); jsdisp_release(&string->dispex); return hres; diff --git a/dlls/jscript/tests/api.js b/dlls/jscript/tests/api.js index 53b7f924e73..ad4822c580e 100644 --- a/dlls/jscript/tests/api.js +++ b/dlls/jscript/tests/api.js @@ -60,22 +60,6 @@ ok(tmp === "abc", "encodeURI('abc') = " + tmp); tmp = "" + new Object(); ok(tmp === "[object Object]", "'' + new Object() = " + tmp); -(tmp = new Array).f = Object.prototype.toString; -ok(tmp.f() === "[object Array]", "tmp.f() = " + tmp.f()); -(tmp = new Boolean).f = Object.prototype.toString; -ok(tmp.f() === "[object Boolean]", "tmp.f() = " + tmp.f()); -(tmp = new Date).f = Object.prototype.toString; -ok(tmp.f() === "[object Date]", "tmp.f() = " + tmp.f()); -(tmp = function() {}).f = Object.prototype.toString; -ok(tmp.f() === "[object Function]", "tmp.f() = " + tmp.f()); -Math.f = Object.prototype.toString; -ok(Math.f() === "[object Math]", "tmp.f() = " + tmp.f()); -(tmp = new Number).f = Object.prototype.toString; -ok(tmp.f() === "[object Number]", "tmp.f() = " + tmp.f()); -(tmp = new RegExp("")).f = Object.prototype.toString; -ok(tmp.f() === "[object RegExp]", "tmp.f() = " + tmp.f()); -(tmp = new String).f = Object.prototype.toString; -ok(tmp.f() === "[object String]", "tmp.f() = " + tmp.f()); ok("".length === 0, "\"\".length = " + "".length); ok(getVT("".length) == "VT_I4", "\"\".length = " + "".length); @@ -285,19 +269,6 @@ ok(tmp === "TEST", "''.toUpperCase() = " + tmp); tmp = "tEsT".toUpperCase(3); ok(tmp === "TEST", "''.toUpperCase(3) = " + tmp); -tmp = "".anchor(); -ok(tmp === "", "''.anchor() = " + tmp); -tmp = "".anchor(3); -ok(tmp === "", "''.anchor(3) = " + tmp); -tmp = "".anchor("red"); -ok(tmp === "", "''.anchor('red') = " + tmp); -tmp = "test".anchor(); -ok(tmp === "test", "'test'.anchor() = " + tmp); -tmp = "test".anchor(3); -ok(tmp === "test", "'test'.anchor(3) = " + tmp); -tmp = "test".anchor("green"); -ok(tmp === "test", "'test'.anchor('green') = " + tmp); - tmp = "".big(); ok(tmp === "", "''.big() = " + tmp); tmp = "".big(3); @@ -334,35 +305,6 @@ ok(tmp === "test", "'test'.fixed() = " + tmp); tmp = "test".fixed(3); ok(tmp === "test", "'test'.fixed(3) = " + tmp); -tmp = "".fontcolor(); -ok(tmp === "", "''.fontcolor() = " + tmp); -tmp = "".fontcolor(3); -ok(tmp === "", "''.fontcolor(3) = " + tmp); -tmp = "".fontcolor("red"); -ok(tmp === "", "''.fontcolor('red') = " + tmp); -tmp = "test".fontcolor(); -ok(tmp === "test", "'test'.fontcolor() = " + tmp); -tmp = "test".fontcolor(3); -ok(tmp === "test", "'test'.fontcolor(3) = " + tmp); -tmp = "test".fontcolor("green"); -ok(tmp === "test", "'test'.fontcolor('green') = " + tmp); - -tmp = "".fontsize(); -ok(tmp === "", "''.fontsize() = " + tmp); -tmp = "".fontsize(3); -ok(tmp === "", "''.fontsize(3) = " + tmp); -tmp = "".fontsize("red"); -ok(tmp === "", "''.fontsize('red') = " + tmp); -tmp = "test".fontsize(); -ok(tmp === "test", "'test'.fontsize() = " + tmp); -tmp = "test".fontsize(3); -ok(tmp === "test", "'test'.fontsize(3) = " + tmp); -tmp = "test".fontsize("green"); -ok(tmp === "test", "'test'.fontsize('green') = " + tmp); - -tmp = ("".fontcolor()).fontsize(); -ok(tmp === "", "(''.fontcolor()).fontsize() = " + tmp); - tmp = "".italics(); ok(tmp === "", "''.italics() = " + tmp); tmp = "".italics(3); @@ -372,19 +314,6 @@ ok(tmp === "test", "'test'.italics() = " + tmp); tmp = "test".italics(3); ok(tmp === "test", "'test'.italics(3) = " + tmp); -tmp = "".link(); -ok(tmp === "", "''.link() = " + tmp); -tmp = "".link(3); -ok(tmp === "", "''.link(3) = " + tmp); -tmp = "".link("red"); -ok(tmp === "", "''.link('red') = " + tmp); -tmp = "test".link(); -ok(tmp === "test", "'test'.link() = " + tmp); -tmp = "test".link(3); -ok(tmp === "test", "'test'.link(3) = " + tmp); -tmp = "test".link("green"); -ok(tmp === "test", "'test'.link('green') = " + tmp); - tmp = "".small(); ok(tmp === "", "''.small() = " + tmp); tmp = "".small(3); @@ -421,13 +350,6 @@ ok(tmp === "test", "'test'.sup() = " + tmp); tmp = "test".sup(3); ok(tmp === "test", "'test'.sup(3) = " + tmp); -ok(String.fromCharCode() === "", "String.fromCharCode() = " + String.fromCharCode()); -ok(String.fromCharCode(65,"66",67) === "ABC", "String.fromCharCode(65,'66',67) = " + String.fromCharCode(65,"66",67)); -ok(String.fromCharCode(1024*64+65, -1024*64+65) === "AA", - "String.fromCharCode(1024*64+65, -1024*64+65) = " + String.fromCharCode(1024*64+65, -1024*64+65)); -ok(String.fromCharCode(65, NaN, undefined).length === 3, - "String.fromCharCode(65, NaN, undefined).length = " + String.fromCharCode(65, NaN, undefined).length); - var arr = new Array(); ok(typeof(arr) === "object", "arr () is not object"); ok((arr.length === 0), "arr.length is not 0"); @@ -517,19 +439,6 @@ ok(arr.sort() === arr, "arr.sort() !== arr"); for(var i=0; i < arr.length; i++) ok(arr[i] === tmp[i], "arr[" + i + "] = " + arr[i] + " expected " + tmp[i]); -arr = ["1", "2", "3"]; -arr.length = 1; -ok(arr.length === 1, "arr.length = " + arr.length); -arr.length = 3; -ok(arr.length === 3, "arr.length = " + arr.length); -ok(arr.toString() === "1,,", "arr.toString() = " + arr.toString()); - -arr = Array("a","b","c"); -ok(arr.toString() === "a,b,c", "arr.toString() = " + arr.toString()); - -ok(arr.valueOf === Object.prototype.valueOf, "arr.valueOf !== Object.prototype.valueOf"); -ok(arr === arr.valueOf(), "arr !== arr.valueOf"); - var num = new Number(6); arr = [0,1,2]; tmp = arr.concat(3, [4,5], num); @@ -547,23 +456,6 @@ tmp = arr.concat([2]); ok(tmp.length === 3, "tmp.length = " + tmp.length); ok(tmp[1] === undefined, "tmp[1] = " + tmp[1]); -arr = [1,false,'a',null,undefined,'a']; -ok(arr.slice(0,6).toString() === "1,false,a,,,a", "arr.slice(0,6).toString() = " + arr.slice(0,6)); -ok(arr.slice(0,6).length === 6, "arr.slice(0,6).length = " + arr.slice(0,6).length); -ok(arr.slice().toString() === "1,false,a,,,a", "arr.slice().toString() = " + arr.slice()); -ok(arr.slice("abc").toString() === "1,false,a,,,a", "arr.slice(\"abc\").toString() = " + arr.slice("abc")); -ok(arr.slice(3,8).toString() === ",,a", "arr.slice(3,8).toString() = " + arr.slice(3,8)); -ok(arr.slice(3,8).length === 3, "arr.slice(3,8).length = " + arr.slice(3,8).length); -ok(arr.slice(1).toString() === "false,a,,,a", "arr.slice(1).toString() = " + arr.slice(1)); -ok(arr.slice(-2).toString() === ",a", "arr.slice(-2).toString() = " + arr.slice(-2)); -ok(arr.slice(3,1).toString() === "", "arr.slice(3,1).toString() = " + arr.slice(3,1)); -tmp = arr.slice(0,6); -for(var i=0; i < arr.length; i++) - ok(arr[i] === tmp[i], "arr[" + i + "] = " + arr[i] + " expected " + tmp[i]); -arr[12] = 2; -ok(arr.slice(5).toString() === "a,,,,,,,2", "arr.slice(5).toString() = " + arr.slice(5).toString()); -ok(arr.slice(5).length === 8, "arr.slice(5).length = " + arr.slice(5).length); - var num = new Number(2); ok(num.toString() === "2", "num(2).toString !== 2"); var num = new Number(); @@ -582,51 +474,6 @@ ok(tmp === 0, "(new Number()).valueOf = " + tmp); tmp = Number.prototype.valueOf(); ok(tmp === 0, "Number.prototype.valueOf = " + tmp); -function equals(val, base) { - var i; - var num = 0; - var str = val.toString(base); - - for(i=0; ival-val/1000 && num= 4"); - tmp++; -} while(tmp < 4) -ok(tmp === 4, "tmp !== 4") - -tmp = 0; while(tmp < 4) { tmp++; if(tmp === 2) { @@ -882,18 +875,4 @@ function testEmbededFunctions() { testEmbededFunctions(); -date = new Date(); -date.toString = function() { return "toString"; } -ok(""+date === "toString", "''+date = " + date); -date.toString = function() { return this; } -ok(""+date === ""+date.valueOf(), "''+date = " + date); - -str = new String("test"); -str.valueOf = function() { return "valueOf"; } -ok(""+str === "valueOf", "''+str = " + str); -str.valueOf = function() { return new Date(); } -ok(""+str === "test", "''+str = " + str); - -ok((function (){return 1;})() === 1, "(function (){return 1;})() = " + (function (){return 1;})()); - reportSuccess(); diff --git a/dlls/jscript/tests/regexp.js b/dlls/jscript/tests/regexp.js index 3e4db68c4af..68091019f2b 100644 --- a/dlls/jscript/tests/regexp.js +++ b/dlls/jscript/tests/regexp.js @@ -31,7 +31,7 @@ ok(m["0"] === "ab", "m[0] is not \"ab\""); m = "abcabc".match(/ab/g); ok(typeof(m) === "object", "typeof m is not object"); -ok(m.length === 2, "m.length is not 2"); +ok(m.length === 2, "m.length is not 1"); ok(m["0"] === "ab", "m[0] is not \"ab\""); ok(m["1"] === "ab", "m[1] is not \"ab\""); @@ -41,7 +41,7 @@ ok(m === null, "m is not null"); m = "abcabc".match(/Ab/gi); ok(typeof(m) === "object", "typeof m is not object"); -ok(m.length === 2, "m.length is not 2"); +ok(m.length === 2, "m.length is not 1"); ok(m["0"] === "ab", "m[0] is not \"ab\""); ok(m["1"] === "ab", "m[1] is not \"ab\""); @@ -64,30 +64,22 @@ ok(m["0"] === "ab", "m[0] is not \"ab\""); m = "abcabc".match(new RegExp("ab","g")); ok(typeof(m) === "object", "typeof m is not object"); -ok(m.length === 2, "m.length is not 2"); +ok(m.length === 2, "m.length is not 1"); ok(m["0"] === "ab", "m[0] is not \"ab\""); ok(m["1"] === "ab", "m[1] is not \"ab\""); m = "abcabc".match(new RegExp(/ab/g)); ok(typeof(m) === "object", "typeof m is not object"); -ok(m.length === 2, "m.length is not 2"); +ok(m.length === 2, "m.length is not 1"); ok(m["0"] === "ab", "m[0] is not \"ab\""); ok(m["1"] === "ab", "m[1] is not \"ab\""); m = "abcabc".match(new RegExp("ab","g", "test")); ok(typeof(m) === "object", "typeof m is not object"); -ok(m.length === 2, "m.length is not 2"); +ok(m.length === 2, "m.length is not 1"); ok(m["0"] === "ab", "m[0] is not \"ab\""); ok(m["1"] === "ab", "m[1] is not \"ab\""); -m = "abcabcg".match("ab", "g"); -ok(typeof(m) === "object", "typeof m is not object"); -ok(m.length === 1, "m.length is not 1"); -ok(m["0"] === "ab", "m[0] is not \"ab\""); - -m = "abcabc".match(); -ok(m === null, "m is not null"); - r = "- [test] -".replace(/\[([^\[]+)\]/g, "success"); ok(r === "- success -", "r = " + r + " expected '- success -'"); diff --git a/dlls/kernel32/Makefile.in b/dlls/kernel32/Makefile.in index 79312246084..d299df9b8fa 100644 --- a/dlls/kernel32/Makefile.in +++ b/dlls/kernel32/Makefile.in @@ -76,9 +76,7 @@ C_SRCS16 = \ registry16.c \ toolhelp16.c -RC_SRCS = \ - locale_rc.rc \ - version.rc +RC_SRCS = kernel.rc RC_SRCS16 = \ version16.rc @@ -88,7 +86,6 @@ MC_SRCS = \ nls/winerr_enu.mc \ nls/winerr_fra.mc \ nls/winerr_kor.mc \ - nls/winerr_lth.mc \ nls/winerr_nld.mc \ nls/winerr_nor.mc \ nls/winerr_plk.mc @@ -98,6 +95,8 @@ EXTRASUBDIRS = nls @MAKE_DLL_RULES@ +kernel.res: $(MC_SRCS:.mc=.mc.rc) + relay16asm.o: $(WINEBUILD) $(WINEBUILD) $(WINEBUILDFLAGS) -o $@ --relay16 diff --git a/dlls/kernel32/except.c b/dlls/kernel32/except.c index a943d3263ce..9db9ca81a2b 100644 --- a/dlls/kernel32/except.c +++ b/dlls/kernel32/except.c @@ -265,16 +265,15 @@ static BOOL start_debugger(PEXCEPTION_POINTERS epointers, HANDLE hEvent) if (format) { - size_t format_size = strlen(format) + 2*20; - cmdline = HeapAlloc(GetProcessHeap(), 0, format_size); - snprintf(cmdline, format_size, format, (long)GetCurrentProcessId(), (long)HandleToLong(hEvent)); + cmdline = HeapAlloc(GetProcessHeap(), 0, strlen(format) + 2*20); + sprintf(cmdline, format, GetCurrentProcessId(), hEvent); HeapFree(GetProcessHeap(), 0, format); } else { cmdline = HeapAlloc(GetProcessHeap(), 0, 80); - snprintf(cmdline, 80, "winedbg --auto %ld %ld", /* as in tools/wine.inf */ - (long)GetCurrentProcessId(), (long)HandleToLong(hEvent)); + sprintf(cmdline, "winedbg --auto %d %ld", + GetCurrentProcessId(), (ULONG_PTR)hEvent); } if (!bAuto) diff --git a/dlls/kernel32/kernel.rc b/dlls/kernel32/kernel.rc new file mode 100644 index 00000000000..30d1dcaa8cd --- /dev/null +++ b/dlls/kernel32/kernel.rc @@ -0,0 +1,29 @@ +/* + * Copyright 2000 Dave Pickles + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "locale_rc.rc" + +#include "nls/winerr_deu.mc.rc" +#include "nls/winerr_enu.mc.rc" +#include "nls/winerr_fra.mc.rc" +#include "nls/winerr_kor.mc.rc" +#include "nls/winerr_nld.mc.rc" +#include "nls/winerr_nor.mc.rc" +#include "nls/winerr_plk.mc.rc" + +#include "version.rc" diff --git a/dlls/kernel32/kernel32.spec b/dlls/kernel32/kernel32.spec index 2fd1b10c382..5182e71fc1a 100644 --- a/dlls/kernel32/kernel32.spec +++ b/dlls/kernel32/kernel32.spec @@ -1133,7 +1133,7 @@ @ stdcall VirtualQuery(ptr ptr long) @ stdcall VirtualQueryEx(long ptr ptr long) @ stdcall VirtualUnlock(ptr long) -@ stdcall WTSGetActiveConsoleSessionId() +# @ stub WTSGetActiveConsoleSessionId @ stdcall WaitCommEvent(long ptr ptr) @ stdcall WaitForDebugEvent(ptr long) @ stdcall WaitForMultipleObjects(long ptr long long) @@ -1144,7 +1144,6 @@ @ stdcall WaitNamedPipeW (wstr long) @ stdcall WideCharToMultiByte(long long wstr long ptr long ptr ptr) @ stdcall WinExec(str long) -@ stdcall Wow64EnableWow64FsRedirection(long) @ stdcall Wow64DisableWow64FsRedirection(ptr) @ stdcall Wow64RevertWow64FsRedirection(ptr) @ stdcall WriteConsoleA(long ptr long ptr ptr) diff --git a/dlls/kernel32/kernel_private.h b/dlls/kernel32/kernel_private.h index 39a5e23c217..b23aedfc13f 100644 --- a/dlls/kernel32/kernel_private.h +++ b/dlls/kernel32/kernel_private.h @@ -71,7 +71,6 @@ extern HANDLE dos_handles[DOS_TABLE_SIZE]; extern const WCHAR *DIR_Windows; extern const WCHAR *DIR_System; -extern const WCHAR *DIR_SysWow64; extern VOID SYSLEVEL_CheckNotLevel( INT level ); diff --git a/dlls/kernel32/ne_module.c b/dlls/kernel32/ne_module.c index 87a1a86737b..4b45e7bb654 100644 --- a/dlls/kernel32/ne_module.c +++ b/dlls/kernel32/ne_module.c @@ -119,15 +119,6 @@ static inline void patch_code_segment( NE_MODULE *pModule ) /*********************************************************************** - * contains_path - */ -static inline int contains_path( LPCSTR name ) -{ - return ((*name && (name[1] == ':')) || strchr(name, '/') || strchr(name, '\\')); -} - - -/*********************************************************************** * NE_strcasecmp * * locale-independent case conversion for module lookups @@ -1683,8 +1674,6 @@ HINSTANCE16 WINAPI WinExec16( LPCSTR lpCmdLine, UINT16 nCmdShow ) int arglen; HINSTANCE16 ret; char buffer[MAX_PATH]; - LOADPARAMS16 params; - WORD showCmd[2]; if (*lpCmdLine == '"') /* has to be only one and only at beginning ! */ { @@ -1733,29 +1722,23 @@ HINSTANCE16 WINAPI WinExec16( LPCSTR lpCmdLine, UINT16 nCmdShow ) TRACE("name: '%s', cmdline: '%.*s'\n", name, cmdline[0], &cmdline[1]); - showCmd[0] = 2; - showCmd[1] = nCmdShow; - - params.hEnvironment = 0; - params.cmdLine = MapLS( cmdline ); - params.showCmd = MapLS( showCmd ); - params.reserved = 0; - if (SearchPathA( NULL, name, ".exe", sizeof(buffer), buffer, NULL )) { + LOADPARAMS16 params; + WORD showCmd[2]; + showCmd[0] = 2; + showCmd[1] = nCmdShow; + + params.hEnvironment = 0; + params.cmdLine = MapLS( cmdline ); + params.showCmd = MapLS( showCmd ); + params.reserved = 0; + ret = LoadModule16( buffer, ¶ms ); + UnMapLS( params.cmdLine ); + UnMapLS( params.showCmd ); } - else if (!contains_path( name )) /* try 16-bit builtin */ - { - lstrcpynA( buffer, name, sizeof(buffer) ); - if (strlen( buffer ) < sizeof(buffer) - 4 && !strchr( buffer, '.' )) strcat( buffer, ".exe" ); - ret = LoadModule16( buffer, ¶ms ); - if (ret == ERROR_FILE_NOT_FOUND) ret = 21; /* it might be a 32-bit builtin too */ - } - else ret = ERROR_FILE_NOT_FOUND; - - UnMapLS( params.cmdLine ); - UnMapLS( params.showCmd ); + else ret = GetLastError(); HeapFree( GetProcessHeap(), 0, cmdline ); if (name != lpCmdLine) HeapFree( GetProcessHeap(), 0, name ); diff --git a/dlls/kernel32/nls/winerr_deu.mc b/dlls/kernel32/nls/winerr_deu.mc index e0d70d5c9aa..6c240aad842 100644 --- a/dlls/kernel32/nls/winerr_deu.mc +++ b/dlls/kernel32/nls/winerr_deu.mc @@ -17,7 +17,6 @@ ; LanguageNames=(DEU=0x0007:winerr) -CodePages=(DEU=65001:0) MessageId=0 SymbolicName=ERROR_SUCCESS @@ -27,7 +26,7 @@ Erfolg MessageId=1 SymbolicName=ERROR_INVALID_FUNCTION Language=DEU -Ungültige Funktion +Ungültige Funktion . MessageId=2 SymbolicName=ERROR_FILE_NOT_FOUND @@ -52,42 +51,42 @@ Zugriff verweigert MessageId=6 SymbolicName=ERROR_INVALID_HANDLE Language=DEU -Ungültiges Handle +Ungültiges Handle . MessageId=7 SymbolicName=ERROR_ARENA_TRASHED Language=DEU -Speicherstrukturen beschädigt +Speicherstrukturen beschädigt . MessageId=8 SymbolicName=ERROR_NOT_ENOUGH_MEMORY Language=DEU -Nicht genügend Arbeitsspeicher +Nicht genügend Arbeitsspeicher . MessageId=9 SymbolicName=ERROR_INVALID_BLOCK Language=DEU -Ungültiger Block +Ungültiger Block . MessageId=10 SymbolicName=ERROR_BAD_ENVIRONMENT Language=DEU -Ungültige Umgebung +Ungültige Umgebung . MessageId=11 SymbolicName=ERROR_BAD_FORMAT Language=DEU -Ungültiges Format +Ungültiges Format . MessageId=12 SymbolicName=ERROR_INVALID_ACCESS Language=DEU -Ungültiger Zugriff +Ungültiger Zugriff . MessageId=13 SymbolicName=ERROR_INVALID_DATA Language=DEU -Ungültige Daten +Ungültige Daten . MessageId=14 SymbolicName=ERROR_OUTOFMEMORY @@ -97,17 +96,17 @@ Kein Arbeitsspeicher mehr MessageId=15 SymbolicName=ERROR_INVALID_DRIVE Language=DEU -Ungültiges Laufwerk +Ungültiges Laufwerk . MessageId=16 SymbolicName=ERROR_CURRENT_DIRECTORY Language=DEU -Kann Arbeitsverzeichnis nicht löschen +Kann Arbeitsverzeichnis nicht löschen . MessageId=17 SymbolicName=ERROR_NOT_SAME_DEVICE Language=DEU -Nicht das gleiche Gerät +Nicht das gleiche Gerät . MessageId=18 SymbolicName=ERROR_NO_MORE_FILES @@ -117,12 +116,12 @@ Keine weiteren Dateien MessageId=19 SymbolicName=ERROR_WRITE_PROTECT Language=DEU -Schreibgeschützt +Schreibgeschützt . MessageId=20 SymbolicName=ERROR_BAD_UNIT Language=DEU -Ungültige Einheit +Ungültige Einheit . MessageId=21 SymbolicName=ERROR_NOT_READY @@ -142,7 +141,7 @@ CRC-Fehler MessageId=24 SymbolicName=ERROR_BAD_LENGTH Language=DEU -Fehlerhafte Länge +Fehlerhafte Länge . MessageId=25 SymbolicName=ERROR_SEEK @@ -152,7 +151,7 @@ Such-Fehler MessageId=26 SymbolicName=ERROR_NOT_DOS_DISK Language=DEU -Kein DOS-Datenträger +Kein DOS-Datenträger . MessageId=27 SymbolicName=ERROR_SECTOR_NOT_FOUND @@ -192,7 +191,7 @@ Lock-Verletzung MessageId=34 SymbolicName=ERROR_WRONG_DISK Language=DEU -Falscher Datenträger +Falscher Datenträger . MessageId=36 SymbolicName=ERROR_SHARING_BUFFER_EXCEEDED @@ -207,12 +206,12 @@ Ende der Datei MessageId=39 SymbolicName=ERROR_HANDLE_DISK_FULL Language=DEU -Datenträger voll +Datenträger voll . MessageId=50 SymbolicName=ERROR_NOT_SUPPORTED Language=DEU -Anfrage nicht unterstützt +Anfrage nicht unterstützt . MessageId=51 SymbolicName=ERROR_REM_NOT_LIST @@ -232,12 +231,12 @@ Fehlerhafter Netzpfad MessageId=54 SymbolicName=ERROR_NETWORK_BUSY Language=DEU -Netzwerk beschäftigt +Netzwerk beschäftigt . MessageId=55 SymbolicName=ERROR_DEV_NOT_EXIST Language=DEU -Gerät existiert nicht +Gerät existiert nicht . MessageId=56 SymbolicName=ERROR_TOO_MANY_CMDS @@ -282,7 +281,7 @@ Druck abgebrochen MessageId=64 SymbolicName=ERROR_NETNAME_DELETED Language=DEU -Netzwerkname gelöscht +Netzwerkname gelöscht . MessageId=65 SymbolicName=ERROR_NETWORK_ACCESS_DENIED @@ -292,7 +291,7 @@ Netzwerkzugriff verweigert MessageId=66 SymbolicName=ERROR_BAD_DEV_TYPE Language=DEU -Fehlerhafter Gerätetyp +Fehlerhafter Gerätetyp . MessageId=67 SymbolicName=ERROR_BAD_NET_NAME @@ -352,12 +351,12 @@ Bereits zugewiesen MessageId=86 SymbolicName=ERROR_INVALID_PASSWORD Language=DEU -Ungültiges Passwort +Ungültiges Passwort . MessageId=87 SymbolicName=ERROR_INVALID_PARAMETER Language=DEU -Ungültiger Parameter +Ungültiger Parameter . MessageId=88 SymbolicName=ERROR_NET_WRITE_FAULT @@ -392,7 +391,7 @@ Zu viele Semaphoren-Anfragen MessageId=104 SymbolicName=ERROR_INVALID_AT_INTERRUPT_TIME Language=DEU -Ungültig zu Interrupt-Zeitpunkt +Ungültig zu Interrupt-Zeitpunkt . MessageId=105 SymbolicName=ERROR_SEM_OWNER_DIED @@ -407,7 +406,7 @@ Semaphoren-Benutzer-Limit MessageId=107 SymbolicName=ERROR_DISK_CHANGE Language=DEU -Datenträger in Laufwerk %1 einlegen +Datenträger in Laufwerk %1 einlegen . MessageId=108 SymbolicName=ERROR_DRIVE_LOCKED @@ -422,17 +421,17 @@ Gebrochene Pipe MessageId=110 SymbolicName=ERROR_OPEN_FAILED Language=DEU -Öffnen fehlgeschlagen +Öffnen fehlgeschlagen . MessageId=111 SymbolicName=ERROR_BUFFER_OVERFLOW Language=DEU -Pufferüberlauf +Pufferüberlauf . MessageId=112 SymbolicName=ERROR_DISK_FULL Language=DEU -Datenträger voll +Datenträger voll . MessageId=113 SymbolicName=ERROR_NO_MORE_SEARCH_HANDLES @@ -442,17 +441,17 @@ Keine weiteren Such-Handles MessageId=114 SymbolicName=ERROR_INVALID_TARGET_HANDLE Language=DEU -Ungültiges Ziel-Handle +Ungültiges Ziel-Handle . MessageId=117 SymbolicName=ERROR_INVALID_CATEGORY Language=DEU -Ungültiges IOCTL +Ungültiges IOCTL . MessageId=118 SymbolicName=ERROR_INVALID_VERIFY_SWITCH Language=DEU -Ungültiger Überprüfungsschalter +Ungültiger Überprüfungsschalter . MessageId=119 SymbolicName=ERROR_BAD_DRIVER_LEVEL @@ -477,12 +476,12 @@ Nicht ausreichender Puffer MessageId=123 SymbolicName=ERROR_INVALID_NAME Language=DEU -Ungültiger Name +Ungültiger Name . MessageId=124 SymbolicName=ERROR_INVALID_LEVEL Language=DEU -Ungültige Ebene +Ungültige Ebene . MessageId=125 SymbolicName=ERROR_NO_VOLUME_LABEL @@ -512,7 +511,7 @@ Kind-Prozess ist nicht abgeschlossen MessageId=130 SymbolicName=ERROR_DIRECT_ACCESS_HANDLE Language=DEU -Ungültige Benutzung eines Handles für Direktzugriff +Ungültige Benutzung eines Handles für Direktzugriff . MessageId=131 SymbolicName=ERROR_NEGATIVE_SEEK @@ -572,7 +571,7 @@ Versuch auf ein geJOINtes Laufwerk zu SUBSTen MessageId=142 SymbolicName=ERROR_BUSY_DRIVE Language=DEU -Laufwerk ist beschäftigt +Laufwerk ist beschäftigt . MessageId=143 SymbolicName=ERROR_SAME_DRIVE @@ -602,7 +601,7 @@ Pfad wird als JOIN benutzt MessageId=148 SymbolicName=ERROR_PATH_BUSY Language=DEU -Pfad ist beschäftigt +Pfad ist beschäftigt . MessageId=149 SymbolicName=ERROR_IS_SUBST_TARGET @@ -617,17 +616,17 @@ System-Trace nicht spezifiziert oder erlaubt MessageId=151 SymbolicName=ERROR_INVALID_EVENT_COUNT Language=DEU -Event-Anzahl für DosMuxSemWait nicht korrekt +Event-Anzahl für DosMuxSemWait nicht korrekt . MessageId=152 SymbolicName=ERROR_TOO_MANY_MUXWAITERS Language=DEU -Zu viele Warter für DosMuxSemWait +Zu viele Warter für DosMuxSemWait . MessageId=153 SymbolicName=ERROR_INVALID_LIST_FORMAT Language=DEU -DosSemMuxWait-Liste ungültig +DosSemMuxWait-Liste ungültig . MessageId=154 SymbolicName=ERROR_LABEL_TOO_LONG @@ -662,17 +661,17 @@ Fehlerhafte Thread-ID-Adresse MessageId=160 SymbolicName=ERROR_BAD_ARGUMENTS Language=DEU -Fehlerhafte Argumente für DosExecPgm +Fehlerhafte Argumente für DosExecPgm . MessageId=161 SymbolicName=ERROR_BAD_PATHNAME Language=DEU -Pfad is ungültig +Pfad is ungültig . MessageId=162 SymbolicName=ERROR_SIGNAL_PENDING Language=DEU -Signal anhängig +Signal anhängig . MessageId=164 SymbolicName=ERROR_MAX_THRDS_REACHED @@ -697,17 +696,17 @@ Abbruch-Verletzung MessageId=174 SymbolicName=ERROR_ATOMIC_LOCKS_NOT_SUPPORTED Language=DEU -Atomare Sperren nicht unterstützt +Atomare Sperren nicht unterstützt . MessageId=180 SymbolicName=ERROR_INVALID_SEGMENT_NUMBER Language=DEU -Ungültige Segmentnummer +Ungültige Segmentnummer . MessageId=182 SymbolicName=ERROR_INVALID_ORDINAL Language=DEU -Ungültiges Ordinal für %1 +Ungültiges Ordinal für %1 . MessageId=183 SymbolicName=ERROR_ALREADY_EXISTS @@ -717,7 +716,7 @@ Datei existiert bereits MessageId=186 SymbolicName=ERROR_INVALID_FLAG_NUMBER Language=DEU -Ungültige Flag-Nummer +Ungültige Flag-Nummer . MessageId=187 SymbolicName=ERROR_SEM_NOT_FOUND @@ -727,47 +726,47 @@ Semaphoren-Name nicht gefunden MessageId=188 SymbolicName=ERROR_INVALID_STARTING_CODESEG Language=DEU -Ungültiges anfängliches Code-Segment für %1 +Ungültiges anfängliches Code-Segment für %1 . MessageId=189 SymbolicName=ERROR_INVALID_STACKSEG Language=DEU -Ungültiges anfängliches Stack-Segment für %1 +Ungültiges anfängliches Stack-Segment für %1 . MessageId=190 SymbolicName=ERROR_INVALID_MODULETYPE Language=DEU -Ungültiger Modul-Typ für %1 +Ungültiger Modul-Typ für %1 . MessageId=191 SymbolicName=ERROR_INVALID_EXE_SIGNATURE Language=DEU -Ungültige EXE-Signatur für %1 +Ungültige EXE-Signatur für %1 . MessageId=192 SymbolicName=ERROR_EXE_MARKED_INVALID Language=DEU -EXE %1 ist als ungültig markiert +EXE %1 ist als ungültig markiert . MessageId=193 SymbolicName=ERROR_BAD_EXE_FORMAT Language=DEU -Fehlerhaftes EXE-Format für %1 +Fehlerhaftes EXE-Format für %1 . MessageId=194 SymbolicName=ERROR_ITERATED_DATA_EXCEEDS_64k Language=DEU -Iterierte Daten übersteigen 64k in %1 +Iterierte Daten übersteigen 64k in %1 . MessageId=195 SymbolicName=ERROR_INVALID_MINALLOCSIZE Language=DEU -Ungültige MinAllocSize in %1 +Ungültige MinAllocSize in %1 . MessageId=196 SymbolicName=ERROR_DYNLINK_FROM_INVALID_RING Language=DEU -Dynlink von ungültigem Ring +Dynlink von ungültigem Ring . MessageId=197 SymbolicName=ERROR_IOPL_NOT_ENABLED @@ -777,12 +776,12 @@ IOPL nicht aktiviert MessageId=198 SymbolicName=ERROR_INVALID_SEGDPL Language=DEU -Ungültiges SEGDPL in %1 +Ungültiges SEGDPL in %1 . MessageId=199 SymbolicName=ERROR_AUTODATASEG_EXCEEDS_64k Language=DEU -Automatisches Daten-Segment übertrifft 64k +Automatisches Daten-Segment übertrifft 64k . MessageId=200 SymbolicName=ERROR_RING2SEG_MUST_BE_MOVABLE @@ -792,7 +791,7 @@ Ring-2-Segment muss bewegbar sein MessageId=201 SymbolicName=ERROR_RELOC_CHAIN_XEEDS_SEGLIM Language=DEU -Relokationskette übertrifft Segmentlimit in %1 +Relokationskette übertrifft Segmentlimit in %1 . MessageId=202 SymbolicName=ERROR_INFLOOP_IN_RELOC_CHAIN @@ -827,7 +826,7 @@ Fehler in Benutzung von Dateinamen-Wildcards MessageId=209 SymbolicName=ERROR_INVALID_SIGNAL_NUMBER Language=DEU -Ungültige Signalnummer +Ungültige Signalnummer . MessageId=210 SymbolicName=ERROR_THREAD_1_INACTIVE @@ -852,7 +851,7 @@ Schachteln von LoadModule-Aufrufen nicht erlaubt MessageId=216 SymbolicName=ERROR_EXE_MACHINE_TYPE_MISMATCH Language=DEU -Maschinen-Typ nicht übereinstimmend +Maschinen-Typ nicht übereinstimmend . MessageId=230 SymbolicName=ERROR_BAD_PIPE @@ -862,7 +861,7 @@ Fehlerhafte Pipe MessageId=231 SymbolicName=ERROR_PIPE_BUSY Language=DEU -Pipe beschäftigt +Pipe beschäftigt . MessageId=232 SymbolicName=ERROR_NO_DATA @@ -877,7 +876,7 @@ Pipe nicht verbunden MessageId=234 SymbolicName=ERROR_MORE_DATA Language=DEU -Mehr Daten verfügbar +Mehr Daten verfügbar . MessageId=240 SymbolicName=ERROR_VC_DISCONNECTED @@ -887,7 +886,7 @@ Sitzung abgebrochen MessageId=254 SymbolicName=ERROR_INVALID_EA_NAME Language=DEU -Ungültiger Name für erweitertes Attribut +Ungültiger Name für erweitertes Attribut . MessageId=255 SymbolicName=ERROR_EA_LIST_INCONSISTENT @@ -907,7 +906,7 @@ Kann Copy-API nicht benutzen MessageId=267 SymbolicName=ERROR_DIRECTORY Language=DEU -Verzeichnisname ist ungültig +Verzeichnisname ist ungültig . MessageId=275 SymbolicName=ERROR_EAS_DIDNT_FIT @@ -917,7 +916,7 @@ Erweiterte Attribute passten nicht MessageId=276 SymbolicName=ERROR_EA_FILE_CORRUPT Language=DEU -Datei für erweiterte Attribute beschädigt +Datei für erweiterte Attribute beschädigt . MessageId=277 SymbolicName=ERROR_EA_TABLE_FULL @@ -927,12 +926,12 @@ Tabelle der erweiterten Attribute voll MessageId=278 SymbolicName=ERROR_INVALID_EA_HANDLE Language=DEU -Ungültiges Handle für erweitertes Attribut +Ungültiges Handle für erweitertes Attribut . MessageId=282 SymbolicName=ERROR_EAS_NOT_SUPPORTED Language=DEU -Erweiterte Attribute nicht unterstützt +Erweiterte Attribute nicht unterstützt . MessageId=288 SymbolicName=ERROR_NOT_OWNER @@ -967,12 +966,12 @@ Meldung 0x%1 nicht in Datei %2 gefunden MessageId=487 SymbolicName=ERROR_INVALID_ADDRESS Language=DEU -Ungültige Adresse +Ungültige Adresse . MessageId=534 SymbolicName=ERROR_ARITHMETIC_OVERFLOW Language=DEU -Arithmetischer Überlauf +Arithmetischer Überlauf . MessageId=535 SymbolicName=ERROR_PIPE_CONNECTED @@ -997,12 +996,12 @@ E/A-Operation abgebrochen MessageId=996 SymbolicName=ERROR_IO_INCOMPLETE Language=DEU -Überlappende E/A unvollständig +Überlappende E/A unvollständig . MessageId=997 SymbolicName=ERROR_IO_PENDING Language=DEU -Überlappende E/A anhängig +Überlappende E/A anhängig . MessageId=998 SymbolicName=ERROR_NOACCESS @@ -1017,12 +1016,12 @@ Swap-Fehler MessageId=1001 SymbolicName=ERROR_STACK_OVERFLOW Language=DEU -Stacküberlauf +Stacküberlauf . MessageId=1002 SymbolicName=ERROR_INVALID_MESSAGE Language=DEU -Ungültige Nachricht +Ungültige Nachricht . MessageId=1003 SymbolicName=ERROR_CAN_NOT_COMPLETE @@ -1032,7 +1031,7 @@ Kann nicht abschliessen MessageId=1004 SymbolicName=ERROR_INVALID_FLAGS Language=DEU -Ungültige Flags +Ungültige Flags . MessageId=1005 SymbolicName=ERROR_UNRECOGNIZED_VOLUME @@ -1042,12 +1041,12 @@ Unerkanntes Volume MessageId=1006 SymbolicName=ERROR_FILE_INVALID Language=DEU -Datei ungültig +Datei ungültig . MessageId=1007 SymbolicName=ERROR_FULLSCREEN_MODE Language=DEU -Kann nicht in Vollbild ausführen +Kann nicht in Vollbild ausführen . MessageId=1008 SymbolicName=ERROR_NO_TOKEN @@ -1057,12 +1056,12 @@ Nicht existierendes Token MessageId=1009 SymbolicName=ERROR_BADDB Language=DEU -Registry beschädigt +Registry beschädigt . MessageId=1010 SymbolicName=ERROR_BADKEY Language=DEU -Ungültiger Schlüssel +Ungültiger Schlüssel . MessageId=1011 SymbolicName=ERROR_CANTOPEN @@ -1072,12 +1071,12 @@ ERROR_CANTOPEN MessageId=1012 SymbolicName=ERROR_CANTREAD Language=DEU -Kann Registry-Schlüssel nicht lesen +Kann Registry-Schlüssel nicht lesen . MessageId=1013 SymbolicName=ERROR_CANTWRITE Language=DEU -Kann Registry-Schlüssel nicht schreiben +Kann Registry-Schlüssel nicht schreiben . MessageId=1014 SymbolicName=ERROR_REGISTRY_RECOVERED @@ -1087,7 +1086,7 @@ Registry wurde wiederhergestellt MessageId=1015 SymbolicName=ERROR_REGISTRY_CORRUPT Language=DEU -Registry ist beschädigt +Registry ist beschädigt . MessageId=1016 SymbolicName=ERROR_REGISTRY_IO_FAILED @@ -1102,37 +1101,37 @@ Keine Registry-Datei MessageId=1018 SymbolicName=ERROR_KEY_DELETED Language=DEU -Schlüssel gelöscht +Schlüssel gelöscht . MessageId=1019 SymbolicName=ERROR_NO_LOG_SPACE Language=DEU -Kein Speicher für Registry-Protokoll +Kein Speicher für Registry-Protokoll . MessageId=1020 SymbolicName=ERROR_KEY_HAS_CHILDREN Language=DEU -Registry-Schlüssel hat Unterschlüssel +Registry-Schlüssel hat Unterschlüssel . MessageId=1021 SymbolicName=ERROR_CHILD_MUST_BE_VOLATILE Language=DEU -Unterschlüssel muss flüchtig sein +Unterschlüssel muss flüchtig sein . MessageId=1022 SymbolicName=ERROR_NOTIFY_ENUM_DIR Language=DEU -Anfrage für Änderungsbenachrichtigung im Gange +Anfrage für Änderungsbenachrichtigung im Gange . MessageId=1051 SymbolicName=ERROR_DEPENDENT_SERVICES_RUNNING Language=DEU -Abhängige Dienste laufen +Abhängige Dienste laufen . MessageId=1052 SymbolicName=ERROR_INVALID_SERVICE_CONTROL Language=DEU -Ungültige Dienststeuerung +Ungültige Dienststeuerung . MessageId=1053 SymbolicName=ERROR_SERVICE_REQUEST_TIMEOUT @@ -1152,12 +1151,12 @@ Dienst-Datenbank gesperrt MessageId=1056 SymbolicName=ERROR_SERVICE_ALREADY_RUNNING Language=DEU -Dienst läuft bereits +Dienst läuft bereits . MessageId=1057 SymbolicName=ERROR_INVALID_SERVICE_ACCOUNT Language=DEU -Ungültiges Dienste-Konto +Ungültiges Dienste-Konto . MessageId=1058 SymbolicName=ERROR_SERVICE_DISABLED @@ -1167,7 +1166,7 @@ Dienst ist deaktiviert MessageId=1059 SymbolicName=ERROR_CIRCULAR_DEPENDENCY Language=DEU -Zirkuläre Abhängigkeit +Zirkuläre Abhängigkeit . MessageId=1060 SymbolicName=ERROR_SERVICE_DOES_NOT_EXIST @@ -1212,7 +1211,7 @@ Prozess fehlgeschlagen MessageId=1068 SymbolicName=ERROR_SERVICE_DEPENDENCY_FAIL Language=DEU -Dienst-Abhängigkeit fehlgeschlagen +Dienst-Abhängigkeit fehlgeschlagen . MessageId=1069 SymbolicName=ERROR_SERVICE_LOGON_FAILED @@ -1227,12 +1226,12 @@ Dienst bei Start aufgehangen MessageId=1071 SymbolicName=ERROR_INVALID_SERVICE_LOCK Language=DEU -Ungültige Dienst-Sperre +Ungültige Dienst-Sperre . MessageId=1072 SymbolicName=ERROR_SERVICE_MARKED_FOR_DELETE Language=DEU -Dienst für Löschen markiert +Dienst für Löschen markiert . MessageId=1073 SymbolicName=ERROR_SERVICE_EXISTS @@ -1247,7 +1246,7 @@ System benutzt letzte als funktionierend bekannte Konfiguration MessageId=1075 SymbolicName=ERROR_SERVICE_DEPENDENCY_DELETED Language=DEU -Dienst-Abhängigkeit gelöscht +Dienst-Abhängigkeit gelöscht . MessageId=1076 SymbolicName=ERROR_BOOT_ALREADY_ACCEPTED @@ -1322,12 +1321,12 @@ Partitionsfehler MessageId=1106 SymbolicName=ERROR_INVALID_BLOCK_LENGTH Language=DEU -Ungültige Blocklänge +Ungültige Blocklänge . MessageId=1107 SymbolicName=ERROR_DEVICE_NOT_PARTITIONED Language=DEU -Gerät nicht partitioniert +Gerät nicht partitioniert . MessageId=1108 SymbolicName=ERROR_UNABLE_TO_LOCK_MEDIA @@ -1357,7 +1356,7 @@ Kein Medium im Laufwerk MessageId=1113 SymbolicName=ERROR_NO_UNICODE_TRANSLATION Language=DEU -Keine Unicode-Übersetzung +Keine Unicode-Übersetzung . MessageId=1114 SymbolicName=ERROR_DLL_INIT_FAILED @@ -1377,27 +1376,27 @@ Kein Herunterfahren im Gange MessageId=1117 SymbolicName=ERROR_IO_DEVICE Language=DEU -E/A Gerätefehler +E/A Gerätefehler . MessageId=1118 SymbolicName=ERROR_SERIAL_NO_DEVICE Language=DEU -Keine seriellen Geräte gefunden +Keine seriellen Geräte gefunden . MessageId=1119 SymbolicName=ERROR_IRQ_BUSY Language=DEU -Geteilter IRQ beschäftigt +Geteilter IRQ beschäftigt . MessageId=1120 SymbolicName=ERROR_MORE_WRITES Language=DEU -Serielle E/A vollständig +Serielle E/A vollständig . MessageId=1121 SymbolicName=ERROR_COUNTER_TIMEOUT Language=DEU -Timeout von seriellem E/A Zähler +Timeout von seriellem E/A Zähler . MessageId=1122 SymbolicName=ERROR_FLOPPY_ID_MARK_NOT_FOUND @@ -1447,12 +1446,12 @@ Nicht genug Serverspeicher MessageId=1131 SymbolicName=ERROR_POSSIBLE_DEADLOCK Language=DEU -Mögliche Verklemmung +Mögliche Verklemmung . MessageId=1132 SymbolicName=ERROR_MAPPED_ALIGNMENT Language=DEU -Ungültige Ausrichtung +Ungültige Ausrichtung . MessageId=1140 SymbolicName=ERROR_SET_POWER_STATE_VETOED @@ -1467,12 +1466,12 @@ Setzen des Energie-Zustands fehlgeschlagen MessageId=1142 SymbolicName=ERROR_TOO_MANY_LINKS Language=DEU -Zu viele Verknüpfungen +Zu viele Verknüpfungen . MessageId=1150 SymbolicName=ERROR_OLD_WIN_VERSION Language=DEU -Neuerer Windows-Version benötigt +Neuerer Windows-Version benötigt . MessageId=1151 SymbolicName=ERROR_APP_WRONG_OS @@ -1492,12 +1491,12 @@ Real-Mode-Anwendung MessageId=1154 SymbolicName=ERROR_INVALID_DLL Language=DEU -Ungültige DLL +Ungültige DLL . MessageId=1155 SymbolicName=ERROR_NO_ASSOCIATION Language=DEU -Keine verknüpfte Anwendung +Keine verknüpfte Anwendung . MessageId=1156 SymbolicName=ERROR_DDE_FAIL @@ -1627,17 +1626,17 @@ ERROR_JOURNAL_ENTRY_DELETED MessageId=1200 SymbolicName=ERROR_BAD_DEVICE Language=DEU -Ungültiger Gerätename +Ungültiger Gerätename . MessageId=1201 SymbolicName=ERROR_CONNECTION_UNAVAIL Language=DEU -Verbindung nicht verfügbar +Verbindung nicht verfügbar . MessageId=1202 SymbolicName=ERROR_DEVICE_ALREADY_REMEMBERED Language=DEU -Gerät wird bereits errinnert +Gerät wird bereits errinnert . MessageId=1203 SymbolicName=ERROR_NO_NET_OR_BAD_PATH @@ -1647,17 +1646,17 @@ Kein Netzwerk oder falscher Pfad MessageId=1204 SymbolicName=ERROR_BAD_PROVIDER Language=DEU -Ungültiger Name für Netzwerk-Provider +Ungültiger Name für Netzwerk-Provider . MessageId=1205 SymbolicName=ERROR_CANNOT_OPEN_PROFILE Language=DEU -Kann Netzwerkverbindungsprofil nicht öffnen +Kann Netzwerkverbindungsprofil nicht öffnen . MessageId=1206 SymbolicName=ERROR_BAD_PROFILE Language=DEU -Beschädigtes Netzwerkverbindungsprofil +Beschädigtes Netzwerkverbindungsprofil . MessageId=1207 SymbolicName=ERROR_NOT_CONTAINER @@ -1672,52 +1671,52 @@ Erweiterter Fehler MessageId=1209 SymbolicName=ERROR_INVALID_GROUPNAME Language=DEU -Ungültiger Gruppenname +Ungültiger Gruppenname . MessageId=1210 SymbolicName=ERROR_INVALID_COMPUTERNAME Language=DEU -Ungültiger Computername +Ungültiger Computername . MessageId=1211 SymbolicName=ERROR_INVALID_EVENTNAME Language=DEU -Ungültiger Ereignisname +Ungültiger Ereignisname . MessageId=1212 SymbolicName=ERROR_INVALID_DOMAINNAME Language=DEU -Ungültiger Domain-Name +Ungültiger Domain-Name . MessageId=1213 SymbolicName=ERROR_INVALID_SERVICENAME Language=DEU -Ungültiger Dienstname +Ungültiger Dienstname . MessageId=1214 SymbolicName=ERROR_INVALID_NETNAME Language=DEU -Ungültiger Netzwerkname +Ungültiger Netzwerkname . MessageId=1215 SymbolicName=ERROR_INVALID_SHARENAME Language=DEU -Ungültiger Freigabenname +Ungültiger Freigabenname . MessageId=1216 SymbolicName=ERROR_INVALID_PASSWORDNAME Language=DEU -Ungültiges Passwort +Ungültiges Passwort . MessageId=1217 SymbolicName=ERROR_INVALID_MESSAGENAME Language=DEU -Ungültiger Nachrichtenname +Ungültiger Nachrichtenname . MessageId=1218 SymbolicName=ERROR_INVALID_MESSAGEDEST Language=DEU -Ungültiges Nachrichtenziel +Ungültiges Nachrichtenziel . MessageId=1219 SymbolicName=ERROR_SESSION_CREDENTIAL_CONFLICT @@ -1727,12 +1726,12 @@ Konflikt in Sitzungs-Berechtigung MessageId=1220 SymbolicName=ERROR_REMOTE_SESSION_LIMIT_EXCEEDED Language=DEU -Situngslimit des Remoterechners überschritten +Situngslimit des Remoterechners überschritten . MessageId=1221 SymbolicName=ERROR_DUP_DOMAINNAME Language=DEU -Doppelter Domänen- oder Arbeitsgruppenname +Doppelter Domänen- oder Arbeitsgruppenname . MessageId=1222 SymbolicName=ERROR_NO_NETWORK @@ -1772,7 +1771,7 @@ Adresse nicht mit Transport-Endpunkt assoziiert MessageId=1229 SymbolicName=ERROR_CONNECTION_INVALID Language=DEU -Ungültige Verbindung +Ungültige Verbindung . MessageId=1230 SymbolicName=ERROR_CONNECTION_ACTIVE @@ -1832,7 +1831,7 @@ Login-Arbeitsplatz-Begrenzung MessageId=1241 SymbolicName=ERROR_INCORRECT_ADDRESS Language=DEU -Ungültige Netzwerkadresse +Ungültige Netzwerkadresse . MessageId=1242 SymbolicName=ERROR_ALREADY_REGISTERED @@ -1867,7 +1866,7 @@ Bereits initialisiert MessageId=1248 SymbolicName=ERROR_NO_MORE_DEVICES Language=DEU -Keine weiteren lokalen Geräte +Keine weiteren lokalen Geräte . MessageId=1249 SymbolicName=ERROR_NO_SUCH_SITE @@ -1912,17 +1911,17 @@ Einige Sicherheits-IDs nicht abgebildet MessageId=1302 SymbolicName=ERROR_NO_QUOTAS_FOR_ACCOUNT Language=DEU -Keine Quota für Account +Keine Quota für Account . MessageId=1303 SymbolicName=ERROR_LOCAL_USER_SESSION_KEY Language=DEU -Sitzungsschlüssel für lokalen Benutzer +Sitzungsschlüssel für lokalen Benutzer . MessageId=1304 SymbolicName=ERROR_NULL_LM_PASSWORD Language=DEU -Passwort zu komplex für LM +Passwort zu komplex für LM . MessageId=1305 SymbolicName=ERROR_UNKNOWN_REVISION @@ -1937,12 +1936,12 @@ Inkompatible Revisions-Levels MessageId=1307 SymbolicName=ERROR_INVALID_OWNER Language=DEU -Ungültiger Besitzer +Ungültiger Besitzer . MessageId=1308 SymbolicName=ERROR_INVALID_PRIMARY_GROUP Language=DEU -Ungültige primäre Gruppe +Ungültige primäre Gruppe . MessageId=1309 SymbolicName=ERROR_NO_IMPERSONATION_TOKEN @@ -1957,7 +1956,7 @@ Kann obligatorische Gruppe nicht deaktivieren MessageId=1311 SymbolicName=ERROR_NO_LOGON_SERVERS Language=DEU -Keine Logon-Server verfügbar +Keine Logon-Server verfügbar . MessageId=1312 SymbolicName=ERROR_NO_SUCH_LOGON_SESSION @@ -1977,7 +1976,7 @@ Privileg nicht besessen MessageId=1315 SymbolicName=ERROR_INVALID_ACCOUNT_NAME Language=DEU -Ungültiger Account-Name +Ungültiger Account-Name . MessageId=1316 SymbolicName=ERROR_USER_EXISTS @@ -2012,7 +2011,7 @@ Benutzer nicht in Gruppe MessageId=1322 SymbolicName=ERROR_LAST_ADMIN Language=DEU -Kann letzten Admin-User nicht löschen +Kann letzten Admin-User nicht löschen . MessageId=1323 SymbolicName=ERROR_WRONG_PASSWORD @@ -2027,7 +2026,7 @@ Falsch formatiertes Passwort MessageId=1325 SymbolicName=ERROR_PASSWORD_RESTRICTION Language=DEU -Passwort-Beschränkung +Passwort-Beschränkung . MessageId=1326 SymbolicName=ERROR_LOGON_FAILURE @@ -2037,17 +2036,17 @@ Logon-Fehler MessageId=1327 SymbolicName=ERROR_ACCOUNT_RESTRICTION Language=DEU -Account-Beschränkung +Account-Beschränkung . MessageId=1328 SymbolicName=ERROR_INVALID_LOGON_HOURS Language=DEU -Ungültige Logon-Zeiten +Ungültige Logon-Zeiten . MessageId=1329 SymbolicName=ERROR_INVALID_WORKSTATION Language=DEU -Ungültiger Arbeitsplatz +Ungültiger Arbeitsplatz . MessageId=1330 SymbolicName=ERROR_PASSWORD_EXPIRED @@ -2072,27 +2071,27 @@ Zu viele LUIDs angefragt MessageId=1334 SymbolicName=ERROR_LUIDS_EXHAUSTED Language=DEU -LUIDs ausgeschöpft +LUIDs ausgeschöpft . MessageId=1335 SymbolicName=ERROR_INVALID_SUB_AUTHORITY Language=DEU -Ungültige Subauthorität +Ungültige Subauthorität . MessageId=1336 SymbolicName=ERROR_INVALID_ACL Language=DEU -Ungültige ACL +Ungültige ACL . MessageId=1337 SymbolicName=ERROR_INVALID_SID Language=DEU -Ungültige SID +Ungültige SID . MessageId=1338 SymbolicName=ERROR_INVALID_SECURITY_DESCR Language=DEU -Ungültiger Sicherheits-Deskriptor +Ungültiger Sicherheits-Deskriptor . MessageId=1340 SymbolicName=ERROR_BAD_INHERITANCE_ACL @@ -2112,17 +2111,17 @@ Server nicht deaktiviert MessageId=1343 SymbolicName=ERROR_INVALID_ID_AUTHORITY Language=DEU -Ungültige ID-Authorität +Ungültige ID-Authorität . MessageId=1344 SymbolicName=ERROR_ALLOTTED_SPACE_EXCEEDED Language=DEU -Zugewiesener Speicher überschritten +Zugewiesener Speicher überschritten . MessageId=1345 SymbolicName=ERROR_INVALID_GROUP_ATTRIBUTES Language=DEU -Ungültige Gruppen-Attribute +Ungültige Gruppen-Attribute . MessageId=1346 SymbolicName=ERROR_BAD_IMPERSONATION_LEVEL @@ -2132,7 +2131,7 @@ Fehlerhaftes Impersonation-Level MessageId=1347 SymbolicName=ERROR_CANT_OPEN_ANONYMOUS Language=DEU -Kann anonymes Sicherheits-Token nicht öffnen +Kann anonymes Sicherheits-Token nicht öffnen . MessageId=1348 SymbolicName=ERROR_BAD_VALIDATION_CLASS @@ -2152,42 +2151,42 @@ Keine Sicherheit auf Objekt MessageId=1351 SymbolicName=ERROR_CANT_ACCESS_DOMAIN_INFO Language=DEU -Kann auf Domänen-Information nicht zugreifen +Kann auf Domänen-Information nicht zugreifen . MessageId=1352 SymbolicName=ERROR_INVALID_SERVER_STATE Language=DEU -Ungültiger Server-Status +Ungültiger Server-Status . MessageId=1353 SymbolicName=ERROR_INVALID_DOMAIN_STATE Language=DEU -Ungültiger Domänen-Status +Ungültiger Domänen-Status . MessageId=1354 SymbolicName=ERROR_INVALID_DOMAIN_ROLE Language=DEU -Ungültige Domänen-Rolle +Ungültige Domänen-Rolle . MessageId=1355 SymbolicName=ERROR_NO_SUCH_DOMAIN Language=DEU -Keine solche Domäne +Keine solche Domäne . MessageId=1356 SymbolicName=ERROR_DOMAIN_EXISTS Language=DEU -Domäne existiert bereits +Domäne existiert bereits . MessageId=1357 SymbolicName=ERROR_DOMAIN_LIMIT_EXCEEDED Language=DEU -Domänen-Limit überschritten +Domänen-Limit überschritten . MessageId=1358 SymbolicName=ERROR_INTERNAL_DB_CORRUPTION Language=DEU -Interne Datenbank beschädigt +Interne Datenbank beschädigt . MessageId=1359 SymbolicName=ERROR_INTERNAL_ERROR @@ -2232,7 +2231,7 @@ Kollision von Logon-Sitzungs-ID MessageId=1367 SymbolicName=ERROR_INVALID_LOGON_TYPE Language=DEU -Ungültiger Logon-Typ +Ungültiger Logon-Typ . MessageId=1368 SymbolicName=ERROR_CANNOT_IMPERSONATE @@ -2242,7 +2241,7 @@ Kann nicht Impersonaten MessageId=1369 SymbolicName=ERROR_RXACT_INVALID_STATE Language=DEU -Ungültiger Transaktions-Status +Ungültiger Transaktions-Status . MessageId=1370 SymbolicName=ERROR_RXACT_COMMIT_FAILURE @@ -2267,7 +2266,7 @@ Benutzer ist eingebaut MessageId=1374 SymbolicName=ERROR_MEMBERS_PRIMARY_GROUP Language=DEU -Gruppe ist primär für Benutzer +Gruppe ist primär für Benutzer . MessageId=1375 SymbolicName=ERROR_TOKEN_ALREADY_IN_USE @@ -2327,7 +2326,7 @@ Logon-Typ nicht zugestanden MessageId=1386 SymbolicName=ERROR_NT_CROSS_ENCRYPTION_REQUIRED Language=DEU -Querverschlüsseltes NT-Passwort erforderlich +Querverschlüsseltes NT-Passwort erforderlich . MessageId=1387 SymbolicName=ERROR_NO_SUCH_MEMBER @@ -2337,7 +2336,7 @@ Kein solches Mitglied MessageId=1388 SymbolicName=ERROR_INVALID_MEMBER Language=DEU -Ungültiges Mitglied +Ungültiges Mitglied . MessageId=1389 SymbolicName=ERROR_TOO_MANY_SIDS @@ -2347,7 +2346,7 @@ Zu viele SIDs MessageId=1390 SymbolicName=ERROR_LM_CROSS_ENCRYPTION_REQUIRED Language=DEU -Querverschlüsseltes LM-Passwort erforderlich +Querverschlüsseltes LM-Passwort erforderlich . MessageId=1391 SymbolicName=ERROR_NO_INHERITANCE @@ -2357,22 +2356,22 @@ Keine vererbbaren Komponenten MessageId=1392 SymbolicName=ERROR_FILE_CORRUPT Language=DEU -Datei oder Verzeichnis beschädigt +Datei oder Verzeichnis beschädigt . MessageId=1393 SymbolicName=ERROR_DISK_CORRUPT Language=DEU -Datenträger beschädigt +Datenträger beschädigt . MessageId=1394 SymbolicName=ERROR_NO_USER_SESSION_KEY Language=DEU -Kein Beutzer-Sitzungs-Schlüssel +Kein Beutzer-Sitzungs-Schlüssel . MessageId=1395 SymbolicName=ERROR_LICENSE_QUOTA_EXCEEDED Language=DEU -Lizenz-Quota überschritten +Lizenz-Quota überschritten . MessageId=1396 SymbolicName=ERROR_WRONG_TARGET_NAME @@ -2392,32 +2391,32 @@ ERROR_TIME_SKEW MessageId=1400 SymbolicName=ERROR_INVALID_WINDOW_HANDLE Language=DEU -Ungültiges Fenster-Handle +Ungültiges Fenster-Handle . MessageId=1401 SymbolicName=ERROR_INVALID_MENU_HANDLE Language=DEU -Ungültiges Menü-Handle +Ungültiges Menü-Handle . MessageId=1402 SymbolicName=ERROR_INVALID_CURSOR_HANDLE Language=DEU -Ungültiges Cursor-Handle +Ungültiges Cursor-Handle . MessageId=1403 SymbolicName=ERROR_INVALID_ACCEL_HANDLE Language=DEU -Ungültiges Accelerator-Tabellen-Handle +Ungültiges Accelerator-Tabellen-Handle . MessageId=1404 SymbolicName=ERROR_INVALID_HOOK_HANDLE Language=DEU -Ungültiges Hook-Handle +Ungültiges Hook-Handle . MessageId=1405 SymbolicName=ERROR_INVALID_DWP_HANDLE Language=DEU -Ungültiges DWP-Handle +Ungültiges DWP-Handle . MessageId=1406 SymbolicName=ERROR_TLW_WITH_WSCHILD @@ -2432,7 +2431,7 @@ Kann Fenster-Klasse nicht finden MessageId=1408 SymbolicName=ERROR_WINDOW_OF_OTHER_THREAD Language=DEU -Fenster gehört anderem Thread +Fenster gehört anderem Thread . MessageId=1409 SymbolicName=ERROR_HOTKEY_ALREADY_REGISTERED @@ -2457,12 +2456,12 @@ Klasse hat offene Fenster MessageId=1413 SymbolicName=ERROR_INVALID_INDEX Language=DEU -Ungültiger Index +Ungültiger Index . MessageId=1414 SymbolicName=ERROR_INVALID_ICON_HANDLE Language=DEU -Ungültiges Icon-Handle +Ungültiges Icon-Handle . MessageId=1415 SymbolicName=ERROR_PRIVATE_DIALOG_INDEX @@ -2502,7 +2501,7 @@ Steuerelement-ID nicht gefunden MessageId=1422 SymbolicName=ERROR_INVALID_COMBOBOX_MESSAGE Language=DEU -Ungültige Combobox-Nachricht +Ungültige Combobox-Nachricht . MessageId=1423 SymbolicName=ERROR_WINDOW_NOT_COMBOBOX @@ -2512,7 +2511,7 @@ Kein Combobox-Fenster MessageId=1424 SymbolicName=ERROR_INVALID_EDIT_HEIGHT Language=DEU -Ungültige Edit-Höhe +Ungültige Edit-Höhe . MessageId=1425 SymbolicName=ERROR_DC_NOT_FOUND @@ -2522,12 +2521,12 @@ DC nicht gefunden MessageId=1426 SymbolicName=ERROR_INVALID_HOOK_FILTER Language=DEU -Ungültiger Hook-Filter +Ungültiger Hook-Filter . MessageId=1427 SymbolicName=ERROR_INVALID_FILTER_PROC Language=DEU -Ungültige Filter-Prozedur +Ungültige Filter-Prozedur . MessageId=1428 SymbolicName=ERROR_HOOK_NEEDS_HMOD @@ -2552,12 +2551,12 @@ Hook-Prozedur nicht installiert MessageId=1432 SymbolicName=ERROR_INVALID_LB_MESSAGE Language=DEU -Ungültige Listbox-Nachricht +Ungültige Listbox-Nachricht . MessageId=1433 SymbolicName=ERROR_SETCOUNT_ON_BAD_LB Language=DEU -Ungültige LB_SETCOUNT gesendet +Ungültige LB_SETCOUNT gesendet . MessageId=1434 SymbolicName=ERROR_LB_WITHOUT_TABSTOPS @@ -2567,27 +2566,27 @@ Keine Tabstops in dieser Listbox MessageId=1435 SymbolicName=ERROR_DESTROY_OBJECT_OF_OTHER_THREAD Language=DEU -Kann nicht Objekt zerstören dass anderem Thread gehört +Kann nicht Objekt zerstören dass anderem Thread gehört . MessageId=1436 SymbolicName=ERROR_CHILD_WINDOW_MENU Language=DEU -Menüs in Kindfenstern nicht erlaubt +Menüs in Kindfenstern nicht erlaubt . MessageId=1437 SymbolicName=ERROR_NO_SYSTEM_MENU Language=DEU -Fenster hat kein System-Menü +Fenster hat kein System-Menü . MessageId=1438 SymbolicName=ERROR_INVALID_MSGBOX_STYLE Language=DEU -Ungültiger Stil für Meldungsfenster +Ungültiger Stil für Meldungsfenster . MessageId=1439 SymbolicName=ERROR_INVALID_SPI_VALUE Language=DEU -Ungültiger SPI-Parameter +Ungültiger SPI-Parameter . MessageId=1440 SymbolicName=ERROR_SCREEN_ALREADY_LOCKED @@ -2607,12 +2606,12 @@ Kein Kindfenster MessageId=1443 SymbolicName=ERROR_INVALID_GW_COMMAND Language=DEU -Ungültiger GW-Befehl +Ungültiger GW-Befehl . MessageId=1444 SymbolicName=ERROR_INVALID_THREAD_ID Language=DEU -Ungültige Thread-ID +Ungültige Thread-ID . MessageId=1445 SymbolicName=ERROR_NON_MDICHILD_WINDOW @@ -2622,7 +2621,7 @@ Kein MDI-Kindfenster MessageId=1446 SymbolicName=ERROR_POPUP_ALREADY_ACTIVE Language=DEU -Popup-Menü bereits aktiv +Popup-Menü bereits aktiv . MessageId=1447 SymbolicName=ERROR_NO_SCROLLBARS @@ -2632,12 +2631,12 @@ Kein Bildlaufleisten MessageId=1448 SymbolicName=ERROR_INVALID_SCROLLBAR_RANGE Language=DEU -Ungültiger Bereich für Bildlaufleiste +Ungültiger Bereich für Bildlaufleiste . MessageId=1449 SymbolicName=ERROR_INVALID_SHOWWIN_COMMAND Language=DEU -Ungültiger ShowWin-Befehl +Ungültiger ShowWin-Befehl . MessageId=1450 SymbolicName=ERROR_NO_SYSTEM_RESOURCES @@ -2657,22 +2656,22 @@ Keine paged Systemressourcen MessageId=1453 SymbolicName=ERROR_WORKING_SET_QUOTA Language=DEU -Keine Quota für Working Set +Keine Quota für Working Set . MessageId=1454 SymbolicName=ERROR_PAGEFILE_QUOTA Language=DEU -Keine Quota für Pagefile +Keine Quota für Pagefile . MessageId=1455 SymbolicName=ERROR_COMMITMENT_LIMIT Language=DEU -Commitment-Grenze überschritten +Commitment-Grenze überschritten . MessageId=1456 SymbolicName=ERROR_MENU_ITEM_NOT_FOUND Language=DEU -Menü-Eintrag nicht gefunden +Menü-Eintrag nicht gefunden . MessageId=1457 SymbolicName=ERROR_INVALID_KEYBOARD_HANDLE @@ -2702,7 +2701,7 @@ ERROR_INVALID_MONITOR_HANDLE MessageId=1500 SymbolicName=ERROR_EVENTLOG_FILE_CORRUPT Language=DEU -Ereignisprotokolldatei beschädigt +Ereignisprotokolldatei beschädigt . MessageId=1501 SymbolicName=ERROR_EVENTLOG_CANT_START @@ -2717,7 +2716,7 @@ Ereignisprotokolldatei voll MessageId=1503 SymbolicName=ERROR_EVENTLOG_FILE_CHANGED Language=DEU -Ereignisprotokolldatei verändert +Ereignisprotokolldatei verändert . MessageId=1601 SymbolicName=ERROR_INSTALL_SERVICE_FAILURE @@ -2927,7 +2926,7 @@ ERROR_SUCCESS_REBOOT_INITIATED MessageId=1700 SymbolicName=RPC_S_INVALID_STRING_BINDING Language=DEU -Ungültige String-Bindung +Ungültige String-Bindung . MessageId=1701 SymbolicName=RPC_S_WRONG_KIND_OF_BINDING @@ -2937,32 +2936,32 @@ Falsche Bindungsart MessageId=1702 SymbolicName=RPC_S_INVALID_BINDING Language=DEU -Ungültige Bindung +Ungültige Bindung . MessageId=1703 SymbolicName=RPC_S_PROTSEQ_NOT_SUPPORTED Language=DEU -RPC-Protokollsequenz nicht unterstützt +RPC-Protokollsequenz nicht unterstützt . MessageId=1704 SymbolicName=RPC_S_INVALID_RPC_PROTSEQ Language=DEU -Ungültige RPC-Protokollsequenz +Ungültige RPC-Protokollsequenz . MessageId=1705 SymbolicName=RPC_S_INVALID_STRING_UUID Language=DEU -Ungültige String-UUID +Ungültige String-UUID . MessageId=1706 SymbolicName=RPC_S_INVALID_ENDPOINT_FORMAT Language=DEU -Ungültiges Endpunkt-Format +Ungültiges Endpunkt-Format . MessageId=1707 SymbolicName=RPC_S_INVALID_NET_ADDR Language=DEU -Ungültige Netzwerkadresse +Ungültige Netzwerkadresse . MessageId=1708 SymbolicName=RPC_S_NO_ENDPOINT_FOUND @@ -2972,7 +2971,7 @@ Kein Endpunkt gefunden MessageId=1709 SymbolicName=RPC_S_INVALID_TIMEOUT Language=DEU -Ungültiger Timeout-Wert +Ungültiger Timeout-Wert . MessageId=1710 SymbolicName=RPC_S_OBJECT_NOT_FOUND @@ -3037,17 +3036,17 @@ Keine Ressourcen mehr MessageId=1722 SymbolicName=RPC_S_SERVER_UNAVAILABLE Language=DEU -RPC-Server nicht verfügbar +RPC-Server nicht verfügbar . MessageId=1723 SymbolicName=RPC_S_SERVER_TOO_BUSY Language=DEU -RPC-Server zu beschäftigt +RPC-Server zu beschäftigt . MessageId=1724 SymbolicName=RPC_S_INVALID_NETWORK_OPTIONS Language=DEU -Ungültige Netzwerk-Optionen +Ungültige Netzwerk-Optionen . MessageId=1725 SymbolicName=RPC_S_NO_CALL_ACTIVE @@ -3062,7 +3061,7 @@ RPC-Aufruf fehlgeschlagen MessageId=1727 SymbolicName=RPC_S_CALL_FAILED_DNE Language=DEU -RPC-Aufruf fehlgeschlagen und nicht ausgeführt +RPC-Aufruf fehlgeschlagen und nicht ausgeführt . MessageId=1728 SymbolicName=RPC_S_PROTOCOL_ERROR @@ -3072,22 +3071,22 @@ RPC-Protokoll-Fehler MessageId=1730 SymbolicName=RPC_S_UNSUPPORTED_TRANS_SYN Language=DEU -Nicht unterstützte Transfer-Syntax +Nicht unterstützte Transfer-Syntax . MessageId=1732 SymbolicName=RPC_S_UNSUPPORTED_TYPE Language=DEU -Nicht unterstützter Typ +Nicht unterstützter Typ . MessageId=1733 SymbolicName=RPC_S_INVALID_TAG Language=DEU -Ungültiges Tag +Ungültiges Tag . MessageId=1734 SymbolicName=RPC_S_INVALID_BOUND Language=DEU -Ungültige Array-Grenzen +Ungültige Array-Grenzen . MessageId=1735 SymbolicName=RPC_S_NO_ENTRY_NAME @@ -3097,12 +3096,12 @@ Kein Eintrags-Name MessageId=1736 SymbolicName=RPC_S_INVALID_NAME_SYNTAX Language=DEU -Ungültige Namens-Syntax +Ungültige Namens-Syntax . MessageId=1737 SymbolicName=RPC_S_UNSUPPORTED_NAME_SYNTAX Language=DEU -Nicht unterstützte Namens-Syntax +Nicht unterstützte Namens-Syntax . MessageId=1739 SymbolicName=RPC_S_UUID_NO_ADDRESS @@ -3122,7 +3121,7 @@ Unbekannter Authentifizierungs-Typ MessageId=1742 SymbolicName=RPC_S_MAX_CALLS_TOO_SMALL Language=DEU -Höchstanzahl an Aufrufen zu niedrig +Höchstanzahl an Aufrufen zu niedrig . MessageId=1743 SymbolicName=RPC_S_STRING_TOO_LONG @@ -3157,7 +3156,7 @@ Unbekanntes Authentifizierungs-Level MessageId=1749 SymbolicName=RPC_S_INVALID_AUTH_IDENTITY Language=DEU -Ungültige Authentifizierungs-Identität +Ungültige Authentifizierungs-Identität . MessageId=1750 SymbolicName=RPC_S_UNKNOWN_AUTHZ_SERVICE @@ -3167,12 +3166,12 @@ Unbekannter Authorisierungs-Dienst MessageId=1751 SymbolicName=EPT_S_INVALID_ENTRY Language=DEU -Ungültiger Eintrag +Ungültiger Eintrag . MessageId=1752 SymbolicName=EPT_S_CANT_PERFORM_OP Language=DEU -Kann Operation nicht ausführen +Kann Operation nicht ausführen . MessageId=1753 SymbolicName=EPT_S_NOT_REGISTERED @@ -3187,12 +3186,12 @@ Nichts zu exportieren MessageId=1755 SymbolicName=RPC_S_INCOMPLETE_NAME Language=DEU -Unvollständiger Name +Unvollständiger Name . MessageId=1756 SymbolicName=RPC_S_INVALID_VERS_OPTION Language=DEU -Ungültige Versions-Option +Ungültige Versions-Option . MessageId=1757 SymbolicName=RPC_S_NO_MORE_MEMBERS @@ -3222,22 +3221,22 @@ Eintrag nicht gefunden MessageId=1762 SymbolicName=RPC_S_NAME_SERVICE_UNAVAILABLE Language=DEU -Namens-Dienst nicht verfügbar +Namens-Dienst nicht verfügbar . MessageId=1763 SymbolicName=RPC_S_INVALID_NAF_ID Language=DEU -Ungültige Netzwerkadressfamilie +Ungültige Netzwerkadressfamilie . MessageId=1764 SymbolicName=RPC_S_CANNOT_SUPPORT Language=DEU -Operation nicht unterstützt +Operation nicht unterstützt . MessageId=1765 SymbolicName=RPC_S_NO_CONTEXT_AVAILABLE Language=DEU -Kein Sicherheits-Kontext verfügbar +Kein Sicherheits-Kontext verfügbar . MessageId=1766 SymbolicName=RPC_S_INTERNAL_ERROR @@ -3257,32 +3256,32 @@ Adressfehler MessageId=1769 SymbolicName=RPC_S_FP_DIV_ZERO Language=DEU -Fließkomma Division durch Null +Fließkomma Division durch Null . MessageId=1770 SymbolicName=RPC_S_FP_UNDERFLOW Language=DEU -Fließkomma-Unterlauf +Fließkomma-Unterlauf . MessageId=1771 SymbolicName=RPC_S_FP_OVERFLOW Language=DEU -Fließkomma-Überlauf +Fließkomma-Überlauf . MessageId=1772 SymbolicName=RPC_X_NO_MORE_ENTRIES Language=DEU -Keine weiteren Einträge +Keine weiteren Einträge . MessageId=1773 SymbolicName=RPC_X_SS_CHAR_TRANS_OPEN_FAIL Language=DEU -Öffnen der Zeichenübersetzungstabelle fehlgeschlagen +Öffnen der Zeichenübersetzungstabelle fehlgeschlagen . MessageId=1774 SymbolicName=RPC_X_SS_CHAR_TRANS_SHORT_FILE Language=DEU -Zeichenübersetzungstabellendatei zu klein +Zeichenübersetzungstabellendatei zu klein . MessageId=1775 SymbolicName=RPC_X_SS_IN_NULL_CONTEXT @@ -3292,12 +3291,12 @@ Kontext-Handle ist Null MessageId=1777 SymbolicName=RPC_X_SS_CONTEXT_DAMAGED Language=DEU -Kontext-Handle beschädigt +Kontext-Handle beschädigt . MessageId=1778 SymbolicName=RPC_X_SS_HANDLES_MISMATCH Language=DEU -Bindungs-Handle stimmen nicht überein +Bindungs-Handle stimmen nicht überein . MessageId=1779 SymbolicName=RPC_X_SS_CANNOT_GET_CALL_HANDLE @@ -3312,7 +3311,7 @@ Referenz-Zeiger ist Null MessageId=1781 SymbolicName=RPC_X_DEUM_VALUE_OUT_OF_RANGE Language=DEU -Aufzählungswert ausserhalb des Bereichs +Aufzählungswert ausserhalb des Bereichs . MessageId=1782 SymbolicName=RPC_X_BYTE_COUNT_TOO_SMALL @@ -3327,7 +3326,7 @@ Fehlerhafte Stub-Daten MessageId=1784 SymbolicName=ERROR_INVALID_USER_BUFFER Language=DEU -Ungültiger Benutzerpuffer +Ungültiger Benutzerpuffer . MessageId=1785 SymbolicName=ERROR_UNRECOGNIZED_MEDIA @@ -3347,7 +3346,7 @@ Kein Vertrauens-SAM-Account MessageId=1788 SymbolicName=ERROR_TRUSTED_DOMAIN_FAILURE Language=DEU -Vertrauens-Domänen-Fehler +Vertrauens-Domänen-Fehler . MessageId=1789 SymbolicName=ERROR_TRUSTED_RELATIONSHIP_FAILURE @@ -3402,17 +3401,17 @@ Unbekannter Druckerprozessor MessageId=1799 SymbolicName=ERROR_INVALID_SEPARATOR_FILE Language=DEU -Ungültige Trenner-Datei +Ungültige Trenner-Datei . MessageId=1800 SymbolicName=ERROR_INVALID_PRIORITY Language=DEU -Ungültige Priorität +Ungültige Priorität . MessageId=1801 SymbolicName=ERROR_INVALID_PRINTER_NAME Language=DEU -Ungültiger Druckername +Ungültiger Druckername . MessageId=1802 SymbolicName=ERROR_PRINTER_ALREADY_EXISTS @@ -3422,17 +3421,17 @@ Drucker existiert bereits MessageId=1803 SymbolicName=ERROR_INVALID_PRINTER_COMMAND Language=DEU -Ungültiger Druckerbefehl +Ungültiger Druckerbefehl . MessageId=1804 SymbolicName=ERROR_INVALID_DATATYPE Language=DEU -Ungültiger Datentyp +Ungültiger Datentyp . MessageId=1805 SymbolicName=ERROR_INVALID_ENVIRONMENT Language=DEU -Ungültige Umgebung +Ungültige Umgebung . MessageId=1806 SymbolicName=RPC_S_NO_MORE_BINDINGS @@ -3442,7 +3441,7 @@ Keine weiteren Bindungen MessageId=1807 SymbolicName=ERROR_NOLOGON_INTERDOMAIN_TRUST_ACCOUNT Language=DEU -Kann nicht mit Interdomänen-Vertrauens-Account einloggen +Kann nicht mit Interdomänen-Vertrauens-Account einloggen . MessageId=1808 SymbolicName=ERROR_NOLOGON_WORKSTATION_TRUST_ACCOUNT @@ -3457,7 +3456,7 @@ Kann nicht mit Server-Vertrauens-Account einloggen MessageId=1810 SymbolicName=ERROR_DOMAIN_TRUST_INCONSISTENT Language=DEU -Domänen-Vertrauens-Information inkonsistent +Domänen-Vertrauens-Information inkonsistent . MessageId=1811 SymbolicName=ERROR_SERVER_HAS_OPEN_HANDLES @@ -3487,7 +3486,7 @@ Ressourcensprache nicht gefunden MessageId=1816 SymbolicName=ERROR_NOT_ENOUGH_QUOTA Language=DEU -Nicht genügend Quota +Nicht genügend Quota . MessageId=1817 SymbolicName=RPC_S_NO_INTERFACES @@ -3502,7 +3501,7 @@ RPC-Aufruf abgebrochen MessageId=1819 SymbolicName=RPC_S_BINDING_INCOMPLETE Language=DEU -Bindung unvollständig +Bindung unvollständig . MessageId=1820 SymbolicName=RPC_S_COMM_FAILURE @@ -3512,7 +3511,7 @@ RPC Comm-Fehler MessageId=1821 SymbolicName=RPC_S_UNSUPPORTED_AUTHN_LEVEL Language=DEU -Nicht unterstütztes Authorisierungs-Level +Nicht unterstütztes Authorisierungs-Level . MessageId=1822 SymbolicName=RPC_S_NO_PRINC_NAME @@ -3542,7 +3541,7 @@ Thread nicht abgebrochen MessageId=1827 SymbolicName=RPC_X_INVALID_ES_ACTION Language=DEU -Ungültige Handle-Operation +Ungültige Handle-Operation . MessageId=1828 SymbolicName=RPC_X_WRONG_ES_VERSION @@ -3557,7 +3556,7 @@ Fehlerhafte Stub-Version MessageId=1830 SymbolicName=RPC_X_INVALID_PIPE_OBJECT Language=DEU -Ungültiges Pipe-Objekt +Ungültiges Pipe-Objekt . MessageId=1831 SymbolicName=RPC_X_WRONG_PIPE_ORDER @@ -3582,22 +3581,22 @@ Kann Endpunkt-Abbildungs-Datenbank nicht erstellen MessageId=1900 SymbolicName=RPC_S_INVALID_OBJECT Language=DEU -Ungültiges Objekt +Ungültiges Objekt . MessageId=1901 SymbolicName=ERROR_INVALID_TIME Language=DEU -Ungültige Zeit +Ungültige Zeit . MessageId=1902 SymbolicName=ERROR_INVALID_FORM_NAME Language=DEU -Ungültiger Formularname +Ungültiger Formularname . MessageId=1903 SymbolicName=ERROR_INVALID_FORM_SIZE Language=DEU -Ungültige Formular-Grösse +Ungültige Formular-Grösse . MessageId=1904 SymbolicName=ERROR_ALREADY_WAITING @@ -3607,22 +3606,22 @@ Warte bereits auf Drucker-Handle MessageId=1905 SymbolicName=ERROR_PRINTER_DELETED Language=DEU -Drucker gelöscht +Drucker gelöscht . MessageId=1906 SymbolicName=ERROR_INVALID_PRINTER_STATE Language=DEU -Ungültiger Druckerzustand +Ungültiger Druckerzustand . MessageId=1907 SymbolicName=ERROR_PASSWORD_MUST_CHANGE Language=DEU -Benutzer muss Passwort ändern +Benutzer muss Passwort ändern . MessageId=1908 SymbolicName=ERROR_DOMAIN_CONTROLLER_NOT_FOUND Language=DEU -Domänen-Controllor nicht gefunden +Domänen-Controllor nicht gefunden . MessageId=1909 SymbolicName=ERROR_ACCOUNT_LOCKED_OUT @@ -3632,12 +3631,12 @@ Account ausgeschlossen MessageId=1910 SymbolicName=OR_INVALID_OXID Language=DEU -Ungültiges Pixel-Format +Ungültiges Pixel-Format . MessageId=1911 SymbolicName=OR_INVALID_OID Language=DEU -Ungültiger Treiber +Ungültiger Treiber . MessageId=1912 SymbolicName=OR_INVALID_SET diff --git a/dlls/kernel32/nls/winerr_enu.mc b/dlls/kernel32/nls/winerr_enu.mc index 0c3aee43597..c615e2ad79f 100644 --- a/dlls/kernel32/nls/winerr_enu.mc +++ b/dlls/kernel32/nls/winerr_enu.mc @@ -786,7 +786,7 @@ Auto data segment exceeds 64k MessageId=200 SymbolicName=ERROR_RING2SEG_MUST_BE_MOVABLE Language=ENU -Ring 2 segment must be movable +Ring 2 segment must be moveable . MessageId=201 SymbolicName=ERROR_RELOC_CHAIN_XEEDS_SEGLIM @@ -1356,7 +1356,7 @@ No media in drive MessageId=1113 SymbolicName=ERROR_NO_UNICODE_TRANSLATION Language=ENU -No Unicode translation +No unicode translation . MessageId=1114 SymbolicName=ERROR_DLL_INIT_FAILED @@ -1756,7 +1756,7 @@ Connection refused MessageId=1226 SymbolicName=ERROR_GRACEFUL_DISCONNECT Language=ENU -Connection gracefully closed +Conection gracefully closed . MessageId=1227 SymbolicName=ERROR_ADDRESS_ALREADY_ASSOCIATED @@ -2226,7 +2226,7 @@ Bad logon session state MessageId=1366 SymbolicName=ERROR_LOGON_SESSION_COLLISION Language=ENU -Logon session ID collision +Logon sesion ID collision . MessageId=1367 SymbolicName=ERROR_INVALID_LOGON_TYPE @@ -3256,17 +3256,17 @@ Address error MessageId=1769 SymbolicName=RPC_S_FP_DIV_ZERO Language=ENU -Floating-point divide-by-zero +Floating divide-by-zero . MessageId=1770 SymbolicName=RPC_S_FP_UNDERFLOW Language=ENU -Floating-point underflow +Floating underflow . MessageId=1771 SymbolicName=RPC_S_FP_OVERFLOW Language=ENU -Floating-point overflow +Floating overlow . MessageId=1772 SymbolicName=RPC_X_NO_MORE_ENTRIES @@ -3728,8 +3728,3 @@ SymbolicName=RPC_S_GRP_ELT_NOT_REMOVED Language=ENU RPC_S_GRP_ELT_NOT_REMOVED . -MessageId=2221 -SymbolicName=NERR_UserNotFound -Language=ENU -The username could not be found -. diff --git a/dlls/kernel32/nls/winerr_fra.mc b/dlls/kernel32/nls/winerr_fra.mc index 7b3e6b655ce..510c3ed39f5 100644 --- a/dlls/kernel32/nls/winerr_fra.mc +++ b/dlls/kernel32/nls/winerr_fra.mc @@ -1,6 +1,5 @@ ; ; Copyright 2006-2007 Jonathan Ernst -; Copyright 2009 Frédéric Delanoy ; ; This library is free software; you can redistribute it and/or ; modify it under the terms of the GNU Lesser General Public @@ -18,12 +17,11 @@ ; LanguageNames=(FRA=0x0c:winerr) -CodePages=(FRA=65001:0) MessageId=0 SymbolicName=ERROR_SUCCESS Language=FRA -Succès +Succès . MessageId=1 SymbolicName=ERROR_INVALID_FUNCTION @@ -48,22 +46,22 @@ Trop de fichiers ouverts MessageId=5 SymbolicName=ERROR_ACCESS_DENIED Language=FRA -Accès refusé +Accès refusé . MessageId=6 SymbolicName=ERROR_INVALID_HANDLE Language=FRA -Descripteur invalide +Attache invalide . MessageId=7 SymbolicName=ERROR_ARENA_TRASHED Language=FRA -Mémoire invalidée +Mémoire invalidée . MessageId=8 SymbolicName=ERROR_NOT_ENOUGH_MEMORY Language=FRA -Pas assez de mémoire +Pas assez de mémoire . MessageId=9 SymbolicName=ERROR_INVALID_BLOCK @@ -83,17 +81,17 @@ Format incorrect MessageId=12 SymbolicName=ERROR_INVALID_ACCESS Language=FRA -Accès invalide +Accès invalide . MessageId=13 SymbolicName=ERROR_INVALID_DATA Language=FRA -Données invalides +Données invalides . MessageId=14 SymbolicName=ERROR_OUTOFMEMORY Language=FRA -Mémoire insuffisante +Mémoire insuffisante . MessageId=15 SymbolicName=ERROR_INVALID_DRIVE @@ -103,32 +101,32 @@ Lecteur invalide MessageId=16 SymbolicName=ERROR_CURRENT_DIRECTORY Language=FRA -Impossible de supprimer le répertoire courant +Impossible de supprimer le répertoire courant . MessageId=17 SymbolicName=ERROR_NOT_SAME_DEVICE Language=FRA -Périphérique différent +Périphérique différent . MessageId=18 SymbolicName=ERROR_NO_MORE_FILES Language=FRA -Il n'y a plus de fichiers +Plus de fichiers . MessageId=19 SymbolicName=ERROR_WRITE_PROTECT Language=FRA -Protégé contre l'écriture +Protégé contre l'écriture . MessageId=20 SymbolicName=ERROR_BAD_UNIT Language=FRA -Unité incorrecte +Unité incorrecte . MessageId=21 SymbolicName=ERROR_NOT_READY Language=FRA -Pas prêt +Non prêt . MessageId=22 SymbolicName=ERROR_BAD_COMMAND @@ -163,12 +161,12 @@ Secteur introuvable MessageId=28 SymbolicName=ERROR_OUT_OF_PAPER Language=FRA -Il n'a plus de papier +Plus de papier . MessageId=29 SymbolicName=ERROR_WRITE_FAULT Language=FRA -Erreur d'écriture +Erreur d'écriture . MessageId=30 SymbolicName=ERROR_READ_FAULT @@ -178,7 +176,7 @@ Erreur de lecture MessageId=31 SymbolicName=ERROR_GEN_FAILURE Language=FRA -Erreur générale +Erreur générale . MessageId=32 SymbolicName=ERROR_SHARING_VIOLATION @@ -193,17 +191,17 @@ Violation de verrou MessageId=34 SymbolicName=ERROR_WRONG_DISK Language=FRA -Disque inadéquat +Mauvais disque . MessageId=36 SymbolicName=ERROR_SHARING_BUFFER_EXCEEDED Language=FRA -Capacité du tampon de partage dépassée +Tampon de partage dépassé . MessageId=38 SymbolicName=ERROR_HANDLE_EOF Language=FRA -Fin de fichier atteinte +Fin de fichier . MessageId=39 SymbolicName=ERROR_HANDLE_DISK_FULL @@ -213,32 +211,32 @@ Disque plein MessageId=50 SymbolicName=ERROR_NOT_SUPPORTED Language=FRA -Demande non prise en charge +Requête non supportée . MessageId=51 SymbolicName=ERROR_REM_NOT_LIST Language=FRA -La machine distante n'écoute pas +La machine distante n'écoute pas . MessageId=52 SymbolicName=ERROR_DUP_NAME Language=FRA -Nom réseau dupliqué +Nom réseau dupliqué . MessageId=53 SymbolicName=ERROR_BAD_NETPATH Language=FRA -Chemin réseau incorrect +Chemin réseau incorrect . MessageId=54 SymbolicName=ERROR_NETWORK_BUSY Language=FRA -Réseau occupé +Réseau occupé . MessageId=55 SymbolicName=ERROR_DEV_NOT_EXIST Language=FRA -Le périphérique n'existe pas +Le périphérique n'existe pas . MessageId=56 SymbolicName=ERROR_TOO_MANY_CMDS @@ -248,17 +246,17 @@ Trop de commandes MessageId=57 SymbolicName=ERROR_ADAP_HDW_ERR Language=FRA -Erreur matérielle de l'adaptateur +Erreur matérielle de l'adaptateur . MessageId=58 SymbolicName=ERROR_BAD_NET_RESP Language=FRA -Réponse du réseau incorrecte +Réponse du réseau incorrecte . MessageId=59 SymbolicName=ERROR_UNEXP_NET_ERR Language=FRA -Erreur réseau inattendue +Erreur réseau inattendue . MessageId=60 SymbolicName=ERROR_BAD_REM_ADAP @@ -268,7 +266,7 @@ Adaptateur distant incorrect MessageId=61 SymbolicName=ERROR_PRINTQ_FULL Language=FRA -File d'attente d'impression pleine +Queue d'impression pleine . MessageId=62 SymbolicName=ERROR_NO_SPOOL_SPACE @@ -278,52 +276,52 @@ Pas d'espace de spool MessageId=63 SymbolicName=ERROR_PRINT_CANCELLED Language=FRA -Impression annulée +Impression annulée . MessageId=64 SymbolicName=ERROR_NETNAME_DELETED Language=FRA -Nom réseau supprimé +Nom réseau supprimé . MessageId=65 SymbolicName=ERROR_NETWORK_ACCESS_DENIED Language=FRA -Accès réseau refusé +Accès réseau refusé . MessageId=66 SymbolicName=ERROR_BAD_DEV_TYPE Language=FRA -Type de périphérique incorrect +Type de périphérique incorrect . MessageId=67 SymbolicName=ERROR_BAD_NET_NAME Language=FRA -Nom réseau introuvable +Nom réseau incorrect . MessageId=68 SymbolicName=ERROR_TOO_MANY_NAMES Language=FRA -Trop de noms réseau +Trop de noms réseau . MessageId=69 SymbolicName=ERROR_TOO_MANY_SESS Language=FRA -Trop de sessions réseau +Trop de sessions réseau . MessageId=70 SymbolicName=ERROR_SHARING_PAUSED Language=FRA -Partage suspendu +Partage en pause . MessageId=71 SymbolicName=ERROR_REQ_NOT_ACCEP Language=FRA -Demande non acceptée +Requête non acceptée . MessageId=72 SymbolicName=ERROR_REDIR_PAUSED Language=FRA -Redirecteur suspendu +Redirecteur en pause . MessageId=80 SymbolicName=ERROR_FILE_EXISTS @@ -333,7 +331,7 @@ Le fichier existe MessageId=82 SymbolicName=ERROR_CANNOT_MAKE Language=FRA -Impossible de créer +Impossible de créer . MessageId=83 SymbolicName=ERROR_FAIL_I24 @@ -343,12 +341,12 @@ Erreur Int24 MessageId=84 SymbolicName=ERROR_OUT_OF_STRUCTURES Language=FRA -À cours de structures +À cours de structures . MessageId=85 SymbolicName=ERROR_ALREADY_ASSIGNED Language=FRA -Déjà assigné +Déjà assigné . MessageId=86 SymbolicName=ERROR_INVALID_PASSWORD @@ -358,12 +356,12 @@ Mot de passe non valide MessageId=87 SymbolicName=ERROR_INVALID_PARAMETER Language=FRA -Paramètre non valide +Paramètre non valide . MessageId=88 SymbolicName=ERROR_NET_WRITE_FAULT Language=FRA -Erreur en écriture sur le réseau +Erreur d'écriture réseau . MessageId=89 SymbolicName=ERROR_NO_PROC_SLOTS @@ -373,22 +371,22 @@ Plus d'emplacement pour processus MessageId=100 SymbolicName=ERROR_TOO_MANY_SEMAPHORES Language=FRA -Trop de sémaphores +Trop de sémaphores . MessageId=101 SymbolicName=ERROR_EXCL_SEM_ALREADY_OWNED Language=FRA -Sémaphore exclusif déjà acquis +Sémaphore exclusif déjà acquis . MessageId=102 SymbolicName=ERROR_SEM_IS_SET Language=FRA -Le sémaphore est actif +Le sémaphore est actif . MessageId=103 SymbolicName=ERROR_TOO_MANY_SEM_REQUESTS Language=FRA -Trop de requêtes de sémaphores +Trop de requêtes de sémaphores . MessageId=104 SymbolicName=ERROR_INVALID_AT_INTERRUPT_TIME @@ -398,22 +396,22 @@ Non valide au moment de l'interruption MessageId=105 SymbolicName=ERROR_SEM_OWNER_DIED Language=FRA -L'acquéreur du sémaphore est mort +L'acquéreur du sémaphore est mort . MessageId=106 SymbolicName=ERROR_SEM_USER_LIMIT Language=FRA -Limite utilisateur pour le sémaphore +Limite utilisateur pour le sémaphore . MessageId=107 SymbolicName=ERROR_DISK_CHANGE Language=FRA -Insérez le disque pour le lecteur %1 +Insérez le disque pour le lecteur %1 . MessageId=108 SymbolicName=ERROR_DRIVE_LOCKED Language=FRA -Lecteur verrouillé +Lecteur verrouillé . MessageId=109 SymbolicName=ERROR_BROKEN_PIPE @@ -423,12 +421,12 @@ Tube interrompu MessageId=110 SymbolicName=ERROR_OPEN_FAILED Language=FRA -Échec lors de l'ouverture +Échec lors de l'ouverture . MessageId=111 SymbolicName=ERROR_BUFFER_OVERFLOW Language=FRA -Dépassement de tampon +Dépassement de tampon . MessageId=112 SymbolicName=ERROR_DISK_FULL @@ -438,12 +436,12 @@ Disque plein MessageId=113 SymbolicName=ERROR_NO_MORE_SEARCH_HANDLES Language=FRA -Il n'y a plus de descripteurs de recherche +Plus d'attaches de recherche . MessageId=114 SymbolicName=ERROR_INVALID_TARGET_HANDLE Language=FRA -Descripteur de fichier cible non valide +Attache de destination non valide . MessageId=117 SymbolicName=ERROR_INVALID_CATEGORY @@ -453,7 +451,7 @@ IOCTL non valide MessageId=118 SymbolicName=ERROR_INVALID_VERIFY_SWITCH Language=FRA -Commutateur de vérification non valide +Bascule de vérification non valide . MessageId=119 SymbolicName=ERROR_BAD_DRIVER_LEVEL @@ -463,17 +461,17 @@ Niveau de pilote incorrect MessageId=120 SymbolicName=ERROR_CALL_NOT_IMPLEMENTED Language=FRA -Appel non implémenté +Appel non implémenté . MessageId=121 SymbolicName=ERROR_SEM_TIMEOUT Language=FRA -Dépassement du délai d'expiration du sémaphore +Dépassement du délai du sémaphore . MessageId=122 SymbolicName=ERROR_INSUFFICIENT_BUFFER Language=FRA -Mémoire tampon insuffisante +Tampon insuffisant . MessageId=123 SymbolicName=ERROR_INVALID_NAME @@ -488,7 +486,7 @@ Niveau non valide MessageId=125 SymbolicName=ERROR_NO_VOLUME_LABEL Language=FRA -Pas d'étiquette de volume +Pas d'étiquette de volume . MessageId=126 SymbolicName=ERROR_MOD_NOT_FOUND @@ -498,457 +496,457 @@ Module introuvable MessageId=127 SymbolicName=ERROR_PROC_NOT_FOUND Language=FRA -Procédure introuvable +Procédure introuvable . MessageId=128 SymbolicName=ERROR_WAIT_NO_CHILDREN Language=FRA -Aucun processus enfant à attendre +No children to wait for . MessageId=129 SymbolicName=ERROR_CHILD_NOT_COMPLETE Language=FRA -Le processus enfant ne s'est pas terminé +Child process has not completed . MessageId=130 SymbolicName=ERROR_DIRECT_ACCESS_HANDLE Language=FRA -Utilisation non valide d'un descripteur d'accès direct +Invalid use of direct access handle . MessageId=131 SymbolicName=ERROR_NEGATIVE_SEEK Language=FRA -Positionnement négatif +Negative seek . MessageId=132 SymbolicName=ERROR_SEEK_ON_DEVICE Language=FRA -Erreur de positionnement +Seek error . MessageId=133 SymbolicName=ERROR_IS_JOIN_TARGET Language=FRA -Le lecteur est la cible d'un JOIN +Drive is a JOIN target . MessageId=134 SymbolicName=ERROR_IS_JOINED Language=FRA -Le lecteur a déjà été JOINt +Drive is already JOINed . MessageId=135 SymbolicName=ERROR_IS_SUBSTED Language=FRA -Le lecteur a déjà été SUBSTitué +Drive is already SUBSTed . MessageId=136 SymbolicName=ERROR_NOT_JOINED Language=FRA -Le lecteur n'est pas JOINt +Drive is not JOINed . MessageId=137 SymbolicName=ERROR_NOT_SUBSTED Language=FRA -Le lecteur n'est pas SUBSTitué +Drive is not SUBSTed . MessageId=138 SymbolicName=ERROR_JOIN_TO_JOIN Language=FRA -Tentative de JOINdre sur un lecteur déjà JOINt +Attempt to JOIN onto a JOINed drive . MessageId=139 SymbolicName=ERROR_SUBST_TO_SUBST Language=FRA -Tentative de SUBSTituer sur un lecteur déjà SUBSTitué +Attempt to SUBST onto a SUBSTed drive . MessageId=140 SymbolicName=ERROR_JOIN_TO_SUBST Language=FRA -Tentative de JOINdre sur un lecteur déjà SUBSTitué +Attempt to JOIN to a SUBSTed drive . MessageId=141 SymbolicName=ERROR_SUBST_TO_JOIN Language=FRA -Tentative de SUBSTituer sur un lecteur déjà JOINt +Attempt to SUBST to a JOINed drive . MessageId=142 SymbolicName=ERROR_BUSY_DRIVE Language=FRA -Le lecteur est occupé +Le lecteur est occupé . MessageId=143 SymbolicName=ERROR_SAME_DRIVE Language=FRA -Même lecteur +Same drive . MessageId=144 SymbolicName=ERROR_DIR_NOT_ROOT Language=FRA -Pas un répertoire racine +Not toplevel directory . MessageId=145 SymbolicName=ERROR_DIR_NOT_EMPTY Language=FRA -Le répertoire n'est pas vide +Le répertoire n'est pas vide . MessageId=146 SymbolicName=ERROR_IS_SUBST_PATH Language=FRA -Le chemin est utilisé dans un SUBST +Path is in use as a SUBST . MessageId=147 SymbolicName=ERROR_IS_JOIN_PATH Language=FRA -Le chemin est utilisé dans un JOIN +Path is in use as a JOIN . MessageId=148 SymbolicName=ERROR_PATH_BUSY Language=FRA -Impossible d'utiliser le chemin actuellement +Path is busy . MessageId=149 SymbolicName=ERROR_IS_SUBST_TARGET Language=FRA -Déjà la cible d'un SUBST +Already a SUBST target . MessageId=150 SymbolicName=ERROR_SYSTEM_TRACE Language=FRA -Trace système non spécifiée ou interdite +System trace not specified or disallowed . MessageId=151 SymbolicName=ERROR_INVALID_EVENT_COUNT Language=FRA -Nombre d'événements pour DosMuxSemWait incorrect +Event count for DosMuxSemWait incorrect . MessageId=152 SymbolicName=ERROR_TOO_MANY_MUXWAITERS Language=FRA -Trop de sémaphores en attente pour DosMuxSemWait +Too many waiters for DosMuxSemWait . MessageId=153 SymbolicName=ERROR_INVALID_LIST_FORMAT Language=FRA -Liste DosSemMuxWait non valide +DosSemMuxWait list invalid . MessageId=154 SymbolicName=ERROR_LABEL_TOO_LONG Language=FRA -Étiquette de volume trop longue +Volume label too long . MessageId=155 SymbolicName=ERROR_TOO_MANY_TCBS Language=FRA -Trop de blocs de contrôle de tâche (TCB) +Too many TCBs . MessageId=156 SymbolicName=ERROR_SIGNAL_REFUSED Language=FRA -Signal refusé +Signal refused . MessageId=157 SymbolicName=ERROR_DISCARDED Language=FRA -Segment rejeté +Segment discarded . MessageId=158 SymbolicName=ERROR_NOT_LOCKED Language=FRA -Segment non verrouillé +Segment not locked . MessageId=159 SymbolicName=ERROR_BAD_THREADID_ADDR Language=FRA -Adresse de l'ID de thread incorrecte +Bad thread ID address . MessageId=160 SymbolicName=ERROR_BAD_ARGUMENTS Language=FRA -Arguments invalides pour DosExecPgm +Bad arguments to DosExecPgm . MessageId=161 SymbolicName=ERROR_BAD_PATHNAME Language=FRA -Chemin invalide +Path is invalid . MessageId=162 SymbolicName=ERROR_SIGNAL_PENDING Language=FRA -Signal déjà en attente +Signal pending . MessageId=164 SymbolicName=ERROR_MAX_THRDS_REACHED Language=FRA -Nombre maximal de threads du système atteint +Max systemwide thread count reached . MessageId=167 SymbolicName=ERROR_LOCK_FAILED Language=FRA -Verrouillage impossible +Lock failed . MessageId=170 SymbolicName=ERROR_BUSY Language=FRA -Ressource en cours d'utilisation +Resource in use . MessageId=173 SymbolicName=ERROR_CANCEL_VIOLATION Language=FRA -Violation de la zone d'annulation +Cancel violation . MessageId=174 SymbolicName=ERROR_ATOMIC_LOCKS_NOT_SUPPORTED Language=FRA -Verrous atomiques non pris en charge +Atomic locks not supported . MessageId=180 SymbolicName=ERROR_INVALID_SEGMENT_NUMBER Language=FRA -Numéro de segment invalide +Invalid segment number . MessageId=182 SymbolicName=ERROR_INVALID_ORDINAL Language=FRA -%1 a un ordinal invalide +Invalid ordinal for %1 . MessageId=183 SymbolicName=ERROR_ALREADY_EXISTS Language=FRA -Le fichier existe déjà +File already exists . MessageId=186 SymbolicName=ERROR_INVALID_FLAG_NUMBER Language=FRA -Numéro d'indicateur non valide +Invalid flag number . MessageId=187 SymbolicName=ERROR_SEM_NOT_FOUND Language=FRA -Nom du sémaphore introuvable +Semaphore name not found . MessageId=188 SymbolicName=ERROR_INVALID_STARTING_CODESEG Language=FRA -Segment de code de démarrage non valide pour %1 +Invalid starting code segment for %1 . MessageId=189 SymbolicName=ERROR_INVALID_STACKSEG Language=FRA -Segment de pile de démarrage non valide pour %1 +Invalid starting stack segment for %1 . MessageId=190 SymbolicName=ERROR_INVALID_MODULETYPE Language=FRA -Type de module non valide pour %1 +Invalid module type for %1 . MessageId=191 SymbolicName=ERROR_INVALID_EXE_SIGNATURE Language=FRA -Signature d'EXE invalide dans %1 +Invalid EXE signature in %1 . MessageId=192 SymbolicName=ERROR_EXE_MARKED_INVALID Language=FRA -L'EXE %1 est marqué comme non valide +EXE %1 is marked invalid . MessageId=193 SymbolicName=ERROR_BAD_EXE_FORMAT Language=FRA -Mauvais format EXE pour %1 +Bad EXE format for %1 . MessageId=194 SymbolicName=ERROR_ITERATED_DATA_EXCEEDS_64k Language=FRA -La taille des données d'itération dépasse 64 Ko dans %1 +Iterated data exceeds 64k in %1 . MessageId=195 SymbolicName=ERROR_INVALID_MINALLOCSIZE Language=FRA -MinAllocSize invalide dans %1 +Invalid MinAllocSize in %1 . MessageId=196 SymbolicName=ERROR_DYNLINK_FROM_INVALID_RING Language=FRA -Dynlink pour un anneau invalide +Dynlink from invalid ring . MessageId=197 SymbolicName=ERROR_IOPL_NOT_ENABLED Language=FRA -IOPL non activé +IOPL not enabled . MessageId=198 SymbolicName=ERROR_INVALID_SEGDPL Language=FRA -SEGDPL invalide dans %1 +Invalid SEGDPL in %1 . MessageId=199 SymbolicName=ERROR_AUTODATASEG_EXCEEDS_64k Language=FRA -La taille du segment des données automatiques dépasse 64 Ko +Auto data segment exceeds 64k . MessageId=200 SymbolicName=ERROR_RING2SEG_MUST_BE_MOVABLE Language=FRA -Le segment de l'anneau 2 doit être déplaçable +Ring 2 segment must be moveable . MessageId=201 SymbolicName=ERROR_RELOC_CHAIN_XEEDS_SEGLIM Language=FRA -La chaîne de réadressage dépasse la limite du segment dans %1 +Relocation chain exceeds segment limit in %1 . MessageId=202 SymbolicName=ERROR_INFLOOP_IN_RELOC_CHAIN Language=FRA -Boucle infinie dans la chaîne de réadressage dans %1 +Infinite loop in relocation chain in %1 . MessageId=203 SymbolicName=ERROR_ENVVAR_NOT_FOUND Language=FRA -Variable d'environnement non trouvée +Environment variable not found . MessageId=205 SymbolicName=ERROR_NO_SIGNAL_SENT Language=FRA -Aucun signal envoyé +No signal sent . MessageId=206 SymbolicName=ERROR_FILENAME_EXCED_RANGE Language=FRA -Nom de fichier trop long +File name is too long . MessageId=207 SymbolicName=ERROR_RING2_STACK_IN_USE Language=FRA -Pile de l'anneau 2 actuellement utilisée +Ring 2 stack in use . MessageId=208 SymbolicName=ERROR_META_EXPANSION_TOO_LONG Language=FRA -Erreur dans l'utilisation de caractères génériques dans les noms de fichiers +Error in use of filename wildcards . MessageId=209 SymbolicName=ERROR_INVALID_SIGNAL_NUMBER Language=FRA -Numéro de signal non valide +Invalid signal number . MessageId=210 SymbolicName=ERROR_THREAD_1_INACTIVE Language=FRA -Erreur lors de l'installation du gestionnaire de signaux +Error setting signal handler . MessageId=212 SymbolicName=ERROR_LOCKED Language=FRA -Segment verrouillé +Segment locked . MessageId=214 SymbolicName=ERROR_TOO_MANY_MODULES Language=FRA -Trop de modules +Too many modules . MessageId=215 SymbolicName=ERROR_NESTING_NOT_ALLOWED Language=FRA -Imbrication d'appels LoadModule interdite +Nesting LoadModule calls not allowed . MessageId=216 SymbolicName=ERROR_EXE_MACHINE_TYPE_MISMATCH Language=FRA -Discordance de type de machine +Machine type mismatch . MessageId=230 SymbolicName=ERROR_BAD_PIPE Language=FRA -Mauvais canal de communication +Bad pipe . MessageId=231 SymbolicName=ERROR_PIPE_BUSY Language=FRA -Canal de communication occupé +Pipe busy . MessageId=232 SymbolicName=ERROR_NO_DATA Language=FRA -Canal de communication fermé +Pipe closed . MessageId=233 SymbolicName=ERROR_PIPE_NOT_CONNECTED Language=FRA -Canal de communication non connecté +Pipe not connected . MessageId=234 SymbolicName=ERROR_MORE_DATA Language=FRA -Données additionnelles disponibles +More data available . MessageId=240 SymbolicName=ERROR_VC_DISCONNECTED Language=FRA -Session annulée +Session cancelled . MessageId=254 SymbolicName=ERROR_INVALID_EA_NAME Language=FRA -Nom d'attribut étendu non valide +Invalid extended attribute name . MessageId=255 SymbolicName=ERROR_EA_LIST_INCONSISTENT Language=FRA -Liste d'attributs étendus non cohérente +Extended attribute list inconsistent . MessageId=259 SymbolicName=ERROR_NO_MORE_ITEMS Language=FRA -Aucune autre donnée n'est disponible +No more data available . MessageId=266 SymbolicName=ERROR_CANNOT_COPY Language=FRA -L'API Copy ne peut pas être utilisée +Cannot use Copy API . MessageId=267 SymbolicName=ERROR_DIRECTORY Language=FRA -Nom de répertoire non valide +Directory name invalid . MessageId=275 SymbolicName=ERROR_EAS_DIDNT_FIT Language=FRA -Les attributs étendus ne tiennent pas dans la mémoire tampon +Extended attributes didn't fit . MessageId=276 SymbolicName=ERROR_EA_FILE_CORRUPT Language=FRA -Fichier d'attributs étendus corrompu +Extended attribute file corrupt . MessageId=277 SymbolicName=ERROR_EA_TABLE_FULL Language=FRA -Table d'attributs étendus corrompue +Extended attribute table full . MessageId=278 SymbolicName=ERROR_INVALID_EA_HANDLE Language=FRA -Descripteur d'attributs étendus non valide +Invalid extended attribute handle . MessageId=282 SymbolicName=ERROR_EAS_NOT_SUPPORTED Language=FRA -Attributs étendus non pris en charge +Extended attributes not supported . MessageId=288 SymbolicName=ERROR_NOT_OWNER Language=FRA -Mutex pas détenu par l'appelant +Mutex not owned by caller . MessageId=298 SymbolicName=ERROR_TOO_MANY_POSTS Language=FRA -Trop d'inscriptions pour le sémaphore +Too many posts to semaphore . MessageId=299 SymbolicName=ERROR_PARTIAL_COPY Language=FRA -Read/WriteProcessMemory partiellement effectué +Read/WriteProcessMemory partially completed . MessageId=300 SymbolicName=ERROR_OPLOCK_NOT_GRANTED @@ -963,107 +961,107 @@ ERROR_INVALID_OPLOCK_PROTOCOL MessageId=317 SymbolicName=ERROR_MR_MID_NOT_FOUND Language=FRA -Message 0x%1 introuvable dans le fichier %2 +Message 0x%1 not found in file %2 . MessageId=487 SymbolicName=ERROR_INVALID_ADDRESS Language=FRA -Adresse non valide +Invalid address . MessageId=534 SymbolicName=ERROR_ARITHMETIC_OVERFLOW Language=FRA -Débordement arithmétique +Arithmetic overflow . MessageId=535 SymbolicName=ERROR_PIPE_CONNECTED Language=FRA -Canal de communication connecté +Pipe connected . MessageId=536 SymbolicName=ERROR_PIPE_LISTENING Language=FRA -Aucun correspondant à l'écoute à l'extrémité du canal de communication +Pipe listening . MessageId=994 SymbolicName=ERROR_EA_ACCESS_DENIED Language=FRA -Accès refusé à l'attribut étendu +Extended attribute access denied . MessageId=995 SymbolicName=ERROR_OPERATION_ABORTED Language=FRA -Opération d'E/S abandonnée +I/O operation aborted . MessageId=996 SymbolicName=ERROR_IO_INCOMPLETE Language=FRA -E/S avec chevauchement inachevée +Overlapped I/O incomplete . MessageId=997 SymbolicName=ERROR_IO_PENDING Language=FRA -E/S avec chevauchement en cours +Overlapped I/O pending . MessageId=998 SymbolicName=ERROR_NOACCESS Language=FRA -Pas d'accès à l'emplacement mémoire +No access to memory location . MessageId=999 SymbolicName=ERROR_SWAPERROR Language=FRA -Erreur de pagination +Swap error . MessageId=1001 SymbolicName=ERROR_STACK_OVERFLOW Language=FRA -Dépassement de capacité de la pile +Stack overflow . MessageId=1002 SymbolicName=ERROR_INVALID_MESSAGE Language=FRA -Message invalide +Invalid message . MessageId=1003 SymbolicName=ERROR_CAN_NOT_COMPLETE Language=FRA -Ne peut terminer cette opération +Cannot complete . MessageId=1004 SymbolicName=ERROR_INVALID_FLAGS Language=FRA -Indicateurs invalides +Invalid flags . MessageId=1005 SymbolicName=ERROR_UNRECOGNIZED_VOLUME Language=FRA -Volume non reconnu +Unrecognised volume . MessageId=1006 SymbolicName=ERROR_FILE_INVALID Language=FRA -Fichier no valide +File invalid . MessageId=1007 SymbolicName=ERROR_FULLSCREEN_MODE Language=FRA -Ne peut s'exécuter en mode plein écran +Cannot run full-screen . MessageId=1008 SymbolicName=ERROR_NO_TOKEN Language=FRA -Le jeton n'existe pas +Nonexistent token . MessageId=1009 SymbolicName=ERROR_BADDB Language=FRA -Registre corrompu +Registry corrupt . MessageId=1010 SymbolicName=ERROR_BADKEY Language=FRA -Clé invalide +Invalid key . MessageId=1011 SymbolicName=ERROR_CANTOPEN @@ -1073,202 +1071,202 @@ ERROR_CANTOPEN MessageId=1012 SymbolicName=ERROR_CANTREAD Language=FRA -Ne peut lire la clé du registre +Can't read registry key . MessageId=1013 SymbolicName=ERROR_CANTWRITE Language=FRA -Ne peut écrire la clé du registre +Can't write registry key . MessageId=1014 SymbolicName=ERROR_REGISTRY_RECOVERED Language=FRA -Le registre a été restauré +Registry has been recovered . MessageId=1015 SymbolicName=ERROR_REGISTRY_CORRUPT Language=FRA -Le registre est corrompu +Registry is corrupt . MessageId=1016 SymbolicName=ERROR_REGISTRY_IO_FAILED Language=FRA -Échec d'opération d'E/S initiée par le registre +I/O to registry failed . MessageId=1017 SymbolicName=ERROR_NOT_REGISTRY_FILE Language=FRA -Pas un fichier registre +Not registry file . MessageId=1018 SymbolicName=ERROR_KEY_DELETED Language=FRA -Clé effacée +Key deleted . MessageId=1019 SymbolicName=ERROR_NO_LOG_SPACE Language=FRA -Pas assez d'espace disponible pour le journal du registre +No registry log space . MessageId=1020 SymbolicName=ERROR_KEY_HAS_CHILDREN Language=FRA -La clé de registre a des sous-clés +Registry key has subkeys . MessageId=1021 SymbolicName=ERROR_CHILD_MUST_BE_VOLATILE Language=FRA -La sous-clé doit être volatile +Subkey must be volatile . MessageId=1022 SymbolicName=ERROR_NOTIFY_ENUM_DIR Language=FRA -Demande de modification de notification en cours +Notify change request in progress . MessageId=1051 SymbolicName=ERROR_DEPENDENT_SERVICES_RUNNING Language=FRA -Les services dépendants sont en cours d'exécution +Dependent services are running . MessageId=1052 SymbolicName=ERROR_INVALID_SERVICE_CONTROL Language=FRA -Code de contrôle de service invalide +Invalid service control . MessageId=1053 SymbolicName=ERROR_SERVICE_REQUEST_TIMEOUT Language=FRA -Expiration du délai d'attente du service +Service request timeout . MessageId=1054 SymbolicName=ERROR_SERVICE_NO_THREAD Language=FRA -Ne peut créer de thread de service +Cannot create service thread . MessageId=1055 SymbolicName=ERROR_SERVICE_DATABASE_LOCKED Language=FRA -Base de données de services verrouillée +Service database locked . MessageId=1056 SymbolicName=ERROR_SERVICE_ALREADY_RUNNING Language=FRA -Service déjà en cours d'exécution +Service already running . MessageId=1057 SymbolicName=ERROR_INVALID_SERVICE_ACCOUNT Language=FRA -Nom de compte de service invalide +Invalid service account . MessageId=1058 SymbolicName=ERROR_SERVICE_DISABLED Language=FRA -Service désactivé +Service is disabled . MessageId=1059 SymbolicName=ERROR_CIRCULAR_DEPENDENCY Language=FRA -Dépendance circulaire +Circular dependency . MessageId=1060 SymbolicName=ERROR_SERVICE_DOES_NOT_EXIST Language=FRA -Le service n'existe pas +Service does not exist . MessageId=1061 SymbolicName=ERROR_SERVICE_CANNOT_ACCEPT_CTRL Language=FRA -Le service ne peut accepter de message de contrôle +Service cannot accept control message . MessageId=1062 SymbolicName=ERROR_SERVICE_NOT_ACTIVE Language=FRA -Service non actif +Service not active . MessageId=1063 SymbolicName=ERROR_FAILED_SERVICE_CONTROLLER_CONNECT Language=FRA -Échec de connexion au contrôleur de service +Service controller connect failed . MessageId=1064 SymbolicName=ERROR_EXCEPTION_IN_SERVICE Language=FRA -Exception durant l'exécution du service +Exception in service . MessageId=1065 SymbolicName=ERROR_DATABASE_DOES_NOT_EXIST Language=FRA -La base de données n'existe pas +Database does not exist . MessageId=1066 SymbolicName=ERROR_SERVICE_SPECIFIC_ERROR Language=FRA -Erreur spécifique au service +Service-specific error . MessageId=1067 SymbolicName=ERROR_PROCESS_ABORTED Language=FRA -Le processus s'est arrêté brutalement +Process aborted . MessageId=1068 SymbolicName=ERROR_SERVICE_DEPENDENCY_FAIL Language=FRA -Dépendances du service non démarrées/ables +Service dependency failed . MessageId=1069 SymbolicName=ERROR_SERVICE_LOGON_FAILED Language=FRA -Échec de connexion du service +Service login failed . MessageId=1070 SymbolicName=ERROR_SERVICE_START_HANG Language=FRA -Blocage lors du démarrage du service +Service start-hang . MessageId=1071 SymbolicName=ERROR_INVALID_SERVICE_LOCK Language=FRA -Verrou des services invalide +Invalid service lock . MessageId=1072 SymbolicName=ERROR_SERVICE_MARKED_FOR_DELETE Language=FRA -Service marqué pour suppression +Service marked for delete . MessageId=1073 SymbolicName=ERROR_SERVICE_EXISTS Language=FRA -Le service existe déjà +Service exists . MessageId=1074 SymbolicName=ERROR_ALREADY_RUNNING_LKG Language=FRA -Le système s'exécute déjà sous la dernière bonne configuration connue +System running last-known-good config . MessageId=1075 SymbolicName=ERROR_SERVICE_DEPENDENCY_DELETED Language=FRA -Dépendance(s) du service supprimée(s) +Service dependency deleted . MessageId=1076 SymbolicName=ERROR_BOOT_ALREADY_ACCEPTED Language=FRA -Démarrage déjà accepté comme dernière configuration correcte +Boot already accepted as last-good config . MessageId=1077 SymbolicName=ERROR_SERVICE_NEVER_STARTED Language=FRA -Service non démarré depuis le dernier démarrage +Service not started since last boot . MessageId=1078 SymbolicName=ERROR_DUPLICATE_SERVICE_NAME Language=FRA -Nom de service dupliqué +Duplicate service name . MessageId=1079 SymbolicName=ERROR_DIFFERENT_SERVICE_ACCOUNT Language=FRA -Nom de compte du service différent +Different service account . MessageId=1080 SymbolicName=ERROR_CANNOT_DETECT_DRIVER_FAILURE @@ -1293,222 +1291,222 @@ ERROR_SERVICE_NOT_IN_EXE MessageId=1100 SymbolicName=ERROR_END_OF_MEDIA Language=FRA -Fin du support +End of media . MessageId=1101 SymbolicName=ERROR_FILEMARK_DETECTED Language=FRA -Marque de fichier détectée +Filemark detected . MessageId=1102 SymbolicName=ERROR_BEGINNING_OF_MEDIA Language=FRA -Début du support +Beginning of media . MessageId=1103 SymbolicName=ERROR_SETMARK_DETECTED Language=FRA -Marque de groupe de fichiers détectée +Setmark detected . MessageId=1104 SymbolicName=ERROR_NO_DATA_DETECTED Language=FRA -Aucune donnée détectée +No data detected . MessageId=1105 SymbolicName=ERROR_PARTITION_FAILURE Language=FRA -Échec du partitionnement +Partition failure . MessageId=1106 SymbolicName=ERROR_INVALID_BLOCK_LENGTH Language=FRA -Longueur de bloc invalide +Invalid block length . MessageId=1107 SymbolicName=ERROR_DEVICE_NOT_PARTITIONED Language=FRA -Périphérique non partitionné +Device not partitioned . MessageId=1108 SymbolicName=ERROR_UNABLE_TO_LOCK_MEDIA Language=FRA -Impossible de verrouiller le support +Unable to lock media . MessageId=1109 SymbolicName=ERROR_UNABLE_TO_UNLOAD_MEDIA Language=FRA -Impossible de décharger le support +Unable to unload media . MessageId=1110 SymbolicName=ERROR_MEDIA_CHANGED Language=FRA -Le support a été remplacé +Media changed . MessageId=1111 SymbolicName=ERROR_BUS_RESET Language=FRA -Réinitialisation du bus d'E/S +I/O bus reset . MessageId=1112 SymbolicName=ERROR_NO_MEDIA_IN_DRIVE Language=FRA -Aucun support dans le lecteur +No media in drive . MessageId=1113 SymbolicName=ERROR_NO_UNICODE_TRANSLATION Language=FRA -Pas de traduction Unicode +No unicode translation . MessageId=1114 SymbolicName=ERROR_DLL_INIT_FAILED Language=FRA -Échec d'initialisation de la DLL +DLL init failed . MessageId=1115 SymbolicName=ERROR_SHUTDOWN_IN_PROGRESS Language=FRA -Arrêt du système en cours +Shutdown in progress . MessageId=1116 SymbolicName=ERROR_NO_SHUTDOWN_IN_PROGRESS Language=FRA -Aucun arrêt du système en cours +No shutdown in progress . MessageId=1117 SymbolicName=ERROR_IO_DEVICE Language=FRA -Erreur de périphérique d'E/S +I/O device error . MessageId=1118 SymbolicName=ERROR_SERIAL_NO_DEVICE Language=FRA -Aucun périphérique série trouvé +No serial devices found . MessageId=1119 SymbolicName=ERROR_IRQ_BUSY Language=FRA -IRQ partagée active +Shared IRQ busy . MessageId=1120 SymbolicName=ERROR_MORE_WRITES Language=FRA -E/S série terminée +Serial I/O completed . MessageId=1121 SymbolicName=ERROR_COUNTER_TIMEOUT Language=FRA -Expiration de la temporisation du compteur d'E/S série +Serial I/O counter timeout . MessageId=1122 SymbolicName=ERROR_FLOPPY_ID_MARK_NOT_FOUND Language=FRA -Marque d'adresse d'ID de disquette non trouvée +Floppy ID address mark not found . MessageId=1123 SymbolicName=ERROR_FLOPPY_WRONG_CYLINDER Language=FRA -Mauvais cylindre annoncé par le contrôleur de disquette +Floppy reports wrong cylinder . MessageId=1124 SymbolicName=ERROR_FLOPPY_UNKNOWN_ERROR Language=FRA -Erreur indéterminée du contrôleur de disquette +Unknown floppy error . MessageId=1125 SymbolicName=ERROR_FLOPPY_BAD_REGISTERS Language=FRA -Registres associées au contrôleur de disquettes incohérents +Floppy registers inconsistent . MessageId=1126 SymbolicName=ERROR_DISK_RECALIBRATE_FAILED Language=FRA -Échec de recalibration du disque dur +Hard disk recalibrate failed . MessageId=1127 SymbolicName=ERROR_DISK_OPERATION_FAILED Language=FRA -Échec d'une opération sur le disque dur +Hard disk operation failed . MessageId=1128 SymbolicName=ERROR_DISK_RESET_FAILED Language=FRA -Échec de réinitialisation du disque dur +Hard disk reset failed . MessageId=1129 SymbolicName=ERROR_EOM_OVERFLOW Language=FRA -Fin du support +End of tape media . MessageId=1130 SymbolicName=ERROR_NOT_ENOUGH_SERVER_MEMORY Language=FRA -Mémoire serveur insuffisante +Not enough server memory . MessageId=1131 SymbolicName=ERROR_POSSIBLE_DEADLOCK Language=FRA -Interblocage possible +Possible deadlock . MessageId=1132 SymbolicName=ERROR_MAPPED_ALIGNMENT Language=FRA -Alignement incorrect +Incorrect alignment . MessageId=1140 SymbolicName=ERROR_SET_POWER_STATE_VETOED Language=FRA -Veto contre une modification de l'état d'alimentation du système +Set-power-state vetoed . MessageId=1141 SymbolicName=ERROR_SET_POWER_STATE_FAILED Language=FRA -Échec de la modification de l'état d'alimentation du système +Set-power-state failed . MessageId=1142 SymbolicName=ERROR_TOO_MANY_LINKS Language=FRA -Trop de liens +Too many links . MessageId=1150 SymbolicName=ERROR_OLD_WIN_VERSION Language=FRA -Version plus récente de Windows nécessaire +Newer windows version needed . MessageId=1151 SymbolicName=ERROR_APP_WRONG_OS Language=FRA -Système d'exploitation incompatible +Wrong operating system . MessageId=1152 SymbolicName=ERROR_SINGLE_INSTANCE_APP Language=FRA -Une seule instance de l'application est autorisée +Single-instance application . MessageId=1153 SymbolicName=ERROR_RMODE_APP Language=FRA -L'application doit tourner en mode réel +Real-mode application . MessageId=1154 SymbolicName=ERROR_INVALID_DLL Language=FRA -DLL invalide +Invalid DLL . MessageId=1155 SymbolicName=ERROR_NO_ASSOCIATION Language=FRA -Aucun application associée +No associated application . MessageId=1156 SymbolicName=ERROR_DDE_FAIL Language=FRA -Échec d'échange dynamique de données (DDE) +DDE failure . MessageId=1157 SymbolicName=ERROR_DLL_NOT_FOUND Language=FRA -DLL non trouvée +DLL not found . MessageId=1158 SymbolicName=ERROR_NO_MORE_USER_HANDLES @@ -1628,247 +1626,247 @@ ERROR_JOURNAL_ENTRY_DELETED MessageId=1200 SymbolicName=ERROR_BAD_DEVICE Language=FRA -Nom de périphérique invalide +Invalid device name . MessageId=1201 SymbolicName=ERROR_CONNECTION_UNAVAIL Language=FRA -Connexion non disponible +Connection unavailable . MessageId=1202 SymbolicName=ERROR_DEVICE_ALREADY_REMEMBERED Language=FRA -Périphérique déjà mémorisé +Device already remembered . MessageId=1203 SymbolicName=ERROR_NO_NET_OR_BAD_PATH Language=FRA -Pas de réseau ou chemin erroné +No network or bad path . MessageId=1204 SymbolicName=ERROR_BAD_PROVIDER Language=FRA -Nom de fournisseur de services réseau invalide +Invalid network provider name . MessageId=1205 SymbolicName=ERROR_CANNOT_OPEN_PROFILE Language=FRA -Impossible d'ouvrir le profil de connexion réseau +Cannot open network connection profile . MessageId=1206 SymbolicName=ERROR_BAD_PROFILE Language=FRA -Profil de connexion réseau corrompu +Corrupt network connection profile . MessageId=1207 SymbolicName=ERROR_NOT_CONTAINER Language=FRA -Pas un conteneur +Not a container . MessageId=1208 SymbolicName=ERROR_EXTENDED_ERROR Language=FRA -Erreur étendue +Extended error . MessageId=1209 SymbolicName=ERROR_INVALID_GROUPNAME Language=FRA -Nom de groupe invalide +Invalid group name . MessageId=1210 SymbolicName=ERROR_INVALID_COMPUTERNAME Language=FRA -Nom d'ordinateur invalide +Invalid computer name . MessageId=1211 SymbolicName=ERROR_INVALID_EVENTNAME Language=FRA -Nom d'événement invalide +Invalid event name . MessageId=1212 SymbolicName=ERROR_INVALID_DOMAINNAME Language=FRA -Nom de domaine invalide +Invalid domain name . MessageId=1213 SymbolicName=ERROR_INVALID_SERVICENAME Language=FRA -Nom de service invalide +Invalid service name . MessageId=1214 SymbolicName=ERROR_INVALID_NETNAME Language=FRA -Nom de réseau invalide +Invalid network name . MessageId=1215 SymbolicName=ERROR_INVALID_SHARENAME Language=FRA -Nom de partage invalide +Invalid share name . MessageId=1216 SymbolicName=ERROR_INVALID_PASSWORDNAME Language=FRA -Mot de passe invalide +Invalid password . MessageId=1217 SymbolicName=ERROR_INVALID_MESSAGENAME Language=FRA -Nom de message invalide +Invalid message name . MessageId=1218 SymbolicName=ERROR_INVALID_MESSAGEDEST Language=FRA -Destination de message invalide +Invalid message destination . MessageId=1219 SymbolicName=ERROR_SESSION_CREDENTIAL_CONFLICT Language=FRA -Informations d'authentification en conflit +Session credential conflict . MessageId=1220 SymbolicName=ERROR_REMOTE_SESSION_LIMIT_EXCEEDED Language=FRA -Nombre maximal de sessions distantes dépassé +Remote session limit exceeded . MessageId=1221 SymbolicName=ERROR_DUP_DOMAINNAME Language=FRA -Nom de domaine ou groupe de travail dupliqué +Duplicate domain or workgroup name . MessageId=1222 SymbolicName=ERROR_NO_NETWORK Language=FRA -Réseau indisponible +No network . MessageId=1223 SymbolicName=ERROR_CANCELLED Language=FRA -Opération annulée par l'utilisateur +Operation cancelled by user . MessageId=1224 SymbolicName=ERROR_USER_MAPPED_FILE Language=FRA -Le fichier contient une section mappée par l'utilisateur +File has a user-mapped section . MessageId=1225 SymbolicName=ERROR_CONNECTION_REFUSED Language=FRA -Connexion refusée +Connection refused . MessageId=1226 SymbolicName=ERROR_GRACEFUL_DISCONNECT Language=FRA -Connexion fermée gracieusement +Conection gracefully closed . MessageId=1227 SymbolicName=ERROR_ADDRESS_ALREADY_ASSOCIATED Language=FRA -Adresse déjà associée au destinataire du transport +Address already associated with transport endpoint . MessageId=1228 SymbolicName=ERROR_ADDRESS_NOT_ASSOCIATED Language=FRA -Adresse non associée au destinataire du transport +Address not associated with transport endpoint . MessageId=1229 SymbolicName=ERROR_CONNECTION_INVALID Language=FRA -Connexion invalide +Connection invalid . MessageId=1230 SymbolicName=ERROR_CONNECTION_ACTIVE Language=FRA -Connexion active +Connection is active . MessageId=1231 SymbolicName=ERROR_NETWORK_UNREACHABLE Language=FRA -Réseau indisponible +Network unreachable . MessageId=1232 SymbolicName=ERROR_HOST_UNREACHABLE Language=FRA -Hôte inaccessible +Host unreachable . MessageId=1233 SymbolicName=ERROR_PROTOCOL_UNREACHABLE Language=FRA -Protocole inutilisable +Protocol unreachable . MessageId=1234 SymbolicName=ERROR_PORT_UNREACHABLE Language=FRA -Port injoignable +Port unreachable . MessageId=1235 SymbolicName=ERROR_REQUEST_ABORTED Language=FRA -Demande abandonnée +Request aborted . MessageId=1236 SymbolicName=ERROR_CONNECTION_ABORTED Language=FRA -Connexion avortée +Connection aborted . MessageId=1237 SymbolicName=ERROR_RETRY Language=FRA -Veuillez réitérer l'opération +Please retry operation . MessageId=1238 SymbolicName=ERROR_CONNECTION_COUNT_LIMIT Language=FRA -Limite du nombre de connexions atteinte +Connection count limit reached . MessageId=1239 SymbolicName=ERROR_LOGIN_TIME_RESTRICTION Language=FRA -Heure de connexion non autorisée +Login time restriction . MessageId=1240 SymbolicName=ERROR_LOGIN_WKSTA_RESTRICTION Language=FRA -Interdit de se connecter depuis cette station de travail +Login workstation restriction . MessageId=1241 SymbolicName=ERROR_INCORRECT_ADDRESS Language=FRA -Adresse réseau incorrecte +Incorrect network address . MessageId=1242 SymbolicName=ERROR_ALREADY_REGISTERED Language=FRA -Service déjà enregistré +Service already registered . MessageId=1243 SymbolicName=ERROR_SERVICE_NOT_FOUND Language=FRA -Service inconnu +Service not found . MessageId=1244 SymbolicName=ERROR_NOT_AUTHENTICATED Language=FRA -Utilisateur non authentifié +User not authenticated . MessageId=1245 SymbolicName=ERROR_NOT_LOGGED_ON Language=FRA -Utilisateur non connecté +User not logged on . MessageId=1246 SymbolicName=ERROR_CONTINUE Language=FRA -Poursuivre le travail en cours +Continue work in progress . MessageId=1247 SymbolicName=ERROR_ALREADY_INITIALIZED Language=FRA -Déjà initialisé +Already initialised . MessageId=1248 SymbolicName=ERROR_NO_MORE_DEVICES Language=FRA -Il n'y a plus de périphériques locaux +No more local devices . MessageId=1249 SymbolicName=ERROR_NO_SUCH_SITE @@ -1903,477 +1901,477 @@ ERROR_NOT_SUPPORTED_ON_SBS MessageId=1300 SymbolicName=ERROR_NOT_ALL_ASSIGNED Language=FRA -Tous les privilèges n'ont pas été accordés +Not all privileges assigned . MessageId=1301 SymbolicName=ERROR_SOME_NOT_MAPPED Language=FRA -Mappage partiel des ID de sécurité +Some security IDs not mapped . MessageId=1302 SymbolicName=ERROR_NO_QUOTAS_FOR_ACCOUNT Language=FRA -Pas de quotas pour ce compte +No quotas for account . MessageId=1303 SymbolicName=ERROR_LOCAL_USER_SESSION_KEY Language=FRA -Clé de session utilisateur locale +Local user session key . MessageId=1304 SymbolicName=ERROR_NULL_LM_PASSWORD Language=FRA -Mot de passe trop complexe pour LM +Password too complex for LM . MessageId=1305 SymbolicName=ERROR_UNKNOWN_REVISION Language=FRA -Révision inconnue +Unknown revision . MessageId=1306 SymbolicName=ERROR_REVISION_MISMATCH Language=FRA -Numéros de version incompatibles +Incompatible revision levels . MessageId=1307 SymbolicName=ERROR_INVALID_OWNER Language=FRA -Propriétaire invalide +Invalid owner . MessageId=1308 SymbolicName=ERROR_INVALID_PRIMARY_GROUP Language=FRA -Groupe primaire invalide +Invalid primary group . MessageId=1309 SymbolicName=ERROR_NO_IMPERSONATION_TOKEN Language=FRA -Pas de jeton d'emprunt d'identité utilisé +No impersonation token . MessageId=1310 SymbolicName=ERROR_CANT_DISABLE_MANDATORY Language=FRA -Ne peut désactiver un groupe obligatoire +Can't disable mandatory group . MessageId=1311 SymbolicName=ERROR_NO_LOGON_SERVERS Language=FRA -Aucun serveur de connexion disponible +No logon servers available . MessageId=1312 SymbolicName=ERROR_NO_SUCH_LOGON_SESSION Language=FRA -Cette session de connexion n'existe pas +No such logon session . MessageId=1313 SymbolicName=ERROR_NO_SUCH_PRIVILEGE Language=FRA -Privilège inconnu +No such privilege . MessageId=1314 SymbolicName=ERROR_PRIVILEGE_NOT_HELD Language=FRA -Ne bénéficie pas du privilège requis +Privilege not held . MessageId=1315 SymbolicName=ERROR_INVALID_ACCOUNT_NAME Language=FRA -Nom de compte invalide +Invalid account name . MessageId=1316 SymbolicName=ERROR_USER_EXISTS Language=FRA -L'utilisateur existe déjà +User already exists . MessageId=1317 SymbolicName=ERROR_NO_SUCH_USER Language=FRA -Utilisateur inconnu +No such user . MessageId=1318 SymbolicName=ERROR_GROUP_EXISTS Language=FRA -Le groupe existe déjà +Group already exists . MessageId=1319 SymbolicName=ERROR_NO_SUCH_GROUP Language=FRA -Groupe inconnu +No such group . MessageId=1320 SymbolicName=ERROR_MEMBER_IN_GROUP Language=FRA -Utilisateur déjà membre du groupe +User already in group . MessageId=1321 SymbolicName=ERROR_MEMBER_NOT_IN_GROUP Language=FRA -Utilisateur non membre du groupe +User not in group . MessageId=1322 SymbolicName=ERROR_LAST_ADMIN Language=FRA -Ne peut effacer le dernier utilisateur administratif +Can't delete last admin user . MessageId=1323 SymbolicName=ERROR_WRONG_PASSWORD Language=FRA -Mot de passe erroné +Wrong password . MessageId=1324 SymbolicName=ERROR_ILL_FORMED_PASSWORD Language=FRA -Le mot de passe contient des valeurs non autorisées +Ill-formed password . MessageId=1325 SymbolicName=ERROR_PASSWORD_RESTRICTION Language=FRA -Règle de mise à jour des mots de passe transgressée +Password restriction . MessageId=1326 SymbolicName=ERROR_LOGON_FAILURE Language=FRA -Impossible de se connecter +Logon failure . MessageId=1327 SymbolicName=ERROR_ACCOUNT_RESTRICTION Language=FRA -Restriction de compte utilisateur +Account restriction . MessageId=1328 SymbolicName=ERROR_INVALID_LOGON_HOURS Language=FRA -Heures de connexion non autorisées +Invalid logon hours . MessageId=1329 SymbolicName=ERROR_INVALID_WORKSTATION Language=FRA -Station de travail non autorisée +Invalid workstation . MessageId=1330 SymbolicName=ERROR_PASSWORD_EXPIRED Language=FRA -Mot de passe expiré +Password expired . MessageId=1331 SymbolicName=ERROR_ACCOUNT_DISABLED Language=FRA -Compte utilisateur désactivé +Account disabled . MessageId=1332 SymbolicName=ERROR_NONE_MAPPED Language=FRA -Aucun mappage d'ID de sécurité +No security ID mapped . MessageId=1333 SymbolicName=ERROR_TOO_MANY_LUIDS_REQUESTED Language=FRA -Trop de descripteurs d'utilisateur local (LUID) demandés +Too many LUIDs requested . MessageId=1334 SymbolicName=ERROR_LUIDS_EXHAUSTED Language=FRA -Il n'y a plus de descripteurs d'utilisateur local (LUID) disponibles +LUIDs exhausted . MessageId=1335 SymbolicName=ERROR_INVALID_SUB_AUTHORITY Language=FRA -Sous-autorité invalide +Invalid sub authority . MessageId=1336 SymbolicName=ERROR_INVALID_ACL Language=FRA -Liste de contrôle d'accès (ACL) invalide +Invalid ACL . MessageId=1337 SymbolicName=ERROR_INVALID_SID Language=FRA -ID de sécurité (SID) invalide +Invalid SID . MessageId=1338 SymbolicName=ERROR_INVALID_SECURITY_DESCR Language=FRA -Descripteur de sécurité invalide +Invalid security descriptor . MessageId=1340 SymbolicName=ERROR_BAD_INHERITANCE_ACL Language=FRA -Liste de contrôle d'accès (ACL) héritée erronée +Bad inherited ACL . MessageId=1341 SymbolicName=ERROR_SERVER_DISABLED Language=FRA -Serveur désactivé +Server disabled . MessageId=1342 SymbolicName=ERROR_SERVER_NOT_DISABLED Language=FRA -Serveur non désactivé +Server not disabled . MessageId=1343 SymbolicName=ERROR_INVALID_ID_AUTHORITY Language=FRA -Autorité d'identificateurs invalide +Invalid ID authority . MessageId=1344 SymbolicName=ERROR_ALLOTTED_SPACE_EXCEEDED Language=FRA -Espace attribué dépassé +Allotted space exceeded . MessageId=1345 SymbolicName=ERROR_INVALID_GROUP_ATTRIBUTES Language=FRA -Attributs de groupe invalides +Invalid group attributes . MessageId=1346 SymbolicName=ERROR_BAD_IMPERSONATION_LEVEL Language=FRA -Mauvais niveau d'emprunt d'identité +Bad impersonation level . MessageId=1347 SymbolicName=ERROR_CANT_OPEN_ANONYMOUS Language=FRA -Impossible d'ouvrir un jeton de sécurité de niveau anonyme +Can't open anonymous security token . MessageId=1348 SymbolicName=ERROR_BAD_VALIDATION_CLASS Language=FRA -Mauvaise classe de validation +Bad validation class . MessageId=1349 SymbolicName=ERROR_BAD_TOKEN_TYPE Language=FRA -Mauvais type de jeton +Bad token type . MessageId=1350 SymbolicName=ERROR_NO_SECURITY_ON_OBJECT Language=FRA -Aucun descripteur de sécurité sur l'objet +No security on object . MessageId=1351 SymbolicName=ERROR_CANT_ACCESS_DOMAIN_INFO Language=FRA -Ne peut accéder aux informations de domaine +Can't access domain information . MessageId=1352 SymbolicName=ERROR_INVALID_SERVER_STATE Language=FRA -État du serveur inadéquat +Invalid server state . MessageId=1353 SymbolicName=ERROR_INVALID_DOMAIN_STATE Language=FRA -État du domaine inadéquat +Invalid domain state . MessageId=1354 SymbolicName=ERROR_INVALID_DOMAIN_ROLE Language=FRA -Rôle du domaine inadéquat +Invalid domain role . MessageId=1355 SymbolicName=ERROR_NO_SUCH_DOMAIN Language=FRA -Domaine inconnu +No such domain . MessageId=1356 SymbolicName=ERROR_DOMAIN_EXISTS Language=FRA -Le domaine existe déjà +Domain already exists . MessageId=1357 SymbolicName=ERROR_DOMAIN_LIMIT_EXCEEDED Language=FRA -Limite du nombre de domaines dépassée +Domain limit exceeded . MessageId=1358 SymbolicName=ERROR_INTERNAL_DB_CORRUPTION Language=FRA -Base de données interne corrompue +Internal database corruption . MessageId=1359 SymbolicName=ERROR_INTERNAL_ERROR Language=FRA -Erreur interne +Internal error . MessageId=1360 SymbolicName=ERROR_GENERIC_NOT_MAPPED Language=FRA -Types d'accès génériques non mappés +Generic access types not mapped . MessageId=1361 SymbolicName=ERROR_BAD_DESCRIPTOR_FORMAT Language=FRA -Format de descripteur invalide +Bad descriptor format . MessageId=1362 SymbolicName=ERROR_NOT_LOGON_PROCESS Language=FRA -Pas un processus de connexion +Not a logon process . MessageId=1363 SymbolicName=ERROR_LOGON_SESSION_EXISTS Language=FRA -L'ID d'ouverture de session existe déjà +Logon session ID exists . MessageId=1364 SymbolicName=ERROR_NO_SUCH_PACKAGE Language=FRA -Package d'authentification inconnu +Unknown authentication package . MessageId=1365 SymbolicName=ERROR_BAD_LOGON_SESSION_STATE Language=FRA -Mauvais état d'ouverture de session +Bad logon session state . MessageId=1366 SymbolicName=ERROR_LOGON_SESSION_COLLISION Language=FRA -Collision d'ID d'ouverture de session +Logon sesion ID collision . MessageId=1367 SymbolicName=ERROR_INVALID_LOGON_TYPE Language=FRA -Type de connexion invalide +Invalid logon type . MessageId=1368 SymbolicName=ERROR_CANNOT_IMPERSONATE Language=FRA -Impossible d'emprunter une identité +Cannot impersonate . MessageId=1369 SymbolicName=ERROR_RXACT_INVALID_STATE Language=FRA -État de transaction invalide +Invalid transaction state . MessageId=1370 SymbolicName=ERROR_RXACT_COMMIT_FAILURE Language=FRA -Échec de validation de la base de données de sécurité +Security DB commit failure . MessageId=1371 SymbolicName=ERROR_SPECIAL_ACCOUNT Language=FRA -Compte prédéfini +Account is built-in . MessageId=1372 SymbolicName=ERROR_SPECIAL_GROUP Language=FRA -Groupe prédéfini +Group is built-in . MessageId=1373 SymbolicName=ERROR_SPECIAL_USER Language=FRA -Utilisateur prédéfini +User is built-in . MessageId=1374 SymbolicName=ERROR_MEMBERS_PRIMARY_GROUP Language=FRA -Ce groupe est le groupe principal de l'utilisateur +Group is primary for user . MessageId=1375 SymbolicName=ERROR_TOKEN_ALREADY_IN_USE Language=FRA -Jeton déjà utilisé +Token already in use . MessageId=1376 SymbolicName=ERROR_NO_SUCH_ALIAS Language=FRA -Groupe local inconnu +No such local group . MessageId=1377 SymbolicName=ERROR_MEMBER_NOT_IN_ALIAS Language=FRA -Utilisateur pas membre du groupe local +User not in local group . MessageId=1378 SymbolicName=ERROR_MEMBER_IN_ALIAS Language=FRA -Utilisateur déjà membre du groupe local +User already in local group . MessageId=1379 SymbolicName=ERROR_ALIAS_EXISTS Language=FRA -Le groupe local existe déjà +Local group already exists . MessageId=1380 SymbolicName=ERROR_LOGON_NOT_GRANTED Language=FRA -Type d'accès non accordé +Logon type not granted . MessageId=1381 SymbolicName=ERROR_TOO_MANY_SECRETS Language=FRA -Trop de secrets +Too many secrets . MessageId=1382 SymbolicName=ERROR_SECRET_TOO_LONG Language=FRA -Secret trop long +Secret too long . MessageId=1383 SymbolicName=ERROR_INTERNAL_DB_ERROR Language=FRA -Erreur interne de la base de données de sécurité +Internal security DB error . MessageId=1384 SymbolicName=ERROR_TOO_MANY_CONTEXT_IDS Language=FRA -Trop d'ID de contexte +Too many context IDs . MessageId=1385 SymbolicName=ERROR_LOGON_TYPE_NOT_GRANTED Language=FRA -Type d'accès non accordé +Logon type not granted . MessageId=1386 SymbolicName=ERROR_NT_CROSS_ENCRYPTION_REQUIRED Language=FRA -Mot de passe NT à chiffrage croisé nécessaire +Cross-encrypted NT password required . MessageId=1387 SymbolicName=ERROR_NO_SUCH_MEMBER Language=FRA -Membre inconnu +No such member . MessageId=1388 SymbolicName=ERROR_INVALID_MEMBER Language=FRA -Membre invalide +Invalid member . MessageId=1389 SymbolicName=ERROR_TOO_MANY_SIDS Language=FRA -Trop d'ID de sécurité (SID) +Too many SIDs . MessageId=1390 SymbolicName=ERROR_LM_CROSS_ENCRYPTION_REQUIRED Language=FRA -Mot de passe LM à chiffrage croisé nécessaire +Cross-encrypted LM password required . MessageId=1391 SymbolicName=ERROR_NO_INHERITANCE Language=FRA -Aucun composant héritable +No inheritable components . MessageId=1392 SymbolicName=ERROR_FILE_CORRUPT Language=FRA -Fichier ou répertoire corrompu +File or directory corrupt . MessageId=1393 SymbolicName=ERROR_DISK_CORRUPT Language=FRA -Disque corrompu +Disk is corrupt . MessageId=1394 SymbolicName=ERROR_NO_USER_SESSION_KEY Language=FRA -Pas de clé de session utilisateur disponible +No user session key . MessageId=1395 SymbolicName=ERROR_LICENSE_QUOTA_EXCEEDED Language=FRA -Quota de licences dépassé +Licence quota exceeded . MessageId=1396 SymbolicName=ERROR_WRONG_TARGET_NAME @@ -2393,287 +2391,287 @@ ERROR_TIME_SKEW MessageId=1400 SymbolicName=ERROR_INVALID_WINDOW_HANDLE Language=FRA -Descripteur de fenêtre invalide +Invalid window handle . MessageId=1401 SymbolicName=ERROR_INVALID_MENU_HANDLE Language=FRA -Descripteur de menu invalide +Invalid menu handle . MessageId=1402 SymbolicName=ERROR_INVALID_CURSOR_HANDLE Language=FRA -Descripteur de curseur invalide +Invalid cursor handle . MessageId=1403 SymbolicName=ERROR_INVALID_ACCEL_HANDLE Language=FRA -Descripteur de table d'accélérateurs invalide +Invalid accelerator table handle . MessageId=1404 SymbolicName=ERROR_INVALID_HOOK_HANDLE Language=FRA -Descripteur de crochet (hook) invalide +Invalid hook handle . MessageId=1405 SymbolicName=ERROR_INVALID_DWP_HANDLE Language=FRA -Descripteur DWP invalide +Invalid DWP handle . MessageId=1406 SymbolicName=ERROR_TLW_WITH_WSCHILD Language=FRA -Ne peut créer de fenêtre enfant supérieure +Can't create top-level child window . MessageId=1407 SymbolicName=ERROR_CANNOT_FIND_WND_CLASS Language=FRA -Classe de fenêtre introuvable +Can't find window class . MessageId=1408 SymbolicName=ERROR_WINDOW_OF_OTHER_THREAD Language=FRA -La fenêtre appartient à un autre thread +Window owned by another thread . MessageId=1409 SymbolicName=ERROR_HOTKEY_ALREADY_REGISTERED Language=FRA -Touche d'accès rapide déjà enregistrée +Hotkey already registered . MessageId=1410 SymbolicName=ERROR_CLASS_ALREADY_EXISTS Language=FRA -La classe existe déjà +Class already exists . MessageId=1411 SymbolicName=ERROR_CLASS_DOES_NOT_EXIST Language=FRA -La classe n'existe pas +Class does not exist . MessageId=1412 SymbolicName=ERROR_CLASS_HAS_WINDOWS Language=FRA -La classe a des fenêtres ouvertes +Class has open windows . MessageId=1413 SymbolicName=ERROR_INVALID_INDEX Language=FRA -Index invalide +Invalid index . MessageId=1414 SymbolicName=ERROR_INVALID_ICON_HANDLE Language=FRA -Descripteur d'icône invalide +Invalid icon handle . MessageId=1415 SymbolicName=ERROR_PRIVATE_DIALOG_INDEX Language=FRA -Index de fenêtre de dialogue privé +Private dialog index . MessageId=1416 SymbolicName=ERROR_LISTBOX_ID_NOT_FOUND Language=FRA -ID de liste de choix non trouvée +Listbox ID not found . MessageId=1417 SymbolicName=ERROR_NO_WILDCARD_CHARACTERS Language=FRA -Aucun caractère générique trouvé +No wildcard characters . MessageId=1418 SymbolicName=ERROR_CLIPBOARD_NOT_OPEN Language=FRA -Presse-papiers pas ouvert +Clipboard not open . MessageId=1419 SymbolicName=ERROR_HOTKEY_NOT_REGISTERED Language=FRA -Touche d'accès rapide non enregistrée +Hotkey not registered . MessageId=1420 SymbolicName=ERROR_WINDOW_NOT_DIALOG Language=FRA -Pas une fenêtre de dialogue +Not a dialog window . MessageId=1421 SymbolicName=ERROR_CONTROL_ID_NOT_FOUND Language=FRA -ID de contrôle non trouvable +Control ID not found . MessageId=1422 SymbolicName=ERROR_INVALID_COMBOBOX_MESSAGE Language=FRA -Message de boîte combinée invalide +Invalid combobox message . MessageId=1423 SymbolicName=ERROR_WINDOW_NOT_COMBOBOX Language=FRA -Cette fenêtre n'est pas une boîte combinée +Not a combobox window . MessageId=1424 SymbolicName=ERROR_INVALID_EDIT_HEIGHT Language=FRA -Hauteur spécifiée invalide +Invalid edit height . MessageId=1425 SymbolicName=ERROR_DC_NOT_FOUND Language=FRA -Contexte de périphérique (DC) introuvable +DC not found . MessageId=1426 SymbolicName=ERROR_INVALID_HOOK_FILTER Language=FRA -Crochet (hook) de filtrage invalide +Invalid hook filter . MessageId=1427 SymbolicName=ERROR_INVALID_FILTER_PROC Language=FRA -Procédure de filtrage invalide +Invalid filter procedure . MessageId=1428 SymbolicName=ERROR_HOOK_NEEDS_HMOD Language=FRA -La procédure de crochet nécessite un identificateur de module +Hook procedure needs module handle . MessageId=1429 SymbolicName=ERROR_GLOBAL_ONLY_HOOK Language=FRA -Procédure de crochet globale seulement +Global-only hook procedure . MessageId=1430 SymbolicName=ERROR_JOURNAL_HOOK_SET Language=FRA -Crochet de journal déjà spécifié +Journal hook already set . MessageId=1431 SymbolicName=ERROR_HOOK_NOT_INSTALLED Language=FRA -Procédure de crochet pas installée +Hook procedure not installed . MessageId=1432 SymbolicName=ERROR_INVALID_LB_MESSAGE Language=FRA -Message de liste de choix invalide +Invalid listbox message . MessageId=1433 SymbolicName=ERROR_SETCOUNT_ON_BAD_LB Language=FRA -LB_SETCOUNT invalide envoyé +Invalid LB_SETCOUNT sent . MessageId=1434 SymbolicName=ERROR_LB_WITHOUT_TABSTOPS Language=FRA -Aucune marque de tabulation dans cette liste de choix +No tabstops on this listbox . MessageId=1435 SymbolicName=ERROR_DESTROY_OBJECT_OF_OTHER_THREAD Language=FRA -Ne peut détruire un objet appartenant à un autre thread +Can't destroy object owned by another thread . MessageId=1436 SymbolicName=ERROR_CHILD_WINDOW_MENU Language=FRA -Les fenêtres enfants ne peuvent comporter de menus +Child window menus not allowed . MessageId=1437 SymbolicName=ERROR_NO_SYSTEM_MENU Language=FRA -La fenêtre ne comporte pas de menu système +Window has no system menu . MessageId=1438 SymbolicName=ERROR_INVALID_MSGBOX_STYLE Language=FRA -Style de boîte de message invalide +Invalid messagebox style . MessageId=1439 SymbolicName=ERROR_INVALID_SPI_VALUE Language=FRA -Paramètre SPI invalide +Invalid SPI parameter . MessageId=1440 SymbolicName=ERROR_SCREEN_ALREADY_LOCKED Language=FRA -Écran déjà verrouillé +Screen already locked . MessageId=1441 SymbolicName=ERROR_HWNDS_HAVE_DIFF_PARENT Language=FRA -Les identificateurs de fenêtres ont des parents distincts +Window handles have different parents . MessageId=1442 SymbolicName=ERROR_NOT_CHILD_WINDOW Language=FRA -Pas une fenêtre enfant +Not a child window . MessageId=1443 SymbolicName=ERROR_INVALID_GW_COMMAND Language=FRA -Commande GW invalide +Invalid GW command . MessageId=1444 SymbolicName=ERROR_INVALID_THREAD_ID Language=FRA -Descripteur de thread invalide +Invalid thread ID . MessageId=1445 SymbolicName=ERROR_NON_MDICHILD_WINDOW Language=FRA -Pas une fenêtre enfant à interface de documents multiples (MDI) +Not an MDI child window . MessageId=1446 SymbolicName=ERROR_POPUP_ALREADY_ACTIVE Language=FRA -Menu contextuel déjà actif +Popup menu already active . MessageId=1447 SymbolicName=ERROR_NO_SCROLLBARS Language=FRA -Aucune barre de défilement +No scrollbars . MessageId=1448 SymbolicName=ERROR_INVALID_SCROLLBAR_RANGE Language=FRA -Étendue de barre de défilement invalide +Invalid scrollbar range . MessageId=1449 SymbolicName=ERROR_INVALID_SHOWWIN_COMMAND Language=FRA -Commande ShowWin invalide +Invalid ShowWin command . MessageId=1450 SymbolicName=ERROR_NO_SYSTEM_RESOURCES Language=FRA -Ressources système insuffisantes +No system resources . MessageId=1451 SymbolicName=ERROR_NONPAGED_SYSTEM_RESOURCES Language=FRA -Ressources système non paginées insuffisantes +No nonpaged system resources . MessageId=1452 SymbolicName=ERROR_PAGED_SYSTEM_RESOURCES Language=FRA -Ressources système paginées insuffisantes +No paged system resources . MessageId=1453 SymbolicName=ERROR_WORKING_SET_QUOTA Language=FRA -Quota insuffisant pour l'espace de travail +No working set quota . MessageId=1454 SymbolicName=ERROR_PAGEFILE_QUOTA Language=FRA -Quota insuffisant pour le fichier d'échange +No pagefile quota . MessageId=1455 SymbolicName=ERROR_COMMITMENT_LIMIT Language=FRA -Dépassement de la limite d'engagement +Exceeded commitment limit . MessageId=1456 SymbolicName=ERROR_MENU_ITEM_NOT_FOUND Language=FRA -Entrée de menu non trouvée +Menu item not found . MessageId=1457 SymbolicName=ERROR_INVALID_KEYBOARD_HANDLE @@ -2703,22 +2701,22 @@ ERROR_INVALID_MONITOR_HANDLE MessageId=1500 SymbolicName=ERROR_EVENTLOG_FILE_CORRUPT Language=FRA -Fichier journal d'événements corrompu +Event log file corrupt . MessageId=1501 SymbolicName=ERROR_EVENTLOG_CANT_START Language=FRA -Impossible d'ouvrir le journal d'événements +Event log can't start . MessageId=1502 SymbolicName=ERROR_LOG_FILE_FULL Language=FRA -Le fichier journal d'événements est plein +Event log file full . MessageId=1503 SymbolicName=ERROR_EVENTLOG_FILE_CHANGED Language=FRA -Fichier journal d'événements modifié +Event log file changed . MessageId=1601 SymbolicName=ERROR_INSTALL_SERVICE_FAILURE @@ -2928,717 +2926,717 @@ ERROR_SUCCESS_REBOOT_INITIATED MessageId=1700 SymbolicName=RPC_S_INVALID_STRING_BINDING Language=FRA -Liaison de chaîne de caractères invalide +Invalid string binding . MessageId=1701 SymbolicName=RPC_S_WRONG_KIND_OF_BINDING Language=FRA -Mauvais type de liaison +Wrong kind of binding . MessageId=1702 SymbolicName=RPC_S_INVALID_BINDING Language=FRA -Liaison invalide +Invalid binding . MessageId=1703 SymbolicName=RPC_S_PROTSEQ_NOT_SUPPORTED Language=FRA -Séquence de protocole RPC non prise en charge +RPC protocol sequence not supported . MessageId=1704 SymbolicName=RPC_S_INVALID_RPC_PROTSEQ Language=FRA -Séquence de protocole RPC invalide +Invalid RPC protocol sequence . MessageId=1705 SymbolicName=RPC_S_INVALID_STRING_UUID Language=FRA -Chaîne d'identificateur unique universel (UUID) invalide +Invalid string UUID . MessageId=1706 SymbolicName=RPC_S_INVALID_ENDPOINT_FORMAT Language=FRA -Format du point d'extrémité invalide +Invalid endpoint format . MessageId=1707 SymbolicName=RPC_S_INVALID_NET_ADDR Language=FRA -Adresse réseau invalide +Invalid network address . MessageId=1708 SymbolicName=RPC_S_NO_ENDPOINT_FOUND Language=FRA -Point d'extrémité introuvable +No endpoint found . MessageId=1709 SymbolicName=RPC_S_INVALID_TIMEOUT Language=FRA -Valeur de temporisation invalide +Invalid timeout value . MessageId=1710 SymbolicName=RPC_S_OBJECT_NOT_FOUND Language=FRA -Chaîne d'identificateur unique universel (UUID) introuvable +Object UUID not found . MessageId=1711 SymbolicName=RPC_S_ALREADY_REGISTERED Language=FRA -Chaîne d'identificateur unique universel (UUID) déjà enregistrée +UUID already registered . MessageId=1712 SymbolicName=RPC_S_TYPE_ALREADY_REGISTERED Language=FRA -Type de chaîne d'identificateur unique universel (UUID) déjà enregistré +UUID type already registered . MessageId=1713 SymbolicName=RPC_S_ALREADY_LISTENING Language=FRA -Serveur RPC déjà en mode écoute +Server already listening . MessageId=1714 SymbolicName=RPC_S_NO_PROTSEQS_REGISTERED Language=FRA -Aucune séquence de protocole enregistrée +No protocol sequences registered . MessageId=1715 SymbolicName=RPC_S_NOT_LISTENING Language=FRA -Serveur RPC pas en mode écoute +RPC server not listening . MessageId=1716 SymbolicName=RPC_S_UNKNOWN_MGR_TYPE Language=FRA -Type de gestionnaire inconnu +Unknown manager type . MessageId=1717 SymbolicName=RPC_S_UNKNOWN_IF Language=FRA -Interface inconnue +Unknown interface . MessageId=1718 SymbolicName=RPC_S_NO_BINDINGS Language=FRA -Pas de liaison +No bindings . MessageId=1719 SymbolicName=RPC_S_NO_PROTSEQS Language=FRA -Pas de séquence de protocole +No protocol sequences . MessageId=1720 SymbolicName=RPC_S_CANT_CREATE_ENDPOINT Language=FRA -Ne peut créer de point d'extrémité +Can't create endpoint . MessageId=1721 SymbolicName=RPC_S_OUT_OF_RESOURCES Language=FRA -Ressources insuffisantes +Out of resources . MessageId=1722 SymbolicName=RPC_S_SERVER_UNAVAILABLE Language=FRA -Serveur RPC indisponible +RPC server unavailable . MessageId=1723 SymbolicName=RPC_S_SERVER_TOO_BUSY Language=FRA -Serveur RPC surchargé +RPC server too busy . MessageId=1724 SymbolicName=RPC_S_INVALID_NETWORK_OPTIONS Language=FRA -Options réseau invalides +Invalid network options . MessageId=1725 SymbolicName=RPC_S_NO_CALL_ACTIVE Language=FRA -Aucun appel RPC actif +No RPC call active . MessageId=1726 SymbolicName=RPC_S_CALL_FAILED Language=FRA -Échec de l'appel RPC +RPC call failed . MessageId=1727 SymbolicName=RPC_S_CALL_FAILED_DNE Language=FRA -L'appel RPC a échoué et ne s'est pas exécuté +RPC call failed and didn't execute . MessageId=1728 SymbolicName=RPC_S_PROTOCOL_ERROR Language=FRA -Erreur de protocole RPC +RPC protocol error . MessageId=1730 SymbolicName=RPC_S_UNSUPPORTED_TRANS_SYN Language=FRA -Syntaxe de transfert non prise en charge +Unsupported transfer syntax . MessageId=1732 SymbolicName=RPC_S_UNSUPPORTED_TYPE Language=FRA -Type non pris en charge +Unsupported type . MessageId=1733 SymbolicName=RPC_S_INVALID_TAG Language=FRA -Balise invalide +Invalid tag . MessageId=1734 SymbolicName=RPC_S_INVALID_BOUND Language=FRA -Limites de tableau invalides +Invalid array bounds . MessageId=1735 SymbolicName=RPC_S_NO_ENTRY_NAME Language=FRA -Pas de nom d'entrée +No entry name . MessageId=1736 SymbolicName=RPC_S_INVALID_NAME_SYNTAX Language=FRA -Syntaxe de nom invalide +Invalid name syntax . MessageId=1737 SymbolicName=RPC_S_UNSUPPORTED_NAME_SYNTAX Language=FRA -Syntaxe de nom pas prise en charge +Unsupported name syntax . MessageId=1739 SymbolicName=RPC_S_UUID_NO_ADDRESS Language=FRA -Pas d'adresse réseau +No network address . MessageId=1740 SymbolicName=RPC_S_DUPLICATE_ENDPOINT Language=FRA -Point d'extrémité dupliqué +Duplicate endpoint . MessageId=1741 SymbolicName=RPC_S_UNKNOWN_AUTHN_TYPE Language=FRA -Type d'authentification inconnue +Unknown authentication type . MessageId=1742 SymbolicName=RPC_S_MAX_CALLS_TOO_SMALL Language=FRA -Nombre maximum d'appels trop bas +Maximum calls too low . MessageId=1743 SymbolicName=RPC_S_STRING_TOO_LONG Language=FRA -Chaîne de caractères trop longue +String too long . MessageId=1744 SymbolicName=RPC_S_PROTSEQ_NOT_FOUND Language=FRA -Séquence de protocole introuvable +Protocol sequence not found . MessageId=1745 SymbolicName=RPC_S_PROCNUM_OUT_OF_RANGE Language=FRA -Numéro de procédure hors intervalle +Procedure number out of range . MessageId=1746 SymbolicName=RPC_S_BINDING_HAS_NO_AUTH Language=FRA -La liaison ne dispose d'aucun information d'authentification +Binding has no authentication data . MessageId=1747 SymbolicName=RPC_S_UNKNOWN_AUTHN_SERVICE Language=FRA -Service d'authentification inconnu +Unknown authentication service . MessageId=1748 SymbolicName=RPC_S_UNKNOWN_AUTHN_LEVEL Language=FRA -Niveau d'authentification inconnu +Unknown authentication level . MessageId=1749 SymbolicName=RPC_S_INVALID_AUTH_IDENTITY Language=FRA -Identité d'authentification invalide +Invalid authentication identity . MessageId=1750 SymbolicName=RPC_S_UNKNOWN_AUTHZ_SERVICE Language=FRA -Service d'autorisation inconnu +Unknown authorisation service . MessageId=1751 SymbolicName=EPT_S_INVALID_ENTRY Language=FRA -Entrée invalide +Invalid entry . MessageId=1752 SymbolicName=EPT_S_CANT_PERFORM_OP Language=FRA -Ne peut effectuer l'opération +Can't perform operation . MessageId=1753 SymbolicName=EPT_S_NOT_REGISTERED Language=FRA -Points d'extrémité non enregistrés +Endpoints not registered . MessageId=1754 SymbolicName=RPC_S_NOTHING_TO_EXPORT Language=FRA -Rien à exporter +Nothing to export . MessageId=1755 SymbolicName=RPC_S_INCOMPLETE_NAME Language=FRA -Nom incomplet +Incomplete name . MessageId=1756 SymbolicName=RPC_S_INVALID_VERS_OPTION Language=FRA -Option de version invalide +Invalid version option . MessageId=1757 SymbolicName=RPC_S_NO_MORE_MEMBERS Language=FRA -Il n'y a plus de membres +No more members . MessageId=1758 SymbolicName=RPC_S_NOT_ALL_OBJS_UNEXPORTED Language=FRA -Tous les objets n'ont pas été désexportés +Not all objects unexported . MessageId=1759 SymbolicName=RPC_S_INTERFACE_NOT_FOUND Language=FRA -Interface non trouvée +Interface not found . MessageId=1760 SymbolicName=RPC_S_ENTRY_ALREADY_EXISTS Language=FRA -L'entrée existe déjà +Entry already exists . MessageId=1761 SymbolicName=RPC_S_ENTRY_NOT_FOUND Language=FRA -Entrée introuvable +Entry not found . MessageId=1762 SymbolicName=RPC_S_NAME_SERVICE_UNAVAILABLE Language=FRA -Service de noms indisponible +Name service unavailable . MessageId=1763 SymbolicName=RPC_S_INVALID_NAF_ID Language=FRA -Famille d'adresses réseau invalide +Invalid network address family . MessageId=1764 SymbolicName=RPC_S_CANNOT_SUPPORT Language=FRA -Opération pas prise en charge +Operation not supported . MessageId=1765 SymbolicName=RPC_S_NO_CONTEXT_AVAILABLE Language=FRA -Aucun contexte de sécurité disponible +No security context available . MessageId=1766 SymbolicName=RPC_S_INTERNAL_ERROR Language=FRA -Erreur RPC interne +RPCInternal error . MessageId=1767 SymbolicName=RPC_S_ZERO_DIVIDE Language=FRA -Division par zéro dans le serveur RPC +RPC divide-by-zero . MessageId=1768 SymbolicName=RPC_S_ADDRESS_ERROR Language=FRA -Erreur d'adressage +Address error . MessageId=1769 SymbolicName=RPC_S_FP_DIV_ZERO Language=FRA -Division en virgule flottante par zéro +Floating divide-by-zero . MessageId=1770 SymbolicName=RPC_S_FP_UNDERFLOW Language=FRA -Dépassement de précision en virgule flottante +Floating underflow . MessageId=1771 SymbolicName=RPC_S_FP_OVERFLOW Language=FRA -Dépassement de capacité en virgule flottante +Floating overlow . MessageId=1772 SymbolicName=RPC_X_NO_MORE_ENTRIES Language=FRA -Il n'y a plus d'entrées +No more entries . MessageId=1773 SymbolicName=RPC_X_SS_CHAR_TRANS_OPEN_FAIL Language=FRA -Échec d'ouverture du fichier de table de traduction des caractères +Character translation table open failed . MessageId=1774 SymbolicName=RPC_X_SS_CHAR_TRANS_SHORT_FILE Language=FRA -Fichier de table de traduction des caractères trop petit +Character translation table file too small . MessageId=1775 SymbolicName=RPC_X_SS_IN_NULL_CONTEXT Language=FRA -Descripteur de contexte null +Null context handle . MessageId=1777 SymbolicName=RPC_X_SS_CONTEXT_DAMAGED Language=FRA -Descripteur de contexte endommagé +Context handle damaged . MessageId=1778 SymbolicName=RPC_X_SS_HANDLES_MISMATCH Language=FRA -Les descripteurs de liaison ne correspondent pas +Binding handle mismatch . MessageId=1779 SymbolicName=RPC_X_SS_CANNOT_GET_CALL_HANDLE Language=FRA -Impossible d'obtenir le descripteur d'appel +Cannot get call handle . MessageId=1780 SymbolicName=RPC_X_NULL_REF_POINTER Language=FRA -Pointeur de référence null +Null reference pointer . MessageId=1781 SymbolicName=RPC_X_ENUM_VALUE_OUT_OF_RANGE Language=FRA -Valeur d'énumération hors plage +Enumeration value out of range . MessageId=1782 SymbolicName=RPC_X_BYTE_COUNT_TOO_SMALL Language=FRA -Nombre d'octets trop petit +Byte count too small . MessageId=1783 SymbolicName=RPC_X_BAD_STUB_DATA Language=FRA -Données de squelette (stub) incorrectes +Bad stub data . MessageId=1784 SymbolicName=ERROR_INVALID_USER_BUFFER Language=FRA -Tampon utilisateur invalide +Invalid user buffer . MessageId=1785 SymbolicName=ERROR_UNRECOGNIZED_MEDIA Language=FRA -Support non reconnu +Unrecognised media . MessageId=1786 SymbolicName=ERROR_NO_TRUST_LSA_SECRET Language=FRA -Pas de secret d'approbation +No trust secret . MessageId=1787 SymbolicName=ERROR_NO_TRUST_SAM_ACCOUNT Language=FRA -Pas de compte SAM d'approbation +No trust SAM account . MessageId=1788 SymbolicName=ERROR_TRUSTED_DOMAIN_FAILURE Language=FRA -Échec du domaine approuvé +Trusted domain failure . MessageId=1789 SymbolicName=ERROR_TRUSTED_RELATIONSHIP_FAILURE Language=FRA -Échec de la relation d'approbation +Trusted relationship failure . MessageId=1790 SymbolicName=ERROR_TRUST_FAILURE Language=FRA -Échec d'approbation lors de la connexion +Trust logon failure . MessageId=1791 SymbolicName=RPC_S_CALL_IN_PROGRESS Language=FRA -Appel RPC déjà en cours +RPC call already in progress . MessageId=1792 SymbolicName=ERROR_NETLOGON_NOT_STARTED Language=FRA -NETLOGON n'est pas démarré +NETLOGON is not started . MessageId=1793 SymbolicName=ERROR_ACCOUNT_EXPIRED Language=FRA -Ce compte a expiré +Account expired . MessageId=1794 SymbolicName=ERROR_REDIRECTOR_HAS_OPEN_HANDLES Language=FRA -Le redirecteur a des descripteurs ouverts +Redirector has open handles . MessageId=1795 SymbolicName=ERROR_PRINTER_DRIVER_ALREADY_INSTALLED Language=FRA -Pilote d'imprimante déjà installé +Printer driver already installed . MessageId=1796 SymbolicName=ERROR_UNKNOWN_PORT Language=FRA -Port inconnu +Unknown port . MessageId=1797 SymbolicName=ERROR_UNKNOWN_PRINTER_DRIVER Language=FRA -Pilote d'imprimante inconnu +Unknown printer driver . MessageId=1798 SymbolicName=ERROR_UNKNOWN_PRINTPROCESSOR Language=FRA -Processeur d'impression inconnu +Unknown print processor . MessageId=1799 SymbolicName=ERROR_INVALID_SEPARATOR_FILE Language=FRA -Fichier séparateur inconnu +Invalid separator file . MessageId=1800 SymbolicName=ERROR_INVALID_PRIORITY Language=FRA -Priorité invalide +Invalid priority . MessageId=1801 SymbolicName=ERROR_INVALID_PRINTER_NAME Language=FRA -Nom d'imprimante non valide +Invalid printer name . MessageId=1802 SymbolicName=ERROR_PRINTER_ALREADY_EXISTS Language=FRA -L'imprimante existe déjà +Printer already exists . MessageId=1803 SymbolicName=ERROR_INVALID_PRINTER_COMMAND Language=FRA -Commande d'imprimante invalide +Invalid printer command . MessageId=1804 SymbolicName=ERROR_INVALID_DATATYPE Language=FRA -Type de donnée invalide +Invalid datatype . MessageId=1805 SymbolicName=ERROR_INVALID_ENVIRONMENT Language=FRA -Environnement invalide +Invalid environment . MessageId=1806 SymbolicName=RPC_S_NO_MORE_BINDINGS Language=FRA -Il n'y a plus de liaisons +No more bindings . MessageId=1807 SymbolicName=ERROR_NOLOGON_INTERDOMAIN_TRUST_ACCOUNT Language=FRA -Ne peut se connecter avec un compte d'approbation interdomaines +Can't logon with interdomain trust account . MessageId=1808 SymbolicName=ERROR_NOLOGON_WORKSTATION_TRUST_ACCOUNT Language=FRA -Ne peut se connecter avec un compte d'approbation de station de travail +Can't logon with workstation trust account . MessageId=1809 SymbolicName=ERROR_NOLOGON_SERVER_TRUST_ACCOUNT Language=FRA -Ne peut se connecter avec un compte d'approbation de serveur +Can't logon with server trust account . MessageId=1810 SymbolicName=ERROR_DOMAIN_TRUST_INCONSISTENT Language=FRA -Informations d'approbation de domaine incohérentes +Domain trust information inconsistent . MessageId=1811 SymbolicName=ERROR_SERVER_HAS_OPEN_HANDLES Language=FRA -Le serveur a des descripteurs ouverts +Server has open handles . MessageId=1812 SymbolicName=ERROR_RESOURCE_DATA_NOT_FOUND Language=FRA -Données ressources introuvables +Resource data not found . MessageId=1813 SymbolicName=ERROR_RESOURCE_TYPE_NOT_FOUND Language=FRA -Type de ressource introuvable +Resource type not found . MessageId=1814 SymbolicName=ERROR_RESOURCE_NAME_NOT_FOUND Language=FRA -Nom de ressource introuvable +Resource name not found . MessageId=1815 SymbolicName=ERROR_RESOURCE_LANG_NOT_FOUND Language=FRA -Langue des ressources introuvable +Resource language not found . MessageId=1816 SymbolicName=ERROR_NOT_ENOUGH_QUOTA Language=FRA -Quota insuffisant +Not enough quota . MessageId=1817 SymbolicName=RPC_S_NO_INTERFACES Language=FRA -Aucune interface +No interfaces . MessageId=1818 SymbolicName=RPC_S_CALL_CANCELLED Language=FRA -Appel RPC annulé +RPC call cancelled . MessageId=1819 SymbolicName=RPC_S_BINDING_INCOMPLETE Language=FRA -Liaison incomplète +Binding incomplete . MessageId=1820 SymbolicName=RPC_S_COMM_FAILURE Language=FRA -Échec de la communication RPC +RPC comm failure . MessageId=1821 SymbolicName=RPC_S_UNSUPPORTED_AUTHN_LEVEL Language=FRA -Niveau d'autorisation non pris en charge +Unsupported authorisation level . MessageId=1822 SymbolicName=RPC_S_NO_PRINC_NAME Language=FRA -Aucun nom principal déclaré +No principal name registered . MessageId=1823 SymbolicName=RPC_S_NOT_RPC_ERROR Language=FRA -Pas une erreur RPC +Not an RPC error . MessageId=1824 SymbolicName=RPC_S_UUID_LOCAL_ONLY Language=FRA -UUID valide localement uniquement +UUID is local only . MessageId=1825 SymbolicName=RPC_S_SEC_PKG_ERROR Language=FRA -Erreur du package de sécurité +Security package error . MessageId=1826 SymbolicName=RPC_S_NOT_CANCELLED Language=FRA -Thread non annulé +Thread not cancelled . MessageId=1827 SymbolicName=RPC_X_INVALID_ES_ACTION Language=FRA -Opération invalide sur un descripteur +Invalid handle operation . MessageId=1828 SymbolicName=RPC_X_WRONG_ES_VERSION Language=FRA -Version incompatible du package de sérialisation +Wrong serialising package version . MessageId=1829 SymbolicName=RPC_X_WRONG_STUB_VERSION Language=FRA -Mauvaise version de squelette +Wrong stub version . MessageId=1830 SymbolicName=RPC_X_INVALID_PIPE_OBJECT Language=FRA -Tube incorrect +Invalid pipe object . MessageId=1831 SymbolicName=RPC_X_WRONG_PIPE_ORDER Language=FRA -Commande incorrecte sur le tube +Wrong pipe order . MessageId=1832 SymbolicName=RPC_X_WRONG_PIPE_VERSION Language=FRA -Version de tube incompatible +Wrong pipe version . MessageId=1898 SymbolicName=RPC_S_GROUP_MEMBER_NOT_FOUND Language=FRA -Membre de groupe introuvable +Group member not found . MessageId=1899 SymbolicName=EPT_S_CANT_CREATE Language=FRA -Impossible de créer la base de données de mappeur de points d'extrémités +Can't create endpoint mapper DB . MessageId=1900 SymbolicName=RPC_S_INVALID_OBJECT Language=FRA -Objet invalide +Invalid object . MessageId=1901 SymbolicName=ERROR_INVALID_TIME Language=FRA -Heure non valide +Invalid time . MessageId=1902 SymbolicName=ERROR_INVALID_FORM_NAME Language=FRA -Nom de formulaire non valide +Invalid form name . MessageId=1903 SymbolicName=ERROR_INVALID_FORM_SIZE Language=FRA -Taille de formulaire non valide +Invalid form size . MessageId=1904 SymbolicName=ERROR_ALREADY_WAITING Language=FRA -Descripteur d'imprimante déjà en attente +Already awaiting printer handle . MessageId=1905 SymbolicName=ERROR_PRINTER_DELETED Language=FRA -Imprimante supprimée +Imprimante supprimée . MessageId=1906 SymbolicName=ERROR_INVALID_PRINTER_STATE Language=FRA -État d'imprimante non valide +Invalid printer state . MessageId=1907 SymbolicName=ERROR_PASSWORD_MUST_CHANGE Language=FRA -L'utilisateur doit modifier son mot de passe +User must change password . MessageId=1908 SymbolicName=ERROR_DOMAIN_CONTROLLER_NOT_FOUND Language=FRA -Contrôleur de domaine introuvable +Domain controller not found . MessageId=1909 SymbolicName=ERROR_ACCOUNT_LOCKED_OUT Language=FRA -Compte verrouillé +Account locked out . MessageId=1910 SymbolicName=OR_INVALID_OXID Language=FRA -Format de pixel invalide +Invalid pixel format . MessageId=1911 SymbolicName=OR_INVALID_OID Language=FRA -Pilote invalide +Invalid driver . MessageId=1912 SymbolicName=OR_INVALID_SET @@ -3730,8 +3728,3 @@ SymbolicName=RPC_S_GRP_ELT_NOT_REMOVED Language=FRA RPC_S_GRP_ELT_NOT_REMOVED . -MessageId=2221 -SymbolicName=NERR_UserNotFound -Language=FRA -Nom d'utilisateur introuvable -. diff --git a/dlls/kernel32/nls/winerr_kor.mc b/dlls/kernel32/nls/winerr_kor.mc index 95082e47b9c..44036defcfc 100644 --- a/dlls/kernel32/nls/winerr_kor.mc +++ b/dlls/kernel32/nls/winerr_kor.mc @@ -18,7 +18,6 @@ ; LanguageNames=(KOR=0x412:winerr) -CodePages=(KOR=949:0) MessageId=0 SymbolicName=ERROR_SUCCESS @@ -3730,8 +3729,3 @@ SymbolicName=RPC_S_GRP_ELT_NOT_REMOVED Language=KOR RPC_S_GRP_ELT_NOT_REMOVED . -MessageId=2221 -SymbolicName=NERR_UserNotFound -Language=KOR -»ç¿ëÀÚ À̸§À» ãÀ» ¼ö ¾ø½À´Ï´Ù -. diff --git a/dlls/kernel32/nls/winerr_lth.mc b/dlls/kernel32/nls/winerr_lth.mc deleted file mode 100644 index 72780259f86..00000000000 --- a/dlls/kernel32/nls/winerr_lth.mc +++ /dev/null @@ -1,3736 +0,0 @@ -; -; Copyright 2009 Aurimas Fišeras -; -; 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA -; - -LanguageNames=(LTH=0x27:winerr) -CodePages=(LTH=65001:0) - -MessageId=0 -SymbolicName=ERROR_SUCCESS -Language=LTH -Sėkmė -. -MessageId=1 -SymbolicName=ERROR_INVALID_FUNCTION -Language=LTH -Netinkama funkcija -. -MessageId=2 -SymbolicName=ERROR_FILE_NOT_FOUND -Language=LTH -Failas nerastas -. -MessageId=3 -SymbolicName=ERROR_PATH_NOT_FOUND -Language=LTH -Kelias nerastas -. -MessageId=4 -SymbolicName=ERROR_TOO_MANY_OPEN_FILES -Language=LTH -Per daug atvertų failų -. -MessageId=5 -SymbolicName=ERROR_ACCESS_DENIED -Language=LTH -Prieiga nesuteikta -. -MessageId=6 -SymbolicName=ERROR_INVALID_HANDLE -Language=LTH -Neteisinga rodyklė -. -MessageId=7 -SymbolicName=ERROR_ARENA_TRASHED -Language=LTH -Atmintis išgadinta -. -MessageId=8 -SymbolicName=ERROR_NOT_ENOUGH_MEMORY -Language=LTH -Per mažai atminties -. -MessageId=9 -SymbolicName=ERROR_INVALID_BLOCK -Language=LTH -Neteisingas blokas -. -MessageId=10 -SymbolicName=ERROR_BAD_ENVIRONMENT -Language=LTH -Bloga aplinka -. -MessageId=11 -SymbolicName=ERROR_BAD_FORMAT -Language=LTH -Blogas formatas -. -MessageId=12 -SymbolicName=ERROR_INVALID_ACCESS -Language=LTH -Neteisinga prieiga -. -MessageId=13 -SymbolicName=ERROR_INVALID_DATA -Language=LTH -Neteisingi duomenys -. -MessageId=14 -SymbolicName=ERROR_OUTOFMEMORY -Language=LTH -Trūksta atminties -. -MessageId=15 -SymbolicName=ERROR_INVALID_DRIVE -Language=LTH -neteisingas diskas -. -MessageId=16 -SymbolicName=ERROR_CURRENT_DIRECTORY -Language=LTH -Negalima pašalinti dabartinio katalogo -. -MessageId=17 -SymbolicName=ERROR_NOT_SAME_DEVICE -Language=LTH -Ne tas pats įrenginys -. -MessageId=18 -SymbolicName=ERROR_NO_MORE_FILES -Language=LTH -Nėra daugiau failų -. -MessageId=19 -SymbolicName=ERROR_WRITE_PROTECT -Language=LTH -Apsaugotas nuo rašymo -. -MessageId=20 -SymbolicName=ERROR_BAD_UNIT -Language=LTH -Blogas vienetas -. -MessageId=21 -SymbolicName=ERROR_NOT_READY -Language=LTH -Nepasiruošęs -. -MessageId=22 -SymbolicName=ERROR_BAD_COMMAND -Language=LTH -Bloga komanda -. -MessageId=23 -SymbolicName=ERROR_CRC -Language=LTH -CRC klaida -. -MessageId=24 -SymbolicName=ERROR_BAD_LENGTH -Language=LTH -Blogas ilgis -. -MessageId=25 -SymbolicName=ERROR_SEEK -Language=LTH -Perėjimo klaida -. -MessageId=26 -SymbolicName=ERROR_NOT_DOS_DISK -Language=LTH -Ne DOS diskas -. -MessageId=27 -SymbolicName=ERROR_SECTOR_NOT_FOUND -Language=LTH -Sektorius nerastas -. -MessageId=28 -SymbolicName=ERROR_OUT_OF_PAPER -Language=LTH -Baigėsi popierius -. -MessageId=29 -SymbolicName=ERROR_WRITE_FAULT -Language=LTH -Rašymo klaida -. -MessageId=30 -SymbolicName=ERROR_READ_FAULT -Language=LTH -Skaitymo klaida -. -MessageId=31 -SymbolicName=ERROR_GEN_FAILURE -Language=LTH -Bendra triktis -. -MessageId=32 -SymbolicName=ERROR_SHARING_VIOLATION -Language=LTH -Bendro naudojimo pažeidimas -. -MessageId=33 -SymbolicName=ERROR_LOCK_VIOLATION -Language=LTH -Blokavimo pažeidimas -. -MessageId=34 -SymbolicName=ERROR_WRONG_DISK -Language=LTH -Ne tas diskas -. -MessageId=36 -SymbolicName=ERROR_SHARING_BUFFER_EXCEEDED -Language=LTH -Viršytas bendro naudojimo buferis -. -MessageId=38 -SymbolicName=ERROR_HANDLE_EOF -Language=LTH -Failo pabaiga -. -MessageId=39 -SymbolicName=ERROR_HANDLE_DISK_FULL -Language=LTH -Diskas pilnas -. -MessageId=50 -SymbolicName=ERROR_NOT_SUPPORTED -Language=LTH -Užklausa nepalaikoma -. -MessageId=51 -SymbolicName=ERROR_REM_NOT_LIST -Language=LTH -Nutolęs kompiuteris nesiklauso -. -MessageId=52 -SymbolicName=ERROR_DUP_NAME -Language=LTH -Vienodi tinklo vardai -. -MessageId=53 -SymbolicName=ERROR_BAD_NETPATH -Language=LTH -Blogas tinklo kelias -. -MessageId=54 -SymbolicName=ERROR_NETWORK_BUSY -Language=LTH -Tinklas užimtas -. -MessageId=55 -SymbolicName=ERROR_DEV_NOT_EXIST -Language=LTH -Įrenginys neegzistuoja -. -MessageId=56 -SymbolicName=ERROR_TOO_MANY_CMDS -Language=LTH -Per daug komandų -. -MessageId=57 -SymbolicName=ERROR_ADAP_HDW_ERR -Language=LTH -Adapterio aparatinė klaida -. -MessageId=58 -SymbolicName=ERROR_BAD_NET_RESP -Language=LTH -Blogas tinklo atsakymas -. -MessageId=59 -SymbolicName=ERROR_UNEXP_NET_ERR -Language=LTH -Netikėta tinklo klaida -. -MessageId=60 -SymbolicName=ERROR_BAD_REM_ADAP -Language=LTH -Blogas nutolęs adapteris -. -MessageId=61 -SymbolicName=ERROR_PRINTQ_FULL -Language=LTH -Spausdinimo eilė pilna -. -MessageId=62 -SymbolicName=ERROR_NO_SPOOL_SPACE -Language=LTH -Nėra vietos kaupe -. -MessageId=63 -SymbolicName=ERROR_PRINT_CANCELLED -Language=LTH -Spausdinimas nutrauktas -. -MessageId=64 -SymbolicName=ERROR_NETNAME_DELETED -Language=LTH -Tinklo vardas pašalintas -. -MessageId=65 -SymbolicName=ERROR_NETWORK_ACCESS_DENIED -Language=LTH -Tinklo prieiga nesuteikta -. -MessageId=66 -SymbolicName=ERROR_BAD_DEV_TYPE -Language=LTH -Blogas įrenginio tipas -. -MessageId=67 -SymbolicName=ERROR_BAD_NET_NAME -Language=LTH -Blogas tinklo vardas -. -MessageId=68 -SymbolicName=ERROR_TOO_MANY_NAMES -Language=LTH -Per daug tinklo vardų -. -MessageId=69 -SymbolicName=ERROR_TOO_MANY_SESS -Language=LTH -Per daug tinklo seansų -. -MessageId=70 -SymbolicName=ERROR_SHARING_PAUSED -Language=LTH -Bendrinimas pristabdytas -. -MessageId=71 -SymbolicName=ERROR_REQ_NOT_ACCEP -Language=LTH -Užklausa nepriimta -. -MessageId=72 -SymbolicName=ERROR_REDIR_PAUSED -Language=LTH -Nukreiptuvė pristabdyta -. -MessageId=80 -SymbolicName=ERROR_FILE_EXISTS -Language=LTH -Failas egzistuoja -. -MessageId=82 -SymbolicName=ERROR_CANNOT_MAKE -Language=LTH -Nepavyko sukurti -. -MessageId=83 -SymbolicName=ERROR_FAIL_I24 -Language=LTH -Int24 klaida -. -MessageId=84 -SymbolicName=ERROR_OUT_OF_STRUCTURES -Language=LTH -Trūksta struktūrų -. -MessageId=85 -SymbolicName=ERROR_ALREADY_ASSIGNED -Language=LTH -Jau priskirta -. -MessageId=86 -SymbolicName=ERROR_INVALID_PASSWORD -Language=LTH -Neteisingas slaptažodis -. -MessageId=87 -SymbolicName=ERROR_INVALID_PARAMETER -Language=LTH -Neteisingas parametras -. -MessageId=88 -SymbolicName=ERROR_NET_WRITE_FAULT -Language=LTH -Tinklo rašymo klaida -. -MessageId=89 -SymbolicName=ERROR_NO_PROC_SLOTS -Language=LTH -Nėra procesų lizdų -. -MessageId=100 -SymbolicName=ERROR_TOO_MANY_SEMAPHORES -Language=LTH -Per daug semaforų -. -MessageId=101 -SymbolicName=ERROR_EXCL_SEM_ALREADY_OWNED -Language=LTH -Jau turimas išskirtinis semaforas -. -MessageId=102 -SymbolicName=ERROR_SEM_IS_SET -Language=LTH -Semaforas nustatytas -. -MessageId=103 -SymbolicName=ERROR_TOO_MANY_SEM_REQUESTS -Language=LTH -Per daug semaforo užklausų -. -MessageId=104 -SymbolicName=ERROR_INVALID_AT_INTERRUPT_TIME -Language=LTH -Netinkamas pertraukties metu -. -MessageId=105 -SymbolicName=ERROR_SEM_OWNER_DIED -Language=LTH -Semaforo turėtojas numirė -. -MessageId=106 -SymbolicName=ERROR_SEM_USER_LIMIT -Language=LTH -Semaforo naudotojų riba -. -MessageId=107 -SymbolicName=ERROR_DISK_CHANGE -Language=LTH -Įdėkite diską į kaupiklį %1 -. -MessageId=108 -SymbolicName=ERROR_DRIVE_LOCKED -Language=LTH -Kaupiklis užblokuotas -. -MessageId=109 -SymbolicName=ERROR_BROKEN_PIPE -Language=LTH -Neveikiantis kanalas -. -MessageId=110 -SymbolicName=ERROR_OPEN_FAILED -Language=LTH -Nepavyko atverti -. -MessageId=111 -SymbolicName=ERROR_BUFFER_OVERFLOW -Language=LTH -Buferio perpildymas -. -MessageId=112 -SymbolicName=ERROR_DISK_FULL -Language=LTH -Diskas pilnas -. -MessageId=113 -SymbolicName=ERROR_NO_MORE_SEARCH_HANDLES -Language=LTH -Daugiau nebėra paieškos rodyklių -. -MessageId=114 -SymbolicName=ERROR_INVALID_TARGET_HANDLE -Language=LTH -Neteisinga tikslo rodyklė -. -MessageId=117 -SymbolicName=ERROR_INVALID_CATEGORY -Language=LTH -Klaidingas IOCTL -. -MessageId=118 -SymbolicName=ERROR_INVALID_VERIFY_SWITCH -Language=LTH -Neteisingas patikrinimo jungiklis -. -MessageId=119 -SymbolicName=ERROR_BAD_DRIVER_LEVEL -Language=LTH -Blogas tvarkyklės lygis -. -MessageId=120 -SymbolicName=ERROR_CALL_NOT_IMPLEMENTED -Language=LTH -Kreipinys nerealizuotas -. -MessageId=121 -SymbolicName=ERROR_SEM_TIMEOUT -Language=LTH -Baigėsi semaforo laikas -. -MessageId=122 -SymbolicName=ERROR_INSUFFICIENT_BUFFER -Language=LTH -Nepakankamas buferis -. -MessageId=123 -SymbolicName=ERROR_INVALID_NAME -Language=LTH -Neteisingas vardas -. -MessageId=124 -SymbolicName=ERROR_INVALID_LEVEL -Language=LTH -Neteisingas lygis -. -MessageId=125 -SymbolicName=ERROR_NO_VOLUME_LABEL -Language=LTH -Nėra tomo vardo -. -MessageId=126 -SymbolicName=ERROR_MOD_NOT_FOUND -Language=LTH -Nerastas modulis -. -MessageId=127 -SymbolicName=ERROR_PROC_NOT_FOUND -Language=LTH -Nerasta procedūra -. -MessageId=128 -SymbolicName=ERROR_WAIT_NO_CHILDREN -Language=LTH -Nėra vaikų laukimui -. -MessageId=129 -SymbolicName=ERROR_CHILD_NOT_COMPLETE -Language=LTH -Antrinis procesas neužbaigtas -. -MessageId=130 -SymbolicName=ERROR_DIRECT_ACCESS_HANDLE -Language=LTH -Neteisingas tiesioginės kreipties rodyklės naudojimas -. -MessageId=131 -SymbolicName=ERROR_NEGATIVE_SEEK -Language=LTH -Neigiamas perėjimas -. -MessageId=132 -SymbolicName=ERROR_SEEK_ON_DEVICE -Language=LTH -Perėjimo klaida -. -MessageId=133 -SymbolicName=ERROR_IS_JOIN_TARGET -Language=LTH -Kaupiklis yra JOIN paskirtis -. -MessageId=134 -SymbolicName=ERROR_IS_JOINED -Language=LTH -Kaupiklis jau prijungtas su JOIN -. -MessageId=135 -SymbolicName=ERROR_IS_SUBSTED -Language=LTH -Kaupiklis jau yra pakeistas su SUBST -. -MessageId=136 -SymbolicName=ERROR_NOT_JOINED -Language=LTH -Kaupiklis nėra prijungtas su JOIN -. -MessageId=137 -SymbolicName=ERROR_NOT_SUBSTED -Language=LTH -Kaupiklis nėra pakeistas su SUBST -. -MessageId=138 -SymbolicName=ERROR_JOIN_TO_JOIN -Language=LTH -Mėginimas prijungti su JOIN prie su JOIN prijungto kaupiklio -. -MessageId=139 -SymbolicName=ERROR_SUBST_TO_SUBST -Language=LTH -Mėginimas pakeisti su SUBST kaupiklį jau pakeistą su SUBST -. -MessageId=140 -SymbolicName=ERROR_JOIN_TO_SUBST -Language=LTH -Mėginimas prijungti su JOIN prie pakeisto su SUBST kaupiklio -. -MessageId=141 -SymbolicName=ERROR_SUBST_TO_JOIN -Language=LTH -Mėginimas pakeisti su SUBST kaupiklį jau prijungtą su JOIN -. -MessageId=142 -SymbolicName=ERROR_BUSY_DRIVE -Language=LTH -Kaupiklis užimtas -. -MessageId=143 -SymbolicName=ERROR_SAME_DRIVE -Language=LTH -Tas pats kaupiklis -. -MessageId=144 -SymbolicName=ERROR_DIR_NOT_ROOT -Language=LTH -Ne aukščiausio lygio katalogas -. -MessageId=145 -SymbolicName=ERROR_DIR_NOT_EMPTY -Language=LTH -Katalogas netuščias -. -MessageId=146 -SymbolicName=ERROR_IS_SUBST_PATH -Language=LTH -Kelias naudojamas kaip SUBST -. -MessageId=147 -SymbolicName=ERROR_IS_JOIN_PATH -Language=LTH -Kelias naudojamas kaip JOIN -. -MessageId=148 -SymbolicName=ERROR_PATH_BUSY -Language=LTH -Kelias užimtas -. -MessageId=149 -SymbolicName=ERROR_IS_SUBST_TARGET -Language=LTH -Jau SUBST paskirtis -. -MessageId=150 -SymbolicName=ERROR_SYSTEM_TRACE -Language=LTH -Nenurodytas ar neleidžiamas sistemos pėdsakas -. -MessageId=151 -SymbolicName=ERROR_INVALID_EVENT_COUNT -Language=LTH -Neteisingas DosMuxSemWait įvykių skaičius -. -MessageId=152 -SymbolicName=ERROR_TOO_MANY_MUXWAITERS -Language=LTH -Per daug laukiančių DosMuxSemWait -. -MessageId=153 -SymbolicName=ERROR_INVALID_LIST_FORMAT -Language=LTH -Neteisingas DosSemMuxWait sąrašas -. -MessageId=154 -SymbolicName=ERROR_LABEL_TOO_LONG -Language=LTH -Tomo vardas per ilgas -. -MessageId=155 -SymbolicName=ERROR_TOO_MANY_TCBS -Language=LTH -Per daug TCB -. -MessageId=156 -SymbolicName=ERROR_SIGNAL_REFUSED -Language=LTH -Signalas nepriimtas -. -MessageId=157 -SymbolicName=ERROR_DISCARDED -Language=LTH -Segmentas atmestas -. -MessageId=158 -SymbolicName=ERROR_NOT_LOCKED -Language=LTH -Segmentas neužblokuotas -. -MessageId=159 -SymbolicName=ERROR_BAD_THREADID_ADDR -Language=LTH -Blogas gijos identifikatoriaus adresas -. -MessageId=160 -SymbolicName=ERROR_BAD_ARGUMENTS -Language=LTH -Blogi DosExecPgm argumentai -. -MessageId=161 -SymbolicName=ERROR_BAD_PATHNAME -Language=LTH -Neteisingas kelias -. -MessageId=162 -SymbolicName=ERROR_SIGNAL_PENDING -Language=LTH -Laukiama signalo -. -MessageId=164 -SymbolicName=ERROR_MAX_THRDS_REACHED -Language=LTH -Pasiekta sistemos gijų skaičiaus riba -. -MessageId=167 -SymbolicName=ERROR_LOCK_FAILED -Language=LTH -Nepavyko užblokuoti -. -MessageId=170 -SymbolicName=ERROR_BUSY -Language=LTH -Išteklius naudojamas -. -MessageId=173 -SymbolicName=ERROR_CANCEL_VIOLATION -Language=LTH -Atmetimo pažeidimas -. -MessageId=174 -SymbolicName=ERROR_ATOMIC_LOCKS_NOT_SUPPORTED -Language=LTH -Neskaidomi užblokavimai nepalaikomi -. -MessageId=180 -SymbolicName=ERROR_INVALID_SEGMENT_NUMBER -Language=LTH -Neteisingas segmento numeris -. -MessageId=182 -SymbolicName=ERROR_INVALID_ORDINAL -Language=LTH -Neteisingas %1 eilės numeris -. -MessageId=183 -SymbolicName=ERROR_ALREADY_EXISTS -Language=LTH -Failas jau egzistuoja -. -MessageId=186 -SymbolicName=ERROR_INVALID_FLAG_NUMBER -Language=LTH -Neteisingas žymos bito numeris -. -MessageId=187 -SymbolicName=ERROR_SEM_NOT_FOUND -Language=LTH -Semaforo vardas nerastas -. -MessageId=188 -SymbolicName=ERROR_INVALID_STARTING_CODESEG -Language=LTH -Neteisingas %1 pradinis kodo segmentas -. -MessageId=189 -SymbolicName=ERROR_INVALID_STACKSEG -Language=LTH -Neteisingas %1 pradinis dėklo segmentas -. -MessageId=190 -SymbolicName=ERROR_INVALID_MODULETYPE -Language=LTH -Neteisingas %1 modulio tipas -. -MessageId=191 -SymbolicName=ERROR_INVALID_EXE_SIGNATURE -Language=LTH -Neteisingas %1 EXE parašas -. -MessageId=192 -SymbolicName=ERROR_EXE_MARKED_INVALID -Language=LTH -%1 EXE pažymėtas neteisingu -. -MessageId=193 -SymbolicName=ERROR_BAD_EXE_FORMAT -Language=LTH -Blogas %1 EXE formatas -. -MessageId=194 -SymbolicName=ERROR_ITERATED_DATA_EXCEEDS_64k -Language=LTH -Pakartoti %1 duomenys viršija 64k -. -MessageId=195 -SymbolicName=ERROR_INVALID_MINALLOCSIZE -Language=LTH -Neteisingas %1 MinAllocSize -. -MessageId=196 -SymbolicName=ERROR_DYNLINK_FROM_INVALID_RING -Language=LTH -Dynlink iš neteisingo žiedo -. -MessageId=197 -SymbolicName=ERROR_IOPL_NOT_ENABLED -Language=LTH -IOPL neįjungtas -. -MessageId=198 -SymbolicName=ERROR_INVALID_SEGDPL -Language=LTH -Neteisingas %1 SEGDPL -. -MessageId=199 -SymbolicName=ERROR_AUTODATASEG_EXCEEDS_64k -Language=LTH -Automatinis duomenų segmentas viršija 64k -. -MessageId=200 -SymbolicName=ERROR_RING2SEG_MUST_BE_MOVABLE -Language=LTH -Antro žiedo segmentas turi būti perkeliamas -. -MessageId=201 -SymbolicName=ERROR_RELOC_CHAIN_XEEDS_SEGLIM -Language=LTH -%1 perkėlimų grandinė viršija segmentų limitą -. -MessageId=202 -SymbolicName=ERROR_INFLOOP_IN_RELOC_CHAIN -Language=LTH -Begalinis ciklas %1 perkėlimų grandinėje -. -MessageId=203 -SymbolicName=ERROR_ENVVAR_NOT_FOUND -Language=LTH -Aplinkos kintamasis nerastas -. -MessageId=205 -SymbolicName=ERROR_NO_SIGNAL_SENT -Language=LTH -Joks signalas neišsiųstas -. -MessageId=206 -SymbolicName=ERROR_FILENAME_EXCED_RANGE -Language=LTH -Failo vardas per ilgas -. -MessageId=207 -SymbolicName=ERROR_RING2_STACK_IN_USE -Language=LTH -Antro žiedo dėklas naudojamas -. -MessageId=208 -SymbolicName=ERROR_META_EXPANSION_TOO_LONG -Language=LTH -Klaida naudojant failo vardo pakaitos simbolius -. -MessageId=209 -SymbolicName=ERROR_INVALID_SIGNAL_NUMBER -Language=LTH -Neteisingas signalo numeris -. -MessageId=210 -SymbolicName=ERROR_THREAD_1_INACTIVE -Language=LTH -Klaida nustatant signalo doroklę -. -MessageId=212 -SymbolicName=ERROR_LOCKED -Language=LTH -Segmentas užblokuotas -. -MessageId=214 -SymbolicName=ERROR_TOO_MANY_MODULES -Language=LTH -Per daug modulių -. -MessageId=215 -SymbolicName=ERROR_NESTING_NOT_ALLOWED -Language=LTH -Negalima naudoti įdėtinių LoadModule kreipinių -. -MessageId=216 -SymbolicName=ERROR_EXE_MACHINE_TYPE_MISMATCH -Language=LTH -Neatitinka kompiuterio tipas -. -MessageId=230 -SymbolicName=ERROR_BAD_PIPE -Language=LTH -Blogas kanalas -. -MessageId=231 -SymbolicName=ERROR_PIPE_BUSY -Language=LTH -Kanalas užimtas -. -MessageId=232 -SymbolicName=ERROR_NO_DATA -Language=LTH -Kanalas užvertas -. -MessageId=233 -SymbolicName=ERROR_PIPE_NOT_CONNECTED -Language=LTH -Kanalas neprijungtas -. -MessageId=234 -SymbolicName=ERROR_MORE_DATA -Language=LTH -Yra daugiau duomenų -. -MessageId=240 -SymbolicName=ERROR_VC_DISCONNECTED -Language=LTH -Seansas nutrauktas -. -MessageId=254 -SymbolicName=ERROR_INVALID_EA_NAME -Language=LTH -Neteisingas išplėstinio atributo vardas -. -MessageId=255 -SymbolicName=ERROR_EA_LIST_INCONSISTENT -Language=LTH -Išplėstinių atributų sąrašas prieštaringas -. -MessageId=259 -SymbolicName=ERROR_NO_MORE_ITEMS -Language=LTH -Nėra daugiau duomenų -. -MessageId=266 -SymbolicName=ERROR_CANNOT_COPY -Language=LTH -Negalima naudoti kopijavimo programų sąsajos -. -MessageId=267 -SymbolicName=ERROR_DIRECTORY -Language=LTH -Neteisingas katalogo vardas -. -MessageId=275 -SymbolicName=ERROR_EAS_DIDNT_FIT -Language=LTH -Netilpo išplėstiniai atributai -. -MessageId=276 -SymbolicName=ERROR_EA_FILE_CORRUPT -Language=LTH -Pažeistas išplėstinių atributų failas -. -MessageId=277 -SymbolicName=ERROR_EA_TABLE_FULL -Language=LTH -Išplėstinių atributų lentelė pilna -. -MessageId=278 -SymbolicName=ERROR_INVALID_EA_HANDLE -Language=LTH -Neteisinga išplėstinių atributų rodyklė -. -MessageId=282 -SymbolicName=ERROR_EAS_NOT_SUPPORTED -Language=LTH -Nepalaikomi išplėstiniai atributai -. -MessageId=288 -SymbolicName=ERROR_NOT_OWNER -Language=LTH -Muteksas nepriklauso kvietėjui -. -MessageId=298 -SymbolicName=ERROR_TOO_MANY_POSTS -Language=LTH -Per didelis semaforo prieaugis -. -MessageId=299 -SymbolicName=ERROR_PARTIAL_COPY -Language=LTH -Funkcija skaityti/rašyti proceso atmintį dalinai baigta -. -MessageId=300 -SymbolicName=ERROR_OPLOCK_NOT_GRANTED -Language=LTH -ERROR_OPLOCK_NOT_GRANTED -. -MessageId=301 -SymbolicName=ERROR_INVALID_OPLOCK_PROTOCOL -Language=LTH -ERROR_INVALID_OPLOCK_PROTOCOL -. -MessageId=317 -SymbolicName=ERROR_MR_MID_NOT_FOUND -Language=LTH -Pranešimas 0x%1 nerastas faile %2 -. -MessageId=487 -SymbolicName=ERROR_INVALID_ADDRESS -Language=LTH -Neteisingas adresas -. -MessageId=534 -SymbolicName=ERROR_ARITHMETIC_OVERFLOW -Language=LTH -Aritmetinis perpildymas -. -MessageId=535 -SymbolicName=ERROR_PIPE_CONNECTED -Language=LTH -Kanalas prijungtas -. -MessageId=536 -SymbolicName=ERROR_PIPE_LISTENING -Language=LTH -Klausomasi kanalo -. -MessageId=994 -SymbolicName=ERROR_EA_ACCESS_DENIED -Language=LTH -Išplėstinių atributų prieiga nesuteikta -. -MessageId=995 -SymbolicName=ERROR_OPERATION_ABORTED -Language=LTH -Į/I operacija nutraukta -. -MessageId=996 -SymbolicName=ERROR_IO_INCOMPLETE -Language=LTH -Persiklojantis Į/I neužbaigtas -. -MessageId=997 -SymbolicName=ERROR_IO_PENDING -Language=LTH -Laukiama persiklojančio Į/I -. -MessageId=998 -SymbolicName=ERROR_NOACCESS -Language=LTH -Nėra prieigos prie atminties vietos -. -MessageId=999 -SymbolicName=ERROR_SWAPERROR -Language=LTH -Sukeitimų klaida -. -MessageId=1001 -SymbolicName=ERROR_STACK_OVERFLOW -Language=LTH -Dėklo perpildymas -. -MessageId=1002 -SymbolicName=ERROR_INVALID_MESSAGE -Language=LTH -Neteisingas pranešimas -. -MessageId=1003 -SymbolicName=ERROR_CAN_NOT_COMPLETE -Language=LTH -Nepavyko užbaigti -. -MessageId=1004 -SymbolicName=ERROR_INVALID_FLAGS -Language=LTH -Neteisingi žymos bitai -. -MessageId=1005 -SymbolicName=ERROR_UNRECOGNIZED_VOLUME -Language=LTH -Neatpažintas tomas -. -MessageId=1006 -SymbolicName=ERROR_FILE_INVALID -Language=LTH -Neteisingas failas -. -MessageId=1007 -SymbolicName=ERROR_FULLSCREEN_MODE -Language=LTH -Negalima paleisti visame ekrane -. -MessageId=1008 -SymbolicName=ERROR_NO_TOKEN -Language=LTH -Neegzistuojantis prieigos raktas -. -MessageId=1009 -SymbolicName=ERROR_BADDB -Language=LTH -Pažeistas registras -. -MessageId=1010 -SymbolicName=ERROR_BADKEY -Language=LTH -Neteisingas raktas -. -MessageId=1011 -SymbolicName=ERROR_CANTOPEN -Language=LTH -ERROR_CANTOPEN -. -MessageId=1012 -SymbolicName=ERROR_CANTREAD -Language=LTH -Nepavyko perskaityti registro rakto -. -MessageId=1013 -SymbolicName=ERROR_CANTWRITE -Language=LTH -Nepavyko įrašyti registro rakto -. -MessageId=1014 -SymbolicName=ERROR_REGISTRY_RECOVERED -Language=LTH -Registras buvo atkurtas -. -MessageId=1015 -SymbolicName=ERROR_REGISTRY_CORRUPT -Language=LTH -Registras yra pažeistas -. -MessageId=1016 -SymbolicName=ERROR_REGISTRY_IO_FAILED -Language=LTH -Nepavyko registro Į/I -. -MessageId=1017 -SymbolicName=ERROR_NOT_REGISTRY_FILE -Language=LTH -Ne registro failas -. -MessageId=1018 -SymbolicName=ERROR_KEY_DELETED -Language=LTH -Raktas ištrintas -. -MessageId=1019 -SymbolicName=ERROR_NO_LOG_SPACE -Language=LTH -Nėra vietos registro žurnale -. -MessageId=1020 -SymbolicName=ERROR_KEY_HAS_CHILDREN -Language=LTH -Registro raktas turi porakčių -. -MessageId=1021 -SymbolicName=ERROR_CHILD_MUST_BE_VOLATILE -Language=LTH -Poraktis turi būti kintamas -. -MessageId=1022 -SymbolicName=ERROR_NOTIFY_ENUM_DIR -Language=LTH -Vyksta pranešimo apie pasikeitimus užklausa -. -MessageId=1051 -SymbolicName=ERROR_DEPENDENT_SERVICES_RUNNING -Language=LTH -Priklausomos tarnybos yra vykdomos -. -MessageId=1052 -SymbolicName=ERROR_INVALID_SERVICE_CONTROL -Language=LTH -Neteisingas tarnybos valdymas -. -MessageId=1053 -SymbolicName=ERROR_SERVICE_REQUEST_TIMEOUT -Language=LTH -Baigėsi tarnybos užklausos laikas -. -MessageId=1054 -SymbolicName=ERROR_SERVICE_NO_THREAD -Language=LTH -Nepavyko sukurti tarnybos gijos -. -MessageId=1055 -SymbolicName=ERROR_SERVICE_DATABASE_LOCKED -Language=LTH -Tarnybų duomenų bazė užblokuota -. -MessageId=1056 -SymbolicName=ERROR_SERVICE_ALREADY_RUNNING -Language=LTH -Tarnyba jau vykdoma -. -MessageId=1057 -SymbolicName=ERROR_INVALID_SERVICE_ACCOUNT -Language=LTH -Neteisinga tarnybos paskyra -. -MessageId=1058 -SymbolicName=ERROR_SERVICE_DISABLED -Language=LTH -Tarnyba išjungta -. -MessageId=1059 -SymbolicName=ERROR_CIRCULAR_DEPENDENCY -Language=LTH -Ciklinė priklausomybė -. -MessageId=1060 -SymbolicName=ERROR_SERVICE_DOES_NOT_EXIST -Language=LTH -Tarnyba neegzistuoja -. -MessageId=1061 -SymbolicName=ERROR_SERVICE_CANNOT_ACCEPT_CTRL -Language=LTH -Tarnyba negali priimti valdymo pranešimo -. -MessageId=1062 -SymbolicName=ERROR_SERVICE_NOT_ACTIVE -Language=LTH -Tarnyba neaktyvi -. -MessageId=1063 -SymbolicName=ERROR_FAILED_SERVICE_CONTROLLER_CONNECT -Language=LTH -Nepavyko prisijungti prie tarnybų valdiklio -. -MessageId=1064 -SymbolicName=ERROR_EXCEPTION_IN_SERVICE -Language=LTH -Išimtinė situacija tarnyboje -. -MessageId=1065 -SymbolicName=ERROR_DATABASE_DOES_NOT_EXIST -Language=LTH -Duomenų bazė neegzistuoja -. -MessageId=1066 -SymbolicName=ERROR_SERVICE_SPECIFIC_ERROR -Language=LTH -Savita tarnybos klaida -. -MessageId=1067 -SymbolicName=ERROR_PROCESS_ABORTED -Language=LTH -Procesas nutrauktas -. -MessageId=1068 -SymbolicName=ERROR_SERVICE_DEPENDENCY_FAIL -Language=LTH -Sutrikę tarnybos priklausomybės -. -MessageId=1069 -SymbolicName=ERROR_SERVICE_LOGON_FAILED -Language=LTH -Nepavyko tarnybos prisijungimas -. -MessageId=1070 -SymbolicName=ERROR_SERVICE_START_HANG -Language=LTH -Tarnybos paleidimo strigtis -. -MessageId=1071 -SymbolicName=ERROR_INVALID_SERVICE_LOCK -Language=LTH -Neteisingas tarnybos blokavimas -. -MessageId=1072 -SymbolicName=ERROR_SERVICE_MARKED_FOR_DELETE -Language=LTH -Tarnyba pažymėta trynimui -. -MessageId=1073 -SymbolicName=ERROR_SERVICE_EXISTS -Language=LTH -Tarnyba egzistuoja -. -MessageId=1074 -SymbolicName=ERROR_ALREADY_RUNNING_LKG -Language=LTH -Sistema veikia su paskutine žinoma gera konfigūracija -. -MessageId=1075 -SymbolicName=ERROR_SERVICE_DEPENDENCY_DELETED -Language=LTH -Pašalinta tarnybos priklausomybė -. -MessageId=1076 -SymbolicName=ERROR_BOOT_ALREADY_ACCEPTED -Language=LTH -Operacinės sistemos paleidimas jau patvirtintas su paskutine žinoma gera konfigūracija -. -MessageId=1077 -SymbolicName=ERROR_SERVICE_NEVER_STARTED -Language=LTH -Tarnyba nepasileido nuo paskutinio operacinės sistemos paleidimo -. -MessageId=1078 -SymbolicName=ERROR_DUPLICATE_SERVICE_NAME -Language=LTH -Vienodas tarnybos vardas -. -MessageId=1079 -SymbolicName=ERROR_DIFFERENT_SERVICE_ACCOUNT -Language=LTH -Kita tarnybos paskyra -. -MessageId=1080 -SymbolicName=ERROR_CANNOT_DETECT_DRIVER_FAILURE -Language=LTH -ERROR_CANNOT_DETECT_DRIVER_FAILURE -. -MessageId=1081 -SymbolicName=ERROR_CANNOT_DETECT_PROCESS_ABORT -Language=LTH -ERROR_CANNOT_DETECT_PROCESS_ABORT -. -MessageId=1082 -SymbolicName=ERROR_NO_RECOVERY_PROGRAM -Language=LTH -ERROR_NO_RECOVERY_PROGRAM -. -MessageId=1083 -SymbolicName=ERROR_SERVICE_NOT_IN_EXE -Language=LTH -ERROR_SERVICE_NOT_IN_EXE -. -MessageId=1100 -SymbolicName=ERROR_END_OF_MEDIA -Language=LTH -Laikmenos pabaiga -. -MessageId=1101 -SymbolicName=ERROR_FILEMARK_DETECTED -Language=LTH -Failo žymė aptikta -. -MessageId=1102 -SymbolicName=ERROR_BEGINNING_OF_MEDIA -Language=LTH -Laikmenos pradžia -. -MessageId=1103 -SymbolicName=ERROR_SETMARK_DETECTED -Language=LTH -Žymės nustatymas aptiktas -. -MessageId=1104 -SymbolicName=ERROR_NO_DATA_DETECTED -Language=LTH -Neaptikta duomenų -. -MessageId=1105 -SymbolicName=ERROR_PARTITION_FAILURE -Language=LTH -Disko skaidinio klaida -. -MessageId=1106 -SymbolicName=ERROR_INVALID_BLOCK_LENGTH -Language=LTH -Neteisingas bloko ilgis -. -MessageId=1107 -SymbolicName=ERROR_DEVICE_NOT_PARTITIONED -Language=LTH -Įrenginys neskaidytas -. -MessageId=1108 -SymbolicName=ERROR_UNABLE_TO_LOCK_MEDIA -Language=LTH -Nepavyko užblokuoti laikmenos -. -MessageId=1109 -SymbolicName=ERROR_UNABLE_TO_UNLOAD_MEDIA -Language=LTH -Nepavyko išstumti laikmenos -. -MessageId=1110 -SymbolicName=ERROR_MEDIA_CHANGED -Language=LTH -Laikmena pasikeitė -. -MessageId=1111 -SymbolicName=ERROR_BUS_RESET -Language=LTH -Į/I magistralės paleidimas iš naujo -. -MessageId=1112 -SymbolicName=ERROR_NO_MEDIA_IN_DRIVE -Language=LTH -Nėra laikmenos kaupiklyje -. -MessageId=1113 -SymbolicName=ERROR_NO_UNICODE_TRANSLATION -Language=LTH -Nėra unikodo perskaičiavimo -. -MessageId=1114 -SymbolicName=ERROR_DLL_INIT_FAILED -Language=LTH -Nepavyko DLL inicijavimas -. -MessageId=1115 -SymbolicName=ERROR_SHUTDOWN_IN_PROGRESS -Language=LTH -Vyksta sistemos stabdymas -. -MessageId=1116 -SymbolicName=ERROR_NO_SHUTDOWN_IN_PROGRESS -Language=LTH -Nevyksta sistemos stabdymas -. -MessageId=1117 -SymbolicName=ERROR_IO_DEVICE -Language=LTH -Į/I įrenginio klaida -. -MessageId=1118 -SymbolicName=ERROR_SERIAL_NO_DEVICE -Language=LTH -Nerastas joks nuoseklusis įtaisas -. -MessageId=1119 -SymbolicName=ERROR_IRQ_BUSY -Language=LTH -Bendrasis IRQ užimtas -. -MessageId=1120 -SymbolicName=ERROR_MORE_WRITES -Language=LTH -Nuoseklusis Į/I baigtas -. -MessageId=1121 -SymbolicName=ERROR_COUNTER_TIMEOUT -Language=LTH -Nuosekliojo Į/I skaitiklio laikas baigėsi -. -MessageId=1122 -SymbolicName=ERROR_FLOPPY_ID_MARK_NOT_FOUND -Language=LTH -Diskelio identifikatoriaus adreso žymė nerasta -. -MessageId=1123 -SymbolicName=ERROR_FLOPPY_WRONG_CYLINDER -Language=LTH -Diskelis perduoda neteisingą cilindrą -. -MessageId=1124 -SymbolicName=ERROR_FLOPPY_UNKNOWN_ERROR -Language=LTH -Nežinoma diskelio klaida -. -MessageId=1125 -SymbolicName=ERROR_FLOPPY_BAD_REGISTERS -Language=LTH -Diskelio registrai prieštaringi -. -MessageId=1126 -SymbolicName=ERROR_DISK_RECALIBRATE_FAILED -Language=LTH -Nepavyko standžiojo disko perkalibravimas -. -MessageId=1127 -SymbolicName=ERROR_DISK_OPERATION_FAILED -Language=LTH -Nepavyko standžiojo disko operacija -. -MessageId=1128 -SymbolicName=ERROR_DISK_RESET_FAILED -Language=LTH -Nepavyko paleisti standžiojo disko iš naujo -. -MessageId=1129 -SymbolicName=ERROR_EOM_OVERFLOW -Language=LTH -Juostinės laikmenos pabaiga -. -MessageId=1130 -SymbolicName=ERROR_NOT_ENOUGH_SERVER_MEMORY -Language=LTH -Trūksta atminties serveryje -. -MessageId=1131 -SymbolicName=ERROR_POSSIBLE_DEADLOCK -Language=LTH -Galima aklavietė -. -MessageId=1132 -SymbolicName=ERROR_MAPPED_ALIGNMENT -Language=LTH -Neteisingas lygiavimas -. -MessageId=1140 -SymbolicName=ERROR_SET_POWER_STATE_VETOED -Language=LTH -Maitinimo būsenos nustatymas vetuotas -. -MessageId=1141 -SymbolicName=ERROR_SET_POWER_STATE_FAILED -Language=LTH -Maitinimo būsenos nustatymas nepavyko -. -MessageId=1142 -SymbolicName=ERROR_TOO_MANY_LINKS -Language=LTH -Per daug nuorodų -. -MessageId=1150 -SymbolicName=ERROR_OLD_WIN_VERSION -Language=LTH -Reikalinga naujesnė windows versija -. -MessageId=1151 -SymbolicName=ERROR_APP_WRONG_OS -Language=LTH -Netinkama operacinė sistema -. -MessageId=1152 -SymbolicName=ERROR_SINGLE_INSTANCE_APP -Language=LTH -Vieno egzemplioriaus programa -. -MessageId=1153 -SymbolicName=ERROR_RMODE_APP -Language=LTH -Real-mode programa -. -MessageId=1154 -SymbolicName=ERROR_INVALID_DLL -Language=LTH -Neteisingas DLL -. -MessageId=1155 -SymbolicName=ERROR_NO_ASSOCIATION -Language=LTH -Nėra susietos programos -. -MessageId=1156 -SymbolicName=ERROR_DDE_FAIL -Language=LTH -DDE klaida -. -MessageId=1157 -SymbolicName=ERROR_DLL_NOT_FOUND -Language=LTH -DLL nerastas -. -MessageId=1158 -SymbolicName=ERROR_NO_MORE_USER_HANDLES -Language=LTH -ERROR_NO_MORE_USER_HANDLES -. -MessageId=1159 -SymbolicName=ERROR_MESSAGE_SYNC_ONLY -Language=LTH -ERROR_MESSAGE_SYNC_ONLY -. -MessageId=1160 -SymbolicName=ERROR_SOURCE_ELEMENT_EMPTY -Language=LTH -ERROR_SOURCE_ELEMENT_EMPTY -. -MessageId=1161 -SymbolicName=ERROR_DESTINATION_ELEMENT_FULL -Language=LTH -ERROR_DESTINATION_ELEMENT_FULL -. -MessageId=1162 -SymbolicName=ERROR_ILLEGAL_ELEMENT_ADDRESS -Language=LTH -ERROR_ILLEGAL_ELEMENT_ADDRESS -. -MessageId=1163 -SymbolicName=ERROR_MAGAZINE_NOT_PRESENT -Language=LTH -ERROR_MAGAZINE_NOT_PRESENT -. -MessageId=1164 -SymbolicName=ERROR_DEVICE_REINITIALIZATION_NEEDED -Language=LTH -ERROR_DEVICE_REINITIALIZATION_NEEDED -. -MessageId=1165 -SymbolicName=ERROR_DEVICE_REQUIRES_CLEANING -Language=LTH -ERROR_DEVICE_REQUIRES_CLEANING -. -MessageId=1166 -SymbolicName=ERROR_DEVICE_DOOR_OPEN -Language=LTH -ERROR_DEVICE_DOOR_OPEN -. -MessageId=1167 -SymbolicName=ERROR_DEVICE_NOT_CONNECTED -Language=LTH -ERROR_DEVICE_NOT_CONNECTED -. -MessageId=1168 -SymbolicName=ERROR_NOT_FOUND -Language=LTH -ERROR_NOT_FOUND -. -MessageId=1169 -SymbolicName=ERROR_NO_MATCH -Language=LTH -ERROR_NO_MATCH -. -MessageId=1170 -SymbolicName=ERROR_SET_NOT_FOUND -Language=LTH -ERROR_SET_NOT_FOUND -. -MessageId=1171 -SymbolicName=ERROR_POINT_NOT_FOUND -Language=LTH -ERROR_POINT_NOT_FOUND -. -MessageId=1172 -SymbolicName=ERROR_NO_TRACKING_SERVICE -Language=LTH -ERROR_NO_TRACKING_SERVICE -. -MessageId=1173 -SymbolicName=ERROR_NO_VOLUME_ID -Language=LTH -ERROR_NO_VOLUME_ID -. -MessageId=1175 -SymbolicName=ERROR_UNABLE_TO_REMOVE_REPLACED -Language=LTH -ERROR_UNABLE_TO_REMOVE_REPLACED -. -MessageId=1176 -SymbolicName=ERROR_UNABLE_TO_MOVE_REPLACEMENT -Language=LTH -ERROR_UNABLE_TO_MOVE_REPLACEMENT -. -MessageId=1177 -SymbolicName=ERROR_UNABLE_TO_MOVE_REPLACEMENT_2 -Language=LTH -ERROR_UNABLE_TO_MOVE_REPLACEMENT_2 -. -MessageId=1178 -SymbolicName=ERROR_JOURNAL_DELETE_IN_PROGRESS -Language=LTH -ERROR_JOURNAL_DELETE_IN_PROGRESS -. -MessageId=1179 -SymbolicName=ERROR_JOURNAL_NOT_ACTIVE -Language=LTH -ERROR_JOURNAL_NOT_ACTIVE -. -MessageId=1180 -SymbolicName=ERROR_POTENTIAL_FILE_FOUND -Language=LTH -ERROR_POTENTIAL_FILE_FOUND -. -MessageId=1181 -SymbolicName=ERROR_JOURNAL_ENTRY_DELETED -Language=LTH -ERROR_JOURNAL_ENTRY_DELETED -. -MessageId=1200 -SymbolicName=ERROR_BAD_DEVICE -Language=LTH -Neteisingas įrenginio vardas -. -MessageId=1201 -SymbolicName=ERROR_CONNECTION_UNAVAIL -Language=LTH -Ryšys negalimas -. -MessageId=1202 -SymbolicName=ERROR_DEVICE_ALREADY_REMEMBERED -Language=LTH -Įrenginys jau atsimintas -. -MessageId=1203 -SymbolicName=ERROR_NO_NET_OR_BAD_PATH -Language=LTH -Nėra tinklo arba blogas kelias -. -MessageId=1204 -SymbolicName=ERROR_BAD_PROVIDER -Language=LTH -Neteisingas tinklo tiekėjo vardas -. -MessageId=1205 -SymbolicName=ERROR_CANNOT_OPEN_PROFILE -Language=LTH -Nepavyko atverti tinklo ryšio profilio -. -MessageId=1206 -SymbolicName=ERROR_BAD_PROFILE -Language=LTH -Pažeistas tinklo ryšio profilis -. -MessageId=1207 -SymbolicName=ERROR_NOT_CONTAINER -Language=LTH -Ne konteineris -. -MessageId=1208 -SymbolicName=ERROR_EXTENDED_ERROR -Language=LTH -Išplėstinė klaida -. -MessageId=1209 -SymbolicName=ERROR_INVALID_GROUPNAME -Language=LTH -Neteisingas grupės vardas -. -MessageId=1210 -SymbolicName=ERROR_INVALID_COMPUTERNAME -Language=LTH -Neteisingas kompiuterio vardas -. -MessageId=1211 -SymbolicName=ERROR_INVALID_EVENTNAME -Language=LTH -Neteisingas įvykio vardas -. -MessageId=1212 -SymbolicName=ERROR_INVALID_DOMAINNAME -Language=LTH -Neteisingas srities vardas -. -MessageId=1213 -SymbolicName=ERROR_INVALID_SERVICENAME -Language=LTH -Neteisingas tarnybos vardas -. -MessageId=1214 -SymbolicName=ERROR_INVALID_NETNAME -Language=LTH -Neteisingas tinklo vardas -. -MessageId=1215 -SymbolicName=ERROR_INVALID_SHARENAME -Language=LTH -Neteisingas viešinio vardas -. -MessageId=1216 -SymbolicName=ERROR_INVALID_PASSWORDNAME -Language=LTH -Neteisingas slaptažodis -. -MessageId=1217 -SymbolicName=ERROR_INVALID_MESSAGENAME -Language=LTH -Neteisingas pranešimo vardas -. -MessageId=1218 -SymbolicName=ERROR_INVALID_MESSAGEDEST -Language=LTH -Neteisinga pranešimo paskirtis -. -MessageId=1219 -SymbolicName=ERROR_SESSION_CREDENTIAL_CONFLICT -Language=LTH -Seanso kredencialų konfliktas -. -MessageId=1220 -SymbolicName=ERROR_REMOTE_SESSION_LIMIT_EXCEEDED -Language=LTH -Viršyta nuotolinių seansų riba -. -MessageId=1221 -SymbolicName=ERROR_DUP_DOMAINNAME -Language=LTH -Vienodi sričių ar darbo grupių vardai -. -MessageId=1222 -SymbolicName=ERROR_NO_NETWORK -Language=LTH -Nėra tinklo -. -MessageId=1223 -SymbolicName=ERROR_CANCELLED -Language=LTH -Operacija nutraukta naudotojo -. -MessageId=1224 -SymbolicName=ERROR_USER_MAPPED_FILE -Language=LTH -Failas turi naudotojo atvaizduotą sekciją -. -MessageId=1225 -SymbolicName=ERROR_CONNECTION_REFUSED -Language=LTH -Sujungimas nepriimtas -. -MessageId=1226 -SymbolicName=ERROR_GRACEFUL_DISCONNECT -Language=LTH -Sujungimas grakščiai nutrauktas -. -MessageId=1227 -SymbolicName=ERROR_ADDRESS_ALREADY_ASSOCIATED -Language=LTH -Adresas jau susietas su transporto galutiniu tašku -. -MessageId=1228 -SymbolicName=ERROR_ADDRESS_NOT_ASSOCIATED -Language=LTH -Adresas nesusietas su transporto galutiniu tašku -. -MessageId=1229 -SymbolicName=ERROR_CONNECTION_INVALID -Language=LTH -Sujungimas negaliojantis -. -MessageId=1230 -SymbolicName=ERROR_CONNECTION_ACTIVE -Language=LTH -Sujungimas aktyvus -. -MessageId=1231 -SymbolicName=ERROR_NETWORK_UNREACHABLE -Language=LTH -Tinklas nepasiekiamas -. -MessageId=1232 -SymbolicName=ERROR_HOST_UNREACHABLE -Language=LTH -Serveris nepasiekiamas -. -MessageId=1233 -SymbolicName=ERROR_PROTOCOL_UNREACHABLE -Language=LTH -Protokolas nepasiekiamas -. -MessageId=1234 -SymbolicName=ERROR_PORT_UNREACHABLE -Language=LTH -Prievadas nepasiekiamas -. -MessageId=1235 -SymbolicName=ERROR_REQUEST_ABORTED -Language=LTH -Užklausa nutraukta -. -MessageId=1236 -SymbolicName=ERROR_CONNECTION_ABORTED -Language=LTH -Sujungimas nutrauktas -. -MessageId=1237 -SymbolicName=ERROR_RETRY -Language=LTH -Prašome pakartoti operaciją -. -MessageId=1238 -SymbolicName=ERROR_CONNECTION_COUNT_LIMIT -Language=LTH -Pasiekta sujungimų kiekio riba -. -MessageId=1239 -SymbolicName=ERROR_LOGIN_TIME_RESTRICTION -Language=LTH -Prisijungimo laiko ribojimas -. -MessageId=1240 -SymbolicName=ERROR_LOGIN_WKSTA_RESTRICTION -Language=LTH -Prisijungimo darbo vietos ribojimas -. -MessageId=1241 -SymbolicName=ERROR_INCORRECT_ADDRESS -Language=LTH -Neteisingas tinklo adresas -. -MessageId=1242 -SymbolicName=ERROR_ALREADY_REGISTERED -Language=LTH -Tarnyba jau užregistruota -. -MessageId=1243 -SymbolicName=ERROR_SERVICE_NOT_FOUND -Language=LTH -Tarnyba nerasta -. -MessageId=1244 -SymbolicName=ERROR_NOT_AUTHENTICATED -Language=LTH -Naudotojo tapatumas nenustatytas -. -MessageId=1245 -SymbolicName=ERROR_NOT_LOGGED_ON -Language=LTH -Naudotojas neprisijungęs -. -MessageId=1246 -SymbolicName=ERROR_CONTINUE -Language=LTH -Tęsti pradėtą darbą -. -MessageId=1247 -SymbolicName=ERROR_ALREADY_INITIALIZED -Language=LTH -Jau inicijuota -. -MessageId=1248 -SymbolicName=ERROR_NO_MORE_DEVICES -Language=LTH -Nėra daugiau vietinių įrenginių -. -MessageId=1249 -SymbolicName=ERROR_NO_SUCH_SITE -Language=LTH -ERROR_NO_SUCH_SITE -. -MessageId=1250 -SymbolicName=ERROR_DOMAIN_CONTROLLER_EXISTS -Language=LTH -ERROR_DOMAIN_CONTROLLER_EXISTS -. -MessageId=1251 -SymbolicName=ERROR_ONLY_IF_CONNECTED -Language=LTH -ERROR_ONLY_IF_CONNECTED -. -MessageId=1252 -SymbolicName=ERROR_OVERRIDE_NOCHANGES -Language=LTH -ERROR_OVERRIDE_NOCHANGES -. -MessageId=1253 -SymbolicName=ERROR_BAD_USER_PROFILE -Language=LTH -ERROR_BAD_USER_PROFILE -. -MessageId=1254 -SymbolicName=ERROR_NOT_SUPPORTED_ON_SBS -Language=LTH -ERROR_NOT_SUPPORTED_ON_SBS -. -MessageId=1300 -SymbolicName=ERROR_NOT_ALL_ASSIGNED -Language=LTH -Priskirtos ne visos teisės -. -MessageId=1301 -SymbolicName=ERROR_SOME_NOT_MAPPED -Language=LTH -Atvaizduoti ne visi saugumo identifikatoriai -. -MessageId=1302 -SymbolicName=ERROR_NO_QUOTAS_FOR_ACCOUNT -Language=LTH -Paskyra neturi kvotų -. -MessageId=1303 -SymbolicName=ERROR_LOCAL_USER_SESSION_KEY -Language=LTH -Vietinio naudotojo seanso raktas -. -MessageId=1304 -SymbolicName=ERROR_NULL_LM_PASSWORD -Language=LTH -Per sudėtingas LM slaptažodis -. -MessageId=1305 -SymbolicName=ERROR_UNKNOWN_REVISION -Language=LTH -Nežinomas poversijis -. -MessageId=1306 -SymbolicName=ERROR_REVISION_MISMATCH -Language=LTH -Nesuderinami poversijų lygiai -. -MessageId=1307 -SymbolicName=ERROR_INVALID_OWNER -Language=LTH -Netinkamas valdytojas -. -MessageId=1308 -SymbolicName=ERROR_INVALID_PRIMARY_GROUP -Language=LTH -Neteisinga pirminė grupė -. -MessageId=1309 -SymbolicName=ERROR_NO_IMPERSONATION_TOKEN -Language=LTH -Nėra apsimetimo prieigos rakto -. -MessageId=1310 -SymbolicName=ERROR_CANT_DISABLE_MANDATORY -Language=LTH -Negalima išjungti privalomos grupės -. -MessageId=1311 -SymbolicName=ERROR_NO_LOGON_SERVERS -Language=LTH -Nėra pasiekiamų prisijungimo serverių -. -MessageId=1312 -SymbolicName=ERROR_NO_SUCH_LOGON_SESSION -Language=LTH -Nėra tokio prisijungimo seanso -. -MessageId=1313 -SymbolicName=ERROR_NO_SUCH_PRIVILEGE -Language=LTH -Nėra tokios teisės -. -MessageId=1314 -SymbolicName=ERROR_PRIVILEGE_NOT_HELD -Language=LTH -Teisė neturima -. -MessageId=1315 -SymbolicName=ERROR_INVALID_ACCOUNT_NAME -Language=LTH -Neteisingas paskyros vardas -. -MessageId=1316 -SymbolicName=ERROR_USER_EXISTS -Language=LTH -Naudotojas jau egzistuoja -. -MessageId=1317 -SymbolicName=ERROR_NO_SUCH_USER -Language=LTH -Nėra tokio naudotojo -. -MessageId=1318 -SymbolicName=ERROR_GROUP_EXISTS -Language=LTH -Grupė jau egzistuoja -. -MessageId=1319 -SymbolicName=ERROR_NO_SUCH_GROUP -Language=LTH -Nėra tokios grupės -. -MessageId=1320 -SymbolicName=ERROR_MEMBER_IN_GROUP -Language=LTH -Naudotojas jau grupėje -. -MessageId=1321 -SymbolicName=ERROR_MEMBER_NOT_IN_GROUP -Language=LTH -Naudotojas ne grupėje -. -MessageId=1322 -SymbolicName=ERROR_LAST_ADMIN -Language=LTH -Negalima pašalinti paskutinio naudotojo administratoriaus -. -MessageId=1323 -SymbolicName=ERROR_WRONG_PASSWORD -Language=LTH -Neteisingas slaptažodis -. -MessageId=1324 -SymbolicName=ERROR_ILL_FORMED_PASSWORD -Language=LTH -Blogai sudarytas slaptažodis -. -MessageId=1325 -SymbolicName=ERROR_PASSWORD_RESTRICTION -Language=LTH -Slaptažodžio ribojimas -. -MessageId=1326 -SymbolicName=ERROR_LOGON_FAILURE -Language=LTH -Prisijungimo klaida -. -MessageId=1327 -SymbolicName=ERROR_ACCOUNT_RESTRICTION -Language=LTH -Paskyros ribojimas -. -MessageId=1328 -SymbolicName=ERROR_INVALID_LOGON_HOURS -Language=LTH -Neteisingos prisijungimo valandos -. -MessageId=1329 -SymbolicName=ERROR_INVALID_WORKSTATION -Language=LTH -Neteisinga darbo vieta -. -MessageId=1330 -SymbolicName=ERROR_PASSWORD_EXPIRED -Language=LTH -Slaptažodis nebegaliojantis -. -MessageId=1331 -SymbolicName=ERROR_ACCOUNT_DISABLED -Language=LTH -Paskyra išjungta -. -MessageId=1332 -SymbolicName=ERROR_NONE_MAPPED -Language=LTH -Nėra atvaizduotų saugumo identifikatorių -. -MessageId=1333 -SymbolicName=ERROR_TOO_MANY_LUIDS_REQUESTED -Language=LTH -Užklausta per daug LUID -. -MessageId=1334 -SymbolicName=ERROR_LUIDS_EXHAUSTED -Language=LTH -LUID išnaudoti -. -MessageId=1335 -SymbolicName=ERROR_INVALID_SUB_AUTHORITY -Language=LTH -Neteisingas žemesnis autoritetas -. -MessageId=1336 -SymbolicName=ERROR_INVALID_ACL -Language=LTH -Neteisingas ACL -. -MessageId=1337 -SymbolicName=ERROR_INVALID_SID -Language=LTH -Neteisingas SID -. -MessageId=1338 -SymbolicName=ERROR_INVALID_SECURITY_DESCR -Language=LTH -Neteisingas saugumo aprašas -. -MessageId=1340 -SymbolicName=ERROR_BAD_INHERITANCE_ACL -Language=LTH -Blogas paveldėtas ACL -. -MessageId=1341 -SymbolicName=ERROR_SERVER_DISABLED -Language=LTH -Serveris išjungtas -. -MessageId=1342 -SymbolicName=ERROR_SERVER_NOT_DISABLED -Language=LTH -Serveris neišjungtas -. -MessageId=1343 -SymbolicName=ERROR_INVALID_ID_AUTHORITY -Language=LTH -Neteisingas identifikatoriaus autoritetas -. -MessageId=1344 -SymbolicName=ERROR_ALLOTTED_SPACE_EXCEEDED -Language=LTH -Viršyta paskirta vieta -. -MessageId=1345 -SymbolicName=ERROR_INVALID_GROUP_ATTRIBUTES -Language=LTH -Neteisingi grupės požymiai -. -MessageId=1346 -SymbolicName=ERROR_BAD_IMPERSONATION_LEVEL -Language=LTH -Blogas apsimetimo lygis -. -MessageId=1347 -SymbolicName=ERROR_CANT_OPEN_ANONYMOUS -Language=LTH -Nepavyko atverti anoniminio saugumo prieigos rakto -. -MessageId=1348 -SymbolicName=ERROR_BAD_VALIDATION_CLASS -Language=LTH -Bloga tikrinimo klasė -. -MessageId=1349 -SymbolicName=ERROR_BAD_TOKEN_TYPE -Language=LTH -Blogas prieigos rakto tipas -. -MessageId=1350 -SymbolicName=ERROR_NO_SECURITY_ON_OBJECT -Language=LTH -Nėra saugumo objektui -. -MessageId=1351 -SymbolicName=ERROR_CANT_ACCESS_DOMAIN_INFO -Language=LTH -Nepavyko prieiti prie srities informacijos -. -MessageId=1352 -SymbolicName=ERROR_INVALID_SERVER_STATE -Language=LTH -Neteisinga serverio būsena -. -MessageId=1353 -SymbolicName=ERROR_INVALID_DOMAIN_STATE -Language=LTH -Neteisinga srities būsena -. -MessageId=1354 -SymbolicName=ERROR_INVALID_DOMAIN_ROLE -Language=LTH -Neteisinga srities rolė -. -MessageId=1355 -SymbolicName=ERROR_NO_SUCH_DOMAIN -Language=LTH -Nėra tokios srities -. -MessageId=1356 -SymbolicName=ERROR_DOMAIN_EXISTS -Language=LTH -Sritis jau egzistuoja -. -MessageId=1357 -SymbolicName=ERROR_DOMAIN_LIMIT_EXCEEDED -Language=LTH -Viršyta sričių riba -. -MessageId=1358 -SymbolicName=ERROR_INTERNAL_DB_CORRUPTION -Language=LTH -Pažeista vidinė duomenų bazė -. -MessageId=1359 -SymbolicName=ERROR_INTERNAL_ERROR -Language=LTH -Vidinė klaida -. -MessageId=1360 -SymbolicName=ERROR_GENERIC_NOT_MAPPED -Language=LTH -Daugybiniai prieigos tipai neatvaizduoti -. -MessageId=1361 -SymbolicName=ERROR_BAD_DESCRIPTOR_FORMAT -Language=LTH -Blogas aprašo formatas -. -MessageId=1362 -SymbolicName=ERROR_NOT_LOGON_PROCESS -Language=LTH -Ne prisijungimo procesas -. -MessageId=1363 -SymbolicName=ERROR_LOGON_SESSION_EXISTS -Language=LTH -Prisijungimo seanso identifikatorius egzistuoja -. -MessageId=1364 -SymbolicName=ERROR_NO_SUCH_PACKAGE -Language=LTH -Nežinomas tapatybės nustatymo paketas -. -MessageId=1365 -SymbolicName=ERROR_BAD_LOGON_SESSION_STATE -Language=LTH -Bloga prisijungimo seanso būsena -. -MessageId=1366 -SymbolicName=ERROR_LOGON_SESSION_COLLISION -Language=LTH -Prisijungimo seanso identifikatorių konfliktas -. -MessageId=1367 -SymbolicName=ERROR_INVALID_LOGON_TYPE -Language=LTH -Neteisingas prisijungimo tipas -. -MessageId=1368 -SymbolicName=ERROR_CANNOT_IMPERSONATE -Language=LTH -Nepavyko apsimesti -. -MessageId=1369 -SymbolicName=ERROR_RXACT_INVALID_STATE -Language=LTH -Neteisinga tranzakcijos būsena -. -MessageId=1370 -SymbolicName=ERROR_RXACT_COMMIT_FAILURE -Language=LTH -Saugumo duomenų bazės nusiuntimo klaida -. -MessageId=1371 -SymbolicName=ERROR_SPECIAL_ACCOUNT -Language=LTH -Paskyra yra įtaisyta -. -MessageId=1372 -SymbolicName=ERROR_SPECIAL_GROUP -Language=LTH -Grupė yra įtaisyta -. -MessageId=1373 -SymbolicName=ERROR_SPECIAL_USER -Language=LTH -Naudotojas yra įtaisytas -. -MessageId=1374 -SymbolicName=ERROR_MEMBERS_PRIMARY_GROUP -Language=LTH -Grupė yra pirminė naudotojui -. -MessageId=1375 -SymbolicName=ERROR_TOKEN_ALREADY_IN_USE -Language=LTH -Prieigos raktas jau naudojamas -. -MessageId=1376 -SymbolicName=ERROR_NO_SUCH_ALIAS -Language=LTH -Nėra tokios vietinės grupės -. -MessageId=1377 -SymbolicName=ERROR_MEMBER_NOT_IN_ALIAS -Language=LTH -Naudotojas ne vietinėje grupėje -. -MessageId=1378 -SymbolicName=ERROR_MEMBER_IN_ALIAS -Language=LTH -Naudotojas jau vietinėje grupėje -. -MessageId=1379 -SymbolicName=ERROR_ALIAS_EXISTS -Language=LTH -Vietinė grupė jau egzistuoja -. -MessageId=1380 -SymbolicName=ERROR_LOGON_NOT_GRANTED -Language=LTH -Nesutikta su prisijungimo tipu -. -MessageId=1381 -SymbolicName=ERROR_TOO_MANY_SECRETS -Language=LTH -Per daug paslapčių -. -MessageId=1382 -SymbolicName=ERROR_SECRET_TOO_LONG -Language=LTH -Paslaptis per ilga -. -MessageId=1383 -SymbolicName=ERROR_INTERNAL_DB_ERROR -Language=LTH -Vidinė saugumo duomenų bazės klaida -. -MessageId=1384 -SymbolicName=ERROR_TOO_MANY_CONTEXT_IDS -Language=LTH -Per daug konteksto identifikatorių -. -MessageId=1385 -SymbolicName=ERROR_LOGON_TYPE_NOT_GRANTED -Language=LTH -Nesutikta su prisijungimo tipu -. -MessageId=1386 -SymbolicName=ERROR_NT_CROSS_ENCRYPTION_REQUIRED -Language=LTH -Reikalingas kryžmiškai užšifruotas NT slaptažodis -. -MessageId=1387 -SymbolicName=ERROR_NO_SUCH_MEMBER -Language=LTH -Nėra tokio nario -. -MessageId=1388 -SymbolicName=ERROR_INVALID_MEMBER -Language=LTH -Neteisingas narys -. -MessageId=1389 -SymbolicName=ERROR_TOO_MANY_SIDS -Language=LTH -Per daug SID -. -MessageId=1390 -SymbolicName=ERROR_LM_CROSS_ENCRYPTION_REQUIRED -Language=LTH -Reikalingas kryžmiškai užšifruotas LM slaptažodis -. -MessageId=1391 -SymbolicName=ERROR_NO_INHERITANCE -Language=LTH -Nėra paveldimų komponentų -. -MessageId=1392 -SymbolicName=ERROR_FILE_CORRUPT -Language=LTH -Failas ar katalogas pažeisti -. -MessageId=1393 -SymbolicName=ERROR_DISK_CORRUPT -Language=LTH -Diskas yra pažeistas -. -MessageId=1394 -SymbolicName=ERROR_NO_USER_SESSION_KEY -Language=LTH -Nėra naudotojo seanso rakto -. -MessageId=1395 -SymbolicName=ERROR_LICENSE_QUOTA_EXCEEDED -Language=LTH -Viršyta licencijų kvota -. -MessageId=1396 -SymbolicName=ERROR_WRONG_TARGET_NAME -Language=LTH -ERROR_WRONG_TARGET_NAME -. -MessageId=1397 -SymbolicName=ERROR_MUTUAL_AUTH_FAILED -Language=LTH -ERROR_MUTUAL_AUTH_FAILED -. -MessageId=1398 -SymbolicName=ERROR_TIME_SKEW -Language=LTH -ERROR_TIME_SKEW -. -MessageId=1400 -SymbolicName=ERROR_INVALID_WINDOW_HANDLE -Language=LTH -Klaidinga lango rodyklė -. -MessageId=1401 -SymbolicName=ERROR_INVALID_MENU_HANDLE -Language=LTH -Klaidinga meniu rodyklė -. -MessageId=1402 -SymbolicName=ERROR_INVALID_CURSOR_HANDLE -Language=LTH -Neteisinga žymeklio rodyklė -. -MessageId=1403 -SymbolicName=ERROR_INVALID_ACCEL_HANDLE -Language=LTH -Neteisinga prieigos klavišų lentelės rodyklė -. -MessageId=1404 -SymbolicName=ERROR_INVALID_HOOK_HANDLE -Language=LTH -Neteisinga hook rodyklė -. -MessageId=1405 -SymbolicName=ERROR_INVALID_DWP_HANDLE -Language=LTH -Neteisinga DWP rodyklė -. -MessageId=1406 -SymbolicName=ERROR_TLW_WITH_WSCHILD -Language=LTH -Nepavyko sukurti aukščiausio lygio polangio -. -MessageId=1407 -SymbolicName=ERROR_CANNOT_FIND_WND_CLASS -Language=LTH -Nerasta lango klasė -. -MessageId=1408 -SymbolicName=ERROR_WINDOW_OF_OTHER_THREAD -Language=LTH -Langas valdomas kitos gijos -. -MessageId=1409 -SymbolicName=ERROR_HOTKEY_ALREADY_REGISTERED -Language=LTH -Spartusis klavišas jau registruotas -. -MessageId=1410 -SymbolicName=ERROR_CLASS_ALREADY_EXISTS -Language=LTH -Klasė jau egzistuoja -. -MessageId=1411 -SymbolicName=ERROR_CLASS_DOES_NOT_EXIST -Language=LTH -Klasė neegzistuoja -. -MessageId=1412 -SymbolicName=ERROR_CLASS_HAS_WINDOWS -Language=LTH -Klasė turi atvertų langų -. -MessageId=1413 -SymbolicName=ERROR_INVALID_INDEX -Language=LTH -Neteisingas indeksas -. -MessageId=1414 -SymbolicName=ERROR_INVALID_ICON_HANDLE -Language=LTH -Neteisinga piktogramos rodyklė -. -MessageId=1415 -SymbolicName=ERROR_PRIVATE_DIALOG_INDEX -Language=LTH -Privataus dialogo lango indeksas -. -MessageId=1416 -SymbolicName=ERROR_LISTBOX_ID_NOT_FOUND -Language=LTH -Nerastas sąrašo langelio identifikatorius -. -MessageId=1417 -SymbolicName=ERROR_NO_WILDCARD_CHARACTERS -Language=LTH -Nerasti pakaitos simboliai -. -MessageId=1418 -SymbolicName=ERROR_CLIPBOARD_NOT_OPEN -Language=LTH -Iškarpinė neatverta -. -MessageId=1419 -SymbolicName=ERROR_HOTKEY_NOT_REGISTERED -Language=LTH -Spartusis klavišas neregistruotas -. -MessageId=1420 -SymbolicName=ERROR_WINDOW_NOT_DIALOG -Language=LTH -Ne dialogo langas -. -MessageId=1421 -SymbolicName=ERROR_CONTROL_ID_NOT_FOUND -Language=LTH -Valdiklio identifikatorius nerastas -. -MessageId=1422 -SymbolicName=ERROR_INVALID_COMBOBOX_MESSAGE -Language=LTH -Neteisingas išskleidžiamojo sąrašo pranešimas -. -MessageId=1423 -SymbolicName=ERROR_WINDOW_NOT_COMBOBOX -Language=LTH -Ne išskleidžiamojo sąrašo langas -. -MessageId=1424 -SymbolicName=ERROR_INVALID_EDIT_HEIGHT -Language=LTH -Neteisingas aukštis -. -MessageId=1425 -SymbolicName=ERROR_DC_NOT_FOUND -Language=LTH -DC nerastas -. -MessageId=1426 -SymbolicName=ERROR_INVALID_HOOK_FILTER -Language=LTH -Neteisingas hook filtras -. -MessageId=1427 -SymbolicName=ERROR_INVALID_FILTER_PROC -Language=LTH -Neteisinga filtro procedūra -. -MessageId=1428 -SymbolicName=ERROR_HOOK_NEEDS_HMOD -Language=LTH -Hook procedūrai reikalinga modulio rodyklė -. -MessageId=1429 -SymbolicName=ERROR_GLOBAL_ONLY_HOOK -Language=LTH -Tik globali hook procedūra -. -MessageId=1430 -SymbolicName=ERROR_JOURNAL_HOOK_SET -Language=LTH -Žurnalo hook jau nustatytas -. -MessageId=1431 -SymbolicName=ERROR_HOOK_NOT_INSTALLED -Language=LTH -Hook procedūra neįdiegta -. -MessageId=1432 -SymbolicName=ERROR_INVALID_LB_MESSAGE -Language=LTH -Neteisingas sąrašo langelio pranešimas -. -MessageId=1433 -SymbolicName=ERROR_SETCOUNT_ON_BAD_LB -Language=LTH -Išsiųstas neteisingas LB_SETCOUNT -. -MessageId=1434 -SymbolicName=ERROR_LB_WITHOUT_TABSTOPS -Language=LTH -Sąrašo langelis be tabuliavimo pozicijų -. -MessageId=1435 -SymbolicName=ERROR_DESTROY_OBJECT_OF_OTHER_THREAD -Language=LTH -Negalima sunaikinti objekto valdomo kitos gijos -. -MessageId=1436 -SymbolicName=ERROR_CHILD_WINDOW_MENU -Language=LTH -Polangio meniu neleidžiami -. -MessageId=1437 -SymbolicName=ERROR_NO_SYSTEM_MENU -Language=LTH -Langas neturi sisteminio meniu -. -MessageId=1438 -SymbolicName=ERROR_INVALID_MSGBOX_STYLE -Language=LTH -Neteisingas pranešimo lango stilius -. -MessageId=1439 -SymbolicName=ERROR_INVALID_SPI_VALUE -Language=LTH -Neteisingas SPI parametras -. -MessageId=1440 -SymbolicName=ERROR_SCREEN_ALREADY_LOCKED -Language=LTH -Ekranas jau užblokuotas -. -MessageId=1441 -SymbolicName=ERROR_HWNDS_HAVE_DIFF_PARENT -Language=LTH -Langų rodyklės turi skirtingus viršlangius -. -MessageId=1442 -SymbolicName=ERROR_NOT_CHILD_WINDOW -Language=LTH -Ne polangis -. -MessageId=1443 -SymbolicName=ERROR_INVALID_GW_COMMAND -Language=LTH -Neteisinga GW komanda -. -MessageId=1444 -SymbolicName=ERROR_INVALID_THREAD_ID -Language=LTH -Neteisingas gijos identifikatorius -. -MessageId=1445 -SymbolicName=ERROR_NON_MDICHILD_WINDOW -Language=LTH -Ne MDI polangis -. -MessageId=1446 -SymbolicName=ERROR_POPUP_ALREADY_ACTIVE -Language=LTH -Iškylantis meniu jau aktyvus -. -MessageId=1447 -SymbolicName=ERROR_NO_SCROLLBARS -Language=LTH -Nėra slankjuosčių -. -MessageId=1448 -SymbolicName=ERROR_INVALID_SCROLLBAR_RANGE -Language=LTH -Neteisingi slankjuostės rėžiai -. -MessageId=1449 -SymbolicName=ERROR_INVALID_SHOWWIN_COMMAND -Language=LTH -Neteisinga ShowWin komanda -. -MessageId=1450 -SymbolicName=ERROR_NO_SYSTEM_RESOURCES -Language=LTH -Nėra sistemos išteklių -. -MessageId=1451 -SymbolicName=ERROR_NONPAGED_SYSTEM_RESOURCES -Language=LTH -Nėra nesukeičiamų sistemos išteklių -. -MessageId=1452 -SymbolicName=ERROR_PAGED_SYSTEM_RESOURCES -Language=LTH -Nėra sukeičiamų sistemos išteklių -. -MessageId=1453 -SymbolicName=ERROR_WORKING_SET_QUOTA -Language=LTH -Nėra darbinio rinkinio kvotos -. -MessageId=1454 -SymbolicName=ERROR_PAGEFILE_QUOTA -Language=LTH -Nėra sukeitimų failo kvotos -. -MessageId=1455 -SymbolicName=ERROR_COMMITMENT_LIMIT -Language=LTH -Viršyta virtualios atminties riba -. -MessageId=1456 -SymbolicName=ERROR_MENU_ITEM_NOT_FOUND -Language=LTH -Meniu elementas nerastas -. -MessageId=1457 -SymbolicName=ERROR_INVALID_KEYBOARD_HANDLE -Language=LTH -ERROR_INVALID_KEYBOARD_HANDLE -. -MessageId=1458 -SymbolicName=ERROR_HOOK_TYPE_NOT_ALLOWED -Language=LTH -ERROR_HOOK_TYPE_NOT_ALLOWED -. -MessageId=1459 -SymbolicName=ERROR_REQUIRES_INTERACTIVE_WINDOWSTATION -Language=LTH -ERROR_REQUIRES_INTERACTIVE_WINDOWSTATION -. -MessageId=1460 -SymbolicName=ERROR_TIMEOUT -Language=LTH -ERROR_TIMEOUT -. -MessageId=1461 -SymbolicName=ERROR_INVALID_MONITOR_HANDLE -Language=LTH -ERROR_INVALID_MONITOR_HANDLE -. -MessageId=1500 -SymbolicName=ERROR_EVENTLOG_FILE_CORRUPT -Language=LTH -Įvykių žurnalo failas pažeistas -. -MessageId=1501 -SymbolicName=ERROR_EVENTLOG_CANT_START -Language=LTH -Nepavyko paleisti įvykių žurnalo -. -MessageId=1502 -SymbolicName=ERROR_LOG_FILE_FULL -Language=LTH -Įvykių žurnalo failas pilnas -. -MessageId=1503 -SymbolicName=ERROR_EVENTLOG_FILE_CHANGED -Language=LTH -Įvykių žurnalo failas pasikeitė -. -MessageId=1601 -SymbolicName=ERROR_INSTALL_SERVICE_FAILURE -Language=LTH -ERROR_INSTALL_SERVICE_FAILURE -. -MessageId=1602 -SymbolicName=ERROR_INSTALL_USEREXIT -Language=LTH -ERROR_INSTALL_USEREXIT -. -MessageId=1603 -SymbolicName=ERROR_INSTALL_FAILURE -Language=LTH -ERROR_INSTALL_FAILURE -. -MessageId=1604 -SymbolicName=ERROR_INSTALL_SUSPEND -Language=LTH -ERROR_INSTALL_SUSPEND -. -MessageId=1605 -SymbolicName=ERROR_UNKNOWN_PRODUCT -Language=LTH -ERROR_UNKNOWN_PRODUCT -. -MessageId=1606 -SymbolicName=ERROR_UNKNOWN_FEATURE -Language=LTH -ERROR_UNKNOWN_FEATURE -. -MessageId=1607 -SymbolicName=ERROR_UNKNOWN_COMPONENT -Language=LTH -ERROR_UNKNOWN_COMPONENT -. -MessageId=1608 -SymbolicName=ERROR_UNKNOWN_PROPERTY -Language=LTH -ERROR_UNKNOWN_PROPERTY -. -MessageId=1609 -SymbolicName=ERROR_INVALID_HANDLE_STATE -Language=LTH -ERROR_INVALID_HANDLE_STATE -. -MessageId=1610 -SymbolicName=ERROR_BAD_CONFIGURATION -Language=LTH -ERROR_BAD_CONFIGURATION -. -MessageId=1611 -SymbolicName=ERROR_INDEX_ABSENT -Language=LTH -ERROR_INDEX_ABSENT -. -MessageId=1612 -SymbolicName=ERROR_INSTALL_SOURCE_ABSENT -Language=LTH -ERROR_INSTALL_SOURCE_ABSENT -. -MessageId=1613 -SymbolicName=ERROR_INSTALL_PACKAGE_VERSION -Language=LTH -ERROR_INSTALL_PACKAGE_VERSION -. -MessageId=1614 -SymbolicName=ERROR_PRODUCT_UNINSTALLED -Language=LTH -ERROR_PRODUCT_UNINSTALLED -. -MessageId=1615 -SymbolicName=ERROR_BAD_QUERY_SYNTAX -Language=LTH -ERROR_BAD_QUERY_SYNTAX -. -MessageId=1616 -SymbolicName=ERROR_INVALID_FIELD -Language=LTH -ERROR_INVALID_FIELD -. -MessageId=1617 -SymbolicName=ERROR_DEVICE_REMOVED -Language=LTH -ERROR_DEVICE_REMOVED -. -MessageId=1618 -SymbolicName=ERROR_INSTALL_ALREADY_RUNNING -Language=LTH -ERROR_INSTALL_ALREADY_RUNNING -. -MessageId=1619 -SymbolicName=ERROR_INSTALL_PACKAGE_OPEN_FAILED -Language=LTH -ERROR_INSTALL_PACKAGE_OPEN_FAILED -. -MessageId=1620 -SymbolicName=ERROR_INSTALL_PACKAGE_INVALID -Language=LTH -ERROR_INSTALL_PACKAGE_INVALID -. -MessageId=1621 -SymbolicName=ERROR_INSTALL_UI_FAILURE -Language=LTH -ERROR_INSTALL_UI_FAILURE -. -MessageId=1622 -SymbolicName=ERROR_INSTALL_LOG_FAILURE -Language=LTH -ERROR_INSTALL_LOG_FAILURE -. -MessageId=1623 -SymbolicName=ERROR_INSTALL_LANGUAGE_UNSUPPORTED -Language=LTH -ERROR_INSTALL_LANGUAGE_UNSUPPORTED -. -MessageId=1624 -SymbolicName=ERROR_INSTALL_TRANSFORM_FAILURE -Language=LTH -ERROR_INSTALL_TRANSFORM_FAILURE -. -MessageId=1625 -SymbolicName=ERROR_INSTALL_PACKAGE_REJECTED -Language=LTH -ERROR_INSTALL_PACKAGE_REJECTED -. -MessageId=1626 -SymbolicName=ERROR_FUNCTION_NOT_CALLED -Language=LTH -ERROR_FUNCTION_NOT_CALLED -. -MessageId=1627 -SymbolicName=ERROR_FUNCTION_FAILED -Language=LTH -ERROR_FUNCTION_FAILED -. -MessageId=1628 -SymbolicName=ERROR_INVALID_TABLE -Language=LTH -ERROR_INVALID_TABLE -. -MessageId=1629 -SymbolicName=ERROR_DATATYPE_MISMATCH -Language=LTH -ERROR_DATATYPE_MISMATCH -. -MessageId=1630 -SymbolicName=ERROR_UNSUPPORTED_TYPE -Language=LTH -ERROR_UNSUPPORTED_TYPE -. -MessageId=1631 -SymbolicName=ERROR_CREATE_FAILED -Language=LTH -ERROR_CREATE_FAILED -. -MessageId=1632 -SymbolicName=ERROR_INSTALL_TEMP_UNWRITABLE -Language=LTH -ERROR_INSTALL_TEMP_UNWRITABLE -. -MessageId=1633 -SymbolicName=ERROR_INSTALL_PLATFORM_UNSUPPORTED -Language=LTH -ERROR_INSTALL_PLATFORM_UNSUPPORTED -. -MessageId=1634 -SymbolicName=ERROR_INSTALL_NOTUSED -Language=LTH -ERROR_INSTALL_NOTUSED -. -MessageId=1635 -SymbolicName=ERROR_PATCH_PACKAGE_OPEN_FAILED -Language=LTH -ERROR_PATCH_PACKAGE_OPEN_FAILED -. -MessageId=1636 -SymbolicName=ERROR_PATCH_PACKAGE_INVALID -Language=LTH -ERROR_PATCH_PACKAGE_INVALID -. -MessageId=1637 -SymbolicName=ERROR_PATCH_PACKAGE_UNSUPPORTED -Language=LTH -ERROR_PATCH_PACKAGE_UNSUPPORTED -. -MessageId=1638 -SymbolicName=ERROR_PRODUCT_VERSION -Language=LTH -ERROR_PRODUCT_VERSION -. -MessageId=1639 -SymbolicName=ERROR_INVALID_COMMAND_LINE -Language=LTH -ERROR_INVALID_COMMAND_LINE -. -MessageId=1640 -SymbolicName=ERROR_INSTALL_REMOTE_DISALLOWED -Language=LTH -ERROR_INSTALL_REMOTE_DISALLOWED -. -MessageId=1641 -SymbolicName=ERROR_SUCCESS_REBOOT_INITIATED -Language=LTH -ERROR_SUCCESS_REBOOT_INITIATED -. -MessageId=1700 -SymbolicName=RPC_S_INVALID_STRING_BINDING -Language=LTH -Neteisingas simbolių eilučių saistymas -. -MessageId=1701 -SymbolicName=RPC_S_WRONG_KIND_OF_BINDING -Language=LTH -Neteisinga saistymo rūšis -. -MessageId=1702 -SymbolicName=RPC_S_INVALID_BINDING -Language=LTH -Neteisingas saistymas -. -MessageId=1703 -SymbolicName=RPC_S_PROTSEQ_NOT_SUPPORTED -Language=LTH -RPC protokolo seka nepalaikoma -. -MessageId=1704 -SymbolicName=RPC_S_INVALID_RPC_PROTSEQ -Language=LTH -Neteisinga RPC protokolo seka -. -MessageId=1705 -SymbolicName=RPC_S_INVALID_STRING_UUID -Language=LTH -Neteisingas UUID -. -MessageId=1706 -SymbolicName=RPC_S_INVALID_ENDPOINT_FORMAT -Language=LTH -Neteisingas galutinio taško formatas -. -MessageId=1707 -SymbolicName=RPC_S_INVALID_NET_ADDR -Language=LTH -Neteisingas tinklo adresas -. -MessageId=1708 -SymbolicName=RPC_S_NO_ENDPOINT_FOUND -Language=LTH -Nerastas galutinis taškas -. -MessageId=1709 -SymbolicName=RPC_S_INVALID_TIMEOUT -Language=LTH -Neteisinga laiko baigimosi reikšmė -. -MessageId=1710 -SymbolicName=RPC_S_OBJECT_NOT_FOUND -Language=LTH -Objekto UUID nerastas -. -MessageId=1711 -SymbolicName=RPC_S_ALREADY_REGISTERED -Language=LTH -UUID jau registruotas -. -MessageId=1712 -SymbolicName=RPC_S_TYPE_ALREADY_REGISTERED -Language=LTH -UUID tipas jau registruotas -. -MessageId=1713 -SymbolicName=RPC_S_ALREADY_LISTENING -Language=LTH -Serveris jau klausosi -. -MessageId=1714 -SymbolicName=RPC_S_NO_PROTSEQS_REGISTERED -Language=LTH -Neužregistruota jokia protokolo seka -. -MessageId=1715 -SymbolicName=RPC_S_NOT_LISTENING -Language=LTH -RPC serveris nesiklauso -. -MessageId=1716 -SymbolicName=RPC_S_UNKNOWN_MGR_TYPE -Language=LTH -Nežinomas tvarkytuvės tipas -. -MessageId=1717 -SymbolicName=RPC_S_UNKNOWN_IF -Language=LTH -Nežinoma sąsaja -. -MessageId=1718 -SymbolicName=RPC_S_NO_BINDINGS -Language=LTH -Nėra saistymų -. -MessageId=1719 -SymbolicName=RPC_S_NO_PROTSEQS -Language=LTH -Nėra protokolo sekų -. -MessageId=1720 -SymbolicName=RPC_S_CANT_CREATE_ENDPOINT -Language=LTH -Nepavyko sukurti galutinio taško -. -MessageId=1721 -SymbolicName=RPC_S_OUT_OF_RESOURCES -Language=LTH -Trūksta išteklių -. -MessageId=1722 -SymbolicName=RPC_S_SERVER_UNAVAILABLE -Language=LTH -RPC serveris nepasiekiamas -. -MessageId=1723 -SymbolicName=RPC_S_SERVER_TOO_BUSY -Language=LTH -RPC serveris per daug užsiėmęs -. -MessageId=1724 -SymbolicName=RPC_S_INVALID_NETWORK_OPTIONS -Language=LTH -Neteisingos tinklo nuostatos -. -MessageId=1725 -SymbolicName=RPC_S_NO_CALL_ACTIVE -Language=LTH -Nėra aktyvaus RPC kreipinio -. -MessageId=1726 -SymbolicName=RPC_S_CALL_FAILED -Language=LTH -RPC kreipinys nepavyko -. -MessageId=1727 -SymbolicName=RPC_S_CALL_FAILED_DNE -Language=LTH -RPC kreipinys nepavyko ir nebuvo įvykdytas -. -MessageId=1728 -SymbolicName=RPC_S_PROTOCOL_ERROR -Language=LTH -RPC protokolo klaida -. -MessageId=1730 -SymbolicName=RPC_S_UNSUPPORTED_TRANS_SYN -Language=LTH -Nepalaikoma perdavimo sintaksė -. -MessageId=1732 -SymbolicName=RPC_S_UNSUPPORTED_TYPE -Language=LTH -Nepalaikomas tipas -. -MessageId=1733 -SymbolicName=RPC_S_INVALID_TAG -Language=LTH -Neteisinga žymė -. -MessageId=1734 -SymbolicName=RPC_S_INVALID_BOUND -Language=LTH -Neteisingos masyvo ribos -. -MessageId=1735 -SymbolicName=RPC_S_NO_ENTRY_NAME -Language=LTH -Nėra įrašo vardo -. -MessageId=1736 -SymbolicName=RPC_S_INVALID_NAME_SYNTAX -Language=LTH -Neteisinga vardo sintaksė -. -MessageId=1737 -SymbolicName=RPC_S_UNSUPPORTED_NAME_SYNTAX -Language=LTH -Nepalaikoma vardo sintaksė -. -MessageId=1739 -SymbolicName=RPC_S_UUID_NO_ADDRESS -Language=LTH -Nėra tinklo adreso -. -MessageId=1740 -SymbolicName=RPC_S_DUPLICATE_ENDPOINT -Language=LTH -Dvigubas pabaigos taškas -. -MessageId=1741 -SymbolicName=RPC_S_UNKNOWN_AUTHN_TYPE -Language=LTH -Nežinomas tapatumo nustatymo tipas -. -MessageId=1742 -SymbolicName=RPC_S_MAX_CALLS_TOO_SMALL -Language=LTH -Didžiausias kreipinių skaičius per mažas -. -MessageId=1743 -SymbolicName=RPC_S_STRING_TOO_LONG -Language=LTH -Eilutė per ilga -. -MessageId=1744 -SymbolicName=RPC_S_PROTSEQ_NOT_FOUND -Language=LTH -Protokolo seka nerasta -. -MessageId=1745 -SymbolicName=RPC_S_PROCNUM_OUT_OF_RANGE -Language=LTH -Procedūros numeris ne tarp rėžių -. -MessageId=1746 -SymbolicName=RPC_S_BINDING_HAS_NO_AUTH -Language=LTH -Saistymas neturi tapatumo nustatymo duomenų -. -MessageId=1747 -SymbolicName=RPC_S_UNKNOWN_AUTHN_SERVICE -Language=LTH -Nežinoma tapatumo nustatymo tarnyba -. -MessageId=1748 -SymbolicName=RPC_S_UNKNOWN_AUTHN_LEVEL -Language=LTH -Nežinomas tapatumo nustatymo lygis -. -MessageId=1749 -SymbolicName=RPC_S_INVALID_AUTH_IDENTITY -Language=LTH -Neteisinga tapatumo nustatymo tapatybė -. -MessageId=1750 -SymbolicName=RPC_S_UNKNOWN_AUTHZ_SERVICE -Language=LTH -Nežinoma prieigos teisių tarnyba -. -MessageId=1751 -SymbolicName=EPT_S_INVALID_ENTRY -Language=LTH -Neteisingas įrašas -. -MessageId=1752 -SymbolicName=EPT_S_CANT_PERFORM_OP -Language=LTH -Nepavyko įvykdyti operacijos -. -MessageId=1753 -SymbolicName=EPT_S_NOT_REGISTERED -Language=LTH -Pabaigos taškai neregistruoti -. -MessageId=1754 -SymbolicName=RPC_S_NOTHING_TO_EXPORT -Language=LTH -Nėra ką eksportuoti -. -MessageId=1755 -SymbolicName=RPC_S_INCOMPLETE_NAME -Language=LTH -Nevisas vardas -. -MessageId=1756 -SymbolicName=RPC_S_INVALID_VERS_OPTION -Language=LTH -Neteisinga versijos išvestis -. -MessageId=1757 -SymbolicName=RPC_S_NO_MORE_MEMBERS -Language=LTH -Nėra daugiau narių -. -MessageId=1758 -SymbolicName=RPC_S_NOT_ALL_OBJS_UNEXPORTED -Language=LTH -Ne visi objektai importuoti -. -MessageId=1759 -SymbolicName=RPC_S_INTERFACE_NOT_FOUND -Language=LTH -Sąsaja nerasta -. -MessageId=1760 -SymbolicName=RPC_S_ENTRY_ALREADY_EXISTS -Language=LTH -Įrašas jau egzistuoja -. -MessageId=1761 -SymbolicName=RPC_S_ENTRY_NOT_FOUND -Language=LTH -Įrašas nerastas -. -MessageId=1762 -SymbolicName=RPC_S_NAME_SERVICE_UNAVAILABLE -Language=LTH -Vardų tarnyba nepasiekiama -. -MessageId=1763 -SymbolicName=RPC_S_INVALID_NAF_ID -Language=LTH -Neteisinga tinklo adresų šeima -. -MessageId=1764 -SymbolicName=RPC_S_CANNOT_SUPPORT -Language=LTH -Operacija nepalaikoma -. -MessageId=1765 -SymbolicName=RPC_S_NO_CONTEXT_AVAILABLE -Language=LTH -Nėra saugumo konteksto -. -MessageId=1766 -SymbolicName=RPC_S_INTERNAL_ERROR -Language=LTH -RPC vidinė klaida -. -MessageId=1767 -SymbolicName=RPC_S_ZERO_DIVIDE -Language=LTH -RPC dalyba iš nulio -. -MessageId=1768 -SymbolicName=RPC_S_ADDRESS_ERROR -Language=LTH -Adreso klaida -. -MessageId=1769 -SymbolicName=RPC_S_FP_DIV_ZERO -Language=LTH -Slankiojo kablelio skaičiaus dalyba iš nulio -. -MessageId=1770 -SymbolicName=RPC_S_FP_UNDERFLOW -Language=LTH -Slankiojo kablelio skaičiaus atvirkštinis perpildymas -. -MessageId=1771 -SymbolicName=RPC_S_FP_OVERFLOW -Language=LTH -Slankiojo kablelio skaičiaus perpildymas -. -MessageId=1772 -SymbolicName=RPC_X_NO_MORE_ENTRIES -Language=LTH -Nėra daugiau įrašų -. -MessageId=1773 -SymbolicName=RPC_X_SS_CHAR_TRANS_OPEN_FAIL -Language=LTH -Nepavyko atverti ženklų perkodavimo lentelės -. -MessageId=1774 -SymbolicName=RPC_X_SS_CHAR_TRANS_SHORT_FILE -Language=LTH -Ženklų perkodavimo lentelės failas per mažas -. -MessageId=1775 -SymbolicName=RPC_X_SS_IN_NULL_CONTEXT -Language=LTH -Nulinė konteksto rodyklė -. -MessageId=1777 -SymbolicName=RPC_X_SS_CONTEXT_DAMAGED -Language=LTH -Pažeista konteksto rodyklė -. -MessageId=1778 -SymbolicName=RPC_X_SS_HANDLES_MISMATCH -Language=LTH -Saistymo rodyklių neatitiktis -. -MessageId=1779 -SymbolicName=RPC_X_SS_CANNOT_GET_CALL_HANDLE -Language=LTH -Nepavyko gauti kreipties rodyklės -. -MessageId=1780 -SymbolicName=RPC_X_NULL_REF_POINTER -Language=LTH -Nulinė rodyklė -. -MessageId=1781 -SymbolicName=RPC_X_ENUM_VALUE_OUT_OF_RANGE -Language=LTH -Išvardijimo reikšmė ne tarp rėžių -. -MessageId=1782 -SymbolicName=RPC_X_BYTE_COUNT_TOO_SMALL -Language=LTH -Gautas baitų skaičius per mažas -. -MessageId=1783 -SymbolicName=RPC_X_BAD_STUB_DATA -Language=LTH -Blogi stub duomenys -. -MessageId=1784 -SymbolicName=ERROR_INVALID_USER_BUFFER -Language=LTH -Netinkamas naudotojo buferis -. -MessageId=1785 -SymbolicName=ERROR_UNRECOGNIZED_MEDIA -Language=LTH -Neatpažinta laikmena -. -MessageId=1786 -SymbolicName=ERROR_NO_TRUST_LSA_SECRET -Language=LTH -Nėra patikėjimo paslapties -. -MessageId=1787 -SymbolicName=ERROR_NO_TRUST_SAM_ACCOUNT -Language=LTH -Nėra patikimos SAM paskyros -. -MessageId=1788 -SymbolicName=ERROR_TRUSTED_DOMAIN_FAILURE -Language=LTH -Patikimos srities klaida -. -MessageId=1789 -SymbolicName=ERROR_TRUSTED_RELATIONSHIP_FAILURE -Language=LTH -Patikimo ryšio klaida -. -MessageId=1790 -SymbolicName=ERROR_TRUST_FAILURE -Language=LTH -Patikimo prisijungimo klaida -. -MessageId=1791 -SymbolicName=RPC_S_CALL_IN_PROGRESS -Language=LTH -RPC kreipinys jau vyksta -. -MessageId=1792 -SymbolicName=ERROR_NETLOGON_NOT_STARTED -Language=LTH -NETLOGON nepaleistas -. -MessageId=1793 -SymbolicName=ERROR_ACCOUNT_EXPIRED -Language=LTH -Paskyra nebegalioja -. -MessageId=1794 -SymbolicName=ERROR_REDIRECTOR_HAS_OPEN_HANDLES -Language=LTH -Nukreiptuvė turi atvertų rodyklių -. -MessageId=1795 -SymbolicName=ERROR_PRINTER_DRIVER_ALREADY_INSTALLED -Language=LTH -Spausdintuvo tvarkyklė jau įdiegta -. -MessageId=1796 -SymbolicName=ERROR_UNKNOWN_PORT -Language=LTH -Nežinomas prievadas -. -MessageId=1797 -SymbolicName=ERROR_UNKNOWN_PRINTER_DRIVER -Language=LTH -Nežinoma spausdintuvo tvarkyklė -. -MessageId=1798 -SymbolicName=ERROR_UNKNOWN_PRINTPROCESSOR -Language=LTH -Nežinoma spausdinimo doroklė -. -MessageId=1799 -SymbolicName=ERROR_INVALID_SEPARATOR_FILE -Language=LTH -Neteisingas skirtuko failas -. -MessageId=1800 -SymbolicName=ERROR_INVALID_PRIORITY -Language=LTH -Neteisingas prioritetas -. -MessageId=1801 -SymbolicName=ERROR_INVALID_PRINTER_NAME -Language=LTH -Neteisingas spausdintuvo vardas -. -MessageId=1802 -SymbolicName=ERROR_PRINTER_ALREADY_EXISTS -Language=LTH -Spausdintuvas jau egzistuoja -. -MessageId=1803 -SymbolicName=ERROR_INVALID_PRINTER_COMMAND -Language=LTH -Neteisinga spausdintuvo komanda -. -MessageId=1804 -SymbolicName=ERROR_INVALID_DATATYPE -Language=LTH -Neteisingas duomenų tipas -. -MessageId=1805 -SymbolicName=ERROR_INVALID_ENVIRONMENT -Language=LTH -Neteisinga aplinka -. -MessageId=1806 -SymbolicName=RPC_S_NO_MORE_BINDINGS -Language=LTH -Nėra daugiau saistymų -. -MessageId=1807 -SymbolicName=ERROR_NOLOGON_INTERDOMAIN_TRUST_ACCOUNT -Language=LTH -Negalima prisijungti su tarpsritine patikima paskyra -. -MessageId=1808 -SymbolicName=ERROR_NOLOGON_WORKSTATION_TRUST_ACCOUNT -Language=LTH -Negalima prisijungti su darbo vietos patikima paskyra -. -MessageId=1809 -SymbolicName=ERROR_NOLOGON_SERVER_TRUST_ACCOUNT -Language=LTH -Negalima prisijungti su serverio patikima paskyra -. -MessageId=1810 -SymbolicName=ERROR_DOMAIN_TRUST_INCONSISTENT -Language=LTH -Srities patikėjimo informacija prieštaringa -. -MessageId=1811 -SymbolicName=ERROR_SERVER_HAS_OPEN_HANDLES -Language=LTH -Serveris turi atvirų rodyklių -. -MessageId=1812 -SymbolicName=ERROR_RESOURCE_DATA_NOT_FOUND -Language=LTH -Išteklių duomenys nerasti -. -MessageId=1813 -SymbolicName=ERROR_RESOURCE_TYPE_NOT_FOUND -Language=LTH -Išteklių tipas nerastas -. -MessageId=1814 -SymbolicName=ERROR_RESOURCE_NAME_NOT_FOUND -Language=LTH -Išteklių vardas nerastas -. -MessageId=1815 -SymbolicName=ERROR_RESOURCE_LANG_NOT_FOUND -Language=LTH -Išteklių kalba nerasta -. -MessageId=1816 -SymbolicName=ERROR_NOT_ENOUGH_QUOTA -Language=LTH -Per maža kvota -. -MessageId=1817 -SymbolicName=RPC_S_NO_INTERFACES -Language=LTH -Nėra sąsajų -. -MessageId=1818 -SymbolicName=RPC_S_CALL_CANCELLED -Language=LTH -RPC kreipinys nutrauktas -. -MessageId=1819 -SymbolicName=RPC_S_BINDING_INCOMPLETE -Language=LTH -Saistymas nepilnas -. -MessageId=1820 -SymbolicName=RPC_S_COMM_FAILURE -Language=LTH -RPC ryšio klaida -. -MessageId=1821 -SymbolicName=RPC_S_UNSUPPORTED_AUTHN_LEVEL -Language=LTH -Nepalaikomas prieigos teisių lygis -. -MessageId=1822 -SymbolicName=RPC_S_NO_PRINC_NAME -Language=LTH -Pagrindinis vardas neužregistruotas -. -MessageId=1823 -SymbolicName=RPC_S_NOT_RPC_ERROR -Language=LTH -Ne RPC klaida -. -MessageId=1824 -SymbolicName=RPC_S_UUID_LOCAL_ONLY -Language=LTH -UUID yra tik vietinis -. -MessageId=1825 -SymbolicName=RPC_S_SEC_PKG_ERROR -Language=LTH -Saugumo paketo klaida -. -MessageId=1826 -SymbolicName=RPC_S_NOT_CANCELLED -Language=LTH -Gija nenutraukta -. -MessageId=1827 -SymbolicName=RPC_X_INVALID_ES_ACTION -Language=LTH -Neteisinga rodyklės operacija -. -MessageId=1828 -SymbolicName=RPC_X_WRONG_ES_VERSION -Language=LTH -Neteisinga sekų išdėstymo paketo versija -. -MessageId=1829 -SymbolicName=RPC_X_WRONG_STUB_VERSION -Language=LTH -Neteisinga stub versija -. -MessageId=1830 -SymbolicName=RPC_X_INVALID_PIPE_OBJECT -Language=LTH -Neteisingas kanalo objektas -. -MessageId=1831 -SymbolicName=RPC_X_WRONG_PIPE_ORDER -Language=LTH -Neteisinga kanalo tvarka -. -MessageId=1832 -SymbolicName=RPC_X_WRONG_PIPE_VERSION -Language=LTH -Neteisinga kanalo versija -. -MessageId=1898 -SymbolicName=RPC_S_GROUP_MEMBER_NOT_FOUND -Language=LTH -Grupės narys nerastas -. -MessageId=1899 -SymbolicName=EPT_S_CANT_CREATE -Language=LTH -Nepavyko sukurti pabaigos taškų atvaizdavimo DB -. -MessageId=1900 -SymbolicName=RPC_S_INVALID_OBJECT -Language=LTH -Neteisingas objektas -. -MessageId=1901 -SymbolicName=ERROR_INVALID_TIME -Language=LTH -Neteisingas laikas -. -MessageId=1902 -SymbolicName=ERROR_INVALID_FORM_NAME -Language=LTH -Neteisingas formos vardas -. -MessageId=1903 -SymbolicName=ERROR_INVALID_FORM_SIZE -Language=LTH -Neteisingas formos dydis -. -MessageId=1904 -SymbolicName=ERROR_ALREADY_WAITING -Language=LTH -Jau laukiama spausdintuvo rodyklės -. -MessageId=1905 -SymbolicName=ERROR_PRINTER_DELETED -Language=LTH -Spausdintuvas ištrintas -. -MessageId=1906 -SymbolicName=ERROR_INVALID_PRINTER_STATE -Language=LTH -Neteisinga spausdintuvo būsena -. -MessageId=1907 -SymbolicName=ERROR_PASSWORD_MUST_CHANGE -Language=LTH -Naudotojas privalo pakeisti slaptažodį -. -MessageId=1908 -SymbolicName=ERROR_DOMAIN_CONTROLLER_NOT_FOUND -Language=LTH -Sričių valdiklis nerastas -. -MessageId=1909 -SymbolicName=ERROR_ACCOUNT_LOCKED_OUT -Language=LTH -Paskyra užblokuota -. -MessageId=1910 -SymbolicName=OR_INVALID_OXID -Language=LTH -Neteisingas pikselio formatas -. -MessageId=1911 -SymbolicName=OR_INVALID_OID -Language=LTH -Neteisinga tvarkyklė -. -MessageId=1912 -SymbolicName=OR_INVALID_SET -Language=LTH -OR_INVALID_SET -. -MessageId=1913 -SymbolicName=RPC_S_SEND_INCOMPLETE -Language=LTH -RPC_S_SEND_INCOMPLETE -. -MessageId=1914 -SymbolicName=RPC_S_INVALID_ASYNC_HANDLE -Language=LTH -RPC_S_INVALID_ASYNC_HANDLE -. -MessageId=1915 -SymbolicName=RPC_S_INVALID_ASYNC_CALL -Language=LTH -RPC_S_INVALID_ASYNC_CALL -. -MessageId=1916 -SymbolicName=RPC_X_PIPE_CLOSED -Language=LTH -RPC_X_PIPE_CLOSED -. -MessageId=1917 -SymbolicName=RPC_X_PIPE_DISCIPLINE_ERROR -Language=LTH -RPC_X_PIPE_DISCIPLINE_ERROR -. -MessageId=1918 -SymbolicName=RPC_X_PIPE_EMPTY -Language=LTH -RPC_X_PIPE_EMPTY -. -MessageId=1919 -SymbolicName=ERROR_NO_SITENAME -Language=LTH -ERROR_NO_SITENAME -. -MessageId=1920 -SymbolicName=ERROR_CANT_ACCESS_FILE -Language=LTH -ERROR_CANT_ACCESS_FILE -. -MessageId=1921 -SymbolicName=ERROR_CANT_RESOLVE_FILENAME -Language=LTH -ERROR_CANT_RESOLVE_FILENAME -. -MessageId=1922 -SymbolicName=RPC_S_ENTRY_TYPE_MISMATCH -Language=LTH -RPC_S_ENTRY_TYPE_MISMATCH -. -MessageId=1923 -SymbolicName=RPC_S_NOT_ALL_OBJS_EXPORTED -Language=LTH -RPC_S_NOT_ALL_OBJS_EXPORTED -. -MessageId=1924 -SymbolicName=RPC_S_INTERFACE_NOT_EXPORTED -Language=LTH -RPC_S_INTERFACE_NOT_EXPORTED -. -MessageId=1925 -SymbolicName=RPC_S_PROFILE_NOT_ADDED -Language=LTH -RPC_S_PROFILE_NOT_ADDED -. -MessageId=1926 -SymbolicName=RPC_S_PRF_ELT_NOT_ADDED -Language=LTH -RPC_S_PRF_ELT_NOT_ADDED -. -MessageId=1927 -SymbolicName=RPC_S_PRF_ELT_NOT_REMOVED -Language=LTH -RPC_S_PRF_ELT_NOT_REMOVED -. -MessageId=1928 -SymbolicName=RPC_S_GRP_ELT_NOT_ADDED -Language=LTH -RPC_S_GRP_ELT_NOT_ADDED -. -MessageId=1929 -SymbolicName=RPC_S_GRP_ELT_NOT_REMOVED -Language=LTH -RPC_S_GRP_ELT_NOT_REMOVED -. -MessageId=2221 -SymbolicName=NERR_UserNotFound -Language=LTH -Naudotojo vardas nerastas -. diff --git a/dlls/kernel32/nls/winerr_nld.mc b/dlls/kernel32/nls/winerr_nld.mc index 5682c2b2198..ab583d9dbfb 100644 --- a/dlls/kernel32/nls/winerr_nld.mc +++ b/dlls/kernel32/nls/winerr_nld.mc @@ -17,7 +17,6 @@ ; LanguageNames=(NLD=0x0013:winerr) -CodePages=(NLD=1252:0) MessageId=0 SymbolicName=ERROR_SUCCESS @@ -3729,8 +3728,3 @@ SymbolicName=RPC_S_GRP_ELT_NOT_REMOVED Language=NLD RPC_S_GRP_ELT_NOT_REMOVED . -MessageId=2221 -SymbolicName=NERR_UserNotFound -Language=NLD -Gebruikersnaam niet gevonden -. diff --git a/dlls/kernel32/nls/winerr_nor.mc b/dlls/kernel32/nls/winerr_nor.mc index 0afa520bbbf..497a14dcde0 100644 --- a/dlls/kernel32/nls/winerr_nor.mc +++ b/dlls/kernel32/nls/winerr_nor.mc @@ -18,7 +18,6 @@ ; LanguageNames=(NOR=0x414:winerr) -CodePages=(NOR=1252:0) MessageId=0 SymbolicName=ERROR_SUCCESS diff --git a/dlls/kernel32/nls/winerr_plk.mc b/dlls/kernel32/nls/winerr_plk.mc index cb1517bbae5..1e5dec34678 100644 --- a/dlls/kernel32/nls/winerr_plk.mc +++ b/dlls/kernel32/nls/winerr_plk.mc @@ -17,7 +17,6 @@ ; LanguageNames=(PLK=0x0015:winerr) -CodePages=(PLK=1250:0) MessageId=0 SymbolicName=ERROR_SUCCESS diff --git a/dlls/kernel32/path.c b/dlls/kernel32/path.c index 299db1cc185..2633d901df5 100644 --- a/dlls/kernel32/path.c +++ b/dlls/kernel32/path.c @@ -1521,22 +1521,10 @@ UINT WINAPI GetSystemDirectoryA( LPSTR path, UINT count ) * - On Win32 we should returns ERROR_CALL_NOT_IMPLEMENTED * - On Win64 we should returns the SysWow64 (system64) directory */ -UINT WINAPI GetSystemWow64DirectoryW( LPWSTR path, UINT count ) +UINT WINAPI GetSystemWow64DirectoryW( LPWSTR lpBuffer, UINT uSize ) { - UINT len; - - if (!DIR_SysWow64) - { - SetLastError( ERROR_CALL_NOT_IMPLEMENTED ); - return 0; - } - len = strlenW( DIR_SysWow64 ) + 1; - if (path && count >= len) - { - strcpyW( path, DIR_SysWow64 ); - len--; - } - return len; + SetLastError( ERROR_CALL_NOT_IMPLEMENTED ); + return 0; } @@ -1545,47 +1533,30 @@ UINT WINAPI GetSystemWow64DirectoryW( LPWSTR path, UINT count ) * * See comment for GetWindowsWow64DirectoryW. */ -UINT WINAPI GetSystemWow64DirectoryA( LPSTR path, UINT count ) +UINT WINAPI GetSystemWow64DirectoryA( LPSTR lpBuffer, UINT uSize ) { - if (!DIR_SysWow64) - { - SetLastError( ERROR_CALL_NOT_IMPLEMENTED ); - return 0; - } - return copy_filename_WtoA( DIR_SysWow64, path, count ); -} - - -/*********************************************************************** - * Wow64EnableWow64FsRedirection (KERNEL32.@) - */ -BOOLEAN WINAPI Wow64EnableWow64FsRedirection( BOOLEAN enable ) -{ - NTSTATUS status = RtlWow64EnableFsRedirection( enable ); - if (status) SetLastError( RtlNtStatusToDosError(status) ); - return !status; + SetLastError( ERROR_CALL_NOT_IMPLEMENTED ); + return 0; } - /*********************************************************************** * Wow64DisableWow64FsRedirection (KERNEL32.@) */ BOOL WINAPI Wow64DisableWow64FsRedirection( PVOID *old_value ) { - NTSTATUS status = RtlWow64EnableFsRedirectionEx( TRUE, (ULONG *)old_value ); - if (status) SetLastError( RtlNtStatusToDosError(status) ); - return !status; -} + FIXME("%p\n", old_value); + if (old_value) *old_value = (void *)0xdeadbeef; + return TRUE; +} /*********************************************************************** * Wow64RevertWow64FsRedirection (KERNEL32.@) */ BOOL WINAPI Wow64RevertWow64FsRedirection( PVOID old_value ) { - NTSTATUS status = RtlWow64EnableFsRedirection( (UINT_PTR)old_value ); - if (status) SetLastError( RtlNtStatusToDosError(status) ); - return !status; + FIXME("%p\n", old_value); + return TRUE; } diff --git a/dlls/kernel32/process.c b/dlls/kernel32/process.c index f90b294950a..83d1aa5f68a 100644 --- a/dlls/kernel32/process.c +++ b/dlls/kernel32/process.c @@ -76,13 +76,11 @@ static UINT process_error_mode; static DWORD shutdown_flags = 0; static DWORD shutdown_priority = 0x280; static DWORD process_dword; -static BOOL is_wow64; HMODULE kernel32_handle = 0; const WCHAR *DIR_Windows = NULL; const WCHAR *DIR_System = NULL; -const WCHAR *DIR_SysWow64 = NULL; /* Process flags */ #define PDB32_DEBUGGED 0x0001 /* Process is being debugged */ @@ -824,7 +822,6 @@ static void init_windows_dirs(void) static const WCHAR winsysdirW[] = {'w','i','n','s','y','s','d','i','r',0}; static const WCHAR default_windirW[] = {'C',':','\\','w','i','n','d','o','w','s',0}; static const WCHAR default_sysdirW[] = {'\\','s','y','s','t','e','m','3','2',0}; - static const WCHAR default_syswow64W[] = {'\\','s','y','s','w','o','w','6','4',0}; DWORD len; WCHAR *buffer; @@ -852,17 +849,6 @@ static void init_windows_dirs(void) DIR_System = buffer; } -#ifndef _WIN64 /* SysWow64 is always defined on 64-bit */ - if (is_wow64) -#endif - { - len = strlenW( DIR_Windows ); - buffer = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) + sizeof(default_syswow64W) ); - memcpy( buffer, DIR_Windows, len * sizeof(WCHAR) ); - memcpy( buffer + len, default_syswow64W, sizeof(default_syswow64W) ); - DIR_SysWow64 = buffer; - } - if (!CreateDirectoryW( DIR_Windows, NULL ) && GetLastError() != ERROR_ALREADY_EXISTS) ERR( "directory %s could not be created, error %u\n", debugstr_w(DIR_Windows), GetLastError() ); @@ -1024,7 +1010,6 @@ void CDECL __wine_kernel_init(void) setbuf(stdout,NULL); setbuf(stderr,NULL); kernel32_handle = GetModuleHandleW(kernel32W); - IsWow64Process( GetCurrentProcess(), &is_wow64 ); LOCALE_Init(); @@ -1319,18 +1304,12 @@ static int fork_and_exec( const char *filename, const WCHAR *cmdline, const WCHA if (!env) env = GetEnvironmentStringsW(); -#ifdef HAVE_PIPE2 - if (pipe2( fd, O_CLOEXEC ) == -1) -#endif + if (pipe(fd) == -1) { - if (pipe(fd) == -1) - { - SetLastError( ERROR_TOO_MANY_OPEN_FILES ); - return -1; - } - fcntl( fd[0], F_SETFD, FD_CLOEXEC ); - fcntl( fd[1], F_SETFD, FD_CLOEXEC ); + SetLastError( ERROR_TOO_MANY_OPEN_FILES ); + return -1; } + fcntl( fd[1], F_SETFD, 1 ); /* set close on exec */ if (!(flags & (CREATE_NEW_PROCESS_GROUP | CREATE_NEW_CONSOLE | DETACHED_PROCESS))) { @@ -3324,12 +3303,3 @@ HRESULT WINAPI RegisterApplicationRestart(PCWSTR pwzCommandLine, DWORD dwFlags) return S_OK; } - -/********************************************************************** - * WTSGetActiveConsoleSessionId (KERNEL32.@) - */ -DWORD WINAPI WTSGetActiveConsoleSessionId(void) -{ - FIXME("stub\n"); - return 0; -} diff --git a/dlls/kernel32/relay16.c b/dlls/kernel32/relay16.c index b3ac234af33..a2a550cc23f 100644 --- a/dlls/kernel32/relay16.c +++ b/dlls/kernel32/relay16.c @@ -283,35 +283,26 @@ static const CALLFROM16 *get_entry_point( STACK16FRAME *frame, LPSTR module, LPS extern int call_entry_point( void *func, int nb_args, const int *args ); __ASM_GLOBAL_FUNC( call_entry_point, - "pushl %ebp\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %ebp,0\n\t") - "movl %esp,%ebp\n\t" - __ASM_CFI(".cfi_def_cfa_register %ebp\n\t") - "pushl %esi\n\t" - __ASM_CFI(".cfi_rel_offset %esi,-4\n\t") - "pushl %edi\n\t" - __ASM_CFI(".cfi_rel_offset %edi,-8\n\t") - "movl 12(%ebp),%edx\n\t" - "shll $2,%edx\n\t" - "jz 1f\n\t" - "subl %edx,%esp\n\t" - "andl $~15,%esp\n\t" - "movl 12(%ebp),%ecx\n\t" - "movl 16(%ebp),%esi\n\t" - "movl %esp,%edi\n\t" - "cld\n\t" - "rep; movsl\n" - "1:\tcall *8(%ebp)\n\t" - "leal -8(%ebp),%esp\n\t" - "popl %edi\n\t" - __ASM_CFI(".cfi_same_value %edi\n\t") - "popl %esi\n\t" - __ASM_CFI(".cfi_same_value %esi\n\t") - "popl %ebp\n\t" - __ASM_CFI(".cfi_def_cfa %esp,4\n\t") - __ASM_CFI(".cfi_same_value %ebp\n\t") - "ret" ) + "\tpushl %ebp\n" + "\tmovl %esp,%ebp\n" + "\tpushl %esi\n" + "\tpushl %edi\n" + "\tmovl 12(%ebp),%edx\n" + "\tshll $2,%edx\n" + "\tjz 1f\n" + "\tsubl %edx,%esp\n" + "\tandl $~15,%esp\n" + "\tmovl 12(%ebp),%ecx\n" + "\tmovl 16(%ebp),%esi\n" + "\tmovl %esp,%edi\n" + "\tcld\n" + "\trep; movsl\n" + "1:\tcall *8(%ebp)\n" + "\tleal -8(%ebp),%esp\n" + "\tpopl %edi\n" + "\tpopl %esi\n" + "\tpopl %ebp\n" + "\tret" ) /*********************************************************************** diff --git a/dlls/kernel32/tests/codepage.c b/dlls/kernel32/tests/codepage.c index 61d0c33af97..906124156b7 100644 --- a/dlls/kernel32/tests/codepage.c +++ b/dlls/kernel32/tests/codepage.c @@ -320,7 +320,7 @@ static void test_string_conversion(LPBOOL bUsedDefaultChar) SetLastError(0xdeadbeef); ret = WideCharToMultiByte(950, 0, dbwcs, -1, mbs, sizeof(mbs), NULL, bUsedDefaultChar); ok(ret == 5, "ret is %d\n", ret); - ok(!strcmp(mbs, "\xb5H\xa9\xd2"), "mbs is %s\n", mbs); + ok(!strcmp(mbs, "µH©Ò"), "mbs is %s\n", mbs); if(bUsedDefaultChar) ok(*bUsedDefaultChar == FALSE, "bUsedDefaultChar is %d\n", *bUsedDefaultChar); ok(GetLastError() == 0xdeadbeef, "GetLastError() is %u\n", GetLastError()); @@ -334,7 +334,7 @@ static void test_string_conversion(LPBOOL bUsedDefaultChar) SetLastError(0xdeadbeef); ret = WideCharToMultiByte(950, 0, dbwcs, 1, mbs, sizeof(mbs), NULL, bUsedDefaultChar); ok(ret == 2, "ret is %d\n", ret); - ok(!strcmp(mbs, "\xb5H"), "mbs is %s\n", mbs); + ok(!strcmp(mbs, "µH"), "mbs is %s\n", mbs); if(bUsedDefaultChar) ok(*bUsedDefaultChar == FALSE, "bUsedDefaultChar is %d\n", *bUsedDefaultChar); ok(GetLastError() == 0xdeadbeef, "GetLastError() is %u\n", GetLastError()); diff --git a/dlls/kernel32/tests/virtual.c b/dlls/kernel32/tests/virtual.c index b7e97db667c..e665f0f3b96 100644 --- a/dlls/kernel32/tests/virtual.c +++ b/dlls/kernel32/tests/virtual.c @@ -284,40 +284,6 @@ static void test_VirtualAlloc(void) ok(old_prot == PAGE_READONLY, "wrong old protection: got %04x instead of PAGE_READONLY\n", old_prot); - ok(VirtualQuery(addr1, &info, sizeof(info)) == sizeof(info), - "VirtualQuery failed\n"); - ok(info.RegionSize == 0x1000, "%lx != 0x1000\n", info.RegionSize); - ok(info.State == MEM_COMMIT, "%x != MEM_COMMIT\n", info.State); - ok(info.Protect == PAGE_READWRITE, "%x != PAGE_READWRITE\n", info.Protect); - memset( addr1, 0x55, 20 ); - ok( *(DWORD *)addr1 == 0x55555555, "wrong data %x\n", *(DWORD *)addr1 ); - - addr2 = VirtualAlloc( addr1, 0x1000, MEM_RESET, PAGE_NOACCESS ); - ok( addr2 == addr1 || broken( !addr2 && GetLastError() == ERROR_INVALID_PARAMETER), /* win9x */ - "VirtualAlloc failed err %u\n", GetLastError() ); - ok( *(DWORD *)addr1 == 0x55555555 || *(DWORD *)addr1 == 0, "wrong data %x\n", *(DWORD *)addr1 ); - if (addr2) - { - ok(VirtualQuery(addr1, &info, sizeof(info)) == sizeof(info), - "VirtualQuery failed\n"); - ok(info.RegionSize == 0x1000, "%lx != 0x1000\n", info.RegionSize); - ok(info.State == MEM_COMMIT, "%x != MEM_COMMIT\n", info.State); - ok(info.Protect == PAGE_READWRITE, "%x != PAGE_READWRITE\n", info.Protect); - - addr2 = VirtualAlloc( (char *)addr1 + 0x1000, 0x1000, MEM_RESET, PAGE_NOACCESS ); - ok( (char *)addr2 == (char *)addr1 + 0x1000, "VirtualAlloc failed\n" ); - - ok(VirtualQuery(addr2, &info, sizeof(info)) == sizeof(info), - "VirtualQuery failed\n"); - ok(info.RegionSize == 0xf000, "%lx != 0xf000\n", info.RegionSize); - ok(info.State == MEM_RESERVE, "%x != MEM_RESERVE\n", info.State); - ok(info.Protect == 0, "%x != 0\n", info.Protect); - - addr2 = VirtualAlloc( (char *)addr1 + 0xf000, 0x2000, MEM_RESET, PAGE_NOACCESS ); - ok( !addr2, "VirtualAlloc failed\n" ); - ok( GetLastError() == ERROR_INVALID_ADDRESS, "wrong error %u\n", GetLastError() ); - } - /* invalid protection values */ SetLastError(0xdeadbeef); addr2 = VirtualAlloc(NULL, 0x1000, MEM_RESERVE, 0); @@ -363,7 +329,7 @@ static void test_MapViewOfFile(void) static const char testfile[] = "testfile.xxx"; const char *name; HANDLE file, mapping, map2; - void *ptr, *ptr2, *addr; + void *ptr, *ptr2; MEMORY_BASIC_INFORMATION info; BOOL ret; @@ -734,10 +700,6 @@ static void test_MapViewOfFile(void) ok(info.Type == MEM_MAPPED, "Type should have been MEM_MAPPED instead of 0x%x\n", info.Type); } - addr = VirtualAlloc( ptr, MAPPING_SIZE, MEM_RESET, PAGE_READONLY ); - ok( addr == ptr || broken(!addr && GetLastError() == ERROR_INVALID_PARAMETER), /* win9x */ - "VirtualAlloc failed with error %u\n", GetLastError() ); - ret = VirtualFree( ptr, 0x10000, MEM_DECOMMIT ); ok( !ret || broken(ret) /* win9x */, "VirtualFree succeeded\n" ); if (!ret) diff --git a/dlls/kernel32/tests/volume.c b/dlls/kernel32/tests/volume.c index 4f8c1c0e0c0..2c25465175f 100644 --- a/dlls/kernel32/tests/volume.c +++ b/dlls/kernel32/tests/volume.c @@ -160,7 +160,7 @@ static void test_GetVolumeNameForVolumeMountPointA(void) "GetVolumeNameForVolumeMountPointA failed on %s, last=%d\n", temp_path, GetLastError()); - /* Try on a nonexistent dos drive */ + /* Try on a non-existent dos drive */ path[2] = 0; for (;path[0] <= 'z'; path[0]++) { ret = QueryDosDeviceA( path, volume, len); @@ -174,7 +174,7 @@ static void test_GetVolumeNameForVolumeMountPointA(void) "GetVolumeNameForVolumeMountPointA failed on %s, last=%d\n", path, GetLastError()); - /* Try without trailing \ and on a nonexistent dos drive */ + /* Try without trailing \ and on a non-existent dos drive */ path[2] = 0; ret = pGetVolumeNameForVolumeMountPointA(path, volume, len); ok(ret == FALSE && GetLastError() == ERROR_INVALID_NAME, diff --git a/dlls/kernel32/volume.c b/dlls/kernel32/volume.c index 9fcd0616708..0f4161c6ec3 100644 --- a/dlls/kernel32/volume.c +++ b/dlls/kernel32/volume.c @@ -1018,10 +1018,11 @@ DWORD WINAPI QueryDosDeviceW( LPCWSTR devname, LPWSTR target, DWORD bufsize ) static const WCHAR prnW[] = {'P','R','N',0}; static const WCHAR comW[] = {'C','O','M',0}; static const WCHAR lptW[] = {'L','P','T',0}; + static const WCHAR rootW[] = {'A',':','\\',0}; static const WCHAR com0W[] = {'\\','?','?','\\','C','O','M','0',0}; static const WCHAR com1W[] = {'\\','D','o','s','D','e','v','i','c','e','s','\\','C','O','M','1',0,0}; static const WCHAR lpt1W[] = {'\\','D','o','s','D','e','v','i','c','e','s','\\','L','P','T','1',0,0}; - static const WCHAR dosdevW[] = {'\\','D','o','s','D','e','v','i','c','e','s','\\',0}; + static const WCHAR driveW[] = {'\\','D','o','s','D','e','v','i','c','e','s','\\','A',':',0}; UNICODE_STRING nt_name; ANSI_STRING unix_name; @@ -1045,21 +1046,15 @@ DWORD WINAPI QueryDosDeviceW( LPCWSTR devname, LPWSTR target, DWORD bufsize ) memcpy( name, devname + HIWORD(dosdev)/sizeof(WCHAR), LOWORD(dosdev) ); name[LOWORD(dosdev)/sizeof(WCHAR)] = 0; } - else + else if (devname[0] && devname[1] == ':' && !devname[2]) { + /* FIXME: should do this for all devices, not just drives */ NTSTATUS status; - WCHAR *buffer; + WCHAR buffer[sizeof(driveW)/sizeof(WCHAR)]; - if (!(buffer = HeapAlloc( GetProcessHeap(), 0, sizeof(dosdevW) + strlenW(devname)*sizeof(WCHAR) ))) - { - SetLastError( ERROR_OUTOFMEMORY ); - return 0; - } - memcpy( buffer, dosdevW, sizeof(dosdevW) ); - strcatW( buffer, devname ); - status = read_nt_symlink( buffer, target, bufsize ); - HeapFree( GetProcessHeap(), 0, buffer ); - if (status) + memcpy( buffer, driveW, sizeof(driveW) ); + buffer[12] = devname[0]; + if ((status = read_nt_symlink( buffer, target, bufsize ))) { SetLastError( RtlNtStatusToDosError(status) ); return 0; @@ -1067,8 +1062,11 @@ DWORD WINAPI QueryDosDeviceW( LPCWSTR devname, LPWSTR target, DWORD bufsize ) ret = strlenW( target ) + 1; goto done; } - - /* FIXME: should read NT symlink for all devices */ + else + { + SetLastError( ERROR_BAD_PATHNAME ); + return 0; + } if (!(path = get_dos_device_path( name ))) return 0; link = read_symlink( path ); @@ -1127,8 +1125,6 @@ DWORD WINAPI QueryDosDeviceW( LPCWSTR devname, LPWSTR target, DWORD bufsize ) } else /* return a list of all devices */ { - OBJECT_ATTRIBUTES attr; - HANDLE handle; WCHAR *p = target; int i; @@ -1138,8 +1134,6 @@ DWORD WINAPI QueryDosDeviceW( LPCWSTR devname, LPWSTR target, DWORD bufsize ) return 0; } - /* FIXME: these should be NT symlinks too */ - memcpy( p, auxW, sizeof(auxW) ); p += sizeof(auxW) / sizeof(WCHAR); memcpy( p, nulW, sizeof(nulW) ); @@ -1186,36 +1180,30 @@ DWORD WINAPI QueryDosDeviceW( LPCWSTR devname, LPWSTR target, DWORD bufsize ) } } - RtlInitUnicodeString( &nt_name, dosdevW ); - nt_name.Length -= sizeof(WCHAR); /* without trailing slash */ - attr.Length = sizeof(attr); - attr.RootDirectory = 0; - attr.ObjectName = &nt_name; - attr.Attributes = OBJ_CASE_INSENSITIVE; - attr.SecurityDescriptor = NULL; - attr.SecurityQualityOfService = NULL; - status = NtOpenDirectoryObject( &handle, FILE_LIST_DIRECTORY, &attr ); - if (!status) + strcpyW( nt_buffer + 4, rootW ); + RtlInitUnicodeString( &nt_name, nt_buffer ); + + /* FIXME: should simply enumerate the DosDevices directory instead */ + for (i = 0; i < 26; i++) { - char data[1024]; - DIRECTORY_BASIC_INFORMATION *info = (DIRECTORY_BASIC_INFORMATION *)data; - ULONG ctx = 0, len; + WCHAR buffer[sizeof(driveW)/sizeof(WCHAR)], dummy[8]; + NTSTATUS status; - while (!NtQueryDirectoryObject( handle, info, sizeof(data), 1, 0, &ctx, &len )) + memcpy( buffer, driveW, sizeof(driveW) ); + buffer[12] = 'A' + i; + status = read_nt_symlink( buffer, dummy, sizeof(dummy)/sizeof(WCHAR) ); + if (status == STATUS_SUCCESS || status == STATUS_BUFFER_TOO_SMALL) { - if (p + info->ObjectName.Length/sizeof(WCHAR) + 1 >= target + bufsize) + if (p + 3 >= target + bufsize) { SetLastError( ERROR_INSUFFICIENT_BUFFER ); - NtClose( handle ); return 0; } - memcpy( p, info->ObjectName.Buffer, info->ObjectName.Length ); - p += info->ObjectName.Length/sizeof(WCHAR); + *p++ = 'A' + i; + *p++ = ':'; *p++ = 0; } - NtClose( handle ); } - *p++ = 0; /* terminating null */ return p - target; } diff --git a/dlls/keyboard.drv16/Makefile.in b/dlls/keyboard.drv16/Makefile.in index 85a20ea8f18..ef8c36c4ecd 100644 --- a/dlls/keyboard.drv16/Makefile.in +++ b/dlls/keyboard.drv16/Makefile.in @@ -6,6 +6,8 @@ MODULE = keyboard.drv16 IMPORTS = user32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16 +SPEC_SRCS = keyboard.drv16.spec + C_SRCS = keyboard.c @MAKE_DLL_RULES@ diff --git a/dlls/loadperf/Makefile.in b/dlls/loadperf/Makefile.in index c092f3fb3bb..1a5715911e5 100644 --- a/dlls/loadperf/Makefile.in +++ b/dlls/loadperf/Makefile.in @@ -7,7 +7,7 @@ IMPORTLIB = loadperf IMPORTS = kernel32 C_SRCS = \ - loadperf_main.c + loadperf_main.c @MAKE_DLL_RULES@ diff --git a/dlls/localspl/Makefile.in b/dlls/localspl/Makefile.in index 9fa087db740..48503630f58 100644 --- a/dlls/localspl/Makefile.in +++ b/dlls/localspl/Makefile.in @@ -10,23 +10,7 @@ C_SRCS = \ localspl_main.c \ provider.c -RC_SRCS = \ - localspl.rc \ - spl_Da.rc \ - spl_De.rc \ - spl_En.rc \ - spl_Fr.rc \ - spl_Ko.rc \ - spl_Lt.rc \ - spl_Nl.rc \ - spl_No.rc \ - spl_Pl.rc \ - spl_Pt.rc \ - spl_Ro.rc \ - spl_Ru.rc \ - spl_Si.rc \ - spl_Sv.rc \ - spl_Zh.rc +RC_SRCS = localspl.rc @MAKE_DLL_RULES@ diff --git a/dlls/localspl/localspl.rc b/dlls/localspl/localspl.rc index 9757afdf504..71c1e4604b9 100644 --- a/dlls/localspl/localspl.rc +++ b/dlls/localspl/localspl.rc @@ -19,6 +19,9 @@ * */ +#include "windef.h" +#include "winbase.h" +#include "winver.h" #include "localspl_private.h" #define WINE_FILENAME_STR "localspl.dll" @@ -32,3 +35,18 @@ #define WINE_PRODUCTVERSION_STR "5.1.2600.2180" #include "wine/wine_common_ver.rc" + +#include "spl_En.rc" +#include "spl_Da.rc" +#include "spl_De.rc" +#include "spl_Fr.rc" +#include "spl_Ko.rc" +#include "spl_Nl.rc" +#include "spl_No.rc" +#include "spl_Pl.rc" +#include "spl_Pt.rc" +#include "spl_Ro.rc" +#include "spl_Ru.rc" +#include "spl_Si.rc" +#include "spl_Sv.rc" +#include "spl_Zh.rc" diff --git a/dlls/localspl/localspl_private.h b/dlls/localspl/localspl_private.h index 952c1f6652d..5174a1a847e 100644 --- a/dlls/localspl/localspl_private.h +++ b/dlls/localspl/localspl_private.h @@ -21,7 +21,6 @@ #ifndef __WINE_LOCALSPL_PRIVATE__ #define __WINE_LOCALSPL_PRIVATE__ -#include /* ## DLL-wide Globals ## */ extern HINSTANCE LOCALSPL_hInstance; diff --git a/dlls/localspl/spl_Da.rc b/dlls/localspl/spl_Da.rc index cf1f3189904..a149cabc20a 100644 --- a/dlls/localspl/spl_Da.rc +++ b/dlls/localspl/spl_Da.rc @@ -18,9 +18,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - -LANGUAGE LANG_DANISH, SUBLANG_DEFAULT + LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { diff --git a/dlls/localspl/spl_De.rc b/dlls/localspl/spl_De.rc index b30e13c903b..4c95e2bcfa5 100644 --- a/dlls/localspl/spl_De.rc +++ b/dlls/localspl/spl_De.rc @@ -19,10 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/localspl/spl_En.rc b/dlls/localspl/spl_En.rc index d189c26a132..c9d12f4f16a 100644 --- a/dlls/localspl/spl_En.rc +++ b/dlls/localspl/spl_En.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/localspl/spl_Fr.rc b/dlls/localspl/spl_Fr.rc index 0e93dc8b72b..95269727162 100644 --- a/dlls/localspl/spl_Fr.rc +++ b/dlls/localspl/spl_Fr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/localspl/spl_Ko.rc b/dlls/localspl/spl_Ko.rc index 86db86797f6..fe2d5720a56 100644 --- a/dlls/localspl/spl_Ko.rc +++ b/dlls/localspl/spl_Ko.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/localspl/spl_Lt.rc b/dlls/localspl/spl_Lt.rc deleted file mode 100644 index 4c72767105d..00000000000 --- a/dlls/localspl/spl_Lt.rc +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Lithuanian resources for localspl - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "localspl_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_LOCALPORT "Vietinis prievadas" - IDS_LOCALMONITOR "Vietinis monitorius" -} diff --git a/dlls/localspl/spl_Nl.rc b/dlls/localspl/spl_Nl.rc index bd024469e80..b9d4c5ca608 100644 --- a/dlls/localspl/spl_Nl.rc +++ b/dlls/localspl/spl_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/localspl/spl_No.rc b/dlls/localspl/spl_No.rc index b81a7b7d1ce..5efa5631e9b 100644 --- a/dlls/localspl/spl_No.rc +++ b/dlls/localspl/spl_No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE DISCARDABLE diff --git a/dlls/localspl/spl_Pl.rc b/dlls/localspl/spl_Pl.rc index cdbb4226771..a0802088666 100644 --- a/dlls/localspl/spl_Pl.rc +++ b/dlls/localspl/spl_Pl.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/localspl/spl_Pt.rc b/dlls/localspl/spl_Pt.rc index 79506c34dc2..8ec66c55f36 100644 --- a/dlls/localspl/spl_Pt.rc +++ b/dlls/localspl/spl_Pt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/localspl/spl_Ro.rc b/dlls/localspl/spl_Ro.rc index 7f988001687..44321957313 100644 --- a/dlls/localspl/spl_Ro.rc +++ b/dlls/localspl/spl_Ro.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - -#pragma code_page(65001) - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/localspl/spl_Ru.rc b/dlls/localspl/spl_Ru.rc index 085488d460d..1ee1e2f327b 100644 --- a/dlls/localspl/spl_Ru.rc +++ b/dlls/localspl/spl_Ru.rc @@ -18,15 +18,10 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { - IDS_LOCALPORT "Локальный порт" - IDS_LOCALMONITOR "Локальный монитор" + IDS_LOCALPORT "Ëîêàëüíûé ïîðò" + IDS_LOCALMONITOR "Ëîêàëüíûé ìîíèòîð" } diff --git a/dlls/localspl/spl_Si.rc b/dlls/localspl/spl_Si.rc index 11928abfa37..66ca2c4ce76 100644 --- a/dlls/localspl/spl_Si.rc +++ b/dlls/localspl/spl_Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -29,3 +27,5 @@ STRINGTABLE DISCARDABLE IDS_LOCALPORT "Lokalna vrata" IDS_LOCALMONITOR "Lokalen monitor" } + +#pragma code_page(default) diff --git a/dlls/localspl/spl_Sv.rc b/dlls/localspl/spl_Sv.rc index 2831da64e11..fca0d6b0835 100644 --- a/dlls/localspl/spl_Sv.rc +++ b/dlls/localspl/spl_Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/localspl/spl_Zh.rc b/dlls/localspl/spl_Zh.rc index 108cb50ee96..c5db382ffe3 100644 --- a/dlls/localspl/spl_Zh.rc +++ b/dlls/localspl/spl_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localspl_private.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -38,3 +36,5 @@ STRINGTABLE DISCARDABLE IDS_LOCALPORT "本地端口" IDS_LOCALMONITOR "本地監視器" } + +#pragma code_page(default) diff --git a/dlls/localui/Makefile.in b/dlls/localui/Makefile.in index 75090a18185..6a439066726 100644 --- a/dlls/localui/Makefile.in +++ b/dlls/localui/Makefile.in @@ -8,23 +8,7 @@ IMPORTS = winspool user32 kernel32 C_SRCS = \ localui.c -RC_SRCS = \ - localui.rc \ - ui_Da.rc \ - ui_De.rc \ - ui_En.rc \ - ui_Fr.rc \ - ui_Ko.rc \ - ui_Lt.rc \ - ui_Nl.rc \ - ui_No.rc \ - ui_Pl.rc \ - ui_Pt.rc \ - ui_Ro.rc \ - ui_Ru.rc \ - ui_Si.rc \ - ui_Sv.rc \ - ui_Zh.rc +RC_SRCS = localui.rc @MAKE_DLL_RULES@ diff --git a/dlls/localui/localui.h b/dlls/localui/localui.h index 25424da568c..aa244bdc824 100644 --- a/dlls/localui/localui.h +++ b/dlls/localui/localui.h @@ -21,8 +21,6 @@ #ifndef __WINE_LOCALUI__ #define __WINE_LOCALUI__ -#include -#include /* ## Resource-ID ## */ #define ADDPORT_DIALOG 100 diff --git a/dlls/localui/localui.rc b/dlls/localui/localui.rc index cdf7bb4c7e8..815cac0ed9f 100644 --- a/dlls/localui/localui.rc +++ b/dlls/localui/localui.rc @@ -19,6 +19,10 @@ * */ +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winver.h" #include "localui.h" #define WINE_FILENAME_STR "localui.dll" @@ -32,3 +36,19 @@ #define WINE_PRODUCTVERSION_STR "5.1.2600.2180" #include "wine/wine_common_ver.rc" + + +#include "ui_Da.rc" +#include "ui_De.rc" +#include "ui_En.rc" +#include "ui_Fr.rc" +#include "ui_Ko.rc" +#include "ui_Nl.rc" +#include "ui_No.rc" +#include "ui_Pl.rc" +#include "ui_Pt.rc" +#include "ui_Ro.rc" +#include "ui_Ru.rc" +#include "ui_Si.rc" +#include "ui_Sv.rc" +#include "ui_Zh.rc" diff --git a/dlls/localui/ui_Da.rc b/dlls/localui/ui_Da.rc index 861ba8f2ddf..97299266959 100644 --- a/dlls/localui/ui_Da.rc +++ b/dlls/localui/ui_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localui.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT ADDPORT_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/localui/ui_De.rc b/dlls/localui/ui_De.rc index 74148c3441b..2fe35fc4e77 100644 --- a/dlls/localui/ui_De.rc +++ b/dlls/localui/ui_De.rc @@ -18,18 +18,14 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localui.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL ADDPORT_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 STYLE DS_CONTEXTHELP | DS_MODALFRAME | DS_SETFONT | DS_SETFOREGROUND | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION -CAPTION "Lokalen Anschluss hinzufügen" +CAPTION "Lokalen Anschluss hinzufügen" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "&Lokaler Anschuss, der hinzugefügt werden soll:", -1, 7, 13, 194, 13, WS_VISIBLE + LTEXT "&Lokaler Anschuss, der hinzugefügt werden soll:", -1, 7, 13, 194, 13, WS_VISIBLE EDITTEXT ADDPORT_EDIT, 6, 28, 174, 12, WS_VISIBLE | ES_AUTOHSCROLL DEFPUSHBUTTON "OK", IDOK, 188, 10, 50, 14, WS_VISIBLE PUSHBUTTON "Abbrechen", IDCANCEL, 188, 27, 50, 14, WS_VISIBLE @@ -41,8 +37,8 @@ STYLE DS_CONTEXTHELP | DS_MODALFRAME | DS_SETFONT | DS_SETFOREGROUND | WS_POPUPW CAPTION "LPT-Anschluss konfigurieren" FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX "Zeitüberschreitung (Sekunden)", LPTCONFIG_GROUP, 6, 6, 150, 35, BS_GROUPBOX - LTEXT "Ü&bertragung wiederholen:", -1, 14, 22, 90, 13, WS_VISIBLE + GROUPBOX "Zeitüberschreitung (Sekunden)", LPTCONFIG_GROUP, 6, 6, 150, 35, BS_GROUPBOX + LTEXT "Ü&bertragung wiederholen:", -1, 14, 22, 90, 13, WS_VISIBLE EDITTEXT LPTCONFIG_EDIT, 112, 20, 32, 13, WS_VISIBLE | ES_NUMBER DEFPUSHBUTTON "OK", IDOK, 164, 10, 50, 14, WS_VISIBLE PUSHBUTTON "Abbrechen", IDCANCEL, 164, 27, 50, 14, WS_VISIBLE @@ -52,7 +48,7 @@ END STRINGTABLE DISCARDABLE { IDS_LOCALPORT "Lokaler Anschluss" - IDS_INVALIDNAME "'%s' ist kein gültiger Anschlussname" + IDS_INVALIDNAME "'%s' ist kein gültiger Anschlussname" IDS_PORTEXISTS "Der Anschluss %s existiert bereits" IDS_NOTHINGTOCONFIG "Dieser Anschluss hat keine Optionen zum Konfigurieren" } diff --git a/dlls/localui/ui_En.rc b/dlls/localui/ui_En.rc index 5a218680472..c2de6263a8a 100644 --- a/dlls/localui/ui_En.rc +++ b/dlls/localui/ui_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localui.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT ADDPORT_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/localui/ui_Fr.rc b/dlls/localui/ui_Fr.rc index 70e4baf06ee..261fa0b7dd2 100644 --- a/dlls/localui/ui_Fr.rc +++ b/dlls/localui/ui_Fr.rc @@ -17,9 +17,6 @@ * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ - -#include "localui.h" - #pragma code_page(65001) LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL @@ -56,3 +53,5 @@ STRINGTABLE DISCARDABLE IDS_PORTEXISTS "Le port %s existe déjà" IDS_NOTHINGTOCONFIG "Ce port n'a pas d'options de configuration" } + +#pragma code_page(default) diff --git a/dlls/localui/ui_Ko.rc b/dlls/localui/ui_Ko.rc index d86b7ef58a5..9a380308422 100644 --- a/dlls/localui/ui_Ko.rc +++ b/dlls/localui/ui_Ko.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localui.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT ADDPORT_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/localui/ui_Lt.rc b/dlls/localui/ui_Lt.rc deleted file mode 100644 index ff789e17fba..00000000000 --- a/dlls/localui/ui_Lt.rc +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Lithuanian resources for localui - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "localui.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -ADDPORT_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 -STYLE DS_CONTEXTHELP | DS_MODALFRAME | DS_SETFONT | DS_SETFOREGROUND | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION -CAPTION "Pridėti vietinį prievadą" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "&Įveskite pridedamo prievado vardą:", -1, 7, 13, 194, 13, WS_VISIBLE - EDITTEXT ADDPORT_EDIT, 6, 28, 174, 12, WS_VISIBLE | ES_AUTOHSCROLL - DEFPUSHBUTTON "Gerai", IDOK, 199, 10, 40, 14, WS_VISIBLE - PUSHBUTTON "Atsisakyti", IDCANCEL, 199, 27, 40, 14, WS_VISIBLE -END - - -LPTCONFIG_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 220, 47 -STYLE DS_CONTEXTHELP | DS_MODALFRAME | DS_SETFONT | DS_SETFOREGROUND | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION -CAPTION "Konfigūruoti LPT prievadą" -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "Laukimo laikas (sekundėmis)", LPTCONFIG_GROUP, 6, 6, 150, 35, BS_GROUPBOX - LTEXT "&Perdavimo pakartojimas:", -1, 14, 22, 90, 13, WS_VISIBLE - EDITTEXT LPTCONFIG_EDIT, 112, 20, 32, 13, WS_VISIBLE | ES_NUMBER - DEFPUSHBUTTON "Gerai", IDOK, 164, 10, 50, 14, WS_VISIBLE - PUSHBUTTON "Atsisakyti", IDCANCEL, 164, 27, 50, 14, WS_VISIBLE -END - - -STRINGTABLE DISCARDABLE -{ - IDS_LOCALPORT "Vietinis prievadas" - IDS_INVALIDNAME "„%s“ yra netinkamas prievado vardas" - IDS_PORTEXISTS "Prievadas %s jau egzistuoja" - IDS_NOTHINGTOCONFIG "Šis prievadas neturi parinkčių konfigūravimui" -} diff --git a/dlls/localui/ui_Nl.rc b/dlls/localui/ui_Nl.rc index 21d7cc84fae..59c58ffd3aa 100644 --- a/dlls/localui/ui_Nl.rc +++ b/dlls/localui/ui_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localui.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL ADDPORT_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/localui/ui_No.rc b/dlls/localui/ui_No.rc index 8ed9e00c8aa..3a46bc8ee88 100644 --- a/dlls/localui/ui_No.rc +++ b/dlls/localui/ui_No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localui.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL ADDPORT_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/localui/ui_Pl.rc b/dlls/localui/ui_Pl.rc index 822763d7dae..74a5015e00a 100644 --- a/dlls/localui/ui_Pl.rc +++ b/dlls/localui/ui_Pl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localui.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT ADDPORT_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/localui/ui_Pt.rc b/dlls/localui/ui_Pt.rc index 7f1684820f7..7bad5211ead 100644 --- a/dlls/localui/ui_Pt.rc +++ b/dlls/localui/ui_Pt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localui.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL ADDPORT_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/localui/ui_Ro.rc b/dlls/localui/ui_Ro.rc index a1b1c771fa1..43edfe6a4b1 100644 --- a/dlls/localui/ui_Ro.rc +++ b/dlls/localui/ui_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localui.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -55,3 +53,5 @@ STRINGTABLE DISCARDABLE IDS_PORTEXISTS "Portul %s existsă deja" IDS_NOTHINGTOCONFIG "Acest port nu are opțiuni de configurat" } + +#pragma code_page(default) diff --git a/dlls/localui/ui_Ru.rc b/dlls/localui/ui_Ru.rc index 04f87b68e70..96e78f1971b 100644 --- a/dlls/localui/ui_Ru.rc +++ b/dlls/localui/ui_Ru.rc @@ -18,42 +18,37 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localui.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT ADDPORT_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 STYLE DS_CONTEXTHELP | DS_MODALFRAME | DS_SETFONT | DS_SETFOREGROUND | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION -CAPTION "Добавить локальный порт" +CAPTION "Äîáàâèòü ëîêàëüíûé ïîðò" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "Введите &название локального порта:", -1, 7, 13, 194, 13, WS_VISIBLE + LTEXT "Ââåäèòå &íàçâàíèå ëîêàëüíîãî ïîðòà:", -1, 7, 13, 194, 13, WS_VISIBLE EDITTEXT ADDPORT_EDIT, 6, 28, 174, 12, WS_VISIBLE | ES_AUTOHSCROLL DEFPUSHBUTTON "OK", IDOK, 199, 10, 40, 14, WS_VISIBLE - PUSHBUTTON "Отменить", IDCANCEL, 199, 27, 40, 14, WS_VISIBLE + PUSHBUTTON "Îòìåíèòü", IDCANCEL, 199, 27, 40, 14, WS_VISIBLE END LPTCONFIG_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 220, 47 STYLE DS_CONTEXTHELP | DS_MODALFRAME | DS_SETFONT | DS_SETFOREGROUND | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION -CAPTION "Установки параллельного порта" +CAPTION "Óñòàíîâêè ïàðàëëåëüíîãî ïîðòà" FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX "Тайм-аут (секунд)", LPTCONFIG_GROUP, 6, 6, 150, 35, BS_GROUPBOX - LTEXT "&Попыток пересылки:", -1, 14, 22, 90, 13, WS_VISIBLE + GROUPBOX "Òàéì-àóò (ñåêóíä)", LPTCONFIG_GROUP, 6, 6, 150, 35, BS_GROUPBOX + LTEXT "&Ïîïûòîê ïåðåñûëêè:", -1, 14, 22, 90, 13, WS_VISIBLE EDITTEXT LPTCONFIG_EDIT, 112, 20, 32, 13, WS_VISIBLE | ES_NUMBER DEFPUSHBUTTON "OK", IDOK, 164, 10, 50, 14, WS_VISIBLE - PUSHBUTTON "Отмена", IDCANCEL, 164, 27, 50, 14, WS_VISIBLE + PUSHBUTTON "Îòìåíà", IDCANCEL, 164, 27, 50, 14, WS_VISIBLE END STRINGTABLE DISCARDABLE { - IDS_LOCALPORT "Локальный порт" - IDS_INVALIDNAME "Не правильное название порта '%s'" - IDS_PORTEXISTS "Порт '%s' уже существует" - IDS_NOTHINGTOCONFIG "Этот порт не имеет настроек" + IDS_LOCALPORT "Ëîêàëüíûé ïîðò" + IDS_INVALIDNAME "Íå ïðàâèëüíîå íàçâàíèå ïîðòà '%s'" + IDS_PORTEXISTS "Ïîðò '%s' óæå ñóùåñòâóåò" + IDS_NOTHINGTOCONFIG "Ýòîò ïîðò íå èìååò íàñòðîåê" } diff --git a/dlls/localui/ui_Si.rc b/dlls/localui/ui_Si.rc index 6810c7ce733..961a2e046d4 100644 --- a/dlls/localui/ui_Si.rc +++ b/dlls/localui/ui_Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localui.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -56,3 +54,5 @@ STRINGTABLE DISCARDABLE IDS_PORTEXISTS "Vrata z imenom %s že obstajajo" IDS_NOTHINGTOCONFIG "Ta vrata nimajo možnosti nastavitve" } + +#pragma code_page(default) diff --git a/dlls/localui/ui_Sv.rc b/dlls/localui/ui_Sv.rc index e137079ffe4..3cd22fd8c70 100644 --- a/dlls/localui/ui_Sv.rc +++ b/dlls/localui/ui_Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localui.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL ADDPORT_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/localui/ui_Zh.rc b/dlls/localui/ui_Zh.rc index f43dde9afbd..197ac1dd38d 100644 --- a/dlls/localui/ui_Zh.rc +++ b/dlls/localui/ui_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "localui.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -92,3 +90,5 @@ STRINGTABLE DISCARDABLE IDS_PORTEXISTS "端口 %s 已經存在" IDS_NOTHINGTOCONFIG "這個端口沒有可設定選項" } + +#pragma code_page(default) diff --git a/dlls/lzexpand.dll16/Makefile.in b/dlls/lzexpand.dll16/Makefile.in index 367a3e58449..aac9c074e35 100644 --- a/dlls/lzexpand.dll16/Makefile.in +++ b/dlls/lzexpand.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = lzexpand.dll16 IMPORTS = lz32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,lz32.dll +SPEC_SRCS = lzexpand.dll16.spec + C_SRCS = lzexpand.c @MAKE_DLL_RULES@ diff --git a/dlls/mapi32/version.rc b/dlls/mapi32/version.rc index d3a620bd8fb..0f955162b37 100644 --- a/dlls/mapi32/version.rc +++ b/dlls/mapi32/version.rc @@ -18,9 +18,5 @@ #define WINE_FILEDESCRIPTION_STR "Wine Messaging API" #define WINE_FILENAME_STR "mapi32.dll" -#define WINE_FILEVERSION 1,0,0,0 -#define WINE_FILEVERSION_STR "1.0.0.0" -#define WINE_PRODUCTVERSION 1,0,0,0 -#define WINE_PRODUCTVERSION_STR "1.0.0.0" #include "wine/wine_common_ver.rc" diff --git a/dlls/mlang/mlang.c b/dlls/mlang/mlang.c index c28e695962d..d762bacd5d8 100644 --- a/dlls/mlang/mlang.c +++ b/dlls/mlang/mlang.c @@ -455,13 +455,13 @@ static const struct mlang_data { "Arabic",1256,sizeof(arabic_cp)/sizeof(arabic_cp[0]),arabic_cp, "Courier","Arial", sidArabic }, /* FIXME */ { "Baltic",1257,sizeof(baltic_cp)/sizeof(baltic_cp[0]),baltic_cp, - "Courier","Arial", sidAsciiLatin }, /* FIXME */ + "Courier","Arial" }, /* FIXME */ { "Chinese Simplified",936,sizeof(chinese_simplified_cp)/sizeof(chinese_simplified_cp[0]),chinese_simplified_cp, - "Courier","Arial", sidHan }, /* FIXME */ + "Courier","Arial" }, /* FIXME */ { "Chinese Traditional",950,sizeof(chinese_traditional_cp)/sizeof(chinese_traditional_cp[0]),chinese_traditional_cp, - "Courier","Arial", sidBopomofo }, /* FIXME */ + "Courier","Arial" }, /* FIXME */ { "Central European",1250,sizeof(central_european_cp)/sizeof(central_european_cp[0]),central_european_cp, - "Courier","Arial", sidAsciiLatin }, /* FIXME */ + "Courier","Arial" }, /* FIXME */ { "Cyrillic",1251,sizeof(cyrillic_cp)/sizeof(cyrillic_cp[0]),cyrillic_cp, "Courier","Arial", sidCyrillic }, /* FIXME */ { "Greek",1253,sizeof(greek_cp)/sizeof(greek_cp[0]),greek_cp, @@ -469,17 +469,17 @@ static const struct mlang_data { "Hebrew",1255,sizeof(hebrew_cp)/sizeof(hebrew_cp[0]),hebrew_cp, "Courier","Arial", sidHebrew }, /* FIXME */ { "Japanese",932,sizeof(japanese_cp)/sizeof(japanese_cp[0]),japanese_cp, - "MS Gothic","MS PGothic", sidKana }, + "MS Gothic","MS PGothic" }, { "Korean",949,sizeof(korean_cp)/sizeof(korean_cp[0]),korean_cp, - "Courier","Arial", sidHangul }, /* FIXME */ + "Courier","Arial" }, /* FIXME */ { "Thai",874,sizeof(thai_cp)/sizeof(thai_cp[0]),thai_cp, "Courier","Arial", sidThai }, /* FIXME */ { "Turkish",1254,sizeof(turkish_cp)/sizeof(turkish_cp[0]),turkish_cp, - "Courier","Arial", sidAsciiLatin }, /* FIXME */ + "Courier","Arial" }, /* FIXME */ { "Vietnamese",1258,sizeof(vietnamese_cp)/sizeof(vietnamese_cp[0]),vietnamese_cp, - "Courier","Arial", sidAsciiLatin }, /* FIXME */ + "Courier","Arial" }, /* FIXME */ { "Western European",1252,sizeof(western_cp)/sizeof(western_cp[0]),western_cp, - "Courier","Arial", sidAsciiLatin }, /* FIXME */ + "Courier","Arial", sidLatin }, /* FIXME */ { "Unicode",CP_UNICODE,sizeof(unicode_cp)/sizeof(unicode_cp[0]),unicode_cp, "Courier","Arial" } /* FIXME */ }; @@ -3125,10 +3125,8 @@ static HRESULT WINAPI fnIMultiLanguage2_IsCodePageInstallable( IMultiLanguage3* iface, UINT uiCodePage) { - TRACE("%u\n", uiCodePage); - - /* FIXME: the installable set is usually larger than the set of valid codepages */ - return IMultiLanguage2_ValidateCodePageEx(iface, uiCodePage, NULL, CPIOD_PEEK); + FIXME("%u\n", uiCodePage); + return E_NOTIMPL; } static HRESULT WINAPI fnIMultiLanguage2_SetMimeDBSource( @@ -3359,30 +3357,8 @@ static HRESULT WINAPI fnIMLangFontLink2_MapFont(IMLangFontLink2* This, static HRESULT WINAPI fnIMLangFontLink2_GetFontUnicodeRanges(IMLangFontLink2* This, HDC hDC, UINT *puiRanges, UNICODERANGE *pUranges) { - DWORD size; - GLYPHSET *gs; - - TRACE("(%p)->%p %p %p\n", This, hDC, puiRanges, pUranges); - - if (!puiRanges) return E_INVALIDARG; - if (!(size = GetFontUnicodeRanges(hDC, NULL))) return E_FAIL; - if (!(gs = HeapAlloc(GetProcessHeap(), 0, size))) return E_OUTOFMEMORY; - - GetFontUnicodeRanges(hDC, gs); - *puiRanges = gs->cRanges; - if (pUranges) - { - UINT i; - for (i = 0; i < gs->cRanges; i++) - { - if (i >= *puiRanges) break; - pUranges[i].wcFrom = gs->ranges[i].wcLow; - pUranges[i].wcTo = gs->ranges[i].wcLow + gs->ranges[i].cGlyphs; - } - *puiRanges = i; - } - HeapFree(GetProcessHeap(), 0, gs); - return S_OK; + FIXME("(%p)->%p %p %p\n",This, hDC, puiRanges, pUranges); + return E_NOTIMPL; } static HRESULT WINAPI fnIMLangFontLink2_GetScriptFontInfo(IMLangFontLink2* This, @@ -3425,21 +3401,8 @@ static HRESULT WINAPI fnIMLangFontLink2_GetScriptFontInfo(IMLangFontLink2* This, static HRESULT WINAPI fnIMLangFontLink2_CodePageToScriptID(IMLangFontLink2* This, UINT uiCodePage, SCRIPT_ID *pSid) { - UINT i; - - TRACE("(%p)->%i %p\n", This, uiCodePage, pSid); - - if (uiCodePage == CP_UNICODE) return E_FAIL; - - for (i = 0; i < sizeof(mlang_data)/sizeof(mlang_data[0]); i++) - { - if (uiCodePage == mlang_data[i].family_codepage) - { - if (pSid) *pSid = mlang_data[i].sid; - return S_OK; - } - } - return E_FAIL; + FIXME("(%p)->%i %p\n",This, uiCodePage, pSid); + return E_NOTIMPL; } static const IMLangFontLink2Vtbl IMLangFontLink2_vtbl = diff --git a/dlls/mlang/tests/mlang.c b/dlls/mlang/tests/mlang.c index 26e89a0bdcf..d4e39412a21 100644 --- a/dlls/mlang/tests/mlang.c +++ b/dlls/mlang/tests/mlang.c @@ -50,9 +50,6 @@ static HRESULT (WINAPI *pConvertINetMultiByteToUnicode)(LPDWORD, DWORD, LPCSTR, LPINT, LPWSTR, LPINT); static HRESULT (WINAPI *pConvertINetUnicodeToMultiByte)(LPDWORD, DWORD, LPCWSTR, LPINT, LPSTR, LPINT); -static HRESULT (WINAPI *pRfc1766ToLcidA)(LCID *, LPCSTR); -static HRESULT (WINAPI *pLcidToRfc1766A)(LCID, LPSTR, INT); - typedef struct lcid_tag_table { LPCSTR rfc1766; LCID lcid; @@ -63,7 +60,7 @@ typedef struct lcid_tag_table { /* en, ar and zh use SUBLANG_NEUTRAL for the rfc1766 name without the country all others suppress the country with SUBLANG_DEFAULT. - For 3 letter language codes, the rfc1766 is too small for the country */ + For 3 letter language codes, the rfc1766 is to small for the country */ static const lcid_table_entry lcid_table[] = { {"e", -1, E_FAIL}, @@ -242,8 +239,6 @@ static BOOL init_function_ptrs(void) pConvertINetMultiByteToUnicode = (void *)GetProcAddress(hMlang, "ConvertINetMultiByteToUnicode"); pConvertINetUnicodeToMultiByte = (void *)GetProcAddress(hMlang, "ConvertINetUnicodeToMultiByte"); - pRfc1766ToLcidA = (void *)GetProcAddress(hMlang, "Rfc1766ToLcidA"); - pLcidToRfc1766A = (void *)GetProcAddress(hMlang, "LcidToRfc1766A"); pGetCPInfoExA = (void *)GetProcAddress(GetModuleHandleA("kernel32.dll"), "GetCPInfoExA"); @@ -1142,7 +1137,7 @@ static void test_Rfc1766ToLcid(void) for(i = 0; i < sizeof(lcid_table) / sizeof(lcid_table[0]); i++) { lcid = -1; - ret = pRfc1766ToLcidA(&lcid, lcid_table[i].rfc1766); + ret = Rfc1766ToLcidA(&lcid, lcid_table[i].rfc1766); /* IE <6.0 guess 0x412 (ko) from "kok" */ ok( (ret == lcid_table[i].hr) || @@ -1152,13 +1147,15 @@ static void test_Rfc1766ToLcid(void) ok( (lcid == lcid_table[i].lcid) || broken(lcid == lcid_table[i].broken_lcid), /* IE <6.0 */ "#%02d: got LCID 0x%x (expected 0x%x)\n", i, lcid, lcid_table[i].lcid); + } - ret = pRfc1766ToLcidA(&lcid, NULL); + ret = Rfc1766ToLcidA(&lcid, NULL); ok(ret == E_INVALIDARG, "got 0x%08x (expected E_INVALIDARG)\n", ret); - ret = pRfc1766ToLcidA(NULL, "en"); + ret = Rfc1766ToLcidA(NULL, "en"); ok(ret == E_INVALIDARG, "got 0x%08x (expected E_INVALIDARG)\n", ret); + } static void test_GetNumberOfCodePageInfo(IMultiLanguage2 *iML2) @@ -1223,7 +1220,7 @@ static void test_LcidToRfc1766(void) memset(buffer, '#', sizeof(buffer)-1); buffer[sizeof(buffer)-1] = '\0'; - hr = pLcidToRfc1766A(lcid_table[i].lcid, buffer, MAX_RFC1766_NAME); + hr = LcidToRfc1766A(lcid_table[i].lcid, buffer, MAX_RFC1766_NAME); /* IE <5.0 does not recognize 0x180c (fr-mc) and 0x457 (kok) */ ok( (hr == lcid_table[i].hr) || @@ -1246,21 +1243,22 @@ static void test_LcidToRfc1766(void) memset(buffer, '#', sizeof(buffer)-1); buffer[sizeof(buffer)-1] = '\0'; - hr = pLcidToRfc1766A(-1, buffer, MAX_RFC1766_NAME); + hr = LcidToRfc1766A(-1, buffer, MAX_RFC1766_NAME); ok(hr == E_FAIL, "got 0x%08x and '%s' (expected E_FAIL)\n", hr, buffer); - hr = pLcidToRfc1766A(LANG_ENGLISH, NULL, MAX_RFC1766_NAME); + hr = LcidToRfc1766A(LANG_ENGLISH, NULL, MAX_RFC1766_NAME); ok(hr == E_INVALIDARG, "got 0x%08x (expected E_INVALIDARG)\n", hr); memset(buffer, '#', sizeof(buffer)-1); buffer[sizeof(buffer)-1] = '\0'; - hr = pLcidToRfc1766A(LANG_ENGLISH, buffer, -1); + hr = LcidToRfc1766A(LANG_ENGLISH, buffer, -1); ok(hr == E_INVALIDARG, "got 0x%08x and '%s' (expected E_INVALIDARG)\n", hr, buffer); memset(buffer, '#', sizeof(buffer)-1); buffer[sizeof(buffer)-1] = '\0'; - hr = pLcidToRfc1766A(LANG_ENGLISH, buffer, 0); + hr = LcidToRfc1766A(LANG_ENGLISH, buffer, 0); ok(hr == E_INVALIDARG, "got 0x%08x and '%s' (expected E_INVALIDARG)\n", hr, buffer); + } static void test_GetRfc1766Info(IMultiLanguage2 *iML2) @@ -1841,23 +1839,23 @@ static void test_GetScriptFontInfo(IMLangFontLink2 *font_link) SCRIPTFONTINFO sfi[1]; nfonts = 0; - hr = IMLangFontLink2_GetScriptFontInfo(font_link, sidAsciiLatin, 0, &nfonts, NULL); + hr = IMLangFontLink2_GetScriptFontInfo(font_link, sidLatin, 0, &nfonts, NULL); ok(hr == S_OK, "GetScriptFontInfo failed %u\n", GetLastError()); ok(nfonts, "unexpected result\n"); nfonts = 0; - hr = IMLangFontLink2_GetScriptFontInfo(font_link, sidAsciiLatin, SCRIPTCONTF_FIXED_FONT, &nfonts, NULL); + hr = IMLangFontLink2_GetScriptFontInfo(font_link, sidLatin, SCRIPTCONTF_FIXED_FONT, &nfonts, NULL); ok(hr == S_OK, "GetScriptFontInfo failed %u\n", GetLastError()); ok(nfonts, "unexpected result\n"); nfonts = 0; - hr = IMLangFontLink2_GetScriptFontInfo(font_link, sidAsciiLatin, SCRIPTCONTF_PROPORTIONAL_FONT, &nfonts, NULL); + hr = IMLangFontLink2_GetScriptFontInfo(font_link, sidLatin, SCRIPTCONTF_PROPORTIONAL_FONT, &nfonts, NULL); ok(hr == S_OK, "GetScriptFontInfo failed %u\n", GetLastError()); ok(nfonts, "unexpected result\n"); nfonts = 1; memset(sfi, 0, sizeof(sfi)); - hr = IMLangFontLink2_GetScriptFontInfo(font_link, sidAsciiLatin, SCRIPTCONTF_FIXED_FONT, &nfonts, sfi); + hr = IMLangFontLink2_GetScriptFontInfo(font_link, sidLatin, SCRIPTCONTF_FIXED_FONT, &nfonts, sfi); ok(hr == S_OK, "GetScriptFontInfo failed %u\n", GetLastError()); ok(nfonts == 1, "got %u, expected 1\n", nfonts); ok(sfi[0].scripts != 0, "unexpected result\n"); @@ -1865,129 +1863,13 @@ static void test_GetScriptFontInfo(IMLangFontLink2 *font_link) nfonts = 1; memset(sfi, 0, sizeof(sfi)); - hr = IMLangFontLink2_GetScriptFontInfo(font_link, sidAsciiLatin, SCRIPTCONTF_PROPORTIONAL_FONT, &nfonts, sfi); + hr = IMLangFontLink2_GetScriptFontInfo(font_link, sidLatin, SCRIPTCONTF_PROPORTIONAL_FONT, &nfonts, sfi); ok(hr == S_OK, "GetScriptFontInfo failed %u\n", GetLastError()); ok(nfonts == 1, "got %u, expected 1\n", nfonts); ok(sfi[0].scripts != 0, "unexpected result\n"); ok(sfi[0].wszFont[0], "unexpected result\n"); } -static void test_CodePageToScriptID(IMLangFontLink2 *font_link) -{ - HRESULT hr; - UINT i; - SCRIPT_ID sid; - static const struct - { - UINT cp; - SCRIPT_ID sid; - HRESULT hr; - } - cp_sid[] = - { - {874, sidThai}, - {932, sidKana}, - {936, sidHan}, - {949, sidHangul}, - {950, sidBopomofo}, - {1250, sidAsciiLatin}, - {1251, sidCyrillic}, - {1252, sidAsciiLatin}, - {1253, sidGreek}, - {1254, sidAsciiLatin}, - {1255, sidHebrew}, - {1256, sidArabic}, - {1257, sidAsciiLatin}, - {1258, sidAsciiLatin}, - {CP_UNICODE, 0, E_FAIL} - }; - - for (i = 0; i < sizeof(cp_sid)/sizeof(cp_sid[0]); i++) - { - hr = IMLangFontLink2_CodePageToScriptID(font_link, cp_sid[i].cp, &sid); - ok(hr == cp_sid[i].hr, "%u CodePageToScriptID failed 0x%08x %u\n", i, hr, GetLastError()); - if (SUCCEEDED(hr)) - { - ok(sid == cp_sid[i].sid, - "%u got sid %u for codepage %u, expected %u\n", i, sid, cp_sid[i].cp, cp_sid[i].sid); - } - } -} - -static void test_GetFontUnicodeRanges(IMLangFontLink2 *font_link) -{ - HRESULT hr; - UINT count; - HFONT hfont, old_hfont; - LOGFONTA lf; - HDC hdc; - UNICODERANGE *ur; - - hdc = CreateCompatibleDC(0); - memset(&lf, 0, sizeof(lf)); - lstrcpyA(lf.lfFaceName, "Arial"); - hfont = CreateFontIndirectA(&lf); - old_hfont = SelectObject(hdc, hfont); - - count = 0; - hr = IMLangFontLink2_GetFontUnicodeRanges(font_link, NULL, &count, NULL); - ok(hr == E_FAIL, "expected E_FAIL, got 0x%08x\n", hr); - - hr = IMLangFontLink2_GetFontUnicodeRanges(font_link, hdc, NULL, NULL); - ok(hr == E_INVALIDARG, "expected E_FAIL, got 0x%08x\n", hr); - - count = 0; - hr = IMLangFontLink2_GetFontUnicodeRanges(font_link, hdc, &count, NULL); - ok(hr == S_OK, "expected S_OK, got 0x%08x\n", hr); - ok(count, "expected count > 0\n"); - - ur = HeapAlloc(GetProcessHeap(), 0, sizeof(*ur) * count); - - hr = IMLangFontLink2_GetFontUnicodeRanges(font_link, hdc, &count, ur); - ok(hr == S_OK, "expected S_OK, got 0x%08x\n", hr); - - count--; - hr = IMLangFontLink2_GetFontUnicodeRanges(font_link, hdc, &count, ur); - ok(hr == S_OK, "expected S_OK, got 0x%08x\n", hr); - - HeapFree(GetProcessHeap(), 0, ur); - - SelectObject(hdc, old_hfont); - DeleteObject(hfont); - DeleteDC(hdc); -} - -static void test_IsCodePageInstallable(IMultiLanguage2 *ml2) -{ - UINT i; - HRESULT hr; - - SetLastError(0xdeadbeef); - lstrcmpW(NULL, NULL); - if (GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) - { - /* This corruption leads (sometimes) to test failures in oleaut32 but also - * to the inability to use the Regional Settings. - * This only seems to be an issue with Win98 and IE6 (mlang version 6.0.2800.1106). - * - * A reboot restores the codepages again. - */ - win_skip("IsCodePageInstallable could mess up the codepages on Win98\n"); - return; - } - - for (i = 0; i < 0xffff; i++) - { - hr = IMultiLanguage2_IsCodePageInstallable(ml2, i); - - /* it would be better to use IMultiLanguage2_ValidateCodePageEx here but that brings - * up an installation dialog on some platforms, even when specifying CPIOD_PEEK. - */ - if (IsValidCodePage(i)) - ok(hr == S_OK, "code page %u is valid but not installable 0x%08x\n", i, hr); - } -} - START_TEST(mlang) { IMultiLanguage *iML = NULL; @@ -2048,8 +1930,6 @@ START_TEST(mlang) test_multibyte_to_unicode_translations(iML2); test_IMultiLanguage2_ConvertStringFromUnicode(iML2); - test_IsCodePageInstallable(iML2); - IMultiLanguage2_Release(iML2); @@ -2067,8 +1947,6 @@ START_TEST(mlang) if (ret != S_OK || !iMLFL2) return; test_GetScriptFontInfo(iMLFL2); - test_GetFontUnicodeRanges(iMLFL2); - test_CodePageToScriptID(iMLFL2); IMLangFontLink2_Release(iMLFL2); CoUninitialize(); diff --git a/dlls/mountmgr.sys/device.c b/dlls/mountmgr.sys/device.c index 03b1f893662..0467079e86b 100644 --- a/dlls/mountmgr.sys/device.c +++ b/dlls/mountmgr.sys/device.c @@ -55,49 +55,26 @@ static const WCHAR drive_types[][8] = static const WCHAR drives_keyW[] = {'S','o','f','t','w','a','r','e','\\', 'W','i','n','e','\\','D','r','i','v','e','s',0}; -struct disk_device +struct dos_drive { + struct list entry; /* entry in drives list */ + char *udi; /* unique identifier for dynamic drives */ + int drive; /* drive letter (0 = A: etc.) */ enum device_type type; /* drive type */ - DEVICE_OBJECT *dev_obj; /* disk device allocated for this volume */ + DEVICE_OBJECT *device; /* disk device allocated for this drive */ UNICODE_STRING name; /* device name */ UNICODE_STRING symlink; /* device symlink if any */ STORAGE_DEVICE_NUMBER devnum; /* device number info */ + struct mount_point *dosdev; /* DosDevices mount point */ + struct mount_point *volume; /* Volume{xxx} mount point */ char *unix_device; /* unix device path */ char *unix_mount; /* unix mount point path */ }; -struct volume -{ - struct list entry; /* entry in volumes list */ - struct disk_device *device; /* disk device */ - char *udi; /* unique identifier for dynamic volumes */ - unsigned int ref; /* ref count */ - GUID guid; /* volume uuid */ - struct mount_point *mount; /* Volume{xxx} mount point */ -}; - -struct dos_drive -{ - struct list entry; /* entry in drives list */ - struct volume *volume; /* volume for this drive */ - int drive; /* drive letter (0 = A: etc.) */ - struct mount_point *mount; /* DosDevices mount point */ -}; - static struct list drives_list = LIST_INIT(drives_list); -static struct list volumes_list = LIST_INIT(volumes_list); static DRIVER_OBJECT *harddisk_driver; -static CRITICAL_SECTION device_section; -static CRITICAL_SECTION_DEBUG critsect_debug = -{ - 0, 0, &device_section, - { &critsect_debug.ProcessLocksList, &critsect_debug.ProcessLocksList }, - 0, 0, { (DWORD_PTR)(__FILE__ ": device_section") } -}; -static CRITICAL_SECTION device_section = { &critsect_debug, -1, 0, 0, 0, 0 }; - static char *get_dosdevices_path( char **drive ) { const char *config_dir = wine_get_config_dir(); @@ -121,14 +98,6 @@ static char *strdupA( const char *str ) return ret; } -static const GUID *get_default_uuid( int letter ) -{ - static GUID guid; - - guid.Data4[7] = 'A' + letter; - return &guid; -} - /* read a Unix symlink; returned buffer must be freed by caller */ static char *read_symlink( const char *path ) { @@ -158,20 +127,6 @@ static char *read_symlink( const char *path ) } } -/* update a symlink if it changed; return TRUE if updated */ -static void update_symlink( const char *path, const char *dest, const char *orig_dest ) -{ - if (dest && dest[0]) - { - if (!orig_dest || strcmp( orig_dest, dest )) - { - unlink( path ); - symlink( dest, path ); - } - } - else unlink( path ); -} - /* send notification about a change to a given drive */ static void send_notify( int drive, int code ) { @@ -187,8 +142,8 @@ static void send_notify( int drive, int code ) WM_DEVICECHANGE, code, (LPARAM)&info ); } -/* create the disk device for a given volume */ -static NTSTATUS create_disk_device( enum device_type type, struct disk_device **device_ret ) +/* create the disk device for a given drive */ +static NTSTATUS create_disk_device( const char *udi, enum device_type type, struct dos_drive **drive_ret ) { static const WCHAR harddiskvolW[] = {'\\','D','e','v','i','c','e', '\\','H','a','r','d','d','i','s','k','V','o','l','u','m','e','%','u',0}; @@ -203,7 +158,7 @@ static NTSTATUS create_disk_device( enum device_type type, struct disk_device ** const WCHAR *format = NULL; UNICODE_STRING name; DEVICE_OBJECT *dev_obj; - struct disk_device *device; + struct dos_drive *drive; switch(type) { @@ -233,31 +188,43 @@ static NTSTATUS create_disk_device( enum device_type type, struct disk_device ** { sprintfW( name.Buffer, format, i ); name.Length = strlenW(name.Buffer) * sizeof(WCHAR); - status = IoCreateDevice( harddisk_driver, sizeof(*device), &name, 0, 0, FALSE, &dev_obj ); + status = IoCreateDevice( harddisk_driver, sizeof(*drive), &name, 0, 0, FALSE, &dev_obj ); if (status != STATUS_OBJECT_NAME_COLLISION) break; } if (!status) { - device = dev_obj->DeviceExtension; - device->dev_obj = dev_obj; - device->name = name; - device->type = type; - device->unix_device = NULL; - device->unix_mount = NULL; - device->symlink.Buffer = NULL; - + drive = dev_obj->DeviceExtension; + drive->drive = -1; + drive->device = dev_obj; + drive->name = name; + drive->type = type; + drive->dosdev = NULL; + drive->volume = NULL; + drive->unix_device = NULL; + drive->unix_mount = NULL; + drive->symlink.Buffer = NULL; + if (udi) + { + if (!(drive->udi = HeapAlloc( GetProcessHeap(), 0, strlen(udi)+1 ))) + { + RtlFreeUnicodeString( &name ); + IoDeleteDevice( drive->device ); + return STATUS_NO_MEMORY; + } + strcpy( drive->udi, udi ); + } switch (type) { case DEVICE_FLOPPY: case DEVICE_RAMDISK: - device->devnum.DeviceType = FILE_DEVICE_DISK; - device->devnum.DeviceNumber = i; - device->devnum.PartitionNumber = ~0u; + drive->devnum.DeviceType = FILE_DEVICE_DISK; + drive->devnum.DeviceNumber = i; + drive->devnum.PartitionNumber = ~0u; break; case DEVICE_CDROM: - device->devnum.DeviceType = FILE_DEVICE_CD_ROM; - device->devnum.DeviceNumber = i; - device->devnum.PartitionNumber = ~0u; + drive->devnum.DeviceType = FILE_DEVICE_CD_ROM; + drive->devnum.DeviceNumber = i; + drive->devnum.PartitionNumber = ~0u; break; case DEVICE_UNKNOWN: case DEVICE_HARDDISK: @@ -270,20 +237,21 @@ static NTSTATUS create_disk_device( enum device_type type, struct disk_device ** { sprintfW( symlink.Buffer, physdriveW, i ); symlink.Length = strlenW(symlink.Buffer) * sizeof(WCHAR); - if (!IoCreateSymbolicLink( &symlink, &name )) device->symlink = symlink; + if (!IoCreateSymbolicLink( &symlink, &name )) drive->symlink = symlink; } - device->devnum.DeviceType = FILE_DEVICE_DISK; - device->devnum.DeviceNumber = i; - device->devnum.PartitionNumber = 0; + drive->devnum.DeviceType = FILE_DEVICE_DISK; + drive->devnum.DeviceNumber = i; + drive->devnum.PartitionNumber = 0; } break; case DEVICE_HARDDISK_VOL: - device->devnum.DeviceType = FILE_DEVICE_DISK; - device->devnum.DeviceNumber = 0; - device->devnum.PartitionNumber = i; + drive->devnum.DeviceType = FILE_DEVICE_DISK; + drive->devnum.DeviceNumber = 0; + drive->devnum.PartitionNumber = i; break; } - *device_ret = device; + list_add_tail( &drives_list, &drive->entry ); + *drive_ret = drive; TRACE( "created device %s\n", debugstr_w(name.Buffer) ); } else @@ -295,220 +263,42 @@ static NTSTATUS create_disk_device( enum device_type type, struct disk_device ** } /* delete the disk device for a given drive */ -static void delete_disk_device( struct disk_device *device ) -{ - TRACE( "deleting device %s\n", debugstr_w(device->name.Buffer) ); - if (device->symlink.Buffer) - { - IoDeleteSymbolicLink( &device->symlink ); - RtlFreeUnicodeString( &device->symlink ); - } - RtlFreeHeap( GetProcessHeap(), 0, device->unix_device ); - RtlFreeHeap( GetProcessHeap(), 0, device->unix_mount ); - RtlFreeUnicodeString( &device->name ); - IoDeleteDevice( device->dev_obj ); -} - -/* grab another reference to a volume */ -static unsigned int grab_volume( struct volume *volume ) -{ - return ++volume->ref; -} - -/* release a volume and delete the corresponding disk device when refcount is 0 */ -static unsigned int release_volume( struct volume *volume ) -{ - unsigned int ret = --volume->ref; - - TRACE( "%s udi %s count now %u\n", debugstr_guid(&volume->guid), debugstr_a(volume->udi), ret ); - if (!ret) - { - assert( !volume->udi ); - list_remove( &volume->entry ); - if (volume->mount) delete_mount_point( volume->mount ); - delete_disk_device( volume->device ); - RtlFreeHeap( GetProcessHeap(), 0, volume ); - } - return ret; -} - -/* set the volume udi */ -static void set_volume_udi( struct volume *volume, const char *udi ) -{ - if (udi) - { - assert( !volume->udi ); - /* having a udi means the HAL side holds an extra reference */ - if ((volume->udi = strdupA( udi ))) grab_volume( volume ); - } - else if (volume->udi) - { - RtlFreeHeap( GetProcessHeap(), 0, volume->udi ); - volume->udi = NULL; - release_volume( volume ); - } -} - -/* create a disk volume */ -static NTSTATUS create_volume( const char *udi, enum device_type type, struct volume **volume_ret ) -{ - struct volume *volume; - NTSTATUS status; - - if (!(volume = RtlAllocateHeap( GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*volume) ))) - return STATUS_NO_MEMORY; - - if (!(status = create_disk_device( type, &volume->device ))) - { - if (udi) set_volume_udi( volume, udi ); - list_add_tail( &volumes_list, &volume->entry ); - *volume_ret = volume; - } - else RtlFreeHeap( GetProcessHeap(), 0, volume ); - - return status; -} - -/* create the disk device for a given volume */ -static NTSTATUS create_dos_device( struct volume *volume, const char *udi, int letter, - enum device_type type, struct dos_drive **drive_ret ) -{ - struct dos_drive *drive; - NTSTATUS status; - - if (!(drive = RtlAllocateHeap( GetProcessHeap(), 0, sizeof(*drive) ))) return STATUS_NO_MEMORY; - drive->drive = letter; - drive->mount = NULL; - - if (volume) - { - if (udi) set_volume_udi( volume, udi ); - drive->volume = volume; - status = STATUS_SUCCESS; - } - else status = create_volume( udi, type, &drive->volume ); - - if (status == STATUS_SUCCESS) - { - grab_volume( drive->volume ); - list_add_tail( &drives_list, &drive->entry ); - *drive_ret = drive; - } - else RtlFreeHeap( GetProcessHeap(), 0, drive ); - - return status; -} - -/* delete the disk device for a given drive */ -static void delete_dos_device( struct dos_drive *drive ) +static void delete_disk_device( struct dos_drive *drive ) { + TRACE( "deleting device %s\n", debugstr_w(drive->name.Buffer) ); list_remove( &drive->entry ); - if (drive->mount) delete_mount_point( drive->mount ); - release_volume( drive->volume ); - RtlFreeHeap( GetProcessHeap(), 0, drive ); + if (drive->dosdev) delete_mount_point( drive->dosdev ); + if (drive->volume) delete_mount_point( drive->volume ); + if (drive->symlink.Buffer) + { + IoDeleteSymbolicLink( &drive->symlink ); + RtlFreeUnicodeString( &drive->symlink ); + } + RtlFreeHeap( GetProcessHeap(), 0, drive->unix_device ); + RtlFreeHeap( GetProcessHeap(), 0, drive->unix_mount ); + RtlFreeHeap( GetProcessHeap(), 0, drive->udi ); + RtlFreeUnicodeString( &drive->name ); + IoDeleteDevice( drive->device ); } -/* find a volume that matches the parameters */ -static struct volume *find_matching_volume( const char *udi, const char *device, - const char *mount_point, enum device_type type ) -{ - struct volume *volume; - struct disk_device *disk_device; - - LIST_FOR_EACH_ENTRY( volume, &volumes_list, struct volume, entry ) - { - /* when we have a udi we only match drives added manually */ - if (udi && volume->udi) continue; - /* and when we don't have a udi we only match dynamic drives */ - if (!udi && !volume->udi) continue; - - disk_device = volume->device; - if (disk_device->type != type) continue; - if (device && disk_device->unix_device && strcmp( device, disk_device->unix_device )) continue; - if (mount_point && disk_device->unix_mount && strcmp( mount_point, disk_device->unix_mount )) continue; - TRACE( "found matching volume %s for device %s mount %s type %u\n", - debugstr_guid(&volume->guid), debugstr_a(device), debugstr_a(mount_point), type ); - return volume; - } - return NULL; -} - -/* change the information for an existing volume */ -static NTSTATUS set_volume_info( struct volume *volume, struct dos_drive *drive, const char *device, - const char *mount_point, enum device_type type, const GUID *guid ) +/* set or change the drive letter for an existing drive */ +static void set_drive_letter( struct dos_drive *drive, int letter ) { void *id = NULL; unsigned int id_len = 0; - struct disk_device *disk_device = volume->device; - NTSTATUS status; - - if (type != disk_device->type) - { - if ((status = create_disk_device( type, &disk_device ))) return status; - if (volume->mount) - { - delete_mount_point( volume->mount ); - volume->mount = NULL; - } - if (drive && drive->mount) - { - delete_mount_point( drive->mount ); - drive->mount = NULL; - } - delete_disk_device( volume->device ); - volume->device = disk_device; - } - else - { - RtlFreeHeap( GetProcessHeap(), 0, disk_device->unix_device ); - RtlFreeHeap( GetProcessHeap(), 0, disk_device->unix_mount ); - } - disk_device->unix_device = strdupA( device ); - disk_device->unix_mount = strdupA( mount_point ); - - if (guid && memcmp( &volume->guid, guid, sizeof(volume->guid) )) - { - volume->guid = *guid; - if (volume->mount) - { - delete_mount_point( volume->mount ); - volume->mount = NULL; - } - } - if (!volume->mount) - volume->mount = add_volume_mount_point( disk_device->dev_obj, &disk_device->name, &volume->guid ); - if (drive && !drive->mount) - drive->mount = add_dosdev_mount_point( disk_device->dev_obj, &disk_device->name, drive->drive ); - - if (disk_device->unix_mount) - { - id = disk_device->unix_mount; - id_len = strlen( disk_device->unix_mount ) + 1; - } - if (volume->mount) set_mount_point_id( volume->mount, id, id_len ); - if (drive && drive->mount) set_mount_point_id( drive->mount, id, id_len ); - - return STATUS_SUCCESS; -} - -/* change the drive letter or volume for an existing drive */ -static void set_drive_info( struct dos_drive *drive, int letter, struct volume *volume ) -{ - if (drive->drive != letter) - { - if (drive->mount) delete_mount_point( drive->mount ); - drive->mount = NULL; - drive->drive = letter; - } - if (drive->volume != volume) + if (drive->drive == letter) return; + if (drive->dosdev) delete_mount_point( drive->dosdev ); + if (drive->volume) delete_mount_point( drive->volume ); + drive->drive = letter; + if (letter == -1) return; + if (drive->unix_mount) { - if (drive->mount) delete_mount_point( drive->mount ); - drive->mount = NULL; - grab_volume( volume ); - release_volume( drive->volume ); - drive->volume = volume; + id = drive->unix_mount; + id_len = strlen( drive->unix_mount ) + 1; } + drive->dosdev = add_dosdev_mount_point( drive->device, &drive->name, letter, id, id_len ); + drive->volume = add_volume_mount_point( drive->device, &drive->name, letter, id, id_len ); } static inline int is_valid_device( struct stat *st ) @@ -595,12 +385,47 @@ done: return drive; } +static BOOL set_unix_mount_point( struct dos_drive *drive, const char *mount_point ) +{ + char *path, *p; + BOOL modified = FALSE; + + if (!(path = get_dosdevices_path( &p ))) return FALSE; + p[0] = 'a' + drive->drive; + p[2] = 0; + + if (mount_point && mount_point[0]) + { + /* try to avoid unlinking if already set correctly */ + if (!drive->unix_mount || strcmp( drive->unix_mount, mount_point )) + { + unlink( path ); + symlink( mount_point, path ); + modified = TRUE; + } + RtlFreeHeap( GetProcessHeap(), 0, drive->unix_mount ); + drive->unix_mount = strdupA( mount_point ); + if (drive->dosdev) set_mount_point_id( drive->dosdev, mount_point, strlen(mount_point) + 1 ); + if (drive->volume) set_mount_point_id( drive->volume, mount_point, strlen(mount_point) + 1 ); + } + else + { + if (unlink( path ) != -1) modified = TRUE; + RtlFreeHeap( GetProcessHeap(), 0, drive->unix_mount ); + drive->unix_mount = NULL; + if (drive->dosdev) set_mount_point_id( drive->dosdev, NULL, 0 ); + if (drive->volume) set_mount_point_id( drive->volume, NULL, 0 ); + } + + HeapFree( GetProcessHeap(), 0, path ); + return modified; +} + /* create devices for mapped drives */ static void create_drive_devices(void) { char *path, *p, *link, *device; struct dos_drive *drive; - struct volume *volume; unsigned int i; HKEY drives_key; enum device_type drive_type; @@ -637,12 +462,11 @@ static void create_drive_devices(void) } } - volume = find_matching_volume( NULL, device, link, drive_type ); - if (!create_dos_device( volume, NULL, i, drive_type, &drive )) + if (!create_disk_device( NULL, drive_type, &drive )) { - /* don't reset uuid if we used an existing volume */ - const GUID *guid = volume ? NULL : get_default_uuid(i); - set_volume_info( drive->volume, drive, device, link, drive_type, guid ); + drive->unix_mount = link; + drive->unix_device = device; + set_drive_letter( drive, i ); } else { @@ -654,217 +478,139 @@ static void create_drive_devices(void) RtlFreeHeap( GetProcessHeap(), 0, path ); } -/* create a new disk volume */ -NTSTATUS add_volume( const char *udi, const char *device, const char *mount_point, - enum device_type type, const GUID *guid ) -{ - struct volume *volume; - NTSTATUS status = STATUS_SUCCESS; - - TRACE( "adding %s device %s mount %s type %u uuid %s\n", debugstr_a(udi), - debugstr_a(device), debugstr_a(mount_point), type, debugstr_guid(guid) ); - - EnterCriticalSection( &device_section ); - LIST_FOR_EACH_ENTRY( volume, &volumes_list, struct volume, entry ) - if (volume->udi && !strcmp( udi, volume->udi )) goto found; - - /* udi not found, search for a non-dynamic volume */ - if ((volume = find_matching_volume( udi, device, mount_point, type ))) set_volume_udi( volume, udi ); - else status = create_volume( udi, type, &volume ); - -found: - if (!status) status = set_volume_info( volume, NULL, device, mount_point, type, guid ); - LeaveCriticalSection( &device_section ); - return status; -} - -/* create a new disk volume */ -NTSTATUS remove_volume( const char *udi ) -{ - NTSTATUS status = STATUS_NO_SUCH_DEVICE; - struct volume *volume; - - EnterCriticalSection( &device_section ); - LIST_FOR_EACH_ENTRY( volume, &volumes_list, struct volume, entry ) - { - if (!volume->udi || strcmp( udi, volume->udi )) continue; - set_volume_udi( volume, NULL ); - status = STATUS_SUCCESS; - break; - } - LeaveCriticalSection( &device_section ); - return status; -} - - /* create a new dos drive */ NTSTATUS add_dos_device( int letter, const char *udi, const char *device, - const char *mount_point, enum device_type type, const GUID *guid ) + const char *mount_point, enum device_type type ) { - char *path, *p; - HKEY hkey; - NTSTATUS status = STATUS_SUCCESS; struct dos_drive *drive, *next; - struct volume *volume; - int notify = -1; - - if (!(path = get_dosdevices_path( &p ))) return STATUS_NO_MEMORY; - - EnterCriticalSection( &device_section ); - volume = find_matching_volume( udi, device, mount_point, type ); if (letter == -1) /* auto-assign a letter */ { letter = add_drive( device, type ); - if (letter == -1) - { - status = STATUS_OBJECT_NAME_COLLISION; - goto done; - } - - LIST_FOR_EACH_ENTRY_SAFE( drive, next, &drives_list, struct dos_drive, entry ) - { - if (drive->volume->udi && !strcmp( udi, drive->volume->udi )) goto found; - if (drive->drive == letter) delete_dos_device( drive ); - } + if (letter == -1) return STATUS_OBJECT_NAME_COLLISION; } else /* simply reset the device symlink */ { - LIST_FOR_EACH_ENTRY( drive, &drives_list, struct dos_drive, entry ) - if (drive->drive == letter) break; + char *path, *p; + if (!(path = get_dosdevices_path( &p ))) return STATUS_NO_MEMORY; *p = 'a' + letter; - if (&drive->entry == &drives_list) update_symlink( path, device, NULL ); - else + unlink( path ); + if (device) symlink( device, path ); + } + + LIST_FOR_EACH_ENTRY_SAFE( drive, next, &drives_list, struct dos_drive, entry ) + { + if (udi && drive->udi && !strcmp( udi, drive->udi )) { - update_symlink( path, device, drive->volume->device->unix_device ); - delete_dos_device( drive ); + if (type == drive->type) goto found; + delete_disk_device( drive ); + continue; } + if (drive->drive == letter) delete_disk_device( drive ); } - if ((status = create_dos_device( volume, udi, letter, type, &drive ))) goto done; + if (create_disk_device( udi, type, &drive )) return STATUS_NO_MEMORY; found: - if (!guid && !volume) guid = get_default_uuid( letter ); - if (!volume) volume = drive->volume; - set_drive_info( drive, letter, volume ); - p[0] = 'a' + drive->drive; - p[2] = 0; - update_symlink( path, mount_point, volume->device->unix_mount ); - set_volume_info( volume, drive, device, mount_point, type, guid ); - - TRACE( "added device %c: udi %s for %s on %s type %u\n", - 'a' + drive->drive, wine_dbgstr_a(udi), wine_dbgstr_a(device), - wine_dbgstr_a(mount_point), type ); + RtlFreeHeap( GetProcessHeap(), 0, drive->unix_device ); + drive->unix_device = strdupA( device ); + set_drive_letter( drive, letter ); + set_unix_mount_point( drive, mount_point ); - /* hack: force the drive type in the registry */ - if (!RegCreateKeyW( HKEY_LOCAL_MACHINE, drives_keyW, &hkey )) + if (drive->drive != -1) { - const WCHAR *type_name = drive_types[type]; - WCHAR name[3] = {'a',':',0}; - - name[0] += drive->drive; - if (!type_name[0] && type == DEVICE_HARDDISK) type_name = drive_types[DEVICE_FLOPPY]; - if (type_name[0]) - RegSetValueExW( hkey, name, 0, REG_SZ, (const BYTE *)type_name, - (strlenW(type_name) + 1) * sizeof(WCHAR) ); - else - RegDeleteValueW( hkey, name ); - RegCloseKey( hkey ); - } + HKEY hkey; - if (udi) notify = drive->drive; + TRACE( "added device %c: udi %s for %s on %s type %u\n", + 'a' + drive->drive, wine_dbgstr_a(udi), wine_dbgstr_a(device), + wine_dbgstr_a(mount_point), type ); -done: - LeaveCriticalSection( &device_section ); - RtlFreeHeap( GetProcessHeap(), 0, path ); - if (notify != -1) send_notify( notify, DBT_DEVICEARRIVAL ); - return status; + /* hack: force the drive type in the registry */ + if (!RegCreateKeyW( HKEY_LOCAL_MACHINE, drives_keyW, &hkey )) + { + const WCHAR *type_name = drive_types[type]; + WCHAR name[3] = {'a',':',0}; + + name[0] += drive->drive; + if (!type_name[0] && type == DEVICE_HARDDISK) type_name = drive_types[DEVICE_FLOPPY]; + if (type_name[0]) + RegSetValueExW( hkey, name, 0, REG_SZ, (const BYTE *)type_name, + (strlenW(type_name) + 1) * sizeof(WCHAR) ); + else + RegDeleteValueW( hkey, name ); + RegCloseKey( hkey ); + } + + if (udi) send_notify( drive->drive, DBT_DEVICEARRIVAL ); + } + return STATUS_SUCCESS; } /* remove an existing dos drive, by letter or udi */ NTSTATUS remove_dos_device( int letter, const char *udi ) { - NTSTATUS status = STATUS_NO_SUCH_DEVICE; HKEY hkey; struct dos_drive *drive; - char *path, *p; - int notify = -1; - EnterCriticalSection( &device_section ); LIST_FOR_EACH_ENTRY( drive, &drives_list, struct dos_drive, entry ) { + if (letter != -1 && drive->drive != letter) continue; if (udi) { - if (!drive->volume->udi) continue; - if (strcmp( udi, drive->volume->udi )) continue; - set_volume_udi( drive->volume, NULL ); + if (!drive->udi) continue; + if (strcmp( udi, drive->udi )) continue; } - else if (drive->drive != letter) continue; - if ((path = get_dosdevices_path( &p ))) + if (drive->drive != -1) { - p[0] = 'a' + drive->drive; - p[2] = 0; - unlink( path ); - RtlFreeHeap( GetProcessHeap(), 0, path ); - } + BOOL modified = set_unix_mount_point( drive, NULL ); - /* clear the registry key too */ - if (!RegOpenKeyW( HKEY_LOCAL_MACHINE, drives_keyW, &hkey )) - { - WCHAR name[3] = {'a',':',0}; - name[0] += drive->drive; - RegDeleteValueW( hkey, name ); - RegCloseKey( hkey ); - } - - if (udi && drive->volume->device->unix_mount) notify = drive->drive; + /* clear the registry key too */ + if (!RegOpenKeyW( HKEY_LOCAL_MACHINE, drives_keyW, &hkey )) + { + WCHAR name[3] = {'a',':',0}; + name[0] += drive->drive; + RegDeleteValueW( hkey, name ); + RegCloseKey( hkey ); + } - delete_dos_device( drive ); - status = STATUS_SUCCESS; - break; + if (modified && udi) send_notify( drive->drive, DBT_DEVICEREMOVECOMPLETE ); + } + delete_disk_device( drive ); + return STATUS_SUCCESS; } - LeaveCriticalSection( &device_section ); - if (notify != -1) send_notify( notify, DBT_DEVICEREMOVECOMPLETE ); - return status; + return STATUS_NO_SUCH_DEVICE; } /* query information about an existing dos drive, by letter or udi */ -NTSTATUS query_dos_device( int letter, enum device_type *type, char **device, char **mount_point ) +NTSTATUS query_dos_device( int letter, enum device_type *type, + const char **device, const char **mount_point ) { - NTSTATUS status = STATUS_NO_SUCH_DEVICE; struct dos_drive *drive; - struct disk_device *disk_device; - EnterCriticalSection( &device_section ); LIST_FOR_EACH_ENTRY( drive, &drives_list, struct dos_drive, entry ) { if (drive->drive != letter) continue; - disk_device = drive->volume->device; - if (type) *type = disk_device->type; - if (device) *device = strdupA( disk_device->unix_device ); - if (mount_point) *mount_point = strdupA( disk_device->unix_mount ); - status = STATUS_SUCCESS; - break; + if (type) *type = drive->type; + if (device) *device = drive->unix_device; + if (mount_point) *mount_point = drive->unix_mount; + return STATUS_SUCCESS; } - LeaveCriticalSection( &device_section ); - return status; + return STATUS_NO_SUCH_DEVICE; } /* handler for ioctls on the harddisk device */ static NTSTATUS WINAPI harddisk_ioctl( DEVICE_OBJECT *device, IRP *irp ) { IO_STACK_LOCATION *irpsp = irp->Tail.Overlay.s.u.CurrentStackLocation; - struct disk_device *dev = device->DeviceExtension; + struct dos_drive *drive = device->DeviceExtension; TRACE( "ioctl %x insize %u outsize %u\n", irpsp->Parameters.DeviceIoControl.IoControlCode, irpsp->Parameters.DeviceIoControl.InputBufferLength, irpsp->Parameters.DeviceIoControl.OutputBufferLength ); - EnterCriticalSection( &device_section ); - switch(irpsp->Parameters.DeviceIoControl.IoControlCode) { case IOCTL_DISK_GET_DRIVE_GEOMETRY: @@ -873,7 +619,7 @@ static NTSTATUS WINAPI harddisk_ioctl( DEVICE_OBJECT *device, IRP *irp ) DWORD len = min( sizeof(info), irpsp->Parameters.DeviceIoControl.OutputBufferLength ); info.Cylinders.QuadPart = 10000; - info.MediaType = (dev->devnum.DeviceType == FILE_DEVICE_DISK) ? FixedMedia : RemovableMedia; + info.MediaType = (drive->devnum.DeviceType == FILE_DEVICE_DISK) ? FixedMedia : RemovableMedia; info.TracksPerCylinder = 255; info.SectorsPerTrack = 63; info.BytesPerSector = 512; @@ -884,9 +630,9 @@ static NTSTATUS WINAPI harddisk_ioctl( DEVICE_OBJECT *device, IRP *irp ) } case IOCTL_STORAGE_GET_DEVICE_NUMBER: { - DWORD len = min( sizeof(dev->devnum), irpsp->Parameters.DeviceIoControl.OutputBufferLength ); + DWORD len = min( sizeof(drive->devnum), irpsp->Parameters.DeviceIoControl.OutputBufferLength ); - memcpy( irp->MdlAddress->StartVa, &dev->devnum, len ); + memcpy( irp->MdlAddress->StartVa, &drive->devnum, len ); irp->IoStatus.Information = len; irp->IoStatus.u.Status = STATUS_SUCCESS; break; @@ -899,21 +645,19 @@ static NTSTATUS WINAPI harddisk_ioctl( DEVICE_OBJECT *device, IRP *irp ) irp->IoStatus.u.Status = STATUS_NOT_SUPPORTED; break; } - - LeaveCriticalSection( &device_section ); return irp->IoStatus.u.Status; } /* driver entry point for the harddisk driver */ NTSTATUS WINAPI harddisk_driver_entry( DRIVER_OBJECT *driver, UNICODE_STRING *path ) { - struct disk_device *device; + struct dos_drive *drive; harddisk_driver = driver; driver->MajorFunction[IRP_MJ_DEVICE_CONTROL] = harddisk_ioctl; /* create a harddisk0 device that isn't assigned to any drive */ - create_disk_device( DEVICE_HARDDISK, &device ); + create_disk_device( "harddisk0 placeholder", DEVICE_HARDDISK, &drive ); create_drive_devices(); diff --git a/dlls/mountmgr.sys/diskarb.c b/dlls/mountmgr.sys/diskarb.c index 0c188ff2e0c..3296d0420cd 100644 --- a/dlls/mountmgr.sys/diskarb.c +++ b/dlls/mountmgr.sys/diskarb.c @@ -42,17 +42,13 @@ static void appeared_callback( DADiskRef disk, void *context ) const void *ref; char device[64]; char mount_point[PATH_MAX]; - GUID guid, *guid_ptr = NULL; enum device_type type = DEVICE_UNKNOWN; if (!dict) return; - if ((ref = CFDictionaryGetValue( dict, CFSTR("DAVolumeUUID") ))) - { - CFUUIDBytes bytes = CFUUIDGetUUIDBytes( ref ); - memcpy( &guid, &bytes, sizeof(guid) ); - guid_ptr = &guid; - } + /* ignore non-removable devices */ + if (!(ref = CFDictionaryGetValue( dict, CFSTR("DAMediaRemovable") )) || + !CFBooleanGetValue( ref )) goto done; /* get device name */ if (!(ref = CFDictionaryGetValue( dict, CFSTR("DAMediaBSDName") ))) goto done; @@ -71,14 +67,9 @@ static void appeared_callback( DADiskRef disk, void *context ) type = DEVICE_CDROM; } - TRACE( "got mount notification for '%s' on '%s' uuid %s\n", - device, mount_point, wine_dbgstr_guid(guid_ptr) ); - - if ((ref = CFDictionaryGetValue( dict, CFSTR("DAMediaRemovable") )) && CFBooleanGetValue( ref )) - add_dos_device( -1, device, device, mount_point, type, guid_ptr ); - else - if (guid_ptr) add_volume( device, device, mount_point, DEVICE_HARDDISK_VOL, guid_ptr ); + TRACE( "got mount notification for '%s' on '%s'\n", device, mount_point ); + add_dos_device( -1, device, device, mount_point, type ); done: CFRelease( dict ); } @@ -96,6 +87,10 @@ static void disappeared_callback( DADiskRef disk, void *context ) if (!dict) return; + /* ignore non-removable devices */ + if (!(ref = CFDictionaryGetValue( dict, CFSTR("DAMediaRemovable") )) || + !CFBooleanGetValue( ref )) goto done; + /* get device name */ if (!(ref = CFDictionaryGetValue( dict, CFSTR("DAMediaBSDName") ))) goto done; strcpy( device, "/dev/r" ); @@ -103,11 +98,7 @@ static void disappeared_callback( DADiskRef disk, void *context ) TRACE( "got unmount notification for '%s'\n", device ); - if ((ref = CFDictionaryGetValue( dict, CFSTR("DAMediaRemovable") )) && CFBooleanGetValue( ref )) - remove_dos_device( -1, device ); - else - remove_volume( device ); - + remove_dos_device( -1, device ); done: CFRelease( dict ); } diff --git a/dlls/mountmgr.sys/hal.c b/dlls/mountmgr.sys/hal.c index 82a70e9bfae..310b1443756 100644 --- a/dlls/mountmgr.sys/hal.c +++ b/dlls/mountmgr.sys/hal.c @@ -28,7 +28,6 @@ #include #include "mountmgr.h" -#include "winnls.h" #include "excpt.h" #include "wine/library.h" @@ -106,33 +105,6 @@ static LONG WINAPI assert_fault(EXCEPTION_POINTERS *eptr) return EXCEPTION_CONTINUE_SEARCH; } -static GUID *parse_uuid( GUID *guid, const char *str ) -{ - /* standard uuid format */ - if (strlen(str) == 36) - { - UNICODE_STRING strW; - WCHAR buffer[39]; - - if (MultiByteToWideChar( CP_UNIXCP, 0, str, 36, buffer + 1, 36 )) - { - buffer[0] = '{'; - buffer[37] = '}'; - buffer[38] = 0; - RtlInitUnicodeString( &strW, buffer ); - if (!RtlGUIDFromString( &strW, guid )) return guid; - } - } - - /* check for xxxx-xxxx format (FAT serial number) */ - if (strlen(str) == 9 && str[4] == '-') - { - memset( guid, 0, sizeof(*guid) ); - if (sscanf( str, "%hx-%hx", &guid->Data2, &guid->Data3 ) == 2) return guid; - } - return NULL; -} - /* HAL callback for new device */ static void new_device( LibHalContext *ctx, const char *udi ) { @@ -141,8 +113,6 @@ static void new_device( LibHalContext *ctx, const char *udi ) char *mount_point = NULL; char *device = NULL; char *type = NULL; - char *uuid_str = NULL; - GUID guid, *guid_ptr = NULL; enum device_type drive_type; p_dbus_error_init( &error ); @@ -156,10 +126,8 @@ static void new_device( LibHalContext *ctx, const char *udi ) if (!(parent = p_libhal_device_get_property_string( ctx, udi, "info.parent", &error ))) goto done; - if (!(uuid_str = p_libhal_device_get_property_string( ctx, udi, "volume.uuid", &error ))) - p_dbus_error_free( &error ); /* ignore error */ - else - guid_ptr = parse_uuid( &guid, uuid_str ); + if (!p_libhal_device_get_property_bool( ctx, parent, "storage.removable", &error )) + goto done; if (!(type = p_libhal_device_get_property_string( ctx, parent, "storage.drive_type", &error ))) p_dbus_error_free( &error ); /* ignore error */ @@ -168,19 +136,15 @@ static void new_device( LibHalContext *ctx, const char *udi ) else if (type && !strcmp( type, "floppy" )) drive_type = DEVICE_FLOPPY; else drive_type = DEVICE_UNKNOWN; - if (p_libhal_device_get_property_bool( ctx, parent, "storage.removable", &error )) - { - add_dos_device( -1, udi, device, mount_point, drive_type, guid_ptr ); - /* add property watch for mount point */ - p_libhal_device_add_property_watch( ctx, udi, &error ); - } - else if (guid_ptr) add_volume( udi, device, mount_point, DEVICE_HARDDISK_VOL, guid_ptr ); + add_dos_device( -1, udi, device, mount_point, drive_type ); + + /* add property watch for mount point */ + p_libhal_device_add_property_watch( ctx, udi, &error ); done: if (type) p_libhal_free_string( type ); if (parent) p_libhal_free_string( parent ); if (device) p_libhal_free_string( device ); - if (uuid_str) p_libhal_free_string( uuid_str ); if (mount_point) p_libhal_free_string( mount_point ); p_dbus_error_free( &error ); } @@ -198,7 +162,6 @@ static void removed_device( LibHalContext *ctx, const char *udi ) p_libhal_device_remove_property_watch( ctx, udi, &error ); p_dbus_error_free( &error ); } - else remove_volume( udi ); } /* HAL callback for property changes */ diff --git a/dlls/mountmgr.sys/mountmgr.c b/dlls/mountmgr.sys/mountmgr.c index a80d4924ebf..d2b15156355 100644 --- a/dlls/mountmgr.sys/mountmgr.c +++ b/dlls/mountmgr.sys/mountmgr.c @@ -61,7 +61,7 @@ void set_mount_point_id( struct mount_point *mount, const void *id, unsigned int } static struct mount_point *add_mount_point( DEVICE_OBJECT *device, UNICODE_STRING *device_name, - const WCHAR *link ) + const WCHAR *link, const void *id, unsigned int id_len ) { struct mount_point *mount; WCHAR *str; @@ -83,6 +83,7 @@ static struct mount_point *add_mount_point( DEVICE_OBJECT *device, UNICODE_STRIN list_add_tail( &mount_points_list, &mount->entry ); IoCreateSymbolicLink( &mount->link, device_name ); + set_mount_point_id( mount, id, id_len ); TRACE( "created %s id %s for %s\n", debugstr_w(mount->link.Buffer), debugstr_a(mount->id), debugstr_w(mount->name.Buffer) ); @@ -90,29 +91,33 @@ static struct mount_point *add_mount_point( DEVICE_OBJECT *device, UNICODE_STRIN } /* create the DosDevices mount point symlink for a new device */ -struct mount_point *add_dosdev_mount_point( DEVICE_OBJECT *device, UNICODE_STRING *device_name, int drive ) +struct mount_point *add_dosdev_mount_point( DEVICE_OBJECT *device, UNICODE_STRING *device_name, + int drive, const void *id, unsigned int id_len ) { static const WCHAR driveW[] = {'\\','D','o','s','D','e','v','i','c','e','s','\\','%','c',':',0}; WCHAR link[sizeof(driveW)]; sprintfW( link, driveW, 'A' + drive ); - return add_mount_point( device, device_name, link ); + return add_mount_point( device, device_name, link, id, id_len ); } /* create the Volume mount point symlink for a new device */ struct mount_point *add_volume_mount_point( DEVICE_OBJECT *device, UNICODE_STRING *device_name, - const GUID *guid ) + int drive, const void *id, unsigned int id_len ) { static const WCHAR volumeW[] = {'\\','?','?','\\','V','o','l','u','m','e','{', '%','0','8','x','-','%','0','4','x','-','%','0','4','x','-', '%','0','2','x','%','0','2','x','-','%','0','2','x','%','0','2','x', '%','0','2','x','%','0','2','x','%','0','2','x','%','0','2','x','}',0}; WCHAR link[sizeof(volumeW)]; - - sprintfW( link, volumeW, guid->Data1, guid->Data2, guid->Data3, - guid->Data4[0], guid->Data4[1], guid->Data4[2], guid->Data4[3], - guid->Data4[4], guid->Data4[5], guid->Data4[6], guid->Data4[7]); - return add_mount_point( device, device_name, link ); + GUID guid; + + memset( &guid, 0, sizeof(guid) ); /* FIXME */ + guid.Data4[7] = 'A' + drive; + sprintfW( link, volumeW, guid.Data1, guid.Data2, guid.Data3, + guid.Data4[0], guid.Data4[1], guid.Data4[2], guid.Data4[3], + guid.Data4[4], guid.Data4[5], guid.Data4[6], guid.Data4[7]); + return add_mount_point( device, device_name, link, id, id_len ); } /* delete the mount point symlinks when a device goes away */ @@ -261,7 +266,7 @@ static NTSTATUS define_unix_drive( const void *in_buff, SIZE_T insize ) case DRIVE_RAMDISK: type = DEVICE_RAMDISK; break; case DRIVE_FIXED: type = DEVICE_HARDDISK_VOL; break; } - return add_dos_device( letter - 'a', NULL, device, mount_point, type, NULL ); + return add_dos_device( letter - 'a', NULL, device, mount_point, type ); } else { @@ -276,7 +281,7 @@ static NTSTATUS query_unix_drive( const void *in_buff, SIZE_T insize, { const struct mountmgr_unix_drive *input = in_buff; struct mountmgr_unix_drive *output = out_buff; - char *device, *mount_point; + const char *device, *mount_point; int letter = tolowerW( input->letter ); NTSTATUS status; DWORD size, type = DEVICE_UNKNOWN; @@ -314,8 +319,7 @@ static NTSTATUS query_unix_drive( const void *in_buff, SIZE_T insize, output->type = type; iosb->Information = FIELD_OFFSET( struct mountmgr_unix_drive, type ) + sizeof(output->type); } - status = STATUS_MORE_ENTRIES; - goto done; + return STATUS_MORE_ENTRIES; } output->size = size; output->letter = letter; @@ -342,10 +346,7 @@ static NTSTATUS query_unix_drive( const void *in_buff, SIZE_T insize, letter, debugstr_a(device), debugstr_a(mount_point), type ); iosb->Information = ptr - (char *)output; -done: - RtlFreeHeap( GetProcessHeap(), 0, device ); - RtlFreeHeap( GetProcessHeap(), 0, mount_point ); - return status; + return STATUS_SUCCESS; } /* handler for ioctls on the mount manager device */ diff --git a/dlls/mountmgr.sys/mountmgr.h b/dlls/mountmgr.sys/mountmgr.h index 3d57ba146ac..e8f7d5d7c7c 100644 --- a/dlls/mountmgr.sys/mountmgr.h +++ b/dlls/mountmgr.sys/mountmgr.h @@ -51,13 +51,11 @@ enum device_type DEVICE_RAMDISK }; -extern NTSTATUS add_volume( const char *udi, const char *device, const char *mount_point, - enum device_type type, const GUID *guid ); -extern NTSTATUS remove_volume( const char *udi ); extern NTSTATUS add_dos_device( int letter, const char *udi, const char *device, - const char *mount_point, enum device_type type, const GUID *guid ); + const char *mount_point, enum device_type type ); extern NTSTATUS remove_dos_device( int letter, const char *udi ); -extern NTSTATUS query_dos_device( int letter, enum device_type *type, char **device, char **mount_point ); +extern NTSTATUS query_dos_device( int letter, enum device_type *type, + const char **device, const char **mount_point ); extern NTSTATUS WINAPI harddisk_driver_entry( DRIVER_OBJECT *driver, UNICODE_STRING *path ); /* mount point functions */ @@ -65,8 +63,8 @@ extern NTSTATUS WINAPI harddisk_driver_entry( DRIVER_OBJECT *driver, UNICODE_STR struct mount_point; extern struct mount_point *add_dosdev_mount_point( DEVICE_OBJECT *device, UNICODE_STRING *device_name, - int drive ); + int drive, const void *id, unsigned int id_len ); extern struct mount_point *add_volume_mount_point( DEVICE_OBJECT *device, UNICODE_STRING *device_name, - const GUID *guid ); + int drive, const void *id, unsigned int id_len ); extern void delete_mount_point( struct mount_point *mount ); extern void set_mount_point_id( struct mount_point *mount, const void *id, unsigned int id_len ); diff --git a/dlls/mouse.drv16/Makefile.in b/dlls/mouse.drv16/Makefile.in index e4226946153..982e9b7ddcf 100644 --- a/dlls/mouse.drv16/Makefile.in +++ b/dlls/mouse.drv16/Makefile.in @@ -8,6 +8,8 @@ IMPORTS = user32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16 EXTRARCFLAGS = -O res16 +SPEC_SRCS = mouse.drv16.spec + C_SRCS = mouse.c RC_SRCS = mouse.rc diff --git a/dlls/mpr/Makefile.in b/dlls/mpr/Makefile.in index 98cd7e982ee..fe92cf9cf27 100644 --- a/dlls/mpr/Makefile.in +++ b/dlls/mpr/Makefile.in @@ -14,31 +14,7 @@ C_SRCS = \ pwcache.c \ wnet.c -RC_SRCS = \ - mpr_Bg.rc \ - mpr_Cs.rc \ - mpr_Da.rc \ - mpr_De.rc \ - mpr_En.rc \ - mpr_Eo.rc \ - mpr_Es.rc \ - mpr_Fr.rc \ - mpr_Hu.rc \ - mpr_It.rc \ - mpr_Ja.rc \ - mpr_Ko.rc \ - mpr_Lt.rc \ - mpr_Nl.rc \ - mpr_No.rc \ - mpr_Pl.rc \ - mpr_Pt.rc \ - mpr_Ro.rc \ - mpr_Ru.rc \ - mpr_Si.rc \ - mpr_Sv.rc \ - mpr_Tr.rc \ - mpr_Zh.rc \ - version.rc +RC_SRCS = mpr.rc @MAKE_DLL_RULES@ diff --git a/dlls/mpr/mpr.rc b/dlls/mpr/mpr.rc new file mode 100644 index 00000000000..e9f0cfbc4b4 --- /dev/null +++ b/dlls/mpr/mpr.rc @@ -0,0 +1,48 @@ +/* + * MPR dll resources + * + * Copyright (C) 2004 Juan Lang + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "mprres.h" + +#include "version.rc" + +#include "mpr_Bg.rc" +#include "mpr_Cs.rc" +#include "mpr_Da.rc" +#include "mpr_De.rc" +#include "mpr_En.rc" +#include "mpr_Eo.rc" +#include "mpr_Es.rc" +#include "mpr_Fr.rc" +#include "mpr_Hu.rc" +#include "mpr_It.rc" +#include "mpr_Ja.rc" +#include "mpr_Ko.rc" +#include "mpr_Nl.rc" +#include "mpr_No.rc" +#include "mpr_Pl.rc" +#include "mpr_Pt.rc" +#include "mpr_Ro.rc" +#include "mpr_Ru.rc" +#include "mpr_Si.rc" +#include "mpr_Sv.rc" +#include "mpr_Tr.rc" +#include "mpr_Zh.rc" diff --git a/dlls/mpr/mpr_Bg.rc b/dlls/mpr/mpr_Bg.rc index 52353d2a066..a37f7961be1 100644 --- a/dlls/mpr/mpr_Bg.rc +++ b/dlls/mpr/mpr_Bg.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_Cs.rc b/dlls/mpr/mpr_Cs.rc index 8e32de4747e..6085e7160c6 100644 --- a/dlls/mpr/mpr_Cs.rc +++ b/dlls/mpr/mpr_Cs.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/dlls/mpr/mpr_Da.rc b/dlls/mpr/mpr_Da.rc index 52dc635d19a..5b6f99fbd04 100644 --- a/dlls/mpr/mpr_Da.rc +++ b/dlls/mpr/mpr_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_De.rc b/dlls/mpr/mpr_De.rc index d8b1298ac41..41429be5501 100644 --- a/dlls/mpr/mpr_De.rc +++ b/dlls/mpr/mpr_De.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_En.rc b/dlls/mpr/mpr_En.rc index c6fdf727785..c71840423f4 100644 --- a/dlls/mpr/mpr_En.rc +++ b/dlls/mpr/mpr_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_Eo.rc b/dlls/mpr/mpr_Eo.rc index 2701f759507..0ed9f470d40 100644 --- a/dlls/mpr/mpr_Eo.rc +++ b/dlls/mpr/mpr_Eo.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_Es.rc b/dlls/mpr/mpr_Es.rc index 630a9fe9141..d82758cbeae 100644 --- a/dlls/mpr/mpr_Es.rc +++ b/dlls/mpr/mpr_Es.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_Fr.rc b/dlls/mpr/mpr_Fr.rc index 4481639ad35..ba43eefa077 100644 --- a/dlls/mpr/mpr_Fr.rc +++ b/dlls/mpr/mpr_Fr.rc @@ -19,34 +19,29 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { - IDS_ENTIRENETWORK "Le réseau entier" + IDS_ENTIRENETWORK "Le réseau entier" } -IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 210, 146 +IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Entrez le mot de passe réseau" +CAPTION "Entrez le mot de passe réseau" FONT 8, "MS Shell Dlg" { - LTEXT "Veuillez saisir votre nom d'utilisateur et votre mot de passe :", IDC_EXPLAIN, 10, 6, 150, 17 - LTEXT "Proxy", -1, 10, 31, 50, 10 + LTEXT "Veuillez saisir votre nom d'utilisateur et votre mot de passe:", IDC_EXPLAIN, 40, 6, 150, 15 + LTEXT "Proxy", -1, 40, 26, 50, 10 /* LTEXT "Realm", -1, 40, 46, 50, 10 */ - LTEXT "Utilisateur", -1, 10, 68, 45, 10 - LTEXT "Mot de passe", -1, 10, 88, 45, 10 - LTEXT "" IDC_PROXY, 56, 32, 144, 14, 0 - LTEXT "" IDC_REALM, 56, 46, 144, 14, 0 - EDITTEXT IDC_USERNAME, 56, 66, 144, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP - EDITTEXT IDC_PASSWORD, 56, 86, 144, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP | ES_PASSWORD - CHECKBOX "&Enregistrer ce mot de passe (risqué)", IDC_SAVEPASSWORD, - 56, 106, 144, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON "OK", IDOK, 68, 126, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON - PUSHBUTTON "Annuler", IDCANCEL, 128, 126, 56, 14, WS_GROUP | WS_TABSTOP + LTEXT "Utilisateur", -1, 40, 66, 50, 10 + LTEXT "Mot de passe", -1, 40, 86, 50, 10 + LTEXT "" IDC_PROXY, 80, 26, 150, 14, 0 + LTEXT "" IDC_REALM, 80, 46, 150, 14, 0 + EDITTEXT IDC_USERNAME, 80, 66, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP + EDITTEXT IDC_PASSWORD, 80, 86, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP | ES_PASSWORD + CHECKBOX "&Enregistrer ce mot de passe (risqué)", IDC_SAVEPASSWORD, + 80, 106, 150, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 98, 126, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON + PUSHBUTTON "Annuler", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP } diff --git a/dlls/mpr/mpr_Hu.rc b/dlls/mpr/mpr_Hu.rc index 32c32dd6da6..d3561cb3fe6 100644 --- a/dlls/mpr/mpr_Hu.rc +++ b/dlls/mpr/mpr_Hu.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_It.rc b/dlls/mpr/mpr_It.rc index 7067ee37d96..501644d0978 100644 --- a/dlls/mpr/mpr_It.rc +++ b/dlls/mpr/mpr_It.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_Ja.rc b/dlls/mpr/mpr_Ja.rc index 7cd68f07754..ad1a45685b3 100644 --- a/dlls/mpr/mpr_Ja.rc +++ b/dlls/mpr/mpr_Ja.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - /* UTF-8 */ #pragma code_page(65001) @@ -29,3 +27,5 @@ STRINGTABLE DISCARDABLE { IDS_ENTIRENETWORK "ネットワーク全体" } + +#pragma code_page(default) diff --git a/dlls/mpr/mpr_Ko.rc b/dlls/mpr/mpr_Ko.rc index 4ebbd8f3575..75688cda4e8 100644 --- a/dlls/mpr/mpr_Ko.rc +++ b/dlls/mpr/mpr_Ko.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_Lt.rc b/dlls/mpr/mpr_Lt.rc deleted file mode 100644 index d086d94c3b7..00000000000 --- a/dlls/mpr/mpr_Lt.rc +++ /dev/null @@ -1,51 +0,0 @@ -/* - * MPR dll resources - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "mprres.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_ENTIRENETWORK "Visas tinklas" -} - -IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Įveskite tinklo slaptažodį" -FONT 8, "MS Shell Dlg" -{ - LTEXT "Įveskite savo naudotojo vardą ir slaptažodį:", IDC_EXPLAIN, 40, 6, 150, 15 - LTEXT "Įgaliot. serv.", -1, 40, 26, 50, 10 -/* LTEXT "Sritis", -1, 40, 46, 50, 10 */ - LTEXT "Naudotojas", -1, 40, 66, 50, 10 - LTEXT "Slaptažodis", -1, 40, 86, 50, 10 - LTEXT "" IDC_PROXY, 80, 26, 150, 14, 0 - LTEXT "" IDC_REALM, 80, 46, 150, 14, 0 - EDITTEXT IDC_USERNAME, 80, 66, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP - EDITTEXT IDC_PASSWORD, 80, 86, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP | ES_PASSWORD - CHECKBOX "Į&rašyti šį slaptažodį (nesaugu)", IDC_SAVEPASSWORD, - 80, 106, 150, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Gerai", IDOK, 98, 126, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON - PUSHBUTTON "Atsisakyti", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP -} diff --git a/dlls/mpr/mpr_Nl.rc b/dlls/mpr/mpr_Nl.rc index b1c67819799..430ac6aa8c8 100644 --- a/dlls/mpr/mpr_Nl.rc +++ b/dlls/mpr/mpr_Nl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_No.rc b/dlls/mpr/mpr_No.rc index 150ee509edb..32833542db9 100644 --- a/dlls/mpr/mpr_No.rc +++ b/dlls/mpr/mpr_No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_Pl.rc b/dlls/mpr/mpr_Pl.rc index afdd3ba6343..a6f2446f3ea 100644 --- a/dlls/mpr/mpr_Pl.rc +++ b/dlls/mpr/mpr_Pl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_Pt.rc b/dlls/mpr/mpr_Pt.rc index b0191939094..f79a96dcab8 100644 --- a/dlls/mpr/mpr_Pt.rc +++ b/dlls/mpr/mpr_Pt.rc @@ -2,7 +2,7 @@ * MPR dll resources * * Copyright (C) 2004 Marcelo Duarte - * Copyright (C) 2006 Américo José Melo + * Copyright (C) 2006 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 @@ -19,11 +19,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE DISCARDABLE { @@ -38,10 +34,10 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Entre a senha da rede" FONT 8, "MS Shell Dlg" { - LTEXT "Por favor, entre como o nome de usuário e a senha:", IDC_EXPLAIN, 40, 6, 150, 15 + LTEXT "Por favor, entre como o nome de usuário e a senha:", IDC_EXPLAIN, 40, 6, 150, 15 LTEXT "Proxy", -1, 40, 26, 50, 10 /* LTEXT "Realm", -1, 40, 46, 50, 10 */ - LTEXT "Usuário", -1, 40, 66, 50, 10 + LTEXT "Usuário", -1, 40, 66, 50, 10 LTEXT "Senha", -1, 40, 86, 50, 10 LTEXT "" IDC_PROXY, 80, 26, 150, 14, 0 LTEXT "" IDC_REALM, 80, 46, 150, 14, 0 diff --git a/dlls/mpr/mpr_Ro.rc b/dlls/mpr/mpr_Ro.rc index ab7d137e2b2..ce06328ef80 100644 --- a/dlls/mpr/mpr_Ro.rc +++ b/dlls/mpr/mpr_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -46,3 +44,5 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "OK", IDOK, 98, 126, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON PUSHBUTTON "Renunță", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP } + +#pragma code_page(default) diff --git a/dlls/mpr/mpr_Ru.rc b/dlls/mpr/mpr_Ru.rc index 3d17a0a93a5..d093c0612bb 100644 --- a/dlls/mpr/mpr_Ru.rc +++ b/dlls/mpr/mpr_Ru.rc @@ -18,34 +18,29 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { - IDS_ENTIRENETWORK "Вся сеть" + IDS_ENTIRENETWORK "Âñÿ ñåòü" } IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Введите сетевой пароль" +CAPTION "Ââåäèòå ñåòåâîé ïàðîëü" FONT 8, "MS Shell Dlg" { - LTEXT "Введите ваши имя и пароль пользователя:", IDC_EXPLAIN, 40, 6, 150, 15 - LTEXT "Прокси", -1, 40, 26, 50, 10 + LTEXT "Ââåäèòå âàøè èìÿ è ïàðîëü ïîëüçîâàòåëÿ:", IDC_EXPLAIN, 40, 6, 150, 15 + LTEXT "Ïðîêñè", -1, 40, 26, 50, 10 /* LTEXT "Realm", -1, 40, 46, 50, 10 */ - LTEXT "Имя", -1, 40, 66, 50, 10 - LTEXT "Пароль", -1, 40, 86, 50, 10 + LTEXT "Èìÿ", -1, 40, 66, 50, 10 + LTEXT "Ïàðîëü", -1, 40, 86, 50, 10 LTEXT "" IDC_PROXY, 80, 26, 150, 14, 0 LTEXT "" IDC_REALM, 80, 46, 150, 14, 0 EDITTEXT IDC_USERNAME, 80, 66, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP EDITTEXT IDC_PASSWORD, 80, 86, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP | ES_PASSWORD - CHECKBOX "&Сохранить этот пароль (небезопасно!)", IDC_SAVEPASSWORD, + CHECKBOX "&Ñîõðàíèòü ýòîò ïàðîëü (íåáåçîïàñíî!)", IDC_SAVEPASSWORD, 80, 106, 150, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP PUSHBUTTON "OK", IDOK, 98, 126, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON - PUSHBUTTON "Отмена", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Îòìåíà", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP } diff --git a/dlls/mpr/mpr_Si.rc b/dlls/mpr/mpr_Si.rc index 8f4022e402f..064bf525978 100644 --- a/dlls/mpr/mpr_Si.rc +++ b/dlls/mpr/mpr_Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -48,3 +46,5 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "V redu", IDOK, 98, 126, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON PUSHBUTTON "Prekliči", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP } + +#pragma code_page(default) diff --git a/dlls/mpr/mpr_Sv.rc b/dlls/mpr/mpr_Sv.rc index 86d0db6602a..ef6a685c44d 100644 --- a/dlls/mpr/mpr_Sv.rc +++ b/dlls/mpr/mpr_Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_Tr.rc b/dlls/mpr/mpr_Tr.rc index 0f48a156a31..b9f3af1fa03 100644 --- a/dlls/mpr/mpr_Tr.rc +++ b/dlls/mpr/mpr_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/mpr/mpr_Zh.rc b/dlls/mpr/mpr_Zh.rc index 661e6b4afcd..47eb629131b 100644 --- a/dlls/mpr/mpr_Zh.rc +++ b/dlls/mpr/mpr_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "mprres.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -76,3 +74,5 @@ FONT 9, "MS Shell Dlg" PUSHBUTTON "確定", IDOK, 98, 126, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON PUSHBUTTON "取消", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP } + +#pragma code_page(default) diff --git a/dlls/mpr/mprres.h b/dlls/mpr/mprres.h index 5c42e565477..292b4765260 100644 --- a/dlls/mpr/mprres.h +++ b/dlls/mpr/mprres.h @@ -18,9 +18,6 @@ #ifndef __WINE_MPRRES_H__ #define __WINE_MPRRES_H__ -#include -#include - #define IDS_ENTIRENETWORK 1 #define IDD_PROXYDLG 0x400 diff --git a/dlls/msacm.dll16/Makefile.in b/dlls/msacm.dll16/Makefile.in index ae02dcfef5c..6bb17e6acb5 100644 --- a/dlls/msacm.dll16/Makefile.in +++ b/dlls/msacm.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = msacm.dll16 IMPORTS = msacm32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,msacm32.dll +SPEC_SRCS = msacm.dll16.spec + C_SRCS = msacm.c @MAKE_DLL_RULES@ diff --git a/dlls/msacm32/Makefile.in b/dlls/msacm32/Makefile.in index 78dfef8a234..48a1d2b2dec 100644 --- a/dlls/msacm32/Makefile.in +++ b/dlls/msacm32/Makefile.in @@ -15,28 +15,7 @@ C_SRCS = \ pcmconverter.c \ stream.c -RC_SRCS = \ - msacm_Cs.rc \ - msacm_Da.rc \ - msacm_De.rc \ - msacm_En.rc \ - msacm_Es.rc \ - msacm_Fr.rc \ - msacm_Hu.rc \ - msacm_It.rc \ - msacm_Ja.rc \ - msacm_Ko.rc \ - msacm_Lt.rc \ - msacm_Nl.rc \ - msacm_No.rc \ - msacm_Pl.rc \ - msacm_Pt.rc \ - msacm_Ro.rc \ - msacm_Ru.rc \ - msacm_Si.rc \ - msacm_Sv.rc \ - msacm_Tr.rc \ - msacm_Zh.rc +RC_SRCS = msacm.rc @MAKE_DLL_RULES@ diff --git a/dlls/msacm32/msacm.rc b/dlls/msacm32/msacm.rc new file mode 100644 index 00000000000..ffc14854308 --- /dev/null +++ b/dlls/msacm32/msacm.rc @@ -0,0 +1,46 @@ +/* + * Top level resource file for MS ACM + * + * Copyright 2000 Eric Pouech + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "wineacm.h" + +#include "msacm_Cs.rc" +#include "msacm_Da.rc" +#include "msacm_De.rc" +#include "msacm_En.rc" +#include "msacm_Es.rc" +#include "msacm_Fr.rc" +#include "msacm_Hu.rc" +#include "msacm_It.rc" +#include "msacm_Ja.rc" +#include "msacm_Ko.rc" +#include "msacm_Lt.rc" +#include "msacm_Nl.rc" +#include "msacm_No.rc" +#include "msacm_Pl.rc" +#include "msacm_Pt.rc" +#include "msacm_Ro.rc" +#include "msacm_Ru.rc" +#include "msacm_Si.rc" +#include "msacm_Sv.rc" +#include "msacm_Tr.rc" +#include "msacm_Zh.rc" diff --git a/dlls/msacm32/msacm_Cs.rc b/dlls/msacm32/msacm_Cs.rc index d7b278e4474..169e760b89c 100644 --- a/dlls/msacm32/msacm_Cs.rc +++ b/dlls/msacm32/msacm_Cs.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/dlls/msacm32/msacm_Da.rc b/dlls/msacm32/msacm_Da.rc index 67f31c8362f..25ca1dbc52b 100644 --- a/dlls/msacm32/msacm_Da.rc +++ b/dlls/msacm32/msacm_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 diff --git a/dlls/msacm32/msacm_De.rc b/dlls/msacm32/msacm_De.rc index 1f35148ebe4..8d60c363a8e 100644 --- a/dlls/msacm32/msacm_De.rc +++ b/dlls/msacm32/msacm_De.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 diff --git a/dlls/msacm32/msacm_En.rc b/dlls/msacm32/msacm_En.rc index 620dfcf1699..e7c7ec2888f 100644 --- a/dlls/msacm32/msacm_En.rc +++ b/dlls/msacm32/msacm_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 diff --git a/dlls/msacm32/msacm_Es.rc b/dlls/msacm32/msacm_Es.rc index 3e6f441767a..8d16b62240e 100644 --- a/dlls/msacm32/msacm_Es.rc +++ b/dlls/msacm32/msacm_Es.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 diff --git a/dlls/msacm32/msacm_Fr.rc b/dlls/msacm32/msacm_Fr.rc index 9341e6cafd4..c170d2fff80 100644 --- a/dlls/msacm32/msacm_Fr.rc +++ b/dlls/msacm32/msacm_Fr.rc @@ -2,7 +2,7 @@ * French resource file for MS ACM * * Copyright 2000 Eric Pouech - * Copyright 2003 Vincent Béron + * Copyright 2003 Vincent Béron * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -19,30 +19,25 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL -DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 250, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Sélection du son" +CAPTION "Sélection du son" FONT 8, "MS Shell Dlg" BEGIN LTEXT "&Nom :", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 15, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Enregistrer sous...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 70, 14 - PUSHBUTTON "&Supprimer", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 199, 14, 45, 14 + PUSHBUTTON "&Enregistrer sous...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 + PUSHBUTTON "&Retirer", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 LTEXT "&Format :", -1, 5, 41, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 48, 39, 197, 15, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP LTEXT "&Attributs :", -1, 5, 59, 44, 8, NOT WS_GROUP @@ -52,7 +47,7 @@ BEGIN CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP | CBS_OWNERDRAWFIXED | CBS_HASSTRINGS #else - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 48, 57, 197, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP #endif DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 diff --git a/dlls/msacm32/msacm_Hu.rc b/dlls/msacm32/msacm_Hu.rc index 52f32584cf7..3bc440e2b3a 100644 --- a/dlls/msacm32/msacm_Hu.rc +++ b/dlls/msacm32/msacm_Hu.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 diff --git a/dlls/msacm32/msacm_It.rc b/dlls/msacm32/msacm_It.rc index 07db54b6d54..1ce6b42b369 100644 --- a/dlls/msacm32/msacm_It.rc +++ b/dlls/msacm32/msacm_It.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 diff --git a/dlls/msacm32/msacm_Ja.rc b/dlls/msacm32/msacm_Ja.rc index 5a27330a167..e9a63f9e257 100644 --- a/dlls/msacm32/msacm_Ja.rc +++ b/dlls/msacm32/msacm_Ja.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - /* UTF-8 */ #pragma code_page(65001) @@ -59,3 +57,5 @@ BEGIN PUSHBUTTON "ヘルプ(&H)", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 END + +#pragma code_page(default) diff --git a/dlls/msacm32/msacm_Ko.rc b/dlls/msacm32/msacm_Ko.rc index fd017cc7ec3..1123e1f7f80 100644 --- a/dlls/msacm32/msacm_Ko.rc +++ b/dlls/msacm32/msacm_Ko.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 diff --git a/dlls/msacm32/msacm_Lt.rc b/dlls/msacm32/msacm_Lt.rc index a94710cd9fb..8decd59d02b 100644 --- a/dlls/msacm32/msacm_Lt.rc +++ b/dlls/msacm32/msacm_Lt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - /* UTF-8 */ #pragma code_page(65001) @@ -59,3 +57,5 @@ BEGIN PUSHBUTTON "&Žinynas", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 END + +#pragma code_page(default) diff --git a/dlls/msacm32/msacm_Nl.rc b/dlls/msacm32/msacm_Nl.rc index 1fb0b059b20..fd7fb79d547 100644 --- a/dlls/msacm32/msacm_Nl.rc +++ b/dlls/msacm32/msacm_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 diff --git a/dlls/msacm32/msacm_No.rc b/dlls/msacm32/msacm_No.rc index 1bef4343834..e099f091a0e 100644 --- a/dlls/msacm32/msacm_No.rc +++ b/dlls/msacm32/msacm_No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 diff --git a/dlls/msacm32/msacm_Pl.rc b/dlls/msacm32/msacm_Pl.rc index 8b580783fe7..940b004d013 100644 --- a/dlls/msacm32/msacm_Pl.rc +++ b/dlls/msacm32/msacm_Pl.rc @@ -18,9 +18,6 @@ * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ - -#include "wineacm.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 235, 100 diff --git a/dlls/msacm32/msacm_Pt.rc b/dlls/msacm32/msacm_Pt.rc index d73951c6899..17cbca22062 100644 --- a/dlls/msacm32/msacm_Pt.rc +++ b/dlls/msacm32/msacm_Pt.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 diff --git a/dlls/msacm32/msacm_Ro.rc b/dlls/msacm32/msacm_Ro.rc index 412d5049ea7..d1cc0bbb653 100644 --- a/dlls/msacm32/msacm_Ro.rc +++ b/dlls/msacm32/msacm_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -52,3 +50,5 @@ BEGIN PUSHBUTTON "&Ajutor", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 END + +#pragma code_page(default) diff --git a/dlls/msacm32/msacm_Ru.rc b/dlls/msacm32/msacm_Ru.rc index a777034e00d..d634139396f 100644 --- a/dlls/msacm32/msacm_Ru.rc +++ b/dlls/msacm32/msacm_Ru.rc @@ -18,33 +18,28 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Выбор звука" +CAPTION "Âûáîð çâóêà" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "&Имя:", -1, 5, 5, 115, 8, NOT WS_GROUP + LTEXT "&Èìÿ:", -1, 5, 5, 115, 8, NOT WS_GROUP COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Сохранить как...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Удалить", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "&Ñîõðàíèòü êàê...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 + PUSHBUTTON "&Óäàëèòü", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 - LTEXT "&Формат:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Ôîðìàò:", -1, 5, 41, 44, 8, NOT WS_GROUP COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Свойства:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Ñâîéñòâà:", -1, 5, 59, 44, 8, NOT WS_GROUP #if 0 COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, @@ -55,7 +50,7 @@ BEGIN CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP #endif DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Отмена", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Помощь", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "Îòìåíà", IDCANCEL, 92, 80, 40, 14 + PUSHBUTTON "&Ïîìîùü", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 END diff --git a/dlls/msacm32/msacm_Si.rc b/dlls/msacm32/msacm_Si.rc index 3834a3304f1..2513f763021 100644 --- a/dlls/msacm32/msacm_Si.rc +++ b/dlls/msacm32/msacm_Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -58,3 +56,5 @@ BEGIN PUSHBUTTON "&Pomoč", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 END + +#pragma code_page(default) diff --git a/dlls/msacm32/msacm_Sv.rc b/dlls/msacm32/msacm_Sv.rc index 939e8793371..747e6085b01 100644 --- a/dlls/msacm32/msacm_Sv.rc +++ b/dlls/msacm32/msacm_Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 diff --git a/dlls/msacm32/msacm_Tr.rc b/dlls/msacm32/msacm_Tr.rc index 6c15ffb0e39..0ececa4cca6 100644 --- a/dlls/msacm32/msacm_Tr.rc +++ b/dlls/msacm32/msacm_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT DLG_ACMFORMATCHOOSE_ID DIALOG DISCARDABLE 10, 20, 225, 100 diff --git a/dlls/msacm32/msacm_Zh.rc b/dlls/msacm32/msacm_Zh.rc index 1b8949e55f2..2bc138b5acd 100644 --- a/dlls/msacm32/msacm_Zh.rc +++ b/dlls/msacm32/msacm_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineacm.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -96,3 +94,5 @@ BEGIN PUSHBUTTON "幫助(&H)", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 END + +#pragma code_page(default) diff --git a/dlls/msacm32/wineacm.h b/dlls/msacm32/wineacm.h index bf0c6ed04d4..b566e618a6a 100644 --- a/dlls/msacm32/wineacm.h +++ b/dlls/msacm32/wineacm.h @@ -20,9 +20,6 @@ #ifndef __WINE_WINEACM_H #define __WINE_WINEACM_H -#include -#include - /*********************************************************************** * Wine specific - Win32 */ diff --git a/dlls/msctf/compartmentmgr.c b/dlls/msctf/compartmentmgr.c index 06a691d9967..5342568cd79 100644 --- a/dlls/msctf/compartmentmgr.c +++ b/dlls/msctf/compartmentmgr.c @@ -67,33 +67,7 @@ typedef struct tagCompartmentEnumGuid { struct list *cursor; } CompartmentEnumGuid; - -typedef struct tagCompartmentSink { - struct list entry; - union { - IUnknown *pIUnknown; - ITfCompartmentEventSink *pITfCompartmentEventSink; - } interfaces; -} CompartmentSink; - -typedef struct tagCompartment { - const ITfCompartmentVtbl *Vtbl; - const ITfSourceVtbl *SourceVtbl; - LONG refCount; - - /* Only VT_I4, VT_UNKNOWN and VT_BSTR data types are allowed */ - VARIANT variant; - CompartmentValue *valueData; - struct list CompartmentEventSink; -} Compartment; - static HRESULT CompartmentEnumGuid_Constructor(struct list* values, IEnumGUID **ppOut); -static HRESULT Compartment_Constructor(CompartmentValue *value, ITfCompartment **ppOut); - -static inline Compartment *impl_from_ITfSourceVtbl(ITfSource *iface) -{ - return (Compartment *)((char *)iface - FIELD_OFFSET(Compartment,SourceVtbl)); -} HRESULT CompartmentMgr_Destructor(ITfCompartmentMgr *iface) { @@ -169,39 +143,8 @@ static HRESULT WINAPI CompartmentMgr_GetCompartment(ITfCompartmentMgr *iface, REFGUID rguid, ITfCompartment **ppcomp) { CompartmentMgr *This = (CompartmentMgr *)iface; - CompartmentValue* value; - struct list *cursor; - HRESULT hr; - - TRACE("(%p) %s %p\n",This,debugstr_guid(rguid),ppcomp); - - LIST_FOR_EACH(cursor, &This->values) - { - value = LIST_ENTRY(cursor,CompartmentValue,entry); - if (IsEqualGUID(rguid,&value->guid)) - { - ITfCompartment_AddRef(value->compartment); - *ppcomp = value->compartment; - return S_OK; - } - } - - value = HeapAlloc(GetProcessHeap(),0,sizeof(CompartmentValue)); - value->guid = *rguid; - value->owner = 0; - hr = Compartment_Constructor(value,&value->compartment); - if (SUCCEEDED(hr)) - { - list_add_head(&This->values,&value->entry); - ITfCompartment_AddRef(value->compartment); - *ppcomp = value->compartment; - } - else - { - HeapFree(GetProcessHeap(),0,value); - *ppcomp = NULL; - } - return hr; + FIXME("STUB:(%p)\n",This); + return E_NOTIMPL; } static HRESULT WINAPI CompartmentMgr_ClearCompartment(ITfCompartmentMgr *iface, @@ -424,237 +367,3 @@ static HRESULT CompartmentEnumGuid_Constructor(struct list *values, IEnumGUID ** *ppOut = (IEnumGUID*)This; return S_OK; } - -/************************************************** - * ITfCompartment - **************************************************/ -static void free_sink(CompartmentSink *sink) -{ - IUnknown_Release(sink->interfaces.pIUnknown); - HeapFree(GetProcessHeap(),0,sink); -} - -static void Compartment_Destructor(Compartment *This) -{ - struct list *cursor, *cursor2; - TRACE("destroying %p\n", This); - VariantClear(&This->variant); - LIST_FOR_EACH_SAFE(cursor, cursor2, &This->CompartmentEventSink) - { - CompartmentSink* sink = LIST_ENTRY(cursor,CompartmentSink,entry); - list_remove(cursor); - free_sink(sink); - } - HeapFree(GetProcessHeap(),0,This); -} - -static HRESULT WINAPI Compartment_QueryInterface(ITfCompartment *iface, REFIID iid, LPVOID *ppvOut) -{ - Compartment *This = (Compartment *)iface; - *ppvOut = NULL; - - if (IsEqualIID(iid, &IID_IUnknown) || IsEqualIID(iid, &IID_ITfCompartment)) - { - *ppvOut = This; - } - else if (IsEqualIID(iid, &IID_ITfSource)) - { - *ppvOut = &This->SourceVtbl; - } - - if (*ppvOut) - { - IUnknown_AddRef(iface); - return S_OK; - } - - WARN("unsupported interface: %s\n", debugstr_guid(iid)); - return E_NOINTERFACE; -} - -static ULONG WINAPI Compartment_AddRef(ITfCompartment *iface) -{ - Compartment *This = (Compartment*)iface; - return InterlockedIncrement(&This->refCount); -} - -static ULONG WINAPI Compartment_Release(ITfCompartment *iface) -{ - Compartment *This = (Compartment *)iface; - ULONG ret; - - ret = InterlockedDecrement(&This->refCount); - if (ret == 0) - Compartment_Destructor(This); - return ret; -} - -static HRESULT WINAPI Compartment_SetValue(ITfCompartment *iface, - TfClientId tid, const VARIANT *pvarValue) -{ - Compartment *This = (Compartment *)iface; - struct list *cursor; - - TRACE("(%p) %i %p\n",This,tid,pvarValue); - - if (!pvarValue) - return E_INVALIDARG; - - if (!(V_VT(pvarValue) == VT_BSTR || V_VT(pvarValue) == VT_I4 || - V_VT(pvarValue) == VT_UNKNOWN)) - return E_INVALIDARG; - - if (!This->valueData->owner) - This->valueData->owner = tid; - - VariantClear(&This->variant); - - /* Shallow copy of value and type */ - This->variant = *pvarValue; - - if (V_VT(pvarValue) == VT_BSTR) - V_BSTR(&This->variant) = SysAllocStringByteLen((char*)V_BSTR(pvarValue), - SysStringByteLen(V_BSTR(pvarValue))); - else if (V_VT(pvarValue) == VT_UNKNOWN) - IUnknown_AddRef(V_UNKNOWN(&This->variant)); - - LIST_FOR_EACH(cursor, &This->CompartmentEventSink) - { - CompartmentSink* sink = LIST_ENTRY(cursor,CompartmentSink,entry); - ITfCompartmentEventSink_OnChange(sink->interfaces.pITfCompartmentEventSink,&This->valueData->guid); - } - - return S_OK; -} - -static HRESULT WINAPI Compartment_GetValue(ITfCompartment *iface, - VARIANT *pvarValue) -{ - Compartment *This = (Compartment *)iface; - TRACE("(%p) %p\n",This, pvarValue); - - if (!pvarValue) - return E_INVALIDARG; - - VariantInit(pvarValue); - if (V_VT(&This->variant) == VT_EMPTY) return S_FALSE; - return VariantCopy(pvarValue,&This->variant); -} - -static const ITfCompartmentVtbl ITfCompartment_Vtbl ={ - Compartment_QueryInterface, - Compartment_AddRef, - Compartment_Release, - - Compartment_SetValue, - Compartment_GetValue -}; - -/***************************************************** - * ITfSource functions - *****************************************************/ - -static HRESULT WINAPI Source_QueryInterface(ITfSource *iface, REFIID iid, LPVOID *ppvOut) -{ - Compartment *This = impl_from_ITfSourceVtbl(iface); - return Compartment_QueryInterface((ITfCompartment *)This, iid, *ppvOut); -} - -static ULONG WINAPI Source_AddRef(ITfSource *iface) -{ - Compartment *This = impl_from_ITfSourceVtbl(iface); - return Compartment_AddRef((ITfCompartment*)This); -} - -static ULONG WINAPI Source_Release(ITfSource *iface) -{ - Compartment *This = impl_from_ITfSourceVtbl(iface); - return Compartment_Release((ITfCompartment *)This); -} - -static WINAPI HRESULT CompartmentSource_AdviseSink(ITfSource *iface, - REFIID riid, IUnknown *punk, DWORD *pdwCookie) -{ - CompartmentSink *cs; - Compartment *This = impl_from_ITfSourceVtbl(iface); - - TRACE("(%p) %s %p %p\n",This,debugstr_guid(riid),punk,pdwCookie); - - if (!riid || !punk || !pdwCookie) - return E_INVALIDARG; - - if (IsEqualIID(riid, &IID_ITfCompartmentEventSink)) - { - cs = HeapAlloc(GetProcessHeap(),0,sizeof(CompartmentSink)); - if (!cs) - return E_OUTOFMEMORY; - if (FAILED(IUnknown_QueryInterface(punk, riid, (LPVOID *)&cs->interfaces.pITfCompartmentEventSink))) - { - HeapFree(GetProcessHeap(),0,cs); - return CONNECT_E_CANNOTCONNECT; - } - list_add_head(&This->CompartmentEventSink,&cs->entry); - *pdwCookie = generate_Cookie(COOKIE_MAGIC_COMPARTMENTSINK , cs); - } - else - { - FIXME("(%p) Unhandled Sink: %s\n",This,debugstr_guid(riid)); - return E_NOTIMPL; - } - - TRACE("cookie %x\n",*pdwCookie); - - return S_OK; -} - -static WINAPI HRESULT CompartmentSource_UnadviseSink(ITfSource *iface, DWORD pdwCookie) -{ - CompartmentSink *sink; - Compartment *This = impl_from_ITfSourceVtbl(iface); - - TRACE("(%p) %x\n",This,pdwCookie); - - if (get_Cookie_magic(pdwCookie)!=COOKIE_MAGIC_COMPARTMENTSINK) - return E_INVALIDARG; - - sink = (CompartmentSink*)remove_Cookie(pdwCookie); - if (!sink) - return CONNECT_E_NOCONNECTION; - - list_remove(&sink->entry); - free_sink(sink); - - return S_OK; -} - -static const ITfSourceVtbl Compartment_SourceVtbl = -{ - Source_QueryInterface, - Source_AddRef, - Source_Release, - - CompartmentSource_AdviseSink, - CompartmentSource_UnadviseSink, -}; - -static HRESULT Compartment_Constructor(CompartmentValue *valueData, ITfCompartment **ppOut) -{ - Compartment *This; - - This = HeapAlloc(GetProcessHeap(),HEAP_ZERO_MEMORY,sizeof(Compartment)); - if (This == NULL) - return E_OUTOFMEMORY; - - This->Vtbl= &ITfCompartment_Vtbl; - This->SourceVtbl = &Compartment_SourceVtbl; - This->refCount = 1; - - This->valueData = valueData; - VariantInit(&This->variant); - - list_init(&This->CompartmentEventSink); - - TRACE("returning %p\n", This); - *ppOut = (ITfCompartment*)This; - return S_OK; -} diff --git a/dlls/msctf/context.c b/dlls/msctf/context.c index 5be06d3e747..e5cf602fb97 100644 --- a/dlls/msctf/context.c +++ b/dlls/msctf/context.c @@ -466,25 +466,8 @@ static HRESULT WINAPI Context_GetStatus (ITfContext *iface, TF_STATUS *pdcs) { Context *This = (Context *)iface; - TRACE("(%p) %p\n",This,pdcs); - - if (!This->connected) - return TF_E_DISCONNECTED; - - if (!pdcs) - return E_INVALIDARG; - - if (!This->pITextStoreACP) - { - FIXME("Context does not have a ITextStoreACP\n"); - return E_NOTIMPL; - } - - ITextStoreACP_GetStatus(This->pITextStoreACP, &This->documentStatus); - - *pdcs = This->documentStatus; - - return S_OK; + FIXME("STUB:(%p)\n",This); + return E_NOTIMPL; } static HRESULT WINAPI Context_GetProperty (ITfContext *iface, @@ -532,9 +515,6 @@ static HRESULT WINAPI Context_GetDocumentMgr (ITfContext *iface, *ppDm = This->manager; if (!This->manager) return S_FALSE; - - ITfDocumentMgr_AddRef(This->manager); - return S_OK; } diff --git a/dlls/msctf/documentmgr.c b/dlls/msctf/documentmgr.c index 0a25b3d3b67..c7aa8209ee1 100644 --- a/dlls/msctf/documentmgr.c +++ b/dlls/msctf/documentmgr.c @@ -52,16 +52,6 @@ typedef struct tagDocumentMgr { ITfThreadMgrEventSink* ThreadMgrSink; } DocumentMgr; -typedef struct tagEnumTfContext { - const IEnumTfContextsVtbl *Vtbl; - LONG refCount; - - DWORD index; - DocumentMgr *docmgr; -} EnumTfContext; - -static HRESULT EnumTfContext_Constructor(DocumentMgr* mgr, IEnumTfContexts **ppOut); - static inline DocumentMgr *impl_from_ITfSourceVtbl(ITfSource *iface) { return (DocumentMgr *)((char *)iface - FIELD_OFFSET(DocumentMgr,SourceVtbl)); @@ -69,12 +59,7 @@ static inline DocumentMgr *impl_from_ITfSourceVtbl(ITfSource *iface) static void DocumentMgr_Destructor(DocumentMgr *This) { - ITfThreadMgr *tm; TRACE("destroying %p\n", This); - - TF_GetThreadMgr(&tm); - ThreadMgr_OnDocumentMgrDestruction(tm, (ITfDocumentMgr*)This); - if (This->contextStack[0]) ITfContext_Release(This->contextStack[0]); if (This->contextStack[1]) @@ -160,8 +145,8 @@ static HRESULT WINAPI DocumentMgr_Push(ITfDocumentMgr *iface, ITfContext *pic) This->contextStack[1] = This->contextStack[0]; This->contextStack[0] = check; - Context_Initialize(check, iface); ITfThreadMgrEventSink_OnPushContext(This->ThreadMgrSink,check); + Context_Initialize(check, iface); return S_OK; } @@ -248,8 +233,8 @@ static HRESULT WINAPI DocumentMgr_GetBase(ITfDocumentMgr *iface, ITfContext **pp static HRESULT WINAPI DocumentMgr_EnumContexts(ITfDocumentMgr *iface, IEnumTfContexts **ppEnum) { DocumentMgr *This = (DocumentMgr *)iface; - TRACE("(%p) %p\n",This,ppEnum); - return EnumTfContext_Constructor(This, ppEnum); + FIXME("STUB:(%p)\n",This); + return E_NOTIMPL; } static const ITfDocumentMgrVtbl DocumentMgr_DocumentMgrVtbl = @@ -332,142 +317,3 @@ HRESULT DocumentMgr_Constructor(ITfThreadMgrEventSink *ThreadMgrSink, ITfDocumen *ppOut = (ITfDocumentMgr*)This; return S_OK; } - -/************************************************** - * IEnumTfContexts implementaion - **************************************************/ -static void EnumTfContext_Destructor(EnumTfContext *This) -{ - TRACE("destroying %p\n", This); - HeapFree(GetProcessHeap(),0,This); -} - -static HRESULT WINAPI EnumTfContext_QueryInterface(IEnumTfContexts *iface, REFIID iid, LPVOID *ppvOut) -{ - EnumTfContext *This = (EnumTfContext *)iface; - *ppvOut = NULL; - - if (IsEqualIID(iid, &IID_IUnknown) || IsEqualIID(iid, &IID_IEnumTfContexts)) - { - *ppvOut = This; - } - - if (*ppvOut) - { - IUnknown_AddRef(iface); - return S_OK; - } - - WARN("unsupported interface: %s\n", debugstr_guid(iid)); - return E_NOINTERFACE; -} - -static ULONG WINAPI EnumTfContext_AddRef(IEnumTfContexts *iface) -{ - EnumTfContext *This = (EnumTfContext*)iface; - return InterlockedIncrement(&This->refCount); -} - -static ULONG WINAPI EnumTfContext_Release(IEnumTfContexts *iface) -{ - EnumTfContext *This = (EnumTfContext *)iface; - ULONG ret; - - ret = InterlockedDecrement(&This->refCount); - if (ret == 0) - EnumTfContext_Destructor(This); - return ret; -} - -static HRESULT WINAPI EnumTfContext_Next(IEnumTfContexts *iface, - ULONG ulCount, ITfContext **rgContext, ULONG *pcFetched) -{ - EnumTfContext *This = (EnumTfContext *)iface; - ULONG fetched = 0; - - TRACE("(%p)\n",This); - - if (rgContext == NULL) return E_POINTER; - - while (fetched < ulCount) - { - if (This->index > 1) - break; - - if (!This->docmgr->contextStack[This->index]) - break; - - *rgContext = This->docmgr->contextStack[This->index]; - ITfContext_AddRef(*rgContext); - - ++This->index; - ++fetched; - ++rgContext; - } - - if (pcFetched) *pcFetched = fetched; - return fetched == ulCount ? S_OK : S_FALSE; -} - -static HRESULT WINAPI EnumTfContext_Skip( IEnumTfContexts* iface, ULONG celt) -{ - EnumTfContext *This = (EnumTfContext *)iface; - TRACE("(%p)\n",This); - This->index += celt; - return S_OK; -} - -static HRESULT WINAPI EnumTfContext_Reset( IEnumTfContexts* iface) -{ - EnumTfContext *This = (EnumTfContext *)iface; - TRACE("(%p)\n",This); - This->index = 0; - return S_OK; -} - -static HRESULT WINAPI EnumTfContext_Clone( IEnumTfContexts *iface, - IEnumTfContexts **ppenum) -{ - EnumTfContext *This = (EnumTfContext *)iface; - HRESULT res; - - TRACE("(%p)\n",This); - - if (ppenum == NULL) return E_POINTER; - - res = EnumTfContext_Constructor(This->docmgr, ppenum); - if (SUCCEEDED(res)) - { - EnumTfContext *new_This = (EnumTfContext *)*ppenum; - new_This->index = This->index; - } - return res; -} - -static const IEnumTfContextsVtbl IEnumTfContexts_Vtbl ={ - EnumTfContext_QueryInterface, - EnumTfContext_AddRef, - EnumTfContext_Release, - - EnumTfContext_Clone, - EnumTfContext_Next, - EnumTfContext_Reset, - EnumTfContext_Skip -}; - -static HRESULT EnumTfContext_Constructor(DocumentMgr *mgr, IEnumTfContexts **ppOut) -{ - EnumTfContext *This; - - This = HeapAlloc(GetProcessHeap(),HEAP_ZERO_MEMORY,sizeof(EnumTfContext)); - if (This == NULL) - return E_OUTOFMEMORY; - - This->Vtbl= &IEnumTfContexts_Vtbl; - This->refCount = 1; - This->docmgr = mgr; - - TRACE("returning %p\n", This); - *ppOut = (IEnumTfContexts*)This; - return S_OK; -} diff --git a/dlls/msctf/inputprocessor.c b/dlls/msctf/inputprocessor.c index 2cd20cddc82..a904a68b854 100644 --- a/dlls/msctf/inputprocessor.c +++ b/dlls/msctf/inputprocessor.c @@ -43,15 +43,10 @@ WINE_DEFAULT_DEBUG_CHANNEL(msctf); static const WCHAR szwLngp[] = {'L','a','n','g','u','a','g','e','P','r','o','f','i','l','e',0}; -static const WCHAR szwEnable[] = {'E','n','a','b','l','e',0}; +static const WCHAR szwEnabled[] = {'E','n','a','b','l','e','d',0}; static const WCHAR szwTipfmt[] = {'%','s','\\','%','s',0}; static const WCHAR szwFullLangfmt[] = {'%','s','\\','%','s','\\','%','s','\\','0','x','%','0','8','x','\\','%','s',0}; -static const WCHAR szwAssemblies[] = {'A','s','s','e','m','b','l','i','e','s',0}; -static const WCHAR szwDefault[] = {'D','e','f','a','u','l','t',0}; -static const WCHAR szwProfile[] = {'P','r','o','f','i','l','e',0}; -static const WCHAR szwDefaultFmt[] = {'%','s','\\','%','s','\\','0','x','%','0','8','x','\\','%','s',0}; - typedef struct tagInputProcessorProfilesSink { struct list entry; union { @@ -149,7 +144,7 @@ static void add_userkey( REFCLSID rclsid, LANGID langid, if (!res && disposition == REG_CREATED_NEW_KEY) { DWORD zero = 0x0; - RegSetValueExW(key, szwEnable, 0, REG_DWORD, (LPBYTE)&zero, sizeof(DWORD)); + RegSetValueExW(key, szwEnabled, 0, REG_DWORD, (LPBYTE)&zero, sizeof(DWORD)); } if (!res) @@ -283,7 +278,7 @@ static HRESULT WINAPI InputProcessorProfiles_AddLanguageProfile( RegSetValueExW(fmtkey, icnf, 0, REG_SZ, (LPBYTE)pchIconFile, cchFile * sizeof(WCHAR)); RegSetValueExW(fmtkey, icni, 0, REG_DWORD, (LPBYTE)&uIconIndex, sizeof(DWORD)); if (disposition == REG_CREATED_NEW_KEY) - RegSetValueExW(fmtkey, szwEnable, 0, REG_DWORD, (LPBYTE)&zero, sizeof(DWORD)); + RegSetValueExW(fmtkey, szwEnabled, 0, REG_DWORD, (LPBYTE)&zero, sizeof(DWORD)); RegCloseKey(fmtkey); add_userkey(rclsid, langid, guidProfile); @@ -317,91 +312,18 @@ static HRESULT WINAPI InputProcessorProfiles_GetDefaultLanguageProfile( ITfInputProcessorProfiles *iface, LANGID langid, REFGUID catid, CLSID *pclsid, GUID *pguidProfile) { - WCHAR fullkey[168]; - WCHAR buf[39]; - HKEY hkey; - DWORD count; - ULONG res; InputProcessorProfiles *This = (InputProcessorProfiles*)iface; - - TRACE("%p) %x %s %p %p\n",This, langid, debugstr_guid(catid),pclsid,pguidProfile); - - if (!catid || !pclsid || !pguidProfile) - return E_INVALIDARG; - - StringFromGUID2(catid, buf, 39); - sprintfW(fullkey, szwDefaultFmt, szwSystemCTFKey, szwAssemblies, langid, buf); - - if (RegOpenKeyExW(HKEY_CURRENT_USER, fullkey, 0, KEY_READ | KEY_WRITE, - &hkey ) != ERROR_SUCCESS) - return S_FALSE; - - count = sizeof(buf); - res = RegQueryValueExW(hkey, szwDefault, 0, NULL, (LPBYTE)buf, &count); - if (res != ERROR_SUCCESS) - { - RegCloseKey(hkey); - return S_FALSE; - } - CLSIDFromString(buf,pclsid); - - res = RegQueryValueExW(hkey, szwProfile, 0, NULL, (LPBYTE)buf, &count); - if (res == ERROR_SUCCESS) - CLSIDFromString(buf,pguidProfile); - - RegCloseKey(hkey); - - return S_OK; + FIXME("STUB:(%p)\n",This); + return E_NOTIMPL; } static HRESULT WINAPI InputProcessorProfiles_SetDefaultLanguageProfile( ITfInputProcessorProfiles *iface, LANGID langid, REFCLSID rclsid, REFGUID guidProfiles) { - WCHAR fullkey[168]; - WCHAR buf[39]; - HKEY hkey; - GUID catid; - HRESULT hr; - ITfCategoryMgr *catmgr; InputProcessorProfiles *This = (InputProcessorProfiles*)iface; - static const GUID * tipcats[3] = { &GUID_TFCAT_TIP_KEYBOARD, - &GUID_TFCAT_TIP_SPEECH, - &GUID_TFCAT_TIP_HANDWRITING }; - - TRACE("%p) %x %s %s\n",This, langid, debugstr_guid(rclsid),debugstr_guid(guidProfiles)); - - if (!rclsid || !guidProfiles) - return E_INVALIDARG; - - hr = CategoryMgr_Constructor(NULL,(IUnknown**)&catmgr); - - if (FAILED(hr)) - return hr; - - if (ITfCategoryMgr_FindClosestCategory(catmgr, rclsid, - &catid, tipcats, 3) != S_OK) - hr = ITfCategoryMgr_FindClosestCategory(catmgr, rclsid, - &catid, NULL, 0); - ITfCategoryMgr_Release(catmgr); - - if (FAILED(hr)) - return E_FAIL; - - StringFromGUID2(&catid, buf, 39); - sprintfW(fullkey, szwDefaultFmt, szwSystemCTFKey, szwAssemblies, langid, buf); - - if (RegCreateKeyExW(HKEY_CURRENT_USER, fullkey, 0, NULL, 0, KEY_READ | KEY_WRITE, - NULL, &hkey, NULL ) != ERROR_SUCCESS) - return E_FAIL; - - StringFromGUID2(rclsid, buf, 39); - RegSetValueExW(hkey, szwDefault, 0, REG_SZ, (LPBYTE)buf, sizeof(buf)); - StringFromGUID2(guidProfiles, buf, 39); - RegSetValueExW(hkey, szwProfile, 0, REG_SZ, (LPBYTE)buf, sizeof(buf)); - RegCloseKey(hkey); - - return S_OK; + FIXME("STUB:(%p)\n",This); + return E_NOTIMPL; } static HRESULT WINAPI InputProcessorProfiles_ActivateLanguageProfile( @@ -500,11 +422,8 @@ static HRESULT WINAPI InputProcessorProfiles_GetLanguageList( ITfInputProcessorProfiles *iface, LANGID **ppLangId, ULONG *pulCount) { InputProcessorProfiles *This = (InputProcessorProfiles*)iface; - FIXME("Semi-STUB:(%p)\n",This); - *ppLangId = CoTaskMemAlloc(sizeof(LANGID)); - **ppLangId = This->currentLanguage; - *pulCount = 1; - return S_OK; + FIXME("STUB:(%p)\n",This); + return E_NOTIMPL; } static HRESULT WINAPI InputProcessorProfiles_EnumLanguageProfiles( @@ -537,7 +456,7 @@ static HRESULT WINAPI InputProcessorProfiles_EnableLanguageProfile( if (!res) { - RegSetValueExW(key, szwEnable, 0, REG_DWORD, (LPBYTE)&fEnable, sizeof(DWORD)); + RegSetValueExW(key, szwEnabled, 0, REG_DWORD, (LPBYTE)&fEnable, sizeof(DWORD)); RegCloseKey(key); } else @@ -571,7 +490,7 @@ static HRESULT WINAPI InputProcessorProfiles_IsEnabledLanguageProfile( if (!res) { DWORD count = sizeof(DWORD); - res = RegQueryValueExW(key, szwEnable, 0, NULL, (LPBYTE)pfEnable, &count); + res = RegQueryValueExW(key, szwEnabled, 0, NULL, (LPBYTE)pfEnable, &count); RegCloseKey(key); } @@ -582,7 +501,7 @@ static HRESULT WINAPI InputProcessorProfiles_IsEnabledLanguageProfile( if (!res) { DWORD count = sizeof(DWORD); - res = RegQueryValueExW(key, szwEnable, 0, NULL, (LPBYTE)pfEnable, &count); + res = RegQueryValueExW(key, szwEnabled, 0, NULL, (LPBYTE)pfEnable, &count); RegCloseKey(key); } } @@ -614,7 +533,7 @@ static HRESULT WINAPI InputProcessorProfiles_EnableLanguageProfileByDefault( if (!res) { - RegSetValueExW(key, szwEnable, 0, REG_DWORD, (LPBYTE)&fEnable, sizeof(DWORD)); + RegSetValueExW(key, szwEnabled, 0, REG_DWORD, (LPBYTE)&fEnable, sizeof(DWORD)); RegCloseKey(key); } else diff --git a/dlls/msctf/msctf.c b/dlls/msctf/msctf.c index 82772787e41..9729ef3952c 100644 --- a/dlls/msctf/msctf.c +++ b/dlls/msctf/msctf.c @@ -33,6 +33,7 @@ #include "shlwapi.h" #include "shlguid.h" #include "comcat.h" +#include "initguid.h" #include "msctf.h" #include "msctf_internal.h" @@ -76,7 +77,6 @@ TfClientId processId = 0; ITfCompartmentMgr *globalCompartmentMgr = NULL; const WCHAR szwSystemTIPKey[] = {'S','O','F','T','W','A','R','E','\\','M','i','c','r','o','s','o','f','t','\\','C','T','F','\\','T','I','P',0}; -const WCHAR szwSystemCTFKey[] = {'S','O','F','T','W','A','R','E','\\','M','i','c','r','o','s','o','f','t','\\','C','T','F',0}; typedef HRESULT (*LPFNCONSTRUCTOR)(IUnknown *pUnkOuter, IUnknown **ppvOut); @@ -599,12 +599,3 @@ HRESULT WINAPI SetInputScopes(HWND hwnd, const INT *pInputScopes, return S_OK; } - -/*********************************************************************** - * TF_CreateInputProcessorProfiles(MSCTF.@) - */ -HRESULT WINAPI TF_CreateInputProcessorProfiles( - ITfInputProcessorProfiles **ppipr) -{ - return InputProcessorProfiles_Constructor(NULL,(IUnknown**)ppipr); -} diff --git a/dlls/msctf/msctf.spec b/dlls/msctf/msctf.spec index f7c35a3a64a..1c8bb37a1b4 100644 --- a/dlls/msctf/msctf.spec +++ b/dlls/msctf/msctf.spec @@ -11,7 +11,7 @@ @ stub TF_CreateCategoryMgr @ stub TF_CreateCicLoadMutex @ stub TF_CreateDisplayAttributeMgr -@ stdcall TF_CreateInputProcessorProfiles(ptr) +@ stub TF_CreateInputProcessorProfiles @ stub TF_CreateLangBarItemMgr @ stub TF_CreateLangBarMgr @ stdcall TF_CreateThreadMgr(ptr) diff --git a/dlls/msctf/msctf_internal.h b/dlls/msctf/msctf_internal.h index 3bb0baa6ee7..d2b1a2e182e 100644 --- a/dlls/msctf/msctf_internal.h +++ b/dlls/msctf/msctf_internal.h @@ -26,7 +26,6 @@ #define COOKIE_MAGIC_GUIDATOM 0x0030 #define COOKIE_MAGIC_IPPSINK 0x0040 #define COOKIE_MAGIC_EDITCOOKIE 0x0050 -#define COOKIE_MAGIC_COMPARTMENTSINK 0x0060 extern DWORD tlsIndex; extern TfClientId processId; @@ -43,7 +42,6 @@ extern HRESULT CompartmentMgr_Destructor(ITfCompartmentMgr *This); extern HRESULT Context_Initialize(ITfContext *cxt, ITfDocumentMgr *manager); extern HRESULT Context_Uninitialize(ITfContext *cxt); -extern void ThreadMgr_OnDocumentMgrDestruction(ITfThreadMgr *tm, ITfDocumentMgr *mgr); extern HRESULT TF_SELECTION_to_TS_SELECTION_ACP(const TF_SELECTION *tf, TS_SELECTION_ACP *tsAcp); /* cookie function */ @@ -64,5 +62,4 @@ extern HRESULT get_textservice_sink(TfClientId tid, REFCLSID iid, IUnknown** sin extern HRESULT set_textservice_sink(TfClientId tid, REFCLSID iid, IUnknown* sink); extern const WCHAR szwSystemTIPKey[]; -extern const WCHAR szwSystemCTFKey[]; #endif /* __WINE_MSCTF_I_H */ diff --git a/dlls/msctf/tests/inputprocessor.c b/dlls/msctf/tests/inputprocessor.c index d35d3917d8d..67d53c61b1b 100644 --- a/dlls/msctf/tests/inputprocessor.c +++ b/dlls/msctf/tests/inputprocessor.c @@ -439,20 +439,6 @@ ITfDocumentMgr *pdimFocus, ITfDocumentMgr *pdimPrevFocus) static HRESULT WINAPI ThreadMgrEventSink_OnPushContext(ITfThreadMgrEventSink *iface, ITfContext *pic) { - HRESULT hr; - ITfDocumentMgr *docmgr; - ITfContext *test; - - hr = ITfContext_GetDocumentMgr(pic,&docmgr); - ok(SUCCEEDED(hr),"GetDocumenMgr failed\n"); - test = (ITfContext*)0xdeadbeef; - ITfDocumentMgr_Release(docmgr); - hr = ITfDocumentMgr_GetTop(docmgr,&test); - ok(SUCCEEDED(hr),"GetTop failed\n"); - ok(test == pic, "Wrong context is on top\n"); - if (test) - ITfContext_Release(test); - ok(test_OnPushContext == SINK_EXPECTED, "Unexpected OnPushContext sink\n"); test_OnPushContext = SINK_FIRED; return S_OK; @@ -461,20 +447,6 @@ ITfContext *pic) static HRESULT WINAPI ThreadMgrEventSink_OnPopContext(ITfThreadMgrEventSink *iface, ITfContext *pic) { - HRESULT hr; - ITfDocumentMgr *docmgr; - ITfContext *test; - - hr = ITfContext_GetDocumentMgr(pic,&docmgr); - ok(SUCCEEDED(hr),"GetDocumenMgr failed\n"); - ITfDocumentMgr_Release(docmgr); - test = (ITfContext*)0xdeadbeef; - hr = ITfDocumentMgr_GetTop(docmgr,&test); - ok(SUCCEEDED(hr),"GetTop failed\n"); - ok(test == pic, "Wrong context is on top\n"); - if (test) - ITfContext_Release(test); - ok(test_OnPopContext == SINK_EXPECTED, "Unexpected OnPopContext sink\n"); test_OnPopContext = SINK_FIRED; return S_OK; @@ -722,15 +694,7 @@ DEFINE_GUID (GUID_TFCAT_DISPLAYATTRIBUTEPROVIDER, 0x046B8C80,0x1647,0x40F7,0x9B DEFINE_GUID(GUID_NULL,0,0,0,0,0,0,0,0,0,0,0); DEFINE_GUID(CLSID_TF_ThreadMgr, 0x529a9e6b,0x6587,0x4f23,0xab,0x9e,0x9c,0x7d,0x68,0x3e,0x3c,0x50); DEFINE_GUID(CLSID_PreservedKey, 0xA0ED8E55,0xCD3B,0x4274,0xB2,0x95,0xF6,0xC9,0xBA,0x2B,0x84,0x72); -DEFINE_GUID(GUID_COMPARTMENT_KEYBOARD_DISABLED, 0x71a5b253,0x1951,0x466b,0x9f,0xbc,0x9c,0x88,0x08,0xfa,0x84,0xf2); -DEFINE_GUID(GUID_COMPARTMENT_KEYBOARD_OPENCLOSE, 0x58273aad,0x01bb,0x4164,0x95,0xc6,0x75,0x5b,0xa0,0xb5,0x16,0x2d); -DEFINE_GUID(GUID_COMPARTMENT_HANDWRITING_OPENCLOSE, 0xf9ae2c6b,0x1866,0x4361,0xaf,0x72,0x7a,0xa3,0x09,0x48,0x89,0x0e); -DEFINE_GUID(GUID_COMPARTMENT_SPEECH_DISABLED, 0x56c5c607,0x0703,0x4e59,0x8e,0x52,0xcb,0xc8,0x4e,0x8b,0xbe,0x35); -DEFINE_GUID(GUID_COMPARTMENT_SPEECH_OPENCLOSE, 0x544d6a63,0xe2e8,0x4752,0xbb,0xd1,0x00,0x09,0x60,0xbc,0xa0,0x83); -DEFINE_GUID(GUID_COMPARTMENT_SPEECH_GLOBALSTATE, 0x2a54fe8e,0x0d08,0x460c,0xa7,0x5d,0x87,0x03,0x5f,0xf4,0x36,0xc5); -DEFINE_GUID(GUID_COMPARTMENT_PERSISTMENUENABLED, 0x575f3783,0x70c8,0x47c8,0xae,0x5d,0x91,0xa0,0x1a,0x1f,0x75,0x92); -DEFINE_GUID(GUID_COMPARTMENT_EMPTYCONTEXT, 0xd7487dbf,0x804e,0x41c5,0x89,0x4d,0xad,0x96,0xfd,0x4e,0xea,0x13); -DEFINE_GUID(GUID_COMPARTMENT_TIPUISTATUS, 0x148ca3ec,0x0366,0x401c,0x8d,0x75,0xed,0x97,0x8d,0x85,0xfb,0xc9); + static HRESULT initialize(void) { @@ -1113,68 +1077,6 @@ static void test_Activate(void) ok(SUCCEEDED(hr),"Failed to Activate text service\n"); } - -static void test_EnumContexts(ITfDocumentMgr *dm, ITfContext *search) -{ - HRESULT hr; - IEnumTfContexts* pEnum; - BOOL found = FALSE; - - hr = ITfDocumentMgr_EnumContexts(dm,&pEnum); - ok(SUCCEEDED(hr),"EnumContexts failed\n"); - if (SUCCEEDED(hr)) - { - ULONG fetched; - ITfContext *cxt; - while (IEnumTfContexts_Next(pEnum, 1, &cxt, &fetched) == S_OK) - { - if (!search) - found = TRUE; - else if (search == cxt) - found = TRUE; - ITfContext_Release(cxt); - } - IEnumTfContexts_Release(pEnum); - } - if (search) - ok(found,"Did not find proper ITfContext\n"); - else - ok(!found,"Found an ITfContext we should should not have\n"); -} - -static void test_EnumDocumentMgr(ITfThreadMgr *tm, ITfDocumentMgr *search, ITfDocumentMgr *absent) -{ - HRESULT hr; - IEnumTfDocumentMgrs* pEnum; - BOOL found = FALSE; - BOOL notfound = TRUE; - - hr = ITfThreadMgr_EnumDocumentMgrs(tm,&pEnum); - ok(SUCCEEDED(hr),"EnumDocumentMgrs failed\n"); - if (SUCCEEDED(hr)) - { - ULONG fetched; - ITfDocumentMgr *dm; - while (IEnumTfDocumentMgrs_Next(pEnum, 1, &dm, &fetched) == S_OK) - { - if (!search) - found = TRUE; - else if (search == dm) - found = TRUE; - if (absent && dm == absent) - notfound = FALSE; - ITfDocumentMgr_Release(dm); - } - IEnumTfDocumentMgrs_Release(pEnum); - } - if (search) - ok(found,"Did not find proper ITfDocumentMgr\n"); - else - ok(!found,"Found an ITfDocumentMgr we should should not have\n"); - if (absent) - ok(notfound,"Found an ITfDocumentMgr we believe should be absent\n"); -} - static inline int check_context_refcount(ITfContext *iface) { IUnknown_AddRef(iface); @@ -1207,21 +1109,9 @@ static void test_startSession(void) hr = ITfThreadMgr_Deactivate(g_tm); ok(SUCCEEDED(hr),"Failed to Deactivate\n"); - test_EnumDocumentMgr(g_tm,NULL,NULL); - hr = ITfThreadMgr_CreateDocumentMgr(g_tm,&g_dm); ok(SUCCEEDED(hr),"CreateDocumentMgr failed\n"); - test_EnumDocumentMgr(g_tm,g_dm,NULL); - - hr = ITfThreadMgr_CreateDocumentMgr(g_tm,&dmtest); - ok(SUCCEEDED(hr),"CreateDocumentMgr failed\n"); - - test_EnumDocumentMgr(g_tm,dmtest,NULL); - - ITfDocumentMgr_Release(dmtest); - test_EnumDocumentMgr(g_tm,g_dm,dmtest); - hr = ITfThreadMgr_GetFocus(g_tm,&dmtest); ok(SUCCEEDED(hr),"GetFocus Failed\n"); ok(dmtest == NULL,"Initial focus not null\n"); @@ -1244,7 +1134,6 @@ static void test_startSession(void) hr = ITfThreadMgr_GetFocus(g_tm,&dmtest); ok(SUCCEEDED(hr),"GetFocus Failed\n"); ok(g_dm == dmtest,"Expected DocumentMgr not focused\n"); - ITfDocumentMgr_Release(dmtest); TextStoreACP_Constructor((IUnknown**)&ts); @@ -1257,8 +1146,6 @@ static void test_startSession(void) hr = ITfDocumentMgr_CreateContext(g_dm, cid, 0, NULL, &cxt3, &editCookie); ok(SUCCEEDED(hr),"CreateContext Failed\n"); - test_EnumContexts(g_dm, NULL); - hr = ITfContext_GetDocumentMgr(cxt,&dmtest); ok(hr == S_OK, "ITfContext_GetDocumentMgr failed with %x\n",hr); ok(dmtest == g_dm, "Wrong documentmgr\n"); @@ -1275,8 +1162,6 @@ static void test_startSession(void) ok(test_OnInitDocumentMgr == SINK_FIRED, "OnInitDocumentMgr sink not fired\n"); ok(test_ACP_AdviseSink == SINK_FIRED,"TextStoreACP_AdviseSink not fired\n"); - test_EnumContexts(g_dm, cxt); - hr = ITfDocumentMgr_GetTop(g_dm, &cxtTest); ok(SUCCEEDED(hr),"GetTop Failed\n"); ok(cxtTest == cxt, "Wrong context on top\n"); @@ -1428,7 +1313,7 @@ static void test_ClientId(void) GUID g2; hr = ITfThreadMgr_QueryInterface(g_tm, &IID_ITfClientId, (LPVOID*)&pcid); - ok(SUCCEEDED(hr),"Unable to acquire ITfClientId interface\n"); + ok(SUCCEEDED(hr),"Unable to aquire ITfClientId interface\n"); CoCreateGuid(&g2); @@ -1667,86 +1552,6 @@ static void test_TStoApplicationText(void) ITfEditSession_Release(es); } -static void enum_compartments(ITfCompartmentMgr *cmpmgr, REFGUID present, REFGUID absent) -{ - BOOL found,found2; - IEnumGUID *ppEnum; - found = FALSE; - found2 = FALSE; - if (SUCCEEDED(ITfCompartmentMgr_EnumCompartments(cmpmgr, &ppEnum))) - { - ULONG fetched; - GUID g; - while (IEnumGUID_Next(ppEnum, 1, &g, &fetched) == S_OK) - { - WCHAR str[50]; - CHAR strA[50]; - StringFromGUID2(&g,str,50); - WideCharToMultiByte(CP_ACP,0,str,50,strA,50,0,0); - trace("found %s\n",strA); - if (present && IsEqualGUID(present,&g)) - found = TRUE; - if (absent && IsEqualGUID(absent, &g)) - found2 = TRUE; - } - IEnumGUID_Release(ppEnum); - } - if (present) - ok(found,"Did not find compartment\n"); - if (absent) - ok(!found2,"Found compartment that should be absent\n"); -} - -static void test_Compartments(void) -{ - ITfContext *cxt; - ITfDocumentMgr *dm; - ITfCompartmentMgr *cmpmgr; - ITfCompartment *cmp; - HRESULT hr; - - ITfThreadMgr_GetFocus(g_tm, &dm); - ITfDocumentMgr_GetTop(dm,&cxt); - - /* Global */ - hr = ITfThreadMgr_GetGlobalCompartment(g_tm, &cmpmgr); - ok(SUCCEEDED(hr),"GetGlobalCompartment failed\n"); - hr = ITfCompartmentMgr_GetCompartment(cmpmgr, &GUID_COMPARTMENT_SPEECH_OPENCLOSE, &cmp); - ok(SUCCEEDED(hr),"GetCompartment failed\n"); - ITfCompartment_Release(cmp); - enum_compartments(cmpmgr,&GUID_COMPARTMENT_SPEECH_OPENCLOSE,NULL); - ITfCompartmentMgr_Release(cmpmgr); - - /* Thread */ - hr = ITfThreadMgr_QueryInterface(g_tm, &IID_ITfCompartmentMgr, (LPVOID*)&cmpmgr); - ok(SUCCEEDED(hr),"ThreadMgr QI for IID_ITfCompartmentMgr failed\n"); - hr = ITfCompartmentMgr_GetCompartment(cmpmgr, &CLSID_FakeService, &cmp); - ok(SUCCEEDED(hr),"GetCompartment failed\n"); - enum_compartments(cmpmgr,&CLSID_FakeService,&GUID_COMPARTMENT_SPEECH_OPENCLOSE); - ITfCompartmentMgr_ClearCompartment(cmpmgr,tid,&CLSID_FakeService); - enum_compartments(cmpmgr,NULL,&CLSID_FakeService); - ITfCompartmentMgr_Release(cmpmgr); - ITfCompartment_Release(cmp); - - /* DocumentMgr */ - hr = ITfDocumentMgr_QueryInterface(dm, &IID_ITfCompartmentMgr, (LPVOID*)&cmpmgr); - ok(SUCCEEDED(hr),"DocumentMgr QI for IID_ITfCompartmentMgr failed\n"); - - hr = ITfCompartmentMgr_GetCompartment(cmpmgr, &GUID_COMPARTMENT_PERSISTMENUENABLED, &cmp); - ok(SUCCEEDED(hr),"GetCompartment failed\n"); - enum_compartments(cmpmgr,&GUID_COMPARTMENT_PERSISTMENUENABLED,&GUID_COMPARTMENT_SPEECH_OPENCLOSE); - ITfCompartmentMgr_Release(cmpmgr); - - /* Context */ - hr = ITfContext_QueryInterface(cxt, &IID_ITfCompartmentMgr, (LPVOID*)&cmpmgr); - ok(SUCCEEDED(hr),"Context QI for IID_ITfCompartmentMgr failed\n"); - enum_compartments(cmpmgr,NULL,&GUID_COMPARTMENT_PERSISTMENUENABLED); - ITfCompartmentMgr_Release(cmpmgr); - - ITfContext_Release(cxt); - ITfDocumentMgr_Release(dm); -} - START_TEST(inputprocessor) { if (SUCCEEDED(initialize())) @@ -1762,7 +1567,6 @@ START_TEST(inputprocessor) test_ClientId(); test_KeystrokeMgr(); test_TStoApplicationText(); - test_Compartments(); test_endSession(); test_EnumLanguageProfiles(); test_FindClosestCategory(); diff --git a/dlls/msctf/threadmgr.c b/dlls/msctf/threadmgr.c index 9fb1b5d42e7..b10910709bc 100644 --- a/dlls/msctf/threadmgr.c +++ b/dlls/msctf/threadmgr.c @@ -65,12 +65,6 @@ typedef struct tagPreservedKey TfClientId tid; } PreservedKey; -typedef struct tagDocumentMgrs -{ - struct list entry; - ITfDocumentMgr *docmgr; -} DocumentMgrEntry; - typedef struct tagACLMulti { const ITfThreadMgrVtbl *ThreadMgrVtbl; const ITfSourceVtbl *SourceVtbl; @@ -96,7 +90,6 @@ typedef struct tagACLMulti { CLSID forgroundTextService; struct list CurrentPreservedKeys; - struct list CreatedDocumentMgrs; /* kept as separate lists to reduce unnecessary iterations */ struct list ActiveLanguageProfileNotifySink; @@ -107,16 +100,6 @@ typedef struct tagACLMulti { struct list ThreadMgrEventSink; } ThreadMgr; -typedef struct tagEnumTfDocumentMgr { - const IEnumTfDocumentMgrsVtbl *Vtbl; - LONG refCount; - - struct list *index; - struct list *head; -} EnumTfDocumentMgr; - -static HRESULT EnumTfDocumentMgr_Constructor(struct list* head, IEnumTfDocumentMgrs **ppOut); - static inline ThreadMgr *impl_from_ITfSourceVtbl(ITfSource *iface) { return (ThreadMgr *)((char *)iface - FIELD_OFFSET(ThreadMgr,SourceVtbl)); @@ -203,14 +186,6 @@ static void ThreadMgr_Destructor(ThreadMgr *This) HeapFree(GetProcessHeap(),0,key); } - LIST_FOR_EACH_SAFE(cursor, cursor2, &This->CreatedDocumentMgrs) - { - DocumentMgrEntry *mgr = LIST_ENTRY(cursor,DocumentMgrEntry,entry); - list_remove(cursor); - FIXME("Left Over ITfDocumentMgr. Should we do something with it?\n"); - HeapFree(GetProcessHeap(),0,mgr); - } - CompartmentMgr_Destructor(This->CompartmentMgr); HeapFree(GetProcessHeap(),0,This); @@ -328,37 +303,16 @@ static HRESULT WINAPI ThreadMgr_CreateDocumentMgr( ITfThreadMgr* iface, ITfDocum **ppdim) { ThreadMgr *This = (ThreadMgr *)iface; - DocumentMgrEntry *mgrentry; - HRESULT hr; - TRACE("(%p)\n",iface); - mgrentry = HeapAlloc(GetProcessHeap(),0,sizeof(DocumentMgrEntry)); - if (mgrentry == NULL) - return E_OUTOFMEMORY; - - hr = DocumentMgr_Constructor((ITfThreadMgrEventSink*)&This->ThreadMgrEventSinkVtbl, ppdim); - - if (SUCCEEDED(hr)) - { - mgrentry->docmgr = *ppdim; - list_add_head(&This->CreatedDocumentMgrs,&mgrentry->entry); - } - else - HeapFree(GetProcessHeap(),0,mgrentry); - - return hr; + return DocumentMgr_Constructor((ITfThreadMgrEventSink*)&This->ThreadMgrEventSinkVtbl, ppdim); } static HRESULT WINAPI ThreadMgr_EnumDocumentMgrs( ITfThreadMgr* iface, IEnumTfDocumentMgrs **ppEnum) { ThreadMgr *This = (ThreadMgr *)iface; - TRACE("(%p) %p\n",This,ppEnum); - - if (!ppEnum) - return E_INVALIDARG; - - return EnumTfDocumentMgr_Constructor(&This->CreatedDocumentMgrs, ppEnum); + FIXME("STUB:(%p)\n",This); + return E_NOTIMPL; } static HRESULT WINAPI ThreadMgr_GetFocus( ITfThreadMgr* iface, ITfDocumentMgr @@ -1129,7 +1083,6 @@ HRESULT ThreadMgr_Constructor(IUnknown *pUnkOuter, IUnknown **ppOut) CompartmentMgr_Constructor((IUnknown*)This, &IID_IUnknown, (IUnknown**)&This->CompartmentMgr); list_init(&This->CurrentPreservedKeys); - list_init(&This->CreatedDocumentMgrs); list_init(&This->ActiveLanguageProfileNotifySink); list_init(&This->DisplayAttributeNotifySink); @@ -1142,164 +1095,3 @@ HRESULT ThreadMgr_Constructor(IUnknown *pUnkOuter, IUnknown **ppOut) *ppOut = (IUnknown *)This; return S_OK; } - -/************************************************** - * IEnumTfDocumentMgrs implementaion - **************************************************/ -static void EnumTfDocumentMgr_Destructor(EnumTfDocumentMgr *This) -{ - TRACE("destroying %p\n", This); - HeapFree(GetProcessHeap(),0,This); -} - -static HRESULT WINAPI EnumTfDocumentMgr_QueryInterface(IEnumTfDocumentMgrs *iface, REFIID iid, LPVOID *ppvOut) -{ - EnumTfDocumentMgr *This = (EnumTfDocumentMgr *)iface; - *ppvOut = NULL; - - if (IsEqualIID(iid, &IID_IUnknown) || IsEqualIID(iid, &IID_IEnumTfDocumentMgrs)) - { - *ppvOut = This; - } - - if (*ppvOut) - { - IUnknown_AddRef(iface); - return S_OK; - } - - WARN("unsupported interface: %s\n", debugstr_guid(iid)); - return E_NOINTERFACE; -} - -static ULONG WINAPI EnumTfDocumentMgr_AddRef(IEnumTfDocumentMgrs *iface) -{ - EnumTfDocumentMgr *This = (EnumTfDocumentMgr*)iface; - return InterlockedIncrement(&This->refCount); -} - -static ULONG WINAPI EnumTfDocumentMgr_Release(IEnumTfDocumentMgrs *iface) -{ - EnumTfDocumentMgr *This = (EnumTfDocumentMgr *)iface; - ULONG ret; - - ret = InterlockedDecrement(&This->refCount); - if (ret == 0) - EnumTfDocumentMgr_Destructor(This); - return ret; -} - -static HRESULT WINAPI EnumTfDocumentMgr_Next(IEnumTfDocumentMgrs *iface, - ULONG ulCount, ITfDocumentMgr **rgDocumentMgr, ULONG *pcFetched) -{ - EnumTfDocumentMgr *This = (EnumTfDocumentMgr *)iface; - ULONG fetched = 0; - - TRACE("(%p)\n",This); - - if (rgDocumentMgr == NULL) return E_POINTER; - - while (fetched < ulCount) - { - DocumentMgrEntry *mgrentry; - if (This->index == NULL) - break; - - mgrentry = LIST_ENTRY(This->index,DocumentMgrEntry,entry); - if (mgrentry == NULL) - break; - - *rgDocumentMgr = mgrentry->docmgr; - ITfDocumentMgr_AddRef(*rgDocumentMgr); - - This->index = list_next(This->head, This->index); - ++fetched; - ++rgDocumentMgr; - } - - if (pcFetched) *pcFetched = fetched; - return fetched == ulCount ? S_OK : S_FALSE; -} - -static HRESULT WINAPI EnumTfDocumentMgr_Skip( IEnumTfDocumentMgrs* iface, ULONG celt) -{ - INT i; - EnumTfDocumentMgr *This = (EnumTfDocumentMgr *)iface; - TRACE("(%p)\n",This); - for(i = 0; i < celt && This->index != NULL; i++) - This->index = list_next(This->head, This->index); - return S_OK; -} - -static HRESULT WINAPI EnumTfDocumentMgr_Reset( IEnumTfDocumentMgrs* iface) -{ - EnumTfDocumentMgr *This = (EnumTfDocumentMgr *)iface; - TRACE("(%p)\n",This); - This->index = list_head(This->head); - return S_OK; -} - -static HRESULT WINAPI EnumTfDocumentMgr_Clone( IEnumTfDocumentMgrs *iface, - IEnumTfDocumentMgrs **ppenum) -{ - EnumTfDocumentMgr *This = (EnumTfDocumentMgr *)iface; - HRESULT res; - - TRACE("(%p)\n",This); - - if (ppenum == NULL) return E_POINTER; - - res = EnumTfDocumentMgr_Constructor(This->head, ppenum); - if (SUCCEEDED(res)) - { - EnumTfDocumentMgr *new_This = (EnumTfDocumentMgr *)*ppenum; - new_This->index = This->index; - } - return res; -} - -static const IEnumTfDocumentMgrsVtbl IEnumTfDocumentMgrs_Vtbl ={ - EnumTfDocumentMgr_QueryInterface, - EnumTfDocumentMgr_AddRef, - EnumTfDocumentMgr_Release, - - EnumTfDocumentMgr_Clone, - EnumTfDocumentMgr_Next, - EnumTfDocumentMgr_Reset, - EnumTfDocumentMgr_Skip -}; - -static HRESULT EnumTfDocumentMgr_Constructor(struct list* head, IEnumTfDocumentMgrs **ppOut) -{ - EnumTfDocumentMgr *This; - - This = HeapAlloc(GetProcessHeap(),HEAP_ZERO_MEMORY,sizeof(EnumTfDocumentMgr)); - if (This == NULL) - return E_OUTOFMEMORY; - - This->Vtbl= &IEnumTfDocumentMgrs_Vtbl; - This->refCount = 1; - This->head = head; - This->index = list_head(This->head); - - TRACE("returning %p\n", This); - *ppOut = (IEnumTfDocumentMgrs*)This; - return S_OK; -} - -void ThreadMgr_OnDocumentMgrDestruction(ITfThreadMgr *tm, ITfDocumentMgr *mgr) -{ - ThreadMgr *This = (ThreadMgr *)tm; - struct list *cursor; - LIST_FOR_EACH(cursor, &This->CreatedDocumentMgrs) - { - DocumentMgrEntry *mgrentry = LIST_ENTRY(cursor,DocumentMgrEntry,entry); - if (mgrentry->docmgr == mgr) - { - list_remove(cursor); - HeapFree(GetProcessHeap(),0,mgrentry); - return; - } - } - FIXME("ITfDocumenMgr %p not found in this thread\n",mgr); -} diff --git a/dlls/msdmo/rsrc.rc b/dlls/msdmo/rsrc.rc index a313b9791fc..d87fbadd152 100644 --- a/dlls/msdmo/rsrc.rc +++ b/dlls/msdmo/rsrc.rc @@ -1,5 +1,5 @@ /* - * Copyright 2003 Michael Günnewig + * Copyright 2003 Michael Günnewig * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public diff --git a/dlls/mshtml/Bg.rc b/dlls/mshtml/Bg.rc index a8fd605ab09..92c86b6ba4f 100644 --- a/dlls/mshtml/Bg.rc +++ b/dlls/mshtml/Bg.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT diff --git a/dlls/mshtml/Da.rc b/dlls/mshtml/Da.rc index 574ea093afe..47579b5a4d8 100644 --- a/dlls/mshtml/Da.rc +++ b/dlls/mshtml/Da.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_DANISH, SUBLANG_DEFAULT diff --git a/dlls/mshtml/De.rc b/dlls/mshtml/De.rc index e1963ecd947..991e84d28fd 100644 --- a/dlls/mshtml/De.rc +++ b/dlls/mshtml/De.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL @@ -70,3 +69,5 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "OK", IDOK, 40, 65, 45, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Abbrechen", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP } + +#pragma code_page(default) diff --git a/dlls/mshtml/En.rc b/dlls/mshtml/En.rc index 41ee1197050..09370deb353 100644 --- a/dlls/mshtml/En.rc +++ b/dlls/mshtml/En.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT diff --git a/dlls/mshtml/Es.rc b/dlls/mshtml/Es.rc index fb79f87852c..94af0cfaf5c 100644 --- a/dlls/mshtml/Es.rc +++ b/dlls/mshtml/Es.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL diff --git a/dlls/mshtml/Fi.rc b/dlls/mshtml/Fi.rc index 564345d6960..d1d389a8ba5 100644 --- a/dlls/mshtml/Fi.rc +++ b/dlls/mshtml/Fi.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT diff --git a/dlls/mshtml/Fr.rc b/dlls/mshtml/Fr.rc index c7671d4aed4..507d0c2ba32 100644 --- a/dlls/mshtml/Fr.rc +++ b/dlls/mshtml/Fr.rc @@ -19,18 +19,14 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { - IDS_HTMLDISABLED "Le rendu HTML est actuellement désactivé." + IDS_HTMLDISABLED "Le rendu HTML est actuellement désactivé." IDS_HTMLDOCUMENT "Document HTML" - IDS_DOWNLOADING "Téléchargement..." + IDS_DOWNLOADING "Téléchargement..." IDS_INSTALLING "Installation..." } @@ -39,9 +35,9 @@ STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMEN CAPTION "Programme d'installation de Gecko pour Wine" FONT 8, "MS Shell Dlg" { - LTEXT "Cette application essaie d'afficher une page HTML. Wine requiert la présence du moteur de rendu Gecko de Mozilla " \ + LTEXT "Cette application essaie d'afficher une page HTML. Wine requiert la présence du moteur de rendu Gecko de Mozilla " \ "pour afficher cette page. Cliquez sur Installer si vous souhaitez que Wine " \ - "télécharge et installe automatiquement Gecko.", ID_DWL_STATUS, 10, 10, 240, 40, SS_LEFT + "télécharge et installe automatiquement Gecko.", ID_DWL_STATUS, 10, 10, 240, 40, SS_LEFT CONTROL "Progression", ID_DWL_PROGRESS, PROGRESS_CLASSA, WS_BORDER|PBS_SMOOTH, 10, 50, 240, 12 DEFPUSHBUTTON "&Installer", ID_DWL_INSTALL, 200, 70, 50, 15, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Annuler", IDCANCEL, 140, 70, 50, 15, WS_GROUP | WS_TABSTOP @@ -53,9 +49,9 @@ CAPTION "Hyperlien" FONT 8, "MS Shell Dlg" { GROUPBOX "Informations sur l'hyperlien", -1, 5, 5, 190, 55 - LTEXT "&Type :", -1, 10, 22, 20, 10 + LTEXT "&Type :", -1, 10, 22, 20, 10 COMBOBOX IDC_TYPE, 35, 20, 45, 100, WS_TABSTOP | WS_GROUP | WS_VSCROLL | CBS_DROPDOWNLIST | CBS_HASSTRINGS - LTEXT "&URL :", -1, 10, 42, 20, 10 + LTEXT "&URL :", -1, 10, 42, 20, 10 EDITTEXT IDC_URL, 35, 40, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP PUSHBUTTON "OK", IDOK, 200, 10, 45, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Annuler", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP diff --git a/dlls/mshtml/Hu.rc b/dlls/mshtml/Hu.rc index 137a1007198..7f3d25446ad 100644 --- a/dlls/mshtml/Hu.rc +++ b/dlls/mshtml/Hu.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT diff --git a/dlls/mshtml/Ja.rc b/dlls/mshtml/Ja.rc index 202bd43164c..81bf8f8eff2 100644 --- a/dlls/mshtml/Ja.rc +++ b/dlls/mshtml/Ja.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -58,13 +56,4 @@ FONT 9, "MS Shell Dlg" PUSHBUTTON "キャンセル", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP } -ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 -STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", ID_PROMPT_PROMPT, 10, 10, 180, 30 - EDITTEXT ID_PROMPT_EDIT, 10, 45, 180, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - PUSHBUTTON "OK", IDOK, 40, 65, 45, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "キャンセル", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP -} +#pragma code_page(default) diff --git a/dlls/mshtml/Ko.rc b/dlls/mshtml/Ko.rc index 01456e39d0d..efad0075a87 100644 --- a/dlls/mshtml/Ko.rc +++ b/dlls/mshtml/Ko.rc @@ -17,7 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT diff --git a/dlls/mshtml/Lt.rc b/dlls/mshtml/Lt.rc index 26167a9adc1..f63b177746d 100644 --- a/dlls/mshtml/Lt.rc +++ b/dlls/mshtml/Lt.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -68,3 +66,5 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "Gerai", IDOK, 40, 65, 45, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Atsisakyti", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP } + +#pragma code_page(default) diff --git a/dlls/mshtml/Makefile.in b/dlls/mshtml/Makefile.in index acda821c057..241ec9d22ed 100644 --- a/dlls/mshtml/Makefile.in +++ b/dlls/mshtml/Makefile.in @@ -65,29 +65,7 @@ C_SRCS = \ txtrange.c \ view.c -RC_SRCS = \ - Bg.rc \ - Da.rc \ - De.rc \ - En.rc \ - Es.rc \ - Fi.rc \ - Fr.rc \ - Hu.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ro.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc \ - rsrc.rc +RC_SRCS = rsrc.rc IDL_H_SRCS = nsiface.idl diff --git a/dlls/mshtml/Nl.rc b/dlls/mshtml/Nl.rc index 1aab09c79d6..f6f47e174b3 100644 --- a/dlls/mshtml/Nl.rc +++ b/dlls/mshtml/Nl.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL diff --git a/dlls/mshtml/No.rc b/dlls/mshtml/No.rc index 4e24ece4a6f..6060a515365 100644 --- a/dlls/mshtml/No.rc +++ b/dlls/mshtml/No.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL diff --git a/dlls/mshtml/Pl.rc b/dlls/mshtml/Pl.rc index 11659ee2297..a17768651ef 100644 --- a/dlls/mshtml/Pl.rc +++ b/dlls/mshtml/Pl.rc @@ -17,7 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_POLISH, SUBLANG_DEFAULT diff --git a/dlls/mshtml/Pt.rc b/dlls/mshtml/Pt.rc index d9ebbb3126a..0a83ee06a41 100644 --- a/dlls/mshtml/Pt.rc +++ b/dlls/mshtml/Pt.rc @@ -16,18 +16,15 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE +LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { - IDS_HTMLDISABLED "A interpretação de HTML está desactivada." + IDS_HTMLDISABLED "A interpretação de HTML está desactivada." IDS_HTMLDOCUMENT "Documento HTML" - IDS_DOWNLOADING "A descarregar..." - IDS_INSTALLING "A instalar..." + IDS_DOWNLOADING "Descarregando..." + IDS_INSTALLING "Instalando..." } ID_DWL_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 0, 0, 260, 95 @@ -35,8 +32,8 @@ STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMEN CAPTION "Instalador Wine Gecko" FONT 8, "MS Shell Dlg" { - LTEXT "Esta aplicação está a tentar mostrar uma página HTML. O Wine precisa que o Gecko " \ - "(Motor HTML Mozilla) seja instalado para mostrar a página. Clique em Instalar se deseja que o Wine " \ + LTEXT "Esta aplicação está a tentar mostrar uma página HTML. O Wine precisa que o Gecko " \ + "(Motor HTML Mozilla) seja instalado para mostrar a página. Clique em Instalar se deseja que o Wine " \ "descarregue e instale o Gecko automaticamente.", ID_DWL_STATUS, 10, 10, 240, 40, SS_LEFT CONTROL "Progresso", ID_DWL_PROGRESS, PROGRESS_CLASSA, WS_BORDER|PBS_SMOOTH, 10, 50, 240, 12 DEFPUSHBUTTON "&Instalar", ID_DWL_INSTALL, 200, 70, 50, 15, WS_GROUP | WS_TABSTOP @@ -45,10 +42,10 @@ FONT 8, "MS Shell Dlg" IDD_HYPERLINK DIALOG LOADONCALL MOVEABLE DISCARDABLE 0, 0, 250, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Hiperligação" +CAPTION "Hiperligação" FONT 8, "MS Shell Dlg" { - GROUPBOX "Informação da Hiperligação", -1, 5, 5, 190, 55 + GROUPBOX "Informação da Hiperligação", -1, 5, 5, 190, 55 LTEXT "&Tipo:", -1, 10, 22, 20, 10 COMBOBOX IDC_TYPE, 35, 20, 45, 100, WS_TABSTOP | WS_GROUP | WS_VSCROLL | CBS_DROPDOWNLIST | CBS_HASSTRINGS LTEXT "&URL:", -1, 10, 42, 20, 10 @@ -56,14 +53,3 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "OK", IDOK, 200, 10, 45, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Cancelar", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP } - -ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 -STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", ID_PROMPT_PROMPT, 10, 10, 180, 30 - EDITTEXT ID_PROMPT_EDIT, 10, 45, 180, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - PUSHBUTTON "OK", IDOK, 40, 65, 45, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Cancelar", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP -} diff --git a/dlls/mshtml/Ro.rc b/dlls/mshtml/Ro.rc index 1bac21645d2..4bb71993c47 100644 --- a/dlls/mshtml/Ro.rc +++ b/dlls/mshtml/Ro.rc @@ -17,7 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL @@ -66,3 +65,5 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "OK", IDOK, 40, 65, 45, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Renunță", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP } + +#pragma code_page(default) diff --git a/dlls/mshtml/Ru.rc b/dlls/mshtml/Ru.rc index 7638d9b8e9d..9460f243567 100644 --- a/dlls/mshtml/Ru.rc +++ b/dlls/mshtml/Ru.rc @@ -16,44 +16,40 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { - IDS_HTMLDISABLED "В настоящее время отображение HTML выключенно." - IDS_HTMLDOCUMENT "Документ HTML" - IDS_DOWNLOADING "Загрузка..." - IDS_INSTALLING "Установка..." + IDS_HTMLDISABLED " íàñòîÿùåå âðåìÿ îòîáðàæåíèå HTML âûêëþ÷åííî." + IDS_HTMLDOCUMENT "Äîêóìåíò HTML" + IDS_DOWNLOADING "Çàãðóçêà..." + IDS_INSTALLING "Óñòàíîâêà..." } ID_DWL_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 0, 0, 261, 85 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Установка Wine Gecko" +CAPTION "Óñòàíîâêà Wine Gecko" FONT 8, "MS Shell Dlg" { - LTEXT "Эта программа пытается отобразить HTML страницу. Для её отображения Wine необходимо " \ - "установить Gecko (Mozilla HTML engine). Нажмите кнопку установить если вы хотите, что бы Wine " \ - "автоматически загрузил и установил Gecko.", ID_DWL_STATUS, 10, 10, 240, 33, SS_LEFT - CONTROL "Прогресс", ID_DWL_PROGRESS, PROGRESS_CLASSA, WS_BORDER|PBS_SMOOTH, 10, 46, 240, 12 - DEFPUSHBUTTON "&Установить", ID_DWL_INSTALL, 200, 63, 50, 15, WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Отмена", IDCANCEL, 140, 63, 50, 15, WS_GROUP | WS_TABSTOP + LTEXT "Ýòà ïðîãðàììà ïûòàåòñÿ îòîáðàçèòü HTML ñòðàíèöó. Äëÿ å¸ îòîáðàæåíèÿ Wine íåîáõîäèìî " \ + "óñòàíîâèòü Gecko (Mozilla HTML engine). Íàæìèòå êíîïêó óñòàíîâèòü åñëè âû õîòèòå, ÷òî áû Wine " \ + "àâòîìàòè÷åñêè çàãðóçèë è óñòàíîâèë Gecko.", ID_DWL_STATUS, 10, 10, 240, 33, SS_LEFT + CONTROL "Ïðîãðåññ", ID_DWL_PROGRESS, PROGRESS_CLASSA, WS_BORDER|PBS_SMOOTH, 10, 46, 240, 12 + DEFPUSHBUTTON "&Óñòàíîâèòü", ID_DWL_INSTALL, 200, 63, 50, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Îòìåíà", IDCANCEL, 140, 63, 50, 15, WS_GROUP | WS_TABSTOP } IDD_HYPERLINK DIALOG LOADONCALL MOVEABLE DISCARDABLE 0, 0, 250, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Ссылка" +CAPTION "Ññûëêà" FONT 8, "MS Shell Dlg" { - GROUPBOX "Информация о ссылке", -1, 5, 5, 190, 55 - LTEXT "&Тип:", -1, 10, 22, 20, 10 + GROUPBOX "Èíôîðìàöèÿ î ññûëêå", -1, 5, 5, 190, 55 + LTEXT "&Òèï:", -1, 10, 22, 20, 10 COMBOBOX IDC_TYPE, 35, 20, 45, 100, WS_TABSTOP | WS_GROUP | WS_VSCROLL | CBS_DROPDOWNLIST | CBS_HASSTRINGS - LTEXT "&Адрес:", -1, 10, 42, 20, 10 + LTEXT "&Àäðåñ:", -1, 10, 42, 20, 10 EDITTEXT IDC_URL, 35, 40, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP PUSHBUTTON "OK", IDOK, 200, 10, 45, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Отмена", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Îòìåíà", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP } diff --git a/dlls/mshtml/Si.rc b/dlls/mshtml/Si.rc index 92721df350d..2a67290fd73 100644 --- a/dlls/mshtml/Si.rc +++ b/dlls/mshtml/Si.rc @@ -16,15 +16,13 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { - IDS_HTMLDISABLED "Prikazovanje HTML dokumentov je trenutno onemogočeno." + IDS_HTMLDISABLED "Prikazovanje HTML dokumento je trenutno onemogočeno." IDS_HTMLDOCUMENT "HTML dokument" IDS_DOWNLOADING "Nalagam ..." IDS_INSTALLING "Nameščam ..." @@ -58,13 +56,4 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "Prekliči", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP } -ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 -STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", ID_PROMPT_PROMPT, 10, 10, 180, 30 - EDITTEXT ID_PROMPT_EDIT, 10, 45, 180, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - PUSHBUTTON "V redu", IDOK, 40, 65, 45, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Prekliči", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP -} +#pragma code_page(default) diff --git a/dlls/mshtml/Sv.rc b/dlls/mshtml/Sv.rc index 041ff8b5dc7..b6a1fd04573 100644 --- a/dlls/mshtml/Sv.rc +++ b/dlls/mshtml/Sv.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL diff --git a/dlls/mshtml/Tr.rc b/dlls/mshtml/Tr.rc index 7e85fc6b4a1..6d843a1503d 100644 --- a/dlls/mshtml/Tr.rc +++ b/dlls/mshtml/Tr.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT diff --git a/dlls/mshtml/Zh.rc b/dlls/mshtml/Zh.rc index 2365120e5bb..4b258a48fca 100644 --- a/dlls/mshtml/Zh.rc +++ b/dlls/mshtml/Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -96,3 +94,5 @@ FONT 9, "MS Shell Dlg" PUSHBUTTON "確定", IDOK, 200, 10, 45, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "取消", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP } + +#pragma code_page(default) diff --git a/dlls/mshtml/dispex.c b/dlls/mshtml/dispex.c index 3dd11b18e4d..0d0422c873a 100644 --- a/dlls/mshtml/dispex.c +++ b/dlls/mshtml/dispex.c @@ -77,8 +77,6 @@ static REFIID tid_ids[] = { &DIID_DispHTMLIFrame, &DIID_DispHTMLImg, &DIID_DispHTMLInputElement, - &DIID_DispHTMLLocation, - &DIID_DispHTMLNavigator, &DIID_DispHTMLOptionElement, &DIID_DispHTMLSelectElement, &DIID_DispHTMLStyle, diff --git a/dlls/mshtml/htmlelemcol.c b/dlls/mshtml/htmlelemcol.c index 43628907943..049da58a9bb 100644 --- a/dlls/mshtml/htmlelemcol.c +++ b/dlls/mshtml/htmlelemcol.c @@ -236,43 +236,39 @@ static BOOL is_elem_name(HTMLElement *elem, LPCWSTR name) return ret; } -static HRESULT get_item_idx(HTMLElementCollection *This, UINT idx, IDispatch **ret) -{ - if(idx < This->len) { - *ret = (IDispatch*)This->elems[idx]; - IDispatch_AddRef(*ret); - } - - return S_OK; -} - static HRESULT WINAPI HTMLElementCollection_item(IHTMLElementCollection *iface, VARIANT name, VARIANT index, IDispatch **pdisp) { HTMLElementCollection *This = ELEMCOL_THIS(iface); - HRESULT hres = S_OK; - TRACE("(%p)->(%s %s %p)\n", This, debugstr_variant(&name), debugstr_variant(&index), pdisp); + TRACE("(%p)->(v(%d) v(%d) %p)\n", This, V_VT(&name), V_VT(&index), pdisp); *pdisp = NULL; - switch(V_VT(&name)) { - case VT_I4: + if(V_VT(&name) == VT_I4) { + TRACE("name is VT_I4: %d\n", V_I4(&name)); + if(V_I4(&name) < 0) return E_INVALIDARG; - hres = get_item_idx(This, V_I4(&name), pdisp); - break; + if(V_I4(&name) >= This->len) + return S_OK; - case VT_UINT: - hres = get_item_idx(This, V_UINT(&name), pdisp); - break; + *pdisp = (IDispatch*)This->elems[V_I4(&name)]; + IDispatch_AddRef(*pdisp); + TRACE("Returning pdisp=%p\n", pdisp); + return S_OK; + } - case VT_BSTR: { + if(V_VT(&name) == VT_BSTR) { DWORD i; + TRACE("name is VT_BSTR: %s\n", debugstr_w(V_BSTR(&name))); + if(V_VT(&index) == VT_I4) { LONG idx = V_I4(&index); + TRACE("index = %d\n", idx); + if(idx < 0) return E_INVALIDARG; @@ -285,6 +281,8 @@ static HRESULT WINAPI HTMLElementCollection_item(IHTMLElementCollection *iface, *pdisp = (IDispatch*)HTMLELEM(This->elems[i]); IDispatch_AddRef(*pdisp); } + + return S_OK; }else { elem_vector_t buf = {NULL, 0, 8}; @@ -306,18 +304,13 @@ static HRESULT WINAPI HTMLElementCollection_item(IHTMLElementCollection *iface, heap_free(buf.buf); } - } - break; - } - default: - FIXME("Unsupported name %s\n", debugstr_variant(&name)); - hres = E_NOTIMPL; + return S_OK; + } } - if(SUCCEEDED(hres)) - TRACE("returning %p\n", *pdisp); - return hres; + FIXME("unsupported arguments\n"); + return E_INVALIDARG; } static HRESULT WINAPI HTMLElementCollection_tags(IHTMLElementCollection *iface, diff --git a/dlls/mshtml/htmllocation.c b/dlls/mshtml/htmllocation.c index 35f042a2676..c671073b84b 100644 --- a/dlls/mshtml/htmllocation.c +++ b/dlls/mshtml/htmllocation.c @@ -293,7 +293,7 @@ static const tid_t HTMLLocation_iface_tids[] = { }; static dispex_static_data_t HTMLLocation_dispex = { NULL, - DispHTMLLocation_tid, + IHTMLLocation_tid, NULL, HTMLLocation_iface_tids }; diff --git a/dlls/mshtml/main.c b/dlls/mshtml/main.c index 548c50ca966..305727629b3 100644 --- a/dlls/mshtml/main.c +++ b/dlls/mshtml/main.c @@ -433,8 +433,6 @@ const char *debugstr_variant(const VARIANT *v) return wine_dbg_sprintf("{VT_DISPATCH: %p}", V_DISPATCH(v)); case VT_BOOL: return wine_dbg_sprintf("{VT_BOOL: %x}", V_BOOL(v)); - case VT_UINT: - return wine_dbg_sprintf("{VT_UINT: %u}", V_UINT(v)); default: return wine_dbg_sprintf("{vt %d}", V_VT(v)); } diff --git a/dlls/mshtml/mshtml_private.h b/dlls/mshtml/mshtml_private.h index 6ab70f2df21..ebb63bbd39c 100644 --- a/dlls/mshtml/mshtml_private.h +++ b/dlls/mshtml/mshtml_private.h @@ -74,8 +74,6 @@ typedef enum { DispHTMLIFrame_tid, DispHTMLImg_tid, DispHTMLInputElement_tid, - DispHTMLLocation_tid, - DispHTMLNavigator_tid, DispHTMLOptionElement_tid, DispHTMLSelectElement_tid, DispHTMLStyle_tid, diff --git a/dlls/mshtml/nsembed.c b/dlls/mshtml/nsembed.c index 85a3a0dbb9e..9a3f3961dc9 100644 --- a/dlls/mshtml/nsembed.c +++ b/dlls/mshtml/nsembed.c @@ -448,6 +448,10 @@ static BOOL init_xpcom(const PRUnichar *gre_path) if(NS_FAILED(nsres)) ERR("AutoRegister(NULL) failed: %08x\n", nsres); + nsres = nsIComponentRegistrar_AutoRegister(registrar, gre_dir); + if(NS_FAILED(nsres)) + ERR("AutoRegister(gre_dir) failed: %08x\n", nsres); + init_nsio(pCompMgr, registrar); }else { ERR("NS_GetComponentRegistrar failed: %08x\n", nsres); diff --git a/dlls/mshtml/omnavigator.c b/dlls/mshtml/omnavigator.c index e86537f946d..a3eed8bce3b 100644 --- a/dlls/mshtml/omnavigator.c +++ b/dlls/mshtml/omnavigator.c @@ -329,7 +329,7 @@ static const tid_t OmNavigator_iface_tids[] = { }; static dispex_static_data_t OmNavigator_dispex = { NULL, - DispHTMLNavigator_tid, + IOmNavigator_tid, NULL, OmNavigator_iface_tids }; diff --git a/dlls/mshtml/resource.h b/dlls/mshtml/resource.h index 1e926378b10..f40938054e3 100644 --- a/dlls/mshtml/resource.h +++ b/dlls/mshtml/resource.h @@ -16,10 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include -#include - #define IDS_HTMLDISABLED 7500 #define IDS_HTMLDOCUMENT 7501 #define IDS_DOWNLOADING 7502 diff --git a/dlls/mshtml/rsrc.rc b/dlls/mshtml/rsrc.rc index 5e669de70ef..8be957f7156 100644 --- a/dlls/mshtml/rsrc.rc +++ b/dlls/mshtml/rsrc.rc @@ -16,6 +16,13 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include "windef.h" +#include "winuser.h" +#include "commctrl.h" +#include "mshtmcid.h" + +#include "resource.h" + #define WINE_OLESELFREGISTER #define WINE_FILEDESCRIPTION_STR "Wine HTML Viewer" #define WINE_FILENAME_STR "mshtml.dll" @@ -26,6 +33,30 @@ #include "wine/wine_common_ver.rc" +#include "Bg.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Es.rc" +#include "Fi.rc" +#include "Fr.rc" +#include "Hu.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Lt.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ro.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" + +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + /* @makedep: mshtml.inf */ REGINST REGINST mshtml.inf diff --git a/dlls/mshtml/tests/dom.c b/dlls/mshtml/tests/dom.c index a153a1456a3..92b379b7523 100644 --- a/dlls/mshtml/tests/dom.c +++ b/dlls/mshtml/tests/dom.c @@ -438,19 +438,18 @@ static void _test_ifaces(unsigned line, IUnknown *iface, REFIID *iids) } } -#define test_get_dispid(u,id) _test_disp(__LINE__,u,id) -static BOOL _test_get_dispid(unsigned line, IUnknown *unk, IID *iid) +#define test_disp(u,id) _test_disp(__LINE__,u,id) +static void _test_disp(unsigned line, IUnknown *unk, const IID *diid) { IDispatchEx *dispex; ITypeInfo *typeinfo; - BOOL ret = FALSE; UINT ticnt; HRESULT hres; hres = IUnknown_QueryInterface(unk, &IID_IDispatchEx, (void**)&dispex); ok_(__FILE__,line) (hres == S_OK, "Could not get IDispatch: %08x\n", hres); if(FAILED(hres)) - return FALSE; + return; ticnt = 0xdeadbeef; hres = IDispatchEx_GetTypeInfoCount(dispex, &ticnt); @@ -465,36 +464,13 @@ static BOOL _test_get_dispid(unsigned line, IUnknown *unk, IID *iid) hres = ITypeInfo_GetTypeAttr(typeinfo, &type_attr); ok_(__FILE__,line) (hres == S_OK, "GetTypeAttr failed: %08x\n", hres); - if(hres == S_OK) { - *iid = type_attr->guid; - ret = TRUE; - } + ok_(__FILE__,line) (IsEqualGUID(&type_attr->guid, diid), "unexpected guid %s\n", dbgstr_guid(&type_attr->guid)); ITypeInfo_ReleaseTypeAttr(typeinfo, type_attr); ITypeInfo_Release(typeinfo); } IDispatchEx_Release(dispex); - return ret; -} - -#define test_disp(u,id) _test_disp(__LINE__,u,id) -static void _test_disp(unsigned line, IUnknown *unk, const IID *diid) -{ - IID iid; - - if(_test_get_dispid(line, unk, &iid)) - ok_(__FILE__,line) (IsEqualGUID(&iid, diid), "unexpected guid %s\n", dbgstr_guid(&iid)); -} - -#define test_disp2(u,id,id2) _test_disp2(__LINE__,u,id,id2) -static void _test_disp2(unsigned line, IUnknown *unk, const IID *diid, const IID *diid2) -{ - IID iid; - - if(_test_get_dispid(line, unk, &iid)) - ok_(__FILE__,line) (IsEqualGUID(&iid, diid) || broken(IsEqualGUID(&iid, diid2)), - "unexpected guid %s\n", dbgstr_guid(&iid)); } #define get_elem_iface(u) _get_elem_iface(__LINE__,u) @@ -1025,7 +1001,7 @@ static void _test_elem_collection(unsigned line, IUnknown *unk, LONG len; DWORD i; VARIANT name, index; - IDispatch *disp, *disp2; + IDispatch *disp; HRESULT hres; hres = IUnknown_QueryInterface(unk, &IID_IHTMLElementCollection, (void**)&col); @@ -1041,9 +1017,9 @@ static void _test_elem_collection(unsigned line, IUnknown *unk, len = exlen; V_VT(&index) = VT_EMPTY; + V_VT(&name) = VT_I4; for(i=0; iTargetPath, target, action ); - r = wait_thread_handle( info ); - release_custom_action_data( info ); - return r; + return wait_thread_handle( info ); } static UINT HANDLE_CustomType18(MSIPACKAGE *package, LPCWSTR source, @@ -1175,7 +1167,9 @@ static DWORD ACTION_CallScript( const GUID *guid ) else ERR("failed to create handle for %p\n", info->package ); - release_custom_action_data( info ); + if (info->type & msidbCustomActionTypeAsync && + info->type & msidbCustomActionTypeContinue) + release_custom_action_data( info ); return S_OK; } @@ -1232,16 +1226,13 @@ static msi_custom_action_info *do_msidbCustomActionTypeScript( static UINT HANDLE_CustomType37_38(MSIPACKAGE *package, LPCWSTR source, LPCWSTR target, const INT type, LPCWSTR action) { - UINT r; msi_custom_action_info *info; TRACE("%s %s\n", debugstr_w(source), debugstr_w(target)); info = do_msidbCustomActionTypeScript( package, type, target, NULL, action ); - r = wait_thread_handle( info ); - release_custom_action_data( info ); - return r; + return wait_thread_handle( info ); } static UINT HANDLE_CustomType5_6(MSIPACKAGE *package, LPCWSTR source, @@ -1286,7 +1277,6 @@ static UINT HANDLE_CustomType5_6(MSIPACKAGE *package, LPCWSTR source, info = do_msidbCustomActionTypeScript( package, type, bufferw, target, action ); r = wait_thread_handle( info ); - release_custom_action_data( info ); done: msi_free(bufferw); @@ -1351,7 +1341,6 @@ static UINT HANDLE_CustomType21_22(MSIPACKAGE *package, LPCWSTR source, info = do_msidbCustomActionTypeScript( package, type, bufferw, target, action ); r = wait_thread_handle( info ); - release_custom_action_data( info ); done: msi_free(bufferw); @@ -1364,7 +1353,6 @@ static UINT HANDLE_CustomType53_54(MSIPACKAGE *package, LPCWSTR source, { msi_custom_action_info *info; WCHAR *prop; - UINT r; TRACE("%s %s\n", debugstr_w(source), debugstr_w(target)); @@ -1374,9 +1362,7 @@ static UINT HANDLE_CustomType53_54(MSIPACKAGE *package, LPCWSTR source, info = do_msidbCustomActionTypeScript( package, type, prop, NULL, action ); msi_free(prop); - r = wait_thread_handle( info ); - release_custom_action_data( info ); - return r; + return wait_thread_handle( info ); } void ACTION_FinishCustomActions(const MSIPACKAGE* package) diff --git a/dlls/msi/database.c b/dlls/msi/database.c index 4c21876c49a..bc9319e33db 100644 --- a/dlls/msi/database.c +++ b/dlls/msi/database.c @@ -41,6 +41,11 @@ WINE_DEFAULT_DEBUG_CHANNEL(msi); +DEFINE_GUID( CLSID_MsiDatabase, 0x000c1084, 0x0000, 0x0000, + 0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x46); +DEFINE_GUID( CLSID_MsiPatch, 0x000c1086, 0x0000, 0x0000, + 0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x46); + /* * .MSI file format * @@ -158,8 +163,7 @@ UINT MSI_OpenDatabaseW(LPCWSTR szDBPath, LPCWSTR szPersist, MSIDATABASE **pdb) } if ( !IsEqualGUID( &stat.clsid, &CLSID_MsiDatabase ) && - !IsEqualGUID( &stat.clsid, &CLSID_MsiPatch ) && - !IsEqualGUID( &stat.clsid, &CLSID_MsiTransform ) ) + !IsEqualGUID( &stat.clsid, &CLSID_MsiPatch ) ) { ERR("storage GUID is not a MSI database GUID %s\n", debugstr_guid(&stat.clsid) ); diff --git a/dlls/msi/dialog.c b/dlls/msi/dialog.c index 88416e3d027..495e033e913 100644 --- a/dlls/msi/dialog.c +++ b/dlls/msi/dialog.c @@ -171,7 +171,7 @@ static HWND hMsiHiddenWindow; static INT msi_dialog_scale_unit( msi_dialog *dialog, INT val ) { - return MulDiv( val, dialog->scale, 12 ); + return (dialog->scale * val + 5) / 10; } static msi_control *msi_dialog_find_control( msi_dialog *dialog, LPCWSTR name ) @@ -417,7 +417,7 @@ static msi_control *msi_dialog_create_window( msi_dialog *dialog, return NULL; strcpyW( control->name, name ); - list_add_tail( &dialog->controls, &control->entry ); + list_add_head( &dialog->controls, &control->entry ); control->handler = NULL; control->update = NULL; control->property = NULL; @@ -2911,7 +2911,7 @@ static INT msi_dialog_get_sans_serif_height( HWND hwnd ) if (hdc) { memset( &lf, 0, sizeof lf ); - lf.lfHeight = MulDiv(12, GetDeviceCaps(hdc, LOGPIXELSY), 72); + lf.lfHeight = MulDiv(10, GetDeviceCaps(hdc, LOGPIXELSY), 72); strcpyW( lf.lfFaceName, szSansSerif ); hFont = CreateFontIndirectW(&lf); if (hFont) @@ -3002,34 +3002,37 @@ static void msi_dialog_adjust_dialog_pos( msi_dialog *dialog, MSIRECORD *rec, LP AdjustWindowRect( pos, style, FALSE ); } -static void msi_dialog_set_tab_order( msi_dialog *dialog, LPCWSTR first ) +static BOOL msi_control_set_next( msi_control *control, msi_control *next ) { - struct list tab_chain; - msi_control *control; - HWND prev = HWND_TOP; + return SetWindowPos( next->hwnd, control->hwnd, 0, 0, 0, 0, + SWP_NOMOVE | SWP_NOOWNERZORDER | SWP_NOREDRAW | + SWP_NOREPOSITION | SWP_NOSENDCHANGING | SWP_NOSIZE ); +} - list_init( &tab_chain ); - if (!(control = msi_dialog_find_control( dialog, first ))) return; +static UINT msi_dialog_set_tab_order( msi_dialog *dialog ) +{ + msi_control *control, *tab_next; - dialog->hWndFocus = control->hwnd; - while (control) + LIST_FOR_EACH_ENTRY( control, &dialog->controls, msi_control, entry ) { - list_remove( &control->entry ); - list_add_tail( &tab_chain, &control->entry ); - if (!control->tabnext) break; - control = msi_dialog_find_control( dialog, control->tabnext ); + tab_next = msi_dialog_find_control( dialog, control->tabnext ); + if( !tab_next ) + continue; + msi_control_set_next( control, tab_next ); } - LIST_FOR_EACH_ENTRY( control, &tab_chain, msi_control, entry ) - { - SetWindowPos( control->hwnd, prev, 0, 0, 0, 0, - SWP_NOMOVE | SWP_NOOWNERZORDER | SWP_NOREDRAW | - SWP_NOREPOSITION | SWP_NOSENDCHANGING | SWP_NOSIZE ); - prev = control->hwnd; - } + return ERROR_SUCCESS; +} + +static void msi_dialog_set_first_control( msi_dialog* dialog, LPCWSTR name ) +{ + msi_control *control; - /* put them back on the main list */ - list_move_head( &dialog->controls, &tab_chain ); + control = msi_dialog_find_control( dialog, name ); + if( control ) + dialog->hWndFocus = control->hwnd; + else + dialog->hWndFocus = NULL; } static LRESULT msi_dialog_oncreate( HWND hwnd, LPCREATESTRUCTW cs ) @@ -3079,7 +3082,8 @@ static LRESULT msi_dialog_oncreate( HWND hwnd, LPCREATESTRUCTW cs ) msi_dialog_build_font_list( dialog ); msi_dialog_fill_controls( dialog ); msi_dialog_evaluate_control_conditions( dialog ); - msi_dialog_set_tab_order( dialog, MSI_RecordGetString( rec, 8 ) ); + msi_dialog_set_tab_order( dialog ); + msi_dialog_set_first_control( dialog, MSI_RecordGetString( rec, 8 ) ); msiobj_release( &rec->hdr ); return 0; diff --git a/dlls/msi/msi.rc b/dlls/msi/msi.rc index 466269a475d..ffcb0c19ca9 100644 --- a/dlls/msi/msi.rc +++ b/dlls/msi/msi.rc @@ -19,6 +19,37 @@ */ #include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winnls.h" + +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + +#include "version.rc" + +#include "msi_Bg.rc" +#include "msi_Da.rc" +#include "msi_De.rc" +#include "msi_En.rc" +#include "msi_Eo.rc" +#include "msi_Es.rc" +#include "msi_Fi.rc" +#include "msi_Fr.rc" +#include "msi_Hu.rc" +#include "msi_It.rc" +#include "msi_Ko.rc" +#include "msi_Nl.rc" +#include "msi_No.rc" +#include "msi_Pl.rc" +#include "msi_Pt.rc" +#include "msi_Ro.rc" +#include "msi_Ru.rc" +#include "msi_Si.rc" +#include "msi_Sv.rc" +#include "msi_Tr.rc" +#include "msi_Zh.rc" + +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL /* @makedep: msiserver.tlb */ 1 TYPELIB LOADONCALL DISCARDABLE msiserver.tlb diff --git a/dlls/msi/msi_Bg.rc b/dlls/msi/msi_Bg.rc index d3b8ca84abb..3f2b34a5eb1 100644 --- a/dlls/msi/msi_Bg.rc +++ b/dlls/msi/msi_Bg.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_Da.rc b/dlls/msi/msi_Da.rc index beee42765ee..0fd1af07ee0 100644 --- a/dlls/msi/msi_Da.rc +++ b/dlls/msi/msi_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_De.rc b/dlls/msi/msi_De.rc index e0cccf07806..00649b6ecd4 100644 --- a/dlls/msi/msi_De.rc +++ b/dlls/msi/msi_De.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -36,3 +34,5 @@ STRINGTABLE DISCARDABLE 14 "Feature von:" 15 "Wählen Sie das Verzeichnis aus, dass %s enthält." } + +#pragma code_page(default) diff --git a/dlls/msi/msi_En.rc b/dlls/msi/msi_En.rc index 74fc5c14a85..55a6b229ff5 100644 --- a/dlls/msi/msi_En.rc +++ b/dlls/msi/msi_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_Eo.rc b/dlls/msi/msi_Eo.rc index 7579bdc65cb..e7ed2fa5a26 100644 --- a/dlls/msi/msi_Eo.rc +++ b/dlls/msi/msi_Eo.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_Es.rc b/dlls/msi/msi_Es.rc index 781be071802..94bfaf55e00 100644 --- a/dlls/msi/msi_Es.rc +++ b/dlls/msi/msi_Es.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_Fi.rc b/dlls/msi/msi_Fi.rc index 17721aa4b01..87ce3280202 100644 --- a/dlls/msi/msi_Fi.rc +++ b/dlls/msi/msi_Fi.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_Fr.rc b/dlls/msi/msi_Fr.rc index f7f733803bc..8b4b83ffdaf 100644 --- a/dlls/msi/msi_Fr.rc +++ b/dlls/msi/msi_Fr.rc @@ -18,22 +18,17 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { - 4 "Le paquet d'installation spécifié n'a pu être ouvert. Veuillez vérifier le chemin du fichier et réessayer." + 4 "The specified installation package could not be opened. Please check the file path and try again." 5 "Le chemin %s est introuvable" - 9 "insérez le disque %s" - 10 "mauvais paramètres" + 9 "insérez le disque %s" + 10 "mauvais paramètres" 11 "saisissez le nom du dossier contenant %s" - 12 "source d'installation pour la fonctionnalité manquante" - 13 "lecteur réseau pour la fonctionnalité manquante" - 14 "fonctionnalité depuis :" - 15 "sélectionnez le dossier contenant %s" + 12 "source d'installation pour la fonctionnalité manquante" + 13 "lecteur réseau pour la fonctionnalité manquant" + 14 "fonctionnalité depuis:" + 15 "sélectionnez le dossier contenant %s" } diff --git a/dlls/msi/msi_Hu.rc b/dlls/msi/msi_Hu.rc index 21ba5cf30c1..ccefef7a14b 100644 --- a/dlls/msi/msi_Hu.rc +++ b/dlls/msi/msi_Hu.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_It.rc b/dlls/msi/msi_It.rc index 9864806fd80..9e952450869 100644 --- a/dlls/msi/msi_It.rc +++ b/dlls/msi/msi_It.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_Ko.rc b/dlls/msi/msi_Ko.rc index ca14253307d..2bca718c58a 100644 --- a/dlls/msi/msi_Ko.rc +++ b/dlls/msi/msi_Ko.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_Lt.rc b/dlls/msi/msi_Lt.rc deleted file mode 100644 index 1cf1c52924e..00000000000 --- a/dlls/msi/msi_Lt.rc +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Lithuanian resources for MSI - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "windef.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - 4 "Nepavyko atverti nurodyto diegimo paketo. Patikrinkite failo kelią ir mėginkite dar kartą." - 5 "kelias %s nerastas" - 9 "įdėkite diską %s" - 10 "blogi parametrai" - 11 "įveskite aplanką, kuris turi %s" - 12 "trūksta diegimo šaltinio komponentui" - 13 "trūksta tinklo disko komponentui" - 14 "komponentas iš:" - 15 "parinkite aplanką, kuris turi %s" -} diff --git a/dlls/msi/msi_Nl.rc b/dlls/msi/msi_Nl.rc index da304304ed3..123b1c69aff 100644 --- a/dlls/msi/msi_Nl.rc +++ b/dlls/msi/msi_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_No.rc b/dlls/msi/msi_No.rc index e885f5adbda..3ab58bcb1cf 100644 --- a/dlls/msi/msi_No.rc +++ b/dlls/msi/msi_No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_Pl.rc b/dlls/msi/msi_Pl.rc index c31311ebf7e..00eb5352bb9 100644 --- a/dlls/msi/msi_Pl.rc +++ b/dlls/msi/msi_Pl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_Pt.rc b/dlls/msi/msi_Pt.rc index 64ab16348d4..3d90f71ded7 100644 --- a/dlls/msi/msi_Pt.rc +++ b/dlls/msi/msi_Pt.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_Ro.rc b/dlls/msi/msi_Ro.rc index b877b42a34e..a167d0558df 100644 --- a/dlls/msi/msi_Ro.rc +++ b/dlls/msi/msi_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -35,3 +33,5 @@ STRINGTABLE DISCARDABLE 14 "caracteristică de la:" 15 "selectați fișierul care conține %s" } + +#pragma code_page(default) diff --git a/dlls/msi/msi_Ru.rc b/dlls/msi/msi_Ru.rc index d63593e6e9f..2646573b659 100644 --- a/dlls/msi/msi_Ru.rc +++ b/dlls/msi/msi_Ru.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_Si.rc b/dlls/msi/msi_Si.rc index 75823390635..bf92697d2ef 100644 --- a/dlls/msi/msi_Si.rc +++ b/dlls/msi/msi_Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -36,3 +34,5 @@ STRINGTABLE DISCARDABLE 14 "funkcija z:" 15 "izberite mapo, ki vsebuje %s" } + +#pragma code_page(default) diff --git a/dlls/msi/msi_Sv.rc b/dlls/msi/msi_Sv.rc index 47bf09b00c4..dc1f2ed36db 100644 --- a/dlls/msi/msi_Sv.rc +++ b/dlls/msi/msi_Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_Tr.rc b/dlls/msi/msi_Tr.rc index a8e0f369666..becd9136d6d 100644 --- a/dlls/msi/msi_Tr.rc +++ b/dlls/msi/msi_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msi/msi_Zh.rc b/dlls/msi/msi_Zh.rc index a6d5cd1eff6..86620db06fc 100644 --- a/dlls/msi/msi_Zh.rc +++ b/dlls/msi/msi_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -52,3 +50,5 @@ STRINGTABLE DISCARDABLE 14 "功能來自:" 15 "選擇包含 %s 的檔案夾" } + +#pragma code_page(default) diff --git a/dlls/msi/msipriv.h b/dlls/msi/msipriv.h index b61d7b6f245..8c4bd3a4515 100644 --- a/dlls/msi/msipriv.h +++ b/dlls/msi/msipriv.h @@ -605,10 +605,6 @@ DEFINE_GUID(CLSID_IMsiServerMessage, 0x000C101D,0x0000,0x0000,0xC0,0x00,0x00,0x0 DEFINE_GUID(CLSID_IWineMsiRemoteCustomAction,0xBA26E6FA,0x4F27,0x4f56,0x95,0x3A,0x3F,0x90,0x27,0x20,0x18,0xAA); DEFINE_GUID(CLSID_IWineMsiRemotePackage,0x902b3592,0x9d08,0x4dfd,0xa5,0x93,0xd0,0x7c,0x52,0x54,0x64,0x21); -DEFINE_GUID(CLSID_MsiTransform, 0x000c1082,0x0000,0x0000,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x46); -DEFINE_GUID(CLSID_MsiDatabase, 0x000c1084,0x0000,0x0000,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x46); -DEFINE_GUID(CLSID_MsiPatch, 0x000c1086,0x0000,0x0000,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x46); - /* handle unicode/ascii output in the Msi* API functions */ typedef struct { BOOL unicode; diff --git a/dlls/msi/msiquery.c b/dlls/msi/msiquery.c index 5a46f9b5cb6..43c7b4dc52a 100644 --- a/dlls/msi/msiquery.c +++ b/dlls/msi/msiquery.c @@ -716,6 +716,8 @@ MSIHANDLE WINAPI MsiGetLastErrorRecord( void ) return 0; } +DEFINE_GUID( CLSID_MsiTransform, 0x000c1082, 0x0000, 0x0000, 0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x46); + UINT MSI_DatabaseApplyTransformW( MSIDATABASE *db, LPCWSTR szTransformFile, int iErrorCond ) { diff --git a/dlls/msi/table.c b/dlls/msi/table.c index 126769a3c62..0b5b99164b9 100644 --- a/dlls/msi/table.c +++ b/dlls/msi/table.c @@ -121,7 +121,6 @@ static void table_calc_column_offsets( MSIDATABASE *db, MSICOLUMNINFO *colinfo, static UINT get_tablecolumns( MSIDATABASE *db, LPCWSTR szTableName, MSICOLUMNINFO *colinfo, UINT *sz); static void msi_free_colinfo( MSICOLUMNINFO *colinfo, UINT count ); -static UINT table_find_insert_idx (MSIVIEW *view, LPCWSTR name, INT *pidx); static inline UINT bytes_per_column( MSIDATABASE *db, const MSICOLUMNINFO *col ) { @@ -621,7 +620,6 @@ UINT msi_create_table( MSIDATABASE *db, LPCWSTR name, column_info *col_info, column_info *col; MSITABLE *table; UINT i; - INT idx; /* only add tables that don't exist already */ if( TABLE_Exists(db, name ) ) @@ -687,11 +685,7 @@ UINT msi_create_table( MSIDATABASE *db, LPCWSTR name, column_info *col_info, if( r ) goto err; - r = table_find_insert_idx (tv, name, &idx); - if (r != ERROR_SUCCESS) - idx = -1; - - r = tv->ops->insert_row( tv, rec, idx, persistent == MSICONDITION_FALSE ); + r = tv->ops->insert_row( tv, rec, -1, persistent == MSICONDITION_FALSE ); TRACE("insert_row returned %x\n", r); if( r ) goto err; @@ -741,11 +735,7 @@ UINT msi_create_table( MSIDATABASE *db, LPCWSTR name, column_info *col_info, if( r ) goto err; - r = table_find_insert_idx (tv, name, &idx); - if (r != ERROR_SUCCESS) - idx = -1; - - r = tv->ops->insert_row( tv, rec, idx, FALSE ); + r = tv->ops->insert_row( tv, rec, -1, FALSE ); if( r ) goto err; @@ -1711,21 +1701,6 @@ static UINT msi_table_update(struct tagMSIVIEW *view, MSIRECORD *rec, UINT row) return TABLE_set_row(view, new_row, rec, (1 << tv->num_cols) - 1); } -static UINT msi_table_assign(struct tagMSIVIEW *view, MSIRECORD *rec) -{ - MSITABLEVIEW *tv = (MSITABLEVIEW *)view; - UINT r, row; - - if (!tv->table) - return ERROR_INVALID_PARAMETER; - - r = msi_table_find_row(tv, rec, &row); - if (r == ERROR_SUCCESS) - return TABLE_set_row(view, row, rec, (1 << tv->num_cols) - 1); - else - return TABLE_insert_row( view, rec, -1, FALSE ); -} - static UINT modify_delete_row( struct tagMSIVIEW *view, MSIRECORD *rec ) { MSITABLEVIEW *tv = (MSITABLEVIEW *)view; @@ -1795,9 +1770,6 @@ static UINT TABLE_modify( struct tagMSIVIEW *view, MSIMODIFY eModifyMode, break; case MSIMODIFY_ASSIGN: - r = msi_table_assign( view, rec ); - break; - case MSIMODIFY_REPLACE: case MSIMODIFY_MERGE: case MSIMODIFY_VALIDATE: @@ -2951,29 +2923,3 @@ void msi_free_transforms( MSIDATABASE *db ) msi_free( t ); } } - -static UINT table_find_insert_idx (MSIVIEW *view, LPCWSTR name, INT *pidx) -{ - UINT r, name_id, row_id; - INT idx; - MSITABLEVIEW *tv = (MSITABLEVIEW *)view; - - TRACE ("%p %s\n", view, debugstr_w(name)); - - r = msi_string2idW(tv->db->strings, name, &name_id); - if (r != ERROR_SUCCESS) - { - *pidx = -1; - return r; - } - - for( idx = 0; idx < tv->table->row_count; idx++ ) - { - r = TABLE_fetch_int( &tv->view, idx, 1, &row_id ); - if (row_id > name_id) - break; - } - - *pidx = idx; - return ERROR_SUCCESS; -} diff --git a/dlls/msi/tests/db.c b/dlls/msi/tests/db.c index 019ff5e8bb7..2d296b580c7 100644 --- a/dlls/msi/tests/db.c +++ b/dlls/msi/tests/db.c @@ -4295,160 +4295,6 @@ static void test_special_tables(void) ok(r == ERROR_SUCCESS, "MsiCloseHandle failed\n"); } -static void test_tables_order(void) -{ - const char *query; - MSIHANDLE hdb = 0, hview = 0, hrec = 0; - UINT r; - char buffer[100]; - DWORD sz; - - r = MsiOpenDatabase(msifile, MSIDBOPEN_CREATE, &hdb); - ok(r == ERROR_SUCCESS, "MsiOpenDatabase failed\n"); - - query = "CREATE TABLE `foo` ( " - "`baz` INT NOT NULL PRIMARY KEY `baz`)"; - r = run_query(hdb, 0, query); - ok(r == ERROR_SUCCESS, "failed to create table\n"); - - query = "CREATE TABLE `bar` ( " - "`foo` INT NOT NULL PRIMARY KEY `foo`)"; - r = run_query(hdb, 0, query); - ok(r == ERROR_SUCCESS, "failed to create table\n"); - - query = "CREATE TABLE `baz` ( " - "`bar` INT NOT NULL, " - "`baz` INT NOT NULL, " - "`foo` INT NOT NULL PRIMARY KEY `bar`)"; - r = run_query(hdb, 0, query); - ok(r == ERROR_SUCCESS, "failed to create table\n"); - - /* The names of the tables in the _Tables table must - be in the same order as these names are created in - the strings table. */ - query = "SELECT * FROM `_Tables`"; - r = MsiDatabaseOpenView(hdb, query, &hview); - ok(r == ERROR_SUCCESS, "MsiDatabaseOpenView failed\n"); - r = MsiViewExecute(hview, 0); - ok(r == ERROR_SUCCESS, "MsiViewExecute failed\n"); - - r = MsiViewFetch(hview, &hrec); - ok(r == ERROR_SUCCESS, "MsiViewFetch failed\n"); - sz = sizeof(buffer); - r = MsiRecordGetString(hrec, 1, buffer, &sz); - ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrcmp(buffer, "foo"), "Expected foo, got %s\n", buffer); - r = MsiCloseHandle(hrec); - ok(r == ERROR_SUCCESS, "failed to close record\n"); - - r = MsiViewFetch(hview, &hrec); - ok(r == ERROR_SUCCESS, "MsiViewFetch failed\n"); - sz = sizeof(buffer); - r = MsiRecordGetString(hrec, 1, buffer, &sz); - ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrcmp(buffer, "baz"), "Expected baz, got %s\n", buffer); - r = MsiCloseHandle(hrec); - ok(r == ERROR_SUCCESS, "failed to close record\n"); - - r = MsiViewFetch(hview, &hrec); - ok(r == ERROR_SUCCESS, "MsiViewFetch failed\n"); - sz = sizeof(buffer); - r = MsiRecordGetString(hrec, 1, buffer, &sz); - ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrcmp(buffer, "bar"), "Expected bar, got %s\n", buffer); - r = MsiCloseHandle(hrec); - ok(r == ERROR_SUCCESS, "failed to close record\n"); - - r = MsiViewClose(hview); - ok(r == ERROR_SUCCESS, "MsiViewClose failed\n"); - r = MsiCloseHandle(hview); - ok(r == ERROR_SUCCESS, "MsiCloseHandle failed\n"); - - /* The names of the tables in the _Columns table must - be in the same order as these names are created in - the strings table. */ - query = "SELECT * FROM `_Columns`"; - r = MsiDatabaseOpenView(hdb, query, &hview); - ok(r == ERROR_SUCCESS, "MsiDatabaseOpenView failed\n"); - r = MsiViewExecute(hview, 0); - ok(r == ERROR_SUCCESS, "MsiViewExecute failed\n"); - - r = MsiViewFetch(hview, &hrec); - ok(r == ERROR_SUCCESS, "MsiViewFetch failed\n"); - sz = sizeof(buffer); - r = MsiRecordGetString(hrec, 1, buffer, &sz); - ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrcmp(buffer, "foo"), "Expected foo, got %s\n", buffer); - sz = sizeof(buffer); - r = MsiRecordGetString(hrec, 3, buffer, &sz); - ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrcmp(buffer, "baz"), "Expected baz, got %s\n", buffer); - r = MsiCloseHandle(hrec); - ok(r == ERROR_SUCCESS, "failed to close record\n"); - - r = MsiViewFetch(hview, &hrec); - ok(r == ERROR_SUCCESS, "MsiViewFetch failed\n"); - sz = sizeof(buffer); - r = MsiRecordGetString(hrec, 1, buffer, &sz); - ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrcmp(buffer, "baz"), "Expected baz, got %s\n", buffer); - sz = sizeof(buffer); - r = MsiRecordGetString(hrec, 3, buffer, &sz); - ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrcmp(buffer, "bar"), "Expected bar, got %s\n", buffer); - r = MsiCloseHandle(hrec); - ok(r == ERROR_SUCCESS, "failed to close record\n"); - - r = MsiViewFetch(hview, &hrec); - ok(r == ERROR_SUCCESS, "MsiViewFetch failed\n"); - sz = sizeof(buffer); - r = MsiRecordGetString(hrec, 1, buffer, &sz); - ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrcmp(buffer, "baz"), "Expected baz, got %s\n", buffer); - sz = sizeof(buffer); - r = MsiRecordGetString(hrec, 3, buffer, &sz); - ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrcmp(buffer, "baz"), "Expected baz, got %s\n", buffer); - r = MsiCloseHandle(hrec); - ok(r == ERROR_SUCCESS, "failed to close record\n"); - - r = MsiViewFetch(hview, &hrec); - ok(r == ERROR_SUCCESS, "MsiViewFetch failed\n"); - sz = sizeof(buffer); - r = MsiRecordGetString(hrec, 1, buffer, &sz); - ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrcmp(buffer, "baz"), "Expected baz, got %s\n", buffer); - sz = sizeof(buffer); - r = MsiRecordGetString(hrec, 3, buffer, &sz); - ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrcmp(buffer, "foo"), "Expected foo, got %s\n", buffer); - r = MsiCloseHandle(hrec); - ok(r == ERROR_SUCCESS, "failed to close record\n"); - - r = MsiViewFetch(hview, &hrec); - ok(r == ERROR_SUCCESS, "MsiViewFetch failed\n"); - sz = sizeof(buffer); - r = MsiRecordGetString(hrec, 1, buffer, &sz); - ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrcmp(buffer, "bar"), "Expected bar, got %s\n", buffer); - sz = sizeof(buffer); - r = MsiRecordGetString(hrec, 3, buffer, &sz); - ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrcmp(buffer, "foo"), "Expected foo, got %s\n", buffer); - r = MsiCloseHandle(hrec); - ok(r == ERROR_SUCCESS, "failed to close record\n"); - - r = MsiViewClose(hview); - ok(r == ERROR_SUCCESS, "MsiViewClose failed\n"); - r = MsiCloseHandle(hview); - ok(r == ERROR_SUCCESS, "MsiCloseHandle failed\n"); - - r = MsiCloseHandle(hdb); - ok(r == ERROR_SUCCESS, "MsiCloseHandle failed\n"); - - DeleteFile(msifile); -} - static void test_select_markers(void) { MSIHANDLE hdb = 0, rec, view, res; @@ -4763,127 +4609,6 @@ static void test_viewmodify_update(void) ok(r == ERROR_SUCCESS, "MsiOpenDatabase close failed\n"); } -static void test_viewmodify_assign(void) -{ - MSIHANDLE hdb = 0, hview = 0, hrec = 0; - const char *query; - UINT r; - - /* setup database */ - DeleteFile(msifile); - - r = MsiOpenDatabase(msifile, MSIDBOPEN_CREATE, &hdb); - ok(r == ERROR_SUCCESS, "MsiOpenDatabase failed\n"); - - query = "CREATE TABLE `table` (`A` INT, `B` INT PRIMARY KEY `A`)"; - r = run_query( hdb, 0, query ); - ok(r == ERROR_SUCCESS, "query failed\n"); - - /* assign to view, new primary key */ - query = "SELECT * FROM `table`"; - r = MsiDatabaseOpenView(hdb, query, &hview); - ok(r == ERROR_SUCCESS, "MsiDatabaseOpenView failed\n"); - r = MsiViewExecute(hview, 0); - ok(r == ERROR_SUCCESS, "MsiViewExecute failed\n"); - - hrec = MsiCreateRecord(2); - ok(hrec != 0, "MsiCreateRecord failed\n"); - - r = MsiRecordSetInteger(hrec, 1, 1); - ok(r == ERROR_SUCCESS, "failed to set integer\n"); - r = MsiRecordSetInteger(hrec, 2, 2); - ok(r == ERROR_SUCCESS, "failed to set integer\n"); - - r = MsiViewModify(hview, MSIMODIFY_ASSIGN, hrec); - ok(r == ERROR_SUCCESS, "MsiViewModify failed: %d\n", r); - - r = MsiCloseHandle(hrec); - ok(r == ERROR_SUCCESS, "failed to close record\n"); - - r = MsiViewClose(hview); - ok(r == ERROR_SUCCESS, "MsiViewClose failed\n"); - r = MsiCloseHandle(hview); - ok(r == ERROR_SUCCESS, "MsiCloseHandle failed\n"); - - query = "SELECT * FROM `table`"; - r = MsiDatabaseOpenView(hdb, query, &hview); - ok(r == ERROR_SUCCESS, "MsiDatabaseOpenView failed\n"); - r = MsiViewExecute(hview, 0); - ok(r == ERROR_SUCCESS, "MsiViewExecute failed\n"); - r = MsiViewFetch(hview, &hrec); - ok(r == ERROR_SUCCESS, "MsiViewFetch failed\n"); - - r = MsiRecordGetInteger(hrec, 1); - ok(r == 1, "Expected 1, got %d\n", r); - r = MsiRecordGetInteger(hrec, 2); - ok(r == 2, "Expected 2, got %d\n", r); - - r = MsiCloseHandle(hrec); - ok(r == ERROR_SUCCESS, "failed to close record\n"); - - r = MsiViewFetch(hview, &hrec); - ok(r == ERROR_NO_MORE_ITEMS, "Expected ERROR_NO_MORE_ITEMS, got %d\n", r); - - r = MsiViewClose(hview); - ok(r == ERROR_SUCCESS, "MsiViewClose failed\n"); - r = MsiCloseHandle(hview); - ok(r == ERROR_SUCCESS, "MsiCloseHandle failed\n"); - - /* assign to view, primary key matches */ - query = "SELECT * FROM `table`"; - r = MsiDatabaseOpenView(hdb, query, &hview); - ok(r == ERROR_SUCCESS, "MsiDatabaseOpenView failed\n"); - r = MsiViewExecute(hview, 0); - ok(r == ERROR_SUCCESS, "MsiViewExecute failed\n"); - - hrec = MsiCreateRecord(2); - ok(hrec != 0, "MsiCreateRecord failed\n"); - - r = MsiRecordSetInteger(hrec, 1, 1); - ok(r == ERROR_SUCCESS, "failed to set integer\n"); - r = MsiRecordSetInteger(hrec, 2, 4); - ok(r == ERROR_SUCCESS, "failed to set integer\n"); - - r = MsiViewModify(hview, MSIMODIFY_ASSIGN, hrec); - ok(r == ERROR_SUCCESS, "MsiViewModify failed: %d\n", r); - - r = MsiCloseHandle(hrec); - ok(r == ERROR_SUCCESS, "failed to close record\n"); - - r = MsiViewClose(hview); - ok(r == ERROR_SUCCESS, "MsiViewClose failed\n"); - r = MsiCloseHandle(hview); - ok(r == ERROR_SUCCESS, "MsiCloseHandle failed\n"); - - query = "SELECT * FROM `table`"; - r = MsiDatabaseOpenView(hdb, query, &hview); - ok(r == ERROR_SUCCESS, "MsiDatabaseOpenView failed\n"); - r = MsiViewExecute(hview, 0); - ok(r == ERROR_SUCCESS, "MsiViewExecute failed\n"); - r = MsiViewFetch(hview, &hrec); - ok(r == ERROR_SUCCESS, "MsiViewFetch failed\n"); - - r = MsiRecordGetInteger(hrec, 1); - ok(r == 1, "Expected 1, got %d\n", r); - r = MsiRecordGetInteger(hrec, 2); - ok(r == 4, "Expected 4, got %d\n", r); - - r = MsiCloseHandle(hrec); - ok(r == ERROR_SUCCESS, "failed to close record\n"); - - r = MsiViewFetch(hview, &hrec); - ok(r == ERROR_NO_MORE_ITEMS, "Expected ERROR_NO_MORE_ITEMS, got %d\n", r); - - r = MsiViewClose(hview); - ok(r == ERROR_SUCCESS, "MsiViewClose failed\n"); - r = MsiCloseHandle(hview); - ok(r == ERROR_SUCCESS, "MsiCloseHandle failed\n"); - - /* close database */ - r = MsiCloseHandle( hdb ); - ok(r == ERROR_SUCCESS, "MsiOpenDatabase close failed\n"); -} - static const WCHAR data10[] = { /* MOO */ 0x8001, 0x000b, }; @@ -8217,10 +7942,8 @@ START_TEST(db) test_integers(); test_update(); test_special_tables(); - test_tables_order(); test_select_markers(); test_viewmodify_update(); - test_viewmodify_assign(); test_stringtable(); test_viewmodify_delete(); test_defaultdatabase(); diff --git a/dlls/msi/tests/install.c b/dlls/msi/tests/install.c index e6c22fb745c..4912f8cf009 100644 --- a/dlls/msi/tests/install.c +++ b/dlls/msi/tests/install.c @@ -4386,19 +4386,31 @@ static void set_transform_summary_info(void) /* build summary info */ r = MsiGetSummaryInformation(0, mstfile, 3, &suminfo); - ok(r == ERROR_SUCCESS , "Failed to open summaryinfo\n"); + todo_wine + { + ok(r == ERROR_SUCCESS , "Failed to open summaryinfo\n"); + } r = MsiSummaryInfoSetProperty(suminfo, PID_TITLE, VT_LPSTR, 0, NULL, "MSITEST"); - ok(r == ERROR_SUCCESS, "Failed to set summary info\n"); + todo_wine + { + ok(r == ERROR_SUCCESS, "Failed to set summary info\n"); + } r = MsiSummaryInfoSetProperty(suminfo, PID_REVNUMBER, VT_LPSTR, 0, NULL, "{7DF88A48-996F-4EC8-A022-BF956F9B2CBB}1.1.1;" "{7DF88A48-996F-4EC8-A022-BF956F9B2CBB}1.1.1;" "{4C0EAA15-0264-4E5A-8758-609EF142B92D}"); - ok(r == ERROR_SUCCESS , "Failed to set summary info\n"); + todo_wine + { + ok(r == ERROR_SUCCESS , "Failed to set summary info\n"); + } r = MsiSummaryInfoSetProperty(suminfo, PID_PAGECOUNT, VT_I4, 100, NULL, NULL); - ok(r == ERROR_SUCCESS, "Failed to set summary info\n"); + todo_wine + { + ok(r == ERROR_SUCCESS, "Failed to set summary info\n"); + } r = MsiSummaryInfoPersist(suminfo); todo_wine diff --git a/dlls/msrle32/Makefile.in b/dlls/msrle32/Makefile.in index df92201111c..eef540bb46c 100644 --- a/dlls/msrle32/Makefile.in +++ b/dlls/msrle32/Makefile.in @@ -7,28 +7,7 @@ IMPORTS = winmm user32 kernel32 C_SRCS = msrle32.c -RC_SRCS = \ - msrle_Bg.rc \ - msrle_Cs.rc \ - msrle_Da.rc \ - msrle_De.rc \ - msrle_En.rc \ - msrle_Es.rc \ - msrle_Fr.rc \ - msrle_Hu.rc \ - msrle_It.rc \ - msrle_Ja.rc \ - msrle_Ko.rc \ - msrle_Lt.rc \ - msrle_Nl.rc \ - msrle_No.rc \ - msrle_Pl.rc \ - msrle_Pt.rc \ - msrle_Ro.rc \ - msrle_Ru.rc \ - msrle_Si.rc \ - msrle_Sv.rc \ - msrle_Tr.rc +RC_SRCS = rsrc.rc @MAKE_DLL_RULES@ diff --git a/dlls/msrle32/msrle_Bg.rc b/dlls/msrle32/msrle_Bg.rc index 5073f0bf375..7c0d4488a57 100644 --- a/dlls/msrle32/msrle_Bg.rc +++ b/dlls/msrle32/msrle_Bg.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msrle32/msrle_Cs.rc b/dlls/msrle32/msrle_Cs.rc index a4a6c2f6e49..51fb1dfbef8 100644 --- a/dlls/msrle32/msrle_Cs.rc +++ b/dlls/msrle32/msrle_Cs.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/dlls/msrle32/msrle_Da.rc b/dlls/msrle32/msrle_Da.rc index 4ab40e3b048..c3ea57b4f11 100644 --- a/dlls/msrle32/msrle_Da.rc +++ b/dlls/msrle32/msrle_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msrle32/msrle_De.rc b/dlls/msrle32/msrle_De.rc index 0480cfbd104..c5f4954e2ef 100644 --- a/dlls/msrle32/msrle_De.rc +++ b/dlls/msrle32/msrle_De.rc @@ -1,7 +1,7 @@ /* * German resource file for MS-RLE * - * Copyright 2002 Michael Günnewig + * Copyright 2002 Michael Günnewig * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -18,15 +18,11 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { IDS_NAME "WINE-MS-RLE" IDS_DESCRIPTION "Wine MS-RLE Videodekoder" - IDS_ABOUT "Wine MS-RLE Videodekoder\nCopyright 2002 by Michael Günnewig" + IDS_ABOUT "Wine MS-RLE Videodekoder\nCopyright 2002 by Michael Günnewig" } diff --git a/dlls/msrle32/msrle_En.rc b/dlls/msrle32/msrle_En.rc index e95f395a70e..030a98a3aa5 100644 --- a/dlls/msrle32/msrle_En.rc +++ b/dlls/msrle32/msrle_En.rc @@ -1,7 +1,7 @@ /* * English resource file for MS-RLE * - * Copyright 2002 Michael Günnewig + * Copyright 2002 Michael Günnewig * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -18,15 +18,11 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - -#pragma code_page(65001) - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { IDS_NAME "WINE-MS-RLE" IDS_DESCRIPTION "Wine MS-RLE video codec" - IDS_ABOUT "Wine MS-RLE video codec\nCopyright 2002 by Michael Günnewig" + IDS_ABOUT "Wine MS-RLE video codec\nCopyright 2002 by Michael Günnewig" } diff --git a/dlls/msrle32/msrle_Es.rc b/dlls/msrle32/msrle_Es.rc index edb62148113..ca418cb7594 100644 --- a/dlls/msrle32/msrle_Es.rc +++ b/dlls/msrle32/msrle_Es.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/msrle32/msrle_Fr.rc b/dlls/msrle32/msrle_Fr.rc index f45892c7d55..e6eb31423f2 100644 --- a/dlls/msrle32/msrle_Fr.rc +++ b/dlls/msrle32/msrle_Fr.rc @@ -1,7 +1,7 @@ /* * French resource file for MS-RLE * - * Copyright 2002 Michael Günnewig + * Copyright 2002 Michael Günnewig * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -18,16 +18,11 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { IDS_NAME "WINE-MS-RLE" - IDS_DESCRIPTION "Wine : codec vidéo MS-RLE" - IDS_ABOUT "Wine : codec vidéo MS-RLE\nCopyright 2002 par Michael Günnewig" + IDS_DESCRIPTION "Wine: décodeur/encodeur vidéo MS-RLE" + IDS_ABOUT "Wine: décodeur/encodeur vidéo MS-RLE\nCopyright 2002 par Michael Günnewig" } diff --git a/dlls/msrle32/msrle_Hu.rc b/dlls/msrle32/msrle_Hu.rc index 3f4b581f4cf..95016acb4d2 100644 --- a/dlls/msrle32/msrle_Hu.rc +++ b/dlls/msrle32/msrle_Hu.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msrle32/msrle_It.rc b/dlls/msrle32/msrle_It.rc index 0b21705355c..695a78285f8 100644 --- a/dlls/msrle32/msrle_It.rc +++ b/dlls/msrle32/msrle_It.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/msrle32/msrle_Ja.rc b/dlls/msrle32/msrle_Ja.rc index e1ec7bb2b10..c2866a155c1 100644 --- a/dlls/msrle32/msrle_Ja.rc +++ b/dlls/msrle32/msrle_Ja.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - /* UTF-8 */ #pragma code_page(65001) @@ -31,3 +29,5 @@ STRINGTABLE DISCARDABLE IDS_DESCRIPTION "Wine MS-RLE ビデオコーデック" IDS_ABOUT "Wine MS-RLE ビデオコーデック\nCopyright 2002 by Michael Günewig" } + +#pragma code_page(default) diff --git a/dlls/msrle32/msrle_Ko.rc b/dlls/msrle32/msrle_Ko.rc index f6c38b37a96..3f9d137b009 100644 --- a/dlls/msrle32/msrle_Ko.rc +++ b/dlls/msrle32/msrle_Ko.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msrle32/msrle_Lt.rc b/dlls/msrle32/msrle_Lt.rc deleted file mode 100644 index f399f544060..00000000000 --- a/dlls/msrle32/msrle_Lt.rc +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Lithuanian resource file for MS-RLE - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "msrle_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_NAME "WINE-MS-RLE" - IDS_DESCRIPTION "Wine MS-RLE vaizdo kodekas" - IDS_ABOUT "Wine MS-RLE vaizdo kodekas\nAutoriaus teisės Michael Günnewig, 2002" -} diff --git a/dlls/msrle32/msrle_Nl.rc b/dlls/msrle32/msrle_Nl.rc index ba0419c48dd..f98f5fd9835 100644 --- a/dlls/msrle32/msrle_Nl.rc +++ b/dlls/msrle32/msrle_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/msrle32/msrle_No.rc b/dlls/msrle32/msrle_No.rc index 6b079f9ed47..411e4590447 100644 --- a/dlls/msrle32/msrle_No.rc +++ b/dlls/msrle32/msrle_No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE DISCARDABLE diff --git a/dlls/msrle32/msrle_Pl.rc b/dlls/msrle32/msrle_Pl.rc index 9394da1aab2..013fea5a0ed 100644 --- a/dlls/msrle32/msrle_Pl.rc +++ b/dlls/msrle32/msrle_Pl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msrle32/msrle_Pt.rc b/dlls/msrle32/msrle_Pt.rc index 33a646205ec..cc74b38e981 100644 --- a/dlls/msrle32/msrle_Pt.rc +++ b/dlls/msrle32/msrle_Pt.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE DISCARDABLE diff --git a/dlls/msrle32/msrle_Ro.rc b/dlls/msrle32/msrle_Ro.rc index 16aa0e9f985..64366c36a91 100644 --- a/dlls/msrle32/msrle_Ro.rc +++ b/dlls/msrle32/msrle_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -29,3 +27,5 @@ STRINGTABLE DISCARDABLE IDS_DESCRIPTION "Codecul video Wine MS-RLE" IDS_ABOUT "Codecul video Wine MS-RLE\nCopyright 2002 by Michael Günnewig" } + +#pragma code_page(default) diff --git a/dlls/msrle32/msrle_Ru.rc b/dlls/msrle32/msrle_Ru.rc index 4ae0101ad43..4f8bd56b158 100644 --- a/dlls/msrle32/msrle_Ru.rc +++ b/dlls/msrle32/msrle_Ru.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msrle32/msrle_Si.rc b/dlls/msrle32/msrle_Si.rc index 346569bf5fd..eeb23739f7d 100644 --- a/dlls/msrle32/msrle_Si.rc +++ b/dlls/msrle32/msrle_Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -30,3 +28,5 @@ STRINGTABLE DISCARDABLE IDS_DESCRIPTION "Wine MS-RLE video kodek" IDS_ABOUT "Wine MS-RLE video kodek\nCopyright 2002 by Michael Günnewig" } + +#pragma code_page(default) diff --git a/dlls/msrle32/msrle_Sv.rc b/dlls/msrle32/msrle_Sv.rc index 4570e609ad5..fba656a33d0 100644 --- a/dlls/msrle32/msrle_Sv.rc +++ b/dlls/msrle32/msrle_Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/msrle32/msrle_Tr.rc b/dlls/msrle32/msrle_Tr.rc index 8decf375762..36cee7531f1 100644 --- a/dlls/msrle32/msrle_Tr.rc +++ b/dlls/msrle32/msrle_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msrle_private.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msrle32/rsrc.rc b/dlls/msrle32/rsrc.rc new file mode 100644 index 00000000000..6d3ff958153 --- /dev/null +++ b/dlls/msrle32/rsrc.rc @@ -0,0 +1,53 @@ +/* + * Top level resource file for MS-RLE + * + * Copyright 2002 Michael Günnewig + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" + +#include "msrle_private.h" + +/* + * Everything specific to any language goes + * in one of the specific files. + * Note that you can and may override resources + * which also have a neutral version. This is to + * get localized bitmaps for example. + */ + +#include "msrle_Bg.rc" +#include "msrle_Cs.rc" +#include "msrle_Da.rc" +#include "msrle_De.rc" +#include "msrle_En.rc" +#include "msrle_Es.rc" +#include "msrle_Fr.rc" +#include "msrle_Hu.rc" +#include "msrle_It.rc" +#include "msrle_Ja.rc" +#include "msrle_Ko.rc" +#include "msrle_Nl.rc" +#include "msrle_No.rc" +#include "msrle_Pl.rc" +#include "msrle_Pt.rc" +#include "msrle_Ro.rc" +#include "msrle_Ru.rc" +#include "msrle_Si.rc" +#include "msrle_Sv.rc" +#include "msrle_Tr.rc" diff --git a/dlls/msvcrt/cppexcept.c b/dlls/msvcrt/cppexcept.c index a777025f69f..6dafc9e8dc0 100644 --- a/dlls/msvcrt/cppexcept.c +++ b/dlls/msvcrt/cppexcept.c @@ -413,22 +413,14 @@ extern DWORD CDECL __CxxFrameHandler( PEXCEPTION_RECORD rec, EXCEPTION_REGISTRAT PCONTEXT context, EXCEPTION_REGISTRATION_RECORD** dispatch ); __ASM_GLOBAL_FUNC( __CxxFrameHandler, "pushl $0\n\t" /* nested_trylevel */ - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") "pushl $0\n\t" /* nested_frame */ - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") "pushl %eax\n\t" /* descr */ - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") "pushl 28(%esp)\n\t" /* dispatch */ - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") "pushl 28(%esp)\n\t" /* context */ - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") "pushl 28(%esp)\n\t" /* frame */ - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") "pushl 28(%esp)\n\t" /* rec */ - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") "call " __ASM_NAME("cxx_frame_handler") "\n\t" "add $28,%esp\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset -28\n\t") "ret" ) diff --git a/dlls/msvcrt/errno.c b/dlls/msvcrt/errno.c index 413ab391fc0..6ed6086877f 100644 --- a/dlls/msvcrt/errno.c +++ b/dlls/msvcrt/errno.c @@ -140,7 +140,6 @@ void msvcrt_set_errno(int err) ERR_CASE(ERROR_DRIVE_LOCKED) ERR_CASE(ERROR_NOT_LOCKED) ERR_CASE(ERROR_INVALID_ACCESS) - ERR_CASE(ERROR_SHARING_VIOLATION) ERR_MAPS(ERROR_LOCK_VIOLATION, MSVCRT_EACCES); ERR_CASE(ERROR_FILE_NOT_FOUND) ERR_CASE(ERROR_NO_MORE_FILES) diff --git a/dlls/msvcrt/except.c b/dlls/msvcrt/except.c index 5de42db376c..9b254f858a7 100644 --- a/dlls/msvcrt/except.c +++ b/dlls/msvcrt/except.c @@ -117,19 +117,14 @@ static DWORD MSVCRT_nested_handler(PEXCEPTION_RECORD rec, /* Provided for VC++ binary compatibility only */ __ASM_GLOBAL_FUNC(_EH_prolog, - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") /* skip ret addr */ "pushl $-1\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") "pushl %eax\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") "pushl %fs:0\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") "movl %esp, %fs:0\n\t" "movl 12(%esp), %eax\n\t" "movl %ebp, 12(%esp)\n\t" "leal 12(%esp), %ebp\n\t" "pushl %eax\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") "ret") static void msvcrt_local_unwind2(MSVCRT_EXCEPTION_FRAME* frame, int trylevel, void *ebp) diff --git a/dlls/msvcrt/misc.c b/dlls/msvcrt/misc.c index 082c38bacc4..3d3c03b9de5 100644 --- a/dlls/msvcrt/misc.c +++ b/dlls/msvcrt/misc.c @@ -138,10 +138,7 @@ __ASM_GLOBAL_FUNC(_chkesp, "jnz 1f\n\t" "ret\n" "1:\tpushl %ebp\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %ebp,0\n\t") "movl %esp,%ebp\n\t" - __ASM_CFI(".cfi_def_cfa_register %ebp\n\t") "subl $12,%esp\n\t" "pushl %eax\n\t" "pushl %ecx\n\t" @@ -151,8 +148,6 @@ __ASM_GLOBAL_FUNC(_chkesp, "popl %ecx\n\t" "popl %eax\n\t" "leave\n\t" - __ASM_CFI(".cfi_def_cfa %esp,4\n\t") - __ASM_CFI(".cfi_same_value %ebp\n\t") "ret") void CDECL MSVCRT_chkesp_fail(void) diff --git a/dlls/msvfw32/Makefile.in b/dlls/msvfw32/Makefile.in index cb92c005ba7..8347fe88131 100644 --- a/dlls/msvfw32/Makefile.in +++ b/dlls/msvfw32/Makefile.in @@ -7,28 +7,11 @@ IMPORTLIB = msvfw32 IMPORTS = winmm version comctl32 user32 gdi32 advapi32 kernel32 ntdll C_SRCS = \ - drawdib.c \ mciwnd.c \ - msvideo_main.c + msvideo_main.c \ + drawdib.c -RC_SRCS = \ - msvfw32_Da.rc \ - msvfw32_De.rc \ - msvfw32_En.rc \ - msvfw32_Es.rc \ - msvfw32_Fr.rc \ - msvfw32_Hu.rc \ - msvfw32_Ko.rc \ - msvfw32_Lt.rc \ - msvfw32_Nl.rc \ - msvfw32_No.rc \ - msvfw32_Pl.rc \ - msvfw32_Pt.rc \ - msvfw32_Ru.rc \ - msvfw32_Si.rc \ - msvfw32_Sv.rc \ - msvfw32_Tr.rc \ - msvfw32_Zh.rc +RC_SRCS = rsrc.rc @MAKE_DLL_RULES@ diff --git a/dlls/msvfw32/msvfw32_Da.rc b/dlls/msvfw32/msvfw32_Da.rc index 20d60e23455..32b54892a75 100644 --- a/dlls/msvfw32/msvfw32_Da.rc +++ b/dlls/msvfw32/msvfw32_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 187, 95 diff --git a/dlls/msvfw32/msvfw32_De.rc b/dlls/msvfw32/msvfw32_De.rc index 051b7df382a..29b5f4b7187 100644 --- a/dlls/msvfw32/msvfw32_De.rc +++ b/dlls/msvfw32/msvfw32_De.rc @@ -17,10 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 187, 95 @@ -35,11 +31,11 @@ FONT 8, "MS Shell Dlg" COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP PUSHBUTTON "Kon&figurieren...",882,129,36,49,14 - PUSHBUTTON "&Über...",883,129,52,49,14 + PUSHBUTTON "&Über...",883,129,52,49,14 SCROLLBAR 884,9,44,111,9,WS_TABSTOP - LTEXT "Komprimierungsqualität:",886,9,34,80,8 + LTEXT "Komprimierungsqualität:",886,9,34,80,8 CONTROL "&Key Frame aller",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 EDITTEXT 888,78,60,22,12 @@ -52,5 +48,5 @@ FONT 8, "MS Shell Dlg" STRINGTABLE DISCARDABLE { - IDS_FULLFRAMES "Vollständige Frames (Unkomprimiert)" + IDS_FULLFRAMES "Vollständige Frames (Unkomprimiert)" } diff --git a/dlls/msvfw32/msvfw32_En.rc b/dlls/msvfw32/msvfw32_En.rc index f3ee7357196..1a563dd9780 100644 --- a/dlls/msvfw32/msvfw32_En.rc +++ b/dlls/msvfw32/msvfw32_En.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 187, 95 diff --git a/dlls/msvfw32/msvfw32_Es.rc b/dlls/msvfw32/msvfw32_Es.rc index 27453619dbd..aa4d3f0159b 100644 --- a/dlls/msvfw32/msvfw32_Es.rc +++ b/dlls/msvfw32/msvfw32_Es.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 187, 95 diff --git a/dlls/msvfw32/msvfw32_Fr.rc b/dlls/msvfw32/msvfw32_Fr.rc index 87d61cc0088..9318ee4b760 100644 --- a/dlls/msvfw32/msvfw32_Fr.rc +++ b/dlls/msvfw32/msvfw32_Fr.rc @@ -16,41 +16,36 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL -ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 208, 95 +ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 187, 95 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Compression vidéo" +CAPTION "Compression vidéo" FONT 8, "MS Shell Dlg" { - DEFPUSHBUTTON "OK",IDOK,150,2,49,14 - PUSHBUTTON "Annuler",IDCANCEL,150,18,49,14 + DEFPUSHBUTTON "OK",IDOK,129,2,49,14 + PUSHBUTTON "Annuler",IDCANCEL,129,18,49,14 - LTEXT "&Compresseur :",-1,9,6,131,8 - COMBOBOX 880,9,16,135,15,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + LTEXT "&Compresseur :",-1,9,6,105,8 + COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - PUSHBUTTON "Con&figurer...",882,150,36,49,14 - PUSHBUTTON "À &propos",883,150,52,49,14 + PUSHBUTTON "Con&figurer...",882,129,36,49,14 + PUSHBUTTON "À &propos",883,129,52,49,14 - SCROLLBAR 884,9,44,133,9,WS_TABSTOP + SCROLLBAR 884,9,44,111,9,WS_TABSTOP - LTEXT "&Qualité de compression :",886,9,34,131,8 + LTEXT "&Qualité de compression :",886,9,34,80,8 - CONTROL "Image &clé toutes les",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,77,12 - EDITTEXT 888,89,60,22,12 - LTEXT "images",889,115,63,26,10 + CONTROL "Image &clé toutes les",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 + EDITTEXT 888,78,60,22,12 + LTEXT "images",889,103,62,26,10 - CONTROL "&Débit de données",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,77,12 - EDITTEXT 895,89,76,22,12 - LTEXT "Kio/sec",896,115,78,26,10 + CONTROL "&Débit de données",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 + EDITTEXT 895,78,76,22,12 + LTEXT "Kio/sec",896,102,78,26,10 } STRINGTABLE DISCARDABLE { - IDS_FULLFRAMES "Images complètes (non compressées)" + IDS_FULLFRAMES "Images complètes (non compressées)" } diff --git a/dlls/msvfw32/msvfw32_Hu.rc b/dlls/msvfw32/msvfw32_Hu.rc index e77b67fd543..aa0eefcfc1c 100644 --- a/dlls/msvfw32/msvfw32_Hu.rc +++ b/dlls/msvfw32/msvfw32_Hu.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 187, 95 diff --git a/dlls/msvfw32/msvfw32_Ko.rc b/dlls/msvfw32/msvfw32_Ko.rc index 72e999d96f4..4d6527e93a2 100644 --- a/dlls/msvfw32/msvfw32_Ko.rc +++ b/dlls/msvfw32/msvfw32_Ko.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 187, 95 diff --git a/dlls/msvfw32/msvfw32_Lt.rc b/dlls/msvfw32/msvfw32_Lt.rc deleted file mode 100644 index c7432d3518f..00000000000 --- a/dlls/msvfw32/msvfw32_Lt.rc +++ /dev/null @@ -1,56 +0,0 @@ -/* - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "msvideo_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 192, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Vaizdų glaudinimas" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "Gerai",IDOK,129,2,54,14 - PUSHBUTTON "Atsisakyti",IDCANCEL,129,18,54,14 - - LTEXT "&Metodas:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "Kon&figūruoti...",882,129,36,54,14 - PUSHBUTTON "&Apie...",883,129,52,54,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "Glaudinimo &kokybė:",886,9,34,80,8 - - CONTROL "&Rakt. kadras kas",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "kadrų",889,103,62,26,10 - - CONTROL "&Duomenų sparta",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/sek",896,102,78,26,10 -} - -STRINGTABLE DISCARDABLE -{ - IDS_FULLFRAMES "Pilni kadrai (neglaudinti)" -} diff --git a/dlls/msvfw32/msvfw32_Nl.rc b/dlls/msvfw32/msvfw32_Nl.rc index d82f860c400..e1236f7c2c9 100644 --- a/dlls/msvfw32/msvfw32_Nl.rc +++ b/dlls/msvfw32/msvfw32_Nl.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 187, 95 diff --git a/dlls/msvfw32/msvfw32_No.rc b/dlls/msvfw32/msvfw32_No.rc index eb07aed3efb..41a24e393db 100644 --- a/dlls/msvfw32/msvfw32_No.rc +++ b/dlls/msvfw32/msvfw32_No.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 187, 95 diff --git a/dlls/msvfw32/msvfw32_Pl.rc b/dlls/msvfw32/msvfw32_Pl.rc index cb5a9eb6cb7..53ee33cf28e 100644 --- a/dlls/msvfw32/msvfw32_Pl.rc +++ b/dlls/msvfw32/msvfw32_Pl.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 207, 95 diff --git a/dlls/msvfw32/msvfw32_Pt.rc b/dlls/msvfw32/msvfw32_Pt.rc index efd31191ad8..0640870f3c3 100644 --- a/dlls/msvfw32/msvfw32_Pt.rc +++ b/dlls/msvfw32/msvfw32_Pt.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 187, 95 diff --git a/dlls/msvfw32/msvfw32_Ru.rc b/dlls/msvfw32/msvfw32_Ru.rc index 5b42d197df7..96c8a814d64 100644 --- a/dlls/msvfw32/msvfw32_Ru.rc +++ b/dlls/msvfw32/msvfw32_Ru.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 187, 95 diff --git a/dlls/msvfw32/msvfw32_Si.rc b/dlls/msvfw32/msvfw32_Si.rc index 93fb1757082..05d1ba588ef 100644 --- a/dlls/msvfw32/msvfw32_Si.rc +++ b/dlls/msvfw32/msvfw32_Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -53,3 +51,5 @@ STRINGTABLE DISCARDABLE { IDS_FULLFRAMES "Polne slike (nestisnjeno)" } + +#pragma code_page(default) diff --git a/dlls/msvfw32/msvfw32_Sv.rc b/dlls/msvfw32/msvfw32_Sv.rc index 2461fce601e..68f51677212 100644 --- a/dlls/msvfw32/msvfw32_Sv.rc +++ b/dlls/msvfw32/msvfw32_Sv.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 187, 95 diff --git a/dlls/msvfw32/msvfw32_Tr.rc b/dlls/msvfw32/msvfw32_Tr.rc index 09635095b5b..b9da7c20f0b 100644 --- a/dlls/msvfw32/msvfw32_Tr.rc +++ b/dlls/msvfw32/msvfw32_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT ICM_CHOOSE_COMPRESSOR DIALOG DISCARDABLE 36, 24, 187, 95 diff --git a/dlls/msvfw32/msvfw32_Zh.rc b/dlls/msvfw32/msvfw32_Zh.rc index 3ff0fc047f7..334fd6947f5 100644 --- a/dlls/msvfw32/msvfw32_Zh.rc +++ b/dlls/msvfw32/msvfw32_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvideo_private.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -90,3 +88,5 @@ STRINGTABLE DISCARDABLE { IDS_FULLFRAMES "全幀(未壓縮)" } + +#pragma code_page(default) diff --git a/dlls/msvfw32/msvideo_main.c b/dlls/msvfw32/msvideo_main.c index 6196fac7433..7c98a1613c9 100644 --- a/dlls/msvfw32/msvideo_main.c +++ b/dlls/msvfw32/msvideo_main.c @@ -91,92 +91,6 @@ BOOL WINAPI DllMain( HINSTANCE hinst, DWORD reason, LPVOID reserved ) return TRUE; } -/****************************************************************** - * MSVIDEO_SendMessage - * - * - */ -static LRESULT MSVIDEO_SendMessage(WINE_HIC* whic, UINT msg, DWORD_PTR lParam1, DWORD_PTR lParam2) -{ - LRESULT ret; - -#define XX(x) case x: TRACE("(%p,"#x",0x%08lx,0x%08lx)\n",whic,lParam1,lParam2); break - - switch (msg) { - /* DRV_* */ - XX(DRV_LOAD); - XX(DRV_ENABLE); - XX(DRV_OPEN); - XX(DRV_CLOSE); - XX(DRV_DISABLE); - XX(DRV_FREE); - /* ICM_RESERVED+X */ - XX(ICM_ABOUT); - XX(ICM_CONFIGURE); - XX(ICM_GET); - XX(ICM_GETINFO); - XX(ICM_GETDEFAULTQUALITY); - XX(ICM_GETQUALITY); - XX(ICM_GETSTATE); - XX(ICM_SETQUALITY); - XX(ICM_SET); - XX(ICM_SETSTATE); - /* ICM_USER+X */ - XX(ICM_COMPRESS_FRAMES_INFO); - XX(ICM_COMPRESS_GET_FORMAT); - XX(ICM_COMPRESS_GET_SIZE); - XX(ICM_COMPRESS_QUERY); - XX(ICM_COMPRESS_BEGIN); - XX(ICM_COMPRESS); - XX(ICM_COMPRESS_END); - XX(ICM_DECOMPRESS_GET_FORMAT); - XX(ICM_DECOMPRESS_QUERY); - XX(ICM_DECOMPRESS_BEGIN); - XX(ICM_DECOMPRESS); - XX(ICM_DECOMPRESS_END); - XX(ICM_DECOMPRESS_SET_PALETTE); - XX(ICM_DECOMPRESS_GET_PALETTE); - XX(ICM_DRAW_QUERY); - XX(ICM_DRAW_BEGIN); - XX(ICM_DRAW_GET_PALETTE); - XX(ICM_DRAW_START); - XX(ICM_DRAW_STOP); - XX(ICM_DRAW_END); - XX(ICM_DRAW_GETTIME); - XX(ICM_DRAW); - XX(ICM_DRAW_WINDOW); - XX(ICM_DRAW_SETTIME); - XX(ICM_DRAW_REALIZE); - XX(ICM_DRAW_FLUSH); - XX(ICM_DRAW_RENDERBUFFER); - XX(ICM_DRAW_START_PLAY); - XX(ICM_DRAW_STOP_PLAY); - XX(ICM_DRAW_SUGGESTFORMAT); - XX(ICM_DRAW_CHANGEPALETTE); - XX(ICM_GETBUFFERSWANTED); - XX(ICM_GETDEFAULTKEYFRAMERATE); - XX(ICM_DECOMPRESSEX_BEGIN); - XX(ICM_DECOMPRESSEX_QUERY); - XX(ICM_DECOMPRESSEX); - XX(ICM_DECOMPRESSEX_END); - XX(ICM_SET_STATUS_PROC); - default: - FIXME("(%p,0x%08x,0x%08lx,0x%08lx) unknown message\n",whic,msg,lParam1,lParam2); - } - -#undef XX - - if (whic->driverproc) { - /* dwDriverId parameter is the value returned by the DRV_OPEN */ - ret = whic->driverproc(whic->driverId, whic->hdrv, msg, lParam1, lParam2); - } else { - ret = SendDriverMessage(whic->hdrv, msg, lParam1, lParam2); - } - - TRACE(" -> 0x%08lx\n", ret); - return ret; -} - static int compare_fourcc(DWORD fcc1, DWORD fcc2) { char fcc_str1[4]; @@ -238,7 +152,7 @@ static BOOL enum_drivers(DWORD fccType, enum_handler_t handler, void* param) * * */ -static WINE_HIC* MSVIDEO_GetHicPtr(HIC hic) +WINE_HIC* MSVIDEO_GetHicPtr(HIC hic) { WINE_HIC* whic; @@ -1086,6 +1000,93 @@ void VFWAPI ICCompressorFree(PCOMPVARS pc) } } + +/****************************************************************** + * MSVIDEO_SendMessage + * + * + */ +LRESULT MSVIDEO_SendMessage(WINE_HIC* whic, UINT msg, DWORD_PTR lParam1, DWORD_PTR lParam2) +{ + LRESULT ret; + +#define XX(x) case x: TRACE("(%p,"#x",0x%08lx,0x%08lx)\n",whic,lParam1,lParam2); break + + switch (msg) { + /* DRV_* */ + XX(DRV_LOAD); + XX(DRV_ENABLE); + XX(DRV_OPEN); + XX(DRV_CLOSE); + XX(DRV_DISABLE); + XX(DRV_FREE); + /* ICM_RESERVED+X */ + XX(ICM_ABOUT); + XX(ICM_CONFIGURE); + XX(ICM_GET); + XX(ICM_GETINFO); + XX(ICM_GETDEFAULTQUALITY); + XX(ICM_GETQUALITY); + XX(ICM_GETSTATE); + XX(ICM_SETQUALITY); + XX(ICM_SET); + XX(ICM_SETSTATE); + /* ICM_USER+X */ + XX(ICM_COMPRESS_FRAMES_INFO); + XX(ICM_COMPRESS_GET_FORMAT); + XX(ICM_COMPRESS_GET_SIZE); + XX(ICM_COMPRESS_QUERY); + XX(ICM_COMPRESS_BEGIN); + XX(ICM_COMPRESS); + XX(ICM_COMPRESS_END); + XX(ICM_DECOMPRESS_GET_FORMAT); + XX(ICM_DECOMPRESS_QUERY); + XX(ICM_DECOMPRESS_BEGIN); + XX(ICM_DECOMPRESS); + XX(ICM_DECOMPRESS_END); + XX(ICM_DECOMPRESS_SET_PALETTE); + XX(ICM_DECOMPRESS_GET_PALETTE); + XX(ICM_DRAW_QUERY); + XX(ICM_DRAW_BEGIN); + XX(ICM_DRAW_GET_PALETTE); + XX(ICM_DRAW_START); + XX(ICM_DRAW_STOP); + XX(ICM_DRAW_END); + XX(ICM_DRAW_GETTIME); + XX(ICM_DRAW); + XX(ICM_DRAW_WINDOW); + XX(ICM_DRAW_SETTIME); + XX(ICM_DRAW_REALIZE); + XX(ICM_DRAW_FLUSH); + XX(ICM_DRAW_RENDERBUFFER); + XX(ICM_DRAW_START_PLAY); + XX(ICM_DRAW_STOP_PLAY); + XX(ICM_DRAW_SUGGESTFORMAT); + XX(ICM_DRAW_CHANGEPALETTE); + XX(ICM_GETBUFFERSWANTED); + XX(ICM_GETDEFAULTKEYFRAMERATE); + XX(ICM_DECOMPRESSEX_BEGIN); + XX(ICM_DECOMPRESSEX_QUERY); + XX(ICM_DECOMPRESSEX); + XX(ICM_DECOMPRESSEX_END); + XX(ICM_SET_STATUS_PROC); + default: + FIXME("(%p,0x%08x,0x%08lx,0x%08lx) unknown message\n",whic,msg,lParam1,lParam2); + } + +#undef XX + + if (whic->driverproc) { + /* dwDriverId parameter is the value returned by the DRV_OPEN */ + ret = whic->driverproc(whic->driverId, whic->hdrv, msg, lParam1, lParam2); + } else { + ret = SendDriverMessage(whic->hdrv, msg, lParam1, lParam2); + } + + TRACE(" -> 0x%08lx\n", ret); + return ret; +} + /*********************************************************************** * ICSendMessage [MSVFW32.@] */ diff --git a/dlls/msvfw32/msvideo_private.h b/dlls/msvfw32/msvideo_private.h index ea0566bb54c..d1e5f8d0d65 100644 --- a/dlls/msvfw32/msvideo_private.h +++ b/dlls/msvfw32/msvideo_private.h @@ -19,9 +19,6 @@ #ifndef __WINE_MSVIDEO_PRIVATE_H #define __WINE_MSVIDEO_PRIVATE_H -#include -#include - #define ICM_CHOOSE_COMPRESSOR 1 #define IDC_COMP_LIST 880 #define IDS_FULLFRAMES 901 @@ -44,6 +41,7 @@ typedef struct tagWINE_HIC { struct tagWINE_HIC* next; } WINE_HIC; +LRESULT MSVIDEO_SendMessage(WINE_HIC*, UINT, DWORD_PTR, DWORD_PTR); #define IDC_CONFIGURE 882 #define IDC_ABOUT 883 diff --git a/dlls/msvfw32/rsrc.rc b/dlls/msvfw32/rsrc.rc new file mode 100644 index 00000000000..512f341d6ca --- /dev/null +++ b/dlls/msvfw32/rsrc.rc @@ -0,0 +1,38 @@ +/* + * Copyright 2005 Dmitry Timoshkov + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winuser.h" +#include "msvideo_private.h" + +#include "msvfw32_Da.rc" +#include "msvfw32_De.rc" +#include "msvfw32_En.rc" +#include "msvfw32_Es.rc" +#include "msvfw32_Fr.rc" +#include "msvfw32_Hu.rc" +#include "msvfw32_Ko.rc" +#include "msvfw32_Nl.rc" +#include "msvfw32_No.rc" +#include "msvfw32_Pl.rc" +#include "msvfw32_Pt.rc" +#include "msvfw32_Ru.rc" +#include "msvfw32_Si.rc" +#include "msvfw32_Sv.rc" +#include "msvfw32_Tr.rc" +#include "msvfw32_Zh.rc" diff --git a/dlls/msvidc32/Makefile.in b/dlls/msvidc32/Makefile.in index 3bc63a8c1ee..3f9be06bbe5 100644 --- a/dlls/msvidc32/Makefile.in +++ b/dlls/msvidc32/Makefile.in @@ -8,24 +8,7 @@ IMPORTS = user32 kernel32 C_SRCS = \ msvideo1.c -RC_SRCS = \ - msvidc32_Da.rc \ - msvidc32_De.rc \ - msvidc32_En.rc \ - msvidc32_Fr.rc \ - msvidc32_Hu.rc \ - msvidc32_Ja.rc \ - msvidc32_Ko.rc \ - msvidc32_Lt.rc \ - msvidc32_Nl.rc \ - msvidc32_No.rc \ - msvidc32_Pl.rc \ - msvidc32_Pt.rc \ - msvidc32_Ro.rc \ - msvidc32_Ru.rc \ - msvidc32_Si.rc \ - msvidc32_Sv.rc \ - msvidc32_Tr.rc +RC_SRCS = rsrc.rc @MAKE_DLL_RULES@ diff --git a/dlls/msvidc32/msvidc32_Da.rc b/dlls/msvidc32/msvidc32_Da.rc index 0b286069358..50ae3f6f5a0 100644 --- a/dlls/msvidc32/msvidc32_Da.rc +++ b/dlls/msvidc32/msvidc32_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msvidc32/msvidc32_De.rc b/dlls/msvidc32/msvidc32_De.rc index 1dc777b8497..1d0de70d0db 100644 --- a/dlls/msvidc32/msvidc32_De.rc +++ b/dlls/msvidc32/msvidc32_De.rc @@ -17,10 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/msvidc32/msvidc32_En.rc b/dlls/msvidc32/msvidc32_En.rc index 8ac6b59373f..93c8518ec9d 100644 --- a/dlls/msvidc32/msvidc32_En.rc +++ b/dlls/msvidc32/msvidc32_En.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msvidc32/msvidc32_Fr.rc b/dlls/msvidc32/msvidc32_Fr.rc index 8843e0d6b10..3592f31331c 100644 --- a/dlls/msvidc32/msvidc32_Fr.rc +++ b/dlls/msvidc32/msvidc32_Fr.rc @@ -16,15 +16,10 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { IDS_NAME "MS-CRAM" - IDS_DESCRIPTION "Codec vidéo Wine Video 1" + IDS_DESCRIPTION "codec vidéo Wine Video 1" } diff --git a/dlls/msvidc32/msvidc32_Hu.rc b/dlls/msvidc32/msvidc32_Hu.rc index 2949bae96d1..c031963f495 100644 --- a/dlls/msvidc32/msvidc32_Hu.rc +++ b/dlls/msvidc32/msvidc32_Hu.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msvidc32/msvidc32_Ja.rc b/dlls/msvidc32/msvidc32_Ja.rc deleted file mode 100644 index 3d09c760b2f..00000000000 --- a/dlls/msvidc32/msvidc32_Ja.rc +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright 2009 Aric Stewart, CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "msvidc32_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT - -STRINGTABLE DISCARDABLE -{ - IDS_NAME "MS-CRAM" - IDS_DESCRIPTION "Wine ビデオ 1 ビデオコーデック" -} diff --git a/dlls/msvidc32/msvidc32_Ko.rc b/dlls/msvidc32/msvidc32_Ko.rc index e95cc9405e2..11c18c1134f 100644 --- a/dlls/msvidc32/msvidc32_Ko.rc +++ b/dlls/msvidc32/msvidc32_Ko.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msvidc32/msvidc32_Lt.rc b/dlls/msvidc32/msvidc32_Lt.rc deleted file mode 100644 index ee75ead8bcc..00000000000 --- a/dlls/msvidc32/msvidc32_Lt.rc +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "msvidc32_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_NAME "MS-CRAM" - IDS_DESCRIPTION "Wine Video 1 vaizdo kodekas" -} diff --git a/dlls/msvidc32/msvidc32_Nl.rc b/dlls/msvidc32/msvidc32_Nl.rc index c11ca47e30d..b68d3eff7a0 100644 --- a/dlls/msvidc32/msvidc32_Nl.rc +++ b/dlls/msvidc32/msvidc32_Nl.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/msvidc32/msvidc32_No.rc b/dlls/msvidc32/msvidc32_No.rc index fa2a96f5760..6d27778dfcc 100644 --- a/dlls/msvidc32/msvidc32_No.rc +++ b/dlls/msvidc32/msvidc32_No.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE DISCARDABLE diff --git a/dlls/msvidc32/msvidc32_Pl.rc b/dlls/msvidc32/msvidc32_Pl.rc index 221c41eb812..af39271d3b1 100644 --- a/dlls/msvidc32/msvidc32_Pl.rc +++ b/dlls/msvidc32/msvidc32_Pl.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msvidc32/msvidc32_Pt.rc b/dlls/msvidc32/msvidc32_Pt.rc index ee0eed48b8b..8dcda922a39 100644 --- a/dlls/msvidc32/msvidc32_Pt.rc +++ b/dlls/msvidc32/msvidc32_Pt.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/msvidc32/msvidc32_Ro.rc b/dlls/msvidc32/msvidc32_Ro.rc index c001dd4f2c0..fa7584a7dfd 100644 --- a/dlls/msvidc32/msvidc32_Ro.rc +++ b/dlls/msvidc32/msvidc32_Ro.rc @@ -17,10 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - -#pragma code_page(65001) - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/msvidc32/msvidc32_Ru.rc b/dlls/msvidc32/msvidc32_Ru.rc index 1f1adc5135e..2c84bff4da4 100644 --- a/dlls/msvidc32/msvidc32_Ru.rc +++ b/dlls/msvidc32/msvidc32_Ru.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msvidc32/msvidc32_Si.rc b/dlls/msvidc32/msvidc32_Si.rc index 19d392fccd3..060ad082142 100644 --- a/dlls/msvidc32/msvidc32_Si.rc +++ b/dlls/msvidc32/msvidc32_Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -27,3 +25,5 @@ STRINGTABLE DISCARDABLE IDS_NAME "MS-CRAM" IDS_DESCRIPTION "Wine Video 1 video kodek" } + +#pragma code_page(default) diff --git a/dlls/msvidc32/msvidc32_Sv.rc b/dlls/msvidc32/msvidc32_Sv.rc index 7c9b0bc0535..1f4770d7a80 100644 --- a/dlls/msvidc32/msvidc32_Sv.rc +++ b/dlls/msvidc32/msvidc32_Sv.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/msvidc32/msvidc32_Tr.rc b/dlls/msvidc32/msvidc32_Tr.rc index d4b882bf715..2353b0c542e 100644 --- a/dlls/msvidc32/msvidc32_Tr.rc +++ b/dlls/msvidc32/msvidc32_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "msvidc32_private.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/msvidc32/msvidc32_private.h b/dlls/msvidc32/msvidc32_private.h index 590600e232b..b47c6e6f556 100644 --- a/dlls/msvidc32/msvidc32_private.h +++ b/dlls/msvidc32/msvidc32_private.h @@ -19,8 +19,6 @@ #ifndef __MSVIDC32_PRIVATE_H #define __MSVIDC32_PRIVATE_H -#include - #define IDS_NAME 100 #define IDS_DESCRIPTION 101 diff --git a/dlls/msvidc32/rsrc.rc b/dlls/msvidc32/rsrc.rc new file mode 100644 index 00000000000..f7f7630c9a9 --- /dev/null +++ b/dlls/msvidc32/rsrc.rc @@ -0,0 +1,36 @@ +/* + * Copyright 2005 Dmitry Timoshkov + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "msvidc32_private.h" + +#include "msvidc32_Da.rc" +#include "msvidc32_De.rc" +#include "msvidc32_Fr.rc" +#include "msvidc32_En.rc" +#include "msvidc32_Hu.rc" +#include "msvidc32_Ko.rc" +#include "msvidc32_Nl.rc" +#include "msvidc32_No.rc" +#include "msvidc32_Pl.rc" +#include "msvidc32_Pt.rc" +#include "msvidc32_Ro.rc" +#include "msvidc32_Ru.rc" +#include "msvidc32_Si.rc" +#include "msvidc32_Sv.rc" +#include "msvidc32_Tr.rc" diff --git a/dlls/msvideo.dll16/Makefile.in b/dlls/msvideo.dll16/Makefile.in index 92429ec1eae..64a093bf56d 100644 --- a/dlls/msvideo.dll16/Makefile.in +++ b/dlls/msvideo.dll16/Makefile.in @@ -7,6 +7,8 @@ IMPORTS = msvfw32 version advapi32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,msvfw32.dll +SPEC_SRCS = msvideo.dll16.spec + C_SRCS = msvideo16.c @MAKE_DLL_RULES@ diff --git a/dlls/mswsock/version.rc b/dlls/mswsock/version.rc index 1408b9913e9..09dfc5d54e5 100644 --- a/dlls/mswsock/version.rc +++ b/dlls/mswsock/version.rc @@ -1,6 +1,6 @@ /* * Copyright 2003 Francois Gouget (for CodeWeavers) - * Copyright 2003 André Johansen + * Copyright 2003 André Johansen * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public diff --git a/dlls/ntdll/directory.c b/dlls/ntdll/directory.c index bccfba6aa26..41880f4a12e 100644 --- a/dlls/ntdll/directory.c +++ b/dlls/ntdll/directory.c @@ -2130,29 +2130,6 @@ done: /****************************************************************** - * RtlWow64EnableFsRedirection (NTDLL.@) - */ -NTSTATUS WINAPI RtlWow64EnableFsRedirection( BOOLEAN enable ) -{ - if (!is_wow64) return STATUS_NOT_IMPLEMENTED; - ntdll_get_thread_data()->wow64_redir = enable; - return STATUS_SUCCESS; -} - - -/****************************************************************** - * RtlWow64EnableFsRedirectionEx (NTDLL.@) - */ -NTSTATUS WINAPI RtlWow64EnableFsRedirectionEx( ULONG enable, ULONG *old_value ) -{ - if (!is_wow64) return STATUS_NOT_IMPLEMENTED; - *old_value = ntdll_get_thread_data()->wow64_redir; - ntdll_get_thread_data()->wow64_redir = enable; - return STATUS_SUCCESS; -} - - -/****************************************************************** * RtlDoesFileExists_U (NTDLL.@) */ BOOLEAN WINAPI RtlDoesFileExists_U(LPCWSTR file_name) diff --git a/dlls/ntdll/heap.c b/dlls/ntdll/heap.c index b721142a307..6c04261b5d7 100644 --- a/dlls/ntdll/heap.c +++ b/dlls/ntdll/heap.c @@ -92,8 +92,6 @@ typedef struct #define LARGE_ALIGNMENT 16 /* large blocks have stricter alignment */ #define ARENA_OFFSET (ALIGNMENT - sizeof(ARENA_INUSE)) -C_ASSERT( sizeof(ARENA_LARGE) % LARGE_ALIGNMENT == 0 ); - #define ROUND_SIZE(size) ((((size) + ALIGNMENT - 1) & ~(ALIGNMENT-1)) + ARENA_OFFSET) #define QUIET 1 /* Suppress messages */ @@ -126,7 +124,6 @@ typedef struct tagSUBHEAP { void *base; /* Base address of the sub-heap memory block */ SIZE_T size; /* Size of the whole sub-heap */ - SIZE_T min_commit; /* Minimum committed size */ SIZE_T commitSize; /* Committed size of the sub-heap */ struct list entry; /* Entry in sub-heap list */ struct tagHEAP *heap; /* Main heap structure */ @@ -148,7 +145,7 @@ typedef struct tagHEAP SIZE_T grow_size; /* Size of next subheap for growing heap */ DWORD magic; /* Magic number */ RTL_CRITICAL_SECTION critSection; /* Critical section for serialization */ - FREE_LIST_ENTRY *freeList; /* Free lists */ + FREE_LIST_ENTRY freeList[HEAP_NB_FREE_LISTS] DECLSPEC_ALIGN(8); /* Free lists */ } HEAP; #define HEAP_MAGIC ((DWORD)('H' | ('E'<<8) | ('A'<<16) | ('P'<<24))) @@ -492,7 +489,6 @@ static inline BOOL HEAP_Decommit( SUBHEAP *subheap, void *ptr ) /* round to next block and add one full block */ size = ((size + COMMIT_MASK) & ~COMMIT_MASK) + COMMIT_MASK + 1; - size = max( size, subheap->min_commit ); if (size >= subheap->commitSize) return TRUE; decommit_size = subheap->commitSize - size; addr = (char *)subheap->base + size; @@ -648,7 +644,7 @@ static void *allocate_large_block( HEAP *heap, DWORD flags, SIZE_T size ) LPVOID address = NULL; if (block_size < size) return NULL; /* overflow */ - if (NtAllocateVirtualMemory( NtCurrentProcess(), &address, 5, + if (NtAllocateVirtualMemory( NtCurrentProcess(), &address, 0, &block_size, MEM_COMMIT, get_protection_type( flags ) )) { WARN("Could not allocate block for %08lx bytes\n", size ); @@ -802,7 +798,6 @@ static SUBHEAP *HEAP_CreateSubHeap( HEAP *heap, LPVOID address, DWORD flags, subheap->base = address; subheap->heap = heap; subheap->size = totalSize; - subheap->min_commit = 0x10000; subheap->commitSize = commitSize; subheap->magic = SUBHEAP_MAGIC; subheap->headerSize = ROUND_SIZE( sizeof(SUBHEAP) ); @@ -823,7 +818,6 @@ static SUBHEAP *HEAP_CreateSubHeap( HEAP *heap, LPVOID address, DWORD flags, subheap->base = address; subheap->heap = heap; subheap->size = totalSize; - subheap->min_commit = commitSize; subheap->commitSize = commitSize; subheap->magic = SUBHEAP_MAGIC; subheap->headerSize = ROUND_SIZE( sizeof(HEAP) ); @@ -831,8 +825,6 @@ static SUBHEAP *HEAP_CreateSubHeap( HEAP *heap, LPVOID address, DWORD flags, /* Build the free lists */ - heap->freeList = (FREE_LIST_ENTRY *)((char *)heap + subheap->headerSize); - subheap->headerSize += HEAP_NB_FREE_LISTS * sizeof(FREE_LIST_ENTRY); list_init( &heap->freeList[0].arena.entry ); for (i = 0, pEntry = heap->freeList; i < HEAP_NB_FREE_LISTS; i++, pEntry++) { @@ -930,18 +922,11 @@ static ARENA_FREE *HEAP_FindFreeBlock( HEAP *heap, SIZE_T size, total_size = size + ROUND_SIZE(sizeof(SUBHEAP)) + sizeof(ARENA_INUSE) + sizeof(ARENA_FREE); if (total_size < size) return NULL; /* overflow */ - if ((subheap = HEAP_CreateSubHeap( heap, NULL, heap->flags, total_size, - max( heap->grow_size, total_size ) ))) - { - if (heap->grow_size < 128 * 1024 * 1024) heap->grow_size *= 2; - } - else while (!subheap) /* shrink the grow size again if we are running out of space */ - { - if (heap->grow_size <= total_size || heap->grow_size <= 4 * 1024 * 1024) return NULL; - heap->grow_size /= 2; - subheap = HEAP_CreateSubHeap( heap, NULL, heap->flags, total_size, - max( heap->grow_size, total_size ) ); - } + if (!(subheap = HEAP_CreateSubHeap( heap, NULL, heap->flags, total_size, + max( heap->grow_size, total_size ) ))) + return NULL; + + if (heap->grow_size < 128 * 1024 * 1024) heap->grow_size *= 2; TRACE("created new sub-heap %p of %08lx bytes for heap %p\n", subheap, subheap->size, heap ); @@ -1279,6 +1264,9 @@ HANDLE WINAPI RtlCreateHeap( ULONG flags, PVOID addr, SIZE_T totalSize, SIZE_T c { processHeap = subheap->heap; /* assume the first heap we create is the process main heap */ list_init( &processHeap->entry ); + /* make sure structure alignment is correct */ + assert( (ULONG_PTR)processHeap->freeList % ALIGNMENT == ARENA_OFFSET ); + assert( sizeof(ARENA_LARGE) % LARGE_ALIGNMENT == 0 ); } return subheap->heap; diff --git a/dlls/ntdll/loader.c b/dlls/ntdll/loader.c index aa9395e4b79..166766b8ee9 100644 --- a/dlls/ntdll/loader.c +++ b/dlls/ntdll/loader.c @@ -148,12 +148,8 @@ static inline void ascii_to_unicode( WCHAR *dst, const char *src, size_t len ) extern BOOL call_dll_entry_point( DLLENTRYPROC proc, void *module, UINT reason, void *reserved ); __ASM_GLOBAL_FUNC(call_dll_entry_point, "pushl %ebp\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %ebp,0\n\t") "movl %esp,%ebp\n\t" - __ASM_CFI(".cfi_def_cfa_register %ebp\n\t") "pushl %ebx\n\t" - __ASM_CFI(".cfi_rel_offset %ebx,-4\n\t") "subl $8,%esp\n\t" "pushl 20(%ebp)\n\t" "pushl 16(%ebp)\n\t" @@ -162,10 +158,7 @@ __ASM_GLOBAL_FUNC(call_dll_entry_point, "call *%eax\n\t" "leal -4(%ebp),%esp\n\t" "popl %ebx\n\t" - __ASM_CFI(".cfi_same_value %ebx\n\t") "popl %ebp\n\t" - __ASM_CFI(".cfi_def_cfa %esp,4\n\t") - __ASM_CFI(".cfi_same_value %ebp\n\t") "ret" ) #else /* __i386__ */ static inline BOOL call_dll_entry_point( DLLENTRYPROC proc, void *module, @@ -2477,11 +2470,11 @@ void WINAPI LdrInitializeThunk( ULONG unknown1, ULONG unknown2, ULONG unknown3, if ((status = fixup_imports( wm, load_path )) != STATUS_SUCCESS) goto error; if ((status = alloc_process_tls()) != STATUS_SUCCESS) goto error; if ((status = alloc_thread_tls()) != STATUS_SUCCESS) goto error; + if (nt->FileHeader.Characteristics & IMAGE_FILE_LARGE_ADDRESS_AWARE) VIRTUAL_UseLargeAddressSpace(); status = wine_call_on_stack( attach_process_dlls, wm, NtCurrentTeb()->Tib.StackBase ); if (status != STATUS_SUCCESS) goto error; - virtual_release_address_space( nt->FileHeader.Characteristics & IMAGE_FILE_LARGE_ADDRESS_AWARE ); virtual_clear_thread_stack(); return; diff --git a/dlls/ntdll/nt.c b/dlls/ntdll/nt.c index c7d931c2f42..89d796d2dcc 100644 --- a/dlls/ntdll/nt.c +++ b/dlls/ntdll/nt.c @@ -321,7 +321,7 @@ NTSTATUS WINAPI NtQueryInformationToken( struct token_groups *tg = buffer; unsigned int *attr = (unsigned int *)(tg + 1); ULONG i; - const int non_sid_portion = (sizeof(struct token_groups) + tg->count * sizeof(unsigned int)); + const int non_sid_portion = (sizeof(struct token_groups) + tg->count * sizeof(unsigned long)); SID *sids = (SID *)((char *)tokeninfo + FIELD_OFFSET( TOKEN_GROUPS, Groups[tg->count] )); ULONG needed_bytes = FIELD_OFFSET( TOKEN_GROUPS, Groups[tg->count] ) + reply->user_len - non_sid_portion; @@ -1328,15 +1328,6 @@ NTSTATUS WINAPI NtPowerInformation( PowerCaps->DefaultLowLatencyWake = PowerSystemUnspecified; return STATUS_SUCCESS; } - case SystemExecutionState: { - PULONG ExecutionState = lpOutputBuffer; - FIXME("semi-stub: SystemExecutionState\n"); - if (lpInputBuffer != NULL) - return STATUS_INVALID_PARAMETER; - /* FIXME: The actual state should be the value set by SetThreadExecutionState which is not currently implemented. */ - *ExecutionState = ES_USER_PRESENT; - return STATUS_SUCCESS; - } default: /* FIXME: Needed by .NET Framework */ WARN("Unimplemented NtPowerInformation action: %d\n", InformationLevel); diff --git a/dlls/ntdll/ntdll.spec b/dlls/ntdll/ntdll.spec index 03686b28209..acc69db53dd 100644 --- a/dlls/ntdll/ntdll.spec +++ b/dlls/ntdll/ntdll.spec @@ -913,8 +913,6 @@ @ stdcall -arch=x86_64 RtlVirtualUnwind(long long long ptr ptr ptr ptr ptr) @ stub RtlWalkFrameChain @ stdcall RtlWalkHeap(long ptr) -@ stdcall RtlWow64EnableFsRedirection(long) -@ stdcall RtlWow64EnableFsRedirectionEx(long ptr) @ stub RtlWriteMemoryStream @ stdcall RtlWriteRegistryValue(long ptr ptr long ptr long) @ stub RtlZeroHeap diff --git a/dlls/ntdll/ntdll_misc.h b/dlls/ntdll/ntdll_misc.h index ea2234afe33..34ae2d62d55 100644 --- a/dlls/ntdll/ntdll_misc.h +++ b/dlls/ntdll/ntdll_misc.h @@ -72,7 +72,6 @@ extern void virtual_init_threading(void); /* server support */ extern timeout_t server_start_time; extern unsigned int server_cpus; -extern int is_wow64; extern void server_init_process(void); extern NTSTATUS server_init_process_done(void); extern size_t server_init_thread( void *entry_point ); @@ -86,7 +85,6 @@ extern void server_leave_uninterrupted_section( RTL_CRITICAL_SECTION *cs, sigset extern int server_remove_fd_from_cache( HANDLE handle ); extern int server_get_unix_fd( HANDLE handle, unsigned int access, int *unix_fd, int *needs_close, enum server_fd_type *type, unsigned int *options ); -extern int server_pipe( int fd[2] ); /* security descriptors */ NTSTATUS NTDLL_create_struct_sd(PSECURITY_DESCRIPTOR nt_sd, struct security_descriptor **server_sd, @@ -152,7 +150,7 @@ extern NTSTATUS virtual_handle_fault( LPCVOID addr, DWORD err ); extern BOOL virtual_check_buffer_for_read( const void *ptr, SIZE_T size ); extern BOOL virtual_check_buffer_for_write( void *ptr, SIZE_T size ); extern void VIRTUAL_SetForceExec( BOOL enable ); -extern void virtual_release_address_space( BOOL free_high_mem ); +extern void VIRTUAL_UseLargeAddressSpace(void); extern struct _KUSER_SHARED_DATA *user_shared_data; /* completion */ @@ -199,9 +197,8 @@ struct ntdll_thread_data int request_fd; /* 1e0/310 fd for sending server requests */ int reply_fd; /* 1e4/314 fd for receiving server replies */ int wait_fd[2]; /* 1e8/318 fd for sleeping server requests */ - BOOL wow64_redir; /* 1f0/320 Wow64 filesystem redirection flag */ - void *vm86_ptr; /* 1f4/328 data for vm86 mode */ - pthread_t pthread_id; /* 1f8/330 pthread thread id */ + void *vm86_ptr; /* 1f0/320 data for vm86 mode */ + pthread_t pthread_id; /* 1f4/328 pthread thread id */ }; static inline struct ntdll_thread_data *ntdll_get_thread_data(void) diff --git a/dlls/ntdll/process.c b/dlls/ntdll/process.c index 62585692724..c129e0a64b6 100644 --- a/dlls/ntdll/process.c +++ b/dlls/ntdll/process.c @@ -307,19 +307,11 @@ NTSTATUS WINAPI NtQueryInformationProcess( case ProcessWow64Information: if (ProcessInformationLength == sizeof(DWORD)) { - DWORD val = 0; - - if (ProcessHandle == GetCurrentProcess()) val = is_wow64; - else if (server_cpus & (1 << CPU_x86_64)) - { - SERVER_START_REQ( get_process_info ) - { - req->handle = wine_server_obj_handle( ProcessHandle ); - if (!(ret = wine_server_call( req ))) val = (reply->cpu != CPU_x86_64); - } - SERVER_END_REQ; - } - *(DWORD *)ProcessInformation = val; +#ifdef __i386__ + *(DWORD *)ProcessInformation = (server_cpus & (1 << CPU_x86_64)) != 0; +#else + *(DWORD *)ProcessInformation = FALSE; +#endif len = sizeof(DWORD); } else ret = STATUS_INFO_LENGTH_MISMATCH; diff --git a/dlls/ntdll/relay.c b/dlls/ntdll/relay.c index 1981e51292d..0f74c410846 100644 --- a/dlls/ntdll/relay.c +++ b/dlls/ntdll/relay.c @@ -320,35 +320,26 @@ static inline void RELAY_PrintArgs( const INT_PTR *args, int nb_args, unsigned i extern LONGLONG CDECL call_entry_point( void *func, int nb_args, const INT_PTR *args ); #ifdef __i386__ __ASM_GLOBAL_FUNC( call_entry_point, - "pushl %ebp\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %ebp,0\n\t") - "movl %esp,%ebp\n\t" - __ASM_CFI(".cfi_def_cfa_register %ebp\n\t") - "pushl %esi\n\t" - __ASM_CFI(".cfi_rel_offset %esi,-4\n\t") - "pushl %edi\n\t" - __ASM_CFI(".cfi_rel_offset %edi,-8\n\t") - "movl 12(%ebp),%edx\n\t" - "shll $2,%edx\n\t" - "jz 1f\n\t" - "subl %edx,%esp\n\t" - "andl $~15,%esp\n\t" - "movl 12(%ebp),%ecx\n\t" - "movl 16(%ebp),%esi\n\t" - "movl %esp,%edi\n\t" - "cld\n\t" - "rep; movsl\n" - "1:\tcall *8(%ebp)\n\t" - "leal -8(%ebp),%esp\n\t" - "popl %edi\n\t" - __ASM_CFI(".cfi_same_value %edi\n\t") - "popl %esi\n\t" - __ASM_CFI(".cfi_same_value %esi\n\t") - "popl %ebp\n\t" - __ASM_CFI(".cfi_def_cfa %esp,4\n\t") - __ASM_CFI(".cfi_same_value %ebp\n\t") - "ret" ) + "\tpushl %ebp\n" + "\tmovl %esp,%ebp\n" + "\tpushl %esi\n" + "\tpushl %edi\n" + "\tmovl 12(%ebp),%edx\n" + "\tshll $2,%edx\n" + "\tjz 1f\n" + "\tsubl %edx,%esp\n" + "\tandl $~15,%esp\n" + "\tmovl 12(%ebp),%ecx\n" + "\tmovl 16(%ebp),%esi\n" + "\tmovl %esp,%edi\n" + "\tcld\n" + "\trep; movsl\n" + "1:\tcall *8(%ebp)\n" + "\tleal -8(%ebp),%esp\n" + "\tpopl %edi\n" + "\tpopl %esi\n" + "\tpopl %ebp\n" + "\tret" ) #else __ASM_GLOBAL_FUNC( call_entry_point, "pushq %rbp\n\t" diff --git a/dlls/ntdll/server.c b/dlls/ntdll/server.c index 1eea402debd..a7bc49392fd 100644 --- a/dlls/ntdll/server.c +++ b/dlls/ntdll/server.c @@ -73,10 +73,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(server); #define SCM_RIGHTS 1 #endif -#ifndef MSG_CMSG_CLOEXEC -#define MSG_CMSG_CLOEXEC 0 -#endif - #define SOCKETNAME "socket" /* name of the socket file */ #define LOCKNAME "lock" /* name of the lock file */ @@ -95,7 +91,6 @@ static const enum cpu_type client_cpu = CPU_SPARC; #endif unsigned int server_cpus = 0; -int is_wow64 = FALSE; #ifndef HAVE_STRUCT_MSGHDR_MSG_ACCRIGHTS /* data structure used to pass an fd with sendmsg/recvmsg */ @@ -413,12 +408,12 @@ static int receive_fd( obj_handle_t *handle ) for (;;) { - if ((ret = recvmsg( fd_socket, &msghdr, MSG_CMSG_CLOEXEC )) > 0) + if ((ret = recvmsg( fd_socket, &msghdr, 0 )) > 0) { #ifndef HAVE_STRUCT_MSGHDR_MSG_ACCRIGHTS fd = cmsg.fd; #endif - if (fd != -1) fcntl( fd, F_SETFD, FD_CLOEXEC ); /* in case MSG_CMSG_CLOEXEC is not supported */ + if (fd != -1) fcntl( fd, F_SETFD, 1 ); /* set close on exec flag */ return fd; } if (!ret) break; @@ -664,32 +659,6 @@ void CDECL wine_server_release_fd( HANDLE handle, int unix_fd ) /*********************************************************************** - * server_pipe - * - * Create a pipe for communicating with the server. - */ -int server_pipe( int fd[2] ) -{ - int ret; -#ifdef HAVE_PIPE2 - static int have_pipe2 = 1; - - if (have_pipe2) - { - if (!(ret = pipe2( fd, O_CLOEXEC ))) return ret; - if (errno == ENOSYS || errno == EINVAL) have_pipe2 = 0; /* don't try again */ - } -#endif - if (!(ret = pipe( fd ))) - { - fcntl( fd[0], F_SETFD, FD_CLOEXEC ); - fcntl( fd[1], F_SETFD, FD_CLOEXEC ); - } - return ret; -} - - -/*********************************************************************** * start_server * * Start a new wine server. @@ -1056,13 +1025,18 @@ size_t server_init_thread( void *entry_point ) sigaction( SIGCHLD, &sig_act, NULL ); /* create the server->client communication pipes */ - if (server_pipe( reply_pipe ) == -1) server_protocol_perror( "pipe" ); - if (server_pipe( ntdll_get_thread_data()->wait_fd ) == -1) server_protocol_perror( "pipe" ); + if (pipe( reply_pipe ) == -1) server_protocol_perror( "pipe" ); + if (pipe( ntdll_get_thread_data()->wait_fd ) == -1) server_protocol_perror( "pipe" ); wine_server_send_fd( reply_pipe[1] ); wine_server_send_fd( ntdll_get_thread_data()->wait_fd[1] ); ntdll_get_thread_data()->reply_fd = reply_pipe[0]; close( reply_pipe[1] ); + /* set close on exec flag */ + fcntl( ntdll_get_thread_data()->reply_fd, F_SETFD, 1 ); + fcntl( ntdll_get_thread_data()->wait_fd[0], F_SETFD, 1 ); + fcntl( ntdll_get_thread_data()->wait_fd[1], F_SETFD, 1 ); + SERVER_START_REQ( init_thread ) { req->unix_pid = getpid(); @@ -1082,11 +1056,6 @@ size_t server_init_thread( void *entry_point ) } SERVER_END_REQ; -#ifndef _WIN64 - is_wow64 = (server_cpus & (1 << CPU_x86_64)) != 0; -#endif - ntdll_get_thread_data()->wow64_redir = is_wow64; - if (ret) { if (ret == STATUS_NOT_SUPPORTED) diff --git a/dlls/ntdll/signal_i386.c b/dlls/ntdll/signal_i386.c index d0e01723a28..ff251fa3d0a 100644 --- a/dlls/ntdll/signal_i386.c +++ b/dlls/ntdll/signal_i386.c @@ -137,15 +137,11 @@ void vm86_return(void); void vm86_return_end(void); __ASM_GLOBAL_FUNC(vm86_enter, "pushl %ebp\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %ebp,0\n\t") - "movl %esp,%ebp\n\t" - __ASM_CFI(".cfi_def_cfa_register %ebp\n\t") - "pushl %ebx\n\t" - __ASM_CFI(".cfi_rel_offset %ebx,-4\n\t") + "movl %esp, %ebp\n\t" "movl $166,%eax\n\t" /*SYS_vm86*/ "movl 8(%ebp),%ecx\n\t" /* vm86_ptr */ "movl (%ecx),%ecx\n\t" + "pushl %ebx\n\t" "movl $1,%ebx\n\t" /*VM86_ENTER*/ "pushl %ecx\n\t" /* put vm86plus_struct ptr somewhere we can find it */ "pushl %fs\n\t" @@ -158,10 +154,7 @@ __ASM_GLOBAL_FUNC(vm86_enter, "popl %fs\n\t" "popl %ecx\n\t" "popl %ebx\n\t" - __ASM_CFI(".cfi_same_value %ebx\n\t") "popl %ebp\n\t" - __ASM_CFI(".cfi_def_cfa %esp,4\n\t") - __ASM_CFI(".cfi_same_value %ebp\n\t") "testl %eax,%eax\n\t" "jl 0f\n\t" "cmpb $0,%al\n\t" /* VM86_SIGNAL */ @@ -2275,10 +2268,7 @@ DEFINE_REGS_ENTRYPOINT( RtlRaiseException, 1 ) extern void DECLSPEC_NORETURN call_thread_func( LPTHREAD_START_ROUTINE entry, void *arg ); __ASM_GLOBAL_FUNC(call_thread_func, "pushl %ebp\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %ebp,0\n\t") "movl %esp,%ebp\n\t" - __ASM_CFI(".cfi_def_cfa_register %ebp\n\t") "subl $4,%esp\n\t" "pushl 12(%ebp)\n\t" "call *8(%ebp)\n\t" @@ -2339,53 +2329,42 @@ __ASM_STDCALL_FUNC( NtCurrentTeb, 0, ".byte 0x64\n\tmovl 0x18,%eax\n\tret" ) * function calling the handler having only 5 parameters (*4). */ __ASM_GLOBAL_FUNC( EXC_CallHandler, - "pushl %ebp\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %ebp,0\n\t") - "movl %esp,%ebp\n\t" - __ASM_CFI(".cfi_def_cfa_register %ebp\n\t") - "pushl %ebx\n\t" - __ASM_CFI(".cfi_rel_offset %ebx,-4\n\t") - "movl 28(%ebp), %edx\n\t" /* ugly hack to pass the 6th param needed because of Shrinker */ - "pushl 24(%ebp)\n\t" - "pushl 20(%ebp)\n\t" - "pushl 16(%ebp)\n\t" - "pushl 12(%ebp)\n\t" - "pushl 8(%ebp)\n\t" - "call " __ASM_NAME("call_exception_handler") "\n\t" - "popl %ebx\n\t" - __ASM_CFI(".cfi_same_value %ebx\n\t") - "leave\n" - __ASM_CFI(".cfi_def_cfa %esp,4\n\t") - __ASM_CFI(".cfi_same_value %ebp\n\t") - "ret" ) +" pushl %ebp\n" +" movl %esp, %ebp\n" +" pushl %ebx\n" +" movl 28(%ebp), %edx\n" /* ugly hack to pass the 6th param needed because of Shrinker */ +" pushl 24(%ebp)\n" +" pushl 20(%ebp)\n" +" pushl 16(%ebp)\n" +" pushl 12(%ebp)\n" +" pushl 8(%ebp)\n" +" call " __ASM_NAME("call_exception_handler") "\n" +" popl %ebx\n" +" leave\n" +" ret\n" +) __ASM_GLOBAL_FUNC(call_exception_handler, - "pushl %ebp\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %ebp,0\n\t") - "movl %esp,%ebp\n\t" - __ASM_CFI(".cfi_def_cfa_register %ebp\n\t") - "subl $12,%esp\n\t" - "pushl 12(%ebp)\n\t" /* make any exceptions in this... */ - "pushl %edx\n\t" /* handler be handled by... */ - ".byte 0x64\n\t" - "pushl (0)\n\t" /* nested_handler (passed in edx). */ - ".byte 0x64\n\t" - "movl %esp,(0)\n\t" /* push the new exception frame onto the exception stack. */ - "pushl 20(%ebp)\n\t" - "pushl 16(%ebp)\n\t" - "pushl 12(%ebp)\n\t" - "pushl 8(%ebp)\n\t" - "movl 24(%ebp), %ecx\n\t" /* (*1) */ - "call *%ecx\n\t" /* call handler. (*2) */ - ".byte 0x64\n\t" - "movl (0), %esp\n\t" /* restore previous... (*3) */ - ".byte 0x64\n\t" - "popl (0)\n\t" /* exception frame. */ - "movl %ebp, %esp\n\t" /* restore saved stack, in case it was corrupted */ - "popl %ebp\n\t" - __ASM_CFI(".cfi_def_cfa %esp,4\n\t") - __ASM_CFI(".cfi_same_value %ebp\n\t") - "ret $20" ) /* (*4) */ - +" pushl %ebp\n" +" movl %esp, %ebp\n" +" subl $12,%esp\n" +" pushl 12(%ebp)\n" /* make any exceptions in this... */ +" pushl %edx\n" /* handler be handled by... */ +" .byte 0x64\n" +" pushl (0)\n" /* nested_handler (passed in edx). */ +" .byte 0x64\n" +" movl %esp,(0)\n" /* push the new exception frame onto the exception stack. */ +" pushl 20(%ebp)\n" +" pushl 16(%ebp)\n" +" pushl 12(%ebp)\n" +" pushl 8(%ebp)\n" +" movl 24(%ebp), %ecx\n" /* (*1) */ +" call *%ecx\n" /* call handler. (*2) */ +" .byte 0x64\n" +" movl (0), %esp\n" /* restore previous... (*3) */ +" .byte 0x64\n" +" popl (0)\n" /* exception frame. */ +" movl %ebp, %esp\n" /* restore saved stack, in case it was corrupted */ +" popl %ebp\n" +" ret $20\n" /* (*4) */ +) #endif /* __i386__ */ diff --git a/dlls/ntdll/sync.c b/dlls/ntdll/sync.c index f3f969a4319..6051f62bfc0 100644 --- a/dlls/ntdll/sync.c +++ b/dlls/ntdll/sync.c @@ -402,7 +402,7 @@ NTSTATUS WINAPI NtQueryEvent ( OUT PULONG ReturnLength) { FIXME("(%p)\n", EventHandle); - return STATUS_NOT_IMPLEMENTED; + return STATUS_SUCCESS; } /* diff --git a/dlls/ntdll/thread.c b/dlls/ntdll/thread.c index 0c73ffd9611..0b924b2cf7e 100644 --- a/dlls/ntdll/thread.c +++ b/dlls/ntdll/thread.c @@ -488,7 +488,8 @@ NTSTATUS WINAPI RtlCreateUserThread( HANDLE process, const SECURITY_DESCRIPTOR * return result.create_thread.status; } - if (server_pipe( request_pipe ) == -1) return STATUS_TOO_MANY_OPENED_FILES; + if (pipe( request_pipe ) == -1) return STATUS_TOO_MANY_OPENED_FILES; + fcntl( request_pipe[1], F_SETFD, 1 ); /* set close on exec flag */ wine_server_send_fd( request_pipe[0] ); SERVER_START_REQ( new_thread ) diff --git a/dlls/ntdll/virtual.c b/dlls/ntdll/virtual.c index 04c90f6f44a..33918ca5d4b 100644 --- a/dlls/ntdll/virtual.c +++ b/dlls/ntdll/virtual.c @@ -156,7 +156,7 @@ static const char *VIRTUAL_GetProtStr( BYTE prot ) { static char buffer[6]; buffer[0] = (prot & VPROT_COMMITTED) ? 'c' : '-'; - buffer[1] = (prot & VPROT_GUARD) ? 'g' : ((prot & VPROT_WRITEWATCH) ? 'H' : '-'); + buffer[1] = (prot & VPROT_GUARD) ? 'g' : '-'; buffer[2] = (prot & VPROT_READ) ? 'r' : '-'; buffer[3] = (prot & VPROT_WRITECOPY) ? 'W' : ((prot & VPROT_WRITE) ? 'w' : '-'); buffer[4] = (prot & VPROT_EXEC) ? 'x' : '-'; @@ -370,36 +370,6 @@ static void add_reserved_area( void *addr, size_t size ) /*********************************************************************** - * remove_reserved_area - * - * Remove a reserved area from the list maintained by libwine. - * The csVirtual section must be held by caller. - */ -static void remove_reserved_area( void *addr, size_t size ) -{ - struct file_view *view; - - TRACE( "removing %p-%p\n", addr, (char *)addr + size ); - wine_mmap_remove_reserved_area( addr, size, 0 ); - - /* unmap areas not covered by an existing view */ - LIST_FOR_EACH_ENTRY( view, &views_list, struct file_view, entry ) - { - if ((char *)view->base >= (char *)addr + size) - { - munmap( addr, size ); - break; - } - if ((char *)view->base + view->size <= (char *)addr) continue; - if (view->base > addr) munmap( addr, (char *)view->base - (char *)addr ); - if ((char *)view->base + view->size > (char *)addr + size) break; - size = (char *)addr + size - ((char *)view->base + view->size); - addr = (char *)view->base + view->size; - } -} - - -/*********************************************************************** * is_beyond_limit * * Check if an address range goes beyond a given limit. @@ -1645,58 +1615,17 @@ void VIRTUAL_SetForceExec( BOOL enable ) server_leave_uninterrupted_section( &csVirtual, &sigset ); } -struct free_range -{ - char *base; - char *limit; -}; - -/* free reserved areas above the limit; callback for wine_mmap_enum_reserved_areas */ -static int free_reserved_memory( void *base, size_t size, void *arg ) -{ - struct free_range *range = arg; - - if ((char *)base >= range->limit) return 0; - if ((char *)base + size <= range->base) return 0; - if ((char *)base < range->base) - { - size -= range->base - (char *)base; - base = range->base; - } - if ((char *)base + size > range->limit) size = range->limit - (char *)base; - remove_reserved_area( base, size ); - return 1; /* stop enumeration since the list has changed */ -} /*********************************************************************** - * virtual_release_address_space + * VIRTUAL_UseLargeAddressSpace * - * Release some address space once we have loaded and initialized the app. + * Increase the address space size for apps that support it. */ -void virtual_release_address_space( BOOL free_high_mem ) +void VIRTUAL_UseLargeAddressSpace(void) { -#ifdef __i386__ - struct free_range range; - sigset_t sigset; - - server_enter_uninterrupted_section( &csVirtual, &sigset ); - -#ifndef __APPLE__ /* dyld doesn't support parts of the WINE_DOS segment being unmapped */ - range.base = (char *)0x20000000; - range.limit = (char *)0x7f000000; - while (wine_mmap_enum_reserved_areas( free_reserved_memory, &range, 0 )) /* nothing */; -#endif - /* no large address space on win9x */ - if (free_high_mem && NtCurrentTeb()->Peb->OSPlatformId == VER_PLATFORM_WIN32_NT) - { - range.base = (char *)0x82000000; - range.limit = address_space_limit; - while (wine_mmap_enum_reserved_areas( free_reserved_memory, &range, 1 )) /* nothing */; - user_space_limit = working_set_limit = address_space_limit; - } - server_leave_uninterrupted_section( &csVirtual, &sigset ); -#endif + if (NtCurrentTeb()->Peb->OSPlatformId != VER_PLATFORM_WIN32_NT) return; + user_space_limit = working_set_limit = address_space_limit; } @@ -1787,7 +1716,7 @@ NTSTATUS WINAPI NtAllocateVirtualMemory( HANDLE process, PVOID *ret, ULONG zero_ /* Compute the alloc type flags */ - if (!(type & (MEM_COMMIT | MEM_RESERVE | MEM_RESET)) || + if (!(type & (MEM_COMMIT | MEM_RESERVE)) || (type & ~(MEM_COMMIT | MEM_RESERVE | MEM_TOP_DOWN | MEM_WRITE_WATCH | MEM_RESET))) { WARN("called with wrong alloc type flags (%08x) !\n", type); @@ -1804,11 +1733,6 @@ NTSTATUS WINAPI NtAllocateVirtualMemory( HANDLE process, PVOID *ret, ULONG zero_ status = map_view( &view, base, size, mask, type & MEM_TOP_DOWN, vprot ); if (status == STATUS_SUCCESS) base = view->base; } - else if (type & MEM_RESET) - { - if (!(view = VIRTUAL_FindView( base, size ))) status = STATUS_NOT_MAPPED_VIEW; - else madvise( base, size, MADV_DONTNEED ); - } else /* commit the pages */ { if (!(view = VIRTUAL_FindView( base, size ))) status = STATUS_NOT_MAPPED_VIEW; diff --git a/dlls/ole2.dll16/Makefile.in b/dlls/ole2.dll16/Makefile.in index 2fcfa286f7b..0a5460d3f0a 100644 --- a/dlls/ole2.dll16/Makefile.in +++ b/dlls/ole2.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = ole2.dll16 IMPORTS = uuid ole32 user32 gdi32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,ole32.dll +SPEC_SRCS = ole2.dll16.spec + C_SRCS = \ memlockbytes.c \ ole2.c diff --git a/dlls/ole2conv.dll16/Makefile.in b/dlls/ole2conv.dll16/Makefile.in index b99bb0d3291..8e132fbde1f 100644 --- a/dlls/ole2conv.dll16/Makefile.in +++ b/dlls/ole2conv.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = ole2conv.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,ole32.dll +SPEC_SRCS = ole2conv.dll16.spec + @MAKE_DLL_RULES@ @DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/ole2disp.dll16/Makefile.in b/dlls/ole2disp.dll16/Makefile.in index 8a2349ebda3..0a056b1d356 100644 --- a/dlls/ole2disp.dll16/Makefile.in +++ b/dlls/ole2disp.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = ole2disp.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,oleaut32.dll +SPEC_SRCS = ole2disp.dll16.spec + C_SRCS = ole2disp.c @MAKE_DLL_RULES@ diff --git a/dlls/ole2nls.dll16/Makefile.in b/dlls/ole2nls.dll16/Makefile.in index 4808531c6d7..54fac813f1f 100644 --- a/dlls/ole2nls.dll16/Makefile.in +++ b/dlls/ole2nls.dll16/Makefile.in @@ -8,6 +8,8 @@ IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,ole32.dll EXTRARCFLAGS = -O res16 +SPEC_SRCS = ole2nls.dll16.spec + C_SRCS = ole2nls.c RC_SRCS = version.rc diff --git a/dlls/ole2prox.dll16/Makefile.in b/dlls/ole2prox.dll16/Makefile.in index 9ab9141aa07..b0f2a2d00ba 100644 --- a/dlls/ole2prox.dll16/Makefile.in +++ b/dlls/ole2prox.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = ole2prox.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,ole32.dll +SPEC_SRCS = ole2prox.dll16.spec + @MAKE_DLL_RULES@ @DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/ole2thk.dll16/Makefile.in b/dlls/ole2thk.dll16/Makefile.in index 7426ee06a8e..e558733b4ed 100644 --- a/dlls/ole2thk.dll16/Makefile.in +++ b/dlls/ole2thk.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = ole2thk.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,ole32.dll +SPEC_SRCS = ole2thk.dll16.spec + @MAKE_DLL_RULES@ @DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/ole32/Makefile.in b/dlls/ole32/Makefile.in index c6f7cbddac6..eb1ac5ea181 100644 --- a/dlls/ole32/Makefile.in +++ b/dlls/ole32/Makefile.in @@ -31,8 +31,8 @@ C_SRCS = \ memlockbytes.c \ moniker.c \ ole2.c \ - ole2impl.c \ ole2stubs.c \ + ole2impl.c \ ole32_main.c \ oleobj.c \ oleproxy.c \ diff --git a/dlls/ole32/clipboard.c b/dlls/ole32/clipboard.c index 7f19d1638a4..81231aad4b1 100644 --- a/dlls/ole32/clipboard.c +++ b/dlls/ole32/clipboard.c @@ -744,30 +744,6 @@ static HRESULT get_data_from_global(IDataObject *data, FORMATETC *fmt, HGLOBAL * return hr; } -static HRESULT get_data_from_enhmetafile(IDataObject *data, FORMATETC *fmt, HGLOBAL *mem) -{ - HENHMETAFILE copy; - HRESULT hr; - FORMATETC mem_fmt; - STGMEDIUM med; - - *mem = NULL; - - mem_fmt = *fmt; - mem_fmt.tymed = TYMED_ENHMF; - - hr = IDataObject_GetData(data, &mem_fmt, &med); - if(FAILED(hr)) return hr; - - copy = CopyEnhMetaFileW(med.u.hEnhMetaFile, NULL); - if(copy) *mem = (HGLOBAL)copy; - else hr = E_FAIL; - - ReleaseStgMedium(&med); - - return hr; -} - /*********************************************************************** * render_format * @@ -797,10 +773,6 @@ static HRESULT render_format(IDataObject *data, LPFORMATETC fmt) { hr = get_data_from_global(data, fmt, &clip_data); } - else if(fmt->tymed & TYMED_ENHMF) - { - hr = get_data_from_enhmetafile(data, fmt, &clip_data); - } else { FIXME("Unhandled tymed %x\n", fmt->tymed); @@ -1133,22 +1105,6 @@ static HRESULT get_stgmed_for_storage(HGLOBAL h, STGMEDIUM *med) return hr; } -/************************************************************************ - * get_stgmed_for_emf - * - * Returns a stg medium with an enhanced metafile based on the handle - */ -static HRESULT get_stgmed_for_emf(HENHMETAFILE hemf, STGMEDIUM *med) -{ - med->pUnkForRelease = NULL; - med->tymed = TYMED_NULL; - - med->u.hEnhMetaFile = CopyEnhMetaFileW(hemf, NULL); - if(!med->u.hEnhMetaFile) return E_OUTOFMEMORY; - med->tymed = TYMED_ENHMF; - return S_OK; -} - static inline BOOL string_off_equal(const DVTARGETDEVICE *t1, WORD off1, const DVTARGETDEVICE *t2, WORD off2) { const WCHAR *str1, *str2; @@ -1238,8 +1194,6 @@ static HRESULT WINAPI snapshot_GetData(IDataObject *iface, FORMATETC *fmt, hr = get_stgmed_for_global(h, med); else if(mask & TYMED_ISTREAM) hr = get_stgmed_for_stream(h, med); - else if(mask & TYMED_ENHMF) - hr = get_stgmed_for_emf((HENHMETAFILE)h, med); else { FIXME("Unhandled tymed - mask %x req tymed %x\n", mask, fmt->tymed); diff --git a/dlls/ole32/compobj.c b/dlls/ole32/compobj.c index b2013cfbfa3..586a930bf45 100644 --- a/dlls/ole32/compobj.c +++ b/dlls/ole32/compobj.c @@ -52,7 +52,6 @@ #include "winerror.h" #include "winreg.h" #include "winuser.h" -#define USE_COM_CONTEXT_DEF #include "objbase.h" #include "ole2.h" #include "ole2ver.h" @@ -72,6 +71,11 @@ WINE_DEFAULT_DEBUG_CHANNEL(ole); * This section defines variables internal to the COM module. */ +static HRESULT COM_GetRegisteredClassObject(const struct apartment *apt, REFCLSID rclsid, + DWORD dwClsContext, LPUNKNOWN* ppUnk); +static void COM_RevokeAllClasses(const struct apartment *apt); +static HRESULT get_inproc_class_object(APARTMENT *apt, HKEY hkeydll, REFCLSID rclsid, REFIID riid, BOOL hostifnecessary, void **ppv); + static APARTMENT *MTA; /* protected by csApartment */ static APARTMENT *MainApartment; /* the first STA apartment */ static struct list apts = LIST_INIT( apts ); /* protected by csApartment */ @@ -178,147 +182,61 @@ struct apartment_loaded_dll static const WCHAR wszAptWinClass[] = {'O','l','e','M','a','i','n','T','h','r','e','a','d','W','n','d','C','l','a','s','s',' ', '0','x','#','#','#','#','#','#','#','#',' ',0}; +static LRESULT CALLBACK apartment_wndproc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam); +static HRESULT apartment_getclassobject(struct apartment *apt, LPCWSTR dllpath, + BOOL apartment_threaded, + REFCLSID rclsid, REFIID riid, void **ppv); +static void apartment_freeunusedlibraries(struct apartment *apt, DWORD delay); -/***************************************************************************** - * This section contains OpenDllList implementation - */ +static HRESULT COMPOBJ_DllList_Add(LPCWSTR library_name, OpenDll **ret); +static OpenDll *COMPOBJ_DllList_Get(LPCWSTR library_name); +static void COMPOBJ_DllList_ReleaseRef(OpenDll *entry, BOOL free_entry); -static OpenDll *COMPOBJ_DllList_Get(LPCWSTR library_name) -{ - OpenDll *ptr; - OpenDll *ret = NULL; - EnterCriticalSection(&csOpenDllList); - LIST_FOR_EACH_ENTRY(ptr, &openDllList, OpenDll, entry) - { - if (!strcmpiW(library_name, ptr->library_name) && - (InterlockedIncrement(&ptr->refs) != 1) /* entry is being destroy if == 1 */) - { - ret = ptr; - break; - } - } - LeaveCriticalSection(&csOpenDllList); - return ret; -} +static DWORD COM_RegReadPath(HKEY hkeyroot, const WCHAR *keyname, const WCHAR *valuename, WCHAR * dst, DWORD dstlen); -/* caller must ensure that library_name is not already in the open dll list */ -static HRESULT COMPOBJ_DllList_Add(LPCWSTR library_name, OpenDll **ret) +static void COMPOBJ_InitProcess( void ) { - OpenDll *entry; - int len; - HRESULT hr = S_OK; - HANDLE hLibrary; - DllCanUnloadNowFunc DllCanUnloadNow; - DllGetClassObjectFunc DllGetClassObject; - - TRACE("\n"); - - *ret = COMPOBJ_DllList_Get(library_name); - if (*ret) return S_OK; - - /* do this outside the csOpenDllList to avoid creating a lock dependency on - * the loader lock */ - hLibrary = LoadLibraryExW(library_name, 0, LOAD_WITH_ALTERED_SEARCH_PATH); - if (!hLibrary) - { - ERR("couldn't load in-process dll %s\n", debugstr_w(library_name)); - /* failure: DLL could not be loaded */ - return E_ACCESSDENIED; /* FIXME: or should this be CO_E_DLLNOTFOUND? */ - } - - DllCanUnloadNow = (void *)GetProcAddress(hLibrary, "DllCanUnloadNow"); - /* Note: failing to find DllCanUnloadNow is not a failure */ - DllGetClassObject = (void *)GetProcAddress(hLibrary, "DllGetClassObject"); - if (!DllGetClassObject) - { - /* failure: the dll did not export DllGetClassObject */ - ERR("couldn't find function DllGetClassObject in %s\n", debugstr_w(library_name)); - FreeLibrary(hLibrary); - return CO_E_DLLNOTFOUND; - } - - EnterCriticalSection( &csOpenDllList ); - - *ret = COMPOBJ_DllList_Get(library_name); - if (*ret) - { - /* another caller to this function already added the dll while we - * weren't in the critical section */ - FreeLibrary(hLibrary); - } - else - { - len = strlenW(library_name); - entry = HeapAlloc(GetProcessHeap(),0, sizeof(OpenDll)); - if (entry) - entry->library_name = HeapAlloc(GetProcessHeap(), 0, (len + 1)*sizeof(WCHAR)); - if (entry && entry->library_name) - { - memcpy(entry->library_name, library_name, (len + 1)*sizeof(WCHAR)); - entry->library = hLibrary; - entry->refs = 1; - entry->DllCanUnloadNow = DllCanUnloadNow; - entry->DllGetClassObject = DllGetClassObject; - list_add_tail(&openDllList, &entry->entry); - } - else - { - HeapFree(GetProcessHeap(), 0, entry); - hr = E_OUTOFMEMORY; - FreeLibrary(hLibrary); - } - *ret = entry; - } - - LeaveCriticalSection( &csOpenDllList ); + WNDCLASSW wclass; - return hr; + /* Dispatching to the correct thread in an apartment is done through + * window messages rather than RPC transports. When an interface is + * marshalled into another apartment in the same process, a window of the + * following class is created. The *caller* of CoMarshalInterface (i.e., the + * application) is responsible for pumping the message loop in that thread. + * The WM_USER messages which point to the RPCs are then dispatched to + * apartment_wndproc by the user's code from the apartment in which the + * interface was unmarshalled. + */ + memset(&wclass, 0, sizeof(wclass)); + wclass.lpfnWndProc = apartment_wndproc; + wclass.hInstance = hProxyDll; + wclass.lpszClassName = wszAptWinClass; + RegisterClassW(&wclass); } -/* pass FALSE for free_entry to release a reference without destroying the - * entry if it reaches zero or TRUE otherwise */ -static void COMPOBJ_DllList_ReleaseRef(OpenDll *entry, BOOL free_entry) +static void COMPOBJ_UninitProcess( void ) { - if (!InterlockedDecrement(&entry->refs) && free_entry) - { - EnterCriticalSection(&csOpenDllList); - list_remove(&entry->entry); - LeaveCriticalSection(&csOpenDllList); - - TRACE("freeing %p\n", entry->library); - FreeLibrary(entry->library); - - HeapFree(GetProcessHeap(), 0, entry->library_name); - HeapFree(GetProcessHeap(), 0, entry); - } + UnregisterClassW(wszAptWinClass, hProxyDll); } -/* frees memory associated with active dll list */ -static void COMPOBJ_DllList_Free(void) +static void COM_TlsDestroy(void) { - OpenDll *entry, *cursor2; - EnterCriticalSection(&csOpenDllList); - LIST_FOR_EACH_ENTRY_SAFE(entry, cursor2, &openDllList, OpenDll, entry) + struct oletls *info = NtCurrentTeb()->ReservedForOle; + if (info) { - list_remove(&entry->entry); - - HeapFree(GetProcessHeap(), 0, entry->library_name); - HeapFree(GetProcessHeap(), 0, entry); + if (info->apt) apartment_release(info->apt); + if (info->errorinfo) IErrorInfo_Release(info->errorinfo); + if (info->state) IUnknown_Release(info->state); + if (info->spy) IUnknown_Release(info->spy); + HeapFree(GetProcessHeap(), 0, info); + NtCurrentTeb()->ReservedForOle = NULL; } - LeaveCriticalSection(&csOpenDllList); } /****************************************************************************** * Manage apartments. */ -static DWORD apartment_addref(struct apartment *apt) -{ - DWORD refs = InterlockedIncrement(&apt->refs); - TRACE("%s: before = %d\n", wine_dbgstr_longlong(apt->oxid), refs - 1); - return refs; -} - /* allocates memory and fills in the necessary fields for a new apartment * object. must be called inside apartment cs */ static APARTMENT *apartment_construct(DWORD model) @@ -417,146 +335,11 @@ static inline BOOL apartment_is_model(const APARTMENT *apt, DWORD model) return (apt->multi_threaded == !(model & COINIT_APARTMENTTHREADED)); } -static void COM_RevokeRegisteredClassObject(RegisteredClass *curClass) -{ - list_remove(&curClass->entry); - - if (curClass->runContext & CLSCTX_LOCAL_SERVER) - RPC_StopLocalServer(curClass->RpcRegistration); - - /* - * Release the reference to the class object. - */ - IUnknown_Release(curClass->classObject); - - if (curClass->pMarshaledData) - { - LARGE_INTEGER zero; - memset(&zero, 0, sizeof(zero)); - IStream_Seek(curClass->pMarshaledData, zero, STREAM_SEEK_SET, NULL); - CoReleaseMarshalData(curClass->pMarshaledData); - IStream_Release(curClass->pMarshaledData); - } - - HeapFree(GetProcessHeap(), 0, curClass); -} - -static void COM_RevokeAllClasses(const struct apartment *apt) +DWORD apartment_addref(struct apartment *apt) { - RegisteredClass *curClass, *cursor; - - EnterCriticalSection( &csRegisteredClassList ); - - LIST_FOR_EACH_ENTRY_SAFE(curClass, cursor, &RegisteredClassList, RegisteredClass, entry) - { - if (curClass->apartment_id == apt->oxid) - COM_RevokeRegisteredClassObject(curClass); - } - - LeaveCriticalSection( &csRegisteredClassList ); -} - -/*********************************************************************** - * CoRevokeClassObject [OLE32.@] - * - * Removes a class object from the class registry. - * - * PARAMS - * dwRegister [I] Cookie returned from CoRegisterClassObject(). - * - * RETURNS - * Success: S_OK. - * Failure: HRESULT code. - * - * NOTES - * Must be called from the same apartment that called CoRegisterClassObject(), - * otherwise it will fail with RPC_E_WRONG_THREAD. - * - * SEE ALSO - * CoRegisterClassObject - */ -HRESULT WINAPI CoRevokeClassObject( - DWORD dwRegister) -{ - HRESULT hr = E_INVALIDARG; - RegisteredClass *curClass; - APARTMENT *apt; - - TRACE("(%08x)\n",dwRegister); - - apt = COM_CurrentApt(); - if (!apt) - { - ERR("COM was not initialized\n"); - return CO_E_NOTINITIALIZED; - } - - EnterCriticalSection( &csRegisteredClassList ); - - LIST_FOR_EACH_ENTRY(curClass, &RegisteredClassList, RegisteredClass, entry) - { - /* - * Check if we have a match on the cookie. - */ - if (curClass->dwCookie == dwRegister) - { - if (curClass->apartment_id == apt->oxid) - { - COM_RevokeRegisteredClassObject(curClass); - hr = S_OK; - } - else - { - ERR("called from wrong apartment, should be called from %s\n", - wine_dbgstr_longlong(curClass->apartment_id)); - hr = RPC_E_WRONG_THREAD; - } - break; - } - } - - LeaveCriticalSection( &csRegisteredClassList ); - - return hr; -} - -/* frees unused libraries loaded by apartment_getclassobject by calling the - * DLL's DllCanUnloadNow entry point */ -static void apartment_freeunusedlibraries(struct apartment *apt, DWORD delay) -{ - struct apartment_loaded_dll *entry, *next; - EnterCriticalSection(&apt->cs); - LIST_FOR_EACH_ENTRY_SAFE(entry, next, &apt->loaded_dlls, struct apartment_loaded_dll, entry) - { - if (entry->dll->DllCanUnloadNow && (entry->dll->DllCanUnloadNow() == S_OK)) - { - DWORD real_delay = delay; - - if (real_delay == INFINITE) - { - /* DLLs that return multi-threaded objects aren't unloaded - * straight away to cope for programs that have races between - * last object destruction and threads in the DLLs that haven't - * finished, despite DllCanUnloadNow returning S_OK */ - if (entry->multi_threaded) - real_delay = 10 * 60 * 1000; /* 10 minutes */ - else - real_delay = 0; - } - - if (!real_delay || (entry->unload_time && (entry->unload_time < GetTickCount()))) - { - list_remove(&entry->entry); - COMPOBJ_DllList_ReleaseRef(entry->dll, TRUE); - HeapFree(GetProcessHeap(), 0, entry); - } - else - entry->unload_time = GetTickCount() + real_delay; - } - else if (entry->unload_time) - entry->unload_time = 0; - } - LeaveCriticalSection(&apt->cs); + DWORD refs = InterlockedIncrement(&apt->refs); + TRACE("%s: before = %d\n", wine_dbgstr_longlong(apt->oxid), refs - 1); + return refs; } DWORD apartment_release(struct apartment *apt) @@ -717,123 +500,23 @@ static APARTMENT *apartment_findmain(void) static APARTMENT *apartment_find_multi_threaded(void) { APARTMENT *result = NULL; - struct list *cursor; - - EnterCriticalSection(&csApartment); - - LIST_FOR_EACH( cursor, &apts ) - { - struct apartment *apt = LIST_ENTRY( cursor, struct apartment, entry ); - if (apt->multi_threaded) - { - result = apt; - apartment_addref(result); - break; - } - } - - LeaveCriticalSection(&csApartment); - return result; -} - -/* gets the specified class object by loading the appropriate DLL, if - * necessary and calls the DllGetClassObject function for the DLL */ -static HRESULT apartment_getclassobject(struct apartment *apt, LPCWSTR dllpath, - BOOL apartment_threaded, - REFCLSID rclsid, REFIID riid, void **ppv) -{ - static const WCHAR wszOle32[] = {'o','l','e','3','2','.','d','l','l',0}; - HRESULT hr = S_OK; - BOOL found = FALSE; - struct apartment_loaded_dll *apartment_loaded_dll; - - if (!strcmpiW(dllpath, wszOle32)) - { - /* we don't need to control the lifetime of this dll, so use the local - * implementation of DllGetClassObject directly */ - TRACE("calling ole32!DllGetClassObject\n"); - hr = DllGetClassObject(rclsid, riid, ppv); - - if (hr != S_OK) - ERR("DllGetClassObject returned error 0x%08x\n", hr); - - return hr; - } - - EnterCriticalSection(&apt->cs); - - LIST_FOR_EACH_ENTRY(apartment_loaded_dll, &apt->loaded_dlls, struct apartment_loaded_dll, entry) - if (!strcmpiW(dllpath, apartment_loaded_dll->dll->library_name)) - { - TRACE("found %s already loaded\n", debugstr_w(dllpath)); - found = TRUE; - break; - } - - if (!found) - { - apartment_loaded_dll = HeapAlloc(GetProcessHeap(), 0, sizeof(*apartment_loaded_dll)); - if (!apartment_loaded_dll) - hr = E_OUTOFMEMORY; - if (SUCCEEDED(hr)) - { - apartment_loaded_dll->unload_time = 0; - apartment_loaded_dll->multi_threaded = FALSE; - hr = COMPOBJ_DllList_Add( dllpath, &apartment_loaded_dll->dll ); - if (FAILED(hr)) - HeapFree(GetProcessHeap(), 0, apartment_loaded_dll); - } - if (SUCCEEDED(hr)) - { - TRACE("added new loaded dll %s\n", debugstr_w(dllpath)); - list_add_tail(&apt->loaded_dlls, &apartment_loaded_dll->entry); - } - } - - LeaveCriticalSection(&apt->cs); - - if (SUCCEEDED(hr)) - { - /* one component being multi-threaded overrides any number of - * apartment-threaded components */ - if (!apartment_threaded) - apartment_loaded_dll->multi_threaded = TRUE; - - TRACE("calling DllGetClassObject %p\n", apartment_loaded_dll->dll->DllGetClassObject); - /* OK: get the ClassObject */ - hr = apartment_loaded_dll->dll->DllGetClassObject(rclsid, riid, ppv); - - if (hr != S_OK) - ERR("DllGetClassObject returned error 0x%08x\n", hr); - } + struct list *cursor; - return hr; -} + EnterCriticalSection(&csApartment); -/*********************************************************************** - * COM_RegReadPath [internal] - * - * Reads a registry value and expands it when necessary - */ -static DWORD COM_RegReadPath(HKEY hkeyroot, const WCHAR *keyname, const WCHAR *valuename, WCHAR * dst, DWORD dstlen) -{ - DWORD ret; - HKEY key; - DWORD keytype; - WCHAR src[MAX_PATH]; - DWORD dwLength = dstlen * sizeof(WCHAR); + LIST_FOR_EACH( cursor, &apts ) + { + struct apartment *apt = LIST_ENTRY( cursor, struct apartment, entry ); + if (apt->multi_threaded) + { + result = apt; + apartment_addref(result); + break; + } + } - if((ret = RegOpenKeyExW(hkeyroot, keyname, 0, KEY_READ, &key)) == ERROR_SUCCESS) { - if( (ret = RegQueryValueExW(key, NULL, NULL, &keytype, (LPBYTE)src, &dwLength)) == ERROR_SUCCESS ) { - if (keytype == REG_EXPAND_SZ) { - if (dstlen <= ExpandEnvironmentStringsW(src, dst, dstlen)) ret = ERROR_MORE_DATA; - } else { - lstrcpynW(dst, src, dstlen); - } - } - RegCloseKey (key); - } - return ret; + LeaveCriticalSection(&csApartment); + return result; } struct host_object_params @@ -1098,44 +781,246 @@ void apartment_joinmta(void) COM_CurrentInfo()->apt = MTA; } -static void COMPOBJ_InitProcess( void ) +/* gets the specified class object by loading the appropriate DLL, if + * necessary and calls the DllGetClassObject function for the DLL */ +static HRESULT apartment_getclassobject(struct apartment *apt, LPCWSTR dllpath, + BOOL apartment_threaded, + REFCLSID rclsid, REFIID riid, void **ppv) { - WNDCLASSW wclass; + static const WCHAR wszOle32[] = {'o','l','e','3','2','.','d','l','l',0}; + HRESULT hr = S_OK; + BOOL found = FALSE; + struct apartment_loaded_dll *apartment_loaded_dll; - /* Dispatching to the correct thread in an apartment is done through - * window messages rather than RPC transports. When an interface is - * marshalled into another apartment in the same process, a window of the - * following class is created. The *caller* of CoMarshalInterface (i.e., the - * application) is responsible for pumping the message loop in that thread. - * The WM_USER messages which point to the RPCs are then dispatched to - * apartment_wndproc by the user's code from the apartment in which the - * interface was unmarshalled. - */ - memset(&wclass, 0, sizeof(wclass)); - wclass.lpfnWndProc = apartment_wndproc; - wclass.hInstance = hProxyDll; - wclass.lpszClassName = wszAptWinClass; - RegisterClassW(&wclass); + if (!strcmpiW(dllpath, wszOle32)) + { + /* we don't need to control the lifetime of this dll, so use the local + * implementation of DllGetClassObject directly */ + TRACE("calling ole32!DllGetClassObject\n"); + hr = DllGetClassObject(rclsid, riid, ppv); + + if (hr != S_OK) + ERR("DllGetClassObject returned error 0x%08x\n", hr); + + return hr; + } + + EnterCriticalSection(&apt->cs); + + LIST_FOR_EACH_ENTRY(apartment_loaded_dll, &apt->loaded_dlls, struct apartment_loaded_dll, entry) + if (!strcmpiW(dllpath, apartment_loaded_dll->dll->library_name)) + { + TRACE("found %s already loaded\n", debugstr_w(dllpath)); + found = TRUE; + break; + } + + if (!found) + { + apartment_loaded_dll = HeapAlloc(GetProcessHeap(), 0, sizeof(*apartment_loaded_dll)); + if (!apartment_loaded_dll) + hr = E_OUTOFMEMORY; + if (SUCCEEDED(hr)) + { + apartment_loaded_dll->unload_time = 0; + apartment_loaded_dll->multi_threaded = FALSE; + hr = COMPOBJ_DllList_Add( dllpath, &apartment_loaded_dll->dll ); + if (FAILED(hr)) + HeapFree(GetProcessHeap(), 0, apartment_loaded_dll); + } + if (SUCCEEDED(hr)) + { + TRACE("added new loaded dll %s\n", debugstr_w(dllpath)); + list_add_tail(&apt->loaded_dlls, &apartment_loaded_dll->entry); + } + } + + LeaveCriticalSection(&apt->cs); + + if (SUCCEEDED(hr)) + { + /* one component being multi-threaded overrides any number of + * apartment-threaded components */ + if (!apartment_threaded) + apartment_loaded_dll->multi_threaded = TRUE; + + TRACE("calling DllGetClassObject %p\n", apartment_loaded_dll->dll->DllGetClassObject); + /* OK: get the ClassObject */ + hr = apartment_loaded_dll->dll->DllGetClassObject(rclsid, riid, ppv); + + if (hr != S_OK) + ERR("DllGetClassObject returned error 0x%08x\n", hr); + } + + return hr; +} + +/* frees unused libraries loaded by apartment_getclassobject by calling the + * DLL's DllCanUnloadNow entry point */ +static void apartment_freeunusedlibraries(struct apartment *apt, DWORD delay) +{ + struct apartment_loaded_dll *entry, *next; + EnterCriticalSection(&apt->cs); + LIST_FOR_EACH_ENTRY_SAFE(entry, next, &apt->loaded_dlls, struct apartment_loaded_dll, entry) + { + if (entry->dll->DllCanUnloadNow && (entry->dll->DllCanUnloadNow() == S_OK)) + { + DWORD real_delay = delay; + + if (real_delay == INFINITE) + { + /* DLLs that return multi-threaded objects aren't unloaded + * straight away to cope for programs that have races between + * last object destruction and threads in the DLLs that haven't + * finished, despite DllCanUnloadNow returning S_OK */ + if (entry->multi_threaded) + real_delay = 10 * 60 * 1000; /* 10 minutes */ + else + real_delay = 0; + } + + if (!real_delay || (entry->unload_time && (entry->unload_time < GetTickCount()))) + { + list_remove(&entry->entry); + COMPOBJ_DllList_ReleaseRef(entry->dll, TRUE); + HeapFree(GetProcessHeap(), 0, entry); + } + else + entry->unload_time = GetTickCount() + real_delay; + } + else if (entry->unload_time) + entry->unload_time = 0; + } + LeaveCriticalSection(&apt->cs); +} + +/***************************************************************************** + * This section contains OpenDllList implementation + */ + +/* caller must ensure that library_name is not already in the open dll list */ +static HRESULT COMPOBJ_DllList_Add(LPCWSTR library_name, OpenDll **ret) +{ + OpenDll *entry; + int len; + HRESULT hr = S_OK; + HANDLE hLibrary; + DllCanUnloadNowFunc DllCanUnloadNow; + DllGetClassObjectFunc DllGetClassObject; + + TRACE("\n"); + + *ret = COMPOBJ_DllList_Get(library_name); + if (*ret) return S_OK; + + /* do this outside the csOpenDllList to avoid creating a lock dependency on + * the loader lock */ + hLibrary = LoadLibraryExW(library_name, 0, LOAD_WITH_ALTERED_SEARCH_PATH); + if (!hLibrary) + { + ERR("couldn't load in-process dll %s\n", debugstr_w(library_name)); + /* failure: DLL could not be loaded */ + return E_ACCESSDENIED; /* FIXME: or should this be CO_E_DLLNOTFOUND? */ + } + + DllCanUnloadNow = (void *)GetProcAddress(hLibrary, "DllCanUnloadNow"); + /* Note: failing to find DllCanUnloadNow is not a failure */ + DllGetClassObject = (void *)GetProcAddress(hLibrary, "DllGetClassObject"); + if (!DllGetClassObject) + { + /* failure: the dll did not export DllGetClassObject */ + ERR("couldn't find function DllGetClassObject in %s\n", debugstr_w(library_name)); + FreeLibrary(hLibrary); + return CO_E_DLLNOTFOUND; + } + + EnterCriticalSection( &csOpenDllList ); + + *ret = COMPOBJ_DllList_Get(library_name); + if (*ret) + { + /* another caller to this function already added the dll while we + * weren't in the critical section */ + FreeLibrary(hLibrary); + } + else + { + len = strlenW(library_name); + entry = HeapAlloc(GetProcessHeap(),0, sizeof(OpenDll)); + if (entry) + entry->library_name = HeapAlloc(GetProcessHeap(), 0, (len + 1)*sizeof(WCHAR)); + if (entry && entry->library_name) + { + memcpy(entry->library_name, library_name, (len + 1)*sizeof(WCHAR)); + entry->library = hLibrary; + entry->refs = 1; + entry->DllCanUnloadNow = DllCanUnloadNow; + entry->DllGetClassObject = DllGetClassObject; + list_add_tail(&openDllList, &entry->entry); + } + else + { + HeapFree(GetProcessHeap(), 0, entry); + hr = E_OUTOFMEMORY; + FreeLibrary(hLibrary); + } + *ret = entry; + } + + LeaveCriticalSection( &csOpenDllList ); + + return hr; +} + +static OpenDll *COMPOBJ_DllList_Get(LPCWSTR library_name) +{ + OpenDll *ptr; + OpenDll *ret = NULL; + EnterCriticalSection(&csOpenDllList); + LIST_FOR_EACH_ENTRY(ptr, &openDllList, OpenDll, entry) + { + if (!strcmpiW(library_name, ptr->library_name) && + (InterlockedIncrement(&ptr->refs) != 1) /* entry is being destroy if == 1 */) + { + ret = ptr; + break; + } + } + LeaveCriticalSection(&csOpenDllList); + return ret; } -static void COMPOBJ_UninitProcess( void ) +/* pass FALSE for free_entry to release a reference without destroying the + * entry if it reaches zero or TRUE otherwise */ +static void COMPOBJ_DllList_ReleaseRef(OpenDll *entry, BOOL free_entry) { - UnregisterClassW(wszAptWinClass, hProxyDll); + if (!InterlockedDecrement(&entry->refs) && free_entry) + { + EnterCriticalSection(&csOpenDllList); + list_remove(&entry->entry); + LeaveCriticalSection(&csOpenDllList); + + TRACE("freeing %p\n", entry->library); + FreeLibrary(entry->library); + + HeapFree(GetProcessHeap(), 0, entry->library_name); + HeapFree(GetProcessHeap(), 0, entry); + } } -static void COM_TlsDestroy(void) +/* frees memory associated with active dll list */ +static void COMPOBJ_DllList_Free(void) { - struct oletls *info = NtCurrentTeb()->ReservedForOle; - if (info) + OpenDll *entry, *cursor2; + EnterCriticalSection(&csOpenDllList); + LIST_FOR_EACH_ENTRY_SAFE(entry, cursor2, &openDllList, OpenDll, entry) { - if (info->apt) apartment_release(info->apt); - if (info->errorinfo) IErrorInfo_Release(info->errorinfo); - if (info->state) IUnknown_Release(info->state); - if (info->spy) IUnknown_Release(info->spy); - if (info->context_token) IObjContext_Release(info->context_token); - HeapFree(GetProcessHeap(), 0, info); - NtCurrentTeb()->ReservedForOle = NULL; + list_remove(&entry->entry); + + HeapFree(GetProcessHeap(), 0, entry->library_name); + HeapFree(GetProcessHeap(), 0, entry); } + LeaveCriticalSection(&csOpenDllList); } /****************************************************************************** @@ -2146,6 +2031,135 @@ HRESULT WINAPI CoRegisterClassObject( return S_OK; } +static void COM_RevokeRegisteredClassObject(RegisteredClass *curClass) +{ + list_remove(&curClass->entry); + + if (curClass->runContext & CLSCTX_LOCAL_SERVER) + RPC_StopLocalServer(curClass->RpcRegistration); + + /* + * Release the reference to the class object. + */ + IUnknown_Release(curClass->classObject); + + if (curClass->pMarshaledData) + { + LARGE_INTEGER zero; + memset(&zero, 0, sizeof(zero)); + IStream_Seek(curClass->pMarshaledData, zero, STREAM_SEEK_SET, NULL); + CoReleaseMarshalData(curClass->pMarshaledData); + IStream_Release(curClass->pMarshaledData); + } + + HeapFree(GetProcessHeap(), 0, curClass); +} + +static void COM_RevokeAllClasses(const struct apartment *apt) +{ + RegisteredClass *curClass, *cursor; + + EnterCriticalSection( &csRegisteredClassList ); + + LIST_FOR_EACH_ENTRY_SAFE(curClass, cursor, &RegisteredClassList, RegisteredClass, entry) + { + if (curClass->apartment_id == apt->oxid) + COM_RevokeRegisteredClassObject(curClass); + } + + LeaveCriticalSection( &csRegisteredClassList ); +} + +/*********************************************************************** + * CoRevokeClassObject [OLE32.@] + * + * Removes a class object from the class registry. + * + * PARAMS + * dwRegister [I] Cookie returned from CoRegisterClassObject(). + * + * RETURNS + * Success: S_OK. + * Failure: HRESULT code. + * + * NOTES + * Must be called from the same apartment that called CoRegisterClassObject(), + * otherwise it will fail with RPC_E_WRONG_THREAD. + * + * SEE ALSO + * CoRegisterClassObject + */ +HRESULT WINAPI CoRevokeClassObject( + DWORD dwRegister) +{ + HRESULT hr = E_INVALIDARG; + RegisteredClass *curClass; + APARTMENT *apt; + + TRACE("(%08x)\n",dwRegister); + + apt = COM_CurrentApt(); + if (!apt) + { + ERR("COM was not initialized\n"); + return CO_E_NOTINITIALIZED; + } + + EnterCriticalSection( &csRegisteredClassList ); + + LIST_FOR_EACH_ENTRY(curClass, &RegisteredClassList, RegisteredClass, entry) + { + /* + * Check if we have a match on the cookie. + */ + if (curClass->dwCookie == dwRegister) + { + if (curClass->apartment_id == apt->oxid) + { + COM_RevokeRegisteredClassObject(curClass); + hr = S_OK; + } + else + { + ERR("called from wrong apartment, should be called from %s\n", + wine_dbgstr_longlong(curClass->apartment_id)); + hr = RPC_E_WRONG_THREAD; + } + break; + } + } + + LeaveCriticalSection( &csRegisteredClassList ); + + return hr; +} + +/*********************************************************************** + * COM_RegReadPath [internal] + * + * Reads a registry value and expands it when necessary + */ +static DWORD COM_RegReadPath(HKEY hkeyroot, const WCHAR *keyname, const WCHAR *valuename, WCHAR * dst, DWORD dstlen) +{ + DWORD ret; + HKEY key; + DWORD keytype; + WCHAR src[MAX_PATH]; + DWORD dwLength = dstlen * sizeof(WCHAR); + + if((ret = RegOpenKeyExW(hkeyroot, keyname, 0, KEY_READ, &key)) == ERROR_SUCCESS) { + if( (ret = RegQueryValueExW(key, NULL, NULL, &keytype, (LPBYTE)src, &dwLength)) == ERROR_SUCCESS ) { + if (keytype == REG_EXPAND_SZ) { + if (dstlen <= ExpandEnvironmentStringsW(src, dst, dstlen)) ret = ERROR_MORE_DATA; + } else { + lstrcpynW(dst, src, dstlen); + } + } + RegCloseKey (key); + } + return ret; +} + static void get_threading_model(HKEY key, LPWSTR value, DWORD len) { static const WCHAR wszThreadingModel[] = {'T','h','r','e','a','d','i','n','g','M','o','d','e','l',0}; @@ -3734,7 +3748,6 @@ typedef struct Context { const IComThreadingInfoVtbl *lpVtbl; const IContextCallbackVtbl *lpCallbackVtbl; - const IObjContextVtbl *lpContextVtbl; LONG refs; APTTYPE apttype; } Context; @@ -3749,11 +3762,6 @@ static inline Context *impl_from_IContextCallback( IContextCallback *iface ) return (Context *)((char*)iface - FIELD_OFFSET(Context, lpCallbackVtbl)); } -static inline Context *impl_from_IObjContext( IObjContext *iface ) -{ - return (Context *)((char*)iface - FIELD_OFFSET(Context, lpContextVtbl)); -} - static HRESULT Context_QueryInterface(Context *iface, REFIID riid, LPVOID *ppv) { *ppv = NULL; @@ -3762,15 +3770,10 @@ static HRESULT Context_QueryInterface(Context *iface, REFIID riid, LPVOID *ppv) IsEqualIID(riid, &IID_IUnknown)) { *ppv = &iface->lpVtbl; - } - else if (IsEqualIID(riid, &IID_IContextCallback)) + } else if (IsEqualIID(riid, &IID_IContextCallback)) { *ppv = &iface->lpCallbackVtbl; } - else if (IsEqualIID(riid, &IID_IObjContext)) - { - *ppv = &iface->lpContextVtbl; - } if (*ppv) { @@ -3900,115 +3903,6 @@ static const IContextCallbackVtbl Context_Callback_Vtbl = Context_CC_ContextCallback }; -static HRESULT WINAPI Context_OC_QueryInterface(IObjContext *iface, REFIID riid, LPVOID *ppv) -{ - Context *This = impl_from_IObjContext(iface); - return Context_QueryInterface(This, riid, ppv); -} - -static ULONG WINAPI Context_OC_AddRef(IObjContext *iface) -{ - Context *This = impl_from_IObjContext(iface); - return Context_AddRef(This); -} - -static ULONG WINAPI Context_OC_Release(IObjContext *iface) -{ - Context *This = impl_from_IObjContext(iface); - return Context_Release(This); -} - -static HRESULT WINAPI Context_OC_SetProperty(IObjContext *iface, REFGUID propid, CPFLAGS flags, IUnknown *punk) -{ - Context *This = impl_from_IObjContext(iface); - - FIXME("(%p/%p)->(%s, %x, %p)\n", This, iface, debugstr_guid(propid), flags, punk); - return E_NOTIMPL; -} - -static HRESULT WINAPI Context_OC_RemoveProperty(IObjContext *iface, REFGUID propid) -{ - Context *This = impl_from_IObjContext(iface); - - FIXME("(%p/%p)->(%s)\n", This, iface, debugstr_guid(propid)); - return E_NOTIMPL; -} - -static HRESULT WINAPI Context_OC_GetProperty(IObjContext *iface, REFGUID propid, CPFLAGS *flags, IUnknown **punk) -{ - Context *This = impl_from_IObjContext(iface); - - FIXME("(%p/%p)->(%s, %p, %p)\n", This, iface, debugstr_guid(propid), flags, punk); - return E_NOTIMPL; -} - -static HRESULT WINAPI Context_OC_EnumContextProps(IObjContext *iface, IEnumContextProps **props) -{ - Context *This = impl_from_IObjContext(iface); - - FIXME("(%p/%p)->(%p)\n", This, iface, props); - return E_NOTIMPL; -} - -static void WINAPI Context_OC_Reserved1(IObjContext *iface) -{ - Context *This = impl_from_IObjContext(iface); - FIXME("(%p/%p)\n", This, iface); -} - -static void WINAPI Context_OC_Reserved2(IObjContext *iface) -{ - Context *This = impl_from_IObjContext(iface); - FIXME("(%p/%p)\n", This, iface); -} - -static void WINAPI Context_OC_Reserved3(IObjContext *iface) -{ - Context *This = impl_from_IObjContext(iface); - FIXME("(%p/%p)\n", This, iface); -} - -static void WINAPI Context_OC_Reserved4(IObjContext *iface) -{ - Context *This = impl_from_IObjContext(iface); - FIXME("(%p/%p)\n", This, iface); -} - -static void WINAPI Context_OC_Reserved5(IObjContext *iface) -{ - Context *This = impl_from_IObjContext(iface); - FIXME("(%p/%p)\n", This, iface); -} - -static void WINAPI Context_OC_Reserved6(IObjContext *iface) -{ - Context *This = impl_from_IObjContext(iface); - FIXME("(%p/%p)\n", This, iface); -} - -static void WINAPI Context_OC_Reserved7(IObjContext *iface) -{ - Context *This = impl_from_IObjContext(iface); - FIXME("(%p/%p)\n", This, iface); -} - -static const IObjContextVtbl Context_Object_Vtbl = -{ - Context_OC_QueryInterface, - Context_OC_AddRef, - Context_OC_Release, - Context_OC_SetProperty, - Context_OC_RemoveProperty, - Context_OC_GetProperty, - Context_OC_EnumContextProps, - Context_OC_Reserved1, - Context_OC_Reserved2, - Context_OC_Reserved3, - Context_OC_Reserved4, - Context_OC_Reserved5, - Context_OC_Reserved6, - Context_OC_Reserved7 -}; /*********************************************************************** * CoGetObjectContext [OLE32.@] @@ -4034,12 +3928,8 @@ HRESULT WINAPI CoGetObjectContext(REFIID riid, void **ppv) *ppv = NULL; if (!apt) { - if (!(apt = apartment_find_multi_threaded())) - { - ERR("apartment not initialised\n"); - return CO_E_NOTINITIALIZED; - } - apartment_release(apt); + ERR("apartment not initialised\n"); + return CO_E_NOTINITIALIZED; } context = HeapAlloc(GetProcessHeap(), 0, sizeof(*context)); @@ -4048,7 +3938,6 @@ HRESULT WINAPI CoGetObjectContext(REFIID riid, void **ppv) context->lpVtbl = &Context_Threading_Vtbl; context->lpCallbackVtbl = &Context_Callback_Vtbl; - context->lpContextVtbl = &Context_Object_Vtbl; context->refs = 1; if (apt->multi_threaded) context->apttype = APTTYPE_MTA; @@ -4070,40 +3959,12 @@ HRESULT WINAPI CoGetObjectContext(REFIID riid, void **ppv) HRESULT WINAPI CoGetContextToken( ULONG_PTR *token ) { struct oletls *info = COM_CurrentInfo(); - - TRACE("(%p)\n", token); - + static int calls; + if(!(calls++)) FIXME( "stub\n" ); if (!info) return E_OUTOFMEMORY; - - if (!info->apt) - { - APARTMENT *apt; - if (!(apt = apartment_find_multi_threaded())) - { - ERR("apartment not initialised\n"); - return CO_E_NOTINITIALIZED; - } - apartment_release(apt); - } - - if (!token) - return E_POINTER; - - if (!info->context_token) - { - HRESULT hr; - IObjContext *ctx; - - hr = CoGetObjectContext(&IID_IObjContext, (void **)&ctx); - if (FAILED(hr)) return hr; - info->context_token = ctx; - } - - *token = (ULONG_PTR)info->context_token; - TRACE("apt->context_token=%p\n", info->context_token); - - return S_OK; + if (token) *token = info->context_token; + return E_NOTIMPL; } diff --git a/dlls/ole32/compobj_private.h b/dlls/ole32/compobj_private.h index fb059349f8c..a7c6dfa67ce 100644 --- a/dlls/ole32/compobj_private.h +++ b/dlls/ole32/compobj_private.h @@ -183,7 +183,7 @@ struct oletls LONG pending_call_count_client; /* number of client calls pending */ LONG pending_call_count_server; /* number of server calls pending */ DWORD unknown; - IObjContext *context_token; /* (+38h on x86) */ + ULONG_PTR context_token; /* (+38h on x86) */ IUnknown *call_state; /* current call context (+3Ch on x86) */ DWORD unknown2[46]; IUnknown *cancel_object; /* cancel object set by CoSetCancelObject (+F8h on x86) */ @@ -203,6 +203,7 @@ HRESULT FTMarshalCF_Create(REFIID riid, LPVOID *ppv); /* Stub Manager */ +ULONG stub_manager_int_addref(struct stub_manager *This); ULONG stub_manager_int_release(struct stub_manager *This); struct stub_manager *new_stub_manager(APARTMENT *apt, IUnknown *object); ULONG stub_manager_ext_addref(struct stub_manager *m, ULONG refs, BOOL tableweak); @@ -252,6 +253,7 @@ void OLEDD_UnInitialize(void); APARTMENT *apartment_findfromoxid(OXID oxid, BOOL ref); APARTMENT *apartment_findfromtid(DWORD tid); +DWORD apartment_addref(struct apartment *apt); DWORD apartment_release(struct apartment *apt); HRESULT apartment_disconnectproxies(struct apartment *apt); void apartment_disconnectobject(struct apartment *apt, void *object); diff --git a/dlls/ole32/defaulthandler.c b/dlls/ole32/defaulthandler.c index 4102d50845b..b85002ad52b 100644 --- a/dlls/ole32/defaulthandler.c +++ b/dlls/ole32/defaulthandler.c @@ -137,11 +137,6 @@ struct DefaultHandler /* storage passed to Load or InitNew */ IStorage *storage; enum storage_state storage_state; - - /* optional class factory for object */ - IClassFactory *pCFObject; - /* TRUE if acting as an inproc server instead of an inproc handler */ - BOOL inproc_server; }; typedef struct DefaultHandler DefaultHandler; @@ -228,12 +223,6 @@ static HRESULT WINAPI DefaultHandler_NDIUnknown_QueryInterface( if (FAILED(hr)) FIXME("interface %s not implemented by data cache\n", debugstr_guid(riid)); return hr; } - else if (This->inproc_server && This->pOleDelegate) - { - HRESULT hr = IUnknown_QueryInterface(This->pOleDelegate, riid, ppvObject); - if (SUCCEEDED(hr)) - return hr; - } /* Check that we obtained an interface. */ if (*ppvObject == NULL) @@ -1912,9 +1901,7 @@ static const IPersistStorageVtbl DefaultHandler_IPersistStorage_VTable = */ static DefaultHandler* DefaultHandler_Construct( REFCLSID clsid, - LPUNKNOWN pUnkOuter, - DWORD flags, - IClassFactory *pCF) + LPUNKNOWN pUnkOuter) { DefaultHandler* This = NULL; HRESULT hr; @@ -1931,8 +1918,6 @@ static DefaultHandler* DefaultHandler_Construct( This->lpvtblIAdviseSink = &DefaultHandler_IAdviseSink_VTable; This->lpvtblIPersistStorage = &DefaultHandler_IPersistStorage_VTable; - This->inproc_server = (flags & EMBDHLP_INPROC_SERVER) ? TRUE : FALSE; - /* * Start with one reference count. The caller of this function * must release the interface pointer when it is done. @@ -1979,30 +1964,6 @@ static DefaultHandler* DefaultHandler_Construct( This->storage = NULL; This->storage_state = storage_state_uninitialised; - if (This->inproc_server && !(flags & EMBDHLP_DELAYCREATE)) - { - HRESULT hr; - This->pCFObject = NULL; - if (pCF) - hr = IClassFactory_CreateInstance(pCF, NULL, &IID_IOleObject, (void **)&This->pOleDelegate); - else - hr = CoCreateInstance(&This->clsid, NULL, CLSCTX_INPROC_SERVER, - &IID_IOleObject, (void **)&This->pOleDelegate); - if (SUCCEEDED(hr)) - hr = IOleObject_QueryInterface(This->pOleDelegate, &IID_IPersistStorage, (void **)&This->pPSDelegate); - if (SUCCEEDED(hr)) - hr = IOleObject_QueryInterface(This->pOleDelegate, &IID_IDataObject, (void **)&This->pDataDelegate); - if (SUCCEEDED(hr)) - This->object_state = object_state_running; - if (FAILED(hr)) - WARN("object creation failed with error %08x\n", hr); - } - else - { - This->pCFObject = pCF; - if (pCF) IClassFactory_AddRef(pCF); - } - return This; } @@ -2050,30 +2011,22 @@ static void DefaultHandler_Destroy( This->storage = NULL; } - if (This->pCFObject) - { - IClassFactory_Release(This->pCFObject); - This->pCFObject = NULL; - } - HeapFree(GetProcessHeap(), 0, This); } /****************************************************************************** - * OleCreateEmbeddingHelper [OLE32.@] + * OleCreateDefaultHandler [OLE32.@] */ -HRESULT WINAPI OleCreateEmbeddingHelper( +HRESULT WINAPI OleCreateDefaultHandler( REFCLSID clsid, LPUNKNOWN pUnkOuter, - DWORD flags, - IClassFactory *pCF, REFIID riid, LPVOID* ppvObj) { DefaultHandler* newHandler = NULL; HRESULT hr = S_OK; - TRACE("(%s, %p, %08x, %p, %s, %p)\n", debugstr_guid(clsid), pUnkOuter, flags, pCF, debugstr_guid(riid), ppvObj); + TRACE("(%s, %p, %s, %p)\n", debugstr_guid(clsid), pUnkOuter, debugstr_guid(riid), ppvObj); if (!ppvObj) return E_POINTER; @@ -2092,7 +2045,7 @@ HRESULT WINAPI OleCreateEmbeddingHelper( /* * Try to construct a new instance of the class. */ - newHandler = DefaultHandler_Construct(clsid, pUnkOuter, flags, pCF); + newHandler = DefaultHandler_Construct(clsid, pUnkOuter); if (!newHandler) return E_OUTOFMEMORY; @@ -2110,15 +2063,3 @@ HRESULT WINAPI OleCreateEmbeddingHelper( return hr; } - - -/****************************************************************************** - * OleCreateDefaultHandler [OLE32.@] - */ -HRESULT WINAPI OleCreateDefaultHandler(REFCLSID clsid, LPUNKNOWN pUnkOuter, - REFIID riid, LPVOID* ppvObj) -{ - TRACE("(%s, %p, %s, %p)\n", debugstr_guid(clsid), pUnkOuter,debugstr_guid(riid), ppvObj); - return OleCreateEmbeddingHelper(clsid, pUnkOuter, EMBDHLP_INPROC_HANDLER | EMBDHLP_CREATENOW, - NULL, riid, ppvObj); -} diff --git a/dlls/ole32/ole2.c b/dlls/ole32/ole2.c index 3b87aacd6a6..fe00066921e 100644 --- a/dlls/ole32/ole2.c +++ b/dlls/ole32/ole2.c @@ -570,7 +570,7 @@ HRESULT WINAPI OleQueryLinkFromData( IDataObject* pSrcDataObject) { FIXME("(%p),stub!\n", pSrcDataObject); - return S_FALSE; + return S_OK; } /*********************************************************************** diff --git a/dlls/ole32/ole32.spec b/dlls/ole32/ole32.spec index 97f2f3d3aac..b9e5c4c3a79 100644 --- a/dlls/ole32/ole32.spec +++ b/dlls/ole32/ole32.spec @@ -180,7 +180,7 @@ @ stub OleConvertOLESTREAMToIStorageEx @ stdcall OleCreate(ptr ptr long ptr ptr ptr ptr) @ stdcall OleCreateDefaultHandler(ptr ptr ptr ptr) -@ stdcall OleCreateEmbeddingHelper(ptr ptr long ptr ptr ptr) +@ stub OleCreateEmbeddingHelper @ stub OleCreateEx @ stdcall OleCreateFromData(ptr ptr long ptr ptr ptr ptr) @ stdcall OleCreateFromDataEx(ptr ptr long long long ptr ptr ptr ptr ptr ptr ptr) diff --git a/dlls/ole32/ole32res.rc b/dlls/ole32/ole32res.rc index 60887a5ec50..0a649a62819 100644 --- a/dlls/ole32/ole32res.rc +++ b/dlls/ole32/ole32res.rc @@ -23,10 +23,7 @@ #include "winuser.h" #include "winnls.h" -#define WINE_OLESELFREGISTER -#define WINE_FILENAME_STR "ole32.dll" - -#include +#include "version.rc" /* * Everything that does not depend on language, @@ -47,3 +44,12 @@ LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL /* @makedep: drag_link.cur */ 3 CURSOR drag_link.cur + + +/* + * Everything specific to any language goes + * in one of the specific files. + * Note that you can and may override resources + * which also have a neutral version. This is to + * get localized bitmaps for example. + */ diff --git a/dlls/ole32/stubmanager.c b/dlls/ole32/stubmanager.c index 12813c6a5d7..0aa80fa15a8 100644 --- a/dlls/ole32/stubmanager.c +++ b/dlls/ole32/stubmanager.c @@ -42,129 +42,8 @@ WINE_DEFAULT_DEBUG_CHANNEL(ole); - -/* generates an ipid in the following format (similar to native version): - * Data1 = apartment-local ipid counter - * Data2 = apartment creator thread ID - * Data3 = process ID - * Data4 = random value - */ -static inline HRESULT generate_ipid(struct stub_manager *m, IPID *ipid) -{ - HRESULT hr; - hr = UuidCreate(ipid); - if (FAILED(hr)) - { - ERR("couldn't create IPID for stub manager %p\n", m); - UuidCreateNil(ipid); - return hr; - } - - ipid->Data1 = InterlockedIncrement(&m->apt->ipidc); - ipid->Data2 = (USHORT)m->apt->tid; - ipid->Data3 = (USHORT)GetCurrentProcessId(); - return S_OK; -} - -/* registers a new interface stub COM object with the stub manager and returns registration record */ -struct ifstub *stub_manager_new_ifstub(struct stub_manager *m, IRpcStubBuffer *sb, IUnknown *iptr, REFIID iid, MSHLFLAGS flags) -{ - struct ifstub *stub; - HRESULT hr; - - TRACE("oid=%s, stubbuffer=%p, iptr=%p, iid=%s\n", - wine_dbgstr_longlong(m->oid), sb, iptr, debugstr_guid(iid)); - - stub = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(struct ifstub)); - if (!stub) return NULL; - - hr = RPC_CreateServerChannel(&stub->chan); - if (hr != S_OK) - { - HeapFree(GetProcessHeap(), 0, stub); - return NULL; - } - - stub->stubbuffer = sb; - if (sb) IRpcStubBuffer_AddRef(sb); - - IUnknown_AddRef(iptr); - stub->iface = iptr; - stub->flags = flags; - stub->iid = *iid; - - /* FIXME: find a cleaner way of identifying that we are creating an ifstub - * for the remunknown interface */ - if (flags & MSHLFLAGSP_REMUNKNOWN) - stub->ipid = m->oxid_info.ipidRemUnknown; - else - generate_ipid(m, &stub->ipid); - - EnterCriticalSection(&m->lock); - list_add_head(&m->ifstubs, &stub->entry); - /* every normal marshal is counted so we don't allow more than we should */ - if (flags & MSHLFLAGS_NORMAL) m->norm_refs++; - LeaveCriticalSection(&m->lock); - - TRACE("ifstub %p created with ipid %s\n", stub, debugstr_guid(&stub->ipid)); - - return stub; -} - -static void stub_manager_delete_ifstub(struct stub_manager *m, struct ifstub *ifstub) -{ - TRACE("m=%p, m->oid=%s, ipid=%s\n", m, wine_dbgstr_longlong(m->oid), debugstr_guid(&ifstub->ipid)); - - list_remove(&ifstub->entry); - - RPC_UnregisterInterface(&ifstub->iid); - - if (ifstub->stubbuffer) IUnknown_Release(ifstub->stubbuffer); - IUnknown_Release(ifstub->iface); - IRpcChannelBuffer_Release(ifstub->chan); - - HeapFree(GetProcessHeap(), 0, ifstub); -} - -static struct ifstub *stub_manager_ipid_to_ifstub(struct stub_manager *m, const IPID *ipid) -{ - struct list *cursor; - struct ifstub *result = NULL; - - EnterCriticalSection(&m->lock); - LIST_FOR_EACH( cursor, &m->ifstubs ) - { - struct ifstub *ifstub = LIST_ENTRY( cursor, struct ifstub, entry ); - - if (IsEqualGUID(ipid, &ifstub->ipid)) - { - result = ifstub; - break; - } - } - LeaveCriticalSection(&m->lock); - - return result; -} - -struct ifstub *stub_manager_find_ifstub(struct stub_manager *m, REFIID iid, MSHLFLAGS flags) -{ - struct ifstub *result = NULL; - struct ifstub *ifstub; - - EnterCriticalSection(&m->lock); - LIST_FOR_EACH_ENTRY( ifstub, &m->ifstubs, struct ifstub, entry ) - { - if (IsEqualIID(iid, &ifstub->iid) && (ifstub->flags == flags)) - { - result = ifstub; - break; - } - } - LeaveCriticalSection(&m->lock); - - return result; -} +static void stub_manager_delete_ifstub(struct stub_manager *m, struct ifstub *ifstub); +static struct ifstub *stub_manager_ipid_to_ifstub(struct stub_manager *m, const IPID *ipid); /* creates a new stub manager and adds it into the apartment. caller must * release stub manager when it is no longer required. the apartment and @@ -250,44 +129,6 @@ static void stub_manager_delete(struct stub_manager *m) HeapFree(GetProcessHeap(), 0, m); } -/* increments the internal refcount */ -static ULONG stub_manager_int_addref(struct stub_manager *This) -{ - ULONG refs; - - EnterCriticalSection(&This->apt->cs); - refs = ++This->refs; - LeaveCriticalSection(&This->apt->cs); - - TRACE("before %d\n", refs - 1); - - return refs; -} - -/* decrements the internal refcount */ -ULONG stub_manager_int_release(struct stub_manager *This) -{ - ULONG refs; - APARTMENT *apt = This->apt; - - EnterCriticalSection(&apt->cs); - refs = --This->refs; - - TRACE("after %d\n", refs); - - /* remove from apartment so no other thread can access it... */ - if (!refs) - list_remove(&This->entry); - - LeaveCriticalSection(&apt->cs); - - /* ... so now we can delete it without being inside the apartment critsec */ - if (!refs) - stub_manager_delete(This); - - return refs; -} - /* gets the stub manager associated with an object - caller must have * a reference to the apartment while a reference to the stub manager is held. * it must also call release on the stub manager when it is no longer needed */ @@ -373,6 +214,44 @@ struct stub_manager *get_stub_manager(APARTMENT *apt, OID oid) return result; } +/* increments the internal refcount */ +ULONG stub_manager_int_addref(struct stub_manager *This) +{ + ULONG refs; + + EnterCriticalSection(&This->apt->cs); + refs = ++This->refs; + LeaveCriticalSection(&This->apt->cs); + + TRACE("before %d\n", refs - 1); + + return refs; +} + +/* decrements the internal refcount */ +ULONG stub_manager_int_release(struct stub_manager *This) +{ + ULONG refs; + APARTMENT *apt = This->apt; + + EnterCriticalSection(&apt->cs); + refs = --This->refs; + + TRACE("after %d\n", refs); + + /* remove from apartment so no other thread can access it... */ + if (!refs) + list_remove(&This->entry); + + LeaveCriticalSection(&apt->cs); + + /* ... so now we can delete it without being inside the apartment critsec */ + if (!refs) + stub_manager_delete(This); + + return refs; +} + /* add some external references (ie from a client that unmarshaled an ifptr) */ ULONG stub_manager_ext_addref(struct stub_manager *m, ULONG refs, BOOL tableweak) { @@ -418,6 +297,46 @@ ULONG stub_manager_ext_release(struct stub_manager *m, ULONG refs, BOOL tablewea return rc; } +static struct ifstub *stub_manager_ipid_to_ifstub(struct stub_manager *m, const IPID *ipid) +{ + struct list *cursor; + struct ifstub *result = NULL; + + EnterCriticalSection(&m->lock); + LIST_FOR_EACH( cursor, &m->ifstubs ) + { + struct ifstub *ifstub = LIST_ENTRY( cursor, struct ifstub, entry ); + + if (IsEqualGUID(ipid, &ifstub->ipid)) + { + result = ifstub; + break; + } + } + LeaveCriticalSection(&m->lock); + + return result; +} + +struct ifstub *stub_manager_find_ifstub(struct stub_manager *m, REFIID iid, MSHLFLAGS flags) +{ + struct ifstub *result = NULL; + struct ifstub *ifstub; + + EnterCriticalSection(&m->lock); + LIST_FOR_EACH_ENTRY( ifstub, &m->ifstubs, struct ifstub, entry ) + { + if (IsEqualIID(iid, &ifstub->iid) && (ifstub->flags == flags)) + { + result = ifstub; + break; + } + } + LeaveCriticalSection(&m->lock); + + return result; +} + /* gets the stub manager associated with an ipid - caller must have * a reference to the apartment while a reference to the stub manager is held. * it must also call release on the stub manager when it is no longer needed */ @@ -507,6 +426,89 @@ HRESULT ipid_get_dispatch_params(const IPID *ipid, APARTMENT **stub_apt, } } +/* generates an ipid in the following format (similar to native version): + * Data1 = apartment-local ipid counter + * Data2 = apartment creator thread ID + * Data3 = process ID + * Data4 = random value + */ +static inline HRESULT generate_ipid(struct stub_manager *m, IPID *ipid) +{ + HRESULT hr; + hr = UuidCreate(ipid); + if (FAILED(hr)) + { + ERR("couldn't create IPID for stub manager %p\n", m); + UuidCreateNil(ipid); + return hr; + } + + ipid->Data1 = InterlockedIncrement(&m->apt->ipidc); + ipid->Data2 = (USHORT)m->apt->tid; + ipid->Data3 = (USHORT)GetCurrentProcessId(); + return S_OK; +} + +/* registers a new interface stub COM object with the stub manager and returns registration record */ +struct ifstub *stub_manager_new_ifstub(struct stub_manager *m, IRpcStubBuffer *sb, IUnknown *iptr, REFIID iid, MSHLFLAGS flags) +{ + struct ifstub *stub; + HRESULT hr; + + TRACE("oid=%s, stubbuffer=%p, iptr=%p, iid=%s\n", + wine_dbgstr_longlong(m->oid), sb, iptr, debugstr_guid(iid)); + + stub = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(struct ifstub)); + if (!stub) return NULL; + + hr = RPC_CreateServerChannel(&stub->chan); + if (hr != S_OK) + { + HeapFree(GetProcessHeap(), 0, stub); + return NULL; + } + + stub->stubbuffer = sb; + if (sb) IRpcStubBuffer_AddRef(sb); + + IUnknown_AddRef(iptr); + stub->iface = iptr; + stub->flags = flags; + stub->iid = *iid; + + /* FIXME: find a cleaner way of identifying that we are creating an ifstub + * for the remunknown interface */ + if (flags & MSHLFLAGSP_REMUNKNOWN) + stub->ipid = m->oxid_info.ipidRemUnknown; + else + generate_ipid(m, &stub->ipid); + + EnterCriticalSection(&m->lock); + list_add_head(&m->ifstubs, &stub->entry); + /* every normal marshal is counted so we don't allow more than we should */ + if (flags & MSHLFLAGS_NORMAL) m->norm_refs++; + LeaveCriticalSection(&m->lock); + + TRACE("ifstub %p created with ipid %s\n", stub, debugstr_guid(&stub->ipid)); + + return stub; +} + +static void stub_manager_delete_ifstub(struct stub_manager *m, struct ifstub *ifstub) +{ + TRACE("m=%p, m->oid=%s, ipid=%s\n", m, wine_dbgstr_longlong(m->oid), debugstr_guid(&ifstub->ipid)); + + list_remove(&ifstub->entry); + + RPC_UnregisterInterface(&ifstub->iid); + + if (ifstub->stubbuffer) IUnknown_Release(ifstub->stubbuffer); + IUnknown_Release(ifstub->iface); + IRpcChannelBuffer_Release(ifstub->chan); + + HeapFree(GetProcessHeap(), 0, ifstub); +} + /* returns TRUE if it is possible to unmarshal, FALSE otherwise. */ BOOL stub_manager_notify_unmarshal(struct stub_manager *m, const IPID *ipid) { diff --git a/dlls/ole32/tests/clipboard.c b/dlls/ole32/tests/clipboard.c index e58ac029237..a6229a18fc2 100644 --- a/dlls/ole32/tests/clipboard.c +++ b/dlls/ole32/tests/clipboard.c @@ -1235,8 +1235,6 @@ static void test_nonole_clipboard(void) FORMATETC fmt; HGLOBAL h, hblob, htext; HENHMETAFILE emf; - STGMEDIUM med; - DWORD obj_type; r = OpenClipboard(NULL); ok(r, "gle %d\n", GetLastError()); @@ -1351,13 +1349,6 @@ static void test_nonole_clipboard(void) ok(hr == S_FALSE, "got %08x\n", hr); IEnumFORMATETC_Release(enum_fmt); - InitFormatEtc(fmt, CF_ENHMETAFILE, TYMED_ENHMF); - hr = IDataObject_GetData(get, &fmt, &med); - ok(hr == S_OK, "got %08x\n", hr); - obj_type = GetObjectType(U(med).hEnhMetaFile); - ok(obj_type == OBJ_ENHMETAFILE, "got %d\n", obj_type); - ReleaseStgMedium(&med); - IDataObject_Release(get); r = OpenClipboard(NULL); diff --git a/dlls/ole32/tests/compobj.c b/dlls/ole32/tests/compobj.c index 44a25217128..d9d684d52b9 100644 --- a/dlls/ole32/tests/compobj.c +++ b/dlls/ole32/tests/compobj.c @@ -25,12 +25,11 @@ #include "windef.h" #include "winbase.h" -#define USE_COM_CONTEXT_DEF -#include "initguid.h" #include "objbase.h" #include "shlguid.h" #include "urlmon.h" /* for CLSID_FileProtocol */ +#include "initguid.h" #include "ctxtcall.h" #include "wine/test.h" @@ -40,7 +39,6 @@ HRESULT (WINAPI * pCoInitializeEx)(LPVOID lpReserved, DWORD dwCoInit); HRESULT (WINAPI * pCoGetObjectContext)(REFIID riid, LPVOID *ppv); HRESULT (WINAPI * pCoSwitchCallContext)(IUnknown *pObject, IUnknown **ppOldObject); HRESULT (WINAPI * pCoGetTreatAsClass)(REFCLSID clsidOld, LPCLSID pClsidNew); -HRESULT (WINAPI * pCoGetContextToken)(ULONG_PTR *token); #define ok_ole_success(hr, func) ok(hr == S_OK, func " failed with error 0x%08x\n", hr) #define ok_more_than_one_lock() ok(cLocks > 0, "Number of locks should be > 0, but actually is %d\n", cLocks) @@ -1079,12 +1077,8 @@ static void test_CoGetObjectContext(void) ULONG refs; IComThreadingInfo *pComThreadingInfo; IContextCallback *pContextCallback; - IObjContext *pObjContext; APTTYPE apttype; THDTYPE thdtype; - struct info info; - HANDLE thread; - DWORD tid, exitcode; if (!pCoGetObjectContext) { @@ -1096,36 +1090,6 @@ static void test_CoGetObjectContext(void) ok(hr == CO_E_NOTINITIALIZED, "CoGetObjectContext should have returned CO_E_NOTINITIALIZED instead of 0x%08x\n", hr); ok(pComThreadingInfo == NULL, "pComThreadingInfo should have been set to NULL\n"); - /* show that COM doesn't have to be initialized for multi-threaded apartments if another - thread has already done so */ - - info.wait = CreateEvent(NULL, TRUE, FALSE, NULL); - ok(info.wait != NULL, "CreateEvent failed with error %d\n", GetLastError()); - - info.stop = CreateEvent(NULL, TRUE, FALSE, NULL); - ok(info.stop != NULL, "CreateEvent failed with error %d\n", GetLastError()); - - thread = CreateThread(NULL, 0, ole_initialize_thread, &info, 0, &tid); - ok(thread != NULL, "CreateThread failed with error %d\n", GetLastError()); - - WaitForSingleObject(info.wait, INFINITE); - - pComThreadingInfo = NULL; - hr = pCoGetObjectContext(&IID_IComThreadingInfo, (void **)&pComThreadingInfo); - ok(hr == S_OK, "Expected S_OK, got 0x%08x\n", hr); - IComThreadingInfo_Release(pComThreadingInfo); - - SetEvent(info.stop); - WaitForSingleObject(thread, INFINITE); - - GetExitCodeThread(thread, &exitcode); - hr = exitcode; - ok(hr == S_OK, "thread should have returned S_OK instead of 0x%08x\n", hr); - - CloseHandle(thread); - CloseHandle(info.wait); - CloseHandle(info.stop); - pCoInitializeEx(NULL, COINIT_APARTMENTTHREADED); hr = pCoGetObjectContext(&IID_IComThreadingInfo, (void **)&pComThreadingInfo); @@ -1178,12 +1142,6 @@ static void test_CoGetObjectContext(void) ok(refs == 0, "pContextCallback should have 0 refs instead of %d refs\n", refs); } - hr = pCoGetObjectContext(&IID_IObjContext, (void **)&pObjContext); - ok_ole_success(hr, "CoGetObjectContext"); - - refs = IObjContext_Release(pObjContext); - ok(refs == 0, "pObjContext should have 0 refs instead of %d refs\n", refs); - CoUninitialize(); } @@ -1287,102 +1245,6 @@ static void test_CoGetCallContext(void) CoUninitialize(); } -static void test_CoGetContextToken(void) -{ - HRESULT hr; - ULONG refs; - ULONG_PTR token; - IObjContext *ctx; - struct info info; - HANDLE thread; - DWORD tid, exitcode; - - if (!pCoGetContextToken) - { - win_skip("CoGetContextToken not present\n"); - return; - } - - token = 0xdeadbeef; - hr = pCoGetContextToken(&token); - ok(hr == CO_E_NOTINITIALIZED, "Expected CO_E_NOTINITIALIZED, got 0x%08x\n", hr); - ok(token == 0xdeadbeef, "Expected 0, got 0x%lx\n", token); - - /* show that COM doesn't have to be initialized for multi-threaded apartments if another - thread has already done so */ - - info.wait = CreateEvent(NULL, TRUE, FALSE, NULL); - ok(info.wait != NULL, "CreateEvent failed with error %d\n", GetLastError()); - - info.stop = CreateEvent(NULL, TRUE, FALSE, NULL); - ok(info.stop != NULL, "CreateEvent failed with error %d\n", GetLastError()); - - thread = CreateThread(NULL, 0, ole_initialize_thread, &info, 0, &tid); - ok(thread != NULL, "CreateThread failed with error %d\n", GetLastError()); - - WaitForSingleObject(info.wait, INFINITE); - - token = 0; - hr = pCoGetContextToken(&token); - ok(hr == S_OK, "Expected S_OK, got 0x%08x\n", hr); - IUnknown_Release((IUnknown *)token); - - SetEvent(info.stop); - WaitForSingleObject(thread, INFINITE); - - GetExitCodeThread(thread, &exitcode); - hr = exitcode; - ok(hr == S_OK, "thread should have returned S_OK instead of 0x%08x\n", hr); - - CloseHandle(thread); - CloseHandle(info.wait); - CloseHandle(info.stop); - - CoInitialize(NULL); - - hr = pCoGetContextToken(NULL); - ok(hr == E_POINTER, "Expected E_POINTER, got 0x%08x\n", hr); - - token = 0; - hr = pCoGetContextToken(&token); - ok(hr == S_OK, "Expected S_OK, got 0x%08x\n", hr); - ok(token, "Expected token != 0\n"); - - refs = IUnknown_AddRef((IUnknown *)token); - ok(refs == 1, "Expected 1, got %u\n", refs); - - hr = pCoGetObjectContext(&IID_IObjContext, (void **)&ctx); - ok(hr == S_OK, "Expected S_OK, got 0x%08x\n", hr); - todo_wine ok(ctx == (IObjContext *)token, "Expected interface pointers to be the same\n"); - - refs = IUnknown_AddRef((IUnknown *)ctx); - todo_wine ok(refs == 3, "Expected 3, got %u\n", refs); - - refs = IUnknown_Release((IUnknown *)ctx); - todo_wine ok(refs == 2, "Expected 2, got %u\n", refs); - - refs = IUnknown_Release((IUnknown *)token); - todo_wine ok(refs == 1, "Expected 1, got %u\n", refs); - - /* CoGetContextToken does not add a reference */ - token = 0; - hr = pCoGetContextToken(&token); - ok(hr == S_OK, "Expected S_OK, got 0x%08x\n", hr); - ok(token, "Expected token != 0\n"); - todo_wine ok(ctx == (IObjContext *)token, "Expected interface pointers to be the same\n"); - - refs = IUnknown_AddRef((IUnknown *)ctx); - ok(refs == 2, "Expected 1, got %u\n", refs); - - refs = IUnknown_Release((IUnknown *)ctx); - ok(refs == 1, "Expected 0, got %u\n", refs); - - refs = IUnknown_Release((IUnknown *)ctx); - ok(refs == 0, "Expected 0, got %u\n", refs); - - CoUninitialize(); -} - static void test_CoGetTreatAsClass(void) { HRESULT hr; @@ -1426,7 +1288,6 @@ START_TEST(compobj) pCoGetObjectContext = (void*)GetProcAddress(hOle32, "CoGetObjectContext"); pCoSwitchCallContext = (void*)GetProcAddress(hOle32, "CoSwitchCallContext"); pCoGetTreatAsClass = (void*)GetProcAddress(hOle32,"CoGetTreatAsClass"); - pCoGetContextToken = (void*)GetProcAddress(hOle32, "CoGetContextToken"); if (!(pCoInitializeEx = (void*)GetProcAddress(hOle32, "CoInitializeEx"))) { trace("You need DCOM95 installed to run this test\n"); @@ -1452,7 +1313,6 @@ START_TEST(compobj) test_CoFreeUnusedLibraries(); test_CoGetObjectContext(); test_CoGetCallContext(); - test_CoGetContextToken(); test_CoGetTreatAsClass(); test_CoInitializeEx(); } diff --git a/dlls/ole32/tests/marshal.c b/dlls/ole32/tests/marshal.c index 7e3ff40ac77..40824881b01 100644 --- a/dlls/ole32/tests/marshal.c +++ b/dlls/ole32/tests/marshal.c @@ -27,11 +27,11 @@ #include "windef.h" #include "winbase.h" +#include "initguid.h" #include "objbase.h" #include "olectl.h" #include "shlguid.h" #include "shobjidl.h" -#include "initguid.h" #include "wine/test.h" @@ -2071,7 +2071,7 @@ static void test_freethreadedmarshaldata(IStream *pStream, MSHCTX mshctx, void * { DWORD expected_size = round_global_size(3*sizeof(DWORD) + sizeof(GUID)); ok(size == expected_size || - broken(size == (2*sizeof(DWORD))) /* Win9x & NT4 */, + broken(size == round_global_size(2*sizeof(DWORD))) /* Win9x & NT4 */, "size should have been %d instead of %d\n", expected_size, size); ok(*(DWORD *)marshal_data == mshlflags, "expected 0x%x, but got 0x%x for mshctx\n", mshlflags, *(DWORD *)marshal_data); diff --git a/dlls/ole32/tests/moniker.c b/dlls/ole32/tests/moniker.c index 306a892fcfb..413045a06b3 100644 --- a/dlls/ole32/tests/moniker.c +++ b/dlls/ole32/tests/moniker.c @@ -28,7 +28,6 @@ #include "windef.h" #include "winbase.h" #include "objbase.h" -#include "initguid.h" #include "comcat.h" #include "olectl.h" @@ -1143,7 +1142,7 @@ static void test_moniker( LPBYTE moniker_data; DWORD moniker_size; DWORD i; - BOOL same; + BOOL same = TRUE; BYTE buffer[128]; IMoniker * moniker_proxy; LPOLESTR display_name; @@ -1183,7 +1182,6 @@ static void test_moniker( testname, sizeof_expected_moniker_comparison_data, moniker_size); /* then do a byte-by-byte comparison */ - same = TRUE; for (i = 0; i < min(moniker_size, sizeof_expected_moniker_comparison_data); i++) { if (expected_moniker_comparison_data[i] != buffer[i]) @@ -1227,7 +1225,6 @@ static void test_moniker( testname, (DWORD)round_global_size(sizeof_expected_moniker_saved_data), moniker_size); /* then do a byte-by-byte comparison */ - same = TRUE; for (i = 0; i < min(moniker_size, round_global_size(sizeof_expected_moniker_saved_data)); i++) { if (expected_moniker_saved_data[i] != moniker_data[i]) @@ -1274,7 +1271,6 @@ static void test_moniker( testname, (DWORD)round_global_size(sizeof_expected_moniker_marshal_data), moniker_size); /* then do a byte-by-byte comparison */ - same = TRUE; if (expected_moniker_marshal_data) { for (i = 0; i < min(moniker_size, round_global_size(sizeof_expected_moniker_marshal_data)); i++) diff --git a/dlls/ole32/tests/usrmarshal.c b/dlls/ole32/tests/usrmarshal.c index a6553977744..fde0034ab5b 100644 --- a/dlls/ole32/tests/usrmarshal.c +++ b/dlls/ole32/tests/usrmarshal.c @@ -29,7 +29,7 @@ #include "wine/test.h" -ULONG __RPC_USER HMETAFILE_UserSize(ULONG *, ULONG, HMETAFILE *); +ULONG __RPC_USER HMETAFILE_UserSize(ULONG *, unsigned long, HMETAFILE *); unsigned char * __RPC_USER HMETAFILE_UserMarshal(ULONG *, unsigned char *, HMETAFILE *); unsigned char * __RPC_USER HMETAFILE_UserUnmarshal(ULONG *, unsigned char *, HMETAFILE *); void __RPC_USER HMETAFILE_UserFree(ULONG *, HMETAFILE *); diff --git a/dlls/ole32/version.rc b/dlls/ole32/version.rc new file mode 100644 index 00000000000..fb85adeba05 --- /dev/null +++ b/dlls/ole32/version.rc @@ -0,0 +1,24 @@ +/* + * version information for ole32.dll + * + * Copyright (C) 2003 John K. Hohm + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#define WINE_OLESELFREGISTER +#define WINE_FILENAME_STR "ole32.dll" + +#include diff --git a/dlls/oleacc/Makefile.in b/dlls/oleacc/Makefile.in index 1f961fa235c..01b03ae6775 100644 --- a/dlls/oleacc/Makefile.in +++ b/dlls/oleacc/Makefile.in @@ -9,15 +9,7 @@ IMPORTS = user32 kernel32 C_SRCS = \ main.c -RC_SRCS = \ - oleacc_De.rc \ - oleacc_En.rc \ - oleacc_Fr.rc \ - oleacc_Ko.rc \ - oleacc_Lt.rc \ - oleacc_Nl.rc \ - oleacc_Pl.rc \ - oleacc_Pt.rc +RC_SRCS = oleacc.rc @MAKE_DLL_RULES@ diff --git a/dlls/oleacc/main.c b/dlls/oleacc/main.c index 34bdb61bcde..0e7b78e8a08 100644 --- a/dlls/oleacc/main.c +++ b/dlls/oleacc/main.c @@ -40,12 +40,6 @@ HRESULT WINAPI CreateStdAccessibleObject( HWND hwnd, LONG idObject, return E_NOTIMPL; } -HRESULT WINAPI ObjectFromLresult( LRESULT result, REFIID riid, WPARAM wParam, void **ppObject ) -{ - FIXME("%ld %s %ld %p\n", result, debugstr_guid(riid), wParam, ppObject ); - return E_NOTIMPL; -} - LRESULT WINAPI LresultFromObject( REFIID riid, WPARAM wParam, LPUNKNOWN pAcc ) { FIXME("%s %ld %p\n", debugstr_guid(riid), wParam, pAcc ); diff --git a/dlls/oleacc/oleacc.rc b/dlls/oleacc/oleacc.rc new file mode 100644 index 00000000000..abcd7fb9943 --- /dev/null +++ b/dlls/oleacc/oleacc.rc @@ -0,0 +1,30 @@ +/* + * Top level resource file for oleacc + * + * Copyright 2008 Nikolay Sivov + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "oleacc.h" + +#include "oleacc_De.rc" +#include "oleacc_En.rc" +#include "oleacc_Fr.rc" +#include "oleacc_Ko.rc" +#include "oleacc_Lt.rc" +#include "oleacc_Nl.rc" +#include "oleacc_Pl.rc" diff --git a/dlls/oleacc/oleacc.spec b/dlls/oleacc/oleacc.spec index 6ace5424f1c..2736a3d6070 100644 --- a/dlls/oleacc/oleacc.spec +++ b/dlls/oleacc/oleacc.spec @@ -16,5 +16,5 @@ @ stub IID_IAccessibleHandler @ stub LIBID_Accessibility @ stdcall LresultFromObject(ptr long ptr) -@ stdcall ObjectFromLresult(long ptr long ptr) +@ stub ObjectFromLresult @ stub WindowFromAccessibleObject diff --git a/dlls/oleacc/oleacc_De.rc b/dlls/oleacc/oleacc_De.rc index f15cc2dcbba..7d96d2a1960 100644 --- a/dlls/oleacc/oleacc_De.rc +++ b/dlls/oleacc/oleacc_De.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/oleacc/oleacc_En.rc b/dlls/oleacc/oleacc_En.rc index 5c1af2de217..992d29c93f0 100644 --- a/dlls/oleacc/oleacc_En.rc +++ b/dlls/oleacc/oleacc_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleacc/oleacc_Fr.rc b/dlls/oleacc/oleacc_Fr.rc index 8eabc3cd4d5..87bea0b5247 100644 --- a/dlls/oleacc/oleacc_Fr.rc +++ b/dlls/oleacc/oleacc_Fr.rc @@ -2,7 +2,6 @@ * French resources for oleacc * * Copyright 2008 Jonathan Ernst - * Copyright 2009 Frédéric Delanoy * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -19,37 +18,32 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { - 0 "objet inconnu" /* non documenté */ + 0 "objet inconnu" /* undocumented */ ROLE_SYSTEM_TITLEBAR "barre de titre" - ROLE_SYSTEM_MENUBAR "barre de menus" + ROLE_SYSTEM_MENUBAR "barre de menu" ROLE_SYSTEM_SCROLLBAR "barre de défilement" - ROLE_SYSTEM_GRIP "poignée" + ROLE_SYSTEM_GRIP "grip" ROLE_SYSTEM_SOUND "son" ROLE_SYSTEM_CURSOR "curseur" - ROLE_SYSTEM_CARET "curseur texte" + ROLE_SYSTEM_CARET "caret" ROLE_SYSTEM_ALERT "alerte" ROLE_SYSTEM_WINDOW "fenêtre" ROLE_SYSTEM_CLIENT "client" - ROLE_SYSTEM_MENUPOPUP "menu contextuel" + ROLE_SYSTEM_MENUPOPUP "menu popup" ROLE_SYSTEM_MENUITEM "élément de menu" ROLE_SYSTEM_TOOLTIP "infobulle" ROLE_SYSTEM_APPLICATION "application" ROLE_SYSTEM_DOCUMENT "document" - ROLE_SYSTEM_PANE "panneau" - ROLE_SYSTEM_CHART "diagramme" + ROLE_SYSTEM_PANE "pane" + ROLE_SYSTEM_CHART "chart" ROLE_SYSTEM_DIALOG "boîte de dialogue" ROLE_SYSTEM_BORDER "bordure" - ROLE_SYSTEM_GROUPING "groupement" - ROLE_SYSTEM_SEPARATOR "séparateur" + ROLE_SYSTEM_GROUPING "grouping" + ROLE_SYSTEM_SEPARATOR "separateur" ROLE_SYSTEM_TOOLBAR "barre d'outils" ROLE_SYSTEM_STATUSBAR "barre d'état" ROLE_SYSTEM_TABLE "table" @@ -63,8 +57,8 @@ STRINGTABLE DISCARDABLE ROLE_SYSTEM_CHARACTER "caractère" ROLE_SYSTEM_LIST "liste" ROLE_SYSTEM_LISTITEM "élément de liste" - ROLE_SYSTEM_OUTLINE "plan" - ROLE_SYSTEM_OUTLINEITEM "élément du plan" + ROLE_SYSTEM_OUTLINE "outline" + ROLE_SYSTEM_OUTLINEITEM "outline item" ROLE_SYSTEM_PAGETAB "onglet de page" ROLE_SYSTEM_PROPERTYPAGE "page de propriétés" ROLE_SYSTEM_INDICATOR "indicateur" @@ -74,23 +68,23 @@ STRINGTABLE DISCARDABLE ROLE_SYSTEM_PUSHBUTTON "bouton pressoir" ROLE_SYSTEM_CHECKBUTTON "case à cocher" ROLE_SYSTEM_RADIOBUTTON "bouton radio" - ROLE_SYSTEM_COMBOBOX "boîte combinée" - ROLE_SYSTEM_DROPLIST "liste déroulante" + ROLE_SYSTEM_COMBOBOX "combo box" + ROLE_SYSTEM_DROPLIST "drop down" ROLE_SYSTEM_PROGRESSBAR "barre de progression" - ROLE_SYSTEM_DIAL "cadran" - ROLE_SYSTEM_HOTKEYFIELD "champ avec raccourci clavier" - ROLE_SYSTEM_SLIDER "glissière" - ROLE_SYSTEM_SPINBUTTON "bouton fléché" + ROLE_SYSTEM_DIAL "dial" + ROLE_SYSTEM_HOTKEYFIELD "hot key field" + ROLE_SYSTEM_SLIDER "slider" + ROLE_SYSTEM_SPINBUTTON "spin box" ROLE_SYSTEM_DIAGRAM "diagramme" ROLE_SYSTEM_ANIMATION "animation" ROLE_SYSTEM_EQUATION "équation" - ROLE_SYSTEM_BUTTONDROPDOWN "bouton avec liste déroulante" + ROLE_SYSTEM_BUTTONDROPDOWN "drop down button" ROLE_SYSTEM_BUTTONMENU "bouton de menu" - ROLE_SYSTEM_BUTTONDROPDOWNGRID "bouton avec grille déroulante" - ROLE_SYSTEM_WHITESPACE "blanc" - ROLE_SYSTEM_PAGETABLIST "liste d'onglets de pages" + ROLE_SYSTEM_BUTTONDROPDOWNGRID "grid drop down button" + ROLE_SYSTEM_WHITESPACE "espace blanc" + ROLE_SYSTEM_PAGETABLIST "page tab list" ROLE_SYSTEM_CLOCK "horloge" - ROLE_SYSTEM_SPLITBUTTON "bouton avec menu" - ROLE_SYSTEM_IPADDRESS "adresse IP" - ROLE_SYSTEM_OUTLINEBUTTON "bouton de résumé" + ROLE_SYSTEM_SPLITBUTTON "split button" + ROLE_SYSTEM_IPADDRESS "Adresse IP" + ROLE_SYSTEM_OUTLINEBUTTON "outline button" } diff --git a/dlls/oleacc/oleacc_Ko.rc b/dlls/oleacc/oleacc_Ko.rc index 919b8d4e5f2..a1993f133f9 100644 --- a/dlls/oleacc/oleacc_Ko.rc +++ b/dlls/oleacc/oleacc_Ko.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleacc/oleacc_Lt.rc b/dlls/oleacc/oleacc_Lt.rc index 4056c3dd9d6..5498e847532 100644 --- a/dlls/oleacc/oleacc_Lt.rc +++ b/dlls/oleacc/oleacc_Lt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - /* UTF-8 */ #pragma code_page(65001) @@ -93,3 +91,5 @@ STRINGTABLE DISCARDABLE ROLE_SYSTEM_IPADDRESS "IP adresas" ROLE_SYSTEM_OUTLINEBUTTON "plano mygtukas" } + +#pragma code_page(default) diff --git a/dlls/oleacc/oleacc_Nl.rc b/dlls/oleacc/oleacc_Nl.rc index 47daa1fba20..1dce053555d 100644 --- a/dlls/oleacc/oleacc_Nl.rc +++ b/dlls/oleacc/oleacc_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/oleacc/oleacc_Pl.rc b/dlls/oleacc/oleacc_Pl.rc index 5d45368cf13..fc93cb052c3 100644 --- a/dlls/oleacc/oleacc_Pl.rc +++ b/dlls/oleacc/oleacc_Pl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - LANGUAGE LANG_POLISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/oleacc/oleacc_Pt.rc b/dlls/oleacc/oleacc_Pt.rc deleted file mode 100644 index 395324a4330..00000000000 --- a/dlls/oleacc/oleacc_Pt.rc +++ /dev/null @@ -1,94 +0,0 @@ -/* - * Portuguese resources for oleacc - * - * Copyright 2009 Ricardo Filipe - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "oleacc.h" - -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE - -STRINGTABLE DISCARDABLE -{ - 0 "objecto desconhecido" /* undocumented */ - ROLE_SYSTEM_TITLEBAR "barra de título" - ROLE_SYSTEM_MENUBAR "barra de menu" - ROLE_SYSTEM_SCROLLBAR "barra de scroll" - ROLE_SYSTEM_GRIP "grip" - ROLE_SYSTEM_SOUND "som" - ROLE_SYSTEM_CURSOR "cursor" - ROLE_SYSTEM_CARET "caret" - ROLE_SYSTEM_ALERT "alerta" - ROLE_SYSTEM_WINDOW "janela" - ROLE_SYSTEM_CLIENT "cliente" - ROLE_SYSTEM_MENUPOPUP "popup menu" - ROLE_SYSTEM_MENUITEM "item do menu" - ROLE_SYSTEM_TOOLTIP "dica" - ROLE_SYSTEM_APPLICATION "aplicação" - ROLE_SYSTEM_DOCUMENT "documento" - ROLE_SYSTEM_PANE "painel" - ROLE_SYSTEM_CHART "gráfico" - ROLE_SYSTEM_DIALOG "diálogo" - ROLE_SYSTEM_BORDER "margem" - ROLE_SYSTEM_GROUPING "agrupamento" - ROLE_SYSTEM_SEPARATOR "separador" - ROLE_SYSTEM_TOOLBAR "barra de ferramentas" - ROLE_SYSTEM_STATUSBAR "barra de estado" - ROLE_SYSTEM_TABLE "tabela" - ROLE_SYSTEM_COLUMNHEADER "cabeçalho da coluna" - ROLE_SYSTEM_ROWHEADER "cabeçalho da linha" - ROLE_SYSTEM_COLUMN "coluna" - ROLE_SYSTEM_ROW "linha" - ROLE_SYSTEM_CELL "célula" - ROLE_SYSTEM_LINK "ligação" - ROLE_SYSTEM_HELPBALLOON "balão de ajuda" - ROLE_SYSTEM_CHARACTER "caracter" - ROLE_SYSTEM_LIST "lista" - ROLE_SYSTEM_LISTITEM "item da lista" - ROLE_SYSTEM_OUTLINE "delinear" - ROLE_SYSTEM_OUTLINEITEM "item delinear" - ROLE_SYSTEM_PAGETAB "tab de página" - ROLE_SYSTEM_PROPERTYPAGE "página de propriedades" - ROLE_SYSTEM_INDICATOR "indicador" - ROLE_SYSTEM_GRAPHIC "gráfico" - ROLE_SYSTEM_STATICTEXT "texto estático" - ROLE_SYSTEM_TEXT "texto" - ROLE_SYSTEM_PUSHBUTTON "push button" - ROLE_SYSTEM_CHECKBUTTON "check button" - ROLE_SYSTEM_RADIOBUTTON "radio button" - ROLE_SYSTEM_COMBOBOX "combo box" - ROLE_SYSTEM_DROPLIST "drop down" - ROLE_SYSTEM_PROGRESSBAR "barra de progresso" - ROLE_SYSTEM_DIAL "dial" - ROLE_SYSTEM_HOTKEYFIELD "hot key field" - ROLE_SYSTEM_SLIDER "slider" - ROLE_SYSTEM_SPINBUTTON "spin box" - ROLE_SYSTEM_DIAGRAM "diagrama" - ROLE_SYSTEM_ANIMATION "animação" - ROLE_SYSTEM_EQUATION "equação" - ROLE_SYSTEM_BUTTONDROPDOWN "drop down button" - ROLE_SYSTEM_BUTTONMENU "menu button" - ROLE_SYSTEM_BUTTONDROPDOWNGRID "grid drop down button" - ROLE_SYSTEM_WHITESPACE "espaço em branco" - ROLE_SYSTEM_PAGETABLIST "page tab list" - ROLE_SYSTEM_CLOCK "relógio" - ROLE_SYSTEM_SPLITBUTTON "split button" - ROLE_SYSTEM_IPADDRESS "endereço IP" - ROLE_SYSTEM_OUTLINEBUTTON "outline button" -} diff --git a/dlls/oleaut32/Makefile.in b/dlls/oleaut32/Makefile.in index 0f2be7fc609..5d41598b179 100644 --- a/dlls/oleaut32/Makefile.in +++ b/dlls/oleaut32/Makefile.in @@ -30,32 +30,7 @@ C_SRCS = \ variant.c \ vartype.c -RC_SRCS = \ - oleaut32_Bg.rc \ - oleaut32_Cz.rc \ - oleaut32_Da.rc \ - oleaut32_De.rc \ - oleaut32_El.rc \ - oleaut32_En.rc \ - oleaut32_Eo.rc \ - oleaut32_Es.rc \ - oleaut32_Fr.rc \ - oleaut32_Hu.rc \ - oleaut32_It.rc \ - oleaut32_Ko.rc \ - oleaut32_Lt.rc \ - oleaut32_Nl.rc \ - oleaut32_No.rc \ - oleaut32_Pl.rc \ - oleaut32_Pt.rc \ - oleaut32_Ro.rc \ - oleaut32_Ru.rc \ - oleaut32_Si.rc \ - oleaut32_Sv.rc \ - oleaut32_Th.rc \ - oleaut32_Tr.rc \ - oleaut32_Zh.rc \ - version.rc +RC_SRCS = oleaut32.rc IDL_P_SRCS = \ oleaut32_oaidl.idl \ diff --git a/dlls/oleaut32/oleaut32.rc b/dlls/oleaut32/oleaut32.rc new file mode 100644 index 00000000000..206a5396b36 --- /dev/null +++ b/dlls/oleaut32/oleaut32.rc @@ -0,0 +1,56 @@ +/* + * Top level resource file for oleaut32 + * + * Copyright 2003 Jon Griffiths + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "resource.h" + +#include "version.rc" + +#include "oleaut32_Bg.rc" +#include "oleaut32_Da.rc" +#include "oleaut32_De.rc" +#include "oleaut32_El.rc" +#include "oleaut32_En.rc" +#include "oleaut32_Eo.rc" +#include "oleaut32_Es.rc" +#include "oleaut32_Cz.rc" +#include "oleaut32_Fr.rc" +#include "oleaut32_Hu.rc" +#include "oleaut32_It.rc" +#include "oleaut32_Ko.rc" +#include "oleaut32_Nl.rc" +#include "oleaut32_No.rc" +#include "oleaut32_Pl.rc" +#include "oleaut32_Pt.rc" +#include "oleaut32_Ro.rc" +#include "oleaut32_Ru.rc" +#include "oleaut32_Si.rc" +#include "oleaut32_Sv.rc" +#include "oleaut32_Th.rc" +#include "oleaut32_Tr.rc" +#include "oleaut32_Zh.rc" + +/* + * FIXME: + * Finnish, Greek, Hebrew, Japanese, Korean, + * Turkish (at least) are localised in XP Home. + * I expect Chinese etc are localised in Asian Editions also. + */ diff --git a/dlls/oleaut32/oleaut32_Bg.rc b/dlls/oleaut32/oleaut32_Bg.rc index 7f0180b2b09..7e930f41020 100644 --- a/dlls/oleaut32/oleaut32_Bg.rc +++ b/dlls/oleaut32/oleaut32_Bg.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Cz.rc b/dlls/oleaut32/oleaut32_Cz.rc index 48be0b70a82..7075b43cc0e 100644 --- a/dlls/oleaut32/oleaut32_Cz.rc +++ b/dlls/oleaut32/oleaut32_Cz.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Da.rc b/dlls/oleaut32/oleaut32_Da.rc index e28922fa1bf..6f1dcbcad91 100644 --- a/dlls/oleaut32/oleaut32_Da.rc +++ b/dlls/oleaut32/oleaut32_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_De.rc b/dlls/oleaut32/oleaut32_De.rc index 1dbee3ee8c7..9fb786cfca0 100644 --- a/dlls/oleaut32/oleaut32_De.rc +++ b/dlls/oleaut32/oleaut32_De.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_El.rc b/dlls/oleaut32/oleaut32_El.rc index a0337950262..145c1a12959 100644 --- a/dlls/oleaut32/oleaut32_El.rc +++ b/dlls/oleaut32/oleaut32_El.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_GREEK, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_En.rc b/dlls/oleaut32/oleaut32_En.rc index 6a98642e7ca..e56eb11d6e3 100644 --- a/dlls/oleaut32/oleaut32_En.rc +++ b/dlls/oleaut32/oleaut32_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Eo.rc b/dlls/oleaut32/oleaut32_Eo.rc index ae67139109e..c00e2fd4f44 100644 --- a/dlls/oleaut32/oleaut32_Eo.rc +++ b/dlls/oleaut32/oleaut32_Eo.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Es.rc b/dlls/oleaut32/oleaut32_Es.rc index 5c187db364f..5cc25ca49d5 100644 --- a/dlls/oleaut32/oleaut32_Es.rc +++ b/dlls/oleaut32/oleaut32_Es.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Fr.rc b/dlls/oleaut32/oleaut32_Fr.rc index d6136ef8cda..40e392ee162 100644 --- a/dlls/oleaut32/oleaut32_Fr.rc +++ b/dlls/oleaut32/oleaut32_Fr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Hu.rc b/dlls/oleaut32/oleaut32_Hu.rc index ec3b9827e3f..35283c8314a 100644 --- a/dlls/oleaut32/oleaut32_Hu.rc +++ b/dlls/oleaut32/oleaut32_Hu.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_It.rc b/dlls/oleaut32/oleaut32_It.rc index 69fa31a34a7..0dee161a217 100644 --- a/dlls/oleaut32/oleaut32_It.rc +++ b/dlls/oleaut32/oleaut32_It.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Ko.rc b/dlls/oleaut32/oleaut32_Ko.rc index 541380543a5..0134c7a54b9 100644 --- a/dlls/oleaut32/oleaut32_Ko.rc +++ b/dlls/oleaut32/oleaut32_Ko.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Lt.rc b/dlls/oleaut32/oleaut32_Lt.rc deleted file mode 100644 index c568d93cb78..00000000000 --- a/dlls/oleaut32/oleaut32_Lt.rc +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Lithuanian resources for oleaut32 - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_TRUE "Tiesa" - IDS_FALSE "Netiesa" - IDS_YES "Taip" - IDS_NO "Ne" - IDS_ON "Įjungta" - IDS_OFF "Išjungta" -} diff --git a/dlls/oleaut32/oleaut32_Nl.rc b/dlls/oleaut32/oleaut32_Nl.rc index e2ae3dea380..6affb2d638c 100644 --- a/dlls/oleaut32/oleaut32_Nl.rc +++ b/dlls/oleaut32/oleaut32_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_No.rc b/dlls/oleaut32/oleaut32_No.rc index 1f99f7bbe56..7ca883c350d 100644 --- a/dlls/oleaut32/oleaut32_No.rc +++ b/dlls/oleaut32/oleaut32_No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Pl.rc b/dlls/oleaut32/oleaut32_Pl.rc index 7d34796fd0b..8c250cbbb9f 100644 --- a/dlls/oleaut32/oleaut32_Pl.rc +++ b/dlls/oleaut32/oleaut32_Pl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Pt.rc b/dlls/oleaut32/oleaut32_Pt.rc index de008bbd0f9..1cbd389209a 100644 --- a/dlls/oleaut32/oleaut32_Pt.rc +++ b/dlls/oleaut32/oleaut32_Pt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Ro.rc b/dlls/oleaut32/oleaut32_Ro.rc index 3a37a69ddef..52421a8cca2 100644 --- a/dlls/oleaut32/oleaut32_Ro.rc +++ b/dlls/oleaut32/oleaut32_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -32,3 +30,5 @@ STRINGTABLE DISCARDABLE IDS_ON "Activat" IDS_OFF "Dezactivat" } + +#pragma code_page(default) diff --git a/dlls/oleaut32/oleaut32_Ru.rc b/dlls/oleaut32/oleaut32_Ru.rc index 7555c3aa25a..194ca9e1a8e 100644 --- a/dlls/oleaut32/oleaut32_Ru.rc +++ b/dlls/oleaut32/oleaut32_Ru.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Si.rc b/dlls/oleaut32/oleaut32_Si.rc index 32a80adefb6..365d877045c 100644 --- a/dlls/oleaut32/oleaut32_Si.rc +++ b/dlls/oleaut32/oleaut32_Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -33,3 +31,5 @@ STRINGTABLE DISCARDABLE IDS_ON "Vključeno" IDS_OFF "Izključeno" } + +#pragma code_page(default) diff --git a/dlls/oleaut32/oleaut32_Sv.rc b/dlls/oleaut32/oleaut32_Sv.rc index 4362a068bab..387b25eb0c4 100644 --- a/dlls/oleaut32/oleaut32_Sv.rc +++ b/dlls/oleaut32/oleaut32_Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Th.rc b/dlls/oleaut32/oleaut32_Th.rc index 8fcf212a969..22f01f74ee3 100644 --- a/dlls/oleaut32/oleaut32_Th.rc +++ b/dlls/oleaut32/oleaut32_Th.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_THAI, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Tr.rc b/dlls/oleaut32/oleaut32_Tr.rc index 08d841a92a4..cc2f3e6f878 100644 --- a/dlls/oleaut32/oleaut32_Tr.rc +++ b/dlls/oleaut32/oleaut32_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/oleaut32/oleaut32_Zh.rc b/dlls/oleaut32/oleaut32_Zh.rc index bbb9e06433e..320c40ff5dd 100644 --- a/dlls/oleaut32/oleaut32_Zh.rc +++ b/dlls/oleaut32/oleaut32_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -46,3 +44,5 @@ STRINGTABLE DISCARDABLE IDS_ON "開" IDS_OFF "關" } + +#pragma code_page(default) diff --git a/dlls/oleaut32/olefont.c b/dlls/oleaut32/olefont.c index a9b2c047abf..3e008443ff7 100644 --- a/dlls/oleaut32/olefont.c +++ b/dlls/oleaut32/olefont.c @@ -132,8 +132,8 @@ struct OLEFontImpl /* * Size ratio */ - LONG cyLogical; - LONG cyHimetric; + long cyLogical; + long cyHimetric; IConnectionPoint *pPropertyNotifyCP; IConnectionPoint *pFontEventsCP; diff --git a/dlls/oleaut32/olepicture.c b/dlls/oleaut32/olepicture.c index 54baf125ad2..4409a150326 100644 --- a/dlls/oleaut32/olepicture.c +++ b/dlls/oleaut32/olepicture.c @@ -1232,6 +1232,7 @@ static HRESULT OLEPictureImpl_LoadGif(OLEPictureImpl *This, BYTE *xbuf, ULONG xr if (pixel == (transparent & 0x000000FFU)) monoPointer[j >> 3] |= 1 << (7 - (j & 7)); } } + hdcref = GetDC(0); hTempMask = CreateDIBitmap( hdcref, &bmi->bmiHeader, @@ -1240,6 +1241,7 @@ static HRESULT OLEPictureImpl_LoadGif(OLEPictureImpl *This, BYTE *xbuf, ULONG xr bmi, DIB_RGB_COLORS ); + DeleteDC(hdcref); bmi->bmiHeader.biHeight = -bmi->bmiHeader.biHeight; This->hbmMask = CreateBitmap(bmi->bmiHeader.biWidth, bmi->bmiHeader.biHeight, 1, 1, NULL); @@ -1264,7 +1266,7 @@ static HRESULT OLEPictureImpl_LoadGif(OLEPictureImpl *This, BYTE *xbuf, ULONG xr DeleteObject(hTempMask); } - ReleaseDC(0, hdcref); + DeleteDC(hdcref); This->desc.picType = PICTYPE_BITMAP; OLEPictureImpl_SetBitmap(This); DGifCloseFile(gif); @@ -1367,7 +1369,7 @@ static HRESULT OLEPictureImpl_LoadJpeg(OLEPictureImpl *This, BYTE *xbuf, ULONG x (BITMAPINFO*)&bmi, DIB_RGB_COLORS ); - ReleaseDC(0, hdcref); + DeleteDC(hdcref); This->desc.picType = PICTYPE_BITMAP; OLEPictureImpl_SetBitmap(This); HeapFree(GetProcessHeap(),0,bits); @@ -1396,7 +1398,7 @@ static HRESULT OLEPictureImpl_LoadDIB(OLEPictureImpl *This, BYTE *xbuf, ULONG xr bi, DIB_RGB_COLORS ); - ReleaseDC(0, hdcref); + DeleteDC(hdcref); if (This->desc.u.bmp.hbitmap == 0) return E_FAIL; This->desc.picType = PICTYPE_BITMAP; diff --git a/dlls/oleaut32/resource.h b/dlls/oleaut32/resource.h index 550170afc61..5c72c7e0acb 100644 --- a/dlls/oleaut32/resource.h +++ b/dlls/oleaut32/resource.h @@ -20,8 +20,6 @@ #ifndef WINE_OLEAUT32_RESOURCE_H #define WINE_OLEAUT32_RESOURCE_H -#include - /* Localised boolean text */ #define IDS_TRUE 100 #define IDS_FALSE 101 diff --git a/dlls/oleaut32/tests/usrmarshal.c b/dlls/oleaut32/tests/usrmarshal.c index d1809460238..38827b1dcd9 100644 --- a/dlls/oleaut32/tests/usrmarshal.c +++ b/dlls/oleaut32/tests/usrmarshal.c @@ -118,7 +118,7 @@ static void check_safearray(void *buffer, LPSAFEARRAY lpsa) if(!lpsa) { - ok(*(DWORD *)wiresa == 0, "wiresa + 0x0 should be NULL instead of 0x%08x\n", *(DWORD *)wiresa); + ok(*(void **)wiresa == NULL, "wiresa + 0x0 should be NULL instead of 0x%08x\n", *(DWORD *)wiresa); return; } @@ -134,19 +134,19 @@ static void check_safearray(void *buffer, LPSAFEARRAY lpsa) wiresa += sizeof(DWORD); ok(*(WORD *)wiresa == lpsa->cDims, "wiresa + 0x8 should be lpsa->cDims instead of 0x%04x\n", *(WORD *)wiresa); wiresa += sizeof(WORD); - ok(*(WORD *)wiresa == lpsa->fFeatures, "wiresa + 0xa should be lpsa->fFeatures instead of 0x%08x\n", *(WORD *)wiresa); + ok(*(WORD *)wiresa == lpsa->fFeatures, "wiresa + 0xc should be lpsa->fFeatures instead of 0x%08x\n", *(WORD *)wiresa); wiresa += sizeof(WORD); - ok(*(DWORD *)wiresa == lpsa->cbElements, "wiresa + 0xc should be lpsa->cbElements instead of 0x%08x\n", *(DWORD *)wiresa); + ok(*(DWORD *)wiresa == lpsa->cbElements, "wiresa + 0x10 should be lpsa->cbElements instead of 0x%08x\n", *(DWORD *)wiresa); wiresa += sizeof(DWORD); - ok(*(WORD *)wiresa == lpsa->cLocks, "wiresa + 0x10 should be lpsa->cLocks instead of 0x%04x\n", *(WORD *)wiresa); + ok(*(WORD *)wiresa == lpsa->cLocks, "wiresa + 0x16 should be lpsa->cLocks instead of 0x%04x\n", *(WORD *)wiresa); wiresa += sizeof(WORD); - ok(*(WORD *)wiresa == vt, "wiresa + 0x12 should be %04x instead of 0x%04x\n", vt, *(WORD *)wiresa); + ok(*(WORD *)wiresa == vt, "wiresa + 0x14 should be %04x instead of 0x%04x\n", vt, *(WORD *)wiresa); wiresa += sizeof(WORD); - ok(*(DWORD *)wiresa == sftype, "wiresa + 0x14 should be %08x instead of 0x%08x\n", (DWORD)sftype, *(DWORD *)wiresa); + ok(*(DWORD *)wiresa == sftype, "wiresa + 0x18 should be %08x instead of 0x%08x\n", (DWORD)sftype, *(DWORD *)wiresa); wiresa += sizeof(DWORD); - ok(*(DWORD *)wiresa == cell_count, "wiresa + 0x18 should be %u instead of %u\n", cell_count, *(DWORD *)wiresa); + ok(*(DWORD *)wiresa == cell_count, "wiresa + 0x1c should be %u instead of %u\n", cell_count, *(DWORD *)wiresa); wiresa += sizeof(DWORD); - ok(*(DWORD *)wiresa, "wiresa + 0x1c should be non-zero instead of 0x%08x\n", *(DWORD *)wiresa); + ok(*(DWORD *)wiresa, "wiresa + 0x20 should be non-zero instead of 0x%08x\n", *(DWORD *)wiresa); wiresa += sizeof(DWORD); if(sftype == SF_HAVEIID) { @@ -158,7 +158,7 @@ static void check_safearray(void *buffer, LPSAFEARRAY lpsa) ok(!memcmp(wiresa, lpsa->rgsabound, sizeof(lpsa->rgsabound[0]) * lpsa->cDims), "bounds mismatch\n"); wiresa += sizeof(lpsa->rgsabound[0]) * lpsa->cDims; - ok(*(DWORD *)wiresa == cell_count, "wiresa + 0x28 should be %u instead of %u\n", cell_count, *(DWORD*)wiresa); + ok(*(DWORD *)wiresa == cell_count, "wiresa + 0x2c should be %u instead of %u\n", cell_count, *(DWORD*)wiresa); wiresa += sizeof(DWORD); /* elements are now pointed to by wiresa */ } @@ -198,7 +198,7 @@ static void init_user_marshal_cb(USER_MARSHAL_CB *umcb, static void test_marshal_LPSAFEARRAY(void) { unsigned char *buffer; - ULONG size, expected; + ULONG size; LPSAFEARRAY lpsa; LPSAFEARRAY lpsa2 = NULL; SAFEARRAYBOUND sab; @@ -217,15 +217,10 @@ static void test_marshal_LPSAFEARRAY(void) lpsa->cLocks = 7; init_user_marshal_cb(&umcb, &stub_msg, &rpc_msg, NULL, 0, MSHCTX_DIFFERENTMACHINE); size = LPSAFEARRAY_UserSize(&umcb.Flags, 1, &lpsa); - expected = (44 + 1 + sizeof(ULONG) - 1) & ~(sizeof(ULONG) - 1); - expected += sab.cElements * sizeof(USHORT); - ok(size == expected || size == expected + 12, /* win64 */ - "size should be %u bytes, not %u\n", expected, size); + ok(size == 68, "size should be 68 bytes, not %d\n", size); init_user_marshal_cb(&umcb, &stub_msg, &rpc_msg, NULL, 0, MSHCTX_DIFFERENTMACHINE); size = LPSAFEARRAY_UserSize(&umcb.Flags, 0, &lpsa); - expected = 44 + sab.cElements * sizeof(USHORT); - ok(size == expected || size == expected + 12, /* win64 */ - "size should be %u bytes, not %u\n", expected, size); + ok(size == 64, "size should be 64 bytes, not %d\n", size); buffer = HeapAlloc(GetProcessHeap(), 0, size); init_user_marshal_cb(&umcb, &stub_msg, &rpc_msg, buffer, size, MSHCTX_DIFFERENTMACHINE); LPSAFEARRAY_UserMarshal(&umcb.Flags, buffer, &lpsa); @@ -278,16 +273,10 @@ static void test_marshal_LPSAFEARRAY(void) lpsa->cLocks = 7; init_user_marshal_cb(&umcb, &stub_msg, &rpc_msg, NULL, 0, MSHCTX_DIFFERENTMACHINE); size = LPSAFEARRAY_UserSize(&umcb.Flags, 1, &lpsa); - expected = (44 + 1 + (sizeof(double) - 1)) & ~(sizeof(double) - 1); - expected += sab.cElements * sizeof(double); - ok(size == expected || size == expected + 16, /* win64 */ - "size should be %u bytes, not %u\n", expected, size); + ok(size == 128, "size should be 128 bytes, not %d\n", size); init_user_marshal_cb(&umcb, &stub_msg, &rpc_msg, NULL, 0, MSHCTX_DIFFERENTMACHINE); - expected = (44 + (sizeof(double) - 1)) & ~(sizeof(double) - 1); - expected += sab.cElements * sizeof(double); size = LPSAFEARRAY_UserSize(&umcb.Flags, 0, &lpsa); - ok(size == expected || size == expected + 8, /* win64 */ - "size should be %u bytes, not %u\n", expected, size); + ok(size == 128, "size should be 128 bytes, not %d\n", size); buffer = HeapAlloc(GetProcessHeap(), 0, size); init_user_marshal_cb(&umcb, &stub_msg, &rpc_msg, buffer, size, MSHCTX_DIFFERENTMACHINE); LPSAFEARRAY_UserMarshal(&umcb.Flags, buffer, &lpsa); @@ -312,10 +301,7 @@ static void test_marshal_LPSAFEARRAY(void) init_user_marshal_cb(&umcb, &stub_msg, &rpc_msg, NULL, 0, MSHCTX_DIFFERENTMACHINE); size = LPSAFEARRAY_UserSize(&umcb.Flags, 0, &lpsa); - expected = (44 + lpsa->cbElements - 1) & ~(lpsa->cbElements - 1); - expected += lpsa->cbElements * lpsa->rgsabound[0].cElements; - ok(size == expected || size == expected + 8, /* win64 */ - "size should be %u bytes, not %u\n", expected, size); + ok(size == 432, "size %d\n", size); buffer = HeapAlloc(GetProcessHeap(), 0, size); init_user_marshal_cb(&umcb, &stub_msg, &rpc_msg, buffer, size, MSHCTX_DIFFERENTMACHINE); LPSAFEARRAY_UserMarshal(&umcb.Flags, buffer, &lpsa); @@ -327,7 +313,7 @@ static void test_marshal_LPSAFEARRAY(void) /* VARTYPE-less arrays with FADF_VARIANT */ hr = SafeArrayAllocDescriptor(1, &lpsa); ok(hr == S_OK, "saad failed %08x\n", hr); - lpsa->cbElements = sizeof(VARIANT); + lpsa->cbElements = 16; lpsa->fFeatures = FADF_VARIANT; lpsa->rgsabound[0].lLbound = 2; lpsa->rgsabound[0].cElements = 48; @@ -339,14 +325,11 @@ static void test_marshal_LPSAFEARRAY(void) init_user_marshal_cb(&umcb, &stub_msg, &rpc_msg, NULL, 0, MSHCTX_DIFFERENTMACHINE); size = LPSAFEARRAY_UserSize(&umcb.Flags, 0, &lpsa); - expected = 44 + 28 * lpsa->rgsabound[0].cElements; todo_wine - ok(size == expected || size == expected + 8, /* win64 */ - "size should be %u bytes, not %u\n", expected, size); + ok(size == 1388, "size %d\n", size); buffer = HeapAlloc(GetProcessHeap(), 0, size); init_user_marshal_cb(&umcb, &stub_msg, &rpc_msg, buffer, size, MSHCTX_DIFFERENTMACHINE); LPSAFEARRAY_UserMarshal(&umcb.Flags, buffer, &lpsa); - lpsa->cbElements = 16; /* VARIANT wire size */ check_safearray(buffer, lpsa); HeapFree(GetProcessHeap(), 0, buffer); SafeArrayDestroyData(lpsa); @@ -572,15 +555,6 @@ static void check_variant_header(DWORD *wirev, VARIANT *v, ULONG size) ok(*wirev == switch_is, "switch_is %08x expected %08x\n", *wirev, switch_is); } -/* Win9x and WinME don't always align as needed. Variants have - * an alignment of 8. - */ -static void *alloc_aligned(SIZE_T size, void **buf) -{ - *buf = HeapAlloc(GetProcessHeap(), 0, size + 7); - return (void *)(((UINT_PTR)*buf + 7) & ~7); -} - static void test_marshal_VARIANT(void) { VARIANT v, v2; @@ -588,7 +562,6 @@ static void test_marshal_VARIANT(void) RPC_MESSAGE rpcMsg = { 0 }; USER_MARSHAL_CB umcb = { 0 }; unsigned char *buffer, *next; - void *oldbuffer; ULONG ul; short s; double d; @@ -599,7 +572,6 @@ static void test_marshal_VARIANT(void) LPSAFEARRAY lpsa; DECIMAL dec, dec2; HeapUnknown *heap_unknown; - DWORD expected; stubMsg.RpcMsg = &rpcMsg; @@ -628,7 +600,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 21, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -648,7 +620,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** I2 ***/ VariantInit(&v); @@ -658,7 +630,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 22, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -678,7 +650,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** I2 BYREF ***/ VariantInit(&v); @@ -689,7 +661,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 26, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -715,7 +687,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** I4 ***/ VariantInit(&v); @@ -725,7 +697,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 24, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -746,7 +718,8 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + + HeapFree(GetProcessHeap(), 0, buffer); /*** UI4 ***/ VariantInit(&v); @@ -756,7 +729,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 24, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -776,7 +749,8 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + + HeapFree(GetProcessHeap(), 0, buffer); /*** UI4 BYREF ***/ VariantInit(&v); @@ -787,7 +761,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 28, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -810,7 +784,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** R4 ***/ VariantInit(&v); @@ -820,7 +794,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 24, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -840,7 +814,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** R8 ***/ VariantInit(&v); @@ -850,7 +824,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 32, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; memset(buffer, 0xcc, stubMsg.BufferLength); next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); @@ -873,7 +847,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** R8 BYREF ***/ VariantInit(&v); @@ -884,7 +858,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 32, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -906,7 +880,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** VARIANT_BOOL ***/ VariantInit(&v); @@ -916,7 +890,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 22, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -936,7 +910,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** DECIMAL ***/ VarDecFromI4(0x12345678, &dec); @@ -948,7 +922,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 40, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; memset(buffer, 0xcc, stubMsg.BufferLength); next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); @@ -974,7 +948,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** DECIMAL BYREF ***/ VariantInit(&v); @@ -984,7 +958,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 40, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -1013,7 +987,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** EMPTY ***/ VariantInit(&v); @@ -1022,7 +996,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 20, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -1039,7 +1013,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** NULL ***/ VariantInit(&v); @@ -1048,7 +1022,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 20, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -1065,7 +1039,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** BSTR ***/ b = SysAllocString(str); @@ -1075,7 +1049,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 60, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -1098,7 +1072,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** BSTR BYREF ***/ VariantInit(&v); @@ -1107,7 +1081,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 64, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); @@ -1132,7 +1106,7 @@ static void test_marshal_VARIANT(void) VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); SysFreeString(b); /*** ARRAY ***/ @@ -1148,16 +1122,14 @@ static void test_marshal_VARIANT(void) V_ARRAY(&v) = lpsa; rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); - expected = 152; - ok(stubMsg.BufferLength == expected || stubMsg.BufferLength == expected + 8, /* win64 */ - "size %u instead of %u\n", stubMsg.BufferLength, expected); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + ok(stubMsg.BufferLength == 152, "size %d\n", stubMsg.BufferLength); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); - ok(next == buffer + expected, "got %p expect %p\n", next, buffer + expected); + ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); wirev = (DWORD*)buffer; - check_variant_header(wirev, &v, expected); + check_variant_header(wirev, &v, stubMsg.BufferLength); wirev += 5; ok(*wirev, "wv[5] %08x\n", *wirev); /* win2k: this is lpsa. winxp: this is (char*)lpsa + 1 */ wirev++; @@ -1169,7 +1141,7 @@ static void test_marshal_VARIANT(void) VariantInit(&v2); stubMsg.Buffer = buffer; next = VARIANT_UserUnmarshal(&umcb.Flags, buffer, &v2); - ok(next == buffer + expected, "got %p expect %p\n", next, buffer + expected); + ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); ok(V_VT(&v) == V_VT(&v2), "got vt %d expect %d\n", V_VT(&v), V_VT(&v2)); ok(SafeArrayGetDim(V_ARRAY(&v)) == SafeArrayGetDim(V_ARRAY(&v)), "array dims differ\n"); SafeArrayGetLBound(V_ARRAY(&v), 1, &bound); @@ -1183,7 +1155,7 @@ static void test_marshal_VARIANT(void) ok(vt == vt2, "array vts differ %x %x\n", vt, vt2); VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** ARRAY BYREF ***/ VariantInit(&v); @@ -1191,16 +1163,14 @@ static void test_marshal_VARIANT(void) V_ARRAYREF(&v) = &lpsa; rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); - expected = 152; - ok(stubMsg.BufferLength == expected || stubMsg.BufferLength == expected + 16, /* win64 */ - "size %u instead of %u\n", stubMsg.BufferLength, expected); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + ok(stubMsg.BufferLength == 152, "size %d\n", stubMsg.BufferLength); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); - ok(next == buffer + expected, "got %p expect %p\n", next, buffer + expected); + ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); wirev = (DWORD*)buffer; - - check_variant_header(wirev, &v, expected); + + check_variant_header(wirev, &v, stubMsg.BufferLength); wirev += 5; ok(*wirev == 4, "wv[5] %08x\n", *wirev); wirev++; @@ -1214,7 +1184,7 @@ static void test_marshal_VARIANT(void) VariantInit(&v2); stubMsg.Buffer = buffer; next = VARIANT_UserUnmarshal(&umcb.Flags, buffer, &v2); - ok(next == buffer + expected, "got %p expect %p\n", next, buffer + expected); + ok(next == buffer + stubMsg.BufferLength, "got %p expect %p\n", next, buffer + stubMsg.BufferLength); ok(V_VT(&v) == V_VT(&v2), "got vt %d expect %d\n", V_VT(&v), V_VT(&v2)); ok(SafeArrayGetDim(*V_ARRAYREF(&v)) == SafeArrayGetDim(*V_ARRAYREF(&v)), "array dims differ\n"); SafeArrayGetLBound(*V_ARRAYREF(&v), 1, &bound); @@ -1228,7 +1198,7 @@ static void test_marshal_VARIANT(void) ok(vt == vt2, "array vts differ %x %x\n", vt, vt2); VARIANT_UserFree(&umcb.Flags, &v2); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); SafeArrayDestroy(lpsa); /*** VARIANT BYREF ***/ @@ -1241,7 +1211,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength == 64, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; memset(buffer, 0xcc, stubMsg.BufferLength); next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); @@ -1250,7 +1220,7 @@ static void test_marshal_VARIANT(void) check_variant_header(wirev, &v, stubMsg.BufferLength); wirev += 5; - ok(*wirev == sizeof(VARIANT), "wv[5] %08x\n", *wirev); + ok(*wirev == 16, "wv[5] %08x\n", *wirev); wirev++; ok(*wirev == ('U' | 's' << 8 | 'e' << 16 | 'r' << 24), "wv[6] %08x\n", *wirev); /* 'User' */ wirev++; @@ -1274,7 +1244,7 @@ static void test_marshal_VARIANT(void) ok(V_R8(V_VARIANTREF(&v)) == V_R8(V_VARIANTREF(&v3)), "r8s differ\n"); VARIANT_UserFree(&umcb.Flags, &v3); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** UNKNOWN ***/ heap_unknown = HeapAlloc(GetProcessHeap(), 0, sizeof(*heap_unknown)); @@ -1287,7 +1257,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength > 32, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; memset(buffer, 0xcc, stubMsg.BufferLength); next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); @@ -1322,7 +1292,7 @@ static void test_marshal_VARIANT(void) ok(heap_unknown->refs == 1, "%d refcounts of IUnknown leaked\n", heap_unknown->refs - 1); IUnknown_Release((IUnknown *)heap_unknown); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); /*** UNKNOWN BYREF ***/ heap_unknown = HeapAlloc(GetProcessHeap(), 0, sizeof(*heap_unknown)); @@ -1335,7 +1305,7 @@ static void test_marshal_VARIANT(void) rpcMsg.BufferLength = stubMsg.BufferLength = VARIANT_UserSize(&umcb.Flags, 0, &v); ok(stubMsg.BufferLength > 36, "size %d\n", stubMsg.BufferLength); - buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = alloc_aligned(stubMsg.BufferLength, &oldbuffer); + buffer = rpcMsg.Buffer = stubMsg.Buffer = stubMsg.BufferStart = HeapAlloc(GetProcessHeap(), 0, stubMsg.BufferLength); stubMsg.BufferEnd = stubMsg.Buffer + stubMsg.BufferLength; memset(buffer, 0xcc, stubMsg.BufferLength); next = VARIANT_UserMarshal(&umcb.Flags, buffer, &v); @@ -1372,7 +1342,7 @@ static void test_marshal_VARIANT(void) ok(heap_unknown->refs == 1, "%d refcounts of IUnknown leaked\n", heap_unknown->refs - 1); IUnknown_Release((IUnknown *)heap_unknown); } - HeapFree(GetProcessHeap(), 0, oldbuffer); + HeapFree(GetProcessHeap(), 0, buffer); } diff --git a/dlls/oleaut32/tests/vartype.c b/dlls/oleaut32/tests/vartype.c index 419e0273d0a..7600946f53e 100644 --- a/dlls/oleaut32/tests/vartype.c +++ b/dlls/oleaut32/tests/vartype.c @@ -3434,11 +3434,6 @@ static void test_VarDateFromStr(void) DFS("1/2/1970"); EXPECT_DBL(25570.0); DFS("1-2-1970"); EXPECT_DBL(25570.0); /* Native fails "1999 January 3, 9AM". I consider that a bug in native */ - - /* test a none english data string */ - DFS("02.01.1970 00:00:00"); EXPECT_MISMATCH; - lcid = MAKELCID(MAKELANGID(LANG_GERMAN,SUBLANG_GERMAN),SORT_DEFAULT); - DFS("02.01.1970 00:00:00"); todo_wine EXPECT_DBL(25570.0); } static void test_VarDateCopy(void) @@ -4413,104 +4408,9 @@ static void test_VarDecCmp(void) MATHVARS1; CHECKPTR(VarDecCmp); - SETDEC(l,0,0,0,1); SETDEC(out,0,0,0,1); MATH1(VarDecCmp); EXPECT_EQ; SETDEC(l,0,0,0,1); SETDEC(out,0,0,0,0); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(l,0,0,0,1); SETDEC(out,0,0,-1,-1); MATH1(VarDecCmp); EXPECT_LT; - - SETDEC(l,0,0,0,1); SETDEC(out,0,DECIMAL_NEG,0,1); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(l,0,0,0,1); SETDEC(out,0,DECIMAL_NEG,0,0); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(l,0,0,0,1); SETDEC(out,0,DECIMAL_NEG,-1,-1); MATH1(VarDecCmp); EXPECT_GT; - - SETDEC(l,0,DECIMAL_NEG,0,1); SETDEC(out,0,0,0,1); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(l,0,DECIMAL_NEG,0,1); SETDEC(out,0,0,0,0); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(l,0,DECIMAL_NEG,0,1); SETDEC(out,0,0,-1,-1); MATH1(VarDecCmp); EXPECT_LT; - - SETDEC(l,0,DECIMAL_NEG,0,1); SETDEC(out,0,DECIMAL_NEG,0,1); MATH1(VarDecCmp); EXPECT_EQ; - SETDEC(l,0,DECIMAL_NEG,0,1); SETDEC(out,0,DECIMAL_NEG,0,0); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(l,0,DECIMAL_NEG,0,1); SETDEC(out,0,DECIMAL_NEG,-1,-1); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(l,0,0,0,0); SETDEC(out,0,0,0,1); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(l,0,0,0,0); SETDEC(out,0,0,0,0); MATH1(VarDecCmp); EXPECT_EQ; - SETDEC(l,0,0,0,0); SETDEC(out,0,0,-1,-1); MATH1(VarDecCmp); EXPECT_LT; - - SETDEC(l,0,0,0,0); SETDEC(out,0,DECIMAL_NEG,0,1); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(l,0,0,0,0); SETDEC(out,0,DECIMAL_NEG,0,0); MATH1(VarDecCmp); EXPECT_EQ; - SETDEC(l,0,0,0,0); SETDEC(out,0,DECIMAL_NEG,-1,-1); MATH1(VarDecCmp); EXPECT_GT; - - SETDEC(l,0,DECIMAL_NEG,0,0); SETDEC(out,0,0,0,1); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(l,0,DECIMAL_NEG,0,0); SETDEC(out,0,0,0,0); MATH1(VarDecCmp); EXPECT_EQ; - SETDEC(l,0,DECIMAL_NEG,0,0); SETDEC(out,0,0,-1,-1); MATH1(VarDecCmp); EXPECT_LT; - - SETDEC(l,0,DECIMAL_NEG,0,0); SETDEC(out,0,DECIMAL_NEG,0,1); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(l,0,DECIMAL_NEG,0,0); SETDEC(out,0,DECIMAL_NEG,0,0); MATH1(VarDecCmp); EXPECT_EQ; - SETDEC(l,0,DECIMAL_NEG,0,0); SETDEC(out,0,DECIMAL_NEG,-1,-1); MATH1(VarDecCmp); EXPECT_GT; - - SETDEC(l,0,0,-1,-1); SETDEC(out,0,0,0,1); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(l,0,0,-1,-1); SETDEC(out,0,0,0,0); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(l,0,0,-1,-1); SETDEC(out,0,0,-1,-1); MATH1(VarDecCmp); EXPECT_EQ; - - SETDEC(l,0,0,-1,-1); SETDEC(out,0,DECIMAL_NEG,0,1); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(l,0,0,-1,-1); SETDEC(out,0,DECIMAL_NEG,0,0); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(l,0,0,-1,-1); SETDEC(out,0,DECIMAL_NEG,-1,-1); MATH1(VarDecCmp); EXPECT_GT; - - SETDEC(l,0,DECIMAL_NEG,-1,-1); SETDEC(out,0,0,0,1); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(l,0,DECIMAL_NEG,-1,-1); SETDEC(out,0,0,0,0); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(l,0,DECIMAL_NEG,-1,-1); SETDEC(out,0,0,-1,-1); MATH1(VarDecCmp); EXPECT_LT; - - SETDEC(l,0,DECIMAL_NEG,-1,-1); SETDEC(out,0,DECIMAL_NEG,0,1); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(l,0,DECIMAL_NEG,-1,-1); SETDEC(out,0,DECIMAL_NEG,0,0); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(l,0,DECIMAL_NEG,-1,-1); SETDEC(out,0,DECIMAL_NEG,-1,-1); MATH1(VarDecCmp); EXPECT_EQ; - - - SETDEC(out,0,0,0,1); SETDEC(l,0,0,0,1); MATH1(VarDecCmp); EXPECT_EQ; - SETDEC(out,0,0,0,1); SETDEC(l,0,0,0,0); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(out,0,0,0,1); SETDEC(l,0,0,-1,-1); MATH1(VarDecCmp); EXPECT_GT; - - SETDEC(out,0,0,0,1); SETDEC(l,0,DECIMAL_NEG,0,1); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(out,0,0,0,1); SETDEC(l,0,DECIMAL_NEG,0,0); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(out,0,0,0,1); SETDEC(l,0,DECIMAL_NEG,-1,-1); MATH1(VarDecCmp); EXPECT_LT; - - SETDEC(out,0,DECIMAL_NEG,0,1); SETDEC(l,0,0,0,1); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(out,0,DECIMAL_NEG,0,1); SETDEC(l,0,0,0,0); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(out,0,DECIMAL_NEG,0,1); SETDEC(l,0,0,-1,-1); MATH1(VarDecCmp); EXPECT_GT; - - SETDEC(out,0,DECIMAL_NEG,0,1); SETDEC(l,0,DECIMAL_NEG,0,1); MATH1(VarDecCmp); EXPECT_EQ; - SETDEC(out,0,DECIMAL_NEG,0,1); SETDEC(l,0,DECIMAL_NEG,0,0); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(out,0,DECIMAL_NEG,0,1); SETDEC(l,0,DECIMAL_NEG,-1,-1); MATH1(VarDecCmp); EXPECT_LT; - - SETDEC(out,0,0,0,0); SETDEC(l,0,0,0,1); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(out,0,0,0,0); SETDEC(l,0,0,0,0); MATH1(VarDecCmp); EXPECT_EQ; - SETDEC(out,0,0,0,0); SETDEC(l,0,0,-1,-1); MATH1(VarDecCmp); EXPECT_GT; - - SETDEC(out,0,0,0,0); SETDEC(l,0,DECIMAL_NEG,0,1); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(out,0,0,0,0); SETDEC(l,0,DECIMAL_NEG,0,0); MATH1(VarDecCmp); EXPECT_EQ; - SETDEC(out,0,0,0,0); SETDEC(l,0,DECIMAL_NEG,-1,-1); MATH1(VarDecCmp); EXPECT_LT; - - SETDEC(out,0,DECIMAL_NEG,0,0); SETDEC(l,0,0,0,1); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(out,0,DECIMAL_NEG,0,0); SETDEC(l,0,0,0,0); MATH1(VarDecCmp); EXPECT_EQ; - SETDEC(out,0,DECIMAL_NEG,0,0); SETDEC(l,0,0,-1,-1); MATH1(VarDecCmp); EXPECT_GT; - - SETDEC(out,0,DECIMAL_NEG,0,0); SETDEC(l,0,DECIMAL_NEG,0,1); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(out,0,DECIMAL_NEG,0,0); SETDEC(l,0,DECIMAL_NEG,0,0); MATH1(VarDecCmp); EXPECT_EQ; - SETDEC(out,0,DECIMAL_NEG,0,0); SETDEC(l,0,DECIMAL_NEG,-1,-1); MATH1(VarDecCmp); EXPECT_LT; - - SETDEC(out,0,0,-1,-1); SETDEC(l,0,0,0,1); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(out,0,0,-1,-1); SETDEC(l,0,0,0,0); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(out,0,0,-1,-1); SETDEC(l,0,0,-1,-1); MATH1(VarDecCmp); EXPECT_EQ; - - SETDEC(out,0,0,-1,-1); SETDEC(l,0,DECIMAL_NEG,0,1); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(out,0,0,-1,-1); SETDEC(l,0,DECIMAL_NEG,0,0); MATH1(VarDecCmp); EXPECT_LT; - SETDEC(out,0,0,-1,-1); SETDEC(l,0,DECIMAL_NEG,-1,-1); MATH1(VarDecCmp); EXPECT_LT; - - SETDEC(out,0,DECIMAL_NEG,-1,-1); SETDEC(l,0,0,0,1); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(out,0,DECIMAL_NEG,-1,-1); SETDEC(l,0,0,0,0); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(out,0,DECIMAL_NEG,-1,-1); SETDEC(l,0,0,-1,-1); MATH1(VarDecCmp); EXPECT_GT; - - SETDEC(out,0,DECIMAL_NEG,-1,-1); SETDEC(l,0,DECIMAL_NEG,0,1); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(out,0,DECIMAL_NEG,-1,-1); SETDEC(l,0,DECIMAL_NEG,0,0); MATH1(VarDecCmp); EXPECT_GT; - SETDEC(out,0,DECIMAL_NEG,-1,-1); SETDEC(l,0,DECIMAL_NEG,-1,-1); MATH1(VarDecCmp); EXPECT_EQ; - } /* diff --git a/dlls/oleaut32/typelib.c b/dlls/oleaut32/typelib.c index 1f104f80f16..10f5e238af2 100644 --- a/dlls/oleaut32/typelib.c +++ b/dlls/oleaut32/typelib.c @@ -938,7 +938,7 @@ typedef struct tagITypeLibImpl BSTR DocString; BSTR HelpFile; BSTR HelpStringDll; - DWORD dwHelpContext; + unsigned long dwHelpContext; int TypeInfoCount; /* nr of typeinfo's in librarry */ struct tagITypeInfoImpl *pTypeInfo; /* linked list of type info data */ int ctCustData; /* number of items in cust data list */ @@ -1058,8 +1058,8 @@ typedef struct tagITypeInfoImpl BSTR Name; BSTR DocString; BSTR DllName; - DWORD dwHelpContext; - DWORD dwHelpStringContext; + unsigned long dwHelpContext; + unsigned long dwHelpStringContext; /* functions */ TLBFuncDesc * funclist; /* linked list with function descriptions */ diff --git a/dlls/oleaut32/typelib2.c b/dlls/oleaut32/typelib2.c index 0f641d4103c..b011342e6d2 100644 --- a/dlls/oleaut32/typelib2.c +++ b/dlls/oleaut32/typelib2.c @@ -760,7 +760,7 @@ static int ctl2_alloc_custdata( if (offset == -1) return offset; *((unsigned short *)&This->typelib_segment_data[MSFT_SEG_CUSTDATA][offset]) = VT_UI4; - *((unsigned int *)&This->typelib_segment_data[MSFT_SEG_CUSTDATA][offset+2]) = V_UI4(pVarVal); + *((unsigned long *)&This->typelib_segment_data[MSFT_SEG_CUSTDATA][offset+2]) = V_UI4(pVarVal); break; default: diff --git a/dlls/oleaut32/usrmarshal.c b/dlls/oleaut32/usrmarshal.c index 3172ebad5fc..1e20c3cd322 100644 --- a/dlls/oleaut32/usrmarshal.c +++ b/dlls/oleaut32/usrmarshal.c @@ -232,7 +232,7 @@ static unsigned int get_type_size(ULONG *pFlags, VARTYPE vt) case VT_DECIMAL: return sizeof(DECIMAL); case VT_BSTR: - return sizeof(ULONG); + return sizeof(BSTR); case VT_VARIANT: return sizeof(VARIANT); case VT_UNKNOWN: @@ -764,7 +764,7 @@ ULONG WINAPI LPSAFEARRAY_UserSize(ULONG *pFlags, ULONG StartingSize, LPSAFEARRAY HRESULT hr; size += sizeof(ULONG); - size += 2 * sizeof(USHORT) + 2 * sizeof(ULONG); + size += FIELD_OFFSET(struct _wireSAFEARRAY, uArrayStructs); sftype = SAFEARRAY_GetUnionType(psa); size += sizeof(ULONG); @@ -850,23 +850,23 @@ unsigned char * WINAPI LPSAFEARRAY_UserMarshal(ULONG *pFlags, unsigned char *Buf VARTYPE vt; SAFEARRAY *psa = *ppsa; ULONG ulCellCount = SAFEARRAY_GetCellCount(psa); + wireSAFEARRAY wiresa; SF_TYPE sftype; GUID guid; *(ULONG *)Buffer = psa->cDims; Buffer += sizeof(ULONG); - *(USHORT *)Buffer = psa->cDims; - Buffer += sizeof(USHORT); - *(USHORT *)Buffer = psa->fFeatures; - Buffer += sizeof(USHORT); - *(ULONG *)Buffer = psa->cbElements; - Buffer += sizeof(ULONG); + wiresa = (wireSAFEARRAY)Buffer; + wiresa->cDims = psa->cDims; + wiresa->fFeatures = psa->fFeatures; + wiresa->cbElements = psa->cbElements; hr = SafeArrayGetVartype(psa, &vt); if (FAILED(hr)) vt = 0; - *(ULONG *)Buffer = (USHORT)psa->cLocks | (vt << 16); - Buffer += sizeof(ULONG); + wiresa->cLocks = (USHORT)psa->cLocks | (vt << 16); + + Buffer += FIELD_OFFSET(struct _wireSAFEARRAY, uArrayStructs); sftype = SAFEARRAY_GetUnionType(psa); *(ULONG *)Buffer = sftype; @@ -987,7 +987,7 @@ unsigned char * WINAPI LPSAFEARRAY_UserUnmarshal(ULONG *pFlags, unsigned char *B Buffer += sizeof(ULONG); wiresa = (wireSAFEARRAY)Buffer; - Buffer += 2 * sizeof(USHORT) + 2 * sizeof(ULONG); + Buffer += FIELD_OFFSET(struct _wireSAFEARRAY, uArrayStructs); if (cDims != wiresa->cDims) RpcRaiseException(RPC_S_INVALID_BOUND); diff --git a/dlls/oleaut32/variant.c b/dlls/oleaut32/variant.c index e92a63dcdd7..37965f8ed53 100644 --- a/dlls/oleaut32/variant.c +++ b/dlls/oleaut32/variant.c @@ -588,7 +588,7 @@ void WINAPI VariantInit(VARIANTARG* pVarg) * * RETURNS * Success: S_OK. Any previous value in pVarg is freed and its type is set to VT_EMPTY. - * Failure: DISP_E_BADVARTYPE, if the variant is not a valid variant type. + * Failure: DISP_E_BADVARTYPE, if the variant is a not a valid variant type. */ HRESULT WINAPI VariantClear(VARIANTARG* pVarg) { @@ -5571,9 +5571,7 @@ HRESULT WINAPI VarMod(LPVARIANT left, LPVARIANT right, LPVARIANT result) V_VT(result) = VT_I8; V_I8(result) = V_I8(&lv) % V_I8(&rv); - TRACE("V_I8(left) == %s, V_I8(right) == %s, V_I8(result) == %s\n", - wine_dbgstr_longlong(V_I8(&lv)), wine_dbgstr_longlong(V_I8(&rv)), - wine_dbgstr_longlong(V_I8(result))); + TRACE("V_I8(left) == %ld, V_I8(right) == %ld, V_I8(result) == %ld\n", (long)V_I8(&lv), (long)V_I8(&rv), (long)V_I8(result)); /* convert left and right to the destination type */ rc = VariantChangeType(result, result, 0, resT); diff --git a/dlls/oleaut32/vartype.c b/dlls/oleaut32/vartype.c index 7f5325936b0..2d5ae7d8ea4 100644 --- a/dlls/oleaut32/vartype.c +++ b/dlls/oleaut32/vartype.c @@ -5788,16 +5788,6 @@ HRESULT WINAPI VarDecCmp(const DECIMAL* pDecLeft, const DECIMAL* pDecRight) HRESULT hRet; DECIMAL result; - if (!pDecLeft || !pDecRight) - return VARCMP_NULL; - - if ((!(DEC_SIGN(pDecLeft) & DECIMAL_NEG)) && (DEC_SIGN(pDecRight) & DECIMAL_NEG) && - (DEC_HI32(pDecLeft) | DEC_MID32(pDecLeft) | DEC_LO32(pDecLeft))) - return VARCMP_GT; - else if ((DEC_SIGN(pDecLeft) & DECIMAL_NEG) && (!(DEC_SIGN(pDecRight) & DECIMAL_NEG)) && - (DEC_HI32(pDecLeft) | DEC_MID32(pDecLeft) | DEC_LO32(pDecLeft))) - return VARCMP_LT; - /* Subtract right from left, and compare the result to 0 */ hRet = VarDecSub(pDecLeft, pDecRight, &result); diff --git a/dlls/olecli.dll16/Makefile.in b/dlls/olecli.dll16/Makefile.in index 5ae4182e493..20d75948770 100644 --- a/dlls/olecli.dll16/Makefile.in +++ b/dlls/olecli.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = olecli.dll16 IMPORTS = gdi32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,olecli32.dll +SPEC_SRCS = olecli.dll16.spec + C_SRCS = olecli.c @MAKE_DLL_RULES@ diff --git a/dlls/oledlg/Makefile.in b/dlls/oledlg/Makefile.in index e60e150bce9..73f079b1a9d 100644 --- a/dlls/oledlg/Makefile.in +++ b/dlls/oledlg/Makefile.in @@ -11,27 +11,7 @@ C_SRCS = \ oledlg_main.c \ pastespl.c -RC_SRCS = \ - oledlg_Cs.rc \ - oledlg_Da.rc \ - oledlg_De.rc \ - oledlg_En.rc \ - oledlg_Es.rc \ - oledlg_Fr.rc \ - oledlg_Hu.rc \ - oledlg_It.rc \ - oledlg_Ja.rc \ - oledlg_Ko.rc \ - oledlg_Lt.rc \ - oledlg_Nl.rc \ - oledlg_No.rc \ - oledlg_Pl.rc \ - oledlg_Pt.rc \ - oledlg_Ru.rc \ - oledlg_Si.rc \ - oledlg_Sv.rc \ - oledlg_Tr.rc \ - oledlg_Zh.rc +RC_SRCS = rsrc.rc @MAKE_DLL_RULES@ diff --git a/dlls/oledlg/oledlg_Cs.rc b/dlls/oledlg/oledlg_Cs.rc index 1cf038537de..4271a762129 100644 --- a/dlls/oledlg/oledlg_Cs.rc +++ b/dlls/oledlg/oledlg_Cs.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/dlls/oledlg/oledlg_Da.rc b/dlls/oledlg/oledlg_Da.rc index 852733ab6d1..d1ef0696cdc 100644 --- a/dlls/oledlg/oledlg_Da.rc +++ b/dlls/oledlg/oledlg_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 diff --git a/dlls/oledlg/oledlg_De.rc b/dlls/oledlg/oledlg_De.rc index 71dff20c10c..b2ae5faf43a 100644 --- a/dlls/oledlg/oledlg_De.rc +++ b/dlls/oledlg/oledlg_De.rc @@ -16,15 +16,11 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Objekt einfügen" +CAPTION "Objekt einfügen" FONT 8, "MS Shell Dlg" BEGIN LISTBOX IDC_OBJTYPELIST,82,19,131,66,LBS_SORT | @@ -41,7 +37,7 @@ BEGIN CONTROL "A&us Datei erstellen",IDC_CREATEFROMFILE,"Button", BS_AUTORADIOBUTTON,7,37,67,10 LTEXT "",IDC_RESULTDESC,49,112,159,23 - PUSHBUTTON "Steuerung hin&zufügen",IDC_ADDCONTROL,81,88,63,14,NOT WS_VISIBLE + PUSHBUTTON "Steuerung hin&zufügen",IDC_ADDCONTROL,81,88,63,14,NOT WS_VISIBLE CONTROL "Als &Symbol anzeigen",IDC_ASICON,"Button",BS_AUTOCHECKBOX | WS_TABSTOP | NOT WS_VISIBLE,223,58,64,10 PUSHBUTTON "D&urchsuchen...",IDC_BROWSE,83,53,50,14,NOT WS_VISIBLE @@ -51,22 +47,22 @@ END STRINGTABLE DISCARDABLE { - IDS_RESULTOBJDESC "Fügt ein neues %s - Objekt in Ihr Dokument ein." - IDS_RESULTFILEOBJDESC "Fügt den Inhalt der Datei als Objekt so in Ihr Dokument ein, dass Sie es mit dem Programm aktivieren können, mit dem es erstellt wurde." + IDS_RESULTOBJDESC "Fügt ein neues %s - Objekt in Ihr Dokument ein." + IDS_RESULTFILEOBJDESC "Fügt den Inhalt der Datei als Objekt so in Ihr Dokument ein, dass Sie es mit dem Programm aktivieren können, mit dem es erstellt wurde." IDS_BROWSE "Durchsuchen" - IDS_NOTOLEMOD "Die Datei ist offenbar kein gültiges OLE - Steuermodul. Die OLE - Steuerung konnte nicht registiert werden." - IDS_NOTOLEMODCAPTION "Steuerung hinzufügen" + IDS_NOTOLEMOD "Die Datei ist offenbar kein gültiges OLE - Steuermodul. Die OLE - Steuerung konnte nicht registiert werden." + IDS_NOTOLEMODCAPTION "Steuerung hinzufügen" } IDD_PASTESPECIAL4 DIALOG DISCARDABLE 3, 15, 293, 140 STYLE DS_MODALFRAME | DS_SETFONT | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Inhalte einfügen" +CAPTION "Inhalte einfügen" FONT 8, "MS Shell Dlg" BEGIN LTEXT "Quelle:", -1, 6, 9, 30, 8, WS_VISIBLE | WS_GROUP - CONTROL "&Einfügen", IDC_PS_PASTE, "Button", BS_AUTORADIOBUTTON | WS_TABSTOP | WS_GROUP | WS_VISIBLE, + CONTROL "&Einfügen", IDC_PS_PASTE, "Button", BS_AUTORADIOBUTTON | WS_TABSTOP | WS_GROUP | WS_VISIBLE, 6, 38, 55, 10 - CONTROL "&Verknüpfung einfügen", IDC_PS_PASTELINK, "Button", BS_AUTORADIOBUTTON | WS_VISIBLE, + CONTROL "&Verknüpfung einfügen", IDC_PS_PASTELINK, "Button", BS_AUTORADIOBUTTON | WS_VISIBLE, 6, 63, 55, 10 LTEXT "&Als:", -1, 65, 25, 16, 8, WS_VISIBLE | WS_GROUP LISTBOX IDC_PS_PASTELIST, 65, 36, 153, 57, LBS_NOTIFY | LBS_USETABSTOPS | WS_VSCROLL | WS_BORDER | NOT WS_VISIBLE @@ -77,7 +73,7 @@ BEGIN CONTROL "&Hilfe", IDC_OLEUIHELP, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 224, 42, 66, 14 CONTROL "Als Symbol &darstellen", IDC_PS_DISPLAYASICON, "Button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_VISIBLE, 224, 59, 66, 14 CONTROL "", IDC_PS_ICONDISPLAY, "Static", SS_ICON | WS_VISIBLE, 224, 75, 66, 44 - CONTROL "&Symbol ändern...", IDC_PS_CHANGEICON, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 224, 123, 66, 14 + CONTROL "&Symbol ändern...", IDC_PS_CHANGEICON, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 224, 123, 66, 14 CONTROL "", IDC_PS_RESULTIMAGE, "Static", SS_ICON | WS_VISIBLE, 8, 101, 42, 34 CONTROL "<< result text goes here >>", IDC_PS_RESULTTEXT, "Static", SS_NOPREFIX | WS_VISIBLE, 54, 100, 159, 35 CONTROL "Ergebnis", -1, "Button", BS_GROUPBOX | WS_GROUP | WS_VISIBLE, 6, 90, 212, 48 @@ -86,13 +82,13 @@ END STRINGTABLE DISCARDABLE { - IDS_PS_PASTE_DATA "Fügt den Inhalt der Zwischenablage in Ihr Dokument als %s ein." - IDS_PS_PASTE_OBJECT "Fügt den Inhalt der Zwischenablage so in Ihr Dokument ein dass Sie es mit %s aktivieren können." - IDS_PS_PASTE_OBJECT_AS_ICON "Fügt den Inhalt der Zwischenablage so in Ihr Dokument ein dass Sie es mit %s aktivieren können. Wird als Symbol dargestellt." - IDS_PS_PASTE_LINK_DATA "Fügt den Inhalt der Zwischenablage in Ihr Dokument als %s ein. Die Daten sind mit der Ursprungsdatei verknüpft so dass Änderungen an dieser in Ihrem Dokument erscheinen." - IDS_PS_PASTE_LINK_OBJECT "Fügt ein Bild des Zwischenablagen-Inhalts in Ihr Dokument ein. Das Bild ist mit der Ursprungsdatei verknüpft so dass Änderungen an dieser in Ihrem Dokument erscheinen." - IDS_PS_PASTE_LINK_OBJECT_AS_ICON "Fügt eine Verknüpfung ein die auf den Ort des Zwischenablagen-Inhalts zeigt. Die Verknüpfung ist mit der Ursprungsdatei verknüpft so dass Änderungen an dieser in Ihrem Dokument erscheinen." - IDS_PS_NON_OLE "Fügt den Inhalt der Zwischenablage in Ihr Dokument als ein." + IDS_PS_PASTE_DATA "Fügt den Inhalt der Zwischenablage in Ihr Dokument als %s ein." + IDS_PS_PASTE_OBJECT "Fügt den Inhalt der Zwischenablage so in Ihr Dokument ein dass Sie es mit %s aktivieren können." + IDS_PS_PASTE_OBJECT_AS_ICON "Fügt den Inhalt der Zwischenablage so in Ihr Dokument ein dass Sie es mit %s aktivieren können. Wird als Symbol dargestellt." + IDS_PS_PASTE_LINK_DATA "Fügt den Inhalt der Zwischenablage in Ihr Dokument als %s ein. Die Daten sind mit der Ursprungsdatei verknüpft so dass Änderungen an dieser in Ihrem Dokument erscheinen." + IDS_PS_PASTE_LINK_OBJECT "Fügt ein Bild des Zwischenablagen-Inhalts in Ihr Dokument ein. Das Bild ist mit der Ursprungsdatei verknüpft so dass Änderungen an dieser in Ihrem Dokument erscheinen." + IDS_PS_PASTE_LINK_OBJECT_AS_ICON "Fügt eine Verknüpfung ein die auf den Ort des Zwischenablagen-Inhalts zeigt. Die Verknüpfung ist mit der Ursprungsdatei verknüpft so dass Änderungen an dieser in Ihrem Dokument erscheinen." + IDS_PS_NON_OLE "Fügt den Inhalt der Zwischenablage in Ihr Dokument als ein." IDS_PS_UNKNOWN_TYPE "Unbekannter Typ" IDS_PS_UNKNOWN_SRC "Unbekannte Quelle" IDS_PS_UNKNOWN_APP "dem Erzeugerprogramm" diff --git a/dlls/oledlg/oledlg_En.rc b/dlls/oledlg/oledlg_En.rc index 5dd5be40b3b..5b89a252c52 100644 --- a/dlls/oledlg/oledlg_En.rc +++ b/dlls/oledlg/oledlg_En.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 diff --git a/dlls/oledlg/oledlg_Es.rc b/dlls/oledlg/oledlg_Es.rc index 74f8c0867f8..44d8d926e7f 100644 --- a/dlls/oledlg/oledlg_Es.rc +++ b/dlls/oledlg/oledlg_Es.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 diff --git a/dlls/oledlg/oledlg_Fr.rc b/dlls/oledlg/oledlg_Fr.rc index 176cc87f70f..41654cb75f4 100644 --- a/dlls/oledlg/oledlg_Fr.rc +++ b/dlls/oledlg/oledlg_Fr.rc @@ -3,7 +3,6 @@ * French language support * * Copyright (C) 2005-2006 Jonathan Ernst - * Copyright (C) 2009 Frédéric Delanoy * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -20,52 +19,48 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL -UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 308, 151 +UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Insérer objet" +CAPTION "Insérer Objet" FONT 8, "MS Shell Dlg" BEGIN - LISTBOX IDC_OBJTYPELIST,94,19,131,66,LBS_SORT | + LISTBOX IDC_OBJTYPELIST,82,19,131,66,LBS_SORT | LBS_NOINTEGRALHEIGHT | WS_VISIBLE | WS_VSCROLL | WS_TABSTOP - LTEXT "Type d'objet :",IDC_OBJTYPELBL,94,7,53,8,WS_VISIBLE - DEFPUSHBUTTON "OK",IDOK,233,7,65,14 - PUSHBUTTON "Annuler",IDCANCEL,233,24,65,14 - GROUPBOX "Résultat",IDC_RESULT,7,103,218,41 - CONTROL "Créer nouveau",IDC_CREATENEW,"Button",BS_AUTORADIOBUTTON | + LTEXT "Type d'objet :",IDC_OBJTYPELBL,82,7,53,8,WS_VISIBLE + DEFPUSHBUTTON "OK",IDOK,221,7,66,14 + PUSHBUTTON "Annuler",IDCANCEL,221,24,66,14 + GROUPBOX "Résultat",IDC_RESULT,7,103,208,41 + CONTROL "Créer nouveau",IDC_CREATENEW,"Button",BS_AUTORADIOBUTTON | WS_GROUP,7,20,62,10 - CONTROL "Créer un contrôle",IDC_CREATECONTROL,"Button", - BS_AUTORADIOBUTTON | NOT WS_VISIBLE,7,54,72,10 - CONTROL "Créer depuis le fichier",IDC_CREATEFROMFILE,"Button", - BS_AUTORADIOBUTTON,7,37,82,10 - LTEXT "",IDC_RESULTDESC,47,112,173,25 - PUSHBUTTON "&Ajouter un contrôle...",IDC_ADDCONTROL,94,88,80,14,NOT WS_VISIBLE - CONTROL "Afficher comme une icône",IDC_ASICON,"Button",BS_AUTOCHECKBOX | - BS_MULTILINE | WS_TABSTOP | NOT WS_VISIBLE,234,51,61,35 - PUSHBUTTON "Parcourir...",IDC_BROWSE,96,53,50,14,NOT WS_VISIBLE - LTEXT "Fichier :",IDC_FILELBL,96,27,27,8, NOT WS_VISIBLE - EDITTEXT IDC_FILE,95,37,129,13,ES_AUTOHSCROLL | NOT WS_VISIBLE + CONTROL "Créer le contrôle",IDC_CREATECONTROL,"Button", + BS_AUTORADIOBUTTON | NOT WS_VISIBLE,7,54,62,10 + CONTROL "Créer depuis le fichier",IDC_CREATEFROMFILE,"Button", + BS_AUTORADIOBUTTON,7,37,67,10 + LTEXT "",IDC_RESULTDESC,49,112,159,23 + PUSHBUTTON "&Ajoute Contrôle...",IDC_ADDCONTROL,81,88,63,14,NOT WS_VISIBLE + CONTROL "Afficher comme icône",IDC_ASICON,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP | NOT WS_VISIBLE,223,58,64,10 + PUSHBUTTON "Parcourir...",IDC_BROWSE,83,53,50,14,NOT WS_VISIBLE + LTEXT "Fichier :",IDC_FILELBL,83,27,20,8, NOT WS_VISIBLE + EDITTEXT IDC_FILE,83,37,132,13,ES_AUTOHSCROLL | NOT WS_VISIBLE END STRINGTABLE DISCARDABLE { - IDS_RESULTOBJDESC "Insérer un nouvel object %s dans votre document" - IDS_RESULTFILEOBJDESC "Insère le contenu du fichier comme un objet dans votre document afin que vous puissiez l'activer en utilisant le programme avec lequel il a été créé." + IDS_RESULTOBJDESC "Insérer un nouvel object %s dans votre document" + IDS_RESULTFILEOBJDESC "Insère le contenu du fichier comme un objet dans votre document afin que vous puissiez l'activer en utilisant le programme avec lequel il a été créé." IDS_BROWSE "Parcourir" - IDS_NOTOLEMOD "Le fichier ne semble pas être un module OLE valide. Impossible d'enregistrer le contrôle OLE." - IDS_NOTOLEMODCAPTION "Ajouter un contrôle" + IDS_NOTOLEMOD "Le fichier ne semble pas être un module OLE valide. Impossible d'enregistrer le contrôle OLE." + IDS_NOTOLEMODCAPTION "Ajouter un contrôle" } -IDD_PASTESPECIAL4 DIALOG DISCARDABLE 3, 15, 308, 140 +IDD_PASTESPECIAL4 DIALOG DISCARDABLE 3, 15, 293, 140 STYLE DS_MODALFRAME | DS_SETFONT | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Collage spécial" +CAPTION "Collage spécial" FONT 8, "MS Shell Dlg" BEGIN LTEXT "Source :", -1, 6, 9, 30, 8, WS_VISIBLE | WS_GROUP @@ -73,32 +68,32 @@ BEGIN 6, 38, 55, 10 CONTROL "Coller le &lien", IDC_PS_PASTELINK, "Button", BS_AUTORADIOBUTTON | WS_VISIBLE, 6, 63, 55, 10 - LTEXT "&Comme :", -1, 65, 25, 31, 8, WS_VISIBLE | WS_GROUP + LTEXT "&Comme :", -1, 65, 25, 16, 8, WS_VISIBLE | WS_GROUP LISTBOX IDC_PS_PASTELIST, 65, 36, 153, 57, LBS_NOTIFY | LBS_USETABSTOPS | WS_VSCROLL | WS_BORDER | NOT WS_VISIBLE LISTBOX IDC_PS_PASTELINKLIST, 65, 36, 153, 57, LBS_NOTIFY | LBS_USETABSTOPS | WS_VSCROLL | WS_BORDER | NOT WS_VISIBLE LISTBOX IDC_PS_DISPLAYLIST, 65, 36, 153, 57, LBS_NOTIFY | LBS_USETABSTOPS | WS_VSCROLL | WS_BORDER | WS_VISIBLE - CONTROL "OK", IDOK, "Button", BS_DEFPUSHBUTTON | WS_TABSTOP | WS_GROUP | WS_VISIBLE, 228, 6, 66, 14 - CONTROL "Annuler", IDCANCEL, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 228, 23, 66, 14 - CONTROL "Aid&e", IDC_OLEUIHELP, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 228, 42, 66, 14 - CONTROL "&Afficher comme une icône", IDC_PS_DISPLAYASICON, "Button", BS_AUTOCHECKBOX | BS_MULTILINE | WS_TABSTOP | WS_VISIBLE, 228, 63, 66, 14 - CONTROL "", IDC_PS_ICONDISPLAY, "Static", SS_ICON | WS_VISIBLE, 224, 84, 21, 20 - CONTROL "Changer l'&icône...", IDC_PS_CHANGEICON, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 224, 123, 66, 14 - CONTROL "", IDC_PS_RESULTIMAGE, "Static", SS_ICON | WS_VISIBLE, 12, 103, 21, 20 - CONTROL "<< le résultat vient ici >>", IDC_PS_RESULTTEXT, "Static", SS_NOPREFIX | WS_VISIBLE, 53, 99, 161, 35 - CONTROL "Résultat", -1, "Button", BS_GROUPBOX | WS_GROUP | WS_VISIBLE, 6, 90, 212, 48 + CONTROL "OK", IDOK, "Button", BS_DEFPUSHBUTTON | WS_TABSTOP | WS_GROUP | WS_VISIBLE, 224, 6, 66, 14 + CONTROL "Annuler", IDCANCEL, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 224, 23, 66, 14 + CONTROL "Aid&e", IDC_OLEUIHELP, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 224, 42, 66, 14 + CONTROL "&Afficher comme icône", IDC_PS_DISPLAYASICON, "Button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_VISIBLE, 224, 59, 66, 14 + CONTROL "", IDC_PS_ICONDISPLAY, "Static", SS_ICON | WS_VISIBLE, 224, 75, 66, 44 + CONTROL "Changer l'&icône...", IDC_PS_CHANGEICON, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 224, 123, 66, 14 + CONTROL "", IDC_PS_RESULTIMAGE, "Static", SS_ICON | WS_VISIBLE, 8, 101, 42, 34 + CONTROL "<< le résultat vient ici >>", IDC_PS_RESULTTEXT, "Static", SS_NOPREFIX | WS_VISIBLE, 54, 100, 159, 35 + CONTROL "Résultat", -1, "Button", BS_GROUPBOX | WS_GROUP | WS_VISIBLE, 6, 90, 212, 48 CONTROL "", IDC_PS_SOURCETEXT, "Edit", ES_READONLY | ES_AUTOHSCROLL | WS_VISIBLE, 37, 9, 180, 8 END STRINGTABLE DISCARDABLE { - IDS_PS_PASTE_DATA "Insère le contenu du presse-papiers dans votre document comme %s." - IDS_PS_PASTE_OBJECT "Insère le contenu du presse-papiers dans votre document de sorte que vous puissiez l'activer en utilisant %s." - IDS_PS_PASTE_OBJECT_AS_ICON "Insère le contenu du presse-papiers dans votre document de sorte que vous puissiez l'activer en utilisant %s. Il sera affiché comme une icône." - IDS_PS_PASTE_LINK_DATA "Insère le contenu du presse-papiers dans votre document comme %s. Les données sont liées au fichier source de sorte que les modifications de celles-ci seront répercutées dans votre document." - IDS_PS_PASTE_LINK_OBJECT "Insère une image du contenu du presse-papiers dans votre document. L'image est liée au fichier source de sorte que les modifications de celui-ci seront répercutées dans votre document." - IDS_PS_PASTE_LINK_OBJECT_AS_ICON "Insère un raccourci qui pointe vers l'emplacement du contenu du presse-papiers. Le raccourci est lié au fichier source de sorte que les modifications de celui-ci seront répercutées dans votre document." - IDS_PS_NON_OLE "Insère le contenu du presse-papiers dans votre document." + IDS_PS_PASTE_DATA "Insère le contenu du presse-papiers dans votre document comme %s." + IDS_PS_PASTE_OBJECT "Insère le contenu du presse-papiers dans votre document de sorte que vous puissiez l'activer en utilisant %s." + IDS_PS_PASTE_OBJECT_AS_ICON "Insère le contenu du presse-papiers dans votre document de sorte que vous puissiez l'activer en utilisant %s. Il sera affiché comme une icône." + IDS_PS_PASTE_LINK_DATA "Insère le contenu du presse-papiers dans votre document comme %s. Les données sont liées au fichier source de sorte que les modifications de celles-ci seront répercutées dans votre document." + IDS_PS_PASTE_LINK_OBJECT "Insère le contenu du presse-papiers dans votre document. L'image est liée au fichier source de sorte que les modifications de celle-ci seront répercutées dans votre document." + IDS_PS_PASTE_LINK_OBJECT_AS_ICON "Insère un raccourci qui pointe vers l'emplacement du contenu du presse-papiers. Le raccourci est lié au fichier source de sorte que les modifications de celui-ci seront répercutées dans votre document." + IDS_PS_NON_OLE "Insère le contenu du presse-papiers dans votre document." IDS_PS_UNKNOWN_TYPE "Type inconnu" IDS_PS_UNKNOWN_SRC "Source inconnue" - IDS_PS_UNKNOWN_APP "le programme avec lequel il a été créé" + IDS_PS_UNKNOWN_APP "le programme avec lequel il a été créé" } diff --git a/dlls/oledlg/oledlg_Hu.rc b/dlls/oledlg/oledlg_Hu.rc index 30bd8e03f96..58cc0882f2a 100644 --- a/dlls/oledlg/oledlg_Hu.rc +++ b/dlls/oledlg/oledlg_Hu.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 diff --git a/dlls/oledlg/oledlg_It.rc b/dlls/oledlg/oledlg_It.rc index 91e43b274c8..2a23abdffcc 100644 --- a/dlls/oledlg/oledlg_It.rc +++ b/dlls/oledlg/oledlg_It.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 diff --git a/dlls/oledlg/oledlg_Ja.rc b/dlls/oledlg/oledlg_Ja.rc index 0029ff35f11..d753022f257 100644 --- a/dlls/oledlg/oledlg_Ja.rc +++ b/dlls/oledlg/oledlg_Ja.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -58,3 +56,5 @@ STRINGTABLE DISCARDABLE IDS_NOTOLEMOD "ファイルは有効なOLEモジュールではないようです。OLEコントロールを登録できません。" IDS_NOTOLEMODCAPTION "コントロールを追加" } + +#pragma code_page(default) diff --git a/dlls/oledlg/oledlg_Ko.rc b/dlls/oledlg/oledlg_Ko.rc index 7e0ae7e5ba4..32a49305afc 100644 --- a/dlls/oledlg/oledlg_Ko.rc +++ b/dlls/oledlg/oledlg_Ko.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 diff --git a/dlls/oledlg/oledlg_Lt.rc b/dlls/oledlg/oledlg_Lt.rc deleted file mode 100644 index 961fd1d996f..00000000000 --- a/dlls/oledlg/oledlg_Lt.rc +++ /dev/null @@ -1,100 +0,0 @@ -/* - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Įterpti objektą" -FONT 8, "MS Shell Dlg" -BEGIN - LISTBOX IDC_OBJTYPELIST,82,19,131,66,LBS_SORT | - LBS_NOINTEGRALHEIGHT | WS_VISIBLE | WS_VSCROLL | - WS_TABSTOP - LTEXT "Objekto tipas:",IDC_OBJTYPELBL,82,7,53,8,WS_VISIBLE - DEFPUSHBUTTON "Gerai",IDOK,221,7,66,14 - PUSHBUTTON "Atsisakyti",IDCANCEL,221,24,66,14 - GROUPBOX "Rezultatas",IDC_RESULT,7,103,208,41 - CONTROL "Sukurti naują",IDC_CREATENEW,"Button",BS_AUTORADIOBUTTON | - WS_GROUP,7,20,62,10 - CONTROL "Sukurti valdiklį",IDC_CREATECONTROL,"Button", - BS_AUTORADIOBUTTON | NOT WS_VISIBLE,7,54,62,10 - CONTROL "Sukurti iš failo",IDC_CREATEFROMFILE,"Button", - BS_AUTORADIOBUTTON,7,37,67,10 - LTEXT "",IDC_RESULTDESC,49,112,159,23 - PUSHBUTTON "&Pridėti valdiklį...",IDC_ADDCONTROL,81,88,63,14,NOT WS_VISIBLE - CONTROL "Rodyti kaip piktogramą",IDC_ASICON,"Button",BS_AUTOCHECKBOX | - BS_MULTILINE | WS_TABSTOP | NOT WS_VISIBLE,223,58,64,20 - PUSHBUTTON "Parinkti...",IDC_BROWSE,83,53,50,14,NOT WS_VISIBLE - LTEXT "Failas:",IDC_FILELBL,83,27,20,8, NOT WS_VISIBLE - EDITTEXT IDC_FILE,83,37,132,13,ES_AUTOHSCROLL | NOT WS_VISIBLE -END - -STRINGTABLE DISCARDABLE -{ - IDS_RESULTOBJDESC "Įterpia naują objektą „%s“ į jūsų dokumentą" - IDS_RESULTFILEOBJDESC "Įterpia failo turinį kaip objektą į jūsų dokumentą, kad galėtumėte jį aktyvuoti naudodami programą, kuri jį sukūrė." - IDS_BROWSE "Parinkti" - IDS_NOTOLEMOD "Panašu, kad failas nėra galiojantis OLE modulis. Nepavyko užregistruoti OLE valdiklio." - IDS_NOTOLEMODCAPTION "Pridėti valdiklį" -} - -IDD_PASTESPECIAL4 DIALOG DISCARDABLE 3, 15, 293, 140 -STYLE DS_MODALFRAME | DS_SETFONT | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Įdėti kaip" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Šaltinis:", -1, 6, 9, 30, 8, WS_VISIBLE | WS_GROUP - CONTROL "Į&dėti", IDC_PS_PASTE, "Button", BS_AUTORADIOBUTTON | WS_TABSTOP | WS_GROUP | WS_VISIBLE, - 6, 38, 55, 10 - CONTROL "Įdėti &saitą", IDC_PS_PASTELINK, "Button", BS_AUTORADIOBUTTON | WS_VISIBLE, - 6, 63, 55, 10 - LTEXT "&Kaip:", -1, 65, 25, 16, 8, WS_VISIBLE | WS_GROUP - LISTBOX IDC_PS_PASTELIST, 65, 36, 153, 57, LBS_NOTIFY | LBS_USETABSTOPS | WS_VSCROLL | WS_BORDER | NOT WS_VISIBLE - LISTBOX IDC_PS_PASTELINKLIST, 65, 36, 153, 57, LBS_NOTIFY | LBS_USETABSTOPS | WS_VSCROLL | WS_BORDER | NOT WS_VISIBLE - LISTBOX IDC_PS_DISPLAYLIST, 65, 36, 153, 57, LBS_NOTIFY | LBS_USETABSTOPS | WS_VSCROLL | WS_BORDER | WS_VISIBLE - CONTROL "Gerai", IDOK, "Button", BS_DEFPUSHBUTTON | WS_TABSTOP | WS_GROUP | WS_VISIBLE, 224, 6, 66, 14 - CONTROL "Atsisakyti", IDCANCEL, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 224, 23, 66, 14 - CONTROL "&Žinynas", IDC_OLEUIHELP, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 224, 42, 66, 14 - CONTROL "&Rodyti kaip piktogramą", IDC_PS_DISPLAYASICON, "Button", BS_AUTOCHECKBOX | BS_MULTILINE | WS_TABSTOP | WS_VISIBLE, 224, 59, 66, 20 - CONTROL "", IDC_PS_ICONDISPLAY, "Static", SS_ICON | WS_VISIBLE, 224, 81, 66, 44 - CONTROL "Keisti &piktogramą...", IDC_PS_CHANGEICON, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 224, 123, 66, 14 - CONTROL "", IDC_PS_RESULTIMAGE, "Static", SS_ICON | WS_VISIBLE, 8, 101, 42, 34 - CONTROL "<< čia pateikiamas rezultato tekstas >>", IDC_PS_RESULTTEXT, "Static", SS_NOPREFIX | WS_VISIBLE, 54, 100, 159, 35 - CONTROL "Rezultatas", -1, "Button", BS_GROUPBOX | WS_GROUP | WS_VISIBLE, 6, 90, 212, 48 - CONTROL "", IDC_PS_SOURCETEXT, "Edit", ES_READONLY | ES_AUTOHSCROLL | WS_VISIBLE, 37, 9, 180, 8 -END - -STRINGTABLE DISCARDABLE -{ - IDS_PS_PASTE_DATA "Įterpia iškarpinės turinį į jūsų dokumentą kaip %s." - IDS_PS_PASTE_OBJECT "Įterpia iškarpinės turinį į jūsų dokumentą, kad galėtumėte jį aktyvuoti naudodami %s." - IDS_PS_PASTE_OBJECT_AS_ICON "Įterpia iškarpinės turinį į jūsų dokumentą, kad galėtumėte jį aktyvuoti naudodami %s. Jis bus rodomas kaip piktograma." - IDS_PS_PASTE_LINK_DATA "Įterpia iškarpinės turinį į jūsų dokumentą kaip %s. Duomenys yra susieti su šaltinio failu, todėl failo pakeitimai bus atspindėti jūsų dokumente." - IDS_PS_PASTE_LINK_OBJECT "Įterpia iškarpinės turinio paveikslą į jūsų dokumentą. Paveikslas yra susietas su šaltinio failu, todėl failo pakeitimai bus atspindėti jūsų dokumente." - IDS_PS_PASTE_LINK_OBJECT_AS_ICON "Įterpia nuorodą, kuri rodo į iškarpinės turinį. Nuoroda yra susieta su šaltinio failu, todėl failo pakeitimai bus atspindėti jūsų dokumente." - IDS_PS_NON_OLE "Įterpia iškarpinės turinį į jūsų dokumentą." - IDS_PS_UNKNOWN_TYPE "Nežinomas tipas" - IDS_PS_UNKNOWN_SRC "Nežinomas šaltinis" - IDS_PS_UNKNOWN_APP "programa, kuri jį sukūrė" -} diff --git a/dlls/oledlg/oledlg_Nl.rc b/dlls/oledlg/oledlg_Nl.rc index 58a63da7cae..27b0e745db2 100644 --- a/dlls/oledlg/oledlg_Nl.rc +++ b/dlls/oledlg/oledlg_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 diff --git a/dlls/oledlg/oledlg_No.rc b/dlls/oledlg/oledlg_No.rc index 5657d495737..4e0411480ed 100644 --- a/dlls/oledlg/oledlg_No.rc +++ b/dlls/oledlg/oledlg_No.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 diff --git a/dlls/oledlg/oledlg_Pl.rc b/dlls/oledlg/oledlg_Pl.rc index 079a2b9d82b..1777dcb053a 100644 --- a/dlls/oledlg/oledlg_Pl.rc +++ b/dlls/oledlg/oledlg_Pl.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 310, 151 diff --git a/dlls/oledlg/oledlg_Pt.rc b/dlls/oledlg/oledlg_Pt.rc index 9ef209e2d9f..69cd06a4629 100644 --- a/dlls/oledlg/oledlg_Pt.rc +++ b/dlls/oledlg/oledlg_Pt.rc @@ -1,7 +1,6 @@ /* * Copyright 2004 Marcelo Duarte - * Copyright 2006 Américo José Melo - * Copyright 2009 Ricardo Filipe + * Copyright 2006 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 @@ -18,10 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 @@ -44,7 +39,7 @@ BEGIN BS_AUTORADIOBUTTON,7,37,67,10 LTEXT "",IDC_RESULTDESC,49,112,159,23 PUSHBUTTON "&Adicionar Controle...",IDC_ADDCONTROL,81,88,63,14,NOT WS_VISIBLE - CONTROL "Mostrar como ícone",IDC_ASICON,"Button",BS_AUTOCHECKBOX | + CONTROL "Mostrar como ícone",IDC_ASICON,"Button",BS_AUTOCHECKBOX | WS_TABSTOP | NOT WS_VISIBLE,223,58,64,10 PUSHBUTTON "Procurar...",IDC_BROWSE,83,53,50,14,NOT WS_VISIBLE LTEXT "Arquivo:",IDC_FILELBL,83,27,20,8, NOT WS_VISIBLE @@ -73,7 +68,7 @@ BEGIN BS_AUTORADIOBUTTON,7,37,67,10 LTEXT "",IDC_RESULTDESC,49,112,159,23 PUSHBUTTON "&Adicionar Controlo...",IDC_ADDCONTROL,81,88,63,14,NOT WS_VISIBLE - CONTROL "Mostrar como ícone",IDC_ASICON,"Button",BS_AUTOCHECKBOX | + CONTROL "Mostrar como ícone",IDC_ASICON,"Button",BS_AUTOCHECKBOX | WS_TABSTOP | NOT WS_VISIBLE,223,58,64,10 PUSHBUTTON "Procurar...",IDC_BROWSE,83,53,50,14,NOT WS_VISIBLE LTEXT "Ficheiro:",IDC_FILELBL,83,27,20,8, NOT WS_VISIBLE @@ -86,9 +81,9 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE DISCARDABLE { IDS_RESULTOBJDESC "Inserir um novo objeto %s no documento" - IDS_RESULTFILEOBJDESC "Inserir o conteúdo do arquivo como um objeto no documento de modo que possa ativá-lo usando o programa que o criou." + IDS_RESULTFILEOBJDESC "Inserir o conteúdo do arquivo como um objeto no documento de modo que possa ativá-lo usando o programa que o criou." IDS_BROWSE "Procurar" - IDS_NOTOLEMOD "O arquivo não parece ser um módulo OLE válido. Impossível registrar o controle OLE." + IDS_NOTOLEMOD "O arquivo não parece ser um módulo OLE válido. Impossível registrar o controle OLE." IDS_NOTOLEMODCAPTION "Adicionar Controle" } @@ -97,48 +92,8 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE DISCARDABLE { IDS_RESULTOBJDESC "Inserir novo objecto %s no documento" - IDS_RESULTFILEOBJDESC "Inserir conteúdo do ficheiro como um objecto no documento de modo que opossa activar usando o programa que o criou." + IDS_RESULTFILEOBJDESC "Inserir conteúdo do ficheiro como um objecto no documento de modo que opossa activar usando o programa que o criou." IDS_BROWSE "Procurar" - IDS_NOTOLEMOD "O ficheiro não parece ser um módulo OLE válido. Impossível registrar o controlo OLE." + IDS_NOTOLEMOD "O ficheiro não parece ser um módulo OLE válido. Impossível registrar o controlo OLE." IDS_NOTOLEMODCAPTION "Adicionar Controlo" } - -IDD_PASTESPECIAL4 DIALOG DISCARDABLE 3, 15, 293, 140 -STYLE DS_MODALFRAME | DS_SETFONT | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Colar Especial" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Origem:", -1, 6, 9, 30, 8, WS_VISIBLE | WS_GROUP - CONTROL "&Colar", IDC_PS_PASTE, "Button", BS_AUTORADIOBUTTON | WS_TABSTOP | WS_GROUP | WS_VISIBLE, - 6, 38, 55, 10 - CONTROL "Colar &Ligação", IDC_PS_PASTELINK, "Button", BS_AUTORADIOBUTTON | WS_VISIBLE, - 6, 63, 55, 10 - LTEXT "&Como:", -1, 65, 25, 16, 8, WS_VISIBLE | WS_GROUP - LISTBOX IDC_PS_PASTELIST, 65, 36, 153, 57, LBS_NOTIFY | LBS_USETABSTOPS | WS_VSCROLL | WS_BORDER | NOT WS_VISIBLE - LISTBOX IDC_PS_PASTELINKLIST, 65, 36, 153, 57, LBS_NOTIFY | LBS_USETABSTOPS | WS_VSCROLL | WS_BORDER | NOT WS_VISIBLE - LISTBOX IDC_PS_DISPLAYLIST, 65, 36, 153, 57, LBS_NOTIFY | LBS_USETABSTOPS | WS_VSCROLL | WS_BORDER | WS_VISIBLE - CONTROL "OK", IDOK, "Button", BS_DEFPUSHBUTTON | WS_TABSTOP | WS_GROUP | WS_VISIBLE, 224, 6, 66, 14 - CONTROL "Cancelar", IDCANCEL, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 224, 23, 66, 14 - CONTROL "&Ajuda", IDC_OLEUIHELP, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 224, 42, 66, 14 - CONTROL "&Mostrar como Icone", IDC_PS_DISPLAYASICON, "Button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_VISIBLE, 224, 59, 66, 14 - CONTROL "", IDC_PS_ICONDISPLAY, "Static", SS_ICON | WS_VISIBLE, 224, 75, 66, 44 - CONTROL "Mudar &Icone...", IDC_PS_CHANGEICON, "Button", BS_PUSHBUTTON | WS_TABSTOP | WS_VISIBLE, 224, 123, 66, 14 - CONTROL "", IDC_PS_RESULTIMAGE, "Static", SS_ICON | WS_VISIBLE, 8, 101, 42, 34 - CONTROL "<< texto resultante fica aqui >>", IDC_PS_RESULTTEXT, "Static", SS_NOPREFIX | WS_VISIBLE, 54, 100, 159, 35 - CONTROL "Resultado", -1, "Button", BS_GROUPBOX | WS_GROUP | WS_VISIBLE, 6, 90, 212, 48 - CONTROL "", IDC_PS_SOURCETEXT, "Edit", ES_READONLY | ES_AUTOHSCROLL | WS_VISIBLE, 37, 9, 180, 8 -END - -STRINGTABLE DISCARDABLE -{ - IDS_PS_PASTE_DATA "Insere o conteúdo da área de transferência no seu documento como %s." - IDS_PS_PASTE_OBJECT "Insere o conteúdo da área de transferência no seu documento para que o possa activar usando %s." - IDS_PS_PASTE_OBJECT_AS_ICON "Insere o conteúdo da área de transferência no seu documento para que o possa activar usando %s. Vai ser mostrado como um icone." - IDS_PS_PASTE_LINK_DATA "Insere o conteúdo da área de transferência no seu documento como %s. Os dados estão ligados ao ficheiro de origem para que alterações ao ficheiro se reflictam no seu documento." - IDS_PS_PASTE_LINK_OBJECT "Insere uma imagem da área de transferência no seu documento. A imagem fica ligada ao ficheiro de origem para que alterações ao ficheiro se reflictam no seu documento." - IDS_PS_PASTE_LINK_OBJECT_AS_ICON "Insere um atalho que aponta para a localização do conteúdo na área de transferência. O atalho fica ligado ao ficheiro de origem para que alterações ao ficheiro se reflictam no seu documento." - IDS_PS_NON_OLE "Insere o conteúdo da área de transferência no seu documento." - IDS_PS_UNKNOWN_TYPE "Tipo Desconhecido" - IDS_PS_UNKNOWN_SRC "Origem Desconhecida" - IDS_PS_UNKNOWN_APP "o programa que o criou" -} diff --git a/dlls/oledlg/oledlg_Ru.rc b/dlls/oledlg/oledlg_Ru.rc index be020800b69..10453ef97eb 100644 --- a/dlls/oledlg/oledlg_Ru.rc +++ b/dlls/oledlg/oledlg_Ru.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 diff --git a/dlls/oledlg/oledlg_Si.rc b/dlls/oledlg/oledlg_Si.rc index 0f737af2d61..04e0eb3c3cb 100644 --- a/dlls/oledlg/oledlg_Si.rc +++ b/dlls/oledlg/oledlg_Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -97,3 +95,5 @@ STRINGTABLE DISCARDABLE IDS_PS_UNKNOWN_SRC "Neznan vir" IDS_PS_UNKNOWN_APP "Neznan program" } + +#pragma code_page(default) diff --git a/dlls/oledlg/oledlg_Sv.rc b/dlls/oledlg/oledlg_Sv.rc index 6a38d90e369..c775f4661f1 100644 --- a/dlls/oledlg/oledlg_Sv.rc +++ b/dlls/oledlg/oledlg_Sv.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 diff --git a/dlls/oledlg/oledlg_Tr.rc b/dlls/oledlg/oledlg_Tr.rc index 7e68c0094ed..8a96fe43220 100644 --- a/dlls/oledlg/oledlg_Tr.rc +++ b/dlls/oledlg/oledlg_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT UIINSERTOBJECT DIALOG DISCARDABLE 0, 0, 294, 151 diff --git a/dlls/oledlg/oledlg_Zh.rc b/dlls/oledlg/oledlg_Zh.rc index 40aac0b9814..2f2daeda90d 100644 --- a/dlls/oledlg/oledlg_Zh.rc +++ b/dlls/oledlg/oledlg_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -178,3 +176,5 @@ STRINGTABLE DISCARDABLE IDS_PS_UNKNOWN_SRC "不明來源" IDS_PS_UNKNOWN_APP "不明應用程式" } + +#pragma code_page(default) diff --git a/dlls/oledlg/resource.h b/dlls/oledlg/resource.h index 13ca052daa8..518f7ba6255 100644 --- a/dlls/oledlg/resource.h +++ b/dlls/oledlg/resource.h @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include - #define IDS_RESULTOBJDESC 101 #define IDS_RESULTFILEOBJDESC 102 #define IDS_BROWSE 103 diff --git a/dlls/oledlg/rsrc.rc b/dlls/oledlg/rsrc.rc new file mode 100644 index 00000000000..6379efcb4f8 --- /dev/null +++ b/dlls/oledlg/rsrc.rc @@ -0,0 +1,54 @@ +/* + * Top level resource file for OLE Dialogs + * + * Copyright 2003 Ulrich Czekalla for CodeWeavers + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winnls.h" +#include "oledlg.h" + +#include "resource.h" + +/* + * Everything specific to any language goes + * in one of the specific files. + * Note that you can and may override resources + * which also have a neutral version. This is to + * get localized bitmaps for example. + */ +#include "oledlg_Cs.rc" +#include "oledlg_Da.rc" +#include "oledlg_De.rc" +#include "oledlg_En.rc" +#include "oledlg_Es.rc" +#include "oledlg_Fr.rc" +#include "oledlg_Hu.rc" +#include "oledlg_It.rc" +#include "oledlg_Ja.rc" +#include "oledlg_Ko.rc" +#include "oledlg_Nl.rc" +#include "oledlg_No.rc" +#include "oledlg_Pl.rc" +#include "oledlg_Pt.rc" +#include "oledlg_Ru.rc" +#include "oledlg_Si.rc" +#include "oledlg_Sv.rc" +#include "oledlg_Tr.rc" +#include "oledlg_Zh.rc" diff --git a/dlls/olepro32/README b/dlls/olepro32/README new file mode 100644 index 00000000000..1c505f2781e --- /dev/null +++ b/dlls/olepro32/README @@ -0,0 +1,9 @@ +29Nov99 +Sean Langley + +This library (OLEPRO32.DLL) is basically a sub-set of what is in OLEAUT32.DLL. +The main difference under Win32 is that OLEPRO32.DLL can be used +as a type library. There are two functions in this DLL which are already +implemented in Wine. They are OleCreateFontIndirect, and OleTranslateColor. +The spec file for both of these functions points to the functions in the +OLEAUT32.DLL. diff --git a/dlls/olesvr.dll16/Makefile.in b/dlls/olesvr.dll16/Makefile.in index 8372456ae33..c7e4864493b 100644 --- a/dlls/olesvr.dll16/Makefile.in +++ b/dlls/olesvr.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = olesvr.dll16 IMPORTS = gdi32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,olesvr32.dll +SPEC_SRCS = olesvr.dll16.spec + C_SRCS = olesvr.c @MAKE_DLL_RULES@ diff --git a/dlls/opengl32/tests/opengl.c b/dlls/opengl32/tests/opengl.c index 2ced97d7985..3078b794151 100644 --- a/dlls/opengl32/tests/opengl.c +++ b/dlls/opengl32/tests/opengl.c @@ -320,7 +320,7 @@ static void test_sharelists(HDC winhdc) } /* Test 3: Share display lists with a context which already shares display lists with another context. - * According to MSDN the second parameter cannot share any display lists but some buggy drivers might allow it */ + * According to MSDN the second paramater can't share any display lists but some buggy drivers might allow it */ hglrc3 = wglCreateContext(winhdc); if(hglrc3) { diff --git a/dlls/rasapi16.dll16/Makefile.in b/dlls/rasapi16.dll16/Makefile.in index d61446a015e..ae51282a695 100644 --- a/dlls/rasapi16.dll16/Makefile.in +++ b/dlls/rasapi16.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = rasapi16.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,rasapi32.dll +SPEC_SRCS = rasapi16.dll16.spec + @MAKE_DLL_RULES@ @DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/riched20/editor.c b/dlls/riched20/editor.c index 1e18c101aa8..278b9aaa843 100644 --- a/dlls/riched20/editor.c +++ b/dlls/riched20/editor.c @@ -422,10 +422,7 @@ void ME_RTFCharAttrHook(RTF_Info *info) else if (info->rtfParam != rtfNoParam) { RTFColor *c = RTFGetColor(info, info->rtfParam); - if (c && c->rtfCBlue >= 0) - fmt.crTextColor = (c->rtfCBlue<<16)|(c->rtfCGreen<<8)|(c->rtfCRed); - else - fmt.dwEffects = CFE_AUTOBACKCOLOR; + fmt.crTextColor = (c->rtfCBlue<<16)|(c->rtfCGreen<<8)|(c->rtfCRed); } break; case rtfForeColor: @@ -436,11 +433,10 @@ void ME_RTFCharAttrHook(RTF_Info *info) else if (info->rtfParam != rtfNoParam) { RTFColor *c = RTFGetColor(info, info->rtfParam); - if (c && c->rtfCBlue >= 0) + if (c) fmt.crTextColor = (c->rtfCBlue<<16)|(c->rtfCGreen<<8)|(c->rtfCRed); - else { - fmt.dwEffects = CFE_AUTOCOLOR; - } + else + fmt.crTextColor = 0; } break; case rtfFontNum: @@ -1345,8 +1341,7 @@ static void ME_RTFReadHook(RTF_Info *info) { case rtfBeginGroup: if (info->stackTop < maxStack) { - info->stack[info->stackTop].style = info->style; - ME_AddRefStyle(info->style); + info->stack[info->stackTop].fmt = info->style->fmt; info->stack[info->stackTop].codePage = info->codePage; info->stack[info->stackTop].unicodeLength = info->unicodeLength; } @@ -1355,6 +1350,7 @@ static void ME_RTFReadHook(RTF_Info *info) break; case rtfEndGroup: { + ME_Style *s; RTFFlushOutputBuffer(info); info->stackTop--; if (info->stackTop<=0) { @@ -1362,12 +1358,15 @@ static void ME_RTFReadHook(RTF_Info *info) return; } assert(info->stackTop >= 0); - - ME_ReleaseStyle(info->style); - info->style = info->stack[info->stackTop].style; - ME_AddRefStyle(info->style); - info->codePage = info->stack[info->stackTop].codePage; - info->unicodeLength = info->stack[info->stackTop].unicodeLength; + if (info->styleChanged) + { + /* FIXME too slow ? how come ? */ + s = ME_ApplyStyle(info->style, &info->stack[info->stackTop].fmt); + ME_ReleaseStyle(info->style); + info->style = s; + info->codePage = info->stack[info->stackTop].codePage; + info->unicodeLength = info->stack[info->stackTop].unicodeLength; + } break; } } @@ -3195,7 +3194,7 @@ LRESULT ME_HandleMessage(ME_TextEditor *editor, UINT msg, WPARAM wParam, /* If we detect ascii rtf at the start of the string, * we know it isn't unicode. */ bRtf = (lParam && (!strncmp((char *)lParam, "{\\rtf", 5) || - !strncmp((char *)lParam, "{\\urtf", 6))); + !strncmp((char *)lParam, "{\\urtf}", 6))); bUnicode = !bRtf && pStruct->codepage == 1200; TRACE("EM_SETTEXTEX - %s, flags %d, cp %d\n", @@ -3464,8 +3463,7 @@ LRESULT ME_HandleMessage(ME_TextEditor *editor, UINT msg, WPARAM wParam, if (lParam) { TRACE("WM_SETTEXT lParam==%lx\n",lParam); - if (!strncmp((char *)lParam, "{\\rtf", 5) || - !strncmp((char *)lParam, "{\\urtf", 6)) + if (!unicode && !strncmp((char *)lParam, "{\\rtf", 5)) { /* Undocumented: WM_SETTEXT supports RTF text */ ME_StreamInRTFString(editor, 0, (char *)lParam); @@ -3587,11 +3585,6 @@ LRESULT ME_HandleMessage(ME_TextEditor *editor, UINT msg, WPARAM wParam, POINT *point = (POINT *)lParam; point->x = editor->horz_si.nPos; point->y = editor->vert_si.nPos; - /* 16-bit scaled value is returned as stored in scrollinfo */ - if (editor->horz_si.nMax > 0xffff) - point->x = MulDiv(point->x, 0xffff, editor->horz_si.nMax); - if (editor->vert_si.nMax > 0xffff) - point->y = MulDiv(point->y, 0xffff, editor->vert_si.nMax); return 1; } case EM_GETTEXTRANGE: @@ -3848,29 +3841,23 @@ LRESULT ME_HandleMessage(ME_TextEditor *editor, UINT msg, WPARAM wParam, } case WM_CREATE: { - INT max; + SCROLLINFO si; ME_SetDefaultFormatRect(editor); - max = (editor->styleFlags & ES_DISABLENOSCROLL) ? 1 : 0; - if (~editor->styleFlags & ES_DISABLENOSCROLL || editor->styleFlags & WS_VSCROLL) - ITextHost_TxSetScrollRange(editor->texthost, SB_VERT, 0, max, TRUE); - - if (~editor->styleFlags & ES_DISABLENOSCROLL || editor->styleFlags & WS_HSCROLL) - ITextHost_TxSetScrollRange(editor->texthost, SB_HORZ, 0, max, TRUE); - + si.cbSize = sizeof(si); + si.fMask = SIF_PAGE | SIF_RANGE; if (editor->styleFlags & ES_DISABLENOSCROLL) - { - if (editor->styleFlags & WS_VSCROLL) - { - ITextHost_TxEnableScrollBar(editor->texthost, SB_VERT, ESB_DISABLE_BOTH); - ITextHost_TxShowScrollBar(editor->texthost, SB_VERT, TRUE); - } - if (editor->styleFlags & WS_HSCROLL) - { - ITextHost_TxEnableScrollBar(editor->texthost, SB_HORZ, ESB_DISABLE_BOTH); - ITextHost_TxShowScrollBar(editor->texthost, SB_HORZ, TRUE); - } + si.fMask |= SIF_DISABLENOSCROLL; + si.nMax = (si.fMask & SIF_DISABLENOSCROLL) ? 1 : 0; + si.nMin = 0; + si.nPage = 0; + if (editor->hWnd) { + SetScrollInfo(editor->hWnd, SB_VERT, &si, TRUE); + SetScrollInfo(editor->hWnd, SB_HORZ, &si, TRUE); + } else { + ITextHost_TxSetScrollRange(editor->texthost, SB_VERT, si.nMin, si.nMax, TRUE); + ITextHost_TxSetScrollRange(editor->texthost, SB_HORZ, si.nMin, si.nMax, TRUE); } ME_CommitUndo(editor); @@ -4017,10 +4004,15 @@ LRESULT ME_HandleMessage(ME_TextEditor *editor, UINT msg, WPARAM wParam, case SB_THUMBTRACK: case SB_THUMBPOSITION: { - int pos = HIWORD(wParam); - if (editor->horz_si.nMax > 0xffff) - pos = MulDiv(pos, editor->horz_si.nMax, 0xffff); - ME_HScrollAbs(editor, pos); + SCROLLINFO sbi; + sbi.cbSize = sizeof(sbi); + sbi.fMask = SIF_TRACKPOS; + /* Try to get 32-bit track position value. */ + if (!GetScrollInfo(editor->hWnd, SB_HORZ, &sbi)) + /* GetScrollInfo failed, settle for 16-bit value in wParam. */ + sbi.nTrackPos = HIWORD(wParam); + + ME_HScrollAbs(editor, sbi.nTrackPos); break; } } @@ -4064,10 +4056,15 @@ LRESULT ME_HandleMessage(ME_TextEditor *editor, UINT msg, WPARAM wParam, case SB_THUMBTRACK: case SB_THUMBPOSITION: { - int pos = HIWORD(wParam); - if (editor->vert_si.nMax > 0xffff) - pos = MulDiv(pos, editor->vert_si.nMax, 0xffff); - ME_VScrollAbs(editor, pos); + SCROLLINFO sbi; + sbi.cbSize = sizeof(sbi); + sbi.fMask = SIF_TRACKPOS; + /* Try to get 32-bit track position value. */ + if (!GetScrollInfo(editor->hWnd, SB_VERT, &sbi)) + /* GetScrollInfo failed, settle for 16-bit value in wParam. */ + sbi.nTrackPos = HIWORD(wParam); + + ME_VScrollAbs(editor, sbi.nTrackPos); break; } } diff --git a/dlls/riched20/paint.c b/dlls/riched20/paint.c index a5be178a023..620ac69160c 100644 --- a/dlls/riched20/paint.c +++ b/dlls/riched20/paint.c @@ -1036,21 +1036,17 @@ void ME_ScrollAbs(ME_TextEditor *editor, int x, int y) if (editor->horz_si.nPos != x) { x = min(x, editor->horz_si.nMax); x = max(x, editor->horz_si.nMin); + ITextHost_TxSetScrollPos(editor->texthost, SB_HORZ, x, TRUE); scrollX = editor->horz_si.nPos - x; editor->horz_si.nPos = x; - if (editor->horz_si.nMax > 0xFFFF) /* scale to 16-bit value */ - x = MulDiv(x, 0xFFFF, editor->horz_si.nMax); - ITextHost_TxSetScrollPos(editor->texthost, SB_HORZ, x, TRUE); } if (editor->vert_si.nPos != y) { y = min(y, editor->vert_si.nMax - (int)editor->vert_si.nPage); y = max(y, editor->vert_si.nMin); + ITextHost_TxSetScrollPos(editor->texthost, SB_VERT, y, TRUE); scrollY = editor->vert_si.nPos - y; editor->vert_si.nPos = y; - if (editor->vert_si.nMax > 0xFFFF) /* scale to 16-bit value */ - y = MulDiv(y, 0xFFFF, editor->vert_si.nMax); - ITextHost_TxSetScrollPos(editor->texthost, SB_VERT, y, TRUE); } if (abs(scrollX) > editor->sizeWindow.cx || @@ -1065,28 +1061,22 @@ void ME_ScrollAbs(ME_TextEditor *editor, int x, int y) if (editor->hWnd) { LONG winStyle = GetWindowLongW(editor->hWnd, GWL_STYLE); - if (editor->styleFlags & WS_HSCROLL) - { - bScrollBarIsVisible = (winStyle & WS_HSCROLL) != 0; - bScrollBarWillBeVisible = (editor->nTotalWidth > editor->sizeWindow.cx - && (editor->styleFlags & WS_HSCROLL)) - || (editor->styleFlags & ES_DISABLENOSCROLL); - if (bScrollBarIsVisible != bScrollBarWillBeVisible) - ITextHost_TxShowScrollBar(editor->texthost, SB_HORZ, - bScrollBarWillBeVisible); - } + bScrollBarIsVisible = (winStyle & WS_HSCROLL) != 0; + bScrollBarWillBeVisible = (editor->nTotalWidth > editor->sizeWindow.cx + && (editor->styleFlags & WS_HSCROLL)) + || (editor->styleFlags & ES_DISABLENOSCROLL); + if (bScrollBarIsVisible != bScrollBarWillBeVisible) + ITextHost_TxShowScrollBar(editor->texthost, SB_HORZ, + bScrollBarWillBeVisible); - if (editor->styleFlags & WS_VSCROLL) - { - bScrollBarIsVisible = (winStyle & WS_VSCROLL) != 0; - bScrollBarWillBeVisible = (editor->nTotalLength > editor->sizeWindow.cy - && (editor->styleFlags & WS_VSCROLL) - && (editor->styleFlags & ES_MULTILINE)) - || (editor->styleFlags & ES_DISABLENOSCROLL); - if (bScrollBarIsVisible != bScrollBarWillBeVisible) - ITextHost_TxShowScrollBar(editor->texthost, SB_VERT, - bScrollBarWillBeVisible); - } + bScrollBarIsVisible = (winStyle & WS_VSCROLL) != 0; + bScrollBarWillBeVisible = (editor->nTotalLength > editor->sizeWindow.cy + && (editor->styleFlags & WS_VSCROLL) + && (editor->styleFlags & ES_MULTILINE)) + || (editor->styleFlags & ES_DISABLENOSCROLL); + if (bScrollBarIsVisible != bScrollBarWillBeVisible) + ITextHost_TxShowScrollBar(editor->texthost, SB_VERT, + bScrollBarWillBeVisible); } ME_UpdateScrollBar(editor); } @@ -1146,7 +1136,6 @@ void ME_UpdateScrollBar(ME_TextEditor *editor) si.cbSize = sizeof(si); si.fMask = SIF_PAGE | SIF_RANGE | SIF_POS; - si.nMin = 0; if (editor->styleFlags & ES_DISABLENOSCROLL) si.fMask |= SIF_DISABLENOSCROLL; @@ -1161,25 +1150,20 @@ void ME_UpdateScrollBar(ME_TextEditor *editor) return; } + si.nMin = 0; si.nMax = editor->nTotalWidth; si.nPos = editor->horz_si.nPos; si.nPage = editor->sizeWindow.cx; - if (si.nMax != editor->horz_si.nMax || + if (si.nMin != editor->horz_si.nMin || + si.nMax != editor->horz_si.nMax || si.nPage != editor->horz_si.nPage) { TRACE("min=%d max=%d page=%d\n", si.nMin, si.nMax, si.nPage); + editor->horz_si.nMin = si.nMin; editor->horz_si.nMax = si.nMax; editor->horz_si.nPage = si.nPage; - if ((bScrollBarWillBeVisible || bScrollBarWasVisible) && - editor->styleFlags & WS_HSCROLL) - { - if (si.nMax > 0xFFFF) - { - /* Native scales the scrollbar info to 16-bit external values. */ - si.nPos = MulDiv(si.nPos, 0xFFFF, si.nMax); - si.nMax = 0xFFFF; - } + if (bScrollBarWillBeVisible || bScrollBarWasVisible) { if (editor->hWnd) { SetScrollInfo(editor->hWnd, SB_HORZ, &si, TRUE); } else { @@ -1191,18 +1175,15 @@ void ME_UpdateScrollBar(ME_TextEditor *editor) } } - if (editor->styleFlags & WS_HSCROLL) - { - if (si.fMask & SIF_DISABLENOSCROLL) { - bScrollBarWillBeVisible = TRUE; - } else if (!(editor->styleFlags & WS_HSCROLL)) { - bScrollBarWillBeVisible = FALSE; - } - - if (bScrollBarWasVisible != bScrollBarWillBeVisible) - ITextHost_TxShowScrollBar(editor->texthost, SB_HORZ, bScrollBarWillBeVisible); + if (si.fMask & SIF_DISABLENOSCROLL) { + bScrollBarWillBeVisible = TRUE; + } else if (!(editor->styleFlags & WS_HSCROLL)) { + bScrollBarWillBeVisible = FALSE; } + if (bScrollBarWasVisible != bScrollBarWillBeVisible) + ITextHost_TxShowScrollBar(editor->texthost, SB_HORZ, bScrollBarWillBeVisible); + /* Update vertical scrollbar */ bScrollBarWasVisible = editor->vert_si.nMax > editor->vert_si.nPage; bScrollBarWillBeVisible = editor->nTotalLength > editor->sizeWindow.cy && @@ -1220,21 +1201,15 @@ void ME_UpdateScrollBar(ME_TextEditor *editor) si.nPos = editor->vert_si.nPos; si.nPage = editor->sizeWindow.cy; - if (si.nMax != editor->vert_si.nMax || + if (si.nMin != editor->vert_si.nMin || + si.nMax != editor->vert_si.nMax || si.nPage != editor->vert_si.nPage) { TRACE("min=%d max=%d page=%d\n", si.nMin, si.nMax, si.nPage); + editor->vert_si.nMin = si.nMin; editor->vert_si.nMax = si.nMax; editor->vert_si.nPage = si.nPage; - if ((bScrollBarWillBeVisible || bScrollBarWasVisible) && - editor->styleFlags & WS_VSCROLL) - { - if (si.nMax > 0xFFFF) - { - /* Native scales the scrollbar info to 16-bit external values. */ - si.nPos = MulDiv(si.nPos, 0xFFFF, si.nMax); - si.nMax = 0xFFFF; - } + if (bScrollBarWillBeVisible || bScrollBarWasVisible) { if (editor->hWnd) { SetScrollInfo(editor->hWnd, SB_VERT, &si, TRUE); } else { @@ -1246,18 +1221,15 @@ void ME_UpdateScrollBar(ME_TextEditor *editor) } } - if (editor->styleFlags & WS_VSCROLL) - { - if (si.fMask & SIF_DISABLENOSCROLL) { - bScrollBarWillBeVisible = TRUE; - } else if (!(editor->styleFlags & WS_VSCROLL)) { - bScrollBarWillBeVisible = FALSE; - } - - if (bScrollBarWasVisible != bScrollBarWillBeVisible) - ITextHost_TxShowScrollBar(editor->texthost, SB_VERT, - bScrollBarWillBeVisible); + if (si.fMask & SIF_DISABLENOSCROLL) { + bScrollBarWillBeVisible = TRUE; + } else if (!(editor->styleFlags & WS_VSCROLL)) { + bScrollBarWillBeVisible = FALSE; } + + if (bScrollBarWasVisible != bScrollBarWillBeVisible) + ITextHost_TxShowScrollBar(editor->texthost, SB_VERT, + bScrollBarWillBeVisible); } void ME_EnsureVisible(ME_TextEditor *editor, ME_Cursor *pCursor) @@ -1270,24 +1242,11 @@ void ME_EnsureVisible(ME_TextEditor *editor, ME_Cursor *pCursor) assert(pRow); assert(pPara); - if (editor->styleFlags & ES_AUTOHSCROLL) - { - x = pRun->pt.x + ME_PointFromChar(editor, pRun, pCursor->nOffset); - if (x > editor->horz_si.nPos + editor->sizeWindow.cx) - x = x + 1 - editor->sizeWindow.cx; - else if (x > editor->horz_si.nPos) - x = editor->horz_si.nPos; - - if (~editor->styleFlags & ES_AUTOVSCROLL) - { - ME_HScrollAbs(editor, x); - return; - } - } else { - if (~editor->styleFlags & ES_AUTOVSCROLL) - return; + x = pRun->pt.x + ME_PointFromChar(editor, pRun, pCursor->nOffset); + if (x > editor->horz_si.nPos + editor->sizeWindow.cx) + x = x + 1 - editor->sizeWindow.cx; + else if (x > editor->horz_si.nPos) x = editor->horz_si.nPos; - } y = pPara->member.para.pt.y + pRow->member.row.pt.y; yheight = pRow->member.row.nHeight; diff --git a/dlls/riched20/reader.c b/dlls/riched20/reader.c index a589a8e0786..b6a6f44f255 100644 --- a/dlls/riched20/reader.c +++ b/dlls/riched20/reader.c @@ -442,11 +442,7 @@ static void RTFUngetToken(RTF_Info *info) * increment the value to compensate for it being decremented * twice due to the RTFUngetToken. */ if(RTFCheckCM (info, rtfGroup, rtfEndGroup)) - { - info->stack[info->stackTop].style = info->style; - ME_AddRefStyle(info->style); info->stackTop++; - } } @@ -994,21 +990,18 @@ static void ReadColorTbl(RTF_Info *info) break; } cp->rtfCNum = cnum++; + cp->rtfCRed = cp->rtfCGreen = cp->rtfCBlue = -1; cp->rtfNextColor = info->colorList; info->colorList = cp; - if (!RTFCheckCM (info, rtfControl, rtfColorName)) - cp->rtfCRed = cp->rtfCGreen = cp->rtfCBlue = -1; - else { - cp->rtfCRed = cp->rtfCGreen = cp->rtfCBlue = 0; - do { - switch (info->rtfMinor) - { - case rtfRed: cp->rtfCRed = info->rtfParam & 0xFF; break; - case rtfGreen: cp->rtfCGreen = info->rtfParam & 0xFF; break; - case rtfBlue: cp->rtfCBlue = info->rtfParam & 0xFF; break; - } - RTFGetToken (info); - } while (RTFCheckCM (info, rtfControl, rtfColorName)); + while (RTFCheckCM (info, rtfControl, rtfColorName)) + { + switch (info->rtfMinor) + { + case rtfRed: cp->rtfCRed = info->rtfParam; break; + case rtfGreen: cp->rtfCGreen = info->rtfParam; break; + case rtfBlue: cp->rtfCBlue = info->rtfParam; break; + } + RTFGetToken (info); } if (info->rtfClass == rtfEOF) break; diff --git a/dlls/riched20/rtf.h b/dlls/riched20/rtf.h index d8ac32396a8..3277301b3a2 100644 --- a/dlls/riched20/rtf.h +++ b/dlls/riched20/rtf.h @@ -1095,7 +1095,7 @@ typedef void (*RTFFuncPtr) (RTF_Info *); /* generic function pointer */ /* RTF parser stack element */ struct tagRTFState { - ME_Style *style; + CHARFORMAT2W fmt; int codePage; int unicodeLength; }; diff --git a/dlls/riched20/tests/editor.c b/dlls/riched20/tests/editor.c index 914f25bd9ae..0383d1487bf 100644 --- a/dlls/riched20/tests/editor.c +++ b/dlls/riched20/tests/editor.c @@ -3282,15 +3282,10 @@ static void test_WM_SETTEXT(void) const char * TestItem7 = "TestSomeText\r\n\r\r\n\rTestSomeText"; const char * TestItem7_after = "TestSomeText\r\n \r\nTestSomeText"; - const char rtftextA[] = "{\\rtf sometext}"; - const char urtftextA[] = "{\\urtf sometext}"; - const WCHAR rtftextW[] = {'{','\\','r','t','f',' ','s','o','m','e','t','e','x','t','}',0}; - const WCHAR urtftextW[] = {'{','\\','u','r','t','f',' ','s','o','m','e','t','e','x','t','}',0}; - const WCHAR sometextW[] = {'s','o','m','e','t','e','x','t',0}; - char buf[1024] = {0}; - WCHAR bufW[1024] = {0}; LRESULT result; + EDITSTREAM es; + char * p; /* This test attempts to show that WM_SETTEXT on a riched20 control causes any solitary \r to be converted to \r\n on return. Properly paired @@ -3307,7 +3302,7 @@ static void test_WM_SETTEXT(void) result, lstrlen(buf)); \ result = strcmp(b, buf); \ ok(result == 0, \ - "WM_SETTEXT round trip: strcmp = %ld, text=\"%s\"\n", result, buf); + "WM_SETTEXT round trip: strcmp = %ld\n", result); TEST_SETTEXT(TestItem1, TestItem1) TEST_SETTEXT(TestItem2, TestItem2_after) @@ -3318,39 +3313,20 @@ static void test_WM_SETTEXT(void) TEST_SETTEXT(TestItem6, TestItem6_after) TEST_SETTEXT(TestItem7, TestItem7_after) - /* The following tests demonstrate that WM_SETTEXT supports RTF strings */ - TEST_SETTEXT(rtftextA, "sometext") /* interpreted as ascii rtf */ - TEST_SETTEXT(urtftextA, "sometext") /* interpreted as ascii rtf */ - TEST_SETTEXT(rtftextW, "{") /* interpreted as ascii text */ - TEST_SETTEXT(urtftextW, "{") /* interpreted as ascii text */ - DestroyWindow(hwndRichEdit); -#undef TEST_SETTEXT - -#define TEST_SETTEXTW(a, b) \ - result = SendMessageW(hwndRichEdit, WM_SETTEXT, 0, (LPARAM) a); \ - ok (result == 1, "WM_SETTEXT returned %ld instead of 1\n", result); \ - result = SendMessageW(hwndRichEdit, WM_GETTEXT, 1024, (LPARAM) bufW); \ - ok (result == lstrlenW(bufW), \ - "WM_GETTEXT returned %ld instead of expected %u\n", \ - result, lstrlenW(bufW)); \ - result = lstrcmpW(b, bufW); \ - ok(result == 0, "WM_SETTEXT round trip: strcmp = %ld\n", result); + /* The following test demonstrates that WM_SETTEXT supports RTF strings */ + SendMessage(hwndRichEdit, WM_SETTEXT, 0, (LPARAM) TestItem1); + p = buf; + es.dwCookie = (DWORD_PTR)&p; + es.dwError = 0; + es.pfnCallback = test_WM_SETTEXT_esCallback; + memset(buf, 0, sizeof(buf)); + SendMessage(hwndRichEdit, EM_STREAMOUT, + (WPARAM)(SF_RTF), (LPARAM)&es); + trace("EM_STREAMOUT produced:\n%s\n", buf); + TEST_SETTEXT(buf, TestItem1) - if (is_win9x) - { - skip("Cannot perform unicode tests\n"); - return; - } -hwndRichEdit = CreateWindowW(RICHEDIT_CLASS20W, NULL, - ES_MULTILINE|WS_POPUP|WS_HSCROLL|WS_VSCROLL|WS_VISIBLE, - 0, 0, 200, 60, NULL, NULL, hmoduleRichEdit, NULL); - ok(hwndRichEdit != NULL, "class: RichEdit20W, error: %d\n", (int) GetLastError()); - TEST_SETTEXTW(rtftextA, sometextW) /* interpreted as ascii rtf */ - TEST_SETTEXTW(urtftextA, sometextW) /* interpreted as ascii rtf */ - TEST_SETTEXTW(rtftextW, rtftextW) /* interpreted as ascii text */ - TEST_SETTEXTW(urtftextW, urtftextW) /* interpreted as ascii text */ +#undef TEST_SETTEXT DestroyWindow(hwndRichEdit); -#undef TEST_SETTEXTW } static void test_EM_STREAMOUT(void) diff --git a/dlls/rpcrt4/cproxy.c b/dlls/rpcrt4/cproxy.c index 9ce555f7146..0887aa2399b 100644 --- a/dlls/rpcrt4/cproxy.c +++ b/dlls/rpcrt4/cproxy.c @@ -76,10 +76,8 @@ struct thunk { extern void call_stubless_func(void); __ASM_GLOBAL_FUNC(call_stubless_func, "pushl %esp\n\t" /* pointer to index */ - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") "call " __ASM_NAME("ObjectStubless") __ASM_STDCALL(4) "\n\t" "popl %edx\n\t" /* args size */ - __ASM_CFI(".cfi_adjust_cfa_offset -4\n\t") "movl (%esp),%ecx\n\t" /* return address */ "addl %edx,%esp\n\t" "jmp *%ecx" ); diff --git a/dlls/rpcrt4/ndr_stubless.c b/dlls/rpcrt4/ndr_stubless.c index 8cb5f2b5e45..6a3854e0854 100644 --- a/dlls/rpcrt4/ndr_stubless.c +++ b/dlls/rpcrt4/ndr_stubless.c @@ -867,14 +867,9 @@ __declspec(naked) LONG_PTR __cdecl call_server_func(SERVER_ROUTINE func, unsigne LONG_PTR __cdecl call_server_func(SERVER_ROUTINE func, unsigned char * args, unsigned int stack_size); __ASM_GLOBAL_FUNC(call_server_func, "pushl %ebp\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %ebp,0\n\t") - "movl %esp,%ebp\n\t" - __ASM_CFI(".cfi_def_cfa_register %ebp\n\t") + "movl %esp, %ebp\n\t" "pushl %edi\n\t" /* Save registers */ - __ASM_CFI(".cfi_rel_offset %edi,-4\n\t") "pushl %esi\n\t" - __ASM_CFI(".cfi_rel_offset %esi,-8\n\t") "movl 16(%ebp), %eax\n\t" /* Get stack size */ "subl %eax, %esp\n\t" /* Make room in stack for arguments */ "andl $~15, %esp\n\t" /* Make sure stack has 16-byte alignment for Mac OS X */ @@ -887,13 +882,9 @@ __ASM_GLOBAL_FUNC(call_server_func, "call *8(%ebp)\n\t" /* Call function */ "leal -8(%ebp), %esp\n\t" /* Restore stack */ "popl %esi\n\t" /* Restore registers */ - __ASM_CFI(".cfi_same_value %esi\n\t") "popl %edi\n\t" - __ASM_CFI(".cfi_same_value %edi\n\t") "popl %ebp\n\t" - __ASM_CFI(".cfi_def_cfa %esp,4\n\t") - __ASM_CFI(".cfi_same_value %ebp\n\t") - "ret" ) + "ret\n" ) #else #warning call_server_func not implemented for your architecture LONG_PTR __cdecl call_server_func(SERVER_ROUTINE func, unsigned char * args, unsigned short stack_size) diff --git a/dlls/rpcrt4/ndr_stubless.h b/dlls/rpcrt4/ndr_stubless.h index 87f603b6065..e32ff634512 100644 --- a/dlls/rpcrt4/ndr_stubless.h +++ b/dlls/rpcrt4/ndr_stubless.h @@ -85,7 +85,7 @@ typedef struct _NDR_PROC_HEADER_RPC * RPCF_Asynchronous = 0x4000 - [async] MIDL attribute * Reserved = 0x8000 */ - unsigned int rpc_flags; + unsigned long rpc_flags; unsigned short proc_num; unsigned short stack_size; diff --git a/dlls/rpcrt4/rpc_assoc.c b/dlls/rpcrt4/rpc_assoc.c index 117301f42c0..256edb24a00 100644 --- a/dlls/rpcrt4/rpc_assoc.c +++ b/dlls/rpcrt4/rpc_assoc.c @@ -125,7 +125,7 @@ RPC_STATUS RPCRT4_GetAssociation(LPCSTR Protseq, LPCSTR NetworkAddr, RPC_STATUS RpcServerAssoc_GetAssociation(LPCSTR Protseq, LPCSTR NetworkAddr, LPCSTR Endpoint, LPCWSTR NetworkOptions, - ULONG assoc_gid, + unsigned long assoc_gid, RpcAssoc **assoc_out) { RpcAssoc *assoc; @@ -223,7 +223,7 @@ static RPC_STATUS RpcAssoc_BindConnection(const RpcAssoc *assoc, RpcConnection * RPC_MESSAGE msg; RPC_STATUS status; unsigned char *auth_data = NULL; - ULONG auth_length; + unsigned long auth_length; TRACE("sending bind request to server\n"); diff --git a/dlls/rpcrt4/rpc_assoc.h b/dlls/rpcrt4/rpc_assoc.h index 70fb664e31d..fb18acbe298 100644 --- a/dlls/rpcrt4/rpc_assoc.h +++ b/dlls/rpcrt4/rpc_assoc.h @@ -50,7 +50,7 @@ RPC_STATUS RPCRT4_GetAssociation(LPCSTR Protseq, LPCSTR NetworkAddr, LPCSTR Endp RPC_STATUS RpcAssoc_GetClientConnection(RpcAssoc *assoc, const RPC_SYNTAX_IDENTIFIER *InterfaceId, const RPC_SYNTAX_IDENTIFIER *TransferSyntax, RpcAuthInfo *AuthInfo, RpcQualityOfService *QOS, RpcConnection **Connection); void RpcAssoc_ReleaseIdleConnection(RpcAssoc *assoc, RpcConnection *Connection); ULONG RpcAssoc_Release(RpcAssoc *assoc); -RPC_STATUS RpcServerAssoc_GetAssociation(LPCSTR Protseq, LPCSTR NetworkAddr, LPCSTR Endpoint, LPCWSTR NetworkOptions, ULONG assoc_gid, RpcAssoc **assoc_out); +RPC_STATUS RpcServerAssoc_GetAssociation(LPCSTR Protseq, LPCSTR NetworkAddr, LPCSTR Endpoint, LPCWSTR NetworkOptions, unsigned long assoc_gid, RpcAssoc **assoc_out); RPC_STATUS RpcServerAssoc_AllocateContextHandle(RpcAssoc *assoc, void *CtxGuard, NDR_SCONTEXT *SContext); RPC_STATUS RpcServerAssoc_FindContextHandle(RpcAssoc *assoc, const UUID *uuid, void *CtxGuard, ULONG Flags, NDR_SCONTEXT *SContext); RPC_STATUS RpcServerAssoc_UpdateContextHandle(RpcAssoc *assoc, NDR_SCONTEXT SContext, void *CtxGuard, NDR_RUNDOWN rundown_routine); diff --git a/dlls/rpcrt4/rpc_binding.c b/dlls/rpcrt4/rpc_binding.c index 29e0709e54f..4463a3ba44a 100644 --- a/dlls/rpcrt4/rpc_binding.c +++ b/dlls/rpcrt4/rpc_binding.c @@ -796,7 +796,7 @@ RPC_STATUS WINAPI RpcBindingFree( RPC_BINDING_HANDLE* Binding ) RPC_STATUS WINAPI RpcBindingVectorFree( RPC_BINDING_VECTOR** BindingVector ) { RPC_STATUS status; - ULONG c; + unsigned long c; TRACE("(%p)\n", BindingVector); for (c=0; c<(*BindingVector)->Count; c++) { diff --git a/dlls/rpcrt4/rpc_defs.h b/dlls/rpcrt4/rpc_defs.h index e70731a3818..83d2483b035 100644 --- a/dlls/rpcrt4/rpc_defs.h +++ b/dlls/rpcrt4/rpc_defs.h @@ -31,13 +31,13 @@ typedef struct unsigned char drep[4]; /* Data representation */ unsigned short frag_len; /* Data size in bytes including header and tail. */ unsigned short auth_len; /* Authentication length */ - unsigned int call_id; /* Call identifier. */ + unsigned long call_id; /* Call identifier. */ } RpcPktCommonHdr; typedef struct { RpcPktCommonHdr common; - unsigned int alloc_hint; /* Data size in bytes excluding header and tail. */ + unsigned long alloc_hint; /* Data size in bytes excluding header and tail. */ unsigned short context_id; /* Presentation context identifier */ unsigned short opnum; } RpcPktRequestHdr; @@ -45,7 +45,7 @@ typedef struct typedef struct { RpcPktCommonHdr common; - unsigned int alloc_hint; /* Data size in bytes excluding header and tail. */ + unsigned long alloc_hint; /* Data size in bytes excluding header and tail. */ unsigned short context_id; /* Presentation context identifier */ unsigned char cancel_count; unsigned char reserved; @@ -54,12 +54,12 @@ typedef struct typedef struct { RpcPktCommonHdr common; - unsigned int alloc_hint; /* Data size in bytes excluding header and tail. */ + unsigned long alloc_hint; /* Data size in bytes excluding header and tail. */ unsigned short context_id; /* Presentation context identifier */ unsigned char cancel_count; /* Received cancel count */ unsigned char reserved; /* Force alignment! */ - unsigned int status; /* Runtime fault code (RPC_STATUS) */ - unsigned int reserved2; + unsigned long status; /* Runtime fault code (RPC_STATUS) */ + unsigned long reserved2; } RpcPktFaultHdr; typedef struct @@ -67,7 +67,7 @@ typedef struct RpcPktCommonHdr common; unsigned short max_tsize; /* Maximum transmission fragment size */ unsigned short max_rsize; /* Maximum receive fragment size */ - unsigned int assoc_gid; /* Associated group id */ + unsigned long assoc_gid; /* Associated group id */ unsigned char num_elements; /* Number of elements */ unsigned char padding[3]; /* Force alignment! */ unsigned short context_id; /* Presentation context identifier */ @@ -99,7 +99,7 @@ typedef struct RpcPktCommonHdr common; unsigned short max_tsize; /* Maximum transmission fragment size */ unsigned short max_rsize; /* Maximum receive fragment size */ - unsigned int assoc_gid; /* Associated group id */ + unsigned long assoc_gid; /* Associated group id */ /* * Following this header are these fields: * RpcAddressString server_address; @@ -147,7 +147,7 @@ typedef struct unsigned char auth_level; /* RPC_C_AUTHN_LEVEL* */ unsigned char auth_pad_length; /* length of padding to restore n % 4 alignment */ unsigned char auth_reserved; /* reserved, must be zero */ - unsigned int auth_context_id; /* unique value for the authenticated connection */ + unsigned long auth_context_id; /* unique value for the authenticated connection */ } RpcAuthVerifier; #define RPC_AUTH_VERIFIER_LEN(common_hdr) \ diff --git a/dlls/rpcrt4/rpc_epmap.c b/dlls/rpcrt4/rpc_epmap.c index 2a03484a200..c7eb222baa7 100644 --- a/dlls/rpcrt4/rpc_epmap.c +++ b/dlls/rpcrt4/rpc_epmap.c @@ -188,7 +188,7 @@ RPC_STATUS WINAPI RpcEpRegisterA( RPC_IF_HANDLE IfSpec, RPC_BINDING_VECTOR *Bind UUID_VECTOR *UuidVector, RPC_CSTR Annotation ) { PRPC_SERVER_INTERFACE If = IfSpec; - ULONG i; + unsigned long i; RPC_STATUS status = RPC_S_OK; error_status_t status2; ept_entry_t *entries; @@ -198,12 +198,12 @@ RPC_STATUS WINAPI RpcEpRegisterA( RPC_IF_HANDLE IfSpec, RPC_BINDING_VECTOR *Bind TRACE(" ifid=%s\n", debugstr_guid(&If->InterfaceId.SyntaxGUID)); for (i=0; iCount; i++) { RpcBinding* bind = BindingVector->BindingH[i]; - TRACE(" protseq[%d]=%s\n", i, debugstr_a(bind->Protseq)); - TRACE(" endpoint[%d]=%s\n", i, debugstr_a(bind->Endpoint)); + TRACE(" protseq[%ld]=%s\n", i, debugstr_a(bind->Protseq)); + TRACE(" endpoint[%ld]=%s\n", i, debugstr_a(bind->Endpoint)); } if (UuidVector) { for (i=0; iCount; i++) - TRACE(" obj[%d]=%s\n", i, debugstr_guid(UuidVector->Uuid[i])); + TRACE(" obj[%ld]=%s\n", i, debugstr_guid(UuidVector->Uuid[i])); } if (!BindingVector->Count) return RPC_S_OK; @@ -302,7 +302,7 @@ RPC_STATUS WINAPI RpcEpUnregister( RPC_IF_HANDLE IfSpec, RPC_BINDING_VECTOR *Bin UUID_VECTOR *UuidVector ) { PRPC_SERVER_INTERFACE If = IfSpec; - ULONG i; + unsigned long i; RPC_STATUS status = RPC_S_OK; error_status_t status2; ept_entry_t *entries; @@ -312,12 +312,12 @@ RPC_STATUS WINAPI RpcEpUnregister( RPC_IF_HANDLE IfSpec, RPC_BINDING_VECTOR *Bin TRACE(" ifid=%s\n", debugstr_guid(&If->InterfaceId.SyntaxGUID)); for (i=0; iCount; i++) { RpcBinding* bind = BindingVector->BindingH[i]; - TRACE(" protseq[%d]=%s\n", i, debugstr_a(bind->Protseq)); - TRACE(" endpoint[%d]=%s\n", i, debugstr_a(bind->Endpoint)); + TRACE(" protseq[%ld]=%s\n", i, debugstr_a(bind->Protseq)); + TRACE(" endpoint[%ld]=%s\n", i, debugstr_a(bind->Endpoint)); } if (UuidVector) { for (i=0; iCount; i++) - TRACE(" obj[%d]=%s\n", i, debugstr_guid(UuidVector->Uuid[i])); + TRACE(" obj[%ld]=%s\n", i, debugstr_guid(UuidVector->Uuid[i])); } entries = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*entries) * BindingVector->Count * (UuidVector ? UuidVector->Count : 1)); diff --git a/dlls/rpcrt4/rpc_message.c b/dlls/rpcrt4/rpc_message.c index cddfbd55358..46830c8583c 100644 --- a/dlls/rpcrt4/rpc_message.c +++ b/dlls/rpcrt4/rpc_message.c @@ -96,7 +96,7 @@ static int packet_has_auth_verifier(const RpcPktHdr *Header) } static VOID RPCRT4_BuildCommonHeader(RpcPktHdr *Header, unsigned char PacketType, - ULONG DataRepresentation) + unsigned long DataRepresentation) { Header->common.rpc_ver = RPC_VER_MAJOR; Header->common.rpc_ver_minor = RPC_VER_MINOR; @@ -111,8 +111,8 @@ static VOID RPCRT4_BuildCommonHeader(RpcPktHdr *Header, unsigned char PacketType /* Flags and fragment length are computed in RPCRT4_Send. */ } -static RpcPktHdr *RPCRT4_BuildRequestHeader(ULONG DataRepresentation, - ULONG BufferLength, +static RpcPktHdr *RPCRT4_BuildRequestHeader(unsigned long DataRepresentation, + unsigned long BufferLength, unsigned short ProcNum, UUID *ObjectUuid) { @@ -141,7 +141,8 @@ static RpcPktHdr *RPCRT4_BuildRequestHeader(ULONG DataRepresentation, return header; } -RpcPktHdr *RPCRT4_BuildResponseHeader(ULONG DataRepresentation, ULONG BufferLength) +RpcPktHdr *RPCRT4_BuildResponseHeader(unsigned long DataRepresentation, + unsigned long BufferLength) { RpcPktHdr *header; @@ -157,7 +158,8 @@ RpcPktHdr *RPCRT4_BuildResponseHeader(ULONG DataRepresentation, ULONG BufferLeng return header; } -RpcPktHdr *RPCRT4_BuildFaultHeader(ULONG DataRepresentation, RPC_STATUS Status) +RpcPktHdr *RPCRT4_BuildFaultHeader(unsigned long DataRepresentation, + RPC_STATUS Status) { RpcPktHdr *header; @@ -173,10 +175,10 @@ RpcPktHdr *RPCRT4_BuildFaultHeader(ULONG DataRepresentation, RPC_STATUS Status) return header; } -RpcPktHdr *RPCRT4_BuildBindHeader(ULONG DataRepresentation, +RpcPktHdr *RPCRT4_BuildBindHeader(unsigned long DataRepresentation, unsigned short MaxTransmissionSize, unsigned short MaxReceiveSize, - ULONG AssocGroupId, + unsigned long AssocGroupId, const RPC_SYNTAX_IDENTIFIER *AbstractId, const RPC_SYNTAX_IDENTIFIER *TransferId) { @@ -200,7 +202,7 @@ RpcPktHdr *RPCRT4_BuildBindHeader(ULONG DataRepresentation, return header; } -static RpcPktHdr *RPCRT4_BuildAuthHeader(ULONG DataRepresentation) +static RpcPktHdr *RPCRT4_BuildAuthHeader(unsigned long DataRepresentation) { RpcPktHdr *header; @@ -216,7 +218,7 @@ static RpcPktHdr *RPCRT4_BuildAuthHeader(ULONG DataRepresentation) return header; } -RpcPktHdr *RPCRT4_BuildBindNackHeader(ULONG DataRepresentation, +RpcPktHdr *RPCRT4_BuildBindNackHeader(unsigned long DataRepresentation, unsigned char RpcVersion, unsigned char RpcVersionMinor) { @@ -237,17 +239,17 @@ RpcPktHdr *RPCRT4_BuildBindNackHeader(ULONG DataRepresentation, return header; } -RpcPktHdr *RPCRT4_BuildBindAckHeader(ULONG DataRepresentation, +RpcPktHdr *RPCRT4_BuildBindAckHeader(unsigned long DataRepresentation, unsigned short MaxTransmissionSize, unsigned short MaxReceiveSize, - ULONG AssocGroupId, + unsigned long AssocGroupId, LPCSTR ServerAddress, - unsigned short Result, - unsigned short Reason, + unsigned long Result, + unsigned long Reason, const RPC_SYNTAX_IDENTIFIER *TransferId) { RpcPktHdr *header; - ULONG header_size; + unsigned long header_size; RpcAddressString *server_address; RpcResults *results; RPC_SYNTAX_IDENTIFIER *transfer_id; @@ -281,7 +283,7 @@ RpcPktHdr *RPCRT4_BuildBindAckHeader(ULONG DataRepresentation, return header; } -RpcPktHdr *RPCRT4_BuildHttpHeader(ULONG DataRepresentation, +RpcPktHdr *RPCRT4_BuildHttpHeader(unsigned long DataRepresentation, unsigned short flags, unsigned short num_data_items, unsigned int payload_size) @@ -813,14 +815,13 @@ static RPC_STATUS RPCRT4_SendWithAuth(RpcConnection *Connection, RpcPktHdr *Head if (Connection->AuthInfo && packet_has_auth_verifier(Header)) { RpcAuthVerifier *auth_hdr = (RpcAuthVerifier *)&pkt[Header->common.frag_len - alen]; - static LONG next_id; auth_hdr->auth_type = Connection->AuthInfo->AuthnSvc; auth_hdr->auth_level = Connection->AuthInfo->AuthnLevel; auth_hdr->auth_pad_length = auth_pad_len; auth_hdr->auth_reserved = 0; /* a unique number... */ - auth_hdr->auth_context_id = InterlockedIncrement(&next_id); + auth_hdr->auth_context_id = (unsigned long)Connection; if (AuthLength) memcpy(auth_hdr + 1, Auth, AuthLength); @@ -1122,14 +1123,14 @@ static RPC_STATUS RPCRT4_receive_fragment(RpcConnection *Connection, RpcPktHdr * RPC_STATUS RPCRT4_ReceiveWithAuth(RpcConnection *Connection, RpcPktHdr **Header, PRPC_MESSAGE pMsg, unsigned char **auth_data_out, - ULONG *auth_length_out) + unsigned long *auth_length_out) { RPC_STATUS status; DWORD hdr_length; unsigned short first_flag; - ULONG data_length; - ULONG buffer_length; - ULONG auth_length = 0; + unsigned long data_length; + unsigned long buffer_length; + unsigned long auth_length = 0; unsigned char *auth_data = NULL; RpcPktHdr *CurrentHeader = NULL; void *payload = NULL; @@ -1193,7 +1194,7 @@ RPC_STATUS RPCRT4_ReceiveWithAuth(RpcConnection *Connection, RpcPktHdr **Header, } if (CurrentHeader->common.auth_len != auth_length) { - WARN("auth_len header field changed from %d to %d\n", + WARN("auth_len header field changed from %ld to %d\n", auth_length, CurrentHeader->common.auth_len); status = RPC_S_PROTOCOL_ERROR; goto fail; @@ -1207,7 +1208,7 @@ RPC_STATUS RPCRT4_ReceiveWithAuth(RpcConnection *Connection, RpcPktHdr **Header, data_length = CurrentHeader->common.frag_len - hdr_length - header_auth_len; if (data_length + buffer_length > pMsg->BufferLength) { - TRACE("allocation hint exceeded, new buffer length = %d\n", + TRACE("allocation hint exceeded, new buffer length = %ld\n", data_length + buffer_length); pMsg->BufferLength = data_length + buffer_length; status = I_RpcReAllocateBuffer(pMsg); @@ -1606,7 +1607,7 @@ RPC_STATUS WINAPI I_RpcReceive(PRPC_MESSAGE pMsg) case PKT_RESPONSE: break; case PKT_FAULT: - ERR ("we got fault packet with status 0x%x\n", hdr->fault.status); + ERR ("we got fault packet with status 0x%lx\n", hdr->fault.status); status = NCA2RPC_STATUS(hdr->fault.status); if (is_hard_error(status)) goto fail; diff --git a/dlls/rpcrt4/rpc_message.h b/dlls/rpcrt4/rpc_message.h index aeeef0773e5..8ce5a558adc 100644 --- a/dlls/rpcrt4/rpc_message.h +++ b/dlls/rpcrt4/rpc_message.h @@ -25,18 +25,18 @@ typedef unsigned int NCA_STATUS; -RpcPktHdr *RPCRT4_BuildFaultHeader(ULONG DataRepresentation, RPC_STATUS Status); -RpcPktHdr *RPCRT4_BuildResponseHeader(ULONG DataRepresentation, ULONG BufferLength); -RpcPktHdr *RPCRT4_BuildBindHeader(ULONG DataRepresentation, unsigned short MaxTransmissionSize, unsigned short MaxReceiveSize, ULONG AssocGroupId, const RPC_SYNTAX_IDENTIFIER *AbstractId, const RPC_SYNTAX_IDENTIFIER *TransferId); -RpcPktHdr *RPCRT4_BuildBindNackHeader(ULONG DataRepresentation, unsigned char RpcVersion, unsigned char RpcVersionMinor); -RpcPktHdr *RPCRT4_BuildBindAckHeader(ULONG DataRepresentation, unsigned short MaxTransmissionSize, unsigned short MaxReceiveSize, ULONG AssocGroupId, LPCSTR ServerAddress, unsigned short Result, unsigned short Reason, const RPC_SYNTAX_IDENTIFIER *TransferId); -RpcPktHdr *RPCRT4_BuildHttpHeader(ULONG DataRepresentation, unsigned short flags, unsigned short num_data_items, unsigned int payload_size); +RpcPktHdr *RPCRT4_BuildFaultHeader(unsigned long DataRepresentation, RPC_STATUS Status); +RpcPktHdr *RPCRT4_BuildResponseHeader(unsigned long DataRepresentation, unsigned long BufferLength); +RpcPktHdr *RPCRT4_BuildBindHeader(unsigned long DataRepresentation, unsigned short MaxTransmissionSize, unsigned short MaxReceiveSize, unsigned long AssocGroupId, const RPC_SYNTAX_IDENTIFIER *AbstractId, const RPC_SYNTAX_IDENTIFIER *TransferId); +RpcPktHdr *RPCRT4_BuildBindNackHeader(unsigned long DataRepresentation, unsigned char RpcVersion, unsigned char RpcVersionMinor); +RpcPktHdr *RPCRT4_BuildBindAckHeader(unsigned long DataRepresentation, unsigned short MaxTransmissionSize, unsigned short MaxReceiveSize, unsigned long AssocGroupId, LPCSTR ServerAddress, unsigned long Result, unsigned long Reason, const RPC_SYNTAX_IDENTIFIER *TransferId); +RpcPktHdr *RPCRT4_BuildHttpHeader(unsigned long DataRepresentation, unsigned short flags, unsigned short num_data_items, unsigned int payload_size); RpcPktHdr *RPCRT4_BuildHttpConnectHeader(unsigned short flags, int out_pipe, const UUID *connection_uuid, const UUID *pipe_uuid, const UUID *association_uuid); RpcPktHdr *RPCRT4_BuildHttpFlowControlHeader(BOOL server, ULONG bytes_transmitted, ULONG flow_control_increment, const UUID *pipe_uuid); VOID RPCRT4_FreeHeader(RpcPktHdr *Header); RPC_STATUS RPCRT4_Send(RpcConnection *Connection, RpcPktHdr *Header, void *Buffer, unsigned int BufferLength); RPC_STATUS RPCRT4_Receive(RpcConnection *Connection, RpcPktHdr **Header, PRPC_MESSAGE pMsg); -RPC_STATUS RPCRT4_ReceiveWithAuth(RpcConnection *Connection, RpcPktHdr **Header, PRPC_MESSAGE pMsg, unsigned char **auth_data_out, ULONG *auth_length_out); +RPC_STATUS RPCRT4_ReceiveWithAuth(RpcConnection *Connection, RpcPktHdr **Header, PRPC_MESSAGE pMsg, unsigned char **auth_data_out, unsigned long *auth_length_out); DWORD RPCRT4_GetHeaderSize(const RpcPktHdr *Header); RPC_STATUS RPCRT4_ValidateCommonHeader(const RpcPktCommonHdr *hdr); diff --git a/dlls/rtutils/Makefile.in b/dlls/rtutils/Makefile.in deleted file mode 100644 index d695502c50f..00000000000 --- a/dlls/rtutils/Makefile.in +++ /dev/null @@ -1,15 +0,0 @@ -TOPSRCDIR = @top_srcdir@ -TOPOBJDIR = ../.. -SRCDIR = @srcdir@ -VPATH = @srcdir@ -MODULE = rtutils.dll -IMPORTLIB = rtutils -IMPORTS = kernel32 - -C_SRCS = \ - main.c \ - tracing.c - -@MAKE_DLL_RULES@ - -@DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/rtutils/main.c b/dlls/rtutils/main.c deleted file mode 100644 index 009101a5517..00000000000 --- a/dlls/rtutils/main.c +++ /dev/null @@ -1,47 +0,0 @@ -/* - * rtutils main - * - * Copyright 2009 Alexander Scott-Johns - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - - -#include - -#include "windef.h" -#include "winbase.h" -#include "wine/debug.h" - -WINE_DEFAULT_DEBUG_CHANNEL(rtutils); - -/*********************************************************************** - * DllMain (RTUTILS.@) - */ -BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) -{ - TRACE("(0x%p, %d, %p)\n",hinstDLL,fdwReason,lpvReserved); - - switch(fdwReason) - { - case DLL_WINE_PREATTACH: - return FALSE; /* prefer native version */ - case DLL_PROCESS_ATTACH: - DisableThreadLibraryCalls( hinstDLL ); - break; - } - - return TRUE; -} diff --git a/dlls/rtutils/rtutils.spec b/dlls/rtutils/rtutils.spec deleted file mode 100644 index 1c8c9c3b0b1..00000000000 --- a/dlls/rtutils/rtutils.spec +++ /dev/null @@ -1,56 +0,0 @@ -@ stub CreateWaitEvent -@ stub CreateWaitEventBinding -@ stub CreateWaitTimer -@ stub DeRegisterWaitEventBinding -@ stub DeRegisterWaitEventBindingSelf -@ stub DeRegisterWaitEventsTimers -@ stub DeRegisterWaitEventsTimersSelf -@ stub DebugPrintWaitWorkerThreads -@ stub LogErrorA -@ stub LogErrorW -@ stub LogEventA -@ stub LogEventW -@ stub MprSetupProtocolEnum -@ stub MprSetupProtocolFree -@ stub QueueWorkItem -@ stub RegisterWaitEventBinding -@ stub RegisterWaitEventsTimers -@ stub RouterAssert -@ stub RouterGetErrorStringA -@ stub RouterGetErrorStringW -@ stub RouterLogDeregisterA -@ stub RouterLogDeregisterW -@ stub RouterLogEventA -@ stub RouterLogEventDataA -@ stub RouterLogEventDataW -@ stub RouterLogEventExA -@ stub RouterLogEventExW -@ stub RouterLogEventStringA -@ stub RouterLogEventStringW -@ stub RouterLogEventValistExA -@ stub RouterLogEventValistExW -@ stub RouterLogEventW -@ stub RouterLogRegisterA -@ stub RouterLogRegisterW -@ stub SetIoCompletionProc -@ stub TraceDeregisterA -@ stub TraceDeregisterExA -@ stub TraceDeregisterExW -@ stub TraceDeregisterW -@ stub TraceDumpExA -@ stub TraceDumpExW -@ stub TraceGetConsoleA -@ stub TraceGetConsoleW -@ stub TracePrintfA -@ stub TracePrintfExA -@ stub TracePrintfExW -@ stub TracePrintfW -@ stub TracePutsExA -@ stub TracePutsExW -@ stdcall TraceRegisterExA(str long) -@ stdcall TraceRegisterExW(wstr long) -@ stub TraceVprintfExA -@ stub TraceVprintfExW -@ stub UpdateWaitTimer -@ stub WTFreeEvent -@ stub WTFreeTimer diff --git a/dlls/rtutils/tracing.c b/dlls/rtutils/tracing.c deleted file mode 100644 index 96d1dfb4a02..00000000000 --- a/dlls/rtutils/tracing.c +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Tracing API functions - * - * Copyright 2009 Alexander Scott-Johns - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include -#include - -#include "windef.h" -#include "winbase.h" -#include "winnt.h" -#include "winuser.h" -#include "winnls.h" - -#include "wine/debug.h" - -#include "rtutils.h" - -WINE_DEFAULT_DEBUG_CHANNEL(rtutils); - -/****************************************************************************** - * TraceRegisterExW (RTUTILS.@) - */ -DWORD WINAPI TraceRegisterExW(LPCWSTR name, DWORD flags) -{ - FIXME("(%s, %x): stub\n", debugstr_w(name), flags); - return INVALID_TRACEID; -} - -/****************************************************************************** - * TraceRegisterExA (RTUTILS.@) - * - * See TraceRegisterExW. - */ -DWORD WINAPI TraceRegisterExA(LPCSTR name, DWORD flags) -{ - DWORD id; - int lenW = MultiByteToWideChar(CP_ACP, 0, name, -1, NULL, 0); - WCHAR* nameW = HeapAlloc(GetProcessHeap(), 0, lenW * sizeof(WCHAR)); - if (!nameW) - { - SetLastError(ERROR_OUTOFMEMORY); - return INVALID_TRACEID; - } - MultiByteToWideChar(CP_ACP, 0, name, -1, nameW, lenW); - id = TraceRegisterExW(nameW, flags); - HeapFree(GetProcessHeap(), 0, nameW); - return id; -} diff --git a/dlls/sane.ds/Makefile.in b/dlls/sane.ds/Makefile.in index e5c3fd45a5e..d13659406e6 100644 --- a/dlls/sane.ds/Makefile.in +++ b/dlls/sane.ds/Makefile.in @@ -15,24 +15,7 @@ C_SRCS = \ ui.c RC_SRCS = \ - sane_Da.rc \ - sane_De.rc \ - sane_En.rc \ - sane_Es.rc \ - sane_Fi.rc \ - sane_Fr.rc \ - sane_Ja.rc \ - sane_Ko.rc \ - sane_Lt.rc \ - sane_Nl.rc \ - sane_No.rc \ - sane_Pl.rc \ - sane_Pt.rc \ - sane_Ro.rc \ - sane_Ru.rc \ - sane_Si.rc \ - sane_Sv.rc \ - sane_Zh.rc + rsrc.rc @MAKE_DLL_RULES@ diff --git a/dlls/sane.ds/resource.h b/dlls/sane.ds/resource.h index 2454fbd4ce2..abc20447026 100644 --- a/dlls/sane.ds/resource.h +++ b/dlls/sane.ds/resource.h @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include -#include - #define IDD_DIALOG1 0x400 #define IDC_STATIC 0x401 diff --git a/dlls/sane.ds/rsrc.rc b/dlls/sane.ds/rsrc.rc new file mode 100644 index 00000000000..53d099f8d32 --- /dev/null +++ b/dlls/sane.ds/rsrc.rc @@ -0,0 +1,43 @@ +/* + * Top level resource file for Twain + * + * Copyright 2006 CodeWeavers, Aric Stewart + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winnls.h" + +#include "resource.h" + +#include "sane_Da.rc" +#include "sane_De.rc" +#include "sane_En.rc" +#include "sane_Es.rc" +#include "sane_Fi.rc" +#include "sane_Fr.rc" +#include "sane_Ko.rc" +#include "sane_Nl.rc" +#include "sane_No.rc" +#include "sane_Pl.rc" +#include "sane_Pt.rc" +#include "sane_Ro.rc" +#include "sane_Ru.rc" +#include "sane_Si.rc" +#include "sane_Sv.rc" +#include "sane_Zh.rc" diff --git a/dlls/sane.ds/sane_Da.rc b/dlls/sane.ds/sane_Da.rc index 98d89dabbd7..5a93ff1489a 100644 --- a/dlls/sane.ds/sane_Da.rc +++ b/dlls/sane.ds/sane_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 diff --git a/dlls/sane.ds/sane_De.rc b/dlls/sane.ds/sane_De.rc index 3f3e116c3dc..172098eba32 100644 --- a/dlls/sane.ds/sane_De.rc +++ b/dlls/sane.ds/sane_De.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 diff --git a/dlls/sane.ds/sane_En.rc b/dlls/sane.ds/sane_En.rc index d0d56b8f23b..3b58a0af8fb 100644 --- a/dlls/sane.ds/sane_En.rc +++ b/dlls/sane.ds/sane_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 diff --git a/dlls/sane.ds/sane_Es.rc b/dlls/sane.ds/sane_Es.rc index c65ebf9d573..0f0b4cbc007 100644 --- a/dlls/sane.ds/sane_Es.rc +++ b/dlls/sane.ds/sane_Es.rc @@ -17,9 +17,6 @@ * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ - -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL @@ -42,3 +39,5 @@ STRINGTABLE DISCARDABLE 5 "%" 6 "ns" } + +#pragma code_page(default) diff --git a/dlls/sane.ds/sane_Fi.rc b/dlls/sane.ds/sane_Fi.rc index 329eb06c826..85a664bfd89 100644 --- a/dlls/sane.ds/sane_Fi.rc +++ b/dlls/sane.ds/sane_Fi.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 diff --git a/dlls/sane.ds/sane_Fr.rc b/dlls/sane.ds/sane_Fr.rc index 49b0747c73f..b54153cfd67 100644 --- a/dlls/sane.ds/sane_Fr.rc +++ b/dlls/sane.ds/sane_Fr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 diff --git a/dlls/sane.ds/sane_Ja.rc b/dlls/sane.ds/sane_Ja.rc deleted file mode 100644 index 27e709549b6..00000000000 --- a/dlls/sane.ds/sane_Ja.rc +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Japanese resources for Twain - * - * Copyright 2009 CodeWeavers, Aric Stewart - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT - -IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE | DS_CENTER | DS_SETFOREGROUND -CAPTION "スキャン中" -FONT 9, "MS Shell Dlg" -BEGIN - LTEXT "スキャン中... しばらくお待ちください",IDC_STATIC,5,19,176,8, SS_CENTER -END - -STRINGTABLE DISCARDABLE -{ - 0 "" - 1 "px" - 2 "b" - 3 "mm" - 4 "dpi" - 5 "%" - 6 "ns" -} diff --git a/dlls/sane.ds/sane_Ko.rc b/dlls/sane.ds/sane_Ko.rc index 4a145b2da3f..980897a8da1 100644 --- a/dlls/sane.ds/sane_Ko.rc +++ b/dlls/sane.ds/sane_Ko.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 diff --git a/dlls/sane.ds/sane_Lt.rc b/dlls/sane.ds/sane_Lt.rc deleted file mode 100644 index 0afe173325e..00000000000 --- a/dlls/sane.ds/sane_Lt.rc +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Lithuanian resources for Twain - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE | DS_CENTER | DS_SETFOREGROUND -CAPTION "Skaitoma" -FONT 8, "MS Sans Serif" -BEGIN - LTEXT "SKAITOMA... Prašome palaukti",IDC_STATIC,5,19,176,8, SS_CENTER -END - -STRINGTABLE DISCARDABLE -{ - 0 "" - 1 "piks" - 2 "b" - 3 "mm" - 4 "tašk./col." - 5 "%" - 6 "ns" -} diff --git a/dlls/sane.ds/sane_Nl.rc b/dlls/sane.ds/sane_Nl.rc index ded7061957e..66559ab1d9f 100644 --- a/dlls/sane.ds/sane_Nl.rc +++ b/dlls/sane.ds/sane_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 diff --git a/dlls/sane.ds/sane_No.rc b/dlls/sane.ds/sane_No.rc index 13927883a1b..4d89f067fb2 100644 --- a/dlls/sane.ds/sane_No.rc +++ b/dlls/sane.ds/sane_No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 diff --git a/dlls/sane.ds/sane_Pl.rc b/dlls/sane.ds/sane_Pl.rc index 344d0c76b22..43a7e8b4bec 100644 --- a/dlls/sane.ds/sane_Pl.rc +++ b/dlls/sane.ds/sane_Pl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 diff --git a/dlls/sane.ds/sane_Pt.rc b/dlls/sane.ds/sane_Pt.rc index 9b0ff4152aa..4f4ffea51aa 100644 --- a/dlls/sane.ds/sane_Pt.rc +++ b/dlls/sane.ds/sane_Pt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 diff --git a/dlls/sane.ds/sane_Ro.rc b/dlls/sane.ds/sane_Ro.rc index dc02708bdb4..7199a613ad6 100644 --- a/dlls/sane.ds/sane_Ro.rc +++ b/dlls/sane.ds/sane_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -41,3 +39,5 @@ STRINGTABLE DISCARDABLE 5 "%" 6 "ns" } + +#pragma code_page(default) diff --git a/dlls/sane.ds/sane_Ru.rc b/dlls/sane.ds/sane_Ru.rc index eefe2772927..58ee4733620 100644 --- a/dlls/sane.ds/sane_Ru.rc +++ b/dlls/sane.ds/sane_Ru.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 diff --git a/dlls/sane.ds/sane_Si.rc b/dlls/sane.ds/sane_Si.rc index 04e7c67d1d6..ad6b8757176 100644 --- a/dlls/sane.ds/sane_Si.rc +++ b/dlls/sane.ds/sane_Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -42,3 +40,5 @@ STRINGTABLE DISCARDABLE 5 "%" 6 "ns" } + +#pragma code_page(default) diff --git a/dlls/sane.ds/sane_Sv.rc b/dlls/sane.ds/sane_Sv.rc index dee4f4565d2..90aab5541bb 100644 --- a/dlls/sane.ds/sane_Sv.rc +++ b/dlls/sane.ds/sane_Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL IDD_DIALOG1 DIALOG DISCARDABLE 0, 0, 186, 46 diff --git a/dlls/sane.ds/sane_Zh.rc b/dlls/sane.ds/sane_Zh.rc index 2487a6a9aac..955b6e199a9 100644 --- a/dlls/sane.ds/sane_Zh.rc +++ b/dlls/sane.ds/sane_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -64,3 +62,5 @@ STRINGTABLE DISCARDABLE 5 "%" 6 "ns" } + +#pragma code_page(default) diff --git a/dlls/secur32/dispatcher.c b/dlls/secur32/dispatcher.c index 666baea0feb..91f425ca1f9 100644 --- a/dlls/secur32/dispatcher.c +++ b/dlls/secur32/dispatcher.c @@ -19,7 +19,6 @@ */ #include "config.h" -#include "wine/port.h" #include #include #ifdef HAVE_UNISTD_H @@ -58,28 +57,16 @@ SECURITY_STATUS fork_helper(PNegoHelper *new_helper, const char *prog, } TRACE("\n"); -#ifdef HAVE_PIPE2 - if (pipe2( pipe_in, O_CLOEXEC ) < 0 ) -#endif + if( pipe(pipe_in) < 0 ) { - if( pipe(pipe_in) < 0 ) return SEC_E_INTERNAL_ERROR; - fcntl( pipe_in[0], F_SETFD, FD_CLOEXEC ); - fcntl( pipe_in[1], F_SETFD, FD_CLOEXEC ); + return SEC_E_INTERNAL_ERROR; } -#ifdef HAVE_PIPE2 - if (pipe2( pipe_out, O_CLOEXEC ) < 0 ) -#endif + if( pipe(pipe_out) < 0 ) { - if( pipe(pipe_out) < 0 ) - { - close(pipe_in[0]); - close(pipe_in[1]); - return SEC_E_INTERNAL_ERROR; - } - fcntl( pipe_out[0], F_SETFD, FD_CLOEXEC ); - fcntl( pipe_out[1], F_SETFD, FD_CLOEXEC ); + close(pipe_in[0]); + close(pipe_in[1]); + return SEC_E_INTERNAL_ERROR; } - if (!(helper = HeapAlloc(GetProcessHeap(),0, sizeof(NegoHelper)))) { close(pipe_in[0]); @@ -104,6 +91,9 @@ SECURITY_STATUS fork_helper(PNegoHelper *new_helper, const char *prog, if(helper->helper_pid == 0) { /* We're in the child now */ + close(0); + close(1); + dup2(pipe_out[0], 0); close(pipe_out[0]); close(pipe_out[1]); @@ -135,8 +125,10 @@ SECURITY_STATUS fork_helper(PNegoHelper *new_helper, const char *prog, helper->crypt.ntlm2.recv_sign_key = NULL; helper->crypt.ntlm2.recv_seal_key = NULL; helper->pipe_in = pipe_in[0]; + fcntl( pipe_in[0], F_SETFD, 1 ); close(pipe_in[1]); helper->pipe_out = pipe_out[1]; + fcntl( pipe_out[1], F_SETFD, 1 ); close(pipe_out[0]); } diff --git a/dlls/serialui/Bg.rc b/dlls/serialui/Bg.rc index 5f1e0f33d09..eb6976d0c73 100644 --- a/dlls/serialui/Bg.rc +++ b/dlls/serialui/Bg.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 200, 159 diff --git a/dlls/serialui/Cs.rc b/dlls/serialui/Cs.rc index ec1aae3db47..103388e9d54 100644 --- a/dlls/serialui/Cs.rc +++ b/dlls/serialui/Cs.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/dlls/serialui/Da.rc b/dlls/serialui/Da.rc index e0735f690fd..7d8e9d6944c 100644 --- a/dlls/serialui/Da.rc +++ b/dlls/serialui/Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/De.rc b/dlls/serialui/De.rc index b969aeec48a..ffd5148b70c 100644 --- a/dlls/serialui/De.rc +++ b/dlls/serialui/De.rc @@ -16,10 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 @@ -29,7 +25,7 @@ FONT 8, "MS Shell Dlg" BEGIN LTEXT "Bits pro Sekunde", -1,5,20,55,10 COMBOBOX IDC_BAUD, 60, 20, 90, 36, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP - LTEXT "Parität", -1,5,40,55,10 + LTEXT "Parität", -1,5,40,55,10 COMBOBOX IDC_PARITY, 60, 40, 90, 36, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP LTEXT "Flusssteuerung", -1,5,60,55,10 COMBOBOX IDC_FLOW, 60, 60, 90, 36, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP diff --git a/dlls/serialui/En.rc b/dlls/serialui/En.rc index 4ed10df7ed3..8cebaf34664 100644 --- a/dlls/serialui/En.rc +++ b/dlls/serialui/En.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/Eo.rc b/dlls/serialui/Eo.rc index 1a82c926acc..41f6ca6a16a 100644 --- a/dlls/serialui/Eo.rc +++ b/dlls/serialui/Eo.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/Es.rc b/dlls/serialui/Es.rc index e3f9affa51a..c833539f5a7 100644 --- a/dlls/serialui/Es.rc +++ b/dlls/serialui/Es.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/Fi.rc b/dlls/serialui/Fi.rc index a5624ba9cb1..8f103bd0f17 100644 --- a/dlls/serialui/Fi.rc +++ b/dlls/serialui/Fi.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/Fr.rc b/dlls/serialui/Fr.rc index 8dc8fbbe2aa..4f09a1e4336 100644 --- a/dlls/serialui/Fr.rc +++ b/dlls/serialui/Fr.rc @@ -3,8 +3,7 @@ * French language support * * Copyright 2000 Mike McCormack - * Copyright 2003 Vincent Béron - * Copyright 2009 Frédéric Delanoy + * Copyright 2003 Vincent Béron * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -21,30 +20,25 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL -IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 180, 150 +IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE -CAPTION "Propriétés pour " +CAPTION "Propriétés pour " FONT 8, "MS Shell Dlg" BEGIN - LTEXT "Vitesse de transmission (bauds)", -1,5,19,70,18 - COMBOBOX IDC_BAUD, 80, 20, 90, 15, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP - LTEXT "Parité", -1,5,42,55,10 - COMBOBOX IDC_PARITY, 80, 40, 90, 15, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP - LTEXT "Contrôle de flux", -1,5,62,55,10 - COMBOBOX IDC_FLOW, 80, 60, 90, 15, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP - LTEXT "Bits de données", -1,5,82,55,10 - COMBOBOX IDC_DATA, 80, 80, 90, 15, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP - LTEXT "Bits d'arrêt", -1,5,102,55,10 - COMBOBOX IDC_STOP, 80, 100, 90, 15, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK,30,125,50,14 - PUSHBUTTON "Annuler", IDCANCEL,93,125,50,14 + LTEXT "Vitesse de connexion", -1,5,20,55,10 + COMBOBOX IDC_BAUD, 60, 20, 90, 36, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP + LTEXT "Parité", -1,5,40,55,10 + COMBOBOX IDC_PARITY, 60, 40, 90, 36, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP + LTEXT "Contrôle de flux", -1,5,60,55,10 + COMBOBOX IDC_FLOW, 60, 60, 90, 36, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP + LTEXT "Bits de données", -1,5,80,55,10 + COMBOBOX IDC_DATA, 60, 80, 90, 36, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP + LTEXT "Bits de stop", -1,5,100,55,10 + COMBOBOX IDC_STOP, 60, 100, 90, 36, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP + DEFPUSHBUTTON "OK", IDOK,30,138,50,14 + PUSHBUTTON "Annuler", IDCANCEL,85,138,50,14 /* these two buttons are for testing Get/SetDefaultCommConfig */ /* PUSHBUTTON "GetDefault", ID_GETDEFAULT,30,115,50,14 */ /* PUSHBUTTON "SetDefault", ID_SETDEFAULT,85,115,50,14 */ diff --git a/dlls/serialui/Hu.rc b/dlls/serialui/Hu.rc index 08773cc3aab..a2666b688a2 100644 --- a/dlls/serialui/Hu.rc +++ b/dlls/serialui/Hu.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/It.rc b/dlls/serialui/It.rc index 18d5df7247a..853b377110c 100644 --- a/dlls/serialui/It.rc +++ b/dlls/serialui/It.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/Ja.rc b/dlls/serialui/Ja.rc index ad98bb65636..dbc829600de 100644 --- a/dlls/serialui/Ja.rc +++ b/dlls/serialui/Ja.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - /* UTF-8 */ #pragma code_page(65001) @@ -44,3 +42,5 @@ BEGIN /* PUSHBUTTON "標準値をロード", ID_GETDEFAULT,30,115,50,14 */ /* PUSHBUTTON "標準値として設定", ID_SETDEFAULT,85,115,50,14 */ END + +#pragma code_page(default) diff --git a/dlls/serialui/Ko.rc b/dlls/serialui/Ko.rc index 3403a11da3f..c4a5a33fdb0 100644 --- a/dlls/serialui/Ko.rc +++ b/dlls/serialui/Ko.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/Lt.rc b/dlls/serialui/Lt.rc deleted file mode 100644 index 9cd16d6ca6d..00000000000 --- a/dlls/serialui/Lt.rc +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "serialui.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE -CAPTION "Savybės: " -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Bodų sparta", -1,5,20,55,10 - COMBOBOX IDC_BAUD, 60, 20, 90, 36, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP - LTEXT "Lyginumas", -1,5,40,55,10 - COMBOBOX IDC_PARITY, 60, 40, 90, 36, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP - LTEXT "Srauto valdymas", -1,5,60,55,10 - COMBOBOX IDC_FLOW, 60, 60, 90, 36, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP - LTEXT "Duomenų bitai", -1,5,80,55,10 - COMBOBOX IDC_DATA, 60, 80, 90, 36, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP - LTEXT "Pabaigos bitai", -1,5,100,55,10 - COMBOBOX IDC_STOP, 60, 100, 90, 36, CBS_DROPDOWNLIST|CBS_AUTOHSCROLL|WS_BORDER | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "Gerai", IDOK,30,138,50,14 - PUSHBUTTON "Atsisakyti", IDCANCEL,85,138,50,14 - /* these two buttons are for testing Get/SetDefaultCommConfig */ - /* PUSHBUTTON "GetDefault", ID_GETDEFAULT,30,115,50,14 */ - /* PUSHBUTTON "SetDefault", ID_SETDEFAULT,85,115,50,14 */ -END diff --git a/dlls/serialui/Makefile.in b/dlls/serialui/Makefile.in index 8b3f1cab49e..3504a5e6aaa 100644 --- a/dlls/serialui/Makefile.in +++ b/dlls/serialui/Makefile.in @@ -9,29 +9,7 @@ IMPORTS = user32 advapi32 kernel32 C_SRCS = \ confdlg.c -RC_SRCS = \ - Bg.rc \ - Cs.rc \ - Da.rc \ - De.rc \ - En.rc \ - Eo.rc \ - Es.rc \ - Fi.rc \ - Fr.rc \ - Hu.rc \ - It.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pt.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc +RC_SRCS= serialui_rc.rc @MAKE_DLL_RULES@ diff --git a/dlls/serialui/Nl.rc b/dlls/serialui/Nl.rc index 39feecda3c4..1c186daafad 100644 --- a/dlls/serialui/Nl.rc +++ b/dlls/serialui/Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/No.rc b/dlls/serialui/No.rc index 276868b5bea..40d54ca9e70 100644 --- a/dlls/serialui/No.rc +++ b/dlls/serialui/No.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/Pt.rc b/dlls/serialui/Pt.rc index 6d424209d8e..8c66525e0ee 100644 --- a/dlls/serialui/Pt.rc +++ b/dlls/serialui/Pt.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/Ru.rc b/dlls/serialui/Ru.rc index 0234fb5f405..be092b4e583 100644 --- a/dlls/serialui/Ru.rc +++ b/dlls/serialui/Ru.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/Si.rc b/dlls/serialui/Si.rc index 2098b029302..f72de244a3c 100644 --- a/dlls/serialui/Si.rc +++ b/dlls/serialui/Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -43,3 +41,5 @@ BEGIN /* PUSHBUTTON "GetDefault", ID_GETDEFAULT,30,115,50,14 */ /* PUSHBUTTON "SetDefault", ID_SETDEFAULT,85,115,50,14 */ END + +#pragma code_page(default) diff --git a/dlls/serialui/Sv.rc b/dlls/serialui/Sv.rc index 8ce09284cfc..069e6c39979 100644 --- a/dlls/serialui/Sv.rc +++ b/dlls/serialui/Sv.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/Tr.rc b/dlls/serialui/Tr.rc index 3336fa5ca55..91ee6724c44 100644 --- a/dlls/serialui/Tr.rc +++ b/dlls/serialui/Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT IDD_SERIALUICONFIG DIALOG DISCARDABLE 0, 0, 160, 159 diff --git a/dlls/serialui/Zh.rc b/dlls/serialui/Zh.rc index adb25c52598..967d8c7e809 100644 --- a/dlls/serialui/Zh.rc +++ b/dlls/serialui/Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "serialui.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -70,3 +68,5 @@ BEGIN /* PUSHBUTTON "GetDefault", ID_GETDEFAULT,30,115,50,14 */ /* PUSHBUTTON "SetDefault", ID_SETDEFAULT,85,115,50,14 */ END + +#pragma code_page(default) diff --git a/dlls/serialui/serialui.h b/dlls/serialui/serialui.h index c4f1bdf4893..8eccc358cc8 100644 --- a/dlls/serialui/serialui.h +++ b/dlls/serialui/serialui.h @@ -19,9 +19,6 @@ #ifndef __WINE_SERIALUI_H #define __WINE_SERIALUI_H -#include -#include - #define IDD_SERIALUICONFIG 0x401 #define IDC_BAUD 0x402 #define IDC_PARITY 0x0403 diff --git a/dlls/serialui/serialui_rc.rc b/dlls/serialui/serialui_rc.rc new file mode 100644 index 00000000000..b732435ad22 --- /dev/null +++ b/dlls/serialui/serialui_rc.rc @@ -0,0 +1,44 @@ +/* + * Copyright 2000 Mike McCormack + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "serialui.h" + +#include "Bg.rc" +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Eo.rc" +#include "Es.rc" +#include "Fi.rc" +#include "Fr.rc" +#include "Hu.rc" +#include "It.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" diff --git a/dlls/setupapi/Bg.rc b/dlls/setupapi/Bg.rc index 05bfc56bc0d..1527cdeea05 100644 --- a/dlls/setupapi/Bg.rc +++ b/dlls/setupapi/Bg.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 diff --git a/dlls/setupapi/Cs.rc b/dlls/setupapi/Cs.rc index bb2f95199c5..9f30d3defcf 100644 --- a/dlls/setupapi/Cs.rc +++ b/dlls/setupapi/Cs.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/dlls/setupapi/Da.rc b/dlls/setupapi/Da.rc index 7a8381664b4..4af93ff4e46 100644 --- a/dlls/setupapi/Da.rc +++ b/dlls/setupapi/Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 diff --git a/dlls/setupapi/De.rc b/dlls/setupapi/De.rc index e3e8461ad33..fc388ed1ece 100644 --- a/dlls/setupapi/De.rc +++ b/dlls/setupapi/De.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - #pragma code_page(65001) LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL @@ -59,3 +57,5 @@ BEGIN PUSHBUTTON "Abbrechen", IDCANCEL, 195, 30, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "Durchsuchen...", IDC_RUNDLG_BROWSE, 190, 100, 55, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP END + +#pragma code_page(default) diff --git a/dlls/setupapi/En.rc b/dlls/setupapi/En.rc index 0524c273ceb..84619f6bd80 100644 --- a/dlls/setupapi/En.rc +++ b/dlls/setupapi/En.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/setupapi/Eo.rc b/dlls/setupapi/Eo.rc index 17dc1231201..c7210739c34 100644 --- a/dlls/setupapi/Eo.rc +++ b/dlls/setupapi/Eo.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 diff --git a/dlls/setupapi/Es.rc b/dlls/setupapi/Es.rc index 658d2e88a9f..78ff3d8e5c4 100644 --- a/dlls/setupapi/Es.rc +++ b/dlls/setupapi/Es.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 diff --git a/dlls/setupapi/Fi.rc b/dlls/setupapi/Fi.rc index d5da7674bda..c3a9cd18166 100644 --- a/dlls/setupapi/Fi.rc +++ b/dlls/setupapi/Fi.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 diff --git a/dlls/setupapi/Fr.rc b/dlls/setupapi/Fr.rc index 24095e57aad..54054256913 100644 --- a/dlls/setupapi/Fr.rc +++ b/dlls/setupapi/Fr.rc @@ -2,7 +2,7 @@ * French resources for SETUPAPI * * Copyright 2001 Andreas Mohr - * Copyright 2003 Vincent Béron + * Copyright 2003 Vincent Béron * Copyright 2009 Jonathan Ernst * * This library is free software; you can redistribute it and/or @@ -20,18 +20,13 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { - IDS_PROMPTDISK "Le fichier « %s » sur %s est requis" + IDS_PROMPTDISK "Le fichier « %s » sur %s est requis" IDS_UNKNOWN "Inconnu" - IDS_COPYFROM "Copier les fichiers depuis :" + IDS_COPYFROM "Copier les fichiers depuis :" IDS_INFO "Saisissez le chemin du fichier, puis cliquez sur OK." } @@ -41,9 +36,9 @@ CAPTION "Copie de fichiers..." FONT 8, "MS Shell Dlg" BEGIN PUSHBUTTON "Annuler", IDCANCEL, 79, 84, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - LTEXT "Source :", -1, 7, 7, 77, 11, WS_CHILD | WS_VISIBLE | WS_GROUP + LTEXT "Source :", -1, 7, 7, 77, 11, WS_CHILD | WS_VISIBLE | WS_GROUP LTEXT "", SOURCESTRORD, 7, 18, 194, 11, WS_CHILD | WS_VISIBLE | WS_GROUP - LTEXT "Destination :", -1, 7, 30, 77, 11, WS_CHILD | WS_VISIBLE | WS_GROUP + LTEXT "Destination :", -1, 7, 30, 77, 11, WS_CHILD | WS_VISIBLE | WS_GROUP LTEXT "", DESTSTRORD, 7, 41, 194, 22, WS_CHILD | WS_VISIBLE | WS_GROUP CONTROL "", PROGRESSORD, "setupx_progress", 7, 63, 194, 13, WS_CHILD | WS_VISIBLE | WS_TABSTOP END @@ -53,9 +48,9 @@ STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU CAPTION "Fichiers requis" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "Veuillez insérer le disque d'installation du fabricant et\nassurez vous que le lecteur correct est sélectionné ci-dessous", IDC_FILENEEDED, 10, 10, 175, 25, WS_CHILD | WS_VISIBLE | WS_GROUP + LTEXT "Veuillez insérer le disque d'installation du fabriquant et\nassurez vous que le lecteur correct est sélectionné ci-dessous", IDC_FILENEEDED, 10, 10, 175, 22, WS_CHILD | WS_VISIBLE | WS_GROUP LTEXT "", IDC_INFO, 10, 50, 175, 22, WS_CHILD | WS_VISIBLE | WS_GROUP - LTEXT "Copier les fichiers du fabricant depuis :", IDC_COPYFROM, 10, 90, 175, 11, WS_CHILD | WS_VISIBLE | WS_GROUP + LTEXT "Copier les fichiers du fabriquan depuis :", IDC_COPYFROM, 10, 90, 175, 11, WS_CHILD | WS_VISIBLE | WS_GROUP CONTROL "", IDC_PATH, "COMBOBOX", WS_TABSTOP | WS_GROUP | WS_VSCROLL | WS_VISIBLE | CBS_DISABLENOSCROLL | CBS_AUTOHSCROLL | CBS_DROPDOWN, 10, 100, 175, 14 PUSHBUTTON "OK", IDOK, 195, 10, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "Annuler", IDCANCEL, 195, 30, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP diff --git a/dlls/setupapi/Hu.rc b/dlls/setupapi/Hu.rc index ae8725d7537..afe3632ed8f 100644 --- a/dlls/setupapi/Hu.rc +++ b/dlls/setupapi/Hu.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 diff --git a/dlls/setupapi/It.rc b/dlls/setupapi/It.rc index f30859f379c..8f776dccee3 100644 --- a/dlls/setupapi/It.rc +++ b/dlls/setupapi/It.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 diff --git a/dlls/setupapi/Ja.rc b/dlls/setupapi/Ja.rc index 50fcb7af703..d8b419b8163 100644 --- a/dlls/setupapi/Ja.rc +++ b/dlls/setupapi/Ja.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - /* UTF-8 */ #pragma code_page(65001) @@ -37,3 +35,5 @@ BEGIN LTEXT "", DESTSTRORD, 7, 41, 194, 22, WS_CHILD | WS_VISIBLE | WS_GROUP CONTROL "", PROGRESSORD, "setupx_progress", 7, 63, 194, 13, WS_CHILD | WS_VISIBLE | WS_TABSTOP END + +#pragma code_page(default) diff --git a/dlls/setupapi/Ko.rc b/dlls/setupapi/Ko.rc index 6def9c230d0..dfd75a92c51 100644 --- a/dlls/setupapi/Ko.rc +++ b/dlls/setupapi/Ko.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/setupapi/Lt.rc b/dlls/setupapi/Lt.rc deleted file mode 100644 index ebee4acf130..00000000000 --- a/dlls/setupapi/Lt.rc +++ /dev/null @@ -1,61 +0,0 @@ -/* - * Lithuanian resources for SETUPAPI - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "setupapi_private.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_PROMPTDISK "Reikalingas failas „%s“ esantis %s" - IDS_UNKNOWN "Nežinomas" - IDS_COPYFROM "Kopijuoti failus iš:" - IDS_INFO "Įveskite kelią iki failo, o tada spauskite Gerai." -} - -COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 -STYLE DS_MODALFRAME | DS_SETFONT | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Kopijuojami failai..." -FONT 8, "MS Shell Dlg" -BEGIN - PUSHBUTTON "Atsisakyti", IDCANCEL, 79, 84, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - LTEXT "Šaltinis:", -1, 7, 7, 77, 11, WS_CHILD | WS_VISIBLE | WS_GROUP - LTEXT "", SOURCESTRORD, 7, 18, 194, 11, WS_CHILD | WS_VISIBLE | WS_GROUP - LTEXT "Paskirtis:", -1, 7, 30, 77, 11, WS_CHILD | WS_VISIBLE | WS_GROUP - LTEXT "", DESTSTRORD, 7, 41, 194, 22, WS_CHILD | WS_VISIBLE | WS_GROUP - CONTROL "", PROGRESSORD, "setupx_progress", 7, 63, 194, 13, WS_CHILD | WS_VISIBLE | WS_TABSTOP -END - -IDPROMPTFORDISK DIALOG MOVEABLE DISCARDABLE 0, 0, 250, 120 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Reikalingi failai" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Įdėkite gamintojo diegimo diską, o tada\nįsitikinkite, kad žemiau išrinktas teisingas diskas", IDC_FILENEEDED, 10, 10, 175, 22, WS_CHILD | WS_VISIBLE | WS_GROUP - LTEXT "", IDC_INFO, 10, 50, 175, 22, WS_CHILD | WS_VISIBLE | WS_GROUP - LTEXT "Kopijuoti gamintojo failus iš:", IDC_COPYFROM, 10, 90, 175, 11, WS_CHILD | WS_VISIBLE | WS_GROUP - CONTROL "", IDC_PATH, "COMBOBOX", WS_TABSTOP | WS_GROUP | WS_VSCROLL | WS_VISIBLE | CBS_DISABLENOSCROLL | CBS_AUTOHSCROLL | CBS_DROPDOWN, 10, 100, 175, 14 - PUSHBUTTON "Gerai", IDOK, 195, 10, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "Atsisakyti", IDCANCEL, 195, 30, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "Parinkti...", IDC_RUNDLG_BROWSE, 195, 100, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP -END diff --git a/dlls/setupapi/Makefile.in b/dlls/setupapi/Makefile.in index 971a5421ed9..700fce3d41e 100644 --- a/dlls/setupapi/Makefile.in +++ b/dlls/setupapi/Makefile.in @@ -31,32 +31,7 @@ C_SRCS16 = \ SPEC_SRCS16 = setupx.spec -RC_SRCS = \ - Bg.rc \ - Cs.rc \ - Da.rc \ - De.rc \ - En.rc \ - Eo.rc \ - Es.rc \ - Fi.rc \ - Fr.rc \ - Hu.rc \ - It.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ro.rc \ - Ru.rc \ - Si.rc \ - Sk.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc +RC_SRCS= setupapi.rc @MAKE_DLL_RULES@ diff --git a/dlls/setupapi/Nl.rc b/dlls/setupapi/Nl.rc index 019d6ccfe33..1aa43dd1747 100644 --- a/dlls/setupapi/Nl.rc +++ b/dlls/setupapi/Nl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/setupapi/No.rc b/dlls/setupapi/No.rc index a1d41f0211e..c41dab8467e 100644 --- a/dlls/setupapi/No.rc +++ b/dlls/setupapi/No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 diff --git a/dlls/setupapi/Pl.rc b/dlls/setupapi/Pl.rc index 34d9b464aa0..27a48e94379 100644 --- a/dlls/setupapi/Pl.rc +++ b/dlls/setupapi/Pl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 diff --git a/dlls/setupapi/Pt.rc b/dlls/setupapi/Pt.rc index 5d7ebdbdbba..be71b27bbca 100644 --- a/dlls/setupapi/Pt.rc +++ b/dlls/setupapi/Pt.rc @@ -2,8 +2,7 @@ * Portuguese resources for SETUPAPI * * Copyright 2003 Marcelo Duarte - * Copyright 2004 Américo José Melo - * Copyright 2009 Ricardo Filipe + * 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 @@ -20,20 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE - -STRINGTABLE DISCARDABLE -{ - IDS_PROMPTDISK "O ficheiro '%s' em %s é necessário" - IDS_UNKNOWN "Desconhecido" - IDS_COPYFROM "Copiar ficheiros de:" - IDS_INFO "Insira o caminho onde se encontram os ficheiros, depois carregue em OK." -} - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 @@ -63,17 +48,3 @@ BEGIN LTEXT "", DESTSTRORD, 7, 41, 194, 22, WS_CHILD | WS_VISIBLE | WS_GROUP CONTROL "", PROGRESSORD, "setupx_progress", 7, 63, 194, 13, WS_CHILD | WS_VISIBLE | WS_TABSTOP END - -IDPROMPTFORDISK DIALOG MOVEABLE DISCARDABLE 0, 0, 250, 120 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Ficheiros Necessários" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Insira o disco de instalação do fabricante, depois\nverifique se a drive correcta está seleccionada", IDC_FILENEEDED, 10, 10, 175, 22, WS_CHILD | WS_VISIBLE | WS_GROUP - LTEXT "", IDC_INFO, 10, 50, 175, 22, WS_CHILD | WS_VISIBLE | WS_GROUP - LTEXT "Copiar ficheiros do fabricante de:", IDC_COPYFROM, 10, 90, 175, 11, WS_CHILD | WS_VISIBLE | WS_GROUP - CONTROL "", IDC_PATH, "COMBOBOX", WS_TABSTOP | WS_GROUP | WS_VSCROLL | WS_VISIBLE | CBS_DISABLENOSCROLL | CBS_AUTOHSCROLL | CBS_DROPDOWN, 10, 100, 175, 14 - PUSHBUTTON "OK", IDOK, 195, 10, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "Cancelar", IDCANCEL, 195, 30, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "Procurar...", IDC_RUNDLG_BROWSE, 195, 100, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP -END diff --git a/dlls/setupapi/Ro.rc b/dlls/setupapi/Ro.rc index 8c3c1e0f5c2..80f90e86959 100644 --- a/dlls/setupapi/Ro.rc +++ b/dlls/setupapi/Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -57,3 +55,5 @@ BEGIN PUSHBUTTON "Renunță", IDCANCEL, 195, 30, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "Navigează...", IDC_RUNDLG_BROWSE, 195, 100, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP END + +#pragma code_page(default) diff --git a/dlls/setupapi/Ru.rc b/dlls/setupapi/Ru.rc index a7ba4d2da01..dafd2eaeb1c 100644 --- a/dlls/setupapi/Ru.rc +++ b/dlls/setupapi/Ru.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 diff --git a/dlls/setupapi/Si.rc b/dlls/setupapi/Si.rc index 839927b5fce..886644ee707 100644 --- a/dlls/setupapi/Si.rc +++ b/dlls/setupapi/Si.rc @@ -18,20 +18,10 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT -STRINGTABLE DISCARDABLE -{ - IDS_PROMPTDISK "Potrebujem datoteko '%s' na %s" - IDS_UNKNOWN "Neznan" - IDS_COPYFROM "Kopiraj datoteke iz:" - IDS_INFO "Napiši pot do datoteke in pritisni V redu." -} - COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 STYLE DS_MODALFRAME | DS_SETFONT | WS_POPUP | WS_VISIBLE | WS_CAPTION CAPTION "Kopiranje datotek ..." @@ -45,16 +35,4 @@ BEGIN CONTROL "", PROGRESSORD, "setupx_progress", 7, 63, 194, 13, WS_CHILD | WS_VISIBLE | WS_TABSTOP END -IDPROMPTFORDISK DIALOG MOVEABLE DISCARDABLE 0, 0, 250, 120 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Files Needed" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Vstavi proizvajalčev CD in spodaj preveri, če je\nizbran pravilen pogon", IDC_FILENEEDED, 10, 10, 175, 22, WS_CHILD | WS_VISIBLE | WS_GROUP - LTEXT "", IDC_INFO, 10, 50, 175, 22, WS_CHILD | WS_VISIBLE | WS_GROUP - LTEXT "Kopiraj proizvajalčeve datoteke iz:", IDC_COPYFROM, 10, 90, 175, 11, WS_CHILD | WS_VISIBLE | WS_GROUP - CONTROL "", IDC_PATH, "COMBOBOX", WS_TABSTOP | WS_GROUP | WS_VSCROLL | WS_VISIBLE | CBS_DISABLENOSCROLL | CBS_AUTOHSCROLL | CBS_DROPDOWN, 10, 100, 175, 14 - PUSHBUTTON "V redu", IDOK, 195, 10, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "Prekliči", IDCANCEL, 195, 30, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "Brskaj ...", IDC_RUNDLG_BROWSE, 195, 100, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP -END +#pragma code_page(default) diff --git a/dlls/setupapi/Sk.rc b/dlls/setupapi/Sk.rc index 7750d20349c..4b08a46b80d 100644 --- a/dlls/setupapi/Sk.rc +++ b/dlls/setupapi/Sk.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_SLOVAK, SUBLANG_DEFAULT COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 diff --git a/dlls/setupapi/Sv.rc b/dlls/setupapi/Sv.rc index e8cdd4bced6..e4b9ec68aa5 100644 --- a/dlls/setupapi/Sv.rc +++ b/dlls/setupapi/Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 diff --git a/dlls/setupapi/Tr.rc b/dlls/setupapi/Tr.rc index 55e31828151..3b922eeb167 100644 --- a/dlls/setupapi/Tr.rc +++ b/dlls/setupapi/Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT COPYFILEDLGORD DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 208, 105 diff --git a/dlls/setupapi/Zh.rc b/dlls/setupapi/Zh.rc index 8969d9f1a57..fdaa5dee515 100644 --- a/dlls/setupapi/Zh.rc +++ b/dlls/setupapi/Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "setupapi_private.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -52,3 +50,5 @@ BEGIN LTEXT "", DESTSTRORD, 7, 41, 194, 22, WS_CHILD | WS_VISIBLE | WS_GROUP CONTROL "", PROGRESSORD, "setupx_progress", 7, 63, 194, 13, WS_CHILD | WS_VISIBLE | WS_TABSTOP END + +#pragma code_page(default) diff --git a/dlls/setupapi/setupapi.rc b/dlls/setupapi/setupapi.rc new file mode 100644 index 00000000000..4a98758563c --- /dev/null +++ b/dlls/setupapi/setupapi.rc @@ -0,0 +1,50 @@ +/* + * Top level resource file for SETUPX + * + * Copyright 2001 Andreas Mohr + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winnls.h" +#include "setupapi_private.h" + +#include "Bg.rc" +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Es.rc" +#include "Eo.rc" +#include "Fi.rc" +#include "Fr.rc" +#include "Hu.rc" +#include "It.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ro.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sk.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" diff --git a/dlls/setupapi/setupapi_private.h b/dlls/setupapi/setupapi_private.h index 307dbae18dd..9aba8cf3afc 100644 --- a/dlls/setupapi/setupapi_private.h +++ b/dlls/setupapi/setupapi_private.h @@ -19,9 +19,6 @@ #ifndef __SETUPAPI_PRIVATE_H #define __SETUPAPI_PRIVATE_H -#include -#include - #define COPYFILEDLGORD 1000 #define SOURCESTRORD 500 #define DESTSTRORD 501 diff --git a/dlls/shdoclc/Bg.rc b/dlls/shdoclc/Bg.rc index 0cec8ec2f96..814ac7c918a 100644 --- a/dlls/shdoclc/Bg.rc +++ b/dlls/shdoclc/Bg.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT diff --git a/dlls/shdoclc/Da.rc b/dlls/shdoclc/Da.rc index 8a25db92dbf..5f22bc8ed61 100644 --- a/dlls/shdoclc/Da.rc +++ b/dlls/shdoclc/Da.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" LANGUAGE LANG_DANISH, SUBLANG_DEFAULT diff --git a/dlls/shdoclc/De.rc b/dlls/shdoclc/De.rc index f41619faeee..c2027732375 100644 --- a/dlls/shdoclc/De.rc +++ b/dlls/shdoclc/De.rc @@ -18,9 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" - -#pragma code_page(65001) LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL @@ -39,19 +36,19 @@ IDR_BROWSE_CONTEXT_MENU MENU { POPUP "Standard" { - MENUITEM "&Zurück", IDM_GOBACKWARD - MENUITEM "V&orwärts", IDM_GOFORWARD + MENUITEM "&Zurück", IDM_GOBACKWARD + MENUITEM "V&orwärts", IDM_GOFORWARD MENUITEM SEPARATOR MENUITEM "&Speichere Hintergrund als...", IDM_SAVEBACKGROUND MENUITEM "Als Hintergrund", IDM_SETWALLPAPER MENUITEM "Hintergrund &kopieren", IDM_COPYBACKGROUND MENUITEM "Als Desktopelement einrichten...", IDM_SETDESKTOPITEM MENUITEM SEPARATOR - MENUITEM "Alles &auswählen", IDM_SELECTALL - MENUITEM "Ein&fügen", IDM_PASTE + MENUITEM "Alles &auswählen", IDM_SELECTALL + MENUITEM "Ein&fügen", IDM_PASTE MENUITEM SEPARATOR - MENUITEM "Erzeuge &Verknüpfung", IDM_CREATESHORTCUT - MENUITEM "Zu &Favoriten hinzufügen", IDM_ADDFAVORITES + MENUITEM "Erzeuge &Verknüpfung", IDM_CREATESHORTCUT + MENUITEM "Zu &Favoriten hinzufügen", IDM_ADDFAVORITES MENUITEM "&Quelltextansicht", IDM_VIEWSOURCE MENUITEM SEPARATOR MENUITEM "&Textkodierung", IDM_LANGUAGE @@ -65,8 +62,8 @@ IDR_BROWSE_CONTEXT_MENU MENU POPUP "Bild" { - MENUITEM "&Öffne Verweis", IDM_FOLLOWLINKC - MENUITEM "Öffne Verweis in neuem Fenster", IDM_FOLLOWLINKN + MENUITEM "&Öffne Verweis", IDM_FOLLOWLINKC + MENUITEM "Öffne Verweis in neuem Fenster", IDM_FOLLOWLINKN MENUITEM "Speichere &Ziel als...", IDM_SAVETARGET MENUITEM "&Drucke Ziel", IDM_PRINTTARGET MENUITEM SEPARATOR @@ -80,10 +77,10 @@ IDR_BROWSE_CONTEXT_MENU MENU MENUITEM SEPARATOR MENUITEM "Aus&schneiden", IDM_CUT MENUITEM "&Kopieren", IDM_COPY - MENUITEM "Verk&nüpfung kopieren", IDM_COPYSHORTCUT - MENUITEM "Ein&fügen", IDM_PASTE + MENUITEM "Verk&nüpfung kopieren", IDM_COPYSHORTCUT + MENUITEM "Ein&fügen", IDM_PASTE MENUITEM SEPARATOR - MENUITEM "Zu &Favoriten hinzufügen...", IDM_ADDFAVORITES + MENUITEM "Zu &Favoriten hinzufügen...", IDM_ADDFAVORITES MENUITEM SEPARATOR MENUITEM SEPARATOR MENUITEM "&Eigenschaften", IDM_PROPERTIES @@ -91,20 +88,20 @@ IDR_BROWSE_CONTEXT_MENU MENU POPUP "Steuerung" { - MENUITEM "&Rückgängig", IDM_UNDO + MENUITEM "&Rückgängig", IDM_UNDO MENUITEM SEPARATOR MENUITEM "Aus&schneiden", IDM_CUT MENUITEM "&Kopieren", IDM_COPY - MENUITEM "Ein&fügen", IDM_PASTE - MENUITEM "&Löschen", IDM_DELETE + MENUITEM "Ein&fügen", IDM_PASTE + MENUITEM "&Löschen", IDM_DELETE MENUITEM SEPARATOR MENUITEM SEPARATOR - MENUITEM "Alles &auswählen", IDM_SELECTALL + MENUITEM "Alles &auswählen", IDM_SELECTALL } POPUP "Tabelle" { - POPUP "&Auswählen" + POPUP "&Auswählen" { MENUITEM "&Zelle", IDM_CELLSELECT MENUITEM "Zei&le", IDM_ROWSELECT @@ -121,25 +118,25 @@ IDR_BROWSE_CONTEXT_MENU MENU { MENUITEM "Aus&schneiden", IDM_CUT MENUITEM "&Kopieren", IDM_COPY - MENUITEM "Ein&fügen", IDM_PASTE - MENUITEM "Alles &auswählen", IDM_SELECTALL + MENUITEM "Ein&fügen", IDM_PASTE + MENUITEM "Alles &auswählen", IDM_SELECTALL MENUITEM "&Drucken", IDM_PRINT MENUITEM SEPARATOR } POPUP "Anker" { - MENUITEM "&Öffnen", IDM_FOLLOWLINKC - MENUITEM "Im &neuen Fenster öffnen", IDM_FOLLOWLINKN + MENUITEM "&Öffnen", IDM_FOLLOWLINKC + MENUITEM "Im &neuen Fenster öffnen", IDM_FOLLOWLINKN MENUITEM "Speichere &Ziel als...", IDM_SAVETARGET MENUITEM "&Drucke Ziel", IDM_PRINTTARGET MENUITEM SEPARATOR MENUITEM "Aus&schneiden", IDM_CUT MENUITEM "&Kopieren", IDM_COPY - MENUITEM "&Verknüpfung kopieren", IDM_COPYSHORTCUT - MENUITEM "Ein&fügen", IDM_PASTE + MENUITEM "&Verknüpfung kopieren", IDM_COPYSHORTCUT + MENUITEM "Ein&fügen", IDM_PASTE MENUITEM SEPARATOR - MENUITEM "Zu &Favoriten hinzufügen...", IDM_ADDFAVORITES + MENUITEM "Zu &Favoriten hinzufügen...", IDM_ADDFAVORITES MENUITEM SEPARATOR MENUITEM SEPARATOR MENUITEM "&Eigenschaften", IDM_PROPERTIES @@ -152,8 +149,8 @@ IDR_BROWSE_CONTEXT_MENU MENU POPUP "DYNSRC Bild" { - MENUITEM "&Öffne Verweis", IDM_FOLLOWLINKC - MENUITEM "Öffne Verweis in &neuem Fenster", IDM_FOLLOWLINKN + MENUITEM "&Öffne Verweis", IDM_FOLLOWLINKC + MENUITEM "Öffne Verweis in &neuem Fenster", IDM_FOLLOWLINKN MENUITEM "Speichere &Ziel als...", IDM_SAVETARGET MENUITEM "&Drucke Ziel", IDM_PRINTTARGET MENUITEM SEPARATOR @@ -164,10 +161,10 @@ IDR_BROWSE_CONTEXT_MENU MENU MENUITEM SEPARATOR MENUITEM "Aus&schneiden", IDM_CUT MENUITEM "&Kopieren", IDM_COPY - MENUITEM "&Verknüpfung kopieren", IDM_COPYSHORTCUT - MENUITEM "Ein&fügen", IDM_PASTE + MENUITEM "&Verknüpfung kopieren", IDM_COPYSHORTCUT + MENUITEM "Ein&fügen", IDM_PASTE MENUITEM SEPARATOR - MENUITEM "Zu &Favoriten hinzufügen...", IDM_ADDFAVORITES + MENUITEM "Zu &Favoriten hinzufügen...", IDM_ADDFAVORITES MENUITEM SEPARATOR MENUITEM SEPARATOR MENUITEM "Abspielen", IDM_DYNSRCPLAY @@ -177,8 +174,8 @@ IDR_BROWSE_CONTEXT_MENU MENU POPUP "ART Bild" { - MENUITEM "&Öffne Verweis", IDM_FOLLOWLINKC - MENUITEM "Öffne Verweis in &neuem Fenster", IDM_FOLLOWLINKN + MENUITEM "&Öffne Verweis", IDM_FOLLOWLINKC + MENUITEM "Öffne Verweis in &neuem Fenster", IDM_FOLLOWLINKN MENUITEM "Speichere &Ziel als...", IDM_SAVETARGET MENUITEM "&Drucke Ziel", IDM_PRINTTARGET MENUITEM SEPARATOR @@ -189,14 +186,14 @@ IDR_BROWSE_CONTEXT_MENU MENU MENUITEM SEPARATOR MENUITEM "Aus&schneiden", IDM_CUT MENUITEM "&Kopieren", IDM_COPY - MENUITEM "&Verknüpfung kopieren", IDM_COPYSHORTCUT - MENUITEM "&Einfügen", IDM_PASTE + MENUITEM "&Verknüpfung kopieren", IDM_COPYSHORTCUT + MENUITEM "&Einfügen", IDM_PASTE MENUITEM SEPARATOR - MENUITEM "Zu &Favoriten hinzufügen...", IDM_ADDFAVORITES + MENUITEM "Zu &Favoriten hinzufügen...", IDM_ADDFAVORITES MENUITEM SEPARATOR MENUITEM "Abspielen", IDM_IMGARTPLAY MENUITEM "Anhalten", IDM_IMGARTSTOP - MENUITEM "Rückspulen", IDM_IMGARTREWIND + MENUITEM "Rückspulen", IDM_IMGARTREWIND MENUITEM SEPARATOR MENUITEM SEPARATOR MENUITEM "&Eigenschaften", IDM_PROPERTIES diff --git a/dlls/shdoclc/En.rc b/dlls/shdoclc/En.rc index 4cb0a11d839..d237c519f80 100644 --- a/dlls/shdoclc/En.rc +++ b/dlls/shdoclc/En.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT @@ -47,7 +46,7 @@ IDR_BROWSE_CONTEXT_MENU MENU MENUITEM "&Paste", IDM_PASTE MENUITEM SEPARATOR MENUITEM "Create Shor&tcut", IDM_CREATESHORTCUT - MENUITEM "Add to &Favorites", IDM_ADDFAVORITES + MENUITEM "Add to &Favourites", IDM_ADDFAVORITES MENUITEM "&View Source", IDM_VIEWSOURCE MENUITEM SEPARATOR MENUITEM "&Encoding", IDM_LANGUAGE @@ -246,221 +245,3 @@ IDR_BROWSE_CONTEXT_MENU MENU MENUITEM "Scroll Right", IDM_SCROLL_RIGHT } } - -LANGUAGE LANG_ENGLISH, SUBLANG_NEUTRAL - -IDR_BROWSE_CONTEXT_MENU MENU -{ - POPUP "Default" - { - MENUITEM "&Back", IDM_GOBACKWARD - MENUITEM "F&orward", IDM_GOFORWARD - MENUITEM SEPARATOR - MENUITEM "&Save Background As...", IDM_SAVEBACKGROUND - MENUITEM "Set As Back&ground", IDM_SETWALLPAPER - MENUITEM "&Copy Background", IDM_COPYBACKGROUND - MENUITEM "Set as &Desktop Item", IDM_SETDESKTOPITEM - MENUITEM SEPARATOR - MENUITEM "Select &All", IDM_SELECTALL - MENUITEM "&Paste", IDM_PASTE - MENUITEM SEPARATOR - MENUITEM "Create Shor&tcut", IDM_CREATESHORTCUT - MENUITEM "Add to &Favourites", IDM_ADDFAVORITES - MENUITEM "&View Source", IDM_VIEWSOURCE - MENUITEM SEPARATOR - MENUITEM "&Encoding", IDM_LANGUAGE - MENUITEM SEPARATOR - MENUITEM "Pr&int", IDM_PRINT - MENUITEM "&Refresh", _IDM_REFRESH - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "&Properties", IDM_PROPERTIES - } - - POPUP "Image" - { - MENUITEM "&Open Link", IDM_FOLLOWLINKC - MENUITEM "Open Link in &New Window", IDM_FOLLOWLINKN - MENUITEM "Save Target &As...", IDM_SAVETARGET - MENUITEM "&Print Target", IDM_PRINTTARGET - MENUITEM SEPARATOR - MENUITEM "S&how Picture", IDM_SHOWPICTURE - MENUITEM "&Save Picture As...", IDM_SAVEPICTURE - MENUITEM "&E-mail Picture...", IDM_MP_EMAILPICTURE - MENUITEM "Pr&int Picture...", IDM_MP_PRINTPICTURE - MENUITEM "&Go to My Pictures", IDM_MP_MYPICS - MENUITEM "Set as Back&ground", IDM_SETWALLPAPER - MENUITEM "Set as &Desktop Item...", IDM_SETDESKTOPITEM - MENUITEM SEPARATOR - MENUITEM "Cu&t", IDM_CUT - MENUITEM "&Copy", IDM_COPY - MENUITEM "Copy Shor&tcut", IDM_COPYSHORTCUT - MENUITEM "&Paste", IDM_PASTE - MENUITEM SEPARATOR - MENUITEM "Add to &Favourites...", IDM_ADDFAVORITES - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "P&roperties", IDM_PROPERTIES - } - - POPUP "Control" - { - MENUITEM "&Undo", IDM_UNDO - MENUITEM SEPARATOR - MENUITEM "Cu&t", IDM_CUT - MENUITEM "&Copy", IDM_COPY - MENUITEM "&Paste", IDM_PASTE - MENUITEM "&Delete", IDM_DELETE - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "Select &All", IDM_SELECTALL - } - - POPUP "Table" - { - POPUP "&Select" - { - MENUITEM "&Cell", IDM_CELLSELECT - MENUITEM "&Row", IDM_ROWSELECT - MENUITEM "&Column", IDM_COLUMNSELECT - MENUITEM "&Table", IDM_TABLESELECT - } - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "&Cell Properties", IDM_CELLPROPERTIES - MENUITEM "&Table Properties", IDM_TABLEPROPERTIES - } - - POPUP "1DSite Select" - { - MENUITEM "Cu&t", IDM_CUT - MENUITEM "&Copy", IDM_COPY - MENUITEM "Paste", IDM_PASTE - MENUITEM "Select &All", IDM_SELECTALL - MENUITEM "&Print", IDM_PRINT - MENUITEM SEPARATOR - } - - POPUP "Anchor" - { - MENUITEM "&Open", IDM_FOLLOWLINKC - MENUITEM "Open in &New Window", IDM_FOLLOWLINKN - MENUITEM "Save Target &As...", IDM_SAVETARGET - MENUITEM "&Print Target", IDM_PRINTTARGET - MENUITEM SEPARATOR - MENUITEM "Cut", IDM_CUT - MENUITEM "&Copy", IDM_COPY - MENUITEM "Copy Shor&tcut", IDM_COPYSHORTCUT - MENUITEM "&Paste", IDM_PASTE - MENUITEM SEPARATOR - MENUITEM "Add to &Favourites...",IDM_ADDFAVORITES - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "P&roperties", IDM_PROPERTIES - } - - POPUP "Context Unknown" - { - MENUITEM SEPARATOR - } - - POPUP "DYNSRC Image" - { - MENUITEM "&Open Link", IDM_FOLLOWLINKC - MENUITEM "Open Link in &New Window", IDM_FOLLOWLINKN - MENUITEM "Save Target &As...", IDM_SAVETARGET - MENUITEM "&Print Target", IDM_PRINTTARGET - MENUITEM SEPARATOR - MENUITEM "S&how Picture", IDM_SHOWPICTURE - MENUITEM "&Save Video As...", IDM_SAVEPICTURE - MENUITEM "Set as Back&ground", IDM_SETWALLPAPER - MENUITEM "Set as &Desktop Item...", IDM_SETDESKTOPITEM - MENUITEM SEPARATOR - MENUITEM "Cu&t", IDM_CUT - MENUITEM "&Copy", IDM_COPY - MENUITEM "Copy Shor&tcut", IDM_COPYSHORTCUT - MENUITEM "&Paste", IDM_PASTE - MENUITEM SEPARATOR - MENUITEM "Add to &Favourites...", IDM_ADDFAVORITES - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "Play", IDM_DYNSRCPLAY - MENUITEM "Stop", IDM_DYNSRCSTOP - MENUITEM "P&roperties", IDM_PROPERTIES - } - - POPUP "ART Image" - { - MENUITEM "&Open Link", IDM_FOLLOWLINKC - MENUITEM "Open Link in &New Window", IDM_FOLLOWLINKN - MENUITEM "Save Target &As...", IDM_SAVETARGET - MENUITEM "&Print Target", IDM_PRINTTARGET - MENUITEM SEPARATOR - MENUITEM "S&how Picture", IDM_SHOWPICTURE - MENUITEM "&Save Picture As...", IDM_SAVEPICTURE - MENUITEM "Set as Back&ground", IDM_SETWALLPAPER - MENUITEM "Set as &Desktop Item...", IDM_SETDESKTOPITEM - MENUITEM SEPARATOR - MENUITEM "Cu&t", IDM_CUT - MENUITEM "&Copy", IDM_COPY - MENUITEM "Copy Shor&tcut", IDM_COPYSHORTCUT - MENUITEM "&Paste", IDM_PASTE - MENUITEM SEPARATOR - MENUITEM "Add to &Favourites...", IDM_ADDFAVORITES - MENUITEM SEPARATOR - MENUITEM "Play", IDM_IMGARTPLAY - MENUITEM "Stop", IDM_IMGARTSTOP - MENUITEM "Rewind", IDM_IMGARTREWIND - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "P&roperties", IDM_PROPERTIES - } - - POPUP "Debug" - { - MENUITEM "Trace Tags", IDM_TRACETAGS - MENUITEM "Resource Failures", IDM_RESOURCEFAILURES - MENUITEM "Dump Tracking Info", IDM_DUMPTRACKINGINFO - MENUITEM "Debug Break", IDM_DEBUGBREAK - MENUITEM "Debug View", IDM_DEBUGVIEW - MENUITEM "Dump Tree", IDM_DUMPTREE - MENUITEM "Dump Lines", IDM_DUMPLINES - MENUITEM "Dump DisplayTree", IDM_DUMPDISPLAYTREE - MENUITEM "Dump FormatCaches", IDM_DUMPFORMATCACHES - MENUITEM "Dump LayoutRects", IDM_DUMPLAYOUTRECTS - MENUITEM "Memory Monitor", IDM_MEMORYMONITOR - MENUITEM "Performance Meters", IDM_PERFORMANCEMETERS - MENUITEM "Save HTML", IDM_SAVEHTML - MENUITEM SEPARATOR - MENUITEM "&Browse View", IDM_BROWSEMODE - MENUITEM "&Edit View", IDM_EDITMODE - } - - POPUP "Vertical Scrollbar" - { - MENUITEM "Scroll Here", IDM_SCROLL_HERE - MENUITEM SEPARATOR - MENUITEM "Top", IDM_SCROLL_TOP - MENUITEM "Bottom", IDM_SCROLL_BOTTOM - MENUITEM SEPARATOR - MENUITEM "Page Up", IDM_SCROLL_PAGEUP - MENUITEM "Page Down", IDM_SCROLL_PAGEDOWN - MENUITEM SEPARATOR - MENUITEM "Scroll Up", IDM_SCROLL_UP - MENUITEM "Scroll Down", IDM_SCROLL_DOWN - } - - POPUP "Horizontal Scrollbar" - { - MENUITEM "Scroll Here", IDM_SCROLL_HERE - MENUITEM SEPARATOR - MENUITEM "Left Edge", IDM_SCROLL_LEFTEDGE - MENUITEM "Right Edge", IDM_SCROLL_RIGHTEDGE - MENUITEM SEPARATOR - MENUITEM "Page Left", IDM_SCROLL_PAGELEFT - MENUITEM "Page Right", IDM_SCROLL_PAGERIGHT - MENUITEM SEPARATOR - MENUITEM "Scroll Left", IDM_SCROLL_LEFT - MENUITEM "Scroll Right", IDM_SCROLL_RIGHT - } -} diff --git a/dlls/shdoclc/Es.rc b/dlls/shdoclc/Es.rc index fd2e3c7ce27..8be9757223a 100644 --- a/dlls/shdoclc/Es.rc +++ b/dlls/shdoclc/Es.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL diff --git a/dlls/shdoclc/Fi.rc b/dlls/shdoclc/Fi.rc index ae5e0c2b861..81233d31f97 100644 --- a/dlls/shdoclc/Fi.rc +++ b/dlls/shdoclc/Fi.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT diff --git a/dlls/shdoclc/Fr.rc b/dlls/shdoclc/Fr.rc index 9277938bb45..75aefc7a1f2 100644 --- a/dlls/shdoclc/Fr.rc +++ b/dlls/shdoclc/Fr.rc @@ -19,10 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" - -/* UTF-8 */ -#pragma code_page(65001) LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL @@ -39,74 +35,74 @@ STRINGTABLE DISCARDABLE IDR_BROWSE_CONTEXT_MENU MENU { - POPUP "Standard" + POPUP "Default" { - MENUITEM "Page &précédente", IDM_GOBACKWARD - MENUITEM "Page &suivante", IDM_GOFORWARD + MENUITEM "Page pré&cédente", IDM_GOBACKWARD + MENUITEM "Page sui&vante", IDM_GOFORWARD MENUITEM SEPARATOR - MENUITEM "Enregistrer l'&arrière-plan sous...", IDM_SAVEBACKGROUND - MENUITEM "Définir &comme arrière-plan", IDM_SETWALLPAPER - MENUITEM "&Copier l'arrière-plan", IDM_COPYBACKGROUND - MENUITEM "Définir comme élément du &Bureau...", IDM_SETDESKTOPITEM + MENUITEM "Enregistrer l'&arrière-plan sous...", IDM_SAVEBACKGROUND + MENUITEM "Ét&ablir en tant qu'élément d'arrière-plan", IDM_SETWALLPAPER + MENUITEM "Copie&r l'arrière-plan", IDM_COPYBACKGROUND + MENUITEM "Définir comme élément du &Bureau...", IDM_SETDESKTOPITEM MENUITEM SEPARATOR - MENUITEM "Sélectionner &tout", IDM_SELECTALL + MENUITEM "&Sélectionner tout", IDM_SELECTALL MENUITEM "C&oller", IDM_PASTE MENUITEM SEPARATOR - MENUITEM "Créer un &raccourci", IDM_CREATESHORTCUT - MENUITEM "Ajouter aux &Favoris...", IDM_ADDFAVORITES - MENUITEM "Afficher la &source", IDM_VIEWSOURCE + MENUITEM "Créer &un raccourci", IDM_CREATESHORTCUT + MENUITEM "Ajouter au&x Favoris...", IDM_ADDFAVORITES + MENUITEM "A&fficher la source", IDM_VIEWSOURCE MENUITEM SEPARATOR - MENUITEM "Coda&ge", IDM_LANGUAGE + MENUITEM "Co&dage", IDM_LANGUAGE MENUITEM SEPARATOR MENUITEM "&Imprimer", IDM_PRINT MENUITEM "Actualis&er", _IDM_REFRESH MENUITEM SEPARATOR MENUITEM SEPARATOR - MENUITEM "Propri&étés", IDM_PROPERTIES + MENUITEM "&Propriétés", IDM_PROPERTIES } POPUP "Image" { MENUITEM "Ou&vrir le lien", IDM_FOLLOWLINKC - MENUITEM "Ouvrir le lien dans une &nouvelle fenêtre", IDM_FOLLOWLINKN + MENUITEM "Ouvrir le lien dans une &nouvelle fenêtre", IDM_FOLLOWLINKN MENUITEM "Enregistrer la cible so&us...", IDM_SAVETARGET MENUITEM "Imprimer la cib&le", IDM_PRINTTARGET MENUITEM SEPARATOR MENUITEM "Affic&her l'image", IDM_SHOWPICTURE MENUITEM "Enregistrer l'image &sous...", IDM_SAVEPICTURE - MENUITEM "Envoyer l'image par &courrier électronique...", IDM_MP_EMAILPICTURE + MENUITEM "Envoyer l'image par &courrier électronique...", IDM_MP_EMAILPICTURE MENUITEM "&Imprimer l'image...", IDM_MP_PRINTPICTURE MENUITEM "Atteindre &Mes images", IDM_MP_MYPICS - MENUITEM "Déf&inir comme arrière-plan", IDM_SETWALLPAPER - MENUITEM "Définir comme élément du &Bureau...", IDM_SETDESKTOPITEM + MENUITEM "É&tablir en tant qu'élément d'arrière-plan", IDM_SETWALLPAPER + MENUITEM "Définir comme élément du &Bureau...", IDM_SETDESKTOPITEM MENUITEM SEPARATOR - MENUITEM "Cou&per", IDM_CUT - MENUITEM "&Copier", IDM_COPY + MENUITEM "Coupe&r", IDM_CUT + MENUITEM "Copi&er", IDM_COPY MENUITEM "Copier le r&accourci", IDM_COPYSHORTCUT MENUITEM "C&oller", IDM_PASTE MENUITEM SEPARATOR - MENUITEM "Ajouter aux &Favoris...", IDM_ADDFAVORITES + MENUITEM "Ajouter au&x Favoris...", IDM_ADDFAVORITES MENUITEM SEPARATOR MENUITEM SEPARATOR - MENUITEM "Propri&étés", IDM_PROPERTIES + MENUITEM "&Propriétés", IDM_PROPERTIES } - POPUP "Contrôle" + POPUP "Control" { MENUITEM "&Annuler", IDM_UNDO MENUITEM SEPARATOR - MENUITEM "Cou&per", IDM_CUT - MENUITEM "&Copier", IDM_COPY + MENUITEM "Coupe&r", IDM_CUT + MENUITEM "Copi&er", IDM_COPY MENUITEM "C&oller", IDM_PASTE MENUITEM "Suppri&mer", IDM_DELETE MENUITEM SEPARATOR MENUITEM SEPARATOR - MENUITEM "&Sélectionner tout", IDM_SELECTALL + MENUITEM "&Sélectionner tout", IDM_SELECTALL } POPUP "Table" { - POPUP "&Sélectionner" + POPUP "&Sélectionner" { MENUITEM "&cellule", IDM_CELLSELECT MENUITEM "&ligne", IDM_ROWSELECT @@ -115,96 +111,96 @@ IDR_BROWSE_CONTEXT_MENU MENU } MENUITEM SEPARATOR MENUITEM SEPARATOR - MENUITEM "Propriétés de la &cellule", IDM_CELLPROPERTIES - MENUITEM "Propriétés de la &table", IDM_TABLEPROPERTIES + MENUITEM "Propriétés de la &cellule", IDM_CELLPROPERTIES + MENUITEM "Propriétés de la &table", IDM_TABLEPROPERTIES } POPUP "1DSite Select" { - MENUITEM "Cou&per", IDM_CUT - MENUITEM "&Copier", IDM_COPY - MENUITEM "C&oller", IDM_PASTE - MENUITEM "Sélectionner &tout", IDM_SELECTALL + MENUITEM "Coupe&r", IDM_CUT + MENUITEM "Copi&er", IDM_COPY + MENUITEM "Coller", IDM_PASTE + MENUITEM "&Sélectionner tout", IDM_SELECTALL MENUITEM "&Imprimer", IDM_PRINT MENUITEM SEPARATOR } - POPUP "Ancre" + POPUP "Anchor" { MENUITEM "Ou&vrir", IDM_FOLLOWLINKC - MENUITEM "Ouvrir dans une &nouvelle fenêtre", IDM_FOLLOWLINKN - MENUITEM "Enregistrer la cible &sous...", IDM_SAVETARGET - MENUITEM "&Imprimer la cible", IDM_PRINTTARGET + MENUITEM "Ouvrir dans une &nouvelle fenêtre", IDM_FOLLOWLINKN + MENUITEM "Enregistrer la cible so&us...", IDM_SAVETARGET + MENUITEM "Imprimer la cib&le", IDM_PRINTTARGET MENUITEM SEPARATOR - MENUITEM "Cou&per", IDM_CUT - MENUITEM "&Copier", IDM_COPY - MENUITEM "Copier le &raccourci", IDM_COPYSHORTCUT + MENUITEM "Coupe&r", IDM_CUT + MENUITEM "Copi&er", IDM_COPY + MENUITEM "Copier le r&accourci", IDM_COPYSHORTCUT MENUITEM "C&oller", IDM_PASTE MENUITEM SEPARATOR - MENUITEM "Ajouter aux &Favoris...", IDM_ADDFAVORITES + MENUITEM "Ajouter au&x Favoris...", IDM_ADDFAVORITES MENUITEM SEPARATOR MENUITEM SEPARATOR - MENUITEM "Propri&étés", IDM_PROPERTIES + MENUITEM "&Propriétés", IDM_PROPERTIES } - POPUP "Contexte inconnu" + POPUP "Context Unknown" { MENUITEM SEPARATOR } - POPUP "Image DYNSRC" + POPUP "DYNSRC Image" { MENUITEM "Ou&vrir le lien", IDM_FOLLOWLINKC - MENUITEM "Ouvrir le lien dans une &nouvelle fenêtre", IDM_FOLLOWLINKN + MENUITEM "Ouvrir le lien dans une &nouvelle fenêtre", IDM_FOLLOWLINKN MENUITEM "Enregistrer la cible so&us...", IDM_SAVETARGET - MENUITEM "&Imprimer la cible", IDM_PRINTTARGET + MENUITEM "Imprimer la cib&le", IDM_PRINTTARGET MENUITEM SEPARATOR MENUITEM "Affic&her l'image", IDM_SHOWPICTURE - MENUITEM "Enregistrer la vidéo &sous...", IDM_SAVEPICTURE - MENUITEM "&Définir comme arrière-plan", IDM_SETWALLPAPER - MENUITEM "Définir comme élément du &Bureau...", IDM_SETDESKTOPITEM + MENUITEM "Enregistrer la vidéo &sous...", IDM_SAVEPICTURE + MENUITEM "É&tablir en tant qu'élément d'arrière-plan", IDM_SETWALLPAPER + MENUITEM "Définir comme élément du &Bureau...", IDM_SETDESKTOPITEM MENUITEM SEPARATOR - MENUITEM "Cou&per", IDM_CUT - MENUITEM "&Copier", IDM_COPY - MENUITEM "Copier le &raccourci", IDM_COPYSHORTCUT + MENUITEM "Coupe&r", IDM_CUT + MENUITEM "Copi&er", IDM_COPY + MENUITEM "Copier le r&accourci", IDM_COPYSHORTCUT MENUITEM "C&oller", IDM_PASTE MENUITEM SEPARATOR - MENUITEM "Ajouter aux &Favoris...", IDM_ADDFAVORITES + MENUITEM "Ajouter au&x Favoris...", IDM_ADDFAVORITES MENUITEM SEPARATOR MENUITEM SEPARATOR MENUITEM "Lecture", IDM_DYNSRCPLAY - MENUITEM "Arrêt", IDM_DYNSRCSTOP - MENUITEM "Propri&étés", IDM_PROPERTIES + MENUITEM "Arrêt", IDM_DYNSRCSTOP + MENUITEM "&Propriétés", IDM_PROPERTIES } - POPUP "Image ART" + POPUP "ART Image" { MENUITEM "Ou&vrir le lien", IDM_FOLLOWLINKC - MENUITEM "Ouvrir le lien dans une &nouvelle fenêtre", IDM_FOLLOWLINKN + MENUITEM "Ouvrir le lien dans une &nouvelle fenêtre", IDM_FOLLOWLINKN MENUITEM "Enregistrer la cible so&us...", IDM_SAVETARGET MENUITEM "Imprimer la cib&le", IDM_PRINTTARGET MENUITEM SEPARATOR MENUITEM "Affic&her l'image", IDM_SHOWPICTURE MENUITEM "Enregistrer l'image &sous...", IDM_SAVEPICTURE - MENUITEM "&Définir comme arrière-plan", IDM_SETWALLPAPER - MENUITEM "Définir comme élément du &Bureau...", IDM_SETDESKTOPITEM + MENUITEM "É&tablir en tant qu'élément d'arrière-plan", IDM_SETWALLPAPER + MENUITEM "Définir comme élément du &Bureau...", IDM_SETDESKTOPITEM MENUITEM SEPARATOR - MENUITEM "Cou&per", IDM_CUT - MENUITEM "&Copier", IDM_COPY - MENUITEM "Copier le &raccourci", IDM_COPYSHORTCUT + MENUITEM "Coupe&r", IDM_CUT + MENUITEM "Copi&er", IDM_COPY + MENUITEM "Copier le r&accourci", IDM_COPYSHORTCUT MENUITEM "C&oller", IDM_PASTE MENUITEM SEPARATOR - MENUITEM "Ajouter aux &Favoris...", IDM_ADDFAVORITES + MENUITEM "Ajouter au&x Favoris...", IDM_ADDFAVORITES MENUITEM SEPARATOR MENUITEM "Lecture", IDM_IMGARTPLAY - MENUITEM "Arrêt", IDM_IMGARTSTOP - MENUITEM "Retour arrière", IDM_IMGARTREWIND + MENUITEM "Arrêt", IDM_IMGARTSTOP + MENUITEM "Retour arrière", IDM_IMGARTREWIND MENUITEM SEPARATOR MENUITEM SEPARATOR - MENUITEM "Propri&étés", IDM_PROPERTIES + MENUITEM "&Propriétés", IDM_PROPERTIES } - POPUP "Déboguage" + POPUP "Debug" { MENUITEM "Trace Tags", IDM_TRACETAGS MENUITEM "Resource Failures", IDM_RESOURCEFAILURES @@ -224,31 +220,31 @@ IDR_BROWSE_CONTEXT_MENU MENU MENUITEM "&Edit View", IDM_EDITMODE } - POPUP "Barre de défilement verticale" + POPUP "Vertical Scrollbar" { - MENUITEM "Défilement ici", IDM_SCROLL_HERE + MENUITEM "Défilement ici", IDM_SCROLL_HERE MENUITEM SEPARATOR MENUITEM "Haut", IDM_SCROLL_TOP MENUITEM "Bas", IDM_SCROLL_BOTTOM MENUITEM SEPARATOR - MENUITEM "Page précédente", IDM_SCROLL_PAGEUP + MENUITEM "Page précédente", IDM_SCROLL_PAGEUP MENUITEM "Page suivante", IDM_SCROLL_PAGEDOWN MENUITEM SEPARATOR - MENUITEM "Défilement vers le haut", IDM_SCROLL_UP - MENUITEM "Défilement vers le bas", IDM_SCROLL_DOWN + MENUITEM "Défilement vers le haut", IDM_SCROLL_UP + MENUITEM "Défilement vers le bas", IDM_SCROLL_DOWN } - POPUP "Barre de défilement horizontale" + POPUP "Horizontal Scrollbar" { - MENUITEM "Défilement ici", IDM_SCROLL_HERE + MENUITEM "Défilement ici", IDM_SCROLL_HERE MENUITEM SEPARATOR - MENUITEM "Bord gauche", IDM_SCROLL_LEFTEDGE - MENUITEM "Bord droit", IDM_SCROLL_RIGHTEDGE + MENUITEM "Côté gauche", IDM_SCROLL_LEFTEDGE + MENUITEM "Côté droit", IDM_SCROLL_RIGHTEDGE MENUITEM SEPARATOR MENUITEM "Page vers la gauche", IDM_SCROLL_PAGELEFT MENUITEM "Page vers la droite", IDM_SCROLL_PAGERIGHT MENUITEM SEPARATOR - MENUITEM "Défilement vers la gauche", IDM_SCROLL_LEFT - MENUITEM "Défilement vers la droite", IDM_SCROLL_RIGHT + MENUITEM "Défilement vers la gauche", IDM_SCROLL_LEFT + MENUITEM "Défilement vers la droite", IDM_SCROLL_RIGHT } } diff --git a/dlls/shdoclc/Hu.rc b/dlls/shdoclc/Hu.rc index 2fdc4c202ef..9ed68caceda 100644 --- a/dlls/shdoclc/Hu.rc +++ b/dlls/shdoclc/Hu.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT diff --git a/dlls/shdoclc/Ko.rc b/dlls/shdoclc/Ko.rc index 6bf28d19890..d038994151b 100644 --- a/dlls/shdoclc/Ko.rc +++ b/dlls/shdoclc/Ko.rc @@ -17,7 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT diff --git a/dlls/shdoclc/Lt.rc b/dlls/shdoclc/Lt.rc deleted file mode 100644 index e6c812d3bfe..00000000000 --- a/dlls/shdoclc/Lt.rc +++ /dev/null @@ -1,251 +0,0 @@ -/* - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "shdoclc.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - IDS_MESSAGE_BOX_TITLE, "Wine interneto naršyklė" -} - -STRINGTABLE DISCARDABLE -{ - IDS_PRINT_HEADER_TEMPLATE "&w&bPuslapis &p" /* FIXME: should be "&w&bPuslapis &p iš &P" */ - IDS_PRINT_FOOTER_TEMPLATE "&u&b&d" -} - -IDR_BROWSE_CONTEXT_MENU MENU -{ - POPUP "Numatytasis" - { - MENUITEM "&Atgal", IDM_GOBACKWARD - MENUITEM "&Pirmyn", IDM_GOFORWARD - MENUITEM SEPARATOR - MENUITEM "&Išsaugoti foną kaip...", IDM_SAVEBACKGROUND - MENUITEM "Parinkti užsk&landos piešiniu", IDM_SETWALLPAPER - MENUITEM "Kopijuoti &foną", IDM_COPYBACKGROUND - MENUITEM "Nustatyti da&rbalaukio elementu", IDM_SETDESKTOPITEM - MENUITEM SEPARATOR - MENUITEM "Pažymėti &viską", IDM_SELECTALL - MENUITEM "Į&dėti", IDM_PASTE - MENUITEM SEPARATOR - MENUITEM "Sukurti &šaukinį", IDM_CREATESHORTCUT - MENUITEM "Pridėti į adr&esyną", IDM_ADDFAVORITES - MENUITEM "Pirminis &tekstas", IDM_VIEWSOURCE - MENUITEM SEPARATOR - MENUITEM "&Koduotė", IDM_LANGUAGE - MENUITEM SEPARATOR - MENUITEM "&Spausdinti", IDM_PRINT - MENUITEM "Atsiųsti iš &naujo", _IDM_REFRESH - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "Savy&bės", IDM_PROPERTIES - } - - POPUP "Paveikslas" - { - MENUITEM "&Atverti saitą", IDM_FOLLOWLINKC - MENUITEM "Atverti saitą &naujame lange", IDM_FOLLOWLINKN - MENUITEM "Įrašyti saistomą &objektą kaip...", IDM_SAVETARGET - MENUITEM "&Spausdinti saistomą objektą", IDM_PRINTTARGET - MENUITEM SEPARATOR - MENUITEM "Rod&yti paveikslą", IDM_SHOWPICTURE - MENUITEM "Įrašyti pa&veikslą kaip...", IDM_SAVEPICTURE - MENUITEM "Išsiųsti pav&eikslą el. paštu...", IDM_MP_EMAILPICTURE - MENUITEM "S&pausdinti paveikslą...", IDM_MP_PRINTPICTURE - MENUITEM "Ei&ti į paveikslų aplanką", IDM_MP_MYPICS - MENUITEM "Parinkti užsk&landos piešiniu", IDM_SETWALLPAPER - MENUITEM "Nustatyti da&rbalaukio elementu...", IDM_SETDESKTOPITEM - MENUITEM SEPARATOR - MENUITEM "&Iškirpti", IDM_CUT - MENUITEM "&Kopijuoti", IDM_COPY - MENUITEM "Kopi&juoti adresą", IDM_COPYSHORTCUT - MENUITEM "Į&dėti", IDM_PASTE - MENUITEM SEPARATOR - MENUITEM "Prid&ėti į adresyną...", IDM_ADDFAVORITES - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "Savy&bės", IDM_PROPERTIES - } - - POPUP "Valdiklis" - { - MENUITEM "&Atšaukti", IDM_UNDO - MENUITEM SEPARATOR - MENUITEM "&Iškirpti", IDM_CUT - MENUITEM "&Kopijuoti", IDM_COPY - MENUITEM "Į&dėti", IDM_PASTE - MENUITEM "&Šalinti", IDM_DELETE - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "Pažymėti &viską", IDM_SELECTALL - } - - POPUP "Lentelė" - { - POPUP "&Pažymėti" - { - MENUITEM "lan&gelį", IDM_CELLSELECT - MENUITEM "&eilutę", IDM_ROWSELECT - MENUITEM "&stulpelį", IDM_COLUMNSELECT - MENUITEM "&lentelę", IDM_TABLESELECT - } - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "Lan&gelio savybės", IDM_CELLPROPERTIES - MENUITEM "&Lentelės savybės", IDM_TABLEPROPERTIES - } - - POPUP "1DPuslapio žymėjimas" - { - MENUITEM "&Iškirpti", IDM_CUT - MENUITEM "&Kopijuoti", IDM_COPY - MENUITEM "Į&dėti", IDM_PASTE - MENUITEM "Pažymėti &viską", IDM_SELECTALL - MENUITEM "&Spausdinti", IDM_PRINT - MENUITEM SEPARATOR - } - - POPUP "Žymė" - { - MENUITEM "&Atverti", IDM_FOLLOWLINKC - MENUITEM "Atverti &naujame lange", IDM_FOLLOWLINKN - MENUITEM "Įrašyti saistomą &objektą kaip...", IDM_SAVETARGET - MENUITEM "&Spausdinti saistomą objektą", IDM_PRINTTARGET - MENUITEM SEPARATOR - MENUITEM "&Iškirpti", IDM_CUT - MENUITEM "&Kopijuoti", IDM_COPY - MENUITEM "Kopi&juoti adresą", IDM_COPYSHORTCUT - MENUITEM "Į&dėti", IDM_PASTE - MENUITEM SEPARATOR - MENUITEM "Pridėti į adr&esyną...", IDM_ADDFAVORITES - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "Savy&bės", IDM_PROPERTIES - } - - POPUP "Nežinomas kontekstas" - { - MENUITEM SEPARATOR - } - - POPUP "DYNSRC paveikslas" - { - MENUITEM "&Atverti saitą", IDM_FOLLOWLINKC - MENUITEM "Atverti saitą &naujame lange", IDM_FOLLOWLINKN - MENUITEM "Įrašyti saistomą &objektą kaip...", IDM_SAVETARGET - MENUITEM "&Spausdinti saistomą objektą", IDM_PRINTTARGET - MENUITEM SEPARATOR - MENUITEM "Rod&yti paveikslą", IDM_SHOWPICTURE - MENUITEM "Įrašyti pa&veikslą kaip...", IDM_SAVEPICTURE - MENUITEM "Parinkti užsk&landos piešiniu", IDM_SETWALLPAPER - MENUITEM "Nustatyti da&rbalaukio elementu...", IDM_SETDESKTOPITEM - MENUITEM SEPARATOR - MENUITEM "&Iškirpti", IDM_CUT - MENUITEM "&Kopijuoti", IDM_COPY - MENUITEM "Kopi&juoti adresą", IDM_COPYSHORTCUT - MENUITEM "Į&dėti", IDM_PASTE - MENUITEM SEPARATOR - MENUITEM "Pridėti į adr&esyną...", IDM_ADDFAVORITES - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "Leisti", IDM_DYNSRCPLAY - MENUITEM "Stabdyti", IDM_DYNSRCSTOP - MENUITEM "Savy&bės", IDM_PROPERTIES - } - - POPUP "ART paveikslas" - { - MENUITEM "&Atverti saitą", IDM_FOLLOWLINKC - MENUITEM "Atverti saitą &naujame lange", IDM_FOLLOWLINKN - MENUITEM "Įrašyti saistomą &objektą kaip...", IDM_SAVETARGET - MENUITEM "&Spausdinti saistomą objektą", IDM_PRINTTARGET - MENUITEM SEPARATOR - MENUITEM "Rod&yti paveikslą", IDM_SHOWPICTURE - MENUITEM "Įrašyti pa&veikslą kaip...", IDM_SAVEPICTURE - MENUITEM "Parinkti užsk&landos piešiniu", IDM_SETWALLPAPER - MENUITEM "Nustatyti da&rbalaukio elementu...", IDM_SETDESKTOPITEM - MENUITEM SEPARATOR - MENUITEM "&Iškirpti", IDM_CUT - MENUITEM "&Kopijuoti", IDM_COPY - MENUITEM "Kopi&juoti adresą", IDM_COPYSHORTCUT - MENUITEM "Į&dėti", IDM_PASTE - MENUITEM SEPARATOR - MENUITEM "Pridėti į adr&esyną...", IDM_ADDFAVORITES - MENUITEM SEPARATOR - MENUITEM "Leisti", IDM_IMGARTPLAY - MENUITEM "Stabdyti", IDM_IMGARTSTOP - MENUITEM "Perleisti", IDM_IMGARTREWIND - MENUITEM SEPARATOR - MENUITEM SEPARATOR - MENUITEM "Savy&bės", IDM_PROPERTIES - } - - POPUP "Derinimas" - { - MENUITEM "Sekti gaires", IDM_TRACETAGS - MENUITEM "Išteklių klaidos", IDM_RESOURCEFAILURES - MENUITEM "Parodyti stebėjimo informaciją", IDM_DUMPTRACKINGINFO - MENUITEM "Derinimo pertraukimas", IDM_DEBUGBREAK - MENUITEM "Derinimo rodinys", IDM_DEBUGVIEW - MENUITEM "Parodyti medį", IDM_DUMPTREE - MENUITEM "Parodyti eilutes", IDM_DUMPLINES - MENUITEM "Parodyti rodymo medį", IDM_DUMPDISPLAYTREE - MENUITEM "Parodyti formatų podėlius", IDM_DUMPFORMATCACHES - MENUITEM "Parodyti išdėstymo stačiakampius", IDM_DUMPLAYOUTRECTS - MENUITEM "Atminties monitorius", IDM_MEMORYMONITOR - MENUITEM "Našumo skaitikliai", IDM_PERFORMANCEMETERS - MENUITEM "Išsaugoti HTML", IDM_SAVEHTML - MENUITEM SEPARATOR - MENUITEM "&Naršyti rodinį", IDM_BROWSEMODE - MENUITEM "&Redaguoti rodinį", IDM_EDITMODE - } - - POPUP "Stačioji slankjuostė" - { - MENUITEM "Slinkti čia", IDM_SCROLL_HERE - MENUITEM SEPARATOR - MENUITEM "Viršus", IDM_SCROLL_TOP - MENUITEM "Apačia", IDM_SCROLL_BOTTOM - MENUITEM SEPARATOR - MENUITEM "Ankstesnis lapas", IDM_SCROLL_PAGEUP - MENUITEM "Tolesnis lapas", IDM_SCROLL_PAGEDOWN - MENUITEM SEPARATOR - MENUITEM "Slinkti aukštyn", IDM_SCROLL_UP - MENUITEM "Slinkti žemyn", IDM_SCROLL_DOWN - } - - POPUP "Gulsčioji slankjuostė" - { - MENUITEM "Slinkti čia", IDM_SCROLL_HERE - MENUITEM SEPARATOR - MENUITEM "Kairysis kraštas", IDM_SCROLL_LEFTEDGE - MENUITEM "Dešinysis kraštas", IDM_SCROLL_RIGHTEDGE - MENUITEM SEPARATOR - MENUITEM "Kairysis lapas", IDM_SCROLL_PAGELEFT - MENUITEM "Dešinysis lapas", IDM_SCROLL_PAGERIGHT - MENUITEM SEPARATOR - MENUITEM "Slinkti kairėn", IDM_SCROLL_LEFT - MENUITEM "Slinkti dešinėn", IDM_SCROLL_RIGHT - } -} diff --git a/dlls/shdoclc/Makefile.in b/dlls/shdoclc/Makefile.in index d053a9d83e1..4045ecf4f40 100644 --- a/dlls/shdoclc/Makefile.in +++ b/dlls/shdoclc/Makefile.in @@ -5,25 +5,7 @@ VPATH = @srcdir@ MODULE = shdoclc.dll IMPORTS = kernel32 -RC_SRCS = \ - Bg.rc \ - Da.rc \ - De.rc \ - En.rc \ - Es.rc \ - Fi.rc \ - Fr.rc \ - Hu.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pt.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc +RC_SRCS = rsrc.rc @MAKE_DLL_RULES@ diff --git a/dlls/shdoclc/Nl.rc b/dlls/shdoclc/Nl.rc index c10e8031fdb..3f764753871 100644 --- a/dlls/shdoclc/Nl.rc +++ b/dlls/shdoclc/Nl.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL diff --git a/dlls/shdoclc/No.rc b/dlls/shdoclc/No.rc index 65f554a5777..6c38a1f61c0 100644 --- a/dlls/shdoclc/No.rc +++ b/dlls/shdoclc/No.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL diff --git a/dlls/shdoclc/Pt.rc b/dlls/shdoclc/Pt.rc index 737747304ff..393037f5f8a 100644 --- a/dlls/shdoclc/Pt.rc +++ b/dlls/shdoclc/Pt.rc @@ -16,15 +16,12 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE +LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { - IDS_MESSAGE_BOX_TITLE, "Explorador de Internet Wine" + IDS_MESSAGE_BOX_TITLE, "Wine Internet Explorer" } STRINGTABLE DISCARDABLE @@ -38,7 +35,7 @@ IDR_BROWSE_CONTEXT_MENU MENU POPUP "Default" { MENUITEM "&Retroceder", IDM_GOBACKWARD - MENUITEM "&Avançar", IDM_GOFORWARD + MENUITEM "&Avançar", IDM_GOFORWARD MENUITEM SEPARATOR MENUITEM "&Guardar fundo como...", IDM_SAVEBACKGROUND MENUITEM "&Definir como fundo", IDM_SETWALLPAPER @@ -50,9 +47,9 @@ IDR_BROWSE_CONTEXT_MENU MENU MENUITEM SEPARATOR MENUITEM "Criar &Atalho", IDM_CREATESHORTCUT MENUITEM "Adicionar aos &Favoritos", IDM_ADDFAVORITES - MENUITEM "&Ver Código Fonte", IDM_VIEWSOURCE + MENUITEM "&Ver Código Fonte", IDM_VIEWSOURCE MENUITEM SEPARATOR - MENUITEM "C&odificação", IDM_LANGUAGE + MENUITEM "C&odificação", IDM_LANGUAGE MENUITEM SEPARATOR MENUITEM "&Imprimir", IDM_PRINT MENUITEM "&Actualizar", _IDM_REFRESH @@ -63,10 +60,10 @@ IDR_BROWSE_CONTEXT_MENU MENU POPUP "Imagem" { - MENUITEM "&Abrir ligação", IDM_FOLLOWLINKC - MENUITEM "Abrir &ligação numa nova janela", IDM_FOLLOWLINKN - MENUITEM "&Guardar ligação como...", IDM_SAVETARGET - MENUITEM "&Imprimir ligação", IDM_PRINTTARGET + MENUITEM "&Abrir ligação", IDM_FOLLOWLINKC + MENUITEM "Abrir &ligação numa nova janela", IDM_FOLLOWLINKN + MENUITEM "&Guardar ligação como...", IDM_SAVETARGET + MENUITEM "&Imprimir ligação", IDM_PRINTTARGET MENUITEM SEPARATOR MENUITEM "&Mostrar imagem", IDM_SHOWPICTURE MENUITEM "G&uardar imagem como...", IDM_SAVEPICTURE @@ -104,14 +101,14 @@ IDR_BROWSE_CONTEXT_MENU MENU { POPUP "&Seleccionar" { - MENUITEM "&Célula", IDM_CELLSELECT + MENUITEM "&Célula", IDM_CELLSELECT MENUITEM "&Linha", IDM_ROWSELECT MENUITEM "C&oluna", IDM_COLUMNSELECT MENUITEM "&Tabela", IDM_TABLESELECT } MENUITEM SEPARATOR MENUITEM SEPARATOR - MENUITEM "&Propriedades da Célula", IDM_CELLPROPERTIES + MENUITEM "&Propriedades da Célula", IDM_CELLPROPERTIES MENUITEM "&Propriedades da Tabela", IDM_TABLEPROPERTIES } @@ -125,12 +122,12 @@ IDR_BROWSE_CONTEXT_MENU MENU MENUITEM SEPARATOR } - POPUP "Âncora" + POPUP "Âncora" { MENUITEM "&Abrir", IDM_FOLLOWLINKC MENUITEM "A&brir numa nova janela", IDM_FOLLOWLINKN - MENUITEM "&Guardar ligação como...", IDM_SAVETARGET - MENUITEM "&Imprimir ligação", IDM_PRINTTARGET + MENUITEM "&Guardar ligação como...", IDM_SAVETARGET + MENUITEM "&Imprimir ligação", IDM_PRINTTARGET MENUITEM SEPARATOR MENUITEM "&Cortar", IDM_CUT MENUITEM "C&opiar", IDM_COPY @@ -150,10 +147,10 @@ IDR_BROWSE_CONTEXT_MENU MENU POPUP "Imagem DYNSRC" { - MENUITEM "&Abrir ligação", IDM_FOLLOWLINKC - MENUITEM "A&brir ligação numa nova janela", IDM_FOLLOWLINKN - MENUITEM "&Guardar ligação como...", IDM_SAVETARGET - MENUITEM "&Imprimir ligação", IDM_PRINTTARGET + MENUITEM "&Abrir ligação", IDM_FOLLOWLINKC + MENUITEM "A&brir ligação numa nova janela", IDM_FOLLOWLINKN + MENUITEM "&Guardar ligação como...", IDM_SAVETARGET + MENUITEM "&Imprimir ligação", IDM_PRINTTARGET MENUITEM SEPARATOR MENUITEM "&Mostrar imagem", IDM_SHOWPICTURE MENUITEM "G&uardar video como...", IDM_SAVEPICTURE @@ -175,10 +172,10 @@ IDR_BROWSE_CONTEXT_MENU MENU POPUP "Imagem ART" { - MENUITEM "&Abrir ligação", IDM_FOLLOWLINKC - MENUITEM "A&brir ligação numa nova janela", IDM_FOLLOWLINKN - MENUITEM "&Guardar ligação como...", IDM_SAVETARGET - MENUITEM "&Imprimir ligação", IDM_PRINTTARGET + MENUITEM "&Abrir ligação", IDM_FOLLOWLINKC + MENUITEM "A&brir ligação numa nova janela", IDM_FOLLOWLINKN + MENUITEM "&Guardar ligação como...", IDM_SAVETARGET + MENUITEM "&Imprimir ligação", IDM_PRINTTARGET MENUITEM SEPARATOR MENUITEM "&Mostrar imagem", IDM_SHOWPICTURE MENUITEM "G&uardar video como...", IDM_SAVEPICTURE @@ -192,9 +189,10 @@ IDR_BROWSE_CONTEXT_MENU MENU MENUITEM SEPARATOR MENUITEM "Adicionar aos &Favoritos...", IDM_ADDFAVORITES MENUITEM SEPARATOR - MENUITEM "I&niciar", IDM_IMGARTPLAY - MENUITEM "&Parar", IDM_IMGARTSTOP - MENUITEM "&Recomeçar", IDM_IMGARTREWIND + MENUITEM SEPARATOR + MENUITEM "I&niciar", IDM_DYNSRCPLAY + MENUITEM "&Parar", IDM_DYNSRCSTOP + MENUITEM "&Recomeçar", IDM_IMGARTREWIND MENUITEM SEPARATOR MENUITEM SEPARATOR MENUITEM "Propriedade&s", IDM_PROPERTIES @@ -227,8 +225,8 @@ IDR_BROWSE_CONTEXT_MENU MENU MENUITEM "Topo", IDM_SCROLL_TOP MENUITEM "Fundo", IDM_SCROLL_BOTTOM MENUITEM SEPARATOR - MENUITEM "Página Acima", IDM_SCROLL_PAGEUP - MENUITEM "Página abaixo", IDM_SCROLL_PAGEDOWN + MENUITEM "Página Acima", IDM_SCROLL_PAGEUP + MENUITEM "Página abaixo", IDM_SCROLL_PAGEDOWN MENUITEM SEPARATOR MENUITEM "Scroll Cima", IDM_SCROLL_UP MENUITEM "Scroll Baixo", IDM_SCROLL_DOWN @@ -241,8 +239,8 @@ IDR_BROWSE_CONTEXT_MENU MENU MENUITEM "Canto Esquerdo", IDM_SCROLL_LEFTEDGE MENUITEM "Canto Direito", IDM_SCROLL_RIGHTEDGE MENUITEM SEPARATOR - MENUITEM "Página esquerda", IDM_SCROLL_PAGELEFT - MENUITEM "Página direita", IDM_SCROLL_PAGERIGHT + MENUITEM "Página esquerda", IDM_SCROLL_PAGELEFT + MENUITEM "Página direita", IDM_SCROLL_PAGERIGHT MENUITEM SEPARATOR MENUITEM "Scroll Esquerda", IDM_SCROLL_LEFT MENUITEM "Scroll Direita", IDM_SCROLL_RIGHT diff --git a/dlls/shdoclc/Ru.rc b/dlls/shdoclc/Ru.rc index 11db8729190..f20c2f469b3 100644 --- a/dlls/shdoclc/Ru.rc +++ b/dlls/shdoclc/Ru.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT diff --git a/dlls/shdoclc/Si.rc b/dlls/shdoclc/Si.rc index c95dc017089..ccc79002144 100644 --- a/dlls/shdoclc/Si.rc +++ b/dlls/shdoclc/Si.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -248,3 +247,5 @@ IDR_BROWSE_CONTEXT_MENU MENU MENUITEM "Drsenje desno", IDM_SCROLL_RIGHT } } + +#pragma code_page(default) diff --git a/dlls/shdoclc/Sv.rc b/dlls/shdoclc/Sv.rc index 277745d5630..9b20705b3d4 100644 --- a/dlls/shdoclc/Sv.rc +++ b/dlls/shdoclc/Sv.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL diff --git a/dlls/shdoclc/Tr.rc b/dlls/shdoclc/Tr.rc index ea238e14bf8..8bd4ed07fa0 100644 --- a/dlls/shdoclc/Tr.rc +++ b/dlls/shdoclc/Tr.rc @@ -16,7 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT diff --git a/dlls/shdoclc/Zh.rc b/dlls/shdoclc/Zh.rc index c597676882c..f3570e840ce 100644 --- a/dlls/shdoclc/Zh.rc +++ b/dlls/shdoclc/Zh.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shdoclc.h" /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -480,3 +479,5 @@ IDR_BROWSE_CONTEXT_MENU MENU MENUITEM "向右滾動", IDM_SCROLL_RIGHT } } + +#pragma code_page(default) diff --git a/dlls/shdoclc/rsrc.rc b/dlls/shdoclc/rsrc.rc new file mode 100644 index 00000000000..847c2e120cd --- /dev/null +++ b/dlls/shdoclc/rsrc.rc @@ -0,0 +1,41 @@ +/* + * Copyright 2005 Jacek Caban + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winuser.h" +#include "mshtmcid.h" + +#include "shdoclc.h" + +#include "Bg.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Es.rc" +#include "Fi.rc" +#include "Fr.rc" +#include "Hu.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" diff --git a/dlls/shdoclc/shdoclc.h b/dlls/shdoclc/shdoclc.h index b5492d6243a..2bc7626990a 100644 --- a/dlls/shdoclc/shdoclc.h +++ b/dlls/shdoclc/shdoclc.h @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include - #define IDS_MESSAGE_BOX_TITLE 2213 #define IDS_PRINT_HEADER_TEMPLATE 8403 diff --git a/dlls/shdocvw/oleobject.c b/dlls/shdocvw/oleobject.c index 017e738e1ad..aab06d0194c 100644 --- a/dlls/shdocvw/oleobject.c +++ b/dlls/shdocvw/oleobject.c @@ -28,7 +28,6 @@ #include "shdocvw.h" #include "htiframe.h" #include "idispids.h" -#include "mshtmdid.h" WINE_DEFAULT_DEBUG_CHANNEL(shdocvw); @@ -724,8 +723,6 @@ static HRESULT WINAPI OleControl_OnAmbientPropertyChange(IOleControl *iface, DIS * BUT the Webbrowser OleControl object doesn't appear to do this. */ return S_OK; - case DISPID_AMBIENT_DLCONTROL: - return S_OK; case DISPID_AMBIENT_OFFLINEIFNOTCONNECTED: return on_offlineconnected_change(This); case DISPID_AMBIENT_SILENT: diff --git a/dlls/shdocvw/shdocvw.rc b/dlls/shdocvw/shdocvw.rc index bb4809b6e08..47718c16722 100644 --- a/dlls/shdocvw/shdocvw.rc +++ b/dlls/shdocvw/shdocvw.rc @@ -16,15 +16,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#define WINE_OLESELFREGISTER -#define WINE_FILEDESCRIPTION_STR "Wine core dll" -#define WINE_FILENAME_STR "shdocvw.dll" -#define WINE_FILEVERSION 6,0,2900,2180 -#define WINE_FILEVERSION_STR "6.0.2900.2180" -#define WINE_PRODUCTVERSION 6,0,2900,2180 -#define WINE_PRODUCTVERSION_STR "6.0.2900.2180" - -#include "wine/wine_common_ver.rc" +#include "version.rc" LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL diff --git a/dlls/shdocvw/version.rc b/dlls/shdocvw/version.rc new file mode 100644 index 00000000000..103b77cb4c3 --- /dev/null +++ b/dlls/shdocvw/version.rc @@ -0,0 +1,27 @@ +/* + * Copyright 2003 Francois Gouget (for CodeWeavers) + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#define WINE_OLESELFREGISTER +#define WINE_FILEDESCRIPTION_STR "Wine core dll" +#define WINE_FILENAME_STR "shdocvw.dll" +#define WINE_FILEVERSION 6,0,2900,2180 +#define WINE_FILEVERSION_STR "6.0.2900.2180" +#define WINE_PRODUCTVERSION 6,0,2900,2180 +#define WINE_PRODUCTVERSION_STR "6.0.2900.2180" + +#include "wine/wine_common_ver.rc" diff --git a/dlls/shell.dll16/Makefile.in b/dlls/shell.dll16/Makefile.in index afa7d8d1416..07cf620edca 100644 --- a/dlls/shell.dll16/Makefile.in +++ b/dlls/shell.dll16/Makefile.in @@ -8,6 +8,8 @@ IMPORTS = shell32 user32 advapi32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,shell32.dll EXTRARCFLAGS = -O res16 +SPEC_SRCS = shell.dll16.spec + C_SRCS = shell.c RC_SRCS = version.rc diff --git a/dlls/shell32/Makefile.in b/dlls/shell32/Makefile.in index 744c8dd1405..6900d312aba 100644 --- a/dlls/shell32/Makefile.in +++ b/dlls/shell32/Makefile.in @@ -17,8 +17,8 @@ C_SRCS = \ clipboard.c \ control.c \ cpanelfolder.c \ - dataobject.c \ dde.c \ + dataobject.c \ debughlp.c \ dialogs.c \ dragdrophelper.c \ @@ -54,37 +54,7 @@ C_SRCS = \ trash.c \ xdg.c -RC_SRCS = \ - shell32_Bg.rc \ - shell32_Ca.rc \ - shell32_Cs.rc \ - shell32_Da.rc \ - shell32_De.rc \ - shell32_En.rc \ - shell32_Eo.rc \ - shell32_Es.rc \ - shell32_Fi.rc \ - shell32_Fr.rc \ - shell32_Hu.rc \ - shell32_It.rc \ - shell32_Ja.rc \ - shell32_Ko.rc \ - shell32_Lt.rc \ - shell32_Nl.rc \ - shell32_No.rc \ - shell32_Pl.rc \ - shell32_Pt.rc \ - shell32_Ro.rc \ - shell32_Ru.rc \ - shell32_Si.rc \ - shell32_Sk.rc \ - shell32_Sv.rc \ - shell32_Tr.rc \ - shell32_Uk.rc \ - shell32_Wa.rc \ - shell32_Zh.rc \ - shres.rc \ - version.rc +RC_SRCS = shres.rc SVG_SRCS = \ desktop.svg \ diff --git a/dlls/shell32/control.c b/dlls/shell32/control.c index 9b566b65ed2..88d6ead0d03 100644 --- a/dlls/shell32/control.c +++ b/dlls/shell32/control.c @@ -59,7 +59,6 @@ CPlApplet* Control_UnloadApplet(CPlApplet* applet) if (applet->proc) applet->proc(applet->hWnd, CPL_EXIT, 0L, 0L); FreeLibrary(applet->hModule); next = applet->next; - HeapFree(GetProcessHeap(), 0, applet->cmd); HeapFree(GetProcessHeap(), 0, applet); return next; } @@ -96,13 +95,6 @@ CPlApplet* Control_LoadApplet(HWND hWnd, LPCWSTR cmd, CPanel* panel) applet = HeapReAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, applet, sizeof(*applet) + (applet->count - 1) * sizeof(NEWCPLINFOW)); - if (!(applet->cmd = HeapAlloc(GetProcessHeap(), 0, (lstrlenW(cmd)+1) * sizeof(WCHAR)))) { - WARN("Cannot allocate memory for applet path\n"); - goto theError; - } - - lstrcpyW(applet->cmd, cmd); - for (i = 0; i < applet->count; i++) { ZeroMemory(&newinfo, sizeof(newinfo)); newinfo.dwSize = sizeof(NEWCPLINFOA); @@ -434,20 +426,6 @@ static CPlItem* Control_GetCPlItem_From_ListView(CPanel *panel) return NULL; } -static void Control_StartApplet(HWND hWnd, CPlItem *item) -{ - WCHAR verbOpen[] = {'c','p','l','o','p','e','n',0}; - WCHAR format[] = {'@','%','d',0}; - WCHAR param[MAX_PATH]; - - /* execute the applet if item is valid */ - if (item) - { - wsprintfW(param, format, item->id); - ShellExecuteW(hWnd, verbOpen, item->applet->cmd, param, NULL, SW_SHOW); - } -} - static LRESULT WINAPI Control_WndProc(HWND hWnd, UINT wMsg, WPARAM lParam1, LPARAM lParam2) { @@ -506,7 +484,13 @@ static LRESULT WINAPI Control_WndProc(HWND hWnd, UINT wMsg, if ((LOWORD(lParam1) >= IDM_CPANEL_APPLET_BASE) && (LOWORD(lParam1) <= IDM_CPANEL_APPLET_BASE + panel->total_subprogs)) { - Control_StartApplet(hWnd, Control_GetCPlItem_From_MenuID(hWnd, LOWORD(lParam1))); + CPlItem *item = Control_GetCPlItem_From_MenuID(hWnd, LOWORD(lParam1)); + + /* execute the applet if item is valid */ + if (item) + item->applet->proc(item->applet->hWnd, CPL_DBLCLK, item->id, + item->applet->info[item->id].lData); + return 0; } @@ -527,7 +511,13 @@ static LRESULT WINAPI Control_WndProc(HWND hWnd, UINT wMsg, case NM_RETURN: case NM_DBLCLK: { - Control_StartApplet(hWnd, Control_GetCPlItem_From_ListView(panel)); + CPlItem *item = Control_GetCPlItem_From_ListView(panel); + + /* execute the applet if item is valid */ + if (item) + item->applet->proc(item->applet->hWnd, CPL_DBLCLK, + item->id, item->applet->info[item->id].lData); + return 0; } case LVN_ITEMCHANGED: @@ -782,11 +772,6 @@ static void Control_DoLaunch(CPanel* panel, HWND hWnd, LPCWSTR wszCmd) extraPmts = extraPmtsBuf; } - /* Now check if there had been a numerical value in the extra params */ - if ((extraPmts) && (*extraPmts == '@') && (sp == -1)) { - sp = atoiW(extraPmts + 1); - } - TRACE("cmd %s, extra %s, sp %d\n", debugstr_w(buffer), debugstr_w(extraPmts), sp); Control_LoadApplet(hWnd, buffer, panel); diff --git a/dlls/shell32/cpanel.h b/dlls/shell32/cpanel.h index 6a1fa574e78..23ec5e538f2 100644 --- a/dlls/shell32/cpanel.h +++ b/dlls/shell32/cpanel.h @@ -26,7 +26,6 @@ typedef struct CPlApplet { struct CPlApplet* next; /* linked list */ HWND hWnd; - LPWSTR cmd; /* path to applet */ unsigned count; /* number of subprograms */ HMODULE hModule; /* module of loaded applet */ APPLET_PROC proc; /* entry point address */ diff --git a/dlls/shell32/dialogs.c b/dlls/shell32/dialogs.c index 0d8dbaca72c..ac6bf211dcb 100644 --- a/dlls/shell32/dialogs.c +++ b/dlls/shell32/dialogs.c @@ -230,13 +230,13 @@ static INT_PTR CALLBACK RunDlgProc (HWND hwnd, UINT message, WPARAM wParam, LPAR else sei.lpDirectory = parent = RunDlg_GetParentDir(sei.lpFile); - if (!ShellExecuteExW( &sei )) - { + if (ShellExecuteExW( &sei ) < 33) + { HeapFree(GetProcessHeap(), 0, psz); HeapFree(GetProcessHeap(), 0, parent); SendMessageA (htxt, CB_SETEDITSEL, 0, MAKELPARAM (0, -1)) ; return TRUE ; - } + } /* FillList is still ANSI */ GetWindowTextA (htxt, (LPSTR)psz, ic + 1) ; @@ -244,7 +244,7 @@ static INT_PTR CALLBACK RunDlgProc (HWND hwnd, UINT message, WPARAM wParam, LPAR HeapFree(GetProcessHeap(), 0, psz); HeapFree(GetProcessHeap(), 0, parent); - EndDialog (hwnd, 0); + EndDialog (hwnd, 0) ; } } diff --git a/dlls/shell32/shell32.spec b/dlls/shell32/shell32.spec index 2eb5934a101..b50890b1a0e 100644 --- a/dlls/shell32/shell32.spec +++ b/dlls/shell32/shell32.spec @@ -210,7 +210,7 @@ 249 stdcall -noname PathParseIconLocation(ptr) PathParseIconLocationAW 250 stdcall -noname PathRemoveExtension(ptr) PathRemoveExtensionAW 251 stdcall -noname PathRemoveArgs(ptr) PathRemoveArgsAW - 256 stdcall SHCreateShellFolderView(ptr ptr) + 256 stdcall @(ptr ptr) SHELL32_256 258 stdcall -noname LinkWindow_RegisterClass() 259 stdcall -noname LinkWindow_UnregisterClass() #299 stub Shl1632_ThunkData32 @@ -251,7 +251,7 @@ 654 stdcall @(long long) shell32_654 # ReadCabinetState@8 660 stdcall -noname FileIconInit(long) - 680 stdcall IsUserAnAdmin() + 680 stdcall -noname IsUserAnAdmin() 704 stdcall -noname GUIDFromStringW(wstr ptr) diff --git a/dlls/shell32/shell32_Bg.rc b/dlls/shell32/shell32_Bg.rc index f38168cdb9b..8624231c6bc 100644 --- a/dlls/shell32/shell32_Bg.rc +++ b/dlls/shell32/shell32_Bg.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT MENU_001 MENU DISCARDABLE diff --git a/dlls/shell32/shell32_Ca.rc b/dlls/shell32/shell32_Ca.rc index 7a3a39754f1..44e4e05a8d9 100644 --- a/dlls/shell32/shell32_Ca.rc +++ b/dlls/shell32/shell32_Ca.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_CATALAN, SUBLANG_DEFAULT /* diff --git a/dlls/shell32/shell32_Cs.rc b/dlls/shell32/shell32_Cs.rc index 2bd50d01905..90b32ae408b 100644 --- a/dlls/shell32/shell32_Cs.rc +++ b/dlls/shell32/shell32_Cs.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/dlls/shell32/shell32_Da.rc b/dlls/shell32/shell32_Da.rc index 232d38781ef..49e7b2b2496 100644 --- a/dlls/shell32/shell32_Da.rc +++ b/dlls/shell32/shell32_Da.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT MENU_001 MENU DISCARDABLE diff --git a/dlls/shell32/shell32_De.rc b/dlls/shell32/shell32_De.rc index 828f56daa8e..051ca6b9014 100644 --- a/dlls/shell32/shell32_De.rc +++ b/dlls/shell32/shell32_De.rc @@ -17,15 +17,11 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL MENU_001 MENU DISCARDABLE BEGIN - MENUITEM "&Große Symbole", FCIDM_SHVIEW_BIGICON + MENUITEM "&Große Symbole", FCIDM_SHVIEW_BIGICON MENUITEM "&Kleine Symbole", FCIDM_SHVIEW_SMALLICON MENUITEM "&Liste", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Details", FCIDM_SHVIEW_REPORTVIEW @@ -40,7 +36,7 @@ BEGIN BEGIN POPUP "&Ansicht" BEGIN - MENUITEM "&Große Symbole", FCIDM_SHVIEW_BIGICON + MENUITEM "&Große Symbole", FCIDM_SHVIEW_BIGICON MENUITEM "&Kleine Symbole", FCIDM_SHVIEW_SMALLICON MENUITEM "&Liste", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Details", FCIDM_SHVIEW_REPORTVIEW @@ -50,7 +46,7 @@ BEGIN BEGIN MENUITEM "Nach &Name", 0x30 /* column 0 */ MENUITEM "Nach &Typ", 0x32 /* column 2 */ - MENUITEM "Nach &Größe", 0x31 /* ... */ + MENUITEM "Nach &Größe", 0x31 /* ... */ MENUITEM "Nach &Datum", 0x33 MENUITEM SEPARATOR MENUITEM "&Automatisch anordnen", FCIDM_SHVIEW_AUTOARRANGE @@ -59,13 +55,13 @@ BEGIN MENUITEM SEPARATOR MENUITEM "Aktualisieren", FCIDM_SHVIEW_REFRESH MENUITEM SEPARATOR - MENUITEM "Einfügen", FCIDM_SHVIEW_INSERT - MENUITEM "Einfügen als Verknüpfung", FCIDM_SHVIEW_INSERTLINK + MENUITEM "Einfügen", FCIDM_SHVIEW_INSERT + MENUITEM "Einfügen als Verknüpfung", FCIDM_SHVIEW_INSERTLINK MENUITEM SEPARATOR POPUP "Neu" BEGIN MENUITEM "Neues Ver&zeichnis", FCIDM_SHVIEW_NEWFOLDER - MENUITEM "Neue Ver&knüpfung", FCIDM_SHVIEW_NEWLINK + MENUITEM "Neue Ver&knüpfung", FCIDM_SHVIEW_NEWLINK MENUITEM SEPARATOR END MENUITEM SEPARATOR @@ -80,15 +76,15 @@ MENU_SHV_FILE MENU DISCARDABLE BEGIN POPUP "" BEGIN - MENUITEM "Aus&wählen" FCIDM_SHVIEW_OPEN + MENUITEM "Aus&wählen" FCIDM_SHVIEW_OPEN MENUITEM "E&rkunden", FCIDM_SHVIEW_EXPLORE - MENUITEM "&Öffnen" FCIDM_SHVIEW_OPEN + MENUITEM "&Öffnen" FCIDM_SHVIEW_OPEN MENUITEM SEPARATOR MENUITEM "&Ausschneiden", FCIDM_SHVIEW_CUT MENUITEM "&Kopieren", FCIDM_SHVIEW_COPY MENUITEM SEPARATOR - MENUITEM "&Verknüpfung erzeugen", FCIDM_SHVIEW_CREATELINK - MENUITEM "&Löschen", FCIDM_SHVIEW_DELETE + MENUITEM "&Verknüpfung erzeugen", FCIDM_SHVIEW_CREATELINK + MENUITEM "&Löschen", FCIDM_SHVIEW_DELETE MENUITEM "&Umbenennen", FCIDM_SHVIEW_RENAME MENUITEM SEPARATOR MENUITEM "&Eigenschaften", FCIDM_SHVIEW_PROPERTIES @@ -97,29 +93,29 @@ END MENU_CPANEL MENU BEGIN - POPUP "&Datei" + POPUP "&File" BEGIN MENUITEM SEPARATOR - MENUITEM "&Beenden", IDM_CPANEL_EXIT + MENUITEM "E&xit", IDM_CPANEL_EXIT END - POPUP "&Ansicht" + POPUP "&View" BEGIN - MENUITEM "&Große Symbole", FCIDM_SHVIEW_BIGICON + MENUITEM "&Große Symbole", FCIDM_SHVIEW_BIGICON MENUITEM "&Kleine Symbole", FCIDM_SHVIEW_SMALLICON MENUITEM "&Liste", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Details", FCIDM_SHVIEW_REPORTVIEW END - POPUP "&Hilfe" + POPUP "&Help" BEGIN - MENUITEM "&Über Systemsteuerung...", IDM_CPANEL_ABOUT + MENUITEM "&About Control Panel...", IDM_CPANEL_ABOUT END END SHBRSFORFOLDER_MSGBOX DIALOG LOADONCALL MOVEABLE DISCARDABLE 15, 40, 188, 192 STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU | DS_MODALFRAME | DS_SETFONT | DS_3DLOOK -CAPTION "Verzeichnis auswählen" +CAPTION "Verzeichnis auswählen" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", 1, 80, 176, 50, 12, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP @@ -134,7 +130,7 @@ FONT 8, "MS Shell Dlg" SHNEWBRSFORFOLDER_MSGBOX DIALOG LOADONCALL MOVEABLE DISCARDABLE 15, 40, 218, 196 STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU | WS_SIZEBOX | DS_MODALFRAME | DS_SETFONT | DS_3DLOOK -CAPTION "Verzeichnis auswählen" +CAPTION "Verzeichnis auswählen" FONT 8, "MS Shell Dlg" { LTEXT "", IDD_TITLE, 10, 8, 198, 24 @@ -165,7 +161,7 @@ FONT 8, "MS Shell Dlg" SHELL_ABOUT_MSGBOX DIALOG LOADONCALL MOVEABLE DISCARDABLE 15, 40, 210, 152 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Informationen über %s" +CAPTION "Informationen über %s" FONT 10, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 153, 133, 50, 12, WS_TABSTOP @@ -175,7 +171,7 @@ FONT 10, "MS Shell Dlg" LTEXT "", IDC_ABOUT_STATIC_TEXT1, 40, 10, 137, 10 LTEXT "", IDC_ABOUT_STATIC_TEXT2, 40, 22, 137, 10 LTEXT "Wine Version %s", IDC_ABOUT_STATIC_TEXT3, 40, 34, 170, 10 - LTEXT "Wine wurde für Sie gekeltert von:", IDC_ABOUT_WINE_TEXT, 8, 55, 137, 10 + LTEXT "Wine wurde für Sie gekeltert von:", IDC_ABOUT_WINE_TEXT, 8, 55, 137, 10 } SHELL_RUN_DLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 0, 0, 227, 95 @@ -184,8 +180,8 @@ CAPTION "" FONT 8, "MS Shell Dlg" { ICON "", 12297, 7, 11, 18, 20, WS_VISIBLE - LTEXT "Geben sie den Namen eines Programmes, eines Ordners, eines Dokumentes oder einer Internet-Ressource ein, die geöffnet werden soll", 12289, 36, 11, 182, 18 - LTEXT "Ö&ffnen:", 12305, 7, 39, 24, 10 + LTEXT "Geben sie den Namen eines Programmes, eines Ordners, eines Dokumentes oder einer Internet-Ressource ein, die geöffnet werden soll", 12289, 36, 11, 182, 18 + LTEXT "Ö&ffnen:", 12305, 7, 39, 24, 10 CONTROL "", 12298, "COMBOBOX", WS_TABSTOP | WS_GROUP | WS_VSCROLL | WS_VISIBLE | CBS_DISABLENOSCROLL | CBS_AUTOHSCROLL | CBS_DROPDOWN, 36, 37, 183, 100 DEFPUSHBUTTON "OK", IDOK, 62, 63, 50, 14, WS_TABSTOP PUSHBUTTON "Abbrechen", IDCANCEL, 116, 63, 50, 14, WS_TABSTOP @@ -196,70 +192,70 @@ STRINGTABLE { /* columns in the shellview */ IDS_SHV_COLUMN1 "Datei" - IDS_SHV_COLUMN2 "Größe" + IDS_SHV_COLUMN2 "Größe" IDS_SHV_COLUMN3 "Typ" - IDS_SHV_COLUMN4 "Geändert" + IDS_SHV_COLUMN4 "Geändert" IDS_SHV_COLUMN5 "Attribute" - IDS_SHV_COLUMN6 "Gesamtgröße" + IDS_SHV_COLUMN6 "Gesamtgröße" IDS_SHV_COLUMN7 "Freier Speicher" IDS_SHV_COLUMN8 "Name" IDS_SHV_COLUMN9 "Kommentar" IDS_SHV_COLUMN10 "Besitzer" IDS_SHV_COLUMN11 "Gruppe" IDS_SHV_COLUMN_DELFROM "Ursprung" - IDS_SHV_COLUMN_DELDATE "Gelöscht am" + IDS_SHV_COLUMN_DELDATE "Gelöscht am" /* special folders */ IDS_DESKTOP "Desktop" IDS_MYCOMPUTER "Arbeitsplatz" IDS_RECYCLEBIN_FOLDER_NAME "Papierkorb" - IDS_CONTROLPANEL "Systemsteuerung" + IDS_CONTROLPANEL "Control Panel" /* context menus */ - IDS_VIEW_LARGE "&Große Symbole" + IDS_VIEW_LARGE "&Große Symbole" IDS_VIEW_SMALL "&Kleine Symbole" IDS_VIEW_LIST "&Liste" IDS_VIEW_DETAILS "&Details" - IDS_SELECT "Auswählen" - IDS_OPEN "Öffnen" + IDS_SELECT "Auswählen" + IDS_OPEN "Öffnen" IDS_CREATEFOLDER_DENIED "Es konnte kein neues Verzeichnis erstellt werden: Zugriff verweigert." IDS_CREATEFOLDER_CAPTION "Es trat ein Fehler beim Erstellen eines neuen Verzeichnisses auf" - IDS_DELETEITEM_CAPTION "Bestätigung: Objekt löschen" - IDS_DELETEFOLDER_CAPTION "Bestätigung: Verzeichnis löschen" - IDS_DELETEITEM_TEXT "Sind Sie sich sicher, dass Sie '%1' löschen möchten?" - IDS_DELETEMULTIPLE_TEXT "Sind Sie sich sicher, dass Sie diese %1 Objekte löschen möchten?" - IDS_DELETESELECTED_TEXT "Sind Sie sich sicher, dass Sie die ausgewählten Objekte löschen möchten?" - IDS_TRASHITEM_TEXT "Sind Sie sich sicher, dass Sie '%1' in den Papierkorb verschieben möchten?" - IDS_TRASHFOLDER_TEXT "Sind Sie sich sicher, dass Sie '%1' und seinen Inhalt in den Papierkorb verschieben möchten?" - IDS_TRASHMULTIPLE_TEXT "Sind Sie sich sicher, dass Sie diese %1 Dateien in den Papierkorb verschieben möchten?" - IDS_CANTTRASH_TEXT "Das Objekt '%1' kann nicht in den Papierkorb verschoben werden.\n\n Möchten Sie es stattdessen löschen?" - IDS_OVERWRITEFILE_TEXT "Der Ordner enthält bereits eine Datei namens '%1'.\n\n Wollen Sie die Datei ersetzen?" - IDS_OVERWRITEFILE_CAPTION "Bestätigung: Datei überschreiben" + IDS_DELETEITEM_CAPTION "Bestätigung: Objekt löschen" + IDS_DELETEFOLDER_CAPTION "Bestätigung: Verzeichnis löschen" + IDS_DELETEITEM_TEXT "Sind Sie sich sicher, dass Sie '%1' löschen möchten?" + IDS_DELETEMULTIPLE_TEXT "Sind Sie sich sicher, dass Sie diese %1 Objekte löschen möchten?" + IDS_DELETESELECTED_TEXT "Sind Sie sich sicher, dass Sie die ausgewählten Objekte löschen möchten?" + IDS_TRASHITEM_TEXT "Sind Sie sich sicher, dass Sie '%1' in den Papierkorb verschieben möchten?" + IDS_TRASHFOLDER_TEXT "Sind Sie sich sicher, dass Sie '%1' und seinen Inhalt in den Papierkorb verschieben möchten?" + IDS_TRASHMULTIPLE_TEXT "Sind Sie sich sicher, dass Sie diese %1 Dateien in den Papierkorb verschieben möchten?" + IDS_CANTTRASH_TEXT "Das Objekt '%1' kann nicht in den Papierkorb verschoben werden.\n\n Möchten Sie es stattdessen löschen?" + IDS_OVERWRITEFILE_TEXT "Der Ordner enthält bereits eine Datei namens '%1'.\n\n Wollen Sie die Datei ersetzen?" + IDS_OVERWRITEFILE_CAPTION "Bestätigung: Datei überschreiben" IDS_OVERWRITEFOLDER_TEXT "Im Verzeichnis befindet sich bereits ein Ordner namens '%1'.\n\n"\ - "Wenn die Dateien im Zielordner die gleichen Namen haben, wie die im ausgewählten Ordner, werden sie ersetzt.\n\n\ - Möchten sie trotzdem fortfahren?" + "Wenn die Dateien im Zielordner die gleichen Namen haben, wie die im ausgewählten Ordner, werden sie ersetzt.\n\n\ + Möchten sie trotzdem fortfahren?" /* message box strings */ IDS_RESTART_TITLE "Neustarten" - IDS_RESTART_PROMPT "Möchten Sie, dass ein simulierter Windows Neustart durchgeführt wird?" + IDS_RESTART_PROMPT "Möchten Sie, dass ein simulierter Windows Neustart durchgeführt wird?" IDS_SHUTDOWN_TITLE "Beenden" - IDS_SHUTDOWN_PROMPT "Möchten Sie die aktuelle Wine Sitzung beenden?" + IDS_SHUTDOWN_PROMPT "Möchten Sie die aktuelle Wine Sitzung beenden?" /* Run File dialog */ - IDS_RUNDLG_ERROR "Konnte Ausführen-Dialog nicht anzeigen (interner Fehler)" + IDS_RUNDLG_ERROR "Konnte Ausführen-Dialog nicht anzeigen (interner Fehler)" IDS_RUNDLG_BROWSE_ERROR "Konnte Durchsuchen-Dialog nicht anzeigen (interner Fehler)" IDS_RUNDLG_BROWSE_CAPTION "Durchsuchen" IDS_RUNDLG_BROWSE_FILTER "Programme\0*.exe\0Alle Dateien\0*.*\0\0" /* shell folder path default values */ - IDS_PROGRAMS "Startmenü\\Programme" + IDS_PROGRAMS "Startmenü\\Programme" IDS_PERSONAL "Eigene Dateien" IDS_FAVORITES "Favoriten" - IDS_STARTUP "Startmenü\\Programme\\Autostart" + IDS_STARTUP "Startmenü\\Programme\\Autostart" IDS_RECENT "Recent" IDS_SENDTO "SendTo" - IDS_STARTMENU "Startmenü" + IDS_STARTMENU "Startmenü" IDS_MYMUSIC "Eigene Musik" IDS_MYVIDEO "Eigene Videos" IDS_DESKTOPDIRECTORY "Desktop" @@ -275,34 +271,34 @@ STRINGTABLE IDS_MYPICTURES "Eigene Bilder" IDS_PROGRAM_FILES_COMMON "Programme\\Gemeinsame Dateien" IDS_COMMON_DOCUMENTS "Dokumente" - IDS_ADMINTOOLS "Startmenü\\Programme\\Verwaltung" - IDS_COMMON_MUSIC "Musik" - IDS_COMMON_PICTURES "Bilder" - IDS_COMMON_VIDEO "Videos" + IDS_ADMINTOOLS "Startmenü\\Programme\\Verwaltung" + IDS_COMMON_MUSIC "Dokumente\\Eigene Musik" + IDS_COMMON_PICTURES "Dokumente\\Eigene Bilder" + IDS_COMMON_VIDEO "Dokumente\\Eigene Videos" IDS_CDBURN_AREA "Lokale Einstellungen\\Anwendungsdaten\\Microsoft\\CD Burning" IDS_NEWFOLDER "Neuer Ordner" - IDS_CPANEL_TITLE "Wine Systemsteuerung" + IDS_CPANEL_TITLE "Wine Control Panel" IDS_CPANEL_NAME "Name" - IDS_CPANEL_DESCRIPTION "Beschreibung" - IDS_SHLEXEC_NOASSOC "Es ist kein Programm mit diesem Dateityp verknüpft." + IDS_CPANEL_DESCRIPTION "Description" + IDS_SHLEXEC_NOASSOC "Es ist kein Programm mit diesem Dateityp verknüpft." } STRINGTABLE { -IDS_LICENSE_CAPTION, "Wine Lizenz" +IDS_LICENSE_CAPTION, "Wine License" IDS_LICENSE, -"Wine ist freie Software; Sie dürfen sie unter den Bedingungen \ +"Wine ist freie Software; Sie dürfen sie unter den Bedingungen \ der GNU Lesser General Public License, welche von der \ -Free Software Foundation veröffentlicht wurde; weiter verteilen \ -und/oder modifizieren gemäß Version 2.1 der Lizenz, oder \ -(nach ihren Ermessen) jeder späteren Version.\n\n\ -Wine wird mit der Hoffnung verteilt das es sich als nützlich erweist. \ +Free Software Foundation veröffentlicht wurde; weiter verteilen \ +und/oder modifizieren gemäß Version 2.1 der Lizenz, oder \ +(nach ihren Ermessen) jeder späteren Version.\n\n\ +Wine wird mit der Hoffnung verteilt das es sich als nützlich erweist. \ Wine kommt aber OHNE JEGLICHE GARANTIE daher; sogar ohne einer \ -angedeuteten Garantie der MARKTGÄNGIGKEIT oder der EIGNUNG FÜR EINEN \ +angedeuteten Garantie der MARKTGÄNGIGKEIT oder der EIGNUNG FÜR EINEN \ BESTIMMTEN NUTZEN. Sehen Sie sich die GNU Lesser General Public License \ -an für mehr Details.\n\n\ +an für mehr Details.\n\n\ Sie sollten mit dieser Bibliothek auch eine Kopie der \ GNU Lesser General Public License erhalten haben; wenn nicht schreiben \ Sie der Free Software Foundation, \ diff --git a/dlls/shell32/shell32_En.rc b/dlls/shell32/shell32_En.rc index 6d68083ef8b..d7fa7c333bd 100644 --- a/dlls/shell32/shell32_En.rc +++ b/dlls/shell32/shell32_En.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT MENU_001 MENU DISCARDABLE @@ -274,9 +272,9 @@ STRINGTABLE IDS_PROGRAM_FILES_COMMON "Program Files\\Common Files" IDS_COMMON_DOCUMENTS "Documents" IDS_ADMINTOOLS "Start Menu\\Programs\\Administrative Tools" - IDS_COMMON_MUSIC "Music" - IDS_COMMON_PICTURES "Pictures" - IDS_COMMON_VIDEO "Videos" + IDS_COMMON_MUSIC "Documents\\My Music" + IDS_COMMON_PICTURES "Documents\\My Pictures" + IDS_COMMON_VIDEO "Documents\\My Videos" IDS_CDBURN_AREA "Local Settings\\Application Data\\Microsoft\\CD Burning" IDS_NEWFOLDER "New Folder" diff --git a/dlls/shell32/shell32_Eo.rc b/dlls/shell32/shell32_Eo.rc index 4d753df541e..40c503ae228 100644 --- a/dlls/shell32/shell32_Eo.rc +++ b/dlls/shell32/shell32_Eo.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT /* Cxapelitaj literoj estas en Latin-3 iso8895-3 */ diff --git a/dlls/shell32/shell32_Es.rc b/dlls/shell32/shell32_Es.rc index 06580d16654..17773fc088f 100644 --- a/dlls/shell32/shell32_Es.rc +++ b/dlls/shell32/shell32_Es.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL MENU_001 MENU DISCARDABLE diff --git a/dlls/shell32/shell32_Fi.rc b/dlls/shell32/shell32_Fi.rc index a124e64d77c..f0a1b5ad282 100644 --- a/dlls/shell32/shell32_Fi.rc +++ b/dlls/shell32/shell32_Fi.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT MENU_001 MENU DISCARDABLE diff --git a/dlls/shell32/shell32_Fr.rc b/dlls/shell32/shell32_Fr.rc index e63a58967f1..e4fc4bb8c29 100644 --- a/dlls/shell32/shell32_Fr.rc +++ b/dlls/shell32/shell32_Fr.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL #pragma code_page(65001) /* UTF-8 */ @@ -87,7 +85,7 @@ BEGIN MENUITEM "E&xplorer", FCIDM_SHVIEW_EXPLORE MENUITEM "&Ouvrir", FCIDM_SHVIEW_OPEN MENUITEM SEPARATOR - MENUITEM "Cou&per", FCIDM_SHVIEW_CUT + MENUITEM "C&ouper", FCIDM_SHVIEW_CUT MENUITEM "&Copier", FCIDM_SHVIEW_COPY MENUITEM SEPARATOR MENUITEM "Créer un &lien", FCIDM_SHVIEW_CREATELINK @@ -100,13 +98,13 @@ END MENU_CPANEL MENU BEGIN - POPUP "&Fichier" + POPUP "&File" BEGIN MENUITEM SEPARATOR - MENUITEM "&Quitter", IDM_CPANEL_EXIT + MENUITEM "E&xit", IDM_CPANEL_EXIT END - POPUP "&Affichage" + POPUP "&View" BEGIN MENUITEM "&Grandes icônes", FCIDM_SHVIEW_BIGICON MENUITEM "&Petites icônes", FCIDM_SHVIEW_SMALLICON @@ -114,9 +112,9 @@ BEGIN MENUITEM "&Détails", FCIDM_SHVIEW_REPORTVIEW END - POPUP "Ai&de" + POPUP "&Help" BEGIN - MENUITEM "À &propos du panneau de configuration...", IDM_CPANEL_ABOUT + MENUITEM "&About Control Panel...", IDM_CPANEL_ABOUT END END @@ -148,7 +146,7 @@ FONT 8, "MS Shell Dlg" WS_BORDER | WS_TABSTOP, 12, 38, 194, 105 EDITTEXT IDD_FOLDERTEXT, 46, 150, 160, 14, WS_BORDER | WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Nouveau dossier", IDD_MAKENEWFOLDER, 12, 174, 70, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Créer un nouveau dossier", IDD_MAKENEWFOLDER, 12, 174, 70, 14, WS_GROUP | WS_TABSTOP DEFPUSHBUTTON "OK", IDOK, 102, 174, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP PUSHBUTTON "Annuler", IDCANCEL, 156, 174, 50, 14, WS_GROUP | WS_TABSTOP } @@ -216,7 +214,7 @@ STRINGTABLE IDS_DESKTOP "Bureau" IDS_MYCOMPUTER "Poste de travail" IDS_RECYCLEBIN_FOLDER_NAME "Corbeille" - IDS_CONTROLPANEL "Panneau de configuration" + IDS_CONTROLPANEL "Control Panel" /* context menus */ IDS_VIEW_LARGE "&Grandes icônes" @@ -226,29 +224,29 @@ STRINGTABLE IDS_SELECT "Sélectionner" IDS_OPEN "Ouvrir" - IDS_CREATEFOLDER_DENIED "Impossible de créer le dossier : permission refusée." - IDS_CREATEFOLDER_CAPTION "Erreur lors de la création du dossier" - IDS_DELETEITEM_CAPTION "Confirmez la suppression du fichier" - IDS_DELETEFOLDER_CAPTION "Confirmez la suppression du dossier" - IDS_DELETEITEM_TEXT "Êtes-vous sûr de vouloir supprimer « %1 » ?" + IDS_CREATEFOLDER_DENIED "Impossible de créer le nouveau dossier : permission refusée." + IDS_CREATEFOLDER_CAPTION "Erreur lors de la création du nouveau dossier" + IDS_DELETEITEM_CAPTION "Confirmer la suppression du fichier" + IDS_DELETEFOLDER_CAPTION "Confirmer la suppression du dossier" + IDS_DELETEITEM_TEXT "Êtes-vous sûr de vouloir supprimer '%1'?" IDS_DELETEMULTIPLE_TEXT "Êtes-vous sûr de vouloir supprimer ces %1 éléments ?" - IDS_DELETESELECTED_TEXT "Êtes-vous sûr de vouloir supprimer le(s) élément(s) sélectionné(s) ?" + IDS_DELETESELECTED_TEXT "Êtes-vous sûr de vouloir supprimer le(les) élément(s) séléectionné(s) ?" IDS_TRASHITEM_TEXT "Êtes-vous sûr de vouloir mettre « %1 » dans la corbeille ?" IDS_TRASHFOLDER_TEXT "Êtes-vous sûr de vouloir mettre « %1 » et tout ce qu'il contient dans la corbeille ?" IDS_TRASHMULTIPLE_TEXT "Êtes-vous sûr de vouloir mettre ces %1 éléments dans la corbeille ?" - IDS_CANTTRASH_TEXT "L'élément « %1 » ne peut être mis dans la corbeille. Souhaitez-vous plutôt le supprimer ?" + IDS_CANTTRASH_TEXT "L'élément « %1 » ne peut pas être mis dans la corbeille. Souhaitez-vous le supprimer à la place ?" IDS_OVERWRITEFILE_TEXT "Ce dossier contient déjà un fichier nommé « %1 ».\n\nVoulez-vous le remplacer ?" - IDS_OVERWRITEFILE_CAPTION "Confirmez l'écrasement du fichier" + IDS_OVERWRITEFILE_CAPTION "Confirmer l'écrasement du fichier" IDS_OVERWRITEFOLDER_TEXT "Ce dossier contient déjà un dossier nommé « %1 ».\n\n"\ "Si des fichiers dans le dossier de destination ont le même nom que ceux dans le dossier\n"\ - "sélectionné, ils seront écrasés. Voulez-vous quand même déplacer ou copier\n"\ + "sélectionné, ils seront remplacés. Voulez-vous quand même déplacer ou copier\n"\ "le dossier ?" /* message box strings */ IDS_RESTART_TITLE "Redémarrer" IDS_RESTART_PROMPT "Voulez-vous simuler le redémarrage de Windows ?" IDS_SHUTDOWN_TITLE "Arrêter" - IDS_SHUTDOWN_PROMPT "Voulez-vous clôturer la session Wine ?" + IDS_SHUTDOWN_PROMPT "Voulez-vous fermer la session Wine ?" /* Run File dialog */ IDS_RUNDLG_ERROR "Impossible d'afficher la boîte de dialogue « Exécuter » (erreur interne)" @@ -261,13 +259,13 @@ STRINGTABLE IDS_PERSONAL "Mes documents" IDS_FAVORITES "Favoris" IDS_STARTUP "Menu Démarrer\\Programmes\\Démarrage" - IDS_RECENT "Documents récents" - IDS_SENDTO "Envoyer vers" + IDS_RECENT "Recent" + IDS_SENDTO "SendTo" IDS_STARTMENU "Menu Démarrer" IDS_MYMUSIC "Ma musique" IDS_MYVIDEO "Mes vidéos" IDS_DESKTOPDIRECTORY "Bureau" - IDS_NETHOOD "Voisinage réseau" + IDS_NETHOOD "Voisinage Réseau" IDS_TEMPLATES "Modèles" IDS_APPDATA "Application Data" IDS_PRINTHOOD "Voisinage d'impression" @@ -287,11 +285,11 @@ STRINGTABLE IDS_NEWFOLDER "Nouveau dossier" - IDS_CPANEL_TITLE "Panneau de configuration de Wine" - IDS_CPANEL_NAME "Nom" + IDS_CPANEL_TITLE "Wine Control Panel" + IDS_CPANEL_NAME "Name" IDS_CPANEL_DESCRIPTION "Description" - IDS_SHLEXEC_NOASSOC "Aucun programme Windows n'est configuré pour ouvrir ce type de fichier." + IDS_SHLEXEC_NOASSOC "Il n'y a aucun programme Windows configuré pour ouvrir ce type de fichier." } STRINGTABLE @@ -301,7 +299,7 @@ IDS_LICENSE, "Wine est un logiciel libre ; vous pouvez le redistribuer et/ou \ le modifier suivant les termes de la Licence Générale Publique Limitée GNU \ telle que publiée par la Free Software Foundation ; soit la version 2.1 \ -de la Licence, soit (à votre gré) toute version ultérieure.\n\n\ +de la License, soit (à votre gré) toute version ultérieure.\n\n\ Wine est distribué dans l’espoir qu'il sera utile, mais \ SANS AUCUNE GARANTIE : sans même la garantie implicite de \ COMMERCIALISABILITÉ ou d’ADÉQUATION À UN OBJECTIF PARTICULIER. Consultez \ @@ -311,3 +309,5 @@ GNU avec Wine ; si ce n’est pas le cas, écrivez à la : \ Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, \ MA 02110-1301, USA." } + +#pragma code_page(default) /* Return to default encoding */ diff --git a/dlls/shell32/shell32_Hu.rc b/dlls/shell32/shell32_Hu.rc index 466e826e213..9b1c198d236 100644 --- a/dlls/shell32/shell32_Hu.rc +++ b/dlls/shell32/shell32_Hu.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT /* diff --git a/dlls/shell32/shell32_It.rc b/dlls/shell32/shell32_It.rc index fb55d528986..baa00778a6e 100644 --- a/dlls/shell32/shell32_It.rc +++ b/dlls/shell32/shell32_It.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL MENU_001 MENU DISCARDABLE diff --git a/dlls/shell32/shell32_Ja.rc b/dlls/shell32/shell32_Ja.rc index e426ee52dd1..6e1ae07d4cc 100644 --- a/dlls/shell32/shell32_Ja.rc +++ b/dlls/shell32/shell32_Ja.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - /* UTF-8 */ #pragma code_page(65001) @@ -305,3 +303,5 @@ You should have received a copy of the GNU Lesser General Public \ License along with Wine; if not, write to the Free Software \ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA." } + +#pragma code_page(default) diff --git a/dlls/shell32/shell32_Ko.rc b/dlls/shell32/shell32_Ko.rc index 91a327ef4cc..16ad3b1c83e 100644 --- a/dlls/shell32/shell32_Ko.rc +++ b/dlls/shell32/shell32_Ko.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT MENU_001 MENU DISCARDABLE diff --git a/dlls/shell32/shell32_Lt.rc b/dlls/shell32/shell32_Lt.rc index 132dcb3d5eb..411bbe62b9b 100644 --- a/dlls/shell32/shell32_Lt.rc +++ b/dlls/shell32/shell32_Lt.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - /* UTF-8 */ #pragma code_page(65001) @@ -227,16 +225,16 @@ STRINGTABLE IDS_CREATEFOLDER_CAPTION "Klaida kuriant naują aplanką" IDS_DELETEITEM_CAPTION "Patvirtinti failo šalinimą" IDS_DELETEFOLDER_CAPTION "Patvirtinti aplanko šalinimą" - IDS_DELETEITEM_TEXT "Ar tikrai norite pašalinti „%1“?" + IDS_DELETEITEM_TEXT "Ar tikrai norite pašalinti '%1'?" IDS_DELETEMULTIPLE_TEXT "Ar tikrai norite pašalinti šiuos %1 elementus?" IDS_DELETESELECTED_TEXT "Ar tikrai norite pašalinti išrinktus elementus?" - IDS_TRASHITEM_TEXT "Ar tikrai norite perkelti „%1“ į šiukšlinę?" - IDS_TRASHFOLDER_TEXT "Ar tikrai norite perkelti „%1“ ir jo turinį į šiukšlinę?" + IDS_TRASHITEM_TEXT "Ar tikrai norite perkelti '%1' į šiukšlinę?" + IDS_TRASHFOLDER_TEXT "Ar tikrai norite perkelti '%1' ir jo turinį į šiukšlinę?" IDS_TRASHMULTIPLE_TEXT "Ar tikrai norite perkelti šiuos %1 elementus į šiukšlinę?" - IDS_CANTTRASH_TEXT "Šis elementas „%1“ negali būti perkeltas į šiukšlinę. Ar norite jį pašalinti vietoj šiukšlinės?" - IDS_OVERWRITEFILE_TEXT "Šis aplankas jau turi failą vardu „%1“.\n\nAr norite jį pakeisti?" + IDS_CANTTRASH_TEXT "Šis elementas '%1' negali būti perkeltas į šiukšlinę. Ar norite jį pašalinti vietoj šiukšlinės?" + IDS_OVERWRITEFILE_TEXT "Šis aplankas jau turi failą vardu '%1'.\n\nAr norite jį pakeisti?" IDS_OVERWRITEFILE_CAPTION "Patvirtinti failo perrašymą" - IDS_OVERWRITEFOLDER_TEXT "Šis aplankas jau turi aplanką vardu „%1“.\n\n"\ + IDS_OVERWRITEFOLDER_TEXT "Šis aplankas jau turi aplanką vardu '%1'.\n\n"\ "Jei failai paskirties aplanke yra pavadinti tais pačiais vardais kaip ir failai\n"\ "išrinktame aplanke, tai jie bus pakeisti. Ar vis dar norite perkelti ar kopijuoti\n"\ "šį aplanką?" @@ -309,3 +307,5 @@ kopiją kartu su Wine; jei negavote, rašykite adresu \ Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, \ Boston, MA 02110-1301, USA." } + +#pragma code_page(default) diff --git a/dlls/shell32/shell32_Nl.rc b/dlls/shell32/shell32_Nl.rc index e3038a16c4c..1de7bf02d37 100644 --- a/dlls/shell32/shell32_Nl.rc +++ b/dlls/shell32/shell32_Nl.rc @@ -17,16 +17,12 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - -#pragma code_page(65001) - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL MENU_001 MENU DISCARDABLE BEGIN - MENUITEM "&Grote Pictogrammen", FCIDM_SHVIEW_BIGICON - MENUITEM "&Kleine Pictogrammen", FCIDM_SHVIEW_SMALLICON + MENUITEM "&Grote Icons", FCIDM_SHVIEW_BIGICON + MENUITEM "&Kleine Icons", FCIDM_SHVIEW_SMALLICON MENUITEM "&Lijst", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Details", FCIDM_SHVIEW_REPORTVIEW END @@ -40,13 +36,13 @@ BEGIN BEGIN POPUP "&Bekijken" BEGIN - MENUITEM "&Grote Pictogrammen", FCIDM_SHVIEW_BIGICON - MENUITEM "&Kleine Pictogrammen", FCIDM_SHVIEW_SMALLICON + MENUITEM "&Grote Icons", FCIDM_SHVIEW_BIGICON + MENUITEM "&Kleine Icons", FCIDM_SHVIEW_SMALLICON MENUITEM "&Lijst", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Details", FCIDM_SHVIEW_REPORTVIEW END MENUITEM SEPARATOR - POPUP "P&ictogrammen Sorteren" + POPUP "Sorteren &Icons" BEGIN MENUITEM "Op &Naam", 0x30 /* column 0 */ MENUITEM "Op &Type", 0x32 /* column 2 */ @@ -55,17 +51,17 @@ BEGIN MENUITEM SEPARATOR MENUITEM "&Automatisch", FCIDM_SHVIEW_AUTOARRANGE END - MENUITEM "Pictogrammen Uitlijnen", FCIDM_SHVIEW_SNAPTOGRID + MENUITEM "Uitlijnen Icons", FCIDM_SHVIEW_SNAPTOGRID MENUITEM SEPARATOR MENUITEM "Vernieuwen", FCIDM_SHVIEW_REFRESH MENUITEM SEPARATOR MENUITEM "Plakken", FCIDM_SHVIEW_INSERT - MENUITEM "Plakken als Snelkoppeling", FCIDM_SHVIEW_INSERTLINK + MENUITEM "Plakken als Link", FCIDM_SHVIEW_INSERTLINK MENUITEM SEPARATOR POPUP "Nieuw" BEGIN MENUITEM "Nieuwe &Map", FCIDM_SHVIEW_NEWFOLDER - MENUITEM "Nieuwe Sne&lkoppeling", FCIDM_SHVIEW_NEWLINK + MENUITEM "Nieuwe &Link", FCIDM_SHVIEW_NEWLINK MENUITEM SEPARATOR END MENUITEM SEPARATOR @@ -81,15 +77,15 @@ MENU_SHV_FILE MENU DISCARDABLE BEGIN POPUP "" BEGIN - MENUITEM "&Selecteren" FCIDM_SHVIEW_OPEN + MENUITEM "&Selecteer" FCIDM_SHVIEW_OPEN MENUITEM "&Verkennen", FCIDM_SHVIEW_EXPLORE - MENUITEM "&Openen", FCIDM_SHVIEW_OPEN + MENUITEM "&Open", FCIDM_SHVIEW_OPEN MENUITEM SEPARATOR MENUITEM "K&nippen", FCIDM_SHVIEW_CUT - MENUITEM "&Kopiëren", FCIDM_SHVIEW_COPY + MENUITEM "&Kopieren", FCIDM_SHVIEW_COPY MENUITEM SEPARATOR - MENUITEM "Maak Sne&lkoppeling", FCIDM_SHVIEW_CREATELINK - MENUITEM "Ver&wijderen", FCIDM_SHVIEW_DELETE + MENUITEM "Creëer &Link", FCIDM_SHVIEW_CREATELINK + MENUITEM "Ver&wijder", FCIDM_SHVIEW_DELETE MENUITEM "&Hernoemen", FCIDM_SHVIEW_RENAME MENUITEM SEPARATOR MENUITEM "&Eigenschappen", FCIDM_SHVIEW_PROPERTIES @@ -98,23 +94,23 @@ END MENU_CPANEL MENU BEGIN - POPUP "&Bestand" + POPUP "&File" BEGIN MENUITEM SEPARATOR - MENUITEM "&Afsluiten", IDM_CPANEL_EXIT + MENUITEM "E&xit", IDM_CPANEL_EXIT END - POPUP "B&eeld" + POPUP "&View" BEGIN - MENUITEM "&Grote Pictogrammen", FCIDM_SHVIEW_BIGICON - MENUITEM "&Kleine Pictogrammen", FCIDM_SHVIEW_SMALLICON + MENUITEM "&Grote Icons", FCIDM_SHVIEW_BIGICON + MENUITEM "&Kleine Icons", FCIDM_SHVIEW_SMALLICON MENUITEM "&Lijst", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Details", FCIDM_SHVIEW_REPORTVIEW END POPUP "&Help" BEGIN - MENUITEM "&Over Configuratiescherm", IDM_CPANEL_ABOUT + MENUITEM "&Over Controle Paneel...", IDM_CPANEL_ABOUT END END @@ -214,32 +210,32 @@ STRINGTABLE IDS_DESKTOP "Bureaublad" IDS_MYCOMPUTER "Mijn Computer" IDS_RECYCLEBIN_FOLDER_NAME "Vuilnisbak" - IDS_CONTROLPANEL "Configuratiescherm" + IDS_CONTROLPANEL "Controle Paneel" /* context menus */ - IDS_VIEW_LARGE "Grote Pictogrammen" - IDS_VIEW_SMALL "&Kleine Pictogrammen" + IDS_VIEW_LARGE "Grote Icons" + IDS_VIEW_SMALL "&Kleine Icons" IDS_VIEW_LIST "&Lijst" IDS_VIEW_DETAILS "&Details" - IDS_SELECT "Selecteren" - IDS_OPEN "Openen" + IDS_SELECT "Selecteer" + IDS_OPEN "Open" - IDS_CREATEFOLDER_DENIED "Niet mogelijk om nieuwe map te maken: Geen permissies." - IDS_CREATEFOLDER_CAPTION "Fout tijdens het maken van een nieuwe map" - IDS_DELETEITEM_CAPTION "Bevestig bestandsverwijdering" - IDS_DELETEFOLDER_CAPTION "Bevestig mapverwijdering" + IDS_CREATEFOLDER_DENIED "Niet mogelijk om nieuwe map te maken: Permissie afgewezen." + IDS_CREATEFOLDER_CAPTION "Fout tijdens creatie van een nieuwe map" + IDS_DELETEITEM_CAPTION "Bevestig bestand verwijdering" + IDS_DELETEFOLDER_CAPTION "Bevestig map verwijdering" IDS_DELETEITEM_TEXT "Weet u zeker dat u '%1' wilt verwijderen?" IDS_DELETEMULTIPLE_TEXT "Weet u zeker dat u deze %1 bestanden wilt verwijderen?" IDS_DELETESELECTED_TEXT "Weet u zeker dat u de geselecteerde bestand(en) wilt verwijderen?" - IDS_TRASHITEM_TEXT "Weet u zeker dat u '%1' naar de Vuilnisbak wilt verplaatsen?" - IDS_TRASHFOLDER_TEXT "Weet u zeker dat u '%1' en zijn gehele inhoud naar de Vuilnisbak wilt verplaatsen?" - IDS_TRASHMULTIPLE_TEXT "Weet u zeker dat u deze %1 bestanden naar de Vuilnisbak wilt verplaatsen?" - IDS_CANTTRASH_TEXT "Bestand '%1' kan niet naar de Vuilnisbak worden verplaatst. Wilt u het bestand permanent verwijderen?" + IDS_TRASHITEM_TEXT "Weet u zeker dat u '%1' naar de Vuilnisbak wilt sturen?" + IDS_TRASHFOLDER_TEXT "Weet u zeker dat u '%1' en zijn gehele inhoud naar de Vuilnisbak wilt sturen?" + IDS_TRASHMULTIPLE_TEXT "Weet u zeker dat u deze %1 bestanden naar de Vuilnisbak wilt sturen?" + IDS_CANTTRASH_TEXT "Bestand '%1' kan niet naar de Vuilnisbak worden gestuurd. Wilt u het dan maar verwijderen?" IDS_OVERWRITEFILE_TEXT "Deze map bevat reeds een bestand genaamd '%1'.\n\nWilt u het vervangen?" - IDS_OVERWRITEFILE_CAPTION "Bevestig bestandsoverschrijving" + IDS_OVERWRITEFILE_CAPTION "Bevestig het overschrijven van het bestand" IDS_OVERWRITEFOLDER_TEXT "Deze map bevat reeds een map genaamd '%1'.\n\n"\ - "Als de bestanden in de doelmap dezelfde naam hebben als de bestanden in de\n"\ - "geselecteerde map zullen ze worden overschreven. Wilt u alsnog de map kopiëren\n"\ + "Als de bestanden in de doel map dezelfde naam hebben als de bestanden in de\n"\ + "geselecteerde map worden ze overschreven. Wilt u nog steeds de map copieren\n"\ "of verplaatsen?" /* message box strings */ @@ -249,47 +245,47 @@ STRINGTABLE IDS_SHUTDOWN_PROMPT "Wilt u uw Wine sessie afsluiten?" /* Run File dialog */ - IDS_RUNDLG_ERROR "Fout tijdens tonen venster 'Uitvoeren Bestand' (interne fout)" - IDS_RUNDLG_BROWSE_ERROR "Fout tijdens tonen van Bladeren venster (interne fout)" + IDS_RUNDLG_ERROR "Fout tijdens tonen Uitvoeren Bestand venster (interne fout)" + IDS_RUNDLG_BROWSE_ERROR "Fout tijdens tonen Bladeren venster (interne fout)" IDS_RUNDLG_BROWSE_CAPTION "Bladeren" IDS_RUNDLG_BROWSE_FILTER "Uitvoerbare bestanden\0*.exe\0Alle bestanden\0*.*\0\0" /* shell folder path default values */ - IDS_PROGRAMS "Start Menu\\Programma's" + IDS_PROGRAMS "Start Menu\\Programmas" IDS_PERSONAL "Mijn Documenten" IDS_FAVORITES "Favorieten" - IDS_STARTUP "Start Menu\\Programma's\\Opstarten" + IDS_STARTUP "Start Menu\\Programmas\\StartUp" IDS_RECENT "Recent" - IDS_SENDTO "SendTo" + IDS_SENDTO "Stuur Naar" IDS_STARTMENU "Start Menu" IDS_MYMUSIC "Mijn Muziek" - IDS_MYVIDEO "Mijn Video's" + IDS_MYVIDEO "Mijn Videos" IDS_DESKTOPDIRECTORY "Bureaublad" IDS_NETHOOD "Netwerkomgeving" IDS_TEMPLATES "Sjablonen" - IDS_APPDATA "Application Data" + IDS_APPDATA "Applicatie Data" IDS_PRINTHOOD "Printeromgeving" - IDS_LOCAL_APPDATA "Local Settings\\Application Data" - IDS_INTERNET_CACHE "Local Settings\\Tijdelijke Internetbestanden" - IDS_COOKIES "Cookies" - IDS_HISTORY "Local Settings\\Geschiedenis" - IDS_PROGRAM_FILES "Program Files" + IDS_LOCAL_APPDATA "Lokale Instellingen\\Applicatie Data" + IDS_INTERNET_CACHE "Lokale Instellingen\\Tijdelijke Internet Bestanden" + IDS_COOKIES "Koekies" + IDS_HISTORY "Lokale Instellingen\\Geschiedenis" + IDS_PROGRAM_FILES "Programma Bestanden" IDS_MYPICTURES "Mijn Afbeeldingen" - IDS_PROGRAM_FILES_COMMON "Program Files\\Common Files" + IDS_PROGRAM_FILES_COMMON "Programma Bestanden\\Gemeenschappelijke Bestanden" IDS_COMMON_DOCUMENTS "Documenten" IDS_ADMINTOOLS "Start Menu\\Programmas\\Administratieve Tools" IDS_COMMON_MUSIC "Documenten\\Mijn Muziek" IDS_COMMON_PICTURES "Documenten\\Mijn Afbeeldingen" IDS_COMMON_VIDEO "Documenten\\Mijn Videos" - IDS_CDBURN_AREA "Local Settings\\Applicatie Data\\Microsoft\\CD Branden" + IDS_CDBURN_AREA "Lokale Instellingen\\Applicatie Data\\Microsoft\\CD Branden" IDS_NEWFOLDER "Nieuwe Map" - IDS_CPANEL_TITLE "Wine Configuratiescherm" + IDS_CPANEL_TITLE "Wine Controle Paneel" IDS_CPANEL_NAME "Naam" IDS_CPANEL_DESCRIPTION "Beschrijving" - IDS_SHLEXEC_NOASSOC "Er is geen Windows-programma geconfigureerd om dit soort bestanden te openen." + IDS_SHLEXEC_NOASSOC "Er is geen Windows programma geconfigureerd om dit soort bestanden te openen." } STRINGTABLE diff --git a/dlls/shell32/shell32_No.rc b/dlls/shell32/shell32_No.rc index 634c733b5b8..82facc0458f 100644 --- a/dlls/shell32/shell32_No.rc +++ b/dlls/shell32/shell32_No.rc @@ -1,5 +1,5 @@ /* - * Copyright 2005-2009 Alexander N. Sørnes + * Copyright 2005-2008 Alexander N. Sørnes * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -16,16 +16,12 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - -#pragma code_page(65001) - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL MENU_001 MENU DISCARDABLE BEGIN MENUITEM "&Store ikoner", FCIDM_SHVIEW_BIGICON - MENUITEM "&Små ikoner", FCIDM_SHVIEW_SMALLICON + MENUITEM "&Små ikoner", FCIDM_SHVIEW_SMALLICON MENUITEM "&Liste", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Detaljer", FCIDM_SHVIEW_REPORTVIEW END @@ -40,7 +36,7 @@ BEGIN POPUP "&Vis" BEGIN MENUITEM "&Store ikoner", FCIDM_SHVIEW_BIGICON - MENUITEM "S&må ikoner", FCIDM_SHVIEW_SMALLICON + MENUITEM "S&må ikoner", FCIDM_SHVIEW_SMALLICON MENUITEM "&Liste", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Detaljer", FCIDM_SHVIEW_REPORTVIEW END @@ -49,7 +45,7 @@ BEGIN BEGIN MENUITEM "Etter &navn", 0x30 /* column 0 */ MENUITEM "Etter &type", 0x32 /* column 2 */ - MENUITEM "Etter &størrelse", 0x31 /* ... */ + MENUITEM "Etter &størrelse", 0x31 /* ... */ MENUITEM "Etter &dato", 0x33 MENUITEM SEPARATOR MENUITEM "Ordne &automatisk", FCIDM_SHVIEW_AUTOARRANGE @@ -81,7 +77,7 @@ BEGIN BEGIN MENUITEM "&Velg" FCIDM_SHVIEW_OPEN MENUITEM "&Utforsk", FCIDM_SHVIEW_EXPLORE - MENUITEM "&Åpne", FCIDM_SHVIEW_OPEN + MENUITEM "&Åpne", FCIDM_SHVIEW_OPEN MENUITEM SEPARATOR MENUITEM "Klipp &ut", FCIDM_SHVIEW_CUT MENUITEM "&Kopier", FCIDM_SHVIEW_COPY @@ -105,7 +101,7 @@ BEGIN POPUP "&Vis" BEGIN MENUITEM "&Store ikoner", FCIDM_SHVIEW_BIGICON - MENUITEM "&Små ikoner", FCIDM_SHVIEW_SMALLICON + MENUITEM "&Små ikoner", FCIDM_SHVIEW_SMALLICON MENUITEM "&Liste", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Detaljer", FCIDM_SHVIEW_REPORTVIEW END @@ -173,7 +169,7 @@ FONT 10, "MS Shell Dlg" ICON "", stc1, 10, 10, 30, 30 LTEXT "", IDC_ABOUT_STATIC_TEXT1, 42, 10, 170, 10 LTEXT "", IDC_ABOUT_STATIC_TEXT2, 42, 22, 170, 10 - LTEXT "Kjører på %s", IDC_ABOUT_STATIC_TEXT3, 42, 34, 170, 10 + LTEXT "Kjører på %s", IDC_ABOUT_STATIC_TEXT3, 42, 34, 170, 10 LTEXT "Wine er laget av", IDC_ABOUT_WINE_TEXT, 8, 54, 204, 10 } @@ -183,8 +179,8 @@ CAPTION "" FONT 8, "MS Shell Dlg" { ICON "", 12297, 7, 11, 18, 20, WS_VISIBLE - LTEXT "Skriv inn navnet på programmet, mappen, dokumentet etter Internett-ressursen du ønsker å åpne.", 12289, 36, 11, 182, 18 - LTEXT "&Åpne:", 12305, 7, 39, 24, 10 + LTEXT "Skriv inn navnet på programmet, mappen, dokumentet etter Internett-ressursen du ønsker å åpne.", 12289, 36, 11, 182, 18 + LTEXT "&Åpne:", 12305, 7, 39, 24, 10 CONTROL "", 12298, "COMBOBOX", WS_TABSTOP | WS_GROUP | WS_VSCROLL | WS_VISIBLE | CBS_DISABLENOSCROLL | CBS_AUTOHSCROLL | CBS_DROPDOWN, 36, 37, 183, 100 DEFPUSHBUTTON "OK", IDOK, 62, 63, 50, 14, WS_TABSTOP PUSHBUTTON "Avbryt", IDCANCEL, 116, 63, 50, 14, WS_TABSTOP @@ -195,11 +191,11 @@ STRINGTABLE { /* columns in the shellview */ IDS_SHV_COLUMN1 "Fil" - IDS_SHV_COLUMN2 "Størrelse" + IDS_SHV_COLUMN2 "Størrelse" IDS_SHV_COLUMN3 "Type" IDS_SHV_COLUMN4 "Endret" IDS_SHV_COLUMN5 "Egenskaper" - IDS_SHV_COLUMN6 "Størrelse" + IDS_SHV_COLUMN6 "Størrelse" IDS_SHV_COLUMN7 "Ledig plass" IDS_SHV_COLUMN8 "Navn" IDS_SHV_COLUMN9 "Kommentarer" @@ -216,23 +212,23 @@ STRINGTABLE /* context menus */ IDS_VIEW_LARGE "&Store ikoner" - IDS_VIEW_SMALL "S&må ikoner" + IDS_VIEW_SMALL "S&må ikoner" IDS_VIEW_LIST "&Liste" IDS_VIEW_DETAILS "&Detaljer" IDS_SELECT "Velg" - IDS_OPEN "Åpne" + IDS_OPEN "Åpne" IDS_CREATEFOLDER_DENIED "Kunne ikke opprette ny mappe: tilgang nektet." IDS_CREATEFOLDER_CAPTION "Klarte ikke opprette ny mappe" IDS_DELETEITEM_CAPTION "Bekreft filsletting" IDS_DELETEFOLDER_CAPTION "Bekreft sletting av mappe" - IDS_DELETEITEM_TEXT "Virkelig slette «%1»?" + IDS_DELETEITEM_TEXT "Virkelig slette «%1»?" IDS_DELETEMULTIPLE_TEXT "Virkelig slette disse %1 elementene?" IDS_DELETESELECTED_TEXT "Virkelig slette valgte element(er)??" - IDS_TRASHITEM_TEXT "Virkelig legge «%1» i papirkurven?" - IDS_TRASHFOLDER_TEXT "Virkelig legge «%1» og alt innholdet i papirkurven?" + IDS_TRASHITEM_TEXT "Virkelig legge «%1» i papirkurven?" + IDS_TRASHFOLDER_TEXT "Virkelig legge «%1» og alt innholdet i papirkurven?" IDS_TRASHMULTIPLE_TEXT "Virkelig legge disse %1 valgte elementene i papirkurven?" - IDS_CANTTRASH_TEXT "Elementet «%1» kan ikke legges i papirkurven. Vil du slette det i stedet?" + IDS_CANTTRASH_TEXT "Elementet «%1» kan ikke legges i papirkurven. Vil du slette det i stedet?" IDS_OVERWRITEFILE_TEXT "This folder already contains a file called '%1'.\n\nDo you want to replace it?" IDS_OVERWRITEFILE_CAPTION "Bekreft overskriving av fil" IDS_OVERWRITEFOLDER_TEXT "This folder already contains a folder named '%1'.\n\n"\ @@ -241,13 +237,13 @@ STRINGTABLE "the folder?" /* message box strings */ - IDS_RESTART_TITLE "Starte på nytt" + IDS_RESTART_TITLE "Starte på nytt" IDS_RESTART_PROMPT "Vil du simulere en omstart av Windows?" IDS_SHUTDOWN_TITLE "Avslutt" - IDS_SHUTDOWN_PROMPT "Vil du avslutte Wine-økten?" + IDS_SHUTDOWN_PROMPT "Vil du avslutte Wine-økten?" /* Run File dialog */ - IDS_RUNDLG_ERROR "Klarte ikke vise Kjør-vinduet (intern feil)" + IDS_RUNDLG_ERROR "Klarte ikke vise Kjør-vinduet (intern feil)" IDS_RUNDLG_BROWSE_ERROR "Klarte ikke vise Bla-vinduet (intern feil)" IDS_RUNDLG_BROWSE_CAPTION "Bla" IDS_RUNDLG_BROWSE_FILTER "Programfiler\0*.exe\0Alle filer\0*.*\0\0" @@ -275,7 +271,7 @@ STRINGTABLE IDS_MYPICTURES "Mine bilder" IDS_PROGRAM_FILES_COMMON "Programfiler\\Fellesfiler" IDS_COMMON_DOCUMENTS "Dokumenter" - IDS_ADMINTOOLS "Start-meny\\Programmer\\Administrative verktøy" + IDS_ADMINTOOLS "Start-meny\\Programmer\\Administrative verktøy" IDS_COMMON_MUSIC "Dokumenter\\Min musikk" IDS_COMMON_PICTURES "Dokumenter\\Mine bilder" IDS_COMMON_VIDEO "Dokumenter\\Mine videoklipp" @@ -286,8 +282,6 @@ STRINGTABLE IDS_CPANEL_TITLE "Wine Kontrollpanel" IDS_CPANEL_NAME "Navn" IDS_CPANEL_DESCRIPTION "Beskrivelse" - - IDS_SHLEXEC_NOASSOC "Intet Windows-program er satt opp til å åpne denne filtypen." } STRINGTABLE @@ -295,14 +289,14 @@ STRINGTABLE IDS_LICENSE_CAPTION, "Lisensbetingelser" IDS_LICENSE, "Wine er fri programvare; du kan distribuere det og/eller \ -endre det i henhold til vilkårene i «GNU Lesser General Public \ -License», utgitt av the Free Software Foundation; enten \ -versjon 2.1 av Lisensen, eller (hvis du ønsker det) en nyere versjon.\n\n\ -Wine utgis i håp om at det er nyttig, \ +endre det i henhold til vilkårene i «GNU Lesser General Public \ +License», utgitt av the Free Software Foundation; enten \ +versjon 2.1 av Lisensen, eller (hvis du ønsker det) en nyere versjon.\n\n\ +Wine utgis i håp om at det er nyttig, \ men UTEN ENHVER GARANTI; uten engang den antydede garantien om \ -HANDELSEGNETHET eller EGNETHET FOR ET SPESIELT FORMÅL. Se «GNU \ -Lesser General Public License» for flere detaljer.\n\n\ -Du skal ha mottatt et eksemplar av «GNU Lesser General Public \ -License» sammen med dette programmet; hvis ikke, skriv til: the Free Software \ +HANDELSEGNETHET eller EGNETHET FOR ET SPESIELT FORMÅL. Se «GNU \ +Lesser General Public License» for flere detaljer.\n\n\ +Du skal ha mottatt et eksemplar av «GNU Lesser General Public \ +License» sammen med dette programmet; hvis ikke, skriv til: the Free Software \ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA." } diff --git a/dlls/shell32/shell32_Pl.rc b/dlls/shell32/shell32_Pl.rc index 31c0a8a3203..420c1671990 100644 --- a/dlls/shell32/shell32_Pl.rc +++ b/dlls/shell32/shell32_Pl.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT MENU_001 MENU DISCARDABLE diff --git a/dlls/shell32/shell32_Pt.rc b/dlls/shell32/shell32_Pt.rc index f3133b9ebe4..ed8b5291628 100644 --- a/dlls/shell32/shell32_Pt.rc +++ b/dlls/shell32/shell32_Pt.rc @@ -1,8 +1,7 @@ /* * Copyright 1998 Juergen Schmied * Copyright 2003 Marcelo Duarte - * Copyright 2006-2007 Américo José Melo - * Copyright 2009 Ricardo Filipe + * Copyright 2006-2007 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 @@ -19,16 +18,12 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN MENU_001 MENU DISCARDABLE BEGIN - MENUITEM "Ícones &grandes", FCIDM_SHVIEW_BIGICON - MENUITEM "Ícones &pequenos", FCIDM_SHVIEW_SMALLICON + MENUITEM "Ícones &grandes", FCIDM_SHVIEW_BIGICON + MENUITEM "Ícones &pequenos", FCIDM_SHVIEW_SMALLICON MENUITEM "&Lista", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Detalhes", FCIDM_SHVIEW_REPORTVIEW END @@ -45,13 +40,13 @@ BEGIN BEGIN POPUP "&Exibir" BEGIN - MENUITEM "Ícones &grandes", FCIDM_SHVIEW_BIGICON - MENUITEM "Ícones &pequenos", FCIDM_SHVIEW_SMALLICON + MENUITEM "Ícones &grandes", FCIDM_SHVIEW_BIGICON + MENUITEM "Ícones &pequenos", FCIDM_SHVIEW_SMALLICON MENUITEM "&Lista", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Detalhes", FCIDM_SHVIEW_REPORTVIEW END MENUITEM SEPARATOR - POPUP "O&rganizar ícones" + POPUP "O&rganizar ícones" BEGIN MENUITEM "Por &nome", 0x30 /* column 0 */ MENUITEM "Por &tipo", 0x32 /* column 2 */ @@ -60,7 +55,7 @@ BEGIN MENUITEM SEPARATOR MENUITEM "Auto organi&zar", FCIDM_SHVIEW_AUTOARRANGE END - MENUITEM "Alin&har ícones", FCIDM_SHVIEW_SNAPTOGRID + MENUITEM "Alin&har ícones", FCIDM_SHVIEW_SNAPTOGRID MENUITEM SEPARATOR MENUITEM "&Atualizar", FCIDM_SHVIEW_REFRESH MENUITEM SEPARATOR @@ -86,13 +81,13 @@ BEGIN BEGIN POPUP "&Mostrar" BEGIN - MENUITEM "Ícones &grandes", FCIDM_SHVIEW_BIGICON - MENUITEM "Ícones &pequenos", FCIDM_SHVIEW_SMALLICON + MENUITEM "Ícones &grandes", FCIDM_SHVIEW_BIGICON + MENUITEM "Ícones &pequenos", FCIDM_SHVIEW_SMALLICON MENUITEM "&Lista", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Detalhes", FCIDM_SHVIEW_REPORTVIEW END MENUITEM SEPARATOR - POPUP "O&rganizar ícones" + POPUP "O&rganizar ícones" BEGIN MENUITEM "Por &nome", 0x30 /* column 0 */ MENUITEM "Por &tipo", 0x32 /* column 2 */ @@ -101,7 +96,7 @@ BEGIN MENUITEM SEPARATOR MENUITEM "Auto organi&zar", FCIDM_SHVIEW_AUTOARRANGE END - MENUITEM "Alin&har ícones", FCIDM_SHVIEW_SNAPTOGRID + MENUITEM "Alin&har ícones", FCIDM_SHVIEW_SNAPTOGRID MENUITEM SEPARATOR MENUITEM "&Actualizar", FCIDM_SHVIEW_REFRESH MENUITEM SEPARATOR @@ -144,49 +139,27 @@ BEGIN END END -/* - shellview item menu -*/ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE -MENU_SHV_FILE MENU DISCARDABLE -BEGIN - POPUP "" - BEGIN - MENUITEM "&Seleccionar" FCIDM_SHVIEW_OPEN - MENUITEM "&Explorar", FCIDM_SHVIEW_EXPLORE - MENUITEM "A&brir", FCIDM_SHVIEW_OPEN - MENUITEM SEPARATOR - MENUITEM "C&ortar", FCIDM_SHVIEW_CUT - MENUITEM "&Copiar", FCIDM_SHVIEW_COPY - MENUITEM SEPARATOR - MENUITEM "Criar a&talho", FCIDM_SHVIEW_CREATELINK - MENUITEM "Re&mover", FCIDM_SHVIEW_DELETE - MENUITEM "&Renomear", FCIDM_SHVIEW_RENAME - MENUITEM SEPARATOR - MENUITEM "&Propriedades", FCIDM_SHVIEW_PROPERTIES - END -END - MENU_CPANEL MENU BEGIN - POPUP "&Ficheiro" + POPUP "&File" BEGIN MENUITEM SEPARATOR - MENUITEM "&Sair", IDM_CPANEL_EXIT + MENUITEM "E&xit", IDM_CPANEL_EXIT END - POPUP "&Ver" + POPUP "&View" BEGIN - MENUITEM "Ícones &grandes", FCIDM_SHVIEW_BIGICON - MENUITEM "Ícones &pequenos", FCIDM_SHVIEW_SMALLICON + MENUITEM "Ícones &grandes", FCIDM_SHVIEW_BIGICON + MENUITEM "Ícones &pequenos", FCIDM_SHVIEW_SMALLICON MENUITEM "&Lista", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Detalhes", FCIDM_SHVIEW_REPORTVIEW END - POPUP "&Ajuda" + POPUP "&Help" BEGIN - MENUITEM "&Sobre o painel de controlo...", IDM_CPANEL_ABOUT + MENUITEM "&About Control Panel...", IDM_CPANEL_ABOUT END END @@ -202,8 +175,8 @@ BEGIN POPUP "&View" BEGIN - MENUITEM "Ícones &grandes", FCIDM_SHVIEW_BIGICON - MENUITEM "Ícones &pequenos", FCIDM_SHVIEW_SMALLICON + MENUITEM "Ícones &grandes", FCIDM_SHVIEW_BIGICON + MENUITEM "Ícones &pequenos", FCIDM_SHVIEW_SMALLICON MENUITEM "&Lista", FCIDM_SHVIEW_LISTVIEW MENUITEM "&Detalhes", FCIDM_SHVIEW_REPORTVIEW END @@ -214,7 +187,7 @@ BEGIN END END -LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN SHBRSFORFOLDER_MSGBOX DIALOG LOADONCALL MOVEABLE DISCARDABLE 15, 40, 188, 192 STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU | DS_MODALFRAME | DS_SETFONT | DS_3DLOOK @@ -231,36 +204,6 @@ FONT 8, "MS Shell Dlg" 4, 40, 180, 120 } -SHNEWBRSFORFOLDER_MSGBOX DIALOG LOADONCALL MOVEABLE DISCARDABLE 15, 40, 218, 196 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU | WS_SIZEBOX | DS_MODALFRAME | DS_SETFONT | DS_3DLOOK -CAPTION "Procurar Pasta" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", IDD_TITLE, 10, 8, 198, 24 - LTEXT "", IDD_STATUS, 10, 25, 198, 12 - LTEXT "Pasta:", IDD_FOLDER, 10, 156, 40, 12 - CONTROL "", IDD_TREEVIEW, "SysTreeView32", - TVS_HASBUTTONS | TVS_HASLINES | TVS_LINESATROOT | - WS_BORDER | WS_TABSTOP, - 12, 38, 194, 105 - EDITTEXT IDD_FOLDERTEXT, 46, 150, 160, 14, WS_BORDER | WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Criar nova pasta", IDD_MAKENEWFOLDER, 12, 174, 70, 14, WS_GROUP | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 102, 174, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Cancelar", IDCANCEL, 156, 174, 50, 14, WS_GROUP | WS_TABSTOP -} - -SHELL_YESTOALL_MSGBOX DIALOG 200, 100, 280, 90 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Mensagem" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "&Sim", IDYES, 34, 69, 53, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "Sim a &todos", IDD_YESTOALL, 92, 69, 65, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Não", IDNO, 162, 69, 53, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "&Cancelar", IDCANCEL, 220, 69, 53, 14, WS_GROUP | WS_TABSTOP - ICON "", IDD_ICON, 10, 10, 16, 16 - LTEXT "", IDD_MESSAGE, 40, 10, 238, 52, 0 -} LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN @@ -270,7 +213,7 @@ CAPTION "Sobre %s" FONT 10, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 153, 133, 60, 12, WS_TABSTOP - PUSHBUTTON "&Licença do Wine", IDC_ABOUT_LICENSE, 153, 113, 60, 12, WS_TABSTOP + PUSHBUTTON "&Licença do Wine", IDC_ABOUT_LICENSE, 153, 113, 60, 12, WS_TABSTOP LISTBOX IDC_ABOUT_LISTBOX, 8, 65, 137, 82, LBS_NOTIFY | WS_VSCROLL | WS_BORDER ICON "", stc1, 10, 10, 30, 30 LTEXT "", IDC_ABOUT_STATIC_TEXT1, 40, 10, 170, 10 @@ -287,7 +230,7 @@ CAPTION "Acerca do %s" FONT 10, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 153, 133, 60, 12, WS_TABSTOP - PUSHBUTTON "&Licença do Wine", IDC_ABOUT_LICENSE, 153, 113, 60, 12, WS_TABSTOP + PUSHBUTTON "&Licença do Wine", IDC_ABOUT_LICENSE, 153, 113, 60, 12, WS_TABSTOP LISTBOX IDC_ABOUT_LISTBOX, 8, 65, 137, 82, LBS_NOTIFY | WS_VSCROLL | WS_BORDER ICON "", stc1, 10, 10, 30, 30 LTEXT "", IDC_ABOUT_STATIC_TEXT1, 40, 10, 170, 10 @@ -305,7 +248,7 @@ CAPTION "" FONT 8, "MS Shell Dlg" { ICON "", 12297, 7, 11, 18, 20, WS_VISIBLE - LTEXT "Digite o nome do programa, pasta, documento, ou endereço Internet, que o Wine irá abrí-lo para você.", 12289, 36, 11, 182, 18 + LTEXT "Digite o nome do programa, pasta, documento, ou endereço Internet, que o Wine irá abrí-lo para você.", 12289, 36, 11, 182, 18 LTEXT "&Abrir:", 12305, 7, 39, 24, 10 CONTROL "", 12298, "COMBOBOX", WS_TABSTOP | WS_GROUP | WS_VSCROLL | WS_VISIBLE | CBS_DISABLENOSCROLL | CBS_AUTOHSCROLL | CBS_DROPDOWN, 36, 37, 183, 100 DEFPUSHBUTTON "OK", IDOK, 62, 63, 50, 14, WS_TABSTOP @@ -321,7 +264,7 @@ CAPTION "" FONT 8, "MS Shell Dlg" { ICON "", 12297, 7, 11, 18, 20, WS_VISIBLE - LTEXT "Digite o nome do programa, pasta, documento, ou endereço Internet, que o Wine irá abrí-lo.", 12289, 36, 11, 182, 18 + LTEXT "Digite o nome do programa, pasta, documento, ou endereço Internet, que o Wine irá abrí-lo.", 12289, 36, 11, 182, 18 LTEXT "&Abrir:", 12305, 7, 39, 24, 10 CONTROL "", 12298, "COMBOBOX", WS_TABSTOP | WS_GROUP | WS_VSCROLL | WS_VISIBLE | CBS_DISABLENOSCROLL | CBS_AUTOHSCROLL | CBS_DROPDOWN, 36, 37, 183, 100 DEFPUSHBUTTON "OK", IDOK, 62, 63, 50, 14, WS_TABSTOP @@ -341,34 +284,33 @@ STRINGTABLE IDS_SHV_COLUMN4 "Modificado" IDS_SHV_COLUMN5 "Atributos" IDS_SHV_COLUMN6 "Tamanho" - IDS_SHV_COLUMN7 "Disponível" + IDS_SHV_COLUMN7 "Disponível" IDS_SHV_COLUMN8 "Nome" - IDS_SHV_COLUMN9 "Comentários" + IDS_SHV_COLUMN9 "Comentários" IDS_SHV_COLUMN10 "Dono" IDS_SHV_COLUMN11 "Grupo" - IDS_SHV_COLUMN_DELFROM "Localização original" - IDS_SHV_COLUMN_DELDATE "Data de exclusão" + IDS_SHV_COLUMN_DELFROM "Localização original" + IDS_SHV_COLUMN_DELDATE "Data de exclusão" /* special folders */ - IDS_DESKTOP "Área de trabalho" + IDS_DESKTOP "Área de trabalho" IDS_MYCOMPUTER "Meu computador" - IDS_RECYCLEBIN_FOLDER_NAME "Reciclagem" - IDS_CONTROLPANEL "Painel de controlo" + IDS_CONTROLPANEL "Control Panel" /* context menus */ - IDS_VIEW_LARGE "Ícones &grandes" - IDS_VIEW_SMALL "Ícones &pequenos" + IDS_VIEW_LARGE "Ícones &grandes" + IDS_VIEW_SMALL "Ícones &pequenos" IDS_VIEW_LIST "&Lista" IDS_VIEW_DETAILS "&Detalhes" IDS_SELECT "Selecionar" IDS_OPEN "Abrir" - IDS_CREATEFOLDER_DENIED "Não pode criar nova pasta: Permissão negada." - IDS_CREATEFOLDER_CAPTION "Erro durante a criação da nova pasta" - IDS_DELETEITEM_CAPTION "Confirmar exclusão de arquivo" - IDS_DELETEFOLDER_CAPTION "Confirmar exclusão de pasta" - IDS_DELETEITEM_TEXT "Você tem certeza que deseja excluir '%1'?" - IDS_DELETEMULTIPLE_TEXT "Você tem certeza que deseja excluir estes %1 itens?" + IDS_CREATEFOLDER_DENIED "Não pode criar nova pasta: Permissão negada." + IDS_CREATEFOLDER_CAPTION "Erro durante a criação da nova pasta" + IDS_DELETEITEM_CAPTION "Confirmar exclusão de arquivo" + IDS_DELETEFOLDER_CAPTION "Confirmar exclusão de pasta" + IDS_DELETEITEM_TEXT "Você tem certeza que deseja excluir '%1'?" + IDS_DELETEMULTIPLE_TEXT "Você tem certeza que deseja excluir estes %1 itens?" IDS_OVERWRITEFILE_TEXT "This folder already contains a file called '%1'.\n\nDo you want to replace it?" IDS_DELETESELECTED_TEXT "Are you sure you want to delete the selected item(s)?" IDS_TRASHITEM_TEXT "Are you sure that you want to send '%1' to the Trash?" @@ -383,9 +325,9 @@ STRINGTABLE /* message box strings */ IDS_RESTART_TITLE "Reiniciar" - IDS_RESTART_PROMPT "Você quer simular a reinicialização do Windows?" + IDS_RESTART_PROMPT "Você quer simular a reinicialização do Windows?" IDS_SHUTDOWN_TITLE "Desligar" - IDS_SHUTDOWN_PROMPT "Você quer finalizar a sessão no Wine?" + IDS_SHUTDOWN_PROMPT "Você quer finalizar a sessão no Wine?" /* shell folder path default values */ IDS_PROGRAMS "Menu Iniciar\\Programas" @@ -395,26 +337,26 @@ STRINGTABLE IDS_RECENT "Recent" IDS_SENDTO "SendTo" IDS_STARTMENU "Menu Iniciar" - IDS_MYMUSIC "Minhas Músicas" - IDS_MYVIDEO "Meus Vídeos" + IDS_MYMUSIC "Minhas Músicas" + IDS_MYVIDEO "Meus Vídeos" IDS_DESKTOPDIRECTORY "Desktop" IDS_NETHOOD "NetHood" IDS_TEMPLATES "Templates" IDS_APPDATA "Application Data" IDS_PRINTHOOD "PrintHood" - IDS_LOCAL_APPDATA "Configurações locais\\Dados de aplicativos" - IDS_INTERNET_CACHE "Configurações locais\\Temporary Internet Files" + IDS_LOCAL_APPDATA "Configurações locais\\Dados de aplicativos" + IDS_INTERNET_CACHE "Configurações locais\\Temporary Internet Files" IDS_COOKIES "Cookies" - IDS_HISTORY "Configurações locais\\Histórico" + IDS_HISTORY "Configurações locais\\Histórico" IDS_PROGRAM_FILES "Arquivos de programas" IDS_MYPICTURES "Minhas Imagens" IDS_PROGRAM_FILES_COMMON "Arquivos de programas\\Arquivos comuns" IDS_COMMON_DOCUMENTS "Documentos" IDS_ADMINTOOLS "Menu Iniciar\\Programas\\Ferramentas Administrativas" - IDS_COMMON_MUSIC "Documentos\\Minhas Músicas" + IDS_COMMON_MUSIC "Documentos\\Minhas Músicas" IDS_COMMON_PICTURES "Documentos\\Minhas Imagens" - IDS_COMMON_VIDEO "Documentos\\Meus Vídeos" - IDS_CDBURN_AREA "Configurações locais\\Dados de aplicativos\\Microsoft\\CD Burning" + IDS_COMMON_VIDEO "Documentos\\Meus Vídeos" + IDS_CDBURN_AREA "Configurações locais\\Dados de aplicativos\\Microsoft\\CD Burning" IDS_NEWFOLDER "Nova Pasta" @@ -434,56 +376,49 @@ STRINGTABLE IDS_SHV_COLUMN4 "Modificado" IDS_SHV_COLUMN5 "Atributos" IDS_SHV_COLUMN6 "Tamanho" - IDS_SHV_COLUMN7 "Disponível" + IDS_SHV_COLUMN7 "Disponível" IDS_SHV_COLUMN8 "Nome" - IDS_SHV_COLUMN9 "Comentários" + IDS_SHV_COLUMN9 "Comentários" IDS_SHV_COLUMN10 "Dono" IDS_SHV_COLUMN11 "Grupo" - IDS_SHV_COLUMN_DELFROM "Localização original" - IDS_SHV_COLUMN_DELDATE "Data de exclusão" + IDS_SHV_COLUMN_DELFROM "Localização original" + IDS_SHV_COLUMN_DELDATE "Data de exclusão" /* special folders */ IDS_DESKTOP "Ambiente de trabalho" IDS_MYCOMPUTER "O Meu Computador" - IDS_RECYCLEBIN_FOLDER_NAME "Reciclagem" - IDS_CONTROLPANEL "Painel de controlo" /* context menus */ - IDS_VIEW_LARGE "Ícones &grandes" - IDS_VIEW_SMALL "Ícones &pequenos" + IDS_VIEW_LARGE "Ícones &grandes" + IDS_VIEW_SMALL "Ícones &pequenos" IDS_VIEW_LIST "&Lista" IDS_VIEW_DETAILS "&Detalhes" IDS_SELECT "Seleccionar" IDS_OPEN "Abrir" - IDS_CREATEFOLDER_DENIED "Não é possível criar nova pasta: Permissão negada." - IDS_CREATEFOLDER_CAPTION "Erro durante a criação da nova pasta" - IDS_DELETEITEM_CAPTION "Confirmar exclusão do ficheiro" - IDS_DELETEFOLDER_CAPTION "Confirmar exclusão da pasta" + IDS_CREATEFOLDER_DENIED "Não é possível criar nova pasta: Permissão negada." + IDS_CREATEFOLDER_CAPTION "Erro durante a criação da nova pasta" + IDS_DELETEITEM_CAPTION "Confirmar exclusão do ficheiro" + IDS_DELETEFOLDER_CAPTION "Confirmar exclusão da pasta" IDS_DELETEITEM_TEXT "Tem certeza que deseja excluir '%1'?" IDS_DELETEMULTIPLE_TEXT "Tem certeza que deseja excluir estes %1 itens?" - IDS_DELETESELECTED_TEXT "Tem a certeza que deseja excluir os itens seleccionados?" - IDS_TRASHITEM_TEXT "Tem a certeza que quer enviar '%1' para a Reciclagem?" - IDS_TRASHFOLDER_TEXT "Tem a certeza que quer enviar '%1' e todo o seu conteúdo para a Reciclagem?" - IDS_TRASHMULTIPLE_TEXT "Tem a certeza que quer enviar estes %1 itens para a Reciclagem?" - IDS_CANTTRASH_TEXT "O item '%1' não pode ser enviado para a Reciclagem. Deseja apagá-lo em vez disso?" + IDS_DELETESELECTED_TEXT "Are you sure you want to delete the selected item(s)?" + IDS_TRASHITEM_TEXT "Are you sure that you want to send '%1' to the Trash?" + IDS_TRASHFOLDER_TEXT "Are you sure that you want to send '%1' and all its content to the Trash?" + IDS_TRASHMULTIPLE_TEXT "Are you sure that you want to send these %1 items to the Trash?" + IDS_CANTTRASH_TEXT "The item '%1' can't be sent to Trash. Do you want to delete it instead?" IDS_OVERWRITEFILE_TEXT "Substituir ficheiro %1?" - IDS_OVERWRITEFILE_CAPTION "Confirmar substituição de ficheiro" - IDS_OVERWRITEFOLDER_TEXT "Esta pasta já contém uma pasta chamada '%1'.\n\n"\ - "Se os ficheiros na pasta de destino tiverem os mesmos nomes de ficheiros na\n"\ - "pasta seleccionada eles serão substituídos. Ainda deseja mover ou copiar a pasta?" + IDS_OVERWRITEFILE_CAPTION "Confirmar substituição de ficheiro" + IDS_OVERWRITEFOLDER_TEXT "This folder already contains a folder named '%1'.\n\n"\ + "If the files in the destination folder have the same names as files in the\n"\ + "selected folder they will be replaced. Do you still want to move or copy\n"\ + "the folder?" /* message box strings */ IDS_RESTART_TITLE "Reiniciar" - IDS_RESTART_PROMPT "Deseja simular a reinicialização do Windows?" + IDS_RESTART_PROMPT "Deseja simular a reinicialização do Windows?" IDS_SHUTDOWN_TITLE "Desligar" - IDS_SHUTDOWN_PROMPT "Deseja finalizar esta sessão do Wine?" - - /* Run File dialog */ - IDS_RUNDLG_ERROR "Não é possível mostrar a caixa de diálogo Executar Ficheiro (erro interno)" - IDS_RUNDLG_BROWSE_ERROR "Não é possível mostrar a caixa de diálogo de Procura (erro interno)" - IDS_RUNDLG_BROWSE_CAPTION "Procurar" - IDS_RUNDLG_BROWSE_FILTER "Ficheiros Executáveis\0*.exe\0Todos os ficheiros\0*.*\0\0" + IDS_SHUTDOWN_PROMPT "Deseja finalizar esta sessão do Wine?" /* shell folder path default values */ IDS_PROGRAMS "Menu Iniciar\\Programas" @@ -493,48 +428,30 @@ STRINGTABLE IDS_RECENT "Recentes" IDS_SENDTO "Enviar Para" IDS_STARTMENU "Menu Iniciar" - IDS_MYMUSIC "As Minhas Músicas" - IDS_MYVIDEO "Os Meus Vídeos" + IDS_MYMUSIC "As Minhas Músicas" + IDS_MYVIDEO "Os Meus Vídeos" IDS_DESKTOPDIRECTORY "Ambiente de Trabalho" - IDS_NETHOOD "Rede" + IDS_NETHOOD "NetHood" IDS_TEMPLATES "Modelos" - IDS_APPDATA "Dados de aplicação" - IDS_PRINTHOOD "Impressoras" - IDS_LOCAL_APPDATA "Definições locais\\Dados de aplicação" - IDS_INTERNET_CACHE "Definições locais\\Ficheiros temporários de Internet" + IDS_APPDATA "Application Data" + IDS_PRINTHOOD "PrintHood" + IDS_LOCAL_APPDATA "Definições locais\\Application Data" + IDS_INTERNET_CACHE "Definições locais\\Temporary Internet Files" IDS_COOKIES "Cookies" - IDS_HISTORY "Definições locais\\Histórico" + IDS_HISTORY "Definições locais\\Histórico" IDS_PROGRAM_FILES "Programas" IDS_MYPICTURES "As Minhas Imagens" IDS_PROGRAM_FILES_COMMON "Programas\\Ficheiros comuns" IDS_COMMON_DOCUMENTS "Os Meus Documentos" IDS_ADMINTOOLS "Menu Iniciar\\Programas\\Ferramentas Administrativas" - IDS_COMMON_MUSIC "Os Meus Documentos\\As Minhas Músicas" + IDS_COMMON_MUSIC "Os Meus Documentos\\As Minhas Músicas" IDS_COMMON_PICTURES "Os Meus Documentos\\As Minhas Imagens" - IDS_COMMON_VIDEO "Os Meus Documentos\\Os Meus Vídeos" - IDS_CDBURN_AREA "Definições locais\\Dados de aplicação\\Microsoft\\CD Burning" + IDS_COMMON_VIDEO "Os Meus Documentos\\Os Meus Vídeos" + IDS_CDBURN_AREA "Definições locais\\Application Data\\Microsoft\\CD Burning" IDS_NEWFOLDER "Nova Pasta" - IDS_CPANEL_TITLE "Painel de controlo do Wine" - IDS_CPANEL_NAME "Nome" - IDS_CPANEL_DESCRIPTION "Descrição" - IDS_SHLEXEC_NOASSOC "Não existe um programa Windows configurado para abrir este tipo de ficheiro." -} - -STRINGTABLE -{ -IDS_LICENSE_CAPTION, "Licença do Wine" -IDS_LICENSE, -"O Wine é software livre; você pode redistribuí-lo e/ou \ -modificá-lo sob os termos da GNU Lesser General Public \ -License tal como publicado pela Free Software Foundation; seja a \ -versão 2.1 da Licença, ou (por sua escolha) outra versão mais recente.\n\n\ -O Wine é distribuído na esperança que seja útil, \ -mas SEM QUALQUER GARANTIA; nem sequer a garantia implícita de \ -MERCANTIBILIDADE ou FEITO PARA UM PROPÓSITO ESPECÍFICO. veja a GNU \ -Lesser General Public License para mais detalhes.\n\n\ -Deverá ter recebido uma cópia da GNU Lesser General Public \ -License com o Wine; se não, escreva à Free Software \ -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA." + IDS_CPANEL_TITLE "Wine Control Panel" + IDS_CPANEL_NAME "Name" + IDS_CPANEL_DESCRIPTION "Description" } diff --git a/dlls/shell32/shell32_Ro.rc b/dlls/shell32/shell32_Ro.rc index f7a50112715..e1a652eae66 100644 --- a/dlls/shell32/shell32_Ro.rc +++ b/dlls/shell32/shell32_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -28,7 +26,7 @@ BEGIN MENUITEM "Pictograme &mari", FCIDM_SHVIEW_BIGICON MENUITEM "Pictograme m&ici", FCIDM_SHVIEW_SMALLICON MENUITEM "&Listă", FCIDM_SHVIEW_LISTVIEW - MENUITEM "&Detalii", FCIDM_SHVIEW_REPORTVIEW + MENUITEM "&Detailii", FCIDM_SHVIEW_REPORTVIEW END /* @@ -43,7 +41,7 @@ BEGIN MENUITEM "Pictograme &mari", FCIDM_SHVIEW_BIGICON MENUITEM "Pictograme m&ici", FCIDM_SHVIEW_SMALLICON MENUITEM "&Listă", FCIDM_SHVIEW_LISTVIEW - MENUITEM "&Detalii", FCIDM_SHVIEW_REPORTVIEW + MENUITEM "&Detailii", FCIDM_SHVIEW_REPORTVIEW END MENUITEM SEPARATOR POPUP "Aranjează &pictogramele" @@ -55,7 +53,7 @@ BEGIN MENUITEM SEPARATOR MENUITEM "&Aranjează automat", FCIDM_SHVIEW_AUTOARRANGE END - MENUITEM "Aliniază pictogramele", FCIDM_SHVIEW_SNAPTOGRID + MENUITEM "Alinează pictogramele", FCIDM_SHVIEW_SNAPTOGRID MENUITEM SEPARATOR MENUITEM "Actualizează", FCIDM_SHVIEW_REFRESH MENUITEM SEPARATOR @@ -108,7 +106,7 @@ BEGIN MENUITEM "Pictograme &mari", FCIDM_SHVIEW_BIGICON MENUITEM "Pictograme m&ici", FCIDM_SHVIEW_SMALLICON MENUITEM "&Listă", FCIDM_SHVIEW_LISTVIEW - MENUITEM "&Detalii", FCIDM_SHVIEW_REPORTVIEW + MENUITEM "&Detailii", FCIDM_SHVIEW_REPORTVIEW END POPUP "&Help" @@ -189,7 +187,7 @@ FONT 8, "MS Shell Dlg" CONTROL "", 12298, "COMBOBOX", WS_TABSTOP | WS_GROUP | WS_VSCROLL | WS_VISIBLE | CBS_DISABLENOSCROLL | CBS_AUTOHSCROLL | CBS_DROPDOWN, 39, 37, 183, 100 DEFPUSHBUTTON "OK", IDOK, 62, 63, 50, 14, WS_TABSTOP PUSHBUTTON "Renunță", IDCANCEL, 116, 63, 50, 14, WS_TABSTOP - PUSHBUTTON "&Navighează...", 12288, 170, 63, 50, 14, WS_TABSTOP + PUSHBUTTON "&Navigează...", 12288, 170, 63, 50, 14, WS_TABSTOP } STRINGTABLE @@ -199,7 +197,7 @@ STRINGTABLE IDS_SHV_COLUMN2 "Mărime" IDS_SHV_COLUMN3 "Tip" IDS_SHV_COLUMN4 "Modificat" - IDS_SHV_COLUMN5 "Atribute" + IDS_SHV_COLUMN5 "Atributuri" IDS_SHV_COLUMN6 "Mărime" IDS_SHV_COLUMN7 "Spațiu disponibil" IDS_SHV_COLUMN8 "Nume" @@ -213,81 +211,29 @@ STRINGTABLE IDS_DESKTOP "Birou" IDS_MYCOMPUTER "Computerul meu" IDS_RECYCLEBIN_FOLDER_NAME "Gunoi" - IDS_CONTROLPANEL "Panoul de control" + IDS_CONTROLPANEL "Control Panel" /* context menus */ IDS_VIEW_LARGE "Pictograme &mari" IDS_VIEW_SMALL "Pictograme m&ici" IDS_VIEW_LIST "&Listă" - IDS_VIEW_DETAILS "&Detalii" + IDS_VIEW_DETAILS "&Detailii" IDS_SELECT "Selectează" IDS_OPEN "Deschide" - IDS_CREATEFOLDER_DENIED "Nu se poate crea un nou dosar: Permisiune refuzată." - IDS_CREATEFOLDER_CAPTION "Eroare la crearea unui nou dosar" - IDS_DELETEITEM_CAPTION "Confirmați ștergerea fișierului" - IDS_DELETEFOLDER_CAPTION "Confirmați ștergerea dosarului" - IDS_DELETEITEM_TEXT "Sunteți sigur că vreți să ștergeți '%1'?" - IDS_DELETEMULTIPLE_TEXT "Sunteți sigur că vreți să ștergeți acest %1 elemente?" - IDS_DELETESELECTED_TEXT "Sunteți sigur că vreți să ștergeți elementele selectate?" - IDS_TRASHITEM_TEXT "Sunteți sigur că vreți să trimiteți '%1' la gunoi?" - IDS_TRASHFOLDER_TEXT "Sunteți sigur că vreți să trimiteți '%1' și tot conținutul lui la gunoi?" - IDS_TRASHMULTIPLE_TEXT "Sunteți sigur că vreți să trimiteți aceste %1 elemente la gunoi?" - IDS_CANTTRASH_TEXT "Elementul '%1' nu poate fi trimis la gunoi. Vreți să îl ștergeți?" - IDS_OVERWRITEFILE_TEXT "Acest dosar conține deja un fișier numit '%1'.\n\nVreți să îl înlocuiți?" - IDS_OVERWRITEFILE_CAPTION "Confirmați suprascrierea fișierului" - IDS_OVERWRITEFOLDER_TEXT "Acest dosar conține deja un dosar numit '%1'.\n\n"\ - "Dacă fișierele din dosarul destinație au același nume cu fișierele din dosarul\n"\ - "selectat vor fi înlocuite. Mai vreți să mutați sau să copiați dosarul?" - /* message box strings */ IDS_RESTART_TITLE "Repornire" IDS_RESTART_PROMPT "Vreți să simulați o repornire de Windows?" IDS_SHUTDOWN_TITLE "Oprire" IDS_SHUTDOWN_PROMPT "Vreți să opriți sesiunea de Wine?" - /* Run File dialog */ - IDS_RUNDLG_ERROR "Nu se poate afișa caseta de rulare fișier (eroare internă)" - IDS_RUNDLG_BROWSE_ERROR "Nu se poate afișa caseta de navigare (eroare internă)" - IDS_RUNDLG_BROWSE_CAPTION "Navighează" - IDS_RUNDLG_BROWSE_FILTER "Fișiere executabile\0*.exe\0Toate fișierele\0*.*\0\0" - /* shell folder path default values */ - IDS_PROGRAMS "Meniu Start\\Programe" - IDS_PERSONAL "Documentele mele" - IDS_FAVORITES "Favorite" - IDS_STARTUP "Meniu Start\\Programe\\AutoStart" - IDS_RECENT "Recente" - IDS_SENDTO "SendTo" - IDS_STARTMENU "Meniu Start" - IDS_MYMUSIC "Muzica mea" - IDS_MYVIDEO "Filmele mele" - IDS_DESKTOPDIRECTORY "Desktop" - IDS_NETHOOD "NetHood" - IDS_TEMPLATES "Templates" - IDS_APPDATA "Application Data" - IDS_PRINTHOOD "PrintHood" - IDS_LOCAL_APPDATA "Local Settings\\Application Data" - IDS_INTERNET_CACHE "Local Settings\\Temporary Internet Files" - IDS_COOKIES "Cookies" - IDS_HISTORY "Local Settings\\History" - IDS_PROGRAM_FILES "Program Files" - IDS_MYPICTURES "My Pictures" - IDS_PROGRAM_FILES_COMMON "Program Files\\Common Files" - IDS_COMMON_DOCUMENTS "Documente" - IDS_ADMINTOOLS "Meniu Start\\Programe\\Scule administrative" - IDS_COMMON_MUSIC "Documente\\Muzica mea" - IDS_COMMON_PICTURES "Documente\\Pozele mele" - IDS_COMMON_VIDEO "Documente\\Filmele mele" - IDS_CDBURN_AREA "Local Settings\\Application Data\\Microsoft\\CD Burning" + IDS_PROGRAMS "Meniu Start\\Programe" + IDS_PERSONAL "Documentele mele" + IDS_FAVORITES "Favorite" - IDS_NEWFOLDER "Dosar nou" - - IDS_CPANEL_TITLE "Panoul de control al Wine" - IDS_CPANEL_NAME "Nume" - IDS_CPANEL_DESCRIPTION "Descriere" - - IDS_SHLEXEC_NOASSOC "Nici un program Windows nu este configurat să deschidă fișiere de acest tip." + IDS_CPANEL_NAME "Name" + IDS_CPANEL_DESCRIPTION "Description" } STRINGTABLE @@ -306,3 +252,5 @@ 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA." } + +#pragma code_page(default) diff --git a/dlls/shell32/shell32_Ru.rc b/dlls/shell32/shell32_Ru.rc index f8978b92dcd..3bcfefd51fa 100644 --- a/dlls/shell32/shell32_Ru.rc +++ b/dlls/shell32/shell32_Ru.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT MENU_001 MENU DISCARDABLE diff --git a/dlls/shell32/shell32_Si.rc b/dlls/shell32/shell32_Si.rc index 76ad64bf2e9..24db7ee321b 100644 --- a/dlls/shell32/shell32_Si.rc +++ b/dlls/shell32/shell32_Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -282,11 +280,9 @@ STRINGTABLE IDS_NEWFOLDER "Nova mapa" - IDS_CPANEL_TITLE "Wine Nadzorna Plošča" - IDS_CPANEL_NAME "Ime" - IDS_CPANEL_DESCRIPTION "Opis" - - IDS_SHLEXEC_NOASSOC "Noben Okenski program ni nastavljen, da bi odpiral ta tip datotek." + IDS_CPANEL_TITLE "Wine Control Panel" + IDS_CPANEL_NAME "Name" + IDS_CPANEL_DESCRIPTION "Description" } STRINGTABLE @@ -305,3 +301,6 @@ 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA." } + + +#pragma code_page(default) diff --git a/dlls/shell32/shell32_Sk.rc b/dlls/shell32/shell32_Sk.rc index 1cb12384cb8..6ce1f545a1a 100644 --- a/dlls/shell32/shell32_Sk.rc +++ b/dlls/shell32/shell32_Sk.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_SLOVAK, SUBLANG_DEFAULT /* diff --git a/dlls/shell32/shell32_Sv.rc b/dlls/shell32/shell32_Sv.rc index 29453accb63..208ddd5d983 100644 --- a/dlls/shell32/shell32_Sv.rc +++ b/dlls/shell32/shell32_Sv.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL /* diff --git a/dlls/shell32/shell32_Tr.rc b/dlls/shell32/shell32_Tr.rc index c8b038ac46e..dc2ea3096fd 100644 --- a/dlls/shell32/shell32_Tr.rc +++ b/dlls/shell32/shell32_Tr.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT MENU_001 MENU DISCARDABLE diff --git a/dlls/shell32/shell32_Uk.rc b/dlls/shell32/shell32_Uk.rc index 7d1f60a2018..624368ad3fe 100644 --- a/dlls/shell32/shell32_Uk.rc +++ b/dlls/shell32/shell32_Uk.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_UKRAINIAN, SUBLANG_DEFAULT MENU_001 MENU DISCARDABLE diff --git a/dlls/shell32/shell32_Wa.rc b/dlls/shell32/shell32_Wa.rc index 48b188841dc..c92e7d29215 100644 --- a/dlls/shell32/shell32_Wa.rc +++ b/dlls/shell32/shell32_Wa.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - LANGUAGE LANG_WALON, SUBLANG_DEFAULT /* diff --git a/dlls/shell32/shell32_Zh.rc b/dlls/shell32/shell32_Zh.rc index 340b9bd71e2..5cc9af95a70 100644 --- a/dlls/shell32/shell32_Zh.rc +++ b/dlls/shell32/shell32_Zh.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "shresdef.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -211,3 +209,5 @@ BEGIN IDS_CPANEL_NAME "名稱" IDS_CPANEL_DESCRIPTION "描述" END + +#pragma code_page(default) diff --git a/dlls/shell32/shellord.c b/dlls/shell32/shellord.c index 44c9c7eca1b..2fef9408570 100644 --- a/dlls/shell32/shellord.c +++ b/dlls/shell32/shellord.c @@ -1893,6 +1893,33 @@ HRESULT WINAPI SHCreateStdEnumFmtEtc( return hRes; } + +/************************************************************************* + * SHELL32_256 (SHELL32.256) + */ +HRESULT WINAPI SHELL32_256(LPDWORD lpdw0, LPDWORD lpdw1) +{ + HRESULT ret = S_OK; + + FIXME("stub %p 0x%08x %p\n", lpdw0, lpdw0 ? *lpdw0 : 0, lpdw1); + + if (!lpdw0 || *lpdw0 != 0x10) + ret = E_INVALIDARG; + else + { + LPVOID lpdata = 0;/*LocalAlloc(LMEM_ZEROINIT, 0x4E4);*/ + + if (!lpdata) + ret = E_OUTOFMEMORY; + else + { + /* Initialize and return unknown lpdata structure */ + } + } + + return ret; +} + /************************************************************************* * SHFindFiles (SHELL32.90) */ @@ -2113,36 +2140,3 @@ HRESULT WINAPI SHGetImageList(int iImageList, REFIID riid, void **ppv) FIXME("STUB: %i %s\n",iImageList,debugstr_guid(riid)); return E_NOINTERFACE; } - -/************************************************************************* - * SHCreateShellFolderView [SHELL32.256] - * - * Create a new instance of the default Shell folder view object. - * - * RETURNS - * Success: S_OK - * Failure: error value - * - * NOTES - * see IShellFolder::CreateViewObject - */ -HRESULT WINAPI SHCreateShellFolderView(const SFV_CREATE *pcsfv, - IShellView **ppsv) -{ - IShellView * psf; - HRESULT hRes; - - TRACE("sf=%p outer=%p callback=%p\n", - pcsfv->pshf, pcsfv->psvOuter, pcsfv->psfvcb); - - psf = IShellView_Constructor(pcsfv->pshf); - - if (!psf) - return E_OUTOFMEMORY; - - IShellView_AddRef(psf); - hRes = IShellView_QueryInterface(psf, &IID_IShellView, (LPVOID *)ppsv); - IShellView_Release(psf); - - return hRes; -} diff --git a/dlls/shell32/shellpath.c b/dlls/shell32/shellpath.c index 0f07a857b36..2434e9af9a8 100644 --- a/dlls/shell32/shellpath.c +++ b/dlls/shell32/shellpath.c @@ -764,7 +764,6 @@ static const WCHAR Common_Administrative_ToolsW[] = {'C','o','m','m','o','n',' ' static const WCHAR Common_AppDataW[] = {'C','o','m','m','o','n',' ','A','p','p','D','a','t','a','\0'}; static const WCHAR Common_DesktopW[] = {'C','o','m','m','o','n',' ','D','e','s','k','t','o','p','\0'}; static const WCHAR Common_DocumentsW[] = {'C','o','m','m','o','n',' ','D','o','c','u','m','e','n','t','s','\0'}; -static const WCHAR Common_FavoritesW[] = {'C','o','m','m','o','n',' ','F','a','v','o','r','i','t','e','s','\0'}; static const WCHAR CommonFilesDirW[] = {'C','o','m','m','o','n','F','i','l','e','s','D','i','r','\0'}; static const WCHAR CommonMusicW[] = {'C','o','m','m','o','n','M','u','s','i','c','\0'}; static const WCHAR CommonPicturesW[] = {'C','o','m','m','o','n','P','i','c','t','u','r','e','s','\0'}; @@ -813,7 +812,6 @@ typedef enum _CSIDL_Type { CSIDL_Type_NonExistent, CSIDL_Type_WindowsPath, CSIDL_Type_SystemPath, - CSIDL_Type_SystemX86Path, } CSIDL_Type; typedef struct @@ -982,7 +980,7 @@ static const CSIDL_DATA CSIDL_Data[] = }, { /* 0x1f - CSIDL_COMMON_FAVORITES */ CSIDL_Type_AllUsers, - Common_FavoritesW, + FavoritesW, MAKEINTRESOURCEW(IDS_FAVORITES) }, { /* 0x20 - CSIDL_INTERNET_CACHE */ @@ -1031,7 +1029,7 @@ static const CSIDL_DATA CSIDL_Data[] = NULL }, { /* 0x29 - CSIDL_SYSTEMX86 */ - CSIDL_Type_SystemX86Path, + CSIDL_Type_NonExistent, NULL, NULL }, @@ -1784,17 +1782,6 @@ HRESULT WINAPI SHGetFolderPathAndSubDirW( } hr = S_OK; break; - case CSIDL_Type_SystemX86Path: - if (!GetSystemWow64DirectoryW(szTemp, MAX_PATH)) GetSystemDirectoryW(szTemp, MAX_PATH); - if (CSIDL_Data[folder].szDefaultPath && - !IS_INTRESOURCE(CSIDL_Data[folder].szDefaultPath) && - *CSIDL_Data[folder].szDefaultPath) - { - PathAddBackslashW(szTemp); - strcatW(szTemp, CSIDL_Data[folder].szDefaultPath); - } - hr = S_OK; - break; case CSIDL_Type_CurrVer: hr = _SHGetCurrentVersionPath(dwFlags, folder, szTemp); break; @@ -2042,10 +2029,6 @@ static HRESULT _SHRegisterCommonShellFolders(void) CSIDL_COMMON_APPDATA, CSIDL_COMMON_TEMPLATES, CSIDL_COMMON_DOCUMENTS, - CSIDL_COMMON_ADMINTOOLS, - CSIDL_COMMON_MUSIC, - CSIDL_COMMON_PICTURES, - CSIDL_COMMON_VIDEO, }; HRESULT hr; diff --git a/dlls/shell32/shfldr_desktop.c b/dlls/shell32/shfldr_desktop.c index a08bb41110a..c9b74123d1b 100644 --- a/dlls/shell32/shfldr_desktop.c +++ b/dlls/shell32/shfldr_desktop.c @@ -187,19 +187,7 @@ static HRESULT WINAPI ISF_Desktop_fnParseDisplayName (IShellFolder2 * iface, } else if (strchrW(lpszDisplayName,':')) { - PARSEDURLW urldata; - - urldata.cbSize = sizeof(urldata); - ParseURLW(lpszDisplayName,&urldata); - - if (urldata.nScheme == URL_SCHEME_SHELL) /* handle shell: urls */ - { - TRACE ("-- shell url: %s\n", debugstr_w(urldata.pszSuffix)); - SHCLSIDFromStringW (urldata.pszSuffix+2, &clsid); - pidlTemp = _ILCreateGuid (PT_GUID, &clsid); - } - else - return IEParseDisplayNameWithBCW(CP_ACP,lpszDisplayName,pbc,ppidl); + return IEParseDisplayNameWithBCW(CP_ACP,lpszDisplayName,pbc,ppidl); } else { diff --git a/dlls/shell32/shres.rc b/dlls/shell32/shres.rc index 8e76a092aca..25b1a2fa9c4 100644 --- a/dlls/shell32/shres.rc +++ b/dlls/shell32/shres.rc @@ -18,7 +18,16 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winnls.h" +#include "wingdi.h" +#include "shlobj.h" #include "shresdef.h" +#include "dlgs.h" + +#include "version.rc" LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL @@ -122,3 +131,40 @@ IDR_AVI_FILENUKE AVI searching.avi /* @makedep: searching.avi */ IDR_AVI_FILEDELETE AVI searching.avi + + +/* + * Everything specific to any language goes + * in one of the specific files. + * Note that you can and may override resources + * which also have a neutral version. This is to + * get localized bitmaps for example. + */ +#include "shell32_Bg.rc" +#include "shell32_Ca.rc" +#include "shell32_Cs.rc" +#include "shell32_Da.rc" +#include "shell32_De.rc" +#include "shell32_En.rc" +#include "shell32_Eo.rc" +#include "shell32_Es.rc" +#include "shell32_Fi.rc" +#include "shell32_Fr.rc" +#include "shell32_Hu.rc" +#include "shell32_It.rc" +#include "shell32_Ja.rc" +#include "shell32_Ko.rc" +#include "shell32_Lt.rc" +#include "shell32_Nl.rc" +#include "shell32_No.rc" +#include "shell32_Pl.rc" +#include "shell32_Pt.rc" +#include "shell32_Ro.rc" +#include "shell32_Ru.rc" +#include "shell32_Si.rc" +#include "shell32_Sk.rc" +#include "shell32_Sv.rc" +#include "shell32_Tr.rc" +#include "shell32_Uk.rc" +#include "shell32_Wa.rc" +#include "shell32_Zh.rc" diff --git a/dlls/shell32/shresdef.h b/dlls/shell32/shresdef.h index 2880135057e..01ec9775280 100644 --- a/dlls/shell32/shresdef.h +++ b/dlls/shell32/shresdef.h @@ -19,13 +19,6 @@ #ifndef __WINE_SHELL_RES_H #define __WINE_SHELL_RES_H -#include -#include -#include -#include -#include -#include - /* columntitles for the shellview */ diff --git a/dlls/shell32/tests/shellpath.c b/dlls/shell32/tests/shellpath.c index b5b196747ac..4cacb087bb9 100644 --- a/dlls/shell32/tests/shellpath.c +++ b/dlls/shell32/tests/shellpath.c @@ -89,7 +89,6 @@ static HRESULT (WINAPI *pSHGetSpecialFolderLocation)(HWND, int, LPITEMIDLIST *); static LPITEMIDLIST (WINAPI *pILFindLastID)(LPCITEMIDLIST); static int (WINAPI *pSHFileOperationA)(LPSHFILEOPSTRUCTA); static HRESULT (WINAPI *pSHGetMalloc)(LPMALLOC *); -static UINT (WINAPI *pGetSystemWow64DirectoryA)(LPSTR,UINT); static DLLVERSIONINFO shellVersion = { 0 }; static LPMALLOC pMalloc; static const BYTE guidType[] = { PT_GUID }; @@ -685,17 +684,10 @@ static void testSystemDir(void) "GetSystemDirectory returns %s SHGetSpecialFolderPath returns %s\n", systemDir, systemShellPath); } - - if (!pGetSystemWow64DirectoryA || !pGetSystemWow64DirectoryA(systemDir, sizeof(systemDir))) - GetSystemDirectoryA(systemDir, sizeof(systemDir)); - myPathRemoveBackslashA(systemDir); - if (pSHGetSpecialFolderPathA(NULL, systemShellPath, CSIDL_SYSTEMX86, FALSE)) - { - myPathRemoveBackslashA(systemShellPath); - ok(!lstrcmpiA(systemDir, systemShellPath), - "GetSystemDirectory returns %s SHGetSpecialFolderPath returns %s\n", - systemDir, systemShellPath); - } + /* CSIDL_SYSTEMX86 isn't checked in the same way, since it's different + * on Win64 (and non-x86 Windows systems, if there are any still in + * existence) than on Win32. + */ } /* Globals used by subprocesses */ @@ -879,8 +871,6 @@ START_TEST(shellpath) if (!init()) return; loadShell32(); - pGetSystemWow64DirectoryA = (void *)GetProcAddress( GetModuleHandleA("kernel32.dll"), - "GetSystemWow64DirectoryA" ); if (myARGC >= 3) doChild(myARGV[2]); diff --git a/dlls/shell32/tests/shfldr_special.c b/dlls/shell32/tests/shfldr_special.c index 06533ba8b95..8c14e517d4b 100644 --- a/dlls/shell32/tests/shfldr_special.c +++ b/dlls/shell32/tests/shfldr_special.c @@ -46,6 +46,7 @@ static void test_parse_for_entire_network(void) LPITEMIDLIST pidl; DWORD attr = ~0; DWORD expected_attr; + DWORD alter_attr; hr = SHGetDesktopFolder(&psfDesktop); ok(hr == S_OK, "SHGetDesktopFolder failed with error 0x%x\n", hr); @@ -69,9 +70,7 @@ static void test_parse_for_entire_network(void) attr = ~0; hr = IShellFolder_ParseDisplayName(psfDesktop, NULL, NULL, entire_network_path, &eaten, &pidl, &attr); - if (hr == HRESULT_FROM_WIN32(ERROR_BAD_NET_NAME) || - hr == HRESULT_FROM_WIN32(ERROR_NO_NET_OR_BAD_PATH) || - hr == HRESULT_FROM_WIN32(ERROR_INVALID_PARAMETER)) + if (hr == HRESULT_FROM_WIN32(ERROR_BAD_NET_NAME) || hr == HRESULT_FROM_WIN32(ERROR_INVALID_PARAMETER)) { win_skip("'EntireNetwork' is not available on Win9x, NT4 and Vista\n"); return; @@ -79,12 +78,12 @@ static void test_parse_for_entire_network(void) ok(hr == S_OK, "IShellFolder_ParseDisplayName failed with error 0x%x\n", hr); todo_wine ok(eaten == 0xdeadbeef, "eaten should not have been set to %u\n", eaten); - expected_attr = SFGAO_HASSUBFOLDER|SFGAO_FOLDER|SFGAO_FILESYSANCESTOR|SFGAO_HASPROPSHEET|SFGAO_CANLINK; + expected_attr = SFGAO_HASSUBFOLDER|SFGAO_FOLDER|SFGAO_FILESYSANCESTOR|SFGAO_STORAGEANCESTOR|SFGAO_HASPROPSHEET|SFGAO_CANLINK; + alter_attr = (expected_attr & (~SFGAO_STORAGEANCESTOR)) | SFGAO_STREAM; todo_wine - ok(attr == expected_attr || /* winme, nt4 */ - attr == (expected_attr | SFGAO_STREAM) || /* win2k */ - attr == (expected_attr | SFGAO_STORAGEANCESTOR), /* others */ - "attr should be 0x%x, not 0x%x\n", expected_attr, attr); + ok(attr == expected_attr || + attr == alter_attr, /* win2k */ + "attr should be 0x%x or 0x%x, not 0x%x\n", expected_attr, alter_attr, attr); ILFree(pidl); } diff --git a/dlls/shell32/tests/shlexec.c b/dlls/shell32/tests/shlexec.c index 5f0776adc0b..6edc9263618 100644 --- a/dlls/shell32/tests/shlexec.c +++ b/dlls/shell32/tests/shlexec.c @@ -864,7 +864,8 @@ static void test_find_executable(void) ok(rc == SE_ERR_NOASSOC /* >= win2000 */ || rc > 32 /* win98, nt4 */, "FindExecutable(NULL) returned %ld\n", rc); ok(strcmp(command, "your word") != 0, "FindExecutable(NULL) returned command=[%s]\n", command); - sprintf(filename, "%s\\test file.sfe", tmpdir); + /* Win95 can't cope with double backslashes in FindExecutableA (tmpdir has a trailing backslash) */ + sprintf(filename, "%stest file.sfe", tmpdir); rc=(INT_PTR)FindExecutableA(filename, NULL, command); ok(rc > 32, "FindExecutable(%s) returned %ld\n", filename, rc); /* Depending on the platform, command could be '%1' or 'test file.sfe' */ @@ -910,6 +911,10 @@ static void test_find_executable(void) test=filename_tests; while (test->basename) { + /* Win95 can't cope with double slashes/backslashes in FindExecutableA */ + if (tmpdir[strlen(tmpdir) - 1] == '\\') + tmpdir[strlen(tmpdir) - 1] = 0; + sprintf(filename, test->basename, tmpdir); if (strchr(filename, '/')) { @@ -1522,13 +1527,8 @@ static void init_test(void) "unable to find argv0!\n"); } - GetTempPathA(sizeof(filename), filename); - GetTempFileNameA(filename, "wt", 0, tmpdir); - DeleteFileA( tmpdir ); - rc = CreateDirectoryA( tmpdir, NULL ); - ok( rc, "failed to create %s err %u\n", tmpdir, GetLastError() ); - rc = GetTempFileNameA(tmpdir, "wt", 0, child_file); - assert(rc != 0); + GetTempPathA(sizeof(tmpdir)/sizeof(*tmpdir), tmpdir); + assert(GetTempFileNameA(tmpdir, "wt", 0, child_file)!=0); init_event(child_file); /* Set up the test files */ @@ -1608,7 +1608,6 @@ static void cleanup_test(void) testfile++; } DeleteFile(child_file); - RemoveDirectoryA(tmpdir); /* Delete the test association */ delete_test_association(".shlexec"); diff --git a/dlls/shell32/tests/shlfolder.c b/dlls/shell32/tests/shlfolder.c index 535c9ada568..74873765f00 100644 --- a/dlls/shell32/tests/shlfolder.c +++ b/dlls/shell32/tests/shlfolder.c @@ -1565,21 +1565,21 @@ static void testSHGetFolderPathAndSubDirA(void) } if(FAILED(pSHGetFolderPathA(NULL, CSIDL_LOCAL_APPDATA, NULL, SHGFP_TYPE_CURRENT, appdata))) { - win_skip("SHGetFolderPathA failed for CSIDL_LOCAL_APPDATA!\n"); + skip("SHGetFolderPathA failed for CSIDL_LOCAL_APPDATA!\n"); return; } sprintf(testpath, "%s\\%s", appdata, winetemp); delret = RemoveDirectoryA(testpath); if(!delret && (ERROR_PATH_NOT_FOUND != GetLastError()) ) { - win_skip("RemoveDirectoryA(%s) failed with error %u\n", testpath, GetLastError()); + skip("RemoveDirectoryA(%s) failed with error %u\n", testpath, GetLastError()); return; } sprintf(testpath, "%s\\%s", appdata, wine); delret = RemoveDirectoryA(testpath); if(!delret && (ERROR_PATH_NOT_FOUND != GetLastError()) && (ERROR_FILE_NOT_FOUND != GetLastError())) { - win_skip("RemoveDirectoryA(%s) failed with error %u\n", testpath, GetLastError()); + skip("RemoveDirectoryA(%s) failed with error %u\n", testpath, GetLastError()); return; } @@ -1695,7 +1695,7 @@ static void test_LocalizedNames(void) len = lstrlenA(cCurrDirA); if (len == 0) { - win_skip("GetCurrentDirectoryA returned empty string. Skipping test_LocalizedNames\n"); + trace("GetCurrentDirectoryA returned empty string. Skipping test_LocalizedNames\n"); goto cleanup; } if(cCurrDirA[len-1] == '\\') @@ -1944,12 +1944,12 @@ START_TEST(shlfolder) if(pSHGetFolderPathAndSubDirA) testSHGetFolderPathAndSubDirA(); else - win_skip("SHGetFolderPathAndSubDirA not present\n"); + skip("SHGetFolderPathAndSubDirA not present\n"); test_LocalizedNames(); if(pSHCreateShellItem) test_SHCreateShellItem(); else - win_skip("SHCreateShellItem not present\n"); + win_skip("test_SHCreateShellItem not present\n"); OleUninitialize(); } diff --git a/dlls/shlwapi/Makefile.in b/dlls/shlwapi/Makefile.in index 20329f686fc..bafe9f27e39 100644 --- a/dlls/shlwapi/Makefile.in +++ b/dlls/shlwapi/Makefile.in @@ -25,31 +25,7 @@ C_SRCS = \ wsprintf.c RC_SRCS = \ - shlwapi_Da.rc \ - shlwapi_De.rc \ - shlwapi_En.rc \ - shlwapi_Eo.rc \ - shlwapi_Es.rc \ - shlwapi_Fi.rc \ - shlwapi_Fr.rc \ - shlwapi_Hu.rc \ - shlwapi_It.rc \ - shlwapi_Ja.rc \ - shlwapi_Ko.rc \ - shlwapi_Lt.rc \ - shlwapi_Nl.rc \ - shlwapi_No.rc \ - shlwapi_Pl.rc \ - shlwapi_Pt.rc \ - shlwapi_Ro.rc \ - shlwapi_Ru.rc \ - shlwapi_Si.rc \ - shlwapi_Sk.rc \ - shlwapi_Sv.rc \ - shlwapi_Tr.rc \ - shlwapi_Uk.rc \ - shlwapi_Zh.rc \ - version.rc + shlwapi.rc @MAKE_DLL_RULES@ diff --git a/dlls/shlwapi/resource.h b/dlls/shlwapi/resource.h index ac53357358e..e0ca08c5dc6 100644 --- a/dlls/shlwapi/resource.h +++ b/dlls/shlwapi/resource.h @@ -20,9 +20,6 @@ #ifndef WINE_SHLWAPI_RESOURCE_H #define WINE_SHLWAPI_RESOURCE_H -#include -#include - #define IDS_BYTES_FORMAT 64 #define IDS_TIME_INTERVAL_HOURS 65 #define IDS_TIME_INTERVAL_MINUTES 66 diff --git a/dlls/shlwapi/shlwapi.rc b/dlls/shlwapi/shlwapi.rc new file mode 100644 index 00000000000..d159dab2290 --- /dev/null +++ b/dlls/shlwapi/shlwapi.rc @@ -0,0 +1,50 @@ +/* + * Top level resource file for shlwapi + * + * Copyright 2004 Jon Griffiths + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "resource.h" + +#include "version.rc" + +#include "shlwapi_Da.rc" +#include "shlwapi_De.rc" +#include "shlwapi_En.rc" +#include "shlwapi_Eo.rc" +#include "shlwapi_Es.rc" +#include "shlwapi_Fi.rc" +#include "shlwapi_Fr.rc" +#include "shlwapi_Hu.rc" +#include "shlwapi_It.rc" +#include "shlwapi_Ja.rc" +#include "shlwapi_Ko.rc" +#include "shlwapi_Nl.rc" +#include "shlwapi_No.rc" +#include "shlwapi_Pl.rc" +#include "shlwapi_Pt.rc" +#include "shlwapi_Ro.rc" +#include "shlwapi_Ru.rc" +#include "shlwapi_Si.rc" +#include "shlwapi_Sk.rc" +#include "shlwapi_Sv.rc" +#include "shlwapi_Tr.rc" +#include "shlwapi_Uk.rc" +#include "shlwapi_Zh.rc" diff --git a/dlls/shlwapi/shlwapi.spec b/dlls/shlwapi/shlwapi.spec index b6426e784db..b7ea3aa6fff 100644 --- a/dlls/shlwapi/shlwapi.spec +++ b/dlls/shlwapi/shlwapi.spec @@ -215,7 +215,7 @@ 215 stdcall -noname SHAnsiToUnicode(str ptr long) 216 stdcall -noname SHAnsiToUnicodeCP(long str ptr long) 217 stdcall -noname SHUnicodeToAnsi(wstr ptr ptr) -218 stdcall -noname SHUnicodeToAnsiCP(long wstr ptr long) +218 stdcall -noname SHUnicodeToAnsiCP(long wstr ptr ptr) 219 stdcall -noname QISearch(long long long long) 220 stdcall -noname SHSetDefaultDialogFont(ptr long) 221 stdcall -noname SHRemoveDefaultDialogFont(ptr) @@ -477,7 +477,7 @@ 477 stub -noname SHCreatePropertyBagOnMemory 478 stdcall -noname IUnknown_TranslateAcceleratorIO(ptr ptr) 479 stub -noname IUnknown_UIActivateIO -480 stdcall -noname UrlCrackW(wstr long long ptr) wininet.InternetCrackUrlW +480 stub -noname UrlCrackW 481 stdcall -noname IUnknown_HasFocusIO(ptr) 482 stub -noname SHMessageBoxHelpA 483 stub -noname SHMessageBoxHelpW diff --git a/dlls/shlwapi/shlwapi_Da.rc b/dlls/shlwapi/shlwapi_Da.rc index 3bb418da2b8..4ed0e61999b 100644 --- a/dlls/shlwapi/shlwapi_Da.rc +++ b/dlls/shlwapi/shlwapi_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_De.rc b/dlls/shlwapi/shlwapi_De.rc index f74600fdf06..eaad902bff8 100644 --- a/dlls/shlwapi/shlwapi_De.rc +++ b/dlls/shlwapi/shlwapi_De.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_En.rc b/dlls/shlwapi/shlwapi_En.rc index 4e1d935cfca..5a327f0e006 100644 --- a/dlls/shlwapi/shlwapi_En.rc +++ b/dlls/shlwapi/shlwapi_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Eo.rc b/dlls/shlwapi/shlwapi_Eo.rc index ce7833d6953..71b3710f6d5 100644 --- a/dlls/shlwapi/shlwapi_Eo.rc +++ b/dlls/shlwapi/shlwapi_Eo.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Es.rc b/dlls/shlwapi/shlwapi_Es.rc index 8d351f680fd..3a325db2c07 100644 --- a/dlls/shlwapi/shlwapi_Es.rc +++ b/dlls/shlwapi/shlwapi_Es.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Fi.rc b/dlls/shlwapi/shlwapi_Fi.rc index 877228f3393..ea9b3950845 100644 --- a/dlls/shlwapi/shlwapi_Fi.rc +++ b/dlls/shlwapi/shlwapi_Fi.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Fr.rc b/dlls/shlwapi/shlwapi_Fr.rc index 745b4fd0ee0..842a67cb33e 100644 --- a/dlls/shlwapi/shlwapi_Fr.rc +++ b/dlls/shlwapi/shlwapi_Fr.rc @@ -18,16 +18,11 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Erreur !" +CAPTION "Erreur!" FONT 8, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 diff --git a/dlls/shlwapi/shlwapi_Hu.rc b/dlls/shlwapi/shlwapi_Hu.rc index 56535e8927b..9aa253e45ba 100644 --- a/dlls/shlwapi/shlwapi_Hu.rc +++ b/dlls/shlwapi/shlwapi_Hu.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_It.rc b/dlls/shlwapi/shlwapi_It.rc index e7a984eaa9a..b62f4940abd 100644 --- a/dlls/shlwapi/shlwapi_It.rc +++ b/dlls/shlwapi/shlwapi_It.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Ja.rc b/dlls/shlwapi/shlwapi_Ja.rc index 4b9c6ae5255..accd716df23 100644 --- a/dlls/shlwapi/shlwapi_Ja.rc +++ b/dlls/shlwapi/shlwapi_Ja.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -46,3 +44,5 @@ STRINGTABLE DISCARDABLE IDS_TIME_INTERVAL_MINUTES " min" IDS_TIME_INTERVAL_SECONDS " sec" } + +#pragma code_page(default) diff --git a/dlls/shlwapi/shlwapi_Ko.rc b/dlls/shlwapi/shlwapi_Ko.rc index 3526cac6a04..8a44a6610f5 100644 --- a/dlls/shlwapi/shlwapi_Ko.rc +++ b/dlls/shlwapi/shlwapi_Ko.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Lt.rc b/dlls/shlwapi/shlwapi_Lt.rc deleted file mode 100644 index 264f6f64eb4..00000000000 --- a/dlls/shlwapi/shlwapi_Lt.rc +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Lithuanian resources for shlwapi - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 -STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Klaida!" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 - LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 - CHECKBOX "Daugiau ne&rodyti šio pranešimo", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Gerai" IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Atsisakyti" IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Taip" IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Ne" IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP -} - -STRINGTABLE DISCARDABLE -{ - IDS_BYTES_FORMAT "%ld baitai" - IDS_TIME_INTERVAL_HOURS " val" - IDS_TIME_INTERVAL_MINUTES " min" - IDS_TIME_INTERVAL_SECONDS " sek" -} diff --git a/dlls/shlwapi/shlwapi_Nl.rc b/dlls/shlwapi/shlwapi_Nl.rc index 0c9e3cb6df0..c7ac3e7d131 100644 --- a/dlls/shlwapi/shlwapi_Nl.rc +++ b/dlls/shlwapi/shlwapi_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_No.rc b/dlls/shlwapi/shlwapi_No.rc index 9a99ac3feea..4df42c87dd0 100644 --- a/dlls/shlwapi/shlwapi_No.rc +++ b/dlls/shlwapi/shlwapi_No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Pl.rc b/dlls/shlwapi/shlwapi_Pl.rc index 8a0032c58cf..467ee8d1f76 100644 --- a/dlls/shlwapi/shlwapi_Pl.rc +++ b/dlls/shlwapi/shlwapi_Pl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Pt.rc b/dlls/shlwapi/shlwapi_Pt.rc index 9974fd673bc..839fa13c500 100644 --- a/dlls/shlwapi/shlwapi_Pt.rc +++ b/dlls/shlwapi/shlwapi_Pt.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Ro.rc b/dlls/shlwapi/shlwapi_Ro.rc index 800f25971e9..9b6278fbf95 100644 --- a/dlls/shlwapi/shlwapi_Ro.rc +++ b/dlls/shlwapi/shlwapi_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -44,3 +42,5 @@ STRINGTABLE DISCARDABLE IDS_TIME_INTERVAL_MINUTES " min" IDS_TIME_INTERVAL_SECONDS " sec" } + +#pragma code_page(default) diff --git a/dlls/shlwapi/shlwapi_Ru.rc b/dlls/shlwapi/shlwapi_Ru.rc index 47479e22ac3..87aee4acb8a 100644 --- a/dlls/shlwapi/shlwapi_Ru.rc +++ b/dlls/shlwapi/shlwapi_Ru.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Si.rc b/dlls/shlwapi/shlwapi_Si.rc index 820b6ce5ed1..ed5a92e787a 100644 --- a/dlls/shlwapi/shlwapi_Si.rc +++ b/dlls/shlwapi/shlwapi_Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -45,3 +43,5 @@ STRINGTABLE DISCARDABLE IDS_TIME_INTERVAL_MINUTES " min" IDS_TIME_INTERVAL_SECONDS " sek" } + +#pragma code_page(default) diff --git a/dlls/shlwapi/shlwapi_Sk.rc b/dlls/shlwapi/shlwapi_Sk.rc index c44ca3f39fa..e5479e90d4c 100644 --- a/dlls/shlwapi/shlwapi_Sk.rc +++ b/dlls/shlwapi/shlwapi_Sk.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SLOVAK, SUBLANG_DEFAULT IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Sv.rc b/dlls/shlwapi/shlwapi_Sv.rc index 6a0d52bc996..6e13b91cae9 100644 --- a/dlls/shlwapi/shlwapi_Sv.rc +++ b/dlls/shlwapi/shlwapi_Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Tr.rc b/dlls/shlwapi/shlwapi_Tr.rc index 58515962719..15453623df3 100644 --- a/dlls/shlwapi/shlwapi_Tr.rc +++ b/dlls/shlwapi/shlwapi_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Uk.rc b/dlls/shlwapi/shlwapi_Uk.rc index c14a7ce13dc..a8a1e3d9fc8 100644 --- a/dlls/shlwapi/shlwapi_Uk.rc +++ b/dlls/shlwapi/shlwapi_Uk.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_UKRAINIAN, SUBLANG_DEFAULT IDD_ERR_DIALOG DIALOG MOVEABLE DISCARDABLE 0, 0, 220, 60 diff --git a/dlls/shlwapi/shlwapi_Zh.rc b/dlls/shlwapi/shlwapi_Zh.rc index 0a1d9a62bf2..842bb15f8cc 100644 --- a/dlls/shlwapi/shlwapi_Zh.rc +++ b/dlls/shlwapi/shlwapi_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -70,3 +68,5 @@ STRINGTABLE DISCARDABLE IDS_TIME_INTERVAL_MINUTES " 分" IDS_TIME_INTERVAL_SECONDS " 秒" } + +#pragma code_page(default) diff --git a/dlls/shlwapi/string.c b/dlls/shlwapi/string.c index 755360d790a..da0dee3cfd2 100644 --- a/dlls/shlwapi/string.c +++ b/dlls/shlwapi/string.c @@ -2477,24 +2477,20 @@ DWORD WINAPI SHAnsiToUnicode(LPCSTR lpSrcStr, LPWSTR lpDstStr, int iLen) * CodePage [I] Code page to use for the conversion * lpSrcStr [I] Source Unicode string to convert * lpDstStr [O] Destination for converted Ascii string - * dstlen [I] Length of buffer at lpDstStr + * lpiLen [I/O] Input length of lpDstStr/destination for length of lpDstStr * * RETURNS - * Success: The length in bytes of the result at lpDstStr (including the terminator) - * Failure: When using CP_UTF8, CP_UTF7 or 0xc350 as codePage, 0 is returned and - * the result is not nul-terminated. - * When using a different codepage, the length in bytes of the truncated - * result at lpDstStr (including the terminator) is returned and - * lpDstStr is always nul-terminated. - * + * Success: The number of characters that result from the conversion. + * Failure: 0. */ -DWORD WINAPI SHUnicodeToAnsiCP(UINT CodePage, LPCWSTR lpSrcStr, LPSTR lpDstStr, int dstlen) +INT WINAPI SHUnicodeToAnsiCP(UINT CodePage, LPCWSTR lpSrcStr, LPSTR lpDstStr, + LPINT lpiLen) { static const WCHAR emptyW[] = { '\0' }; int len , reqLen; LPSTR mem; - if (!lpDstStr || !dstlen) + if (!lpDstStr || !lpiLen) return 0; if (!lpSrcStr) @@ -2513,41 +2509,41 @@ DWORD WINAPI SHUnicodeToAnsiCP(UINT CodePage, LPCWSTR lpSrcStr, LPSTR lpDstStr, case CP_UTF8: { DWORD dwMode = 0; - INT lenW = len - 1; - INT needed = dstlen - 1; - HRESULT hr; - - /* try the user supplied buffer first */ - hr = ConvertINetUnicodeToMultiByte(&dwMode, CodePage, lpSrcStr, &lenW, lpDstStr, &needed); - if (hr == S_OK) - { - lpDstStr[needed] = '\0'; - return needed + 1; - } + INT nWideCharCount = len - 1; - /* user buffer too small. exclude termination and copy as much as possible */ - lenW = len; - hr = ConvertINetUnicodeToMultiByte(&dwMode, CodePage, lpSrcStr, &lenW, NULL, &needed); - needed++; - mem = HeapAlloc(GetProcessHeap(), 0, needed); - if (!mem) + if (ConvertINetUnicodeToMultiByte(&dwMode, CodePage, lpSrcStr, + &nWideCharCount, lpDstStr, + lpiLen) == S_OK) return 0; - hr = ConvertINetUnicodeToMultiByte(&dwMode, CodePage, lpSrcStr, &len, mem, &needed); - if (hr == S_OK) + if (nWideCharCount < len - 1) { - reqLen = SHTruncateString(mem, dstlen); - if (reqLen > 0) memcpy(lpDstStr, mem, reqLen-1); + mem = HeapAlloc(GetProcessHeap(), 0, *lpiLen); + if (!mem) + return 0; + + *lpiLen = 0; + + if (ConvertINetUnicodeToMultiByte(&dwMode, CodePage, lpSrcStr, &len, + mem, lpiLen) != S_OK) + { + SHTruncateString(mem, *lpiLen); + lstrcpynA(lpDstStr, mem, *lpiLen + 1); + HeapFree(GetProcessHeap(), 0, mem); + return *lpiLen + 1; + } + HeapFree(GetProcessHeap(), 0, mem); + return *lpiLen; } - HeapFree(GetProcessHeap(), 0, mem); - return 0; + lpDstStr[*lpiLen] = '\0'; + return *lpiLen; } default: break; } - /* try the user supplied buffer first */ - reqLen = WideCharToMultiByte(CodePage, 0, lpSrcStr, len, lpDstStr, dstlen, NULL, NULL); + reqLen = WideCharToMultiByte(CodePage, 0, lpSrcStr, len, lpDstStr, + *lpiLen, NULL, NULL); if (!reqLen && GetLastError() == ERROR_INSUFFICIENT_BUFFER) { @@ -2560,12 +2556,12 @@ DWORD WINAPI SHUnicodeToAnsiCP(UINT CodePage, LPCWSTR lpSrcStr, LPSTR lpDstStr, reqLen = WideCharToMultiByte(CodePage, 0, lpSrcStr, len, mem, reqLen, NULL, NULL); - reqLen = SHTruncateString(mem, dstlen -1); + reqLen = SHTruncateString(mem, *lpiLen); reqLen++; - lstrcpynA(lpDstStr, mem, reqLen); + lstrcpynA(lpDstStr, mem, *lpiLen); + HeapFree(GetProcessHeap(), 0, mem); - lpDstStr[reqLen-1] = '\0'; } } } @@ -2590,7 +2586,9 @@ DWORD WINAPI SHUnicodeToAnsiCP(UINT CodePage, LPCWSTR lpSrcStr, LPSTR lpDstStr, */ INT WINAPI SHUnicodeToAnsi(LPCWSTR lpSrcStr, LPSTR lpDstStr, INT iLen) { - return SHUnicodeToAnsiCP(CP_ACP, lpSrcStr, lpDstStr, iLen); + INT myint = iLen; + + return SHUnicodeToAnsiCP(CP_ACP, lpSrcStr, lpDstStr, &myint); } /************************************************************************* diff --git a/dlls/sound.drv16/Makefile.in b/dlls/sound.drv16/Makefile.in index 8e43a7d443b..e61efec816f 100644 --- a/dlls/sound.drv16/Makefile.in +++ b/dlls/sound.drv16/Makefile.in @@ -6,6 +6,8 @@ MODULE = sound.drv16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,winmm.dll +SPEC_SRCS = sound.drv16.spec + C_SRCS = sound.c @MAKE_DLL_RULES@ diff --git a/dlls/spoolss/Makefile.in b/dlls/spoolss/Makefile.in index 646a11d6f7e..00fc258acc9 100644 --- a/dlls/spoolss/Makefile.in +++ b/dlls/spoolss/Makefile.in @@ -6,7 +6,7 @@ MODULE = spoolss.dll IMPORTLIB = spoolss IMPORTS = winspool kernel32 -C_SRCS = \ +C_SRCS = \ router.c \ spoolss_main.c diff --git a/dlls/storage.dll16/Makefile.in b/dlls/storage.dll16/Makefile.in index 66768fab12e..f8794fbe722 100644 --- a/dlls/storage.dll16/Makefile.in +++ b/dlls/storage.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = storage.dll16 IMPORTS = uuid ole32 kernel32 ntdll EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,ole32.dll +SPEC_SRCS = storage.dll16.spec + C_SRCS = storage.c @MAKE_DLL_RULES@ diff --git a/dlls/stress.dll16/Makefile.in b/dlls/stress.dll16/Makefile.in index e4f17ac02ea..1d45fc01515 100644 --- a/dlls/stress.dll16/Makefile.in +++ b/dlls/stress.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = stress.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16 +SPEC_SRCS = stress.dll16.spec + C_SRCS = stress.c @MAKE_DLL_RULES@ diff --git a/dlls/t2embed/main.c b/dlls/t2embed/main.c index c9c5dc53551..89622485bd0 100644 --- a/dlls/t2embed/main.c +++ b/dlls/t2embed/main.c @@ -24,10 +24,6 @@ #include "windef.h" #include "winbase.h" -#include "t2embapi.h" -#include "wine/debug.h" - -WINE_DEFAULT_DEBUG_CHANNEL(t2embed); BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) { @@ -45,17 +41,3 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) return TRUE; } - -LONG WINAPI TTLoadEmbeddedFont(HANDLE *phFontReference, ULONG ulFlags, - ULONG *pulPrivStatus, ULONG ulPrivs, - ULONG *pulStatus, READEMBEDPROC lpfnReadFromStream, - LPVOID lpvReadStream, LPWSTR szWinFamilyName, - LPSTR szMacFamilyName, TTLOADINFO *pTTLoadInfo) -{ - FIXME("(%p 0x%08x %p 0x%08x %p %p %p %s %s %p) stub\n", phFontReference, - ulFlags, pulPrivStatus, ulPrivs, pulStatus, lpfnReadFromStream, - lpvReadStream, debugstr_w(szWinFamilyName), szMacFamilyName, - pTTLoadInfo); - - return E_API_NOTIMPL; -} diff --git a/dlls/t2embed/t2embed.spec b/dlls/t2embed/t2embed.spec index ed5d25b6698..ed0c71f88ef 100644 --- a/dlls/t2embed/t2embed.spec +++ b/dlls/t2embed/t2embed.spec @@ -7,7 +7,7 @@ @ stub TTGetEmbeddingType @ stub TTIsEmbeddingEnabled @ stub TTIsEmbeddingEnabledForFacename -@ stdcall TTLoadEmbeddedFont(ptr long ptr long ptr ptr ptr wstr str ptr) +@ stub TTLoadEmbeddedFont @ stub TTRunValidationTests @ stub _TTCharToUnicode@24 @ stub _TTDeleteEmbeddedFont@12 diff --git a/dlls/twain.dll16/Makefile.in b/dlls/twain.dll16/Makefile.in index 09c6ff7c736..ba8e564b615 100644 --- a/dlls/twain.dll16/Makefile.in +++ b/dlls/twain.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = twain.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,twain_32.dll +SPEC_SRCS = twain.dll16.spec + C_SRCS = twain.c @MAKE_DLL_RULES@ diff --git a/dlls/typelib.dll16/Makefile.in b/dlls/typelib.dll16/Makefile.in index 35b1ab112c9..d8d6c9a4579 100644 --- a/dlls/typelib.dll16/Makefile.in +++ b/dlls/typelib.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = typelib.dll16 IMPORTS = oleaut32 advapi32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,oleaut32.dll +SPEC_SRCS = typelib.dll16.spec + C_SRCS = typelib.c @MAKE_DLL_RULES@ diff --git a/dlls/urlmon/bindctx.c b/dlls/urlmon/bindctx.c index 0b3efa6c874..8c1949bae8c 100644 --- a/dlls/urlmon/bindctx.c +++ b/dlls/urlmon/bindctx.c @@ -28,38 +28,32 @@ static WCHAR BSCBHolder[] = { '_','B','S','C','B','_','H','o','l','d','e','r','_ extern IID IID_IBindStatusCallbackHolder; typedef struct { - const IBindStatusCallbackExVtbl *lpBindStatusCallbackExVtbl; - const IServiceProviderVtbl *lpServiceProviderVtbl; - const IHttpNegotiate2Vtbl *lpHttpNegotiate2Vtbl; - const IAuthenticateVtbl *lpAuthenticateVtbl; + const IBindStatusCallbackVtbl *lpBindStatusCallbackVtbl; + const IServiceProviderVtbl *lpServiceProviderVtbl; + const IHttpNegotiate2Vtbl *lpHttpNegotiate2Vtbl; + const IAuthenticateVtbl *lpAuthenticateVtbl; LONG ref; IBindStatusCallback *callback; IServiceProvider *serv_prov; + + IHttpNegotiate *http_negotiate; + BOOL init_http_negotiate; + IHttpNegotiate2 *http_negotiate2; + BOOL init_http_negotiate2; + IAuthenticate *authenticate; + BOOL init_authenticate; } BindStatusCallback; -#define STATUSCLB(x) ((IBindStatusCallback*) &(x)->lpBindStatusCallbackExVtbl) -#define STATUSCLBEX(x) ((IBindStatusCallbackEx*)&(x)->lpBindStatusCallbackExVtbl) +#define STATUSCLB(x) ((IBindStatusCallback*) &(x)->lpBindStatusCallbackVtbl) #define SERVPROV(x) ((IServiceProvider*) &(x)->lpServiceProviderVtbl) #define HTTPNEG2(x) ((IHttpNegotiate2*) &(x)->lpHttpNegotiate2Vtbl) #define AUTHENTICATE(x) ((IAuthenticate*) &(x)->lpAuthenticateVtbl) -static void *get_callback_iface(BindStatusCallback *This, REFIID riid) -{ - void *ret; - HRESULT hres; - - hres = IBindStatusCallback_QueryInterface(This->callback, riid, (void**)&ret); - if(FAILED(hres) && This->serv_prov) - hres = IServiceProvider_QueryService(This->serv_prov, riid, riid, &ret); +#define STATUSCLB_THIS(iface) DEFINE_THIS(BindStatusCallback, BindStatusCallback, iface) - return SUCCEEDED(hres) ? ret : NULL; -} - -#define STATUSCLB_THIS(iface) DEFINE_THIS(BindStatusCallback, BindStatusCallbackEx, iface) - -static HRESULT WINAPI BindStatusCallback_QueryInterface(IBindStatusCallbackEx *iface, +static HRESULT WINAPI BindStatusCallback_QueryInterface(IBindStatusCallback *iface, REFIID riid, void **ppv) { BindStatusCallback *This = STATUSCLB_THIS(iface); @@ -72,9 +66,6 @@ static HRESULT WINAPI BindStatusCallback_QueryInterface(IBindStatusCallbackEx *i }else if(IsEqualGUID(&IID_IBindStatusCallback, riid)) { TRACE("(%p)->(IID_IBindStatusCallback, %p)\n", This, ppv); *ppv = STATUSCLB(This); - }else if(IsEqualGUID(&IID_IBindStatusCallbackEx, riid)) { - TRACE("(%p)->(IID_IBindStatusCallback, %p)\n", This, ppv); - *ppv = STATUSCLBEX(This); }else if(IsEqualGUID(&IID_IBindStatusCallbackHolder, riid)) { TRACE("(%p)->(IID_IBindStatusCallbackHolder, %p)\n", This, ppv); *ppv = This; @@ -101,7 +92,7 @@ static HRESULT WINAPI BindStatusCallback_QueryInterface(IBindStatusCallbackEx *i return E_NOINTERFACE; } -static ULONG WINAPI BindStatusCallback_AddRef(IBindStatusCallbackEx *iface) +static ULONG WINAPI BindStatusCallback_AddRef(IBindStatusCallback *iface) { BindStatusCallback *This = STATUSCLB_THIS(iface); LONG ref = InterlockedIncrement(&This->ref); @@ -111,7 +102,7 @@ static ULONG WINAPI BindStatusCallback_AddRef(IBindStatusCallbackEx *iface) return ref; } -static ULONG WINAPI BindStatusCallback_Release(IBindStatusCallbackEx *iface) +static ULONG WINAPI BindStatusCallback_Release(IBindStatusCallback *iface) { BindStatusCallback *This = STATUSCLB_THIS(iface); LONG ref = InterlockedDecrement(&This->ref); @@ -121,6 +112,12 @@ static ULONG WINAPI BindStatusCallback_Release(IBindStatusCallbackEx *iface) if(!ref) { if(This->serv_prov) IServiceProvider_Release(This->serv_prov); + if(This->http_negotiate) + IHttpNegotiate_Release(This->http_negotiate); + if(This->http_negotiate2) + IHttpNegotiate2_Release(This->http_negotiate2); + if(This->authenticate) + IAuthenticate_Release(This->authenticate); IBindStatusCallback_Release(This->callback); heap_free(This); } @@ -128,7 +125,7 @@ static ULONG WINAPI BindStatusCallback_Release(IBindStatusCallbackEx *iface) return ref; } -static HRESULT WINAPI BindStatusCallback_OnStartBinding(IBindStatusCallbackEx *iface, +static HRESULT WINAPI BindStatusCallback_OnStartBinding(IBindStatusCallback *iface, DWORD dwReserved, IBinding *pbind) { BindStatusCallback *This = STATUSCLB_THIS(iface); @@ -138,7 +135,7 @@ static HRESULT WINAPI BindStatusCallback_OnStartBinding(IBindStatusCallbackEx *i return IBindStatusCallback_OnStartBinding(This->callback, 0xff, pbind); } -static HRESULT WINAPI BindStatusCallback_GetPriority(IBindStatusCallbackEx *iface, LONG *pnPriority) +static HRESULT WINAPI BindStatusCallback_GetPriority(IBindStatusCallback *iface, LONG *pnPriority) { BindStatusCallback *This = STATUSCLB_THIS(iface); @@ -147,7 +144,7 @@ static HRESULT WINAPI BindStatusCallback_GetPriority(IBindStatusCallbackEx *ifac return IBindStatusCallback_GetPriority(This->callback, pnPriority); } -static HRESULT WINAPI BindStatusCallback_OnLowResource(IBindStatusCallbackEx *iface, DWORD reserved) +static HRESULT WINAPI BindStatusCallback_OnLowResource(IBindStatusCallback *iface, DWORD reserved) { BindStatusCallback *This = STATUSCLB_THIS(iface); @@ -156,7 +153,7 @@ static HRESULT WINAPI BindStatusCallback_OnLowResource(IBindStatusCallbackEx *if return IBindStatusCallback_OnLowResource(This->callback, reserved); } -static HRESULT WINAPI BindStatusCallback_OnProgress(IBindStatusCallbackEx *iface, ULONG ulProgress, +static HRESULT WINAPI BindStatusCallback_OnProgress(IBindStatusCallback *iface, ULONG ulProgress, ULONG ulProgressMax, ULONG ulStatusCode, LPCWSTR szStatusText) { BindStatusCallback *This = STATUSCLB_THIS(iface); @@ -168,7 +165,7 @@ static HRESULT WINAPI BindStatusCallback_OnProgress(IBindStatusCallbackEx *iface ulProgressMax, ulStatusCode, szStatusText); } -static HRESULT WINAPI BindStatusCallback_OnStopBinding(IBindStatusCallbackEx *iface, +static HRESULT WINAPI BindStatusCallback_OnStopBinding(IBindStatusCallback *iface, HRESULT hresult, LPCWSTR szError) { BindStatusCallback *This = STATUSCLB_THIS(iface); @@ -178,29 +175,17 @@ static HRESULT WINAPI BindStatusCallback_OnStopBinding(IBindStatusCallbackEx *if return IBindStatusCallback_OnStopBinding(This->callback, hresult, szError); } -static HRESULT WINAPI BindStatusCallback_GetBindInfo(IBindStatusCallbackEx *iface, +static HRESULT WINAPI BindStatusCallback_GetBindInfo(IBindStatusCallback *iface, DWORD *grfBINDF, BINDINFO *pbindinfo) { BindStatusCallback *This = STATUSCLB_THIS(iface); - IBindStatusCallbackEx *bscex; - HRESULT hres; TRACE("(%p)->(%p %p)\n", This, grfBINDF, pbindinfo); - hres = IBindStatusCallback_QueryInterface(This->callback, &IID_IBindStatusCallbackEx, (void**)&bscex); - if(SUCCEEDED(hres)) { - DWORD bindf2 = 0, reserv = 0; - - hres = IBindStatusCallbackEx_GetBindInfoEx(bscex, grfBINDF, pbindinfo, &bindf2, &reserv); - IBindStatusCallbackEx_Release(bscex); - }else { - hres = IBindStatusCallback_GetBindInfo(This->callback, grfBINDF, pbindinfo); - } - - return hres; + return IBindStatusCallback_GetBindInfo(This->callback, grfBINDF, pbindinfo); } -static HRESULT WINAPI BindStatusCallback_OnDataAvailable(IBindStatusCallbackEx *iface, +static HRESULT WINAPI BindStatusCallback_OnDataAvailable(IBindStatusCallback *iface, DWORD grfBSCF, DWORD dwSize, FORMATETC *pformatetc, STGMEDIUM *pstgmed) { BindStatusCallback *This = STATUSCLB_THIS(iface); @@ -210,7 +195,7 @@ static HRESULT WINAPI BindStatusCallback_OnDataAvailable(IBindStatusCallbackEx * return IBindStatusCallback_OnDataAvailable(This->callback, grfBSCF, dwSize, pformatetc, pstgmed); } -static HRESULT WINAPI BindStatusCallback_OnObjectAvailable(IBindStatusCallbackEx *iface, +static HRESULT WINAPI BindStatusCallback_OnObjectAvailable(IBindStatusCallback *iface, REFIID riid, IUnknown *punk) { BindStatusCallback *This = STATUSCLB_THIS(iface); @@ -220,29 +205,9 @@ static HRESULT WINAPI BindStatusCallback_OnObjectAvailable(IBindStatusCallbackEx return IBindStatusCallback_OnObjectAvailable(This->callback, riid, punk); } -static HRESULT WINAPI BindStatusCallback_GetBindInfoEx(IBindStatusCallbackEx *iface, DWORD *grfBINDF, - BINDINFO *pbindinfo, DWORD *grfBINDF2, DWORD *pdwReserved) -{ - BindStatusCallback *This = STATUSCLB_THIS(iface); - IBindStatusCallbackEx *bscex; - HRESULT hres; - - TRACE("(%p)->(%p %p %p %p)\n", This, grfBINDF, pbindinfo, grfBINDF2, pdwReserved); - - hres = IBindStatusCallback_QueryInterface(This->callback, &IID_IBindStatusCallbackEx, (void**)&bscex); - if(SUCCEEDED(hres)) { - hres = IBindStatusCallbackEx_GetBindInfoEx(bscex, grfBINDF, pbindinfo, grfBINDF2, pdwReserved); - IBindStatusCallbackEx_Release(bscex); - }else { - hres = IBindStatusCallback_GetBindInfo(This->callback, grfBINDF, pbindinfo); - } - - return hres; -} - #undef STATUSCLB_THIS -static const IBindStatusCallbackExVtbl BindStatusCallbackExVtbl = { +static const IBindStatusCallbackVtbl BindStatusCallbackVtbl = { BindStatusCallback_QueryInterface, BindStatusCallback_AddRef, BindStatusCallback_Release, @@ -253,8 +218,7 @@ static const IBindStatusCallbackExVtbl BindStatusCallbackExVtbl = { BindStatusCallback_OnStopBinding, BindStatusCallback_GetBindInfo, BindStatusCallback_OnDataAvailable, - BindStatusCallback_OnObjectAvailable, - BindStatusCallback_GetBindInfoEx + BindStatusCallback_OnObjectAvailable }; #define SERVPROV_THIS(iface) DEFINE_THIS(BindStatusCallback, ServiceProvider, iface) @@ -286,16 +250,46 @@ static HRESULT WINAPI BSCServiceProvider_QueryService(IServiceProvider *iface, if(IsEqualGUID(&IID_IHttpNegotiate, guidService)) { TRACE("(%p)->(IID_IHttpNegotiate %s %p)\n", This, debugstr_guid(riid), ppv); + + if(!This->init_http_negotiate) { + This->init_http_negotiate = TRUE; + hres = IBindStatusCallback_QueryInterface(This->callback, &IID_IHttpNegotiate, + (void**)&This->http_negotiate); + if(FAILED(hres) && This->serv_prov) + IServiceProvider_QueryService(This->serv_prov, &IID_IHttpNegotiate, + &IID_IHttpNegotiate, (void**)&This->http_negotiate); + } + return IBindStatusCallback_QueryInterface(STATUSCLB(This), riid, ppv); } if(IsEqualGUID(&IID_IHttpNegotiate2, guidService)) { TRACE("(%p)->(IID_IHttpNegotiate2 %s %p)\n", This, debugstr_guid(riid), ppv); + + if(!This->init_http_negotiate2) { + This->init_http_negotiate2 = TRUE; + hres = IBindStatusCallback_QueryInterface(This->callback, &IID_IHttpNegotiate2, + (void**)&This->http_negotiate2); + if(FAILED(hres) && This->serv_prov) + IServiceProvider_QueryService(This->serv_prov, &IID_IHttpNegotiate2, + &IID_IHttpNegotiate2, (void**)&This->http_negotiate2); + } + return IBindStatusCallback_QueryInterface(STATUSCLB(This), riid, ppv); } if(IsEqualGUID(&IID_IAuthenticate, guidService)) { TRACE("(%p)->(IID_IAuthenticate %s %p)\n", This, debugstr_guid(riid), ppv); + + if(!This->init_authenticate) { + This->init_authenticate = TRUE; + hres = IBindStatusCallback_QueryInterface(This->callback, &IID_IAuthenticate, + (void**)&This->authenticate); + if(FAILED(hres) && This->serv_prov) + IServiceProvider_QueryService(This->serv_prov, &IID_IAuthenticate, + &IID_IAuthenticate, (void**)&This->authenticate); + } + return IBindStatusCallback_QueryInterface(STATUSCLB(This), riid, ppv); } @@ -348,22 +342,17 @@ static HRESULT WINAPI BSCHttpNegotiate_BeginningTransaction(IHttpNegotiate2 *ifa LPCWSTR szURL, LPCWSTR szHeaders, DWORD dwReserved, LPWSTR *pszAdditionalHeaders) { BindStatusCallback *This = HTTPNEG2_THIS(iface); - IHttpNegotiate *http_negotiate; - HRESULT hres = S_OK; TRACE("(%p)->(%s %s %d %p)\n", This, debugstr_w(szURL), debugstr_w(szHeaders), dwReserved, pszAdditionalHeaders); *pszAdditionalHeaders = NULL; - http_negotiate = get_callback_iface(This, &IID_IHttpNegotiate); - if(http_negotiate) { - hres = IHttpNegotiate_BeginningTransaction(http_negotiate, szURL, szHeaders, - dwReserved, pszAdditionalHeaders); - IHttpNegotiate_Release(http_negotiate); - } + if(!This->http_negotiate) + return S_OK; - return hres; + return IHttpNegotiate_BeginningTransaction(This->http_negotiate, szURL, szHeaders, + dwReserved, pszAdditionalHeaders); } static HRESULT WINAPI BSCHttpNegotiate_OnResponse(IHttpNegotiate2 *iface, DWORD dwResponseCode, @@ -372,18 +361,14 @@ static HRESULT WINAPI BSCHttpNegotiate_OnResponse(IHttpNegotiate2 *iface, DWORD { BindStatusCallback *This = HTTPNEG2_THIS(iface); LPWSTR additional_headers = NULL; - IHttpNegotiate *http_negotiate; HRESULT hres = S_OK; TRACE("(%p)->(%d %s %s %p)\n", This, dwResponseCode, debugstr_w(szResponseHeaders), debugstr_w(szRequestHeaders), pszAdditionalRequestHeaders); - http_negotiate = get_callback_iface(This, &IID_IHttpNegotiate); - if(http_negotiate) { - hres = IHttpNegotiate_OnResponse(http_negotiate, dwResponseCode, szResponseHeaders, - szRequestHeaders, &additional_headers); - IHttpNegotiate_Release(http_negotiate); - } + if(This->http_negotiate) + hres = IHttpNegotiate_OnResponse(This->http_negotiate, dwResponseCode, szResponseHeaders, + szRequestHeaders, &additional_headers); if(pszAdditionalRequestHeaders) *pszAdditionalRequestHeaders = additional_headers; @@ -397,19 +382,14 @@ static HRESULT WINAPI BSCHttpNegotiate_GetRootSecurityId(IHttpNegotiate2 *iface, BYTE *pbSecurityId, DWORD *pcbSecurityId, DWORD_PTR dwReserved) { BindStatusCallback *This = HTTPNEG2_THIS(iface); - IHttpNegotiate2 *http_negotiate2; - HRESULT hres = E_FAIL; TRACE("(%p)->(%p %p %ld)\n", This, pbSecurityId, pcbSecurityId, dwReserved); - http_negotiate2 = get_callback_iface(This, &IID_IHttpNegotiate2); - if(http_negotiate2) { - hres = IHttpNegotiate2_GetRootSecurityId(http_negotiate2, pbSecurityId, - pcbSecurityId, dwReserved); - IHttpNegotiate2_Release(http_negotiate2); - } + if(!This->http_negotiate2) + return E_NOTIMPL; - return hres; + return IHttpNegotiate2_GetRootSecurityId(This->http_negotiate2, pbSecurityId, + pcbSecurityId, dwReserved); } #undef HTTPNEG2_THIS @@ -464,7 +444,7 @@ static IBindStatusCallback *create_bsc(IBindStatusCallback *bsc) { BindStatusCallback *ret = heap_alloc_zero(sizeof(BindStatusCallback)); - ret->lpBindStatusCallbackExVtbl = &BindStatusCallbackExVtbl; + ret->lpBindStatusCallbackVtbl = &BindStatusCallbackVtbl; ret->lpServiceProviderVtbl = &BSCServiceProviderVtbl; ret->lpHttpNegotiate2Vtbl = &BSCHttpNegotiateVtbl; ret->lpAuthenticateVtbl = &BSCAuthenticateVtbl; diff --git a/dlls/urlmon/rsrc.rc b/dlls/urlmon/rsrc.rc index c87ea81998c..d71b2faff0d 100644 --- a/dlls/urlmon/rsrc.rc +++ b/dlls/urlmon/rsrc.rc @@ -19,10 +19,4 @@ /* @makedep: urlmon.inf */ REGINST REGINST urlmon.inf -#define WINE_FILENAME_STR "urlmon.dll" -#define WINE_FILEVERSION 6,0,2800,1485 -#define WINE_FILEVERSION_STR "6.0.2800.1485" -#define WINE_PRODUCTVERSION 6,0,2800,1485 -#define WINE_PRODUCTVERSION_STR "6.0.2800.1485" - -#include "wine/wine_common_ver.rc" +#include "version.rc" diff --git a/dlls/urlmon/sec_mgr.c b/dlls/urlmon/sec_mgr.c index d54b2bf7d5b..943b6dd7678 100644 --- a/dlls/urlmon/sec_mgr.c +++ b/dlls/urlmon/sec_mgr.c @@ -3,7 +3,6 @@ * * Copyright (c) 2004 Huw D M Davies * Copyright 2004 Jacek Caban - * Copyright 2009 Detlef Riekenberg * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -30,73 +29,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(urlmon); -static const WCHAR currentlevelW[] = {'C','u','r','r','e','n','t','L','e','v','e','l',0}; -static const WCHAR descriptionW[] = {'D','e','s','c','r','i','p','t','i','o','n',0}; -static const WCHAR displaynameW[] = {'D','i','s','p','l','a','y','N','a','m','e',0}; static const WCHAR fileW[] = {'f','i','l','e',0}; -static const WCHAR flagsW[] = {'F','l','a','g','s',0}; -static const WCHAR iconW[] = {'I','c','o','n',0}; -static const WCHAR minlevelW[] = {'M','i','n','L','e','v','e','l',0}; -static const WCHAR recommendedlevelW[] = {'R','e','c','o','m','m','e','n','d','e','d', - 'L','e','v','e','l',0}; -static const WCHAR wszZonesKey[] = {'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','\\', - 'I','n','t','e','r','n','e','t',' ','S','e','t','t','i','n','g','s','\\', - 'Z','o','n','e','s','\\',0}; - -/******************************************************************** - * get_string_from_reg [internal] - * - * helper to get a string from the reg. - * - */ -static void get_string_from_reg(HKEY hcu, HKEY hklm, LPCWSTR name, LPWSTR out, DWORD maxlen) -{ - DWORD type = REG_SZ; - DWORD len = maxlen * sizeof(WCHAR); - DWORD res; - - res = RegQueryValueExW(hcu, name, NULL, &type, (LPBYTE) out, &len); - - if (res && hklm) { - len = maxlen * sizeof(WCHAR); - type = REG_SZ; - res = RegQueryValueExW(hklm, name, NULL, &type, (LPBYTE) out, &len); - } - - if (res) { - TRACE("%s failed: %d\n", debugstr_w(name), res); - *out = '\0'; - } -} - -/******************************************************************** - * get_dword_from_reg [internal] - * - * helper to get a dword from the reg. - * - */ -static void get_dword_from_reg(HKEY hcu, HKEY hklm, LPCWSTR name, LPDWORD out) -{ - DWORD type = REG_DWORD; - DWORD len = sizeof(DWORD); - DWORD res; - - res = RegQueryValueExW(hcu, name, NULL, &type, (LPBYTE) out, &len); - - if (res && hklm) { - len = sizeof(DWORD); - type = REG_DWORD; - res = RegQueryValueExW(hklm, name, NULL, &type, (LPBYTE) out, &len); - } - - if (res) { - TRACE("%s failed: %d\n", debugstr_w(name), res); - *out = 0; - } -} static HRESULT get_zone_from_reg(LPCWSTR schema, DWORD *zone) { @@ -212,6 +145,13 @@ static HRESULT map_url_to_zone(LPCWSTR url, DWORD *zone, LPWSTR *ret_url) static HRESULT open_zone_key(HKEY parent_key, DWORD zone, HKEY *hkey) { + static const WCHAR wszZonesKey[] = + {'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','\\', + 'I','n','t','e','r','n','e','t',' ','S','e','t','t','i','n','g','s','\\', + 'Z','o','n','e','s','\\',0}; static const WCHAR wszFormat[] = {'%','s','%','l','d',0}; WCHAR key_name[sizeof(wszZonesKey)/sizeof(WCHAR)+8]; @@ -671,75 +611,14 @@ HRESULT SecManagerImpl_Construct(IUnknown *pUnkOuter, LPVOID *ppobj) * */ typedef struct { - const IInternetZoneManagerEx2Vtbl* lpVtbl; + const IInternetZoneManagerVtbl* lpVtbl; LONG ref; - LPDWORD *zonemaps; - DWORD zonemap_count; } ZoneMgrImpl; - -/*********************************************************************** - * build_zonemap_from_reg [internal] - * - * Enumerate the Zones in the Registry and return the Zones in a DWORD-array - * The number of the Zones is returned in data[0] - */ -static LPDWORD build_zonemap_from_reg(void) -{ - WCHAR name[32]; - HKEY hkey; - LPDWORD data = NULL; - DWORD allocated = 6; /* space for the zonecount and Zone "0" upto Zone "4" */ - DWORD used = 0; - DWORD res; - DWORD len; - - - res = RegOpenKeyW(HKEY_CURRENT_USER, wszZonesKey, &hkey); - if (res) - return NULL; - - data = heap_alloc(allocated * sizeof(DWORD)); - if (!data) - goto cleanup; - - while (!res) { - name[0] = '\0'; - len = sizeof(name) / sizeof(name[0]); - res = RegEnumKeyExW(hkey, used, name, &len, NULL, NULL, NULL, NULL); - - if (!res) { - used++; - if (used == allocated) { - LPDWORD new_data; - - allocated *= 2; - new_data = heap_realloc_zero(data, allocated * sizeof(DWORD)); - if (!new_data) - goto cleanup; - - data = new_data; - } - data[used] = atoiW(name); - } - } - if (used) { - RegCloseKey(hkey); - data[0] = used; - return data; - } - -cleanup: - /* something failed */ - RegCloseKey(hkey); - heap_free(data); - return NULL; -} - /******************************************************************** * IInternetZoneManager_QueryInterface */ -static HRESULT WINAPI ZoneMgrImpl_QueryInterface(IInternetZoneManagerEx2* iface, REFIID riid, void** ppvObject) +static HRESULT WINAPI ZoneMgrImpl_QueryInterface(IInternetZoneManager* iface, REFIID riid, void** ppvObject) { ZoneMgrImpl* This = (ZoneMgrImpl*)iface; @@ -748,17 +627,7 @@ static HRESULT WINAPI ZoneMgrImpl_QueryInterface(IInternetZoneManagerEx2* iface, if(!This || !ppvObject) return E_INVALIDARG; - if(IsEqualIID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppvObject); - }else if(IsEqualIID(&IID_IInternetZoneManager, riid)) { - TRACE("(%p)->(IID_InternetZoneManager %p)\n", This, ppvObject); - }else if(IsEqualIID(&IID_IInternetZoneManagerEx, riid)) { - TRACE("(%p)->(IID_InternetZoneManagerEx %p)\n", This, ppvObject); - }else if(IsEqualIID(&IID_IInternetZoneManagerEx2, riid)) { - TRACE("(%p)->(IID_InternetZoneManagerEx2 %p)\n", This, ppvObject); - } - else - { + if(!IsEqualIID(&IID_IUnknown, riid) && !IsEqualIID(&IID_IInternetZoneManager, riid)) { FIXME("Unknown interface: %s\n", debugstr_guid(riid)); *ppvObject = NULL; return E_NOINTERFACE; @@ -766,13 +635,14 @@ static HRESULT WINAPI ZoneMgrImpl_QueryInterface(IInternetZoneManagerEx2* iface, *ppvObject = iface; IInternetZoneManager_AddRef(iface); + return S_OK; } /******************************************************************** * IInternetZoneManager_AddRef */ -static ULONG WINAPI ZoneMgrImpl_AddRef(IInternetZoneManagerEx2* iface) +static ULONG WINAPI ZoneMgrImpl_AddRef(IInternetZoneManager* iface) { ZoneMgrImpl* This = (ZoneMgrImpl*)iface; ULONG refCount = InterlockedIncrement(&This->ref); @@ -785,7 +655,7 @@ static ULONG WINAPI ZoneMgrImpl_AddRef(IInternetZoneManagerEx2* iface) /******************************************************************** * IInternetZoneManager_Release */ -static ULONG WINAPI ZoneMgrImpl_Release(IInternetZoneManagerEx2* iface) +static ULONG WINAPI ZoneMgrImpl_Release(IInternetZoneManager* iface) { ZoneMgrImpl* This = (ZoneMgrImpl*)iface; ULONG refCount = InterlockedDecrement(&This->ref); @@ -793,8 +663,6 @@ static ULONG WINAPI ZoneMgrImpl_Release(IInternetZoneManagerEx2* iface) TRACE("(%p)->(ref before=%u)\n",This, refCount + 1); if(!refCount) { - while (This->zonemap_count) heap_free(This->zonemaps[--This->zonemap_count]); - heap_free(This->zonemaps); heap_free(This); URLMON_UnlockModule(); } @@ -805,45 +673,18 @@ static ULONG WINAPI ZoneMgrImpl_Release(IInternetZoneManagerEx2* iface) /******************************************************************** * IInternetZoneManager_GetZoneAttributes */ -static HRESULT WINAPI ZoneMgrImpl_GetZoneAttributes(IInternetZoneManagerEx2* iface, +static HRESULT WINAPI ZoneMgrImpl_GetZoneAttributes(IInternetZoneManager* iface, DWORD dwZone, ZONEATTRIBUTES* pZoneAttributes) { - ZoneMgrImpl* This = (ZoneMgrImpl*)iface; - HRESULT hr; - HKEY hcu; - HKEY hklm = NULL; - - TRACE("(%p)->(%d %p)\n", This, dwZone, pZoneAttributes); - - if (!pZoneAttributes) - return E_INVALIDARG; - - hr = open_zone_key(HKEY_CURRENT_USER, dwZone, &hcu); - if (FAILED(hr)) - return S_OK; /* IE6 and older returned E_FAIL here */ - - hr = open_zone_key(HKEY_LOCAL_MACHINE, dwZone, &hklm); - if (FAILED(hr)) - TRACE("Zone %d not in HKLM\n", dwZone); - - get_string_from_reg(hcu, hklm, displaynameW, pZoneAttributes->szDisplayName, MAX_ZONE_PATH); - get_string_from_reg(hcu, hklm, descriptionW, pZoneAttributes->szDescription, MAX_ZONE_DESCRIPTION); - get_string_from_reg(hcu, hklm, iconW, pZoneAttributes->szIconPath, MAX_ZONE_PATH); - get_dword_from_reg(hcu, hklm, minlevelW, &pZoneAttributes->dwTemplateMinLevel); - get_dword_from_reg(hcu, hklm, currentlevelW, &pZoneAttributes->dwTemplateCurrentLevel); - get_dword_from_reg(hcu, hklm, recommendedlevelW, &pZoneAttributes->dwTemplateRecommended); - get_dword_from_reg(hcu, hklm, flagsW, &pZoneAttributes->dwFlags); - - RegCloseKey(hklm); - RegCloseKey(hcu); - return S_OK; + FIXME("(%p)->(%d %p) stub\n", iface, dwZone, pZoneAttributes); + return E_NOTIMPL; } /******************************************************************** * IInternetZoneManager_SetZoneAttributes */ -static HRESULT WINAPI ZoneMgrImpl_SetZoneAttributes(IInternetZoneManagerEx2* iface, +static HRESULT WINAPI ZoneMgrImpl_SetZoneAttributes(IInternetZoneManager* iface, DWORD dwZone, ZONEATTRIBUTES* pZoneAttributes) { @@ -854,7 +695,7 @@ static HRESULT WINAPI ZoneMgrImpl_SetZoneAttributes(IInternetZoneManagerEx2* ifa /******************************************************************** * IInternetZoneManager_GetZoneCustomPolicy */ -static HRESULT WINAPI ZoneMgrImpl_GetZoneCustomPolicy(IInternetZoneManagerEx2* iface, +static HRESULT WINAPI ZoneMgrImpl_GetZoneCustomPolicy(IInternetZoneManager* iface, DWORD dwZone, REFGUID guidKey, BYTE** ppPolicy, @@ -869,7 +710,7 @@ static HRESULT WINAPI ZoneMgrImpl_GetZoneCustomPolicy(IInternetZoneManagerEx2* i /******************************************************************** * IInternetZoneManager_SetZoneCustomPolicy */ -static HRESULT WINAPI ZoneMgrImpl_SetZoneCustomPolicy(IInternetZoneManagerEx2* iface, +static HRESULT WINAPI ZoneMgrImpl_SetZoneCustomPolicy(IInternetZoneManager* iface, DWORD dwZone, REFGUID guidKey, BYTE* ppPolicy, @@ -884,7 +725,7 @@ static HRESULT WINAPI ZoneMgrImpl_SetZoneCustomPolicy(IInternetZoneManagerEx2* i /******************************************************************** * IInternetZoneManager_GetZoneActionPolicy */ -static HRESULT WINAPI ZoneMgrImpl_GetZoneActionPolicy(IInternetZoneManagerEx2* iface, +static HRESULT WINAPI ZoneMgrImpl_GetZoneActionPolicy(IInternetZoneManager* iface, DWORD dwZone, DWORD dwAction, BYTE* pPolicy, DWORD cbPolicy, URLZONEREG urlZoneReg) { TRACE("(%p)->(%d %08x %p %d %d)\n", iface, dwZone, dwAction, pPolicy, @@ -899,7 +740,7 @@ static HRESULT WINAPI ZoneMgrImpl_GetZoneActionPolicy(IInternetZoneManagerEx2* i /******************************************************************** * IInternetZoneManager_SetZoneActionPolicy */ -static HRESULT WINAPI ZoneMgrImpl_SetZoneActionPolicy(IInternetZoneManagerEx2* iface, +static HRESULT WINAPI ZoneMgrImpl_SetZoneActionPolicy(IInternetZoneManager* iface, DWORD dwZone, DWORD dwAction, BYTE* pPolicy, @@ -914,7 +755,7 @@ static HRESULT WINAPI ZoneMgrImpl_SetZoneActionPolicy(IInternetZoneManagerEx2* i /******************************************************************** * IInternetZoneManager_PromptAction */ -static HRESULT WINAPI ZoneMgrImpl_PromptAction(IInternetZoneManagerEx2* iface, +static HRESULT WINAPI ZoneMgrImpl_PromptAction(IInternetZoneManager* iface, DWORD dwAction, HWND hwndParent, LPCWSTR pwszUrl, @@ -929,7 +770,7 @@ static HRESULT WINAPI ZoneMgrImpl_PromptAction(IInternetZoneManagerEx2* iface, /******************************************************************** * IInternetZoneManager_LogAction */ -static HRESULT WINAPI ZoneMgrImpl_LogAction(IInternetZoneManagerEx2* iface, +static HRESULT WINAPI ZoneMgrImpl_LogAction(IInternetZoneManager* iface, DWORD dwAction, LPCWSTR pwszUrl, LPCWSTR pwszText, @@ -943,108 +784,41 @@ static HRESULT WINAPI ZoneMgrImpl_LogAction(IInternetZoneManagerEx2* iface, /******************************************************************** * IInternetZoneManager_CreateZoneEnumerator */ -static HRESULT WINAPI ZoneMgrImpl_CreateZoneEnumerator(IInternetZoneManagerEx2* iface, +static HRESULT WINAPI ZoneMgrImpl_CreateZoneEnumerator(IInternetZoneManager* iface, DWORD* pdwEnum, DWORD* pdwCount, DWORD dwFlags) { - ZoneMgrImpl* This = (ZoneMgrImpl*)iface; - LPDWORD * new_maps; - LPDWORD data; - DWORD i; - - TRACE("(%p)->(%p, %p, 0x%08x)\n", This, pdwEnum, pdwCount, dwFlags); - if (!pdwEnum || !pdwCount || (dwFlags != 0)) - return E_INVALIDARG; - - data = build_zonemap_from_reg(); - TRACE("found %d zones\n", data ? data[0] : -1); - - if (!data) - return E_FAIL; - - for (i = 0; i < This->zonemap_count; i++) { - if (This->zonemaps && !This->zonemaps[i]) { - This->zonemaps[i] = data; - *pdwEnum = i; - *pdwCount = data[0]; - return S_OK; - } - } - - if (This->zonemaps) { - /* try to double the nr. of pointers in the array */ - new_maps = heap_realloc_zero(This->zonemaps, This->zonemap_count * 2 * sizeof(LPDWORD)); - if (new_maps) - This->zonemap_count *= 2; - } - else - { - This->zonemap_count = 2; - new_maps = heap_alloc_zero(This->zonemap_count * sizeof(LPDWORD)); - } - - if (!new_maps) { - heap_free(data); - return E_FAIL; - } - This->zonemaps = new_maps; - This->zonemaps[i] = data; - *pdwEnum = i; - *pdwCount = data[0]; - return S_OK; + FIXME("(%p)->(%p %p %08x) stub\n", iface, pdwEnum, pdwCount, dwFlags); + return E_NOTIMPL; } /******************************************************************** * IInternetZoneManager_GetZoneAt */ -static HRESULT WINAPI ZoneMgrImpl_GetZoneAt(IInternetZoneManagerEx2* iface, +static HRESULT WINAPI ZoneMgrImpl_GetZoneAt(IInternetZoneManager* iface, DWORD dwEnum, DWORD dwIndex, DWORD* pdwZone) { - ZoneMgrImpl* This = (ZoneMgrImpl*)iface; - LPDWORD data; - - TRACE("(%p)->(0x%08x, %d, %p)\n", This, dwEnum, dwIndex, pdwZone); - - /* make sure, that dwEnum and dwIndex are in the valid range */ - if (dwEnum < This->zonemap_count) { - if ((data = This->zonemaps[dwEnum])) { - if (dwIndex < data[0]) { - *pdwZone = data[dwIndex + 1]; - return S_OK; - } - } - } - return E_INVALIDARG; + FIXME("(%p)->(%08x %08x %p) stub\n", iface, dwEnum, dwIndex, pdwZone); + return E_NOTIMPL; } /******************************************************************** * IInternetZoneManager_DestroyZoneEnumerator */ -static HRESULT WINAPI ZoneMgrImpl_DestroyZoneEnumerator(IInternetZoneManagerEx2* iface, +static HRESULT WINAPI ZoneMgrImpl_DestroyZoneEnumerator(IInternetZoneManager* iface, DWORD dwEnum) { - ZoneMgrImpl* This = (ZoneMgrImpl*)iface; - LPDWORD data; - - TRACE("(%p)->(0x%08x)\n", This, dwEnum); - /* make sure, that dwEnum is valid */ - if (dwEnum < This->zonemap_count) { - if ((data = This->zonemaps[dwEnum])) { - This->zonemaps[dwEnum] = NULL; - heap_free(data); - return S_OK; - } - } - return E_INVALIDARG; + FIXME("(%p)->(%08x) stub\n", iface, dwEnum); + return E_NOTIMPL; } /******************************************************************** * IInternetZoneManager_CopyTemplatePoliciesToZone */ -static HRESULT WINAPI ZoneMgrImpl_CopyTemplatePoliciesToZone(IInternetZoneManagerEx2* iface, +static HRESULT WINAPI ZoneMgrImpl_CopyTemplatePoliciesToZone(IInternetZoneManager* iface, DWORD dwTemplate, DWORD dwZone, DWORD dwReserved) @@ -1054,118 +828,12 @@ static HRESULT WINAPI ZoneMgrImpl_CopyTemplatePoliciesToZone(IInternetZoneManage } /******************************************************************** - * IInternetZoneManagerEx_GetZoneActionPolicyEx - */ -static HRESULT WINAPI ZoneMgrImpl_GetZoneActionPolicyEx(IInternetZoneManagerEx2* iface, - DWORD dwZone, - DWORD dwAction, - BYTE* pPolicy, - DWORD cbPolicy, - URLZONEREG urlZoneReg, - DWORD dwFlags) -{ - TRACE("(%p)->(%d, 0x%x, %p, %d, %d, 0x%x)\n", iface, dwZone, - dwAction, pPolicy, cbPolicy, urlZoneReg, dwFlags); - - if(!pPolicy) - return E_INVALIDARG; - - if (dwFlags) - FIXME("dwFlags 0x%x ignored\n", dwFlags); - - return get_action_policy(dwZone, dwAction, pPolicy, cbPolicy, urlZoneReg); -} - -/******************************************************************** - * IInternetZoneManagerEx_SetZoneActionPolicyEx - */ -static HRESULT WINAPI ZoneMgrImpl_SetZoneActionPolicyEx(IInternetZoneManagerEx2* iface, - DWORD dwZone, - DWORD dwAction, - BYTE* pPolicy, - DWORD cbPolicy, - URLZONEREG urlZoneReg, - DWORD dwFlags) -{ - FIXME("(%p)->(%d, 0x%x, %p, %d, %d, 0x%x) stub\n", iface, dwZone, dwAction, pPolicy, - cbPolicy, urlZoneReg, dwFlags); - return E_NOTIMPL; -} - -/******************************************************************** - * IInternetZoneManagerEx2_GetZoneAttributesEx - */ -static HRESULT WINAPI ZoneMgrImpl_GetZoneAttributesEx(IInternetZoneManagerEx2* iface, - DWORD dwZone, - ZONEATTRIBUTES* pZoneAttributes, - DWORD dwFlags) -{ - TRACE("(%p)->(%d, %p, 0x%x)\n", iface, dwZone, pZoneAttributes, dwFlags); - - if (dwFlags) - FIXME("dwFlags 0x%x ignored\n", dwFlags); - - return IInternetZoneManager_GetZoneAttributes(iface, dwZone, pZoneAttributes); -} - - -/******************************************************************** - * IInternetZoneManagerEx2_GetZoneSecurityState - */ -static HRESULT WINAPI ZoneMgrImpl_GetZoneSecurityState(IInternetZoneManagerEx2* iface, - DWORD dwZoneIndex, - BOOL fRespectPolicy, - LPDWORD pdwState, - BOOL *pfPolicyEncountered) -{ - FIXME("(%p)->(%d, %d, %p, %p) stub\n", iface, dwZoneIndex, fRespectPolicy, - pdwState, pfPolicyEncountered); - - *pdwState = SECURITY_IE_STATE_GREEN; - - if (pfPolicyEncountered) - *pfPolicyEncountered = FALSE; - - return S_OK; -} - -/******************************************************************** - * IInternetZoneManagerEx2_GetIESecurityState - */ -static HRESULT WINAPI ZoneMgrImpl_GetIESecurityState(IInternetZoneManagerEx2* iface, - BOOL fRespectPolicy, - LPDWORD pdwState, - BOOL *pfPolicyEncountered, - BOOL fNoCache) -{ - FIXME("(%p)->(%d, %p, %p, %d) stub\n", iface, fRespectPolicy, pdwState, - pfPolicyEncountered, fNoCache); - - *pdwState = SECURITY_IE_STATE_GREEN; - - if (pfPolicyEncountered) - *pfPolicyEncountered = FALSE; - - return S_OK; -} - -/******************************************************************** - * IInternetZoneManagerEx2_FixInsecureSettings - */ -static HRESULT WINAPI ZoneMgrImpl_FixInsecureSettings(IInternetZoneManagerEx2* iface) -{ - FIXME("(%p) stub\n", iface); - return S_OK; -} - -/******************************************************************** * IInternetZoneManager_Construct */ -static const IInternetZoneManagerEx2Vtbl ZoneMgrImplVtbl = { +static const IInternetZoneManagerVtbl ZoneMgrImplVtbl = { ZoneMgrImpl_QueryInterface, ZoneMgrImpl_AddRef, ZoneMgrImpl_Release, - /* IInternetZoneManager */ ZoneMgrImpl_GetZoneAttributes, ZoneMgrImpl_SetZoneAttributes, ZoneMgrImpl_GetZoneCustomPolicy, @@ -1178,24 +846,16 @@ static const IInternetZoneManagerEx2Vtbl ZoneMgrImplVtbl = { ZoneMgrImpl_GetZoneAt, ZoneMgrImpl_DestroyZoneEnumerator, ZoneMgrImpl_CopyTemplatePoliciesToZone, - /* IInternetZoneManagerEx */ - ZoneMgrImpl_GetZoneActionPolicyEx, - ZoneMgrImpl_SetZoneActionPolicyEx, - /* IInternetZoneManagerEx2 */ - ZoneMgrImpl_GetZoneAttributesEx, - ZoneMgrImpl_GetZoneSecurityState, - ZoneMgrImpl_GetIESecurityState, - ZoneMgrImpl_FixInsecureSettings, }; HRESULT ZoneMgrImpl_Construct(IUnknown *pUnkOuter, LPVOID *ppobj) { - ZoneMgrImpl* ret = heap_alloc_zero(sizeof(ZoneMgrImpl)); + ZoneMgrImpl* ret = heap_alloc(sizeof(ZoneMgrImpl)); TRACE("(%p %p)\n", pUnkOuter, ppobj); ret->lpVtbl = &ZoneMgrImplVtbl; ret->ref = 1; - *ppobj = (IInternetZoneManagerEx*)ret; + *ppobj = (IInternetZoneManager*)ret; URLMON_LockModule(); diff --git a/dlls/urlmon/session.c b/dlls/urlmon/session.c index 69f1aa12606..933202c352d 100644 --- a/dlls/urlmon/session.c +++ b/dlls/urlmon/session.c @@ -52,13 +52,6 @@ static CRITICAL_SECTION_DEBUG session_cs_dbg = }; static CRITICAL_SECTION session_cs = { &session_cs_dbg, -1, 0, 0, 0, 0 }; -static const WCHAR internet_settings_keyW[] = - {'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', - '\\','I','n','t','e','r','n','e','t',' ','S','e','t','t','i','n','g','s',0}; - static name_space *find_name_space(LPCWSTR protocol) { name_space *iter; @@ -489,9 +482,15 @@ static BOOL get_url_encoding(HKEY root, DWORD *encoding) DWORD size = sizeof(DWORD), res, type; HKEY hkey; + static const WCHAR wszKeyName[] = + {'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', + '\\','I','n','t','e','r','n','e','t',' ','S','e','t','t','i','n','g','s',0}; static const WCHAR wszUrlEncoding[] = {'U','r','l','E','n','c','o','d','i','n','g',0}; - res = RegOpenKeyW(root, internet_settings_keyW, &hkey); + res = RegOpenKeyW(root, wszKeyName, &hkey); if(res != ERROR_SUCCESS) return FALSE; @@ -501,37 +500,6 @@ static BOOL get_url_encoding(HKEY root, DWORD *encoding) return res == ERROR_SUCCESS; } -static LPWSTR user_agent; - -static void ensure_useragent(void) -{ - DWORD size = sizeof(DWORD), res, type; - HKEY hkey; - - static const WCHAR user_agentW[] = {'U','s','e','r',' ','A','g','e','n','t',0}; - - if(user_agent) - return; - - res = RegOpenKeyW(HKEY_CURRENT_USER, internet_settings_keyW, &hkey); - if(res != ERROR_SUCCESS) - return; - - res = RegQueryValueExW(hkey, user_agentW, NULL, &type, NULL, &size); - if(res == ERROR_SUCCESS && type == REG_SZ) { - user_agent = heap_alloc(size); - res = RegQueryValueExW(hkey, user_agentW, NULL, &type, (LPBYTE)user_agent, &size); - if(res != ERROR_SUCCESS) { - heap_free(user_agent); - user_agent = NULL; - } - }else { - WARN("Could not find User Agent value: %u\n", res); - } - - RegCloseKey(hkey); -} - HRESULT WINAPI UrlMkGetSessionOption(DWORD dwOption, LPVOID pBuffer, DWORD dwBufferLength, DWORD* pdwBufferLength, DWORD dwReserved) { @@ -541,32 +509,6 @@ HRESULT WINAPI UrlMkGetSessionOption(DWORD dwOption, LPVOID pBuffer, DWORD dwBuf WARN("dwReserved = %d\n", dwReserved); switch(dwOption) { - case URLMON_OPTION_USERAGENT: { - HRESULT hres = E_OUTOFMEMORY; - DWORD size; - - if(!pdwBufferLength) - return E_INVALIDARG; - - EnterCriticalSection(&session_cs); - - ensure_useragent(); - if(user_agent) { - size = WideCharToMultiByte(CP_ACP, 0, user_agent, -1, NULL, 0, NULL, NULL); - *pdwBufferLength = size; - if(size <= dwBufferLength) { - if(pBuffer) - WideCharToMultiByte(CP_ACP, 0, user_agent, -1, pBuffer, size, NULL, NULL); - else - hres = E_INVALIDARG; - } - } - - LeaveCriticalSection(&session_cs); - - /* Tests prove that we have to return E_OUTOFMEMORY on success. */ - return hres; - } case URLMON_OPTION_URL_ENCODING: { DWORD encoding = 0; @@ -586,85 +528,3 @@ HRESULT WINAPI UrlMkGetSessionOption(DWORD dwOption, LPVOID pBuffer, DWORD dwBuf return E_INVALIDARG; } - -/************************************************************************** - * UrlMkSetSessionOption (URLMON.@) - */ -HRESULT WINAPI UrlMkSetSessionOption(DWORD dwOption, LPVOID pBuffer, DWORD dwBufferLength, - DWORD Reserved) -{ - TRACE("(%x %p %x)\n", dwOption, pBuffer, dwBufferLength); - - switch(dwOption) { - case URLMON_OPTION_USERAGENT: { - LPWSTR new_user_agent; - char *buf = pBuffer; - DWORD len, size; - - if(!pBuffer || !dwBufferLength) - return E_INVALIDARG; - - for(len=0; len 0, "size=%d, expected non-zero\n", size); str2 = HeapAlloc(GetProcessHeap(), 0, (size+20)*sizeof(CHAR)); - saved = size; - hres = ObtainUserAgentString(0, str2, &size); - ok(hres == S_OK, "ObtainUserAgentString failed: %08x\n", hres); - ok(size == saved, "size=%d, expected %d\n", size, saved); - ok(strlen(expected) <= strlen(str2) && - !memcmp(expected, str2, strlen(expected)*sizeof(CHAR)), - "user agent was \"%s\", expected to start with \"%s\"\n", - str2, expected); - - size = saved+10; - hres = ObtainUserAgentString(0, str2, &size); - ok(hres == S_OK, "ObtainUserAgentString failed: %08x\n", hres); - ok(size == saved, "size=%d, expected %d\n", size, saved); - - size = 0; - hres = UrlMkGetSessionOption(URLMON_OPTION_USERAGENT, NULL, 0, &size, 0); - ok(hres == E_OUTOFMEMORY, "UrlMkGetSessionOption failed: %08x\n", hres); - ok(size, "size == 0\n"); - - size = 0xdeadbeef; - hres = UrlMkGetSessionOption(URLMON_OPTION_USERAGENT, NULL, 1000, &size, 0); - ok(hres == E_INVALIDARG, "UrlMkGetSessionOption failed: %08x\n", hres); - ok(size, "size == 0\n"); - - saved = size; - size = 0; - hres = UrlMkGetSessionOption(URLMON_OPTION_USERAGENT, str2, saved+10, &size, 0); - ok(hres == E_OUTOFMEMORY, "UrlMkGetSessionOption failed: %08x\n", hres); - ok(size == saved, "size = %d, expected %d\n", size, saved); - ok(sizeof(expected) <= strlen(str2) && !memcmp(expected, str2, sizeof(expected)-1), - "user agent was \"%s\", expected to start with \"%s\"\n", - str2, expected); - - size = 0; - str2[0] = 0; - hres = UrlMkGetSessionOption(URLMON_OPTION_USERAGENT, str2, saved, &size, 0); - ok(hres == E_OUTOFMEMORY, "UrlMkGetSessionOption failed: %08x\n", hres); - ok(size == saved, "size = %d, expected %d\n", size, saved); - ok(sizeof(expected) <= strlen(str2) && !memcmp(expected, str2, sizeof(expected)-1), - "user agent was \"%s\", expected to start with \"%s\"\n", - str2, expected); - - size = saved; - str2[0] = 0; - hres = UrlMkGetSessionOption(URLMON_OPTION_USERAGENT, str2, saved-1, &size, 0); - ok(hres == E_OUTOFMEMORY, "UrlMkGetSessionOption failed: %08x\n", hres); - ok(size == saved, "size = %d, expected %d\n", size, saved); - ok(!str2[0], "buf changed\n"); - - size = saved; - str2[0] = 0; - hres = UrlMkGetSessionOption(URLMON_OPTION_USERAGENT, str2, saved, NULL, 0); - ok(hres == E_INVALIDARG, "UrlMkGetSessionOption failed: %08x\n", hres); - ok(!str2[0], "buf changed\n"); - - hres = UrlMkSetSessionOption(URLMON_OPTION_USERAGENT, test_str, sizeof(test_str), 0); - ok(hres == S_OK, "UrlMkSetSessionOption failed: %08x\n", hres); - - size = 0; - str2[0] = 0; - hres = UrlMkGetSessionOption(URLMON_OPTION_USERAGENT, str2, saved, &size, 0); - ok(hres == E_OUTOFMEMORY, "UrlMkGetSessionOption failed: %08x\n", hres); - ok(size == sizeof(test_str) && !memcmp(str2, test_str, sizeof(test_str)), "wrong user agent\n"); - - hres = UrlMkSetSessionOption(URLMON_OPTION_USERAGENT, test2_str, sizeof(test2_str), 0); - ok(hres == S_OK, "UrlMkSetSessionOption failed: %08x\n", hres); - - size = 0; - str2[0] = 0; - hres = UrlMkGetSessionOption(URLMON_OPTION_USERAGENT, str2, saved, &size, 0); - ok(hres == E_OUTOFMEMORY, "UrlMkGetSessionOption failed: %08x\n", hres); - ok(size == sizeof(test_str) && !memcmp(str2, test_str, sizeof(test_str)), "wrong user agent\n"); - - hres = UrlMkSetSessionOption(URLMON_OPTION_USERAGENT, test_str, 2, 0); - ok(hres == S_OK, "UrlMkSetSessionOption failed: %08x\n", hres); - - size = 0; - str2[0] = 0; - hres = UrlMkGetSessionOption(URLMON_OPTION_USERAGENT, str2, saved, &size, 0); - ok(hres == E_OUTOFMEMORY, "UrlMkGetSessionOption failed: %08x\n", hres); - ok(size == 3 && !strcmp(str2, "te"), "wrong user agent\n"); - - hres = UrlMkSetSessionOption(URLMON_OPTION_USERAGENT, test_str, 0, 0); - ok(hres == E_INVALIDARG, "UrlMkSetSessionOption failed: %08x\n", hres); - - hres = UrlMkSetSessionOption(URLMON_OPTION_USERAGENT, NULL, sizeof(test_str), 0); - ok(hres == E_INVALIDARG, "UrlMkSetSessionOption failed: %08x\n", hres); - - hres = UrlMkSetSessionOption(URLMON_OPTION_USERAGENT, NULL, 0, 0); - ok(hres == E_INVALIDARG, "UrlMkSetSessionOption failed: %08x\n", hres); - + if (!str2) + { + skip("skipping rest of ObtainUserAgent tests, out of memory\n"); + } + else + { + saved = size; + hres = ObtainUserAgentString(0, str2, &size); + ok(hres == S_OK, "ObtainUserAgentString failed: %08x\n", hres); + ok(size == saved, "size=%d, expected %d\n", size, saved); + ok(strlen(expected) <= strlen(str2) && + !memcmp(expected, str2, strlen(expected)*sizeof(CHAR)), + "user agent was \"%s\", expected to start with \"%s\"\n", + str2, expected); + + size = saved+10; + hres = ObtainUserAgentString(0, str2, &size); + ok(hres == S_OK, "ObtainUserAgentString failed: %08x\n", hres); + ok(size == saved, "size=%d, expected %d\n", size, saved); + } HeapFree(GetProcessHeap(), 0, str2); } @@ -1350,7 +1277,7 @@ START_TEST(misc) test_ReleaseBindInfo(); test_CopyStgMedium(); test_UrlMkGetSessionOption(); - test_user_agent(); + test_ObtainUserAgentString(); test_MkParseDisplayNameEx(); OleUninitialize(); diff --git a/dlls/urlmon/tests/protocol.c b/dlls/urlmon/tests/protocol.c index 26ed8de7be8..44276b11830 100644 --- a/dlls/urlmon/tests/protocol.c +++ b/dlls/urlmon/tests/protocol.c @@ -195,18 +195,9 @@ static const char *debugstr_guid(REFIID riid) static int strcmp_wa(LPCWSTR strw, const char *stra) { - CHAR buf[512]; - WideCharToMultiByte(CP_ACP, 0, strw, -1, buf, sizeof(buf), NULL, NULL); - return lstrcmpA(stra, buf); -} - -/* lstrcmpW is not implemented on Win9x */ -static int strcmp_ww(LPCWSTR strw1, LPCWSTR strw2) -{ - CHAR stra1[512], stra2[512]; - WideCharToMultiByte(CP_ACP, 0, strw1, -1, stra1, MAX_PATH, NULL, NULL); - WideCharToMultiByte(CP_ACP, 0, strw2, -1, stra2, MAX_PATH, NULL, NULL); - return lstrcmpA(stra1, stra2); + WCHAR buf[512]; + MultiByteToWideChar(CP_ACP, 0, stra, -1, buf, sizeof(buf)/sizeof(WCHAR)); + return lstrcmpW(strw, buf); } static HRESULT WINAPI HttpSecurity_QueryInterface(IHttpSecurity *iface, REFIID riid, void **ppv) @@ -299,9 +290,9 @@ static HRESULT WINAPI HttpNegotiate_BeginningTransaction(IHttpNegotiate2 *iface, CHECK_EXPECT(BeginningTransaction); if(binding_test) - ok(!strcmp_ww(szURL, binding_urls[tested_protocol]), "szURL != http_url\n"); + ok(!lstrcmpW(szURL, binding_urls[tested_protocol]), "szURL != http_url\n"); else - ok(!strcmp_ww(szURL, http_url), "szURL != http_url\n"); + ok(!lstrcmpW(szURL, http_url), "szURL != http_url\n"); ok(!dwReserved, "dwReserved=%d, expected 0\n", dwReserved); ok(pszAdditionalHeaders != NULL, "pszAdditionalHeaders == NULL\n"); if(pszAdditionalHeaders) @@ -316,7 +307,7 @@ static HRESULT WINAPI HttpNegotiate_BeginningTransaction(IHttpNegotiate2 *iface, skip("Out of memory\n"); return E_OUTOFMEMORY; } - memcpy(addl_headers, wszHeaders, sizeof(wszHeaders)); + lstrcpyW(addl_headers, wszHeaders); *pszAdditionalHeaders = addl_headers; } } @@ -565,9 +556,9 @@ static HRESULT WINAPI ProtocolSink_ReportProgress(IInternetProtocolSink *iface, ok(szStatusText != NULL, "szStatusText == NULL\n"); if(szStatusText) { if(binding_test) - ok(!strcmp_ww(szStatusText, expect_wsz), "unexpected szStatusText\n"); + ok(!lstrcmpW(szStatusText, expect_wsz), "unexpected szStatusText\n"); else if(tested_protocol == FILE_TEST) - ok(!strcmp_ww(szStatusText, file_name), "szStatusText = \"%s\"\n", debugstr_w(szStatusText)); + ok(!lstrcmpW(szStatusText, file_name), "szStatusText = \"%s\"\n", debugstr_w(szStatusText)); else ok(szStatusText != NULL, "szStatusText == NULL\n"); } @@ -592,12 +583,12 @@ static HRESULT WINAPI ProtocolSink_ReportProgress(IInternetProtocolSink *iface, CHECK_EXPECT(ReportProgress_VERIFIEDMIMETYPEAVAILABLE); ok(szStatusText != NULL, "szStatusText == NULL\n"); if(szStatusText) - ok(!strcmp_ww(szStatusText, text_htmlW), "szStatusText != text/html\n"); + ok(!lstrcmpW(szStatusText, text_htmlW), "szStatusText != text/html\n"); break; case BINDSTATUS_PROTOCOLCLASSID: CHECK_EXPECT(ReportProgress_PROTOCOLCLASSID); ok(szStatusText != NULL, "szStatusText == NULL\n"); - ok(!strcmp_ww(szStatusText, null_guid), "unexpected szStatusText\n"); + ok(!lstrcmpW(szStatusText, null_guid), "unexpected szStatusText\n"); break; case BINDSTATUS_COOKIE_SENT: CHECK_EXPECT(ReportProgress_COOKIE_SENT); @@ -626,7 +617,7 @@ static HRESULT WINAPI ProtocolSink_ReportProgress(IInternetProtocolSink *iface, break; case BINDSTATUS_DECODING: CHECK_EXPECT(ReportProgress_DECODING); - ok(!strcmp_ww(szStatusText, gzipW), "szStatusText = %s\n", debugstr_w(szStatusText)); + ok(!lstrcmpW(szStatusText, gzipW), "szStatusText = %s\n", debugstr_w(szStatusText)); break; default: ok(0, "Unexpected status %d\n", ulStatusCode); @@ -853,8 +844,6 @@ static IInternetProtocolSink mime_protocol_sink = { &mime_protocol_sink_vtbl }; static HRESULT QueryInterface(REFIID riid, void **ppv) { - static const IID IID_undocumented = {0x58DFC7D0,0x5381,0x43E5,{0x9D,0x72,0x4C,0xDD,0xE4,0xCB,0x0F,0x1A}}; - *ppv = NULL; if(IsEqualGUID(&IID_IUnknown, riid) || IsEqualGUID(&IID_IInternetProtocolSink, riid)) @@ -864,10 +853,6 @@ static HRESULT QueryInterface(REFIID riid, void **ppv) if(IsEqualGUID(&IID_IUriContainer, riid)) return E_NOINTERFACE; /* TODO */ - /* NOTE: IE8 queries for undocumented {58DFC7D0-5381-43E5-9D72-4CDDE4CB0F1A} interface. */ - if(IsEqualGUID(&IID_undocumented, riid)) - return E_NOINTERFACE; - if(*ppv) return S_OK; @@ -1227,7 +1212,7 @@ static HRESULT WINAPI ProtocolEmul_Start(IInternetProtocol *iface, LPCWSTR szUrl ok(hres == S_OK, "GetBindString(BINDSTRING_USER_AGETNT) failed: %08x\n", hres); ok(fetched == 1, "fetched = %d, expected 254\n", fetched); ok(ua != NULL, "ua = %p\n", ua); - ok(!strcmp_ww(ua, user_agentW), "unexpected user agent %s\n", debugstr_w(ua)); + ok(!lstrcmpW(ua, user_agentW), "unexpected user agent %s\n", debugstr_w(ua)); CoTaskMemFree(ua); fetched = 256; @@ -1239,7 +1224,7 @@ static HRESULT WINAPI ProtocolEmul_Start(IInternetProtocol *iface, LPCWSTR szUrl ok(hres == S_OK, "GetBindString(BINDSTRING_ACCEPT_MIMES) failed: %08x\n", hres); ok(fetched == 1, "fetched = %d, expected 1\n", fetched); - ok(!strcmp_ww(acc_mimeW, accept_mimes[0]), "unexpected mimes %s\n", debugstr_w(accept_mimes[0])); + ok(!lstrcmpW(acc_mimeW, accept_mimes[0]), "unexpected mimes %s\n", debugstr_w(accept_mimes[0])); hres = IInternetBindInfo_QueryInterface(pOIBindInfo, &IID_IServiceProvider, (void**)&service_provider); @@ -1570,7 +1555,7 @@ static HRESULT WINAPI MimeProtocol_Start(IInternetProtocol *iface, LPCWSTR szUrl CHECK_EXPECT(MimeFilter_Start); - ok(!strcmp_ww(szUrl, gzipW), "wrong url %s\n", debugstr_w(szUrl)); + ok(!lstrcmpW(szUrl, gzipW), "wrong url %s\n", debugstr_w(szUrl)); ok(grfPI == (PI_FILTER_MODE|PI_FORCE_ASYNC), "grfPI=%x, expected PI_FILTER_MODE|PI_FORCE_ASYNC\n", grfPI); ok(dwReserved, "dwReserved == 0\n"); ok(pOIProtSink != NULL, "pOIProtSink == NULL\n"); @@ -1630,7 +1615,7 @@ static HRESULT WINAPI MimeProtocol_Start(IInternetProtocol *iface, LPCWSTR szUrl hres = IInternetBindInfo_GetBindString(pOIBindInfo, BINDSTRING_URL, &url_str, 1, &fetched); ok(hres == S_OK, "GetBindString(BINDSTRING_URL) failed: %08x\n", hres); ok(fetched == 1, "fetched = %d\n", fetched); - ok(!strcmp_ww(url_str, binding_urls[tested_protocol]), "wrong url_str %s\n", debugstr_w(url_str)); + ok(!lstrcmpW(url_str, binding_urls[tested_protocol]), "wrong url_str %s\n", debugstr_w(url_str)); CoTaskMemFree(url_str); CHECK_CALLED(GetBindString_URL); @@ -1801,9 +1786,8 @@ static const IClassFactoryVtbl MimeFilterCFVtbl = { static IClassFactory mimefilter_cf = { &MimeFilterCFVtbl }; -#define TEST_BINDING 0x01 -#define TEST_FILTER 0x02 -#define TEST_FIRST_HTTP 0x04 +#define TEST_BINDING 1 +#define TEST_FILTER 2 static void init_test(int prot, DWORD flags) { @@ -1819,9 +1803,6 @@ static void init_test(int prot, DWORD flags) ResetEvent(event_complete2); async_protocol = binding_protocol = filtered_protocol = NULL; filtered_sink = NULL; - http_is_first = (flags & TEST_FIRST_HTTP) != 0; - first_data_notif = TRUE; - state = 0; } static void test_priority(IInternetProtocol *protocol) @@ -2147,11 +2128,14 @@ static void test_file_protocol(void) { test_file_protocol_fail(); } -static BOOL http_protocol_start(LPCWSTR url) +static BOOL http_protocol_start(LPCWSTR url, BOOL is_first) { static BOOL got_user_agent = FALSE; HRESULT hres; + first_data_notif = TRUE; + state = 0; + SET_EXPECT(GetBindInfo); if (!(bindf & BINDF_FROMURLMON)) SET_EXPECT(ReportProgress_DIRECTBIND); @@ -2236,17 +2220,17 @@ static void test_http_info(IInternetProtocol *protocol) /* is_first refers to whether this is the first call to this function * _for this url_ */ -static void test_http_protocol_url(LPCWSTR url, int prot, DWORD flags) +static void test_http_protocol_url(LPCWSTR url, BOOL is_https, BOOL is_first) { IInternetProtocolInfo *protocol_info; IClassFactory *factory; IUnknown *unk; HRESULT hres; - init_test(prot, flags); http_url = url; + http_is_first = is_first; - hres = CoGetClassObject(prot == HTTPS_TEST ? &CLSID_HttpSProtocol : &CLSID_HttpProtocol, + hres = CoGetClassObject(is_https ? &CLSID_HttpSProtocol : &CLSID_HttpProtocol, CLSCTX_INPROC_SERVER, NULL, &IID_IUnknown, (void**)&unk); ok(hres == S_OK, "CoGetClassObject failed: %08x\n", hres); if(FAILED(hres)) @@ -2278,7 +2262,7 @@ static void test_http_protocol_url(LPCWSTR url, int prot, DWORD flags) SET_EXPECT(ReportProgress_CONNECTING); SET_EXPECT(ReportProgress_SENDINGREQUEST); SET_EXPECT(ReportProgress_PROXYDETECTING); - if(prot == HTTP_TEST) + if(! is_https) SET_EXPECT(ReportProgress_CACHEFILENAMEAVAILABLE); else SET_EXPECT(QueryService_HttpSecurity); @@ -2290,7 +2274,7 @@ static void test_http_protocol_url(LPCWSTR url, int prot, DWORD flags) SET_EXPECT(Switch); } - if(!http_protocol_start(url)) + if(!http_protocol_start(url, is_first)) return; SET_EXPECT(ReportResult); @@ -2305,7 +2289,7 @@ static void test_http_protocol_url(LPCWSTR url, int prot, DWORD flags) CHECK_CALLED(Switch); else CHECK_CALLED(ReportData); - if(prot == HTTPS_TEST) + if (is_https) CLEAR_CALLED(QueryService_HttpSecurity); while(1) { @@ -2333,7 +2317,7 @@ static void test_http_protocol_url(LPCWSTR url, int prot, DWORD flags) } ok(hres == S_FALSE, "Read failed: %08x\n", hres); CHECK_CALLED(ReportResult); - if(prot == HTTPS_TEST) + if (is_https) CLEAR_CALLED(ReportProgress_SENDINGREQUEST); test_protocol_terminate(async_protocol); @@ -2355,23 +2339,24 @@ static void test_http_protocol(void) 'p','o','s','t','t','e','s','t','.','p','h','p',0}; trace("Testing http protocol (not from urlmon)...\n"); + tested_protocol = HTTP_TEST; bindf = BINDF_ASYNCHRONOUS | BINDF_ASYNCSTORAGE | BINDF_PULLDATA; - test_http_protocol_url(winehq_url, HTTP_TEST, TEST_FIRST_HTTP); + test_http_protocol_url(winehq_url, FALSE, TRUE); trace("Testing http protocol (from urlmon)...\n"); bindf = BINDF_ASYNCHRONOUS | BINDF_ASYNCSTORAGE | BINDF_PULLDATA | BINDF_FROMURLMON; - test_http_protocol_url(winehq_url, HTTP_TEST, 0); + test_http_protocol_url(winehq_url, FALSE, FALSE); trace("Testing http protocol (to file)...\n"); bindf = BINDF_ASYNCHRONOUS | BINDF_ASYNCSTORAGE | BINDF_PULLDATA | BINDF_FROMURLMON | BINDF_NEEDFILE; - test_http_protocol_url(winehq_url, HTTP_TEST, 0); + test_http_protocol_url(winehq_url, FALSE, FALSE); trace("Testing http protocol (post data)...\n"); http_post_test = TRUE; /* Without this flag we get a ReportProgress_CACHEFILENAMEAVAILABLE * notification with BINDVERB_POST */ bindf = BINDF_ASYNCHRONOUS | BINDF_ASYNCSTORAGE | BINDF_PULLDATA | BINDF_FROMURLMON | BINDF_NOWRITECACHE; - test_http_protocol_url(posttest_url, HTTP_TEST, TEST_FIRST_HTTP); + test_http_protocol_url(posttest_url, FALSE, TRUE); http_post_test = FALSE; } @@ -2382,8 +2367,9 @@ static void test_https_protocol(void) '.','c','o','m','/','t','e','s','t','.','h','t','m','l',0}; trace("Testing https protocol (from urlmon)...\n"); + init_test(HTTPS_TEST, 0); bindf = BINDF_ASYNCHRONOUS | BINDF_ASYNCSTORAGE | BINDF_PULLDATA | BINDF_FROMURLMON | BINDF_NOWRITECACHE; - test_http_protocol_url(codeweavers_url, HTTPS_TEST, TEST_FIRST_HTTP); + test_http_protocol_url(codeweavers_url, TRUE, TRUE); } diff --git a/dlls/urlmon/tests/sec_mgr.c b/dlls/urlmon/tests/sec_mgr.c index c7774eca3d8..f90f5a5b96c 100644 --- a/dlls/urlmon/tests/sec_mgr.c +++ b/dlls/urlmon/tests/sec_mgr.c @@ -1,6 +1,5 @@ /* * Copyright 2005-2006 Jacek Caban for CodeWeavers - * Copyright 2009 Detlef Riekenberg * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -21,9 +20,6 @@ #define CONST_VTABLE #define NONAMELESSUNION -/* needed for IInternetZoneManagerEx2 */ -#define _WIN32_IE 0x0700 - #include #include #include @@ -285,116 +281,7 @@ static void test_polices(void) IInternetZoneManager_Release(zonemgr); } -static void test_CoInternetCreateZoneManager(void) -{ - IInternetZoneManager *zonemgr = NULL; - IUnknown *punk = NULL; - HRESULT hr; - - hr = CoInternetCreateZoneManager(NULL, &zonemgr, 0); - ok(hr == S_OK, "CoInternetCreateZoneManager result: 0x%x\n", hr); - if (FAILED(hr)) - return; - - hr = IInternetZoneManager_QueryInterface(zonemgr, &IID_IUnknown, (void **) &punk); - ok(SUCCEEDED(hr), "got 0x%x with %p (expected Success)\n", hr, punk); - if (punk) - IUnknown_Release(punk); - - hr = IInternetZoneManager_QueryInterface(zonemgr, &IID_IInternetZoneManager, (void **) &punk); - ok(SUCCEEDED(hr), "got 0x%x with %p (expected Success)\n", hr, punk); - if (punk) - IUnknown_Release(punk); - - - hr = IInternetZoneManager_QueryInterface(zonemgr, &IID_IInternetZoneManagerEx, (void **) &punk); - if (SUCCEEDED(hr)) { - IUnknown_Release(punk); - - hr = IInternetZoneManager_QueryInterface(zonemgr, &IID_IInternetZoneManagerEx2, (void **) &punk); - if (punk) - IUnknown_Release(punk); - else - win_skip("InternetZoneManagerEx2 not supported\n"); - - } - else - win_skip("InternetZoneManagerEx not supported\n"); - - hr = IInternetZoneManager_Release(zonemgr); - ok(hr == S_OK, "got 0x%x (expected S_OK)\n", hr); - -} - -static void test_CreateZoneEnumerator(void) -{ - IInternetZoneManager *zonemgr = NULL; - HRESULT hr; - DWORD dwEnum; - DWORD dwEnum2; - DWORD dwCount; - DWORD dwCount2; - - hr = CoInternetCreateZoneManager(NULL, &zonemgr, 0); - ok(hr == S_OK, "CoInternetCreateZoneManager result: 0x%x\n", hr); - if (FAILED(hr)) - return; - - dwEnum=0xdeadbeef; - hr = IInternetZoneManager_CreateZoneEnumerator(zonemgr, &dwEnum, NULL, 0); - ok((hr == E_INVALIDARG) && (dwEnum == 0xdeadbeef), - "got 0x%x with 0x%x (expected E_INVALIDARG with 0xdeadbeef)\n", hr, dwEnum); - - dwCount=0xdeadbeef; - hr = IInternetZoneManager_CreateZoneEnumerator(zonemgr, NULL, &dwCount, 0); - ok((hr == E_INVALIDARG) && (dwCount == 0xdeadbeef), - "got 0x%x and 0x%x (expected E_INVALIDARG and 0xdeadbeef)\n", hr, dwCount); - - dwEnum=0xdeadbeef; - dwCount=0xdeadbeef; - hr = IInternetZoneManager_CreateZoneEnumerator(zonemgr, &dwEnum, &dwCount, 0xffffffff); - ok((hr == E_INVALIDARG) && (dwEnum == 0xdeadbeef) && (dwCount == 0xdeadbeef), - "got 0x%x with 0x%x and 0x%x (expected E_INVALIDARG with 0xdeadbeef and 0xdeadbeef)\n", - hr, dwEnum, dwCount); - - dwEnum=0xdeadbeef; - dwCount=0xdeadbeef; - hr = IInternetZoneManager_CreateZoneEnumerator(zonemgr, &dwEnum, &dwCount, 1); - ok((hr == E_INVALIDARG) && (dwEnum == 0xdeadbeef) && (dwCount == 0xdeadbeef), - "got 0x%x with 0x%x and 0x%x (expected E_INVALIDARG with 0xdeadbeef and 0xdeadbeef)\n", - hr, dwEnum, dwCount); - - dwEnum=0xdeadbeef; - dwCount=0xdeadbeef; - /* Normal use */ - hr = IInternetZoneManager_CreateZoneEnumerator(zonemgr, &dwEnum, &dwCount, 0); - ok(hr == S_OK, "got 0x%x (expected S_OK)\n", hr); - - if (SUCCEEDED(hr)) { - dwEnum2=0xdeadbeef; - dwCount2=0xdeadbeef; - hr = IInternetZoneManager_CreateZoneEnumerator(zonemgr, &dwEnum2, &dwCount2, 0); - ok(hr == S_OK, "got 0x%x (expected S_OK)\n", hr); - if (SUCCEEDED(hr)) { - /* native urlmon has an incrementing counter for dwEnum */ - hr = IInternetZoneManager_DestroyZoneEnumerator(zonemgr, dwEnum2); - ok(hr == S_OK, "got 0x%x (expected S_OK)\n", hr); - } - - hr = IInternetZoneManager_DestroyZoneEnumerator(zonemgr, dwEnum); - ok(hr == S_OK, "got 0x%x (expected S_OK)\n", hr); - - /* Destroy the Enumerator twice is detected and handled in native urlmon */ - hr = IInternetZoneManager_DestroyZoneEnumerator(zonemgr, dwEnum); - ok((hr == E_INVALIDARG), "got 0x%x (expected E_INVALIDARG)\n", hr); - } - - /* ::Release succeed also, when a ::DestroyZoneEnumerator is missing */ - hr = IInternetZoneManager_Release(zonemgr); - ok(hr == S_OK, "got 0x%x (expected S_OK)\n", hr); -} - -static void test_GetZoneActionPolicy(void) +static void test_ZoneManager(void) { IInternetZoneManager *zonemgr = NULL; BYTE buf[32]; @@ -434,108 +321,6 @@ static void test_GetZoneActionPolicy(void) IInternetZoneManager_Release(zonemgr); } -static void test_GetZoneAt(void) -{ - IInternetZoneManager *zonemgr = NULL; - HRESULT hr; - DWORD dwEnum; - DWORD dwCount; - DWORD dwZone; - DWORD i; - - hr = CoInternetCreateZoneManager(NULL, &zonemgr, 0); - ok(hr == S_OK, "CoInternetCreateZoneManager result: 0x%x\n", hr); - if (FAILED(hr)) - return; - - hr = IInternetZoneManager_CreateZoneEnumerator(zonemgr, &dwEnum, &dwCount, 0); - if (FAILED(hr)) - goto cleanup; - - if (0) { - /* this crashes with native urlmon */ - hr = IInternetZoneManager_GetZoneAt(zonemgr, dwEnum, 0, NULL); - } - - dwZone = 0xdeadbeef; - hr = IInternetZoneManager_GetZoneAt(zonemgr, 0xdeadbeef, 0, &dwZone); - ok(hr == E_INVALIDARG, - "got 0x%x with 0x%x (expected E_INVALIDARG)\n", hr, dwZone); - - for (i = 0; i < dwCount; i++) - { - dwZone = 0xdeadbeef; - hr = IInternetZoneManager_GetZoneAt(zonemgr, dwEnum, i, &dwZone); - ok(hr == S_OK, "#%d: got x%x with %d (expected S_OK)\n", i, hr, dwZone); - } - - dwZone = 0xdeadbeef; - /* MSDN (index .. must be .. less than or equal to) is wrong */ - hr = IInternetZoneManager_GetZoneAt(zonemgr, dwEnum, dwCount, &dwZone); - ok(hr == E_INVALIDARG, - "got 0x%x with 0x%x (expected E_INVALIDARG)\n", hr, dwZone); - - hr = IInternetZoneManager_DestroyZoneEnumerator(zonemgr, dwEnum); - ok(hr == S_OK, "got 0x%x (expected S_OK)\n", hr); - -cleanup: - hr = IInternetZoneManager_Release(zonemgr); - ok(hr == S_OK, "got 0x%x (expected S_OK)\n", hr); -} - -static void test_GetZoneAttributes(void) -{ - IInternetZoneManager *zonemgr = NULL; - CHAR buffer [sizeof(ZONEATTRIBUTES) + 32]; - ZONEATTRIBUTES* pZA = (ZONEATTRIBUTES*) buffer; - HRESULT hr; - DWORD i; - - hr = CoInternetCreateZoneManager(NULL, &zonemgr, 0); - ok(hr == S_OK, "CoInternetCreateZoneManager result: 0x%x\n", hr); - if (FAILED(hr)) - return; - - /* native urlmon has Zone "0" upto Zone "4" since IE4 */ - for (i = 0; i < 5; i++) { - memset(buffer, -1, sizeof(buffer)); - hr = IInternetZoneManager_GetZoneAttributes(zonemgr, i, pZA); - ok(hr == S_OK, "#%d: got 0x%x (expected S_OK)\n", i, hr); - } - - /* IE8 no longer set cbSize */ - memset(buffer, -1, sizeof(buffer)); - pZA->cbSize = 0; - hr = IInternetZoneManager_GetZoneAttributes(zonemgr, 0, pZA); - ok(hr == S_OK, "got 0x%x (expected S_OK)\n", hr); - ok((pZA->cbSize == 0) || (pZA->cbSize == sizeof(ZONEATTRIBUTES)), - "got cbSize = %d (expected 0)\n", pZA->cbSize); - - memset(buffer, -1, sizeof(buffer)); - pZA->cbSize = 64; - hr = IInternetZoneManager_GetZoneAttributes(zonemgr, 0, pZA); - ok(hr == S_OK, "got 0x%x (expected S_OK)\n", hr); - ok((pZA->cbSize == 64) || (pZA->cbSize == sizeof(ZONEATTRIBUTES)), - "got cbSize = %d (expected 64)\n", pZA->cbSize); - - memset(buffer, -1, sizeof(buffer)); - hr = IInternetZoneManager_GetZoneAttributes(zonemgr, 0, pZA); - ok(hr == S_OK, "got 0x%x (expected S_OK)\n", hr); - ok((pZA->cbSize == 0xffffffff) || (pZA->cbSize == sizeof(ZONEATTRIBUTES)), - "got cbSize = 0x%x (expected 0xffffffff)\n", pZA->cbSize); - - /* IE8 no longer fail on invalid zones */ - memset(buffer, -1, sizeof(buffer)); - hr = IInternetZoneManager_GetZoneAttributes(zonemgr, 0xdeadbeef, pZA); - ok(hr == S_OK || (hr == E_FAIL), - "got 0x%x (expected S_OK or E_FAIL)\n", hr); - - hr = IInternetZoneManager_GetZoneAttributes(zonemgr, 0, NULL); - ok(hr == E_INVALIDARG, "got 0x%x (expected E_INVALIDARG)\n", hr); - - hr = IInternetZoneManager_Release(zonemgr); - ok(hr == S_OK, "got 0x%x (expected S_OK)\n", hr); -} START_TEST(sec_mgr) @@ -544,11 +329,7 @@ START_TEST(sec_mgr) test_SecurityManager(); test_polices(); - test_CoInternetCreateZoneManager(); - test_CreateZoneEnumerator(); - test_GetZoneActionPolicy(); - test_GetZoneAt(); - test_GetZoneAttributes(); + test_ZoneManager(); OleUninitialize(); } diff --git a/dlls/urlmon/tests/url.c b/dlls/urlmon/tests/url.c index b5bf79c03fc..c3815d67576 100644 --- a/dlls/urlmon/tests/url.c +++ b/dlls/urlmon/tests/url.c @@ -81,7 +81,6 @@ DEFINE_GUID(IID_IBindStatusCallbackHolder,0x79eac9cc,0xbaf9,0x11ce,0x8c,0x82,0x0 DEFINE_EXPECT(QueryInterface_IServiceProvider); DEFINE_EXPECT(QueryInterface_IHttpNegotiate); DEFINE_EXPECT(QueryInterface_IBindStatusCallback); -DEFINE_EXPECT(QueryInterface_IBindStatusCallbackEx); DEFINE_EXPECT(QueryInterface_IBindStatusCallbackHolder); DEFINE_EXPECT(QueryInterface_IInternetBindInfo); DEFINE_EXPECT(QueryInterface_IAuthenticate); @@ -94,7 +93,6 @@ DEFINE_EXPECT(OnResponse); DEFINE_EXPECT(QueryInterface_IHttpNegotiate2); DEFINE_EXPECT(GetRootSecurityId); DEFINE_EXPECT(GetBindInfo); -DEFINE_EXPECT(GetBindInfoEx); DEFINE_EXPECT(OnStartBinding); DEFINE_EXPECT(OnProgress_FINDINGRESOURCE); DEFINE_EXPECT(OnProgress_CONNECTING); @@ -178,7 +176,7 @@ static IInternetProtocolSink *protocol_sink = NULL; static IBinding *current_binding; static HANDLE complete_event, complete_event2; static HRESULT binding_hres; -static BOOL have_IHttpNegotiate2, use_bscex; +static BOOL have_IHttpNegotiate2; static LPCWSTR urls[] = { WINE_ABOUT_URL, @@ -564,9 +562,10 @@ static HRESULT WINAPI Protocol_Start(IInternetProtocol *iface, LPCWSTR szUrl, SET_EXPECT(QueryService_IInternetBindInfo); hres = IInternetBindInfo_GetBindString(pOIBindInfo, BINDSTRING_USER_AGENT, &ua, 1, &fetched); - CLEAR_CALLED(QueryInterface_IInternetBindInfo); /* IE <8 */ - CLEAR_CALLED(QueryService_IInternetBindInfo); /* IE <8 */ - + todo_wine { + CHECK_CALLED(QueryInterface_IInternetBindInfo); + CHECK_CALLED(QueryService_IInternetBindInfo); + } ok(hres == E_NOINTERFACE, "GetBindString(BINDSTRING_USER_AGETNT) failed: %08x\n", hres); ok(fetched == 256, "fetched = %d, expected 254\n", fetched); @@ -596,14 +595,12 @@ static HRESULT WINAPI Protocol_Start(IInternetProtocol *iface, LPCWSTR szUrl, SET_EXPECT(QueryInterface_IHttpNegotiate); hres = IServiceProvider_QueryService(service_provider, &IID_IHttpNegotiate, &IID_IHttpNegotiate, (void**)&http_negotiate); - CLEAR_CALLED(QueryInterface_IHttpNegotiate); /* IE <8 */ + CHECK_CALLED(QueryInterface_IHttpNegotiate); ok(hres == S_OK, "QueryService failed: %08x\n", hres); SET_EXPECT(BeginningTransaction); - SET_EXPECT(QueryInterface_IHttpNegotiate); hres = IHttpNegotiate_BeginningTransaction(http_negotiate, urls[test_protocol], NULL, 0, &additional_headers); - CHECK_CALLED_BROKEN(QueryInterface_IHttpNegotiate); CHECK_CALLED(BeginningTransaction); IHttpNegotiate_Release(http_negotiate); ok(hres == S_OK, "BeginningTransction failed: %08x\n", hres); @@ -612,14 +609,12 @@ static HRESULT WINAPI Protocol_Start(IInternetProtocol *iface, LPCWSTR szUrl, SET_EXPECT(QueryInterface_IHttpNegotiate2); hres = IServiceProvider_QueryService(service_provider, &IID_IHttpNegotiate2, &IID_IHttpNegotiate2, (void**)&http_negotiate2); - CLEAR_CALLED(QueryInterface_IHttpNegotiate2); /* IE <8 */ + CHECK_CALLED(QueryInterface_IHttpNegotiate2); ok(hres == S_OK, "QueryService failed: %08x\n", hres); size = 512; - SET_EXPECT(QueryInterface_IHttpNegotiate2); SET_EXPECT(GetRootSecurityId); hres = IHttpNegotiate2_GetRootSecurityId(http_negotiate2, sec_id, &size, 0); - CHECK_CALLED_BROKEN(QueryInterface_IHttpNegotiate2); CHECK_CALLED(GetRootSecurityId); IHttpNegotiate2_Release(http_negotiate2); ok(hres == E_FAIL, "GetRootSecurityId failed: %08x, expected E_FAIL\n", hres); @@ -770,10 +765,8 @@ static HRESULT WINAPI Protocol_Continue(IInternetProtocol *iface, &IID_IHttpNegotiate, (void**)&http_negotiate); ok(hres == S_OK, "Could not get IHttpNegotiate\n"); - SET_EXPECT(QueryInterface_IHttpNegotiate); SET_EXPECT(OnResponse); hres = IHttpNegotiate_OnResponse(http_negotiate, 200, header, NULL, NULL); - CHECK_CALLED_BROKEN(QueryInterface_IHttpNegotiate); CHECK_CALLED(OnResponse); IHttpNegotiate_Release(http_negotiate); ok(hres == S_OK, "OnResponse failed: %08x\n", hres); @@ -1119,9 +1112,9 @@ static IServiceProviderVtbl ServiceProviderVtbl = { static IServiceProvider ServiceProvider = { &ServiceProviderVtbl }; -static IBindStatusCallbackEx objbsc; +static IBindStatusCallback objbsc; -static HRESULT WINAPI statusclb_QueryInterface(IBindStatusCallbackEx *iface, REFIID riid, void **ppv) +static HRESULT WINAPI statusclb_QueryInterface(IBindStatusCallback *iface, REFIID riid, void **ppv) { ok(GetCurrentThreadId() == thread_id, "wrong thread %d\n", GetCurrentThreadId()); @@ -1142,7 +1135,7 @@ static HRESULT WINAPI statusclb_QueryInterface(IBindStatusCallbackEx *iface, REF } else if (IsEqualGUID(&IID_IHttpNegotiate, riid)) { - CHECK_EXPECT2(QueryInterface_IHttpNegotiate); + CHECK_EXPECT(QueryInterface_IHttpNegotiate); *ppv = &HttpNegotiate; return S_OK; } @@ -1168,14 +1161,6 @@ static HRESULT WINAPI statusclb_QueryInterface(IBindStatusCallbackEx *iface, REF CHECK_EXPECT2(QueryInterface_IBindStatusCallbackHolder); return E_NOINTERFACE; } - else if(IsEqualGUID(&IID_IBindStatusCallbackEx, riid)) - { - CHECK_EXPECT(QueryInterface_IBindStatusCallbackEx); - if(!use_bscex) - return E_NOINTERFACE; - *ppv = iface; - return S_OK; - } else if(IsEqualGUID(&IID_IInternetBindInfo, riid)) { /* TODO */ @@ -1189,17 +1174,17 @@ static HRESULT WINAPI statusclb_QueryInterface(IBindStatusCallbackEx *iface, REF return E_NOINTERFACE; } -static ULONG WINAPI statusclb_AddRef(IBindStatusCallbackEx *iface) +static ULONG WINAPI statusclb_AddRef(IBindStatusCallback *iface) { return 2; } -static ULONG WINAPI statusclb_Release(IBindStatusCallbackEx *iface) +static ULONG WINAPI statusclb_Release(IBindStatusCallback *iface) { return 1; } -static HRESULT WINAPI statusclb_OnStartBinding(IBindStatusCallbackEx *iface, DWORD dwReserved, +static HRESULT WINAPI statusclb_OnStartBinding(IBindStatusCallback *iface, DWORD dwReserved, IBinding *pib) { IWinInetHttpInfo *http_info; @@ -1232,19 +1217,19 @@ static HRESULT WINAPI statusclb_OnStartBinding(IBindStatusCallbackEx *iface, DWO return S_OK; } -static HRESULT WINAPI statusclb_GetPriority(IBindStatusCallbackEx *iface, LONG *pnPriority) +static HRESULT WINAPI statusclb_GetPriority(IBindStatusCallback *iface, LONG *pnPriority) { ok(0, "unexpected call\n"); return E_NOTIMPL; } -static HRESULT WINAPI statusclb_OnLowResource(IBindStatusCallbackEx *iface, DWORD reserved) +static HRESULT WINAPI statusclb_OnLowResource(IBindStatusCallback *iface, DWORD reserved) { ok(0, "unexpected call\n"); return E_NOTIMPL; } -static HRESULT WINAPI statusclb_OnProgress(IBindStatusCallbackEx *iface, ULONG ulProgress, +static HRESULT WINAPI statusclb_OnProgress(IBindStatusCallback *iface, ULONG ulProgress, ULONG ulProgressMax, ULONG ulStatusCode, LPCWSTR szStatusText) { ok(GetCurrentThreadId() == thread_id, "wrong thread %d\n", GetCurrentThreadId()); @@ -1401,7 +1386,7 @@ static HRESULT WINAPI statusclb_OnProgress(IBindStatusCallbackEx *iface, ULONG u return S_OK; } -static HRESULT WINAPI statusclb_OnStopBinding(IBindStatusCallbackEx *iface, HRESULT hresult, LPCWSTR szError) +static HRESULT WINAPI statusclb_OnStopBinding(IBindStatusCallback *iface, HRESULT hresult, LPCWSTR szError) { if(iface == &objbsc) { CHECK_EXPECT(Obj_OnStopBinding); @@ -1432,7 +1417,7 @@ static HRESULT WINAPI statusclb_OnStopBinding(IBindStatusCallbackEx *iface, HRES return S_OK; } -static HRESULT WINAPI statusclb_GetBindInfo(IBindStatusCallbackEx *iface, DWORD *grfBINDF, BINDINFO *pbindinfo) +static HRESULT WINAPI statusclb_GetBindInfo(IBindStatusCallback *iface, DWORD *grfBINDF, BINDINFO *pbindinfo) { DWORD cbSize; @@ -1451,7 +1436,7 @@ static HRESULT WINAPI statusclb_GetBindInfo(IBindStatusCallbackEx *iface, DWORD return S_OK; } -static HRESULT WINAPI statusclb_OnDataAvailable(IBindStatusCallbackEx *iface, DWORD grfBSCF, +static HRESULT WINAPI statusclb_OnDataAvailable(IBindStatusCallback *iface, DWORD grfBSCF, DWORD dwSize, FORMATETC* pformatetc, STGMEDIUM* pstgmed) { HRESULT hres; @@ -1530,7 +1515,7 @@ static HRESULT WINAPI statusclb_OnDataAvailable(IBindStatusCallbackEx *iface, DW return S_OK; } -static HRESULT WINAPI statusclb_OnObjectAvailable(IBindStatusCallbackEx *iface, REFIID riid, IUnknown *punk) +static HRESULT WINAPI statusclb_OnObjectAvailable(IBindStatusCallback *iface, REFIID riid, IUnknown *punk) { CHECK_EXPECT(OnObjectAvailable); @@ -1543,20 +1528,7 @@ static HRESULT WINAPI statusclb_OnObjectAvailable(IBindStatusCallbackEx *iface, return S_OK; } -static HRESULT WINAPI statusclb_GetBindInfoEx(IBindStatusCallbackEx *iface, DWORD *grfBINDF, BINDINFO *pbindinfo, - DWORD *grfBINDF2, DWORD *pdwReserved) -{ - CHECK_EXPECT(GetBindInfoEx); - - ok(grfBINDF != NULL, "grfBINDF == NULL\n"); - ok(grfBINDF2 != NULL, "grfBINDF2 == NULL\n"); - ok(pbindinfo != NULL, "pbindinfo == NULL\n"); - ok(pdwReserved != NULL, "dwReserved == NULL\n"); - - return S_OK; -} - -static const IBindStatusCallbackExVtbl BindStatusCallbackVtbl = { +static const IBindStatusCallbackVtbl BindStatusCallbackVtbl = { statusclb_QueryInterface, statusclb_AddRef, statusclb_Release, @@ -1567,12 +1539,11 @@ static const IBindStatusCallbackExVtbl BindStatusCallbackVtbl = { statusclb_OnStopBinding, statusclb_GetBindInfo, statusclb_OnDataAvailable, - statusclb_OnObjectAvailable, - statusclb_GetBindInfoEx + statusclb_OnObjectAvailable }; -static IBindStatusCallbackEx bsc = { &BindStatusCallbackVtbl }; -static IBindStatusCallbackEx objbsc = { &BindStatusCallbackVtbl }; +static IBindStatusCallback bsc = { &BindStatusCallbackVtbl }; +static IBindStatusCallback objbsc = { &BindStatusCallbackVtbl }; static HRESULT WINAPI MonikerProp_QueryInterface(IMonikerProp *iface, REFIID riid, void **ppv) { @@ -1688,11 +1659,10 @@ static HRESULT WINAPI PersistMoniker_Load(IPersistMoniker *iface, BOOL fFullyAva } SET_EXPECT(QueryInterface_IServiceProvider); - hres = RegisterBindStatusCallback(pibc, (IBindStatusCallback*)&bsc, NULL, 0); + hres = RegisterBindStatusCallback(pibc, &bsc, NULL, 0); ok(hres == S_OK, "RegisterBindStatusCallback failed: %08x\n", hres); CHECK_CALLED(QueryInterface_IServiceProvider); - SET_EXPECT(QueryInterface_IBindStatusCallbackEx); SET_EXPECT(GetBindInfo); SET_EXPECT(OnStartBinding); SET_EXPECT(OnProgress_BEGINDOWNLOADDATA); @@ -1708,7 +1678,6 @@ static HRESULT WINAPI PersistMoniker_Load(IPersistMoniker *iface, BOOL fFullyAva hres = IMoniker_BindToStorage(pimkName, pibc, NULL, &IID_IStream, (void**)&unk); ok(hres == S_OK, "Load failed: %08x\n", hres); - CLEAR_CALLED(QueryInterface_IBindStatusCallbackEx); /* IE 8 */ CHECK_CALLED(GetBindInfo); CHECK_CALLED(OnStartBinding); CHECK_CALLED(OnProgress_BEGINDOWNLOADDATA); @@ -1828,7 +1797,7 @@ static void test_CreateAsyncBindCtx(void) ok(hres == E_INVALIDARG, "CreateAsyncBindCtx failed. expected: E_INVALIDARG, got: %08x\n", hres); SET_EXPECT(QueryInterface_IServiceProvider); - hres = CreateAsyncBindCtx(0, (IBindStatusCallback*)&bsc, NULL, &bctx); + hres = CreateAsyncBindCtx(0, &bsc, NULL, &bctx); ok(hres == S_OK, "CreateAsyncBindCtx failed: %08x\n", hres); CHECK_CALLED(QueryInterface_IServiceProvider); @@ -1904,7 +1873,7 @@ static void test_CreateAsyncBindCtxEx(void) IBindCtx_Release(bctx_arg); SET_EXPECT(QueryInterface_IServiceProvider); - hres = CreateAsyncBindCtxEx(NULL, 0, (IBindStatusCallback*)&bsc, NULL, &bctx, 0); + hres = CreateAsyncBindCtxEx(NULL, 0, &bsc, NULL, &bctx, 0); ok(hres == S_OK, "CreateAsyncBindCtxEx failed: %08x\n", hres); CHECK_CALLED(QueryInterface_IServiceProvider); @@ -1932,52 +1901,6 @@ static void test_CreateAsyncBindCtxEx(void) IBindCtx_Release(bctx2); } -static void test_GetBindInfoEx(IBindStatusCallback *holder) -{ - IBindStatusCallbackEx *bscex; - BINDINFO bindinfo = {sizeof(bindinfo)}; - DWORD bindf, bindf2, dw; - HRESULT hres; - - hres = IBindStatusCallback_QueryInterface(holder, &IID_IBindStatusCallbackEx, (void**)&bscex); - if(FAILED(hres)) { - win_skip("IBindStatusCallbackEx not supported\n"); - return; - } - - use_bscex = TRUE; - - bindf = 0; - SET_EXPECT(QueryInterface_IBindStatusCallbackEx); - SET_EXPECT(GetBindInfoEx); - hres = IBindStatusCallback_GetBindInfo(holder, &bindf, &bindinfo); - ok(hres == S_OK, "GetBindInfo failed: %08x\n", hres); - CHECK_CALLED(QueryInterface_IBindStatusCallbackEx); - CHECK_CALLED(GetBindInfoEx); - - bindf = bindf2 = dw = 0; - SET_EXPECT(QueryInterface_IBindStatusCallbackEx); - SET_EXPECT(GetBindInfoEx); - hres = IBindStatusCallbackEx_GetBindInfoEx(bscex, &bindf, &bindinfo, &bindf2, &dw); - ok(hres == S_OK, "GetBindInfo failed: %08x\n", hres); - CHECK_CALLED(QueryInterface_IBindStatusCallbackEx); - CHECK_CALLED(GetBindInfoEx); - - use_bscex = FALSE; - - bindf = bindf2 = dw = 0xdeadbeef; - SET_EXPECT(QueryInterface_IBindStatusCallbackEx); - SET_EXPECT(GetBindInfo); - hres = IBindStatusCallbackEx_GetBindInfoEx(bscex, &bindf, &bindinfo, &bindf2, &dw); - ok(hres == S_OK, "GetBindInfo failed: %08x\n", hres); - CHECK_CALLED(QueryInterface_IBindStatusCallbackEx); - CHECK_CALLED(GetBindInfo); - ok(bindf2 == 0xdeadbeef, "bindf2 = %x\n", bindf2); - ok(dw == 0xdeadbeef, "dw = %x\n", dw); - - IBindStatusCallbackEx_Release(bscex); -} - static BOOL test_bscholder(IBindStatusCallback *holder) { IServiceProvider *serv_prov; @@ -1995,15 +1918,11 @@ static BOOL test_bscholder(IBindStatusCallback *holder) ok(hres == S_OK, "Could not get IServiceProvider interface: %08x\n", hres); dw = 0xdeadbeef; - SET_EXPECT(QueryInterface_IBindStatusCallbackEx); SET_EXPECT(GetBindInfo); hres = IBindStatusCallback_GetBindInfo(holder, &dw, &bindinfo); ok(hres == S_OK, "GetBindInfo failed: %08x\n", hres); - CLEAR_CALLED(QueryInterface_IBindStatusCallbackEx); /* IE 8 */ CHECK_CALLED(GetBindInfo); - test_GetBindInfoEx(holder); - SET_EXPECT(OnStartBinding); hres = IBindStatusCallback_OnStartBinding(holder, 0, (void*)0xdeadbeef); ok(hres == S_OK, "OnStartBinding failed: %08x\n", hres); @@ -2012,19 +1931,22 @@ static BOOL test_bscholder(IBindStatusCallback *holder) hres = IBindStatusCallback_QueryInterface(holder, &IID_IHttpNegotiate, (void**)&http_negotiate); ok(hres == S_OK, "Could not get IHttpNegotiate interface: %08x\n", hres); + wstr = (void*)0xdeadbeef; + hres = IHttpNegotiate_BeginningTransaction(http_negotiate, urls[test_protocol], (void*)0xdeadbeef, 0xff, &wstr); + ok(hres == S_OK, "BeginningTransaction failed: %08x\n", hres); + ok(wstr == NULL, "wstr = %p\n", wstr); + SET_EXPECT(QueryInterface_IHttpNegotiate); hres = IServiceProvider_QueryService(serv_prov, &IID_IHttpNegotiate, &IID_IHttpNegotiate, (void**)&http_negotiate_serv); ok(hres == S_OK, "Could not get IHttpNegotiate service: %08x\n", hres); - CLEAR_CALLED(QueryInterface_IHttpNegotiate); /* IE <8 */ + CHECK_CALLED(QueryInterface_IHttpNegotiate); ok(http_negotiate == http_negotiate_serv, "http_negotiate != http_negotiate_serv\n"); wstr = (void*)0xdeadbeef; - SET_EXPECT(QueryInterface_IHttpNegotiate); SET_EXPECT(BeginningTransaction); hres = IHttpNegotiate_BeginningTransaction(http_negotiate_serv, urls[test_protocol], emptyW, 0, &wstr); - CHECK_CALLED_BROKEN(QueryInterface_IHttpNegotiate); /* IE8 */ CHECK_CALLED(BeginningTransaction); ok(hres == S_OK, "BeginningTransaction failed: %08x\n", hres); ok(wstr == NULL, "wstr = %p\n", wstr); @@ -2040,19 +1962,19 @@ static BOOL test_bscholder(IBindStatusCallback *holder) hres = IBindStatusCallback_QueryInterface(holder, &IID_IHttpNegotiate2, (void**)&http_negotiate2); if(SUCCEEDED(hres)) { have_IHttpNegotiate2 = TRUE; + hres = IHttpNegotiate2_GetRootSecurityId(http_negotiate2, (void*)0xdeadbeef, (void*)0xdeadbeef, 0); + ok(hres == E_FAIL || hres == E_NOTIMPL, "GetRootSecurityId failed: %08x\n", hres); SET_EXPECT(QueryInterface_IHttpNegotiate2); hres = IServiceProvider_QueryService(serv_prov, &IID_IHttpNegotiate2, &IID_IHttpNegotiate2, (void**)&http_negotiate2_serv); ok(hres == S_OK, "Could not get IHttpNegotiate2 service: %08x\n", hres); - CLEAR_CALLED(QueryInterface_IHttpNegotiate2); /* IE <8 */ + CHECK_CALLED(QueryInterface_IHttpNegotiate2); ok(http_negotiate2 == http_negotiate2_serv, "http_negotiate != http_negotiate_serv\n"); - SET_EXPECT(QueryInterface_IHttpNegotiate2); SET_EXPECT(GetRootSecurityId); hres = IHttpNegotiate2_GetRootSecurityId(http_negotiate2, (void*)0xdeadbeef, (void*)0xdeadbeef, 0); ok(hres == E_NOTIMPL, "GetRootSecurityId failed: %08x\n", hres); - CHECK_CALLED_BROKEN(QueryInterface_IHttpNegotiate2); /* IE8 */ CHECK_CALLED(GetRootSecurityId); IHttpNegotiate_Release(http_negotiate2_serv); @@ -2067,12 +1989,10 @@ static BOOL test_bscholder(IBindStatusCallback *holder) ok(hres == S_OK, "OnProgress failed: %08x\n", hres); CHECK_CALLED(OnProgress_FINDINGRESOURCE); - SET_EXPECT(QueryInterface_IHttpNegotiate); SET_EXPECT(OnResponse); wstr = (void*)0xdeadbeef; hres = IHttpNegotiate_OnResponse(http_negotiate, 200, emptyW, NULL, NULL); ok(hres == S_OK, "OnResponse failed: %08x\n", hres); - CHECK_CALLED_BROKEN(QueryInterface_IHttpNegotiate); /* IE8 */ CHECK_CALLED(OnResponse); IHttpNegotiate_Release(http_negotiate); @@ -2085,8 +2005,8 @@ static BOOL test_bscholder(IBindStatusCallback *holder) hres = IServiceProvider_QueryService(serv_prov, &IID_IAuthenticate, &IID_IAuthenticate, (void**)&authenticate_serv); ok(hres == S_OK, "Could not get IAuthenticate service: %08x\n", hres); - CLEAR_CALLED(QueryInterface_IAuthenticate); /* IE <8 */ - CLEAR_CALLED(QueryService_IAuthenticate); /* IE <8 */ + CHECK_CALLED(QueryInterface_IAuthenticate); + CHECK_CALLED(QueryService_IAuthenticate); ok(authenticate == authenticate_serv, "authenticate != authenticate_serv\n"); IAuthenticate_Release(authenticate_serv); @@ -2134,9 +2054,9 @@ static BOOL test_RegisterBindStatusCallback(void) SET_EXPECT(QueryInterface_IBindStatusCallback); SET_EXPECT(QueryInterface_IBindStatusCallbackHolder); prevbsc = (void*)0xdeadbeef; - hres = RegisterBindStatusCallback(bindctx, (IBindStatusCallback*)&bsc, &prevbsc, 0); + hres = RegisterBindStatusCallback(bindctx, &bsc, &prevbsc, 0); ok(hres == S_OK, "RegisterBindStatusCallback failed: %08x\n", hres); - ok(prevbsc == (IBindStatusCallback*)&bsc, "prevbsc=%p\n", prevbsc); + ok(prevbsc == &bsc, "prevbsc=%p\n", prevbsc); CHECK_CALLED(QueryInterface_IBindStatusCallback); CHECK_CALLED(QueryInterface_IBindStatusCallbackHolder); @@ -2148,14 +2068,14 @@ static BOOL test_RegisterBindStatusCallback(void) hres = IUnknown_QueryInterface(unk, &IID_IBindStatusCallback, (void**)&clb); IUnknown_Release(unk); ok(hres == S_OK, "QueryInterface(IID_IBindStatusCallback) failed: %08x\n", hres); - ok(clb != (IBindStatusCallback*)&bsc, "bsc == clb\n"); + ok(clb != &bsc, "bsc == clb\n"); if(!test_bscholder(clb)) ret = FALSE; IBindStatusCallback_Release(clb); - hres = RevokeBindStatusCallback(bindctx, (IBindStatusCallback*)&bsc); + hres = RevokeBindStatusCallback(bindctx, &bsc); ok(hres == S_OK, "RevokeBindStatusCallback failed: %08x\n", hres); unk = (void*)0xdeadbeef; @@ -2212,16 +2132,16 @@ static void test_BindToStorage(int protocol, BOOL emul, DWORD t) init_bind_test(protocol, emul ? BINDTEST_EMULATE : 0, t); SET_EXPECT(QueryInterface_IServiceProvider); - hres = CreateAsyncBindCtx(0, (IBindStatusCallback*)&bsc, NULL, &bctx); + hres = CreateAsyncBindCtx(0, &bsc, NULL, &bctx); ok(hres == S_OK, "CreateAsyncBindCtx failed: %08x\n\n", hres); CHECK_CALLED(QueryInterface_IServiceProvider); if(FAILED(hres)) return; SET_EXPECT(QueryInterface_IServiceProvider); - hres = RegisterBindStatusCallback(bctx, (IBindStatusCallback*)&bsc, &previousclb, 0); + hres = RegisterBindStatusCallback(bctx, &bsc, &previousclb, 0); ok(hres == S_OK, "RegisterBindStatusCallback failed: %08x\n", hres); - ok(previousclb == (IBindStatusCallback*)&bsc, "previousclb(%p) != sclb(%p)\n", previousclb, &bsc); + ok(previousclb == &bsc, "previousclb(%p) != sclb(%p)\n", previousclb, &bsc); CHECK_CALLED(QueryInterface_IServiceProvider); if(previousclb) IBindStatusCallback_Release(previousclb); @@ -2247,7 +2167,6 @@ static void test_BindToStorage(int protocol, BOOL emul, DWORD t) if(tymed == TYMED_FILE && (test_protocol == ABOUT_TEST || test_protocol == ITS_TEST)) binding_hres = INET_E_DATA_NOT_AVAILABLE; - SET_EXPECT(QueryInterface_IBindStatusCallbackEx); SET_EXPECT(GetBindInfo); SET_EXPECT(QueryInterface_IInternetProtocol); if(!emulate_protocol) @@ -2275,10 +2194,8 @@ static void test_BindToStorage(int protocol, BOOL emul, DWORD t) if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST || test_protocol == FTP_TEST || test_protocol == FILE_TEST) SET_EXPECT(OnProgress_SENDINGREQUEST); - if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) { - SET_EXPECT(QueryInterface_IHttpNegotiate); + if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) SET_EXPECT(OnResponse); - } SET_EXPECT(OnProgress_MIMETYPEAVAILABLE); SET_EXPECT(OnProgress_BEGINDOWNLOADDATA); if(test_protocol == FILE_TEST) @@ -2323,7 +2240,6 @@ static void test_BindToStorage(int protocol, BOOL emul, DWORD t) DispatchMessage(&msg); } - CLEAR_CALLED(QueryInterface_IBindStatusCallbackEx); /* IE 8 */ CHECK_CALLED(GetBindInfo); CHECK_CALLED(QueryInterface_IInternetProtocol); if(!emulate_protocol) @@ -2364,10 +2280,8 @@ static void test_BindToStorage(int protocol, BOOL emul, DWORD t) CHECK_CALLED(OnProgress_SENDINGREQUEST); else if(test_protocol == FTP_TEST) todo_wine CHECK_CALLED(OnProgress_SENDINGREQUEST); - if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) { - CLEAR_CALLED(QueryInterface_IHttpNegotiate); + if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) CHECK_CALLED(OnResponse); - } CHECK_CALLED(OnProgress_MIMETYPEAVAILABLE); CHECK_CALLED(OnProgress_BEGINDOWNLOADDATA); if(test_protocol == FILE_TEST) @@ -2405,7 +2319,7 @@ static void test_BindToObject(int protocol, BOOL emul) CLSCTX_INPROC_SERVER, REGCLS_MULTIPLEUSE, ®id); SET_EXPECT(QueryInterface_IServiceProvider); - hres = CreateAsyncBindCtx(0, (IBindStatusCallback*)&objbsc, NULL, &bctx); + hres = CreateAsyncBindCtx(0, &objbsc, NULL, &bctx); ok(SUCCEEDED(hres), "CreateAsyncBindCtx failed: %08x\n\n", hres); CHECK_CALLED(QueryInterface_IServiceProvider); if(FAILED(hres)) @@ -2427,7 +2341,6 @@ static void test_BindToObject(int protocol, BOOL emul) ok(hres == S_OK, "GetDisplayName failed %08x\n", hres); ok(!lstrcmpW(display_name, urls[test_protocol]), "GetDisplayName got wrong name\n"); - SET_EXPECT(QueryInterface_IBindStatusCallbackEx); SET_EXPECT(Obj_GetBindInfo); SET_EXPECT(QueryInterface_IInternetProtocol); if(!emulate_protocol) @@ -2453,10 +2366,8 @@ static void test_BindToObject(int protocol, BOOL emul) } if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST || test_protocol == FILE_TEST) SET_EXPECT(Obj_OnProgress_SENDINGREQUEST); - if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) { - SET_EXPECT(QueryInterface_IHttpNegotiate); + if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) SET_EXPECT(OnResponse); - } SET_EXPECT(Obj_OnProgress_MIMETYPEAVAILABLE); SET_EXPECT(Obj_OnProgress_BEGINDOWNLOADDATA); if(test_protocol == FILE_TEST) @@ -2501,7 +2412,6 @@ static void test_BindToObject(int protocol, BOOL emul) DispatchMessage(&msg); } - CLEAR_CALLED(QueryInterface_IBindStatusCallbackEx); CHECK_CALLED(Obj_GetBindInfo); CHECK_CALLED(QueryInterface_IInternetProtocol); if(!emulate_protocol) @@ -2540,10 +2450,8 @@ static void test_BindToObject(int protocol, BOOL emul) else CHECK_CALLED(Obj_OnProgress_SENDINGREQUEST); } - if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) { - CLEAR_CALLED(QueryInterface_IHttpNegotiate); + if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) CHECK_CALLED(OnResponse); - } CHECK_CALLED(Obj_OnProgress_MIMETYPEAVAILABLE); CHECK_CALLED(Obj_OnProgress_BEGINDOWNLOADDATA); if(test_protocol == FILE_TEST) @@ -2605,10 +2513,8 @@ static void test_URLDownloadToFile(DWORD prot, BOOL emul) } if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST || test_protocol == FILE_TEST) SET_EXPECT(OnProgress_SENDINGREQUEST); - if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) { - SET_EXPECT(QueryInterface_IHttpNegotiate); + if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) SET_EXPECT(OnResponse); - } SET_EXPECT(OnProgress_MIMETYPEAVAILABLE); SET_EXPECT(OnProgress_BEGINDOWNLOADDATA); if(test_protocol == FILE_TEST) @@ -2619,8 +2525,7 @@ static void test_URLDownloadToFile(DWORD prot, BOOL emul) SET_EXPECT(OnStopBinding); } - hres = URLDownloadToFileW(NULL, test_protocol == FILE_TEST ? file_url : urls[test_protocol], - dwl_htmlW, 0, (IBindStatusCallback*)&bsc); + hres = URLDownloadToFileW(NULL, test_protocol == FILE_TEST ? file_url : urls[test_protocol], dwl_htmlW, 0, &bsc); ok(hres == S_OK, "URLDownloadToFile failed: %08x\n", hres); CHECK_CALLED(GetBindInfo); @@ -2649,10 +2554,8 @@ static void test_URLDownloadToFile(DWORD prot, BOOL emul) CHECK_CALLED(OnProgress_SENDINGREQUEST); else if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) CLEAR_CALLED(OnProgress_SENDINGREQUEST); /* not called by IE7 */ - if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) { - CLEAR_CALLED(QueryInterface_IHttpNegotiate); + if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) CHECK_CALLED(OnResponse); - } CHECK_CALLED(OnProgress_MIMETYPEAVAILABLE); CHECK_CALLED(OnProgress_BEGINDOWNLOADDATA); if(test_protocol == FILE_TEST) @@ -2727,11 +2630,10 @@ static void test_ReportResult(HRESULT exhres) ok(hres == S_OK, "CreateURLMoniker failed: %08x\n", hres); SET_EXPECT(QueryInterface_IServiceProvider); - hres = CreateAsyncBindCtx(0, (IBindStatusCallback*)&bsc, NULL, &bctx); + hres = CreateAsyncBindCtx(0, &bsc, NULL, &bctx); ok(hres == S_OK, "CreateAsyncBindCtx failed: %08x\n\n", hres); CHECK_CALLED(QueryInterface_IServiceProvider); - SET_EXPECT(QueryInterface_IBindStatusCallbackEx); SET_EXPECT(GetBindInfo); SET_EXPECT(QueryInterface_IInternetProtocol); SET_EXPECT(OnStartBinding); @@ -2746,7 +2648,6 @@ static void test_ReportResult(HRESULT exhres) ok(hres == exhres || hres == MK_S_ASYNCHRONOUS, "BindToStorage failed: %08x, expected %08x or MK_S_ASYNCHRONOUS\n", hres, exhres); - CLEAR_CALLED(QueryInterface_IBindStatusCallbackEx); /* IE 8 */ CHECK_CALLED(GetBindInfo); CHECK_CALLED(QueryInterface_IInternetProtocol); CHECK_CALLED(OnStartBinding); @@ -2850,16 +2751,10 @@ START_TEST(url) create_file(); test_create(); - - trace("test CreateAsyncBindCtx...\n"); test_CreateAsyncBindCtx(); - - trace("test CreateAsyncBindCtxEx...\n"); test_CreateAsyncBindCtxEx(); - trace("test RegisterBindStatusCallback...\n"); if(test_RegisterBindStatusCallback()) { - trace("test BindToStorage failures...\n"); test_BindToStorage_fail(); trace("synchronous http test (COM not initialised)...\n"); diff --git a/dlls/urlmon/urlmon.inf b/dlls/urlmon/urlmon.inf index 4d781c73bd0..63d88c4a613 100644 --- a/dlls/urlmon/urlmon.inf +++ b/dlls/urlmon/urlmon.inf @@ -3,11 +3,11 @@ Signature="$CHICAGO$" [RegisterDll] -AddReg=Classes.Reg, Protocols.Reg, ZoneMap.Reg, Zones.Reg, Misc.Reg +AddReg=Classes.Reg, Protocols.Reg, ZoneMap.Reg, Zones.Reg [UnregisterDll] -DelReg=Classes.Reg, Protocols.Reg, ZoneMap.Reg, Zones.Reg, Misc.Reg +DelReg=Classes.Reg, Protocols.Reg, ZoneMap.Reg, Zones.Reg [Classes.Reg] @@ -460,16 +460,9 @@ HKCU,"%ZONES_UNTRUSTED%","1E05",0x10003,0x10000 HKLM,"%ZONES_UNTRUSTED%","1E05",0x10003,0x10000 -[Misc.Reg] -HKCU,"%INTERNET_SETTINGS%","User Agent",,"%USER_AGENT%" - - [Strings] MODULE="urlmon.dll" -USER_AGENT="Mozilla/4.0 (compatible; MSIE 8.0; Win32)" -INTERNET_SETTINGS="Software\Microsoft\Windows\CurrentVersion\Internet Settings" - PATH_ZONEMAP="Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap" PATH_ZONEMAP_PROTOCOLS="Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\ProtocolDefaults" PATH_ZONEMAP_DOMAINS="Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains" diff --git a/dlls/urlmon/urlmon_main.c b/dlls/urlmon/urlmon_main.c index 2e624fb97c2..6e51db56b98 100644 --- a/dlls/urlmon/urlmon_main.c +++ b/dlls/urlmon/urlmon_main.c @@ -139,7 +139,6 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID fImpLoad) FreeLibrary(hCabinet); hCabinet = NULL; init_session(FALSE); - free_session(); free_tls_list(); URLMON_hInstance = 0; break; @@ -363,6 +362,42 @@ HRESULT WINAPI DllRegisterServerEx(void) } /************************************************************************** + * UrlMkSetSessionOption (URLMON.@) + */ +HRESULT WINAPI UrlMkSetSessionOption(DWORD dwOption, LPVOID pBuffer, DWORD dwBufferLength, + DWORD Reserved) +{ + FIXME("(%#x, %p, %#x): stub\n", dwOption, pBuffer, dwBufferLength); + + return S_OK; +} + +static const CHAR Agent[] = "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)"; + +/************************************************************************** + * ObtainUserAgentString (URLMON.@) + */ +HRESULT WINAPI ObtainUserAgentString(DWORD dwOption, LPSTR pcszUAOut, DWORD *cbSize) +{ + FIXME("(%d, %p, %p): stub\n", dwOption, pcszUAOut, cbSize); + + if (pcszUAOut == NULL || cbSize == NULL) + return E_INVALIDARG; + + if (*cbSize < sizeof(Agent)) + { + *cbSize = sizeof(Agent); + return E_OUTOFMEMORY; + } + + if (sizeof(Agent) < *cbSize) + *cbSize = sizeof(Agent); + lstrcpynA(pcszUAOut, Agent, *cbSize); + + return S_OK; +} + +/************************************************************************** * IsValidURL (URLMON.@) * * Determines if a specified string is a valid URL. diff --git a/dlls/urlmon/urlmon_main.h b/dlls/urlmon/urlmon_main.h index 62a7e9137c9..e5501e01adc 100644 --- a/dlls/urlmon/urlmon_main.h +++ b/dlls/urlmon/urlmon_main.h @@ -63,7 +63,6 @@ HRESULT get_protocol_handler(LPCWSTR,CLSID*,BOOL*,IClassFactory**); IInternetProtocol *get_mime_filter(LPCWSTR); BOOL is_registered_protocol(LPCWSTR); void register_urlmon_namespace(IClassFactory*,REFIID,LPCWSTR,BOOL); -void free_session(void); HRESULT bind_to_storage(LPCWSTR url, IBindCtx *pbc, REFIID riid, void **ppv); HRESULT bind_to_object(IMoniker *mon, LPCWSTR url, IBindCtx *pbc, REFIID riid, void **ppv); @@ -151,11 +150,6 @@ static inline void *heap_realloc(void *mem, size_t len) return HeapReAlloc(GetProcessHeap(), 0, mem, len); } -static inline void *heap_realloc_zero(void *mem, size_t len) -{ - return HeapReAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, mem, len); -} - static inline BOOL heap_free(void *mem) { return HeapFree(GetProcessHeap(), 0, mem); diff --git a/dlls/urlmon/version.rc b/dlls/urlmon/version.rc new file mode 100644 index 00000000000..10cc7216ccd --- /dev/null +++ b/dlls/urlmon/version.rc @@ -0,0 +1,27 @@ +/* + * Copyright 2005 + * + * Stefan Leichter + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#define WINE_FILENAME_STR "urlmon.dll" +#define WINE_FILEVERSION 6,0,2800,1485 +#define WINE_FILEVERSION_STR "6.0.2800.1485" +#define WINE_PRODUCTVERSION 6,0,2800,1485 +#define WINE_PRODUCTVERSION_STR "6.0.2800.1485" + +#include "wine/wine_common_ver.rc" diff --git a/dlls/user32/Makefile.in b/dlls/user32/Makefile.in index c6947f1691b..21418226342 100644 --- a/dlls/user32/Makefile.in +++ b/dlls/user32/Makefile.in @@ -68,37 +68,7 @@ C_SRCS16 = \ user16.c \ wnd16.c -RC_SRCS = \ - resources/user32_Bg.rc \ - resources/user32_Ca.rc \ - resources/user32_Cs.rc \ - resources/user32_Da.rc \ - resources/user32_De.rc \ - resources/user32_En.rc \ - resources/user32_Eo.rc \ - resources/user32_Es.rc \ - resources/user32_Fi.rc \ - resources/user32_Fr.rc \ - resources/user32_Hu.rc \ - resources/user32_It.rc \ - resources/user32_Ja.rc \ - resources/user32_Ko.rc \ - resources/user32_Lt.rc \ - resources/user32_Nl.rc \ - resources/user32_No.rc \ - resources/user32_Pl.rc \ - resources/user32_Pt.rc \ - resources/user32_Ro.rc \ - resources/user32_Ru.rc \ - resources/user32_Si.rc \ - resources/user32_Sk.rc \ - resources/user32_Sv.rc \ - resources/user32_Tr.rc \ - resources/user32_Uk.rc \ - resources/user32_Wa.rc \ - resources/user32_Zh.rc \ - resources/user32_bin.rc \ - resources/version.rc +RC_SRCS = resources/user32.rc SVG_SRCS = resources/oic_winlogo.svg diff --git a/dlls/user32/button.c b/dlls/user32/button.c index 1681949172f..926563c98f2 100644 --- a/dlls/user32/button.c +++ b/dlls/user32/button.c @@ -75,7 +75,6 @@ #include "wingdi.h" #include "wine/winuser16.h" #include "controls.h" -#include "win.h" #include "user_private.h" #include "wine/debug.h" @@ -272,13 +271,6 @@ static LRESULT ButtonWndProc_common(HWND hWnd, UINT uMsg, } if (btn_type >= MAX_BTN_TYPE) return -1; /* abort */ - - /* XP turns a BS_USERBUTTON into BS_PUSHBUTTON */ - if (btn_type == BS_USERBUTTON ) - { - style = (style & ~0x0f) | BS_PUSHBUTTON; - WIN_SetStyle( hWnd, style, 0x0f & ~style ); - } set_button_state( hWnd, BUTTON_UNCHECKED ); return 0; @@ -466,11 +458,11 @@ static LRESULT ButtonWndProc_common(HWND hWnd, UINT uMsg, if ((wParam & 0x0f) >= MAX_BTN_TYPE) break; btn_type = wParam & 0x0f; style = (style & ~0x0f) | btn_type; - WIN_SetStyle( hWnd, style, 0x0f & ~style ); + SetWindowLongW( hWnd, GWL_STYLE, style ); /* Only redraw if lParam flag is set.*/ if (lParam) - InvalidateRect( hWnd, NULL, TRUE ); + paint_button( hWnd, btn_type, ODA_DRAWENTIRE ); break; @@ -826,9 +818,6 @@ static void PB_Paint( HWND hwnd, HDC hDC, UINT action ) hOldBrush = SelectObject(hDC,GetSysColorBrush(COLOR_BTNFACE)); oldBkMode = SetBkMode(hDC, TRANSPARENT); - /* completely skip the drawing if only focus has changed */ - if (action == ODA_FOCUS) goto draw_focus; - if (get_button_type(style) == BS_DEFPUSHBUTTON) { Rectangle(hDC, rc.left, rc.top, rc.right, rc.bottom); @@ -872,9 +861,7 @@ static void PB_Paint( HWND hwnd, HDC hDC, UINT action ) SetTextColor( hDC, oldTxtColor ); -draw_focus: - if ((action == ODA_FOCUS) || - ((action == ODA_DRAWENTIRE) && (state & BUTTON_HASFOCUS))) + if (state & BUTTON_HASFOCUS) { InflateRect( &focus_rect, -1, -1 ); IntersectRect(&focus_rect, &focus_rect, &rc); @@ -1118,8 +1105,6 @@ static void UB_Paint( HWND hwnd, HDC hDC, UINT action ) if ((action == ODA_FOCUS) || ((action == ODA_DRAWENTIRE) && (state & BUTTON_HASFOCUS))) DrawFocusRect( hDC, &rc ); - - BUTTON_NOTIFY_PARENT( hwnd, BN_PAINT ); } diff --git a/dlls/user32/cursoricon.c b/dlls/user32/cursoricon.c index 48a1a59ff7e..707d2bb8b1a 100644 --- a/dlls/user32/cursoricon.c +++ b/dlls/user32/cursoricon.c @@ -1598,73 +1598,6 @@ BOOL WINAPI DestroyCursor( HCURSOR hCursor ) return DestroyIcon32(HCURSOR_16(hCursor), CID_WIN32); } -/*********************************************************************** - * bitmap_has_alpha_channel - * - * Analyses bits bitmap to determine if alpha data is present. - * - * PARAMS - * bpp [I] The bits-per-pixel of the bitmap - * bitmapBits [I] A pointer to the bitmap data - * bitmapLength [I] The length of the bitmap in bytes - * - * RETURNS - * TRUE if an alpha channel is discovered, FALSE - * - * NOTE - * Windows' behaviour is that if the icon bitmap is 32-bit and at - * least one pixel has a non-zero alpha, then the bitmap is a - * treated as having an alpha channel transparentcy. Otherwise, - * it's treated as being completely opaque. - * - */ -static BOOL bitmap_has_alpha_channel( int bpp, unsigned char *bitmapBits, - unsigned int bitmapLength ) -{ - /* Detect an alpha channel by looking for non-zero alpha pixels */ - if(bpp == 32) - { - unsigned int offset; - for(offset = 3; offset < bitmapLength; offset += 4) - { - if(bitmapBits[offset] != 0) - { - return TRUE; - } - } - } - return FALSE; -} - -/*********************************************************************** - * premultiply_alpha_channel - * - * Premultiplies the color channels of a 32-bit bitmap by the alpha - * channel. This is a necessary step that must be carried out on - * the image before it is passed to GdiAlphaBlend - * - * PARAMS - * destBitmap [I] The destination bitmap buffer - * srcBitmap [I] The source bitmap buffer - * bitmapLength [I] The length of the bitmap in bytes - * - */ -static void premultiply_alpha_channel( unsigned char *destBitmap, - unsigned char *srcBitmap, - unsigned int bitmapLength ) -{ - unsigned char *destPixel = destBitmap; - unsigned char *srcPixel = srcBitmap; - - while(destPixel < destBitmap + bitmapLength) - { - unsigned char alpha = srcPixel[3]; - *(destPixel++) = *(srcPixel++) * alpha / 255; - *(destPixel++) = *(srcPixel++) * alpha / 255; - *(destPixel++) = *(srcPixel++) * alpha / 255; - *(destPixel++) = *(srcPixel++); - } -} /*********************************************************************** * DrawIcon (USER32.@) @@ -1673,69 +1606,28 @@ BOOL WINAPI DrawIcon( HDC hdc, INT x, INT y, HICON hIcon ) { CURSORICONINFO *ptr; HDC hMemDC; - HBITMAP hXorBits = NULL, hAndBits = NULL, hBitTemp = NULL; + HBITMAP hXorBits, hAndBits; COLORREF oldFg, oldBg; - unsigned char *xorBitmapBits; - unsigned int dibLength; TRACE("%p, (%d,%d), %p\n", hdc, x, y, hIcon); if (!(ptr = GlobalLock16(HICON_16(hIcon)))) return FALSE; if (!(hMemDC = CreateCompatibleDC( hdc ))) return FALSE; - - dibLength = ptr->nHeight * get_bitmap_width_bytes( - ptr->nWidth, ptr->bBitsPerPixel); - - xorBitmapBits = (unsigned char *)(ptr + 1) + ptr->nHeight * - get_bitmap_width_bytes(ptr->nWidth, 1); - + hAndBits = CreateBitmap( ptr->nWidth, ptr->nHeight, 1, 1, ptr + 1 ); + hXorBits = CreateBitmap( ptr->nWidth, ptr->nHeight, ptr->bPlanes, + ptr->bBitsPerPixel, (char *)(ptr + 1) + + ptr->nHeight * get_bitmap_width_bytes(ptr->nWidth,1) ); oldFg = SetTextColor( hdc, RGB(0,0,0) ); oldBg = SetBkColor( hdc, RGB(255,255,255) ); - if(bitmap_has_alpha_channel(ptr->bBitsPerPixel, xorBitmapBits, dibLength)) + if (hXorBits && hAndBits) { - BITMAPINFOHEADER bmih; - unsigned char *dibBits; - - memset(&bmih, 0, sizeof(BITMAPINFOHEADER)); - bmih.biSize = sizeof(BITMAPINFOHEADER); - bmih.biWidth = ptr->nWidth; - bmih.biHeight = -ptr->nHeight; - bmih.biPlanes = ptr->bPlanes; - bmih.biBitCount = 32; - bmih.biCompression = BI_RGB; - - hXorBits = CreateDIBSection(hdc, (BITMAPINFO*)&bmih, DIB_RGB_COLORS, - (void*)&dibBits, NULL, 0); - - if (hXorBits && dibBits) - { - BLENDFUNCTION pixelblend = { AC_SRC_OVER, 0, 255, AC_SRC_ALPHA }; - - /* Do the alpha blending render */ - premultiply_alpha_channel(dibBits, xorBitmapBits, dibLength); - hBitTemp = SelectObject( hMemDC, hXorBits ); - GdiAlphaBlend(hdc, x, y, ptr->nWidth, ptr->nHeight, hMemDC, - 0, 0, ptr->nWidth, ptr->nHeight, pixelblend); - SelectObject( hMemDC, hBitTemp ); - } + HBITMAP hBitTemp = SelectObject( hMemDC, hAndBits ); + BitBlt( hdc, x, y, ptr->nWidth, ptr->nHeight, hMemDC, 0, 0, SRCAND ); + SelectObject( hMemDC, hXorBits ); + BitBlt(hdc, x, y, ptr->nWidth, ptr->nHeight, hMemDC, 0, 0,SRCINVERT); + SelectObject( hMemDC, hBitTemp ); } - else - { - hAndBits = CreateBitmap( ptr->nWidth, ptr->nHeight, 1, 1, ptr + 1 ); - hXorBits = CreateBitmap( ptr->nWidth, ptr->nHeight, ptr->bPlanes, - ptr->bBitsPerPixel, xorBitmapBits); - - if (hXorBits && hAndBits) - { - hBitTemp = SelectObject( hMemDC, hAndBits ); - BitBlt( hdc, x, y, ptr->nWidth, ptr->nHeight, hMemDC, 0, 0, SRCAND ); - SelectObject( hMemDC, hXorBits ); - BitBlt(hdc, x, y, ptr->nWidth, ptr->nHeight, hMemDC, 0, 0,SRCINVERT); - SelectObject( hMemDC, hBitTemp ); - } - } - DeleteDC( hMemDC ); if (hXorBits) DeleteObject( hXorBits ); if (hAndBits) DeleteObject( hAndBits ); @@ -2272,33 +2164,25 @@ BOOL WINAPI DrawIconEx( HDC hdc, INT x0, INT y0, HICON hIcon, INT cxWidth, INT cyWidth, UINT istep, HBRUSH hbr, UINT flags ) { - CURSORICONINFO *ptr; + CURSORICONINFO *ptr = GlobalLock16(HICON_16(hIcon)); HDC hDC_off = 0, hMemDC; BOOL result = FALSE, DoOffscreen; HBITMAP hB_off = 0, hOld = 0; - unsigned char *xorBitmapBits; - unsigned int xorLength; - BOOL has_alpha = FALSE; + if (!ptr) return FALSE; TRACE_(icon)("(hdc=%p,pos=%d.%d,hicon=%p,extend=%d.%d,istep=%d,br=%p,flags=0x%08x)\n", hdc,x0,y0,hIcon,cxWidth,cyWidth,istep,hbr,flags ); - if (!(ptr = GlobalLock16(HICON_16(hIcon)))) return FALSE; - if (!(hMemDC = CreateCompatibleDC( hdc ))) return FALSE; - + hMemDC = CreateCompatibleDC (hdc); if (istep) FIXME_(icon)("Ignoring istep=%d\n", istep); if (flags & DI_NOMIRROR) FIXME_(icon)("Ignoring flag DI_NOMIRROR\n"); - xorLength = ptr->nHeight * get_bitmap_width_bytes( - ptr->nWidth, ptr->bBitsPerPixel); - xorBitmapBits = (unsigned char *)(ptr + 1) + ptr->nHeight * - get_bitmap_width_bytes(ptr->nWidth, 1); - - if (flags & DI_IMAGE) - has_alpha = bitmap_has_alpha_channel( - ptr->bBitsPerPixel, xorBitmapBits, xorLength); + if (!flags) { + FIXME_(icon)("no flags set? setting to DI_NORMAL\n"); + flags = DI_NORMAL; + } /* Calculate the size of the destination image. */ if (cxWidth == 0) @@ -2336,90 +2220,50 @@ BOOL WINAPI DrawIconEx( HDC hdc, INT x0, INT y0, HICON hIcon, if (hMemDC && (!DoOffscreen || (hDC_off && hB_off))) { - HBITMAP hBitTemp; - HBITMAP hXorBits = NULL, hAndBits = NULL; + HBITMAP hXorBits, hAndBits; COLORREF oldFg, oldBg; INT nStretchMode; nStretchMode = SetStretchBltMode (hdc, STRETCH_DELETESCANS); + hXorBits = CreateBitmap ( ptr->nWidth, ptr->nHeight, + ptr->bPlanes, ptr->bBitsPerPixel, + (char *)(ptr + 1) + + ptr->nHeight * + get_bitmap_width_bytes(ptr->nWidth,1) ); + hAndBits = CreateBitmap ( ptr->nWidth, ptr->nHeight, 1, 1, ptr + 1 ); oldFg = SetTextColor( hdc, RGB(0,0,0) ); oldBg = SetBkColor( hdc, RGB(255,255,255) ); - if (((flags & DI_MASK) && !(flags & DI_IMAGE)) || - ((flags & DI_MASK) && !has_alpha)) + if (hXorBits && hAndBits) { - hAndBits = CreateBitmap ( ptr->nWidth, ptr->nHeight, 1, 1, ptr + 1 ); - if (hAndBits) + HBITMAP hBitTemp = SelectObject( hMemDC, hAndBits ); + if (flags & DI_MASK) { - hBitTemp = SelectObject( hMemDC, hAndBits ); if (DoOffscreen) StretchBlt (hDC_off, 0, 0, cxWidth, cyWidth, hMemDC, 0, 0, ptr->nWidth, ptr->nHeight, SRCAND); else StretchBlt (hdc, x0, y0, cxWidth, cyWidth, hMemDC, 0, 0, ptr->nWidth, ptr->nHeight, SRCAND); - SelectObject( hMemDC, hBitTemp ); } - } - - if (flags & DI_IMAGE) - { - BITMAPINFOHEADER bmih; - unsigned char *dibBits; - - memset(&bmih, 0, sizeof(BITMAPINFOHEADER)); - bmih.biSize = sizeof(BITMAPINFOHEADER); - bmih.biWidth = ptr->nWidth; - bmih.biHeight = -ptr->nHeight; - bmih.biPlanes = ptr->bPlanes; - bmih.biBitCount = ptr->bBitsPerPixel; - bmih.biCompression = BI_RGB; - - hXorBits = CreateDIBSection(hdc, (BITMAPINFO*)&bmih, DIB_RGB_COLORS, - (void*)&dibBits, NULL, 0); - - if (hXorBits && dibBits) + SelectObject( hMemDC, hXorBits ); + if (flags & DI_IMAGE) { - if(has_alpha) - { - BLENDFUNCTION pixelblend = { AC_SRC_OVER, 0, 255, AC_SRC_ALPHA }; - - /* Do the alpha blending render */ - premultiply_alpha_channel(dibBits, xorBitmapBits, xorLength); - hBitTemp = SelectObject( hMemDC, hXorBits ); - - if (DoOffscreen) - GdiAlphaBlend(hDC_off, 0, 0, cxWidth, cyWidth, hMemDC, - 0, 0, ptr->nWidth, ptr->nHeight, pixelblend); - else - GdiAlphaBlend(hdc, x0, y0, cxWidth, cyWidth, hMemDC, - 0, 0, ptr->nWidth, ptr->nHeight, pixelblend); - - SelectObject( hMemDC, hBitTemp ); - } + if (DoOffscreen) + StretchBlt (hDC_off, 0, 0, cxWidth, cyWidth, + hMemDC, 0, 0, ptr->nWidth, ptr->nHeight, SRCPAINT); else - { - memcpy(dibBits, xorBitmapBits, xorLength); - hBitTemp = SelectObject( hMemDC, hXorBits ); - if (DoOffscreen) - StretchBlt (hDC_off, 0, 0, cxWidth, cyWidth, - hMemDC, 0, 0, ptr->nWidth, ptr->nHeight, SRCPAINT); - else - StretchBlt (hdc, x0, y0, cxWidth, cyWidth, - hMemDC, 0, 0, ptr->nWidth, ptr->nHeight, SRCPAINT); - SelectObject( hMemDC, hBitTemp ); - } - - DeleteObject( hXorBits ); + StretchBlt (hdc, x0, y0, cxWidth, cyWidth, + hMemDC, 0, 0, ptr->nWidth, ptr->nHeight, SRCPAINT); } + SelectObject( hMemDC, hBitTemp ); + result = TRUE; } - result = TRUE; - SetTextColor( hdc, oldFg ); SetBkColor( hdc, oldBg ); - + if (hXorBits) DeleteObject( hXorBits ); if (hAndBits) DeleteObject( hAndBits ); SetStretchBltMode (hdc, nStretchMode); if (DoOffscreen) { diff --git a/dlls/user32/defwnd.c b/dlls/user32/defwnd.c index 19d6ab22656..bf30c97478d 100644 --- a/dlls/user32/defwnd.c +++ b/dlls/user32/defwnd.c @@ -216,7 +216,7 @@ static void DEFWND_Print( HWND hwnd, HDC hdc, ULONG uFlags) * Client area */ if ( uFlags & PRF_CLIENT) - SendMessageW(hwnd, WM_PRINTCLIENT, (WPARAM)hdc, uFlags); + SendMessageW(hwnd, WM_PRINTCLIENT, (WPARAM)hdc, PRF_CLIENT); } diff --git a/dlls/user32/menu.c b/dlls/user32/menu.c index 203340a3bef..ab473eab5b8 100644 --- a/dlls/user32/menu.c +++ b/dlls/user32/menu.c @@ -147,11 +147,6 @@ typedef struct #define MENU_TOP_MARGIN 3 #define MENU_BOTTOM_MARGIN 2 -/* maximum allowed depth of any branch in the menu tree. - * This value is slightly larger than in windows (25) to - * stay on the safe side. */ -#define MAXMENUDEPTH 30 - /* (other menu->FocusedItem values give the position of the focused item) */ #define NO_SELECTED_ITEM 0xffff @@ -190,8 +185,6 @@ static LRESULT WINAPI PopupMenuWndProc( HWND hwnd, UINT message, WPARAM wParam, DWORD WINAPI DrawMenuBarTemp(HWND hwnd, HDC hDC, LPRECT lprect, HMENU hMenu, HFONT hFont); -static BOOL SetMenuItemInfo_common( MENUITEM *, const MENUITEMINFOW *, BOOL); - /********************************************************************* * menu class descriptor */ @@ -2055,6 +2048,92 @@ static void MENU_MoveSelection( HWND hwndOwner, HMENU hmenu, INT offset ) /********************************************************************** + * MENU_SetItemData + * + * Set an item's flags, id and text ptr. Called by InsertMenu() and + * ModifyMenu(). + */ +static BOOL MENU_SetItemData( MENUITEM *item, UINT flags, UINT_PTR id, + LPCWSTR str ) +{ + debug_print_menuitem("MENU_SetItemData from: ", item, ""); + TRACE("flags=%x str=%p\n", flags, str); + + if (IS_STRING_ITEM(flags)) + { + LPWSTR prevText = item->text; + if (!str) + { + flags |= MF_SEPARATOR; + item->text = NULL; + } + else + { + LPWSTR text; + /* Item beginning with a backspace is a help item */ + if (*str == '\b') + { + flags |= MF_HELP; + str++; + } + if (!(text = HeapAlloc( GetProcessHeap(), 0, (strlenW(str)+1) * sizeof(WCHAR) ))) + return FALSE; + strcpyW( text, str ); + item->text = text; + } + item->hbmpItem = NULL; + HeapFree( GetProcessHeap(), 0, prevText ); + } + else if(( flags & MFT_BITMAP)) { + item->hbmpItem = HBITMAP_32(LOWORD(str)); + /* setting bitmap clears text */ + HeapFree( GetProcessHeap(), 0, item->text ); + item->text = NULL; + } + + if (flags & MF_SEPARATOR) flags |= MF_GRAYED | MF_DISABLED; + + if (flags & MF_OWNERDRAW) + item->dwItemData = (DWORD_PTR)str; + else + item->dwItemData = 0; + + if ((item->fType & MF_POPUP) && (flags & MF_POPUP) && (item->hSubMenu != (HMENU)id) ) + DestroyMenu( item->hSubMenu ); /* ModifyMenu() spec */ + + if (flags & MF_POPUP) + { + POPUPMENU *menu = MENU_GetMenu((HMENU)id); + if (menu) menu->wFlags |= MF_POPUP; + else + { + item->wID = 0; + item->hSubMenu = 0; + item->fType = 0; + item->fState = 0; + return FALSE; + } + } + + item->wID = id; + if (flags & MF_POPUP) item->hSubMenu = (HMENU)id; + + if ((item->fType & MF_POPUP) && !(flags & MF_POPUP) ) + flags |= MF_POPUP; /* keep popup */ + + item->fType = flags & TYPE_MASK; + /* MFS_DEFAULT is not accepted. MF_HILITE is not listed as a valid flag + for ModifyMenu, but Windows accepts it */ + item->fState = flags & MENUITEMINFO_STATE_MASK & ~MFS_DEFAULT; + + /* Don't call SetRectEmpty here! */ + + debug_print_menuitem("MENU_SetItemData to : ", item, ""); + return TRUE; +} + + +/********************************************************************** * MENU_InsertItem * * Insert (allocate) a new item into a menu. @@ -2085,7 +2164,8 @@ static MENUITEM *MENU_InsertItem( HMENU hMenu, UINT pos, UINT flags ) * Note: XP treats only bitmap handles 1 - 6 as "magic" ones * regardless of their id. */ - while (pos > 0 && (INT_PTR)menu->items[pos - 1].hbmpItem >= (INT_PTR)HBMMENU_SYSTEM && + while (pos > 0 && (menu->items[pos - 1].fType & MFT_BITMAP) && + (INT_PTR)menu->items[pos - 1].hbmpItem >= (INT_PTR)HBMMENU_SYSTEM && (INT_PTR)menu->items[pos - 1].hbmpItem <= (INT_PTR)HBMMENU_MBAR_CLOSE_D) pos--; @@ -3747,49 +3827,6 @@ UINT WINAPI GetMenuItemID( HMENU hMenu, INT nPos ) } -/********************************************************************** - * MENU_mnu2mnuii - * - * Uses flags, id and text ptr, passed by InsertMenu() and - * ModifyMenu() to setup a MenuItemInfo structure. - */ -static void MENU_mnu2mnuii( UINT flags, UINT_PTR id, LPCWSTR str, - LPMENUITEMINFOW pmii) -{ - ZeroMemory( pmii, sizeof( MENUITEMINFOW)); - pmii->cbSize = sizeof( MENUITEMINFOW); - pmii->fMask = MIIM_STATE | MIIM_ID | MIIM_FTYPE; - /* setting bitmap clears text and vice versa */ - if( IS_STRING_ITEM(flags)) { - pmii->fMask |= MIIM_STRING | MIIM_BITMAP; - if( !str) - flags |= MF_SEPARATOR; - /* Item beginning with a backspace is a help item */ - /* FIXME: wrong place, this is only true in win16 */ - else if( *str == '\b') { - flags |= MF_HELP; - str++; - } - pmii->dwTypeData = (LPWSTR)str; - } else if( flags & MFT_BITMAP){ - pmii->fMask |= MIIM_BITMAP | MIIM_STRING; - pmii->hbmpItem = HBITMAP_32(LOWORD(str)); - } - if( flags & MF_OWNERDRAW){ - pmii->fMask |= MIIM_DATA; - pmii->dwItemData = (ULONG_PTR) str; - } - if( flags & MF_POPUP) { - pmii->fMask |= MIIM_SUBMENU; - pmii->hSubMenu = (HMENU)id; - } - if( flags & MF_SEPARATOR) flags |= MF_GRAYED | MF_DISABLED; - pmii->fState = flags & MENUITEMINFO_STATE_MASK & ~MFS_DEFAULT; - pmii->fType = flags & MENUITEMINFO_TYPE_MASK; - pmii->wID = (UINT)id; -} - - /******************************************************************* * InsertMenuW (USER32.@) */ @@ -3797,7 +3834,6 @@ BOOL WINAPI InsertMenuW( HMENU hMenu, UINT pos, UINT flags, UINT_PTR id, LPCWSTR str ) { MENUITEM *item; - MENUITEMINFOW mii; if (IS_STRING_ITEM(flags) && str) TRACE("hMenu %p, pos %d, flags %08x, id %04lx, str %s\n", @@ -3806,8 +3842,8 @@ BOOL WINAPI InsertMenuW( HMENU hMenu, UINT pos, UINT flags, hMenu, pos, flags, id, str ); if (!(item = MENU_InsertItem( hMenu, pos, flags ))) return FALSE; - MENU_mnu2mnuii( flags, id, str, &mii); - if (!(SetMenuItemInfo_common( item, &mii, TRUE))) + + if (!(MENU_SetItemData( item, flags, id, str ))) { RemoveMenu( hMenu, pos, flags ); return FALSE; @@ -3919,7 +3955,6 @@ BOOL WINAPI ModifyMenuW( HMENU hMenu, UINT pos, UINT flags, UINT_PTR id, LPCWSTR str ) { MENUITEM *item; - MENUITEMINFOW mii; if (IS_STRING_ITEM(flags)) TRACE("%p %d %04x %04lx %s\n", hMenu, pos, flags, id, debugstr_w(str) ); @@ -3928,8 +3963,7 @@ BOOL WINAPI ModifyMenuW( HMENU hMenu, UINT pos, UINT flags, if (!(item = MENU_FindItem( &hMenu, &pos, flags ))) return FALSE; MENU_GetMenu(hMenu)->Height = 0; /* force size recalculate */ - MENU_mnu2mnuii( flags, id, str, &mii); - return SetMenuItemInfo_common( item, &mii, TRUE); + return MENU_SetItemData( item, flags, id, str ); } @@ -4632,34 +4666,7 @@ static inline void set_menu_item_text( MENUITEM *menu, LPCWSTR text, BOOL unicod /********************************************************************** - * MENU_depth - * - * detect if there are loops in the menu tree (or the depth is too large) - */ -static int MENU_depth( POPUPMENU *pmenu, int depth) -{ - int i; - MENUITEM *item; - - depth++; - if( depth > MAXMENUDEPTH) return depth; - item = pmenu->items; - for( i = 0; i < pmenu->nItems && depth <= MAXMENUDEPTH; i++, item++){ - POPUPMENU *psubmenu = MENU_GetMenu( item->hSubMenu); - if( psubmenu){ - int bdepth = MENU_depth( psubmenu, depth); - if( bdepth > depth) depth = bdepth; - } - } - return depth; -} - - -/********************************************************************** * SetMenuItemInfo_common - * - * Note: does not support the MIIM_TYPE flag. Use the MIIM_FTYPE, - * MIIM_BITMAP and MIIM_STRING flags instead. */ static BOOL SetMenuItemInfo_common(MENUITEM * menu, @@ -4670,7 +4677,30 @@ static BOOL SetMenuItemInfo_common(MENUITEM * menu, debug_print_menuitem("SetMenuItemInfo_common from: ", menu, ""); + if (lpmii->fMask & MIIM_TYPE ) { + if( lpmii->fMask & ( MIIM_STRING | MIIM_FTYPE | MIIM_BITMAP)) { + WARN("invalid combination of fMask bits used\n"); + /* this does not happen on Win9x/ME */ + SetLastError( ERROR_INVALID_PARAMETER); + return FALSE; + } + + /* Remove the old type bits and replace them with the new ones */ + menu->fType &= ~MENUITEMINFO_TYPE_MASK; + menu->fType |= lpmii->fType & MENUITEMINFO_TYPE_MASK; + + if (IS_STRING_ITEM(menu->fType)) { + HeapFree(GetProcessHeap(), 0, menu->text); + set_menu_item_text( menu, lpmii->dwTypeData, unicode ); + } else if( (menu->fType) & MFT_BITMAP) + menu->hbmpItem = HBITMAP_32(LOWORD(lpmii->dwTypeData)); + } + if (lpmii->fMask & MIIM_FTYPE ) { + if(( lpmii->fType & MFT_BITMAP)) { + SetLastError( ERROR_INVALID_PARAMETER); + return FALSE; + } menu->fType &= ~MENUITEMINFO_TYPE_MASK; menu->fType |= lpmii->fType & MENUITEMINFO_TYPE_MASK; } @@ -4681,9 +4711,11 @@ static BOOL SetMenuItemInfo_common(MENUITEM * menu, } if (lpmii->fMask & MIIM_STATE) + { /* Other menu items having MFS_DEFAULT are not converted to normal items */ menu->fState = lpmii->fState & MENUITEMINFO_STATE_MASK; + } if (lpmii->fMask & MIIM_ID) menu->wID = lpmii->wID; @@ -4693,14 +4725,10 @@ static BOOL SetMenuItemInfo_common(MENUITEM * menu, if (menu->hSubMenu) { POPUPMENU *subMenu = MENU_GetMenu(menu->hSubMenu); if (subMenu) { - if( MENU_depth( subMenu, 0) > MAXMENUDEPTH) { - ERR( "Loop detected in menu hierarchy or maximum menu depth exceeded!\n"); - menu->hSubMenu = 0; - return FALSE; - } subMenu->wFlags |= MF_POPUP; menu->fType |= MF_POPUP; - } else { + } + else { SetLastError( ERROR_INVALID_PARAMETER); return FALSE; } @@ -4728,63 +4756,27 @@ static BOOL SetMenuItemInfo_common(MENUITEM * menu, } /********************************************************************** - * MENU_NormalizeMenuItemInfoStruct - * - * Helper for SetMenuItemInfo and InsertMenuItemInfo: - * check, copy and extend the MENUITEMINFO struct from the version that the application - * supplied to the version used by wine source. */ -static BOOL MENU_NormalizeMenuItemInfoStruct( const MENUITEMINFOW *pmii_in, - MENUITEMINFOW *pmii_out ) -{ - /* do we recognize the size? */ - if( pmii_in->cbSize != sizeof( MENUITEMINFOW) && - pmii_in->cbSize != sizeof( MENUITEMINFOW) - sizeof( pmii_in->hbmpItem)) { - SetLastError( ERROR_INVALID_PARAMETER); - return FALSE; - } - /* copy the fields that we have */ - memcpy( pmii_out, pmii_in, pmii_in->cbSize); - /* if the hbmpItem member is missing then extend */ - if( pmii_in->cbSize != sizeof( MENUITEMINFOW)) { - pmii_out->cbSize = sizeof( MENUITEMINFOW); - pmii_out->hbmpItem = NULL; - } - /* test for invalid bit combinations */ - if( (pmii_out->fMask & MIIM_TYPE && - pmii_out->fMask & (MIIM_STRING | MIIM_FTYPE | MIIM_BITMAP)) || - (pmii_out->fMask & MIIM_FTYPE && pmii_out->fType & MFT_BITMAP)) { - WARN("invalid combination of fMask bits used\n"); - /* this does not happen on Win9x/ME */ - SetLastError( ERROR_INVALID_PARAMETER); - return FALSE; - } - /* convert old style (MIIM_TYPE) to the new */ - if( pmii_out->fMask & MIIM_TYPE){ - pmii_out->fMask |= MIIM_FTYPE; - if( IS_STRING_ITEM(pmii_out->fType)){ - pmii_out->fMask |= MIIM_STRING; - } else if( (pmii_out->fType) & MFT_BITMAP){ - pmii_out->fMask |= MIIM_BITMAP; - pmii_out->hbmpItem = HBITMAP_32(LOWORD(pmii_out->dwTypeData)); - } - } - return TRUE; -} - -/********************************************************************** * SetMenuItemInfoA (USER32.@) */ BOOL WINAPI SetMenuItemInfoA(HMENU hmenu, UINT item, BOOL bypos, const MENUITEMINFOA *lpmii) { - MENUITEMINFOW mii; + MENUITEMINFOA mii; TRACE("hmenu %p, item %u, by pos %d, info %p\n", hmenu, item, bypos, lpmii); - if (!MENU_NormalizeMenuItemInfoStruct( (MENUITEMINFOW *)lpmii, &mii )) return FALSE; - + if( lpmii->cbSize != sizeof( mii) && + lpmii->cbSize != sizeof( mii) - sizeof ( mii.hbmpItem)) { + SetLastError( ERROR_INVALID_PARAMETER); + return FALSE; + } + memcpy( &mii, lpmii, lpmii->cbSize); + if( lpmii->cbSize != sizeof( mii)) { + mii.cbSize = sizeof( mii); + mii.hbmpItem = NULL; + } return SetMenuItemInfo_common(MENU_FindItem(&hmenu, &item, bypos? MF_BYPOSITION : 0), - &mii, FALSE); + (const MENUITEMINFOW *)&mii, FALSE); } /********************************************************************** @@ -4797,7 +4789,16 @@ BOOL WINAPI SetMenuItemInfoW(HMENU hmenu, UINT item, BOOL bypos, TRACE("hmenu %p, item %u, by pos %d, info %p\n", hmenu, item, bypos, lpmii); - if (!MENU_NormalizeMenuItemInfoStruct( lpmii, &mii )) return FALSE; + if( lpmii->cbSize != sizeof( mii) && + lpmii->cbSize != sizeof( mii) - sizeof ( mii.hbmpItem)) { + SetLastError( ERROR_INVALID_PARAMETER); + return FALSE; + } + memcpy( &mii, lpmii, lpmii->cbSize); + if( lpmii->cbSize != sizeof( mii)) { + mii.cbSize = sizeof( mii); + mii.hbmpItem = NULL; + } return SetMenuItemInfo_common(MENU_FindItem(&hmenu, &item, bypos? MF_BYPOSITION : 0), &mii, TRUE); } @@ -4900,14 +4901,23 @@ BOOL WINAPI InsertMenuItemA(HMENU hMenu, UINT uItem, BOOL bypos, const MENUITEMINFOA *lpmii) { MENUITEM *item; - MENUITEMINFOW mii; + MENUITEMINFOA mii; TRACE("hmenu %p, item %04x, by pos %d, info %p\n", hMenu, uItem, bypos, lpmii); - if (!MENU_NormalizeMenuItemInfoStruct( (MENUITEMINFOW *)lpmii, &mii )) return FALSE; + if( lpmii->cbSize != sizeof( mii) && + lpmii->cbSize != sizeof( mii) - sizeof ( mii.hbmpItem)) { + SetLastError( ERROR_INVALID_PARAMETER); + return FALSE; + } + memcpy( &mii, lpmii, lpmii->cbSize); + if( lpmii->cbSize != sizeof( mii)) { + mii.cbSize = sizeof( mii); + mii.hbmpItem = NULL; + } item = MENU_InsertItem(hMenu, uItem, bypos ? MF_BYPOSITION : 0 ); - return SetMenuItemInfo_common(item, &mii, FALSE); + return SetMenuItemInfo_common(item, (const MENUITEMINFOW *)&mii, FALSE); } @@ -4922,7 +4932,16 @@ BOOL WINAPI InsertMenuItemW(HMENU hMenu, UINT uItem, BOOL bypos, TRACE("hmenu %p, item %04x, by pos %d, info %p\n", hMenu, uItem, bypos, lpmii); - if (!MENU_NormalizeMenuItemInfoStruct( lpmii, &mii )) return FALSE; + if( lpmii->cbSize != sizeof( mii) && + lpmii->cbSize != sizeof( mii) - sizeof ( mii.hbmpItem)) { + SetLastError( ERROR_INVALID_PARAMETER); + return FALSE; + } + memcpy( &mii, lpmii, lpmii->cbSize); + if( lpmii->cbSize != sizeof( mii)) { + mii.cbSize = sizeof( mii); + mii.hbmpItem = NULL; + } item = MENU_InsertItem(hMenu, uItem, bypos ? MF_BYPOSITION : 0 ); return SetMenuItemInfo_common(item, &mii, TRUE); diff --git a/dlls/user32/resources.h b/dlls/user32/resources.h deleted file mode 100644 index 45c02914c79..00000000000 --- a/dlls/user32/resources.h +++ /dev/null @@ -1,28 +0,0 @@ -/* - * Copyright 1999 Bertho Stultiens - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#define OEMRESOURCE -#include -#include -#include -#include -#include - -#define MDI_IDC_LISTBOX 100 -#define IDS_MDI_MOREWINDOWS 13 -#define IDS_ERROR 2 diff --git a/dlls/user32/resources/user32.rc b/dlls/user32/resources/user32.rc new file mode 100644 index 00000000000..6d33b2175dd --- /dev/null +++ b/dlls/user32/resources/user32.rc @@ -0,0 +1,76 @@ +/* + * Top level resource file for USER + * + * Copyright 1999 Bertho Stultiens + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#define OEMRESOURCE +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winnls.h" +#include "dlgs.h" + +#define MDI_IDC_LISTBOX 100 +#define IDS_MDI_MOREWINDOWS 13 +#define IDS_ERROR 2 + +/* + * Everything that does not depend on language, + * like textless bitmaps etc, go into the + * neutral language. This will prevent them from + * being duplicated for each language. + */ +#include "resources/user32_bin.rc" + +/* + * Everything specific to any language goes + * in one of the specific files. + * Note that you can and may override resources + * which also have a neutral version. This is to + * get localized bitmaps for example. + */ +#include "resources/user32_Bg.rc" +#include "resources/user32_Ca.rc" +#include "resources/user32_Cs.rc" +#include "resources/user32_Da.rc" +#include "resources/user32_De.rc" +#include "resources/user32_En.rc" +#include "resources/user32_Eo.rc" +#include "resources/user32_Es.rc" +#include "resources/user32_Fi.rc" +#include "resources/user32_Fr.rc" +#include "resources/user32_Hu.rc" +#include "resources/user32_It.rc" +#include "resources/user32_Ko.rc" +#include "resources/user32_Lt.rc" +#include "resources/user32_Nl.rc" +#include "resources/user32_No.rc" +#include "resources/user32_Pl.rc" +#include "resources/user32_Pt.rc" +#include "resources/user32_Ro.rc" +#include "resources/user32_Ru.rc" +#include "resources/user32_Si.rc" +#include "resources/user32_Sk.rc" +#include "resources/user32_Sv.rc" +#include "resources/user32_Tr.rc" +#include "resources/user32_Uk.rc" +#include "resources/user32_Wa.rc" +#include "resources/user32_Ja.rc" +#include "resources/user32_Zh.rc" + +#include "resources/version.rc" diff --git a/dlls/user32/resources/user32_Bg.rc b/dlls/user32/resources/user32_Bg.rc index da8d923613a..728c1df471b 100644 --- a/dlls/user32/resources/user32_Bg.rc +++ b/dlls/user32/resources/user32_Bg.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Ca.rc b/dlls/user32/resources/user32_Ca.rc index ee846ccbefc..21c30cb257c 100644 --- a/dlls/user32/resources/user32_Ca.rc +++ b/dlls/user32/resources/user32_Ca.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_CATALAN, SUBLANG_DEFAULT SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Cs.rc b/dlls/user32/resources/user32_Cs.rc index b82dfe23a99..e3ecc4de299 100644 --- a/dlls/user32/resources/user32_Cs.rc +++ b/dlls/user32/resources/user32_Cs.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/dlls/user32/resources/user32_Da.rc b/dlls/user32/resources/user32_Da.rc index 3b5b48033b3..549cae2ff5b 100644 --- a/dlls/user32/resources/user32_Da.rc +++ b/dlls/user32/resources/user32_Da.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_De.rc b/dlls/user32/resources/user32_De.rc index edb7c30f1b1..da381d71127 100644 --- a/dlls/user32/resources/user32_De.rc +++ b/dlls/user32/resources/user32_De.rc @@ -17,35 +17,31 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE { MENUITEM "&Wiederherstellen", 61728 MENUITEM "&Verschieben", 61456 - MENUITEM "&Größe", 61440 + MENUITEM "&Größe", 61440 MENUITEM "Mi&nimieren", 61472 MENUITEM "Ma&ximieren", 61488 MENUITEM SEPARATOR - MENUITEM "&Schließen\tAlt-F4", 61536 + MENUITEM "&Schließen\tAlt-F4", 61536 MENUITEM SEPARATOR - MENUITEM "&Über Wine...", 61761 + MENUITEM "&Über Wine...", 61761 } EDITMENU MENU LOADONCALL MOVEABLE DISCARDABLE { POPUP "" BEGIN - MENUITEM "&Rückgängig", EM_UNDO + MENUITEM "&Rückgängig", EM_UNDO MENUITEM SEPARATOR MENUITEM "&Ausschneiden", WM_CUT MENUITEM "&Kopieren", WM_COPY - MENUITEM "&Einfügen", WM_PASTE - MENUITEM "&Löschen", WM_CLEAR + MENUITEM "&Einfügen", WM_PASTE + MENUITEM "&Löschen", WM_CLEAR MENUITEM SEPARATOR MENUITEM "&Alles markieren", EM_SETSEL END @@ -56,21 +52,21 @@ STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYS BEGIN ICON "", 1088, 8, 20, 16, 16, WS_CHILD | WS_VISIBLE LTEXT "", 100, 32, 4, 176, 48, WS_CHILD | WS_VISIBLE | WS_GROUP | SS_NOPREFIX - PUSHBUTTON "&OK", 1, 16, 56, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "&Abbrechen", 2, 84, 56, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "Abbr&uch", 3, 152, 56, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "&Wiederholen", 4, 220, 56, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "&Ignorieren", 5, 288, 56, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "&Ja", 6, 356, 56, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "&Nein", 7, 424, 56, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "&Erneut versuchen", 10, 492, 56, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "&Fortsetzen", 11, 560, 56, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "Hilfe", 9, 628, 56, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&OK", 1, 16, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Abbrechen", 2, 64, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "Abbr&uch", 3, 112, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Wiederholen", 4, 160, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Ignorieren", 5, 208, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Ja", 6, 256, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Nein", 7, 304, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Try Again", 10, 352, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Continue", 11, 400, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "Help", 9, 448, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP END MDI_MOREWINDOWS DIALOG FIXED IMPURE 20, 20, 232, 122 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Fenster auswählen" +CAPTION "Fenster auswählen" FONT 8, "MS Shell Dlg" BEGIN LISTBOX MDI_IDC_LISTBOX, 5, 7, 222, 90, WS_VSCROLL | WS_HSCROLL /* defined in mdi.h */ diff --git a/dlls/user32/resources/user32_En.rc b/dlls/user32/resources/user32_En.rc index a567e69e0b6..2b58927aec3 100644 --- a/dlls/user32/resources/user32_En.rc +++ b/dlls/user32/resources/user32_En.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Eo.rc b/dlls/user32/resources/user32_Eo.rc index 1b67607e86d..707dbac0915 100644 --- a/dlls/user32/resources/user32_Eo.rc +++ b/dlls/user32/resources/user32_Eo.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Es.rc b/dlls/user32/resources/user32_Es.rc index f0ee7ed7263..6cca38ef28e 100644 --- a/dlls/user32/resources/user32_Es.rc +++ b/dlls/user32/resources/user32_Es.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Fi.rc b/dlls/user32/resources/user32_Fi.rc index 2823db877f0..e4018cd3ad8 100644 --- a/dlls/user32/resources/user32_Fi.rc +++ b/dlls/user32/resources/user32_Fi.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Fr.rc b/dlls/user32/resources/user32_Fr.rc index 18d9039f788..b37a1577466 100644 --- a/dlls/user32/resources/user32_Fr.rc +++ b/dlls/user32/resources/user32_Fr.rc @@ -1,5 +1,5 @@ /* - * User32 + * User * French language support * * Copyright 1995 Alexandre Julliard @@ -19,24 +19,19 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE { MENUITEM "&Restauration", 61728 - MENUITEM "&Déplacement", 61456 + MENUITEM "&Déplacement", 61456 MENUITEM "Di&mension", 61440 - MENUITEM "Réduct&ion", 61472 + MENUITEM "Réduct&ion", 61472 MENUITEM "&Agrandissement", 61488 MENUITEM SEPARATOR MENUITEM "&Fermeture\tAlt-F4", 61536 MENUITEM SEPARATOR - MENUITEM "À propos de &Wine...", 61761 + MENUITEM "À propos de &Wine...", 61761 } EDITMENU MENU LOADONCALL MOVEABLE DISCARDABLE @@ -45,12 +40,12 @@ EDITMENU MENU LOADONCALL MOVEABLE DISCARDABLE BEGIN MENUITEM "&Annuler", EM_UNDO MENUITEM SEPARATOR - MENUITEM "&Couper", WM_CUT - MENUITEM "Co&pier", WM_COPY + MENUITEM "Coupe&r", WM_CUT + MENUITEM "&Copier", WM_COPY MENUITEM "C&oller", WM_PASTE MENUITEM "E&ffacer", WM_CLEAR MENUITEM SEPARATOR - MENUITEM "&Tout sélectionner", EM_SETSEL + MENUITEM "Tout &sélectionner", EM_SETSEL END } @@ -61,19 +56,19 @@ BEGIN LTEXT "", 100, 32, 4, 176, 48, WS_CHILD | WS_VISIBLE | WS_GROUP | SS_NOPREFIX PUSHBUTTON "&Ok", 1, 16, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "&Annuler", 2, 64, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "A&bandonner", 3, 112, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "Ré&péter", 4, 160, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Annuler", 3, 112, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Répéter", 4, 160, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "&Ignorer", 5, 208, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "&Oui", 6, 256, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "&Non", 7, 304, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "&Réessayer", 10, 352, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "&Continuer", 11, 400, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "Aide", 9, 448, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Try Again", 10, 352, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Continue", 11, 400, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "Help", 9, 448, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP END MDI_MOREWINDOWS DIALOG FIXED IMPURE 20, 20, 232, 122 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Sélection de fenêtre" +CAPTION "Sélection de fenêtre" FONT 8, "MS Shell Dlg" BEGIN LISTBOX MDI_IDC_LISTBOX, 5, 7, 222, 90, WS_VSCROLL | WS_HSCROLL /* defined in mdi.h */ @@ -85,5 +80,5 @@ END STRINGTABLE DISCARDABLE { IDS_ERROR "Erreur" - IDS_MDI_MOREWINDOWS "&Plus de fenêtres..." + IDS_MDI_MOREWINDOWS "&Plus de fenêtres..." } diff --git a/dlls/user32/resources/user32_Hu.rc b/dlls/user32/resources/user32_Hu.rc index 0ad28fe557d..851c3770edc 100644 --- a/dlls/user32/resources/user32_Hu.rc +++ b/dlls/user32/resources/user32_Hu.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_It.rc b/dlls/user32/resources/user32_It.rc index d083ace836c..542eac0daff 100644 --- a/dlls/user32/resources/user32_It.rc +++ b/dlls/user32/resources/user32_It.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Ja.rc b/dlls/user32/resources/user32_Ja.rc index c527f6b91aa..19ba7708c5e 100644 --- a/dlls/user32/resources/user32_Ja.rc +++ b/dlls/user32/resources/user32_Ja.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - /* UTF-8 */ #pragma code_page(65001) @@ -64,8 +62,8 @@ BEGIN PUSHBUTTON "無視(&I)", 5, 208, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "はい(&Y)", 6, 256, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "いいえ(&N)", 7, 304, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "再試行(&T)", 10, 352, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "続ける(&C)", 11, 400, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Try Again", 10, 352, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Continue", 11, 400, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "ヘルプ", 9, 448, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP END @@ -85,3 +83,5 @@ STRINGTABLE DISCARDABLE IDS_ERROR "エラー" IDS_MDI_MOREWINDOWS "&More Windows..." } + +#pragma code_page(default) diff --git a/dlls/user32/resources/user32_Ko.rc b/dlls/user32/resources/user32_Ko.rc index f101ad86dfe..5bae991c210 100644 --- a/dlls/user32/resources/user32_Ko.rc +++ b/dlls/user32/resources/user32_Ko.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Lt.rc b/dlls/user32/resources/user32_Lt.rc index be282de1129..a4e60b995e5 100644 --- a/dlls/user32/resources/user32_Lt.rc +++ b/dlls/user32/resources/user32_Lt.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - /* UTF-8 */ #pragma code_page(65001) @@ -84,3 +82,5 @@ STRINGTABLE DISCARDABLE IDS_ERROR "Klaida" IDS_MDI_MOREWINDOWS "&Daugiau langų..." } + +#pragma code_page(default) diff --git a/dlls/user32/resources/user32_Nl.rc b/dlls/user32/resources/user32_Nl.rc index 22169765fb7..2df1b74da12 100644 --- a/dlls/user32/resources/user32_Nl.rc +++ b/dlls/user32/resources/user32_Nl.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_No.rc b/dlls/user32/resources/user32_No.rc index 133d99a35ba..a44eb439629 100644 --- a/dlls/user32/resources/user32_No.rc +++ b/dlls/user32/resources/user32_No.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Pl.rc b/dlls/user32/resources/user32_Pl.rc index 9ccb96deaac..fe728224b2f 100644 --- a/dlls/user32/resources/user32_Pl.rc +++ b/dlls/user32/resources/user32_Pl.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Pt.rc b/dlls/user32/resources/user32_Pt.rc index a57e64f1c2f..20ea200cc42 100644 --- a/dlls/user32/resources/user32_Pt.rc +++ b/dlls/user32/resources/user32_Pt.rc @@ -1,7 +1,6 @@ /* * Copyright 1997 Ricardo R. Massaro - * Copyright 2006 Américo José Melo - * Copyright 2009 Ricardo Filipe + * Copyright 2006 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 @@ -18,10 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - -#pragma code_page(65001) - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE @@ -88,23 +83,23 @@ EDITMENU MENU LOADONCALL MOVEABLE DISCARDABLE } -LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN MSGBOX DIALOG 100, 80, 216, 168 STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU BEGIN ICON "", 1088, 8, 20, 16, 16, WS_CHILD | WS_VISIBLE LTEXT "", 100, 32, 4, 176, 48, WS_CHILD | WS_VISIBLE | WS_GROUP | SS_NOPREFIX - PUSHBUTTON "&OK", 1, 16, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Ok", 1, 16, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "&Cancelar", 2, 64, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "&Abortar", 3, 112, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "&Repetir", 4, 160, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "&Ignorar", 5, 208, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP PUSHBUTTON "&Sim", 6, 256, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "&Não", 7, 304, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "&Tente Novamente", 10, 352, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "&Continuar", 11, 400, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP - PUSHBUTTON "Ajuda", 9, 448, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Não", 7, 304, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Try Again", 10, 352, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Continue", 11, 400, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "Help", 9, 448, 56, 40, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP END @@ -133,7 +128,7 @@ BEGIN END -LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE DISCARDABLE { diff --git a/dlls/user32/resources/user32_Ro.rc b/dlls/user32/resources/user32_Ro.rc index d72f7879c93..f0568510f96 100644 --- a/dlls/user32/resources/user32_Ro.rc +++ b/dlls/user32/resources/user32_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -84,3 +82,5 @@ STRINGTABLE DISCARDABLE IDS_ERROR "Eroare" IDS_MDI_MOREWINDOWS "&Mai multe ferestre..." } + +#pragma code_page(default) diff --git a/dlls/user32/resources/user32_Ru.rc b/dlls/user32/resources/user32_Ru.rc index f3bfe0f258d..f3d6d3abc50 100644 --- a/dlls/user32/resources/user32_Ru.rc +++ b/dlls/user32/resources/user32_Ru.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Si.rc b/dlls/user32/resources/user32_Si.rc index f9966cac313..6a267c0124c 100644 --- a/dlls/user32/resources/user32_Si.rc +++ b/dlls/user32/resources/user32_Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -83,3 +81,5 @@ STRINGTABLE DISCARDABLE IDS_ERROR "Napaka" IDS_MDI_MOREWINDOWS "&Več oken ..." } + +#pragma code_page(default) diff --git a/dlls/user32/resources/user32_Sk.rc b/dlls/user32/resources/user32_Sk.rc index 44fda6c28b8..585998af544 100644 --- a/dlls/user32/resources/user32_Sk.rc +++ b/dlls/user32/resources/user32_Sk.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_SLOVAK, SUBLANG_DEFAULT SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Sv.rc b/dlls/user32/resources/user32_Sv.rc index 7f99e6fe4d2..b56657e1404 100644 --- a/dlls/user32/resources/user32_Sv.rc +++ b/dlls/user32/resources/user32_Sv.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Tr.rc b/dlls/user32/resources/user32_Tr.rc index 0aa8581ed24..c518277ae27 100644 --- a/dlls/user32/resources/user32_Tr.rc +++ b/dlls/user32/resources/user32_Tr.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Uk.rc b/dlls/user32/resources/user32_Uk.rc index 9698165c812..9559d36f17b 100644 --- a/dlls/user32/resources/user32_Uk.rc +++ b/dlls/user32/resources/user32_Uk.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_UKRAINIAN, SUBLANG_DEFAULT SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE diff --git a/dlls/user32/resources/user32_Wa.rc b/dlls/user32/resources/user32_Wa.rc index c999fe7b736..821baf8fb6a 100644 --- a/dlls/user32/resources/user32_Wa.rc +++ b/dlls/user32/resources/user32_Wa.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_WALON, SUBLANG_DEFAULT /* diff --git a/dlls/user32/resources/user32_Zh.rc b/dlls/user32/resources/user32_Zh.rc index 3dd20fae245..c112b99d3eb 100644 --- a/dlls/user32/resources/user32_Zh.rc +++ b/dlls/user32/resources/user32_Zh.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -149,3 +147,5 @@ STRINGTABLE DISCARDABLE IDS_ERROR "错误" IDS_MDI_MOREWINDOWS "更多視窗(&M)..." } + +#pragma code_page(default) diff --git a/dlls/user32/resources/user32_bin.rc b/dlls/user32/resources/user32_bin.rc index 948986f5104..9cd87c3dded 100644 --- a/dlls/user32/resources/user32_bin.rc +++ b/dlls/user32/resources/user32_bin.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" /****************************************************************/ /* Bitmaps */ diff --git a/dlls/user32/resources/version.rc b/dlls/user32/resources/version.rc index 228da33fac2..413133869ca 100644 --- a/dlls/user32/resources/version.rc +++ b/dlls/user32/resources/version.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include - LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL #define WINE_FILEVERSION_STR "1.0" diff --git a/dlls/user32/spy.c b/dlls/user32/spy.c index 3301ac1e216..c2bd60b99b8 100644 --- a/dlls/user32/spy.c +++ b/dlls/user32/spy.c @@ -731,7 +731,7 @@ static const char * const MessageTypeNames[SPY_MAX_MSGNUM + 1] = }; -#define SPY_MAX_LVMMSGNUM 182 +#define SPY_MAX_LVMMSGNUM 140 static const char * const LVMMessageTypeNames[SPY_MAX_LVMMSGNUM + 1] = { "LVM_GETBKCOLOR", /* 1000 */ @@ -872,51 +872,9 @@ static const char * const LVMMessageTypeNames[SPY_MAX_LVMMSGNUM + 1] = NULL, NULL, NULL, + NULL, "LVM_SETBKIMAGEW", - "LVM_GETBKIMAGEW", /* 0x108B */ - "LVM_SETSELECTEDCOLUMN", - "LVM_SETTILEWIDTH", - "LVM_SETVIEW", - "LVM_GETVIEW", - NULL, - "LVM_INSERTGROUP", - NULL, - "LVM_SETGROUPINFO", - NULL, - "LVM_GETGROUPINFO", - "LVM_REMOVEGROUP", - "LVM_MOVEGROUP", - NULL, - NULL, - "LVM_MOVEITEMTOGROUP", - "LVM_SETGROUPMETRICS", - "LVM_GETGROUPMETRICS", - "LVM_ENABLEGROUPVIEW", - "LVM_SORTGROUPS", - "LVM_INSERTGROUPSORTED", - "LVM_REMOVEALLGROUPS", - "LVM_HASGROUP", - "LVM_SETTILEVIEWINFO", - "LVM_GETTILEVIEWINFO", - "LVM_SETTILEINFO", - "LVM_GETTILEINFO", - "LVM_SETINSERTMARK", - "LVM_GETINSERTMARK", - "LVM_INSERTMARKHITTEST", - "LVM_GETINSERTMARKRECT", - "LVM_SETINSERTMARKCOLOR", - "LVM_GETINSERTMARKCOLOR", - NULL, - "LVM_SETINFOTIP", - "LVM_GETSELECTEDCOLUMN", - "LVM_ISGROUPVIEWENABLED", - "LVM_GETOUTLINECOLOR", - "LVM_SETOUTLINECOLOR", - NULL, - "LVM_CANCELEDITLABEL", - "LVM_MAPINDEXTOID", - "LVM_MAPIDTOINDEX", - "LVM_ISITEMVISIBLE" + "LVM_GETBKIMAGEW" /* 0x108B */ }; diff --git a/dlls/user32/tests/cursoricon.c b/dlls/user32/tests/cursoricon.c index 3f8bd82b3d3..947553498ef 100644 --- a/dlls/user32/tests/cursoricon.c +++ b/dlls/user32/tests/cursoricon.c @@ -956,262 +956,6 @@ static void test_CreateIconFromResource(void) HeapFree(GetProcessHeap(), 0, hotspot); } -static HICON create_test_icon(HDC hdc, int width, int height, int bpp, - BOOL maskvalue, UINT32 *color, int colorSize) -{ - ICONINFO iconInfo; - BITMAPINFO bitmapInfo; - UINT32 *buffer = NULL; - UINT32 mask = maskvalue ? 0xFFFFFFFF : 0x00000000; - - memset(&bitmapInfo, 0, sizeof(bitmapInfo)); - bitmapInfo.bmiHeader.biSize = sizeof(BITMAPINFOHEADER); - bitmapInfo.bmiHeader.biWidth = width; - bitmapInfo.bmiHeader.biHeight = height; - bitmapInfo.bmiHeader.biPlanes = 1; - bitmapInfo.bmiHeader.biBitCount = bpp; - bitmapInfo.bmiHeader.biCompression = BI_RGB; - bitmapInfo.bmiHeader.biSizeImage = colorSize; - - iconInfo.fIcon = TRUE; - iconInfo.xHotspot = 0; - iconInfo.yHotspot = 0; - - iconInfo.hbmMask = CreateBitmap( width, height, 1, 1, &mask ); - if(!iconInfo.hbmMask) return NULL; - - iconInfo.hbmColor = CreateDIBSection(hdc, &bitmapInfo, DIB_RGB_COLORS, (void**)&buffer, NULL, 0); - if(!iconInfo.hbmColor || !buffer) - { - DeleteObject(iconInfo.hbmMask); - return NULL; - } - - memcpy(buffer, color, colorSize); - - return CreateIconIndirect(&iconInfo); -} - -static BOOL color_match(COLORREF a, COLORREF b) -{ - /* 5-bit accuracy is a sufficient test. This will match, so long as - * colors are never truncated to less that 3x5-bit accuracy i.e. - * paletized. */ - return (a & 0x00F8F8F8) == (b & 0x00F8F8F8); -} - -static void check_alpha_draw(HDC hdc, BOOL drawiconex, BOOL alpha, int bpp, int line) -{ - HICON hicon; - UINT32 mask; - UINT32 color[2]; - COLORREF modern_expected, legacy_expected, result; - - mask = 0x00000000; - color[0] = 0x00A0B0C0; - color[1] = alpha ? 0xFF000000 : 0x00000000; - modern_expected = alpha ? 0x00FFFFFF : 0x00C0B0A0; - legacy_expected = 0x00C0B0A0; - - hicon = create_test_icon(hdc, 2, 1, bpp, 0, color, sizeof(color)); - if (!hicon) return; - - SetPixelV(hdc, 0, 0, 0x00FFFFFF); - - if(drawiconex) - DrawIconEx(hdc, 0, 0, hicon, 2, 1, 0, NULL, DI_NORMAL); - else - DrawIcon(hdc, 0, 0, hicon); - - result = GetPixel(hdc, 0, 0); - ok (color_match(result, modern_expected) || /* Windows 2000 and up */ - broken(color_match(result, legacy_expected)), /* Windows NT 4.0, 9X and below */ - "%s. Expected a close match to %06X (modern) or %06X (legacy) with %s. " - "Got %06X from line %d\n", - alpha ? "Alpha blending" : "Not alpha blending", modern_expected, legacy_expected, - drawiconex ? "DrawIconEx" : "DrawIcon", result, line); -} - -static void check_DrawIcon(HDC hdc, BOOL maskvalue, UINT32 color, int bpp, COLORREF background, - COLORREF modern_expected, COLORREF legacy_expected, int line) -{ - COLORREF result; - HICON hicon = create_test_icon(hdc, 1, 1, bpp, maskvalue, &color, sizeof(color)); - if (!hicon) return; - SetPixelV(hdc, 0, 0, background); - DrawIcon(hdc, 0, 0, hicon); - result = GetPixel(hdc, 0, 0); - - ok (color_match(result, modern_expected) || /* Windows 2000 and up */ - broken(color_match(result, legacy_expected)), /* Windows NT 4.0, 9X and below */ - "Overlaying Mask %d on Color %06X with DrawIcon. " - "Expected a close match to %06X (modern), or %06X (legacy). Got %06X from line %d\n", - maskvalue, color, modern_expected, legacy_expected, result, line); -} - -static void test_DrawIcon(void) -{ - BITMAPINFO bitmapInfo; - HDC hdcDst = NULL; - HBITMAP bmpDst = NULL; - HBITMAP bmpOld = NULL; - UINT32 *bits = 0; - - hdcDst = CreateCompatibleDC(0); - ok(hdcDst != 0, "CreateCompatibleDC(0) failed to return a valid DC\n"); - if (!hdcDst) - return; - - if(GetDeviceCaps(hdcDst, BITSPIXEL) <= 8) - { - skip("Windows will distort DrawIcon colors at 8-bpp and less due to palletizing.\n"); - goto cleanup; - } - - memset(&bitmapInfo, 0, sizeof(bitmapInfo)); - bitmapInfo.bmiHeader.biSize = sizeof(BITMAPINFOHEADER); - bitmapInfo.bmiHeader.biWidth = 1; - bitmapInfo.bmiHeader.biHeight = 1; - bitmapInfo.bmiHeader.biBitCount = 32; - bitmapInfo.bmiHeader.biPlanes = 1; - bitmapInfo.bmiHeader.biCompression = BI_RGB; - bitmapInfo.bmiHeader.biSizeImage = sizeof(UINT32); - - bmpDst = CreateDIBSection(hdcDst, &bitmapInfo, DIB_RGB_COLORS, (void**)&bits, NULL, 0); - ok (bmpDst && bits, "CreateDIBSection failed to return a valid bitmap and buffer\n"); - if (!bmpDst || !bits) - goto cleanup; - bmpOld = SelectObject(hdcDst, bmpDst); - - /* Mask is only heeded if alpha channel is always zero */ - check_DrawIcon(hdcDst, FALSE, 0x00A0B0C0, 32, 0x00FFFFFF, 0x00C0B0A0, 0x00C0B0A0, __LINE__); - check_DrawIcon(hdcDst, TRUE, 0x00A0B0C0, 32, 0x00FFFFFF, 0x003F4F5F, 0x003F4F5F, __LINE__); - - /* Test alpha blending */ - /* Windows 2000 and up will alpha blend, earlier Windows versions will not */ - check_DrawIcon(hdcDst, FALSE, 0xFFA0B0C0, 32, 0x00FFFFFF, 0x00C0B0A0, 0x00C0B0A0, __LINE__); - check_DrawIcon(hdcDst, TRUE, 0xFFA0B0C0, 32, 0x00FFFFFF, 0x00C0B0A0, 0x003F4F5F, __LINE__); - - check_DrawIcon(hdcDst, FALSE, 0x80A0B0C0, 32, 0x00000000, 0x00605850, 0x00C0B0A0, __LINE__); - check_DrawIcon(hdcDst, TRUE, 0x80A0B0C0, 32, 0x00000000, 0x00605850, 0x00C0B0A0, __LINE__); - check_DrawIcon(hdcDst, FALSE, 0x80A0B0C0, 32, 0x00FFFFFF, 0x00DFD7CF, 0x00C0B0A0, __LINE__); - check_DrawIcon(hdcDst, TRUE, 0x80A0B0C0, 32, 0x00FFFFFF, 0x00DFD7CF, 0x003F4F5F, __LINE__); - - check_DrawIcon(hdcDst, FALSE, 0x01FFFFFF, 32, 0x00000000, 0x00010101, 0x00FFFFFF, __LINE__); - check_DrawIcon(hdcDst, TRUE, 0x01FFFFFF, 32, 0x00000000, 0x00010101, 0x00FFFFFF, __LINE__); - - /* Test detecting of alpha channel */ - /* If a single pixel's alpha channel is non-zero, the icon - will be alpha blended, otherwise it will be draw with - and + xor blts. */ - check_alpha_draw(hdcDst, FALSE, FALSE, 32, __LINE__); - check_alpha_draw(hdcDst, FALSE, TRUE, 32, __LINE__); - -cleanup: - if(bmpOld) - SelectObject(hdcDst, bmpOld); - if(bmpDst) - DeleteObject(bmpDst); - if(hdcDst) - DeleteDC(hdcDst); -} - -static void check_DrawIconEx(HDC hdc, BOOL maskvalue, UINT32 color, int bpp, UINT flags, COLORREF background, - COLORREF modern_expected, COLORREF legacy_expected, int line) -{ - COLORREF result; - HICON hicon = create_test_icon(hdc, 1, 1, bpp, maskvalue, &color, sizeof(color)); - if (!hicon) return; - SetPixelV(hdc, 0, 0, background); - DrawIconEx(hdc, 0, 0, hicon, 1, 1, 0, NULL, flags); - result = GetPixel(hdc, 0, 0); - - ok (color_match(result, modern_expected) || /* Windows 2000 and up */ - broken(color_match(result, legacy_expected)), /* Windows NT 4.0, 9X and below */ - "Overlaying Mask %d on Color %06X with DrawIconEx flags %08X. " - "Expected a close match to %06X (modern) or %06X (legacy). Got %06X from line %d\n", - maskvalue, color, flags, modern_expected, legacy_expected, result, line); -} - -static void test_DrawIconEx(void) -{ - BITMAPINFO bitmapInfo; - HDC hdcDst = NULL; - HBITMAP bmpDst = NULL; - HBITMAP bmpOld = NULL; - UINT32 bits = 0; - - hdcDst = CreateCompatibleDC(0); - ok(hdcDst != 0, "CreateCompatibleDC(0) failed to return a valid DC\n"); - if (!hdcDst) - return; - - if(GetDeviceCaps(hdcDst, BITSPIXEL) <= 8) - { - skip("Windows will distort DrawIconEx colors at 8-bpp and less due to palletizing.\n"); - goto cleanup; - } - - memset(&bitmapInfo, 0, sizeof(bitmapInfo)); - bitmapInfo.bmiHeader.biSize = sizeof(BITMAPINFOHEADER); - bitmapInfo.bmiHeader.biWidth = 1; - bitmapInfo.bmiHeader.biHeight = 1; - bitmapInfo.bmiHeader.biBitCount = 32; - bitmapInfo.bmiHeader.biPlanes = 1; - bitmapInfo.bmiHeader.biCompression = BI_RGB; - bitmapInfo.bmiHeader.biSizeImage = sizeof(UINT32); - bmpDst = CreateDIBSection(hdcDst, &bitmapInfo, DIB_RGB_COLORS, (void**)&bits, NULL, 0); - ok (bmpDst && bits, "CreateDIBSection failed to return a valid bitmap and buffer\n"); - if (!bmpDst || !bits) - goto cleanup; - bmpOld = SelectObject(hdcDst, bmpDst); - - /* Test null, image only, and mask only drawing */ - check_DrawIconEx(hdcDst, FALSE, 0x00A0B0C0, 32, 0, 0x00102030, 0x00102030, 0x00102030, __LINE__); - check_DrawIconEx(hdcDst, TRUE, 0x00A0B0C0, 32, 0, 0x00102030, 0x00102030, 0x00102030, __LINE__); - - check_DrawIconEx(hdcDst, FALSE, 0x80A0B0C0, 32, DI_MASK, 0x00FFFFFF, 0x00000000, 0x00000000, __LINE__); - check_DrawIconEx(hdcDst, TRUE, 0x80A0B0C0, 32, DI_MASK, 0x00FFFFFF, 0x00FFFFFF, 0x00FFFFFF, __LINE__); - - todo_wine - { - check_DrawIconEx(hdcDst, FALSE, 0x00A0B0C0, 32, DI_IMAGE, 0x00FFFFFF, 0x00C0B0A0, 0x00C0B0A0, __LINE__); - check_DrawIconEx(hdcDst, TRUE, 0x00A0B0C0, 32, DI_IMAGE, 0x00FFFFFF, 0x00C0B0A0, 0x00C0B0A0, __LINE__); - } - - /* Test normal drawing */ - check_DrawIconEx(hdcDst, FALSE, 0x00A0B0C0, 32, DI_NORMAL, 0x00FFFFFF, 0x00C0B0A0, 0x00C0B0A0, __LINE__); - todo_wine check_DrawIconEx(hdcDst, TRUE, 0x00A0B0C0, 32, DI_NORMAL, 0x00FFFFFF, 0x003F4F5F, 0x003F4F5F, __LINE__); - check_DrawIconEx(hdcDst, FALSE, 0xFFA0B0C0, 32, DI_NORMAL, 0x00FFFFFF, 0x00C0B0A0, 0x00C0B0A0, __LINE__); - - /* Test alpha blending */ - /* Windows 2000 and up will alpha blend, earlier Windows versions will not */ - check_DrawIconEx(hdcDst, TRUE, 0xFFA0B0C0, 32, DI_NORMAL, 0x00FFFFFF, 0x00C0B0A0, 0x003F4F5F, __LINE__); - - check_DrawIconEx(hdcDst, FALSE, 0x80A0B0C0, 32, DI_NORMAL, 0x00000000, 0x00605850, 0x00C0B0A0, __LINE__); - check_DrawIconEx(hdcDst, TRUE, 0x80A0B0C0, 32, DI_NORMAL, 0x00000000, 0x00605850, 0x00C0B0A0, __LINE__); - check_DrawIconEx(hdcDst, FALSE, 0x80A0B0C0, 32, DI_NORMAL, 0x00FFFFFF, 0x00DFD7CF, 0x00C0B0A0, __LINE__); - check_DrawIconEx(hdcDst, TRUE, 0x80A0B0C0, 32, DI_NORMAL, 0x00FFFFFF, 0x00DFD7CF, 0x003F4F5F, __LINE__); - - check_DrawIconEx(hdcDst, FALSE, 0x01FFFFFF, 32, DI_NORMAL, 0x00000000, 0x00010101, 0x00FFFFFF, __LINE__); - check_DrawIconEx(hdcDst, TRUE, 0x01FFFFFF, 32, DI_NORMAL, 0x00000000, 0x00010101, 0x00FFFFFF, __LINE__); - - /* Test detecting of alpha channel */ - /* If a single pixel's alpha channel is non-zero, the icon - will be alpha blended, otherwise it will be draw with - and + xor blts. */ - check_alpha_draw(hdcDst, TRUE, FALSE, 32, __LINE__); - check_alpha_draw(hdcDst, TRUE, TRUE, 32, __LINE__); - -cleanup: - if(bmpOld) - SelectObject(hdcDst, bmpOld); - if(bmpDst) - DeleteObject(bmpDst); - if(hdcDst) - DeleteDC(hdcDst); -} - static void test_DestroyCursor(void) { static const BYTE bmp_bits[4096]; @@ -1319,8 +1063,6 @@ START_TEST(cursoricon) test_CreateIcon(); test_LoadImage(); test_CreateIconFromResource(); - test_DrawIcon(); - test_DrawIconEx(); test_DestroyCursor(); do_parent(); test_child_process(); diff --git a/dlls/user32/tests/input.c b/dlls/user32/tests/input.c index 6ef7817ed15..d100610f22a 100644 --- a/dlls/user32/tests/input.c +++ b/dlls/user32/tests/input.c @@ -824,8 +824,7 @@ static LRESULT CALLBACK WndProc2(HWND hWnd, UINT Msg, WPARAM wParam, Msg != WM_GETTEXT && Msg != WM_GETICON && Msg != WM_IME_SELECT && - Msg != WM_DEVICECHANGE && - Msg != WM_TIMECHANGE) + Msg != WM_DEVICECHANGE) { ok(sent_messages_cnt < MAXKEYMESSAGES, "Too many messages\n"); if (sent_messages_cnt < MAXKEYMESSAGES) diff --git a/dlls/user32/tests/menu.c b/dlls/user32/tests/menu.c index a1af9446a6d..0948f69b0e7 100644 --- a/dlls/user32/tests/menu.c +++ b/dlls/user32/tests/menu.c @@ -2451,48 +2451,6 @@ static HMENU create_menu_from_data(const struct menu_data *item, INT item_count) return hmenu; } -/* use InsertMenuItem: does not set the MFT_BITMAP flag, - * and does not accept non-magic bitmaps with invalid - * bitmap handles */ -static HMENU create_menuitem_from_data(const struct menu_data *item, INT item_count) -{ - HMENU hmenu; - INT i; - BOOL ret; - MENUITEMINFO mii = { sizeof( MENUITEMINFO)}; - - hmenu = CreateMenu(); - assert(hmenu != 0); - - for (i = 0; i < item_count; i++) - { - SetLastError(0xdeadbeef); - - mii.fMask = MIIM_FTYPE | MIIM_ID | MIIM_STATE; - mii.fType = 0; - if( item[i].type & MFT_BITMAP) - { - mii.fMask |= MIIM_BITMAP; - mii.hbmpItem = (HBITMAP)item[i].str; - } - else if( item[i].type & MFT_SEPARATOR) - mii.fType = MFT_SEPARATOR; - else - { - mii.fMask |= MIIM_STRING; - mii.dwTypeData = (LPSTR)item[i].str; - mii.cch = strlen( item[i].str); - } - mii.fState = 0; - if( item[i].type & MF_HELP) mii.fType |= MF_HELP; - mii.wID = item[i].id; - ret = InsertMenuItem( hmenu, -1, TRUE, &mii); - ok(ret, "%d: InsertMenuItem(%04x, %04x, %p) error %u\n", - i, item[i].type, item[i].id, item[i].str, GetLastError()); - } - return hmenu; -} - static void compare_menu_data(HMENU hmenu, const struct menu_data *item, INT item_count) { INT count, i; @@ -2521,12 +2479,14 @@ static void compare_menu_data(HMENU hmenu, const struct menu_data *item, INT ite "%u: expected fType %04x, got %04x\n", i, item[i].type, mii.fType); ok(mii.wID == item[i].id, "%u: expected wID %04x, got %04x\n", i, item[i].id, mii.wID); - if (mii.hbmpItem || !item[i].str) + if (item[i].type & (MF_BITMAP | MF_SEPARATOR)) + { /* For some reason Windows sets high word to not 0 for * not "magic" ids. */ ok(LOWORD(mii.hbmpItem) == LOWORD(item[i].str), "%u: expected hbmpItem %p, got %p\n", i, item[i].str, mii.hbmpItem); + } else { ok(mii.cch == strlen(item[i].str), @@ -2539,7 +2499,6 @@ static void compare_menu_data(HMENU hmenu, const struct menu_data *item, INT ite static void test_InsertMenu(void) { - HBITMAP hbm = CreateBitmap(1,1,1,1,NULL); /* Note: XP treats only bitmap handles 1 - 6 as "magic" ones * regardless of their id. */ @@ -2555,28 +2514,16 @@ static void test_InsertMenu(void) { MF_STRING|MF_HELP, 2, "Help" }, { MF_BITMAP|MF_HELP, SC_CLOSE, MAKEINTRESOURCE(1) } }; - static const struct menu_data out1a[] = + static const struct menu_data in2[] = { { MF_STRING, 1, "File" }, - { MF_STRING|MF_HELP, 2, "Help" }, - { MF_HELP, SC_CLOSE, MAKEINTRESOURCE(1) } - }; - const struct menu_data in2[] = - { - { MF_STRING, 1, "File" }, - { MF_BITMAP|MF_HELP, SC_CLOSE, (char*)hbm }, + { MF_BITMAP|MF_HELP, SC_CLOSE, MAKEINTRESOURCE(100) }, { MF_STRING|MF_HELP, 2, "Help" } }; - const struct menu_data out2[] = + static const struct menu_data out2[] = { { MF_STRING, 1, "File" }, - { MF_BITMAP|MF_HELP, SC_CLOSE, (char*)hbm }, - { MF_STRING|MF_HELP, 2, "Help" } - }; - const struct menu_data out2a[] = - { - { MF_STRING, 1, "File" }, - { MF_HELP, SC_CLOSE, (char*)hbm }, + { MF_BITMAP|MF_HELP, SC_CLOSE, MAKEINTRESOURCE(100) }, { MF_STRING|MF_HELP, 2, "Help" } }; static const struct menu_data in3[] = @@ -2603,16 +2550,9 @@ static void test_InsertMenu(void) { MF_STRING|MF_HELP, 2, "Help" }, { MF_BITMAP|MF_HELP, 1, MAKEINTRESOURCE(1) } }; - static const struct menu_data out4a[] = - { - { MF_STRING, 1, "File" }, - { MF_STRING|MF_HELP, 2, "Help" }, - { MF_HELP, 1, MAKEINTRESOURCE(1) } - }; HMENU hmenu; #define create_menu(a) create_menu_from_data((a), sizeof(a)/sizeof((a)[0])) -#define create_menuitem(a) create_menuitem_from_data((a), sizeof(a)/sizeof((a)[0])) #define compare_menu(h, a) compare_menu_data((h), (a), sizeof(a)/sizeof((a)[0])) hmenu = create_menu(in1); @@ -2631,25 +2571,7 @@ static void test_InsertMenu(void) compare_menu(hmenu, out4); DestroyMenu(hmenu); - /* now using InsertMenuItemInfo */ - hmenu = create_menuitem(in1); - compare_menu(hmenu, out1a); - DestroyMenu(hmenu); - - hmenu = create_menuitem(in2); - compare_menu(hmenu, out2a); - DestroyMenu(hmenu); - - hmenu = create_menuitem(in3); - compare_menu(hmenu, out3); - DestroyMenu(hmenu); - - hmenu = create_menuitem(in4); - compare_menu(hmenu, out4a); - DestroyMenu(hmenu); - #undef create_menu -#undef create_menuitem #undef compare_menu } @@ -3010,63 +2932,6 @@ static void test_menu_cancelmode(void) DestroyWindow( hwnd); } -/* show menu trees have a maximum depth */ -static void test_menu_maxdepth(void) -{ -#define NR_MENUS 100 - HMENU hmenus[ NR_MENUS]; - int i; - DWORD ret; - - SetLastError(12345678); - for( i = 0; i < NR_MENUS; i++) { - hmenus[i] = CreatePopupMenu(); - if( !hmenus[i]) break; - } - ok( i == NR_MENUS, "could not create more then %d menu's\n", i); - for( i = 1; i < NR_MENUS; i++) { - ret = AppendMenuA( hmenus[i], MF_POPUP, (UINT_PTR)hmenus[i-1],"test"); - if( !ret) break; - } - trace("Maximum depth is %d\n", i); - ok( GetLastError() == 12345678, "unexpected error %d\n", GetLastError()); - ok( i < NR_MENUS || - broken( i == NR_MENUS), /* win98, NT */ - "no ( or very large) limit on menu depth!\n"); - - for( i = 0; i < NR_MENUS; i++) - DestroyMenu( hmenus[i]); -} - -/* bug #12171 */ -static void test_menu_circref(void) -{ - HMENU menu1, menu2; - DWORD ret; - - menu1 = CreatePopupMenu(); - menu2 = CreatePopupMenu(); - ok( menu1 && menu2, "error creating menus.\n"); - ret = AppendMenuA( menu1, MF_POPUP, (UINT_PTR)menu2, "winetest"); - ok( ret, "AppendMenu failed, error is %d\n", GetLastError()); - ret = AppendMenuA( menu1, MF_STRING | MF_HILITE, 123, "winetest"); - ok( ret, "AppendMenu failed, error is %d\n", GetLastError()); - /* app chooses an id that happens to clash with its own hmenu */ - ret = AppendMenuA( menu2, MF_STRING, (UINT_PTR)menu2, "winetest"); - ok( ret, "AppendMenu failed, error is %d\n", GetLastError()); - /* now attempt to change the string of the first item of menu1 */ - ret = ModifyMenuA( menu1, (UINT_PTR)menu2, MF_POPUP, (UINT_PTR)menu2, "menu 2"); - ok( !ret || - broken( ret), /* win98, NT */ - "ModifyMenu should have failed.\n"); - if( !ret) { /* will probably stack fault if the ModifyMenu succeeded */ - ret = GetMenuState( menu1, 123, 0); - ok( ret == MF_HILITE, "GetMenuState returned %x\n",ret); - } - DestroyMenu( menu2); - DestroyMenu( menu1); -} - START_TEST(menu) { init_function_pointers(); @@ -3105,6 +2970,4 @@ START_TEST(menu) test_menu_hilitemenuitem(); test_menu_trackpopupmenu(); test_menu_cancelmode(); - test_menu_maxdepth(); - test_menu_circref(); } diff --git a/dlls/user32/tests/msg.c b/dlls/user32/tests/msg.c index e2789cee03f..580582f58ad 100644 --- a/dlls/user32/tests/msg.c +++ b/dlls/user32/tests/msg.c @@ -5209,49 +5209,6 @@ static const struct message WmSetFontButtonSeq[] = { WM_CTLCOLORBTN, sent|defwinproc }, { 0 } }; -static const struct message WmSetStyleButtonSeq[] = -{ - { BM_SETSTYLE, sent }, - { WM_APP, sent|wparam|lparam, 0, 0 }, - { WM_PAINT, sent }, - { WM_NCPAINT, sent|defwinproc|optional }, /* FIXME: Wine sends it */ - { WM_ERASEBKGND, sent|defwinproc|optional }, /* Win9x doesn't send it */ - { WM_CTLCOLORBTN, sent|parent }, - { 0 } -}; -static const struct message WmSetStyleStaticSeq[] = -{ - { BM_SETSTYLE, sent }, - { WM_APP, sent|wparam|lparam, 0, 0 }, - { WM_PAINT, sent }, - { WM_NCPAINT, sent|defwinproc|optional }, /* FIXME: Wine sends it */ - { WM_ERASEBKGND, sent|defwinproc|optional }, /* Win9x doesn't send it */ - { WM_CTLCOLORSTATIC, sent|parent }, - { 0 } -}; -static const struct message WmSetStyleUserSeq[] = -{ - { BM_SETSTYLE, sent }, - { WM_APP, sent|wparam|lparam, 0, 0 }, - { WM_PAINT, sent }, - { WM_NCPAINT, sent|defwinproc|optional }, /* FIXME: Wine sends it */ - { WM_ERASEBKGND, sent|defwinproc|optional }, /* Win9x doesn't send it */ - { WM_CTLCOLORBTN, sent|parent }, - { WM_COMMAND, sent|wparam|parent, MAKEWPARAM(ID_BUTTON, BN_PAINT) }, - { 0 } -}; -static const struct message WmSetStyleOwnerdrawSeq[] = -{ - { BM_SETSTYLE, sent }, - { WM_APP, sent|wparam|lparam, 0, 0 }, - { WM_PAINT, sent }, - { WM_NCPAINT, sent|optional }, /* FIXME: Wine sends it */ - { WM_ERASEBKGND, sent|defwinproc|optional }, /* Win9x doesn't send it */ - { WM_CTLCOLORBTN, sent|parent }, - { WM_CTLCOLORBTN, sent|parent|optional }, /* Win9x doesn't send it */ - { WM_DRAWITEM, sent|wparam|lparam|parent, ID_BUTTON, 0x000010e4 }, - { 0 } -}; static WNDPROC old_button_proc; @@ -5311,30 +5268,29 @@ static void test_button_messages(void) DWORD dlg_code; const struct message *setfocus; const struct message *killfocus; - const struct message *setstyle; } button[] = { { BS_PUSHBUTTON, DLGC_BUTTON | DLGC_UNDEFPUSHBUTTON, - WmSetFocusButtonSeq, WmKillFocusButtonSeq, WmSetStyleButtonSeq }, + WmSetFocusButtonSeq, WmKillFocusButtonSeq }, { BS_DEFPUSHBUTTON, DLGC_BUTTON | DLGC_DEFPUSHBUTTON, - WmSetFocusButtonSeq, WmKillFocusButtonSeq, WmSetStyleButtonSeq }, + WmSetFocusButtonSeq, WmKillFocusButtonSeq }, { BS_CHECKBOX, DLGC_BUTTON, - WmSetFocusStaticSeq, WmKillFocusStaticSeq, WmSetStyleStaticSeq }, + WmSetFocusStaticSeq, WmKillFocusStaticSeq }, { BS_AUTOCHECKBOX, DLGC_BUTTON, - WmSetFocusStaticSeq, WmKillFocusStaticSeq, WmSetStyleStaticSeq }, + WmSetFocusStaticSeq, WmKillFocusStaticSeq }, { BS_RADIOBUTTON, DLGC_BUTTON | DLGC_RADIOBUTTON, - WmSetFocusStaticSeq, WmKillFocusStaticSeq, WmSetStyleStaticSeq }, + WmSetFocusStaticSeq, WmKillFocusStaticSeq }, { BS_3STATE, DLGC_BUTTON, - WmSetFocusStaticSeq, WmKillFocusStaticSeq, WmSetStyleStaticSeq }, + WmSetFocusStaticSeq, WmKillFocusStaticSeq }, { BS_AUTO3STATE, DLGC_BUTTON, - WmSetFocusStaticSeq, WmKillFocusStaticSeq, WmSetStyleStaticSeq }, + WmSetFocusStaticSeq, WmKillFocusStaticSeq }, { BS_GROUPBOX, DLGC_STATIC, - WmSetFocusStaticSeq, WmKillFocusStaticSeq, WmSetStyleStaticSeq }, + WmSetFocusStaticSeq, WmKillFocusStaticSeq }, { BS_USERBUTTON, DLGC_BUTTON | DLGC_UNDEFPUSHBUTTON, - WmSetFocusButtonSeq, WmKillFocusButtonSeq, WmSetStyleUserSeq }, + WmSetFocusButtonSeq, WmKillFocusButtonSeq }, { BS_AUTORADIOBUTTON, DLGC_BUTTON | DLGC_RADIOBUTTON, - WmSetFocusStaticSeq, WmKillFocusStaticSeq, WmSetStyleStaticSeq }, + WmSetFocusStaticSeq, WmKillFocusStaticSeq }, { BS_OWNERDRAW, DLGC_BUTTON, - WmSetFocusOwnerdrawSeq, WmKillFocusOwnerdrawSeq, WmSetStyleOwnerdrawSeq } + WmSetFocusOwnerdrawSeq, WmKillFocusOwnerdrawSeq } }; unsigned int i; HWND hwnd, parent; @@ -5363,8 +5319,6 @@ static void test_button_messages(void) MSG msg; DWORD style; - trace("button style %08x\n", button[i].style); - hwnd = CreateWindowExA(0, "my_button_class", "test", button[i].style | WS_CHILD | BS_NOTIFY, 0, 0, 50, 14, parent, (HMENU)ID_BUTTON, 0, NULL); ok(hwnd != 0, "Failed to create button window\n"); @@ -5373,9 +5327,9 @@ static void test_button_messages(void) style &= ~(WS_CHILD | BS_NOTIFY); /* XP turns a BS_USERBUTTON into BS_PUSHBUTTON */ if (button[i].style == BS_USERBUTTON) - ok(style == BS_PUSHBUTTON, "expected style BS_PUSHBUTTON got %x\n", style); + todo_wine ok(style == BS_PUSHBUTTON, "expected style BS_PUSHBUTTON got %x\n", style); else - ok(style == button[i].style, "expected style %x got %x\n", button[i].style, style); + ok(style == button[i].style, "expected style %x got %x\n", button[i].style, style); dlg_code = SendMessageA(hwnd, WM_GETDLGCODE, 0, 0); ok(dlg_code == button[i].dlg_code, "%u: wrong dlg_code %08x\n", i, dlg_code); @@ -5388,6 +5342,7 @@ static void test_button_messages(void) log_all_parent_messages++; + trace("button style %08x\n", button[i].style); ok(GetFocus() == 0, "expected focus 0, got %p\n", GetFocus()); SetFocus(hwnd); SendMessage(hwnd, WM_APP, 0, 0); /* place a separator mark here */ @@ -5399,20 +5354,9 @@ static void test_button_messages(void) while (PeekMessage(&msg, 0, 0, 0, PM_REMOVE)) DispatchMessage(&msg); ok_sequence(button[i].killfocus, "SetFocus(0) on a button", FALSE); - ok(GetFocus() == 0, "expected focus 0, got %p\n", GetFocus()); - - SendMessage(hwnd, BM_SETSTYLE, button[i].style | BS_BOTTOM, TRUE); - SendMessage(hwnd, WM_APP, 0, 0); /* place a separator mark here */ - while (PeekMessage(&msg, 0, 0, 0, PM_REMOVE)) DispatchMessage(&msg); - ok_sequence(button[i].setstyle, "BM_SETSTYLE on a button", FALSE); - - style = GetWindowLongA(hwnd, GWL_STYLE); - style &= ~(WS_VISIBLE | WS_CHILD | BS_NOTIFY); - /* XP doesn't turn a BS_USERBUTTON into BS_PUSHBUTTON here! */ - ok(style == button[i].style, "expected style %x got %x\n", button[i].style, style); - log_all_parent_messages--; + ok(GetFocus() == 0, "expected focus 0, got %p\n", GetFocus()); DestroyWindow(hwnd); } diff --git a/dlls/user32/winproc.c b/dlls/user32/winproc.c index 91eeeb7d858..2a883291019 100644 --- a/dlls/user32/winproc.c +++ b/dlls/user32/winproc.c @@ -282,16 +282,10 @@ extern LRESULT WINPROC_wrapper( WNDPROC proc, HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam ); __ASM_GLOBAL_FUNC( WINPROC_wrapper, "pushl %ebp\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %ebp,0\n\t") "movl %esp,%ebp\n\t" - __ASM_CFI(".cfi_def_cfa_register %ebp\n\t") "pushl %edi\n\t" - __ASM_CFI(".cfi_rel_offset %edi,-4\n\t") "pushl %esi\n\t" - __ASM_CFI(".cfi_rel_offset %esi,-8\n\t") "pushl %ebx\n\t" - __ASM_CFI(".cfi_rel_offset %ebx,-12\n\t") "subl $12,%esp\n\t" "pushl 24(%ebp)\n\t" "pushl 20(%ebp)\n\t" @@ -301,14 +295,9 @@ __ASM_GLOBAL_FUNC( WINPROC_wrapper, "call *%eax\n\t" "leal -12(%ebp),%esp\n\t" "popl %ebx\n\t" - __ASM_CFI(".cfi_same_value %ebx\n\t") "popl %esi\n\t" - __ASM_CFI(".cfi_same_value %esi\n\t") "popl %edi\n\t" - __ASM_CFI(".cfi_same_value %edi\n\t") "leave\n\t" - __ASM_CFI(".cfi_def_cfa %esp,4\n\t") - __ASM_CFI(".cfi_same_value %ebp\n\t") "ret" ) #else static inline LRESULT WINPROC_wrapper( WNDPROC proc, HWND hwnd, UINT msg, diff --git a/dlls/uuid/uuid.c b/dlls/uuid/uuid.c index afb9abde8ce..840a34684a8 100644 --- a/dlls/uuid/uuid.c +++ b/dlls/uuid/uuid.c @@ -32,7 +32,6 @@ DEFINE_GUID(GUID_NULL,0,0,0,0,0,0,0,0,0,0,0); #include "wingdi.h" #include "winuser.h" -#define USE_COM_CONTEXT_DEF #include "objbase.h" #include "servprov.h" @@ -76,11 +75,6 @@ DEFINE_GUID(GUID_NULL,0,0,0,0,0,0,0,0,0,0,0); #include "isguids.h" #include "objsafe.h" #include "perhist.h" -#include "netcon.h" -#include "netfw.h" -#include "msctf.h" -#include "sensevts.h" -#include "ocmm.h" /* FIXME: cguids declares GUIDs but does not define their values */ diff --git a/dlls/w32sys.dll16/Makefile.in b/dlls/w32sys.dll16/Makefile.in index 7c62613a354..c04db41563c 100644 --- a/dlls/w32sys.dll16/Makefile.in +++ b/dlls/w32sys.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = w32sys.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,w32skrnl.dll +SPEC_SRCS = w32sys.dll16.spec + C_SRCS = w32sys.c @MAKE_DLL_RULES@ diff --git a/dlls/wbemprox/Makefile.in b/dlls/wbemprox/Makefile.in index 0e3b9dc73a6..58aad374f8e 100644 --- a/dlls/wbemprox/Makefile.in +++ b/dlls/wbemprox/Makefile.in @@ -3,12 +3,10 @@ TOPOBJDIR = ../.. SRCDIR = @srcdir@ VPATH = @srcdir@ MODULE = wbemprox.dll -IMPORTS = ole32 advapi32 kernel32 +IMPORTS = kernel32 C_SRCS = \ - main.c \ - regsvr.c \ - wbemlocator.c + main.c @MAKE_DLL_RULES@ diff --git a/dlls/wbemprox/main.c b/dlls/wbemprox/main.c dissimilarity index 67% index c22f57f8a2b..89812b2ea78 100644 --- a/dlls/wbemprox/main.c +++ b/dlls/wbemprox/main.c @@ -1,150 +1,42 @@ -/* - * - * Copyright 2009 Austin English - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "config.h" - -#include - -#define COBJMACROS - -#include "windef.h" -#include "winbase.h" -#include "objbase.h" -#include "wbemcli.h" - -#include "wbemprox_private.h" -#include "wine/debug.h" - -WINE_DEFAULT_DEBUG_CHANNEL(wbemprox); - -typedef HRESULT (*fnCreateInstance)( IUnknown *pUnkOuter, LPVOID *ppObj ); - -typedef struct -{ - const struct IClassFactoryVtbl *vtbl; - fnCreateInstance pfnCreateInstance; -} wbemprox_cf; - -static inline wbemprox_cf *impl_from_IClassFactory( IClassFactory *iface ) -{ - return (wbemprox_cf *)((char *)iface - FIELD_OFFSET( wbemprox_cf, vtbl )); -} - -static HRESULT WINAPI wbemprox_cf_QueryInterface( IClassFactory *iface, REFIID riid, LPVOID *ppobj ) -{ - if (IsEqualGUID(riid, &IID_IUnknown) || - IsEqualGUID(riid, &IID_IClassFactory)) - { - IClassFactory_AddRef( iface ); - *ppobj = iface; - return S_OK; - } - FIXME("interface %s not implemented\n", debugstr_guid(riid)); - return E_NOINTERFACE; -} - -static ULONG WINAPI wbemprox_cf_AddRef( IClassFactory *iface ) -{ - return 2; -} - -static ULONG WINAPI wbemprox_cf_Release( IClassFactory *iface ) -{ - return 1; -} - -static HRESULT WINAPI wbemprox_cf_CreateInstance( IClassFactory *iface, LPUNKNOWN pOuter, - REFIID riid, LPVOID *ppobj ) -{ - wbemprox_cf *This = impl_from_IClassFactory( iface ); - HRESULT r; - IUnknown *punk; - - TRACE("%p %s %p\n", pOuter, debugstr_guid(riid), ppobj); - - *ppobj = NULL; - - if (pOuter) - return CLASS_E_NOAGGREGATION; - - r = This->pfnCreateInstance( pOuter, (LPVOID *)&punk ); - if (FAILED(r)) - return r; - - r = IUnknown_QueryInterface( punk, riid, ppobj ); - if (FAILED(r)) - return r; - - IUnknown_Release( punk ); - return r; -} - -static HRESULT WINAPI wbemprox_cf_LockServer( IClassFactory *iface, BOOL dolock ) -{ - FIXME("(%p)->(%d)\n", iface, dolock); - return S_OK; -} - -static const struct IClassFactoryVtbl wbemprox_cf_vtbl = -{ - wbemprox_cf_QueryInterface, - wbemprox_cf_AddRef, - wbemprox_cf_Release, - wbemprox_cf_CreateInstance, - wbemprox_cf_LockServer -}; - -static wbemprox_cf wbem_locator_cf = { &wbemprox_cf_vtbl, WbemLocator_create }; - -BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) -{ - - switch (fdwReason) - { - case DLL_WINE_PREATTACH: - return FALSE; /* prefer native version */ - case DLL_PROCESS_ATTACH: - DisableThreadLibraryCalls(hinstDLL); - break; - case DLL_PROCESS_DETACH: - break; - } - - return TRUE; -} - -HRESULT WINAPI DllGetClassObject( REFCLSID rclsid, REFIID iid, LPVOID *ppv ) -{ - IClassFactory *cf = NULL; - - TRACE("%s %s %p\n", debugstr_guid(rclsid), debugstr_guid(iid), ppv); - - if (IsEqualGUID( rclsid, &CLSID_WbemLocator )) - { - cf = (IClassFactory *)&wbem_locator_cf.vtbl; - } - if (!cf) return CLASS_E_CLASSNOTAVAILABLE; - return IClassFactory_QueryInterface( cf, iid, ppv ); -} - -HRESULT WINAPI DllCanUnloadNow( void ) -{ - FIXME("\n"); - return S_FALSE; -} +/* + * + * Copyright 2009 Austin English + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "config.h" + +#include + +#include "windef.h" +#include "winbase.h" + +BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) +{ + + switch (fdwReason) + { + case DLL_WINE_PREATTACH: + return FALSE; /* prefer native version */ + case DLL_PROCESS_ATTACH: + DisableThreadLibraryCalls(hinstDLL); + break; + case DLL_PROCESS_DETACH: + break; + } + + return TRUE; +} diff --git a/dlls/wbemprox/regsvr.c b/dlls/wbemprox/regsvr.c deleted file mode 100644 index 60f3515a4fa..00000000000 --- a/dlls/wbemprox/regsvr.c +++ /dev/null @@ -1,424 +0,0 @@ -/* - * self-registerable dll functions for wbemprox.dll - * - * Copyright (C) 2003 John K. Hohm - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - - -#include -#include - -#include "windef.h" -#include "winbase.h" -#include "winuser.h" -#include "winreg.h" -#include "winerror.h" -#include "objbase.h" -#include "wbemcli.h" - -#include "wine/debug.h" -#include "wine/unicode.h" - -WINE_DEFAULT_DEBUG_CHANNEL(wbemprox); - -/* - * Near the bottom of this file are the exported DllRegisterServer and - * DllUnregisterServer, which make all this worthwhile. - */ - -/*********************************************************************** - * interface for self-registering - */ -struct regsvr_interface -{ - IID const *iid; /* NULL for end of list */ - LPCSTR name; /* can be NULL to omit */ - IID const *base_iid; /* can be NULL to omit */ - int num_methods; /* can be <0 to omit */ - CLSID const *ps_clsid; /* can be NULL to omit */ - CLSID const *ps_clsid32; /* can be NULL to omit */ -}; - -static HRESULT register_interfaces(struct regsvr_interface const *list); -static HRESULT unregister_interfaces(struct regsvr_interface const *list); - -struct regsvr_coclass -{ - CLSID const *clsid; /* NULL for end of list */ - LPCSTR name; /* can be NULL to omit */ - LPCSTR ips; /* can be NULL to omit */ - LPCSTR ips32; /* can be NULL to omit */ - LPCSTR ips32_tmodel; /* can be NULL to omit */ - LPCSTR clsid_str; /* can be NULL to omit */ - LPCSTR progid; /* can be NULL to omit */ -}; - -static HRESULT register_coclasses(struct regsvr_coclass const *list); -static HRESULT unregister_coclasses(struct regsvr_coclass const *list); - -/*********************************************************************** - * static string constants - */ -static WCHAR const interface_keyname[10] = { - 'I', 'n', 't', 'e', 'r', 'f', 'a', 'c', 'e', 0 }; -static WCHAR const base_ifa_keyname[14] = { - 'B', 'a', 's', 'e', 'I', 'n', 't', 'e', 'r', 'f', 'a', 'c', - 'e', 0 }; -static WCHAR const num_methods_keyname[11] = { - 'N', 'u', 'm', 'M', 'e', 't', 'h', 'o', 'd', 's', 0 }; -static WCHAR const ps_clsid_keyname[15] = { - 'P', 'r', 'o', 'x', 'y', 'S', 't', 'u', 'b', 'C', 'l', 's', - 'i', 'd', 0 }; -static WCHAR const ps_clsid32_keyname[17] = { - 'P', 'r', 'o', 'x', 'y', 'S', 't', 'u', 'b', 'C', 'l', 's', - 'i', 'd', '3', '2', 0 }; -static WCHAR const clsid_keyname[6] = { - 'C', 'L', 'S', 'I', 'D', 0 }; -static WCHAR const ips_keyname[13] = { - 'I', 'n', 'P', 'r', 'o', 'c', 'S', 'e', 'r', 'v', 'e', 'r', - 0 }; -static WCHAR const ips32_keyname[15] = { - 'I', 'n', 'P', 'r', 'o', 'c', 'S', 'e', 'r', 'v', 'e', 'r', - '3', '2', 0 }; -static WCHAR const progid_keyname[7] = { - 'P', 'r', 'o', 'g', 'I', 'D', 0 }; -static char const tmodel_valuename[] = "ThreadingModel"; - -/*********************************************************************** - * static helper functions - */ -static LONG register_key_guid(HKEY base, WCHAR const *name, GUID const *guid); -static LONG register_key_defvalueW(HKEY base, WCHAR const *name, - WCHAR const *value); -static LONG register_key_defvalueA(HKEY base, WCHAR const *name, - char const *value); - -/*********************************************************************** - * register_interfaces - */ -static HRESULT register_interfaces(struct regsvr_interface const *list) -{ - LONG res = ERROR_SUCCESS; - HKEY interface_key; - - res = RegCreateKeyExW(HKEY_CLASSES_ROOT, interface_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &interface_key, NULL); - if (res != ERROR_SUCCESS) goto error_return; - - for (; res == ERROR_SUCCESS && list->iid; ++list) { - WCHAR buf[39]; - HKEY iid_key; - - StringFromGUID2(list->iid, buf, 39); - res = RegCreateKeyExW(interface_key, buf, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &iid_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_interface_key; - - if (list->name) { - res = RegSetValueExA(iid_key, NULL, 0, REG_SZ, - (CONST BYTE*)(list->name), - strlen(list->name) + 1); - if (res != ERROR_SUCCESS) goto error_close_iid_key; - } - - if (list->base_iid) { - res = register_key_guid(iid_key, base_ifa_keyname, list->base_iid); - if (res != ERROR_SUCCESS) goto error_close_iid_key; - } - - if (0 <= list->num_methods) { - static WCHAR const fmt[3] = { '%', 'd', 0 }; - HKEY key; - - res = RegCreateKeyExW(iid_key, num_methods_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &key, NULL); - if (res != ERROR_SUCCESS) goto error_close_iid_key; - - sprintfW(buf, fmt, list->num_methods); - res = RegSetValueExW(key, NULL, 0, REG_SZ, - (CONST BYTE*)buf, - (lstrlenW(buf) + 1) * sizeof(WCHAR)); - RegCloseKey(key); - - if (res != ERROR_SUCCESS) goto error_close_iid_key; - } - - if (list->ps_clsid) { - res = register_key_guid(iid_key, ps_clsid_keyname, list->ps_clsid); - if (res != ERROR_SUCCESS) goto error_close_iid_key; - } - - if (list->ps_clsid32) { - res = register_key_guid(iid_key, ps_clsid32_keyname, list->ps_clsid32); - if (res != ERROR_SUCCESS) goto error_close_iid_key; - } - - error_close_iid_key: - RegCloseKey(iid_key); - } - -error_close_interface_key: - RegCloseKey(interface_key); -error_return: - return res != ERROR_SUCCESS ? HRESULT_FROM_WIN32(res) : S_OK; -} - -/*********************************************************************** - * unregister_interfaces - */ -static HRESULT unregister_interfaces(struct regsvr_interface const *list) -{ - LONG res = ERROR_SUCCESS; - HKEY interface_key; - - res = RegOpenKeyExW(HKEY_CLASSES_ROOT, interface_keyname, 0, - KEY_READ | KEY_WRITE, &interface_key); - if (res == ERROR_FILE_NOT_FOUND) return S_OK; - if (res != ERROR_SUCCESS) goto error_return; - - for (; res == ERROR_SUCCESS && list->iid; ++list) { - WCHAR buf[39]; - - StringFromGUID2(list->iid, buf, 39); - res = RegDeleteTreeW(interface_key, buf); - if (res == ERROR_FILE_NOT_FOUND) res = ERROR_SUCCESS; - } - - RegCloseKey(interface_key); -error_return: - return res != ERROR_SUCCESS ? HRESULT_FROM_WIN32(res) : S_OK; -} - -/*********************************************************************** - * register_coclasses - */ -static HRESULT register_coclasses(struct regsvr_coclass const *list) -{ - LONG res = ERROR_SUCCESS; - HKEY coclass_key; - - res = RegCreateKeyExW(HKEY_CLASSES_ROOT, clsid_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &coclass_key, NULL); - if (res != ERROR_SUCCESS) goto error_return; - - for (; res == ERROR_SUCCESS && list->clsid; ++list) { - WCHAR buf[39]; - HKEY clsid_key; - - StringFromGUID2(list->clsid, buf, 39); - res = RegCreateKeyExW(coclass_key, buf, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &clsid_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - - if (list->name) { - res = RegSetValueExA(clsid_key, NULL, 0, REG_SZ, - (CONST BYTE*)(list->name), - strlen(list->name) + 1); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->ips) { - res = register_key_defvalueA(clsid_key, ips_keyname, list->ips); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->ips32) { - HKEY ips32_key; - - res = RegCreateKeyExW(clsid_key, ips32_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, - &ips32_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - - res = RegSetValueExA(ips32_key, NULL, 0, REG_SZ, - (CONST BYTE*)list->ips32, - lstrlenA(list->ips32) + 1); - if (res == ERROR_SUCCESS && list->ips32_tmodel) - res = RegSetValueExA(ips32_key, tmodel_valuename, 0, REG_SZ, - (CONST BYTE*)list->ips32_tmodel, - strlen(list->ips32_tmodel) + 1); - RegCloseKey(ips32_key); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->clsid_str) { - res = register_key_defvalueA(clsid_key, clsid_keyname, - list->clsid_str); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->progid) { - HKEY progid_key; - - res = register_key_defvalueA(clsid_key, progid_keyname, - list->progid); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - - res = RegCreateKeyExA(HKEY_CLASSES_ROOT, list->progid, 0, - NULL, 0, KEY_READ | KEY_WRITE, NULL, - &progid_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - - res = register_key_defvalueW(progid_key, clsid_keyname, buf); - RegCloseKey(progid_key); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - error_close_clsid_key: - RegCloseKey(clsid_key); - } - -error_close_coclass_key: - RegCloseKey(coclass_key); -error_return: - return res != ERROR_SUCCESS ? HRESULT_FROM_WIN32(res) : S_OK; -} - -/*********************************************************************** - * unregister_coclasses - */ -static HRESULT unregister_coclasses(struct regsvr_coclass const *list) -{ - LONG res = ERROR_SUCCESS; - HKEY coclass_key; - - res = RegOpenKeyExW(HKEY_CLASSES_ROOT, clsid_keyname, 0, - KEY_READ | KEY_WRITE, &coclass_key); - if (res == ERROR_FILE_NOT_FOUND) return S_OK; - if (res != ERROR_SUCCESS) goto error_return; - - for (; res == ERROR_SUCCESS && list->clsid; ++list) { - WCHAR buf[39]; - - StringFromGUID2(list->clsid, buf, 39); - res = RegDeleteTreeW(coclass_key, buf); - if (res == ERROR_FILE_NOT_FOUND) res = ERROR_SUCCESS; - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - - if (list->progid) { - res = RegDeleteTreeA(HKEY_CLASSES_ROOT, list->progid); - if (res == ERROR_FILE_NOT_FOUND) res = ERROR_SUCCESS; - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - } - } - -error_close_coclass_key: - RegCloseKey(coclass_key); -error_return: - return res != ERROR_SUCCESS ? HRESULT_FROM_WIN32(res) : S_OK; -} - -/*********************************************************************** - * regsvr_key_guid - */ -static LONG register_key_guid(HKEY base, WCHAR const *name, GUID const *guid) -{ - WCHAR buf[39]; - - StringFromGUID2(guid, buf, 39); - return register_key_defvalueW(base, name, buf); -} - -/*********************************************************************** - * regsvr_key_defvalueW - */ -static LONG register_key_defvalueW( - HKEY base, - WCHAR const *name, - WCHAR const *value) -{ - LONG res; - HKEY key; - - res = RegCreateKeyExW(base, name, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &key, NULL); - if (res != ERROR_SUCCESS) return res; - res = RegSetValueExW(key, NULL, 0, REG_SZ, (CONST BYTE*)value, - (lstrlenW(value) + 1) * sizeof(WCHAR)); - RegCloseKey(key); - return res; -} - -/*********************************************************************** - * regsvr_key_defvalueA - */ -static LONG register_key_defvalueA( - HKEY base, - WCHAR const *name, - char const *value) -{ - LONG res; - HKEY key; - - res = RegCreateKeyExW(base, name, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &key, NULL); - if (res != ERROR_SUCCESS) return res; - res = RegSetValueExA(key, NULL, 0, REG_SZ, (CONST BYTE*)value, - lstrlenA(value) + 1); - RegCloseKey(key); - return res; -} - -/*********************************************************************** - * coclass list - */ -static struct regsvr_coclass const coclass_list[] = { - { &CLSID_WbemLocator, - "CLSID_WbemLocator", - NULL, - "wbemprox.dll", - "Both" - }, - { NULL } /* list terminator */ -}; - -/*********************************************************************** - * interface list - */ -static struct regsvr_interface const interface_list[] = { - { NULL } /* list terminator */ -}; - -/*********************************************************************** - * DllRegisterServer (INETCOMM.@) - */ -HRESULT WINAPI DllRegisterServer(void) -{ - HRESULT hr; - - TRACE("\n"); - - hr = register_coclasses(coclass_list); - if (SUCCEEDED(hr)) - hr = register_interfaces(interface_list); - return hr; -} - -/*********************************************************************** - * DllUnregisterServer (INETCOMM.@) - */ -HRESULT WINAPI DllUnregisterServer(void) -{ - HRESULT hr; - - TRACE("\n"); - - hr = unregister_coclasses(coclass_list); - if (SUCCEEDED(hr)) - hr = unregister_interfaces(interface_list); - return hr; -} diff --git a/dlls/wbemprox/wbemlocator.c b/dlls/wbemprox/wbemlocator.c deleted file mode 100644 index ad6a75d168f..00000000000 --- a/dlls/wbemprox/wbemlocator.c +++ /dev/null @@ -1,130 +0,0 @@ -/* - * Copyright 2009 Hans Leidekker for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#define COBJMACROS - -#include "config.h" -#include - -#include "windef.h" -#include "winbase.h" -#include "initguid.h" -#include "objbase.h" -#include "wbemcli.h" - -#include "wine/debug.h" -#include "wine/unicode.h" -#include "wbemprox_private.h" - -WINE_DEFAULT_DEBUG_CHANNEL(wbemprox); - -typedef struct -{ - const IWbemLocatorVtbl *vtbl; - LONG refs; -} wbem_locator; - -static inline wbem_locator *impl_from_IWbemLocator( IWbemLocator *iface ) -{ - return (wbem_locator *)((char *)iface - FIELD_OFFSET( wbem_locator, vtbl )); -} - -static ULONG WINAPI wbem_locator_AddRef( - IWbemLocator *iface ) -{ - wbem_locator *wl = impl_from_IWbemLocator( iface ); - return InterlockedIncrement( &wl->refs ); -} - -static ULONG WINAPI wbem_locator_Release( - IWbemLocator *iface ) -{ - wbem_locator *wl = impl_from_IWbemLocator( iface ); - LONG refs = InterlockedDecrement( &wl->refs ); - if (!refs) - { - TRACE("destroying %p\n", wl); - HeapFree( GetProcessHeap(), 0, wl ); - } - return refs; -} - -static HRESULT WINAPI wbem_locator_QueryInterface( - IWbemLocator *iface, - REFIID riid, - void **ppvObject ) -{ - wbem_locator *This = impl_from_IWbemLocator( iface ); - - TRACE("%p %s %p\n", This, debugstr_guid( riid ), ppvObject ); - - if ( IsEqualGUID( riid, &IID_IWbemLocator ) || - IsEqualGUID( riid, &IID_IUnknown ) ) - { - *ppvObject = iface; - } - else - { - FIXME("interface %s not implemented\n", debugstr_guid(riid)); - return E_NOINTERFACE; - } - IWbemLocator_AddRef( iface ); - return S_OK; -} - -static HRESULT WINAPI wbem_locator_ConnectServer( - IWbemLocator *iface, - const BSTR NetworkResource, - const BSTR User, - const BSTR Password, - const BSTR Locale, - LONG SecurityFlags, - const BSTR Authority, - IWbemContext *pCtx, - IWbemServices **ppNamespace) -{ - FIXME("%p, %s, %s, %s, %s, 0x%08x, %s, %p, %p)\n", iface, debugstr_w(NetworkResource), debugstr_w(User), - debugstr_w(Password), debugstr_w(Locale), SecurityFlags, debugstr_w(Authority), pCtx, ppNamespace); - return WBEM_E_FAILED; -} - -static const IWbemLocatorVtbl wbem_locator_vtbl = -{ - wbem_locator_QueryInterface, - wbem_locator_AddRef, - wbem_locator_Release, - wbem_locator_ConnectServer -}; - -HRESULT WbemLocator_create( IUnknown *pUnkOuter, LPVOID *ppObj ) -{ - wbem_locator *wl; - - TRACE("(%p,%p)\n", pUnkOuter, ppObj); - - wl = HeapAlloc( GetProcessHeap(), 0, sizeof(*wl) ); - if (!wl) return E_OUTOFMEMORY; - - wl->vtbl = &wbem_locator_vtbl; - wl->refs = 1; - - *ppObj = &wl->vtbl; - - TRACE("returning iface %p\n", *ppObj); - return S_OK; -} diff --git a/dlls/wbemprox/wbemprox.spec b/dlls/wbemprox/wbemprox.spec index b16365d0c9f..c5fc87af6d5 100644 --- a/dlls/wbemprox/wbemprox.spec +++ b/dlls/wbemprox/wbemprox.spec @@ -1,4 +1,4 @@ -@ stdcall -private DllCanUnloadNow() -@ stdcall -private DllGetClassObject(ptr ptr ptr) -@ stdcall -private DllRegisterServer() -@ stdcall -private DllUnregisterServer() +@ stub DllCanUnloadNow +@ stub DllGetClassObject +@ stub DllRegisterServer +@ stub DllUnregisterServer diff --git a/dlls/wbemprox/wbemprox_private.h b/dlls/wbemprox/wbemprox_private.h deleted file mode 100644 index cf4301dd61b..00000000000 --- a/dlls/wbemprox/wbemprox_private.h +++ /dev/null @@ -1,19 +0,0 @@ -/* - * Copyright 2009 Hans Leidekker for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -HRESULT WbemLocator_create(IUnknown *, LPVOID *); diff --git a/dlls/win32s16.dll16/Makefile.in b/dlls/win32s16.dll16/Makefile.in index 40fa726d69b..bb1bdf6b906 100644 --- a/dlls/win32s16.dll16/Makefile.in +++ b/dlls/win32s16.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = win32s16.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,w32skrnl.dll +SPEC_SRCS = win32s16.dll16.spec + C_SRCS = win32s16.c @MAKE_DLL_RULES@ diff --git a/dlls/win87em.dll16/Makefile.in b/dlls/win87em.dll16/Makefile.in index a74f4b56b81..929361d2215 100644 --- a/dlls/win87em.dll16/Makefile.in +++ b/dlls/win87em.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = win87em.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16 +SPEC_SRCS = win87em.dll16.spec + C_SRCS = win87em.c @MAKE_DLL_RULES@ diff --git a/dlls/winaspi.dll16/Makefile.in b/dlls/winaspi.dll16/Makefile.in index 2c9afcd2f6e..318e321ce8c 100644 --- a/dlls/winaspi.dll16/Makefile.in +++ b/dlls/winaspi.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = winaspi.dll16 IMPORTS = advapi32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,wnaspi32.dll +SPEC_SRCS = winaspi.dll16.spec + C_SRCS = winaspi.c @MAKE_DLL_RULES@ diff --git a/dlls/windebug.dll16/Makefile.in b/dlls/windebug.dll16/Makefile.in index 8d0777f75cb..5615a2c02a5 100644 --- a/dlls/windebug.dll16/Makefile.in +++ b/dlls/windebug.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = windebug.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16 +SPEC_SRCS = windebug.dll16.spec + C_SRCS = windebug.c @MAKE_DLL_RULES@ diff --git a/dlls/windowscodecs/Makefile.in b/dlls/windowscodecs/Makefile.in index 4de3b62673a..1449089313c 100644 --- a/dlls/windowscodecs/Makefile.in +++ b/dlls/windowscodecs/Makefile.in @@ -3,16 +3,10 @@ TOPOBJDIR = ../.. SRCDIR = @srcdir@ VPATH = @srcdir@ MODULE = windowscodecs.dll -IMPORTLIB = windowscodecs -IMPORTS = uuid ole32 advapi32 kernel32 +IMPORTS = kernel32 C_SRCS = \ - bmpdecode.c \ - clsfactory.c \ - imgfactory.c \ - main.c \ - palette.c \ - regsvr.c + main.c @MAKE_DLL_RULES@ diff --git a/dlls/windowscodecs/bmpdecode.c b/dlls/windowscodecs/bmpdecode.c deleted file mode 100644 index 0064e9dba56..00000000000 --- a/dlls/windowscodecs/bmpdecode.c +++ /dev/null @@ -1,983 +0,0 @@ -/* - * Copyright 2009 Vincent Povirk for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "config.h" - -#include - -#define COBJMACROS - -#include "windef.h" -#include "winbase.h" -#include "winreg.h" -#include "wingdi.h" -#include "objbase.h" -#include "wincodec.h" - -#include "wincodecs_private.h" - -#include "wine/debug.h" - -WINE_DEFAULT_DEBUG_CHANNEL(wincodecs); - -typedef struct { - DWORD bc2Size; - DWORD bc2Width; - DWORD bc2Height; - WORD bc2Planes; - WORD bc2BitCount; - DWORD bc2Compression; - DWORD bc2SizeImage; - DWORD bc2XRes; - DWORD bc2YRes; - DWORD bc2ClrUsed; - DWORD bc2ClrImportant; - /* same as BITMAPINFOHEADER until this point */ - WORD bc2ResUnit; - WORD bc2Reserved; - WORD bc2Orientation; - WORD bc2Halftoning; - DWORD bc2HalftoneSize1; - DWORD bc2HalftoneSize2; - DWORD bc2ColorSpace; - DWORD bc2AppData; -} BITMAPCOREHEADER2; - -struct BmpFrameDecode; -typedef HRESULT (*ReadDataFunc)(struct BmpFrameDecode* This); - -typedef struct BmpFrameDecode { - const IWICBitmapFrameDecodeVtbl *lpVtbl; - LONG ref; - IStream *stream; - BITMAPFILEHEADER bfh; - BITMAPV5HEADER bih; - const WICPixelFormatGUID *pixelformat; - int bitsperpixel; - ReadDataFunc read_data_func; - INT stride; - BYTE *imagedata; - BYTE *imagedatastart; -} BmpFrameDecode; - -static HRESULT WINAPI BmpFrameDecode_QueryInterface(IWICBitmapFrameDecode *iface, REFIID iid, - void **ppv) -{ - BmpFrameDecode *This = (BmpFrameDecode*)iface; - TRACE("(%p,%s,%p)\n", iface, debugstr_guid(iid), ppv); - - if (!ppv) return E_INVALIDARG; - - if (IsEqualIID(&IID_IUnknown, iid) || - IsEqualIID(&IID_IWICBitmapSource, iid) || - IsEqualIID(&IID_IWICBitmapFrameDecode, iid)) - { - *ppv = This; - } - else - { - *ppv = NULL; - return E_NOINTERFACE; - } - - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; -} - -static ULONG WINAPI BmpFrameDecode_AddRef(IWICBitmapFrameDecode *iface) -{ - BmpFrameDecode *This = (BmpFrameDecode*)iface; - ULONG ref = InterlockedIncrement(&This->ref); - - TRACE("(%p) refcount=%u\n", iface, ref); - - return ref; -} - -static ULONG WINAPI BmpFrameDecode_Release(IWICBitmapFrameDecode *iface) -{ - BmpFrameDecode *This = (BmpFrameDecode*)iface; - ULONG ref = InterlockedDecrement(&This->ref); - - TRACE("(%p) refcount=%u\n", iface, ref); - - if (ref == 0) - { - IStream_Release(This->stream); - HeapFree(GetProcessHeap(), 0, This->imagedata); - HeapFree(GetProcessHeap(), 0, This); - } - - return ref; -} - -static HRESULT WINAPI BmpFrameDecode_GetSize(IWICBitmapFrameDecode *iface, - UINT *puiWidth, UINT *puiHeight) -{ - BmpFrameDecode *This = (BmpFrameDecode*)iface; - TRACE("(%p,%p,%p)\n", iface, puiWidth, puiHeight); - - if (This->bih.bV5Size == sizeof(BITMAPCOREHEADER)) - { - BITMAPCOREHEADER *bch = (BITMAPCOREHEADER*)&This->bih; - *puiWidth = bch->bcWidth; - *puiHeight = bch->bcHeight; - } - else - { - *puiWidth = This->bih.bV5Width; - *puiHeight = abs(This->bih.bV5Height); - } - return S_OK; -} - -static HRESULT WINAPI BmpFrameDecode_GetPixelFormat(IWICBitmapFrameDecode *iface, - WICPixelFormatGUID *pPixelFormat) -{ - BmpFrameDecode *This = (BmpFrameDecode*)iface; - TRACE("(%p,%p)\n", iface, pPixelFormat); - - memcpy(pPixelFormat, This->pixelformat, sizeof(GUID)); - - return S_OK; -} - -static HRESULT BmpHeader_GetResolution(BITMAPV5HEADER *bih, double *pDpiX, double *pDpiY) -{ - switch (bih->bV5Size) - { - case sizeof(BITMAPCOREHEADER): - *pDpiX = 96.0; - *pDpiY = 96.0; - return S_OK; - case sizeof(BITMAPCOREHEADER2): - case sizeof(BITMAPINFOHEADER): - case sizeof(BITMAPV4HEADER): - case sizeof(BITMAPV5HEADER): - *pDpiX = bih->bV5XPelsPerMeter * 0.0254; - *pDpiY = bih->bV5YPelsPerMeter * 0.0254; - return S_OK; - default: - return E_FAIL; - } -} - -static HRESULT WINAPI BmpFrameDecode_GetResolution(IWICBitmapFrameDecode *iface, - double *pDpiX, double *pDpiY) -{ - BmpFrameDecode *This = (BmpFrameDecode*)iface; - TRACE("(%p,%p,%p)\n", iface, pDpiX, pDpiY); - - return BmpHeader_GetResolution(&This->bih, pDpiX, pDpiY); -} - -static HRESULT WINAPI BmpFrameDecode_CopyPalette(IWICBitmapFrameDecode *iface, - IWICPalette *pIPalette) -{ - HRESULT hr; - BmpFrameDecode *This = (BmpFrameDecode*)iface; - int count; - WICColor *wiccolors=NULL; - RGBTRIPLE *bgrcolors=NULL; - - TRACE("(%p,%p)\n", iface, pIPalette); - - if (This->bih.bV5Size == sizeof(BITMAPCOREHEADER)) - { - BITMAPCOREHEADER *bch = (BITMAPCOREHEADER*)&This->bih; - if (bch->bcBitCount <= 8) - { - /* 2**n colors in BGR format after the header */ - ULONG tablesize, bytesread; - LARGE_INTEGER offset; - int i; - - count = 1 << bch->bcBitCount; - wiccolors = HeapAlloc(GetProcessHeap(), 0, sizeof(WICColor) * count); - tablesize = sizeof(RGBTRIPLE) * count; - bgrcolors = HeapAlloc(GetProcessHeap(), 0, tablesize); - if (!wiccolors || !bgrcolors) - { - hr = E_OUTOFMEMORY; - goto end; - } - - offset.QuadPart = sizeof(BITMAPFILEHEADER)+sizeof(BITMAPCOREHEADER); - hr = IStream_Seek(This->stream, offset, STREAM_SEEK_SET, NULL); - if (FAILED(hr)) goto end; - - hr = IStream_Read(This->stream, bgrcolors, tablesize, &bytesread); - if (FAILED(hr)) goto end; - if (bytesread != tablesize) { - hr = E_FAIL; - goto end; - } - - for (i=0; ibih.bV5BitCount <= 8) - { - ULONG tablesize, bytesread; - LARGE_INTEGER offset; - int i; - - if (This->bih.bV5ClrUsed == 0) - count = 1 << This->bih.bV5BitCount; - else - count = This->bih.bV5ClrUsed; - - tablesize = sizeof(WICColor) * count; - wiccolors = HeapAlloc(GetProcessHeap(), 0, tablesize); - if (!wiccolors) return E_OUTOFMEMORY; - - offset.QuadPart = sizeof(BITMAPFILEHEADER) + This->bih.bV5Size; - hr = IStream_Seek(This->stream, offset, STREAM_SEEK_SET, NULL); - if (FAILED(hr)) goto end; - - hr = IStream_Read(This->stream, wiccolors, tablesize, &bytesread); - if (FAILED(hr)) goto end; - if (bytesread != tablesize) { - hr = E_FAIL; - goto end; - } - - /* convert from BGR to BGRA by setting alpha to 100% */ - for (i=0; iimagedata) - { - hr = This->read_data_func(This); - if (FAILED(hr)) return hr; - } - - hr = BmpFrameDecode_GetSize(iface, &width, &height); - if (FAILED(hr)) return hr; - - return copy_pixels(This->bitsperpixel, This->imagedatastart, - width, height, This->stride, - prc, cbStride, cbBufferSize, pbBuffer); -} - -static HRESULT WINAPI BmpFrameDecode_GetMetadataQueryReader(IWICBitmapFrameDecode *iface, - IWICMetadataQueryReader **ppIMetadataQueryReader) -{ - TRACE("(%p,%p)\n", iface, ppIMetadataQueryReader); - return WINCODEC_ERR_UNSUPPORTEDOPERATION; -} - -static HRESULT WINAPI BmpFrameDecode_GetColorContexts(IWICBitmapFrameDecode *iface, - UINT cCount, IWICColorContext **ppIColorContexts, UINT *pcActualCount) -{ - TRACE("(%p,%u,%p,%p)\n", iface, cCount, ppIColorContexts, pcActualCount); - return WINCODEC_ERR_UNSUPPORTEDOPERATION; -} - -static HRESULT WINAPI BmpFrameDecode_GetThumbnail(IWICBitmapFrameDecode *iface, - IWICBitmapSource **ppIThumbnail) -{ - TRACE("(%p,%p)\n", iface, ppIThumbnail); - return WINCODEC_ERR_CODECNOTHUMBNAIL; -} - -static HRESULT BmpFrameDecode_ReadUncompressed(BmpFrameDecode* This) -{ - UINT bytesperrow; - UINT width, height; - UINT datasize; - int bottomup; - HRESULT hr; - LARGE_INTEGER offbits; - ULONG bytesread; - - if (This->bih.bV5Size == sizeof(BITMAPCOREHEADER)) - { - BITMAPCOREHEADER *bch = (BITMAPCOREHEADER*)&This->bih; - width = bch->bcWidth; - height = bch->bcHeight; - bottomup = 1; - } - else - { - width = This->bih.bV5Width; - height = abs(This->bih.bV5Height); - bottomup = (This->bih.bV5Height > 0); - } - - /* row sizes in BMP files must be divisible by 4 bytes */ - bytesperrow = (((width * This->bitsperpixel)+31)/32)*4; - datasize = bytesperrow * height; - - This->imagedata = HeapAlloc(GetProcessHeap(), 0, datasize); - if (!This->imagedata) return E_OUTOFMEMORY; - - offbits.QuadPart = This->bfh.bfOffBits; - hr = IStream_Seek(This->stream, offbits, STREAM_SEEK_SET, NULL); - if (FAILED(hr)) goto fail; - - hr = IStream_Read(This->stream, This->imagedata, datasize, &bytesread); - if (FAILED(hr) || bytesread != datasize) goto fail; - - if (bottomup) - { - This->imagedatastart = This->imagedata + (height-1) * bytesperrow; - This->stride = -bytesperrow; - } - else - { - This->imagedatastart = This->imagedata; - This->stride = bytesperrow; - } - return S_OK; - -fail: - HeapFree(GetProcessHeap(), 0, This->imagedata); - This->imagedata = NULL; - if (SUCCEEDED(hr)) hr = E_FAIL; - return hr; -} - -static HRESULT BmpFrameDecode_ReadRLE8(BmpFrameDecode* This) -{ - UINT bytesperrow; - UINT width, height; - BYTE *rledata, *cursor, *rledataend; - UINT rlesize, datasize, palettesize; - DWORD palette[256]; - UINT x, y; - DWORD *bgrdata; - HRESULT hr; - LARGE_INTEGER offbits; - ULONG bytesread; - - width = This->bih.bV5Width; - height = abs(This->bih.bV5Height); - bytesperrow = width * 4; - datasize = bytesperrow * height; - rlesize = This->bih.bV5SizeImage; - if (This->bih.bV5ClrUsed && This->bih.bV5ClrUsed < 256) - palettesize = 4 * This->bih.bV5ClrUsed; - else - palettesize = 4 * 256; - - rledata = HeapAlloc(GetProcessHeap(), 0, rlesize); - This->imagedata = HeapAlloc(GetProcessHeap(), 0, datasize); - if (!This->imagedata || !rledata) - { - hr = E_OUTOFMEMORY; - goto fail; - } - - /* read palette */ - offbits.QuadPart = sizeof(BITMAPFILEHEADER) + This->bih.bV5Size; - hr = IStream_Seek(This->stream, offbits, STREAM_SEEK_SET, NULL); - if (FAILED(hr)) goto fail; - - hr = IStream_Read(This->stream, palette, palettesize, &bytesread); - if (FAILED(hr) || bytesread != palettesize) goto fail; - - /* read RLE data */ - offbits.QuadPart = This->bfh.bfOffBits; - hr = IStream_Seek(This->stream, offbits, STREAM_SEEK_SET, NULL); - if (FAILED(hr)) goto fail; - - hr = IStream_Read(This->stream, rledata, rlesize, &bytesread); - if (FAILED(hr) || bytesread != rlesize) goto fail; - - /* decode RLE */ - bgrdata = (DWORD*)This->imagedata; - x = 0; - y = 0; - rledataend = rledata + rlesize; - cursor = rledata; - while (cursor < rledataend && y < height) - { - BYTE length = *cursor++; - if (length == 0) - { - /* escape code */ - BYTE escape = *cursor++; - switch(escape) - { - case 0: /* end of line */ - x = 0; - y++; - break; - case 1: /* end of bitmap */ - goto end; - case 2: /* delta */ - if (cursor < rledataend) - { - x += *cursor++; - y += *cursor++; - } - break; - default: /* absolute mode */ - length = escape; - while (cursor < rledataend && length-- && x < width) - bgrdata[y*width + x++] = palette[*cursor++]; - if (escape & 1) cursor++; /* skip pad byte */ - } - } - else - { - DWORD color = palette[*cursor++]; - while (length-- && x < width) - bgrdata[y*width + x++] = color; - } - } - -end: - HeapFree(GetProcessHeap(), 0, rledata); - - This->imagedatastart = This->imagedata + (height-1) * bytesperrow; - This->stride = -bytesperrow; - - return S_OK; - -fail: - HeapFree(GetProcessHeap(), 0, rledata); - HeapFree(GetProcessHeap(), 0, This->imagedata); - This->imagedata = NULL; - if (SUCCEEDED(hr)) hr = E_FAIL; - return hr; -} - -static HRESULT BmpFrameDecode_ReadRLE4(BmpFrameDecode* This) -{ - UINT bytesperrow; - UINT width, height; - BYTE *rledata, *cursor, *rledataend; - UINT rlesize, datasize, palettesize; - DWORD palette[16]; - UINT x, y; - DWORD *bgrdata; - HRESULT hr; - LARGE_INTEGER offbits; - ULONG bytesread; - - width = This->bih.bV5Width; - height = abs(This->bih.bV5Height); - bytesperrow = width * 4; - datasize = bytesperrow * height; - rlesize = This->bih.bV5SizeImage; - if (This->bih.bV5ClrUsed && This->bih.bV5ClrUsed < 16) - palettesize = 4 * This->bih.bV5ClrUsed; - else - palettesize = 4 * 16; - - rledata = HeapAlloc(GetProcessHeap(), 0, rlesize); - This->imagedata = HeapAlloc(GetProcessHeap(), 0, datasize); - if (!This->imagedata || !rledata) - { - hr = E_OUTOFMEMORY; - goto fail; - } - - /* read palette */ - offbits.QuadPart = sizeof(BITMAPFILEHEADER) + This->bih.bV5Size; - hr = IStream_Seek(This->stream, offbits, STREAM_SEEK_SET, NULL); - if (FAILED(hr)) goto fail; - - hr = IStream_Read(This->stream, palette, palettesize, &bytesread); - if (FAILED(hr) || bytesread != palettesize) goto fail; - - /* read RLE data */ - offbits.QuadPart = This->bfh.bfOffBits; - hr = IStream_Seek(This->stream, offbits, STREAM_SEEK_SET, NULL); - if (FAILED(hr)) goto fail; - - hr = IStream_Read(This->stream, rledata, rlesize, &bytesread); - if (FAILED(hr) || bytesread != rlesize) goto fail; - - /* decode RLE */ - bgrdata = (DWORD*)This->imagedata; - x = 0; - y = 0; - rledataend = rledata + rlesize; - cursor = rledata; - while (cursor < rledataend && y < height) - { - BYTE length = *cursor++; - if (length == 0) - { - /* escape code */ - BYTE escape = *cursor++; - switch(escape) - { - case 0: /* end of line */ - x = 0; - y++; - break; - case 1: /* end of bitmap */ - goto end; - case 2: /* delta */ - if (cursor < rledataend) - { - x += *cursor++; - y += *cursor++; - } - break; - default: /* absolute mode */ - length = escape; - while (cursor < rledataend && length-- && x < width) - { - BYTE colors = *cursor++; - bgrdata[y*width + x++] = palette[colors>>4]; - if (length-- && x < width) - bgrdata[y*width + x++] = palette[colors&0xf]; - else - break; - } - if ((cursor - rledata) & 1) cursor++; /* skip pad byte */ - } - } - else - { - BYTE colors = *cursor++; - DWORD color1 = palette[colors>>4]; - DWORD color2 = palette[colors&0xf]; - while (length-- && x < width) - { - bgrdata[y*width + x++] = color1; - if (length-- && x < width) - bgrdata[y*width + x++] = color2; - else - break; - } - } - } - -end: - HeapFree(GetProcessHeap(), 0, rledata); - - This->imagedatastart = This->imagedata + (height-1) * bytesperrow; - This->stride = -bytesperrow; - - return S_OK; - -fail: - HeapFree(GetProcessHeap(), 0, rledata); - HeapFree(GetProcessHeap(), 0, This->imagedata); - This->imagedata = NULL; - if (SUCCEEDED(hr)) hr = E_FAIL; - return hr; -} - -static HRESULT BmpFrameDecode_ReadUnsupported(BmpFrameDecode* This) -{ - return E_FAIL; -} - -static const IWICBitmapFrameDecodeVtbl BmpFrameDecode_Vtbl = { - BmpFrameDecode_QueryInterface, - BmpFrameDecode_AddRef, - BmpFrameDecode_Release, - BmpFrameDecode_GetSize, - BmpFrameDecode_GetPixelFormat, - BmpFrameDecode_GetResolution, - BmpFrameDecode_CopyPalette, - BmpFrameDecode_CopyPixels, - BmpFrameDecode_GetMetadataQueryReader, - BmpFrameDecode_GetColorContexts, - BmpFrameDecode_GetThumbnail -}; - -typedef struct { - const IWICBitmapDecoderVtbl *lpVtbl; - LONG ref; - BOOL initialized; - IStream *stream; - BITMAPFILEHEADER bfh; - BITMAPV5HEADER bih; - BmpFrameDecode *framedecode; - const WICPixelFormatGUID *pixelformat; - int bitsperpixel; - ReadDataFunc read_data_func; -} BmpDecoder; - -static HRESULT BmpDecoder_ReadHeaders(BmpDecoder* This, IStream *stream) -{ - HRESULT hr; - ULONG bytestoread, bytesread; - LARGE_INTEGER seek; - - if (This->initialized) return WINCODEC_ERR_WRONGSTATE; - - seek.QuadPart = 0; - hr = IStream_Seek(stream, seek, STREAM_SEEK_SET, NULL); - if (FAILED(hr)) return hr; - - hr = IStream_Read(stream, &This->bfh, sizeof(BITMAPFILEHEADER), &bytesread); - if (FAILED(hr)) return hr; - if (bytesread != sizeof(BITMAPFILEHEADER) || - This->bfh.bfType != 0x4d42 /* "BM" */) return E_FAIL; - - hr = IStream_Read(stream, &This->bih.bV5Size, sizeof(DWORD), &bytesread); - if (FAILED(hr)) return hr; - if (bytesread != sizeof(DWORD) || - (This->bih.bV5Size != sizeof(BITMAPCOREHEADER) && - This->bih.bV5Size != sizeof(BITMAPCOREHEADER2) && - This->bih.bV5Size != sizeof(BITMAPINFOHEADER) && - This->bih.bV5Size != sizeof(BITMAPV4HEADER) && - This->bih.bV5Size != sizeof(BITMAPV5HEADER))) return E_FAIL; - - bytestoread = This->bih.bV5Size-sizeof(DWORD); - hr = IStream_Read(stream, &This->bih.bV5Width, bytestoread, &bytesread); - if (FAILED(hr)) return hr; - if (bytestoread != bytesread) return E_FAIL; - - /* decide what kind of bitmap this is and how/if we can read it */ - if (This->bih.bV5Size == sizeof(BITMAPCOREHEADER)) - { - BITMAPCOREHEADER *bch = (BITMAPCOREHEADER*)&This->bih; - TRACE("BITMAPCOREHEADER with depth=%i\n", bch->bcBitCount); - This->bitsperpixel = bch->bcBitCount; - This->read_data_func = BmpFrameDecode_ReadUncompressed; - switch(bch->bcBitCount) - { - case 1: - This->pixelformat = &GUID_WICPixelFormat1bppIndexed; - break; - case 2: - This->pixelformat = &GUID_WICPixelFormat2bppIndexed; - break; - case 4: - This->pixelformat = &GUID_WICPixelFormat4bppIndexed; - break; - case 8: - This->pixelformat = &GUID_WICPixelFormat8bppIndexed; - break; - case 24: - This->pixelformat = &GUID_WICPixelFormat24bppBGR; - break; - default: - This->pixelformat = &GUID_WICPixelFormatUndefined; - WARN("unsupported bit depth %i for BITMAPCOREHEADER\n", bch->bcBitCount); - break; - } - } - else /* struct is compatible with BITMAPINFOHEADER */ - { - TRACE("bitmap header=%i compression=%i depth=%i\n", This->bih.bV5Size, This->bih.bV5Compression, This->bih.bV5BitCount); - switch(This->bih.bV5Compression) - { - case BI_RGB: - This->bitsperpixel = This->bih.bV5BitCount; - This->read_data_func = BmpFrameDecode_ReadUncompressed; - switch(This->bih.bV5BitCount) - { - case 1: - This->pixelformat = &GUID_WICPixelFormat1bppIndexed; - break; - case 2: - This->pixelformat = &GUID_WICPixelFormat2bppIndexed; - break; - case 4: - This->pixelformat = &GUID_WICPixelFormat4bppIndexed; - break; - case 8: - This->pixelformat = &GUID_WICPixelFormat8bppIndexed; - break; - case 16: - This->pixelformat = &GUID_WICPixelFormat16bppBGR555; - break; - case 24: - This->pixelformat = &GUID_WICPixelFormat24bppBGR; - break; - case 32: - This->pixelformat = &GUID_WICPixelFormat32bppBGR; - break; - default: - This->pixelformat = &GUID_WICPixelFormatUndefined; - FIXME("unsupported bit depth %i for uncompressed RGB\n", This->bih.bV5BitCount); - } - break; - case BI_RLE8: - This->bitsperpixel = 32; - This->read_data_func = BmpFrameDecode_ReadRLE8; - This->pixelformat = &GUID_WICPixelFormat32bppBGR; - break; - case BI_RLE4: - This->bitsperpixel = 32; - This->read_data_func = BmpFrameDecode_ReadRLE4; - This->pixelformat = &GUID_WICPixelFormat32bppBGR; - break; - default: - This->bitsperpixel = 0; - This->read_data_func = BmpFrameDecode_ReadUnsupported; - This->pixelformat = &GUID_WICPixelFormatUndefined; - FIXME("unsupported bitmap type header=%i compression=%i depth=%i\n", This->bih.bV5Size, This->bih.bV5Compression, This->bih.bV5BitCount); - break; - } - } - - This->initialized = TRUE; - - return S_OK; -} - -static HRESULT WINAPI BmpDecoder_QueryInterface(IWICBitmapDecoder *iface, REFIID iid, - void **ppv) -{ - BmpDecoder *This = (BmpDecoder*)iface; - TRACE("(%p,%s,%p)\n", iface, debugstr_guid(iid), ppv); - - if (!ppv) return E_INVALIDARG; - - if (IsEqualIID(&IID_IUnknown, iid) || IsEqualIID(&IID_IWICBitmapDecoder, iid)) - { - *ppv = This; - } - else - { - *ppv = NULL; - return E_NOINTERFACE; - } - - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; -} - -static ULONG WINAPI BmpDecoder_AddRef(IWICBitmapDecoder *iface) -{ - BmpDecoder *This = (BmpDecoder*)iface; - ULONG ref = InterlockedIncrement(&This->ref); - - TRACE("(%p) refcount=%u\n", iface, ref); - - return ref; -} - -static ULONG WINAPI BmpDecoder_Release(IWICBitmapDecoder *iface) -{ - BmpDecoder *This = (BmpDecoder*)iface; - ULONG ref = InterlockedDecrement(&This->ref); - - TRACE("(%p) refcount=%u\n", iface, ref); - - if (ref == 0) - { - if (This->stream) IStream_Release(This->stream); - if (This->framedecode) IUnknown_Release((IUnknown*)This->framedecode); - HeapFree(GetProcessHeap(), 0, This); - } - - return ref; -} - -static HRESULT WINAPI BmpDecoder_QueryCapability(IWICBitmapDecoder *iface, IStream *pIStream, - DWORD *pdwCapability) -{ - HRESULT hr; - BmpDecoder *This = (BmpDecoder*)iface; - - hr = BmpDecoder_ReadHeaders(This, pIStream); - if (FAILED(hr)) return hr; - - if (This->read_data_func == BmpFrameDecode_ReadUnsupported) - *pdwCapability = 0; - else - *pdwCapability = WICBitmapDecoderCapabilityCanDecodeAllImages; - - return S_OK; -} - -static HRESULT WINAPI BmpDecoder_Initialize(IWICBitmapDecoder *iface, IStream *pIStream, - WICDecodeOptions cacheOptions) -{ - HRESULT hr; - BmpDecoder *This = (BmpDecoder*)iface; - - hr = BmpDecoder_ReadHeaders(This, pIStream); - - if (SUCCEEDED(hr)) - { - This->stream = pIStream; - IStream_AddRef(pIStream); - } - - return hr; -} - -static HRESULT WINAPI BmpDecoder_GetContainerFormat(IWICBitmapDecoder *iface, - GUID *pguidContainerFormat) -{ - memcpy(pguidContainerFormat, &GUID_ContainerFormatBmp, sizeof(GUID)); - return S_OK; -} - -static HRESULT WINAPI BmpDecoder_GetDecoderInfo(IWICBitmapDecoder *iface, - IWICBitmapDecoderInfo **ppIDecoderInfo) -{ - FIXME("(%p,%p): stub\n", iface, ppIDecoderInfo); - return E_NOTIMPL; -} - -static HRESULT WINAPI BmpDecoder_CopyPalette(IWICBitmapDecoder *iface, - IWICPalette *pIPalette) -{ - TRACE("(%p,%p)\n", iface, pIPalette); - - return WINCODEC_ERR_PALETTEUNAVAILABLE; -} - -static HRESULT WINAPI BmpDecoder_GetMetadataQueryReader(IWICBitmapDecoder *iface, - IWICMetadataQueryReader **ppIMetadataQueryReader) -{ - TRACE("(%p,%p)\n", iface, ppIMetadataQueryReader); - return WINCODEC_ERR_UNSUPPORTEDOPERATION; -} - -static HRESULT WINAPI BmpDecoder_GetPreview(IWICBitmapDecoder *iface, - IWICBitmapSource **ppIBitmapSource) -{ - TRACE("(%p,%p)\n", iface, ppIBitmapSource); - return WINCODEC_ERR_UNSUPPORTEDOPERATION; -} - -static HRESULT WINAPI BmpDecoder_GetColorContexts(IWICBitmapDecoder *iface, - UINT cCount, IWICColorContext **ppIColorContexts, UINT *pcActualCount) -{ - TRACE("(%p,%u,%p,%p)\n", iface, cCount, ppIColorContexts, pcActualCount); - return WINCODEC_ERR_UNSUPPORTEDOPERATION; -} - -static HRESULT WINAPI BmpDecoder_GetThumbnail(IWICBitmapDecoder *iface, - IWICBitmapSource **ppIThumbnail) -{ - TRACE("(%p,%p)\n", iface, ppIThumbnail); - return WINCODEC_ERR_CODECNOTHUMBNAIL; -} - -static HRESULT WINAPI BmpDecoder_GetFrameCount(IWICBitmapDecoder *iface, - UINT *pCount) -{ - *pCount = 1; - return S_OK; -} - -static HRESULT WINAPI BmpDecoder_GetFrame(IWICBitmapDecoder *iface, - UINT index, IWICBitmapFrameDecode **ppIBitmapFrame) -{ - BmpDecoder *This = (BmpDecoder*)iface; - - if (index != 0) return E_INVALIDARG; - - if (!This->stream) return WINCODEC_ERR_WRONGSTATE; - - if (!This->framedecode) - { - This->framedecode = HeapAlloc(GetProcessHeap(), 0, sizeof(BmpFrameDecode)); - if (!This->framedecode) return E_OUTOFMEMORY; - - This->framedecode->lpVtbl = &BmpFrameDecode_Vtbl; - This->framedecode->ref = 1; - This->framedecode->stream = This->stream; - IStream_AddRef(This->stream); - This->framedecode->bfh = This->bfh; - This->framedecode->bih = This->bih; - This->framedecode->pixelformat = This->pixelformat; - This->framedecode->bitsperpixel = This->bitsperpixel; - This->framedecode->read_data_func = This->read_data_func; - This->framedecode->imagedata = NULL; - } - - *ppIBitmapFrame = (IWICBitmapFrameDecode*)This->framedecode; - IWICBitmapFrameDecode_AddRef((IWICBitmapFrameDecode*)This->framedecode); - - return S_OK; -} - -static const IWICBitmapDecoderVtbl BmpDecoder_Vtbl = { - BmpDecoder_QueryInterface, - BmpDecoder_AddRef, - BmpDecoder_Release, - BmpDecoder_QueryCapability, - BmpDecoder_Initialize, - BmpDecoder_GetContainerFormat, - BmpDecoder_GetDecoderInfo, - BmpDecoder_CopyPalette, - BmpDecoder_GetMetadataQueryReader, - BmpDecoder_GetPreview, - BmpDecoder_GetColorContexts, - BmpDecoder_GetThumbnail, - BmpDecoder_GetFrameCount, - BmpDecoder_GetFrame -}; - -HRESULT BmpDecoder_CreateInstance(IUnknown *pUnkOuter, REFIID iid, void** ppv) -{ - BmpDecoder *This; - HRESULT ret; - - TRACE("(%p,%s,%p)\n", pUnkOuter, debugstr_guid(iid), ppv); - - *ppv = NULL; - - if (pUnkOuter) return CLASS_E_NOAGGREGATION; - - This = HeapAlloc(GetProcessHeap(), 0, sizeof(BmpDecoder)); - if (!This) return E_OUTOFMEMORY; - - This->lpVtbl = &BmpDecoder_Vtbl; - This->ref = 1; - This->initialized = FALSE; - This->stream = NULL; - This->framedecode = NULL; - - ret = IUnknown_QueryInterface((IUnknown*)This, iid, ppv); - IUnknown_Release((IUnknown*)This); - - return ret; -} diff --git a/dlls/windowscodecs/clsfactory.c b/dlls/windowscodecs/clsfactory.c deleted file mode 100644 index 37e30e590a8..00000000000 --- a/dlls/windowscodecs/clsfactory.c +++ /dev/null @@ -1,171 +0,0 @@ -/* - * Copyright 2009 Vincent Povirk for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "config.h" - -#include - -#define COBJMACROS - -#include "windef.h" -#include "winbase.h" -#include "winreg.h" -#include "objbase.h" -#include "ocidl.h" -#include "initguid.h" -#include "wincodec.h" - -#include "wincodecs_private.h" - -#include "wine/debug.h" - -WINE_DEFAULT_DEBUG_CHANNEL(wincodecs); - -typedef struct { - REFCLSID classid; - HRESULT (*constructor)(IUnknown*,REFIID,void**); -} classinfo; - -static classinfo wic_classes[] = { - {&CLSID_WICImagingFactory, ImagingFactory_CreateInstance}, - {&CLSID_WICBmpDecoder, BmpDecoder_CreateInstance}, - {0}}; - -typedef struct { - const IClassFactoryVtbl *lpIClassFactoryVtbl; - LONG ref; - classinfo *info; -} ClassFactoryImpl; - -static HRESULT WINAPI ClassFactoryImpl_QueryInterface(IClassFactory *iface, - REFIID iid, void **ppv) -{ - ClassFactoryImpl *This = (ClassFactoryImpl*)iface; - TRACE("(%p,%s,%p)\n", iface, debugstr_guid(iid), ppv); - - if (!ppv) return E_INVALIDARG; - - if (IsEqualIID(&IID_IUnknown, iid) || IsEqualIID(&IID_IClassFactory, iid)) - { - *ppv = This; - } - else - { - *ppv = NULL; - return E_NOINTERFACE; - } - - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; -} - -static ULONG WINAPI ClassFactoryImpl_AddRef(IClassFactory *iface) -{ - ClassFactoryImpl *This = (ClassFactoryImpl*)iface; - ULONG ref = InterlockedIncrement(&This->ref); - - TRACE("(%p) refcount=%u\n", iface, ref); - - return ref; -} - -static ULONG WINAPI ClassFactoryImpl_Release(IClassFactory *iface) -{ - ClassFactoryImpl *This = (ClassFactoryImpl*)iface; - ULONG ref = InterlockedDecrement(&This->ref); - - TRACE("(%p) refcount=%u\n", iface, ref); - - if (ref == 0) - HeapFree(GetProcessHeap(), 0, This); - - return ref; -} - -static HRESULT WINAPI ClassFactoryImpl_CreateInstance(IClassFactory *iface, - IUnknown *pUnkOuter, REFIID riid, void **ppv) -{ - ClassFactoryImpl *This = (ClassFactoryImpl*)iface; - - return This->info->constructor(pUnkOuter, riid, ppv); -} - -static HRESULT WINAPI ClassFactoryImpl_LockServer(IClassFactory *iface, BOOL lock) -{ - TRACE("(%p, %i): stub\n", iface, lock); - return E_NOTIMPL; -} - -static const IClassFactoryVtbl ClassFactoryImpl_Vtbl = { - ClassFactoryImpl_QueryInterface, - ClassFactoryImpl_AddRef, - ClassFactoryImpl_Release, - ClassFactoryImpl_CreateInstance, - ClassFactoryImpl_LockServer -}; - -static HRESULT ClassFactoryImpl_Constructor(classinfo *info, REFIID riid, LPVOID *ppv) -{ - ClassFactoryImpl *This; - HRESULT ret; - - *ppv = NULL; - - This = HeapAlloc(GetProcessHeap(), 0, sizeof(ClassFactoryImpl)); - if (!This) return E_OUTOFMEMORY; - - This->lpIClassFactoryVtbl = &ClassFactoryImpl_Vtbl; - This->ref = 1; - This->info = info; - - ret = IClassFactory_QueryInterface((IClassFactory*)This, riid, ppv); - IClassFactory_Release((IClassFactory*)This); - - return ret; -} - -HRESULT WINAPI DllGetClassObject(REFCLSID rclsid, REFIID iid, LPVOID *ppv) -{ - HRESULT ret; - classinfo *info=NULL; - int i; - - TRACE("(%s,%s,%p)\n", debugstr_guid(rclsid), debugstr_guid(iid), ppv); - - if (!rclsid || !iid || !ppv) - return E_INVALIDARG; - - *ppv = NULL; - - for (i=0; wic_classes[i].classid; i++) - { - if (IsEqualCLSID(wic_classes[i].classid, rclsid)) - { - info = &wic_classes[i]; - break; - } - } - - if (info) - ret = ClassFactoryImpl_Constructor(info, iid, ppv); - else - ret = CLASS_E_CLASSNOTAVAILABLE; - - TRACE("<-- %08X\n", ret); - return ret; -} diff --git a/dlls/windowscodecs/imgfactory.c b/dlls/windowscodecs/imgfactory.c deleted file mode 100644 index b727d1616a4..00000000000 --- a/dlls/windowscodecs/imgfactory.c +++ /dev/null @@ -1,339 +0,0 @@ -/* - * Copyright 2009 Vincent Povirk for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "config.h" - -#include - -#define COBJMACROS - -#include "windef.h" -#include "winbase.h" -#include "winreg.h" -#include "objbase.h" -#include "wincodec.h" - -#include "wincodecs_private.h" - -#include "wine/debug.h" - -WINE_DEFAULT_DEBUG_CHANNEL(wincodecs); - -typedef struct { - const IWICImagingFactoryVtbl *lpIWICImagingFactoryVtbl; - LONG ref; -} ImagingFactory; - -static HRESULT WINAPI ImagingFactory_QueryInterface(IWICImagingFactory *iface, REFIID iid, - void **ppv) -{ - ImagingFactory *This = (ImagingFactory*)iface; - TRACE("(%p,%s,%p)\n", iface, debugstr_guid(iid), ppv); - - if (!ppv) return E_INVALIDARG; - - if (IsEqualIID(&IID_IUnknown, iid) || IsEqualIID(&IID_IWICImagingFactory, iid)) - { - *ppv = This; - } - else - { - *ppv = NULL; - return E_NOINTERFACE; - } - - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; -} - -static ULONG WINAPI ImagingFactory_AddRef(IWICImagingFactory *iface) -{ - ImagingFactory *This = (ImagingFactory*)iface; - ULONG ref = InterlockedIncrement(&This->ref); - - TRACE("(%p) refcount=%u\n", iface, ref); - - return ref; -} - -static ULONG WINAPI ImagingFactory_Release(IWICImagingFactory *iface) -{ - ImagingFactory *This = (ImagingFactory*)iface; - ULONG ref = InterlockedDecrement(&This->ref); - - TRACE("(%p) refcount=%u\n", iface, ref); - - if (ref == 0) - HeapFree(GetProcessHeap(), 0, This); - - return ref; -} - -static HRESULT WINAPI ImagingFactory_CreateDecoderFromFilename( - IWICImagingFactory *iface, LPCWSTR wzFilename, const GUID *pguidVendor, - DWORD dwDesiredAccess, WICDecodeOptions metadataOptions, - IWICBitmapDecoder **ppIDecoder) -{ - FIXME("(%p,%s,%s,%u,%u,%p): stub\n", iface, debugstr_w(wzFilename), - debugstr_guid(pguidVendor), dwDesiredAccess, metadataOptions, ppIDecoder); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateDecoderFromStream( - IWICImagingFactory *iface, IStream *pIStream, const GUID *pguidVendor, - WICDecodeOptions metadataOptions, IWICBitmapDecoder **ppIDecoder) -{ - FIXME("(%p,%p,%s,%u,%p): stub\n", iface, pIStream, debugstr_guid(pguidVendor), - metadataOptions, ppIDecoder); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateDecoderFromFileHandle( - IWICImagingFactory *iface, ULONG_PTR hFile, const GUID *pguidVendor, - WICDecodeOptions metadataOptions, IWICBitmapDecoder **ppIDecoder) -{ - FIXME("(%p,%lx,%s,%u,%p): stub\n", iface, hFile, debugstr_guid(pguidVendor), - metadataOptions, ppIDecoder); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateComponentInfo(IWICImagingFactory *iface, - REFCLSID clsidComponent, IWICComponentInfo **ppIInfo) -{ - FIXME("(%p,%s,%p): stub\n", iface, debugstr_guid(clsidComponent), ppIInfo); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateDecoder(IWICImagingFactory *iface, - REFGUID guidContainerFormat, const GUID *pguidVendor, - IWICBitmapDecoder **ppIDecoder) -{ - FIXME("(%p,%s,%s,%p): stub\n", iface, debugstr_guid(guidContainerFormat), - debugstr_guid(pguidVendor), ppIDecoder); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateEncoder(IWICImagingFactory *iface, - REFGUID guidContainerFormat, const GUID *pguidVendor, - IWICBitmapEncoder **ppIEncoder) -{ - FIXME("(%p,%s,%s,%p): stub\n", iface, debugstr_guid(guidContainerFormat), - debugstr_guid(pguidVendor), ppIEncoder); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreatePalette(IWICImagingFactory *iface, - IWICPalette **ppIPalette) -{ - TRACE("(%p,%p)\n", iface, ppIPalette); - return PaletteImpl_Create(ppIPalette); -} - -static HRESULT WINAPI ImagingFactory_CreateFormatConverter(IWICImagingFactory *iface, - IWICFormatConverter **ppIFormatConverter) -{ - FIXME("(%p,%p): stub\n", iface, ppIFormatConverter); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateBitmapScaler(IWICImagingFactory *iface, - IWICBitmapScaler **ppIBitmapScaler) -{ - FIXME("(%p,%p): stub\n", iface, ppIBitmapScaler); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateBitmapClipper(IWICImagingFactory *iface, - IWICBitmapClipper **ppIBitmapClipper) -{ - FIXME("(%p,%p): stub\n", iface, ppIBitmapClipper); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateBitmapFlipRotator(IWICImagingFactory *iface, - IWICBitmapFlipRotator **ppIBitmapFlipRotator) -{ - FIXME("(%p,%p): stub\n", iface, ppIBitmapFlipRotator); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateStream(IWICImagingFactory *iface, - IWICStream **ppIWICStream) -{ - FIXME("(%p,%p): stub\n", iface, ppIWICStream); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateColorContext(IWICImagingFactory *iface, - IWICColorContext **ppIColorContext) -{ - FIXME("(%p,%p): stub\n", iface, ppIColorContext); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateColorTransformer(IWICImagingFactory *iface, - IWICColorTransform **ppIColorTransform) -{ - FIXME("(%p,%p): stub\n", iface, ppIColorTransform); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateBitmap(IWICImagingFactory *iface, - UINT uiWidth, UINT uiHeight, REFWICPixelFormatGUID pixelFormat, - WICBitmapCreateCacheOption option, IWICBitmap **ppIBitmap) -{ - FIXME("(%p,%u,%u,%s,%u,%p): stub\n", iface, uiWidth, uiHeight, - debugstr_guid(pixelFormat), option, ppIBitmap); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateBitmapFromSource(IWICImagingFactory *iface, - IWICBitmapSource *piBitmapSource, WICBitmapCreateCacheOption option, - IWICBitmap **ppIBitmap) -{ - FIXME("(%p,%p,%u,%p): stub\n", iface, piBitmapSource, option, ppIBitmap); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateBitmapFromSourceRect(IWICImagingFactory *iface, - IWICBitmapSource *piBitmapSource, UINT x, UINT y, UINT width, UINT height, - IWICBitmap **ppIBitmap) -{ - FIXME("(%p,%p,%u,%u,%u,%u,%p): stub\n", iface, piBitmapSource, x, y, width, - height, ppIBitmap); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateBitmapFromMemory(IWICImagingFactory *iface, - UINT uiWidth, UINT uiHeight, REFWICPixelFormatGUID pixelFormat, UINT cbStride, - UINT cbBufferSize, BYTE *pbBuffer, IWICBitmap **ppIBitmap) -{ - FIXME("(%p,%u,%u,%s,%u,%u,%p,%p): stub\n", iface, uiWidth, uiHeight, - debugstr_guid(pixelFormat), cbStride, cbBufferSize, pbBuffer, ppIBitmap); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateBitmapFromHBITMAP(IWICImagingFactory *iface, - HBITMAP hBitmap, HPALETTE hPalette, WICBitmapAlphaChannelOption options, - IWICBitmap **ppIBitmap) -{ - FIXME("(%p,%p,%p,%u,%p): stub\n", iface, hBitmap, hPalette, options, ppIBitmap); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateBitmapFromHICON(IWICImagingFactory *iface, - HICON hIcon, IWICBitmap **ppIBitmap) -{ - FIXME("(%p,%p,%p): stub\n", iface, hIcon, ppIBitmap); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateComponentEnumerator(IWICImagingFactory *iface, - DWORD componentTypes, DWORD options, IEnumUnknown **ppIEnumUnknown) -{ - FIXME("(%p,%u,%u,%p): stub\n", iface, componentTypes, options, ppIEnumUnknown); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateFastMetadataEncoderFromDecoder( - IWICImagingFactory *iface, IWICBitmapDecoder *pIDecoder, - IWICFastMetadataEncoder **ppIFastEncoder) -{ - FIXME("(%p,%p,%p): stub\n", iface, pIDecoder, ppIFastEncoder); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateFastMetadataEncoderFromFrameDecode( - IWICImagingFactory *iface, IWICBitmapFrameDecode *pIFrameDecoder, - IWICFastMetadataEncoder **ppIFastEncoder) -{ - FIXME("(%p,%p,%p): stub\n", iface, pIFrameDecoder, ppIFastEncoder); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateQueryWriter(IWICImagingFactory *iface, - REFGUID guidMetadataFormat, const GUID *pguidVendor, - IWICMetadataQueryWriter **ppIQueryWriter) -{ - FIXME("(%p,%s,%s,%p): stub\n", iface, debugstr_guid(guidMetadataFormat), - debugstr_guid(pguidVendor), ppIQueryWriter); - return E_NOTIMPL; -} - -static HRESULT WINAPI ImagingFactory_CreateQueryWriterFromReader(IWICImagingFactory *iface, - IWICMetadataQueryReader *pIQueryReader, const GUID *pguidVendor, - IWICMetadataQueryWriter **ppIQueryWriter) -{ - FIXME("(%p,%p,%s,%p): stub\n", iface, pIQueryReader, debugstr_guid(pguidVendor), - ppIQueryWriter); - return E_NOTIMPL; -} - -static const IWICImagingFactoryVtbl ImagingFactory_Vtbl = { - ImagingFactory_QueryInterface, - ImagingFactory_AddRef, - ImagingFactory_Release, - ImagingFactory_CreateDecoderFromFilename, - ImagingFactory_CreateDecoderFromStream, - ImagingFactory_CreateDecoderFromFileHandle, - ImagingFactory_CreateComponentInfo, - ImagingFactory_CreateDecoder, - ImagingFactory_CreateEncoder, - ImagingFactory_CreatePalette, - ImagingFactory_CreateFormatConverter, - ImagingFactory_CreateBitmapScaler, - ImagingFactory_CreateBitmapClipper, - ImagingFactory_CreateBitmapFlipRotator, - ImagingFactory_CreateStream, - ImagingFactory_CreateColorContext, - ImagingFactory_CreateColorTransformer, - ImagingFactory_CreateBitmap, - ImagingFactory_CreateBitmapFromSource, - ImagingFactory_CreateBitmapFromSourceRect, - ImagingFactory_CreateBitmapFromMemory, - ImagingFactory_CreateBitmapFromHBITMAP, - ImagingFactory_CreateBitmapFromHICON, - ImagingFactory_CreateComponentEnumerator, - ImagingFactory_CreateFastMetadataEncoderFromDecoder, - ImagingFactory_CreateFastMetadataEncoderFromFrameDecode, - ImagingFactory_CreateQueryWriter, - ImagingFactory_CreateQueryWriterFromReader -}; - -HRESULT ImagingFactory_CreateInstance(IUnknown *pUnkOuter, REFIID iid, void** ppv) -{ - ImagingFactory *This; - HRESULT ret; - - TRACE("(%p,%s,%p)\n", pUnkOuter, debugstr_guid(iid), ppv); - - *ppv = NULL; - - if (pUnkOuter) return CLASS_E_NOAGGREGATION; - - This = HeapAlloc(GetProcessHeap(), 0, sizeof(ImagingFactory)); - if (!This) return E_OUTOFMEMORY; - - This->lpIWICImagingFactoryVtbl = &ImagingFactory_Vtbl; - This->ref = 1; - - ret = IUnknown_QueryInterface((IUnknown*)This, iid, ppv); - IUnknown_Release((IUnknown*)This); - - return ret; -} diff --git a/dlls/windowscodecs/main.c b/dlls/windowscodecs/main.c index ac636031c6c..e3912b8462a 100644 --- a/dlls/windowscodecs/main.c +++ b/dlls/windowscodecs/main.c @@ -23,14 +23,6 @@ #include "windef.h" #include "winbase.h" -#include "objbase.h" -#include "wincodec.h" - -#include "wincodecs_private.h" - -#include "wine/debug.h" - -WINE_DEFAULT_DEBUG_CHANNEL(wincodecs); BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) { @@ -48,48 +40,3 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) return TRUE; } - -HRESULT copy_pixels(UINT bpp, const BYTE *srcbuffer, - UINT srcwidth, UINT srcheight, INT srcstride, - const WICRect *rc, UINT dststride, UINT dstbuffersize, BYTE *dstbuffer) -{ - UINT bytesperrow; - UINT row_offset; /* number of bits into the source rows where the data starts */ - - if (rc->X < 0 || rc->Y < 0 || rc->X+rc->Width > srcwidth || rc->Y+rc->Height > srcheight) - return E_INVALIDARG; - - bytesperrow = ((bpp * rc->Width)+7)/8; - - if (dststride < bytesperrow) - return E_INVALIDARG; - - if ((dststride * rc->Height) > dstbuffersize) - return E_INVALIDARG; - - row_offset = rc->X * bpp; - - if (row_offset % 8 == 0) - { - /* everything lines up on a byte boundary */ - UINT row; - const BYTE *src; - BYTE *dst; - - src = srcbuffer + (row_offset / 8); - dst = dstbuffer; - for (row=0; row < rc->Height; row++) - { - memcpy(dst, src, bytesperrow); - src += srcstride; - dst += dststride; - } - return S_OK; - } - else - { - /* we have to do a weird bitwise copy. eww. */ - FIXME("cannot reliably copy bitmap data if bpp < 8\n"); - return E_FAIL; - } -} diff --git a/dlls/windowscodecs/palette.c b/dlls/windowscodecs/palette.c deleted file mode 100644 index 842d3b51c30..00000000000 --- a/dlls/windowscodecs/palette.c +++ /dev/null @@ -1,279 +0,0 @@ -/* - * Copyright 2009 Vincent Povirk for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "config.h" - -#include - -#define COBJMACROS - -#include "windef.h" -#include "winbase.h" -#include "winreg.h" -#include "objbase.h" -#include "wincodec.h" - -#include "wincodecs_private.h" - -#include "wine/debug.h" - -WINE_DEFAULT_DEBUG_CHANNEL(wincodecs); - -typedef struct { - const IWICPaletteVtbl *lpIWICPaletteVtbl; - LONG ref; - UINT count; - WICColor *colors; - WICBitmapPaletteType type; -} PaletteImpl; - -static HRESULT WINAPI PaletteImpl_QueryInterface(IWICPalette *iface, REFIID iid, - void **ppv) -{ - PaletteImpl *This = (PaletteImpl*)iface; - TRACE("(%p,%s,%p)\n", iface, debugstr_guid(iid), ppv); - - if (!ppv) return E_INVALIDARG; - - if (IsEqualIID(&IID_IUnknown, iid) || IsEqualIID(&IID_IWICPalette, iid)) - { - *ppv = This; - } - else - { - *ppv = NULL; - return E_NOINTERFACE; - } - - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; -} - -static ULONG WINAPI PaletteImpl_AddRef(IWICPalette *iface) -{ - PaletteImpl *This = (PaletteImpl*)iface; - ULONG ref = InterlockedIncrement(&This->ref); - - TRACE("(%p) refcount=%u\n", iface, ref); - - return ref; -} - -static ULONG WINAPI PaletteImpl_Release(IWICPalette *iface) -{ - PaletteImpl *This = (PaletteImpl*)iface; - ULONG ref = InterlockedDecrement(&This->ref); - - TRACE("(%p) refcount=%u\n", iface, ref); - - if (ref == 0) - { - HeapFree(GetProcessHeap(), 0, This->colors); - HeapFree(GetProcessHeap(), 0, This); - } - - return ref; -} - -static HRESULT WINAPI PaletteImpl_InitializePredefined(IWICPalette *iface, - WICBitmapPaletteType ePaletteType, BOOL fAddTransparentColor) -{ - FIXME("(%p,%u,%i): stub\n", iface, ePaletteType, fAddTransparentColor); - return E_NOTIMPL; -} - -static HRESULT WINAPI PaletteImpl_InitializeCustom(IWICPalette *iface, - WICColor *pColors, UINT colorCount) -{ - PaletteImpl *This = (PaletteImpl*)iface; - WICColor *new_colors; - - TRACE("(%p,%p,%u)\n", iface, pColors, colorCount); - - if (colorCount == 0) - { - new_colors = NULL; - } - else - { - if (!pColors) return E_INVALIDARG; - new_colors = HeapAlloc(GetProcessHeap(), 0, sizeof(WICColor) * colorCount); - if (!new_colors) return E_OUTOFMEMORY; - memcpy(new_colors, pColors, sizeof(WICColor) * colorCount); - } - - HeapFree(GetProcessHeap(), 0, This->colors); - This->colors = new_colors; - This->count = colorCount; - This->type = WICBitmapPaletteTypeCustom; - - return S_OK; -} - -static HRESULT WINAPI PaletteImpl_InitializeFromBitmap(IWICPalette *iface, - IWICBitmapSource *pISurface, UINT colorCount, BOOL fAddTransparentColor) -{ - FIXME("(%p,%p,%u,%i): stub\n", iface, pISurface, colorCount, fAddTransparentColor); - return E_NOTIMPL; -} - -static HRESULT WINAPI PaletteImpl_InitializeFromPalette(IWICPalette *iface, - IWICPalette *pIPalette) -{ - FIXME("(%p,%p): stub\n", iface, pIPalette); - return E_NOTIMPL; -} - -static HRESULT WINAPI PaletteImpl_GetType(IWICPalette *iface, - WICBitmapPaletteType *pePaletteType) -{ - PaletteImpl *This = (PaletteImpl*)iface; - - TRACE("(%p,%p)\n", iface, pePaletteType); - - if (!pePaletteType) return E_INVALIDARG; - - *pePaletteType = This->type; - - return S_OK; -} - -static HRESULT WINAPI PaletteImpl_GetColorCount(IWICPalette *iface, UINT *pcCount) -{ - PaletteImpl *This = (PaletteImpl*)iface; - - TRACE("(%p,%p)\n", iface, pcCount); - - if (!pcCount) return E_INVALIDARG; - - *pcCount = This->count; - - return S_OK; -} - -static HRESULT WINAPI PaletteImpl_GetColors(IWICPalette *iface, UINT colorCount, - WICColor *pColors, UINT *pcActualColors) -{ - PaletteImpl *This = (PaletteImpl*)iface; - - TRACE("(%p,%i,%p,%p)\n", iface, colorCount, pColors, pcActualColors); - - if (!pColors || !pcActualColors) return E_INVALIDARG; - - if (This->count < colorCount) colorCount = This->count; - - memcpy(pColors, This->colors, sizeof(WICColor) * colorCount); - - *pcActualColors = colorCount; - - return S_OK; -} - -static HRESULT WINAPI PaletteImpl_IsBlackWhite(IWICPalette *iface, BOOL *pfIsBlackWhite) -{ - PaletteImpl *This = (PaletteImpl*)iface; - - TRACE("(%p,%p)\n", iface, pfIsBlackWhite); - - if (!pfIsBlackWhite) return E_INVALIDARG; - - if (This->type == WICBitmapPaletteTypeFixedBW) - *pfIsBlackWhite = TRUE; - else - *pfIsBlackWhite = FALSE; - - return S_OK; -} - -static HRESULT WINAPI PaletteImpl_IsGrayscale(IWICPalette *iface, BOOL *pfIsGrayscale) -{ - PaletteImpl *This = (PaletteImpl*)iface; - - TRACE("(%p,%p)\n", iface, pfIsGrayscale); - - if (!pfIsGrayscale) return E_INVALIDARG; - - switch(This->type) - { - case WICBitmapPaletteTypeFixedBW: - case WICBitmapPaletteTypeFixedGray4: - case WICBitmapPaletteTypeFixedGray16: - case WICBitmapPaletteTypeFixedGray256: - *pfIsGrayscale = TRUE; - break; - default: - *pfIsGrayscale = FALSE; - } - - return S_OK; -} - -static HRESULT WINAPI PaletteImpl_HasAlpha(IWICPalette *iface, BOOL *pfHasAlpha) -{ - PaletteImpl *This = (PaletteImpl*)iface; - int i; - - TRACE("(%p,%p)\n", iface, pfHasAlpha); - - if (!pfHasAlpha) return E_INVALIDARG; - - *pfHasAlpha = FALSE; - - for (i=0; icount; i++) - if ((This->colors[i]&0xff000000) != 0xff000000) - { - *pfHasAlpha = TRUE; - break; - } - - return S_OK; -} - -static const IWICPaletteVtbl PaletteImpl_Vtbl = { - PaletteImpl_QueryInterface, - PaletteImpl_AddRef, - PaletteImpl_Release, - PaletteImpl_InitializePredefined, - PaletteImpl_InitializeCustom, - PaletteImpl_InitializeFromBitmap, - PaletteImpl_InitializeFromPalette, - PaletteImpl_GetType, - PaletteImpl_GetColorCount, - PaletteImpl_GetColors, - PaletteImpl_IsBlackWhite, - PaletteImpl_IsGrayscale, - PaletteImpl_HasAlpha -}; - -HRESULT PaletteImpl_Create(IWICPalette **palette) -{ - PaletteImpl *This; - - This = HeapAlloc(GetProcessHeap(), 0, sizeof(PaletteImpl)); - if (!This) return E_OUTOFMEMORY; - - This->lpIWICPaletteVtbl = &PaletteImpl_Vtbl; - This->ref = 1; - This->count = 0; - This->colors = NULL; - This->type = WICBitmapPaletteTypeCustom; - - *palette = (IWICPalette*)This; - - return S_OK; -} diff --git a/dlls/windowscodecs/regsvr.c b/dlls/windowscodecs/regsvr.c deleted file mode 100644 index 2a3996e93a6..00000000000 --- a/dlls/windowscodecs/regsvr.c +++ /dev/null @@ -1,628 +0,0 @@ -/* - * Copyright 2009 Vincent Povirk for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#define NONAMELESSUNION -#define NONAMELESSSTRUCT -#define COBJMACROS -#include -#include - -#include "windef.h" -#include "winbase.h" -#include "wingdi.h" -#include "winuser.h" -#include "winreg.h" -#include "winerror.h" - -#include "objbase.h" -#include "ocidl.h" -#include "wincodec.h" - -#include "wine/debug.h" -#include "wine/unicode.h" - -WINE_DEFAULT_DEBUG_CHANNEL(wincodecs); - -/*********************************************************************** - * interface for self-registering - */ -struct regsvr_coclass -{ - CLSID const *clsid; /* NULL for end of list */ - LPCSTR name; /* can be NULL to omit */ - LPCSTR ips; /* can be NULL to omit */ - LPCSTR ips32; /* can be NULL to omit */ - LPCSTR ips32_tmodel; /* can be NULL to omit */ - LPCSTR progid; /* can be NULL to omit */ - LPCSTR viprogid; /* can be NULL to omit */ - LPCSTR progid_extra; /* can be NULL to omit */ -}; - -static HRESULT register_coclasses(struct regsvr_coclass const *list); -static HRESULT unregister_coclasses(struct regsvr_coclass const *list); - -struct decoder_pattern -{ - DWORD length; /* 0 for end of list */ - DWORD position; - const BYTE *pattern; - const BYTE *mask; - DWORD endofstream; -}; - -struct regsvr_decoder -{ - CLSID const *clsid; /* NULL for end of list */ - LPCSTR author; - LPCSTR friendlyname; - LPCSTR version; - GUID const *vendor; - LPCSTR mimetypes; - LPCSTR extensions; - GUID const * const *formats; - const struct decoder_pattern *patterns; -}; - -static HRESULT register_decoders(struct regsvr_decoder const *list); -static HRESULT unregister_decoders(struct regsvr_decoder const *list); - -/*********************************************************************** - * static string constants - */ -static WCHAR const clsid_keyname[6] = { - 'C', 'L', 'S', 'I', 'D', 0 }; -static WCHAR const curver_keyname[7] = { - 'C', 'u', 'r', 'V', 'e', 'r', 0 }; -static WCHAR const ips_keyname[13] = { - 'I', 'n', 'P', 'r', 'o', 'c', 'S', 'e', 'r', 'v', 'e', 'r', - 0 }; -static WCHAR const ips32_keyname[15] = { - 'I', 'n', 'P', 'r', 'o', 'c', 'S', 'e', 'r', 'v', 'e', 'r', - '3', '2', 0 }; -static WCHAR const progid_keyname[7] = { - 'P', 'r', 'o', 'g', 'I', 'D', 0 }; -static WCHAR const viprogid_keyname[25] = { - 'V', 'e', 'r', 's', 'i', 'o', 'n', 'I', 'n', 'd', 'e', 'p', - 'e', 'n', 'd', 'e', 'n', 't', 'P', 'r', 'o', 'g', 'I', 'D', - 0 }; -static char const tmodel_valuename[] = "ThreadingModel"; -static char const author_valuename[] = "Author"; -static char const friendlyname_valuename[] = "FriendlyName"; -static WCHAR const vendor_valuename[] = {'V','e','n','d','o','r',0}; -static char const version_valuename[] = "Version"; -static char const mimetypes_valuename[] = "MimeTypes"; -static char const extensions_valuename[] = "FileExtensions"; -static WCHAR const formats_keyname[] = {'F','o','r','m','a','t','s',0}; -static WCHAR const patterns_keyname[] = {'P','a','t','t','e','r','n','s',0}; -static WCHAR const instance_keyname[] = {'I','n','s','t','a','n','c','e',0}; -static WCHAR const clsid_valuename[] = {'C','L','S','I','D',0}; -static char const length_valuename[] = "Length"; -static char const position_valuename[] = "Position"; -static char const pattern_valuename[] = "Pattern"; -static char const mask_valuename[] = "Mask"; -static char const endofstream_valuename[] = "EndOfStream"; - -/*********************************************************************** - * static helper functions - */ -static LONG register_key_defvalueW(HKEY base, WCHAR const *name, - WCHAR const *value); -static LONG register_key_defvalueA(HKEY base, WCHAR const *name, - char const *value); -static LONG register_progid(WCHAR const *clsid, - char const *progid, char const *curver_progid, - char const *name, char const *extra); - -/*********************************************************************** - * register_coclasses - */ -static HRESULT register_coclasses(struct regsvr_coclass const *list) -{ - LONG res = ERROR_SUCCESS; - HKEY coclass_key; - - res = RegCreateKeyExW(HKEY_CLASSES_ROOT, clsid_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &coclass_key, NULL); - if (res != ERROR_SUCCESS) goto error_return; - - for (; res == ERROR_SUCCESS && list->clsid; ++list) { - WCHAR buf[39]; - HKEY clsid_key; - - StringFromGUID2(list->clsid, buf, 39); - res = RegCreateKeyExW(coclass_key, buf, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &clsid_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - - if (list->name) { - res = RegSetValueExA(clsid_key, NULL, 0, REG_SZ, - (CONST BYTE*)(list->name), - strlen(list->name) + 1); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->ips) { - res = register_key_defvalueA(clsid_key, ips_keyname, list->ips); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->ips32) { - HKEY ips32_key; - - res = RegCreateKeyExW(clsid_key, ips32_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, - &ips32_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - - res = RegSetValueExA(ips32_key, NULL, 0, REG_SZ, - (CONST BYTE*)list->ips32, - lstrlenA(list->ips32) + 1); - if (res == ERROR_SUCCESS && list->ips32_tmodel) - res = RegSetValueExA(ips32_key, tmodel_valuename, 0, REG_SZ, - (CONST BYTE*)list->ips32_tmodel, - strlen(list->ips32_tmodel) + 1); - RegCloseKey(ips32_key); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->progid) { - res = register_key_defvalueA(clsid_key, progid_keyname, - list->progid); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - - res = register_progid(buf, list->progid, NULL, - list->name, list->progid_extra); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->viprogid) { - res = register_key_defvalueA(clsid_key, viprogid_keyname, - list->viprogid); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - - res = register_progid(buf, list->viprogid, list->progid, - list->name, list->progid_extra); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - error_close_clsid_key: - RegCloseKey(clsid_key); - } - -error_close_coclass_key: - RegCloseKey(coclass_key); -error_return: - return res != ERROR_SUCCESS ? HRESULT_FROM_WIN32(res) : S_OK; -} - -/*********************************************************************** - * unregister_coclasses - */ -static HRESULT unregister_coclasses(struct regsvr_coclass const *list) -{ - LONG res = ERROR_SUCCESS; - HKEY coclass_key; - - res = RegOpenKeyExW(HKEY_CLASSES_ROOT, clsid_keyname, 0, - KEY_READ | KEY_WRITE, &coclass_key); - if (res == ERROR_FILE_NOT_FOUND) return S_OK; - if (res != ERROR_SUCCESS) goto error_return; - - for (; res == ERROR_SUCCESS && list->clsid; ++list) { - WCHAR buf[39]; - - StringFromGUID2(list->clsid, buf, 39); - res = RegDeleteTreeW(coclass_key, buf); - if (res == ERROR_FILE_NOT_FOUND) res = ERROR_SUCCESS; - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - - if (list->progid) { - res = RegDeleteTreeA(HKEY_CLASSES_ROOT, list->progid); - if (res == ERROR_FILE_NOT_FOUND) res = ERROR_SUCCESS; - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - } - - if (list->viprogid) { - res = RegDeleteTreeA(HKEY_CLASSES_ROOT, list->viprogid); - if (res == ERROR_FILE_NOT_FOUND) res = ERROR_SUCCESS; - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - } - } - -error_close_coclass_key: - RegCloseKey(coclass_key); -error_return: - return res != ERROR_SUCCESS ? HRESULT_FROM_WIN32(res) : S_OK; -} - -/*********************************************************************** - * register_decoders - */ -static HRESULT register_decoders(struct regsvr_decoder const *list) -{ - LONG res = ERROR_SUCCESS; - HKEY coclass_key; - WCHAR buf[39]; - HKEY decoders_key; - HKEY instance_key; - - res = RegCreateKeyExW(HKEY_CLASSES_ROOT, clsid_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &coclass_key, NULL); - if (res == ERROR_SUCCESS) { - StringFromGUID2(&CATID_WICBitmapDecoders, buf, 39); - res = RegCreateKeyExW(coclass_key, buf, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &decoders_key, NULL); - if (res == ERROR_SUCCESS) - { - res = RegCreateKeyExW(decoders_key, instance_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &instance_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - } - if (res != ERROR_SUCCESS) - RegCloseKey(coclass_key); - } - if (res != ERROR_SUCCESS) goto error_return; - - for (; res == ERROR_SUCCESS && list->clsid; ++list) { - HKEY clsid_key; - HKEY instance_clsid_key; - - StringFromGUID2(list->clsid, buf, 39); - res = RegCreateKeyExW(coclass_key, buf, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &clsid_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - - StringFromGUID2(list->clsid, buf, 39); - res = RegCreateKeyExW(instance_key, buf, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &instance_clsid_key, NULL); - if (res == ERROR_SUCCESS) { - res = RegSetValueExW(instance_clsid_key, clsid_valuename, 0, REG_SZ, - (CONST BYTE*)(buf), 78); - RegCloseKey(instance_clsid_key); - } - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - - if (list->author) { - res = RegSetValueExA(clsid_key, author_valuename, 0, REG_SZ, - (CONST BYTE*)(list->author), - strlen(list->author) + 1); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->friendlyname) { - res = RegSetValueExA(clsid_key, friendlyname_valuename, 0, REG_SZ, - (CONST BYTE*)(list->friendlyname), - strlen(list->friendlyname) + 1); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->vendor) { - StringFromGUID2(list->vendor, buf, 39); - res = RegSetValueExW(clsid_key, vendor_valuename, 0, REG_SZ, - (CONST BYTE*)(buf), 78); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->version) { - res = RegSetValueExA(clsid_key, version_valuename, 0, REG_SZ, - (CONST BYTE*)(list->version), - strlen(list->version) + 1); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->mimetypes) { - res = RegSetValueExA(clsid_key, mimetypes_valuename, 0, REG_SZ, - (CONST BYTE*)(list->mimetypes), - strlen(list->mimetypes) + 1); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->extensions) { - res = RegSetValueExA(clsid_key, extensions_valuename, 0, REG_SZ, - (CONST BYTE*)(list->extensions), - strlen(list->extensions) + 1); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->formats) { - HKEY formats_key; - GUID const * const *format; - - res = RegCreateKeyExW(clsid_key, formats_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &formats_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - for (format=list->formats; *format; ++format) - { - HKEY format_key; - StringFromGUID2(*format, buf, 39); - res = RegCreateKeyExW(formats_key, buf, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &format_key, NULL); - if (res != ERROR_SUCCESS) break; - RegCloseKey(format_key); - } - RegCloseKey(formats_key); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->patterns) { - HKEY patterns_key; - int i; - - res = RegCreateKeyExW(clsid_key, patterns_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &patterns_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - for (i=0; list->patterns[i].length; i++) - { - HKEY pattern_key; - static const WCHAR int_format[] = {'%','i',0}; - snprintfW(buf, 39, int_format, i); - res = RegCreateKeyExW(patterns_key, buf, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &pattern_key, NULL); - if (res != ERROR_SUCCESS) break; - res = RegSetValueExA(pattern_key, length_valuename, 0, REG_DWORD, - (CONST BYTE*)(&list->patterns[i].length), 4); - if (res == ERROR_SUCCESS) - res = RegSetValueExA(pattern_key, position_valuename, 0, REG_DWORD, - (CONST BYTE*)(&list->patterns[i].position), 4); - if (res == ERROR_SUCCESS) - res = RegSetValueExA(pattern_key, pattern_valuename, 0, REG_BINARY, - list->patterns[i].pattern, - list->patterns[i].length); - if (res == ERROR_SUCCESS) - res = RegSetValueExA(pattern_key, mask_valuename, 0, REG_BINARY, - list->patterns[i].mask, - list->patterns[i].length); - if (res == ERROR_SUCCESS) - res = RegSetValueExA(pattern_key, endofstream_valuename, 0, REG_DWORD, - (CONST BYTE*)&(list->patterns[i].endofstream), 4); - RegCloseKey(pattern_key); - } - RegCloseKey(patterns_key); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - error_close_clsid_key: - RegCloseKey(clsid_key); - } - -error_close_coclass_key: - RegCloseKey(instance_key); - RegCloseKey(decoders_key); - RegCloseKey(coclass_key); -error_return: - return res != ERROR_SUCCESS ? HRESULT_FROM_WIN32(res) : S_OK; -} - -/*********************************************************************** - * unregister_decoders - */ -static HRESULT unregister_decoders(struct regsvr_decoder const *list) -{ - LONG res = ERROR_SUCCESS; - HKEY coclass_key; - WCHAR buf[39]; - HKEY decoders_key; - HKEY instance_key; - - res = RegOpenKeyExW(HKEY_CLASSES_ROOT, clsid_keyname, 0, - KEY_READ | KEY_WRITE, &coclass_key); - if (res == ERROR_FILE_NOT_FOUND) return S_OK; - - if (res == ERROR_SUCCESS) { - StringFromGUID2(&CATID_WICBitmapDecoders, buf, 39); - res = RegCreateKeyExW(coclass_key, buf, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &decoders_key, NULL); - if (res == ERROR_SUCCESS) - { - res = RegCreateKeyExW(decoders_key, instance_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &instance_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - } - if (res != ERROR_SUCCESS) - RegCloseKey(coclass_key); - } - if (res != ERROR_SUCCESS) goto error_return; - - for (; res == ERROR_SUCCESS && list->clsid; ++list) { - StringFromGUID2(list->clsid, buf, 39); - - res = RegDeleteTreeW(coclass_key, buf); - if (res == ERROR_FILE_NOT_FOUND) res = ERROR_SUCCESS; - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - - res = RegDeleteTreeW(instance_key, buf); - if (res == ERROR_FILE_NOT_FOUND) res = ERROR_SUCCESS; - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - } - -error_close_coclass_key: - RegCloseKey(instance_key); - RegCloseKey(decoders_key); - RegCloseKey(coclass_key); -error_return: - return res != ERROR_SUCCESS ? HRESULT_FROM_WIN32(res) : S_OK; -} - -/*********************************************************************** - * register_key_defvalueW - */ -static LONG register_key_defvalueW( - HKEY base, - WCHAR const *name, - WCHAR const *value) -{ - LONG res; - HKEY key; - - res = RegCreateKeyExW(base, name, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &key, NULL); - if (res != ERROR_SUCCESS) return res; - res = RegSetValueExW(key, NULL, 0, REG_SZ, (CONST BYTE*)value, - (lstrlenW(value) + 1) * sizeof(WCHAR)); - RegCloseKey(key); - return res; -} - -/*********************************************************************** - * register_key_defvalueA - */ -static LONG register_key_defvalueA( - HKEY base, - WCHAR const *name, - char const *value) -{ - LONG res; - HKEY key; - - res = RegCreateKeyExW(base, name, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &key, NULL); - if (res != ERROR_SUCCESS) return res; - res = RegSetValueExA(key, NULL, 0, REG_SZ, (CONST BYTE*)value, - lstrlenA(value) + 1); - RegCloseKey(key); - return res; -} - -/*********************************************************************** - * register_progid - */ -static LONG register_progid( - WCHAR const *clsid, - char const *progid, - char const *curver_progid, - char const *name, - char const *extra) -{ - LONG res; - HKEY progid_key; - - res = RegCreateKeyExA(HKEY_CLASSES_ROOT, progid, 0, - NULL, 0, KEY_READ | KEY_WRITE, NULL, - &progid_key, NULL); - if (res != ERROR_SUCCESS) return res; - - if (name) { - res = RegSetValueExA(progid_key, NULL, 0, REG_SZ, - (CONST BYTE*)name, strlen(name) + 1); - if (res != ERROR_SUCCESS) goto error_close_progid_key; - } - - if (clsid) { - res = register_key_defvalueW(progid_key, clsid_keyname, clsid); - if (res != ERROR_SUCCESS) goto error_close_progid_key; - } - - if (curver_progid) { - res = register_key_defvalueA(progid_key, curver_keyname, - curver_progid); - if (res != ERROR_SUCCESS) goto error_close_progid_key; - } - - if (extra) { - HKEY extra_key; - - res = RegCreateKeyExA(progid_key, extra, 0, - NULL, 0, KEY_READ | KEY_WRITE, NULL, - &extra_key, NULL); - if (res == ERROR_SUCCESS) - RegCloseKey(extra_key); - } - -error_close_progid_key: - RegCloseKey(progid_key); - return res; -} - -/*********************************************************************** - * coclass list - */ -static struct regsvr_coclass const coclass_list[] = { - { &CLSID_WICImagingFactory, - "WIC Imaging Factory", - NULL, - "windowscodecs.dll", - "Apartment" - }, - { &CLSID_WICBmpDecoder, - "WIC BMP Decoder", - NULL, - "windowscodecs.dll", - "Apartment" - }, - { NULL } /* list terminator */ -}; - -/*********************************************************************** - * decoder list - */ -static const BYTE bmp_magic[] = {0x42,0x4d}; -static const BYTE mask_all[] = {0xff,0xff}; - -static GUID const * const bmp_formats[] = { - &GUID_WICPixelFormat1bppIndexed, - &GUID_WICPixelFormat2bppIndexed, - &GUID_WICPixelFormat4bppIndexed, - &GUID_WICPixelFormat8bppIndexed, - &GUID_WICPixelFormat16bppBGR555, - &GUID_WICPixelFormat24bppBGR, - &GUID_WICPixelFormat32bppBGR, - NULL -}; - -static struct decoder_pattern const bmp_patterns[] = { - {2,0,bmp_magic,mask_all,0}, - {0} -}; - -static struct regsvr_decoder const decoder_list[] = { - { &CLSID_WICBmpDecoder, - "The Wine Project", - "BMP Decoder", - "1.0.0.0", - &GUID_VendorMicrosoft, - "image/bmp", - ".bmp,.dib,.rle", - bmp_formats, - bmp_patterns - }, - { NULL } /* list terminator */ -}; - -HRESULT WINAPI DllRegisterServer(void) -{ - HRESULT hr; - - TRACE("\n"); - - hr = register_coclasses(coclass_list); - if (SUCCEEDED(hr)) - register_decoders(decoder_list); - return hr; -} - -HRESULT WINAPI DllUnregisterServer(void) -{ - HRESULT hr; - - TRACE("\n"); - - hr = unregister_coclasses(coclass_list); - if (SUCCEEDED(hr)) - unregister_decoders(decoder_list); - return hr; -} diff --git a/dlls/windowscodecs/tests/Makefile.in b/dlls/windowscodecs/tests/Makefile.in deleted file mode 100644 index 2bb8c0175aa..00000000000 --- a/dlls/windowscodecs/tests/Makefile.in +++ /dev/null @@ -1,14 +0,0 @@ -TOPSRCDIR = @top_srcdir@ -TOPOBJDIR = ../../.. -SRCDIR = @srcdir@ -VPATH = @srcdir@ -TESTDLL = windowscodecs.dll -IMPORTS = kernel32 ole32 - -CTESTS = \ - bmpformat.c \ - palette.c - -@MAKE_TEST_RULES@ - -@DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/windowscodecs/tests/bmpformat.c b/dlls/windowscodecs/tests/bmpformat.c deleted file mode 100644 index 5dc9cae7029..00000000000 --- a/dlls/windowscodecs/tests/bmpformat.c +++ /dev/null @@ -1,901 +0,0 @@ -/* - * Copyright 2009 Vincent Povirk for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include -#include - -#define COBJMACROS - -#include "windef.h" -#include "initguid.h" -#include "objbase.h" -#include "wincodec.h" -#include "wine/test.h" - -static const char testbmp_24bpp[] = { - /* BITMAPFILEHEADER */ - 66,77, /* "BM" */ - 50,0,0,0, /* file size */ - 0,0,0,0, /* reserved */ - 26,0,0,0, /* offset to bits */ - /* BITMAPCOREHEADER */ - 12,0,0,0, /* header size */ - 2,0, /* width */ - 3,0, /* height */ - 1,0, /* planes */ - 24,0, /* bit count */ - /* bits */ - 0,0,0, 0,255,0, 0,0, - 255,0,0, 255,255,0, 0,0, - 255,0,255, 255,255,255, 0,0 -}; - -static void test_decode_24bpp(void) -{ - IWICBitmapDecoder *decoder, *decoder2; - IWICBitmapFrameDecode *framedecode; - IWICMetadataQueryReader *queryreader; - IWICColorContext *colorcontext; - IWICBitmapSource *thumbnail; - HRESULT hr; - HGLOBAL hbmpdata; - char *bmpdata; - IStream *bmpstream; - DWORD capability=0; - GUID guidresult; - UINT count=0, width=0, height=0; - double dpiX, dpiY; - BYTE imagedata[36] = {1}; - const BYTE expected_imagedata[36] = { - 255,0,255, 255,255,255, - 255,0,0, 255,255,0, - 0,0,0, 0,255,0}; - WICRect rc; - - hr = CoCreateInstance(&CLSID_WICBmpDecoder, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICBitmapDecoder, (void**)&decoder); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (!SUCCEEDED(hr)) return; - - hbmpdata = GlobalAlloc(GMEM_MOVEABLE, sizeof(testbmp_24bpp)); - ok(hbmpdata != 0, "GlobalAlloc failed\n"); - if (hbmpdata) - { - bmpdata = GlobalLock(hbmpdata); - memcpy(bmpdata, testbmp_24bpp, sizeof(testbmp_24bpp)); - GlobalUnlock(hbmpdata); - - hr = CreateStreamOnHGlobal(hbmpdata, FALSE, &bmpstream); - ok(SUCCEEDED(hr), "CreateStreamOnHGlobal failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_Initialize(decoder, bmpstream, WICDecodeMetadataCacheOnLoad); - ok(hr == S_OK, "Initialize failed, hr=%x\n", hr); - - hr = IWICBitmapDecoder_GetContainerFormat(decoder, &guidresult); - ok(SUCCEEDED(hr), "GetContainerFormat failed, hr=%x\n", hr); - ok(IsEqualGUID(&guidresult, &GUID_ContainerFormatBmp), "unexpected container format\n"); - - hr = IWICBitmapDecoder_GetMetadataQueryReader(decoder, &queryreader); - ok(hr == WINCODEC_ERR_UNSUPPORTEDOPERATION, "expected WINCODEC_ERR_UNSUPPORTEDOPERATION, got %x\n", hr); - - hr = IWICBitmapDecoder_GetColorContexts(decoder, 1, &colorcontext, &count); - ok(hr == WINCODEC_ERR_UNSUPPORTEDOPERATION, "expected WINCODEC_ERR_UNSUPPORTEDOPERATION, got %x\n", hr); - - hr = IWICBitmapDecoder_GetThumbnail(decoder, &thumbnail); - ok(hr == WINCODEC_ERR_CODECNOTHUMBNAIL, "expected WINCODEC_ERR_CODECNOTHUMBNAIL, got %x\n", hr); - - hr = IWICBitmapDecoder_GetPreview(decoder, &thumbnail); - ok(hr == WINCODEC_ERR_UNSUPPORTEDOPERATION, "expected WINCODEC_ERR_UNSUPPORTEDOPERATION, got %x\n", hr); - - hr = IWICBitmapDecoder_GetFrameCount(decoder, &count); - ok(SUCCEEDED(hr), "GetFrameCount failed, hr=%x\n", hr); - ok(count == 1, "unexpected count %u\n", count); - - hr = IWICBitmapDecoder_GetFrame(decoder, 1, &framedecode); - ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got %x\n", hr); - - hr = IWICBitmapDecoder_GetFrame(decoder, 0, &framedecode); - ok(SUCCEEDED(hr), "GetFrame failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - IWICImagingFactory *factory; - IWICPalette *palette; - - hr = IWICBitmapFrameDecode_GetSize(framedecode, &width, &height); - ok(SUCCEEDED(hr), "GetSize failed, hr=%x\n", hr); - ok(width == 2, "expected width=2, got %u\n", width); - ok(height == 3, "expected height=2, got %u\n", height); - - hr = IWICBitmapFrameDecode_GetResolution(framedecode, &dpiX, &dpiY); - ok(SUCCEEDED(hr), "GetResolution failed, hr=%x\n", hr); - ok(dpiX == 96.0, "expected dpiX=96.0, got %f\n", dpiX); - ok(dpiY == 96.0, "expected dpiY=96.0, got %f\n", dpiY); - - hr = IWICBitmapFrameDecode_GetPixelFormat(framedecode, &guidresult); - ok(SUCCEEDED(hr), "GetPixelFormat failed, hr=%x\n", hr); - ok(IsEqualGUID(&guidresult, &GUID_WICPixelFormat24bppBGR), "unexpected pixel format\n"); - - hr = IWICBitmapFrameDecode_GetMetadataQueryReader(framedecode, &queryreader); - ok(hr == WINCODEC_ERR_UNSUPPORTEDOPERATION, "expected WINCODEC_ERR_UNSUPPORTEDOPERATION, got %x\n", hr); - - hr = IWICBitmapFrameDecode_GetColorContexts(framedecode, 1, &colorcontext, &count); - ok(hr == WINCODEC_ERR_UNSUPPORTEDOPERATION, "expected WINCODEC_ERR_UNSUPPORTEDOPERATION, got %x\n", hr); - - hr = IWICBitmapFrameDecode_GetThumbnail(framedecode, &thumbnail); - ok(hr == WINCODEC_ERR_CODECNOTHUMBNAIL, "expected WINCODEC_ERR_CODECNOTHUMBNAIL, got %x\n", hr); - - hr = CoCreateInstance(&CLSID_WICImagingFactory, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICImagingFactory, (void**)&factory); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICImagingFactory_CreatePalette(factory, &palette); - ok(SUCCEEDED(hr), "CreatePalette failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_CopyPalette(decoder, palette); - ok(hr == WINCODEC_ERR_PALETTEUNAVAILABLE, "expected WINCODEC_ERR_PALETTEUNAVAILABLE, got %x\n", hr); - - hr = IWICBitmapFrameDecode_CopyPalette(framedecode, palette); - ok(hr == WINCODEC_ERR_PALETTEUNAVAILABLE, "expected WINCODEC_ERR_PALETTEUNAVAILABLE, got %x\n", hr); - - IWICPalette_Release(palette); - } - - IWICImagingFactory_Release(factory); - } - - rc.X = 0; - rc.Y = 0; - rc.Width = 3; - rc.Height = 3; - hr = IWICBitmapFrameDecode_CopyPixels(framedecode, &rc, 6, sizeof(imagedata), imagedata); - ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got %x\n", hr); - - rc.X = -1; - rc.Y = 0; - rc.Width = 2; - rc.Height = 3; - hr = IWICBitmapFrameDecode_CopyPixels(framedecode, &rc, 6, sizeof(imagedata), imagedata); - ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got %x\n", hr); - - rc.X = 0; - rc.Y = 0; - rc.Width = 2; - rc.Height = 3; - hr = IWICBitmapFrameDecode_CopyPixels(framedecode, &rc, 4, sizeof(imagedata), imagedata); - ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got %x\n", hr); - - rc.X = 0; - rc.Y = 0; - rc.Width = 2; - rc.Height = 3; - hr = IWICBitmapFrameDecode_CopyPixels(framedecode, &rc, 4, 5, imagedata); - ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got %x\n", hr); - - rc.X = 0; - rc.Y = 0; - rc.Width = 2; - rc.Height = 3; - hr = IWICBitmapFrameDecode_CopyPixels(framedecode, &rc, 6, sizeof(imagedata), imagedata); - ok(SUCCEEDED(hr), "CopyPixels failed, hr=%x\n", hr); - ok(!memcmp(imagedata, expected_imagedata, sizeof(imagedata)), "unexpected image data\n"); - - IWICBitmapFrameDecode_Release(framedecode); - } - - /* cannot initialize twice */ - hr = IWICBitmapDecoder_Initialize(decoder, bmpstream, WICDecodeMetadataCacheOnLoad); - ok(hr == WINCODEC_ERR_WRONGSTATE, "expected WINCODEC_ERR_WRONGSTATE, hr=%x\n", hr); - - /* cannot querycapability after initialize */ - hr = IWICBitmapDecoder_QueryCapability(decoder, bmpstream, &capability); - ok(hr == WINCODEC_ERR_WRONGSTATE, "expected WINCODEC_ERR_WRONGSTATE, hr=%x\n", hr); - - hr = CoCreateInstance(&CLSID_WICBmpDecoder, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICBitmapDecoder, (void**)&decoder2); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_QueryCapability(decoder2, bmpstream, &capability); - ok(hr == S_OK, "QueryCapability failed, hr=%x\n", hr); - ok(capability == (WICBitmapDecoderCapabilityCanDecodeAllImages), - "unexpected capabilities: %x\n", capability); - - /* cannot initialize after querycapability */ - hr = IWICBitmapDecoder_Initialize(decoder2, bmpstream, WICDecodeMetadataCacheOnLoad); - ok(hr == WINCODEC_ERR_WRONGSTATE, "expected WINCODEC_ERR_WRONGSTATE, hr=%x\n", hr); - - /* cannot querycapability twice */ - hr = IWICBitmapDecoder_QueryCapability(decoder2, bmpstream, &capability); - ok(hr == WINCODEC_ERR_WRONGSTATE, "expected WINCODEC_ERR_WRONGSTATE, hr=%x\n", hr); - } - - IStream_Release(bmpstream); - } - - GlobalFree(hbmpdata); - } - - IWICBitmapDecoder_Release(decoder); -} - -static const char testbmp_1bpp[] = { - /* BITMAPFILEHEADER */ - 66,77, /* "BM" */ - 40,0,0,0, /* file size */ - 0,0,0,0, /* reserved */ - 32,0,0,0, /* offset to bits */ - /* BITMAPCOREHEADER */ - 12,0,0,0, /* header size */ - 2,0, /* width */ - 2,0, /* height */ - 1,0, /* planes */ - 1,0, /* bit count */ - /* color table */ - 255,0,0, - 0,255,0, - /* bits */ - 0xc0,0,0,0, - 0x80,0,0,0 -}; - -static void test_decode_1bpp(void) -{ - IWICBitmapDecoder *decoder, *decoder2; - IWICBitmapFrameDecode *framedecode; - HRESULT hr; - HGLOBAL hbmpdata; - char *bmpdata; - IStream *bmpstream; - DWORD capability=0; - GUID guidresult; - UINT count=0, width=0, height=0; - double dpiX, dpiY; - BYTE imagedata[2] = {1}; - const BYTE expected_imagedata[2] = {0x80,0xc0}; - WICColor palettedata[2] = {1}; - const WICColor expected_palettedata[2] = {0xff0000ff,0xff00ff00}; - WICRect rc; - - hr = CoCreateInstance(&CLSID_WICBmpDecoder, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICBitmapDecoder, (void**)&decoder); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (!SUCCEEDED(hr)) return; - - hbmpdata = GlobalAlloc(GMEM_MOVEABLE, sizeof(testbmp_1bpp)); - ok(hbmpdata != 0, "GlobalAlloc failed\n"); - if (hbmpdata) - { - bmpdata = GlobalLock(hbmpdata); - memcpy(bmpdata, testbmp_1bpp, sizeof(testbmp_1bpp)); - GlobalUnlock(hbmpdata); - - hr = CreateStreamOnHGlobal(hbmpdata, FALSE, &bmpstream); - ok(SUCCEEDED(hr), "CreateStreamOnHGlobal failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_Initialize(decoder, bmpstream, WICDecodeMetadataCacheOnLoad); - ok(hr == S_OK, "Initialize failed, hr=%x\n", hr); - - hr = IWICBitmapDecoder_GetContainerFormat(decoder, &guidresult); - ok(SUCCEEDED(hr), "GetContainerFormat failed, hr=%x\n", hr); - ok(IsEqualGUID(&guidresult, &GUID_ContainerFormatBmp), "unexpected container format\n"); - - hr = IWICBitmapDecoder_GetFrameCount(decoder, &count); - ok(SUCCEEDED(hr), "GetFrameCount failed, hr=%x\n", hr); - ok(count == 1, "unexpected count %u\n", count); - - hr = IWICBitmapDecoder_GetFrame(decoder, 0, &framedecode); - ok(SUCCEEDED(hr), "GetFrame failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - IWICImagingFactory *factory; - IWICPalette *palette; - - hr = IWICBitmapFrameDecode_GetSize(framedecode, &width, &height); - ok(SUCCEEDED(hr), "GetSize failed, hr=%x\n", hr); - ok(width == 2, "expected width=2, got %u\n", width); - ok(height == 2, "expected height=2, got %u\n", height); - - hr = IWICBitmapFrameDecode_GetResolution(framedecode, &dpiX, &dpiY); - ok(SUCCEEDED(hr), "GetResolution failed, hr=%x\n", hr); - ok(dpiX == 96.0, "expected dpiX=96.0, got %f\n", dpiX); - ok(dpiY == 96.0, "expected dpiY=96.0, got %f\n", dpiY); - - hr = IWICBitmapFrameDecode_GetPixelFormat(framedecode, &guidresult); - ok(SUCCEEDED(hr), "GetPixelFormat failed, hr=%x\n", hr); - ok(IsEqualGUID(&guidresult, &GUID_WICPixelFormat1bppIndexed), "unexpected pixel format\n"); - - hr = CoCreateInstance(&CLSID_WICImagingFactory, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICImagingFactory, (void**)&factory); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICImagingFactory_CreatePalette(factory, &palette); - ok(SUCCEEDED(hr), "CreatePalette failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_CopyPalette(decoder, palette); - ok(hr == WINCODEC_ERR_PALETTEUNAVAILABLE, "expected WINCODEC_ERR_PALETTEUNAVAILABLE, got %x\n", hr); - - hr = IWICBitmapFrameDecode_CopyPalette(framedecode, palette); - ok(SUCCEEDED(hr), "CopyPalette failed, hr=%x\n", hr); - - hr = IWICPalette_GetColorCount(palette, &count); - ok(SUCCEEDED(hr), "GetColorCount failed, hr=%x\n", hr); - ok(count == 2, "expected count=2, got %u\n", count); - - hr = IWICPalette_GetColors(palette, 2, palettedata, &count); - ok(SUCCEEDED(hr), "GetColorCount failed, hr=%x\n", hr); - ok(count == 2, "expected count=2, got %u\n", count); - ok(!memcmp(palettedata, expected_palettedata, sizeof(palettedata)), "unexpected palette data\n"); - - IWICPalette_Release(palette); - } - - IWICImagingFactory_Release(factory); - } - - rc.X = 0; - rc.Y = 0; - rc.Width = 2; - rc.Height = 2; - hr = IWICBitmapFrameDecode_CopyPixels(framedecode, &rc, 1, sizeof(imagedata), imagedata); - ok(SUCCEEDED(hr), "CopyPixels failed, hr=%x\n", hr); - ok(!memcmp(imagedata, expected_imagedata, sizeof(imagedata)), "unexpected image data\n"); - - IWICBitmapFrameDecode_Release(framedecode); - } - - hr = CoCreateInstance(&CLSID_WICBmpDecoder, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICBitmapDecoder, (void**)&decoder2); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_QueryCapability(decoder2, bmpstream, &capability); - ok(hr == S_OK, "QueryCapability failed, hr=%x\n", hr); - ok(capability == (WICBitmapDecoderCapabilityCanDecodeAllImages), - "unexpected capabilities: %x\n", capability); - } - - IStream_Release(bmpstream); - } - - GlobalFree(hbmpdata); - } - - IWICBitmapDecoder_Release(decoder); -} - -static const char testbmp_4bpp[] = { - /* BITMAPFILEHEADER */ - 66,77, /* "BM" */ - 82,0,0,0, /* file size */ - 0,0,0,0, /* reserved */ - 74,0,0,0, /* offset to bits */ - /* BITMAPINFOHEADER */ - 40,0,0,0, /* header size */ - 2,0,0,0, /* width */ - 254,255,255,255, /* height = -2 */ - 1,0, /* planes */ - 4,0, /* bit count */ - 0,0,0,0, /* compression = BI_RGB */ - 0,0,0,0, /* image size = 0 */ - 16,39,0,0, /* X pixels per meter = 10000 */ - 32,78,0,0, /* Y pixels per meter = 20000 */ - 5,0,0,0, /* colors used */ - 5,0,0,0, /* colors important */ - /* color table */ - 255,0,0,0, - 0,255,0,255, - 0,0,255,23, - 128,0,128,1, - 255,255,255,0, - /* bits */ - 0x01,0,0,0, - 0x23,0,0,0, -}; - -static void test_decode_4bpp(void) -{ - IWICBitmapDecoder *decoder, *decoder2; - IWICBitmapFrameDecode *framedecode; - HRESULT hr; - HGLOBAL hbmpdata; - char *bmpdata; - IStream *bmpstream; - DWORD capability=0; - GUID guidresult; - UINT count=0, width=0, height=0; - double dpiX, dpiY; - BYTE imagedata[2] = {1}; - const BYTE expected_imagedata[2] = {0x01,0x23}; - WICColor palettedata[5] = {1}; - const WICColor expected_palettedata[5] = - {0xff0000ff,0xff00ff00,0xffff0000,0xff800080,0xffffffff}; - WICRect rc; - - hr = CoCreateInstance(&CLSID_WICBmpDecoder, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICBitmapDecoder, (void**)&decoder); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (!SUCCEEDED(hr)) return; - - hbmpdata = GlobalAlloc(GMEM_MOVEABLE, sizeof(testbmp_4bpp)); - ok(hbmpdata != 0, "GlobalAlloc failed\n"); - if (hbmpdata) - { - bmpdata = GlobalLock(hbmpdata); - memcpy(bmpdata, testbmp_4bpp, sizeof(testbmp_4bpp)); - GlobalUnlock(hbmpdata); - - hr = CreateStreamOnHGlobal(hbmpdata, FALSE, &bmpstream); - ok(SUCCEEDED(hr), "CreateStreamOnHGlobal failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_Initialize(decoder, bmpstream, WICDecodeMetadataCacheOnLoad); - ok(hr == S_OK, "Initialize failed, hr=%x\n", hr); - - hr = IWICBitmapDecoder_GetContainerFormat(decoder, &guidresult); - ok(SUCCEEDED(hr), "GetContainerFormat failed, hr=%x\n", hr); - ok(IsEqualGUID(&guidresult, &GUID_ContainerFormatBmp), "unexpected container format\n"); - - hr = IWICBitmapDecoder_GetFrameCount(decoder, &count); - ok(SUCCEEDED(hr), "GetFrameCount failed, hr=%x\n", hr); - ok(count == 1, "unexpected count %u\n", count); - - hr = IWICBitmapDecoder_GetFrame(decoder, 0, &framedecode); - ok(SUCCEEDED(hr), "GetFrame failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - IWICImagingFactory *factory; - IWICPalette *palette; - - hr = IWICBitmapFrameDecode_GetSize(framedecode, &width, &height); - ok(SUCCEEDED(hr), "GetSize failed, hr=%x\n", hr); - ok(width == 2, "expected width=2, got %u\n", width); - ok(height == 2, "expected height=2, got %u\n", height); - - hr = IWICBitmapFrameDecode_GetResolution(framedecode, &dpiX, &dpiY); - ok(SUCCEEDED(hr), "GetResolution failed, hr=%x\n", hr); - ok(fabs(dpiX - 254.0) < 0.01, "expected dpiX=96.0, got %f\n", dpiX); - ok(fabs(dpiY - 508.0) < 0.01, "expected dpiY=96.0, got %f\n", dpiY); - - hr = IWICBitmapFrameDecode_GetPixelFormat(framedecode, &guidresult); - ok(SUCCEEDED(hr), "GetPixelFormat failed, hr=%x\n", hr); - ok(IsEqualGUID(&guidresult, &GUID_WICPixelFormat4bppIndexed), "unexpected pixel format\n"); - - hr = CoCreateInstance(&CLSID_WICImagingFactory, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICImagingFactory, (void**)&factory); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICImagingFactory_CreatePalette(factory, &palette); - ok(SUCCEEDED(hr), "CreatePalette failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_CopyPalette(decoder, palette); - ok(hr == WINCODEC_ERR_PALETTEUNAVAILABLE, "expected WINCODEC_ERR_PALETTEUNAVAILABLE, got %x\n", hr); - - hr = IWICBitmapFrameDecode_CopyPalette(framedecode, palette); - ok(SUCCEEDED(hr), "CopyPalette failed, hr=%x\n", hr); - - hr = IWICPalette_GetColorCount(palette, &count); - ok(SUCCEEDED(hr), "GetColorCount failed, hr=%x\n", hr); - ok(count == 5, "expected count=5, got %u\n", count); - - hr = IWICPalette_GetColors(palette, 5, palettedata, &count); - ok(SUCCEEDED(hr), "GetColorCount failed, hr=%x\n", hr); - ok(count == 5, "expected count=5, got %u\n", count); - ok(!memcmp(palettedata, expected_palettedata, sizeof(palettedata)), "unexpected palette data\n"); - - IWICPalette_Release(palette); - } - - IWICImagingFactory_Release(factory); - } - - rc.X = 0; - rc.Y = 0; - rc.Width = 2; - rc.Height = 2; - hr = IWICBitmapFrameDecode_CopyPixels(framedecode, &rc, 1, sizeof(imagedata), imagedata); - ok(SUCCEEDED(hr), "CopyPixels failed, hr=%x\n", hr); - ok(!memcmp(imagedata, expected_imagedata, sizeof(imagedata)), "unexpected image data\n"); - - IWICBitmapFrameDecode_Release(framedecode); - } - - hr = CoCreateInstance(&CLSID_WICBmpDecoder, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICBitmapDecoder, (void**)&decoder2); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_QueryCapability(decoder2, bmpstream, &capability); - ok(hr == S_OK, "QueryCapability failed, hr=%x\n", hr); - ok(capability == (WICBitmapDecoderCapabilityCanDecodeAllImages), - "unexpected capabilities: %x\n", capability); - } - - IStream_Release(bmpstream); - } - - GlobalFree(hbmpdata); - } - - IWICBitmapDecoder_Release(decoder); -} - -static const char testbmp_rle8[] = { - /* BITMAPFILEHEADER */ - 66,77, /* "BM" */ - 202,0,0,0, /* file size */ - 0,0,0,0, /* reserved */ - 122,0,0,0, /* offset to bits */ - /* BITMAPINFOHEADER */ - 40,0,0,0, /* header size */ - 8,0,0,0, /* width */ - 8,0,0,0, /* height */ - 1,0, /* planes */ - 8,0, /* bit count */ - 1,0,0,0, /* compression = BI_RLE8 */ - 80,0,0,0, /* image size */ - 19,11,0,0, /* X pixels per meter */ - 19,11,0,0, /* Y pixels per meter */ - 17,0,0,0, /* colors used */ - 17,0,0,0, /* colors important */ - /* color table */ - 0,0,0,0, - 17,17,17,0, - 255,0,0,0, - 34,34,34,0, - 0,0,204,0, - 0,0,221,0, - 0,0,238,0, - 51,51,51,0, - 0,0,255,0, - 68,68,68,0, - 255,0,255,0, - 85,85,85,0, - 0,204,0,0, - 0,221,0,0, - 0,238,0,0, - 0,255,0,0, - 255,255,255,0, - /* bits */ - 4,15,0,4,11,9,9,0,0,0,4,14,0,4,3,10,10,7,0,0,4,13,0,4,3,10,10,7,0,0,4,12,0,4,0,1,1,11,0,0,0,4,16,2,16,2,4,4,0,0,0,4,2,16,2,16,4,5,0,0,0,4,16,2,16,2,4,6,0,0,0,4,2,16,2,16,4,8,0,1 -}; - -static void test_decode_rle8(void) -{ - IWICBitmapDecoder *decoder, *decoder2; - IWICBitmapFrameDecode *framedecode; - HRESULT hr; - HGLOBAL hbmpdata; - char *bmpdata; - IStream *bmpstream; - DWORD capability=0; - GUID guidresult; - UINT count=0, width=0, height=0; - double dpiX, dpiY; - DWORD imagedata[64] = {1}; - const DWORD expected_imagedata[64] = { - 0x0000ff,0xffffff,0x0000ff,0xffffff,0xff0000,0xff0000,0xff0000,0xff0000, - 0xffffff,0x0000ff,0xffffff,0x0000ff,0xee0000,0xee0000,0xee0000,0xee0000, - 0x0000ff,0xffffff,0x0000ff,0xffffff,0xdd0000,0xdd0000,0xdd0000,0xdd0000, - 0xffffff,0x0000ff,0xffffff,0x0000ff,0xcc0000,0xcc0000,0xcc0000,0xcc0000, - 0x00cc00,0x00cc00,0x00cc00,0x00cc00,0x000000,0x111111,0x111111,0x555555, - 0x00dd00,0x00dd00,0x00dd00,0x00dd00,0x222222,0xff00ff,0xff00ff,0x333333, - 0x00ee00,0x00ee00,0x00ee00,0x00ee00,0x222222,0xff00ff,0xff00ff,0x333333, - 0x00ff00,0x00ff00,0x00ff00,0x00ff00,0x555555,0x444444,0x444444,0x000000}; - WICColor palettedata[17] = {1}; - const WICColor expected_palettedata[17] = { - 0xff000000,0xff111111,0xff0000ff,0xff222222,0xffcc0000,0xffdd0000, - 0xffee0000,0xff333333,0xffff0000,0xff444444,0xffff00ff,0xff555555, - 0xff00cc00,0xff00dd00,0xff00ee00,0xff00ff00,0xffffffff}; - WICRect rc; - - hr = CoCreateInstance(&CLSID_WICBmpDecoder, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICBitmapDecoder, (void**)&decoder); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (!SUCCEEDED(hr)) return; - - hbmpdata = GlobalAlloc(GMEM_MOVEABLE, sizeof(testbmp_rle8)); - ok(hbmpdata != 0, "GlobalAlloc failed\n"); - if (hbmpdata) - { - bmpdata = GlobalLock(hbmpdata); - memcpy(bmpdata, testbmp_rle8, sizeof(testbmp_rle8)); - GlobalUnlock(hbmpdata); - - hr = CreateStreamOnHGlobal(hbmpdata, FALSE, &bmpstream); - ok(SUCCEEDED(hr), "CreateStreamOnHGlobal failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_Initialize(decoder, bmpstream, WICDecodeMetadataCacheOnLoad); - ok(hr == S_OK, "Initialize failed, hr=%x\n", hr); - - hr = IWICBitmapDecoder_GetContainerFormat(decoder, &guidresult); - ok(SUCCEEDED(hr), "GetContainerFormat failed, hr=%x\n", hr); - ok(IsEqualGUID(&guidresult, &GUID_ContainerFormatBmp), "unexpected container format\n"); - - hr = IWICBitmapDecoder_GetFrameCount(decoder, &count); - ok(SUCCEEDED(hr), "GetFrameCount failed, hr=%x\n", hr); - ok(count == 1, "unexpected count %u\n", count); - - hr = IWICBitmapDecoder_GetFrame(decoder, 0, &framedecode); - ok(SUCCEEDED(hr), "GetFrame failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - IWICImagingFactory *factory; - IWICPalette *palette; - - hr = IWICBitmapFrameDecode_GetSize(framedecode, &width, &height); - ok(SUCCEEDED(hr), "GetSize failed, hr=%x\n", hr); - ok(width == 8, "expected width=8, got %u\n", width); - ok(height == 8, "expected height=8, got %u\n", height); - - hr = IWICBitmapFrameDecode_GetResolution(framedecode, &dpiX, &dpiY); - ok(SUCCEEDED(hr), "GetResolution failed, hr=%x\n", hr); - ok(fabs(dpiX - 72.0) < 0.01, "expected dpiX=96.0, got %f\n", dpiX); - ok(fabs(dpiY - 72.0) < 0.01, "expected dpiY=96.0, got %f\n", dpiY); - - hr = IWICBitmapFrameDecode_GetPixelFormat(framedecode, &guidresult); - ok(SUCCEEDED(hr), "GetPixelFormat failed, hr=%x\n", hr); - ok(IsEqualGUID(&guidresult, &GUID_WICPixelFormat32bppBGR), "unexpected pixel format\n"); - - hr = CoCreateInstance(&CLSID_WICImagingFactory, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICImagingFactory, (void**)&factory); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICImagingFactory_CreatePalette(factory, &palette); - ok(SUCCEEDED(hr), "CreatePalette failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_CopyPalette(decoder, palette); - ok(hr == WINCODEC_ERR_PALETTEUNAVAILABLE, "expected WINCODEC_ERR_PALETTEUNAVAILABLE, got %x\n", hr); - - hr = IWICBitmapFrameDecode_CopyPalette(framedecode, palette); - ok(SUCCEEDED(hr), "CopyPalette failed, hr=%x\n", hr); - - hr = IWICPalette_GetColorCount(palette, &count); - ok(SUCCEEDED(hr), "GetColorCount failed, hr=%x\n", hr); - ok(count == 17, "expected count=17, got %u\n", count); - - hr = IWICPalette_GetColors(palette, 17, palettedata, &count); - ok(SUCCEEDED(hr), "GetColorCount failed, hr=%x\n", hr); - ok(count == 17, "expected count=17, got %u\n", count); - ok(!memcmp(palettedata, expected_palettedata, sizeof(palettedata)), "unexpected palette data\n"); - - IWICPalette_Release(palette); - } - - IWICImagingFactory_Release(factory); - } - - rc.X = 0; - rc.Y = 0; - rc.Width = 8; - rc.Height = 8; - hr = IWICBitmapFrameDecode_CopyPixels(framedecode, &rc, 32, sizeof(imagedata), (BYTE*)imagedata); - ok(SUCCEEDED(hr), "CopyPixels failed, hr=%x\n", hr); - ok(!memcmp(imagedata, expected_imagedata, sizeof(imagedata)), "unexpected image data\n"); - - IWICBitmapFrameDecode_Release(framedecode); - } - - hr = CoCreateInstance(&CLSID_WICBmpDecoder, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICBitmapDecoder, (void**)&decoder2); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_QueryCapability(decoder2, bmpstream, &capability); - ok(hr == S_OK, "QueryCapability failed, hr=%x\n", hr); - ok(capability == (WICBitmapDecoderCapabilityCanDecodeAllImages), - "unexpected capabilities: %x\n", capability); - } - - IStream_Release(bmpstream); - } - - GlobalFree(hbmpdata); - } - - IWICBitmapDecoder_Release(decoder); -} - -static const char testbmp_rle4[] = { - /* BITMAPFILEHEADER */ - 66,77, /* "BM" */ - 142,0,0,0, /* file size */ - 0,0,0,0, /* reserved */ - 78,0,0,0, /* offset to bits */ - /* BITMAPINFOHEADER */ - 40,0,0,0, /* header size */ - 8,0,0,0, /* width */ - 8,0,0,0, /* height */ - 1,0, /* planes */ - 4,0, /* bit count */ - 2,0,0,0, /* compression = BI_RLE4 */ - 64,0,0,0, /* image size */ - 19,11,0,0, /* X pixels per meter */ - 19,11,0,0, /* Y pixels per meter */ - 6,0,0,0, /* colors used */ - 6,0,0,0, /* colors important */ - /* color table */ - 0,0,0,0, - 255,0,0,0, - 0,0,255,0, - 255,0,255,0, - 0,255,0,0, - 255,255,255,0, - /* bits */ - 0,8,68,68,0,0,0,0,0,8,68,68,3,48,0,0,0,8,68,68,3,48,0,0,0,8,68,68,0,0,0,0,0,8,81,81,34,34,0,0,0,8,21,21,34,34,0,0,0,8,81,81,34,34,0,0,0,8,21,21,34,34,0,1 -}; - -static void test_decode_rle4(void) -{ - IWICBitmapDecoder *decoder, *decoder2; - IWICBitmapFrameDecode *framedecode; - HRESULT hr; - HGLOBAL hbmpdata; - char *bmpdata; - IStream *bmpstream; - DWORD capability=0; - GUID guidresult; - UINT count=0, width=0, height=0; - double dpiX, dpiY; - DWORD imagedata[64] = {1}; - const DWORD expected_imagedata[64] = { - 0x0000ff,0xffffff,0x0000ff,0xffffff,0xff0000,0xff0000,0xff0000,0xff0000, - 0xffffff,0x0000ff,0xffffff,0x0000ff,0xff0000,0xff0000,0xff0000,0xff0000, - 0x0000ff,0xffffff,0x0000ff,0xffffff,0xff0000,0xff0000,0xff0000,0xff0000, - 0xffffff,0x0000ff,0xffffff,0x0000ff,0xff0000,0xff0000,0xff0000,0xff0000, - 0x00ff00,0x00ff00,0x00ff00,0x00ff00,0x000000,0x000000,0x000000,0x000000, - 0x00ff00,0x00ff00,0x00ff00,0x00ff00,0x000000,0xff00ff,0xff00ff,0x000000, - 0x00ff00,0x00ff00,0x00ff00,0x00ff00,0x000000,0xff00ff,0xff00ff,0x000000, - 0x00ff00,0x00ff00,0x00ff00,0x00ff00,0x000000,0x000000,0x000000,0x000000}; - WICColor palettedata[6] = {1}; - const WICColor expected_palettedata[6] = { - 0xff000000,0xff0000ff,0xffff0000,0xffff00ff,0xff00ff00,0xffffffff}; - WICRect rc; - - hr = CoCreateInstance(&CLSID_WICBmpDecoder, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICBitmapDecoder, (void**)&decoder); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (!SUCCEEDED(hr)) return; - - hbmpdata = GlobalAlloc(GMEM_MOVEABLE, sizeof(testbmp_rle4)); - ok(hbmpdata != 0, "GlobalAlloc failed\n"); - if (hbmpdata) - { - bmpdata = GlobalLock(hbmpdata); - memcpy(bmpdata, testbmp_rle4, sizeof(testbmp_rle4)); - GlobalUnlock(hbmpdata); - - hr = CreateStreamOnHGlobal(hbmpdata, FALSE, &bmpstream); - ok(SUCCEEDED(hr), "CreateStreamOnHGlobal failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_Initialize(decoder, bmpstream, WICDecodeMetadataCacheOnLoad); - ok(hr == S_OK, "Initialize failed, hr=%x\n", hr); - - hr = IWICBitmapDecoder_GetContainerFormat(decoder, &guidresult); - ok(SUCCEEDED(hr), "GetContainerFormat failed, hr=%x\n", hr); - ok(IsEqualGUID(&guidresult, &GUID_ContainerFormatBmp), "unexpected container format\n"); - - hr = IWICBitmapDecoder_GetFrameCount(decoder, &count); - ok(SUCCEEDED(hr), "GetFrameCount failed, hr=%x\n", hr); - ok(count == 1, "unexpected count %u\n", count); - - hr = IWICBitmapDecoder_GetFrame(decoder, 0, &framedecode); - ok(SUCCEEDED(hr), "GetFrame failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - IWICImagingFactory *factory; - IWICPalette *palette; - - hr = IWICBitmapFrameDecode_GetSize(framedecode, &width, &height); - ok(SUCCEEDED(hr), "GetSize failed, hr=%x\n", hr); - ok(width == 8, "expected width=8, got %u\n", width); - ok(height == 8, "expected height=8, got %u\n", height); - - hr = IWICBitmapFrameDecode_GetResolution(framedecode, &dpiX, &dpiY); - ok(SUCCEEDED(hr), "GetResolution failed, hr=%x\n", hr); - ok(fabs(dpiX - 72.0) < 0.01, "expected dpiX=96.0, got %f\n", dpiX); - ok(fabs(dpiY - 72.0) < 0.01, "expected dpiY=96.0, got %f\n", dpiY); - - hr = IWICBitmapFrameDecode_GetPixelFormat(framedecode, &guidresult); - ok(SUCCEEDED(hr), "GetPixelFormat failed, hr=%x\n", hr); - ok(IsEqualGUID(&guidresult, &GUID_WICPixelFormat32bppBGR), "unexpected pixel format\n"); - - hr = CoCreateInstance(&CLSID_WICImagingFactory, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICImagingFactory, (void**)&factory); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICImagingFactory_CreatePalette(factory, &palette); - ok(SUCCEEDED(hr), "CreatePalette failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_CopyPalette(decoder, palette); - ok(hr == WINCODEC_ERR_PALETTEUNAVAILABLE, "expected WINCODEC_ERR_PALETTEUNAVAILABLE, got %x\n", hr); - - hr = IWICBitmapFrameDecode_CopyPalette(framedecode, palette); - ok(SUCCEEDED(hr), "CopyPalette failed, hr=%x\n", hr); - - hr = IWICPalette_GetColorCount(palette, &count); - ok(SUCCEEDED(hr), "GetColorCount failed, hr=%x\n", hr); - ok(count == 6, "expected count=6, got %u\n", count); - - hr = IWICPalette_GetColors(palette, 6, palettedata, &count); - ok(SUCCEEDED(hr), "GetColorCount failed, hr=%x\n", hr); - ok(count == 6, "expected count=6, got %u\n", count); - ok(!memcmp(palettedata, expected_palettedata, sizeof(palettedata)), "unexpected palette data\n"); - - IWICPalette_Release(palette); - } - - IWICImagingFactory_Release(factory); - } - - rc.X = 0; - rc.Y = 0; - rc.Width = 8; - rc.Height = 8; - hr = IWICBitmapFrameDecode_CopyPixels(framedecode, &rc, 32, sizeof(imagedata), (BYTE*)imagedata); - ok(SUCCEEDED(hr), "CopyPixels failed, hr=%x\n", hr); - ok(!memcmp(imagedata, expected_imagedata, sizeof(imagedata)), "unexpected image data\n"); - - IWICBitmapFrameDecode_Release(framedecode); - } - - hr = CoCreateInstance(&CLSID_WICBmpDecoder, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICBitmapDecoder, (void**)&decoder2); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICBitmapDecoder_QueryCapability(decoder2, bmpstream, &capability); - ok(hr == S_OK, "QueryCapability failed, hr=%x\n", hr); - ok(capability == (WICBitmapDecoderCapabilityCanDecodeAllImages), - "unexpected capabilities: %x\n", capability); - } - - IStream_Release(bmpstream); - } - - GlobalFree(hbmpdata); - } - - IWICBitmapDecoder_Release(decoder); -} - -START_TEST(bmpformat) -{ - CoInitializeEx(NULL, COINIT_APARTMENTTHREADED); - - test_decode_24bpp(); - test_decode_1bpp(); - test_decode_4bpp(); - test_decode_rle8(); - test_decode_rle4(); - - CoUninitialize(); -} diff --git a/dlls/windowscodecs/tests/palette.c b/dlls/windowscodecs/tests/palette.c deleted file mode 100644 index d1e5c8800bf..00000000000 --- a/dlls/windowscodecs/tests/palette.c +++ /dev/null @@ -1,158 +0,0 @@ -/* - * Copyright 2009 Vincent Povirk for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include - -#define COBJMACROS - -#include "windef.h" -#include "objbase.h" -#include "wincodec.h" -#include "wine/test.h" - -static void test_custom_palette(void) -{ - IWICImagingFactory *factory; - IWICPalette *palette; - HRESULT hr; - WICBitmapPaletteType type=0xffffffff; - UINT count=1; - const WICColor initcolors[4]={0xff000000,0xff0000ff,0xffffff00,0xffffffff}; - WICColor colors[4]; - BOOL boolresult; - - hr = CoCreateInstance(&CLSID_WICImagingFactory, NULL, CLSCTX_INPROC_SERVER, - &IID_IWICImagingFactory, (void**)&factory); - ok(SUCCEEDED(hr), "CoCreateInstance failed, hr=%x\n", hr); - if (!SUCCEEDED(hr)) return; - - hr = IWICImagingFactory_CreatePalette(factory, &palette); - ok(SUCCEEDED(hr), "CreatePalette failed, hr=%x\n", hr); - if (SUCCEEDED(hr)) - { - hr = IWICPalette_GetType(palette, &type); - ok(SUCCEEDED(hr), "GetType failed, hr=%x\n", hr); - ok(type == WICBitmapPaletteTypeCustom, "expected WICBitmapPaletteTypeCustom, got %x\n", type); - - hr = IWICPalette_GetColorCount(palette, &count); - ok(SUCCEEDED(hr), "GetColorCount failed, hr=%x\n", hr); - ok(count == 0, "expected 0, got %u\n", count); - - hr = IWICPalette_GetColors(palette, 0, colors, &count); - ok(SUCCEEDED(hr), "GetColors failed, hr=%x\n", hr); - ok(count == 0, "expected 0, got %u\n", count); - - hr = IWICPalette_GetColors(palette, 4, colors, &count); - ok(SUCCEEDED(hr), "GetColors failed, hr=%x\n", hr); - ok(count == 0, "expected 0, got %u\n", count); - - memcpy(colors, initcolors, sizeof(initcolors)); - hr = IWICPalette_InitializeCustom(palette, colors, 4); - ok(SUCCEEDED(hr), "InitializeCustom failed, hr=%x\n", hr); - - hr = IWICPalette_GetType(palette, &type); - ok(SUCCEEDED(hr), "GetType failed, hr=%x\n", hr); - ok(type == WICBitmapPaletteTypeCustom, "expected WICBitmapPaletteTypeCustom, got %x\n", type); - - hr = IWICPalette_GetColorCount(palette, &count); - ok(SUCCEEDED(hr), "GetColorCount failed, hr=%x\n", hr); - ok(count == 4, "expected 4, got %u\n", count); - - memset(colors, 0, sizeof(colors)); - count = 0; - hr = IWICPalette_GetColors(palette, 4, colors, &count); - ok(SUCCEEDED(hr), "GetColors failed, hr=%x\n", hr); - ok(count == 4, "expected 4, got %u\n", count); - ok(!memcmp(colors, initcolors, sizeof(colors)), "got unexpected palette data\n"); - - memset(colors, 0, sizeof(colors)); - count = 0; - hr = IWICPalette_GetColors(palette, 2, colors, &count); - ok(SUCCEEDED(hr), "GetColors failed, hr=%x\n", hr); - ok(count == 2, "expected 2, got %u\n", count); - ok(!memcmp(colors, initcolors, sizeof(WICColor)*2), "got unexpected palette data\n"); - - count = 0; - hr = IWICPalette_GetColors(palette, 6, colors, &count); - ok(SUCCEEDED(hr), "GetColors failed, hr=%x\n", hr); - ok(count == 4, "expected 4, got %u\n", count); - - hr = IWICPalette_HasAlpha(palette, &boolresult); - ok(SUCCEEDED(hr), "HasAlpha failed, hr=%x\n", hr); - ok(!boolresult, "expected FALSE, got TRUE\n"); - - hr = IWICPalette_IsBlackWhite(palette, &boolresult); - ok(SUCCEEDED(hr), "IsBlackWhite failed, hr=%x\n", hr); - ok(!boolresult, "expected FALSE, got TRUE\n"); - - hr = IWICPalette_IsGrayscale(palette, &boolresult); - ok(SUCCEEDED(hr), "IsGrayscale failed, hr=%x\n", hr); - ok(!boolresult, "expected FALSE, got TRUE\n"); - - /* try a palette with some alpha in it */ - colors[2] = 0x80ffffff; - hr = IWICPalette_InitializeCustom(palette, colors, 4); - ok(SUCCEEDED(hr), "InitializeCustom failed, hr=%x\n", hr); - - hr = IWICPalette_HasAlpha(palette, &boolresult); - ok(SUCCEEDED(hr), "HasAlpha failed, hr=%x\n", hr); - ok(boolresult, "expected TRUE, got FALSE\n"); - - /* setting to a 0-color palette is acceptable */ - hr = IWICPalette_InitializeCustom(palette, NULL, 0); - ok(SUCCEEDED(hr), "InitializeCustom failed, hr=%x\n", hr); - - /* IWICPalette is paranoid about NULL pointers */ - hr = IWICPalette_GetType(palette, NULL); - ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got %x\n", hr); - - hr = IWICPalette_GetColorCount(palette, NULL); - ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got %x\n", hr); - - hr = IWICPalette_InitializeCustom(palette, NULL, 4); - ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got %x\n", hr); - - hr = IWICPalette_GetColors(palette, 4, NULL, &count); - ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got %x\n", hr); - - hr = IWICPalette_GetColors(palette, 4, colors, NULL); - ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got %x\n", hr); - - hr = IWICPalette_HasAlpha(palette, NULL); - ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got %x\n", hr); - - hr = IWICPalette_IsBlackWhite(palette, NULL); - ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got %x\n", hr); - - hr = IWICPalette_IsGrayscale(palette, NULL); - ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got %x\n", hr); - - IWICPalette_Release(palette); - } - - IWICImagingFactory_Release(factory); -} - -START_TEST(palette) -{ - CoInitializeEx(NULL, COINIT_APARTMENTTHREADED); - - test_custom_palette(); - - CoUninitialize(); -} diff --git a/dlls/windowscodecs/wincodecs_private.h b/dlls/windowscodecs/wincodecs_private.h deleted file mode 100644 index a6e09ffe3d5..00000000000 --- a/dlls/windowscodecs/wincodecs_private.h +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright 2009 Vincent Povirk for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#ifndef WINCODECS_PRIVATE_H -#define WINCODECS_PRIVATE_H - -extern HRESULT ImagingFactory_CreateInstance(IUnknown *pUnkOuter, REFIID riid, void** ppv); -extern HRESULT BmpDecoder_CreateInstance(IUnknown *pUnkOuter, REFIID riid, void** ppv); - -extern HRESULT PaletteImpl_Create(IWICPalette **palette); - -extern HRESULT copy_pixels(UINT bpp, const BYTE *srcbuffer, - UINT srcwidth, UINT srcheight, INT srcstride, - const WICRect *rc, UINT dststride, UINT dstbuffersize, BYTE *dstbuffer); - -#endif /* WINCODECS_PRIVATE_H */ diff --git a/dlls/windowscodecs/windowscodecs.spec b/dlls/windowscodecs/windowscodecs.spec index 8e3729eb4f1..8fc2026a1b4 100644 --- a/dlls/windowscodecs/windowscodecs.spec +++ b/dlls/windowscodecs/windowscodecs.spec @@ -1,6 +1,4 @@ -@ stdcall -private DllGetClassObject(ptr ptr ptr) -@ stdcall -private DllRegisterServer() -@ stdcall -private DllUnregisterServer() +@ stub DllGetClassObject @ stub IEnumString_Next_WIC_Proxy @ stub IEnumString_Reset_WIC_Proxy @ stub IPropertyBag2_Write_Proxy diff --git a/dlls/winealsa.drv/Makefile.in b/dlls/winealsa.drv/Makefile.in index 1f7a78d4f14..3e07ef2a219 100644 --- a/dlls/winealsa.drv/Makefile.in +++ b/dlls/winealsa.drv/Makefile.in @@ -12,8 +12,8 @@ C_SRCS = \ dsoutput.c \ midi.c \ mixer.c \ - wavein.c \ waveinit.c \ + wavein.c \ waveout.c @MAKE_DLL_RULES@ diff --git a/dlls/winealsa.drv/dsoutput.c b/dlls/winealsa.drv/dsoutput.c index dd95ad03aa6..15cff5f1fbf 100644 --- a/dlls/winealsa.drv/dsoutput.c +++ b/dlls/winealsa.drv/dsoutput.c @@ -83,9 +83,8 @@ struct IDsDriverBufferImpl IDsDriverImpl* drv; CRITICAL_SECTION pcm_crst; - BYTE *mmap_buffer; + LPVOID mmap_buffer; DWORD mmap_buflen_bytes; - BOOL mmap; snd_pcm_t *pcm; snd_pcm_hw_params_t *hw_params; @@ -103,44 +102,25 @@ struct IDsDriverBufferImpl static snd_pcm_uframes_t CommitAll(IDsDriverBufferImpl *This) { const snd_pcm_channel_area_t *areas; - snd_pcm_sframes_t used; + snd_pcm_uframes_t used; const snd_pcm_uframes_t commitahead = This->mmap_commitahead; used = This->mmap_buflen_frames - snd_pcm_avail_update(This->pcm); - if (used < 0) used = 0; - TRACE("%p needs to commit to %lu, used: %ld\n", This, commitahead, used); + TRACE("%p needs to commit to %lu, used: %lu\n", This, commitahead, used); if (used < commitahead) { snd_pcm_uframes_t done, putin = commitahead - used; - if (This->mmap) - { - snd_pcm_mmap_begin(This->pcm, &areas, &This->mmap_pos, &putin); - done = snd_pcm_mmap_commit(This->pcm, This->mmap_pos, putin); - } - else - { - if (putin + This->mmap_pos > This->mmap_buflen_frames) - putin = This->mmap_buflen_frames - This->mmap_pos; - done = putin; - snd_pcm_writei(This->pcm, This->mmap_buffer + snd_pcm_frames_to_bytes(This->pcm, This->mmap_pos), putin); - } + snd_pcm_mmap_begin(This->pcm, &areas, &This->mmap_pos, &putin); + done = snd_pcm_mmap_commit(This->pcm, This->mmap_pos, putin); This->mmap_pos += done; used += done; putin = commitahead - used; if (This->mmap_pos == This->mmap_buflen_frames && (snd_pcm_sframes_t)putin > 0) { - if (This->mmap) - { - snd_pcm_mmap_begin(This->pcm, &areas, &This->mmap_pos, &putin); - done = snd_pcm_mmap_commit(This->pcm, This->mmap_pos, putin); - This->mmap_pos += done; - } - else - { - snd_pcm_writei(This->pcm, This->mmap_buffer, putin); - This->mmap_pos = done = putin; - } + snd_pcm_mmap_begin(This->pcm, &areas, &This->mmap_pos, &putin); + done = snd_pcm_mmap_commit(This->pcm, This->mmap_pos, putin); + This->mmap_pos += done; used += done; } } @@ -196,7 +176,6 @@ static int DSDB_CreateMMAP(IDsDriverBufferImpl* pdbi) const snd_pcm_channel_area_t *areas; snd_pcm_hw_params_t *hw_params = pdbi->hw_params; snd_pcm_sw_params_t *sw_params = pdbi->sw_params; - void *buf; mmap_mode = snd_pcm_type(pcm); @@ -239,27 +218,15 @@ static int DSDB_CreateMMAP(IDsDriverBufferImpl* pdbi) ERR("No buffer is available: %s.\n", snd_strerror(avail)); return DSERR_GENERIC; } - - if (!pdbi->mmap) + err = snd_pcm_mmap_begin(pcm, &areas, &ofs, &avail); + if ( err < 0 ) { - buf = pdbi->mmap_buffer = HeapAlloc(GetProcessHeap(), 0, pdbi->mmap_buflen_bytes); - if (!buf) - return DSERR_OUTOFMEMORY; - - snd_pcm_format_set_silence(format, buf, pdbi->mmap_buflen_frames); - } - else - { - err = snd_pcm_mmap_begin(pcm, &areas, &ofs, &avail); - if ( err < 0 ) - { - ERR("Can't map sound device for direct access: %s/%d\n", snd_strerror(err), err); - return DSERR_GENERIC; - } - snd_pcm_format_set_silence(format, areas->addr, pdbi->mmap_buflen_frames); - pdbi->mmap_pos = ofs + snd_pcm_mmap_commit(pcm, ofs, 0); - pdbi->mmap_buffer = areas->addr; + ERR("Can't map sound device for direct access: %s\n", snd_strerror(err)); + return DSERR_GENERIC; } + snd_pcm_format_set_silence(format, areas->addr, pdbi->mmap_buflen_frames); + pdbi->mmap_pos = ofs + snd_pcm_mmap_commit(pcm, ofs, 0); + pdbi->mmap_buffer = areas->addr; TRACE("created mmap buffer of %ld frames (%d bytes) at %p\n", frames, pdbi->mmap_buflen_bytes, pdbi->mmap_buffer); @@ -307,8 +274,6 @@ static ULONG WINAPI IDsDriverBufferImpl_Release(PIDSDRIVERBUFFER iface) This->pcm = NULL; HeapFree(GetProcessHeap(), 0, This->sw_params); HeapFree(GetProcessHeap(), 0, This->hw_params); - if (!This->mmap) - HeapFree(GetProcessHeap(), 0, This->mmap_buffer); HeapFree(GetProcessHeap(), 0, This); return 0; } @@ -340,7 +305,7 @@ static HRESULT WINAPI IDsDriverBufferImpl_Lock(PIDSDRIVERBUFFER iface, if (ppvAudio2) *ppvAudio2 = NULL; if (pdwLen2) *pdwLen2 = 0; - *ppvAudio1 = This->mmap_buffer + dwWritePosition; + *ppvAudio1 = (LPBYTE)This->mmap_buffer + dwWritePosition; *pdwLen1 = dwWriteLen; if (dwWritePosition+dwWriteLen > This->mmap_buflen_bytes) @@ -362,8 +327,7 @@ static HRESULT WINAPI IDsDriverBufferImpl_Lock(PIDSDRIVERBUFFER iface, const snd_pcm_channel_area_t *areas; snd_pcm_uframes_t writelen = snd_pcm_bytes_to_frames(This->pcm, dwWriteLen), putin = writelen; TRACE("Hit mmap_pos, locking data!\n"); - if (This->mmap) - snd_pcm_mmap_begin(This->pcm, &areas, &This->mmap_pos, &putin); + snd_pcm_mmap_begin(This->pcm, &areas, &This->mmap_pos, &putin); } else WARN("mmap_pos (%lu) != writepos (%lu) not locking data!\n", This->mmap_pos, writepos); @@ -392,40 +356,14 @@ static HRESULT WINAPI IDsDriverBufferImpl_Unlock(PIDSDRIVERBUFFER iface, const snd_pcm_channel_area_t *areas; snd_pcm_uframes_t writelen = snd_pcm_bytes_to_frames(This->pcm, dwLen1); TRACE("Committing data\n"); - if (This->mmap) - This->mmap_pos += snd_pcm_mmap_commit(This->pcm, This->mmap_pos, writelen); - else - { - int ret; - ret = snd_pcm_writei(This->pcm, pvAudio1, writelen); - if (ret == -EPIPE) - { - WARN("Underrun occured\n"); - snd_pcm_prepare(This->pcm); - ret = snd_pcm_writei(This->pcm, pvAudio1, writelen); - snd_pcm_start(This->pcm); - } - if (ret < 0) - WARN("Committing data: %d / %s (%p %ld)\n", ret, snd_strerror(ret), pvAudio1, writelen); - This->mmap_pos += writelen; - } - + This->mmap_pos += snd_pcm_mmap_commit(This->pcm, This->mmap_pos, writelen); if (This->mmap_pos == This->mmap_buflen_frames) This->mmap_pos = 0; if (!This->mmap_pos && dwLen2) { writelen = snd_pcm_bytes_to_frames(This->pcm, dwLen2); - if (This->mmap) - { - snd_pcm_mmap_begin(This->pcm, &areas, &This->mmap_pos, &writelen); - This->mmap_pos += snd_pcm_mmap_commit(This->pcm, This->mmap_pos, writelen); - } - else - { - int ret; - ret = snd_pcm_writei(This->pcm, pvAudio2, writelen); - This->mmap_pos = writelen; - } + snd_pcm_mmap_begin(This->pcm, &areas, &This->mmap_pos, &writelen); + This->mmap_pos += snd_pcm_mmap_commit(This->pcm, This->mmap_pos, writelen); assert(This->mmap_pos < This->mmap_buflen_frames); } } @@ -504,30 +442,13 @@ static HRESULT SetFormat(IDsDriverBufferImpl *This, LPWAVEFORMATEX pwfx) snd_pcm_hw_params_set_buffer_time_near(pcm, hw_params, &buffer_time, NULL); buffer_time = 10000; snd_pcm_hw_params_set_period_time_near(pcm, hw_params, &buffer_time, NULL); - - err = snd_pcm_hw_params_get_period_size(hw_params, &psize, NULL); - buffer_time = 16; - snd_pcm_hw_params_set_periods_near(pcm, hw_params, &buffer_time, NULL); - - if (!This->mmap) - { - HeapFree(GetProcessHeap(), 0, This->mmap_buffer); - This->mmap_buffer = NULL; - } - - err = snd_pcm_hw_params_set_access (pcm, hw_params, SND_PCM_ACCESS_MMAP_INTERLEAVED); - if (err >= 0) - This->mmap = 1; - else - { - This->mmap = 0; - err = snd_pcm_hw_params_set_access (pcm, hw_params, SND_PCM_ACCESS_RW_INTERLEAVED); - } - err = snd_pcm_hw_params(pcm, hw_params); err = snd_pcm_sw_params(pcm, This->sw_params); snd_pcm_prepare(pcm); + err = snd_pcm_hw_params_get_period_size(hw_params, &psize, NULL); + TRACE("Period size is: %lu\n", psize); + /* ALSA needs at least 3 buffers to work successfully */ This->mmap_commitahead = 3 * psize; while (This->mmap_commitahead <= 512) @@ -632,13 +553,9 @@ static HRESULT WINAPI IDsDriverBufferImpl_GetPosition(PIDSDRIVERBUFFER iface, if (used < 0) { - WARN("Underrun: %ld / %ld\n", used, snd_pcm_avail_update(This->pcm)); - if (This->mmap) - { - snd_pcm_forward(This->pcm, -used); - This->mmap_pos += -used; - This->mmap_pos %= This->mmap_buflen_frames; - } + This->mmap_pos += -used; + snd_pcm_forward(This->pcm, -used); + This->mmap_pos %= This->mmap_buflen_frames; used = 0; } @@ -692,19 +609,10 @@ static HRESULT WINAPI IDsDriverBufferImpl_Stop(PIDSDRIVERBUFFER iface) snd_pcm_drop(This->pcm); snd_pcm_prepare(This->pcm); avail = snd_pcm_avail_update(This->pcm); + snd_pcm_mmap_begin(This->pcm, &areas, &This->mmap_pos, &avail); snd_pcm_hw_params_get_format(This->hw_params, &format); - if (This->mmap) - { - snd_pcm_mmap_begin(This->pcm, &areas, &This->mmap_pos, &avail); - snd_pcm_format_set_silence(format, areas->addr, This->mmap_buflen_frames); - snd_pcm_mmap_commit(This->pcm, This->mmap_pos, 0); - } - else - { - snd_pcm_format_set_silence(format, This->mmap_buffer, This->mmap_buflen_frames); - snd_pcm_writei(This->pcm, This->mmap_buffer, This->mmap_buflen_frames); - This->mmap_pos = 0; - } + snd_pcm_format_set_silence(format, areas->addr, This->mmap_buflen_frames); + snd_pcm_mmap_commit(This->pcm, This->mmap_pos, 0); /* **** */ LeaveCriticalSection(&This->pcm_crst); @@ -802,8 +710,6 @@ static HRESULT WINAPI IDsDriverImpl_Open(PIDSDRIVER iface) err = snd_pcm_hw_params_any(pcm, hw_params); if (err < 0) goto err; err = snd_pcm_hw_params_set_access (pcm, hw_params, SND_PCM_ACCESS_MMAP_INTERLEAVED); - if (err < 0) - err = snd_pcm_hw_params_set_access (pcm, hw_params, SND_PCM_ACCESS_RW_INTERLEAVED); if (err < 0) goto err; TRACE("Success\n"); diff --git a/dlls/wined3d/Makefile.in b/dlls/wined3d/Makefile.in index cdafc914cfd..2fcb4ec0f07 100644 --- a/dlls/wined3d/Makefile.in +++ b/dlls/wined3d/Makefile.in @@ -29,12 +29,12 @@ C_SRCS = \ shader_sm4.c \ state.c \ stateblock.c \ - surface.c \ surface_base.c \ + surface.c \ surface_gdi.c \ swapchain.c \ - swapchain_base.c \ swapchain_gdi.c \ + swapchain_base.c \ texture.c \ utils.c \ vertexdeclaration.c \ diff --git a/dlls/wined3d/arb_program_shader.c b/dlls/wined3d/arb_program_shader.c index 682624bd605..c886195f254 100644 --- a/dlls/wined3d/arb_program_shader.c +++ b/dlls/wined3d/arb_program_shader.c @@ -42,26 +42,22 @@ WINE_DECLARE_DEBUG_CHANNEL(d3d); #define GLINFO_LOCATION (*gl_info) /* GL locking for state handlers is done by the caller. */ -static BOOL need_mova_const(IWineD3DBaseShader *shader, const struct wined3d_gl_info *gl_info) -{ +static BOOL need_mova_const(IWineD3DBaseShader *shader, const WineD3D_GL_Info *gl_info) { IWineD3DBaseShaderImpl *This = (IWineD3DBaseShaderImpl *) shader; if(!This->baseShader.reg_maps.usesmova) return FALSE; return !GL_SUPPORT(NV_VERTEX_PROGRAM2_OPTION); } -static BOOL need_helper_const(const struct wined3d_gl_info *gl_info) -{ - if (!GL_SUPPORT(NV_VERTEX_PROGRAM) /* Need to init colors. */ - || gl_info->quirks & WINED3D_QUIRK_ARB_VS_OFFSET_LIMIT /* Load the immval offset. */ - || gl_info->quirks & WINED3D_QUIRK_SET_TEXCOORD_W) /* Have to init texcoords. */ - { +static BOOL need_helper_const(const WineD3D_GL_Info *gl_info) { + if(!GL_SUPPORT(NV_VERTEX_PROGRAM) || /* Need to init colors */ + gl_info->arb_vs_offset_limit || /* Have to init texcoords */ + gl_info->set_texcoord_w) { /* Load the immval offset */ return TRUE; } return FALSE; } -static unsigned int reserved_vs_const(IWineD3DBaseShader *shader, const struct wined3d_gl_info *gl_info) -{ +static unsigned int reserved_vs_const(IWineD3DBaseShader *shader, const WineD3D_GL_Info *gl_info) { unsigned int ret = 1; /* We use one PARAM for the pos fixup, and in some cases one to load * some immediate values into the shader @@ -76,12 +72,6 @@ static inline BOOL ffp_clip_emul(IWineD3DStateBlockImpl *stateblock) return stateblock->lowest_disabled_stage < 7; } -/* Returns TRUE if result.clip from GL_NV_vertex_program2 should be used and FALSE otherwise */ -static inline BOOL use_nv_clip(const struct wined3d_gl_info *gl_info) -{ - return GL_SUPPORT(NV_VERTEX_PROGRAM2_OPTION); -} - /* Internally used shader constants. Applications can use constants 0 to GL_LIMITS(vshader_constantsF) - 1, * so upload them above that */ @@ -89,14 +79,6 @@ static inline BOOL use_nv_clip(const struct wined3d_gl_info *gl_info) #define ARB_SHADER_PRIVCONST_POS ARB_SHADER_PRIVCONST_BASE + 0 /* ARB_program_shader private data */ - -struct loop_control -{ - unsigned int count; - unsigned int start; - int step; -}; - struct control_frame { struct list entry; @@ -114,20 +96,10 @@ struct control_frame unsigned int loop_no; unsigned int ifc_no; }; - struct loop_control loop_control; + DWORD loop_control[3]; BOOL had_else; }; -struct arb_ps_np2fixup_info -{ - struct ps_np2fixup_info super; - /* For ARB we need a offset value: - * With both GLSL and ARB mode the NP2 fixup information (the texture dimensions) are stored in a - * consecutive way (GLSL uses a uniform array). Since ARB doesn't know the notion of a "standalone" - * array we need an offset to the index inside the program local parameter array. */ - UINT offset; -}; - struct arb_ps_compile_args { struct ps_compile_args super; @@ -144,14 +116,13 @@ struct stb_const_desc struct arb_ps_compiled_shader { struct arb_ps_compile_args args; - struct arb_ps_np2fixup_info np2fixup_info; + GLuint prgId; struct stb_const_desc bumpenvmatconst[MAX_TEXTURES]; + unsigned char numbumpenvmatconsts; struct stb_const_desc luminanceconst[MAX_TEXTURES]; UINT int_consts[MAX_CONST_I]; - GLuint prgId; - UINT ycorrection; - unsigned char numbumpenvmatconsts; char num_int_consts; + UINT ycorrection; }; struct arb_vs_compile_args @@ -181,8 +152,6 @@ struct arb_vs_compiled_shader GLuint prgId; UINT int_consts[MAX_CONST_I]; char num_int_consts; - char need_color_unclamp; - UINT pos_fixup; }; struct recorded_instruction @@ -208,7 +177,6 @@ struct shader_arb_ctx_priv const struct arb_ps_compile_args *cur_ps_args; const struct arb_ps_compiled_shader *compiled_fprog; const struct arb_vs_compiled_shader *compiled_vprog; - struct arb_ps_np2fixup_info *cur_np2fixup_info; struct list control_frames; struct list record; BOOL recording; @@ -216,10 +184,6 @@ struct shader_arb_ctx_priv unsigned int num_loops, loop_depth, num_ifcs; int aL; - unsigned int vs_clipplanes; - BOOL footer_written; - BOOL in_main_func; - /* For 3.0 vertex shaders */ const char *vs_output[MAX_REG_OUTPUT]; /* For 2.x and earlier vertex shaders */ @@ -242,7 +206,6 @@ struct arb_pshader_private { BOOL has_signature_idx; DWORD input_signature_idx; DWORD clipplane_emulation; - BOOL clamp_consts; }; struct arb_vshader_private { @@ -260,8 +223,6 @@ struct shader_arb_priv GLuint depth_blt_fprogram_id[tex_type_count]; BOOL use_arbfp_fixed_func; struct wine_rb_tree fragment_shaders; - BOOL last_ps_const_clamped; - BOOL last_vs_color_unclamp; struct wine_rb_tree signature_tree; DWORD ps_sig_number; @@ -279,7 +240,7 @@ struct shader_arb_priv * or GL_FRAGMENT_PROGRAM_ARB (for pixel shaders) */ /* GL locking is done by the caller */ -static unsigned int shader_arb_load_constantsF(IWineD3DBaseShaderImpl *This, const struct wined3d_gl_info *gl_info, +static unsigned int shader_arb_load_constantsF(IWineD3DBaseShaderImpl* This, const WineD3D_GL_Info *gl_info, GLuint target_type, unsigned int max_constants, const float *constants, char *dirty_consts) { local_constant* lconst; @@ -303,20 +264,20 @@ static unsigned int shader_arb_load_constantsF(IWineD3DBaseShaderImpl *This, con dirty_consts[i] = 0; j = 4 * i; - if (constants[j + 0] > 1.0f) lcl_const[0] = 1.0f; - else if (constants[j + 0] < -1.0f) lcl_const[0] = -1.0f; + if(constants[j + 0] > 1.0) lcl_const[0] = 1.0; + else if(constants[j + 0] < -1.0) lcl_const[0] = -1.0; else lcl_const[0] = constants[j + 0]; - if (constants[j + 1] > 1.0f) lcl_const[1] = 1.0f; - else if (constants[j + 1] < -1.0f) lcl_const[1] = -1.0f; + if(constants[j + 1] > 1.0) lcl_const[1] = 1.0; + else if(constants[j + 1] < -1.0) lcl_const[1] = -1.0; else lcl_const[1] = constants[j + 1]; - if (constants[j + 2] > 1.0f) lcl_const[2] = 1.0f; - else if (constants[j + 2] < -1.0f) lcl_const[2] = -1.0f; + if(constants[j + 2] > 1.0) lcl_const[2] = 1.0; + else if(constants[j + 2] < -1.0) lcl_const[2] = -1.0; else lcl_const[2] = constants[j + 2]; - if (constants[j + 3] > 1.0f) lcl_const[3] = 1.0f; - else if (constants[j + 3] < -1.0f) lcl_const[3] = -1.0f; + if(constants[j + 3] > 1.0) lcl_const[3] = 1.0; + else if(constants[j + 3] < -1.0) lcl_const[3] = -1.0; else lcl_const[3] = constants[j + 3]; GL_EXTCALL(glProgramEnvParameter4fvARB(target_type, i, lcl_const)); @@ -381,54 +342,13 @@ static void shader_arb_load_np2fixup_constants( IWineD3DDevice* device, char usePixelShader, char useVertexShader) { - - IWineD3DDeviceImpl* deviceImpl = (IWineD3DDeviceImpl *) device; - const struct shader_arb_priv* const priv = (const struct shader_arb_priv *) deviceImpl->shader_priv; - IWineD3DStateBlockImpl* stateBlock = deviceImpl->stateBlock; - const struct wined3d_gl_info *gl_info = &deviceImpl->adapter->gl_info; - - if (!usePixelShader) { - /* NP2 texcoord fixup is (currently) only done for pixelshaders. */ - return; - } - - if (priv->compiled_fprog && priv->compiled_fprog->np2fixup_info.super.active) { - const struct arb_ps_np2fixup_info* const fixup = &priv->compiled_fprog->np2fixup_info; - UINT i; - WORD active = fixup->super.active; - GLfloat np2fixup_constants[4 * MAX_FRAGMENT_SAMPLERS]; - - for (i = 0; active; active >>= 1, ++i) { - const unsigned char idx = fixup->super.idx[i]; - const IWineD3DTextureImpl* const tex = (const IWineD3DTextureImpl*) stateBlock->textures[i]; - GLfloat* tex_dim = &np2fixup_constants[(idx >> 1) * 4]; - - if (!(active & 1)) continue; - - if (!tex) { - FIXME("Nonexistent texture is flagged for NP2 texcoord fixup\n"); - continue; - } - - if (idx % 2) { - tex_dim[2] = tex->baseTexture.pow2Matrix[0]; tex_dim[3] = tex->baseTexture.pow2Matrix[5]; - } else { - tex_dim[0] = tex->baseTexture.pow2Matrix[0]; tex_dim[1] = tex->baseTexture.pow2Matrix[5]; - } - } - - for (i = 0; i < fixup->super.num_consts; ++i) { - GL_EXTCALL(glProgramEnvParameter4fvARB(GL_FRAGMENT_PROGRAM_ARB, - fixup->offset + i, &np2fixup_constants[i * 4])); - } - } + /* not implemented */ } -/* GL locking is done by the caller. */ static inline void shader_arb_ps_local_constants(IWineD3DDeviceImpl* deviceImpl) { IWineD3DStateBlockImpl* stateBlock = deviceImpl->stateBlock; - const struct wined3d_gl_info *gl_info = &deviceImpl->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &deviceImpl->adapter->gl_info; unsigned char i; struct shader_arb_priv *priv = deviceImpl->shader_priv; const struct arb_ps_compiled_shader *gl_shader = priv->compiled_fprog; @@ -452,7 +372,7 @@ static inline void shader_arb_ps_local_constants(IWineD3DDeviceImpl* deviceImpl) GL_EXTCALL(glProgramLocalParameter4fvARB(GL_FRAGMENT_PROGRAM_ARB, gl_shader->luminanceconst[i].const_num, scale)); } } - checkGLcall("Load bumpmap consts"); + checkGLcall("Load bumpmap consts\n"); if(gl_shader->ycorrection != WINED3D_CONST_NUM_UNUSED) { @@ -462,12 +382,12 @@ static inline void shader_arb_ps_local_constants(IWineD3DDeviceImpl* deviceImpl) * ycorrection.w: 0.0 */ float val[4]; - val[0] = deviceImpl->render_offscreen ? 0.0f : ((IWineD3DSurfaceImpl *) deviceImpl->render_targets[0])->currentDesc.Height; - val[1] = deviceImpl->render_offscreen ? 1.0f : -1.0f; - val[2] = 1.0f; - val[3] = 0.0f; + val[0] = deviceImpl->render_offscreen ? 0.0 : ((IWineD3DSurfaceImpl *) deviceImpl->render_targets[0])->currentDesc.Height; + val[1] = deviceImpl->render_offscreen ? 1.0 : -1.0; + val[2] = 1.0; + val[3] = 0.0; GL_EXTCALL(glProgramLocalParameter4fvARB(GL_FRAGMENT_PROGRAM_ARB, gl_shader->ycorrection, val)); - checkGLcall("y correction loading"); + checkGLcall("y correction loading\n"); } if(gl_shader->num_int_consts == 0) return; @@ -480,28 +400,25 @@ static inline void shader_arb_ps_local_constants(IWineD3DDeviceImpl* deviceImpl) val[0] = stateBlock->pixelShaderConstantI[4 * i]; val[1] = stateBlock->pixelShaderConstantI[4 * i + 1]; val[2] = stateBlock->pixelShaderConstantI[4 * i + 2]; - val[3] = -1.0f; + val[3] = -1.0; GL_EXTCALL(glProgramLocalParameter4fvARB(GL_FRAGMENT_PROGRAM_ARB, gl_shader->int_consts[i], val)); } } - checkGLcall("Load ps int consts"); + checkGLcall("Load ps int consts\n"); } -/* GL locking is done by the caller. */ static inline void shader_arb_vs_local_constants(IWineD3DDeviceImpl* deviceImpl) { IWineD3DStateBlockImpl* stateBlock; - const struct wined3d_gl_info *gl_info = &deviceImpl->adapter->gl_info; + const WineD3D_GL_Info *gl_info; unsigned char i; struct shader_arb_priv *priv = deviceImpl->shader_priv; const struct arb_vs_compiled_shader *gl_shader = priv->compiled_vprog; - /* Upload the position fixup */ - GL_EXTCALL(glProgramLocalParameter4fvARB(GL_VERTEX_PROGRAM_ARB, gl_shader->pos_fixup, deviceImpl->posFixup)); - if(gl_shader->num_int_consts == 0) return; + gl_info = &deviceImpl->adapter->gl_info; stateBlock = deviceImpl->stateBlock; for(i = 0; i < MAX_CONST_I; i++) @@ -512,12 +429,12 @@ static inline void shader_arb_vs_local_constants(IWineD3DDeviceImpl* deviceImpl) val[0] = stateBlock->vertexShaderConstantI[4 * i]; val[1] = stateBlock->vertexShaderConstantI[4 * i + 1]; val[2] = stateBlock->vertexShaderConstantI[4 * i + 2]; - val[3] = -1.0f; + val[3] = -1.0; GL_EXTCALL(glProgramLocalParameter4fvARB(GL_VERTEX_PROGRAM_ARB, gl_shader->int_consts[i], val)); } } - checkGLcall("Load vs int consts"); + checkGLcall("Load vs int consts\n"); } /** @@ -534,15 +451,20 @@ static void shader_arb_load_constants( IWineD3DDeviceImpl* deviceImpl = (IWineD3DDeviceImpl*) device; IWineD3DStateBlockImpl* stateBlock = deviceImpl->stateBlock; - const struct WineD3DContext *context = context_get_current(); - const struct wined3d_gl_info *gl_info = context->gl_info; + const WineD3D_GL_Info *gl_info = &deviceImpl->adapter->gl_info; if (useVertexShader) { IWineD3DBaseShaderImpl* vshader = (IWineD3DBaseShaderImpl*) stateBlock->vertexShader; /* Load DirectX 9 float constants for vertex shader */ - deviceImpl->highest_dirty_vs_const = shader_arb_load_constantsF(vshader, gl_info, GL_VERTEX_PROGRAM_ARB, - deviceImpl->highest_dirty_vs_const, stateBlock->vertexShaderConstantF, context->vshader_const_dirty); + deviceImpl->highest_dirty_vs_const = shader_arb_load_constantsF( + vshader, gl_info, GL_VERTEX_PROGRAM_ARB, + deviceImpl->highest_dirty_vs_const, + stateBlock->vertexShaderConstantF, + deviceImpl->activeContext->vshader_const_dirty); + + /* Upload the position fixup */ + GL_EXTCALL(glProgramEnvParameter4fvARB(GL_VERTEX_PROGRAM_ARB, ARB_SHADER_PRIVCONST_POS, deviceImpl->posFixup)); shader_arb_vs_local_constants(deviceImpl); } @@ -551,8 +473,11 @@ static void shader_arb_load_constants( IWineD3DBaseShaderImpl* pshader = (IWineD3DBaseShaderImpl*) stateBlock->pixelShader; /* Load DirectX 9 float constants for pixel shader */ - deviceImpl->highest_dirty_ps_const = shader_arb_load_constantsF(pshader, gl_info, GL_FRAGMENT_PROGRAM_ARB, - deviceImpl->highest_dirty_ps_const, stateBlock->pixelShaderConstantF, context->pshader_const_dirty); + deviceImpl->highest_dirty_ps_const = shader_arb_load_constantsF( + pshader, gl_info, GL_FRAGMENT_PROGRAM_ARB, + deviceImpl->highest_dirty_ps_const, + stateBlock->pixelShaderConstantF, + deviceImpl->activeContext->pshader_const_dirty); shader_arb_ps_local_constants(deviceImpl); } } @@ -560,27 +485,23 @@ static void shader_arb_load_constants( static void shader_arb_update_float_vertex_constants(IWineD3DDevice *iface, UINT start, UINT count) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; - struct WineD3DContext *context = context_get_current(); /* We don't want shader constant dirtification to be an O(contexts), so just dirtify the active * context. On a context switch the old context will be fully dirtified */ - if (!context || ((IWineD3DSurfaceImpl *)context->surface)->resource.wineD3DDevice != This) return; - - memset(context->vshader_const_dirty + start, 1, sizeof(*context->vshader_const_dirty) * count); - This->highest_dirty_vs_const = max(This->highest_dirty_vs_const, start + count); + memset(This->activeContext->vshader_const_dirty + start, 1, + sizeof(*This->activeContext->vshader_const_dirty) * count); + This->highest_dirty_vs_const = max(This->highest_dirty_vs_const, start + count + 1); } static void shader_arb_update_float_pixel_constants(IWineD3DDevice *iface, UINT start, UINT count) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; - struct WineD3DContext *context = context_get_current(); /* We don't want shader constant dirtification to be an O(contexts), so just dirtify the active * context. On a context switch the old context will be fully dirtified */ - if (!context || ((IWineD3DSurfaceImpl *)context->surface)->resource.wineD3DDevice != This) return; - - memset(context->pshader_const_dirty + start, 1, sizeof(*context->pshader_const_dirty) * count); - This->highest_dirty_ps_const = max(This->highest_dirty_ps_const, start + count); + memset(This->activeContext->pshader_const_dirty + start, 1, + sizeof(*This->activeContext->pshader_const_dirty) * count); + This->highest_dirty_ps_const = max(This->highest_dirty_ps_const, start + count + 1); } static DWORD *local_const_mapping(IWineD3DBaseShaderImpl *This) @@ -605,8 +526,8 @@ static DWORD *local_const_mapping(IWineD3DBaseShaderImpl *This) /* Generate the variable & register declarations for the ARB_vertex_program output target */ static DWORD shader_generate_arb_declarations(IWineD3DBaseShader *iface, const shader_reg_maps *reg_maps, - struct wined3d_shader_buffer *buffer, const struct wined3d_gl_info *gl_info, DWORD *lconst_map, - DWORD *num_clipplanes, struct shader_arb_ctx_priv *ctx) + SHADER_BUFFER *buffer, const WineD3D_GL_Info *gl_info, DWORD *lconst_map, DWORD *num_clipplanes, + struct shader_arb_ctx_priv *ctx) { IWineD3DBaseShaderImpl* This = (IWineD3DBaseShaderImpl*) iface; DWORD i, next_local = 0; @@ -652,7 +573,7 @@ static DWORD shader_generate_arb_declarations(IWineD3DBaseShader *iface, const s { if(ctx->target_version >= NV2) *num_clipplanes = GL_LIMITS(clipplanes); else *num_clipplanes = min(GL_LIMITS(clipplanes), 4); - max_constantsF = GL_LIMITS(vshader_constantsF); + max_constantsF = GL_LIMITS(vshader_constantsF) - 1; } } @@ -780,7 +701,7 @@ static void shader_arb_get_swizzle(const struct wined3d_shader_src_param *param, static void shader_arb_request_a0(const struct wined3d_shader_instruction *ins, const char *src) { struct shader_arb_ctx_priv *priv = ins->ctx->backend_data; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; if(strcmp(priv->addr_reg, src) == 0) return; @@ -957,22 +878,23 @@ static void shader_arb_get_register_name(const struct wined3d_shader_instruction break; case WINED3DSPR_COLOROUT: - if(ctx->cur_ps_args->super.srgb_correction && reg->idx == 0) - { - strcpy(register_name, "TMP_COLOR"); - } - else + if (reg->idx == 0) { - if(ctx->cur_ps_args->super.srgb_correction) FIXME("sRGB correction on higher render targets\n"); - if(This->baseShader.reg_maps.highest_render_target > 0) + if(ctx->cur_ps_args->super.srgb_correction) { - sprintf(register_name, "result.color[%u]", reg->idx); + strcpy(register_name, "TMP_COLOR"); } else { strcpy(register_name, "result.color"); } } + else + { + /* TODO: See GL_ARB_draw_buffers */ + FIXME("Unsupported write to render target %u\n", reg->idx); + sprintf(register_name, "unsupported_register"); + } break; case WINED3DSPR_RASTOUT: @@ -999,11 +921,11 @@ static void shader_arb_get_register_name(const struct wined3d_shader_instruction { if(This->baseShader.reg_maps.shader_version.major < 3) { - strcpy(register_name, ctx->texcrd_output[reg->idx]); + sprintf(register_name, ctx->texcrd_output[reg->idx]); } else { - strcpy(register_name, ctx->vs_output[reg->idx]); + sprintf(register_name, ctx->vs_output[reg->idx]); } } break; @@ -1084,8 +1006,8 @@ static const char *shader_arb_get_fixup_swizzle(enum fixup_channel_source channe } } -static void gen_color_correction(struct wined3d_shader_buffer *buffer, const char *reg, - DWORD dst_mask, const char *one, const char *two, struct color_fixup_desc fixup) +static void gen_color_correction(SHADER_BUFFER *buffer, const char *reg, DWORD dst_mask, + const char *one, const char *two, struct color_fixup_desc fixup) { DWORD mask; @@ -1181,10 +1103,9 @@ static const char *shader_arb_get_modifier(const struct wined3d_shader_instructi static void shader_hw_sample(const struct wined3d_shader_instruction *ins, DWORD sampler_idx, const char *dst_str, const char *coord_reg, WORD flags, const char *dsx, const char *dsy) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; DWORD sampler_type = ins->ctx->reg_maps->sampler_type[sampler_idx]; const char *tex_type; - BOOL np2_fixup = FALSE; IWineD3DBaseShaderImpl *This = (IWineD3DBaseShaderImpl *)ins->ctx->shader; IWineD3DDeviceImpl *device = (IWineD3DDeviceImpl *) This->baseShader.device; struct shader_arb_ctx_priv *priv = ins->ctx->backend_data; @@ -1208,10 +1129,9 @@ static void shader_hw_sample(const struct wined3d_shader_instruction *ins, DWORD } if (shader_is_pshader_version(ins->ctx->reg_maps->shader_version.type)) { - if (priv->cur_np2fixup_info->super.active & (1 << sampler_idx)) + if(priv->cur_ps_args->super.np2_fixup & (1 << sampler_idx)) { - if (flags) FIXME("Only ordinary sampling from NP2 textures is supported.\n"); - else np2_fixup = TRUE; + FIXME("NP2 texcoord fixup is currently not implemented in ARB mode (use GLSL instead).\n"); } } break; @@ -1268,16 +1188,7 @@ static void shader_hw_sample(const struct wined3d_shader_instruction *ins, DWORD } else { - if (np2_fixup) - { - const unsigned char idx = priv->cur_np2fixup_info->super.idx[sampler_idx]; - shader_addline(buffer, "MUL TA, np2fixup[%u].%s, %s;\n", idx >> 1, - (idx % 2) ? "zwxy" : "xyzw", coord_reg); - - shader_addline(buffer, "TEX%s %s, TA, texture[%u], %s;\n", mod, dst_str, sampler_idx, tex_type); - } - else - shader_addline(buffer, "TEX%s %s, %s, texture[%u], %s;\n", mod, dst_str, coord_reg, sampler_idx, tex_type); + shader_addline(buffer, "TEX%s %s, %s, texture[%u], %s;\n", mod, dst_str, coord_reg, sampler_idx, tex_type); } if (pshader) @@ -1295,7 +1206,7 @@ static void shader_arb_get_src_param(const struct wined3d_shader_instruction *in char regstr[256]; char swzstr[20]; int insert_line; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; struct shader_arb_ctx_priv *ctx = ins->ctx->backend_data; /* Assume a new line will be added */ @@ -1374,7 +1285,7 @@ static void shader_arb_get_src_param(const struct wined3d_shader_instruction *in static void pshader_hw_bem(const struct wined3d_shader_instruction *ins) { const struct wined3d_shader_dst_param *dst = &ins->dst[0]; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char dst_name[50]; char src_name[2][50]; DWORD sampler_code = dst->reg.idx; @@ -1397,33 +1308,10 @@ static void pshader_hw_bem(const struct wined3d_shader_instruction *ins) shader_addline(buffer, "ADD %s, %s, TC;\n", dst_name, src_name[0]); } -static DWORD negate_modifiers(DWORD mod, char *extra_char) -{ - *extra_char = ' '; - switch(mod) - { - case WINED3DSPSM_NONE: return WINED3DSPSM_NEG; - case WINED3DSPSM_NEG: return WINED3DSPSM_NONE; - case WINED3DSPSM_BIAS: return WINED3DSPSM_BIASNEG; - case WINED3DSPSM_BIASNEG: return WINED3DSPSM_BIAS; - case WINED3DSPSM_SIGN: return WINED3DSPSM_SIGNNEG; - case WINED3DSPSM_SIGNNEG: return WINED3DSPSM_SIGN; - case WINED3DSPSM_COMP: *extra_char = '-'; return WINED3DSPSM_COMP; - case WINED3DSPSM_X2: return WINED3DSPSM_X2NEG; - case WINED3DSPSM_X2NEG: return WINED3DSPSM_X2; - case WINED3DSPSM_DZ: *extra_char = '-'; return WINED3DSPSM_DZ; - case WINED3DSPSM_DW: *extra_char = '-'; return WINED3DSPSM_DW; - case WINED3DSPSM_ABS: return WINED3DSPSM_ABSNEG; - case WINED3DSPSM_ABSNEG: return WINED3DSPSM_ABS; - } - FIXME("Unknown modifier %u\n", mod); - return mod; -} - static void pshader_hw_cnd(const struct wined3d_shader_instruction *ins) { const struct wined3d_shader_dst_param *dst = &ins->dst[0]; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char dst_name[50]; char src_name[3][50]; DWORD shader_version = WINED3D_SHADER_VERSION(ins->ctx->reg_maps->shader_version.major, @@ -1438,15 +1326,9 @@ static void pshader_hw_cnd(const struct wined3d_shader_instruction *ins) { shader_addline(buffer, "MOV%s %s, %s;\n", shader_arb_get_modifier(ins), dst_name, src_name[1]); } else { - struct wined3d_shader_src_param src0_copy = ins->src[0]; - char extra_neg; - - /* src0 may have a negate srcmod set, so we can't blindly add "-" to the name */ - src0_copy.modifiers = negate_modifiers(src0_copy.modifiers, &extra_neg); - - shader_arb_get_src_param(ins, &src0_copy, 0, src_name[0]); + shader_arb_get_src_param(ins, &ins->src[0], 0, src_name[0]); shader_arb_get_src_param(ins, &ins->src[2], 2, src_name[2]); - shader_addline(buffer, "ADD TA, %c%s, coefdiv.x;\n", extra_neg, src_name[0]); + shader_addline(buffer, "ADD TA, -%s, coefdiv.x;\n", src_name[0]); /* No modifiers supported on CMP */ shader_addline(buffer, "CMP %s, TA, %s, %s;\n", dst_name, src_name[1], src_name[2]); @@ -1462,7 +1344,7 @@ static void pshader_hw_cnd(const struct wined3d_shader_instruction *ins) static void pshader_hw_cmp(const struct wined3d_shader_instruction *ins) { const struct wined3d_shader_dst_param *dst = &ins->dst[0]; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char dst_name[50]; char src_name[3][50]; BOOL is_color; @@ -1490,7 +1372,7 @@ static void pshader_hw_cmp(const struct wined3d_shader_instruction *ins) static void pshader_hw_dp2add(const struct wined3d_shader_instruction *ins) { const struct wined3d_shader_dst_param *dst = &ins->dst[0]; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char dst_name[50]; char src_name[3][50]; struct shader_arb_ctx_priv *ctx = ins->ctx->backend_data; @@ -1543,7 +1425,7 @@ static void pshader_hw_dp2add(const struct wined3d_shader_instruction *ins) /* Map the opcode 1-to-1 to the GL code */ static void shader_hw_map2gl(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; const char *instruction; char arguments[256], dst_str[50]; unsigned int i; @@ -1557,14 +1439,19 @@ static void shader_hw_map2gl(const struct wined3d_shader_instruction *ins) case WINED3DSIH_DP3: instruction = "DP3"; break; case WINED3DSIH_DP4: instruction = "DP4"; break; case WINED3DSIH_DST: instruction = "DST"; break; + case WINED3DSIH_EXP: instruction = "EX2"; break; + case WINED3DSIH_EXPP: instruction = "EXP"; break; case WINED3DSIH_FRC: instruction = "FRC"; break; case WINED3DSIH_LIT: instruction = "LIT"; break; + case WINED3DSIH_LOG: instruction = "LG2"; break; + case WINED3DSIH_LOGP: instruction = "LOG"; break; case WINED3DSIH_LRP: instruction = "LRP"; break; case WINED3DSIH_MAD: instruction = "MAD"; break; case WINED3DSIH_MAX: instruction = "MAX"; break; case WINED3DSIH_MIN: instruction = "MIN"; break; case WINED3DSIH_MOV: instruction = "MOV"; break; case WINED3DSIH_MUL: instruction = "MUL"; break; + case WINED3DSIH_POW: instruction = "POW"; break; case WINED3DSIH_SGE: instruction = "SGE"; break; case WINED3DSIH_SLT: instruction = "SLT"; break; case WINED3DSIH_SUB: instruction = "SUB"; break; @@ -1591,7 +1478,7 @@ static void shader_hw_map2gl(const struct wined3d_shader_instruction *ins) static void shader_hw_nop(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; shader_addline(buffer, "NOP;\n"); } @@ -1601,17 +1488,19 @@ static void shader_hw_mov(const struct wined3d_shader_instruction *ins) BOOL pshader = shader_is_pshader_version(shader->baseShader.reg_maps.shader_version.type); struct shader_arb_ctx_priv *ctx = ins->ctx->backend_data; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char src0_param[256]; if(ins->handler_idx == WINED3DSIH_MOVA) { + struct wined3d_shader_src_param tmp_src = ins->src[0]; char write_mask[6]; if(ctx->target_version >= NV2) { shader_hw_map2gl(ins); return; } - shader_arb_get_src_param(ins, &ins->src[0], 0, src0_param); + tmp_src.swizzle = (tmp_src.swizzle & 0x3) * 0x55; + shader_arb_get_src_param(ins, &tmp_src, 0, src0_param); shader_arb_get_write_mask(ins, &ins->dst[0], write_mask); /* This implements the mova formula used in GLSL. The first two instructions @@ -1630,10 +1519,6 @@ static void shader_hw_mov(const struct wined3d_shader_instruction *ins) shader_addline(buffer, "ABS TA%s, %s;\n", write_mask, src0_param); shader_addline(buffer, "ADD TA%s, TA, mova_const.x;\n", write_mask); shader_addline(buffer, "FLR TA%s, TA;\n", write_mask); - if (((IWineD3DVertexShaderImpl *)shader)->rel_offset) - { - shader_addline(buffer, "ADD TA%s, TA, helper_const.z;\n", write_mask); - } shader_addline(buffer, "MUL A0_SHADOW%s, TA, A0_SHADOW;\n", write_mask); ((struct shader_arb_ctx_priv *)ins->ctx->backend_data)->addr_reg[0] = '\0'; @@ -1678,7 +1563,7 @@ static void shader_hw_mov(const struct wined3d_shader_instruction *ins) static void pshader_hw_texkill(const struct wined3d_shader_instruction *ins) { const struct wined3d_shader_dst_param *dst = &ins->dst[0]; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char reg_dest[40]; /* No swizzles are allowed in d3d's texkill. PS 1.x ignores the 4th component as documented, @@ -1688,28 +1573,9 @@ static void pshader_hw_texkill(const struct wined3d_shader_instruction *ins) if (ins->ctx->reg_maps->shader_version.major >= 2) { - const char *kilsrc = "TA"; - BOOL is_color; - - shader_arb_get_register_name(ins, &dst->reg, reg_dest, &is_color); - if(dst->write_mask == WINED3DSP_WRITEMASK_ALL) - { - kilsrc = reg_dest; - } - else - { - /* Sigh. KIL doesn't support swizzles/writemasks. KIL passes a writemask, but ".xy" for example - * is not valid as a swizzle in ARB (needs ".xyyy"). Use SWZ to load the register properly, and set - * masked out components to 0(won't kill) - */ - char x = '0', y = '0', z = '0', w = '0'; - if(dst->write_mask & WINED3DSP_WRITEMASK_0) x = 'x'; - if(dst->write_mask & WINED3DSP_WRITEMASK_1) y = 'y'; - if(dst->write_mask & WINED3DSP_WRITEMASK_2) z = 'z'; - if(dst->write_mask & WINED3DSP_WRITEMASK_3) w = 'w'; - shader_addline(buffer, "SWZ TA, %s, %c, %c, %c, %c;\n", reg_dest, x, y, z, w); - } - shader_addline(buffer, "KIL %s;\n", kilsrc); + /* The arb backend doesn't claim ps 2.0 support, but try to eat what the app feeds to us */ + shader_arb_get_dst_param(ins, dst, reg_dest); + shader_addline(buffer, "KIL %s;\n", reg_dest); } else { /* ARB fp doesn't like swizzles on the parameter of the KIL instruction. To mask the 4th component, * copy the register into our general purpose TMP variable, overwrite .w and pass TMP to KIL @@ -1801,7 +1667,7 @@ static void pshader_hw_tex(const struct wined3d_shader_instruction *ins) static void pshader_hw_texcoord(const struct wined3d_shader_instruction *ins) { const struct wined3d_shader_dst_param *dst = &ins->dst[0]; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; DWORD shader_version = WINED3D_SHADER_VERSION(ins->ctx->reg_maps->shader_version.major, ins->ctx->reg_maps->shader_version.minor); char dst_str[50]; @@ -1823,7 +1689,7 @@ static void pshader_hw_texcoord(const struct wined3d_shader_instruction *ins) static void pshader_hw_texreg2ar(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; IWineD3DPixelShaderImpl *This = (IWineD3DPixelShaderImpl *)ins->ctx->shader; IWineD3DDeviceImpl* deviceImpl = (IWineD3DDeviceImpl*) This->baseShader.device; DWORD flags; @@ -1844,7 +1710,7 @@ static void pshader_hw_texreg2ar(const struct wined3d_shader_instruction *ins) static void pshader_hw_texreg2gb(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; DWORD reg1 = ins->dst[0].reg.idx; char dst_str[50]; @@ -1874,7 +1740,7 @@ static void pshader_hw_texbem(const struct wined3d_shader_instruction *ins) { IWineD3DPixelShaderImpl *This = (IWineD3DPixelShaderImpl *)ins->ctx->shader; const struct wined3d_shader_dst_param *dst = &ins->dst[0]; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char reg_coord[40], dst_reg[50], src_reg[50]; DWORD reg_dest_code; @@ -1927,7 +1793,7 @@ static void pshader_hw_texbem(const struct wined3d_shader_instruction *ins) static void pshader_hw_texm3x2pad(const struct wined3d_shader_instruction *ins) { DWORD reg = ins->dst[0].reg.idx; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char src0_name[50], dst_name[50]; BOOL is_color; struct wined3d_shader_register tmp_reg = ins->dst[0].reg; @@ -1947,7 +1813,7 @@ static void pshader_hw_texm3x2tex(const struct wined3d_shader_instruction *ins) IWineD3DDeviceImpl* deviceImpl = (IWineD3DDeviceImpl*) This->baseShader.device; DWORD flags; DWORD reg = ins->dst[0].reg.idx; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char dst_str[50]; char src0_name[50]; char dst_reg[50]; @@ -1967,7 +1833,7 @@ static void pshader_hw_texm3x3pad(const struct wined3d_shader_instruction *ins) { IWineD3DPixelShaderImpl *This = (IWineD3DPixelShaderImpl *)ins->ctx->shader; DWORD reg = ins->dst[0].reg.idx; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; SHADER_PARSE_STATE* current_state = &This->baseShader.parse_state; char src0_name[50], dst_name[50]; struct wined3d_shader_register tmp_reg = ins->dst[0].reg; @@ -1992,7 +1858,7 @@ static void pshader_hw_texm3x3tex(const struct wined3d_shader_instruction *ins) IWineD3DDeviceImpl* deviceImpl = (IWineD3DDeviceImpl*) This->baseShader.device; DWORD flags; DWORD reg = ins->dst[0].reg.idx; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; SHADER_PARSE_STATE* current_state = &This->baseShader.parse_state; char dst_str[50]; char src0_name[50], dst_name[50]; @@ -2015,7 +1881,7 @@ static void pshader_hw_texm3x3vspec(const struct wined3d_shader_instruction *ins IWineD3DDeviceImpl* deviceImpl = (IWineD3DDeviceImpl*) This->baseShader.device; DWORD flags; DWORD reg = ins->dst[0].reg.idx; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; SHADER_PARSE_STATE* current_state = &This->baseShader.parse_state; char dst_str[50]; char src0_name[50]; @@ -2058,7 +1924,7 @@ static void pshader_hw_texm3x3spec(const struct wined3d_shader_instruction *ins) DWORD flags; DWORD reg = ins->dst[0].reg.idx; SHADER_PARSE_STATE* current_state = &This->baseShader.parse_state; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char dst_str[50]; char src0_name[50]; char src1_name[50]; @@ -2096,7 +1962,7 @@ static void pshader_hw_texm3x3spec(const struct wined3d_shader_instruction *ins) static void pshader_hw_texdepth(const struct wined3d_shader_instruction *ins) { const struct wined3d_shader_dst_param *dst = &ins->dst[0]; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char dst_name[50]; /* texdepth has an implicit destination, the fragment depth value. It's only parameter, @@ -2126,7 +1992,7 @@ static void pshader_hw_texdepth(const struct wined3d_shader_instruction *ins) * then perform a 1D texture lookup from stage dstregnum, place into dst. */ static void pshader_hw_texdp3tex(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; DWORD sampler_idx = ins->dst[0].reg.idx; char src0[50]; char dst_str[50]; @@ -2146,7 +2012,7 @@ static void pshader_hw_texdp3(const struct wined3d_shader_instruction *ins) const struct wined3d_shader_dst_param *dst = &ins->dst[0]; char src0[50]; char dst_str[50]; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; /* Handle output register */ shader_arb_get_dst_param(ins, dst, dst_str); @@ -2159,7 +2025,7 @@ static void pshader_hw_texdp3(const struct wined3d_shader_instruction *ins) static void pshader_hw_texm3x3(const struct wined3d_shader_instruction *ins) { const struct wined3d_shader_dst_param *dst = &ins->dst[0]; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char dst_str[50], dst_name[50]; char src0[50]; BOOL is_color; @@ -2178,7 +2044,7 @@ static void pshader_hw_texm3x3(const struct wined3d_shader_instruction *ins) */ static void pshader_hw_texm3x2depth(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; const struct wined3d_shader_dst_param *dst = &ins->dst[0]; char src0[50], dst_name[50]; BOOL is_color; @@ -2253,9 +2119,9 @@ static void shader_hw_mnxn(const struct wined3d_shader_instruction *ins) } } -static void shader_hw_scalar_op(const struct wined3d_shader_instruction *ins) +static void shader_hw_rsq_rcp(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; const char *instruction; char dst[50]; @@ -2263,10 +2129,8 @@ static void shader_hw_scalar_op(const struct wined3d_shader_instruction *ins) switch(ins->handler_idx) { - case WINED3DSIH_RSQ: instruction = "RSQ"; break; - case WINED3DSIH_RCP: instruction = "RCP"; break; - case WINED3DSIH_EXP: instruction = "EX2"; break; - case WINED3DSIH_EXPP: instruction = "EXP"; break; + case WINED3DSIH_RSQ: instruction = "RSQ"; break; + case WINED3DSIH_RCP: instruction = "RCP"; break; default: instruction = ""; FIXME("Unhandled opcode %#x\n", ins->handler_idx); break; @@ -2287,7 +2151,7 @@ static void shader_hw_scalar_op(const struct wined3d_shader_instruction *ins) static void shader_hw_nrm(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char dst_name[50]; char src_name[50]; struct shader_arb_ctx_priv *priv = ins->ctx->backend_data; @@ -2312,7 +2176,7 @@ static void shader_hw_nrm(const struct wined3d_shader_instruction *ins) static void shader_hw_lrp(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char dst_name[50]; char src_name[3][50]; @@ -2338,7 +2202,7 @@ static void shader_hw_sincos(const struct wined3d_shader_instruction *ins) * must contain fixed constants. So we need a separate function to filter those constants and * can't use map2gl */ - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; struct shader_arb_ctx_priv *priv = ins->ctx->backend_data; const struct wined3d_shader_dst_param *dst = &ins->dst[0]; char dst_name[50]; @@ -2439,9 +2303,10 @@ static void shader_hw_sincos(const struct wined3d_shader_instruction *ins) } } +/* GL locking is done by the caller */ static void shader_hw_sgn(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char dst_name[50]; char src_name[50]; struct shader_arb_ctx_priv *ctx = ins->ctx->backend_data; @@ -2454,36 +2319,22 @@ static void shader_hw_sgn(const struct wined3d_shader_instruction *ins) shader_arb_get_dst_param(ins, &ins->dst[0], dst_name); shader_arb_get_src_param(ins, &ins->src[0], 0, src_name); + FIXME("Emulated SGN untested\n"); /* If SRC > 0.0, -SRC < SRC = TRUE, otherwise false. * if SRC < 0.0, SRC < -SRC = TRUE. If neither is true, src = 0.0 */ if(ins->dst[0].modifiers & WINED3DSPDM_SATURATE) { shader_addline(buffer, "SLT %s, -%s, %s;\n", dst_name, src_name, src_name); } else { - /* src contains TA? Write to the dest first. This won't overwrite our destination. - * Then use TA, and calculate the final result - * - * Not reading from TA? Store the first result in TA to avoid overwriting the - * destination if src reg = dst reg - */ - if(strstr(src_name, "TA")) - { - shader_addline(buffer, "SLT %s, %s, -%s;\n", dst_name, src_name, src_name); - shader_addline(buffer, "SLT TA, -%s, %s;\n", src_name, src_name); - shader_addline(buffer, "ADD %s, %s, -TA;\n", dst_name, dst_name); - } - else - { - shader_addline(buffer, "SLT TA, -%s, %s;\n", src_name, src_name); - shader_addline(buffer, "SLT %s, %s, -%s;\n", dst_name, src_name, src_name); - shader_addline(buffer, "ADD %s, TA, -%s;\n", dst_name, dst_name); - } + shader_addline(buffer, "SLT TB, -%s, %s;\n", src_name, src_name); + shader_addline(buffer, "SLT TC, %s, -%s;\n", src_name, src_name); + shader_addline(buffer, "ADD %s, TB, -TC;\n", dst_name); } } static void shader_hw_dsy(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char src[50]; char dst[50]; char dst_name[50]; @@ -2497,81 +2348,9 @@ static void shader_hw_dsy(const struct wined3d_shader_instruction *ins) shader_addline(buffer, "MUL%s %s, %s, ycorrection.y;\n", shader_arb_get_modifier(ins), dst, dst_name); } -static DWORD abs_modifier(DWORD mod, BOOL *need_abs) -{ - *need_abs = FALSE; - - switch(mod) - { - case WINED3DSPSM_NONE: return WINED3DSPSM_ABS; - case WINED3DSPSM_NEG: return WINED3DSPSM_ABS; - case WINED3DSPSM_BIAS: *need_abs = TRUE; return WINED3DSPSM_BIAS; - case WINED3DSPSM_BIASNEG: *need_abs = TRUE; return WINED3DSPSM_BIASNEG; - case WINED3DSPSM_SIGN: *need_abs = TRUE; return WINED3DSPSM_SIGN; - case WINED3DSPSM_SIGNNEG: *need_abs = TRUE; return WINED3DSPSM_SIGNNEG; - case WINED3DSPSM_COMP: *need_abs = TRUE; return WINED3DSPSM_COMP; - case WINED3DSPSM_X2: *need_abs = TRUE; return WINED3DSPSM_X2; - case WINED3DSPSM_X2NEG: *need_abs = TRUE; return WINED3DSPSM_X2NEG; - case WINED3DSPSM_DZ: *need_abs = TRUE; return WINED3DSPSM_DZ; - case WINED3DSPSM_DW: *need_abs = TRUE; return WINED3DSPSM_DW; - case WINED3DSPSM_ABS: return WINED3DSPSM_ABS; - case WINED3DSPSM_ABSNEG: return WINED3DSPSM_ABS; - } - FIXME("Unknown modifier %u\n", mod); - return mod; -} - -static void shader_hw_log_pow(const struct wined3d_shader_instruction *ins) -{ - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; - char src0[50], src1[50], dst[50]; - struct wined3d_shader_src_param src0_copy = ins->src[0]; - BOOL need_abs = FALSE; - const char *instr; - BOOL arg2 = FALSE; - - switch(ins->handler_idx) - { - case WINED3DSIH_LOG: instr = "LG2"; break; - case WINED3DSIH_LOGP: instr = "LOG"; break; - case WINED3DSIH_POW: instr = "POW"; arg2 = TRUE; break; - default: - ERR("Unexpected instruction %d\n", ins->handler_idx); - return; - } - - /* LOG, LOGP and POW operate on the absolute value of the input */ - src0_copy.modifiers = abs_modifier(src0_copy.modifiers, &need_abs); - - shader_arb_get_dst_param(ins, &ins->dst[0], dst); - shader_arb_get_src_param(ins, &src0_copy, 0, src0); - if(arg2) shader_arb_get_src_param(ins, &ins->src[1], 1, src1); - - if(need_abs) - { - shader_addline(buffer, "ABS TA, %s;\n", src0); - if(arg2) - { - shader_addline(buffer, "%s%s %s, TA, %s;\n", instr, shader_arb_get_modifier(ins), dst, src1); - } - else - { - shader_addline(buffer, "%s%s %s, TA;\n", instr, shader_arb_get_modifier(ins), dst); - } - } - else if(arg2) - { - shader_addline(buffer, "%s%s %s, %s, %s;\n", instr, shader_arb_get_modifier(ins), dst, src0, src1); - } - else - { - shader_addline(buffer, "%s%s %s, %s;\n", instr, shader_arb_get_modifier(ins), dst, src0); - } -} - static void shader_hw_loop(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char src_name[50]; BOOL vshader = shader_is_vshader_version(ins->ctx->reg_maps->shader_version.type); @@ -2598,7 +2377,7 @@ static void shader_hw_loop(const struct wined3d_shader_instruction *ins) static void shader_hw_rep(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; char src_name[50]; BOOL vshader = shader_is_vshader_version(ins->ctx->reg_maps->shader_version.type); @@ -2625,7 +2404,7 @@ static void shader_hw_rep(const struct wined3d_shader_instruction *ins) static void shader_hw_endloop(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; BOOL vshader = shader_is_vshader_version(ins->ctx->reg_maps->shader_version.type); if(vshader) @@ -2648,7 +2427,7 @@ static void shader_hw_endloop(const struct wined3d_shader_instruction *ins) static void shader_hw_endrep(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; BOOL vshader = shader_is_vshader_version(ins->ctx->reg_maps->shader_version.type); if(vshader) @@ -2683,7 +2462,7 @@ static const struct control_frame *find_last_loop(const struct shader_arb_ctx_pr static void shader_hw_break(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; const struct control_frame *control_frame = find_last_loop(ins->ctx->backend_data); BOOL vshader = shader_is_vshader_version(ins->ctx->reg_maps->shader_version.type); @@ -2697,50 +2476,31 @@ static void shader_hw_break(const struct wined3d_shader_instruction *ins) } } -static const char *get_compare(COMPARISON_TYPE flags) -{ - switch (flags) - { - case COMPARISON_GT: return "GT"; - case COMPARISON_EQ: return "EQ"; - case COMPARISON_GE: return "GE"; - case COMPARISON_LT: return "LT"; - case COMPARISON_NE: return "NE"; - case COMPARISON_LE: return "LE"; - default: - FIXME("Unrecognized comparison value: %u\n", flags); - return "(\?\?)"; - } -} - -static COMPARISON_TYPE invert_compare(COMPARISON_TYPE flags) -{ - switch (flags) - { - case COMPARISON_GT: return COMPARISON_LE; - case COMPARISON_EQ: return COMPARISON_NE; - case COMPARISON_GE: return COMPARISON_LT; - case COMPARISON_LT: return COMPARISON_GE; - case COMPARISON_NE: return COMPARISON_EQ; - case COMPARISON_LE: return COMPARISON_GT; - default: - FIXME("Unrecognized comparison value: %u\n", flags); - return -1; - } -} - static void shader_hw_breakc(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; BOOL vshader = shader_is_vshader_version(ins->ctx->reg_maps->shader_version.type); const struct control_frame *control_frame = find_last_loop(ins->ctx->backend_data); char src_name0[50]; char src_name1[50]; - const char *comp = get_compare(ins->flags); + const char *comp; shader_arb_get_src_param(ins, &ins->src[0], 0, src_name0); shader_arb_get_src_param(ins, &ins->src[1], 1, src_name1); + switch (ins->flags) + { + case COMPARISON_GT: comp = "GT"; break; + case COMPARISON_EQ: comp = "EQ"; break; + case COMPARISON_GE: comp = "GE"; break; + case COMPARISON_LT: comp = "LT"; break; + case COMPARISON_NE: comp = "NE"; break; + case COMPARISON_LE: comp = "LE"; break; + default: + FIXME("Unrecognized comparison value: %u\n", ins->flags); + comp = "(\?\?)"; + } + if(vshader) { /* SUBC CC, src0, src1" works only in pixel shaders, so use TA to throw @@ -2751,14 +2511,14 @@ static void shader_hw_breakc(const struct wined3d_shader_instruction *ins) } else { - shader_addline(buffer, "SUBC TA, %s, %s;\n", src_name0, src_name1); + shader_addline(buffer, "SUBC CC, %s, %s;\n", src_name0, src_name1); shader_addline(buffer, "BRK (%s.x);\n", comp); } } static void shader_hw_ifc(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; struct shader_arb_ctx_priv *priv = ins->ctx->backend_data; struct list *e = list_head(&priv->control_frames); struct control_frame *control_frame = LIST_ENTRY(e, struct control_frame, entry); @@ -2767,27 +2527,38 @@ static void shader_hw_ifc(const struct wined3d_shader_instruction *ins) char src_name1[50]; BOOL vshader = shader_is_vshader_version(ins->ctx->reg_maps->shader_version.type); + /* Invert the flag. We jump to the else label if the condition is NOT true */ + switch(ins->flags) + { + case COMPARISON_GT: comp = "LE"; break; + case COMPARISON_EQ: comp = "NE"; break; + case COMPARISON_GE: comp = "LT"; break; + case COMPARISON_LT: comp = "GE"; break; + case COMPARISON_NE: comp = "EQ"; break; + case COMPARISON_LE: comp = "GT"; break; + default: + FIXME("Unrecognized comparison value: %u\n", ins->flags); + comp = "\?\?"; + } + shader_arb_get_src_param(ins, &ins->src[0], 0, src_name0); shader_arb_get_src_param(ins, &ins->src[1], 1, src_name1); if(vshader) { - /* Invert the flag. We jump to the else label if the condition is NOT true */ - comp = get_compare(invert_compare(ins->flags)); shader_addline(buffer, "SUBC TA, %s, %s;\n", src_name0, src_name1); - shader_addline(buffer, "BRA ifc_%u_else (%s.x);\n", control_frame->ifc_no, comp); + shader_addline(buffer, "BRA ifc_%u_endif (%s.x);\n", control_frame->ifc_no, comp); } else { - comp = get_compare(ins->flags); - shader_addline(buffer, "SUBC TA, %s, %s;\n", src_name0, src_name1); + shader_addline(buffer, "SUBC CC, %s, %s;\n", src_name0, src_name1); shader_addline(buffer, "IF %s.x;\n", comp); } } static void shader_hw_else(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; struct shader_arb_ctx_priv *priv = ins->ctx->backend_data; struct list *e = list_head(&priv->control_frames); struct control_frame *control_frame = LIST_ENTRY(e, struct control_frame, entry); @@ -2807,7 +2578,7 @@ static void shader_hw_else(const struct wined3d_shader_instruction *ins) static void shader_hw_endif(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; struct shader_arb_ctx_priv *priv = ins->ctx->backend_data; struct list *e = list_head(&priv->control_frames); struct control_frame *control_frame = LIST_ENTRY(e, struct control_frame, entry); @@ -2865,130 +2636,7 @@ static void shader_hw_texldl(const struct wined3d_shader_instruction *ins) shader_hw_sample(ins, sampler_idx, reg_dest, reg_coord, flags, NULL, NULL); } -static void shader_hw_label(const struct wined3d_shader_instruction *ins) -{ - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; - struct shader_arb_ctx_priv *priv = ins->ctx->backend_data; - - priv->in_main_func = FALSE; - /* Call instructions activate the NV extensions, not labels and rets. If there is an uncalled - * subroutine, don't generate a label that will make GL complain - */ - if(priv->target_version == ARB) return; - - shader_addline(buffer, "l%u:\n", ins->src[0].reg.idx); -} - -static void vshader_add_footer(IWineD3DVertexShaderImpl *This, struct wined3d_shader_buffer *buffer, - const struct arb_vs_compile_args *args, struct shader_arb_ctx_priv *priv_ctx) -{ - const shader_reg_maps *reg_maps = &This->baseShader.reg_maps; - IWineD3DDeviceImpl *device = (IWineD3DDeviceImpl *)This->baseShader.device; - const struct wined3d_gl_info *gl_info = &device->adapter->gl_info; - unsigned int i; - - /* The D3DRS_FOGTABLEMODE render state defines if the shader-generated fog coord is used - * or if the fragment depth is used. If the fragment depth is used(FOGTABLEMODE != NONE), - * the fog frag coord is thrown away. If the fog frag coord is used, but not written by - * the shader, it is set to 0.0(fully fogged, since start = 1.0, end = 0.0) - */ - if(args->super.fog_src == VS_FOG_Z) { - shader_addline(buffer, "MOV result.fogcoord, TMP_OUT.z;\n"); - } else if (!reg_maps->fog) { - /* posFixup.x is always 1.0, so we can savely use it */ - shader_addline(buffer, "ADD result.fogcoord, posFixup.x, -posFixup.x;\n"); - } - - /* Write the final position. - * - * OpenGL coordinates specify the center of the pixel while d3d coords specify - * the corner. The offsets are stored in z and w in posFixup. posFixup.y contains - * 1.0 or -1.0 to turn the rendering upside down for offscreen rendering. PosFixup.x - * contains 1.0 to allow a mad, but arb vs swizzles are too restricted for that. - */ - shader_addline(buffer, "MUL TA, posFixup, TMP_OUT.w;\n"); - shader_addline(buffer, "ADD TMP_OUT.x, TMP_OUT.x, TA.z;\n"); - shader_addline(buffer, "MAD TMP_OUT.y, TMP_OUT.y, posFixup.y, TA.w;\n"); - - if(use_nv_clip(gl_info) && priv_ctx->target_version >= NV2) - { - for(i = 0; i < priv_ctx->vs_clipplanes; i++) - { - shader_addline(buffer, "DP4 result.clip[%u].x, TMP_OUT, state.clip[%u].plane;\n", i, i); - } - } - else if(args->boolclip.clip_control[0]) - { - unsigned int cur_clip = 0; - char component[4] = {'x', 'y', 'z', 'w'}; - - for(i = 0; i < GL_LIMITS(clipplanes); i++) - { - if(args->boolclip.clip_control[1] & (1 << i)) - { - shader_addline(buffer, "DP4 TA.%c, TMP_OUT, state.clip[%u].plane;\n", - component[cur_clip++], i); - } - } - switch(cur_clip) - { - case 0: - shader_addline(buffer, "MOV TA, -helper_const.w;\n"); - break; - case 1: - shader_addline(buffer, "MOV TA.yzw, -helper_const.w;\n"); - break; - case 2: - shader_addline(buffer, "MOV TA.zw, -helper_const.w;\n"); - break; - case 3: - shader_addline(buffer, "MOV TA.w, -helper_const.w;\n"); - break; - } - shader_addline(buffer, "MOV result.texcoord[%u], TA;\n", - args->boolclip.clip_control[0] - 1); - } - - /* Z coord [0;1]->[-1;1] mapping, see comment in transform_projection in state.c - * and the glsl equivalent - */ - if(need_helper_const(gl_info)) { - shader_addline(buffer, "MAD TMP_OUT.z, TMP_OUT.z, helper_const.x, -TMP_OUT.w;\n"); - } else { - shader_addline(buffer, "ADD TMP_OUT.z, TMP_OUT.z, TMP_OUT.z;\n"); - shader_addline(buffer, "ADD TMP_OUT.z, TMP_OUT.z, -TMP_OUT.w;\n"); - } - - shader_addline(buffer, "MOV result.position, TMP_OUT;\n"); - - priv_ctx->footer_written = TRUE; -} - -static void shader_hw_ret(const struct wined3d_shader_instruction *ins) -{ - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; - struct shader_arb_ctx_priv *priv = ins->ctx->backend_data; - IWineD3DBaseShaderImpl *shader = (IWineD3DBaseShaderImpl *) ins->ctx->shader; - BOOL vshader = shader_is_vshader_version(ins->ctx->reg_maps->shader_version.type); - - if(priv->target_version == ARB) return; - - if(vshader) - { - if(priv->in_main_func) vshader_add_footer((IWineD3DVertexShaderImpl *) shader, buffer, priv->cur_vs_args, priv); - } - - shader_addline(buffer, "RET;\n"); -} - -static void shader_hw_call(const struct wined3d_shader_instruction *ins) -{ - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; - shader_addline(buffer, "CAL l%u;\n", ins->src[0].reg.idx); -} - -/* GL locking is done by the caller */ -static GLuint create_arb_blt_vertex_program(const struct wined3d_gl_info *gl_info) +static GLuint create_arb_blt_vertex_program(const WineD3D_GL_Info *gl_info) { GLuint program_id = 0; const char *blt_vprogram = @@ -3014,7 +2662,7 @@ static GLuint create_arb_blt_vertex_program(const struct wined3d_gl_info *gl_inf } /* GL locking is done by the caller */ -static GLuint create_arb_blt_fragment_program(const struct wined3d_gl_info *gl_info, enum tex_types tex_type) +static GLuint create_arb_blt_fragment_program(const WineD3D_GL_Info *gl_info, enum tex_types tex_type) { GLuint program_id = 0; static const char * const blt_fprograms[tex_type_count] = @@ -3063,9 +2711,8 @@ static GLuint create_arb_blt_fragment_program(const struct wined3d_gl_info *gl_i return program_id; } -static void arbfp_add_sRGB_correction(struct wined3d_shader_buffer *buffer, const char *fragcolor, - const char *tmp1, const char *tmp2, const char *tmp3, const char *tmp4, BOOL condcode) -{ +static void arbfp_add_sRGB_correction(SHADER_BUFFER *buffer, const char *fragcolor, const char *tmp1, + const char *tmp2, const char *tmp3, const char *tmp4, BOOL condcode) { /* Perform sRGB write correction. See GLX_EXT_framebuffer_sRGB */ if(condcode) @@ -3197,12 +2844,12 @@ static void init_ps_input(const IWineD3DPixelShaderImpl *This, const struct arb_ } /* GL locking is done by the caller */ -static GLuint shader_arb_generate_pshader(IWineD3DPixelShaderImpl *This, struct wined3d_shader_buffer *buffer, - const struct arb_ps_compile_args *args, struct arb_ps_compiled_shader *compiled) +static GLuint shader_arb_generate_pshader(IWineD3DPixelShaderImpl *This, + SHADER_BUFFER *buffer, const struct arb_ps_compile_args *args, struct arb_ps_compiled_shader *compiled) { const shader_reg_maps* reg_maps = &This->baseShader.reg_maps; CONST DWORD *function = This->baseShader.function; - const struct wined3d_gl_info *gl_info = &((IWineD3DDeviceImpl *)This->baseShader.device)->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &((IWineD3DDeviceImpl *)This->baseShader.device)->adapter->gl_info; const local_constant *lconst; GLuint retval; char fragcolor[16]; @@ -3255,7 +2902,6 @@ static GLuint shader_arb_generate_pshader(IWineD3DPixelShaderImpl *This, struct memset(&priv_ctx, 0, sizeof(priv_ctx)); priv_ctx.cur_ps_args = args; priv_ctx.compiled_fprog = compiled; - priv_ctx.cur_np2fixup_info = &compiled->np2fixup_info; init_ps_input(This, args, &priv_ctx); list_init(&priv_ctx.control_frames); @@ -3271,7 +2917,7 @@ static GLuint shader_arb_generate_pshader(IWineD3DPixelShaderImpl *This, struct * So enable the best we can get. */ if(reg_maps->usesdsx || reg_maps->usesdsy || reg_maps->loop_depth > 0 || reg_maps->usestexldd || - reg_maps->usestexldl || reg_maps->usesfacing || reg_maps->usesifc || reg_maps->usescall) + reg_maps->usestexldl || reg_maps->usesfacing) { want_nv_prog = TRUE; } @@ -3295,11 +2941,6 @@ static GLuint shader_arb_generate_pshader(IWineD3DPixelShaderImpl *This, struct priv_ctx.target_version = ARB; } - if(This->baseShader.reg_maps.highest_render_target > 0) - { - shader_addline(buffer, "OPTION ARB_draw_buffers;\n"); - } - if (reg_maps->shader_version.major < 3) { switch(args->super.fog) { @@ -3429,44 +3070,6 @@ static GLuint shader_arb_generate_pshader(IWineD3DPixelShaderImpl *This, struct compiled->ycorrection = WINED3D_CONST_NUM_UNUSED; } - /* Load constants to fixup NP2 texcoords if there are still free constants left: - * Constants (texture dimensions) for the NP2 fixup are loaded as local program parameters. This will consume - * at most 8 (MAX_FRAGMENT_SAMPLERS / 2) parameters, which is highly unlikely, since the application had to - * use 16 NP2 textures at the same time. In case that we run out of constants the fixup is simply not - * applied / activated. This will probably result in wrong rendering of the texture, but will save us from - * shader compilation errors and the subsequent errors when drawing with this shader. */ - if (priv_ctx.cur_ps_args->super.np2_fixup) { - - struct arb_ps_np2fixup_info* const fixup = priv_ctx.cur_np2fixup_info; - const WORD map = priv_ctx.cur_ps_args->super.np2_fixup; - const UINT max_lconsts = gl_info->ps_arb_max_local_constants; - - fixup->offset = next_local; - fixup->super.active = 0; - - cur = 0; - for (i = 0; i < MAX_FRAGMENT_SAMPLERS; ++i) { - if (!(map & (1 << i))) continue; - - if (fixup->offset + (cur >> 1) < max_lconsts) { - fixup->super.active |= (1 << i); - fixup->super.idx[i] = cur++; - } else { - FIXME("No free constant found to load NP2 fixup data into shader. " - "Sampling from this texture will probably look wrong.\n"); - break; - } - } - - fixup->super.num_consts = (cur + 1) >> 1; - if (fixup->super.num_consts) { - shader_addline(buffer, "PARAM np2fixup[%u] = { program.env[%u..%u] };\n", - fixup->super.num_consts, fixup->offset, fixup->super.num_consts + fixup->offset - 1); - } - - next_local += fixup->super.num_consts; - } - if(shader_priv->clipplane_emulation) { shader_addline(buffer, "KIL fragment.texcoord[%u];\n", shader_priv->clipplane_emulation - 1); @@ -3585,8 +3188,7 @@ static DWORD find_input_signature(struct shader_arb_priv *priv, const struct win return found_sig->idx; } -static void init_output_registers(IWineD3DVertexShaderImpl *shader, DWORD sig_num, struct shader_arb_ctx_priv *priv_ctx, - struct arb_vs_compiled_shader *compiled) +static void init_output_registers(IWineD3DVertexShaderImpl *shader, DWORD sig_num, struct shader_arb_ctx_priv *priv_ctx) { unsigned int i, j; static const char *texcoords[8] = @@ -3706,16 +3308,6 @@ static void init_output_registers(IWineD3DVertexShaderImpl *shader, DWORD sig_nu { if(semantic_idx == 0) priv_ctx->fog_output = decl_idx_to_string[reg_idx]; } - else - { - continue; - } - - if(strcmp(decl_idx_to_string[reg_idx], "result.color.primary") == 0 || - strcmp(decl_idx_to_string[reg_idx], "result.color.secondary") == 0) - { - compiled->need_color_unclamp = TRUE; - } } /* Map declared to declared */ @@ -3753,35 +3345,30 @@ static void init_output_registers(IWineD3DVertexShaderImpl *shader, DWORD sig_nu sig[j].semantic_idx == shader->output_signature[i].semantic_idx) { priv_ctx->vs_output[i] = decl_idx_to_string[sig[j].register_idx]; - - if(strcmp(priv_ctx->vs_output[i], "result.color.primary") == 0 || - strcmp(priv_ctx->vs_output[i], "result.color.secondary") == 0) - { - compiled->need_color_unclamp = TRUE; - } } } } } /* GL locking is done by the caller */ -static GLuint shader_arb_generate_vshader(IWineD3DVertexShaderImpl *This, struct wined3d_shader_buffer *buffer, - const struct arb_vs_compile_args *args, struct arb_vs_compiled_shader *compiled) +static GLuint shader_arb_generate_vshader(IWineD3DVertexShaderImpl *This, + SHADER_BUFFER *buffer, const struct arb_vs_compile_args *args, struct arb_vs_compiled_shader *compiled) { const shader_reg_maps *reg_maps = &This->baseShader.reg_maps; CONST DWORD *function = This->baseShader.function; IWineD3DDeviceImpl *device = (IWineD3DDeviceImpl *)This->baseShader.device; - const struct wined3d_gl_info *gl_info = &device->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &device->adapter->gl_info; const local_constant *lconst; GLuint ret; DWORD next_local, *lconst_map = local_const_mapping((IWineD3DBaseShaderImpl *) This); struct shader_arb_ctx_priv priv_ctx; unsigned int i; + DWORD num_clipplanes = 0; memset(&priv_ctx, 0, sizeof(priv_ctx)); priv_ctx.cur_vs_args = args; list_init(&priv_ctx.control_frames); - init_output_registers(This, args->ps_signature, &priv_ctx, compiled); + init_output_registers(This, args->ps_signature, &priv_ctx); /* Create the hw ARB shader */ shader_addline(buffer, "!!ARBvp1.0\n"); @@ -3814,7 +3401,7 @@ static GLuint shader_arb_generate_vshader(IWineD3DVertexShaderImpl *This, struct /* Base Declarations */ next_local = shader_generate_arb_declarations( (IWineD3DBaseShader*) This, reg_maps, buffer, &GLINFO_LOCATION, - lconst_map, &priv_ctx.vs_clipplanes, &priv_ctx); + lconst_map, &num_clipplanes, &priv_ctx); for(i = 0; i < MAX_CONST_I; i++) { @@ -3838,8 +3425,7 @@ static GLuint shader_arb_generate_vshader(IWineD3DVertexShaderImpl *This, struct } /* We need a constant to fixup the final position */ - shader_addline(buffer, "PARAM posFixup = program.local[%u];\n", next_local); - compiled->pos_fixup = next_local++; + shader_addline(buffer, "PARAM posFixup = program.env[%d];\n", ARB_SHADER_PRIVCONST_POS); /* Initialize output parameters. GL_ARB_vertex_program does not require special initialization values * for output parameters. D3D in theory does not do that either, but some applications depend on a @@ -3855,8 +3441,7 @@ static GLuint shader_arb_generate_vshader(IWineD3DVertexShaderImpl *This, struct if(!GL_SUPPORT(NV_VERTEX_PROGRAM)) { shader_addline(buffer, "MOV result.color.secondary, -helper_const.wwwy;\n"); - if ((GLINFO_LOCATION).quirks & WINED3D_QUIRK_SET_TEXCOORD_W && !device->frag_pipe->ffp_proj_control) - { + if((GLINFO_LOCATION).set_texcoord_w && !device->frag_pipe->ffp_proj_control) { int i; for(i = 0; i < min(8, MAX_REG_TEXCRD); i++) { if(This->baseShader.reg_maps.texcoord_mask[i] != 0 && @@ -3867,12 +3452,82 @@ static GLuint shader_arb_generate_vshader(IWineD3DVertexShaderImpl *This, struct } } - /* The shader starts with the main function */ - priv_ctx.in_main_func = TRUE; /* Base Shader Body */ shader_generate_main((IWineD3DBaseShader *)This, buffer, reg_maps, function, &priv_ctx); - if(!priv_ctx.footer_written) vshader_add_footer(This, buffer, args, &priv_ctx); + /* The D3DRS_FOGTABLEMODE render state defines if the shader-generated fog coord is used + * or if the fragment depth is used. If the fragment depth is used(FOGTABLEMODE != NONE), + * the fog frag coord is thrown away. If the fog frag coord is used, but not written by + * the shader, it is set to 0.0(fully fogged, since start = 1.0, end = 0.0) + */ + if(args->super.fog_src == VS_FOG_Z) { + shader_addline(buffer, "MOV result.fogcoord, TMP_OUT.z;\n"); + } else if (!reg_maps->fog) { + /* posFixup.x is always 1.0, so we can savely use it */ + shader_addline(buffer, "ADD result.fogcoord, posFixup.x, -posFixup.x;\n"); + } + + /* Write the final position. + * + * OpenGL coordinates specify the center of the pixel while d3d coords specify + * the corner. The offsets are stored in z and w in posFixup. posFixup.y contains + * 1.0 or -1.0 to turn the rendering upside down for offscreen rendering. PosFixup.x + * contains 1.0 to allow a mad, but arb vs swizzles are too restricted for that. + */ + shader_addline(buffer, "MUL TA, posFixup, TMP_OUT.w;\n"); + shader_addline(buffer, "ADD TMP_OUT.x, TMP_OUT.x, TA.z;\n"); + shader_addline(buffer, "MAD TMP_OUT.y, TMP_OUT.y, posFixup.y, TA.w;\n"); + + if(priv_ctx.target_version >= NV2) + { + for(i = 0; i < num_clipplanes; i++) + { + shader_addline(buffer, "DP4 result.clip[%u].x, TMP_OUT, state.clip[%u].plane;\n", i, i); + } + } + else if(args->boolclip.clip_control[0]) + { + unsigned int cur_clip = 0; + char component[4] = {'x', 'y', 'z', 'w'}; + + for(i = 0; i < GL_LIMITS(clipplanes); i++) + { + if(args->boolclip.clip_control[1] & (1 << i)) + { + shader_addline(buffer, "DP4 TA.%c, TMP_OUT, state.clip[%u].plane;\n", + component[cur_clip++], i); + } + } + switch(cur_clip) + { + case 0: + shader_addline(buffer, "MOV TA, -helper_const.w;\n"); + break; + case 1: + shader_addline(buffer, "MOV TA.yzw, -helper_const.w;\n"); + break; + case 2: + shader_addline(buffer, "MOV TA.zw, -helper_const.w;\n"); + break; + case 3: + shader_addline(buffer, "MOV TA.w, -helper_const.w;\n"); + break; + } + shader_addline(buffer, "MOV result.texcoord[%u], TA;\n", + args->boolclip.clip_control[0] - 1); + } + + /* Z coord [0;1]->[-1;1] mapping, see comment in transform_projection in state.c + * and the glsl equivalent + */ + if(need_helper_const(gl_info)) { + shader_addline(buffer, "MAD TMP_OUT.z, TMP_OUT.z, helper_const.x, -TMP_OUT.w;\n"); + } else { + shader_addline(buffer, "ADD TMP_OUT.z, TMP_OUT.z, TMP_OUT.z;\n"); + shader_addline(buffer, "ADD TMP_OUT.z, TMP_OUT.z, -TMP_OUT.w;\n"); + } + + shader_addline(buffer, "MOV result.position, TMP_OUT;\n"); shader_addline(buffer, "END\n"); @@ -3907,67 +3562,18 @@ static GLuint shader_arb_generate_vshader(IWineD3DVertexShaderImpl *This, struct return ret; } -static void find_clip_texcoord(IWineD3DPixelShaderImpl *ps) -{ - struct arb_pshader_private *shader_priv = ps->backend_priv; - int i; - const struct wined3d_gl_info *gl_info = &((IWineD3DDeviceImpl *)ps->baseShader.device)->adapter->gl_info; - - /* See if we can use fragment.texcoord[7] for clipplane emulation - * - * Don't do this if it is not supported, or fragment.texcoord[7] is used - */ - if(ps->baseShader.reg_maps.shader_version.major < 3) - { - for(i = GL_LIMITS(texture_stages); i > 0; i--) - { - if(!ps->baseShader.reg_maps.texcoord[i - 1]) - { - shader_priv->clipplane_emulation = i; - return; - } - } - WARN("Did not find a free clip reg(2.0)\n"); - } - else - { - for(i = GL_LIMITS(texture_stages); i > 0; i--) - { - if(!(ps->baseShader.reg_maps.input_registers & (1 << (i - 1)))) - { - shader_priv->clipplane_emulation = i; - return; - } - } - WARN("Did not find a free clip reg(3.0)\n"); - } -} - /* GL locking is done by the caller */ static struct arb_ps_compiled_shader *find_arb_pshader(IWineD3DPixelShaderImpl *shader, const struct arb_ps_compile_args *args) { UINT i; DWORD new_size; struct arb_ps_compiled_shader *new_array; - struct wined3d_shader_buffer buffer; + SHADER_BUFFER buffer; struct arb_pshader_private *shader_data; GLuint ret; if(!shader->backend_priv) { - IWineD3DDeviceImpl *device = (IWineD3DDeviceImpl *) shader->baseShader.device; - struct shader_arb_priv *priv = device->shader_priv; - shader->backend_priv = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*shader_data)); - shader_data = shader->backend_priv; - shader_data->clamp_consts = shader->baseShader.reg_maps.shader_version.major == 1; - - if(shader->baseShader.reg_maps.shader_version.major < 3) shader_data->input_signature_idx = ~0; - else shader_data->input_signature_idx = find_input_signature(priv, shader->input_signature); - - shader_data->has_signature_idx = TRUE; - TRACE("Shader got assigned input signature index %u\n", shader_data->input_signature_idx); - - if(!device->vs_clipping) find_clip_texcoord(shader); } shader_data = shader->backend_priv; @@ -4006,12 +3612,7 @@ static struct arb_ps_compiled_shader *find_arb_pshader(IWineD3DPixelShaderImpl * pixelshader_update_samplers(&shader->baseShader.reg_maps, ((IWineD3DDeviceImpl *)shader->baseShader.device)->stateBlock->textures); - if (!shader_buffer_init(&buffer)) - { - ERR("Failed to initialize shader buffer.\n"); - return 0; - } - + shader_buffer_init(&buffer); ret = shader_arb_generate_pshader(shader, &buffer, args, &shader_data->gl_shaders[shader_data->num_gl_shaders]); shader_buffer_free(&buffer); @@ -4038,10 +3639,10 @@ static struct arb_vs_compiled_shader *find_arb_vshader(IWineD3DVertexShaderImpl DWORD new_size; struct arb_vs_compiled_shader *new_array; DWORD use_map = ((IWineD3DDeviceImpl *)shader->baseShader.device)->strided_streams.use_map; - struct wined3d_shader_buffer buffer; + SHADER_BUFFER buffer; struct arb_vshader_private *shader_data; GLuint ret; - const struct wined3d_gl_info *gl_info = &((IWineD3DDeviceImpl *)shader->baseShader.device)->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &((IWineD3DDeviceImpl *)shader->baseShader.device)->adapter->gl_info; if(!shader->backend_priv) { shader->backend_priv = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*shader_data)); @@ -4081,12 +3682,7 @@ static struct arb_vs_compiled_shader *find_arb_vshader(IWineD3DVertexShaderImpl shader_data->gl_shaders[shader_data->num_gl_shaders].args = *args; - if (!shader_buffer_init(&buffer)) - { - ERR("Failed to initialize shader buffer.\n"); - return 0; - } - + shader_buffer_init(&buffer); ret = shader_arb_generate_vshader(shader, &buffer, args, &shader_data->gl_shaders[shader_data->num_gl_shaders]); shader_buffer_free(&buffer); @@ -4100,7 +3696,7 @@ static inline void find_arb_ps_compile_args(IWineD3DPixelShaderImpl *shader, IWi { int i; WORD int_skip; - const struct wined3d_gl_info *gl_info = &((IWineD3DDeviceImpl *)shader->baseShader.device)->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &((IWineD3DDeviceImpl *)shader->baseShader.device)->adapter->gl_info; find_ps_compile_args(shader, stateblock, &args->super); /* This forces all local boolean constants to 1 to make them stateblock independent */ @@ -4142,10 +3738,12 @@ static inline void find_arb_vs_compile_args(IWineD3DVertexShaderImpl *shader, IW int i; WORD int_skip; IWineD3DDeviceImpl *dev = (IWineD3DDeviceImpl *)shader->baseShader.device; - const struct wined3d_gl_info *gl_info = &dev->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &dev->adapter->gl_info; find_vs_compile_args(shader, stateblock, &args->super); - args->boolclip_compare = 0; + /* This forces all local boolean constants to 1 to make them stateblock independent */ + args->boolclip.bools = shader->baseShader.reg_maps.local_bool_consts; + if(use_ps(stateblock)) { IWineD3DPixelShaderImpl *ps = (IWineD3DPixelShaderImpl *) stateblock->pixelShader; @@ -4157,11 +3755,7 @@ static inline void find_arb_vs_compile_args(IWineD3DVertexShaderImpl *shader, IW else { args->ps_signature = ~0; - if(!dev->vs_clipping) - { - args->boolclip.clip_control[0] = ffp_clip_emul(stateblock) ? GL_LIMITS(texture_stages) : 0; - } - /* Otherwise: Setting boolclip_compare set clip_control[0] to 0 */ + args->boolclip.clip_control[0] = ffp_clip_emul(stateblock) ? GL_LIMITS(texture_stages) : 0; } if(args->boolclip.clip_control[0]) @@ -4170,11 +3764,12 @@ static inline void find_arb_vs_compile_args(IWineD3DVertexShaderImpl *shader, IW { args->boolclip.clip_control[1] = stateblock->renderState[WINED3DRS_CLIPPLANEENABLE]; } - /* clip_control[1] was set to 0 by setting boolclip_compare to 0 */ + else + { + args->boolclip.clip_control[1] = 0; + } } - /* This forces all local boolean constants to 1 to make them stateblock independent */ - args->boolclip.bools = shader->baseShader.reg_maps.local_bool_consts; /* TODO: Figure out if it would be better to store bool constants as bitmasks in the stateblock */ for(i = 0; i < MAX_CONST_B; i++) { @@ -4188,7 +3783,7 @@ static inline void find_arb_vs_compile_args(IWineD3DVertexShaderImpl *shader, IW /* Skip if unused or local */ int_skip = ~shader->baseShader.reg_maps.integer_constants | shader->baseShader.reg_maps.local_int_consts; - if(int_skip == 0xffff || GL_SUPPORT(NV_VERTEX_PROGRAM2_OPTION)) /* This is about flow control, not clipping */ + if(int_skip == 0xffff || GL_SUPPORT(NV_VERTEX_PROGRAM2_OPTION)) { memset(&args->loop_ctrl, 0, sizeof(args->loop_ctrl)); return; @@ -4211,18 +3806,50 @@ static inline void find_arb_vs_compile_args(IWineD3DVertexShaderImpl *shader, IW } } +static void find_clip_texcoord(IWineD3DPixelShaderImpl *ps, const WineD3D_GL_Info *gl_info) +{ + struct arb_pshader_private *shader_priv = ps->backend_priv; + int i; + + /* See if we can use fragment.texcoord[7] for clipplane emulation + * + * Don't do this if it is not supported, or fragment.texcoord[7] is used + */ + if(ps->baseShader.reg_maps.shader_version.major < 3) + { + for(i = GL_LIMITS(texture_stages); i > 0; i--) + { + if(!ps->baseShader.reg_maps.texcoord[i - 1]) + { + shader_priv->clipplane_emulation = i; + break; + } + } + } + else + { + for(i = GL_LIMITS(texture_stages); i > 0; i--) + { + if(!ps->baseShader.reg_maps.input_registers & (1 << (i - 1))) + { + shader_priv->clipplane_emulation = i; + break; + } + } + } +} + /* GL locking is done by the caller */ static void shader_arb_select(IWineD3DDevice *iface, BOOL usePS, BOOL useVS) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; struct shader_arb_priv *priv = This->shader_priv; - struct WineD3DContext *context = context_get_current(); - const struct wined3d_gl_info *gl_info = context->gl_info; - int i; + const WineD3D_GL_Info *gl_info = &This->adapter->gl_info; /* Deal with pixel shaders first so the vertex shader arg function has the input signature ready */ if (usePS) { struct arb_ps_compile_args compile_args; struct arb_ps_compiled_shader *compiled; + struct arb_pshader_private *shader_priv; IWineD3DPixelShaderImpl *ps = (IWineD3DPixelShaderImpl *) This->stateBlock->pixelShader; TRACE("Using pixel shader %p\n", This->stateBlock->pixelShader); @@ -4231,6 +3858,18 @@ static void shader_arb_select(IWineD3DDevice *iface, BOOL usePS, BOOL useVS) { priv->current_fprogram_id = compiled->prgId; priv->compiled_fprog = compiled; + shader_priv = ps->backend_priv; + if(!shader_priv->has_signature_idx) + { + if(ps->baseShader.reg_maps.shader_version.major < 3) shader_priv->input_signature_idx = ~0; + else shader_priv->input_signature_idx = find_input_signature(priv, ps->input_signature); + + shader_priv->has_signature_idx = TRUE; + TRACE("Shader got assigned input signature index %u\n", shader_priv->input_signature_idx); + + if(!This->vs_clipping) find_clip_texcoord(ps, gl_info); + } + /* Bind the fragment program */ GL_EXTCALL(glBindProgramARB(GL_FRAGMENT_PROGRAM_ARB, priv->current_fprogram_id)); checkGLcall("glBindProgramARB(GL_FRAGMENT_PROGRAM_ARB, priv->current_fprogram_id);"); @@ -4242,27 +3881,7 @@ static void shader_arb_select(IWineD3DDevice *iface, BOOL usePS, BOOL useVS) { } TRACE("(%p) : Bound fragment program %u and enabled GL_FRAGMENT_PROGRAM_ARB\n", This, priv->current_fprogram_id); - /* Pixel Shader 1.x constants are clamped to [-1;1], Pixel Shader 2.0 constants are not. If switching between - * a 1.x and newer shader, reload the first 8 constants - */ - if(priv->last_ps_const_clamped != ((struct arb_pshader_private *) ps->backend_priv)->clamp_consts) - { - priv->last_ps_const_clamped = ((struct arb_pshader_private *) ps->backend_priv)->clamp_consts; - This->highest_dirty_ps_const = max(This->highest_dirty_ps_const, 8); - for(i = 0; i < 8; i++) - { - context->pshader_const_dirty[i] = 1; - } - /* Also takes care of loading local constants */ - shader_arb_load_constants(iface, TRUE, FALSE); - } - else - { - shader_arb_ps_local_constants(This); - } - - /* Force constant reloading for the NP2 fixup (see comment in shader_glsl_select for more info) */ - if (compiled->np2fixup_info.super.active) This->shader_backend->shader_load_np2fixup_constants(iface, usePS, useVS); + shader_arb_ps_local_constants(This); } else if(GL_SUPPORT(ARB_FRAGMENT_PROGRAM) && !priv->use_arbfp_fixed_func) { /* Disable only if we're not using arbfp fixed function fragment processing. If this is used, * keep GL_FRAGMENT_PROGRAM_ARB enabled, and the fixed function pipeline will bind the fixed function @@ -4276,11 +3895,10 @@ static void shader_arb_select(IWineD3DDevice *iface, BOOL usePS, BOOL useVS) { if (useVS) { struct arb_vs_compile_args compile_args; struct arb_vs_compiled_shader *compiled; - IWineD3DVertexShaderImpl *vs = (IWineD3DVertexShaderImpl *) This->stateBlock->vertexShader; TRACE("Using vertex shader %p\n", This->stateBlock->vertexShader); - find_arb_vs_compile_args(vs, This->stateBlock, &compile_args); - compiled = find_arb_vshader(vs, &compile_args); + find_arb_vs_compile_args((IWineD3DVertexShaderImpl *) This->stateBlock->vertexShader, This->stateBlock, &compile_args); + compiled = find_arb_vshader((IWineD3DVertexShaderImpl *) This->stateBlock->vertexShader, &compile_args); priv->current_vprogram_id = compiled->prgId; priv->compiled_vprog = compiled; @@ -4293,17 +3911,6 @@ static void shader_arb_select(IWineD3DDevice *iface, BOOL usePS, BOOL useVS) { checkGLcall("glEnable(GL_VERTEX_PROGRAM_ARB);"); TRACE("(%p) : Bound vertex program %u and enabled GL_VERTEX_PROGRAM_ARB\n", This, priv->current_vprogram_id); shader_arb_vs_local_constants(This); - - if(priv->last_vs_color_unclamp != compiled->need_color_unclamp) { - priv->last_vs_color_unclamp = compiled->need_color_unclamp; - - if (GL_SUPPORT(ARB_COLOR_BUFFER_FLOAT)) { - GL_EXTCALL(glClampColorARB(GL_CLAMP_VERTEX_COLOR_ARB, !compiled->need_color_unclamp)); - checkGLcall("glClampColorARB"); - } else { - FIXME("vertex color clamp needs to be changed, but extension not supported.\n"); - } - } } else if(GL_SUPPORT(ARB_VERTEX_PROGRAM)) { priv->current_vprogram_id = 0; glDisable(GL_VERTEX_PROGRAM_ARB); @@ -4316,7 +3923,7 @@ static void shader_arb_select_depth_blt(IWineD3DDevice *iface, enum tex_types te IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; struct shader_arb_priv *priv = This->shader_priv; GLuint *blt_fprogram = &priv->depth_blt_fprogram_id[tex_type]; - const struct wined3d_gl_info *gl_info = &This->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &This->adapter->gl_info; if (!priv->depth_blt_vprogram_id) priv->depth_blt_vprogram_id = create_arb_blt_vertex_program(gl_info); GL_EXTCALL(glBindProgramARB(GL_VERTEX_PROGRAM_ARB, priv->depth_blt_vprogram_id)); @@ -4331,12 +3938,15 @@ static void shader_arb_select_depth_blt(IWineD3DDevice *iface, enum tex_types te static void shader_arb_deselect_depth_blt(IWineD3DDevice *iface) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; struct shader_arb_priv *priv = This->shader_priv; - const struct wined3d_gl_info *gl_info = &This->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &This->adapter->gl_info; if (priv->current_vprogram_id) { GL_EXTCALL(glBindProgramARB(GL_VERTEX_PROGRAM_ARB, priv->current_vprogram_id)); checkGLcall("glBindProgramARB(GL_VERTEX_PROGRAM_ARB, vertexShader->prgId);"); + glEnable(GL_VERTEX_PROGRAM_ARB); + checkGLcall("glEnable(GL_VERTEX_PROGRAM_ARB);"); + TRACE("(%p) : Bound vertex program %u and enabled GL_VERTEX_PROGRAM_ARB\n", This, priv->current_vprogram_id); } else { glDisable(GL_VERTEX_PROGRAM_ARB); @@ -4347,8 +3957,11 @@ static void shader_arb_deselect_depth_blt(IWineD3DDevice *iface) { GL_EXTCALL(glBindProgramARB(GL_FRAGMENT_PROGRAM_ARB, priv->current_fprogram_id)); checkGLcall("glBindProgramARB(GL_FRAGMENT_PROGRAM_ARB, pixelShader->prgId);"); + glEnable(GL_FRAGMENT_PROGRAM_ARB); + checkGLcall("glEnable(GL_FRAGMENT_PROGRAM_ARB);"); + TRACE("(%p) : Bound fragment program %u and enabled GL_FRAGMENT_PROGRAM_ARB\n", This, priv->current_fprogram_id); - } else if(!priv->use_arbfp_fixed_func) { + } else { glDisable(GL_FRAGMENT_PROGRAM_ARB); checkGLcall("glDisable(GL_FRAGMENT_PROGRAM_ARB)"); } @@ -4357,7 +3970,9 @@ static void shader_arb_deselect_depth_blt(IWineD3DDevice *iface) { static void shader_arb_destroy(IWineD3DBaseShader *iface) { IWineD3DBaseShaderImpl *baseShader = (IWineD3DBaseShaderImpl *) iface; IWineD3DDeviceImpl *device = (IWineD3DDeviceImpl *)baseShader->baseShader.device; - const struct wined3d_gl_info *gl_info = &device->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &device->adapter->gl_info; + + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); if (shader_is_pshader_version(baseShader->baseShader.reg_maps.shader_version.type)) { @@ -4367,9 +3982,6 @@ static void shader_arb_destroy(IWineD3DBaseShader *iface) { if(!shader_data) return; /* This can happen if a shader was never compiled */ ENTER_GL(); - - if(shader_data->num_gl_shaders) ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); - for(i = 0; i < shader_data->num_gl_shaders; i++) { GL_EXTCALL(glDeleteProgramsARB(1, &shader_data->gl_shaders[i].prgId)); checkGLcall("GL_EXTCALL(glDeleteProgramsARB(1, &shader_data->gl_shaders[i].prgId))"); @@ -4385,9 +3997,6 @@ static void shader_arb_destroy(IWineD3DBaseShader *iface) { if(!shader_data) return; /* This can happen if a shader was never compiled */ ENTER_GL(); - - if(shader_data->num_gl_shaders) ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); - for(i = 0; i < shader_data->num_gl_shaders; i++) { GL_EXTCALL(glDeleteProgramsARB(1, &shader_data->gl_shaders[i].prgId)); checkGLcall("GL_EXTCALL(glDeleteProgramsARB(1, &shader_data->gl_shaders[i].prgId))"); @@ -4438,10 +4047,9 @@ static void release_signature(struct wine_rb_entry *entry, void *context) HeapFree(GetProcessHeap(), 0, sig); } -/* Context activation is done by the caller. */ static void shader_arb_free(IWineD3DDevice *iface) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; - const struct wined3d_gl_info *gl_info = &This->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &This->adapter->gl_info; struct shader_arb_priv *priv = This->shader_priv; int i; @@ -4464,8 +4072,7 @@ static BOOL shader_arb_dirty_const(IWineD3DDevice *iface) { return TRUE; } -static void shader_arb_get_caps(WINED3DDEVTYPE devtype, const struct wined3d_gl_info *gl_info, - struct shader_caps *pCaps) +static void shader_arb_get_caps(WINED3DDEVTYPE devtype, const WineD3D_GL_Info *gl_info, struct shader_caps *pCaps) { /* We don't have an ARB fixed function pipeline yet, so let the none backend set its caps, * then overwrite the shader specific ones @@ -4473,47 +4080,19 @@ static void shader_arb_get_caps(WINED3DDEVTYPE devtype, const struct wined3d_gl_ none_shader_backend.shader_get_caps(devtype, gl_info, pCaps); if(GL_SUPPORT(ARB_VERTEX_PROGRAM)) { - if(GL_SUPPORT(NV_VERTEX_PROGRAM3)) - { - pCaps->VertexShaderVersion = WINED3DVS_VERSION(3,0); - TRACE_(d3d_caps)("Hardware vertex shader version 3.0 enabled (NV_VERTEX_PROGRAM3)\n"); - } - else if(GL_LIMITS(vshader_constantsF) >= 256) - { - /* Shader Model 2.0 requires at least 256 vertex shader constants */ - pCaps->VertexShaderVersion = WINED3DVS_VERSION(2,0); - TRACE_(d3d_caps)("Hardware vertex shader version 2.0 enabled (ARB_PROGRAM)\n"); - } - else - { - pCaps->VertexShaderVersion = WINED3DVS_VERSION(1,1); - TRACE_(d3d_caps)("Hardware vertex shader version 1.1 enabled (ARB_PROGRAM)\n"); - } - pCaps->MaxVertexShaderConst = GL_LIMITS(vshader_constantsF); + pCaps->VertexShaderVersion = WINED3DVS_VERSION(1,1); + TRACE_(d3d_caps)("Hardware vertex shader version 1.1 enabled (ARB_PROGRAM)\n"); + pCaps->MaxVertexShaderConst = GL_LIMITS(vshader_constantsF) - 1; } if(GL_SUPPORT(ARB_FRAGMENT_PROGRAM)) { - if(GL_SUPPORT(NV_FRAGMENT_PROGRAM2)) - { - pCaps->PixelShaderVersion = WINED3DPS_VERSION(3,0); - TRACE_(d3d_caps)("Hardware pixel shader version 3.0 enabled (NV_FRAGMENT_PROGRAM2)\n"); - } - else if(GL_LIMITS(pshader_constantsF) >= 32) - { - /* Shader Model 2.0 requires at least 32 pixel shader constants */ - pCaps->PixelShaderVersion = WINED3DPS_VERSION(2,0); - TRACE_(d3d_caps)("Hardware pixel shader version 2.0 enabled (ARB_PROGRAM)\n"); - } - else - { - pCaps->PixelShaderVersion = WINED3DPS_VERSION(1,4); - TRACE_(d3d_caps)("Hardware pixel shader version 1.4 enabled (ARB_PROGRAM)\n"); - } - pCaps->PixelShader1xMaxValue = 8.0f; + pCaps->PixelShaderVersion = WINED3DPS_VERSION(1,4); + pCaps->PixelShader1xMaxValue = 8.0; + TRACE_(d3d_caps)("Hardware pixel shader version 1.4 enabled (ARB_PROGRAM)\n"); pCaps->MaxPixelShaderConst = GL_LIMITS(pshader_constantsF); } - pCaps->VSClipping = use_nv_clip(gl_info); + pCaps->VSClipping = GL_SUPPORT(NV_VERTEX_PROGRAM2_OPTION); } static BOOL shader_arb_color_fixup_supported(struct color_fixup_desc fixup) @@ -4538,7 +4117,7 @@ static BOOL shader_arb_color_fixup_supported(struct color_fixup_desc fixup) static void shader_arb_add_instruction_modifiers(const struct wined3d_shader_instruction *ins) { DWORD shift; char write_mask[20], regstr[50]; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; BOOL is_color = FALSE; const struct wined3d_shader_dst_param *dst; @@ -4567,7 +4146,7 @@ static const SHADER_HANDLER shader_arb_instruction_handler_table[WINED3DSIH_TABL /* WINED3DSIH_BREAK */ shader_hw_break, /* WINED3DSIH_BREAKC */ shader_hw_breakc, /* WINED3DSIH_BREAKP */ NULL, - /* WINED3DSIH_CALL */ shader_hw_call, + /* WINED3DSIH_CALL */ NULL, /* WINED3DSIH_CALLNZ */ NULL, /* WINED3DSIH_CMP */ pshader_hw_cmp, /* WINED3DSIH_CND */ pshader_hw_cnd, @@ -4586,15 +4165,15 @@ static const SHADER_HANDLER shader_arb_instruction_handler_table[WINED3DSIH_TABL /* WINED3DSIH_ENDIF */ shader_hw_endif, /* WINED3DSIH_ENDLOOP */ shader_hw_endloop, /* WINED3DSIH_ENDREP */ shader_hw_endrep, - /* WINED3DSIH_EXP */ shader_hw_scalar_op, - /* WINED3DSIH_EXPP */ shader_hw_scalar_op, + /* WINED3DSIH_EXP */ shader_hw_map2gl, + /* WINED3DSIH_EXPP */ shader_hw_map2gl, /* WINED3DSIH_FRC */ shader_hw_map2gl, /* WINED3DSIH_IF */ NULL /* Hardcoded into the shader */, /* WINED3DSIH_IFC */ shader_hw_ifc, - /* WINED3DSIH_LABEL */ shader_hw_label, + /* WINED3DSIH_LABEL */ NULL, /* WINED3DSIH_LIT */ shader_hw_map2gl, - /* WINED3DSIH_LOG */ shader_hw_log_pow, - /* WINED3DSIH_LOGP */ shader_hw_log_pow, + /* WINED3DSIH_LOG */ shader_hw_map2gl, + /* WINED3DSIH_LOGP */ shader_hw_map2gl, /* WINED3DSIH_LOOP */ shader_hw_loop, /* WINED3DSIH_LRP */ shader_hw_lrp, /* WINED3DSIH_M3x2 */ shader_hw_mnxn, @@ -4611,11 +4190,11 @@ static const SHADER_HANDLER shader_arb_instruction_handler_table[WINED3DSIH_TABL /* WINED3DSIH_NOP */ shader_hw_nop, /* WINED3DSIH_NRM */ shader_hw_nrm, /* WINED3DSIH_PHASE */ NULL, - /* WINED3DSIH_POW */ shader_hw_log_pow, - /* WINED3DSIH_RCP */ shader_hw_scalar_op, + /* WINED3DSIH_POW */ shader_hw_map2gl, + /* WINED3DSIH_RCP */ shader_hw_rsq_rcp, /* WINED3DSIH_REP */ shader_hw_rep, - /* WINED3DSIH_RET */ shader_hw_ret, - /* WINED3DSIH_RSQ */ shader_hw_scalar_op, + /* WINED3DSIH_RET */ NULL, + /* WINED3DSIH_RSQ */ shader_hw_rsq_rcp, /* WINED3DSIH_SETP */ NULL, /* WINED3DSIH_SGE */ shader_hw_map2gl, /* WINED3DSIH_SGN */ shader_hw_sgn, @@ -4675,55 +4254,53 @@ static inline BOOL get_bool_const(const struct wined3d_shader_instruction *ins, } } -static void get_loop_control_const(const struct wined3d_shader_instruction *ins, - IWineD3DBaseShaderImpl *This, UINT idx, struct loop_control *loop_control) +static inline void get_int_const(const struct wined3d_shader_instruction *ins, IWineD3DBaseShaderImpl *This, DWORD idx, int *ret) { + BOOL vshader = shader_is_vshader_version(This->baseShader.reg_maps.shader_version.type); + WORD flag = (1 << idx); + const local_constant *constant; struct shader_arb_ctx_priv *priv = ins->ctx->backend_data; /* Integer constants can either be a local constant, or they can be stored in the shader - * type specific compile args. */ - if (This->baseShader.reg_maps.local_int_consts & (1 << idx)) + * type specific compile args + */ + if(This->baseShader.reg_maps.local_int_consts & flag) { - const local_constant *constant; - LIST_FOR_EACH_ENTRY(constant, &This->baseShader.constantsI, local_constant, entry) { if (constant->idx == idx) { - loop_control->count = constant->value[0]; - loop_control->start = constant->value[1]; - /* Step is signed. */ - loop_control->step = (int)constant->value[2]; + ret[0] = constant->value[0]; + ret[1] = constant->value[1]; + /* Step / stride is signed */ + ret[2] = (int) constant->value[2]; return; } } /* If this happens the flag was set incorrectly */ ERR("Local constant not found\n"); - loop_control->count = 0; - loop_control->start = 0; - loop_control->step = 0; + ret[0] = 0; + ret[1] = 0; + ret[2] = 0; return; } - - switch (This->baseShader.reg_maps.shader_version.type) + else { - case WINED3D_SHADER_TYPE_VERTEX: + if(vshader) + { /* Count and aL start value are unsigned */ - loop_control->count = priv->cur_vs_args->loop_ctrl[idx][0]; - loop_control->start = priv->cur_vs_args->loop_ctrl[idx][1]; - /* Step is signed. */ - loop_control->step = ((char)priv->cur_vs_args->loop_ctrl[idx][2]); - break; - - case WINED3D_SHADER_TYPE_PIXEL: - loop_control->count = priv->cur_ps_args->loop_ctrl[idx][0]; - loop_control->start = priv->cur_ps_args->loop_ctrl[idx][1]; - loop_control->step = ((char)priv->cur_ps_args->loop_ctrl[idx][2]); - break; - - default: - FIXME("Unhandled shader type %#x.\n", This->baseShader.reg_maps.shader_version.type); - break; + ret[0] = priv->cur_vs_args->loop_ctrl[idx][0]; + ret[1] = priv->cur_vs_args->loop_ctrl[idx][1]; + /* The step/stride is signed */ + ret[2] = ((char) priv->cur_vs_args->loop_ctrl[idx][2]); + } + else + { + ret[0] = priv->cur_ps_args->loop_ctrl[idx][0]; + ret[1] = priv->cur_ps_args->loop_ctrl[idx][1]; + ret[2] = ((char) priv->cur_ps_args->loop_ctrl[idx][2]); + } + return; } } @@ -4817,8 +4394,7 @@ static void shader_arb_handle_instruction(const struct wined3d_shader_instructio struct shader_arb_ctx_priv *priv = ins->ctx->backend_data; IWineD3DBaseShaderImpl *This = (IWineD3DBaseShaderImpl *)ins->ctx->shader; struct control_frame *control_frame; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; - BOOL bool_const; + SHADER_BUFFER *buffer = ins->ctx->buffer; if(ins->handler_idx == WINED3DSIH_LOOP || ins->handler_idx == WINED3DSIH_REP) { @@ -4843,10 +4419,14 @@ static void shader_arb_handle_instruction(const struct wined3d_shader_instructio if(!priv->recording) { + int control_values[3]; + get_int_const(ins, This, ins->src[0].reg.idx, control_values); list_init(&priv->record); priv->recording = TRUE; control_frame->outer_loop = TRUE; - get_loop_control_const(ins, This, ins->src[0].reg.idx, &control_frame->loop_control); + control_frame->loop_control[0] = control_values[0]; + control_frame->loop_control[1] = control_values[1]; + control_frame->loop_control[2] = control_values[2]; return; /* Instruction is handled */ } /* Record this loop in the outer loop's recording */ @@ -4882,17 +4462,17 @@ static void shader_arb_handle_instruction(const struct wined3d_shader_instructio if(ins->handler_idx == WINED3DSIH_ENDLOOP) { - shader_addline(buffer, "#unrolling loop: %u iterations, aL=%u, inc %d\n", - control_frame->loop_control.count, control_frame->loop_control.start, - control_frame->loop_control.step); - aL = control_frame->loop_control.start; + shader_addline(buffer, "#unrolling loop: %d iterations, aL=%d, inc %d\n", + control_frame->loop_control[0], control_frame->loop_control[1], + control_frame->loop_control[2]); + aL = control_frame->loop_control[1]; } else { - shader_addline(buffer, "#unrolling rep: %u iterations\n", control_frame->loop_control.count); + shader_addline(buffer, "#unrolling rep: %d iterations\n", control_frame->loop_control[0]); } - for (iteration = 0; iteration < control_frame->loop_control.count; ++iteration) + for(iteration = 0; iteration < control_frame->loop_control[0]; iteration++) { struct recorded_instruction *rec_ins; if(ins->handler_idx == WINED3DSIH_ENDLOOP) @@ -4912,7 +4492,7 @@ static void shader_arb_handle_instruction(const struct wined3d_shader_instructio if(ins->handler_idx == WINED3DSIH_ENDLOOP) { - aL += control_frame->loop_control.step; + aL += control_frame->loop_control[2]; } } shader_addline(buffer, "#end loop/rep\n"); @@ -4942,9 +4522,7 @@ static void shader_arb_handle_instruction(const struct wined3d_shader_instructio list_add_head(&priv->control_frames, &control_frame->entry); control_frame->type = IF; - bool_const = get_bool_const(ins, This, ins->src[0].reg.idx); - if(ins->src[0].modifiers == WINED3DSPSM_NOT) bool_const = !bool_const; - if(!priv->muted && bool_const == FALSE) + if(!priv->muted && get_bool_const(ins, This, ins->src[0].reg.idx) == FALSE) { shader_addline(buffer, "#if(FALSE){\n"); priv->muted = TRUE; @@ -5060,7 +4638,6 @@ struct arbfp_ffp_desc unsigned int num_textures_used; }; -/* Context activation is done by the caller. */ static void arbfp_enable(IWineD3DDevice *iface, BOOL enable) { ENTER_GL(); if(enable) { @@ -5097,10 +4674,9 @@ static HRESULT arbfp_alloc(IWineD3DDevice *iface) { return WINED3D_OK; } -/* Context activation is done by the caller. */ static void arbfp_free_ffpshader(struct wine_rb_entry *entry, void *context) { - const struct wined3d_gl_info *gl_info = context; + const WineD3D_GL_Info *gl_info = context; struct arbfp_ffp_desc *entry_arb = WINE_RB_ENTRY_VALUE(entry, struct arbfp_ffp_desc, parent.entry); ENTER_GL(); @@ -5110,7 +4686,6 @@ static void arbfp_free_ffpshader(struct wine_rb_entry *entry, void *context) LEAVE_GL(); } -/* Context activation is done by the caller. */ static void arbfp_free(IWineD3DDevice *iface) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *) iface; struct shader_arb_priv *priv = This->fragment_priv; @@ -5123,7 +4698,7 @@ static void arbfp_free(IWineD3DDevice *iface) { } } -static void arbfp_get_caps(WINED3DDEVTYPE devtype, const struct wined3d_gl_info *gl_info, struct fragment_caps *caps) +static void arbfp_get_caps(WINED3DDEVTYPE devtype, const WineD3D_GL_Info *gl_info, struct fragment_caps *caps) { caps->TextureOpCaps = WINED3DTEXOPCAPS_DISABLE | WINED3DTEXOPCAPS_SELECTARG1 | @@ -5172,7 +4747,7 @@ static void state_texfactor_arbfp(DWORD state, IWineD3DStateBlockImpl *statebloc if (use_ps(stateblock)) return; device = stateblock->wineD3DDevice; - context->pshader_const_dirty[ARB_FFP_CONST_TFACTOR] = 1; + device->activeContext->pshader_const_dirty[ARB_FFP_CONST_TFACTOR] = 1; device->highest_dirty_ps_const = max(device->highest_dirty_ps_const, ARB_FFP_CONST_TFACTOR + 1); } @@ -5193,17 +4768,17 @@ static void state_arb_specularenable(DWORD state, IWineD3DStateBlockImpl *stateb if (use_ps(stateblock)) return; device = stateblock->wineD3DDevice; - context->pshader_const_dirty[ARB_FFP_CONST_SPECULAR_ENABLE] = 1; + device->activeContext->pshader_const_dirty[ARB_FFP_CONST_SPECULAR_ENABLE] = 1; device->highest_dirty_ps_const = max(device->highest_dirty_ps_const, ARB_FFP_CONST_SPECULAR_ENABLE + 1); } if(stateblock->renderState[WINED3DRS_SPECULARENABLE]) { /* The specular color has no alpha */ - col[0] = 1.0f; col[1] = 1.0f; - col[2] = 1.0f; col[3] = 0.0f; + col[0] = 1.0; col[1] = 1.0; + col[2] = 1.0; col[3] = 0.0; } else { - col[0] = 0.0f; col[1] = 0.0f; - col[2] = 0.0f; col[3] = 0.0f; + col[0] = 0.0; col[1] = 0.0; + col[2] = 0.0; col[3] = 0.0; } GL_EXTCALL(glProgramEnvParameter4fvARB(GL_FRAGMENT_PROGRAM_ARB, ARB_FFP_CONST_SPECULAR_ENABLE, col)); checkGLcall("glProgramEnvParameter4fvARB(GL_FRAGMENT_PROGRAM_ARB, ARB_FFP_CONST_SPECULAR_ENABLE, col)"); @@ -5231,7 +4806,7 @@ static void set_bumpmat_arbfp(DWORD state, IWineD3DStateBlockImpl *stateblock, W return; } } else if(device->shader_backend == &arb_program_shader_backend) { - context->pshader_const_dirty[ARB_FFP_CONST_BUMPMAT(stage)] = 1; + device->activeContext->pshader_const_dirty[ARB_FFP_CONST_BUMPMAT(stage)] = 1; device->highest_dirty_ps_const = max(device->highest_dirty_ps_const, ARB_FFP_CONST_BUMPMAT(stage) + 1); } @@ -5266,21 +4841,20 @@ static void tex_bumpenvlum_arbfp(DWORD state, IWineD3DStateBlockImpl *stateblock return; } } else if(device->shader_backend == &arb_program_shader_backend) { - context->pshader_const_dirty[ARB_FFP_CONST_LUMINANCE(stage)] = 1; + device->activeContext->pshader_const_dirty[ARB_FFP_CONST_LUMINANCE(stage)] = 1; device->highest_dirty_ps_const = max(device->highest_dirty_ps_const, ARB_FFP_CONST_LUMINANCE(stage) + 1); } param[0] = *((float *) &stateblock->textureState[stage][WINED3DTSS_BUMPENVLSCALE]); param[1] = *((float *) &stateblock->textureState[stage][WINED3DTSS_BUMPENVLOFFSET]); - param[2] = 0.0f; - param[3] = 0.0f; + param[2] = 0.0; + param[3] = 0.0; GL_EXTCALL(glProgramEnvParameter4fvARB(GL_FRAGMENT_PROGRAM_ARB, ARB_FFP_CONST_LUMINANCE(stage), param)); checkGLcall("glProgramEnvParameter4fvARB(GL_FRAGMENT_PROGRAM_ARB, ARB_FFP_CONST_LUMINANCE(stage), param)"); } -static const char *get_argreg(struct wined3d_shader_buffer *buffer, DWORD argnum, unsigned int stage, DWORD arg) -{ +static const char *get_argreg(SHADER_BUFFER *buffer, DWORD argnum, unsigned int stage, DWORD arg) { const char *ret; if(arg == ARG_UNUSED) return "unused"; /* This is the marker for unused registers */ @@ -5351,9 +4925,8 @@ static const char *get_argreg(struct wined3d_shader_buffer *buffer, DWORD argnum return ret; } -static void gen_ffp_instr(struct wined3d_shader_buffer *buffer, unsigned int stage, BOOL color, - BOOL alpha, DWORD dst, DWORD op, DWORD dw_arg0, DWORD dw_arg1, DWORD dw_arg2) -{ +static void gen_ffp_instr(SHADER_BUFFER *buffer, unsigned int stage, BOOL color, BOOL alpha, + DWORD dst, DWORD op, DWORD dw_arg0, DWORD dw_arg1, DWORD dw_arg2) { const char *dstmask, *dstreg, *arg0, *arg1, *arg2; unsigned int mul = 1; BOOL mul_final_dest = FALSE; @@ -5494,7 +5067,7 @@ static void gen_ffp_instr(struct wined3d_shader_buffer *buffer, unsigned int sta static GLuint gen_arbfp_ffp_shader(const struct ffp_frag_settings *settings, IWineD3DStateBlockImpl *stateblock) { unsigned int stage; - struct wined3d_shader_buffer buffer; + SHADER_BUFFER buffer; BOOL tex_read[MAX_TEXTURES] = {FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE}; BOOL bump_used[MAX_TEXTURES] = {FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE}; BOOL luminance_used[MAX_TEXTURES] = {FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE}; @@ -5506,6 +5079,7 @@ static GLuint gen_arbfp_ffp_shader(const struct ffp_frag_settings *settings, IWi BOOL tempreg_used = FALSE, tfactor_used = FALSE; BOOL op_equal; const char *final_combiner_src = "ret"; + IWineD3DDeviceImpl *device = stateblock->wineD3DDevice; /* Find out which textures are read */ for(stage = 0; stage < MAX_TEXTURES; stage++) { @@ -5557,11 +5131,7 @@ static GLuint gen_arbfp_ffp_shader(const struct ffp_frag_settings *settings, IWi } /* Shader header */ - if (!shader_buffer_init(&buffer)) - { - ERR("Failed to initialize shader buffer.\n"); - return 0; - } + shader_buffer_init(&buffer); shader_addline(&buffer, "!!ARBfp1.0\n"); @@ -5600,7 +5170,7 @@ static GLuint gen_arbfp_ffp_shader(const struct ffp_frag_settings *settings, IWi srgb_sub_high, 0.0, 0.0, 0.0); } - if(ffp_clip_emul(stateblock) && settings->emul_clipplanes) shader_addline(&buffer, "KIL fragment.texcoord[7];\n"); + if(ffp_clip_emul(stateblock) && device->vs_clipping) shader_addline(&buffer, "KIL fragment.texcoord[7];\n"); /* Generate texture sampling instructions) */ for(stage = 0; stage < MAX_TEXTURES && settings->op[stage].cop != WINED3DTOP_DISABLE; stage++) { @@ -6064,8 +5634,6 @@ static HRESULT arbfp_blit_alloc(IWineD3DDevice *iface) { } return WINED3D_OK; } - -/* Context activation is done by the caller. */ static void arbfp_blit_free(IWineD3DDevice *iface) { IWineD3DDeviceImpl *device = (IWineD3DDeviceImpl *) iface; struct arbfp_blit_priv *priv = device->blit_priv; @@ -6077,12 +5645,11 @@ static void arbfp_blit_free(IWineD3DDevice *iface) { GL_EXTCALL(glDeleteProgramsARB(1, &priv->uyvy_2d_shader)); GL_EXTCALL(glDeleteProgramsARB(1, &priv->yv12_rect_shader)); GL_EXTCALL(glDeleteProgramsARB(1, &priv->yv12_2d_shader)); - checkGLcall("Delete yuv programs"); + checkGLcall("Delete yuv programs\n"); LEAVE_GL(); } -static BOOL gen_planar_yuv_read(struct wined3d_shader_buffer *buffer, enum yuv_fixup yuv_fixup, - GLenum textype, char *luminance) +static BOOL gen_planar_yuv_read(SHADER_BUFFER *buffer, enum yuv_fixup yuv_fixup, GLenum textype, char *luminance) { char chroma; const char *tex, *texinstr; @@ -6169,7 +5736,7 @@ static BOOL gen_planar_yuv_read(struct wined3d_shader_buffer *buffer, enum yuv_f return TRUE; } -static BOOL gen_yv12_read(struct wined3d_shader_buffer *buffer, GLenum textype, char *luminance) +static BOOL gen_yv12_read(SHADER_BUFFER *buffer, GLenum textype, char *luminance) { const char *tex; @@ -6220,7 +5787,7 @@ static BOOL gen_yv12_read(struct wined3d_shader_buffer *buffer, GLenum textype, * go from 0 to d3d_height, whereas the opengl texture height is 1.5 * d3d_height */ shader_addline(buffer, "PARAM yv12_coef = {%f, %f, %f, %f};\n", - 2.0f / 3.0f, 1.0f / 6.0f, (2.0f / 3.0f) + (1.0f / 6.0f), 1.0f / 3.0f); + 2.0 / 3.0, 1.0 / 6.0, (2.0 / 3.0) + (1.0 / 6.0), 1.0 / 3.0); shader_addline(buffer, "MOV texcrd, fragment.texcoord[0];\n"); /* the chroma planes have only half the width */ @@ -6315,20 +5882,15 @@ static BOOL gen_yv12_read(struct wined3d_shader_buffer *buffer, GLenum textype, return TRUE; } -/* Context activation is done by the caller. */ static GLuint gen_yuv_shader(IWineD3DDeviceImpl *device, enum yuv_fixup yuv_fixup, GLenum textype) { GLenum shader; - struct wined3d_shader_buffer buffer; + SHADER_BUFFER buffer; char luminance_component; struct arbfp_blit_priv *priv = device->blit_priv; /* Shader header */ - if (!shader_buffer_init(&buffer)) - { - ERR("Failed to initialize shader buffer.\n"); - return 0; - } + shader_buffer_init(&buffer); ENTER_GL(); GL_EXTCALL(glGenProgramsARB(1, &shader)); @@ -6456,7 +6018,6 @@ static GLuint gen_yuv_shader(IWineD3DDeviceImpl *device, enum yuv_fixup yuv_fixu return shader; } -/* Context activation is done by the caller. */ static HRESULT arbfp_blit_set(IWineD3DDevice *iface, const struct GlPixelFormatDesc *format_desc, GLenum textype, UINT width, UINT height) { @@ -6517,7 +6078,6 @@ static HRESULT arbfp_blit_set(IWineD3DDevice *iface, const struct GlPixelFormatD return WINED3D_OK; } -/* Context activation is done by the caller. */ static void arbfp_blit_unset(IWineD3DDevice *iface) { IWineD3DDeviceImpl *device = (IWineD3DDeviceImpl *) iface; diff --git a/dlls/wined3d/ati_fragment_shader.c b/dlls/wined3d/ati_fragment_shader.c index 29a78503513..1f6f2037614 100644 --- a/dlls/wined3d/ati_fragment_shader.c +++ b/dlls/wined3d/ati_fragment_shader.c @@ -192,9 +192,8 @@ static const char *debug_mask(GLuint mask) { } #define GLINFO_LOCATION (*gl_info) -static void wrap_op1(const struct wined3d_gl_info *gl_info, GLuint op, GLuint dst, GLuint dstMask, GLuint dstMod, - GLuint arg1, GLuint arg1Rep, GLuint arg1Mod) -{ +static void wrap_op1(const WineD3D_GL_Info *gl_info, GLuint op, GLuint dst, GLuint dstMask, GLuint dstMod, + GLuint arg1, GLuint arg1Rep, GLuint arg1Mod) { if(dstMask == GL_ALPHA) { TRACE("glAlphaFragmentOp1ATI(%s, %s, %s, %s, %s, %s)\n", debug_op(op), debug_register(dst), debug_dstmod(dstMod), debug_register(arg1), debug_rep(arg1Rep), debug_argmod(arg1Mod)); @@ -207,9 +206,9 @@ static void wrap_op1(const struct wined3d_gl_info *gl_info, GLuint op, GLuint ds } } -static void wrap_op2(const struct wined3d_gl_info *gl_info, GLuint op, GLuint dst, GLuint dstMask, GLuint dstMod, - GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod) -{ +static void wrap_op2(const WineD3D_GL_Info *gl_info, GLuint op, GLuint dst, GLuint dstMask, GLuint dstMod, + GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, + GLuint arg2, GLuint arg2Rep, GLuint arg2Mod) { if(dstMask == GL_ALPHA) { TRACE("glAlphaFragmentOp2ATI(%s, %s, %s, %s, %s, %s, %s, %s, %s)\n", debug_op(op), debug_register(dst), debug_dstmod(dstMod), debug_register(arg1), debug_rep(arg1Rep), debug_argmod(arg1Mod), @@ -224,10 +223,10 @@ static void wrap_op2(const struct wined3d_gl_info *gl_info, GLuint op, GLuint ds } } -static void wrap_op3(const struct wined3d_gl_info *gl_info, GLuint op, GLuint dst, GLuint dstMask, GLuint dstMod, - GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, - GLuint arg3, GLuint arg3Rep, GLuint arg3Mod) -{ +static void wrap_op3(const WineD3D_GL_Info *gl_info, GLuint op, GLuint dst, GLuint dstMask, GLuint dstMod, + GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, + GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, + GLuint arg3, GLuint arg3Rep, GLuint arg3Mod) { if(dstMask == GL_ALPHA) { /* Leave some free space to fit "GL_NONE, " in to align most alpha and color op lines */ TRACE("glAlphaFragmentOp3ATI(%s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s)\n", debug_op(op), debug_register(dst), debug_dstmod(dstMod), @@ -251,7 +250,7 @@ static void wrap_op3(const struct wined3d_gl_info *gl_info, GLuint op, GLuint ds } } -static GLuint register_for_arg(DWORD arg, const struct wined3d_gl_info *gl_info, +static GLuint register_for_arg(DWORD arg, const WineD3D_GL_Info *gl_info, unsigned int stage, GLuint *mod, GLuint *rep, GLuint tmparg) { GLenum ret; @@ -379,7 +378,7 @@ static GLuint find_tmpreg(const struct texture_stage_op op[MAX_TEXTURES]) } } -static GLuint gen_ati_shader(const struct texture_stage_op op[MAX_TEXTURES], const struct wined3d_gl_info *gl_info) +static GLuint gen_ati_shader(const struct texture_stage_op op[MAX_TEXTURES], const WineD3D_GL_Info *gl_info) { GLuint ret = GL_EXTCALL(glGenFragmentShadersATI(1)); unsigned int stage; @@ -865,10 +864,10 @@ static void set_bumpmat(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3D * shader(it is free). This might potentially reduce precision. However, if the hardware does * support proper floats it shouldn't, and if it doesn't we can't get anything better anyway */ - mat[0][0] = (mat[0][0] + 1.0f) * 0.5f; - mat[1][0] = (mat[1][0] + 1.0f) * 0.5f; - mat[0][1] = (mat[0][1] + 1.0f) * 0.5f; - mat[1][1] = (mat[1][1] + 1.0f) * 0.5f; + mat[0][0] = (mat[0][0] + 1.0) * 0.5; + mat[1][0] = (mat[1][0] + 1.0) * 0.5; + mat[0][1] = (mat[0][1] + 1.0) * 0.5; + mat[1][1] = (mat[1][1] + 1.0) * 0.5; GL_EXTCALL(glSetFragmentShaderConstantATI(ATI_FFP_CONST_BUMPMAT(stage), (float *) mat)); checkGLcall("glSetFragmentShaderConstantATI(ATI_FFP_CONST_BUMPMAT(stage), mat)"); } @@ -1039,7 +1038,6 @@ static const struct StateEntryTemplate atifs_fragmentstate_template[] = { {0 /* Terminate */, { 0, 0 }, WINED3D_GL_EXT_NONE }, }; -/* Context activation is done by the caller. */ static void atifs_enable(IWineD3DDevice *iface, BOOL enable) { ENTER_GL(); if(enable) { @@ -1052,7 +1050,7 @@ static void atifs_enable(IWineD3DDevice *iface, BOOL enable) { LEAVE_GL(); } -static void atifs_get_caps(WINED3DDEVTYPE devtype, const struct wined3d_gl_info *gl_info, struct fragment_caps *caps) +static void atifs_get_caps(WINED3DDEVTYPE devtype, const WineD3D_GL_Info *gl_info, struct fragment_caps *caps) { caps->TextureOpCaps = WINED3DTEXOPCAPS_DISABLE | WINED3DTEXOPCAPS_SELECTARG1 | @@ -1120,7 +1118,6 @@ static HRESULT atifs_alloc(IWineD3DDevice *iface) { } #define GLINFO_LOCATION This->adapter->gl_info -/* Context activation is done by the caller. */ static void atifs_free_ffpshader(struct wine_rb_entry *entry, void *context) { IWineD3DDeviceImpl *This = context; @@ -1133,7 +1130,6 @@ static void atifs_free_ffpshader(struct wine_rb_entry *entry, void *context) LEAVE_GL(); } -/* Context activation is done by the caller. */ static void atifs_free(IWineD3DDevice *iface) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *) iface; struct atifs_private_data *priv = This->fragment_priv; diff --git a/dlls/wined3d/baseshader.c b/dlls/wined3d/baseshader.c index 40efdd4aba6..d1c8a4bb0a6 100644 --- a/dlls/wined3d/baseshader.c +++ b/dlls/wined3d/baseshader.c @@ -138,41 +138,35 @@ const struct wined3d_shader_frontend *shader_select_frontend(DWORD version_token } } -void shader_buffer_clear(struct wined3d_shader_buffer *buffer) +static inline BOOL shader_is_version_token(DWORD token) { + return shader_is_pshader_version(token) || + shader_is_vshader_version(token); +} + +void shader_buffer_init(struct SHADER_BUFFER *buffer) { + buffer->buffer = HeapAlloc(GetProcessHeap(), 0, SHADER_PGMSIZE); buffer->buffer[0] = '\0'; buffer->bsize = 0; buffer->lineNo = 0; buffer->newline = TRUE; } -BOOL shader_buffer_init(struct wined3d_shader_buffer *buffer) -{ - buffer->buffer = HeapAlloc(GetProcessHeap(), 0, SHADER_PGMSIZE); - if (!buffer->buffer) - { - ERR("Failed to allocate shader buffer memory.\n"); - return FALSE; - } - - shader_buffer_clear(buffer); - return TRUE; -} - -void shader_buffer_free(struct wined3d_shader_buffer *buffer) +void shader_buffer_free(struct SHADER_BUFFER *buffer) { HeapFree(GetProcessHeap(), 0, buffer->buffer); } -int shader_vaddline(struct wined3d_shader_buffer *buffer, const char *format, va_list args) +int shader_vaddline(SHADER_BUFFER* buffer, const char *format, va_list args) { char* base = buffer->buffer + buffer->bsize; int rc; rc = vsnprintf(base, SHADER_PGMSIZE - 1 - buffer->bsize, format, args); - if (rc < 0 /* C89 */ || (unsigned int)rc > SHADER_PGMSIZE - 1 - buffer->bsize /* C99 */) - { + if (rc < 0 || /* C89 */ + rc > SHADER_PGMSIZE - 1 - buffer->bsize) { /* C99 */ + ERR("The buffer allocated for the shader program string " "is too small at %d bytes.\n", SHADER_PGMSIZE); buffer->bsize = SHADER_PGMSIZE - 1; @@ -194,7 +188,7 @@ int shader_vaddline(struct wined3d_shader_buffer *buffer, const char *format, va return 0; } -int shader_addline(struct wined3d_shader_buffer *buffer, const char *format, ...) +int shader_addline(SHADER_BUFFER* buffer, const char *format, ...) { int ret; va_list args; @@ -252,12 +246,12 @@ static inline void set_bitmap_bit(DWORD *bitmap, DWORD bit) } static void shader_record_register_usage(IWineD3DBaseShaderImpl *This, struct shader_reg_maps *reg_maps, - const struct wined3d_shader_register *reg, enum wined3d_shader_type shader_type) + const struct wined3d_shader_register *reg, BOOL pshader) { switch (reg->type) { case WINED3DSPR_TEXTURE: /* WINED3DSPR_ADDR */ - if (shader_type == WINED3D_SHADER_TYPE_PIXEL) reg_maps->texcoord[reg->idx] = 1; + if (pshader) reg_maps->texcoord[reg->idx] = 1; else reg_maps->address[reg->idx] = 1; break; @@ -266,7 +260,8 @@ static void shader_record_register_usage(IWineD3DBaseShaderImpl *This, struct sh break; case WINED3DSPR_INPUT: - if (shader_type == WINED3D_SHADER_TYPE_PIXEL) + if (!pshader) reg_maps->input_registers |= 1 << reg->idx; + else { if (reg->rel_addr) { @@ -284,7 +279,6 @@ static void shader_record_register_usage(IWineD3DBaseShaderImpl *This, struct sh ((IWineD3DPixelShaderImpl *)This)->input_reg_used[reg->idx] = TRUE; } } - else reg_maps->input_registers |= 1 << reg->idx; break; case WINED3DSPR_RASTOUT: @@ -292,26 +286,19 @@ static void shader_record_register_usage(IWineD3DBaseShaderImpl *This, struct sh break; case WINED3DSPR_MISCTYPE: - if (shader_type == WINED3D_SHADER_TYPE_PIXEL) - { - if (reg->idx == 0) reg_maps->vpos = 1; - else if (reg->idx == 1) reg_maps->usesfacing = 1; - } + if (pshader && reg->idx == 0) reg_maps->vpos = 1; + if (pshader && reg->idx == 1) reg_maps->usesfacing = 1; break; case WINED3DSPR_CONST: if (reg->rel_addr) { - if (shader_type != WINED3D_SHADER_TYPE_PIXEL) + if (!pshader) { - if (reg->idx < ((IWineD3DVertexShaderImpl *)This)->min_rel_offset) - { + if (reg->idx <= ((IWineD3DVertexShaderImpl *)This)->min_rel_offset) ((IWineD3DVertexShaderImpl *)This)->min_rel_offset = reg->idx; - } - if (reg->idx > ((IWineD3DVertexShaderImpl *)This)->max_rel_offset) - { + else if (reg->idx >= ((IWineD3DVertexShaderImpl *)This)->max_rel_offset) ((IWineD3DVertexShaderImpl *)This)->max_rel_offset = reg->idx; - } } reg_maps->usesrelconstF = TRUE; } @@ -329,10 +316,6 @@ static void shader_record_register_usage(IWineD3DBaseShaderImpl *This, struct sh reg_maps->boolean_constants |= (1 << reg->idx); break; - case WINED3DSPR_COLOROUT: - reg_maps->highest_render_target = max(reg_maps->highest_render_target, reg->idx); - break; - default: TRACE("Not recording register of type %#x and idx %u\n", reg->type, reg->idx); break; @@ -417,6 +400,7 @@ HRESULT shader_get_registers_used(IWineD3DBaseShader *iface, const struct wined3 struct wined3d_shader_version shader_version; unsigned int cur_loop_depth = 0, max_loop_depth = 0; const DWORD* pToken = byte_code; + char pshader; /* There are some minor differences between pixel and vertex shaders */ @@ -431,6 +415,7 @@ HRESULT shader_get_registers_used(IWineD3DBaseShader *iface, const struct wined3 fe->shader_read_header(fe_data, &pToken, &shader_version); reg_maps->shader_version = shader_version; + pshader = shader_is_pshader_version(shader_version.type); reg_maps->constf = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*reg_maps->constf) * ((constf_size + 31) / 32)); @@ -516,17 +501,17 @@ HRESULT shader_get_registers_used(IWineD3DBaseShader *iface, const struct wined3 pToken += 4; /* In pixel shader 1.X shaders, the constants are clamped between [-1;1] */ - if (shader_version.major == 1 && shader_version.type == WINED3D_SHADER_TYPE_PIXEL) + if (shader_version.major == 1 && pshader) { float *value = (float *) lconst->value; - if (value[0] < -1.0f) value[0] = -1.0f; - else if (value[0] > 1.0f) value[0] = 1.0f; - if (value[1] < -1.0f) value[1] = -1.0f; - else if (value[1] > 1.0f) value[1] = 1.0f; - if (value[2] < -1.0f) value[2] = -1.0f; - else if (value[2] > 1.0f) value[2] = 1.0f; - if (value[3] < -1.0f) value[3] = -1.0f; - else if (value[3] > 1.0f) value[3] = 1.0f; + if(value[0] < -1.0) value[0] = -1.0; + else if(value[0] > 1.0) value[0] = 1.0; + if(value[1] < -1.0) value[1] = -1.0; + else if(value[1] > 1.0) value[1] = 1.0; + if(value[2] < -1.0) value[2] = -1.0; + else if(value[2] > 1.0) value[2] = 1.0; + if(value[3] < -1.0) value[3] = -1.0; + else if(value[3] > 1.0) value[3] = 1.0; } list_add_head(&This->baseShader.constantsF, &lconst->entry); @@ -621,49 +606,26 @@ HRESULT shader_get_registers_used(IWineD3DBaseShader *iface, const struct wined3 fe->shader_read_dst_param(fe_data, &pToken, &dst_param, &dst_rel_addr); - shader_record_register_usage(This, reg_maps, &dst_param.reg, shader_version.type); - /* WINED3DSPR_TEXCRDOUT is the same as WINED3DSPR_OUTPUT. _OUTPUT can be > MAX_REG_TEXCRD and * is used in >= 3.0 shaders. Filter 3.0 shaders to prevent overflows, and also filter pixel * shaders because TECRDOUT isn't used in them, but future register types might cause issues */ - if (shader_version.type == WINED3D_SHADER_TYPE_VERTEX && shader_version.major < 3 - && dst_param.reg.type == WINED3DSPR_TEXCRDOUT) + if (!pshader && shader_version.major < 3 && dst_param.reg.type == WINED3DSPR_TEXCRDOUT) { - reg_maps->texcoord_mask[dst_param.reg.idx] |= dst_param.write_mask; + reg_maps->texcoord_mask[dst_param.reg.type] |= dst_param.write_mask; } - - if (shader_version.type == WINED3D_SHADER_TYPE_PIXEL) + else { - IWineD3DPixelShaderImpl *ps = (IWineD3DPixelShaderImpl *)This; - - if(dst_param.reg.type == WINED3DSPR_COLOROUT && dst_param.reg.idx == 0) - { - /* Many 2.0 and 3.0 pixel shaders end with a MOV from a temp register to - * COLOROUT 0. If we know this in advance, the ARB shader backend can skip - * the mov and perform the sRGB write correction from the source register. - * - * However, if the mov is only partial, we can't do this, and if the write - * comes from an instruction other than MOV it is hard to do as well. If - * COLOROUT 0 is overwritten partially later, the marker is dropped again. */ - - ps->color0_mov = FALSE; - if (ins.handler_idx == WINED3DSIH_MOV) - { - /* Used later when the source register is read. */ - color0_mov = TRUE; - } - } - /* Also drop the MOV marker if the source register is overwritten prior to the shader - * end - */ - else if(dst_param.reg.type == WINED3DSPR_TEMP && dst_param.reg.idx == ps->color0_reg) + if(pshader && dst_param.reg.type == WINED3DSPR_COLOROUT && dst_param.reg.idx == 0) { + IWineD3DPixelShaderImpl *ps = (IWineD3DPixelShaderImpl *) This; ps->color0_mov = FALSE; } + shader_record_register_usage(This, reg_maps, &dst_param.reg, pshader); } /* Declare 1.X samplers implicitly, based on the destination reg. number */ if (shader_version.major == 1 + && pshader /* Filter different instructions with the same enum values in VS */ && (ins.handler_idx == WINED3DSIH_TEX || ins.handler_idx == WINED3DSIH_TEXBEM || ins.handler_idx == WINED3DSIH_TEXBEML @@ -693,10 +655,26 @@ HRESULT shader_get_registers_used(IWineD3DBaseShader *iface, const struct wined3 } } } - else if (ins.handler_idx == WINED3DSIH_BEM) + else if (pshader && ins.handler_idx == WINED3DSIH_BEM) { reg_maps->bumpmat[dst_param.reg.idx] = TRUE; } + else if(pshader && ins.handler_idx == WINED3DSIH_MOV) + { + /* Many 2.0 and 3.0 pixel shaders end with a MOV from a temp register to + * COLOROUT 0. If we know this in advance, the ARB shader backend can skip + * the mov and perform the sRGB write correction from the source register. + * + * However, if the mov is only partial, we can't do this, and if the write + * comes from an instruction other than MOV it is hard to do as well. If + * COLOROUT 0 is overwritten partially later, the marker is dropped again + */ + if(dst_param.reg.type == WINED3DSPR_COLOROUT && dst_param.reg.idx == 0) + { + /* Used later when the source register is read */ + color0_mov = TRUE; + } + } } if (ins.handler_idx == WINED3DSIH_NRM) @@ -723,14 +701,6 @@ HRESULT shader_get_registers_used(IWineD3DBaseShader *iface, const struct wined3 { reg_maps->usesmova = 1; } - else if(ins.handler_idx == WINED3DSIH_IFC) - { - reg_maps->usesifc = 1; - } - else if(ins.handler_idx == WINED3DSIH_CALL) - { - reg_maps->usescall = 1; - } limit = ins.src_count + (ins.predicate ? 1 : 0); for (i = 0; i < limit; ++i) @@ -741,11 +711,11 @@ HRESULT shader_get_registers_used(IWineD3DBaseShader *iface, const struct wined3 fe->shader_read_src_param(fe_data, &pToken, &src_param, &src_rel_addr); count = get_instr_extra_regcount(ins.handler_idx, i); - shader_record_register_usage(This, reg_maps, &src_param.reg, shader_version.type); + shader_record_register_usage(This, reg_maps, &src_param.reg, pshader); while (count) { ++src_param.reg.idx; - shader_record_register_usage(This, reg_maps, &src_param.reg, shader_version.type); + shader_record_register_usage(This, reg_maps, &src_param.reg, pshader); --count; } @@ -764,7 +734,7 @@ HRESULT shader_get_registers_used(IWineD3DBaseShader *iface, const struct wined3 } reg_maps->loop_depth = max_loop_depth; - This->baseShader.functionLength = ((const char *)pToken - (const char *)byte_code); + This->baseShader.functionLength = ((char *)pToken - (char *)byte_code); return WINED3D_OK; } @@ -787,7 +757,7 @@ static void shader_dump_decl_usage(const struct wined3d_shader_semantic *semanti else { /* Pixel shaders 3.0 don't have usage semantics */ - if (shader_version->major < 3 && shader_version->type == WINED3D_SHADER_TYPE_PIXEL) + if (shader_is_pshader_version(shader_version->type) && shader_version->major < 3) return; else TRACE("_"); @@ -869,7 +839,7 @@ static void shader_dump_register(const struct wined3d_shader_register *reg, break; case WINED3DSPR_TEXTURE: /* vs: case WINED3DSPR_ADDR */ - TRACE("%c", shader_version->type == WINED3D_SHADER_TYPE_PIXEL ? 't' : 'a'); + TRACE("%c", shader_is_pshader_version(shader_version->type) ? 't' : 'a'); break; case WINED3DSPR_RASTOUT: @@ -928,10 +898,6 @@ static void shader_dump_register(const struct wined3d_shader_register *reg, TRACE("l"); break; - case WINED3DSPR_CONSTBUFFER: - TRACE("cb"); - break; - default: TRACE("unhandled_rtype(%#x)", reg->type); break; @@ -943,13 +909,13 @@ static void shader_dump_register(const struct wined3d_shader_register *reg, switch (reg->immconst_type) { case WINED3D_IMMCONST_FLOAT: - TRACE("%.8e", *(const float *)reg->immconst_data); + TRACE("%.8e", *(float *)reg->immconst_data); break; case WINED3D_IMMCONST_FLOAT4: TRACE("%.8e, %.8e, %.8e, %.8e", - *(const float *)®->immconst_data[0], *(const float *)®->immconst_data[1], - *(const float *)®->immconst_data[2], *(const float *)®->immconst_data[3]); + *(float *)®->immconst_data[0], *(float *)®->immconst_data[1], + *(float *)®->immconst_data[2], *(float *)®->immconst_data[3]); break; default: @@ -960,27 +926,14 @@ static void shader_dump_register(const struct wined3d_shader_register *reg, } else if (reg->type != WINED3DSPR_RASTOUT && reg->type != WINED3DSPR_MISCTYPE) { - if (reg->array_idx != ~0U) + if (reg->rel_addr) { - TRACE("%u[%u", offset, reg->array_idx); - if (reg->rel_addr) - { - TRACE(" + "); - shader_dump_src_param(reg->rel_addr, shader_version); - } - TRACE("]"); - } - else - { - if (reg->rel_addr) - { - TRACE("["); - shader_dump_src_param(reg->rel_addr, shader_version); - TRACE(" + "); - } - TRACE("%u", offset); - if (reg->rel_addr) TRACE("]"); + TRACE("["); + shader_dump_src_param(reg->rel_addr, shader_version); + TRACE(" + "); } + TRACE("%u", offset); + if (reg->rel_addr) TRACE("]"); } } @@ -1072,7 +1025,7 @@ void shader_dump_src_param(const struct wined3d_shader_src_param *param, /* Shared code in order to generate the bulk of the shader string. * NOTE: A description of how to parse tokens can be found on msdn */ -void shader_generate_main(IWineD3DBaseShader *iface, struct wined3d_shader_buffer *buffer, +void shader_generate_main(IWineD3DBaseShader *iface, SHADER_BUFFER *buffer, const shader_reg_maps *reg_maps, const DWORD *pFunction, void *backend_ctx) { IWineD3DBaseShaderImpl* This = (IWineD3DBaseShaderImpl*) iface; @@ -1128,7 +1081,8 @@ void shader_generate_main(IWineD3DBaseShader *iface, struct wined3d_shader_buffe || ins.handler_idx == WINED3DSIH_DEF || ins.handler_idx == WINED3DSIH_DEFI || ins.handler_idx == WINED3DSIH_DEFB - || ins.handler_idx == WINED3DSIH_PHASE) + || ins.handler_idx == WINED3DSIH_PHASE + || ins.handler_idx == WINED3DSIH_RET) { pToken += param_size; continue; @@ -1180,34 +1134,14 @@ void shader_trace_init(const struct wined3d_shader_frontend *fe, void *fe_data, { struct wined3d_shader_version shader_version; const DWORD* pToken = pFunction; - const char *type_prefix; DWORD i; TRACE("Parsing %p\n", pFunction); fe->shader_read_header(fe_data, &pToken, &shader_version); - switch (shader_version.type) - { - case WINED3D_SHADER_TYPE_VERTEX: - type_prefix = "vs"; - break; - - case WINED3D_SHADER_TYPE_GEOMETRY: - type_prefix = "gs"; - break; - - case WINED3D_SHADER_TYPE_PIXEL: - type_prefix = "ps"; - break; - - default: - FIXME("Unhandled shader type %#x.\n", shader_version.type); - type_prefix = "unknown"; - break; - } - - TRACE("%s_%u_%u\n", type_prefix, shader_version.major, shader_version.minor); + TRACE("%s_%u_%u\n", shader_is_pshader_version(shader_version.type) ? "ps": "vs", + shader_version.major, shader_version.minor); while (!fe->shader_is_end(fe_data, &pToken)) { @@ -1379,13 +1313,12 @@ static void shader_none_free(IWineD3DDevice *iface) {} static BOOL shader_none_dirty_const(IWineD3DDevice *iface) {return FALSE;} #define GLINFO_LOCATION (*gl_info) -static void shader_none_get_caps(WINED3DDEVTYPE devtype, - const struct wined3d_gl_info *gl_info, struct shader_caps *pCaps) +static void shader_none_get_caps(WINED3DDEVTYPE devtype, const WineD3D_GL_Info *gl_info, struct shader_caps *pCaps) { /* Set the shader caps to 0 for the none shader backend */ pCaps->VertexShaderVersion = 0; pCaps->PixelShaderVersion = 0; - pCaps->PixelShader1xMaxValue = 0.0f; + pCaps->PixelShader1xMaxValue = 0.0; } #undef GLINFO_LOCATION static BOOL shader_none_color_fixup_supported(struct color_fixup_desc fixup) diff --git a/dlls/wined3d/basetexture.c b/dlls/wined3d/basetexture.c index 0e74fd110d2..547ed1e1bb1 100644 --- a/dlls/wined3d/basetexture.c +++ b/dlls/wined3d/basetexture.c @@ -63,7 +63,7 @@ void basetexture_unload(IWineD3DBaseTexture *iface) IWineD3DDeviceImpl *device = This->resource.wineD3DDevice; if(This->baseTexture.textureName) { - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); glDeleteTextures(1, &This->baseTexture.textureName); This->baseTexture.textureName = 0; @@ -71,7 +71,7 @@ void basetexture_unload(IWineD3DBaseTexture *iface) } if(This->baseTexture.srgbTextureName) { - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); glDeleteTextures(1, &This->baseTexture.srgbTextureName); This->baseTexture.srgbTextureName = 0; @@ -135,7 +135,7 @@ HRESULT basetexture_set_autogen_filter_type(IWineD3DBaseTexture *iface, WINED3DT * Or should we delay the applying until the texture is used for drawing? For now, apply * immediately. */ - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); glBindTexture(textureDimensions, This->baseTexture.textureName); checkGLcall("glBindTexture"); @@ -197,7 +197,6 @@ BOOL basetexture_get_dirty(IWineD3DBaseTexture *iface) return This->baseTexture.dirty || This->baseTexture.srgbDirty; } -/* Context activation is done by the caller. */ HRESULT basetexture_bind(IWineD3DBaseTexture *iface, BOOL srgb, BOOL *set_surface_desc) { IWineD3DBaseTextureImpl *This = (IWineD3DBaseTextureImpl *)iface; diff --git a/dlls/wined3d/buffer.c b/dlls/wined3d/buffer.c index 157b218da57..e9f3ff6cc03 100644 --- a/dlls/wined3d/buffer.c +++ b/dlls/wined3d/buffer.c @@ -34,14 +34,16 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3d); #define VB_MAXDECLCHANGES 100 /* After that number we stop converting */ #define VB_RESETDECLCHANGE 1000 /* Reset the changecount after that number of draws */ -/* Context activation is done by the caller. */ static void buffer_create_buffer_object(struct wined3d_buffer *This) { GLenum error, gl_usage; + IWineD3DDeviceImpl *device = This->resource.wineD3DDevice; TRACE("Creating an OpenGL vertex buffer object for IWineD3DVertexBuffer %p Usage(%s)\n", This, debug_d3dusage(This->resource.usage)); + /* Make sure that a context is there. Needed in a multithreaded environment. Otherwise this call is a nop */ + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); /* Make sure that the gl error is cleared. Do not use checkGLcall @@ -455,7 +457,6 @@ static BOOL buffer_find_decl(struct wined3d_buffer *This) return ret; } -/* Context activation is done by the caller. */ static void buffer_check_buffer_object_size(struct wined3d_buffer *This) { UINT size = This->conversion_stride ? @@ -505,18 +506,29 @@ static inline void fixup_d3dcolor(DWORD *dst_color) static inline void fixup_transformed_pos(float *p) { - /* rhw conversion like in position_float4(). */ - if (p[3] != 1.0f && p[3] != 0.0f) + float x, y, z, w; + + /* rhw conversion like in drawStridedSlow */ + if (p[3] == 1.0 || ((p[3] < eps) && (p[3] > -eps))) { - float w = 1.0f / p[3]; - p[0] *= w; - p[1] *= w; - p[2] *= w; - p[3] = w; + x = p[0]; + y = p[1]; + z = p[2]; + w = 1.0; } + else + { + w = 1.0 / p[3]; + x = p[0] * w; + y = p[1] * w; + z = p[2] * w; + } + p[0] = x; + p[1] = y; + p[2] = z; + p[3] = w; } -/* Context activation is done by the caller. */ const BYTE *buffer_get_memory(IWineD3DBuffer *iface, UINT offset, GLuint *buffer_object) { struct wined3d_buffer *This = (struct wined3d_buffer *)iface; @@ -576,8 +588,7 @@ static ULONG STDMETHODCALLTYPE buffer_AddRef(IWineD3DBuffer *iface) return refcount; } -/* Context activation is done by the caller. */ -BYTE *buffer_get_sysmem(struct wined3d_buffer *This) +const BYTE *buffer_get_sysmem(struct wined3d_buffer *This) { /* AllocatedMemory exists if the buffer is double buffered or has no buffer object at all */ if(This->resource.allocatedMemory) return This->resource.allocatedMemory; @@ -603,7 +614,7 @@ static void STDMETHODCALLTYPE buffer_UnLoad(IWineD3DBuffer *iface) { IWineD3DDeviceImpl *device = This->resource.wineD3DDevice; - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); /* Download the buffer, but don't permanently enable double buffering */ if(!(This->flags & WINED3D_BUFFER_DOUBLEBUFFER)) @@ -690,8 +701,6 @@ static void STDMETHODCALLTYPE buffer_PreLoad(IWineD3DBuffer *iface) TRACE("iface %p\n", iface); - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); - if (!This->buffer_object) { /* TODO: Make converting independent from VBOs */ @@ -727,7 +736,7 @@ static void STDMETHODCALLTYPE buffer_PreLoad(IWineD3DBuffer *iface) if (This->conversion_count > VB_MAXDECLCHANGES) { FIXME("Too many declaration changes, stopping converting\n"); - + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); GL_EXTCALL(glDeleteBuffersARB(1, &This->buffer_object)); checkGLcall("glDeleteBuffersARB"); @@ -800,7 +809,7 @@ static void STDMETHODCALLTYPE buffer_PreLoad(IWineD3DBuffer *iface) if (!device->isInDraw) { - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); } ENTER_GL(); GL_EXTCALL(glBindBufferARB(This->buffer_type_hint, This->buffer_object)); @@ -950,7 +959,7 @@ static HRESULT STDMETHODCALLTYPE buffer_Map(IWineD3DBuffer *iface, UINT offset, IWineD3DDeviceImpl_MarkStateDirty(This->resource.wineD3DDevice, STATE_INDEXBUFFER); } - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); GL_EXTCALL(glBindBufferARB(This->buffer_type_hint, This->buffer_object)); This->resource.allocatedMemory = GL_EXTCALL(glMapBufferARB(This->buffer_type_hint, GL_READ_WRITE_ARB)); @@ -1002,7 +1011,7 @@ static HRESULT STDMETHODCALLTYPE buffer_Unmap(IWineD3DBuffer *iface) IWineD3DDeviceImpl_MarkStateDirty(This->resource.wineD3DDevice, STATE_INDEXBUFFER); } - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); GL_EXTCALL(glBindBufferARB(This->buffer_type_hint, This->buffer_object)); GL_EXTCALL(glUnmapBufferARB(This->buffer_type_hint)); diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c index 413c1d62868..81bddb18c22 100644 --- a/dlls/wined3d/context.c +++ b/dlls/wined3d/context.c @@ -2,7 +2,6 @@ * Context and render target management in wined3d * * Copyright 2007-2008 Stefan Dösinger for CodeWeavers - * Copyright 2009 Henri Verbeet for CodeWeavers * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -28,63 +27,35 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3d); -#define GLINFO_LOCATION (*gl_info) +#define GLINFO_LOCATION This->adapter->gl_info -static DWORD wined3d_context_tls_idx; +/* The last used device. + * + * If the application creates multiple devices and switches between them, ActivateContext has to + * change the opengl context. This flag allows to keep track which device is active + */ +static IWineD3DDeviceImpl *last_device; /* FBO helper functions */ /* GL locking is done by the caller */ -void context_bind_fbo(struct WineD3DContext *context, GLenum target, GLuint *fbo) +void context_bind_fbo(IWineD3DDevice *iface, GLenum target, GLuint *fbo) { - const struct wined3d_gl_info *gl_info = context->gl_info; - GLuint f; - - if (!fbo) - { - f = 0; - } - else - { - if (!*fbo) - { - GL_EXTCALL(glGenFramebuffersEXT(1, fbo)); - checkGLcall("glGenFramebuffersEXT()"); - TRACE("Created FBO %u.\n", *fbo); - } - f = *fbo; - } + const IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; - switch (target) + if (!*fbo) { - case GL_READ_FRAMEBUFFER_EXT: - if (context->fbo_read_binding == f) return; - context->fbo_read_binding = f; - break; - - case GL_DRAW_FRAMEBUFFER_EXT: - if (context->fbo_draw_binding == f) return; - context->fbo_draw_binding = f; - break; - - case GL_FRAMEBUFFER_EXT: - if (context->fbo_read_binding == f - && context->fbo_draw_binding == f) return; - context->fbo_read_binding = f; - context->fbo_draw_binding = f; - break; - - default: - FIXME("Unhandled target %#x.\n", target); - break; + GL_EXTCALL(glGenFramebuffersEXT(1, fbo)); + checkGLcall("glGenFramebuffersEXT()"); + TRACE("Created FBO %d\n", *fbo); } - GL_EXTCALL(glBindFramebufferEXT(target, f)); + GL_EXTCALL(glBindFramebufferEXT(target, *fbo)); checkGLcall("glBindFramebuffer()"); } /* GL locking is done by the caller */ -static void context_clean_fbo_attachments(const struct wined3d_gl_info *gl_info) +static void context_clean_fbo_attachments(IWineD3DDeviceImpl *This) { unsigned int i; @@ -101,23 +72,24 @@ static void context_clean_fbo_attachments(const struct wined3d_gl_info *gl_info) } /* GL locking is done by the caller */ -static void context_destroy_fbo(struct WineD3DContext *context, GLuint *fbo) +static void context_destroy_fbo(IWineD3DDeviceImpl *This, const GLuint *fbo) { - const struct wined3d_gl_info *gl_info = context->gl_info; + GL_EXTCALL(glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, *fbo)); + checkGLcall("glBindFramebuffer()"); - context_bind_fbo(context, GL_FRAMEBUFFER_EXT, fbo); - context_clean_fbo_attachments(gl_info); - context_bind_fbo(context, GL_FRAMEBUFFER_EXT, NULL); + context_clean_fbo_attachments(This); + GL_EXTCALL(glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0)); + checkGLcall("glBindFramebuffer()"); GL_EXTCALL(glDeleteFramebuffersEXT(1, fbo)); checkGLcall("glDeleteFramebuffers()"); } /* GL locking is done by the caller */ -static void context_apply_attachment_filter_states(IWineD3DSurface *surface, BOOL force_preload) +static void context_apply_attachment_filter_states(IWineD3DDevice *iface, IWineD3DSurface *surface, BOOL force_preload) { + IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; const IWineD3DSurfaceImpl *surface_impl = (IWineD3DSurfaceImpl *)surface; - IWineD3DDeviceImpl *device = surface_impl->resource.wineD3DDevice; IWineD3DBaseTextureImpl *texture_impl; BOOL update_minfilter = FALSE; BOOL update_magfilter = FALSE; @@ -142,7 +114,7 @@ static void context_apply_attachment_filter_states(IWineD3DSurface *surface, BOO if (texture_impl->baseTexture.bindCount) { WARN("Render targets should not be bound to a sampler\n"); - IWineD3DDeviceImpl_MarkStateDirty(device, STATE_SAMPLER(texture_impl->baseTexture.sampler)); + IWineD3DDeviceImpl_MarkStateDirty(This, STATE_SAMPLER(texture_impl->baseTexture.sampler)); } IWineD3DBaseTexture_Release((IWineD3DBaseTexture *)texture_impl); @@ -153,7 +125,7 @@ static void context_apply_attachment_filter_states(IWineD3DSurface *surface, BOO GLenum target, bind_target; GLint old_binding; - target = surface_impl->texture_target; + target = surface_impl->glDescription.target; if (target == GL_TEXTURE_2D) { bind_target = GL_TEXTURE_2D; @@ -168,7 +140,7 @@ static void context_apply_attachment_filter_states(IWineD3DSurface *surface, BOO surface_internal_preload(surface, SRGB_RGB); - glBindTexture(bind_target, surface_impl->texture_name); + glBindTexture(bind_target, surface_impl->glDescription.textureName); if (update_minfilter) glTexParameteri(bind_target, GL_TEXTURE_MIN_FILTER, GL_NEAREST); if (update_magfilter) glTexParameteri(bind_target, GL_TEXTURE_MAG_FILTER, GL_NEAREST); glBindTexture(bind_target, old_binding); @@ -178,11 +150,9 @@ static void context_apply_attachment_filter_states(IWineD3DSurface *surface, BOO } /* GL locking is done by the caller */ -void context_attach_depth_stencil_fbo(struct WineD3DContext *context, - GLenum fbo_target, IWineD3DSurface *depth_stencil, BOOL use_render_buffer) +void context_attach_depth_stencil_fbo(IWineD3DDeviceImpl *This, GLenum fbo_target, IWineD3DSurface *depth_stencil, BOOL use_render_buffer) { IWineD3DSurfaceImpl *depth_stencil_impl = (IWineD3DSurfaceImpl *)depth_stencil; - const struct wined3d_gl_info *gl_info = context->gl_info; TRACE("Attach depth stencil %p\n", depth_stencil); @@ -208,21 +178,21 @@ void context_attach_depth_stencil_fbo(struct WineD3DContext *context, } else { - context_apply_attachment_filter_states(depth_stencil, TRUE); + context_apply_attachment_filter_states((IWineD3DDevice *)This, depth_stencil, TRUE); if (format_flags & WINED3DFMT_FLAG_DEPTH) { GL_EXTCALL(glFramebufferTexture2DEXT(fbo_target, GL_DEPTH_ATTACHMENT_EXT, - depth_stencil_impl->texture_target, depth_stencil_impl->texture_name, - depth_stencil_impl->texture_level)); + depth_stencil_impl->glDescription.target, depth_stencil_impl->glDescription.textureName, + depth_stencil_impl->glDescription.level)); checkGLcall("glFramebufferTexture2DEXT()"); } if (format_flags & WINED3DFMT_FLAG_STENCIL) { GL_EXTCALL(glFramebufferTexture2DEXT(fbo_target, GL_STENCIL_ATTACHMENT_EXT, - depth_stencil_impl->texture_target, depth_stencil_impl->texture_name, - depth_stencil_impl->texture_level)); + depth_stencil_impl->glDescription.target, depth_stencil_impl->glDescription.textureName, + depth_stencil_impl->glDescription.level)); checkGLcall("glFramebufferTexture2DEXT()"); } } @@ -250,20 +220,18 @@ void context_attach_depth_stencil_fbo(struct WineD3DContext *context, } /* GL locking is done by the caller */ -void context_attach_surface_fbo(const struct WineD3DContext *context, - GLenum fbo_target, DWORD idx, IWineD3DSurface *surface) +void context_attach_surface_fbo(IWineD3DDeviceImpl *This, GLenum fbo_target, DWORD idx, IWineD3DSurface *surface) { const IWineD3DSurfaceImpl *surface_impl = (IWineD3DSurfaceImpl *)surface; - const struct wined3d_gl_info *gl_info = context->gl_info; TRACE("Attach surface %p to %u\n", surface, idx); if (surface) { - context_apply_attachment_filter_states(surface, TRUE); + context_apply_attachment_filter_states((IWineD3DDevice *)This, surface, TRUE); - GL_EXTCALL(glFramebufferTexture2DEXT(fbo_target, GL_COLOR_ATTACHMENT0_EXT + idx, surface_impl->texture_target, - surface_impl->texture_name, surface_impl->texture_level)); + GL_EXTCALL(glFramebufferTexture2DEXT(fbo_target, GL_COLOR_ATTACHMENT0_EXT + idx, surface_impl->glDescription.target, + surface_impl->glDescription.textureName, surface_impl->glDescription.level)); checkGLcall("glFramebufferTexture2DEXT()"); } else { GL_EXTCALL(glFramebufferTexture2DEXT(fbo_target, GL_COLOR_ATTACHMENT0_EXT + idx, GL_TEXTURE_2D, 0, 0)); @@ -272,9 +240,9 @@ void context_attach_surface_fbo(const struct WineD3DContext *context, } /* GL locking is done by the caller */ -static void context_check_fbo_status(struct WineD3DContext *context) +static void context_check_fbo_status(IWineD3DDevice *iface) { - const struct wined3d_gl_info *gl_info = context->gl_info; + IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; GLenum status; status = GL_EXTCALL(glCheckFramebufferStatusEXT(GL_FRAMEBUFFER_EXT)); @@ -289,7 +257,7 @@ static void context_check_fbo_status(struct WineD3DContext *context) /* Dump the FBO attachments */ for (i = 0; i < GL_LIMITS(buffers); ++i) { - attachment = (IWineD3DSurfaceImpl *)context->current_fbo->render_targets[i]; + attachment = (IWineD3DSurfaceImpl *)This->activeContext->current_fbo->render_targets[i]; if (attachment) { FIXME("\tColor attachment %d: (%p) %s %ux%u\n", @@ -297,7 +265,7 @@ static void context_check_fbo_status(struct WineD3DContext *context) attachment->pow2Width, attachment->pow2Height); } } - attachment = (IWineD3DSurfaceImpl *)context->current_fbo->depth_stencil; + attachment = (IWineD3DSurfaceImpl *)This->activeContext->current_fbo->depth_stencil; if (attachment) { FIXME("\tDepth attachment: (%p) %s %ux%u\n", @@ -307,16 +275,15 @@ static void context_check_fbo_status(struct WineD3DContext *context) } } -static struct fbo_entry *context_create_fbo_entry(struct WineD3DContext *context) +static struct fbo_entry *context_create_fbo_entry(IWineD3DDevice *iface) { - IWineD3DDeviceImpl *device = ((IWineD3DSurfaceImpl *)context->surface)->resource.wineD3DDevice; - const struct wined3d_gl_info *gl_info = context->gl_info; + IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; struct fbo_entry *entry; entry = HeapAlloc(GetProcessHeap(), 0, sizeof(*entry)); entry->render_targets = HeapAlloc(GetProcessHeap(), 0, GL_LIMITS(buffers) * sizeof(*entry->render_targets)); - memcpy(entry->render_targets, device->render_targets, GL_LIMITS(buffers) * sizeof(*entry->render_targets)); - entry->depth_stencil = device->stencilBufferTarget; + memcpy(entry->render_targets, This->render_targets, GL_LIMITS(buffers) * sizeof(*entry->render_targets)); + entry->depth_stencil = This->stencilBufferTarget; entry->attached = FALSE; entry->id = 0; @@ -324,26 +291,26 @@ static struct fbo_entry *context_create_fbo_entry(struct WineD3DContext *context } /* GL locking is done by the caller */ -static void context_reuse_fbo_entry(struct WineD3DContext *context, struct fbo_entry *entry) +static void context_reuse_fbo_entry(IWineD3DDevice *iface, struct fbo_entry *entry) { - IWineD3DDeviceImpl *device = ((IWineD3DSurfaceImpl *)context->surface)->resource.wineD3DDevice; - const struct wined3d_gl_info *gl_info = context->gl_info; + IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; - context_bind_fbo(context, GL_FRAMEBUFFER_EXT, &entry->id); - context_clean_fbo_attachments(gl_info); + GL_EXTCALL(glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, entry->id)); + checkGLcall("glBindFramebuffer()"); + context_clean_fbo_attachments(This); - memcpy(entry->render_targets, device->render_targets, GL_LIMITS(buffers) * sizeof(*entry->render_targets)); - entry->depth_stencil = device->stencilBufferTarget; + memcpy(entry->render_targets, This->render_targets, GL_LIMITS(buffers) * sizeof(*entry->render_targets)); + entry->depth_stencil = This->stencilBufferTarget; entry->attached = FALSE; } /* GL locking is done by the caller */ -static void context_destroy_fbo_entry(struct WineD3DContext *context, struct fbo_entry *entry) +static void context_destroy_fbo_entry(IWineD3DDeviceImpl *This, WineD3DContext *context, struct fbo_entry *entry) { if (entry->id) { TRACE("Destroy FBO %d\n", entry->id); - context_destroy_fbo(context, &entry->id); + context_destroy_fbo(This, &entry->id); } --context->fbo_entry_count; list_remove(&entry->entry); @@ -353,16 +320,15 @@ static void context_destroy_fbo_entry(struct WineD3DContext *context, struct fbo /* GL locking is done by the caller */ -static struct fbo_entry *context_find_fbo_entry(struct WineD3DContext *context) +static struct fbo_entry *context_find_fbo_entry(IWineD3DDevice *iface, WineD3DContext *context) { - IWineD3DDeviceImpl *device = ((IWineD3DSurfaceImpl *)context->surface)->resource.wineD3DDevice; - const struct wined3d_gl_info *gl_info = context->gl_info; + IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; struct fbo_entry *entry; LIST_FOR_EACH_ENTRY(entry, &context->fbo_list, struct fbo_entry, entry) { - if (!memcmp(entry->render_targets, device->render_targets, GL_LIMITS(buffers) * sizeof(*entry->render_targets)) - && entry->depth_stencil == device->stencilBufferTarget) + if (!memcmp(entry->render_targets, This->render_targets, GL_LIMITS(buffers) * sizeof(*entry->render_targets)) + && entry->depth_stencil == This->stencilBufferTarget) { list_remove(&entry->entry); list_add_head(&context->fbo_list, &entry->entry); @@ -372,14 +338,14 @@ static struct fbo_entry *context_find_fbo_entry(struct WineD3DContext *context) if (context->fbo_entry_count < WINED3D_MAX_FBO_ENTRIES) { - entry = context_create_fbo_entry(context); + entry = context_create_fbo_entry(iface); list_add_head(&context->fbo_list, &entry->entry); ++context->fbo_entry_count; } else { entry = LIST_ENTRY(list_tail(&context->fbo_list), struct fbo_entry, entry); - context_reuse_fbo_entry(context, entry); + context_reuse_fbo_entry(iface, entry); list_remove(&entry->entry); list_add_head(&context->fbo_list, &entry->entry); } @@ -388,191 +354,67 @@ static struct fbo_entry *context_find_fbo_entry(struct WineD3DContext *context) } /* GL locking is done by the caller */ -static void context_apply_fbo_entry(struct WineD3DContext *context, struct fbo_entry *entry) +static void context_apply_fbo_entry(IWineD3DDevice *iface, struct fbo_entry *entry) { - IWineD3DDeviceImpl *device = ((IWineD3DSurfaceImpl *)context->surface)->resource.wineD3DDevice; - const struct wined3d_gl_info *gl_info = context->gl_info; + IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; unsigned int i; - context_bind_fbo(context, GL_FRAMEBUFFER_EXT, &entry->id); + context_bind_fbo(iface, GL_FRAMEBUFFER_EXT, &entry->id); if (!entry->attached) { /* Apply render targets */ for (i = 0; i < GL_LIMITS(buffers); ++i) { - IWineD3DSurface *render_target = device->render_targets[i]; - context_attach_surface_fbo(context, GL_FRAMEBUFFER_EXT, i, render_target); + IWineD3DSurface *render_target = This->render_targets[i]; + context_attach_surface_fbo(This, GL_FRAMEBUFFER_EXT, i, render_target); } /* Apply depth targets */ - if (device->stencilBufferTarget) - { - unsigned int w = ((IWineD3DSurfaceImpl *)device->render_targets[0])->pow2Width; - unsigned int h = ((IWineD3DSurfaceImpl *)device->render_targets[0])->pow2Height; + if (This->stencilBufferTarget) { + unsigned int w = ((IWineD3DSurfaceImpl *)This->render_targets[0])->pow2Width; + unsigned int h = ((IWineD3DSurfaceImpl *)This->render_targets[0])->pow2Height; - surface_set_compatible_renderbuffer(device->stencilBufferTarget, w, h); + surface_set_compatible_renderbuffer(This->stencilBufferTarget, w, h); } - context_attach_depth_stencil_fbo(context, GL_FRAMEBUFFER_EXT, device->stencilBufferTarget, TRUE); + context_attach_depth_stencil_fbo(This, GL_FRAMEBUFFER_EXT, This->stencilBufferTarget, TRUE); entry->attached = TRUE; } else { for (i = 0; i < GL_LIMITS(buffers); ++i) { - if (device->render_targets[i]) - context_apply_attachment_filter_states(device->render_targets[i], FALSE); + if (This->render_targets[i]) + context_apply_attachment_filter_states(iface, This->render_targets[i], FALSE); } - if (device->stencilBufferTarget) - context_apply_attachment_filter_states(device->stencilBufferTarget, FALSE); + if (This->stencilBufferTarget) + context_apply_attachment_filter_states(iface, This->stencilBufferTarget, FALSE); } for (i = 0; i < GL_LIMITS(buffers); ++i) { - if (device->render_targets[i]) - device->draw_buffers[i] = GL_COLOR_ATTACHMENT0_EXT + i; + if (This->render_targets[i]) + This->draw_buffers[i] = GL_COLOR_ATTACHMENT0_EXT + i; else - device->draw_buffers[i] = GL_NONE; + This->draw_buffers[i] = GL_NONE; } } /* GL locking is done by the caller */ -static void context_apply_fbo_state(struct WineD3DContext *context) +static void context_apply_fbo_state(IWineD3DDevice *iface) { - IWineD3DDeviceImpl *device = ((IWineD3DSurfaceImpl *)context->surface)->resource.wineD3DDevice; + IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; + WineD3DContext *context = This->activeContext; - if (device->render_offscreen) + if (This->render_offscreen) { - context->current_fbo = context_find_fbo_entry(context); - context_apply_fbo_entry(context, context->current_fbo); + context->current_fbo = context_find_fbo_entry(iface, context); + context_apply_fbo_entry(iface, context->current_fbo); } else { context->current_fbo = NULL; - context_bind_fbo(context, GL_FRAMEBUFFER_EXT, NULL); - } - - context_check_fbo_status(context); -} - -/* Context activation is done by the caller. */ -void context_alloc_occlusion_query(struct WineD3DContext *context, struct wined3d_occlusion_query *query) -{ - const struct wined3d_gl_info *gl_info = context->gl_info; - - if (context->free_occlusion_query_count) - { - query->id = context->free_occlusion_queries[--context->free_occlusion_query_count]; - } - else - { - if (GL_SUPPORT(ARB_OCCLUSION_QUERY)) - { - ENTER_GL(); - GL_EXTCALL(glGenQueriesARB(1, &query->id)); - checkGLcall("glGenQueriesARB"); - LEAVE_GL(); - - TRACE("Allocated occlusion query %u in context %p.\n", query->id, context); - } - else - { - WARN("Occlusion queries not supported, not allocating query id.\n"); - query->id = 0; - } - } - - query->context = context; - list_add_head(&context->occlusion_queries, &query->entry); -} - -void context_free_occlusion_query(struct wined3d_occlusion_query *query) -{ - struct WineD3DContext *context = query->context; - - list_remove(&query->entry); - query->context = NULL; - - if (context->free_occlusion_query_count >= context->free_occlusion_query_size - 1) - { - UINT new_size = context->free_occlusion_query_size << 1; - GLuint *new_data = HeapReAlloc(GetProcessHeap(), 0, context->free_occlusion_queries, - new_size * sizeof(*context->free_occlusion_queries)); - - if (!new_data) - { - ERR("Failed to grow free list, leaking query %u in context %p.\n", query->id, context); - return; - } - - context->free_occlusion_query_size = new_size; - context->free_occlusion_queries = new_data; - } - - context->free_occlusion_queries[context->free_occlusion_query_count++] = query->id; -} - -/* Context activation is done by the caller. */ -void context_alloc_event_query(struct WineD3DContext *context, struct wined3d_event_query *query) -{ - const struct wined3d_gl_info *gl_info = context->gl_info; - - if (context->free_event_query_count) - { - query->id = context->free_event_queries[--context->free_event_query_count]; - } - else - { - if (GL_SUPPORT(APPLE_FENCE)) - { - ENTER_GL(); - GL_EXTCALL(glGenFencesAPPLE(1, &query->id)); - checkGLcall("glGenFencesAPPLE"); - LEAVE_GL(); - - TRACE("Allocated event query %u in context %p.\n", query->id, context); - } - else if(GL_SUPPORT(NV_FENCE)) - { - ENTER_GL(); - GL_EXTCALL(glGenFencesNV(1, &query->id)); - checkGLcall("glGenFencesNV"); - LEAVE_GL(); - - TRACE("Allocated event query %u in context %p.\n", query->id, context); - } - else - { - WARN("Event queries not supported, not allocating query id.\n"); - query->id = 0; - } - } - - query->context = context; - list_add_head(&context->event_queries, &query->entry); -} - -void context_free_event_query(struct wined3d_event_query *query) -{ - struct WineD3DContext *context = query->context; - - list_remove(&query->entry); - query->context = NULL; - - if (context->free_event_query_count >= context->free_event_query_size - 1) - { - UINT new_size = context->free_event_query_size << 1; - GLuint *new_data = HeapReAlloc(GetProcessHeap(), 0, context->free_event_queries, - new_size * sizeof(*context->free_event_queries)); - - if (!new_data) - { - ERR("Failed to grow free list, leaking query %u in context %p.\n", query->id, context); - return; - } - - context->free_event_query_size = new_size; - context->free_event_queries = new_data; + GL_EXTCALL(glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0)); } - context->free_event_queries[context->free_event_query_count++] = query->id; + context_check_fbo_status(iface); } void context_resource_released(IWineD3DDevice *iface, IWineD3DResource *resource, WINED3DRESOURCETYPE type) @@ -580,18 +422,13 @@ void context_resource_released(IWineD3DDevice *iface, IWineD3DResource *resource IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; UINT i; - if (!This->d3d_initialized) return; - switch(type) { case WINED3DRTYPE_SURFACE: { - ActivateContext(This, NULL, CTXUSAGE_RESOURCELOAD); - for (i = 0; i < This->numContexts; ++i) { WineD3DContext *context = This->contexts[i]; - const struct wined3d_gl_info *gl_info = context->gl_info; struct fbo_entry *entry, *entry2; ENTER_GL(); @@ -605,13 +442,13 @@ void context_resource_released(IWineD3DDevice *iface, IWineD3DResource *resource { if (entry->render_targets[j] == (IWineD3DSurface *)resource) { - context_destroy_fbo_entry(context, entry); + context_destroy_fbo_entry(This, context, entry); destroyed = TRUE; } } if (!destroyed && entry->depth_stencil == (IWineD3DSurface *)resource) - context_destroy_fbo_entry(context, entry); + context_destroy_fbo_entry(This, context, entry); } LEAVE_GL(); @@ -625,151 +462,6 @@ void context_resource_released(IWineD3DDevice *iface, IWineD3DResource *resource } } -static void context_destroy_gl_resources(struct WineD3DContext *context) -{ - const struct wined3d_gl_info *gl_info = context->gl_info; - struct wined3d_occlusion_query *occlusion_query; - struct wined3d_event_query *event_query; - struct fbo_entry *entry, *entry2; - BOOL has_glctx; - - has_glctx = pwglMakeCurrent(context->hdc, context->glCtx); - if (!has_glctx) WARN("Failed to activate context. Window already destroyed?\n"); - - ENTER_GL(); - - LIST_FOR_EACH_ENTRY(occlusion_query, &context->occlusion_queries, struct wined3d_occlusion_query, entry) - { - if (has_glctx && GL_SUPPORT(ARB_OCCLUSION_QUERY)) GL_EXTCALL(glDeleteQueriesARB(1, &occlusion_query->id)); - occlusion_query->context = NULL; - } - - LIST_FOR_EACH_ENTRY(event_query, &context->event_queries, struct wined3d_event_query, entry) - { - if (has_glctx) - { - if (GL_SUPPORT(APPLE_FENCE)) GL_EXTCALL(glDeleteFencesAPPLE(1, &event_query->id)); - else if (GL_SUPPORT(NV_FENCE)) GL_EXTCALL(glDeleteFencesNV(1, &event_query->id)); - } - event_query->context = NULL; - } - - LIST_FOR_EACH_ENTRY_SAFE(entry, entry2, &context->fbo_list, struct fbo_entry, entry) { - if (!has_glctx) entry->id = 0; - context_destroy_fbo_entry(context, entry); - } - if (has_glctx) - { - if (context->src_fbo) - { - TRACE("Destroy src FBO %d\n", context->src_fbo); - context_destroy_fbo(context, &context->src_fbo); - } - if (context->dst_fbo) - { - TRACE("Destroy dst FBO %d\n", context->dst_fbo); - context_destroy_fbo(context, &context->dst_fbo); - } - if (context->dummy_arbfp_prog) - { - GL_EXTCALL(glDeleteProgramsARB(1, &context->dummy_arbfp_prog)); - } - - GL_EXTCALL(glDeleteQueriesARB(context->free_occlusion_query_count, context->free_occlusion_queries)); - - if (GL_SUPPORT(APPLE_FENCE)) - GL_EXTCALL(glDeleteFencesAPPLE(context->free_event_query_count, context->free_event_queries)); - else if (GL_SUPPORT(NV_FENCE)) - GL_EXTCALL(glDeleteFencesNV(context->free_event_query_count, context->free_event_queries)); - - checkGLcall("context cleanup"); - } - - LEAVE_GL(); - - HeapFree(GetProcessHeap(), 0, context->free_occlusion_queries); - HeapFree(GetProcessHeap(), 0, context->free_event_queries); - - if (!pwglMakeCurrent(NULL, NULL)) - { - ERR("Failed to disable GL context.\n"); - } - - if (context->isPBuffer) - { - GL_EXTCALL(wglReleasePbufferDCARB(context->pbuffer, context->hdc)); - GL_EXTCALL(wglDestroyPbufferARB(context->pbuffer)); - } - else - { - ReleaseDC(context->win_handle, context->hdc); - } - - pwglDeleteContext(context->glCtx); -} - -DWORD context_get_tls_idx(void) -{ - return wined3d_context_tls_idx; -} - -void context_set_tls_idx(DWORD idx) -{ - wined3d_context_tls_idx = idx; -} - -struct WineD3DContext *context_get_current(void) -{ - return TlsGetValue(wined3d_context_tls_idx); -} - -BOOL context_set_current(struct WineD3DContext *ctx) -{ - struct WineD3DContext *old = context_get_current(); - - if (old == ctx) - { - TRACE("Already using D3D context %p.\n", ctx); - return TRUE; - } - - if (old) - { - if (old->destroyed) - { - TRACE("Switching away from destroyed context %p.\n", old); - context_destroy_gl_resources(old); - HeapFree(GetProcessHeap(), 0, old); - } - else - { - old->current = 0; - } - } - - if (ctx) - { - TRACE("Switching to D3D context %p, GL context %p, device context %p.\n", ctx, ctx->glCtx, ctx->hdc); - if (!pwglMakeCurrent(ctx->hdc, ctx->glCtx)) - { - ERR("Failed to make GL context %p current on device context %p.\n", ctx->glCtx, ctx->hdc); - return FALSE; - } - ctx->current = 1; - } - else - { - TRACE("Clearing current D3D context.\n"); - if (!pwglMakeCurrent(NULL, NULL)) - { - ERR("Failed to clear current GL context.\n"); - return FALSE; - } - } - - return TlsSetValue(wined3d_context_tls_idx, ctx); -} - /***************************************************************************** * Context_MarkStateDirty * @@ -1043,12 +735,11 @@ static int WineD3D_ChoosePixelFormat(IWineD3DDeviceImpl *This, HDC hdc, * *****************************************************************************/ WineD3DContext *CreateContext(IWineD3DDeviceImpl *This, IWineD3DSurfaceImpl *target, HWND win_handle, BOOL create_pbuffer, const WINED3DPRESENT_PARAMETERS *pPresentParms) { - const struct wined3d_gl_info *gl_info = &This->adapter->gl_info; + HDC oldDrawable, hdc; HPBUFFERARB pbuffer = NULL; + HGLRC ctx = NULL, oldCtx; WineD3DContext *ret = NULL; unsigned int s; - HGLRC ctx; - HDC hdc; TRACE("(%p): Creating a %s context for render target %p\n", This, create_pbuffer ? "offscreen" : "onscreen", target); @@ -1164,7 +855,7 @@ WineD3DContext *CreateContext(IWineD3DDeviceImpl *This, IWineD3DSurfaceImpl *tar /* If we still don't have a pixel format, something is very wrong as ChoosePixelFormat barely fails */ if(!iPixelFormat) { ERR("Can't find a suitable iPixelFormat\n"); - return NULL; + return FALSE; } DescribePixelFormat(hdc, iPixelFormat, sizeof(pfd), &pfd); @@ -1183,7 +874,7 @@ WineD3DContext *CreateContext(IWineD3DDeviceImpl *This, IWineD3DSurfaceImpl *tar if(!res) { ERR("wglSetPixelFormatWINE failed on HDC=%p for iPixelFormat=%d\n", hdc, iPixelFormat); - return NULL; + return FALSE; } } else if(oldPixelFormat) { /* OpenGL doesn't allow pixel format adjustments. Print an error and continue using the old format. @@ -1191,21 +882,13 @@ WineD3DContext *CreateContext(IWineD3DDeviceImpl *This, IWineD3DSurfaceImpl *tar ERR("HDC=%p is already set to iPixelFormat=%d and OpenGL doesn't allow changes!\n", hdc, oldPixelFormat); } else { ERR("SetPixelFormat failed on HDC=%p for iPixelFormat=%d\n", hdc, iPixelFormat); - return NULL; + return FALSE; } } } ctx = pwglCreateContext(hdc); - if (This->numContexts) - { - if (!pwglShareLists(This->contexts[0]->glCtx, ctx)) - { - DWORD err = GetLastError(); - ERR("wglShareLists(%p, %p) failed, last error %#x.\n", - This->contexts[0]->glCtx, ctx, err); - } - } + if(This->numContexts) pwglShareLists(This->contexts[0]->glCtx, ctx); if(!ctx) { ERR("Failed to create a WGL context\n"); @@ -1218,20 +901,14 @@ WineD3DContext *CreateContext(IWineD3DDeviceImpl *This, IWineD3DSurfaceImpl *tar ret = AddContextToArray(This, win_handle, hdc, ctx, pbuffer); if(!ret) { ERR("Failed to add the newly created context to the context list\n"); - if (!pwglDeleteContext(ctx)) - { - DWORD err = GetLastError(); - ERR("wglDeleteContext(%p) failed, last error %#x.\n", ctx, err); - } + pwglDeleteContext(ctx); if(create_pbuffer) { GL_EXTCALL(wglReleasePbufferDCARB(pbuffer, hdc)); GL_EXTCALL(wglDestroyPbufferARB(pbuffer)); } goto out; } - ret->gl_info = &This->adapter->gl_info; ret->surface = (IWineD3DSurface *) target; - ret->current_rt = (IWineD3DSurface *)target; ret->isPBuffer = create_pbuffer; ret->tid = GetCurrentThreadId(); if(This->shader_backend->shader_dirtifyable_constants((IWineD3DDevice *) This)) { @@ -1246,27 +923,18 @@ WineD3DContext *CreateContext(IWineD3DDeviceImpl *This, IWineD3DSurfaceImpl *tar sizeof(*ret->pshader_const_dirty) * GL_LIMITS(pshader_constantsF)); } - ret->free_occlusion_query_size = 4; - ret->free_occlusion_queries = HeapAlloc(GetProcessHeap(), 0, - ret->free_occlusion_query_size * sizeof(*ret->free_occlusion_queries)); - if (!ret->free_occlusion_queries) goto out; - - list_init(&ret->occlusion_queries); - - ret->free_event_query_size = 4; - ret->free_event_queries = HeapAlloc(GetProcessHeap(), 0, - ret->free_event_query_size * sizeof(*ret->free_event_queries)); - if (!ret->free_event_queries) goto out; - - list_init(&ret->event_queries); - TRACE("Successfully created new context %p\n", ret); list_init(&ret->fbo_list); /* Set up the context defaults */ - if (!context_set_current(ret)) - { + oldCtx = pwglGetCurrentContext(); + oldDrawable = pwglGetCurrentDC(); + if(oldCtx && oldDrawable) { + /* See comment in ActivateContext context switching */ + This->frag_pipe->enable_extension((IWineD3DDevice *) This, FALSE); + } + if(pwglMakeCurrent(hdc, ctx) == FALSE) { ERR("Cannot activate context to set up defaults\n"); goto out; } @@ -1277,7 +945,7 @@ WineD3DContext *CreateContext(IWineD3DDeviceImpl *This, IWineD3DSurfaceImpl *tar TRACE("Setting up the screen\n"); /* Clear the screen */ - glClearColor(1.0f, 0.0f, 0.0f, 0.0f); + glClearColor(1.0, 0.0, 0.0, 0.0); checkGLcall("glClearColor"); glClearIndex(0); glClearDepth(1); @@ -1321,7 +989,7 @@ WineD3DContext *CreateContext(IWineD3DDeviceImpl *This, IWineD3DSurfaceImpl *tar for(s = 1; s < GL_LIMITS(textures); s++) { GL_EXTCALL(glActiveTextureARB(GL_TEXTURE0_ARB + s)); glTexEnvi(GL_TEXTURE_SHADER_NV, GL_PREVIOUS_TEXTURE_INPUT_NV, GL_TEXTURE0_ARB + s - 1); - checkGLcall("glTexEnvi(GL_TEXTURE_SHADER_NV, GL_PREVIOUS_TEXTURE_INPUT_NV, ..."); + checkGLcall("glTexEnvi(GL_TEXTURE_SHADER_NV, GL_PREVIOUS_TEXTURE_INPUT_NV, ...\n"); } } if(GL_SUPPORT(ARB_FRAGMENT_PROGRAM)) { @@ -1346,23 +1014,23 @@ WineD3DContext *CreateContext(IWineD3DDeviceImpl *This, IWineD3DSurfaceImpl *tar for(s = 0; s < GL_LIMITS(point_sprite_units); s++) { GL_EXTCALL(glActiveTextureARB(GL_TEXTURE0_ARB + s)); glTexEnvi(GL_POINT_SPRITE_ARB, GL_COORD_REPLACE_ARB, GL_TRUE); - checkGLcall("glTexEnvi(GL_POINT_SPRITE_ARB, GL_COORD_REPLACE_ARB, GL_TRUE)"); + checkGLcall("glTexEnvi(GL_POINT_SPRITE_ARB, GL_COORD_REPLACE_ARB, GL_TRUE)\n"); } LEAVE_GL(); + /* Never keep GL_FRAGMENT_SHADER_ATI enabled on a context that we switch away from, + * but enable it for the first context we create, and reenable it on the old context + */ + if(oldDrawable && oldCtx) { + pwglMakeCurrent(oldDrawable, oldCtx); + } else { + last_device = This; + } This->frag_pipe->enable_extension((IWineD3DDevice *) This, TRUE); return ret; out: - if (ret) - { - HeapFree(GetProcessHeap(), 0, ret->free_event_queries); - HeapFree(GetProcessHeap(), 0, ret->free_occlusion_queries); - HeapFree(GetProcessHeap(), 0, ret->pshader_const_dirty); - HeapFree(GetProcessHeap(), 0, ret->vshader_const_dirty); - HeapFree(GetProcessHeap(), 0, ret); - } return NULL; } @@ -1391,6 +1059,7 @@ static void RemoveContextFromArray(IWineD3DDeviceImpl *This, WineD3DContext *con { if (This->contexts[i] == context) { + HeapFree(GetProcessHeap(), 0, context); found = TRUE; break; } @@ -1436,32 +1105,53 @@ static void RemoveContextFromArray(IWineD3DDeviceImpl *This, WineD3DContext *con * context: Context to destroy * *****************************************************************************/ -void DestroyContext(IWineD3DDeviceImpl *This, WineD3DContext *context) -{ - BOOL destroy; +void DestroyContext(IWineD3DDeviceImpl *This, WineD3DContext *context) { + struct fbo_entry *entry, *entry2; TRACE("Destroying ctx %p\n", context); - if (context->tid == GetCurrentThreadId() || !context->current) - { - context_destroy_gl_resources(context); - destroy = TRUE; + /* The correct GL context needs to be active to cleanup the GL resources below */ + if(pwglGetCurrentContext() != context->glCtx){ + pwglMakeCurrent(context->hdc, context->glCtx); + last_device = NULL; + } - if (!context_set_current(NULL)) - { - ERR("Failed to clear current D3D context.\n"); - } + ENTER_GL(); + + LIST_FOR_EACH_ENTRY_SAFE(entry, entry2, &context->fbo_list, struct fbo_entry, entry) { + context_destroy_fbo_entry(This, context, entry); } - else + if (context->src_fbo) { + TRACE("Destroy src FBO %d\n", context->src_fbo); + context_destroy_fbo(This, &context->src_fbo); + } + if (context->dst_fbo) { + TRACE("Destroy dst FBO %d\n", context->dst_fbo); + context_destroy_fbo(This, &context->dst_fbo); + } + if(context->dummy_arbfp_prog) { + GL_EXTCALL(glDeleteProgramsARB(1, &context->dummy_arbfp_prog)); + } + + LEAVE_GL(); + + if (This->activeContext == context) { - context->destroyed = 1; - destroy = FALSE; + This->activeContext = NULL; + TRACE("Destroying the active context.\n"); } + /* Cleanup the GL context */ + pwglMakeCurrent(NULL, NULL); + if(context->isPBuffer) { + GL_EXTCALL(wglReleasePbufferDCARB(context->pbuffer, context->hdc)); + GL_EXTCALL(wglDestroyPbufferARB(context->pbuffer)); + } else ReleaseDC(context->win_handle, context->hdc); + pwglDeleteContext(context->glCtx); + HeapFree(GetProcessHeap(), 0, context->vshader_const_dirty); HeapFree(GetProcessHeap(), 0, context->pshader_const_dirty); RemoveContextFromArray(This, context); - if (destroy) HeapFree(GetProcessHeap(), 0, context); } /* GL locking is done by the caller */ @@ -1494,11 +1184,9 @@ static inline void set_blit_dimension(UINT width, UINT height) { * height: render target height * *****************************************************************************/ -/* Context activation is done by the caller. */ static inline void SetupForBlit(IWineD3DDeviceImpl *This, WineD3DContext *context, UINT width, UINT height) { int i, sampler; const struct StateEntry *StateTable = This->StateTable; - const struct wined3d_gl_info *gl_info = context->gl_info; TRACE("Setting up context %p for blitting\n", context); if(context->last_was_blit) { @@ -1596,7 +1284,7 @@ static inline void SetupForBlit(IWineD3DDeviceImpl *This, WineD3DContext *contex if (GL_SUPPORT(EXT_TEXTURE_LOD_BIAS)) { glTexEnvf(GL_TEXTURE_FILTER_CONTROL_EXT, GL_TEXTURE_LOD_BIAS_EXT, - 0.0f); + 0.0); checkGLcall("glTexEnvi GL_TEXTURE_LOD_BIAS_EXT ..."); } @@ -1713,34 +1401,25 @@ static WineD3DContext *findThreadContextForSwapChain(IWineD3DSwapChain *swapchai static inline WineD3DContext *FindContext(IWineD3DDeviceImpl *This, IWineD3DSurface *target, DWORD tid) { IWineD3DSwapChain *swapchain = NULL; BOOL readTexture = wined3d_settings.offscreen_rendering_mode != ORM_FBO && This->render_offscreen; - struct WineD3DContext *current_context = context_get_current(); + WineD3DContext *context = This->activeContext; BOOL oldRenderOffscreen = This->render_offscreen; + const struct GlPixelFormatDesc *old = ((IWineD3DSurfaceImpl *)This->lastActiveRenderTarget)->resource.format_desc; + const struct GlPixelFormatDesc *new = ((IWineD3DSurfaceImpl *)target)->resource.format_desc; const struct StateEntry *StateTable = This->StateTable; - const struct GlPixelFormatDesc *old, *new; - struct WineD3DContext *context; - - if (current_context && current_context->destroyed) current_context = NULL; - if (!target) + /* To compensate the lack of format switching with some offscreen rendering methods and on onscreen buffers + * the alpha blend state changes with different render target formats + */ + if (old->format != new->format) { - if (current_context - && ((IWineD3DSurfaceImpl *)current_context->surface)->resource.wineD3DDevice == This) - { - target = current_context->current_rt; - } - else + /* Disable blending when the alpha mask has changed and when a format doesn't support blending */ + if ((old->alpha_mask && !new->alpha_mask) || (!old->alpha_mask && new->alpha_mask) + || !(new->Flags & WINED3DFMT_FLAG_POSTPIXELSHADER_BLENDING)) { - IWineD3DSwapChainImpl *swapchain = (IWineD3DSwapChainImpl *)This->swapchains[0]; - if (swapchain->backBuffer) target = swapchain->backBuffer[0]; - else target = swapchain->frontBuffer; + Context_MarkStateDirty(context, STATE_RENDER(WINED3DRS_ALPHABLENDENABLE), StateTable); } } - if (current_context && current_context->current_rt == target) - { - return current_context; - } - if (SUCCEEDED(IWineD3DSurface_GetContainer(target, &IID_IWineD3DSwapChain, (void **)&swapchain))) { TRACE("Rendering onscreen\n"); @@ -1758,90 +1437,92 @@ static inline WineD3DContext *FindContext(IWineD3DDeviceImpl *This, IWineD3DSurf } } IWineD3DSwapChain_Release(swapchain); - } - else - { + + if(oldRenderOffscreen) { + Context_MarkStateDirty(context, WINED3DTS_PROJECTION, StateTable); + Context_MarkStateDirty(context, STATE_VDECL, StateTable); + Context_MarkStateDirty(context, STATE_VIEWPORT, StateTable); + Context_MarkStateDirty(context, STATE_SCISSORRECT, StateTable); + Context_MarkStateDirty(context, STATE_FRONTFACE, StateTable); + } + + } else { TRACE("Rendering offscreen\n"); This->render_offscreen = TRUE; -retry: - if (wined3d_settings.offscreen_rendering_mode == ORM_PBUFFER) - { - IWineD3DSurfaceImpl *targetimpl = (IWineD3DSurfaceImpl *)target; - if (!This->pbufferContext - || This->pbufferWidth < targetimpl->currentDesc.Width - || This->pbufferHeight < targetimpl->currentDesc.Height) + switch(wined3d_settings.offscreen_rendering_mode) { + case ORM_FBO: + /* FBOs do not need a different context. Stay with whatever context is active at the moment */ + if(This->activeContext && tid == This->lastThread) { + context = This->activeContext; + } else { + /* This may happen if the app jumps straight into offscreen rendering + * Start using the context of the primary swapchain. tid == 0 is no problem + * for findThreadContextForSwapChain. + * + * Can also happen on thread switches - in that case findThreadContextForSwapChain + * is perfect to call. + */ + context = findThreadContextForSwapChain(This->swapchains[0], tid); + } + break; + + case ORM_PBUFFER: { - if (This->pbufferContext) DestroyContext(This, This->pbufferContext); - - /* The display is irrelevant here, the window is 0. But - * CreateContext needs a valid X connection. Create the context - * on the same server as the primary swapchain. The primary - * swapchain is exists at this point. */ - This->pbufferContext = CreateContext(This, targetimpl, - ((IWineD3DSwapChainImpl *)This->swapchains[0])->context[0]->win_handle, - TRUE /* pbuffer */, &((IWineD3DSwapChainImpl *)This->swapchains[0])->presentParms); - This->pbufferWidth = targetimpl->currentDesc.Width; - This->pbufferHeight = targetimpl->currentDesc.Height; + IWineD3DSurfaceImpl *targetimpl = (IWineD3DSurfaceImpl *) target; + if(This->pbufferContext == NULL || + This->pbufferWidth < targetimpl->currentDesc.Width || + This->pbufferHeight < targetimpl->currentDesc.Height) { + if(This->pbufferContext) { + DestroyContext(This, This->pbufferContext); + } + + /* The display is irrelevant here, the window is 0. But CreateContext needs a valid X connection. + * Create the context on the same server as the primary swapchain. The primary swapchain is exists at this point. + */ + This->pbufferContext = CreateContext(This, targetimpl, + ((IWineD3DSwapChainImpl *) This->swapchains[0])->context[0]->win_handle, + TRUE /* pbuffer */, &((IWineD3DSwapChainImpl *)This->swapchains[0])->presentParms); + This->pbufferWidth = targetimpl->currentDesc.Width; + This->pbufferHeight = targetimpl->currentDesc.Height; + } + + if(This->pbufferContext) { + if(This->pbufferContext->tid != 0 && This->pbufferContext->tid != tid) { + FIXME("The PBuffr context is only supported for one thread for now!\n"); + } + This->pbufferContext->tid = tid; + context = This->pbufferContext; + break; + } else { + ERR("Failed to create a buffer context and drawable, falling back to back buffer offscreen rendering\n"); + wined3d_settings.offscreen_rendering_mode = ORM_BACKBUFFER; + } } - if (This->pbufferContext) - { - if (This->pbufferContext->tid && This->pbufferContext->tid != tid) - { - FIXME("The PBuffer context is only supported for one thread for now!\n"); + case ORM_BACKBUFFER: + /* Stay with the currently active context for back buffer rendering */ + if(This->activeContext && tid == This->lastThread) { + context = This->activeContext; + } else { + /* This may happen if the app jumps straight into offscreen rendering + * Start using the context of the primary swapchain. tid == 0 is no problem + * for findThreadContextForSwapChain. + * + * Can also happen on thread switches - in that case findThreadContextForSwapChain + * is perfect to call. + */ + context = findThreadContextForSwapChain(This->swapchains[0], tid); } - This->pbufferContext->tid = tid; - context = This->pbufferContext; - } - else - { - ERR("Failed to create a buffer context and drawable, falling back to back buffer offscreen rendering.\n"); - wined3d_settings.offscreen_rendering_mode = ORM_BACKBUFFER; - goto retry; - } - } - else - { - /* Stay with the currently active context. */ - if (current_context - && ((IWineD3DSurfaceImpl *)current_context->surface)->resource.wineD3DDevice == This) - { - context = current_context; - } - else - { - /* This may happen if the app jumps straight into offscreen rendering - * Start using the context of the primary swapchain. tid == 0 is no problem - * for findThreadContextForSwapChain. - * - * Can also happen on thread switches - in that case findThreadContextForSwapChain - * is perfect to call. */ - context = findThreadContextForSwapChain(This->swapchains[0], tid); - } + break; } - } - - if (This->render_offscreen != oldRenderOffscreen) - { - Context_MarkStateDirty(context, WINED3DTS_PROJECTION, StateTable); - Context_MarkStateDirty(context, STATE_VDECL, StateTable); - Context_MarkStateDirty(context, STATE_VIEWPORT, StateTable); - Context_MarkStateDirty(context, STATE_SCISSORRECT, StateTable); - Context_MarkStateDirty(context, STATE_FRONTFACE, StateTable); - } - /* To compensate the lack of format switching with some offscreen rendering methods and on onscreen buffers - * the alpha blend state changes with different render target formats. */ - old = ((IWineD3DSurfaceImpl *)context->current_rt)->resource.format_desc; - new = ((IWineD3DSurfaceImpl *)target)->resource.format_desc; - if (old->format != new->format) - { - /* Disable blending when the alpha mask has changed and when a format doesn't support blending. */ - if ((old->alpha_mask && !new->alpha_mask) || (!old->alpha_mask && new->alpha_mask) - || !(new->Flags & WINED3DFMT_FLAG_POSTPIXELSHADER_BLENDING)) - { - Context_MarkStateDirty(context, STATE_RENDER(WINED3DRS_ALPHABLENDENABLE), StateTable); + if(!oldRenderOffscreen) { + Context_MarkStateDirty(context, WINED3DTS_PROJECTION, StateTable); + Context_MarkStateDirty(context, STATE_VDECL, StateTable); + Context_MarkStateDirty(context, STATE_VIEWPORT, StateTable); + Context_MarkStateDirty(context, STATE_SCISSORRECT, StateTable); + Context_MarkStateDirty(context, STATE_FRONTFACE, StateTable); } } @@ -1871,8 +1552,7 @@ retry: * After that, the outer ActivateContext(which calls PreLoad) can activate the new * target for the new thread */ - if (readTexture && context->current_rt != target) - { + if (readTexture && This->lastActiveRenderTarget != target) { BOOL oldInDraw = This->isInDraw; /* PreLoad requires a context to load the texture, thus it will call ActivateContext. @@ -1884,39 +1564,30 @@ retry: /* Do that before switching the context: * Read the back buffer of the old drawable into the destination texture */ - if (((IWineD3DSurfaceImpl *)context->current_rt)->texture_name_srgb) - { - surface_internal_preload(context->current_rt, SRGB_BOTH); + if(((IWineD3DSurfaceImpl *)This->lastActiveRenderTarget)->glDescription.srgbTextureName) { + surface_internal_preload(This->lastActiveRenderTarget, SRGB_BOTH); } else { - surface_internal_preload(context->current_rt, SRGB_RGB); + surface_internal_preload(This->lastActiveRenderTarget, SRGB_RGB); } /* Assume that the drawable will be modified by some other things now */ - IWineD3DSurface_ModifyLocation(context->current_rt, SFLAG_INDRAWABLE, FALSE); + IWineD3DSurface_ModifyLocation(This->lastActiveRenderTarget, SFLAG_INDRAWABLE, FALSE); This->isInDraw = oldInDraw; } - context->draw_buffer_dirty = TRUE; - context->current_rt = target; - return context; } -/* Context activation is done by the caller. */ -static void context_apply_draw_buffer(struct WineD3DContext *context, BOOL blit) +static void apply_draw_buffer(IWineD3DDeviceImpl *This, IWineD3DSurface *target, BOOL blit) { - const struct wined3d_gl_info *gl_info = context->gl_info; - IWineD3DSurface *rt = context->current_rt; IWineD3DSwapChain *swapchain; - IWineD3DDeviceImpl *device; - device = ((IWineD3DSurfaceImpl *)rt)->resource.wineD3DDevice; - if (SUCCEEDED(IWineD3DSurface_GetContainer(rt, &IID_IWineD3DSwapChain, (void **)&swapchain))) + if (SUCCEEDED(IWineD3DSurface_GetContainer(target, &IID_IWineD3DSwapChain, (void **)&swapchain))) { IWineD3DSwapChain_Release((IUnknown *)swapchain); ENTER_GL(); - glDrawBuffer(surface_get_gl_buffer(rt, swapchain)); + glDrawBuffer(surface_get_gl_buffer(target, swapchain)); checkGLcall("glDrawBuffers()"); LEAVE_GL(); } @@ -1929,12 +1600,12 @@ static void context_apply_draw_buffer(struct WineD3DContext *context, BOOL blit) { if (GL_SUPPORT(ARB_DRAW_BUFFERS)) { - GL_EXTCALL(glDrawBuffersARB(GL_LIMITS(buffers), device->draw_buffers)); + GL_EXTCALL(glDrawBuffersARB(GL_LIMITS(buffers), This->draw_buffers)); checkGLcall("glDrawBuffers()"); } else { - glDrawBuffer(device->draw_buffers[0]); + glDrawBuffer(This->draw_buffers[0]); checkGLcall("glDrawBuffer()"); } } else { @@ -1944,7 +1615,7 @@ static void context_apply_draw_buffer(struct WineD3DContext *context, BOOL blit) } else { - glDrawBuffer(device->offscreenBuffer); + glDrawBuffer(This->offscreenBuffer); checkGLcall("glDrawBuffer()"); } LEAVE_GL(); @@ -1964,40 +1635,54 @@ static void context_apply_draw_buffer(struct WineD3DContext *context, BOOL blit) * usage: Prepares the context for blitting, drawing or other actions * *****************************************************************************/ -struct WineD3DContext *ActivateContext(IWineD3DDeviceImpl *This, IWineD3DSurface *target, enum ContextUsage usage) -{ - struct WineD3DContext *current_context = context_get_current(); +void ActivateContext(IWineD3DDeviceImpl *This, IWineD3DSurface *target, ContextUsage usage) { DWORD tid = GetCurrentThreadId(); DWORD i, dirtyState, idx; BYTE shift; WineD3DContext *context; const struct StateEntry *StateTable = This->StateTable; - const struct wined3d_gl_info *gl_info; TRACE("(%p): Selecting context for render target %p, thread %d\n", This, target, tid); - - context = FindContext(This, target, tid); - - gl_info = context->gl_info; + if(This->lastActiveRenderTarget != target || tid != This->lastThread) { + context = FindContext(This, target, tid); + context->draw_buffer_dirty = TRUE; + This->lastActiveRenderTarget = target; + This->lastThread = tid; + } else { + /* Stick to the old context */ + context = This->activeContext; + } /* Activate the opengl context */ - if (context != current_context) - { - if (!context_set_current(context)) ERR("Failed to activate the new context.\n"); - else This->frag_pipe->enable_extension((IWineD3DDevice *)This, !context->last_was_blit); + if(last_device != This || context != This->activeContext) { + BOOL ret; - if (context->vshader_const_dirty) - { - memset(context->vshader_const_dirty, 1, - sizeof(*context->vshader_const_dirty) * GL_LIMITS(vshader_constantsF)); - This->highest_dirty_vs_const = GL_LIMITS(vshader_constantsF); + /* Prevent an unneeded context switch as those are expensive */ + if(context->glCtx && (context->glCtx == pwglGetCurrentContext())) { + TRACE("Already using gl context %p\n", context->glCtx); } - if (context->pshader_const_dirty) - { - memset(context->pshader_const_dirty, 1, - sizeof(*context->pshader_const_dirty) * GL_LIMITS(pshader_constantsF)); - This->highest_dirty_ps_const = GL_LIMITS(pshader_constantsF); + else { + TRACE("Switching gl ctx to %p, hdc=%p ctx=%p\n", context, context->hdc, context->glCtx); + + ret = pwglMakeCurrent(context->hdc, context->glCtx); + if(ret == FALSE) { + ERR("Failed to activate the new context\n"); + } else if(!context->last_was_blit) { + This->frag_pipe->enable_extension((IWineD3DDevice *) This, TRUE); + } else { + This->frag_pipe->enable_extension((IWineD3DDevice *) This, FALSE); + } } + if(This->activeContext->vshader_const_dirty) { + memset(This->activeContext->vshader_const_dirty, 1, + sizeof(*This->activeContext->vshader_const_dirty) * GL_LIMITS(vshader_constantsF)); + } + if(This->activeContext->pshader_const_dirty) { + memset(This->activeContext->pshader_const_dirty, 1, + sizeof(*This->activeContext->pshader_const_dirty) * GL_LIMITS(pshader_constantsF)); + } + This->activeContext = context; + last_device = This; } switch (usage) { @@ -2005,11 +1690,11 @@ struct WineD3DContext *ActivateContext(IWineD3DDeviceImpl *This, IWineD3DSurface case CTXUSAGE_DRAWPRIM: if (wined3d_settings.offscreen_rendering_mode == ORM_FBO) { ENTER_GL(); - context_apply_fbo_state(context); + context_apply_fbo_state((IWineD3DDevice *)This); LEAVE_GL(); } if (context->draw_buffer_dirty) { - context_apply_draw_buffer(context, FALSE); + apply_draw_buffer(This, target, FALSE); context->draw_buffer_dirty = FALSE; } break; @@ -2019,19 +1704,20 @@ struct WineD3DContext *ActivateContext(IWineD3DDeviceImpl *This, IWineD3DSurface if (This->render_offscreen) { FIXME("Activating for CTXUSAGE_BLIT for an offscreen target with ORM_FBO. This should be avoided.\n"); ENTER_GL(); - context_bind_fbo(context, GL_FRAMEBUFFER_EXT, &context->dst_fbo); - context_attach_surface_fbo(context, GL_FRAMEBUFFER_EXT, 0, target); - context_attach_depth_stencil_fbo(context, GL_FRAMEBUFFER_EXT, NULL, FALSE); + context_bind_fbo((IWineD3DDevice *)This, GL_FRAMEBUFFER_EXT, &context->dst_fbo); + context_attach_surface_fbo(This, GL_FRAMEBUFFER_EXT, 0, target); + context_attach_depth_stencil_fbo(This, GL_FRAMEBUFFER_EXT, NULL, FALSE); LEAVE_GL(); } else { ENTER_GL(); - context_bind_fbo(context, GL_FRAMEBUFFER_EXT, NULL); + GL_EXTCALL(glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0)); + checkGLcall("glFramebufferRenderbufferEXT"); LEAVE_GL(); } context->draw_buffer_dirty = TRUE; } if (context->draw_buffer_dirty) { - context_apply_draw_buffer(context, TRUE); + apply_draw_buffer(This, target, TRUE); if (wined3d_settings.offscreen_rendering_mode != ORM_FBO) { context->draw_buffer_dirty = FALSE; } @@ -2099,6 +1785,8 @@ struct WineD3DContext *ActivateContext(IWineD3DDeviceImpl *This, IWineD3DSurface default: FIXME("Unexpected context usage requested\n"); } +} - return context; +WineD3DContext *getActiveContext(void) { + return last_device->activeContext; } diff --git a/dlls/wined3d/cubetexture.c b/dlls/wined3d/cubetexture.c index afba1e84ea3..dec15abc5ad 100644 --- a/dlls/wined3d/cubetexture.c +++ b/dlls/wined3d/cubetexture.c @@ -66,7 +66,7 @@ static void cubetexture_internal_preload(IWineD3DBaseTexture *iface, enum WINED3 { /* No danger of recursive calls, ActivateContext sets isInDraw to true * when loading offscreen render targets into their texture. */ - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); } if (This->resource.format_desc->format == WINED3DFMT_P8 @@ -140,7 +140,7 @@ static void cubetexture_cleanup(IWineD3DCubeTextureImpl *This, D3DCB_DESTROYSURF HRESULT cubetexture_init(IWineD3DCubeTextureImpl *texture, UINT edge_length, UINT levels, IWineD3DDeviceImpl *device, DWORD usage, WINED3DFORMAT format, WINED3DPOOL pool, IUnknown *parent) { - const struct wined3d_gl_info *gl_info = &device->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &device->adapter->gl_info; const struct GlPixelFormatDesc *format_desc = getFormatDescEntry(format, gl_info); UINT pow2_edge_length; unsigned int i, j; @@ -210,10 +210,10 @@ HRESULT cubetexture_init(IWineD3DCubeTextureImpl *texture, UINT edge_length, UIN if (GL_SUPPORT(ARB_TEXTURE_NON_POWER_OF_TWO) || (edge_length == pow2_edge_length)) { /* Precalculated scaling for 'faked' non power of two texture coords. */ - texture->baseTexture.pow2Matrix[0] = 1.0f; - texture->baseTexture.pow2Matrix[5] = 1.0f; - texture->baseTexture.pow2Matrix[10] = 1.0f; - texture->baseTexture.pow2Matrix[15] = 1.0f; + texture->baseTexture.pow2Matrix[0] = 1.0; + texture->baseTexture.pow2Matrix[5] = 1.0; + texture->baseTexture.pow2Matrix[10] = 1.0; + texture->baseTexture.pow2Matrix[15] = 1.0; } else { @@ -221,7 +221,7 @@ HRESULT cubetexture_init(IWineD3DCubeTextureImpl *texture, UINT edge_length, UIN texture->baseTexture.pow2Matrix[0] = ((float)edge_length) / ((float)pow2_edge_length); texture->baseTexture.pow2Matrix[5] = ((float)edge_length) / ((float)pow2_edge_length); texture->baseTexture.pow2Matrix[10] = ((float)edge_length) / ((float)pow2_edge_length); - texture->baseTexture.pow2Matrix[15] = 1.0f; + texture->baseTexture.pow2Matrix[15] = 1.0; texture->baseTexture.pow2Matrix_identity = FALSE; } @@ -401,7 +401,6 @@ static BOOL WINAPI IWineD3DCubeTextureImpl_GetDirty(IWineD3DCubeTexture *iface) return basetexture_get_dirty((IWineD3DBaseTexture *)iface); } -/* Context activation is done by the caller. */ static HRESULT WINAPI IWineD3DCubeTextureImpl_BindTexture(IWineD3DCubeTexture *iface, BOOL srgb) { IWineD3DCubeTextureImpl *This = (IWineD3DCubeTextureImpl *)iface; BOOL set_gl_texture_desc; diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index e62934c5056..04a453ee6d0 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -38,29 +38,23 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3d); /* Define the default light parameters as specified by MSDN */ const WINED3DLIGHT WINED3D_default_light = { - WINED3DLIGHT_DIRECTIONAL, /* Type */ - { 1.0f, 1.0f, 1.0f, 0.0f }, /* Diffuse r,g,b,a */ - { 0.0f, 0.0f, 0.0f, 0.0f }, /* Specular r,g,b,a */ - { 0.0f, 0.0f, 0.0f, 0.0f }, /* Ambient r,g,b,a, */ - { 0.0f, 0.0f, 0.0f }, /* Position x,y,z */ - { 0.0f, 0.0f, 1.0f }, /* Direction x,y,z */ - 0.0f, /* Range */ - 0.0f, /* Falloff */ - 0.0f, 0.0f, 0.0f, /* Attenuation 0,1,2 */ - 0.0f, /* Theta */ - 0.0f /* Phi */ + WINED3DLIGHT_DIRECTIONAL, /* Type */ + { 1.0, 1.0, 1.0, 0.0 }, /* Diffuse r,g,b,a */ + { 0.0, 0.0, 0.0, 0.0 }, /* Specular r,g,b,a */ + { 0.0, 0.0, 0.0, 0.0 }, /* Ambient r,g,b,a, */ + { 0.0, 0.0, 0.0 }, /* Position x,y,z */ + { 0.0, 0.0, 1.0 }, /* Direction x,y,z */ + 0.0, /* Range */ + 0.0, /* Falloff */ + 0.0, 0.0, 0.0, /* Attenuation 0,1,2 */ + 0.0, /* Theta */ + 0.0 /* Phi */ }; /********************************************************** * Global variable / Constants follow **********************************************************/ -const float identity[] = -{ - 1.0f, 0.0f, 0.0f, 0.0f, - 0.0f, 1.0f, 0.0f, 0.0f, - 0.0f, 0.0f, 1.0f, 0.0f, - 0.0f, 0.0f, 0.0f, 1.0f, -}; /* When needed for comparisons */ +const float identity[16] = {1,0,0,0, 0,1,0,0, 0,0,1,0, 0,0,0,1}; /* When needed for comparisons */ /* Note that except for WINED3DPT_POINTLIST and WINED3DPT_LINELIST these * actually have the same values in GL and D3D. */ @@ -172,7 +166,6 @@ static BOOL fixed_get_input(BYTE usage, BYTE usage_idx, unsigned int *regnum) return TRUE; } -/* Context activation is done by the caller. */ void device_stream_info_from_declaration(IWineD3DDeviceImpl *This, BOOL use_vshader, struct wined3d_stream_info *stream_info, BOOL *fixup) { @@ -1191,13 +1184,32 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateQuery(IWineD3DDevice *iface, WINE /* allocated the 'extended' data based on the type of query requested */ switch(Type){ case WINED3DQUERYTYPE_OCCLUSION: - object->extendedData = HeapAlloc(GetProcessHeap(), 0, sizeof(struct wined3d_occlusion_query)); - ((struct wined3d_occlusion_query *)object->extendedData)->context = NULL; - break; + object->extendedData = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(WineQueryOcclusionData)); + ((WineQueryOcclusionData *)(object->extendedData))->ctx = This->activeContext; + + if(GL_SUPPORT(ARB_OCCLUSION_QUERY)) { + TRACE("(%p) Allocating data for an occlusion query\n", This); + ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); + ENTER_GL(); + GL_EXTCALL(glGenQueriesARB(1, &((WineQueryOcclusionData *)(object->extendedData))->queryId)); + LEAVE_GL(); + break; + } case WINED3DQUERYTYPE_EVENT: - object->extendedData = HeapAlloc(GetProcessHeap(), 0, sizeof(struct wined3d_event_query)); - ((struct wined3d_event_query *)object->extendedData)->context = NULL; + object->extendedData = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(WineQueryEventData)); + ((WineQueryEventData *)(object->extendedData))->ctx = This->activeContext; + + ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); + ENTER_GL(); + if(GL_SUPPORT(APPLE_FENCE)) { + GL_EXTCALL(glGenFencesAPPLE(1, &((WineQueryEventData *)(object->extendedData))->fenceId)); + checkGLcall("glGenFencesAPPLE"); + } else if(GL_SUPPORT(NV_FENCE)) { + GL_EXTCALL(glGenFencesNV(1, &((WineQueryEventData *)(object->extendedData))->fenceId)); + checkGLcall("glGenFencesNV"); + } + LEAVE_GL(); break; case WINED3DQUERYTYPE_VCACHE: @@ -2011,7 +2023,6 @@ static void IWineD3DDeviceImpl_LoadLogo(IWineD3DDeviceImpl *This, const char *fi return; } -/* Context activation is done by the caller. */ static void create_dummy_textures(IWineD3DDeviceImpl *This) { unsigned int i; /* Under DirectX you can have texture stage operations even if no texture is @@ -2118,7 +2129,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_Init3D(IWineD3DDevice *iface, } } - /* Setup the implicit swapchain. This also initializes a context. */ + /* Setup the implicit swapchain */ TRACE("Creating implicit swapchain\n"); hr = IWineD3DDeviceParent_CreateSwapChain(This->device_parent, pPresentationParameters, (IWineD3DSwapChain **)&swapchain); @@ -2139,12 +2150,16 @@ static HRESULT WINAPI IWineD3DDeviceImpl_Init3D(IWineD3DDevice *iface, if(swapchain->backBuffer && swapchain->backBuffer[0]) { TRACE("Setting rendertarget to %p\n", swapchain->backBuffer); This->render_targets[0] = swapchain->backBuffer[0]; + This->lastActiveRenderTarget = swapchain->backBuffer[0]; } else { TRACE("Setting rendertarget to %p\n", swapchain->frontBuffer); This->render_targets[0] = swapchain->frontBuffer; + This->lastActiveRenderTarget = swapchain->frontBuffer; } IWineD3DSurface_AddRef(This->render_targets[0]); + This->activeContext = swapchain->context[0]; + This->lastThread = GetCurrentThreadId(); /* Depth Stencil support */ This->stencilBufferTarget = This->auto_depth_stencil_buffer; @@ -2190,8 +2205,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_Init3D(IWineD3DDevice *iface, case ORM_BACKBUFFER: { - if (context_get_current()->aux_buffers > 0) - { + if(This->activeContext->aux_buffers > 0) { TRACE("Using auxilliary buffer for offscreen rendering\n"); This->offscreenBuffer = GL_AUX0; } else { @@ -2207,7 +2221,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_Init3D(IWineD3DDevice *iface, /* Clear the screen */ IWineD3DDevice_Clear((IWineD3DDevice *) This, 0, NULL, WINED3DCLEAR_TARGET | pPresentationParameters->EnableAutoDepthStencil ? WINED3DCLEAR_ZBUFFER | WINED3DCLEAR_STENCIL : 0, - 0x00, 1.0f, 0); + 0x00, 1.0, 0); This->d3d_initialized = TRUE; @@ -2296,7 +2310,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_Uninit3D(IWineD3DDevice *iface, D3DCB_D /* I don't think that the interface guarantees that the device is destroyed from the same thread * it was created. Thus make sure a context is active for the glDelete* calls */ - ActivateContext(This, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); if(This->logo_surface) IWineD3DSurface_Release(This->logo_surface); @@ -2782,8 +2796,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_SetLight(IWineD3DDevice *iface, DWORD I /* Incorrect attenuation values can cause the gl driver to crash. Happens with Need for speed * most wanted */ - if (pLight->Attenuation0 < 0.0f || pLight->Attenuation1 < 0.0f || pLight->Attenuation2 < 0.0f) - { + if(pLight->Attenuation0 < 0.0 || pLight->Attenuation1 < 0.0 || pLight->Attenuation2 < 0.0) { WARN("Attenuation is negative, returning WINED3DERR_INVALIDCALL\n"); return WINED3DERR_INVALIDCALL; } @@ -2845,7 +2858,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_SetLight(IWineD3DDevice *iface, DWORD I object->lightPosn[0] = -pLight->Direction.x; object->lightPosn[1] = -pLight->Direction.y; object->lightPosn[2] = -pLight->Direction.z; - object->lightPosn[3] = 0.0f; + object->lightPosn[3] = 0.0; object->exponent = 0.0f; object->cutoff = 180.0f; break; @@ -2855,13 +2868,13 @@ static HRESULT WINAPI IWineD3DDeviceImpl_SetLight(IWineD3DDevice *iface, DWORD I object->lightPosn[0] = pLight->Position.x; object->lightPosn[1] = pLight->Position.y; object->lightPosn[2] = pLight->Position.z; - object->lightPosn[3] = 1.0f; + object->lightPosn[3] = 1.0; /* Direction */ object->lightDirn[0] = pLight->Direction.x; object->lightDirn[1] = pLight->Direction.y; object->lightDirn[2] = pLight->Direction.z; - object->lightDirn[3] = 1.0f; + object->lightDirn[3] = 1.0; /* * opengl-ish and d3d-ish spot lights use too different models for the @@ -2876,15 +2889,14 @@ static HRESULT WINAPI IWineD3DDeviceImpl_SetLight(IWineD3DDevice *iface, DWORD I * will always be 1.0 for both of them, and we don't have to care for the * rest of the rather complex calculation */ - object->exponent = 0.0f; + object->exponent = 0; } else { rho = pLight->Theta + (pLight->Phi - pLight->Theta)/(2*pLight->Falloff); - if (rho < 0.0001f) rho = 0.0001f; - object->exponent = -0.3f/logf(cosf(rho/2)); + if (rho < 0.0001) rho = 0.0001f; + object->exponent = -0.3/log(cos(rho/2)); } - if (object->exponent > 128.0f) - { - object->exponent = 128.0f; + if (object->exponent > 128.0) { + object->exponent = 128.0; } object->cutoff = pLight->Phi*90/M_PI; @@ -4022,7 +4034,6 @@ static HRESULT WINAPI IWineD3DDeviceImpl_GetPixelShaderConstantF( return WINED3D_OK; } -/* Context activation is done by the caller. */ #define copy_and_next(dest, src, size) memcpy(dest, src, size); dest += (size) static HRESULT process_vertices_strided(IWineD3DDeviceImpl *This, DWORD dwDestIndex, DWORD dwCount, const struct wined3d_stream_info *stream_info, struct wined3d_buffer *dest, DWORD dwFlags, @@ -4150,10 +4161,10 @@ static HRESULT process_vertices_strided(IWineD3DDeviceImpl *This, DWORD dwDestIn TRACE("In: ( %06.2f %06.2f %06.2f )\n", p[0], p[1], p[2]); /* Multiplication with world, view and projection matrix */ - x = (p[0] * mat.u.s._11) + (p[1] * mat.u.s._21) + (p[2] * mat.u.s._31) + (1.0f * mat.u.s._41); - y = (p[0] * mat.u.s._12) + (p[1] * mat.u.s._22) + (p[2] * mat.u.s._32) + (1.0f * mat.u.s._42); - z = (p[0] * mat.u.s._13) + (p[1] * mat.u.s._23) + (p[2] * mat.u.s._33) + (1.0f * mat.u.s._43); - rhw = (p[0] * mat.u.s._14) + (p[1] * mat.u.s._24) + (p[2] * mat.u.s._34) + (1.0f * mat.u.s._44); + x = (p[0] * mat.u.s._11) + (p[1] * mat.u.s._21) + (p[2] * mat.u.s._31) + (1.0 * mat.u.s._41); + y = (p[0] * mat.u.s._12) + (p[1] * mat.u.s._22) + (p[2] * mat.u.s._32) + (1.0 * mat.u.s._42); + z = (p[0] * mat.u.s._13) + (p[1] * mat.u.s._23) + (p[2] * mat.u.s._33) + (1.0 * mat.u.s._43); + rhw = (p[0] * mat.u.s._14) + (p[1] * mat.u.s._24) + (p[2] * mat.u.s._34) + (1.0 * mat.u.s._44); TRACE("x=%f y=%f z=%f rhw=%f\n", x, y, z, rhw); @@ -4378,7 +4389,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_ProcessVertices(IWineD3DDevice *iface, } /* Need any context to write to the vbo. */ - ActivateContext(This, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); /* ProcessVertices reads from vertex buffers, which have to be assigned. DrawPrimitive and DrawPrimitiveUP * control the streamIsUP flag, thus restore it afterwards. @@ -4844,7 +4855,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_EndScene(IWineD3DDevice *iface) { return WINED3DERR_INVALIDCALL; } - ActivateContext(This, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); /* We only have to do this if we need to read the, swapbuffers performs a flush for us */ glFlush(); /* No checkGLcall here to avoid locking the lock just for checking a call that hardly ever @@ -4888,7 +4899,6 @@ HRESULT IWineD3DDeviceImpl_ClearSurface(IWineD3DDeviceImpl *This, IWineD3DSurfa UINT drawable_width, drawable_height; IWineD3DSurfaceImpl *depth_stencil = (IWineD3DSurfaceImpl *) This->stencilBufferTarget; IWineD3DSwapChainImpl *swapchain = NULL; - struct WineD3DContext *context; /* When we're clearing parts of the drawable, make sure that the target surface is well up to date in the * drawable. After the clear we'll mark the drawable up to date, so we have to make sure that this is true @@ -4924,10 +4934,9 @@ HRESULT IWineD3DDeviceImpl_ClearSurface(IWineD3DDeviceImpl *This, IWineD3DSurfa } } - context = ActivateContext(This, (IWineD3DSurface *)target, CTXUSAGE_CLEAR); - - target->get_drawable_size(context, &drawable_width, &drawable_height); + target->get_drawable_size(target, &drawable_width, &drawable_height); + ActivateContext(This, (IWineD3DSurface *) target, CTXUSAGE_CLEAR); ENTER_GL(); /* Only set the values up once, as they are not changing */ @@ -4948,19 +4957,19 @@ HRESULT IWineD3DDeviceImpl_ClearSurface(IWineD3DDeviceImpl *This, IWineD3DSurfa if (vp->X != 0 || vp->Y != 0 || vp->Width < depth_stencil->currentDesc.Width || vp->Height < depth_stencil->currentDesc.Height) { - surface_load_ds_location(This->stencilBufferTarget, context, location); + surface_load_ds_location(This->stencilBufferTarget, location); } else if (This->stateBlock->renderState[WINED3DRS_SCISSORTESTENABLE] && ( This->stateBlock->scissorRect.left > 0 || This->stateBlock->scissorRect.top > 0 || This->stateBlock->scissorRect.right < depth_stencil->currentDesc.Width || This->stateBlock->scissorRect.bottom < depth_stencil->currentDesc.Height)) { - surface_load_ds_location(This->stencilBufferTarget, context, location); + surface_load_ds_location(This->stencilBufferTarget, location); } else if (Count > 0 && pRects && ( pRects[0].x1 > 0 || pRects[0].y1 > 0 || pRects[0].x2 < depth_stencil->currentDesc.Width || pRects[0].y2 < depth_stencil->currentDesc.Height)) { - surface_load_ds_location(This->stencilBufferTarget, context, location); + surface_load_ds_location(This->stencilBufferTarget, location); } } @@ -5045,7 +5054,7 @@ HRESULT IWineD3DDeviceImpl_ClearSurface(IWineD3DDeviceImpl *This, IWineD3DSurfa /* Dirtify the target surface for now. If the surface is locked regularly, and an up to date sysmem copy exists, * it is most likely more efficient to perform a clear on the sysmem copy too instead of downloading it */ - IWineD3DSurface_ModifyLocation((IWineD3DSurface *)target, SFLAG_INDRAWABLE, TRUE); + IWineD3DSurface_ModifyLocation(This->lastActiveRenderTarget, SFLAG_INDRAWABLE, TRUE); } if (Flags & WINED3DCLEAR_ZBUFFER) { /* Note that WINED3DCLEAR_ZBUFFER implies a depth stencil exists on the device */ @@ -5718,7 +5727,6 @@ static HRESULT WINAPI IWineD3DDeviceImpl_UpdateSurface(IWineD3DDevice *iface, * NOTE: move code to surface to accomplish this ****************************************/ IWineD3DSurfaceImpl *pSrcSurface = (IWineD3DSurfaceImpl *)pSourceSurface; - IWineD3DSurfaceImpl *dst_impl = (IWineD3DSurfaceImpl *)pDestinationSurface; int srcWidth, srcHeight; unsigned int srcSurfaceWidth, srcSurfaceHeight, destSurfaceWidth, destSurfaceHeight; WINED3DFORMAT destFormat, srcFormat; @@ -5727,6 +5735,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_UpdateSurface(IWineD3DDevice *iface, WINED3DPOOL srcPool, destPool; int offset = 0; int rowoffset = 0; /* how many bytes to add onto the end of a row to wraparound to the beginning of the next */ + glDescriptor *glDescription = NULL; const struct GlPixelFormatDesc *src_format_desc, *dst_format_desc; GLenum dummy; int sampler; @@ -5759,7 +5768,8 @@ static HRESULT WINAPI IWineD3DDeviceImpl_UpdateSurface(IWineD3DDevice *iface, * destination's sysmem copy. If surface conversion is needed, use BltFast instead to * copy in sysmem and use regular surface loading. */ - d3dfmt_get_conv(dst_impl, FALSE, TRUE, &dummy, &dummy, &dummy, &convert, &bpp, FALSE); + d3dfmt_get_conv((IWineD3DSurfaceImpl *) pDestinationSurface, FALSE, TRUE, + &dummy, &dummy, &dummy, &convert, &bpp, FALSE); if(convert != NO_CONVERSION) { return IWineD3DSurface_BltFast(pDestinationSurface, pDestPoint ? pDestPoint->x : 0, @@ -5775,7 +5785,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_UpdateSurface(IWineD3DDevice *iface, IWineD3DSurface_GetDesc(pDestinationSurface, &winedesc); } - ActivateContext(This, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); GL_EXTCALL(glActiveTextureARB(GL_TEXTURE0_ARB)); @@ -5786,8 +5796,10 @@ static HRESULT WINAPI IWineD3DDeviceImpl_UpdateSurface(IWineD3DDevice *iface, surface_internal_preload(pDestinationSurface, SRGB_RGB); IWineD3DSurface_BindTexture(pDestinationSurface, FALSE); + IWineD3DSurface_GetGlDesc(pDestinationSurface, &glDescription); + src_format_desc = ((IWineD3DSurfaceImpl *)pSrcSurface)->resource.format_desc; - dst_format_desc = dst_impl->resource.format_desc; + dst_format_desc = ((IWineD3DSurfaceImpl *)pDestinationSurface)->resource.format_desc; /* this needs to be done in lines if the sourceRect != the sourceWidth */ srcWidth = pSourceRect ? pSourceRect->right - pSourceRect->left : srcSurfaceWidth; @@ -5810,7 +5822,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_UpdateSurface(IWineD3DDevice *iface, offset += pSourceRect->top * srcSurfaceWidth * src_format_desc->byte_count; } TRACE("(%p) glTexSubImage2D, level %d, left %d, top %d, width %d, height %d, fmt %#x, type %#x, memory %p+%#x\n", - This, dst_impl->texture_level, destLeft, destTop, srcWidth, srcHeight, dst_format_desc->glFormat, + This, glDescription->level, destLeft, destTop, srcWidth, srcHeight, dst_format_desc->glFormat, dst_format_desc->glType, IWineD3DSurface_GetData(pSourceSurface), offset); /* Sanity check */ @@ -5832,7 +5844,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_UpdateSurface(IWineD3DDevice *iface, for (j = destTop; j < (srcHeight + destTop); ++j) { - glTexSubImage2D(dst_impl->texture_target, dst_impl->texture_level, destLeft, j, + glTexSubImage2D(glDescription->target, glDescription->level, destLeft, j, srcWidth, 1, dst_format_desc->glFormat, dst_format_desc->glType,data); data += rowoffset; } @@ -5853,13 +5865,13 @@ static HRESULT WINAPI IWineD3DDeviceImpl_UpdateSurface(IWineD3DDevice *iface, } else { - GL_EXTCALL(glCompressedTexImage2DARB(dst_impl->texture_target, dst_impl->texture_level, + GL_EXTCALL(glCompressedTexImage2DARB(glDescription->target, glDescription->level, dst_format_desc->glInternal, srcWidth, srcHeight, 0, destSize, data)); } } else { - glTexSubImage2D(dst_impl->texture_target, dst_impl->texture_level, destLeft, destTop, + glTexSubImage2D(glDescription->target, glDescription->level, destLeft, destTop, srcWidth, srcHeight, dst_format_desc->glFormat, dst_format_desc->glType, data); } } @@ -6011,7 +6023,6 @@ static void color_fill_fbo(IWineD3DDevice *iface, IWineD3DSurface *surface, const WINED3DRECT *rect, const float color[4]) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *) iface; - struct WineD3DContext *context; IWineD3DSwapChain *swapchain; swapchain = get_swapchain(surface); @@ -6020,20 +6031,20 @@ static void color_fill_fbo(IWineD3DDevice *iface, IWineD3DSurface *surface, TRACE("Surface %p is onscreen\n", surface); - context = ActivateContext(This, surface, CTXUSAGE_RESOURCELOAD); + ActivateContext(This, surface, CTXUSAGE_RESOURCELOAD); ENTER_GL(); - context_bind_fbo(context, GL_FRAMEBUFFER_EXT, NULL); + GL_EXTCALL(glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0)); buffer = surface_get_gl_buffer(surface, swapchain); glDrawBuffer(buffer); checkGLcall("glDrawBuffer()"); } else { TRACE("Surface %p is offscreen\n", surface); - context = ActivateContext(This, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); - context_bind_fbo(context, GL_FRAMEBUFFER_EXT, &context->dst_fbo); - context_attach_surface_fbo(context, GL_FRAMEBUFFER_EXT, 0, surface); - context_attach_depth_stencil_fbo(context, GL_FRAMEBUFFER_EXT, NULL, FALSE); + context_bind_fbo(iface, GL_FRAMEBUFFER_EXT, &This->activeContext->dst_fbo); + context_attach_surface_fbo(This, GL_FRAMEBUFFER_EXT, 0, surface); + context_attach_depth_stencil_fbo(This, GL_FRAMEBUFFER_EXT, NULL, FALSE); } if (rect) { @@ -6061,6 +6072,13 @@ static void color_fill_fbo(IWineD3DDevice *iface, IWineD3DSurface *surface, glClear(GL_COLOR_BUFFER_BIT); checkGLcall("glClear"); + if (This->activeContext->current_fbo) { + context_bind_fbo(iface, GL_FRAMEBUFFER_EXT, &This->activeContext->current_fbo->id); + } else { + GL_EXTCALL(glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0)); + checkGLcall("glBindFramebuffer()"); + } + if (swapchain && surface == ((IWineD3DSwapChainImpl *)swapchain)->frontBuffer && ((IWineD3DSwapChainImpl *)swapchain)->backBuffer) { glDrawBuffer(GL_BACK); @@ -6236,10 +6254,10 @@ static void WINAPI IWineD3DDeviceImpl_ClearRendertargetView(IWineD3DDevice *ifac WARN("Converting to WINED3DCOLOR, this might give incorrect results\n"); - c = ((DWORD)(color[2] * 255.0f)); - c |= ((DWORD)(color[1] * 255.0f)) << 8; - c |= ((DWORD)(color[0] * 255.0f)) << 16; - c |= ((DWORD)(color[3] * 255.0f)) << 24; + c = ((DWORD)(color[2] * 255.0)); + c |= ((DWORD)(color[1] * 255.0)) << 8; + c |= ((DWORD)(color[0] * 255.0)) << 16; + c |= ((DWORD)(color[3] * 255.0)) << 24; /* Just forward this to the DirectDraw blitting engine */ memset(&BltFx, 0, sizeof(BltFx)); @@ -6330,8 +6348,6 @@ static HRESULT WINAPI IWineD3DDeviceImpl_SetFrontBackBuffers(IWineD3DDevice *ifa /* What to do about the context here in the case of multithreading? Not sure. * This function is called by IDirect3D7::CreateDevice so in theory its initialization code */ - WARN("No active context?\n"); - ENTER_GL(); if(!Swapchain->backBuffer[0]) { /* GL was told to draw to the front buffer at creation, @@ -6390,7 +6406,6 @@ void stretch_rect_fbo(IWineD3DDevice *iface, IWineD3DSurface *src_surface, WINED IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; GLbitfield mask = GL_COLOR_BUFFER_BIT; /* TODO: Support blitting depth/stencil surfaces */ IWineD3DSwapChain *src_swapchain, *dst_swapchain; - struct WineD3DContext *context; GLenum gl_filter; POINT offset = {0, 0}; @@ -6416,9 +6431,9 @@ void stretch_rect_fbo(IWineD3DDevice *iface, IWineD3DSurface *src_surface, WINED src_swapchain = get_swapchain(src_surface); dst_swapchain = get_swapchain(dst_surface); - if (src_swapchain) context = ActivateContext(This, src_surface, CTXUSAGE_RESOURCELOAD); - else if (dst_swapchain) context = ActivateContext(This, dst_surface, CTXUSAGE_RESOURCELOAD); - else context = ActivateContext(This, NULL, CTXUSAGE_RESOURCELOAD); + if (src_swapchain) ActivateContext(This, src_surface, CTXUSAGE_RESOURCELOAD); + else if (dst_swapchain) ActivateContext(This, dst_surface, CTXUSAGE_RESOURCELOAD); + else ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); if (src_swapchain) { GLenum buffer = surface_get_gl_buffer(src_surface, src_swapchain); @@ -6443,17 +6458,17 @@ void stretch_rect_fbo(IWineD3DDevice *iface, IWineD3DSurface *src_surface, WINED } ENTER_GL(); - context_bind_fbo(context, GL_READ_FRAMEBUFFER_EXT, NULL); + GL_EXTCALL(glBindFramebufferEXT(GL_READ_FRAMEBUFFER_EXT, 0)); glReadBuffer(buffer); checkGLcall("glReadBuffer()"); } else { TRACE("Source surface %p is offscreen\n", src_surface); ENTER_GL(); - context_bind_fbo(context, GL_READ_FRAMEBUFFER_EXT, &context->src_fbo); - context_attach_surface_fbo(context, GL_READ_FRAMEBUFFER_EXT, 0, src_surface); + context_bind_fbo(iface, GL_READ_FRAMEBUFFER_EXT, &This->activeContext->src_fbo); + context_attach_surface_fbo(This, GL_READ_FRAMEBUFFER_EXT, 0, src_surface); glReadBuffer(GL_COLOR_ATTACHMENT0_EXT); checkGLcall("glReadBuffer()"); - context_attach_depth_stencil_fbo(context, GL_READ_FRAMEBUFFER_EXT, NULL, FALSE); + context_attach_depth_stencil_fbo(This, GL_READ_FRAMEBUFFER_EXT, NULL, FALSE); } LEAVE_GL(); @@ -6482,18 +6497,18 @@ void stretch_rect_fbo(IWineD3DDevice *iface, IWineD3DSurface *src_surface, WINED } ENTER_GL(); - context_bind_fbo(context, GL_DRAW_FRAMEBUFFER_EXT, NULL); + GL_EXTCALL(glBindFramebufferEXT(GL_DRAW_FRAMEBUFFER_EXT, 0)); glDrawBuffer(buffer); checkGLcall("glDrawBuffer()"); } else { TRACE("Destination surface %p is offscreen\n", dst_surface); ENTER_GL(); - context_bind_fbo(context, GL_DRAW_FRAMEBUFFER_EXT, &context->dst_fbo); - context_attach_surface_fbo(context, GL_DRAW_FRAMEBUFFER_EXT, 0, dst_surface); + context_bind_fbo(iface, GL_DRAW_FRAMEBUFFER_EXT, &This->activeContext->dst_fbo); + context_attach_surface_fbo(This, GL_DRAW_FRAMEBUFFER_EXT, 0, dst_surface); glDrawBuffer(GL_COLOR_ATTACHMENT0_EXT); checkGLcall("glDrawBuffer()"); - context_attach_depth_stencil_fbo(context, GL_DRAW_FRAMEBUFFER_EXT, NULL, FALSE); + context_attach_depth_stencil_fbo(This, GL_DRAW_FRAMEBUFFER_EXT, NULL, FALSE); } glDisable(GL_SCISSOR_TEST); IWineD3DDeviceImpl_MarkStateDirty(This, STATE_RENDER(WINED3DRS_SCISSORTESTENABLE)); @@ -6510,6 +6525,13 @@ void stretch_rect_fbo(IWineD3DDevice *iface, IWineD3DSurface *src_surface, WINED IWineD3DSurface_ModifyLocation(dst_surface, SFLAG_INDRAWABLE, TRUE); + if (This->activeContext->current_fbo) { + context_bind_fbo(iface, GL_FRAMEBUFFER_EXT, &This->activeContext->current_fbo->id); + } else { + GL_EXTCALL(glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0)); + checkGLcall("glBindFramebuffer()"); + } + /* If we switched from GL_BACK to GL_FRONT above, we need to switch back here */ if (dst_swapchain && dst_surface == ((IWineD3DSwapChainImpl *)dst_swapchain)->frontBuffer && ((IWineD3DSwapChainImpl *)dst_swapchain)->backBuffer) { @@ -6593,8 +6615,8 @@ static HRESULT WINAPI IWineD3DDeviceImpl_SetDepthStencilSurface(IWineD3DDevice * || ((IWineD3DSurfaceImpl *)This->stencilBufferTarget)->Flags & SFLAG_DISCARD) { surface_modify_ds_location(This->stencilBufferTarget, SFLAG_DS_DISCARDED); } else { - struct WineD3DContext *context = ActivateContext(This, This->render_targets[0], CTXUSAGE_RESOURCELOAD); - surface_load_ds_location(This->stencilBufferTarget, context, SFLAG_DS_OFFSCREEN); + ActivateContext(This, This->render_targets[0], CTXUSAGE_RESOURCELOAD); + surface_load_ds_location(This->stencilBufferTarget, SFLAG_DS_OFFSCREEN); surface_modify_ds_location(This->stencilBufferTarget, SFLAG_DS_OFFSCREEN); } } @@ -6628,7 +6650,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_SetCursorProperties(IWineD3DDevice* i /* some basic validation checks */ if(This->cursorTexture) { - ActivateContext(This, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); glDeleteTextures(1, &This->cursorTexture); LEAVE_GL(); @@ -6686,9 +6708,6 @@ static HRESULT WINAPI IWineD3DDeviceImpl_SetCursorProperties(IWineD3DDevice* i for(i = 0; i < height; i++) memcpy(&mem[width * bpp * i], &bits[rect.Pitch * i], width * bpp); IWineD3DSurface_UnlockRect(pCursorBitmap); - - ActivateContext(This, NULL, CTXUSAGE_RESOURCELOAD); - ENTER_GL(); if(GL_SUPPORT(APPLE_CLIENT_STORAGE)) { @@ -6886,13 +6905,12 @@ static void updateSurfaceDesc(IWineD3DSurfaceImpl *surface, const WINED3DPRESENT surface->glRect.right = surface->pow2Width; surface->glRect.bottom = surface->pow2Height; - if (surface->texture_name) - { - ActivateContext(This, NULL, CTXUSAGE_RESOURCELOAD); + if(surface->glDescription.textureName) { + ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); - glDeleteTextures(1, &surface->texture_name); + glDeleteTextures(1, &surface->glDescription.textureName); LEAVE_GL(); - surface->texture_name = 0; + surface->glDescription.textureName = 0; surface->Flags &= ~SFLAG_CLIENT; } if(surface->pow2Width != pPresentationParameters->BackBufferWidth || @@ -6953,8 +6971,6 @@ void delete_opengl_contexts(IWineD3DDevice *iface, IWineD3DSwapChain *swapchain_ UINT i; IWineD3DBaseShaderImpl *shader; - ActivateContext(This, NULL, CTXUSAGE_RESOURCELOAD); - IWineD3DDevice_EnumResources(iface, reset_unload_resources, NULL); LIST_FOR_EACH_ENTRY(shader, &This->shaders, IWineD3DBaseShaderImpl, baseShader.shader_list_entry) { This->shader_backend->shader_destroy((IWineD3DBaseShader *) shader); @@ -6989,6 +7005,7 @@ void delete_opengl_contexts(IWineD3DDevice *iface, IWineD3DSwapChain *swapchain_ while(This->numContexts) { DestroyContext(This, This->contexts[0]); } + This->activeContext = NULL; HeapFree(GetProcessHeap(), 0, swapchain->context); swapchain->context = NULL; swapchain->num_contexts = 0; @@ -7010,6 +7027,7 @@ HRESULT create_primary_opengl_context(IWineD3DDevice *iface, IWineD3DSwapChain * swapchain->context[0] = CreateContext(This, target, swapchain->win_handle, FALSE, &swapchain->presentParms); swapchain->num_contexts = 1; + This->activeContext = swapchain->context[0]; create_dummy_textures(This); @@ -7307,8 +7325,39 @@ void device_resource_released(IWineD3DDeviceImpl *This, IWineD3DResource *resour case WINED3DRTYPE_SURFACE: { unsigned int i; - if (This->d3d_initialized) - { + /* Cleanup any FBO attachments if d3d is enabled */ + if(This->d3d_initialized) { + if((IWineD3DSurface *)resource == This->lastActiveRenderTarget) { + IWineD3DSwapChainImpl *swapchain = This->swapchains ? (IWineD3DSwapChainImpl *) This->swapchains[0] : NULL; + + TRACE("Last active render target destroyed\n"); + /* Find a replacement surface for the currently active back buffer. The context manager does not do NULL + * checks, so switch to a valid target as long as the currently set surface is still valid. Use the + * surface of the implicit swpchain. If that is the same as the destroyed surface the device is destroyed + * and the lastActiveRenderTarget member shouldn't matter + */ + if(swapchain) { + if(swapchain->backBuffer && swapchain->backBuffer[0] != (IWineD3DSurface *)resource) { + TRACE("Activating primary back buffer\n"); + ActivateContext(This, swapchain->backBuffer[0], CTXUSAGE_RESOURCELOAD); + } else if(!swapchain->backBuffer && swapchain->frontBuffer != (IWineD3DSurface *)resource) { + /* Single buffering environment */ + TRACE("Activating primary front buffer\n"); + ActivateContext(This, swapchain->frontBuffer, CTXUSAGE_RESOURCELOAD); + } else { + TRACE("Device is being destroyed, setting lastActiveRenderTarget = 0xdeadbabe\n"); + /* Implicit render target destroyed, that means the device is being destroyed + * whatever we set here, it shouldn't matter + */ + This->lastActiveRenderTarget = (IWineD3DSurface *) 0xdeadbabe; + } + } else { + /* May happen during ddraw uninitialization */ + TRACE("Render target set, but swapchain does not exist!\n"); + This->lastActiveRenderTarget = (IWineD3DSurface *) 0xdeadcafe; + } + } + for (i = 0; i < GL_LIMITS(buffers); ++i) { if (This->render_targets[i] == (IWineD3DSurface *)resource) { This->render_targets[i] = NULL; @@ -7696,29 +7745,28 @@ void IWineD3DDeviceImpl_MarkStateDirty(IWineD3DDeviceImpl *This, DWORD state) { } } -void get_drawable_size_pbuffer(struct WineD3DContext *context, UINT *width, UINT *height) -{ - IWineD3DDeviceImpl *device = ((IWineD3DSurfaceImpl *)context->current_rt)->resource.wineD3DDevice; - /* The drawable size of a pbuffer render target is the current pbuffer size. */ - *width = device->pbufferWidth; - *height = device->pbufferHeight; +void get_drawable_size_pbuffer(IWineD3DSurfaceImpl *This, UINT *width, UINT *height) { + IWineD3DDeviceImpl *dev = This->resource.wineD3DDevice; + /* The drawable size of a pbuffer render target is the current pbuffer size + */ + *width = dev->pbufferWidth; + *height = dev->pbufferHeight; } -void get_drawable_size_fbo(struct WineD3DContext *context, UINT *width, UINT *height) -{ - IWineD3DSurfaceImpl *surface = (IWineD3DSurfaceImpl *)context->current_rt; - /* The drawable size of a fbo target is the opengl texture size, which is the power of two size. */ - *width = surface->pow2Width; - *height = surface->pow2Height; +void get_drawable_size_fbo(IWineD3DSurfaceImpl *This, UINT *width, UINT *height) { + /* The drawable size of a fbo target is the opengl texture size, which is the power of two size + */ + *width = This->pow2Width; + *height = This->pow2Height; } -void get_drawable_size_backbuffer(struct WineD3DContext *context, UINT *width, UINT *height) -{ - IWineD3DSurfaceImpl *surface = (IWineD3DSurfaceImpl *)context->surface; +void get_drawable_size_backbuffer(IWineD3DSurfaceImpl *This, UINT *width, UINT *height) { + IWineD3DDeviceImpl *dev = This->resource.wineD3DDevice; /* The drawable size of a backbuffer / aux buffer offscreen target is the size of the * current context's drawable, which is the size of the back buffer of the swapchain * the active context belongs to. The back buffer of the swapchain is stored as the - * surface the context belongs to. */ - *width = surface->currentDesc.Width; - *height = surface->currentDesc.Height; + * surface the context belongs to. + */ + *width = ((IWineD3DSurfaceImpl *) dev->activeContext->surface)->currentDesc.Width; + *height = ((IWineD3DSurfaceImpl *) dev->activeContext->surface)->currentDesc.Height; } diff --git a/dlls/wined3d/directx.c b/dlls/wined3d/directx.c index e6fb1c73d5c..28f07efabff 100644 --- a/dlls/wined3d/directx.c +++ b/dlls/wined3d/directx.c @@ -22,7 +22,15 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +/* Compile time diagnostics: */ + +#ifndef DEBUG_SINGLE_MODE +/* Set to 1 to force only a single display mode to be exposed: */ +#define DEBUG_SINGLE_MODE 0 +#endif + #include "config.h" +#include #include "wined3d_private.h" WINE_DEFAULT_DEBUG_CHANNEL(d3d); @@ -197,104 +205,132 @@ glMultiTexCoordFunc multi_texcoord_funcs[WINED3D_FFP_EMIT_COUNT]; * function query some info from GL. */ -struct wined3d_fake_gl_ctx +static int wined3d_fake_gl_context_ref = 0; +static BOOL wined3d_fake_gl_context_foreign; +static BOOL wined3d_fake_gl_context_available = FALSE; +static HDC wined3d_fake_gl_context_hdc = NULL; +static HWND wined3d_fake_gl_context_hwnd = NULL; + +static CRITICAL_SECTION wined3d_fake_gl_context_cs; +static CRITICAL_SECTION_DEBUG wined3d_fake_gl_context_cs_debug = { - HDC dc; - HWND wnd; - HGLRC gl_ctx; + 0, 0, &wined3d_fake_gl_context_cs, + { &wined3d_fake_gl_context_cs_debug.ProcessLocksList, + &wined3d_fake_gl_context_cs_debug.ProcessLocksList }, + 0, 0, { (DWORD_PTR)(__FILE__ ": wined3d_fake_gl_context_cs") } }; +static CRITICAL_SECTION wined3d_fake_gl_context_cs = { &wined3d_fake_gl_context_cs_debug, -1, 0, 0, 0, 0 }; -static void WineD3D_ReleaseFakeGLContext(struct wined3d_fake_gl_ctx *ctx) -{ - TRACE_(d3d_caps)("Destroying fake GL context.\n"); +static void WineD3D_ReleaseFakeGLContext(void) { + HGLRC glCtx; - if (!pwglMakeCurrent(NULL, NULL)) - { - ERR_(d3d_caps)("Failed to disable fake GL context.\n"); + EnterCriticalSection(&wined3d_fake_gl_context_cs); + + if(!wined3d_fake_gl_context_available) { + TRACE_(d3d_caps)("context not available\n"); + LeaveCriticalSection(&wined3d_fake_gl_context_cs); + return; } - if (!pwglDeleteContext(ctx->gl_ctx)) - { - DWORD err = GetLastError(); - ERR("wglDeleteContext(%p) failed, last error %#x.\n", ctx->gl_ctx, err); + glCtx = pwglGetCurrentContext(); + + TRACE_(d3d_caps)("decrementing ref from %i\n", wined3d_fake_gl_context_ref); + if (0 == (--wined3d_fake_gl_context_ref) ) { + if(!wined3d_fake_gl_context_foreign && glCtx) { + TRACE_(d3d_caps)("destroying fake GL context\n"); + pwglMakeCurrent(NULL, NULL); + pwglDeleteContext(glCtx); + } + if(wined3d_fake_gl_context_hdc) + ReleaseDC(wined3d_fake_gl_context_hwnd, wined3d_fake_gl_context_hdc); + wined3d_fake_gl_context_hdc = NULL; /* Make sure we don't think that it is still around */ + if(wined3d_fake_gl_context_hwnd) + DestroyWindow(wined3d_fake_gl_context_hwnd); + wined3d_fake_gl_context_hwnd = NULL; + wined3d_fake_gl_context_available = FALSE; } + assert(wined3d_fake_gl_context_ref >= 0); - ReleaseDC(ctx->wnd, ctx->dc); - DestroyWindow(ctx->wnd); + LeaveCriticalSection(&wined3d_fake_gl_context_cs); } -static BOOL WineD3D_CreateFakeGLContext(struct wined3d_fake_gl_ctx *ctx) -{ - PIXELFORMATDESCRIPTOR pfd; - int iPixelFormat; +static BOOL WineD3D_CreateFakeGLContext(void) { + HGLRC glCtx = NULL; + + EnterCriticalSection(&wined3d_fake_gl_context_cs); TRACE("getting context...\n"); + if(wined3d_fake_gl_context_ref > 0) goto ret; + assert(0 == wined3d_fake_gl_context_ref); - /* We need a fake window as a hdc retrieved using GetDC(0) can't be used for much GL purposes. */ - ctx->wnd = CreateWindowA(WINED3D_OPENGL_WINDOW_CLASS_NAME, "WineD3D fake window", - WS_OVERLAPPEDWINDOW, 10, 10, 10, 10, NULL, NULL, NULL, NULL); - if (!ctx->wnd) - { - ERR_(d3d_caps)("Failed to create a window.\n"); - goto fail; - } + wined3d_fake_gl_context_foreign = TRUE; - ctx->dc = GetDC(ctx->wnd); - if (!ctx->dc) - { - ERR_(d3d_caps)("Failed to get a DC.\n"); - goto fail; - } + glCtx = pwglGetCurrentContext(); + if (!glCtx) { + PIXELFORMATDESCRIPTOR pfd; + int iPixelFormat; - /* PixelFormat selection */ - ZeroMemory(&pfd, sizeof(pfd)); - pfd.nSize = sizeof(pfd); - pfd.nVersion = 1; - pfd.dwFlags = PFD_SUPPORT_OPENGL | PFD_DOUBLEBUFFER | PFD_DRAW_TO_WINDOW; /* PFD_GENERIC_ACCELERATED */ - pfd.iPixelType = PFD_TYPE_RGBA; - pfd.cColorBits = 32; - pfd.iLayerType = PFD_MAIN_PLANE; - - iPixelFormat = ChoosePixelFormat(ctx->dc, &pfd); - if (!iPixelFormat) - { - /* If this happens something is very wrong as ChoosePixelFormat barely fails. */ - ERR_(d3d_caps)("Can't find a suitable iPixelFormat.\n"); - goto fail; - } - DescribePixelFormat(ctx->dc, iPixelFormat, sizeof(pfd), &pfd); - SetPixelFormat(ctx->dc, iPixelFormat, &pfd); + wined3d_fake_gl_context_foreign = FALSE; - /* Create a GL context. */ - ctx->gl_ctx = pwglCreateContext(ctx->dc); - if (!ctx->gl_ctx) - { - WARN_(d3d_caps)("Error creating default context for capabilities initialization.\n"); - goto fail; - } + /* We need a fake window as a hdc retrieved using GetDC(0) can't be used for much GL purposes */ + wined3d_fake_gl_context_hwnd = CreateWindowA(WINED3D_OPENGL_WINDOW_CLASS_NAME, "WineD3D fake window", WS_OVERLAPPEDWINDOW, 10, 10, 10, 10, NULL, NULL, NULL, NULL); + if(!wined3d_fake_gl_context_hwnd) { + ERR("HWND creation failed!\n"); + goto fail; + } + wined3d_fake_gl_context_hdc = GetDC(wined3d_fake_gl_context_hwnd); + if(!wined3d_fake_gl_context_hdc) { + ERR("GetDC failed!\n"); + goto fail; + } - /* Make it the current GL context. */ - if (!context_set_current(NULL)) - { - ERR_(d3d_caps)("Failed to clear current D3D context.\n"); - } + /* PixelFormat selection */ + ZeroMemory(&pfd, sizeof(pfd)); + pfd.nSize = sizeof(pfd); + pfd.nVersion = 1; + pfd.dwFlags = PFD_SUPPORT_OPENGL | PFD_DOUBLEBUFFER | PFD_DRAW_TO_WINDOW;/*PFD_GENERIC_ACCELERATED*/ + pfd.iPixelType = PFD_TYPE_RGBA; + pfd.cColorBits = 32; + pfd.iLayerType = PFD_MAIN_PLANE; + + iPixelFormat = ChoosePixelFormat(wined3d_fake_gl_context_hdc, &pfd); + if(!iPixelFormat) { + /* If this happens something is very wrong as ChoosePixelFormat barely fails */ + ERR("Can't find a suitable iPixelFormat\n"); + goto fail; + } + DescribePixelFormat(wined3d_fake_gl_context_hdc, iPixelFormat, sizeof(pfd), &pfd); + SetPixelFormat(wined3d_fake_gl_context_hdc, iPixelFormat, &pfd); + + /* Create a GL context */ + glCtx = pwglCreateContext(wined3d_fake_gl_context_hdc); + if (!glCtx) { + WARN_(d3d_caps)("Error creating default context for capabilities initialization\n"); + goto fail; + } - if (!pwglMakeCurrent(ctx->dc, ctx->gl_ctx)) - { - ERR_(d3d_caps)("Failed to make fake GL context current.\n"); - goto fail; + /* Make it the current GL context */ + if (!pwglMakeCurrent(wined3d_fake_gl_context_hdc, glCtx)) { + WARN_(d3d_caps)("Error setting default context as current for capabilities initialization\n"); + goto fail; + } } + ret: + TRACE("incrementing ref from %i\n", wined3d_fake_gl_context_ref); + wined3d_fake_gl_context_ref++; + wined3d_fake_gl_context_available = TRUE; + LeaveCriticalSection(&wined3d_fake_gl_context_cs); return TRUE; - -fail: - if (ctx->gl_ctx) pwglDeleteContext(ctx->gl_ctx); - ctx->gl_ctx = NULL; - if (ctx->dc) ReleaseDC(ctx->wnd, ctx->dc); - ctx->dc = NULL; - if (ctx->wnd) DestroyWindow(ctx->wnd); - ctx->wnd = NULL; - + fail: + if(wined3d_fake_gl_context_hdc) + ReleaseDC(wined3d_fake_gl_context_hwnd, wined3d_fake_gl_context_hdc); + wined3d_fake_gl_context_hdc = NULL; + if(wined3d_fake_gl_context_hwnd) + DestroyWindow(wined3d_fake_gl_context_hwnd); + wined3d_fake_gl_context_hwnd = NULL; + if(glCtx) pwglDeleteContext(glCtx); + LeaveCriticalSection(&wined3d_fake_gl_context_cs); return FALSE; } @@ -356,8 +392,7 @@ static ULONG WINAPI IWineD3DImpl_Release(IWineD3D *iface) { /* Set the shader type for this device, depending on the given capabilities, * the device type, and the user preferences in wined3d_settings */ -static void select_shader_mode(const struct wined3d_gl_info *gl_info, - WINED3DDEVTYPE DeviceType, int *ps_selected, int *vs_selected) +static void select_shader_mode(const WineD3D_GL_Info *gl_info, WINED3DDEVTYPE DeviceType, int *ps_selected, int *vs_selected) { if (wined3d_settings.vs_mode == VS_NONE) { *vs_selected = SHADER_NONE; @@ -389,8 +424,11 @@ static void select_shader_mode(const struct wined3d_gl_info *gl_info, } /** Select the number of report maximum shader constants based on the selected shader modes */ -static void select_shader_max_constants(int ps_selected_mode, int vs_selected_mode, struct wined3d_gl_info *gl_info) -{ +static void select_shader_max_constants( + int ps_selected_mode, + int vs_selected_mode, + WineD3D_GL_Info *gl_info) { + switch (vs_selected_mode) { case SHADER_GLSL: gl_info->max_vshader_constantsF = gl_info->vs_glsl_constantsF; @@ -421,7 +459,7 @@ static void select_shader_max_constants(int ps_selected_mode, int vs_selected_mo **********************************************************/ /* GL locking is done by the caller */ -static inline BOOL test_arb_vs_offset_limit(const struct wined3d_gl_info *gl_info) +static inline BOOL test_arb_vs_offset_limit(const WineD3D_GL_Info *gl_info) { GLuint prog; BOOL ret = FALSE; @@ -450,7 +488,7 @@ static inline BOOL test_arb_vs_offset_limit(const struct wined3d_gl_info *gl_inf GL_EXTCALL(glBindProgramARB(GL_VERTEX_PROGRAM_ARB, 0)); GL_EXTCALL(glDeleteProgramsARB(1, &prog)); - checkGLcall("ARB vp offset limit test cleanup"); + checkGLcall("ARB vp offset limit test cleanup\n"); return ret; } @@ -466,697 +504,202 @@ static DWORD ver_for_ext(GL_SupportedExt ext) return 0; } -static BOOL match_ati_r300_to_500(const struct wined3d_gl_info *gl_info, const char *gl_renderer) -{ - if (gl_info->gl_vendor != VENDOR_ATI) return FALSE; - if (gl_info->gl_card == CARD_ATI_RADEON_9500) return TRUE; - if (gl_info->gl_card == CARD_ATI_RADEON_X700) return TRUE; - if (gl_info->gl_card == CARD_ATI_RADEON_X1600) return TRUE; - return FALSE; -} +static BOOL IWineD3DImpl_FillGLCaps(WineD3D_GL_Info *gl_info) { + const char *GL_Extensions = NULL; + const char *WGL_Extensions = NULL; + const char *gl_string = NULL; + const char *gl_string_cursor = NULL; + GLint gl_max; + GLfloat gl_floatv[2]; + int major = 1, minor = 0; + BOOL return_value = TRUE; + unsigned i; + HDC hdc; + unsigned int vidmem=0; -static BOOL match_geforce5(const struct wined3d_gl_info *gl_info, const char *gl_renderer) -{ - if (gl_info->gl_vendor == VENDOR_NVIDIA) - { - if (gl_info->gl_card == CARD_NVIDIA_GEFORCEFX_5800 || gl_info->gl_card == CARD_NVIDIA_GEFORCEFX_5600) - { - return TRUE; - } - } - return FALSE; -} + TRACE_(d3d_caps)("(%p)\n", gl_info); -static BOOL match_apple(const struct wined3d_gl_info *gl_info, const char *gl_renderer) -{ - /* MacOS has various specialities in the extensions it advertises. Some have to be loaded from - * the opengl 1.2+ core, while other extensions are advertised, but software emulated. So try to - * detect the Apple OpenGL implementation to apply some extension fixups afterwards. - * - * Detecting this isn't really easy. The vendor string doesn't mention Apple. Compile-time checks - * aren't sufficient either because a Linux binary may display on a macos X server via remote X11. - * So try to detect the GL implementation by looking at certain Apple extensions. Some extensions - * like client storage might be supported on other implementations too, but GL_APPLE_flush_render - * is specific to the Mac OS X window management, and GL_APPLE_ycbcr_422 is QuickTime specific. So - * the chance that other implementations support them is rather small since Win32 QuickTime uses - * DirectDraw, not OpenGL. */ - if (gl_info->supported[APPLE_FENCE] - && gl_info->supported[APPLE_CLIENT_STORAGE] - && gl_info->supported[APPLE_FLUSH_RENDER] - && gl_info->supported[APPLE_YCBCR_422]) - { - TRACE_(d3d_caps)("GL_APPLE_fence, GL_APPLE_client_storage, GL_APPLE_flush_render and GL_ycbcr_422 are supported.\n"); - TRACE_(d3d_caps)("Activating MacOS fixups.\n"); - return TRUE; - } - else - { - TRACE_(d3d_caps)("Apple extensions are not supported.\n"); - TRACE_(d3d_caps)("Not activating MacOS fixups.\n"); - return FALSE; - } -} + ENTER_GL(); -/* Context activation is done by the caller. */ -static void test_pbo_functionality(struct wined3d_gl_info *gl_info) -{ - /* Some OpenGL implementations, namely Apple's Geforce 8 driver, advertises PBOs, - * but glTexSubImage from a PBO fails miserably, with the first line repeated over - * all the texture. This function detects this bug by its symptom and disables PBOs - * if the test fails. - * - * The test uploads a 4x4 texture via the PBO in the "native" format GL_BGRA, - * GL_UNSIGNED_INT_8_8_8_8_REV. This format triggers the bug, and it is what we use - * for D3DFMT_A8R8G8B8. Then the texture is read back without any PBO and the data - * read back is compared to the original. If they are equal PBOs are assumed to work, - * otherwise the PBO extension is disabled. */ - GLuint texture, pbo; - static const unsigned int pattern[] = - { - 0x00000000, 0x000000ff, 0x0000ff00, 0x40ff0000, - 0x80ffffff, 0x40ffff00, 0x00ff00ff, 0x0000ffff, - 0x00ffff00, 0x00ff00ff, 0x0000ffff, 0x000000ff, - 0x80ff00ff, 0x0000ffff, 0x00ff00ff, 0x40ff00ff - }; - unsigned int check[sizeof(pattern) / sizeof(pattern[0])]; + gl_string = (const char *) glGetString(GL_RENDERER); + if (!gl_string) gl_string = "None"; + strcpy(gl_info->gl_renderer, gl_string); - /* No PBO -> No point in testing them. */ - if (!gl_info->supported[ARB_PIXEL_BUFFER_OBJECT]) return; + gl_string = (const char *) glGetString(GL_VENDOR); + TRACE_(d3d_caps)("Filling vendor string %s\n", gl_string); + if (gl_string != NULL) { + /* Fill in the GL vendor */ + if (strstr(gl_string, "NVIDIA")) { + gl_info->gl_vendor = VENDOR_NVIDIA; + } else if (strstr(gl_string, "ATI")) { + gl_info->gl_vendor = VENDOR_ATI; + } else if (strstr(gl_string, "Intel(R)") || + strstr(gl_info->gl_renderer, "Intel(R)") || + strstr(gl_string, "Intel Inc.")) { + gl_info->gl_vendor = VENDOR_INTEL; + } else if (strstr(gl_string, "Mesa")) { + gl_info->gl_vendor = VENDOR_MESA; + } else { + gl_info->gl_vendor = VENDOR_WINE; + } + } else { + gl_info->gl_vendor = VENDOR_WINE; + } - ENTER_GL(); - while (glGetError()); - glGenTextures(1, &texture); - glBindTexture(GL_TEXTURE_2D, texture); + TRACE_(d3d_caps)("found GL_VENDOR (%s)->(0x%04x)\n", debugstr_a(gl_string), gl_info->gl_vendor); - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAX_LEVEL, 0); - glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA8, 4, 4, 0, GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV, 0); - checkGLcall("Specifying the PBO test texture"); + /* Parse the GL_VERSION field into major and minor information */ + gl_string = (const char *) glGetString(GL_VERSION); + if (gl_string != NULL) { - GL_EXTCALL(glGenBuffersARB(1, &pbo)); - GL_EXTCALL(glBindBufferARB(GL_PIXEL_UNPACK_BUFFER_ARB, pbo)); - GL_EXTCALL(glBufferDataARB(GL_PIXEL_UNPACK_BUFFER_ARB, sizeof(pattern), pattern, GL_STREAM_DRAW_ARB)); - checkGLcall("Specifying the PBO test pbo"); + /* First, parse the generic opengl version. This is supposed not to be convoluted with + * driver specific information + */ + gl_string_cursor = gl_string; + major = atoi(gl_string_cursor); + if(major <= 0) { + ERR("Invalid opengl major version: %d\n", major); + } + while (*gl_string_cursor <= '9' && *gl_string_cursor >= '0') { + ++gl_string_cursor; + } + if (*gl_string_cursor++ != '.') { + ERR_(d3d_caps)("Invalid opengl version string: %s\n", debugstr_a(gl_string)); + } + minor = atoi(gl_string_cursor); + TRACE_(d3d_caps)("Found OpenGL version: %d.%d\n", major, minor); + gl_info->gl_version = MAKEDWORD_VERSION(major, minor); - glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, 4, 4, GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV, NULL); - checkGLcall("Loading the PBO test texture"); + /* Now parse the driver specific string which we'll report to the app */ + switch (gl_info->gl_vendor) { + case VENDOR_NVIDIA: + gl_string_cursor = strstr(gl_string, "NVIDIA"); + if (!gl_string_cursor) { + ERR_(d3d_caps)("Invalid nVidia version string: %s\n", debugstr_a(gl_string)); + break; + } - GL_EXTCALL(glBindBufferARB(GL_PIXEL_UNPACK_BUFFER_ARB, 0)); - glFinish(); /* just to be sure */ + gl_string_cursor = strstr(gl_string_cursor, " "); + if (!gl_string_cursor) { + ERR_(d3d_caps)("Invalid nVidia version string: %s\n", debugstr_a(gl_string)); + break; + } - memset(check, 0, sizeof(check)); - glGetTexImage(GL_TEXTURE_2D, 0, GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV, check); - checkGLcall("Reading back the PBO test texture"); + while (*gl_string_cursor == ' ') { + ++gl_string_cursor; + } - glDeleteTextures(1, &texture); - GL_EXTCALL(glDeleteBuffersARB(1, &pbo)); - checkGLcall("PBO test cleanup"); + if (!*gl_string_cursor) { + ERR_(d3d_caps)("Invalid nVidia version string: %s\n", debugstr_a(gl_string)); + break; + } - LEAVE_GL(); + major = atoi(gl_string_cursor); + while (*gl_string_cursor <= '9' && *gl_string_cursor >= '0') { + ++gl_string_cursor; + } - if (memcmp(check, pattern, sizeof(check))) - { - WARN_(d3d_caps)("PBO test failed, read back data doesn't match original.\n"); - WARN_(d3d_caps)("Disabling PBOs. This may result in slower performance.\n"); - gl_info->supported[ARB_PIXEL_BUFFER_OBJECT] = FALSE; - } - else - { - TRACE_(d3d_caps)("PBO test successful.\n"); - } -} + if (*gl_string_cursor++ != '.') { + ERR_(d3d_caps)("Invalid nVidia version string: %s\n", debugstr_a(gl_string)); + break; + } -static BOOL match_apple_intel(const struct wined3d_gl_info *gl_info, const char *gl_renderer) -{ - return gl_info->gl_vendor == VENDOR_INTEL && match_apple(gl_info, gl_renderer); -} + minor = atoi(gl_string_cursor); + minor = major*100+minor; + major = 10; -static BOOL match_apple_nonr500ati(const struct wined3d_gl_info *gl_info, const char *gl_renderer) -{ - if (!match_apple(gl_info, gl_renderer)) return FALSE; - if (gl_info->gl_vendor != VENDOR_ATI) return FALSE; - if (gl_info->gl_card == CARD_ATI_RADEON_X1600) return FALSE; - return TRUE; -} + break; -static BOOL match_fglrx(const struct wined3d_gl_info *gl_info, const char *gl_renderer) -{ - if (gl_info->gl_vendor != VENDOR_ATI) return FALSE; - if (match_apple(gl_info, gl_renderer)) return FALSE; - if (strstr(gl_renderer, "DRI")) return FALSE; /* Filter out Mesa DRI drivers. */ - return TRUE; -} + case VENDOR_ATI: + major = minor = 0; + gl_string_cursor = strchr(gl_string, '-'); + if (gl_string_cursor) { + gl_string_cursor++; + + /* Check if version number is of the form x.y.z */ + if ( *gl_string_cursor < '0' || *gl_string_cursor > '9' + || *(gl_string_cursor+1) != '.' + || *(gl_string_cursor+2) < '0' || *(gl_string_cursor+2) > '9' + || *(gl_string_cursor+3) != '.' + || *(gl_string_cursor+4) < '0' || *(gl_string_cursor+4) > '9' ) + /* Mark version number as malformed */ + gl_string_cursor = 0; + } -static BOOL match_dx10_capable(const struct wined3d_gl_info *gl_info, const char *gl_renderer) -{ - /* DX9 cards support 40 single float varyings in hardware, most drivers report 32. ATI misreports - * 44 varyings. So assume that if we have more than 44 varyings we have a dx10 card. - * This detection is for the gl_ClipPos varying quirk. If a d3d9 card really supports more than 44 - * varyings and we subtract one in dx9 shaders its not going to hurt us because the dx9 limit is - * hardcoded - * - * dx10 cards usually have 64 varyings */ - return gl_info->max_glsl_varyings > 44; -} + if (!gl_string_cursor) + WARN_(d3d_caps)("malformed GL_VERSION (%s)\n", debugstr_a(gl_string)); + else { + major = *gl_string_cursor - '0'; + minor = (*(gl_string_cursor+2) - '0') * 256 + (*(gl_string_cursor+4) - '0'); + } + break; -/* A GL context is provided by the caller */ -static BOOL match_allows_spec_alpha(const struct wined3d_gl_info *gl_info, const char *gl_renderer) -{ - GLenum error; - DWORD data[16]; + case VENDOR_INTEL: + /* Apple and Mesa version strings look differently, but both provide intel drivers */ + if(strstr(gl_string, "APPLE")) { + /* [0-9]+.[0-9]+ APPLE-[0-9]+.[0.9]+.[0.9]+ + * We only need the first part, and use the APPLE as identification + * "1.2 APPLE-1.4.56" + */ + gl_string_cursor = gl_string; + major = atoi(gl_string_cursor); + while (*gl_string_cursor <= '9' && *gl_string_cursor >= '0') { + ++gl_string_cursor; + } - if(!GL_SUPPORT(EXT_SECONDARY_COLOR)) return FALSE; + if (*gl_string_cursor++ != '.') { + ERR_(d3d_caps)("Invalid MacOS-Intel version string: %s\n", debugstr_a(gl_string)); + break; + } - ENTER_GL(); - while(glGetError()); - GL_EXTCALL(glSecondaryColorPointerEXT)(4, GL_UNSIGNED_BYTE, 4, data); - error = glGetError(); - LEAVE_GL(); + minor = atoi(gl_string_cursor); + break; + } - if(error == GL_NO_ERROR) - { - TRACE("GL Implementation accepts 4 component specular color pointers\n"); - return TRUE; - } - else - { - TRACE("GL implementation does not accept 4 component specular colors, error %s\n", - debug_glerror(error)); - return FALSE; - } -} + case VENDOR_MESA: + gl_string_cursor = strstr(gl_string, "Mesa"); + gl_string_cursor = strstr(gl_string_cursor, " "); + while (*gl_string_cursor && ' ' == *gl_string_cursor) ++gl_string_cursor; + if (*gl_string_cursor) { + char tmp[16]; + int cursor = 0; -static void quirk_arb_constants(struct wined3d_gl_info *gl_info) -{ - TRACE_(d3d_caps)("Using ARB vs constant limit(=%u) for GLSL.\n", gl_info->vs_arb_constantsF); - gl_info->vs_glsl_constantsF = gl_info->vs_arb_constantsF; - TRACE_(d3d_caps)("Using ARB ps constant limit(=%u) for GLSL.\n", gl_info->ps_arb_constantsF); - gl_info->ps_glsl_constantsF = gl_info->ps_arb_constantsF; -} + while (*gl_string_cursor <= '9' && *gl_string_cursor >= '0') { + tmp[cursor++] = *gl_string_cursor; + ++gl_string_cursor; + } + tmp[cursor] = 0; + major = atoi(tmp); -static void quirk_apple_glsl_constants(struct wined3d_gl_info *gl_info) -{ - quirk_arb_constants(gl_info); - /* MacOS needs uniforms for relative addressing offsets. This can accumulate to quite a few uniforms. - * Beyond that the general uniform isn't optimal, so reserve a number of uniforms. 12 vec4's should - * allow 48 different offsets or other helper immediate values. */ - TRACE_(d3d_caps)("Reserving 12 GLSL constants for compiler private use.\n"); - gl_info->reserved_glsl_constants = max(gl_info->reserved_glsl_constants, 12); -} + if (*gl_string_cursor != '.') WARN_(d3d_caps)("malformed GL_VERSION (%s)\n", debugstr_a(gl_string)); + ++gl_string_cursor; -/* fglrx crashes with a very bad kernel panic if GL_POINT_SPRITE_ARB is set to GL_COORD_REPLACE_ARB - * on more than one texture unit. This means that the d3d9 visual point size test will cause a - * kernel panic on any machine running fglrx 9.3(latest that supports r300 to r500 cards). This - * quirk only enables point sprites on the first texture unit. This keeps point sprites working in - * most games, but avoids the crash - * - * A more sophisticated way would be to find all units that need texture coordinates and enable - * point sprites for one if only one is found, and software emulate point sprites in drawStridedSlow - * if more than one unit needs texture coordinates(This requires software ffp and vertex shaders though) - * - * Note that disabling the extension entirely does not gain predictability because there is no point - * sprite capability flag in d3d, so the potential rendering bugs are the same if we disable the extension. */ -static void quirk_one_point_sprite(struct wined3d_gl_info *gl_info) -{ - if (gl_info->supported[ARB_POINT_SPRITE]) - { - TRACE("Limiting point sprites to one texture unit.\n"); - gl_info->max_point_sprite_units = 1; + cursor = 0; + while (*gl_string_cursor <= '9' && *gl_string_cursor >= '0') { + tmp[cursor++] = *gl_string_cursor; + ++gl_string_cursor; + } + tmp[cursor] = 0; + minor = atoi(tmp); + } + break; + + default: + major = 0; + minor = 9; + } + gl_info->driver_version = MAKEDWORD_VERSION(major, minor); + TRACE_(d3d_caps)("found driver version (%s)->%i.%i->(0x%08x)\n", debugstr_a(gl_string), major, minor, gl_info->driver_version); + /* Current Windows drivers have versions like 6.14.... (some older have an earlier version) */ + gl_info->driver_version_hipart = MAKEDWORD_VERSION(6, 14); + } else { + FIXME("OpenGL driver did not return version information\n"); + gl_info->driver_version = MAKEDWORD_VERSION(0, 0); + gl_info->driver_version_hipart = MAKEDWORD_VERSION(6, 14); } -} -static void quirk_ati_dx9(struct wined3d_gl_info *gl_info) -{ - quirk_arb_constants(gl_info); - - /* MacOS advertises GL_ARB_texture_non_power_of_two on ATI r500 and earlier cards, although - * these cards only support GL_ARB_texture_rectangle(D3DPTEXTURECAPS_NONPOW2CONDITIONAL). - * If real NP2 textures are used, the driver falls back to software. We could just remove the - * extension and use GL_ARB_texture_rectangle instead, but texture_rectangle is inconventient - * due to the non-normalized texture coordinates. Thus set an internal extension flag, - * GL_WINE_normalized_texrect, which signals the code that it can use non power of two textures - * as per GL_ARB_texture_non_power_of_two, but has to stick to the texture_rectangle limits. - * - * fglrx doesn't advertise GL_ARB_texture_non_power_of_two, but it advertises opengl 2.0 which - * has this extension promoted to core. The extension loading code sets this extension supported - * due to that, so this code works on fglrx as well. */ - TRACE("GL_ARB_texture_non_power_of_two advertised on R500 or earlier card, removing.\n"); - gl_info->supported[ARB_TEXTURE_NON_POWER_OF_TWO] = FALSE; - gl_info->supported[WINE_NORMALIZED_TEXRECT] = TRUE; - - /* fglrx has the same structural issues as the one described in quirk_apple_glsl_constants, although - * it is generally more efficient. Reserve just 8 constants. */ - TRACE_(d3d_caps)("Reserving 8 GLSL constants for compiler private use.\n"); - gl_info->reserved_glsl_constants = max(gl_info->reserved_glsl_constants, 8); -} - -static void quirk_no_np2(struct wined3d_gl_info *gl_info) -{ - /* The nVidia GeForceFX series reports OpenGL 2.0 capabilities with the latest drivers versions, but - * doesn't explicitly advertise the ARB_tex_npot extension in the GL extension string. - * This usually means that ARB_tex_npot is supported in hardware as long as the application is staying - * within the limits enforced by the ARB_texture_rectangle extension. This however is not true for the - * FX series, which instantly falls back to a slower software path as soon as ARB_tex_npot is used. - * We therefore completely remove ARB_tex_npot from the list of supported extensions. - * - * Note that wine_normalized_texrect can't be used in this case because internally it uses ARB_tex_npot, - * triggering the software fallback. There is not much we can do here apart from disabling the - * software-emulated extension and reenable ARB_tex_rect (which was previously disabled - * in IWineD3DImpl_FillGLCaps). - * This fixup removes performance problems on both the FX 5900 and FX 5700 (e.g. for framebuffer - * post-processing effects in the game "Max Payne 2"). - * The behaviour can be verified through a simple test app attached in bugreport #14724. */ - TRACE("GL_ARB_texture_non_power_of_two advertised through OpenGL 2.0 on NV FX card, removing.\n"); - gl_info->supported[ARB_TEXTURE_NON_POWER_OF_TWO] = FALSE; - gl_info->supported[ARB_TEXTURE_RECTANGLE] = TRUE; -} - -static void quirk_texcoord_w(struct wined3d_gl_info *gl_info) -{ - /* The Intel GPUs on MacOS set the .w register of texcoords to 0.0 by default, which causes problems - * with fixed function fragment processing. Ideally this flag should be detected with a test shader - * and OpenGL feedback mode, but some GL implementations (MacOS ATI at least, probably all MacOS ones) - * do not like vertex shaders in feedback mode and return an error, even though it should be valid - * according to the spec. - * - * We don't want to enable this on all cards, as it adds an extra instruction per texcoord used. This - * makes the shader slower and eats instruction slots which should be available to the d3d app. - * - * ATI Radeon HD 2xxx cards on MacOS have the issue. Instead of checking for the buggy cards, blacklist - * all radeon cards on Macs and whitelist the good ones. That way we're prepared for the future. If - * this workaround is activated on cards that do not need it, it won't break things, just affect - * performance negatively. */ - TRACE("Enabling vertex texture coord fixes in vertex shaders.\n"); - gl_info->quirks |= WINED3D_QUIRK_SET_TEXCOORD_W; -} - -static void quirk_clip_varying(struct wined3d_gl_info *gl_info) -{ - gl_info->quirks |= WINED3D_QUIRK_GLSL_CLIP_VARYING; -} - -static void quirk_allows_specular_alpha(struct wined3d_gl_info *gl_info) -{ - gl_info->quirks |= WINED3D_QUIRK_ALLOWS_SPECULAR_ALPHA; -} - -struct driver_quirk -{ - BOOL (*match)(const struct wined3d_gl_info *gl_info, const char *gl_renderer); - void (*apply)(struct wined3d_gl_info *gl_info); - const char *description; -}; - -struct driver_quirk quirk_table[] = -{ - { - match_ati_r300_to_500, - quirk_ati_dx9, - "ATI GLSL constant and normalized texrect quirk" - }, - /* MacOS advertises more GLSL vertex shader uniforms than supported by the hardware, and if more are - * used it falls back to software. While the compiler can detect if the shader uses all declared - * uniforms, the optimization fails if the shader uses relative addressing. So any GLSL shader - * using relative addressing falls back to software. - * - * ARB vp gives the correct amount of uniforms, so use it instead of GLSL. */ - { - match_apple, - quirk_apple_glsl_constants, - "Apple GLSL uniform override" - }, - { - match_geforce5, - quirk_no_np2, - "Geforce 5 NP2 disable" - }, - { - match_apple_intel, - quirk_texcoord_w, - "Init texcoord .w for Apple Intel GPU driver" - }, - { - match_apple_nonr500ati, - quirk_texcoord_w, - "Init texcoord .w for Apple ATI >= r600 GPU driver" - }, - { - match_fglrx, - quirk_one_point_sprite, - "Fglrx point sprite crash workaround" - }, - { - match_dx10_capable, - quirk_clip_varying, - "Reserved varying for gl_ClipPos" - }, - { - /* GL_EXT_secondary_color does not allow 4 component secondary colors, but most - * GL implementations accept it. The Mac GL is the only implementation known to - * reject it. - * - * If we can pass 4 component specular colors, do it, because (a) we don't have - * to screw around with the data, and (b) the D3D fixed function vertex pipeline - * passes specular alpha to the pixel shader if any is used. Otherwise the - * specular alpha is used to pass the fog coordinate, which we pass to opengl - * via GL_EXT_fog_coord. - */ - match_allows_spec_alpha, - quirk_allows_specular_alpha, - "Allow specular alpha quirk" - } -}; - -/* Certain applications (Steam) complain if we report an outdated driver version. In general, - * reporting a driver version is moot because we are not the Windows driver, and we have different - * bugs, features, etc. - * - * If a card is not found in this table, the GL driver version is reported. */ -struct driver_version_information -{ - WORD vendor; /* reported PCI card vendor ID */ - WORD card; /* reported PCI card device ID */ - const char *description; /* Description of the card e.g. NVIDIA RIVA TNT */ - WORD hipart_hi, hipart_lo; /* driver hiword to report */ - WORD lopart_hi, lopart_lo; /* driver loword to report */ -}; - -static const struct driver_version_information driver_version_table[] = -{ - /* Nvidia drivers. Geforce6 and newer cards are supported by the current driver (180.x) - * GeforceFX support is up to 173.x, - driver uses numbering x.y.11.7341 for 173.41 where x is the windows revision (6=2000/xp, 7=vista), y is unknown - * Geforce2MX/3/4 up to 96.x - driver uses numbering 9.6.8.9 for 96.89 - * TNT/Geforce1/2 up to 71.x - driver uses numbering 7.1.8.6 for 71.86 - * - * All version numbers used below are from the Linux nvidia drivers. */ - {VENDOR_NVIDIA, CARD_NVIDIA_RIVA_TNT, "NVIDIA RIVA TNT", 7, 1, 8, 6 }, - {VENDOR_NVIDIA, CARD_NVIDIA_RIVA_TNT2, "NVIDIA RIVA TNT2/TNT2 Pro", 7, 1, 8, 6 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE, "NVIDIA GeForce 256", 7, 1, 8, 6 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE2_MX, "NVIDIA GeForce2 MX/MX 400", 9, 6, 4, 3 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE2, "NVIDIA GeForce2 GTS/GeForce2 Pro", 7, 1, 8, 6 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE3, "NVIDIA GeForce3", 9, 6, 10, 9371 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE4_MX, "NVIDIA GeForce4 MX 460", 9, 6, 10, 9371 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE4_TI4200, "NVIDIA GeForce4 Ti 4200", 9, 6, 10, 9371 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCEFX_5200, "NVIDIA GeForce FX 5200", 7, 15, 11, 7516 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCEFX_5600, "NVIDIA GeForce FX 5600", 7, 15, 11, 7516 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCEFX_5800, "NVIDIA GeForce FX 5800", 7, 15, 11, 7516 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_6200, "NVIDIA GeForce 6200", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_6600GT, "NVIDIA GeForce 6600 GT", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_6800, "NVIDIA GeForce 6800", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_7300, "NVIDIA GeForce Go 7300", 7, 15, 11, 8585 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_7400, "NVIDIA GeForce Go 7400", 7, 15, 11, 8585 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_7600, "NVIDIA GeForce 7600 GT", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_7800GT, "NVIDIA GeForce 7800 GT", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8300GS, "NVIDIA GeForce 8300 GS", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8600GT, "NVIDIA GeForce 8600 GT", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8600MGT, "NVIDIA GeForce 8600M GT", 7, 15, 11, 8585 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8800GTS, "NVIDIA GeForce 8800 GTS", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9200, "NVIDIA GeForce 9200", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9400GT, "NVIDIA GeForce 9400 GT", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9500GT, "NVIDIA GeForce 9500 GT", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9600GT, "NVIDIA GeForce 9600 GT", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9800GT, "NVIDIA GeForce 9800 GT", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX260, "NVIDIA GeForce GTX 260", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX275, "NVIDIA GeForce GTX 275", 7, 15, 11, 8618 }, - {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX280, "NVIDIA GeForce GTX 280", 7, 15, 11, 8618 }, - - /* ATI cards. The driver versions are somewhat similar, but not quite the same. Let's hardcode. */ - {VENDOR_ATI, CARD_ATI_RADEON_9500, "ATI Radeon 9500", 6, 14, 10, 6764 }, - {VENDOR_ATI, CARD_ATI_RADEON_X700, "ATI Radeon X700 SE", 6, 14, 10, 6764 }, - {VENDOR_ATI, CARD_ATI_RADEON_X1600, "ATI Radeon X1600 Series", 6, 14, 10, 6764 }, - {VENDOR_ATI, CARD_ATI_RADEON_HD2300, "ATI Mobility Radeon HD 2300", 6, 14, 10, 6764 }, - {VENDOR_ATI, CARD_ATI_RADEON_HD2600, "ATI Mobility Radeon HD 2600", 6, 14, 10, 6764 }, - {VENDOR_ATI, CARD_ATI_RADEON_HD2900, "ATI Radeon HD 2900 XT", 6, 14, 10, 6764 }, - {VENDOR_ATI, CARD_ATI_RADEON_HD4350, "ATI Radeon HD 4350", 6, 14, 10, 6764 }, - {VENDOR_ATI, CARD_ATI_RADEON_HD4600, "ATI Radeon HD 4600 Series", 6, 14, 10, 6764 }, - {VENDOR_ATI, CARD_ATI_RADEON_HD4700, "ATI Radeon HD 4700 Series", 6, 14, 10, 6764 }, - {VENDOR_ATI, CARD_ATI_RADEON_HD4800, "ATI Radeon HD 4800 Series", 6, 14, 10, 6764 }, - - /* TODO: Add information about legacy ATI hardware, Intel and other cards. */ -}; - -/* Context activation is done by the caller. */ -static void fixup_extensions(struct wined3d_gl_info *gl_info, const char *gl_renderer) -{ - unsigned int i; - - for (i = 0; i < (sizeof(quirk_table) / sizeof(*quirk_table)); ++i) - { - if (!quirk_table[i].match(gl_info, gl_renderer)) continue; - TRACE_(d3d_caps)("Applying driver quirk \"%s\".\n", quirk_table[i].description); - quirk_table[i].apply(gl_info); - } - - /* Find out if PBOs work as they are supposed to. */ - test_pbo_functionality(gl_info); - - /* Fixup the driver version */ - for (i = 0; i < (sizeof(driver_version_table) / sizeof(driver_version_table[0])); ++i) - { - if (gl_info->gl_vendor == driver_version_table[i].vendor - && gl_info->gl_card == driver_version_table[i].card) - { - TRACE_(d3d_caps)("Found card 0x%04x, 0x%04x in driver version DB.\n", - gl_info->gl_vendor, gl_info->gl_card); - - gl_info->driver_version = MAKEDWORD_VERSION(driver_version_table[i].lopart_hi, - driver_version_table[i].lopart_lo); - gl_info->driver_version_hipart = MAKEDWORD_VERSION(driver_version_table[i].hipart_hi, - driver_version_table[i].hipart_lo); - gl_info->driver_description = driver_version_table[i].description; - break; - } - } -} - -/* Context activation is done by the caller. */ -static BOOL IWineD3DImpl_FillGLCaps(struct wined3d_gl_info *gl_info) -{ - const char *GL_Extensions = NULL; - const char *WGL_Extensions = NULL; - const char *gl_string = NULL; - const char *gl_string_cursor = NULL; - GLint gl_max; - GLfloat gl_floatv[2]; - int major = 1, minor = 0; - unsigned i; - HDC hdc; - unsigned int vidmem=0; - char *gl_renderer; - DWORD gl_version; - size_t len; - - TRACE_(d3d_caps)("(%p)\n", gl_info); - - ENTER_GL(); - - gl_string = (const char *)glGetString(GL_RENDERER); - TRACE_(d3d_caps)("GL_RENDERER: %s.\n", gl_string); - if (!gl_string) - { - ERR_(d3d_caps)("Received a NULL GL_RENDERER.\n"); - return FALSE; - } - - len = strlen(gl_string) + 1; - gl_renderer = HeapAlloc(GetProcessHeap(), 0, len); - if (!gl_renderer) - { - ERR_(d3d_caps)("Failed to allocate gl_renderer memory.\n"); - return FALSE; - } - memcpy(gl_renderer, gl_string, len); - - gl_string = (const char *)glGetString(GL_VENDOR); - TRACE_(d3d_caps)("GL_VENDOR: %s.\n", gl_string); - if (!gl_string) - { - ERR_(d3d_caps)("Received a NULL GL_VENDOR.\n"); - HeapFree(GetProcessHeap(), 0, gl_renderer); - return FALSE; - } - - /* Fill in the GL vendor */ - if (strstr(gl_string, "NVIDIA")) - { - gl_info->gl_vendor = VENDOR_NVIDIA; - } - else if (strstr(gl_string, "ATI")) - { - gl_info->gl_vendor = VENDOR_ATI; - } - else if (strstr(gl_string, "Intel(R)") - || strstr(gl_renderer, "Intel(R)") - || strstr(gl_string, "Intel Inc.")) - { - gl_info->gl_vendor = VENDOR_INTEL; - } - else if (strstr(gl_string, "Mesa")) - { - gl_info->gl_vendor = VENDOR_MESA; - } - else - { - FIXME_(d3d_caps)("Received unrecognized GL_VENDOR %s. Setting VENDOR_WINE.\n", gl_string); - gl_info->gl_vendor = VENDOR_WINE; - } - TRACE_(d3d_caps)("found GL_VENDOR (%s)->(0x%04x)\n", debugstr_a(gl_string), gl_info->gl_vendor); - - /* Parse the GL_VERSION field into major and minor information */ - gl_string = (const char *)glGetString(GL_VERSION); - TRACE_(d3d_caps)("GL_VERSION: %s.\n", gl_string); - if (!gl_string) - { - ERR_(d3d_caps)("Received a NULL GL_VERSION.\n"); - HeapFree(GetProcessHeap(), 0, gl_renderer); - return FALSE; - } - - /* First, parse the generic opengl version. This is supposed not to be - * convoluted with driver specific information. */ - gl_string_cursor = gl_string; - - major = atoi(gl_string_cursor); - if (major <= 0) ERR_(d3d_caps)("Invalid opengl major version: %d.\n", major); - while (*gl_string_cursor <= '9' && *gl_string_cursor >= '0') ++gl_string_cursor; - if (*gl_string_cursor++ != '.') ERR_(d3d_caps)("Invalid opengl version string: %s.\n", debugstr_a(gl_string)); - - minor = atoi(gl_string_cursor); - TRACE_(d3d_caps)("Found OpenGL version: %d.%d.\n", major, minor); - gl_version = MAKEDWORD_VERSION(major, minor); - - /* Now parse the driver specific string which we'll report to the app. */ - switch (gl_info->gl_vendor) - { - case VENDOR_NVIDIA: - gl_string_cursor = strstr(gl_string, "NVIDIA"); - if (!gl_string_cursor) - { - ERR_(d3d_caps)("Invalid nVidia version string: %s.\n", debugstr_a(gl_string)); - break; - } - - gl_string_cursor = strstr(gl_string_cursor, " "); - if (!gl_string_cursor) - { - ERR_(d3d_caps)("Invalid nVidia version string: %s.\n", debugstr_a(gl_string)); - break; - } - - while (*gl_string_cursor == ' ') ++gl_string_cursor; - - if (!*gl_string_cursor) - { - ERR_(d3d_caps)("Invalid nVidia version string: %s.\n", debugstr_a(gl_string)); - break; - } - - major = atoi(gl_string_cursor); - while (*gl_string_cursor <= '9' && *gl_string_cursor >= '0') ++gl_string_cursor; - - if (*gl_string_cursor++ != '.') - { - ERR_(d3d_caps)("Invalid nVidia version string: %s.\n", debugstr_a(gl_string)); - break; - } - - minor = atoi(gl_string_cursor); - minor = major * 100 + minor; - major = 10; - break; - - case VENDOR_ATI: - major = minor = 0; - gl_string_cursor = strchr(gl_string, '-'); - if (gl_string_cursor) - { - ++gl_string_cursor; - - /* Check if version number is of the form x.y.z. */ - if (*gl_string_cursor < '0' || *gl_string_cursor > '9' - || gl_string_cursor[1] != '.' - || gl_string_cursor[2] < '0' || gl_string_cursor[2] > '9' - || gl_string_cursor[3] != '.' - || gl_string_cursor[4] < '0' || gl_string_cursor[4] > '9') - /* Mark version number as malformed. */ - gl_string_cursor = 0; - } - - if (!gl_string_cursor) - { - WARN_(d3d_caps)("malformed GL_VERSION (%s).\n", debugstr_a(gl_string)); - } - else - { - major = *gl_string_cursor - '0'; - minor = (gl_string_cursor[2] - '0') * 256 + (gl_string_cursor[4] - '0'); - } - break; - - case VENDOR_INTEL: - /* Apple and Mesa version strings look differently, but both provide intel drivers. */ - if (strstr(gl_string, "APPLE")) - { - /* [0-9]+.[0-9]+ APPLE-[0-9]+.[0.9]+.[0.9]+ - * We only need the first part, and use the APPLE as identification - * "1.2 APPLE-1.4.56". */ - gl_string_cursor = gl_string; - major = atoi(gl_string_cursor); - while (*gl_string_cursor <= '9' && *gl_string_cursor >= '0') ++gl_string_cursor; - - if (*gl_string_cursor++ != '.') - { - ERR_(d3d_caps)("Invalid MacOS-Intel version string: %s.\n", debugstr_a(gl_string)); - break; - } - - minor = atoi(gl_string_cursor); - break; - } - /* Fallthrough */ - - case VENDOR_MESA: - gl_string_cursor = strstr(gl_string, "Mesa"); - gl_string_cursor = strstr(gl_string_cursor, " "); - while (*gl_string_cursor && ' ' == *gl_string_cursor) ++gl_string_cursor; - if (*gl_string_cursor) - { - char tmp[16]; - int cursor = 0; - - while (*gl_string_cursor <= '9' && *gl_string_cursor >= '0') - { - tmp[cursor++] = *gl_string_cursor; - ++gl_string_cursor; - } - tmp[cursor] = 0; - major = atoi(tmp); - - if (*gl_string_cursor != '.') WARN_(d3d_caps)("malformed GL_VERSION (%s).\n", debugstr_a(gl_string)); - ++gl_string_cursor; - - cursor = 0; - while (*gl_string_cursor <= '9' && *gl_string_cursor >= '0') - { - tmp[cursor++] = *gl_string_cursor; - ++gl_string_cursor; - } - tmp[cursor] = 0; - minor = atoi(tmp); - } - break; - - default: - major = 0; - minor = 9; - break; - } - - gl_info->driver_version = MAKEDWORD_VERSION(major, minor); - TRACE_(d3d_caps)("found driver version (%s)->%i.%i->(0x%08x).\n", - debugstr_a(gl_string), major, minor, gl_info->driver_version); - /* Current Windows drivers have versions like 6.14.... (some older have an earlier version). */ - gl_info->driver_version_hipart = MAKEDWORD_VERSION(6, 14); + TRACE_(d3d_caps)("found GL_RENDERER (%s)->(0x%04x)\n", debugstr_a(gl_info->gl_renderer), gl_info->gl_card); /* * Initialize openGL extension related variables @@ -1182,7 +725,6 @@ static BOOL IWineD3DImpl_FillGLCaps(struct wined3d_gl_info *gl_info) gl_info->ps_glsl_constantsF = 0; gl_info->vs_arb_constantsF = 0; gl_info->ps_arb_constantsF = 0; - gl_info->ps_arb_max_local_constants = 0; /* Retrieve opengl defaults */ glGetIntegerv(GL_MAX_CLIP_PLANES, &gl_max); @@ -1202,331 +744,285 @@ static BOOL IWineD3DImpl_FillGLCaps(struct wined3d_gl_info *gl_info) gl_info->max_pointsize = gl_floatv[1]; TRACE_(d3d_caps)("Maximum point size support - max point size=%f\n", gl_floatv[1]); - /* Parse the gl supported features, in theory enabling parts of our code appropriately. */ - GL_Extensions = (const char *)glGetString(GL_EXTENSIONS); - if (!GL_Extensions) - { - ERR_(d3d_caps)("Received a NULL GL_EXTENSIONS.\n"); - HeapFree(GetProcessHeap(), 0, gl_renderer); - return FALSE; - } - + /* Parse the gl supported features, in theory enabling parts of our code appropriately */ + GL_Extensions = (const char *) glGetString(GL_EXTENSIONS); TRACE_(d3d_caps)("GL_Extensions reported:\n"); - gl_info->supported[WINED3D_GL_EXT_NONE] = TRUE; + if (NULL == GL_Extensions) { + ERR(" GL_Extensions returns NULL\n"); + } else { + gl_info->supported[WINED3D_GL_EXT_NONE] = TRUE; - while (*GL_Extensions) - { - const char *start; - char current_ext[256]; + while (*GL_Extensions != 0x00) { + const char *Start; + char ThisExtn[256]; + size_t len; - while (isspace(*GL_Extensions)) ++GL_Extensions; - start = GL_Extensions; - while (!isspace(*GL_Extensions) && *GL_Extensions) ++GL_Extensions; + while (isspace(*GL_Extensions)) GL_Extensions++; + Start = GL_Extensions; + while (!isspace(*GL_Extensions) && *GL_Extensions != 0x00) { + GL_Extensions++; + } - len = GL_Extensions - start; - if (!len || len >= sizeof(current_ext)) continue; + len = GL_Extensions - Start; + if (len == 0 || len >= sizeof(ThisExtn)) + continue; - memcpy(current_ext, start, len); - current_ext[len] = '\0'; - TRACE_(d3d_caps)("- %s\n", current_ext); + memcpy(ThisExtn, Start, len); + ThisExtn[len] = '\0'; + TRACE_(d3d_caps)("- %s\n", ThisExtn); - for (i = 0; i < (sizeof(EXTENSION_MAP) / sizeof(*EXTENSION_MAP)); ++i) - { - if (!strcmp(current_ext, EXTENSION_MAP[i].extension_string)) - { - TRACE_(d3d_caps)(" FOUND: %s support.\n", EXTENSION_MAP[i].extension_string); - gl_info->supported[EXTENSION_MAP[i].extension] = TRUE; - break; + for (i = 0; i < (sizeof(EXTENSION_MAP) / sizeof(*EXTENSION_MAP)); ++i) { + if (!strcmp(ThisExtn, EXTENSION_MAP[i].extension_string)) { + TRACE_(d3d_caps)(" FOUND: %s support\n", EXTENSION_MAP[i].extension_string); + gl_info->supported[EXTENSION_MAP[i].extension] = TRUE; + break; + } } } - } - LEAVE_GL(); + LEAVE_GL(); - /* Now work out what GL support this card really has */ -#define USE_GL_FUNC(type, pfn, ext, replace) \ -{ \ - DWORD ver = ver_for_ext(ext); \ - if (gl_info->supported[ext]) gl_info->pfn = (type)pwglGetProcAddress(#pfn); \ - else if (ver && ver <= gl_version) gl_info->pfn = (type)pwglGetProcAddress(#replace); \ - else gl_info->pfn = NULL; \ -} - GL_EXT_FUNCS_GEN; + /* Now work out what GL support this card really has */ +#define USE_GL_FUNC(type, pfn, ext, replace) { \ + DWORD ver = ver_for_ext(ext); \ + if(gl_info->supported[ext]) gl_info->pfn = (type) pwglGetProcAddress(#pfn); \ + else if(ver && ver <= gl_info->gl_version) gl_info->pfn = (type) pwglGetProcAddress(#replace); \ + else gl_info->pfn = NULL; \ + } + GL_EXT_FUNCS_GEN; #undef USE_GL_FUNC -#define USE_GL_FUNC(type, pfn, ext, replace) gl_info->pfn = (type)pwglGetProcAddress(#pfn); - WGL_EXT_FUNCS_GEN; +#define USE_GL_FUNC(type, pfn, ext, replace) gl_info->pfn = (type) pwglGetProcAddress(#pfn); + WGL_EXT_FUNCS_GEN; #undef USE_GL_FUNC - ENTER_GL(); - - /* Now mark all the extensions supported which are included in the opengl core version. Do this *after* - * loading the functions, otherwise the code above will load the extension entry points instead of the - * core functions, which may not work. */ - for (i = 0; i < (sizeof(EXTENSION_MAP) / sizeof(*EXTENSION_MAP)); ++i) - { - if (!gl_info->supported[EXTENSION_MAP[i].extension] - && EXTENSION_MAP[i].version <= gl_version && EXTENSION_MAP[i].version) - { - TRACE_(d3d_caps)(" GL CORE: %s support.\n", EXTENSION_MAP[i].extension_string); - gl_info->supported[EXTENSION_MAP[i].extension] = TRUE; + ENTER_GL(); + /* Now mark all the extensions supported which are included in the opengl core version. Do this *after* + * loading the functions, otherwise the code above will load the extension entry points instead of the + * core functions, which may not work + */ + for (i = 0; i < (sizeof(EXTENSION_MAP) / sizeof(*EXTENSION_MAP)); ++i) { + if (gl_info->supported[EXTENSION_MAP[i].extension] == FALSE && + EXTENSION_MAP[i].version <= gl_info->gl_version && EXTENSION_MAP[i].version) { + TRACE_(d3d_caps)(" GL CORE: %s support\n", EXTENSION_MAP[i].extension_string); + gl_info->supported[EXTENSION_MAP[i].extension] = TRUE; + } } - } - if (gl_info->supported[APPLE_FENCE]) - { - /* GL_NV_fence and GL_APPLE_fence provide the same functionality basically. - * The apple extension interacts with some other apple exts. Disable the NV - * extension if the apple one is support to prevent confusion in other parts - * of the code. */ - gl_info->supported[NV_FENCE] = FALSE; - } - if (gl_info->supported[APPLE_FLOAT_PIXELS]) - { - /* GL_APPLE_float_pixels == GL_ARB_texture_float + GL_ARB_half_float_pixel - * - * The enums are the same: - * GL_RGBA16F_ARB = GL_RGBA_FLOAT16_APPLE = 0x881A - * GL_RGB16F_ARB = GL_RGB_FLOAT16_APPLE = 0x881B - * GL_RGBA32F_ARB = GL_RGBA_FLOAT32_APPLE = 0x8814 - * GL_RGB32F_ARB = GL_RGB_FLOAT32_APPLE = 0x8815 - * GL_HALF_FLOAT_ARB = GL_HALF_APPLE = 0x140B - */ - if (!gl_info->supported[ARB_TEXTURE_FLOAT]) - { - TRACE_(d3d_caps)(" IMPLIED: GL_ARB_texture_float support(from GL_APPLE_float_pixels.\n"); - gl_info->supported[ARB_TEXTURE_FLOAT] = TRUE; + if (gl_info->supported[APPLE_FENCE]) { + /* GL_NV_fence and GL_APPLE_fence provide the same functionality basically. + * The apple extension interacts with some other apple exts. Disable the NV + * extension if the apple one is support to prevent confusion in other parts + * of the code + */ + gl_info->supported[NV_FENCE] = FALSE; } - if (!gl_info->supported[ARB_HALF_FLOAT_PIXEL]) - { - TRACE_(d3d_caps)(" IMPLIED: GL_ARB_half_float_pixel support(from GL_APPLE_float_pixels.\n"); - gl_info->supported[ARB_HALF_FLOAT_PIXEL] = TRUE; + if (gl_info->supported[APPLE_FLOAT_PIXELS]) { + /* GL_APPLE_float_pixels == GL_ARB_texture_float + GL_ARB_half_float_pixel + * + * The enums are the same: + * GL_RGBA16F_ARB = GL_RGBA_FLOAT16_APPLE = 0x881A + * GL_RGB16F_ARB = GL_RGB_FLOAT16_APPLE = 0x881B + * GL_RGBA32F_ARB = GL_RGBA_FLOAT32_APPLE = 0x8814 + * GL_RGB32F_ARB = GL_RGB_FLOAT32_APPLE = 0x8815 + * GL_HALF_FLOAT_ARB = GL_HALF_APPLE = 0x140B + */ + if(!gl_info->supported[ARB_TEXTURE_FLOAT]) { + TRACE_(d3d_caps)(" IMPLIED: GL_ARB_texture_float support(from GL_APPLE_float_pixels\n"); + gl_info->supported[ARB_TEXTURE_FLOAT] = TRUE; + } + if(!gl_info->supported[ARB_HALF_FLOAT_PIXEL]) { + TRACE_(d3d_caps)(" IMPLIED: GL_ARB_half_float_pixel support(from GL_APPLE_float_pixels\n"); + gl_info->supported[ARB_HALF_FLOAT_PIXEL] = TRUE; + } } - } - if (gl_info->supported[ARB_TEXTURE_CUBE_MAP]) - { - TRACE_(d3d_caps)(" IMPLIED: NVIDIA (NV) Texture Gen Reflection support.\n"); - gl_info->supported[NV_TEXGEN_REFLECTION] = TRUE; - } - if (gl_info->supported[NV_TEXTURE_SHADER2]) - { - if (gl_info->supported[NV_REGISTER_COMBINERS]) - { - /* Also disable ATI_FRAGMENT_SHADER if register combiners and texture_shader2 - * are supported. The nv extensions provide the same functionality as the - * ATI one, and a bit more(signed pixelformats). */ - gl_info->supported[ATI_FRAGMENT_SHADER] = FALSE; + if (gl_info->supported[ARB_TEXTURE_CUBE_MAP]) { + TRACE_(d3d_caps)(" IMPLIED: NVIDIA (NV) Texture Gen Reflection support\n"); + gl_info->supported[NV_TEXGEN_REFLECTION] = TRUE; } - } - if (gl_info->supported[ARB_DRAW_BUFFERS]) - { - glGetIntegerv(GL_MAX_DRAW_BUFFERS_ARB, &gl_max); - gl_info->max_buffers = gl_max; - TRACE_(d3d_caps)("Max draw buffers: %u.\n", gl_max); - } - if (gl_info->supported[ARB_MULTITEXTURE]) - { - glGetIntegerv(GL_MAX_TEXTURE_UNITS_ARB, &gl_max); - gl_info->max_textures = min(MAX_TEXTURES, gl_max); - TRACE_(d3d_caps)("Max textures: %d.\n", gl_info->max_textures); - - if (gl_info->supported[NV_REGISTER_COMBINERS]) - { - GLint tmp; - glGetIntegerv(GL_MAX_GENERAL_COMBINERS_NV, &tmp); - gl_info->max_texture_stages = min(MAX_TEXTURES, tmp); + if (gl_info->supported[NV_TEXTURE_SHADER2]) { + if(gl_info->supported[NV_REGISTER_COMBINERS]) { + /* Also disable ATI_FRAGMENT_SHADER if register combiners and texture_shader2 + * are supported. The nv extensions provide the same functionality as the + * ATI one, and a bit more(signed pixelformats) + */ + gl_info->supported[ATI_FRAGMENT_SHADER] = FALSE; + } } - else - { - gl_info->max_texture_stages = min(MAX_TEXTURES, gl_max); + if (gl_info->supported[ARB_DRAW_BUFFERS]) { + glGetIntegerv(GL_MAX_DRAW_BUFFERS_ARB, &gl_max); + gl_info->max_buffers = gl_max; + TRACE_(d3d_caps)("Max draw buffers: %u\n", gl_max); } - TRACE_(d3d_caps)("Max texture stages: %d.\n", gl_info->max_texture_stages); + if (gl_info->supported[ARB_MULTITEXTURE]) { + glGetIntegerv(GL_MAX_TEXTURE_UNITS_ARB, &gl_max); + gl_info->max_textures = min(MAX_TEXTURES, gl_max); + TRACE_(d3d_caps)("Max textures: %d\n", gl_info->max_textures); + + if (gl_info->supported[NV_REGISTER_COMBINERS]) { + GLint tmp; + glGetIntegerv(GL_MAX_GENERAL_COMBINERS_NV, &tmp); + gl_info->max_texture_stages = min(MAX_TEXTURES, tmp); + } else { + gl_info->max_texture_stages = min(MAX_TEXTURES, gl_max); + } + TRACE_(d3d_caps)("Max texture stages: %d\n", gl_info->max_texture_stages); - if (gl_info->supported[ARB_FRAGMENT_PROGRAM]) - { - GLint tmp; - glGetIntegerv(GL_MAX_TEXTURE_IMAGE_UNITS_ARB, &tmp); - gl_info->max_fragment_samplers = min(MAX_FRAGMENT_SAMPLERS, tmp); + if (gl_info->supported[ARB_FRAGMENT_PROGRAM]) { + GLint tmp; + glGetIntegerv(GL_MAX_TEXTURE_IMAGE_UNITS_ARB, &tmp); + gl_info->max_fragment_samplers = min(MAX_FRAGMENT_SAMPLERS, tmp); + } else { + gl_info->max_fragment_samplers = max(gl_info->max_fragment_samplers, gl_max); + } + TRACE_(d3d_caps)("Max fragment samplers: %d\n", gl_info->max_fragment_samplers); + + if (gl_info->supported[ARB_VERTEX_SHADER]) { + GLint tmp; + glGetIntegerv(GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB, &tmp); + gl_info->max_vertex_samplers = tmp; + glGetIntegerv(GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS_ARB, &tmp); + gl_info->max_combined_samplers = tmp; + + /* Loading GLSL sampler uniforms is much simpler if we can assume that the sampler setup + * is known at shader link time. In a vertex shader + pixel shader combination this isn't + * an issue because then the sampler setup only depends on the two shaders. If a pixel + * shader is used with fixed function vertex processing we're fine too because fixed function + * vertex processing doesn't use any samplers. If fixed function fragment processing is + * used we have to make sure that all vertex sampler setups are valid together with all + * possible fixed function fragment processing setups. This is true if vsamplers + MAX_TEXTURES + * <= max_samplers. This is true on all d3d9 cards that support vtf(gf 6 and gf7 cards). + * dx9 radeon cards do not support vertex texture fetch. DX10 cards have 128 samplers, and + * dx9 is limited to 8 fixed function texture stages and 4 vertex samplers. DX10 does not have + * a fixed function pipeline anymore. + * + * So this is just a check to check that our assumption holds true. If not, write a warning + * and reduce the number of vertex samplers or probably disable vertex texture fetch. + */ + if(gl_info->max_vertex_samplers && gl_info->max_combined_samplers < 12 && + MAX_TEXTURES + gl_info->max_vertex_samplers > gl_info->max_combined_samplers) { + FIXME("OpenGL implementation supports %u vertex samplers and %u total samplers\n", + gl_info->max_vertex_samplers, gl_info->max_combined_samplers); + FIXME("Expected vertex samplers + MAX_TEXTURES(=8) > combined_samplers\n"); + if( gl_info->max_combined_samplers > MAX_TEXTURES ) + gl_info->max_vertex_samplers = + gl_info->max_combined_samplers - MAX_TEXTURES; + else + gl_info->max_vertex_samplers = 0; + } + } else { + gl_info->max_combined_samplers = gl_info->max_fragment_samplers; + } + TRACE_(d3d_caps)("Max vertex samplers: %u\n", gl_info->max_vertex_samplers); + TRACE_(d3d_caps)("Max combined samplers: %u\n", gl_info->max_combined_samplers); } - else - { - gl_info->max_fragment_samplers = max(gl_info->max_fragment_samplers, gl_max); + if (gl_info->supported[ARB_VERTEX_BLEND]) { + glGetIntegerv(GL_MAX_VERTEX_UNITS_ARB, &gl_max); + gl_info->max_blends = gl_max; + TRACE_(d3d_caps)("Max blends: %u\n", gl_info->max_blends); } - TRACE_(d3d_caps)("Max fragment samplers: %d.\n", gl_info->max_fragment_samplers); - - if (gl_info->supported[ARB_VERTEX_SHADER]) - { - GLint tmp; - glGetIntegerv(GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB, &tmp); - gl_info->max_vertex_samplers = tmp; - glGetIntegerv(GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS_ARB, &tmp); - gl_info->max_combined_samplers = tmp; - - /* Loading GLSL sampler uniforms is much simpler if we can assume that the sampler setup - * is known at shader link time. In a vertex shader + pixel shader combination this isn't - * an issue because then the sampler setup only depends on the two shaders. If a pixel - * shader is used with fixed function vertex processing we're fine too because fixed function - * vertex processing doesn't use any samplers. If fixed function fragment processing is - * used we have to make sure that all vertex sampler setups are valid together with all - * possible fixed function fragment processing setups. This is true if vsamplers + MAX_TEXTURES - * <= max_samplers. This is true on all d3d9 cards that support vtf(gf 6 and gf7 cards). - * dx9 radeon cards do not support vertex texture fetch. DX10 cards have 128 samplers, and - * dx9 is limited to 8 fixed function texture stages and 4 vertex samplers. DX10 does not have - * a fixed function pipeline anymore. - * - * So this is just a check to check that our assumption holds true. If not, write a warning - * and reduce the number of vertex samplers or probably disable vertex texture fetch. */ - if (gl_info->max_vertex_samplers && gl_info->max_combined_samplers < 12 - && MAX_TEXTURES + gl_info->max_vertex_samplers > gl_info->max_combined_samplers) - { - FIXME("OpenGL implementation supports %u vertex samplers and %u total samplers.\n", - gl_info->max_vertex_samplers, gl_info->max_combined_samplers); - FIXME("Expected vertex samplers + MAX_TEXTURES(=8) > combined_samplers.\n"); - if (gl_info->max_combined_samplers > MAX_TEXTURES) - gl_info->max_vertex_samplers = gl_info->max_combined_samplers - MAX_TEXTURES; - else - gl_info->max_vertex_samplers = 0; - } + if (gl_info->supported[EXT_TEXTURE3D]) { + glGetIntegerv(GL_MAX_3D_TEXTURE_SIZE_EXT, &gl_max); + gl_info->max_texture3d_size = gl_max; + TRACE_(d3d_caps)("Max texture3D size: %d\n", gl_info->max_texture3d_size); } - else - { - gl_info->max_combined_samplers = gl_info->max_fragment_samplers; + if (gl_info->supported[EXT_TEXTURE_FILTER_ANISOTROPIC]) { + glGetIntegerv(GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT, &gl_max); + gl_info->max_anisotropy = gl_max; + TRACE_(d3d_caps)("Max anisotropy: %d\n", gl_info->max_anisotropy); + } + if (gl_info->supported[ARB_FRAGMENT_PROGRAM]) { + gl_info->ps_arb_version = PS_VERSION_11; + GL_EXTCALL(glGetProgramivARB(GL_FRAGMENT_PROGRAM_ARB, GL_MAX_PROGRAM_ENV_PARAMETERS_ARB, &gl_max)); + gl_info->ps_arb_constantsF = gl_max; + TRACE_(d3d_caps)("Max ARB_FRAGMENT_PROGRAM float constants: %d\n", gl_info->ps_arb_constantsF); + GL_EXTCALL(glGetProgramivARB(GL_FRAGMENT_PROGRAM_ARB, GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB, &gl_max)); + gl_info->ps_arb_max_temps = gl_max; + TRACE_(d3d_caps)("Max ARB_FRAGMENT_PROGRAM native temporaries: %d\n", gl_info->ps_arb_max_temps); + GL_EXTCALL(glGetProgramivARB(GL_FRAGMENT_PROGRAM_ARB, GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB, &gl_max)); + gl_info->ps_arb_max_instructions = gl_max; + TRACE_(d3d_caps)("Max ARB_FRAGMENT_PROGRAM native instructions: %d\n", gl_info->ps_arb_max_instructions); + } + if (gl_info->supported[ARB_VERTEX_PROGRAM]) { + gl_info->vs_arb_version = VS_VERSION_11; + GL_EXTCALL(glGetProgramivARB(GL_VERTEX_PROGRAM_ARB, GL_MAX_PROGRAM_ENV_PARAMETERS_ARB, &gl_max)); + gl_info->vs_arb_constantsF = gl_max; + TRACE_(d3d_caps)("Max ARB_VERTEX_PROGRAM float constants: %d\n", gl_info->vs_arb_constantsF); + GL_EXTCALL(glGetProgramivARB(GL_VERTEX_PROGRAM_ARB, GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB, &gl_max)); + gl_info->vs_arb_max_temps = gl_max; + TRACE_(d3d_caps)("Max ARB_VERTEX_PROGRAM native temporaries: %d\n", gl_info->vs_arb_max_temps); + GL_EXTCALL(glGetProgramivARB(GL_VERTEX_PROGRAM_ARB, GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB, &gl_max)); + gl_info->vs_arb_max_instructions = gl_max; + TRACE_(d3d_caps)("Max ARB_VERTEX_PROGRAM native instructions: %d\n", gl_info->vs_arb_max_instructions); + + gl_info->arb_vs_offset_limit = test_arb_vs_offset_limit(gl_info); + } + if (gl_info->supported[ARB_VERTEX_SHADER]) { + glGetIntegerv(GL_MAX_VERTEX_UNIFORM_COMPONENTS_ARB, &gl_max); + gl_info->vs_glsl_constantsF = gl_max / 4; + TRACE_(d3d_caps)("Max ARB_VERTEX_SHADER float constants: %u\n", gl_info->vs_glsl_constantsF); + } + if (gl_info->supported[ARB_FRAGMENT_SHADER]) { + glGetIntegerv(GL_MAX_FRAGMENT_UNIFORM_COMPONENTS_ARB, &gl_max); + gl_info->ps_glsl_constantsF = gl_max / 4; + TRACE_(d3d_caps)("Max ARB_FRAGMENT_SHADER float constants: %u\n", gl_info->ps_glsl_constantsF); + glGetIntegerv(GL_MAX_VARYING_FLOATS_ARB, &gl_max); + gl_info->max_glsl_varyings = gl_max; + TRACE_(d3d_caps)("Max GLSL varyings: %u (%u 4 component varyings)\n", gl_max, gl_max / 4); + } + if (gl_info->supported[EXT_VERTEX_SHADER]) { + gl_info->vs_ati_version = VS_VERSION_11; + } + if (gl_info->supported[NV_VERTEX_PROGRAM3]) { + gl_info->vs_nv_version = VS_VERSION_30; + } else if (gl_info->supported[NV_VERTEX_PROGRAM2]) { + gl_info->vs_nv_version = VS_VERSION_20; + } else if (gl_info->supported[NV_VERTEX_PROGRAM1_1]) { + gl_info->vs_nv_version = VS_VERSION_11; + } else if (gl_info->supported[NV_VERTEX_PROGRAM]) { + gl_info->vs_nv_version = VS_VERSION_10; + } + if (gl_info->supported[NV_FRAGMENT_PROGRAM2]) { + gl_info->ps_nv_version = PS_VERSION_30; + } else if (gl_info->supported[NV_FRAGMENT_PROGRAM]) { + gl_info->ps_nv_version = PS_VERSION_20; + } + if (gl_info->supported[NV_LIGHT_MAX_EXPONENT]) { + glGetFloatv(GL_MAX_SHININESS_NV, &gl_info->max_shininess); + } else { + gl_info->max_shininess = 128.0; + } + if (gl_info->supported[ARB_TEXTURE_NON_POWER_OF_TWO]) { + /* If we have full NP2 texture support, disable GL_ARB_texture_rectangle because we will never use it. + * This saves a few redundant glDisable calls + */ + gl_info->supported[ARB_TEXTURE_RECTANGLE] = FALSE; + } + if(gl_info->supported[ATI_FRAGMENT_SHADER]) { + /* Disable NV_register_combiners and fragment shader if this is supported. + * generally the NV extensions are preferred over the ATI ones, and this + * extension is disabled if register_combiners and texture_shader2 are both + * supported. So we reach this place only if we have incomplete NV dxlevel 8 + * fragment processing support + */ + gl_info->supported[NV_REGISTER_COMBINERS] = FALSE; + gl_info->supported[NV_REGISTER_COMBINERS2] = FALSE; + gl_info->supported[NV_TEXTURE_SHADER] = FALSE; + gl_info->supported[NV_TEXTURE_SHADER2] = FALSE; + gl_info->supported[NV_TEXTURE_SHADER3] = FALSE; + } + if(gl_info->supported[NV_HALF_FLOAT]) { + /* GL_ARB_half_float_vertex is a subset of GL_NV_half_float */ + gl_info->supported[ARB_HALF_FLOAT_VERTEX] = TRUE; + } + if(gl_info->supported[ARB_POINT_SPRITE]) { + gl_info->max_point_sprite_units = gl_info->max_textures; + } else { + gl_info->max_point_sprite_units = 0; } - TRACE_(d3d_caps)("Max vertex samplers: %u.\n", gl_info->max_vertex_samplers); - TRACE_(d3d_caps)("Max combined samplers: %u.\n", gl_info->max_combined_samplers); - } - if (gl_info->supported[ARB_VERTEX_BLEND]) - { - glGetIntegerv(GL_MAX_VERTEX_UNITS_ARB, &gl_max); - gl_info->max_blends = gl_max; - TRACE_(d3d_caps)("Max blends: %u.\n", gl_info->max_blends); - } - if (gl_info->supported[EXT_TEXTURE3D]) - { - glGetIntegerv(GL_MAX_3D_TEXTURE_SIZE_EXT, &gl_max); - gl_info->max_texture3d_size = gl_max; - TRACE_(d3d_caps)("Max texture3D size: %d.\n", gl_info->max_texture3d_size); - } - if (gl_info->supported[EXT_TEXTURE_FILTER_ANISOTROPIC]) - { - glGetIntegerv(GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT, &gl_max); - gl_info->max_anisotropy = gl_max; - TRACE_(d3d_caps)("Max anisotropy: %d.\n", gl_info->max_anisotropy); - } - if (gl_info->supported[ARB_FRAGMENT_PROGRAM]) - { - gl_info->ps_arb_version = PS_VERSION_11; - GL_EXTCALL(glGetProgramivARB(GL_FRAGMENT_PROGRAM_ARB, GL_MAX_PROGRAM_ENV_PARAMETERS_ARB, &gl_max)); - gl_info->ps_arb_constantsF = gl_max; - TRACE_(d3d_caps)("Max ARB_FRAGMENT_PROGRAM float constants: %d.\n", gl_info->ps_arb_constantsF); - GL_EXTCALL(glGetProgramivARB(GL_FRAGMENT_PROGRAM_ARB, GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB, &gl_max)); - gl_info->ps_arb_max_temps = gl_max; - TRACE_(d3d_caps)("Max ARB_FRAGMENT_PROGRAM native temporaries: %d.\n", gl_info->ps_arb_max_temps); - GL_EXTCALL(glGetProgramivARB(GL_FRAGMENT_PROGRAM_ARB, GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB, &gl_max)); - gl_info->ps_arb_max_instructions = gl_max; - TRACE_(d3d_caps)("Max ARB_FRAGMENT_PROGRAM native instructions: %d.\n", gl_info->ps_arb_max_instructions); - } - if (gl_info->supported[ARB_VERTEX_PROGRAM]) - { - gl_info->vs_arb_version = VS_VERSION_11; - GL_EXTCALL(glGetProgramivARB(GL_VERTEX_PROGRAM_ARB, GL_MAX_PROGRAM_ENV_PARAMETERS_ARB, &gl_max)); - gl_info->vs_arb_constantsF = gl_max; - TRACE_(d3d_caps)("Max ARB_VERTEX_PROGRAM float constants: %d.\n", gl_info->vs_arb_constantsF); - GL_EXTCALL(glGetProgramivARB(GL_VERTEX_PROGRAM_ARB, GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB, &gl_max)); - gl_info->vs_arb_max_temps = gl_max; - TRACE_(d3d_caps)("Max ARB_VERTEX_PROGRAM native temporaries: %d.\n", gl_info->vs_arb_max_temps); - GL_EXTCALL(glGetProgramivARB(GL_VERTEX_PROGRAM_ARB, GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB, &gl_max)); - gl_info->vs_arb_max_instructions = gl_max; - TRACE_(d3d_caps)("Max ARB_VERTEX_PROGRAM native instructions: %d.\n", gl_info->vs_arb_max_instructions); - - if (test_arb_vs_offset_limit(gl_info)) gl_info->quirks |= WINED3D_QUIRK_ARB_VS_OFFSET_LIMIT; - } - if (gl_info->supported[ARB_VERTEX_SHADER]) - { - glGetIntegerv(GL_MAX_VERTEX_UNIFORM_COMPONENTS_ARB, &gl_max); - gl_info->vs_glsl_constantsF = gl_max / 4; - TRACE_(d3d_caps)("Max ARB_VERTEX_SHADER float constants: %u.\n", gl_info->vs_glsl_constantsF); - } - if (gl_info->supported[ARB_FRAGMENT_SHADER]) - { - glGetIntegerv(GL_MAX_FRAGMENT_UNIFORM_COMPONENTS_ARB, &gl_max); - gl_info->ps_glsl_constantsF = gl_max / 4; - TRACE_(d3d_caps)("Max ARB_FRAGMENT_SHADER float constants: %u.\n", gl_info->ps_glsl_constantsF); - glGetIntegerv(GL_MAX_VARYING_FLOATS_ARB, &gl_max); - gl_info->max_glsl_varyings = gl_max; - TRACE_(d3d_caps)("Max GLSL varyings: %u (%u 4 component varyings).\n", gl_max, gl_max / 4); - } - if (gl_info->supported[EXT_VERTEX_SHADER]) - { - gl_info->vs_ati_version = VS_VERSION_11; - } - if (gl_info->supported[NV_VERTEX_PROGRAM3]) - { - gl_info->vs_nv_version = VS_VERSION_30; - } - else if (gl_info->supported[NV_VERTEX_PROGRAM2]) - { - gl_info->vs_nv_version = VS_VERSION_20; - } - else if (gl_info->supported[NV_VERTEX_PROGRAM1_1]) - { - gl_info->vs_nv_version = VS_VERSION_11; - } - else if (gl_info->supported[NV_VERTEX_PROGRAM]) - { - gl_info->vs_nv_version = VS_VERSION_10; - } - if (gl_info->supported[NV_FRAGMENT_PROGRAM2]) - { - gl_info->ps_nv_version = PS_VERSION_30; - } - else if (gl_info->supported[NV_FRAGMENT_PROGRAM]) - { - gl_info->ps_nv_version = PS_VERSION_20; - } - if (gl_info->supported[NV_LIGHT_MAX_EXPONENT]) - { - glGetFloatv(GL_MAX_SHININESS_NV, &gl_info->max_shininess); - } - else - { - gl_info->max_shininess = 128.0f; - } - if (gl_info->supported[ARB_TEXTURE_NON_POWER_OF_TWO]) - { - /* If we have full NP2 texture support, disable - * GL_ARB_texture_rectangle because we will never use it. - * This saves a few redundant glDisable calls. */ - gl_info->supported[ARB_TEXTURE_RECTANGLE] = FALSE; - } - if (gl_info->supported[ATI_FRAGMENT_SHADER]) - { - /* Disable NV_register_combiners and fragment shader if this is supported. - * generally the NV extensions are preferred over the ATI ones, and this - * extension is disabled if register_combiners and texture_shader2 are both - * supported. So we reach this place only if we have incomplete NV dxlevel 8 - * fragment processing support. */ - gl_info->supported[NV_REGISTER_COMBINERS] = FALSE; - gl_info->supported[NV_REGISTER_COMBINERS2] = FALSE; - gl_info->supported[NV_TEXTURE_SHADER] = FALSE; - gl_info->supported[NV_TEXTURE_SHADER2] = FALSE; - gl_info->supported[NV_TEXTURE_SHADER3] = FALSE; - } - if (gl_info->supported[NV_HALF_FLOAT]) - { - /* GL_ARB_half_float_vertex is a subset of GL_NV_half_float. */ - gl_info->supported[ARB_HALF_FLOAT_VERTEX] = TRUE; - } - if (gl_info->supported[ARB_POINT_SPRITE]) - { - gl_info->max_point_sprite_units = gl_info->max_textures; - } - else - { - gl_info->max_point_sprite_units = 0; } - checkGLcall("extension detection"); + checkGLcall("extension detection\n"); /* In some cases the number of texture stages can be larger than the number * of samplers. The GF4 for example can use only 2 samplers (no fragment @@ -1593,128 +1089,118 @@ static BOOL IWineD3DImpl_FillGLCaps(struct wined3d_gl_info *gl_info) */ if(WINE_D3D9_CAPABLE(gl_info) && (gl_info->vs_nv_version == VS_VERSION_30)) { /* Geforce 200 - highend */ - if (strstr(gl_renderer, "GTX 280") - || strstr(gl_renderer, "GTX 285") - || strstr(gl_renderer, "GTX 295")) + if(strstr(gl_info->gl_renderer, "GTX 280") || + strstr(gl_info->gl_renderer, "GTX 285") || + strstr(gl_info->gl_renderer, "GTX 295")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_GTX280; vidmem = 1024; } /* Geforce 200 - midend high */ - else if (strstr(gl_renderer, "GTX 275")) - { + if(strstr(gl_info->gl_renderer, "GTX 275")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_GTX275; vidmem = 896; } /* Geforce 200 - midend */ - else if (strstr(gl_renderer, "GTX 260")) - { + if(strstr(gl_info->gl_renderer, "GTX 260")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_GTX260; vidmem = 1024; } /* Geforce9 - highend / Geforce 200 - midend (GTS 150/250 are based on the same core) */ - else if (strstr(gl_renderer, "9800") - || strstr(gl_renderer, "GTS 150") - || strstr(gl_renderer, "GTS 250")) + else if(strstr(gl_info->gl_renderer, "9800") || + strstr(gl_info->gl_renderer, "GTS 150") || + strstr(gl_info->gl_renderer, "GTS 250")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_9800GT; vidmem = 512; } /* Geforce9 - midend */ - else if (strstr(gl_renderer, "9600")) - { + else if(strstr(gl_info->gl_renderer, "9600")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_9600GT; vidmem = 384; /* The 9600GSO has 384MB, the 9600GT has 512-1024MB */ } /* Geforce9 - midend low / Geforce 200 - low*/ - else if (strstr(gl_renderer, "9500") - || strstr(gl_renderer, "GT 120") - || strstr(gl_renderer, "GT 130")) + else if(strstr(gl_info->gl_renderer, "9500") || + strstr(gl_info->gl_renderer, "GT 120") || + strstr(gl_info->gl_renderer, "GT 130")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_9500GT; vidmem = 256; /* The 9500GT has 256-1024MB */ } /* Geforce9 - lowend */ - else if (strstr(gl_renderer, "9400")) - { + else if(strstr(gl_info->gl_renderer, "9400")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_9400GT; vidmem = 256; /* The 9400GT has 256-1024MB */ } /* Geforce9 - lowend low */ - else if (strstr(gl_renderer, "9100") - || strstr(gl_renderer, "9200") - || strstr(gl_renderer, "9300") - || strstr(gl_renderer, "G 100")) + else if(strstr(gl_info->gl_renderer, "9100") || + strstr(gl_info->gl_renderer, "9200") || + strstr(gl_info->gl_renderer, "9300") || + strstr(gl_info->gl_renderer, "G 100")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_9200; vidmem = 256; /* The 9100-9300 cards have 256MB */ } /* Geforce8 - highend */ - else if (strstr(gl_renderer, "8800")) - { + else if (strstr(gl_info->gl_renderer, "8800")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_8800GTS; vidmem = 320; /* The 8800GTS uses 320MB, a 8800GTX can have 768MB */ } /* Geforce8 - midend mobile */ - else if (strstr(gl_renderer, "8600 M")) - { + else if(strstr(gl_info->gl_renderer, "8600 M")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_8600MGT; vidmem = 512; } /* Geforce8 - midend */ - else if (strstr(gl_renderer, "8600") - || strstr(gl_renderer, "8700")) + else if(strstr(gl_info->gl_renderer, "8600") || + strstr(gl_info->gl_renderer, "8700")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_8600GT; vidmem = 256; } /* Geforce8 - lowend */ - else if (strstr(gl_renderer, "8300") - || strstr(gl_renderer, "8400") - || strstr(gl_renderer, "8500")) + else if(strstr(gl_info->gl_renderer, "8300") || + strstr(gl_info->gl_renderer, "8400") || + strstr(gl_info->gl_renderer, "8500")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_8300GS; vidmem = 128; /* 128-256MB for a 8300, 256-512MB for a 8400 */ } /* Geforce7 - highend */ - else if (strstr(gl_renderer, "7800") - || strstr(gl_renderer, "7900") - || strstr(gl_renderer, "7950") - || strstr(gl_renderer, "Quadro FX 4") - || strstr(gl_renderer, "Quadro FX 5")) + else if(strstr(gl_info->gl_renderer, "7800") || + strstr(gl_info->gl_renderer, "7900") || + strstr(gl_info->gl_renderer, "7950") || + strstr(gl_info->gl_renderer, "Quadro FX 4") || + strstr(gl_info->gl_renderer, "Quadro FX 5")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_7800GT; vidmem = 256; /* A 7800GT uses 256MB while highend 7900 cards can use 512MB */ } /* Geforce7 midend */ - else if (strstr(gl_renderer, "7600") - || strstr(gl_renderer, "7700")) - { + else if(strstr(gl_info->gl_renderer, "7600") || + strstr(gl_info->gl_renderer, "7700")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_7600; vidmem = 256; /* The 7600 uses 256-512MB */ /* Geforce7 lower medium */ - } - else if (strstr(gl_renderer, "7400")) - { + } else if(strstr(gl_info->gl_renderer, "7400")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_7400; vidmem = 256; /* The 7400 uses 256-512MB */ } /* Geforce7 lowend */ - else if (strstr(gl_renderer, "7300")) - { + else if(strstr(gl_info->gl_renderer, "7300")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_7300; vidmem = 256; /* Mac Pros with this card have 256 MB */ } /* Geforce6 highend */ - else if (strstr(gl_renderer, "6800")) + else if(strstr(gl_info->gl_renderer, "6800")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_6800; vidmem = 128; /* The 6800 uses 128-256MB, the 7600 uses 256-512MB */ } /* Geforce6 - midend */ - else if (strstr(gl_renderer, "6600") - || strstr(gl_renderer, "6610") - || strstr(gl_renderer, "6700")) + else if(strstr(gl_info->gl_renderer, "6600") || + strstr(gl_info->gl_renderer, "6610") || + strstr(gl_info->gl_renderer, "6700")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE_6600GT; vidmem = 128; /* A 6600GT has 128-256MB */ @@ -1726,19 +1212,19 @@ static BOOL IWineD3DImpl_FillGLCaps(struct wined3d_gl_info *gl_info) } } else if(WINE_D3D9_CAPABLE(gl_info)) { /* GeforceFX - highend */ - if (strstr(gl_renderer, "5800") - || strstr(gl_renderer, "5900") - || strstr(gl_renderer, "5950") - || strstr(gl_renderer, "Quadro FX")) + if (strstr(gl_info->gl_renderer, "5800") || + strstr(gl_info->gl_renderer, "5900") || + strstr(gl_info->gl_renderer, "5950") || + strstr(gl_info->gl_renderer, "Quadro FX")) { gl_info->gl_card = CARD_NVIDIA_GEFORCEFX_5800; vidmem = 256; /* 5800-5900 cards use 256MB */ } /* GeforceFX - midend */ - else if (strstr(gl_renderer, "5600") - || strstr(gl_renderer, "5650") - || strstr(gl_renderer, "5700") - || strstr(gl_renderer, "5750")) + else if(strstr(gl_info->gl_renderer, "5600") || + strstr(gl_info->gl_renderer, "5650") || + strstr(gl_info->gl_renderer, "5700") || + strstr(gl_info->gl_renderer, "5750")) { gl_info->gl_card = CARD_NVIDIA_GEFORCEFX_5600; vidmem = 128; /* A 5600 uses 128-256MB */ @@ -1749,45 +1235,37 @@ static BOOL IWineD3DImpl_FillGLCaps(struct wined3d_gl_info *gl_info) vidmem = 64; /* Normal FX5200 cards use 64-256MB; laptop (non-standard) can have less */ } } else if(WINE_D3D8_CAPABLE(gl_info)) { - if (strstr(gl_renderer, "GeForce4 Ti") || strstr(gl_renderer, "Quadro4")) - { + if (strstr(gl_info->gl_renderer, "GeForce4 Ti") || strstr(gl_info->gl_renderer, "Quadro4")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE4_TI4200; /* Geforce4 Ti4200/Ti4400/Ti4600/Ti4800, Quadro4 */ vidmem = 64; /* Geforce4 Ti cards have 64-128MB */ } - else - { + else { gl_info->gl_card = CARD_NVIDIA_GEFORCE3; /* Geforce3 standard/Ti200/Ti500, Quadro DCC */ vidmem = 64; /* Geforce3 cards have 64-128MB */ } } else if(WINE_D3D7_CAPABLE(gl_info)) { - if (strstr(gl_renderer, "GeForce4 MX")) - { + if (strstr(gl_info->gl_renderer, "GeForce4 MX")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE4_MX; /* MX420/MX440/MX460/MX4000 */ vidmem = 64; /* Most Geforce4MX GPUs have at least 64MB of memory, some early models had 32MB but most have 64MB or even 128MB */ } - else if(strstr(gl_renderer, "GeForce2 MX") || strstr(gl_renderer, "Quadro2 MXR")) - { + else if(strstr(gl_info->gl_renderer, "GeForce2 MX") || strstr(gl_info->gl_renderer, "Quadro2 MXR")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE2_MX; /* Geforce2 standard/MX100/MX200/MX400, Quadro2 MXR */ vidmem = 32; /* Geforce2MX GPUs have 32-64MB of video memory */ } - else if(strstr(gl_renderer, "GeForce2") || strstr(gl_renderer, "Quadro2")) - { + else if(strstr(gl_info->gl_renderer, "GeForce2") || strstr(gl_info->gl_renderer, "Quadro2")) { gl_info->gl_card = CARD_NVIDIA_GEFORCE2; /* Geforce2 GTS/Pro/Ti/Ultra, Quadro2 */ vidmem = 32; /* Geforce2 GPUs have 32-64MB of video memory */ } - else - { + else { gl_info->gl_card = CARD_NVIDIA_GEFORCE; /* Geforce 256/DDR, Quadro */ vidmem = 32; /* Most Geforce1 cards have 32MB, there are also some rare 16 and 64MB (Dell) models */ } } else { - if (strstr(gl_renderer, "TNT2")) - { + if (strstr(gl_info->gl_renderer, "TNT2")) { gl_info->gl_card = CARD_NVIDIA_RIVA_TNT2; /* Riva TNT2 standard/M64/Pro/Ultra */ vidmem = 32; /* Most TNT2 boards have 32MB, though there are 16MB boards too */ } - else - { + else { gl_info->gl_card = CARD_NVIDIA_RIVA_TNT; /* Riva TNT, Vanta */ vidmem = 16; /* Most TNT boards have 16MB, some rare models have 8MB */ } @@ -1801,97 +1279,97 @@ static BOOL IWineD3DImpl_FillGLCaps(struct wined3d_gl_info *gl_info) */ if(WINE_D3D9_CAPABLE(gl_info)) { /* Radeon R7xx HD4800 - highend */ - if (strstr(gl_renderer, "HD 4800") /* Radeon RV7xx HD48xx generic renderer string */ - || strstr(gl_renderer, "HD 4830") /* Radeon RV770 */ - || strstr(gl_renderer, "HD 4850") /* Radeon RV770 */ - || strstr(gl_renderer, "HD 4870") /* Radeon RV770 */ - || strstr(gl_renderer, "HD 4890")) /* Radeon RV790 */ + if (strstr(gl_info->gl_renderer, "HD 4800") || /* Radeon RV7xx HD48xx generic renderer string */ + strstr(gl_info->gl_renderer, "HD 4830") || /* Radeon RV770 */ + strstr(gl_info->gl_renderer, "HD 4850") || /* Radeon RV770 */ + strstr(gl_info->gl_renderer, "HD 4870") || /* Radeon RV770 */ + strstr(gl_info->gl_renderer, "HD 4890")) /* Radeon RV790 */ { gl_info->gl_card = CARD_ATI_RADEON_HD4800; vidmem = 512; /* note: HD4890 cards use 1024MB */ } /* Radeon R740 HD4700 - midend */ - else if (strstr(gl_renderer, "HD 4700") /* Radeon RV770 */ - || strstr(gl_renderer, "HD 4770")) /* Radeon RV740 */ + else if (strstr(gl_info->gl_renderer, "HD 4700") || /* Radeon RV770 */ + strstr(gl_info->gl_renderer, "HD 4770")) /* Radeon RV740 */ { gl_info->gl_card = CARD_ATI_RADEON_HD4700; vidmem = 512; } /* Radeon R730 HD4600 - midend */ - else if (strstr(gl_renderer, "HD 4600") /* Radeon RV730 */ - || strstr(gl_renderer, "HD 4650") /* Radeon RV730 */ - || strstr(gl_renderer, "HD 4670")) /* Radeon RV730 */ + else if (strstr(gl_info->gl_renderer, "HD 4600") || /* Radeon RV730 */ + strstr(gl_info->gl_renderer, "HD 4650") || /* Radeon RV730 */ + strstr(gl_info->gl_renderer, "HD 4670")) /* Radeon RV730 */ { gl_info->gl_card = CARD_ATI_RADEON_HD4600; vidmem = 512; } /* Radeon R710 HD4500/HD4350 - lowend */ - else if (strstr(gl_renderer, "HD 4350") /* Radeon RV710 */ - || strstr(gl_renderer, "HD 4550")) /* Radeon RV710 */ + else if (strstr(gl_info->gl_renderer, "HD 4350") || /* Radeon RV710 */ + strstr(gl_info->gl_renderer, "HD 4550")) /* Radeon RV710 */ { gl_info->gl_card = CARD_ATI_RADEON_HD4350; vidmem = 256; } /* Radeon R6xx HD2900/HD3800 - highend */ - else if (strstr(gl_renderer, "HD 2900") - || strstr(gl_renderer, "HD 3870") - || strstr(gl_renderer, "HD 3850")) + else if (strstr(gl_info->gl_renderer, "HD 2900") || + strstr(gl_info->gl_renderer, "HD 3870") || + strstr(gl_info->gl_renderer, "HD 3850")) { gl_info->gl_card = CARD_ATI_RADEON_HD2900; vidmem = 512; /* HD2900/HD3800 uses 256-1024MB */ } /* Radeon R6xx HD2600/HD3600 - midend; HD3830 is China-only midend */ - else if (strstr(gl_renderer, "HD 2600") - || strstr(gl_renderer, "HD 3830") - || strstr(gl_renderer, "HD 3690") - || strstr(gl_renderer, "HD 3650")) + else if (strstr(gl_info->gl_renderer, "HD 2600") || + strstr(gl_info->gl_renderer, "HD 3830") || + strstr(gl_info->gl_renderer, "HD 3690") || + strstr(gl_info->gl_renderer, "HD 3650")) { gl_info->gl_card = CARD_ATI_RADEON_HD2600; vidmem = 256; /* HD2600/HD3600 uses 256-512MB */ } /* Radeon R6xx HD2300/HD2400/HD3400 - lowend */ - else if (strstr(gl_renderer, "HD 2300") - || strstr(gl_renderer, "HD 2400") - || strstr(gl_renderer, "HD 3470") - || strstr(gl_renderer, "HD 3450") - || strstr(gl_renderer, "HD 3430") - || strstr(gl_renderer, "HD 3400")) + else if (strstr(gl_info->gl_renderer, "HD 2300") || + strstr(gl_info->gl_renderer, "HD 2400") || + strstr(gl_info->gl_renderer, "HD 3470") || + strstr(gl_info->gl_renderer, "HD 3450") || + strstr(gl_info->gl_renderer, "HD 3430") || + strstr(gl_info->gl_renderer, "HD 3400")) { gl_info->gl_card = CARD_ATI_RADEON_HD2300; vidmem = 128; /* HD2300 uses at least 128MB, HD2400 uses 256MB */ } /* Radeon R6xx/R7xx integrated */ - else if (strstr(gl_renderer, "HD 3100") - || strstr(gl_renderer, "HD 3200") - || strstr(gl_renderer, "HD 3300")) + else if (strstr(gl_info->gl_renderer, "HD 3100") || + strstr(gl_info->gl_renderer, "HD 3200") || + strstr(gl_info->gl_renderer, "HD 3300")) { gl_info->gl_card = CARD_ATI_RADEON_HD3200; vidmem = 128; /* 128MB */ } /* Radeon R5xx */ - else if (strstr(gl_renderer, "X1600") - || strstr(gl_renderer, "X1650") - || strstr(gl_renderer, "X1800") - || strstr(gl_renderer, "X1900") - || strstr(gl_renderer, "X1950")) + else if (strstr(gl_info->gl_renderer, "X1600") || + strstr(gl_info->gl_renderer, "X1650") || + strstr(gl_info->gl_renderer, "X1800") || + strstr(gl_info->gl_renderer, "X1900") || + strstr(gl_info->gl_renderer, "X1950")) { gl_info->gl_card = CARD_ATI_RADEON_X1600; vidmem = 128; /* X1600 uses 128-256MB, >=X1800 uses 256MB */ } /* Radeon R4xx + X1300/X1400/X1450/X1550/X2300 (lowend R5xx) */ - else if(strstr(gl_renderer, "X700") - || strstr(gl_renderer, "X800") - || strstr(gl_renderer, "X850") - || strstr(gl_renderer, "X1300") - || strstr(gl_renderer, "X1400") - || strstr(gl_renderer, "X1450") - || strstr(gl_renderer, "X1550")) + else if(strstr(gl_info->gl_renderer, "X700") || + strstr(gl_info->gl_renderer, "X800") || + strstr(gl_info->gl_renderer, "X850") || + strstr(gl_info->gl_renderer, "X1300") || + strstr(gl_info->gl_renderer, "X1400") || + strstr(gl_info->gl_renderer, "X1450") || + strstr(gl_info->gl_renderer, "X1550")) { gl_info->gl_card = CARD_ATI_RADEON_X700; vidmem = 128; /* x700/x8*0 use 128-256MB, >=x1300 128-512MB */ } /* Radeon Xpress Series - onboard, DX9b, Shader 2.0, 300-400MHz */ - else if(strstr(gl_renderer, "Radeon Xpress")) + else if(strstr(gl_info->gl_renderer, "Radeon Xpress")) { gl_info->gl_card = CARD_ATI_RADEON_XPRESS_200M; vidmem = 64; /* Shared RAM, BIOS configurable, 64-256M */ @@ -1913,36 +1391,20 @@ static BOOL IWineD3DImpl_FillGLCaps(struct wined3d_gl_info *gl_info) } break; case VENDOR_INTEL: - if(strstr(gl_renderer, "X3100")) - { - /* MacOS calls the card GMA X3100, Google findings also suggest the name GM965 */ - gl_info->gl_card = CARD_INTEL_X3100; - vidmem = 128; - } - else if (strstr(gl_renderer, "GMA 950") || strstr(gl_renderer, "945GM")) - { + if (strstr(gl_info->gl_renderer, "GMA 950") || + strstr(gl_info->gl_renderer, "945GM")) { /* MacOS calls the card GMA 950, but everywhere else the PCI ID is named 945GM */ gl_info->gl_card = CARD_INTEL_I945GM; vidmem = 64; - } - else if (strstr(gl_renderer, "915GM")) - { + } else if (strstr(gl_info->gl_renderer, "915GM")) { gl_info->gl_card = CARD_INTEL_I915GM; - } - else if (strstr(gl_renderer, "915G")) - { + } else if (strstr(gl_info->gl_renderer, "915G")) { gl_info->gl_card = CARD_INTEL_I915G; - } - else if (strstr(gl_renderer, "865G")) - { + } else if (strstr(gl_info->gl_renderer, "865G")) { gl_info->gl_card = CARD_INTEL_I865G; - } - else if (strstr(gl_renderer, "855G")) - { + } else if (strstr(gl_info->gl_renderer, "855G")) { gl_info->gl_card = CARD_INTEL_I855G; - } - else if (strstr(gl_renderer, "830G")) - { + } else if (strstr(gl_info->gl_renderer, "830G")) { gl_info->gl_card = CARD_INTEL_I830G; } else { gl_info->gl_card = CARD_INTEL_I915G; @@ -2030,6 +1492,7 @@ static BOOL IWineD3DImpl_FillGLCaps(struct wined3d_gl_info *gl_info) while (*WGL_Extensions != 0x00) { const char *Start; char ThisExtn[256]; + size_t len; while (isspace(*WGL_Extensions)) WGL_Extensions++; Start = WGL_Extensions; @@ -2062,11 +1525,7 @@ static BOOL IWineD3DImpl_FillGLCaps(struct wined3d_gl_info *gl_info) } LEAVE_GL(); - fixup_extensions(gl_info, gl_renderer); - add_gl_compat_wrappers(gl_info); - - HeapFree(GetProcessHeap(), 0, gl_renderer); - return TRUE; + return return_value; } /********************************************************** @@ -2113,39 +1572,40 @@ static UINT WINAPI IWineD3DImpl_GetAdapterModeCount(IWineD3D *iface, UINT Ad /* TODO: Store modes per adapter and read it from the adapter structure */ if (Adapter == 0) { /* Display */ - unsigned int i = 0; - unsigned int j = 0; - DEVMODEW mode; - - memset(&mode, 0, sizeof(mode)); - mode.dmSize = sizeof(mode); - - while (EnumDisplaySettingsExW(NULL, j, &mode, 0)) - { - ++j; - switch (Format) - { - case WINED3DFMT_UNKNOWN: - /* This is for D3D8, do not enumerate P8 here */ - if (mode.dmBitsPerPel == 32 || mode.dmBitsPerPel == 16) ++i; - break; - - case WINED3DFMT_X8R8G8B8: - if (mode.dmBitsPerPel == 32) ++i; - break; - - case WINED3DFMT_R5G6B5: - if (mode.dmBitsPerPel == 16) ++i; - break; + int i = 0; + int j = 0; - case WINED3DFMT_P8: - if (mode.dmBitsPerPel == 8) ++i; - break; + if (!DEBUG_SINGLE_MODE) { + DEVMODEW DevModeW; - default: - /* Skip other modes as they do not match the requested format */ - break; + ZeroMemory(&DevModeW, sizeof(DevModeW)); + DevModeW.dmSize = sizeof(DevModeW); + while (EnumDisplaySettingsExW(NULL, j, &DevModeW, 0)) { + j++; + switch (Format) + { + case WINED3DFMT_UNKNOWN: + /* This is for D3D8, do not enumerate P8 here */ + if (DevModeW.dmBitsPerPel == 32 || + DevModeW.dmBitsPerPel == 16) i++; + break; + case WINED3DFMT_X8R8G8B8: + if (DevModeW.dmBitsPerPel == 32) i++; + break; + case WINED3DFMT_R5G6B5: + if (DevModeW.dmBitsPerPel == 16) i++; + break; + case WINED3DFMT_P8: + if (DevModeW.dmBitsPerPel == 8) i++; + break; + default: + /* Skip other modes as they do not match the requested format */ + break; + } } + } else { + i = 1; + j = 1; } TRACE_(d3d_caps)("(%p}->(Adapter: %d) => %d (out of %d)\n", This, Adapter, i, j); @@ -2169,8 +1629,7 @@ static HRESULT WINAPI IWineD3DImpl_EnumAdapterModes(IWineD3D *iface, UINT Adapte } /* TODO: Store modes per adapter and read it from the adapter structure */ - if (Adapter == 0) - { + if (Adapter == 0 && !DEBUG_SINGLE_MODE) { /* Display */ DEVMODEW DevModeW; int ModeIdx = 0; UINT i = 0; @@ -2234,9 +1693,14 @@ static HRESULT WINAPI IWineD3DImpl_EnumAdapterModes(IWineD3D *iface, UINT Adapte pMode->RefreshRate, pMode->Format, debug_d3dformat(pMode->Format), DevModeW.dmBitsPerPel); - } - else - { + } else if (DEBUG_SINGLE_MODE) { + /* Return one setting of the format requested */ + if (Mode > 0) return WINED3DERR_INVALIDCALL; + pMode->Width = 800; + pMode->Height = 600; + pMode->RefreshRate = 60; + pMode->Format = (Format == WINED3DFMT_UNKNOWN) ? WINED3DFMT_X8R8G8B8 : Format; + } else { FIXME_(d3d_caps)("Adapter not primary display\n"); } @@ -2284,7 +1748,6 @@ static HRESULT WINAPI IWineD3DImpl_GetAdapterDisplayMode(IWineD3D *iface, UINT A static HRESULT WINAPI IWineD3DImpl_GetAdapterIdentifier(IWineD3D *iface, UINT Adapter, DWORD Flags, WINED3DADAPTER_IDENTIFIER* pIdentifier) { IWineD3DImpl *This = (IWineD3DImpl *)iface; - size_t len; TRACE_(d3d_caps)("(%p}->(Adapter: %d, Flags: %x, pId=%p)\n", This, Adapter, Flags, pIdentifier); @@ -2294,70 +1757,44 @@ static HRESULT WINAPI IWineD3DImpl_GetAdapterIdentifier(IWineD3D *iface, UINT Ad /* Return the information requested */ TRACE_(d3d_caps)("device/Vendor Name and Version detection using FillGLCaps\n"); - - if (pIdentifier->driver_size) - { - len = min(strlen(This->adapters[Adapter].driver), pIdentifier->driver_size - 1); - memcpy(pIdentifier->driver, This->adapters[Adapter].driver, len); - pIdentifier->driver[len] = '\0'; - } - - if (pIdentifier->description_size) - { - const char *description; - - if (This->adapters[Adapter].gl_info.driver_description) - description = This->adapters[Adapter].gl_info.driver_description; - else - description = This->adapters[Adapter].description; - - len = min(strlen(description), pIdentifier->description_size - 1); - memcpy(pIdentifier->description, description, len); - pIdentifier->description[len] = '\0'; - } - - /* Note that d3d8 doesn't supply a device name. */ - if (pIdentifier->device_name_size) - { - static const char *device_name = "\\\\.\\DISPLAY1"; /* FIXME: May depend on desktop? */ - - len = strlen(device_name); - if (len >= pIdentifier->device_name_size) - { - ERR("Device name size too small.\n"); - return WINED3DERR_INVALIDCALL; - } - - memcpy(pIdentifier->device_name, device_name, len); - pIdentifier->device_name[len] = '\0'; - } - - pIdentifier->driver_version.u.HighPart = This->adapters[Adapter].gl_info.driver_version_hipart; - pIdentifier->driver_version.u.LowPart = This->adapters[Adapter].gl_info.driver_version; - pIdentifier->vendor_id = This->adapters[Adapter].gl_info.gl_vendor; - pIdentifier->device_id = This->adapters[Adapter].gl_info.gl_card; - pIdentifier->subsystem_id = 0; - pIdentifier->revision = 0; - memcpy(&pIdentifier->device_identifier, &IID_D3DDEVICE_D3DUID, sizeof(pIdentifier->device_identifier)); + strcpy(pIdentifier->Driver, This->adapters[Adapter].driver); + if(This->adapters[Adapter].gl_info.driver_description) + strcpy(pIdentifier->Description, This->adapters[Adapter].gl_info.driver_description); + else /* Copy default description "Direct3D HAL" */ + strcpy(pIdentifier->Description, This->adapters[Adapter].description); + + /* Note dx8 doesn't supply a DeviceName */ + if (NULL != pIdentifier->DeviceName) strcpy(pIdentifier->DeviceName, "\\\\.\\DISPLAY1"); /* FIXME: May depend on desktop? */ + pIdentifier->DriverVersion->u.HighPart = This->adapters[Adapter].gl_info.driver_version_hipart; + pIdentifier->DriverVersion->u.LowPart = This->adapters[Adapter].gl_info.driver_version; + *(pIdentifier->VendorId) = This->adapters[Adapter].gl_info.gl_vendor; + *(pIdentifier->DeviceId) = This->adapters[Adapter].gl_info.gl_card; + *(pIdentifier->SubSysId) = 0; + *(pIdentifier->Revision) = 0; + *pIdentifier->DeviceIdentifier = IID_D3DDEVICE_D3DUID; if(wined3d_settings.pci_device_id != PCI_DEVICE_NONE) { TRACE_(d3d_caps)("Overriding pci device id with: %x\n", wined3d_settings.pci_device_id); - pIdentifier->device_id = wined3d_settings.pci_device_id; + *(pIdentifier->DeviceId) = wined3d_settings.pci_device_id; } if(wined3d_settings.pci_vendor_id != PCI_VENDOR_NONE) { TRACE_(d3d_caps)("Overriding pci vendor id with: %x\n", wined3d_settings.pci_vendor_id); - pIdentifier->vendor_id = wined3d_settings.pci_vendor_id; + *(pIdentifier->VendorId) = wined3d_settings.pci_vendor_id; } - pIdentifier->whql_level = (Flags & WINED3DENUM_NO_WHQL_LEVEL) ? 0 : 1; + if (Flags & WINED3DENUM_NO_WHQL_LEVEL) { + *(pIdentifier->WHQLLevel) = 0; + } else { + *(pIdentifier->WHQLLevel) = 1; + } return WINED3D_OK; } -static BOOL IWineD3DImpl_IsPixelFormatCompatibleWithRenderFmt(const struct wined3d_gl_info *gl_info, +static BOOL IWineD3DImpl_IsPixelFormatCompatibleWithRenderFmt(const WineD3D_GL_Info *gl_info, const WineD3D_PixelFormat *cfg, const struct GlPixelFormatDesc *format_desc) { short redSize, greenSize, blueSize, alphaSize, colorBits; @@ -2406,7 +1843,7 @@ static BOOL IWineD3DImpl_IsPixelFormatCompatibleWithRenderFmt(const struct wined return FALSE; } -static BOOL IWineD3DImpl_IsPixelFormatCompatibleWithDepthFmt(const struct wined3d_gl_info *gl_info, +static BOOL IWineD3DImpl_IsPixelFormatCompatibleWithDepthFmt(const WineD3D_GL_Info *gl_info, const WineD3D_PixelFormat *cfg, const struct GlPixelFormatDesc *format_desc) { short depthSize, stencilSize; @@ -2785,7 +2222,7 @@ static BOOL CheckRenderTargetCapability(struct WineD3DAdapter *adapter, static BOOL CheckSrgbReadCapability(struct WineD3DAdapter *adapter, const struct GlPixelFormatDesc *format_desc) { - const struct wined3d_gl_info *gl_info = &adapter->gl_info; + const WineD3D_GL_Info *gl_info = &adapter->gl_info; /* Check for supported sRGB formats (Texture loading and framebuffer) */ if(!GL_SUPPORT(EXT_TEXTURE_SRGB)) { @@ -2865,7 +2302,7 @@ static BOOL CheckWrapAndMipCapability(struct WineD3DAdapter *adapter, const stru static BOOL CheckTextureCapability(struct WineD3DAdapter *adapter, WINED3DDEVTYPE DeviceType, const struct GlPixelFormatDesc *format_desc) { - const struct wined3d_gl_info *gl_info = &adapter->gl_info; + const WineD3D_GL_Info *gl_info = &adapter->gl_info; const shader_backend_t *shader_backend; const struct fragment_pipeline *fp; @@ -3145,7 +2582,7 @@ static BOOL CheckSurfaceCapability(struct WineD3DAdapter *adapter, const struct static BOOL CheckVertexTextureCapability(struct WineD3DAdapter *adapter, const struct GlPixelFormatDesc *format_desc) { - const struct wined3d_gl_info *gl_info = &adapter->gl_info; + const WineD3D_GL_Info *gl_info = &adapter->gl_info; if (!GL_LIMITS(vertex_samplers)) { TRACE_(d3d_caps)("[FAILED]\n"); @@ -3174,7 +2611,7 @@ static HRESULT WINAPI IWineD3DImpl_CheckDeviceFormat(IWineD3D *iface, UINT Adapt WINED3DSURFTYPE SurfaceType) { IWineD3DImpl *This = (IWineD3DImpl *)iface; struct WineD3DAdapter *adapter = &This->adapters[Adapter]; - const struct wined3d_gl_info *gl_info = &adapter->gl_info; + const WineD3D_GL_Info *gl_info = &adapter->gl_info; const struct GlPixelFormatDesc *format_desc = getFormatDescEntry(CheckFormat, gl_info); const struct GlPixelFormatDesc *adapter_format_desc = getFormatDescEntry(AdapterFormat, gl_info); DWORD UsageCaps = 0; @@ -3711,7 +3148,7 @@ static const shader_backend_t *select_shader_backend(struct WineD3DAdapter *adap static const struct fragment_pipeline *select_fragment_implementation(struct WineD3DAdapter *adapter, WINED3DDEVTYPE DeviceType) { - const struct wined3d_gl_info *gl_info = &adapter->gl_info; + const WineD3D_GL_Info *gl_info = &adapter->gl_info; int vs_selected_mode; int ps_selected_mode; @@ -3731,7 +3168,7 @@ static const struct fragment_pipeline *select_fragment_implementation(struct Win static const struct blit_shader *select_blit_implementation(struct WineD3DAdapter *adapter, WINED3DDEVTYPE DeviceType) { - const struct wined3d_gl_info *gl_info = &adapter->gl_info; + const WineD3D_GL_Info *gl_info = &adapter->gl_info; int vs_selected_mode; int ps_selected_mode; @@ -3750,7 +3187,7 @@ static HRESULT WINAPI IWineD3DImpl_GetDeviceCaps(IWineD3D *iface, UINT Adapter, IWineD3DImpl *This = (IWineD3DImpl *)iface; struct WineD3DAdapter *adapter = &This->adapters[Adapter]; - const struct wined3d_gl_info *gl_info = &adapter->gl_info; + const WineD3D_GL_Info *gl_info = &adapter->gl_info; int vs_selected_mode; int ps_selected_mode; struct shader_caps shader_caps; @@ -4052,14 +3489,14 @@ static HRESULT WINAPI IWineD3DImpl_GetDeviceCaps(IWineD3D *iface, UINT Adapter, pCaps->MaxTextureRepeat = 32768; pCaps->MaxTextureAspectRatio = GL_LIMITS(texture_size); - pCaps->MaxVertexW = 1.0f; + pCaps->MaxVertexW = 1.0; - pCaps->GuardBandLeft = 0.0f; - pCaps->GuardBandTop = 0.0f; - pCaps->GuardBandRight = 0.0f; - pCaps->GuardBandBottom = 0.0f; + pCaps->GuardBandLeft = 0; + pCaps->GuardBandTop = 0; + pCaps->GuardBandRight = 0; + pCaps->GuardBandBottom = 0; - pCaps->ExtentsAdjust = 0.0f; + pCaps->ExtentsAdjust = 0; pCaps->StencilCaps = WINED3DSTENCILCAPS_DECRSAT | WINED3DSTENCILCAPS_INCRSAT | @@ -4145,7 +3582,7 @@ static HRESULT WINAPI IWineD3DImpl_GetDeviceCaps(IWineD3D *iface, UINT Adapter, if(ps_selected_mode == SHADER_NONE) { TRACE_(d3d_caps)("Pixel shader disabled in config, reporting version 0.0\n"); pCaps->PixelShaderVersion = WINED3DPS_VERSION(0,0); - pCaps->PixelShader1xMaxValue = 0.0f; + pCaps->PixelShader1xMaxValue = 0.0; } else { pCaps->PixelShaderVersion = shader_caps.PixelShaderVersion; pCaps->PixelShader1xMaxValue = shader_caps.PixelShader1xMaxValue; @@ -4363,101 +3800,490 @@ static HRESULT WINAPI IWineD3DImpl_CreateDevice(IWineD3D *iface, UINT Adapter, list_init(&object->resources); list_init(&object->shaders); - if(This->dxVersion == 7) { - object->surface_alignment = DDRAW_PITCH_ALIGNMENT; + if(This->dxVersion == 7) { + object->surface_alignment = DDRAW_PITCH_ALIGNMENT; + } else { + object->surface_alignment = D3D8_PITCH_ALIGNMENT; + } + object->posFixup[0] = 1.0; /* This is needed to get the x coord unmodified through a MAD */ + + /* Set the state up as invalid until the device is fully created */ + object->state = WINED3DERR_DRIVERINTERNALERROR; + + TRACE("(%p)->(Adptr:%d, DevType: %x, FocusHwnd: %p, BehFlags: %x, RetDevInt: %p)\n", This, Adapter, DeviceType, + hFocusWindow, BehaviourFlags, ppReturnedDeviceInterface); + + /* Save the creation parameters */ + object->createParms.AdapterOrdinal = Adapter; + object->createParms.DeviceType = DeviceType; + object->createParms.hFocusWindow = hFocusWindow; + object->createParms.BehaviorFlags = BehaviourFlags; + + /* Initialize other useful values */ + object->adapterNo = Adapter; + object->devType = DeviceType; + + select_shader_mode(&adapter->gl_info, DeviceType, + &object->ps_selected_mode, &object->vs_selected_mode); + object->shader_backend = select_shader_backend(adapter, DeviceType); + + memset(&shader_caps, 0, sizeof(shader_caps)); + object->shader_backend->shader_get_caps(DeviceType, &adapter->gl_info, &shader_caps); + object->d3d_vshader_constantF = shader_caps.MaxVertexShaderConst; + object->d3d_pshader_constantF = shader_caps.MaxPixelShaderConst; + object->vs_clipping = shader_caps.VSClipping; + + memset(&ffp_caps, 0, sizeof(ffp_caps)); + frag_pipeline = select_fragment_implementation(adapter, DeviceType); + object->frag_pipe = frag_pipeline; + frag_pipeline->get_caps(DeviceType, &adapter->gl_info, &ffp_caps); + object->max_ffp_textures = ffp_caps.MaxSimultaneousTextures; + object->max_ffp_texture_stages = ffp_caps.MaxTextureBlendStages; + hr = compile_state_table(object->StateTable, object->multistate_funcs, &adapter->gl_info, + ffp_vertexstate_template, frag_pipeline, misc_state_template); + + if (FAILED(hr)) { + IWineD3D_Release(object->wineD3D); + HeapFree(GetProcessHeap(), 0, object); + + return hr; + } + + object->blitter = select_blit_implementation(adapter, DeviceType); + + /* set the state of the device to valid */ + object->state = WINED3D_OK; + + /* Get the initial screen setup for ddraw */ + IWineD3DImpl_GetAdapterDisplayMode(iface, Adapter, &mode); + + object->ddraw_width = mode.Width; + object->ddraw_height = mode.Height; + object->ddraw_format = mode.Format; + + for(i = 0; i < PATCHMAP_SIZE; i++) { + list_init(&object->patches[i]); + } + + IWineD3DDeviceParent_WineD3DDeviceCreated(device_parent, *ppReturnedDeviceInterface); + + return WINED3D_OK; +} + +static HRESULT WINAPI IWineD3DImpl_GetParent(IWineD3D *iface, IUnknown **pParent) { + IWineD3DImpl *This = (IWineD3DImpl *)iface; + IUnknown_AddRef(This->parent); + *pParent = This->parent; + return WINED3D_OK; +} + +ULONG WINAPI D3DCB_DefaultDestroySurface(IWineD3DSurface *pSurface) { + IUnknown* surfaceParent; + TRACE("(%p) call back\n", pSurface); + + /* Now, release the parent, which will take care of cleaning up the surface for us */ + IWineD3DSurface_GetParent(pSurface, &surfaceParent); + IUnknown_Release(surfaceParent); + return IUnknown_Release(surfaceParent); +} + +ULONG WINAPI D3DCB_DefaultDestroyVolume(IWineD3DVolume *pVolume) { + IUnknown* volumeParent; + TRACE("(%p) call back\n", pVolume); + + /* Now, release the parent, which will take care of cleaning up the volume for us */ + IWineD3DVolume_GetParent(pVolume, &volumeParent); + IUnknown_Release(volumeParent); + return IUnknown_Release(volumeParent); +} + +static BOOL match_apple(const WineD3D_GL_Info *gl_info) +{ + /* MacOS has various specialities in the extensions it advertises. Some have to be loaded from + * the opengl 1.2+ core, while other extensions are advertised, but software emulated. So try to + * detect the Apple OpenGL implementation to apply some extension fixups afterwards. + * + * Detecting this isn't really easy. The vendor string doesn't mention Apple. Compile-time checks + * aren't sufficient either because a Linux binary may display on a macos X server via remote X11. + * So try to detect the GL implementation by looking at certain Apple extensions. Some extensions + * like client storage might be supported on other implementations too, but GL_APPLE_flush_render + * is specific to the Mac OS X window management, and GL_APPLE_ycbcr_422 is QuickTime specific. So + * the chance that other implementations support them is rather small since Win32 QuickTime uses + * DirectDraw, not OpenGL. + */ + if(gl_info->supported[APPLE_FENCE] && + gl_info->supported[APPLE_CLIENT_STORAGE] && + gl_info->supported[APPLE_FLUSH_RENDER] && + gl_info->supported[APPLE_YCBCR_422]) { + TRACE_(d3d_caps)("GL_APPLE_fence, GL_APPLE_client_storage, GL_APPLE_flush_render and GL_ycbcr_422 are supported\n"); + TRACE_(d3d_caps)("Activating MacOS fixups\n"); + return TRUE; + } else { + TRACE_(d3d_caps)("Apple extensions are not supported\n"); + TRACE_(d3d_caps)("Not activating MacOS fixups\n"); + return FALSE; + } +} + +static void test_pbo_functionality(WineD3D_GL_Info *gl_info) { + /* Some OpenGL implementations, namely Apple's Geforce 8 driver, advertises PBOs, + * but glTexSubImage from a PBO fails miserably, with the first line repeated over + * all the texture. This function detects this bug by its symptom and disables PBOs + * if the test fails. + * + * The test uploads a 4x4 texture via the PBO in the "native" format GL_BGRA, + * GL_UNSIGNED_INT_8_8_8_8_REV. This format triggers the bug, and it is what we use + * for D3DFMT_A8R8G8B8. Then the texture is read back without any PBO and the data + * read back is compared to the original. If they are equal PBOs are assumed to work, + * otherwise the PBO extension is disabled. + */ + GLuint texture, pbo; + static const unsigned int pattern[] = { + 0x00000000, 0x000000ff, 0x0000ff00, 0x40ff0000, + 0x80ffffff, 0x40ffff00, 0x00ff00ff, 0x0000ffff, + 0x00ffff00, 0x00ff00ff, 0x0000ffff, 0x000000ff, + 0x80ff00ff, 0x0000ffff, 0x00ff00ff, 0x40ff00ff + }; + unsigned int check[sizeof(pattern) / sizeof(pattern[0])]; + + if(!gl_info->supported[ARB_PIXEL_BUFFER_OBJECT]) { + /* No PBO -> No point in testing them */ + return; + } + + ENTER_GL(); + + while(glGetError()); + glGenTextures(1, &texture); + glBindTexture(GL_TEXTURE_2D, texture); + + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAX_LEVEL, 0); + glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA8, 4, 4, 0, GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV, 0); + checkGLcall("Specifying the PBO test texture\n"); + + GL_EXTCALL(glGenBuffersARB(1, &pbo)); + GL_EXTCALL(glBindBufferARB(GL_PIXEL_UNPACK_BUFFER_ARB, pbo)); + GL_EXTCALL(glBufferDataARB(GL_PIXEL_UNPACK_BUFFER_ARB, sizeof(pattern), pattern, GL_STREAM_DRAW_ARB)); + checkGLcall("Specifying the PBO test pbo\n"); + + glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, 4, 4, GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV, NULL); + checkGLcall("Loading the PBO test texture\n"); + + GL_EXTCALL(glBindBufferARB(GL_PIXEL_UNPACK_BUFFER_ARB, 0)); + glFinish(); /* just to be sure */ + + memset(check, 0, sizeof(check)); + glGetTexImage(GL_TEXTURE_2D, 0, GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV, check); + checkGLcall("Reading back the PBO test texture\n"); + + glDeleteTextures(1, &texture); + GL_EXTCALL(glDeleteBuffersARB(1, &pbo)); + checkGLcall("PBO test cleanup\n"); + + LEAVE_GL(); + + if(memcmp(check, pattern, sizeof(check)) != 0) { + WARN_(d3d_caps)("PBO test failed, read back data doesn't match original\n"); + WARN_(d3d_caps)("Disabling PBOs. This may result in slower performance\n"); + gl_info->supported[ARB_PIXEL_BUFFER_OBJECT] = FALSE; } else { - object->surface_alignment = D3D8_PITCH_ALIGNMENT; + TRACE_(d3d_caps)("PBO test successful\n"); } - object->posFixup[0] = 1.0f; /* This is needed to get the x coord unmodified through a MAD. */ - - /* Set the state up as invalid until the device is fully created */ - object->state = WINED3DERR_DRIVERINTERNALERROR; - - TRACE("(%p)->(Adptr:%d, DevType: %x, FocusHwnd: %p, BehFlags: %x, RetDevInt: %p)\n", This, Adapter, DeviceType, - hFocusWindow, BehaviourFlags, ppReturnedDeviceInterface); +} - /* Save the creation parameters */ - object->createParms.AdapterOrdinal = Adapter; - object->createParms.DeviceType = DeviceType; - object->createParms.hFocusWindow = hFocusWindow; - object->createParms.BehaviorFlags = BehaviourFlags; +/* Certain applications(Steam) complain if we report an outdated driver version. In general, + * reporting a driver version is moot because we are not the Windows driver, and we have different + * bugs, features, etc. + * + * If a card is not found in this table, the gl driver version is reported + */ +struct driver_version_information { + WORD vendor; /* reported PCI card vendor ID */ + WORD card; /* reported PCI card device ID */ + const char *description; /* Description of the card e.g. NVIDIA RIVA TNT */ + WORD hipart_hi, hipart_lo; /* driver hiword to report */ + WORD lopart_hi, lopart_lo; /* driver loword to report */ +}; - /* Initialize other useful values */ - object->adapterNo = Adapter; - object->devType = DeviceType; +static const struct driver_version_information driver_version_table[] = { + /* Nvidia drivers. Geforce6 and newer cards are supported by the current driver (180.x) + * GeforceFX support is up to 173.x, - driver uses numbering x.y.11.7341 for 173.41 where x is the windows revision (6=2000/xp, 7=vista), y is unknown + * Geforce2MX/3/4 up to 96.x - driver uses numbering 9.6.8.9 for 96.89 + * TNT/Geforce1/2 up to 71.x - driver uses numbering 7.1.8.6 for 71.86 + * + * All version numbers used below are from the Linux nvidia drivers. + */ + {VENDOR_NVIDIA, CARD_NVIDIA_RIVA_TNT, "NVIDIA RIVA TNT", 7, 1, 8, 6 }, + {VENDOR_NVIDIA, CARD_NVIDIA_RIVA_TNT2, "NVIDIA RIVA TNT2/TNT2 Pro", 7, 1, 8, 6 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE, "NVIDIA GeForce 256", 7, 1, 8, 6 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE2_MX, "NVIDIA GeForce2 MX/MX 400", 9, 6, 4, 3 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE2, "NVIDIA GeForce2 GTS/GeForce2 Pro", 7, 1, 8, 6 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE3, "NVIDIA GeForce3", 9, 6, 4, 3 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE4_MX, "NVIDIA GeForce4 MX 460", 9, 6, 4, 3 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE4_TI4200, "NVIDIA GeForce4 Ti 4200", 9, 6, 4, 3 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCEFX_5200, "NVIDIA GeForce FX 5200", 7, 15, 11, 7341 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCEFX_5600, "NVIDIA GeForce FX 5600", 7, 15, 11, 7341 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCEFX_5800, "NVIDIA GeForce FX 5800", 7, 15, 11, 7341 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_6200, "NVIDIA GeForce 6200", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_6600GT, "NVIDIA GeForce 6600 GT", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_6800, "NVIDIA GeForce 6800", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_7300, "NVIDIA GeForce Go 7300", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_7400, "NVIDIA GeForce Go 7400", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_7600, "NVIDIA GeForce 7600 GT", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_7800GT, "NVIDIA GeForce 7800 GT", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8300GS, "NVIDIA GeForce 8300 GS", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8600GT, "NVIDIA GeForce 8600 GT", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8600MGT, "NVIDIA GeForce 8600M GT", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8800GTS, "NVIDIA GeForce 8800 GTS", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9200, "NVIDIA GeForce 9200", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9400GT, "NVIDIA GeForce 9400 GT", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9500GT, "NVIDIA GeForce 9500 GT", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9600GT, "NVIDIA GeForce 9600 GT", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9800GT, "NVIDIA GeForce 9800 GT", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX260, "NVIDIA GeForce GTX 260", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX275, "NVIDIA GeForce GTX 275", 7, 15, 11, 8044 }, + {VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX280, "NVIDIA GeForce GTX 280", 7, 15, 11, 8044 }, + + /* ATI cards. The driver versions are somewhat similar, but not quite the same. Let's hardcode */ + {VENDOR_ATI, CARD_ATI_RADEON_9500, "ATI Radeon 9500", 6, 14, 10, 6764 }, + {VENDOR_ATI, CARD_ATI_RADEON_X700, "ATI Radeon X700 SE", 6, 14, 10, 6764 }, + {VENDOR_ATI, CARD_ATI_RADEON_X1600, "ATI Radeon X1600 Series", 6, 14, 10, 6764 }, + {VENDOR_ATI, CARD_ATI_RADEON_HD2300, "ATI Mobility Radeon HD 2300", 6, 14, 10, 6764 }, + {VENDOR_ATI, CARD_ATI_RADEON_HD2600, "ATI Mobility Radeon HD 2600", 6, 14, 10, 6764 }, + {VENDOR_ATI, CARD_ATI_RADEON_HD2900, "ATI Radeon HD 2900 XT", 6, 14, 10, 6764 }, + {VENDOR_ATI, CARD_ATI_RADEON_HD4350, "ATI Radeon HD 4350", 6, 14, 10, 6764 }, + {VENDOR_ATI, CARD_ATI_RADEON_HD4600, "ATI Radeon HD 4600 Series", 6, 14, 10, 6764 }, + {VENDOR_ATI, CARD_ATI_RADEON_HD4700, "ATI Radeon HD 4700 Series", 6, 14, 10, 6764 }, + {VENDOR_ATI, CARD_ATI_RADEON_HD4800, "ATI Radeon HD 4800 Series", 6, 14, 10, 6764 }, - select_shader_mode(&adapter->gl_info, DeviceType, - &object->ps_selected_mode, &object->vs_selected_mode); - object->shader_backend = select_shader_backend(adapter, DeviceType); + /* TODO: Add information about legacy ATI hardware, Intel and other cards */ +}; - memset(&shader_caps, 0, sizeof(shader_caps)); - object->shader_backend->shader_get_caps(DeviceType, &adapter->gl_info, &shader_caps); - object->d3d_vshader_constantF = shader_caps.MaxVertexShaderConst; - object->d3d_pshader_constantF = shader_caps.MaxPixelShaderConst; - object->vs_clipping = shader_caps.VSClipping; +static BOOL match_ati_r300_to_500(const WineD3D_GL_Info *gl_info) { + if(gl_info->gl_vendor != VENDOR_ATI) return FALSE; + if(gl_info->gl_card == CARD_ATI_RADEON_9500) return TRUE; + if(gl_info->gl_card == CARD_ATI_RADEON_X700) return TRUE; + if(gl_info->gl_card == CARD_ATI_RADEON_X1600) return TRUE; + return FALSE; +} - memset(&ffp_caps, 0, sizeof(ffp_caps)); - frag_pipeline = select_fragment_implementation(adapter, DeviceType); - object->frag_pipe = frag_pipeline; - frag_pipeline->get_caps(DeviceType, &adapter->gl_info, &ffp_caps); - object->max_ffp_textures = ffp_caps.MaxSimultaneousTextures; - object->max_ffp_texture_stages = ffp_caps.MaxTextureBlendStages; - hr = compile_state_table(object->StateTable, object->multistate_funcs, &adapter->gl_info, - ffp_vertexstate_template, frag_pipeline, misc_state_template); +static BOOL match_geforce5(const WineD3D_GL_Info *gl_info) { + if(gl_info->gl_vendor == VENDOR_NVIDIA) { + if(gl_info->gl_card == CARD_NVIDIA_GEFORCEFX_5800 || gl_info->gl_card == CARD_NVIDIA_GEFORCEFX_5600) { + return TRUE; + } + } + return FALSE; +} - if (FAILED(hr)) { - IWineD3D_Release(object->wineD3D); - HeapFree(GetProcessHeap(), 0, object); +static BOOL match_apple_intel(const WineD3D_GL_Info *gl_info) { + return gl_info->gl_vendor == VENDOR_INTEL && match_apple(gl_info); +} - return hr; - } +static BOOL match_apple_nonr500ati(const WineD3D_GL_Info *gl_info) { + if(!match_apple(gl_info)) return FALSE; + if(gl_info->gl_vendor != VENDOR_ATI) return FALSE; + if(gl_info->gl_card == CARD_ATI_RADEON_X1600) return FALSE; + return TRUE; +} - object->blitter = select_blit_implementation(adapter, DeviceType); +static BOOL match_fglrx(const WineD3D_GL_Info *gl_info) { + if(gl_info->gl_vendor != VENDOR_ATI) return FALSE; + if(match_apple(gl_info)) return FALSE; + if(strstr(gl_info->gl_renderer, "DRI")) return FALSE; /* Filter out Mesa DRI drivers */ + return TRUE; +} - /* set the state of the device to valid */ - object->state = WINED3D_OK; +static BOOL match_dx10_capable(const WineD3D_GL_Info *gl_info) { + /* DX9 cards support 40 single float varyings in hardware, most drivers report 32. ATI misreports + * 44 varyings. So assume that if we have more than 44 varyings we have a dx10 card. + * This detection is for the gl_ClipPos varying quirk. If a d3d9 card really supports more than 44 + * varyings and we subtract one in dx9 shaders its not going to hurt us because the dx9 limit is + * hardcoded + * + * dx10 cards usually have 64 varyings + */ + return gl_info->max_glsl_varyings > 44; +} - /* Get the initial screen setup for ddraw */ - IWineD3DImpl_GetAdapterDisplayMode(iface, Adapter, &mode); +static void quirk_arb_constants(WineD3D_GL_Info *gl_info) { + TRACE_(d3d_caps)("Using ARB vs constant limit(=%u) for GLSL\n", gl_info->vs_arb_constantsF); + gl_info->vs_glsl_constantsF = gl_info->vs_arb_constantsF; + TRACE_(d3d_caps)("Using ARB ps constant limit(=%u) for GLSL\n", gl_info->ps_arb_constantsF); + gl_info->ps_glsl_constantsF = gl_info->ps_arb_constantsF; +} - object->ddraw_width = mode.Width; - object->ddraw_height = mode.Height; - object->ddraw_format = mode.Format; +static void quirk_apple_glsl_constants(WineD3D_GL_Info *gl_info) { + quirk_arb_constants(gl_info); + /* MacOS needs uniforms for relative addressing offsets. This can accumulate to quite a few uniforms. + * Beyond that the general uniform isn't optimal, so reserve a number of uniforms. 12 vec4's should + * allow 48 different offsets or other helper immediate values + */ + TRACE_(d3d_caps)("Reserving 12 GLSL constants for compiler private use\n"); + gl_info->reserved_glsl_constants = max(gl_info->reserved_glsl_constants, 12); +} - for(i = 0; i < PATCHMAP_SIZE; i++) { - list_init(&object->patches[i]); +/* fglrx crashes with a very bad kernel panic if GL_POINT_SPRITE_ARB is set to GL_COORD_REPLACE_ARB + * on more than one texture unit. This means that the d3d9 visual point size test will cause a + * kernel panic on any machine running fglrx 9.3(latest that supports r300 to r500 cards). This + * quirk only enables point sprites on the first texture unit. This keeps point sprites working in + * most games, but avoids the crash + * + * A more sophisticated way would be to find all units that need texture coordinates and enable + * point sprites for one if only one is found, and software emulate point sprites in drawStridedSlow + * if more than one unit needs texture coordinates(This requires software ffp and vertex shaders though) + * + * Note that disabling the extension entirely does not gain predictability because there is no point + * sprite capability flag in d3d, so the potential rendering bugs are the same if we disable the extension. + */ +static void quirk_one_point_sprite(WineD3D_GL_Info *gl_info) { + if(gl_info->supported[ARB_POINT_SPRITE]) { + TRACE("Limiting point sprites to one texture unit\n"); + gl_info->max_point_sprite_units = 1; } +} - IWineD3DDeviceParent_WineD3DDeviceCreated(device_parent, *ppReturnedDeviceInterface); +static void quirk_ati_dx9(WineD3D_GL_Info *gl_info) { + quirk_arb_constants(gl_info); - return WINED3D_OK; + /* MacOS advertises GL_ARB_texture_non_power_of_two on ATI r500 and earlier cards, although + * these cards only support GL_ARB_texture_rectangle(D3DPTEXTURECAPS_NONPOW2CONDITIONAL). + * If real NP2 textures are used, the driver falls back to software. We could just remove the + * extension and use GL_ARB_texture_rectangle instead, but texture_rectangle is inconventient + * due to the non-normalized texture coordinates. Thus set an internal extension flag, + * GL_WINE_normalized_texrect, which signals the code that it can use non power of two textures + * as per GL_ARB_texture_non_power_of_two, but has to stick to the texture_rectangle limits. + * + * fglrx doesn't advertise GL_ARB_texture_non_power_of_two, but it advertises opengl 2.0 which + * has this extension promoted to core. The extension loading code sets this extension supported + * due to that, so this code works on fglrx as well. + */ + TRACE("GL_ARB_texture_non_power_of_two advertised on R500 or earlier card, removing\n"); + gl_info->supported[ARB_TEXTURE_NON_POWER_OF_TWO] = FALSE; + gl_info->supported[WINE_NORMALIZED_TEXRECT] = TRUE; + + /* fglrx has the same structural issues as the one described in quirk_apple_glsl_constants, although + * it is generally more efficient. Reserve just 8 constants + */ + TRACE_(d3d_caps)("Reserving 8 GLSL constants for compiler private use\n"); + gl_info->reserved_glsl_constants = max(gl_info->reserved_glsl_constants, 8); } -static HRESULT WINAPI IWineD3DImpl_GetParent(IWineD3D *iface, IUnknown **pParent) { - IWineD3DImpl *This = (IWineD3DImpl *)iface; - IUnknown_AddRef(This->parent); - *pParent = This->parent; - return WINED3D_OK; +static void quirk_no_np2(WineD3D_GL_Info *gl_info) { + /* The nVidia GeForceFX series reports OpenGL 2.0 capabilities with the latest drivers versions, but + * doesn't explicitly advertise the ARB_tex_npot extension in the GL extension string. + * This usually means that ARB_tex_npot is supported in hardware as long as the application is staying + * within the limits enforced by the ARB_texture_rectangle extension. This however is not true for the + * FX series, which instantly falls back to a slower software path as soon as ARB_tex_npot is used. + * We therefore completely remove ARB_tex_npot from the list of supported extensions. + * + * Note that wine_normalized_texrect can't be used in this case because internally it uses ARB_tex_npot, + * triggering the software fallback. There is not much we can do here apart from disabling the + * software-emulated extension and reenable ARB_tex_rect (which was previously disabled + * in IWineD3DImpl_FillGLCaps). + * This fixup removes performance problems on both the FX 5900 and FX 5700 (e.g. for framebuffer + * post-processing effects in the game "Max Payne 2"). + * The behaviour can be verified through a simple test app attached in bugreport #14724. + */ + TRACE("GL_ARB_texture_non_power_of_two advertised through OpenGL 2.0 on NV FX card, removing\n"); + gl_info->supported[ARB_TEXTURE_NON_POWER_OF_TWO] = FALSE; + gl_info->supported[ARB_TEXTURE_RECTANGLE] = TRUE; } -ULONG WINAPI D3DCB_DefaultDestroySurface(IWineD3DSurface *pSurface) { - IUnknown* surfaceParent; - TRACE("(%p) call back\n", pSurface); +static void quirk_texcoord_w(WineD3D_GL_Info *gl_info) { + /* The Intel GPUs on MacOS set the .w register of texcoords to 0.0 by default, which causes problems + * with fixed function fragment processing. Ideally this flag should be detected with a test shader + * and OpenGL feedback mode, but some GL implementations (MacOS ATI at least, probably all MacOS ones) + * do not like vertex shaders in feedback mode and return an error, even though it should be valid + * according to the spec. + * + * We don't want to enable this on all cards, as it adds an extra instruction per texcoord used. This + * makes the shader slower and eats instruction slots which should be available to the d3d app. + * + * ATI Radeon HD 2xxx cards on MacOS have the issue. Instead of checking for the buggy cards, blacklist + * all radeon cards on Macs and whitelist the good ones. That way we're prepared for the future. If + * this workaround is activated on cards that do not need it, it won't break things, just affect + * performance negatively. + */ + TRACE("Enabling vertex texture coord fixes in vertex shaders\n"); + gl_info->set_texcoord_w = TRUE; +} - /* Now, release the parent, which will take care of cleaning up the surface for us */ - IWineD3DSurface_GetParent(pSurface, &surfaceParent); - IUnknown_Release(surfaceParent); - return IUnknown_Release(surfaceParent); +static void quirk_clip_varying(WineD3D_GL_Info *gl_info) { + gl_info->glsl_clip_varying = TRUE; } -ULONG WINAPI D3DCB_DefaultDestroyVolume(IWineD3DVolume *pVolume) { - IUnknown* volumeParent; - TRACE("(%p) call back\n", pVolume); +struct driver_quirk quirk_table[] = { + { + match_ati_r300_to_500, + quirk_ati_dx9, + "ATI GLSL constant and normalized texrect quirk" + }, + /* MacOS advertises more GLSL vertex shader uniforms than supported by the hardware, and if more are + * used it falls back to software. While the compiler can detect if the shader uses all declared + * uniforms, the optimization fails if the shader uses relative addressing. So any GLSL shader + * using relative addressing falls back to software. + * + * ARB vp gives the correct amount of uniforms, so use it instead of GLSL + */ + { + match_apple, + quirk_apple_glsl_constants, + "Apple GLSL uniform override" + }, + { + match_geforce5, + quirk_no_np2, + "Geforce 5 NP2 disable" + }, + { + match_apple_intel, + quirk_texcoord_w, + "Init texcoord .w for Apple Intel GPU driver" + }, + { + match_apple_nonr500ati, + quirk_texcoord_w, + "Init texcoord .w for Apple ATI >= r600 GPU driver" + }, + { + match_fglrx, + quirk_one_point_sprite, + "Fglrx point sprite crash workaround" + }, + { + match_dx10_capable, + quirk_clip_varying, + "Reserved varying for gl_ClipPos" + } +}; - /* Now, release the parent, which will take care of cleaning up the volume for us */ - IWineD3DVolume_GetParent(pVolume, &volumeParent); - IUnknown_Release(volumeParent); - return IUnknown_Release(volumeParent); +static void fixup_extensions(WineD3D_GL_Info *gl_info) { + unsigned int i; + + for(i = 0; i < (sizeof(quirk_table) / sizeof(*quirk_table)); i++) { + if(!quirk_table[i].match(gl_info)) continue; + TRACE_(d3d_caps)("Applying driver quirk \"%s\"\n", quirk_table[i].description); + quirk_table[i].apply(gl_info); + } + + /* Find out if PBOs work as they are supposed to */ + test_pbo_functionality(gl_info); + + /* Fixup the driver version */ + for(i = 0; i < (sizeof(driver_version_table) / sizeof(driver_version_table[0])); i++) { + if(gl_info->gl_vendor == driver_version_table[i].vendor && + gl_info->gl_card == driver_version_table[i].card) { + TRACE_(d3d_caps)("Found card 0x%04x, 0x%04x in driver version DB\n", gl_info->gl_vendor, gl_info->gl_card); + + gl_info->driver_version = MAKEDWORD_VERSION(driver_version_table[i].lopart_hi, + driver_version_table[i].lopart_lo); + gl_info->driver_version_hipart = MAKEDWORD_VERSION(driver_version_table[i].hipart_hi, + driver_version_table[i].hipart_lo); + strcpy(gl_info->driver_description, driver_version_table[i].description); + break; + } + } } static void WINE_GLAPI invalid_func(const void *data) @@ -4490,16 +4316,13 @@ static void WINE_GLAPI position_float4(const void *data) { const GLfloat *pos = data; - if (pos[3] != 0.0f && pos[3] != 1.0f) - { - float w = 1.0f / pos[3]; + if (pos[3] < eps && pos[3] > -eps) + glVertex3fv(pos); + else { + float w = 1.0 / pos[3]; glVertex4f(pos[0] * w, pos[1] * w, pos[2] * w, w); } - else - { - glVertex3fv(pos); - } } static void WINE_GLAPI diffuse_d3dcolor(const void *data) @@ -4527,7 +4350,7 @@ static void WINE_GLAPI warn_no_specular_func(const void *data) WARN("GL_EXT_secondary_color not supported\n"); } -static void fillGLAttribFuncs(const struct wined3d_gl_info *gl_info) +static void fillGLAttribFuncs(const WineD3D_GL_Info *gl_info) { position_funcs[WINED3D_FFP_EMIT_FLOAT1] = invalid_func; position_funcs[WINED3D_FFP_EMIT_FLOAT2] = invalid_func; @@ -4698,8 +4521,7 @@ BOOL InitAdapters(IWineD3DImpl *This) /* For now only one default adapter */ { struct WineD3DAdapter *adapter = &This->adapters[0]; - const struct wined3d_gl_info *gl_info = &adapter->gl_info; - struct wined3d_fake_gl_ctx fake_gl_ctx = {0}; + const WineD3D_GL_Info *gl_info = &adapter->gl_info; int iPixelFormat; int res; int i; @@ -4712,26 +4534,31 @@ BOOL InitAdapters(IWineD3DImpl *This) adapter->monitorPoint.x = -1; adapter->monitorPoint.y = -1; - if (!WineD3D_CreateFakeGLContext(&fake_gl_ctx)) - { + if (!WineD3D_CreateFakeGLContext()) { ERR("Failed to get a gl context for default adapter\n"); + WineD3D_ReleaseFakeGLContext(); goto nogl_adapter; } ret = IWineD3DImpl_FillGLCaps(&adapter->gl_info); if(!ret) { ERR("Failed to initialize gl caps for default adapter\n"); - WineD3D_ReleaseFakeGLContext(&fake_gl_ctx); + WineD3D_ReleaseFakeGLContext(); goto nogl_adapter; } ret = initPixelFormats(&adapter->gl_info); if(!ret) { ERR("Failed to init gl formats\n"); - WineD3D_ReleaseFakeGLContext(&fake_gl_ctx); + WineD3D_ReleaseFakeGLContext(); goto nogl_adapter; } - hdc = fake_gl_ctx.dc; + hdc = pwglGetCurrentDC(); + if(!hdc) { + ERR("Failed to get gl HDC\n"); + WineD3D_ReleaseFakeGLContext(); + goto nogl_adapter; + } adapter->driver = "Display"; adapter->description = "Direct3D HAL"; @@ -4868,7 +4695,7 @@ BOOL InitAdapters(IWineD3DImpl *This) { ERR("Disabling Direct3D because no hardware accelerated pixel formats have been found!\n"); - WineD3D_ReleaseFakeGLContext(&fake_gl_ctx); + WineD3D_ReleaseFakeGLContext(); HeapFree(GetProcessHeap(), 0, adapter->cfgs); goto nogl_adapter; } @@ -4893,7 +4720,10 @@ BOOL InitAdapters(IWineD3DImpl *This) } } - WineD3D_ReleaseFakeGLContext(&fake_gl_ctx); + fixup_extensions(&adapter->gl_info); + add_gl_compat_wrappers(&adapter->gl_info); + + WineD3D_ReleaseFakeGLContext(); select_shader_mode(&adapter->gl_info, WINED3DDEVTYPE_HAL, &ps_selected_mode, &vs_selected_mode); select_shader_max_constants(ps_selected_mode, vs_selected_mode, &adapter->gl_info); diff --git a/dlls/wined3d/drawprim.c b/dlls/wined3d/drawprim.c index 57f4227e0bc..c644aa20d32 100644 --- a/dlls/wined3d/drawprim.c +++ b/dlls/wined3d/drawprim.c @@ -73,7 +73,6 @@ static void drawStridedFast(IWineD3DDevice *iface, GLenum primitive_type, static void drawStridedSlow(IWineD3DDevice *iface, const struct wined3d_stream_info *si, UINT NumVertexes, GLenum glPrimType, const void *idxData, UINT idxSize, UINT minIndex, UINT startIdx) { - struct WineD3DContext *context = context_get_current(); unsigned int textureNo = 0; const WORD *pIdxBufS = NULL; const DWORD *pIdxBufL = NULL; @@ -87,7 +86,6 @@ static void drawStridedSlow(IWineD3DDevice *iface, const struct wined3d_stream_i const BYTE *texCoords[WINED3DDP_MAXTEXCOORD]; const BYTE *diffuse = NULL, *specular = NULL, *normal = NULL, *position = NULL; const struct wined3d_stream_info_element *element; - UINT num_untracked_materials; DWORD tex_mask = 0; TRACE("Using slow vertex array code\n"); @@ -123,8 +121,7 @@ static void drawStridedSlow(IWineD3DDevice *iface, const struct wined3d_stream_i element = &si->elements[WINED3D_FFP_DIFFUSE]; if (element->data) diffuse = element->data + streamOffset[element->stream_idx]; else glColor4f(1.0f, 1.0f, 1.0f, 1.0f); - num_untracked_materials = context->num_untracked_materials; - if (num_untracked_materials && element->format_desc->format != WINED3DFMT_A8R8G8B8) + if (This->activeContext->num_untracked_materials && element->format_desc->format != WINED3DFMT_A8R8G8B8) FIXME("Implement diffuse color tracking from %s\n", debug_d3dformat(element->format_desc->format)); element = &si->elements[WINED3D_FFP_SPECULAR]; @@ -249,20 +246,18 @@ static void drawStridedSlow(IWineD3DDevice *iface, const struct wined3d_stream_i const void *ptrToCoords = diffuse + SkipnStrides * si->elements[WINED3D_FFP_DIFFUSE].stride; diffuse_funcs[si->elements[WINED3D_FFP_DIFFUSE].format_desc->emit_idx](ptrToCoords); - if (num_untracked_materials) - { + if(This->activeContext->num_untracked_materials) { DWORD diffuseColor = ((const DWORD *)ptrToCoords)[0]; unsigned char i; float color[4]; - color[0] = D3DCOLOR_B_R(diffuseColor) / 255.0f; - color[1] = D3DCOLOR_B_G(diffuseColor) / 255.0f; - color[2] = D3DCOLOR_B_B(diffuseColor) / 255.0f; - color[3] = D3DCOLOR_B_A(diffuseColor) / 255.0f; + color[0] = D3DCOLOR_B_R(diffuseColor) / 255.0; + color[1] = D3DCOLOR_B_G(diffuseColor) / 255.0; + color[2] = D3DCOLOR_B_B(diffuseColor) / 255.0; + color[3] = D3DCOLOR_B_A(diffuseColor) / 255.0; - for (i = 0; i < num_untracked_materials; ++i) - { - glMaterialfv(GL_FRONT_AND_BACK, context->untracked_materials[i], color); + for(i = 0; i < This->activeContext->num_untracked_materials; i++) { + glMaterialfv(GL_FRONT_AND_BACK, This->activeContext->untracked_materials[i], color); } } } @@ -559,7 +554,6 @@ void drawPrimitive(IWineD3DDevice *iface, UINT index_count, UINT numberOfVertice IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; IWineD3DSurfaceImpl *target; - struct WineD3DContext *context; unsigned int i; if (!index_count) return; @@ -581,7 +575,7 @@ void drawPrimitive(IWineD3DDevice *iface, UINT index_count, UINT numberOfVertice /* Signals other modules that a drawing is in progress and the stateblock finalized */ This->isInDraw = TRUE; - context = ActivateContext(This, This->render_targets[0], CTXUSAGE_DRAWPRIM); + ActivateContext(This, This->render_targets[0], CTXUSAGE_DRAWPRIM); if (This->stencilBufferTarget) { /* Note that this depends on the ActivateContext call above to set @@ -592,7 +586,7 @@ void drawPrimitive(IWineD3DDevice *iface, UINT index_count, UINT numberOfVertice DWORD location = This->render_offscreen ? SFLAG_DS_OFFSCREEN : SFLAG_DS_ONSCREEN; if (This->stateBlock->renderState[WINED3DRS_ZWRITEENABLE] || This->stateBlock->renderState[WINED3DRS_ZENABLE]) - surface_load_ds_location(This->stencilBufferTarget, context, location); + surface_load_ds_location(This->stencilBufferTarget, location); if (This->stateBlock->renderState[WINED3DRS_ZWRITEENABLE]) surface_modify_ds_location(This->stencilBufferTarget, location); } @@ -609,7 +603,7 @@ void drawPrimitive(IWineD3DDevice *iface, UINT index_count, UINT numberOfVertice if (!use_vs(This->stateBlock)) { - if (!This->strided_streams.position_transformed && context->num_untracked_materials + if (!This->strided_streams.position_transformed && This->activeContext->num_untracked_materials && This->stateBlock->renderState[WINED3DRS_LIGHTING]) { static BOOL warned; @@ -621,8 +615,7 @@ void drawPrimitive(IWineD3DDevice *iface, UINT index_count, UINT numberOfVertice } emulation = TRUE; } - else if (context->fog_coord && This->stateBlock->renderState[WINED3DRS_FOGENABLE]) - { + else if(This->activeContext->fog_coord && This->stateBlock->renderState[WINED3DRS_FOGENABLE]) { /* Either write a pipeline replacement shader or convert the specular alpha from unsigned byte * to a float in the vertex buffer */ @@ -718,7 +711,7 @@ void drawPrimitive(IWineD3DDevice *iface, UINT index_count, UINT numberOfVertice static void normalize_normal(float *n) { float length = n[0] * n[0] + n[1] * n[1] + n[2] * n[2]; - if (length == 0.0f) return; + if(length == 0.0) return; length = sqrt(length); n[0] = n[0] / length; n[1] = n[1] / length; @@ -750,7 +743,7 @@ static void normalize_normal(float *n) { HRESULT tesselate_rectpatch(IWineD3DDeviceImpl *This, struct WineD3DRectPatch *patch) { unsigned int i, j, num_quads, out_vertex_size, buffer_size, d3d_out_vertex_size; - float max_x = 0.0f, max_y = 0.0f, max_z = 0.0f, neg_z = 0.0f; + float max_x = 0.0, max_y = 0.0, max_z = 0.0, neg_z = 0.0; struct wined3d_stream_info stream_info; struct wined3d_stream_info_element *e; const BYTE *data; @@ -759,11 +752,6 @@ HRESULT tesselate_rectpatch(IWineD3DDeviceImpl *This, GLenum feedback_type; GLfloat *feedbuffer; - /* Simply activate the context for blitting. This disables all the things we don't want and - * takes care of dirtifying. Dirtifying is preferred over pushing / popping, since drawing the - * patch (as opposed to normal draws) will most likely need different changes anyway. */ - ActivateContext(This, NULL, CTXUSAGE_BLIT); - /* First, locate the position data. This is provided in a vertex buffer in the stateblock. * Beware of vbos */ @@ -814,14 +802,19 @@ HRESULT tesselate_rectpatch(IWineD3DDeviceImpl *This, patch->has_normals = TRUE; patch->has_texcoords = FALSE; + /* Simply activate the context for blitting. This disables all the things we don't want and + * takes care of dirtifying. Dirtifying is preferred over pushing / popping, since drawing the + * patch (as opposed to normal draws) will most likely need different changes anyway + */ + ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_BLIT); ENTER_GL(); glMatrixMode(GL_PROJECTION); checkGLcall("glMatrixMode(GL_PROJECTION)"); glLoadIdentity(); checkGLcall("glLoadIndentity()"); - glScalef(1.0f / (max_x), 1.0f / (max_y), max_z == 0.0f ? 1.0f : 1.0f / (2.0f * max_z)); - glTranslatef(0.0f, 0.0f, 0.5f); + glScalef(1 / (max_x) , 1 / (max_y), max_z == 0 ? 1 : 1 / ( 2 * max_z)); + glTranslatef(0, 0, 0.5); checkGLcall("glScalef"); glViewport(-max_x, -max_y, 2 * (max_x), 2 * (max_y)); checkGLcall("glViewport"); @@ -833,11 +826,11 @@ HRESULT tesselate_rectpatch(IWineD3DDeviceImpl *This, checkGLcall("glPolygonMode(GL_FRONT_AND_BACK, GL_FILL)"); IWineD3DDeviceImpl_MarkStateDirty(This, STATE_RENDER(WINED3DRS_FILLMODE)); if(patch->has_normals) { - static const GLfloat black[] = {0.0f, 0.0f, 0.0f, 0.0f}; - static const GLfloat red[] = {1.0f, 0.0f, 0.0f, 0.0f}; - static const GLfloat green[] = {0.0f, 1.0f, 0.0f, 0.0f}; - static const GLfloat blue[] = {0.0f, 0.0f, 1.0f, 0.0f}; - static const GLfloat white[] = {1.0f, 1.0f, 1.0f, 1.0f}; + static const GLfloat black[] = {0, 0, 0, 0}; + static const GLfloat red[] = {1, 0, 0, 0}; + static const GLfloat green[] = {0, 1, 0, 0}; + static const GLfloat blue[] = {0, 0, 1, 0}; + static const GLfloat white[] = {1, 1, 1, 1}; glEnable(GL_LIGHTING); checkGLcall("glEnable(GL_LIGHTING)"); glLightModelfv(GL_LIGHT_MODEL_AMBIENT, black); @@ -856,21 +849,21 @@ HRESULT tesselate_rectpatch(IWineD3DDeviceImpl *This, glLightfv(GL_LIGHT0, GL_AMBIENT, black); glLightfv(GL_LIGHT0, GL_POSITION, red); glEnable(GL_LIGHT0); - checkGLcall("Setting up light 1"); + checkGLcall("Setting up light 1\n"); IWineD3DDeviceImpl_MarkStateDirty(This, STATE_ACTIVELIGHT(1)); glLightfv(GL_LIGHT1, GL_DIFFUSE, green); glLightfv(GL_LIGHT1, GL_SPECULAR, black); glLightfv(GL_LIGHT1, GL_AMBIENT, black); glLightfv(GL_LIGHT1, GL_POSITION, green); glEnable(GL_LIGHT1); - checkGLcall("Setting up light 2"); + checkGLcall("Setting up light 2\n"); IWineD3DDeviceImpl_MarkStateDirty(This, STATE_ACTIVELIGHT(2)); glLightfv(GL_LIGHT2, GL_DIFFUSE, blue); glLightfv(GL_LIGHT2, GL_SPECULAR, black); glLightfv(GL_LIGHT2, GL_AMBIENT, black); glLightfv(GL_LIGHT2, GL_POSITION, blue); glEnable(GL_LIGHT2); - checkGLcall("Setting up light 3"); + checkGLcall("Setting up light 3\n"); IWineD3DDeviceImpl_MarkStateDirty(This, STATE_MATERIAL); IWineD3DDeviceImpl_MarkStateDirty(This, STATE_RENDER(WINED3DRS_COLORVERTEX)); @@ -878,7 +871,7 @@ HRESULT tesselate_rectpatch(IWineD3DDeviceImpl *This, glMaterialfv(GL_FRONT_AND_BACK, GL_EMISSION, black); glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, black); glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, white); - checkGLcall("Setting up materials"); + checkGLcall("Setting up materials\n"); } /* Enable the needed maps. @@ -918,18 +911,18 @@ HRESULT tesselate_rectpatch(IWineD3DDeviceImpl *This, feedbuffer = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, buffer_size * sizeof(float) * 8); glMap2f(GL_MAP2_VERTEX_3, - 0.0f, 1.0f, vtxStride / sizeof(float), info->Width, - 0.0f, 1.0f, info->Stride * vtxStride / sizeof(float), info->Height, + 0, 1, vtxStride / sizeof(float), info->Width, + 0, 1, info->Stride * vtxStride / sizeof(float), info->Height, (const GLfloat *)data); checkGLcall("glMap2f"); if(patch->has_texcoords) { glMap2f(GL_MAP2_TEXTURE_COORD_4, - 0.0f, 1.0f, vtxStride / sizeof(float), info->Width, - 0.0f, 1.0f, info->Stride * vtxStride / sizeof(float), info->Height, + 0, 1, vtxStride / sizeof(float), info->Width, + 0, 1, info->Stride * vtxStride / sizeof(float), info->Height, (const GLfloat *)data); checkGLcall("glMap2f"); } - glMapGrid2f(ceilf(patch->numSegs[0]), 0.0f, 1.0f, ceilf(patch->numSegs[1]), 0.0f, 1.0f); + glMapGrid2f(ceilf(patch->numSegs[0]), 0.0, 1.0, ceilf(patch->numSegs[1]), 0.0, 1.0); checkGLcall("glMapGrid2f"); glFeedbackBuffer(buffer_size * 2, feedback_type, feedbuffer); @@ -937,7 +930,7 @@ HRESULT tesselate_rectpatch(IWineD3DDeviceImpl *This, glRenderMode(GL_FEEDBACK); glEvalMesh2(GL_FILL, 0, ceilf(patch->numSegs[0]), 0, ceilf(patch->numSegs[1])); - checkGLcall("glEvalMesh2"); + checkGLcall("glEvalMesh2\n"); i = glRenderMode(GL_RENDER); if(i == -1) { @@ -971,7 +964,7 @@ HRESULT tesselate_rectpatch(IWineD3DDeviceImpl *This, */ patch->mem[i + 0] = feedbuffer[j + out_vertex_size * 2 + 2]; /* x, triangle 2 */ patch->mem[i + 1] = feedbuffer[j + out_vertex_size * 2 + 3]; /* y, triangle 2 */ - patch->mem[i + 2] = (feedbuffer[j + out_vertex_size * 2 + 4] - 0.5f) * 4.0f * max_z; /* z, triangle 3 */ + patch->mem[i + 2] = (feedbuffer[j + out_vertex_size * 2 + 4] - 0.5) * 4 * max_z; /* z, triangle 3 */ if(patch->has_normals) { patch->mem[i + 3] = feedbuffer[j + out_vertex_size * 2 + 5]; patch->mem[i + 4] = feedbuffer[j + out_vertex_size * 2 + 6]; @@ -981,7 +974,7 @@ HRESULT tesselate_rectpatch(IWineD3DDeviceImpl *This, patch->mem[i + 0] = feedbuffer[j + out_vertex_size * 1 + 2]; /* x, triangle 2 */ patch->mem[i + 1] = feedbuffer[j + out_vertex_size * 1 + 3]; /* y, triangle 2 */ - patch->mem[i + 2] = (feedbuffer[j + out_vertex_size * 1 + 4] - 0.5f) * 4.0f * max_z; /* z, triangle 2 */ + patch->mem[i + 2] = (feedbuffer[j + out_vertex_size * 1 + 4] - 0.5) * 4 * max_z; /* z, triangle 2 */ if(patch->has_normals) { patch->mem[i + 3] = feedbuffer[j + out_vertex_size * 1 + 5]; patch->mem[i + 4] = feedbuffer[j + out_vertex_size * 1 + 6]; @@ -991,7 +984,7 @@ HRESULT tesselate_rectpatch(IWineD3DDeviceImpl *This, patch->mem[i + 0] = feedbuffer[j + out_vertex_size * 0 + 2]; /* x, triangle 1 */ patch->mem[i + 1] = feedbuffer[j + out_vertex_size * 0 + 3]; /* y, triangle 1 */ - patch->mem[i + 2] = (feedbuffer[j + out_vertex_size * 0 + 4] - 0.5f) * 4.0f * max_z; /* z, triangle 1 */ + patch->mem[i + 2] = (feedbuffer[j + out_vertex_size * 0 + 4] - 0.5) * 4 * max_z; /* z, triangle 1 */ if(patch->has_normals) { patch->mem[i + 3] = feedbuffer[j + out_vertex_size * 0 + 5]; patch->mem[i + 4] = feedbuffer[j + out_vertex_size * 0 + 6]; @@ -1002,18 +995,18 @@ HRESULT tesselate_rectpatch(IWineD3DDeviceImpl *This, if(patch->has_normals) { /* Now do the same with reverse light directions */ - static const GLfloat x[] = {-1.0f, 0.0f, 0.0f, 0.0f}; - static const GLfloat y[] = { 0.0f, -1.0f, 0.0f, 0.0f}; - static const GLfloat z[] = { 0.0f, 0.0f, -1.0f, 0.0f}; + static const GLfloat x[] = {-1, 0, 0, 0}; + static const GLfloat y[] = { 0, -1, 0, 0}; + static const GLfloat z[] = { 0, 0, -1, 0}; glLightfv(GL_LIGHT0, GL_POSITION, x); glLightfv(GL_LIGHT1, GL_POSITION, y); glLightfv(GL_LIGHT2, GL_POSITION, z); - checkGLcall("Setting up reverse light directions"); + checkGLcall("Setting up reverse light directions\n"); glRenderMode(GL_FEEDBACK); checkGLcall("glRenderMode(GL_FEEDBACK)"); glEvalMesh2(GL_FILL, 0, ceilf(patch->numSegs[0]), 0, ceilf(patch->numSegs[1])); - checkGLcall("glEvalMesh2"); + checkGLcall("glEvalMesh2\n"); i = glRenderMode(GL_RENDER); checkGLcall("glRenderMode(GL_RENDER)"); @@ -1027,29 +1020,29 @@ HRESULT tesselate_rectpatch(IWineD3DDeviceImpl *This, ERR("Unexpected polygon: %f corners\n", feedbuffer[j + 1]); continue; } - if(patch->mem[i + 3] == 0.0f) + if(patch->mem[i + 3] == 0.0) patch->mem[i + 3] = -feedbuffer[j + out_vertex_size * 2 + 5]; - if(patch->mem[i + 4] == 0.0f) + if(patch->mem[i + 4] == 0.0) patch->mem[i + 4] = -feedbuffer[j + out_vertex_size * 2 + 6]; - if(patch->mem[i + 5] == 0.0f) + if(patch->mem[i + 5] == 0.0) patch->mem[i + 5] = -feedbuffer[j + out_vertex_size * 2 + 7]; normalize_normal(patch->mem + i + 3); i += d3d_out_vertex_size; - if(patch->mem[i + 3] == 0.0f) + if(patch->mem[i + 3] == 0.0) patch->mem[i + 3] = -feedbuffer[j + out_vertex_size * 1 + 5]; - if(patch->mem[i + 4] == 0.0f) + if(patch->mem[i + 4] == 0.0) patch->mem[i + 4] = -feedbuffer[j + out_vertex_size * 1 + 6]; - if(patch->mem[i + 5] == 0.0f) + if(patch->mem[i + 5] == 0.0) patch->mem[i + 5] = -feedbuffer[j + out_vertex_size * 1 + 7]; normalize_normal(patch->mem + i + 3); i += d3d_out_vertex_size; - if(patch->mem[i + 3] == 0.0f) + if(patch->mem[i + 3] == 0.0) patch->mem[i + 3] = -feedbuffer[j + out_vertex_size * 0 + 5]; - if(patch->mem[i + 4] == 0.0f) + if(patch->mem[i + 4] == 0.0) patch->mem[i + 4] = -feedbuffer[j + out_vertex_size * 0 + 6]; - if(patch->mem[i + 5] == 0.0f) + if(patch->mem[i + 5] == 0.0) patch->mem[i + 5] = -feedbuffer[j + out_vertex_size * 0 + 7]; normalize_normal(patch->mem + i + 3); i += d3d_out_vertex_size; diff --git a/dlls/wined3d/gl_compat.c b/dlls/wined3d/gl_compat.c index 30d34086e1b..1fc48cc9204 100644 --- a/dlls/wined3d/gl_compat.c +++ b/dlls/wined3d/gl_compat.c @@ -133,7 +133,7 @@ static void WINE_GLAPI wine_glGetIntegerv(GLenum pname, GLint* params) { static void (WINE_GLAPI *old_multitex_glGetFloatv) (GLenum pname, GLfloat* params) = NULL; static void WINE_GLAPI wine_glGetFloatv(GLenum pname, GLfloat* params) { - if (pname == GL_ACTIVE_TEXTURE) *params = 0.0f; + if(pname == GL_ACTIVE_TEXTURE) *params = 0.0; else old_multitex_glGetFloatv(pname, params); } @@ -147,7 +147,7 @@ static void WINE_GLAPI wine_glGetDoublev(GLenum pname, GLdouble* params) { static void (WINE_GLAPI *old_fogcoord_glEnable) (GLenum cap) = NULL; static void WINE_GLAPI wine_glEnable(GLenum cap) { if(cap == GL_FOG) { - struct WineD3DContext *ctx = context_get_current(); + WineD3DContext *ctx = getActiveContext(); ctx->fog_enabled = 1; if(ctx->gl_fog_source != GL_FRAGMENT_DEPTH_EXT) return; } @@ -157,7 +157,7 @@ static void WINE_GLAPI wine_glEnable(GLenum cap) { static void (WINE_GLAPI *old_fogcoord_glDisable) (GLenum cap) = NULL; static void WINE_GLAPI wine_glDisable(GLenum cap) { if(cap == GL_FOG) { - struct WineD3DContext *ctx = context_get_current(); + WineD3DContext *ctx = getActiveContext(); ctx->fog_enabled = 0; if(ctx->gl_fog_source != GL_FRAGMENT_DEPTH_EXT) return; } @@ -166,9 +166,8 @@ static void WINE_GLAPI wine_glDisable(GLenum cap) { static void (WINE_GLAPI *old_fogcoord_glFogi) (GLenum pname, GLint param) = NULL; static void WINE_GLAPI wine_glFogi(GLenum pname, GLint param) { - struct WineD3DContext *ctx = context_get_current(); - if(pname == GL_FOG_COORDINATE_SOURCE_EXT) { + WineD3DContext *ctx = getActiveContext(); ctx->gl_fog_source = param; if(param == GL_FRAGMENT_DEPTH_EXT) { if(ctx->fog_enabled) old_fogcoord_glEnable(GL_FOG); @@ -178,9 +177,9 @@ static void WINE_GLAPI wine_glFogi(GLenum pname, GLint param) { } } else { if(pname == GL_FOG_START) { - ctx->fogstart = param; + getActiveContext()->fogstart = param; } else if(pname == GL_FOG_END) { - ctx->fogend = param; + getActiveContext()->fogend = param; } old_fogcoord_glFogi(pname, param); } @@ -188,8 +187,8 @@ static void WINE_GLAPI wine_glFogi(GLenum pname, GLint param) { static void (WINE_GLAPI *old_fogcoord_glFogiv) (GLenum pname, const GLint *param) = NULL; static void WINE_GLAPI wine_glFogiv(GLenum pname, const GLint *param) { - struct WineD3DContext *ctx = context_get_current(); if(pname == GL_FOG_COORDINATE_SOURCE_EXT) { + WineD3DContext *ctx = getActiveContext(); ctx->gl_fog_source = *param; if(*param == GL_FRAGMENT_DEPTH_EXT) { if(ctx->fog_enabled) old_fogcoord_glEnable(GL_FOG); @@ -199,9 +198,9 @@ static void WINE_GLAPI wine_glFogiv(GLenum pname, const GLint *param) { } } else { if(pname == GL_FOG_START) { - ctx->fogstart = *param; + getActiveContext()->fogstart = *param; } else if(pname == GL_FOG_END) { - ctx->fogend = *param; + getActiveContext()->fogend = *param; } old_fogcoord_glFogiv(pname, param); } @@ -209,8 +208,8 @@ static void WINE_GLAPI wine_glFogiv(GLenum pname, const GLint *param) { static void (WINE_GLAPI *old_fogcoord_glFogf) (GLenum pname, GLfloat param) = NULL; static void WINE_GLAPI wine_glFogf(GLenum pname, GLfloat param) { - struct WineD3DContext *ctx = context_get_current(); if(pname == GL_FOG_COORDINATE_SOURCE_EXT) { + WineD3DContext *ctx = getActiveContext(); ctx->gl_fog_source = (GLint) param; if(param == GL_FRAGMENT_DEPTH_EXT) { if(ctx->fog_enabled) old_fogcoord_glEnable(GL_FOG); @@ -220,9 +219,9 @@ static void WINE_GLAPI wine_glFogf(GLenum pname, GLfloat param) { } } else { if(pname == GL_FOG_START) { - ctx->fogstart = param; + getActiveContext()->fogstart = param; } else if(pname == GL_FOG_END) { - ctx->fogend = param; + getActiveContext()->fogend = param; } old_fogcoord_glFogf(pname, param); } @@ -230,8 +229,8 @@ static void WINE_GLAPI wine_glFogf(GLenum pname, GLfloat param) { static void (WINE_GLAPI *old_fogcoord_glFogfv) (GLenum pname, const GLfloat *param) = NULL; static void WINE_GLAPI wine_glFogfv(GLenum pname, const GLfloat *param) { - struct WineD3DContext *ctx = context_get_current(); if(pname == GL_FOG_COORDINATE_SOURCE_EXT) { + WineD3DContext *ctx = getActiveContext(); ctx->gl_fog_source = (GLint) *param; if(*param == GL_FRAGMENT_DEPTH_EXT) { if(ctx->fog_enabled) old_fogcoord_glEnable(GL_FOG); @@ -241,14 +240,15 @@ static void WINE_GLAPI wine_glFogfv(GLenum pname, const GLfloat *param) { } } else { if(pname == GL_FOG_COLOR) { + WineD3DContext *ctx = getActiveContext(); ctx->fogcolor[0] = param[0]; ctx->fogcolor[1] = param[1]; ctx->fogcolor[2] = param[2]; ctx->fogcolor[3] = param[3]; } else if(pname == GL_FOG_START) { - ctx->fogstart = *param; + getActiveContext()->fogstart = *param; } else if(pname == GL_FOG_END) { - ctx->fogend = *param; + getActiveContext()->fogend = *param; } old_fogcoord_glFogfv(pname, param); } @@ -269,15 +269,15 @@ static void (WINE_GLAPI *old_fogcoord_glFogCoordfvEXT) (const GLfloat *f) = NULL static void (WINE_GLAPI *old_fogcoord_glFogCoorddvEXT) (const GLdouble *f) = NULL; static void WINE_GLAPI wine_glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w) { - struct WineD3DContext *ctx = context_get_current(); + WineD3DContext *ctx = getActiveContext(); if(ctx->gl_fog_source == GL_FOG_COORDINATE_EXT && ctx->fog_enabled) { GLfloat c[4] = {ctx->color[0], ctx->color[1], ctx->color[2], ctx->color[3]}; GLfloat i; i = (ctx->fogend - ctx->fog_coord_value) / (ctx->fogend - ctx->fogstart); - c[0] = i * c[0] + (1.0f - i) * ctx->fogcolor[0]; - c[1] = i * c[1] + (1.0f - i) * ctx->fogcolor[1]; - c[2] = i * c[2] + (1.0f - i) * ctx->fogcolor[2]; + c[0] = i * c[0] + (1.0 - i) * ctx->fogcolor[0]; + c[1] = i * c[1] + (1.0 - i) * ctx->fogcolor[1]; + c[2] = i * c[2] + (1.0 - i) * ctx->fogcolor[2]; old_fogcoord_glColor4f(c[0], c[1], c[2], c[3]); old_fogcoord_glVertex4f(x, y, z, w); @@ -291,15 +291,15 @@ static void WINE_GLAPI wine_glVertex4fv(const GLfloat *pos) { } static void WINE_GLAPI wine_glVertex3f(GLfloat x, GLfloat y, GLfloat z) { - wine_glVertex4f(x, y, z, 1.0f); + wine_glVertex4f(x, y, z, 1.0); } static void WINE_GLAPI wine_glVertex3fv(const GLfloat *pos) { - wine_glVertex4f(pos[0], pos[1], pos[2], 1.0f); + wine_glVertex4f(pos[0], pos[1], pos[2], 1.0); } -static void WINE_GLAPI wine_glColor4f(GLfloat r, GLfloat g, GLfloat b, GLfloat a) { - struct WineD3DContext *ctx = context_get_current(); +static void wine_glColor4f(GLfloat r, GLfloat g, GLfloat b, GLfloat a) { + WineD3DContext *ctx = getActiveContext(); ctx->color[0] = r; ctx->color[1] = g; ctx->color[2] = b; @@ -307,44 +307,43 @@ static void WINE_GLAPI wine_glColor4f(GLfloat r, GLfloat g, GLfloat b, GLfloat a old_fogcoord_glColor4f(r, g, b, a); } -static void WINE_GLAPI wine_glColor4fv(const GLfloat *c) { +static void wine_glColor4fv(const GLfloat *c) { wine_glColor4f(c[0], c[1], c[2], c[3]); } -static void WINE_GLAPI wine_glColor3f(GLfloat r, GLfloat g, GLfloat b) { - wine_glColor4f(r, g, b, 1.0f); +static void wine_glColor3f(GLfloat r, GLfloat g, GLfloat b) { + wine_glColor4f(r, g, b, 1.0); } -static void WINE_GLAPI wine_glColor3fv(const GLfloat *c) { - wine_glColor4f(c[0], c[1], c[2], 1.0f); +static void wine_glColor3fv(const GLfloat *c) { + wine_glColor4f(c[0], c[1], c[2], 1.0); } -static void WINE_GLAPI wine_glColor4ub(GLubyte r, GLubyte g, GLubyte b, GLubyte a) { - wine_glColor4f(r / 255.0f, g / 255.0f, b / 255.0f, a / 255.0f); +static void wine_glColor4ub(GLubyte r, GLubyte g, GLubyte b, GLubyte a) { + wine_glColor4f(r / 255.0, g / 255.0, b / 255.0, a / 255.0); } /* In D3D the fog coord is a UBYTE, so there's no problem with using the single * precision function */ -static void WINE_GLAPI wine_glFogCoordfEXT(GLfloat f) { - struct WineD3DContext *ctx = context_get_current(); +static void wine_glFogCoordfEXT(GLfloat f) { + WineD3DContext *ctx = getActiveContext(); ctx->fog_coord_value = f; } -static void WINE_GLAPI wine_glFogCoorddEXT(GLdouble f) { +static void wine_glFogCoorddEXT(GLdouble f) { wine_glFogCoordfEXT(f); } -static void WINE_GLAPI wine_glFogCoordfvEXT(const GLfloat *f) { +static void wine_glFogCoordfvEXT(const GLfloat *f) { wine_glFogCoordfEXT(*f); } -static void WINE_GLAPI wine_glFogCoorddvEXT(const GLdouble *f) { +static void wine_glFogCoorddvEXT(const GLdouble *f) { wine_glFogCoordfEXT(*f); } /* End GL_EXT_fog_coord emulation */ #define GLINFO_LOCATION (*gl_info) -void add_gl_compat_wrappers(struct wined3d_gl_info *gl_info) -{ +void add_gl_compat_wrappers(WineD3D_GL_Info *gl_info) { if(!GL_SUPPORT(ARB_MULTITEXTURE)) { TRACE("Applying GL_ARB_multitexture emulation hooks\n"); gl_info->glActiveTextureARB = wine_glActiveTextureARB; diff --git a/dlls/wined3d/glsl_shader.c b/dlls/wined3d/glsl_shader.c index 95649ecb4a5..e065296d88d 100644 --- a/dlls/wined3d/glsl_shader.c +++ b/dlls/wined3d/glsl_shader.c @@ -83,7 +83,6 @@ struct constant_heap /* GLSL shader private data */ struct shader_glsl_priv { - struct wined3d_shader_buffer shader_buffer; struct wine_rb_tree program_lookup; struct glsl_shader_prog_link *glsl_program; struct constant_heap vconst_heap; @@ -104,7 +103,7 @@ struct glsl_shader_prog_link { GLint vuniformI_locations[MAX_CONST_I]; GLint puniformI_locations[MAX_CONST_I]; GLint posFixup_location; - GLint np2Fixup_location; + GLint np2Fixup_location[MAX_FRAGMENT_SAMPLERS]; GLint bumpenvmat_location[MAX_TEXTURES]; GLint luminancescale_location[MAX_TEXTURES]; GLint luminanceoffset_location[MAX_TEXTURES]; @@ -115,7 +114,6 @@ struct glsl_shader_prog_link { struct vs_compile_args vs_args; struct ps_compile_args ps_args; UINT constant_version; - const struct ps_np2fixup_info *np2Fixup_info; }; typedef struct { @@ -128,13 +126,11 @@ typedef struct { struct shader_glsl_ctx_priv { const struct vs_compile_args *cur_vs_args; const struct ps_compile_args *cur_ps_args; - struct ps_np2fixup_info *cur_np2fixup_info; }; struct glsl_ps_compiled_shader { struct ps_compile_args args; - struct ps_np2fixup_info np2fixup; GLhandleARB prgId; }; @@ -177,7 +173,7 @@ static char *get_info_log_line(char **ptr) /** Prints the GLSL info log which will contain error messages if they exist */ /* GL locking is done by the caller */ -static void print_glsl_info_log(const struct wined3d_gl_info *gl_info, GLhandleARB obj) +static void print_glsl_info_log(const WineD3D_GL_Info *gl_info, GLhandleARB obj) { int infologLength = 0; char *infoLog; @@ -193,8 +189,10 @@ static void print_glsl_info_log(const struct wined3d_gl_info *gl_info, GLhandleA "Vertex shader(s) linked, no fragment shader(s) defined. \n ", /* fglrx, with \n */ "Vertex shader(s) linked, no fragment shader(s) defined.", /* fglrx, no \n */ "Fragment shader was successfully compiled to run on hardware.\n" + "WARNING: 0:2: extension 'GL_ARB_draw_buffers' is not supported", "Fragment shader(s) linked, no vertex shader(s) defined.", /* fglrx, no \n */ "Fragment shader(s) linked, no vertex shader(s) defined. \n ", /* fglrx, with \n */ + "WARNING: 0:2: extension 'GL_ARB_draw_buffers' is not supported\n" /* MacOS ati */ }; if (!TRACE_ON(d3d_shader) && !FIXME_ON(d3d_shader)) return; @@ -242,8 +240,7 @@ static void print_glsl_info_log(const struct wined3d_gl_info *gl_info, GLhandleA * Loads (pixel shader) samplers */ /* GL locking is done by the caller */ -static void shader_glsl_load_psamplers(const struct wined3d_gl_info *gl_info, - DWORD *tex_unit_map, GLhandleARB programId) +static void shader_glsl_load_psamplers(const WineD3D_GL_Info *gl_info, DWORD *tex_unit_map, GLhandleARB programId) { GLint name_loc; int i; @@ -267,8 +264,7 @@ static void shader_glsl_load_psamplers(const struct wined3d_gl_info *gl_info, } /* GL locking is done by the caller */ -static void shader_glsl_load_vsamplers(const struct wined3d_gl_info *gl_info, - DWORD *tex_unit_map, GLhandleARB programId) +static void shader_glsl_load_vsamplers(const WineD3D_GL_Info *gl_info, DWORD *tex_unit_map, GLhandleARB programId) { GLint name_loc; char sampler_name[20]; @@ -292,7 +288,7 @@ static void shader_glsl_load_vsamplers(const struct wined3d_gl_info *gl_info, } /* GL locking is done by the caller */ -static inline void walk_constant_heap(const struct wined3d_gl_info *gl_info, const float *constants, +static inline void walk_constant_heap(const WineD3D_GL_Info *gl_info, const float *constants, const GLint *constant_locations, const struct constant_heap *heap, unsigned char *stack, DWORD version) { int stack_idx = 0; @@ -354,22 +350,22 @@ static inline void walk_constant_heap(const struct wined3d_gl_info *gl_info, con } /* GL locking is done by the caller */ -static inline void apply_clamped_constant(const struct wined3d_gl_info *gl_info, GLint location, const GLfloat *data) +static inline void apply_clamped_constant(const WineD3D_GL_Info *gl_info, GLint location, const GLfloat *data) { GLfloat clamped_constant[4]; if (location == -1) return; - clamped_constant[0] = data[0] < -1.0f ? -1.0f : data[0] > 1.0f ? 1.0f : data[0]; - clamped_constant[1] = data[1] < -1.0f ? -1.0f : data[1] > 1.0f ? 1.0f : data[1]; - clamped_constant[2] = data[2] < -1.0f ? -1.0f : data[2] > 1.0f ? 1.0f : data[2]; - clamped_constant[3] = data[3] < -1.0f ? -1.0f : data[3] > 1.0f ? 1.0f : data[3]; + clamped_constant[0] = data[0] < -1.0f ? -1.0f : data[0] > 1.0 ? 1.0 : data[0]; + clamped_constant[1] = data[1] < -1.0f ? -1.0f : data[1] > 1.0 ? 1.0 : data[1]; + clamped_constant[2] = data[2] < -1.0f ? -1.0f : data[2] > 1.0 ? 1.0 : data[2]; + clamped_constant[3] = data[3] < -1.0f ? -1.0f : data[3] > 1.0 ? 1.0 : data[3]; GL_EXTCALL(glUniform4fvARB(location, 1, clamped_constant)); } /* GL locking is done by the caller */ -static inline void walk_constant_heap_clamped(const struct wined3d_gl_info *gl_info, const float *constants, +static inline void walk_constant_heap_clamped(const WineD3D_GL_Info *gl_info, const float *constants, const GLint *constant_locations, const struct constant_heap *heap, unsigned char *stack, DWORD version) { int stack_idx = 0; @@ -430,7 +426,7 @@ static inline void walk_constant_heap_clamped(const struct wined3d_gl_info *gl_i /* Loads floating point constants (aka uniforms) into the currently set GLSL program. */ /* GL locking is done by the caller */ -static void shader_glsl_load_constantsF(IWineD3DBaseShaderImpl *This, const struct wined3d_gl_info *gl_info, +static void shader_glsl_load_constantsF(IWineD3DBaseShaderImpl *This, const WineD3D_GL_Info *gl_info, const float *constants, const GLint *constant_locations, const struct constant_heap *heap, unsigned char *stack, UINT version) { @@ -461,7 +457,7 @@ static void shader_glsl_load_constantsF(IWineD3DBaseShaderImpl *This, const stru /* Loads integer constants (aka uniforms) into the currently set GLSL program. */ /* GL locking is done by the caller */ -static void shader_glsl_load_constantsI(IWineD3DBaseShaderImpl *This, const struct wined3d_gl_info *gl_info, +static void shader_glsl_load_constantsI(IWineD3DBaseShaderImpl *This, const WineD3D_GL_Info *gl_info, const GLint locations[MAX_CONST_I], const int *constants, WORD constants_set) { unsigned int i; @@ -498,36 +494,16 @@ static void shader_glsl_load_constantsI(IWineD3DBaseShaderImpl *This, const stru /* Loads boolean constants (aka uniforms) into the currently set GLSL program. */ /* GL locking is done by the caller */ -static void shader_glsl_load_constantsB(IWineD3DBaseShaderImpl *This, const struct wined3d_gl_info *gl_info, +static void shader_glsl_load_constantsB(IWineD3DBaseShaderImpl *This, const WineD3D_GL_Info *gl_info, GLhandleARB programId, const BOOL *constants, WORD constants_set) { GLint tmp_loc; unsigned int i; char tmp_name[8]; - const char *prefix; + char is_pshader = shader_is_pshader_version(This->baseShader.reg_maps.shader_version.type); + const char* prefix = is_pshader? "PB":"VB"; struct list* ptr; - switch (This->baseShader.reg_maps.shader_version.type) - { - case WINED3D_SHADER_TYPE_VERTEX: - prefix = "VB"; - break; - - case WINED3D_SHADER_TYPE_GEOMETRY: - prefix = "GB"; - break; - - case WINED3D_SHADER_TYPE_PIXEL: - prefix = "PB"; - break; - - default: - FIXME("Unknown shader type %#x.\n", - This->baseShader.reg_maps.shader_version.type); - prefix = "UB"; - break; - } - /* TODO: Benchmark and see if it would be beneficial to store the * locations of the constants to avoid looking up each time */ for (i = 0; constants_set; constants_set >>= 1, ++i) @@ -595,31 +571,24 @@ static void shader_glsl_load_np2fixup_constants( return; } - if (prog->ps_args.np2_fixup && -1 != prog->np2Fixup_location) { - const struct wined3d_gl_info *gl_info = &deviceImpl->adapter->gl_info; - const IWineD3DStateBlockImpl* stateBlock = (const IWineD3DStateBlockImpl*) deviceImpl->stateBlock; + if (prog->ps_args.np2_fixup) { UINT i; UINT fixup = prog->ps_args.np2_fixup; - GLfloat np2fixup_constants[4 * MAX_FRAGMENT_SAMPLERS]; + const WineD3D_GL_Info* gl_info = &deviceImpl->adapter->gl_info; + const IWineD3DStateBlockImpl* stateBlock = (const IWineD3DStateBlockImpl*) deviceImpl->stateBlock; for (i = 0; fixup; fixup >>= 1, ++i) { - const unsigned char idx = prog->np2Fixup_info->idx[i]; - const IWineD3DBaseTextureImpl* const tex = (const IWineD3DBaseTextureImpl*) stateBlock->textures[i]; - GLfloat* tex_dim = &np2fixup_constants[(idx >> 1) * 4]; - - if (!tex) { - FIXME("Nonexistent texture is flagged for NP2 texcoord fixup\n"); - continue; - } - - if (idx % 2) { - tex_dim[2] = tex->baseTexture.pow2Matrix[0]; tex_dim[3] = tex->baseTexture.pow2Matrix[5]; - } else { - tex_dim[0] = tex->baseTexture.pow2Matrix[0]; tex_dim[1] = tex->baseTexture.pow2Matrix[5]; + if (-1 != prog->np2Fixup_location[i]) { + const IWineD3DBaseTextureImpl* const tex = (const IWineD3DBaseTextureImpl*) stateBlock->textures[i]; + if (!tex) { + FIXME("Nonexistent texture is flagged for NP2 texcoord fixup\n"); + continue; + } else { + const float tex_dim[2] = {tex->baseTexture.pow2Matrix[0], tex->baseTexture.pow2Matrix[5]}; + GL_EXTCALL(glUniform2fvARB(prog->np2Fixup_location[i], 1, tex_dim)); + } } } - - GL_EXTCALL(glUniform4fvARB(prog->np2Fixup_location, prog->np2Fixup_info->num_consts, np2fixup_constants)); } } @@ -635,7 +604,7 @@ static void shader_glsl_load_constants( IWineD3DDeviceImpl* deviceImpl = (IWineD3DDeviceImpl*) device; struct shader_glsl_priv *priv = deviceImpl->shader_priv; IWineD3DStateBlockImpl* stateBlock = deviceImpl->stateBlock; - const struct wined3d_gl_info *gl_info = &deviceImpl->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &deviceImpl->adapter->gl_info; GLhandleARB programId; struct glsl_shader_prog_link *prog = priv->glsl_program; @@ -714,12 +683,12 @@ static void shader_glsl_load_constants( if(((IWineD3DPixelShaderImpl *) pshader)->vpos_uniform) { float correction_params[4]; if(deviceImpl->render_offscreen) { - correction_params[0] = 0.0f; - correction_params[1] = 1.0f; + correction_params[0] = 0.0; + correction_params[1] = 1.0; } else { /* position is window relative, not viewport relative */ correction_params[0] = ((IWineD3DSurfaceImpl *) deviceImpl->render_targets[0])->currentDesc.Height; - correction_params[1] = -1.0f; + correction_params[1] = -1.0; } GL_EXTCALL(glUniform4fvARB(prog->ycorrection_location, 1, correction_params)); } @@ -792,25 +761,24 @@ static void shader_glsl_update_float_pixel_constants(IWineD3DDevice *iface, UINT } } -static unsigned int vec4_varyings(DWORD shader_major, const struct wined3d_gl_info *gl_info) +static int vec4_varyings(DWORD shader_major, const WineD3D_GL_Info *gl_info) { - unsigned int ret = GL_LIMITS(glsl_varyings) / 4; + int ret = GL_LIMITS(glsl_varyings) / 4; /* 4.0 shaders do not write clip coords because d3d10 does not support user clipplanes */ if(shader_major > 3) return ret; /* 3.0 shaders may need an extra varying for the clip coord on some cards(mostly dx10 ones) */ - if (gl_info->quirks & WINED3D_QUIRK_GLSL_CLIP_VARYING) ret -= 1; + if(gl_info->glsl_clip_varying) ret -= 1; return ret; } /** Generate the variable & register declarations for the GLSL output target */ static void shader_generate_glsl_declarations(IWineD3DBaseShader *iface, const shader_reg_maps *reg_maps, - struct wined3d_shader_buffer *buffer, const struct wined3d_gl_info *gl_info, - struct shader_glsl_ctx_priv *ctx_priv) + SHADER_BUFFER *buffer, const WineD3D_GL_Info *gl_info, + const struct ps_compile_args *ps_args) { IWineD3DBaseShaderImpl* This = (IWineD3DBaseShaderImpl*) iface; IWineD3DDeviceImpl *device = (IWineD3DDeviceImpl *) This->baseShader.device; - const struct ps_compile_args *ps_args = ctx_priv->cur_ps_args; unsigned int i, extra_constants_needed = 0; const local_constant *lconst; @@ -913,12 +881,11 @@ static void shader_generate_glsl_declarations(IWineD3DBaseShader *iface, const s extra_constants_needed++; } - if (ps_args->srgb_correction) - { - shader_addline(buffer, "const vec4 srgb_const0 = vec4(%.8e, %.8e, %.8e, %.8e);\n", - srgb_pow, srgb_mul_high, srgb_sub_high, srgb_mul_low); - shader_addline(buffer, "const vec4 srgb_const1 = vec4(%.8e, 0.0, 0.0, 0.0);\n", - srgb_cmp); + if(ps_args->srgb_correction) { + shader_addline(buffer, "const vec4 srgb_mul_low = vec4(%f, %f, %f, %f);\n", + srgb_mul_low, srgb_mul_low, srgb_mul_low, srgb_mul_low); + shader_addline(buffer, "const vec4 srgb_comparison = vec4(%f, %f, %f, %f);\n", + srgb_cmp, srgb_cmp, srgb_cmp, srgb_cmp); } if(reg_maps->vpos || reg_maps->usesdsy) { if(This->baseShader.limits.constant_float + extra_constants_needed + 1 < GL_LIMITS(pshader_constantsF)) { @@ -931,8 +898,8 @@ static void shader_generate_glsl_declarations(IWineD3DBaseShader *iface, const s */ FIXME("Cannot find a free uniform for vpos correction params\n"); shader_addline(buffer, "const vec4 ycorrection = vec4(%f, %f, 0.0, 0.0);\n", - device->render_offscreen ? 0.0f : ((IWineD3DSurfaceImpl *)device->render_targets[0])->currentDesc.Height, - device->render_offscreen ? 1.0f : -1.0f); + device->render_offscreen ? 0.0 : ((IWineD3DSurfaceImpl *) device->render_targets[0])->currentDesc.Height, + device->render_offscreen ? 1.0 : -1.0); } shader_addline(buffer, "vec4 vpos;\n"); } @@ -954,6 +921,15 @@ static void shader_generate_glsl_declarations(IWineD3DBaseShader *iface, const s } else { shader_addline(buffer, "uniform sampler2D %csampler%u;\n", prefix, i); } + + if (pshader && ps_args->np2_fixup & (1 << i)) + { + /* NP2/RECT textures in OpenGL use texcoords in the range [0,width]x[0,height] + * while D3D has them in the (normalized) [0,1]x[0,1] range. + * samplerNP2Fixup stores texture dimensions and is updated through + * shader_glsl_load_np2fixup_constants when the sampler changes. */ + shader_addline(buffer, "uniform vec2 %csamplerNP2Fixup%u;\n", prefix, i); + } break; case WINED3DSTT_CUBE: shader_addline(buffer, "uniform samplerCube %csampler%u;\n", prefix, i); @@ -968,38 +944,7 @@ static void shader_generate_glsl_declarations(IWineD3DBaseShader *iface, const s } } } - - /* Declare uniforms for NP2 texcoord fixup: - * This is NOT done inside the loop that declares the texture samplers since the NP2 fixup code - * is currently only used for the GeforceFX series and when forcing the ARB_npot extension off. - * Modern cards just skip the code anyway, so put it inside a seperate loop. */ - if (pshader && ps_args->np2_fixup) { - - struct ps_np2fixup_info* const fixup = ctx_priv->cur_np2fixup_info; - UINT cur = 0; - - /* NP2/RECT textures in OpenGL use texcoords in the range [0,width]x[0,height] - * while D3D has them in the (normalized) [0,1]x[0,1] range. - * samplerNP2Fixup stores texture dimensions and is updated through - * shader_glsl_load_np2fixup_constants when the sampler changes. */ - - for (i = 0; i < This->baseShader.limits.sampler; ++i) { - if (reg_maps->sampler_type[i]) { - if (!(ps_args->np2_fixup & (1 << i))) continue; - - if (WINED3DSTT_2D != reg_maps->sampler_type[i]) { - FIXME("Non-2D texture is flagged for NP2 texcoord fixup.\n"); - continue; - } - - fixup->idx[i] = cur++; - } - } - - fixup->num_consts = (cur + 1) >> 1; - shader_addline(buffer, "uniform vec4 %csamplerNP2Fixup[%u];\n", prefix, fixup->num_consts); - } - + /* Declare address variables */ for (i = 0; i < This->baseShader.limits.address; i++) { if (reg_maps->address[i]) @@ -1185,7 +1130,7 @@ static void shader_glsl_get_register_name(const struct wined3d_shader_register * IWineD3DBaseShaderImpl *This = (IWineD3DBaseShaderImpl *)ins->ctx->shader; IWineD3DDeviceImpl* deviceImpl = (IWineD3DDeviceImpl*) This->baseShader.device; - const struct wined3d_gl_info *gl_info = &deviceImpl->adapter->gl_info; + const WineD3D_GL_Info* gl_info = &deviceImpl->adapter->gl_info; char pshader = shader_is_pshader_version(This->baseShader.reg_maps.shader_version.type); *is_color = FALSE; @@ -1210,7 +1155,7 @@ static void shader_glsl_get_register_name(const struct wined3d_shader_register * if (This->baseShader.reg_maps.shader_version.major >= 3) { DWORD idx = ((IWineD3DPixelShaderImpl *)This)->input_reg_map[reg->idx]; - unsigned int in_count = vec4_varyings(This->baseShader.reg_maps.shader_version.major, gl_info); + DWORD in_count = vec4_varyings(This->baseShader.reg_maps.shader_version.major, gl_info); if (reg->rel_addr) { @@ -1313,7 +1258,9 @@ static void shader_glsl_get_register_name(const struct wined3d_shader_register * if (reg->idx >= GL_LIMITS(buffers)) WARN("Write to render target %u, only %d supported\n", reg->idx, GL_LIMITS(buffers)); - sprintf(register_name, "gl_FragData[%u]", reg->idx); + if (GL_SUPPORT(ARB_DRAW_BUFFERS)) sprintf(register_name, "gl_FragData[%u]", reg->idx); + /* On older cards with GLSL support like the GeforceFX there's only one buffer. */ + else sprintf(register_name, "gl_FragColor"); break; case WINED3DSPR_RASTOUT: @@ -1358,13 +1305,13 @@ static void shader_glsl_get_register_name(const struct wined3d_shader_register * switch (reg->immconst_type) { case WINED3D_IMMCONST_FLOAT: - sprintf(register_name, "%.8e", *(const float *)reg->immconst_data); + sprintf(register_name, "%.8e", *(float *)reg->immconst_data); break; case WINED3D_IMMCONST_FLOAT4: sprintf(register_name, "vec4(%.8e, %.8e, %.8e, %.8e)", - *(const float *)®->immconst_data[0], *(const float *)®->immconst_data[1], - *(const float *)®->immconst_data[2], *(const float *)®->immconst_data[3]); + *(float *)®->immconst_data[0], *(float *)®->immconst_data[1], + *(float *)®->immconst_data[2], *(float *)®->immconst_data[3]); break; default: @@ -1478,7 +1425,7 @@ static DWORD shader_glsl_add_dst_param(const struct wined3d_shader_instruction * } /* Append the destination part of the instruction to the buffer, return the effective write mask */ -static DWORD shader_glsl_append_dst_ext(struct wined3d_shader_buffer *buffer, +static DWORD shader_glsl_append_dst_ext(SHADER_BUFFER *buffer, const struct wined3d_shader_instruction *ins, const struct wined3d_shader_dst_param *dst) { glsl_dst_param_t glsl_dst; @@ -1491,7 +1438,7 @@ static DWORD shader_glsl_append_dst_ext(struct wined3d_shader_buffer *buffer, } /* Append the destination part of the instruction to the buffer, return the effective write mask */ -static DWORD shader_glsl_append_dst(struct wined3d_shader_buffer *buffer, const struct wined3d_shader_instruction *ins) +static DWORD shader_glsl_append_dst(SHADER_BUFFER *buffer, const struct wined3d_shader_instruction *ins) { return shader_glsl_append_dst_ext(buffer, ins, &ins->dst[0]); } @@ -1733,7 +1680,7 @@ static void PRINTF_ATTR(8, 9) shader_glsl_gen_sample_code(const struct wined3d_s if (shader_is_pshader_version(ins->ctx->reg_maps->shader_version.type)) { - const struct shader_glsl_ctx_priv *priv = ins->ctx->backend_data; + struct shader_glsl_ctx_priv *priv = ins->ctx->backend_data; fixup = priv->cur_ps_args->color_fixup[sampler]; sampler_base = "Psampler"; @@ -1761,11 +1708,7 @@ static void PRINTF_ATTR(8, 9) shader_glsl_gen_sample_code(const struct wined3d_s shader_addline(ins->ctx->buffer, ", %s)%s);\n", bias, dst_swizzle); } else { if (np2_fixup) { - const struct shader_glsl_ctx_priv *priv = ins->ctx->backend_data; - const unsigned char idx = priv->cur_np2fixup_info->idx[sampler]; - - shader_addline(ins->ctx->buffer, " * PsamplerNP2Fixup[%u].%s)%s);\n", idx >> 1, - (idx % 2) ? "zw" : "xy", dst_swizzle); + shader_addline(ins->ctx->buffer, " * PsamplerNP2Fixup%u)%s);\n", sampler, dst_swizzle); } else if(dx && dy) { shader_addline(ins->ctx->buffer, ", %s, %s)%s);\n", dx, dy, dst_swizzle); } else { @@ -1787,7 +1730,7 @@ static void PRINTF_ATTR(8, 9) shader_glsl_gen_sample_code(const struct wined3d_s /* Generate GLSL arithmetic functions (dst = src1 + src2) */ static void shader_glsl_arith(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; glsl_src_param_t src0_param; glsl_src_param_t src1_param; DWORD write_mask; @@ -1814,7 +1757,7 @@ static void shader_glsl_arith(const struct wined3d_shader_instruction *ins) /* Process the WINED3DSIO_MOV opcode using GLSL (dst = src) */ static void shader_glsl_mov(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; glsl_src_param_t src0_param; DWORD write_mask; @@ -1852,7 +1795,7 @@ static void shader_glsl_mov(const struct wined3d_shader_instruction *ins) /* Process the dot product operators DP3 and DP4 in GLSL (dst = dot(src0, src1)) */ static void shader_glsl_dot(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; glsl_src_param_t src0_param; glsl_src_param_t src1_param; DWORD dst_write_mask, src_write_mask; @@ -1900,7 +1843,7 @@ static void shader_glsl_cross(const struct wined3d_shader_instruction *ins) * GLSL uses the value as-is. */ static void shader_glsl_pow(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; glsl_src_param_t src0_param; glsl_src_param_t src1_param; DWORD dst_write_mask; @@ -1924,7 +1867,7 @@ static void shader_glsl_pow(const struct wined3d_shader_instruction *ins) * GLSL uses the value as-is. */ static void shader_glsl_log(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; glsl_src_param_t src0_param; DWORD dst_write_mask; unsigned int dst_size; @@ -1944,7 +1887,7 @@ static void shader_glsl_log(const struct wined3d_shader_instruction *ins) /* Map the opcode 1-to-1 to the GL code (arg->dst = instruction(src0, src1, ...) */ static void shader_glsl_map2gl(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; glsl_src_param_t src_param; const char *instruction; DWORD write_mask; @@ -2048,7 +1991,7 @@ static void shader_glsl_rcp(const struct wined3d_shader_instruction *ins) static void shader_glsl_rsq(const struct wined3d_shader_instruction *ins) { - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; glsl_src_param_t src_param; DWORD write_mask; unsigned int mask_size; @@ -2626,13 +2569,6 @@ static void shader_glsl_callnz(const struct wined3d_shader_instruction *ins) shader_addline(ins->ctx->buffer, "if (%s) subroutine%u();\n", src1_param.param_str, ins->src[0].reg.idx); } -static void shader_glsl_ret(const struct wined3d_shader_instruction *ins) -{ - /* No-op. The closing } is written when a new function is started, and at the end of the shader. This - * function only suppresses the unhandled instruction warning - */ -} - /********************************************* * Pixel Shader Specific Code begins here ********************************************/ @@ -2729,7 +2665,7 @@ static void shader_glsl_texldd(const struct wined3d_shader_instruction *ins) { IWineD3DBaseShaderImpl *This = (IWineD3DBaseShaderImpl *)ins->ctx->shader; IWineD3DDeviceImpl* deviceImpl = (IWineD3DDeviceImpl*) This->baseShader.device; - const struct wined3d_gl_info *gl_info = &deviceImpl->adapter->gl_info; + const WineD3D_GL_Info* gl_info = &deviceImpl->adapter->gl_info; glsl_sample_function_t sample_function; glsl_src_param_t coord_param, dx_param, dy_param; DWORD sample_flags = WINED3D_GLSL_SAMPLE_GRAD; @@ -2793,7 +2729,7 @@ static void shader_glsl_texldl(const struct wined3d_shader_instruction *ins) static void pshader_glsl_texcoord(const struct wined3d_shader_instruction *ins) { /* FIXME: Make this work for more than just 2D textures */ - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; DWORD write_mask = shader_glsl_append_dst(ins->ctx->buffer, ins); if (!(ins->ctx->reg_maps->shader_version.major == 1 && ins->ctx->reg_maps->shader_version.minor == 4)) @@ -2943,7 +2879,7 @@ static void pshader_glsl_texm3x2pad(const struct wined3d_shader_instruction *ins { DWORD src_mask = WINED3DSP_WRITEMASK_0 | WINED3DSP_WRITEMASK_1 | WINED3DSP_WRITEMASK_2; DWORD reg = ins->dst[0].reg.idx; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; glsl_src_param_t src0_param; shader_glsl_add_src_param(ins, &ins->src[0], src_mask, &src0_param); @@ -2957,7 +2893,7 @@ static void pshader_glsl_texm3x3pad(const struct wined3d_shader_instruction *ins IWineD3DPixelShaderImpl *shader = (IWineD3DPixelShaderImpl *)ins->ctx->shader; DWORD src_mask = WINED3DSP_WRITEMASK_0 | WINED3DSP_WRITEMASK_1 | WINED3DSP_WRITEMASK_2; DWORD reg = ins->dst[0].reg.idx; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; SHADER_PARSE_STATE* current_state = &shader->baseShader.parse_state; glsl_src_param_t src0_param; @@ -2970,7 +2906,7 @@ static void pshader_glsl_texm3x2tex(const struct wined3d_shader_instruction *ins { DWORD src_mask = WINED3DSP_WRITEMASK_0 | WINED3DSP_WRITEMASK_1 | WINED3DSP_WRITEMASK_2; DWORD reg = ins->dst[0].reg.idx; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; glsl_src_param_t src0_param; WINED3DSAMPLER_TEXTURE_TYPE sampler_type = ins->ctx->reg_maps->sampler_type[reg]; glsl_sample_function_t sample_function; @@ -3036,7 +2972,7 @@ static void pshader_glsl_texm3x3spec(const struct wined3d_shader_instruction *in DWORD reg = ins->dst[0].reg.idx; glsl_src_param_t src0_param; glsl_src_param_t src1_param; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; SHADER_PARSE_STATE* current_state = &shader->baseShader.parse_state; WINED3DSAMPLER_TEXTURE_TYPE stype = ins->ctx->reg_maps->sampler_type[reg]; DWORD src_mask = WINED3DSP_WRITEMASK_0 | WINED3DSP_WRITEMASK_1 | WINED3DSP_WRITEMASK_2; @@ -3065,7 +3001,7 @@ static void pshader_glsl_texm3x3vspec(const struct wined3d_shader_instruction *i { IWineD3DPixelShaderImpl *shader = (IWineD3DPixelShaderImpl *)ins->ctx->shader; DWORD reg = ins->dst[0].reg.idx; - struct wined3d_shader_buffer *buffer = ins->ctx->buffer; + SHADER_BUFFER *buffer = ins->ctx->buffer; SHADER_PARSE_STATE* current_state = &shader->baseShader.parse_state; glsl_src_param_t src0_param; DWORD src_mask = WINED3DSP_WRITEMASK_0 | WINED3DSP_WRITEMASK_1 | WINED3DSP_WRITEMASK_2; @@ -3263,7 +3199,7 @@ static void pshader_glsl_dp2add(const struct wined3d_shader_instruction *ins) } } -static void pshader_glsl_input_pack(IWineD3DPixelShader *iface, struct wined3d_shader_buffer *buffer, +static void pshader_glsl_input_pack(IWineD3DPixelShader *iface, SHADER_BUFFER *buffer, const struct wined3d_shader_signature_element *input_signature, const struct shader_reg_maps *reg_maps, enum vertexprocessing_mode vertexprocessing) { @@ -3347,7 +3283,7 @@ static struct glsl_shader_prog_link *get_glsl_program_entry(struct shader_glsl_p } /* GL locking is done by the caller */ -static void delete_glsl_program_entry(struct shader_glsl_priv *priv, const struct wined3d_gl_info *gl_info, +static void delete_glsl_program_entry(struct shader_glsl_priv *priv, const WineD3D_GL_Info *gl_info, struct glsl_shader_prog_link *entry) { glsl_program_key_t key; @@ -3366,7 +3302,7 @@ static void delete_glsl_program_entry(struct shader_glsl_priv *priv, const struc HeapFree(GetProcessHeap(), 0, entry); } -static void handle_ps3_input(struct wined3d_shader_buffer *buffer, const struct wined3d_gl_info *gl_info, const DWORD *map, +static void handle_ps3_input(SHADER_BUFFER *buffer, const WineD3D_GL_Info *gl_info, const DWORD *map, const struct wined3d_shader_signature_element *input_signature, const struct shader_reg_maps *reg_maps_in, const struct wined3d_shader_signature_element *output_signature, const struct shader_reg_maps *reg_maps_out) { @@ -3375,7 +3311,7 @@ static void handle_ps3_input(struct wined3d_shader_buffer *buffer, const struct UINT semantic_idx_in, semantic_idx_out; DWORD *set; DWORD in_idx; - unsigned int in_count = vec4_varyings(3, gl_info); + DWORD in_count = vec4_varyings(3, gl_info); char reg_mask[6], reg_mask_out[6]; char destination[50]; WORD input_map, output_map; @@ -3528,8 +3464,8 @@ static void handle_ps3_input(struct wined3d_shader_buffer *buffer, const struct } /* GL locking is done by the caller */ -static GLhandleARB generate_param_reorder_function(struct wined3d_shader_buffer *buffer, - IWineD3DVertexShader *vertexshader, IWineD3DPixelShader *pixelshader, const struct wined3d_gl_info *gl_info) +static GLhandleARB generate_param_reorder_function(IWineD3DVertexShader *vertexshader, + IWineD3DPixelShader *pixelshader, const WineD3D_GL_Info *gl_info) { GLhandleARB ret = 0; IWineD3DVertexShaderImpl *vs = (IWineD3DVertexShaderImpl *) vertexshader; @@ -3538,33 +3474,33 @@ static GLhandleARB generate_param_reorder_function(struct wined3d_shader_buffer DWORD vs_major = vs->baseShader.reg_maps.shader_version.major; DWORD ps_major = ps ? ps->baseShader.reg_maps.shader_version.major : 0; unsigned int i; + SHADER_BUFFER buffer; const char *semantic_name; UINT semantic_idx; char reg_mask[6]; const struct wined3d_shader_signature_element *output_signature; - shader_buffer_clear(buffer); + shader_buffer_init(&buffer); - shader_addline(buffer, "#version 120\n"); + shader_addline(&buffer, "#version 120\n"); if(vs_major < 3 && ps_major < 3) { /* That one is easy: The vertex shader writes to the builtin varyings, the pixel shader reads from them. * Take care about the texcoord .w fixup though if we're using the fixed function fragment pipeline */ device = (IWineD3DDeviceImpl *) vs->baseShader.device; - if (((GLINFO_LOCATION).quirks & WINED3D_QUIRK_SET_TEXCOORD_W) - && ps_major == 0 && vs_major > 0 && !device->frag_pipe->ffp_proj_control) - { - shader_addline(buffer, "void order_ps_input() {\n"); + if((GLINFO_LOCATION).set_texcoord_w && ps_major == 0 && vs_major > 0 && + !device->frag_pipe->ffp_proj_control) { + shader_addline(&buffer, "void order_ps_input() {\n"); for(i = 0; i < min(8, MAX_REG_TEXCRD); i++) { if(vs->baseShader.reg_maps.texcoord_mask[i] != 0 && vs->baseShader.reg_maps.texcoord_mask[i] != WINED3DSP_WRITEMASK_ALL) { - shader_addline(buffer, "gl_TexCoord[%u].w = 1.0;\n", i); + shader_addline(&buffer, "gl_TexCoord[%u].w = 1.0;\n", i); } } - shader_addline(buffer, "}\n"); + shader_addline(&buffer, "}\n"); } else { - shader_addline(buffer, "void order_ps_input() { /* do nothing */ }\n"); + shader_addline(&buffer, "void order_ps_input() { /* do nothing */ }\n"); } } else if(ps_major < 3 && vs_major >= 3) { WORD map = vs->baseShader.reg_maps.output_registers; @@ -3572,7 +3508,7 @@ static GLhandleARB generate_param_reorder_function(struct wined3d_shader_buffer /* The vertex shader writes to its own varyings, the pixel shader needs them in the builtin ones */ output_signature = vs->output_signature; - shader_addline(buffer, "void order_ps_input(in vec4 OUT[%u]) {\n", MAX_REG_OUTPUT); + shader_addline(&buffer, "void order_ps_input(in vec4 OUT[%u]) {\n", MAX_REG_OUTPUT); for (i = 0; map; map >>= 1, ++i) { DWORD write_mask; @@ -3587,37 +3523,36 @@ static GLhandleARB generate_param_reorder_function(struct wined3d_shader_buffer if (shader_match_semantic(semantic_name, WINED3DDECLUSAGE_COLOR)) { if (semantic_idx == 0) - shader_addline(buffer, "gl_FrontColor%s = OUT[%u]%s;\n", reg_mask, i, reg_mask); + shader_addline(&buffer, "gl_FrontColor%s = OUT[%u]%s;\n", reg_mask, i, reg_mask); else if (semantic_idx == 1) - shader_addline(buffer, "gl_FrontSecondaryColor%s = OUT[%u]%s;\n", reg_mask, i, reg_mask); + shader_addline(&buffer, "gl_FrontSecondaryColor%s = OUT[%u]%s;\n", reg_mask, i, reg_mask); } else if (shader_match_semantic(semantic_name, WINED3DDECLUSAGE_POSITION)) { - shader_addline(buffer, "gl_Position%s = OUT[%u]%s;\n", reg_mask, i, reg_mask); + shader_addline(&buffer, "gl_Position%s = OUT[%u]%s;\n", reg_mask, i, reg_mask); } else if (shader_match_semantic(semantic_name, WINED3DDECLUSAGE_TEXCOORD)) { if (semantic_idx < 8) { - if (!((GLINFO_LOCATION).quirks & WINED3D_QUIRK_SET_TEXCOORD_W) || ps_major > 0) - write_mask |= WINED3DSP_WRITEMASK_3; + if (!(GLINFO_LOCATION).set_texcoord_w || ps_major > 0) write_mask |= WINED3DSP_WRITEMASK_3; - shader_addline(buffer, "gl_TexCoord[%u]%s = OUT[%u]%s;\n", + shader_addline(&buffer, "gl_TexCoord[%u]%s = OUT[%u]%s;\n", semantic_idx, reg_mask, i, reg_mask); if (!(write_mask & WINED3DSP_WRITEMASK_3)) - shader_addline(buffer, "gl_TexCoord[%u].w = 1.0;\n", semantic_idx); + shader_addline(&buffer, "gl_TexCoord[%u].w = 1.0;\n", semantic_idx); } } else if (shader_match_semantic(semantic_name, WINED3DDECLUSAGE_PSIZE)) { - shader_addline(buffer, "gl_PointSize = OUT[%u].x;\n", i); + shader_addline(&buffer, "gl_PointSize = OUT[%u].x;\n", i); } else if (shader_match_semantic(semantic_name, WINED3DDECLUSAGE_FOG)) { - shader_addline(buffer, "gl_FogFragCoord = OUT[%u].%c;\n", i, reg_mask[1]); + shader_addline(&buffer, "gl_FogFragCoord = OUT[%u].%c;\n", i, reg_mask[1]); } } - shader_addline(buffer, "}\n"); + shader_addline(&buffer, "}\n"); } else if(ps_major >= 3 && vs_major >= 3) { WORD map = vs->baseShader.reg_maps.output_registers; @@ -3625,8 +3560,8 @@ static GLhandleARB generate_param_reorder_function(struct wined3d_shader_buffer output_signature = vs->output_signature; /* This one is tricky: a 3.0 pixel shader reads from a 3.0 vertex shader */ - shader_addline(buffer, "varying vec4 IN[%u];\n", vec4_varyings(3, gl_info)); - shader_addline(buffer, "void order_ps_input(in vec4 OUT[%u]) {\n", MAX_REG_OUTPUT); + shader_addline(&buffer, "varying vec4 IN[%u];\n", vec4_varyings(3, gl_info)); + shader_addline(&buffer, "void order_ps_input(in vec4 OUT[%u]) {\n", MAX_REG_OUTPUT); /* First, sort out position and point size. Those are not passed to the pixel shader */ for (i = 0; map; map >>= 1, ++i) @@ -3638,45 +3573,46 @@ static GLhandleARB generate_param_reorder_function(struct wined3d_shader_buffer if (shader_match_semantic(semantic_name, WINED3DDECLUSAGE_POSITION)) { - shader_addline(buffer, "gl_Position%s = OUT[%u]%s;\n", reg_mask, i, reg_mask); + shader_addline(&buffer, "gl_Position%s = OUT[%u]%s;\n", reg_mask, i, reg_mask); } else if (shader_match_semantic(semantic_name, WINED3DDECLUSAGE_PSIZE)) { - shader_addline(buffer, "gl_PointSize = OUT[%u].x;\n", i); + shader_addline(&buffer, "gl_PointSize = OUT[%u].x;\n", i); } } /* Then, fix the pixel shader input */ - handle_ps3_input(buffer, gl_info, ps->input_reg_map, ps->input_signature, + handle_ps3_input(&buffer, gl_info, ps->input_reg_map, ps->input_signature, &ps->baseShader.reg_maps, output_signature, &vs->baseShader.reg_maps); - shader_addline(buffer, "}\n"); + shader_addline(&buffer, "}\n"); } else if(ps_major >= 3 && vs_major < 3) { - shader_addline(buffer, "varying vec4 IN[%u];\n", vec4_varyings(3, gl_info)); - shader_addline(buffer, "void order_ps_input() {\n"); + shader_addline(&buffer, "varying vec4 IN[%u];\n", vec4_varyings(3, gl_info)); + shader_addline(&buffer, "void order_ps_input() {\n"); /* The vertex shader wrote to the builtin varyings. There is no need to figure out position and * point size, but we depend on the optimizers kindness to find out that the pixel shader doesn't * read gl_TexCoord and gl_ColorX, otherwise we'll run out of varyings */ - handle_ps3_input(buffer, gl_info, ps->input_reg_map, ps->input_signature, + handle_ps3_input(&buffer, gl_info, ps->input_reg_map, ps->input_signature, &ps->baseShader.reg_maps, NULL, NULL); - shader_addline(buffer, "}\n"); + shader_addline(&buffer, "}\n"); } else { ERR("Unexpected vertex and pixel shader version condition: vs: %d, ps: %d\n", vs_major, ps_major); } ret = GL_EXTCALL(glCreateShaderObjectARB(GL_VERTEX_SHADER_ARB)); checkGLcall("glCreateShaderObjectARB(GL_VERTEX_SHADER_ARB)"); - GL_EXTCALL(glShaderSourceARB(ret, 1, (const char**)&buffer->buffer, NULL)); - checkGLcall("glShaderSourceARB(ret, 1, &buffer->buffer, NULL)"); + GL_EXTCALL(glShaderSourceARB(ret, 1, (const char**)&buffer.buffer, NULL)); + checkGLcall("glShaderSourceARB(ret, 1, &buffer.buffer, NULL)"); GL_EXTCALL(glCompileShaderARB(ret)); checkGLcall("glCompileShaderARB(ret)"); + shader_buffer_free(&buffer); return ret; } /* GL locking is done by the caller */ -static void hardcode_local_constants(IWineD3DBaseShaderImpl *shader, const struct wined3d_gl_info *gl_info, +static void hardcode_local_constants(IWineD3DBaseShaderImpl *shader, const WineD3D_GL_Info *gl_info, GLhandleARB programId, char prefix) { const local_constant *lconst; @@ -3690,16 +3626,17 @@ static void hardcode_local_constants(IWineD3DBaseShaderImpl *shader, const struc tmp_loc = GL_EXTCALL(glGetUniformLocationARB(programId, glsl_name)); GL_EXTCALL(glUniform4fvARB(tmp_loc, 1, value)); } - checkGLcall("Hardcoding local constants"); + checkGLcall("Hardcoding local constants\n"); } /* GL locking is done by the caller */ -static GLuint shader_glsl_generate_pshader(IWineD3DPixelShaderImpl *This, struct wined3d_shader_buffer *buffer, - const struct ps_compile_args *args, struct ps_np2fixup_info *np2fixup_info) +static GLuint shader_glsl_generate_pshader(IWineD3DPixelShaderImpl *This, + SHADER_BUFFER *buffer, const struct ps_compile_args *args) { const struct shader_reg_maps *reg_maps = &This->baseShader.reg_maps; CONST DWORD *function = This->baseShader.function; - const struct wined3d_gl_info *gl_info = &((IWineD3DDeviceImpl *)This->baseShader.device)->adapter->gl_info; + const char *fragcolor; + const WineD3D_GL_Info *gl_info = &((IWineD3DDeviceImpl *)This->baseShader.device)->adapter->gl_info; struct shader_glsl_ctx_priv priv_ctx; /* Create the hw GLSL shader object and assign it as the shader->prgId */ @@ -3707,10 +3644,12 @@ static GLuint shader_glsl_generate_pshader(IWineD3DPixelShaderImpl *This, struct memset(&priv_ctx, 0, sizeof(priv_ctx)); priv_ctx.cur_ps_args = args; - priv_ctx.cur_np2fixup_info = np2fixup_info; shader_addline(buffer, "#version 120\n"); + if (GL_SUPPORT(ARB_DRAW_BUFFERS)) { + shader_addline(buffer, "#extension GL_ARB_draw_buffers : enable\n"); + } if(GL_SUPPORT(ARB_SHADER_TEXTURE_LOD) && reg_maps->usestexldd) { shader_addline(buffer, "#extension GL_ARB_shader_texture_lod : enable\n"); } @@ -3722,7 +3661,7 @@ static GLuint shader_glsl_generate_pshader(IWineD3DPixelShaderImpl *This, struct } /* Base Declarations */ - shader_generate_glsl_declarations( (IWineD3DBaseShader*) This, reg_maps, buffer, &GLINFO_LOCATION, &priv_ctx); + shader_generate_glsl_declarations( (IWineD3DBaseShader*) This, reg_maps, buffer, &GLINFO_LOCATION, args); /* Pack 3.0 inputs */ if (reg_maps->shader_version.major >= 3 && args->vp_mode != vertexshader) @@ -3737,17 +3676,26 @@ static GLuint shader_glsl_generate_pshader(IWineD3DPixelShaderImpl *This, struct if (reg_maps->shader_version.major < 2) { /* Some older cards like GeforceFX ones don't support multiple buffers, so also not gl_FragData */ - shader_addline(buffer, "gl_FragData[0] = R0;\n"); + if(GL_SUPPORT(ARB_DRAW_BUFFERS)) + shader_addline(buffer, "gl_FragData[0] = R0;\n"); + else + shader_addline(buffer, "gl_FragColor = R0;\n"); } - if (args->srgb_correction) - { - shader_addline(buffer, "tmp0.xyz = pow(gl_FragData[0].xyz, vec3(srgb_const0.x));\n"); - shader_addline(buffer, "tmp0.xyz = tmp0.xyz * vec3(srgb_const0.y) - vec3(srgb_const0.z);\n"); - shader_addline(buffer, "tmp1.xyz = gl_FragData[0].xyz * vec3(srgb_const0.w);\n"); - shader_addline(buffer, "bvec3 srgb_compare = lessThan(gl_FragData[0].xyz, vec3(srgb_const1.x));\n"); - shader_addline(buffer, "gl_FragData[0].xyz = mix(tmp0.xyz, tmp1.xyz, vec3(srgb_compare));\n"); - shader_addline(buffer, "gl_FragData[0] = clamp(gl_FragData[0], 0.0, 1.0);\n"); + if(GL_SUPPORT(ARB_DRAW_BUFFERS)) { + fragcolor = "gl_FragData[0]"; + } else { + fragcolor = "gl_FragColor"; + } + if(args->srgb_correction) { + shader_addline(buffer, "tmp0.xyz = pow(%s.xyz, vec3(%f, %f, %f)) * vec3(%f, %f, %f) - vec3(%f, %f, %f);\n", + fragcolor, srgb_pow, srgb_pow, srgb_pow, srgb_mul_high, srgb_mul_high, srgb_mul_high, + srgb_sub_high, srgb_sub_high, srgb_sub_high); + shader_addline(buffer, "tmp1.xyz = %s.xyz * srgb_mul_low.xyz;\n", fragcolor); + shader_addline(buffer, "%s.x = %s.x < srgb_comparison.x ? tmp1.x : tmp0.x;\n", fragcolor, fragcolor); + shader_addline(buffer, "%s.y = %s.y < srgb_comparison.y ? tmp1.y : tmp0.y;\n", fragcolor, fragcolor); + shader_addline(buffer, "%s.z = %s.z < srgb_comparison.z ? tmp1.z : tmp0.z;\n", fragcolor, fragcolor); + shader_addline(buffer, "%s = clamp(%s, 0.0, 1.0);\n", fragcolor, fragcolor); } /* Pixel shader < 3.0 do not replace the fog stage. * This implements linear fog computation and blending. @@ -3763,19 +3711,19 @@ static GLuint shader_glsl_generate_pshader(IWineD3DPixelShaderImpl *This, struct shader_addline(buffer, "float fogstart = -1.0 / (gl_Fog.end - gl_Fog.start);\n"); shader_addline(buffer, "float fogend = gl_Fog.end * -fogstart;\n"); shader_addline(buffer, "float Fog = clamp(gl_FogFragCoord * fogstart + fogend, 0.0, 1.0);\n"); - shader_addline(buffer, "gl_FragData[0].xyz = mix(gl_Fog.color.xyz, gl_FragData[0].xyz, Fog);\n"); + shader_addline(buffer, "%s.xyz = mix(gl_Fog.color.xyz, %s.xyz, Fog);\n", fragcolor, fragcolor); break; case FOG_EXP: /* Fog = e^(-gl_Fog.density * gl_FogFragCoord) */ shader_addline(buffer, "float Fog = exp(-gl_Fog.density * gl_FogFragCoord);\n"); shader_addline(buffer, "Fog = clamp(Fog, 0.0, 1.0);\n"); - shader_addline(buffer, "gl_FragData[0].xyz = mix(gl_Fog.color.xyz, gl_FragData[0].xyz, Fog);\n"); + shader_addline(buffer, "%s.xyz = mix(gl_Fog.color.xyz, %s.xyz, Fog);\n", fragcolor, fragcolor); break; case FOG_EXP2: /* Fog = e^(-(gl_Fog.density * gl_FogFragCoord)^2) */ shader_addline(buffer, "float Fog = exp(-gl_Fog.density * gl_Fog.density * gl_FogFragCoord * gl_FogFragCoord);\n"); shader_addline(buffer, "Fog = clamp(Fog, 0.0, 1.0);\n"); - shader_addline(buffer, "gl_FragData[0].xyz = mix(gl_Fog.color.xyz, gl_FragData[0].xyz, Fog);\n"); + shader_addline(buffer, "%s.xyz = mix(gl_Fog.color.xyz, %s.xyz, Fog);\n", fragcolor, fragcolor); break; } } @@ -3793,11 +3741,11 @@ static GLuint shader_glsl_generate_pshader(IWineD3DPixelShaderImpl *This, struct /* GL locking is done by the caller */ static GLuint shader_glsl_generate_vshader(IWineD3DVertexShaderImpl *This, - struct wined3d_shader_buffer *buffer, const struct vs_compile_args *args) + SHADER_BUFFER *buffer, const struct vs_compile_args *args) { const struct shader_reg_maps *reg_maps = &This->baseShader.reg_maps; CONST DWORD *function = This->baseShader.function; - const struct wined3d_gl_info *gl_info = &((IWineD3DDeviceImpl *)This->baseShader.device)->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &((IWineD3DDeviceImpl *)This->baseShader.device)->adapter->gl_info; struct shader_glsl_ctx_priv priv_ctx; /* Create the hw GLSL shader program and assign it as the shader->prgId */ @@ -3809,7 +3757,7 @@ static GLuint shader_glsl_generate_vshader(IWineD3DVertexShaderImpl *This, priv_ctx.cur_vs_args = args; /* Base Declarations */ - shader_generate_glsl_declarations( (IWineD3DBaseShader*) This, reg_maps, buffer, &GLINFO_LOCATION, &priv_ctx); + shader_generate_glsl_declarations( (IWineD3DBaseShader*) This, reg_maps, buffer, &GLINFO_LOCATION, NULL); /* Base Shader Body */ shader_generate_main((IWineD3DBaseShader*)This, buffer, reg_maps, function, &priv_ctx); @@ -3858,14 +3806,13 @@ static GLuint shader_glsl_generate_vshader(IWineD3DVertexShaderImpl *This, return shader_obj; } -static GLhandleARB find_glsl_pshader(struct wined3d_shader_buffer *buffer, IWineD3DPixelShaderImpl *shader, - const struct ps_compile_args *args, const struct ps_np2fixup_info **np2fixup_info) +static GLhandleARB find_glsl_pshader(IWineD3DPixelShaderImpl *shader, const struct ps_compile_args *args) { UINT i; DWORD new_size; struct glsl_ps_compiled_shader *new_array; - struct glsl_pshader_private *shader_data; - struct ps_np2fixup_info *np2fixup = NULL; + SHADER_BUFFER buffer; + struct glsl_pshader_private *shader_data; GLhandleARB ret; if(!shader->backend_priv) { @@ -3879,12 +3826,11 @@ static GLhandleARB find_glsl_pshader(struct wined3d_shader_buffer *buffer, IWine */ for(i = 0; i < shader_data->num_gl_shaders; i++) { if(memcmp(&shader_data->gl_shaders[i].args, args, sizeof(*args)) == 0) { - if(args->np2_fixup) *np2fixup_info = &shader_data->gl_shaders[i].np2fixup; return shader_data->gl_shaders[i].prgId; } } - TRACE("No matching GL shader found for shader %p, compiling a new shader.\n", shader); + TRACE("No matching GL shader found, compiling a new shader\n"); if(shader_data->shader_array_size == shader_data->num_gl_shaders) { if (shader_data->num_gl_shaders) { @@ -3906,16 +3852,13 @@ static GLhandleARB find_glsl_pshader(struct wined3d_shader_buffer *buffer, IWine shader_data->gl_shaders[shader_data->num_gl_shaders].args = *args; - memset(&shader_data->gl_shaders[shader_data->num_gl_shaders].np2fixup, 0, sizeof(struct ps_np2fixup_info)); - if (args->np2_fixup) np2fixup = &shader_data->gl_shaders[shader_data->num_gl_shaders].np2fixup; - pixelshader_update_samplers(&shader->baseShader.reg_maps, ((IWineD3DDeviceImpl *)shader->baseShader.device)->stateBlock->textures); - shader_buffer_clear(buffer); - ret = shader_glsl_generate_pshader(shader, buffer, args, np2fixup); + shader_buffer_init(&buffer); + ret = shader_glsl_generate_pshader(shader, &buffer, args); + shader_buffer_free(&buffer); shader_data->gl_shaders[shader_data->num_gl_shaders++].prgId = ret; - *np2fixup_info = np2fixup; return ret; } @@ -3926,13 +3869,13 @@ static inline BOOL vs_args_equal(const struct vs_compile_args *stored, const str return stored->fog_src == new->fog_src; } -static GLhandleARB find_glsl_vshader(struct wined3d_shader_buffer *buffer, IWineD3DVertexShaderImpl *shader, - const struct vs_compile_args *args) +static GLhandleARB find_glsl_vshader(IWineD3DVertexShaderImpl *shader, const struct vs_compile_args *args) { UINT i; DWORD new_size; struct glsl_vs_compiled_shader *new_array; DWORD use_map = ((IWineD3DDeviceImpl *)shader->baseShader.device)->strided_streams.use_map; + SHADER_BUFFER buffer; struct glsl_vshader_private *shader_data; GLhandleARB ret; @@ -3951,7 +3894,7 @@ static GLhandleARB find_glsl_vshader(struct wined3d_shader_buffer *buffer, IWine } } - TRACE("No matching GL shader found for shader %p, compiling a new shader.\n", shader); + TRACE("No matching GL shader found, compiling a new shader\n"); if(shader_data->shader_array_size == shader_data->num_gl_shaders) { if (shader_data->num_gl_shaders) @@ -3974,8 +3917,9 @@ static GLhandleARB find_glsl_vshader(struct wined3d_shader_buffer *buffer, IWine shader_data->gl_shaders[shader_data->num_gl_shaders].args = *args; - shader_buffer_clear(buffer); - ret = shader_glsl_generate_vshader(shader, buffer, args); + shader_buffer_init(&buffer); + ret = shader_glsl_generate_vshader(shader, &buffer, args); + shader_buffer_free(&buffer); shader_data->gl_shaders[shader_data->num_gl_shaders++].prgId = ret; return ret; @@ -3994,7 +3938,7 @@ static GLhandleARB find_glsl_vshader(struct wined3d_shader_buffer *buffer, IWine static void set_glsl_shader_program(IWineD3DDevice *iface, BOOL use_ps, BOOL use_vs) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; struct shader_glsl_priv *priv = This->shader_priv; - const struct wined3d_gl_info *gl_info = &This->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &This->adapter->gl_info; IWineD3DPixelShader *pshader = use_ps ? This->stateBlock->pixelShader : NULL; IWineD3DVertexShader *vshader = use_vs ? This->stateBlock->vertexShader : NULL; struct glsl_shader_prog_link *entry = NULL; @@ -4026,7 +3970,6 @@ static void set_glsl_shader_program(IWineD3DDevice *iface, BOOL use_ps, BOOL use entry->vs_args = vs_compile_args; entry->ps_args = ps_compile_args; entry->constant_version = 0; - entry->np2Fixup_info = NULL; /* Add the hash table entry */ add_glsl_program_entry(priv, entry); @@ -4036,12 +3979,11 @@ static void set_glsl_shader_program(IWineD3DDevice *iface, BOOL use_ps, BOOL use /* Attach GLSL vshader */ if (vshader) { - GLhandleARB vshader_id = find_glsl_vshader(&priv->shader_buffer, (IWineD3DVertexShaderImpl *)vshader, - &vs_compile_args); + GLhandleARB vshader_id = find_glsl_vshader((IWineD3DVertexShaderImpl *)vshader, &vs_compile_args); WORD map = ((IWineD3DBaseShaderImpl *)vshader)->baseShader.reg_maps.input_registers; char tmp_name[10]; - reorder_shader_id = generate_param_reorder_function(&priv->shader_buffer, vshader, pshader, gl_info); + reorder_shader_id = generate_param_reorder_function(vshader, pshader, gl_info); TRACE("Attaching GLSL shader object %u to program %u\n", reorder_shader_id, programId); GL_EXTCALL(glAttachObjectARB(programId, reorder_shader_id)); checkGLcall("glAttachObjectARB"); @@ -4078,8 +4020,7 @@ static void set_glsl_shader_program(IWineD3DDevice *iface, BOOL use_ps, BOOL use /* Attach GLSL pshader */ if (pshader) { - GLhandleARB pshader_id = find_glsl_pshader(&priv->shader_buffer, (IWineD3DPixelShaderImpl *)pshader, - &ps_compile_args, &entry->np2Fixup_info); + GLhandleARB pshader_id = find_glsl_pshader((IWineD3DPixelShaderImpl *)pshader, &ps_compile_args); TRACE("Attaching GLSL shader object %u to program %u\n", pshader_id, programId); GL_EXTCALL(glAttachObjectARB(programId, pshader_id)); checkGLcall("glAttachObjectARB"); @@ -4113,6 +4054,7 @@ static void set_glsl_shader_program(IWineD3DDevice *iface, BOOL use_ps, BOOL use if(pshader) { char name[32]; + WORD map; for(i = 0; i < MAX_TEXTURES; i++) { sprintf(name, "bumpenvmat%u", i); @@ -4123,12 +4065,13 @@ static void set_glsl_shader_program(IWineD3DDevice *iface, BOOL use_ps, BOOL use entry->luminanceoffset_location[i] = GL_EXTCALL(glGetUniformLocationARB(programId, name)); } - if (ps_compile_args.np2_fixup) { - if (entry->np2Fixup_info) { - entry->np2Fixup_location = GL_EXTCALL(glGetUniformLocationARB(programId, "PsamplerNP2Fixup")); - } else { - FIXME("NP2 texcoord fixup needed for this pixelshader, but no fixup uniform found.\n"); - } + map = ps_compile_args.np2_fixup; + for (i = 0; map; map >>= 1, ++i) + { + if (!(map & 1)) continue; + + sprintf(name, "PsamplerNP2Fixup%u", i); + entry->np2Fixup_location[i] = GL_EXTCALL(glGetUniformLocationARB(programId, name)); } } @@ -4174,7 +4117,7 @@ static void set_glsl_shader_program(IWineD3DDevice *iface, BOOL use_ps, BOOL use } /* GL locking is done by the caller */ -static GLhandleARB create_glsl_blt_shader(const struct wined3d_gl_info *gl_info, enum tex_types tex_type) +static GLhandleARB create_glsl_blt_shader(const WineD3D_GL_Info *gl_info, enum tex_types tex_type) { GLhandleARB program_id; GLhandleARB vshader_id, pshader_id; @@ -4252,7 +4195,7 @@ static GLhandleARB create_glsl_blt_shader(const struct wined3d_gl_info *gl_info, static void shader_glsl_select(IWineD3DDevice *iface, BOOL usePS, BOOL useVS) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; struct shader_glsl_priv *priv = This->shader_priv; - const struct wined3d_gl_info *gl_info = &This->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &This->adapter->gl_info; GLhandleARB program_id = 0; GLenum old_vertex_color_clamp, current_vertex_color_clamp; @@ -4276,19 +4219,12 @@ static void shader_glsl_select(IWineD3DDevice *iface, BOOL usePS, BOOL useVS) { if (program_id) TRACE("Using GLSL program %u\n", program_id); GL_EXTCALL(glUseProgramObjectARB(program_id)); checkGLcall("glUseProgramObjectARB"); - - /* In case that NP2 texcoord fixup data is found for the selected program, trigger a reload of the - * constants. This has to be done because it can't be guaranteed that sampler() (from state.c) is - * called between selecting the shader and using it, which results in wrong fixup for some frames. */ - if (priv->glsl_program && priv->glsl_program->np2Fixup_info) { - This->shader_backend->shader_load_np2fixup_constants(iface, usePS, useVS); - } } /* GL locking is done by the caller */ static void shader_glsl_select_depth_blt(IWineD3DDevice *iface, enum tex_types tex_type) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; - const struct wined3d_gl_info *gl_info = &This->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &This->adapter->gl_info; struct shader_glsl_priv *priv = This->shader_priv; GLhandleARB *blt_program = &priv->depth_blt_program[tex_type]; @@ -4306,7 +4242,7 @@ static void shader_glsl_select_depth_blt(IWineD3DDevice *iface, enum tex_types t /* GL locking is done by the caller */ static void shader_glsl_deselect_depth_blt(IWineD3DDevice *iface) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; - const struct wined3d_gl_info *gl_info = &This->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &This->adapter->gl_info; struct shader_glsl_priv *priv = This->shader_priv; GLhandleARB program_id; @@ -4322,7 +4258,7 @@ static void shader_glsl_destroy(IWineD3DBaseShader *iface) { IWineD3DBaseShaderImpl *This = (IWineD3DBaseShaderImpl *) iface; IWineD3DDeviceImpl *device = (IWineD3DDeviceImpl *)This->baseShader.device; struct shader_glsl_priv *priv = device->shader_priv; - const struct wined3d_gl_info *gl_info = &device->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &device->adapter->gl_info; IWineD3DPixelShaderImpl *ps = NULL; IWineD3DVertexShaderImpl *vs = NULL; @@ -4331,6 +4267,8 @@ static void shader_glsl_destroy(IWineD3DBaseShader *iface) { */ char pshader = shader_is_pshader_version(This->baseShader.reg_maps.shader_version.type); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); + if(pshader) { struct glsl_pshader_private *shader_data; ps = (IWineD3DPixelShaderImpl *) This; @@ -4342,8 +4280,6 @@ static void shader_glsl_destroy(IWineD3DBaseShader *iface) { return; } - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); - if (priv->glsl_program && (IWineD3DBaseShader *)priv->glsl_program->pshader == iface) { ENTER_GL(); @@ -4361,8 +4297,6 @@ static void shader_glsl_destroy(IWineD3DBaseShader *iface) { return; } - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); - if (priv->glsl_program && (IWineD3DBaseShader *)priv->glsl_program->vshader == iface) { ENTER_GL(); @@ -4474,59 +4408,54 @@ static const struct wine_rb_functions wined3d_glsl_program_rb_functions = static HRESULT shader_glsl_alloc(IWineD3DDevice *iface) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; - const struct wined3d_gl_info *gl_info = &This->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &This->adapter->gl_info; struct shader_glsl_priv *priv = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(struct shader_glsl_priv)); SIZE_T stack_size = wined3d_log2i(max(GL_LIMITS(vshader_constantsF), GL_LIMITS(pshader_constantsF))) + 1; - if (!shader_buffer_init(&priv->shader_buffer)) - { - ERR("Failed to initialize shader buffer.\n"); - goto fail; - } - priv->stack = HeapAlloc(GetProcessHeap(), 0, stack_size * sizeof(*priv->stack)); if (!priv->stack) { ERR("Failed to allocate memory.\n"); - goto fail; + HeapFree(GetProcessHeap(), 0, priv); + return E_OUTOFMEMORY; } if (!constant_heap_init(&priv->vconst_heap, GL_LIMITS(vshader_constantsF))) { ERR("Failed to initialize vertex shader constant heap\n"); - goto fail; + HeapFree(GetProcessHeap(), 0, priv->stack); + HeapFree(GetProcessHeap(), 0, priv); + return E_OUTOFMEMORY; } if (!constant_heap_init(&priv->pconst_heap, GL_LIMITS(pshader_constantsF))) { ERR("Failed to initialize pixel shader constant heap\n"); - goto fail; + constant_heap_free(&priv->vconst_heap); + HeapFree(GetProcessHeap(), 0, priv->stack); + HeapFree(GetProcessHeap(), 0, priv); + return E_OUTOFMEMORY; } if (wine_rb_init(&priv->program_lookup, &wined3d_glsl_program_rb_functions) == -1) { ERR("Failed to initialize rbtree.\n"); - goto fail; + constant_heap_free(&priv->pconst_heap); + constant_heap_free(&priv->vconst_heap); + HeapFree(GetProcessHeap(), 0, priv->stack); + HeapFree(GetProcessHeap(), 0, priv); + return E_OUTOFMEMORY; } priv->next_constant_version = 1; This->shader_priv = priv; return WINED3D_OK; - -fail: - constant_heap_free(&priv->pconst_heap); - constant_heap_free(&priv->vconst_heap); - HeapFree(GetProcessHeap(), 0, priv->stack); - shader_buffer_free(&priv->shader_buffer); - HeapFree(GetProcessHeap(), 0, priv); - return E_OUTOFMEMORY; } -/* Context activation is done by the caller. */ static void shader_glsl_free(IWineD3DDevice *iface) { IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *)iface; - const struct wined3d_gl_info *gl_info = &This->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &This->adapter->gl_info; struct shader_glsl_priv *priv = This->shader_priv; int i; @@ -4554,8 +4483,7 @@ static BOOL shader_glsl_dirty_const(IWineD3DDevice *iface) { return FALSE; } -static void shader_glsl_get_caps(WINED3DDEVTYPE devtype, - const struct wined3d_gl_info *gl_info, struct shader_caps *pCaps) +static void shader_glsl_get_caps(WINED3DDEVTYPE devtype, const WineD3D_GL_Info *gl_info, struct shader_caps *pCaps) { /* Nvidia Geforce6/7 or Ati R4xx/R5xx cards with GLSL support, support VS 3.0 but older Nvidia/Ati * models with GLSL support only support 2.0. In case of nvidia we can detect VS 2.0 support using @@ -4682,7 +4610,7 @@ static const SHADER_HANDLER shader_glsl_instruction_handler_table[WINED3DSIH_TAB /* WINED3DSIH_POW */ shader_glsl_pow, /* WINED3DSIH_RCP */ shader_glsl_rcp, /* WINED3DSIH_REP */ shader_glsl_rep, - /* WINED3DSIH_RET */ shader_glsl_ret, + /* WINED3DSIH_RET */ NULL, /* WINED3DSIH_RSQ */ shader_glsl_rsq, /* WINED3DSIH_SETP */ NULL, /* WINED3DSIH_SGE */ shader_glsl_compare, diff --git a/dlls/wined3d/nvidia_texture_shader.c b/dlls/wined3d/nvidia_texture_shader.c index 1448cfcac46..ffb73f35b82 100644 --- a/dlls/wined3d/nvidia_texture_shader.c +++ b/dlls/wined3d/nvidia_texture_shader.c @@ -448,7 +448,8 @@ void set_tex_op_nvrc(IWineD3DDevice *iface, BOOL is_alpha, int stage, WINED3DTEX stage, is_alpha, debug_d3dtop(op), op, arg1, arg2, arg3, texture_idx); } - checkGLcall("set_tex_op_nvrc()"); + checkGLcall("set_tex_op_nvrc()\n"); + } @@ -594,10 +595,8 @@ static void nvrc_texfactor(DWORD state, IWineD3DStateBlockImpl *stateblock, Wine #undef GLINFO_LOCATION #define GLINFO_LOCATION (*gl_info) -/* Context activation is done by the caller. */ static void nvrc_enable(IWineD3DDevice *iface, BOOL enable) { } -/* Context activation is done by the caller. */ static void nvts_enable(IWineD3DDevice *iface, BOOL enable) { ENTER_GL(); if(enable) { @@ -610,8 +609,7 @@ static void nvts_enable(IWineD3DDevice *iface, BOOL enable) { LEAVE_GL(); } -static void nvrc_fragment_get_caps(WINED3DDEVTYPE devtype, - const struct wined3d_gl_info *gl_info, struct fragment_caps *pCaps) +static void nvrc_fragment_get_caps(WINED3DDEVTYPE devtype, const WineD3D_GL_Info *gl_info, struct fragment_caps *pCaps) { pCaps->TextureOpCaps = WINED3DTEXOPCAPS_ADD | WINED3DTEXOPCAPS_ADDSIGNED | @@ -666,7 +664,6 @@ static void nvrc_fragment_get_caps(WINED3DDEVTYPE devtype, } static HRESULT nvrc_fragment_alloc(IWineD3DDevice *iface) { return WINED3D_OK; } -/* Context activation is done by the caller. */ static void nvrc_fragment_free(IWineD3DDevice *iface) {} /* Two fixed function pipeline implementations using GL_NV_register_combiners and diff --git a/dlls/wined3d/palette.c b/dlls/wined3d/palette.c index a5447d07335..338e66e0906 100644 --- a/dlls/wined3d/palette.c +++ b/dlls/wined3d/palette.c @@ -22,6 +22,7 @@ #include "winerror.h" #include "wine/debug.h" +#include #include #include "wined3d_private.h" @@ -77,9 +78,7 @@ DWORD IWineD3DPaletteImpl_Size(DWORD dwFlags) { case WINEDDPCAPS_2BIT: return 4; case WINEDDPCAPS_4BIT: return 16; case WINEDDPCAPS_8BIT: return 256; - default: - FIXME("Unhandled size bits %#x.\n", dwFlags & SIZE_BITS); - return 256; + default: assert(0); return 256; } } diff --git a/dlls/wined3d/query.c b/dlls/wined3d/query.c index 0f395bca458..481177f4e72 100644 --- a/dlls/wined3d/query.c +++ b/dlls/wined3d/query.c @@ -62,22 +62,38 @@ static ULONG WINAPI IWineD3DQueryImpl_Release(IWineD3DQuery *iface) { TRACE("(%p) : Releasing from %d\n", This, This->ref); ref = InterlockedDecrement(&This->ref); if (ref == 0) { + ENTER_GL(); /* Queries are specific to the GL context that created them. Not * deleting the query will obviously leak it, but that's still better * than potentially deleting a different query with the same id in this * context, and (still) leaking the actual query. */ - if (This->type == WINED3DQUERYTYPE_EVENT) - { - struct wined3d_event_query *query = This->extendedData; - - if (query->context) context_free_event_query(query); - } - else if (This->type == WINED3DQUERYTYPE_OCCLUSION) - { - struct wined3d_occlusion_query *query = This->extendedData; - - if (query->context) context_free_occlusion_query(query); + if(This->type == WINED3DQUERYTYPE_EVENT) { + if (((WineQueryEventData *)This->extendedData)->ctx != This->wineD3DDevice->activeContext + || This->wineD3DDevice->activeContext->tid != GetCurrentThreadId()) + { + FIXME("Query was created in a different context, skipping deletion\n"); + } + else if(GL_SUPPORT(APPLE_FENCE)) + { + GL_EXTCALL(glDeleteFencesAPPLE(1, &((WineQueryEventData *)(This->extendedData))->fenceId)); + checkGLcall("glDeleteFencesAPPLE"); + } else if(GL_SUPPORT(NV_FENCE)) { + GL_EXTCALL(glDeleteFencesNV(1, &((WineQueryEventData *)(This->extendedData))->fenceId)); + checkGLcall("glDeleteFencesNV"); + } + } else if(This->type == WINED3DQUERYTYPE_OCCLUSION && GL_SUPPORT(ARB_OCCLUSION_QUERY)) { + if (((WineQueryOcclusionData *)This->extendedData)->ctx != This->wineD3DDevice->activeContext + || This->wineD3DDevice->activeContext->tid != GetCurrentThreadId()) + { + FIXME("Query was created in a different context, skipping deletion\n"); + } + else + { + GL_EXTCALL(glDeleteQueriesARB(1, &((WineQueryOcclusionData *)(This->extendedData))->queryId)); + checkGLcall("glDeleteQueriesARB"); + } } + LEAVE_GL(); HeapFree(GetProcessHeap(), 0, This->extendedData); HeapFree(GetProcessHeap(), 0, This); @@ -270,7 +286,7 @@ static HRESULT WINAPI IWineD3DQueryImpl_GetData(IWineD3DQuery* iface, void* pDa static HRESULT WINAPI IWineD3DOcclusionQueryImpl_GetData(IWineD3DQuery* iface, void* pData, DWORD dwSize, DWORD dwGetDataFlags) { IWineD3DQueryImpl *This = (IWineD3DQueryImpl *) iface; - struct wined3d_occlusion_query *query = This->extendedData; + GLuint queryId = ((WineQueryOcclusionData *)This->extendedData)->queryId; DWORD* data = pData; GLuint available; GLuint samples; @@ -278,8 +294,6 @@ static HRESULT WINAPI IWineD3DOcclusionQueryImpl_GetData(IWineD3DQuery* iface, TRACE("(%p) : type D3DQUERY_OCCLUSION, pData %p, dwSize %#x, dwGetDataFlags %#x\n", This, pData, dwSize, dwGetDataFlags); - if (!query->context) This->state = QUERY_CREATED; - if (This->state == QUERY_CREATED) { /* D3D allows GetData on a new query, OpenGL doesn't. So just invent the data ourselves */ @@ -302,27 +316,26 @@ static HRESULT WINAPI IWineD3DOcclusionQueryImpl_GetData(IWineD3DQuery* iface, return S_OK; } - if (query->context->tid != GetCurrentThreadId()) + if (((WineQueryOcclusionData *)This->extendedData)->ctx != This->wineD3DDevice->activeContext + || This->wineD3DDevice->activeContext->tid != GetCurrentThreadId()) { - FIXME("%p Wrong thread, returning 1.\n", This); + FIXME("%p Wrong context, returning 1.\n", This); *data = 1; return S_OK; } - ActivateContext(This->wineD3DDevice, query->context->current_rt, CTXUSAGE_RESOURCELOAD); - ENTER_GL(); - GL_EXTCALL(glGetQueryObjectuivARB(query->id, GL_QUERY_RESULT_AVAILABLE_ARB, &available)); - checkGLcall("glGetQueryObjectuivARB(GL_QUERY_RESULT_AVAILABLE)"); + GL_EXTCALL(glGetQueryObjectuivARB(queryId, GL_QUERY_RESULT_AVAILABLE_ARB, &available)); + checkGLcall("glGetQueryObjectuivARB(GL_QUERY_RESULT_AVAILABLE)\n"); TRACE("(%p) : available %d.\n", This, available); if (available) { if (data) { - GL_EXTCALL(glGetQueryObjectuivARB(query->id, GL_QUERY_RESULT_ARB, &samples)); - checkGLcall("glGetQueryObjectuivARB(GL_QUERY_RESULT)"); + GL_EXTCALL(glGetQueryObjectuivARB(queryId, GL_QUERY_RESULT_ARB, &samples)); + checkGLcall("glGetQueryObjectuivARB(GL_QUERY_RESULT)\n"); TRACE("(%p) : Returning %d samples.\n", This, samples); *data = samples; } @@ -340,44 +353,32 @@ static HRESULT WINAPI IWineD3DOcclusionQueryImpl_GetData(IWineD3DQuery* iface, static HRESULT WINAPI IWineD3DEventQueryImpl_GetData(IWineD3DQuery* iface, void* pData, DWORD dwSize, DWORD dwGetDataFlags) { IWineD3DQueryImpl *This = (IWineD3DQueryImpl *) iface; - struct wined3d_event_query *query = This->extendedData; BOOL* data = pData; - + WineD3DContext *ctx; TRACE("(%p) : type D3DQUERY_EVENT, pData %p, dwSize %#x, dwGetDataFlags %#x\n", This, pData, dwSize, dwGetDataFlags); - if (!pData || !dwSize) return S_OK; - - if (query->context->tid != GetCurrentThreadId()) - { + ctx = ((WineQueryEventData *)This->extendedData)->ctx; + if(pData == NULL || dwSize == 0) { + return S_OK; + } if(ctx != This->wineD3DDevice->activeContext || ctx->tid != GetCurrentThreadId()) { /* See comment in IWineD3DQuery::Issue, event query codeblock */ - FIXME("Wrong thread, reporting GPU idle.\n"); + FIXME("Query context not active, reporting GPU idle\n"); *data = TRUE; - - return S_OK; - } - - ActivateContext(This->wineD3DDevice, query->context->current_rt, CTXUSAGE_RESOURCELOAD); - - ENTER_GL(); - - if (GL_SUPPORT(APPLE_FENCE)) - { - *data = GL_EXTCALL(glTestFenceAPPLE(query->id)); + } else if(GL_SUPPORT(APPLE_FENCE)) { + ENTER_GL(); + *data = GL_EXTCALL(glTestFenceAPPLE(((WineQueryEventData *)This->extendedData)->fenceId)); checkGLcall("glTestFenceAPPLE"); - } - else if (GL_SUPPORT(NV_FENCE)) - { - *data = GL_EXTCALL(glTestFenceNV(query->id)); + LEAVE_GL(); + } else if(GL_SUPPORT(NV_FENCE)) { + ENTER_GL(); + *data = GL_EXTCALL(glTestFenceNV(((WineQueryEventData *)This->extendedData)->fenceId)); checkGLcall("glTestFenceNV"); - } - else - { + LEAVE_GL(); + } else { WARN("(%p): reporting GPU idle\n", This); *data = TRUE; } - LEAVE_GL(); - return S_OK; } @@ -454,47 +455,29 @@ static HRESULT WINAPI IWineD3DEventQueryImpl_Issue(IWineD3DQuery* iface, DWORD IWineD3DQueryImpl *This = (IWineD3DQueryImpl *)iface; TRACE("(%p) : dwIssueFlags %#x, type D3DQUERY_EVENT\n", This, dwIssueFlags); - if (dwIssueFlags & WINED3DISSUE_END) - { - struct wined3d_event_query *query = This->extendedData; - struct WineD3DContext *context; - - if (query->context) - { - if (query->context->tid != GetCurrentThreadId()) - { - context_free_event_query(query); - context = ActivateContext(This->wineD3DDevice, NULL, CTXUSAGE_RESOURCELOAD); - context_alloc_event_query(context, query); - } - else - { - ActivateContext(This->wineD3DDevice, query->context->current_rt, CTXUSAGE_RESOURCELOAD); - } - } - else - { - context = ActivateContext(This->wineD3DDevice, NULL, CTXUSAGE_RESOURCELOAD); - context_alloc_event_query(context, query); - } - - ENTER_GL(); - - if (GL_SUPPORT(APPLE_FENCE)) - { - GL_EXTCALL(glSetFenceAPPLE(query->id)); + if (dwIssueFlags & WINED3DISSUE_END) { + WineD3DContext *ctx = ((WineQueryEventData *)This->extendedData)->ctx; + if(ctx != This->wineD3DDevice->activeContext || ctx->tid != GetCurrentThreadId()) { + /* GL fences can be used only from the context that created them, + * so if a different context is active, don't bother setting the query. The penalty + * of a context switch is most likely higher than the gain of a correct query result + * + * If the query is used from a different thread, don't bother creating a multithread + * context - there's no point in doing that as the query would be unusable anyway + */ + WARN("Query context not active\n"); + } else if(GL_SUPPORT(APPLE_FENCE)) { + ENTER_GL(); + GL_EXTCALL(glSetFenceAPPLE(((WineQueryEventData *)This->extendedData)->fenceId)); checkGLcall("glSetFenceAPPLE"); - } - else if (GL_SUPPORT(NV_FENCE)) - { - GL_EXTCALL(glSetFenceNV(query->id, GL_ALL_COMPLETED_NV)); + LEAVE_GL(); + } else if (GL_SUPPORT(NV_FENCE)) { + ENTER_GL(); + GL_EXTCALL(glSetFenceNV(((WineQueryEventData *)This->extendedData)->fenceId, GL_ALL_COMPLETED_NV)); checkGLcall("glSetFenceNV"); + LEAVE_GL(); } - - LEAVE_GL(); - } - else if(dwIssueFlags & WINED3DISSUE_BEGIN) - { + } else if(dwIssueFlags & WINED3DISSUE_BEGIN) { /* Started implicitly at device creation */ ERR("Event query issued with START flag - what to do?\n"); } @@ -511,67 +494,34 @@ static HRESULT WINAPI IWineD3DEventQueryImpl_Issue(IWineD3DQuery* iface, DWORD static HRESULT WINAPI IWineD3DOcclusionQueryImpl_Issue(IWineD3DQuery* iface, DWORD dwIssueFlags) { IWineD3DQueryImpl *This = (IWineD3DQueryImpl *)iface; - if (GL_SUPPORT(ARB_OCCLUSION_QUERY)) - { - struct wined3d_occlusion_query *query = This->extendedData; - struct WineD3DContext *context; - - /* This is allowed according to msdn and our tests. Reset the query and restart */ - if (dwIssueFlags & WINED3DISSUE_BEGIN) - { - if (This->state == QUERY_BUILDING) - { - if (query->context->tid != GetCurrentThreadId()) - { - FIXME("Wrong thread, can't restart query.\n"); + if (GL_SUPPORT(ARB_OCCLUSION_QUERY)) { + WineD3DContext *ctx = ((WineQueryOcclusionData *)This->extendedData)->ctx; - context_free_occlusion_query(query); - context = ActivateContext(This->wineD3DDevice, NULL, CTXUSAGE_RESOURCELOAD); - context_alloc_occlusion_query(context, query); - } - else - { - ActivateContext(This->wineD3DDevice, query->context->current_rt, CTXUSAGE_RESOURCELOAD); - - ENTER_GL(); + if(ctx != This->wineD3DDevice->activeContext || ctx->tid != GetCurrentThreadId()) { + FIXME("Not the owning context, can't start query\n"); + } else { + ENTER_GL(); + /* This is allowed according to msdn and our tests. Reset the query and restart */ + if (dwIssueFlags & WINED3DISSUE_BEGIN) { + if(This->state == QUERY_BUILDING) { GL_EXTCALL(glEndQueryARB(GL_SAMPLES_PASSED_ARB)); checkGLcall("glEndQuery()"); - LEAVE_GL(); - } - } - else - { - if (query->context) context_free_occlusion_query(query); - context = ActivateContext(This->wineD3DDevice, NULL, CTXUSAGE_RESOURCELOAD); - context_alloc_occlusion_query(context, query); - } - - ENTER_GL(); - GL_EXTCALL(glBeginQueryARB(GL_SAMPLES_PASSED_ARB, query->id)); - checkGLcall("glBeginQuery()"); - LEAVE_GL(); - } - if (dwIssueFlags & WINED3DISSUE_END) { - /* Msdn says _END on a non-building occlusion query returns an error, but - * our tests show that it returns OK. But OpenGL doesn't like it, so avoid - * generating an error - */ - if (This->state == QUERY_BUILDING) - { - if (query->context->tid != GetCurrentThreadId()) - { - FIXME("Wrong thread, can't end query.\n"); } - else - { - ActivateContext(This->wineD3DDevice, query->context->current_rt, CTXUSAGE_RESOURCELOAD); - ENTER_GL(); + GL_EXTCALL(glBeginQueryARB(GL_SAMPLES_PASSED_ARB, ((WineQueryOcclusionData *)This->extendedData)->queryId)); + checkGLcall("glBeginQuery()"); + } + if (dwIssueFlags & WINED3DISSUE_END) { + /* Msdn says _END on a non-building occlusion query returns an error, but + * our tests show that it returns OK. But OpenGL doesn't like it, so avoid + * generating an error + */ + if(This->state == QUERY_BUILDING) { GL_EXTCALL(glEndQueryARB(GL_SAMPLES_PASSED_ARB)); checkGLcall("glEndQuery()"); - LEAVE_GL(); } } + LEAVE_GL(); } } else { FIXME("(%p) : Occlusion queries not supported\n", This); diff --git a/dlls/wined3d/shader_sm1.c b/dlls/wined3d/shader_sm1.c index ead2769e34c..a626d52a763 100644 --- a/dlls/wined3d/shader_sm1.c +++ b/dlls/wined3d/shader_sm1.c @@ -349,7 +349,6 @@ static void shader_parse_src_param(DWORD param, const struct wined3d_shader_src_ src->reg.type = ((param & WINED3DSP_REGTYPE_MASK) >> WINED3DSP_REGTYPE_SHIFT) | ((param & WINED3DSP_REGTYPE_MASK2) >> WINED3DSP_REGTYPE_SHIFT2); src->reg.idx = param & WINED3DSP_REGNUM_MASK; - src->reg.array_idx = ~0U; src->swizzle = (param & WINED3DSP_SWIZZLE_MASK) >> WINED3DSP_SWIZZLE_SHIFT; src->modifiers = (param & WINED3DSP_SRCMOD_MASK) >> WINED3DSP_SRCMOD_SHIFT; src->reg.rel_addr = rel_addr; @@ -361,7 +360,6 @@ static void shader_parse_dst_param(DWORD param, const struct wined3d_shader_src_ dst->reg.type = ((param & WINED3DSP_REGTYPE_MASK) >> WINED3DSP_REGTYPE_SHIFT) | ((param & WINED3DSP_REGTYPE_MASK2) >> WINED3DSP_REGTYPE_SHIFT2); dst->reg.idx = param & WINED3DSP_REGNUM_MASK; - dst->reg.array_idx = ~0U; dst->write_mask = (param & WINED3D_SM1_WRITEMASK_MASK) >> WINED3D_SM1_WRITEMASK_SHIFT; dst->modifiers = (param & WINED3DSP_DSTMOD_MASK) >> WINED3DSP_DSTMOD_SHIFT; dst->shift = (param & WINED3DSP_DSTSHIFT_MASK) >> WINED3DSP_DSTSHIFT_SHIFT; diff --git a/dlls/wined3d/shader_sm4.c b/dlls/wined3d/shader_sm4.c index 4e7a69ea33f..5cc445db69a 100644 --- a/dlls/wined3d/shader_sm4.c +++ b/dlls/wined3d/shader_sm4.c @@ -28,9 +28,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3d_shader); #define WINED3D_SM4_OPCODE_MASK 0xff -#define WINED3D_SM4_REGISTER_ORDER_SHIFT 20 -#define WINED3D_SM4_REGISTER_ORDER_MASK (0x3 << WINED3D_SM4_REGISTER_ORDER_SHIFT) - #define WINED3D_SM4_REGISTER_TYPE_SHIFT 12 #define WINED3D_SM4_REGISTER_TYPE_MASK (0xf << WINED3D_SM4_REGISTER_TYPE_SHIFT) @@ -49,24 +46,19 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3d_shader); enum wined3d_sm4_opcode { WINED3D_SM4_OP_ADD = 0x00, - WINED3D_SM4_OP_DP3 = 0x10, - WINED3D_SM4_OP_DP4 = 0x11, WINED3D_SM4_OP_EXP = 0x19, - WINED3D_SM4_OP_LOG = 0x2f, WINED3D_SM4_OP_MOV = 0x36, WINED3D_SM4_OP_MUL = 0x38, WINED3D_SM4_OP_RET = 0x3e, - WINED3D_SM4_OP_RSQ = 0x44, WINED3D_SM4_OP_SINCOS = 0x4d, }; enum wined3d_sm4_register_type { - WINED3D_SM4_RT_TEMP = 0x0, - WINED3D_SM4_RT_INPUT = 0x1, - WINED3D_SM4_RT_OUTPUT = 0x2, - WINED3D_SM4_RT_IMMCONST = 0x4, - WINED3D_SM4_RT_CONSTBUFFER = 0x8, + WINED3D_SM4_RT_TEMP = 0x0, + WINED3D_SM4_RT_INPUT = 0x1, + WINED3D_SM4_RT_OUTPUT = 0x2, + WINED3D_SM4_RT_IMMCONST = 0x4, }; enum wined3d_sm4_immconst_type @@ -100,28 +92,20 @@ struct sysval_map static const struct wined3d_sm4_opcode_info opcode_table[] = { {WINED3D_SM4_OP_ADD, WINED3DSIH_ADD, 1, 2}, - {WINED3D_SM4_OP_DP3, WINED3DSIH_DP3, 1, 2}, - {WINED3D_SM4_OP_DP4, WINED3DSIH_DP4, 1, 2}, {WINED3D_SM4_OP_EXP, WINED3DSIH_EXP, 1, 1}, - {WINED3D_SM4_OP_LOG, WINED3DSIH_LOG, 1, 1}, {WINED3D_SM4_OP_MOV, WINED3DSIH_MOV, 1, 1}, {WINED3D_SM4_OP_MUL, WINED3DSIH_MUL, 1, 2}, {WINED3D_SM4_OP_RET, WINED3DSIH_RET, 0, 0}, - {WINED3D_SM4_OP_RSQ, WINED3DSIH_RSQ, 1, 1}, {WINED3D_SM4_OP_SINCOS, WINED3DSIH_SINCOS, 1, 2}, }; static const WINED3DSHADER_PARAM_REGISTER_TYPE register_type_table[] = { - /* WINED3D_SM4_RT_TEMP */ WINED3DSPR_TEMP, - /* WINED3D_SM4_RT_INPUT */ WINED3DSPR_INPUT, - /* WINED3D_SM4_RT_OUTPUT */ WINED3DSPR_OUTPUT, - /* UNKNOWN */ 0, - /* WINED3D_SM4_RT_IMMCONST */ WINED3DSPR_IMMCONST, - /* UNKNOWN */ 0, - /* UNKNOWN */ 0, - /* UNKNOWN */ 0, - /* WINED3D_SM4_RT_CONSTBUFFER */ WINED3DSPR_CONSTBUFFER, + /* WINED3D_SM4_RT_TEMP */ WINED3DSPR_TEMP, + /* WINED3D_SM4_RT_INPUT */ WINED3DSPR_INPUT, + /* WINED3D_SM4_RT_OUTPUT */ WINED3DSPR_OUTPUT, + /* UNKNOWN */ 0, + /* WINED3D_SM4_RT_IMMCONST */ WINED3DSPR_IMMCONST, }; static const struct sysval_map sysval_map[] = @@ -281,7 +265,6 @@ static void shader_sm4_read_src_param(void *data, const DWORD **ptr, struct wine struct wined3d_sm4_data *priv = data; DWORD token = *(*ptr)++; enum wined3d_sm4_register_type register_type; - DWORD order; register_type = (token & WINED3D_SM4_REGISTER_TYPE_MASK) >> WINED3D_SM4_REGISTER_TYPE_SHIFT; if (register_type >= sizeof(register_type_table) / sizeof(*register_type_table)) @@ -294,16 +277,6 @@ static void shader_sm4_read_src_param(void *data, const DWORD **ptr, struct wine src_param->reg.type = register_type_table[register_type]; } - order = (token & WINED3D_SM4_REGISTER_ORDER_MASK) >> WINED3D_SM4_REGISTER_ORDER_SHIFT; - - if (order < 1) src_param->reg.idx = ~0U; - else src_param->reg.idx = *(*ptr)++; - - if (order < 2) src_param->reg.array_idx = ~0U; - else src_param->reg.array_idx = *(*ptr)++; - - if (order > 2) FIXME("Unhandled order %u.\n", order); - if (register_type == WINED3D_SM4_RT_IMMCONST) { enum wined3d_sm4_immconst_type immconst_type = @@ -331,6 +304,7 @@ static void shader_sm4_read_src_param(void *data, const DWORD **ptr, struct wine } else { + src_param->reg.idx = *(*ptr)++; src_param->swizzle = (token & WINED3D_SM4_SWIZZLE_MASK) >> WINED3D_SM4_SWIZZLE_SHIFT; } @@ -345,8 +319,8 @@ static void shader_sm4_read_dst_param(void *data, const DWORD **ptr, struct wine { struct wined3d_sm4_data *priv = data; DWORD token = *(*ptr)++; + UINT register_idx = *(*ptr)++; enum wined3d_sm4_register_type register_type; - DWORD order; register_type = (token & WINED3D_SM4_REGISTER_TYPE_MASK) >> WINED3D_SM4_REGISTER_TYPE_SHIFT; if (register_type >= sizeof(register_type_table) / sizeof(*register_type_table)) @@ -359,16 +333,7 @@ static void shader_sm4_read_dst_param(void *data, const DWORD **ptr, struct wine dst_param->reg.type = register_type_table[register_type]; } - order = (token & WINED3D_SM4_REGISTER_ORDER_MASK) >> WINED3D_SM4_REGISTER_ORDER_SHIFT; - - if (order < 1) dst_param->reg.idx = ~0U; - else dst_param->reg.idx = *(*ptr)++; - - if (order < 2) dst_param->reg.array_idx = ~0U; - else dst_param->reg.array_idx = *(*ptr)++; - - if (order > 2) FIXME("Unhandled order %u.\n", order); - + dst_param->reg.idx = register_idx; dst_param->write_mask = (token & WINED3D_SM4_WRITEMASK_MASK) >> WINED3D_SM4_WRITEMASK_SHIFT; dst_param->modifiers = 0; dst_param->shift = 0; diff --git a/dlls/wined3d/state.c b/dlls/wined3d/state.c index 44c0c064b81..c468d2b4c5f 100644 --- a/dlls/wined3d/state.c +++ b/dlls/wined3d/state.c @@ -510,7 +510,7 @@ static void state_alpha(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3D if(stateblock->renderState[WINED3DRS_COLORKEYENABLE] && enable_ckey) { glParm = GL_NOTEQUAL; - ref = 0.0f; + ref = 0.0; } else { ref = ((float) stateblock->renderState[WINED3DRS_ALPHAREF]) / 255.0f; glParm = CompareFunc(stateblock->renderState[WINED3DRS_ALPHAFUNC]); @@ -935,13 +935,13 @@ void state_fogstartend(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3DC switch(context->fog_source) { case FOGSOURCE_VS: - fogstart = 1.0f; - fogend = 0.0f; + fogstart = 1.0; + fogend = 0.0; break; case FOGSOURCE_COORD: - fogstart = 255.0f; - fogend = 0.0f; + fogstart = 255.0; + fogend = 0.0; break; case FOGSOURCE_FFP: @@ -951,8 +951,8 @@ void state_fogstartend(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3DC fogend = tmpvalue.f; /* In GL, fogstart == fogend disables fog, in D3D everything's fogged.*/ if(fogstart == fogend) { - fogstart = -1.0f / 0.0f; - fogend = 0.0f; + fogstart = -1.0 / 0.0; + fogend = 0.0; } break; @@ -961,8 +961,8 @@ void state_fogstartend(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3DC * Still this is needed to make the compiler happy */ ERR("Unexpected fog coordinate source\n"); - fogstart = 0.0f; - fogend = 0.0f; + fogstart = 0.0; + fogend = 0.0; } glFogf(GL_FOG_START, fogstart); @@ -1335,13 +1335,11 @@ static void state_psizemin_w(DWORD state, IWineD3DStateBlockImpl *stateblock, Wi } tmpvalue; tmpvalue.d = stateblock->renderState[WINED3DRS_POINTSIZE_MIN]; - if (tmpvalue.f != 1.0f) - { + if(tmpvalue.f != 1.0) { FIXME("WINED3DRS_POINTSIZE_MIN not supported on this opengl, value is %f\n", tmpvalue.f); } tmpvalue.d = stateblock->renderState[WINED3DRS_POINTSIZE_MAX]; - if (tmpvalue.f != 64.0f) - { + if(tmpvalue.f != 64.0) { FIXME("WINED3DRS_POINTSIZE_MAX not supported on this opengl, value is %f\n", tmpvalue.f); } @@ -3037,8 +3035,8 @@ static void transform_texture(DWORD state, IWineD3DStateBlockImpl *stateblock, W if(generated) { FIXME("Non-power2 texture being used with generated texture coords\n"); } - /* NP2 texcoord fixup is implemented for pixelshaders so only enable the - fixed-function-pipeline fixup via pow2Matrix when no PS is used. */ + /* NP2 texcoord fixup is implemented for pixelshaders (currently only in GLSL backend) so + only enable the fixed-function-pipeline fixup via pow2Matrix when no PS is used. */ if (!use_ps(stateblock)) { TRACE("Non power two matrix multiply fixup\n"); glMultMatrixf(((IWineD3DTextureImpl *) stateblock->textures[texUnit])->baseTexture.pow2Matrix); @@ -3105,10 +3103,10 @@ static void loadTexCoords(IWineD3DStateBlockImpl *stateblock, const struct wined static void tex_coordindex(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3DContext *context) { DWORD stage = (state - STATE_TEXTURESTAGE(0, 0)) / (WINED3D_HIGHEST_TEXTURE_STATE + 1); DWORD mapped_stage = stateblock->wineD3DDevice->texUnitMap[stage]; - static const GLfloat s_plane[] = { 1.0f, 0.0f, 0.0f, 0.0f }; - static const GLfloat t_plane[] = { 0.0f, 1.0f, 0.0f, 0.0f }; - static const GLfloat r_plane[] = { 0.0f, 0.0f, 1.0f, 0.0f }; - static const GLfloat q_plane[] = { 0.0f, 0.0f, 0.0f, 1.0f }; + static const GLfloat s_plane[] = { 1.0, 0.0, 0.0, 0.0 }; + static const GLfloat t_plane[] = { 0.0, 1.0, 0.0, 0.0 }; + static const GLfloat r_plane[] = { 0.0, 0.0, 1.0, 0.0 }; + static const GLfloat q_plane[] = { 0.0, 0.0, 0.0, 1.0 }; if (mapped_stage == WINED3D_UNMAPPED_STAGE) { @@ -3381,7 +3379,8 @@ static void sampler(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3DCont } } - /* Trigger shader constant reloading (for NP2 texcoord fixup) */ + /* Trigger shader constant reloading (for NP2 texcoord fixup) + * Only do this if pshaders are used (note: fixup is currently only implemented in GLSL). */ if (!tex_impl->baseTexture.pow2Matrix_identity) { IWineD3DDeviceImpl* d3ddevice = stateblock->wineD3DDevice; d3ddevice->shader_backend->shader_load_np2fixup_constants( @@ -3510,7 +3509,7 @@ static void clipplane(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3DCo glPushMatrix(); glLoadIdentity(); if(stateblock->wineD3DDevice->render_offscreen) { - glScalef(1.0f, -1.0f, 1.0f); + glScalef(1.0, -1.0, 1.0); } } @@ -3744,12 +3743,12 @@ static void transform_projection(DWORD state, IWineD3DStateBlockImpl *stateblock checkGLcall("glOrtho"); /* Window Coord 0 is the middle of the first pixel, so translate by 1/2 pixels */ - glTranslatef(0.5f, 0.5f, 0.0f); - checkGLcall("glTranslatef(0.5f, 0.5f, 0.0f)"); + glTranslatef(0.5, 0.5, 0); + checkGLcall("glTranslatef(0.5, 0.5, 0)"); /* D3D texture coordinates are flipped compared to OpenGL ones, so * render everything upside down when rendering offscreen. */ if (stateblock->wineD3DDevice->render_offscreen) { - glScalef(1.0f, -1.0f, 1.0f); + glScalef(1.0, -1.0, 1.0); checkGLcall("glScalef"); } } else { @@ -3793,13 +3792,13 @@ static void transform_projection(DWORD state, IWineD3DStateBlockImpl *stateblock if (stateblock->wineD3DDevice->render_offscreen) { /* D3D texture coordinates are flipped compared to OpenGL ones, so * render everything upside down when rendering offscreen. */ - glTranslatef(1.0f / stateblock->viewport.Width, 1.0f / stateblock->viewport.Height, -1.0f); - checkGLcall("glTranslatef(1.0f / width, 1.0f / height, -1.0f)"); - glScalef(1.0f, -1.0f, 2.0f); + glTranslatef(1.0 / stateblock->viewport.Width, 1.0 / stateblock->viewport.Height, -1.0); + checkGLcall("glTranslatef(1.0 / width, 1.0 / height, -1.0)"); + glScalef(1.0, -1.0, 2.0); } else { - glTranslatef(1.0f / stateblock->viewport.Width, -1.0f / stateblock->viewport.Height, -1.0f); - checkGLcall("glTranslatef(1.0f / width, -1.0f / height, -1.0f)"); - glScalef(1.0f, 1.0f, 2.0f); + glTranslatef(1.0 / stateblock->viewport.Width, -1.0 / stateblock->viewport.Height, -1.0); + checkGLcall("glTranslatef(1.0 / width, -1.0 / height, -1.0)"); + glScalef(1.0, 1.0, 2.0); } checkGLcall("glScalef"); @@ -4199,45 +4198,15 @@ static void loadVertexData(IWineD3DStateBlockImpl *stateblock, const struct wine VTRACE(("glSecondaryColorPointer(4, GL_UNSIGNED_BYTE, %d, %p)\n", e->stride, e->data)); if (GL_SUPPORT(EXT_SECONDARY_COLOR)) { - GLenum type = e->format_desc->gl_vtx_type; - GLint format = e->format_desc->gl_vtx_format; - if (curVBO != e->buffer_object) { GL_EXTCALL(glBindBufferARB(GL_ARRAY_BUFFER_ARB, e->buffer_object)); checkGLcall("glBindBufferARB"); curVBO = e->buffer_object; } - - if(format != 4 || (GLINFO_LOCATION.quirks & WINED3D_QUIRK_ALLOWS_SPECULAR_ALPHA)) - { - /* Usually specular colors only allow 3 components, since they have no alpha. In D3D, the specular alpha - * contains the fog coordinate, which is passed to GL with GL_EXT_fog_coord. However, the fixed function - * vertex pipeline can pass the specular alpha through, and pixel shaders can read it. So it GL accepts - * 4 component secondary colors use it - */ - GL_EXTCALL(glSecondaryColorPointerEXT)(format, type, - e->stride, e->data + stateblock->loadBaseVertexIndex * e->stride + offset[e->stream_idx]); - checkGLcall("glSecondaryColorPointerEXT(format, type, ...)"); - } - else - { - switch(type) - { - case GL_UNSIGNED_BYTE: - GL_EXTCALL(glSecondaryColorPointerEXT)(3, GL_UNSIGNED_BYTE, - e->stride, e->data + stateblock->loadBaseVertexIndex * e->stride + offset[e->stream_idx]); - checkGLcall("glSecondaryColorPointerEXT(3, GL_UNSIGNED_BYTE, ...)"); - break; - - default: - FIXME("Add 4 component specular color pointers for type %x\n", type); - /* Make sure that the right color component is dropped */ - GL_EXTCALL(glSecondaryColorPointerEXT)(3, type, - e->stride, e->data + stateblock->loadBaseVertexIndex * e->stride + offset[e->stream_idx]); - checkGLcall("glSecondaryColorPointerEXT(3, type, ...)"); - } - } + GL_EXTCALL(glSecondaryColorPointerEXT)(e->format_desc->gl_vtx_format, e->format_desc->gl_vtx_type, + e->stride, e->data + stateblock->loadBaseVertexIndex * e->stride + offset[e->stream_idx]); + checkGLcall("glSecondaryColorPointerEXT(4, GL_UNSIGNED_BYTE, ...)"); glEnableClientState(GL_SECONDARY_COLOR_ARRAY_EXT); checkGLcall("glEnableClientState(GL_SECONDARY_COLOR_ARRAY_EXT)"); } else { @@ -4400,7 +4369,7 @@ static void vertexdeclaration(DWORD state, IWineD3DStateBlockImpl *stateblock, W * TODO: Move to the viewport state */ if (useVertexShaderFunction) { - device->posFixup[1] = device->render_offscreen ? -1.0f : 1.0f; + device->posFixup[1] = device->render_offscreen ? -1.0 : 1.0; device->posFixup[3] = -device->posFixup[1] / stateblock->viewport.Height; } } @@ -4532,7 +4501,7 @@ static void viewport_miscpart(DWORD state, IWineD3DStateBlockImpl *stateblock, W stateblock->viewport.Width, stateblock->viewport.Height); } else { target = (IWineD3DSurfaceImpl *) stateblock->wineD3DDevice->render_targets[0]; - target->get_drawable_size(context, &width, &height); + target->get_drawable_size(target, &width, &height); glViewport(stateblock->viewport.X, (height - (stateblock->viewport.Y + stateblock->viewport.Height)), @@ -4543,7 +4512,7 @@ static void viewport_miscpart(DWORD state, IWineD3DStateBlockImpl *stateblock, W } static void viewport_vertexpart(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3DContext *context) { - stateblock->wineD3DDevice->posFixup[2] = 1.0f / stateblock->viewport.Width; + stateblock->wineD3DDevice->posFixup[2] = 1.0 / stateblock->viewport.Width; stateblock->wineD3DDevice->posFixup[3] = -stateblock->wineD3DDevice->posFixup[1] / stateblock->viewport.Height; if(!isStateDirty(context, STATE_TRANSFORM(WINED3DTS_PROJECTION))) { transform_projection(STATE_TRANSFORM(WINED3DTS_PROJECTION), stateblock, context); @@ -4562,7 +4531,7 @@ static void light(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3DContex checkGLcall("glDisable(GL_LIGHT0 + Index)"); } else { float quad_att; - float colRGBA[] = {0.0f, 0.0f, 0.0f, 0.0f}; + float colRGBA[] = {0.0, 0.0, 0.0, 0.0}; /* Light settings are affected by the model view in OpenGL, the View transform in direct3d*/ glMatrixMode(GL_MODELVIEW); @@ -4594,9 +4563,9 @@ static void light(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3DContex checkGLcall("glLightfv"); if ((lightInfo->OriginalParms.Range *lightInfo->OriginalParms.Range) >= FLT_MIN) { - quad_att = 1.4f/(lightInfo->OriginalParms.Range *lightInfo->OriginalParms.Range); + quad_att = 1.4/(lightInfo->OriginalParms.Range *lightInfo->OriginalParms.Range); } else { - quad_att = 0.0f; /* 0 or MAX? (0 seems to be ok) */ + quad_att = 0; /* 0 or MAX? (0 seems to be ok) */ } /* Do not assign attenuation values for lights that do not use them. D3D apps are free to pass any junk, @@ -4674,7 +4643,7 @@ static void scissorrect(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3D UINT width; IWineD3DSurfaceImpl *target = (IWineD3DSurfaceImpl *) stateblock->wineD3DDevice->render_targets[0]; - target->get_drawable_size(context, &width, &height); + target->get_drawable_size(target, &width, &height); /* Warning: glScissor uses window coordinates, not viewport coordinates, so our viewport correction does not apply * Warning2: Even in windowed mode the coords are relative to the window, not the screen */ @@ -5389,11 +5358,9 @@ static const struct StateEntryTemplate ffp_fragmentstate_template[] = { #undef GLINFO_LOCATION #define GLINFO_LOCATION (*gl_info) -/* Context activation is done by the caller. */ static void ffp_enable(IWineD3DDevice *iface, BOOL enable) { } -static void ffp_fragment_get_caps(WINED3DDEVTYPE devtype, - const struct wined3d_gl_info *gl_info, struct fragment_caps *pCaps) +static void ffp_fragment_get_caps(WINED3DDEVTYPE devtype, const WineD3D_GL_Info *gl_info, struct fragment_caps *pCaps) { pCaps->TextureOpCaps = WINED3DTEXOPCAPS_ADD | WINED3DTEXOPCAPS_ADDSIGNED | @@ -5480,7 +5447,7 @@ static void multistate_apply_3(DWORD state, IWineD3DStateBlockImpl *stateblock, } HRESULT compile_state_table(struct StateEntry *StateTable, APPLYSTATEFUNC **dev_multistate_funcs, - const struct wined3d_gl_info *gl_info, const struct StateEntryTemplate *vertex, + const WineD3D_GL_Info *gl_info, const struct StateEntryTemplate *vertex, const struct fragment_pipeline *fragment, const struct StateEntryTemplate *misc) { unsigned int i, type, handlers; diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 843247dc5ab..c6eaa69168f 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -38,7 +38,7 @@ WINE_DECLARE_DEBUG_CHANNEL(d3d); static void surface_cleanup(IWineD3DSurfaceImpl *This) { IWineD3DDeviceImpl *device = This->resource.wineD3DDevice; - const struct wined3d_gl_info *gl_info = &device->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &device->adapter->gl_info; renderbuffer_entry_t *entry, *entry2; TRACE("(%p) : Cleaning up.\n", This); @@ -49,16 +49,16 @@ static void surface_cleanup(IWineD3DSurfaceImpl *This) * target, Uninit3D() will activate a context before doing anything. */ if (device->render_targets && device->render_targets[0]) { - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); } ENTER_GL(); - if (This->texture_name) + if (This->glDescription.textureName) { /* Release the OpenGL texture. */ - TRACE("Deleting texture %u.\n", This->texture_name); - glDeleteTextures(1, &This->texture_name); + TRACE("Deleting texture %u.\n", This->glDescription.textureName); + glDeleteTextures(1, &This->glDescription.textureName); } if (This->Flags & SFLAG_PBO) @@ -114,7 +114,7 @@ UINT surface_calculate_size(const struct GlPixelFormatDesc *format_desc, UINT al size = height * (((width * format_desc->byte_count) + alignment - 1) & ~(alignment - 1)); } - if (format_desc->heightscale != 0.0f) size *= format_desc->heightscale; + if (format_desc->heightscale != 0.0) size *= format_desc->heightscale; return size; } @@ -124,7 +124,7 @@ HRESULT surface_init(IWineD3DSurfaceImpl *surface, WINED3DSURFTYPE surface_type, UINT multisample_quality, IWineD3DDeviceImpl *device, DWORD usage, WINED3DFORMAT format, WINED3DPOOL pool, IUnknown *parent) { - const struct wined3d_gl_info *gl_info = &device->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &device->adapter->gl_info; const struct GlPixelFormatDesc *format_desc = getFormatDescEntry(format, &GLINFO_LOCATION); void (*cleanup)(IWineD3DSurfaceImpl *This); unsigned int resource_size; @@ -173,7 +173,7 @@ HRESULT surface_init(IWineD3DSurfaceImpl *surface, WINED3DSURFTYPE surface_type, surface->currentDesc.Height = height; surface->currentDesc.MultiSampleType = multisample_type; surface->currentDesc.MultiSampleQuality = multisample_quality; - surface->texture_level = level; + surface->glDescription.level = level; list_init(&surface->overlays); /* Flags */ @@ -254,12 +254,12 @@ void surface_set_texture_name(IWineD3DSurface *iface, GLuint new_name, BOOL srgb if(srgb) { - name = &This->texture_name_srgb; + name = &This->glDescription.srgbTextureName; flag = SFLAG_INSRGBTEX; } else { - name = &This->texture_name; + name = &This->glDescription.textureName; flag = SFLAG_INTEXTURE; } @@ -284,22 +284,21 @@ void surface_set_texture_target(IWineD3DSurface *iface, GLenum target) TRACE("(%p) : setting target %#x\n", This, target); - if (This->texture_target != target) + if (This->glDescription.target != target) { if (target == GL_TEXTURE_RECTANGLE_ARB) { This->Flags &= ~SFLAG_NORMCOORD; } - else if (This->texture_target == GL_TEXTURE_RECTANGLE_ARB) + else if (This->glDescription.target == GL_TEXTURE_RECTANGLE_ARB) { This->Flags |= SFLAG_NORMCOORD; } } - This->texture_target = target; + This->glDescription.target = target; surface_force_reload(iface); } -/* Context activation is done by the caller. */ static void surface_bind_and_dirtify(IWineD3DSurfaceImpl *This, BOOL srgb) { int active_sampler; @@ -342,9 +341,8 @@ static BOOL primary_render_target_is_p8(IWineD3DDeviceImpl *device) #define GLINFO_LOCATION This->resource.wineD3DDevice->adapter->gl_info -/* This call just downloads data, the caller is responsible for binding the - * correct texture. */ -/* Context activation is done by the caller. */ +/* This call just downloads data, the caller is responsible for activating the + * right context and binding the correct texture. */ static void surface_download_data(IWineD3DSurfaceImpl *This) { const struct GlPixelFormatDesc *format_desc = This->resource.format_desc; @@ -360,22 +358,22 @@ static void surface_download_data(IWineD3DSurfaceImpl *This) { if (format_desc->Flags & WINED3DFMT_FLAG_COMPRESSED) { TRACE("(%p) : Calling glGetCompressedTexImageARB level %d, format %#x, type %#x, data %p.\n", - This, This->texture_level, format_desc->glFormat, format_desc->glType, + This, This->glDescription.level, format_desc->glFormat, format_desc->glType, This->resource.allocatedMemory); if (This->Flags & SFLAG_PBO) { GL_EXTCALL(glBindBufferARB(GL_PIXEL_PACK_BUFFER_ARB, This->pbo)); checkGLcall("glBindBufferARB"); - GL_EXTCALL(glGetCompressedTexImageARB(This->texture_target, This->texture_level, NULL)); + GL_EXTCALL(glGetCompressedTexImageARB(This->glDescription.target, This->glDescription.level, NULL)); checkGLcall("glGetCompressedTexImageARB()"); GL_EXTCALL(glBindBufferARB(GL_PIXEL_PACK_BUFFER_ARB, 0)); checkGLcall("glBindBufferARB"); } else { - GL_EXTCALL(glGetCompressedTexImageARB(This->texture_target, - This->texture_level, This->resource.allocatedMemory)); + GL_EXTCALL(glGetCompressedTexImageARB(This->glDescription.target, + This->glDescription.level, This->resource.allocatedMemory)); checkGLcall("glGetCompressedTexImageARB()"); } @@ -404,20 +402,22 @@ static void surface_download_data(IWineD3DSurfaceImpl *This) { mem = This->resource.allocatedMemory; } - TRACE("(%p) : Calling glGetTexImage level %d, format %#x, type %#x, data %p\n", - This, This->texture_level, format, type, mem); + TRACE("(%p) : Calling glGetTexImage level %d, format %#x, type %#x, data %p\n", This, This->glDescription.level, + format, type, mem); if(This->Flags & SFLAG_PBO) { GL_EXTCALL(glBindBufferARB(GL_PIXEL_PACK_BUFFER_ARB, This->pbo)); checkGLcall("glBindBufferARB"); - glGetTexImage(This->texture_target, This->texture_level, format, type, NULL); + glGetTexImage(This->glDescription.target, This->glDescription.level, format, + type, NULL); checkGLcall("glGetTexImage()"); GL_EXTCALL(glBindBufferARB(GL_PIXEL_PACK_BUFFER_ARB, 0)); checkGLcall("glBindBufferARB"); } else { - glGetTexImage(This->texture_target, This->texture_level, format, type, mem); + glGetTexImage(This->glDescription.target, This->glDescription.level, format, + type, mem); checkGLcall("glGetTexImage()"); } LEAVE_GL(); @@ -494,13 +494,12 @@ static void surface_download_data(IWineD3DSurfaceImpl *This) { This->Flags |= SFLAG_INSYSMEM; } -/* This call just uploads data, the caller is responsible for binding the - * correct texture. */ -/* Context activation is done by the caller. */ +/* This call just uploads data, the caller is responsible for activating the + * right context and binding the correct texture. */ static void surface_upload_data(IWineD3DSurfaceImpl *This, GLenum internal, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *data) { const struct GlPixelFormatDesc *format_desc = This->resource.format_desc; - if (format_desc->heightscale != 1.0f && format_desc->heightscale != 0.0f) height *= format_desc->heightscale; + if (format_desc->heightscale != 1.0 && format_desc->heightscale != 0.0) height *= format_desc->heightscale; if (format_desc->Flags & WINED3DFMT_FLAG_COMPRESSED) { @@ -521,7 +520,7 @@ static void surface_upload_data(IWineD3DSurfaceImpl *This, GLenum internal, GLsi TRACE("(%p) pbo: %#x, data: %p.\n", This, This->pbo, data); - GL_EXTCALL(glCompressedTexImage2DARB(This->texture_target, This->texture_level, + GL_EXTCALL(glCompressedTexImage2DARB(This->glDescription.target, This->glDescription.level, internal, width, height, 0 /* border */, This->resource.size, NULL)); checkGLcall("glCompressedTexImage2DARB"); @@ -530,7 +529,7 @@ static void surface_upload_data(IWineD3DSurfaceImpl *This, GLenum internal, GLsi } else { - GL_EXTCALL(glCompressedTexImage2DARB(This->texture_target, This->texture_level, + GL_EXTCALL(glCompressedTexImage2DARB(This->glDescription.target, This->glDescription.level, internal, width, height, 0 /* border */, This->resource.size, data)); checkGLcall("glCompressedTexSubImage2D"); } @@ -547,14 +546,14 @@ static void surface_upload_data(IWineD3DSurfaceImpl *This, GLenum internal, GLsi checkGLcall("glBindBufferARB"); TRACE("(%p) pbo: %#x, data: %p\n", This, This->pbo, data); - glTexSubImage2D(This->texture_target, This->texture_level, 0, 0, width, height, format, type, NULL); + glTexSubImage2D(This->glDescription.target, This->glDescription.level, 0, 0, width, height, format, type, NULL); checkGLcall("glTexSubImage2D"); GL_EXTCALL(glBindBufferARB(GL_PIXEL_UNPACK_BUFFER_ARB, 0)); checkGLcall("glBindBufferARB"); } else { - glTexSubImage2D(This->texture_target, This->texture_level, 0, 0, width, height, format, type, data); + glTexSubImage2D(This->glDescription.target, This->glDescription.level, 0, 0, width, height, format, type, data); checkGLcall("glTexSubImage2D"); } @@ -562,18 +561,17 @@ static void surface_upload_data(IWineD3DSurfaceImpl *This, GLenum internal, GLsi } } -/* This call just allocates the texture, the caller is responsible for binding - * the correct texture. */ -/* Context activation is done by the caller. */ +/* This call just allocates the texture, the caller is responsible for + * activating the right context and binding the correct texture. */ static void surface_allocate_surface(IWineD3DSurfaceImpl *This, GLenum internal, GLsizei width, GLsizei height, GLenum format, GLenum type) { const struct GlPixelFormatDesc *format_desc = This->resource.format_desc; BOOL enable_client_storage = FALSE; const BYTE *mem = NULL; - if (format_desc->heightscale != 1.0f && format_desc->heightscale != 0.0f) height *= format_desc->heightscale; + if (format_desc->heightscale != 1.0 && format_desc->heightscale != 0.0) height *= format_desc->heightscale; TRACE("(%p) : Creating surface (target %#x) level %d, d3d format %s, internal format %#x, width %d, height %d, gl format %#x, gl type=%#x\n", - This, This->texture_target, This->texture_level, debug_d3dformat(format_desc->format), + This, This->glDescription.target, This->glDescription.level, debug_d3dformat(format_desc->format), internal, width, height, format, type); if (format_desc->Flags & WINED3DFMT_FLAG_COMPRESSED) @@ -589,8 +587,8 @@ static void surface_allocate_surface(IWineD3DSurfaceImpl *This, GLenum internal, This->Flags |= SFLAG_CLIENT; mem = (BYTE *)(((ULONG_PTR) This->resource.heapMemory + (RESOURCE_ALIGNMENT - 1)) & ~(RESOURCE_ALIGNMENT - 1)); ENTER_GL(); - GL_EXTCALL(glCompressedTexImage2DARB(This->texture_target, This->texture_level, internal, - width, height, 0 /* border */, This->resource.size, mem)); + GL_EXTCALL(glCompressedTexImage2DARB(This->glDescription.target, This->glDescription.level, internal, + width, height, 0 /* border */, This->resource.size, mem)); LEAVE_GL(); } @@ -621,7 +619,7 @@ static void surface_allocate_surface(IWineD3DSurfaceImpl *This, GLenum internal, mem = (BYTE *)(((ULONG_PTR) This->resource.heapMemory + (RESOURCE_ALIGNMENT - 1)) & ~(RESOURCE_ALIGNMENT - 1)); } } - glTexImage2D(This->texture_target, This->texture_level, internal, width, height, 0, format, type, mem); + glTexImage2D(This->glDescription.target, This->glDescription.level, internal, width, height, 0, format, type, mem); checkGLcall("glTexImage2D"); if(enable_client_storage) { @@ -784,7 +782,7 @@ void surface_internal_preload(IWineD3DSurface *iface, enum WINED3DSRGB srgb) TRACE("(%p) : About to load surface\n", This); if(!device->isInDraw) { - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); } if (This->resource.format_desc->format == WINED3DFMT_P8 @@ -806,7 +804,7 @@ void surface_internal_preload(IWineD3DSurface *iface, enum WINED3DSRGB srgb) GLclampf tmp; tmp = 0.9f; ENTER_GL(); - glPrioritizeTextures(1, &This->texture_name, &tmp); + glPrioritizeTextures(1, &This->glDescription.textureName, &tmp); LEAVE_GL(); } } @@ -817,7 +815,6 @@ static void WINAPI IWineD3DSurfaceImpl_PreLoad(IWineD3DSurface *iface) { surface_internal_preload(iface, SRGB_ANY); } -/* Context activation is done by the caller. */ static void surface_remove_pbo(IWineD3DSurfaceImpl *This) { This->resource.heapMemory = HeapAlloc(GetProcessHeap() ,0 , This->resource.size + RESOURCE_ALIGNMENT); This->resource.allocatedMemory = @@ -839,7 +836,6 @@ static void surface_remove_pbo(IWineD3DSurfaceImpl *This) { static void WINAPI IWineD3DSurfaceImpl_UnLoad(IWineD3DSurface *iface) { IWineD3DBaseTexture *texture = NULL; IWineD3DSurfaceImpl *This = (IWineD3DSurfaceImpl *) iface; - IWineD3DDeviceImpl *device = This->resource.wineD3DDevice; renderbuffer_entry_t *entry, *entry2; TRACE("(%p)\n", iface); @@ -867,11 +863,8 @@ static void WINAPI IWineD3DSurfaceImpl_UnLoad(IWineD3DSurface *iface) { IWineD3DSurface_ModifyLocation(iface, SFLAG_INDRAWABLE, FALSE); } IWineD3DSurface_ModifyLocation(iface, SFLAG_INTEXTURE, FALSE); - IWineD3DSurface_ModifyLocation(iface, SFLAG_INSRGBTEX, FALSE); This->Flags &= ~(SFLAG_ALLOCATED | SFLAG_SRGBALLOCATED); - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); - /* Destroy PBOs, but load them into real sysmem before */ if(This->Flags & SFLAG_PBO) { surface_remove_pbo(This); @@ -897,10 +890,10 @@ static void WINAPI IWineD3DSurfaceImpl_UnLoad(IWineD3DSurface *iface) { IWineD3DSurface_GetContainer(iface, &IID_IWineD3DBaseTexture, (void **) &texture); if(!texture) { ENTER_GL(); - glDeleteTextures(1, &This->texture_name); - This->texture_name = 0; - glDeleteTextures(1, &This->texture_name_srgb); - This->texture_name_srgb = 0; + glDeleteTextures(1, &This->glDescription.textureName); + This->glDescription.textureName = 0; + glDeleteTextures(1, &This->glDescription.srgbTextureName); + This->glDescription.srgbTextureName = 0; LEAVE_GL(); } else { IWineD3DBaseTexture_Release(texture); @@ -912,6 +905,13 @@ static void WINAPI IWineD3DSurfaceImpl_UnLoad(IWineD3DSurface *iface) { IWineD3DSurface IWineD3DSurface parts follow ****************************************************** */ +static void WINAPI IWineD3DSurfaceImpl_GetGlDesc(IWineD3DSurface *iface, glDescriptor **glDescription) +{ + IWineD3DSurfaceImpl *This = (IWineD3DSurfaceImpl *)iface; + TRACE("(%p) : returning %p\n", This, &This->glDescription); + *glDescription = &This->glDescription; +} + /* Read the framebuffer back into the surface */ static void read_from_framebuffer(IWineD3DSurfaceImpl *This, CONST RECT *rect, void *dest, UINT pitch) { IWineD3DSwapChainImpl *swapchain; @@ -1215,15 +1215,18 @@ static void read_from_framebuffer_texture(IWineD3DSurfaceImpl *This, BOOL srgb) * this code from getting called in such cases or perhaps * we can use FBOs */ - glCopyTexSubImage2D(This->texture_target, This->texture_level, - 0, 0, 0, 0, This->currentDesc.Width, This->currentDesc.Height); + glCopyTexSubImage2D(This->glDescription.target, + This->glDescription.level, + 0, 0, 0, 0, + This->currentDesc.Width, + This->currentDesc.Height); checkGLcall("glCopyTexSubImage2D"); glReadBuffer(prevRead); checkGLcall("glReadBuffer"); LEAVE_GL(); - TRACE("Updated target %d\n", This->texture_target); + TRACE("Updated target %d\n", This->glDescription.target); } static void surface_prepare_system_memory(IWineD3DSurfaceImpl *This) { @@ -1247,7 +1250,7 @@ static void surface_prepare_system_memory(IWineD3DSurfaceImpl *This) { GLenum error; IWineD3DDeviceImpl *device = This->resource.wineD3DDevice; - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); GL_EXTCALL(glGenBuffersARB(1, &This->pbo)); @@ -1343,7 +1346,7 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_LockRect(IWineD3DSurface *iface, WINED lock_end: if(This->Flags & SFLAG_PBO) { - ActivateContext(myDevice, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(myDevice, myDevice->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); GL_EXTCALL(glBindBufferARB(GL_PIXEL_UNPACK_BUFFER_ARB, This->pbo)); checkGLcall("glBindBufferARB"); @@ -1416,7 +1419,7 @@ static void flush_to_framebuffer_drawpixels(IWineD3DSurfaceImpl *This, GLenum fm checkGLcall("glIntegerv"); glGetIntegerv(GL_CURRENT_RASTER_POSITION, &prev_rasterpos[0]); checkGLcall("glIntegerv"); - glPixelZoom(1.0f, -1.0f); + glPixelZoom(1.0, -1.0); checkGLcall("glPixelZoom"); /* If not fullscreen, we need to skip a number of bytes to find the next row of data */ @@ -1466,7 +1469,7 @@ static void flush_to_framebuffer_drawpixels(IWineD3DSurfaceImpl *This, GLenum fm checkGLcall("glBindBufferARB"); } - glPixelZoom(1.0f, 1.0f); + glPixelZoom(1.0,1.0); checkGLcall("glPixelZoom"); glRasterPos3iv(&prev_rasterpos[0]); @@ -1503,7 +1506,7 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_UnlockRect(IWineD3DSurface *iface) { if (This->Flags & SFLAG_PBO) { TRACE("Freeing PBO memory\n"); - ActivateContext(myDevice, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(myDevice, myDevice->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); GL_EXTCALL(glBindBufferARB(GL_PIXEL_UNPACK_BUFFER_ARB, This->pbo)); GL_EXTCALL(glUnmapBufferARB(GL_PIXEL_UNPACK_BUFFER_ARB)); @@ -2389,7 +2392,7 @@ static HRESULT d3dfmt_convert_surface(const BYTE *src, BYTE *dst, UINT pitch, UI float red = (*Source++); Dest[0] = green; Dest[1] = red; - Dest[2] = 1.0f; + Dest[2] = 1.0; Dest += 3; } } @@ -2465,7 +2468,6 @@ static HRESULT d3dfmt_convert_surface(const BYTE *src, BYTE *dst, UINT pitch, UI It supports GL_EXT_paletted_texture and GL_ARB_fragment_program, support for other extensions like ATI_fragment_shaders is possible. */ -/* Context activation is done by the caller. */ static void d3dfmt_p8_upload_palette(IWineD3DSurface *iface, CONVERT_TYPES convert) { IWineD3DSurfaceImpl *This = (IWineD3DSurfaceImpl *)iface; BYTE table[256][4]; @@ -2478,7 +2480,7 @@ static void d3dfmt_p8_upload_palette(IWineD3DSurface *iface, CONVERT_TYPES conve { TRACE("Using GL_EXT_PALETTED_TEXTURE for 8-bit paletted texture support\n"); ENTER_GL(); - GL_EXTCALL(glColorTableEXT(This->texture_target, GL_RGBA, 256, GL_RGBA, GL_UNSIGNED_BYTE, table)); + GL_EXTCALL(glColorTableEXT(This->glDescription.target,GL_RGBA,256,GL_RGBA,GL_UNSIGNED_BYTE, table)); LEAVE_GL(); } else @@ -2527,7 +2529,7 @@ static void d3dfmt_p8_upload_palette(IWineD3DSurface *iface, CONVERT_TYPES conve GL_EXTCALL(glActiveTextureARB(GL_TEXTURE0)); /* Rebind the texture because it isn't bound anymore */ - glBindTexture(This->texture_target, This->texture_name); + glBindTexture(This->glDescription.target, This->glDescription.textureName); LEAVE_GL(); } @@ -2603,8 +2605,7 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_LoadTexture(IWineD3DSurface *iface, BO char buffer[4096]; ++gen; if ((gen % 10) == 0) { - snprintf(buffer, sizeof(buffer), "/tmp/surface%p_type%u_level%u_%u.ppm", - This, This->texture_target, This->texture_level, gen); + snprintf(buffer, sizeof(buffer), "/tmp/surface%p_type%u_level%u_%u.ppm", This, This->glDescription.target, This->glDescription.level, gen); IWineD3DSurfaceImpl_SaveSnapshot(iface, buffer); } /* @@ -2627,7 +2628,6 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_LoadTexture(IWineD3DSurface *iface, BO return WINED3D_OK; } -/* Context activation is done by the caller. */ static void WINAPI IWineD3DSurfaceImpl_BindTexture(IWineD3DSurface *iface, BOOL srgb) { /* TODO: check for locks */ IWineD3DSurfaceImpl *This = (IWineD3DSurfaceImpl *)iface; @@ -2643,31 +2643,30 @@ static void WINAPI IWineD3DSurfaceImpl_BindTexture(IWineD3DSurface *iface, BOOL GLuint *name; TRACE("(%p) : Binding surface\n", This); - name = srgb ? &This->texture_name_srgb : &This->texture_name; + name = srgb ? &This->glDescription.srgbTextureName : &This->glDescription.textureName; if(!device->isInDraw) { - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); } ENTER_GL(); - if (!This->texture_level) - { + if (!This->glDescription.level) { if (!*name) { glGenTextures(1, name); checkGLcall("glGenTextures"); TRACE("Surface %p given name %d\n", This, *name); - glBindTexture(This->texture_target, *name); + glBindTexture(This->glDescription.target, *name); checkGLcall("glBindTexture"); - glTexParameteri(This->texture_target, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); + glTexParameteri(This->glDescription.target, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); checkGLcall("glTexParameteri(dimension, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE)"); - glTexParameteri(This->texture_target, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); + glTexParameteri(This->glDescription.target, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); checkGLcall("glTexParameteri(dimension, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE)"); - glTexParameteri(This->texture_target, GL_TEXTURE_WRAP_R, GL_CLAMP_TO_EDGE); + glTexParameteri(This->glDescription.target, GL_TEXTURE_WRAP_R, GL_CLAMP_TO_EDGE); checkGLcall("glTexParameteri(dimension, GL_TEXTURE_WRAP_R, GL_CLAMP_TO_EDGE)"); - glTexParameteri(This->texture_target, GL_TEXTURE_MIN_FILTER, GL_NEAREST); + glTexParameteri(This->glDescription.target, GL_TEXTURE_MIN_FILTER, GL_NEAREST); checkGLcall("glTexParameteri(dimension, GL_TEXTURE_MIN_FILTER, GL_NEAREST)"); - glTexParameteri(This->texture_target, GL_TEXTURE_MAG_FILTER, GL_NEAREST); + glTexParameteri(This->glDescription.target, GL_TEXTURE_MAG_FILTER, GL_NEAREST); checkGLcall("glTexParameteri(dimension, GL_TEXTURE_MAG_FILTER, GL_NEAREST)"); } /* This is where we should be reducing the amount of GLMemoryUsed */ @@ -2676,7 +2675,7 @@ static void WINAPI IWineD3DSurfaceImpl_BindTexture(IWineD3DSurface *iface, BOOL ERR("Mipmap surface has a glTexture bound to it!\n"); } - glBindTexture(This->texture_target, *name); + glBindTexture(This->glDescription.target, *name); checkGLcall("glBindTexture"); LEAVE_GL(); @@ -2759,8 +2758,12 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_SaveSnapshot(IWineD3DSurface *iface, c } allocatedMemory = HeapAlloc(GetProcessHeap(), 0, width * height * 4); ENTER_GL(); - FIXME("Saving texture level %d width %d height %d\n", This->texture_level, width, height); - glGetTexImage(GL_TEXTURE_2D, This->texture_level, GL_RGBA, GL_UNSIGNED_INT_8_8_8_8_REV, allocatedMemory); + FIXME("Saving texture level %d width %d height %d\n", This->glDescription.level, width, height); + glGetTexImage(GL_TEXTURE_2D, + This->glDescription.level, + GL_RGBA, + GL_UNSIGNED_INT_8_8_8_8_REV, + allocatedMemory); checkGLcall("glTexImage2D"); if (tmpTexture) { glBindTexture(GL_TEXTURE_2D, 0); @@ -2962,15 +2965,9 @@ void flip_surface(IWineD3DSurfaceImpl *front, IWineD3DSurfaceImpl *back) { /* Flip the opengl texture */ { - GLuint tmp; - - tmp = back->texture_name; - back->texture_name = front->texture_name; - front->texture_name = tmp; - - tmp = back->texture_name_srgb; - back->texture_name_srgb = front->texture_name_srgb; - front->texture_name_srgb = tmp; + glDescriptor tmp_desc = back->glDescription; + back->glDescription = front->glDescription; + front->glDescription = tmp_desc; } { @@ -3057,7 +3054,7 @@ static inline void fb_copy_to_texture_direct(IWineD3DSurfaceImpl *This, IWineD3D ENTER_GL(); /* Bind the target texture */ - glBindTexture(This->texture_target, This->texture_name); + glBindTexture(This->glDescription.target, This->glDescription.textureName); checkGLcall("glBindTexture"); if(!swapchain) { TRACE("Reading from an offscreen target\n"); @@ -3072,30 +3069,26 @@ static inline void fb_copy_to_texture_direct(IWineD3DSurfaceImpl *This, IWineD3D xrel = (float) (srect->x2 - srect->x1) / (float) (drect->x2 - drect->x1); yrel = (float) (srect->y2 - srect->y1) / (float) (drect->y2 - drect->y1); - if ((xrel - 1.0f < -eps) || (xrel - 1.0f > eps)) - { + if( (xrel - 1.0 < -eps) || (xrel - 1.0 > eps)) { FIXME("Doing a pixel by pixel copy from the framebuffer to a texture, expect major performance issues\n"); if(Filter != WINED3DTEXF_NONE && Filter != WINED3DTEXF_POINT) { ERR("Texture filtering not supported in direct blit\n"); } - } - else if ((Filter != WINED3DTEXF_NONE && Filter != WINED3DTEXF_POINT) - && ((yrel - 1.0f < -eps) || (yrel - 1.0f > eps))) - { + } else if((Filter != WINED3DTEXF_NONE && Filter != WINED3DTEXF_POINT) && ((yrel - 1.0 < -eps) || (yrel - 1.0 > eps))) { ERR("Texture filtering not supported in direct blit\n"); } - if (upsidedown - && !((xrel - 1.0f < -eps) || (xrel - 1.0f > eps)) - && !((yrel - 1.0f < -eps) || (yrel - 1.0f > eps))) - { + if(upsidedown && + !((xrel - 1.0 < -eps) || (xrel - 1.0 > eps)) && + !((yrel - 1.0 < -eps) || (yrel - 1.0 > eps))) { /* Upside down copy without stretching is nice, one glCopyTexSubImage call will do */ - glCopyTexSubImage2D(This->texture_target, This->texture_level, - drect->x1 /*xoffset */, drect->y1 /* y offset */, - srect->x1, Src->currentDesc.Height - srect->y2, - drect->x2 - drect->x1, drect->y2 - drect->y1); + glCopyTexSubImage2D(This->glDescription.target, + This->glDescription.level, + drect->x1, drect->y1, /* xoffset, yoffset */ + srect->x1, Src->currentDesc.Height - srect->y2, + drect->x2 - drect->x1, drect->y2 - drect->y1); } else { UINT yoffset = Src->currentDesc.Height - srect->y1 + drect->y1 - 1; /* I have to process this row by row to swap the image, @@ -3105,22 +3098,25 @@ static inline void fb_copy_to_texture_direct(IWineD3DSurfaceImpl *This, IWineD3D * However, stretching in x direction can be avoided if not necessary */ for(row = drect->y1; row < drect->y2; row++) { - if ((xrel - 1.0f < -eps) || (xrel - 1.0f > eps)) - { + if( (xrel - 1.0 < -eps) || (xrel - 1.0 > eps)) { /* Well, that stuff works, but it's very slow. * find a better way instead */ UINT col; for(col = drect->x1; col < drect->x2; col++) { - glCopyTexSubImage2D(This->texture_target, This->texture_level, - drect->x1 + col /* x offset */, row /* y offset */, - srect->x1 + col * xrel, yoffset - (int) (row * yrel), 1, 1); + glCopyTexSubImage2D(This->glDescription.target, + This->glDescription.level, + drect->x1 + col, row, /* xoffset, yoffset */ + srect->x1 + col * xrel, yoffset - (int) (row * yrel), + 1, 1); } } else { - glCopyTexSubImage2D(This->texture_target, This->texture_level, - drect->x1 /* x offset */, row /* y offset */, - srect->x1, yoffset - (int) (row * yrel), drect->x2-drect->x1, 1); + glCopyTexSubImage2D(This->glDescription.target, + This->glDescription.level, + drect->x1, row, /* xoffset, yoffset */ + srect->x1, yoffset - (int) (row * yrel), + drect->x2-drect->x1, 1); } } } @@ -3140,19 +3136,17 @@ static inline void fb_copy_to_texture_hwstretch(IWineD3DSurfaceImpl *This, IWine float left, right, top, bottom; /* Texture coordinates */ UINT fbwidth = Src->currentDesc.Width; UINT fbheight = Src->currentDesc.Height; - struct WineD3DContext *context; GLenum drawBuffer = GL_BACK; GLenum texture_target; BOOL noBackBufferBackup; TRACE("Using hwstretch blit\n"); /* Activate the Proper context for reading from the source surface, set it up for blitting */ - context = ActivateContext(myDevice, SrcSurface, CTXUSAGE_BLIT); + ActivateContext(myDevice, SrcSurface, CTXUSAGE_BLIT); surface_internal_preload((IWineD3DSurface *) This, SRGB_RGB); noBackBufferBackup = !swapchain && wined3d_settings.offscreen_rendering_mode == ORM_FBO; - if (!noBackBufferBackup && !Src->texture_name) - { + if(!noBackBufferBackup && Src->glDescription.textureName == 0) { /* Get it a description */ surface_internal_preload(SrcSurface, SRGB_RGB); } @@ -3161,30 +3155,27 @@ static inline void fb_copy_to_texture_hwstretch(IWineD3DSurfaceImpl *This, IWine /* Try to use an aux buffer for drawing the rectangle. This way it doesn't need restoring. * This way we don't have to wait for the 2nd readback to finish to leave this function. */ - if (context->aux_buffers >= 2) - { + if(myDevice->activeContext->aux_buffers >= 2) { /* Got more than one aux buffer? Use the 2nd aux buffer */ drawBuffer = GL_AUX1; - } - else if ((swapchain || myDevice->offscreenBuffer == GL_BACK) && context->aux_buffers >= 1) - { + } else if((swapchain || myDevice->offscreenBuffer == GL_BACK) && myDevice->activeContext->aux_buffers >= 1) { /* Only one aux buffer, but it isn't used (Onscreen rendering, or non-aux orm)? Use it! */ drawBuffer = GL_AUX0; } if(noBackBufferBackup) { glGenTextures(1, &backup); - checkGLcall("glGenTextures"); + checkGLcall("glGenTextures\n"); glBindTexture(GL_TEXTURE_2D, backup); - checkGLcall("glBindTexture(GL_TEXTURE_2D, backup)"); + checkGLcall("glBindTexture(Src->glDescription.target, Src->glDescription.textureName)"); texture_target = GL_TEXTURE_2D; } else { /* Backup the back buffer and copy the source buffer into a texture to draw an upside down stretched quad. If * we are reading from the back buffer, the backup can be used as source texture */ - texture_target = Src->texture_target; - glBindTexture(texture_target, Src->texture_name); - checkGLcall("glBindTexture(texture_target, Src->texture_name)"); + texture_target = Src->glDescription.target; + glBindTexture(texture_target, Src->glDescription.textureName); + checkGLcall("glBindTexture(texture_target, Src->glDescription.textureName)"); glEnable(texture_target); checkGLcall("glEnable(texture_target)"); @@ -3218,7 +3209,7 @@ static inline void fb_copy_to_texture_hwstretch(IWineD3DSurfaceImpl *This, IWine checkGLcall("glTexParameteri"); if(!swapchain || (IWineD3DSurface *) Src == swapchain->backBuffer[0]) { - src = backup ? backup : Src->texture_name; + src = backup ? backup : Src->glDescription.textureName; } else { glReadBuffer(GL_FRONT); checkGLcall("glReadBuffer(GL_FRONT)"); @@ -3300,15 +3291,14 @@ static inline void fb_copy_to_texture_hwstretch(IWineD3DSurfaceImpl *This, IWine glEnd(); checkGLcall("glEnd and previous"); - if (texture_target != This->texture_target) - { + if(texture_target != This->glDescription.target) { glDisable(texture_target); - glEnable(This->texture_target); - texture_target = This->texture_target; + glEnable(This->glDescription.target); + texture_target = This->glDescription.target; } /* Now read the stretched and upside down image into the destination texture */ - glBindTexture(texture_target, This->texture_name); + glBindTexture(texture_target, This->glDescription.textureName); checkGLcall("glBindTexture"); glCopyTexSubImage2D(texture_target, 0, @@ -3328,27 +3318,26 @@ static inline void fb_copy_to_texture_hwstretch(IWineD3DSurfaceImpl *This, IWine glBindTexture(GL_TEXTURE_2D, backup); checkGLcall("glBindTexture(GL_TEXTURE_2D, backup)"); } else { - if (texture_target != Src->texture_target) - { + if(texture_target != Src->glDescription.target) { glDisable(texture_target); - glEnable(Src->texture_target); - texture_target = Src->texture_target; + glEnable(Src->glDescription.target); + texture_target = Src->glDescription.target; } - glBindTexture(Src->texture_target, Src->texture_name); - checkGLcall("glBindTexture(Src->texture_target, Src->texture_name)"); + glBindTexture(Src->glDescription.target, Src->glDescription.textureName); + checkGLcall("glBindTexture(Src->glDescription.target, Src->glDescription.textureName)"); } glBegin(GL_QUADS); /* top left */ - glTexCoord2f(0.0f, (float)fbheight / (float)Src->pow2Height); + glTexCoord2f(0.0, (float) fbheight / (float) Src->pow2Height); glVertex2i(0, 0); /* bottom left */ - glTexCoord2f(0.0f, 0.0f); + glTexCoord2f(0.0, 0.0); glVertex2i(0, fbheight); /* bottom right */ - glTexCoord2f((float)fbwidth / (float)Src->pow2Width, 0.0f); + glTexCoord2f((float) fbwidth / (float) Src->pow2Width, 0.0); glVertex2i(fbwidth, Src->currentDesc.Height); /* top right */ @@ -3363,8 +3352,7 @@ static inline void fb_copy_to_texture_hwstretch(IWineD3DSurfaceImpl *This, IWine checkGLcall("glDisable(texture_target)"); /* Cleanup */ - if (src != Src->texture_name && src != backup) - { + if(src != Src->glDescription.textureName && src != backup) { glDeleteTextures(1, &src); checkGLcall("glDeleteTextures(1, &src)"); } @@ -3764,21 +3752,23 @@ static HRESULT IWineD3DSurfaceImpl_BltOverride(IWineD3DSurfaceImpl *This, const } myDevice->blitter->set_shader((IWineD3DDevice *) myDevice, Src->resource.format_desc, - Src->texture_target, Src->pow2Width, Src->pow2Height); + Src->glDescription.target, Src->pow2Width, Src->pow2Height); ENTER_GL(); /* Bind the texture */ - glBindTexture(Src->texture_target, Src->texture_name); + glBindTexture(Src->glDescription.target, Src->glDescription.textureName); checkGLcall("glBindTexture"); /* Filtering for StretchRect */ - glTexParameteri(Src->texture_target, GL_TEXTURE_MAG_FILTER, magLookup[Filter - WINED3DTEXF_NONE]); + glTexParameteri(Src->glDescription.target, GL_TEXTURE_MAG_FILTER, + magLookup[Filter - WINED3DTEXF_NONE]); checkGLcall("glTexParameteri"); - glTexParameteri(Src->texture_target, GL_TEXTURE_MIN_FILTER, minMipLookup[Filter].mip[WINED3DTEXF_NONE]); + glTexParameteri(Src->glDescription.target, GL_TEXTURE_MIN_FILTER, + minMipLookup[Filter].mip[WINED3DTEXF_NONE]); checkGLcall("glTexParameteri"); - glTexParameteri(Src->texture_target, GL_TEXTURE_WRAP_S, GL_CLAMP); - glTexParameteri(Src->texture_target, GL_TEXTURE_WRAP_T, GL_CLAMP); + glTexParameteri(Src->glDescription.target, GL_TEXTURE_WRAP_S, GL_CLAMP); + glTexParameteri(Src->glDescription.target, GL_TEXTURE_WRAP_T, GL_CLAMP); glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE); checkGLcall("glTexEnvi"); @@ -3791,10 +3781,10 @@ static HRESULT IWineD3DSurfaceImpl_BltOverride(IWineD3DSurfaceImpl *This, const * Which means that the colorkey is one of the palette entries. In other cases pixels that * should be masked away have alpha set to 0. */ if(primary_render_target_is_p8(myDevice)) - glAlphaFunc(GL_NOTEQUAL, (float)Src->SrcBltCKey.dwColorSpaceLowValue / 256.0f); + glAlphaFunc(GL_NOTEQUAL, (float)Src->SrcBltCKey.dwColorSpaceLowValue / 256.0); else - glAlphaFunc(GL_NOTEQUAL, 0.0f); - checkGLcall("glAlphaFunc"); + glAlphaFunc(GL_NOTEQUAL, 0.0); + checkGLcall("glAlphaFunc\n"); } else { glDisable(GL_ALPHA_TEST); checkGLcall("glDisable GL_ALPHA_TEST"); @@ -3804,19 +3794,24 @@ static HRESULT IWineD3DSurfaceImpl_BltOverride(IWineD3DSurfaceImpl *This, const */ glBegin(GL_QUADS); - glColor3f(1.0f, 1.0f, 1.0f); + glColor3d(1.0f, 1.0f, 1.0f); glTexCoord2f(glTexCoord[0], glTexCoord[2]); - glVertex3f(rect.x1, rect.y1, 0.0f); + glVertex3f(rect.x1, + rect.y1, + 0.0); glTexCoord2f(glTexCoord[0], glTexCoord[3]); - glVertex3f(rect.x1, rect.y2, 0.0f); + glVertex3f(rect.x1, rect.y2, 0.0); glTexCoord2f(glTexCoord[1], glTexCoord[3]); - glVertex3f(rect.x2, rect.y2, 0.0f); + glVertex3f(rect.x2, + rect.y2, + 0.0); glTexCoord2f(glTexCoord[1], glTexCoord[2]); - glVertex3f(rect.x2, rect.y1, 0.0f); - + glVertex3f(rect.x2, + rect.y1, + 0.0); glEnd(); checkGLcall("glEnd"); @@ -3825,8 +3820,8 @@ static HRESULT IWineD3DSurfaceImpl_BltOverride(IWineD3DSurfaceImpl *This, const checkGLcall("glDisable(GL_ALPHA_TEST)"); } - glBindTexture(Src->texture_target, 0); - checkGLcall("glBindTexture(Src->texture_target, 0)"); + glBindTexture(Src->glDescription.target, 0); + checkGLcall("glBindTexture(Src->glDescription.target, 0)"); /* Restore the color key parameters */ Src->CKeyFlags = oldCKeyFlags; @@ -3914,8 +3909,11 @@ static HRESULT IWineD3DSurfaceImpl_BltOverride(IWineD3DSurfaceImpl *This, const } TRACE("(%p) executing Render Target override, color = %x\n", This, color); - IWineD3DDeviceImpl_ClearSurface(myDevice, This, 1 /* Number of rectangles */, - &rect, WINED3DCLEAR_TARGET, color, 0.0f /* Z */, 0 /* Stencil */); + IWineD3DDeviceImpl_ClearSurface(myDevice, This, + 1, /* Number of rectangles */ + &rect, WINED3DCLEAR_TARGET, color, + 0.0 /* Z */, + 0 /* Stencil */); return WINED3D_OK; } } @@ -3948,7 +3946,7 @@ static HRESULT IWineD3DSurfaceImpl_BltZ(IWineD3DSurfaceImpl *This, const RECT *D depth = (float) DDBltFx->u5.dwFillDepth / (float) 0xffffffff; break; default: - depth = 0.0f; + depth = 0.0; ERR("Unexpected format for depth fill: %s\n", debug_d3dformat(This->resource.format_desc->format)); } @@ -4092,8 +4090,6 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_RealizePalette(IWineD3DSurface *iface) if((This->resource.usage & WINED3DUSAGE_RENDERTARGET) && (convert == NO_CONVERSION)) { - IWineD3DDeviceImpl *device = This->resource.wineD3DDevice; - /* Make sure the texture is up to date. This call doesn't do anything if the texture is already up to date. */ IWineD3DSurface_LoadLocation(iface, SFLAG_INTEXTURE, NULL); @@ -4101,7 +4097,6 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_RealizePalette(IWineD3DSurface *iface) IWineD3DSurface_ModifyLocation(iface, SFLAG_INDRAWABLE, FALSE); /* Re-upload the palette */ - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); d3dfmt_p8_upload_palette(iface, convert); } else { if(!(This->Flags & SFLAG_INSYSMEM)) { @@ -4136,8 +4131,8 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_PrivateSetup(IWineD3DSurface *iface) { IWineD3DSurfaceImpl *This = (IWineD3DSurfaceImpl *) iface; unsigned int pow2Width, pow2Height; - This->texture_name = 0; - This->texture_target = GL_TEXTURE_2D; + This->glDescription.textureName = 0; + This->glDescription.target = GL_TEXTURE_2D; /* Non-power2 support */ if (GL_SUPPORT(ARB_TEXTURE_NON_POWER_OF_TWO) || GL_SUPPORT(WINE_NORMALIZED_TEXRECT)) { @@ -4195,7 +4190,7 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_PrivateSetup(IWineD3DSurface *iface) { && (wined3d_settings.rendertargetlock_mode == RTL_READTEX || wined3d_settings.rendertargetlock_mode == RTL_TEXTEX))) { - This->texture_target = GL_TEXTURE_RECTANGLE_ARB; + This->glDescription.target = GL_TEXTURE_RECTANGLE_ARB; This->pow2Width = This->currentDesc.Width; This->pow2Height = This->currentDesc.Height; This->Flags &= ~(SFLAG_NONPOW2 | SFLAG_NORMCOORD); @@ -4325,14 +4320,14 @@ static void surface_depth_blt(IWineD3DSurfaceImpl *This, GLuint texture, GLsizei glPushAttrib(GL_ENABLE_BIT | GL_DEPTH_BUFFER_BIT | GL_COLOR_BUFFER_BIT | GL_VIEWPORT_BIT); glDisable(GL_CULL_FACE); - glDisable(GL_BLEND); + glEnable(GL_BLEND); glDisable(GL_ALPHA_TEST); glDisable(GL_SCISSOR_TEST); glDisable(GL_STENCIL_TEST); glEnable(GL_DEPTH_TEST); glDepthFunc(GL_ALWAYS); glDepthMask(GL_TRUE); - glColorMask(GL_FALSE, GL_FALSE, GL_FALSE, GL_FALSE); + glBlendFunc(GL_ZERO, GL_ONE); glViewport(0, 0, w, h); surface_get_depth_blt_info(target, w, h, &info); @@ -4373,9 +4368,7 @@ void surface_modify_ds_location(IWineD3DSurface *iface, DWORD location) { This->Flags |= location; } -/* Context activation is done by the caller. */ -void surface_load_ds_location(IWineD3DSurface *iface, struct WineD3DContext *context, DWORD location) -{ +void surface_load_ds_location(IWineD3DSurface *iface, DWORD location) { IWineD3DSurfaceImpl *This = (IWineD3DSurfaceImpl *)iface; IWineD3DDeviceImpl *device = This->resource.wineD3DDevice; @@ -4409,9 +4402,8 @@ void surface_load_ds_location(IWineD3DSurface *iface, struct WineD3DContext *con /* Note that we use depth_blt here as well, rather than glCopyTexImage2D * directly on the FBO texture. That's because we need to flip. */ - context_bind_fbo(context, GL_FRAMEBUFFER_EXT, NULL); - if (This->texture_target == GL_TEXTURE_RECTANGLE_ARB) - { + GL_EXTCALL(glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0)); + if (This->glDescription.target == GL_TEXTURE_RECTANGLE_ARB) { glGetIntegerv(GL_TEXTURE_BINDING_RECTANGLE_ARB, &old_binding); bind_target = GL_TEXTURE_RECTANGLE_ARB; } else { @@ -4419,13 +4411,16 @@ void surface_load_ds_location(IWineD3DSurface *iface, struct WineD3DContext *con bind_target = GL_TEXTURE_2D; } glBindTexture(bind_target, device->depth_blt_texture); - glCopyTexImage2D(bind_target, This->texture_level, This->resource.format_desc->glInternal, - 0, 0, This->currentDesc.Width, This->currentDesc.Height, 0); + glCopyTexImage2D(bind_target, + This->glDescription.level, + This->resource.format_desc->glInternal, + 0, + 0, + This->currentDesc.Width, + This->currentDesc.Height, + 0); glTexParameteri(bind_target, GL_TEXTURE_MIN_FILTER, GL_NEAREST); glTexParameteri(bind_target, GL_TEXTURE_MAG_FILTER, GL_NEAREST); - glTexParameteri(bind_target, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); - glTexParameteri(bind_target, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); - glTexParameteri(bind_target, GL_TEXTURE_WRAP_R, GL_CLAMP_TO_EDGE); glTexParameteri(bind_target, GL_DEPTH_TEXTURE_MODE_ARB, GL_LUMINANCE); glBindTexture(bind_target, old_binding); @@ -4444,17 +4439,21 @@ void surface_load_ds_location(IWineD3DSurface *iface, struct WineD3DContext *con device->depth_blt_rb_h = This->currentDesc.Height; } - context_bind_fbo(context, GL_FRAMEBUFFER_EXT, &context->dst_fbo); + context_bind_fbo((IWineD3DDevice *)device, GL_FRAMEBUFFER_EXT, &device->activeContext->dst_fbo); GL_EXTCALL(glFramebufferRenderbufferEXT(GL_FRAMEBUFFER_EXT, GL_COLOR_ATTACHMENT0_EXT, GL_RENDERBUFFER_EXT, device->depth_blt_rb)); checkGLcall("glFramebufferRenderbufferEXT"); - context_attach_depth_stencil_fbo(context, GL_FRAMEBUFFER_EXT, iface, FALSE); + context_attach_depth_stencil_fbo(device, GL_FRAMEBUFFER_EXT, iface, FALSE); /* Do the actual blit */ surface_depth_blt(This, device->depth_blt_texture, This->currentDesc.Width, This->currentDesc.Height, bind_target); checkGLcall("depth_blt"); - if (context->current_fbo) context_bind_fbo(context, GL_FRAMEBUFFER_EXT, &context->current_fbo->id); - else context_bind_fbo(context, GL_FRAMEBUFFER_EXT, NULL); + if (device->activeContext->current_fbo) { + context_bind_fbo((IWineD3DDevice *)device, GL_FRAMEBUFFER_EXT, &device->activeContext->current_fbo->id); + } else { + GL_EXTCALL(glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0)); + checkGLcall("glBindFramebuffer()"); + } LEAVE_GL(); } else { @@ -4466,12 +4465,15 @@ void surface_load_ds_location(IWineD3DSurface *iface, struct WineD3DContext *con ENTER_GL(); - context_bind_fbo(context, GL_FRAMEBUFFER_EXT, NULL); - surface_depth_blt(This, This->texture_name, This->currentDesc.Width, - This->currentDesc.Height, This->texture_target); + GL_EXTCALL(glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0)); + checkGLcall("glBindFramebuffer()"); + surface_depth_blt(This, This->glDescription.textureName, This->currentDesc.Width, This->currentDesc.Height, This->glDescription.target); checkGLcall("depth_blt"); - if (context->current_fbo) context_bind_fbo(context, GL_FRAMEBUFFER_EXT, &context->current_fbo->id); + if (device->activeContext->current_fbo) { + GL_EXTCALL(glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, device->activeContext->current_fbo->id)); + checkGLcall("glBindFramebuffer()"); + } LEAVE_GL(); } else { @@ -4574,7 +4576,7 @@ static inline void surface_blt_to_drawable(IWineD3DSurfaceImpl *This, const RECT rect.bottom = This->currentDesc.Height; } - switch (This->texture_target) + switch(This->glDescription.target) { case GL_TEXTURE_2D: bind_target = GL_TEXTURE_2D; @@ -4659,7 +4661,7 @@ static inline void surface_blt_to_drawable(IWineD3DSurfaceImpl *This, const RECT break; default: - ERR("Unexpected texture target %#x\n", This->texture_target); + ERR("Unexpected texture target %#x\n", This->glDescription.target); return; } @@ -4668,8 +4670,8 @@ static inline void surface_blt_to_drawable(IWineD3DSurfaceImpl *This, const RECT glEnable(bind_target); checkGLcall("glEnable(bind_target)"); - glBindTexture(bind_target, This->texture_name); - checkGLcall("bind_target, This->texture_name)"); + glBindTexture(bind_target, This->glDescription.textureName); + checkGLcall("bind_target, This->glDescription.textureName)"); glTexParameteri(bind_target, GL_TEXTURE_MAG_FILTER, GL_NEAREST); checkGLcall("glTexParameteri"); glTexParameteri(bind_target, GL_TEXTURE_MIN_FILTER, GL_NEAREST); @@ -4788,7 +4790,7 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_LoadLocation(IWineD3DSurface *iface, D /* Download the surface to system memory */ if(This->Flags & (SFLAG_INTEXTURE | SFLAG_INSRGBTEX)) { - if (!device->isInDraw) ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + if(!device->isInDraw) ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); surface_bind_and_dirtify(This, !(This->Flags & SFLAG_INTEXTURE)); surface_download_data(This); @@ -4820,7 +4822,6 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_LoadLocation(IWineD3DSurface *iface, D * but it isn't set (yet) in all cases it is getting called. */ if((convert != NO_CONVERSION) && (This->Flags & SFLAG_PBO)) { TRACE("Removing the pbo attached to surface %p\n", This); - if (!device->isInDraw) ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); surface_remove_pbo(This); } @@ -4872,7 +4873,7 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_LoadLocation(IWineD3DSurface *iface, D } } - if (!device->isInDraw) ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + if(!device->isInDraw) ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); surface_bind_and_dirtify(This, srgb); if(This->CKeyFlags & WINEDDSD_CKSRCBLT) { @@ -5067,6 +5068,7 @@ const IWineD3DSurfaceVtbl IWineD3DSurface_Vtbl = IWineD3DSurfaceImpl_BindTexture, IWineD3DSurfaceImpl_SaveSnapshot, IWineD3DSurfaceImpl_SetContainer, + IWineD3DSurfaceImpl_GetGlDesc, IWineD3DBaseSurfaceImpl_GetData, IWineD3DSurfaceImpl_SetFormat, IWineD3DSurfaceImpl_PrivateSetup, @@ -5079,10 +5081,8 @@ const IWineD3DSurfaceVtbl IWineD3DSurface_Vtbl = #define GLINFO_LOCATION device->adapter->gl_info static HRESULT ffp_blit_alloc(IWineD3DDevice *iface) { return WINED3D_OK; } -/* Context activation is done by the caller. */ static void ffp_blit_free(IWineD3DDevice *iface) { } -/* Context activation is done by the caller. */ static HRESULT ffp_blit_set(IWineD3DDevice *iface, const struct GlPixelFormatDesc *format_desc, GLenum textype, UINT width, UINT height) { @@ -5093,7 +5093,6 @@ static HRESULT ffp_blit_set(IWineD3DDevice *iface, const struct GlPixelFormatDes return WINED3D_OK; } -/* Context activation is done by the caller. */ static void ffp_blit_unset(IWineD3DDevice *iface) { IWineD3DDeviceImpl *device = (IWineD3DDeviceImpl *) iface; ENTER_GL(); diff --git a/dlls/wined3d/surface_base.c b/dlls/wined3d/surface_base.c index 5c00b2b8c3e..d776785a018 100644 --- a/dlls/wined3d/surface_base.c +++ b/dlls/wined3d/surface_base.c @@ -30,6 +30,8 @@ #include "wine/port.h" #include "wined3d_private.h" +#include + WINE_DEFAULT_DEBUG_CHANNEL(d3d_surface); /* See also float_16_to_32() in wined3d_private.h */ @@ -41,26 +43,26 @@ static inline unsigned short float_32_to_16(const float *in) unsigned short ret; /* Deal with special numbers */ - if (*in == 0.0f) return 0x0000; + if(*in == 0.0) return 0x0000; if(isnan(*in)) return 0x7C01; - if (isinf(*in)) return (*in < 0.0f ? 0xFC00 : 0x7c00); + if(isinf(*in)) return (*in < 0.0 ? 0xFC00 : 0x7c00); if(tmp < pow(2, 10)) { do { - tmp = tmp * 2.0f; + tmp = tmp * 2.0; exp--; }while(tmp < pow(2, 10)); } else if(tmp >= pow(2, 11)) { do { - tmp /= 2.0f; + tmp /= 2.0; exp++; }while(tmp >= pow(2, 11)); } mantissa = (unsigned int) tmp; - if(tmp - mantissa >= 0.5f) mantissa++; /* round to nearest, away from zero */ + if(tmp - mantissa >= 0.5) mantissa++; /* round to nearest, away from zero */ exp += 10; /* Normalize the mantissa */ exp += 15; /* Exponent is encoded with excess 15 */ @@ -78,7 +80,7 @@ static inline unsigned short float_32_to_16(const float *in) ret = (exp << 10) | (mantissa & 0x3ff); } - ret |= ((*in < 0.0f ? 1 : 0) << 15); /* Add the sign */ + ret |= ((*in < 0.0 ? 1 : 0) << 15); /* Add the sign */ return ret; } @@ -724,25 +726,6 @@ static void convert_r5g6b5_x8r8g8b8(const BYTE *src, BYTE *dst, } } -static void convert_a8r8g8b8_x8r8g8b8(const BYTE *src, BYTE *dst, - DWORD pitch_in, DWORD pitch_out, unsigned int w, unsigned int h) -{ - unsigned int x, y; - - TRACE("Converting %ux%u pixels, pitches %u %u\n", w, h, pitch_in, pitch_out); - - for (y = 0; y < h; ++y) - { - const DWORD *src_line = (const DWORD *)(src + y * pitch_in); - DWORD *dst_line = (DWORD *)(dst + y * pitch_out); - - for (x = 0; x < w; ++x) - { - dst_line[x] = 0xff000000 | (src_line[x] & 0xffffff); - } - } -} - struct d3dfmt_convertor_desc { WINED3DFORMAT from, to; void (*convert)(const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, unsigned int w, unsigned int h); @@ -752,7 +735,6 @@ static const struct d3dfmt_convertor_desc convertors[] = { {WINED3DFMT_R32_FLOAT, WINED3DFMT_R16_FLOAT, convert_r32_float_r16_float}, {WINED3DFMT_R5G6B5, WINED3DFMT_X8R8G8B8, convert_r5g6b5_x8r8g8b8}, - {WINED3DFMT_A8R8G8B8, WINED3DFMT_X8R8G8B8, convert_a8r8g8b8_x8r8g8b8}, }; static inline const struct d3dfmt_convertor_desc *find_convertor(WINED3DFORMAT from, WINED3DFORMAT to) @@ -1135,6 +1117,8 @@ HRESULT WINAPI IWineD3DBaseSurfaceImpl_Blt(IWineD3DSurface *iface, const RECT *D dstwidth = xdst.right - xdst.left; width = (xdst.right - xdst.left) * bpp; + assert(width <= dlock.Pitch); + if (DestRect && Src != This) dbuf = dlock.pBits; else @@ -1635,6 +1619,7 @@ HRESULT WINAPI IWineD3DBaseSurfaceImpl_BltFast(IWineD3DSurface *iface, DWORD dst slock.Pitch = dlock.Pitch; /* Since slock was originally copied from this surface's description, we can just reuse it */ + assert(This->resource.allocatedMemory != NULL); sbuf = This->resource.allocatedMemory + lock_src.top * pitch + lock_src.left * bpp; dbuf = This->resource.allocatedMemory + lock_dst.top * pitch + lock_dst.left * bpp; sEntry = Src->resource.format_desc; diff --git a/dlls/wined3d/surface_gdi.c b/dlls/wined3d/surface_gdi.c index 02467829e83..a1945691e6d 100644 --- a/dlls/wined3d/surface_gdi.c +++ b/dlls/wined3d/surface_gdi.c @@ -29,6 +29,7 @@ #include "wine/port.h" #include "wined3d_private.h" +#include #include /* Use the d3d_surface debug channel to have one channel for all surfaces */ @@ -183,8 +184,7 @@ IWineGDISurfaceImpl_UnlockRect(IWineD3DSurface *iface) char buffer[4096]; ++gen; if ((gen % 10) == 0) { - snprintf(buffer, sizeof(buffer), "/tmp/surface%p_type%u_level%u_%u.ppm", - This, This->texture_target, This->texture_level, gen); + snprintf(buffer, sizeof(buffer), "/tmp/surface%p_type%u_level%u_%u.ppm", This, This->glDescription.target, This->glDescription.level, gen); IWineD3DSurfaceImpl_SaveSnapshot(iface, buffer); } /* @@ -200,10 +200,7 @@ IWineGDISurfaceImpl_UnlockRect(IWineD3DSurface *iface) /* Tell the swapchain to update the screen */ if (SUCCEEDED(IWineD3DSurface_GetContainer(iface, &IID_IWineD3DSwapChain, (void **)&swapchain))) { - if(iface == swapchain->frontBuffer) - { - x11_copy_to_screen(swapchain, &This->lockedRect); - } + x11_copy_to_screen(swapchain, &This->lockedRect); IWineD3DSwapChain_Release((IWineD3DSwapChain *) swapchain); } @@ -494,10 +491,7 @@ static HRESULT WINAPI IWineGDISurfaceImpl_RealizePalette(IWineD3DSurface *iface) /* Tell the swapchain to update the screen */ if (SUCCEEDED(IWineD3DSurface_GetContainer(iface, &IID_IWineD3DSwapChain, (void **)&swapchain))) { - if(iface == swapchain->frontBuffer) - { - x11_copy_to_screen(swapchain, NULL); - } + x11_copy_to_screen(swapchain, NULL); IWineD3DSwapChain_Release((IWineD3DSwapChain *) swapchain); } @@ -548,6 +542,12 @@ IWineGDISurfaceImpl_PrivateSetup(IWineD3DSurface *iface) return WINED3D_OK; } +static void WINAPI IWineGDISurfaceImpl_GetGlDesc(IWineD3DSurface *iface, glDescriptor **glDescription) { + IWineD3DSurfaceImpl *This = (IWineD3DSurfaceImpl *)iface; + FIXME("(%p) : Should not be called on a GDI surface\n", This); + *glDescription = NULL; +} + static HRESULT WINAPI IWineGDISurfaceImpl_SetMem(IWineD3DSurface *iface, void *Mem) { IWineD3DSurfaceImpl *This = (IWineD3DSurfaceImpl *) iface; @@ -677,6 +677,7 @@ const IWineD3DSurfaceVtbl IWineGDISurface_Vtbl = IWineD3DBaseSurfaceImpl_BindTexture, IWineGDISurfaceImpl_SaveSnapshot, IWineD3DBaseSurfaceImpl_SetContainer, + IWineGDISurfaceImpl_GetGlDesc, IWineD3DBaseSurfaceImpl_GetData, IWineD3DBaseSurfaceImpl_SetFormat, IWineGDISurfaceImpl_PrivateSetup, diff --git a/dlls/wined3d/swapchain.c b/dlls/wined3d/swapchain.c index 0994c6d8a69..12f812eb316 100644 --- a/dlls/wined3d/swapchain.c +++ b/dlls/wined3d/swapchain.c @@ -64,8 +64,7 @@ static void WINAPI IWineD3DSwapChainImpl_Destroy(IWineD3DSwapChain *iface, D3DCB HeapFree(GetProcessHeap(), 0, This->backBuffer); } - for (i = 0; i < This->num_contexts; ++i) - { + for(i = 0; i < This->num_contexts; i++) { DestroyContext(This->wineD3DDevice, This->context[i]); } /* Restore the screen resolution if we rendered in fullscreen @@ -112,9 +111,9 @@ static HRESULT WINAPI IWineD3DSwapChainImpl_Present(IWineD3DSwapChain *iface, CO cursor.resource.pool = WINED3DPOOL_SCRATCH; cursor.resource.format_desc = getFormatDescEntry(WINED3DFMT_A8R8G8B8, &This->wineD3DDevice->adapter->gl_info); cursor.resource.resourceType = WINED3DRTYPE_SURFACE; - cursor.texture_name = This->wineD3DDevice->cursorTexture; - cursor.texture_target = GL_TEXTURE_2D; - cursor.texture_level = 0; + cursor.glDescription.textureName = This->wineD3DDevice->cursorTexture; + cursor.glDescription.target = GL_TEXTURE_2D; + cursor.glDescription.level = 0; cursor.currentDesc.Width = This->wineD3DDevice->cursorWidth; cursor.currentDesc.Height = This->wineD3DDevice->cursorHeight; cursor.glRect.left = 0; @@ -224,7 +223,7 @@ static HRESULT WINAPI IWineD3DSwapChainImpl_Present(IWineD3DSwapChain *iface, CO TRACE("Clearing the color buffer with cyan color\n"); IWineD3DDevice_Clear((IWineD3DDevice*)This->wineD3DDevice, 0, NULL, - WINED3DCLEAR_TARGET, 0xff00ffff, 1.0f, 0); + WINED3DCLEAR_TARGET, 0xff00ffff, 1.0, 0); } if(((IWineD3DSurfaceImpl *) This->frontBuffer)->Flags & SFLAG_INSYSMEM || @@ -402,11 +401,10 @@ WineD3DContext *IWineD3DSwapChainImpl_CreateContextForThread(IWineD3DSwapChain * return ctx; } -void get_drawable_size_swapchain(struct WineD3DContext *context, UINT *width, UINT *height) -{ - IWineD3DSurfaceImpl *surface = (IWineD3DSurfaceImpl *)context->surface; +void get_drawable_size_swapchain(IWineD3DSurfaceImpl *This, UINT *width, UINT *height) { /* The drawable size of an onscreen drawable is the surface size. - * (Actually: The window size, but the surface is created in window size) */ - *width = surface->currentDesc.Width; - *height = surface->currentDesc.Height; + * (Actually: The window size, but the surface is created in window size) + */ + *width = This->currentDesc.Width; + *height = This->currentDesc.Height; } diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c index ab0544948eb..05e29bb77de 100644 --- a/dlls/wined3d/texture.c +++ b/dlls/wined3d/texture.c @@ -63,7 +63,7 @@ static void texture_internal_preload(IWineD3DBaseTexture *iface, enum WINED3DSRG { /* ActivateContext sets isInDraw to TRUE when loading a pbuffer into a texture, * thus no danger of recursive calls. */ - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); } if (This->resource.format_desc->format == WINED3DFMT_P8 @@ -127,7 +127,7 @@ static void texture_cleanup(IWineD3DTextureImpl *This, D3DCB_DESTROYSURFACEFN su HRESULT texture_init(IWineD3DTextureImpl *texture, UINT width, UINT height, UINT levels, IWineD3DDeviceImpl *device, DWORD usage, WINED3DFORMAT format, WINED3DPOOL pool, IUnknown *parent) { - const struct wined3d_gl_info *gl_info = &device->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &device->adapter->gl_info; const struct GlPixelFormatDesc *format_desc = getFormatDescEntry(format, gl_info); UINT pow2_width, pow2_height; UINT tmp_w, tmp_h; @@ -214,10 +214,10 @@ HRESULT texture_init(IWineD3DTextureImpl *texture, UINT width, UINT height, UINT * doesn't work in combination with ARB_TEXTURE_RECTANGLE. */ if (GL_SUPPORT(WINE_NORMALIZED_TEXRECT) && (width != pow2_width || height != pow2_height)) { - texture->baseTexture.pow2Matrix[0] = 1.0f; - texture->baseTexture.pow2Matrix[5] = 1.0f; - texture->baseTexture.pow2Matrix[10] = 1.0f; - texture->baseTexture.pow2Matrix[15] = 1.0f; + texture->baseTexture.pow2Matrix[0] = 1.0; + texture->baseTexture.pow2Matrix[5] = 1.0; + texture->baseTexture.pow2Matrix[10] = 1.0; + texture->baseTexture.pow2Matrix[15] = 1.0; texture->target = GL_TEXTURE_2D; texture->cond_np2 = TRUE; texture->baseTexture.minMipLookup = minMipLookup_noFilter; @@ -231,8 +231,8 @@ HRESULT texture_init(IWineD3DTextureImpl *texture, UINT width, UINT height, UINT texture->baseTexture.pow2Matrix[0] = (float)width; texture->baseTexture.pow2Matrix[5] = (float)height; - texture->baseTexture.pow2Matrix[10] = 1.0f; - texture->baseTexture.pow2Matrix[15] = 1.0f; + texture->baseTexture.pow2Matrix[10] = 1.0; + texture->baseTexture.pow2Matrix[15] = 1.0; texture->target = GL_TEXTURE_RECTANGLE_ARB; texture->cond_np2 = TRUE; texture->baseTexture.minMipLookup = minMipLookup_noFilter; @@ -247,12 +247,12 @@ HRESULT texture_init(IWineD3DTextureImpl *texture, UINT width, UINT height, UINT } else { - texture->baseTexture.pow2Matrix[0] = 1.0f; - texture->baseTexture.pow2Matrix[5] = 1.0f; + texture->baseTexture.pow2Matrix[0] = 1.0; + texture->baseTexture.pow2Matrix[5] = 1.0; } - texture->baseTexture.pow2Matrix[10] = 1.0f; - texture->baseTexture.pow2Matrix[15] = 1.0f; + texture->baseTexture.pow2Matrix[10] = 1.0; + texture->baseTexture.pow2Matrix[15] = 1.0; texture->target = GL_TEXTURE_2D; texture->cond_np2 = FALSE; } @@ -422,7 +422,6 @@ static BOOL WINAPI IWineD3DTextureImpl_GetDirty(IWineD3DTexture *iface) { return basetexture_get_dirty((IWineD3DBaseTexture *)iface); } -/* Context activation is done by the caller. */ static HRESULT WINAPI IWineD3DTextureImpl_BindTexture(IWineD3DTexture *iface, BOOL srgb) { IWineD3DTextureImpl *This = (IWineD3DTextureImpl *)iface; BOOL set_gl_texture_desc; diff --git a/dlls/wined3d/utils.c b/dlls/wined3d/utils.c index d2631ea0135..881736ee42d 100644 --- a/dlls/wined3d/utils.c +++ b/dlls/wined3d/utils.c @@ -353,7 +353,7 @@ static const GlPixelFormatDescTemplate gl_formats_template[] = { GL_RGBA, GL_UNSIGNED_INT_8_8_8_8_REV, WINED3DFMT_FLAG_POSTPIXELSHADER_BLENDING | WINED3DFMT_FLAG_FILTERING, WINED3D_GL_EXT_NONE}, - {WINED3DFMT_R16G16_UNORM, GL_RGB16_EXT, GL_RGB16_EXT, GL_RGBA16_EXT, + {WINED3DFMT_R16G16_UNORM, GL_RGB16_EXT, GL_RGB16_EXT, 0, GL_RGB, GL_UNSIGNED_SHORT, WINED3DFMT_FLAG_POSTPIXELSHADER_BLENDING | WINED3DFMT_FLAG_FILTERING, WINED3D_GL_EXT_NONE}, @@ -500,7 +500,7 @@ static inline int getFmtIdx(WINED3DFORMAT fmt) { return -1; } -static BOOL init_format_base_info(struct wined3d_gl_info *gl_info) +static BOOL init_format_base_info(WineD3D_GL_Info *gl_info) { UINT format_count = sizeof(formats) / sizeof(*formats); UINT i; @@ -529,7 +529,7 @@ static BOOL init_format_base_info(struct wined3d_gl_info *gl_info) return TRUE; } -static BOOL init_format_compression_info(struct wined3d_gl_info *gl_info) +static BOOL init_format_compression_info(WineD3D_GL_Info *gl_info) { unsigned int i; @@ -557,144 +557,41 @@ static BOOL init_format_compression_info(struct wined3d_gl_info *gl_info) #define GLINFO_LOCATION (*gl_info) -/* Context activation is done by the caller. */ -static void check_fbo_compat(const struct wined3d_gl_info *gl_info, struct GlPixelFormatDesc *format_desc) +static BOOL check_fbo_compat(const WineD3D_GL_Info *gl_info, GLint internal_format, GLenum format, GLenum type) { - /* Check if the default internal format is supported as a frame buffer - * target, otherwise fall back to the render target internal. - * - * Try to stick to the standard format if possible, this limits precision differences. */ GLenum status; GLuint tex; ENTER_GL(); while(glGetError()); - glDisable(GL_BLEND); - glGenTextures(1, &tex); glBindTexture(GL_TEXTURE_2D, tex); - - glTexImage2D(GL_TEXTURE_2D, 0, format_desc->glInternal, 16, 16, 0, - format_desc->glFormat, format_desc->glType, NULL); + glTexImage2D(GL_TEXTURE_2D, 0, internal_format, 16, 16, 0, format, type, NULL); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST); GL_EXTCALL(glFramebufferTexture2DEXT(GL_FRAMEBUFFER_EXT, GL_COLOR_ATTACHMENT0_EXT, GL_TEXTURE_2D, tex, 0)); status = GL_EXTCALL(glCheckFramebufferStatusEXT(GL_FRAMEBUFFER_EXT)); - checkGLcall("Framebuffer format check"); - - if (status == GL_FRAMEBUFFER_COMPLETE_EXT) - { - TRACE("Format %s is supported as FBO color attachment\n", debug_d3dformat(format_desc->format)); - format_desc->Flags |= WINED3DFMT_FLAG_FBO_ATTACHABLE; - format_desc->rtInternal = format_desc->glInternal; - } - else - { - if (!format_desc->rtInternal) - { - if (format_desc->Flags & WINED3DFMT_FLAG_RENDERTARGET) - { - FIXME("Format %s with rendertarget flag is not supported as FBO color attachment," - " and no fallback specified.\n", debug_d3dformat(format_desc->format)); - format_desc->Flags &= ~WINED3DFMT_FLAG_RENDERTARGET; - } - else - { - TRACE("Format %s is not supported as FBO color attachment.\n", debug_d3dformat(format_desc->format)); - } - format_desc->rtInternal = format_desc->glInternal; - } - else - { - TRACE("Format %s is not supported as FBO color attachment, trying rtInternal format as fallback.\n", - debug_d3dformat(format_desc->format)); - - while(glGetError()); - - GL_EXTCALL(glFramebufferTexture2DEXT(GL_FRAMEBUFFER_EXT, GL_COLOR_ATTACHMENT0_EXT, GL_TEXTURE_2D, 0, 0)); - - glTexImage2D(GL_TEXTURE_2D, 0, format_desc->rtInternal, 16, 16, 0, - format_desc->glFormat, format_desc->glType, NULL); - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST); - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST); - - GL_EXTCALL(glFramebufferTexture2DEXT(GL_FRAMEBUFFER_EXT, GL_COLOR_ATTACHMENT0_EXT, GL_TEXTURE_2D, tex, 0)); - - status = GL_EXTCALL(glCheckFramebufferStatusEXT(GL_FRAMEBUFFER_EXT)); - checkGLcall("Framebuffer format check"); - - if (status == GL_FRAMEBUFFER_COMPLETE_EXT) - { - TRACE("Format %s rtInternal format is supported as FBO color attachment\n", - debug_d3dformat(format_desc->format)); - } - else - { - FIXME("Format %s rtInternal format is not supported as FBO color attachment.\n", - debug_d3dformat(format_desc->format)); - format_desc->Flags &= ~WINED3DFMT_FLAG_RENDERTARGET; - } - } - } - - if (status == GL_FRAMEBUFFER_COMPLETE_EXT && format_desc->Flags & WINED3DFMT_FLAG_POSTPIXELSHADER_BLENDING) - { - GLuint rb; - - if (GL_SUPPORT(EXT_PACKED_DEPTH_STENCIL)) - { - GL_EXTCALL(glGenRenderbuffersEXT(1, &rb)); - GL_EXTCALL(glBindRenderbufferEXT(GL_RENDERBUFFER_EXT, rb)); - GL_EXTCALL(glRenderbufferStorageEXT(GL_RENDERBUFFER_EXT, GL_DEPTH24_STENCIL8_EXT, 16, 16)); - GL_EXTCALL(glFramebufferRenderbufferEXT(GL_FRAMEBUFFER_EXT, GL_DEPTH_ATTACHMENT_EXT, - GL_RENDERBUFFER_EXT, rb)); - GL_EXTCALL(glFramebufferRenderbufferEXT(GL_FRAMEBUFFER_EXT, GL_STENCIL_ATTACHMENT_EXT, - GL_RENDERBUFFER_EXT, rb)); - checkGLcall("RB attachment"); - } - - glEnable(GL_BLEND); - glClear(GL_COLOR_BUFFER_BIT); - if (glGetError() == GL_INVALID_FRAMEBUFFER_OPERATION_EXT) - { - while(glGetError()); - TRACE("Format doesn't support post-pixelshader blending.\n"); - format_desc->Flags &= ~WINED3DFMT_FLAG_POSTPIXELSHADER_BLENDING; - } - - if (GL_SUPPORT(EXT_PACKED_DEPTH_STENCIL)) - { - GL_EXTCALL(glFramebufferRenderbufferEXT(GL_FRAMEBUFFER_EXT, GL_DEPTH_ATTACHMENT_EXT, - GL_RENDERBUFFER_EXT, 0)); - GL_EXTCALL(glFramebufferRenderbufferEXT(GL_FRAMEBUFFER_EXT, GL_STENCIL_ATTACHMENT_EXT, - GL_RENDERBUFFER_EXT, 0)); - GL_EXTCALL(glDeleteRenderbuffersEXT(1, &rb)); - checkGLcall("RB cleanup"); - } - } - glDeleteTextures(1, &tex); + checkGLcall("Framebuffer format check"); + LEAVE_GL(); + + return status == GL_FRAMEBUFFER_COMPLETE_EXT; } -/* Context activation is done by the caller. */ -static void init_format_fbo_compat_info(struct wined3d_gl_info *gl_info) +static void init_format_fbo_compat_info(WineD3D_GL_Info *gl_info) { unsigned int i; GLuint fbo; if (wined3d_settings.offscreen_rendering_mode == ORM_FBO) { - ENTER_GL(); - GL_EXTCALL(glGenFramebuffersEXT(1, &fbo)); GL_EXTCALL(glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, fbo)); - - LEAVE_GL(); } for (i = 0; i < sizeof(formats) / sizeof(*formats); ++i) @@ -720,7 +617,39 @@ static void init_format_fbo_compat_info(struct wined3d_gl_info *gl_info) if (wined3d_settings.offscreen_rendering_mode == ORM_FBO) { TRACE("Checking if format %s is supported as FBO color attachment...\n", debug_d3dformat(desc->format)); - check_fbo_compat(gl_info, desc); + + /* Check if the default internal format is supported as a frame buffer target, otherwise + * fall back to the render target internal. + * + * Try to stick to the standard format if possible, this limits precision differences. */ + if (check_fbo_compat(gl_info, desc->glInternal, desc->glFormat, desc->glType)) + { + TRACE("Format %s is supported as FBO color attachment\n", debug_d3dformat(desc->format)); + desc->Flags |= WINED3DFMT_FLAG_FBO_ATTACHABLE; + desc->rtInternal = desc->glInternal; + } + else + { + if (!desc->rtInternal) + { + if (desc->Flags & WINED3DFMT_FLAG_RENDERTARGET) + { + FIXME("Format %s with rendertarget flag is not supported as FBO color attachment," + " and no fallback specified.\n", debug_d3dformat(desc->format)); + desc->Flags &= ~WINED3DFMT_FLAG_RENDERTARGET; + } + else + { + TRACE("Format %s is not supported as FBO color attachment.\n", debug_d3dformat(desc->format)); + } + desc->rtInternal = desc->glInternal; + } + else + { + TRACE("Format %s is not supported as FBO color attachment, using rtInternal format as fallback.\n", + debug_d3dformat(desc->format)); + } + } } else { @@ -730,15 +659,11 @@ static void init_format_fbo_compat_info(struct wined3d_gl_info *gl_info) if (wined3d_settings.offscreen_rendering_mode == ORM_FBO) { - ENTER_GL(); - GL_EXTCALL(glDeleteFramebuffersEXT(1, &fbo)); - - LEAVE_GL(); } } -static BOOL init_format_texture_info(struct wined3d_gl_info *gl_info) +static BOOL init_format_texture_info(WineD3D_GL_Info *gl_info) { unsigned int i; @@ -764,13 +689,13 @@ static BOOL init_format_texture_info(struct wined3d_gl_info *gl_info) desc->glType = gl_formats_template[i].glType; desc->color_fixup = COLOR_FIXUP_IDENTITY; desc->Flags |= gl_formats_template[i].Flags; - desc->heightscale = 1.0f; + desc->heightscale = 1.0; } return TRUE; } -static void apply_format_fixups(struct wined3d_gl_info *gl_info) +static void apply_format_fixups(WineD3D_GL_Info *gl_info) { int idx; @@ -869,7 +794,7 @@ static void apply_format_fixups(struct wined3d_gl_info *gl_info) } idx = getFmtIdx(WINED3DFMT_YV12); - gl_info->gl_formats[idx].heightscale = 1.5f; + gl_info->gl_formats[idx].heightscale = 1.5; gl_info->gl_formats[idx].color_fixup = create_yuv_fixup_desc(YUV_FIXUP_YV12); if (GL_SUPPORT(EXT_VERTEX_ARRAY_BGRA)) @@ -890,7 +815,7 @@ static void apply_format_fixups(struct wined3d_gl_info *gl_info) } } -static BOOL init_format_vertex_info(struct wined3d_gl_info *gl_info) +static BOOL init_format_vertex_info(WineD3D_GL_Info *gl_info) { unsigned int i; @@ -918,7 +843,7 @@ static BOOL init_format_vertex_info(struct wined3d_gl_info *gl_info) return TRUE; } -BOOL initPixelFormatsNoGL(struct wined3d_gl_info *gl_info) +BOOL initPixelFormatsNoGL(WineD3D_GL_Info *gl_info) { if (!init_format_base_info(gl_info)) return FALSE; @@ -931,8 +856,7 @@ BOOL initPixelFormatsNoGL(struct wined3d_gl_info *gl_info) return TRUE; } -/* Context activation is done by the caller. */ -BOOL initPixelFormats(struct wined3d_gl_info *gl_info) +BOOL initPixelFormats(WineD3D_GL_Info *gl_info) { if (!init_format_base_info(gl_info)) return FALSE; @@ -954,7 +878,7 @@ fail: #define GLINFO_LOCATION This->adapter->gl_info -const struct GlPixelFormatDesc *getFormatDescEntry(WINED3DFORMAT fmt, const struct wined3d_gl_info *gl_info) +const struct GlPixelFormatDesc *getFormatDescEntry(WINED3DFORMAT fmt, const WineD3D_GL_Info *gl_info) { int idx = getFmtIdx(fmt); @@ -2029,8 +1953,7 @@ BOOL CalculateTexRect(IWineD3DSurfaceImpl *This, RECT *Rect, float glTexCoord[4] /* No oversized texture? This is easy */ if(!(This->Flags & SFLAG_OVERSIZE)) { /* Which rect from the texture do I need? */ - if (This->texture_target == GL_TEXTURE_RECTANGLE_ARB) - { + if(This->glDescription.target == GL_TEXTURE_RECTANGLE_ARB) { glTexCoord[0] = (float) Rect->left; glTexCoord[2] = (float) Rect->top; glTexCoord[1] = (float) Rect->right; @@ -2168,7 +2091,6 @@ void gen_ffp_frag_op(IWineD3DStateBlockImpl *stateblock, struct ffp_frag_setting unsigned int i; DWORD ttff; DWORD cop, aop, carg0, carg1, carg2, aarg0, aarg1, aarg2; - IWineD3DDeviceImpl *device = stateblock->wineD3DDevice; for(i = 0; i < GL_LIMITS(texture_stages); i++) { IWineD3DBaseTextureImpl *texture; @@ -2222,7 +2144,8 @@ void gen_ffp_frag_op(IWineD3DStateBlockImpl *stateblock, struct ffp_frag_setting carg2 = (args[cop] & ARG2) ? stateblock->textureState[i][WINED3DTSS_COLORARG2] : ARG_UNUSED; carg0 = (args[cop] & ARG0) ? stateblock->textureState[i][WINED3DTSS_COLORARG0] : ARG_UNUSED; - if(is_invalid_op(device, i, cop, carg1, carg2, carg0)) { + if(is_invalid_op(stateblock->wineD3DDevice, i, cop, + carg1, carg2, carg0)) { carg0 = ARG_UNUSED; carg2 = ARG_UNUSED; carg1 = WINED3DTA_CURRENT; @@ -2281,7 +2204,8 @@ void gen_ffp_frag_op(IWineD3DStateBlockImpl *stateblock, struct ffp_frag_setting } } - if(is_invalid_op(device, i, aop, aarg1, aarg2, aarg0)) { + if(is_invalid_op(stateblock->wineD3DDevice, i, aop, + aarg1, aarg2, aarg0)) { aarg0 = ARG_UNUSED; aarg2 = ARG_UNUSED; aarg1 = WINED3DTA_CURRENT; @@ -2360,14 +2284,6 @@ void gen_ffp_frag_op(IWineD3DStateBlockImpl *stateblock, struct ffp_frag_setting } else { settings->sRGB_write = 0; } - if(device->vs_clipping || !use_vs(stateblock)) { - /* No need to emulate clipplanes if GL supports native vertex shader clipping or if - * the fixed function vertex pipeline is used(which always supports clipplanes) - */ - settings->emul_clipplanes = 0; - } else { - settings->emul_clipplanes = 1; - } } #undef GLINFO_LOCATION diff --git a/dlls/wined3d/vertexshader.c b/dlls/wined3d/vertexshader.c index 6348e1c3cd1..6c1440d4c25 100644 --- a/dlls/wined3d/vertexshader.c +++ b/dlls/wined3d/vertexshader.c @@ -280,10 +280,10 @@ static HRESULT WINAPI IWineD3DVertexShaderImpl_SetFunction(IWineD3DVertexShader vshader_set_limits(This); - if (deviceImpl->vs_selected_mode == SHADER_ARB - && ((GLINFO_LOCATION).quirks & WINED3D_QUIRK_ARB_VS_OFFSET_LIMIT) - && This->min_rel_offset <= This->max_rel_offset) - { + if(deviceImpl->vs_selected_mode == SHADER_ARB && + (GLINFO_LOCATION).arb_vs_offset_limit && + This->min_rel_offset <= This->max_rel_offset) { + if(This->max_rel_offset - This->min_rel_offset > 127) { FIXME("The difference between the minimum and maximum relative offset is > 127\n"); FIXME("Which this OpenGL implementation does not support. Try using GLSL\n"); diff --git a/dlls/wined3d/volume.c b/dlls/wined3d/volume.c index 871fdf73135..829607d2fba 100644 --- a/dlls/wined3d/volume.c +++ b/dlls/wined3d/volume.c @@ -26,7 +26,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3d_surface); #define GLINFO_LOCATION This->resource.wineD3DDevice->adapter->gl_info -/* Context activation is done by the caller. */ static void volume_bind_and_dirtify(IWineD3DVolume *iface) { IWineD3DVolumeImpl *This = (IWineD3DVolumeImpl *)iface; IWineD3DVolumeTexture *texture; @@ -302,7 +301,6 @@ static HRESULT WINAPI IWineD3DVolumeImpl_SetContainer(IWineD3DVolume *iface, IWi return WINED3D_OK; } -/* Context activation is done by the caller. */ static HRESULT WINAPI IWineD3DVolumeImpl_LoadTexture(IWineD3DVolume *iface, int gl_level, BOOL srgb_mode) { IWineD3DVolumeImpl *This = (IWineD3DVolumeImpl *)iface; const struct GlPixelFormatDesc *glDesc = This->resource.format_desc; diff --git a/dlls/wined3d/volumetexture.c b/dlls/wined3d/volumetexture.c index a847f87623b..491525b31f8 100644 --- a/dlls/wined3d/volumetexture.c +++ b/dlls/wined3d/volumetexture.c @@ -32,7 +32,7 @@ static void volumetexture_internal_preload(IWineD3DBaseTexture *iface, enum WINE /* Override the IWineD3DResource Preload method. */ IWineD3DVolumeTextureImpl *This = (IWineD3DVolumeTextureImpl *)iface; IWineD3DDeviceImpl *device = This->resource.wineD3DDevice; - const struct wined3d_gl_info *gl_info = &device->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &device->adapter->gl_info; BOOL srgb_mode = This->baseTexture.is_srgb; BOOL srgb_was_toggled = FALSE; unsigned int i; @@ -41,7 +41,7 @@ static void volumetexture_internal_preload(IWineD3DBaseTexture *iface, enum WINE if (!device->isInDraw) { - ActivateContext(device, NULL, CTXUSAGE_RESOURCELOAD); + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); } else if (GL_SUPPORT(EXT_TEXTURE_SRGB) && This->baseTexture.bindCount > 0) { @@ -99,7 +99,7 @@ static void volumetexture_cleanup(IWineD3DVolumeTextureImpl *This, D3DCB_DESTROY HRESULT volumetexture_init(IWineD3DVolumeTextureImpl *texture, UINT width, UINT height, UINT depth, UINT levels, IWineD3DDeviceImpl *device, DWORD usage, WINED3DFORMAT format, WINED3DPOOL pool, IUnknown *parent) { - const struct wined3d_gl_info *gl_info = &device->adapter->gl_info; + const WineD3D_GL_Info *gl_info = &device->adapter->gl_info; const struct GlPixelFormatDesc *format_desc = getFormatDescEntry(format, gl_info); UINT tmp_w, tmp_h, tmp_d; unsigned int i; @@ -162,10 +162,10 @@ HRESULT volumetexture_init(IWineD3DVolumeTextureImpl *texture, UINT width, UINT } /* Is NP2 support for volumes needed? */ - texture->baseTexture.pow2Matrix[0] = 1.0f; - texture->baseTexture.pow2Matrix[5] = 1.0f; - texture->baseTexture.pow2Matrix[10] = 1.0f; - texture->baseTexture.pow2Matrix[15] = 1.0f; + texture->baseTexture.pow2Matrix[0] = 1.0; + texture->baseTexture.pow2Matrix[5] = 1.0; + texture->baseTexture.pow2Matrix[10] = 1.0; + texture->baseTexture.pow2Matrix[15] = 1.0; /* Generate all the surfaces. */ tmp_w = width; @@ -331,7 +331,6 @@ static BOOL WINAPI IWineD3DVolumeTextureImpl_GetDirty(IWineD3DVolumeTexture *ifa return basetexture_get_dirty((IWineD3DBaseTexture *)iface); } -/* Context activation is done by the caller. */ static HRESULT WINAPI IWineD3DVolumeTextureImpl_BindTexture(IWineD3DVolumeTexture *iface, BOOL srgb) { IWineD3DVolumeTextureImpl *This = (IWineD3DVolumeTextureImpl *)iface; BOOL dummy; diff --git a/dlls/wined3d/wined3d_gl.h b/dlls/wined3d/wined3d_gl.h index dcb526b0059..9f508a8dafa 100644 --- a/dlls/wined3d/wined3d_gl.h +++ b/dlls/wined3d/wined3d_gl.h @@ -3378,7 +3378,6 @@ typedef enum _GL_Cards { CARD_INTEL_I915G = 0x2582, CARD_INTEL_I915GM = 0x2592, CARD_INTEL_I945GM = 0x27a2, /* Same as GMA 950?? */ - CARD_INTEL_X3100 = 0x2a02, /* found in macs. Same as GMA 965? */ } GL_Cards; #define WINE_DEFAULT_VIDMEM 64*1024*1024 @@ -3949,68 +3948,78 @@ typedef BOOL (WINAPI * WINED3D_PFNWGLSETPIXELFORMATWINE) (HDC hdc, int iPixelFor ****************************************************/ #define USE_GL_FUNC(type, pfn, ext, replace) type pfn; +typedef struct _WineD3D_GL_Info { + + DWORD glx_version; + DWORD gl_version; + + GL_Vendors gl_vendor; + GL_Cards gl_card; + UINT vidmem; + DWORD driver_version; + DWORD driver_version_hipart; + CHAR driver_description[255]; + CHAR gl_renderer[255]; + /** + * CAPS Constants + */ + UINT max_buffers; + UINT max_lights; + UINT max_textures; + UINT max_texture_stages; + UINT max_fragment_samplers; + UINT max_vertex_samplers; + UINT max_combined_samplers; + UINT max_sampler_stages; + UINT max_clipplanes; + UINT max_texture_size; + UINT max_texture3d_size; + float max_pointsize, max_pointsizemin; + UINT max_point_sprite_units; + UINT max_blends; + UINT max_anisotropy; + UINT max_glsl_varyings; + float max_shininess; + + unsigned max_vshader_constantsF; + unsigned max_pshader_constantsF; + + unsigned vs_arb_constantsF; + unsigned vs_arb_max_instructions; + unsigned vs_arb_max_temps; + unsigned ps_arb_constantsF; + unsigned ps_arb_max_instructions; + unsigned ps_arb_max_temps; + unsigned vs_glsl_constantsF; + unsigned ps_glsl_constantsF; + + GL_PSVersion ps_arb_version; + GL_PSVersion ps_nv_version; + + GL_VSVersion vs_arb_version; + GL_VSVersion vs_nv_version; + GL_VSVersion vs_ati_version; + + BOOL arb_vs_offset_limit; + BOOL set_texcoord_w; + DWORD reserved_glsl_constants; + BOOL glsl_clip_varying; + + BOOL supported[WINED3D_GL_EXT_COUNT]; + + /** OpenGL EXT and ARB functions ptr */ + GL_EXT_FUNCS_GEN + /** OpenGL WGL functions ptr */ + WGL_EXT_FUNCS_GEN + + struct GlPixelFormatDesc *gl_formats; +} WineD3D_GL_Info; +#undef USE_GL_FUNC -struct wined3d_gl_info -{ - GL_Vendors gl_vendor; - GL_Cards gl_card; - UINT vidmem; - DWORD driver_version; - DWORD driver_version_hipart; - const char *driver_description; - - UINT max_buffers; - UINT max_lights; - UINT max_textures; - UINT max_texture_stages; - UINT max_fragment_samplers; - UINT max_vertex_samplers; - UINT max_combined_samplers; - UINT max_sampler_stages; - UINT max_clipplanes; - UINT max_texture_size; - UINT max_texture3d_size; - float max_pointsize, max_pointsizemin; - UINT max_point_sprite_units; - UINT max_blends; - UINT max_anisotropy; - UINT max_glsl_varyings; - float max_shininess; - - unsigned int max_vshader_constantsF; - unsigned int max_pshader_constantsF; - - unsigned int vs_arb_constantsF; - unsigned int vs_arb_max_instructions; - unsigned int vs_arb_max_temps; - unsigned int ps_arb_constantsF; - unsigned int ps_arb_max_local_constants; - unsigned int ps_arb_max_instructions; - unsigned int ps_arb_max_temps; - unsigned int vs_glsl_constantsF; - unsigned int ps_glsl_constantsF; - - GL_PSVersion ps_arb_version; - GL_PSVersion ps_nv_version; - - GL_VSVersion vs_arb_version; - GL_VSVersion vs_nv_version; - GL_VSVersion vs_ati_version; - - DWORD reserved_glsl_constants; - - DWORD quirks; - - BOOL supported[WINED3D_GL_EXT_COUNT]; - - /* GL function pointers */ - GL_EXT_FUNCS_GEN - /* WGL function pointers */ - WGL_EXT_FUNCS_GEN - - struct GlPixelFormatDesc *gl_formats; +struct driver_quirk { + BOOL (*match)(const WineD3D_GL_Info *gl_info); + void (*apply)(WineD3D_GL_Info *gl_info); + const char *description; }; -#undef USE_GL_FUNC - #endif /* __WINE_WINED3D_GL */ diff --git a/dlls/wined3d/wined3d_main.c b/dlls/wined3d/wined3d_main.c index 045eea0082b..f996aecdfcf 100644 --- a/dlls/wined3d/wined3d_main.c +++ b/dlls/wined3d/wined3d_main.c @@ -97,7 +97,6 @@ static void CDECL wined3d_do_nothing(void) static BOOL wined3d_init(HINSTANCE hInstDLL) { - DWORD wined3d_context_tls_idx; HMODULE mod; char buffer[MAX_PATH+10]; DWORD size = sizeof(buffer); @@ -106,15 +105,6 @@ static BOOL wined3d_init(HINSTANCE hInstDLL) DWORD len, tmpvalue; WNDCLASSA wc; - wined3d_context_tls_idx = TlsAlloc(); - if (wined3d_context_tls_idx == TLS_OUT_OF_INDEXES) - { - DWORD err = GetLastError(); - ERR("Failed to allocate context TLS index, err %#x.\n", err); - return FALSE; - } - context_set_tls_idx(wined3d_context_tls_idx); - /* We need our own window class for a fake window which we use to retrieve GL capabilities */ /* We might need CS_OWNDC in the future if we notice strange things on Windows. * Various articles/posts about OpenGL problems on Windows recommend this. */ @@ -132,11 +122,6 @@ static BOOL wined3d_init(HINSTANCE hInstDLL) if (!RegisterClassA(&wc)) { ERR("Failed to register window class 'WineD3D_OpenGL'!\n"); - if (!TlsFree(wined3d_context_tls_idx)) - { - DWORD err = GetLastError(); - ERR("Failed to free context TLS index, err %#x.\n", err); - } return FALSE; } @@ -337,14 +322,6 @@ static BOOL wined3d_init(HINSTANCE hInstDLL) static BOOL wined3d_destroy(HINSTANCE hInstDLL) { - DWORD wined3d_context_tls_idx = context_get_tls_idx(); - - if (!TlsFree(wined3d_context_tls_idx)) - { - DWORD err = GetLastError(); - ERR("Failed to free context TLS index, err %#x.\n", err); - } - HeapFree(GetProcessHeap(), 0, wined3d_settings.logo); UnregisterClassA(WINED3D_OPENGL_WINDOW_CLASS_NAME, hInstDLL); @@ -364,15 +341,6 @@ BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpv) case DLL_PROCESS_DETACH: return wined3d_destroy(hInstDLL); - case DLL_THREAD_DETACH: - { - if (!context_set_current(NULL)) - { - ERR("Failed to clear current context.\n"); - } - return TRUE; - } - default: return TRUE; } diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index 00f311dd648..b7c5592d09e 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -43,12 +43,6 @@ #include "wine/list.h" #include "wine/rbtree.h" -/* Driver quirks */ -#define WINED3D_QUIRK_ARB_VS_OFFSET_LIMIT 0x00000001 -#define WINED3D_QUIRK_SET_TEXCOORD_W 0x00000002 -#define WINED3D_QUIRK_GLSL_CLIP_VARYING 0x00000004 -#define WINED3D_QUIRK_ALLOWS_SPECULAR_ALPHA 0x00000008 - /* Texture format fixups */ enum fixup_channel_source @@ -198,16 +192,16 @@ static inline float float_16_to_32(const unsigned short *in) { const unsigned short s = ((*in) & 0x8000); const unsigned short e = ((*in) & 0x7C00) >> 10; const unsigned short m = (*in) & 0x3FF; - const float sgn = (s ? -1.0f : 1.0f); + const float sgn = (s ? -1.0 : 1.0); if(e == 0) { - if(m == 0) return sgn * 0.0f; /* +0.0 or -0.0 */ - else return sgn * pow(2, -14.0f) * ((float)m / 1024.0f); + if(m == 0) return sgn * 0.0; /* +0.0 or -0.0 */ + else return sgn * pow(2, -14.0) * ( (float) m / 1024.0); } else if(e < 31) { - return sgn * pow(2, (float)e - 15.0f) * (1.0f + ((float)m / 1024.0f)); + return sgn * pow(2, (float) e-15.0) * (1.0 + ((float) m / 1024.0)); } else { - if(m == 0) return sgn / 0.0f; /* +INF / -INF */ - else return 0.0f / 0.0f; /* NAN */ + if(m == 0) return sgn / 0.0; /* +INF / -INF */ + else return 0.0 / 0.0; /* NAN */ } } @@ -228,8 +222,8 @@ static inline float float_24_to_32(DWORD in) } else { - if (m == 0) return sgn / 0.0f; /* +INF / -INF */ - else return 0.0f / 0.0f; /* NAN */ + if (m == 0) return sgn / 0.0; /* +INF / -INF */ + else return 0.0 / 0.0; /* NAN */ } } @@ -325,7 +319,6 @@ typedef enum _WINED3DSHADER_PARAM_REGISTER_TYPE WINED3DSPR_LABEL = 18, WINED3DSPR_PREDICATE = 19, WINED3DSPR_IMMCONST, - WINED3DSPR_CONSTBUFFER, } WINED3DSHADER_PARAM_REGISTER_TYPE; enum wined3d_immconst_type @@ -507,14 +500,12 @@ typedef enum COMPARISON_TYPE #define MAX_LABELS 16 #define SHADER_PGMSIZE 65535 - -struct wined3d_shader_buffer -{ - char *buffer; +typedef struct SHADER_BUFFER { + char* buffer; unsigned int bsize; unsigned int lineNo; BOOL newline; -}; +} SHADER_BUFFER; enum WINED3D_SHADER_INSTRUCTION_HANDLER { @@ -649,13 +640,10 @@ typedef struct shader_reg_maps unsigned usesrelconstF : 1; unsigned fog : 1; unsigned usestexldl : 1; - unsigned usesifc : 1; - unsigned usescall : 1; - unsigned padding : 4; + unsigned padding : 6; /* Whether or not loops are used in this shader, and nesting depth */ unsigned loop_depth; - unsigned highest_render_target; } shader_reg_maps; @@ -663,7 +651,7 @@ struct wined3d_shader_context { IWineD3DBaseShader *shader; const struct shader_reg_maps *reg_maps; - struct wined3d_shader_buffer *buffer; + SHADER_BUFFER *buffer; void *backend_data; }; @@ -671,7 +659,6 @@ struct wined3d_shader_register { WINED3DSHADER_PARAM_REGISTER_TYPE type; UINT idx; - UINT array_idx; const struct wined3d_shader_src_param *rel_addr; enum wined3d_immconst_type immconst_type; DWORD immconst_data[4]; @@ -822,7 +809,7 @@ typedef struct { HRESULT (*shader_alloc_private)(IWineD3DDevice *iface); void (*shader_free_private)(IWineD3DDevice *iface); BOOL (*shader_dirtifyable_constants)(IWineD3DDevice *iface); - void (*shader_get_caps)(WINED3DDEVTYPE devtype, const struct wined3d_gl_info *gl_info, struct shader_caps *caps); + void (*shader_get_caps)(WINED3DDEVTYPE devtype, const WineD3D_GL_Info *gl_info, struct shader_caps *caps); BOOL (*shader_color_fixup_supported)(struct color_fixup_desc fixup); void (*shader_add_instruction_modifiers)(const struct wined3d_shader_instruction *ins); } shader_backend_t; @@ -885,19 +872,17 @@ extern int num_lock; /* Checking of API calls */ /* --------------------- */ #ifndef WINE_NO_DEBUG_MSGS -#define checkGLcall(A) \ -do { \ - GLint err; \ - if(!__WINE_IS_DEBUG_ON(_FIXME, __wine_dbch___default)) break; \ - err = glGetError(); \ - if (err == GL_NO_ERROR) { \ - TRACE("%s call ok %s / %d\n", A, __FILE__, __LINE__); \ - \ - } else do { \ - FIXME(">>>>>>>>>>>>>>>>> %s (%#x) from %s @ %s / %d\n", \ - debug_glerror(err), err, A, __FILE__, __LINE__); \ - err = glGetError(); \ - } while (err != GL_NO_ERROR); \ +#define checkGLcall(A) \ +do { \ + GLint err = glGetError(); \ + if (err == GL_NO_ERROR) { \ + TRACE("%s call ok %s / %d\n", A, __FILE__, __LINE__); \ + \ + } else do { \ + FIXME(">>>>>>>>>>>>>>>>> %s (%#x) from %s @ %s / %d\n", \ + debug_glerror(err), err, A, __FILE__, __LINE__); \ + err = glGetError(); \ + } while (err != GL_NO_ERROR); \ } while(0) #else #define checkGLcall(A) do {} while(0) @@ -1146,7 +1131,7 @@ struct fragment_caps { struct fragment_pipeline { void (*enable_extension)(IWineD3DDevice *iface, BOOL enable); - void (*get_caps)(WINED3DDEVTYPE devtype, const struct wined3d_gl_info *gl_info, struct fragment_caps *caps); + void (*get_caps)(WINED3DDEVTYPE devtype, const WineD3D_GL_Info *gl_info, struct fragment_caps *caps); HRESULT (*alloc_private)(IWineD3DDevice *iface); void (*free_private)(IWineD3DDevice *iface); BOOL (*color_fixup_supported)(struct color_fixup_desc fixup); @@ -1164,7 +1149,7 @@ extern const struct fragment_pipeline nvrc_fragment_pipeline; /* "Base" state table */ HRESULT compile_state_table(struct StateEntry *StateTable, APPLYSTATEFUNC **dev_multistate_funcs, - const struct wined3d_gl_info *gl_info, const struct StateEntryTemplate *vertex, + const WineD3D_GL_Info *gl_info, const struct StateEntryTemplate *vertex, const struct fragment_pipeline *fragment, const struct StateEntryTemplate *misc); /* Shaders for color conversions in blits */ @@ -1188,24 +1173,8 @@ enum fogsource { #define WINED3D_MAX_FBO_ENTRIES 64 -struct wined3d_occlusion_query -{ - struct list entry; - GLuint id; - struct WineD3DContext *context; -}; - -struct wined3d_event_query -{ - struct list entry; - GLuint id; - struct WineD3DContext *context; -}; - /* The new context manager that should deal with onscreen and offscreen rendering */ -struct WineD3DContext -{ - const struct wined3d_gl_info *gl_info; +struct WineD3DContext { /* State dirtification * dirtyArray is an array that contains markers for dirty states. numDirtyEntries states are dirty, their numbers are in indices * 0...numDirtyEntries - 1. isStateDirty is a redundant copy of the dirtyArray. Technically only one of them would be needed, @@ -1217,7 +1186,6 @@ struct WineD3DContext DWORD isStateDirty[STATE_HIGHEST/32 + 1]; /* Bitmap to find out quickly if a state is dirty */ IWineD3DSurface *surface; - IWineD3DSurface *current_rt; DWORD tid; /* Thread ID which owns this context at the moment */ /* Stores some information about the context state for optimization */ @@ -1233,9 +1201,7 @@ struct WineD3DContext WORD isPBuffer : 1; WORD fog_enabled : 1; WORD num_untracked_materials : 2; /* Max value 2 */ - WORD current : 1; - WORD destroyed : 1; - WORD padding : 1; + WORD padding : 3; BYTE texShaderBumpMap; /* MAX_TEXTURES, 8 */ BYTE lastWasPow2Texture; /* MAX_TEXTURES, 8 */ DWORD numbered_array_mask; @@ -1259,19 +1225,6 @@ struct WineD3DContext struct fbo_entry *current_fbo; GLuint src_fbo; GLuint dst_fbo; - GLuint fbo_read_binding; - GLuint fbo_draw_binding; - - /* Queries */ - GLuint *free_occlusion_queries; - UINT free_occlusion_query_size; - UINT free_occlusion_query_count; - struct list occlusion_queries; - - GLuint *free_event_queries; - UINT free_event_query_size; - UINT free_event_query_count; - struct list event_queries; /* Extension emulation */ GLint gl_fog_source; @@ -1287,23 +1240,14 @@ typedef enum ContextUsage { CTXUSAGE_CLEAR = 4, /* Drawable and states are set up for clearing */ } ContextUsage; -struct WineD3DContext *ActivateContext(IWineD3DDeviceImpl *This, IWineD3DSurface *target, enum ContextUsage usage); +void ActivateContext(IWineD3DDeviceImpl *device, IWineD3DSurface *target, ContextUsage usage); +WineD3DContext *getActiveContext(void); WineD3DContext *CreateContext(IWineD3DDeviceImpl *This, IWineD3DSurfaceImpl *target, HWND win, BOOL create_pbuffer, const WINED3DPRESENT_PARAMETERS *pPresentParms); void DestroyContext(IWineD3DDeviceImpl *This, WineD3DContext *context); -void context_alloc_event_query(struct WineD3DContext *context, struct wined3d_event_query *query); -void context_alloc_occlusion_query(struct WineD3DContext *context, struct wined3d_occlusion_query *query); void context_resource_released(IWineD3DDevice *iface, IWineD3DResource *resource, WINED3DRESOURCETYPE type); -void context_bind_fbo(struct WineD3DContext *context, GLenum target, GLuint *fbo); -void context_attach_depth_stencil_fbo(struct WineD3DContext *context, - GLenum fbo_target, IWineD3DSurface *depth_stencil, BOOL use_render_buffer); -void context_attach_surface_fbo(const struct WineD3DContext *context, - GLenum fbo_target, DWORD idx, IWineD3DSurface *surface); -void context_free_event_query(struct wined3d_event_query *query); -void context_free_occlusion_query(struct wined3d_occlusion_query *query); -struct WineD3DContext *context_get_current(void); -DWORD context_get_tls_idx(void); -BOOL context_set_current(struct WineD3DContext *ctx); -void context_set_tls_idx(DWORD idx); +void context_bind_fbo(IWineD3DDevice *iface, GLenum target, GLuint *fbo); +void context_attach_depth_stencil_fbo(IWineD3DDeviceImpl *This, GLenum fbo_target, IWineD3DSurface *depth_stencil, BOOL use_render_buffer); +void context_attach_surface_fbo(IWineD3DDeviceImpl *This, GLenum fbo_target, DWORD idx, IWineD3DSurface *surface); void delete_opengl_contexts(IWineD3DDevice *iface, IWineD3DSwapChain *swapchain); HRESULT create_primary_opengl_context(IWineD3DDevice *iface, IWineD3DSwapChain *swapchain); @@ -1362,7 +1306,7 @@ struct WineD3DAdapter UINT num; BOOL opengl; POINT monitorPoint; - struct wined3d_gl_info gl_info; + WineD3D_GL_Info gl_info; const char *driver; const char *description; WCHAR DeviceName[CCHDEVICENAME]; /* DeviceName for use with e.g. ChangeDisplaySettings */ @@ -1373,10 +1317,10 @@ struct WineD3DAdapter unsigned int UsedTextureRam; }; -extern BOOL initPixelFormats(struct wined3d_gl_info *gl_info); -BOOL initPixelFormatsNoGL(struct wined3d_gl_info *gl_info); +extern BOOL initPixelFormats(WineD3D_GL_Info *gl_info); +BOOL initPixelFormatsNoGL(WineD3D_GL_Info *gl_info); extern long WineD3DAdapterChangeGLRam(IWineD3DDeviceImpl *D3DDevice, long glram); -extern void add_gl_compat_wrappers(struct wined3d_gl_info *gl_info); +extern void add_gl_compat_wrappers(WineD3D_GL_Info *gl_info); /***************************************************************************** * High order patch management @@ -1433,9 +1377,8 @@ struct texture_stage_op struct ffp_frag_settings { struct texture_stage_op op[MAX_TEXTURES]; enum fogmode fog; - /* Use shorts instead of chars to get dword alignment */ - unsigned short sRGB_write; - unsigned short emul_clipplanes; + /* Use an int instead of a char to get dword alignment */ + unsigned int sRGB_write; }; struct ffp_frag_desc @@ -1568,6 +1511,10 @@ struct IWineD3DDeviceImpl IWineD3DSurface *auto_depth_stencil_buffer; IWineD3DSurface *stencilBufferTarget; + /* Caches to avoid unneeded context changes */ + IWineD3DSurface *lastActiveRenderTarget; + IWineD3DSwapChain *lastActiveSwapChain; + /* palettes texture management */ UINT NumberOfPalettes; PALETTEENTRY **palettes; @@ -1616,6 +1563,8 @@ struct IWineD3DDeviceImpl /* Context management */ WineD3DContext **contexts; /* Dynamic array containing pointers to context structures */ + WineD3DContext *activeContext; + DWORD lastThread; UINT numContexts; WineD3DContext *pbufferContext; /* The context that has a pbuffer as drawable */ DWORD pbufferWidth, pbufferHeight; /* Size of the buffer drawable */ @@ -1956,23 +1905,21 @@ struct IWineD3DSurfaceImpl UINT pow2Height; /* A method to retrieve the drawable size. Not in the Vtable to make it changeable */ - void (*get_drawable_size)(struct WineD3DContext *context, UINT *width, UINT *height); + void (*get_drawable_size)(IWineD3DSurfaceImpl *This, UINT *width, UINT *height); /* Oversized texture */ RECT glRect; /* PBO */ GLuint pbo; - GLuint texture_name; - GLuint texture_name_srgb; - GLint texture_level; - GLenum texture_target; RECT lockedRect; RECT dirtyRect; int lockCount; #define MAXLOCKCOUNT 50 /* After this amount of locks do not free the sysmem copy */ + glDescriptor glDescription; + /* For GetDC */ wineD3DSurface_DIB dib; HDC hDC; @@ -2050,10 +1997,10 @@ HRESULT WINAPI IWineD3DBaseSurfaceImpl_LockRect(IWineD3DSurface *iface, WINED3DL void WINAPI IWineD3DBaseSurfaceImpl_BindTexture(IWineD3DSurface *iface, BOOL srgb); const void *WINAPI IWineD3DBaseSurfaceImpl_GetData(IWineD3DSurface *iface); -void get_drawable_size_swapchain(struct WineD3DContext *context, UINT *width, UINT *height); -void get_drawable_size_backbuffer(struct WineD3DContext *context, UINT *width, UINT *height); -void get_drawable_size_pbuffer(struct WineD3DContext *context, UINT *width, UINT *height); -void get_drawable_size_fbo(struct WineD3DContext *context, UINT *width, UINT *height); +void get_drawable_size_swapchain(IWineD3DSurfaceImpl *This, UINT *width, UINT *height); +void get_drawable_size_backbuffer(IWineD3DSurfaceImpl *This, UINT *width, UINT *height); +void get_drawable_size_pbuffer(IWineD3DSurfaceImpl *This, UINT *width, UINT *height); +void get_drawable_size_fbo(IWineD3DSurfaceImpl *This, UINT *width, UINT *height); void flip_surface(IWineD3DSurfaceImpl *front, IWineD3DSurfaceImpl *back); @@ -2377,6 +2324,17 @@ extern const IWineD3DQueryVtbl IWineD3DQuery_Vtbl; extern const IWineD3DQueryVtbl IWineD3DEventQuery_Vtbl; extern const IWineD3DQueryVtbl IWineD3DOcclusionQuery_Vtbl; +/* Datastructures for IWineD3DQueryImpl.extendedData */ +typedef struct WineQueryOcclusionData { + GLuint queryId; + WineD3DContext *ctx; +} WineQueryOcclusionData; + +typedef struct WineQueryEventData { + GLuint fenceId; + WineD3DContext *ctx; +} WineQueryEventData; + /* IWineD3DBuffer */ /* TODO: Add tests and support for FLOAT16_4 POSITIONT, D3DCOLOR position, other @@ -2425,7 +2383,7 @@ struct wined3d_buffer extern const IWineD3DBufferVtbl wined3d_buffer_vtbl; const BYTE *buffer_get_memory(IWineD3DBuffer *iface, UINT offset, GLuint *buffer_object); -BYTE *buffer_get_sysmem(struct wined3d_buffer *This); +const BYTE *buffer_get_sysmem(struct wined3d_buffer *This); /* IWineD3DRendertargetView */ struct wined3d_rendertarget_view @@ -2532,7 +2490,7 @@ void state_fog_fragpart(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3D void surface_add_dirty_rect(IWineD3DSurface *iface, const RECT *dirty_rect); GLenum surface_get_gl_buffer(IWineD3DSurface *iface, IWineD3DSwapChain *swapchain); -void surface_load_ds_location(IWineD3DSurface *iface, struct WineD3DContext *context, DWORD location); +void surface_load_ds_location(IWineD3DSurface *iface, DWORD location); void surface_modify_ds_location(IWineD3DSurface *iface, DWORD location); void surface_set_compatible_renderbuffer(IWineD3DSurface *iface, unsigned int width, unsigned int height); void surface_set_texture_name(IWineD3DSurface *iface, GLuint name, BOOL srgb_name); @@ -2580,9 +2538,12 @@ typedef struct SHADER_PARSE_STATE { #define PRINTF_ATTR(fmt,args) #endif -/* Base Shader utility functions. */ -int shader_addline(struct wined3d_shader_buffer *buffer, const char *fmt, ...) PRINTF_ATTR(2,3); -int shader_vaddline(struct wined3d_shader_buffer *buffer, const char *fmt, va_list args); +/* Base Shader utility functions. + * (may move callers into the same file in the future) */ +extern int shader_addline( + SHADER_BUFFER* buffer, + const char* fmt, ...) PRINTF_ATTR(2,3); +int shader_vaddline(SHADER_BUFFER *buffer, const char *fmt, va_list args); /* Vertex shader utility functions */ extern BOOL vshader_get_input( @@ -2630,15 +2591,14 @@ typedef struct IWineD3DBaseShaderImpl { IWineD3DBaseShaderClass baseShader; } IWineD3DBaseShaderImpl; -void shader_buffer_clear(struct wined3d_shader_buffer *buffer); -BOOL shader_buffer_init(struct wined3d_shader_buffer *buffer); -void shader_buffer_free(struct wined3d_shader_buffer *buffer); +void shader_buffer_init(struct SHADER_BUFFER *buffer); +void shader_buffer_free(struct SHADER_BUFFER *buffer); void shader_cleanup(IWineD3DBaseShader *iface); void shader_dump_src_param(const struct wined3d_shader_src_param *param, const struct wined3d_shader_version *shader_version); void shader_dump_dst_param(const struct wined3d_shader_dst_param *param, const struct wined3d_shader_version *shader_version); -void shader_generate_main(IWineD3DBaseShader *iface, struct wined3d_shader_buffer *buffer, +void shader_generate_main(IWineD3DBaseShader *iface, SHADER_BUFFER *buffer, const shader_reg_maps *reg_maps, const DWORD *pFunction, void *backend_ctx); HRESULT shader_get_registers_used(IWineD3DBaseShader *iface, const struct wined3d_shader_frontend *fe, struct shader_reg_maps *reg_maps, struct wined3d_shader_attribute *attributes, @@ -2745,24 +2705,6 @@ void find_vs_compile_args(IWineD3DVertexShaderImpl *shader, IWineD3DStateBlockIm /***************************************************************************** * IDirect3DPixelShader implementation structure */ - -/* Using additional shader constants (uniforms in GLSL / program environment - * or local parameters in ARB) is costly: - * ARB only knows float4 parameters and GLSL compiler are not really smart - * when it comes to efficiently pack float2 uniforms, so no space is wasted - * (in fact most compilers map a float2 to a full float4 uniform). - * - * For NP2 texcoord fixup we only need 2 floats (width and height) for each - * 2D texture used in the shader. We therefore pack fixup info for 2 textures - * into a single shader constant (uniform / program parameter). - * - * This structure is shared between the GLSL and the ARB backend.*/ -struct ps_np2fixup_info { - unsigned char idx[MAX_FRAGMENT_SAMPLERS]; /* indices to the real constant */ - WORD active; /* bitfield indicating if we can apply the fixup */ - WORD num_consts; -}; - typedef struct IWineD3DPixelShaderImpl { /* IUnknown parts */ const IWineD3DPixelShaderVtbl *lpVtbl; @@ -2777,7 +2719,7 @@ typedef struct IWineD3DPixelShaderImpl { struct wined3d_shader_signature_element input_signature[MAX_REG_INPUT]; DWORD input_reg_map[MAX_REG_INPUT]; BOOL input_reg_used[MAX_REG_INPUT]; - unsigned int declared_in_count; + int declared_in_count; /* The GL shader */ void *backend_priv; @@ -2795,11 +2737,11 @@ void pixelshader_update_samplers(struct shader_reg_maps *reg_maps, IWineD3DBaseT void find_ps_compile_args(IWineD3DPixelShaderImpl *shader, IWineD3DStateBlockImpl *stateblock, struct ps_compile_args *args); /* sRGB correction constants */ -static const float srgb_cmp = 0.0031308f; -static const float srgb_mul_low = 12.92f; -static const float srgb_pow = 0.41666f; -static const float srgb_mul_high = 1.055f; -static const float srgb_sub_high = 0.055f; +static const float srgb_cmp = 0.0031308; +static const float srgb_mul_low = 12.92; +static const float srgb_pow = 0.41666; +static const float srgb_mul_high = 1.055; +static const float srgb_sub_high = 0.055; /***************************************************************************** * IWineD3DPalette implementation structure @@ -2874,7 +2816,7 @@ struct GlPixelFormatDesc struct color_fixup_desc color_fixup; }; -const struct GlPixelFormatDesc *getFormatDescEntry(WINED3DFORMAT fmt, const struct wined3d_gl_info *gl_info); +const struct GlPixelFormatDesc *getFormatDescEntry(WINED3DFORMAT fmt, const WineD3D_GL_Info *gl_info); static inline BOOL use_vs(IWineD3DStateBlockImpl *stateblock) { diff --git a/dlls/winedos/int21.c b/dlls/winedos/int21.c index 6fd131f9442..16b23598ad8 100644 --- a/dlls/winedos/int21.c +++ b/dlls/winedos/int21.c @@ -3419,7 +3419,7 @@ static BOOL INT21_NetworkFunc (CONTEXT86 *context) static int INT21_GetDiskSerialNumber( CONTEXT86 *context ) { BYTE *dataptr = CTX_SEG_OFF_TO_LIN(context, context->SegDs, context->Edx); - WCHAR path[] = {'A',':','\\',0}, label[11]; + WCHAR path[] = {'A',':',0}, label[11]; DWORD serial; path[0] += INT21_MapDrive(BL_reg(context)); @@ -3877,7 +3877,7 @@ static unsigned INT21_FindHelper(LPCWSTR fullPath, unsigned drive, unsigned coun if ((search_attr & ~(FA_UNUSED | FA_ARCHIVE | FA_RDONLY)) == FA_LABEL) { - WCHAR path[] = {' ',':','\\',0}; + WCHAR path[] = {' ',':',0}; if (count) return 0; path[0] = drive + 'A'; diff --git a/dlls/winedos/int31.c b/dlls/winedos/int31.c index 0c5bdc7b2b8..905d7e6bf5e 100644 --- a/dlls/winedos/int31.c +++ b/dlls/winedos/int31.c @@ -312,14 +312,9 @@ void DPMI_CallRMCB32(RMCB *rmcb, UINT16 ss, DWORD esp, UINT16*es, DWORD*edi) ; __ASM_GLOBAL_FUNC(DPMI_CallRMCB32, "pushl %ebp\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %ebp,0\n\t") "movl %esp,%ebp\n\t" - __ASM_CFI(".cfi_def_cfa_register %ebp\n\t") "pushl %edi\n\t" - __ASM_CFI(".cfi_rel_offset %edi,-4\n\t") "pushl %esi\n\t" - __ASM_CFI(".cfi_rel_offset %esi,-8\n\t") "movl 0x8(%ebp),%eax\n\t" "movl 0x10(%ebp),%esi\n\t" "movl 0xc(%ebp),%edx\n\t" @@ -344,12 +339,8 @@ __ASM_GLOBAL_FUNC(DPMI_CallRMCB32, "movl 0x18(%ebp),%edx\n\t" "movl %edi,(%edx)\n\t" "popl %esi\n\t" - __ASM_CFI(".cfi_same_value %esi\n\t") "popl %edi\n\t" - __ASM_CFI(".cfi_same_value %edi\n\t") "leave\n\t" - __ASM_CFI(".cfi_def_cfa %esp,4\n\t") - __ASM_CFI(".cfi_same_value %ebp\n\t") "ret") #endif diff --git a/dlls/wineesd.drv/Makefile.in b/dlls/wineesd.drv/Makefile.in index e42d04c2844..b34e374dcf0 100644 --- a/dlls/wineesd.drv/Makefile.in +++ b/dlls/wineesd.drv/Makefile.in @@ -8,8 +8,8 @@ EXTRAINCL = @ESDINCL@ EXTRALIBS = @ESDLIBS@ C_SRCS = \ - audio.c \ - esound.c + esound.c \ + audio.c @MAKE_DLL_RULES@ diff --git a/dlls/wineps.drv/Makefile.in b/dlls/wineps.drv/Makefile.in index 5d96ce43032..940ca270f8f 100644 --- a/dlls/wineps.drv/Makefile.in +++ b/dlls/wineps.drv/Makefile.in @@ -69,30 +69,7 @@ C_SRCS = \ type1afm.c \ type42.c -RC_SRCS= \ - wps_Bg.rc \ - wps_Cs.rc \ - wps_Da.rc \ - wps_De.rc \ - wps_En.rc \ - wps_Es.rc \ - wps_Fr.rc \ - wps_Hu.rc \ - wps_It.rc \ - wps_Ja.rc \ - wps_Ko.rc \ - wps_Lt.rc \ - wps_Nl.rc \ - wps_No.rc \ - wps_Pl.rc \ - wps_Pt.rc \ - wps_Ro.rc \ - wps_Ru.rc \ - wps_Si.rc \ - wps_Sk.rc \ - wps_Sv.rc \ - wps_Tr.rc \ - wps_Zh.rc +RC_SRCS= rsrc.rc EXTRASUBDIRS = data diff --git a/dlls/wineps.drv/driver.c b/dlls/wineps.drv/driver.c index 904f97a1809..158ea1f35e5 100644 --- a/dlls/wineps.drv/driver.c +++ b/dlls/wineps.drv/driver.c @@ -30,12 +30,12 @@ #include #include "wine/debug.h" +#include "psdlg.h" #include "psdrv.h" #include "winuser.h" #include "wownt32.h" #include "prsht.h" -#include "psdlg.h" WINE_DEFAULT_DEBUG_CHANNEL(psdrv); diff --git a/dlls/wineps.drv/psdlg.h b/dlls/wineps.drv/psdlg.h index 24e429154f9..f16c683907f 100644 --- a/dlls/wineps.drv/psdlg.h +++ b/dlls/wineps.drv/psdlg.h @@ -21,9 +21,6 @@ #ifndef __WINE_PSDLG_H #define __WINE_PSDLG_H -#include -#include - #define IDD_PAPERS 100 #define IDD_ORIENT_PORTRAIT 101 #define IDD_ORIENT_LANDSCAPE 102 diff --git a/dlls/wineps.drv/rsrc.rc b/dlls/wineps.drv/rsrc.rc new file mode 100644 index 00000000000..2529bf0fb01 --- /dev/null +++ b/dlls/wineps.drv/rsrc.rc @@ -0,0 +1,57 @@ +/* + * Top level resource file for wineps + * + * Copyright 2000 Huw D M Davies + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winnls.h" +#include "psdlg.h" + + +/* + * Everything specific to any language goes + * in one of the specific files. + * Note that you can and may override resources + * which also have a neutral version. This is to + * get localized bitmaps for example. + */ +#include "wps_Bg.rc" +#include "wps_Cs.rc" +#include "wps_Da.rc" +#include "wps_De.rc" +#include "wps_En.rc" +#include "wps_Es.rc" +#include "wps_Fr.rc" +#include "wps_Hu.rc" +#include "wps_It.rc" +#include "wps_Ja.rc" +#include "wps_Ko.rc" +#include "wps_Lt.rc" +#include "wps_Nl.rc" +#include "wps_No.rc" +#include "wps_Pt.rc" +#include "wps_Pl.rc" +#include "wps_Ro.rc" +#include "wps_Ru.rc" +#include "wps_Si.rc" +#include "wps_Sk.rc" +#include "wps_Sv.rc" +#include "wps_Tr.rc" +#include "wps_Zh.rc" diff --git a/dlls/wineps.drv/truetype.c b/dlls/wineps.drv/truetype.c index 59ebe19d6bd..b5269590da1 100644 --- a/dlls/wineps.drv/truetype.c +++ b/dlls/wineps.drv/truetype.c @@ -49,6 +49,10 @@ #endif #ifdef HAVE_FREETYPE_FTSNAMES_H #include +#else +# ifdef HAVE_FREETYPE_FTNAMES_H +# include +# endif #endif #ifdef HAVE_FREETYPE_TTNAMEID_H #include diff --git a/dlls/wineps.drv/wps_Bg.rc b/dlls/wineps.drv/wps_Bg.rc index fb256f80d72..423d148ffc5 100644 --- a/dlls/wineps.drv/wps_Bg.rc +++ b/dlls/wineps.drv/wps_Bg.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_Cs.rc b/dlls/wineps.drv/wps_Cs.rc index 9378ebc8d8f..f8806c9c6d9 100644 --- a/dlls/wineps.drv/wps_Cs.rc +++ b/dlls/wineps.drv/wps_Cs.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/dlls/wineps.drv/wps_Da.rc b/dlls/wineps.drv/wps_Da.rc index a2c11b3bc28..1fa6a585fe3 100644 --- a/dlls/wineps.drv/wps_Da.rc +++ b/dlls/wineps.drv/wps_Da.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_De.rc b/dlls/wineps.drv/wps_De.rc index 7ff88ec5f4c..6d0df403c27 100644 --- a/dlls/wineps.drv/wps_De.rc +++ b/dlls/wineps.drv/wps_De.rc @@ -16,10 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 @@ -27,7 +23,7 @@ STYLE WS_POPUP | WS_CAPTION | WS_CLIPSIBLINGS | WS_VISIBLE CAPTION "Papier" FONT 8, "MS Shell Dlg" { - LTEXT "&Papiergröße:", -1, 10, 6, 100, 8 + LTEXT "&Papiergröße:", -1, 10, 6, 100, 8 LISTBOX IDD_PAPERS, 10, 15, 200, 45, LBS_STANDARD | LBS_HASSTRINGS | WS_TABSTOP GROUPBOX "Ausrichtung", -1, 10, 80, 200, 50 diff --git a/dlls/wineps.drv/wps_En.rc b/dlls/wineps.drv/wps_En.rc index be31f8721cd..d29a582c9c6 100644 --- a/dlls/wineps.drv/wps_En.rc +++ b/dlls/wineps.drv/wps_En.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_Es.rc b/dlls/wineps.drv/wps_Es.rc index c363f735bc3..6f488f52cf1 100644 --- a/dlls/wineps.drv/wps_Es.rc +++ b/dlls/wineps.drv/wps_Es.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_Fr.rc b/dlls/wineps.drv/wps_Fr.rc index c48f568ff0f..6bdadb7dea3 100644 --- a/dlls/wineps.drv/wps_Fr.rc +++ b/dlls/wineps.drv/wps_Fr.rc @@ -19,11 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 @@ -32,14 +27,14 @@ CAPTION "Papier" FONT 8, "MS Shell Dlg" { LTEXT "&Taille du papier :", -1, 10, 6, 100, 8 - LISTBOX IDD_PAPERS, 10, 17, 200, 45, LBS_STANDARD | LBS_HASSTRINGS | + LISTBOX IDD_PAPERS, 10, 15, 200, 45, LBS_STANDARD | LBS_HASSTRINGS | WS_TABSTOP GROUPBOX "Orientation", -1, 10, 80, 200, 50 CONTROL "&Portrait", IDD_ORIENT_PORTRAIT, "Button", BS_AUTORADIOBUTTON | - WS_TABSTOP, 20, 93, 60, 10 + WS_TABSTOP, 20, 90, 60, 10 CONTROL "P&aysage", IDD_ORIENT_LANDSCAPE, "Button", BS_AUTORADIOBUTTON, 20, 110, 60, 10 - LTEXT "Recto-verso :", IDD_DUPLEX_NAME, 10, 140, 100, 8 + LTEXT "Recto-verso:", IDD_DUPLEX_NAME, 10, 140, 100, 8 COMBOBOX IDD_DUPLEX, 10, 151, 200, 20, CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_TABSTOP } diff --git a/dlls/wineps.drv/wps_Hu.rc b/dlls/wineps.drv/wps_Hu.rc index b5d17c9b0e7..2b74b42800b 100644 --- a/dlls/wineps.drv/wps_Hu.rc +++ b/dlls/wineps.drv/wps_Hu.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_It.rc b/dlls/wineps.drv/wps_It.rc index 120919b803b..7cb3ea2a98a 100644 --- a/dlls/wineps.drv/wps_It.rc +++ b/dlls/wineps.drv/wps_It.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_Ja.rc b/dlls/wineps.drv/wps_Ja.rc index be2e8ec0bab..4e15f27fc2d 100644 --- a/dlls/wineps.drv/wps_Ja.rc +++ b/dlls/wineps.drv/wps_Ja.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - /* UTF-8 */ #pragma code_page(65001) @@ -40,3 +38,5 @@ FONT 9, "MS Shell Dlg" COMBOBOX IDD_DUPLEX, 10, 151, 200, 20, CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_TABSTOP } + +#pragma code_page(default) diff --git a/dlls/wineps.drv/wps_Ko.rc b/dlls/wineps.drv/wps_Ko.rc index 8e0c9a36cf7..f84add20c1c 100644 --- a/dlls/wineps.drv/wps_Ko.rc +++ b/dlls/wineps.drv/wps_Ko.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_Lt.rc b/dlls/wineps.drv/wps_Lt.rc index d77e7f1ec16..5476cb10752 100644 --- a/dlls/wineps.drv/wps_Lt.rc +++ b/dlls/wineps.drv/wps_Lt.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - /* UTF-8 */ #pragma code_page(65001) @@ -40,3 +38,4 @@ FONT 8, "MS Shell Dlg" COMBOBOX IDD_DUPLEX, 10, 151, 200, 20, CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_TABSTOP } +#pragma code_page(default) diff --git a/dlls/wineps.drv/wps_Nl.rc b/dlls/wineps.drv/wps_Nl.rc index e5b1f9c7674..4254e820d40 100644 --- a/dlls/wineps.drv/wps_Nl.rc +++ b/dlls/wineps.drv/wps_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_No.rc b/dlls/wineps.drv/wps_No.rc index eaa7eac7e1f..e9a5904ccb9 100644 --- a/dlls/wineps.drv/wps_No.rc +++ b/dlls/wineps.drv/wps_No.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_Pl.rc b/dlls/wineps.drv/wps_Pl.rc index dcc226ce4b1..a64e25ca937 100644 --- a/dlls/wineps.drv/wps_Pl.rc +++ b/dlls/wineps.drv/wps_Pl.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_POLISH, SUBLANG_NEUTRAL PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_Pt.rc b/dlls/wineps.drv/wps_Pt.rc index 03cae1909c8..062ed05343b 100644 --- a/dlls/wineps.drv/wps_Pt.rc +++ b/dlls/wineps.drv/wps_Pt.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_Ro.rc b/dlls/wineps.drv/wps_Ro.rc index 73064a49858..a9f7d1e26a0 100644 --- a/dlls/wineps.drv/wps_Ro.rc +++ b/dlls/wineps.drv/wps_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -40,3 +38,5 @@ FONT 8, "MS Shell Dlg" COMBOBOX IDD_DUPLEX, 10, 151, 200, 20, CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_TABSTOP } + +#pragma code_page(default) diff --git a/dlls/wineps.drv/wps_Ru.rc b/dlls/wineps.drv/wps_Ru.rc index 5250407d601..d009c44c98b 100644 --- a/dlls/wineps.drv/wps_Ru.rc +++ b/dlls/wineps.drv/wps_Ru.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - /* Russian strings in cp1251 */ LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT diff --git a/dlls/wineps.drv/wps_Si.rc b/dlls/wineps.drv/wps_Si.rc index c06145568a1..e1b1a9a4c18 100644 --- a/dlls/wineps.drv/wps_Si.rc +++ b/dlls/wineps.drv/wps_Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_Sk.rc b/dlls/wineps.drv/wps_Sk.rc index baac24dd58d..541f37321ad 100644 --- a/dlls/wineps.drv/wps_Sk.rc +++ b/dlls/wineps.drv/wps_Sk.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_SLOVAK, SUBLANG_DEFAULT PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_Sv.rc b/dlls/wineps.drv/wps_Sv.rc index af58d278a5a..7aa23085f51 100644 --- a/dlls/wineps.drv/wps_Sv.rc +++ b/dlls/wineps.drv/wps_Sv.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_Tr.rc b/dlls/wineps.drv/wps_Tr.rc index ec9098886a8..c13bc08ec5f 100644 --- a/dlls/wineps.drv/wps_Tr.rc +++ b/dlls/wineps.drv/wps_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT PAPER DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 diff --git a/dlls/wineps.drv/wps_Zh.rc b/dlls/wineps.drv/wps_Zh.rc index 0bb9ab45319..50fc5e67e9f 100644 --- a/dlls/wineps.drv/wps_Zh.rc +++ b/dlls/wineps.drv/wps_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "psdlg.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -62,3 +60,5 @@ FONT 9, "MS Shell Dlg" COMBOBOX IDD_DUPLEX, 10, 151, 200, 20, CBS_DROPDOWNLIST | CBS_HASSTRINGS | WS_TABSTOP } + +#pragma code_page(default) diff --git a/dlls/winex11.drv/bitblt.c b/dlls/winex11.drv/bitblt.c index 119ac5bd13c..259c1bb01f5 100644 --- a/dlls/winex11.drv/bitblt.c +++ b/dlls/winex11.drv/bitblt.c @@ -1436,20 +1436,14 @@ static BOOL BITBLT_InternalStretchBlt( X11DRV_PDEVICE *physDevDst, INT xDst, INT pixmaps[SRC] = XCreatePixmap( gdi_display, root_window, width, height, physDevDst->depth ); wine_tsx11_unlock(); - - if(!X11DRV_XRender_GetSrcAreaStretch( physDevSrc, physDevDst, pixmaps[SRC], tmpGC, - widthSrc, heightSrc, widthDst, heightDst, - &visRectSrc, &visRectDst)) - { - if (fStretch) - BITBLT_GetSrcAreaStretch( physDevSrc, physDevDst, pixmaps[SRC], tmpGC, - xSrc, ySrc, widthSrc, heightSrc, - xDst, yDst, widthDst, heightDst, - &visRectSrc, &visRectDst ); - else - BITBLT_GetSrcArea( physDevSrc, physDevDst, pixmaps[SRC], tmpGC, - &visRectSrc ); - } + if (fStretch) + BITBLT_GetSrcAreaStretch( physDevSrc, physDevDst, pixmaps[SRC], tmpGC, + xSrc, ySrc, widthSrc, heightSrc, + xDst, yDst, widthDst, heightDst, + &visRectSrc, &visRectDst ); + else + BITBLT_GetSrcArea( physDevSrc, physDevDst, pixmaps[SRC], tmpGC, + &visRectSrc ); } if (useDst) BITBLT_GetDstArea( physDevDst, pixmaps[DST], tmpGC, &visRectDst ); diff --git a/dlls/winex11.drv/bitmap.c b/dlls/winex11.drv/bitmap.c index a28835213de..facf405b97d 100644 --- a/dlls/winex11.drv/bitmap.c +++ b/dlls/winex11.drv/bitmap.c @@ -31,56 +31,38 @@ WINE_DEFAULT_DEBUG_CHANNEL(x11drv); /* GCs used for B&W and color bitmap operations */ -static GC bitmap_gc[32]; +GC BITMAP_monoGC = 0, BITMAP_colorGC = 0; X_PHYSBITMAP BITMAP_stock_phys_bitmap = { 0 }; /* phys bitmap for the default stock bitmap */ static XContext bitmap_context; /* X context to associate a phys bitmap to a handle */ -GC get_bitmap_gc(int depth) -{ - if(depth < 1 || depth > 32) - return 0; - - return bitmap_gc[depth-1]; -} - /*********************************************************************** * X11DRV_BITMAP_Init */ void X11DRV_BITMAP_Init(void) { - int depth_count, index, i; - int *depth_list; Pixmap tmpPixmap; + /* Create the necessary GCs */ + wine_tsx11_lock(); bitmap_context = XUniqueContext(); BITMAP_stock_phys_bitmap.pixmap_depth = 1; BITMAP_stock_phys_bitmap.pixmap = XCreatePixmap( gdi_display, root_window, 1, 1, 1 ); - bitmap_gc[0] = XCreateGC( gdi_display, BITMAP_stock_phys_bitmap.pixmap, 0, NULL ); - XSetGraphicsExposures( gdi_display, bitmap_gc[0], False ); - XSetSubwindowMode( gdi_display, bitmap_gc[0], IncludeInferiors ); - - /* Create a GC for all available depths. GCs at depths other than 1-bit/screen_depth are for use - * in combination with XRender which allows us to create dibsections at more depths. - */ - depth_list = XListDepths(gdi_display, DefaultScreen(gdi_display), &depth_count); - for (i = 0; i < depth_count; i++) + BITMAP_monoGC = XCreateGC( gdi_display, BITMAP_stock_phys_bitmap.pixmap, 0, NULL ); + XSetGraphicsExposures( gdi_display, BITMAP_monoGC, False ); + XSetSubwindowMode( gdi_display, BITMAP_monoGC, IncludeInferiors ); + + if (screen_depth != 1) { - index = depth_list[i] - 1; - if (bitmap_gc[index]) continue; - if ((tmpPixmap = XCreatePixmap( gdi_display, root_window, 1, 1, depth_list[i]))) + if ((tmpPixmap = XCreatePixmap( gdi_display, root_window, 1, 1, screen_depth ))) { - if ((bitmap_gc[index] = XCreateGC( gdi_display, tmpPixmap, 0, NULL ))) - { - XSetGraphicsExposures( gdi_display, bitmap_gc[index], False ); - XSetSubwindowMode( gdi_display, bitmap_gc[index], IncludeInferiors ); - } + BITMAP_colorGC = XCreateGC( gdi_display, tmpPixmap, 0, NULL ); + XSetGraphicsExposures( gdi_display, BITMAP_colorGC, False ); + XSetSubwindowMode( gdi_display, BITMAP_colorGC, IncludeInferiors ); XFreePixmap( gdi_display, tmpPixmap ); } } - XFree( depth_list ); - wine_tsx11_unlock(); } @@ -175,12 +157,11 @@ BOOL CDECL X11DRV_CreateBitmap( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, LPVOID } else /* else clear the bitmap */ { - GC gc = get_bitmap_gc(physBitmap->pixmap_depth); wine_tsx11_lock(); - XSetFunction( gdi_display, gc, GXclear ); - XFillRectangle( gdi_display, physBitmap->pixmap, gc, 0, 0, + XSetFunction( gdi_display, BITMAP_GC(physBitmap), GXclear ); + XFillRectangle( gdi_display, physBitmap->pixmap, BITMAP_GC(physBitmap), 0, 0, bitmap.bmWidth, bitmap.bmHeight ); - XSetFunction( gdi_display, gc, GXcopy ); + XSetFunction( gdi_display, BITMAP_GC(physBitmap), GXcopy ); wine_tsx11_unlock(); } return TRUE; @@ -424,7 +405,7 @@ LONG CDECL X11DRV_SetBitmapBits( HBITMAP hbitmap, const void *bits, LONG count ) FIXME("Unhandled bits:%d\n", bitmap.bmBitsPixel); } - XPutImage( gdi_display, physBitmap->pixmap, get_bitmap_gc(physBitmap->pixmap_depth), + XPutImage( gdi_display, physBitmap->pixmap, BITMAP_GC(physBitmap), image, 0, 0, 0, 0, bitmap.bmWidth, height ); HeapFree( GetProcessHeap(), 0, image->data ); image->data = NULL; diff --git a/dlls/winex11.drv/brush.c b/dlls/winex11.drv/brush.c index c94e04eabc8..612968c1636 100644 --- a/dlls/winex11.drv/brush.c +++ b/dlls/winex11.drv/brush.c @@ -103,18 +103,17 @@ static const COLORREF WHITE = RGB(0xff, 0xff, 0xff); /*********************************************************************** * BRUSH_DitherColor */ -static Pixmap BRUSH_DitherColor( COLORREF color, int depth) +static Pixmap BRUSH_DitherColor( COLORREF color ) { /* X image for building dithered pixmap */ static XImage *ditherImage = NULL; static COLORREF prevColor = 0xffffffff; unsigned int x, y; Pixmap pixmap; - GC gc = get_bitmap_gc(depth); if (!ditherImage) { - ditherImage = X11DRV_DIB_CreateXImage( MATRIX_SIZE, MATRIX_SIZE, depth ); + ditherImage = X11DRV_DIB_CreateXImage( MATRIX_SIZE, MATRIX_SIZE, screen_depth ); if (!ditherImage) { ERR("Could not create dither image\n"); @@ -144,8 +143,8 @@ static Pixmap BRUSH_DitherColor( COLORREF color, int depth) prevColor = color; } - pixmap = XCreatePixmap( gdi_display, root_window, MATRIX_SIZE, MATRIX_SIZE, depth ); - XPutImage( gdi_display, pixmap, gc, ditherImage, 0, 0, + pixmap = XCreatePixmap( gdi_display, root_window, MATRIX_SIZE, MATRIX_SIZE, screen_depth ); + XPutImage( gdi_display, pixmap, BITMAP_colorGC, ditherImage, 0, 0, 0, 0, MATRIX_SIZE, MATRIX_SIZE ); wine_tsx11_unlock(); @@ -186,7 +185,7 @@ static void BRUSH_SelectSolidBrush( X11DRV_PDEVICE *physDev, COLORREF color ) if ((physDev->depth > 1) && (screen_depth <= 8) && !X11DRV_IsSolidColor( color )) { /* Dithered brush */ - physDev->brush.pixmap = BRUSH_DitherColor( color, physDev->depth ); + physDev->brush.pixmap = BRUSH_DitherColor( color ); physDev->brush.fillStyle = FillTiled; physDev->brush.pixel = 0; } @@ -223,7 +222,7 @@ static BOOL BRUSH_SelectPatternBrush( X11DRV_PDEVICE *physDev, HBITMAP hbitmap ) bitmap.bmWidth, bitmap.bmHeight, 1); /* FIXME: should probably convert to monochrome instead */ XCopyPlane( gdi_display, physBitmap->pixmap, physDev->brush.pixmap, - get_bitmap_gc(1), 0, 0, bitmap.bmWidth, bitmap.bmHeight, 0, 0, 1 ); + BITMAP_monoGC, 0, 0, bitmap.bmWidth, bitmap.bmHeight, 0, 0, 1 ); } else { @@ -231,7 +230,7 @@ static BOOL BRUSH_SelectPatternBrush( X11DRV_PDEVICE *physDev, HBITMAP hbitmap ) bitmap.bmWidth, bitmap.bmHeight, physBitmap->pixmap_depth ); XCopyArea( gdi_display, physBitmap->pixmap, physDev->brush.pixmap, - get_bitmap_gc(physBitmap->pixmap_depth), 0, 0, bitmap.bmWidth, bitmap.bmHeight, 0, 0 ); + BITMAP_GC(physBitmap), 0, 0, bitmap.bmWidth, bitmap.bmHeight, 0, 0 ); } wine_tsx11_unlock(); diff --git a/dlls/winex11.drv/clipboard.c b/dlls/winex11.drv/clipboard.c index 82928a228aa..b634451b443 100644 --- a/dlls/winex11.drv/clipboard.c +++ b/dlls/winex11.drv/clipboard.c @@ -293,8 +293,6 @@ static WINE_CLIPFORMAT ClipFormats[] = /* Maps X properties to Windows formats */ static const WCHAR wszRichTextFormat[] = {'R','i','c','h',' ','T','e','x','t',' ','F','o','r','m','a','t',0}; static const WCHAR wszGIF[] = {'G','I','F',0}; -static const WCHAR wszJFIF[] = {'J','F','I','F',0}; -static const WCHAR wszPNG[] = {'P','N','G',0}; static const WCHAR wszHTMLFormat[] = {'H','T','M','L',' ','F','o','r','m','a','t',0}; static const struct { @@ -305,8 +303,6 @@ static const struct { wszRichTextFormat, XATOM_text_rtf }, { wszRichTextFormat, XATOM_text_richtext }, { wszGIF, XATOM_image_gif }, - { wszJFIF, XATOM_image_jpeg }, - { wszPNG, XATOM_image_png }, { wszHTMLFormat, XATOM_text_html }, }; @@ -2504,52 +2500,6 @@ INT CDECL X11DRV_GetClipboardFormatName(UINT wFormat, LPWSTR retStr, INT maxlen) return strlenW(retStr); } -static void selection_acquire(void) -{ - Window owner; - Display *display; - - owner = thread_selection_wnd(); - display = thread_display(); - - wine_tsx11_lock(); - - selectionAcquired = 0; - selectionWindow = 0; - - /* Grab PRIMARY selection if not owned */ - if (use_primary_selection) - XSetSelectionOwner(display, XA_PRIMARY, owner, CurrentTime); - - /* Grab CLIPBOARD selection if not owned */ - XSetSelectionOwner(display, x11drv_atom(CLIPBOARD), owner, CurrentTime); - - if (use_primary_selection && XGetSelectionOwner(display, XA_PRIMARY) == owner) - selectionAcquired |= S_PRIMARY; - - if (XGetSelectionOwner(display,x11drv_atom(CLIPBOARD)) == owner) - selectionAcquired |= S_CLIPBOARD; - - wine_tsx11_unlock(); - - if (selectionAcquired) - { - selectionWindow = owner; - TRACE("Grabbed X selection, owner=(%08x)\n", (unsigned) owner); - } -} - -static DWORD WINAPI selection_thread_proc(LPVOID unused) -{ - selection_acquire(); - - while (selectionAcquired) - { - MsgWaitForMultipleObjectsEx(0, NULL, INFINITE, QS_SENDMESSAGE, 0); - } - - return 0; -} /************************************************************************** * AcquireClipboard (X11DRV.@) @@ -2557,7 +2507,8 @@ static DWORD WINAPI selection_thread_proc(LPVOID unused) int CDECL X11DRV_AcquireClipboard(HWND hWndClipWindow) { DWORD procid; - HANDLE selectionThread; + Window owner; + Display *display; TRACE(" %p\n", hWndClipWindow); @@ -2585,21 +2536,33 @@ int CDECL X11DRV_AcquireClipboard(HWND hWndClipWindow) } } - if (hWndClipWindow) - { - selection_acquire(); - } - else - { - selectionThread = CreateThread(NULL, 0, &selection_thread_proc, NULL, 0, NULL); + owner = thread_selection_wnd(); + display = thread_display(); - if (!selectionThread) - { - WARN("Could not start clipboard thread\n"); - return 0; - } + wine_tsx11_lock(); - CloseHandle(selectionThread); + selectionAcquired = 0; + selectionWindow = 0; + + /* Grab PRIMARY selection if not owned */ + if (use_primary_selection) + XSetSelectionOwner(display, XA_PRIMARY, owner, CurrentTime); + + /* Grab CLIPBOARD selection if not owned */ + XSetSelectionOwner(display, x11drv_atom(CLIPBOARD), owner, CurrentTime); + + if (use_primary_selection && XGetSelectionOwner(display, XA_PRIMARY) == owner) + selectionAcquired |= S_PRIMARY; + + if (XGetSelectionOwner(display,x11drv_atom(CLIPBOARD)) == owner) + selectionAcquired |= S_CLIPBOARD; + + wine_tsx11_unlock(); + + if (selectionAcquired) + { + selectionWindow = owner; + TRACE("Grabbed X selection, owner=(%08x)\n", (unsigned) owner); } return 1; diff --git a/dlls/winex11.drv/dib.c b/dlls/winex11.drv/dib.c index 07ce9e1ebec..6df41379c17 100644 --- a/dlls/winex11.drv/dib.c +++ b/dlls/winex11.drv/dib.c @@ -3984,7 +3984,7 @@ INT CDECL X11DRV_SetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT start descr.lines = tmpheight >= 0 ? lines : -lines; descr.depth = physBitmap->pixmap_depth; descr.drawable = physBitmap->pixmap; - descr.gc = get_bitmap_gc(physBitmap->pixmap_depth); + descr.gc = BITMAP_GC(physBitmap); descr.xSrc = 0; descr.ySrc = 0; descr.xDest = 0; @@ -4138,7 +4138,7 @@ INT CDECL X11DRV_GetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT start descr.lines = lines; descr.depth = physBitmap->pixmap_depth; descr.drawable = physBitmap->pixmap; - descr.gc = get_bitmap_gc(physBitmap->pixmap_depth); + descr.gc = BITMAP_GC(physBitmap); descr.width = dib.dsBm.bmWidth; descr.height = dib.dsBm.bmHeight; descr.xDest = 0; @@ -4353,7 +4353,7 @@ static void X11DRV_DIB_DoUpdateDIBSection(X_PHYSBITMAP *physBitmap, BOOL toDIB) GetObjectW( physBitmap->hbitmap, sizeof(bitmap), &bitmap ); X11DRV_DIB_DoCopyDIBSection(physBitmap, toDIB, physBitmap->colorMap, physBitmap->nColorMap, - physBitmap->pixmap, get_bitmap_gc(physBitmap->pixmap_depth), + physBitmap->pixmap, BITMAP_GC(physBitmap), 0, 0, 0, 0, bitmap.bmWidth, bitmap.bmHeight); } diff --git a/dlls/winex11.drv/graphics.c b/dlls/winex11.drv/graphics.c index 7a64022fc4c..8d74c7788e3 100644 --- a/dlls/winex11.drv/graphics.c +++ b/dlls/winex11.drv/graphics.c @@ -233,7 +233,7 @@ BOOL X11DRV_SetupGCForPatBlt( X11DRV_PDEVICE *physDev, GC gc, BOOL fMapColors ) register int x, y; XImage *image; wine_tsx11_lock(); - pixmap = XCreatePixmap( gdi_display, root_window, 8, 8, physDev->depth ); + pixmap = XCreatePixmap( gdi_display, root_window, 8, 8, screen_depth ); image = XGetImage( gdi_display, physDev->brush.pixmap, 0, 0, 8, 8, AllPlanes, ZPixmap ); for (y = 0; y < 8; y++) @@ -1072,7 +1072,7 @@ X11DRV_GetPixel( X11DRV_PDEVICE *physDev, INT x, INT y ) /* to avoid a BadMatch error */ if (!pixmap) pixmap = XCreatePixmap( gdi_display, root_window, 1, 1, physDev->depth ); - XCopyArea( gdi_display, physDev->drawable, pixmap, get_bitmap_gc(physDev->depth), + XCopyArea( gdi_display, physDev->drawable, pixmap, BITMAP_colorGC, physDev->dc_rect.left + pt.x, physDev->dc_rect.top + pt.y, 1, 1, 0, 0 ); image = XGetImage( gdi_display, pixmap, 0, 0, 1, 1, AllPlanes, ZPixmap ); } diff --git a/dlls/winex11.drv/keyboard.c b/dlls/winex11.drv/keyboard.c index 867be232a2f..daffe366972 100644 --- a/dlls/winex11.drv/keyboard.c +++ b/dlls/winex11.drv/keyboard.c @@ -2354,7 +2354,11 @@ INT CDECL X11DRV_GetKeyNameText(LONG lParam, LPWSTR lpBuffer, INT nSize) TRACE("found scan=%04x keyc=%04x keysym=%04x string=%s\n", scanCode, keyc, (int)keys, name); if (lpBuffer && nSize && name) - return MultiByteToWideChar(CP_UNIXCP, 0, name, -1, lpBuffer, nSize); + { + MultiByteToWideChar(CP_UNIXCP, 0, name, -1, lpBuffer, nSize); + lpBuffer[nSize - 1] = 0; + return nSize; + } } /* Finally issue WARN for unknown keys */ diff --git a/dlls/winex11.drv/opengl.c b/dlls/winex11.drv/opengl.c index b2cf82a9878..f1557b65cd0 100644 --- a/dlls/winex11.drv/opengl.c +++ b/dlls/winex11.drv/opengl.c @@ -48,6 +48,9 @@ WINE_DEFAULT_DEBUG_CHANNEL(wgl); #ifdef HAVE_GL_GLX_H # include #endif +#ifdef HAVE_GL_GLEXT_H +# include +#endif #include "wine/wgl.h" diff --git a/dlls/winex11.drv/window.c b/dlls/winex11.drv/window.c index 99703484b8a..56f99cb306b 100644 --- a/dlls/winex11.drv/window.c +++ b/dlls/winex11.drv/window.c @@ -1443,6 +1443,11 @@ static Window create_whole_window( Display *display, struct x11drv_win_data *dat BYTE alpha; DWORD layered_flags; + if (!(cx = data->window_rect.right - data->window_rect.left)) cx = 1; + else if (cx > 65535) cx = 65535; + if (!(cy = data->window_rect.bottom - data->window_rect.top)) cy = 1; + else if (cy > 65535) cy = 65535; + if (!data->managed && is_window_managed( data->hwnd, SWP_NOACTIVATE, &data->window_rect )) { TRACE( "making win %p/%lx managed\n", data->hwnd, data->whole_window ); @@ -1452,17 +1457,12 @@ static Window create_whole_window( Display *display, struct x11drv_win_data *dat mask = get_window_attributes( display, data, &attr ); - data->whole_rect = data->window_rect; - X11DRV_window_to_X_rect( data, &data->whole_rect ); - if (!(cx = data->whole_rect.right - data->whole_rect.left)) cx = 1; - else if (cx > 65535) cx = 65535; - if (!(cy = data->whole_rect.bottom - data->whole_rect.top)) cy = 1; - else if (cy > 65535) cy = 65535; - wine_tsx11_lock(); + + data->whole_rect = data->window_rect; data->whole_window = XCreateWindow( display, root_window, - data->whole_rect.left - virtual_screen_rect.left, - data->whole_rect.top - virtual_screen_rect.top, + data->window_rect.left - virtual_screen_rect.left, + data->window_rect.top - virtual_screen_rect.top, cx, cy, 0, screen_depth, InputOutput, visual, mask, &attr ); diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h index 1a7a634f43e..b11e6a18b87 100644 --- a/dlls/winex11.drv/x11drv.h +++ b/dlls/winex11.drv/x11drv.h @@ -144,10 +144,11 @@ typedef struct } X11DRV_PDEVICE; + /* GCs used for B&W and color bitmap operations */ +extern GC BITMAP_monoGC, BITMAP_colorGC; extern X_PHYSBITMAP BITMAP_stock_phys_bitmap; /* phys bitmap for the default stock bitmap */ -/* Retrieve the GC used for bitmap operations */ -extern GC get_bitmap_gc(int depth); +#define BITMAP_GC(physBitmap) (((physBitmap)->pixmap_depth == 1) ? BITMAP_monoGC : BITMAP_colorGC) /* Wine driver X11 functions */ @@ -267,11 +268,6 @@ extern void X11DRV_XRender_DeleteDC(X11DRV_PDEVICE*); extern BOOL X11DRV_XRender_ExtTextOut(X11DRV_PDEVICE *physDev, INT x, INT y, UINT flags, const RECT *lprect, LPCWSTR wstr, UINT count, const INT *lpDx); -BOOL X11DRV_XRender_GetSrcAreaStretch(X11DRV_PDEVICE *physDevSrc, X11DRV_PDEVICE *physDevDst, - Pixmap pixmap, GC gc, - INT widthSrc, INT heightSrc, - INT widthDst, INT heightDst, - RECT *visRectSrc, RECT *visRectDst); extern void X11DRV_XRender_UpdateDrawable(X11DRV_PDEVICE *physDev); extern Drawable get_glxdrawable(X11DRV_PDEVICE *physDev); @@ -639,8 +635,6 @@ enum x11drv_atoms XATOM_XdndTypeList, XATOM_WCF_DIB, XATOM_image_gif, - XATOM_image_jpeg, - XATOM_image_png, XATOM_text_html, XATOM_text_plain, XATOM_text_rtf, diff --git a/dlls/winex11.drv/x11drv_main.c b/dlls/winex11.drv/x11drv_main.c index 8299457f0f9..41c866c3a37 100644 --- a/dlls/winex11.drv/x11drv_main.c +++ b/dlls/winex11.drv/x11drv_main.c @@ -172,8 +172,6 @@ static const char * const atom_names[NB_XATOMS - FIRST_XATOM] = "XdndTypeList", "WCF_DIB", "image/gif", - "image/jpeg", - "image/png", "text/html", "text/plain", "text/rtf", diff --git a/dlls/winex11.drv/xrandr.c b/dlls/winex11.drv/xrandr.c index c313bab8d00..4884e1fc042 100644 --- a/dlls/winex11.drv/xrandr.c +++ b/dlls/winex11.drv/xrandr.c @@ -178,11 +178,16 @@ static LONG X11DRV_XRandR_SetCurrentMode(int mode) short rate; unsigned int i; int j; + DWORD dwBpp = screen_bpp; wine_tsx11_lock(); root = RootWindow (gdi_display, DefaultScreen(gdi_display)); sc = pXRRGetScreenInfo (gdi_display, root); size = pXRRConfigCurrentConfiguration (sc, &rot); + if (dwBpp != dd_modes[mode].dwBPP) + { + FIXME("Cannot change screen BPP from %d to %d\n", dwBpp, dd_modes[mode].dwBPP); + } mode = mode%real_xrandr_modes_count; TRACE("Changing Resolution to %dx%d @%d Hz\n", diff --git a/dlls/winex11.drv/xrender.c b/dlls/winex11.drv/xrender.c index 072cd25d031..afe60cd3c6d 100644 --- a/dlls/winex11.drv/xrender.c +++ b/dlls/winex11.drv/xrender.c @@ -54,59 +54,8 @@ static BOOL X11DRV_XRender_Installed = FALSE; #define RepeatReflect 3 #endif -#define MAX_FORMATS 10 -typedef enum wine_xrformat -{ - WXR_FORMAT_MONO, - WXR_FORMAT_GRAY, - WXR_FORMAT_X1R5G5B5, - WXR_FORMAT_X1B5G5R5, - WXR_FORMAT_R5G6B5, - WXR_FORMAT_B5G6R5, - WXR_FORMAT_R8G8B8, - WXR_FORMAT_B8G8R8, - WXR_FORMAT_A8R8G8B8, - WXR_FORMAT_X8R8G8B8, -} WXRFormat; - -typedef struct wine_xrender_format_template -{ - WXRFormat wxr_format; - unsigned int depth; - unsigned int alpha; - unsigned int alphaMask; - unsigned int red; - unsigned int redMask; - unsigned int green; - unsigned int greenMask; - unsigned int blue; - unsigned int blueMask; -} WineXRenderFormatTemplate; - -static const WineXRenderFormatTemplate wxr_formats_template[] = -{ - /* Format depth alpha mask red mask green mask blue mask*/ - {WXR_FORMAT_MONO, 1, 0, 0x01, 0, 0, 0, 0, 0, 0 }, - {WXR_FORMAT_GRAY, 8, 0, 0xff, 0, 0, 0, 0, 0, 0 }, - {WXR_FORMAT_X1R5G5B5, 16, 0, 0, 10, 0x1f, 5, 0x1f, 0, 0x1f }, - {WXR_FORMAT_X1B5G5R5, 16, 0, 0, 0, 0x1f, 5, 0x1f, 10, 0x1f }, - {WXR_FORMAT_R5G6B5, 16, 0, 0, 11, 0x1f, 5, 0x3f, 0, 0x1f }, - {WXR_FORMAT_B5G6R5, 16, 0, 0, 0, 0x1f, 5, 0x3f, 11, 0x1f }, - {WXR_FORMAT_R8G8B8, 24, 0, 0, 16, 0xff, 8, 0xff, 0, 0xff }, - {WXR_FORMAT_B8G8R8, 24, 0, 0, 0, 0xff, 8, 0xff, 16, 0xff }, - {WXR_FORMAT_A8R8G8B8, 32, 24, 0xff, 16, 0xff, 8, 0xff, 0, 0xff }, - {WXR_FORMAT_X8R8G8B8, 32, 0, 0, 16, 0xff, 8, 0xff, 0, 0xff } -}; - -typedef struct wine_xrender_format -{ - WXRFormat format; - XRenderPictFormat *pict_format; -} WineXRenderFormat; - -static WineXRenderFormat wxr_formats[MAX_FORMATS]; -static int WineXRenderFormatsListSize = 0; -static WineXRenderFormat *default_format = NULL; +enum drawable_depth_type {mono_drawable, color_drawable}; +static XRenderPictFormat *pict_formats[2]; typedef struct { @@ -123,7 +72,7 @@ typedef enum { AA_None = 0, AA_Grey, AA_RGB, AA_BGR, AA_VRGB, AA_VBGR, AA_MAXVAL typedef struct { GlyphSet glyphset; - WineXRenderFormat *font_format; + XRenderPictFormat *font_format; int nrealized; BOOL *realized; void **bitmaps; @@ -206,101 +155,6 @@ static CRITICAL_SECTION xrender_cs = { &critsect_debug, -1, 0, 0, 0, 0 }; #define NATIVE_BYTE_ORDER LSBFirst #endif -static BOOL get_xrender_template(const WineXRenderFormatTemplate *fmt, XRenderPictFormat *templ, unsigned long *mask) -{ - templ->id = 0; - templ->type = PictTypeDirect; - templ->depth = fmt->depth; - templ->direct.alpha = fmt->alpha; - templ->direct.alphaMask = fmt->alphaMask; - templ->direct.red = fmt->red; - templ->direct.redMask = fmt->redMask; - templ->direct.green = fmt->green; - templ->direct.greenMask = fmt->greenMask; - templ->direct.blue = fmt->blue; - templ->direct.blueMask = fmt->blueMask; - templ->colormap = 0; - - *mask = PictFormatType | PictFormatDepth | PictFormatAlpha | PictFormatAlphaMask | PictFormatRed | PictFormatRedMask | PictFormatGreen | PictFormatGreenMask | PictFormatBlue | PictFormatBlueMask; - - return TRUE; -} - -static BOOL is_wxrformat_compatible_with_default_visual(const WineXRenderFormatTemplate *fmt) -{ - if(fmt->depth != screen_depth) - return FALSE; - if( (fmt->redMask << fmt->red) != visual->red_mask) - return FALSE; - if( (fmt->greenMask << fmt->green) != visual->green_mask) - return FALSE; - if( (fmt->blueMask << fmt->blue) != visual->blue_mask) - return FALSE; - - /* We never select a default ARGB visual */ - if(fmt->alphaMask) - return FALSE; - - return TRUE; -} - -static int load_xrender_formats(void) -{ - unsigned int i; - for(i = 0; i < (sizeof(wxr_formats_template) / sizeof(wxr_formats_template[0])); i++) - { - XRenderPictFormat templ, *pict_format; - - if(is_wxrformat_compatible_with_default_visual(&wxr_formats_template[i])) - { - wine_tsx11_lock(); - pict_format = pXRenderFindVisualFormat(gdi_display, visual); - if(!pict_format) - { - /* Xrender doesn't like DirectColor visuals, try to find a TrueColor one instead */ - if (visual->class == DirectColor) - { - XVisualInfo info; - if (XMatchVisualInfo( gdi_display, DefaultScreen(gdi_display), - screen_depth, TrueColor, &info )) - { - pict_format = pXRenderFindVisualFormat(gdi_display, info.visual); - if (pict_format) visual = info.visual; - } - } - } - wine_tsx11_unlock(); - - if(pict_format) - { - wxr_formats[WineXRenderFormatsListSize].format = wxr_formats_template[i].wxr_format; - wxr_formats[WineXRenderFormatsListSize].pict_format = pict_format; - default_format = &wxr_formats[WineXRenderFormatsListSize]; - WineXRenderFormatsListSize++; - TRACE("Loaded pict_format with id=%#lx for wxr_format=%#x\n", pict_format->id, wxr_formats_template[i].wxr_format); - } - } - else - { - unsigned long mask = 0; - get_xrender_template(&wxr_formats_template[i], &templ, &mask); - - wine_tsx11_lock(); - pict_format = pXRenderFindFormat(gdi_display, mask, &templ, 0); - wine_tsx11_unlock(); - - if(pict_format) - { - wxr_formats[WineXRenderFormatsListSize].format = wxr_formats_template[i].wxr_format; - wxr_formats[WineXRenderFormatsListSize].pict_format = pict_format; - WineXRenderFormatsListSize++; - TRACE("Loaded pict_format with id=%#lx for wxr_format=%#x\n", pict_format->id, wxr_formats_template[i].wxr_format); - } - } - } - return WineXRenderFormatsListSize; -} - /*********************************************************************** * X11DRV_XRender_Init * @@ -310,6 +164,7 @@ static int load_xrender_formats(void) void X11DRV_XRender_Init(void) { int event_base, i; + XRenderPictFormat pf; if (client_side_with_render && wine_dlopen(SONAME_LIBX11, RTLD_NOW|RTLD_GLOBAL, NULL, 0) && @@ -340,12 +195,27 @@ LOAD_OPTIONAL_FUNCPTR(XRenderSetPictureTransform) #undef LOAD_OPTIONAL_FUNCPTR #endif + wine_tsx11_lock(); - X11DRV_XRender_Installed = pXRenderQueryExtension(gdi_display, &event_base, &xrender_error_base); - wine_tsx11_unlock(); - if(X11DRV_XRender_Installed) { + if(pXRenderQueryExtension(gdi_display, &event_base, &xrender_error_base)) { + X11DRV_XRender_Installed = TRUE; TRACE("Xrender is up and running error_base = %d\n", xrender_error_base); - if(!load_xrender_formats()) /* This fails in buggy versions of libXrender.so */ + pict_formats[color_drawable] = pXRenderFindVisualFormat(gdi_display, visual); + if(!pict_formats[color_drawable]) + { + /* Xrender doesn't like DirectColor visuals, try to find a TrueColor one instead */ + if (visual->class == DirectColor) + { + XVisualInfo info; + if (XMatchVisualInfo( gdi_display, DefaultScreen(gdi_display), + screen_depth, TrueColor, &info )) + { + pict_formats[color_drawable] = pXRenderFindVisualFormat(gdi_display, info.visual); + if (pict_formats[color_drawable]) visual = info.visual; + } + } + } + if(!pict_formats[color_drawable]) /* This fails in buggy versions of libXrender.so */ { wine_tsx11_unlock(); WINE_MESSAGE( @@ -355,12 +225,23 @@ LOAD_OPTIONAL_FUNCPTR(XRenderSetPictureTransform) X11DRV_XRender_Installed = FALSE; return; } - + pf.type = PictTypeDirect; + pf.depth = 1; + pf.direct.alpha = 0; + pf.direct.alphaMask = 1; + pict_formats[mono_drawable] = pXRenderFindFormat(gdi_display, PictFormatType | + PictFormatDepth | PictFormatAlpha | + PictFormatAlphaMask, &pf, 0); + if(!pict_formats[mono_drawable]) { + ERR("mono_format == NULL?\n"); + X11DRV_XRender_Installed = FALSE; + } if (!visual->red_mask || !visual->green_mask || !visual->blue_mask) { WARN("one or more of the colour masks are 0, disabling XRENDER. Try running in 16-bit mode or higher.\n"); X11DRV_XRender_Installed = FALSE; } } + wine_tsx11_unlock(); } sym_not_found: @@ -390,62 +271,6 @@ sym_not_found: else TRACE("Using X11 core fonts\n"); } -/* Helper function to convert from a color packed in a 32-bit integer to a XRenderColor */ -static void get_xrender_color(WineXRenderFormat *wxr_format, int src_color, XRenderColor *dst_color) -{ - XRenderPictFormat *pf = wxr_format->pict_format; - - if(pf->direct.redMask) - dst_color->red = ((src_color >> pf->direct.red) & pf->direct.redMask) * 65535/pf->direct.redMask; - else - dst_color->red = 0; - - if(pf->direct.greenMask) - dst_color->green = ((src_color >> pf->direct.green) & pf->direct.greenMask) * 65535/pf->direct.greenMask; - else - dst_color->green = 0; - - if(pf->direct.blueMask) - dst_color->blue = ((src_color >> pf->direct.blue) & pf->direct.blueMask) * 65535/pf->direct.blueMask; - else - dst_color->blue = 0; - - dst_color->alpha = 0xffff; -} - -static WineXRenderFormat *get_xrender_format(WXRFormat format) -{ - int i; - for(i=0; idepth) - { - case 1: - format = WXR_FORMAT_MONO; - break; - default: - /* For now fall back to the format of the default visual. - In the future we should check if we are using a DDB/DIB and what exact format we need. - */ - return default_format; - } - - return get_xrender_format(format); -} - static BOOL fontcmp(LFANDSIZE *p1, LFANDSIZE *p2) { if(p1->hash != p2->hash) return TRUE; @@ -853,7 +678,8 @@ static BOOL UploadGlyph(X11DRV_PDEVICE *physDev, int glyph, AA_Type format) gsCacheEntry *entry = glyphsetCache + physDev->xrender->cache_index; gsCacheEntryFormat *formatEntry; UINT ggo_format = GGO_GLYPH_INDEX; - WXRFormat wxr_format; + XRenderPictFormat pf; + unsigned long pf_mask; static const char zero[4]; static const MAT2 identity = { {0,1},{0,0},{0,0},{0,1} }; @@ -942,28 +768,48 @@ static BOOL UploadGlyph(X11DRV_PDEVICE *physDev, int glyph, AA_Type format) if(formatEntry->glyphset == 0 && X11DRV_XRender_Installed) { switch(format) { - case AA_Grey: - wxr_format = WXR_FORMAT_GRAY; - break; - - case AA_RGB: - case AA_BGR: - case AA_VRGB: - case AA_VBGR: - wxr_format = WXR_FORMAT_A8R8G8B8; - break; + case AA_Grey: + pf_mask = PictFormatType | PictFormatDepth | PictFormatAlpha | PictFormatAlphaMask, + pf.type = PictTypeDirect; + pf.depth = 8; + pf.direct.alpha = 0; + pf.direct.alphaMask = 0xff; + break; + + case AA_RGB: + case AA_BGR: + case AA_VRGB: + case AA_VBGR: + pf_mask = PictFormatType | PictFormatDepth | PictFormatRed | PictFormatRedMask | + PictFormatGreen | PictFormatGreenMask | PictFormatBlue | + PictFormatBlueMask | PictFormatAlpha | PictFormatAlphaMask; + pf.type = PictTypeDirect; + pf.depth = 32; + pf.direct.red = 16; + pf.direct.redMask = 0xff; + pf.direct.green = 8; + pf.direct.greenMask = 0xff; + pf.direct.blue = 0; + pf.direct.blueMask = 0xff; + pf.direct.alpha = 24; + pf.direct.alphaMask = 0xff; + break; - default: - ERR("aa = %d - not implemented\n", format); - case AA_None: - wxr_format = WXR_FORMAT_MONO; - break; - } + default: + ERR("aa = %d - not implemented\n", format); + case AA_None: + pf_mask = PictFormatType | PictFormatDepth | PictFormatAlpha | PictFormatAlphaMask, + pf.type = PictTypeDirect; + pf.depth = 1; + pf.direct.alpha = 0; + pf.direct.alphaMask = 1; + break; + } - wine_tsx11_lock(); - formatEntry->font_format = get_xrender_format(wxr_format); - formatEntry->glyphset = pXRenderCreateGlyphSet(gdi_display, formatEntry->font_format->pict_format); - wine_tsx11_unlock(); + wine_tsx11_lock(); + formatEntry->font_format = pXRenderFindFormat(gdi_display, pf_mask, &pf, 0); + formatEntry->glyphset = pXRenderCreateGlyphSet(gdi_display, formatEntry->font_format); + wine_tsx11_unlock(); } @@ -1307,33 +1153,33 @@ static void SmoothGlyphGray(XImage *image, int x, int y, void *bitmap, XGlyphInf * Returns an appropriate Picture for tiling the text colour. * Call and use result within the xrender_cs */ -static Picture get_tile_pict(WineXRenderFormat *wxr_format, int text_pixel) +static Picture get_tile_pict(enum drawable_depth_type type, int text_pixel) { static struct { Pixmap xpm; Picture pict; int current_color; - } tiles[MAX_FORMATS], *tile; + } tiles[2], *tile; XRenderColor col; - tile = &tiles[wxr_format->format]; + tile = &tiles[type]; if(!tile->xpm) { XRenderPictureAttributes pa; wine_tsx11_lock(); - tile->xpm = XCreatePixmap(gdi_display, root_window, 1, 1, wxr_format->pict_format->depth); + tile->xpm = XCreatePixmap(gdi_display, root_window, 1, 1, pict_formats[type]->depth); pa.repeat = RepeatNormal; - tile->pict = pXRenderCreatePicture(gdi_display, tile->xpm, wxr_format->pict_format, CPRepeat, &pa); + tile->pict = pXRenderCreatePicture(gdi_display, tile->xpm, pict_formats[type], CPRepeat, &pa); wine_tsx11_unlock(); /* init current_color to something different from text_pixel */ tile->current_color = ~text_pixel; - if(wxr_format->format == WXR_FORMAT_MONO) + if(type == mono_drawable) { /* for a 1bpp bitmap we always need a 1 in the tile */ col.red = col.green = col.blue = 0; @@ -1344,9 +1190,25 @@ static Picture get_tile_pict(WineXRenderFormat *wxr_format, int text_pixel) } } - if(text_pixel != tile->current_color && wxr_format->format != WXR_FORMAT_MONO) + if(text_pixel != tile->current_color && type == color_drawable) { - get_xrender_color(wxr_format, text_pixel, &col); + /* Map 0 -- 0xff onto 0 -- 0xffff */ + int r_shift, r_len; + int g_shift, g_len; + int b_shift, b_len; + + ExamineBitfield (visual->red_mask, &r_shift, &r_len ); + ExamineBitfield (visual->green_mask, &g_shift, &g_len); + ExamineBitfield (visual->blue_mask, &b_shift, &b_len); + + col.red = GetField(text_pixel, r_shift, r_len); + col.red |= col.red << 8; + col.green = GetField(text_pixel, g_shift, g_len); + col.green |= col.green << 8; + col.blue = GetField(text_pixel, b_shift, b_len); + col.blue |= col.blue << 8; + col.alpha = 0xffff; + wine_tsx11_lock(); pXRenderFillRectangle(gdi_display, PictOpSrc, tile->pict, &col, 0, 0, 1, 1); wine_tsx11_unlock(); @@ -1381,7 +1243,7 @@ BOOL X11DRV_XRender_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flag unsigned int idx; double cosEsc, sinEsc; LOGFONTW lf; - WineXRenderFormat *dst_format = get_xrender_format_from_pdevice(physDev); + enum drawable_depth_type depth_type = (physDev->depth == 1) ? mono_drawable : color_drawable; Picture tile_pict = 0; /* Do we need to disable antialiasing because of palette mode? */ @@ -1460,7 +1322,8 @@ BOOL X11DRV_XRender_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flag wine_tsx11_lock(); physDev->xrender->pict = pXRenderCreatePicture(gdi_display, - physDev->drawable, dst_format->pict_format, + physDev->drawable, + pict_formats[depth_type], CPSubwindowMode, &pa); wine_tsx11_unlock(); @@ -1525,11 +1388,11 @@ BOOL X11DRV_XRender_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flag desired.y = physDev->dc_rect.top + y; current.x = current.y = 0; - tile_pict = get_tile_pict(dst_format, physDev->textPixel); + tile_pict = get_tile_pict(depth_type, physDev->textPixel); /* FIXME the mapping of Text/BkColor onto 1 or 0 needs investigation. */ - if((dst_format->format == WXR_FORMAT_MONO) && (textPixel == 0)) + if((depth_type == mono_drawable) && (textPixel == 0)) render_op = PictOpOutReverse; /* This gives us 'black' text */ for(idx = 0; idx < count; idx++) @@ -1559,7 +1422,7 @@ BOOL X11DRV_XRender_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flag pXRenderCompositeText16(gdi_display, render_op, tile_pict, physDev->xrender->pict, - formatEntry->font_format->pict_format, + formatEntry->font_format, 0, 0, 0, 0, elts, count); wine_tsx11_unlock(); HeapFree(GetProcessHeap(), 0, elts); @@ -1719,55 +1582,6 @@ done_unlock: return retv; } -/* Set the x/y scaling and x/y offsets in the transformation matrix of the source picture */ -static void set_xrender_transformation(Picture src_pict, float xscale, float yscale, int xoffset, int yoffset) -{ -#ifdef HAVE_XRENDERSETPICTURETRANSFORM - XTransform xform = {{ - { XDoubleToFixed(xscale), XDoubleToFixed(0), XDoubleToFixed(xoffset) }, - { XDoubleToFixed(0), XDoubleToFixed(yscale), XDoubleToFixed(yoffset) }, - { XDoubleToFixed(0), XDoubleToFixed(0), XDoubleToFixed(1) } - }}; - - pXRenderSetPictureTransform(gdi_display, src_pict, &xform); -#endif -} - -/* Helper function for (stretched) blitting using xrender */ -static void xrender_blit(Picture src_pict, Picture mask_pict, Picture dst_pict, int x_src, int y_src, float xscale, float yscale, int width, int height) -{ - /* Further down a transformation matrix is used for stretching and mirroring the source data. - * xscale/yscale contain the scaling factors for the width and height. In case of mirroring - * we also need a x- and y-offset because without the pixels will be in the wrong quadrant of the x-y plane. - */ - int x_offset = (xscale<0) ? width : 0; - int y_offset = (yscale<0) ? height : 0; - - /* When we need to scale we perform scaling and source_x / source_y translation using a transformation matrix. - * This is needed because XRender is inaccurate in combination with scaled source coordinates passed to XRenderComposite. - * In all other cases we do use XRenderComposite for translation as it is faster than using a transformation matrix. */ - if(xscale != 1.0 || yscale != 1.0) - { - /* When we are using a mask, 'src_pict' contains a 1x1 picture for tiling, the actual source data is in mask_pict */ - if(mask_pict) - set_xrender_transformation(mask_pict, xscale, yscale, x_offset, y_offset); - else - set_xrender_transformation(src_pict, xscale, yscale, x_src + x_offset, y_src + y_offset); - - pXRenderComposite(gdi_display, PictOpSrc, src_pict, mask_pict, dst_pict, 0, 0, 0, 0, 0, 0, width, height); - } - else - { - /* When we are using a mask, 'src_pict' contains a 1x1 picture for tiling, the actual source data is in mask_pict */ - if(mask_pict) - set_xrender_transformation(mask_pict, 1, 1, 0, 0); - else - set_xrender_transformation(src_pict, 1, 1, 0, 0); - - pXRenderComposite(gdi_display, PictOpSrc, src_pict, mask_pict, dst_pict, x_src, y_src, 0, 0, 0, 0, width, height); - } -} - /****************************************************************************** * AlphaBlend (x11drv.@) */ @@ -1776,6 +1590,35 @@ BOOL CDECL X11DRV_AlphaBlend(X11DRV_PDEVICE *devDst, INT xDst, INT yDst, INT wid BLENDFUNCTION blendfn) { XRenderPictureAttributes pa; + XRenderPictFormat *src_format; + XRenderPictFormat argb32_templ = { + 0, /* id */ + PictTypeDirect, /* type */ + 32, /* depth */ + { /* direct */ + 16, /* direct.red */ + 0xff, /* direct.redMask */ + 8, /* direct.green */ + 0xff, /* direct.greenMask */ + 0, /* direct.blue */ + 0xff, /* direct.blueMask */ + 24, /* direct.alpha */ + 0xff, /* direct.alphaMask */ + }, + 0, /* colormap */ + }; + unsigned long argb32_templ_mask = + PictFormatType | + PictFormatDepth | + PictFormatRed | + PictFormatRedMask | + PictFormatGreen | + PictFormatGreenMask | + PictFormatBlue | + PictFormatBlueMask | + PictFormatAlpha | + PictFormatAlphaMask; + Picture dst_pict, src_pict; Pixmap xpm; DIBSECTION dib; @@ -1787,8 +1630,7 @@ BOOL CDECL X11DRV_AlphaBlend(X11DRV_PDEVICE *devDst, INT xDst, INT yDst, INT wid POINT pts[2]; BOOL top_down = FALSE; RGNDATA *rgndata; - WineXRenderFormat *dst_format = get_xrender_format_from_pdevice(devDst); - WineXRenderFormat *src_format; + enum drawable_depth_type dst_depth_type = (devDst->depth == 1) ? mono_drawable : color_drawable; int repeat_src; if(!X11DRV_XRender_Installed) { @@ -1905,13 +1747,13 @@ BOOL CDECL X11DRV_AlphaBlend(X11DRV_PDEVICE *devDst, INT xDst, INT yDst, INT wid image = XCreateImage(gdi_display, visual, 32, ZPixmap, 0, (char*) data, widthSrc, heightSrc, 32, widthSrc * 4); - src_format = get_xrender_format(WXR_FORMAT_A8R8G8B8); + /* + Avoid using XRenderFindStandardFormat as older libraries don't have it + src_format = pXRenderFindStandardFormat(gdi_display, PictStandardARGB32); + */ + src_format = pXRenderFindFormat(gdi_display, argb32_templ_mask, &argb32_templ, 0); + TRACE("src_format %p\n", src_format); - if(!src_format) - { - WARN("Unable to find a picture format supporting alpha, make sure X is running at 24-bit\n"); - return FALSE; - } pa.subwindow_mode = IncludeInferiors; pa.repeat = repeat_src ? RepeatNormal : RepeatNone; @@ -1919,7 +1761,7 @@ BOOL CDECL X11DRV_AlphaBlend(X11DRV_PDEVICE *devDst, INT xDst, INT yDst, INT wid /* FIXME use devDst->xrender->pict ? */ dst_pict = pXRenderCreatePicture(gdi_display, devDst->drawable, - dst_format->pict_format, + pict_formats[dst_depth_type], CPSubwindowMode, &pa); TRACE("dst_pict %08lx\n", dst_pict); TRACE("src_drawable = %08lx\n", devSrc->drawable); @@ -1932,7 +1774,7 @@ BOOL CDECL X11DRV_AlphaBlend(X11DRV_PDEVICE *devDst, INT xDst, INT yDst, INT wid XPutImage(gdi_display, xpm, gc, image, 0, 0, 0, 0, widthSrc, heightSrc); src_pict = pXRenderCreatePicture(gdi_display, - xpm, src_format->pict_format, + xpm, src_format, CPSubwindowMode|CPRepeat, &pa); TRACE("src_pict %08lx\n", src_pict); @@ -1945,10 +1787,18 @@ BOOL CDECL X11DRV_AlphaBlend(X11DRV_PDEVICE *devDst, INT xDst, INT yDst, INT wid HeapFree( GetProcessHeap(), 0, rgndata ); } - /* Make sure we ALWAYS set the transformation matrix even if we don't need to scale. The reason is - * that later on we want to reuse pictures (it can bring a lot of extra performance) and each time - * a different transformation matrix might have been used. */ - set_xrender_transformation(src_pict, widthSrc/(double)widthDst, heightSrc/(double)heightDst, 0, 0); +#ifdef HAVE_XRENDERSETPICTURETRANSFORM + if(!repeat_src && (widthDst != widthSrc || heightDst != heightSrc)) { + double xscale = widthSrc/(double)widthDst; + double yscale = heightSrc/(double)heightDst; + XTransform xform = {{ + { XDoubleToFixed(xscale), XDoubleToFixed(0), XDoubleToFixed(0) }, + { XDoubleToFixed(0), XDoubleToFixed(yscale), XDoubleToFixed(0) }, + { XDoubleToFixed(0), XDoubleToFixed(0), XDoubleToFixed(1) } + }}; + pXRenderSetPictureTransform(gdi_display, src_pict, &xform); + } +#endif pXRenderComposite(gdi_display, PictOpOver, src_pict, 0, dst_pict, 0, 0, 0, 0, xDst + devDst->dc_rect.left, yDst + devDst->dc_rect.top, widthDst, heightDst); @@ -1966,98 +1816,6 @@ BOOL CDECL X11DRV_AlphaBlend(X11DRV_PDEVICE *devDst, INT xDst, INT yDst, INT wid return TRUE; } -BOOL X11DRV_XRender_GetSrcAreaStretch(X11DRV_PDEVICE *physDevSrc, X11DRV_PDEVICE *physDevDst, - Pixmap pixmap, GC gc, - INT widthSrc, INT heightSrc, - INT widthDst, INT heightDst, - RECT *visRectSrc, RECT *visRectDst ) -{ - BOOL stretch = (widthSrc != widthDst) || (heightSrc != heightDst); - int width = visRectDst->right - visRectDst->left; - int height = visRectDst->bottom - visRectDst->top; - int x_src = physDevSrc->dc_rect.left + visRectSrc->left; - int y_src = physDevSrc->dc_rect.top + visRectSrc->top; - WineXRenderFormat *src_format = get_xrender_format_from_pdevice(physDevSrc); - WineXRenderFormat *dst_format = get_xrender_format_from_pdevice(physDevDst); - Picture src_pict=0, dst_pict=0, mask_pict=0; - - double xscale = widthSrc/(double)widthDst; - double yscale = heightSrc/(double)heightDst; - - XRenderPictureAttributes pa; - pa.subwindow_mode = IncludeInferiors; - pa.repeat = RepeatNone; - - TRACE("src depth=%d widthSrc=%d heightSrc=%d xSrc=%d ySrc=%d\n", physDevSrc->depth, widthSrc, heightSrc, x_src, y_src); - TRACE("dst depth=%d widthDst=%d heightDst=%d\n", physDevDst->depth, widthDst, heightDst); - - if(!X11DRV_XRender_Installed) - { - TRACE("Not using XRender since it is not available or disabled\n"); - return FALSE; - } - - /* XRender can't handle palettes, so abort */ - if(X11DRV_PALETTE_XPixelToPalette) - return FALSE; - - /* XRender is of no use in this case */ - if((physDevDst->depth == 1) && (physDevSrc->depth > 1)) - return FALSE; - - /* Just use traditional X copy when the depths match and we don't need stretching */ - if((physDevSrc->depth == physDevDst->depth) && !stretch) - { - TRACE("Source and destination depth match and no stretching needed falling back to XCopyArea\n"); - wine_tsx11_lock(); - XCopyArea( gdi_display, physDevSrc->drawable, pixmap, gc, x_src, y_src, width, height, 0, 0); - wine_tsx11_unlock(); - return TRUE; - } - - /* mono -> color */ - if(physDevSrc->depth == 1) - { - XRenderColor col; - get_xrender_color(dst_format, physDevDst->textPixel, &col); - - /* We use the source drawable as a mask */ - wine_tsx11_lock(); - mask_pict = pXRenderCreatePicture(gdi_display, physDevSrc->drawable, src_format->pict_format, CPSubwindowMode|CPRepeat, &pa); - - /* Use backgroundPixel as the foreground color */ - src_pict = get_tile_pict(dst_format, physDevDst->backgroundPixel); - - /* Create a destination picture and fill it with textPixel color as the background color */ - dst_pict = pXRenderCreatePicture(gdi_display, pixmap, dst_format->pict_format, CPSubwindowMode|CPRepeat, &pa); - pXRenderFillRectangle(gdi_display, PictOpSrc, dst_pict, &col, 0, 0, width, height); - - xrender_blit(src_pict, mask_pict, dst_pict, x_src, y_src, xscale, yscale, width, height); - - if(dst_pict) pXRenderFreePicture(gdi_display, dst_pict); - if(mask_pict) pXRenderFreePicture(gdi_display, mask_pict); - wine_tsx11_unlock(); - } - else /* color -> color but with different depths */ - { - wine_tsx11_lock(); - src_pict = pXRenderCreatePicture(gdi_display, - physDevSrc->drawable, src_format->pict_format, - CPSubwindowMode|CPRepeat, &pa); - - dst_pict = pXRenderCreatePicture(gdi_display, - pixmap, dst_format->pict_format, - CPSubwindowMode|CPRepeat, &pa); - - xrender_blit(src_pict, 0, dst_pict, x_src, y_src, xscale, yscale, width, height); - - if(src_pict) pXRenderFreePicture(gdi_display, src_pict); - if(dst_pict) pXRenderFreePicture(gdi_display, dst_pict); - wine_tsx11_unlock(); - } - return TRUE; -} - #else /* SONAME_LIBXRENDER */ void X11DRV_XRender_Init(void) @@ -2107,14 +1865,4 @@ BOOL X11DRV_AlphaBlend(X11DRV_PDEVICE *devDst, INT xDst, INT yDst, INT widthDst, return FALSE; } -BOOL X11DRV_XRender_GetSrcAreaStretch(X11DRV_PDEVICE *physDevSrc, X11DRV_PDEVICE *physDevDst, - Pixmap pixmap, GC gc, - INT xSrc, INT ySrc, - INT widthSrc, INT heightSrc, - INT xDst, INT yDst, - INT widthDst, INT heightDst, - RECT *visRectSrc, RECT *visRectDst) -{ - return FALSE; -} #endif /* SONAME_LIBXRENDER */ diff --git a/dlls/winhttp/Makefile.in b/dlls/winhttp/Makefile.in index 7a61dc92f86..78d3814ad20 100644 --- a/dlls/winhttp/Makefile.in +++ b/dlls/winhttp/Makefile.in @@ -5,7 +5,7 @@ VPATH = @srcdir@ MODULE = winhttp.dll IMPORTLIB = winhttp IMPORTS = shlwapi kernel32 -DELAYIMPORTS = crypt32 advapi32 +DELAYIMPORTS = crypt32 EXTRALIBS = @SOCKETLIBS@ C_SRCS = \ diff --git a/dlls/winhttp/net.c b/dlls/winhttp/net.c index ed4d4b90e37..79e67890298 100644 --- a/dlls/winhttp/net.c +++ b/dlls/winhttp/net.c @@ -58,6 +58,9 @@ WINE_DEFAULT_DEBUG_CHANNEL(winhttp); +#define DEFAULT_SEND_TIMEOUT 30 +#define DEFAULT_RECEIVE_TIMEOUT 30 + #ifndef HAVE_GETADDRINFO /* critical section to protect non-reentrant gethostbyname() */ @@ -97,6 +100,8 @@ MAKE_FUNCPTR( SSL_write ); MAKE_FUNCPTR( SSL_read ); MAKE_FUNCPTR( SSL_get_verify_result ); MAKE_FUNCPTR( SSL_get_peer_certificate ); +MAKE_FUNCPTR( SSL_CTX_get_timeout ); +MAKE_FUNCPTR( SSL_CTX_set_timeout ); MAKE_FUNCPTR( SSL_CTX_set_default_verify_paths ); MAKE_FUNCPTR( BIO_new_fp ); @@ -213,6 +218,8 @@ BOOL netconn_init( netconn_t *conn, BOOL secure ) LOAD_FUNCPTR( SSL_read ); LOAD_FUNCPTR( SSL_get_verify_result ); LOAD_FUNCPTR( SSL_get_peer_certificate ); + LOAD_FUNCPTR( SSL_CTX_get_timeout ); + LOAD_FUNCPTR( SSL_CTX_set_timeout ); LOAD_FUNCPTR( SSL_CTX_set_default_verify_paths ); #undef LOAD_FUNCPTR @@ -287,44 +294,15 @@ BOOL netconn_close( netconn_t *conn ) return TRUE; } -BOOL netconn_connect( netconn_t *conn, const struct sockaddr *sockaddr, unsigned int addr_len, int timeout ) +BOOL netconn_connect( netconn_t *conn, const struct sockaddr *sockaddr, unsigned int addr_len ) { - BOOL ret = FALSE; - int res = 0, state; - - if (timeout > 0) - { - state = 1; - ioctlsocket( conn->socket, FIONBIO, &state ); - } - if (connect( conn->socket, sockaddr, addr_len ) < 0) - { - res = sock_get_error( errno ); - if (res == WSAEWOULDBLOCK || res == WSAEINPROGRESS) - { - struct pollfd pfd; - - pfd.fd = conn->socket; - pfd.events = POLLOUT; - if (poll( &pfd, 1, timeout ) > 0) - ret = TRUE; - else - res = sock_get_error( errno ); - } - } - else - ret = TRUE; - if (timeout > 0) + if (connect( conn->socket, sockaddr, addr_len ) == -1) { - state = 0; - ioctlsocket( conn->socket, FIONBIO, &state ); - } - if (!ret) - { - WARN("unable to connect to host (%d)\n", res); - set_last_error( res ); + WARN("unable to connect to host (%s)\n", strerror(errno)); + set_last_error( sock_get_error( errno ) ); + return FALSE; } - return ret; + return TRUE; } BOOL netconn_secure_connect( netconn_t *conn ) @@ -504,6 +482,11 @@ BOOL netconn_get_next_line( netconn_t *conn, char *buffer, DWORD *buflen ) if (conn->secure) { #ifdef SONAME_LIBSSL + long timeout; + + timeout = pSSL_CTX_get_timeout( ctx ); + pSSL_CTX_set_timeout( ctx, DEFAULT_RECEIVE_TIMEOUT ); + while (recvd < *buflen) { int dummy; @@ -519,6 +502,7 @@ BOOL netconn_get_next_line( netconn_t *conn, char *buffer, DWORD *buflen ) } if (buffer[recvd] != '\r') recvd++; } + pSSL_CTX_set_timeout( ctx, timeout ); if (ret) { buffer[recvd++] = 0; @@ -535,16 +519,9 @@ BOOL netconn_get_next_line( netconn_t *conn, char *buffer, DWORD *buflen ) pfd.events = POLLIN; while (recvd < *buflen) { - int timeout, res; - struct timeval tv; - socklen_t len = sizeof(tv); - - if ((res = getsockopt( conn->socket, SOL_SOCKET, SO_RCVTIMEO, (void*)&tv, &len ) != -1)) - timeout = tv.tv_sec * 1000 + tv.tv_usec / 1000; - else - timeout = -1; - if (poll( &pfd, 1, timeout ) > 0) + if (poll( &pfd, 1, DEFAULT_RECEIVE_TIMEOUT * 1000 ) > 0) { + int res; if ((res = recv( conn->socket, &buffer[recvd], 1, 0 )) <= 0) { if (res == -1) set_last_error( sock_get_error( errno ) ); @@ -589,7 +566,7 @@ DWORD netconn_set_timeout( netconn_t *netconn, BOOL send, int value ) return ERROR_SUCCESS; } -BOOL netconn_resolve( WCHAR *hostnameW, INTERNET_PORT port, struct sockaddr *sa, socklen_t *sa_len ) +BOOL netconn_resolve( WCHAR *hostnameW, INTERNET_PORT port, struct sockaddr_in *sa ) { char *hostname; #ifdef HAVE_GETADDRINFO @@ -597,53 +574,27 @@ BOOL netconn_resolve( WCHAR *hostnameW, INTERNET_PORT port, struct sockaddr *sa, int ret; #else struct hostent *he; - struct sockaddr_in *sin = (struct sockaddr_in *)sa; #endif if (!(hostname = strdupWA( hostnameW ))) return FALSE; #ifdef HAVE_GETADDRINFO memset( &hints, 0, sizeof(struct addrinfo) ); - /* Prefer IPv4 to IPv6 addresses, since some web servers do not listen on - * their IPv6 addresses even though they have IPv6 addresses in the DNS. - */ hints.ai_family = AF_INET; ret = getaddrinfo( hostname, NULL, &hints, &res ); - if (ret != 0) - { - TRACE("failed to get IPv4 address of %s (%s), retrying with IPv6\n", debugstr_w(hostnameW), gai_strerror(ret)); - hints.ai_family = AF_INET6; - ret = getaddrinfo( hostname, NULL, &hints, &res ); - if (ret != 0) - { - TRACE("failed to get address of %s (%s)\n", debugstr_w(hostnameW), gai_strerror(ret)); - heap_free( hostname ); - return FALSE; - } - } heap_free( hostname ); - if (*sa_len < res->ai_addrlen) + if (ret != 0) { - WARN("address too small\n"); - freeaddrinfo( res ); + TRACE("failed to get address of %s (%s)\n", debugstr_w(hostnameW), gai_strerror(ret)); return FALSE; } - *sa_len = res->ai_addrlen; - memcpy( sa, res->ai_addr, res->ai_addrlen ); - /* Copy port */ - switch (res->ai_family) - { - case AF_INET: - ((struct sockaddr_in *)sa)->sin_port = htons( port ); - break; - case AF_INET6: - ((struct sockaddr_in6 *)sa)->sin6_port = htons( port ); - break; - } + memset( sa, 0, sizeof(struct sockaddr_in) ); + memcpy( &sa->sin_addr, &((struct sockaddr_in *)res->ai_addr)->sin_addr, sizeof(struct in_addr) ); + sa->sin_family = res->ai_family; + sa->sin_port = htons( port ); freeaddrinfo( res ); - return TRUE; #else EnterCriticalSection( &cs_gethostbyname ); @@ -655,21 +606,14 @@ BOOL netconn_resolve( WCHAR *hostnameW, INTERNET_PORT port, struct sockaddr *sa, LeaveCriticalSection( &cs_gethostbyname ); return FALSE; } - if (*sa_len < sizeof(struct sockaddr_in)) - { - WARN("address too small\n"); - LeaveCriticalSection( &cs_gethostbyname ); - return FALSE; - } - *sa_len = sizeof(struct sockaddr_in); memset( sa, 0, sizeof(struct sockaddr_in) ); - memcpy( &sin->sin_addr, he->h_addr, he->h_length ); - sin->sin_family = he->h_addrtype; - sin->sin_port = htons( port ); + memcpy( &sa->sin_addr, he->h_addr, he->h_length ); + sa->sin_family = he->h_addrtype; + sa->sin_port = htons( port ); LeaveCriticalSection( &cs_gethostbyname ); - return TRUE; #endif + return TRUE; } const void *netconn_get_certificate( netconn_t *conn ) diff --git a/dlls/winhttp/request.c b/dlls/winhttp/request.c index 0efada470d5..ddfac13c449 100644 --- a/dlls/winhttp/request.c +++ b/dlls/winhttp/request.c @@ -1,8 +1,5 @@ /* - * Copyright 2004 Mike McCormack for CodeWeavers - * Copyright 2006 Rob Shearman for CodeWeavers * Copyright 2008 Hans Leidekker for CodeWeavers - * Copyright 2009 Juan Lang * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -477,47 +474,6 @@ BOOL WINAPI WinHttpAddRequestHeaders( HINTERNET hrequest, LPCWSTR headers, DWORD return ret; } -static WCHAR *build_request_path( request_t *request ) -{ - WCHAR *ret; - - if (strcmpiW( request->connect->hostname, request->connect->servername )) - { - static const WCHAR http[] = { 'h','t','t','p',0 }; - static const WCHAR https[] = { 'h','t','t','p','s',0 }; - static const WCHAR fmt[] = { '%','s',':','/','/','%','s',0 }; - LPCWSTR scheme = request->netconn.secure ? https : http; - int len; - - len = strlenW( scheme ) + strlenW( request->connect->hostname ); - /* 3 characters for '://', 1 for NUL. */ - len += 4; - if (request->connect->hostport) - { - /* 1 for ':' between host and port, up to 5 for port */ - len += 6; - } - if (request->path) - len += strlenW( request->path ); - if ((ret = heap_alloc( len * sizeof(WCHAR) ))) - { - sprintfW( ret, fmt, scheme, request->connect->hostname ); - if (request->connect->hostport) - { - static const WCHAR colonFmt[] = { ':','%','d',0 }; - - sprintfW( ret + strlenW( ret ), colonFmt, - request->connect->hostport ); - } - if (request->path) - strcatW( ret, request->path ); - } - } - else - ret = request->path; - return ret; -} - static WCHAR *build_request_string( request_t *request ) { static const WCHAR space[] = {' ',0}; @@ -525,7 +481,7 @@ static WCHAR *build_request_string( request_t *request ) static const WCHAR colon[] = {':',' ',0}; static const WCHAR twocrlf[] = {'\r','\n','\r','\n',0}; - WCHAR *path, *ret; + WCHAR *ret; const WCHAR **headers, **p; unsigned int len, i = 0, j; @@ -533,10 +489,9 @@ static WCHAR *build_request_string( request_t *request ) len = request->num_headers * 4 + 7; if (!(headers = heap_alloc( len * sizeof(LPCWSTR) ))) return NULL; - path = build_request_path( request ); headers[i++] = request->verb; headers[i++] = space; - headers[i++] = path; + headers[i++] = request->path; headers[i++] = space; headers[i++] = request->version; @@ -561,13 +516,13 @@ static WCHAR *build_request_string( request_t *request ) len++; if (!(ret = heap_alloc( len * sizeof(WCHAR) ))) - goto out; + { + heap_free( headers ); + return NULL; + } *ret = 0; for (p = headers; *p; p++) strcatW( ret, *p ); -out: - if (path != request->path) - heap_free( path ); heap_free( headers ); return ret; } @@ -755,199 +710,46 @@ BOOL WINAPI WinHttpQueryHeaders( HINTERNET hrequest, DWORD level, LPCWSTR name, return ret; } -static LPWSTR concatenate_string_list( LPCWSTR *list, int len ) -{ - LPCWSTR *t; - LPWSTR str; - - for( t = list; *t ; t++ ) - len += strlenW( *t ); - len++; - - str = heap_alloc( len * sizeof(WCHAR) ); - if (!str) return NULL; - *str = 0; - - for( t = list; *t ; t++ ) - strcatW( str, *t ); - - return str; -} - -static LPWSTR build_header_request_string( request_t *request, LPCWSTR verb, - LPCWSTR path, LPCWSTR version ) -{ - static const WCHAR crlf[] = {'\r','\n',0}; - static const WCHAR space[] = { ' ',0 }; - static const WCHAR colon[] = { ':',' ',0 }; - static const WCHAR twocrlf[] = {'\r','\n','\r','\n', 0}; - LPWSTR requestString; - DWORD len, n; - LPCWSTR *req; - UINT i; - LPWSTR p; - - /* allocate space for an array of all the string pointers to be added */ - len = (request->num_headers) * 4 + 10; - req = heap_alloc( len * sizeof(LPCWSTR) ); - if (!req) return NULL; - - /* add the verb, path and HTTP version string */ - n = 0; - req[n++] = verb; - req[n++] = space; - req[n++] = path; - req[n++] = space; - req[n++] = version; - - /* Append custom request headers */ - for (i = 0; i < request->num_headers; i++) - { - if (request->headers[i].is_request) - { - req[n++] = crlf; - req[n++] = request->headers[i].field; - req[n++] = colon; - req[n++] = request->headers[i].value; - - TRACE("Adding custom header %s (%s)\n", - debugstr_w(request->headers[i].field), - debugstr_w(request->headers[i].value)); - } - } - - if( n >= len ) - ERR("oops. buffer overrun\n"); - - req[n] = NULL; - requestString = concatenate_string_list( req, 4 ); - heap_free( req ); - if (!requestString) return NULL; - - /* - * Set (header) termination string for request - * Make sure there's exactly two new lines at the end of the request - */ - p = &requestString[strlenW(requestString)-1]; - while ( (*p == '\n') || (*p == '\r') ) - p--; - strcpyW( p+1, twocrlf ); - - return requestString; -} - -static BOOL read_reply( request_t *request ); - -static BOOL secure_proxy_connect( request_t *request ) -{ - static const WCHAR verbConnect[] = {'C','O','N','N','E','C','T',0}; - static const WCHAR fmt[] = {'%','s',':','%','d',0}; - static const WCHAR http1_1[] = {'H','T','T','P','/','1','.','1',0}; - BOOL ret = FALSE; - LPWSTR path; - connect_t *connect = request->connect; - - path = heap_alloc( (strlenW( connect->hostname ) + 13) * sizeof(WCHAR) ); - if (path) - { - LPWSTR requestString; - - sprintfW( path, fmt, connect->hostname, connect->hostport ); - requestString = build_header_request_string( request, verbConnect, - path, http1_1 ); - heap_free( path ); - if (requestString) - { - LPSTR req_ascii = strdupWA( requestString ); - - heap_free( requestString ); - if (req_ascii) - { - int len = strlen( req_ascii ), bytes_sent; - - ret = netconn_send( &request->netconn, req_ascii, len, 0, &bytes_sent ); - heap_free( req_ascii ); - if (ret) - ret = read_reply( request ); - } - } - } - return ret; -} - -#ifndef INET6_ADDRSTRLEN -#define INET6_ADDRSTRLEN 46 -#endif - static BOOL open_connection( request_t *request ) { connect_t *connect; - const void *addr; - char address[INET6_ADDRSTRLEN]; + char address[32]; WCHAR *addressW; INTERNET_PORT port; - socklen_t slen; if (netconn_connected( &request->netconn )) return TRUE; connect = request->connect; - port = connect->serverport ? connect->serverport : (request->hdr.flags & WINHTTP_FLAG_SECURE ? 443 : 80); + port = connect->hostport ? connect->hostport : (request->hdr.flags & WINHTTP_FLAG_SECURE ? 443 : 80); send_callback( &request->hdr, WINHTTP_CALLBACK_STATUS_RESOLVING_NAME, connect->servername, strlenW(connect->servername) + 1 ); - slen = sizeof(connect->sockaddr); - if (!netconn_resolve( connect->servername, port, (struct sockaddr *)&connect->sockaddr, &slen )) return FALSE; - switch (connect->sockaddr.ss_family) - { - case AF_INET: - addr = &((struct sockaddr_in *)&connect->sockaddr)->sin_addr; - break; - case AF_INET6: - addr = &((struct sockaddr_in6 *)&connect->sockaddr)->sin6_addr; - break; - default: - WARN("unsupported address family %d\n", connect->sockaddr.ss_family); - return FALSE; - } - inet_ntop( connect->sockaddr.ss_family, addr, address, sizeof(address) ); + if (!netconn_resolve( connect->servername, port, &connect->sockaddr )) return FALSE; + inet_ntop( connect->sockaddr.sin_family, &connect->sockaddr.sin_addr, address, sizeof(address) ); addressW = strdupAW( address ); send_callback( &request->hdr, WINHTTP_CALLBACK_STATUS_NAME_RESOLVED, addressW, strlenW(addressW) + 1 ); - TRACE("connecting to %s:%u\n", address, port); + TRACE("connecting to %s:%u\n", address, ntohs(connect->sockaddr.sin_port)); send_callback( &request->hdr, WINHTTP_CALLBACK_STATUS_CONNECTING_TO_SERVER, addressW, 0 ); - if (!netconn_create( &request->netconn, connect->sockaddr.ss_family, SOCK_STREAM, 0 )) + if (!netconn_create( &request->netconn, connect->sockaddr.sin_family, SOCK_STREAM, 0 )) { heap_free( addressW ); return FALSE; } - netconn_set_timeout( &request->netconn, TRUE, request->send_timeout ); - netconn_set_timeout( &request->netconn, FALSE, request->recv_timeout ); - if (!netconn_connect( &request->netconn, (struct sockaddr *)&connect->sockaddr, slen, request->connect_timeout )) + if (!netconn_connect( &request->netconn, (struct sockaddr *)&connect->sockaddr, sizeof(struct sockaddr_in) )) { netconn_close( &request->netconn ); heap_free( addressW ); return FALSE; } - if (request->hdr.flags & WINHTTP_FLAG_SECURE) + if (request->hdr.flags & WINHTTP_FLAG_SECURE && !netconn_secure_connect( &request->netconn )) { - if (connect->session->proxy_server && - strcmpiW( connect->hostname, connect->servername )) - { - if (!secure_proxy_connect( request )) - { - heap_free( addressW ); - return FALSE; - } - } - if (!netconn_secure_connect( &request->netconn )) - { - netconn_close( &request->netconn ); - heap_free( addressW ); - return FALSE; - } + netconn_close( &request->netconn ); + heap_free( addressW ); + return FALSE; } send_callback( &request->hdr, WINHTTP_CALLBACK_STATUS_CONNECTED_TO_SERVER, addressW, strlenW(addressW) + 1 ); @@ -1295,12 +1097,13 @@ static BOOL handle_redirect( request_t *request ) hostname[len] = 0; port = uc.nPort ? uc.nPort : (uc.nScheme == INTERNET_SCHEME_HTTPS ? 443 : 80); - if (strcmpiW( connect->hostname, hostname ) || connect->serverport != port) + if (strcmpiW( connect->servername, hostname ) || connect->serverport != port) { heap_free( connect->hostname ); connect->hostname = hostname; - connect->hostport = port; - if (!(ret = set_server_for_hostname( connect, hostname, port ))) goto end; + heap_free( connect->servername ); + connect->servername = strdupW( connect->hostname ); + connect->serverport = connect->hostport = port; netconn_close( &request->netconn ); if (!(ret = netconn_init( &request->netconn, request->hdr.flags & WINHTTP_FLAG_SECURE ))) goto end; diff --git a/dlls/winhttp/session.c b/dlls/winhttp/session.c index 7bc61a97552..11c4b4fbf99 100644 --- a/dlls/winhttp/session.c +++ b/dlls/winhttp/session.c @@ -21,22 +21,16 @@ #include "wine/debug.h" #include -#include #include "windef.h" #include "winbase.h" #include "winhttp.h" #include "wincrypt.h" -#include "winreg.h" #include "winhttp_private.h" WINE_DEFAULT_DEBUG_CHANNEL(winhttp); -#define DEFAULT_CONNECT_TIMEOUT 60000 -#define DEFAULT_SEND_TIMEOUT 30000 -#define DEFAULT_RECEIVE_TIMEOUT 30000 - void set_last_error( DWORD error ) { /* FIXME */ @@ -172,35 +166,13 @@ HINTERNET WINAPI WinHttpOpen( LPCWSTR agent, DWORD access, LPCWSTR proxy, LPCWST session->hdr.vtbl = &session_vtbl; session->hdr.flags = flags; session->hdr.refs = 1; + session->access = access; session->hdr.redirect_policy = WINHTTP_OPTION_REDIRECT_POLICY_DISALLOW_HTTPS_TO_HTTP; list_init( &session->cookie_cache ); if (agent && !(session->agent = strdupW( agent ))) goto end; - if (access == WINHTTP_ACCESS_TYPE_DEFAULT_PROXY) - { - WINHTTP_PROXY_INFO info; - - WinHttpGetDefaultProxyConfiguration( &info ); - session->access = info.dwAccessType; - if (info.lpszProxy && !(session->proxy_server = strdupW( info.lpszProxy ))) - { - GlobalFree( (LPWSTR)info.lpszProxy ); - GlobalFree( (LPWSTR)info.lpszProxyBypass ); - goto end; - } - if (info.lpszProxyBypass && !(session->proxy_bypass = strdupW( info.lpszProxyBypass ))) - { - GlobalFree( (LPWSTR)info.lpszProxy ); - GlobalFree( (LPWSTR)info.lpszProxyBypass ); - goto end; - } - } - else if (access == WINHTTP_ACCESS_TYPE_NAMED_PROXY) - { - session->access = access; - if (proxy && !(session->proxy_server = strdupW( proxy ))) goto end; - if (bypass && !(session->proxy_bypass = strdupW( bypass ))) goto end; - } + if (proxy && !(session->proxy_server = strdupW( proxy ))) goto end; + if (bypass && !(session->proxy_bypass = strdupW( bypass ))) goto end; if (!(handle = alloc_handle( &session->hdr ))) goto end; session->hdr.handle = handle; @@ -236,149 +208,6 @@ static const object_vtbl_t connect_vtbl = NULL }; -static BOOL domain_matches(LPCWSTR server, LPCWSTR domain) -{ - static const WCHAR localW[] = { '<','l','o','c','a','l','>',0 }; - BOOL ret = FALSE; - - if (!strcmpiW( domain, localW ) && !strchrW( server, '.' )) - ret = TRUE; - else if (*domain == '*') - { - if (domain[1] == '.') - { - LPCWSTR dot; - - /* For a hostname to match a wildcard, the last domain must match - * the wildcard exactly. E.g. if the wildcard is *.a.b, and the - * hostname is www.foo.a.b, it matches, but a.b does not. - */ - dot = strchrW( server, '.' ); - if (dot) - { - int len = strlenW( dot + 1 ); - - if (len > strlenW( domain + 2 )) - { - LPCWSTR ptr; - - /* The server's domain is longer than the wildcard, so it - * could be a subdomain. Compare the last portion of the - * server's domain. - */ - ptr = dot + len + 1 - strlenW( domain + 2 ); - if (!strcmpiW( ptr, domain + 2 )) - { - /* This is only a match if the preceding character is - * a '.', i.e. that it is a matching domain. E.g. - * if domain is '*.b.c' and server is 'www.ab.c' they - * do not match. - */ - ret = *(ptr - 1) == '.'; - } - } - else - ret = !strcmpiW( dot + 1, domain + 2 ); - } - } - } - else - ret = !strcmpiW( server, domain ); - return ret; -} - -/* Matches INTERNET_MAX_HOST_NAME_LENGTH in wininet.h, also RFC 1035 */ -#define MAX_HOST_NAME_LENGTH 256 - -static BOOL should_bypass_proxy(session_t *session, LPCWSTR server) -{ - LPCWSTR ptr; - BOOL ret = FALSE; - - if (!session->proxy_bypass) return FALSE; - ptr = session->proxy_bypass; - do { - LPCWSTR tmp = ptr; - - ptr = strchrW( ptr, ';' ); - if (!ptr) - ptr = strchrW( tmp, ' ' ); - if (ptr) - { - if (ptr - tmp < MAX_HOST_NAME_LENGTH) - { - WCHAR domain[MAX_HOST_NAME_LENGTH]; - - memcpy( domain, tmp, (ptr - tmp) * sizeof(WCHAR) ); - domain[ptr - tmp] = 0; - ret = domain_matches( server, domain ); - } - ptr += 1; - } - else if (*tmp) - ret = domain_matches( server, tmp ); - } while (ptr && !ret); - return ret; -} - -BOOL set_server_for_hostname( connect_t *connect, LPCWSTR server, INTERNET_PORT port ) -{ - session_t *session = connect->session; - BOOL ret = TRUE; - - if (session->proxy_server && !should_bypass_proxy(session, server)) - { - LPCWSTR colon; - - if ((colon = strchrW( session->proxy_server, ':' ))) - { - if (!connect->servername || strncmpiW( connect->servername, - session->proxy_server, colon - session->proxy_server - 1 )) - { - heap_free( connect->servername ); - if (!(connect->servername = heap_alloc( - (colon - session->proxy_server + 1) * sizeof(WCHAR) ))) - { - ret = FALSE; - goto end; - } - memcpy( connect->servername, session->proxy_server, - (colon - session->proxy_server) * sizeof(WCHAR) ); - connect->servername[colon - session->proxy_server] = 0; - if (*(colon + 1)) - connect->serverport = atoiW( colon + 1 ); - else - connect->serverport = INTERNET_DEFAULT_PORT; - } - } - else - { - if (!connect->servername || strcmpiW( connect->servername, - session->proxy_server )) - { - heap_free( connect->servername ); - if (!(connect->servername = strdupW( session->proxy_server ))) - { - ret = FALSE; - goto end; - } - connect->serverport = INTERNET_DEFAULT_PORT; - } - } - } - else if (server) - { - if (!(connect->servername = strdupW( server ))) - { - ret = FALSE; - goto end; - } - connect->serverport = port; - } -end: - return ret; -} - /*********************************************************************** * WinHttpConnect (winhttp.@) */ @@ -426,8 +255,8 @@ HINTERNET WINAPI WinHttpConnect( HINTERNET hsession, LPCWSTR server, INTERNET_PO if (server && !(connect->hostname = strdupW( server ))) goto end; connect->hostport = port; - if (!set_server_for_hostname( connect, server, port )) - goto end; + if (server && !(connect->servername = strdupW( server ))) goto end; + connect->serverport = port; if (!(hconnect = alloc_handle( &connect->hdr ))) goto end; connect->hdr.handle = hconnect; @@ -637,9 +466,6 @@ HINTERNET WINAPI WinHttpOpenRequest( HINTERNET hconnect, LPCWSTR verb, LPCWSTR o list_add_head( &connect->hdr.children, &request->hdr.entry ); if (!netconn_init( &request->netconn, request->hdr.flags & WINHTTP_FLAG_SECURE )) goto end; - request->connect_timeout = DEFAULT_CONNECT_TIMEOUT; - request->send_timeout = DEFAULT_SEND_TIMEOUT; - request->recv_timeout = DEFAULT_RECEIVE_TIMEOUT; if (!verb || !verb[0]) verb = getW; if (!(request->verb = strdupW( verb ))) goto end; @@ -822,167 +648,17 @@ BOOL WINAPI WinHttpDetectAutoProxyConfigUrl( DWORD flags, LPWSTR *url ) return FALSE; } -static const WCHAR Connections[] = { - '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','\\', - 'I','n','t','e','r','n','e','t',' ','S','e','t','t','i','n','g','s','\\', - 'C','o','n','n','e','c','t','i','o','n','s',0 }; -static const WCHAR WinHttpSettings[] = { - 'W','i','n','H','t','t','p','S','e','t','t','i','n','g','s',0 }; -static const DWORD WINHTTPSETTINGS_MAGIC = 0x18; -static const DWORD WINHTTP_PROXY_TYPE_DIRECT = 1; -static const DWORD WINHTTP_PROXY_TYPE_PROXY = 2; - -struct winhttp_settings_header -{ - DWORD magic; - DWORD unknown; /* always zero? */ - DWORD flags; /* one of WINHTTP_PROXY_TYPE_* */ -}; - -static inline void copy_char_to_wchar_sz(const BYTE *src, DWORD len, WCHAR *dst) -{ - const BYTE *begin; - - for (begin = src; src - begin < len; src++, dst++) - *dst = *src; - *dst = 0; -} - /*********************************************************************** * WinHttpGetDefaultProxyConfiguration (winhttp.@) */ BOOL WINAPI WinHttpGetDefaultProxyConfiguration( WINHTTP_PROXY_INFO *info ) { - LONG l; - HKEY key; - BOOL got_from_reg = FALSE, direct = TRUE; - char *envproxy; - - TRACE("%p\n", info); + FIXME("%p\n", info); - l = RegOpenKeyExW( HKEY_LOCAL_MACHINE, Connections, 0, KEY_READ, &key ); - if (!l) - { - DWORD type, size = 0; - - l = RegQueryValueExW( key, WinHttpSettings, NULL, &type, NULL, &size ); - if (!l && type == REG_BINARY && - size >= sizeof(struct winhttp_settings_header) + 2 * sizeof(DWORD)) - { - BYTE *buf = heap_alloc( size ); - - if (buf) - { - struct winhttp_settings_header *hdr = - (struct winhttp_settings_header *)buf; - DWORD *len = (DWORD *)(hdr + 1); - - l = RegQueryValueExW( key, WinHttpSettings, NULL, NULL, buf, - &size ); - if (!l && hdr->magic == WINHTTPSETTINGS_MAGIC && - hdr->unknown == 0) - { - if (hdr->flags & WINHTTP_PROXY_TYPE_PROXY) - { - BOOL sane = FALSE; - LPWSTR proxy = NULL; - LPWSTR proxy_bypass = NULL; - - /* Sanity-check length of proxy string */ - if ((BYTE *)len - buf + *len <= size) - { - sane = TRUE; - proxy = GlobalAlloc( 0, (*len + 1) * sizeof(WCHAR) ); - if (proxy) - copy_char_to_wchar_sz( (BYTE *)(len + 1), *len, proxy ); - len = (DWORD *)((BYTE *)(len + 1) + *len); - } - if (sane) - { - /* Sanity-check length of proxy bypass string */ - if ((BYTE *)len - buf + *len <= size) - { - proxy_bypass = GlobalAlloc( 0, (*len + 1) * sizeof(WCHAR) ); - if (proxy_bypass) - copy_char_to_wchar_sz( (BYTE *)(len + 1), *len, proxy_bypass ); - } - else - { - sane = FALSE; - GlobalFree( proxy ); - proxy = NULL; - } - } - info->lpszProxy = proxy; - info->lpszProxyBypass = proxy_bypass; - if (sane) - { - got_from_reg = TRUE; - direct = FALSE; - info->dwAccessType = - WINHTTP_ACCESS_TYPE_NAMED_PROXY; - TRACE("http proxy (from registry) = %s, bypass = %s\n", - debugstr_w(info->lpszProxy), - debugstr_w(info->lpszProxyBypass)); - } - } - } - heap_free( buf ); - } - } - RegCloseKey( key ); - } - if (!got_from_reg && (envproxy = getenv( "http_proxy" ))) - { - char *colon, *http_proxy; + info->dwAccessType = WINHTTP_ACCESS_TYPE_NO_PROXY; + info->lpszProxy = NULL; + info->lpszProxyBypass = NULL; - if ((colon = strchr( envproxy, ':' ))) - { - if (*(colon + 1) == '/' && *(colon + 2) == '/') - { - static const char http[] = "http://"; - - /* It's a scheme, check that it's http */ - if (!strncmp( envproxy, http, strlen( http ) )) - http_proxy = envproxy + strlen( http ); - else - { - WARN("unsupported scheme in $http_proxy: %s\n", envproxy); - http_proxy = NULL; - } - } - else - http_proxy = envproxy; - } - else - http_proxy = envproxy; - if (http_proxy) - { - WCHAR *http_proxyW; - int len; - - len = MultiByteToWideChar( CP_UNIXCP, 0, http_proxy, -1, NULL, 0 ); - if ((http_proxyW = GlobalAlloc( 0, len * sizeof(WCHAR)))) - { - MultiByteToWideChar( CP_UNIXCP, 0, http_proxy, -1, http_proxyW, len ); - direct = FALSE; - info->dwAccessType = WINHTTP_ACCESS_TYPE_NAMED_PROXY; - info->lpszProxy = http_proxyW; - info->lpszProxyBypass = NULL; - TRACE("http proxy (from environment) = %s\n", - debugstr_w(info->lpszProxy)); - } - } - } - if (direct) - { - info->dwAccessType = WINHTTP_ACCESS_TYPE_NO_PROXY; - info->lpszProxy = NULL; - info->lpszProxyBypass = NULL; - } return TRUE; } @@ -1027,106 +703,9 @@ BOOL WINAPI WinHttpGetProxyForUrl( HINTERNET hsession, LPCWSTR url, WINHTTP_AUTO */ BOOL WINAPI WinHttpSetDefaultProxyConfiguration( WINHTTP_PROXY_INFO *info ) { - LONG l; - HKEY key; - BOOL ret = FALSE; - const WCHAR *src; - - TRACE("%p\n", info); - - if (!info) - { - set_last_error( ERROR_INVALID_PARAMETER ); - return FALSE; - } - switch (info->dwAccessType) - { - case WINHTTP_ACCESS_TYPE_NO_PROXY: - break; - case WINHTTP_ACCESS_TYPE_NAMED_PROXY: - if (!info->lpszProxy) - { - set_last_error( ERROR_INVALID_PARAMETER ); - return FALSE; - } - /* Only ASCII characters are allowed */ - for (src = info->lpszProxy; *src; src++) - if (*src > 0x7f) - { - set_last_error( ERROR_INVALID_PARAMETER ); - return FALSE; - } - if (info->lpszProxyBypass) - { - for (src = info->lpszProxyBypass; *src; src++) - if (*src > 0x7f) - { - set_last_error( ERROR_INVALID_PARAMETER ); - return FALSE; - } - } - break; - default: - set_last_error( ERROR_INVALID_PARAMETER ); - return FALSE; - } - - l = RegCreateKeyExW( HKEY_LOCAL_MACHINE, Connections, 0, NULL, 0, - KEY_WRITE, NULL, &key, NULL ); - if (!l) - { - DWORD size = sizeof(struct winhttp_settings_header) + 2 * sizeof(DWORD); - BYTE *buf; - - if (info->dwAccessType == WINHTTP_ACCESS_TYPE_NAMED_PROXY) - { - size += strlenW( info->lpszProxy ); - if (info->lpszProxyBypass) - size += strlenW( info->lpszProxyBypass ); - } - buf = heap_alloc( size ); - if (buf) - { - struct winhttp_settings_header *hdr = - (struct winhttp_settings_header *)buf; - DWORD *len = (DWORD *)(hdr + 1); - - hdr->magic = WINHTTPSETTINGS_MAGIC; - hdr->unknown = 0; - if (info->dwAccessType == WINHTTP_ACCESS_TYPE_NAMED_PROXY) - { - BYTE *dst; - - hdr->flags = WINHTTP_PROXY_TYPE_PROXY; - *len++ = strlenW( info->lpszProxy ); - for (dst = (BYTE *)len, src = info->lpszProxy; *src; - src++, dst++) - *dst = *src; - len = (DWORD *)dst; - if (info->lpszProxyBypass) - { - *len++ = strlenW( info->lpszProxyBypass ); - for (dst = (BYTE *)len, src = info->lpszProxyBypass; *src; - src++, dst++) - *dst = *src; - } - else - *len++ = 0; - } - else - { - hdr->flags = WINHTTP_PROXY_TYPE_DIRECT; - *len++ = 0; - *len++ = 0; - } - l = RegSetValueExW( key, WinHttpSettings, 0, REG_BINARY, buf, size ); - if (!l) - ret = TRUE; - heap_free( buf ); - } - RegCloseKey( key ); - } - return ret; + FIXME("%p [%u, %s, %s]\n", info, info->dwAccessType, debugstr_w(info->lpszProxy), + debugstr_w(info->lpszProxyBypass)); + return TRUE; } /*********************************************************************** @@ -1158,49 +737,8 @@ WINHTTP_STATUS_CALLBACK WINAPI WinHttpSetStatusCallback( HINTERNET handle, WINHT */ BOOL WINAPI WinHttpSetTimeouts( HINTERNET handle, int resolve, int connect, int send, int receive ) { - BOOL ret = TRUE; - request_t *request; - - TRACE("%p, %d, %d, %d, %d\n", handle, resolve, connect, send, receive); - - if (resolve < -1 || connect < -1 || send < -1 || receive < -1) - { - set_last_error( ERROR_INVALID_PARAMETER ); - return FALSE; - } - - if (resolve > 0) - FIXME("resolve timeout (%d) not supported\n", resolve); - - if (!(request = (request_t *)grab_object( handle ))) - { - set_last_error( ERROR_INVALID_HANDLE ); - return FALSE; - } - - if (request->hdr.type != WINHTTP_HANDLE_TYPE_REQUEST) - { - release_object( &request->hdr ); - set_last_error( ERROR_WINHTTP_INCORRECT_HANDLE_TYPE ); - return FALSE; - } - - request->connect_timeout = connect; - - if (send < 0) send = 0; - request->send_timeout = send; - - if (receive < 0) receive = 0; - request->recv_timeout = receive; - - if (netconn_connected( &request->netconn )) - { - if (netconn_set_timeout( &request->netconn, TRUE, send )) ret = FALSE; - if (netconn_set_timeout( &request->netconn, FALSE, receive )) ret = FALSE; - } - - release_object( &request->hdr ); - return ret; + FIXME("%p, %d, %d, %d, %d\n", handle, resolve, connect, send, receive); + return TRUE; } static const WCHAR wkday[7][4] = diff --git a/dlls/winhttp/tests/Makefile.in b/dlls/winhttp/tests/Makefile.in index 670ee1abdd8..561efac8a1d 100644 --- a/dlls/winhttp/tests/Makefile.in +++ b/dlls/winhttp/tests/Makefile.in @@ -3,7 +3,7 @@ TOPOBJDIR = ../../.. SRCDIR = @srcdir@ VPATH = @srcdir@ TESTDLL = winhttp.dll -IMPORTS = winhttp advapi32 kernel32 +IMPORTS = winhttp kernel32 CTESTS = \ notification.c \ diff --git a/dlls/winhttp/tests/winhttp.c b/dlls/winhttp/tests/winhttp.c index 67ac5042009..74e1c9a12ec 100644 --- a/dlls/winhttp/tests/winhttp.c +++ b/dlls/winhttp/tests/winhttp.c @@ -24,7 +24,6 @@ #include #include #include -#include #include "wine/test.h" @@ -343,8 +342,6 @@ static void test_WinHttpAddHeaders(void) static const WCHAR test_header_begin[] = {'P','O','S','T',' ','/','p','o','s','t','t','e','s','t','.','p','h','p',' ','H','T','T','P','/','1'}; - static const WCHAR full_path_test_header_begin[] = - {'P','O','S','T',' ','h','t','t','p',':','/','/','c','r','o','s','s','o','v','e','r','.','c','o','d','e','w','e','a','v','e','r','s','.','c','o','m',':','8','0','/','p','o','s','t','t','e','s','t','.','p','h','p',' ','H','T','T','P','/','1'}; static const WCHAR test_header_end[] = {'\r','\n','\r','\n',0}; static const WCHAR test_header_name[] = {'W','a','r','n','i','n','g',0}; @@ -478,8 +475,7 @@ static void test_WinHttpAddHeaders(void) ok(len + sizeof(WCHAR) <= oldlen, "WinHttpQueryHeaders resulting length longer than advertized.\n"); ok((len < sizeof(buffer) - sizeof(WCHAR)) && buffer[len / sizeof(WCHAR)] == 0, "WinHttpQueryHeaders did not append NULL terminator\n"); ok(len == lstrlenW(buffer) * sizeof(WCHAR), "WinHttpQueryHeaders returned incorrect length.\n"); - ok(memcmp(buffer, test_header_begin, sizeof(test_header_begin)) == 0 || - memcmp(buffer, full_path_test_header_begin, sizeof(full_path_test_header_begin)) == 0, + ok(memcmp(buffer, test_header_begin, sizeof(test_header_begin)) == 0, "WinHttpQueryHeaders returned invalid beginning of header string.\n"); ok(memcmp(buffer + lstrlenW(buffer) - 4, test_header_end, sizeof(test_header_end)) == 0, "WinHttpQueryHeaders returned invalid end of header string.\n"); @@ -506,9 +502,7 @@ static void test_WinHttpAddHeaders(void) ok(len + sizeof(WCHAR) <= oldlen, "resulting length longer than advertized\n"); ok((len < sizeof(buffer) - sizeof(WCHAR)) && !buffer[len / sizeof(WCHAR)] && !buffer[len / sizeof(WCHAR) - 1], "no double NULL terminator\n"); - ok(memcmp(buffer, test_header_begin, sizeof(test_header_begin)) == 0 || - memcmp(buffer, full_path_test_header_begin, sizeof(full_path_test_header_begin)) == 0, - "invalid beginning of header string.\n"); + ok(!memcmp(buffer, test_header_begin, sizeof(test_header_begin)), "invalid beginning of header string\n"); ok(index == 0, "header index was incremented\n"); /* tests for more indices */ @@ -823,137 +817,6 @@ static void test_request_parameter_defaults(void) WinHttpCloseHandle(ses); } -static const WCHAR Connections[] = { - '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','\\', - 'I','n','t','e','r','n','e','t',' ','S','e','t','t','i','n','g','s','\\', - 'C','o','n','n','e','c','t','i','o','n','s',0 }; -static const WCHAR WinHttpSettings[] = { - 'W','i','n','H','t','t','p','S','e','t','t','i','n','g','s',0 }; - -static DWORD get_default_proxy_reg_value( BYTE *buf, DWORD len, DWORD *type ) -{ - LONG l; - HKEY key; - DWORD ret = 0; - - l = RegOpenKeyExW( HKEY_LOCAL_MACHINE, Connections, 0, KEY_READ, &key ); - if (!l) - { - DWORD size = 0; - - l = RegQueryValueExW( key, WinHttpSettings, NULL, type, NULL, &size ); - if (!l) - { - if (size <= len) - l = RegQueryValueExW( key, WinHttpSettings, NULL, type, buf, - &size ); - if (!l) - ret = size; - } - RegCloseKey( key ); - } - return ret; -} - -static void set_default_proxy_reg_value( BYTE *buf, DWORD len, DWORD type ) -{ - LONG l; - HKEY key; - - l = RegCreateKeyExW( HKEY_LOCAL_MACHINE, Connections, 0, NULL, 0, - KEY_WRITE, NULL, &key, NULL ); - if (!l) - { - if (len) - RegSetValueExW( key, WinHttpSettings, 0, type, buf, len ); - else - RegDeleteValueW( key, WinHttpSettings ); - RegCloseKey( key ); - } -} - -static void test_set_default_proxy_config(void) -{ - static const WCHAR wideString[] = { 0x226f, 0x575b, 0 }; - static const WCHAR normalString[] = { 'f','o','o',0 }; - DWORD type, len; - BYTE *saved_proxy_settings = NULL; - WINHTTP_PROXY_INFO info; - BOOL ret; - - /* FIXME: it would be simpler to read the current settings using - * WinHttpGetDefaultProxyConfiguration and save them using - * WinHttpSetDefaultProxyConfiguration, but they appear to have a bug. - * - * If a proxy is configured in the registry, e.g. via 'proxcfg -p "foo"', - * the access type reported by WinHttpGetDefaultProxyConfiguration is 1, - * WINHTTP_ACCESS_TYPE_NO_PROXY, whereas it should be - * WINHTTP_ACCESS_TYPE_NAMED_PROXY. - * If WinHttpSetDefaultProxyConfiguration is called with dwAccessType = 1, - * the lpszProxy and lpszProxyBypass values are ignored. - * Thus, if a proxy is set with proxycfg, then calling - * WinHttpGetDefaultProxyConfiguration followed by - * WinHttpSetDefaultProxyConfiguration results in the proxy settings - * getting deleted from the registry. - * - * Instead I read the current registry value and restore it directly. - */ - len = get_default_proxy_reg_value( NULL, 0, &type ); - if (len) - { - saved_proxy_settings = HeapAlloc( GetProcessHeap(), 0, len ); - len = get_default_proxy_reg_value( saved_proxy_settings, len, &type ); - } - - if (0) - { - /* Crashes on Vista and higher */ - SetLastError(0xdeadbeef); - ret = WinHttpSetDefaultProxyConfiguration(NULL); - ok(!ret && GetLastError() == ERROR_INVALID_PARAMETER, - "expected ERROR_INVALID_PARAMETER, got %d\n", GetLastError()); - } - - /* test with invalid access type */ - info.dwAccessType = 0xdeadbeef; - info.lpszProxy = info.lpszProxyBypass = NULL; - SetLastError(0xdeadbeef); - ret = WinHttpSetDefaultProxyConfiguration(&info); - ok(!ret && GetLastError() == ERROR_INVALID_PARAMETER, - "expected ERROR_INVALID_PARAMETER, got %d\n", GetLastError()); - - /* at a minimum, the proxy server must be set */ - info.dwAccessType = WINHTTP_ACCESS_TYPE_NAMED_PROXY; - info.lpszProxy = info.lpszProxyBypass = NULL; - SetLastError(0xdeadbeef); - ret = WinHttpSetDefaultProxyConfiguration(&info); - ok(!ret && GetLastError() == ERROR_INVALID_PARAMETER, - "expected ERROR_INVALID_PARAMETER, got %d\n", GetLastError()); - info.lpszProxyBypass = normalString; - SetLastError(0xdeadbeef); - ret = WinHttpSetDefaultProxyConfiguration(&info); - ok(!ret && GetLastError() == ERROR_INVALID_PARAMETER, - "expected ERROR_INVALID_PARAMETER, got %d\n", GetLastError()); - - /* the proxy server can't have wide characters */ - info.lpszProxy = wideString; - SetLastError(0xdeadbeef); - ret = WinHttpSetDefaultProxyConfiguration(&info); - ok((!ret && GetLastError() == ERROR_INVALID_PARAMETER) || - broken(ret), /* Earlier winhttp versions on W2K/XP */ - "expected ERROR_INVALID_PARAMETER, got %d\n", GetLastError()); - - info.lpszProxy = normalString; - SetLastError(0xdeadbeef); - ret = WinHttpSetDefaultProxyConfiguration(&info); - ok(ret, "WinHttpSetDefaultProxyConfiguration failed: %d\n", GetLastError()); - - set_default_proxy_reg_value( saved_proxy_settings, len, type ); -} - START_TEST (winhttp) { test_OpenRequest(); @@ -964,5 +827,4 @@ START_TEST (winhttp) test_secure_connection(); test_request_parameter_defaults(); test_QueryOption(); - test_set_default_proxy_config(); } diff --git a/dlls/winhttp/winhttp_private.h b/dlls/winhttp/winhttp_private.h index 83df0c0643e..511e124c5a3 100644 --- a/dlls/winhttp/winhttp_private.h +++ b/dlls/winhttp/winhttp_private.h @@ -110,7 +110,7 @@ typedef struct LPWSTR password; INTERNET_PORT hostport; INTERNET_PORT serverport; - struct sockaddr_storage sockaddr; + struct sockaddr_in sockaddr; } connect_t; typedef struct @@ -139,9 +139,6 @@ typedef struct LPWSTR version; LPWSTR raw_headers; netconn_t netconn; - int connect_timeout; - int send_timeout; - int recv_timeout; LPWSTR status_text; DWORD content_length; /* total number of bytes to be read (per chunk) */ DWORD content_read; /* bytes read so far */ @@ -207,24 +204,22 @@ void send_callback( object_header_t *, DWORD, LPVOID, DWORD ); void close_connection( request_t * ); BOOL netconn_close( netconn_t * ); -BOOL netconn_connect( netconn_t *, const struct sockaddr *, unsigned int, int ); +BOOL netconn_connect( netconn_t *, const struct sockaddr *, unsigned int ); BOOL netconn_connected( netconn_t * ); BOOL netconn_create( netconn_t *, int, int, int ); BOOL netconn_get_next_line( netconn_t *, char *, DWORD * ); BOOL netconn_init( netconn_t *, BOOL ); BOOL netconn_query_data_available( netconn_t *, DWORD * ); BOOL netconn_recv( netconn_t *, void *, size_t, int, int * ); -BOOL netconn_resolve( WCHAR *, INTERNET_PORT, struct sockaddr *, socklen_t * ); +BOOL netconn_resolve( WCHAR *, INTERNET_PORT, struct sockaddr_in * ); BOOL netconn_secure_connect( netconn_t * ); BOOL netconn_send( netconn_t *, const void *, size_t, int, int * ); -DWORD netconn_set_timeout( netconn_t *, BOOL, int ); const void *netconn_get_certificate( netconn_t * ); BOOL set_cookies( request_t *, const WCHAR * ); BOOL add_cookie_headers( request_t * ); BOOL add_request_headers( request_t *, LPCWSTR, DWORD, DWORD ); void delete_domain( domain_t * ); -BOOL set_server_for_hostname( connect_t *connect, LPCWSTR server, INTERNET_PORT port ); static inline void *heap_alloc( SIZE_T size ) { diff --git a/dlls/wininet/Makefile.in b/dlls/wininet/Makefile.in index 9872b754c5b..c7cc1e0a8c1 100644 --- a/dlls/wininet/Makefile.in +++ b/dlls/wininet/Makefile.in @@ -22,32 +22,8 @@ C_SRCS = \ wininet_main.c RC_SRCS = \ - version.rc \ - wininet_Bg.rc \ - wininet_Cs.rc \ - wininet_Da.rc \ - wininet_De.rc \ - wininet_En.rc \ - wininet_Eo.rc \ - wininet_Es.rc \ - wininet_Fi.rc \ - wininet_Fr.rc \ - wininet_Hu.rc \ - wininet_It.rc \ - wininet_Ja.rc \ - wininet_Ko.rc \ - wininet_Lt.rc \ - wininet_Nl.rc \ - wininet_No.rc \ - wininet_Pl.rc \ - wininet_Pt.rc \ - wininet_Ro.rc \ - wininet_Ru.rc \ - wininet_Si.rc \ - wininet_Sv.rc \ - wininet_Tr.rc \ - wininet_Uk.rc \ - wininet_Zh.rc + rsrc.rc \ + version.rc @MAKE_DLL_RULES@ diff --git a/dlls/wininet/cookie.c b/dlls/wininet/cookie.c index 30e0b99ee92..dc77b17265b 100644 --- a/dlls/wininet/cookie.c +++ b/dlls/wininet/cookie.c @@ -95,8 +95,17 @@ static cookie *COOKIE_addCookie(cookie_domain *domain, LPCWSTR name, LPCWSTR dat newCookie->lpCookieName = NULL; newCookie->lpCookieData = NULL; newCookie->expiry = expiry; - newCookie->lpCookieName = heap_strdupW(name); - newCookie->lpCookieData = heap_strdupW(data); + + if (name) + { + newCookie->lpCookieName = HeapAlloc(GetProcessHeap(), 0, (strlenW(name) + 1)*sizeof(WCHAR)); + lstrcpyW(newCookie->lpCookieName, name); + } + if (data) + { + newCookie->lpCookieData = HeapAlloc(GetProcessHeap(), 0, (strlenW(data) + 1)*sizeof(WCHAR)); + lstrcpyW(newCookie->lpCookieData, data); + } TRACE("added cookie %p (data is %s)\n", newCookie, debugstr_w(data) ); @@ -151,8 +160,17 @@ static cookie_domain *COOKIE_addDomain(LPCWSTR domain, LPCWSTR path) list_init(&newDomain->cookie_list); newDomain->lpCookieDomain = NULL; newDomain->lpCookiePath = NULL; - newDomain->lpCookieDomain = heap_strdupW(domain); - newDomain->lpCookiePath = heap_strdupW(path); + + if (domain) + { + newDomain->lpCookieDomain = HeapAlloc(GetProcessHeap(), 0, (strlenW(domain) + 1)*sizeof(WCHAR)); + strcpyW(newDomain->lpCookieDomain, domain); + } + if (path) + { + newDomain->lpCookiePath = HeapAlloc(GetProcessHeap(), 0, (strlenW(path) + 1)*sizeof(WCHAR)); + lstrcpyW(newDomain->lpCookiePath, path); + } list_add_tail(&domain_list, &newDomain->entry); @@ -380,16 +398,27 @@ BOOL WINAPI InternetGetCookieA(LPCSTR lpszUrl, LPCSTR lpszCookieName, LPSTR lpCookieData, LPDWORD lpdwSize) { DWORD len; - LPWSTR szCookieData = NULL, url, name; + LPWSTR szCookieData = NULL, szUrl = NULL, szCookieName = NULL; BOOL r; TRACE("(%s,%s,%p)\n", debugstr_a(lpszUrl), debugstr_a(lpszCookieName), lpCookieData); - url = heap_strdupAtoW(lpszUrl); - name = heap_strdupAtoW(lpszCookieName); + if( lpszUrl ) + { + len = MultiByteToWideChar( CP_ACP, 0, lpszUrl, -1, NULL, 0 ); + szUrl = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) ); + MultiByteToWideChar( CP_ACP, 0, lpszUrl, -1, szUrl, len ); + } + + if( lpszCookieName ) + { + len = MultiByteToWideChar( CP_ACP, 0, lpszCookieName, -1, NULL, 0 ); + szCookieName = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) ); + MultiByteToWideChar( CP_ACP, 0, lpszCookieName, -1, szCookieName, len ); + } - r = InternetGetCookieW( url, name, NULL, &len ); + r = InternetGetCookieW( szUrl, szCookieName, NULL, &len ); if( r ) { szCookieData = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) ); @@ -399,7 +428,7 @@ BOOL WINAPI InternetGetCookieA(LPCSTR lpszUrl, LPCSTR lpszCookieName, } else { - r = InternetGetCookieW( url, name, szCookieData, &len ); + r = InternetGetCookieW( szUrl, szCookieName, szCookieData, &len ); *lpdwSize = WideCharToMultiByte( CP_ACP, 0, szCookieData, len, lpCookieData, *lpdwSize, NULL, NULL ); @@ -407,8 +436,8 @@ BOOL WINAPI InternetGetCookieA(LPCSTR lpszUrl, LPCSTR lpszCookieName, } HeapFree( GetProcessHeap(), 0, szCookieData ); - HeapFree( GetProcessHeap(), 0, name ); - HeapFree( GetProcessHeap(), 0, url ); + HeapFree( GetProcessHeap(), 0, szCookieName ); + HeapFree( GetProcessHeap(), 0, szUrl ); return r; } @@ -423,13 +452,8 @@ static BOOL set_cookie(LPCWSTR domain, LPCWSTR path, LPCWSTR cookie_name, LPCWST FILETIME expiry; BOOL expired = FALSE; - value = data = heap_strdupW(cookie_data); - if (!data) - { - ERR("could not allocate %zu bytes for the cookie data buffer\n", (strlenW(cookie_data) + 1) * sizeof(WCHAR)); - return FALSE; - } - + value = data = HeapAlloc(GetProcessHeap(), 0, (strlenW(cookie_data) + 1) * sizeof(WCHAR)); + strcpyW(data,cookie_data); memset(&expiry,0,sizeof(expiry)); /* lots of information can be parsed out of the cookie value */ @@ -446,15 +470,7 @@ static BOOL set_cookie(LPCWSTR domain, LPCWSTR path, LPCWSTR cookie_name, LPCWST if (!(ptr = strchrW(ptr,';'))) break; *ptr++ = 0; - if (value != data) - HeapFree(GetProcessHeap(), 0, value); value = HeapAlloc(GetProcessHeap(), 0, (ptr - data) * sizeof(WCHAR)); - if (value == NULL) - { - HeapFree(GetProcessHeap(), 0, data); - ERR("could not allocate %zu bytes for the cookie value buffer\n", (ptr - data) * sizeof(WCHAR)); - return FALSE; - } strcpyW(value, data); while (*ptr == ' ') ptr++; /* whitespace */ @@ -575,19 +591,21 @@ BOOL WINAPI InternetSetCookieW(LPCWSTR lpszUrl, LPCWSTR lpszCookieName, if (!lpszCookieName) { + unsigned int len; WCHAR *cookie, *data; - cookie = heap_strdupW(lpCookieData); - if (!cookie) + len = strlenW(lpCookieData); + if (!(cookie = HeapAlloc(GetProcessHeap(), 0, (len + 1) * sizeof(WCHAR)))) { SetLastError(ERROR_OUTOFMEMORY); return FALSE; } + strcpyW(cookie, lpCookieData); /* some apps (or is it us??) try to add a cookie with no cookie name, but * the cookie data in the form of name[=data]. */ - if (!(data = strchrW(cookie, '='))) data = cookie + strlenW(cookie); + if (!(data = strchrW(cookie, '='))) data = cookie + len; else *data++ = 0; ret = set_cookie(hostName, path, cookie, data); @@ -612,21 +630,39 @@ BOOL WINAPI InternetSetCookieW(LPCWSTR lpszUrl, LPCWSTR lpszCookieName, BOOL WINAPI InternetSetCookieA(LPCSTR lpszUrl, LPCSTR lpszCookieName, LPCSTR lpCookieData) { - LPWSTR data, url, name; + DWORD len; + LPWSTR szCookieData = NULL, szUrl = NULL, szCookieName = NULL; BOOL r; TRACE("(%s,%s,%s)\n", debugstr_a(lpszUrl), debugstr_a(lpszCookieName), debugstr_a(lpCookieData)); - url = heap_strdupAtoW(lpszUrl); - name = heap_strdupAtoW(lpszCookieName); - data = heap_strdupAtoW(lpCookieData); + if( lpszUrl ) + { + len = MultiByteToWideChar( CP_ACP, 0, lpszUrl, -1, NULL, 0 ); + szUrl = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) ); + MultiByteToWideChar( CP_ACP, 0, lpszUrl, -1, szUrl, len ); + } + + if( lpszCookieName ) + { + len = MultiByteToWideChar( CP_ACP, 0, lpszCookieName, -1, NULL, 0 ); + szCookieName = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) ); + MultiByteToWideChar( CP_ACP, 0, lpszCookieName, -1, szCookieName, len ); + } + + if( lpCookieData ) + { + len = MultiByteToWideChar( CP_ACP, 0, lpCookieData, -1, NULL, 0 ); + szCookieData = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) ); + MultiByteToWideChar( CP_ACP, 0, lpCookieData, -1, szCookieData, len ); + } - r = InternetSetCookieW( url, name, data ); + r = InternetSetCookieW( szUrl, szCookieName, szCookieData ); - HeapFree( GetProcessHeap(), 0, data ); - HeapFree( GetProcessHeap(), 0, name ); - HeapFree( GetProcessHeap(), 0, url ); + HeapFree( GetProcessHeap(), 0, szCookieData ); + HeapFree( GetProcessHeap(), 0, szCookieName ); + HeapFree( GetProcessHeap(), 0, szUrl ); return r; } diff --git a/dlls/wininet/dialogs.c b/dlls/wininet/dialogs.c index d66e7e354cb..41494a67509 100644 --- a/dlls/wininet/dialogs.c +++ b/dlls/wininet/dialogs.c @@ -62,23 +62,22 @@ struct WININET_ErrorDlgParams */ static BOOL WININET_GetProxyServer( HINTERNET hRequest, LPWSTR szBuf, DWORD sz ) { - http_request_t *lpwhr; - http_session_t *lpwhs = NULL; - appinfo_t *hIC = NULL; - BOOL ret = FALSE; + LPWININETHTTPREQW lpwhr; + LPWININETHTTPSESSIONW lpwhs = NULL; + LPWININETAPPINFOW hIC = NULL; LPWSTR p; - lpwhr = (http_request_t*) WININET_GetObject( hRequest ); + lpwhr = (LPWININETHTTPREQW) WININET_GetObject( hRequest ); if (NULL == lpwhr) - goto done; + return FALSE; lpwhs = lpwhr->lpHttpSession; if (NULL == lpwhs) - goto done; + return FALSE; hIC = lpwhs->lpAppInfo; if (NULL == hIC) - goto done; + return FALSE; lstrcpynW(szBuf, hIC->lpszProxy, sz); @@ -87,39 +86,7 @@ static BOOL WININET_GetProxyServer( HINTERNET hRequest, LPWSTR szBuf, DWORD sz ) if (p) *p = 0; - ret = TRUE; - -done: - WININET_Release( &lpwhr->hdr ); - return ret; -} - -/*********************************************************************** - * WININET_GetServer - * - * Determine the name of the web server - */ -static BOOL WININET_GetServer( HINTERNET hRequest, LPWSTR szBuf, DWORD sz ) -{ - http_request_t *lpwhr; - http_session_t *lpwhs = NULL; - BOOL ret = FALSE; - - lpwhr = (http_request_t*) WININET_GetObject( hRequest ); - if (NULL == lpwhr) - goto done; - - lpwhs = lpwhr->lpHttpSession; - if (NULL == lpwhs) - goto done; - - lstrcpynW(szBuf, lpwhs->lpszHostName, sz); - - ret = TRUE; - -done: - WININET_Release( &lpwhr->hdr ); - return ret; + return TRUE; } /*********************************************************************** @@ -127,20 +94,16 @@ done: * * Determine the name of the (basic) Authentication realm */ -static BOOL WININET_GetAuthRealm( HINTERNET hRequest, LPWSTR szBuf, DWORD sz, BOOL proxy ) +static BOOL WININET_GetAuthRealm( HINTERNET hRequest, LPWSTR szBuf, DWORD sz ) { LPWSTR p, q; - DWORD index, query; + DWORD index; static const WCHAR szRealm[] = { 'r','e','a','l','m','=',0 }; - if (proxy) - query = HTTP_QUERY_PROXY_AUTHENTICATE; - else - query = HTTP_QUERY_WWW_AUTHENTICATE; - - /* extract the Realm from the response and show it */ + /* extract the Realm from the proxy response and show it */ index = 0; - if( !HttpQueryInfoW( hRequest, query, szBuf, &sz, &index) ) + if( !HttpQueryInfoW( hRequest, HTTP_QUERY_PROXY_AUTHENTICATE, + szBuf, &sz, &index) ) return FALSE; /* @@ -150,10 +113,11 @@ static BOOL WININET_GetAuthRealm( HINTERNET hRequest, LPWSTR szBuf, DWORD sz, BO p = strchrW( szBuf, ' ' ); if( !p || strncmpW( p+1, szRealm, strlenW(szRealm) ) ) { - ERR("response wrong? (%s)\n", debugstr_w(szBuf)); + ERR("proxy response wrong? (%s)\n", debugstr_w(szBuf)); return FALSE; } + /* remove quotes */ p += 7; if( *p == '"' ) @@ -234,62 +198,44 @@ static BOOL WININET_GetSetPassword( HWND hdlg, LPCWSTR szServer, } /*********************************************************************** - * WININET_SetAuthorization + * WININET_SetProxyAuthorization */ -static BOOL WININET_SetAuthorization( HINTERNET hRequest, LPWSTR username, - LPWSTR password, BOOL proxy ) +static BOOL WININET_SetProxyAuthorization( HINTERNET hRequest, + LPWSTR username, LPWSTR password ) { - http_request_t *lpwhr; - http_session_t *lpwhs; - BOOL ret = FALSE; - LPWSTR p, q; + LPWININETHTTPREQW lpwhr; + LPWININETHTTPSESSIONW lpwhs; + LPWININETAPPINFOW hIC; + LPWSTR p; - lpwhr = (http_request_t*) WININET_GetObject( hRequest ); + lpwhr = (LPWININETHTTPREQW) WININET_GetObject( hRequest ); if( !lpwhr ) - return FALSE; - + return FALSE; + lpwhs = lpwhr->lpHttpSession; if (NULL == lpwhs || lpwhs->hdr.htype != WH_HHTTPSESSION) { INTERNET_SetLastError(ERROR_INTERNET_INCORRECT_HANDLE_TYPE); - goto done; + return FALSE; } - p = heap_strdupW(username); - if( !p ) - goto done; - - q = heap_strdupW(password); - if( !q ) - { - HeapFree(GetProcessHeap(), 0, username); - goto done; - } - - if (proxy) - { - appinfo_t *hIC = lpwhs->lpAppInfo; - - HeapFree(GetProcessHeap(), 0, hIC->lpszProxyUsername); - hIC->lpszProxyUsername = p; - - HeapFree(GetProcessHeap(), 0, hIC->lpszProxyPassword); - hIC->lpszProxyPassword = q; - } - else - { - HeapFree(GetProcessHeap(), 0, lpwhs->lpszUserName); - lpwhs->lpszUserName = p; + hIC = lpwhs->lpAppInfo; - HeapFree(GetProcessHeap(), 0, lpwhs->lpszPassword); - lpwhs->lpszPassword = q; - } + p = HeapAlloc( GetProcessHeap(), 0, (strlenW( username ) + 1)*sizeof(WCHAR) ); + if( !p ) + return FALSE; + + lstrcpyW( p, username ); + hIC->lpszProxyUsername = p; - ret = TRUE; + p = HeapAlloc( GetProcessHeap(), 0, (strlenW( password ) + 1)*sizeof(WCHAR) ); + if( !p ) + return FALSE; + + lstrcpyW( p, password ); + hIC->lpszProxyPassword = p; -done: - WININET_Release( &lpwhr->hdr ); - return ret; + return TRUE; } /*********************************************************************** @@ -312,7 +258,7 @@ static INT_PTR WINAPI WININET_ProxyPasswordDialog( /* extract the Realm from the proxy response and show it */ if( WININET_GetAuthRealm( params->hRequest, - szRealm, sizeof szRealm/sizeof(WCHAR), TRUE ) ) + szRealm, sizeof szRealm/sizeof(WCHAR)) ) { hitem = GetDlgItem( hdlg, IDC_REALM ); SetWindowTextW( hitem, szRealm ); @@ -355,97 +301,13 @@ static INT_PTR WINAPI WININET_ProxyPasswordDialog( if( hitem && SendMessageW( hitem, BM_GETSTATE, 0, 0 ) && WININET_GetAuthRealm( params->hRequest, - szRealm, sizeof szRealm/sizeof(WCHAR), TRUE ) && + szRealm, sizeof szRealm/sizeof(WCHAR)) && WININET_GetProxyServer( params->hRequest, szServer, sizeof szServer/sizeof(WCHAR)) ) { WININET_GetSetPassword( hdlg, szServer, szRealm, TRUE ); } - WININET_SetAuthorization( params->hRequest, username, password, TRUE ); - - EndDialog( hdlg, ERROR_INTERNET_FORCE_RETRY ); - return TRUE; - } - if( wParam == IDCANCEL ) - { - EndDialog( hdlg, 0 ); - return TRUE; - } - break; - } - return FALSE; -} - -/*********************************************************************** - * WININET_PasswordDialog - */ -static INT_PTR WINAPI WININET_PasswordDialog( - HWND hdlg, UINT uMsg, WPARAM wParam, LPARAM lParam ) -{ - HWND hitem; - struct WININET_ErrorDlgParams *params; - WCHAR szRealm[0x80], szServer[0x80]; - - if( uMsg == WM_INITDIALOG ) - { - TRACE("WM_INITDIALOG (%08lx)\n", lParam); - - /* save the parameter list */ - params = (struct WININET_ErrorDlgParams*) lParam; - SetWindowLongPtrW( hdlg, GWLP_USERDATA, lParam ); - - /* extract the Realm from the response and show it */ - if( WININET_GetAuthRealm( params->hRequest, - szRealm, sizeof szRealm/sizeof(WCHAR), FALSE ) ) - { - hitem = GetDlgItem( hdlg, IDC_REALM ); - SetWindowTextW( hitem, szRealm ); - } - - /* extract the name of the server */ - if( WININET_GetServer( params->hRequest, - szServer, sizeof szServer/sizeof(WCHAR)) ) - { - hitem = GetDlgItem( hdlg, IDC_SERVER ); - SetWindowTextW( hitem, szServer ); - } - - WININET_GetSetPassword( hdlg, szServer, szRealm, FALSE ); - - return TRUE; - } - - params = (struct WININET_ErrorDlgParams*) - GetWindowLongPtrW( hdlg, GWLP_USERDATA ); - - switch( uMsg ) - { - case WM_COMMAND: - if( wParam == IDOK ) - { - WCHAR username[0x20], password[0x20]; - - username[0] = 0; - hitem = GetDlgItem( hdlg, IDC_USERNAME ); - if( hitem ) - GetWindowTextW( hitem, username, sizeof username/sizeof(WCHAR) ); - - password[0] = 0; - hitem = GetDlgItem( hdlg, IDC_PASSWORD ); - if( hitem ) - GetWindowTextW( hitem, password, sizeof password/sizeof(WCHAR) ); - - hitem = GetDlgItem( hdlg, IDC_SAVEPASSWORD ); - if( hitem && - SendMessageW( hitem, BM_GETSTATE, 0, 0 ) && - WININET_GetAuthRealm( params->hRequest, - szRealm, sizeof szRealm/sizeof(WCHAR), FALSE ) && - WININET_GetServer( params->hRequest, - szServer, sizeof szServer/sizeof(WCHAR)) ) - { - WININET_GetSetPassword( hdlg, szServer, szRealm, TRUE ); - } - WININET_SetAuthorization( params->hRequest, username, password, FALSE ); + WININET_SetProxyAuthorization( params->hRequest, username, password ); EndDialog( hdlg, ERROR_INTERNET_FORCE_RETRY ); return TRUE; @@ -504,23 +366,17 @@ DWORD WINAPI InternetErrorDlg(HWND hWnd, HINTERNET hRequest, switch( dwError ) { case ERROR_SUCCESS: - case ERROR_INTERNET_INCORRECT_PASSWORD: - if( !dwError && !(dwFlags & FLAGS_ERROR_UI_FILTER_FOR_ERRORS ) ) + if( !(dwFlags & FLAGS_ERROR_UI_FILTER_FOR_ERRORS ) ) return 0; - dwStatus = WININET_GetConnectionStatus( hRequest ); - switch (dwStatus) - { - case HTTP_STATUS_PROXY_AUTH_REQ: - return DialogBoxParamW( hwininet, MAKEINTRESOURCEW( IDD_PROXYDLG ), - hWnd, WININET_ProxyPasswordDialog, (LPARAM) ¶ms ); - case HTTP_STATUS_DENIED: - return DialogBoxParamW( hwininet, MAKEINTRESOURCEW( IDD_AUTHDLG ), - hWnd, WININET_PasswordDialog, (LPARAM) ¶ms ); - default: - WARN("unhandled status %u\n", dwStatus); - return 0; - } + if( HTTP_STATUS_PROXY_AUTH_REQ != dwStatus ) + return ERROR_SUCCESS; + return DialogBoxParamW( hwininet, MAKEINTRESOURCEW( IDD_PROXYDLG ), + hWnd, WININET_ProxyPasswordDialog, (LPARAM) ¶ms ); + + case ERROR_INTERNET_INCORRECT_PASSWORD: + return DialogBoxParamW( hwininet, MAKEINTRESOURCEW( IDD_PROXYDLG ), + hWnd, WININET_ProxyPasswordDialog, (LPARAM) ¶ms ); case ERROR_INTERNET_HTTP_TO_HTTPS_ON_REDIR: case ERROR_INTERNET_INVALID_CA: diff --git a/dlls/wininet/ftp.c b/dlls/wininet/ftp.c index dbb54cbc3d6..db0bf569ebc 100644 --- a/dlls/wininet/ftp.c +++ b/dlls/wininet/ftp.c @@ -68,29 +68,29 @@ WINE_DEFAULT_DEBUG_CHANNEL(wininet); -typedef struct _ftp_session_t ftp_session_t; +typedef struct _WININETFTPSESSIONW WININETFTPSESSIONW; typedef struct { - object_header_t hdr; - ftp_session_t *lpFtpSession; + WININETHANDLEHEADER hdr; + WININETFTPSESSIONW *lpFtpSession; BOOL session_deleted; int nDataSocket; -} ftp_file_t; +} WININETFTPFILE, *LPWININETFTPFILE; -struct _ftp_session_t +typedef struct _WININETFTPSESSIONW { - object_header_t hdr; - appinfo_t *lpAppInfo; + WININETHANDLEHEADER hdr; + WININETAPPINFOW *lpAppInfo; int sndSocket; int lstnSocket; int pasvSocket; /* data socket connected by us in case of passive FTP */ - ftp_file_t *download_in_progress; + LPWININETFTPFILE download_in_progress; struct sockaddr_in socketAddress; struct sockaddr_in lstnSocketAddress; LPWSTR lpszPassword; LPWSTR lpszUserName; -}; +} *LPWININETFTPSESSIONW; typedef struct { @@ -103,8 +103,8 @@ typedef struct typedef struct { - object_header_t hdr; - ftp_session_t *lpFtpSession; + WININETHANDLEHEADER hdr; + WININETFTPSESSIONW *lpFtpSession; DWORD index; DWORD size; LPFILEPROPERTIESW lpafp; @@ -172,41 +172,41 @@ static const CHAR szMonths[] = "JANFEBMARAPRMAYJUNJULAUGSEPOCTNOVDEC"; static const WCHAR szNoAccount[] = {'n','o','a','c','c','o','u','n','t','\0'}; static BOOL FTP_SendCommand(INT nSocket, FTP_COMMAND ftpCmd, LPCWSTR lpszParam, - INTERNET_STATUS_CALLBACK lpfnStatusCB, object_header_t *hdr, DWORD_PTR dwContext); -static BOOL FTP_SendStore(ftp_session_t*, LPCWSTR lpszRemoteFile, DWORD dwType); -static BOOL FTP_GetDataSocket(ftp_session_t*, LPINT nDataSocket); -static BOOL FTP_SendData(ftp_session_t*, INT nDataSocket, HANDLE hFile); -static INT FTP_ReceiveResponse(ftp_session_t*, DWORD_PTR dwContext); -static BOOL FTP_SendRetrieve(ftp_session_t*, LPCWSTR lpszRemoteFile, DWORD dwType); -static BOOL FTP_RetrieveFileData(ftp_session_t*, INT nDataSocket, HANDLE hFile); -static BOOL FTP_InitListenSocket(ftp_session_t*); -static BOOL FTP_ConnectToHost(ftp_session_t*); -static BOOL FTP_SendPassword(ftp_session_t*); -static BOOL FTP_SendAccount(ftp_session_t*); -static BOOL FTP_SendType(ftp_session_t*, DWORD dwType); -static BOOL FTP_SendPort(ftp_session_t*); -static BOOL FTP_DoPassive(ftp_session_t*); -static BOOL FTP_SendPortOrPasv(ftp_session_t*); + INTERNET_STATUS_CALLBACK lpfnStatusCB, LPWININETHANDLEHEADER hdr, DWORD_PTR dwContext); +static BOOL FTP_SendStore(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszRemoteFile, DWORD dwType); +static BOOL FTP_GetDataSocket(LPWININETFTPSESSIONW lpwfs, LPINT nDataSocket); +static BOOL FTP_SendData(LPWININETFTPSESSIONW lpwfs, INT nDataSocket, HANDLE hFile); +static INT FTP_ReceiveResponse(LPWININETFTPSESSIONW lpwfs, DWORD_PTR dwContext); +static BOOL FTP_SendRetrieve(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszRemoteFile, DWORD dwType); +static BOOL FTP_RetrieveFileData(LPWININETFTPSESSIONW lpwfs, INT nDataSocket, HANDLE hFile); +static BOOL FTP_InitListenSocket(LPWININETFTPSESSIONW lpwfs); +static BOOL FTP_ConnectToHost(LPWININETFTPSESSIONW lpwfs); +static BOOL FTP_SendPassword(LPWININETFTPSESSIONW lpwfs); +static BOOL FTP_SendAccount(LPWININETFTPSESSIONW lpwfs); +static BOOL FTP_SendType(LPWININETFTPSESSIONW lpwfs, DWORD dwType); +static BOOL FTP_SendPort(LPWININETFTPSESSIONW lpwfs); +static BOOL FTP_DoPassive(LPWININETFTPSESSIONW lpwfs); +static BOOL FTP_SendPortOrPasv(LPWININETFTPSESSIONW lpwfs); static BOOL FTP_ParsePermission(LPCSTR lpszPermission, LPFILEPROPERTIESW lpfp); static BOOL FTP_ParseNextFile(INT nSocket, LPCWSTR lpszSearchFile, LPFILEPROPERTIESW fileprop); -static BOOL FTP_ParseDirectory(ftp_session_t*, INT nSocket, LPCWSTR lpszSearchFile, +static BOOL FTP_ParseDirectory(LPWININETFTPSESSIONW lpwfs, INT nSocket, LPCWSTR lpszSearchFile, LPFILEPROPERTIESW *lpafp, LPDWORD dwfp); -static HINTERNET FTP_ReceiveFileList(ftp_session_t*, INT nSocket, LPCWSTR lpszSearchFile, +static HINTERNET FTP_ReceiveFileList(LPWININETFTPSESSIONW lpwfs, INT nSocket, LPCWSTR lpszSearchFile, LPWIN32_FIND_DATAW lpFindFileData, DWORD_PTR dwContext); static DWORD FTP_SetResponseError(DWORD dwResponse); static BOOL FTP_ConvertFileProp(LPFILEPROPERTIESW lpafp, LPWIN32_FIND_DATAW lpFindFileData); -static BOOL FTP_FtpPutFileW(ftp_session_t*, LPCWSTR lpszLocalFile, +static BOOL FTP_FtpPutFileW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszLocalFile, LPCWSTR lpszNewRemoteFile, DWORD dwFlags, DWORD_PTR dwContext); -static BOOL FTP_FtpSetCurrentDirectoryW(ftp_session_t*, LPCWSTR lpszDirectory); -static BOOL FTP_FtpCreateDirectoryW(ftp_session_t*, LPCWSTR lpszDirectory); -static HINTERNET FTP_FtpFindFirstFileW(ftp_session_t*, +static BOOL FTP_FtpSetCurrentDirectoryW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszDirectory); +static BOOL FTP_FtpCreateDirectoryW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszDirectory); +static HINTERNET FTP_FtpFindFirstFileW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszSearchFile, LPWIN32_FIND_DATAW lpFindFileData, DWORD dwFlags, DWORD_PTR dwContext); -static BOOL FTP_FtpGetCurrentDirectoryW(ftp_session_t*, LPWSTR lpszCurrentDirectory, +static BOOL FTP_FtpGetCurrentDirectoryW(LPWININETFTPSESSIONW lpwfs, LPWSTR lpszCurrentDirectory, LPDWORD lpdwCurrentDirectory); -static BOOL FTP_FtpRenameFileW(ftp_session_t*, LPCWSTR lpszSrc, LPCWSTR lpszDest); -static BOOL FTP_FtpRemoveDirectoryW(ftp_session_t*, LPCWSTR lpszDirectory); -static BOOL FTP_FtpDeleteFileW(ftp_session_t*, LPCWSTR lpszFileName); -static BOOL FTP_FtpGetFileW(ftp_session_t*, LPCWSTR lpszRemoteFile, LPCWSTR lpszNewFile, +static BOOL FTP_FtpRenameFileW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszSrc, LPCWSTR lpszDest); +static BOOL FTP_FtpRemoveDirectoryW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszDirectory); +static BOOL FTP_FtpDeleteFileW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszFileName); +static BOOL FTP_FtpGetFileW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszRemoteFile, LPCWSTR lpszNewFile, BOOL fFailIfExists, DWORD dwLocalFlagsAttribute, DWORD dwInternetFlags, DWORD_PTR dwContext); @@ -228,8 +228,8 @@ BOOL WINAPI FtpPutFileA(HINTERNET hConnect, LPCSTR lpszLocalFile, LPWSTR lpwzNewRemoteFile; BOOL ret; - lpwzLocalFile = heap_strdupAtoW(lpszLocalFile); - lpwzNewRemoteFile = heap_strdupAtoW(lpszNewRemoteFile); + lpwzLocalFile = lpszLocalFile?WININET_strdup_AtoW(lpszLocalFile):NULL; + lpwzNewRemoteFile = lpszNewRemoteFile?WININET_strdup_AtoW(lpszNewRemoteFile):NULL; ret = FtpPutFileW(hConnect, lpwzLocalFile, lpwzNewRemoteFile, dwFlags, dwContext); HeapFree(GetProcessHeap(), 0, lpwzLocalFile); @@ -240,7 +240,7 @@ BOOL WINAPI FtpPutFileA(HINTERNET hConnect, LPCSTR lpszLocalFile, static void AsyncFtpPutFileProc(WORKREQUEST *workRequest) { struct WORKREQ_FTPPUTFILEW const *req = &workRequest->u.FtpPutFileW; - ftp_session_t *lpwfs = (ftp_session_t*) workRequest->hdr; + LPWININETFTPSESSIONW lpwfs = (LPWININETFTPSESSIONW) workRequest->hdr; TRACE("%p\n", lpwfs); @@ -264,8 +264,8 @@ static void AsyncFtpPutFileProc(WORKREQUEST *workRequest) BOOL WINAPI FtpPutFileW(HINTERNET hConnect, LPCWSTR lpszLocalFile, LPCWSTR lpszNewRemoteFile, DWORD dwFlags, DWORD_PTR dwContext) { - ftp_session_t *lpwfs; - appinfo_t *hIC = NULL; + LPWININETFTPSESSIONW lpwfs; + LPWININETAPPINFOW hIC = NULL; BOOL r = FALSE; if (!lpszLocalFile || !lpszNewRemoteFile) @@ -274,7 +274,7 @@ BOOL WINAPI FtpPutFileW(HINTERNET hConnect, LPCWSTR lpszLocalFile, return FALSE; } - lpwfs = (ftp_session_t*) WININET_GetObject( hConnect ); + lpwfs = (LPWININETFTPSESSIONW) WININET_GetObject( hConnect ); if (!lpwfs) { INTERNET_SetLastError(ERROR_INVALID_HANDLE); @@ -307,8 +307,8 @@ BOOL WINAPI FtpPutFileW(HINTERNET hConnect, LPCWSTR lpszLocalFile, workRequest.asyncproc = AsyncFtpPutFileProc; workRequest.hdr = WININET_AddRef( &lpwfs->hdr ); - req->lpszLocalFile = heap_strdupW(lpszLocalFile); - req->lpszNewRemoteFile = heap_strdupW(lpszNewRemoteFile); + req->lpszLocalFile = WININET_strdupW(lpszLocalFile); + req->lpszNewRemoteFile = WININET_strdupW(lpszNewRemoteFile); req->dwFlags = dwFlags; req->dwContext = dwContext; @@ -336,12 +336,12 @@ lend: * FALSE on failure * */ -static BOOL FTP_FtpPutFileW(ftp_session_t *lpwfs, LPCWSTR lpszLocalFile, +static BOOL FTP_FtpPutFileW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszLocalFile, LPCWSTR lpszNewRemoteFile, DWORD dwFlags, DWORD_PTR dwContext) { HANDLE hFile; BOOL bSuccess = FALSE; - appinfo_t *hIC = NULL; + LPWININETAPPINFOW hIC = NULL; INT nResCode; TRACE(" lpszLocalFile(%s) lpszNewRemoteFile(%s)\n", debugstr_w(lpszLocalFile), debugstr_w(lpszNewRemoteFile)); @@ -413,7 +413,7 @@ BOOL WINAPI FtpSetCurrentDirectoryA(HINTERNET hConnect, LPCSTR lpszDirectory) LPWSTR lpwzDirectory; BOOL ret; - lpwzDirectory = heap_strdupAtoW(lpszDirectory); + lpwzDirectory = lpszDirectory?WININET_strdup_AtoW(lpszDirectory):NULL; ret = FtpSetCurrentDirectoryW(hConnect, lpwzDirectory); HeapFree(GetProcessHeap(), 0, lpwzDirectory); return ret; @@ -423,7 +423,7 @@ BOOL WINAPI FtpSetCurrentDirectoryA(HINTERNET hConnect, LPCSTR lpszDirectory) static void AsyncFtpSetCurrentDirectoryProc(WORKREQUEST *workRequest) { struct WORKREQ_FTPSETCURRENTDIRECTORYW const *req = &workRequest->u.FtpSetCurrentDirectoryW; - ftp_session_t *lpwfs = (ftp_session_t*) workRequest->hdr; + LPWININETFTPSESSIONW lpwfs = (LPWININETFTPSESSIONW) workRequest->hdr; TRACE("%p\n", lpwfs); @@ -443,8 +443,8 @@ static void AsyncFtpSetCurrentDirectoryProc(WORKREQUEST *workRequest) */ BOOL WINAPI FtpSetCurrentDirectoryW(HINTERNET hConnect, LPCWSTR lpszDirectory) { - ftp_session_t *lpwfs = NULL; - appinfo_t *hIC = NULL; + LPWININETFTPSESSIONW lpwfs = NULL; + LPWININETAPPINFOW hIC = NULL; BOOL r = FALSE; if (!lpszDirectory) @@ -453,7 +453,7 @@ BOOL WINAPI FtpSetCurrentDirectoryW(HINTERNET hConnect, LPCWSTR lpszDirectory) goto lend; } - lpwfs = (ftp_session_t*) WININET_GetObject( hConnect ); + lpwfs = (LPWININETFTPSESSIONW) WININET_GetObject( hConnect ); if (NULL == lpwfs || WH_HFTPSESSION != lpwfs->hdr.htype) { INTERNET_SetLastError(ERROR_INTERNET_INCORRECT_HANDLE_TYPE); @@ -477,7 +477,7 @@ BOOL WINAPI FtpSetCurrentDirectoryW(HINTERNET hConnect, LPCWSTR lpszDirectory) workRequest.asyncproc = AsyncFtpSetCurrentDirectoryProc; workRequest.hdr = WININET_AddRef( &lpwfs->hdr ); req = &workRequest.u.FtpSetCurrentDirectoryW; - req->lpszDirectory = heap_strdupW(lpszDirectory); + req->lpszDirectory = WININET_strdupW(lpszDirectory); r = INTERNET_AsyncCall(&workRequest); } @@ -504,10 +504,10 @@ lend: * FALSE on failure * */ -static BOOL FTP_FtpSetCurrentDirectoryW(ftp_session_t *lpwfs, LPCWSTR lpszDirectory) +static BOOL FTP_FtpSetCurrentDirectoryW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszDirectory) { INT nResCode; - appinfo_t *hIC = NULL; + LPWININETAPPINFOW hIC = NULL; DWORD bSuccess = FALSE; TRACE("lpszDirectory(%s)\n", debugstr_w(lpszDirectory)); @@ -559,7 +559,7 @@ BOOL WINAPI FtpCreateDirectoryA(HINTERNET hConnect, LPCSTR lpszDirectory) LPWSTR lpwzDirectory; BOOL ret; - lpwzDirectory = heap_strdupAtoW(lpszDirectory); + lpwzDirectory = lpszDirectory?WININET_strdup_AtoW(lpszDirectory):NULL; ret = FtpCreateDirectoryW(hConnect, lpwzDirectory); HeapFree(GetProcessHeap(), 0, lpwzDirectory); return ret; @@ -569,7 +569,7 @@ BOOL WINAPI FtpCreateDirectoryA(HINTERNET hConnect, LPCSTR lpszDirectory) static void AsyncFtpCreateDirectoryProc(WORKREQUEST *workRequest) { struct WORKREQ_FTPCREATEDIRECTORYW const *req = &workRequest->u.FtpCreateDirectoryW; - ftp_session_t *lpwfs = (ftp_session_t*) workRequest->hdr; + LPWININETFTPSESSIONW lpwfs = (LPWININETFTPSESSIONW) workRequest->hdr; TRACE(" %p\n", lpwfs); @@ -589,11 +589,11 @@ static void AsyncFtpCreateDirectoryProc(WORKREQUEST *workRequest) */ BOOL WINAPI FtpCreateDirectoryW(HINTERNET hConnect, LPCWSTR lpszDirectory) { - ftp_session_t *lpwfs; - appinfo_t *hIC = NULL; + LPWININETFTPSESSIONW lpwfs; + LPWININETAPPINFOW hIC = NULL; BOOL r = FALSE; - lpwfs = (ftp_session_t*) WININET_GetObject( hConnect ); + lpwfs = (LPWININETFTPSESSIONW) WININET_GetObject( hConnect ); if (!lpwfs) { INTERNET_SetLastError(ERROR_INVALID_HANDLE); @@ -627,7 +627,7 @@ BOOL WINAPI FtpCreateDirectoryW(HINTERNET hConnect, LPCWSTR lpszDirectory) workRequest.asyncproc = AsyncFtpCreateDirectoryProc; workRequest.hdr = WININET_AddRef( &lpwfs->hdr ); req = &workRequest.u.FtpCreateDirectoryW; - req->lpszDirectory = heap_strdupW(lpszDirectory); + req->lpszDirectory = WININET_strdupW(lpszDirectory); r = INTERNET_AsyncCall(&workRequest); } @@ -652,11 +652,11 @@ lend: * FALSE on failure * */ -static BOOL FTP_FtpCreateDirectoryW(ftp_session_t *lpwfs, LPCWSTR lpszDirectory) +static BOOL FTP_FtpCreateDirectoryW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszDirectory) { INT nResCode; BOOL bSuccess = FALSE; - appinfo_t *hIC = NULL; + LPWININETAPPINFOW hIC = NULL; TRACE("lpszDirectory(%s)\n", debugstr_w(lpszDirectory)); @@ -708,7 +708,7 @@ HINTERNET WINAPI FtpFindFirstFileA(HINTERNET hConnect, LPWIN32_FIND_DATAW lpFindFileDataW; HINTERNET ret; - lpwzSearchFile = heap_strdupAtoW(lpszSearchFile); + lpwzSearchFile = lpszSearchFile?WININET_strdup_AtoW(lpszSearchFile):NULL; lpFindFileDataW = lpFindFileData?&wfd:NULL; ret = FtpFindFirstFileW(hConnect, lpwzSearchFile, lpFindFileDataW, dwFlags, dwContext); HeapFree(GetProcessHeap(), 0, lpwzSearchFile); @@ -723,7 +723,7 @@ HINTERNET WINAPI FtpFindFirstFileA(HINTERNET hConnect, static void AsyncFtpFindFirstFileProc(WORKREQUEST *workRequest) { struct WORKREQ_FTPFINDFIRSTFILEW const *req = &workRequest->u.FtpFindFirstFileW; - ftp_session_t *lpwfs = (ftp_session_t*) workRequest->hdr; + LPWININETFTPSESSIONW lpwfs = (LPWININETFTPSESSIONW) workRequest->hdr; TRACE("%p\n", lpwfs); @@ -745,11 +745,11 @@ static void AsyncFtpFindFirstFileProc(WORKREQUEST *workRequest) HINTERNET WINAPI FtpFindFirstFileW(HINTERNET hConnect, LPCWSTR lpszSearchFile, LPWIN32_FIND_DATAW lpFindFileData, DWORD dwFlags, DWORD_PTR dwContext) { - ftp_session_t *lpwfs; - appinfo_t *hIC = NULL; + LPWININETFTPSESSIONW lpwfs; + LPWININETAPPINFOW hIC = NULL; HINTERNET r = NULL; - lpwfs = (ftp_session_t*) WININET_GetObject( hConnect ); + lpwfs = (LPWININETFTPSESSIONW) WININET_GetObject( hConnect ); if (NULL == lpwfs || WH_HFTPSESSION != lpwfs->hdr.htype) { INTERNET_SetLastError(ERROR_INTERNET_INCORRECT_HANDLE_TYPE); @@ -771,7 +771,7 @@ HINTERNET WINAPI FtpFindFirstFileW(HINTERNET hConnect, workRequest.asyncproc = AsyncFtpFindFirstFileProc; workRequest.hdr = WININET_AddRef( &lpwfs->hdr ); req = &workRequest.u.FtpFindFirstFileW; - req->lpszSearchFile = (lpszSearchFile == NULL) ? NULL : heap_strdupW(lpszSearchFile); + req->lpszSearchFile = (lpszSearchFile == NULL) ? NULL : WININET_strdupW(lpszSearchFile); req->lpFindFileData = lpFindFileData; req->dwFlags = dwFlags; req->dwContext= dwContext; @@ -802,11 +802,11 @@ lend: * NULL on failure * */ -static HINTERNET FTP_FtpFindFirstFileW(ftp_session_t *lpwfs, +static HINTERNET FTP_FtpFindFirstFileW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszSearchFile, LPWIN32_FIND_DATAW lpFindFileData, DWORD dwFlags, DWORD_PTR dwContext) { INT nResCode; - appinfo_t *hIC = NULL; + LPWININETAPPINFOW hIC = NULL; HINTERNET hFindNext = NULL; TRACE("\n"); @@ -918,7 +918,7 @@ BOOL WINAPI FtpGetCurrentDirectoryA(HINTERNET hFtpSession, LPSTR lpszCurrentDire static void AsyncFtpGetCurrentDirectoryProc(WORKREQUEST *workRequest) { struct WORKREQ_FTPGETCURRENTDIRECTORYW const *req = &workRequest->u.FtpGetCurrentDirectoryW; - ftp_session_t *lpwfs = (ftp_session_t*) workRequest->hdr; + LPWININETFTPSESSIONW lpwfs = (LPWININETFTPSESSIONW) workRequest->hdr; TRACE("%p\n", lpwfs); @@ -938,13 +938,13 @@ static void AsyncFtpGetCurrentDirectoryProc(WORKREQUEST *workRequest) BOOL WINAPI FtpGetCurrentDirectoryW(HINTERNET hFtpSession, LPWSTR lpszCurrentDirectory, LPDWORD lpdwCurrentDirectory) { - ftp_session_t *lpwfs; - appinfo_t *hIC = NULL; + LPWININETFTPSESSIONW lpwfs; + LPWININETAPPINFOW hIC = NULL; BOOL r = FALSE; TRACE("%p %p %p\n", hFtpSession, lpszCurrentDirectory, lpdwCurrentDirectory); - lpwfs = (ftp_session_t*) WININET_GetObject( hFtpSession ); + lpwfs = (LPWININETFTPSESSIONW) WININET_GetObject( hFtpSession ); if (NULL == lpwfs) { INTERNET_SetLastError(ERROR_INVALID_HANDLE); @@ -1013,11 +1013,11 @@ lend: * FALSE on failure * */ -static BOOL FTP_FtpGetCurrentDirectoryW(ftp_session_t *lpwfs, LPWSTR lpszCurrentDirectory, +static BOOL FTP_FtpGetCurrentDirectoryW(LPWININETFTPSESSIONW lpwfs, LPWSTR lpszCurrentDirectory, LPDWORD lpdwCurrentDirectory) { INT nResCode; - appinfo_t *hIC = NULL; + LPWININETAPPINFOW hIC = NULL; DWORD bSuccess = FALSE; /* Clear any error information */ @@ -1034,7 +1034,7 @@ static BOOL FTP_FtpGetCurrentDirectoryW(ftp_session_t *lpwfs, LPWSTR lpszCurrent if (nResCode == 257) /* Extract directory name */ { DWORD firstpos, lastpos, len; - LPWSTR lpszResponseBuffer = heap_strdupAtoW(INTERNET_GetResponseBuffer()); + LPWSTR lpszResponseBuffer = WININET_strdup_AtoW(INTERNET_GetResponseBuffer()); for (firstpos = 0, lastpos = 0; lpszResponseBuffer[lastpos]; lastpos++) { @@ -1084,10 +1084,10 @@ lend: * the 'transfer complete' message (this is a bit of a hack though :-/ ) * */ -static void FTPFILE_Destroy(object_header_t *hdr) +static void FTPFILE_Destroy(WININETHANDLEHEADER *hdr) { - ftp_file_t *lpwh = (ftp_file_t*) hdr; - ftp_session_t *lpwfs = lpwh->lpFtpSession; + LPWININETFTPFILE lpwh = (LPWININETFTPFILE) hdr; + LPWININETFTPSESSIONW lpwfs = lpwh->lpFtpSession; INT nResCode; TRACE("\n"); @@ -1106,7 +1106,7 @@ static void FTPFILE_Destroy(object_header_t *hdr) HeapFree(GetProcessHeap(), 0, lpwh); } -static DWORD FTPFILE_QueryOption(object_header_t *hdr, DWORD option, void *buffer, DWORD *size, BOOL unicode) +static DWORD FTPFILE_QueryOption(WININETHANDLEHEADER *hdr, DWORD option, void *buffer, DWORD *size, BOOL unicode) { switch(option) { case INTERNET_OPTION_HANDLE_TYPE: @@ -1123,9 +1123,9 @@ static DWORD FTPFILE_QueryOption(object_header_t *hdr, DWORD option, void *buffe return INET_QueryOption(option, buffer, size, unicode); } -static DWORD FTPFILE_ReadFile(object_header_t *hdr, void *buffer, DWORD size, DWORD *read) +static DWORD FTPFILE_ReadFile(WININETHANDLEHEADER *hdr, void *buffer, DWORD size, DWORD *read) { - ftp_file_t *file = (ftp_file_t*)hdr; + WININETFTPFILE *file = (WININETFTPFILE*)hdr; int res; if (file->nDataSocket == -1) @@ -1138,21 +1138,21 @@ static DWORD FTPFILE_ReadFile(object_header_t *hdr, void *buffer, DWORD size, DW return res>=0 ? ERROR_SUCCESS : INTERNET_ERROR_BASE; /* FIXME*/ } -static DWORD FTPFILE_ReadFileExA(object_header_t *hdr, INTERNET_BUFFERSA *buffers, +static DWORD FTPFILE_ReadFileExA(WININETHANDLEHEADER *hdr, INTERNET_BUFFERSA *buffers, DWORD flags, DWORD_PTR context) { return FTPFILE_ReadFile(hdr, buffers->lpvBuffer, buffers->dwBufferLength, &buffers->dwBufferLength); } -static DWORD FTPFILE_ReadFileExW(object_header_t *hdr, INTERNET_BUFFERSW *buffers, +static DWORD FTPFILE_ReadFileExW(WININETHANDLEHEADER *hdr, INTERNET_BUFFERSW *buffers, DWORD flags, DWORD_PTR context) { return FTPFILE_ReadFile(hdr, buffers->lpvBuffer, buffers->dwBufferLength, &buffers->dwBufferLength); } -static BOOL FTPFILE_WriteFile(object_header_t *hdr, const void *buffer, DWORD size, DWORD *written) +static BOOL FTPFILE_WriteFile(WININETHANDLEHEADER *hdr, const void *buffer, DWORD size, DWORD *written) { - ftp_file_t *lpwh = (ftp_file_t*) hdr; + LPWININETFTPFILE lpwh = (LPWININETFTPFILE) hdr; int res; res = send(lpwh->nDataSocket, buffer, size, 0); @@ -1161,7 +1161,7 @@ static BOOL FTPFILE_WriteFile(object_header_t *hdr, const void *buffer, DWORD si return res >= 0; } -static void FTP_ReceiveRequestData(ftp_file_t *file, BOOL first_notif) +static void FTP_ReceiveRequestData(WININETFTPFILE *file, BOOL first_notif) { INTERNET_ASYNC_RESULT iar; BYTE buffer[4096]; @@ -1185,14 +1185,14 @@ static void FTP_ReceiveRequestData(ftp_file_t *file, BOOL first_notif) static void FTPFILE_AsyncQueryDataAvailableProc(WORKREQUEST *workRequest) { - ftp_file_t *file = (ftp_file_t*)workRequest->hdr; + WININETFTPFILE *file = (WININETFTPFILE*)workRequest->hdr; FTP_ReceiveRequestData(file, FALSE); } -static DWORD FTPFILE_QueryDataAvailable(object_header_t *hdr, DWORD *available, DWORD flags, DWORD_PTR ctx) +static DWORD FTPFILE_QueryDataAvailable(WININETHANDLEHEADER *hdr, DWORD *available, DWORD flags, DWORD_PTR ctx) { - ftp_file_t *file = (ftp_file_t*) hdr; + LPWININETFTPFILE file = (LPWININETFTPFILE) hdr; int retval, unread = 0; TRACE("(%p %p %x %lx)\n", file, available, flags, ctx); @@ -1230,7 +1230,7 @@ static DWORD FTPFILE_QueryDataAvailable(object_header_t *hdr, DWORD *available, } -static const object_vtbl_t FTPFILEVtbl = { +static const HANDLEHEADERVtbl FTPFILEVtbl = { FTPFILE_Destroy, NULL, FTPFILE_QueryOption, @@ -1253,14 +1253,14 @@ static const object_vtbl_t FTPFILEVtbl = { * NULL on failure * */ -HINTERNET FTP_FtpOpenFileW(ftp_session_t *lpwfs, +HINTERNET FTP_FtpOpenFileW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszFileName, DWORD fdwAccess, DWORD dwFlags, DWORD_PTR dwContext) { INT nDataSocket; BOOL bSuccess = FALSE; - ftp_file_t *lpwh = NULL; - appinfo_t *hIC = NULL; + LPWININETFTPFILE lpwh = NULL; + LPWININETAPPINFOW hIC = NULL; HINTERNET handle = NULL; TRACE("\n"); @@ -1282,7 +1282,7 @@ HINTERNET FTP_FtpOpenFileW(ftp_session_t *lpwfs, /* Get data socket to server */ if (bSuccess && FTP_GetDataSocket(lpwfs, &nDataSocket)) { - lpwh = HeapAlloc(GetProcessHeap(), 0, sizeof(ftp_file_t)); + lpwh = HeapAlloc(GetProcessHeap(), 0, sizeof(WININETFTPFILE)); lpwh->hdr.htype = WH_HFILE; lpwh->hdr.vtbl = &FTPFILEVtbl; lpwh->hdr.dwFlags = dwFlags; @@ -1355,7 +1355,7 @@ HINTERNET WINAPI FtpOpenFileA(HINTERNET hFtpSession, LPWSTR lpwzFileName; HINTERNET ret; - lpwzFileName = heap_strdupAtoW(lpszFileName); + lpwzFileName = lpszFileName?WININET_strdup_AtoW(lpszFileName):NULL; ret = FtpOpenFileW(hFtpSession, lpwzFileName, fdwAccess, dwFlags, dwContext); HeapFree(GetProcessHeap(), 0, lpwzFileName); return ret; @@ -1365,7 +1365,7 @@ HINTERNET WINAPI FtpOpenFileA(HINTERNET hFtpSession, static void AsyncFtpOpenFileProc(WORKREQUEST *workRequest) { struct WORKREQ_FTPOPENFILEW const *req = &workRequest->u.FtpOpenFileW; - ftp_session_t *lpwfs = (ftp_session_t*) workRequest->hdr; + LPWININETFTPSESSIONW lpwfs = (LPWININETFTPSESSIONW) workRequest->hdr; TRACE("%p\n", lpwfs); @@ -1388,14 +1388,14 @@ HINTERNET WINAPI FtpOpenFileW(HINTERNET hFtpSession, LPCWSTR lpszFileName, DWORD fdwAccess, DWORD dwFlags, DWORD_PTR dwContext) { - ftp_session_t *lpwfs; - appinfo_t *hIC = NULL; + LPWININETFTPSESSIONW lpwfs; + LPWININETAPPINFOW hIC = NULL; HINTERNET r = NULL; TRACE("(%p,%s,0x%08x,0x%08x,0x%08lx)\n", hFtpSession, debugstr_w(lpszFileName), fdwAccess, dwFlags, dwContext); - lpwfs = (ftp_session_t*) WININET_GetObject( hFtpSession ); + lpwfs = (LPWININETFTPSESSIONW) WININET_GetObject( hFtpSession ); if (!lpwfs) { INTERNET_SetLastError(ERROR_INVALID_HANDLE); @@ -1431,7 +1431,7 @@ HINTERNET WINAPI FtpOpenFileW(HINTERNET hFtpSession, workRequest.asyncproc = AsyncFtpOpenFileProc; workRequest.hdr = WININET_AddRef( &lpwfs->hdr ); req = &workRequest.u.FtpOpenFileW; - req->lpszFilename = heap_strdupW(lpszFileName); + req->lpszFilename = WININET_strdupW(lpszFileName); req->dwAccess = fdwAccess; req->dwFlags = dwFlags; req->dwContext = dwContext; @@ -1469,8 +1469,8 @@ BOOL WINAPI FtpGetFileA(HINTERNET hInternet, LPCSTR lpszRemoteFile, LPCSTR lpszN LPWSTR lpwzNewFile; BOOL ret; - lpwzRemoteFile = heap_strdupAtoW(lpszRemoteFile); - lpwzNewFile = heap_strdupAtoW(lpszNewFile); + lpwzRemoteFile = lpszRemoteFile?WININET_strdup_AtoW(lpszRemoteFile):NULL; + lpwzNewFile = lpszNewFile?WININET_strdup_AtoW(lpszNewFile):NULL; ret = FtpGetFileW(hInternet, lpwzRemoteFile, lpwzNewFile, fFailIfExists, dwLocalFlagsAttribute, dwInternetFlags, dwContext); HeapFree(GetProcessHeap(), 0, lpwzRemoteFile); @@ -1482,7 +1482,7 @@ BOOL WINAPI FtpGetFileA(HINTERNET hInternet, LPCSTR lpszRemoteFile, LPCSTR lpszN static void AsyncFtpGetFileProc(WORKREQUEST *workRequest) { struct WORKREQ_FTPGETFILEW const *req = &workRequest->u.FtpGetFileW; - ftp_session_t *lpwfs = (ftp_session_t*) workRequest->hdr; + LPWININETFTPSESSIONW lpwfs = (LPWININETFTPSESSIONW) workRequest->hdr; TRACE("%p\n", lpwfs); @@ -1508,8 +1508,8 @@ BOOL WINAPI FtpGetFileW(HINTERNET hInternet, LPCWSTR lpszRemoteFile, LPCWSTR lps BOOL fFailIfExists, DWORD dwLocalFlagsAttribute, DWORD dwInternetFlags, DWORD_PTR dwContext) { - ftp_session_t *lpwfs; - appinfo_t *hIC = NULL; + LPWININETFTPSESSIONW lpwfs; + LPWININETAPPINFOW hIC = NULL; BOOL r = FALSE; if (!lpszRemoteFile || !lpszNewFile) @@ -1518,7 +1518,7 @@ BOOL WINAPI FtpGetFileW(HINTERNET hInternet, LPCWSTR lpszRemoteFile, LPCWSTR lps return FALSE; } - lpwfs = (ftp_session_t*) WININET_GetObject( hInternet ); + lpwfs = (LPWININETFTPSESSIONW) WININET_GetObject( hInternet ); if (!lpwfs) { INTERNET_SetLastError(ERROR_INVALID_HANDLE); @@ -1552,8 +1552,8 @@ BOOL WINAPI FtpGetFileW(HINTERNET hInternet, LPCWSTR lpszRemoteFile, LPCWSTR lps workRequest.asyncproc = AsyncFtpGetFileProc; workRequest.hdr = WININET_AddRef( &lpwfs->hdr ); req = &workRequest.u.FtpGetFileW; - req->lpszRemoteFile = heap_strdupW(lpszRemoteFile); - req->lpszNewFile = heap_strdupW(lpszNewFile); + req->lpszRemoteFile = WININET_strdupW(lpszRemoteFile); + req->lpszNewFile = WININET_strdupW(lpszNewFile); req->dwLocalFlagsAttribute = dwLocalFlagsAttribute; req->fFailIfExists = fFailIfExists; req->dwFlags = dwInternetFlags; @@ -1584,13 +1584,13 @@ lend: * FALSE on failure * */ -static BOOL FTP_FtpGetFileW(ftp_session_t *lpwfs, LPCWSTR lpszRemoteFile, LPCWSTR lpszNewFile, +static BOOL FTP_FtpGetFileW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszRemoteFile, LPCWSTR lpszNewFile, BOOL fFailIfExists, DWORD dwLocalFlagsAttribute, DWORD dwInternetFlags, DWORD_PTR dwContext) { BOOL bSuccess = FALSE; HANDLE hFile; - appinfo_t *hIC = NULL; + LPWININETAPPINFOW hIC = NULL; TRACE("lpszRemoteFile(%s) lpszNewFile(%s)\n", debugstr_w(lpszRemoteFile), debugstr_w(lpszNewFile)); @@ -1676,7 +1676,7 @@ BOOL WINAPI FtpDeleteFileA(HINTERNET hFtpSession, LPCSTR lpszFileName) LPWSTR lpwzFileName; BOOL ret; - lpwzFileName = heap_strdupAtoW(lpszFileName); + lpwzFileName = lpszFileName?WININET_strdup_AtoW(lpszFileName):NULL; ret = FtpDeleteFileW(hFtpSession, lpwzFileName); HeapFree(GetProcessHeap(), 0, lpwzFileName); return ret; @@ -1685,7 +1685,7 @@ BOOL WINAPI FtpDeleteFileA(HINTERNET hFtpSession, LPCSTR lpszFileName) static void AsyncFtpDeleteFileProc(WORKREQUEST *workRequest) { struct WORKREQ_FTPDELETEFILEW const *req = &workRequest->u.FtpDeleteFileW; - ftp_session_t *lpwfs = (ftp_session_t*) workRequest->hdr; + LPWININETFTPSESSIONW lpwfs = (LPWININETFTPSESSIONW) workRequest->hdr; TRACE("%p\n", lpwfs); @@ -1705,11 +1705,11 @@ static void AsyncFtpDeleteFileProc(WORKREQUEST *workRequest) */ BOOL WINAPI FtpDeleteFileW(HINTERNET hFtpSession, LPCWSTR lpszFileName) { - ftp_session_t *lpwfs; - appinfo_t *hIC = NULL; + LPWININETFTPSESSIONW lpwfs; + LPWININETAPPINFOW hIC = NULL; BOOL r = FALSE; - lpwfs = (ftp_session_t*) WININET_GetObject( hFtpSession ); + lpwfs = (LPWININETFTPSESSIONW) WININET_GetObject( hFtpSession ); if (!lpwfs) { INTERNET_SetLastError(ERROR_INVALID_HANDLE); @@ -1743,7 +1743,7 @@ BOOL WINAPI FtpDeleteFileW(HINTERNET hFtpSession, LPCWSTR lpszFileName) workRequest.asyncproc = AsyncFtpDeleteFileProc; workRequest.hdr = WININET_AddRef( &lpwfs->hdr ); req = &workRequest.u.FtpDeleteFileW; - req->lpszFilename = heap_strdupW(lpszFileName); + req->lpszFilename = WININET_strdupW(lpszFileName); r = INTERNET_AsyncCall(&workRequest); } @@ -1768,11 +1768,11 @@ lend: * FALSE on failure * */ -BOOL FTP_FtpDeleteFileW(ftp_session_t *lpwfs, LPCWSTR lpszFileName) +BOOL FTP_FtpDeleteFileW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszFileName) { INT nResCode; BOOL bSuccess = FALSE; - appinfo_t *hIC = NULL; + LPWININETAPPINFOW hIC = NULL; TRACE("%p\n", lpwfs); @@ -1821,7 +1821,7 @@ BOOL WINAPI FtpRemoveDirectoryA(HINTERNET hFtpSession, LPCSTR lpszDirectory) LPWSTR lpwzDirectory; BOOL ret; - lpwzDirectory = heap_strdupAtoW(lpszDirectory); + lpwzDirectory = lpszDirectory?WININET_strdup_AtoW(lpszDirectory):NULL; ret = FtpRemoveDirectoryW(hFtpSession, lpwzDirectory); HeapFree(GetProcessHeap(), 0, lpwzDirectory); return ret; @@ -1830,7 +1830,7 @@ BOOL WINAPI FtpRemoveDirectoryA(HINTERNET hFtpSession, LPCSTR lpszDirectory) static void AsyncFtpRemoveDirectoryProc(WORKREQUEST *workRequest) { struct WORKREQ_FTPREMOVEDIRECTORYW const *req = &workRequest->u.FtpRemoveDirectoryW; - ftp_session_t *lpwfs = (ftp_session_t*) workRequest->hdr; + LPWININETFTPSESSIONW lpwfs = (LPWININETFTPSESSIONW) workRequest->hdr; TRACE("%p\n", lpwfs); @@ -1850,11 +1850,11 @@ static void AsyncFtpRemoveDirectoryProc(WORKREQUEST *workRequest) */ BOOL WINAPI FtpRemoveDirectoryW(HINTERNET hFtpSession, LPCWSTR lpszDirectory) { - ftp_session_t *lpwfs; - appinfo_t *hIC = NULL; + LPWININETFTPSESSIONW lpwfs; + LPWININETAPPINFOW hIC = NULL; BOOL r = FALSE; - lpwfs = (ftp_session_t*) WININET_GetObject( hFtpSession ); + lpwfs = (LPWININETFTPSESSIONW) WININET_GetObject( hFtpSession ); if (!lpwfs) { INTERNET_SetLastError(ERROR_INVALID_HANDLE); @@ -1888,7 +1888,7 @@ BOOL WINAPI FtpRemoveDirectoryW(HINTERNET hFtpSession, LPCWSTR lpszDirectory) workRequest.asyncproc = AsyncFtpRemoveDirectoryProc; workRequest.hdr = WININET_AddRef( &lpwfs->hdr ); req = &workRequest.u.FtpRemoveDirectoryW; - req->lpszDirectory = heap_strdupW(lpszDirectory); + req->lpszDirectory = WININET_strdupW(lpszDirectory); r = INTERNET_AsyncCall(&workRequest); } @@ -1913,11 +1913,11 @@ lend: * FALSE on failure * */ -BOOL FTP_FtpRemoveDirectoryW(ftp_session_t *lpwfs, LPCWSTR lpszDirectory) +BOOL FTP_FtpRemoveDirectoryW(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszDirectory) { INT nResCode; BOOL bSuccess = FALSE; - appinfo_t *hIC = NULL; + LPWININETAPPINFOW hIC = NULL; TRACE("\n"); @@ -1968,8 +1968,8 @@ BOOL WINAPI FtpRenameFileA(HINTERNET hFtpSession, LPCSTR lpszSrc, LPCSTR lpszDes LPWSTR lpwzDest; BOOL ret; - lpwzSrc = heap_strdupAtoW(lpszSrc); - lpwzDest = heap_strdupAtoW(lpszDest); + lpwzSrc = lpszSrc?WININET_strdup_AtoW(lpszSrc):NULL; + lpwzDest = lpszDest?WININET_strdup_AtoW(lpszDest):NULL; ret = FtpRenameFileW(hFtpSession, lpwzSrc, lpwzDest); HeapFree(GetProcessHeap(), 0, lpwzSrc); HeapFree(GetProcessHeap(), 0, lpwzDest); @@ -1979,7 +1979,7 @@ BOOL WINAPI FtpRenameFileA(HINTERNET hFtpSession, LPCSTR lpszSrc, LPCSTR lpszDes static void AsyncFtpRenameFileProc(WORKREQUEST *workRequest) { struct WORKREQ_FTPRENAMEFILEW const *req = &workRequest->u.FtpRenameFileW; - ftp_session_t *lpwfs = (ftp_session_t*) workRequest->hdr; + LPWININETFTPSESSIONW lpwfs = (LPWININETFTPSESSIONW) workRequest->hdr; TRACE("%p\n", lpwfs); @@ -2000,11 +2000,11 @@ static void AsyncFtpRenameFileProc(WORKREQUEST *workRequest) */ BOOL WINAPI FtpRenameFileW(HINTERNET hFtpSession, LPCWSTR lpszSrc, LPCWSTR lpszDest) { - ftp_session_t *lpwfs; - appinfo_t *hIC = NULL; + LPWININETFTPSESSIONW lpwfs; + LPWININETAPPINFOW hIC = NULL; BOOL r = FALSE; - lpwfs = (ftp_session_t*) WININET_GetObject( hFtpSession ); + lpwfs = (LPWININETFTPSESSIONW) WININET_GetObject( hFtpSession ); if (!lpwfs) { INTERNET_SetLastError(ERROR_INVALID_HANDLE); @@ -2038,8 +2038,8 @@ BOOL WINAPI FtpRenameFileW(HINTERNET hFtpSession, LPCWSTR lpszSrc, LPCWSTR lpszD workRequest.asyncproc = AsyncFtpRenameFileProc; workRequest.hdr = WININET_AddRef( &lpwfs->hdr ); req = &workRequest.u.FtpRenameFileW; - req->lpszSrcFile = heap_strdupW(lpszSrc); - req->lpszDestFile = heap_strdupW(lpszDest); + req->lpszSrcFile = WININET_strdupW(lpszSrc); + req->lpszDestFile = WININET_strdupW(lpszDest); r = INTERNET_AsyncCall(&workRequest); } @@ -2064,11 +2064,12 @@ lend: * FALSE on failure * */ -BOOL FTP_FtpRenameFileW(ftp_session_t *lpwfs, LPCWSTR lpszSrc, LPCWSTR lpszDest) +BOOL FTP_FtpRenameFileW( LPWININETFTPSESSIONW lpwfs, + LPCWSTR lpszSrc, LPCWSTR lpszDest) { INT nResCode; BOOL bSuccess = FALSE; - appinfo_t *hIC = NULL; + LPWININETAPPINFOW hIC = NULL; TRACE("\n"); @@ -2131,7 +2132,7 @@ BOOL WINAPI FtpCommandA( HINTERNET hConnect, BOOL fExpectResponse, DWORD dwFlags return FALSE; } - if (!(cmdW = heap_strdupAtoW(lpszCommand))) + if (!(cmdW = WININET_strdup_AtoW(lpszCommand))) { INTERNET_SetLastError(ERROR_OUTOFMEMORY); return FALSE; @@ -2150,7 +2151,7 @@ BOOL WINAPI FtpCommandW( HINTERNET hConnect, BOOL fExpectResponse, DWORD dwFlags LPCWSTR lpszCommand, DWORD_PTR dwContext, HINTERNET* phFtpCommand ) { BOOL r = FALSE; - ftp_session_t *lpwfs; + LPWININETFTPSESSIONW lpwfs; LPSTR cmd = NULL; DWORD len, nBytesSent= 0; INT nResCode, nRC = 0; @@ -2170,7 +2171,7 @@ BOOL WINAPI FtpCommandW( HINTERNET hConnect, BOOL fExpectResponse, DWORD dwFlags return FALSE; } - lpwfs = (ftp_session_t*) WININET_GetObject( hConnect ); + lpwfs = (LPWININETFTPSESSIONW) WININET_GetObject( hConnect ); if (!lpwfs) { INTERNET_SetLastError(ERROR_INVALID_HANDLE); @@ -2233,9 +2234,9 @@ lend: * * Deallocate session handle */ -static void FTPSESSION_Destroy(object_header_t *hdr) +static void FTPSESSION_Destroy(WININETHANDLEHEADER *hdr) { - ftp_session_t *lpwfs = (ftp_session_t*) hdr; + LPWININETFTPSESSIONW lpwfs = (LPWININETFTPSESSIONW) hdr; TRACE("\n"); @@ -2246,9 +2247,9 @@ static void FTPSESSION_Destroy(object_header_t *hdr) HeapFree(GetProcessHeap(), 0, lpwfs); } -static void FTPSESSION_CloseConnection(object_header_t *hdr) +static void FTPSESSION_CloseConnection(WININETHANDLEHEADER *hdr) { - ftp_session_t *lpwfs = (ftp_session_t*) hdr; + LPWININETFTPSESSIONW lpwfs = (LPWININETFTPSESSIONW) hdr; TRACE("\n"); @@ -2271,7 +2272,7 @@ static void FTPSESSION_CloseConnection(object_header_t *hdr) INTERNET_STATUS_CONNECTION_CLOSED, 0, 0); } -static DWORD FTPSESSION_QueryOption(object_header_t *hdr, DWORD option, void *buffer, DWORD *size, BOOL unicode) +static DWORD FTPSESSION_QueryOption(WININETHANDLEHEADER *hdr, DWORD option, void *buffer, DWORD *size, BOOL unicode) { switch(option) { case INTERNET_OPTION_HANDLE_TYPE: @@ -2288,7 +2289,7 @@ static DWORD FTPSESSION_QueryOption(object_header_t *hdr, DWORD option, void *bu return INET_QueryOption(option, buffer, size, unicode); } -static const object_vtbl_t FTPSESSIONVtbl = { +static const HANDLEHEADERVtbl FTPSESSIONVtbl = { FTPSESSION_Destroy, FTPSESSION_CloseConnection, FTPSESSION_QueryOption, @@ -2321,7 +2322,7 @@ static const object_vtbl_t FTPSESSIONVtbl = { * */ -HINTERNET FTP_Connect(appinfo_t *hIC, LPCWSTR lpszServerName, +HINTERNET FTP_Connect(LPWININETAPPINFOW hIC, LPCWSTR lpszServerName, INTERNET_PORT nServerPort, LPCWSTR lpszUserName, LPCWSTR lpszPassword, DWORD dwFlags, DWORD_PTR dwContext, DWORD dwInternalFlags) @@ -2338,7 +2339,7 @@ HINTERNET FTP_Connect(appinfo_t *hIC, LPCWSTR lpszServerName, INT nsocket = -1; UINT sock_namelen; BOOL bSuccess = FALSE; - ftp_session_t *lpwfs = NULL; + LPWININETFTPSESSIONW lpwfs = NULL; HINTERNET handle = NULL; TRACE("%p Server(%s) Port(%d) User(%s) Paswd(%s)\n", @@ -2353,7 +2354,7 @@ HINTERNET FTP_Connect(appinfo_t *hIC, LPCWSTR lpszServerName, goto lerror; } - lpwfs = HeapAlloc(GetProcessHeap(), 0, sizeof(ftp_session_t)); + lpwfs = HeapAlloc(GetProcessHeap(), 0, sizeof(WININETFTPSESSIONW)); if (NULL == lpwfs) { INTERNET_SetLastError(ERROR_OUTOFMEMORY); @@ -2398,7 +2399,7 @@ HINTERNET FTP_Connect(appinfo_t *hIC, LPCWSTR lpszServerName, WCHAR szPassword[MAX_PATH]; DWORD len = sizeof(szPassword); - lpwfs->lpszUserName = heap_strdupW(szDefaultUsername); + lpwfs->lpszUserName = WININET_strdupW(szDefaultUsername); RegOpenKeyW(HKEY_CURRENT_USER, szKey, &key); if (RegQueryValueExW(key, szValue, NULL, NULL, (LPBYTE)szPassword, &len)) { @@ -2411,11 +2412,15 @@ HINTERNET FTP_Connect(appinfo_t *hIC, LPCWSTR lpszServerName, RegCloseKey(key); TRACE("Password used for anonymous ftp : (%s)\n", debugstr_w(szPassword)); - lpwfs->lpszPassword = heap_strdupW(szPassword); + lpwfs->lpszPassword = WININET_strdupW(szPassword); } else { - lpwfs->lpszUserName = heap_strdupW(lpszUserName); - lpwfs->lpszPassword = heap_strdupW(lpszPassword ? lpszPassword : szEmpty); + lpwfs->lpszUserName = WININET_strdupW(lpszUserName); + + if (lpszPassword) + lpwfs->lpszPassword = WININET_strdupW(lpszPassword); + else + lpwfs->lpszPassword = WININET_strdupW(szEmpty); } /* Don't send a handle created callback if this handle was created with InternetOpenUrl */ @@ -2434,9 +2439,7 @@ HINTERNET FTP_Connect(appinfo_t *hIC, LPCWSTR lpszServerName, SendAsyncCallback(&hIC->hdr, dwContext, INTERNET_STATUS_RESOLVING_NAME, (LPWSTR) lpszServerName, strlenW(lpszServerName)); - sock_namelen = sizeof(socketAddr); - if (!GetAddress(lpszServerName, nServerPort, - (struct sockaddr *)&socketAddr, &sock_namelen)) + if (!GetAddress(lpszServerName, nServerPort, &socketAddr)) { INTERNET_SetLastError(ERROR_INTERNET_NAME_NOT_RESOLVED); goto lerror; @@ -2445,12 +2448,6 @@ HINTERNET FTP_Connect(appinfo_t *hIC, LPCWSTR lpszServerName, SendAsyncCallback(&hIC->hdr, dwContext, INTERNET_STATUS_NAME_RESOLVED, (LPWSTR) lpszServerName, strlenW(lpszServerName)); - if (socketAddr.sin_family != AF_INET) - { - WARN("unsupported address family %d\n", socketAddr.sin_family); - INTERNET_SetLastError(ERROR_INTERNET_CANNOT_CONNECT); - goto lerror; - } nsocket = socket(AF_INET,SOCK_STREAM,0); if (nsocket == -1) { @@ -2459,20 +2456,19 @@ HINTERNET FTP_Connect(appinfo_t *hIC, LPCWSTR lpszServerName, } SendAsyncCallback(&hIC->hdr, dwContext, INTERNET_STATUS_CONNECTING_TO_SERVER, - &socketAddr, sock_namelen); + &socketAddr, sizeof(struct sockaddr_in)); - if (connect(nsocket, (struct sockaddr *)&socketAddr, sock_namelen) < 0) + if (connect(nsocket, (struct sockaddr *)&socketAddr, sizeof(socketAddr)) < 0) { ERR("Unable to connect (%s)\n", strerror(errno)); INTERNET_SetLastError(ERROR_INTERNET_CANNOT_CONNECT); - closesocket(nsocket); } else { TRACE("Connected to server\n"); lpwfs->sndSocket = nsocket; SendAsyncCallback(&hIC->hdr, dwContext, INTERNET_STATUS_CONNECTED_TO_SERVER, - &socketAddr, sock_namelen); + &socketAddr, sizeof(struct sockaddr_in)); sock_namelen = sizeof(lpwfs->socketAddress); getsockname(nsocket, (struct sockaddr *) &lpwfs->socketAddress, &sock_namelen); @@ -2507,7 +2503,7 @@ lerror: * NULL on failure * */ -static BOOL FTP_ConnectToHost(ftp_session_t *lpwfs) +static BOOL FTP_ConnectToHost(LPWININETFTPSESSIONW lpwfs) { INT nResCode; BOOL bSuccess = FALSE; @@ -2551,7 +2547,7 @@ lend: * */ static BOOL FTP_SendCommandA(INT nSocket, FTP_COMMAND ftpCmd, LPCSTR lpszParam, - INTERNET_STATUS_CALLBACK lpfnStatusCB, object_header_t *hdr, DWORD_PTR dwContext) + INTERNET_STATUS_CALLBACK lpfnStatusCB, LPWININETHANDLEHEADER hdr, DWORD_PTR dwContext) { DWORD len; CHAR *buf; @@ -2606,10 +2602,10 @@ static BOOL FTP_SendCommandA(INT nSocket, FTP_COMMAND ftpCmd, LPCSTR lpszParam, * */ static BOOL FTP_SendCommand(INT nSocket, FTP_COMMAND ftpCmd, LPCWSTR lpszParam, - INTERNET_STATUS_CALLBACK lpfnStatusCB, object_header_t *hdr, DWORD_PTR dwContext) + INTERNET_STATUS_CALLBACK lpfnStatusCB, LPWININETHANDLEHEADER hdr, DWORD_PTR dwContext) { BOOL ret; - LPSTR lpszParamA = heap_strdupWtoA(lpszParam); + LPSTR lpszParamA = lpszParam?WININET_strdup_WtoA(lpszParam):NULL; ret = FTP_SendCommandA(nSocket, ftpCmd, lpszParamA, lpfnStatusCB, hdr, dwContext); HeapFree(GetProcessHeap(), 0, lpszParamA); return ret; @@ -2625,7 +2621,7 @@ static BOOL FTP_SendCommand(INT nSocket, FTP_COMMAND ftpCmd, LPCWSTR lpszParam, * 0 on failure * */ -INT FTP_ReceiveResponse(ftp_session_t *lpwfs, DWORD_PTR dwContext) +INT FTP_ReceiveResponse(LPWININETFTPSESSIONW lpwfs, DWORD_PTR dwContext) { LPSTR lpszResponse = INTERNET_GetResponseBuffer(); DWORD nRecv; @@ -2688,7 +2684,7 @@ lerror: * NULL on failure * */ -static BOOL FTP_SendPassword(ftp_session_t *lpwfs) +static BOOL FTP_SendPassword(LPWININETFTPSESSIONW lpwfs) { INT nResCode; BOOL bSuccess = FALSE; @@ -2728,7 +2724,7 @@ lend: * FALSE on failure * */ -static BOOL FTP_SendAccount(ftp_session_t *lpwfs) +static BOOL FTP_SendAccount(LPWININETFTPSESSIONW lpwfs) { INT nResCode; BOOL bSuccess = FALSE; @@ -2758,7 +2754,7 @@ lend: * FALSE on failure * */ -static BOOL FTP_SendStore(ftp_session_t *lpwfs, LPCWSTR lpszRemoteFile, DWORD dwType) +static BOOL FTP_SendStore(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszRemoteFile, DWORD dwType) { INT nResCode; BOOL bSuccess = FALSE; @@ -2805,10 +2801,10 @@ lend: * FALSE on failure * */ -static BOOL FTP_InitListenSocket(ftp_session_t *lpwfs) +static BOOL FTP_InitListenSocket(LPWININETFTPSESSIONW lpwfs) { BOOL bSuccess = FALSE; - socklen_t namelen = sizeof(lpwfs->lstnSocketAddress); + socklen_t namelen = sizeof(struct sockaddr_in); TRACE("\n"); @@ -2825,7 +2821,7 @@ static BOOL FTP_InitListenSocket(ftp_session_t *lpwfs) /* and get the system to assign us a port */ lpwfs->lstnSocketAddress.sin_port = htons(0); - if (bind(lpwfs->lstnSocket,(struct sockaddr *) &lpwfs->lstnSocketAddress, sizeof(lpwfs->lstnSocketAddress)) == -1) + if (bind(lpwfs->lstnSocket,(struct sockaddr *) &lpwfs->lstnSocketAddress, sizeof(struct sockaddr_in)) == -1) { TRACE("Unable to bind socket\n"); goto lend; @@ -2864,7 +2860,7 @@ lend: * (i.e. it sends it always), * so we probably don't want to do that either. */ -static BOOL FTP_SendType(ftp_session_t *lpwfs, DWORD dwType) +static BOOL FTP_SendType(LPWININETFTPSESSIONW lpwfs, DWORD dwType) { INT nResCode; WCHAR type[] = { 'I','\0' }; @@ -2902,7 +2898,7 @@ lend: * FALSE on failure * */ -static BOOL FTP_GetFileSize(ftp_session_t *lpwfs, LPCWSTR lpszRemoteFile, DWORD *dwSize) +static BOOL FTP_GetFileSize(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszRemoteFile, DWORD *dwSize) { INT nResCode; BOOL bSuccess = FALSE; @@ -2946,7 +2942,7 @@ lend: * FALSE on failure * */ -static BOOL FTP_SendPort(ftp_session_t *lpwfs) +static BOOL FTP_SendPort(LPWININETFTPSESSIONW lpwfs) { static const WCHAR szIPFormat[] = {'%','d',',','%','d',',','%','d',',','%','d',',','%','d',',','%','d','\0'}; INT nResCode; @@ -2990,7 +2986,7 @@ lend: * FALSE on failure * */ -static BOOL FTP_DoPassive(ftp_session_t *lpwfs) +static BOOL FTP_DoPassive(LPWININETFTPSESSIONW lpwfs) { INT nResCode; BOOL bSuccess = FALSE; @@ -3062,7 +3058,7 @@ lend: } -static BOOL FTP_SendPortOrPasv(ftp_session_t *lpwfs) +static BOOL FTP_SendPortOrPasv(LPWININETFTPSESSIONW lpwfs) { if (lpwfs->hdr.dwFlags & INTERNET_FLAG_PASSIVE) { @@ -3091,7 +3087,7 @@ static BOOL FTP_SendPortOrPasv(ftp_session_t *lpwfs) * FALSE on failure * */ -static BOOL FTP_GetDataSocket(ftp_session_t *lpwfs, LPINT nDataSocket) +static BOOL FTP_GetDataSocket(LPWININETFTPSESSIONW lpwfs, LPINT nDataSocket) { struct sockaddr_in saddr; socklen_t addrlen = sizeof(struct sockaddr); @@ -3121,7 +3117,7 @@ static BOOL FTP_GetDataSocket(ftp_session_t *lpwfs, LPINT nDataSocket) * FALSE on failure * */ -static BOOL FTP_SendData(ftp_session_t *lpwfs, INT nDataSocket, HANDLE hFile) +static BOOL FTP_SendData(LPWININETFTPSESSIONW lpwfs, INT nDataSocket, HANDLE hFile) { BY_HANDLE_FILE_INFORMATION fi; DWORD nBytesRead = 0; @@ -3202,7 +3198,7 @@ static BOOL FTP_SendData(ftp_session_t *lpwfs, INT nDataSocket, HANDLE hFile) * 0 on failure * */ -static BOOL FTP_SendRetrieve(ftp_session_t *lpwfs, LPCWSTR lpszRemoteFile, DWORD dwType) +static BOOL FTP_SendRetrieve(LPWININETFTPSESSIONW lpwfs, LPCWSTR lpszRemoteFile, DWORD dwType) { INT nResCode; BOOL ret; @@ -3248,7 +3244,7 @@ lend: * FALSE on failure * */ -static BOOL FTP_RetrieveFileData(ftp_session_t *lpwfs, INT nDataSocket, HANDLE hFile) +static BOOL FTP_RetrieveFileData(LPWININETFTPSESSIONW lpwfs, INT nDataSocket, HANDLE hFile) { DWORD nBytesWritten; INT nRC = 0; @@ -3288,7 +3284,7 @@ recv_end: * * Deallocate session handle */ -static void FTPFINDNEXT_Destroy(object_header_t *hdr) +static void FTPFINDNEXT_Destroy(WININETHANDLEHEADER *hdr) { LPWININETFTPFINDNEXTW lpwfn = (LPWININETFTPFINDNEXTW) hdr; DWORD i; @@ -3346,7 +3342,7 @@ static void FTPFINDNEXT_AsyncFindNextFileProc(WORKREQUEST *workRequest) FTPFINDNEXT_FindNextFileProc((WININETFTPFINDNEXTW*)workRequest->hdr, req->lpFindFileData); } -static DWORD FTPFINDNEXT_QueryOption(object_header_t *hdr, DWORD option, void *buffer, DWORD *size, BOOL unicode) +static DWORD FTPFINDNEXT_QueryOption(WININETHANDLEHEADER *hdr, DWORD option, void *buffer, DWORD *size, BOOL unicode) { switch(option) { case INTERNET_OPTION_HANDLE_TYPE: @@ -3363,7 +3359,7 @@ static DWORD FTPFINDNEXT_QueryOption(object_header_t *hdr, DWORD option, void *b return INET_QueryOption(option, buffer, size, unicode); } -static DWORD FTPFINDNEXT_FindNextFileW(object_header_t *hdr, void *data) +static DWORD FTPFINDNEXT_FindNextFileW(WININETHANDLEHEADER *hdr, void *data) { WININETFTPFINDNEXTW *find = (WININETFTPFINDNEXTW*)hdr; @@ -3385,7 +3381,7 @@ static DWORD FTPFINDNEXT_FindNextFileW(object_header_t *hdr, void *data) return FTPFINDNEXT_FindNextFileProc(find, data); } -static const object_vtbl_t FTPFINDNEXTVtbl = { +static const HANDLEHEADERVtbl FTPFINDNEXTVtbl = { FTPFINDNEXT_Destroy, NULL, FTPFINDNEXT_QueryOption, @@ -3408,7 +3404,7 @@ static const object_vtbl_t FTPFINDNEXTVtbl = { * NULL on failure * */ -static HINTERNET FTP_ReceiveFileList(ftp_session_t *lpwfs, INT nSocket, LPCWSTR lpszSearchFile, +static HINTERNET FTP_ReceiveFileList(LPWININETFTPSESSIONW lpwfs, INT nSocket, LPCWSTR lpszSearchFile, LPWIN32_FIND_DATAW lpFindFileData, DWORD_PTR dwContext) { DWORD dwSize = 0; @@ -3578,7 +3574,7 @@ static BOOL FTP_ParseNextFile(INT nSocket, LPCWSTR lpszSearchFile, LPFILEPROPERT pszToken = strtok(NULL, szSpace); if(!pszToken) continue; - lpfp->lpszName = heap_strdupAtoW(pszToken); + lpfp->lpszName = WININET_strdup_AtoW(pszToken); TRACE("File: %s\n", debugstr_w(lpfp->lpszName)); } /* NT way of parsing ... : @@ -3627,7 +3623,7 @@ static BOOL FTP_ParseNextFile(INT nSocket, LPCWSTR lpszSearchFile, LPFILEPROPERT pszToken = strtok(NULL, szSpace); if(!pszToken) continue; - lpfp->lpszName = heap_strdupAtoW(pszToken); + lpfp->lpszName = WININET_strdup_AtoW(pszToken); TRACE("Name: %s\n", debugstr_w(lpfp->lpszName)); } /* EPLF format - http://cr.yp.to/ftp/list/eplf.html */ @@ -3659,7 +3655,7 @@ static BOOL FTP_ParseNextFile(INT nSocket, LPCWSTR lpszSearchFile, LPFILEPROPERT * TRUE on success * FALSE on failure */ -static BOOL FTP_ParseDirectory(ftp_session_t *lpwfs, INT nSocket, LPCWSTR lpszSearchFile, +static BOOL FTP_ParseDirectory(LPWININETFTPSESSIONW lpwfs, INT nSocket, LPCWSTR lpszSearchFile, LPFILEPROPERTIESW *lpafp, LPDWORD dwfp) { BOOL bSuccess = TRUE; diff --git a/dlls/wininet/http.c b/dlls/wininet/http.c index 693a44fa297..e1a7ddc76d1 100644 --- a/dlls/wininet/http.c +++ b/dlls/wininet/http.c @@ -79,7 +79,6 @@ static const WCHAR szProxy_Authorization[] = { 'P','r','o','x','y','-','A','u',' static const WCHAR szStatus[] = { 'S','t','a','t','u','s',0 }; static const WCHAR szKeepAlive[] = {'K','e','e','p','-','A','l','i','v','e',0}; static const WCHAR szGET[] = { 'G','E','T', 0 }; -static const WCHAR szHEAD[] = { 'H','E','A','D', 0 }; static const WCHAR szCrLf[] = {'\r','\n', 0}; static const WCHAR szAccept[] = { 'A','c','c','e','p','t',0 }; @@ -177,23 +176,23 @@ struct gzip_stream_t { BOOL end_of_data; }; -static BOOL HTTP_OpenConnection(http_request_t *req); -static BOOL HTTP_GetResponseHeaders(http_request_t *req, BOOL clear); -static BOOL HTTP_ProcessHeader(http_request_t *req, LPCWSTR field, LPCWSTR value, DWORD dwModifier); +static BOOL HTTP_OpenConnection(LPWININETHTTPREQW lpwhr); +static BOOL HTTP_GetResponseHeaders(LPWININETHTTPREQW lpwhr, BOOL clear); +static BOOL HTTP_ProcessHeader(LPWININETHTTPREQW lpwhr, LPCWSTR field, LPCWSTR value, DWORD dwModifier); static LPWSTR * HTTP_InterpretHttpHeader(LPCWSTR buffer); -static BOOL HTTP_InsertCustomHeader(http_request_t *req, LPHTTPHEADERW lpHdr); -static INT HTTP_GetCustomHeaderIndex(http_request_t *req, LPCWSTR lpszField, INT index, BOOL Request); -static BOOL HTTP_DeleteCustomHeader(http_request_t *req, DWORD index); +static BOOL HTTP_InsertCustomHeader(LPWININETHTTPREQW lpwhr, LPHTTPHEADERW lpHdr); +static INT HTTP_GetCustomHeaderIndex(LPWININETHTTPREQW lpwhr, LPCWSTR lpszField, INT index, BOOL Request); +static BOOL HTTP_DeleteCustomHeader(LPWININETHTTPREQW lpwhr, DWORD index); static LPWSTR HTTP_build_req( LPCWSTR *list, int len ); -static BOOL HTTP_HttpQueryInfoW(http_request_t*, DWORD, LPVOID, LPDWORD, LPDWORD); -static LPWSTR HTTP_GetRedirectURL(http_request_t *req, LPCWSTR lpszUrl); -static BOOL HTTP_HandleRedirect(http_request_t *req, LPCWSTR lpszUrl); +static BOOL HTTP_HttpQueryInfoW(LPWININETHTTPREQW, DWORD, LPVOID, LPDWORD, LPDWORD); +static LPWSTR HTTP_GetRedirectURL(LPWININETHTTPREQW lpwhr, LPCWSTR lpszUrl); +static BOOL HTTP_HandleRedirect(LPWININETHTTPREQW lpwhr, LPCWSTR lpszUrl); static UINT HTTP_DecodeBase64(LPCWSTR base64, LPSTR bin); -static BOOL HTTP_VerifyValidHeader(http_request_t *req, LPCWSTR field); -static void HTTP_DrainContent(http_request_t *req); -static BOOL HTTP_FinishedReading(http_request_t *req); +static BOOL HTTP_VerifyValidHeader(LPWININETHTTPREQW lpwhr, LPCWSTR field); +static void HTTP_DrainContent(WININETHTTPREQW *req); +static BOOL HTTP_FinishedReading(LPWININETHTTPREQW lpwhr); -static LPHTTPHEADERW HTTP_GetHeader(http_request_t *req, LPCWSTR head) +static LPHTTPHEADERW HTTP_GetHeader(LPWININETHTTPREQW req, LPCWSTR head) { int HeaderIndex = 0; HeaderIndex = HTTP_GetCustomHeaderIndex(req, head, 0, TRUE); @@ -215,7 +214,7 @@ static void wininet_zfree(voidpf opaque, voidpf address) HeapFree(GetProcessHeap(), 0, address); } -static void init_gzip_stream(http_request_t *req) +static void init_gzip_stream(WININETHTTPREQW *req) { gzip_stream_t *gzip_stream; int zres; @@ -244,7 +243,7 @@ static void init_gzip_stream(http_request_t *req) #else -static void init_gzip_stream(http_request_t *req) +static void init_gzip_stream(WININETHTTPREQW *req) { ERR("gzip stream not supported, missing zlib.\n"); } @@ -252,7 +251,7 @@ static void init_gzip_stream(http_request_t *req) #endif /* set the request content length based on the headers */ -static DWORD set_content_length( http_request_t *lpwhr ) +static DWORD set_content_length( LPWININETHTTPREQW lpwhr ) { static const WCHAR szChunked[] = {'c','h','u','n','k','e','d',0}; WCHAR encoding[20]; @@ -357,7 +356,7 @@ static void HTTP_FreeTokens(LPWSTR * token_array) static void AsyncHttpSendRequestProc(WORKREQUEST *workRequest) { struct WORKREQ_HTTPSENDREQUESTW const *req = &workRequest->u.HttpSendRequestW; - http_request_t *lpwhr = (http_request_t*) workRequest->hdr; + LPWININETHTTPREQW lpwhr = (LPWININETHTTPREQW) workRequest->hdr; TRACE("%p\n", lpwhr); @@ -368,14 +367,14 @@ static void AsyncHttpSendRequestProc(WORKREQUEST *workRequest) HeapFree(GetProcessHeap(), 0, req->lpszHeader); } -static void HTTP_FixURL(http_request_t *lpwhr) +static void HTTP_FixURL( LPWININETHTTPREQW lpwhr) { static const WCHAR szSlash[] = { '/',0 }; static const WCHAR szHttp[] = { 'h','t','t','p',':','/','/', 0 }; /* If we don't have a path we set it to root */ if (NULL == lpwhr->lpszPath) - lpwhr->lpszPath = heap_strdupW(szSlash); + lpwhr->lpszPath = WININET_strdupW(szSlash); else /* remove \r and \n*/ { int nLen = strlenW(lpwhr->lpszPath); @@ -404,7 +403,7 @@ static void HTTP_FixURL(http_request_t *lpwhr) } } -static LPWSTR HTTP_BuildHeaderRequestString( http_request_t *lpwhr, LPCWSTR verb, LPCWSTR path, LPCWSTR version ) +static LPWSTR HTTP_BuildHeaderRequestString( LPWININETHTTPREQW lpwhr, LPCWSTR verb, LPCWSTR path, LPCWSTR version ) { LPWSTR requestString; DWORD len, n; @@ -463,7 +462,7 @@ static LPWSTR HTTP_BuildHeaderRequestString( http_request_t *lpwhr, LPCWSTR verb return requestString; } -static void HTTP_ProcessCookies( http_request_t *lpwhr ) +static void HTTP_ProcessCookies( LPWININETHTTPREQW lpwhr ) { int HeaderIndex; int numCookies = 0; @@ -499,7 +498,7 @@ static inline BOOL is_basic_auth_value( LPCWSTR pszAuthValue ) ((pszAuthValue[ARRAYSIZE(szBasic)] == ' ') || !pszAuthValue[ARRAYSIZE(szBasic)]); } -static BOOL HTTP_DoAuthorization( http_request_t *lpwhr, LPCWSTR pszAuthValue, +static BOOL HTTP_DoAuthorization( LPWININETHTTPREQW lpwhr, LPCWSTR pszAuthValue, struct HttpAuthInfo **ppAuthInfo, LPWSTR domain_and_username, LPWSTR password ) { @@ -529,7 +528,7 @@ static BOOL HTTP_DoAuthorization( http_request_t *lpwhr, LPCWSTR pszAuthValue, if (is_basic_auth_value(pszAuthValue)) { static const WCHAR szBasic[] = {'B','a','s','i','c',0}; - pAuthInfo->scheme = heap_strdupW(szBasic); + pAuthInfo->scheme = WININET_strdupW(szBasic); if (!pAuthInfo->scheme) { HeapFree(GetProcessHeap(), 0, pAuthInfo); @@ -541,7 +540,7 @@ static BOOL HTTP_DoAuthorization( http_request_t *lpwhr, LPCWSTR pszAuthValue, PVOID pAuthData; SEC_WINNT_AUTH_IDENTITY_W nt_auth_identity; - pAuthInfo->scheme = heap_strdupW(pszAuthValue); + pAuthInfo->scheme = WININET_strdupW(pszAuthValue); if (!pAuthInfo->scheme) { HeapFree(GetProcessHeap(), 0, pAuthInfo); @@ -714,7 +713,7 @@ static BOOL HTTP_DoAuthorization( http_request_t *lpwhr, LPCWSTR pszAuthValue, /*********************************************************************** * HTTP_HttpAddRequestHeadersW (internal) */ -static BOOL HTTP_HttpAddRequestHeadersW(http_request_t *lpwhr, +static BOOL HTTP_HttpAddRequestHeadersW(LPWININETHTTPREQW lpwhr, LPCWSTR lpszHeader, DWORD dwHeaderLength, DWORD dwModifier) { LPWSTR lpszStart; @@ -801,14 +800,14 @@ BOOL WINAPI HttpAddRequestHeadersW(HINTERNET hHttpRequest, LPCWSTR lpszHeader, DWORD dwHeaderLength, DWORD dwModifier) { BOOL bSuccess = FALSE; - http_request_t *lpwhr; + LPWININETHTTPREQW lpwhr; TRACE("%p, %s, %i, %i\n", hHttpRequest, debugstr_wn(lpszHeader, dwHeaderLength), dwHeaderLength, dwModifier); if (!lpszHeader) return TRUE; - lpwhr = (http_request_t*) WININET_GetObject( hHttpRequest ); + lpwhr = (LPWININETHTTPREQW) WININET_GetObject( hHttpRequest ); if (NULL == lpwhr || lpwhr->hdr.htype != WH_HHTTPREQ) { INTERNET_SetLastError(ERROR_INTERNET_INCORRECT_HANDLE_TYPE); @@ -878,7 +877,7 @@ BOOL WINAPI HttpEndRequestA(HINTERNET hRequest, return HttpEndRequestW(hRequest, NULL, dwFlags, dwContext); } -static BOOL HTTP_HttpEndRequestW(http_request_t *lpwhr, DWORD dwFlags, DWORD_PTR dwContext) +static BOOL HTTP_HttpEndRequestW(LPWININETHTTPREQW lpwhr, DWORD dwFlags, DWORD_PTR dwContext) { BOOL rc = FALSE; INT responseLen; @@ -910,11 +909,9 @@ static BOOL HTTP_HttpEndRequestW(http_request_t *lpwhr, DWORD dwFlags, DWORD_PTR dwBufferSize=sizeof(szNewLocation); if (HTTP_HttpQueryInfoW(lpwhr, HTTP_QUERY_LOCATION, szNewLocation, &dwBufferSize, NULL)) { - if (strcmpW(lpwhr->lpszVerb, szGET) && strcmpW(lpwhr->lpszVerb, szHEAD)) - { - HeapFree(GetProcessHeap(), 0, lpwhr->lpszVerb); - lpwhr->lpszVerb = heap_strdupW(szGET); - } + /* redirects are always GETs */ + HeapFree(GetProcessHeap(), 0, lpwhr->lpszVerb); + lpwhr->lpszVerb = WININET_strdupW(szGET); HTTP_DrainContent(lpwhr); if ((new_url = HTTP_GetRedirectURL( lpwhr, szNewLocation ))) { @@ -941,7 +938,7 @@ static BOOL HTTP_HttpEndRequestW(http_request_t *lpwhr, DWORD dwFlags, DWORD_PTR static void AsyncHttpEndRequestProc(WORKREQUEST *work) { struct WORKREQ_HTTPENDREQUESTW const *req = &work->u.HttpEndRequestW; - http_request_t *lpwhr = (http_request_t*)work->hdr; + LPWININETHTTPREQW lpwhr = (LPWININETHTTPREQW)work->hdr; TRACE("%p\n", lpwhr); @@ -962,7 +959,7 @@ BOOL WINAPI HttpEndRequestW(HINTERNET hRequest, LPINTERNET_BUFFERSW lpBuffersOut, DWORD dwFlags, DWORD_PTR dwContext) { BOOL rc = FALSE; - http_request_t *lpwhr; + LPWININETHTTPREQW lpwhr; TRACE("-->\n"); @@ -972,7 +969,7 @@ BOOL WINAPI HttpEndRequestW(HINTERNET hRequest, return FALSE; } - lpwhr = (http_request_t*) WININET_GetObject( hRequest ); + lpwhr = (LPWININETHTTPREQW) WININET_GetObject( hRequest ); if (NULL == lpwhr || lpwhr->hdr.htype != WH_HHTTPREQ) { @@ -1021,7 +1018,7 @@ HINTERNET WINAPI HttpOpenRequestW(HINTERNET hHttpSession, LPCWSTR lpszReferrer , LPCWSTR *lpszAcceptTypes, DWORD dwFlags, DWORD_PTR dwContext) { - http_session_t *lpwhs; + LPWININETHTTPSESSIONW lpwhs; HINTERNET handle = NULL; TRACE("(%p, %s, %s, %s, %s, %p, %08x, %08lx)\n", hHttpSession, @@ -1035,7 +1032,7 @@ HINTERNET WINAPI HttpOpenRequestW(HINTERNET hHttpSession, TRACE("\taccept type: %s\n",debugstr_w(lpszAcceptTypes[i])); } - lpwhs = (http_session_t*) WININET_GetObject( hHttpSession ); + lpwhs = (LPWININETHTTPSESSIONW) WININET_GetObject( hHttpSession ); if (NULL == lpwhs || lpwhs->hdr.htype != WH_HHTTPSESSION) { INTERNET_SetLastError(ERROR_INTERNET_INCORRECT_HANDLE_TYPE); @@ -1077,7 +1074,7 @@ HINTERNET WINAPI HttpOpenRequestA(HINTERNET hHttpSession, { LPWSTR szVerb = NULL, szObjectName = NULL; LPWSTR szVersion = NULL, szReferrer = NULL, *szAcceptTypes = NULL; - INT acceptTypesCount; + INT len, acceptTypesCount; HINTERNET rc = FALSE; LPCSTR *types; @@ -1088,30 +1085,38 @@ HINTERNET WINAPI HttpOpenRequestA(HINTERNET hHttpSession, if (lpszVerb) { - szVerb = heap_strdupAtoW(lpszVerb); + len = MultiByteToWideChar(CP_ACP, 0, lpszVerb, -1, NULL, 0 ); + szVerb = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR) ); if ( !szVerb ) goto end; + MultiByteToWideChar(CP_ACP, 0, lpszVerb, -1, szVerb, len); } if (lpszObjectName) { - szObjectName = heap_strdupAtoW(lpszObjectName); + len = MultiByteToWideChar(CP_ACP, 0, lpszObjectName, -1, NULL, 0 ); + szObjectName = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR) ); if ( !szObjectName ) goto end; + MultiByteToWideChar(CP_ACP, 0, lpszObjectName, -1, szObjectName, len ); } if (lpszVersion) { - szVersion = heap_strdupAtoW(lpszVersion); + len = MultiByteToWideChar(CP_ACP, 0, lpszVersion, -1, NULL, 0 ); + szVersion = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); if ( !szVersion ) goto end; + MultiByteToWideChar(CP_ACP, 0, lpszVersion, -1, szVersion, len ); } if (lpszReferrer) { - szReferrer = heap_strdupAtoW(lpszReferrer); + len = MultiByteToWideChar(CP_ACP, 0, lpszReferrer, -1, NULL, 0 ); + szReferrer = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); if ( !szReferrer ) goto end; + MultiByteToWideChar(CP_ACP, 0, lpszReferrer, -1, szReferrer, len ); } if (lpszAcceptTypes) @@ -1146,7 +1151,13 @@ HINTERNET WINAPI HttpOpenRequestA(HINTERNET hHttpSession, __TRY { if (*types && **types) - szAcceptTypes[acceptTypesCount++] = heap_strdupAtoW(*types); + { + len = MultiByteToWideChar(CP_ACP, 0, *types, -1, NULL, 0 ); + szAcceptTypes[acceptTypesCount] = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); + + MultiByteToWideChar(CP_ACP, 0, *types, -1, szAcceptTypes[acceptTypesCount], len); + acceptTypesCount++; + } } __EXCEPT_PAGE_FAULT { @@ -1318,7 +1329,7 @@ static UINT HTTP_DecodeBase64( LPCWSTR base64, LPSTR bin ) * * Insert or delete the authorization field in the request header. */ -static BOOL HTTP_InsertAuthorization( http_request_t *lpwhr, struct HttpAuthInfo *pAuthInfo, LPCWSTR header ) +static BOOL HTTP_InsertAuthorization( LPWININETHTTPREQW lpwhr, struct HttpAuthInfo *pAuthInfo, LPCWSTR header ) { if (pAuthInfo) { @@ -1361,7 +1372,7 @@ static BOOL HTTP_InsertAuthorization( http_request_t *lpwhr, struct HttpAuthInfo return TRUE; } -static WCHAR *HTTP_BuildProxyRequestUrl(http_request_t *req) +static WCHAR *HTTP_BuildProxyRequestUrl(WININETHTTPREQW *req) { WCHAR new_location[INTERNET_MAX_URL_LENGTH], *url; DWORD size; @@ -1377,7 +1388,7 @@ static WCHAR *HTTP_BuildProxyRequestUrl(http_request_t *req) static const WCHAR slash[] = { '/',0 }; static const WCHAR format[] = { 'h','t','t','p',':','/','/','%','s',':','%','d',0 }; static const WCHAR formatSSL[] = { 'h','t','t','p','s',':','/','/','%','s',':','%','d',0 }; - http_session_t *session = req->lpHttpSession; + WININETHTTPSESSIONW *session = req->lpHttpSession; size = 16; /* "https://" + sizeof(port#) + ":/\0" */ size += strlenW( session->lpszHostName ) + strlenW( req->lpszPath ); @@ -1398,7 +1409,8 @@ static WCHAR *HTTP_BuildProxyRequestUrl(http_request_t *req) /*********************************************************************** * HTTP_DealWithProxy */ -static BOOL HTTP_DealWithProxy(appinfo_t *hIC, http_session_t *lpwhs, http_request_t *lpwhr) +static BOOL HTTP_DealWithProxy( LPWININETAPPINFOW hIC, + LPWININETHTTPSESSIONW lpwhs, LPWININETHTTPREQW lpwhr) { WCHAR buf[MAXHOSTNAME]; WCHAR proxy[MAXHOSTNAME + 15]; /* 15 == "http://" + sizeof(port#) + ":/\0" */ @@ -1429,50 +1441,32 @@ static BOOL HTTP_DealWithProxy(appinfo_t *hIC, http_session_t *lpwhs, http_reque UrlComponents.nPort = INTERNET_DEFAULT_HTTP_PORT; HeapFree(GetProcessHeap(), 0, lpwhs->lpszServerName); - lpwhs->lpszServerName = heap_strdupW(UrlComponents.lpszHostName); + lpwhs->lpszServerName = WININET_strdupW(UrlComponents.lpszHostName); lpwhs->nServerPort = UrlComponents.nPort; TRACE("proxy server=%s port=%d\n", debugstr_w(lpwhs->lpszServerName), lpwhs->nServerPort); return TRUE; } -#ifndef INET6_ADDRSTRLEN -#define INET6_ADDRSTRLEN 46 -#endif - -static BOOL HTTP_ResolveName(http_request_t *lpwhr) +static BOOL HTTP_ResolveName(LPWININETHTTPREQW lpwhr) { - char szaddr[INET6_ADDRSTRLEN]; - http_session_t *lpwhs = lpwhr->lpHttpSession; - const void *addr; + char szaddr[32]; + LPWININETHTTPSESSIONW lpwhs = lpwhr->lpHttpSession; INTERNET_SendCallback(&lpwhr->hdr, lpwhr->hdr.dwContext, INTERNET_STATUS_RESOLVING_NAME, lpwhs->lpszServerName, strlenW(lpwhs->lpszServerName)+1); - lpwhs->sa_len = sizeof(lpwhs->socketAddress); if (!GetAddress(lpwhs->lpszServerName, lpwhs->nServerPort, - (struct sockaddr *)&lpwhs->socketAddress, &lpwhs->sa_len)) + &lpwhs->socketAddress)) { INTERNET_SetLastError(ERROR_INTERNET_NAME_NOT_RESOLVED); return FALSE; } - switch (lpwhs->socketAddress.ss_family) - { - case AF_INET: - addr = &((struct sockaddr_in *)&lpwhs->socketAddress)->sin_addr; - break; - case AF_INET6: - addr = &((struct sockaddr_in6 *)&lpwhs->socketAddress)->sin6_addr; - break; - default: - WARN("unsupported family %d\n", lpwhs->socketAddress.ss_family); - INTERNET_SetLastError(ERROR_INTERNET_NAME_NOT_RESOLVED); - return FALSE; - } - inet_ntop(lpwhs->socketAddress.ss_family, addr, szaddr, sizeof(szaddr)); + inet_ntop(lpwhs->socketAddress.sin_family, &lpwhs->socketAddress.sin_addr, + szaddr, sizeof(szaddr)); INTERNET_SendCallback(&lpwhr->hdr, lpwhr->hdr.dwContext, INTERNET_STATUS_NAME_RESOLVED, szaddr, strlen(szaddr)+1); @@ -1488,9 +1482,9 @@ static BOOL HTTP_ResolveName(http_request_t *lpwhr) * Deallocate request handle * */ -static void HTTPREQ_Destroy(object_header_t *hdr) +static void HTTPREQ_Destroy(WININETHANDLEHEADER *hdr) { - http_request_t *lpwhr = (http_request_t*) hdr; + LPWININETHTTPREQW lpwhr = (LPWININETHTTPREQW) hdr; DWORD i; TRACE("\n"); @@ -1498,7 +1492,10 @@ static void HTTPREQ_Destroy(object_header_t *hdr) if(lpwhr->hCacheFile) CloseHandle(lpwhr->hCacheFile); - HeapFree(GetProcessHeap(), 0, lpwhr->lpszCacheFile); + if(lpwhr->lpszCacheFile) { + DeleteFileW(lpwhr->lpszCacheFile); /* FIXME */ + HeapFree(GetProcessHeap(), 0, lpwhr->lpszCacheFile); + } DeleteCriticalSection( &lpwhr->read_section ); WININET_Release(&lpwhr->lpHttpSession->hdr); @@ -1545,9 +1542,9 @@ static void HTTPREQ_Destroy(object_header_t *hdr) HeapFree(GetProcessHeap(), 0, lpwhr); } -static void HTTPREQ_CloseConnection(object_header_t *hdr) +static void HTTPREQ_CloseConnection(WININETHANDLEHEADER *hdr) { - http_request_t *lpwhr = (http_request_t*) hdr; + LPWININETHTTPREQW lpwhr = (LPWININETHTTPREQW) hdr; TRACE("%p\n",lpwhr); @@ -1571,7 +1568,7 @@ static void HTTPREQ_CloseConnection(object_header_t *hdr) INTERNET_STATUS_CONNECTION_CLOSED, 0, 0); } -static BOOL HTTP_GetRequestURL(http_request_t *req, LPWSTR buf) +static BOOL HTTP_GetRequestURL(WININETHTTPREQW *req, LPWSTR buf) { LPHTTPHEADERW host_header; @@ -1585,28 +1582,11 @@ static BOOL HTTP_GetRequestURL(http_request_t *req, LPWSTR buf) return TRUE; } -static DWORD HTTPREQ_QueryOption(object_header_t *hdr, DWORD option, void *buffer, DWORD *size, BOOL unicode) +static DWORD HTTPREQ_QueryOption(WININETHANDLEHEADER *hdr, DWORD option, void *buffer, DWORD *size, BOOL unicode) { - http_request_t *req = (http_request_t*)hdr; + WININETHTTPREQW *req = (WININETHTTPREQW*)hdr; switch(option) { - case INTERNET_OPTION_SECURITY_FLAGS: - { - http_session_t *lpwhs; - lpwhs = req->lpHttpSession; - - if (*size < sizeof(ULONG)) - return ERROR_INSUFFICIENT_BUFFER; - - *size = sizeof(DWORD); - if (lpwhs->hdr.dwFlags & INTERNET_FLAG_SECURE) - *(DWORD*)buffer = SECURITY_FLAG_SECURE; - else - *(DWORD*)buffer = 0; - FIXME("Semi-STUB INTERNET_OPTION_SECURITY_FLAGS: %x\n",*(DWORD*)buffer); - return ERROR_SUCCESS; - } - case INTERNET_OPTION_HANDLE_TYPE: TRACE("INTERNET_OPTION_HANDLE_TYPE\n"); @@ -1784,9 +1764,9 @@ static DWORD HTTPREQ_QueryOption(object_header_t *hdr, DWORD option, void *buffe return INET_QueryOption(option, buffer, size, unicode); } -static DWORD HTTPREQ_SetOption(object_header_t *hdr, DWORD option, void *buffer, DWORD size) +static DWORD HTTPREQ_SetOption(WININETHANDLEHEADER *hdr, DWORD option, void *buffer, DWORD size) { - http_request_t *req = (http_request_t*)hdr; + WININETHTTPREQW *req = (WININETHTTPREQW*)hdr; switch(option) { case INTERNET_OPTION_SEND_TIMEOUT: @@ -1801,12 +1781,12 @@ static DWORD HTTPREQ_SetOption(object_header_t *hdr, DWORD option, void *buffer, case INTERNET_OPTION_USERNAME: HeapFree(GetProcessHeap(), 0, req->lpHttpSession->lpszUserName); - if (!(req->lpHttpSession->lpszUserName = heap_strdupW(buffer))) return ERROR_OUTOFMEMORY; + if (!(req->lpHttpSession->lpszUserName = WININET_strdupW(buffer))) return ERROR_OUTOFMEMORY; return ERROR_SUCCESS; case INTERNET_OPTION_PASSWORD: HeapFree(GetProcessHeap(), 0, req->lpHttpSession->lpszPassword); - if (!(req->lpHttpSession->lpszPassword = heap_strdupW(buffer))) return ERROR_OUTOFMEMORY; + if (!(req->lpHttpSession->lpszPassword = WININET_strdupW(buffer))) return ERROR_OUTOFMEMORY; return ERROR_SUCCESS; case INTERNET_OPTION_HTTP_DECODING: if(size != sizeof(BOOL)) @@ -1819,7 +1799,7 @@ static DWORD HTTPREQ_SetOption(object_header_t *hdr, DWORD option, void *buffer, } /* read some more data into the read buffer (the read section must be held) */ -static BOOL read_more_data( http_request_t *req, int maxlen ) +static BOOL read_more_data( WININETHTTPREQW *req, int maxlen ) { int len; @@ -1842,13 +1822,13 @@ static BOOL read_more_data( http_request_t *req, int maxlen ) } /* remove some amount of data from the read buffer (the read section must be held) */ -static void remove_data( http_request_t *req, int count ) +static void remove_data( WININETHTTPREQW *req, int count ) { if (!(req->read_size -= count)) req->read_pos = 0; else req->read_pos += count; } -static BOOL read_line( http_request_t *req, LPSTR buffer, DWORD *len ) +static BOOL read_line( WININETHTTPREQW *req, LPSTR buffer, DWORD *len ) { int count, bytes_read, pos = 0; @@ -1891,7 +1871,7 @@ static BOOL read_line( http_request_t *req, LPSTR buffer, DWORD *len ) } /* discard data contents until we reach end of line (the read section must be held) */ -static BOOL discard_eol( http_request_t *req ) +static BOOL discard_eol( WININETHTTPREQW *req ) { do { @@ -1908,7 +1888,7 @@ static BOOL discard_eol( http_request_t *req ) } /* read the size of the next chunk (the read section must be held) */ -static BOOL start_next_chunk( http_request_t *req ) +static BOOL start_next_chunk( WININETHTTPREQW *req ) { DWORD chunk_size = 0; @@ -1948,7 +1928,7 @@ static BOOL start_next_chunk( http_request_t *req ) } /* check if we have reached the end of the data to read (the read section must be held) */ -static BOOL end_of_read_data( http_request_t *req ) +static BOOL end_of_read_data( WININETHTTPREQW *req ) { if (req->gzip_stream) return req->gzip_stream->end_of_data && !req->gzip_stream->buf_size; if (req->read_chunked) return (req->dwContentLength == 0); @@ -1957,7 +1937,7 @@ static BOOL end_of_read_data( http_request_t *req ) } /* fetch some more data into the read buffer (the read section must be held) */ -static BOOL refill_buffer( http_request_t *req ) +static BOOL refill_buffer( WININETHTTPREQW *req ) { int len = sizeof(req->read_buf); @@ -1974,7 +1954,7 @@ static BOOL refill_buffer( http_request_t *req ) return TRUE; } -static DWORD read_gzip_data(http_request_t *req, BYTE *buf, int size, BOOL sync, int *read_ret) +static DWORD read_gzip_data(WININETHTTPREQW *req, BYTE *buf, int size, BOOL sync, int *read_ret) { DWORD ret = ERROR_SUCCESS; int read = 0; @@ -2012,7 +1992,7 @@ static DWORD read_gzip_data(http_request_t *req, BYTE *buf, int size, BOOL sync, return ret; } -static void refill_gzip_buffer(http_request_t *req) +static void refill_gzip_buffer(WININETHTTPREQW *req) { DWORD res; int len; @@ -2033,7 +2013,7 @@ static void refill_gzip_buffer(http_request_t *req) } /* return the size of data available to be read immediately (the read section must be held) */ -static DWORD get_avail_data( http_request_t *req ) +static DWORD get_avail_data( WININETHTTPREQW *req ) { if (req->gzip_stream) { refill_gzip_buffer(req); @@ -2044,7 +2024,7 @@ static DWORD get_avail_data( http_request_t *req ) return min( req->read_size, req->dwContentLength - req->dwContentRead ); } -static void HTTP_ReceiveRequestData(http_request_t *req, BOOL first_notif) +static void HTTP_ReceiveRequestData(WININETHTTPREQW *req, BOOL first_notif) { INTERNET_ASYNC_RESULT iar; @@ -2065,7 +2045,7 @@ static void HTTP_ReceiveRequestData(http_request_t *req, BOOL first_notif) } /* read data from the http connection (the read section must be held) */ -static DWORD HTTPREQ_Read(http_request_t *req, void *buffer, DWORD size, DWORD *read, BOOL sync) +static DWORD HTTPREQ_Read(WININETHTTPREQW *req, void *buffer, DWORD size, DWORD *read, BOOL sync) { BOOL finished_reading = FALSE; int len, bytes_read = 0; @@ -2136,16 +2116,16 @@ done: } -static DWORD HTTPREQ_ReadFile(object_header_t *hdr, void *buffer, DWORD size, DWORD *read) +static DWORD HTTPREQ_ReadFile(WININETHANDLEHEADER *hdr, void *buffer, DWORD size, DWORD *read) { - http_request_t *req = (http_request_t*)hdr; + WININETHTTPREQW *req = (WININETHTTPREQW*)hdr; return HTTPREQ_Read(req, buffer, size, read, TRUE); } static void HTTPREQ_AsyncReadFileExAProc(WORKREQUEST *workRequest) { struct WORKREQ_INTERNETREADFILEEXA const *data = &workRequest->u.InternetReadFileExA; - http_request_t *req = (http_request_t*)workRequest->hdr; + WININETHTTPREQW *req = (WININETHTTPREQW*)workRequest->hdr; INTERNET_ASYNC_RESULT iar; DWORD res; @@ -2162,10 +2142,11 @@ static void HTTPREQ_AsyncReadFileExAProc(WORKREQUEST *workRequest) sizeof(INTERNET_ASYNC_RESULT)); } -static DWORD HTTPREQ_ReadFileExA(object_header_t *hdr, INTERNET_BUFFERSA *buffers, +static DWORD HTTPREQ_ReadFileExA(WININETHANDLEHEADER *hdr, INTERNET_BUFFERSA *buffers, DWORD flags, DWORD_PTR context) { - http_request_t *req = (http_request_t*)hdr; + + WININETHTTPREQW *req = (WININETHTTPREQW*)hdr; DWORD res; if (flags & ~(IRF_ASYNC|IRF_NO_WAIT)) @@ -2217,7 +2198,7 @@ done: static void HTTPREQ_AsyncReadFileExWProc(WORKREQUEST *workRequest) { struct WORKREQ_INTERNETREADFILEEXW const *data = &workRequest->u.InternetReadFileExW; - http_request_t *req = (http_request_t*)workRequest->hdr; + WININETHTTPREQW *req = (WININETHTTPREQW*)workRequest->hdr; INTERNET_ASYNC_RESULT iar; DWORD res; @@ -2234,11 +2215,11 @@ static void HTTPREQ_AsyncReadFileExWProc(WORKREQUEST *workRequest) sizeof(INTERNET_ASYNC_RESULT)); } -static DWORD HTTPREQ_ReadFileExW(object_header_t *hdr, INTERNET_BUFFERSW *buffers, +static DWORD HTTPREQ_ReadFileExW(WININETHANDLEHEADER *hdr, INTERNET_BUFFERSW *buffers, DWORD flags, DWORD_PTR context) { - http_request_t *req = (http_request_t*)hdr; + WININETHTTPREQW *req = (WININETHTTPREQW*)hdr; DWORD res; if (flags & ~(IRF_ASYNC|IRF_NO_WAIT)) @@ -2287,10 +2268,10 @@ done: return res; } -static BOOL HTTPREQ_WriteFile(object_header_t *hdr, const void *buffer, DWORD size, DWORD *written) +static BOOL HTTPREQ_WriteFile(WININETHANDLEHEADER *hdr, const void *buffer, DWORD size, DWORD *written) { BOOL ret; - http_request_t *lpwhr = (http_request_t*)hdr; + LPWININETHTTPREQW lpwhr = (LPWININETHTTPREQW)hdr; INTERNET_SendCallback(&lpwhr->hdr, lpwhr->hdr.dwContext, INTERNET_STATUS_SENDING_REQUEST, NULL, 0); @@ -2304,14 +2285,14 @@ static BOOL HTTPREQ_WriteFile(object_header_t *hdr, const void *buffer, DWORD si static void HTTPREQ_AsyncQueryDataAvailableProc(WORKREQUEST *workRequest) { - http_request_t *req = (http_request_t*)workRequest->hdr; + WININETHTTPREQW *req = (WININETHTTPREQW*)workRequest->hdr; HTTP_ReceiveRequestData(req, FALSE); } -static DWORD HTTPREQ_QueryDataAvailable(object_header_t *hdr, DWORD *available, DWORD flags, DWORD_PTR ctx) +static DWORD HTTPREQ_QueryDataAvailable(WININETHANDLEHEADER *hdr, DWORD *available, DWORD flags, DWORD_PTR ctx) { - http_request_t *req = (http_request_t*)hdr; + WININETHTTPREQW *req = (WININETHTTPREQW*)hdr; TRACE("(%p %p %x %lx)\n", req, available, flags, ctx); @@ -2356,7 +2337,7 @@ done: return ERROR_SUCCESS; } -static const object_vtbl_t HTTPREQVtbl = { +static const HANDLEHEADERVtbl HTTPREQVtbl = { HTTPREQ_Destroy, HTTPREQ_CloseConnection, HTTPREQ_QueryOption, @@ -2379,13 +2360,13 @@ static const object_vtbl_t HTTPREQVtbl = { * NULL on failure * */ -HINTERNET WINAPI HTTP_HttpOpenRequestW(http_session_t *lpwhs, +HINTERNET WINAPI HTTP_HttpOpenRequestW(LPWININETHTTPSESSIONW lpwhs, LPCWSTR lpszVerb, LPCWSTR lpszObjectName, LPCWSTR lpszVersion, LPCWSTR lpszReferrer , LPCWSTR *lpszAcceptTypes, DWORD dwFlags, DWORD_PTR dwContext) { - appinfo_t *hIC = NULL; - http_request_t *lpwhr; + LPWININETAPPINFOW hIC = NULL; + LPWININETHTTPREQW lpwhr; LPWSTR lpszHostName = NULL; HINTERNET handle = NULL; static const WCHAR szHostForm[] = {'%','s',':','%','u',0}; @@ -2396,7 +2377,7 @@ HINTERNET WINAPI HTTP_HttpOpenRequestW(http_session_t *lpwhs, assert( lpwhs->hdr.htype == WH_HHTTPSESSION ); hIC = lpwhs->lpAppInfo; - lpwhr = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(http_request_t)); + lpwhr = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(WININETHTTPREQW)); if (NULL == lpwhr) { INTERNET_SetLastError(ERROR_OUTOFMEMORY); @@ -2456,7 +2437,7 @@ HINTERNET WINAPI HTTP_HttpOpenRequestW(http_session_t *lpwhs, }else { static const WCHAR slashW[] = {'/',0}; - lpwhr->lpszPath = heap_strdupW(slashW); + lpwhr->lpszPath = WININET_strdupW(slashW); } if (lpszReferrer && *lpszReferrer) @@ -2475,8 +2456,12 @@ HINTERNET WINAPI HTTP_HttpOpenRequestW(http_session_t *lpwhs, } } - lpwhr->lpszVerb = heap_strdupW(lpszVerb && *lpszVerb ? lpszVerb : szGET); - lpwhr->lpszVersion = heap_strdupW(lpszVersion ? lpszVersion : g_szHttp1_1); + lpwhr->lpszVerb = WININET_strdupW(lpszVerb && *lpszVerb ? lpszVerb : szGET); + + if (lpszVersion) + lpwhr->lpszVersion = WININET_strdupW(lpszVersion); + else + lpwhr->lpszVersion = WININET_strdupW(g_szHttp1_1); if (lpwhs->nHostPort != INTERNET_INVALID_PORT_NUMBER && lpwhs->nHostPort != INTERNET_DEFAULT_HTTP_PORT && @@ -2518,7 +2503,7 @@ lend: /* read any content returned by the server so that the connection can be * reused */ -static void HTTP_DrainContent(http_request_t *req) +static void HTTP_DrainContent(WININETHTTPREQW *req) { DWORD bytes_read; @@ -2529,7 +2514,6 @@ static void HTTP_DrainContent(http_request_t *req) NETCON_close(&req->netConnection); return; } - if (!strcmpW(req->lpszVerb, szHEAD)) return; do { @@ -2618,7 +2602,7 @@ static const LPCWSTR header_lookup[] = { /*********************************************************************** * HTTP_HttpQueryInfoW (internal) */ -static BOOL HTTP_HttpQueryInfoW(http_request_t *lpwhr, DWORD dwInfoLevel, +static BOOL HTTP_HttpQueryInfoW( LPWININETHTTPREQW lpwhr, DWORD dwInfoLevel, LPVOID lpBuffer, LPDWORD lpdwBufferLength, LPDWORD lpdwIndex) { LPHTTPHEADERW lphttpHdr = NULL; @@ -2846,7 +2830,7 @@ BOOL WINAPI HttpQueryInfoW(HINTERNET hHttpRequest, DWORD dwInfoLevel, LPVOID lpBuffer, LPDWORD lpdwBufferLength, LPDWORD lpdwIndex) { BOOL bSuccess = FALSE; - http_request_t *lpwhr; + LPWININETHTTPREQW lpwhr; if (TRACE_ON(wininet)) { #define FE(x) { x, #x } @@ -2958,7 +2942,7 @@ BOOL WINAPI HttpQueryInfoW(HINTERNET hHttpRequest, DWORD dwInfoLevel, TRACE("\n"); } - lpwhr = (http_request_t*) WININET_GetObject( hHttpRequest ); + lpwhr = (LPWININETHTTPREQW) WININET_GetObject( hHttpRequest ); if (NULL == lpwhr || lpwhr->hdr.htype != WH_HHTTPREQ) { INTERNET_SetLastError(ERROR_INTERNET_INCORRECT_HANDLE_TYPE); @@ -3117,14 +3101,14 @@ BOOL WINAPI HttpSendRequestExW(HINTERNET hRequest, DWORD dwFlags, DWORD_PTR dwContext) { BOOL ret = FALSE; - http_request_t *lpwhr; - http_session_t *lpwhs; - appinfo_t *hIC; + LPWININETHTTPREQW lpwhr; + LPWININETHTTPSESSIONW lpwhs; + LPWININETAPPINFOW hIC; TRACE("(%p, %p, %p, %08x, %08lx)\n", hRequest, lpBuffersIn, lpBuffersOut, dwFlags, dwContext); - lpwhr = (http_request_t*) WININET_GetObject( hRequest ); + lpwhr = (LPWININETHTTPREQW) WININET_GetObject( hRequest ); if (NULL == lpwhr || lpwhr->hdr.htype != WH_HHTTPREQ) { @@ -3147,8 +3131,11 @@ BOOL WINAPI HttpSendRequestExW(HINTERNET hRequest, req = &workRequest.u.HttpSendRequestW; if (lpBuffersIn) { - /* FIXME: this should use dwHeadersLength or may not be necessary at all */ - req->lpszHeader = heap_strdupW(lpBuffersIn->lpcszHeader); + if (lpBuffersIn->lpcszHeader) + /* FIXME: this should use dwHeadersLength or may not be necessary at all */ + req->lpszHeader = WININET_strdupW(lpBuffersIn->lpcszHeader); + else + req->lpszHeader = NULL; req->dwHeaderLength = lpBuffersIn->dwHeadersLength; req->lpOptional = lpBuffersIn->lpvBuffer; req->dwOptionalLength = lpBuffersIn->dwBufferLength; @@ -3202,15 +3189,15 @@ lend: BOOL WINAPI HttpSendRequestW(HINTERNET hHttpRequest, LPCWSTR lpszHeaders, DWORD dwHeaderLength, LPVOID lpOptional ,DWORD dwOptionalLength) { - http_request_t *lpwhr; - http_session_t *lpwhs = NULL; - appinfo_t *hIC = NULL; + LPWININETHTTPREQW lpwhr; + LPWININETHTTPSESSIONW lpwhs = NULL; + LPWININETAPPINFOW hIC = NULL; BOOL r; TRACE("%p, %s, %i, %p, %i)\n", hHttpRequest, debugstr_wn(lpszHeaders, dwHeaderLength), dwHeaderLength, lpOptional, dwOptionalLength); - lpwhr = (http_request_t*) WININET_GetObject( hHttpRequest ); + lpwhr = (LPWININETHTTPREQW) WININET_GetObject( hHttpRequest ); if (NULL == lpwhr || lpwhr->hdr.htype != WH_HHTTPREQ) { INTERNET_SetLastError(ERROR_INTERNET_INCORRECT_HANDLE_TYPE); @@ -3309,11 +3296,11 @@ BOOL WINAPI HttpSendRequestA(HINTERNET hHttpRequest, LPCSTR lpszHeaders, /*********************************************************************** * HTTP_GetRedirectURL (internal) */ -static LPWSTR HTTP_GetRedirectURL(http_request_t *lpwhr, LPCWSTR lpszUrl) +static LPWSTR HTTP_GetRedirectURL(LPWININETHTTPREQW lpwhr, LPCWSTR lpszUrl) { static WCHAR szHttp[] = {'h','t','t','p',0}; static WCHAR szHttps[] = {'h','t','t','p','s',0}; - http_session_t *lpwhs = lpwhr->lpHttpSession; + LPWININETHTTPSESSIONW lpwhs = lpwhr->lpHttpSession; URL_COMPONENTSW urlComponents; DWORD url_length = 0; LPWSTR orig_url; @@ -3371,10 +3358,10 @@ static LPWSTR HTTP_GetRedirectURL(http_request_t *lpwhr, LPCWSTR lpszUrl) /*********************************************************************** * HTTP_HandleRedirect (internal) */ -static BOOL HTTP_HandleRedirect(http_request_t *lpwhr, LPCWSTR lpszUrl) +static BOOL HTTP_HandleRedirect(LPWININETHTTPREQW lpwhr, LPCWSTR lpszUrl) { - http_session_t *lpwhs = lpwhr->lpHttpSession; - appinfo_t *hIC = lpwhs->lpAppInfo; + LPWININETHTTPSESSIONW lpwhs = lpwhr->lpHttpSession; + LPWININETAPPINFOW hIC = lpwhs->lpAppInfo; BOOL using_proxy = hIC->lpszProxy && hIC->lpszProxy[0]; WCHAR path[INTERNET_MAX_URL_LENGTH]; int index; @@ -3463,21 +3450,21 @@ static BOOL HTTP_HandleRedirect(http_request_t *lpwhr, LPCWSTR lpszUrl) sprintfW(lpwhs->lpszHostName, fmt, hostName, urlComponents.nPort); } else - lpwhs->lpszHostName = heap_strdupW(hostName); + lpwhs->lpszHostName = WININET_strdupW(hostName); HTTP_ProcessHeader(lpwhr, hostW, lpwhs->lpszHostName, HTTP_ADDREQ_FLAG_ADD | HTTP_ADDREQ_FLAG_REPLACE | HTTP_ADDHDR_FLAG_REQ); HeapFree(GetProcessHeap(), 0, lpwhs->lpszUserName); lpwhs->lpszUserName = NULL; if (userName[0]) - lpwhs->lpszUserName = heap_strdupW(userName); + lpwhs->lpszUserName = WININET_strdupW(userName); if (!using_proxy) { if (strcmpiW(lpwhs->lpszServerName, hostName) || lpwhs->nServerPort != urlComponents.nPort) { HeapFree(GetProcessHeap(), 0, lpwhs->lpszServerName); - lpwhs->lpszServerName = heap_strdupW(hostName); + lpwhs->lpszServerName = WININET_strdupW(hostName); lpwhs->nServerPort = urlComponents.nPort; NETCON_close(&lpwhr->netConnection); @@ -3545,7 +3532,7 @@ static LPWSTR HTTP_build_req( LPCWSTR *list, int len ) return str; } -static BOOL HTTP_SecureProxyConnect(http_request_t *lpwhr) +static BOOL HTTP_SecureProxyConnect(LPWININETHTTPREQW lpwhr) { LPWSTR lpszPath; LPWSTR requestString; @@ -3556,7 +3543,7 @@ static BOOL HTTP_SecureProxyConnect(http_request_t *lpwhr) BOOL ret; static const WCHAR szConnect[] = {'C','O','N','N','E','C','T',0}; static const WCHAR szFormat[] = {'%','s',':','%','d',0}; - http_session_t *lpwhs = lpwhr->lpHttpSession; + LPWININETHTTPSESSIONW lpwhs = lpwhr->lpHttpSession; TRACE("\n"); @@ -3587,7 +3574,7 @@ static BOOL HTTP_SecureProxyConnect(http_request_t *lpwhr) return TRUE; } -static void HTTP_InsertCookies(http_request_t *lpwhr) +static void HTTP_InsertCookies(LPWININETHTTPREQW lpwhr) { static const WCHAR szUrlForm[] = {'h','t','t','p',':','/','/','%','s','%','s',0}; LPWSTR lpszCookies, lpszUrl = NULL; @@ -3627,7 +3614,7 @@ static void HTTP_InsertCookies(http_request_t *lpwhr) * FALSE on failure * */ -BOOL WINAPI HTTP_HttpSendRequestW(http_request_t *lpwhr, LPCWSTR lpszHeaders, +BOOL WINAPI HTTP_HttpSendRequestW(LPWININETHTTPREQW lpwhr, LPCWSTR lpszHeaders, DWORD dwHeaderLength, LPVOID lpOptional, DWORD dwOptionalLength, DWORD dwContentLength, BOOL bEndRequest) { @@ -3648,7 +3635,7 @@ BOOL WINAPI HTTP_HttpSendRequestW(http_request_t *lpwhr, LPCWSTR lpszHeaders, /* if the verb is NULL default to GET */ if (!lpwhr->lpszVerb) - lpwhr->lpszVerb = heap_strdupW(szGET); + lpwhr->lpszVerb = WININET_strdupW(szGET); if (dwContentLength || strcmpW(lpwhr->lpszVerb, szGET)) { @@ -3794,11 +3781,10 @@ BOOL WINAPI HTTP_HttpSendRequestW(http_request_t *lpwhr, LPCWSTR lpszHeaders, if ((dwStatusCode==HTTP_STATUS_REDIRECT || dwStatusCode==HTTP_STATUS_MOVED) && HTTP_HttpQueryInfoW(lpwhr,HTTP_QUERY_LOCATION,szNewLocation,&dwBufferSize,NULL)) { - if (strcmpW(lpwhr->lpszVerb, szGET) && strcmpW(lpwhr->lpszVerb, szHEAD)) - { - HeapFree(GetProcessHeap(), 0, lpwhr->lpszVerb); - lpwhr->lpszVerb = heap_strdupW(szGET); - } + /* redirects are always GETs */ + HeapFree(GetProcessHeap(), 0, lpwhr->lpszVerb); + lpwhr->lpszVerb = WININET_strdupW(szGET); + HTTP_DrainContent(lpwhr); if ((new_url = HTTP_GetRedirectURL( lpwhr, szNewLocation ))) { @@ -3869,7 +3855,7 @@ BOOL WINAPI HTTP_HttpSendRequestW(http_request_t *lpwhr, LPCWSTR lpszHeaders, b = CreateUrlCacheEntryW(url, lpwhr->dwContentLength > 0 ? lpwhr->dwContentLength : 0, NULL, cacheFileName, 0); if(b) { - lpwhr->lpszCacheFile = heap_strdupW(cacheFileName); + lpwhr->lpszCacheFile = WININET_strdupW(cacheFileName); lpwhr->hCacheFile = CreateFileW(lpwhr->lpszCacheFile, GENERIC_WRITE, FILE_SHARE_READ|FILE_SHARE_WRITE, NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL); if(lpwhr->hCacheFile == INVALID_HANDLE_VALUE) { @@ -3924,9 +3910,9 @@ lend: * Deallocate session handle * */ -static void HTTPSESSION_Destroy(object_header_t *hdr) +static void HTTPSESSION_Destroy(WININETHANDLEHEADER *hdr) { - http_session_t *lpwhs = (http_session_t*) hdr; + LPWININETHTTPSESSIONW lpwhs = (LPWININETHTTPSESSIONW) hdr; TRACE("%p\n", lpwhs); @@ -3939,7 +3925,7 @@ static void HTTPSESSION_Destroy(object_header_t *hdr) HeapFree(GetProcessHeap(), 0, lpwhs); } -static DWORD HTTPSESSION_QueryOption(object_header_t *hdr, DWORD option, void *buffer, DWORD *size, BOOL unicode) +static DWORD HTTPSESSION_QueryOption(WININETHANDLEHEADER *hdr, DWORD option, void *buffer, DWORD *size, BOOL unicode) { switch(option) { case INTERNET_OPTION_HANDLE_TYPE: @@ -3956,21 +3942,21 @@ static DWORD HTTPSESSION_QueryOption(object_header_t *hdr, DWORD option, void *b return INET_QueryOption(option, buffer, size, unicode); } -static DWORD HTTPSESSION_SetOption(object_header_t *hdr, DWORD option, void *buffer, DWORD size) +static DWORD HTTPSESSION_SetOption(WININETHANDLEHEADER *hdr, DWORD option, void *buffer, DWORD size) { - http_session_t *ses = (http_session_t*)hdr; + WININETHTTPSESSIONW *ses = (WININETHTTPSESSIONW*)hdr; switch(option) { case INTERNET_OPTION_USERNAME: { HeapFree(GetProcessHeap(), 0, ses->lpszUserName); - if (!(ses->lpszUserName = heap_strdupW(buffer))) return ERROR_OUTOFMEMORY; + if (!(ses->lpszUserName = WININET_strdupW(buffer))) return ERROR_OUTOFMEMORY; return ERROR_SUCCESS; } case INTERNET_OPTION_PASSWORD: { HeapFree(GetProcessHeap(), 0, ses->lpszPassword); - if (!(ses->lpszPassword = heap_strdupW(buffer))) return ERROR_OUTOFMEMORY; + if (!(ses->lpszPassword = WININET_strdupW(buffer))) return ERROR_OUTOFMEMORY; return ERROR_SUCCESS; } default: break; @@ -3979,7 +3965,7 @@ static DWORD HTTPSESSION_SetOption(object_header_t *hdr, DWORD option, void *buf return ERROR_INTERNET_INVALID_OPTION; } -static const object_vtbl_t HTTPSESSIONVtbl = { +static const HANDLEHEADERVtbl HTTPSESSIONVtbl = { HTTPSESSION_Destroy, NULL, HTTPSESSION_QueryOption, @@ -4002,12 +3988,12 @@ static const object_vtbl_t HTTPSESSIONVtbl = { * NULL on failure * */ -HINTERNET HTTP_Connect(appinfo_t *hIC, LPCWSTR lpszServerName, +HINTERNET HTTP_Connect(LPWININETAPPINFOW hIC, LPCWSTR lpszServerName, INTERNET_PORT nServerPort, LPCWSTR lpszUserName, LPCWSTR lpszPassword, DWORD dwFlags, DWORD_PTR dwContext, DWORD dwInternalFlags) { - http_session_t *lpwhs = NULL; + LPWININETHTTPSESSIONW lpwhs = NULL; HINTERNET handle = NULL; TRACE("-->\n"); @@ -4020,7 +4006,7 @@ HINTERNET HTTP_Connect(appinfo_t *hIC, LPCWSTR lpszServerName, assert( hIC->hdr.htype == WH_HINIT ); - lpwhs = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(http_session_t)); + lpwhs = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(WININETHTTPSESSIONW)); if (NULL == lpwhs) { INTERNET_SetLastError(ERROR_OUTOFMEMORY); @@ -4059,13 +4045,13 @@ HINTERNET HTTP_Connect(appinfo_t *hIC, LPCWSTR lpszServerName, } if (lpszServerName && lpszServerName[0]) { - lpwhs->lpszServerName = heap_strdupW(lpszServerName); - lpwhs->lpszHostName = heap_strdupW(lpszServerName); + lpwhs->lpszServerName = WININET_strdupW(lpszServerName); + lpwhs->lpszHostName = WININET_strdupW(lpszServerName); } if (lpszUserName && lpszUserName[0]) - lpwhs->lpszUserName = heap_strdupW(lpszUserName); + lpwhs->lpszUserName = WININET_strdupW(lpszUserName); if (lpszPassword && lpszPassword[0]) - lpwhs->lpszPassword = heap_strdupW(lpszPassword); + lpwhs->lpszPassword = WININET_strdupW(lpszPassword); lpwhs->nServerPort = nServerPort; lpwhs->nHostPort = nServerPort; @@ -4101,13 +4087,12 @@ lerror: * TRUE on success * FALSE on failure */ -static BOOL HTTP_OpenConnection(http_request_t *lpwhr) +static BOOL HTTP_OpenConnection(LPWININETHTTPREQW lpwhr) { BOOL bSuccess = FALSE; - http_session_t *lpwhs; - appinfo_t *hIC = NULL; - char szaddr[INET6_ADDRSTRLEN]; - const void *addr; + LPWININETHTTPSESSIONW lpwhs; + LPWININETAPPINFOW hIC = NULL; + char szaddr[32]; TRACE("-->\n"); @@ -4128,26 +4113,14 @@ static BOOL HTTP_OpenConnection(http_request_t *lpwhr) lpwhs = lpwhr->lpHttpSession; hIC = lpwhs->lpAppInfo; - switch (lpwhs->socketAddress.ss_family) - { - case AF_INET: - addr = &((struct sockaddr_in *)&lpwhs->socketAddress)->sin_addr; - break; - case AF_INET6: - addr = &((struct sockaddr_in6 *)&lpwhs->socketAddress)->sin6_addr; - break; - default: - WARN("unsupported family %d\n", lpwhs->socketAddress.ss_family); - INTERNET_SetLastError(ERROR_INTERNET_NAME_NOT_RESOLVED); - return FALSE; - } - inet_ntop(lpwhs->socketAddress.ss_family, addr, szaddr, sizeof(szaddr)); + inet_ntop(lpwhs->socketAddress.sin_family, &lpwhs->socketAddress.sin_addr, + szaddr, sizeof(szaddr)); INTERNET_SendCallback(&lpwhr->hdr, lpwhr->hdr.dwContext, INTERNET_STATUS_CONNECTING_TO_SERVER, szaddr, strlen(szaddr)+1); - if (!NETCON_create(&lpwhr->netConnection, lpwhs->socketAddress.ss_family, + if (!NETCON_create(&lpwhr->netConnection, lpwhs->socketAddress.sin_family, SOCK_STREAM, 0)) { WARN("Socket creation failed: %u\n", INTERNET_GetLastError()); @@ -4155,7 +4128,7 @@ static BOOL HTTP_OpenConnection(http_request_t *lpwhr) } if (!NETCON_connect(&lpwhr->netConnection, (struct sockaddr *)&lpwhs->socketAddress, - lpwhs->sa_len)) + sizeof(lpwhs->socketAddress))) goto lend; if (lpwhr->hdr.dwFlags & INTERNET_FLAG_SECURE) @@ -4196,7 +4169,7 @@ lend: * * clear out any old response headers */ -static void HTTP_clear_response_headers( http_request_t *lpwhr ) +static void HTTP_clear_response_headers( LPWININETHTTPREQW lpwhr ) { DWORD i; @@ -4223,20 +4196,20 @@ static void HTTP_clear_response_headers( http_request_t *lpwhr ) * TRUE on success * FALSE on error */ -static INT HTTP_GetResponseHeaders(http_request_t *lpwhr, BOOL clear) +static INT HTTP_GetResponseHeaders(LPWININETHTTPREQW lpwhr, BOOL clear) { INT cbreaks = 0; WCHAR buffer[MAX_REPLY_LEN]; DWORD buflen = MAX_REPLY_LEN; BOOL bSuccess = FALSE; INT rc = 0; + static const WCHAR szHundred[] = {'1','0','0',0}; char bufferA[MAX_REPLY_LEN]; - LPWSTR status_code = NULL, status_text = NULL; + LPWSTR status_code, status_text; DWORD cchMaxRawHeaders = 1024; LPWSTR lpszRawHeaders = HeapAlloc(GetProcessHeap(), 0, (cchMaxRawHeaders+1)*sizeof(WCHAR)); LPWSTR temp; DWORD cchRawHeaders = 0; - BOOL codeHundred = FALSE; TRACE("-->\n"); @@ -4247,7 +4220,6 @@ static INT HTTP_GetResponseHeaders(http_request_t *lpwhr, BOOL clear) goto lend; do { - static const WCHAR szHundred[] = {'1','0','0',0}; /* * We should first receive 'HTTP/1.x nnn OK' where nnn is the status code. */ @@ -4256,32 +4228,23 @@ static INT HTTP_GetResponseHeaders(http_request_t *lpwhr, BOOL clear) goto lend; rc += buflen; MultiByteToWideChar( CP_ACP, 0, bufferA, buflen, buffer, MAX_REPLY_LEN ); - /* check is this a status code line? */ - if (!strncmpW(buffer, g_szHttp1_0, 4)) - { - /* split the version from the status code */ - status_code = strchrW( buffer, ' ' ); - if( !status_code ) - goto lend; - *status_code++=0; - /* split the status code from the status text */ - status_text = strchrW( status_code, ' ' ); - if( !status_text ) - goto lend; - *status_text++=0; + /* split the version from the status code */ + status_code = strchrW( buffer, ' ' ); + if( !status_code ) + goto lend; + *status_code++=0; - TRACE("version [%s] status code [%s] status text [%s]\n", - debugstr_w(buffer), debugstr_w(status_code), debugstr_w(status_text) ); + /* split the status code from the status text */ + status_text = strchrW( status_code, ' ' ); + if( !status_text ) + goto lend; + *status_text++=0; - codeHundred = (!strcmpW(status_code, szHundred)); - } - else if (!codeHundred) - { - FIXME("Non status line at head of response (%s)\n",debugstr_w(buffer)); - continue; - } - } while (codeHundred); + TRACE("version [%s] status code [%s] status text [%s]\n", + debugstr_w(buffer), debugstr_w(status_code), debugstr_w(status_text) ); + + } while (!strcmpW(status_code, szHundred)); /* ignore "100 Continue" responses */ /* Add status code */ HTTP_ProcessHeader(lpwhr, szStatus, status_code, @@ -4290,8 +4253,8 @@ static INT HTTP_GetResponseHeaders(http_request_t *lpwhr, BOOL clear) HeapFree(GetProcessHeap(),0,lpwhr->lpszVersion); HeapFree(GetProcessHeap(),0,lpwhr->lpszStatusText); - lpwhr->lpszVersion = heap_strdupW(buffer); - lpwhr->lpszStatusText = heap_strdupW(status_text); + lpwhr->lpszVersion= WININET_strdupW(buffer); + lpwhr->lpszStatusText = WININET_strdupW(status_text); /* Restore the spaces */ *(status_code-1) = ' '; @@ -4350,19 +4313,6 @@ static INT HTTP_GetResponseHeaders(http_request_t *lpwhr, BOOL clear) } }while(1); - /* make sure the response header is terminated with an empty line. Some apps really - truly care about that empty line being there for some reason. Just add it to the - header. */ - if (cchRawHeaders + strlenW(szCrLf) > cchMaxRawHeaders) - { - cchMaxRawHeaders = cchRawHeaders + strlenW(szCrLf); - temp = HeapReAlloc(GetProcessHeap(), 0, lpszRawHeaders, (cchMaxRawHeaders + 1) * sizeof(WCHAR)); - if (temp == NULL) goto lend; - lpszRawHeaders = temp; - } - - memcpy(&lpszRawHeaders[cchRawHeaders], szCrLf, sizeof(szCrLf)); - HeapFree(GetProcessHeap(), 0, lpwhr->lpszRawHeaders); lpwhr->lpszRawHeaders = lpszRawHeaders; TRACE("raw headers: %s\n", debugstr_w(lpszRawHeaders)); @@ -4465,7 +4415,7 @@ static LPWSTR * HTTP_InterpretHttpHeader(LPCWSTR buffer) #define COALESCEFLAGS (HTTP_ADDHDR_FLAG_COALESCE|HTTP_ADDHDR_FLAG_COALESCE_WITH_COMMA|HTTP_ADDHDR_FLAG_COALESCE_WITH_SEMICOLON) -static BOOL HTTP_ProcessHeader(http_request_t *lpwhr, LPCWSTR field, LPCWSTR value, DWORD dwModifier) +static BOOL HTTP_ProcessHeader(LPWININETHTTPREQW lpwhr, LPCWSTR field, LPCWSTR value, DWORD dwModifier) { LPHTTPHEADERW lphttpHdr = NULL; BOOL bSuccess = FALSE; @@ -4587,7 +4537,7 @@ static BOOL HTTP_ProcessHeader(http_request_t *lpwhr, LPCWSTR field, LPCWSTR val * Called when all content from server has been read by client. * */ -static BOOL HTTP_FinishedReading(http_request_t *lpwhr) +static BOOL HTTP_FinishedReading(LPWININETHTTPREQW lpwhr) { WCHAR szVersion[10]; WCHAR szConnectionResponse[20]; @@ -4629,7 +4579,7 @@ static BOOL HTTP_FinishedReading(http_request_t *lpwhr) * Return index of custom header from header array * */ -static INT HTTP_GetCustomHeaderIndex(http_request_t *lpwhr, LPCWSTR lpszField, +static INT HTTP_GetCustomHeaderIndex(LPWININETHTTPREQW lpwhr, LPCWSTR lpszField, int requested_index, BOOL request_only) { DWORD index; @@ -4666,7 +4616,7 @@ static INT HTTP_GetCustomHeaderIndex(http_request_t *lpwhr, LPCWSTR lpszField, * Insert header into array * */ -static BOOL HTTP_InsertCustomHeader(http_request_t *lpwhr, LPHTTPHEADERW lpHdr) +static BOOL HTTP_InsertCustomHeader(LPWININETHTTPREQW lpwhr, LPHTTPHEADERW lpHdr) { INT count; LPHTTPHEADERW lph = NULL; @@ -4682,8 +4632,8 @@ static BOOL HTTP_InsertCustomHeader(http_request_t *lpwhr, LPHTTPHEADERW lpHdr) if (NULL != lph) { lpwhr->pCustHeaders = lph; - lpwhr->pCustHeaders[count-1].lpszField = heap_strdupW(lpHdr->lpszField); - lpwhr->pCustHeaders[count-1].lpszValue = heap_strdupW(lpHdr->lpszValue); + lpwhr->pCustHeaders[count-1].lpszField = WININET_strdupW(lpHdr->lpszField); + lpwhr->pCustHeaders[count-1].lpszValue = WININET_strdupW(lpHdr->lpszValue); lpwhr->pCustHeaders[count-1].wFlags = lpHdr->wFlags; lpwhr->pCustHeaders[count-1].wCount= lpHdr->wCount; lpwhr->nCustHeaders++; @@ -4704,7 +4654,7 @@ static BOOL HTTP_InsertCustomHeader(http_request_t *lpwhr, LPHTTPHEADERW lpHdr) * Delete header from array * If this function is called, the indexs may change. */ -static BOOL HTTP_DeleteCustomHeader(http_request_t *lpwhr, DWORD index) +static BOOL HTTP_DeleteCustomHeader(LPWININETHTTPREQW lpwhr, DWORD index) { if( lpwhr->nCustHeaders <= 0 ) return FALSE; @@ -4729,7 +4679,7 @@ static BOOL HTTP_DeleteCustomHeader(http_request_t *lpwhr, DWORD index) * Verify the given header is not invalid for the given http request * */ -static BOOL HTTP_VerifyValidHeader(http_request_t *lpwhr, LPCWSTR field) +static BOOL HTTP_VerifyValidHeader(LPWININETHTTPREQW lpwhr, LPCWSTR field) { /* Accept-Encoding is stripped from HTTP/1.0 requests. It is invalid */ if (!strcmpW(lpwhr->lpszVersion, g_szHttp1_0) && !strcmpiW(field, szAccept_Encoding)) diff --git a/dlls/wininet/internet.c b/dlls/wininet/internet.c index 236e1f66453..4bb25e74942 100644 --- a/dlls/wininet/internet.c +++ b/dlls/wininet/internet.c @@ -101,13 +101,13 @@ static CRITICAL_SECTION_DEBUG WININET_cs_debug = }; static CRITICAL_SECTION WININET_cs = { &WININET_cs_debug, -1, 0, 0, 0, 0 }; -static object_header_t **WININET_Handles; +static LPWININETHANDLEHEADER *WININET_Handles; static UINT WININET_dwNextHandle; static UINT WININET_dwMaxHandles; -HINTERNET WININET_AllocHandle( object_header_t *info ) +HINTERNET WININET_AllocHandle( LPWININETHANDLEHEADER info ) { - object_header_t **p; + LPWININETHANDLEHEADER *p; UINT handle = 0, num; list_init( &info->children ); @@ -149,16 +149,16 @@ end: return info->hInternet = (HINTERNET) (handle+1); } -object_header_t *WININET_AddRef( object_header_t *info ) +LPWININETHANDLEHEADER WININET_AddRef( LPWININETHANDLEHEADER info ) { ULONG refs = InterlockedIncrement(&info->refs); TRACE("%p -> refcount = %d\n", info, refs ); return info; } -object_header_t *WININET_GetObject( HINTERNET hinternet ) +LPWININETHANDLEHEADER WININET_GetObject( HINTERNET hinternet ) { - object_header_t *info = NULL; + LPWININETHANDLEHEADER info = NULL; UINT handle = (UINT) hinternet; EnterCriticalSection( &WININET_cs ); @@ -174,7 +174,7 @@ object_header_t *WININET_GetObject( HINTERNET hinternet ) return info; } -BOOL WININET_Release( object_header_t *info ) +BOOL WININET_Release( LPWININETHANDLEHEADER info ) { ULONG refs = InterlockedDecrement(&info->refs); TRACE( "object %p refcount = %d\n", info, refs ); @@ -205,7 +205,7 @@ BOOL WININET_FreeHandle( HINTERNET hinternet ) { BOOL ret = FALSE; UINT handle = (UINT) hinternet; - object_header_t *info = NULL, *child, *next; + LPWININETHANDLEHEADER info = NULL, child, next; EnterCriticalSection( &WININET_cs ); @@ -229,7 +229,7 @@ BOOL WININET_FreeHandle( HINTERNET hinternet ) if( info ) { /* Free all children as native does */ - LIST_FOR_EACH_ENTRY_SAFE( child, next, &info->children, object_header_t, entry ) + LIST_FOR_EACH_ENTRY_SAFE( child, next, &info->children, WININETHANDLEHEADER, entry ) { TRACE( "freeing child handle %d for parent handle %d\n", (UINT)child->hInternet, handle+1); @@ -348,7 +348,7 @@ BOOL WINAPI DetectAutoProxyUrl(LPSTR lpszAutoProxyUrl, * The proxy may be specified in the form 'http=proxy.my.org' * Presumably that means there can be ftp=ftpproxy.my.org too. */ -static BOOL INTERNET_ConfigureProxy( appinfo_t *lpwai ) +static BOOL INTERNET_ConfigureProxy( LPWININETAPPINFOW lpwai ) { HKEY key; DWORD type, len, enabled = 0; @@ -487,9 +487,9 @@ static void dump_INTERNET_FLAGS(DWORD dwFlags) * Close internet handle * */ -static VOID APPINFO_Destroy(object_header_t *hdr) +static VOID APPINFO_Destroy(WININETHANDLEHEADER *hdr) { - appinfo_t *lpwai = (appinfo_t*)hdr; + LPWININETAPPINFOW lpwai = (LPWININETAPPINFOW) hdr; TRACE("%p\n",lpwai); @@ -501,9 +501,9 @@ static VOID APPINFO_Destroy(object_header_t *hdr) HeapFree(GetProcessHeap(), 0, lpwai); } -static DWORD APPINFO_QueryOption(object_header_t *hdr, DWORD option, void *buffer, DWORD *size, BOOL unicode) +static DWORD APPINFO_QueryOption(WININETHANDLEHEADER *hdr, DWORD option, void *buffer, DWORD *size, BOOL unicode) { - appinfo_t *ai = (appinfo_t*)hdr; + LPWININETAPPINFOW ai = (LPWININETAPPINFOW)hdr; switch(option) { case INTERNET_OPTION_HANDLE_TYPE: @@ -613,7 +613,7 @@ static DWORD APPINFO_QueryOption(object_header_t *hdr, DWORD option, void *buffe return INET_QueryOption(option, buffer, size, unicode); } -static const object_vtbl_t APPINFOVtbl = { +static const HANDLEHEADERVtbl APPINFOVtbl = { APPINFO_Destroy, NULL, APPINFO_QueryOption, @@ -639,7 +639,7 @@ static const object_vtbl_t APPINFOVtbl = { HINTERNET WINAPI InternetOpenW(LPCWSTR lpszAgent, DWORD dwAccessType, LPCWSTR lpszProxy, LPCWSTR lpszProxyBypass, DWORD dwFlags) { - appinfo_t *lpwai = NULL; + LPWININETAPPINFOW lpwai = NULL; HINTERNET handle = NULL; if (TRACE_ON(wininet)) { @@ -670,7 +670,7 @@ HINTERNET WINAPI InternetOpenW(LPCWSTR lpszAgent, DWORD dwAccessType, /* Clear any error information */ INTERNET_SetLastError(0); - lpwai = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(appinfo_t)); + lpwai = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(WININETAPPINFOW)); if (NULL == lpwai) { INTERNET_SetLastError(ERROR_OUTOFMEMORY); @@ -693,12 +693,30 @@ HINTERNET WINAPI InternetOpenW(LPCWSTR lpszAgent, DWORD dwAccessType, goto lend; } - lpwai->lpszAgent = heap_strdupW(lpszAgent); + if (NULL != lpszAgent) + { + lpwai->lpszAgent = HeapAlloc( GetProcessHeap(),0, + (strlenW(lpszAgent)+1)*sizeof(WCHAR)); + if (lpwai->lpszAgent) + lstrcpyW( lpwai->lpszAgent, lpszAgent ); + } if(dwAccessType == INTERNET_OPEN_TYPE_PRECONFIG) INTERNET_ConfigureProxy( lpwai ); - else - lpwai->lpszProxy = heap_strdupW(lpszProxy); - lpwai->lpszProxyBypass = heap_strdupW(lpszProxyBypass); + else if (NULL != lpszProxy) + { + lpwai->lpszProxy = HeapAlloc( GetProcessHeap(), 0, + (strlenW(lpszProxy)+1)*sizeof(WCHAR)); + if (lpwai->lpszProxy) + lstrcpyW( lpwai->lpszProxy, lpszProxy ); + } + + if (NULL != lpszProxyBypass) + { + lpwai->lpszProxyBypass = HeapAlloc( GetProcessHeap(), 0, + (strlenW(lpszProxyBypass)+1)*sizeof(WCHAR)); + if (lpwai->lpszProxyBypass) + lstrcpyW( lpwai->lpszProxyBypass, lpszProxyBypass ); + } lend: if( lpwai ) @@ -723,15 +741,33 @@ lend: HINTERNET WINAPI InternetOpenA(LPCSTR lpszAgent, DWORD dwAccessType, LPCSTR lpszProxy, LPCSTR lpszProxyBypass, DWORD dwFlags) { - WCHAR *szAgent, *szProxy, *szBypass; - HINTERNET rc; + HINTERNET rc = NULL; + INT len; + WCHAR *szAgent = NULL, *szProxy = NULL, *szBypass = NULL; TRACE("(%s, 0x%08x, %s, %s, 0x%08x)\n", debugstr_a(lpszAgent), dwAccessType, debugstr_a(lpszProxy), debugstr_a(lpszProxyBypass), dwFlags); - szAgent = heap_strdupAtoW(lpszAgent); - szProxy = heap_strdupAtoW(lpszProxy); - szBypass = heap_strdupAtoW(lpszProxyBypass); + if( lpszAgent ) + { + len = MultiByteToWideChar(CP_ACP, 0, lpszAgent, -1, NULL, 0); + szAgent = HeapAlloc(GetProcessHeap(), 0, len*sizeof(WCHAR)); + MultiByteToWideChar(CP_ACP, 0, lpszAgent, -1, szAgent, len); + } + + if( lpszProxy ) + { + len = MultiByteToWideChar(CP_ACP, 0, lpszProxy, -1, NULL, 0); + szProxy = HeapAlloc(GetProcessHeap(), 0, len*sizeof(WCHAR)); + MultiByteToWideChar(CP_ACP, 0, lpszProxy, -1, szProxy, len); + } + + if( lpszProxyBypass ) + { + len = MultiByteToWideChar(CP_ACP, 0, lpszProxyBypass, -1, NULL, 0); + szBypass = HeapAlloc(GetProcessHeap(), 0, len*sizeof(WCHAR)); + MultiByteToWideChar(CP_ACP, 0, lpszProxyBypass, -1, szBypass, len); + } rc = InternetOpenW(szAgent, dwAccessType, szProxy, szBypass, dwFlags); @@ -926,7 +962,7 @@ HINTERNET WINAPI InternetConnectW(HINTERNET hInternet, LPCWSTR lpszUserName, LPCWSTR lpszPassword, DWORD dwService, DWORD dwFlags, DWORD_PTR dwContext) { - appinfo_t *hIC; + LPWININETAPPINFOW hIC; HINTERNET rc = NULL; TRACE("(%p, %s, %i, %s, %s, %i, %i, %lx)\n", hInternet, debugstr_w(lpszServerName), @@ -941,7 +977,7 @@ HINTERNET WINAPI InternetConnectW(HINTERNET hInternet, /* Clear any error information */ INTERNET_SetLastError(0); - hIC = (appinfo_t*)WININET_GetObject( hInternet ); + hIC = (LPWININETAPPINFOW) WININET_GetObject( hInternet ); if ( (hIC == NULL) || (hIC->hdr.htype != WH_HINIT) ) { INTERNET_SetLastError(ERROR_INVALID_HANDLE); @@ -989,13 +1025,30 @@ HINTERNET WINAPI InternetConnectA(HINTERNET hInternet, DWORD dwService, DWORD dwFlags, DWORD_PTR dwContext) { HINTERNET rc = NULL; - LPWSTR szServerName; - LPWSTR szUserName; - LPWSTR szPassword; + INT len = 0; + LPWSTR szServerName = NULL; + LPWSTR szUserName = NULL; + LPWSTR szPassword = NULL; + + if (lpszServerName) + { + len = MultiByteToWideChar(CP_ACP, 0, lpszServerName, -1, NULL, 0); + szServerName = HeapAlloc(GetProcessHeap(), 0, len*sizeof(WCHAR)); + MultiByteToWideChar(CP_ACP, 0, lpszServerName, -1, szServerName, len); + } + if (lpszUserName) + { + len = MultiByteToWideChar(CP_ACP, 0, lpszUserName, -1, NULL, 0); + szUserName = HeapAlloc(GetProcessHeap(), 0, len*sizeof(WCHAR)); + MultiByteToWideChar(CP_ACP, 0, lpszUserName, -1, szUserName, len); + } + if (lpszPassword) + { + len = MultiByteToWideChar(CP_ACP, 0, lpszPassword, -1, NULL, 0); + szPassword = HeapAlloc(GetProcessHeap(), 0, len*sizeof(WCHAR)); + MultiByteToWideChar(CP_ACP, 0, lpszPassword, -1, szPassword, len); + } - szServerName = heap_strdupAtoW(lpszServerName); - szUserName = heap_strdupAtoW(lpszUserName); - szPassword = heap_strdupAtoW(lpszPassword); rc = InternetConnectW(hInternet, szServerName, nServerPort, szUserName, szPassword, dwService, dwFlags, dwContext); @@ -1040,7 +1093,7 @@ BOOL WINAPI InternetFindNextFileA(HINTERNET hFind, LPVOID lpvFindData) */ BOOL WINAPI InternetFindNextFileW(HINTERNET hFind, LPVOID lpvFindData) { - object_header_t *hdr; + WININETHANDLEHEADER *hdr; DWORD res; TRACE("\n"); @@ -1078,7 +1131,7 @@ BOOL WINAPI InternetFindNextFileW(HINTERNET hFind, LPVOID lpvFindData) */ BOOL WINAPI InternetCloseHandle(HINTERNET hInternet) { - object_header_t *lpwh; + LPWININETHANDLEHEADER lpwh; TRACE("%p\n",hInternet); @@ -1742,7 +1795,7 @@ BOOL WINAPI InternetCanonicalizeUrlW(LPCWSTR lpszUrl, LPWSTR lpszBuffer, /* #################################################### */ static INTERNET_STATUS_CALLBACK set_status_callback( - object_header_t *lpwh, INTERNET_STATUS_CALLBACK callback, BOOL unicode) + LPWININETHANDLEHEADER lpwh, INTERNET_STATUS_CALLBACK callback, BOOL unicode) { INTERNET_STATUS_CALLBACK ret; @@ -1770,7 +1823,7 @@ INTERNET_STATUS_CALLBACK WINAPI InternetSetStatusCallbackA( HINTERNET hInternet ,INTERNET_STATUS_CALLBACK lpfnIntCB) { INTERNET_STATUS_CALLBACK retVal; - object_header_t *lpwh; + LPWININETHANDLEHEADER lpwh; TRACE("%p\n", hInternet); @@ -1798,7 +1851,7 @@ INTERNET_STATUS_CALLBACK WINAPI InternetSetStatusCallbackW( HINTERNET hInternet ,INTERNET_STATUS_CALLBACK lpfnIntCB) { INTERNET_STATUS_CALLBACK retVal; - object_header_t *lpwh; + LPWININETHANDLEHEADER lpwh; TRACE("%p\n", hInternet); @@ -1834,7 +1887,7 @@ DWORD WINAPI InternetSetFilePointer(HINTERNET hFile, LONG lDistanceToMove, BOOL WINAPI InternetWriteFile(HINTERNET hFile, LPCVOID lpBuffer, DWORD dwNumOfBytesToWrite, LPDWORD lpdwNumOfBytesWritten) { - object_header_t *lpwh; + LPWININETHANDLEHEADER lpwh; BOOL retval = FALSE; TRACE("(%p %p %d %p)\n", hFile, lpBuffer, dwNumOfBytesToWrite, lpdwNumOfBytesWritten); @@ -1873,7 +1926,7 @@ BOOL WINAPI InternetWriteFile(HINTERNET hFile, LPCVOID lpBuffer, BOOL WINAPI InternetReadFile(HINTERNET hFile, LPVOID lpBuffer, DWORD dwNumOfBytesToRead, LPDWORD pdwNumOfBytesRead) { - object_header_t *hdr; + LPWININETHANDLEHEADER hdr; DWORD res = ERROR_INTERNET_INCORRECT_HANDLE_TYPE; TRACE("%p %p %d %p\n", hFile, lpBuffer, dwNumOfBytesToRead, pdwNumOfBytesRead); @@ -1927,7 +1980,7 @@ BOOL WINAPI InternetReadFile(HINTERNET hFile, LPVOID lpBuffer, BOOL WINAPI InternetReadFileExA(HINTERNET hFile, LPINTERNET_BUFFERSA lpBuffersOut, DWORD dwFlags, DWORD_PTR dwContext) { - object_header_t *hdr; + LPWININETHANDLEHEADER hdr; DWORD res = ERROR_INTERNET_INCORRECT_HANDLE_TYPE; TRACE("(%p %p 0x%x 0x%lx)\n", hFile, lpBuffersOut, dwFlags, dwContext); @@ -1959,7 +2012,7 @@ BOOL WINAPI InternetReadFileExA(HINTERNET hFile, LPINTERNET_BUFFERSA lpBuffersOu BOOL WINAPI InternetReadFileExW(HINTERNET hFile, LPINTERNET_BUFFERSW lpBuffer, DWORD dwFlags, DWORD_PTR dwContext) { - object_header_t *hdr; + LPWININETHANDLEHEADER hdr; DWORD res = ERROR_INTERNET_INCORRECT_HANDLE_TYPE; TRACE("(%p %p 0x%x 0x%lx)\n", hFile, lpBuffer, dwFlags, dwContext); @@ -2013,6 +2066,7 @@ DWORD INET_QueryOption(DWORD option, void *buffer, DWORD *size, BOOL unicode) return ERROR_SUCCESS; case INTERNET_OPTION_CONNECTED_STATE: + if (warn) { FIXME("INTERNET_OPTION_CONNECTED_STATE: semi-stub\n"); warn = FALSE; @@ -2026,10 +2080,10 @@ DWORD INET_QueryOption(DWORD option, void *buffer, DWORD *size, BOOL unicode) return ERROR_SUCCESS; case INTERNET_OPTION_PROXY: { - appinfo_t ai; + WININETAPPINFOW ai; TRACE("Getting global proxy info\n"); - memset(&ai, 0, sizeof(appinfo_t)); + memset(&ai, 0, sizeof(WININETAPPINFOW)); INTERNET_ConfigureProxy(&ai); return APPINFO_QueryOption(&ai.hdr, INTERNET_OPTION_PROXY, buffer, size, unicode); /* FIXME */ @@ -2132,7 +2186,7 @@ DWORD INET_QueryOption(DWORD option, void *buffer, DWORD *size, BOOL unicode) BOOL WINAPI InternetQueryOptionW(HINTERNET hInternet, DWORD dwOption, LPVOID lpBuffer, LPDWORD lpdwBufferLength) { - object_header_t *hdr; + LPWININETHANDLEHEADER hdr; DWORD res = ERROR_INVALID_HANDLE; TRACE("%p %d %p %p\n", hInternet, dwOption, lpBuffer, lpdwBufferLength); @@ -2165,7 +2219,7 @@ BOOL WINAPI InternetQueryOptionW(HINTERNET hInternet, DWORD dwOption, BOOL WINAPI InternetQueryOptionA(HINTERNET hInternet, DWORD dwOption, LPVOID lpBuffer, LPDWORD lpdwBufferLength) { - object_header_t *hdr; + LPWININETHANDLEHEADER hdr; DWORD res = ERROR_INVALID_HANDLE; TRACE("%p %d %p %p\n", hInternet, dwOption, lpBuffer, lpdwBufferLength); @@ -2199,12 +2253,12 @@ BOOL WINAPI InternetQueryOptionA(HINTERNET hInternet, DWORD dwOption, BOOL WINAPI InternetSetOptionW(HINTERNET hInternet, DWORD dwOption, LPVOID lpBuffer, DWORD dwBufferLength) { - object_header_t *lpwhh; + LPWININETHANDLEHEADER lpwhh; BOOL ret = TRUE; TRACE("(%p %d %p %d)\n", hInternet, dwOption, lpBuffer, dwBufferLength); - lpwhh = (object_header_t*) WININET_GetObject( hInternet ); + lpwhh = (LPWININETHANDLEHEADER) WININET_GetObject( hInternet ); if(lpwhh && lpwhh->vtbl->SetOption) { DWORD res; @@ -2379,7 +2433,7 @@ BOOL WINAPI InternetSetOptionA(HINTERNET hInternet, DWORD dwOption, { case INTERNET_OPTION_CALLBACK: { - object_header_t *lpwh; + LPWININETHANDLEHEADER lpwh; if (!(lpwh = WININET_GetObject(hInternet))) { @@ -2537,12 +2591,16 @@ BOOL WINAPI InternetTimeToSystemTimeA( LPCSTR string, SYSTEMTIME* time, DWORD re { BOOL ret = FALSE; WCHAR *stringW; + int len; TRACE( "%s %p 0x%08x\n", debugstr_a(string), time, reserved ); - stringW = heap_strdupAtoW(string); + len = MultiByteToWideChar( CP_ACP, 0, string, -1, NULL, 0 ); + stringW = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) ); + if (stringW) { + MultiByteToWideChar( CP_ACP, 0, string, -1, stringW, len ); ret = InternetTimeToSystemTimeW( stringW, time, reserved ); HeapFree( GetProcessHeap(), 0, stringW ); } @@ -2691,16 +2749,15 @@ BOOL WINAPI InternetCheckConnectionW( LPCWSTR lpszUrl, DWORD dwFlags, DWORD dwRe if (dwFlags & FLAG_ICC_FORCE_CONNECTION) { - struct sockaddr_storage saddr; - socklen_t sa_len = sizeof(saddr); + struct sockaddr_in sin; int fd; - if (!GetAddress(hostW, port, (struct sockaddr *)&saddr, &sa_len)) + if (!GetAddress(hostW, port, &sin)) goto End; - fd = socket(saddr.ss_family, SOCK_STREAM, 0); + fd = socket(sin.sin_family, SOCK_STREAM, 0); if (fd != -1) { - if (connect(fd, (struct sockaddr *)&saddr, sa_len) == 0) + if (connect(fd, (struct sockaddr *)&sin, sizeof(sin)) == 0) rc = TRUE; close(fd); } @@ -2749,18 +2806,17 @@ End: */ BOOL WINAPI InternetCheckConnectionA(LPCSTR lpszUrl, DWORD dwFlags, DWORD dwReserved) { - WCHAR *url = NULL; + WCHAR *szUrl; + INT len; BOOL rc; - if(lpszUrl) { - url = heap_strdupAtoW(lpszUrl); - if(!url) - return FALSE; - } - - rc = InternetCheckConnectionW(url, dwFlags, dwReserved); - - HeapFree(GetProcessHeap(), 0, url); + len = MultiByteToWideChar(CP_ACP, 0, lpszUrl, -1, NULL, 0); + if (!(szUrl = HeapAlloc(GetProcessHeap(), 0, len*sizeof(WCHAR)))) + return FALSE; + MultiByteToWideChar(CP_ACP, 0, lpszUrl, -1, szUrl, len); + rc = InternetCheckConnectionW(szUrl, dwFlags, dwReserved); + HeapFree(GetProcessHeap(), 0, szUrl); + return rc; } @@ -2773,7 +2829,7 @@ BOOL WINAPI InternetCheckConnectionA(LPCSTR lpszUrl, DWORD dwFlags, DWORD dwRese * RETURNS * handle of connection or NULL on failure */ -static HINTERNET INTERNET_InternetOpenUrlW(appinfo_t *hIC, LPCWSTR lpszUrl, +static HINTERNET INTERNET_InternetOpenUrlW(LPWININETAPPINFOW hIC, LPCWSTR lpszUrl, LPCWSTR lpszHeaders, DWORD dwHeadersLength, DWORD dwFlags, DWORD_PTR dwContext) { URL_COMPONENTSW urlComponents; @@ -2885,7 +2941,7 @@ static HINTERNET INTERNET_InternetOpenUrlW(appinfo_t *hIC, LPCWSTR lpszUrl, static void AsyncInternetOpenUrlProc(WORKREQUEST *workRequest) { struct WORKREQ_INTERNETOPENURLW const *req = &workRequest->u.InternetOpenUrlW; - appinfo_t *hIC = (appinfo_t*) workRequest->hdr; + LPWININETAPPINFOW hIC = (LPWININETAPPINFOW) workRequest->hdr; TRACE("%p\n", hIC); @@ -2899,7 +2955,7 @@ HINTERNET WINAPI InternetOpenUrlW(HINTERNET hInternet, LPCWSTR lpszUrl, LPCWSTR lpszHeaders, DWORD dwHeadersLength, DWORD dwFlags, DWORD_PTR dwContext) { HINTERNET ret = NULL; - appinfo_t *hIC = NULL; + LPWININETAPPINFOW hIC = NULL; if (TRACE_ON(wininet)) { TRACE("(%p, %s, %s, %08x, %08x, %08lx)\n", hInternet, debugstr_w(lpszUrl), debugstr_w(lpszHeaders), @@ -2914,7 +2970,7 @@ HINTERNET WINAPI InternetOpenUrlW(HINTERNET hInternet, LPCWSTR lpszUrl, goto lend; } - hIC = (appinfo_t*)WININET_GetObject( hInternet ); + hIC = (LPWININETAPPINFOW) WININET_GetObject( hInternet ); if (NULL == hIC || hIC->hdr.htype != WH_HINIT) { INTERNET_SetLastError(ERROR_INTERNET_INCORRECT_HANDLE_TYPE); goto lend; @@ -2926,9 +2982,12 @@ HINTERNET WINAPI InternetOpenUrlW(HINTERNET hInternet, LPCWSTR lpszUrl, workRequest.asyncproc = AsyncInternetOpenUrlProc; workRequest.hdr = WININET_AddRef( &hIC->hdr ); - req = &workRequest.u.InternetOpenUrlW; - req->lpszUrl = heap_strdupW(lpszUrl); - req->lpszHeaders = heap_strdupW(lpszHeaders); + req = &workRequest.u.InternetOpenUrlW; + req->lpszUrl = WININET_strdupW(lpszUrl); + if (lpszHeaders) + req->lpszHeaders = WININET_strdupW(lpszHeaders); + else + req->lpszHeaders = 0; req->dwHeadersLength = dwHeadersLength; req->dwFlags = dwFlags; req->dwContext = dwContext; @@ -2962,16 +3021,20 @@ HINTERNET WINAPI InternetOpenUrlA(HINTERNET hInternet, LPCSTR lpszUrl, LPCSTR lpszHeaders, DWORD dwHeadersLength, DWORD dwFlags, DWORD_PTR dwContext) { HINTERNET rc = NULL; - DWORD lenHeaders = 0; + + INT lenUrl; + INT lenHeaders = 0; LPWSTR szUrl = NULL; LPWSTR szHeaders = NULL; TRACE("\n"); if(lpszUrl) { - szUrl = heap_strdupAtoW(lpszUrl); + lenUrl = MultiByteToWideChar(CP_ACP, 0, lpszUrl, -1, NULL, 0 ); + szUrl = HeapAlloc(GetProcessHeap(), 0, lenUrl*sizeof(WCHAR)); if(!szUrl) return NULL; + MultiByteToWideChar(CP_ACP, 0, lpszUrl, -1, szUrl, lenUrl); } if(lpszHeaders) { @@ -3204,7 +3267,7 @@ BOOL WINAPI InternetQueryDataAvailable( HINTERNET hFile, LPDWORD lpdwNumberOfBytesAvailble, DWORD dwFlags, DWORD_PTR dwContext) { - object_header_t *hdr; + WININETHANDLEHEADER *hdr; DWORD res; TRACE("(%p %p %x %lx)\n", hFile, lpdwNumberOfBytesAvailble, dwFlags, dwContext); @@ -3752,16 +3815,12 @@ DWORD WINAPI InternetConfirmZoneCrossingW( HWND hWnd, LPWSTR szUrlPrev, LPWSTR s return ERROR_SUCCESS; } -static DWORD zone_preference = 3; - /*********************************************************************** * PrivacySetZonePreferenceW (WININET.@) */ DWORD WINAPI PrivacySetZonePreferenceW( DWORD zone, DWORD type, DWORD template, LPCWSTR preference ) { FIXME( "%x %x %x %s: stub\n", zone, type, template, debugstr_w(preference) ); - - zone_preference = template; return 0; } @@ -3771,9 +3830,7 @@ DWORD WINAPI PrivacySetZonePreferenceW( DWORD zone, DWORD type, DWORD template, DWORD WINAPI PrivacyGetZonePreferenceW( DWORD zone, DWORD type, LPDWORD template, LPWSTR preference, LPDWORD length ) { - FIXME( "%x %x %p %p %p: stub\n", zone, type, template, preference, length ); - - if (template) *template = zone_preference; + FIXME( "%x %x: stub\n", zone, type ); return 0; } diff --git a/dlls/wininet/internet.h b/dlls/wininet/internet.h index 39d80831ad0..1d49eaa7c3f 100644 --- a/dlls/wininet/internet.h +++ b/dlls/wininet/internet.h @@ -55,49 +55,28 @@ typedef struct void *ssl_s; } WININET_NETCONNECTION; -static inline LPWSTR heap_strdupW(LPCWSTR str) +static inline LPWSTR WININET_strdupW( LPCWSTR str ) { - LPWSTR ret = NULL; - - if(str) { - DWORD size; - - size = (strlenW(str)+1)*sizeof(WCHAR); - ret = HeapAlloc(GetProcessHeap(), 0, size); - if(ret) - memcpy(ret, str, size); - } - + LPWSTR ret = HeapAlloc( GetProcessHeap(), 0, (strlenW(str) + 1)*sizeof(WCHAR) ); + if (ret) strcpyW( ret, str ); return ret; } -static inline WCHAR *heap_strdupAtoW(const char *str) +static inline LPWSTR WININET_strdup_AtoW( LPCSTR str ) { - LPWSTR ret = NULL; - - if(str) { - DWORD len; - - len = MultiByteToWideChar(CP_ACP, 0, str, -1, NULL, 0); - ret = HeapAlloc(GetProcessHeap(), 0, len*sizeof(WCHAR)); - if(ret) - MultiByteToWideChar(CP_ACP, 0, str, -1, ret, len); - } - + int len = MultiByteToWideChar( CP_ACP, 0, str, -1, NULL, 0); + LPWSTR ret = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) ); + if (ret) + MultiByteToWideChar( CP_ACP, 0, str, -1, ret, len); return ret; } -static inline char *heap_strdupWtoA(LPCWSTR str) +static inline LPSTR WININET_strdup_WtoA( LPCWSTR str ) { - char *ret = NULL; - - if(str) { - DWORD size = WideCharToMultiByte(CP_ACP, 0, str, -1, NULL, 0, NULL, NULL); - ret = HeapAlloc(GetProcessHeap(), 0, size); - if(ret) - WideCharToMultiByte(CP_ACP, 0, str, -1, ret, size, NULL, NULL); - } - + int len = WideCharToMultiByte( CP_ACP, 0, str, -1, NULL, 0, NULL, NULL); + LPSTR ret = HeapAlloc( GetProcessHeap(), 0, len ); + if (ret) + WideCharToMultiByte( CP_ACP, 0, str, -1, ret, len, NULL, NULL); return ret; } @@ -133,25 +112,25 @@ typedef enum #define INET_OPENURL 0x0001 #define INET_CALLBACKW 0x0002 -typedef struct _object_header_t object_header_t; +typedef struct _WININETHANDLEHEADER WININETHANDLEHEADER, *LPWININETHANDLEHEADER; typedef struct { - void (*Destroy)(object_header_t*); - void (*CloseConnection)(object_header_t*); - DWORD (*QueryOption)(object_header_t*,DWORD,void*,DWORD*,BOOL); - DWORD (*SetOption)(object_header_t*,DWORD,void*,DWORD); - DWORD (*ReadFile)(object_header_t*,void*,DWORD,DWORD*); - DWORD (*ReadFileExA)(object_header_t*,INTERNET_BUFFERSA*,DWORD,DWORD_PTR); - DWORD (*ReadFileExW)(object_header_t*,INTERNET_BUFFERSW*,DWORD,DWORD_PTR); - BOOL (*WriteFile)(object_header_t*,const void*,DWORD,DWORD*); - DWORD (*QueryDataAvailable)(object_header_t*,DWORD*,DWORD,DWORD_PTR); - DWORD (*FindNextFileW)(object_header_t*,void*); -} object_vtbl_t; - -struct _object_header_t + void (*Destroy)(WININETHANDLEHEADER*); + void (*CloseConnection)(WININETHANDLEHEADER*); + DWORD (*QueryOption)(WININETHANDLEHEADER*,DWORD,void*,DWORD*,BOOL); + DWORD (*SetOption)(WININETHANDLEHEADER*,DWORD,void*,DWORD); + DWORD (*ReadFile)(WININETHANDLEHEADER*,void*,DWORD,DWORD*); + DWORD (*ReadFileExA)(WININETHANDLEHEADER*,INTERNET_BUFFERSA*,DWORD,DWORD_PTR); + DWORD (*ReadFileExW)(WININETHANDLEHEADER*,INTERNET_BUFFERSW*,DWORD,DWORD_PTR); + BOOL (*WriteFile)(WININETHANDLEHEADER*,const void*,DWORD,DWORD*); + DWORD (*QueryDataAvailable)(WININETHANDLEHEADER*,DWORD*,DWORD,DWORD_PTR); + DWORD (*FindNextFileW)(WININETHANDLEHEADER*,void*); +} HANDLEHEADERVtbl; + +struct _WININETHANDLEHEADER { WH_TYPE htype; - const object_vtbl_t *vtbl; + const HANDLEHEADERVtbl *vtbl; HINTERNET hInternet; DWORD dwFlags; DWORD_PTR dwContext; @@ -166,29 +145,28 @@ struct _object_header_t typedef struct { - object_header_t hdr; + WININETHANDLEHEADER hdr; LPWSTR lpszAgent; LPWSTR lpszProxy; LPWSTR lpszProxyBypass; LPWSTR lpszProxyUsername; LPWSTR lpszProxyPassword; DWORD dwAccessType; -} appinfo_t; +} WININETAPPINFOW, *LPWININETAPPINFOW; typedef struct { - object_header_t hdr; - appinfo_t *lpAppInfo; + WININETHANDLEHEADER hdr; + WININETAPPINFOW *lpAppInfo; LPWSTR lpszHostName; /* the final destination of the request */ LPWSTR lpszServerName; /* the name of the server we directly connect to */ LPWSTR lpszUserName; LPWSTR lpszPassword; INTERNET_PORT nHostPort; /* the final destination port of the request */ INTERNET_PORT nServerPort; /* the port of the server we directly connect to */ - struct sockaddr_storage socketAddress; - socklen_t sa_len; -} http_session_t; + struct sockaddr_in socketAddress; +} WININETHTTPSESSIONW, *LPWININETHTTPSESSIONW; #define HDR_ISREQUEST 0x0001 #define HDR_COMMADELIMITED 0x0002 @@ -209,8 +187,8 @@ typedef struct gzip_stream_t gzip_stream_t; typedef struct { - object_header_t hdr; - http_session_t *lpHttpSession; + WININETHANDLEHEADER hdr; + WININETHTTPSESSIONW *lpHttpSession; LPWSTR lpszPath; LPWSTR lpszVerb; LPWSTR lpszRawHeaders; @@ -236,7 +214,7 @@ typedef struct BOOL decoding; gzip_stream_t *gzip_stream; -} http_request_t; +} WININETHTTPREQW, *LPWININETHTTPREQW; @@ -358,7 +336,7 @@ struct WORKREQ_INTERNETREADFILEEXW typedef struct WORKREQ { void (*asyncproc)(struct WORKREQ*); - object_header_t *hdr; + WININETHANDLEHEADER *hdr; union { struct WORKREQ_FTPPUTFILEW FtpPutFileW; @@ -382,28 +360,28 @@ typedef struct WORKREQ } WORKREQUEST, *LPWORKREQUEST; -HINTERNET WININET_AllocHandle( object_header_t *info ); -object_header_t *WININET_GetObject( HINTERNET hinternet ); -object_header_t *WININET_AddRef( object_header_t *info ); -BOOL WININET_Release( object_header_t *info ); +HINTERNET WININET_AllocHandle( LPWININETHANDLEHEADER info ); +LPWININETHANDLEHEADER WININET_GetObject( HINTERNET hinternet ); +LPWININETHANDLEHEADER WININET_AddRef( LPWININETHANDLEHEADER info ); +BOOL WININET_Release( LPWININETHANDLEHEADER info ); BOOL WININET_FreeHandle( HINTERNET hinternet ); DWORD INET_QueryOption(DWORD,void*,DWORD*,BOOL); time_t ConvertTimeString(LPCWSTR asctime); -HINTERNET FTP_Connect(appinfo_t *hIC, LPCWSTR lpszServerName, +HINTERNET FTP_Connect(LPWININETAPPINFOW hIC, LPCWSTR lpszServerName, INTERNET_PORT nServerPort, LPCWSTR lpszUserName, LPCWSTR lpszPassword, DWORD dwFlags, DWORD_PTR dwContext, DWORD dwInternalFlags); -HINTERNET HTTP_Connect(appinfo_t *hIC, LPCWSTR lpszServerName, +HINTERNET HTTP_Connect(LPWININETAPPINFOW hIC, LPCWSTR lpszServerName, INTERNET_PORT nServerPort, LPCWSTR lpszUserName, LPCWSTR lpszPassword, DWORD dwFlags, DWORD_PTR dwContext, DWORD dwInternalFlags); BOOL GetAddress(LPCWSTR lpszServerName, INTERNET_PORT nServerPort, - struct sockaddr *psa, socklen_t *sa_len); + struct sockaddr_in *psa); void INTERNET_SetLastError(DWORD dwError); DWORD INTERNET_GetLastError(void); @@ -411,19 +389,19 @@ BOOL INTERNET_AsyncCall(LPWORKREQUEST lpWorkRequest); LPSTR INTERNET_GetResponseBuffer(void); LPSTR INTERNET_GetNextLine(INT nSocket, LPDWORD dwLen); -BOOLAPI HTTP_HttpSendRequestW(http_request_t *req, LPCWSTR lpszHeaders, +BOOLAPI HTTP_HttpSendRequestW(LPWININETHTTPREQW lpwhr, LPCWSTR lpszHeaders, DWORD dwHeaderLength, LPVOID lpOptional, DWORD dwOptionalLength, DWORD dwContentLength, BOOL bEndRequest); -INTERNETAPI HINTERNET WINAPI HTTP_HttpOpenRequestW(http_session_t *session, +INTERNETAPI HINTERNET WINAPI HTTP_HttpOpenRequestW(LPWININETHTTPSESSIONW lpwhs, LPCWSTR lpszVerb, LPCWSTR lpszObjectName, LPCWSTR lpszVersion, LPCWSTR lpszReferrer , LPCWSTR *lpszAcceptTypes, DWORD dwFlags, DWORD_PTR dwContext); -VOID SendAsyncCallback(object_header_t *hdr, DWORD_PTR dwContext, +VOID SendAsyncCallback(LPWININETHANDLEHEADER hdr, DWORD_PTR dwContext, DWORD dwInternetStatus, LPVOID lpvStatusInfo, DWORD dwStatusInfoLength); -VOID INTERNET_SendCallback(object_header_t *hdr, DWORD_PTR dwContext, +VOID INTERNET_SendCallback(LPWININETHANDLEHEADER hdr, DWORD_PTR dwContext, DWORD dwInternetStatus, LPVOID lpvStatusInfo, DWORD dwStatusInfoLength); diff --git a/dlls/wininet/resource.h b/dlls/wininet/resource.h index 279c1123db8..8a6e4d152e2 100644 --- a/dlls/wininet/resource.h +++ b/dlls/wininet/resource.h @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include - -#define IDD_AUTHDLG 0x399 #define IDD_PROXYDLG 0x400 #define IDC_PROXY 0x401 @@ -29,6 +25,5 @@ #define IDC_USERNAME 0x403 #define IDC_PASSWORD 0x404 #define IDC_SAVEPASSWORD 0x405 -#define IDC_SERVER 0x406 #define IDS_LANCONNECTION 0x500 diff --git a/dlls/wininet/rsrc.rc b/dlls/wininet/rsrc.rc new file mode 100644 index 00000000000..fdf3692829f --- /dev/null +++ b/dlls/wininet/rsrc.rc @@ -0,0 +1,67 @@ +/* + * Top level resource file for Wininet + * + * Copyright 2003 Mike McCormack for CodeWeavers + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "winnls.h" + +#include "resource.h" + +/* + * Everything that does not depend on language, + * like textless bitmaps etc, go into the + * neutral language. This will prevent them from + * being duplicated for each language. + */ +/* #include "wininet_xx.rc" */ + +/* + * Everything specific to any language goes + * in one of the specific files. + * Note that you can and may override resources + * which also have a neutral version. This is to + * get localized bitmaps for example. + */ +#include "wininet_Bg.rc" +#include "wininet_Cs.rc" +#include "wininet_Da.rc" +#include "wininet_De.rc" +#include "wininet_En.rc" +#include "wininet_Eo.rc" +#include "wininet_Es.rc" +#include "wininet_Fi.rc" +#include "wininet_Fr.rc" +#include "wininet_Hu.rc" +#include "wininet_It.rc" +#include "wininet_Ja.rc" +#include "wininet_Ko.rc" +#include "wininet_Lt.rc" +#include "wininet_Nl.rc" +#include "wininet_No.rc" +#include "wininet_Pl.rc" +#include "wininet_Pt.rc" +#include "wininet_Ro.rc" +#include "wininet_Ru.rc" +#include "wininet_Si.rc" +#include "wininet_Sv.rc" +#include "wininet_Uk.rc" +#include "wininet_Tr.rc" +#include "wininet_Zh.rc" diff --git a/dlls/wininet/tests/http.c b/dlls/wininet/tests/http.c index b11cb2cddeb..ba72629428d 100644 --- a/dlls/wininet/tests/http.c +++ b/dlls/wininet/tests/http.c @@ -1146,7 +1146,7 @@ static void test_http_cache(void) file = CreateFile(file_name, GENERIC_READ, FILE_SHARE_READ|FILE_SHARE_WRITE, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL); - ok(file != INVALID_HANDLE_VALUE, "Could not create file: %u\n", GetLastError()); + todo_wine ok(file != INVALID_HANDLE_VALUE, "Could not create file: %u\n", GetLastError()); CloseHandle(file); request = HttpOpenRequestA(connect, NULL, "/", NULL, NULL, types, INTERNET_FLAG_NO_CACHE_WRITE, 0); @@ -1482,18 +1482,9 @@ done: ok(InternetCloseHandle(hSession), "Close session handle failed\n"); } -static const char garbagemsg[] = -"Garbage: Header\r\n"; - static const char contmsg[] = "HTTP/1.1 100 Continue\r\n"; -static const char expandcontmsg[] = -"HTTP/1.1 100 Continue\r\n" -"Server: winecontinue\r\n" -"Tag: something witty\r\n" -"\r\n"; - static const char okmsg[] = "HTTP/1.1 200 OK\r\n" "Server: winetest\r\n" @@ -1719,15 +1710,6 @@ static DWORD CALLBACK server_thread(LPVOID param) send(c, page1, sizeof page1-1, 0); last_request = 1; } - if (strstr(buffer, "GET /testF")) - { - send(c, expandcontmsg, sizeof expandcontmsg-1, 0); - send(c, garbagemsg, sizeof garbagemsg-1, 0); - send(c, contmsg, sizeof contmsg-1, 0); - send(c, garbagemsg, sizeof garbagemsg-1, 0); - send(c, okmsg, sizeof okmsg-1, 0); - send(c, page1, sizeof page1-1, 0); - } shutdown(c, 2); closesocket(c); @@ -1788,12 +1770,7 @@ static void test_proxy_indirect(int port) sz = sizeof buffer; r = HttpQueryInfo(hr, HTTP_QUERY_PROXY_AUTHENTICATE, buffer, &sz, NULL); - ok(r || GetLastError() == ERROR_HTTP_HEADER_NOT_FOUND, "HttpQueryInfo failed: %d\n", GetLastError()); - if (!r) - { - skip("missing proxy header, not testing remaining proxy headers\n"); - goto out; - } + ok(r, "HttpQueryInfo failed\n"); ok(!strcmp(buffer, "Basic realm=\"placebo\""), "proxy auth info wrong\n"); sz = sizeof buffer; @@ -1826,7 +1803,6 @@ static void test_proxy_indirect(int port) ok(GetLastError() == ERROR_HTTP_HEADER_NOT_FOUND, "HttpQueryInfo should fail\n"); ok(r == FALSE, "HttpQueryInfo failed\n"); -out: InternetCloseHandle(hr); InternetCloseHandle(hc); InternetCloseHandle(hi); @@ -2340,7 +2316,6 @@ static void test_http_connection(void) test_basic_request(si.port, "RPC_IN_DATA", "/test5"); test_basic_request(si.port, "RPC_OUT_DATA", "/test5"); test_basic_request(si.port, "GET", "/test6"); - test_basic_request(si.port, "GET", "/testF"); test_connection_header(si.port); test_http1_1(si.port); test_cookie_header(si.port); diff --git a/dlls/wininet/tests/internet.c b/dlls/wininet/tests/internet.c index 728c8dc2755..5f36c3d9354 100644 --- a/dlls/wininet/tests/internet.c +++ b/dlls/wininet/tests/internet.c @@ -795,33 +795,6 @@ static void test_IsDomainLegalCookieDomainW(void) ok(!ret, "IsDomainLegalCookieDomainW succeeded\n"); } -static void test_PrivacyGetSetZonePreferenceW(void) -{ - DWORD ret, zone, type, template, old_template; - - zone = 3; - type = 0; - ret = PrivacyGetZonePreferenceW(zone, type, NULL, NULL, NULL); - ok(ret == 0, "expected ret == 0, got %u\n", ret); - - old_template = 0; - ret = PrivacyGetZonePreferenceW(zone, type, &old_template, NULL, NULL); - ok(ret == 0, "expected ret == 0, got %u\n", ret); - - template = 5; - ret = PrivacySetZonePreferenceW(zone, type, template, NULL); - ok(ret == 0, "expected ret == 0, got %u\n", ret); - - template = 0; - ret = PrivacyGetZonePreferenceW(zone, type, &template, NULL, NULL); - ok(ret == 0, "expected ret == 0, got %u\n", ret); - ok(template == 5, "expected template == 5, got %u\n", template); - - template = 5; - ret = PrivacySetZonePreferenceW(zone, type, old_template, NULL); - ok(ret == 0, "expected ret == 0, got %u\n", ret); -} - /* ############################### */ START_TEST(internet) @@ -860,6 +833,4 @@ START_TEST(internet) win_skip("IsDomainLegalCookieDomainW (or ordinal 117) is not available\n"); else test_IsDomainLegalCookieDomainW(); - - test_PrivacyGetSetZonePreferenceW(); } diff --git a/dlls/wininet/urlcache.c b/dlls/wininet/urlcache.c index 0b29a6e9a7b..418f508f650 100644 --- a/dlls/wininet/urlcache.c +++ b/dlls/wininet/urlcache.c @@ -465,6 +465,7 @@ static void URLCacheContainer_CloseIndex(URLCACHECONTAINER * pContainer) static BOOL URLCacheContainers_AddContainer(LPCWSTR cache_prefix, LPCWSTR path, LPWSTR mutex_name) { URLCACHECONTAINER * pContainer = HeapAlloc(GetProcessHeap(), 0, sizeof(URLCACHECONTAINER)); + int path_len = strlenW(path); int cache_prefix_len = strlenW(cache_prefix); if (!pContainer) @@ -475,13 +476,15 @@ static BOOL URLCacheContainers_AddContainer(LPCWSTR cache_prefix, LPCWSTR path, pContainer->hMapping = NULL; pContainer->file_size = 0; - pContainer->path = heap_strdupW(path); + pContainer->path = HeapAlloc(GetProcessHeap(), 0, (path_len + 1) * sizeof(WCHAR)); if (!pContainer->path) { HeapFree(GetProcessHeap(), 0, pContainer); return FALSE; } + memcpy(pContainer->path, path, (path_len + 1) * sizeof(WCHAR)); + pContainer->cache_prefix = HeapAlloc(GetProcessHeap(), 0, (cache_prefix_len + 1) * sizeof(WCHAR)); if (!pContainer->cache_prefix) { @@ -590,9 +593,6 @@ static DWORD URLCacheContainers_FindContainerW(LPCWSTR lpwszUrl, URLCACHECONTAIN TRACE("searching for prefix for URL: %s\n", debugstr_w(lpwszUrl)); - if(!lpwszUrl) - return ERROR_INVALID_PARAMETER; - LIST_FOR_EACH_ENTRY(pContainer, &UrlContainers, URLCACHECONTAINER, entry) { int prefix_len = strlenW(pContainer->cache_prefix); @@ -609,15 +609,17 @@ static DWORD URLCacheContainers_FindContainerW(LPCWSTR lpwszUrl, URLCACHECONTAIN static DWORD URLCacheContainers_FindContainerA(LPCSTR lpszUrl, URLCACHECONTAINER ** ppContainer) { - LPWSTR url = NULL; DWORD ret; - - if (lpszUrl && !(url = heap_strdupAtoW(lpszUrl))) - return ERROR_OUTOFMEMORY; - - ret = URLCacheContainers_FindContainerW(url, ppContainer); - HeapFree(GetProcessHeap(), 0, url); - return ret; + LPWSTR lpwszUrl; + int url_len = MultiByteToWideChar(CP_ACP, 0, lpszUrl, -1, NULL, 0); + if (url_len && (lpwszUrl = HeapAlloc(GetProcessHeap(), 0, url_len * sizeof(WCHAR)))) + { + MultiByteToWideChar(CP_ACP, 0, lpszUrl, -1, lpwszUrl, url_len); + ret = URLCacheContainers_FindContainerW(lpwszUrl, ppContainer); + HeapFree(GetProcessHeap(), 0, lpwszUrl); + return ret; + } + return GetLastError(); } static BOOL URLCacheContainers_Enum(LPCWSTR lpwszSearchPattern, DWORD dwIndex, URLCACHECONTAINER ** ppContainer) @@ -1239,15 +1241,17 @@ static BOOL URLCache_FindHash(LPCURLCACHE_HEADER pHeader, LPCSTR lpszUrl, struct static BOOL URLCache_FindHashW(LPCURLCACHE_HEADER pHeader, LPCWSTR lpszUrl, struct _HASH_ENTRY ** ppHashEntry) { LPSTR urlA; + int url_len; BOOL ret; - urlA = heap_strdupWtoA(lpszUrl); + url_len = WideCharToMultiByte(CP_ACP, 0, lpszUrl, -1, NULL, 0, NULL, NULL); + urlA = HeapAlloc(GetProcessHeap(), 0, url_len * sizeof(CHAR)); if (!urlA) { SetLastError(ERROR_OUTOFMEMORY); return FALSE; } - + WideCharToMultiByte(CP_ACP, 0, lpszUrl, -1, urlA, url_len, NULL, NULL); ret = URLCache_FindHash(pHeader, urlA, ppHashEntry); HeapFree(GetProcessHeap(), 0, urlA); return ret; @@ -2139,16 +2143,21 @@ BOOL WINAPI CreateUrlCacheEntryA( IN DWORD dwReserved ) { + DWORD len; WCHAR *url_name; WCHAR *file_extension; WCHAR file_name[MAX_PATH]; BOOL bSuccess = FALSE; DWORD dwError = 0; - if (lpszUrlName && (url_name = heap_strdupAtoW(lpszUrlName))) + if ((len = MultiByteToWideChar(CP_ACP, 0, lpszUrlName, -1, NULL, 0)) != 0 && + (url_name = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR))) != 0) { - if (lpszFileExtension && (file_extension = heap_strdupAtoW(lpszFileExtension))) + MultiByteToWideChar(CP_ACP, 0, lpszUrlName, -1, url_name, len); + if ((len = MultiByteToWideChar(CP_ACP, 0, lpszFileExtension, -1, NULL, 0)) != 0 && + (file_extension = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR))) != 0) { + MultiByteToWideChar(CP_ACP, 0, lpszFileExtension, -1, file_extension, len); if (CreateUrlCacheEntryW(url_name, dwExpectedFileSize, file_extension, file_name, dwReserved)) { if (WideCharToMultiByte(CP_ACP, 0, file_name, -1, lpszFileName, MAX_PATH, NULL, NULL) < MAX_PATH) @@ -2435,17 +2444,25 @@ static BOOL CommitUrlCacheEntryInternal( if (!(pHeader = URLCacheContainer_LockIndex(pContainer))) return FALSE; - lpszUrlNameA = heap_strdupWtoA(lpszUrlName); + len = WideCharToMultiByte(CP_ACP, 0, lpszUrlName, -1, NULL, 0, NULL, NULL); + lpszUrlNameA = HeapAlloc(GetProcessHeap(), 0, len * sizeof(char)); if (!lpszUrlNameA) { error = GetLastError(); goto cleanup; } + WideCharToMultiByte(CP_ACP, 0, lpszUrlName, -1, lpszUrlNameA, len, NULL, NULL); - if (lpszFileExtension && !(lpszFileExtensionA = heap_strdupWtoA(lpszFileExtension))) + if (lpszFileExtension) { - error = GetLastError(); - goto cleanup; + len = WideCharToMultiByte(CP_ACP, 0, lpszFileExtension, -1, NULL, 0, NULL, NULL); + lpszFileExtensionA = HeapAlloc(GetProcessHeap(), 0, len * sizeof(char)); + if (!lpszFileExtensionA) + { + error = GetLastError(); + goto cleanup; + } + WideCharToMultiByte(CP_ACP, 0, lpszFileExtension, -1, lpszFileExtensionA, len, NULL, NULL); } if (URLCache_FindHash(pHeader, lpszUrlNameA, &pHashEntry)) @@ -2602,6 +2619,7 @@ BOOL WINAPI CommitUrlCacheEntryA( IN LPCSTR lpszOriginalUrl ) { + DWORD len; WCHAR *url_name = NULL; WCHAR *local_file_name = NULL; WCHAR *original_url = NULL; @@ -2617,27 +2635,35 @@ BOOL WINAPI CommitUrlCacheEntryA( debugstr_a(lpszFileExtension), debugstr_a(lpszOriginalUrl)); - url_name = heap_strdupAtoW(lpszUrlName); + len = MultiByteToWideChar(CP_ACP, 0, lpszUrlName, -1, NULL, 0); + url_name = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); if (!url_name) goto cleanup; + MultiByteToWideChar(CP_ACP, 0, lpszUrlName, -1, url_name, len); if (lpszLocalFileName) { - local_file_name = heap_strdupAtoW(lpszLocalFileName); + len = MultiByteToWideChar(CP_ACP, 0, lpszLocalFileName, -1, NULL, 0); + local_file_name = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); if (!local_file_name) goto cleanup; + MultiByteToWideChar(CP_ACP, 0, lpszLocalFileName, -1, local_file_name, len); } if (lpszFileExtension) { - file_extension = heap_strdupAtoW(lpszFileExtension); + len = MultiByteToWideChar(CP_ACP, 0, lpszFileExtension, -1, NULL, 0); + file_extension = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); if (!file_extension) goto cleanup; + MultiByteToWideChar(CP_ACP, 0, lpszFileExtension, -1, file_extension, len); } if (lpszOriginalUrl) { - original_url = heap_strdupAtoW(lpszOriginalUrl); + len = MultiByteToWideChar(CP_ACP, 0, lpszOriginalUrl, -1, NULL, 0); + original_url = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); if (!original_url) goto cleanup; + MultiByteToWideChar(CP_ACP, 0, lpszOriginalUrl, -1, original_url, len); } bSuccess = CommitUrlCacheEntryInternal(url_name, local_file_name, ExpireTime, LastModifiedTime, @@ -2683,8 +2709,12 @@ BOOL WINAPI CommitUrlCacheEntryW( debugstr_w(lpszFileExtension), debugstr_w(lpszOriginalUrl)); - if (!lpHeaderInfo || (header_info = heap_strdupWtoA(lpHeaderInfo))) + if (!lpHeaderInfo || + ((len = WideCharToMultiByte(CP_ACP, 0, lpHeaderInfo, -1, NULL, 0, NULL, NULL)) != 0 && + (header_info = HeapAlloc(GetProcessHeap(), 0, sizeof(CHAR) * len)) != 0)) { + if (header_info) + WideCharToMultiByte(CP_ACP, 0, lpHeaderInfo, -1, header_info, len, NULL, NULL); if (CommitUrlCacheEntryInternal(lpszUrlName, lpszLocalFileName, ExpireTime, LastModifiedTime, CacheEntryType, (LPBYTE)header_info, len, lpszFileExtension, lpszOriginalUrl)) { @@ -2907,16 +2937,19 @@ BOOL WINAPI DeleteUrlCacheEntryW(LPCWSTR lpszUrlName) struct _HASH_ENTRY * pHashEntry; CACHEFILE_ENTRY * pEntry; LPSTR urlA; + int url_len; DWORD error; TRACE("(%s)\n", debugstr_w(lpszUrlName)); - urlA = heap_strdupWtoA(lpszUrlName); + url_len = WideCharToMultiByte(CP_ACP, 0, lpszUrlName, -1, NULL, 0, NULL, NULL); + urlA = HeapAlloc(GetProcessHeap(), 0, url_len * sizeof(CHAR)); if (!urlA) { SetLastError(ERROR_OUTOFMEMORY); return FALSE; } + WideCharToMultiByte(CP_ACP, 0, lpszUrlName, -1, urlA, url_len, NULL, NULL); error = URLCacheContainers_FindContainerW(lpszUrlName, &pContainer); if (error != ERROR_SUCCESS) @@ -3097,12 +3130,14 @@ INTERNETAPI HANDLE WINAPI FindFirstUrlCacheEntryA(LPCSTR lpszUrlSearchPattern, pEntryHandle->dwMagic = URLCACHE_FIND_ENTRY_HANDLE_MAGIC; if (lpszUrlSearchPattern) { - pEntryHandle->lpszUrlSearchPattern = heap_strdupAtoW(lpszUrlSearchPattern); + int len = MultiByteToWideChar(CP_ACP, 0, lpszUrlSearchPattern, -1, NULL, 0); + pEntryHandle->lpszUrlSearchPattern = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); if (!pEntryHandle->lpszUrlSearchPattern) { HeapFree(GetProcessHeap(), 0, pEntryHandle); return NULL; } + MultiByteToWideChar(CP_ACP, 0, lpszUrlSearchPattern, -1, pEntryHandle->lpszUrlSearchPattern, len); } else pEntryHandle->lpszUrlSearchPattern = NULL; @@ -3136,12 +3171,14 @@ INTERNETAPI HANDLE WINAPI FindFirstUrlCacheEntryW(LPCWSTR lpszUrlSearchPattern, pEntryHandle->dwMagic = URLCACHE_FIND_ENTRY_HANDLE_MAGIC; if (lpszUrlSearchPattern) { - pEntryHandle->lpszUrlSearchPattern = heap_strdupW(lpszUrlSearchPattern); + int len = strlenW(lpszUrlSearchPattern); + pEntryHandle->lpszUrlSearchPattern = HeapAlloc(GetProcessHeap(), 0, (len + 1) * sizeof(WCHAR)); if (!pEntryHandle->lpszUrlSearchPattern) { HeapFree(GetProcessHeap(), 0, pEntryHandle); return NULL; } + memcpy(pEntryHandle->lpszUrlSearchPattern, lpszUrlSearchPattern, (len + 1) * sizeof(WCHAR)); } else pEntryHandle->lpszUrlSearchPattern = NULL; diff --git a/dlls/wininet/utility.c b/dlls/wininet/utility.c index 66fbecdd653..b68cf8d4a57 100644 --- a/dlls/wininet/utility.c +++ b/dlls/wininet/utility.c @@ -145,7 +145,7 @@ time_t ConvertTimeString(LPCWSTR asctime) BOOL GetAddress(LPCWSTR lpszServerName, INTERNET_PORT nServerPort, - struct sockaddr *psa, socklen_t *sa_len) + struct sockaddr_in *psa) { WCHAR *found; char *name; @@ -155,7 +155,6 @@ BOOL GetAddress(LPCWSTR lpszServerName, INTERNET_PORT nServerPort, int ret; #else struct hostent *phe; - struct sockaddr_in *sin = (struct sockaddr_in *)psa; #endif TRACE("%s\n", debugstr_w(lpszServerName)); @@ -178,42 +177,19 @@ BOOL GetAddress(LPCWSTR lpszServerName, INTERNET_PORT nServerPort, #ifdef HAVE_GETADDRINFO memset( &hints, 0, sizeof(struct addrinfo) ); - /* Prefer IPv4 to IPv6 addresses, since some servers do not listen on - * their IPv6 addresses even though they have IPv6 addresses in the DNS. - */ hints.ai_family = AF_INET; ret = getaddrinfo( name, NULL, &hints, &res ); HeapFree( GetProcessHeap(), 0, name ); if (ret != 0) { - TRACE("failed to get IPv4 address of %s (%s), retrying with IPv6\n", debugstr_w(lpszServerName), gai_strerror(ret)); - hints.ai_family = AF_INET6; - ret = getaddrinfo( name, NULL, &hints, &res ); - if (ret != 0) - { - TRACE("failed to get address of %s (%s)\n", debugstr_w(lpszServerName), gai_strerror(ret)); - return FALSE; - } - } - if (*sa_len < res->ai_addrlen) - { - WARN("address too small\n"); - freeaddrinfo( res ); + TRACE("failed to get address of %s (%s)\n", debugstr_w(lpszServerName), gai_strerror(ret)); return FALSE; } - *sa_len = res->ai_addrlen; - memcpy( psa, res->ai_addr, res->ai_addrlen ); - /* Copy port */ - switch (res->ai_family) - { - case AF_INET: - ((struct sockaddr_in *)psa)->sin_port = htons(nServerPort); - break; - case AF_INET6: - ((struct sockaddr_in6 *)psa)->sin6_port = htons(nServerPort); - break; - } + memset( psa, 0, sizeof(struct sockaddr_in) ); + memcpy( &psa->sin_addr, &((struct sockaddr_in *)res->ai_addr)->sin_addr, sizeof(struct in_addr) ); + psa->sin_family = res->ai_family; + psa->sin_port = htons(nServerPort); freeaddrinfo( res ); #else @@ -227,17 +203,10 @@ BOOL GetAddress(LPCWSTR lpszServerName, INTERNET_PORT nServerPort, LeaveCriticalSection( &cs_gethostbyname ); return FALSE; } - if (*sa_len < sizeof(struct sockaddr_in)) - { - WARN("address too small\n"); - LeaveCriticalSection( &cs_gethostbyname ); - return FALSE; - } - *sa_len = sizeof(struct sockaddr_in); - memset(sin,0,sizeof(struct sockaddr_in)); - memcpy((char *)&sin->sin_addr, phe->h_addr, phe->h_length); - sin->sin_family = phe->h_addrtype; - sin->sin_port = htons(nServerPort); + memset(psa,0,sizeof(struct sockaddr_in)); + memcpy((char *)&psa->sin_addr, phe->h_addr, phe->h_length); + psa->sin_family = phe->h_addrtype; + psa->sin_port = htons(nServerPort); LeaveCriticalSection( &cs_gethostbyname ); #endif @@ -286,7 +255,7 @@ static const char *get_callback_name(DWORD dwInternetStatus) { return "Unknown"; } -VOID INTERNET_SendCallback(object_header_t *hdr, DWORD_PTR dwContext, +VOID INTERNET_SendCallback(LPWININETHANDLEHEADER hdr, DWORD_PTR dwContext, DWORD dwInternetStatus, LPVOID lpvStatusInfo, DWORD dwStatusInfoLength) { @@ -306,11 +275,11 @@ VOID INTERNET_SendCallback(object_header_t *hdr, DWORD_PTR dwContext, case INTERNET_STATUS_NAME_RESOLVED: case INTERNET_STATUS_CONNECTING_TO_SERVER: case INTERNET_STATUS_CONNECTED_TO_SERVER: - lpvNewInfo = heap_strdupAtoW(lpvStatusInfo); + lpvNewInfo = WININET_strdup_AtoW(lpvStatusInfo); break; case INTERNET_STATUS_RESOLVING_NAME: case INTERNET_STATUS_REDIRECT: - lpvNewInfo = heap_strdupW(lpvStatusInfo); + lpvNewInfo = WININET_strdupW(lpvStatusInfo); break; } }else { @@ -324,7 +293,7 @@ VOID INTERNET_SendCallback(object_header_t *hdr, DWORD_PTR dwContext, break; case INTERNET_STATUS_RESOLVING_NAME: case INTERNET_STATUS_REDIRECT: - lpvNewInfo = heap_strdupWtoA(lpvStatusInfo); + lpvNewInfo = WININET_strdup_WtoA(lpvStatusInfo); break; } } @@ -356,7 +325,7 @@ static void SendAsyncCallbackProc(WORKREQUEST *workRequest) HeapFree(GetProcessHeap(), 0, req->lpvStatusInfo); } -void SendAsyncCallback(object_header_t *hdr, DWORD_PTR dwContext, +VOID SendAsyncCallback(LPWININETHANDLEHEADER hdr, DWORD_PTR dwContext, DWORD dwInternetStatus, LPVOID lpvStatusInfo, DWORD dwStatusInfoLength) { diff --git a/dlls/wininet/wininet_Bg.rc b/dlls/wininet/wininet_Bg.rc index b25356e074e..52d797ed751 100644 --- a/dlls/wininet/wininet_Bg.rc +++ b/dlls/wininet/wininet_Bg.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_Cs.rc b/dlls/wininet/wininet_Cs.rc index 443c0175190..9ca75397c4f 100644 --- a/dlls/wininet/wininet_Cs.rc +++ b/dlls/wininet/wininet_Cs.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/dlls/wininet/wininet_Da.rc b/dlls/wininet/wininet_Da.rc index 6b37857ed54..515dcabd8b3 100644 --- a/dlls/wininet/wininet_Da.rc +++ b/dlls/wininet/wininet_Da.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_De.rc b/dlls/wininet/wininet_De.rc index f602a97a97d..9fb6be58c8d 100644 --- a/dlls/wininet/wininet_De.rc +++ b/dlls/wininet/wininet_De.rc @@ -1,6 +1,5 @@ /* * Copyright 2004 Henning Gerhardt - * Copyright 2009 André Hentschel * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -17,10 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 @@ -30,8 +25,8 @@ FONT 8, "MS Shell Dlg" { LTEXT "Geben Sie Benutzernamen und Kennwort ein:", -1, 40, 6, 150, 15 LTEXT "Proxy", -1, 40, 26, 50, 10 - LTEXT "Bereich", -1, 40, 46, 50, 10 - LTEXT "Ben&utzer", -1, 40, 66, 50, 10 + LTEXT "Realm", -1, 40, 46, 50, 10 + LTEXT "Ben&utzername", -1, 40, 66, 50, 10 LTEXT "Kenn&wort", -1, 40, 86, 50, 10 LTEXT "" IDC_PROXY, 80, 26, 150, 14, 0 LTEXT "" IDC_REALM, 80, 46, 150, 14, 0 @@ -43,26 +38,6 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "Abbrechen", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP } -IDD_AUTHDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Benutzeranmeldung" -FONT 8, "MS Shell Dlg" -{ - LTEXT "Geben Sie Benutzernamen und Kennwort ein:", -1, 40, 6, 150, 15 - LTEXT "Server", -1, 40, 26, 50, 10 - LTEXT "Bereich", -1, 40, 46, 50, 10 - LTEXT "Benutzer", -1, 40, 66, 50, 10 - LTEXT "Kennwort", -1, 40, 86, 50, 10 - LTEXT "" IDC_SERVER, 80, 26, 150, 14, 0 - LTEXT "" IDC_REALM, 80, 46, 150, 14, 0 - EDITTEXT IDC_USERNAME, 80, 66, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP - EDITTEXT IDC_PASSWORD, 80, 86, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP | ES_PASSWORD - CHECKBOX "Dieses &Kennwort speichern (unsicher)", IDC_SAVEPASSWORD, - 80, 106, 150, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON "OK", IDOK, 98, 126, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON - PUSHBUTTON "Abbrechen", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP -} - STRINGTABLE DISCARDABLE { IDS_LANCONNECTION "LAN Verbindung" diff --git a/dlls/wininet/wininet_En.rc b/dlls/wininet/wininet_En.rc index d22d249f1cd..66837dabc8e 100644 --- a/dlls/wininet/wininet_En.rc +++ b/dlls/wininet/wininet_En.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 @@ -40,26 +38,6 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "Cancel", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP } -IDD_AUTHDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Authentication Required" -FONT 8, "MS Shell Dlg" -{ - LTEXT "Please enter your username and password:", -1, 40, 6, 150, 15 - LTEXT "Server", -1, 40, 26, 50, 10 - LTEXT "Realm", -1, 40, 46, 50, 10 - LTEXT "User", -1, 40, 66, 50, 10 - LTEXT "Password", -1, 40, 86, 50, 10 - LTEXT "" IDC_SERVER, 80, 26, 150, 14, 0 - LTEXT "" IDC_REALM, 80, 46, 150, 14, 0 - EDITTEXT IDC_USERNAME, 80, 66, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP - EDITTEXT IDC_PASSWORD, 80, 86, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP | ES_PASSWORD - CHECKBOX "&Save this password (insecure)", IDC_SAVEPASSWORD, - 80, 106, 150, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON "OK", IDOK, 98, 126, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON - PUSHBUTTON "Cancel", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP -} - STRINGTABLE DISCARDABLE { IDS_LANCONNECTION "LAN Connection" diff --git a/dlls/wininet/wininet_Eo.rc b/dlls/wininet/wininet_Eo.rc index 3fa19f37897..a145e263621 100644 --- a/dlls/wininet/wininet_Eo.rc +++ b/dlls/wininet/wininet_Eo.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_Es.rc b/dlls/wininet/wininet_Es.rc index c9ce2cebbe2..bbf08aeb2f6 100644 --- a/dlls/wininet/wininet_Es.rc +++ b/dlls/wininet/wininet_Es.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_Fi.rc b/dlls/wininet/wininet_Fi.rc index df5ca723044..176a00337ce 100644 --- a/dlls/wininet/wininet_Fi.rc +++ b/dlls/wininet/wininet_Fi.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_Fr.rc b/dlls/wininet/wininet_Fr.rc dissimilarity index 62% index 74ee208a7ee..0435b8eb711 100644 --- a/dlls/wininet/wininet_Fr.rc +++ b/dlls/wininet/wininet_Fr.rc @@ -1,75 +1,49 @@ -/* - * Wininet - * French language support - * - * Copyright 2003 Mike McCormack for CodeWeavers - * Copyright 2003 Vincent Béron - * Copyright 2005 Jonathan Ernst - * Copyright 2009 Frédéric Delanoy - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL - -IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 218, 150 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Entrez le mot de passe réseau" -FONT 8, "MS Shell Dlg" -{ - LTEXT "Entrez votre nom d'utilisateur et votre mot de passe :", -1, 10, 8, 173, 12 - LTEXT "Serveur mandataire", -1, 10, 28, 50, 17 - LTEXT "Domaine", -1, 10, 50, 50, 10 - LTEXT "Utilisateur", -1, 10, 71, 50, 10 - LTEXT "Mot de passe", -1, 10, 90, 50, 10 - LTEXT "" IDC_PROXY, 58, 28, 150, 14, 0 - LTEXT "" IDC_REALM, 58, 48, 150, 14, 0 - EDITTEXT IDC_USERNAME, 58, 68, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP - EDITTEXT IDC_PASSWORD, 58, 88, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP | ES_PASSWORD - CHECKBOX "&Enregistrer ce mot de passe (risqué)", IDC_SAVEPASSWORD, - 58, 108, 150, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON "OK", IDOK, 87, 128, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON - PUSHBUTTON "Annuler", IDCANCEL, 147, 128, 56, 14, WS_GROUP | WS_TABSTOP -} - -IDD_AUTHDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 218, 150 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Authentification requise" -FONT 8, "MS Shell Dlg" -{ - LTEXT "Entrez votre nom d'utilisateur et votre mot de passe :", -1, 10, 8, 173, 12 - LTEXT "Serveur", -1, 10, 28, 50, 17 - LTEXT "Domaine", -1, 10, 50, 50, 10 - LTEXT "Utilisateur", -1, 10, 71, 50, 10 - LTEXT "Mot de passe", -1, 10, 90, 50, 10 - LTEXT "" IDC_SERVER, 58, 28, 150, 14, 0 - LTEXT "" IDC_REALM, 58, 48, 150, 14, 0 - EDITTEXT IDC_USERNAME, 58, 68, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP - EDITTEXT IDC_PASSWORD, 58, 88, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP | ES_PASSWORD - CHECKBOX "&Enregistrer ce mot de passe (risqué)", IDC_SAVEPASSWORD, - 58, 108, 150, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON "OK", IDOK, 87, 128, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON - PUSHBUTTON "Annuler", IDCANCEL, 147, 128, 56, 14, WS_GROUP | WS_TABSTOP -} - -STRINGTABLE DISCARDABLE -{ - IDS_LANCONNECTION "Connexion réseau local (LAN)" -} +/* + * Wininet + * French language support + * + * Copyright 2003 Mike McCormack for CodeWeavers + * Copyright 2003 Vincent Béron + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL + +IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Entrez le mot de passe réseau" +FONT 8, "MS Shell Dlg" +{ + LTEXT "Entrez votre nom d'utilisateur et votre mot de passe :", -1, 40, 6, 150, 15 + LTEXT "Mandataire", -1, 40, 26, 50, 10 + LTEXT "Domaine", -1, 40, 46, 50, 10 + LTEXT "Utilisateur", -1, 40, 66, 50, 10 + LTEXT "Mot de passe", -1, 40, 86, 50, 10 + LTEXT "" IDC_PROXY, 80, 26, 150, 14, 0 + LTEXT "" IDC_REALM, 80, 46, 150, 14, 0 + EDITTEXT IDC_USERNAME, 80, 66, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP + EDITTEXT IDC_PASSWORD, 80, 86, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP | ES_PASSWORD + CHECKBOX "&Enregistrer ce mot de passe (risqué)", IDC_SAVEPASSWORD, + 80, 106, 150, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 98, 126, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON + PUSHBUTTON "Annuler", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP +} + +STRINGTABLE DISCARDABLE +{ + IDS_LANCONNECTION "Connexion LAN" +} diff --git a/dlls/wininet/wininet_Hu.rc b/dlls/wininet/wininet_Hu.rc index b19e03dc007..c9704f9080b 100644 --- a/dlls/wininet/wininet_Hu.rc +++ b/dlls/wininet/wininet_Hu.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_It.rc b/dlls/wininet/wininet_It.rc index 911b8a9428e..45045460c33 100644 --- a/dlls/wininet/wininet_It.rc +++ b/dlls/wininet/wininet_It.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_Ja.rc b/dlls/wininet/wininet_Ja.rc index e179b849254..615d7be1c86 100644 --- a/dlls/wininet/wininet_Ja.rc +++ b/dlls/wininet/wininet_Ja.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -47,3 +45,5 @@ STRINGTABLE DISCARDABLE { IDS_LANCONNECTION "LAN 接続" } + +#pragma code_page(default) diff --git a/dlls/wininet/wininet_Ko.rc b/dlls/wininet/wininet_Ko.rc index 5c2595a9b37..26ed4a2fad2 100644 --- a/dlls/wininet/wininet_Ko.rc +++ b/dlls/wininet/wininet_Ko.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_Lt.rc b/dlls/wininet/wininet_Lt.rc index cd4bf482e35..bf5dbf2f212 100644 --- a/dlls/wininet/wininet_Lt.rc +++ b/dlls/wininet/wininet_Lt.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -43,27 +41,9 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "Atsisakyti", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP } -IDD_AUTHDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Reikalingas tapatumo nustatymas" -FONT 8, "MS Shell Dlg" -{ - LTEXT "Įveskite savo naudotojo vardą ir slaptažodį:", -1, 40, 6, 150, 15 - LTEXT "Serveris", -1, 40, 26, 50, 10 - LTEXT "Sritis", -1, 40, 46, 50, 10 - LTEXT "Naudotojas", -1, 40, 66, 50, 10 - LTEXT "Slaptažodis", -1, 40, 86, 50, 10 - LTEXT "" IDC_SERVER, 80, 26, 150, 14, 0 - LTEXT "" IDC_REALM, 80, 46, 150, 14, 0 - EDITTEXT IDC_USERNAME, 80, 66, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP - EDITTEXT IDC_PASSWORD, 80, 86, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP | ES_PASSWORD - CHECKBOX "Į&rašyti šį slaptažodį (nesaugu)", IDC_SAVEPASSWORD, - 80, 106, 150, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Gerai", IDOK, 98, 126, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON - PUSHBUTTON "Atsisakyti", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP -} - STRINGTABLE DISCARDABLE { IDS_LANCONNECTION "Vietinio tinklo ryšys" } + +#pragma code_page(default) diff --git a/dlls/wininet/wininet_Nl.rc b/dlls/wininet/wininet_Nl.rc index f0e891c7e19..16c80ccaad8 100644 --- a/dlls/wininet/wininet_Nl.rc +++ b/dlls/wininet/wininet_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 @@ -42,26 +40,6 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "Annuleren", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP } -IDD_AUTHDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Authenticatie vereist" -FONT 8, "MS Shell Dlg" -{ - LTEXT "Voer uw gebruikersnaam en wachtwoord in:", -1, 40, 6, 150, 15 - LTEXT "Server", -1, 40, 26, 50, 10 - LTEXT "Realm", -1, 40, 46, 50, 10 - LTEXT "Gebruikersnaam", -1, 40, 66, 50, 10 - LTEXT "Wachtwoord", -1, 40, 86, 50, 10 - LTEXT "" IDC_SERVER, 80, 26, 150, 14, 0 - LTEXT "" IDC_REALM, 80, 46, 150, 14, 0 - EDITTEXT IDC_USERNAME, 80, 66, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP - EDITTEXT IDC_PASSWORD, 80, 86, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP | ES_PASSWORD - CHECKBOX "&Wachtwoord opslaan (onveilig)", IDC_SAVEPASSWORD, - 80, 106, 150, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON "OK", IDOK, 98, 126, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON - PUSHBUTTON "Annuleren", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP -} - STRINGTABLE DISCARDABLE { IDS_LANCONNECTION "LAN Verbinding" diff --git a/dlls/wininet/wininet_No.rc b/dlls/wininet/wininet_No.rc index 5ba61f5e80c..fb885e9030d 100644 --- a/dlls/wininet/wininet_No.rc +++ b/dlls/wininet/wininet_No.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_Pl.rc b/dlls/wininet/wininet_Pl.rc index 0c76d5335aa..7ddb399a584 100644 --- a/dlls/wininet/wininet_Pl.rc +++ b/dlls/wininet/wininet_Pl.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_Pt.rc b/dlls/wininet/wininet_Pt.rc index a968ab48c16..57dd625a740 100644 --- a/dlls/wininet/wininet_Pt.rc +++ b/dlls/wininet/wininet_Pt.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_Ro.rc b/dlls/wininet/wininet_Ro.rc index 2bc607a1921..367bbb5955a 100644 --- a/dlls/wininet/wininet_Ro.rc +++ b/dlls/wininet/wininet_Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -47,3 +45,5 @@ STRINGTABLE DISCARDABLE { IDS_LANCONNECTION "Conexiune LAN" } + +#pragma code_page(default) diff --git a/dlls/wininet/wininet_Ru.rc b/dlls/wininet/wininet_Ru.rc index dd8bc85fc59..d75985ba1b7 100644 --- a/dlls/wininet/wininet_Ru.rc +++ b/dlls/wininet/wininet_Ru.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_Si.rc b/dlls/wininet/wininet_Si.rc index b5bf2914328..93ac9e1f33b 100644 --- a/dlls/wininet/wininet_Si.rc +++ b/dlls/wininet/wininet_Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -46,3 +44,5 @@ STRINGTABLE DISCARDABLE { IDS_LANCONNECTION "LAN povezava" } + +#pragma code_page(default) diff --git a/dlls/wininet/wininet_Sv.rc b/dlls/wininet/wininet_Sv.rc index 8d3291ec750..6d71f2ef842 100644 --- a/dlls/wininet/wininet_Sv.rc +++ b/dlls/wininet/wininet_Sv.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_Tr.rc b/dlls/wininet/wininet_Tr.rc index 8d26cf21694..dd796777236 100644 --- a/dlls/wininet/wininet_Tr.rc +++ b/dlls/wininet/wininet_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_Uk.rc b/dlls/wininet/wininet_Uk.rc index 94a9611888b..be58bb621f2 100644 --- a/dlls/wininet/wininet_Uk.rc +++ b/dlls/wininet/wininet_Uk.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_UKRAINIAN, SUBLANG_DEFAULT IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154 diff --git a/dlls/wininet/wininet_Zh.rc b/dlls/wininet/wininet_Zh.rc index e2e36ded277..4406bd87c1a 100644 --- a/dlls/wininet/wininet_Zh.rc +++ b/dlls/wininet/wininet_Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -76,3 +74,5 @@ STRINGTABLE DISCARDABLE { IDS_LANCONNECTION "局域網連接" } + +#pragma code_page(default) diff --git a/dlls/winmm/Makefile.in b/dlls/winmm/Makefile.in index 64c7b5b4803..a8ebc62e32b 100644 --- a/dlls/winmm/Makefile.in +++ b/dlls/winmm/Makefile.in @@ -24,26 +24,7 @@ C_SRCS16 = \ SPEC_SRCS16 = \ mmsystem.spec -RC_SRCS = \ - winmm_Cs.rc \ - winmm_Da.rc \ - winmm_De.rc \ - winmm_En.rc \ - winmm_Es.rc \ - winmm_Fr.rc \ - winmm_It.rc \ - winmm_Ja.rc \ - winmm_Ko.rc \ - winmm_Lt.rc \ - winmm_Nl.rc \ - winmm_No.rc \ - winmm_Pl.rc \ - winmm_Pt.rc \ - winmm_Ru.rc \ - winmm_Si.rc \ - winmm_Sk.rc \ - winmm_Tr.rc \ - winmm_res.rc +RC_SRCS = winmm_res.rc @MAKE_DLL_RULES@ diff --git a/dlls/winmm/mci.c b/dlls/winmm/mci.c index 6fca0138128..262d62ddca5 100644 --- a/dlls/winmm/mci.c +++ b/dlls/winmm/mci.c @@ -1506,7 +1506,7 @@ DWORD WINAPI mciSendStringA(LPCSTR lpstrCommand, LPSTR lpstrRet, } } ret = mciSendStringW(lpwstrCommand, lpwstrRet, uRetLen, hwndCallback); - if (!ret && lpwstrRet) + if (lpwstrRet) WideCharToMultiByte( CP_ACP, 0, lpwstrRet, -1, lpstrRet, uRetLen, NULL, NULL ); HeapFree(GetProcessHeap(), 0, lpwstrCommand); HeapFree(GetProcessHeap(), 0, lpwstrRet); diff --git a/dlls/winmm/tests/mci.c b/dlls/winmm/tests/mci.c index 5f8698507a8..8764b307f17 100644 --- a/dlls/winmm/tests/mci.c +++ b/dlls/winmm/tests/mci.c @@ -53,7 +53,7 @@ START_TEST(mci) memset(buf, 0, sizeof(buf)); err = mciSendString(command_close_all, buf, sizeof(buf), hwnd); todo_wine ok(!err,"mciSendString(%s, buf, sizeof(buf) , NULL) returned error: %d\n", command_close_all, err); - ok(buf[0] == 0, "mciSendString(%s, buf, sizeof(buf) , NULL) changed output buffer: %s\n", command_close_all, buf); + todo_wine ok(buf[0] == 0, "mciSendString(%s, buf, sizeof(buf) , NULL) changed output buffer: %s\n", command_close_all, buf); memset(buf, 0, sizeof(buf)); err = mciSendString(command_sysinfo, buf, sizeof(buf), NULL); diff --git a/dlls/winmm/winmm_Cs.rc b/dlls/winmm/winmm_Cs.rc index 36604d455fe..aa4cd639fd0 100644 --- a/dlls/winmm/winmm_Cs.rc +++ b/dlls/winmm/winmm_Cs.rc @@ -19,9 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - /* Czech strings in CP1250 */ STRINGTABLE LANGUAGE LANG_CZECH, SUBLANG_NEUTRAL diff --git a/dlls/winmm/winmm_Da.rc b/dlls/winmm/winmm_Da.rc index 7f55353ea7f..feeb9de7abf 100644 --- a/dlls/winmm/winmm_Da.rc +++ b/dlls/winmm/winmm_Da.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - STRINGTABLE LANGUAGE LANG_DANISH, SUBLANG_DEFAULT BEGIN diff --git a/dlls/winmm/winmm_De.rc b/dlls/winmm/winmm_De.rc dissimilarity index 68% index c259204059c..4b16e17ecf6 100644 --- a/dlls/winmm/winmm_De.rc +++ b/dlls/winmm/winmm_De.rc @@ -1,131 +1,126 @@ -/* - * Copyright 2004 Henning Gerhardt - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "windef.h" -#include "mmddk.h" - -#pragma code_page(65001) - -STRINGTABLE LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL -BEGIN - -/* MMSYS errors */ -MMSYSERR_NOERROR, "Der angeforderte Befehl wurde ausgeführt." -MMSYSERR_ERROR, "Unbekannter externer Fehler." -MMSYSERR_BADDEVICEID, "Die derzeit verwendete Gerätekennung ist außerhalb des zulässigen Bereichs für Ihr System." -MMSYSERR_NOTENABLED, "Der Treiber konnte nicht gestartet werden." -MMSYSERR_ALLOCATED, "Das Gerät wird bereits verwendet. Warten Sie, bis es freigegeben ist, und versuchen Sie es erneut." -MMSYSERR_INVALHANDLE, "Das angegebende Gerätehandle ist ungültig." -MMSYSERR_NODRIVER, "Es ist kein Treiber auf Ihrem System installiert !\n" -MMSYSERR_NOMEM, "Nicht genügend Speicher für diesen Befehl. Beenden Sie eine oder mehrere Anwendungen, und versuchen Sie es erneut." -MMSYSERR_NOTSUPPORTED, "Diese Funktion wird nicht unterstützt. Benutzen Sie die Funktion 'Capabilities', um zu ermitteln, welche Funktion dieser Treiber unterstützt." -MMSYSERR_BADERRNUM, "Die angegebene Fehlernummer ist für dieses System nicht definiert." -MMSYSERR_INVALFLAG, "Ein ungültiges Flag wurde an eine Systemfunktion übergeben." -MMSYSERR_INVALPARAM, "Ein ungültiger Parameter wurde an eine Systemfunktion übergeben." - -/* WAVE errors */ -WAVERR_BADFORMAT, "Dieses Format wird nicht unterstützt oder kann nicht übersetzt werden. Benutzen Sie die Funktion 'Capabilities', um die unterstützten Formate zu ermitteln." -WAVERR_STILLPLAYING, "Die Funktion kann nicht durchgeführt werden, wenn noch Mediendateien wiedergegeben werden. Starten Sie das Gerät neu, oder warten Sie bis keine Daten mehr wiedergegeben werden." -WAVERR_UNPREPARED, "Der WAVE - Header wurde nicht vorbereitet. Benutzen Sie die Funktion 'Prepare' zum Vorbereiten des Headers und versuchen Sie es erneut." -WAVERR_SYNC, "Das Gerät kann nicht ohne das WAVE_ALLOWSYNC - Flag geöffnet werden. Benutzen Sie dieses Flag und versuchen Sie es erneut." - -/* MIDI errors */ -MIDIERR_UNPREPARED, "Der MIDI - Header wurde nicht vorbereitet. Benutzen Sie die Funktion 'Prepare' zum Vorbereiten des Headers und versuchen Sie es erneut." -MIDIERR_STILLPLAYING, "Die Funktion kann nicht durchgeführt werden, wenn noch Mediendateien wiedergegeben werden. Starten Sie das Gerät neu, oder warten Sie bis keine Daten mehr wiedergegeben werden." -MIDIERR_NOMAP, "Es wurde keine MIDI - Map gefunden. Es könnte ein Problem mit dem Treiber geben oder die Datei MIDIMAP.CFG fehlt oder ist beschädigt." -MIDIERR_NOTREADY, "Der Anschluss ist mit der Datenausgabe belegt. Warten Sie, bis die Daten übertragen wurden und versuchen Sie es erneut." -MIDIERR_NODEVICE, "Das gegenwärtige MIDI - Mapper Setup benutzt ein MIDI - Gerät, das nicht installiert ist. Benutzen Sie den MIDI - Mapper, um das Setup zu ändern." -MIDIERR_INVALIDSETUP, "Das aktuelle MIDI Setup ist beschädigt. Kopieren sie die ursprüngliche Datei MIDIMAP.CFG ind das Windows - Systemverzeichnis und versuchen Sie es erneut." - -/* MCI errors */ -MCIERR_INVALID_DEVICE_ID, "Ungültige MCI - Gerätekennung. Benutzen Sie die zurückgegebene ID, wenn Sie das MCI - Gerät öffnen." -MCIERR_UNRECOGNIZED_KEYWORD, "Der Treiber kann den angegebenen Befehlsparameter nicht anerkennen." -MCIERR_UNRECOGNIZED_COMMAND, "Der Treiber kann den angegebenen Befehl nicht anerkennen." -MCIERR_HARDWARE, "Es gibt ein Problem mit Ihrem Media - Gerät. Stellen Sie sicher, dass es richtig arbeitet oder fragen Sie den Gerätehersteller." -MCIERR_INVALID_DEVICE_NAME, "Das angegebene Gerät ist nicht geöffnet oder wird vom MCI nicht erkannt." -MCIERR_OUT_OF_MEMORY, "Nicht genügend Speicher für den angeforderten Vorgang.\nBeenden Sie eine oder mehrere Anwendungen, und versuchen Sie es erneut." -MCIERR_DEVICE_OPEN, "Der Gerätename wird von dieser Anwendung bereits als Alias benutzt. Benutzen Sie einen eindeutigen Alias" -MCIERR_CANNOT_LOAD_DRIVER, "Es gibt ein unbekanntes Problem beim Laden des angegebenen Gerätetreibers." -MCIERR_MISSING_COMMAND_STRING, "Kein Befehl wurde angegeben." -MCIERR_PARAM_OVERFLOW, "Die Ausgabezeichenkette war zu lang für den Rückgabepuffer. Erhöhen Sie die Puffergröße." -MCIERR_MISSING_STRING_ARGUMENT, "Der Befehl erfordert einen Zeichenkettenparameter. Bitte stellen Sie einen bereit." -MCIERR_BAD_INTEGER, "Die Angabe einer ganzen Zahl ist für diesen Befehl ungültig." -MCIERR_PARSER_INTERNAL, "Der Gerätetreiber hat einen ungültigen Rückgabewert geliefert. Fragen Sie den Gerätehersteller nach einem neuen Treiber." -MCIERR_DRIVER_INTERNAL, "Ein Treiberfehler ist aufgetreten. Fragen Sie den Gerätehersteller nach einem neuen Treiber." -MCIERR_MISSING_PARAMETER, "Der angegebene Befehl erfordert einen Parameter. Bitte geben Sie einen an." -MCIERR_UNSUPPORTED_FUNCTION, "Das verwendete MCI - Gerät unterstützt diesen Befehl nicht." -MCIERR_FILE_NOT_FOUND, "Die angeforderte Datei wurde nicht gefunden. Stellen Sie sicher, dass Pfad- und Dateiname richtig sind." -MCIERR_DEVICE_NOT_READY, "Der Gerätetreiber ist nicht bereit." -MCIERR_INTERNAL, "Ein Fehler ereignete sich beim Starten von MCI. Versuche Windows neu zu starten." -MCIERR_DRIVER, "Es gibt ein Problem mit dem Gerätetreiber. Der Treiber wird geschlossen. Ein Fehler kann nicht gemeldet werden." -MCIERR_CANNOT_USE_ALL, "Der Gerätename 'all' ist nicht in diesem Befehl erlaubt." -MCIERR_MULTIPLE, "Es traten Fehler in mehr als einem Gerät auf. Geben Sie jeden Befehl für jedes Gerät einzeln an, um zu bestimmen, welches Gerät die Fehler verursachte." -MCIERR_EXTENSION_NOT_FOUND, "Kann keinen Gerätetyp aus der angegebenen Dateinamenerweiterung ermitteln." -MCIERR_OUTOFRANGE, "Der angegebene Parameter liegt außerhalb des zulässigen Bereichs für diesen Befehl." -MCIERR_FLAGS_NOT_COMPATIBLE, "Die Parameter können nicht zusammen verwendet werden." -MCIERR_FILE_NOT_SAVED, "Die Datei kann nicht gespeichert werden. Stellen Sie sicher, dass genügend Platz auf dem Datenträger verfügbar ist oder Ihre Netzwerkverbindung noch besteht." -MCIERR_DEVICE_TYPE_REQUIRED, "Das angegebene Gerät wurde nicht gefunden. Stellen Sie sicher, dass es installiert ist oder der Gerätename richtig geschrieben ist." -MCIERR_DEVICE_LOCKED, "Das angegebene Gerät wird geschlossen. Warten Sie einige Sekunden, und versuchen Sie es erneut." -MCIERR_DUPLICATE_ALIAS, "Der angegebene Alias wird von dieser Anwendung bereits verwendet. Wählen Sie einen eindeutigen Alias." -MCIERR_BAD_CONSTANT, "Der angegebene Parameter für diesen Befehl ungültig." -MCIERR_MUST_USE_SHAREABLE, "Das Gerät ist bereits geöffnet. Benutzen Sie den 'shareable' - Parameter bei jedem 'open' - Befehl." -MCIERR_MISSING_DEVICE_NAME, "Der angegebene Befehl erfordert einen Alias-, Datei-, Treiber- oder Gerätenamen. Bitte geben Sie einen an." -MCIERR_BAD_TIME_FORMAT, "Der angegebene Wert für das Zeitformat ist ungültig. Lesen Sie in der MCI - Dokumentation nach gültigen Formaten nach." -MCIERR_NO_CLOSING_QUOTE, "Ein abschließendes Anführungszeichen fehlt im Parameter. Bitte geben Sie eins an." -MCIERR_DUPLICATE_FLAGS, "Ein Parameter oder Wert wurde zweimal angegeben. Geben Sie in nur einzeln an." -MCIERR_INVALID_FILE, "Die angegebene Datei kann auf dem MCI - Gerät nicht wiedergegeben werden. Die Datei ist wahrscheinlich beschädigt oder in einem ungültigen Format." -MCIERR_NULL_PARAMETER_BLOCK, "Der Parameterblock, der zu MCI übergeben wurde, war NULL." -MCIERR_UNNAMED_RESOURCE, "Es kann keine unbenannte Datei gespeichert werden. Geben Sie einen Dateinamen an." -MCIERR_NEW_REQUIRES_ALIAS, "Sie müssen einen Alias mit dem 'new' - Parameter angeben." -MCIERR_NOTIFY_ON_AUTO_OPEN, "Das 'notify' Flag ist unzulässig für selbstöffnende Geräte." -MCIERR_NO_ELEMENT_ALLOWED, "Ein Dateiname kann mit diesem Gerät nicht verwendet werden." -MCIERR_NONAPPLICABLE_FUNCTION, "Die Befehle sind in der angegebenen Reihenfolge nicht ausführbar. Ändern Sie die Reihenfolge, und versuchen Sie es erneut." -MCIERR_ILLEGAL_FOR_AUTO_OPEN, "Der Befehl kann nicht auf ein selbstöffnedes Gerät angewandt werden. Warten Sie, bis das Gerät geschlossen wurde und versuchen Sie es erneut." -MCIERR_FILENAME_REQUIRED, "Der Dateiname ist ungültig. Der Dateiname muss aus maximal 8 Zeichen, gefolgt von einem Punkt und einer Dateinamenerweiterung bestehen." -MCIERR_EXTRA_CHARACTERS, "Zusätzliche Zeichen nach einer Zeichenkette mit Anführungszeichen sind nicht erlaubt." -MCIERR_DEVICE_NOT_INSTALLED, "Das angegebene Gerät ist nicht auf Ihren System installiert. Benutzen Sie die Hardwareerkennung in der Systemsteuerung, um das Gerät zu installieren." -MCIERR_GET_CD, "Auf die angegebene Datei oder das MCI - Gerät kann nicht zugegriffen werden. Versuchen Sie, das Verzeichnis zu wechseln oder das System neu zu starten." -MCIERR_SET_CD, "Auf die angegebene Datei oder das MCI - Gerät kann nicht zugegriffen werden, weil die Anwendung nicht das Verzeichnis wechseln kann." -MCIERR_SET_DRIVE, "Auf die angegebene Datei oder das MCI - Gerät kann nicht zugegriffen werden, weil die Anwendung nicht das Laufwerk wechseln kann." -MCIERR_DEVICE_LENGTH, "Geben Sie einen Geräte- oder Treibernamen mit weniger als 79 Zeichen an." -MCIERR_DEVICE_ORD_LENGTH, "Geben Sie einen Geräte- oder Treibernamen mit weniger als 69 Zeichen an." -MCIERR_NO_INTEGER, "Der angegebene Befehl erfordert einen ganzzahligen Parameter. Bitte geben Sie einen an." -MCIERR_WAVE_OUTPUTSINUSE, "Alle Waveformgeräte, die diese Dateien in dem gegenwärtigen Format wiedergeben könnten, sind in Benutzung. Warten Sie, bis ein Waveformgerät frei ist, und wiederholen Sie den Vorgang." -MCIERR_WAVE_SETOUTPUTINUSE, "Das gegenwärtige Waveformgerät kann nicht wiedergeben, weil es gerade benutzt wird. Warten Sie, bis das Gerät frei ist, und wiederholen Sie den Vorgang." -MCIERR_WAVE_INPUTSINUSE, "Es ist kein Waveformgerät frei, das das gegenwärtige Format aufzeichnen könnte. Warten Sie, bis ein Waveformgerät frei ist, und wiederholen Sie den Vorgang." -MCIERR_WAVE_SETINPUTINUSE, "Das gegenwärtige Waveformgerät kann nicht aufzeichnen, weil es gerade verwendet wird. Warten Sie, bis das Gerät frei ist, und wiederholen Sie den Vorgang." -MCIERR_WAVE_OUTPUTUNSPECIFIED, "Jedes kompatible Waveform - Wiedergabegerät kann verwendet werden." -MCIERR_WAVE_INPUTUNSPECIFIED, "Jedes kompatible Waveform - Aufnahmegerät kann verwendet werden." -MCIERR_WAVE_OUTPUTSUNSUITABLE, "Es ist kein Waveformgerät installiert, das Dateien im aktuellen Format wiedergeben kann. Benutzen Sie die Hardwareerkennung in der Systemsteuerung, um ein Waveformgerät zu installieren." -MCIERR_WAVE_SETOUTPUTUNSUITABLE,"Das Wiedergabegerät erkennt das gegenwärtige Dateiformat nicht." -MCIERR_WAVE_INPUTSUNSUITABLE, "Es ist kein Waveformgerät installiert, das Dateien im aktuellen Format aufnehmen kann. Benutzen Sie die Hardwareerkennung in der Systemsteuerung, um ein Waveformgerät zu installieren." -MCIERR_WAVE_SETINPUTUNSUITABLE, "Das Gerät, mit dem Sie aufzeichnen möchten, erkennt das gegenwärtige Dateiformat nicht." -MCIERR_NO_WINDOW, "Es gibt kein Anzeigefenster." -MCIERR_CREATEWINDOW, "Fenster konnte nicht erzeugt oder verwendet werden." -MCIERR_FILE_READ, "Die Datei konnte nicht gelesen werden. Stellen Sie sicher, dass die Datei existiert oder Ihre Netzwerkverbindung noch besteht." -MCIERR_FILE_WRITE, "Die Datei konnte nicht geschrieben werden. Stellen Sie sicher, dass genügend Platz auf dem Datenträger verfügbar ist, oder dass die Netzwerkverbindung noch besteht." -MCIERR_SEQ_DIV_INCOMPATIBLE, "Die Zeitformate von ""song pointer"" und SMPTE schliessen sich gegenseitig aus. Sie können sie nicht zusammen verwenden." -MCIERR_SEQ_NOMIDIPRESENT, "Es sind keine MIDI - Geräte auf dem System installiert. Benutzen Sie die Hardwareerkennung in der Systemsteuerung, um einen MIDI - Treiber zu installieren." -MCIERR_SEQ_PORT_INUSE, "Der angegebene MIDI - Anschluss wird bereits verwendet. Warten Sie bis der Anschluss frei ist, und versuchen Sie es erneut." -MCIERR_SEQ_PORT_MAPNODEVICE, "Das gegenwärtige MIDI - Mapper Setup benutzt ein MIDI - Gerät, dass nicht auf Ihren System installiert ist. Benutzen Sie den MIDI - Mapper in der Systemsteuerung, um das Setup zu ändern." -MCIERR_SEQ_PORT_MISCERROR, "Beim Benutzen des angegebenen Anschlusses trat ein Fehler auf." -MCIERR_SEQ_PORT_NONEXISTENT, "Es sind keine angegebnen MIDI - Geräte auf dem System installiert. Benutzen Sie die Hardwareerkennung in der Systemsteuerung, um ein MIDI - Gerät zu installieren." -MCIERR_SEQ_PORTUNSPECIFIED, "Es gibt keinen aktuellen MIDI - Anschluss auf dem System." -MCIERR_SEQ_TIMER, "Alle Multimediazeitgeber werden von anderen Anwendungen verwendet. Beenden Sie eine dieser Anwendungen, und versuchen Sie es erneut." - -END +/* + * Copyright 2004 Henning Gerhardt + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +STRINGTABLE LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL +BEGIN + +/* MMSYS errors */ +MMSYSERR_NOERROR, "Der angeforderte Befehl wurde ausgeführt." +MMSYSERR_ERROR, "Unbekannter externer Fehler." +MMSYSERR_BADDEVICEID, "Die derzeit verwendete Gerätekennung ist außerhalb des zulässigen Bereichs für Ihr System." +MMSYSERR_NOTENABLED, "Der Treiber konnte nicht gestartet werden." +MMSYSERR_ALLOCATED, "Das Gerät wird bereits verwendet. Warten Sie, bis es freigegeben ist, und versuchen Sie es erneut." +MMSYSERR_INVALHANDLE, "Das angegebende Gerätehandle ist ungültig." +MMSYSERR_NODRIVER, "Es ist kein Treiber auf Ihrem System installiert !\n" +MMSYSERR_NOMEM, "Nicht genügend Speicher für diesen Befehl. Beenden Sie eine oder mehrere Anwendungen, und versuchen Sie es erneut." +MMSYSERR_NOTSUPPORTED, "Diese Funktion wird nicht unterstützt. Benutzen Sie die Funktion 'Capabilities', um zu ermitteln, welche Funktion dieser Treiber unterstützt." +MMSYSERR_BADERRNUM, "Die angegebene Fehlernummer ist für dieses System nicht definiert." +MMSYSERR_INVALFLAG, "Ein ungültiges Flag wurde an eine Systemfunktion übergeben." +MMSYSERR_INVALPARAM, "Ein ungültiger Parameter wurde an eine Systemfunktion übergeben." + +/* WAVE errors */ +WAVERR_BADFORMAT, "Dieses Format wird nicht unterstützt oder kann nicht übersetzt werden. Benutzen Sie die Funktion 'Capabilities', um die unterstützten Formate zu ermitteln." +WAVERR_STILLPLAYING, "Die Funktion kann nicht durchgeführt werden, wenn noch Mediendateien wiedergegeben werden. Starten Sie das Gerät neu, oder warten Sie bis keine Daten mehr wiedergegeben werden." +WAVERR_UNPREPARED, "Der WAVE - Header wurde nicht vorbereitet. Benutzen Sie die Funktion 'Prepare' zum Vorbereiten des Headers und versuchen Sie es erneut." +WAVERR_SYNC, "Das Gerät kann nicht ohne das WAVE_ALLOWSYNC - Flag geöffnet werden. Benutzen Sie dieses Flag und versuchen Sie es erneut." + +/* MIDI errors */ +MIDIERR_UNPREPARED, "Der MIDI - Header wurde nicht vorbereitet. Benutzen Sie die Funktion 'Prepare' zum Vorbereiten des Headers und versuchen Sie es erneut." +MIDIERR_STILLPLAYING, "Die Funktion kann nicht durchgeführt werden, wenn noch Mediendateien wiedergegeben werden. Starten Sie das Gerät neu, oder warten Sie bis keine Daten mehr wiedergegeben werden." +MIDIERR_NOMAP, "Es wurde keine MIDI - Map gefunden. Es könnte ein Problem mit dem Treiber geben oder die Datei MIDIMAP.CFG fehlt oder ist beschädigt." +MIDIERR_NOTREADY, "Der Anschluss ist mit der Datenausgabe belegt. Warten Sie, bis die Daten übertragen wurden und versuchen Sie es erneut." +MIDIERR_NODEVICE, "Das gegenwärtige MIDI - Mapper Setup benutzt ein MIDI - Gerät, das nicht installiert ist. Benutzen Sie den MIDI - Mapper, um das Setup zu ändern." +MIDIERR_INVALIDSETUP, "Das aktuelle MIDI Setup ist beschädigt. Kopieren sie die ursprüngliche Datei MIDIMAP.CFG ind das Windows - Systemverzeichnis und versuchen Sie es erneut." + +/* MCI errors */ +MCIERR_INVALID_DEVICE_ID, "Ungültige MCI - Gerätekennung. Benutzen Sie die zurückgegebene ID, wenn Sie das MCI - Gerät öffnen." +MCIERR_UNRECOGNIZED_KEYWORD, "Der Treiber kann den angegebenen Befehlsparameter nicht anerkennen." +MCIERR_UNRECOGNIZED_COMMAND, "Der Treiber kann den angegebenen Befehl nicht anerkennen." +MCIERR_HARDWARE, "Es gibt ein Problem mit Ihrem Media - Gerät. Stellen Sie sicher, dass es richtig arbeitet oder fragen Sie den Gerätehersteller." +MCIERR_INVALID_DEVICE_NAME, "Das angegebene Gerät ist nicht geöffnet oder wird vom MCI nicht erkannt." +MCIERR_OUT_OF_MEMORY, "Nicht genügend Speicher für den angeforderten Vorgang.\nBeenden Sie eine oder mehrere Anwendungen, und versuchen Sie es erneut." +MCIERR_DEVICE_OPEN, "Der Gerätename wird von dieser Anwendung bereits als Alias benutzt. Benutzen Sie einen eindeutigen Alias" +MCIERR_CANNOT_LOAD_DRIVER, "Es gibt ein unbekanntes Problem beim Laden des angegebenen Gerätetreibers." +MCIERR_MISSING_COMMAND_STRING, "Kein Befehl wurde angegeben." +MCIERR_PARAM_OVERFLOW, "Die Ausgabezeichenkette war zu lang für den Rückgabepuffer. Erhöhen Sie die Puffergröße." +MCIERR_MISSING_STRING_ARGUMENT, "Der Befehl erfordert einen Zeichenkettenparameter. Bitte stellen Sie einen bereit." +MCIERR_BAD_INTEGER, "Die Angabe einer ganzen Zahl ist für diesen Befehl ungültig." +MCIERR_PARSER_INTERNAL, "Der Gerätetreiber hat einen ungültigen Rückgabewert geliefert. Fragen Sie den Gerätehersteller nach einem neuen Treiber." +MCIERR_DRIVER_INTERNAL, "Ein Treiberfehler ist aufgetreten. Fragen Sie den Gerätehersteller nach einem neuen Treiber." +MCIERR_MISSING_PARAMETER, "Der angegebene Befehl erfordert einen Parameter. Bitte geben Sie einen an." +MCIERR_UNSUPPORTED_FUNCTION, "Das verwendete MCI - Gerät unterstützt diesen Befehl nicht." +MCIERR_FILE_NOT_FOUND, "Die angeforderte Datei wurde nicht gefunden. Stellen Sie sicher, dass Pfad- und Dateiname richtig sind." +MCIERR_DEVICE_NOT_READY, "Der Gerätetreiber ist nicht bereit." +MCIERR_INTERNAL, "Ein Fehler ereignete sich beim Starten von MCI. Versuche Windows neu zu starten." +MCIERR_DRIVER, "Es gibt ein Problem mit dem Gerätetreiber. Der Treiber wird geschlossen. Ein Fehler kann nicht gemeldet werden." +MCIERR_CANNOT_USE_ALL, "Der Gerätename 'all' ist nicht in diesem Befehl erlaubt." +MCIERR_MULTIPLE, "Es traten Fehler in mehr als einem Gerät auf. Geben Sie jeden Befehl für jedes Gerät einzeln an, um zu bestimmen, welches Gerät die Fehler verursachte." +MCIERR_EXTENSION_NOT_FOUND, "Kann keinen Gerätetyp aus der angegebenen Dateinamenerweiterung ermitteln." +MCIERR_OUTOFRANGE, "Der angegebene Parameter liegt außerhalb des zulässigen Bereichs für diesen Befehl." +MCIERR_FLAGS_NOT_COMPATIBLE, "Die Parameter können nicht zusammen verwendet werden." +MCIERR_FILE_NOT_SAVED, "Die Datei kann nicht gespeichert werden. Stellen Sie sicher, dass genügend Platz auf dem Datenträger verfügbar ist oder Ihre Netzwerkverbindung noch besteht." +MCIERR_DEVICE_TYPE_REQUIRED, "Das angegebene Gerät wurde nicht gefunden. Stellen Sie sicher, dass es installiert ist oder der Gerätename richtig geschrieben ist." +MCIERR_DEVICE_LOCKED, "Das angegebene Gerät wird geschlossen. Warten Sie einige Sekunden, und versuchen Sie es erneut." +MCIERR_DUPLICATE_ALIAS, "Der angegebene Alias wird von dieser Anwendung bereits verwendet. Wählen Sie einen eindeutigen Alias." +MCIERR_BAD_CONSTANT, "Der angegebene Parameter für diesen Befehl ungültig." +MCIERR_MUST_USE_SHAREABLE, "Das Gerät ist bereits geöffnet. Benutzen Sie den 'shareable' - Parameter bei jedem 'open' - Befehl." +MCIERR_MISSING_DEVICE_NAME, "Der angegebene Befehl erfordert einen Alias-, Datei-, Treiber- oder Gerätenamen. Bitte geben Sie einen an." +MCIERR_BAD_TIME_FORMAT, "Der angegebene Wert für das Zeitformat ist ungültig. Lesen Sie in der MCI - Dokumentation nach gültigen Formaten nach." +MCIERR_NO_CLOSING_QUOTE, "Ein abschließendes Anführungszeichen fehlt im Parameter. Bitte geben Sie eins an." +MCIERR_DUPLICATE_FLAGS, "Ein Parameter oder Wert wurde zweimal angegeben. Geben Sie in nur einzeln an." +MCIERR_INVALID_FILE, "Die angegebene Datei kann auf dem MCI - Gerät nicht wiedergegeben werden. Die Datei ist wahrscheinlich beschädigt oder in einem ungültigen Format." +MCIERR_NULL_PARAMETER_BLOCK, "Der Parameterblock, der zu MCI übergeben wurde, war NULL." +MCIERR_UNNAMED_RESOURCE, "Es kann keine unbenannte Datei gespeichert werden. Geben Sie einen Dateinamen an." +MCIERR_NEW_REQUIRES_ALIAS, "Sie müssen einen Alias mit dem 'new' - Parameter angeben." +MCIERR_NOTIFY_ON_AUTO_OPEN, "Das 'notify' Flag ist unzulässig für selbstöffnende Geräte." +MCIERR_NO_ELEMENT_ALLOWED, "Ein Dateiname kann mit diesem Gerät nicht verwendet werden." +MCIERR_NONAPPLICABLE_FUNCTION, "Die Befehle sind in der angegebenen Reihenfolge nicht ausführbar. Ändern Sie die Reihenfolge, und versuchen Sie es erneut." +MCIERR_ILLEGAL_FOR_AUTO_OPEN, "Der Befehl kann nicht auf ein selbstöffnedes Gerät angewandt werden. Warten Sie, bis das Gerät geschlossen wurde und versuchen Sie es erneut." +MCIERR_FILENAME_REQUIRED, "Der Dateiname ist ungültig. Der Dateiname muss aus maximal 8 Zeichen, gefolgt von einem Punkt und einer Dateinamenerweiterung bestehen." +MCIERR_EXTRA_CHARACTERS, "Zusätzliche Zeichen nach einer Zeichenkette mit Anführungszeichen sind nicht erlaubt." +MCIERR_DEVICE_NOT_INSTALLED, "Das angegebene Gerät ist nicht auf Ihren System installiert. Benutzen Sie die Hardwareerkennung in der Systemsteuerung, um das Gerät zu installieren." +MCIERR_GET_CD, "Auf die angegebene Datei oder das MCI - Gerät kann nicht zugegriffen werden. Versuchen Sie, das Verzeichnis zu wechseln oder das System neu zu starten." +MCIERR_SET_CD, "Auf die angegebene Datei oder das MCI - Gerät kann nicht zugegriffen werden, weil die Anwendung nicht das Verzeichnis wechseln kann." +MCIERR_SET_DRIVE, "Auf die angegebene Datei oder das MCI - Gerät kann nicht zugegriffen werden, weil die Anwendung nicht das Laufwerk wechseln kann." +MCIERR_DEVICE_LENGTH, "Geben Sie einen Geräte- oder Treibernamen mit weniger als 79 Zeichen an." +MCIERR_DEVICE_ORD_LENGTH, "Geben Sie einen Geräte- oder Treibernamen mit weniger als 69 Zeichen an." +MCIERR_NO_INTEGER, "Der angegebene Befehl erfordert einen ganzzahligen Parameter. Bitte geben Sie einen an." +MCIERR_WAVE_OUTPUTSINUSE, "Alle Waveformgeräte, die diese Dateien in dem gegenwärtigen Format wiedergeben könnten, sind in Benutzung. Warten Sie, bis ein Waveformgerät frei ist, und wiederholen Sie den Vorgang." +MCIERR_WAVE_SETOUTPUTINUSE, "Das gegenwärtige Waveformgerät kann nicht wiedergeben, weil es gerade benutzt wird. Warten Sie, bis das Gerät frei ist, und wiederholen Sie den Vorgang." +MCIERR_WAVE_INPUTSINUSE, "Es ist kein Waveformgerät frei, das das gegenwärtige Format aufzeichnen könnte. Warten Sie, bis ein Waveformgerät frei ist, und wiederholen Sie den Vorgang." +MCIERR_WAVE_SETINPUTINUSE, "Das gegenwärtige Waveformgerät kann nicht aufzeichnen, weil es gerade verwendet wird. Warten Sie, bis das Gerät frei ist, und wiederholen Sie den Vorgang." +MCIERR_WAVE_OUTPUTUNSPECIFIED, "Jedes kompatible Waveform - Wiedergabegerät kann verwendet werden." +MCIERR_WAVE_INPUTUNSPECIFIED, "Jedes kompatible Waveform - Aufnahmegerät kann verwendet werden." +MCIERR_WAVE_OUTPUTSUNSUITABLE, "Es ist kein Waveformgerät installiert, das Dateien im aktuellen Format wiedergeben kann. Benutzen Sie die Hardwareerkennung in der Systemsteuerung, um ein Waveformgerät zu installieren." +MCIERR_WAVE_SETOUTPUTUNSUITABLE,"Das Wiedergabegerät erkennt das gegenwärtige Dateiformat nicht." +MCIERR_WAVE_INPUTSUNSUITABLE, "Es ist kein Waveformgerät installiert, das Dateien im aktuellen Format aufnehmen kann. Benutzen Sie die Hardwareerkennung in der Systemsteuerung, um ein Waveformgerät zu installieren." +MCIERR_WAVE_SETINPUTUNSUITABLE, "Das Gerät, mit dem Sie aufzeichnen möchten, erkennt das gegenwärtige Dateiformat nicht." +MCIERR_NO_WINDOW, "Es gibt kein Anzeigefenster." +MCIERR_CREATEWINDOW, "Fenster konnte nicht erzeugt oder verwendet werden." +MCIERR_FILE_READ, "Die Datei konnte nicht gelesen werden. Stellen Sie sicher, dass die Datei existiert oder Ihre Netzwerkverbindung noch besteht." +MCIERR_FILE_WRITE, "Die Datei konnte nicht geschrieben werden. Stellen Sie sicher, dass genügend Platz auf dem Datenträger verfügbar ist, oder dass die Netzwerkverbindung noch besteht." +MCIERR_SEQ_DIV_INCOMPATIBLE, "Die Zeitformate von ""song pointer"" und SMPTE schliessen sich gegenseitig aus. Sie können sie nicht zusammen verwenden." +MCIERR_SEQ_NOMIDIPRESENT, "Es sind keine MIDI - Geräte auf dem System installiert. Benutzen Sie die Hardwareerkennung in der Systemsteuerung, um einen MIDI - Treiber zu installieren." +MCIERR_SEQ_PORT_INUSE, "Der angegebene MIDI - Anschluss wird bereits verwendet. Warten Sie bis der Anschluss frei ist, und versuchen Sie es erneut." +MCIERR_SEQ_PORT_MAPNODEVICE, "Das gegenwärtige MIDI - Mapper Setup benutzt ein MIDI - Gerät, dass nicht auf Ihren System installiert ist. Benutzen Sie den MIDI - Mapper in der Systemsteuerung, um das Setup zu ändern." +MCIERR_SEQ_PORT_MISCERROR, "Beim Benutzen des angegebenen Anschlusses trat ein Fehler auf." +MCIERR_SEQ_PORT_NONEXISTENT, "Es sind keine angegebnen MIDI - Geräte auf dem System installiert. Benutzen Sie die Hardwareerkennung in der Systemsteuerung, um ein MIDI - Gerät zu installieren." +MCIERR_SEQ_PORTUNSPECIFIED, "Es gibt keinen aktuellen MIDI - Anschluss auf dem System." +MCIERR_SEQ_TIMER, "Alle Multimediazeitgeber werden von anderen Anwendungen verwendet. Beenden Sie eine dieser Anwendungen, und versuchen Sie es erneut." + +END diff --git a/dlls/winmm/winmm_En.rc b/dlls/winmm/winmm_En.rc index 1a945d880d0..dd3e56cc45a 100644 --- a/dlls/winmm/winmm_En.rc +++ b/dlls/winmm/winmm_En.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - STRINGTABLE LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT BEGIN diff --git a/dlls/winmm/winmm_Es.rc b/dlls/winmm/winmm_Es.rc index 8713075adf8..5d22f7bf8b0 100644 --- a/dlls/winmm/winmm_Es.rc +++ b/dlls/winmm/winmm_Es.rc @@ -17,9 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - STRINGTABLE LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL BEGIN diff --git a/dlls/winmm/winmm_Fr.rc b/dlls/winmm/winmm_Fr.rc dissimilarity index 84% index 47510075a59..de66778a77f 100644 --- a/dlls/winmm/winmm_Fr.rc +++ b/dlls/winmm/winmm_Fr.rc @@ -1,137 +1,131 @@ -/* - * Winmm - * French language support - * - * Copyright 1999 Eric Pouech - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "windef.h" -#include "mmddk.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL - -STRINGTABLE -BEGIN - -/* MMSYS errors */ -MMSYSERR_NOERROR, "La commande spécifiée a été exécutée." -MMSYSERR_ERROR, "Erreur externe non définie." -MMSYSERR_BADDEVICEID, "Un identificateur de périphérique hors des limites pour votre système a été utilisé." -MMSYSERR_NOTENABLED, "Le pilote n'a pas été activé." -MMSYSERR_ALLOCATED, "Le périphérique spécifié est en cours d'utilisation. Attendez qu'il soit libre, puis essayez à nouveau." -MMSYSERR_INVALHANDLE, "Le handle de périphérique spécifié n'est pas valide." -MMSYSERR_NODRIVER, "Il n'y a pas de pilote installé sur votre système." -MMSYSERR_NOMEM, "Mémoire insuffisante pour cette tâche. Quittez un ou plusieurs programmes, puis essayez à nouveau." -MMSYSERR_NOTSUPPORTED, "Fonction non prise en charge. Utilisez la fonction Capacités pour obtenir les fonctions de ce pilote." -MMSYSERR_BADERRNUM, "Un numéro d'erreur non défini dans le système a été spécifié." -MMSYSERR_INVALFLAG, "Un indicateur non valide a été transmis à une fonction système." -MMSYSERR_INVALPARAM, "Un paramètre non valide a été passé à une fonction système." - -/* WAVE errors */ -WAVERR_BADFORMAT, "Le format choisi ne peut être traduit ou utilisé. Utilisez Capacités pour voir les formats pris en charge." -WAVERR_STILLPLAYING, "Le Lecteur multimédia continue à lire des données. Réinitialisez-le ou attendez que toutes les données aient été lues." -WAVERR_UNPREPARED, "L'en-tête du son n'a pas été préparé. Utilisez la fonction Préparer pour le faire, puis essayez à nouveau." -WAVERR_SYNC, "Impossible d'ouvrir le périphérique sans utiliser l'indicateur WAVE_ALLOWSYNC. Utilisez l'indicateur, puis essayez à nouveau." - -/* MIDI errors */ -MIDIERR_UNPREPARED, "L'en-tête MIDI n'a pas été préparé. Utilisez la fonction Préparer pour le faire, puis essayez à nouveau." -MIDIERR_STILLPLAYING, "Le Lecteur multimédia continue à lire des données. Réinitialisez-le ou attendez que toutes les données aient été. lues." -MIDIERR_NOMAP, "Il n'y a pas d'instrument défini pour un mappeur MIDI. Utiliser l'onglet MIDI dans Propriétés multimédia pour installer les instruments." -MIDIERR_NOTREADY, "Le port transmet des données au périphérique. Attendez la fin de la transmission, puis essayez à nouveau." -MIDIERR_NODEVICE, "Le fichier de description d'instrument MIDI (.IDF) n'est pas valide. Pour plus d'informations, contactez le constructeur de l'instrument." -MIDIERR_INVALIDSETUP, "Un appel MIDI non valide dans le mode d'ouverture en cours a été émis. Ouvrez à nouveau le périphérique en employant le mode correct." - -/* MCI errors */ -MCIERR_INVALID_DEVICE_ID, "ID de périphérique MCI non valide. Utilisez l'ID renvoyé lorsque vous avez ouvert le périphérique MCI." -MCIERR_UNRECOGNIZED_KEYWORD, "Le paramètre de commande utilisé n'est pas défini dans l'ensemble de commandes MCI." -MCIERR_UNRECOGNIZED_COMMAND, "La commande utilisée n'est pas une commande MCI valide." -MCIERR_HARDWARE, "Votre périphérique multimédia présente un problème. Vérifiez qu'il fonctionne convenablement ou contactez le constructeur." -MCIERR_INVALID_DEVICE_NAME, "Ce n'est pas un périphérique MCI connu." -MCIERR_OUT_OF_MEMORY, "Mémoire insuffisante pour cette tâche. Quittez un ou plusieurs programmes, puis essayez à nouveau." -MCIERR_DEVICE_OPEN, "Cet alias est déjà utilisé par ce programme. Employez un alias unique plutôt que le nom du périphérique." -MCIERR_CANNOT_LOAD_DRIVER, "Le pilote de périphérique n'a pas pu être chargé. Vérifiez qu'il est installé correctement." -MCIERR_MISSING_COMMAND_STRING, "La chaîne de commande est vide." -MCIERR_PARAM_OVERFLOW, "La chaîne de sortie était trop grande pour tenir dans la mémoire tampon de retour. Augmentez la taille de la mémoire tampon." -MCIERR_MISSING_STRING_ARGUMENT, "La commande spécifiée nécessite un paramètre chaîne de caractères : veuillez l'entrer." -MCIERR_BAD_INTEGER, "Le nombre entier que vous avez spécifié n'est pas valide pour cette commande. Entrez un nombre." -MCIERR_PARSER_INTERNAL, "Le pilote de périphérique a renvoyé une réponse de type non valide. Pour obtenir un nouveau pilote, contactez le constructeur du périphérique." -MCIERR_DRIVER_INTERNAL, "Le pilote de périphérique présente un problème. Demandez au constructeur du périphérique de vous fournir un nouveau pilote." -MCIERR_MISSING_PARAMETER, "Il manque un paramètre dans la commande spécifiée : veuillez l'entrer." -MCIERR_UNSUPPORTED_FUNCTION, "Le périphérique MCI que vous utilisez ne prend pas en charge la commande spécifiée." -MCIERR_FILE_NOT_FOUND, "Le fichier spécifié est introuvable. Vérifiez que le chemin d'accès et le nom de fichier sont corrects." -MCIERR_DEVICE_NOT_READY, "Le pilote de périphérique n'est pas prêt. Attendez une minute avant d'essayer à nouveau." -MCIERR_INTERNAL, "Un problème est survenu lors de l'initialisation de MCI. Essayez de redémarrer Windows." -MCIERR_DRIVER, "Une erreur spécifique au pilote a provoqué sa fermeture. Essayez de relancer la commande." -MCIERR_CANNOT_USE_ALL, "Utilisez un nom de périphérique spécifique pour cette commande." -MCIERR_MULTIPLE, "Des erreurs se sont produites dans plusieurs périphériques. Spécifiez chaque commande et chaque périphérique séparément afin de déterminer les périphériques qui ont provoqué les erreurs." -MCIERR_EXTENSION_NOT_FOUND, "Impossible de jouer ce fichier. Vérifiez le nom de fichier ou installez un pilote qui reconnaît ce type de fichier." -MCIERR_OUTOFRANGE, "Le paramètre est hors limites pour la commande spécifiée." -MCIERR_FLAGS_NOT_COMPATIBLE, "Les paramètres spécifiés ne peuvent être utilisés ensemble." -MCIERR_FILE_NOT_SAVED, "Il est impossible d'enregistrer le fichier spécifié. Vérifiez que vous avez assez d'espace disque ou que vous êtes toujours connecté au réseau." -MCIERR_DEVICE_TYPE_REQUIRED, "Le périphérique spécifié est introuvable. Vérifiez s'il est installé ou si son nom est correctement orthographié." -MCIERR_DEVICE_LOCKED, "Le périphérique spécifié est en cours de fermeture. Attendez quelques secondes puis essayez à nouveau." -MCIERR_DUPLICATE_ALIAS, "L'alias spécifié est déjà utilisé dans cette application. Utilisez un alias unique." -MCIERR_BAD_CONSTANT, "La constante utilisée n'est pas correcte pour cette commande." -MCIERR_MUST_USE_SHAREABLE, "Le pilote de périphérique est déjà utilisé en ce moment. Pour le partager, utilisez le paramètre de partage ('shareable') dans chaque commande d'ouverture ('open')." -MCIERR_MISSING_DEVICE_NAME, "La commande spécifiée requiert un nom d'alias, de fichier, de pilote ou de périphérique : veuillez l'entrer." -MCIERR_BAD_TIME_FORMAT, "La valeur spécifiée comme format horaire n'est pas valide. Les formats valides sont indiqués dans la documentation MCI." -MCIERR_NO_CLOSING_QUOTE, "Un guillemet double fermant manque dans la valeur du paramètre. Ajoutez-le." -MCIERR_DUPLICATE_FLAGS, "Un paramètre ou une valeur a été spécifié deux fois et ne peut être spécifié qu'une seule fois." -MCIERR_INVALID_FILE, "Le fichier ne peut pas être exécuté sur un périphérique MCI spécifié. Le fichier est endommagé ou son format n'est pas correct." -MCIERR_NULL_PARAMETER_BLOCK, "Un bloc de paramètres nuls a été passé à MCI." -MCIERR_UNNAMED_RESOURCE, "Impossible d'enregistrer un fichier sans nom. Entrez un nom de fichier." -MCIERR_NEW_REQUIRES_ALIAS, "Vous devez spécifier un alias lorsque vous employez le paramètre 'nouveau'." -MCIERR_NOTIFY_ON_AUTO_OPEN, "Il est impossible d'utiliser l'indicateur 'notifier' avec les périphériques à ouverture automatique." -MCIERR_NO_ELEMENT_ALLOWED, "Impossible d'utiliser un nom de fichier avec le périphérique spécifié." -MCIERR_NONAPPLICABLE_FUNCTION, "Impossible d'exécuter les commandes dans l'ordre spécifié. Corrigez l'ordre des commandes, puis essayez à nouveau." -MCIERR_ILLEGAL_FOR_AUTO_OPEN, "Impossible d'exécuter cette commande sur un périphérique à ouverture automatique. Attendez que le périphérique soit fermé pour essayer à nouveau." -MCIERR_FILENAME_REQUIRED, "Le nom de fichier est incorrect." -MCIERR_EXTRA_CHARACTERS, "Il est impossible de spécifier des caractères supplémentaires après une chaîne placée entre guillemets." -MCIERR_DEVICE_NOT_INSTALLED, "Ce périphérique n'est pas installé. Pour installer un nouveau pilote, double-cliquez sur l'icône Ajout de périphérique dans le Panneau de configuration." -MCIERR_GET_CD, "Impossible d'accéder au fichier ou au périphérique MCI spécifié. Essayez de changer de répertoire ou de redémarrer votre ordinateur." -MCIERR_SET_CD, "Impossible d'accéder au fichier ou au périphérique MCI spécifié, car l'application ne peut pas changer de répertoire." -MCIERR_SET_DRIVE, "Impossible d'accéder au fichier ou au périphérique MCI spécifié, car l'application ne peut pas changer de lecteur." -MCIERR_DEVICE_LENGTH, "Spécifiez un nom de périphérique ou de pilote de moins de 79 caractères." -MCIERR_DEVICE_ORD_LENGTH, "Spécifiez un nom de périphérique ou de pilote comptant moins de 69 caractères." -MCIERR_NO_INTEGER, "La commande spécifiée nécessite un paramètre numérique. Exemple : ""jouer jusqu'à 10"". Entrez ce paramètre." -MCIERR_WAVE_OUTPUTSINUSE, "Tous les périphériques audio capables de jouer des fichiers sous ce format sont en cours d'utilisation. Attendez qu'un périphérique audio soit libre, puis essayez à nouveau." -MCIERR_WAVE_SETOUTPUTINUSE, "Le périphérique audio de lecture est en cours d'utilisation. Attendez qu'il soit libre, puis essayez à nouveau." -MCIERR_WAVE_INPUTSINUSE, "Tous les périphériques audio capables d'enregistrer des fichiers sous ce format sont en cours d'utilisation. Attendez qu'un périphérique audio soit libre, puis essayez à nouveau." -MCIERR_WAVE_SETINPUTINUSE, "Le périphérique audio d'enregistrement est en cours d'utilisation. Attendez qu'il soit libre, puis essayez à nouveau." -MCIERR_WAVE_OUTPUTUNSPECIFIED, "N'importe quel périphérique audio de lecture peut être utilisé." -MCIERR_WAVE_INPUTUNSPECIFIED, "N'importe quel périphérique audio d'enregistrement peut être utilisé." -MCIERR_WAVE_OUTPUTSUNSUITABLE, "Aucun périphérique audio capable de jouer des fichiers sous le format en cours n'a été installé." -MCIERR_WAVE_SETOUTPUTUNSUITABLE,"Ce périphérique ne parvient pas à reconnaître le format du fichier actuel. Sélectionnez un autre périphérique, puis essayez à nouveau." -MCIERR_WAVE_INPUTSUNSUITABLE, "Aucun périphérique audio capable d'enregistrer des fichiers sous le format en cours n'a été installé." -MCIERR_WAVE_SETINPUTUNSUITABLE, "Ce périphérique ne parvient pas à reconnaître le format du fichier actuel. Sélectionnez un autre périphérique, puis essayez à nouveau." -MCIERR_NO_WINDOW, "Il n'y pas de fenêtre d'affichage." -MCIERR_CREATEWINDOW, "Impossible d'utiliser ou de créer une fenêtre." -MCIERR_FILE_READ, "Impossible de lire ce fichier. Assurez-vous qu'il n'a pas été supprimé ou vérifiez votre disque ou votre connexion réseau." -MCIERR_FILE_WRITE, "Il est impossible d'écrire des informations dans le fichier spécifié. Vérifiez que vous avez assez d'espace disque ou que vous êtes toujours connecté au réseau." -MCIERR_SEQ_DIV_INCOMPATIBLE, "Il est impossible d'utiliser le format horaire pointeur de piste et le format horaire SMPTE en même temps." -MCIERR_SEQ_NOMIDIPRESENT, "Le système n'a pas de périphériques MIDI installés. Pour installer un nouveau pilote, double-cliquez sur l'icône Ajout de périphérique dans le Panneau de configuration." -MCIERR_SEQ_PORT_INUSE, "Le port MIDI spécifié est déjà utilisé. Attendez qu'il soit libre et essayez à nouveau." -MCIERR_SEQ_PORT_MAPNODEVICE, "La configuration actuelle du mappeur MIDI fait référence à un périphérique MIDI non installé sur votre système. Utilisez l'option mappeur MIDI dans le Panneau de Configuration pour changer la configuration." -MCIERR_SEQ_PORT_MISCERROR, "Une erreur est survenue sur le port spécifié." -MCIERR_SEQ_PORT_NONEXISTENT, "Ce périphérique n'est pas installé. Pour installer un nouveau pilote, double-cliquez sur l'icône Ajout de périphérique dans le Panneau de configuration." -MCIERR_SEQ_PORTUNSPECIFIED, "Le système n'a pas spécifié de port MIDI par défaut." -MCIERR_SEQ_TIMER, "Tous les temporisateurs multimédia sont en cours d'utilisation par d'autres applications. Quittez une de ces applications et essayez à nouveau." - -END +/* + * Winmm + * French language support + * + * Copyright 1999 Eric Pouech + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL + +STRINGTABLE +BEGIN + +/* MMSYS errors */ +MMSYSERR_NOERROR, "La commande spécifiée a été exécutée." +MMSYSERR_ERROR, "Erreur externe non définie." +MMSYSERR_BADDEVICEID, "Un identificateur de périphérique hors des limites pour votre système a été utilisé." +MMSYSERR_NOTENABLED, "Le pilote n'a pas été activé." +MMSYSERR_ALLOCATED, "Le périphérique spécifié est en cours d'utilisation. Attendez qu'il soit libre, puis essayez à nouveau." +MMSYSERR_INVALHANDLE, "Le handle de périphérique spécifié n'est pas valide." +MMSYSERR_NODRIVER, "Il n'y a pas de pilote installé sur votre système." +MMSYSERR_NOMEM, "Mémoire insuffisante pour cette tâche. Quittez un ou plusieurs programmes, puis essayez à nouveau." +MMSYSERR_NOTSUPPORTED, "Fonction non prise en charge. Utilisez la fonction Capacités pour obtenir les fonctions de ce pilote." +MMSYSERR_BADERRNUM, "Un numéro d'erreur non défini dans le système a été spécifié." +MMSYSERR_INVALFLAG, "Un indicateur non valide a été transmis à une fonction système." +MMSYSERR_INVALPARAM, "Un paramètre non valide a été passé à une fonction système." + +/* WAVE errors */ +WAVERR_BADFORMAT, "Le format choisi ne peut être traduit ou utilisé. Utilisez Capacités pour voir les formats pris en charge." +WAVERR_STILLPLAYING, "Le Lecteur multimédia continue à lire des données. Réinitialisez-le ou attendez que toutes les données aient été lues." +WAVERR_UNPREPARED, "L'en-tête du son n'a pas été préparé. Utilisez la fonction Préparer pour le faire, puis essayez à nouveau." +WAVERR_SYNC, "Impossible d'ouvrir le périphérique sans utiliser l'indicateur WAVE_ALLOWSYNC. Utilisez l'indicateur, puis essayez à nouveau." + +/* MIDI errors */ +MIDIERR_UNPREPARED, "L'en-tête MIDI n'a pas été préparé. Utilisez la fonction Préparer pour le faire, puis essayez à nouveau." +MIDIERR_STILLPLAYING, "Le Lecteur multimédia continue à lire des données. Réinitialisez-le ou attendez que toutes les données aient été. lues." +MIDIERR_NOMAP, "Il n'y a pas d'instrument défini pour un mappeur MIDI. Utiliser l'onglet MIDI dans Propriétés multimédia pour installer les instruments." +MIDIERR_NOTREADY, "Le port transmet des données au périphérique. Attendez la fin de la transmission, puis essayez à nouveau." +MIDIERR_NODEVICE, "Le fichier de description d'instrument MIDI (.IDF) n'est pas valide. Pour plus d'informations, contactez le constructeur de l'instrument." +MIDIERR_INVALIDSETUP, "Un appel MIDI non valide dans le mode d'ouverture en cours a été émis. Ouvrez à nouveau le périphérique en employant le mode correct." + +/* MCI errors */ +MCIERR_INVALID_DEVICE_ID, "ID de périphérique MCI non valide. Utilisez l'ID renvoyé lorsque vous avez ouvert le périphérique MCI." +MCIERR_UNRECOGNIZED_KEYWORD, "Le paramêtre de commande utilisé n'est pas défini dans l'ensemble de commandes MCI." +MCIERR_UNRECOGNIZED_COMMAND, "La commande utilisée n'est pas une commande MCI valide." +MCIERR_HARDWARE, "Votre périphérique multimédia présente un problème. Vérifiez qu'il fonctionne convenablement ou contactez le constructeur." +MCIERR_INVALID_DEVICE_NAME, "Ce n'est pas un périphérique MCI connu." +MCIERR_OUT_OF_MEMORY, "Mémoire insuffisante pour cette tâche. Quittez un ou plusieurs programmes, puis essayez à nouveau." +MCIERR_DEVICE_OPEN, "Cet alias est déjà utilisé par ce programme. Employez un alias unique plutôt que le nom du périphérique." +MCIERR_CANNOT_LOAD_DRIVER, "Le pilote de périphérique n'a pas pu être chargé. Vérifiez qu'il est installé correctement." +MCIERR_MISSING_COMMAND_STRING, "La chaîne de commande est vide." +MCIERR_PARAM_OVERFLOW, "La chaîne de sortie était trop grande pour tenir dans la mémoire tampon de retour. Augmentez la taille de la mémoire tampon." +MCIERR_MISSING_STRING_ARGUMENT, "La commande spécifiée nécessite un paramêtre chaîne de caractères : veuillez l'entrer." +MCIERR_BAD_INTEGER, "Le nombre entier que vous avez spécifié n'est pas valide pour cette commande. Entrez un nombre." +MCIERR_PARSER_INTERNAL, "Le pilote de périphérique a renvoyé une réponse de type non valide. Pour obtenir un nouveau pilote, contactez le constructeur du périphérique." +MCIERR_DRIVER_INTERNAL, "Le pilote de périphérique présente un problème. Demandez au constructeur du périphérique de vous fournir un nouveau pilote." +MCIERR_MISSING_PARAMETER, "Il manque un paramêtre dans la commande spécifiée : veuillez l'entrer." +MCIERR_UNSUPPORTED_FUNCTION, "Le périphérique MCI que vous utilisez ne prend pas en charge la commande spécifiée." +MCIERR_FILE_NOT_FOUND, "Le fichier spécifié est introuvable. Vérifiez que le chemin d'accès et le nom de fichier sont corrects." +MCIERR_DEVICE_NOT_READY, "Le pilote de périphérique n'est pas prêt. Attendez une minute avant d'essayer à nouveau." +MCIERR_INTERNAL, "Un problème est survenu lors de l'initialisation de MCI. Essayez de redémarrer Windows." +MCIERR_DRIVER, "Une erreur spécifique au pilote a provoqué sa fermeture. Essayez de relancer la commande." +MCIERR_CANNOT_USE_ALL, "Utilisez un nom de périphérique spécifique pour cette commande." +MCIERR_MULTIPLE, "Des erreurs se sont produites dans plusieurs périphériques. Spécifiez chaque commande et chaque périphérique séparément afin de déterminer les périphériques qui ont provoqué les erreurs." +MCIERR_EXTENSION_NOT_FOUND, "Impossible de jouer ce fichier. Vérifiez le nom de fichier ou installez un pilote qui reconnaît ce type de fichier." +MCIERR_OUTOFRANGE, "Le paramêtre est hors limites pour la commande spécifiée." +MCIERR_FLAGS_NOT_COMPATIBLE, "Les paramêtres spécifiés ne peuvent être utilisés ensemble." +MCIERR_FILE_NOT_SAVED, "Il est impossible d'enregistrer le fichier spécifié. Vérifiez que vous avez assez d'espace disque ou que vous êtes toujours connecté au réseau." +MCIERR_DEVICE_TYPE_REQUIRED, "Le périphérique spécifié est introuvable. Vérifiez s'il est installé ou si son nom est correctement orthographié." +MCIERR_DEVICE_LOCKED, "Le périphérique spécifié est en cours de fermeture. Attendez quelques secondes, puis essayez à nouveau." +MCIERR_DUPLICATE_ALIAS, "L'alias spécifié est déjà utilisé dans cette application. Utilisez un alias unique." +MCIERR_BAD_CONSTANT, "La constante utilisée n'est pas correcte pour cette commande." +MCIERR_MUST_USE_SHAREABLE, "Le pilote de périphérique est déjà utilisé en ce moment. Pour le partager, utilisez le paramêtre de partage ('shareable') dans chaque commande d'ouverture ('open')." +MCIERR_MISSING_DEVICE_NAME, "La commande spécifiée requiert un nom d'alias, de fichier, de pilote ou de périphérique : veuillez l'entrer." +MCIERR_BAD_TIME_FORMAT, "La valeur spécifiée comme format horaire n'est pas valide. Les formats valides sont indiqués dans la documentation MCI." +MCIERR_NO_CLOSING_QUOTE, "Un guillemet double fermant manque dans la valeur du paramêtre. Ajoutez-le." +MCIERR_DUPLICATE_FLAGS, "Un paramêtre ou une valeur a été spécifié deux fois et ne doit être spécifié qu'une seule fois." +MCIERR_INVALID_FILE, "Le fichier ne peut pas être exécuté sur un périphérique MCI spécifié. Le fichier est endommagé ou son format n'est pas correct." +MCIERR_NULL_PARAMETER_BLOCK, "Un bloc de paramêtres nuls a été passé à MCI." +MCIERR_UNNAMED_RESOURCE, "Impossible d'enregistrer un fichier sans nom. Entrez un nom de fichier." +MCIERR_NEW_REQUIRES_ALIAS, "Vous devez spécifier un alias lorsque vous employez le paramêtre 'nouveau'." +MCIERR_NOTIFY_ON_AUTO_OPEN, "Il est impossible d'utiliser l'indicateur 'notifier' avec les périphériques à ouverture automatique." +MCIERR_NO_ELEMENT_ALLOWED, "Impossible d'utiliser un nom de fichier avec le périphérique spécifié." +MCIERR_NONAPPLICABLE_FUNCTION, "Impossible d'exécuter les commandes dans l'ordre spécifié. Corrigez l'ordre des commandes, puis essayez à nouveau." +MCIERR_ILLEGAL_FOR_AUTO_OPEN, "Impossible d'exécuter cette commande sur un périphérique à ouverture automatique. Attendez que le périphérique soit fermé pour essayer à nouveau." +MCIERR_FILENAME_REQUIRED, "Le nom de fichier est incorrect." +MCIERR_EXTRA_CHARACTERS, "Il est impossible de spécifier des caractères supplémentaires après une chaîne placée entre guillemets." +MCIERR_DEVICE_NOT_INSTALLED, "Ce périphérique n'est pas installé. Pour installer un nouveau pilote, double-cliquez sur l'icône Ajout de périphérique dans le Panneau de configuration." +MCIERR_GET_CD, "Impossible d'accéder au fichier ou au périphérique MCI spécifié. Essayez de changer de répertoire ou de redémarrer votre ordinateur." +MCIERR_SET_CD, "Impossible d'accéder au fichier ou au périphérique MCI spécifié, car l'application ne peut pas changer de répertoire." +MCIERR_SET_DRIVE, "Impossible d'accéder au fichier ou au périphérique MCI spécifié, car l'application ne peut pas changer de lecteur." +MCIERR_DEVICE_LENGTH, "Spécifiez un nom de périphérique ou de pilote de moins de 79 caractères." +MCIERR_DEVICE_ORD_LENGTH, "Spécifiez un nom de périphérique ou de pilote comptant moins de 69 caractères." +MCIERR_NO_INTEGER, "La commande spécifiée nécessite un paramêtre numérique. Exemple : ""jouer jusqu'à 10"". Entrez ce paramêtre." +MCIERR_WAVE_OUTPUTSINUSE, "Tous les périphériques audio capables de jouer des fichiers sous ce format sont en cours d'utilisation. Attendez qu'un périphérique audio soit libre, puis essayez à nouveau." +MCIERR_WAVE_SETOUTPUTINUSE, "Le périphérique audio de lecture est en cours d'utilisation. Attendez qu'il soit libre, puis essayez à nouveau." +MCIERR_WAVE_INPUTSINUSE, "Tous les périphériques audio capables d'enregistrer des fichiers sous ce format sont en cours d'utilisation. Attendez qu'un périphérique audio soit libre, puis essayez à nouveau." +MCIERR_WAVE_SETINPUTINUSE, "Le périphérique audio d'enregistrement est en cours d'utilisation. Attendez qu'il soit libre, puis essayez à nouveau." +MCIERR_WAVE_OUTPUTUNSPECIFIED, "N'importe quel périphérique audio de lecture peut être utilisé." +MCIERR_WAVE_INPUTUNSPECIFIED, "N'importe quel périphérique audio d'enregistrement peut être utilisé." +MCIERR_WAVE_OUTPUTSUNSUITABLE, "Aucun périphérique audio capable de jouer des fichiers sous le format en cours n'a été installé." +MCIERR_WAVE_SETOUTPUTUNSUITABLE,"Ce périphérique ne parvient pas à reconnaître le format du fichier actuel. Sélectionnez un autre périphérique, puis essayez à nouveau." +MCIERR_WAVE_INPUTSUNSUITABLE, "Aucun périphérique audio capable d'enregistrer des fichiers sous le format en cours n'a été installé." +MCIERR_WAVE_SETINPUTUNSUITABLE, "Ce périphérique ne parvient pas à reconnaître le format du fichier actuel. Sélectionnez un autre périphérique, puis essayez à nouveau." +MCIERR_NO_WINDOW, "Il n'y pas de fenêtre d'affichage." +MCIERR_CREATEWINDOW, "Impossible d'utiliser ou de créer une fenêtre." +MCIERR_FILE_READ, "Impossible de lire ce fichier. Assurez-vous qu'il n'a pas été supprimé ou vérifiez votre disque ou votre connexion réseau." +MCIERR_FILE_WRITE, "Il est impossible d'écrire des informations dans le fichier spécifié. Vérifiez que vous avez assez d'espace disque ou que vous êtes toujours connecté au réseau." +MCIERR_SEQ_DIV_INCOMPATIBLE, "Il est impossible d'utiliser le format horaire pointeur de piste et le format horaire SMPTE en même temps." +MCIERR_SEQ_NOMIDIPRESENT, "Le système n'a pas de périphériques MIDI installés. Pour installer un nouveau pilote, double-cliquez sur l'icône Ajout de périphérique dans le Panneau de configuration." +MCIERR_SEQ_PORT_INUSE, "Le port MIDI spécifié est déjà utilisé. Attendez qu'il soit libre et essayez à nouveau." +MCIERR_SEQ_PORT_MAPNODEVICE, "La configuration actuelle du mappeur MIDI fait référence à un périphérique MIDI non installé sur votre système. Utilisez l'option mappeur MIDI dans le Control Panel pour changer la configuration." +MCIERR_SEQ_PORT_MISCERROR, "Une erreur est survenue sur le port spécifié." +MCIERR_SEQ_PORT_NONEXISTENT, "Ce périphérique n'est pas installé. Pour installer un nouveau pilote, double-cliquez sur l'icône Ajout de périphérique dans le Panneau de configuration." +MCIERR_SEQ_PORTUNSPECIFIED, "Le système n'a pas spécifié de port MIDI par défaut." +MCIERR_SEQ_TIMER, "Tous les timers multimédia sont en cours d'utilisation par d'autres applications. Quittez une de ces applications et essayez à nouveau." + +END diff --git a/dlls/winmm/winmm_It.rc b/dlls/winmm/winmm_It.rc index f4c2fa078f9..91d5818d906 100644 --- a/dlls/winmm/winmm_It.rc +++ b/dlls/winmm/winmm_It.rc @@ -17,9 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - STRINGTABLE LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL BEGIN diff --git a/dlls/winmm/winmm_Ja.rc b/dlls/winmm/winmm_Ja.rc index b8f1c53cee5..1805ac866c0 100644 --- a/dlls/winmm/winmm_Ja.rc +++ b/dlls/winmm/winmm_Ja.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - /* UTF-8 */ #pragma code_page(65001) @@ -130,3 +127,5 @@ MCIERR_SEQ_PORTUNSPECIFIED, "システムに現在のMIDIポートが指定さ MCIERR_SEQ_TIMER, "全てのマルチメディアタイマは他のアプリケーションによって使用されています。タイマを使用しているアプリケーションを一つ終了してからやり直して下さい。" END + +#pragma code_page(default) diff --git a/dlls/winmm/winmm_Ko.rc b/dlls/winmm/winmm_Ko.rc index bf7c8a50a4d..1d5c074baa9 100644 --- a/dlls/winmm/winmm_Ko.rc +++ b/dlls/winmm/winmm_Ko.rc @@ -17,9 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - STRINGTABLE LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT BEGIN diff --git a/dlls/winmm/winmm_Lt.rc b/dlls/winmm/winmm_Lt.rc deleted file mode 100644 index 6cb9981e1a8..00000000000 --- a/dlls/winmm/winmm_Lt.rc +++ /dev/null @@ -1,134 +0,0 @@ -/* - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "windef.h" -#include "mmddk.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE -BEGIN - -/* MMSYS errors */ -MMSYSERR_NOERROR, "Nurodyta komanda buvo atlikta." -MMSYSERR_ERROR, "Neapibrėžta išorinė klaida." -MMSYSERR_BADDEVICEID, "Buvo panaudotas įrenginio identifikatorius, kuris nepatenka į sistemos rėžius." -MMSYSERR_NOTENABLED, "Tvarkyklė nebuvo įjungta." -MMSYSERR_ALLOCATED, "Nurodytas įrenginys jau naudojamas. Palaukite, kol jis atsilaisvins, tada mėginkite vėl." -MMSYSERR_INVALHANDLE, "Nurodyta įrenginio rodyklė yra netinkama." -MMSYSERR_NODRIVER, "Sistemoje nėra įdiegta tvarkyklė!\n" -MMSYSERR_NOMEM, "Trūksta atminties šiai užduočiai. Išeikite iš vienos ar daugiau programų laisvos atminties kiekiui padidinti ir mėginkite vėl." -MMSYSERR_NOTSUPPORTED, "Ši funkcija yra nepalaikoma. Naudokite gebėjimų (Capabilities) funkciją, kad nustatytumėte, kurias funkcijas ir pranešimus tvarkyklė palaiko." -MMSYSERR_BADERRNUM, "Buvo nurodytas klaidos kodas, kuris yra neapibrėžtas sistemoje." -MMSYSERR_INVALFLAG, "Sisteminei funkcijai buvo perduotas neteisingas žymos bitas." -MMSYSERR_INVALPARAM, "Sisteminei funkcijai buvo perduotas neteisingas parametras." - -/* WAVE errors */ -WAVERR_BADFORMAT, "Nurodytas formatas yra nepalaikomas arba negali būti perskaičiuotas. Naudokite gebėjimų (Capabilities) funkciją palaikomiems formatams nustatyti" -WAVERR_STILLPLAYING, "Negalima įvykdyti šios operacijos kol medijos duomenys dar groja. Paleiskite įrenginį iš naujo arba laukite kol duomenys bus baigti groti." -WAVERR_UNPREPARED, "Wave antraštė nebuvo paruošta. Naudokite paruošimo (Prepare) funkciją antraštei paruošti ir mėginkite vėl." -WAVERR_SYNC, "Negalima atverti įrenginio nenaudojat WAVE_ALLOWSYNC žymos bito. Naudokite žymos bitą ir mėginkite vėl." - -/* MIDI errors */ -MIDIERR_UNPREPARED, "MIDI antraštė nebuvo paruošta. Naudokite paruošimo (Prepare) funkciją antraštei paruošti ir mėginkite vėl." -MIDIERR_STILLPLAYING, "Negalima įvykdyti šios operacijos, kol medijos duomenys dar groja. Paleiskite įrenginį iš naujo arba laukite kol duomenys bus baigti groti." -MIDIERR_NOMAP, "MIDI atvaizdis nerastas. Tai gali būti problema su tvarkykle arba trūksta MIDIMAP.CFG failo arba jis yra pažeistas." -MIDIERR_NOTREADY, "Prievadas perduoda duomenis įrenginiui. Palaukite kol duomenys bus perduoti ir mėginkite vėl." -MIDIERR_NODEVICE, "Dabartinė MIDI atvaizdžio konfigūracija kreipiasi į MIDI įrenginį, kuris nėra įdiegtas sistemoje. Naudokite MIDI Mapper konfigūracijai redaguoti." -MIDIERR_INVALIDSETUP, "Dabartinė MIDI konfigūracija yra pažeista. Nukopijuokite originalų MIDIMAP.CFG failą į Windows SYSTEM katalogą ir mėginkite vėl." - -/* MCI errors */ -MCIERR_INVALID_DEVICE_ID, "Klaidingas MCI įrenginio identifikatorius. Naudokite identifikatorių grąžintą atveriant MCI įrenginį." -MCIERR_UNRECOGNIZED_KEYWORD, "Tvarkyklė negali atpažinti nurodyto komandos parametro." -MCIERR_UNRECOGNIZED_COMMAND, "Tvarkyklė negali atpažinti nurodytos komandos." -MCIERR_HARDWARE, "Iškilo problema su jūsų medijos įrenginiu. Įsitikinkite, kad jis veikia teisingai arba kreipkitės į įrenginio gamintoją." -MCIERR_INVALID_DEVICE_NAME, "Nurodytas įrenginys nėra atvertas arba yra neatpažintas MCI." -MCIERR_OUT_OF_MEMORY, "Trūksta atminties šiai užduočiai.\nIšeikite iš vienos ar daugiau programų laisvos atminties kiekiui padidinti ir mėginkite vėl." -MCIERR_DEVICE_OPEN, "Įrenginio vardas jau yra naudojamas programos kaip alternatyvus vardas. Naudokite unikalų alternatyvų vardą." -MCIERR_CANNOT_LOAD_DRIVER, "Iškilo neaptinkama klaida įkeliant nurodytą įrenginio tvarkyklę." -MCIERR_MISSING_COMMAND_STRING, "Nenurodyta jokia komanda." -MCIERR_PARAM_OVERFLOW, "Išvedimo eilutė buvo per ilga, kad tilptų į buferį. Padidinkite buferio dydį." -MCIERR_MISSING_STRING_ARGUMENT, "Nurodytai komandai reikalingas simbolių eilutės parametras. Prašome jį nurodyti." -MCIERR_BAD_INTEGER, "Nurodytas sveikasis skaičius yra klaidingas šiai komandai." -MCIERR_PARSER_INTERNAL, "Įrenginio tvarkyklė grąžino klaidingą atsakymo tipą. Susisiekite su įrenginio gamintoju dėl naujos tvarkyklės gavimo." -MCIERR_DRIVER_INTERNAL, "Yra problema su įrenginio tvarkykle. Susisiekite su įrenginio gamintoju dėl naujos tvarkyklės gavimo." -MCIERR_MISSING_PARAMETER, "Nurodytai komandai yra privalomas parametras. Prašome jį nurodyti." -MCIERR_UNSUPPORTED_FUNCTION, "MCI įrenginys, kurį jūs naudojate, nepalaiko nurodytos komandos." -MCIERR_FILE_NOT_FOUND, "Nepavyko rasti nurodyto failo. Įsitikinkite, kad kelias ir failo vardas yra teisingi." -MCIERR_DEVICE_NOT_READY, "Įrenginio tvarkyklė neparengta." -MCIERR_INTERNAL, "Įvyko klaida inicijuojant MCI. Mėginkite perkrauti Windows." -MCIERR_DRIVER, "Yra problema su įrenginio tvarkykle. Tvarkyklė buvo užverta. Nepavyko gauti klaidos." -MCIERR_CANNOT_USE_ALL, "Negalima naudoti „all“ kaip įrenginio vardo nurodytai komandai." -MCIERR_MULTIPLE, "Įvyko klaidų daugiau kaip viename įrenginyje. Nurodykite kiekvieną komandą ir įrenginį atskirai, kad nustatytumėte, kurie įrenginiai sukėlė klaidą." -MCIERR_EXTENSION_NOT_FOUND, "Nepavyko nustatyti įrenginio tipo iš duoto failo prievardžio." -MCIERR_OUTOFRANGE, "Nurodytas parametras nepatenka į rėžius nurodytai komandai." -MCIERR_FLAGS_NOT_COMPATIBLE, "Nurodyti parametrai negali būti naudojami kartu." -MCIERR_FILE_NOT_SAVED, "Nepavyko išsaugoti nurodyto failo. Įsitikinkite, kad diske yra pakankamai vietos, ar vis dar prisijungę prie tinklo." -MCIERR_DEVICE_TYPE_REQUIRED, "Nepavyko rasti nurodyto įrenginio. Įsitikinkite, kad jis įdiegtas ir ar teisingai įrašytas įrenginio vardas." -MCIERR_DEVICE_LOCKED, "Nurodytas įrenginys yra užveriamas. Palaukite kelias sekundes ir mėginkite vėl." -MCIERR_DUPLICATE_ALIAS, "Nurodytas alternatyvus vardas jau yra naudojamas šioje programoje. Naudokite unikalų alternatyvų vardą." -MCIERR_BAD_CONSTANT, "Nurodytas parametras yra klaidingas šiai komandai." -MCIERR_MUST_USE_SHAREABLE, "Įrenginio tvarkyklė jau naudojama. Norėdami naudoti bendrai, naudokite parametrą „shareable“ su kiekviena „open“ komanda." -MCIERR_MISSING_DEVICE_NAME, "Nurodytai komandai reikalingas alternatyvus vardas, failo, tvarkyklės ar įrenginio vardas. Prašome jį pateikti." -MCIERR_BAD_TIME_FORMAT, "Nurodyta reikšmė laiko formatui yra klaidinga. Skaitykite MCI dokumentaciją tinkamiems formatams rasti." -MCIERR_NO_CLOSING_QUOTE, "Parametro reikšmei trūksta reikalingų užveriančių dvigubų kabučių. Prašome jas pateikti." -MCIERR_DUPLICATE_FLAGS, "Parametras ar reikšmė buvo nurodyta du kartus. Nurodykite tik vieną kartą." -MCIERR_INVALID_FILE, "Nurodytas failas negali būti grojamas per nurodytą MCI įrenginį. Failas gali būti sugadintas arba netinkamo formato." -MCIERR_NULL_PARAMETER_BLOCK, "Nulinis parametrų blokas buvo perduotas į MCI." -MCIERR_UNNAMED_RESOURCE, "Negalima išsaugoti bevardžio failo. Nurodykite failo vardą." -MCIERR_NEW_REQUIRES_ALIAS, "Jūs privalote pateikti alternatyvų vardą, kai naudojate parametrą „new“." -MCIERR_NOTIFY_ON_AUTO_OPEN, "Negalima naudoti „notify“ žymos bito su automatiškai atvertais įrenginiais." -MCIERR_NO_ELEMENT_ALLOWED, "Negalima naudoti failo vardo su nurodytu įrenginiu." -MCIERR_NONAPPLICABLE_FUNCTION, "Negalima įvykdyti komandų nurodyta tvarka. Ištaisykite komandų seką ir mėginkite vėl." -MCIERR_ILLEGAL_FOR_AUTO_OPEN, "Negalima įvykdyti nurodytos komandos automatiškai atvertam įrenginiui. Palaukite, kol įrenginys bus užvertas ir tada mėginkite vėl." -MCIERR_FILENAME_REQUIRED, "Netinkamas failo vardas. Įsitikinkite, kad failo vardas yra neilgesnis kaip 8 simbolių, o po jų seka taškas ir plėtinys." -MCIERR_EXTRA_CHARACTERS, "Negalima nurodyti papildomų simbolių po eilutės apsuptos kabutėmis." -MCIERR_DEVICE_NOT_INSTALLED, "Nurodytas įrenginys neįdiegtas sistemoje. Naudokite tvarkyklių parinktį valdymo skydelyje įrenginiui įdiegti." -MCIERR_GET_CD, "Nepavyko kreiptis į nurodytą failą ar MCI įrenginį. Mėginkite keisti katalogus ar perkrauti kompiuterį." -MCIERR_SET_CD, "Nepavyko kreiptis į nurodytą failą ar MCI įrenginį, nes programa negali pakeisti katalogų." -MCIERR_SET_DRIVE, "Nepavyko kreiptis į nurodytą failą ar MCI įrenginį, nes programa negali pakeisti diskų." -MCIERR_DEVICE_LENGTH, "Nurodykite įrenginio ar tvarkyklės vardą, kuris yra trumpesnis nei 79 simboliai." -MCIERR_DEVICE_ORD_LENGTH, "Nurodykite įrenginio ar tvarkyklės vardą, kuris yra trumpesnis nei 69 simboliai." -MCIERR_NO_INTEGER, "Nurodytai komandai reikalingas sveikojo skaičiaus parametras. Prašome jį pateikti." -MCIERR_WAVE_OUTPUTSINUSE, "Visi wave įrenginiai, kurie gali groti dabartinio formato failus yra naudojami. Palaukite kol wave įrenginys bus laisvas ir mėginkite vėl." -MCIERR_WAVE_SETOUTPUTINUSE, "Negalima nustatyti dabartinio wave įrenginio grojimui, nes jis yra naudojamas. Palaukite kol wave įrenginys bus laisvas ir mėginkite vėl." -MCIERR_WAVE_INPUTSINUSE, "Visi wave įrenginiai, kurie gali įrašyti failus dabartiniu formatu yra naudojami. Palaukite kol wave įrenginys bus laisvas ir mėginkite vėl." -MCIERR_WAVE_SETINPUTINUSE, "Negalima nustatyti dabartinio wave įrenginio įrašymui, nes jis yra naudojamas. Palaukite kol wave įrenginys bus laisvas ir mėginkite vėl." -MCIERR_WAVE_OUTPUTUNSPECIFIED, "Bet kuris derantis wave tipo grojimo įrenginys gali būti naudojamas." -MCIERR_WAVE_INPUTUNSPECIFIED, "Bet kuris derantis wave tipo įrašymo įrenginys gali būti naudojamas." -MCIERR_WAVE_OUTPUTSUNSUITABLE, "Nėra įdiegtas joks wave įrenginys galintis groti dabartinio formato failus. Naudokite tvarkyklių parinktį wave įrenginiui įdiegti." -MCIERR_WAVE_SETOUTPUTUNSUITABLE, "Įrenginys per kurį mėginate groti negali atpažinti dabartinio failo formato." -MCIERR_WAVE_INPUTSUNSUITABLE, "Nėra įdiegtas joks wave įrenginys galintis įrašyti dabartinio formato failus. Naudokite tvarkyklių parinktį wave įrenginiui įdiegti." -MCIERR_WAVE_SETINPUTUNSUITABLE, "Įrenginys iš kurio mėginate įrašyti negali atpažinti dabartinio failo formato." -MCIERR_NO_WINDOW, "Nėra rodymo lango." -MCIERR_CREATEWINDOW, "Nepavyko sukurti ar naudoti lango." -MCIERR_FILE_READ, "Nepavyko skaityti nurodyto failo. Įsitikinkite, kad failas vis dar egzistuoja arba patikrinkite diską ar tinklo ryšį." -MCIERR_FILE_WRITE, "Nepavyko rašyti į nurodytą failą. Įsitikinkite, kad yra pakankamai laisvos vietos diske, ar vis dar prisijungę prie tinklo." -MCIERR_SEQ_DIV_INCOMPATIBLE, "„Dainos rodyklės“ ir SMPTE laiko formatai yra nesuderinami. Negalite jų naudoti kartu." -MCIERR_SEQ_NOMIDIPRESENT, "Sistemoje nėra įdiegtų MIDI įrenginių. Naudokite tvarkyklių parinktį valdymo skydelyje MIDI tvarkyklei įdiegti." -MCIERR_SEQ_PORT_INUSE, "Nurodytas MIDI prievadas jau naudojamas. Palaukite, kol jis bus laisvas ir mėginkite vėl." -MCIERR_SEQ_PORT_MAPNODEVICE, "Dabartinė MIDI Mapper konfigūracija kreipiasi į MIDI įrenginį, kuris nėra įdiegtas sistemoje. Naudokite MIDI Mapper nuostatą valdymo skydelyje konfigūracijai redaguoti." -MCIERR_SEQ_PORT_MISCERROR, "Įvyko klaida su nurodytu prievadu." -MCIERR_SEQ_PORT_NONEXISTENT, "Nurodytas MIDI įrenginys yra neįdiegtas sistemoje. Naudokite tvarkyklių nuostatą valdymo skydelyje MIDI įrenginiui įdiegti." -MCIERR_SEQ_PORTUNSPECIFIED, "Sistemoje nėra nurodytas dabartinis MIDI prievadas." -MCIERR_SEQ_TIMER, "Visi įvairialypės terpės laikmačiai yra naudojami kitų programų. Išeikite iš vienos tokios programos ir mėginkite vėl." - -END diff --git a/dlls/winmm/winmm_Nl.rc b/dlls/winmm/winmm_Nl.rc index ef8a7ada3f1..15f15353976 100644 --- a/dlls/winmm/winmm_Nl.rc +++ b/dlls/winmm/winmm_Nl.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - STRINGTABLE LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL BEGIN diff --git a/dlls/winmm/winmm_No.rc b/dlls/winmm/winmm_No.rc index 511e4b3841d..e2cbc30a194 100644 --- a/dlls/winmm/winmm_No.rc +++ b/dlls/winmm/winmm_No.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - STRINGTABLE LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL BEGIN diff --git a/dlls/winmm/winmm_Pl.rc b/dlls/winmm/winmm_Pl.rc index 5abf3f55765..c57c48b7d9a 100644 --- a/dlls/winmm/winmm_Pl.rc +++ b/dlls/winmm/winmm_Pl.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - STRINGTABLE LANGUAGE LANG_POLISH, SUBLANG_NEUTRAL BEGIN diff --git a/dlls/winmm/winmm_Pt.rc b/dlls/winmm/winmm_Pt.rc index 52adb076eeb..2da48d8d890 100644 --- a/dlls/winmm/winmm_Pt.rc +++ b/dlls/winmm/winmm_Pt.rc @@ -18,9 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - STRINGTABLE LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN BEGIN diff --git a/dlls/winmm/winmm_Ru.rc b/dlls/winmm/winmm_Ru.rc index 3392260c06f..9824cc5a271 100644 --- a/dlls/winmm/winmm_Ru.rc +++ b/dlls/winmm/winmm_Ru.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - STRINGTABLE LANGUAGE LANG_RUSSIAN, SUBLANG_NEUTRAL BEGIN diff --git a/dlls/winmm/winmm_Si.rc b/dlls/winmm/winmm_Si.rc index 918e7f11ab7..04e6e1bb0c3 100644 --- a/dlls/winmm/winmm_Si.rc +++ b/dlls/winmm/winmm_Si.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - #pragma code_page(65001) STRINGTABLE LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -129,3 +126,5 @@ MCIERR_SEQ_PORTUNSPECIFIED, "Zahtevana MIDI vrata niso nameščena." MCIERR_SEQ_TIMER, "Vsi većpredstavnostni števci so zasedeni. Zaprite enega od večpredstavnostih programov in poskusite znova." END + +#pragma code_page(default) diff --git a/dlls/winmm/winmm_Sk.rc b/dlls/winmm/winmm_Sk.rc index d9345eccbc3..80030c26cb8 100644 --- a/dlls/winmm/winmm_Sk.rc +++ b/dlls/winmm/winmm_Sk.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - STRINGTABLE LANGUAGE LANG_SLOVAK, SUBLANG_NEUTRAL BEGIN diff --git a/dlls/winmm/winmm_Tr.rc b/dlls/winmm/winmm_Tr.rc index 6c8a73ee188..36d5693a880 100644 --- a/dlls/winmm/winmm_Tr.rc +++ b/dlls/winmm/winmm_Tr.rc @@ -18,9 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "mmddk.h" - STRINGTABLE LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT BEGIN diff --git a/dlls/winmm/winmm_res.rc b/dlls/winmm/winmm_res.rc index 808220d8fba..a31146b8ab9 100644 --- a/dlls/winmm/winmm_res.rc +++ b/dlls/winmm/winmm_res.rc @@ -23,7 +23,30 @@ */ #include "windef.h" +#include "winbase.h" #include "mmddk.h" +#include "winnls.h" + +/* Add your language specific defines here */ +#include "winmm_Cs.rc" +#include "winmm_Da.rc" +#include "winmm_De.rc" +#include "winmm_En.rc" +#include "winmm_Es.rc" +#include "winmm_Fr.rc" +#include "winmm_It.rc" +#include "winmm_Ko.rc" +#include "winmm_Ja.rc" +#include "winmm_Nl.rc" +#include "winmm_No.rc" +#include "winmm_Pl.rc" +#include "winmm_Pt.rc" +#include "winmm_Ru.rc" +#include "winmm_Si.rc" +#include "winmm_Sk.rc" +#include "winmm_Tr.rc" + +/* do not add NLS specific stuff below that line */ LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL diff --git a/dlls/winnls.dll16/Makefile.in b/dlls/winnls.dll16/Makefile.in index 4e67a6dce2a..0552321bd43 100644 --- a/dlls/winnls.dll16/Makefile.in +++ b/dlls/winnls.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = winnls.dll16 IMPORTS = winnls32 kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,winnls32.dll +SPEC_SRCS = winnls.dll16.spec + C_SRCS = winnls.c @MAKE_DLL_RULES@ diff --git a/dlls/winspool.drv/Bg.rc b/dlls/winspool.drv/Bg.rc index eeeb2fccc4b..fb70b48b35c 100644 --- a/dlls/winspool.drv/Bg.rc +++ b/dlls/winspool.drv/Bg.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/Da.rc b/dlls/winspool.drv/Da.rc index adf4ff47ca5..2183cb7a9e0 100644 --- a/dlls/winspool.drv/Da.rc +++ b/dlls/winspool.drv/Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/De.rc b/dlls/winspool.drv/De.rc index 3490477fcc8..0bdb1de9379 100644 --- a/dlls/winspool.drv/De.rc +++ b/dlls/winspool.drv/De.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 @@ -37,7 +33,7 @@ END STRINGTABLE DISCARDABLE { - IDS_CAPTION "Lokaler Anschluß" - IDS_FILE_EXISTS "Die Ausgabedatei existiert schon. Drücken Sie OK zum Überschreiben." + IDS_CAPTION "Lokaler Anschluß" + IDS_FILE_EXISTS "Die Ausgabedatei existiert schon. Drücken Sie OK zum Überschreiben." IDS_CANNOT_OPEN "Die Ausgabedatei konnte nicht erzeugt werden." } diff --git a/dlls/winspool.drv/En.rc b/dlls/winspool.drv/En.rc index d6359d16da9..93d8de5c863 100644 --- a/dlls/winspool.drv/En.rc +++ b/dlls/winspool.drv/En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/Eo.rc b/dlls/winspool.drv/Eo.rc index 8b321cc1222..45a29085360 100644 --- a/dlls/winspool.drv/Eo.rc +++ b/dlls/winspool.drv/Eo.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/Es.rc b/dlls/winspool.drv/Es.rc index acb8d1b96a0..95f38cbccca 100644 --- a/dlls/winspool.drv/Es.rc +++ b/dlls/winspool.drv/Es.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/Fi.rc b/dlls/winspool.drv/Fi.rc index f4076fc8b44..27047651068 100644 --- a/dlls/winspool.drv/Fi.rc +++ b/dlls/winspool.drv/Fi.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/Fr.rc b/dlls/winspool.drv/Fr.rc index 40d9c235830..964bb40fd7c 100644 --- a/dlls/winspool.drv/Fr.rc +++ b/dlls/winspool.drv/Fr.rc @@ -18,11 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 @@ -30,7 +25,7 @@ STYLE DS_CONTEXTHELP | DS_MODALFRAME | DS_SETFONT | DS_SETFOREGROUND | WS_POPUPW CAPTION "Imprimer dans un fichier" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "&Fichier de sortie :", -1, 7, 13, 194, 13, WS_VISIBLE + LTEXT "&Fichier de sortie :", -1, 7, 13, 194, 13, WS_VISIBLE EDITTEXT EDITBOX, 6, 28, 174, 12, WS_VISIBLE | ES_AUTOHSCROLL DEFPUSHBUTTON "OK", IDOK, 199, 10, 40, 14, WS_VISIBLE PUSHBUTTON "Annuler", IDCANCEL, 199, 27, 40, 14, WS_VISIBLE @@ -39,6 +34,6 @@ END STRINGTABLE DISCARDABLE { IDS_CAPTION "Port local" - IDS_FILE_EXISTS "Le fichier de sortie existe déjà. Cliquez sur OK pour l'écraser." - IDS_CANNOT_OPEN "Impossible de créer le fichier de sortie." + IDS_FILE_EXISTS "Le fichier de sortie existe déjà. Cliquez sur OK pour l'écraser." + IDS_CANNOT_OPEN "Impossible de créer le fichier de sortie." } diff --git a/dlls/winspool.drv/It.rc b/dlls/winspool.drv/It.rc index aff05a4903d..6965c3eb779 100644 --- a/dlls/winspool.drv/It.rc +++ b/dlls/winspool.drv/It.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/Ko.rc b/dlls/winspool.drv/Ko.rc index 8c5a9c482e4..8cb7162dc44 100644 --- a/dlls/winspool.drv/Ko.rc +++ b/dlls/winspool.drv/Ko.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/Lt.rc b/dlls/winspool.drv/Lt.rc index 1c5b1e84a64..0f6b4eae3ae 100644 --- a/dlls/winspool.drv/Lt.rc +++ b/dlls/winspool.drv/Lt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - /* UTF-8 */ #pragma code_page(65001) @@ -39,6 +37,8 @@ END STRINGTABLE DISCARDABLE { IDS_CAPTION "Lokalus prievadas" - IDS_FILE_EXISTS "Išvesties failas jau egzistuoja. Norėdami failą keisti spauskite Gerai." + IDS_FILE_EXISTS "Išvesties failas jau egzistouja. Norėdami failą keisti spauskite Gerai." IDS_CANNOT_OPEN "Nepavyko sukurti išvesties failo." } + +#pragma code_page(default) diff --git a/dlls/winspool.drv/Makefile.in b/dlls/winspool.drv/Makefile.in index d0b64104301..7e670dbd018 100644 --- a/dlls/winspool.drv/Makefile.in +++ b/dlls/winspool.drv/Makefile.in @@ -12,28 +12,7 @@ C_SRCS = \ info.c \ wspool.c -RC_SRCS = \ - Bg.rc \ - Da.rc \ - De.rc \ - En.rc \ - Eo.rc \ - Es.rc \ - Fi.rc \ - Fr.rc \ - It.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc \ - winspool.rc +RC_SRCS = winspool.rc @MAKE_DLL_RULES@ diff --git a/dlls/winspool.drv/Nl.rc b/dlls/winspool.drv/Nl.rc index a785ff31ecf..a6a165c96e7 100644 --- a/dlls/winspool.drv/Nl.rc +++ b/dlls/winspool.drv/Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/No.rc b/dlls/winspool.drv/No.rc index 52482520134..ae226744981 100644 --- a/dlls/winspool.drv/No.rc +++ b/dlls/winspool.drv/No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/Pl.rc b/dlls/winspool.drv/Pl.rc index 966fd12a1dd..0dfee64730e 100644 --- a/dlls/winspool.drv/Pl.rc +++ b/dlls/winspool.drv/Pl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/Pt.rc b/dlls/winspool.drv/Pt.rc index 02b883a2e38..f00dc0c06b4 100644 --- a/dlls/winspool.drv/Pt.rc +++ b/dlls/winspool.drv/Pt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/Ru.rc b/dlls/winspool.drv/Ru.rc index 0a8481f95a0..6b0639c7135 100644 --- a/dlls/winspool.drv/Ru.rc +++ b/dlls/winspool.drv/Ru.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/Si.rc b/dlls/winspool.drv/Si.rc index 350047a4bd1..2efa67d14f0 100644 --- a/dlls/winspool.drv/Si.rc +++ b/dlls/winspool.drv/Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -41,3 +39,5 @@ STRINGTABLE DISCARDABLE IDS_FILE_EXISTS "Izhodna datoteka že obstaja. Za prepis kliknite gumb V redu." IDS_CANNOT_OPEN "Izhodne datoteke ni mogoče ustvariti." } + +#pragma code_page(default) diff --git a/dlls/winspool.drv/Sv.rc b/dlls/winspool.drv/Sv.rc index 6052eedd3bf..2bd3987bdb9 100644 --- a/dlls/winspool.drv/Sv.rc +++ b/dlls/winspool.drv/Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/Tr.rc b/dlls/winspool.drv/Tr.rc index 4a1b8ab45f8..b6d885a1a4d 100644 --- a/dlls/winspool.drv/Tr.rc +++ b/dlls/winspool.drv/Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT FILENAME_DIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 6, 18, 245, 47 diff --git a/dlls/winspool.drv/Zh.rc b/dlls/winspool.drv/Zh.rc index 08010c2c89b..4a265b3b6a6 100644 --- a/dlls/winspool.drv/Zh.rc +++ b/dlls/winspool.drv/Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wspool.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -62,3 +60,5 @@ STRINGTABLE DISCARDABLE IDS_FILE_EXISTS "輸出檔案已存在, 按'確定'覆蓋。" IDS_CANNOT_OPEN "不能開啟輸出檔案." } + +#pragma code_page(default) diff --git a/dlls/winspool.drv/winspool.rc b/dlls/winspool.drv/winspool.rc index 019f5ea1dd7..f8316185817 100644 --- a/dlls/winspool.drv/winspool.rc +++ b/dlls/winspool.drv/winspool.rc @@ -18,7 +18,11 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include "windef.h" +#include "winbase.h" +#include "winuser.h" #include "wspool.h" +#include "winver.h" #define WINE_FILENAME_STR "winspool.drv" #define WINE_FILEDESCRIPTION_STR "Wine core printer driver" @@ -34,3 +38,24 @@ #define WINE_PRODUCTVERSION_STR "5.1.2600.2180" #include "wine/wine_common_ver.rc" + +#include "Bg.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Eo.rc" +#include "Es.rc" +#include "Fi.rc" +#include "Fr.rc" +#include "It.rc" +#include "Ko.rc" +#include "Lt.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" diff --git a/dlls/winspool.drv/wspool.h b/dlls/winspool.drv/wspool.h index bb7922b794d..5b831dc1f31 100644 --- a/dlls/winspool.drv/wspool.h +++ b/dlls/winspool.drv/wspool.h @@ -19,9 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include - extern HINSTANCE WINSPOOL_hInstance; extern PRINTPROVIDOR * backend; diff --git a/dlls/wintab.dll16/Makefile.in b/dlls/wintab.dll16/Makefile.in index 7e742476e91..855116424fe 100644 --- a/dlls/wintab.dll16/Makefile.in +++ b/dlls/wintab.dll16/Makefile.in @@ -6,6 +6,8 @@ MODULE = wintab.dll16 IMPORTS = kernel32 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,wintab32.dll +SPEC_SRCS = wintab.dll16.spec + C_SRCS = wintab.c @MAKE_DLL_RULES@ diff --git a/dlls/wintrust/Makefile.in b/dlls/wintrust/Makefile.in index 6f2f4061b3c..f74717904b8 100644 --- a/dlls/wintrust/Makefile.in +++ b/dlls/wintrust/Makefile.in @@ -15,7 +15,7 @@ C_SRCS = \ wintrust_main.c RC_SRCS = \ - version.rc + version.rc @MAKE_DLL_RULES@ diff --git a/dlls/wintrust/crypt.c b/dlls/wintrust/crypt.c index d9fa5633562..e01a23006fa 100644 --- a/dlls/wintrust/crypt.c +++ b/dlls/wintrust/crypt.c @@ -1121,6 +1121,36 @@ static BOOL WINTRUST_GetSignedMsgFromCabFile(SIP_SUBJECTINFO *pSubjectInfo, TRACE("(%p %p %d %p %p)\n", pSubjectInfo, pdwEncodingType, dwIndex, pcbSignedDataMsg, pbSignedDataMsg); + /* + * FIXME: I just noticed that I am memorizing the initial file pointer + * offset and restoring it before reading in the rest of the header + * information in the cabinet. Perhaps that's correct -- that is, perhaps + * this API is supposed to support "streaming" cabinets which are embedded + * in other files, or cabinets which begin at file offsets other than zero. + * Otherwise, I should instead go to the absolute beginning of the file. + * (Either way, the semantics of wine's FDICopy require me to leave the + * file pointer where it is afterwards -- If Windows does not do so, we + * ought to duplicate the native behavior in the FDIIsCabinet API, not here. + * + * So, the answer lies in Windows; will native cabinet.dll recognize a + * cabinet "file" embedded in another file? Note that cabextract.c does + * support this, which implies that Microsoft's might. I haven't tried it + * yet so I don't know. ATM, most of wine's FDI cabinet routines (except + * this one) would not work in this way. To fix it, we could just make the + * various references to absolute file positions in the code relative to an + * initial "beginning" offset. Because the FDICopy API doesn't take a + * file-handle like this one, we would therein need to search through the + * file for the beginning of the cabinet (as we also do in cabextract.c). + * Note that this limits us to a maximum of one cabinet per. file: the first. + * + * So, in summary: either the code below is wrong, or the rest of fdi.c is + * wrong... I cannot imagine that both are correct ;) One of these flaws + * should be fixed after determining the behavior on Windows. We ought + * to check both FDIIsCabinet and FDICopy for the right behavior. + * + * -gmt + */ + /* get basic offset & size info */ base_offset = SetFilePointer(pSubjectInfo->hFile, 0L, NULL, SEEK_CUR); @@ -1132,7 +1162,7 @@ static BOOL WINTRUST_GetSignedMsgFromCabFile(SIP_SUBJECTINFO *pSubjectInfo, cabsize = SetFilePointer(pSubjectInfo->hFile, 0L, NULL, SEEK_CUR); if ((cabsize == -1) || (base_offset == -1) || - (SetFilePointer(pSubjectInfo->hFile, 0, NULL, SEEK_SET) == INVALID_SET_FILE_POINTER)) + (SetFilePointer(pSubjectInfo->hFile, base_offset, NULL, SEEK_SET) == INVALID_SET_FILE_POINTER)) { TRACE("seek error\n"); return FALSE; @@ -1237,7 +1267,6 @@ static BOOL WINTRUST_GetSignedMsgFromCabFile(SIP_SUBJECTINFO *pSubjectInfo, NULL) || dwRead != cert_size) { ERR("couldn't read cert\n"); - SetFilePointer(pSubjectInfo->hFile, base_offset, NULL, SEEK_SET); return FALSE; } /* The encoding of the files I've seen appears to be in ASN.1 @@ -1245,8 +1274,6 @@ static BOOL WINTRUST_GetSignedMsgFromCabFile(SIP_SUBJECTINFO *pSubjectInfo, * always is. */ *pdwEncodingType = X509_ASN_ENCODING | PKCS_7_ASN_ENCODING; - /* Restore base offset */ - SetFilePointer(pSubjectInfo->hFile, base_offset, NULL, SEEK_SET); return TRUE; } diff --git a/dlls/wintrust/tests/asn.c b/dlls/wintrust/tests/asn.c index a4f4fbb43d3..308fb8b997d 100644 --- a/dlls/wintrust/tests/asn.c +++ b/dlls/wintrust/tests/asn.c @@ -725,7 +725,6 @@ static void test_decodeCatNameValue(void) DWORD size; CAT_NAMEVALUE *value; - buf = NULL; ret = pCryptDecodeObjectEx(X509_ASN_ENCODING, CAT_NAMEVALUE_STRUCT, emptyCatNameValue, sizeof(emptyCatNameValue), CRYPT_DECODE_ALLOC_FLAG, NULL, &buf, &size); @@ -740,7 +739,6 @@ static void test_decodeCatNameValue(void) value->Value.cbData); LocalFree(buf); } - buf = NULL; ret = pCryptDecodeObjectEx(X509_ASN_ENCODING, CAT_NAMEVALUE_STRUCT, catNameValueWithTag, sizeof(catNameValueWithTag), CRYPT_DECODE_ALLOC_FLAG, NULL, &buf, &size); @@ -756,7 +754,6 @@ static void test_decodeCatNameValue(void) value->Value.cbData); LocalFree(buf); } - buf = NULL; ret = pCryptDecodeObjectEx(X509_ASN_ENCODING, CAT_NAMEVALUE_STRUCT, catNameValueWithFlags, sizeof(catNameValueWithFlags), CRYPT_DECODE_ALLOC_FLAG, NULL, &buf, &size); @@ -771,7 +768,6 @@ static void test_decodeCatNameValue(void) value->Value.cbData); LocalFree(buf); } - buf = NULL; ret = pCryptDecodeObjectEx(X509_ASN_ENCODING, CAT_NAMEVALUE_STRUCT, catNameValueWithValue, sizeof(catNameValueWithValue), CRYPT_DECODE_ALLOC_FLAG, NULL, &buf, &size); diff --git a/dlls/wintrust/wintrust.spec b/dlls/wintrust/wintrust.spec index 64c51e20375..602d4bd79cc 100644 --- a/dlls/wintrust/wintrust.spec +++ b/dlls/wintrust/wintrust.spec @@ -73,7 +73,6 @@ @ stub TrustFreeDecode @ stdcall TrustIsCertificateSelfSigned(ptr) @ stub TrustOpenStores -@ stdcall WTHelperCertCheckValidSignature(ptr) @ stub WTHelperCertFindIssuerCertificate @ stub WTHelperCertIsSelfSigned @ stub WTHelperCheckCertUsage diff --git a/dlls/wintrust/wintrust_main.c b/dlls/wintrust/wintrust_main.c index c61f6e0f2d6..0a40fbab6f8 100644 --- a/dlls/wintrust/wintrust_main.c +++ b/dlls/wintrust/wintrust_main.c @@ -1085,12 +1085,3 @@ BOOL WINAPI OpenPersonalTrustDBDialog(HWND hwnd) uiCertMgr.pszInitUsageOID = NULL; return CryptUIDlgCertMgr(&uiCertMgr); } - -/*********************************************************************** - * WTHelperCertCheckValidSignature - */ -HRESULT WINAPI WTHelperCertCheckValidSignature(CRYPT_PROVIDER_DATA *pProvData) -{ - FIXME("Stub\n"); - return S_OK; -} diff --git a/dlls/wldap32/Makefile.in b/dlls/wldap32/Makefile.in index 5b1776eb031..b7126b369d1 100644 --- a/dlls/wldap32/Makefile.in +++ b/dlls/wldap32/Makefile.in @@ -29,21 +29,7 @@ C_SRCS = \ search.c \ value.c -RC_SRCS = \ - wldap32_Da.rc \ - wldap32_De.rc \ - wldap32_En.rc \ - wldap32_Es.rc \ - wldap32_Fr.rc \ - wldap32_Ko.rc \ - wldap32_Lt.rc \ - wldap32_Nl.rc \ - wldap32_No.rc \ - wldap32_Pl.rc \ - wldap32_Pt.rc \ - wldap32_Ru.rc \ - wldap32_Sv.rc \ - wldap32_Tr.rc +RC_SRCS = wldap32.rc @MAKE_DLL_RULES@ diff --git a/dlls/wldap32/wldap32.rc b/dlls/wldap32/wldap32.rc new file mode 100644 index 00000000000..50f9562ca53 --- /dev/null +++ b/dlls/wldap32/wldap32.rc @@ -0,0 +1,37 @@ +/* + * Top level resource file for WLDAP32 + * + * Copyright 2005 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "winuser.h" + +#include "wldap32_Da.rc" +#include "wldap32_De.rc" +#include "wldap32_En.rc" +#include "wldap32_Es.rc" +#include "wldap32_Fr.rc" +#include "wldap32_Ko.rc" +#include "wldap32_Nl.rc" +#include "wldap32_No.rc" +#include "wldap32_Pl.rc" +#include "wldap32_Pt.rc" +#include "wldap32_Ru.rc" +#include "wldap32_Sv.rc" +#include "wldap32_Tr.rc" diff --git a/dlls/wldap32/wldap32_Da.rc b/dlls/wldap32/wldap32_Da.rc index 286a8e47624..2a48498feea 100644 --- a/dlls/wldap32/wldap32_Da.rc +++ b/dlls/wldap32/wldap32_Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/wldap32/wldap32_De.rc b/dlls/wldap32/wldap32_De.rc index 2886330cc56..86d0263a8e2 100644 --- a/dlls/wldap32/wldap32_De.rc +++ b/dlls/wldap32/wldap32_De.rc @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE @@ -29,25 +25,25 @@ STRINGTABLE DISCARDABLE 0 "Erfolgreich" 1 "Operationsfehler" 2 "Protokollfehler" - 3 "Zeitlimit überschritten" - 4 "Größenlimit überschritten" + 3 "Zeitlimit überschritten" + 4 "Größenlimit überschritten" 5 "Vergleich falsch" 6 "Vergleich wahr" - 7 "Authentifizierungsmethode nicht unterstützt" + 7 "Authentifizierungsmethode nicht unterstützt" 8 "Starke Authentifizierung erforderlich" 9 "Weiterleitung (v2)" 10 "Weiterleitung" - 11 "Verwaltungslimit überschritten" - 12 "Kritische Erweiterung nicht verfügbar" + 11 "Verwaltungslimit überschritten" + 12 "Kritische Erweiterung nicht verfügbar" 13 "Vertraulichkeit erforderlich" 14 "" 15 "" 16 "Attribut nicht vorhanden" 17 "Nicht definierter Typ" - 18 "Unzulässiger Vergleich" + 18 "Unzulässiger Vergleich" 19 "Restriktionsverletzung" 20 "Attribut oder Wert vorhanden" - 21 "Ungültige Syntax" + 21 "Ungültige Syntax" 22 "" 23 "" 24 "" @@ -60,7 +56,7 @@ STRINGTABLE DISCARDABLE 31 "" 32 "Objekt nicht vorhanden" 33 "Aliasproblem" - 34 "Ungültige DN Syntax" + 34 "Ungültige DN Syntax" 35 "Endknoten" 36 "Alias Dereferenzierungsproblem" 37 "" @@ -77,9 +73,9 @@ STRINGTABLE DISCARDABLE 48 "Fehlerhafte Authentifizierung" 49 "Anmeldeinformationen fehlerhaft" 50 "Nicht ausreichende Rechte" - 51 "Beschäftigt" - 52 "Nicht verfügbar" - 53 "Ausführung verweigert" + 51 "Beschäftigt" + 52 "Nicht verfügbar" + 53 "Ausführung verweigert" 54 "Schleife erkannt" 55 "" 56 "" @@ -92,11 +88,11 @@ STRINGTABLE DISCARDABLE 63 "" 64 "Bennenungsverletzung" 65 "Objektklasse verletzt" - 66 "Nicht erlaubt für Nicht-Endknoten" - 67 "Nicht erlaubt für RDN" + 66 "Nicht erlaubt für Nicht-Endknoten" + 67 "Nicht erlaubt für RDN" 68 "Bereits vorhanden" 69 "Keine Objektklassenmodifikationen" - 70 "Ergebnisse zu groß" + 70 "Ergebnisse zu groß" 71 "Mehrere DSAs betroffen" 72 "" 73 "" @@ -111,17 +107,17 @@ STRINGTABLE DISCARDABLE 82 "Lokaler Fehler" 83 "Kodierungsfehler" 84 "Dekodierungsfehler" - 85 "Zeitüberschreitung" + 85 "Zeitüberschreitung" 86 "Unbekannte Authentifizierung" 87 "Filterfehler" 88 "Benutzerabbruch" 89 "Parameterfehler" - 90 "Nicht genügend Speicher" + 90 "Nicht genügend Speicher" 91 "Kann nicht zum LDAP Server verbinden" - 92 "Die Operation wird durch dieses LDAP Protokoll nicht unterstützt" + 92 "Die Operation wird durch dieses LDAP Protokoll nicht unterstützt" 93 "Angegebenes Steuerobjekt wurde in der Meldung nicht gefunden" 94 "Keine Ergebnisse in der Meldung vorhanden" 95 "Weitere Ergebnisse gefunden" - 96 "Schleife während der Abarbeitung von Weiterleitungen" - 97 "Überschreitung der maximalen Anzahl von Weiterleitungen" + 96 "Schleife während der Abarbeitung von Weiterleitungen" + 97 "Überschreitung der maximalen Anzahl von Weiterleitungen" } diff --git a/dlls/wldap32/wldap32_En.rc b/dlls/wldap32/wldap32_En.rc index 1c2ca0fd520..4d213642aa8 100644 --- a/dlls/wldap32/wldap32_En.rc +++ b/dlls/wldap32/wldap32_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/wldap32/wldap32_Es.rc b/dlls/wldap32/wldap32_Es.rc index 959dd11157e..d0935b1f8e6 100644 --- a/dlls/wldap32/wldap32_Es.rc +++ b/dlls/wldap32/wldap32_Es.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/wldap32/wldap32_Fr.rc b/dlls/wldap32/wldap32_Fr.rc index fa3d4f807ff..8ea8d1c8bdd 100644 --- a/dlls/wldap32/wldap32_Fr.rc +++ b/dlls/wldap32/wldap32_Fr.rc @@ -2,7 +2,6 @@ * French resources for WLDAP32 * * Copyright 2005 Jonathan Ernst - * Copyright 2009 Frédéric Delanoy * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -19,36 +18,31 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { - 0 "Succès" - 1 "Erreur d'opération" + 0 "Succès" + 1 "Erreur d'opération" 2 "Erreur de protocole" - 3 "Limite de temps dépassée" - 4 "Limite de taille dépassée" - 5 "Comparaison fausse" - 6 "Comparaison vraie" - 7 "Méthode d'authentification non prise en charge" + 3 "Limite de temps dépassée" + 4 "Limite de taille dépassée" + 5 "Comparaison Fausse" + 6 "Comparaison Vraie" + 7 "Méthode d'authentification non supportée" 8 "Authentification forte requise" - 9 "Référant (v2)" - 10 "Référant" - 11 "Limite administrative dépassée" + 9 "Référant (v2)" + 10 "Référant" + 11 "Limite administrative dépassée" 12 "Extension critique indisponible" - 13 "Confidentialité requise" + 13 "Confidentialité requise" 14 "" 15 "" 16 "Attribut inconnu" - 17 "Type non défini" - 18 "Correspondance inappropriée" + 17 "Type indéfini" + 18 "Inappropriate Matching" 19 "Violation de contrainte" - 20 "Attribut ou valeur préexistant(e)" + 20 "Attribut ou valeur existant" 21 "Syntaxe invalide" 22 "" 23 "" @@ -61,10 +55,10 @@ STRINGTABLE DISCARDABLE 30 "" 31 "" 32 "Objet inconnu" - 33 "Problème d'alias" + 33 "Problème d'alias" 34 "Syntaxe DN invalide" 35 "Est une feuille" - 36 "Problème de déréférencement d'alias" + 36 "Problème de déréférencement d'alias" 37 "" 38 "" 39 "" @@ -76,30 +70,30 @@ STRINGTABLE DISCARDABLE 45 "" 46 "" 47 "" - 48 "Authentification inappropriée" - 49 "Autorisations invalides" + 48 "Authentification inappropriée" + 49 "Droits invalides" 50 "Droits insuffisants" - 51 "Occupé" + 51 "Occupé" 52 "Indisponible" - 53 "Pas disposé à s'exécuter" - 54 "Boucle détectée" + 53 "Ne souhaite pas s'exécuter" + 54 "Boucle détectée" 55 "" 56 "" 57 "" 58 "" 59 "" - 60 "Contrôle de tri manquant" - 61 "Erreur de plage d'index" + 60 "Contrôle de tri manquant" + 61 "Erreur d'intervalle d'index" 62 "" 63 "" 64 "Violation de nomenclature" 65 "Violation de classe d'objet" 66 "Interdit sur des non-feuilles" 67 "Interdit sur RDN" - 68 "Existe déjà" - 69 "Pas de modification de classe d'objet" - 70 "Résultats trop grands" - 71 "Affecte de multiples DSA" + 68 "Existe déjà" + 69 "Pas de Mods de classe d'objet" + 70 "Résultat trop grand" + 71 "Affecte de multiple DSAs" 72 "" 73 "" 74 "" @@ -112,18 +106,18 @@ STRINGTABLE DISCARDABLE 81 "Serveur indisponible" 82 "Erreur locale" 83 "Erreur d'encodage" - 84 "Erreur de décodage" - 85 "Délai d'attente dépassé" - 86 "Méthode d'authentification inconnue" - 87 "Erreur de filtrage" - 88 "Annulation par l'utilisateur" - 89 "Erreur de paramètre" - 90 "Mémoire insuffisante" + 84 "Erreur de décodage" + 85 "Délai d'attente dépassé" + 86 "Auth inconnue" + 87 "Erreur de filtre" + 88 "Annulation de l'utilisateur" + 89 "Erreur de paramètre" + 90 "Pas de mémoire" 91 "Impossible de se connecter au serveur LDAP" - 92 "Opération non supportée par cette version du protocole LDAP" - 93 "Le contrôle spécifié n'a pas été trouvé dans le message" - 94 "Aucun résultat dans le message" - 95 "Plus de résultats reçus" - 96 "Boucle lors du traitement des référants" - 97 "Limite du nombre de référants dépassée" + 92 "Opération non supportée par cette version du protocole LDAP" + 93 "Le contrôle spécifié n'a pas été trouvé dans le message" + 94 "Pas de résultat dans le message" + 95 "Plus de résultats retournés" + 96 "Boucle lors du traitement des référants" + 97 "Limite du nombre de référents dépassée" } diff --git a/dlls/wldap32/wldap32_Ko.rc b/dlls/wldap32/wldap32_Ko.rc index 9b9c9ce79b0..a5f01373322 100644 --- a/dlls/wldap32/wldap32_Ko.rc +++ b/dlls/wldap32/wldap32_Ko.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/wldap32/wldap32_Lt.rc b/dlls/wldap32/wldap32_Lt.rc deleted file mode 100644 index 41a8f599f56..00000000000 --- a/dlls/wldap32/wldap32_Lt.rc +++ /dev/null @@ -1,128 +0,0 @@ -/* - * Lithuanian resources for WLDAP32 - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "windef.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -{ - 0 "Sėkmė" - 1 "Operacijų klaida" - 2 "Protokolo klaida" - 3 "Viršytas skirtas laikas" - 4 "Viršyta dydžio riba" - 5 "Nelygu" - 6 "Lygu" - 7 "Tapatumo nustatymo metodas nerealizuotas" - 8 "Reikalingas stiprus tapatumo nustatymas" - 9 "Perdavimas (v2)" - 10 "Perdavimas" - 11 "Viršyta administravimo riba" - 12 "Nepasiekiamas kritinis plėtinys" - 13 "Reikalingas slaptumas" - 14 "" - 15 "" - 16 "Nėra tokio atributo" - 17 "Neapibrėžtas tipas" - 18 "Netinkamas atitikimas" - 19 "Ribojimų pažeidimas" - 20 "Atributas ar reikšmė egzistuoja" - 21 "Neteisinga sintaksė" - 22 "" - 23 "" - 24 "" - 25 "" - 26 "" - 27 "" - 28 "" - 29 "" - 30 "" - 31 "" - 32 "Nėra tokio objekto" - 33 "Alternatyviojo vardo problema" - 34 "Neteisinga DN sintaksė" - 35 "Objektas yra lapas" - 36 "Alternatyviojo vardo reikšmės nustatymo problema" - 37 "" - 38 "" - 39 "" - 40 "" - 41 "" - 42 "" - 43 "" - 44 "" - 45 "" - 46 "" - 47 "" - 48 "Netinkamas tapatumo nustatymas" - 49 "Neteisingi kredencialai" - 50 "Nepakanka teisių" - 51 "Užimtas" - 52 "Nepasiekiamas" - 53 "Nelinkęs aptarnauti" - 54 "Aptiktas ciklas" - 55 "" - 56 "" - 57 "" - 58 "" - 59 "" - 60 "Trūksta rikiavimo valdiklio" - 61 "Indekso rėžių klaida" - 62 "" - 63 "" - 64 "Įvardijimo pažeidimas" - 65 "Objekto klasės pažeidimas" - 66 "Leistina tik su lapu" - 67 "Neleistina su RDN" - 68 "Jau yra" - 69 "Negalimas objektų klasės modifikavimas" - 70 "Rezultatai per dideli" - 71 "Įtakoja daugelį DSA" - 72 "" - 73 "" - 74 "" - 75 "" - 76 "" - 77 "" - 78 "" - 79 "" - 80 "Kita" - 81 "Serveris nepasiekiamas" - 82 "Vietinė klaida" - 83 "Kodavimo klaida" - 84 "Dekodavimo klaida" - 85 "Baigėsi laikas" - 86 "Nežinomas tapatumo nustatymas" - 87 "Filtro klaida" - 88 "Nutraukta naudotojo" - 89 "Parametro klaida" - 90 "Trūksta atminties" - 91 "Nepavyko prisijungti prie LDAP serverio" - 92 "Operacija nepalaikoma šioje LDAP protokolo versijoje" - 93 "Nurodytas valdiklis nerastas pranešime" - 94 "Pranešime nėra rezultato" - 95 "Grąžinta daugiau rezultatų" - 96 "Aptiktas ciklas apdorojant perdavimus" - 97 "Viršyta perdavimo šuolių riba" -} diff --git a/dlls/wldap32/wldap32_Nl.rc b/dlls/wldap32/wldap32_Nl.rc index 58ac2efc531..3146f1733ea 100644 --- a/dlls/wldap32/wldap32_Nl.rc +++ b/dlls/wldap32/wldap32_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/wldap32/wldap32_No.rc b/dlls/wldap32/wldap32_No.rc index dc174f75406..de0a5935750 100644 --- a/dlls/wldap32/wldap32_No.rc +++ b/dlls/wldap32/wldap32_No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE DISCARDABLE diff --git a/dlls/wldap32/wldap32_Pl.rc b/dlls/wldap32/wldap32_Pl.rc index 41d0e31f57f..2e80b884058 100644 --- a/dlls/wldap32/wldap32_Pl.rc +++ b/dlls/wldap32/wldap32_Pl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/wldap32/wldap32_Pt.rc b/dlls/wldap32/wldap32_Pt.rc index 386c7a5b11f..172234c8722 100644 --- a/dlls/wldap32/wldap32_Pt.rc +++ b/dlls/wldap32/wldap32_Pt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/wldap32/wldap32_Ru.rc b/dlls/wldap32/wldap32_Ru.rc index 48ff24f26d4..7e6a5604a12 100644 --- a/dlls/wldap32/wldap32_Ru.rc +++ b/dlls/wldap32/wldap32_Ru.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/wldap32/wldap32_Sv.rc b/dlls/wldap32/wldap32_Sv.rc index f308ade3bd3..69137406d8b 100644 --- a/dlls/wldap32/wldap32_Sv.rc +++ b/dlls/wldap32/wldap32_Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/dlls/wldap32/wldap32_Tr.rc b/dlls/wldap32/wldap32_Tr.rc index 7f49abc1bb0..3f089e768f8 100644 --- a/dlls/wldap32/wldap32_Tr.rc +++ b/dlls/wldap32/wldap32_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/dlls/wmiutils/Makefile.in b/dlls/wmiutils/Makefile.in deleted file mode 100644 index 084be5fc185..00000000000 --- a/dlls/wmiutils/Makefile.in +++ /dev/null @@ -1,15 +0,0 @@ -TOPSRCDIR = @top_srcdir@ -TOPOBJDIR = ../.. -SRCDIR = @srcdir@ -VPATH = @srcdir@ -MODULE = wmiutils.dll -IMPORTS = oleaut32 ole32 advapi32 kernel32 - -C_SRCS = \ - main.c \ - regsvr.c \ - statuscode.c - -@MAKE_DLL_RULES@ - -@DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/wmiutils/main.c b/dlls/wmiutils/main.c deleted file mode 100644 index 6dda4bce6f1..00000000000 --- a/dlls/wmiutils/main.c +++ /dev/null @@ -1,147 +0,0 @@ -/* - * Copyright 2009 Hans Leidekker for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "config.h" -#include - -#define COBJMACROS - -#include "windef.h" -#include "winbase.h" -#include "winuser.h" -#include "objbase.h" -#include "wbemcli.h" - -#include "wine/debug.h" -#include "wmiutils_private.h" - -WINE_DEFAULT_DEBUG_CHANNEL(wmiutils); - -typedef HRESULT (*fnCreateInstance)( IUnknown *pUnkOuter, LPVOID *ppObj ); - -typedef struct -{ - const struct IClassFactoryVtbl *vtbl; - fnCreateInstance pfnCreateInstance; -} wmiutils_cf; - -static inline wmiutils_cf *impl_from_IClassFactory( IClassFactory *iface ) -{ - return (wmiutils_cf *)((char *)iface - FIELD_OFFSET( wmiutils_cf, vtbl )); -} - -static HRESULT WINAPI wmiutils_cf_QueryInterface( IClassFactory *iface, REFIID riid, LPVOID *ppobj ) -{ - if (IsEqualGUID(riid, &IID_IUnknown) || - IsEqualGUID(riid, &IID_IClassFactory)) - { - IClassFactory_AddRef( iface ); - *ppobj = iface; - return S_OK; - } - FIXME("interface %s not implemented\n", debugstr_guid(riid)); - return E_NOINTERFACE; -} - -static ULONG WINAPI wmiutils_cf_AddRef( IClassFactory *iface ) -{ - return 2; -} - -static ULONG WINAPI wmiutils_cf_Release( IClassFactory *iface ) -{ - return 1; -} - -static HRESULT WINAPI wmiutils_cf_CreateInstance( IClassFactory *iface, LPUNKNOWN pOuter, - REFIID riid, LPVOID *ppobj ) -{ - wmiutils_cf *This = impl_from_IClassFactory( iface ); - HRESULT r; - IUnknown *punk; - - TRACE("%p %s %p\n", pOuter, debugstr_guid(riid), ppobj); - - *ppobj = NULL; - - if (pOuter) - return CLASS_E_NOAGGREGATION; - - r = This->pfnCreateInstance( pOuter, (LPVOID *)&punk ); - if (FAILED(r)) - return r; - - r = IUnknown_QueryInterface( punk, riid, ppobj ); - if (FAILED(r)) - return r; - - IUnknown_Release( punk ); - return r; -} - -static HRESULT WINAPI wmiutils_cf_LockServer( IClassFactory *iface, BOOL dolock ) -{ - FIXME("(%p)->(%d)\n", iface, dolock); - return S_OK; -} - -static const struct IClassFactoryVtbl wmiutils_cf_vtbl = -{ - wmiutils_cf_QueryInterface, - wmiutils_cf_AddRef, - wmiutils_cf_Release, - wmiutils_cf_CreateInstance, - wmiutils_cf_LockServer -}; - -static wmiutils_cf status_code_cf = { &wmiutils_cf_vtbl, WbemStatusCodeText_create }; - -BOOL WINAPI DllMain( HINSTANCE hinst, DWORD reason, LPVOID lpv ) -{ - switch(reason) - { - case DLL_WINE_PREATTACH: - return FALSE; /* prefer native version */ - case DLL_PROCESS_ATTACH: - DisableThreadLibraryCalls( hinst ); - break; - case DLL_PROCESS_DETACH: - break; - } - return TRUE; -} - -HRESULT WINAPI DllGetClassObject( REFCLSID rclsid, REFIID iid, LPVOID *ppv ) -{ - IClassFactory *cf = NULL; - - TRACE("%s %s %p\n", debugstr_guid(rclsid), debugstr_guid(iid), ppv); - - if (IsEqualGUID( rclsid, &CLSID_WbemStatusCode )) - { - cf = (IClassFactory *)&status_code_cf.vtbl; - } - if (!cf) return CLASS_E_CLASSNOTAVAILABLE; - return IClassFactory_QueryInterface( cf, iid, ppv ); -} - -HRESULT WINAPI DllCanUnloadNow( void ) -{ - FIXME("\n"); - return S_FALSE; -} diff --git a/dlls/wmiutils/regsvr.c b/dlls/wmiutils/regsvr.c deleted file mode 100644 index bc5aeee19b9..00000000000 --- a/dlls/wmiutils/regsvr.c +++ /dev/null @@ -1,424 +0,0 @@ -/* - * self-registerable dll functions for wmiutils.dll - * - * Copyright (C) 2003 John K. Hohm - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - - -#include -#include - -#include "windef.h" -#include "winbase.h" -#include "winuser.h" -#include "winreg.h" -#include "winerror.h" -#include "objbase.h" -#include "wbemcli.h" - -#include "wine/debug.h" -#include "wine/unicode.h" - -WINE_DEFAULT_DEBUG_CHANNEL(wmiutils); - -/* - * Near the bottom of this file are the exported DllRegisterServer and - * DllUnregisterServer, which make all this worthwhile. - */ - -/*********************************************************************** - * interface for self-registering - */ -struct regsvr_interface -{ - IID const *iid; /* NULL for end of list */ - LPCSTR name; /* can be NULL to omit */ - IID const *base_iid; /* can be NULL to omit */ - int num_methods; /* can be <0 to omit */ - CLSID const *ps_clsid; /* can be NULL to omit */ - CLSID const *ps_clsid32; /* can be NULL to omit */ -}; - -static HRESULT register_interfaces(struct regsvr_interface const *list); -static HRESULT unregister_interfaces(struct regsvr_interface const *list); - -struct regsvr_coclass -{ - CLSID const *clsid; /* NULL for end of list */ - LPCSTR name; /* can be NULL to omit */ - LPCSTR ips; /* can be NULL to omit */ - LPCSTR ips32; /* can be NULL to omit */ - LPCSTR ips32_tmodel; /* can be NULL to omit */ - LPCSTR clsid_str; /* can be NULL to omit */ - LPCSTR progid; /* can be NULL to omit */ -}; - -static HRESULT register_coclasses(struct regsvr_coclass const *list); -static HRESULT unregister_coclasses(struct regsvr_coclass const *list); - -/*********************************************************************** - * static string constants - */ -static WCHAR const interface_keyname[10] = { - 'I', 'n', 't', 'e', 'r', 'f', 'a', 'c', 'e', 0 }; -static WCHAR const base_ifa_keyname[14] = { - 'B', 'a', 's', 'e', 'I', 'n', 't', 'e', 'r', 'f', 'a', 'c', - 'e', 0 }; -static WCHAR const num_methods_keyname[11] = { - 'N', 'u', 'm', 'M', 'e', 't', 'h', 'o', 'd', 's', 0 }; -static WCHAR const ps_clsid_keyname[15] = { - 'P', 'r', 'o', 'x', 'y', 'S', 't', 'u', 'b', 'C', 'l', 's', - 'i', 'd', 0 }; -static WCHAR const ps_clsid32_keyname[17] = { - 'P', 'r', 'o', 'x', 'y', 'S', 't', 'u', 'b', 'C', 'l', 's', - 'i', 'd', '3', '2', 0 }; -static WCHAR const clsid_keyname[6] = { - 'C', 'L', 'S', 'I', 'D', 0 }; -static WCHAR const ips_keyname[13] = { - 'I', 'n', 'P', 'r', 'o', 'c', 'S', 'e', 'r', 'v', 'e', 'r', - 0 }; -static WCHAR const ips32_keyname[15] = { - 'I', 'n', 'P', 'r', 'o', 'c', 'S', 'e', 'r', 'v', 'e', 'r', - '3', '2', 0 }; -static WCHAR const progid_keyname[7] = { - 'P', 'r', 'o', 'g', 'I', 'D', 0 }; -static char const tmodel_valuename[] = "ThreadingModel"; - -/*********************************************************************** - * static helper functions - */ -static LONG register_key_guid(HKEY base, WCHAR const *name, GUID const *guid); -static LONG register_key_defvalueW(HKEY base, WCHAR const *name, - WCHAR const *value); -static LONG register_key_defvalueA(HKEY base, WCHAR const *name, - char const *value); - -/*********************************************************************** - * register_interfaces - */ -static HRESULT register_interfaces(struct regsvr_interface const *list) -{ - LONG res = ERROR_SUCCESS; - HKEY interface_key; - - res = RegCreateKeyExW(HKEY_CLASSES_ROOT, interface_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &interface_key, NULL); - if (res != ERROR_SUCCESS) goto error_return; - - for (; res == ERROR_SUCCESS && list->iid; ++list) { - WCHAR buf[39]; - HKEY iid_key; - - StringFromGUID2(list->iid, buf, 39); - res = RegCreateKeyExW(interface_key, buf, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &iid_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_interface_key; - - if (list->name) { - res = RegSetValueExA(iid_key, NULL, 0, REG_SZ, - (CONST BYTE*)(list->name), - strlen(list->name) + 1); - if (res != ERROR_SUCCESS) goto error_close_iid_key; - } - - if (list->base_iid) { - res = register_key_guid(iid_key, base_ifa_keyname, list->base_iid); - if (res != ERROR_SUCCESS) goto error_close_iid_key; - } - - if (0 <= list->num_methods) { - static WCHAR const fmt[3] = { '%', 'd', 0 }; - HKEY key; - - res = RegCreateKeyExW(iid_key, num_methods_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &key, NULL); - if (res != ERROR_SUCCESS) goto error_close_iid_key; - - sprintfW(buf, fmt, list->num_methods); - res = RegSetValueExW(key, NULL, 0, REG_SZ, - (CONST BYTE*)buf, - (lstrlenW(buf) + 1) * sizeof(WCHAR)); - RegCloseKey(key); - - if (res != ERROR_SUCCESS) goto error_close_iid_key; - } - - if (list->ps_clsid) { - res = register_key_guid(iid_key, ps_clsid_keyname, list->ps_clsid); - if (res != ERROR_SUCCESS) goto error_close_iid_key; - } - - if (list->ps_clsid32) { - res = register_key_guid(iid_key, ps_clsid32_keyname, list->ps_clsid32); - if (res != ERROR_SUCCESS) goto error_close_iid_key; - } - - error_close_iid_key: - RegCloseKey(iid_key); - } - -error_close_interface_key: - RegCloseKey(interface_key); -error_return: - return res != ERROR_SUCCESS ? HRESULT_FROM_WIN32(res) : S_OK; -} - -/*********************************************************************** - * unregister_interfaces - */ -static HRESULT unregister_interfaces(struct regsvr_interface const *list) -{ - LONG res = ERROR_SUCCESS; - HKEY interface_key; - - res = RegOpenKeyExW(HKEY_CLASSES_ROOT, interface_keyname, 0, - KEY_READ | KEY_WRITE, &interface_key); - if (res == ERROR_FILE_NOT_FOUND) return S_OK; - if (res != ERROR_SUCCESS) goto error_return; - - for (; res == ERROR_SUCCESS && list->iid; ++list) { - WCHAR buf[39]; - - StringFromGUID2(list->iid, buf, 39); - res = RegDeleteTreeW(interface_key, buf); - if (res == ERROR_FILE_NOT_FOUND) res = ERROR_SUCCESS; - } - - RegCloseKey(interface_key); -error_return: - return res != ERROR_SUCCESS ? HRESULT_FROM_WIN32(res) : S_OK; -} - -/*********************************************************************** - * register_coclasses - */ -static HRESULT register_coclasses(struct regsvr_coclass const *list) -{ - LONG res = ERROR_SUCCESS; - HKEY coclass_key; - - res = RegCreateKeyExW(HKEY_CLASSES_ROOT, clsid_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &coclass_key, NULL); - if (res != ERROR_SUCCESS) goto error_return; - - for (; res == ERROR_SUCCESS && list->clsid; ++list) { - WCHAR buf[39]; - HKEY clsid_key; - - StringFromGUID2(list->clsid, buf, 39); - res = RegCreateKeyExW(coclass_key, buf, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &clsid_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - - if (list->name) { - res = RegSetValueExA(clsid_key, NULL, 0, REG_SZ, - (CONST BYTE*)(list->name), - strlen(list->name) + 1); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->ips) { - res = register_key_defvalueA(clsid_key, ips_keyname, list->ips); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->ips32) { - HKEY ips32_key; - - res = RegCreateKeyExW(clsid_key, ips32_keyname, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, - &ips32_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - - res = RegSetValueExA(ips32_key, NULL, 0, REG_SZ, - (CONST BYTE*)list->ips32, - lstrlenA(list->ips32) + 1); - if (res == ERROR_SUCCESS && list->ips32_tmodel) - res = RegSetValueExA(ips32_key, tmodel_valuename, 0, REG_SZ, - (CONST BYTE*)list->ips32_tmodel, - strlen(list->ips32_tmodel) + 1); - RegCloseKey(ips32_key); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->clsid_str) { - res = register_key_defvalueA(clsid_key, clsid_keyname, - list->clsid_str); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - if (list->progid) { - HKEY progid_key; - - res = register_key_defvalueA(clsid_key, progid_keyname, - list->progid); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - - res = RegCreateKeyExA(HKEY_CLASSES_ROOT, list->progid, 0, - NULL, 0, KEY_READ | KEY_WRITE, NULL, - &progid_key, NULL); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - - res = register_key_defvalueW(progid_key, clsid_keyname, buf); - RegCloseKey(progid_key); - if (res != ERROR_SUCCESS) goto error_close_clsid_key; - } - - error_close_clsid_key: - RegCloseKey(clsid_key); - } - -error_close_coclass_key: - RegCloseKey(coclass_key); -error_return: - return res != ERROR_SUCCESS ? HRESULT_FROM_WIN32(res) : S_OK; -} - -/*********************************************************************** - * unregister_coclasses - */ -static HRESULT unregister_coclasses(struct regsvr_coclass const *list) -{ - LONG res = ERROR_SUCCESS; - HKEY coclass_key; - - res = RegOpenKeyExW(HKEY_CLASSES_ROOT, clsid_keyname, 0, - KEY_READ | KEY_WRITE, &coclass_key); - if (res == ERROR_FILE_NOT_FOUND) return S_OK; - if (res != ERROR_SUCCESS) goto error_return; - - for (; res == ERROR_SUCCESS && list->clsid; ++list) { - WCHAR buf[39]; - - StringFromGUID2(list->clsid, buf, 39); - res = RegDeleteTreeW(coclass_key, buf); - if (res == ERROR_FILE_NOT_FOUND) res = ERROR_SUCCESS; - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - - if (list->progid) { - res = RegDeleteTreeA(HKEY_CLASSES_ROOT, list->progid); - if (res == ERROR_FILE_NOT_FOUND) res = ERROR_SUCCESS; - if (res != ERROR_SUCCESS) goto error_close_coclass_key; - } - } - -error_close_coclass_key: - RegCloseKey(coclass_key); -error_return: - return res != ERROR_SUCCESS ? HRESULT_FROM_WIN32(res) : S_OK; -} - -/*********************************************************************** - * regsvr_key_guid - */ -static LONG register_key_guid(HKEY base, WCHAR const *name, GUID const *guid) -{ - WCHAR buf[39]; - - StringFromGUID2(guid, buf, 39); - return register_key_defvalueW(base, name, buf); -} - -/*********************************************************************** - * regsvr_key_defvalueW - */ -static LONG register_key_defvalueW( - HKEY base, - WCHAR const *name, - WCHAR const *value) -{ - LONG res; - HKEY key; - - res = RegCreateKeyExW(base, name, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &key, NULL); - if (res != ERROR_SUCCESS) return res; - res = RegSetValueExW(key, NULL, 0, REG_SZ, (CONST BYTE*)value, - (lstrlenW(value) + 1) * sizeof(WCHAR)); - RegCloseKey(key); - return res; -} - -/*********************************************************************** - * regsvr_key_defvalueA - */ -static LONG register_key_defvalueA( - HKEY base, - WCHAR const *name, - char const *value) -{ - LONG res; - HKEY key; - - res = RegCreateKeyExW(base, name, 0, NULL, 0, - KEY_READ | KEY_WRITE, NULL, &key, NULL); - if (res != ERROR_SUCCESS) return res; - res = RegSetValueExA(key, NULL, 0, REG_SZ, (CONST BYTE*)value, - lstrlenA(value) + 1); - RegCloseKey(key); - return res; -} - -/*********************************************************************** - * coclass list - */ -static struct regsvr_coclass const coclass_list[] = { - { &CLSID_WbemStatusCode, - "CLSID_WbemStatusCode", - NULL, - "wmiutils.dll", - "Both" - }, - { NULL } /* list terminator */ -}; - -/*********************************************************************** - * interface list - */ -static struct regsvr_interface const interface_list[] = { - { NULL } /* list terminator */ -}; - -/*********************************************************************** - * DllRegisterServer (INETCOMM.@) - */ -HRESULT WINAPI DllRegisterServer(void) -{ - HRESULT hr; - - TRACE("\n"); - - hr = register_coclasses(coclass_list); - if (SUCCEEDED(hr)) - hr = register_interfaces(interface_list); - return hr; -} - -/*********************************************************************** - * DllUnregisterServer (INETCOMM.@) - */ -HRESULT WINAPI DllUnregisterServer(void) -{ - HRESULT hr; - - TRACE("\n"); - - hr = unregister_coclasses(coclass_list); - if (SUCCEEDED(hr)) - hr = unregister_interfaces(interface_list); - return hr; -} diff --git a/dlls/wmiutils/statuscode.c b/dlls/wmiutils/statuscode.c deleted file mode 100644 index dfa3872837a..00000000000 --- a/dlls/wmiutils/statuscode.c +++ /dev/null @@ -1,153 +0,0 @@ -/* - * Copyright 2009 Hans Leidekker for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#define COBJMACROS - -#include "config.h" -#include -#include - -#include "windef.h" -#include "winbase.h" -#include "winuser.h" -#include "initguid.h" -#include "ole2.h" -#include "wbemcli.h" - -#include "wine/debug.h" -#include "wine/unicode.h" -#include "wmiutils_private.h" - -WINE_DEFAULT_DEBUG_CHANNEL(wmiutils); - -typedef struct status_code -{ - const IWbemStatusCodeTextVtbl *vtbl; - LONG refs; -} status_code; - -static inline status_code *impl_from_IWbemStatusCodeText( IWbemStatusCodeText *iface ) -{ - return (status_code *)((char *)iface - FIELD_OFFSET( status_code, vtbl )); -} - -static ULONG WINAPI status_code_AddRef( - IWbemStatusCodeText *iface ) -{ - status_code *status_code = impl_from_IWbemStatusCodeText( iface ); - return InterlockedIncrement( &status_code->refs ); -} - -static ULONG WINAPI status_code_Release( - IWbemStatusCodeText *iface ) -{ - status_code *status_code = impl_from_IWbemStatusCodeText( iface ); - LONG refs = InterlockedDecrement( &status_code->refs ); - if (!refs) - { - TRACE("destroying %p\n", status_code); - HeapFree( GetProcessHeap(), 0, status_code ); - } - return refs; -} - -static HRESULT WINAPI status_code_QueryInterface( - IWbemStatusCodeText *iface, - REFIID riid, - void **ppvObject ) -{ - status_code *This = impl_from_IWbemStatusCodeText( iface ); - - TRACE("%p %s %p\n", This, debugstr_guid( riid ), ppvObject ); - - if ( IsEqualGUID( riid, &IID_IWbemStatusCodeText ) || - IsEqualGUID( riid, &IID_IUnknown ) ) - { - *ppvObject = iface; - } - else - { - FIXME("interface %s not implemented\n", debugstr_guid(riid)); - return E_NOINTERFACE; - } - IWbemStatusCodeText_AddRef( iface ); - return S_OK; -} - -static HRESULT WINAPI status_code_GetErrorCodeText( - IWbemStatusCodeText *iface, - HRESULT res, - LCID lcid, - LONG flags, - BSTR *text ) -{ - static const WCHAR fmt[] = - {'E','r','r','o','r',' ','c','o','d','e',':',' ','0','x','%','0','8','x',0}; - WCHAR msg[32]; - - FIXME("%p, 0x%08x, 0x%04x, 0x%08x, %p\n", iface, res, lcid, flags, text); - - sprintfW(msg, fmt, res); - *text = SysAllocString(msg); - return WBEM_S_NO_ERROR; -} - -static HRESULT WINAPI status_code_GetFacilityCodeText( - IWbemStatusCodeText *iface, - HRESULT res, - LCID lcid, - LONG flags, - BSTR *text ) -{ - static const WCHAR fmt[] = - {'F','a','c','i','l','i','t','y',' ','c','o','d','e',':',' ','0','x','%','0','8','x',0}; - WCHAR msg[32]; - - FIXME("%p, 0x%08x, 0x%04x, 0x%08x, %p\n", iface, res, lcid, flags, text); - - sprintfW(msg, fmt, res); - *text = SysAllocString(msg); - return WBEM_S_NO_ERROR; -} - -static const struct IWbemStatusCodeTextVtbl status_code_vtbl = -{ - status_code_QueryInterface, - status_code_AddRef, - status_code_Release, - status_code_GetErrorCodeText, - status_code_GetFacilityCodeText -}; - -HRESULT WbemStatusCodeText_create( IUnknown *pUnkOuter, LPVOID *ppObj ) -{ - status_code *sc; - - TRACE("(%p,%p)\n", pUnkOuter, ppObj); - - sc = HeapAlloc( GetProcessHeap(), 0, sizeof(*sc) ); - if (!sc) return E_OUTOFMEMORY; - - sc->vtbl = &status_code_vtbl; - sc->refs = 1; - - *ppObj = &sc->vtbl; - - TRACE("returning iface %p\n", *ppObj); - return S_OK; -} diff --git a/dlls/wmiutils/wmiutils.spec b/dlls/wmiutils/wmiutils.spec deleted file mode 100644 index b16365d0c9f..00000000000 --- a/dlls/wmiutils/wmiutils.spec +++ /dev/null @@ -1,4 +0,0 @@ -@ stdcall -private DllCanUnloadNow() -@ stdcall -private DllGetClassObject(ptr ptr ptr) -@ stdcall -private DllRegisterServer() -@ stdcall -private DllUnregisterServer() diff --git a/dlls/wmiutils/wmiutils_private.h b/dlls/wmiutils/wmiutils_private.h deleted file mode 100644 index 23082ce1b0f..00000000000 --- a/dlls/wmiutils/wmiutils_private.h +++ /dev/null @@ -1,19 +0,0 @@ -/* - * Copyright 2009 Hans Leidekker for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -HRESULT WbemStatusCodeText_create(IUnknown *, LPVOID *); diff --git a/dlls/ws2_32/socket.c b/dlls/ws2_32/socket.c index 2eb58377735..55162602ff7 100644 --- a/dlls/ws2_32/socket.c +++ b/dlls/ws2_32/socket.c @@ -2406,11 +2406,25 @@ int WINAPI WS_ioctlsocket(SOCKET s, LONG cmd, WS_u_long *argp) SetLastError(WSAEINVAL); return SOCKET_ERROR; } - if (*argp) - _enable_event(SOCKET2HANDLE(s), 0, FD_WINE_NONBLOCKING, 0); - else - _enable_event(SOCKET2HANDLE(s), 0, 0, FD_WINE_NONBLOCKING); - return 0; + fd = get_sock_fd( s, 0, NULL ); + if (fd != -1) + { + int ret; + if (*argp) + { + _enable_event(SOCKET2HANDLE(s), 0, FD_WINE_NONBLOCKING, 0); + ret = fcntl( fd, F_SETFL, O_NONBLOCK ); + } + else + { + _enable_event(SOCKET2HANDLE(s), 0, 0, FD_WINE_NONBLOCKING); + ret = fcntl( fd, F_SETFL, 0 ); + } + release_sock_fd( s, fd ); + if (!ret) return 0; + SetLastError((errno == EBADF) ? WSAENOTSOCK : wsaErrno()); + } + return SOCKET_ERROR; case WS_SIOCATMARK: newcmd=SIOCATMARK; @@ -4395,12 +4409,6 @@ INT WINAPI WSARecvFrom( SOCKET s, LPWSABUF lpBuffers, DWORD dwBufferCount, wsa->first_iovec = 0; for (i = 0; i < dwBufferCount; i++) { - /* check buffer first to trigger write watches */ - if (IsBadWritePtr( lpBuffers[i].buf, lpBuffers[i].len )) - { - err = WSAEFAULT; - goto error; - } wsa->iovec[i].iov_base = lpBuffers[i].buf; wsa->iovec[i].iov_len = lpBuffers[i].len; } @@ -4919,13 +4927,13 @@ INT WINAPI WSAAddressToStringA( LPSOCKADDR sockaddr, DWORD len, TRACE( "(%p, %d, %p, %p, %p)\n", sockaddr, len, info, string, lenstr ); - if (!sockaddr) return SOCKET_ERROR; + if (!sockaddr || len < sizeof(SOCKADDR_IN)) return SOCKET_ERROR; if (!string || !lenstr) return SOCKET_ERROR; - switch(sockaddr->sa_family) + /* sin_family is guaranteed to be the first u_short */ + switch(((SOCKADDR_IN *)sockaddr)->sin_family) { case WS_AF_INET: - if (len < sizeof(SOCKADDR_IN)) return SOCKET_ERROR; sprintf( buffer, "%u.%u.%u.%u:%u", (unsigned int)(ntohl( ((SOCKADDR_IN *)sockaddr)->sin_addr.WS_s_addr ) >> 24 & 0xff), (unsigned int)(ntohl( ((SOCKADDR_IN *)sockaddr)->sin_addr.WS_s_addr ) >> 16 & 0xff), @@ -4941,7 +4949,6 @@ INT WINAPI WSAAddressToStringA( LPSOCKADDR sockaddr, DWORD len, { struct WS_sockaddr_in6 *sockaddr6 = (LPSOCKADDR_IN6) sockaddr; - if (len < sizeof(SOCKADDR_IN6)) return SOCKET_ERROR; if (!WS_inet_ntop(WS_AF_INET6, &sockaddr6->sin6_addr, buffer, sizeof(buffer))) { WSASetLastError(WSAEINVAL); @@ -4987,29 +4994,42 @@ INT WINAPI WSAAddressToStringA( LPSOCKADDR sockaddr, DWORD len, * * NOTES * The 'info' parameter is ignored. + * + * BUGS + * Only supports AF_INET addresses. */ INT WINAPI WSAAddressToStringW( LPSOCKADDR sockaddr, DWORD len, LPWSAPROTOCOL_INFOW info, LPWSTR string, LPDWORD lenstr ) { - INT ret; DWORD size; - WCHAR buffer[54]; /* 32 digits + 7':' + '[' + '%" + 5 digits + ']:' + 5 digits + '\0' */ - CHAR bufAddr[54]; + WCHAR buffer[22]; /* 12 digits + 3 dots + ':' + 5 digits + '\0' */ + static const WCHAR format[] = { '%','u','.','%','u','.','%','u','.','%','u',':','%','u',0 }; + WCHAR *p; - TRACE( "(%p, %d, %p, %p, %p)\n", sockaddr, len, info, string, lenstr ); + TRACE( "(%p, %x, %p, %p, %p)\n", sockaddr, len, info, string, lenstr ); + + if (!sockaddr || len < sizeof(SOCKADDR_IN)) return SOCKET_ERROR; + if (!string || !lenstr) return SOCKET_ERROR; - size = *lenstr; - ret = WSAAddressToStringA(sockaddr, len, NULL, bufAddr, &size); + /* sin_family is guaranteed to be the first u_short */ + if (((SOCKADDR_IN *)sockaddr)->sin_family != AF_INET) return SOCKET_ERROR; - if (ret) return ret; + sprintfW( buffer, format, + (unsigned int)(ntohl( ((SOCKADDR_IN *)sockaddr)->sin_addr.WS_s_addr ) >> 24 & 0xff), + (unsigned int)(ntohl( ((SOCKADDR_IN *)sockaddr)->sin_addr.WS_s_addr ) >> 16 & 0xff), + (unsigned int)(ntohl( ((SOCKADDR_IN *)sockaddr)->sin_addr.WS_s_addr ) >> 8 & 0xff), + (unsigned int)(ntohl( ((SOCKADDR_IN *)sockaddr)->sin_addr.WS_s_addr ) & 0xff), + ntohs( ((SOCKADDR_IN *)sockaddr)->sin_port ) ); - MultiByteToWideChar( CP_ACP, 0, bufAddr, size, buffer, sizeof( buffer )/sizeof(WCHAR)); + p = strchrW( buffer, ':' ); + if (!((SOCKADDR_IN *)sockaddr)->sin_port) *p = 0; + + size = strlenW( buffer ) + 1; if (*lenstr < size) { *lenstr = size; - WSASetLastError(WSAEFAULT); return SOCKET_ERROR; } diff --git a/dlls/ws2_32/tests/sock.c b/dlls/ws2_32/tests/sock.c index b1b85fe350a..c90f391fe25 100644 --- a/dlls/ws2_32/tests/sock.c +++ b/dlls/ws2_32/tests/sock.c @@ -1474,7 +1474,6 @@ end: static void test_WSAAddressToStringW(void) { - SOCKET v6 = INVALID_SOCKET; INT ret; DWORD len; int GLE; @@ -1487,19 +1486,6 @@ static void test_WSAAddressToStringW(void) WCHAR expect4[] = { '2','5','5','.','2','5','5','.','2','5','5','.','2','5','5', ':', '6', '5', '5', '3', '5', 0 }; - SOCKADDR_IN6 sockaddr6; - WCHAR address6[54]; /* 32 digits + 7':' + '[' + '%" + 5 digits + ']:' + 5 digits + '\0' */ - - CHAR addr6_1[] = {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01}; - CHAR addr6_2[] = {0x20,0xab,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01}; - CHAR addr6_3[] = {0x20,0xab,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x01}; - - WCHAR expect6_1[] = {':',':','1',0}; - WCHAR expect6_2[] = {'2','0','a','b',':',':','1',0}; - WCHAR expect6_3[] = {'[','2','0','a','b',':',':','2','0','0','1',']',':','3','3','2','7','4',0}; - WCHAR expect6_3_2[] = {'[','2','0','a','b',':',':','2','0','0','1','%','4','6','6','0',']',':','3','3','2','7','4',0}; - WCHAR expect6_3_3[] = {'2','0','a','b',':',':','2','0','0','1','%','6','5','5','3','4',0}; - len = 0; sockaddr.sin_family = AF_INET; @@ -1556,94 +1542,7 @@ static void test_WSAAddressToStringW(void) ok( !ret, "WSAAddressToStringW() failed unexpectedly: %d\n", WSAGetLastError() ); ok( !lstrcmpW( address, expect4 ), "Expected different address string\n" ); - ok( len == sizeof( expect4 )/sizeof( WCHAR ), "Got %d\n", len); - - /*check to see it IPv6 is available */ - v6 = socket(AF_INET6, SOCK_STREAM, IPPROTO_TCP); - if (v6 == INVALID_SOCKET) { - skip("Could not create IPv6 socket (LastError: %d; %d expected if IPv6 not available).\n", - WSAGetLastError(), WSAEAFNOSUPPORT); - goto end; - } - - /* Test a short IPv6 address */ - len = sizeof(address6)/sizeof(WCHAR); - - sockaddr6.sin6_family = AF_INET6; - sockaddr6.sin6_port = 0x0000; - sockaddr6.sin6_scope_id = 0; - memcpy (sockaddr6.sin6_addr.s6_addr, addr6_1, sizeof(addr6_1)); - - ret = WSAAddressToStringW( (SOCKADDR*)&sockaddr6, sizeof(sockaddr6), NULL, address6, &len ); - ok( !ret, "WSAAddressToStringW() failed unexpectedly: %d\n", WSAGetLastError() ); - ok( !lstrcmpW( address6, expect6_1 ), "Wrong string returned\n" ); - ok( len == sizeof(expect6_1)/sizeof(WCHAR), "Got %d\n", len); - - /* Test a longer IPv6 address */ - len = sizeof(address6)/sizeof(WCHAR); - - sockaddr6.sin6_family = AF_INET6; - sockaddr6.sin6_port = 0x0000; - sockaddr6.sin6_scope_id = 0; - memcpy (sockaddr6.sin6_addr.s6_addr, addr6_2, sizeof(addr6_2)); - - ret = WSAAddressToStringW( (SOCKADDR*)&sockaddr6, sizeof(sockaddr6), NULL, address6, &len ); - ok( !ret, "WSAAddressToStringW() failed unexpectedly: %d\n", WSAGetLastError() ); - - ok( !lstrcmpW( address6, expect6_2 ), "Wrong string returned\n" ); - ok( len == sizeof(expect6_2)/sizeof(WCHAR), "Got %d\n", len); - - /* Test IPv6 address and port number */ - len = sizeof(address6)/sizeof(WCHAR); - - sockaddr6.sin6_family = AF_INET6; - sockaddr6.sin6_port = 0xfa81; - sockaddr6.sin6_scope_id = 0; - memcpy (sockaddr6.sin6_addr.s6_addr, addr6_3, sizeof(addr6_3)); - - ret = WSAAddressToStringW( (SOCKADDR*)&sockaddr6, sizeof(sockaddr6), NULL, address6, &len ); - ok( !ret, "WSAAddressToStringW() failed unexpectedly: %d\n", WSAGetLastError() ); - todo_wine - { - ok( !lstrcmpW( address6, expect6_3 ), "Wrong string returned\n" ); - ok( len == sizeof(expect6_3)/sizeof(WCHAR), "Got %d\n", len); - } - - /* Test IPv6 address, port number and scope_id */ - len = sizeof(address6)/sizeof(WCHAR); - - sockaddr6.sin6_family = AF_INET6; - sockaddr6.sin6_port = 0xfa81; - sockaddr6.sin6_scope_id = 0x1234; - memcpy (sockaddr6.sin6_addr.s6_addr, addr6_3, sizeof(addr6_3)); - - ret = WSAAddressToStringW( (SOCKADDR*)&sockaddr6, sizeof(sockaddr6), NULL, address6, &len ); - ok( !ret, "WSAAddressToStringW() failed unexpectedly: %d\n", WSAGetLastError() ); - todo_wine - { - ok( !lstrcmpW( address6, expect6_3_2 ), "Wrong string returned\n" ); - ok( len == sizeof(expect6_3_2)/sizeof(WCHAR), "Got %d\n", len); - } - - /* Test IPv6 address and scope_id */ - len = sizeof(address6)/sizeof(WCHAR); - - sockaddr6.sin6_family = AF_INET6; - sockaddr6.sin6_port = 0x0000; - sockaddr6.sin6_scope_id = 0xfffe; - memcpy (sockaddr6.sin6_addr.s6_addr, addr6_3, sizeof(addr6_3)); - - ret = WSAAddressToStringW( (SOCKADDR*)&sockaddr6, sizeof(sockaddr6), NULL, address6, &len ); - ok( !ret, "WSAAddressToStringW() failed unexpectedly: %d\n", WSAGetLastError() ); - todo_wine - { - ok( !lstrcmpW( address6, expect6_3_3 ), "Wrong string returned\n" ); - ok( len == sizeof(expect6_3_3)/sizeof(WCHAR), "Got %d\n", len); - } - -end: - if (v6 != INVALID_SOCKET) - closesocket(v6); + ok( len == sizeof( expect4 )/sizeof( WCHAR ), "Got size %d\n", len); } static void test_WSAStringToAddressA(void) @@ -2640,387 +2539,6 @@ static void test_GetAddrInfoW(void) pFreeAddrInfoW(result); } -static int CALLBACK AlwaysDeferConditionFunc(LPWSABUF lpCallerId, LPWSABUF lpCallerData, LPQOS pQos, - LPQOS lpGQOS, LPWSABUF lpCalleeId, LPWSABUF lpCalleeData, - GROUP FAR * g, DWORD_PTR dwCallbackData) -{ - return CF_DEFER; -} - -static void test_AcceptEx(void) -{ - SOCKET listener = INVALID_SOCKET; - SOCKET acceptor = INVALID_SOCKET; - SOCKET connector = INVALID_SOCKET; - SOCKET connector2 = INVALID_SOCKET; - struct sockaddr_in bindAddress; - int socklen; - GUID acceptExGuid = WSAID_ACCEPTEX; - LPFN_ACCEPTEX pAcceptEx = NULL; - fd_set fds_accept, fds_send; - struct timeval timeout = {0,10}; /* wait for 10 milliseconds */ - int got, conn1, i; - DWORD bytesReturned; - char buffer[1024]; - OVERLAPPED overlapped; - int iret; - BOOL bret; - DWORD dwret; - - memset(&overlapped, 0, sizeof(overlapped)); - - listener = socket(AF_INET, SOCK_STREAM, 0); - if (listener == INVALID_SOCKET) { - skip("could not create listener socket, error %d\n", WSAGetLastError()); - goto end; - } - - acceptor = socket(AF_INET, SOCK_STREAM, 0); - if (acceptor == INVALID_SOCKET) { - skip("could not create acceptor socket, error %d\n", WSAGetLastError()); - goto end; - } - - connector = socket(AF_INET, SOCK_STREAM, 0); - if (connector == INVALID_SOCKET) { - skip("could not create connector socket, error %d\n", WSAGetLastError()); - goto end; - } - - memset(&bindAddress, 0, sizeof(bindAddress)); - bindAddress.sin_family = AF_INET; - bindAddress.sin_addr.s_addr = inet_addr("127.0.0.1"); - iret = bind(listener, (struct sockaddr*)&bindAddress, sizeof(bindAddress)); - if (iret != 0) { - skip("failed to bind, error %d\n", WSAGetLastError()); - goto end; - } - - socklen = sizeof(bindAddress); - iret = getsockname(listener, (struct sockaddr*)&bindAddress, &socklen); - if (iret != 0) { - skip("failed to lookup bind address, error %d\n", WSAGetLastError()); - goto end; - } - - if (set_blocking(listener, FALSE)) { - skip("couldn't make socket non-blocking, error %d\n", WSAGetLastError()); - goto end; - } - - iret = WSAIoctl(listener, SIO_GET_EXTENSION_FUNCTION_POINTER, &acceptExGuid, sizeof(acceptExGuid), - &pAcceptEx, sizeof(pAcceptEx), &bytesReturned, NULL, NULL); - if (iret) { - skip("WSAIoctl failed to get AcceptEx with ret %d + errno %d\n", iret, WSAGetLastError()); - goto end; - } - - bret = pAcceptEx(INVALID_SOCKET, acceptor, buffer, sizeof(buffer) - 2*(sizeof(struct sockaddr_in) + 16), - sizeof(struct sockaddr_in) + 16, sizeof(struct sockaddr_in) + 16, - &bytesReturned, &overlapped); - ok(bret == FALSE && WSAGetLastError() == WSAENOTSOCK, "AcceptEx on invalid listening socket " - "returned %d + errno %d\n", bret, WSAGetLastError()); - - bret = pAcceptEx(listener, INVALID_SOCKET, buffer, sizeof(buffer) - 2*(sizeof(struct sockaddr_in) + 16), - sizeof(struct sockaddr_in) + 16, sizeof(struct sockaddr_in) + 16, - &bytesReturned, &overlapped); - ok(bret == FALSE && WSAGetLastError() == WSAEINVAL, "AcceptEx on invalid accepting socket " - "returned %d + errno %d\n", bret, WSAGetLastError()); - - bret = pAcceptEx(listener, acceptor, NULL, sizeof(buffer) - 2*(sizeof(struct sockaddr_in) + 16), - sizeof(struct sockaddr_in) + 16, sizeof(struct sockaddr_in) + 16, - &bytesReturned, &overlapped); - ok(bret == FALSE && - (WSAGetLastError() == WSAEINVAL || - broken(WSAGetLastError() == WSAEFAULT)), /* NT4 */ - "AcceptEx on NULL buffer returned %d + errno %d\n", bret, WSAGetLastError()); - - bret = pAcceptEx(listener, acceptor, buffer, 0, 0, sizeof(struct sockaddr_in) + 16, - &bytesReturned, &overlapped); - ok(bret == FALSE && WSAGetLastError() == WSAEINVAL, "AcceptEx on too small local address size " - "returned %d + errno %d\n", bret, WSAGetLastError()); - - bret = pAcceptEx(listener, acceptor, buffer, 0, sizeof(struct sockaddr_in) + 16, 0, - &bytesReturned, &overlapped); - ok(bret == FALSE && WSAGetLastError() == WSAEINVAL, "AcceptEx on too small remote address size " - "returned %d + errno %d\n", bret, WSAGetLastError()); - - bret = pAcceptEx(listener, acceptor, buffer, 0, - sizeof(struct sockaddr_in) + 16, sizeof(struct sockaddr_in) + 16, - &bytesReturned, NULL); - ok(bret == FALSE && WSAGetLastError() == ERROR_INVALID_PARAMETER, "AcceptEx on a NULL overlapped " - "returned %d + errno %d\n", bret, WSAGetLastError()); - - bret = pAcceptEx(listener, acceptor, buffer, sizeof(buffer) - 2*(sizeof(struct sockaddr_in) + 16), - sizeof(struct sockaddr_in) + 16, sizeof(struct sockaddr_in) + 16, - &bytesReturned, &overlapped); - ok(bret == FALSE && WSAGetLastError() == WSAEINVAL, "AcceptEx on a non-listening socket " - "returned %d + errno %d\n", bret, WSAGetLastError()); - - iret = listen(listener, 5); - if (iret != 0) { - skip("listening failed, errno = %d\n", WSAGetLastError()); - goto end; - } - - overlapped.hEvent = CreateEvent(NULL, FALSE, FALSE, NULL); - if (overlapped.hEvent == NULL) { - skip("could not create event object, errno = %d\n", GetLastError()); - goto end; - } - - bret = pAcceptEx(listener, acceptor, buffer, 0, - sizeof(struct sockaddr_in) + 16, sizeof(struct sockaddr_in) + 16, - &bytesReturned, &overlapped); - ok(bret == FALSE && WSAGetLastError() == ERROR_IO_PENDING, "AcceptEx returned %d + errno %d\n", bret, WSAGetLastError()); - - bret = pAcceptEx(listener, acceptor, buffer, 0, - sizeof(struct sockaddr_in) + 16, sizeof(struct sockaddr_in) + 16, - &bytesReturned, &overlapped); - ok((bret == FALSE && WSAGetLastError() == WSAEINVAL) || broken(bret == FALSE && WSAGetLastError() == ERROR_IO_PENDING) /* NT4 */, - "AcceptEx on already pending socket returned %d + errno %d\n", bret, WSAGetLastError()); - if (bret == FALSE && WSAGetLastError() == ERROR_IO_PENDING) { - /* We need to cancel this call, otherwise things fail */ - bret = CancelIo((HANDLE) listener); - ok(bret, "Failed to cancel failed test. Bailing...\n"); - if (!bret) return; - - bret = pAcceptEx(listener, acceptor, buffer, 0, - sizeof(struct sockaddr_in) + 16, sizeof(struct sockaddr_in) + 16, - &bytesReturned, &overlapped); - ok(bret == FALSE && WSAGetLastError() == ERROR_IO_PENDING, "AcceptEx returned %d + errno %d\n", bret, WSAGetLastError()); - } - - iret = connect(connector, (struct sockaddr*)&bindAddress, sizeof(bindAddress)); - ok(iret == 0, "connecting to accepting socket failed, error %d\n", WSAGetLastError()); - - dwret = WaitForSingleObject(overlapped.hEvent, INFINITE); - ok(dwret == WAIT_OBJECT_0, "Waiting for accept event failed with %d + errno %d\n", dwret, GetLastError()); - - bret = GetOverlappedResult((HANDLE)listener, &overlapped, &bytesReturned, FALSE); - ok(bret, "GetOverlappedResult failed, error %d\n", GetLastError()); - ok(bytesReturned == 0, "bytesReturned isn't supposed to be %d\n", bytesReturned); - - closesocket(connector); - connector = INVALID_SOCKET; - closesocket(acceptor); - acceptor = INVALID_SOCKET; - - /* Test short reads */ - - acceptor = socket(AF_INET, SOCK_STREAM, 0); - if (acceptor == INVALID_SOCKET) { - skip("could not create acceptor socket, error %d\n", WSAGetLastError()); - goto end; - } - connector = socket(AF_INET, SOCK_STREAM, 0); - if (connector == INVALID_SOCKET) { - skip("could not create connector socket, error %d\n", WSAGetLastError()); - goto end; - } - bret = pAcceptEx(listener, acceptor, buffer, 2, - sizeof(struct sockaddr_in) + 16, sizeof(struct sockaddr_in) + 16, - &bytesReturned, &overlapped); - ok(bret == FALSE && WSAGetLastError() == ERROR_IO_PENDING, "AcceptEx returned %d + errno %d\n", bret, WSAGetLastError()); - - iret = connect(connector, (struct sockaddr*)&bindAddress, sizeof(bindAddress)); - ok(iret == 0, "connecting to accepting socket failed, error %d\n", WSAGetLastError()); - - dwret = WaitForSingleObject(overlapped.hEvent, 0); - ok(dwret == WAIT_TIMEOUT, "Waiting for accept event timeout failed with %d + errno %d\n", dwret, GetLastError()); - - iret = send(connector, buffer, 1, 0); - ok(iret == 1, "could not send 1 byte: send %d errno %d\n", iret, WSAGetLastError()); - - dwret = WaitForSingleObject(overlapped.hEvent, 1000); - ok(dwret == WAIT_OBJECT_0, "Waiting for accept event failed with %d + errno %d\n", dwret, GetLastError()); - - bret = GetOverlappedResult((HANDLE)listener, &overlapped, &bytesReturned, FALSE); - ok(bret, "GetOverlappedResult failed, error %d\n", GetLastError()); - ok(bytesReturned == 1, "bytesReturned isn't supposed to be %d\n", bytesReturned); - - closesocket(connector); - connector = INVALID_SOCKET; - closesocket(acceptor); - acceptor = INVALID_SOCKET; - - /* Test CF_DEFER & AcceptEx interaction */ - - acceptor = socket(AF_INET, SOCK_STREAM, 0); - if (acceptor == INVALID_SOCKET) { - skip("could not create acceptor socket, error %d\n", WSAGetLastError()); - goto end; - } - connector = socket(AF_INET, SOCK_STREAM, 0); - if (connector == INVALID_SOCKET) { - skip("could not create connector socket, error %d\n", WSAGetLastError()); - goto end; - } - connector2 = socket(AF_INET, SOCK_STREAM, 0); - if (connector == INVALID_SOCKET) { - skip("could not create connector socket, error %d\n", WSAGetLastError()); - goto end; - } - - if (set_blocking(connector, FALSE)) { - skip("couldn't make socket non-blocking, error %d\n", WSAGetLastError()); - goto end; - } - - if (set_blocking(connector2, FALSE)) { - skip("couldn't make socket non-blocking, error %d\n", WSAGetLastError()); - goto end; - } - - /* Connect socket #1 */ - iret = connect(connector, (struct sockaddr*)&bindAddress, sizeof(bindAddress)); - ok(iret == SOCKET_ERROR && WSAGetLastError() == WSAEWOULDBLOCK, "connecting to accepting socket failed, error %d\n", WSAGetLastError()); - - FD_ZERO ( &fds_accept ); - FD_ZERO ( &fds_send ); - - FD_SET ( listener, &fds_accept ); - FD_SET ( connector, &fds_send ); - - buffer[0] = '0'; - got = 0; - conn1 = 0; - - for (i = 0; i < 4000; ++i) - { - fd_set fds_openaccept = fds_accept, fds_opensend = fds_send; - - wsa_ok ( ( select ( 0, &fds_openaccept, &fds_opensend, NULL, &timeout ) ), SOCKET_ERROR !=, - "acceptex test(%d): could not select on socket, errno %d\n" ); - - /* check for incoming requests */ - if ( FD_ISSET ( listener, &fds_openaccept ) ) { - got++; - if (got == 1) { - SOCKET tmp = WSAAccept(listener, NULL, NULL, (LPCONDITIONPROC) AlwaysDeferConditionFunc, 0); - ok(tmp == INVALID_SOCKET && WSAGetLastError() == WSATRY_AGAIN, "Failed to defer connection, %d\n", WSAGetLastError()); - bret = pAcceptEx(listener, acceptor, buffer, 0, - sizeof(struct sockaddr_in) + 16, sizeof(struct sockaddr_in) + 16, - &bytesReturned, &overlapped); - ok(bret == FALSE && WSAGetLastError() == ERROR_IO_PENDING, "AcceptEx returned %d + errno %d\n", bret, WSAGetLastError()); - } - else if (got == 2) { - /* this should be socket #2 */ - SOCKET tmp = accept(listener, NULL, NULL); - ok(tmp != INVALID_SOCKET, "accept failed %d\n", WSAGetLastError()); - closesocket(tmp); - } - else { - ok(FALSE, "Got more than 2 connections?\n"); - } - } - if ( conn1 && FD_ISSET ( connector2, &fds_opensend ) ) { - /* Send data on second socket, and stop */ - send(connector2, "2", 1, 0); - FD_CLR ( connector2, &fds_send ); - - break; - } - if ( FD_ISSET ( connector, &fds_opensend ) ) { - /* Once #1 is connected, allow #2 to connect */ - conn1 = 1; - - send(connector, "1", 1, 0); - FD_CLR ( connector, &fds_send ); - - iret = connect(connector2, (struct sockaddr*)&bindAddress, sizeof(bindAddress)); - ok(iret == SOCKET_ERROR && WSAGetLastError() == WSAEWOULDBLOCK, "connecting to accepting socket failed, error %d\n", WSAGetLastError()); - FD_SET ( connector2, &fds_send ); - } - } - - ok (got == 2 || broken(got == 1) /* NT4 */, - "Did not get both connections, got %d\n", got); - - dwret = WaitForSingleObject(overlapped.hEvent, 0); - ok(dwret == WAIT_OBJECT_0, "Waiting for accept event failed with %d + errno %d\n", dwret, GetLastError()); - - bret = GetOverlappedResult((HANDLE)listener, &overlapped, &bytesReturned, FALSE); - ok(bret, "GetOverlappedResult failed, error %d\n", GetLastError()); - ok(bytesReturned == 0, "bytesReturned isn't supposed to be %d\n", bytesReturned); - - set_blocking(acceptor, TRUE); - iret = recv( acceptor, buffer, 2, 0); - ok(iret == 1, "Failed to get data, %d, errno: %d\n", iret, WSAGetLastError()); - - ok(buffer[0] == '1', "The wrong first client was accepted by acceptex: %c != 1\n", buffer[0]); - - closesocket(connector); - connector = INVALID_SOCKET; - closesocket(acceptor); - acceptor = INVALID_SOCKET; - - /* clean up in case of failures */ - while ((acceptor = accept(listener, NULL, NULL)) != INVALID_SOCKET) - closesocket(acceptor); - - /* Disconnect during receive? */ - - acceptor = socket(AF_INET, SOCK_STREAM, 0); - if (acceptor == INVALID_SOCKET) { - skip("could not create acceptor socket, error %d\n", WSAGetLastError()); - goto end; - } - connector = socket(AF_INET, SOCK_STREAM, 0); - if (connector == INVALID_SOCKET) { - skip("could not create connector socket, error %d\n", WSAGetLastError()); - goto end; - } - bret = pAcceptEx(listener, acceptor, buffer, sizeof(buffer) - 2*(sizeof(struct sockaddr_in) + 16), - sizeof(struct sockaddr_in) + 16, sizeof(struct sockaddr_in) + 16, - &bytesReturned, &overlapped); - ok(bret == FALSE && WSAGetLastError() == ERROR_IO_PENDING, "AcceptEx returned %d + errno %d\n", bret, WSAGetLastError()); - - iret = connect(connector, (struct sockaddr*)&bindAddress, sizeof(bindAddress)); - ok(iret == 0, "connecting to accepting socket failed, error %d\n", WSAGetLastError()); - - closesocket(connector); - connector = INVALID_SOCKET; - - dwret = WaitForSingleObject(overlapped.hEvent, 1000); - ok(dwret == WAIT_OBJECT_0, "Waiting for accept event failed with %d + errno %d\n", dwret, GetLastError()); - - bret = GetOverlappedResult((HANDLE)listener, &overlapped, &bytesReturned, FALSE); - ok(bret, "GetOverlappedResult failed, error %d\n", GetLastError()); - ok(bytesReturned == 0, "bytesReturned isn't supposed to be %d\n", bytesReturned); - - acceptor = socket(AF_INET, SOCK_STREAM, 0); - if (acceptor == INVALID_SOCKET) { - skip("could not create acceptor socket, error %d\n", WSAGetLastError()); - goto end; - } - bret = pAcceptEx(listener, acceptor, buffer, sizeof(buffer) - 2*(sizeof(struct sockaddr_in) + 16), - sizeof(struct sockaddr_in) + 16, sizeof(struct sockaddr_in) + 16, - &bytesReturned, &overlapped); - ok(bret == FALSE && WSAGetLastError() == ERROR_IO_PENDING, "AcceptEx returned %d + errno %d\n", bret, WSAGetLastError()); - - closesocket(listener); - listener = INVALID_SOCKET; - - dwret = WaitForSingleObject(overlapped.hEvent, 1000); - ok(dwret == WAIT_OBJECT_0, "Waiting for accept event failed with %d + errno %d\n", dwret, GetLastError()); - - bret = GetOverlappedResult((HANDLE)listener, &overlapped, &bytesReturned, FALSE); - ok(!bret && GetLastError() == ERROR_OPERATION_ABORTED, "GetOverlappedResult failed, error %d\n", GetLastError()); - -end: - if (overlapped.hEvent) - WSACloseEvent(overlapped.hEvent); - if (listener != INVALID_SOCKET) - closesocket(listener); - if (acceptor != INVALID_SOCKET) - closesocket(acceptor); - if (connector != INVALID_SOCKET) - closesocket(connector); - if (connector2 != INVALID_SOCKET) - closesocket(connector2); -} - /**************** Main program ***************/ START_TEST( sock ) @@ -3073,7 +2591,5 @@ START_TEST( sock ) test_ipv6only(); test_GetAddrInfoW(); - test_AcceptEx(); - Exit(); } diff --git a/documentation/README.de b/documentation/README.de index 0d7414e23ed..332ab886115 100644 --- a/documentation/README.de +++ b/documentation/README.de @@ -111,9 +111,9 @@ Mit ./configure --help k die Kompilierung anzeigen lassen. Um mit Hilfe einer Patch-Datei auf ein neueres Release zu aktualisieren, -wechseln Sie erst mit cd in das Wurzelverzeichnis dieses Releases (eins -über dem, welches diese README-Datei enthält). Geben Sie dann -"make clean" ein und patchen Sie das Release mit dem Kommando: +wechsen Sie erst mit cd in das Wurzelverzeichnis dieses Releases (das, +welches diese README-Datei enthält). Geben Sie dann "make clean" ein +und patchen Sie das Release mit dem Kommando: bunzip2 -c Patch-Datei | patch -p1 @@ -145,7 +145,7 @@ Datei angeben oder nur einen Dateinamen. Beispiel: Um Notepad auszuführen: - wine notepad (den Suchpfad, der in der Konfigurations-Datei + wine notepad (den Suchpfad, der in der Konfiguartions-Datei wine notepad.exe angegeben wurde, benutzend) wine c:\\windows\\notepad.exe (die Dateinamen-Syntax von DOS benutzend) diff --git a/include/Makefile.in b/include/Makefile.in index aee348f5414..c62b85fbb06 100644 --- a/include/Makefile.in +++ b/include/Makefile.in @@ -50,7 +50,6 @@ PUBLIC_IDL_H_SRCS = \ mstask.idl \ msxml.idl \ msxml2.idl \ - netcon.idl \ netfw.idl \ oaidl.idl \ objidl.idl \ @@ -78,7 +77,6 @@ PUBLIC_IDL_H_SRCS = \ urlhist.idl \ urlmon.idl \ vmr9.idl \ - wbemcli.idl \ wincodec.idl \ wine/itss.idl \ wine/svcctl.idl \ @@ -106,7 +104,6 @@ SRCDIR_INCLUDES = \ basetsd.h \ basetyps.h \ bcrypt.h \ - binres.idl \ bitsmsg.h \ cderr.h \ cfgmgr32.h \ @@ -121,7 +118,6 @@ SRCDIR_INCLUDES = \ corerror.h \ corhdr.h \ cpl.h \ - crtrow.idl \ cryptdlg.h \ cryptuiapi.h \ custcntl.h \ @@ -143,6 +139,11 @@ SRCDIR_INCLUDES = \ d3drmobj.h \ d3dtypes.h \ d3dvec.inl \ + d3dx8.h \ + d3dx8core.h \ + d3dx8math.h \ + d3dx8math.inl \ + d3dx8mesh.h \ d3dx9.h \ d3dx9core.h \ d3dx9math.h \ @@ -150,9 +151,6 @@ SRCDIR_INCLUDES = \ d3dx9mesh.h \ d3dx9shader.h \ d3dx9tex.h \ - dbccmd.idl \ - dbcses.idl \ - dbdsad.idl \ dbghelp.h \ dbinit.idl \ dbprop.idl \ @@ -351,7 +349,6 @@ SRCDIR_INCLUDES = \ npapi.h \ nspapi.h \ ntddcdrm.h \ - ntddndis.h \ ntddscsi.h \ ntddstor.h \ ntdsapi.h \ @@ -367,7 +364,6 @@ SRCDIR_INCLUDES = \ oleauto.h \ olectl.h \ oledlg.h \ - opnrst.idl \ pdh.h \ pdhmsg.h \ pktdef.h \ @@ -394,7 +390,6 @@ SRCDIR_INCLUDES = \ rpcndr.h \ rpcnterr.h \ rpcproxy.h \ - rtutils.h \ scarderr.h \ schannel.h \ schemadef.h \ @@ -403,7 +398,6 @@ SRCDIR_INCLUDES = \ secext.h \ security.h \ sensapi.h \ - sesprp.idl \ setupapi.h \ sfc.h \ shdispid.h \ @@ -423,7 +417,6 @@ SRCDIR_INCLUDES = \ sspi.h \ storage.h \ svrapi.h \ - t2embapi.h \ tapi.h \ tchar.h \ textserv.h \ diff --git a/include/activscp.idl b/include/activscp.idl index 9be7ec45617..e75fbec9734 100644 --- a/include/activscp.idl +++ b/include/activscp.idl @@ -40,11 +40,8 @@ cpp_quote("#define SCRIPTPROP_CONVERSIONLCID 0x00001002") cpp_quote("#define SCRIPTPROP_HOSTSTACKREQUIRED 0x00001003") cpp_quote("#define SCRIPTPROP_DEBUGGER 0x00001100") cpp_quote("#define SCRIPTPROP_JITDEBUG 0x00001101") -cpp_quote("#define SCRIPTPROP_INVOKEVERSIONING 0x00004000") - -cpp_quote("#define SCRIPTPROP_HACK_FIBERSUPPORT 0x70000000") -cpp_quote("#define SCRIPTPROP_HACK_TRIDENTEVENTSINK 0x70000001") -cpp_quote("#define SCRIPTPROP_ABBREVIATE_GLOBALNAME_RESOLUTION 0x70000002") +cpp_quote("#define SCRIPTPROP_HACK_FIBERSUPPORT 0x70000000") +cpp_quote("#define SCRIPTPROP_HACK_TRIDENTEVENTSINK 0x70000001") typedef enum tagSCRIPTSTATE { SCRIPTSTATE_UNINITIALIZED = 0, diff --git a/include/binres.idl b/include/binres.idl deleted file mode 100644 index 3797c028820..00000000000 --- a/include/binres.idl +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Copyright (C) 2009 Huw Davies - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -[ - object, - uuid(0c733ab1-2a1c-11ce-ade5-00aa0044773d), - pointer_default(unique) -] -interface IBindResource : IUnknown -{ - [local] - HRESULT Bind([in] IUnknown *pUnkOuter, - [in] LPCOLESTR pwszURL, - [in] DBBINDURLFLAG dwBindURLFlags, - [in] REFGUID rguid, - [in] REFIID riid, - [in] IAuthenticate *pAuthenticate, - [in, out, unique] DBIMPLICITSESSION *pImplSession, - [in, out, unique] DBBINDURLSTATUS *pdwBindStatus, - [out, iid_is(riid)] IUnknown **ppUnk); - - [call_as(Bind)] - HRESULT RemoteBind([in] IUnknown *pUnkOuter, - [in] LPCOLESTR pwszURL, - [in] DBBINDURLFLAG dwBindURLFlags, - [in] REFGUID rguid, - [in] REFIID riid, - [in] IAuthenticate *pAuthenticate, - [in] IUnknown *pSessionUnkOuter, - [in, unique] IID *piid, - [in, out, unique, iid_is(piid)] IUnknown **ppSession, - [in, out, unique] DBBINDURLSTATUS *pdwBindStatus, - [out, iid_is(riid)] IUnknown **ppUnk); -} diff --git a/include/commctrl.h b/include/commctrl.h index 8673ba9d241..b064c01537d 100644 --- a/include/commctrl.h +++ b/include/commctrl.h @@ -484,8 +484,6 @@ static const WCHAR PROGRESS_CLASSW[] = { 'm','s','c','t','l','s','_', #define PBM_GETPOS (WM_USER+8) #define PBM_SETBARCOLOR (WM_USER+9) #define PBM_SETMARQUEE (WM_USER+10) -#define PBM_GETBKCOLOR (WM_USER+14) -#define PBM_GETBARCOLOR (WM_USER+15) #define PBM_SETBKCOLOR CCM_SETBKCOLOR #define PBS_SMOOTH 0x01 @@ -1988,9 +1986,6 @@ typedef struct tagREBARBANDINFOA UINT cxIdeal; LPARAM lParam; UINT cxHeader; - /* _WIN32_WINNT >= 0x0600 */ - RECT rcChevronLocation; - UINT uChevronState; } REBARBANDINFOA, *LPREBARBANDINFOA; typedef REBARBANDINFOA const *LPCREBARBANDINFOA; @@ -2017,9 +2012,6 @@ typedef struct tagREBARBANDINFOW UINT cxIdeal; LPARAM lParam; UINT cxHeader; - /* _WIN32_WINNT >= 0x0600 */ - RECT rcChevronLocation; - UINT uChevronState; } REBARBANDINFOW, *LPREBARBANDINFOW; typedef REBARBANDINFOW const *LPCREBARBANDINFOW; @@ -2031,9 +2023,6 @@ typedef REBARBANDINFOW const *LPCREBARBANDINFOW; #define REBARBANDINFOA_V3_SIZE CCSIZEOF_STRUCT(REBARBANDINFOA, wID) #define REBARBANDINFOW_V3_SIZE CCSIZEOF_STRUCT(REBARBANDINFOW, wID) #define REBARBANDINFO_V3_SIZE CCSIZEOF_STRUCT(WINELIB_NAME_AW(REBARBANDINFO), wID) -#define REBARBANDINFOA_V6_SIZE CCSIZEOF_STRUCT(REBARBANDINFOA, cxHeader) -#define REBARBANDINFOW_V6_SIZE CCSIZEOF_STRUCT(REBARBANDINFOW, cxHeader) -#define REBARBANDINFO_V6_SIZE CCSIZEOF_STRUCT(WINELIB_NAME_AW(REBARBANDINFO), cxHeader) typedef struct tagNMREBARCHILDSIZE { @@ -3263,7 +3252,6 @@ static const WCHAR WC_LISTVIEWW[] = { 'S','y','s', #define LVM_CANCELEDITLABEL (LVM_FIRST + 179) #define LVM_MAPINDEXTOID (LVM_FIRST + 180) #define LVM_MAPIDTOINDEX (LVM_FIRST + 181) -#define LVM_ISITEMVISIBLE (LVM_FIRST + 182) #define LVN_FIRST (0U-100U) #define LVN_LAST (0U-199U) diff --git a/include/config.h.in b/include/config.h.in index 6ef0892af9f..c113fcb4662 100644 --- a/include/config.h.in +++ b/include/config.h.in @@ -123,6 +123,9 @@ /* Define to 1 if you have the header file. */ #undef HAVE_FREETYPE_FTMODAPI_H +/* Define to 1 if you have the header file. */ +#undef HAVE_FREETYPE_FTNAMES_H + /* Define to 1 if you have the header file. */ #undef HAVE_FREETYPE_FTOUTLN_H @@ -219,6 +222,9 @@ /* Define to 1 if you have the `getuid' function. */ #undef HAVE_GETUID +/* Define to 1 if you have the header file. */ +#undef HAVE_GL_GLEXT_H + /* Define to 1 if you have the header file. */ #undef HAVE_GL_GLU_H @@ -552,9 +558,6 @@ /* Define to 1 if the system has the type `pid_t'. */ #undef HAVE_PID_T -/* Define to 1 if you have the `pipe2' function. */ -#undef HAVE_PIPE2 - /* Define to 1 if you have the header file. */ #undef HAVE_PNG_H @@ -831,9 +834,6 @@ /* Define to 1 if you have the header file. */ #undef HAVE_SYS_FILIO_H -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_INOTIFY_H - /* Define to 1 if you have the header file. */ #undef HAVE_SYS_IOCTL_H @@ -1191,9 +1191,6 @@ /* Define to 1 if the X Window System is missing or not being used. */ #undef X_DISPLAY_MISSING -/* Define to a macro to output a .cfi assembly pseudo-op */ -#undef __ASM_CFI - /* Define to a macro to define an assembly function */ #undef __ASM_DEFINE_FUNC diff --git a/include/crtrow.idl b/include/crtrow.idl deleted file mode 100644 index da26a72d5d9..00000000000 --- a/include/crtrow.idl +++ /dev/null @@ -1,51 +0,0 @@ -/* - * Copyright (C) 2009 Huw Davies - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -[ - object, - uuid(0c733ab2-2a1c-11ce-ade5-00aa0044773d), - pointer_default(unique) -] -interface ICreateRow : IUnknown -{ - [local] - HRESULT CreateRow([in, unique] IUnknown *pUnkOuter, - [in] LPCOLESTR pwszURL, - [in] DBBINDURLFLAG dwBindURLFlags, - [in] REFGUID rguid, - [in] REFIID riid, - [in, unique] IAuthenticate *pAuthenticate, - [in, out, unique] DBIMPLICITSESSION *pImplSession, - [in, out, unique] DBBINDURLSTATUS *pdwBindStatus, - [out, /*annotation("__deref_opt_out_opt")*/] LPOLESTR *ppwszNewURL, - [out, iid_is(riid)] IUnknown **ppUnk); - - [call_as(CreateRow)] - HRESULT RemoteCreateRow([in] IUnknown *pUnkOuter, - [in] LPCOLESTR pwszURL, - [in] DBBINDURLFLAG dwBindURLFlags, - [in] REFGUID rguid, - [in] REFIID riid, - [in] IAuthenticate *pAuthenticate, - [in] IUnknown *pSessionUnkOuter, - [in, unique] IID *piid, - [in, out, unique, iid_is(piid)] IUnknown **ppSession, - [in, out, unique] DBBINDURLSTATUS *pdwBindStatus, - [in, out, unique] LPOLESTR *ppwszNewURL, - [out, iid_is(riid)] IUnknown **ppUnk); -} diff --git a/include/d3d10effect.h b/include/d3d10effect.h index b9c5c0861cb..37d4bd1932a 100644 --- a/include/d3d10effect.h +++ b/include/d3d10effect.h @@ -203,49 +203,6 @@ DECLARE_INTERFACE_(ID3D10EffectConstantBuffer, ID3D10EffectVariable) }; #undef INTERFACE -DEFINE_GUID(IID_ID3D10EffectMatrixVariable, 0x50666c24, 0xb82f, 0x4eed, 0xa1, 0x72, 0x5b, 0x6e, 0x7e, 0x85, 0x22, 0xe0); - -#define INTERFACE ID3D10EffectMatrixVariable -DECLARE_INTERFACE_(ID3D10EffectMatrixVariable, ID3D10EffectVariable) -{ - /* ID3D10EffectVariable methods */ - STDMETHOD_(BOOL, IsValid)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectType *, GetType)(THIS) PURE; - STDMETHOD(GetDesc)(THIS_ D3D10_EFFECT_VARIABLE_DESC *desc) PURE; - STDMETHOD_(struct ID3D10EffectVariable *, GetAnnotationByIndex)(THIS_ UINT index) PURE; - STDMETHOD_(struct ID3D10EffectVariable *, GetAnnotationByName)(THIS_ LPCSTR name) PURE; - STDMETHOD_(struct ID3D10EffectVariable *, GetMemberByIndex)(THIS_ UINT index) PURE; - STDMETHOD_(struct ID3D10EffectVariable *, GetMemberByName)(THIS_ LPCSTR name) PURE; - STDMETHOD_(struct ID3D10EffectVariable *, GetMemberBySemantic)(THIS_ LPCSTR semantic) PURE; - STDMETHOD_(struct ID3D10EffectVariable *, GetElement)(THIS_ UINT index) PURE; - STDMETHOD_(struct ID3D10EffectConstantBuffer *, GetParentConstantBuffer)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectScalarVariable *, AsScalar)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectVectorVariable *, AsVector)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectMatrixVariable *, AsMatrix)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectStringVariable *, AsString)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectShaderResourceVariable *, AsShaderResource)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectRenderTargetViewVariable *, AsRenderTargetView)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectDepthStencilViewVariable *, AsDepthStencilView)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectConstantBuffer *, AsConstantBuffer)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectShaderVariable *, AsShader)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectBlendVariable *, AsBlend)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectDepthStencilVariable *, AsDepthStencil)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectRasterizerVariable *, AsRasterizer)(THIS) PURE; - STDMETHOD_(struct ID3D10EffectSamplerVariable *, AsSampler)(THIS) PURE; - STDMETHOD(SetRawValue)(THIS_ void *data, UINT offset, UINT count) PURE; - STDMETHOD(GetRawValue)(THIS_ void *data, UINT offset, UINT count) PURE; - /* ID3D10EffectMatrixVariable methods */ - STDMETHOD(SetMatrix)(THIS_ float *data) PURE; - STDMETHOD(GetMatrix)(THIS_ float *data) PURE; - STDMETHOD(SetMatrixArray)(THIS_ float *data, UINT offset, UINT count) PURE; - STDMETHOD(GetMatrixArray)(THIS_ float *data, UINT offset, UINT count) PURE; - STDMETHOD(SetMatrixTranspose)(THIS_ float *data) PURE; - STDMETHOD(GetMatrixTranspose)(THIS_ float *data) PURE; - STDMETHOD(SetMatrixTransposeArray)(THIS_ float *data, UINT offset, UINT count) PURE; - STDMETHOD(GetMatrixTransposeArray)(THIS_ float *data, UINT offset, UINT count) PURE; -}; -#undef INTERFACE - DEFINE_GUID(IID_ID3D10EffectTechnique, 0xdb122ce8, 0xd1c9, 0x4292, 0xb2, 0x37, 0x24, 0xed, 0x3d, 0xe8, 0xb1, 0x75); #define INTERFACE ID3D10EffectTechnique diff --git a/include/d3dx8.h b/include/d3dx8.h new file mode 100644 index 00000000000..0ae27c3a52e --- /dev/null +++ b/include/d3dx8.h @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2007 David Adam + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#ifndef __D3DX8_H__ +#define __D3DX8_H__ + +#include +#include + +#include +#include +/* FIXME: #include */ +#include +/* FIXME: #include */ +/* FIXME: #include */ + +#endif diff --git a/include/d3dx8core.h b/include/d3dx8core.h new file mode 100644 index 00000000000..6de45833949 --- /dev/null +++ b/include/d3dx8core.h @@ -0,0 +1,130 @@ +/* + * Copyright (C) 2002 Raphael Junqueira + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#ifndef __WINE_D3DX8CORE_H +#define __WINE_D3DX8CORE_H + +#include + +/***************************************************************************** + * #defines and error codes + */ +#define D3DXASM_DEBUG 1 +#define D3DXASM_SKIPVALIDATION 2 + +#define _FACD3D 0x876 +#define MAKE_D3DXHRESULT( code ) MAKE_HRESULT( 1, _FACD3D, code ) + +/* + * Direct3D Errors + */ +#define D3DXERR_CANNOTATTRSORT MAKE_D3DXHRESULT(2158) +#define D3DXERR_CANNOTMODIFYINDEXBUFFER MAKE_D3DXHRESULT(2159) +#define D3DXERR_INVALIDMESH MAKE_D3DXHRESULT(2160) +#define D3DXERR_SKINNINGNOTSUPPORTED MAKE_D3DXHRESULT(2161) +#define D3DXERR_TOOMANYINFLUENCES MAKE_D3DXHRESULT(2162) +#define D3DXERR_INVALIDDATA MAKE_D3DXHRESULT(2163) + +/***************************************************************************** + * Predeclare the interfaces + */ +DEFINE_GUID(IID_ID3DXBuffer, 0x1,0x1,0x4,0xB0,0xCF,0x98,0xFE,0xFD,0xFF,0x95,0x12);/* FIXME */ +typedef struct ID3DXBuffer *LPD3DXBUFFER; +DEFINE_GUID(IID_ID3DXFont, 0x1,0x1,0x4,0xB0,0xCF,0x98,0xFE,0xFD,0xFF,0x95,0x13);/* FIXME */ +typedef struct ID3DXFont *LPD3DXFONT; + +/***************************************************************************** + * ID3DXBuffer interface + */ +#define INTERFACE ID3DXBuffer +DECLARE_INTERFACE_(ID3DXBuffer,IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + /*** ID3DXBuffer methods ***/ + STDMETHOD_(LPVOID,GetBufferPointer)(THIS) PURE; + STDMETHOD_(DWORD,GetBufferSize)(THIS) PURE; +}; +#undef INTERFACE + +#if !defined(__cplusplus) || defined(CINTERFACE) +/*** IUnknown methods ***/ +#define ID3DXBuffer_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define ID3DXBuffer_AddRef(p) (p)->lpVtbl->AddRef(p) +#define ID3DXBuffer_Release(p) (p)->lpVtbl->Release(p) +/*** ID3DXBuffer methods ***/ +#define ID3DXBuffer_GetBufferPointer(p) (p)->lpVtbl->GetBufferPointer(p) +#define ID3DXBuffer_GetBufferSize(p) (p)->lpVtbl->GetBufferSize(p) +#endif + +/***************************************************************************** + * ID3DXFont interface + */ +#define INTERFACE ID3DXFont +DECLARE_INTERFACE_(ID3DXFont,IUnknown) +{ + /*** IUnknown methods ***/ + STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + /*** ID3DXFont methods ***/ + STDMETHOD(Begin)(THIS) PURE; + STDMETHOD(DrawTextA)(THIS) PURE; + STDMETHOD(End)(THIS) PURE; +}; +#undef INTERFACE + +#if !defined(__cplusplus) || defined(CINTERFACE) +/*** IUnknown methods ***/ +#define ID3DXFont_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define ID3DXFont_AddRef(p) (p)->lpVtbl->AddRef(p) +#define ID3DXFont_Release(p) (p)->lpVtbl->Release(p) +/*** ID3DXFont methods ***/ +#define ID3DXFont_Begin(p) (p)->lpVtbl->Begin(p) +#define ID3DXFont_DrawTextA(p,a,b,c,d,e)(p)->lpVtbl->DrawText(p,a,b,c,d,e) +#define ID3DXFont_End(p) (p)->lpVtbl->End(p) +#endif + +/************************************************************************************* + * Define entrypoints + */ +#ifdef __cplusplus +extern "C" { +#endif + +HRESULT WINAPI D3DXCreateFont(LPDIRECT3DDEVICE8 pDevice, HFONT hFont, LPD3DXFONT* ppFont); +HRESULT WINAPI D3DXAssembleShader(LPCVOID pSrcData, UINT SrcDataLen, DWORD Flags, + LPD3DXBUFFER* ppConstants, + LPD3DXBUFFER* ppCompiledShader, + LPD3DXBUFFER* ppCompilationErrors); +HRESULT WINAPI D3DXAssembleShaderFromFileA(LPCSTR pSrcFile, DWORD Flags, + LPD3DXBUFFER* ppConstants, + LPD3DXBUFFER* ppCompiledShader, + LPD3DXBUFFER* ppCompilationErrors); +HRESULT WINAPI D3DXAssembleShaderFromFileW(LPCWSTR pSrcFile, DWORD Flags, + LPD3DXBUFFER* ppConstants, + LPD3DXBUFFER* ppCompiledShader, + LPD3DXBUFFER* ppCompilationErrors); + +#ifdef __cplusplus +} +#endif + +#endif /* __WINE_D3DX8CORE_H */ diff --git a/include/d3dx8math.h b/include/d3dx8math.h new file mode 100644 index 00000000000..ee5c220dd0e --- /dev/null +++ b/include/d3dx8math.h @@ -0,0 +1,415 @@ +/* + * Copyright (C) 2007 David Adam + * Copyright (C) 2007 Tony Wasserka + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include + +#ifndef __D3DX8MATH_H__ +#define __D3DX8MATH_H__ + +#include + +#define D3DX_PI ((FLOAT)3.141592654) +#define D3DX_1BYPI ((FLOAT)0.318309886) + +#define D3DXToRadian(degree) ((degree) * (D3DX_PI / 180.0f)) +#define D3DXToDegree(radian) ((radian) * (180.0f / D3DX_PI)) + +typedef struct ID3DXMatrixStack *LPD3DXMATRIXSTACK; + +DEFINE_GUID(IID_ID3DXMatrixStack, +0xe3357330, 0xcc5e, 0x11d2, 0xa4, 0x34, 0x0, 0xa0, 0xc9, 0x6, 0x29, 0xa8); + +typedef struct D3DXVECTOR2 +{ +#ifdef __cplusplus + D3DXVECTOR2(); + D3DXVECTOR2(CONST FLOAT *pf); + D3DXVECTOR2(FLOAT fx, FLOAT fy); + + operator FLOAT* (); + operator CONST FLOAT* () const; + + D3DXVECTOR2& operator += (CONST D3DXVECTOR2&); + D3DXVECTOR2& operator -= (CONST D3DXVECTOR2&); + D3DXVECTOR2& operator *= (FLOAT); + D3DXVECTOR2& operator /= (FLOAT); + + D3DXVECTOR2 operator + () const; + D3DXVECTOR2 operator - () const; + + D3DXVECTOR2 operator + (CONST D3DXVECTOR2&) const; + D3DXVECTOR2 operator - (CONST D3DXVECTOR2&) const; + D3DXVECTOR2 operator * (FLOAT) const; + D3DXVECTOR2 operator / (FLOAT) const; + + friend D3DXVECTOR2 operator * (FLOAT, CONST D3DXVECTOR2&); + + BOOL operator == (CONST D3DXVECTOR2&) const; + BOOL operator != (CONST D3DXVECTOR2&) const; +#endif /* __cplusplus */ + FLOAT x, y; +} D3DXVECTOR2, *LPD3DXVECTOR2; + +#ifdef __cplusplus +typedef struct D3DXVECTOR3 : public D3DVECTOR +{ + D3DXVECTOR3(); + D3DXVECTOR3(CONST FLOAT *pf); + D3DXVECTOR3(CONST D3DVECTOR& v); + D3DXVECTOR3(FLOAT fx, FLOAT fy, FLOAT fz); + + operator FLOAT* (); + operator CONST FLOAT* () const; + + D3DXVECTOR3& operator += (CONST D3DXVECTOR3&); + D3DXVECTOR3& operator -= (CONST D3DXVECTOR3&); + D3DXVECTOR3& operator *= (FLOAT); + D3DXVECTOR3& operator /= (FLOAT); + + D3DXVECTOR3 operator + () const; + D3DXVECTOR3 operator - () const; + + D3DXVECTOR3 operator + (CONST D3DXVECTOR3&) const; + D3DXVECTOR3 operator - (CONST D3DXVECTOR3&) const; + D3DXVECTOR3 operator * (FLOAT) const; + D3DXVECTOR3 operator / (FLOAT) const; + + friend D3DXVECTOR3 operator * (FLOAT, CONST struct D3DXVECTOR3&); + + BOOL operator == (CONST D3DXVECTOR3&) const; + BOOL operator != (CONST D3DXVECTOR3&) const; +} D3DXVECTOR3, *LPD3DXVECTOR3; +#else /* !__cplusplus */ +typedef struct _D3DVECTOR D3DXVECTOR3, *LPD3DXVECTOR3; +#endif /* !__cplusplus */ + +typedef struct D3DXVECTOR4 +{ +#ifdef __cplusplus + D3DXVECTOR4(); + D3DXVECTOR4(CONST FLOAT *pf); + D3DXVECTOR4(FLOAT fx, FLOAT fy, FLOAT fz, FLOAT fw); + + operator FLOAT* (); + operator CONST FLOAT* () const; + + D3DXVECTOR4& operator += (CONST D3DXVECTOR4&); + D3DXVECTOR4& operator -= (CONST D3DXVECTOR4&); + D3DXVECTOR4& operator *= (FLOAT); + D3DXVECTOR4& operator /= (FLOAT); + + D3DXVECTOR4 operator + () const; + D3DXVECTOR4 operator - () const; + + D3DXVECTOR4 operator + (CONST D3DXVECTOR4&) const; + D3DXVECTOR4 operator - (CONST D3DXVECTOR4&) const; + D3DXVECTOR4 operator * (FLOAT) const; + D3DXVECTOR4 operator / (FLOAT) const; + + friend D3DXVECTOR4 operator * (FLOAT, CONST D3DXVECTOR4&); + + BOOL operator == (CONST D3DXVECTOR4&) const; + BOOL operator != (CONST D3DXVECTOR4&) const; +#endif /* __cplusplus */ + FLOAT x, y, z, w; +} D3DXVECTOR4, *LPD3DXVECTOR4; + +#ifdef __cplusplus +typedef struct D3DXMATRIX : public D3DMATRIX +{ + D3DXMATRIX(); + D3DXMATRIX(CONST FLOAT *pf); + D3DXMATRIX(CONST D3DMATRIX& mat); + D3DXMATRIX(FLOAT f11, FLOAT f12, FLOAT f13, FLOAT f14, + FLOAT f21, FLOAT f22, FLOAT f23, FLOAT f24, + FLOAT f31, FLOAT f32, FLOAT f33, FLOAT f34, + FLOAT f41, FLOAT f42, FLOAT f43, FLOAT f44); + + FLOAT& operator () (UINT row, UINT col); + FLOAT operator () (UINT row, UINT col) const; + + operator FLOAT* (); + operator CONST FLOAT* () const; + + D3DXMATRIX& operator *= (CONST D3DXMATRIX&); + D3DXMATRIX& operator += (CONST D3DXMATRIX&); + D3DXMATRIX& operator -= (CONST D3DXMATRIX&); + D3DXMATRIX& operator *= (FLOAT); + D3DXMATRIX& operator /= (FLOAT); + + D3DXMATRIX operator + () const; + D3DXMATRIX operator - () const; + + D3DXMATRIX operator * (CONST D3DXMATRIX&) const; + D3DXMATRIX operator + (CONST D3DXMATRIX&) const; + D3DXMATRIX operator - (CONST D3DXMATRIX&) const; + D3DXMATRIX operator * (FLOAT) const; + D3DXMATRIX operator / (FLOAT) const; + + friend D3DXMATRIX operator * (FLOAT, CONST D3DXMATRIX&); + + BOOL operator == (CONST D3DXMATRIX&) const; + BOOL operator != (CONST D3DXMATRIX&) const; +} D3DXMATRIX, *LPD3DXMATRIX; +#else /* !__cplusplus */ +typedef struct _D3DMATRIX D3DXMATRIX, *LPD3DXMATRIX; +#endif /* !__cplusplus */ + +typedef struct D3DXQUATERNION +{ +#ifdef __cplusplus + D3DXQUATERNION(); + D3DXQUATERNION(CONST FLOAT *pf); + D3DXQUATERNION(FLOAT fx, FLOAT fy, FLOAT fz, FLOAT fw); + + operator FLOAT* (); + operator CONST FLOAT* () const; + + D3DXQUATERNION& operator += (CONST D3DXQUATERNION&); + D3DXQUATERNION& operator -= (CONST D3DXQUATERNION&); + D3DXQUATERNION& operator *= (CONST D3DXQUATERNION&); + D3DXQUATERNION& operator *= (FLOAT); + D3DXQUATERNION& operator /= (FLOAT); + + D3DXQUATERNION operator + () const; + D3DXQUATERNION operator - () const; + + D3DXQUATERNION operator + (CONST D3DXQUATERNION&) const; + D3DXQUATERNION operator - (CONST D3DXQUATERNION&) const; + D3DXQUATERNION operator * (CONST D3DXQUATERNION&) const; + D3DXQUATERNION operator * (FLOAT) const; + D3DXQUATERNION operator / (FLOAT) const; + + friend D3DXQUATERNION operator * (FLOAT, CONST D3DXQUATERNION&); + + BOOL operator == (CONST D3DXQUATERNION&) const; + BOOL operator != (CONST D3DXQUATERNION&) const; +#endif /* __cplusplus */ + FLOAT x, y, z, w; +} D3DXQUATERNION, *LPD3DXQUATERNION; + +typedef struct D3DXPLANE +{ +#ifdef __cplusplus + D3DXPLANE(); + D3DXPLANE(CONST FLOAT *pf); + D3DXPLANE(FLOAT fa, FLOAT fb, FLOAT fc, FLOAT fd); + + operator FLOAT* (); + operator CONST FLOAT* () const; + + D3DXPLANE operator + () const; + D3DXPLANE operator - () const; + + BOOL operator == (CONST D3DXPLANE&) const; + BOOL operator != (CONST D3DXPLANE&) const; +#endif /* __cplusplus */ + FLOAT a, b, c, d; +} D3DXPLANE, *LPD3DXPLANE; + +typedef struct D3DXCOLOR +{ +#ifdef __cplusplus + D3DXCOLOR(); + D3DXCOLOR(DWORD col); + D3DXCOLOR(CONST FLOAT *pf); + D3DXCOLOR(CONST D3DCOLORVALUE& col); + D3DXCOLOR(FLOAT fr, FLOAT fg, FLOAT fb, FLOAT fa); + + operator DWORD () const; + + operator FLOAT* (); + operator CONST FLOAT* () const; + + operator D3DCOLORVALUE* (); + operator CONST D3DCOLORVALUE* () const; + + operator D3DCOLORVALUE& (); + operator CONST D3DCOLORVALUE& () const; + + D3DXCOLOR& operator += (CONST D3DXCOLOR&); + D3DXCOLOR& operator -= (CONST D3DXCOLOR&); + D3DXCOLOR& operator *= (FLOAT); + D3DXCOLOR& operator /= (FLOAT); + + D3DXCOLOR operator + () const; + D3DXCOLOR operator - () const; + + D3DXCOLOR operator + (CONST D3DXCOLOR&) const; + D3DXCOLOR operator - (CONST D3DXCOLOR&) const; + D3DXCOLOR operator * (FLOAT) const; + D3DXCOLOR operator / (FLOAT) const; + + friend D3DXCOLOR operator * (FLOAT, CONST D3DXCOLOR&); + + BOOL operator == (CONST D3DXCOLOR&) const; + BOOL operator != (CONST D3DXCOLOR&) const; +#endif /* __cplusplus */ + FLOAT r, g, b, a; +} D3DXCOLOR, *LPD3DXCOLOR; + +#ifdef __cplusplus +extern "C" { +#endif + +D3DXCOLOR* WINAPI D3DXColorAdjustContrast(D3DXCOLOR *pout, CONST D3DXCOLOR *pc, FLOAT s); +D3DXCOLOR* WINAPI D3DXColorAdjustSaturation(D3DXCOLOR *pout, CONST D3DXCOLOR *pc, FLOAT s); + +FLOAT WINAPI D3DXFresnelTerm(FLOAT costheta, FLOAT refractionindex); + +D3DXMATRIX* WINAPI D3DXMatrixAffineTransformation(D3DXMATRIX *pout, FLOAT scaling, CONST D3DXVECTOR3 *rotationcenter, CONST D3DXQUATERNION *rotation, CONST D3DXVECTOR3 *translation); +FLOAT WINAPI D3DXMatrixfDeterminant(CONST D3DXMATRIX *pm); +D3DXMATRIX* WINAPI D3DXMatrixInverse(D3DXMATRIX *pout, FLOAT *pdeterminant, CONST D3DXMATRIX *pm); +D3DXMATRIX* WINAPI D3DXMatrixLookAtLH(D3DXMATRIX *pout, CONST D3DXVECTOR3 *peye, CONST D3DXVECTOR3 *pat, CONST D3DXVECTOR3 *pup); +D3DXMATRIX* WINAPI D3DXMatrixLookAtRH(D3DXMATRIX *pout, CONST D3DXVECTOR3 *peye, CONST D3DXVECTOR3 *pat, CONST D3DXVECTOR3 *pup); +D3DXMATRIX* WINAPI D3DXMatrixMultiply(D3DXMATRIX *pout, CONST D3DXMATRIX *pm1, CONST D3DXMATRIX *pm2); +D3DXMATRIX* WINAPI D3DXMatrixMultiplyTranspose(D3DXMATRIX *pout, CONST D3DXMATRIX *pm1, CONST D3DXMATRIX *pm2); +D3DXMATRIX* WINAPI D3DXMatrixOrthoLH(D3DXMATRIX *pout, FLOAT w, FLOAT h, FLOAT zn, FLOAT zf); +D3DXMATRIX* WINAPI D3DXMatrixOrthoOffCenterLH(D3DXMATRIX *pout, FLOAT l, FLOAT r, FLOAT b, FLOAT t, FLOAT zn, FLOAT zf); +D3DXMATRIX* WINAPI D3DXMatrixOrthoOffCenterRH(D3DXMATRIX *pout, FLOAT l, FLOAT r, FLOAT b, FLOAT t, FLOAT zn, FLOAT zf); +D3DXMATRIX* WINAPI D3DXMatrixOrthoLH(D3DXMATRIX *pout, FLOAT w, FLOAT h, FLOAT zn, FLOAT zf); +D3DXMATRIX* WINAPI D3DXMatrixOrthoRH(D3DXMATRIX *pout, FLOAT w, FLOAT h, FLOAT zn, FLOAT zf); +D3DXMATRIX* WINAPI D3DXMatrixPerspectiveFovLH(D3DXMATRIX *pout, FLOAT fovy, FLOAT aspect, FLOAT zn, FLOAT zf); +D3DXMATRIX* WINAPI D3DXMatrixPerspectiveFovRH(D3DXMATRIX *pout, FLOAT fovy, FLOAT aspect, FLOAT zn, FLOAT zf); +D3DXMATRIX* WINAPI D3DXMatrixPerspectiveLH(D3DXMATRIX *pout, FLOAT w, FLOAT h, FLOAT zn, FLOAT zf); +D3DXMATRIX* WINAPI D3DXMatrixPerspectiveOffCenterLH(D3DXMATRIX *pout, FLOAT l, FLOAT r, FLOAT b, FLOAT t, FLOAT zn, FLOAT zf); +D3DXMATRIX* WINAPI D3DXMatrixPerspectiveOffCenterRH(D3DXMATRIX *pout, FLOAT l, FLOAT r, FLOAT b, FLOAT t, FLOAT zn, FLOAT zf); +D3DXMATRIX* WINAPI D3DXMatrixPerspectiveRH(D3DXMATRIX *pout, FLOAT w, FLOAT h, FLOAT zn, FLOAT zf); +D3DXMATRIX* WINAPI D3DXMatrixReflect(D3DXMATRIX *pout, CONST D3DXPLANE *pplane); +D3DXMATRIX* WINAPI D3DXMatrixRotationAxis(D3DXMATRIX *pout, CONST D3DXVECTOR3 *pv, FLOAT angle); +D3DXMATRIX* WINAPI D3DXMatrixRotationQuaternion(D3DXMATRIX *pout, CONST D3DXQUATERNION *pq); +D3DXMATRIX* WINAPI D3DXMatrixRotationX(D3DXMATRIX *pout, FLOAT angle); +D3DXMATRIX* WINAPI D3DXMatrixRotationY(D3DXMATRIX *pout, FLOAT angle); +D3DXMATRIX* WINAPI D3DXMatrixRotationYawPitchRoll(D3DXMATRIX *pout, FLOAT yaw, FLOAT pitch, FLOAT roll); +D3DXMATRIX* WINAPI D3DXMatrixRotationZ(D3DXMATRIX *pout, FLOAT angle); +D3DXMATRIX* WINAPI D3DXMatrixScaling(D3DXMATRIX *pout, FLOAT sx, FLOAT sy, FLOAT sz); +D3DXMATRIX* WINAPI D3DXMatrixShadow(D3DXMATRIX *pout, CONST D3DXVECTOR4 *plight, CONST D3DXPLANE *pPlane); +D3DXMATRIX* WINAPI D3DXMatrixTransformation(D3DXMATRIX *pout, CONST D3DXVECTOR3 *pscalingcenter, CONST D3DXQUATERNION *pscalingrotation, CONST D3DXVECTOR3 *pscaling, CONST D3DXVECTOR3 *protationcenter, CONST D3DXQUATERNION *protation, CONST D3DXVECTOR3 *ptranslation); +D3DXMATRIX* WINAPI D3DXMatrixTranslation(D3DXMATRIX *pout, FLOAT x, FLOAT y, FLOAT z); +D3DXMATRIX* WINAPI D3DXMatrixTranspose(D3DXMATRIX *pout, CONST D3DXMATRIX *pm); + +D3DXPLANE* WINAPI D3DXPlaneFromPointNormal(D3DXPLANE *pout, CONST D3DXVECTOR3 *pvpoint, CONST D3DXVECTOR3 *pvnormal); +D3DXPLANE* WINAPI D3DXPlaneFromPoints(D3DXPLANE *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2, CONST D3DXVECTOR3 *pv3); +D3DXVECTOR3* WINAPI D3DXPlaneIntersectLine(D3DXVECTOR3 *pout, CONST D3DXPLANE *pp, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2); +D3DXPLANE* WINAPI D3DXPlaneNormalize(D3DXPLANE *pout, CONST D3DXPLANE *pp); +D3DXPLANE* WINAPI D3DXPlaneTransform(D3DXPLANE *pout, CONST D3DXPLANE *pplane, CONST D3DXMATRIX *pm); + +D3DXQUATERNION* WINAPI D3DXQuaternionBaryCentric(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq1, CONST D3DXQUATERNION *pq2, CONST D3DXQUATERNION *pq3, FLOAT f, FLOAT g); +D3DXQUATERNION* WINAPI D3DXQuaternionExp(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq); +D3DXQUATERNION* WINAPI D3DXQuaternionInverse(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq); +D3DXQUATERNION* WINAPI D3DXQuaternionLn(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq); +D3DXQUATERNION* WINAPI D3DXQuaternionMultiply(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq1, CONST D3DXQUATERNION *pq2); +D3DXQUATERNION* WINAPI D3DXQuaternionNormalize(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq); +D3DXQUATERNION* WINAPI D3DXQuaternionRotationAxis(D3DXQUATERNION *pout, CONST D3DXVECTOR3 *pv, FLOAT angle); +D3DXQUATERNION* WINAPI D3DXQuaternionRotationMatrix(D3DXQUATERNION *pout, CONST D3DXMATRIX *pm); +D3DXQUATERNION* WINAPI D3DXQuaternionRotationYawPitchRoll(D3DXQUATERNION *pout, FLOAT yaw, FLOAT pitch, FLOAT roll); +D3DXQUATERNION* WINAPI D3DXQuaternionSlerp(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq1, CONST D3DXQUATERNION *pq2, FLOAT t); +D3DXQUATERNION* WINAPI D3DXQuaternionSquad(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq1, CONST D3DXQUATERNION *pq2, CONST D3DXQUATERNION *pq3, CONST D3DXQUATERNION *pq4, FLOAT t); +void WINAPI D3DXQuaternionToAxisAngle(CONST D3DXQUATERNION *pq, D3DXVECTOR3 *paxis, FLOAT *pangle); + +D3DXVECTOR2* WINAPI D3DXVec2BaryCentric(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pv2, CONST D3DXVECTOR2 *pv3, FLOAT f, FLOAT g); +D3DXVECTOR2* WINAPI D3DXVec2CatmullRom(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv0, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pv2, CONST D3DXVECTOR2 *pv3, FLOAT s); +D3DXVECTOR2* WINAPI D3DXVec2Hermite(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pt1, CONST D3DXVECTOR2 *pv2, CONST D3DXVECTOR2 *pt2, FLOAT s); +D3DXVECTOR2* WINAPI D3DXVec2Normalize(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv); +D3DXVECTOR4* WINAPI D3DXVec2Transform(D3DXVECTOR4 *pout, CONST D3DXVECTOR2 *pv, CONST D3DXMATRIX *pm); +D3DXVECTOR2* WINAPI D3DXVec2TransformCoord(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv, CONST D3DXMATRIX *pm); +D3DXVECTOR2* WINAPI D3DXVec2TransformNormal(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv, CONST D3DXMATRIX *pm); + +D3DXVECTOR3* WINAPI D3DXVec3BaryCentric(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2, CONST D3DXVECTOR3 *pv3, FLOAT f, FLOAT g); +D3DXVECTOR3* WINAPI D3DXVec3CatmullRom( D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv0, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2, CONST D3DXVECTOR3 *pv3, FLOAT s); +D3DXVECTOR3* WINAPI D3DXVec3Hermite(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pt1, CONST D3DXVECTOR3 *pv2, CONST D3DXVECTOR3 *pt2, FLOAT s); +D3DXVECTOR3* WINAPI D3DXVec3Normalize(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv); +D3DXVECTOR3* WINAPI D3DXVec3Project(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv, CONST D3DVIEWPORT8 *pviewport, CONST D3DXMATRIX *pprojection, CONST D3DXMATRIX *pview, CONST D3DXMATRIX *pworld); +D3DXVECTOR4* WINAPI D3DXVec3Transform(D3DXVECTOR4 *pout, CONST D3DXVECTOR3 *pv, CONST D3DXMATRIX *pm); +D3DXVECTOR3* WINAPI D3DXVec3TransformCoord(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv, CONST D3DXMATRIX *pm); +D3DXVECTOR3* WINAPI D3DXVec3TransformNormal(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv, CONST D3DXMATRIX *pm); +D3DXVECTOR3* WINAPI D3DXVec3Unproject(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv, CONST D3DVIEWPORT8 *pviewport, CONST D3DXMATRIX *pprojection, CONST D3DXMATRIX *pview, CONST D3DXMATRIX *pworld); + +D3DXVECTOR4* WINAPI D3DXVec4BaryCentric(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2, CONST D3DXVECTOR4 *pv3, FLOAT f, FLOAT g); +D3DXVECTOR4* WINAPI D3DXVec4CatmullRom(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv0, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2, CONST D3DXVECTOR4 *pv3, FLOAT s); +D3DXVECTOR4* WINAPI D3DXVec4Cross(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2, CONST D3DXVECTOR4 *pv3); +D3DXVECTOR4* WINAPI D3DXVec4Hermite(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pt1, CONST D3DXVECTOR4 *pv2, CONST D3DXVECTOR4 *pt2, FLOAT s); +D3DXVECTOR4* WINAPI D3DXVec4Normalize(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv); +D3DXVECTOR4* WINAPI D3DXVec4Transform(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv, CONST D3DXMATRIX *pm); + +#ifdef __cplusplus +} +#endif + +#define INTERFACE ID3DXMatrixStack +DECLARE_INTERFACE_(ID3DXMatrixStack, IUnknown) +{ + STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID, LPVOID*) PURE; + STDMETHOD_(ULONG,AddRef)(THIS) PURE; + STDMETHOD_(ULONG,Release)(THIS) PURE; + STDMETHOD(Pop)(THIS) PURE; + STDMETHOD(Push)(THIS) PURE; + STDMETHOD(LoadIdentity)(THIS) PURE; + STDMETHOD(LoadMatrix)(THIS_ CONST D3DXMATRIX *) PURE; + STDMETHOD(MultMatrix)(THIS_ CONST D3DXMATRIX *) PURE; + STDMETHOD(MultMatrixLocal)(THIS_ CONST D3DXMATRIX *) PURE; + STDMETHOD(RotateAxis)(THIS_ CONST D3DXVECTOR3 *, FLOAT) PURE; + STDMETHOD(RotateAxisLocal)(THIS_ CONST D3DXVECTOR3 *, FLOAT) PURE; + STDMETHOD(RotateYawPitchRoll)(THIS_ FLOAT, FLOAT, FLOAT) PURE; + STDMETHOD(RotateYawPitchRollLocal)(THIS_ FLOAT, FLOAT, FLOAT) PURE; + STDMETHOD(Scale)(THIS_ FLOAT, FLOAT, FLOAT) PURE; + STDMETHOD(ScaleLocal)(THIS_ FLOAT, FLOAT, FLOAT) PURE; + STDMETHOD(Translate)(THIS_ FLOAT, FLOAT, FLOAT) PURE; + STDMETHOD(TranslateLocal)(THIS_ FLOAT, FLOAT, FLOAT) PURE; + STDMETHOD_(LPD3DXMATRIX, GetTop)(THIS) PURE; +}; + +#undef INTERFACE + +#if !defined(__cplusplus) || defined(CINTERFACE) + +#define ID3DXMatrixStack_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) +#define ID3DXMatrixStack_AddRef(p) (p)->lpVtbl->AddRef(p) +#define ID3DXMatrixStack_Release(p) (p)->lpVtbl->Release(p) +#define ID3DXMatrixStack_Pop(p) (p)->lpVtbl->Pop(p) +#define ID3DXMatrixStack_Push(p) (p)->lpVtbl->Push(p) +#define ID3DXMatrixStack_LoadIdentity(p) (p)->lpVtbl->LoadIdentity(p) +#define ID3DXMatrixStack_LoadMatrix(p,a) (p)->lpVtbl->LoadMatrix(p,a) +#define ID3DXMatrixStack_MultMatrix(p,a) (p)->lpVtbl->MultMatrix(p,a) +#define ID3DXMatrixStack_MultMatrixLocal(p,a) (p)->lpVtbl->MultMatrixLocal(p,a) +#define ID3DXMatrixStack_RotateAxis(p,a,b) (p)->lpVtbl->RotateAxis(p,a,b) +#define ID3DXMatrixStack_RotateAxisLocal(p,a,b) (p)->lpVtbl->RotateAxisLocal(p,a,b) +#define ID3DXMatrixStack_RotateYawPitchRoll(p,a,b,c) (p)->lpVtbl->RotateYawPitchRoll(p,a,b,c) +#define ID3DXMatrixStack_RotateYawPitchRollLocal(p,a,b,c) (p)->lpVtbl->RotateYawPitchRollLocal(p,a,b,c) +#define ID3DXMatrixStack_Scale(p,a,b,c) (p)->lpVtbl->Scale(p,a,b,c) +#define ID3DXMatrixStack_ScaleLocal(p,a,b,c) (p)->lpVtbl->ScaleLocal(p,a,b,c) +#define ID3DXMatrixStack_Translate(p,a,b,c) (p)->lpVtbl->Translate(p,a,b,c) +#define ID3DXMatrixStack_TranslateLocal(p,a,b,c) (p)->lpVtbl->TranslateLocal(p,a,b,c) +#define ID3DXMatrixStack_GetTop(p) (p)->lpVtbl->GetTop(p) + +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +HRESULT WINAPI D3DXCreateMatrixStack(DWORD flags, LPD3DXMATRIXSTACK* ppstack); + +#ifdef __cplusplus +} +#endif + +#include + +#endif /* __D3DX8MATH_H__ */ diff --git a/include/d3dx8math.inl b/include/d3dx8math.inl new file mode 100644 index 00000000000..01e7af35542 --- /dev/null +++ b/include/d3dx8math.inl @@ -0,0 +1,1268 @@ +/* + * Copyright (C) 2007 David Adam + * Copyright (C) 2007 Tony Wasserka + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#ifndef __D3DX8MATH_INL__ +#define __D3DX8MATH_INL__ + +/* constructors & operators */ +#ifdef __cplusplus + +inline D3DXVECTOR2::D3DXVECTOR2() +{ +} + +inline D3DXVECTOR2::D3DXVECTOR2(CONST FLOAT *pf) +{ + if(!pf) return; + x = pf[0]; + y = pf[1]; +} + +inline D3DXVECTOR2::D3DXVECTOR2(FLOAT fx, FLOAT fy) +{ + x = fx; + y = fy; +} + +inline D3DXVECTOR2::operator FLOAT* () +{ + return (FLOAT*)&x; +} + +inline D3DXVECTOR2::operator CONST FLOAT* () const +{ + return (CONST FLOAT*)&x; +} + +inline D3DXVECTOR2& D3DXVECTOR2::operator += (CONST D3DXVECTOR2& v) +{ + x += v.x; + y += v.y; + return *this; +} + +inline D3DXVECTOR2& D3DXVECTOR2::operator -= (CONST D3DXVECTOR2& v) +{ + x -= v.x; + y -= v.y; + return *this; +} + +inline D3DXVECTOR2& D3DXVECTOR2::operator *= (FLOAT f) +{ + x *= f; + y *= f; + return *this; +} + +inline D3DXVECTOR2& D3DXVECTOR2::operator /= (FLOAT f) +{ + x /= f; + y /= f; + return *this; +} + +inline D3DXVECTOR2 D3DXVECTOR2::operator + () const +{ + return *this; +} + +inline D3DXVECTOR2 D3DXVECTOR2::operator - () const +{ + return D3DXVECTOR2(-x, -y); +} + +inline D3DXVECTOR2 D3DXVECTOR2::operator + (CONST D3DXVECTOR2& v) const +{ + return D3DXVECTOR2(x + v.x, y + v.y); +} + +inline D3DXVECTOR2 D3DXVECTOR2::operator - (CONST D3DXVECTOR2& v) const +{ + return D3DXVECTOR2(x - v.x, y - v.y); +} + +inline D3DXVECTOR2 D3DXVECTOR2::operator * (FLOAT f) const +{ + return D3DXVECTOR2(x * f, y * f); +} + +inline D3DXVECTOR2 D3DXVECTOR2::operator / (FLOAT f) const +{ + return D3DXVECTOR2(x / f, y / f); +} + +inline D3DXVECTOR2 operator * (FLOAT f, CONST D3DXVECTOR2& v) +{ + return D3DXVECTOR2(f * v.x, f * v.y); +} + +inline BOOL D3DXVECTOR2::operator == (CONST D3DXVECTOR2& v) const +{ + return x == v.x && y == v.y; +} + +inline BOOL D3DXVECTOR2::operator != (CONST D3DXVECTOR2& v) const +{ + return x != v.x || y != v.y; +} + +inline D3DXVECTOR3::D3DXVECTOR3() +{ +} + +inline D3DXVECTOR3::D3DXVECTOR3(CONST FLOAT *pf) +{ + if(!pf) return; + x = pf[0]; + y = pf[1]; + z = pf[2]; +} + +inline D3DXVECTOR3::D3DXVECTOR3(CONST D3DVECTOR& v) +{ + x = v.x; + y = v.y; + z = v.z; +} + +inline D3DXVECTOR3::D3DXVECTOR3(FLOAT fx, FLOAT fy, FLOAT fz) +{ + x = fx; + y = fy; + z = fz; +} + +inline D3DXVECTOR3::operator FLOAT* () +{ + return (FLOAT*)&x; +} + +inline D3DXVECTOR3::operator CONST FLOAT* () const +{ + return (CONST FLOAT*)&x; +} + +inline D3DXVECTOR3& D3DXVECTOR3::operator += (CONST D3DXVECTOR3& v) +{ + x += v.x; + y += v.y; + z += v.z; + return *this; +} + +inline D3DXVECTOR3& D3DXVECTOR3::operator -= (CONST D3DXVECTOR3& v) +{ + x -= v.x; + y -= v.y; + z -= v.z; + return *this; +} + +inline D3DXVECTOR3& D3DXVECTOR3::operator *= (FLOAT f) +{ + x *= f; + y *= f; + z *= f; + return *this; +} + +inline D3DXVECTOR3& D3DXVECTOR3::operator /= (FLOAT f) +{ + x /= f; + y /= f; + z /= f; + return *this; +} + +inline D3DXVECTOR3 D3DXVECTOR3::operator + () const +{ + return *this; +} + +inline D3DXVECTOR3 D3DXVECTOR3::operator - () const +{ + return D3DXVECTOR3(-x, -y, -z); +} + +inline D3DXVECTOR3 D3DXVECTOR3::operator + (CONST D3DXVECTOR3& v) const +{ + return D3DXVECTOR3(x + v.x, y + v.y, z + v.z); +} + +inline D3DXVECTOR3 D3DXVECTOR3::operator - (CONST D3DXVECTOR3& v) const +{ + return D3DXVECTOR3(x - v.x, y - v.y, z - v.z); +} + +inline D3DXVECTOR3 D3DXVECTOR3::operator * (FLOAT f) const +{ + return D3DXVECTOR3(x * f, y * f, z * f); +} + +inline D3DXVECTOR3 D3DXVECTOR3::operator / (FLOAT f) const +{ + return D3DXVECTOR3(x / f, y / f, z / f); +} + +inline D3DXVECTOR3 operator * (FLOAT f, CONST D3DXVECTOR3& v) +{ + return D3DXVECTOR3(f * v.x, f * v.y, f * v.z); +} + +inline BOOL D3DXVECTOR3::operator == (CONST D3DXVECTOR3& v) const +{ + return x == v.x && y == v.y && z == v.z; +} + +inline BOOL D3DXVECTOR3::operator != (CONST D3DXVECTOR3& v) const +{ + return x != v.x || y != v.y || z != v.z; +} + +inline D3DXVECTOR4::D3DXVECTOR4() +{ +} + +inline D3DXVECTOR4::D3DXVECTOR4(CONST FLOAT *pf) +{ + if(!pf) return; + x = pf[0]; + y = pf[1]; + z = pf[2]; + w = pf[3]; +} + +inline D3DXVECTOR4::D3DXVECTOR4(FLOAT fx, FLOAT fy, FLOAT fz, FLOAT fw) +{ + x = fx; + y = fy; + z = fz; + w = fw; +} + +inline D3DXVECTOR4::operator FLOAT* () +{ + return (FLOAT*)&x; +} + +inline D3DXVECTOR4::operator CONST FLOAT* () const +{ + return (CONST FLOAT*)&x; +} + +inline D3DXVECTOR4& D3DXVECTOR4::operator += (CONST D3DXVECTOR4& v) +{ + x += v.x; + y += v.y; + z += v.z; + w += v.w; + return *this; +} + +inline D3DXVECTOR4& D3DXVECTOR4::operator -= (CONST D3DXVECTOR4& v) +{ + x -= v.x; + y -= v.y; + z -= v.z; + w -= v.w; + return *this; +} + +inline D3DXVECTOR4& D3DXVECTOR4::operator *= (FLOAT f) +{ + x *= f; + y *= f; + z *= f; + w *= f; + return *this; +} + +inline D3DXVECTOR4& D3DXVECTOR4::operator /= (FLOAT f) +{ + x /= f; + y /= f; + z /= f; + w /= f; + return *this; +} + +inline D3DXVECTOR4 D3DXVECTOR4::operator + () const +{ + return *this; +} + +inline D3DXVECTOR4 D3DXVECTOR4::operator - () const +{ + return D3DXVECTOR4(-x, -y, -z, -w); +} + +inline D3DXVECTOR4 D3DXVECTOR4::operator + (CONST D3DXVECTOR4& v) const +{ + return D3DXVECTOR4(x + v.x, y + v.y, z + v.z, w + v.w); +} + +inline D3DXVECTOR4 D3DXVECTOR4::operator - (CONST D3DXVECTOR4& v) const +{ + return D3DXVECTOR4(x - v.x, y - v.y, z - v.z, w - v.w); +} + +inline D3DXVECTOR4 D3DXVECTOR4::operator * (FLOAT f) const +{ + return D3DXVECTOR4(x * f, y * f, z * f, w * f); +} + +inline D3DXVECTOR4 D3DXVECTOR4::operator / (FLOAT f) const +{ + return D3DXVECTOR4(x / f, y / f, z / f, w / f); +} + +inline D3DXVECTOR4 operator * (FLOAT f, CONST D3DXVECTOR4& v) +{ + return D3DXVECTOR4(f * v.x, f * v.y, f * v.z, f * v.w); +} + +inline BOOL D3DXVECTOR4::operator == (CONST D3DXVECTOR4& v) const +{ + return x == v.x && y == v.y && z == v.z && w == v.w; +} + +inline BOOL D3DXVECTOR4::operator != (CONST D3DXVECTOR4& v) const +{ + return x != v.x || y != v.y || z != v.z || w != v.w; +} + +inline D3DXMATRIX::D3DXMATRIX() +{ +} + +inline D3DXMATRIX::D3DXMATRIX(CONST FLOAT *pf) +{ + if(!pf) return; + memcpy(&_11, pf, sizeof(D3DXMATRIX)); +} + +inline D3DXMATRIX::D3DXMATRIX(CONST D3DMATRIX& mat) +{ + memcpy(&_11, &mat, sizeof(D3DXMATRIX)); +} + +inline D3DXMATRIX::D3DXMATRIX(FLOAT f11, FLOAT f12, FLOAT f13, FLOAT f14, + FLOAT f21, FLOAT f22, FLOAT f23, FLOAT f24, + FLOAT f31, FLOAT f32, FLOAT f33, FLOAT f34, + FLOAT f41, FLOAT f42, FLOAT f43, FLOAT f44) +{ + _11 = f11; _12 = f12; _13 = f13; _14 = f14; + _21 = f21; _22 = f22; _23 = f23; _24 = f24; + _31 = f31; _32 = f32; _33 = f33; _34 = f34; + _41 = f41; _42 = f42; _43 = f43; _44 = f44; +} + +inline FLOAT& D3DXMATRIX::operator () (UINT row, UINT col) +{ + return m[row][col]; +} + +inline FLOAT D3DXMATRIX::operator () (UINT row, UINT col) const +{ + return m[row][col]; +} + +inline D3DXMATRIX::operator FLOAT* () +{ + return (FLOAT*)&_11; +} + +inline D3DXMATRIX::operator CONST FLOAT* () const +{ + return (CONST FLOAT*)&_11; +} + +inline D3DXMATRIX& D3DXMATRIX::operator *= (CONST D3DXMATRIX& mat) +{ + D3DXMatrixMultiply(this, this, &mat); + return *this; +} + +inline D3DXMATRIX& D3DXMATRIX::operator += (CONST D3DXMATRIX& mat) +{ + _11 += mat._11; _12 += mat._12; _13 += mat._13; _14 += mat._14; + _21 += mat._21; _22 += mat._22; _23 += mat._23; _24 += mat._24; + _31 += mat._31; _32 += mat._32; _33 += mat._33; _34 += mat._34; + _41 += mat._41; _42 += mat._42; _43 += mat._43; _44 += mat._44; + return *this; +} + +inline D3DXMATRIX& D3DXMATRIX::operator -= (CONST D3DXMATRIX& mat) +{ + _11 -= mat._11; _12 -= mat._12; _13 -= mat._13; _14 -= mat._14; + _21 -= mat._21; _22 -= mat._22; _23 -= mat._23; _24 -= mat._24; + _31 -= mat._31; _32 -= mat._32; _33 -= mat._33; _34 -= mat._34; + _41 -= mat._41; _42 -= mat._42; _43 -= mat._43; _44 -= mat._44; + return *this; +} + +inline D3DXMATRIX& D3DXMATRIX::operator *= (FLOAT f) +{ + _11 *= f; _12 *= f; _13 *= f; _14 *= f; + _21 *= f; _22 *= f; _23 *= f; _24 *= f; + _31 *= f; _32 *= f; _33 *= f; _34 *= f; + _41 *= f; _42 *= f; _43 *= f; _44 *= f; + return *this; +} + +inline D3DXMATRIX& D3DXMATRIX::operator /= (FLOAT f) +{ + FLOAT inv = 1.0f / f; + _11 *= inv; _12 *= inv; _13 *= inv; _14 *= inv; + _21 *= inv; _22 *= inv; _23 *= inv; _24 *= inv; + _31 *= inv; _32 *= inv; _33 *= inv; _34 *= inv; + _41 *= inv; _42 *= inv; _43 *= inv; _44 *= inv; + return *this; +} + +inline D3DXMATRIX D3DXMATRIX::operator + () const +{ + return *this; +} + +inline D3DXMATRIX D3DXMATRIX::operator - () const +{ + return D3DXMATRIX(-_11, -_12, -_13, -_14, + -_21, -_22, -_23, -_24, + -_31, -_32, -_33, -_34, + -_41, -_42, -_43, -_44); +} + +inline D3DXMATRIX D3DXMATRIX::operator * (CONST D3DXMATRIX& mat) const +{ + D3DXMATRIX buf; + D3DXMatrixMultiply(&buf, this, &mat); + return buf; +} + +inline D3DXMATRIX D3DXMATRIX::operator + (CONST D3DXMATRIX& mat) const +{ + return D3DXMATRIX(_11 + mat._11, _12 + mat._12, _13 + mat._13, _14 + mat._14, + _21 + mat._21, _22 + mat._22, _23 + mat._23, _24 + mat._24, + _31 + mat._31, _32 + mat._32, _33 + mat._33, _34 + mat._34, + _41 + mat._41, _42 + mat._42, _43 + mat._43, _44 + mat._44); +} + +inline D3DXMATRIX D3DXMATRIX::operator - (CONST D3DXMATRIX& mat) const +{ + return D3DXMATRIX(_11 - mat._11, _12 - mat._12, _13 - mat._13, _14 - mat._14, + _21 - mat._21, _22 - mat._22, _23 - mat._23, _24 - mat._24, + _31 - mat._31, _32 - mat._32, _33 - mat._33, _34 - mat._34, + _41 - mat._41, _42 - mat._42, _43 - mat._43, _44 - mat._44); +} + +inline D3DXMATRIX D3DXMATRIX::operator * (FLOAT f) const +{ + return D3DXMATRIX(_11 * f, _12 * f, _13 * f, _14 * f, + _21 * f, _22 * f, _23 * f, _24 * f, + _31 * f, _32 * f, _33 * f, _34 * f, + _41 * f, _42 * f, _43 * f, _44 * f); +} + +inline D3DXMATRIX D3DXMATRIX::operator / (FLOAT f) const +{ + FLOAT inv = 1.0f / f; + return D3DXMATRIX(_11 * inv, _12 * inv, _13 * inv, _14 * inv, + _21 * inv, _22 * inv, _23 * inv, _24 * inv, + _31 * inv, _32 * inv, _33 * inv, _34 * inv, + _41 * inv, _42 * inv, _43 * inv, _44 * inv); +} + +inline D3DXMATRIX operator * (FLOAT f, CONST D3DXMATRIX& mat) +{ + return D3DXMATRIX(f * mat._11, f * mat._12, f * mat._13, f * mat._14, + f * mat._21, f * mat._22, f * mat._23, f * mat._24, + f * mat._31, f * mat._32, f * mat._33, f * mat._34, + f * mat._41, f * mat._42, f * mat._43, f * mat._44); +} + +inline BOOL D3DXMATRIX::operator == (CONST D3DXMATRIX& mat) const +{ + return (memcmp(this, &mat, sizeof(D3DXMATRIX)) == 0); +} + +inline BOOL D3DXMATRIX::operator != (CONST D3DXMATRIX& mat) const +{ + return (memcmp(this, &mat, sizeof(D3DXMATRIX)) != 0); +} + +inline D3DXQUATERNION::D3DXQUATERNION() +{ +} + +inline D3DXQUATERNION::D3DXQUATERNION(CONST FLOAT *pf) +{ + if(!pf) return; + x = pf[0]; + y = pf[1]; + z = pf[2]; + w = pf[3]; +} + +inline D3DXQUATERNION::D3DXQUATERNION(FLOAT fx, FLOAT fy, FLOAT fz, FLOAT fw) +{ + x = fx; + y = fy; + z = fz; + w = fw; +} + +inline D3DXQUATERNION::operator FLOAT* () +{ + return (FLOAT*)&x; +} + +inline D3DXQUATERNION::operator CONST FLOAT* () const +{ + return (CONST FLOAT*)&x; +} + +inline D3DXQUATERNION& D3DXQUATERNION::operator += (CONST D3DXQUATERNION& quat) +{ + x += quat.x; + y += quat.y; + z += quat.z; + w += quat.w; + return *this; +} + +inline D3DXQUATERNION& D3DXQUATERNION::operator -= (CONST D3DXQUATERNION& quat) +{ + x -= quat.x; + y -= quat.y; + z -= quat.z; + w -= quat.w; + return *this; +} + +/* TODO: uncomment this when D3DXQuaternionMultiply has been implemented +inline D3DXQUATERNION& D3DXQUATERNION::operator *= (CONST D3DXQUATERNION& quat) +{ + D3DXQuaternionMultiply(this, this, &quat); + return *this; +} +*/ + +inline D3DXQUATERNION& D3DXQUATERNION::operator *= (FLOAT f) +{ + x *= f; + y *= f; + z *= f; + w *= f; + return *this; +} + +inline D3DXQUATERNION& D3DXQUATERNION::operator /= (FLOAT f) +{ + FLOAT inv = 1.0f / f; + x *= inv; + y *= inv; + z *= inv; + w *= inv; + return *this; +} + +inline D3DXQUATERNION D3DXQUATERNION::operator + () const +{ + return *this; +} + +inline D3DXQUATERNION D3DXQUATERNION::operator - () const +{ + return D3DXQUATERNION(-x, -y, -z, -w); +} + +inline D3DXQUATERNION D3DXQUATERNION::operator + (CONST D3DXQUATERNION& quat) const +{ + return D3DXQUATERNION(x + quat.x, y + quat.y, z + quat.z, w + quat.w); +} + +inline D3DXQUATERNION D3DXQUATERNION::operator - (CONST D3DXQUATERNION& quat) const +{ + return D3DXQUATERNION(x - quat.x, y - quat.y, z - quat.z, w - quat.w); +} + +/* TODO: uncomment this when D3DXQuaternionMultiply has been implemented +inline D3DXQUATERNION D3DXQUATERNION::operator * (CONST D3DXQUATERNION& quat) const +{ + D3DXQUATERNION buf; + D3DXQuaternionMultiply(&buf, this, &quat); + return buf; +} +*/ + +inline D3DXQUATERNION D3DXQUATERNION::operator * (FLOAT f) const +{ + return D3DXQUATERNION(x * f, y * f, z * f, w * f); +} + +inline D3DXQUATERNION D3DXQUATERNION::operator / (FLOAT f) const +{ + FLOAT inv = 1.0f / f; + return D3DXQUATERNION(x * inv, y * inv, z * inv, w * inv); +} + +inline D3DXQUATERNION operator * (FLOAT f, CONST D3DXQUATERNION& quat) +{ + return D3DXQUATERNION(f * quat.x, f * quat.y, f * quat.z, f * quat.w); +} + +inline BOOL D3DXQUATERNION::operator == (CONST D3DXQUATERNION& quat) const +{ + return x == quat.x && y == quat.y && z == quat.z && w == quat.w; +} + +inline BOOL D3DXQUATERNION::operator != (CONST D3DXQUATERNION& quat) const +{ + return x != quat.x || y != quat.y || z != quat.z || w != quat.w; +} + +inline D3DXPLANE::D3DXPLANE() +{ +} + +inline D3DXPLANE::D3DXPLANE(CONST FLOAT *pf) +{ + if(!pf) return; + a = pf[0]; + b = pf[1]; + c = pf[2]; + d = pf[3]; +} + +inline D3DXPLANE::D3DXPLANE(FLOAT fa, FLOAT fb, FLOAT fc, FLOAT fd) +{ + a = fa; + b = fb; + c = fc; + d = fd; +} + +inline D3DXPLANE::operator FLOAT* () +{ + return (FLOAT*)&a; +} + +inline D3DXPLANE::operator CONST FLOAT* () const +{ + return (CONST FLOAT*)&a; +} + +inline D3DXPLANE D3DXPLANE::operator + () const +{ + return *this; +} + +inline D3DXPLANE D3DXPLANE::operator - () const +{ + return D3DXPLANE(-a, -b, -c, -d); +} + +inline BOOL D3DXPLANE::operator == (CONST D3DXPLANE& pl) const +{ + return a == pl.a && b == pl.b && c == pl.c && d == pl.d; +} + +inline BOOL D3DXPLANE::operator != (CONST D3DXPLANE& pl) const +{ + return a != pl.a || b != pl.b || c != pl.c || d != pl.d; +} + +inline D3DXCOLOR::D3DXCOLOR() +{ +} + +inline D3DXCOLOR::D3DXCOLOR(DWORD col) +{ + CONST FLOAT f = 1.0f / 255.0f; + r = f * (FLOAT)(unsigned char)(col >> 16); + g = f * (FLOAT)(unsigned char)(col >> 8); + b = f * (FLOAT)(unsigned char)col; + a = f * (FLOAT)(unsigned char)(col >> 24); +} + +inline D3DXCOLOR::D3DXCOLOR(CONST FLOAT *pf) +{ + if(!pf) return; + r = pf[0]; + g = pf[1]; + b = pf[2]; + a = pf[3]; +} + +inline D3DXCOLOR::D3DXCOLOR(CONST D3DCOLORVALUE& col) +{ + r = col.r; + g = col.g; + b = col.b; + a = col.a; +} + +inline D3DXCOLOR::D3DXCOLOR(FLOAT fr, FLOAT fg, FLOAT fb, FLOAT fa) +{ + r = fr; + g = fg; + b = fb; + a = fa; +} + +inline D3DXCOLOR::operator DWORD () const +{ + DWORD _r = r >= 1.0f ? 0xff : r <= 0.0f ? 0x00 : (DWORD)(r * 255.0f + 0.5f); + DWORD _g = g >= 1.0f ? 0xff : g <= 0.0f ? 0x00 : (DWORD)(g * 255.0f + 0.5f); + DWORD _b = b >= 1.0f ? 0xff : b <= 0.0f ? 0x00 : (DWORD)(b * 255.0f + 0.5f); + DWORD _a = a >= 1.0f ? 0xff : a <= 0.0f ? 0x00 : (DWORD)(a * 255.0f + 0.5f); + + return (_a << 24) | (_r << 16) | (_g << 8) | _b; +} + +inline D3DXCOLOR::operator FLOAT * () +{ + return (FLOAT*)&r; +} + +inline D3DXCOLOR::operator CONST FLOAT * () const +{ + return (CONST FLOAT*)&r; +} + +inline D3DXCOLOR::operator D3DCOLORVALUE * () +{ + return (D3DCOLORVALUE*)&r; +} + +inline D3DXCOLOR::operator CONST D3DCOLORVALUE * () const +{ + return (CONST D3DCOLORVALUE*)&r; +} + +inline D3DXCOLOR::operator D3DCOLORVALUE& () +{ + return *((D3DCOLORVALUE*)&r); +} + +inline D3DXCOLOR::operator CONST D3DCOLORVALUE& () const +{ + return *((CONST D3DCOLORVALUE*)&r); +} + +inline D3DXCOLOR& D3DXCOLOR::operator += (CONST D3DXCOLOR& col) +{ + r += col.r; + g += col.g; + b += col.b; + a += col.a; + return *this; +} + +inline D3DXCOLOR& D3DXCOLOR::operator -= (CONST D3DXCOLOR& col) +{ + r -= col.r; + g -= col.g; + b -= col.b; + a -= col.a; + return *this; +} + +inline D3DXCOLOR& D3DXCOLOR::operator *= (FLOAT f) +{ + r *= f; + g *= f; + b *= f; + a *= f; + return *this; +} + +inline D3DXCOLOR& D3DXCOLOR::operator /= (FLOAT f) +{ + FLOAT inv = 1.0f / f; + r *= inv; + g *= inv; + b *= inv; + a *= inv; + return *this; +} + +inline D3DXCOLOR D3DXCOLOR::operator + () const +{ + return *this; +} + +inline D3DXCOLOR D3DXCOLOR::operator - () const +{ + return D3DXCOLOR(-r, -g, -b, -a); +} + +inline D3DXCOLOR D3DXCOLOR::operator + (CONST D3DXCOLOR& col) const +{ + return D3DXCOLOR(r + col.r, g + col.g, b + col.b, a + col.a); +} + +inline D3DXCOLOR D3DXCOLOR::operator - (CONST D3DXCOLOR& col) const +{ + return D3DXCOLOR(r - col.r, g - col.g, b - col.b, a - col.a); +} + +inline D3DXCOLOR D3DXCOLOR::operator * (FLOAT f) const +{ + return D3DXCOLOR(r * f, g * f, b * f, a * f); +} + +inline D3DXCOLOR D3DXCOLOR::operator / (FLOAT f) const +{ + FLOAT inv = 1.0f / f; + return D3DXCOLOR(r * inv, g * inv, b * inv, a * inv); +} + +inline D3DXCOLOR operator * (FLOAT f, CONST D3DXCOLOR& col) +{ + return D3DXCOLOR(f * col.r, f * col.g, f * col.b, f * col.a); +} + +inline BOOL D3DXCOLOR::operator == (CONST D3DXCOLOR& col) const +{ + return r == col.r && g == col.g && b == col.b && a == col.a; +} + +inline BOOL D3DXCOLOR::operator != (CONST D3DXCOLOR& col) const +{ + return r != col.r || g != col.g || b != col.b || a != col.a; +} + +#endif /* __cplusplus */ + +/*_______________D3DXCOLOR_____________________*/ + +static inline D3DXCOLOR* D3DXColorAdd(D3DXCOLOR *pout, CONST D3DXCOLOR *pc1, CONST D3DXCOLOR *pc2) +{ + if ( !pout || !pc1 || !pc2 ) return NULL; + pout->r = (pc1->r) + (pc2->r); + pout->g = (pc1->g) + (pc2->g); + pout->b = (pc1->b) + (pc2->b); + pout->a = (pc1->a) + (pc2->a); + return pout; +} + +static inline D3DXCOLOR* D3DXColorLerp(D3DXCOLOR *pout, CONST D3DXCOLOR *pc1, CONST D3DXCOLOR *pc2, FLOAT s) +{ + if ( !pout || !pc1 || !pc2 ) return NULL; + pout->r = (1-s) * (pc1->r) + s *(pc2->r); + pout->g = (1-s) * (pc1->g) + s *(pc2->g); + pout->b = (1-s) * (pc1->b) + s *(pc2->b); + pout->a = (1-s) * (pc1->a) + s *(pc2->a); + return pout; +} + +static inline D3DXCOLOR* D3DXColorModulate(D3DXCOLOR *pout, CONST D3DXCOLOR *pc1, CONST D3DXCOLOR *pc2) +{ + if ( !pout || !pc1 || !pc2 ) return NULL; + pout->r = (pc1->r) * (pc2->r); + pout->g = (pc1->g) * (pc2->g); + pout->b = (pc1->b) * (pc2->b); + pout->a = (pc1->a) * (pc2->a); + return pout; +} + +static inline D3DXCOLOR* D3DXColorNegative(D3DXCOLOR *pout, CONST D3DXCOLOR *pc) +{ + if ( !pout || !pc ) return NULL; + pout->r = 1.0f - pc->r; + pout->g = 1.0f - pc->g; + pout->b = 1.0f - pc->b; + pout->a = pc->a; + return pout; +} + +static inline D3DXCOLOR* D3DXColorScale(D3DXCOLOR *pout, CONST D3DXCOLOR *pc, FLOAT s) +{ + if ( !pout || !pc ) return NULL; + pout->r = s* (pc->r); + pout->g = s* (pc->g); + pout->b = s* (pc->b); + pout->a = s* (pc->a); + return pout; +} + +static inline D3DXCOLOR* D3DXColorSubtract(D3DXCOLOR *pout, CONST D3DXCOLOR *pc1, CONST D3DXCOLOR *pc2) +{ + if ( !pout || !pc1 || !pc2 ) return NULL; + pout->r = (pc1->r) - (pc2->r); + pout->g = (pc1->g) - (pc2->g); + pout->b = (pc1->b) - (pc2->b); + pout->a = (pc1->a) - (pc2->a); + return pout; +} + +/*_______________D3DXVECTOR2________________________*/ + +static inline D3DXVECTOR2* D3DXVec2Add(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pv2) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = pv1->x + pv2->x; + pout->y = pv1->y + pv2->y; + return pout; +} + +static inline FLOAT D3DXVec2CCW(CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pv2) +{ + if ( !pv1 || !pv2) return 0.0f; + return ( (pv1->x) * (pv2->y) - (pv1->y) * (pv2->x) ); +} + +static inline FLOAT D3DXVec2Dot(CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pv2) +{ + if ( !pv1 || !pv2) return 0.0f; + return ( (pv1->x * pv2->x + pv1->y * pv2->y) ); +} + +static inline FLOAT D3DXVec2Length(CONST D3DXVECTOR2 *pv) +{ + if (!pv) return 0.0f; + return sqrt( (pv->x) * (pv->x) + (pv->y) * (pv->y) ); +} + +static inline FLOAT D3DXVec2LengthSq(CONST D3DXVECTOR2 *pv) +{ + if (!pv) return 0.0f; + return( (pv->x) * (pv->x) + (pv->y) * (pv->y) ); +} + +static inline D3DXVECTOR2* D3DXVec2Lerp(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pv2, FLOAT s) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = (1-s) * (pv1->x) + s * (pv2->x); + pout->y = (1-s) * (pv1->y) + s * (pv2->y); + return pout; +} + +static inline D3DXVECTOR2* D3DXVec2Maximize(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pv2) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = max(pv1->x , pv2->x); + pout->y = max(pv1->y , pv2->y); + return pout; +} + +static inline D3DXVECTOR2* D3DXVec2Minimize(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pv2) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = min(pv1->x , pv2->x); + pout->y = min(pv1->y , pv2->y); + return pout; +} + +static inline D3DXVECTOR2* D3DXVec2Scale(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv, FLOAT s) +{ + if ( !pout || !pv) return NULL; + pout->x = s * (pv->x); + pout->y = s * (pv->y); + return pout; +} + +static inline D3DXVECTOR2* D3DXVec2Subtract(D3DXVECTOR2 *pout, CONST D3DXVECTOR2 *pv1, CONST D3DXVECTOR2 *pv2) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = pv1->x - pv2->x; + pout->y = pv1->y - pv2->y; + return pout; +} + +/*__________________D3DXVECTOR3_______________________*/ + +static inline D3DXVECTOR3* D3DXVec3Add(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = pv1->x + pv2->x; + pout->y = pv1->y + pv2->y; + pout->z = pv1->z + pv2->z; + return pout; +} + +static inline D3DXVECTOR3* D3DXVec3Cross(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = (pv1->y) * (pv2->z) - (pv1->z) * (pv2->y); + pout->y = (pv1->z) * (pv2->x) - (pv1->x) * (pv2->z); + pout->z = (pv1->x) * (pv2->y) - (pv1->y) * (pv2->x); + return pout; +} + +static inline FLOAT D3DXVec3Dot(CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2) +{ + if ( !pv1 || !pv2 ) return 0.0f; + return (pv1->x) * (pv2->x) + (pv1->y) * (pv2->y) + (pv1->z) * (pv2->z); +} + +static inline FLOAT D3DXVec3Length(CONST D3DXVECTOR3 *pv) +{ + if (!pv) return 0.0f; + return sqrt( (pv->x) * (pv->x) + (pv->y) * (pv->y) + (pv->z) * (pv->z) ); +} + +static inline FLOAT D3DXVec3LengthSq(CONST D3DXVECTOR3 *pv) +{ + if (!pv) return 0.0f; + return (pv->x) * (pv->x) + (pv->y) * (pv->y) + (pv->z) * (pv->z); +} + +static inline D3DXVECTOR3* D3DXVec3Lerp(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2, FLOAT s) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = (1-s) * (pv1->x) + s * (pv2->x); + pout->y = (1-s) * (pv1->y) + s * (pv2->y); + pout->z = (1-s) * (pv1->z) + s * (pv2->z); + return pout; +} + +static inline D3DXVECTOR3* D3DXVec3Maximize(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = max(pv1->x , pv2->x); + pout->y = max(pv1->y , pv2->y); + pout->z = max(pv1->z , pv2->z); + return pout; +} + +static inline D3DXVECTOR3* D3DXVec3Minimize(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = min(pv1->x , pv2->x); + pout->y = min(pv1->y , pv2->y); + pout->z = min(pv1->z , pv2->z); + return pout; +} + +static inline D3DXVECTOR3* D3DXVec3Scale(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv, FLOAT s) +{ + if ( !pout || !pv) return NULL; + pout->x = s * (pv->x); + pout->y = s * (pv->y); + pout->z = s * (pv->z); + return pout; +} + +static inline D3DXVECTOR3* D3DXVec3Subtract(D3DXVECTOR3 *pout, CONST D3DXVECTOR3 *pv1, CONST D3DXVECTOR3 *pv2) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = pv1->x - pv2->x; + pout->y = pv1->y - pv2->y; + pout->z = pv1->z - pv2->z; + return pout; +} +/*__________________D3DXVECTOR4_______________________*/ + +static inline D3DXVECTOR4* D3DXVec4Add(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = pv1->x + pv2->x; + pout->y = pv1->y + pv2->y; + pout->z = pv1->z + pv2->z; + pout->w = pv1->w + pv2->w; + return pout; +} + +static inline FLOAT D3DXVec4Dot(CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2) +{ + if (!pv1 || !pv2 ) return 0.0f; + return (pv1->x) * (pv2->x) + (pv1->y) * (pv2->y) + (pv1->z) * (pv2->z) + (pv1->w) * (pv2->w); +} + +static inline FLOAT D3DXVec4Length(CONST D3DXVECTOR4 *pv) +{ + if (!pv) return 0.0f; + return sqrt( (pv->x) * (pv->x) + (pv->y) * (pv->y) + (pv->z) * (pv->z) + (pv->w) * (pv->w) ); +} + +static inline FLOAT D3DXVec4LengthSq(CONST D3DXVECTOR4 *pv) +{ + if (!pv) return 0.0f; + return (pv->x) * (pv->x) + (pv->y) * (pv->y) + (pv->z) * (pv->z) + (pv->w) * (pv->w); +} + +static inline D3DXVECTOR4* D3DXVec4Lerp(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2, FLOAT s) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = (1-s) * (pv1->x) + s * (pv2->x); + pout->y = (1-s) * (pv1->y) + s * (pv2->y); + pout->z = (1-s) * (pv1->z) + s * (pv2->z); + pout->w = (1-s) * (pv1->w) + s * (pv2->w); + return pout; +} + + +static inline D3DXVECTOR4* D3DXVec4Maximize(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = max(pv1->x , pv2->x); + pout->y = max(pv1->y , pv2->y); + pout->z = max(pv1->z , pv2->z); + pout->w = max(pv1->w , pv2->w); + return pout; +} + +static inline D3DXVECTOR4* D3DXVec4Minimize(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = min(pv1->x , pv2->x); + pout->y = min(pv1->y , pv2->y); + pout->z = min(pv1->z , pv2->z); + pout->w = min(pv1->w , pv2->w); + return pout; +} + +static inline D3DXVECTOR4* D3DXVec4Scale(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv, FLOAT s) +{ + if ( !pout || !pv) return NULL; + pout->x = s * (pv->x); + pout->y = s * (pv->y); + pout->z = s * (pv->z); + pout->w = s * (pv->w); + return pout; +} + +static inline D3DXVECTOR4* D3DXVec4Subtract(D3DXVECTOR4 *pout, CONST D3DXVECTOR4 *pv1, CONST D3DXVECTOR4 *pv2) +{ + if ( !pout || !pv1 || !pv2) return NULL; + pout->x = pv1->x - pv2->x; + pout->y = pv1->y - pv2->y; + pout->z = pv1->z - pv2->z; + pout->w = pv1->w - pv2->w; + return pout; +} + +/*__________________D3DXMatrix____________________*/ +#ifdef NONAMELESSUNION +# define D3DX_U(x) (x).u +#else +# define D3DX_U(x) (x) +#endif + +static inline D3DXMATRIX* D3DXMatrixIdentity(D3DXMATRIX *pout) +{ + if ( !pout ) return NULL; + D3DX_U(*pout).m[0][1] = 0.0f; + D3DX_U(*pout).m[0][2] = 0.0f; + D3DX_U(*pout).m[0][3] = 0.0f; + D3DX_U(*pout).m[1][0] = 0.0f; + D3DX_U(*pout).m[1][2] = 0.0f; + D3DX_U(*pout).m[1][3] = 0.0f; + D3DX_U(*pout).m[2][0] = 0.0f; + D3DX_U(*pout).m[2][1] = 0.0f; + D3DX_U(*pout).m[2][3] = 0.0f; + D3DX_U(*pout).m[3][0] = 0.0f; + D3DX_U(*pout).m[3][1] = 0.0f; + D3DX_U(*pout).m[3][2] = 0.0f; + D3DX_U(*pout).m[0][0] = 1.0f; + D3DX_U(*pout).m[1][1] = 1.0f; + D3DX_U(*pout).m[2][2] = 1.0f; + D3DX_U(*pout).m[3][3] = 1.0f; + return pout; +} + +static inline BOOL D3DXMatrixIsIdentity(D3DXMATRIX *pm) +{ + int i,j; + D3DXMATRIX testmatrix; + + if ( !pm ) return FALSE; + D3DXMatrixIdentity(&testmatrix); + for (i=0; i<4; i++) + { + for (j=0; j<4; j++) + { + if ( D3DX_U(*pm).m[i][j] != D3DX_U(testmatrix).m[i][j] ) return FALSE; + } + } + return TRUE; +} +#undef D3DX_U + +/*__________________D3DXPLANE____________________*/ + +static inline FLOAT D3DXPlaneDot(CONST D3DXPLANE *pp, CONST D3DXVECTOR4 *pv) +{ + if ( !pp || !pv ) return 0.0f; + return ( (pp->a) * (pv->x) + (pp->b) * (pv->y) + (pp->c) * (pv->z) + (pp->d) * (pv->w) ); +} + +static inline FLOAT D3DXPlaneDotCoord(CONST D3DXPLANE *pp, CONST D3DXVECTOR4 *pv) +{ + if ( !pp || !pv ) return 0.0f; + return ( (pp->a) * (pv->x) + (pp->b) * (pv->y) + (pp->c) * (pv->z) + (pp->d) ); +} + +static inline FLOAT D3DXPlaneDotNormal(CONST D3DXPLANE *pp, CONST D3DXVECTOR4 *pv) +{ + if ( !pp || !pv ) return 0.0f; + return ( (pp->a) * (pv->x) + (pp->b) * (pv->y) + (pp->c) * (pv->z) ); +} + +/*__________________D3DXQUATERNION____________________*/ + +static inline D3DXQUATERNION* D3DXQuaternionConjugate(D3DXQUATERNION *pout, CONST D3DXQUATERNION *pq) +{ + if ( !pout || !pq) return NULL; + pout->x = -pq->x; + pout->y = -pq->y; + pout->z = -pq->z; + pout->w = pq->w; + return pout; +} + +static inline FLOAT D3DXQuaternionDot(CONST D3DXQUATERNION *pq1, CONST D3DXQUATERNION *pq2) +{ + if ( !pq1 || !pq2 ) return 0.0f; + return (pq1->x) * (pq2->x) + (pq1->y) * (pq2->y) + (pq1->z) * (pq2->z) + (pq1->w) * (pq2->w); +} + +static inline D3DXQUATERNION* D3DXQuaternionIdentity(D3DXQUATERNION *pout) +{ + if ( !pout) return NULL; + pout->x = 0.0f; + pout->y = 0.0f; + pout->z = 0.0f; + pout->w = 1.0f; + return pout; +} + +static inline BOOL D3DXQuaternionIsIdentity(D3DXQUATERNION *pq) +{ + if ( !pq) return FALSE; + return ( (pq->x == 0.0f) && (pq->y == 0.0f) && (pq->z == 0.0f) && (pq->w == 1.0f) ); +} + +static inline FLOAT D3DXQuaternionLength(CONST D3DXQUATERNION *pq) +{ + if (!pq) return 0.0f; + return sqrt( (pq->x) * (pq->x) + (pq->y) * (pq->y) + (pq->z) * (pq->z) + (pq->w) * (pq->w) ); +} + +static inline FLOAT D3DXQuaternionLengthSq(CONST D3DXQUATERNION *pq) +{ + if (!pq) return 0.0f; + return (pq->x) * (pq->x) + (pq->y) * (pq->y) + (pq->z) * (pq->z) + (pq->w) * (pq->w); +} + +#endif diff --git a/include/d3dx8mesh.h b/include/d3dx8mesh.h new file mode 100644 index 00000000000..7f9262d0680 --- /dev/null +++ b/include/d3dx8mesh.h @@ -0,0 +1,41 @@ +/* + * Copyright (C) 2008 Francois Gouget + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#ifndef __WINE_D3DX8MESH_H +#define __WINE_D3DX8MESH_H + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +HRESULT WINAPI D3DXCreateBuffer(DWORD,LPD3DXBUFFER*); +UINT WINAPI D3DXGetFVFVertexSize(DWORD); +BOOL WINAPI D3DXBoxBoundProbe(CONST D3DXVECTOR3 *, CONST D3DXVECTOR3 *, CONST D3DXVECTOR3 *, CONST D3DXVECTOR3 *); +BOOL WINAPI D3DXSphereBoundProbe(CONST D3DXVECTOR3 *,FLOAT,CONST D3DXVECTOR3 *,CONST D3DXVECTOR3 *); +BOOL CDECL D3DXIntersectTri(CONST D3DXVECTOR3 *, CONST D3DXVECTOR3 *, CONST D3DXVECTOR3 *, CONST D3DXVECTOR3 *, CONST D3DXVECTOR3 *, FLOAT *, FLOAT *, FLOAT *); +HRESULT WINAPI D3DXComputeBoundingBox(PVOID, DWORD, DWORD, D3DXVECTOR3 *, D3DXVECTOR3 *); +HRESULT WINAPI D3DXComputeBoundingSphere(PVOID, DWORD, DWORD, D3DXVECTOR3 *, FLOAT *); + +#ifdef __cplusplus +} +#endif + +#endif /* __WINE_D3DX8MESH_H */ diff --git a/include/d3dx9math.h b/include/d3dx9math.h index f842e3ece3f..83b87493a5a 100644 --- a/include/d3dx9math.h +++ b/include/d3dx9math.h @@ -30,8 +30,6 @@ #define D3DXToRadian(degree) ((degree) * (D3DX_PI / 180.0f)) #define D3DXToDegree(radian) ((radian) * (180.0f / D3DX_PI)) - - typedef struct D3DXVECTOR2 { #ifdef __cplusplus @@ -268,11 +266,9 @@ extern "C" { D3DXCOLOR* WINAPI D3DXColorAdjustContrast(D3DXCOLOR *pout, CONST D3DXCOLOR *pc, FLOAT s); D3DXCOLOR* WINAPI D3DXColorAdjustSaturation(D3DXCOLOR *pout, CONST D3DXCOLOR *pc, FLOAT s); -FLOAT WINAPI D3DXFresnelTerm(FLOAT costheta, FLOAT refractionindex); - -D3DXMATRIX* WINAPI D3DXMatrixAffineTransformation(D3DXMATRIX *pout, FLOAT scaling, CONST D3DXVECTOR3 *rotationcenter, CONST D3DXQUATERNION *rotation, CONST D3DXVECTOR3 *translation); +D3DXMATRIX* WINAPI D3DXMatrixAffineTransformation(D3DXMATRIX *pout, float scaling, D3DXVECTOR3 *rotationcenter, D3DXQUATERNION *rotation, D3DXVECTOR3 *translation); D3DXMATRIX* WINAPI D3DXMatrixAffineTransformation2D(D3DXMATRIX *pout, FLOAT scaling, CONST D3DXVECTOR2 *protationcenter, FLOAT rotation, CONST D3DXVECTOR2 *ptranslation); -HRESULT WINAPI D3DXMatrixDecompose(D3DXVECTOR3 *poutscale, D3DXQUATERNION *poutrotation, D3DXVECTOR3 *pouttranslation, CONST D3DXMATRIX *pm); +HRESULT WINAPI D3DXMatrixDecompose(D3DXVECTOR3 *poutscale, D3DXQUATERNION *poutrotation, D3DXVECTOR3 *pouttranslation, D3DXMATRIX *pm); FLOAT WINAPI D3DXMatrixDeterminant(CONST D3DXMATRIX *pm); D3DXMATRIX* WINAPI D3DXMatrixInverse(D3DXMATRIX *pout, FLOAT *pdeterminant, CONST D3DXMATRIX *pm); D3DXMATRIX* WINAPI D3DXMatrixLookAtLH(D3DXMATRIX *pout, CONST D3DXVECTOR3 *peye, CONST D3DXVECTOR3 *pat, CONST D3DXVECTOR3 *pup); @@ -362,71 +358,6 @@ D3DXVECTOR4* WINAPI D3DXVec4TransformArray(D3DXVECTOR4 *pout, UINT outstride, CO } #endif -typedef interface ID3DXMatrixStack *LPD3DXMATRIXSTACK; - -DEFINE_GUID(IID_ID3DXMatrixStack, -0xc7885ba7, 0xf990, 0x4fe7, 0x92, 0x2d, 0x85, 0x15, 0xe4, 0x77, 0xdd, 0x85); - -#undef INTERFACE -#define INTERFACE ID3DXMatrixStack - -DECLARE_INTERFACE_(ID3DXMatrixStack, IUnknown) -{ - STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID * ppvObj) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - STDMETHOD(Pop)(THIS) PURE; - STDMETHOD(Push)(THIS) PURE; - STDMETHOD(LoadIdentity)(THIS) PURE; - STDMETHOD(LoadMatrix)(THIS_ CONST D3DXMATRIX* pM ) PURE; - STDMETHOD(MultMatrix)(THIS_ CONST D3DXMATRIX* pM ) PURE; - STDMETHOD(MultMatrixLocal)(THIS_ CONST D3DXMATRIX* pM ) PURE; - STDMETHOD(RotateAxis)(THIS_ CONST D3DXVECTOR3* pV, FLOAT Angle) PURE; - STDMETHOD(RotateAxisLocal)(THIS_ CONST D3DXVECTOR3* pV, FLOAT Angle) PURE; - STDMETHOD(RotateYawPitchRoll)(THIS_ FLOAT Yaw, FLOAT Pitch, FLOAT Roll) PURE; - STDMETHOD(RotateYawPitchRollLocal)(THIS_ FLOAT Yaw, FLOAT Pitch, FLOAT Roll) PURE; - STDMETHOD(Scale)(THIS_ FLOAT x, FLOAT y, FLOAT z) PURE; - STDMETHOD(ScaleLocal)(THIS_ FLOAT x, FLOAT y, FLOAT z) PURE; - STDMETHOD(Translate)(THIS_ FLOAT x, FLOAT y, FLOAT z ) PURE; - STDMETHOD(TranslateLocal)(THIS_ FLOAT x, FLOAT y, FLOAT z) PURE; - STDMETHOD_(D3DXMATRIX*, GetTop)(THIS) PURE; -}; - -#undef INTERFACE - -#if !defined(__cplusplus) || defined(CINTERFACE) - -#define ID3DXMatrixStack_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define ID3DXMatrixStack_AddRef(p) (p)->lpVtbl->AddRef(p) -#define ID3DXMatrixStack_Release(p) (p)->lpVtbl->Release(p) -#define ID3DXMatrixStack_Pop(p) (p)->lpVtbl->Pop(p) -#define ID3DXMatrixStack_Push(p) (p)->lpVtbl->Push(p) -#define ID3DXMatrixStack_LoadIdentity(p) (p)->lpVtbl->LoadIdentity(p) -#define ID3DXMatrixStack_LoadMatrix(p,a) (p)->lpVtbl->LoadMatrix(p,a) -#define ID3DXMatrixStack_MultMatrix(p,a) (p)->lpVtbl->MultMatrix(p,a) -#define ID3DXMatrixStack_MultMatrixLocal(p,a) (p)->lpVtbl->MultMatrixLocal(p,a) -#define ID3DXMatrixStack_RotateAxis(p,a,b) (p)->lpVtbl->RotateAxis(p,a,b) -#define ID3DXMatrixStack_RotateAxisLocal(p,a,b) (p)->lpVtbl->RotateAxisLocal(p,a,b) -#define ID3DXMatrixStack_RotateYawPitchRoll(p,a,b,c) (p)->lpVtbl->RotateYawPitchRoll(p,a,b,c) -#define ID3DXMatrixStack_RotateYawPitchRollLocal(p,a,b,c) (p)->lpVtbl->RotateYawPitchRollLocal(p,a,b,c) -#define ID3DXMatrixStack_Scale(p,a,b,c) (p)->lpVtbl->Scale(p,a,b,c) -#define ID3DXMatrixStack_ScaleLocal(p,a,b,c) (p)->lpVtbl->ScaleLocal(p,a,b,c) -#define ID3DXMatrixStack_Translate(p,a,b,c) (p)->lpVtbl->Translate(p,a,b,c) -#define ID3DXMatrixStack_TranslateLocal(p,a,b,c) (p)->lpVtbl->TranslateLocal(p,a,b,c) -#define ID3DXMatrixStack_GetTop(p) (p)->lpVtbl->GetTop(p) - -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -HRESULT WINAPI D3DXCreateMatrixStack(DWORD flags, LPD3DXMATRIXSTACK* ppstack); - -#ifdef __cplusplus -} -#endif - #include #endif /* __D3DX9MATH_H__ */ diff --git a/include/dbccmd.idl b/include/dbccmd.idl deleted file mode 100644 index 28763d202fc..00000000000 --- a/include/dbccmd.idl +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (C) 2009 Huw Davies - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -[ - object, - uuid(0c733a1d-2a1c-11ce-ade5-00aa0044773d), - pointer_default(unique) -] -interface IDBCreateCommand : IUnknown -{ - [local] - HRESULT CreateCommand([in] IUnknown *pUnkOuter, - [in] REFIID riid, - [out, iid_is(riid)] IUnknown **ppCommand); - - [call_as(CreateCommand)] - HRESULT RemoteCreateCommand([in] IUnknown *pUnkOuter, - [in] REFIID riid, - [out, iid_is(riid)] IUnknown **ppCommand, - [out] IErrorInfo **ppErrorInfoRem); -} diff --git a/include/dbcses.idl b/include/dbcses.idl deleted file mode 100644 index 54418159472..00000000000 --- a/include/dbcses.idl +++ /dev/null @@ -1,36 +0,0 @@ -/* - * Copyright (C) 2009 Huw Davies - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -[ - object, - uuid(0c733a5d-2a1c-11ce-ade5-00aa0044773d), - pointer_default(unique) -] -interface IDBCreateSession : IUnknown -{ - [local] - HRESULT CreateSession([in] IUnknown *pUnkOuter, - [in] REFIID riid, - [out, iid_is(riid)] IUnknown **ppDBSession); - - [call_as(CreateSession)] - HRESULT RemoteCreateSession([in] IUnknown *pUnkOuter, - [in] REFIID riid, - [out, iid_is(riid)] IUnknown **ppDBSession, - [out] IErrorInfo **ppErrorInfoRem); -} diff --git a/include/dbdsad.idl b/include/dbdsad.idl deleted file mode 100644 index 1fb8c9f53f0..00000000000 --- a/include/dbdsad.idl +++ /dev/null @@ -1,75 +0,0 @@ -/* - * Copyright (C) 2009 Huw Davies - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -[ - object, - uuid(0c733a7a-2a1c-11ce-ade5-00aa0044773d), - pointer_default(unique) -] -interface IDBDataSourceAdmin : IUnknown -{ - [local] - HRESULT CreateDataSource([in] ULONG cPropertySets, - [in, out, size_is(cPropertySets)] DBPROPSET rgPropertySets[], - [in] IUnknown *pUnkOuter, - [in] REFIID riid, - [out, iid_is(riid)] IUnknown **ppDBSession); - - [call_as(CreateDataSource)] - HRESULT RemoteCreateDataSource([in] ULONG cPropertySets, - [in, unique, size_is(cPropertySets)] DBPROPSET *rgPropertySets, - [in] IUnknown *pUnkOuter, - [in] REFIID riid, - [in, out, unique, iid_is(riid)] IUnknown **ppDBSession, - [in] ULONG cTotalProps, - [out, size_is(cTotalProps)] DBPROPSTATUS *rgPropStatus, - [out] IErrorInfo **ppErrorInfoRem); - - [local] - HRESULT DestroyDataSource(); - - [call_as(DestroyDataSource)] - HRESULT RemoteDestroyDataSource([out] IErrorInfo **ppErrorInfoRem); - - [local] - HRESULT GetCreationProperties([in] ULONG cPropertyIDSets, - [in, size_is(cPropertyIDSets)] const DBPROPIDSET rgPropertyIDSets[], - [in, out] ULONG *pcPropertyInfoSets, - [out, size_is(,*pcPropertyInfoSets)] DBPROPINFOSET **prgPropertyInfoSets, - [out, /*annotation("__deref_out_z_opt")*/] OLECHAR **ppDescBuffer); - - [call_as(GetCreationProperties)] - HRESULT RemoteGetCreationProperties([in] ULONG cPropertyIDSets, - [in, unique, size_is(cPropertyIDSets)] const DBPROPIDSET *rgPropertyIDSets, - [in, out] ULONG *pcPropertyInfoSets, - [out, size_is(,*pcPropertyInfoSets)] DBPROPINFOSET **prgPropertyInfoSets, - [in, out] DBCOUNTITEM *pcOffsets, - [out, size_is(,(ULONG)*pcOffsets)] DBBYTEOFFSET **prgDescOffsets, - [in, out] ULONG *pcbDescBuffer, - [in, out, unique, size_is(,*pcbDescBuffer)] OLECHAR **ppDescBuffer, - [out] IErrorInfo **ppErrorInfoRem); - - [local] - HRESULT ModifyDataSource([in] ULONG cPropertySets, - [in, size_is(cPropertySets)] DBPROPSET rgPropertySets[]); - - [call_as(ModifyDataSource)] - HRESULT RemoteModifyDataSource([in] ULONG cPropertySets, - [in, size_is(cPropertySets)] DBPROPSET *rgPropertySets, - [out] IErrorInfo **ppErrorInfoRem); -} diff --git a/include/dbprop.idl b/include/dbprop.idl index 77ceab01c94..5ed5301385f 100644 --- a/include/dbprop.idl +++ b/include/dbprop.idl @@ -30,7 +30,7 @@ interface IDBProperties : IUnknown { [call_as(GetProperties)] HRESULT RemoteGetProperties( [in] ULONG cPropertyIDSets, - [in, unique, size_is(cPropertyIDSets)] const DBPROPIDSET *rgPropertyIDSets, + [in, size_is(cPropertyIDSets)] const DBPROPIDSET rgPropertyIDSets[], [in, out] ULONG *pcPropertySets, [out, size_is(,*pcPropertySets)] DBPROPSET **prgPropertySets, [out] IErrorInfo **ppErrorInfoRem); @@ -39,18 +39,17 @@ interface IDBProperties : IUnknown { [in] ULONG cPropertyIDSets, [in, size_is(cPropertyIDSets)] const DBPROPIDSET rgPropertyIDSets[], [in, out] ULONG *pcPropertyInfoSets, - [out, size_is(,*pcPropertyInfoSets)] DBPROPINFOSET **prgPropertyInfoSets, - [out, /*annotation("__deref_out_z_opt")*/] OLECHAR **ppDescBuffer); + [out, size_is(,*pcPropertyInfoSets)] DBPROPINFOSET **prgPropertyInfoSets); [call_as(GetPropertyInfo)] HRESULT RemoteGetPropertyInfo( [in] ULONG cPropertyIDSets, - [in, unique, size_is(cPropertyIDSets)] const DBPROPIDSET *rgPropertyIDSets, + [in,size_is(cPropertyIDSets)] const DBPROPIDSET *rgPropertyIDSets, [in, out] ULONG *pcPropertyInfoSets, [out, size_is(,*pcPropertyInfoSets)] DBPROPINFOSET **prgPropertyInfoSets, [in, out] ULONG *pcOffsets, [out, size_is(,*pcOffsets)] DBBYTEOFFSET **prgDescOffsets, [in, out] ULONG *pcbDescBuffer, - [in, out, unique, size_is(,*pcbDescBuffer)] OLECHAR **ppDescBuffer, + [out, size_is(,*pcbDescBuffer)] OLECHAR **ppDescBuffer, [out] IErrorInfo **ppErrorInfoRem); [local] HRESULT SetProperties( @@ -59,7 +58,7 @@ interface IDBProperties : IUnknown { [call_as(SetProperties)] HRESULT RemoteSetProperties( [in] ULONG cPropertySets, - [in, unique, size_is(cPropertySets)] DBPROPSET *rgPropertySets, + [in, out, size_is(cPropertySets)] DBPROPSET *rgPropertySets, [in] ULONG cTotalProps, [out, size_is(cTotalProps)] DBPROPSTATUS *rgPropStatus, [out] IErrorInfo **ppErrorInfoRem); diff --git a/include/dbs.idl b/include/dbs.idl index 9909c9d3ba1..19c2997b3ab 100644 --- a/include/dbs.idl +++ b/include/dbs.idl @@ -99,13 +99,3 @@ typedef struct tagDBPROPINFOSET { ULONG cPropertyInfos; GUID guidPropertySet; } DBPROPINFOSET; - -typedef DWORD DBBINDURLFLAG; -typedef DWORD DBBINDURLSTATUS; - -typedef struct tagDBIMPLICITSESSION -{ - IUnknown *pUnkOuter; - IID *piid; - IUnknown *pSession; -} DBIMPLICITSESSION; diff --git a/include/gdiplusflat.h b/include/gdiplusflat.h index 2ee24bdbc38..4e830b57b6f 100644 --- a/include/gdiplusflat.h +++ b/include/gdiplusflat.h @@ -127,7 +127,6 @@ GpStatus WINGDIPAPI GdipFlush(GpGraphics*, GpFlushIntention); GpStatus WINGDIPAPI GdipBeginContainer(GpGraphics*,GDIPCONST GpRectF*,GDIPCONST GpRectF*,GpUnit,GraphicsContainer*); GpStatus WINGDIPAPI GdipBeginContainer2(GpGraphics*,GraphicsContainer*); GpStatus WINGDIPAPI GdipBeginContainerI(GpGraphics*,GDIPCONST GpRect*,GDIPCONST GpRect*,GpUnit,GraphicsContainer*); -GpStatus WINGDIPAPI GdipEndContainer(GpGraphics*,GraphicsContainer); GpStatus WINGDIPAPI GdipComment(GpGraphics*,UINT,GDIPCONST BYTE*); GpStatus WINGDIPAPI GdipCreateFromHDC(HDC,GpGraphics**); GpStatus WINGDIPAPI GdipCreateFromHDC2(HDC,HANDLE,GpGraphics**); @@ -148,8 +147,6 @@ GpStatus WINGDIPAPI GdipDrawCurve(GpGraphics*,GpPen*,GDIPCONST GpPointF*,INT); GpStatus WINGDIPAPI GdipDrawCurveI(GpGraphics*,GpPen*,GDIPCONST GpPoint*,INT); GpStatus WINGDIPAPI GdipDrawCurve2(GpGraphics*,GpPen*,GDIPCONST GpPointF*,INT,REAL); GpStatus WINGDIPAPI GdipDrawCurve2I(GpGraphics*,GpPen*,GDIPCONST GpPoint*,INT,REAL); -GpStatus WINGDIPAPI GdipDrawCurve3(GpGraphics*,GpPen*,GDIPCONST GpPointF*,INT,INT,INT,REAL); -GpStatus WINGDIPAPI GdipDrawCurve3I(GpGraphics*,GpPen*,GDIPCONST GpPoint*,INT,INT,INT,REAL); GpStatus WINGDIPAPI GdipDrawEllipse(GpGraphics*,GpPen*,REAL,REAL,REAL,REAL); GpStatus WINGDIPAPI GdipDrawEllipseI(GpGraphics*,GpPen*,INT,INT,INT,INT); GpStatus WINGDIPAPI GdipDrawImage(GpGraphics*,GpImage*,REAL,REAL); @@ -409,7 +406,6 @@ GpStatus WINGDIPAPI GdipGetLineBlendCount(GpLineGradient*,INT*); GpStatus WINGDIPAPI GdipSetLineColors(GpLineGradient*,ARGB,ARGB); GpStatus WINGDIPAPI GdipSetLineGammaCorrection(GpLineGradient*,BOOL); GpStatus WINGDIPAPI GdipSetLineSigmaBlend(GpLineGradient*,REAL,REAL); -GpStatus WINGDIPAPI GdipSetLineLinearBlend(GpLineGradient*,REAL,REAL); GpStatus WINGDIPAPI GdipSetLineWrapMode(GpLineGradient*,GpWrapMode); /* Matrix */ diff --git a/include/msctf.idl b/include/msctf.idl index bcd2587d833..4db67f4db69 100644 --- a/include/msctf.idl +++ b/include/msctf.idl @@ -29,20 +29,9 @@ cpp_quote("#define TF_E_DISCONNECTED MAKE_HRESULT(SEVERITY_ERROR, FACILITY_IT cpp_quote("#define TF_E_ALREADY_EXISTS MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0506)") cpp_quote("#define TF_E_NOLOCK MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0201)") -cpp_quote("HRESULT WINAPI TF_CreateThreadMgr(ITfThreadMgr **pptim);") -cpp_quote("HRESULT WINAPI TF_GetThreadMgr(ITfThreadMgr **pptim);") -cpp_quote("HRESULT WINAPI TF_CreateInputProcessorProfiles(ITfInputProcessorProfiles **ppipr);") - -cpp_quote("EXTERN_C const GUID GUID_PROP_TEXTOWNER;") -cpp_quote("DEFINE_GUID(GUID_PROP_ATTRIBUTE,0x34b45670,0x7526,0x11d2,0xa1,0x47,0x00,0x10,0x5a,0x27,0x99,0xb5);") -cpp_quote("EXTERN_C const GUID GUID_PROP_LANGID;") -cpp_quote("EXTERN_C const GUID GUID_PROP_READING;") -cpp_quote("EXTERN_C const GUID GUID_PROP_COMPOSING;") - cpp_quote("EXTERN_C const CLSID CLSID_TF_ThreadMgr;") cpp_quote("EXTERN_C const CLSID CLSID_TF_InputProcessorProfiles;") cpp_quote("EXTERN_C const CLSID CLSID_TF_CategoryMgr;") -cpp_quote("DEFINE_GUID(CLSID_TF_DisplayAttributeMgr,0x3ce74de4,0x53d3,0x4d74,0x8b,0x83,0x43,0x1b,0x38,0x28,0xba,0x53);") /* GUIDs for Compartments */ cpp_quote("EXTERN_C const GUID GUID_COMPARTMENT_KEYBOARD_DISABLED;") @@ -157,17 +146,6 @@ interface ITfThreadMgr: IUnknown [out] ITfCompartmentMgr **ppCompMgr); }; -[ - object, - uuid(d7540241-f9a1-4364-befc-dbcd2c4395b7), - pointer_default(unique) -] -interface ITfCompositionView : IUnknown -{ - HRESULT GetOwnerClsid([out] CLSID *pclsid); - - HRESULT GetRange([out] ITfRange **ppRange); -} [ object, @@ -419,109 +397,6 @@ interface ITfInputProcessorProfiles : IUnknown [in] HKL hKL); }; -typedef [uuid(c4cc07f1-80cc-4a7b-bc54-98512782cbe3)] -enum { - TF_LS_NONE = 0, - TF_LS_SOLID = 1, - TF_LS_DOT = 2, - TF_LS_DASH = 3, - TF_LS_SQUIGGLE = 4 -} TF_DA_LINESTYLE; - -typedef [uuid(d9b92e21-084a-401b-9c64-1e6dad91a1ab)] -enum { - TF_CT_NONE = 0, - TF_CT_SYSCOLOR = 1, - TF_CT_COLORREF = 2 -} TF_DA_COLORTYPE; - -typedef [uuid(90d0cb5e-6520-4a0f-b47c-c39bd955f0d6)] -struct TF_DA_COLOR { - TF_DA_COLORTYPE type; - [switch_type(TF_DA_COLORTYPE), switch_is(type)] - union { - [case(TF_CT_SYSCOLOR)] int nIndex; - [case(TF_CT_COLORREF)] COLORREF cr; - }; -} TF_DA_COLOR; - -typedef [uuid(33d2fe4b-6c24-4f67-8d75-3bc1819e4126)] -enum { - TF_ATTR_INPUT = 0, - TF_ATTR_TARGET_CONVERTED = 1, - TF_ATTR_CONVERTED = 2, - TF_ATTR_TARGET_NOTCONVERTED = 3, - TF_ATTR_INPUT_ERROR = 4, - TF_ATTR_FIXEDCONVERTED = 5, - TF_ATTR_OTHER = -1 -} TF_DA_ATTR_INFO; - -typedef [uuid(1bf1c305-419b-4182-a4d2-9bfadc3f021f)] -struct TF_DISPLAYATTRIBUTE { - TF_DA_COLOR crText; - TF_DA_COLOR crBk; - TF_DA_LINESTYLE lsStyle; - BOOL fBoldLine; - TF_DA_COLOR crLine; - TF_DA_ATTR_INFO bAttr; -} TF_DISPLAYATTRIBUTE; - -[ - object, - uuid(70528852-2f26-4aea-8c96-215150578932), - pointer_default(unique) -] -interface ITfDisplayAttributeInfo : IUnknown -{ - HRESULT GetGUID([out] GUID *pguid); - - HRESULT GetDescription([out] BSTR *pbstrDesc); - - HRESULT GetAttributeInfo([out] TF_DISPLAYATTRIBUTE *pda); - - HRESULT SetAttributeInfo([in] const TF_DISPLAYATTRIBUTE *pda); - - HRESULT Reset(); -} - -[ - object, - uuid(7cef04d7-cb75-4e80-a7ab-5f5bc7d332de), - pointer_default(unique) -] -interface IEnumTfDisplayAttributeInfo : IUnknown -{ - HRESULT Clone([out] IEnumTfDisplayAttributeInfo **ppEnum); - - HRESULT Next( - [in] ULONG ulCount, - [out, size_is(ulCount), length_is(*pcFetched)] ITfDisplayAttributeInfo **rgInfo, - [out] ULONG *pcFetched); - - HRESULT Reset(); - - HRESULT Skip([in] ULONG ulCount); -} - -[ - object, - local, - uuid(8ded7393-5db1-475c-9e71-a39111b0ff67), - pointer_default(unique) -] -interface ITfDisplayAttributeMgr : IUnknown -{ - HRESULT OnUpdateInfo(); - - HRESULT EnumDisplayAttributeInfo([out] IEnumTfDisplayAttributeInfo **ppEnum); - - HRESULT GetDisplayAttributeInfo( - [in] REFGUID guid, - [out] ITfDisplayAttributeInfo **ppInfo, - [out] CLSID *pclsidOwner); - -} - [ object, local, @@ -1007,20 +882,6 @@ interface ITfRange : IUnknown [ object, - uuid(057a6296-029b-4154-b79a-0d461d4ea94c), - pointer_default(unique) -] -interface ITfRangeACP : ITfRange -{ - HRESULT GetExtent([out] LONG *pacpAnchor, - [out] LONG *pcch); - - HRESULT SetExtent([in] LONG acpAnchor, - [in] LONG cch); -} - -[ - object, uuid(55ce16ba-3014-41c1-9ceb-fade1446ac6c), pointer_default(unique) ] @@ -1045,203 +906,6 @@ interface ITfInsertAtSelection : IUnknown }; [ - object, - uuid(6834b120-88cb-11d2-bf45-00105a2799b5), - pointer_default(unique) -] -interface ITfPropertyStore : IUnknown -{ - const DWORD TF_TU_CORRECTION = 0x1; - - HRESULT GetType([out] GUID *pguid); - - HRESULT GetDataType([out] DWORD *pdwReserved); - - HRESULT GetData([out] VARIANT *pvarValue); - - HRESULT OnTextUpdated( - [in] DWORD dwFlags, - [in] ITfRange *pRangeNew, - [out] BOOL *pfAccept); - - HRESULT Shrink( - [in] ITfRange *pRangeNew, - [out] BOOL *pfFree); - - HRESULT Divide( - [in] ITfRange *pRangeThis, - [in] ITfRange *pRangeNew, - [out] ITfPropertyStore **ppPropStore); - - HRESULT Clone( - [out] ITfPropertyStore **pPropStore); - - HRESULT GetPropertyRangeCreator( - [out] CLSID *pclsid); - - HRESULT Serialize( - [in] IStream *pStream, - [out] ULONG *pcb); -} - -[ - object, - uuid(f99d3f40-8e32-11d2-bf46-00105a2799b5), - pointer_default(unique) -] -interface IEnumTfRanges : IUnknown -{ - HRESULT Clone([out] IEnumTfRanges **ppEnum); - - HRESULT Next( - [in] ULONG ulCount, - [out, size_is(ulCount), length_is(*pcFetched)] ITfRange **ppRange, - [out] ULONG *pcFetched); - - HRESULT Reset(); - - HRESULT Skip(ULONG ulCount); -} - -[ - object, - uuid(5efd22Ba-7838-46cb-88e2-cadb14124f8f), - pointer_default(unique) -] -interface IEnumITfCompositionView : IUnknown -{ - HRESULT Clone([out] IEnumITfCompositionView **ppEnum); - - HRESULT Next( - [in] ULONG ulCount, - [out, size_is(ulCount), length_is(*pcFetched)] ITfCompositionView **rgCompositionView, - [out] ULONG *pcFetched); - - HRESULT Reset(); - - HRESULT Skip([in] ULONG ulCount); -} - -[ - object, - uuid(20168d64-5a8f-4a5a-b7bd-cfa29f4D0fd9), - pointer_default(unique) -] -interface ITfComposition : IUnknown -{ - HRESULT GetRange([out] ITfRange **ppRange); - - HRESULT ShiftStart( - [in] TfEditCookie ecWrite, - [in] ITfRange *pNewStart); - - HRESULT ShiftEnd( - [in] TfEditCookie ecWrite, - [in] ITfRange *pNewEnd); - - HRESULT EndComposition([in] TfEditCookie ecWrite); -} - -[ - object, - uuid(a781718c-579a-4b15-a280-32b8577acc5e), - pointer_default(unique) -] -interface ITfCompositionSink : IUnknown -{ - HRESULT OnCompositionTerminated( - [in] TfEditCookie ecWrite, - [in] ITfComposition *pComposition); -} - -[ - object, - uuid(d40C8aae-aC92-4fc7-9a11-0ee0e23aa39b), - pointer_default(unique) -] -interface ITfContextComposition : IUnknown -{ - HRESULT StartComposition( - [in] TfEditCookie ecWrite, - [in] ITfRange *pCompositionRange, - [in] ITfCompositionSink *pSink, - [out] ITfComposition **ppComposition); - - HRESULT EnumCompositions([out] IEnumITfCompositionView **ppEnum); - - HRESULT FindComposition( - [in] TfEditCookie ecRead, - [in] ITfRange *pTestRange, - [out] IEnumITfCompositionView **ppEnum); - - HRESULT TakeOwnership( - [in] TfEditCookie ecWrite, - [in] ITfCompositionView *pComposition, - [in] ITfCompositionSink *pSink, - [out] ITfComposition **ppComposition); -} - -[ - object, - uuid(86462810-593b-4916-9764-19c08e9ce110), - pointer_default(unique) -] -interface ITfContextOwnerCompositionServices : ITfContextComposition -{ - HRESULT TerminateComposition([in] ITfCompositionView *pComposition); -} - -[ - object, - uuid(17d49a3d-f8b8-4b2f-b254-52319dd64c53), - pointer_default(unique) -] -interface ITfReadOnlyProperty : IUnknown -{ - HRESULT GetType([out] GUID *pguid); - - HRESULT EnumRanges( - [in] TfEditCookie ec, - [out] IEnumTfRanges **ppEnum, - [in] ITfRange *pTargetRange); - - HRESULT GetValue( - [in] TfEditCookie ec, - [in] ITfRange *pRange, - [out] VARIANT *pvarValue); - - HRESULT GetContext([out] ITfContext **ppContext); -} - -[ - object, - uuid(e2449660-9542-11d2-bf46-00105a2799b5), - pointer_default(unique) -] -interface ITfProperty : ITfReadOnlyProperty -{ - HRESULT FindRange( - [in] TfEditCookie ec, - [in] ITfRange *pRange, - [out] ITfRange **ppRange, - [in] TfAnchor aPos); - - HRESULT SetValueStore( - [in] TfEditCookie ec, - [in] ITfRange *pRange, - [in] ITfPropertyStore *pPropStore); - - HRESULT SetValue( - [in] TfEditCookie ec, - [in] ITfRange *pRange, - [in] const VARIANT *pvarValue); - - HRESULT Clear( - [in] TfEditCookie ec, - [in] ITfRange *pRange); -} - -[ object, uuid(bb08f7a9-607a-4384-8623-056892b64371), pointer_default(unique) @@ -1274,56 +938,3 @@ interface ITfCompartmentMgr : IUnknown HRESULT EnumCompartments( [out] IEnumGUID **ppEnum); }; - -[ - object, - uuid(743abd5f-f26d-48df-8cc5-238492419b64), - pointer_default(unique) -] -interface ITfCompartmentEventSink : IUnknown -{ - HRESULT OnChange( - [in] REFGUID rguid); -} - -[ - object, - uuid(8f1a7ea6-1654-4502-a86e-b2902344d507), - pointer_default(unique) -] -interface IEnumTfContexts : IUnknown -{ - HRESULT Clone( - [out] IEnumTfContexts **ppEnum); - - HRESULT Next( - [in] ULONG ulCount, - [out, size_is(ulCount), length_is(*pcFetched)] ITfContext **rgContext, - [out] ULONG *pcFetched); - - HRESULT Reset(); - - HRESULT Skip( - [in] ULONG ulCount); -}; - -[ - object, - uuid(aa80e808-2021-11d2-93e0-0060b067b86e), - pointer_default(unique) -] -interface IEnumTfDocumentMgrs : IUnknown -{ - HRESULT Clone( - [out] IEnumTfDocumentMgrs **ppEnum); - - HRESULT Next( - [in] ULONG ulCount, - [out, size_is(ulCount), length_is(*pcFetched)] ITfDocumentMgr **rgDocumentMgr, - [out] ULONG *pcFetched); - - HRESULT Reset(); - - HRESULT Skip( - [in] ULONG ulCount); -}; diff --git a/include/mshtmdid.h b/include/mshtmdid.h index 980fbdd4681..8f882f8c13c 100644 --- a/include/mshtmdid.h +++ b/include/mshtmdid.h @@ -1315,13 +1315,6 @@ #define DISPID_IHTMLDATABINDING_DATASRC DISPID_ELEMENT+22 #define DISPID_IHTMLDATABINDING_DATAFORMATAS DISPID_ELEMENT+23 -/* IHTMLDOMConstructor */ -#define DISPID_IHTMLDOMCONSTRUCTOR_CONSTRUCTOR DISPID_HTMLOBJECT+9 -#define DISPID_IHTMLDOMCONSTRUCTOR_LOOKUPGETTER -#define DISPID_IHTMLDOMCONSTRUCTOR_LOOKUPSETTER -#define DISPID_IHTMLDOMCONSTRUCTOR_DEFINEGETTER -#define DISPID_IHTMLDOMCONSTRUCTOR_DEFINESETTER - /* IHTMLStyle */ #define DISPID_IHTMLSTYLE_PIXELTOP DISPID_STYLE #define DISPID_IHTMLSTYLE_PIXELLEFT (DISPID_STYLE+1) diff --git a/include/mshtml.idl b/include/mshtml.idl index e2190056b99..c8537fcedac 100644 --- a/include/mshtml.idl +++ b/include/mshtml.idl @@ -13017,89 +13017,13 @@ interface IOmNavigator : IDispatch HRESULT userProfile([retval, out] IHTMLOpsProfile **p); } -/***************************************************************************** - * DispHTMLNavigator dispinterface - */ -[ - hidden, - uuid(3050f54c-98b5-11cf-bb82-00aa00bdce0b) -] -dispinterface DispHTMLNavigator -{ -properties: -methods: - [propget, id(DISPID_IOMNAVIGATOR_APPCODENAME)] - BSTR appCodeName(); - - [propget, id(DISPID_IOMNAVIGATOR_APPNAME)] - BSTR appName(); - - [propget, id(DISPID_IOMNAVIGATOR_APPVERSION)] - BSTR appVersion(); - - [propget, id(DISPID_IOMNAVIGATOR_USERAGENT)] - BSTR userAgent(); - - [id(DISPID_IOMNAVIGATOR_JAVAENABLED)] - VARIANT_BOOL javaEnabled(); - - [id(DISPID_IOMNAVIGATOR_TAINTENABLED)] - VARIANT_BOOL taintEnabled(); - - [propget, id(DISPID_IOMNAVIGATOR_MIMETYPES)] - IHTMLMimeTypesCollection *mimeTypes(); - - [propget, id(DISPID_IOMNAVIGATOR_PLUGINS)] - IHTMLPluginsCollection *plugins(); - - [propget, id(DISPID_IOMNAVIGATOR_COOKIEENABLED)] - VARIANT_BOOL cookieEnabled(); - - [propget, id(DISPID_IOMNAVIGATOR_OPSPROFILE)] - IHTMLOpsProfile *opsProfile(); - - [id(DISPID_IOMNAVIGATOR_TOSTRING)] - BSTR toString(); - - [propget, id(DISPID_IOMNAVIGATOR_CPUCLASS)] - BSTR cpuClass(); - - [propget, id(DISPID_IOMNAVIGATOR_SYSTEMLANGUAGE)] - BSTR systemLanguage(); - - [propget, id(DISPID_IOMNAVIGATOR_BROWSERLANGUAGE), hidden] - BSTR browserLanguage(); - - [propget, id(DISPID_IOMNAVIGATOR_USERLANGUAGE)] - BSTR userLanguage(); - - [propget, id(DISPID_IOMNAVIGATOR_PLATFORM)] - BSTR platform(); - - [propget, id(DISPID_IOMNAVIGATOR_APPMINORVERSION)] - BSTR appMinorVersion(); - - [propget, id(DISPID_IOMNAVIGATOR_CONNECTIONSPEED), hidden] - LONG connectionSpeed(); - - [propget, id(DISPID_IOMNAVIGATOR_ONLINE)] - VARIANT_BOOL onLine(); - - [propget, id(DISPID_IOMNAVIGATOR_USERPROFILE)] - IHTMLOpsProfile *userProfile(); - - [propget, id(DISPID_IHTMLDOMCONSTRUCTOR_CONSTRUCTOR), hidden] - IDispatch *constructor(); -} - [ noncreatable, uuid(FECEAAA6-8405-11cf-8BA1-00AA00476DA6) ] coclass HTMLNavigator { - [default] dispinterface DispHTMLNavigator; - interface IOmNavigator; + [default] interface IOmNavigator; } /***************************************************************************** @@ -13174,89 +13098,13 @@ interface IHTMLLocation : IDispatch HRESULT toString([retval, out] BSTR *String); } -/***************************************************************************** - * DispHTMLLocation dispinterface - */ -[ - hidden, - uuid(3050f54e-98b5-11cf-bb82-00aa00bdce0b) -] -dispinterface DispHTMLLocation -{ -properties: -methods: - [propput, id(DISPID_IHTMLLOCATION_HREF)] - void href(BSTR v); - - [propget, id(DISPID_IHTMLLOCATION_HREF)] - BSTR href(); - - [propput, id(DISPID_IHTMLLOCATION_PROTOCOL)] - void protocol(BSTR v); - - [propget, id(DISPID_IHTMLLOCATION_PROTOCOL)] - BSTR protocol(); - - [propput, id(DISPID_IHTMLLOCATION_HOST)] - void host(BSTR v); - - [propget, id(DISPID_IHTMLLOCATION_HOST)] - BSTR host(); - - [propput, id(DISPID_IHTMLLOCATION_HOSTNAME)] - void hostname(BSTR v); - - [propget, id(DISPID_IHTMLLOCATION_HOSTNAME)] - BSTR hostname(); - - [propput, id(DISPID_IHTMLLOCATION_PORT)] - void port(BSTR v); - - [propget, id(DISPID_IHTMLLOCATION_PORT)] - BSTR port(); - - [propput, id(DISPID_IHTMLLOCATION_PATHNAME)] - void pathname(BSTR v); - - [propget, id(DISPID_IHTMLLOCATION_PATHNAME)] - BSTR pathname(); - - [propput, id(DISPID_IHTMLLOCATION_SEARCH)] - void search(BSTR v); - - [propget, id(DISPID_IHTMLLOCATION_SEARCH)] - BSTR search(); - - [propput, id(DISPID_IHTMLLOCATION_HASH)] - void hash(BSTR v); - - [propget, id(DISPID_IHTMLLOCATION_HASH)] - BSTR hash(); - - [id(DISPID_IHTMLLOCATION_RELOAD)] - void reload([in, defaultvalue(0)] VARIANT_BOOL flag); - - [id(DISPID_IHTMLLOCATION_REPLACE)] - void replace([in] BSTR bstr); - - [id(DISPID_IHTMLLOCATION_ASSIGN)] - void assign([in] BSTR bstr); - - [id(DISPID_IHTMLLOCATION_TOSTRING)] - BSTR toString(); - - [propget, id(DISPID_IHTMLDOMCONSTRUCTOR_CONSTRUCTOR), hidden] - IDispatch *constructor(); -} - [ noncreatable, uuid(163BB1E1-6E00-11cf-837A-48DC04C10000) ] coclass HTMLLocation { - [default] dispinterface DispHTMLLocation; - interface IHTMLLocation; + [default] interface IHTMLLocation; } [ diff --git a/include/netcon.idl b/include/netcon.idl deleted file mode 100644 index eecc1d2af3e..00000000000 --- a/include/netcon.idl +++ /dev/null @@ -1,412 +0,0 @@ -/* - * Copyright 2009 Jacek Caban for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#ifndef DO_NO_IMPORTS -import "oaidl.idl"; -import "unknwn.idl"; -import "wtypes.idl"; -/* import "prsht.idl"; */ -#endif - -cpp_quote("DEFINE_GUID(CLSID_NetSharingManager,0x5c63c1ad,0x3956,0x4ff8,0x84,0x86,0x40,0x03,0x47,0x58,0x31,0x5b);") - -[ - object, - uuid(c08956a1-1cd3-11d1-b1c5-00805fc1270e), - pointer_default(unique) -] -interface INetConnection : IUnknown -{ - typedef enum tagNETCON_CHARACTERISTIC_FLAGS - { - NCCF_NONE = 0x0000, - NCCF_ALL_USERS = 0x0001, - NCCF_ALLOW_DUPLICATION = 0x0002, - NCCF_ALLOW_REMOVAL = 0x0004, - NCCF_ALLOW_RENAME = 0x0008, - NCCF_INCOMING_ONLY = 0x0020, - NCCF_OUTGOING_ONLY = 0x0040, - NCCF_BRANDED = 0x0080, - NCCF_SHARED = 0x0100, - NCCF_BRIDGED = 0x0200, - NCCF_FIREWALLED = 0x0400, - NCCF_DEFAULT = 0x0800, - NCCF_HOMENET_CAPABLE = 0x1000, - NCCF_SHARED_PRIVATE = 0x2000, - NCCF_QUARANTINED = 0x4000, - NCCF_RESERVED = 0x8000, - NCCF_BLUETOOTH_MASK = 0x000F0000, - NCCF_LAN_MASK = 0x00F00000 - } NETCON_CHARACTERISTIC_FLAGS; - - typedef enum tagNETCON_STATUS - { - NCS_DISCONNECTED, - NCS_CONNECTING, - NCS_CONNECTED, - NCS_DISCONNECTING, - NCS_HARDWARE_NOT_PRESENT, - NCS_HARDWARE_DISABLED, - NCS_HARDWARE_MALFUNCTION, - NCS_MEDIA_DISCONNECTED, - NCS_AUTHENTICATING, - NCS_AUTHENTICATION_SUCCEEDED, - NCS_AUTHENTICATION_FAILED, - NCS_INVALID_ADDRESS, - NCS_CREDENTIALS_REQUIRED - } NETCON_STATUS; - - typedef enum tagNETCON_TYPE - { - NCT_DIRECT_CONNECT, - NCT_INBOUND, - NCT_INTERNET, - NCT_LAN, - NCT_PHONE, - NCT_TUNNEL, - NCT_BRIDGE - } NETCON_TYPE; - - typedef enum tagNETCON_MEDIATYPE - { - NCM_NONE, - NCM_DIRECT, - NCM_ISDN, - NCM_LAN, - NCM_PHONE, - NCM_TUNNEL, - NCM_PPPOE, - NCM_BRIDGE, - NCM_SHAREDACCESSHOST_LAN, - NCM_SHAREDACCESSHOST_RAS - } NETCON_MEDIATYPE; - - typedef struct tagNETCON_PROPERTIES - { - GUID guidId; - [string] LPWSTR pszwName; - [string] LPWSTR pszwDeviceName; - NETCON_STATUS Status; - NETCON_MEDIATYPE MediaType; - DWORD dwCharacter; - CLSID clsidThisObject; - CLSID clsidUiObject; - } NETCON_PROPERTIES; - - HRESULT Connect(); - - HRESULT Disconnect(); - - HRESULT Delete(); - - HRESULT Duplicate( - [in, string] LPCWSTR pszwDuplicateName, - [out] INetConnection **ppCon); - - HRESULT GetProperties([out] NETCON_PROPERTIES **ppProps); - - HRESULT GetUiObjectClassId([out, ref] CLSID *pclsid); - - HRESULT Rename([in, string] LPCWSTR pszwNewName); -} - -[ - object, - uuid(24b7e9b5-e38f-4685-851b-00892cf5f940), - oleautomation, - dual, - pointer_default(unique) -] -interface INetSharingPortMappingProps : IDispatch -{ - [propget, id(1)] - HRESULT Name([out, retval] BSTR *pbstrName); - - [propget, id(2)] - HRESULT IPProtocol([out, retval] UCHAR *pucIPProt); - - [propget, id(3)] - HRESULT ExternalPort([out, retval] long *pusPort); - - [propget, id(4)] - HRESULT InternalPort([out, retval] long *pusPort); - - [propget, id(5)] - HRESULT Options([out, retval] long *pdwOptions); - - [propget, id(6)] - HRESULT TargetName([out, retval] BSTR *pbstrTargetName); - - [propget, id(7)] - HRESULT TargetIPAddress([out, retval] BSTR *pbstrTargetIPAddress); - - [propget, id(8)] - HRESULT Enabled([out, retval] VARIANT_BOOL *pbool); -} - -[ - object, - uuid(c08956b1-1cd3-11d1-b1c5-00805fc1270e), - oleautomation, - dual, - pointer_default(unique) -] -interface INetSharingPortMapping : IDispatch -{ - [id(1)] - HRESULT Disable(); - - [id(2)] - HRESULT Enable(); - - [propget, id(3)] - HRESULT Properties([out, retval] INetSharingPortMappingProps **ppNSPMP); - - [id(4)] - HRESULT Delete(); -}; -[ - object, - uuid(02e4a2de-da20-4e34-89c8-ac22275a010b), - oleautomation, - dual, - pointer_default(unique) -] -interface INetSharingPortMappingCollection : IDispatch -{ - [propget, id(DISPID_NEWENUM), restricted] - HRESULT _NewEnum([out, retval] IUnknown **pVal); - - [propget, id(1)] - HRESULT Count([out, retval] long *pVal); -} - -[ - object, - uuid(c08956b6-1cd3-11d1-b1c5-00805fc1270e), - oleautomation, - dual, - pointer_default(unique) -] -interface INetSharingConfiguration : IDispatch -{ - typedef enum tagSHARINGCONNECTIONTYPE { - ICSSHARINGTYPE_PUBLIC, - ICSSHARINGTYPE_PRIVATE - } SHARINGCONNECTIONTYPE, *LPSHARINGCONNECTIONTYPE; - - typedef enum tagSHARINGCONNECTION_ENUM_FLAGS { - ICSSC_DEFAULT, - ICSSC_ENABLED - } SHARINGCONNECTION_ENUM_FLAGS; - - typedef enum tagICS_TARGETTYPE { - ICSTT_NAME, - ICSTT_IPADDRESS - }ICS_TARGETTYPE; - - [propget, id(1)] - HRESULT SharingEnabled([out, retval] VARIANT_BOOL *pbEnabled); - - [propget, id(2)] - HRESULT SharingConnectionType([out, retval] SHARINGCONNECTIONTYPE *pType); - - [id(3)] - HRESULT DisableSharing(); - - [id(4)] - HRESULT EnableSharing([in] SHARINGCONNECTIONTYPE Type); - - [propget, id(5)] - HRESULT InternetFirewallEnabled([out, retval] VARIANT_BOOL *pbEnabled); - - [id(6)] - HRESULT DisableInternetFirewall(); - - [id(7)] - HRESULT EnableInternetFirewall(); - - [propget, id(8)] - HRESULT EnumPortMappings( - [in] SHARINGCONNECTION_ENUM_FLAGS Flags, - [out, retval] INetSharingPortMappingCollection **ppColl); - - [id(9)] - HRESULT AddPortMapping( - [in] BSTR bstrName, - [in] UCHAR ucIPProtocol, - [in] USHORT usExternalPort, - [in] USHORT usInternalPort, - [in] DWORD dwOptions, - [in] BSTR bstrTargetNameOrIPAddress, - [in] ICS_TARGETTYPE eTargetType, - [out, retval] INetSharingPortMapping **ppMapping ); - - [id(10)] - HRESULT RemovePortMapping([in] INetSharingPortMapping *pMapping); -} - -[ - object, - uuid(c08956b4-1cd3-11d1-b1c5-00805fc1270e), - pointer_default(unique) -] -interface IEnumNetSharingPublicConnection : IUnknown -{ - HRESULT Next( - [in] ULONG celt, - [out, size_is(celt), length_is(*pceltFetched)] VARIANT *rgVar, - [out] ULONG *pceltFetched); - - HRESULT Skip([in] ULONG celt); - - HRESULT Reset(); - - HRESULT Clone([out] IEnumNetSharingPublicConnection **ppenum); -} - -[ - object, - uuid(c08956b5-1cd3-11d1-b1c5-00805fc1270e), - pointer_default(unique) -] -interface IEnumNetSharingPrivateConnection : IUnknown -{ - HRESULT Next( - [in] ULONG celt, - [out, size_is(celt), length_is(*pCeltFetched)] VARIANT *rgVar, - [out] ULONG *pCeltFetched); - - HRESULT Skip([in] ULONG celt); - - HRESULT Reset(); - - HRESULT Clone([out] IEnumNetSharingPrivateConnection **ppenum); -} - -[ - object, - uuid(f4277c95-ce5b-463d-8167-5662d9bcaa72), - oleautomation, - dual, - pointer_default(unique) -] -interface INetConnectionProps : IDispatch -{ - [propget, id(1)] - HRESULT Guid([out, retval] BSTR *pbstrGuid); - - [propget, id(2)] - HRESULT Name([out, retval] BSTR *pbstrName); - - [propget, id(3)] - HRESULT DeviceName([out, retval] BSTR *pbstrDeviceName); - - [propget, id(4)] - HRESULT Status([out, retval] NETCON_STATUS *pStatus); - - [propget, id(5)] - HRESULT MediaType([out, retval] NETCON_MEDIATYPE *pMediaType); - - [propget, id(6)] - HRESULT Characteristics([out, retval] DWORD *pdwFlags); -} - -[ - object, - uuid(7d7a6355-f372-4971-a149-bfc927be762a), - oleautomation, - dual, - pointer_default(unique) -] -interface INetSharingPublicConnectionCollection : IDispatch -{ - [propget, id(DISPID_NEWENUM), restricted] - HRESULT _NewEnum([out, retval] IUnknown **pVal); - - [propget, id(1)] - HRESULT Count([out, retval] long *pVal); -} - -[ - object, - uuid(33c4643c-7811-46fa-a89a-768597bd7223), - oleautomation, - dual, - pointer_default(unique) - ] -interface INetSharingEveryConnectionCollection : IDispatch -{ - [propget, id(DISPID_NEWENUM), restricted] - HRESULT _NewEnum([out, retval] IUnknown **pVal); - - [propget, id(1)] - HRESULT Count([out, retval] long *pVal); -} - -[ - object, - uuid(38ae69e0-4409-402a-a2cb-e965c727f840), - oleautomation, - dual, - pointer_default(unique) - ] -interface INetSharingPrivateConnectionCollection : IDispatch -{ - [propget, id(DISPID_NEWENUM), restricted] - HRESULT _NewEnum([out, retval] IUnknown **pVal); - - [propget, id(1)] - HRESULT Count([out, retval] long *pVal); -} - -[ - object, - uuid(c08956b7-1cd3-11d1-b1c5-00805fc1270e), - oleautomation, - dual, - pointer_default(unique) -] -interface INetSharingManager : IDispatch -{ - [propget, id(1)] - HRESULT SharingInstalled([out, retval] VARIANT_BOOL *pbInstalled); - - [propget, id(2)] - HRESULT EnumPublicConnections( - [in] SHARINGCONNECTION_ENUM_FLAGS Flags, - [out, retval] INetSharingPublicConnectionCollection **ppColl); - - [propget, id(3)] - HRESULT EnumPrivateConnections( - [in] SHARINGCONNECTION_ENUM_FLAGS Flags, - [out, retval] INetSharingPrivateConnectionCollection **ppColl); - - [propget, id(6)] - HRESULT INetSharingConfigurationForINetConnection( - [in] INetConnection *pNetConnection, - [out, retval] INetSharingConfiguration **ppNetSharingConfiguration); - - [propget, id(7)] - HRESULT EnumEveryConnection([out, retval] INetSharingEveryConnectionCollection **ppColl); - - [propget, id(8)] - HRESULT NetConnectionProps( - [in] INetConnection *pNetConnection, - [out, retval] INetConnectionProps **ppProps); -} diff --git a/include/ntddndis.h b/include/ntddndis.h deleted file mode 100644 index 44566e861e9..00000000000 --- a/include/ntddndis.h +++ /dev/null @@ -1,168 +0,0 @@ -/* - * Copyright 2009 Jacek Caban for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#ifndef _NTDDNDIS_ -#define _NTDDNDIS_ - -#ifdef __cplusplus -extern "C" { -#endif - -/* #include */ -/* #include */ -/* #include */ - -#define _NDIS_CONTROL_CODE(request, method) \ - CTL_CODE(FILE_DEVICE_PHYSICAL_NETCARD, request, method, FILE_ANY_ACCESS) - -#define IOCTL_NDIS_QUERY_GLOBAL_STATS _NDIS_CONTROL_CODE(0, METHOD_OUT_DIRECT) -#define IOCTL_NDIS_QUERY_ALL_STATS _NDIS_CONTROL_CODE(1, METHOD_OUT_DIRECT) -#define IOCTL_NDIS_DO_PNP_OPERATION _NDIS_CONTROL_CODE(2, METHOD_BUFFERED) -#define IOCTL_NDIS_QUERY_SELECTED_STATS _NDIS_CONTROL_CODE(3, METHOD_OUT_DIRECT) -#define IOCTL_NDIS_ENUMERATE_INTERFACES _NDIS_CONTROL_CODE(4, METHOD_BUFFERED) -#define IOCTL_NDIS_ADD_TDI_DEVICE _NDIS_CONTROL_CODE(5, METHOD_BUFFERED) -#define IOCTL_NDIS_GET_LOG_DATA _NDIS_CONTROL_CODE(7, METHOD_OUT_DIRECT) -#define IOCTL_NDIS_GET_VERSION _NDIS_CONTROL_CODE(8, METHOD_BUFFERED) - -#define IOCTL_NDIS_RESERVED1 _NDIS_CONTROL_CODE(0x09, METHOD_BUFFERED) -#define IOCTL_NDIS_RESERVED2 _NDIS_CONTROL_CODE(0x0a, METHOD_BUFFERED) -#define IOCTL_NDIS_RESERVED3 _NDIS_CONTROL_CODE(0x0b, METHOD_BUFFERED) -#define IOCTL_NDIS_RESERVED4 _NDIS_CONTROL_CODE(0x0c, METHOD_BUFFERED) -#define IOCTL_NDIS_RESERVED5 CTL_CODE(FILE_DEVICE_PHYSICAL_NETCARD, 0x0d, METHOD_BUFFERED, FILE_ANY_ACCESS) -#define IOCTL_NDIS_RESERVED6 CTL_CODE(FILE_DEVICE_PHYSICAL_NETCARD, 0x0e, METHOD_BUFFERED, FILE_WRITE_ACCESS) -#define IOCTL_NDIS_RESERVED7 _NDIS_CONTROL_CODE(0x0f, METHOD_OUT_DIRECT) -#define IOCTL_NDIS_RESERVED8 _NDIS_CONTROL_CODE(0x10, METHOD_BUFFERED) -#define IOCTL_NDIS_RESERVED9 _NDIS_CONTROL_CODE(0x11, METHOD_BUFFERED) -#define IOCTL_NDIS_RESERVED10 _NDIS_CONTROL_CODE(0x12, METHOD_BUFFERED) -#define IOCTL_NDIS_RESERVED11 _NDIS_CONTROL_CODE(0x13, METHOD_BUFFERED) -#define IOCTL_NDIS_RESERVED12 _NDIS_CONTROL_CODE(0x14, METHOD_BUFFERED) -#define IOCTL_NDIS_RESERVED13 _NDIS_CONTROL_CODE(0x15, METHOD_BUFFERED) - - -#define OID_802_11_BSSID 0x0d010101 -#define OID_802_11_SSID 0x0d010102 -#define OID_802_11_NETWORK_TYPES_SUPPORTED 0x0d010203 -#define OID_802_11_NETWORK_TYPE_IN_USE 0x0d010204 -#define OID_802_11_TX_POWER_LEVEL 0x0d010205 -#define OID_802_11_RSSI 0x0d010206 -#define OID_802_11_RSSI_TRIGGER 0x0d010207 -#define OID_802_11_INFRASTRUCTURE_MODE 0x0d010108 -#define OID_802_11_FRAGMENTATION_THRESHOLD 0x0d010209 -#define OID_802_11_RTS_THRESHOLD 0x0d01020a -#define OID_802_11_NUMBER_OF_ANTENNAS 0x0d01020b -#define OID_802_11_RX_ANTENNA_SELECTED 0x0d01020c -#define OID_802_11_TX_ANTENNA_SELECTED 0x0d01020d -#define OID_802_11_SUPPORTED_RATES 0x0d01020e -#define OID_802_11_DESIRED_RATES 0x0d010210 -#define OID_802_11_CONFIGURATION 0x0d010211 -#define OID_802_11_STATISTICS 0x0d020212 -#define OID_802_11_ADD_WEP 0x0d010113 -#define OID_802_11_REMOVE_WEP 0x0d010114 -#define OID_802_11_DISASSOCIATE 0x0d010115 -#define OID_802_11_POWER_MODE 0x0d010216 -#define OID_802_11_BSSID_LIST 0x0d010217 -#define OID_802_11_AUTHENTICATION_MODE 0x0d010118 -#define OID_802_11_PRIVACY_FILTER 0x0d010119 -#define OID_802_11_BSSID_LIST_SCAN 0x0d01011a -#define OID_802_11_WEP_STATUS 0x0d01011b -#define OID_802_11_ENCRYPTION_STATUS OID_802_11_WEP_STATUS -#define OID_802_11_RELOAD_DEFAULTS 0x0d01011c -#define OID_802_11_ADD_KEY 0x0d01011d -#define OID_802_11_REMOVE_KEY 0x0d01011e -#define OID_802_11_ASSOCIATION_INFORMATION 0x0d01011f -#define OID_802_11_TEST 0x0d010120 -#define OID_802_11_MEDIA_STREAM_MODE 0x0d010121 -#define OID_802_11_CAPABILITY 0x0d010122 -#define OID_802_11_PMKID 0x0d010123 -#define OID_802_11_NON_BCAST_SSID_LIST 0x0d010124 -#define OID_802_11_RADIO_STATUS 0x0d010125 - -#define NDIS_802_11_LENGTH_SSID 32 -#define NDIS_802_11_LENGTH_RATES 8 -#define NDIS_802_11_LENGTH_RATES_EX 16 - -typedef LONG NDIS_802_11_RSSI; - -typedef struct _NDIS_802_11_CONFIGURATION_FH { - ULONG Length; - ULONG HopPattern; - ULONG HopSet; - ULONG DwellTime; -} NDIS_802_11_CONFIGURATION_FH, *PNDIS_802_11_CONFIGURATION_FH; - -typedef struct _NDIS_802_11_CONFIGURATION { - ULONG Length; - ULONG BeaconPeriod; - ULONG ATIMWindow; - ULONG DSConfig; - NDIS_802_11_CONFIGURATION_FH FHConfig; -} NDIS_802_11_CONFIGURATION, *PNDIS_802_11_CONFIGURATION; - -typedef UCHAR NDIS_802_11_MAC_ADDRESS[6]; - -typedef enum _NDIS_802_11_NETWORK_INFRASTRUCTURE { - Ndis802_11IBSS, - Ndis802_11Infrastructure, - Ndis802_11AutoUnknown, - Ndis802_11InfrastructureMax -} NDIS_802_11_NETWORK_INFRASTRUCTURE, *PNDIS_802_11_NETWORK_INFRASTRUCTURE; - -typedef enum _NDIS_802_11_NETWORK_TYPE { - Ndis802_11FH, - Ndis802_11DS, - Ndis802_11OFDM5, - Ndis802_11OFDM24, - Ndis802_11Automode, - Ndis802_11NetworkTypeMax -} NDIS_802_11_NETWORK_TYPE, *PNDIS_802_11_NETWORK_TYPE; - -typedef UCHAR NDIS_802_11_RATES[NDIS_802_11_LENGTH_RATES]; -typedef UCHAR NDIS_802_11_RATES_EX[NDIS_802_11_LENGTH_RATES_EX]; - -typedef struct _NDIS_802_11_SSID { - ULONG SsidLength; - UCHAR Ssid[NDIS_802_11_LENGTH_SSID]; -} NDIS_802_11_SSID, *PNDIS_802_11_SSID; - -typedef struct _NDIS_WLAN_BSSID { - ULONG Length; - NDIS_802_11_MAC_ADDRESS MacAddress; - UCHAR Reserved[2]; - NDIS_802_11_SSID Ssid; - ULONG Privacy; - NDIS_802_11_RSSI Rssi; - NDIS_802_11_NETWORK_TYPE NetworkTypeInUse; - NDIS_802_11_CONFIGURATION Configuration; - NDIS_802_11_NETWORK_INFRASTRUCTURE InfrastructureMode; - NDIS_802_11_RATES SupportedRates; -} NDIS_WLAN_BSSID, *PNDIS_WLAN_BSSID; - -typedef struct _NDIS_802_11_BSSID_LIST { - ULONG NumberOfItems; - NDIS_WLAN_BSSID Bssid[1]; -} NDIS_802_11_BSSID_LIST, *PNDIS_802_11_BSSID_LIST; - -#ifndef _NDIS_ -typedef int NDIS_STATUS, *PNDIS_STATUS; -#endif - -#ifdef __cplusplus -} -#endif - -#endif /* _NTDDNDIS_ */ diff --git a/include/objidl.idl b/include/objidl.idl index 2aa606579d6..29b907d03c6 100644 --- a/include/objidl.idl +++ b/include/objidl.idl @@ -2454,21 +2454,4 @@ interface IContext : IUnknown [out] IEnumContextProps **ppEnumContextProps); } -[ - local, - object, - uuid(000001c6-0000-0000-c000-000000000046), - pointer_default(unique) -] -interface IObjContext : IContext -{ - void Reserved1(); - void Reserved2(); - void Reserved3(); - void Reserved4(); - void Reserved5(); - void Reserved6(); - void Reserved7(); -} - cpp_quote("#endif /* defined USE_COM_CONTEXT_DEF */") diff --git a/include/oledb.idl b/include/oledb.idl index 31e2111420d..dd6b2181307 100644 --- a/include/oledb.idl +++ b/include/oledb.idl @@ -20,19 +20,9 @@ import "wtypes.idl"; import "oaidl.idl"; import "ocidl.idl"; import "propidl.idl"; -import "urlmon.idl"; typedef ULONG DBBYTEOFFSET; -typedef ULONG DBCOUNTITEM; +#include "dbinit.idl" #include "dbs.idl" - -#include "dbccmd.idl" -#include "dbcses.idl" #include "dbprop.idl" -#include "dbinit.idl" -#include "dbdsad.idl" -#include "sesprp.idl" -#include "opnrst.idl" -#include "binres.idl" -#include "crtrow.idl" diff --git a/include/opnrst.idl b/include/opnrst.idl deleted file mode 100644 index 07c23805fc9..00000000000 --- a/include/opnrst.idl +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (C) 2009 Huw Davies - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -[ - object, - uuid(0c733a69-2a1c-11ce-ade5-00aa0044773d), - pointer_default(unique) -] -interface IOpenRowset : IUnknown -{ - [local] - HRESULT OpenRowset([in] IUnknown *pUnkOuter, - [in, unique] DBID *pTableID, - [in, unique] DBID *pIndexID, - [in] REFIID riid, - [in] ULONG cPropertySets, - [in, out, size_is(cPropertySets)] DBPROPSET rgPropertySets[], - [out, iid_is(riid)] IUnknown **ppRowset); - - [call_as(OpenRowset)] - HRESULT RemoteOpenRowset([in] IUnknown *pUnkOuter, - [in, unique] DBID *pTableID, - [in, unique] DBID *pIndexID, - [in] REFIID riid, - [in] ULONG cPropertySets, - [in, unique, size_is(cPropertySets)] DBPROPSET *rgPropertySets, - [in, out, unique, iid_is(riid)] IUnknown **ppRowset, - [in] ULONG cTotalProps, - [out, size_is(cTotalProps)] DBPROPSTATUS *rgPropStatus, - [out] IErrorInfo **ppErrorInfoRem); - -} diff --git a/include/rtutils.h b/include/rtutils.h deleted file mode 100644 index 1e2921ab302..00000000000 --- a/include/rtutils.h +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Rtutils.h - Routing utilities / RRAS tracing - * - * Copyright (C) 2009 Alexander Scott-Johns - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#ifndef _RTUTILS_H_ -#define _RTUTILS_H_ - -#include - -#ifdef __cplusplus -extern "C" { -#endif - -DWORD WINAPI TraceRegisterExW(LPCWSTR name, DWORD flags); -DWORD WINAPI TraceRegisterExA(LPCSTR name, DWORD flags); -#define TraceRegisterEx WINELIB_NAME_AW(TraceRegisterEx) - -#define TraceRegisterW(name) TraceRegisterExW((name), 0) -#define TraceRegisterA(name) TraceRegisterExA((name), 0) -#define TraceRegister WINELIB_NAME_AW(TraceRegister) - -/* Flags for TraceRegisterEx(W|A) */ -#define TRACE_USE_FILE 1 -#define TRACE_USE_CONSOLE 2 - -/* Return value of TraceRegisterEx(W|A) */ -#define INVALID_TRACEID 0xFFFFFFFF - -#ifdef __cplusplus -} -#endif - -#endif /* _RTUTILS_H_ */ diff --git a/include/sesprp.idl b/include/sesprp.idl deleted file mode 100644 index 11e63912a17..00000000000 --- a/include/sesprp.idl +++ /dev/null @@ -1,51 +0,0 @@ -/* - * Copyright (C) 2009 Huw Davies - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -[ - object, - uuid(0c733a85-2a1c-11ce-ade5-00aa0044773d), - pointer_default(unique) -] -interface ISessionProperties : IUnknown -{ - [local] - HRESULT GetProperties([in] ULONG cPropertyIDSets, - [in, size_is(cPropertyIDSets)] const DBPROPIDSET rgPropertyIDSets[], - [in, out] ULONG *pcPropertySets, - [out, size_is(,*pcPropertySets)] const DBPROPSET **prgPropertySets); - - [call_as(GetProperties)] - HRESULT RemoteGetProperties([in] ULONG cPropertyIDSets, - [in, unique, size_is(cPropertyIDSets)] const DBPROPIDSET *rgPropertyIDSets, - [in, out] ULONG *pcPropertySets, - [out, size_is(,*pcPropertySets)] const DBPROPSET **prgPropertySets, - [out] IErrorInfo **ppErrorInfoRem); - - - [local] - HRESULT SetProperties([in] ULONG cPropertySets, - [in, out, unique, size_is(cPropertySets)] DBPROPSET rgPropertySets[]); - - [call_as(SetProperties)] - HRESULT RemoteSetProperties([in] ULONG cPropertySets, - [in, unique, size_is(cPropertySets)] DBPROPSET *rgPropertySets, - [in] ULONG cTotalProps, - [out, size_is(cTotalProps)] DBPROPSTATUS *rgPropStatus, - [out] IErrorInfo **ppErrorInfoRem); - -} diff --git a/include/shlobj.h b/include/shlobj.h index c24c29ca1a6..01f8368c0b7 100644 --- a/include/shlobj.h +++ b/include/shlobj.h @@ -514,31 +514,6 @@ DECLARE_INTERFACE_(IACList2,IACList) #define IACList2_SetOptions(p,a) (p)->lpVtbl->SetOptions(p,a) #endif -/**************************************************************************** - * IShellFolderViewCB interface - */ - -#define INTERFACE IShellFolderViewCB -DECLARE_INTERFACE_(IShellFolderViewCB,IUnknown) -{ - /*** IUnknown methods ***/ - STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE; - STDMETHOD_(ULONG,AddRef)(THIS) PURE; - STDMETHOD_(ULONG,Release)(THIS) PURE; - /*** IShellFolderViewCB methods ***/ - STDMETHOD(MessageSFVCB)(THIS_ UINT uMsg, WPARAM wParam, LPARAM lParam) PURE; -}; -#undef INTERFACE - -#if !defined(__cplusplus) || defined(CINTERFACE) -/*** IUnknown methods ***/ -#define IShellFolderViewCB_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b) -#define IShellFolderViewCB_AddRef(p) (p)->lpVtbl->AddRef(p) -#define IShellFolderViewCB_Release(p) (p)->lpVtbl->Release(p) -/*** IShellFolderViewCB methods ***/ -#define IShellFolderViewCB_MessageSFVCB(p,a,b,c) (p)->lpVtbl->MessageSFVCB(p,a,b,c) -#endif - /* IProgressDialog interface */ #define PROGDLG_NORMAL 0x00000000 #define PROGDLG_MODAL 0x00000001 @@ -762,16 +737,6 @@ HRESULT WINAPI SHCreateShellFolderViewEx(LPCSFV pshfvi, IShellView **ppshv); #define SFVM_GET_WEBVIEW_THEME 86 /* undocumented */ #define SFVM_GETDEFERREDVIEWSETTINGS 92 /* undocumented */ -typedef struct _SFV_CREATE -{ - UINT cbSize; - IShellFolder *pshf; - IShellView *psvOuter; - IShellFolderViewCB *psfvcb; -} SFV_CREATE; - -HRESULT WINAPI SHCreateShellFolderView(const SFV_CREATE *pscfv, IShellView **ppsv); - /* Types and definitions for the SFM_* parameters */ #include diff --git a/include/t2embapi.h b/include/t2embapi.h deleted file mode 100644 index f1997647d09..00000000000 --- a/include/t2embapi.h +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright (c) 2009 Andrew Nguyen - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#ifndef __WINE_T2EMBAPI_H -#define __WINE_T2EMBAPI_H - -#ifdef __cplusplus -extern "C" { -#endif - -/* Possible return values. */ -#define E_NONE 0x0000L -#define E_API_NOTIMPL 0x0001L - -typedef ULONG (WINAPIV * READEMBEDPROC)(void*,void*,ULONG); - -typedef struct -{ - unsigned short usStructSize; - unsigned short usRefStrSize; - unsigned short *pusRefStr; -} TTLOADINFO; - -LONG WINAPI TTLoadEmbeddedFont(HANDLE*,ULONG,ULONG*,ULONG,ULONG*,READEMBEDPROC, - LPVOID,LPWSTR,LPSTR,TTLOADINFO*); - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/include/textstor.idl b/include/textstor.idl index 25f7749477b..2e79e3c9bea 100644 --- a/include/textstor.idl +++ b/include/textstor.idl @@ -20,19 +20,8 @@ import "oaidl.idl"; #endif -cpp_quote("#define TS_E_INVALIDPOS MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0200)") -cpp_quote("#define TS_E_NOLOCK MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0201)") -cpp_quote("#define TS_E_NOOBJECT MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0202)") -cpp_quote("#define TS_E_NOSERVICE MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0203)") -cpp_quote("#define TS_E_NOINTERFACE MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0204)") -cpp_quote("#define TS_E_NOSELECTION MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0205)") -cpp_quote("#define TS_E_NOLAYOUT MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0206)") -cpp_quote("#define TS_E_INVALIDPOINT MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0207)") -cpp_quote("#define TS_E_SYNCHRONOUS MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0208)") cpp_quote("#define TS_E_READONLY MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0209)") -cpp_quote("#define TS_E_FORMAT MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x020a)") - -cpp_quote("#define TS_S_ASYNC MAKE_HRESULT(SEVERITY_SUCCESS, FACILITY_ITF, 0x0300)") +cpp_quote("#define TS_E_NOLOCK MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0201)") const ULONG TS_DEFAULT_SELECTION = ~0u; @@ -61,9 +50,6 @@ const WCHAR TS_CHAR_EMBEDDED = 0xfffc; const WCHAR TS_CHAR_REGION = 0x0000; const WCHAR TS_CHAR_REPLACEMENT = 0xfffd; -const DWORD TS_IAS_NOQUERY = 0x1; -const DWORD TS_IAS_QUERYONLY = 0x2; - typedef [uuid(05fcf85b-5e9c-4c3e-ab71-29471d4f38e7)] enum { TS_AE_NONE, TS_AE_START, TS_AE_END } TsActiveSelEnd; typedef [uuid(033b0df0-f193-4170-b47b-141afc247878)] enum { TS_RT_PLAIN, TS_RT_HIDDEN, TS_RT_OPAQUE } TsRunType; typedef [uuid(ef3457d9-8446-49a7-a9e6-b50d9d5f3fd9)] GUID TS_ATTRID; diff --git a/include/urlmon.idl b/include/urlmon.idl index 3c6576bb13a..13c09be9f7c 100644 --- a/include/urlmon.idl +++ b/include/urlmon.idl @@ -311,45 +311,6 @@ interface IBindStatusCallback : IUnknown } /***************************************************************************** - * IBindStatusCallbackEx interface - */ -[ - object, - uuid(aaa74ef9-8ee7-4659-88d9-f8c504da73cc), - pointer_default(unique) -] -interface IBindStatusCallbackEx : IBindStatusCallback -{ - typedef [unique] IBindStatusCallbackEx *LPBINDSTATUSCALLBACKEX; - - typedef enum { - BINDF2_DISABLEBASICOVERHTTP = 0x00000001, - BINDF2_DISABLEAUTOCOOKIEHANDLING = 0x00000002, - BINDF2_READ_DATA_GREATER_THAN_4GB = 0x00000004, - BINDF2_DISABLE_HTTP_REDIRECT_XSECURITYID = 0x00000008, - BINDF2_RESERVED_3 = 0x20000000, - BINDF2_RESERVED_2 = 0x40000000, - BINDF2_RESERVED_1 = 0x80000000, - } BINDF2; - - [local] - HRESULT GetBindInfoEx( - [out] DWORD *grfBINDF, - [in, out, unique] BINDINFO *pbindinfo, - [out] DWORD *grfBINDF2, - [out] DWORD *pdwReserved); - - [call_as(GetBindInfoEx)] - HRESULT RemoteGetBindInfoEx( - [out] DWORD *grfBINDF, - [in, out, unique] RemBINDINFO *pbindinfo, - [in, out, unique] RemSTGMEDIUM *pstgmed, - [out] DWORD *grfBINDF2, - [out] DWORD *pdwReserved); -} - - -/***************************************************************************** * IAuthenticate interface */ [ @@ -1210,26 +1171,20 @@ interface IInternetZoneManager : IUnknown URLTEMPLATE_CUSTOM = 0x00000, URLTEMPLATE_PREDEFINED_MIN = 0x10000, URLTEMPLATE_LOW = 0x10000, - URLTEMPLATE_MEDLOW = 0x10500, URLTEMPLATE_MEDIUM = 0x11000, - URLTEMPLATE_MEDHIGH = 0x11500, URLTEMPLATE_HIGH = 0x12000, URLTEMPLATE_PREDEFINED_MAX = 0x20000, } URLTEMPLATE ; typedef enum { - ZAFLAGS_CUSTOM_EDIT = 0x00000001, - ZAFLAGS_ADD_SITES = 0x00000002, - ZAFLAGS_REQUIRE_VERIFICATION = 0x00000004, - ZAFLAGS_INCLUDE_PROXY_OVERRIDE = 0x00000008, - ZAFLAGS_INCLUDE_INTRANET_SITES = 0x00000010, - ZAFLAGS_NO_UI = 0x00000020, - ZAFLAGS_SUPPORTS_VERIFICATION = 0x00000040, - ZAFLAGS_UNC_AS_INTRANET = 0x00000080, - ZAFLAGS_DETECT_INTRANET = 0x00000100, - ZAFLAGS_USE_LOCKED_ZONES = 0x00010000, - ZAFLAGS_VERIFY_TEMPLATE_SETTINGS = 0x00020000, - ZAFLAGS_NO_CACHE = 0x00040000, + ZAFLAGS_CUSTOM_EDIT = 0x00000001, + ZAFLAGS_ADD_SITES = 0x00000002, + ZAFLAGS_REQUIRE_VERIFICATION = 0x00000004, + ZAFLAGS_INCLUDE_PROXY_OVERRIDE = 0x00000008, + ZAFLAGS_INCLUDE_INTRANET_SITES = 0x00000010, + ZAFLAGS_NO_UI = 0x00000020, + ZAFLAGS_SUPPORTS_VERIFICATION = 0x00000040, + ZAFLAGS_UNC_AS_INTRANET = 0x00000080, } ZAFLAGS ; enum { @@ -1322,72 +1277,6 @@ interface IInternetZoneManager : IUnknown [in] DWORD dwReserved); } -/***************************************************************************** - * IInternetZoneManagerEx interface - */ -[ - local, - object, - uuid(A4C23339-8E06-431E-9BF4-7E711C085648), - pointer_default(unique) -] -interface IInternetZoneManagerEx : IInternetZoneManager -{ - HRESULT GetZoneActionPolicyEx( - [in] DWORD dwZone, - [in] DWORD dwAction, - [out] BYTE* pPolicy, - [in] DWORD cbPolicy, - [in] URLZONEREG urlZoneReg, - [in] DWORD dwFlags); - - HRESULT SetZoneActionPolicyEx( - [in] DWORD dwZone, - [in] DWORD dwAction, - [in] BYTE* pPolicy, - [in] DWORD cbPolicy, - [in] URLZONEREG urlZoneReg, - [in] DWORD dwFlags); - -} - -/***************************************************************************** - * IInternetZoneManagerEx2 interface - */ - -cpp_quote("#define SECURITY_IE_STATE_GREEN 0") -cpp_quote("#define SECURITY_IE_STATE_RED 1") - -[ - local, - object, - uuid(EDC17559-DD5D-4846-8EEF-8BECBA5A4ABF), - pointer_default(unique) -] -interface IInternetZoneManagerEx2 : IInternetZoneManagerEx -{ - HRESULT GetZoneAttributesEx( - [in] DWORD dwZone, - [in, out, unique] ZONEATTRIBUTES* pZoneAttributes, - [in] DWORD dwFlags); - - HRESULT GetZoneSecurityState( - [in] DWORD dwZoneIndex, - [in] BOOL fRespectPolicy, - [in, out] LPDWORD pdwState, - [in, out] BOOL *pfPolicyEncountered); - - HRESULT GetIESecurityState( - [in] BOOL fRespectPolicy, - [in, out] LPDWORD pdwState, - [in, out] BOOL *pfPolicyEncountered, - [in] BOOL fNoCache); - - HRESULT FixInsecureSettings(void); - -} - - typedef struct _tagSOFTDISTINFO { ULONG cbSize; diff --git a/include/wbemcli.idl b/include/wbemcli.idl deleted file mode 100644 index b2ac6c1d988..00000000000 --- a/include/wbemcli.idl +++ /dev/null @@ -1,211 +0,0 @@ -/* - * Copyright 2009 Hans Leidekker for CodeWeavers - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -cpp_quote("DEFINE_GUID(CLSID_WbemLocator, 0x4590f811,0x1d3A,0x11d0,0x89,0x1f,0x00,0xaa,0x00,0x4b,0x2e,0x24);") -cpp_quote("DEFINE_GUID(CLSID_WbemStatusCode, 0xeb87e1bd,0x3233,0x11d2,0xae,0xc9,0x00,0xc0,0x4f,0xb6,0x88,0x20);") - -import "objidl.idl"; - -interface IWbemContext; -interface IWbemServices; -interface IWbemStatusCodeText; - -typedef [v1_enum] enum tag_WBEMSTATUS -{ - WBEM_NO_ERROR = 0, - WBEM_S_NO_ERROR = 0, - WBEM_S_SAME = 0, - WBEM_S_FALSE = 1, - WBEM_S_ALREADY_EXISTS = 0x40001, - WBEM_S_RESET_TO_DEFAULT = 0x40002, - WBEM_S_DIFFERENT = 0x40003, - WBEM_S_TIMEDOUT = 0x40004, - WBEM_S_NO_MORE_DATA = 0x40005, - WBEM_S_OPERATION_CANCELLED = 0x40006, - WBEM_S_PENDING = 0x40007, - WBEM_S_DUPLICATE_OBJECTS = 0x40008, - WBEM_S_ACCESS_DENIED = 0x40009, - WBEM_S_PARTIAL_RESULTS = 0x40010, - WBEM_S_SOURCE_NOT_AVAILABLE = 0x40017, - WBEM_E_FAILED = 0x80041001, - WBEM_E_NOT_FOUND = 0x80041002, - WBEM_E_ACCESS_DENIED = 0x80041003, - WBEM_E_PROVIDER_FAILURE = 0x80041004, - WBEM_E_TYPE_MISMATCH = 0x80041005, - WBEM_E_OUT_OF_MEMORY = 0x80041006, - WBEM_E_INVALID_CONTEXT = 0x80041007, - WBEM_E_INVALID_PARAMETER = 0x80041008, - WBEM_E_NOT_AVAILABLE = 0x80041009, - WBEM_E_CRITICAL_ERROR = 0x8004100a, - WBEM_E_INVALID_STREAM = 0x8004100b, - WBEM_E_NOT_SUPPORTED = 0x8004100c, - WBEM_E_INVALID_SUPERCLASS = 0x8004100d, - WBEM_E_INVALID_NAMESPACE = 0x8004100e, - WBEM_E_INVALID_OBJECT = 0x8004100f, - WBEM_E_INVALID_CLASS = 0x80041010, - WBEM_E_PROVIDER_NOT_FOUND = 0x80041011, - WBEM_E_INVALID_PROVIDER_REGISTRATION = 0x80041012, - WBEM_E_PROVIDER_LOAD_FAILURE = 0x80041013, - WBEM_E_INITIALIZATION_FAILURE = 0x80041014, - WBEM_E_TRANSPORT_FAILURE = 0x80041015, - WBEM_E_INVALID_OPERATION = 0x80041016, - WBEM_E_INVALID_QUERY = 0x80041017, - WBEM_E_INVALID_QUERY_TYPE = 0x80041018, - WBEM_E_ALREADY_EXISTS = 0x80041019, - WBEM_E_OVERRIDE_NOT_ALLOWED = 0x8004101a, - WBEM_E_PROPAGATED_QUALIFIER = 0x8004101b, - WBEM_E_PROPAGATED_PROPERTY = 0x8004101c, - WBEM_E_UNEXPECTED = 0x8004101d, - WBEM_E_ILLEGAL_OPERATION = 0x8004101e, - WBEM_E_CANNOT_BE_KEY = 0x8004101f, - WBEM_E_INCOMPLETE_CLASS = 0x80041020, - WBEM_E_INVALID_SYNTAX = 0x80041021, - WBEM_E_NONDECORATED_OBJECT = 0x80041022, - WBEM_E_READ_ONLY = 0x80041023, - WBEM_E_PROVIDER_NOT_CAPABLE = 0x80041024, - WBEM_E_CLASS_HAS_CHILDREN = 0x80041025, - WBEM_E_CLASS_HAS_INSTANCES = 0x80041026, - WBEM_E_QUERY_NOT_IMPLEMENTED = 0x80041027, - WBEM_E_ILLEGAL_NULL = 0x80041028, - WBEM_E_INVALID_QUALIFIER_TYPE = 0x80041029, - WBEM_E_INVALID_PROPERTY_TYPE = 0x8004102a, - WBEM_E_VALUE_OUT_OF_RANGE = 0x8004102b, - WBEM_E_CANNOT_BE_SINGLETON = 0x8004102c, - WBEM_E_INVALID_CIM_TYPE = 0x8004102d, - WBEM_E_INVALID_METHOD = 0x8004102e, - WBEM_E_INVALID_METHOD_PARAMETERS = 0x8004102f, - WBEM_E_SYSTEM_PROPERTY = 0x80041030, - WBEM_E_INVALID_PROPERTY = 0x80041031, - WBEM_E_CALL_CANCELLED = 0x80041032, - WBEM_E_SHUTTING_DOWN = 0x80041033, - WBEM_E_PROPAGATED_METHOD = 0x80041034, - WBEM_E_UNSUPPORTED_PARAMETER = 0x80041035, - WBEM_E_MISSING_PARAMETER_ID = 0x80041036, - WBEM_E_INVALID_PARAMETER_ID = 0x80041037, - WBEM_E_NONCONSECUTIVE_PARAMETER_IDS = 0x80041038, - WBEM_E_PARAMETER_ID_ON_RETVAL = 0x80041039, - WBEM_E_INVALID_OBJECT_PATH = 0x8004103a, - WBEM_E_OUT_OF_DISK_SPACE = 0x8004103b, - WBEM_E_BUFFER_TOO_SMALL = 0x8004103c, - WBEM_E_UNSUPPORTED_PUT_EXTENSION = 0x8004103d, - WBEM_E_UNKNOWN_OBJECT_TYPE = 0x8004103e, - WBEM_E_UNKNOWN_PACKET_TYPE = 0x8004103f, - WBEM_E_MARSHAL_VERSION_MISMATCH = 0x80041040, - WBEM_E_MARSHAL_INVALID_SIGNATURE = 0x80041041, - WBEM_E_INVALID_QUALIFIER = 0x80041042, - WBEM_E_INVALID_DUPLICATE_PARAMETER = 0x80041043, - WBEM_E_TOO_MUCH_DATA = 0x80041044, - WBEM_E_SERVER_TOO_BUSY = 0x80041045, - WBEM_E_INVALID_FLAVOR = 0x80041046, - WBEM_E_CIRCULAR_REFERENCE = 0x80041047, - WBEM_E_UNSUPPORTED_CLASS_UPDATE = 0x80041048, - WBEM_E_CANNOT_CHANGE_KEY_INHERITANCE = 0x80041049, - WBEM_E_CANNOT_CHANGE_INDEX_INHERITANCE = 0x80041050, - WBEM_E_TOO_MANY_PROPERTIES = 0x80041051, - WBEM_E_UPDATE_TYPE_MISMATCH = 0x80041052, - WBEM_E_UPDATE_OVERRIDE_NOT_ALLOWED = 0x80041053, - WBEM_E_UPDATE_PROPAGATED_METHOD = 0x80041054, - WBEM_E_METHOD_NOT_IMPLEMENTED = 0x80041055, - WBEM_E_METHOD_DISABLED = 0x80041056, - WBEM_E_REFRESHER_BUSY = 0x80041057, - WBEM_E_UNPARSABLE_QUERY = 0x80041058, - WBEM_E_NOT_EVENT_CLASS = 0x80041059, - WBEM_E_MISSING_GROUP_WITHIN = 0x8004105a, - WBEM_E_MISSING_AGGREGATION_LIST = 0x8004105b, - WBEM_E_PROPERTY_NOT_AN_OBJECT = 0x8004105c, - WBEM_E_AGGREGATING_BY_OBJECT = 0x8004105d, - WBEM_E_UNINTERPRETABLE_PROVIDER_QUERY = 0x8004105f, - WBEM_E_BACKUP_RESTORE_WINMGMT_RUNNING = 0x80041060, - WBEM_E_QUEUE_OVERFLOW = 0x80041061, - WBEM_E_PRIVILEGE_NOT_HELD = 0x80041062, - WBEM_E_INVALID_OPERATOR = 0x80041063, - WBEM_E_LOCAL_CREDENTIALS = 0x80041064, - WBEM_E_CANNOT_BE_ABSTRACT = 0x80041065, - WBEM_E_AMENDED_OBJECT = 0x80041066, - WBEM_E_CLIENT_TOO_SLOW = 0x80041067, - WBEM_E_NULL_SECURITY_DESCRIPTOR = 0x80041068, - WBEM_E_TIMED_OUT = 0x80041069, - WBEM_E_INVALID_ASSOCIATION = 0x8004106a, - WBEM_E_AMBIGUOUS_OPERATION = 0x8004106b, - WBEM_E_QUOTA_VIOLATION = 0x8004106c, - WBEM_E_RESERVED_001 = 0x8004106d, - WBEM_E_RESERVED_002 = 0x8004106e, - WBEM_E_UNSUPPORTED_LOCALE = 0x8004106f, - WBEM_E_HANDLE_OUT_OF_DATE = 0x80041070, - WBEM_E_CONNECTION_FAILED = 0x80041071, - WBEM_E_INVALID_HANDLE_REQUEST = 0x80041072, - WBEM_E_PROPERTY_NAME_TOO_WIDE = 0x80041073, - WBEM_E_CLASS_NAME_TOO_WIDE = 0x80041074, - WBEM_E_METHOD_NAME_TOO_WIDE = 0x80041075, - WBEM_E_QUALIFIER_NAME_TOO_WIDE = 0x80041076, - WBEM_E_RERUN_COMMAND = 0x80041077, - WBEM_E_DATABASE_VER_MISMATCH = 0x80041078, - WBEM_E_VETO_DELETE = 0x80041079, - WBEM_E_VETO_PUT = 0x8004107a, - WBEM_E_INVALID_LOCALE = 0x80041080, - WBEM_E_PROVIDER_SUSPENDED = 0x80041081, - WBEM_E_SYNCHRONIZATION_REQUIRED = 0x80041082, - WBEM_E_NO_SCHEMA = 0x80041083, - WBEM_E_PROVIDER_ALREADY_REGISTERED = 0x80041084, - WBEM_E_PROVIDER_NOT_REGISTERED = 0x80041085, - WBEM_E_FATAL_TRANSPORT_ERROR = 0x80041086, - WBEM_E_ENCRYPTED_CONNECTION_REQUIRED = 0x80041087, - WBEM_E_PROVIDER_TIMED_OUT = 0x80041088, - WBEM_E_NO_KEY = 0x80041089, - WBEM_E_PROVIDER_DISABLED = 0x8004108a -} WBEMSTATUS; - -[ - object, - restricted, - local, - uuid(dc12a687-737f-11cf-884d-00aa004b2e24), - pointer_default(unique) -] -interface IWbemLocator : IUnknown -{ - HRESULT ConnectServer( - [in] const BSTR strNetworkResource, - [in] const BSTR strUser, - [in] const BSTR strPassword, - [in] const BSTR strLocale, - [in] LONG lSecurityFlags, - [in] const BSTR strAuthority, - [in] IWbemContext *pCtx, - [out] IWbemServices **ppNamespace); -}; - -[ - object, - local, - uuid(eb87e1bc-3233-11d2-aec9-00c04fb68820) -] -interface IWbemStatusCodeText : IUnknown -{ - HRESULT GetErrorCodeText( - [in] HRESULT hRes, - [in] LCID LocaleId, - [in] LONG lFlags, - [out] BSTR *MessageText); - - HRESULT GetFacilityCodeText( - [in] HRESULT hRes, - [in] LCID LocaleId, - [in] LONG lFlags, - [out] BSTR *MessageText); -}; diff --git a/include/winbase.h b/include/winbase.h index 613114c6b08..0794fc6dd4d 100644 --- a/include/winbase.h +++ b/include/winbase.h @@ -1726,9 +1726,6 @@ WINBASEAPI VOID WINAPI GetSystemTimeAsFileTime(LPFILETIME); WINBASEAPI UINT WINAPI GetSystemWindowsDirectoryA(LPSTR,UINT); WINBASEAPI UINT WINAPI GetSystemWindowsDirectoryW(LPWSTR,UINT); #define GetSystemWindowsDirectory WINELIB_NAME_AW(GetSystemWindowsDirectory) -WINBASEAPI UINT WINAPI GetSystemWow64DirectoryA(LPSTR,UINT); -WINBASEAPI UINT WINAPI GetSystemWow64DirectoryW(LPWSTR,UINT); -#define GetSystemWow64Directory WINELIB_NAME_AW(GetSystemWow64Directory) WINBASEAPI DWORD WINAPI GetTapeParameters(HANDLE,DWORD,LPDWORD,LPVOID); WINBASEAPI DWORD WINAPI GetTapePosition(HANDLE,DWORD,LPDWORD,LPDWORD,LPDWORD); WINBASEAPI DWORD WINAPI GetTapeStatus(HANDLE); @@ -2136,7 +2133,6 @@ WINBASEAPI BOOL WINAPI VirtualProtectEx(HANDLE,LPVOID,SIZE_T,DWORD,LPDWOR WINBASEAPI SIZE_T WINAPI VirtualQuery(LPCVOID,PMEMORY_BASIC_INFORMATION,SIZE_T); WINBASEAPI SIZE_T WINAPI VirtualQueryEx(HANDLE,LPCVOID,PMEMORY_BASIC_INFORMATION,SIZE_T); WINBASEAPI BOOL WINAPI VirtualUnlock(LPVOID,SIZE_T); -WINBASEAPI DWORD WINAPI WTSGetActiveConsoleSessionId(void); WINBASEAPI BOOL WINAPI WaitCommEvent(HANDLE,LPDWORD,LPOVERLAPPED); WINBASEAPI BOOL WINAPI WaitForDebugEvent(LPDEBUG_EVENT,DWORD); WINBASEAPI DWORD WINAPI WaitForMultipleObjects(DWORD,const HANDLE*,BOOL,DWORD); @@ -2147,9 +2143,6 @@ WINBASEAPI BOOL WINAPI WaitNamedPipeA(LPCSTR,DWORD); WINBASEAPI BOOL WINAPI WaitNamedPipeW(LPCWSTR,DWORD); #define WaitNamedPipe WINELIB_NAME_AW(WaitNamedPipe) WINBASEAPI UINT WINAPI WinExec(LPCSTR,UINT); -WINBASEAPI BOOL WINAPI Wow64DisableWow64FsRedirection(PVOID*); -WINBASEAPI BOOLEAN WINAPI Wow64EnableWow64FsRedirection(BOOLEAN); -WINBASEAPI BOOL WINAPI Wow64RevertWow64FsRedirection(PVOID); WINBASEAPI BOOL WINAPI WriteFile(HANDLE,LPCVOID,DWORD,LPDWORD,LPOVERLAPPED); WINBASEAPI BOOL WINAPI WriteFileEx(HANDLE,LPCVOID,DWORD,LPOVERLAPPED,LPOVERLAPPED_COMPLETION_ROUTINE); WINBASEAPI BOOL WINAPI WriteFileGather(HANDLE,FILE_SEGMENT_ELEMENT*,DWORD,LPDWORD,LPOVERLAPPED); diff --git a/include/wincodec.idl b/include/wincodec.idl index 5850bea857c..abb4d088100 100644 --- a/include/wincodec.idl +++ b/include/wincodec.idl @@ -43,47 +43,9 @@ typedef enum WICBitmapAlphaChannelOption { WICBITMAPALPHACHANNELOPTIONS_FORCE_DWORD = CODEC_FORCE_DWORD } WICBitmapAlphaChannelOption; -typedef enum WICBitmapDecoderCapabilities { - WICBitmapDecoderCapabilitySameEncoder = 0x00000001, - WICBitmapDecoderCapabilityCanDecodeAllImages = 0x00000002, - WICBitmapDecoderCapabilityCanDecodeSomeImages = 0x00000004, - WICBitmapDecoderCapabilityCanEnumerateMetadata = 0x00000008, - WICBitmapDecoderCapabilityCanDecodeThumbnail = 0x00000010, -} WICBitmapDecoderCapabilities; - -typedef enum WICBitmapPaletteType { - WICBitmapPaletteTypeCustom = 0x00000000, - WICBitmapPaletteTypeMedianCut = 0x00000001, - WICBitmapPaletteTypeFixedBW = 0x00000002, - WICBitmapPaletteTypeFixedHalftone8 = 0x00000003, - WICBitmapPaletteTypeFixedHalftone27 = 0x00000004, - WICBitmapPaletteTypeFixedHalftone64 = 0x00000005, - WICBitmapPaletteTypeFixedHalftone125 = 0x00000006, - WICBitmapPaletteTypeFixedHalftone216 = 0x00000007, - WICBitmapPaletteTypeFixedWebPalette = WICBitmapPaletteTypeFixedHalftone216, - WICBitmapPaletteTypeFixedHalftone252 = 0x00000008, - WICBitmapPaletteTypeFixedHalftone256 = 0x00000009, - WICBitmapPaletteTypeFixedGray4 = 0x0000000A, - WICBitmapPaletteTypeFixedGray16 = 0x0000000B, - WICBitmapPaletteTypeFixedGray256 = 0x0000000C, - WICBITMAPPALETTETYPE_FORCE_DWORD = CODEC_FORCE_DWORD -} WICBitmapPaletteType; - typedef GUID WICPixelFormatGUID; typedef REFGUID REFWICPixelFormatGUID; -cpp_quote("DEFINE_GUID(GUID_WICPixelFormatDontCare, 0x6fddc324,0x4e03,0x4bfe,0xb1,0x85,0x3d,0x77,0x76,0x8d,0xc9,0x00);") -cpp_quote("#define GUID_WICPixelFormatUndefined GUID_WICPixelFormatDontCare") - -cpp_quote("DEFINE_GUID(GUID_WICPixelFormat1bppIndexed, 0x6fddc324,0x4e03,0x4bfe,0xb1,0x85,0x3d,0x77,0x76,0x8d,0xc9,0x01);") -cpp_quote("DEFINE_GUID(GUID_WICPixelFormat2bppIndexed, 0x6fddc324,0x4e03,0x4bfe,0xb1,0x85,0x3d,0x77,0x76,0x8d,0xc9,0x02);") -cpp_quote("DEFINE_GUID(GUID_WICPixelFormat4bppIndexed, 0x6fddc324,0x4e03,0x4bfe,0xb1,0x85,0x3d,0x77,0x76,0x8d,0xc9,0x03);") -cpp_quote("DEFINE_GUID(GUID_WICPixelFormat8bppIndexed, 0x6fddc324,0x4e03,0x4bfe,0xb1,0x85,0x3d,0x77,0x76,0x8d,0xc9,0x04);") - -cpp_quote("DEFINE_GUID(GUID_WICPixelFormat16bppBGR555, 0x6fddc324,0x4e03,0x4bfe,0xb1,0x85,0x3d,0x77,0x76,0x8d,0xc9,0x09);") -cpp_quote("DEFINE_GUID(GUID_WICPixelFormat24bppBGR, 0x6fddc324,0x4e03,0x4bfe,0xb1,0x85,0x3d,0x77,0x76,0x8d,0xc9,0x0c);") -cpp_quote("DEFINE_GUID(GUID_WICPixelFormat32bppBGR, 0x6fddc324,0x4e03,0x4bfe,0xb1,0x85,0x3d,0x77,0x76,0x8d,0xc9,0x0e);") - typedef struct WICRect { INT X; INT Y; @@ -91,13 +53,6 @@ typedef struct WICRect { INT Height; } WICRect; -typedef UINT32 WICColor; - -cpp_quote("#define WINCODEC_ERR_WRONGSTATE 0x88982f04") -cpp_quote("#define WINCODEC_ERR_CODECNOTHUMBNAIL 0x88982f44") -cpp_quote("#define WINCODEC_ERR_PALETTEUNAVAILABLE 0x88982f45") -cpp_quote("#define WINCODEC_ERR_UNSUPPORTEDOPERATION 0x88982f81") - interface IWICBitmap; interface IWICComponentInfo; interface IWICBitmapEncoder; @@ -143,49 +98,6 @@ interface IWICBitmapSource : IUnknown [ object, - uuid(00000040-a8f2-4877-ba0a-fd2b6645fb94) -] -interface IWICPalette : IUnknown -{ - HRESULT InitializePredefined( - [in] WICBitmapPaletteType ePaletteType, - [in] BOOL fAddTransparentColor); - - HRESULT InitializeCustom( - [in, size_is(colorCount)] WICColor *pColors, - [in] UINT colorCount); - - HRESULT InitializeFromBitmap( - [in] IWICBitmapSource *pISurface, - [in] UINT colorCount, - [in] BOOL fAddTransparentColor); - - HRESULT InitializeFromPalette( - [in] IWICPalette *pIPalette); - - HRESULT GetType( - [out] WICBitmapPaletteType *pePaletteType); - - HRESULT GetColorCount( - [out] UINT *pcCount); - - HRESULT GetColors( - [in] UINT colorCount, - [out, size_is(colorCount)] WICColor *pColors, - [out] UINT *pcActualColors); - - HRESULT IsBlackWhite( - [out] BOOL *pfIsBlackWhite); - - HRESULT IsGrayscale( - [out] BOOL *pfIsGrayscale); - - HRESULT HasAlpha( - [out] BOOL *pfHasAlpha); -} - -[ - object, uuid(3b16811b-6a43-4ec9-a813-3d930c13b940) ] interface IWICBitmapFrameDecode : IWICBitmapSource @@ -390,7 +302,3 @@ cpp_quote("DEFINE_GUID(GUID_ContainerFormatJpeg, 0x19e4a5aa,0x5662,0x4fc5,0xa0,0 cpp_quote("DEFINE_GUID(GUID_ContainerFormatTiff, 0x163bcc30,0xe2e9,0x4f0b,0x96,0x1d,0xa3,0xe9,0xfd,0xb7,0x88,0xa3);") cpp_quote("DEFINE_GUID(GUID_ContainerFormatGif, 0x1f8a5601,0x7d4d,0x4cbd,0x9c,0x82,0x1b,0xc8,0xd4,0xee,0xb9,0xa5);") cpp_quote("DEFINE_GUID(GUID_ContainerFormatWmp, 0x57a37caa,0x367a,0x4540,0x91,0x6b,0xf1,0x83,0xc5,0x09,0x3a,0x4b);") - -cpp_quote("DEFINE_GUID(GUID_VendorMicrosoft, 0xf0e749ca,0xedef,0x4589,0xa7,0x3a,0xee,0x0e,0x62,0x6a,0x2a,0x2b);") - -cpp_quote("DEFINE_GUID(CATID_WICBitmapDecoders, 0x7ed96837,0x96f0,0x4812,0xb2,0x11,0xf1,0x3c,0x24,0x11,0x7e,0xd3);") diff --git a/include/wine/pthread.h b/include/wine/pthread.h new file mode 100644 index 00000000000..561c22c5221 --- /dev/null +++ b/include/wine/pthread.h @@ -0,0 +1,67 @@ +/* + * Definitions for Wine pthread emulation + * + * Copyright 2003 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#ifndef __WINE_WINE_PTHREAD_H +#define __WINE_WINE_PTHREAD_H + +struct wine_pthread_callbacks; + +#include + +#ifndef HAVE_SIGSET_T +struct sigset_t; +typedef struct sigset_t sigset_t; +#endif + +/* thread information used to creating and exiting threads */ +struct wine_pthread_thread_info +{ + void *stack_base; /* base address of the stack */ + size_t stack_size; /* size of the stack */ + void *teb_base; /* base address of the TEB */ + size_t teb_size; /* size of the TEB (possibly including signal stack) */ + unsigned short teb_sel; /* selector to use for TEB */ + int pid; /* Unix process id */ + int tid; /* Unix thread id */ + void (*entry)( struct wine_pthread_thread_info *info ); /* thread entry point */ + long exit_status; /* thread exit status when calling wine_pthread_exit_thread */ +}; + +struct wine_pthread_functions +{ + void (*init_process)( const struct wine_pthread_callbacks *callbacks, size_t size ); + void (*init_thread)( struct wine_pthread_thread_info *info ); + int (*create_thread)( struct wine_pthread_thread_info *info ); + void (*init_current_teb)( struct wine_pthread_thread_info *info ); + void * (*get_current_teb)(void); +#ifdef __GNUC__ + void (* __attribute__((noreturn)) exit_thread)( struct wine_pthread_thread_info *info ); + void (* __attribute__((noreturn)) abort_thread)( long status ); +#else + void (*exit_thread)( struct wine_pthread_thread_info *info ); + void (*abort_thread)( long status ); +#endif + int (*sigprocmask)( int how, const sigset_t *newset, sigset_t *oldset ); +}; + +extern void wine_pthread_get_functions( struct wine_pthread_functions *functions, size_t size ); +extern void wine_pthread_set_functions( const struct wine_pthread_functions *functions, size_t size ); + +#endif /* __WINE_WINE_PTHREAD_H */ diff --git a/include/wine/server_protocol.h b/include/wine/server_protocol.h index c7566ead0db..f8196860924 100644 --- a/include/wine/server_protocol.h +++ b/include/wine/server_protocol.h @@ -693,8 +693,6 @@ struct get_process_info_reply timeout_t end_time; int exit_code; int priority; - cpu_type_t cpu; - char __pad_60[4]; }; @@ -5312,6 +5310,6 @@ union generic_reply struct set_window_layered_info_reply set_window_layered_info_reply; }; -#define SERVER_PROTOCOL_VERSION 387 +#define SERVER_PROTOCOL_VERSION 386 #endif /* __WINE_WINE_SERVER_PROTOCOL_H */ diff --git a/include/wine/wined3d.idl b/include/wine/wined3d.idl index 0e87d7f04a5..31222f3c724 100644 --- a/include/wine/wined3d.idl +++ b/include/wine/wined3d.idl @@ -1691,19 +1691,16 @@ typedef struct _WINED3DTRIPATCH_INFO typedef struct _WINED3DADAPTER_IDENTIFIER { - char *driver; - UINT driver_size; - char *description; - UINT description_size; - char *device_name; - UINT device_name_size; - LARGE_INTEGER driver_version; - DWORD vendor_id; - DWORD device_id; - DWORD subsystem_id; - DWORD revision; - GUID device_identifier; - DWORD whql_level; + char *Driver; + char *Description; + char *DeviceName; + LARGE_INTEGER *DriverVersion; + DWORD *VendorId; + DWORD *DeviceId; + DWORD *SubSysId; + DWORD *Revision; + GUID *DeviceIdentifier; + DWORD *WHQLLevel; } WINED3DADAPTER_IDENTIFIER; typedef struct _WINED3DPRESENT_PARAMETERS @@ -1886,6 +1883,13 @@ typedef struct _WINED3DBUFFER_DESC UINT Size; } WINED3DBUFFER_DESC; +typedef struct glDescriptor +{ + UINT textureName, srgbTextureName; + int level; + int /*GLenum*/ target; +} glDescriptor; + typedef struct WineDirect3DStridedData { WINED3DFORMAT format; /* Format of the data */ @@ -2525,6 +2529,9 @@ interface IWineD3DSurface : IWineD3DResource HRESULT SetContainer( [in] IWineD3DBase *container ); + void GetGlDesc( + [out] glDescriptor **desc + ); const void *GetData( ); HRESULT SetFormat( diff --git a/include/wingdi.h b/include/wingdi.h index 0e5d5e6b507..a6cdd640979 100644 --- a/include/wingdi.h +++ b/include/wingdi.h @@ -1775,14 +1775,14 @@ typedef struct tagEXTLOGPEN /* Device-independent bitmaps */ -typedef struct tagRGBQUAD { +typedef struct { BYTE rgbBlue; BYTE rgbGreen; BYTE rgbRed; BYTE rgbReserved; } RGBQUAD, *LPRGBQUAD; -typedef struct tagRGBTRIPLE { +typedef struct { BYTE rgbtBlue; BYTE rgbtGreen; BYTE rgbtRed; diff --git a/include/winternl.h b/include/winternl.h index 6d0b4805d93..b386787218d 100644 --- a/include/winternl.h +++ b/include/winternl.h @@ -2512,8 +2512,6 @@ NTSYSAPI BOOLEAN WINAPI RtlValidSid(PSID); NTSYSAPI BOOLEAN WINAPI RtlValidateHeap(HANDLE,ULONG,LPCVOID); NTSYSAPI NTSTATUS WINAPI RtlVerifyVersionInfo(const RTL_OSVERSIONINFOEXW*,DWORD,DWORDLONG); NTSYSAPI NTSTATUS WINAPI RtlWalkHeap(HANDLE,PVOID); -NTSYSAPI NTSTATUS WINAPI RtlWow64EnableFsRedirection(BOOLEAN); -NTSYSAPI NTSTATUS WINAPI RtlWow64EnableFsRedirectionEx(ULONG,ULONG*); NTSYSAPI NTSTATUS WINAPI RtlWriteRegistryValue(ULONG,PCWSTR,PCWSTR,ULONG,PVOID,ULONG); NTSYSAPI NTSTATUS WINAPI RtlpNtCreateKey(PHANDLE,ACCESS_MASK,const OBJECT_ATTRIBUTES*,ULONG,const UNICODE_STRING*,ULONG,PULONG); NTSYSAPI NTSTATUS WINAPI RtlpNtEnumerateSubKey(HANDLE,UNICODE_STRING *, ULONG); diff --git a/libs/port/interlocked.c b/libs/port/interlocked.c index cefbb5e467d..fc40fe5970c 100644 --- a/libs/port/interlocked.c +++ b/libs/port/interlocked.c @@ -40,11 +40,7 @@ __ASM_GLOBAL_FUNC(interlocked_cmpxchg_ptr, "ret") __ASM_GLOBAL_FUNC(interlocked_cmpxchg64, "push %ebx\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %ebx,0\n\t") "push %esi\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %esi,0\n\t") "movl 12(%esp),%esi\n\t" "movl 16(%esp),%ebx\n\t" "movl 20(%esp),%ecx\n\t" @@ -52,11 +48,7 @@ __ASM_GLOBAL_FUNC(interlocked_cmpxchg_ptr, "movl 28(%esp),%edx\n\t" "lock; cmpxchg8b (%esi)\n\t" "pop %esi\n\t" - __ASM_CFI(".cfi_same_value %esi\n\t") - __ASM_CFI(".cfi_adjust_cfa_offset -4\n\t") "pop %ebx\n\t" - __ASM_CFI(".cfi_same_value %ebx\n\t") - __ASM_CFI(".cfi_adjust_cfa_offset -4\n\t") "ret") __ASM_GLOBAL_FUNC(interlocked_xchg, "movl 8(%esp),%eax\n\t" diff --git a/libs/wine/Makefile.in b/libs/wine/Makefile.in index 7e7baf1e2e9..c84684844ea 100644 --- a/libs/wine/Makefile.in +++ b/libs/wine/Makefile.in @@ -17,14 +17,50 @@ DYNAME = libwine.$(SOVERSION).dylib INSTALLDIRS = $(DESTDIR)$(libdir) C_SRCS = \ + casemap.c \ + collation.c \ + compose.c \ + config.c \ + cptable.c \ + debug.c \ + fold.c \ + ldt.c \ + loader.c \ + mbtowc.c \ + mmap.c \ + port.c \ + sortkey.c \ + string.c \ + utf8.c \ + wctomb.c \ + wctype.c \ c_037.c \ - c_10000.c \ - c_10006.c \ - c_10007.c \ - c_10029.c \ + c_424.c \ + c_437.c \ + c_500.c \ + c_737.c \ + c_775.c \ + c_850.c \ + c_852.c \ + c_855.c \ + c_856.c \ + c_857.c \ + c_860.c \ + c_861.c \ + c_862.c \ + c_863.c \ + c_864.c \ + c_865.c \ + c_866.c \ + c_869.c \ + c_874.c \ + c_875.c \ + c_878.c \ + c_932.c \ + c_936.c \ + c_949.c \ + c_950.c \ c_1006.c \ - c_10079.c \ - c_10081.c \ c_1026.c \ c_1250.c \ c_1251.c \ @@ -36,6 +72,12 @@ C_SRCS = \ c_1257.c \ c_1258.c \ c_1361.c \ + c_10000.c \ + c_10006.c \ + c_10007.c \ + c_10029.c \ + c_10079.c \ + c_10081.c \ c_20127.c \ c_20866.c \ c_20932.c \ @@ -53,49 +95,7 @@ C_SRCS = \ c_28603.c \ c_28604.c \ c_28605.c \ - c_28606.c \ - c_424.c \ - c_437.c \ - c_500.c \ - c_737.c \ - c_775.c \ - c_850.c \ - c_852.c \ - c_855.c \ - c_856.c \ - c_857.c \ - c_860.c \ - c_861.c \ - c_862.c \ - c_863.c \ - c_864.c \ - c_865.c \ - c_866.c \ - c_869.c \ - c_874.c \ - c_875.c \ - c_878.c \ - c_932.c \ - c_936.c \ - c_949.c \ - c_950.c \ - casemap.c \ - collation.c \ - compose.c \ - config.c \ - cptable.c \ - debug.c \ - fold.c \ - ldt.c \ - loader.c \ - mbtowc.c \ - mmap.c \ - port.c \ - sortkey.c \ - string.c \ - utf8.c \ - wctomb.c \ - wctype.c + c_28606.c EXTRA_OBJS = version.o diff --git a/libs/wine/port.c b/libs/wine/port.c index 1e05e2b0b26..63070693082 100644 --- a/libs/wine/port.c +++ b/libs/wine/port.c @@ -26,10 +26,9 @@ #include #include "wine/library.h" +#include "wine/pthread.h" -/* no longer used, for backwards compatibility only */ -struct wine_pthread_functions; -static void *pthread_functions[8]; +static struct wine_pthread_functions pthread_functions; /*********************************************************************** * wine_pthread_get_functions @@ -95,29 +94,19 @@ void DECLSPEC_NORETURN wine_switch_to_stack( void (*func)(void *), void *arg, vo #if defined(__i386__) && defined(__GNUC__) __ASM_GLOBAL_FUNC( wine_call_on_stack, "pushl %ebp\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %ebp,0\n\t") "pushl %esi\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") - __ASM_CFI(".cfi_rel_offset %esi,0\n\t") - "movl %esp,%esi\n\t" - __ASM_CFI(".cfi_def_cfa_register %esi\n\t") "movl 12(%esp),%ecx\n\t" /* func */ "movl 16(%esp),%edx\n\t" /* arg */ - "movl 20(%esp),%eax\n\t" /* stack */ - "andl $~15,%eax\n\t" - "subl $12,%eax\n\t" - "movl %eax,%esp\n\t" + "movl 20(%esp),%esi\n\t" /* stack */ + "andl $~15,%esi\n\t" + "subl $12,%esi\n\t" + "xchgl %esi,%esp\n\t" "pushl %edx\n\t" "xorl %ebp,%ebp\n\t" "call *%ecx\n\t" "movl %esi,%esp\n\t" "popl %esi\n\t" - __ASM_CFI(".cfi_adjust_cfa_offset -4\n\t") - __ASM_CFI(".cfi_same_value %esi\n\t") "popl %ebp\n\t" - __ASM_CFI(".cfi_def_cfa %esp,4\n\t") - __ASM_CFI(".cfi_same_value %ebp\n\t") "ret" ) #elif defined(__i386__) && defined(_MSC_VER) __declspec(naked) int wine_call_on_stack( int (*func)(void *), void *arg, void *stack ) diff --git a/libs/wine/wctomb.c b/libs/wine/wctomb.c index 3b081d45653..966e6af693b 100644 --- a/libs/wine/wctomb.c +++ b/libs/wine/wctomb.c @@ -69,9 +69,9 @@ WCHAR compose( const WCHAR *str ) static inline int is_valid_sbcs_mapping( const struct sbcs_table *table, int flags, WCHAR wch, unsigned char ch ) { - if ((flags & WC_NO_BEST_FIT_CHARS) || ch == (unsigned char)table->info.def_char) - return (table->cp2uni[ch] == wch); - return 1; + if (flags & WC_NO_BEST_FIT_CHARS) return (table->cp2uni[ch] == wch); + if (ch != (unsigned char)table->info.def_char) return 1; + return (wch == table->info.def_unicode_char); } /* query necessary dst length for src string */ @@ -262,7 +262,8 @@ static int wcstombs_sbcs_slow( const struct sbcs_table *table, int flags, static inline int is_valid_dbcs_mapping( const struct dbcs_table *table, int flags, WCHAR wch, unsigned short ch ) { - if ((flags & WC_NO_BEST_FIT_CHARS) || ch == table->info.def_char) + if (ch == table->info.def_char && wch != table->info.def_unicode_char) return 0; + if (flags & WC_NO_BEST_FIT_CHARS) { /* check if char maps back to the same Unicode value */ if (ch & 0xff00) diff --git a/loader/Makefile.in b/loader/Makefile.in index 0ce816a21fd..afe3f73753e 100644 --- a/loader/Makefile.in +++ b/loader/Makefile.in @@ -6,7 +6,10 @@ MODULE = wine C_SRCS = \ main.c \ - preloader.c + preloader.c \ + pthread.c + +MAIN_OBJS = pthread.o main.o EXTRA_BINARIES = @EXTRA_BINARIES@ @@ -36,11 +39,11 @@ LDEXECFLAGS = @LDEXECFLAGS@ wine-preloader: preloader.o Makefile.in $(CC) -o $@ -static -nostartfiles -nodefaultlibs -Wl,-Ttext=0x7c000000 preloader.o $(LIBPORT) $(LDFLAGS) -wine: main.o Makefile.in - $(CC) -o $@ $(LDEXECFLAGS) main.o $(LIBWINE) $(LIBPORT) $(LIBPTHREAD) $(EXTRALIBS) $(LDFLAGS) $(LDRPATH_LOCAL) +wine: $(MAIN_OBJS) Makefile.in + $(CC) -o $@ $(LDEXECFLAGS) $(MAIN_OBJS) $(LIBWINE) $(LIBPORT) $(LIBPTHREAD) $(EXTRALIBS) $(LDFLAGS) $(LDRPATH_LOCAL) -wine-installed: main.o Makefile.in - $(CC) -o $@ $(LDEXECFLAGS) main.o $(LIBWINE) $(LIBPORT) $(LIBPTHREAD) $(EXTRALIBS) $(LDFLAGS) $(LDRPATH_INSTALL) +wine-installed: $(MAIN_OBJS) Makefile.in + $(CC) -o $@ $(LDEXECFLAGS) $(MAIN_OBJS) $(LIBWINE) $(LIBPORT) $(LIBPTHREAD) $(EXTRALIBS) $(LDFLAGS) $(LDRPATH_INSTALL) $(EXTRA_BINARIES:%=__install__%): $(EXTRA_BINARIES) $(DESTDIR)$(bindir) dummy f=`expr $@ : '__install__\(.*\)'` && $(INSTALL_PROGRAM) $$f $(DESTDIR)$(bindir)/$$f diff --git a/loader/main.c b/loader/main.c index 6de500e6a27..c3189ec5b10 100644 --- a/loader/main.c +++ b/loader/main.c @@ -40,9 +40,9 @@ #ifdef __APPLE__ -asm(".zerofill WINE_DOS, WINE_DOS, ___wine_dos, 0x40000000"); -asm(".zerofill WINE_SHAREDHEAP, WINE_SHAREDHEAP, ___wine_shared_heap, 0x03000000"); -extern char __wine_dos[0x40000000], __wine_shared_heap[0x03000000]; +asm(".zerofill WINE_DOS, WINE_DOS, ___wine_dos, 0x60000000"); +asm(".zerofill WINE_SHARED_HEAP, WINE_SHARED_HEAP, ___wine_shared_heap, 0x03000000"); +extern char __wine_dos[0x60000000], __wine_shared_heap[0x03000000]; static const struct wine_preload_info wine_main_preload_info[] = { @@ -215,6 +215,7 @@ int main( int argc, char *argv[] ) reserve_area( wine_main_preload_info[i].addr, wine_main_preload_info[i].size ); } + init_pthread_functions(); wine_init( argc, argv, error, sizeof(error) ); fprintf( stderr, "wine: failed to initialize: %s\n", error ); exit(1); diff --git a/loader/main.h b/loader/main.h index 7d4d4dc7726..b06423f227e 100644 --- a/loader/main.h +++ b/loader/main.h @@ -28,4 +28,10 @@ struct wine_preload_info size_t size; }; +#if defined(__GNUC__) && ((__GNUC__ > 3) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3))) +extern void init_pthread_functions(void) __attribute__((visibility ("hidden"))); +#else +extern void init_pthread_functions(void); +#endif + #endif /* __WINE_LOADER_MAIN_H */ diff --git a/loader/preloader.c b/loader/preloader.c index 087d04b68ae..11439726f76 100644 --- a/loader/preloader.c +++ b/loader/preloader.c @@ -110,7 +110,7 @@ static struct wine_preload_info preload_info[] = { { (void *)0x00000000, 0x00010000 }, /* low 64k */ { (void *)0x00010000, 0x00100000 }, /* DOS area */ - { (void *)0x00110000, 0x67ef0000 }, /* low memory area */ + { (void *)0x00110000, 0x5fef0000 }, /* low memory area */ { (void *)0x7f000000, 0x03000000 }, /* top-down allocations + shared heap + virtual heap */ { 0, 0 }, /* PE exe range set with WINEPRELOADRESERVE */ { 0, 0 } /* end of list */ diff --git a/loader/pthread.c b/loader/pthread.c new file mode 100644 index 00000000000..712bd379075 --- /dev/null +++ b/loader/pthread.c @@ -0,0 +1,241 @@ +/* + * Wine threading routines using the pthread library + * + * Copyright 2003 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "config.h" +#include "wine/port.h" + +#include +#include +#include +#ifdef HAVE_UNISTD_H +# include +#endif +#include +#include +#ifdef HAVE_SYS_MMAN_H +#include +#endif +#ifdef HAVE_MACH_MACH_H +#include +#endif +#ifdef HAVE_SYS_THR_H +#include +#include +#endif +#include +#ifdef HAVE_PTHREAD_NP_H +#include +#endif + +#include "wine/library.h" +#include "wine/pthread.h" + +static int init_done; +static int nb_threads = 1; + +#if !defined(__i386__) && !defined(__x86_64__) +static pthread_key_t teb_key; +#endif + +#if defined(__x86_64__) && defined(__linux__) +#include +extern int arch_prctl(int func, void *ptr); +#endif + +/*********************************************************************** + * init_process + * + * Initialization for a newly created process. + */ +static void init_process( const struct wine_pthread_callbacks *callbacks, size_t size ) +{ + init_done = 1; +} + + +/*********************************************************************** + * init_thread + * + * Initialization for a newly created thread. + */ +static void init_thread( struct wine_pthread_thread_info *info ) +{ + /* retrieve the stack info (except for main thread) */ + if (init_done) + { +#ifdef HAVE_PTHREAD_GETATTR_NP + pthread_attr_t attr; + pthread_getattr_np( pthread_self(), &attr ); + pthread_attr_getstack( &attr, &info->stack_base, &info->stack_size ); + pthread_attr_destroy( &attr ); +#elif defined(HAVE_PTHREAD_ATTR_GET_NP) + pthread_attr_t attr; + pthread_attr_init( &attr ); + pthread_attr_get_np( pthread_self(), &attr ); + pthread_attr_getstack( &attr, &info->stack_base, &info->stack_size ); + pthread_attr_destroy( &attr ); +#elif defined(HAVE_PTHREAD_GET_STACKSIZE_NP) && defined(HAVE_PTHREAD_GET_STACKADDR_NP) + char dummy; + info->stack_size = pthread_get_stacksize_np(pthread_self()); + info->stack_base = pthread_get_stackaddr_np(pthread_self()); + /* if base is too large assume it's the top of the stack instead */ + if ((char *)info->stack_base > &dummy) + info->stack_base = (char *)info->stack_base - info->stack_size; +#else + /* assume that the stack allocation is page aligned */ + char dummy; + size_t page_size = getpagesize(); + char *stack_top = (char *)((unsigned long)&dummy & ~(page_size - 1)) + page_size; + info->stack_base = stack_top - info->stack_size; +#endif + } +} + + +/*********************************************************************** + * create_thread + */ +static int create_thread( struct wine_pthread_thread_info *info ) +{ + pthread_t id; + pthread_attr_t attr; + int ret = 0; + + pthread_attr_init( &attr ); + pthread_attr_setstacksize( &attr, info->stack_size ); + pthread_attr_setdetachstate( &attr, PTHREAD_CREATE_DETACHED ); + pthread_attr_setscope( &attr, PTHREAD_SCOPE_SYSTEM ); /* force creating a kernel thread on Solaris */ + interlocked_xchg_add( &nb_threads, 1 ); + if (pthread_create( &id, &attr, (void * (*)(void *))info->entry, info )) + { + interlocked_xchg_add( &nb_threads, -1 ); + ret = -1; + } + pthread_attr_destroy( &attr ); + return ret; +} + + +/*********************************************************************** + * init_current_teb + * + * Set the current TEB for a new thread. + */ +static void init_current_teb( struct wine_pthread_thread_info *info ) +{ +#ifdef __i386__ + /* On the i386, the current thread is in the %fs register */ + LDT_ENTRY fs_entry; + + wine_ldt_set_base( &fs_entry, info->teb_base ); + wine_ldt_set_limit( &fs_entry, info->teb_size - 1 ); + wine_ldt_set_flags( &fs_entry, WINE_LDT_FLAGS_DATA|WINE_LDT_FLAGS_32BIT ); + wine_ldt_init_fs( info->teb_sel, &fs_entry ); +#elif defined(__x86_64__) + /* On x86_64, it's in %gs */ +# ifdef __linux__ + arch_prctl(ARCH_SET_GS, info->teb_base); +# else +# error Please define setting %gs for your architecture +# endif +#else + if (!init_done) /* first thread */ + pthread_key_create( &teb_key, NULL ); + pthread_setspecific( teb_key, info->teb_base ); +#endif + + /* set pid and tid */ + info->pid = getpid(); +#ifdef __sun + info->tid = pthread_self(); /* this should return the lwp id on solaris */ +#elif defined(__APPLE__) + info->tid = mach_thread_self(); +#elif defined(__FreeBSD__) + { + long lwpid; + thr_self( &lwpid ); + info->tid = (int) lwpid; + } +#else + info->tid = gettid(); +#endif +} + + +/*********************************************************************** + * get_current_teb + */ +static void *get_current_teb(void) +{ +#ifdef __i386__ + void *ret; + __asm__( ".byte 0x64\n\tmovl 0x18,%0" : "=r" (ret) ); + return ret; +#elif defined(__x86_64__) + void *ret; + __asm__( ".byte 0x65\n\tmovq 0x30,%0" : "=r" (ret) ); + return ret; +#else + return pthread_getspecific( teb_key ); +#endif +} + + +/*********************************************************************** + * exit_thread + */ +static void DECLSPEC_NORETURN exit_thread( struct wine_pthread_thread_info *info ) +{ + if (interlocked_xchg_add( &nb_threads, -1 ) <= 1) exit( info->exit_status ); + wine_ldt_free_fs( info->teb_sel ); + if (info->teb_size) munmap( info->teb_base, info->teb_size ); + pthread_exit( (void *)info->exit_status ); +} + + +/*********************************************************************** + * abort_thread + */ +static void DECLSPEC_NORETURN abort_thread( long status ) +{ + if (interlocked_xchg_add( &nb_threads, -1 ) <= 1) _exit( status ); + pthread_exit( (void *)status ); +} + + +/*********************************************************************** + * pthread_functions + */ +static const struct wine_pthread_functions pthread_functions = +{ + init_process, + init_thread, + create_thread, + init_current_teb, + get_current_teb, + exit_thread, + abort_thread, + pthread_sigmask +}; + +void init_pthread_functions(void) +{ + wine_pthread_set_functions( &pthread_functions, sizeof(pthread_functions) ); +} diff --git a/programs/clock/De.rc b/programs/clock/De.rc index 14bd101e732..f1e794b4c3f 100644 --- a/programs/clock/De.rc +++ b/programs/clock/De.rc @@ -21,8 +21,6 @@ #include "clock_res.h" -#pragma code_page(65001) - MAIN_MENU MENU LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL { POPUP "&Einstellungen" { @@ -41,7 +39,7 @@ MAIN_MENU MENU LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL POPUP "Inf&o" { MENUITEM "&Lizenz...", IDM_LICENSE MENUITEM "&KEINE GARANTIE...", IDM_NOWARRANTY - MENUITEM "&Über Uhr...", IDM_ABOUT + MENUITEM "&Über Uhr...", IDM_ABOUT } } @@ -54,15 +52,15 @@ STRINGTABLE DISCARDABLE LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL { IDS_LICENSE_CAPTION, "LIZENZ" IDS_LICENSE, -"Diese Bibliothek ist freie Software; Sie dürfen sie unter den \ +"Diese Bibliothek ist freie Software; Sie dürfen sie unter den \ Bedingungen der GNU Lesser General Public License, wie von der \ -Free Software Foundation veröffentlicht, weiterverteilen und/oder \ -modifizieren; entweder gemäß Version 2.1 der Lizenz oder (nach \ -Ihrer Option) jeder späteren Version.\n\ -Diese Bibliothek wird in der Hoffnung weiterverbreitet, daß sie \ -nützlich sein wird, jedoch OHNE IRGENDEINE GARANTIE, auch ohne \ +Free Software Foundation veröffentlicht, weiterverteilen und/oder \ +modifizieren; entweder gemäß Version 2.1 der Lizenz oder (nach \ +Ihrer Option) jeder späteren Version.\n\ +Diese Bibliothek wird in der Hoffnung weiterverbreitet, daß sie \ +nützlich sein wird, jedoch OHNE IRGENDEINE GARANTIE, auch ohne \ die implizierte Garantie der MARKTREIFE oder der VERWENDBARKEIT \ -FÜR EINEN BESTIMMTEN ZWECK. Mehr Details finden Sie in der \ +FÜR EINEN BESTIMMTEN ZWECK. Mehr Details finden Sie in der \ GNU Lesser General Public License.\n\ Sie sollten eine Kopie der GNU Lesser General Public License zusammen \ mit dieser Bibliothek erhalten haben; falls nicht, schreiben Sie an \ @@ -71,8 +69,8 @@ Boston, MA 02110, USA." IDS_WARRANTY_CAPTION, "KEINE GARANTIE" IDS_WARRANTY, -"Diese Bibliothek wird in der Hoffnung weiterverbreitet, daß sie nützlich \ +"Diese Bibliothek wird in der Hoffnung weiterverbreitet, daß sie nützlich \ sein wird, jedoch OHNE IRGENDEINE GARANTIE, auch ohne die implizierte Garantie \ -der MARKTREIFE oder der VERWENDBARKEIT FÜR EINEN BESTIMMTEN ZWECK. Mehr Details \ +der MARKTREIFE oder der VERWENDBARKEIT FÜR EINEN BESTIMMTEN ZWECK. Mehr Details \ finden Sie in der GNU Lesser General Public License." } diff --git a/programs/clock/Fr.rc b/programs/clock/Fr.rc index c6c24ba4385..ce6aa8d590e 100644 --- a/programs/clock/Fr.rc +++ b/programs/clock/Fr.rc @@ -22,16 +22,13 @@ #include "clock_res.h" -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL MAIN_MENU MENU { - POPUP "&Propriétés" { + POPUP "&Propriétés" { MENUITEM "Ana&logique", IDM_ANALOG - MENUITEM "&Numérique", IDM_DIGITAL + MENUITEM "&Numérique", IDM_DIGITAL MENUITEM SEPARATOR MENUITEM "&Police...", IDM_FONT MENUITEM SEPARATOR @@ -45,7 +42,7 @@ MAIN_MENU MENU POPUP "Inf&o" { MENUITEM "&Licence...", IDM_LICENSE MENUITEM "AUCUNE &GARANTIE...", IDM_NOWARRANTY - MENUITEM "À &propos de l'horloge", IDM_ABOUT + MENUITEM "À &propos de l'horloge", IDM_ABOUT } } @@ -58,23 +55,23 @@ STRINGTABLE DISCARDABLE LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL { IDS_LICENSE_CAPTION, "LICENCE" IDS_LICENSE, -"Ce programme est un logiciel libre ; vous pouvez le redistribuer et/ou \ -le modifier suivant les termes de la Licence Générale Publique Limitée GNU \ -telle que publiée par la Free Software Foundation ; soit la version 2.1 \ -de la Licence, soit (à votre gré) toute version ultérieure.\n\ -Ce programme est distribué dans l'espoir qu'il sera utile, mais \ -SANS AUCUNE GARANTIE : sans même la garantie implicite de \ -COMMERCIALISABILITÉ ou d'ADÉQUATION À UN OBJECTIF PARTICULIER. Consultez \ -la Licence Générale Publique Limitée pour plus de détails.\n\ -Vous devriez avoir reçu une copie de la Licence Générale Publique Limitée \ -GNU avec ce programme ; si ce n'est pas le cas, écrivez à la : \ +"Ce programme est un logiciel libre ; vous pouvez le redistribuer et/ou \ +le modifier suivant les termes de la Licence Générale Publique Limitée GNU \ +telle que publiée par la Free Software Foundation ; soit la version 2.1 \ +de la License, soit (à votre gré) toute version ultérieure.\n\ +Ce programme est distribué dans l'espoir qu'il sera utile, mais \ +SANS AUCUNE GARANTIE : sans même la garantie implicite de \ +COMMERCIALISABILITÉ ou d'ADÉQUATION À UN OBJECTIF PARTICULIER. Consultez \ +la Licence Générale Publique Limitée pour plus de détails.\n\ +Vous devriez avoir reçu une copie de la Licence Générale Publique Limitée \ +GNU avec ce programme ; si ce n'est pas le cas, écrivez à la : \ Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, \ MA 02110-1301, USA." IDS_WARRANTY_CAPTION, "AUCUNE GARANTIE" IDS_WARRANTY, -"Ce programme est distribué dans l'espoir qu'il sera utile, mais \ -SANS AUCUNE GARANTIE : sans même la garantie implicite de \ -COMMERCIALISABILITÉ ou d'ADÉQUATION À UN OBJECTIF PARTICULIER. Consultez \ -la Licence Générale Publique Limitée pour plus de détails." +"Ce programme est distribué dans l'espoir qu'il sera utile, mais \ +SANS AUCUNE GARANTIE : sans même la garantie implicite de \ +COMMERCIALISABILITÉ ou d'ADÉQUATION À UN OBJECTIF PARTICULIER. Consultez \ +la Licence Générale Publique Limitée pour plus de détails." } diff --git a/programs/clock/It.rc b/programs/clock/It.rc index 8f5976803ba..91970b3d1e4 100644 --- a/programs/clock/It.rc +++ b/programs/clock/It.rc @@ -30,7 +30,7 @@ MAIN_MENU MENU MENUITEM "Ana&logico", IDM_ANALOG MENUITEM "Digi&tale", IDM_DIGITAL MENUITEM SEPARATOR - MENUITEM "&Carattere...", IDM_FONT + MENUITEM "&Font...", IDM_FONT MENUITEM SEPARATOR MENUITEM "&Nascondi la barra del titolo", IDM_NOTITLE MENUITEM SEPARATOR diff --git a/programs/clock/Lt.rc b/programs/clock/Lt.rc deleted file mode 100644 index e516f4acb6b..00000000000 --- a/programs/clock/Lt.rc +++ /dev/null @@ -1,79 +0,0 @@ -/* - * Clock (Lithuanian resources) - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "clock_res.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -MAIN_MENU MENU -{ - POPUP "&Savybės" { - MENUITEM "Ana&loginis", IDM_ANALOG - MENUITEM "Skai&tmeninis", IDM_DIGITAL - MENUITEM SEPARATOR - MENUITEM "&Šriftas...", IDM_FONT - MENUITEM SEPARATOR - MENUITEM "&Be lango antraštės juostos", IDM_NOTITLE - MENUITEM SEPARATOR - MENUITEM "S&ekundės", IDM_SECONDS - MENUITEM "&Data", IDM_DATE - MENUITEM SEPARATOR - MENUITEM "&Visada viršuje", IDM_ONTOP - } - POPUP "&Informacija" { - MENUITEM "&Licencija...", IDM_LICENSE - MENUITEM "JOKIŲ &GARANTIJŲ...", IDM_NOWARRANTY - MENUITEM "&Apie laikrodį...", IDM_ABOUT - } -} - -STRINGTABLE DISCARDABLE -{ -IDS_CLOCK, "Laikrodis" -} - -STRINGTABLE DISCARDABLE -{ -IDS_LICENSE_CAPTION, "LICENCIJA" -IDS_LICENSE, -"Ši programa yra laisva programinė įranga; galite ją platinti ir/ar \ -modifikuoti GNU laisvosios bendrosios viešosios licencijos (LGPL) \ -sąlygomis, kurios paskelbtos Laisvosios programinės įrangos fondo \ -(FSF); 2.1-osios arba (Jūsų pasirinkimu) bet kurios vėlesnės \ -licencijos versijos sąlygomis.\n\ -Ši programa yra platinama tikintis, kad ji bus naudinga, bet BE JOKIŲ \ -GARANTIJŲ; net be numanomų PERKAMUMO ar TINKAMUMO KONKREČIAI \ -UŽDUOČIAI garantijų. Išsamią informaciją rasite GNU laisvojoje \ -bendrojoje viešojoje licencijoje.\n\ -Jūs turėjote gauti GNU laisvosios bendrosios viešosios licencijos \ -kopiją kartu su Wine; jei negavote, rašykite adresu \ -Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, \ -Boston, MA 02110-1301, USA." - -IDS_WARRANTY_CAPTION, "JOKIŲ GARANTIJŲ" -IDS_WARRANTY, -"Ši programa yra platinama tikintis, kad ji bus naudinga, bet BE JOKIŲ \ -GARANTIJŲ; net be numanomų PERKAMUMO ar TINKAMUMO KONKREČIAI \ -UŽDUOČIAI garantijų. Išsamią informaciją rasite GNU laisvojoje \ -bendrojoje viešojoje licencijoje." -} diff --git a/programs/clock/Makefile.in b/programs/clock/Makefile.in index 1667416d1e0..093ddefbc1e 100644 --- a/programs/clock/Makefile.in +++ b/programs/clock/Makefile.in @@ -23,12 +23,10 @@ RC_SRCS = \ It.rc \ Ja.rc \ Ko.rc \ - Lt.rc \ Nl.rc \ No.rc \ Pl.rc \ Pt.rc \ - Ro.rc \ Ru.rc \ Si.rc \ Sk.rc \ diff --git a/programs/clock/Pt.rc b/programs/clock/Pt.rc index 1e64342209f..2b045836c0d 100644 --- a/programs/clock/Pt.rc +++ b/programs/clock/Pt.rc @@ -5,7 +5,7 @@ * Copyright 1999 Gustavo Junior Alves * Copyright 2002 Sylvain Petreolle * Copyright 2003 Marcelo Duarte - * Copyright 2004 Américo José Melo + * 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 @@ -24,27 +24,25 @@ #include "clock_res.h" -#pragma code_page(65001) - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN MAIN_MENU MENU { POPUP "&Propriedades" { - MENUITEM "&Analógico", IDM_ANALOG + MENUITEM "&Analógico", IDM_ANALOG MENUITEM "Digi&tal", IDM_DIGITAL MENUITEM SEPARATOR MENUITEM "&Fonte...", IDM_FONT MENUITEM SEPARATOR - MENUITEM "&Sem barra de título", IDM_NOTITLE + MENUITEM "&Sem barra de título", IDM_NOTITLE MENUITEM SEPARATOR MENUITEM "&Segundos", IDM_SECONDS MENUITEM "&Data", IDM_DATE MENUITEM SEPARATOR - MENUITEM "&Sempre visível", IDM_ONTOP + MENUITEM "&Sempre visível", IDM_ONTOP } - POPUP "&Informações" { - MENUITEM "&Licença...", IDM_LICENSE + POPUP "&Informações" { + MENUITEM "&Licença...", IDM_LICENSE MENUITEM "&SEM GARANTIA...", IDM_NOWARRANTY MENUITEM "&Sobre Clock...", IDM_ABOUT } @@ -55,20 +53,20 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE MAIN_MENU MENU { POPUP "&Propriedades" { - MENUITEM "&Analógico", IDM_ANALOG + MENUITEM "&Analógico", IDM_ANALOG MENUITEM "Digi&tal", IDM_DIGITAL MENUITEM SEPARATOR MENUITEM "Tipo de &Letra...", IDM_FONT MENUITEM SEPARATOR - MENUITEM "&Sem barra de título", IDM_NOTITLE + MENUITEM "&Sem barra de título", IDM_NOTITLE MENUITEM SEPARATOR MENUITEM "&Segundos", IDM_SECONDS MENUITEM "&Data", IDM_DATE MENUITEM SEPARATOR - MENUITEM "&Sempre visível", IDM_ONTOP + MENUITEM "&Sempre visível", IDM_ONTOP } - POPUP "&Informações" { - MENUITEM "&Licença...", IDM_LICENSE + POPUP "&Informações" { + MENUITEM "&Licença...", IDM_LICENSE MENUITEM "&SEM GARANTIA...", IDM_NOWARRANTY MENUITEM "&Acerca do Clock...", IDM_ABOUT } @@ -79,29 +77,5 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { -IDS_CLOCK, "Relógio" -} - -STRINGTABLE DISCARDABLE LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE -{ -IDS_LICENSE_CAPTION, "Licença do Wine" -IDS_LICENSE, -"O Wine é software livre; você pode redistribuí-lo e/ou \ -modificá-lo sob os termos da GNU Lesser General Public \ -License tal como publicado pela Free Software Foundation; seja a \ -versão 2.1 da Licença, ou (por sua escolha) outra versão mais recente.\n\n\ -O Wine é distribuído na esperança que seja útil, \ -mas SEM QUALQUER GARANTIA; nem sequer a garantia implícita de \ -MERCANTIBILIDADE ou FEITO PARA UM PROPÓSITO ESPECÍFICO. veja a GNU \ -Lesser General Public License para mais detalhes.\n\n\ -Deverá ter recebido uma cópia da GNU Lesser General Public \ -License com o Wine; se não, escreva à Free Software \ -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA." - -IDS_WARRANTY_CAPTION, "SEM GARANTIA" -IDS_WARRANTY, -"O Wine é distribuído na esperança que seja útil, \ -mas SEM QUALQUER GARANTIA; nem sequer a garantia implícita de \ -MERCANTIBILIDADE ou FEITO PARA UM PROPÓSITO ESPECÍFICO. veja a GNU \ -Lesser General Public License para mais detalhes." +IDS_CLOCK, "Relógio" } diff --git a/programs/clock/README b/programs/clock/README new file mode 100644 index 00000000000..8f465e36d9e --- /dev/null +++ b/programs/clock/README @@ -0,0 +1,5 @@ + + Clock for Wine + ============== + + Originally contributed by diff --git a/programs/clock/Ro.rc b/programs/clock/Ro.rc deleted file mode 100644 index a7023280c3c..00000000000 --- a/programs/clock/Ro.rc +++ /dev/null @@ -1,76 +0,0 @@ -/* - * Clock (Romanian resources) - * - * Copyright 2009 Paul Chitescu - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "clock_res.h" - -#pragma code_page(65001) - -LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL - -MAIN_MENU MENU -{ - POPUP "&Proprietăți" { - MENUITEM "Ana&logic", IDM_ANALOG - MENUITEM "Digi&tal", IDM_DIGITAL - MENUITEM SEPARATOR - MENUITEM "&Font...", IDM_FONT - MENUITEM SEPARATOR - MENUITEM "Fără &bara de titlu", IDM_NOTITLE - MENUITEM SEPARATOR - MENUITEM "&Secunde", IDM_SECONDS - MENUITEM "&Data", IDM_DATE - MENUITEM SEPARATOR - MENUITEM "T&otdeauna deasupra", IDM_ONTOP - } - POPUP "Inf&ormații" { - MENUITEM "&Licența...", IDM_LICENSE - MENUITEM "&FĂRĂ GARANȚIE...", IDM_NOWARRANTY - MENUITEM "&Despre ceas...", IDM_ABOUT - } -} - -STRINGTABLE DISCARDABLE -{ -IDS_CLOCK, "Ceas" -} - -STRINGTABLE DISCARDABLE LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL -{ -IDS_LICENSE_CAPTION, "LICENȚĂ" -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.\n\ -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 \ -Lesser General Public License for more details.\n\ -You should have received a copy of the GNU Lesser General Public \ -License along with this program; if not, write to the Free Software \ -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA" - -IDS_WARRANTY_CAPTION, "FĂRĂ GARANȚIE" -IDS_WARRANTY, -"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 \ -Lesser General Public License for more details." -} diff --git a/programs/clock/Ru.rc b/programs/clock/Ru.rc index 71bd67fdf54..df5b4897c67 100644 --- a/programs/clock/Ru.rc +++ b/programs/clock/Ru.rc @@ -20,34 +20,29 @@ #include "clock_res.h" -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT - -MAIN_MENU MENU +MAIN_MENU MENU LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT { - POPUP "&Свойства" { - MENUITEM "&Аналовые", IDM_ANALOG - MENUITEM "&Цифровые", IDM_DIGITAL + POPUP "&Ñâîéñòâà" { + MENUITEM "&Àíàëîâûå", IDM_ANALOG + MENUITEM "&Öèôðîâûå", IDM_DIGITAL MENUITEM SEPARATOR - MENUITEM "&Шрифт...", IDM_FONT + MENUITEM "&Øðèôò...", IDM_FONT MENUITEM SEPARATOR - MENUITEM "&Без заголовка", IDM_NOTITLE + MENUITEM "&Áåç çàãîëîâêà", IDM_NOTITLE MENUITEM SEPARATOR - MENUITEM "&Секунды", IDM_SECONDS - MENUITEM "&Дата", IDM_DATE + MENUITEM "&Ñåêóíäû", IDM_SECONDS + MENUITEM "&Äàòà", IDM_DATE MENUITEM SEPARATOR - MENUITEM "&Поверх всех", IDM_ONTOP + MENUITEM "&Ïîâåðõ âñåõ", IDM_ONTOP } - POPUP "&Сведения" { - MENUITEM "&Лицензия...", IDM_LICENSE - MENUITEM "&БЕЗ ГАРАНТИЙ...", IDM_NOWARRANTY - MENUITEM "&О программе...", IDM_ABOUT + POPUP "&Ñâåäåíèÿ" { + MENUITEM "&Ëèöåíçèÿ...", IDM_LICENSE + MENUITEM "&ÁÅÇ ÃÀÐÀÍÒÈÉ...", IDM_NOWARRANTY + MENUITEM "&Î ïðîãðàììå...", IDM_ABOUT } } -STRINGTABLE DISCARDABLE +STRINGTABLE DISCARDABLE LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT { -IDS_CLOCK, "Часы" +IDS_CLOCK, "×àñû" } diff --git a/programs/clock/TODO b/programs/clock/TODO new file mode 100644 index 00000000000..70f57f8831a --- /dev/null +++ b/programs/clock/TODO @@ -0,0 +1,4 @@ +'L button move', 'No title bar' & 'Always on top' don't work unless Wine is in +desktop mode + +This is a problem in Wine, not in Clock diff --git a/programs/cmd/Cs.rc b/programs/cmd/Cs.rc index 7c634450306..15ece453dcc 100644 --- a/programs/cmd/Cs.rc +++ b/programs/cmd/Cs.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wcmd.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/programs/cmd/Da.rc b/programs/cmd/Da.rc index 4bbe6886b69..9870f71ce29 100644 --- a/programs/cmd/Da.rc +++ b/programs/cmd/Da.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wcmd.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/cmd/De.rc b/programs/cmd/De.rc index 2ad3de1f7d1..ab41d334b76 100644 --- a/programs/cmd/De.rc +++ b/programs/cmd/De.rc @@ -3,7 +3,6 @@ * German Language Support * * Copyright 2004 Henning Gerhardt - * Copyright 2009 André Hentschel * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -20,80 +19,76 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wcmd.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE { - WCMD_ATTRIB, "ATTRIB zeigt oder ändert die DOS Dateieigenschaften.\n" + WCMD_ATTRIB, "Hilfe für ATTRIB\n" WCMD_CALL, "CALL wird in einer Batchdatei genutzt, um Befehle aus\n\ -einer anderen Batchdatei auszuführen. Wenn die Batchdatei exisiert, kehrt\n\ -die Kontrolle zu der Datei zurück, die sie aufgerufen hat. Der CALL Befehl kann\n\ -Parameter zu der rufenden Prozedure übergeben.\n\ +einer anderen Batchdatei auszuführen. Wenn die Batchdatei exisiert, kehrt\n\ +die Kontrolle zu der Datei zurück, die sie gerufen hat. Der CALL Befehl kann\n\ +Parameter zu der rufenden Prozedure übertragen.\n\ \n\ -Änderungen für das aktuelle Verzeichnis, Umgebungsvariablen usw. werden in\n\ +Änderungen für das aktuelle Verzeichnis, Umgebungsvariablen usw. werden in\n\ der gerufenen Prozedur gemacht, die sie von der aufgerufenen geerbt hat.\n" - WCMD_CD, "CD ist die Kurzform von CHDIR.\n" - WCMD_CHDIR, "CHDIR Wechselt in ein Verzeichnis.\n" + WCMD_CD, "Hilfe für CD\n" + WCMD_CHDIR, "Hilfe für CHDIR\n" - WCMD_CLS, "CLS löscht den Bildschirminhalt der Konsole.\n" + WCMD_CLS, "CLS löscht den Inhalt der Konsole\n" - WCMD_COPY, "COPY Kopiert eine Datei.\n" - WCMD_CTTY, "CTTY Ändert das Eingabe/Ausgabe - Gerät.\n" - WCMD_DATE, "DATE zeigt oder ändert das Systemdatum.\n" - WCMD_DEL, "DEL löscht eine oder mehrere Dateien\n" - WCMD_DIR, "DIR listet den Inhalt eines Verzeichnisses.\n" + WCMD_COPY, "Hilfe für COPY\n" + WCMD_CTTY, "Hilfe für CTTY\n" + WCMD_DATE, "Hilfe für DATE\n" + WCMD_DEL, "Hilfe für DEL\n" + WCMD_DIR, "Hilfe für DIR\n" WCMD_ECHO, -"ECHO zeigt die auf dem aktuellen Terminalgerät.\n\ +"ECHO zeigt die auf dem aktuellen Terminalgerät.\n\ \n\ ECHO ON bewirkt, dass alle nachfolgenden Befehle in einer Batchdatei zuerst\n\ -auf dem Terminalgerät angezeigt und danach ausgeführt werden.\n\ +auf dem Terminalgerät angezeigt und danach ausgeführt werden.\n\ \n\ -ECHO OFF kehrt den Effekt des vorherigen ECHO ON (ECHO ist standardmässig\n\ +ECHO OFF kehrt den Effekt des vorherigen ECHO ON (ECHO ist standardmässig\n\ auf OFF) um. Um den ECHO OFF Befehl nicht anzeigen zu lassen, kann vor dessen\n\ ein @ Zeichen gesetzt werden.\n" - WCMD_ERASE, "ERASE löscht die angegebenen Dateien.\n" + WCMD_ERASE, "Hilfe für ERASE\n" WCMD_FOR, -"Der FOR Befehl wird genutzt, um einen Befehl für eine Menge von Dateien\n\ -einzeln auszuführen.\n\ +"Der FOR Befehl wird genutzt, um einen Befehl für eine Menge von Dateien\n\ +einzeln auszuführen.\n\ \n\ Syntax: FOR %Variable IN (set) DO Befehl\n\ \n\ Die Anforderung das % Zeichen zu verdoppeln, sobald FOR in einer Batchdatei\n\ -benutzt wird, existiert in CMD nicht.\n" +benutzt wird, existiert im CMD nicht.\n" WCMD_GOTO, -"Der GOTO Befehl transferiert die Ausführung zu einer anderen Stelle in einer\n\ +"Der GOTO Befehl transferiert die Ausführung zu einer anderen Stelle in einer\n\ Batchdatei.\n\ \n\ Die Bezeichnung, die das Ziel eines GOTO's ist, kann bis zu 255 Zeichen lang\n\ -sein, darf aber keine Leerzeichen enthalten (dies ist der Unterschied zu\n\ +sein, darf aber keine Leerzeichen enthakten (dies ist der Unterschied zu\n\ anderen Betriebssystemen). Wenn zwei oder mehr identische Bezeichnungen in\n\ einer Batchdatei existieren, dann wird immer zu der ersten Bezeichnung\n\ gesprungen. Versucht GOTO zu einer nicht vorhanden Bezeichnung zu springen,\n\ -beendet sich die Ausführung der Batchdatei.\n\ +beendet sich die Ausführung der Batchdatei.\n\ \n\ GOTO hat keine Auswirkungen, wenn es interaktiv genutzt wird.\n" - WCMD_HELP, "HELP zeigt die Hilfe an\n" + WCMD_HELP, "Hilfe für HELP\n" WCMD_IF, -"IF wird benutzt, um einen Befehl bedingt auszuführen.\n\ +"IF wird benutzt, um einen Befehl bedingt auszuführen.\n\ \n\ Syntax: IF [NOT] EXIST Dateiname Befehl\n\ IF [NOT] Zeichenkette1==Zeichenkette2 Befehl\n\ IF [NOT] ERRORLEVEL Nummer Befehl\n\ \n\ -In der zweiten Form des Befehls, müssen die beiden Zeichenketten in doppelten\n\ -Anführungszeichen stehen. Der Vergleich achtet nicht auf die Groß- und\n\ +In der zweiten Form des Befehls, müssen die beiden Zeichenketten in doppelten\n\ +Anführungszeichen stehen. Der Vergleich achtet nicht auf die Groß- und\n\ Kleinschreibung.\n" WCMD_LABEL, @@ -101,12 +96,12 @@ Kleinschreibung.\n" \n\ Syntax: LABEL [Laufwerk:]\n\ \n\ -Der Befehl wartet auf die Eingabe einer neuen Bezeichnung für das angegebene\n\ -Laufwerk. Sie können sich auch die Laufwerksbezeicnung mit dem VOL - Befehl\n\ +Der Befehl wartet auf die Eingabe einer neuen Bezeichnung für das angegebene\n\ +Laufwerk. Sie können sich auch die Laufwerksbezeicnung mit dem VOL - Befehl\n\ anzeigen lassen.\n" - WCMD_MD, "MD ist die Kurzform von MKDIR\n" - WCMD_MKDIR, "MKDIR erstellt ein Verzeichnis\n" + WCMD_MD, "Hilfe für MD\n" + WCMD_MKDIR, "Hilfe für MKDIR\n" WCMD_MOVE, "MOVE verschiebt eine Datei oder ein Verzeichnis zu einem neuen Punkt im\n\ Dateisystem.\n\ @@ -114,25 +109,25 @@ Dateisystem.\n\ Ist das zu verschiebende Objekt ein Verzeichnis, dann werden alle Dateien und\n\ Unterverzeichnisse unterhalb des Objektes genauso verschoben.\n\ \n\ -MOVE schlägt fehl, wenn die alte und die neue Position auf verschiedenen DOS\n\ +MOVE schlägt fehl, wenn die alte und die neue Position auf verschiedenen DOS\n\ Laufwerken sind.\n" WCMD_PATH, -"PATH ändert oder zeigt den CMD Suchpfad an.\n\ +"PATH ändert oder zeigt den CMD Suchpfad an.\n\ \n\ Nach der Eingabe von PATH, wird die aktuelle PATH Einstellung angezeigt\n\ (nach dem Start wird der Wert aus der wine.conf Datei genommen). Um die\n\ -Einstellungen zu ändern, muss nach dem PATH Befehl der neue Wert angegeben\n\ +Einstellungen zu ändern, muss nach dem PATH Befehl der neue Wert angegeben\n\ werden\n\ \n\ -Es ist auch möglich den PATH mit Hilfe der PATH Umgebungsvariable zu\n\ +Es ist auch möglich den PATH mit Hilfe der PATH Umgebungsvariable zu\n\ modifizieren. Zum Beispiel:\n\ PATH %PATH%;c:\\temp\n" WCMD_PAUSE, -"PAUSE lässt eine Meldung auf dem Bildschirm erscheinen\n\ -'Drücken Sie die Eingabetaste um fortzufahren' und wartet darauf, dass der\n\ -Benutzer die Eingabetaste/Enter-Taste drückt. Es wird hauptsächlich in\n\ +"PAUSE lässt eine Meldung auf dem Bildschirm erscheinen\n\ +'Drücken Sie die Eingabetaste um fortzufahren' und wartet darauf, dass der\n\ +Benutzer die Eingabetaste/Enter-Taste drückt. Es wird hauptsächlich in\n\ Batchdateien genutzt, um dem Beutzer zu erlauben, die Ausgabe eines vorherigen\n\ Befehls zu lesen, bevor es durch Scrollen vom Bildschirm verschwindet.\n" @@ -151,65 +146,66 @@ $l < Zeichen $n akutelles Laufwerk $p aktueller Pfad\n\ $q Gleichheitszeichen $t aktuelle Zeit $v cmd Version\n\ \n\ Hinweis: Die Eingabe des PROMPT Befehls ohne eine Prompt-Zeichenkette, setzt\n\ -den Prompt zu den Standardwert zurück, was das aktuelle Verzeichnis (inklusive\n\ -dem aktuellen Laufwerksbuchstaben) gefolgt von einen Größerzeichen (>)\n\ +den Prompt zu den Standardwert zurück, was das aktuelle Verzeichnis (inklusive\n\ +dem aktuellen Laufwerksbuchstaben) gefolgt von einen Größerzeichen (>)\n\ (genau wie der PROMPT $p$g Befehl).\n\ \n\ -Der Prompt kann auch geändert werden durch das Ändern der PROMPT\n\ +Der Prompt kann auch geändert werden durch das Ändern der PROMPT\n\ Umgebungsvariable, so hat der Befehl 'SET PROMPT=text' die gleiche Auswirkung\n\ wie 'PROMPT text'.\n" WCMD_REM, "Beginnt eine Befehlszeile mit REM (gefolgt von einem Leerzeichen), wird\n\ -keine Aktion ausgeführt und kann deshalb auch als Kommentar in einer\n\ +keine Aktion ausgeführt und kann deshalb auch als Kommentar in einer\n\ Batchdatei genutzt werden.\n" - WCMD_REN, "REN ist die Kurzform von RENAME.\n" - WCMD_RENAME, "RENAME benennt die angegebenen Dateien um.\n" - WCMD_RD, "RD ist die Kurzform von RMDIR.\n" - WCMD_RMDIR, "RMDIR löscht das angegebene Verzeichnis.\n" + WCMD_REN, "Hilfe für REN\n" + WCMD_RENAME, "Hilfe für RENAME\n" + WCMD_RD, "Hilfe für RD\n" + WCMD_RMDIR, "Hilfe für RMDIR\n" WCMD_SET, -"SET ändert oder zeigt die CMD Umgebungsvariablen an.\n\ +"SET ändert oder zeigt die CMD Umgebungsvariablen an.\n\ \n\ SET ohne Parameter zeigt alle aktuellen Umgebungsvariablen an.\n\ \n\ -Um eine Umgebungsvariable zu erschaffen oder zu ändern, ist der Syntax nötig:\n\ +Um eine Umgebungsvariable zu erschaffen oder zu ändern, ist der Syntax nötig:\n\ \n\ SET =\n\ \n\ -Wobei und Zeichenkette sind. Es dürfen keine Leerzeichen vor\n\ -dem Gleichheitszeichen sein, noch darf der Variablenname Leerzeichen enthalten.\n\ +Wobei und Zeichenkette sind. Es müssen keine Leerzeichen vor\n\ +dem Gleichheitszeichen sein, noch muss der Variablenname in Anführungszeichen\n\ +eingeschlossen sein.\n\ \n\ In Wine werden die Umgebungsvariablen des darunterliegenden Betriebssystems\n\ -mit in die Win32 Umgebung eingebunden, deshalb gibt es gewöhnlich mehr Werte\n\ -als es sie in einer ursprünglichen Win32 Realisierung gäbe. Anmerkung: Es ist\n\ -nicht möglich die Umgebungsvariablen des Betriebssystems vom CMD aus zu\n\ +mit in die Win32 Umgebung eingebunden, deshalb gibt es gewöhnlich mehr Werte\n\ +als es sie in einer ursprünglichen Win32 Realisierung gäbe. Anmerkung: Es ist\n\ +nicht möglich die Umgebungsvariablen des Betriebssystems vom CMD aus zu\n\ beeinflussen.\n" WCMD_SHIFT, "SHIFT wird in einer Batchdatei genutzt, um einen Parameter vom Anfang der\n\ Liste zu entfernen, so das der Parameter 2 zu Parameter 1 wird und so weiter.\n\ -Es hat keine Auswirkungen, wenn es von der Befehlszeile aus aufgerufen wird.\n" +Es hat keine Auswirkungen, wenn es von der Befehlszeile gerufen wird.\n" - WCMD_TIME, "TIME Setzt oder zeigt die aktuelle Systemzeit an.\n" + WCMD_TIME, "Hilfe für TIME\n" WCMD_TITLE, -"Setzt den Fenstertitel für das CMD - Fenster.\n\ +"Setzt den Fenstertitel für das CMD - Fenster.\n\ \n\ Syntax: TITLE [Zeichenkette]\n" WCMD_TYPE, -"TYPE kopiert zu dem Konsolengerät (oder dorthin, wohin\n\ -dies umgeleitet wurde). Es wird keine Überprüfung vorgenommen, ob die\n\ -Datei lesbaren Text enthält.\n" +"TYPE kopiert zu dem Konsolengerät (oder dorthin, wohin\n\ +dies umgeleitet wurde). Es wird keine Überprüfung vorgenommen, ob die\n\ +Datei lesbarer Text ist.\n" WCMD_VERIFY, -"VERIFY wird benutzt, um das Verify Flag zu setzen, zu löschen oder zu\n\ -testen. Gültige Eingaben sind:\n\ +"VERIFY wird benutzt, um das Verify Flag zu setzen, zu löschen oder zu\n\ +testen. Gültige Eingaben sind:\n\ \n\ VERIFY ON Setzt das Flag\n\ -VERIFY OFF Löscht das Flag\n\ +VERIFY OFF Löscht das Flag\n\ VERIFY Zeigt an, ob ON oder OFF verwendet wird.\n\ \n\ Das Verify Flag hat keine Funktion in Wine.\n" @@ -217,7 +213,7 @@ Das Verify Flag hat keine Funktion in Wine.\n" WCMD_VER, "VER zeigt die aktuelle Version von CMD an.\n" - WCMD_VOL, "VOL zeigt die Volumeseriennummer an\n" + WCMD_VOL, "Hilfe für VOL\n" WCMD_PUSHD, "PUSHD speichert das aktuelle\n\ Verzeichnis auf einem Stack und wecheselt das Arbeitsverzeichnis\n\ @@ -226,22 +222,22 @@ zu dem angegebenen.\n" WCMD_POPD, "POPD wechselt das Arbeitsverzeichnis zu dem zuletzt\n\ mit PUSHD gespeicherten.\n" - WCMD_MORE, "MORE gibt Dateien und Pipes seitenweise aus.\n" + WCMD_MORE, "MORE displays output of files or piped input in pages.\n" WCMD_EXIT, "EXIT beendet die aktuelle Befehlssitzung und kehrt zum\n\ -Betriebssystem oder der Shell zurück, von der CMD gestart wurde.\n" +Betriebssystem oder der Shell zurück, von der CMD gestart wurde.\n" WCMD_ALLHELP, "CMD eingebauten Befehle sind:\n\ -ATTRIB\t\tZeigt oder ändert die DOS Dateieigenschaften\n\ +ATTRIB\t\tZeigt an oder ändert die DOS Dateieigenschaften\n\ CALL\t\tRuft eine Batch-Datei innerhalb einer anderen auf\n\ -CD (CHDIR)\tWechselt in ein Verzeichnis\n\ -CLS\t\tLöscht den Inhalt der Konsole\n\ +CD (CHDIR)\tWechselt in das Verzeichnis\n\ +CLS\t\tLöscht den Inhalt der Konsole\n\ COPY\t\tKopiert eine Datei\n\ -CTTY\t\tÄndert das Eingabe/Ausgabe - Gerät\n\ -DATE\t\tZeigt oder ändert das Systemdatum\n\ -DEL (ERASE)\tLöscht eine oder mehrere Dateien\n\ +CTTY\t\tÄndert das Eingabe/Ausgabe - Gerät\n\ +DATE\t\tZeigt an oder ändert das Systemdatum\n\ +DEL (ERASE)\tLöscht eine oder mehrere Dateien\n\ DIR\t\tListet den Inhalt eines Verzeichnisses\n\ ECHO\t\tKopiert den Text direkt zur Konsolenausgabe\n\ HELP\t\tZeigt detalierte Informationen zu einen Thema\n\ @@ -249,52 +245,52 @@ MD (MKDIR)\tErzeugt ein Unterverzeichnis\n\ MORE\t\tZeigt die Ausgabe seitenweise an\n\ MOVE\t\tBewegt eine oder mehrere Dateien oder einen Verzeichnisbaum\n\ PATH\t\tSetzt oder zeigt den Suchpfad an\n\ -PROMPT\t\tÄndert den Befehlszeilenprompt\n\ +PROMPT\t\tÄndert den Befehlszeilenprompt\n\ REN (RENAME)\tBenennt eine Datei um\n\ -RD (RMDIR)\tLöscht ein Unterverzeichnis\n\ +RD (RMDIR)\tLöscht ein Unterverzeichnis\n\ SET\t\tSetzt oder zeigt die Umgebungsvariablen an\n\ TIME\t\tSetzt oder zeigt die aktuelle Systemzeit an\n\ -TITLE\t\tSetzt den Fenstertitel für die CMD - Sitzung\n\ +TITLE\t\tSetzt den Fenstertitel für die CMD - Sitzung\n\ TYPE\t\tGibt den Inhalt einer Textdatei aus\n\ VER\t\tZeigt die aktuelle Version von CMD an\n\ VOL\t\tZeigt die Bezeichnung eines Laufwerkes an\n\ EXIT\t\tBeendet den CMD\n\n\ -Geben Sie HELP ein, damit Sie weitere Informationen für einen der\n\ +Geben Sie HELP ein, damit Sie weitere Informationen für einen der\n\ obigen Befehle erhalten.\n" WCMD_CONFIRM, "Sind sie sicher" WCMD_YES, "J" WCMD_NO, "N" - WCMD_NOASSOC, "Verknüpfung für Dateiendung %s fehlt\n" - WCMD_NOFTYPE, "Kein Befehl zum Öffnen für Dateityp '%s'\n" - WCMD_OVERWRITE, "%s überschreiben" + WCMD_NOASSOC, "Verknüpfung für Dateiendung %s fehlt\n" + WCMD_NOFTYPE, "Kein Befehl zum Öffnen für Dateityp '%s'\n" + WCMD_OVERWRITE, "%s überschreiben" WCMD_MORESTR, "Mehr..." - WCMD_TRUNCATEDLINE, "Die Zeile bei der Batchverarbeitung ist möglicherweise abgeschnitten. Benutze:\n" + WCMD_TRUNCATEDLINE, "Die Zeile bei der Batchverarbeitung ist möglicherweise abgeschnitten. Benutze:\n" WCMD_NYI, "Noch nicht implementiert\n\n" WCMD_NOARG, "Argument fehlt\n" WCMD_SYNTAXERR, "Syntaxfehler\n" WCMD_FILENOTFOUND, "%s : Datei nicht gefunden\n" - WCMD_NOCMDHELP, "Hilfe für %s ist nicht verfügbar\n" + WCMD_NOCMDHELP, "Hilfe für %s ist nicht verfügbar\n" WCMD_NOTARGET, "Das Sprungziel von GOTO wurde nicht gefunden\n" WCMD_CURRENTDATE, "Aktuelles Datum ist %s\n" WCMD_CURRENTTIME, "Aktuelle Zeit ist %s\n" WCMD_NEWDATE, "Geben Sie das neue Datum ein: " WCMD_NEWTIME, "Geben Sie die neue Zeit ein: " WCMD_MISSINGENV, "Die Umgebungsvariable %s ist nicht definiert\n" - WCMD_READFAIL, "'%s' konnte nicht geöffnet werden\n" - WCMD_CALLINSCRIPT, "Kann kein Batch-Label außerhalb eines Batch-Scripts aufrufen\n" + WCMD_READFAIL, "'%s' konnte nicht geöffnet werden\n" + WCMD_CALLINSCRIPT, "Cannot call batch label outside of a batch script\n" WCMD_ALL, "A" - WCMD_DELPROMPT, "%s, löschen" + WCMD_DELPROMPT, "%s, löschen" WCMD_ECHOPROMPT, "Echo ist %s\n" WCMD_VERIFYPROMPT, "Verify ist %s\n" - WCMD_VERIFYERR, "Verify muß ON oder OFF sein\n"; + WCMD_VERIFYERR, "Verify muß ON oder OFF sein\n"; WCMD_ARGERR, "Parameterfehler\n" WCMD_VOLUMEDETAIL, "Volume in Laufwerk %c ist %s\nVolumeseriennummer ist %04x-%04x\n\n" - WCMD_VOLUMEPROMPT, "Volumebezeichnung (11 Zeichen, EINGABETASTE für keine)?" + WCMD_VOLUMEPROMPT, "Volumebezeichnung (11 Zeichen, EINGABETASTE für keine)?" WCMD_NOPATH, "PATH nicht gefunden\n" - WCMD_ANYKEY,"Drücken Sie die Eingabetaste um fortzufahren: " + WCMD_ANYKEY,"Drücken Sie die Eingabetaste um fortzufahren: " WCMD_CONSTITLE,"Wine Befehlsprozessor" WCMD_VERSION,"CMD Version %s\n\n" WCMD_MOREPROMPT, "Mehr? " - WCMD_LINETOOLONG, "Die Eingabezeile ist zu lang.\n" + WCMD_LINETOOLONG, "The input line is too long.\n" } diff --git a/programs/cmd/En.rc b/programs/cmd/En.rc index 0c31dfb03b9..941d58fb555 100644 --- a/programs/cmd/En.rc +++ b/programs/cmd/En.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wcmd.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/cmd/Es.rc b/programs/cmd/Es.rc index 1253b27a3fe..f27906a28e7 100644 --- a/programs/cmd/Es.rc +++ b/programs/cmd/Es.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wcmd.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL STRINGTABLE diff --git a/programs/cmd/Fr.rc b/programs/cmd/Fr.rc dissimilarity index 68% index 1f3837c9062..7551c766dc8 100644 --- a/programs/cmd/Fr.rc +++ b/programs/cmd/Fr.rc @@ -1,282 +1,274 @@ -/* - * Wine command prompt - * French Language Support - * - * Copyright 2003 Sylvain Petreolle - * Copyright 2007 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "wcmd.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL - -STRINGTABLE -{ - WCMD_ATTRIB, "Aide d'ATTRIB\n" - WCMD_CALL, -"CALL sert à appeler un fichier batch\n\ -depuis un autre fichier batch. Quand le fichier batch sort, le contrôle revient\n\ -au fichier qui l'a appelé. La commande CALL doit être suivie des paramètres\n\ -de la procédure appelée.\n\ -\n\ -Les changements de répertoire courant, de variables d'environnement etc. faits\n\ -dans une procédure appelée sont transmis à l'appelant.\n" - - WCMD_CD, "Aide de CD\n" - WCMD_CHDIR, "Aide de CHDIR\n" - - WCMD_CLS, -"CLS efface l'écran de la console\n" - - WCMD_COPY, "Aide de COPY\n" - WCMD_CTTY, "Aide de CTTY\n" - WCMD_DATE, "Aide de DATE\n" - WCMD_DEL, "Aide de DEL\n" - WCMD_DIR, "Aide de DIR\n" - - WCMD_ECHO, -"ECHO affiche sur la console courante.\n\ -\n\ -ECHO ON provoque l'affichage de toutes les commandes sur la console\n\ -avant leur exécution.\n\ -\n\ -ECHO OFF annule l'effet de tout ECHO ON antérieur (ECHO est OFF par\n\ -défaut). On peut empêcher l'affichage de ECHO OFF en le faisant\n\ -précéder d'un signe @.\n" - - WCMD_ERASE, "Aide de ERASE\n" - - WCMD_FOR, -"La commande FOR sert à exécuter une commande pour chaque fichier d'un groupe de fichiers.\n\ -\n\ -Syntaxe : FOR %variable IN (groupe) DO commande\n\ -\n\ -La nécessité de doubler le signe '%' lorsque l'on utilise FOR dans un fichier batch\n\ -n'existe pas dans cmd.\n" - - WCMD_GOTO, -"La commande GOTO transfère l'exécution à une autre commande (située\n\ -après une étiquette donnée) dans un fichier batch.\n\ -\n\ -L'étiquette cible du GOTO a une longueur de maximum 255 caractères\n\ -mais ne peut inclure d'espaces (à la différence d'autres systèmes\n\ -d'exploitation). Si deux étiquettes identiques (ou plus) sont dans le même\n\ -fichier, seule la première sera utilisée. Essayer de sauter vers une étiquette\n\ -non existante termine l'exécution du fichier batch.\n\ -\n\ -GOTO n'a pas d'effet si utilisé interactivement.\n" - - WCMD_HELP, "Affiche une brève aide sur les commandes internes de CMD\n" - - WCMD_IF, -"IF est utilisé pour exécuter une commande de façon conditionnelle.\n\ -\n\ -Syntaxe : IF [NOT] EXIST nomfichier commande\n\ - IF [NOT] chaîne1==chaîne2 commande\n\ - IF [NOT] ERRORLEVEL nombre commande\n\ -\n\ -Dans la deuxième forme de la commande, chaîne1 et chaîne2 doivent être\n\ -entre guillemets. La comparaison est insensible à la casse.\n" - - WCMD_LABEL, "LABEL sert à modifier le nom de volume d'un disque.\n\ -\n\ -Syntaxe : LABEL [lecteur:]\n\ -La commande demande le nouveau nom de volume pour le lecteur spécifié.\n\ -Vous pouvez afficher le nom de volume avec la commande VOL.\n" - - WCMD_MD, "Aide de MD\n" - WCMD_MKDIR, "Aide de MKDIR\n" - WCMD_MOVE, -"MOVE déplace un fichier, un groupe de fichiers ou un répertoire\n\ -à un autre endroit dans le système de fichiers. Si l'objet déplacé est un répertoire, alors\n\ -tous les fichiers et sous-répertoires de l'objet sont également déplacés.\n\ -MOVE échoue si l'ancien et le nouvel emplacement sont sur des lecteurs DOS différents.\n" - - WCMD_PATH, -"PATH affiche ou change le chemin de recherche de cmd.\n\ -\n\ -Entrer PATH seul affiche le réglage courant de PATH (initialement\n\ -c'est la valeur donnée dans le fichier wine.conf). Pour changer\n\ -le réglage, faites suivre la commande PATH par la nouvelle valeur.\n\ -Il est aussi possible de modifier le PATH en utilisant la variable\n\ -d'environnement PATH, par exemple :\n\ - PATH %PATH%;c:\\temp\n" - - WCMD_PAUSE, -"PAUSE affiche un message sur l'écran : 'Pressez Entrée pour continuer'\n\ -et attend que l'utilisateur presse la touche Entrée. PAUSE est surtout utilisé dans\n\ -les fichiers batchs pour permettre à l'utilisateur de lire la sortie de\n\ -la dernière commande avant qu'elle ne disparaisse de l'écran.\n" - - WCMD_PROMPT, -"PROMPT règle l'invite de commande.\n\ -\n\ -La chaîne suivant la commande PROMPT (ainsi que le blanc la suivant directement)\n\ -apparaît au début de la ligne quand cmd attend une entrée texte.\n\ -\n\ -Les chaînes de caractères suivantes ont une signification spéciale :\n\ -\n\ -$$ Signe dollar $_ Saut de ligne $b Barre verticale (|)\n\ -$d Date courante $e Escape $g Signe >\n\ -$l Signe < $n Lecteur courant $p Répertoire courant\n\ -$q Signe = $t Heure courante $v Version de cmd\n\ -\n\ -Notez qu'entrer la commande PROMPT sans texte d'invite remet l'invite\n\ -à sa valeur par défaut, à savoir la lettre du lecteur courant suivie de\n\ -son répertoire courant et d'un signe plus-grand-que (>).\n\ -(c.-à-d. la commande PROMPT $p$g).\n\ -\n\ -L'invite peut aussi être adaptée en modifiant la variable d'environnement\n\ - PROMPT ; ainsi la commande 'SET PROMPT=texte' a le même effet que 'PROMPT texte'\n" - - WCMD_REM, -"Une ligne de commande commençant par REM (suivi d'une espace) n'engendre\n\ -aucune action, et peut donc servir de commentaire dans un fichier batch.\n" - - WCMD_REN, "Aide de REN\n" - WCMD_RENAME, "Aide de RENAME\n" - WCMD_RD, "Aide de RD.\n" - WCMD_RMDIR, "Aide de RMDIR.\n" - - WCMD_SET, -"SET affiche ou change les variables d'environnement de cmd.\n\ -\n\ -SET sans paramètre affiche l'environnement courant.\n\ -\n\ -Pour créer et modifier une variable d'environnement, la syntaxe est :\n\ -\n\ - SET =\n\ -\n\ -où et sont des chaînes de caractères. Il ne peut y avoir aucun\n\ -espace autour du signe '=', ni dans .\n\ -\n\ -\n\ -Sous Wine, l'environnement du système hôte est\n\ -inclus dans l'environnement Win32, il y aura par conséquent généralement\n\ -bien plus de valeurs que dans un système Win32 natif. Notez qu'il\n\ -n'est pas possible de modifier l'environnement du système d'exploitation dans cmd.\n" - - WCMD_SHIFT, -"SHIFT est utilisé dans un fichier batch pour enlever le premier paramètre de la\n\ -liste ; ainsi, le paramètre 2 devient paramètre 1 et ainsi de suite. Il est sans effet\n\ -s'il est appelé depuis la ligne de commande.\n" - - WCMD_TIME, "Aide de TIME\n" - - WCMD_TITLE, -"Définit le titre de la fenêtre pour la session cmd, Syntaxe : TITLE [chaîne]\n" - - WCMD_TYPE, -"TYPE affiche sur la console (ou ailleurs\n\ -si redirigé). Aucun test n'est fait pour voir si le fichier contient bien du texte.\n" - - WCMD_VERIFY, -"VERIFY est utilisé pour positionner, effacer ou tester l'indicateur de vérification.\n\ -\n\ -Les formes suivantes sont correctes :\n\ -VERIFY ON Positionne l'indicateur\n\ -VERIFY OFF Efface l'indicateur\n\ -VERIFY\t\tAffiche l'état ON ou OFF de l'indicateur.\n\ -\n\ -L'indicateur de vérification n'a pas de fonction dans Wine.\n" - - WCMD_VER, -"VER affiche la version de cmd utilisée.\n" - - WCMD_VOL, "Aide de VOL\n" - - WCMD_PUSHD, "PUSHD enregistre le répertoire courant sur\n\ -une pile et remplace le répertoire courant par le répertoire spécifié.\n" - - WCMD_POPD, "POPD change le répertoire courant par le dernier enregistré à l'aide de\n\ -PUSHD.\n" - - WCMD_MORE, "MORE affiche le contenu de fichiers ou l'entrée standard par pages.\n" - - WCMD_EXIT, -"EXIT termine la session de ligne de commande et retourne\n\ -au système d'exploitation ou au shell où vous avez invoqué cmd.\n" - - WCMD_ALLHELP, "Les commandes intégrées de CMD sont :\n\ -ATTRIB\t\tAffiche ou modifie les attributs de fichiers DOS\n\ -CALL\t\tInvoque un fichier batch à l'intérieur d'un autre\n\ -CD (CHDIR)\tChange le répertoire courant par défaut\n\ -CLS\t\tEfface l'écran\n\ -COPY\t\tCopie un ou plusieurs fichiers\n\ -CTTY\t\tChange le périphérique d'entrée/sortie\n\ -DATE\t\tAffiche ou modifie la date système\n\ -DEL (ERASE)\tEfface un fichier ou un groupe de fichiers\n\ -DIR\t\tListe le contenu d'un répertoire\n\ -ECHO\t\tAffiche du texte sur la console\n\ -HELP\t\tAffiche de brefs détails sur l'utilisation d'une commande\n\ -MD (MKDIR)\tCrée un répertoire\n\ -MORE\t\tAffiche du texte par pages\n\ -MOVE\t\tDéplace un fichier, un groupe de fichiers ou un répertoire\n\ -PATH\t\tRègle ou affiche le chemin de recherche\n\ -POPD\t\tRemplace le répertoire courant par le dernier enregistré avec PUSHD\n\ -PROMPT\t\tChange l'invite de commande\n\ -PUSHD\t\tChange de répertoire en enregistrant le répertoire courant\n\ -REN (RENAME)\tRenomme un fichier\n\ -RD (RMDIR)\tEfface un répertoire\n\ -SET\t\tRègle ou affiche les variables d'environnement\n\ -TIME\t\tRègle ou affiche l'heure système courante\n\ -TITLE\t\tRègle le titre de la fenêtre pour la session CMD\n\ -TYPE\t\tAffiche le contenu d'un fichier texte\n\ -VER\t\tAffiche la version de cmd utilisée.\n\ -VOL\t\tAffiche le nom de volume d'un lecteur de disque\n\ -EXIT\t\tQuitte CMD\n\n\ -Entrez HELP pour plus d'informations sur les commandes ci-dessus\n" - - WCMD_CONFIRM, "Êtes-vous sûr" - WCMD_YES, "O" - WCMD_NO, "N" - WCMD_NOASSOC, "Association de fichier manquante pour l'extension %s\n" - WCMD_NOFTYPE, "Aucune commande d'ouverture n'est associée avec le type de fichier « %s »\n" - WCMD_OVERWRITE, "Écraser %s" - WCMD_MORESTR, "Plus..." - WCMD_TRUNCATEDLINE, "Ligne du processus batch probablement tronquée. Utilisation de :\n" - WCMD_NYI, "Pas encore implémenté\n\n" - WCMD_NOARG, "Argument manquant\n" - WCMD_SYNTAXERR, "Erreur de syntaxe\n" - WCMD_FILENOTFOUND, "%s : fichier non trouvé\n" - WCMD_NOCMDHELP, "Pas d'aide disponible pour %s\n" - WCMD_NOTARGET, "La destination de l'instruction GOTO n'a pas été trouvée\n" - WCMD_CURRENTDATE, "La date courante est %s\n" - WCMD_CURRENTTIME, "L'heure courante est %s\n" - WCMD_NEWDATE, "Saisissez la nouvelle date : " - WCMD_NEWTIME, "Saisissez la nouvelle heure : " - WCMD_MISSINGENV, "La variable d'environnement %s n'est pas définie\n" - WCMD_READFAIL, "Impossible d'ouvrir « %s »\n" - WCMD_CALLINSCRIPT, "Impossible d'appeler une étiquette de batch hors d'un script batch\n" - WCMD_ALL, "T" - WCMD_DELPROMPT, "%s, Supprimer" - WCMD_ECHOPROMPT, "Echo est %s\n" - WCMD_VERIFYPROMPT, "Verify est %s\n" - WCMD_VERIFYERR, "Verify doit être ON ou OFF\n"; - WCMD_ARGERR, "Erreur de paramètre\n" - WCMD_VOLUMEDETAIL, "Le volume dans le lecteur %c est %s\nLe numéro de série du volume est %04x-%04x\n\n" - WCMD_VOLUMEPROMPT, "Étiquette du volume (11 caractères, ENTRÉE pour aucun) ?" - WCMD_NOPATH, "PATH non trouvé\n" - WCMD_ANYKEY,"Appuyez sur ENTRÉE pour continuer : " - WCMD_CONSTITLE,"Invite de commande Wine" - WCMD_VERSION,"CMD version %s\n\n" - WCMD_MOREPROMPT, "Plus ? " - WCMD_LINETOOLONG, "La ligne d'entrée est trop longue.\n" -} +/* + * Wine command prompt + * French Language Support + * + * Copyright 2003 Sylvain Petreolle + * Copyright 2007 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL + +STRINGTABLE +{ + WCMD_ATTRIB, "Aide d'ATTRIB\n" + WCMD_CALL, +"CALL sert à appeler un fichier batch\n\ +depuis un autre fichier batch. Quand le fichier batch sort, le contrôle revient\n\ +au fichier qui l'a appelé. La commande CALL doit être suivie des paramètres\n\ +de la procédure appelée.\n\ +\n\ +Les changements de répertoire courant, de variables d'environment etc. faits\n\ +dans une procédure appelée sont transmis à l'appelant.\n" + + WCMD_CD, "Change le répertoire courant par défaut\n" + WCMD_CHDIR, "Change le répertoire courant par défaut\n" + + WCMD_CLS, +"CLS efface l'écran\n" + + WCMD_COPY, "Aide de COPY\n" + WCMD_CTTY, "Aide de CTTY\n" + WCMD_DATE, "Aide de DATE\n" + WCMD_DEL, "Aide de DEL\n" + WCMD_DIR, "Aide de DIR\n" + + WCMD_ECHO, +"ECHO affiche sur la console courante.\n\ +\n\ +ECHO ON provoque l'affichage de toutes les commandes sur la console\n\ +avant leur exécution.\n\ +\n\ +ECHO OFF annule l'effet de tout précédent ECHO ON (ECHO est OFF par\n\ +défaut). On peut empêcher l'affichage de ECHO OFF en le faisant\n\ +précéder d'un signe @.\n" + + WCMD_ERASE, "Aide de ERASE\n" + + WCMD_FOR, +"La commande FOR sert à exécuter une commande pour un groupe de fichiers.\n\ +\n\ +Syntaxe : FOR %variable IN (groupe) DO commande\n\ +\n\ +La nécessité de doubler le signe '%' en utilisant FOR dans un fichier batch\n\ +n'existe pas dans cmd.\n" + + WCMD_GOTO, +"La commande GOTO transfère l'exécution à un autre label dans un\n\ +fichier batch.\n\ +\n\ +Le label cible de GOTO peut être long de 255 caractères\n\ +mais ne peut inclure d'espaces (ceci est différent d'autres systèmes\n\ +d'exploitation). Si deux ou plusieurs labels identiques sont dans le même fichier\n\ +seul le premier sera exécuté. Essayer de sauter à un label non-existant\n\ +termine l'exécution du fichier batch .\n\ +\n\ +GOTO n'a pas d'effet si utilisé interactivement.\n" + + WCMD_HELP, "Affiche une brève aide sur les commandes internes de CMD\n" + + WCMD_IF, +"IF est utilisé pour exécuter une commande de façon conditionnelle.\n\ +\n\ +Syntaxe : IF [NOT] EXIST nomfichier commande\n\ + IF [NOT] chaîne1==chaîne2 commande\n\ + IF [NOT] ERRORLEVEL nombre commande\n\ +\n\ +Dans la deuxième forme de la commande, chaîne1 et chaîne2 doivent être\n\ +entre guillemets doubles. La comparaison est insensible à la casse.\n" + + WCMD_LABEL, "LABEL sert à modifier le nom de volume d'un disque.\n\ +\n\ +Syntaxe : LABEL [lecteur:]\n\ +La commnande demandera le nouveau nom de volume pour le lecteur donné.\n\ +Vous pouvez afficher le nom de volume avec la commande VOL.\n" + + WCMD_MD, "Crée le répertoire donné en paramètre.\n" + WCMD_MKDIR, "Crée le répertoire donné en paramètre.\n" + WCMD_MOVE, +"MOVE déplace un fichier, un groupe de fichiers ou un répertoire\n\ +à un autre endroit. Si l'objet déplacé est un répertoire alors\n\ +tous les fichiers et sous-répertoires de l'objet sont également déplacés.\n\ +MOVE échoue si l'ancien et le nouvel emplacement sont sur des lecteurs DOS différents.\n" + + WCMD_PATH, +"PATH affiche ou change le chemin de recherche de cmd.\n\ +Entrer PATH affichera le réglage courant de PATH (au départ\n\ +c'est la valeur donnée dans le fichier de configuration wine). Pour changer\n\ +le réglage, faites suivre la commande PATH de la nouvelle valeur.\n\ +Il est possible de modifier le PATH en utilisant la variable d'environment PATH,\n\ +par exemple :\n\ + PATH %PATH%;c:\\temp\n" + + WCMD_PAUSE, +"PAUSE affiche un message sur l'écran : 'Pressez Entrée pour continuer'\n\ +et attend que l'utilisateur presse la touche Entrée. PAUSE est surtout utilisé dans\n\ +les fichiers batchs pour permettre à l'utilisateur de lire la sortie de\n\ +la dernière commande avant qu'elle ne disparaisse de l'écran.\n" + + WCMD_PROMPT, +"PROMPT règle l'invite de commande.\n\ +\n\ +La chaîne suivant la commande PROMPT (and the space immediately after)\n\ +apparaît au début de la ligne quand cmd attend une entrée texte.\n\ +\n\ +Les chaînes de caractères suivantes ont une signification spéciale :\n\ +\n\ +$$ Signe Dollar $_ Saut de ligne $b Signe Pipe (|)\n\ +$d Date courante $e Escape $g Signe >\n\ +$l Signe < $n Lecteur courant $p Répertoire courant\n\ +$q Signe = $t Heure courante $v Version de cmd\n\ +\n\ +Notez qu'entrer la commande PROMPT sans texte d'invite remet l'invite\n\ +à la valeur par défaut, qui est la lettre du lecteur courant suivie de\n\ +son répertoire courant et d'un signe plus-grand-que (>).\n\ +(Tel que la commande PROMPT $p$g).\n\ +\n\ +L'invite peut aussi être modifiée en changeant la variable d'environment PROMPT,\n\ +donc la commande 'SET PROMPT=texte' a le même effet que 'PROMPT texte'\n" + + WCMD_REM, +"Une ligne de commande commençant par REM (suivi d'une espace) n'engendre\n\ +aucune action, et peut donc servir de commentaire dans un fichier batch.\n" + + WCMD_REN, "Aide de REN\n" + WCMD_RENAME, "Aide de RENAME\n" + WCMD_RD, "Efface le répertoire donné en paramètre.\n" + WCMD_RMDIR, "Efface le répertoire donné en paramètre.\n" + + WCMD_SET, +"SET affiche ou change les variables d'environnement de cmd.\n\ +\n\ +SET sans paramètre affiche l'environnement courant.\n\ +\n\ +Pour créer et modifier une variable d'environnement la syntaxe est:\n\ +\n\ + SET =\n\ +\n\ +où et sont des chaînes de caractères. Il est à noter que \n\ +ne peut contenir d'espace, et qu'il ne doit pas y en avoir non plus autour du signe d'égalité.\n\ +\n\ +Sous Wine, l'environment du système hôte est\n\ +inclus dans l'environnment Win32, il y aura par conséquent généralement\n\ +bien plus de valeurs que dans un système Win32 natif. Notez qu'il\n\ +n'est pas possible de modifier l'environnement du système d'exploitation dans cmd.\n" + + WCMD_SHIFT, +"SHIFT est utilisé dans un fichier batch pour enlever un paramètre de la\n\ +liste, ainsi le paramètre 2 devient paramètre 1 et ainsi de suite. Il est sans effet\n\ +s'il est appelé depuis la ligne de commande.\n" + + WCMD_TIME, "Aide de TIME\n" + + WCMD_TITLE, +"Règle le titre de la fenêtre pour la session cmd, Syntaxe : TITLE [chaîne]\n" + + WCMD_TYPE, +"TYPE affiche sur la console (ou ailleurs\n\ +si redirigé). Aucun test n'est fait quand au format texte du fichier.\n" + + WCMD_VERIFY, +"VERIFY est utilisé pour positionner, effacer ou tester le flag de vérification.\n\ +Les formes suivantes sont correctes :\n\ +VERIFY ON Positionne le flag\n\ +VERIFY OFF Efface le flag\n\ +VERIFY\t\tAffiche l'état ON ou OFF du flag.\n\ +\n\ +Le flag de verification n'a pas de fonction dans Wine.\n" + + WCMD_VER, +"VER affiche la version de cmd actuellement en mémoire.\n" + + WCMD_VOL, "Aide de VOL\n" + + WCMD_PUSHD, "PUSHD enregistre le répertoire courant sur\n\ +une pile et change le répertoire courrant par le répertoire spécifié.\n" + + WCMD_POPD, "POPD change le répertoire courant par le dernier enregistré à l'aide de\n\ +PUSHD.\n" + + WCMD_MORE, "MORE displays output of files or piped input in pages.\n" + + WCMD_EXIT, +"EXIT termine la session de ligne de commande et retourne\n\ +au système d'exploitation ou au shell où vous avez invoqué cmd.\n" + + WCMD_ALLHELP, "Les commandes internes CMD sont :\n\ +ATTRIB\t\tAffiche ou change les attributs de fichiers DOS\n\ +CALL\t\tInvoque un fichier batch à l'intérieur d'un autre\n\ +CD (CHDIR)\tChange le répertoire courant par défaut\n\ +CLS\t\tEfface l'écran\n\ +COPY\t\tCopie un ou plusieurs fichiers\n\ +CTTY\t\tChange le périphérique d'entrée/sortie\n\ +DATE\t\tAffiche ou change la date système\n\ +DEL (ERASE)\tEfface un fichier ou un groupe de fichiers\n\ +DIR\t\tListe le contenu d'un répertoire\n\ +ECHO\t\tAffiche du texte sur la console\n\ +HELP\t\tAffiche de brefs détails sur l'utilisation d'une commande\n\ +MD (MKDIR)\tCrée un répertoire\n\ +MORE\t\tDisplay output in pages\n\ +MOVE\t\tDéplace un fichier, un groupe de fichiers ou un répertoire\n\ +PATH\t\tRègle ou affiche le chemin de recherche\n\ +POPD\t\tChange le répertoire courant par le dernier enregistré avec PUSHD\n\ +PROMPT\t\tChange l'invite de commande\n\ +PUSHD\t\tChange de répertoire en enregistrant le répertoire courant\n\ +REN (RENAME)\tRenomme un fichier, un groupe de fichiers ou un répertoire\n\ +RD (RMDIR)\tEfface un répertoire\n\ +SET\t\tRègle ou affiche les variables d'environment\n\ +TIME\t\tRègle ou affiche l'heure système courante\n\ +TITLE\t\tRègle le titre de la fenêtre pour la session CMD\n\ +TYPE\t\tAffiche le contenu d'un fichier texte\n\ +VER\t\tAffiche la version de cmd actuellement en mémoire.\n\ +VOL\t\tAffiche le nom de volume d'un lecteur de disque\n\ +EXIT\t\tQuitte CMD\n\n\ +Entrez HELP pour plus d'informations sur les commandes ci-dessus\n" + + WCMD_CONFIRM, "Êtes-vous sûr" + WCMD_YES, "O" + WCMD_NO, "N" + WCMD_NOASSOC, "Association de fichier manquante pour l'extension %s\n" + WCMD_NOFTYPE, "Aucun commande d'ouverture associée avec le type de fichier « %s »\n" + WCMD_OVERWRITE, "Écraser %s" + WCMD_MORESTR, "Plus..." + WCMD_TRUNCATEDLINE, "Ligne du processus batch probablement tronquée. Utilisation de :\n" + WCMD_NYI, "Pas encore implémenté\n\n" + WCMD_NOARG, "Argument manquant\n" + WCMD_SYNTAXERR, "Erreur de syntaxe\n" + WCMD_FILENOTFOUND, "%s : Fichier non trouvé\n" + WCMD_NOCMDHELP, "Pas d'aide disponible pour %s\n" + WCMD_NOTARGET, "La destination de l'instruction GOTO n'a pas été trouvée\n" + WCMD_CURRENTDATE, "La date courante est %s\n" + WCMD_CURRENTTIME, "L'heure courante est %s\n" + WCMD_NEWDATE, "Saisissez la nouvelle date : " + WCMD_NEWTIME, "Saisissez la nouvelle heure : " + WCMD_MISSINGENV, "La variable d'environnement %s n'est pas définie\n" + WCMD_READFAIL, "Impossible d'ouvrir « %s »\n" + WCMD_CALLINSCRIPT, "Impossible d'appeler une étiquette de batch hors d'un script batch\n" + WCMD_ALL, "T" + WCMD_DELPROMPT, "%s, Supprimer" + WCMD_ECHOPROMPT, "Echo est %s\n" + WCMD_VERIFYPROMPT, "Verify est %s\n" + WCMD_VERIFYERR, "Verify doit être ON ou OFF\n"; + WCMD_ARGERR, "Erreur de paramètre\n" + WCMD_VOLUMEDETAIL, "Le volume dans le lecteur %c est %s\nLe numéro de série du volume est %04x-%04x\n\n" + WCMD_VOLUMEPROMPT, "Étiquette du volume (11 caractères, ENTRÉE pour aucun) ?" + WCMD_NOPATH, "PATH not found\n" + WCMD_ANYKEY,"Appuyez sur ENTRÉE pour continuer : " + WCMD_CONSTITLE,"Invite de commande Wine" + WCMD_VERSION,"CMD version %s\n\n" + WCMD_MOREPROMPT, "Plus ? " + WCMD_LINETOOLONG, "The input line is too long.\n" +} diff --git a/programs/cmd/Ja.rc b/programs/cmd/Ja.rc index 7f8a95c687b..20273ec9a95 100644 --- a/programs/cmd/Ja.rc +++ b/programs/cmd/Ja.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wcmd.h" - /* UTF-8 */ #pragma code_page(65001) @@ -281,3 +279,5 @@ EXIT\t\tCMDを終了\n\n\ WCMD_MOREPROMPT, "More? " WCMD_LINETOOLONG, "The input line is too long.\n" } + +#pragma code_page(default) diff --git a/programs/cmd/Ko.rc b/programs/cmd/Ko.rc index 114fb3bc5a7..e2831f51bd7 100644 --- a/programs/cmd/Ko.rc +++ b/programs/cmd/Ko.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wcmd.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/cmd/Lt.rc b/programs/cmd/Lt.rc deleted file mode 100644 index 1a335faed5b..00000000000 --- a/programs/cmd/Lt.rc +++ /dev/null @@ -1,279 +0,0 @@ -/* - * Wine command prompt - * Lithuanian Language Support - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "wcmd.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE -{ - WCMD_ATTRIB, "Informacija apie ATTRIB\n" - WCMD_CALL, -"CALL yra naudojama komandų failo viduje komandoms iš\n\ -kito komandų failo vykdyti. Kai komandų failas egzistuoja, valdymas\n\ -grąžinamas kvietusiam failui. CALL komanda gali pateikti parametrus\n\ -kviečiamai procedūrai.\n\ -\n\ -Numatytojo katalogo, aplinkos kintamųjų ir pan. pakeitimai atlikti\n\ -iškviestoje procedūroje yra paveldimi kviečiančiosios procedūros.\n" - - WCMD_CD, "Informacija apie CD\n" - WCMD_CHDIR, "Informacija apie CHDIR\n" - - WCMD_CLS, "CLS išvalo pulto ekraną\n" - - WCMD_COPY, "Informacija apie COPY\n" - WCMD_CTTY, "Informacija apie CTTY\n" - WCMD_DATE, "Informacija apie DATE\n" - WCMD_DEL, "Informacija apie DEL\n" - WCMD_DIR, "Informacija apie DIR\n" - - WCMD_ECHO, -"ECHO parodo dabartiniame terminale.\n\ -\n\ -ECHO ON priverčia visas vėlesnes komandų failo komandas būti parodytas\n\ -terminale prieš įvykdymą.\n\ -\n\ -ECHO OFF panaikina ankstesnės ECHO ON komandos veikimą (ECHO OFF yra\n\ -numatyta). ECHO OFF komandos rodymo galima išvengti prieš ją pridedant\n\ -simbolį @.\n" - - WCMD_ERASE, "Informacija apie ERASE\n" - - WCMD_FOR, -"FOR komanda yra naudojama įvykdyti komandą kiekvienam failų aibės elementui.\n\ -\n\ -Sintaksė: FOR %kintamasis IN (aibė) DO komanda\n\ -\n\ -Reikalavimas dubliuoti % simbolį naudojant FOR komandų faile neegzistuoja\n\ -wine komandų interpretatoriuje.\n" - - WCMD_GOTO, -"GOTO komanda perduoda vykdymą kitam teiginiui komandų faile.\n\ -\n\ -Žymė, kuri yra GOTO komandos tikslas gali būti 255 simbolių ilgio,\n\ -bet be tarpų (tai skiriasi nuo kitų operacinių sistemų). Jei komandų\n\ -faile egzistuoja dvi ar daugiau identiškos žymės, visuomet bus vykdoma\n\ -pirmoji. Mėginimas perduoti vykdymą į neegzistuojančią žymę nutraukia\n\ -komandų failo vykdymą.\n\ -\n\ -GOTO neturi poveikio naudojant interaktyviai.\n" - - WCMD_HELP, "Informacija apie HELP\n" - - WCMD_IF, -"IF yra naudojama vykdyti komandą su sąlyga.\n\ -\n\ -Sintaksė: IF [NOT] EXIST failas komanda\n\ - IF [NOT] eilutė1==eilutė2 komanda\n\ - IF [NOT] ERRORLEVEL skaičius komanda\n\ -\n\ -Antroje komandos formoje, eilutė1 ir eilutė2 privalo būti tarp dvigubų\n\ -kabučių. Palyginimas neskiria didžiųjų ir mažųjų raidžių.\n" - - WCMD_LABEL, "LABEL yra naudojamas disko tomo vardui nustatyti.\n\ -\n\ -Sintaksė: LABEL [diskas:]\n\ -Komanda paklaus naujo tomo vardo duotam diskui.\n\ -Parodyti disko tomo vardą galima su komanda VOL.\n" - - WCMD_MD, "Informacija apie MD\n" - WCMD_MKDIR, "Informacija apie MKDIR\n" - WCMD_MOVE, -"MOVE perkelia failą ar katalogą į naują failų sistemos vietą.\n\ -\n\ -Jei perkeliamas objektas yra katalogas, tai taip pat perkeliami visi\n\ -katalogo failai ir pakatalogiai.\n\ -\n\ -MOVE nepavyksta jei sena ir nauja vietos yra su skirtingomis DOS raidėmis.\n" - - WCMD_PATH, -"PATH parodo ar pakeičia paieškos kelią.\n\ -\n\ -Įvedus PATH bus parodyta dabartinė PATH reikšmė (iš pradžių tai reikšmė\n\ -nurodyta jūsų wine.conf faile). Norėdami pakeisti nuostatą nurodykite PATH\n\ -komandai naują reikšmę kaip parametrą.\n\ -\n\ -PATH modifikuoti taip pat galima naudojant PATH aplinkos kintamąjį,\n\ -pavyzdžiui:\n\ - PATH %PATH%;c:\\laikinas\n" - - WCMD_PAUSE, -"PAUSE ekrane parodo pranešimą „Norėdami tęsti spauskite įvedimo klavišą“\n\ -ir laukia kol naudotojas paspaus įvedimo klavišą. Ši komanda naudingiausia\n\ -komandų failuose, kad leistų naudotojui perskaityti ankstesnės komandos\n\ -rezultatą kol jis nepasislinko už ekrano ribų.\n" - - WCMD_PROMPT, -"PROMPT nustato komandinės eilutės raginimą.\n\ -\n\ -Simbolių eilutė, einanti po PROMPT komandos (ir tarpas iškart po to),\n\ -atsiranda eilutės pradžioje, kai CMD laukia įvedimo.\n\ -\n\ -Šie simboliai turi nurodytą specialią reikšmę:\n\ -\n\ -$$ Dolerio ženklas $_ Eilutės patraukimas $b Status brūkšnys (|)\n\ -$d Dabartinė data $e Grįžimo klavišas $g > ženklas\n\ -$l < ženklas $n Dabartinis diskas $p Dabartinis kelias\n\ -$q Lygybės ženklas $t Dabartinis laikas $v CMD versija\n\ -\n\ -Pastebėkite, kad PROMPT komandos be raginimo eilutės įvedimas atkuria\n\ -numatytą raginimo reikšmę, kuri yra dabartinis kelias (įskaitant\n\ -dabartinio disko raidę) ir daugiau-už (>) simbolis.\n\ -(Taip pat, kaip komanda PROMPT $p$g).\n\ -\n\ -Raginimas taip pat gali būti pakeistas keičiant PROMPT aplinkos kintamąjį,\n\ -taigi, komanda „SET PROMPT=tekstas“ turi tą patį efektą kaip „PROMPT tekstas“\n" - - WCMD_REM, -"Komandos eilutė prasidedanti REM (ir tarpu) neatlieka jokio veiksmo\n\ -ir todėl gali būti naudojama kaip komentaras komandų faile.\n" - - WCMD_REN, "Informacija apie REN\n" - WCMD_RENAME, "Informacija apie RENAME\n" - WCMD_RD, "Informacija apie RD\n" - WCMD_RMDIR, "Informacija apie RMDIR\n" - - WCMD_SET, -"SET parodo ar pakeičia CMD aplinkos kintamuosius.\n\ -\n\ -SET be parametrų parodo visus dabartinius aplinkos kintamuosius.\n\ -\n\ -Aplinkos kintamojo sukūrimo ar modifikavimo sintaksė yra:\n\ -\n\ - SET =\n\ -\n\ -kur ir yra simbolių eilutės. Prieš lygybės ženklą\n\ -neturi būti tarpų, taip pat kintamojo vardas negali turėti įterptų tarpų.\n\ -\n\ -Naudojant Wine, pagrindinės operacinės sistemos aplinka yra įtraukiama į\n\ -Win32 aplinką, todėl paprastai bus žymiai daugiau reikšmių negu savoje\n\ -Win32 realizacijoje. Pastebėkite, kad neįmanoma įtakoti operacinės sistemos\n\ -aplinkos iš komandų interpretatoriaus.\n" - - WCMD_SHIFT, -"SHIFT yra naudojamas komandų faile pašalinti vienam parametrui iš sąrašo\n\ -priekio, taip parametras 2 tampa parametru 1 ir t.t. Ši komanda neturi\n\ -jokio poveikio, kai kviečiama iš komandos eilutės.\n" - - WCMD_TIME, "Informacija apie TIME\n" - - WCMD_TITLE, "Nustato CMD lango antraštę, sintaksė TITLE [tekstas]\n" - - WCMD_TYPE, -"TYPE nukopijuoja į pulto įrenginį (arba kitur, jei\n\ -nukreipta). Nėra tikrinama ar faile yra skaitomas tekstas.\n" - - WCMD_VERIFY, -"VERIFY yra naudojama nustatyti, išvalyti ar testuoti tikrinimo žymos bitą.\n\ -Galimos formos yra:\n\ -\n\ -VERIFY ON Nustatyti žymos bitą\n\ -VERIFY OFF Išvalyti žymos bitą\n\ -VERIFY Parodo ON arba OFF, kuris tinkamas.\n\ -\n\ -Tikrinimo žymos bitas neturi jokios funkcijos Wine.\n" - - WCMD_VER, -"VER parodo dabar vykdomo CMD versiją\n" - - WCMD_VOL, "Informacija apie VOL\n" - - WCMD_PUSHD, "PUSHD išsaugo dabartinį katalogą į dėklą,\n\ -o po to pakeičia dabartinį katalogą į nurodytą.\n" - - WCMD_POPD, "POPD pakeičia dabartinį katalogą į paskutinį išsaugotą su PUSHD.\n" - - WCMD_MORE, "MORE parodo failo išvedimą ar kanalo įvedimą puslapiais.\n" - - WCMD_EXIT, -"EXIT baigia dabartinį komandų seansą ir grįžta į operacinę sistemą\n\ -ar apvalkalą iš kur CMD buvo iškviestas.\n" - - WCMD_ALLHELP, "CMD įtaisytos komandos yra:\n\ -ATTRIB\t\tRodyti ar keisti DOS failo požymius\n\ -CALL\t\tKviesti komandų failą iš kito komandų failo\n\ -CD (CHDIR)\tPakeisti dabartinį numatytą katalogą\n\ -CLS\t\tIšvalyti pulto ekraną\n\ -COPY\t\tKopijuoti failą\n\ -CTTY\t\tPakeisti įvedimo/išvedimo įrenginį\n\ -DATE\t\tRodyti ar keisti sistemos datą\n\ -DEL (ERASE)\tŠalinti failą ar failų aibę\n\ -DIR\t\tPateikti katalogo turinį\n\ -ECHO\t\tKopijuoti tekstą tiesiai į pulto išvedimą\n\ -HELP\t\tParodyti trumpą pagalbą apie temą\n\ -MD (MKDIR)\tSukurti pakatalogį\n\ -MORE\t\tRodyti išvedimą puslapiais\n\ -MOVE\t\tPerkelti failą, failų aibę ar katalogų medį\n\ -PATH\t\tNustatyti ar parodyti paieškos kelią\n\ -POPD\t\tAtstato katalogą į paskutinį išsaugotą su PUSHD\n\ -PROMPT\t\tKeičia komandos raginimą\n\ -PUSHD\t\tPakeičia į naują katalogą, išsaugo dabartinį\n\ -REN (RENAME)\tPervadinti failą\n\ -RD (RMDIR)\tŠalinti pakatalogį\n\ -SET\t\tNustatyti ar parodyti aplinkos kintamuosius\n\ -TIME\t\tNustatyti ar parodyti dabartinį sistemos laiką\n\ -TITLE\t\tNustatyti CMD seanso lango antraštę\n\ -TYPE\t\tIšvesti tekstinio failo turinį\n\ -VER\t\tParodyti dabartinę CMD versiją\n\ -VOL\t\tParodyti tomo vardą\n\ -EXIT\t\tUžveria CMD\n\n\ -Įveskite HELP platesnei informacijai apie išvardintas komandas gauti\n" - - WCMD_CONFIRM, "Ar tikrai" - WCMD_YES, "T" - WCMD_NO, "N" - WCMD_NOASSOC, "Trūksta failo susiejimo prievardžiui %s\n" - WCMD_NOFTYPE, "Jokia atvėrimo komanda nesusieta su failo tipu „%s“\n" - WCMD_OVERWRITE, "Perrašyti %s" - WCMD_MORESTR, "Daugiau..." - WCMD_TRUNCATEDLINE, "Paketinio apdorojimo eilutė galimai nukirsta. Naudojama:\n" - WCMD_NYI, "Dar nerealizuota\n\n" - WCMD_NOARG, "Trūksta argumento\n" - WCMD_SYNTAXERR, "Sintaksės klaida\n" - WCMD_FILENOTFOUND, "%s: failas nerastas\n" - WCMD_NOCMDHELP, "Nėra informacijos apie %s\n" - WCMD_NOTARGET, "GOTO tikslas nerastas\n" - WCMD_CURRENTDATE, "Dabartinė data yra %s\n" - WCMD_CURRENTTIME, "Dabartinis laikas yra %s\n" - WCMD_NEWDATE, "Įveskite naują datą: " - WCMD_NEWTIME, "Įveskite naują laiką: " - WCMD_MISSINGENV, "Aplinkos kintamasis %s neapibrėžtas\n" - WCMD_READFAIL, "Nepavyko atverti „%s“\n" - WCMD_CALLINSCRIPT, "Negalima iškviesti žymės esančios už komandos failo ribų\n" - WCMD_ALL, "V" - WCMD_DELPROMPT, "%s, trinti" - WCMD_ECHOPROMPT, "ECHO yra %s\n" - WCMD_VERIFYPROMPT, "VERIFY yra %s\n" - WCMD_VERIFYERR, "VERIFY turi būti ON arba OFF\n"; - WCMD_ARGERR, "Parametro klaida\n" - WCMD_VOLUMEDETAIL, "Tomas diske %c yra %s\nTomo serijos numeris yra %04x-%04x\n\n" - WCMD_VOLUMEPROMPT, "Tomo vardas (11 simbolių, ENTER - bevardis)?" - WCMD_NOPATH, "KELIAS nerastas\n" - WCMD_ANYKEY, "Norėdami tęsti spauskite įvedimo klavišą: " - WCMD_CONSTITLE, "Wine komandų interpretatorius" - WCMD_VERSION, "CMD versija %s\n\n" - WCMD_MOREPROMPT, "Daugiau? " - WCMD_LINETOOLONG, "Įvedimo eilutė per ilga.\n" -} diff --git a/programs/cmd/Makefile.in b/programs/cmd/Makefile.in index f2a0d8faa3c..7767dcd1dc7 100644 --- a/programs/cmd/Makefile.in +++ b/programs/cmd/Makefile.in @@ -13,24 +13,7 @@ C_SRCS = \ directory.c \ wcmdmain.c -RC_SRCS = \ - Cs.rc \ - Da.rc \ - De.rc \ - En.rc \ - Es.rc \ - Fr.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Si.rc \ - Tr.rc \ - wcmdrc.rc +RC_SRCS = wcmdrc.rc SVG_SRCS = wcmd.svg diff --git a/programs/cmd/Nl.rc b/programs/cmd/Nl.rc index 2e8bf1cce3c..6863b00969b 100644 --- a/programs/cmd/Nl.rc +++ b/programs/cmd/Nl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wcmd.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE diff --git a/programs/cmd/No.rc b/programs/cmd/No.rc index 89f020a276a..71a694b9af5 100644 --- a/programs/cmd/No.rc +++ b/programs/cmd/No.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wcmd.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE diff --git a/programs/cmd/Pl.rc b/programs/cmd/Pl.rc index 5696dc06ab7..74e852ea70d 100644 --- a/programs/cmd/Pl.rc +++ b/programs/cmd/Pl.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wcmd.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/cmd/Pt.rc b/programs/cmd/Pt.rc index be6ce52e93c..65e0a6b8833 100644 --- a/programs/cmd/Pt.rc +++ b/programs/cmd/Pt.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wcmd.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE diff --git a/programs/cmd/README b/programs/cmd/README new file mode 100644 index 00000000000..d7d80c2dd88 --- /dev/null +++ b/programs/cmd/README @@ -0,0 +1,39 @@ +CMD - A Command-Line Interface for WINE +Copyright (C) 1999 D Pickles (davep@nugate.demon.co.uk) +Open Source software published under the Wine Licence and Warranty. + +This is an Alpha version and is very much "work in progress". + +WHAT'S INCLUDED +- Sources +- A Makefile for compiling with LibWine. Build Wine with "-enable-dll" first. +- A Makefile for Borland C++ (needs editing for directories). + +WHAT'S MISSING +- Command-line qualifiers for most builtin commands +- Set functionality in DATE, TIME, ATTRIB, LABEL +- Full internationalisation of the text (and commands?). + +WHAT DOESN'T WORK +- The ATTRIB command reports all files having their Archive flag set, and the +READONLY setting depends on the Unix file permissions. All other flags are +always clear. The Wine attributes API calls map to the Unix stat() function +which cannot handle the other attributes available in DOS. +- Date/timestamps of files in the DIR listing are shown using the current +locale, which is set using the Unix LANG environment variable. By default the +US date-time format is used. Set eg "LANG=en_GB" for DD/MM/YY dates and 24-hour +times. +- Line editing and command recall doesn't work due to missing functionality in +Wine. +- Redirection is implemented as a command line is parsed. This means that ">" +and "<" symbols cannot appear in command arguments even within quotes. +- In many cases parsing and syntax checking is less rigorous than DOS. Thus an +existing DOS batch file will probably run unchanged under wine's cmd but the +reverse may not be the case. + +WINE OR WIN32 BINARY? +cmd can be built as a Wine binary, or (using a Win32 compiler) as a Win32 .EXE +image. The Wine binary is simpler to invoke from the U**x command line or from +a GUI such as KDE, however it is not possible to invoke a second shell using the +"CMD /C filename" syntax. Conversely a Win32 application can be invoked from a +Win32 GUI such as Program Manager but that needs starting under Wine first. diff --git a/programs/cmd/Ru.rc b/programs/cmd/Ru.rc dissimilarity index 91% index 9e9853746a4..5bd2a05098a 100644 --- a/programs/cmd/Ru.rc +++ b/programs/cmd/Ru.rc @@ -1,287 +1,282 @@ -/* - * Wine command prompt (Russian resources) - * - * Copyright 2003 Igor Stepin - * Copyright 2007 Lyutin Anatoly - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "wcmd.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT - -STRINGTABLE -{ - WCMD_ATTRIB, "Справка об ATTRIB\n" - WCMD_CALL, -"CALL <имя bat-файла> используется в bat-файлах для запуска других\n\ -bat-файлов. При выходе из bat-файла управление возвращается\n\ -файлу, вызвавшему его. Команда CALL может передавать параметры\n\ -вызванному bat-файлу.\n\ -\n\ -Изменения каталога по умолчанию, переменных окружения и т.д., сделанные\n\ -вызванной процедурой, наследуются вызвавшему.\n" - - WCMD_CD, "Справка о CD\n" - WCMD_CHDIR, "Справка о CHDIR\n" - - WCMD_CLS, "CLS очищает экран консоли\n" - - WCMD_COPY, "Справка о COPY\n" - WCMD_CTTY, "Справка о CTTY\n" - WCMD_DATE, "Справка о DATE\n" - WCMD_DEL, "Справка о DEL\n" - WCMD_DIR, "Справка о DIR\n" - - WCMD_ECHO, -"ECHO <строка> отображает <строку> на текущем терминальном устройстве.\n\ -\n\ -ECHO ON включает отображение всех последующих команд в bat-файле\n\ -в терминал перед их выполнением.\n\ -\n\ -ECHO OFF даёт эффект, противоположный ECHO ON (ECHO отключено (OFF) по\n\ -умолчанию). Знак @, предшествующий ECHO OFF, препятствует её отображению.\n" - - WCMD_ERASE, "Справка об ERASE\n" - - WCMD_FOR, -"FOR используется для применения заданной <команды> для\n\ -одного файла или набора файлов.\n\ -\n\ -Синтаксис: FOR %переменная IN (набор) DO команда\n\ -\n\ -Необходимость в удвоении знака % при использовании FOR в bat-файлах\n\ -отсутствует в cmd.\n" - - - WCMD_GOTO, -"GOTO передаёт управление на строку, помеченную специальной меткой, в\n\ -пределах bat-файла.\n\ -\n\ -Метка, являющаяся целью GOTO, может иметь длину до 255 символов, но\n\ -не может содержать пробелы (это отличие от других операционных\n\ -систем). Если в bat-файле присутствует две или более метки с одинаковым именем,\n\ -то передаваться управление будет всегда на первую.\n\ -Попытка GOTO перейти по несуществующей метке прерывает выполнение bat-файла.\n\ -\n\ -Команда GOTO не работает в интерактивном режиме.\n" - - WCMD_HELP, "Справка о HELP\n" - - WCMD_IF, -"IF осуществляет условную обработку.\n\ -\n\ -Синтаксис: IF [NOT] EXIST файл команда\n\ - IF [NOT] \"строка1\"==\"строка2\" команда\n\ - IF [NOT] ERRORLEVEL число команда\n\ -\n\ -В первом примере команда EXIST проверяет существование файла.\n\ -Во втором примере сравнение не зависит от регистра.\n\ -В третьем примере ERRORLEVEL - значение, возвращаемое программой после выполнения.\n\ -IF проверяет ERRORLEVEL на >= <число>.\n" - - WCMD_LABEL, -"LABEL задаёт метку диска.\n\ -\n\ -Синтаксис: LABEL [диск:]\n\ -Команда выводит подсказку о создании новой метки для диска.\n\ -Посмотреть текущую метку диска возможно с помощью команды VOL.\n" - - - WCMD_MD, "Справка о MD\n" - WCMD_MKDIR, "Справка о MKDIR\n" - WCMD_MOVE, -"MOVE перемещает файл или каталог на новое место файловой системы.\n\ -\n\ -Если перемещается каталог, то все файлы и подкаталоги внутри него\n\ -также переместятся.\n\ -\n\ -MOVE не работает для перемещения данных с одного логического диска на другой.\n" - - WCMD_PATH, -"PATH отображает или изменяет маршрут поиска в cmd.\n\ -\n\ -Команда PATH отображает текущую установку пути поиска исполняемых файлов\n\ -(первоначально это значение задаётся в Вашем wine.conf файле).\n\ -Для изменения значения вызовите PATH с новым значением.\n\ -\n\ -Так же возможно изменять значение PATH, используя значение переменной\n\ -окружения PATH, например:\n\ - PATH %PATH%;c:\\temp\n" - - WCMD_PAUSE, -"PAUSE выводит на экран сообщение 'Press Return key to continue'\n\ -и ждёт пока пользователь не нажмёт клавишу Return. Она используется\n\ -в bat-файлах для того, чтобы пользователь смог прочесть вывод предыдущей команды\n\ -прежде чем он исчезнет с экрана.\n" - - WCMD_PROMPT, -"PROMPT изменяет вид подсказки командной строки.\n\ -\n\ -Строка, идущая после команды PROMPT (и за пробелом после команды),\n\ -появляется в начале строки, когда cmd ждёт ввода.\n\ -\n\ -Следующие строки имеют предопределённые значения, которые можно отобразить:\n\ -\n\ -$$ Знак доллара $_ Linefeed $b Знак Pipe (|)\n\ -$d Текущая дата $e Esc-символ (27) $g Знак >\n\ -$l Знак < $n Текущий диск $p Текущий путь\n\ -$q Знак равно $t Текущее время $v Версия cmd\n\ -\n\ -При вводе команды PROMPT без новой строки подсказки\n\ -подсказка устанавливается по умолчанию (буква текущего диска, путь до текущего\n\ -каталога и знак больше (>).\n\ -(как при вызове PROMPT $p$g).\n\ -\n\ -Подсказка может быть также изменена сменой переменной окружения PROMPT,\n\ -поэтому команда 'SET PROMPT=<текст>' имеет такой же эффект, как 'PROMPT '\n" - - WCMD_REM, -"Командная строка, начинающаяся с REM (с последующим пробелом) не выполняет\n\ -никаких действий, поэтому REM используется для комментариев в bat-файлах.\n" - - WCMD_REN, "Справка о REN\n" - WCMD_RENAME, "Справка о RENAME\n" - WCMD_RD, "Справка о RD\n" - WCMD_RMDIR, "Справка о RMDIR\n" - - WCMD_SET, -"SET показывает или изменяет переменные окружения cmd.\n\ -\n\ -SET без параметров показывает всё текущее окружение.\n\ -\n\ -Для создания или изменения переменной окружения используйте:\n\ -\n\ - SET <переменная>=<значение>\n\ -\n\ -где <переменная> и <значение> являются символьными строками. Перед знаком\n\ -равно не должно быть пробелов, имя переменной не может содержать\n\ -пробелы.\n\ -\n\ -В Wine переменные окружения основной операционной системы включены\n\ -в окружение Win32, поэтому будет доступно несколько больше\n\ -переменных, чем в обычной Win32. Стоит отметить,\n\ -что невозможно изменить окружение операционной системы из cmd.\n" - - WCMD_SHIFT, -"SHIFT используется в bat-файлах для удаления одного параметра с вершины\n\ -списка, таким образом параметр 2 переместится в параметр 1 и так далее.\n\ -SHIFT не работает при вызове в командной строке.\n" - - WCMD_TIME, "Справка о TIME\n" - - WCMD_TITLE, "Устанавливает заголовок окна cmd для текущей сессии.\n Синтаксис: TITLE <строка>\n" - - WCMD_TYPE, -"TYPE <файл> копирует <файл> в устройство консоли (или куда угодно, если он перенаправлен).\n\ -Проверка на то, что файл - это текст, предназначенный для чтения, отсутствует.\n" - - WCMD_VERIFY, -"VERIFY предназначена для установки, сброса или определения флага проверки\n\ -корректности записи файлов на диск. Возможные значения:\n\ -\n\ -VERIFY ON Установить флаг\n\ -VERIFY OFF Сбросить флаг\n\ -VERIFY Выводит текущее состояние: ON или OFF.\n\ -\n\ -Флаг verify не используется Wine.\n" - - WCMD_VER, -"VER отображает версию запущенного cmd\n" - - WCMD_VOL, "Справка о VOL\n" - - WCMD_PUSHD, "PUSHD сохраняет текущий каталог в стек,\n\ -а затем переходит в указанный каталог.\n" - - WCMD_POPD, "POPD переходит в каталог, сохранённый командой\n\ -PUSHD.\n" - - WCMD_MORE, "MORE выводит содержимое файлов или каналов постранично.\n" - - WCMD_EXIT, -"EXIT завершает текущую командную сессию и возвращает\n\ -в операционную систему или оболочку из которой был запущен cmd.\n" - - WCMD_ALLHELP, "Встроенные команды CMD:\n\ -ATTRIB\t\tПоказать или изменить DOS-атрибуты файла\n\ -CALL\t\tЗапустить bat-файл из другого bat-файла\n\ -CD (CHDIR)\tСменить текущую папку\n\ -CLS\t\tОчистить экран консоли\n\ -COPY\t\tСкопировать файл\n\ -CTTY\t\tСменить устройство ввода/вывода\n\ -DATE\t\tПоказать или изменить системную дату\n\ -DEL (ERASE)\tУдалить файл или набор файлов\n\ -DIR\t\tПоказать содержание папки\n\ -ECHO\t\tСкопировать текст прямо на выход консоли\n\ -HELP\t\tПоказать краткую подсказку по команде\n\ -MD (MKDIR)\tСоздать папку\n\ -MORE\t\tВывести данные по страницам\n\ -MOVE\t\tПереместить файл, набор файлов или дерево папок\n\ -PATH\t\tПоказать или изменить путь поиска программ\n\ -POPD\t\tВосстановить предыдущее значение текущей папки, сохранённого с помощью PUSHD\n\ -PUSHD\t\tСохранить значение текущей папки и переходит к другой папке\n\ -PROMPT\t\tИзменить приглашение командной строки\n\ -REN (RENAME)\tПереименовать файл\n\ -RD (RMDIR)\tУдалить папку\n\ -SET\t\tПоказать или изменить переменные окружения\n\ -TIME\t\tПоказать или изменить текущее системное время\n\ -TITLE\t\tУстанавить заголовок окна cmd для текущей сессии\n\ -TYPE\t\tВывести содержание текстового файла\n\ -VER\t\tПоказать текущую версию CMD\n\ -VOL\t\tПоказать метку тома дискового устройства\n\ -EXIT\t\tВыйти из CMD\n\n\ -Выполните HELP <команда> для дополнительной информации по перечисленным выше командам.\n" - - WCMD_CONFIRM, "Вы уверены?" - WCMD_YES, "Д" - WCMD_NO, "Н" - WCMD_NOASSOC, "Файл, ассоциированный с расширением %s,отсутствует\n" - WCMD_NOFTYPE, "Не работает команда, ассоциированная с файлом '%s'\n" - WCMD_OVERWRITE, "Перезаписано %s" - WCMD_MORESTR, "Дальше..." - WCMD_TRUNCATEDLINE, "Строка в обрабатываемом bat-файле возможно урезана. Используем:\n" - WCMD_NYI, "Ещё не выполнено\n\n" - WCMD_NOARG, "Отсутствует аргумент\n" - WCMD_SYNTAXERR, "Синтаксическая ошибка\n" - WCMD_FILENOTFOUND, "%s : Файл не найден\n" - WCMD_NOCMDHELP, "Справка для %s отсутствует\n" - WCMD_NOTARGET, "Цель для GOTO не найдена\n" - WCMD_CURRENTDATE, "Текущая дата %s\n" - WCMD_CURRENTTIME, "Текущее время %s\n" - WCMD_NEWDATE, "Введите новую дату: " - WCMD_NEWTIME, "Введите новое время: " - WCMD_MISSINGENV, "Переменная окружения %s не определена\n" - WCMD_READFAIL, "Ошибка при открытии '%s'\n" - WCMD_CALLINSCRIPT, "Не могу вызвать метку bat-файла вне bat-скрипта\n" - WCMD_ALL, "В" - WCMD_DELPROMPT, "%s, Удалено" - WCMD_ECHOPROMPT, "Echo установлено в %s\n" - WCMD_VERIFYPROMPT, "Verify установлено в %s\n" - WCMD_VERIFYERR, "Verify должен быть либо ON, либо OFF\n"; - WCMD_ARGERR, "Неверный параметр\n" - WCMD_VOLUMEDETAIL, "Объём диска %c %s\n Серийный номер %04x-%04x\n\n" - WCMD_VOLUMEPROMPT, "Метка диска (11 символов, ENTER для ввода пустой метки)?" - WCMD_NOPATH, "PATH не найден\n" - WCMD_ANYKEY,"Нажмите ввод для продолжения: " - WCMD_CONSTITLE,"Приглашение командной строки Wine" - WCMD_VERSION,"Версия CMD %s\n\n" - WCMD_MOREPROMPT, "Ещё? " - WCMD_LINETOOLONG, "Введенная команда слишком длинная.\n" -} +/* + * Wine command prompt (Russian resources) + * + * Copyright 2003 Igor Stepin + * Copyright 2007 Lyutin Anatoly + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT + +STRINGTABLE +{ + WCMD_ATTRIB, "Ñïðàâêà îá ATTRIB\n" + WCMD_CALL, +"CALL <èìÿ bat-ôàéëà> èñïîëüçóåòñÿ â bat-ôàéëàõ äëÿ çàïóñêà äðóãèõ\n\ +bat-ôàéëîâ. Ïðè âûõîäå èç bat-ôàéëà óïðàâëåíèå âîçâðàùàåòñÿ\n\ +ôàéëó, âûçâàâøåìó åãî. Êîìàíäà CALL ìîæåò ïåðåäàâàòü ïàðàìåòðû\n\ +âûçâàííîìó bat-ôàéëó.\n\ +\n\ +Èçìåíåíèÿ êàòàëîãà ïî óìîë÷àíèþ, ïåðåìåííûõ îêðóæåíèÿ è ò.ä., ñäåëàííûå\n\ +âûçâàííîé ïðîöåäóðîé, íàñëåäóþòñÿ âûçâàâøåìó.\n" + + WCMD_CD, "Ñïðàâêà î CD\n" + WCMD_CHDIR, "Ñïðàâêà î CHDIR\n" + + WCMD_CLS, "CLS î÷èùàåò ýêðàí êîíñîëè\n" + + WCMD_COPY, "Ñïðàâêà î COPY\n" + WCMD_CTTY, "Ñïðàâêà î CTTY\n" + WCMD_DATE, "Ñïðàâêà î DATE\n" + WCMD_DEL, "Ñïðàâêà î DEL\n" + WCMD_DIR, "Ñïðàâêà î DIR\n" + + WCMD_ECHO, +"ECHO <ñòðîêà> îòîáðàæàåò <ñòðîêó> íà òåêóùåì òåðìèíàëüíîì óñòðîéñòâå.\n\ +\n\ +ECHO ON âêëþ÷àåò îòîáðàæåíèå âñåõ ïîñëåäóþùèõ êîìàíä â bat-ôàéëå\n\ +â òåðìèíàë ïåðåä èõ âûïîëíåíèåì.\n\ +\n\ +ECHO OFF äà¸ò ýôôåêò, ïðîòèâîïîëîæíûé ECHO ON (ECHO îòêëþ÷åíî (OFF) ïî\n\ +óìîë÷àíèþ). Çíàê @, ïðåäøåñòâóþùèé ECHO OFF, ïðåïÿòñòâóåò å¸ îòîáðàæåíèþ.\n" + + WCMD_ERASE, "Ñïðàâêà îá ERASE\n" + + WCMD_FOR, +"FOR èñïîëüçóåòñÿ äëÿ ïðèìåíåíèÿ çàäàííîé <êîìàíäû> äëÿ\n\ +îäíîãî ôàéëà èëè íàáîðà ôàéëîâ.\n\ +\n\ +Ñèíòàêñèñ: FOR %ïåðåìåííàÿ IN (íàáîð) DO êîìàíäà\n\ +\n\ +Íåîáõîäèìîñòü â óäâîåíèè çíàêà % ïðè èñïîëüçîâàíèè FOR â bat-ôàéëàõ\n\ +îòñóòñòâóåò â cmd.\n" + + + WCMD_GOTO, +"GOTO ïåðåäà¸ò óïðàâëåíèå íà ñòðîêó, ïîìå÷åííóþ ñïåöèàëüíîé ìåòêîé, â\n\ +ïðåäåëàõ bat-ôàéëà.\n\ +\n\ +Ìåòêà, ÿâëÿþùàÿñÿ öåëüþ GOTO, ìîæåò èìåòü äëèíó äî 255 ñèìâîëîâ, íî\n\ +íå ìîæåò ñîäåðæàòü ïðîáåëû (ýòî îòëè÷èå îò äðóãèõ îïåðàöèîííûõ\n\ +ñèñòåì). Åñëè â bat-ôàéëå ïðèñóòñòâóåò äâå èëè áîëåå ìåòêè ñ îäèíàêîâûì èìåíåì,\n\ +òî ïåðåäàâàòüñÿ óïðàâëåíèå áóäåò âñåãäà íà ïåðâóþ.\n\ +Ïîïûòêà GOTO ïåðåéòè ïî íåñóùåñòâóþùåé ìåòêå ïðåðûâàåò âûïîëíåíèå bat-ôàéëà.\n\ +\n\ +Êîìàíäà GOTO íå ðàáîòàåò â èíòåðàêòèâíîì ðåæèìå.\n" + + WCMD_HELP, "Ñïðàâêà î HELP\n" + + WCMD_IF, +"IF îñóùåñòâëÿåò óñëîâíóþ îáðàáîòêó.\n\ +\n\ +Ñèíòàêñèñ: IF [NOT] EXIST ôàéë êîìàíäà\n\ + IF [NOT] \"ñòðîêà1\"==\"ñòðîêà2\" êîìàíäà\n\ + IF [NOT] ERRORLEVEL ÷èñëî êîìàíäà\n\ +\n\ + ïåðâîì ïðèìåðå êîìàíäà EXIST ïðîâåðÿåò ñóùåñòâîâàíèå ôàéëà.\n\ +Âî âòîðîì ïðèìåðå ñðàâíåíèå íå çàâèñèò îò ðåãèñòðà.\n\ + òðåòüåì ïðèìåðå ERRORLEVEL - çíà÷åíèå, âîçâðàùàåìîå ïðîãðàììîé ïîñëå âûïîëíåíèÿ.\n\ +IF ïðîâåðÿåò ERRORLEVEL íà >= <÷èñëî>.\n" + + WCMD_LABEL, +"LABEL çàäà¸ò ìåòêó äèñêà.\n\ +\n\ +Ñèíòàêñèñ: LABEL [äèñê:]\n\ +Êîìàíäà âûâîäèò ïîäñêàçêó î ñîçäàíèè íîâîé ìåòêè äëÿ äèñêà.\n\ +Ïîñìîòðåòü òåêóùóþ ìåòêó äèñêà âîçìîæíî ñ ïîìîùüþ êîìàíäû VOL.\n" + + + WCMD_MD, "Ñïðàâêà î MD\n" + WCMD_MKDIR, "Ñïðàâêà î MKDIR\n" + WCMD_MOVE, +"MOVE ïåðåìåùàåò ôàéë èëè êàòàëîã íà íîâîå ìåñòî ôàéëîâîé ñèñòåìû.\n\ +\n\ +Åñëè ïåðåìåùàåòñÿ êàòàëîã, òî âñå ôàéëû è ïîäêàòàëîãè âíóòðè íåãî\n\ +òàêæå ïåðåìåñòÿòñÿ.\n\ +\n\ +MOVE íå ðàáîòàåò äëÿ ïåðåìåùåíèÿ äàííûõ ñ îäíîãî ëîãè÷åñêîãî äèñêà íà äðóãîé.\n" + + WCMD_PATH, +"PATH îòîáðàæàåò èëè èçìåíÿåò ìàðøðóò ïîèñêà â cmd.\n\ +\n\ +Êîìàíäà PATH îòîáðàæàåò òåêóùóþ óñòàíîâêó ïóòè ïîèñêà èñïîëíÿåìûõ ôàéëîâ\n\ +(ïåðâîíà÷àëüíî ýòî çíà÷åíèå çàäà¸òñÿ â Âàøåì wine.conf ôàéëå).\n\ +Äëÿ èçìåíåíèÿ çíà÷åíèÿ âûçîâèòå PATH ñ íîâûì çíà÷åíèåì.\n\ +\n\ +Òàê æå âîçìîæíî èçìåíÿòü çíà÷åíèå PATH, èñïîëüçóÿ çíà÷åíèå ïåðåìåííîé\n\ +îêðóæåíèÿ PATH, íàïðèìåð:\n\ + PATH %PATH%;c:\\temp\n" + + WCMD_PAUSE, +"PAUSE âûâîäèò íà ýêðàí ñîîáùåíèå 'Press Return key to continue'\n\ +è æä¸ò ïîêà ïîëüçîâàòåëü íå íàæì¸ò êëàâèøó Return. Îíà èñïîëüçóåòñÿ\n\ +â bat-ôàéëàõ äëÿ òîãî, ÷òîáû ïîëüçîâàòåëü ñìîã ïðî÷åñòü âûâîä ïðåäûäóùåé êîìàíäû\n\ +ïðåæäå ÷åì îí èñ÷åçíåò ñ ýêðàíà.\n" + + WCMD_PROMPT, +"PROMPT èçìåíÿåò âèä ïîäñêàçêè êîìàíäíîé ñòðîêè.\n\ +\n\ +Ñòðîêà, èäóùàÿ ïîñëå êîìàíäû PROMPT (è çà ïðîáåëîì ïîñëå êîìàíäû),\n\ +ïîÿâëÿåòñÿ â íà÷àëå ñòðîêè, êîãäà cmd æä¸ò ââîäà.\n\ +\n\ +Ñëåäóþùèå ñòðîêè èìåþò ïðåäîïðåäåë¸ííûå çíà÷åíèÿ, êîòîðûå ìîæíî îòîáðàçèòü:\n\ +\n\ +$$ Çíàê äîëëàðà $_ Linefeed $b Çíàê Pipe (|)\n\ +$d Òåêóùàÿ äàòà $e Esc-ñèìâîë (27) $g Çíàê >\n\ +$l Çíàê < $n Òåêóùèé äèñê $p Òåêóùèé ïóòü\n\ +$q Çíàê ðàâíî $t Òåêóùåå âðåìÿ $v Âåðñèÿ cmd\n\ +\n\ +Ïðè ââîäå êîìàíäû PROMPT áåç íîâîé ñòðîêè ïîäñêàçêè\n\ +ïîäñêàçêà óñòàíàâëèâàåòñÿ ïî óìîë÷àíèþ (áóêâà òåêóùåãî äèñêà, ïóòü äî òåêóùåãî\n\ +êàòàëîãà è çíàê áîëüøå (>).\n\ +(êàê ïðè âûçîâå PROMPT $p$g).\n\ +\n\ +Ïîäñêàçêà ìîæåò áûòü òàêæå èçìåíåíà ñìåíîé ïåðåìåííîé îêðóæåíèÿ PROMPT,\n\ +ïîýòîìó êîìàíäà 'SET PROMPT=<òåêñò>' èìååò òàêîé æå ýôôåêò, êàê 'PROMPT '\n" + + WCMD_REM, +"Êîìàíäíàÿ ñòðîêà, íà÷èíàþùàÿñÿ ñ REM (ñ ïîñëåäóþùèì ïðîáåëîì) íå âûïîëíÿåò\n\ +íèêàêèõ äåéñòâèé, ïîýòîìó REM èñïîëüçóåòñÿ äëÿ êîììåíòàðèåâ â bat-ôàéëàõ.\n" + + WCMD_REN, "Ñïðàâêà î REN\n" + WCMD_RENAME, "Ñïðàâêà î RENAME\n" + WCMD_RD, "Ñïðàâêà î RD\n" + WCMD_RMDIR, "Ñïðàâêà î RMDIR\n" + + WCMD_SET, +"SET ïîêàçûâàåò èëè èçìåíÿåò ïåðåìåííûå îêðóæåíèÿ cmd.\n\ +\n\ +SET áåç ïàðàìåòðîâ ïîêàçûâàåò âñ¸ òåêóùåå îêðóæåíèå.\n\ +\n\ +Äëÿ ñîçäàíèÿ èëè èçìåíåíèÿ ïåðåìåííîé îêðóæåíèÿ èñïîëüçóéòå:\n\ +\n\ + SET <ïåðåìåííàÿ>=<çíà÷åíèå>\n\ +\n\ +ãäå <ïåðåìåííàÿ> è <çíà÷åíèå> ÿâëÿþòñÿ ñèìâîëüíûìè ñòðîêàìè. Ïåðåä çíàêîì\n\ +ðàâíî íå äîëæíî áûòü ïðîáåëîâ, èìÿ ïåðåìåííîé íå ìîæåò ñîäåðæàòü\n\ +ïðîáåëû.\n\ +\n\ + Wine ïåðåìåííûå îêðóæåíèÿ îñíîâíîé îïåðàöèîííîé ñèñòåìû âêëþ÷åíû\n\ +â îêðóæåíèå Win32, ïîýòîìó áóäåò äîñòóïíî íåñêîëüêî áîëüøå\n\ +ïåðåìåííûõ, ÷åì â îáû÷íîé Win32. Ñòîèò îòìåòèòü,\n\ +÷òî íåâîçìîæíî èçìåíèòü îêðóæåíèå îïåðàöèîííîé ñèñòåìû èç cmd.\n" + + WCMD_SHIFT, +"SHIFT èñïîëüçóåòñÿ â bat-ôàéëàõ äëÿ óäàëåíèÿ îäíîãî ïàðàìåòðà ñ âåðøèíû\n\ +ñïèñêà, òàêèì îáðàçîì ïàðàìåòð 2 ïåðåìåñòèòñÿ â ïàðàìåòð 1 è òàê äàëåå.\n\ +SHIFT íå ðàáîòàåò ïðè âûçîâå â êîìàíäíîé ñòðîêå.\n" + + WCMD_TIME, "Ñïðàâêà î TIME\n" + + WCMD_TITLE, "Óñòàíàâëèâàåò çàãîëîâîê îêíà cmd äëÿ òåêóùåé ñåññèè.\n Ñèíòàêñèñ: TITLE <ñòðîêà>\n" + + WCMD_TYPE, +"TYPE <ôàéë> êîïèðóåò <ôàéë> â óñòðîéñòâî êîíñîëè (èëè êóäà óãîäíî, åñëè îí ïåðåíàïðàâëåí).\n\ +Ïðîâåðêà íà òî, ÷òî ôàéë - ýòî òåêñò, ïðåäíàçíà÷åííûé äëÿ ÷òåíèÿ, îòñóòñòâóåò.\n" + + WCMD_VERIFY, +"VERIFY ïðåäíàçíà÷åíà äëÿ óñòàíîâêè, ñáðîñà èëè îïðåäåëåíèÿ ôëàãà ïðîâåðêè\n\ +êîððåêòíîñòè çàïèñè ôàéëîâ íà äèñê. Âîçìîæíûå çíà÷åíèÿ:\n\ +\n\ +VERIFY ON Óñòàíîâèòü ôëàã\n\ +VERIFY OFF Ñáðîñèòü ôëàã\n\ +VERIFY Âûâîäèò òåêóùåå ñîñòîÿíèå: ON èëè OFF.\n\ +\n\ +Ôëàã verify íå èñïîëüçóåòñÿ Wine.\n" + + WCMD_VER, +"VER îòîáðàæàåò âåðñèþ çàïóùåííîãî cmd\n" + + WCMD_VOL, "Ñïðàâêà î VOL\n" + + WCMD_PUSHD, "PUSHD ñîõðàíÿåò òåêóùèé êàòàëîã â ñòåê,\n\ +à çàòåì ïåðåõîäèò â óêàçàííûé êàòàëîã.\n" + + WCMD_POPD, "POPD ïåðåõîäèò â êàòàëîã, ñîõðàí¸ííûé êîìàíäîé\n\ +PUSHD.\n" + + WCMD_MORE, "MORE displays output of files or piped input in pages.\n" + + WCMD_EXIT, +"EXIT çàâåðøàåò òåêóùóþ êîìàíäíóþ ñåññèþ è âîçâðàùàåò\n\ +â îïåðàöèîííóþ ñèñòåìó èëè îáîëî÷êó èç êîòîðîé áûë çàïóùåí cmd.\n" + + WCMD_ALLHELP, "Âñòðîåííûå êîìàíäû CMD:\n\ +ATTRIB\t\tÏîêàçàòü èëè èçìåíèòü DOS-àòðèáóòû ôàéëà\n\ +CALL\t\tÇàïóñòèòü bat-ôàéë èç äðóãîãî bat-ôàéëà\n\ +CD (CHDIR)\tÑìåíèòü òåêóùóþ ïàïêó\n\ +CLS\t\tÎ÷èñòèòü ýêðàí êîíñîëè\n\ +COPY\t\tÑêîïèðîâàòü ôàéë\n\ +CTTY\t\tÑìåíèòü óñòðîéñòâî ââîäà/âûâîäà\n\ +DATE\t\tÏîêàçàòü èëè èçìåíèòü ñèñòåìíóþ äàòó\n\ +DEL (ERASE)\tÓäàëèòü ôàéë èëè íàáîð ôàéëîâ\n\ +DIR\t\tÏîêàçàòü ñîäåðæàíèå ïàïêè\n\ +ECHO\t\tÑêîïèðîâàòü òåêñò ïðÿìî íà âûõîä êîíñîëè\n\ +HELP\t\tÏîêàçàòü êðàòêóþ ïîäñêàçêó ïî êîìàíäå\n\ +MD (MKDIR)\tÑîçäàòü ïàïêó\n\ +MORE\t\tÂûâåñòè äàííûå ïî ñòðàíèöàì\n\ +MOVE\t\tÏåðåìåñòèòü ôàéë, íàáîð ôàéëîâ èëè äåðåâî ïàïîê\n\ +PATH\t\tÏîêàçàòü èëè èçìåíèòü ïóòü ïîèñêà ïðîãðàìì\n\ +POPD\t\tÂîññòàíîâèòü ïðåäûäóùåå çíà÷åíèå òåêóùåé ïàïêè, ñîõðàí¸ííîãî ñ ïîìîùüþ PUSHD\n\ +PUSHD\t\tÑîõðàíèòü çíà÷åíèå òåêóùåé ïàïêè è ïåðåõîäèò ê äðóãîé ïàïêå\n\ +PROMPT\t\tÈçìåíèòü ïðèãëàøåíèå êîìàíäíîé ñòðîêè\n\ +REN (RENAME)\tÏåðåèìåíîâàòü ôàéë\n\ +RD (RMDIR)\tÓäàëèòü ïàïêó\n\ +SET\t\tÏîêàçàòü èëè èçìåíèòü ïåðåìåííûå îêðóæåíèÿ\n\ +TIME\t\tÏîêàçàòü èëè èçìåíèòü òåêóùåå ñèñòåìíîå âðåìÿ\n\ +TITLE\t\tÓñòàíàâèòü çàãîëîâîê îêíà cmd äëÿ òåêóùåé ñåññèè\n\ +TYPE\t\tÂûâåñòè ñîäåðæàíèå òåêñòîâîãî ôàéëà\n\ +VER\t\tÏîêàçàòü òåêóùóþ âåðñèþ CMD\n\ +VOL\t\tÏîêàçàòü ìåòêó òîìà äèñêîâîãî óñòðîéñòâà\n\ +EXIT\t\tÂûéòè èç CMD\n\n\ +Âûïîëíèòå HELP <êîìàíäà> äëÿ äîïîëíèòåëüíîé èíôîðìàöèè ïî ïåðå÷èñëåííûì âûøå êîìàíäàì.\n" + + WCMD_CONFIRM, "Âû óâåðåíû?" + WCMD_YES, "Ä" + WCMD_NO, "Í" + WCMD_NOASSOC, "Ôàéë, àññîöèèðîâàííûé ñ ðàñøèðåíèåì %s,îòñóòñòâóåò\n" + WCMD_NOFTYPE, "Íå ðàáîòàåò êîìàíäà, àññîöèèðîâàííàÿ ñ ôàéëîì '%s'\n" + WCMD_OVERWRITE, "Ïåðåçàïèñàíî %s" + WCMD_MORESTR, "Äàëüøå..." + WCMD_TRUNCATEDLINE, "Ñòðîêà â îáðàáàòûâàåìîì bat-ôàéëå âîçìîæíî óðåçàíà. Èñïîëüçóåì:\n" + WCMD_NYI, "Åù¸ íå âûïîëíåíî\n\n" + WCMD_NOARG, "Îòñóòñòâóåò àðãóìåíò\n" + WCMD_SYNTAXERR, "Ñèíòàêñè÷åñêàÿ îøèáêà\n" + WCMD_FILENOTFOUND, "%s : Ôàéë íå íàéäåí\n" + WCMD_NOCMDHELP, "Ñïðàâêà äëÿ %s îòñóòñòâóåò\n" + WCMD_NOTARGET, "Öåëü äëÿ GOTO íå íàéäåíà\n" + WCMD_CURRENTDATE, "Òåêóùàÿ äàòà %s\n" + WCMD_CURRENTTIME, "Òåêóùåå âðåìÿ %s\n" + WCMD_NEWDATE, "Ââåäèòå íîâóþ äàòó: " + WCMD_NEWTIME, "Ââåäèòå íîâîå âðåìÿ: " + WCMD_MISSINGENV, "Ïåðåìåííàÿ îêðóæåíèÿ %s íå îïðåäåëåíà\n" + WCMD_READFAIL, "Îøèáêà ïðè îòêðûòèè '%s'\n" + WCMD_CALLINSCRIPT, "Íå ìîãó âûçâàòü ìåòêó bat-ôàéëà âíå bat-ñêðèïòà\n" + WCMD_ALL, "Â" + WCMD_DELPROMPT, "%s, Óäàëåíî" + WCMD_ECHOPROMPT, "Echo óñòàíîâëåíî â %s\n" + WCMD_VERIFYPROMPT, "Verify óñòàíîâëåíî â %s\n" + WCMD_VERIFYERR, "Verify äîëæåí áûòü ëèáî ON, ëèáî OFF\n"; + WCMD_ARGERR, "Íåâåðíûé ïàðàìåòð\n" + WCMD_VOLUMEDETAIL, "Îáú¸ì äèñêà %c %s\n Ñåðèéíûé íîìåð %04x-%04x\n\n" + WCMD_VOLUMEPROMPT, "Ìåòêà äèñêà (11 ñèìâîëîâ, ENTER äëÿ ââîäà ïóñòîé ìåòêè)?" + WCMD_NOPATH, "PATH íå íàéäåí\n" + WCMD_ANYKEY,"Íàæìèòå ââîä äëÿ ïðîäîëæåíèÿ: " + WCMD_CONSTITLE,"Ïðèãëàøåíèå êîìàíäíîé ñòðîêè Wine" + WCMD_VERSION,"Âåðñèÿ CMD %s\n\n" + WCMD_MOREPROMPT, "Åù¸? " + WCMD_LINETOOLONG, "The input line is too long.\n" +} diff --git a/programs/cmd/Si.rc b/programs/cmd/Si.rc index d58aab0d24e..9a18741367c 100644 --- a/programs/cmd/Si.rc +++ b/programs/cmd/Si.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wcmd.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -274,3 +272,5 @@ Uporabite HELP za več informacijo o kateremkoli od zgoraj navedenih ukaz WCMD_MOREPROMPT, "Več? " WCMD_LINETOOLONG, "The input line is too long.\n" } + +#pragma code_page(default) diff --git a/programs/cmd/Tr.rc b/programs/cmd/Tr.rc index 36fbf70aa72..656a5831685 100644 --- a/programs/cmd/Tr.rc +++ b/programs/cmd/Tr.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wcmd.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/cmd/wcmd.h b/programs/cmd/wcmd.h index 667b3b99051..4d3bab6621a 100644 --- a/programs/cmd/wcmd.h +++ b/programs/cmd/wcmd.h @@ -21,7 +21,6 @@ #define IDI_ICON1 1 #include -#include #ifndef RC_INVOKED #include #include diff --git a/programs/cmd/wcmdrc.rc b/programs/cmd/wcmdrc.rc index 1eec83982c8..d6906d38776 100644 --- a/programs/cmd/wcmdrc.rc +++ b/programs/cmd/wcmdrc.rc @@ -16,7 +16,28 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include +#include + #include "wcmd.h" +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Es.rc" +#include "Fr.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Tr.rc" + +LANGUAGE LANG_NEUTRAL,SUBLANG_NEUTRAL + /* @makedep: wcmd.ico */ IDI_ICON1 ICON wcmd.ico diff --git a/programs/cmdlgtst/Cs.rc b/programs/cmdlgtst/Cs.rc index 6e8ed2f69a4..d6bb383ee0c 100644 --- a/programs/cmdlgtst/Cs.rc +++ b/programs/cmdlgtst/Cs.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/programs/cmdlgtst/Da.rc b/programs/cmdlgtst/Da.rc index 9d73888f7bc..99bd0fee5b8 100644 --- a/programs/cmdlgtst/Da.rc +++ b/programs/cmdlgtst/Da.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT CmdlgtstMenu MENU diff --git a/programs/cmdlgtst/De.rc b/programs/cmdlgtst/De.rc index 5583c6ba202..f8e7d0e31e5 100644 --- a/programs/cmdlgtst/De.rc +++ b/programs/cmdlgtst/De.rc @@ -19,10 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL CmdlgtstMenu MENU @@ -34,7 +30,7 @@ CmdlgtstMenu MENU POPUP "&Commdlg" { - MENUITEM "&Öffnen", CM_U_OPEN + MENUITEM "&Öffnen", CM_U_OPEN MENUITEM "&Speichern", CM_U_SAVE MENUITEM SEPARATOR MENUITEM "&Farbe", CM_U_COLOR @@ -63,7 +59,7 @@ CmdlgtstMenu MENU POPUP "&Hilfe" { MENUITEM "&Gebrauch", CM_H_USAGE - MENUITEM "Ü&ber", CM_H_ABOUT + MENUITEM "Ü&ber", CM_H_ABOUT } } @@ -149,7 +145,7 @@ FONT 8, "MS Shell Dlg" CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 168, 11, 13 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 180, 11, 13 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 24, 228, 11, 13 - CONTROL "Markierte Flags sind durch das System gesetzt worden und müssen von dem Benutzer entfernt werden", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 48, 228, 98, 36 + CONTROL "Markierte Flags sind durch das System gesetzt worden und müssen von dem Benutzer entfernt werden", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 48, 228, 98, 36 } Print_Flags_Dialog DIALOG 4, 17, 239, 287 @@ -214,7 +210,7 @@ FONT 8, "MS Shell Dlg" File_Flags_Dialog DIALOG 6, 15, 207, 227 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Öffne Datei/Sichere Datei Flags" +CAPTION "Öffne Datei/Sichere Datei Flags" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 @@ -241,7 +237,7 @@ FONT 8, "MS Shell Dlg" AboutDialog DIALOG 6, 15, 194, 119 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Über" +CAPTION "Über" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 72, 96, 50, 14 @@ -257,11 +253,11 @@ FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 70, 276, 50, 14 LTEXT "Common Dialog Test Jig Exerciser, Version 1.20", -1, 13, 48, 168, 12 - LTEXT "Dieses Tool testet COMMDLG für Wine.", -1, 12, 72, 168, 12 - LTEXT "Die Flags können im Flags - Menü gefunden werden.", -1, 12, 96, 168, 24 - LTEXT "Farbdialog ändert die Hintergrundfarbe.", -1, 12, 120, 168, 12 - LTEXT "Schriftdialog ändert alle Schriften und die Schriftfarbe, wenn CF_EFFECTS ausgewählt ist.", -1, 12, 144, 168, 24 - LTEXT "Die linke, obere Ecke weist auf den vollständen Verzeichnisnamen und die Bezeichnung des letzten erfolgreichen Öffnens oder Sicherns hin.", -1, 12, 180, 168, 24 + LTEXT "Dieses Tool testet COMMDLG für Wine.", -1, 12, 72, 168, 12 + LTEXT "Die Flags können im Flags - Menü gefunden werden.", -1, 12, 96, 168, 24 + LTEXT "Farbdialog ändert die Hintergrundfarbe.", -1, 12, 120, 168, 12 + LTEXT "Schriftdialog ändert alle Schriften und die Schriftfarbe, wenn CF_EFFECTS ausgewählt ist.", -1, 12, 144, 168, 24 + LTEXT "Die linke, obere Ecke weist auf den vollständen Verzeichnisnamen und die Bezeichnung des letzten erfolgreichen Öffnens oder Sicherns hin.", -1, 12, 180, 168, 24 LTEXT "(c) 1999-2000, Eric Williams. Rights are as granted under the WINE license. Don't hoard code... share it!", -1, 12, 228, 168, 36 ICON "AboutIcon", -1, 86, 12, 18, 20 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 216, 168, 2 @@ -276,7 +272,7 @@ BEGIN CONTROL "", rct2, "Static", SS_GRAYRECT, 160, 12, 4, 80 CONTROL "", rct3, "Static", SS_GRAYRECT, 84, 88, 80, 4 GROUPBOX "Papier", grp2, 8, 96, 224, 56, BS_GROUPBOX - LTEXT "&Größe:", stc2, 16, 112, 36, 8 + LTEXT "&Größe:", stc2, 16, 112, 36, 8 COMBOBOX cmb2, 64, 110, 80, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL COMBOBOX cmb1, 150, 110, 80, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL LTEXT "&Zufuhr", stc3, 16, 132, 36, 8 @@ -284,7 +280,7 @@ BEGIN GROUPBOX "Format", grp1, 8, 156, 64, 56, BS_GROUPBOX AUTORADIOBUTTON "&Hochformat", rad1, 16, 170, 52, 12, BS_AUTORADIOBUTTON AUTORADIOBUTTON "&Querformat", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON - GROUPBOX "Ränder", grp4, 80, 156, 152, 56, BS_GROUPBOX + GROUPBOX "Ränder", grp4, 80, 156, 152, 56, BS_GROUPBOX LTEXT "&Links:", stc15, 88, 172, 21, 8 EDITTEXT edt4, 111, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER LTEXT "&Rechts:", stc16, 159, 172, 27, 8 diff --git a/programs/cmdlgtst/En.rc b/programs/cmdlgtst/En.rc index 839a9171128..5d73c575b34 100644 --- a/programs/cmdlgtst/En.rc +++ b/programs/cmdlgtst/En.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT CmdlgtstMenu MENU diff --git a/programs/cmdlgtst/Es.rc b/programs/cmdlgtst/Es.rc index 94d221cc2f4..04ef2bb9287 100644 --- a/programs/cmdlgtst/Es.rc +++ b/programs/cmdlgtst/Es.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL CmdlgtstMenu MENU diff --git a/programs/cmdlgtst/Fr.rc b/programs/cmdlgtst/Fr.rc index c1a11e9a8b9..b8cb1b40c61 100644 --- a/programs/cmdlgtst/Fr.rc +++ b/programs/cmdlgtst/Fr.rc @@ -3,8 +3,8 @@ * French Language Support * * Copyright (c) 1999 Eric Williams. - * Copyright (c) 2003 Vincent Béron. - * Copyright (c) 2006 Jonathan Ernst. + * Copyright (c) 2003 Vincent Béron. + * Copyright (c) 2006 Jonathan Ernst. * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -21,11 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL CmdlgtstMenu MENU @@ -50,7 +45,7 @@ CmdlgtstMenu MENU MENUITEM "Mise en pa&ge", CM_U_PAGESETUP } - POPUP "&Indicateurs" + POPUP "&Drapeaux" { MENUITEM "&Fichier", CM_F_FILE MENUITEM SEPARATOR @@ -63,17 +58,17 @@ CmdlgtstMenu MENU MENUITEM "Mise en pa&ge", CM_F_PAGESETUP } - POPUP "&Aide" + POPUP "Aid&e" { MENUITEM "&Usage", CM_H_USAGE - MENUITEM "À &propos", CM_H_ABOUT + MENUITEM "À &propos", CM_H_ABOUT } } Color_Flags_Dialog DIALOG 11, 20, 207, 107 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Indicateurs de la boîte de dialogue de choix de la couleur" +CAPTION "Drapeaux de la boîte de dialogue de choix de la couleur" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP @@ -90,7 +85,7 @@ FONT 8, "MS Shell Dlg" Font_Flags_Dialog DIALOG 9, 20, 207, 313 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Indicateurs de la boîte de dialogue de choix de la police" +CAPTION "Drapeaux de la boîte de dialogue de choix de la police" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 @@ -124,7 +119,7 @@ FONT 8, "MS Shell Dlg" Find_Flags_Dialog DIALOG 8, 24, 207, 306 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Indicateurs de la fenêtre de recherche/remplacement" +CAPTION "Drapeaux de la fenêtre de recherche/remplacement" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 @@ -152,12 +147,12 @@ FONT 8, "MS Shell Dlg" CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 168, 11, 13 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 180, 11, 13 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 24, 228, 11, 13 - CONTROL "Signale les indicateurs qui sont définis par le système et doivent être explicitement effacés par l'utilisateur.", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 48, 228, 98, 36 + CONTROL "Indique les drapeaux qui sont fournis par le système et qui doivent être effacés par l'usager.", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 48, 228, 98, 36 } Print_Flags_Dialog DIALOG 4, 17, 239, 287 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Indicateurs de la boîte de dialogue d'impression" +CAPTION "Drapeaux de la boîte de dialogue d'impression" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 180, 6, 50, 14 @@ -217,7 +212,7 @@ FONT 8, "MS Shell Dlg" File_Flags_Dialog DIALOG 6, 15, 207, 227 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Indicateurs de la boîte de dialogue d'ouverture et d'enregistrement de fichier" +CAPTION "Drapeaux de la boîte de dialogue d'ouverture et d'enregistrement de fichier" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 @@ -244,12 +239,12 @@ FONT 8, "MS Shell Dlg" AboutDialog DIALOG 6, 15, 194, 119 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "À propos" +CAPTION "À propos" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 72, 96, 50, 14 - LTEXT "Test des boîtes de dialogue standard, version 1.20", -1, 13, 36, 168, 12 - LTEXT "(c) 1999-2000, Eric Williams. Droits tels qu'accordés par la licence de Wine. N'accumulez pas du code tout seul... partagez-le !", -1, 18, 60, 157, 24 + LTEXT "Gabarit de test des boîtes de dialogue standards, version 1.20", -1, 13, 36, 168, 12 + LTEXT "(c) 1999-2000, Eric Williams. Droits tels qu'accordés par la licence de Wine. N'accumulez pas du code tout seul... partagez-le !", -1, 18, 60, 157, 24 ICON "AboutIcon", -1, 84, 12, 18, 20 } @@ -259,43 +254,43 @@ CAPTION "Usage" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 70, 276, 50, 14 - LTEXT "Test des boîtes de dialogue standard, version 1.20", -1, 13, 48, 168, 12 + LTEXT "Gabarit de test des boîtes de dialogue standards, version 1.20", -1, 13, 48, 168, 12 LTEXT "Cet outil teste COMMDLG pour Wine.", -1, 12, 72, 168, 12 - LTEXT "Indicateurs spécifiés dans le menu Indicateurs.", -1, 12, 96, 168, 12 - LTEXT "La boîte de dialogue de choix de la couleur permet de modifier la couleur de l'arrière-plan.", -1, 12, 114, 168, 18 - LTEXT "La boîte de dialogue de choix de la police permet de sélectionner toutes les polices, et couleurs de police si CF_EFFECTS est sélectionné.", -1, 12, 144, 168, 24 - LTEXT "Le nom complet et le titre de la dernière opération réussie d'ouverture ou d'enregistrement se trouvent dans le coin en haut à gauche.", -1, 12, 180, 168, 24 - LTEXT "(c) 1999-2000, Eric Williams. Droits tels qu'accordés par la licence de Wine. N'accumulez pas du code tout seul... partagez-le !", -1, 12, 228, 168, 36 + LTEXT "Les drapeaux sont spécifés dans le menu Drapeaux.", -1, 12, 96, 168, 12 + LTEXT "La boîte de dialogue de choix de la couleur change la couleur de l'arrière-plan.", -1, 12, 120, 168, 12 + LTEXT "La boîte de dialogue de choix de la police change toutes les polices, et la couleur de la police si CF_EFFECTS est sélectionné.", -1, 12, 144, 168, 24 + LTEXT "Le nom complet et le titre de la dernière opération réussie d'ouverture ou d'enregistrement se trouvent dans le coin en haut à gauche.", -1, 12, 180, 168, 24 + LTEXT "(c) 1999-2000, Eric Williams. Droits tels qu'accordés par la licence de Wine. N'accumulez pas du code tout seul... partagez-le !", -1, 12, 228, 168, 36 ICON "AboutIcon", -1, 86, 12, 18, 20 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 216, 168, 2 } PAGESETUPDLGORD_CSTM DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 240, 240 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Boîte de dialogue de test TFT" +CAPTION "TFT test dialog" FONT 8, "MS Shell Dlg" BEGIN CONTROL "", rct1, "Static", SS_WHITERECT, 80, 8, 80, 80 CONTROL "", rct2, "Static", SS_GRAYRECT, 160, 12, 4, 80 CONTROL "", rct3, "Static", SS_GRAYRECT, 84, 88, 80, 4 GROUPBOX "Papier", grp2, 8, 96, 224, 56, BS_GROUPBOX - LTEXT "&Taille :", stc2, 16, 112, 36, 8 + LTEXT "&Taille :", stc2, 16, 112, 36, 8 COMBOBOX cmb2, 64, 110, 80, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL COMBOBOX cmb1, 150, 110, 80, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - LTEXT "Ba&c :", stc3, 16, 132, 36, 8 + LTEXT "&Bac :", stc3, 16, 132, 36, 8 COMBOBOX cmb3, 64, 130, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL GROUPBOX "Orientation", grp1, 8, 156, 64, 56, BS_GROUPBOX AUTORADIOBUTTON "&Portrait", rad1, 16, 170, 52, 12, BS_AUTORADIOBUTTON - AUTORADIOBUTTON "Pa&ysage", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON + AUTORADIOBUTTON "&Paysage", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON GROUPBOX "Bordures", grp4, 80, 156, 152, 56, BS_GROUPBOX - LTEXT "&Gauche :", stc15, 88, 172, 29, 8 - EDITTEXT edt4, 119, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "&Droite :", stc16, 163, 172, 27, 8 - EDITTEXT edt6, 190, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "&Haut :", stc17, 88, 192, 21, 8 - EDITTEXT edt5, 119, 190, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "&Bas :", stc18, 163, 192, 23, 8 - EDITTEXT edt7, 190, 190, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER + LTEXT "&Gauche :", stc15, 88, 172, 21, 8 + EDITTEXT edt4, 111, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER + LTEXT "&Droite :", stc16, 159, 172, 27, 8 + EDITTEXT edt6, 187, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER + LTEXT "&Haut :", stc17, 88, 192, 21, 8 + EDITTEXT edt5, 111, 190, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER + LTEXT "&Bas :", stc18, 159, 192, 23, 8 + EDITTEXT edt7, 187, 190, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER DEFPUSHBUTTON "OK", IDOK, 71, 220, 50, 14, BS_PUSHBUTTON PUSHBUTTON "Annuler", IDCANCEL, 126, 220, 50, 14 PUSHBUTTON "&Imprimante...", psh3, 184, 220, 48, 14 diff --git a/programs/cmdlgtst/It.rc b/programs/cmdlgtst/It.rc index 1bc2e46ad87..069045e2e0d 100644 --- a/programs/cmdlgtst/It.rc +++ b/programs/cmdlgtst/It.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL /* @@ -42,26 +40,26 @@ CmdlgtstMenu MENU MENUITEM "&Salva", CM_U_SAVE MENUITEM SEPARATOR MENUITEM "&Colori", CM_U_COLOR - MENUITEM "&Carattere", CM_U_FONT + MENUITEM "&Font", CM_U_FONT MENUITEM SEPARATOR MENUITEM "Trova &Testo", CM_U_FIND MENUITEM "&Sostituisci Testo", CM_U_REPLACE MENUITEM SEPARATOR MENUITEM "&Stampa", CM_U_PRINT - MENUITEM "Installazione Pa&gina", CM_U_PAGESETUP + MENUITEM "Pa&ge Setup", CM_U_PAGESETUP } - POPUP "B&andiere" + POPUP "F&lags" { MENUITEM "Fil&e", CM_F_FILE MENUITEM SEPARATOR MENUITEM "&Colori", CM_F_COLOR - MENUITEM "&Carattere", CM_F_FONT + MENUITEM "&Font", CM_F_FONT MENUITEM SEPARATOR MENUITEM "Trova/&Sostituisci", CM_F_FINDREPLACE MENUITEM SEPARATOR MENUITEM "&Stampa", CM_F_PRINT - MENUITEM "Installazione Pa&gina", CM_F_PAGESETUP + MENUITEM "Pa&ge Setup", CM_F_PAGESETUP } POPUP "&Aiuto" @@ -74,11 +72,11 @@ CmdlgtstMenu MENU Color_Flags_Dialog DIALOG 11, 20, 207, 107 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Bandiere Dialogo Carattere" +CAPTION "Font Dialog Flags" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Annulla", IDCANCEL, 148, 24, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Cancella", IDCANCEL, 148, 24, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "Aiuto", CM_R_HELP, 148, 42, 50, 14, WS_GROUP | WS_TABSTOP CHECKBOX "CC_ENABLEHOOK", I_CC_ENABLEHOOK, 12, 12, 122, 10, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "CC_ENABLETEMPLATE", I_CC_ENABLETEMPLATE, 12, 24, 122, 10, BS_AUTOCHECKBOX | WS_TABSTOP @@ -95,7 +93,7 @@ CAPTION "Font Dialog Flags" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 - PUSHBUTTON "Annulla", IDCANCEL, 148, 24, 50, 14 + PUSHBUTTON "Cancella", IDCANCEL, 148, 24, 50, 14 PUSHBUTTON "Aiuto", CM_R_HELP, 148, 42, 50, 14 CHECKBOX "CF_APPLY", I_CF_APPLY, 12, 12, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "CF_ANSIONLY", I_CF_ANSIONLY, 12, 24, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP @@ -129,7 +127,7 @@ CAPTION "Trova/Sostituisci Dialog Flags" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 - PUSHBUTTON "Annulla", IDCANCEL, 148, 24, 50, 14 + PUSHBUTTON "Cancella", IDCANCEL, 148, 24, 50, 14 PUSHBUTTON "Aiuto", IDHELP, 148, 42, 50, 14 CHECKBOX "FR_DIALOGTERM", I_FR_DIALOGTERM, 24, 12, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "FR_DOWN", I_FR_DOWN, 24, 24, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP @@ -228,15 +226,15 @@ FONT 8, "MS Shell Dlg" UsageDialog DIALOG 183, 22, 190, 300 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Utilizzo" +CAPTION "Ustilizzo" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 70, 276, 50, 14 LTEXT "Common Dialog Test Jig Exerciser, versione 1.20", -1, 13, 48, 168, 12 LTEXT "Questo programma testa COMMDLG per Wine.", -1, 12, 72, 168, 12 - LTEXT "Le Bandiere sono specificate nel menù bandiere.", -1, 12, 96, 168, 12 + LTEXT "I Flags sono specificati nel menu flags.", -1, 12, 96, 168, 12 LTEXT "La finestra di dialogo dei colori modifica il colore dello sfondo.", -1, 12, 120, 168, 12 - LTEXT "La finestra di dialogo dei Caratteri modifica tutti i Caratteri, e il loro colore se CF_EFFECTS e selezionato.", -1, 12, 144, 168, 24 + LTEXT "La finestra di dialogo dei Font modifica tutti i Font, e il loro colore se CF_EFFECTS e selezionato.", -1, 12, 144, 168, 24 LTEXT "L'angolo in alto a sinistra indica il percorso completo e il titolo dell'ultima operazione di apertura o salvataggio conclusa con successo.", -1, 12, 180, 168, 24 LTEXT "(c) 1999-2000, Eric Williams. I diritti sono concessi sotto la licenza di WINE. Non nascondere i sorgenti... condividili!", -1, 12, 228, 168, 36 ICON "AboutIcon", -1, 86, 12, 18, 20 diff --git a/programs/cmdlgtst/Ja.rc b/programs/cmdlgtst/Ja.rc index 92ccddb3996..fb73bfa94c1 100644 --- a/programs/cmdlgtst/Ja.rc +++ b/programs/cmdlgtst/Ja.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - /* UTF-8 */ #pragma code_page(65001) @@ -298,3 +296,5 @@ BEGIN PUSHBUTTON "キャンセル", IDCANCEL, 126, 220, 50, 14 PUSHBUTTON "プリンタ(&R)...", psh3, 184, 220, 48, 14 END + +#pragma code_page(default) diff --git a/programs/cmdlgtst/Ko.rc b/programs/cmdlgtst/Ko.rc index 7d099f725c6..314ba9bf208 100644 --- a/programs/cmdlgtst/Ko.rc +++ b/programs/cmdlgtst/Ko.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT CmdlgtstMenu MENU diff --git a/programs/cmdlgtst/Lt.rc b/programs/cmdlgtst/Lt.rc deleted file mode 100644 index a6d7e83a7bc..00000000000 --- a/programs/cmdlgtst/Lt.rc +++ /dev/null @@ -1,300 +0,0 @@ -/* - * Common Dialog Test Jig Exerciser - * Lithuanian Language Support - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "cmdlgtst.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -CmdlgtstMenu MENU -{ - POPUP "&Failas" - { - MENUITEM "&Išeiti", CM_U_EXIT - } - - POPUP "&Commdlg" - { - MENUITEM "&Atverti", CM_U_OPEN - MENUITEM "&Išsaugoti", CM_U_SAVE - MENUITEM SEPARATOR - MENUITEM "&Spalva", CM_U_COLOR - MENUITEM "&Šriftas", CM_U_FONT - MENUITEM SEPARATOR - MENUITEM "Ieškoti &teksto", CM_U_FIND - MENUITEM "Pa&keisti tekstą", CM_U_REPLACE - MENUITEM SEPARATOR - MENUITEM "S&pausdinti", CM_U_PRINT - MENUITEM "Puslapio &nuostatos", CM_U_PAGESETUP - } - - POPUP "Ž&ymos bitai" - { - MENUITEM "&Failas", CM_F_FILE - MENUITEM SEPARATOR - MENUITEM "&Spalva", CM_F_COLOR - MENUITEM "&Šriftas", CM_F_FONT - MENUITEM SEPARATOR - MENUITEM "&Ieškoti/pakeisti", CM_F_FINDREPLACE - MENUITEM SEPARATOR - MENUITEM "S&pausdinti", CM_F_PRINT - MENUITEM "Puslapio &nuostatos", CM_F_PAGESETUP - } - - POPUP "&Žinynas" - { - MENUITEM "&Naudojimas", CM_H_USAGE - MENUITEM "&Apie", CM_H_ABOUT - } - -} - -Color_Flags_Dialog DIALOG 11, 20, 207, 107 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Spalvos dialogo lango žymos bitai" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "Gerai", IDOK, 148, 6, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Atsisakyti", IDCANCEL, 148, 24, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "Žinynas", CM_R_HELP, 148, 42, 50, 14, WS_GROUP | WS_TABSTOP - CHECKBOX "CC_ENABLEHOOK", I_CC_ENABLEHOOK, 12, 12, 122, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CC_ENABLETEMPLATE", I_CC_ENABLETEMPLATE, 12, 24, 122, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CC_ENABLETEMPLATEHANDLE", I_CC_ENABLETEMPLATEHANDLE, 12, 36, 122, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CC_FULLOPEN", I_CC_FULLOPEN, 12, 48, 122, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CC_PREVENTFULLOPEN", I_CC_PREVENTFULLOPEN, 12, 60, 122, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CC_RGBINIT", I_CC_RGBINIT, 12, 72, 122, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CC_SHOWHELP", I_CC_SHOWHELP, 12, 84, 122, 10, BS_AUTOCHECKBOX | WS_TABSTOP -} - -Font_Flags_Dialog DIALOG 9, 20, 207, 313 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Šrifto dialogo lango žymos bitai" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "Gerai", IDOK, 148, 6, 50, 14 - PUSHBUTTON "Atsisakyti", IDCANCEL, 148, 24, 50, 14 - PUSHBUTTON "Žinynas", CM_R_HELP, 148, 42, 50, 14 - CHECKBOX "CF_APPLY", I_CF_APPLY, 12, 12, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_ANSIONLY", I_CF_ANSIONLY, 12, 24, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_BOTH", I_CF_BOTH, 12, 36, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_TTONLY", I_CF_TTONLY, 12, 48, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_EFFECTS", I_CF_EFFECTS, 12, 60, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_ENABLEHOOK", I_CF_ENABLEHOOK, 12, 72, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_ENABLETEMPLATE", I_CF_ENABLETEMPLATE, 12, 84, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_ENABLETEMPLATEHANDLE", I_CF_ENABLETEMPLATEHANDLE, 12, 96, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_FIXEDPITCHONLY", I_CF_FIXEDPITCHONLY, 12, 108, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_FORCEFONTEXIST", I_CF_FORCEFONTEXIST, 12, 120, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_INITTOLOGFONTSTRUCT", I_CF_INITTOLOGFONTSTRUCT, 12, 132, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_LIMITSIZE", I_CF_LIMITSIZE, 12, 144, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_NOFACESEL", I_CF_NOFACESEL, 12, 156, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_NOOEMFONTS", I_CF_NOOEMFONTS, 12, 168, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_NOSIMULATIONS", I_CF_NOSIMULATIONS, 12, 180, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_NOSIZESEL", I_CF_NOSIZESEL, 12, 192, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_NOSTYLESEL", I_CF_NOSTYLESEL, 12, 204, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_NOVECTORFONTS", I_CF_NOVECTORFONTS, 12, 216, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_PRINTERFONTS", I_CF_PRINTERFONTS, 12, 228, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_SCALABLEONLY", I_CF_SCALABLEONLY, 12, 240, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_SHOWHELP", I_CF_SHOWHELP, 12, 264, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_SCREENFONTS", I_CF_SCREENFONTS, 12, 252, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_USESTYLE", I_CF_USESTYLE, 12, 276, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "CF_WYSIWYG", I_CF_WYSIWYG, 12, 288, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP -} - -Find_Flags_Dialog DIALOG 8, 24, 207, 306 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Ieškoti/pakeisti dialogo lango žymos bitai" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "Gerai", IDOK, 148, 6, 50, 14 - PUSHBUTTON "Atsisakyti", IDCANCEL, 148, 24, 50, 14 - PUSHBUTTON "Žinynas", IDHELP, 148, 42, 50, 14 - CHECKBOX "FR_DIALOGTERM", I_FR_DIALOGTERM, 24, 12, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_DOWN", I_FR_DOWN, 24, 24, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_ENABLEHOOK", I_FR_ENABLEHOOK, 24, 36, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_ENABLETEMPLATE", I_FR_ENABLETEMPLATE, 24, 48, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_ENABLETEMPLATEHANDLE", I_FR_ENABLETEMPLATEHANDLE, 24, 60, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_FINDNEXT", I_FR_FINDNEXT, 24, 72, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_HIDEMATCHCASE", I_FR_HIDEMATCHCASE, 24, 84, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_HIDEWHOLEWORD", I_FR_HIDEWHOLEWORD, 24, 96, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_HIDEUPDOWN", I_FR_HIDEUPDOWN, 24, 108, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_MATCHCASE", I_FR_MATCHCASE, 24, 120, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_NOMATCHCASE", I_FR_NOMATCHCASE, 24, 132, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_NOUPDOWN", I_FR_NOUPDOWN, 24, 144, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_NOWHOLEWORD", I_FR_NOWHOLEWORD, 24, 156, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_REPLACE", I_FR_REPLACE, 24, 168, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_REPLACEALL", I_FR_REPLACEALL, 24, 180, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_SHOWHELP", I_FR_SHOWHELP, 24, 192, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "FR_WHOLEWORD", I_FR_WHOLEWORD, 24, 204, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 12, 11, 13 - CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 72, 11, 13 - CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 168, 11, 13 - CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 180, 11, 13 - CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 24, 228, 11, 13 - CONTROL "Pažymi žymos bitus, kurie yra nustatyti sistemos ir turi būti išvalyti naudotojo.", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 48, 228, 98, 36 -} - -Print_Flags_Dialog DIALOG 4, 17, 239, 287 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Spausdinimo / puslapio nuostatų žymos bitai" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "Gerai", IDOK, 180, 6, 50, 14 - PUSHBUTTON "Atsisakyti", IDCANCEL, 180, 24, 50, 14 - PUSHBUTTON "Žinynas", CM_R_HELP, 180, 42, 50, 14 - CHECKBOX "PD_ALLPAGES", I_PD_ALLPAGES, 12, 12, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_COLLATE", I_PD_COLLATE, 12, 24, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_DISABLEPRINTTOFILE", I_PD_DISABLEPRINTTOFILE, 12, 36, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_ENABLEPRINTHOOK", I_PD_ENABLEPRINTHOOK, 12, 48, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_ENABLEPRINTTEMPLATE", I_PD_ENABLEPRINTTEMPLATE, 12, 60, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_ENABLEPRINTTEMPLATEHANDLE", I_PD_ENABLEPRINTTEMPLATEHANDLE, 12, 72, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_ENABLESETUPHOOK", I_PD_ENABLESETUPHOOK, 12, 84, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_ENABLESETUPTEMPLATE", I_PD_ENABLESETUPTEMPLATE, 12, 96, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_ENABLESETUPTEMPLATEHANDLE", I_PD_ENABLESETUPTEMPLATEHANDLE, 12, 108, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_HIDEPRINTTOFILE", I_PD_HIDEPRINTTOFILE, 12, 120, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_NOPAGENUMS", I_PD_NOPAGENUMS, 12, 132, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_NOSELECTION", I_PD_NOSELECTION, 12, 144, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_NOWARNING", I_PD_NOWARNING, 12, 156, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_PAGENUMS", I_PD_PAGENUMS, 12, 168, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_PRINTSETUP", I_PD_PRINTSETUP, 12, 180, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_PRINTTOFILE", I_PD_PRINTTOFILE, 12, 192, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_RETURNDC", I_PD_RETURNDC, 12, 204, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_RETURNDEFAULT", I_PD_RETURNDEFAULT, 12, 216, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_RETURNIC", I_PD_RETURNIC, 12, 228, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_SELECTION", I_PD_SELECTION, 12, 240, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_SHOWHELP", I_PD_SHOWHELP, 12, 252, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PD_USEDEVMODECOPIES", I_PD_USEDEVMODECOPIES, 12, 264, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP -} - -PageSetup_Flags_Dialog DIALOG 4, 17, 239, 245 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION " " -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "Gerai", IDOK, 180, 6, 50, 14 - PUSHBUTTON "Atsisakyti", IDCANCEL, 180, 24, 50, 14 - CHECKBOX "PSD_DEFAULTMINMARGINS", I_PSD_DEFAULTMINMARGINS, 12, 12, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_DISABLEMARGINS", I_PSD_DISABLEMARGINS, 12, 24, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_DISABLEORIENTATION", I_PSD_DISABLEORIENTATION, 12, 36, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_DISABLEPAGEPAINTING", I_PSD_DISABLEPAGEPAINTING, 12, 48, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_DISABLEPAPER", I_PSD_DISABLEPAPER, 12, 60, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_DISABLEPRINTER", I_PSD_DISABLEPRINTER, 12, 72, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_ENABLEPAGEPAINTHOOK", I_PSD_ENABLEPAGEPAINTHOOK, 12, 84, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_ENABLEPAGESETUPHOOK", I_PSD_ENABLEPAGESETUPHOOK, 12, 96, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_ENABLEPAGESETUPTEMPLATE", I_PSD_ENABLEPAGESETUPTEMPLATE, 12, 108, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_ENABLEPAGESETUPTEMPLATEHANDLE", I_PSD_ENABLEPAGESETUPTEMPLATEHANDLE, 12, 120, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_INHUNDREDTHSOFMILLIMETERS", I_PSD_INHUNDREDTHSOFMILLIMETERS, 12, 132, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_INTHOUSANDTHSOFINCHES", I_PSD_INTHOUSANDTHSOFINCHES, 12, 144, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_INWININIINTLMEASURE", I_PSD_INWININIINTLMEASURE, 12, 156, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_MARGINS", I_PSD_MARGINS, 12, 168, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_MINMARGINS", I_PSD_MINMARGINS, 12, 180, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_NONETWORKBUTTON", I_PSD_NONETWORKBUTTON, 12, 192, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_NOWARNING", I_PSD_NOWARNING, 12, 204, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_RETURNDEFAULT", I_PSD_RETURNDEFAULT, 12, 216, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_SHOWHELP", I_PSD_SHOWHELP, 12, 228, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP -} - -File_Flags_Dialog DIALOG 6, 15, 207, 227 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Atverti failą/išsaugoti failą žymos bitai" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "Gerai", IDOK, 148, 6, 50, 14 - PUSHBUTTON "Atsisakyti", IDCANCEL, 148, 24, 50, 14 - PUSHBUTTON "Žinynas", CM_R_HELP, 148, 42, 50, 14 - CHECKBOX "OFN_ALLOWMULTISELECT", I_OFN_ALLOWMULTISELECT, 12, 12, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_CREATEPROMPT", I_OFN_CREATEPROMPT, 12, 24, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_ENABLEHOOK", I_OFN_ENABLEHOOK, 12, 36, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_ENABLETEMPLATE", I_OFN_ENABLETEMPLATE, 12, 48, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_ENABLETEMPLATEHANDLE", I_OFN_ENABLETEMPLATEHANDLE, 12, 60, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_EXTENSIONDIFFERENT", I_OFN_EXTENSIONDIFFERENT, 12, 72, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_FILEMUSTEXIST", I_OFN_FILEMUSTEXIST, 12, 84, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_HIDEREADONLY", I_OFN_HIDEREADONLY, 12, 96, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_NOCHANGEDIR", I_OFN_NOCHANGEDIR, 12, 108, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_NOREADONLYRETURN", I_OFN_NOREADONLYRETURN, 12, 120, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_NOTESTFILECREATE", I_OFN_NOTESTFILECREATE, 12, 132, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_NOVALIDATE", I_OFN_NOVALIDATE, 12, 144, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_OVERWRITEPROMPT", I_OFN_OVERWRITEPROMPT, 12, 156, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_PATHMUSTEXIST", I_OFN_PATHMUSTEXIST, 12, 168, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_READONLY", I_OFN_READONLY, 12, 180, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_SHAREAWARE", I_OFN_SHAREAWARE, 12, 192, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "OFN_SHOWHELP", I_OFN_SHOWHELP, 12, 204, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP -} - -AboutDialog DIALOG 6, 15, 194, 119 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Apie" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "Gerai", IDOK, 72, 96, 50, 14 - LTEXT "Common Dialog Test Jig Exerciser, versija 1.20", -1, 13, 36, 168, 12 - LTEXT "(c) 1999-2000, Eric Williams. Tokios teisės, kurios duotos WINE licencijos. Nekaupkite kodo... dalinkitės!", -1, 18, 60, 157, 24 - ICON "AboutIcon", -1, 84, 12, 18, 20 -} - -UsageDialog DIALOG 183, 22, 190, 300 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Naudojimas" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "Gerai", IDOK, 70, 276, 50, 14 - LTEXT "Common Dialog Test Jig Exerciser, versija 1.20", -1, 13, 48, 168, 12 - LTEXT "Šis įrankis testuoja Wine COMMDLG.", -1, 12, 72, 168, 12 - LTEXT "Žymos bitai nurodomi žymos bitų meniu.", -1, 12, 96, 168, 12 - LTEXT "Spalvos dialogo langas keičia fono spalvą.", -1, 12, 120, 168, 12 - LTEXT "Šrifto dialogo langas keičia visus šriftus ir šrifto spalvą, jei CF_EFFECTS pažymėtas.", -1, 12, 144, 168, 24 - LTEXT "Viršutinis kairysis kampas rodo paskutinio sėkmingo atvėrimo ar išsaugojimo visą kelią ir pavadinimą.", -1, 12, 180, 168, 24 - LTEXT "(c) 1999-2000, Eric Williams. Tokios teisės, kurios duotos WINE licencijos. Nekaupkite kodo... dalinkitės!", -1, 12, 228, 168, 36 - ICON "AboutIcon", -1, 86, 12, 18, 20 - CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 216, 168, 2 -} - -PAGESETUPDLGORD_CSTM DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 240, 240 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "TFT testo dialogo langas" -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "", rct1, "Static", SS_WHITERECT, 80, 8, 80, 80 - CONTROL "", rct2, "Static", SS_GRAYRECT, 160, 12, 4, 80 - CONTROL "", rct3, "Static", SS_GRAYRECT, 84, 88, 80, 4 - GROUPBOX "Popierius", grp2, 8, 96, 224, 56, BS_GROUPBOX - LTEXT "&Dydis:", stc2, 16, 112, 36, 8 - COMBOBOX cmb2, 64, 110, 80, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - COMBOBOX cmb1, 150, 110, 80, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - LTEXT "Dė&klas:", stc3, 16, 132, 36, 8 - COMBOBOX cmb3, 64, 130, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - GROUPBOX "Padėtis", grp1, 8, 156, 64, 56, BS_GROUPBOX - AUTORADIOBUTTON "&Stačias", rad1, 16, 170, 52, 12, BS_AUTORADIOBUTTON - AUTORADIOBUTTON "&Gulsčias", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON - GROUPBOX "Paraštės", grp4, 80, 156, 152, 56, BS_GROUPBOX - LTEXT "&Kairėje:", stc15, 88, 172, 30, 8 - EDITTEXT edt4, 119, 170, 36, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "&Dešinėje:", stc16, 159, 172, 32, 8 - EDITTEXT edt6, 192, 170, 36, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "&Viršutinė:", stc17, 88, 192, 30, 8 - EDITTEXT edt5, 119, 190, 36, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "&Apatinė:", stc18, 159, 192, 32, 8 - EDITTEXT edt7, 192, 190, 36, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - DEFPUSHBUTTON "Gerai", IDOK, 61, 220, 50, 14, BS_PUSHBUTTON - PUSHBUTTON "Atsisakyti", IDCANCEL, 116, 220, 50, 14 - PUSHBUTTON "S&pausdintuvas...", psh3, 171, 220, 61, 14 -END diff --git a/programs/cmdlgtst/Makefile.in b/programs/cmdlgtst/Makefile.in index 1c6fdce9ef1..15409a86245 100644 --- a/programs/cmdlgtst/Makefile.in +++ b/programs/cmdlgtst/Makefile.in @@ -9,26 +9,7 @@ IMPORTS = comdlg32 user32 gdi32 kernel32 C_SRCS = \ cmdlgtst.c -RC_SRCS = \ - Cs.rc \ - Da.rc \ - De.rc \ - En.rc \ - Es.rc \ - Fr.rc \ - It.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - cmdlgr.rc +RC_SRCS = cmdlgr.rc @MAKE_PROG_RULES@ diff --git a/programs/cmdlgtst/Nl.rc b/programs/cmdlgtst/Nl.rc index 245794d1074..0b9d1353dbf 100644 --- a/programs/cmdlgtst/Nl.rc +++ b/programs/cmdlgtst/Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL CmdlgtstMenu MENU diff --git a/programs/cmdlgtst/No.rc b/programs/cmdlgtst/No.rc index d1e7b3bc175..7d96a2d486e 100644 --- a/programs/cmdlgtst/No.rc +++ b/programs/cmdlgtst/No.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL CmdlgtstMenu MENU diff --git a/programs/cmdlgtst/Pl.rc b/programs/cmdlgtst/Pl.rc index 090e1f4bf0e..3123c2cdcdc 100644 --- a/programs/cmdlgtst/Pl.rc +++ b/programs/cmdlgtst/Pl.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT CmdlgtstMenu MENU diff --git a/programs/cmdlgtst/Pt.rc b/programs/cmdlgtst/Pt.rc index fa53152b26a..38e783ef0b9 100644 --- a/programs/cmdlgtst/Pt.rc +++ b/programs/cmdlgtst/Pt.rc @@ -3,8 +3,7 @@ * Portuguese Language Support * * Copyright 2003 Marcelo Duarte - * Copyright 2004 Américo José Melo - * Copyright 2009 Ricardo Filipe + * 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 @@ -21,10 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - -#pragma code_page(65001) - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN CmdlgtstMenu MENU @@ -91,7 +86,7 @@ CmdlgtstMenu MENU MENUITEM "&Substituir texto", CM_U_REPLACE MENUITEM SEPARATOR MENUITEM "&Imprimir", CM_U_PRINT - MENUITEM "Configurar Página", CM_U_PAGESETUP + MENUITEM "Pa&ge Setup", CM_U_PAGESETUP } POPUP "F&lags" @@ -104,7 +99,7 @@ CmdlgtstMenu MENU MENUITEM "&Localizar/Substituir", CM_F_FINDREPLACE MENUITEM SEPARATOR MENUITEM "&Imprimir", CM_F_PRINT - MENUITEM "Configurar Página", CM_F_PAGESETUP + MENUITEM "Pa&ge Setup", CM_F_PAGESETUP } POPUP "Aj&uda" @@ -120,7 +115,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN Color_Flags_Dialog DIALOG 11, 20, 207, 107 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Flags do diálode de cores" +CAPTION "Flags do diálode de cores" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP @@ -139,7 +134,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE Color_Flags_Dialog DIALOG 11, 20, 207, 107 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Opções do diálogo de cores" +CAPTION "Opções do diálogo de cores" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP @@ -159,7 +154,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN Font_Flags_Dialog DIALOG 9, 20, 207, 313 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Flags do diálogo de fontes" +CAPTION "Flags do diálogo de fontes" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 @@ -194,7 +189,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE Font_Flags_Dialog DIALOG 9, 20, 207, 313 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Opções do diálogo dos tipos de letra" +CAPTION "Opções do diálogo dos tipos de letra" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 @@ -231,7 +226,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN Find_Flags_Dialog DIALOG 8, 24, 207, 306 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Flags do diálogo Localizar/Substituir" +CAPTION "Flags do diálogo Localizar/Substituir" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 @@ -259,14 +254,14 @@ FONT 8, "MS Shell Dlg" CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 168, 11, 13 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 180, 11, 13 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 24, 228, 11, 13 - CONTROL "Marcas flags que são configurados pelo sistema e devem ser limpos pelo usuário.", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 48, 228, 98, 36 + CONTROL "Marcas flags que são configurados pelo sistema e devem ser limpos pelo usuário.", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 48, 228, 98, 36 } LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE Find_Flags_Dialog DIALOG 8, 24, 207, 306 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Opções do diálogo Localizar/Substituir" +CAPTION "Opções do diálogo Localizar/Substituir" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 @@ -294,7 +289,7 @@ FONT 8, "MS Shell Dlg" CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 168, 11, 13 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 180, 11, 13 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 24, 228, 11, 13 - CONTROL "Marcas de opções que são configuradas pelo sistema e devem ser limpos pelo utilizador.", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 48, 228, 98, 36 + CONTROL "Marcas de opções que são configuradas pelo sistema e devem ser limpos pelo utilizador.", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 48, 228, 98, 36 } @@ -302,7 +297,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN Print_Flags_Dialog DIALOG 4, 17, 239, 287 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Flags do diálogo Imprimir/Configurar Impressão" +CAPTION "Flags do diálogo Imprimir/Configurar Impressão" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 180, 6, 50, 14 @@ -336,7 +331,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE Print_Flags_Dialog DIALOG 4, 17, 239, 287 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Opções do diálogo Imprimir/Configurar Impressão" +CAPTION "Opções do diálogo Imprimir/Configurar Impressão" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 180, 6, 50, 14 @@ -366,33 +361,6 @@ FONT 8, "MS Shell Dlg" CHECKBOX "PD_USEDEVMODECOPIES", I_PD_USEDEVMODECOPIES, 12, 264, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP } -PageSetup_Flags_Dialog DIALOG 4, 17, 239, 245 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION " " -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK", IDOK, 180, 6, 50, 14 - PUSHBUTTON "Cancelar", IDCANCEL, 180, 24, 50, 14 - CHECKBOX "PSD_DEFAULTMINMARGINS", I_PSD_DEFAULTMINMARGINS, 12, 12, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_DISABLEMARGINS", I_PSD_DISABLEMARGINS, 12, 24, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_DISABLEORIENTATION", I_PSD_DISABLEORIENTATION, 12, 36, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_DISABLEPAGEPAINTING", I_PSD_DISABLEPAGEPAINTING, 12, 48, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_DISABLEPAPER", I_PSD_DISABLEPAPER, 12, 60, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_DISABLEPRINTER", I_PSD_DISABLEPRINTER, 12, 72, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_ENABLEPAGEPAINTHOOK", I_PSD_ENABLEPAGEPAINTHOOK, 12, 84, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_ENABLEPAGESETUPHOOK", I_PSD_ENABLEPAGESETUPHOOK, 12, 96, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_ENABLEPAGESETUPTEMPLATE", I_PSD_ENABLEPAGESETUPTEMPLATE, 12, 108, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_ENABLEPAGESETUPTEMPLATEHANDLE", I_PSD_ENABLEPAGESETUPTEMPLATEHANDLE, 12, 120, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_INHUNDREDTHSOFMILLIMETERS", I_PSD_INHUNDREDTHSOFMILLIMETERS, 12, 132, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_INTHOUSANDTHSOFINCHES", I_PSD_INTHOUSANDTHSOFINCHES, 12, 144, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_INWININIINTLMEASURE", I_PSD_INWININIINTLMEASURE, 12, 156, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_MARGINS", I_PSD_MARGINS, 12, 168, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_MINMARGINS", I_PSD_MINMARGINS, 12, 180, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_NONETWORKBUTTON", I_PSD_NONETWORKBUTTON, 12, 192, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_NOWARNING", I_PSD_NOWARNING, 12, 204, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_RETURNDEFAULT", I_PSD_RETURNDEFAULT, 12, 216, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP - CHECKBOX "PSD_SHOWHELP", I_PSD_SHOWHELP, 12, 228, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP -} LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN @@ -427,7 +395,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE File_Flags_Dialog DIALOG 6, 15, 207, 227 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Opções do Abrir/Gravar ficheiro" +CAPTION "Opções do Abrir/Gravar ficheiro" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 @@ -461,8 +429,8 @@ CAPTION "Sobre" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 72, 96, 50, 14 - LTEXT "Common Dialog Test Jig Exerciser, versão 1.20", -1, 13, 36, 168, 12 - LTEXT "(c) 1999-2000, Eric Williams. Direitos garantidos pelo licença do WINE. Don't hoard code... share it", -1, 18, 60, 157, 24 + LTEXT "Common Dialog Test Jig Exerciser, versão 1.20", -1, 13, 36, 168, 12 + LTEXT "(c) 1999-2000, Eric Williams. Direitos garantidos pelo licença do WINE. Don't hoard code... share it", -1, 18, 60, 157, 24 ICON "AboutIcon", -1, 84, 12, 18, 20 } @@ -474,8 +442,8 @@ CAPTION "Acerca" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 72, 96, 50, 14 - LTEXT "Common Dialog Test Jig Exerciser, versão 1.20", -1, 13, 36, 168, 12 - LTEXT "(c) 1999-2000, Eric Williams. Direitos garantidos pela licença WINE. Não guarde o código... partilhe-o", -1, 18, 60, 157, 24 + LTEXT "Common Dialog Test Jig Exerciser, versão 1.20", -1, 13, 36, 168, 12 + LTEXT "(c) 1999-2000, Eric Williams. Direitos garantidos pela licença WINE. Não guarde o código... partilhe-o", -1, 18, 60, 157, 24 ICON "AboutIcon", -1, 84, 12, 18, 20 } @@ -488,13 +456,13 @@ CAPTION "Uso" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 70, 276, 50, 14 - LTEXT "Common Dialog Test Jig Exerciser, versão 1.20", -1, 13, 48, 168, 12 + LTEXT "Common Dialog Test Jig Exerciser, versão 1.20", -1, 13, 48, 168, 12 LTEXT "Esta ferramenta testa COMMDLG para o Wine.", -1, 12, 72, 168, 12 - LTEXT "Flags são especificados no menu Flags.", -1, 12, 96, 168, 12 - LTEXT "Diálogo de cores muda a cor de fundo.", -1, 12, 120, 168, 12 - LTEXT "Diálogo de fontes muda todas as fontes, cores das fontes se CF_EFFECTS está selecionado.", -1, 12, 144, 168, 24 - LTEXT "O canto superior esquerdo indica o caminho completo e o título dos último sucesso de Abrir ou Salvar.", -1, 12, 180, 168, 24 - LTEXT "(c) 1999-2000, Eric Williams. Direitos garantidos pelo licença do WINE. Don't hoard code... share it", -1, 18, 60, 157, 24 + LTEXT "Flags são especificados no menu Flags.", -1, 12, 96, 168, 12 + LTEXT "Diálogo de cores muda a cor de fundo.", -1, 12, 120, 168, 12 + LTEXT "Diálogo de fontes muda todas as fontes, cores das fontes se CF_EFFECTS está selecionado.", -1, 12, 144, 168, 24 + LTEXT "O canto superior esquerdo indica o caminho completo e o título dos último sucesso de Abrir ou Salvar.", -1, 12, 180, 168, 24 + LTEXT "(c) 1999-2000, Eric Williams. Direitos garantidos pelo licença do WINE. Don't hoard code... share it", -1, 18, 60, 157, 24 ICON "AboutIcon", -1, 86, 12, 18, 20 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 216, 168, 2 } @@ -507,44 +475,13 @@ CAPTION "Uso" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 70, 276, 50, 14 - LTEXT "Exercício Jig de Teste de Diálogo Comum, versão 1.20", -1, 13, 48, 168, 12 + LTEXT "Exercício Jig de Teste de Diálogo Comum, versão 1.20", -1, 13, 48, 168, 12 LTEXT "Esta ferramenta testa o COMMDLG para o Wine.", -1, 12, 72, 168, 12 - LTEXT "As flags são indicadas no menu Flags.", -1, 12, 96, 168, 12 - LTEXT "O diálogo de cores muda a cor de fundo.", -1, 12, 120, 168, 12 - LTEXT "O diálogo de tipos de letra muda todas as letras, cores das letras se CF_EFFECTS estiver seleccionado.", -1, 12, 144, 168, 24 - LTEXT "O canto superior esquerdo indica a localização completo e o título dos últimos sucessos de Abrir ou Gravar", -1, 12, 180, 168, 24 - LTEXT "(c) 1999-2000, Eric Williams. Direitos garantidos pela licença WINE. Não guarde o código... partilhe-o", -1, 18, 60, 157, 24 + LTEXT "As flags são indicadas no menu Flags.", -1, 12, 96, 168, 12 + LTEXT "O diálogo de cores muda a cor de fundo.", -1, 12, 120, 168, 12 + LTEXT "O diálogo de tipos de letra muda todas as letras, cores das letras se CF_EFFECTS estiver seleccionado.", -1, 12, 144, 168, 24 + LTEXT "O canto superior esquerdo indica a localização completo e o título dos últimos sucessos de Abrir ou Gravar", -1, 12, 180, 168, 24 + LTEXT "(c) 1999-2000, Eric Williams. Direitos garantidos pela licença WINE. Não guarde o código... partilhe-o", -1, 18, 60, 157, 24 ICON "AboutIcon", -1, 86, 12, 18, 20 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 216, 168, 2 } - -PAGESETUPDLGORD_CSTM DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 240, 240 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "diálogo de teste TFT" -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "", rct1, "Static", SS_WHITERECT, 80, 8, 80, 80 - CONTROL "", rct2, "Static", SS_GRAYRECT, 160, 12, 4, 80 - CONTROL "", rct3, "Static", SS_GRAYRECT, 84, 88, 80, 4 - GROUPBOX "Papel", grp2, 8, 96, 224, 56, BS_GROUPBOX - LTEXT "&Tamanho:", stc2, 16, 112, 36, 8 - COMBOBOX cmb2, 64, 110, 80, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - COMBOBOX cmb1, 150, 110, 80, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - LTEXT "&Bandeja:", stc3, 16, 132, 36, 8 - COMBOBOX cmb3, 64, 130, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - GROUPBOX "Orientação", grp1, 8, 156, 64, 56, BS_GROUPBOX - AUTORADIOBUTTON "&Retrato", rad1, 16, 170, 52, 12, BS_AUTORADIOBUTTON - AUTORADIOBUTTON "&Paisagem", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON - GROUPBOX "Margens", grp4, 80, 156, 152, 56, BS_GROUPBOX - LTEXT "&Esquerda:", stc15, 88, 172, 21, 8 - EDITTEXT edt4, 111, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "&Direita:", stc16, 159, 172, 27, 8 - EDITTEXT edt6, 187, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "&Cima:", stc17, 88, 192, 21, 8 - EDITTEXT edt5, 111, 190, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - LTEXT "&Baixo:", stc18, 159, 192, 23, 8 - EDITTEXT edt7, 187, 190, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER - DEFPUSHBUTTON "OK", IDOK, 71, 220, 50, 14, BS_PUSHBUTTON - PUSHBUTTON "Cancelar", IDCANCEL, 126, 220, 50, 14 - PUSHBUTTON "&Impressora...", psh3, 184, 220, 48, 14 -END diff --git a/programs/cmdlgtst/Ru.rc b/programs/cmdlgtst/Ru.rc index b80661a0c66..a438b24c0d5 100644 --- a/programs/cmdlgtst/Ru.rc +++ b/programs/cmdlgtst/Ru.rc @@ -18,64 +18,59 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT CmdlgtstMenu MENU { - POPUP "&Файл" + POPUP "&Ôàéë" { - MENUITEM "В&ыход", CM_U_EXIT + MENUITEM "Â&ûõîä", CM_U_EXIT } - POPUP "&Диалоги сommdlg" + POPUP "&Äèàëîãè ñommdlg" { - MENUITEM "&Открыть", CM_U_OPEN - MENUITEM "&Сохранить", CM_U_SAVE + MENUITEM "&Îòêðûòü", CM_U_OPEN + MENUITEM "&Ñîõðàíèòü", CM_U_SAVE MENUITEM SEPARATOR - MENUITEM "&Цвет", CM_U_COLOR - MENUITEM "&Шрифт", CM_U_FONT + MENUITEM "&Öâåò", CM_U_COLOR + MENUITEM "&Øðèôò", CM_U_FONT MENUITEM SEPARATOR - MENUITEM "Найти &текст", CM_U_FIND - MENUITEM "&Заменить текст", CM_U_REPLACE + MENUITEM "Íàéòè &òåêñò", CM_U_FIND + MENUITEM "&Çàìåíèòü òåêñò", CM_U_REPLACE MENUITEM SEPARATOR - MENUITEM "&Печатать", CM_U_PRINT - MENUITEM "Параметры &страницы", CM_U_PAGESETUP + MENUITEM "&Ïå÷àòàòü", CM_U_PRINT + MENUITEM "Ïàðàìåòðû &ñòðàíèöû", CM_U_PAGESETUP } - POPUP "Ф&лаги диалогов" + POPUP "Ô&ëàãè äèàëîãîâ" { - MENUITEM "&Файл", CM_F_FILE + MENUITEM "&Ôàéë", CM_F_FILE MENUITEM SEPARATOR - MENUITEM "&Цвет", CM_F_COLOR - MENUITEM "&Шрифт", CM_F_FONT + MENUITEM "&Öâåò", CM_F_COLOR + MENUITEM "&Øðèôò", CM_F_FONT MENUITEM SEPARATOR - MENUITEM "&Найти/заменить", CM_F_FINDREPLACE + MENUITEM "&Íàéòè/çàìåíèòü", CM_F_FINDREPLACE MENUITEM SEPARATOR - MENUITEM "&Печатать", CM_F_PRINT - MENUITEM "Параметры &страницы", CM_F_PAGESETUP + MENUITEM "&Ïå÷àòàòü", CM_F_PRINT + MENUITEM "Ïàðàìåòðû &ñòðàíèöû", CM_F_PAGESETUP } - POPUP "&Справка" + POPUP "&Ñïðàâêà" { - MENUITEM "&Использование", CM_H_USAGE - MENUITEM "&О программе", CM_H_ABOUT + MENUITEM "&Èñïîëüçîâàíèå", CM_H_USAGE + MENUITEM "&Î ïðîãðàììå", CM_H_ABOUT } } Color_Flags_Dialog DIALOG 11, 20, 207, 107 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Флаги диалога выбора цвета" +CAPTION "Ôëàãè äèàëîãà âûáîðà öâåòà" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Отмена", IDCANCEL, 148, 24, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON "Справка", CM_R_HELP, 148, 42, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Îòìåíà", IDCANCEL, 148, 24, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Ñïðàâêà", CM_R_HELP, 148, 42, 50, 14, WS_GROUP | WS_TABSTOP CHECKBOX "CC_ENABLEHOOK", I_CC_ENABLEHOOK, 12, 12, 122, 10, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "CC_ENABLETEMPLATE", I_CC_ENABLETEMPLATE, 12, 24, 122, 10, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "CC_ENABLETEMPLATEHANDLE", I_CC_ENABLETEMPLATEHANDLE, 12, 36, 122, 10, BS_AUTOCHECKBOX | WS_TABSTOP @@ -87,12 +82,12 @@ FONT 8, "MS Shell Dlg" Font_Flags_Dialog DIALOG 9, 20, 207, 313 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Флаги диалога выбора шрифта" +CAPTION "Ôëàãè äèàëîãà âûáîðà øðèôòà" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 - PUSHBUTTON "Отмена", IDCANCEL, 148, 24, 50, 14 - PUSHBUTTON "Справка", CM_R_HELP, 148, 42, 50, 14 + PUSHBUTTON "Îòìåíà", IDCANCEL, 148, 24, 50, 14 + PUSHBUTTON "Ñïðàâêà", CM_R_HELP, 148, 42, 50, 14 CHECKBOX "CF_APPLY", I_CF_APPLY, 12, 12, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "CF_ANSIONLY", I_CF_ANSIONLY, 12, 24, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "CF_BOTH", I_CF_BOTH, 12, 36, 120, 10, BS_AUTOCHECKBOX | WS_TABSTOP @@ -121,12 +116,12 @@ FONT 8, "MS Shell Dlg" Find_Flags_Dialog DIALOG 8, 24, 207, 306 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION -CAPTION "Флаги диалогов найти/заменить" +CAPTION "Ôëàãè äèàëîãîâ íàéòè/çàìåíèòü" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 - PUSHBUTTON "Отмена", IDCANCEL, 148, 24, 50, 14 - PUSHBUTTON "Справка", IDHELP, 148, 42, 50, 14 + PUSHBUTTON "Îòìåíà", IDCANCEL, 148, 24, 50, 14 + PUSHBUTTON "Ñïðàâêà", IDHELP, 148, 42, 50, 14 CHECKBOX "FR_DIALOGTERM", I_FR_DIALOGTERM, 24, 12, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "FR_DOWN", I_FR_DOWN, 24, 24, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "FR_ENABLEHOOK", I_FR_ENABLEHOOK, 24, 36, 120, 12, BS_AUTOCHECKBOX | WS_TABSTOP @@ -149,17 +144,17 @@ FONT 8, "MS Shell Dlg" CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 168, 11, 13 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 180, 11, 13 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 24, 228, 11, 13 - CONTROL "Так отмечены флаги, которые установлены системой и обязаны быть сброшены пользователем.", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 48, 228, 98, 36 + CONTROL "Òàê îòìå÷åíû ôëàãè, êîòîðûå óñòàíîâëåíû ñèñòåìîé è îáÿçàíû áûòü ñáðîøåíû ïîëüçîâàòåëåì.", -1, "static", SS_LEFT | WS_CHILD | WS_VISIBLE, 48, 228, 98, 36 } Print_Flags_Dialog DIALOG 4, 17, 239, 287 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Флаги диалогов печать/настройка печати" +CAPTION "Ôëàãè äèàëîãîâ ïå÷àòü/íàñòðîéêà ïå÷àòè" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 180, 6, 50, 14 - PUSHBUTTON "Отмена", IDCANCEL, 180, 24, 50, 14 - PUSHBUTTON "Справка", CM_R_HELP, 180, 42, 50, 14 + PUSHBUTTON "Îòìåíà", IDCANCEL, 180, 24, 50, 14 + PUSHBUTTON "Ñïðàâêà", CM_R_HELP, 180, 42, 50, 14 CHECKBOX "PD_ALLPAGES", I_PD_ALLPAGES, 12, 12, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "PD_COLLATE", I_PD_COLLATE, 12, 24, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "PD_DISABLEPRINTTOFILE", I_PD_DISABLEPRINTTOFILE, 12, 36, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP @@ -190,7 +185,7 @@ CAPTION " " FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 180, 6, 50, 14 - PUSHBUTTON "Отмена", IDCANCEL, 180, 24, 50, 14 + PUSHBUTTON "Îòìåíà", IDCANCEL, 180, 24, 50, 14 CHECKBOX "PSD_DEFAULTMINMARGINS", I_PSD_DEFAULTMINMARGINS, 12, 12, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "PSD_DISABLEMARGINS", I_PSD_DISABLEMARGINS, 12, 24, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "PSD_DISABLEORIENTATION", I_PSD_DISABLEORIENTATION, 12, 36, 144, 12, BS_AUTOCHECKBOX | WS_TABSTOP @@ -214,12 +209,12 @@ FONT 8, "MS Shell Dlg" File_Flags_Dialog DIALOG 6, 15, 207, 227 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Флаги диалогов открыть/сохранить файл" +CAPTION "Ôëàãè äèàëîãîâ îòêðûòü/ñîõðàíèòü ôàéë" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 148, 6, 50, 14 - PUSHBUTTON "Отмена", IDCANCEL, 148, 24, 50, 14 - PUSHBUTTON "Справка", CM_R_HELP, 148, 42, 50, 14 + PUSHBUTTON "Îòìåíà", IDCANCEL, 148, 24, 50, 14 + PUSHBUTTON "Ñïðàâêà", CM_R_HELP, 148, 42, 50, 14 CHECKBOX "OFN_ALLOWMULTISELECT", I_OFN_ALLOWMULTISELECT, 12, 12, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "OFN_CREATEPROMPT", I_OFN_CREATEPROMPT, 12, 24, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP CHECKBOX "OFN_ENABLEHOOK", I_OFN_ENABLEHOOK, 12, 36, 132, 12, BS_AUTOCHECKBOX | WS_TABSTOP @@ -241,59 +236,59 @@ FONT 8, "MS Shell Dlg" AboutDialog DIALOG 6, 15, 194, 119 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "О программе" +CAPTION "Î ïðîãðàììå" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 72, 96, 50, 14 LTEXT "Common Dialog Test Jig Exerciser, version 1.20", -1, 13, 36, 168, 12 - LTEXT "(c) 1999-2000, Eric Williams. Распространяется по лицензии WINE. Не складируйте код...распространяйте его!", -1, 18, 60, 157, 24 + LTEXT "(c) 1999-2000, Eric Williams. Ðàñïðîñòðàíÿåòñÿ ïî ëèöåíçèè WINE. Íå ñêëàäèðóéòå êîä...ðàñïðîñòðàíÿéòå åãî!", -1, 18, 60, 157, 24 ICON "AboutIcon", -1, 84, 12, 18, 20 } UsageDialog DIALOG 183, 22, 190, 300 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Использование" +CAPTION "Èñïîëüçîâàíèå" FONT 8, "MS Shell Dlg" { DEFPUSHBUTTON "OK", IDOK, 70, 276, 50, 14 LTEXT "Common Dialog Test Jig Exerciser, version 1.20", -1, 13, 48, 168, 12 - LTEXT "Эта утила тестирует COMMDLG для Wine.", -1, 12, 72, 168, 12 - LTEXT "Флаги задаются в меню 'Флаги диалогов'.", -1, 12, 96, 168, 12 - LTEXT "Диалог выбора цвета меняет цвет фона.", -1, 12, 120, 168, 12 - LTEXT "Диалог выбора шрифта меняет все шрифты и цвета шрифтов, если флаг CF_EFFECTS установлен.", -1, 12, 144, 168, 24 - LTEXT "Верхний левый угол рабочей области приложения показывает полное имя файла и заголовок последнего успешного завершения диалогов открытия или сохранения файла.", -1, 12, 180, 168, 24 - LTEXT "(c) 1999-2000, Eric Williams. Распространяется по лицензии WINE. Не складируйте код...распространяйте его!", -1, 12, 228, 168, 36 + LTEXT "Ýòà óòèëà òåñòèðóåò COMMDLG äëÿ Wine.", -1, 12, 72, 168, 12 + LTEXT "Ôëàãè çàäàþòñÿ â ìåíþ 'Ôëàãè äèàëîãîâ'.", -1, 12, 96, 168, 12 + LTEXT "Äèàëîã âûáîðà öâåòà ìåíÿåò öâåò ôîíà.", -1, 12, 120, 168, 12 + LTEXT "Äèàëîã âûáîðà øðèôòà ìåíÿåò âñå øðèôòû è öâåòà øðèôòîâ, åñëè ôëàã CF_EFFECTS óñòàíîâëåí.", -1, 12, 144, 168, 24 + LTEXT "Âåðõíèé ëåâûé óãîë ðàáî÷åé îáëàñòè ïðèëîæåíèÿ ïîêàçûâàåò ïîëíîå èìÿ ôàéëà è çàãîëîâîê ïîñëåäíåãî óñïåøíîãî çàâåðøåíèÿ äèàëîãîâ îòêðûòèÿ èëè ñîõðàíåíèÿ ôàéëà.", -1, 12, 180, 168, 24 + LTEXT "(c) 1999-2000, Eric Williams. Ðàñïðîñòðàíÿåòñÿ ïî ëèöåíçèè WINE. Íå ñêëàäèðóéòå êîä...ðàñïðîñòðàíÿéòå åãî!", -1, 12, 228, 168, 36 ICON "AboutIcon", -1, 86, 12, 18, 20 CONTROL "", -1, "static", SS_BLACKRECT | WS_CHILD | WS_VISIBLE, 12, 216, 168, 2 } PAGESETUPDLGORD_CSTM DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 240, 240 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Собственный диалог" +CAPTION "óÏÂÓÔ×ÅÎÎÙÊ ÄÉÁÌÏÇ" FONT 8, "MS Shell Dlg" BEGIN CONTROL "", rct1, "Static", SS_WHITERECT, 80, 8, 80, 80 CONTROL "", rct2, "Static", SS_GRAYRECT, 160, 12, 4, 80 CONTROL "", rct3, "Static", SS_GRAYRECT, 84, 88, 80, 4 - GROUPBOX "Бумага и принтер", grp2, 8, 96, 224, 56, BS_GROUPBOX - LTEXT "&Бумага:", stc2, 16, 112, 36, 8 + GROUPBOX "Áóìàãà è ïðèíòåð", grp2, 8, 96, 224, 56, BS_GROUPBOX + LTEXT "&Áóìàãà:", stc2, 16, 112, 36, 8 COMBOBOX cmb2, 64, 110, 80, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL COMBOBOX cmb1, 150, 110, 80, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL - LTEXT "Подача:", stc3, 16, 132, 36, 8 + LTEXT "Ïîäà÷à:", stc3, 16, 132, 36, 8 COMBOBOX cmb3, 64, 130, 160, 160, CBS_SIMPLE|CBS_DROPDOWN|CBS_SORT|WS_GROUP|WS_TABSTOP|WS_VSCROLL -GROUPBOX "Ориентация", grp1, 8, 156, 64, 56, BS_GROUPBOX -AUTORADIOBUTTON "К&нижная", rad1, 16, 170, 52, 12, BS_AUTORADIOBUTTON -AUTORADIOBUTTON "Аль&бомная", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON -GROUPBOX "Поля", grp4, 80, 156, 152, 56, BS_GROUPBOX -LTEXT "&Слева:", stc15, 88, 172, 21, 8 +GROUPBOX "Îðèåíòàöèÿ", grp1, 8, 156, 64, 56, BS_GROUPBOX +AUTORADIOBUTTON "Ê&íèæíàÿ", rad1, 16, 170, 52, 12, BS_AUTORADIOBUTTON +AUTORADIOBUTTON "Àëü&áîìíàÿ", rad2, 16, 190, 52, 12, BS_AUTORADIOBUTTON +GROUPBOX "Ïîëÿ", grp4, 80, 156, 152, 56, BS_GROUPBOX +LTEXT "&Ñëåâà:", stc15, 88, 172, 21, 8 EDITTEXT edt4, 111, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER -LTEXT "Све&рху:", stc16, 159, 172, 27, 8 +LTEXT "Ñâå&ðõó:", stc16, 159, 172, 27, 8 EDITTEXT edt6, 187, 170, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER -LTEXT "С&права:", stc17, 88, 192, 21, 8 +LTEXT "Ñ&ïðàâà:", stc17, 88, 192, 21, 8 EDITTEXT edt5, 111, 190, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER -LTEXT "Сни&зу:", stc18, 159, 192, 23, 8 +LTEXT "Ñíè&çó:", stc18, 159, 192, 23, 8 EDITTEXT edt7, 187, 190, 39, 12, WS_TABSTOP|WS_GROUP|WS_BORDER DEFPUSHBUTTON "OK", IDOK, 71, 220, 50, 14, BS_PUSHBUTTON -PUSHBUTTON "Отмена", IDCANCEL, 126, 220, 50, 14 -PUSHBUTTON "&Принтер...", psh3, 184, 220, 48, 14 +PUSHBUTTON "Îòìåíà", IDCANCEL, 126, 220, 50, 14 +PUSHBUTTON "&Ïðèíòåð...", psh3, 184, 220, 48, 14 END diff --git a/programs/cmdlgtst/Si.rc b/programs/cmdlgtst/Si.rc index f7c02f3740a..e080da30752 100644 --- a/programs/cmdlgtst/Si.rc +++ b/programs/cmdlgtst/Si.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -297,3 +295,5 @@ BEGIN PUSHBUTTON "Prekliči", IDCANCEL, 126, 220, 50, 14 PUSHBUTTON "&Tiskalnik ...", psh3, 184, 220, 48, 14 END + +#pragma code_page(default) diff --git a/programs/cmdlgtst/Sv.rc b/programs/cmdlgtst/Sv.rc index c5c42dd8384..3ec66f2fa8d 100644 --- a/programs/cmdlgtst/Sv.rc +++ b/programs/cmdlgtst/Sv.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL CmdlgtstMenu MENU diff --git a/programs/cmdlgtst/Tr.rc b/programs/cmdlgtst/Tr.rc index c892470c8c8..94b6d50fe9e 100644 --- a/programs/cmdlgtst/Tr.rc +++ b/programs/cmdlgtst/Tr.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "cmdlgtst.h" - /* FIXME: to be completed */ LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT diff --git a/programs/cmdlgtst/cmdlgr.rc b/programs/cmdlgtst/cmdlgr.rc index bbeabf7364b..598eab82164 100644 --- a/programs/cmdlgtst/cmdlgr.rc +++ b/programs/cmdlgtst/cmdlgr.rc @@ -18,7 +18,31 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include +#include +#include + #include "cmdlgtst.h" +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Es.rc" +#include "Fr.rc" +#include "It.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" + +LANGUAGE LANG_NEUTRAL,SUBLANG_NEUTRAL + /* @makedep: about.ico */ AboutIcon ICON about.ico diff --git a/programs/cmdlgtst/cmdlgtst.h b/programs/cmdlgtst/cmdlgtst.h index 58b2992e193..b096eb9ea48 100644 --- a/programs/cmdlgtst/cmdlgtst.h +++ b/programs/cmdlgtst/cmdlgtst.h @@ -16,10 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include -#include - #define CM_U_COLOR 105 #define CM_U_SAVE 104 #define CM_U_OPEN 107 diff --git a/programs/control/cpl_list b/programs/control/cpl_list new file mode 100644 index 00000000000..bdd7231a6dd --- /dev/null +++ b/programs/control/cpl_list @@ -0,0 +1,95 @@ + +Alphabetical List of Windows 95 Control Panels +---------------------------------------------- + +Filename Description + +APPWIZ.CPL Software Properties + ,NewLinkHere %1 - Create new .lnk link "%1" +DESK.CPL Desktop Properties + ,,0 - Background Properties + ,,1 - Screen Saver Properties + ,,2 - Color Properties +INETCPL.CPL Internet Properties + ,SiteCERT_RunFromCmdLine %1 - View site certificate "%1" +INTL.CPL Internation Country/Timezone Properties + ,,0 - Country-specific settings + ,,1 - Numbers + ,,2 - Currency + ,,3 - Clock + ,,4 - Date +JOY.CPL Joystick Properties +MAIN.CPL @0 - Mouse Buttons Properties + @1 - Keyboard Speed Properties + @1,1 - Keyboard Language Properties + @1,2 - Keyboard General Properties + @2 - Printer + @3 - Fonts + @4 - Energy +MMSYS.CPL Multimedia Properties + ,,0 - Audio + ,,1 - Video + ,,2 - MIDI + ,,3 - Audio CD + ,,4 - Extended (Multimedia drivers) +MODEM.CPL Modem Properties (does not take parameters) +MSWEBCPL.CPL Personal WebServer Properties (comes with Win95 4.0B) + (does not take parameters) +NETCPL.CPL Network (does not take parameters) +ODBCCP32.CPL 32bit-ODBC Properties +PASSWORD.CPL Password Properties (does not take parameters) +SYSDM.CPL System Properties + ,,0 - Generic + ,,1 - Device Manager + ,,2 - Hardware Profiles + ,,3 - Advanced Features +TELEPHON.CPL Telephone Properties (renamed to TELEPHON.CP$ if not installed) + (does not take parameters) +TIMEDATE.CPL Time/Date Properties + ,,0 - Date and Time + ,,1 - Timezone + ,,m - summer/wintertime notification + (issued by kernel32.dll on windows startup) + + + +Alphabetical List of alien CPLs / rundll commands +------------------------------------------------- + + command: amovie.ocx,RunDll [/play] [/close] %1 +description: open document %1 in ActiveMovie Viewer + /play: auto-play document + /close: close viewer after playing + + command: deskcp16.dll,QUICKRES_RUNDLLENTRY +description: show SVGA display manager in task bar + + command: mailnews.dll,EMLFileHandler %1 +description: ? + + command: mailnews.dll,Mail_RunDLL %1 +description: ? + + command: mailnews.dll,News_RunDLL %1 +description: ? + + command: rnaui.dll,RnaRunImport %1 +description: ? + + command: shscrap.dll,OpenScrap_RunDLL /r /x %1 +description: ? + + command: shell32.dll,Control_RunDLL %1,%* +description: open control panel file "%1" with parameters "%*" + (control.exe is a user front end for this call) + + command: shell32.dll,SHHelpShortcuts_RunDLL PrintersFolder +description: show "Printers" Explorer Window + + command: url.dll,FileProtocolHandler %1 +description: tell system to handle file protocol "%1" + + command: url.dll,OpenURL %1 +description: launch default web browser, open "%1" site. + +(add your alien commands here) diff --git a/programs/msiexec/rsrc.rc b/programs/msiexec/rsrc.rc index cfc89370039..01e43befe19 100644 --- a/programs/msiexec/rsrc.rc +++ b/programs/msiexec/rsrc.rc @@ -18,16 +18,7 @@ #include -#define WINE_FILEDESCRIPTION_STR "Wine Installer" -#define WINE_FILENAME_STR "msiexec.exe" -#define WINE_FILETYPE VFT_APP -#define WINE_FILEVERSION 3,1,4000,1823 -#define WINE_FILEVERSION_STR "3.1.4000.1823" -#define WINE_PRODUCTVERSION 3,1,4000,1823 -#define WINE_PRODUCTVERSION_STR "3.1.4000.1823" -#define WINE_PRODUCTNAME_STR "Wine Installer" - -#include "wine/wine_common_ver.rc" +#include "version.rc" LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL diff --git a/programs/msiexec/version.rc b/programs/msiexec/version.rc new file mode 100644 index 00000000000..077759431e2 --- /dev/null +++ b/programs/msiexec/version.rc @@ -0,0 +1,28 @@ +/* + * Copyright (c) 2004 Mike McCormack + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#define WINE_FILEDESCRIPTION_STR "Wine Installer" +#define WINE_FILENAME_STR "msiexec.exe" +#define WINE_FILETYPE VFT_APP +#define WINE_FILEVERSION 3,1,4000,1823 +#define WINE_FILEVERSION_STR "3.1.4000.1823" +#define WINE_PRODUCTVERSION 3,1,4000,1823 +#define WINE_PRODUCTVERSION_STR "3.1.4000.1823" +#define WINE_PRODUCTNAME_STR "Wine Installer" + +#include "wine/wine_common_ver.rc" diff --git a/programs/net/Da.rc b/programs/net/Da.rc index 3be4723a9b0..02694fd2a0d 100644 --- a/programs/net/Da.rc +++ b/programs/net/Da.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/net/De.rc b/programs/net/De.rc index 0e2b0f3537a..78f87ecafe6 100644 --- a/programs/net/De.rc +++ b/programs/net/De.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - #pragma code_page(65001) LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL @@ -46,3 +44,5 @@ STRINGTABLE STRING_USE_HEADER, "\nStatus Lokal Entfernt\n---------------------------------------------------------------\n" STRING_USE_ENTRY, "%s %S %S Offene Ressourcen: %lu\n" } + +#pragma code_page(default) diff --git a/programs/net/En.rc b/programs/net/En.rc index 49233a4d9ee..54da5ed188b 100644 --- a/programs/net/En.rc +++ b/programs/net/En.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/net/Fr.rc b/programs/net/Fr.rc index 49e6be49298..38906498235 100644 --- a/programs/net/Fr.rc +++ b/programs/net/Fr.rc @@ -18,9 +18,6 @@ * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ - -#include "resources.h" - #pragma code_page(65001) LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL @@ -45,3 +42,5 @@ STRINGTABLE STRING_USE_HEADER, "\nStatut Local Distant\n---------------------------------------------------------------\n" STRING_USE_ENTRY, "%s %S %S Ressources ouvertes : %lu\n" } + +#pragma code_page(default) diff --git a/programs/net/Ko.rc b/programs/net/Ko.rc index 713edf81c94..44775d3e4f6 100644 --- a/programs/net/Ko.rc +++ b/programs/net/Ko.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/net/Lt.rc b/programs/net/Lt.rc deleted file mode 100644 index 7db57624d5c..00000000000 --- a/programs/net/Lt.rc +++ /dev/null @@ -1,49 +0,0 @@ -/* - * NET.EXE - Wine-compatible net program - * Lithuanian language support - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resources.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE -{ - STRING_USAGE, "Šios komandos sintaksė yra:\n\nNET [ HELP | START | STOP | USE ]\n" - STRING_START_USAGE, "Nurodykite paleidžiamos tarnybos vardą.\n" - STRING_STOP_USAGE, "Nurodykite stabdomos tarnybos vardą.\n" - STRING_STOP_DEP, "Stabdoma priklausoma tarnyba: %s\n" - STRING_CANT_STOP, "Nepavyko sustabdyti tarnybos %s\n" - STRING_NO_SCM, "Nepavyko gauti tarnybos valdymo tvarkytuvės rodyklės.\n" - STRING_NO_SVCHANDLE, "Nepavyko gauti tarnybos rodyklės.\n" - STRING_START_SVC, "Tarnyba %s yra paleidžiama.\n" - STRING_START_SVC_SUCCESS, "Tarnyba %s sėkmingai paleista.\n" - STRING_START_SVC_FAIL, "Tarnyba %s nepasileido.\n" - STRING_STOP_SVC, "Tarnyba %s yra stabdoma.\n" - STRING_STOP_SVC_SUCCESS, "Tarnyba %s sėkmingai sustabdyta.\n" - STRING_STOP_SVC_FAIL, "Tarnyba %s nesustojo.\n" - STRING_HELP_USAGE, "Šios komandos sintaksė yra:\n\nNET HELP komanda\n -arba-\nNET komanda /HELP\n\n"\ - " Galimos komandos yra:\n NET HELP NET START NET STOP NET USE\n" - STRING_NO_ENTRIES, "Sąraše nėra elementų.\n" - STRING_USE_HEADER, "\nBūsena Vietinė Nutolusi\n---------------------------------------------------------------\n" - STRING_USE_ENTRY, "%s %S %S Atverti ištekliai: %lu\n" -} diff --git a/programs/net/Makefile.in b/programs/net/Makefile.in index 4f6f6fc7350..8ababf7f9a8 100644 --- a/programs/net/Makefile.in +++ b/programs/net/Makefile.in @@ -8,19 +8,7 @@ IMPORTS = netapi32 user32 advapi32 kernel32 C_SRCS = net.c -RC_SRCS = \ - Da.rc \ - De.rc \ - En.rc \ - Fr.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Si.rc +RC_SRCS = rsrc.rc @MAKE_PROG_RULES@ diff --git a/programs/net/Nl.rc b/programs/net/Nl.rc index 5f7e12bb09e..93fa8347587 100644 --- a/programs/net/Nl.rc +++ b/programs/net/Nl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE diff --git a/programs/net/No.rc b/programs/net/No.rc index 7cd0b572eed..bc0ad333ac5 100644 --- a/programs/net/No.rc +++ b/programs/net/No.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE diff --git a/programs/net/Pl.rc b/programs/net/Pl.rc index a60a5febc56..c5ef8a38c4f 100644 --- a/programs/net/Pl.rc +++ b/programs/net/Pl.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/net/Pt.rc b/programs/net/Pt.rc index 0229cb9527c..0efa8c2727b 100644 --- a/programs/net/Pt.rc +++ b/programs/net/Pt.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE diff --git a/programs/net/Ru.rc b/programs/net/Ru.rc dissimilarity index 64% index bf4cd65a0b9..33da048e0b3 100644 --- a/programs/net/Ru.rc +++ b/programs/net/Ru.rc @@ -1,49 +1,44 @@ -/* - * NET.EXE - Wine-compatible net program - * Russian language support - * - * Copyright (C) 2007 Konstantin Kondratyuk (Etersoft) - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resources.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT - -STRINGTABLE -{ - STRING_USAGE, "Использование:\n\nNET [ HELP | START | STOP | USE ]\n" - STRING_START_USAGE, "Укажите запускаемую службу.\n" - STRING_STOP_USAGE, "Укажите останавливаемую службу.\n" - STRING_STOP_DEP, "Остановка зависимой службы: %s\n" - STRING_CANT_STOP, "Невозможно остановить службу %s\n" - STRING_NO_SCM, "Невозможно получить доступ к диспетчеру служб.\n" - STRING_NO_SVCHANDLE, "Невозможно получить доступ к службе.\n" - STRING_START_SVC, "Запуск службы %s.\n" - STRING_START_SVC_SUCCESS, "Служба %s успешно запущена.\n" - STRING_START_SVC_FAIL, "Ошибка при запуске службы %s.\n" - STRING_STOP_SVC, "Остановка службы %s.\n" - STRING_STOP_SVC_SUCCESS, "Служба %s успешно остановлена.\n" - STRING_STOP_SVC_FAIL, "Ошибка при остановке службы %s.\n" - STRING_HELP_USAGE, "Использование:\n\nNET HELP команда\n -или-\nNET команда /HELP\n\n"\ - " Доступные команды:\n NET HELP NET START NET STOP NET USE\n" - STRING_NO_ENTRIES, "Список пуст.\n" - STRING_USE_HEADER, "\nСтатус Локальный Удалённый\n---------------------------------------------------------------\n" - STRING_USE_ENTRY, "%s %S %S Открытых ресурсов: %lu\n" -} +/* + * NET.EXE - Wine-compatible net program + * Russian language support + * + * Copyright (C) 2007 Konstantin Kondratyuk (Etersoft) + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT + +STRINGTABLE +{ + STRING_USAGE, "Èñïîëüçîâàíèå:\n\nNET [ HELP | START | STOP | USE ]\n" + STRING_START_USAGE, "Óêàæèòå çàïóñêàåìóþ ñëóæáó.\n" + STRING_STOP_USAGE, "Óêàæèòå îñòàíàâëèâàåìóþ ñëóæáó.\n" + STRING_STOP_DEP, "Îñòàíîâêà çàâèñèìîé ñëóæáû: %s\n" + STRING_CANT_STOP, "Íåâîçìîæíî îñòàíîâèòü ñëóæáó %s\n" + STRING_NO_SCM, "Íåâîçìîæíî ïîëó÷èòü äîñòóï ê äèñïåò÷åðó ñëóæá.\n" + STRING_NO_SVCHANDLE, "Íåâîçìîæíî ïîëó÷èòü äîñòóï ê ñëóæáå.\n" + STRING_START_SVC, "Çàïóñê ñëóæáû %s.\n" + STRING_START_SVC_SUCCESS, "Ñëóæáà %s óñïåøíî çàïóùåíà.\n" + STRING_START_SVC_FAIL, "Îøèáêà ïðè çàïóñêå ñëóæáû %s.\n" + STRING_STOP_SVC, "Îñòàíîâêà ñëóæáû %s.\n" + STRING_STOP_SVC_SUCCESS, "Ñëóæáà %s óñïåøíî îñòàíîâëåíà.\n" + STRING_STOP_SVC_FAIL, "Îøèáêà ïðè îñòàíîâêå ñëóæáû %s.\n" + STRING_HELP_USAGE, "Èñïîëüçîâàíèå:\n\nNET HELP êîìàíäà\n -èëè-\nNET êîìàíäà /HELP\n\n"\ + " Äîñòóïíûå êîìàíäû:\n NET HELP NET START NET STOP NET USE\n" + STRING_NO_ENTRIES, "Ñïèñîê ïóñò.\n" + STRING_USE_HEADER, "\nÑòàòóñ Ëîêàëüíûé Óäàë¸ííûé\n---------------------------------------------------------------\n" + STRING_USE_ENTRY, "%s %S %S Îòêðûòûõ ðåñóðñîâ: %lu\n" +} diff --git a/programs/net/Si.rc b/programs/net/Si.rc index 7a7e0cf0bef..7130967b0d3 100644 --- a/programs/net/Si.rc +++ b/programs/net/Si.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -46,3 +44,5 @@ STRINGTABLE STRING_USE_HEADER, "\nStanje Lokalno Oddaljeno\n---------------------------------------------------------------\n" STRING_USE_ENTRY, "%s %S %S Porabljena sredstva: %lu\n" } + +#pragma code_page(default) diff --git a/programs/net/resources.h b/programs/net/resources.h index 659e47f1ec7..c5199fd932d 100644 --- a/programs/net/resources.h +++ b/programs/net/resources.h @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include - #define STRING_USAGE 101 #define STRING_START_USAGE 102 #define STRING_STOP_USAGE 103 diff --git a/programs/net/rsrc.rc b/programs/net/rsrc.rc new file mode 100644 index 00000000000..231d7d90c22 --- /dev/null +++ b/programs/net/rsrc.rc @@ -0,0 +1,35 @@ +/* + * Copyright 2007 Tim Schwartz + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include + +#include "resources.h" + +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Fr.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" diff --git a/programs/notepad/Bg.rc b/programs/notepad/Bg.rc index 85fb4fc5aa5..2a8dcad2336 100644 --- a/programs/notepad/Bg.rc +++ b/programs/notepad/Bg.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT MAIN_MENU MENU diff --git a/programs/notepad/Cs.rc b/programs/notepad/Cs.rc index 745062df6e5..f2720e5ceae 100644 --- a/programs/notepad/Cs.rc +++ b/programs/notepad/Cs.rc @@ -22,8 +22,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/programs/notepad/Da.rc b/programs/notepad/Da.rc index d152cfeea66..5454ea22f34 100644 --- a/programs/notepad/Da.rc +++ b/programs/notepad/Da.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT MAIN_MENU MENU diff --git a/programs/notepad/De.rc b/programs/notepad/De.rc index a9daa2d57fc..fb315a863fb 100644 --- a/programs/notepad/De.rc +++ b/programs/notepad/De.rc @@ -20,17 +20,13 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL MAIN_MENU MENU { POPUP "&Datei" { MENUITEM "&Neu\tStrg+N", CMD_NEW - MENUITEM "Ö&ffnen...\tStrg+O", CMD_OPEN + MENUITEM "Ö&ffnen...\tStrg+O", CMD_OPEN MENUITEM "&Speichern\tStrg+S", CMD_SAVE MENUITEM "Speichern &unter...", CMD_SAVE_AS MENUITEM SEPARATOR @@ -41,12 +37,12 @@ MAIN_MENU MENU MENUITEM "&Beenden", CMD_EXIT } POPUP "&Bearbeiten" { - MENUITEM "&Rückgängig\tStrg+Z", CMD_UNDO + MENUITEM "&Rückgängig\tStrg+Z", CMD_UNDO MENUITEM SEPARATOR MENUITEM "&Ausschneiden\tStrg+X", CMD_CUT MENUITEM "&Kopieren\tStrg+C", CMD_COPY - MENUITEM "&Einfügen\tStrg+V", CMD_PASTE - MENUITEM "&Löschen\tEntf", CMD_DELETE + MENUITEM "&Einfügen\tStrg+V", CMD_PASTE + MENUITEM "&Löschen\tEntf", CMD_DELETE MENUITEM SEPARATOR MENUITEM "Alles &markieren\tStrg+A", CMD_SELECT_ALL MENUITEM "&Uhrzeit/Datum\tF5", CMD_TIME_DATE @@ -64,7 +60,7 @@ POPUP "&Hilfe" { MENUITEM "&Suchen...", CMD_HELP_SEARCH MENUITEM "&Hilfe benutzen", CMD_HELP_ON_HELP MENUITEM SEPARATOR - MENUITEM "Ü&ber Notepad", CMD_HELP_ABOUT_NOTEPAD + MENUITEM "Ü&ber Notepad", CMD_HELP_ABOUT_NOTEPAD } } @@ -77,10 +73,10 @@ CAPTION "Seite einrichten" { LTEXT "&Kopfzeile:", 0x140, 10, 07, 40, 15 EDITTEXT IDC_PAGESETUP_HEADERVALUE, 60, 05,110, 12, WS_BORDER | WS_TABSTOP -LTEXT "&Fußzeile:", 0x142, 10, 24, 40, 15 +LTEXT "&Fußzeile:", 0x142, 10, 24, 40, 15 EDITTEXT IDC_PAGESETUP_FOOTERVALUE, 60, 22,110, 12, WS_BORDER | WS_TABSTOP -GROUPBOX "Ränder (Millimeter)", 0x144, 10, 43,160, 45 +GROUPBOX "Ränder (Millimeter)", 0x144, 10, 43,160, 45 LTEXT "&Links:", 0x145, 20, 55, 30, 10, WS_CHILD EDITTEXT IDC_PAGESETUP_LEFTVALUE, 50, 55, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP LTEXT "&Oben:", 0x148, 20, 73, 30, 10, WS_CHILD @@ -95,14 +91,6 @@ PUSHBUTTON "Abbrechen", IDCANCEL, 180, 21, 40, 15, WS_TABST PUSHBUTTON "&Hilfe", IDHELP, 180, 39, 40, 15, WS_TABSTOP } -IDD_OFN_TEMPLATE DIALOG DISCARDABLE 50,50,300,15 -STYLE DS_3DLOOK | DS_CONTROL | WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | WS_BORDER -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Kodierung:", -1, 5,0, 50,12 - COMBOBOX IDC_OFN_ENCCOMBO, 53,0, 156,48, WS_CHILD | WS_VSCROLL | CBS_DROPDOWNLIST -END - STRINGTABLE DISCARDABLE { STRING_PAGESETUP_HEADERVALUE, "&f" @@ -118,27 +106,19 @@ STRING_UNTITLED, "(unbenannt)" STRING_ALL_FILES, "Alle Dateien (*.*)" STRING_TEXT_FILES_TXT, "Textdateien (*.txt)" -STRING_TOOLARGE, "Die Datei '%s' ist zu groß für den Editor\n \ +STRING_TOOLARGE, "Die Datei '%s' ist zu groß für den Editor\n \ Benutzen Sie bitte einen anderen Editor, um diese Datei zu bearbeiten." STRING_NOTEXT, "Sie haben keinen Text eingegeben, der \ -gespeichert\n werden könnte. Geben Sie Text ein, und versuchen Sie es \ +gespeichert\n werden könnte. Geben Sie Text ein, und versuchen Sie es \ \nerneut." STRING_DOESNOTEXIST, "Die Datei '%s'\nexistiert nicht.\n\n \ -Möchten Sie eine neue Datei erstellen ?" -STRING_NOTSAVED, "Datei %s\n wurde geändert.\n\n \ -Möchten Sie die Änderungen speichern ?" +Möchten Sie eine neue Datei erstellen ?" +STRING_NOTSAVED, "Datei %s\n wurde geändert.\n\n \ +Möchten Sie die Änderungen speichern ?" STRING_NOTFOUND, "'%s' kann nicht gefunden werden." -STRING_OUT_OF_MEMORY, "Nicht genügend Arbeitsspeicher, \ -um diese Funktion\nabzuschließen. Beenden Sie eine oder mehrere \ -\nAnwendungen, um den verfügbaren Arbeitsspeicher zu\nerhöhen." +STRING_OUT_OF_MEMORY, "Nicht genügend Arbeitsspeicher, \ +um diese Funktion\nabzuschließen. Beenden Sie eine oder mehrere \ +\nAnwendungen, um den verfügbaren Arbeitsspeicher zu\nerhöhen." -STRING_UNICODE_LE, "Unicode (UTF-16)" -STRING_UNICODE_BE, "Unicode (UTF-16 Big-Endian)" -STRING_LOSS_OF_UNICODE_CHARACTERS, "%s\n\ -Diese Datei enthält Unicode-Zeichen, die verloren gehen, wenn\n\ -Sie die Datei mit %s-Zeichenkodierung speichern.\n\ -Um die Zeichen beizubehalten, klicken Sie Abbrechen und wählen\n\ -Sie eine der Unicode-Optionen in der Liste.\n\ -Möchten Sie fortfahren?" } diff --git a/programs/notepad/En.rc b/programs/notepad/En.rc index d9ea7cd238a..c4a4baf440e 100644 --- a/programs/notepad/En.rc +++ b/programs/notepad/En.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT MAIN_MENU MENU @@ -93,14 +91,6 @@ PUSHBUTTON "Cancel", IDCANCEL, 180, 21, 40, 15, WS_TABSTOP PUSHBUTTON "&Help", IDHELP, 180, 39, 40, 15, WS_TABSTOP } -IDD_OFN_TEMPLATE DIALOG DISCARDABLE 50,50,300,15 -STYLE DS_3DLOOK | DS_CONTROL | WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | WS_BORDER -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Encoding:", -1, 5,0, 50,12 - COMBOBOX IDC_OFN_ENCCOMBO, 53,0, 156,48, WS_CHILD | WS_VSCROLL | CBS_DROPDOWNLIST -END - STRINGTABLE DISCARDABLE { STRING_PAGESETUP_HEADERVALUE, "&f" @@ -116,25 +106,17 @@ STRING_UNTITLED, "Untitled" STRING_ALL_FILES, "All files (*.*)" STRING_TEXT_FILES_TXT, "Text files (*.txt)" -STRING_TOOLARGE, "File '%s' is too large for notepad.\n\ +STRING_TOOLARGE, "File '%s' is too large for notepad.\n \ Please use a different editor." -STRING_NOTEXT, "You didn't enter any text.\ +STRING_NOTEXT, "You didn't enter any text. \ \nPlease type something and try again" -STRING_DOESNOTEXIST, "File '%s' does not exist.\n\n\ -Do you want to create a new file?" -STRING_NOTSAVED, "File '%s' has been modified.\n\n\ -Would you like to save the changes?" +STRING_DOESNOTEXIST, "File '%s'\ndoes not exist\n\n \ +Do you want to create a new file ?" +STRING_NOTSAVED, "File '%s'\nhas been modified\n\n \ +Would you like to save the changes ?" STRING_NOTFOUND, "'%s' could not be found." STRING_OUT_OF_MEMORY, "Not enough memory to complete this \ -task.\nClose one or more applications to increase the amount of free memory." - -STRING_UNICODE_LE, "Unicode (UTF-16)" -STRING_UNICODE_BE, "Unicode (UTF-16 big-endian)" +task.\nClose one or more applications to increase the amount of\nfree \ +memory." -STRING_LOSS_OF_UNICODE_CHARACTERS, "%s\n\ -This file contains Unicode characters which will be lost if\n\ -you save this file in the %s encoding.\n\ -To keep these characters, click Cancel, and then select\n\ -one of the Unicode options in the Encoding drop down list.\n\ -Continue?" } diff --git a/programs/notepad/Eo.rc b/programs/notepad/Eo.rc index 9aafbef8c85..7b75244c195 100644 --- a/programs/notepad/Eo.rc +++ b/programs/notepad/Eo.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT MAIN_MENU MENU diff --git a/programs/notepad/Es.rc b/programs/notepad/Es.rc index d73f167140d..dd19927c336 100644 --- a/programs/notepad/Es.rc +++ b/programs/notepad/Es.rc @@ -22,8 +22,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL MAIN_MENU MENU @@ -57,7 +55,6 @@ POPUP "&Editar" { POPUP "&Buscar" { MENUITEM "&Buscar...\tCtrl+F", CMD_SEARCH MENUITEM "Buscar &siguiente\tF3", CMD_SEARCH_NEXT - MENUITEM "&Reemplazar...\tCtrl+H", CMD_REPLACE } POPUP "A&yuda" { MENUITEM "Í&ndice", CMD_HELP_CONTENTS diff --git a/programs/notepad/Fi.rc b/programs/notepad/Fi.rc index 637dc7726ca..bd4b204a9c6 100644 --- a/programs/notepad/Fi.rc +++ b/programs/notepad/Fi.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT MAIN_MENU MENU @@ -54,7 +52,6 @@ POPUP "&Muokkaa" { POPUP "&Etsi" { MENUITEM "Etsi...", CMD_SEARCH MENUITEM "Etsi &seuraava\tF3", CMD_SEARCH_NEXT - MENUITEM "&Korvaa...\tCtrl+H", CMD_REPLACE } POPUP "&Apua" { MENUITEM "&Sisältö", CMD_HELP_CONTENTS diff --git a/programs/notepad/Fr.rc b/programs/notepad/Fr.rc index 77b3c3c90ce..506fd523b41 100644 --- a/programs/notepad/Fr.rc +++ b/programs/notepad/Fr.rc @@ -21,11 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL MAIN_MENU MENU @@ -42,7 +37,7 @@ MAIN_MENU MENU MENUITEM SEPARATOR MENUITEM "&Quitter", CMD_EXIT } -POPUP "É&dition" { +POPUP "É&dition" { MENUITEM "&Annuler\tCtrl+Z", CMD_UNDO MENUITEM SEPARATOR MENUITEM "Co&uper\tCtrl+X", CMD_CUT @@ -50,10 +45,10 @@ POPUP "É&dition" { MENUITEM "C&oller\tCtrl+V", CMD_PASTE MENUITEM "&Effacer\tDel", CMD_DELETE MENUITEM SEPARATOR - MENUITEM "Tout &sélectionner\tCtrl+A", CMD_SELECT_ALL + MENUITEM "Tout &sélectionner\tCtrl+A", CMD_SELECT_ALL MENUITEM "&Heure/Date\tF5", CMD_TIME_DATE MENUITEM SEPARATOR - MENUITEM "&Retour à la ligne automatique", CMD_WRAP + MENUITEM "&Retour à la ligne", CMD_WRAP MENUITEM "&Police...", CMD_FONT } POPUP "&Rechercher" { @@ -66,7 +61,7 @@ POPUP "Aid&e" { MENUITEM "&Rechercher...", CMD_HELP_SEARCH MENUITEM "&Utiliser l'aide", CMD_HELP_ON_HELP MENUITEM SEPARATOR - MENUITEM "À &propos du Bloc-notes", CMD_HELP_ABOUT_NOTEPAD + MENUITEM "À &propos du Bloc-notes", CMD_HELP_ABOUT_NOTEPAD } } @@ -77,34 +72,26 @@ STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU FONT 8, "MS Shell Dlg" CAPTION "Mise en page" { -LTEXT "&En-tête :", 0x140, 10, 07, 50, 15 +LTEXT "&En-tête:", 0x140, 10, 07, 40, 15 EDITTEXT IDC_PAGESETUP_HEADERVALUE, 60, 05,110, 12, WS_BORDER | WS_TABSTOP -LTEXT "&Pied de page :", 0x142, 10, 24, 50, 15 +LTEXT "&Pied de page :", 0x142, 10, 24, 40, 15 EDITTEXT IDC_PAGESETUP_FOOTERVALUE, 60, 22,110, 12, WS_BORDER | WS_TABSTOP -GROUPBOX "&Marges (millimètres):", 0x144, 10, 43,160, 45 -LTEXT "&Gauche :", 0x145, 20, 55, 30, 10, WS_CHILD +GROUPBOX "&Marges (millimètre):", 0x144, 10, 43,160, 45 +LTEXT "&Gauche :", 0x145, 20, 55, 30, 10, WS_CHILD EDITTEXT IDC_PAGESETUP_LEFTVALUE, 50, 55, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP -LTEXT "&Haut :", 0x148, 20, 73, 30, 10, WS_CHILD +LTEXT "&Haut :", 0x148, 20, 73, 30, 10, WS_CHILD EDITTEXT IDC_PAGESETUP_TOPVALUE, 50, 73, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP -LTEXT "&Droite :", 0x14B, 100, 55, 30, 10, WS_CHILD +LTEXT "&Droite :", 0x14B, 100, 55, 30, 10, WS_CHILD EDITTEXT IDC_PAGESETUP_RIGHTVALUE, 130, 55, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP -LTEXT "&Bas :", 0x14E,100, 73, 30, 10, WS_CHILD +LTEXT "&Bas :", 0x14E,100, 73, 30, 10, WS_CHILD EDITTEXT IDC_PAGESETUP_BOTTOMVALUE, 130, 73, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP DEFPUSHBUTTON "OK", IDOK, 180, 3, 40, 15, WS_TABSTOP PUSHBUTTON "Annuler", IDCANCEL, 180, 21, 40, 15, WS_TABSTOP -PUSHBUTTON "&Aide", IDHELP, 180, 39, 40, 15, WS_TABSTOP +PUSHBUTTON "Aid&e", IDHELP, 180, 39, 40, 15, WS_TABSTOP } -IDD_OFN_TEMPLATE DIALOG DISCARDABLE 50,50,300,15 -STYLE DS_3DLOOK | DS_CONTROL | WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | WS_BORDER -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Codage", -1, 5,0, 50,12 - COMBOBOX IDC_OFN_ENCCOMBO, 59,0, 156,48, WS_CHILD | WS_VSCROLL | CBS_DROPDOWNLIST -END - STRINGTABLE DISCARDABLE { STRING_PAGESETUP_HEADERVALUE, "&f" @@ -115,31 +102,22 @@ STRING_ERROR, "ERREUR" STRING_WARNING, "ATTENTION" STRING_INFO, "Information" -STRING_UNTITLED, "(sans titre)" +STRING_UNTITLED, "(sans-titre)" -STRING_ALL_FILES, "Tous les fichiers (*.*)" +STRING_ALL_FILES, "Tous fichiers (*.*)" STRING_TEXT_FILES_TXT, "Fichiers texte (*.txt)" -STRING_TOOLARGE, "Le fichier « %s » est trop grand pour le bloc-notes.\n\ -Veuillez utiliser un autre éditeur." -STRING_NOTEXT, "Vous n'avez pas entré de texte. \ +STRING_TOOLARGE, "Le fichier '%s' est trop grand pour le bloc-notes.\n \ +Veuillez utiliser un autre éditeur." +STRING_NOTEXT, "Vous n'avez pas entré de texte. \ Veuillez taper quelque chose et recommencer" -STRING_DOESNOTEXIST, "Le fichier « %s » n'existe pas.\n\n\ -Voulez-vous créer un nouveau fichier ?" -STRING_NOTSAVED, "Le fichier « %s » a été modifié\n\n\ -Voulez-vous enregistrer vos modifications ?" -STRING_NOTFOUND, "« %s » non trouvé." -STRING_OUT_OF_MEMORY, "Pas assez de mémoire pour terminer cette \ -tâche.\nFermez une ou plusieurs applications pour libérer\n\ -de la mémoire." - -STRING_UNICODE_LE, "Unicode (UTF-16)" -STRING_UNICODE_BE, "Unicode (UTF-16 big-endian)" +STRING_DOESNOTEXIST, "Le fichier '%s'\nn'existe pas.\n\n \ +Voulez-vous créer un nouveau fichier ?" +STRING_NOTSAVED, "Le fichier '%s'\na été modifié\n\n \ +Voulez-vous enregistrer vos modifications ?" +STRING_NOTFOUND, "'%s' non trouvé." +STRING_OUT_OF_MEMORY, "Pas assez de mémoire pour compléter cette \ +tâche.\nFermez une ou plusieurs applications pour libérer\n\ +de la mémoire." -STRING_LOSS_OF_UNICODE_CHARACTERS, "%s\n\ -Ce fichier contient des caractères Unicode qui seront perdus si\n\ -vous le sauvez dans le codage %s.\n\ -Pour conserver ces caractères, cliquez sur Annuler et sélectionnez\n\ -une des alternatives Unicode dans la liste déroulante Codage.\n\ -Continuer ?" } diff --git a/programs/notepad/Hu.rc b/programs/notepad/Hu.rc index e1251b5215f..9bf29866c9f 100644 --- a/programs/notepad/Hu.rc +++ b/programs/notepad/Hu.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - MAIN_MENU MENU LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT { POPUP "&Fájl" { diff --git a/programs/notepad/It.rc b/programs/notepad/It.rc index b8fb42ab5cc..755b08a15ff 100644 --- a/programs/notepad/It.rc +++ b/programs/notepad/It.rc @@ -23,8 +23,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL MAIN_MENU MENU diff --git a/programs/notepad/Ja.rc b/programs/notepad/Ja.rc index fcb81686e63..55139327286 100644 --- a/programs/notepad/Ja.rc +++ b/programs/notepad/Ja.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - /* UTF-8 */ #pragma code_page(65001) @@ -58,7 +56,6 @@ POPUP "編集(&E)" { POPUP "検索(&S)" { MENUITEM "検索(&S)...\tCtrl+F", CMD_SEARCH MENUITEM "次を検索(&S)\tF3", CMD_SEARCH_NEXT - MENUITEM "置き換える(&R)...\tCtrl+H", CMD_REPLACE } POPUP "ヘルプ(&H)" { MENUITEM "目次(&C)", CMD_HELP_CONTENTS @@ -125,3 +122,5 @@ STRING_OUT_OF_MEMORY, "この操作を実行するためのメ 下さい。" } + +#pragma code_page(default) diff --git a/programs/notepad/Ko.rc b/programs/notepad/Ko.rc index 94f1d10760b..3b4e5d470fe 100644 --- a/programs/notepad/Ko.rc +++ b/programs/notepad/Ko.rc @@ -22,8 +22,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT MAIN_MENU MENU @@ -114,22 +112,12 @@ STRING_TOOLARGE, "%s ´Ù¸¥ ÆíÁý±â¸¦ »ç¿ëÇϽʽÿÀ." STRING_NOTEXT, "ÀÔ·ÂÇÑ ³»¿ëÀÌ ¾ø½À´Ï´Ù.\ \n³»¿ëÀ» ÀÔ·ÂÇÑ ÈÄ Àç½ÃµµÇϽʽÿÀ" -STRING_DOESNOTEXIST, "%s\ ÆÄÀÏÀÌ ¾ø½À´Ï´Ù.\n\n \ +STRING_DOESNOTEXIST, "%s\nÆÄÀÏÀÌ ¾ø½À´Ï´Ù.\n\n \ ÆÄÀÏÀ» »õ·Î ¸¸µå½Ã°Ú½À´Ï±î?" -STRING_NOTSAVED, "%s\ ÆÄÀÏ ³»¿ëÀÌ º¯°æµÇ¾ú½À´Ï´Ù.\n\n \ +STRING_NOTSAVED, "%s\nÆÄÀÏ ³»¿ëÀÌ º¯°æµÇ¾ú½À´Ï´Ù.\n\n \ º¯°æ ³»¿ëÀ» ÀúÀåÇϽðڽÀ´Ï±î?" STRING_NOTFOUND, "%s ¹®ÀÚ¿­À» ãÀ» ¼ö ¾ø½À´Ï´Ù." STRING_OUT_OF_MEMORY, "ÀÌ ÀÛ¾÷À» ¿Ï·áÇÏ´Â µ¥ ÇÊ¿äÇÑ ¸Þ¸ð¸®°¡ ºÎÁ·ÇÕ´Ï´Ù.\ -\n»ç¿ë °¡´ÉÇÑ ¸Þ¸ð¸®ÀÇ ¾çÀ» È®º¸Çϱâ À§ÇØ Çϳª ÀÌ»óÀÇ ÀÀ¿ë ÇÁ·Î±×·¥À» ´Ý¾Æ ÁֽʽÿÀ." - - -STRING_UNICODE_LE, "À¯´ÏÄÚµå (UTF-16)" -STRING_UNICODE_BE, "À¯´ÏÄÚµå (UTF-16 ºò-¿£µð¾ð)" +\n»ç¿ë °¡´ÉÇÑ ¸Þ¸ð¸®ÀÇ ¾çÀ» È®º¸Çϱâ À§ÇØ Çϳª ÀÌ»óÀÇ ÀÀ¿ë ÇÁ·Î±×·¥À» ´Ý¾Æ ÁֽʽÿÀ.\n" -STRING_LOSS_OF_UNICODE_CHARACTERS, "%s\n\ -À¯´ÏÄÚµå ¹®ÀÚ¸¦ Æ÷ÇÔÇÏ°í ÀÖ´Â ÀÌ ÆÄÀÏÀº ¸¸¾à ´ç½ÅÀÌ %s ÀÎÄÚµùÀ¸·Î\n\ -ÆÄÀÏÀ» ÀúÀåÇÏ¸é ¹®ÀÚÀÇ ¼Õ½ÇÀÌ ÀÖÀ» °ÍÀÔ´Ï´Ù.\n\ -ÀÌ ¹®ÀÚ¸¦ º¸Á¸ÇÏ·Á¸é Ãë¼Ò¸¦ Ŭ¸¯ÇÏ°í, ÀÎÄÚµù µå·Ó´Ù¿î¸ñ·ÏÀÇ À¯´ÏÄÚµå\n\ -¿É¼Ç ÁßÀÇ Çϳª¸¦ ¼±ÅÃÇϽʽÿÀt.\n\ -°è¼ÓÇϽðڽÀ´Ï±î?" } diff --git a/programs/notepad/Lt.rc b/programs/notepad/Lt.rc index ddc2d61b596..ce289f22920 100644 --- a/programs/notepad/Lt.rc +++ b/programs/notepad/Lt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - /* UTF-8 */ #pragma code_page(65001) @@ -31,7 +29,7 @@ MAIN_MENU MENU MENUITEM "&Naujas\tCtrl+N", CMD_NEW MENUITEM "&Atverti...\tCtrl+O", CMD_OPEN MENUITEM "&Išsaugoti\tCtrl+S", CMD_SAVE - MENUITEM "Išsaugoti &kaip...", CMD_SAVE_AS + MENUITEM "Išsaugoti k&aip...", CMD_SAVE_AS MENUITEM SEPARATOR MENUITEM "S&pausdinti...\tCtrl+P", CMD_PRINT MENUITEM "Puslapio &nuostatos...", CMD_PAGE_SETUP @@ -50,12 +48,12 @@ POPUP "&Taisa" { MENUITEM "&Pažymėti viską\tCtrl+A", CMD_SELECT_ALL MENUITEM "&Laikas/Data\tF5", CMD_TIME_DATE MENUITEM SEPARATOR - MENUITEM "Skaidyti ilgas &eilutes", CMD_WRAP + MENUITEM "Laužyti ilgas &eilutes", CMD_WRAP MENUITEM "Š&riftas...", CMD_FONT } POPUP "&Paieška" { MENUITEM "&Ieškoti...\tCtrl+F", CMD_SEARCH - MENUITEM "Ieškoti ki&to\tF3", CMD_SEARCH_NEXT + MENUITEM "Ieškoti k&ito\tF3", CMD_SEARCH_NEXT MENUITEM "Pa&keisti...\tCtrl+H", CMD_REPLACE } POPUP "&Žinynas" { @@ -63,7 +61,7 @@ POPUP "&Žinynas" { MENUITEM "&Paieška...", CMD_HELP_SEARCH MENUITEM "Pa&galba apie žinyną", CMD_HELP_ON_HELP MENUITEM SEPARATOR - MENUITEM "&Apie užrašinę", CMD_HELP_ABOUT_NOTEPAD + MENUITEM "&Apie Notepad", CMD_HELP_ABOUT_NOTEPAD } } @@ -94,20 +92,12 @@ PUSHBUTTON "Atsisakyti", IDCANCEL, 180, 21, 40, 15, WS_TABSTOP PUSHBUTTON "&Žinynas", IDHELP, 180, 39, 40, 15, WS_TABSTOP } -IDD_OFN_TEMPLATE DIALOG DISCARDABLE 50,50,300,15 -STYLE DS_3DLOOK | DS_CONTROL | WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | WS_BORDER -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Koduotė:", -1, 5,0, 50,12 - COMBOBOX IDC_OFN_ENCCOMBO, 53,0, 156,48, WS_CHILD | WS_VSCROLL | CBS_DROPDOWNLIST -END - STRINGTABLE DISCARDABLE { STRING_PAGESETUP_HEADERVALUE, "&f" STRING_PAGESETUP_FOOTERVALUE, "Puslapis &p" -STRING_NOTEPAD, "Užrašinė" +STRING_NOTEPAD, "Notepad" STRING_ERROR, "KLAIDA" STRING_WARNING, "ĮSPĖJIMAS" STRING_INFO, "Informacija" @@ -117,24 +107,17 @@ STRING_UNTITLED, "Be pavadinimo" STRING_ALL_FILES, "Visi failai (*.*)" STRING_TEXT_FILES_TXT, "Tekstiniai failai (*.txt)" -STRING_TOOLARGE, "Failas „%s“ yra per didelis užrašinei.\n\ - Prašome naudoti kitą tekstų rengyklę." +STRING_TOOLARGE, "Failas '%s' yra per didelis notepad programai.\n\ +Prašome naudoti kitą tekstų rengyklę." STRING_NOTEXT, "Jūs neįvedėte jokio teksto.\n\ - Prašome ką nors įvesti ir mėginti dar kartą" -STRING_DOESNOTEXIST, "Failas „%s“\nneegzistuoja\n\n\ - Ar norite sukurti naują failą?" -STRING_NOTSAVED, "Failas „%s“\nbuvo pakeistas\n\n\ - Ar norite išsaugoti pakeitimus?" -STRING_NOTFOUND, "Frazė „%s“ nerasta." -STRING_OUT_OF_MEMORY, "Neužtenka atminties operacijai užbaigti.\n\ - Norėdami atlaisvinti atminties uždarykite vieną ar daugiau programų." - -STRING_UNICODE_LE, "Unikodas (UTF-16)" -STRING_UNICODE_BE, "Unikodas (UTF-16 mažėjantys baitai)" +Prašome ką nors įvesti ir mėginti dar kartą" +STRING_DOESNOTEXIST, "Failas '%s'\nneegzistuoja\n\n\ +Ar norite sukurti naują failą?" +STRING_NOTSAVED, "Failas '%s'\nbuvo pakeistas\n\n\ +Ar norite išsaugoti pakeitimus?" +STRING_NOTFOUND, "Frazė '%s' nerasta." +STRING_OUT_OF_MEMORY, "Neužtenka atminties operacijai užbaigti.\ +\nNorėdami atlaisvinti atminties uždarykite vieną ar daugiau programų." -STRING_LOSS_OF_UNICODE_CHARACTERS, "%s\n\ - Šiame faile yra unikodo ženklų, kurie bus prarasti, jei išsaugosite failą %s koduotėje.\n\ - Norėdami išsaugoti šiuos ženklus, spauskite „Atsisakyti“ ir pasirinkite vieną iš \ - unikodo nuostatų koduotės išskleidžiamajame sąraše.\n\ - Tęsti?" } +#pragma code_page(default) diff --git a/programs/notepad/Makefile.in b/programs/notepad/Makefile.in index c48acf7350e..fcdc8729600 100644 --- a/programs/notepad/Makefile.in +++ b/programs/notepad/Makefile.in @@ -13,34 +13,7 @@ C_SRCS = \ dialog.c \ main.c -RC_SRCS = \ - Bg.rc \ - Cs.rc \ - Da.rc \ - De.rc \ - En.rc \ - Eo.rc \ - Es.rc \ - Fi.rc \ - Fr.rc \ - Hu.rc \ - It.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ro.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Th.rc \ - Tr.rc \ - Wa.rc \ - Zh.rc \ - rsrc.rc +RC_SRCS = rsrc.rc SVG_SRCS = notepad.svg diff --git a/programs/notepad/Nl.rc b/programs/notepad/Nl.rc index f543b13001a..e4d12217c64 100644 --- a/programs/notepad/Nl.rc +++ b/programs/notepad/Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL MAIN_MENU MENU @@ -91,14 +89,6 @@ PUSHBUTTON "Annuleren", IDCANCEL, 180, 21, 40, 15, WS_TABSTOP PUSHBUTTON "&Help", IDHELP, 180, 39, 40, 15, WS_TABSTOP } -IDD_OFN_TEMPLATE DIALOG DISCARDABLE 50,50,300,15 -STYLE DS_3DLOOK | DS_CONTROL | WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | WS_BORDER -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Codering:", -1, 5,0, 50,12 - COMBOBOX IDC_OFN_ENCCOMBO, 53,0, 156,48, WS_CHILD | WS_VSCROLL | CBS_DROPDOWNLIST -END - STRINGTABLE DISCARDABLE { STRING_PAGESETUP_HEADERVALUE, "&f" @@ -125,14 +115,4 @@ Wilt u de wijzigingen opslaan?" STRING_NOTFOUND, "'%s' kan niet worden gevonden." STRING_OUT_OF_MEMORY, "Onvoldoende geheugen. \ \nSluit een of meer applicaties om de hoeveelheid\nbeschikbaar geheugen te vergroten." - -STRING_UNICODE_LE, "Unicode (UTF-16)" -STRING_UNICODE_BE, "Unicode (UTF-16 big-endian)" - -STRING_LOSS_OF_UNICODE_CHARACTERS, "%s\n\ -Dit bestand bevat Unicode tekens welke verloren zullen gaan\n\ -als dit bestand wordt opgeslagen in de %s codering.\n\ -Om deze tekens te behouden, klikt u op Annuleren en selecteert\n\ -daarna een van de Unicode-opties in de Codering keuzelijst.\n\ -Wilt u doorgaan?" } diff --git a/programs/notepad/No.rc b/programs/notepad/No.rc index 271e038e9cc..6692561b697 100644 --- a/programs/notepad/No.rc +++ b/programs/notepad/No.rc @@ -1,7 +1,7 @@ /* - * Notepad (Norwegian Bokmål resources) + * Notepad (Norwegian Bokmål resources) * - * Copyright 2005-2006 Alexander N. Sørnes + * Copyright 2005-2006 Alexander N. Sørnes * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -18,17 +18,13 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - -#pragma code_page(65001) - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL MAIN_MENU MENU { POPUP "&Fil" { MENUITEM "&Ny\tCtrl+N", CMD_NEW - MENUITEM "&Åpne...\tCtrl+O", CMD_OPEN + MENUITEM "&Åpne...\tCtrl+O", CMD_OPEN MENUITEM "&Lagre\tCtrl+S", CMD_SAVE MENUITEM "Lagr&e som...", CMD_SAVE_AS MENUITEM SEPARATOR @@ -52,14 +48,13 @@ POPUP "R&ediger" { MENUITEM "Tekstbrytin&g", CMD_WRAP MENUITEM "Skr&ift...", CMD_FONT } -POPUP "&Søk" { - MENUITEM "&Søk...\tCtrl+F", CMD_SEARCH - MENUITEM "Søk etter nest&e\tF3", CMD_SEARCH_NEXT - MENUITEM "E&rstatt...\tCtrl+H", CMD_REPLACE +POPUP "&Søk" { + MENUITEM "&Søk...\tCtrl+F", CMD_SEARCH + MENUITEM "&Søk etter nest&e\tF3", CMD_SEARCH_NEXT } POPUP "&Hjelp" { MENUITEM "&Innhold", CMD_HELP_CONTENTS - MENUITEM "&Søk...", CMD_HELP_SEARCH + MENUITEM "&Søk...", CMD_HELP_SEARCH MENUITEM "&Hjelp om hjelp", CMD_HELP_ON_HELP MENUITEM SEPARATOR MENUITEM "&Om Notepad", CMD_HELP_ABOUT_NOTEPAD @@ -83,7 +78,7 @@ LTEXT "&Venstre:", 0x145, 20, 55, 30, 10, WS_CHILD EDITTEXT IDC_PAGESETUP_LEFTVALUE, 50, 55, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP LTEXT "&Topp:", 0x148, 20, 73, 30, 10, WS_CHILD EDITTEXT IDC_PAGESETUP_TOPVALUE, 50, 73, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP -LTEXT "Høy&re:", 0x14B, 100, 55, 30, 10, WS_CHILD +LTEXT "Høy&re:", 0x14B, 100, 55, 30, 10, WS_CHILD EDITTEXT IDC_PAGESETUP_RIGHTVALUE, 130, 55, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP LTEXT "&Bunn:", 0x14E,100, 73, 30, 10, WS_CHILD EDITTEXT IDC_PAGESETUP_BOTTOMVALUE, 130, 73, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP @@ -93,14 +88,6 @@ PUSHBUTTON "Avbryt", IDCANCEL, 180, 21, 40, 15, WS_TABSTOP PUSHBUTTON "&Hjelp", IDHELP, 180, 39, 40, 15, WS_TABSTOP } -IDD_OFN_TEMPLATE DIALOG DISCARDABLE 50,50,300,15 -STYLE DS_3DLOOK | DS_CONTROL | WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | WS_BORDER -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Tegnkoding:", -1, 5,0, 50,12 - COMBOBOX IDC_OFN_ENCCOMBO, 53,0, 156,48, WS_CHILD | WS_VSCROLL | CBS_DROPDOWNLIST -END - STRINGTABLE DISCARDABLE { STRING_PAGESETUP_HEADERVALUE, "&f" @@ -116,26 +103,17 @@ STRING_UNTITLED, "(Uten navn)" STRING_ALL_FILES, "Alle filer (*.*)" STRING_TEXT_FILES_TXT, "Tekstfiler (*.txt)" -STRING_TOOLARGE, "Filen «%s» er for stor for Notisblokk.\n \ +STRING_TOOLARGE, "Filen «%s» er for stor for Notisblokk.\n \ Bruk en annen redigerer." STRING_NOTEXT, "Du skrev ikke inn noe tekst. \ -\nSkriv noe og prøv igjen." -STRING_DOESNOTEXIST, "Filen «%s» finnes ikke.\n\n \ +\nSkriv noe og prøv igjen." +STRING_DOESNOTEXIST, "Filen «%s» finnes ikke.\n\n \ Opprette en ny fil?" -STRING_NOTSAVED, "Filen «%s» er endret.\n\n \ +STRING_NOTSAVED, "Filen «%s» er endret.\n\n \ Lagre endringene?" -STRING_NOTFOUND, "Klarte ikke finne «%s»." -STRING_OUT_OF_MEMORY, "Ikke nok minne for å fullføre \ -operasjonen.\nLukk et eller flere programmer for å frigjøre\nmer \ +STRING_NOTFOUND, "Klarte ikke finne «%s»." +STRING_OUT_OF_MEMORY, "Ikke nok minne for å fullføre \ +operasjonen.\nLukk et eller flere programmer for å frigjøre\nmer \ minne." -STRING_UNICODE_LE, "Unicode (UTF-16)" -STRING_UNICODE_BE, "Unicode (UTF-16 big-endian)" - -STRING_LOSS_OF_UNICODE_CHARACTERS, "«%s»\n\ -Denne filen inneholder Unicode-tegn som vil gå tapt hvis\n\ -filen lagres med tegnkodingen %s.\n\ -Trykk Avbryt og velg et av Unicode-valgene fra listen\n\ -hvis du vil beholde tegnene.\n\ -Fortsette?" } diff --git a/programs/notepad/Pl.rc b/programs/notepad/Pl.rc index f7dbfe008b1..c05c715be97 100644 --- a/programs/notepad/Pl.rc +++ b/programs/notepad/Pl.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT MAIN_MENU MENU diff --git a/programs/notepad/Pt.rc b/programs/notepad/Pt.rc index 194225ca2db..b9ef4d9a6ce 100644 --- a/programs/notepad/Pt.rc +++ b/programs/notepad/Pt.rc @@ -5,7 +5,7 @@ * Copyright 1999 Marcel Baur * Copyright 2002 Sylvain Petreolle * Copyright 2003 Marcelo Duarte - * Copyright 2004 Américo José Melo + * 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 @@ -22,10 +22,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - -#pragma code_page(65001) - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN MAIN_MENU MENU @@ -37,7 +33,7 @@ MAIN_MENU MENU MENUITEM "Salvar &como...", CMD_SAVE_AS MENUITEM SEPARATOR MENUITEM "&Imprimir...\tCtrl+P", CMD_PRINT - MENUITEM "C&onfigurar página...", CMD_PAGE_SETUP + MENUITEM "C&onfigurar página...", CMD_PAGE_SETUP MENUITEM "Configurar i&mpressora...", CMD_PRINTER_SETUP MENUITEM SEPARATOR MENUITEM "Sai&r", CMD_EXIT @@ -53,15 +49,15 @@ POPUP "&Editar" { MENUITEM "Selecionar &tudo", CMD_SELECT_ALL MENUITEM "&Data/Hora\tF5", CMD_TIME_DATE MENUITEM SEPARATOR - MENUITEM "&Quebrar automática de linha", CMD_WRAP + MENUITEM "&Quebrar automática de linha", CMD_WRAP MENUITEM "&Fonte...", CMD_FONT } POPUP "&Pesquisa" { MENUITEM "&Localizar...", CMD_SEARCH - MENUITEM "Localizar &próxima\tF3", CMD_SEARCH_NEXT + MENUITEM "Localizar &próxima\tF3", CMD_SEARCH_NEXT } POPUP "&Ajuda" { - MENUITEM "&Conteúdo", CMD_HELP_CONTENTS + MENUITEM "&Conteúdo", CMD_HELP_CONTENTS MENUITEM "&Procurar...", CMD_HELP_SEARCH MENUITEM "&Ajuda na ajuda", CMD_HELP_ON_HELP MENUITEM SEPARATOR @@ -80,7 +76,7 @@ MAIN_MENU MENU MENUITEM "Gravar &como...", CMD_SAVE_AS MENUITEM SEPARATOR MENUITEM "&Imprimir", CMD_PRINT - MENUITEM "C&onfigurar página...", CMD_PAGE_SETUP + MENUITEM "C&onfigurar página...", CMD_PAGE_SETUP MENUITEM "Configurar i&mpressora...", CMD_PRINTER_SETUP MENUITEM SEPARATOR MENUITEM "Sai&r", CMD_EXIT @@ -96,20 +92,19 @@ POPUP "&Editar" { MENUITEM "Seleccionar &tudo", CMD_SELECT_ALL MENUITEM "&Data/Hora\tF5", CMD_TIME_DATE MENUITEM SEPARATOR - MENUITEM "&Quebrar automática de linha", CMD_WRAP + MENUITEM "&Quebrar automática de linha", CMD_WRAP MENUITEM "&Tipo de Letra...", CMD_FONT } POPUP "&Pesquisa" { MENUITEM "&Localizar...", CMD_SEARCH - MENUITEM "Localizar &próxima\tF3", CMD_SEARCH_NEXT - MENUITEM "&Substituir...\tCtrl+H", CMD_REPLACE + MENUITEM "Localizar &próxima\tF3", CMD_SEARCH_NEXT } POPUP "&Ajuda" { - MENUITEM "&Conteúdo", CMD_HELP_CONTENTS + MENUITEM "&Conteúdo", CMD_HELP_CONTENTS MENUITEM "&Procurar...", CMD_HELP_SEARCH MENUITEM "&Ajuda na ajuda", CMD_HELP_ON_HELP MENUITEM SEPARATOR - MENUITEM "&Acerca do Notepad...", CMD_HELP_ABOUT_NOTEPAD + MENUITEM "&About Notepad...", CMD_HELP_ABOUT_NOTEPAD } } @@ -121,11 +116,11 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL DIALOG_PAGESETUP DIALOG 0, 0, 225, 95 STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU FONT 8, "MS Shell Dlg" -CAPTION "Configurar página" +CAPTION "Configurar página" { -LTEXT "&Cabeçalho (mm):", 0x140, 10, 07, 40, 15 +LTEXT "&Cabeçalho (mm):", 0x140, 10, 07, 40, 15 EDITTEXT IDC_PAGESETUP_HEADERVALUE, 60, 05,110, 12, WS_BORDER | WS_TABSTOP -LTEXT "&Rodapé:", 0x142, 10, 24, 40, 15 +LTEXT "&Rodapé:", 0x142, 10, 24, 40, 15 EDITTEXT IDC_PAGESETUP_FOOTERVALUE, 60, 22,110, 12, WS_BORDER | WS_TABSTOP GROUPBOX "&Margens:", 0x144, 10, 43,160, 45 @@ -143,42 +138,35 @@ PUSHBUTTON "Cancelar", IDCANCEL, 180, 21, 40, 15, WS_TABSTO PUSHBUTTON "&Ajuda", IDHELP, 180, 39, 40, 15, WS_TABSTOP } -IDD_OFN_TEMPLATE DIALOG DISCARDABLE 50,50,300,15 -STYLE DS_3DLOOK | DS_CONTROL | WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | WS_BORDER -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Codificação:", -1, 5,0, 50,12 - COMBOBOX IDC_OFN_ENCCOMBO, 53,0, 156,48, WS_CHILD | WS_VSCROLL | CBS_DROPDOWNLIST -END LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE DISCARDABLE { STRING_PAGESETUP_HEADERVALUE, "&f" -STRING_PAGESETUP_FOOTERVALUE, "Página &p" +STRING_PAGESETUP_FOOTERVALUE, "Página &p" STRING_NOTEPAD, "Notepad" STRING_ERROR, "ERRO" STRING_WARNING, "AVISO" -STRING_INFO, "Informação" +STRING_INFO, "Informação" STRING_UNTITLED, "(sem nome)" STRING_ALL_FILES, "Todos os arquivos (*.*)" STRING_TEXT_FILES_TXT, "Arquivos texto (*.txt)" -STRING_TOOLARGE, "Arquivo '%s' é muito longo para o notepad.\n \ +STRING_TOOLARGE, "Arquivo '%s' é muito longo para o notepad.\n \ Por favor use um editor diferente." -STRING_NOTEXT, "Você não digitou nenhum texto. \ +STRING_NOTEXT, "Você não digitou nenhum texto. \ \nPor favor digite alguma coisa e tente novamente" -STRING_DOESNOTEXIST, "Arquivo '%s'\nnão existe\n\n \ -Você deseja criar um novo arquivo?" +STRING_DOESNOTEXIST, "Arquivo '%s'\nnão existe\n\n \ +Você deseja criar um novo arquivo?" STRING_NOTSAVED, "Arquivo '%s'\nfoi modificado\n\n \ -Gostaria de salvar as alteraçÕes?" -STRING_NOTFOUND, "'%s' não pode ser encontrado." -STRING_OUT_OF_MEMORY, "Não há memória suficiente para completar essa \ -tarefa.\nFeche uma ou mais aplicações para aumentar a quantidade de memória livre." +Gostaria de salvar as alteraçÕes?" +STRING_NOTFOUND, "'%s' não pode ser encontrado." +STRING_OUT_OF_MEMORY, "Não há memória suficiente para completar essa \ +tarefa.\nFeche uma ou mais aplicações para aumentar a quantidade de memória livre." } LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE @@ -186,37 +174,27 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE DISCARDABLE { STRING_PAGESETUP_HEADERVALUE, "&f" - STRING_PAGESETUP_FOOTERVALUE, "Página &p" + STRING_PAGESETUP_FOOTERVALUE, "Página &p" STRING_NOTEPAD, "Notepad" STRING_ERROR, "ERRO" STRING_WARNING, "AVISO" - STRING_INFO, "Informação" + STRING_INFO, "Informação" STRING_UNTITLED, "(sem nome)" STRING_ALL_FILES, "Todos os arquivos (*.*)" STRING_TEXT_FILES_TXT, "Ficheiros de texto (*.txt)" - STRING_TOOLARGE, "Ficheiros '%s' é muito longo para o notepad.\n \ + STRING_TOOLARGE, "Ficheiros '%s' é muito longo para o notepad.\n \ Por favor use um editor diferente." - STRING_NOTEXT, "Não digitou nenhum texto. \ + STRING_NOTEXT, "Não digitou nenhum texto. \ \nPor favor digite alguma coisa e tente novamente" - STRING_DOESNOTEXIST, "Ficheiro '%s'\nnão existe\n\n \ + STRING_DOESNOTEXIST, "Ficheiro '%s'\nnão existe\n\n \ Deseja criar um novo ficheiro?" STRING_NOTSAVED, "Ficheiro '%s'\nfoi modificado\n\n \ -Gostaria de gravar as alteraçÕes?" - STRING_NOTFOUND, "'%s' não pode ser encontrado." - STRING_OUT_OF_MEMORY, "Não há memória suficiente para completar esta \ -tarefa.\nFeche uma ou mais aplicações para aumentar a quantidade de memória livre." - -STRING_UNICODE_LE, "Unicode (UTF-16)" -STRING_UNICODE_BE, "Unicode (UTF-16 big-endian)" - -STRING_LOSS_OF_UNICODE_CHARACTERS, "%s\n\ -Este ficheiro contém caracteres Unicode que serão perdidos se\n\ -guardar este ficheiro na codificação %s.\n\ -Para manter estes caracteres, carregue em Cancelar, e depois seleccione\n\ -uma das opções Unicode na lista de Codificações.\n\ -Continuar?" +Gostaria de gravar as alteraçÕes?" + STRING_NOTFOUND, "'%s' não pode ser encontrado." + STRING_OUT_OF_MEMORY, "Não há memória suficiente para completar esta \ +tarefa.\nFeche uma ou mais aplicações para aumentar a quantidade de memória livre." } diff --git a/programs/notepad/Ro.rc b/programs/notepad/Ro.rc index a00be21eaad..9685de903af 100644 --- a/programs/notepad/Ro.rc +++ b/programs/notepad/Ro.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -116,3 +114,5 @@ STRING_NOTFOUND, "'%s' nu a fost găsit." STRING_OUT_OF_MEMORY, "Nu este destulă memorie pentru a completa această sarcină.\nÎnchideți una sau mai multe aplicații pentru a mări memoria liberă." } + +#pragma code_page(default) diff --git a/programs/notepad/Ru.rc b/programs/notepad/Ru.rc dissimilarity index 71% index 814b7fcd8fc..439c1ebca9d 100644 --- a/programs/notepad/Ru.rc +++ b/programs/notepad/Ru.rc @@ -1,139 +1,118 @@ -/* - * Notepad (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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "notepad_res.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT - -MAIN_MENU MENU -{ - POPUP "&Файл" { - MENUITEM "Созд&ать\tCtrl+N", CMD_NEW - MENUITEM "&Открыть...\tCtrl+O", CMD_OPEN - MENUITEM "&Сохранить\tCtrl+S", CMD_SAVE - MENUITEM "Сохранить &как...", CMD_SAVE_AS - MENUITEM SEPARATOR - MENUITEM "&Печатать...\tCtrl+P", CMD_PRINT - MENUITEM "Пара&метры страницы...", CMD_PAGE_SETUP - MENUITEM "&Настройка принтера...", CMD_PRINTER_SETUP - MENUITEM SEPARATOR - MENUITEM "В&ыход", CMD_EXIT - } -POPUP "&Правка" { - MENUITEM "&Отменить\tCtrl+Z", CMD_UNDO - MENUITEM SEPARATOR - MENUITEM "&Вырезать\tCtrl+X", CMD_CUT - MENUITEM "&Копировать\tCtrl+C", CMD_COPY - MENUITEM "Вст&авить\tCtrl+V", CMD_PASTE - MENUITEM "&Удалить\tDel", CMD_DELETE - MENUITEM SEPARATOR - MENUITEM "Выделить в&се", CMD_SELECT_ALL - MENUITEM "Врем&я и дата\tF5", CMD_TIME_DATE - MENUITEM SEPARATOR - MENUITEM "&Перенос по словам", CMD_WRAP - MENUITEM "&Шрифт...", CMD_FONT - } -POPUP "П&оиск" { - MENUITEM "&Найти...", CMD_SEARCH - MENUITEM "Найти &далее\tF3", CMD_SEARCH_NEXT - } -POPUP "&Справка" { - MENUITEM "&Содержание", CMD_HELP_CONTENTS - MENUITEM "&Поиск...", CMD_HELP_SEARCH - MENUITEM "&Использование справки", CMD_HELP_ON_HELP - MENUITEM SEPARATOR - MENUITEM "&О Notepad", CMD_HELP_ABOUT_NOTEPAD - } -} - -/* Dialog `Page setup' */ - -DIALOG_PAGESETUP DIALOG 0, 0, 225, 95 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -FONT 8, "MS Shell Dlg" -CAPTION "Параметры страницы" -{ -LTEXT "В&ерхний колонтитул:", 0x140, 10, 07, 40, 15 -EDITTEXT IDC_PAGESETUP_HEADERVALUE, 60, 05,110, 12, WS_BORDER | WS_TABSTOP -LTEXT "Н&ижний колонтитул:", 0x142, 10, 24, 40, 15 -EDITTEXT IDC_PAGESETUP_FOOTERVALUE, 60, 22,110, 12, WS_BORDER | WS_TABSTOP - -GROUPBOX "Поля (мм):", 0x144, 10, 43,160, 45 -LTEXT "&Левое:", 0x145, 20, 55, 30, 10, WS_CHILD -EDITTEXT IDC_PAGESETUP_LEFTVALUE, 50, 55, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP -LTEXT "&Верхнее:", 0x148, 20, 73, 30, 10, WS_CHILD -EDITTEXT IDC_PAGESETUP_TOPVALUE, 50, 73, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP -LTEXT "&Правое:", 0x14B, 100, 55, 30, 10, WS_CHILD -EDITTEXT IDC_PAGESETUP_RIGHTVALUE, 130, 55, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP -LTEXT "&Нижнее:", 0x14E,100, 73, 30, 10, WS_CHILD -EDITTEXT IDC_PAGESETUP_BOTTOMVALUE, 130, 73, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP - -DEFPUSHBUTTON "OK", IDOK, 180, 3, 40, 15, WS_TABSTOP -PUSHBUTTON "Отмена", IDCANCEL, 180, 21, 40, 15, WS_TABSTOP -PUSHBUTTON "&Справка", IDHELP, 180, 39, 40, 15, WS_TABSTOP -} - -IDD_OFN_TEMPLATE DIALOG DISCARDABLE 50,50,300,15 -STYLE DS_3DLOOK | DS_CONTROL | WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | WS_BORDER -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Кодировка:", -1, 5,0, 50,12 - COMBOBOX IDC_OFN_ENCCOMBO, 53,0, 156,48, WS_CHILD | WS_VSCROLL | CBS_DROPDOWNLIST -END - -STRINGTABLE DISCARDABLE -{ -STRING_PAGESETUP_HEADERVALUE, "&f" -STRING_PAGESETUP_FOOTERVALUE, "Страница &p" - -STRING_NOTEPAD, "Блокнот" -STRING_ERROR, "ОШИБКА" -STRING_WARNING, "ВНИМАНИЕ" -STRING_INFO, "Информация" - -STRING_UNTITLED, "(без заголовка)" - -STRING_ALL_FILES, "Все файлы (*.*)" -STRING_TEXT_FILES_TXT, "Текстовые файлы (*.txt)" - -STRING_TOOLARGE, "Файл '%s' слишком большой для блокнота.\n \ -Используйте другой редактор." -STRING_NOTEXT, "Вы не ввели никакого текста. \ -\nВведите что-нибудь и попробуйте еще." -STRING_DOESNOTEXIST, "Файл '%s'\nне существует\n\n \ -Хотите создать новый файл?" -STRING_NOTSAVED, "Файл '%s'\nбыл изменен\n\n \ -Хотите сохранить изменения?" -STRING_NOTFOUND, "'%s' не найден." -STRING_OUT_OF_MEMORY, "Недостаточно памяти для завершения этой операции \ -\nЗакройте одно или несколько приложений и повторите попытку." - -STRING_UNICODE_LE, "Юникод (UTF-16)" -STRING_UNICODE_BE, "Юникод (UTF-16 big-endian)" - -STRING_LOSS_OF_UNICODE_CHARACTERS, "%s\n\ -Этот файл содержит текст в формате Юникод, который будет потерян, если вы сохраните этот файл как файл в кодировке %s.\n\ -Чтобы сохранить данные в формате Юникод, нажмите кнопку \"Отмена\" и выберите\n\ -один из вариантов сохранения в формате Юникод.\n\ -Продолжить?" -} +/* + * Notepad (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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT + +MAIN_MENU MENU +{ + POPUP "&Ôàéë" { + MENUITEM "Ñîçä&àòü\tCtrl+N", CMD_NEW + MENUITEM "&Îòêðûòü...\tCtrl+O", CMD_OPEN + MENUITEM "&Ñîõðàíèòü\tCtrl+S", CMD_SAVE + MENUITEM "Ñîõðàíèòü &êàê...", CMD_SAVE_AS + MENUITEM SEPARATOR + MENUITEM "&Ïå÷àòàòü...\tCtrl+P", CMD_PRINT + MENUITEM "Ïàðà&ìåòðû ñòðàíèöû...", CMD_PAGE_SETUP + MENUITEM "&Íàñòðîéêà ïðèíòåðà...", CMD_PRINTER_SETUP + MENUITEM SEPARATOR + MENUITEM "Â&ûõîä", CMD_EXIT + } +POPUP "&Ïðàâêà" { + MENUITEM "&Îòìåíèòü\tCtrl+Z", CMD_UNDO + MENUITEM SEPARATOR + MENUITEM "&Âûðåçàòü\tCtrl+X", CMD_CUT + MENUITEM "&Êîïèðîâàòü\tCtrl+C", CMD_COPY + MENUITEM "Âñò&àâèòü\tCtrl+V", CMD_PASTE + MENUITEM "&Óäàëèòü\tDel", CMD_DELETE + MENUITEM SEPARATOR + MENUITEM "Âûäåëèòü â&ñå", CMD_SELECT_ALL + MENUITEM "Âðåì&ÿ è äàòà\tF5", CMD_TIME_DATE + MENUITEM SEPARATOR + MENUITEM "&Ïåðåíîñ ïî ñëîâàì", CMD_WRAP + MENUITEM "&Øðèôò...", CMD_FONT + } +POPUP "Ï&îèñê" { + MENUITEM "&Íàéòè...", CMD_SEARCH + MENUITEM "Íàéòè &äàëåå\tF3", CMD_SEARCH_NEXT + } +POPUP "&Ñïðàâêà" { + MENUITEM "&Ñîäåðæàíèå", CMD_HELP_CONTENTS + MENUITEM "&Ïîèñê...", CMD_HELP_SEARCH + MENUITEM "&Èñïîëüçîâàíèå ñïðàâêè", CMD_HELP_ON_HELP + MENUITEM SEPARATOR + MENUITEM "&Î Notepad", CMD_HELP_ABOUT_NOTEPAD + } +} + +/* Dialog `Page setup' */ + +DIALOG_PAGESETUP DIALOG 0, 0, 225, 95 +STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +FONT 8, "MS Shell Dlg" +CAPTION "Ïàðàìåòðû ñòðàíèöû" +{ +LTEXT "Â&åðõíèé êîëîíòèòóë:", 0x140, 10, 07, 40, 15 +EDITTEXT IDC_PAGESETUP_HEADERVALUE, 60, 05,110, 12, WS_BORDER | WS_TABSTOP +LTEXT "Í&èæíèé êîëîíòèòóë:", 0x142, 10, 24, 40, 15 +EDITTEXT IDC_PAGESETUP_FOOTERVALUE, 60, 22,110, 12, WS_BORDER | WS_TABSTOP + +GROUPBOX "Ïîëÿ (ìì):", 0x144, 10, 43,160, 45 +LTEXT "&Ëåâîå:", 0x145, 20, 55, 30, 10, WS_CHILD +EDITTEXT IDC_PAGESETUP_LEFTVALUE, 50, 55, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP +LTEXT "&Âåðõíåå:", 0x148, 20, 73, 30, 10, WS_CHILD +EDITTEXT IDC_PAGESETUP_TOPVALUE, 50, 73, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP +LTEXT "&Ïðàâîå:", 0x14B, 100, 55, 30, 10, WS_CHILD +EDITTEXT IDC_PAGESETUP_RIGHTVALUE, 130, 55, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP +LTEXT "&Íèæíåå:", 0x14E,100, 73, 30, 10, WS_CHILD +EDITTEXT IDC_PAGESETUP_BOTTOMVALUE, 130, 73, 35, 11, WS_CHILD | WS_BORDER | WS_TABSTOP + +DEFPUSHBUTTON "OK", IDOK, 180, 3, 40, 15, WS_TABSTOP +PUSHBUTTON "Îòìåíà", IDCANCEL, 180, 21, 40, 15, WS_TABSTOP +PUSHBUTTON "&Ñïðàâêà", IDHELP, 180, 39, 40, 15, WS_TABSTOP +} + +STRINGTABLE DISCARDABLE +{ +STRING_PAGESETUP_HEADERVALUE, "&f" +STRING_PAGESETUP_FOOTERVALUE, "Ñòðàíèöà &p" + +STRING_NOTEPAD, "Áëîêíîò" +STRING_ERROR, "ÎØÈÁÊÀ" +STRING_WARNING, "ÂÍÈÌÀÍÈÅ" +STRING_INFO, "Èíôîðìàöèÿ" + +STRING_UNTITLED, "(áåç çàãîëîâêà)" + +STRING_ALL_FILES, "Âñå ôàéëû (*.*)" +STRING_TEXT_FILES_TXT, "Òåêñòîâûå ôàéëû (*.txt)" + +STRING_TOOLARGE, "Ôàéë '%s' ñëèøêîì áîëüøîé äëÿ áëîêíîòà.\n \ +Èñïîëüçóéòå äðóãîé ðåäàêòîð." +STRING_NOTEXT, "Âû íå ââåëè íèêàêîãî òåêñòà. \ +\nÂâåäèòå ÷òî-íèáóäü è ïîïðîáóéòå åùå." +STRING_DOESNOTEXIST, "Ôàéë '%s'\níå ñóùåñòâóåò\n\n \ +Õîòèòå ñîçäàòü íîâûé ôàéë?" +STRING_NOTSAVED, "Ôàéë '%s'\náûë èçìåíåí\n\n \ +Õîòèòå ñîõðàíèòü èçìåíåíèÿ?" +STRING_NOTFOUND, "'%s' íå íàéäåí." +STRING_OUT_OF_MEMORY, "Íåäîñòàòî÷íî ïàìÿòè äëÿ çàâåðøåíèÿ ýòîé îïåðàöèè \ +\nÇàêðîéòå îäíî èëè íåñêîëüêî ïðèëîæåíèé è ïîâòîðèòå ïîïûòêó." + +} diff --git a/programs/notepad/Si.rc b/programs/notepad/Si.rc index 57a8071dd53..533bfd64a4c 100644 --- a/programs/notepad/Si.rc +++ b/programs/notepad/Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -55,7 +53,6 @@ POPUP "&Urejanje" { POPUP "&Iskanje" { MENUITEM "&Najdi ...\tCtrl+F", CMD_SEARCH MENUITEM "Najdi na&slednje\tF3", CMD_SEARCH_NEXT - MENUITEM "&Zamenjaj ...\tCtrl+H", CMD_REPLACE } POPUP "&Pomoč" { MENUITEM "&Teme pomoči", CMD_HELP_CONTENTS @@ -121,3 +118,5 @@ STRING_OUT_OF_MEMORY, "Za dokončanje operacije je na voljo pr pomnilnika.\nZaprite enega ali več programov in poskusite znova." } + +#pragma code_page(default) diff --git a/programs/notepad/Sv.rc b/programs/notepad/Sv.rc index cfc675f0faa..7e4aa294c1f 100644 --- a/programs/notepad/Sv.rc +++ b/programs/notepad/Sv.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL MAIN_MENU MENU @@ -94,14 +92,6 @@ PUSHBUTTON "Avbryt", IDCANCEL, 180, 21, 40, 15, WS_TABSTOP PUSHBUTTON "&Hjälp", IDHELP, 180, 39, 40, 15, WS_TABSTOP } -IDD_OFN_TEMPLATE DIALOG DISCARDABLE 50,50,300,15 -STYLE DS_3DLOOK | DS_CONTROL | WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | WS_BORDER -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Kodning:", -1, 5,0, 50,12 - COMBOBOX IDC_OFN_ENCCOMBO, 53,0, 156,48, WS_CHILD | WS_VSCROLL | CBS_DROPDOWNLIST -END - STRINGTABLE DISCARDABLE { STRING_PAGESETUP_HEADERVALUE, "&f" @@ -130,13 +120,4 @@ STRING_OUT_OF_MEMORY, "Det finns inte tillr den här uppgiften.\nAvsluta ett eller flera program för att öka mängden\nledigt \ minne." -STRING_UNICODE_LE, "Unicode (UTF-16)" -STRING_UNICODE_BE, "Unicode (UTF-16 big-endian)" - -STRING_LOSS_OF_UNICODE_CHARACTERS, "%s\n\ -Denna fil innehåller Unicode-tecken vilka kommer att gå\n\ -förlorade om du sparar filen under kodningen %s.\n\ -Klicka Avbryt och välj sedan ett av Unicode-alternativen\n\ -i teckenkodningslistan för att behålla dessa tecken.\n\ -Vill du fortsätta?" } diff --git a/programs/notepad/Th.rc b/programs/notepad/Th.rc index 10a6db56c6c..988a39210d4 100644 --- a/programs/notepad/Th.rc +++ b/programs/notepad/Th.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_THAI, SUBLANG_DEFAULT MAIN_MENU MENU diff --git a/programs/notepad/Tr.rc b/programs/notepad/Tr.rc index 31b02652fa1..172193cc7ae 100644 --- a/programs/notepad/Tr.rc +++ b/programs/notepad/Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT MAIN_MENU MENU diff --git a/programs/notepad/Wa.rc b/programs/notepad/Wa.rc index 1856490b9a7..88f206889ae 100644 --- a/programs/notepad/Wa.rc +++ b/programs/notepad/Wa.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - #ifdef LANG_WALON LANGUAGE LANG_WALON, SUBLANG_DEFAULT diff --git a/programs/notepad/Zh.rc b/programs/notepad/Zh.rc index 005c67d9ce9..040b8cc2263 100644 --- a/programs/notepad/Zh.rc +++ b/programs/notepad/Zh.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "notepad_res.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -214,3 +212,5 @@ STRING_NOTSAVED, "檔案 '%s'\n正文已更改\n\n是否儲存更改?" STRING_NOTFOUND, "找不到: '%s'" STRING_OUT_OF_MEMORY, "沒有足夠的內存來完成此項任務,\n請關閉一些程式後再試。" } + +#pragma code_page(default) diff --git a/programs/notepad/dialog.c b/programs/notepad/dialog.c index 559406922ca..d7354e71521 100644 --- a/programs/notepad/dialog.c +++ b/programs/notepad/dialog.c @@ -26,7 +26,6 @@ #include #include #include -#include #include "main.h" #include "dialog.h" @@ -38,35 +37,6 @@ static const WCHAR helpfileW[] = { 'n','o','t','e','p','a','d','.','h','l','p',0 static INT_PTR WINAPI DIALOG_PAGESETUP_DlgProc(HWND hDlg, UINT msg, WPARAM wParam, LPARAM lParam); -/* Swap bytes of WCHAR buffer (big-endian <-> little-endian). */ -static inline void byteswap_wide_string(LPWSTR str, UINT num) -{ - UINT i; - for (i = 0; i < num; i++) str[i] = RtlUshortByteSwap(str[i]); -} - -static void load_encoding_name(ENCODING enc, WCHAR* buffer, int length) -{ - switch (enc) - { - case ENCODING_UTF16LE: - LoadStringW(Globals.hInstance, STRING_UNICODE_LE, buffer, length); - break; - - case ENCODING_UTF16BE: - LoadStringW(Globals.hInstance, STRING_UNICODE_BE, buffer, length); - break; - - default: - { - CPINFOEXW cpi; - GetCPInfoExW((enc==ENCODING_UTF8) ? CP_UTF8 : CP_ACP, 0, &cpi); - lstrcpynW(buffer, cpi.CodePageName, length); - break; - } - } -} - VOID ShowLastError(void) { DWORD error = GetLastError(); @@ -89,7 +59,7 @@ VOID ShowLastError(void) * Untitled - Notepad if no file is open * filename - Notepad if a file is given */ -void UpdateWindowCaption(void) +static void UpdateWindowCaption(void) { WCHAR szCaption[MAX_STRING_LEN]; WCHAR szNotepad[MAX_STRING_LEN]; @@ -142,23 +112,6 @@ static int AlertFileNotSaved(LPCWSTR szFileName) MB_ICONQUESTION|MB_YESNOCANCEL); } -static int AlertUnicodeCharactersLost(LPCWSTR szFileName) -{ - WCHAR szMsgFormat[MAX_STRING_LEN]; - WCHAR szEnc[MAX_STRING_LEN]; - WCHAR szMsg[ARRAY_SIZE(szMsgFormat) + MAX_PATH + ARRAY_SIZE(szEnc)]; - WCHAR szCaption[MAX_STRING_LEN]; - - LoadStringW(Globals.hInstance, STRING_LOSS_OF_UNICODE_CHARACTERS, - szMsgFormat, ARRAY_SIZE(szMsgFormat)); - load_encoding_name(ENCODING_ANSI, szEnc, ARRAY_SIZE(szEnc)); - wnsprintfW(szMsg, ARRAY_SIZE(szMsg), szMsgFormat, szFileName, szEnc); - LoadStringW(Globals.hInstance, STRING_NOTEPAD, szCaption, - ARRAY_SIZE(szCaption)); - return MessageBoxW(Globals.hMainWnd, szMsg, szCaption, - MB_OKCANCEL|MB_ICONEXCLAMATION); -} - /** * Returns: * TRUE - if file exists @@ -175,115 +128,40 @@ BOOL FileExists(LPCWSTR szFilename) return (hFile != INVALID_HANDLE_VALUE); } -static inline BOOL is_conversion_to_ansi_lossy(LPCWSTR textW, int lenW) -{ - BOOL ret = FALSE; - WideCharToMultiByte(CP_ACP, WC_NO_BEST_FIT_CHARS, textW, lenW, NULL, 0, - NULL, &ret); - return ret; -} - -typedef enum -{ - SAVED_OK, - SAVE_FAILED, - SHOW_SAVEAS_DIALOG -} SAVE_STATUS; -/* szFileName is the filename to save under; enc is the encoding to use. - * - * If the function succeeds, it returns SAVED_OK. - * If the function fails, it returns SAVE_FAILED. - * If Unicode data could be lost due to conversion to a non-Unicode character - * set, a warning is displayed. The user can continue (and the function carries - * on), or cancel (and the function returns SHOW_SAVEAS_DIALOG). - */ -static SAVE_STATUS DoSaveFile(LPCWSTR szFileName, ENCODING enc) +static VOID DoSaveFile(VOID) { - int lenW; - WCHAR* textW; HANDLE hFile; DWORD dwNumWrite; - PVOID pBytes; + LPSTR pTemp; DWORD size; - /* lenW includes the byte-order mark, but not the \0. */ - lenW = GetWindowTextLengthW(Globals.hEdit) + 1; - textW = HeapAlloc(GetProcessHeap(), 0, (lenW+1) * sizeof(WCHAR)); - if (!textW) - { - ShowLastError(); - return SAVE_FAILED; - } - textW[0] = (WCHAR) 0xfeff; - lenW = GetWindowTextW(Globals.hEdit, textW+1, lenW) + 1; - - switch (enc) - { - case ENCODING_UTF16BE: - byteswap_wide_string(textW, lenW); - /* fall through */ - - case ENCODING_UTF16LE: - size = lenW * sizeof(WCHAR); - pBytes = textW; - break; - - case ENCODING_UTF8: - size = WideCharToMultiByte(CP_UTF8, 0, textW, lenW, NULL, 0, NULL, NULL); - pBytes = HeapAlloc(GetProcessHeap(), 0, size); - if (!pBytes) - { - ShowLastError(); - HeapFree(GetProcessHeap(), 0, textW); - return SAVE_FAILED; - } - WideCharToMultiByte(CP_UTF8, 0, textW, lenW, pBytes, size, NULL, NULL); - HeapFree(GetProcessHeap(), 0, textW); - break; - - default: - if (is_conversion_to_ansi_lossy(textW+1, lenW-1) - && AlertUnicodeCharactersLost(szFileName) == IDCANCEL) - { - HeapFree(GetProcessHeap(), 0, textW); - return SHOW_SAVEAS_DIALOG; - } - - size = WideCharToMultiByte(CP_ACP, 0, textW+1, lenW-1, NULL, 0, NULL, NULL); - pBytes = HeapAlloc(GetProcessHeap(), 0, size); - if (!pBytes) - { - ShowLastError(); - HeapFree(GetProcessHeap(), 0, textW); - return SAVE_FAILED; - } - WideCharToMultiByte(CP_ACP, 0, textW+1, lenW-1, pBytes, size, NULL, NULL); - HeapFree(GetProcessHeap(), 0, textW); - break; - } - - hFile = CreateFileW(szFileName, GENERIC_WRITE, FILE_SHARE_WRITE, + hFile = CreateFileW(Globals.szFileName, GENERIC_WRITE, FILE_SHARE_WRITE, NULL, OPEN_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL); if(hFile == INVALID_HANDLE_VALUE) { ShowLastError(); - HeapFree(GetProcessHeap(), 0, pBytes); - return SAVE_FAILED; + return; } - if (!WriteFile(hFile, pBytes, size, &dwNumWrite, NULL)) + + size = GetWindowTextLengthA(Globals.hEdit) + 1; + pTemp = HeapAlloc(GetProcessHeap(), 0, size); + if (!pTemp) { + CloseHandle(hFile); ShowLastError(); - CloseHandle(hFile); - HeapFree(GetProcessHeap(), 0, pBytes); - return SAVE_FAILED; + return; } + size = GetWindowTextA(Globals.hEdit, pTemp, size); + + if (!WriteFile(hFile, pTemp, size, &dwNumWrite, NULL)) + ShowLastError(); + else + SendMessageW(Globals.hEdit, EM_SETMODIFY, FALSE, 0); + SetEndOfFile(hFile); CloseHandle(hFile); - HeapFree(GetProcessHeap(), 0, pBytes); - - SendMessageW(Globals.hEdit, EM_SETMODIFY, FALSE, 0); - return SAVED_OK; + HeapFree(GetProcessHeap(), 0, pTemp); } /** @@ -311,42 +189,20 @@ BOOL DoCloseFile(void) } /* switch */ } /* if */ - SetFileNameAndEncoding(empty_strW, ENCODING_ANSI); + SetFileName(empty_strW); UpdateWindowCaption(); return(TRUE); } -static inline ENCODING detect_encoding_of_buffer(const void* buffer, int size) -{ - static const char bom_utf8[] = { 0xef, 0xbb, 0xbf }; - if (size >= sizeof(bom_utf8) && !memcmp(buffer, bom_utf8, sizeof(bom_utf8))) - return ENCODING_UTF8; - else - { - int flags = IS_TEXT_UNICODE_SIGNATURE | - IS_TEXT_UNICODE_REVERSE_SIGNATURE | - IS_TEXT_UNICODE_ODD_LENGTH; - IsTextUnicode(buffer, size, &flags); - if (flags & IS_TEXT_UNICODE_SIGNATURE) - return ENCODING_UTF16LE; - else if (flags & IS_TEXT_UNICODE_REVERSE_SIGNATURE) - return ENCODING_UTF16BE; - else - return ENCODING_ANSI; - } -} -void DoOpenFile(LPCWSTR szFileName, ENCODING enc) +void DoOpenFile(LPCWSTR szFileName) { static const WCHAR dotlog[] = { '.','L','O','G',0 }; HANDLE hFile; LPSTR pTemp; DWORD size; DWORD dwNumRead; - int lenW; - WCHAR* textW; - int i; WCHAR log[5]; /* Close any files and prompt to save changes */ @@ -368,9 +224,9 @@ void DoOpenFile(LPCWSTR szFileName, ENCODING enc) ShowLastError(); return; } + size++; - /* Extra memory for (WCHAR)'\0'-termination. */ - pTemp = HeapAlloc(GetProcessHeap(), 0, size+2); + pTemp = HeapAlloc(GetProcessHeap(), 0, size); if (!pTemp) { CloseHandle(hFile); @@ -387,67 +243,14 @@ void DoOpenFile(LPCWSTR szFileName, ENCODING enc) } CloseHandle(hFile); + pTemp[dwNumRead] = 0; - size = dwNumRead; - - if (enc == ENCODING_AUTO) - enc = detect_encoding_of_buffer(pTemp, size); - else if (size >= 2 && (enc==ENCODING_UTF16LE || enc==ENCODING_UTF16BE)) - { - /* If UTF-16 (BE or LE) is selected, and there is a UTF-16 BOM, - * override the selection (like native Notepad). - */ - if ((BYTE)pTemp[0] == 0xff && (BYTE)pTemp[1] == 0xfe) - enc = ENCODING_UTF16LE; - else if ((BYTE)pTemp[0] == 0xfe && (BYTE)pTemp[1] == 0xff) - enc = ENCODING_UTF16BE; - } - - switch (enc) - { - case ENCODING_UTF16BE: - byteswap_wide_string((WCHAR*) pTemp, size/sizeof(WCHAR)); - /* Forget whether the file is BE or LE, like native Notepad. */ - enc = ENCODING_UTF16LE; - - /* fall through */ - - case ENCODING_UTF16LE: - textW = (LPWSTR)pTemp; - lenW = size/sizeof(WCHAR); - break; - - default: - { - int cp = (enc==ENCODING_UTF8) ? CP_UTF8 : CP_ACP; - lenW = MultiByteToWideChar(cp, 0, pTemp, size, NULL, 0); - textW = HeapAlloc(GetProcessHeap(), 0, (lenW+1) * sizeof(WCHAR)); - if (!textW) - { - ShowLastError(); - HeapFree(GetProcessHeap(), 0, pTemp); - return; - } - MultiByteToWideChar(cp, 0, pTemp, size, textW, lenW); - HeapFree(GetProcessHeap(), 0, pTemp); - break; - } - } - - /* Replace '\0's with spaces. Other than creating a custom control that - * can deal with '\0' characters, it's the best that can be done. - */ - for (i = 0; i < lenW; i++) - if (textW[i] == '\0') - textW[i] = ' '; - textW[lenW] = '\0'; - - if (lenW >= 1 && textW[0] == 0xfeff) - SetWindowTextW(Globals.hEdit, textW+1); + if((size -1) >= 2 && (BYTE)pTemp[0] == 0xff && (BYTE)pTemp[1] == 0xfe) + SetWindowTextW(Globals.hEdit, (LPWSTR)pTemp + 1); else - SetWindowTextW(Globals.hEdit, textW); + SetWindowTextA(Globals.hEdit, pTemp); - HeapFree(GetProcessHeap(), 0, textW); + HeapFree(GetProcessHeap(), 0, pTemp); SendMessageW(Globals.hEdit, EM_SETMODIFY, FALSE, 0); SendMessageW(Globals.hEdit, EM_EMPTYUNDOBUFFER, 0, 0); @@ -463,7 +266,7 @@ void DoOpenFile(LPCWSTR szFileName, ENCODING enc) SendMessageW(Globals.hEdit, EM_REPLACESEL, TRUE, (LPARAM)lfW); } - SetFileNameAndEncoding(szFileName, enc); + SetFileName(szFileName); UpdateWindowCaption(); } @@ -479,97 +282,6 @@ VOID DIALOG_FileNew(VOID) } } -/* Used to detect encoding of files selected in Open dialog. - * Returns ENCODING_AUTO if file can't be read, etc. - */ -static ENCODING detect_encoding_of_file(LPCWSTR szFileName) -{ - DWORD size; - HANDLE hFile = CreateFileW(szFileName, GENERIC_READ, FILE_SHARE_READ, NULL, - OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL); - if (hFile == INVALID_HANDLE_VALUE) - return ENCODING_AUTO; - size = GetFileSize(hFile, NULL); - if (size == INVALID_FILE_SIZE) - { - CloseHandle(hFile); - return ENCODING_AUTO; - } - else - { - DWORD dwNumRead; - BYTE buffer[MAX_STRING_LEN]; - if (!ReadFile(hFile, buffer, min(size, sizeof(buffer)), &dwNumRead, NULL)) - { - CloseHandle(hFile); - return ENCODING_AUTO; - } - CloseHandle(hFile); - return detect_encoding_of_buffer(buffer, dwNumRead); - } -} - -static UINT_PTR CALLBACK OfnHookProc(HWND hdlg, UINT uMsg, WPARAM wParam, LPARAM lParam) -{ - static HWND hEncCombo; - - switch (uMsg) - { - case WM_INITDIALOG: - { - ENCODING enc; - hEncCombo = GetDlgItem(hdlg, IDC_OFN_ENCCOMBO); - for (enc = MIN_ENCODING; enc <= MAX_ENCODING; enc++) - { - WCHAR szEnc[MAX_STRING_LEN]; - load_encoding_name(enc, szEnc, ARRAY_SIZE(szEnc)); - SendMessageW(hEncCombo, CB_ADDSTRING, 0, (LPARAM)szEnc); - } - SendMessageW(hEncCombo, CB_SETCURSEL, (WPARAM)Globals.encOfnCombo, 0); - } - break; - - case WM_COMMAND: - if (LOWORD(wParam) == IDC_OFN_ENCCOMBO && - HIWORD(wParam) == CBN_SELCHANGE) - { - int index = SendMessageW(hEncCombo, CB_GETCURSEL, 0, 0); - Globals.encOfnCombo = index==CB_ERR ? ENCODING_ANSI : (ENCODING)index; - } - - break; - - case WM_NOTIFY: - switch (((OFNOTIFYW*)lParam)->hdr.code) - { - case CDN_SELCHANGE: - if (Globals.bOfnIsOpenDialog) - { - /* Check the start of the selected file for a BOM. */ - ENCODING enc; - WCHAR szFileName[MAX_PATH]; - SendMessageW(GetParent(hdlg), CDM_GETFILEPATH, - ARRAY_SIZE(szFileName), (LPARAM)szFileName); - enc = detect_encoding_of_file(szFileName); - if (enc != ENCODING_AUTO) - { - Globals.encOfnCombo = enc; - SendMessageW(hEncCombo, CB_SETCURSEL, (WPARAM)enc, 0); - } - } - break; - - default: - break; - } - break; - - default: - break; - } - return 0; -} - VOID DIALOG_FileOpen(VOID) { OPENFILENAMEW openfilename; @@ -590,34 +302,23 @@ VOID DIALOG_FileOpen(VOID) openfilename.lpstrFile = szPath; openfilename.nMaxFile = ARRAY_SIZE(szPath); openfilename.lpstrInitialDir = szDir; - openfilename.Flags = OFN_ENABLETEMPLATE | OFN_ENABLEHOOK | OFN_EXPLORER | - OFN_FILEMUSTEXIST | OFN_PATHMUSTEXIST | - OFN_HIDEREADONLY | OFN_ENABLESIZING; - openfilename.lpfnHook = OfnHookProc; - openfilename.lpTemplateName = MAKEINTRESOURCEW(IDD_OFN_TEMPLATE); + openfilename.Flags = OFN_FILEMUSTEXIST | OFN_PATHMUSTEXIST | + OFN_HIDEREADONLY | OFN_ENABLESIZING; openfilename.lpstrDefExt = szDefaultExt; - Globals.encOfnCombo = ENCODING_ANSI; - Globals.bOfnIsOpenDialog = TRUE; if (GetOpenFileNameW(&openfilename)) - DoOpenFile(openfilename.lpstrFile, Globals.encOfnCombo); + DoOpenFile(openfilename.lpstrFile); } -/* Return FALSE to cancel close */ + BOOL DIALOG_FileSave(VOID) { if (Globals.szFileName[0] == '\0') return DIALOG_FileSaveAs(); else - { - switch (DoSaveFile(Globals.szFileName, Globals.encFile)) - { - case SAVED_OK: return TRUE; - case SHOW_SAVEAS_DIALOG: return DIALOG_FileSaveAs(); - default: return FALSE; - } - } + DoSaveFile(); + return TRUE; } BOOL DIALOG_FileSaveAs(VOID) @@ -640,34 +341,17 @@ BOOL DIALOG_FileSaveAs(VOID) saveas.lpstrFile = szPath; saveas.nMaxFile = ARRAY_SIZE(szPath); saveas.lpstrInitialDir = szDir; - saveas.Flags = OFN_ENABLETEMPLATE | OFN_ENABLEHOOK | OFN_EXPLORER | - OFN_PATHMUSTEXIST | OFN_OVERWRITEPROMPT | - OFN_HIDEREADONLY | OFN_ENABLESIZING; - saveas.lpfnHook = OfnHookProc; - saveas.lpTemplateName = MAKEINTRESOURCEW(IDD_OFN_TEMPLATE); + saveas.Flags = OFN_PATHMUSTEXIST | OFN_OVERWRITEPROMPT | + OFN_HIDEREADONLY | OFN_ENABLESIZING; saveas.lpstrDefExt = szDefaultExt; - /* Preset encoding to what file was opened/saved last with. */ - Globals.encOfnCombo = Globals.encFile; - Globals.bOfnIsOpenDialog = FALSE; - -retry: - if (!GetSaveFileNameW(&saveas)) - return FALSE; - - switch (DoSaveFile(szPath, Globals.encOfnCombo)) - { - case SAVED_OK: - SetFileNameAndEncoding(szPath, Globals.encOfnCombo); - UpdateWindowCaption(); - return TRUE; - - case SHOW_SAVEAS_DIALOG: - goto retry; - - default: - return FALSE; + if (GetSaveFileNameW(&saveas)) { + SetFileName(szPath); + UpdateWindowCaption(); + DoSaveFile(); + return TRUE; } + return FALSE; } typedef struct { diff --git a/programs/notepad/dialog.h b/programs/notepad/dialog.h index 8a784271766..d9271431444 100644 --- a/programs/notepad/dialog.h +++ b/programs/notepad/dialog.h @@ -52,7 +52,6 @@ int DIALOG_StringMsgBox(HWND hParent, int formatId, LPCWSTR szString, DWORD dwFl /* utility functions */ VOID ShowLastError(void); -void UpdateWindowCaption(void); BOOL FileExists(LPCWSTR szFilename); BOOL DoCloseFile(void); -void DoOpenFile(LPCWSTR szFileName, ENCODING enc); +void DoOpenFile(LPCWSTR szFileName); diff --git a/programs/notepad/main.c b/programs/notepad/main.c index d45fac7f098..c195668f4a3 100644 --- a/programs/notepad/main.c +++ b/programs/notepad/main.c @@ -64,18 +64,15 @@ static const WCHAR value_szFooter[] = {'s','z','T','r','a','i','l','e',' /*********************************************************************** * - * SetFileNameAndEncoding + * SetFileName * - * Sets global file name and encoding (which is used to preselect original - * encoding in Save As dialog, and when saving without using the Save As - * dialog). + * Sets Global File Name. */ -VOID SetFileNameAndEncoding(LPCWSTR szFileName, ENCODING enc) +VOID SetFileName(LPCWSTR szFileName) { lstrcpyW(Globals.szFileName, szFileName); Globals.szFileTitle[0] = 0; GetFileTitleW(szFileName, Globals.szFileTitle, sizeof(Globals.szFileTitle)); - Globals.encFile = enc; } /****************************************************************************** @@ -581,7 +578,7 @@ static LRESULT WINAPI NOTEPAD_WndProc(HWND hWnd, UINT msg, WPARAM wParam, DragQueryFileW(hDrop, 0, szFileName, ARRAY_SIZE(szFileName)); DragFinish(hDrop); - DoOpenFile(szFileName, ENCODING_AUTO); + DoOpenFile(szFileName); break; } @@ -607,7 +604,7 @@ static int AlertFileDoesNotExist(LPCWSTR szFileName) LoadStringW(Globals.hInstance, STRING_ERROR, szResource, ARRAY_SIZE(szResource)); nResult = MessageBoxW(Globals.hMainWnd, szMessage, szResource, - MB_ICONEXCLAMATION | MB_YESNOCANCEL); + MB_ICONEXCLAMATION | MB_YESNO); return(nResult); } @@ -692,7 +689,7 @@ static void HandleCommandLine(LPWSTR cmdline) if (file_exists) { - DoOpenFile(file_name, ENCODING_AUTO); + DoOpenFile(file_name); InvalidateRect(Globals.hMainWnd, NULL, FALSE); if (opt_print) DIALOG_FilePrint(); @@ -701,16 +698,11 @@ static void HandleCommandLine(LPWSTR cmdline) { switch (AlertFileDoesNotExist(file_name)) { case IDYES: - SetFileNameAndEncoding(file_name, ENCODING_ANSI); - UpdateWindowCaption(); + DoOpenFile(file_name); break; case IDNO: break; - - case IDCANCEL: - DestroyWindow(Globals.hMainWnd); - break; } } } diff --git a/programs/notepad/main.h b/programs/notepad/main.h index b672be66f5c..f81c437eeb1 100644 --- a/programs/notepad/main.h +++ b/programs/notepad/main.h @@ -25,19 +25,6 @@ #define MAX_STRING_LEN 255 -/* Values are indexes of the items in the Encoding combobox. */ -typedef enum -{ - ENCODING_AUTO = -1, - ENCODING_ANSI = 0, - ENCODING_UTF16LE = 1, - ENCODING_UTF16BE = 2, - ENCODING_UTF8 = 3 -} ENCODING; - -#define MIN_ENCODING 0 -#define MAX_ENCODING 3 - typedef struct { HANDLE hInstance; @@ -51,10 +38,7 @@ typedef struct WCHAR szReplaceText[MAX_PATH]; WCHAR szFileName[MAX_PATH]; WCHAR szFileTitle[MAX_PATH]; - ENCODING encFile; WCHAR szFilter[2 * MAX_STRING_LEN + 100]; - ENCODING encOfnCombo; /* Encoding selected in IDC_OFN_ENCCOMBO */ - BOOL bOfnIsOpenDialog; INT iMarginTop; INT iMarginBottom; INT iMarginLeft; @@ -70,6 +54,6 @@ typedef struct extern NOTEPAD_GLOBALS Globals; -VOID SetFileNameAndEncoding(LPCWSTR szFileName, ENCODING enc); +VOID SetFileName(LPCWSTR szFileName); void NOTEPAD_DoFind(FINDREPLACEW *fr); DWORD get_dpi(void); diff --git a/programs/notepad/notepad_res.h b/programs/notepad/notepad_res.h index 5428c0dc554..8176b855e7f 100644 --- a/programs/notepad/notepad_res.h +++ b/programs/notepad/notepad_res.h @@ -19,9 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include - #define MAIN_MENU 0x201 #define DIALOG_PAGESETUP 0x202 #define ID_ACCEL 0x203 @@ -84,12 +81,3 @@ #define STRING_NOTFOUND 0x17B #define STRING_OUT_OF_MEMORY 0x17C - -#define STRING_UNICODE_LE 0x180 -#define STRING_UNICODE_BE 0x181 - -#define STRING_LOSS_OF_UNICODE_CHARACTERS 0x182 - -/* Open/Save As dialog template */ -#define IDD_OFN_TEMPLATE 0x190 -#define IDC_OFN_ENCCOMBO 0x191 diff --git a/programs/notepad/rsrc.rc b/programs/notepad/rsrc.rc index f796d92d52b..50b3558f5ad 100644 --- a/programs/notepad/rsrc.rc +++ b/programs/notepad/rsrc.rc @@ -17,6 +17,12 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "main.h" +#include "winnls.h" +#include "commctrl.h" #include "notepad_res.h" ID_ACCEL ACCELERATORS @@ -41,3 +47,30 @@ ID_ACCEL ACCELERATORS /* @makedep: notepad.ico */ IDI_NOTEPAD ICON "notepad.ico" + +#include "Bg.rc" +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Eo.rc" +#include "Es.rc" +#include "Fi.rc" +#include "Fr.rc" +#include "Hu.rc" +#include "It.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Lt.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ro.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Th.rc" +#include "Tr.rc" +#include "Wa.rc" +#include "Zh.rc" diff --git a/programs/oleview/Da.rc b/programs/oleview/Da.rc index 04b46e46bf0..02058f626b7 100644 --- a/programs/oleview/Da.rc +++ b/programs/oleview/Da.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT IDM_MENU MENU diff --git a/programs/oleview/De.rc b/programs/oleview/De.rc index afb0b7c9914..d01059687c7 100644 --- a/programs/oleview/De.rc +++ b/programs/oleview/De.rc @@ -19,10 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL IDM_MENU MENU @@ -33,7 +29,7 @@ IDM_MENU MENU MENUITEM "&TypeLib anzeigen...", IDM_TYPELIB MENUITEM SEPARATOR MENUITEM "&Systemkonfiguration...", IDM_SYSCONF - MENUITEM "&Registry-Editor ausführen", IDM_REGEDIT + MENUITEM "&Registry-Editor ausführen", IDM_REGEDIT MENUITEM SEPARATOR MENUITEM "&Beenden", IDM_EXIT } @@ -71,7 +67,7 @@ IDM_MENU MENU } POPUP "&Hilfe" { - MENUITEM "Ü&ber OleView", IDM_ABOUT + MENUITEM "Ü&ber OleView", IDM_ABOUT } } @@ -99,23 +95,23 @@ STRINGTABLE IDS_ABOUT "OleView - OLE/COM Objektbetrachter" IDS_ABOUTVER "Version 1.0" IDS_TYPELIBTITLE "ITypeLib-Betrachter" - IDS_OPEN "Öffnen" + IDS_OPEN "Öffnen" IDS_OPEN_TYPELIB_FILTER "TypeLib Files (*.tlb;*.olb;*.dll;*.ocx;*.exe)\0*.tlb;*.olb;*.dll;*.ocx;*.exe\0All Files (*.*)\0*.*\0\0" IDM_BIND, "An Datei via Datei-Moniker binden" - IDM_TYPELIB, "TypeLib-Datei öffnen und Inhalt betrachten" - IDM_SYSCONF, "Maschinenweite Distributed-COM-Einstellungen ändern" - IDM_REGEDIT, "Wine-Registry-Editor ausführen" - IDM_EXIT, "Anwendung beenden. Frag ob Änderungen zu speichern sind" - IDM_CREATEINST, "Eine Instanz des ausgewählten Objekts erstellen" - IDM_CREATEINSTON, "Eine Instanz des ausgewählten Objekts auf einer bestimmten Maschine erstellen" - IDM_RELEASEINST, "Ausgewählte Objekt-Instanz freigeben" - IDM_COPYCLSID, "GUID des ausgewählten Objekts in die Zwischenablage kopieren" - IDM_VIEW, "Betrachter für ausgewähltes Element anzeigen" - IDM_FLAG_INSERV, "CLSCTX_INPROC_SERVER für Aufruf von CoGetClassObject benutzen" - IDM_FLAG_INHANDL, "CLSCTX_INPROC_HANDLER für Aufruf von CoGetClassObject benutzen" - IDM_FLAG_LOCSERV, "CLSCTX_LOCAL_SERVER für Aufruf von CoGetClassObject benutzen" - IDM_FLAG_REMSERV, "CLSCTX_REMOTE_SERVER für Aufruf von CoGetClassObject benutzen" + IDM_TYPELIB, "TypeLib-Datei öffnen und Inhalt betrachten" + IDM_SYSCONF, "Maschinenweite Distributed-COM-Einstellungen ändern" + IDM_REGEDIT, "Wine-Registry-Editor ausführen" + IDM_EXIT, "Anwendung beenden. Frag ob Änderungen zu speichern sind" + IDM_CREATEINST, "Eine Instanz des ausgewählten Objekts erstellen" + IDM_CREATEINSTON, "Eine Instanz des ausgewählten Objekts auf einer bestimmten Maschine erstellen" + IDM_RELEASEINST, "Ausgewählte Objekt-Instanz freigeben" + IDM_COPYCLSID, "GUID des ausgewählten Objekts in die Zwischenablage kopieren" + IDM_VIEW, "Betrachter für ausgewähltes Element anzeigen" + IDM_FLAG_INSERV, "CLSCTX_INPROC_SERVER für Aufruf von CoGetClassObject benutzen" + IDM_FLAG_INHANDL, "CLSCTX_INPROC_HANDLER für Aufruf von CoGetClassObject benutzen" + IDM_FLAG_LOCSERV, "CLSCTX_LOCAL_SERVER für Aufruf von CoGetClassObject benutzen" + IDM_FLAG_REMSERV, "CLSCTX_REMOTE_SERVER für Aufruf von CoGetClassObject benutzen" IDM_EXPERT, "Zwischen einfachem und Experten-Modus umschalten" IDM_HIDDEN, "Anzeige von nicht als sichtbar angedachten Komponenten-Kategorien umschalten" IDM_TOOLBAR, "Symbolleiste zeigen oder verstecken" @@ -170,7 +166,7 @@ FONT 8, "MS Shell Dlg" LTEXT "Systemeinstellungen", -1, 5, 6, 160, 8 CHECKBOX "&Distributed COM aktivieren", IDC_ENABLEDCOM, 5, 20, 160, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX CHECKBOX "&Remote-Verbindungen aktivieren (nur Win95)", IDC_ENABLEREMOTE, 5, 35, 160, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX - LTEXT "Diese Einstellungen ändern nur Registry-Werte.\nSie haben keinen Einfluss auf die Wine-Performance.", -1, 5, 50, 160, 40 + LTEXT "Diese Einstellungen ändern nur Registry-Werte.\nSie haben keinen Einfluss auf die Wine-Performance.", -1, 5, 50, 160, 40 DEFPUSHBUTTON "&OK", IDOK, 70, 80, 45, 14 PUSHBUTTON "&Abbrechen", IDCANCEL, 120, 80, 45, 14 } diff --git a/programs/oleview/En.rc b/programs/oleview/En.rc index 36dfadaf0f7..700e1d704b6 100644 --- a/programs/oleview/En.rc +++ b/programs/oleview/En.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT IDM_MENU MENU diff --git a/programs/oleview/Fr.rc b/programs/oleview/Fr.rc index 91bbf6933de..56d72505789 100644 --- a/programs/oleview/Fr.rc +++ b/programs/oleview/Fr.rc @@ -1,6 +1,6 @@ /* * OleView (Fr.rc) - * French Language Support + * Frencg Language Support * * Copyright 2006 Jonathan Ernst * @@ -19,11 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL IDM_MENU MENU @@ -33,14 +28,14 @@ IDM_MENU MENU MENUITEM "&Lier au fichier...", IDM_BIND MENUITEM "&Afficher la TypeLib...", IDM_TYPELIB MENUITEM SEPARATOR - MENUITEM "&Configuration système...", IDM_SYSCONF - MENUITEM "&Exécuter l'éditeur de la base de registre", IDM_REGEDIT + MENUITEM "&Configuration système...", IDM_SYSCONF + MENUITEM "&Exécuter l'éditeur de la base de registre", IDM_REGEDIT MENUITEM SEPARATOR MENUITEM "&Quitter", IDM_EXIT } POPUP "&Objet" { - POPUP "Indicateur &CoCreateInstance" + POPUP "&CoCreateInstance Flag" { MENUITEM "CLSCTX_&INPROC_SERVER", IDM_FLAG_INSERV,CHECKED MENUITEM "CLSCTX_INPROC_&HANDLER", IDM_FLAG_INHANDL @@ -50,12 +45,12 @@ IDM_MENU MENU MENUITEM SEPARATOR MENUITEM "Afficher les informations sur le &type", IDM_TYPEINFO, GRAYED MENUITEM SEPARATOR - MENUITEM "Créer une &instance", IDM_CREATEINST, GRAYED - MENUITEM "Créer une instance &sur...", IDM_CREATEINSTON, GRAYED - MENUITEM "&Libérer l'instance", IDM_RELEASEINST, GRAYED + MENUITEM "Créer une &instance", IDM_CREATEINST, GRAYED + MENUITEM "Créer une instance &sur...", IDM_CREATEINSTON, GRAYED + MENUITEM "&Libérer l'instance", IDM_RELEASEINST, GRAYED MENUITEM SEPARATOR MENUITEM "Copier le &CLSID dans le presse-papiers", IDM_COPYCLSID, GRAYED - MENUITEM "Copier la balise &HTML de l'objet dans le presse-papiers", IDM_HTMLTAG, GRAYED + MENUITEM "Copier la balse &HTML de l'objet dans le presse-papiers", IDM_HTMLTAG, GRAYED MENUITEM SEPARATOR MENUITEM "&Afficher...", IDM_VIEW, GRAYED } @@ -63,16 +58,16 @@ IDM_MENU MENU { MENUITEM "Mode &expert", IDM_EXPERT,CHECKED MENUITEM SEPARATOR - MENUITEM "Catégories de composants &cachés", IDM_HIDDEN, GRAYED + MENUITEM "Catégories de compsants &cachés", IDM_HIDDEN, GRAYED MENUITEM SEPARATOR MENUITEM "&Barre d'outils", IDM_TOOLBAR,CHECKED - MENUITEM "Barre d'é&tat", IDM_STATUSBAR,CHECKED + MENUITEM "Barre d'é&tat", IDM_STATUSBAR,CHECKED MENUITEM SEPARATOR MENUITEM "A&ctualiser\tF5", IDM_REFRESH } POPUP "Aid&e" { - MENUITEM "À &propos de OleView", IDM_ABOUT + MENUITEM "À &propos de OleView", IDM_ABOUT } } @@ -88,7 +83,7 @@ IDM_TYPELIB MENU MENUITEM "&Grouper par type", IDM_GROUP MENUITEM SEPARATOR MENUITEM "Barre d'&outils", IDM_TOOLBAR - MENUITEM "&Barre d'état", IDM_STATUSBAR,CHECKED + MENUITEM "&Barre d'état", IDM_STATUSBAR,CHECKED } } @@ -96,97 +91,97 @@ STRINGTABLE { IDS_APPNAME "OleView" IDS_APPTITLE "OleView" - IDS_READY "Prêt" + IDS_READY "Prêt" IDS_ABOUT "OleView - Visionneur d'objets OLE/COM" IDS_ABOUTVER "version 1.0" IDS_TYPELIBTITLE "Visionneur d'ITypeLib" IDS_OPEN "Ouvrir" - IDS_OPEN_TYPELIB_FILTER "Fichiers TypeLib (*.tlb;*.olb;*.dll;*.ocx;*.exe)\0*.tlb;*.olb;*.dll;*.ocx;*.exe\0Tous les fichiers (*.*)\0*.*\0\0" - - IDM_BIND, "Lier à un fichier à l'aide d'un File Moniker" - IDM_TYPELIB, "Ouvrir un fichier TypeLib et afficher son contenu" - IDM_SYSCONF, "Modifier les paramètres COM distribuées pour l'ensemble de la machine" - IDM_REGEDIT, "Exécuter l'éditeur de base de registre de Wine" - IDM_EXIT, "Quitter l'application. Demande s'il faut enregistrer les modifications au préalable" - IDM_CREATEINST, "Créer une instance de l'objet sélectionné" - IDM_CREATEINSTON, "Créer une instance de l'objet sélectionné sur une machine spécifique" - IDM_RELEASEINST, "Libérer l'instance de l'objet actuellement sélectionné" - IDM_COPYCLSID, "Copier le GUID de l'objet actuellement sélectionné dans le presse-papiers" - IDM_VIEW, "Afficher le visionneur pour l'objet actuellement sélectionné" - IDM_FLAG_INSERV, "Utiliser CLSCTX_INPROC_SERVER lors de l'appel à CoGetClassObject" - IDM_FLAG_INHANDL, "Utiliser CLSCTX_INPROC_HANDLER lors de l'appel à CoGetClassObject" - IDM_FLAG_LOCSERV, "Utiliser CLSCTX_LOCAL_SERVER lors de l'appel à CoGetClassObject" - IDM_FLAG_REMSERV, "Utiliser CLSCTX_REMOTE_SERVER lors de l'appel à CoGetClassObject" - IDM_EXPERT, "Basculer entre le mode d'affichage expert et le mode d'affichage débutant" - IDM_HIDDEN, "Activer/désactiver l'affichage des catégories des composant qui ne sont pas prévues pour être visibles" - IDM_TOOLBAR, "Afficher ou masquer la barre d'outils" - IDM_STATUSBAR, "Afficher ou masquer la barre d'état" - IDM_REFRESH, "Actualiser toutes les listes" - IDM_ABOUT, "Afficher les informations sur le programme, le numéro de version et la licence" + IDS_OPEN_TYPELIB_FILTER "TypeLib Files (*.tlb;*.olb;*.dll;*.ocx;*.exe)\0*.tlb;*.olb;*.dll;*.ocx;*.exe\0All Files (*.*)\0*.*\0\0" + + IDM_BIND, "Lie à un fichier à l'aide d'un File Moniker" + IDM_TYPELIB, "Ouvre un fichier TypeLib et afficher son contenu" + IDM_SYSCONF, "Modifie les paramètres COM distribuées pour l'ensemble de la machine" + IDM_REGEDIT, "Exécute l'éditeur de base de registre de Wine" + IDM_EXIT, "Quitte l'application après avoir demandé s'il faut enregistrer les modifications" + IDM_CREATEINST, "Crée une instance de l'objet sélectionné" + IDM_CREATEINSTON, "Crée une instance de l'objet sélectionné sur une machine spécifique" + IDM_RELEASEINST, "Libère l'instance de l'objet actuellement sélectionné" + IDM_COPYCLSID, "Copie le GUID de l'objet actuellement sélectionné dans le presse-papiers" + IDM_VIEW, "Affiche le visionneur pour l'objet actuellement sélectionné" + IDM_FLAG_INSERV, "Utilise CLSCTX_INPROC_SERVER lors de l'appel à CoGetClassObject" + IDM_FLAG_INHANDL, "Utilise CLSCTX_INPROC_HANDLER lors de l'appel à CoGetClassObject" + IDM_FLAG_LOCSERV, "Utilise CLSCTX_LOCAL_SERVER lors de l'appel à CoGetClassObject" + IDM_FLAG_REMSERV, "Utilise CLSCTX_REMOTE_SERVER lors de l'appel à CoGetClassObject" + IDM_EXPERT, "Bascule entre le mode d'affichage expert et le mode d'affichage débutant" + IDM_HIDDEN, "Bascule l'affichage des catégories des composant qui ne sont pas prévue pour être visible" + IDM_TOOLBAR, "Affiche ou masque la barre d'outils" + IDM_STATUSBAR, "Affiche ou masque la barre d'état" + IDM_REFRESH, "Actualise toutes les listes" + IDM_ABOUT, "Affiche les informations sur le programme ; le numéro de version et la licence" IDM_SAVEAS, "Enregistrer en tant que fichier .IDL ou .H" - IDM_CLOSE, "Fermer la fenêtre" - IDM_GROUP, "Grouper les typeinfos par catégorie" + IDM_CLOSE, "Fermer la fenêtre" + IDM_GROUP, "Grouper par typeinfos" - IDS_TREE_OC, "Classes d'objets" - IDS_TREE_GBCC, "Groupés par catégorie de composants" + IDS_TREE_OC, "ObjectClasses" + IDS_TREE_GBCC, "Groupés par catégorie de composants" IDS_TREE_O1O, "Objets OLE 1.0" - IDS_TREE_CLO, "Objets de la bibliothèque COM" + IDS_TREE_CLO, "Objets de la bibliothèque COM" IDS_TREE_AO, "Tous les objets" IDS_TREE_AID, "Identificateurs d'application" - IDS_TREE_TL, "Bibliothèques de types" + IDS_TREE_TL, "Bibliothèques type" IDS_TL_VER, "ver." IDS_TREE_I, "Interfaces" IDS_TAB_REG, "Base de registre" - IDS_TAB_IMPL, "Implémentation" + IDS_TAB_IMPL, "Implémentation" IDS_TAB_ACTIV, "Activation" - IDS_CGCOFAIL, "CoGetClassObject a échoué." + IDS_CGCOFAIL, "CoGetClassObject a échoué." IDS_ERROR_UNKN, "Erreur inconnue" - IDS_TRUE, "Vrai" + IDS_TRUE, "True" IDS_FALSE, "Faux" IDS_BYTES, "octets" - IDS_ERROR_LOADTYPELIB, "Échec de LoadTypeLib( %s ) ($%x)" - IDS_INHERITINTERFACES, "Interfaces héritées" + IDS_ERROR_LOADTYPELIB, "Échec de LoadTypeLib( %s ) ($%x)" + IDS_INHERITINTERFACES, "Interfaces héritées" } DLG_CREATEINSTON DIALOG DISCARDABLE 0, 0, 250, 41 STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "Se connecter à une autre machine" +CAPTION "Se connecter à une autre machine" FONT 8, "MS Shell Dlg" { - LTEXT "Nom de la &machine :", -1, 5, 6, 190, 8 + LTEXT "Nom de la &machine :", -1, 5, 6, 190, 8 EDITTEXT IDC_MACHINE, 5, 16, 190, 12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL DEFPUSHBUTTON "&OK", IDOK, 200, 5, 45, 14 PUSHBUTTON "&Annuler", IDCANCEL, 200, 22, 45, 14 } -DLG_SYSCONF DIALOG DISCARDABLE 0, 0, 210, 100 +DLG_SYSCONF DIALOG DISCARDABLE 0, 0, 170, 100 STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "Configuration système" +CAPTION "Configuration système" FONT 8, "MS Shell Dlg" { - LTEXT "Paramètres système", -1, 5, 6, 160, 8 - CHECKBOX "&Activer le COM distribué", IDC_ENABLEDCOM, 5, 20, 160, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX - CHECKBOX "Activer les connexions à &distance (Win95 uniquement)", IDC_ENABLEREMOTE, 5, 35, 190, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX - LTEXT "Ces paramètres ne font que modifier des valeurs du registre.\nIls n'ont pas d'effet sur les performances de Wine.", -1, 5, 50, 200, 40 - DEFPUSHBUTTON "&OK", IDOK, 100, 80, 45, 14 - PUSHBUTTON "&Annuler", IDCANCEL, 150, 80, 45, 14 + LTEXT "Paramètres système", -1, 5, 6, 160, 8 + CHECKBOX "&Activer le COM distribué", IDC_ENABLEDCOM, 5, 20, 160, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX + CHECKBOX "Activer les connexions à &distance (seulement Win95)", IDC_ENABLEREMOTE, 5, 35, 160, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX + LTEXT "Ces paramètres ne font que modifier les valeurs du registre.\nIls n'ont pas d'effet sur les performances de Wine.", -1, 5, 50, 160, 40 + DEFPUSHBUTTON "&OK", IDOK, 70, 80, 45, 14 + PUSHBUTTON "&Annuler", IDCANCEL, 120, 80, 45, 14 } DLG_DEFAULT_IV DIALOG DISCARDABLE 0, 0, 280, 50 STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "Visionneur d'interface par défaut" +CAPTION "Visionneur d'interface par défaut" FONT 8, "MS Shell Dlg" { LTEXT "Interface", -1, 5, 6, 50, 8 LTEXT "", IDC_LABEL, 60, 6, 145, 8 - LTEXT "IID :", -1, 5, 16, 50, 8 + LTEXT "IID:", -1, 5, 16, 50, 8 LTEXT "", IDC_IDENTIFIER, 60, 16, 165, 8 DEFPUSHBUTTON "&Fermer", IDCANCEL, 230, 6, 45, 14 - PUSHBUTTON "&Afficher les informations de type", IDC_VIEWTYPEINFO, 6, 31, 120, 14, WS_DISABLED + PUSHBUTTON "&Afficher les informations de type", IDC_VIEWTYPEINFO, 6, 31, 70, 14, WS_DISABLED } DLG_IPERSIST_IV DIALOG DISCARDABLE 0, 0, 280, 29 @@ -194,9 +189,9 @@ STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU CAPTION "IPersist Interface Viewer" FONT 8, "MS Shell Dlg" { - LTEXT "Nom de classe :", -1, 5, 6, 50, 8 + LTEXT "Nom de la classe :", -1, 5, 6, 50, 8 LTEXT "", IDC_LABEL, 60, 6, 145, 8 - LTEXT "CLSID :", -1, 5, 16, 50, 8 + LTEXT "CLSID:", -1, 5, 16, 50, 8 LTEXT "", IDC_IDENTIFIER, 60, 16, 165, 8 DEFPUSHBUTTON "&Fermer", IDCANCEL, 230, 6, 45, 14 } @@ -206,9 +201,9 @@ STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU CAPTION "Visionneur d'interface IPersistStream" FONT 8, "MS Shell Dlg" { - LTEXT "Nom de classe :", -1, 5, 6, 50, 8 + LTEXT "Nom de la classe :", -1, 5, 6, 50, 8 LTEXT "", IDC_LABEL, 60, 6, 145, 8 - LTEXT "CLSID :", -1, 5, 16, 50, 8 + LTEXT "CLSID:", -1, 5, 16, 50, 8 LTEXT "", IDC_IDENTIFIER, 60, 16, 165, 8 DEFPUSHBUTTON "&Fermer", IDCANCEL, 230, 6, 45, 14 PUSHBUTTON "&IsDirty", IDC_ISDIRTY_BUTTON, 6, 31, 50, 14 diff --git a/programs/oleview/Ja.rc b/programs/oleview/Ja.rc index 8ed1eac16db..955174ca15f 100644 --- a/programs/oleview/Ja.rc +++ b/programs/oleview/Ja.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -216,3 +214,5 @@ FONT 9, "MS Shell Dlg" PUSHBUTTON "&GetSizeMax", IDC_GETSIZEMAX_BUTTON, 6, 49, 50, 14 LTEXT "???", IDC_GETSIZEMAX, 60, 52, 145, 8 } + +#pragma code_page(default) diff --git a/programs/oleview/Ko.rc b/programs/oleview/Ko.rc index 0df4e7f25cb..e1d61a9ab90 100644 --- a/programs/oleview/Ko.rc +++ b/programs/oleview/Ko.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT IDM_MENU MENU diff --git a/programs/oleview/Lt.rc b/programs/oleview/Lt.rc deleted file mode 100644 index df8dee06f7f..00000000000 --- a/programs/oleview/Lt.rc +++ /dev/null @@ -1,218 +0,0 @@ -/* - * OLE žiūryklė - * Lithuanian Language Support - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -IDM_MENU MENU -{ - POPUP "&Failas" - { - MENUITEM "Susieti su &failu...", IDM_BIND - MENUITEM "&Peržiūrėti TypeLib...", IDM_TYPELIB - MENUITEM SEPARATOR - MENUITEM "&Sistemos konfigūracija...", IDM_SYSCONF - MENUITEM "Paleisti ®istro tvarkytuvę", IDM_REGEDIT - MENUITEM SEPARATOR - MENUITEM "Iš&eiti", IDM_EXIT - } - POPUP "&Objektas" - { - POPUP "&CoCreateInstance žymos bitai" - { - MENUITEM "CLSCTX_&INPROC_SERVER", IDM_FLAG_INSERV,CHECKED - MENUITEM "CLSCTX_INPROC_&HANDLER", IDM_FLAG_INHANDL - MENUITEM "CLSCTX_&LOCAL_SERVER", IDM_FLAG_LOCSERV,CHECKED - MENUITEM "CLSCTX_&REMOTE_SERVER", IDM_FLAG_REMSERV - } - MENUITEM SEPARATOR - MENUITEM "Peržiūrėti &tipų informaciją", IDM_TYPEINFO, GRAYED - MENUITEM SEPARATOR - MENUITEM "Sukurti &egzempliorių", IDM_CREATEINST, GRAYED - MENUITEM "Sukurti egzempliorių &kompiuteryje...", IDM_CREATEINSTON, GRAYED - MENUITEM "&Naikinti egzempliorių", IDM_RELEASEINST, GRAYED - MENUITEM SEPARATOR - MENUITEM "Kopijuoti C&LSID į iškarpinę", IDM_COPYCLSID, GRAYED - MENUITEM "Kopijuoti &HTML objekto gairę į iškarpinę", IDM_HTMLTAG, GRAYED - MENUITEM SEPARATOR - MENUITEM "&Peržiūrėti...", IDM_VIEW, GRAYED - } - POPUP "&Rodinys" - { - MENUITEM "&Eksperto režimas", IDM_EXPERT,CHECKED - MENUITEM SEPARATOR - MENUITEM "&Paslėptų komponentų kategorijos", IDM_HIDDEN, GRAYED - MENUITEM SEPARATOR - MENUITEM "&Įrankių juosta", IDM_TOOLBAR,CHECKED - MENUITEM "&Būsenos juosta", IDM_STATUSBAR,CHECKED - MENUITEM SEPARATOR - MENUITEM "&Atnaujinti\tF5", IDM_REFRESH - } - POPUP "&Žinynas" - { - MENUITEM "&Apie OLE žiūrykę", IDM_ABOUT - } -} - -IDM_TYPELIB MENU -{ - POPUP "&Failas" - { - MENUITEM "Išsaugoti &kaip...", IDM_SAVEAS - MENUITEM "&Užverti", IDM_CLOSE - } - POPUP "&Rodinys" - { - MENUITEM "&Grupuoti pagal rūšį", IDM_GROUP - MENUITEM SEPARATOR - MENUITEM "&Įrankių juosta", IDM_TOOLBAR - MENUITEM "&Būsenos juosta", IDM_STATUSBAR,CHECKED - } -} - -STRINGTABLE -{ - IDS_APPNAME "OLE žiūryklė" - IDS_APPTITLE "OLE žiūryklė" - IDS_READY "Parengta" - IDS_ABOUT "OLE žiūryklė - OLE/COM objektų žiūryklė" - IDS_ABOUTVER "versija 1.0" - IDS_TYPELIBTITLE "ITypeLib žiūryklė" - IDS_OPEN "Atverti" - IDS_OPEN_TYPELIB_FILTER "TypeLib failai (*.tlb;*.olb;*.dll;*.ocx;*.exe)\0*.tlb;*.olb;*.dll;*.ocx;*.exe\0Visi failai (*.*)\0*.*\0\0" - - IDM_BIND, "Susieti su failu per failo vardą" - IDM_TYPELIB, "Atverti TypeLib failą ir peržiūrėti jo turinį" - IDM_SYSCONF, "Keisti paskirstytojo COM kompiuterio nustatymus" - IDM_REGEDIT, "Paleisti Wine registro tvarkytuvę" - IDM_EXIT, "Išeiti iš programos. Paragina išsaugoti pakeitimus" - IDM_CREATEINST, "Sukurti pažymėto objekto egzempliorių" - IDM_CREATEINSTON, "Sukurti pažymėto objekto egzempliorių nurodytame kompiuteryje" - IDM_RELEASEINST, "Naikinti pažymėto objekto egzempliorių" - IDM_COPYCLSID, "Kopijuoti pažymėto elemento GUID į iškarpinę" - IDM_VIEW, "Rodyti žiūryklę pasirinktam elementui" - IDM_FLAG_INSERV, "Naudoti CLSCTX_INPROC_SERVER iškviečiant CoGetClassObject" - IDM_FLAG_INHANDL, "Naudoti CLSCTX_INPROC_HANDLER iškviečiant CoGetClassObject" - IDM_FLAG_LOCSERV, "Naudoti CLSCTX_LOCAL_SERVER iškviečiant CoGetClassObject" - IDM_FLAG_REMSERV, "Naudoti CLSCTX_REMOTE_SERVER iškviečiant CoGetClassObject" - IDM_EXPERT, "Perjungti tarp eksperto ir naujoko rodymo režimų" - IDM_HIDDEN, "Perjungti komponentų kategorijų, kurios turėjo būti nematomos, rodymą" - IDM_TOOLBAR, "Rodyti ar slėpti įrankių juostą" - IDM_STATUSBAR, "Rodyti ar slėpti būsenos juostą" - IDM_REFRESH, "Atnaujinti visus sąrašus" - IDM_ABOUT, "Parodo programos informaciją, versijos numerį ir autoriaus teises" - - IDM_SAVEAS, "Išsaugoti kaip .IDL ar .H failą" - IDM_CLOSE, "Užverti langą" - IDM_GROUP, "Grupuoti tipų informaciją pagal rūšį" - - IDS_TREE_OC, "Objektų klasės" - IDS_TREE_GBCC, "Sugrupuotos pagal komponento kategoriją" - IDS_TREE_O1O, "OLE 1.0 objektai" - IDS_TREE_CLO, "COM bibliotekos objektai" - IDS_TREE_AO, "Visi objektai" - IDS_TREE_AID, "Programų identifikatoriai" - IDS_TREE_TL, "Tipų bibliotekos" - IDS_TL_VER, "ver." - IDS_TREE_I, "Sąsajos" - - IDS_TAB_REG, "Registras" - IDS_TAB_IMPL, "Realizacija" - IDS_TAB_ACTIV, "Aktyvinimas" - - IDS_CGCOFAIL, "CoGetClassObject nepavyko." - IDS_ERROR_UNKN, "Nežinoma klaida" - IDS_TRUE, "Tiesa" - IDS_FALSE, "Netiesa" - IDS_BYTES, "baitai" - - IDS_ERROR_LOADTYPELIB, "LoadTypeLib( %s ) nepavyko ($%x)" - IDS_INHERITINTERFACES, "Paveldėtos sąsajos" -} - -DLG_CREATEINSTON DIALOG DISCARDABLE 0, 0, 250, 41 -STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "Jungtis prie kito kompiuterio" -FONT 8, "MS Shell Dlg" -{ - LTEXT "&Kompiuterio vardas:", -1, 5, 6, 190, 8 - EDITTEXT IDC_MACHINE, 5, 16, 190, 12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL - DEFPUSHBUTTON "&Gerai", IDOK, 200, 5, 45, 14 - PUSHBUTTON "&Atsisakyti", IDCANCEL, 200, 22, 45, 14 -} - -DLG_SYSCONF DIALOG DISCARDABLE 0, 0, 170, 100 -STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "Sistemos konfigūracija" -FONT 8, "MS Shell Dlg" -{ - LTEXT "Sistemos nuostatos", -1, 5, 6, 160, 8 - CHECKBOX "Įjungti &paskirstytąjį COM", IDC_ENABLEDCOM, 5, 20, 160, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX - CHECKBOX "Įjungti &nuotolinį prisijungimą (tik Win95)", IDC_ENABLEREMOTE, 5, 35, 160, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX - LTEXT "Šios nuostatos keičia tik registro reikšmes.\nTai neturi jokios įtakos Wine našumui.", -1, 5, 50, 160, 40 - DEFPUSHBUTTON "&Gerai", IDOK, 70, 80, 45, 14 - PUSHBUTTON "&Atsisakyti", IDCANCEL, 120, 80, 45, 14 -} - -DLG_DEFAULT_IV DIALOG DISCARDABLE 0, 0, 280, 50 -STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "Numatytosios sąsajos žiūryklė" -FONT 8, "MS Shell Dlg" -{ - LTEXT "Sąsaja", -1, 5, 6, 50, 8 - LTEXT "", IDC_LABEL, 60, 6, 145, 8 - LTEXT "IID:", -1, 5, 16, 50, 8 - LTEXT "", IDC_IDENTIFIER, 60, 16, 165, 8 - DEFPUSHBUTTON "&Užverti", IDCANCEL, 230, 6, 45, 14 - PUSHBUTTON "&Peržiūrėti tipų informaciją", IDC_VIEWTYPEINFO, 6, 31, 90, 14, WS_DISABLED -} - -DLG_IPERSIST_IV DIALOG DISCARDABLE 0, 0, 280, 29 -STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "IPersist sąsajos žiūryklė" -FONT 8, "MS Shell Dlg" -{ - LTEXT "Klasės vardas:", -1, 5, 6, 50, 8 - LTEXT "", IDC_LABEL, 60, 6, 145, 8 - LTEXT "CLSID:", -1, 5, 16, 50, 8 - LTEXT "", IDC_IDENTIFIER, 60, 16, 165, 8 - DEFPUSHBUTTON "&Užverti", IDCANCEL, 230, 6, 45, 14 -} - -DLG_IPERSISTSTREAM_IV DIALOG DISCARDABLE 0, 0, 280, 68 -STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "IPersistStream sąsajos žiūryklė" -FONT 8, "MS Shell Dlg" -{ - LTEXT "Klasės vardas:", -1, 5, 6, 50, 8 - LTEXT "", IDC_LABEL, 60, 6, 145, 8 - LTEXT "CLSID:", -1, 5, 16, 50, 8 - LTEXT "", IDC_IDENTIFIER, 60, 16, 165, 8 - DEFPUSHBUTTON "&Užverti", IDCANCEL, 230, 6, 45, 14 - PUSHBUTTON "&IsDirty()", IDC_ISDIRTY_BUTTON, 6, 31, 50, 14 - LTEXT "???", IDC_ISDIRTY, 60, 34, 145, 8 - PUSHBUTTON "&GetSizeMax()", IDC_GETSIZEMAX_BUTTON, 6, 49, 50, 14 - LTEXT "???", IDC_GETSIZEMAX, 60, 52, 145, 8 -} diff --git a/programs/oleview/Makefile.in b/programs/oleview/Makefile.in index d1dad43f51a..2c69eda229b 100644 --- a/programs/oleview/Makefile.in +++ b/programs/oleview/Makefile.in @@ -15,22 +15,7 @@ C_SRCS = \ tree.c \ typelib.c -RC_SRCS = \ - Da.rc \ - De.rc \ - En.rc \ - Fr.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Sv.rc \ - Zh.rc \ - rsrc.rc +RC_SRCS = rsrc.rc @MAKE_PROG_RULES@ diff --git a/programs/oleview/Nl.rc b/programs/oleview/Nl.rc index 6e109af14e5..ed2821d09fa 100644 --- a/programs/oleview/Nl.rc +++ b/programs/oleview/Nl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL IDM_MENU MENU diff --git a/programs/oleview/No.rc b/programs/oleview/No.rc index 5aecd775ef3..f5e885aac84 100644 --- a/programs/oleview/No.rc +++ b/programs/oleview/No.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL IDM_MENU MENU diff --git a/programs/oleview/Pl.rc b/programs/oleview/Pl.rc index d3be5b30d5d..77a0f8a11f9 100644 --- a/programs/oleview/Pl.rc +++ b/programs/oleview/Pl.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT IDM_MENU MENU diff --git a/programs/oleview/Pt.rc b/programs/oleview/Pt.rc index dfc7abac6da..d520f498f08 100644 --- a/programs/oleview/Pt.rc +++ b/programs/oleview/Pt.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL IDM_MENU MENU diff --git a/programs/oleview/Ru.rc b/programs/oleview/Ru.rc index ec3e17f1241..cf63d750d57 100644 --- a/programs/oleview/Ru.rc +++ b/programs/oleview/Ru.rc @@ -19,26 +19,21 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_RUSSIAN IDM_MENU MENU { - POPUP "&Файл" + POPUP "&Ôàéë" { - MENUITEM "П&ривязать к файлу...", IDM_BIND - MENUITEM "&Просмотр TypeLib...", IDM_TYPELIB + MENUITEM "Ï&ðèâÿçàòü ê ôàéëó...", IDM_BIND + MENUITEM "&Ïðîñìîòð TypeLib...", IDM_TYPELIB MENUITEM SEPARATOR - MENUITEM "&Конфигурация системы...", IDM_SYSCONF - MENUITEM "&Запустить Редактор реестра", IDM_REGEDIT + MENUITEM "&Êîíôèãóðàöèÿ ñèñòåìû...", IDM_SYSCONF + MENUITEM "&Çàïóñòèòü Ðåäàêòîð ðååñòðà", IDM_REGEDIT MENUITEM SEPARATOR - MENUITEM "&Выход", IDM_EXIT + MENUITEM "&Âûõîä", IDM_EXIT } - POPUP "&Обьект" + POPUP "&Îáüåêò" { POPUP "&CoCreateInstance Flag" { @@ -48,47 +43,47 @@ IDM_MENU MENU MENUITEM "CLSCTX_&REMOTE_SERVER", IDM_FLAG_REMSERV } MENUITEM SEPARATOR - MENUITEM "Просмотр &Type info", IDM_TYPEINFO, GRAYED + MENUITEM "Ïðîñìîòð &Type info", IDM_TYPEINFO, GRAYED MENUITEM SEPARATOR MENUITEM "Create &Instance", IDM_CREATEINST, GRAYED MENUITEM "Create Instance &On...", IDM_CREATEINSTON, GRAYED MENUITEM "&Release Instance", IDM_RELEASEINST, GRAYED MENUITEM SEPARATOR - MENUITEM "Копировать C&LSID в буфер", IDM_COPYCLSID, GRAYED - MENUITEM "Копировать &HTML object Tag в буфер", IDM_HTMLTAG, GRAYED + MENUITEM "Êîïèðîâàòü C&LSID â áóôåð", IDM_COPYCLSID, GRAYED + MENUITEM "Êîïèðîâàòü &HTML object Tag â áóôåð", IDM_HTMLTAG, GRAYED MENUITEM SEPARATOR - MENUITEM "&Вид...", IDM_VIEW, GRAYED + MENUITEM "&Âèä...", IDM_VIEW, GRAYED } - POPUP "&Вид" + POPUP "&Âèä" { - MENUITEM "&Режим эксперта", IDM_EXPERT,CHECKED + MENUITEM "&Ðåæèì ýêñïåðòà", IDM_EXPERT,CHECKED MENUITEM SEPARATOR MENUITEM "&Hidden component categories", IDM_HIDDEN, GRAYED MENUITEM SEPARATOR - MENUITEM "&Панель инструментов", IDM_TOOLBAR,CHECKED - MENUITEM "&Строка состояния", IDM_STATUSBAR,CHECKED + MENUITEM "&Ïàíåëü èíñòðóìåíòîâ", IDM_TOOLBAR,CHECKED + MENUITEM "&Ñòðîêà ñîñòîÿíèÿ", IDM_STATUSBAR,CHECKED MENUITEM SEPARATOR - MENUITEM "&Обновить\tF5", IDM_REFRESH + MENUITEM "&Îáíîâèòü\tF5", IDM_REFRESH } - POPUP "&Помощь" + POPUP "&Ïîìîùü" { - MENUITEM "&О программе...", IDM_ABOUT + MENUITEM "&Î ïðîãðàììå...", IDM_ABOUT } } IDM_TYPELIB MENU { - POPUP "&Файл" + POPUP "&Ôàéë" { - MENUITEM "&Сохранить как...", IDM_SAVEAS - MENUITEM "&Закрыть", IDM_CLOSE + MENUITEM "&Ñîõðàíèòü êàê...", IDM_SAVEAS + MENUITEM "&Çàêðûòü", IDM_CLOSE } - POPUP "&Вид" + POPUP "&Âèä" { MENUITEM "&Group by type kind", IDM_GROUP MENUITEM SEPARATOR - MENUITEM "&Панель инструментов", IDM_TOOLBAR - MENUITEM "&Строка состояния", IDM_STATUSBAR,CHECKED + MENUITEM "&Ïàíåëü èíñòðóìåíòîâ", IDM_TOOLBAR + MENUITEM "&Ñòðîêà ñîñòîÿíèÿ", IDM_STATUSBAR,CHECKED } } @@ -96,57 +91,57 @@ STRINGTABLE { IDS_APPNAME "OleView" IDS_APPTITLE "OleView" - IDS_READY "Готово" + IDS_READY "Ãîòîâî" IDS_ABOUT "OleView - OLE/COM Object Viewer" - IDS_ABOUTVER "версия 1.0" + IDS_ABOUTVER "âåðñèÿ 1.0" IDS_TYPELIBTITLE "ITypeLib viewer" - IDS_OPEN "Открыть" - IDS_OPEN_TYPELIB_FILTER "Файлы TypeLib (*.tlb;*.olb;*.dll;*.ocx;*.exe)\0*.tlb;*.olb;*.dll;*.ocx;*.exe\0All Files (*.*)\0*.*\0\0" + IDS_OPEN "Îòêðûòü" + IDS_OPEN_TYPELIB_FILTER "Ôàéëû TypeLib (*.tlb;*.olb;*.dll;*.ocx;*.exe)\0*.tlb;*.olb;*.dll;*.ocx;*.exe\0All Files (*.*)\0*.*\0\0" IDM_BIND, "Bind to file via a File Moniker" IDM_TYPELIB, "Open a TypeLib file and view the contents" IDM_SYSCONF, "Change machine wide Distributed COM settings" - IDM_REGEDIT, "Запустить Редактор реестра Wine" - IDM_EXIT, "Выйти из приложения с предложением сохранить изменения" + IDM_REGEDIT, "Çàïóñòèòü Ðåäàêòîð ðååñòðà Wine" + IDM_EXIT, "Âûéòè èç ïðèëîæåíèÿ ñ ïðåäëîæåíèåì ñîõðàíèòü èçìåíåíèÿ" IDM_CREATEINST, "Create an instance of the selected object" IDM_CREATEINSTON, "Create an instance of the selected object on a specific machine" IDM_RELEASEINST, "Release the currently selected object instance" - IDM_COPYCLSID, "Копировать GUID выделенного элемента в буфер" + IDM_COPYCLSID, "Êîïèðîâàòü GUID âûäåëåííîãî ýëåìåíòà â áóôåð" IDM_VIEW, "Display the viewer for the selected item" - IDM_FLAG_INSERV, "Использовать CLSCTX_INPROC_SERVER при вызове CoGetClassObject" - IDM_FLAG_INHANDL, "Использовать CLSCTX_INPROC_HANDLER при вызове CoGetClassObject" - IDM_FLAG_LOCSERV, "Использовать CLSCTX_LOCAL_SERVER при вызове CoGetClassObject" - IDM_FLAG_REMSERV, "Использовать CLSCTX_REMOTE_SERVER при вызове CoGetClassObject" - IDM_EXPERT, "Переключиться между режимом эксперт/новичок" + IDM_FLAG_INSERV, "Èñïîëüçîâàòü CLSCTX_INPROC_SERVER ïðè âûçîâå CoGetClassObject" + IDM_FLAG_INHANDL, "Èñïîëüçîâàòü CLSCTX_INPROC_HANDLER ïðè âûçîâå CoGetClassObject" + IDM_FLAG_LOCSERV, "Èñïîëüçîâàòü CLSCTX_LOCAL_SERVER ïðè âûçîâå CoGetClassObject" + IDM_FLAG_REMSERV, "Èñïîëüçîâàòü CLSCTX_REMOTE_SERVER ïðè âûçîâå CoGetClassObject" + IDM_EXPERT, "Ïåðåêëþ÷èòüñÿ ìåæäó ðåæèìîì ýêñïåðò/íîâè÷îê" IDM_HIDDEN, "Toggle the display of component categories that are not meant to be visible" - IDM_TOOLBAR, "Показать/скрыть панель инструментов" - IDM_STATUSBAR, "Показать/скрыть строку состояния" - IDM_REFRESH, "Обновить все списки" - IDM_ABOUT, "Отобразить информацию о программе, номер версии и копирайт" + IDM_TOOLBAR, "Ïîêàçàòü/ñêðûòü ïàíåëü èíñòðóìåíòîâ" + IDM_STATUSBAR, "Ïîêàçàòü/ñêðûòü ñòðîêó ñîñòîÿíèÿ" + IDM_REFRESH, "Îáíîâèòü âñå ñïèñêè" + IDM_ABOUT, "Îòîáðàçèòü èíôîðìàöèþ î ïðîãðàììå, íîìåð âåðñèè è êîïèðàéò" - IDM_SAVEAS, "Сохранить как .IDL или .H файл" - IDM_CLOSE, "Закрыть окно" + IDM_SAVEAS, "Ñîõðàíèòü êàê .IDL èëè .H ôàéë" + IDM_CLOSE, "Çàêðûòü îêíî" IDM_GROUP, "Group typeinfos by kind" IDS_TREE_OC, "ObjectClasses" IDS_TREE_GBCC, "Grouped by Component Category" - IDS_TREE_O1O, "Объекты OLE 1.0" - IDS_TREE_CLO, "Объекты библиотеки COM" - IDS_TREE_AO, "Все объекты" - IDS_TREE_AID, "ID приложения" + IDS_TREE_O1O, "Îáúåêòû OLE 1.0" + IDS_TREE_CLO, "Îáúåêòû áèáëèîòåêè COM" + IDS_TREE_AO, "Âñå îáúåêòû" + IDS_TREE_AID, "ID ïðèëîæåíèÿ" IDS_TREE_TL, "Type Libraries" - IDS_TL_VER, "вер." - IDS_TREE_I, "Интерфейсы" + IDS_TL_VER, "âåð." + IDS_TREE_I, "Èíòåðôåéñû" - IDS_TAB_REG, "Реестр" + IDS_TAB_REG, "Ðååñòð" IDS_TAB_IMPL, "Implementation" IDS_TAB_ACTIV, "Activation" IDS_CGCOFAIL, "CoGetClassObject failed." - IDS_ERROR_UNKN, "Неизвестная ошибка" + IDS_ERROR_UNKN, "Íåèçâåñòíàÿ îøèáêà" IDS_TRUE, "True" IDS_FALSE, "False" - IDS_BYTES, "байт" + IDS_BYTES, "áàéò" IDS_ERROR_LOADTYPELIB, "LoadTypeLib( %s ) failed ($%x)" IDS_INHERITINTERFACES, "Inherited Interfaces" @@ -154,26 +149,26 @@ STRINGTABLE DLG_CREATEINSTON DIALOG DISCARDABLE 0, 0, 250, 41 STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "Подключиться к другому компьютеру" +CAPTION "Ïîäêëþ÷èòüñÿ ê äðóãîìó êîìïüþòåðó" FONT 8, "MS Shell Dlg" { - LTEXT "&Имя компьютера:", -1, 5, 6, 190, 8 + LTEXT "&Èìÿ êîìïüþòåðà:", -1, 5, 6, 190, 8 EDITTEXT IDC_MACHINE, 5, 16, 190, 12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL DEFPUSHBUTTON "&OK", IDOK, 200, 5, 45, 14 - PUSHBUTTON "&Отмена", IDCANCEL, 200, 22, 45, 14 + PUSHBUTTON "&Îòìåíà", IDCANCEL, 200, 22, 45, 14 } DLG_SYSCONF DIALOG DISCARDABLE 0, 0, 170, 100 STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "Конфигурация системы" +CAPTION "Êîíôèãóðàöèÿ ñèñòåìû" FONT 8, "MS Shell Dlg" { - LTEXT "Настройки системы", -1, 5, 6, 160, 8 - CHECKBOX "&Разрешить распределенный COM", IDC_ENABLEDCOM, 5, 20, 160, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX - CHECKBOX "Разрешить &удаленные подключения (только Win95)", IDC_ENABLEREMOTE, 5, 35, 160, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX - LTEXT "Эти настройки изменяют только значения реестра и не оказывают влияния на производительность Wine.", -1, 5, 50, 160, 40 + LTEXT "Íàñòðîéêè ñèñòåìû", -1, 5, 6, 160, 8 + CHECKBOX "&Ðàçðåøèòü ðàñïðåäåëåííûé COM", IDC_ENABLEDCOM, 5, 20, 160, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX + CHECKBOX "Ðàçðåøèòü &óäàëåííûå ïîäêëþ÷åíèÿ (òîëüêî Win95)", IDC_ENABLEREMOTE, 5, 35, 160, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX + LTEXT "Ýòè íàñòðîéêè èçìåíÿþò òîëüêî çíà÷åíèÿ ðååñòðà è íå îêàçûâàþò âëèÿíèÿ íà ïðîèçâîäèòåëüíîñòü Wine.", -1, 5, 50, 160, 40 DEFPUSHBUTTON "&OK", IDOK, 70, 80, 45, 14 - PUSHBUTTON "&Отмена", IDCANCEL, 120, 80, 45, 14 + PUSHBUTTON "&Îòìåíà", IDCANCEL, 120, 80, 45, 14 } DLG_DEFAULT_IV DIALOG DISCARDABLE 0, 0, 280, 50 @@ -181,11 +176,11 @@ STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU CAPTION "Default Interface Viewer" FONT 8, "MS Shell Dlg" { - LTEXT "Интерфейс", -1, 5, 6, 50, 8 + LTEXT "Èíòåðôåéñ", -1, 5, 6, 50, 8 LTEXT "", IDC_LABEL, 60, 6, 145, 8 LTEXT "IID:", -1, 5, 16, 50, 8 LTEXT "", IDC_IDENTIFIER, 60, 16, 165, 8 - DEFPUSHBUTTON "&Закрыть", IDCANCEL, 230, 6, 45, 14 + DEFPUSHBUTTON "&Çàêðûòü", IDCANCEL, 230, 6, 45, 14 PUSHBUTTON "&View Type Info", IDC_VIEWTYPEINFO, 6, 31, 70, 14, WS_DISABLED } @@ -194,11 +189,11 @@ STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU CAPTION "IPersist Interface Viewer" FONT 8, "MS Shell Dlg" { - LTEXT "Имя класса:", -1, 5, 6, 50, 8 + LTEXT "Èìÿ êëàññà:", -1, 5, 6, 50, 8 LTEXT "", IDC_LABEL, 60, 6, 145, 8 LTEXT "CLSID:", -1, 5, 16, 50, 8 LTEXT "", IDC_IDENTIFIER, 60, 16, 165, 8 - DEFPUSHBUTTON "&Закрыть", IDCANCEL, 230, 6, 45, 14 + DEFPUSHBUTTON "&Çàêðûòü", IDCANCEL, 230, 6, 45, 14 } DLG_IPERSISTSTREAM_IV DIALOG DISCARDABLE 0, 0, 280, 68 @@ -206,11 +201,11 @@ STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU CAPTION "IPersistStream Interface Viewer" FONT 8, "MS Shell Dlg" { - LTEXT "Имя класса:", -1, 5, 6, 50, 8 + LTEXT "Èìÿ êëàññà:", -1, 5, 6, 50, 8 LTEXT "", IDC_LABEL, 60, 6, 145, 8 LTEXT "CLSID:", -1, 5, 16, 50, 8 LTEXT "", IDC_IDENTIFIER, 60, 16, 165, 8 - DEFPUSHBUTTON "&Закрыть", IDCANCEL, 230, 6, 45, 14 + DEFPUSHBUTTON "&Çàêðûòü", IDCANCEL, 230, 6, 45, 14 PUSHBUTTON "&IsDirty", IDC_ISDIRTY_BUTTON, 6, 31, 50, 14 LTEXT "???", IDC_ISDIRTY, 60, 34, 145, 8 PUSHBUTTON "&GetSizeMax", IDC_GETSIZEMAX_BUTTON, 6, 49, 50, 14 diff --git a/programs/oleview/Sv.rc b/programs/oleview/Sv.rc index be9c053f7ce..ed121f1b5c4 100644 --- a/programs/oleview/Sv.rc +++ b/programs/oleview/Sv.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL IDM_MENU MENU diff --git a/programs/oleview/Zh.rc b/programs/oleview/Zh.rc index 4d0f7127dca..8f9b59c5c1f 100644 --- a/programs/oleview/Zh.rc +++ b/programs/oleview/Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -408,3 +406,5 @@ FONT 9, "MS Shell Dlg" PUSHBUTTON "獲取最大(&G)", IDC_GETSIZEMAX_BUTTON, 6, 49, 50, 14 LTEXT "???", IDC_GETSIZEMAX, 60, 52, 145, 8 } + +#pragma code_page(default) diff --git a/programs/oleview/resource.h b/programs/oleview/resource.h index 9e732e6f08c..e88ec050539 100644 --- a/programs/oleview/resource.h +++ b/programs/oleview/resource.h @@ -18,9 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include - #define IDS_APPNAME 1 #define IDS_APPTITLE 2 #define IDM_MENU 3 diff --git a/programs/oleview/rsrc.rc b/programs/oleview/rsrc.rc index 20537f3ffdf..3f36889dabc 100644 --- a/programs/oleview/rsrc.rc +++ b/programs/oleview/rsrc.rc @@ -18,8 +18,25 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include +#include + #include "resource.h" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Fr.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Sv.rc" +#include "Zh.rc" + LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL IDA_OLEVIEW ACCELERATORS DISCARDABLE diff --git a/programs/progman/Cs.rc b/programs/progman/Cs.rc index 06139b928a9..07838b000c3 100644 --- a/programs/progman/Cs.rc +++ b/programs/progman/Cs.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - /* Czech strings in CP1250 */ /* Menu */ diff --git a/programs/progman/Da.rc b/programs/progman/Da.rc index 7e1438d71e1..b99c5f59ee3 100644 --- a/programs/progman/Da.rc +++ b/programs/progman/Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT /* Menu */ diff --git a/programs/progman/De.rc b/programs/progman/De.rc index 4c09164015e..c94328cd425 100644 --- a/programs/progman/De.rc +++ b/programs/progman/De.rc @@ -20,23 +20,19 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - -#pragma code_page(65001) - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL { POPUP "&Datei" { MENUITEM "&Neu...", PM_NEW - MENUITEM "Ö&ffnen\tEingabetaste", PM_OPEN + MENUITEM "Ö&ffnen\tEingabetaste", PM_OPEN MENUITEM "&Verschieben...\tF7", PM_MOVE, GRAYED MENUITEM "&Kopieren...\tF8", PM_COPY, GRAYED - MENUITEM "&Löschen\tEntf", PM_DELETE + MENUITEM "&Löschen\tEntf", PM_DELETE MENUITEM "&Eigenschaften...\tAlt+Eingabetaste", PM_ATTRIBUTES MENUITEM SEPARATOR - MENUITEM "&Ausführen...", PM_EXECUTE + MENUITEM "&Ausführen...", PM_EXECUTE MENUITEM SEPARATOR MENUITEM "&Programm-Manager beenden...", PM_EXIT } @@ -46,7 +42,7 @@ MAIN_MENU MENU LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL MENUITEM "&Einstellungen beim Beenden speichern", PM_SAVE_SETTINGS } POPUP "&Fenster" { - MENUITEM "Über&lappend\tUmschalt+F5", PM_OVERLAP + MENUITEM "Über&lappend\tUmschalt+F5", PM_OVERLAP MENUITEM "&Nebeneinander\tUmschalt+F4", PM_SIDE_BY_SIDE MENUITEM "&Symbole anordnen", PM_ARRANGE } @@ -62,7 +58,7 @@ POPUP "&Hilfe" { POPUP "&Info..." { MENUITEM "&Lizenz", PM_LICENSE MENUITEM "&KEINE GARANTIE", PM_NO_WARRANTY - MENUITEM "Ü&ber WINE", PM_ABOUT_WINE + MENUITEM "Ü&ber WINE", PM_ABOUT_WINE } } } @@ -165,7 +161,7 @@ PUSHBUTTON "&Hilfe", PM_HELP, 185, 85, 60, 15, W DIALOG_SYMBOL DIALOG 0, 0, 200, 85 LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Symbol auswählen" +CAPTION "Symbol auswählen" { LTEXT "Datei&name:", PM_ICON_FILE_TXT, 5, 15, 40, 10 EDITTEXT PM_ICON_FILE, 45, 15, 85, 12, WS_TABSTOP @@ -183,7 +179,7 @@ PUSHBUTTON "&Hilfe", PM_HELP, 135, 65, 60, 15, WS_TABSTOP DIALOG_EXECUTE DIALOG 0, 0, 200, 85 LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Programm ausführen" +CAPTION "Programm ausführen" { LTEXT "&Befehlszeile:", -1, 05, 15, 120, 10 EDITTEXT PM_COMMAND, 05, 25, 120, 12, WS_TABSTOP @@ -203,18 +199,18 @@ IDS_PROGRAM_MANAGER, "Programm-Manager" IDS_ERROR, "FEHLER" IDS_WARNING, "ACHTUNG" IDS_INFO, "Information" -IDS_DELETE, "Löschen" -IDS_DELETE_GROUP_s, "Lösche Programmgruppe „%s“?" -IDS_DELETE_PROGRAM_s, "Lösche Programm „%s“?" +IDS_DELETE, "Löschen" +IDS_DELETE_GROUP_s, "Lösche Programmgruppe „%s“?" +IDS_DELETE_PROGRAM_s, "Lösche Programm „%s“?" IDS_NOT_IMPLEMENTED, "Nicht implementiert" -IDS_FILE_READ_ERROR_s, "Fehler beim Lesen von „%s“." -IDS_FILE_WRITE_ERROR_s, "Fehler beim Schreiben von „%s“." -IDS_GRPFILE_READ_ERROR_s, "Die Programmgruppendatei „%s“ kann nicht geöffnet werden.\n\Soll weiterhin versucht werden, diese Datei zu laden?" +IDS_FILE_READ_ERROR_s, "Fehler beim Lesen von „%s“." +IDS_FILE_WRITE_ERROR_s, "Fehler beim Schreiben von „%s“." +IDS_GRPFILE_READ_ERROR_s, "Die Programmgruppendatei „%s“ kann nicht geöffnet werden.\n\Soll weiterhin versucht werden, diese Datei zu laden?" IDS_OUT_OF_MEMORY, "Zu wenig Hauptspeicher." -IDS_WINHELP_ERROR, "Keine Hilfe verfügbar." +IDS_WINHELP_ERROR, "Keine Hilfe verfügbar." IDS_UNKNOWN_FEATURE_s, "Unbekannte Eigenschaft in %s" -IDS_FILE_NOT_OVERWRITTEN_s, "Datei „%s“ existiert. Sie wird nicht überschrieben." -IDS_SAVE_GROUP_AS_s, "Die Programmgruppe wird als „%s“ gesichert, um das Überschreiben der Originaldatei zu verhindern." +IDS_FILE_NOT_OVERWRITTEN_s, "Datei „%s“ existiert. Sie wird nicht überschrieben." +IDS_SAVE_GROUP_AS_s, "Die Programmgruppe wird als „%s“ gesichert, um das Überschreiben der Originaldatei zu verhindern." IDS_NO_HOT_KEY, "Keine" IDS_ALL_FILES, "Alle Dateien (*.*)" IDS_PROGRAMS, "Programme" @@ -227,15 +223,15 @@ STRINGTABLE DISCARDABLE LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL { IDS_LICENSE_CAPTION, "LIZENZ" IDS_LICENSE, -"Diese Bibliothek ist freie Software; Sie dürfen sie unter den \ +"Diese Bibliothek ist freie Software; Sie dürfen sie unter den \ Bedingungen der GNU Lesser General Public License, wie von der \ -Free Software Foundation veröffentlicht, weiterverteilen und/oder \ -modifizieren; entweder gemäß Version 2.1 der Lizenz oder (nach \ -Ihrer Option) jeder späteren Version.\n\ -Diese Bibliothek wird in der Hoffnung weiterverbreitet, daß sie \ -nützlich sein wird, jedoch OHNE IRGENDEINE GARANTIE, auch ohne \ +Free Software Foundation veröffentlicht, weiterverteilen und/oder \ +modifizieren; entweder gemäß Version 2.1 der Lizenz oder (nach \ +Ihrer Option) jeder späteren Version.\n\ +Diese Bibliothek wird in der Hoffnung weiterverbreitet, daß sie \ +nützlich sein wird, jedoch OHNE IRGENDEINE GARANTIE, auch ohne \ die implizierte Garantie der MARKTREIFE oder der VERWENDBARKEIT \ -FÜR EINEN BESTIMMTEN ZWECK. Mehr Details finden Sie in der \ +FÜR EINEN BESTIMMTEN ZWECK. Mehr Details finden Sie in der \ GNU Lesser General Public License.\n\ Sie sollten eine Kopie der GNU Lesser General Public License zusammen \ mit dieser Bibliothek erhalten haben; falls nicht, schreiben Sie an \ @@ -244,8 +240,8 @@ Boston, MA 02110, USA." IDS_WARRANTY_CAPTION, "KEINE GARANTIE" IDS_WARRANTY, -"Diese Bibliothek wird in der Hoffnung weiterverbreitet, daß sie nützlich \ +"Diese Bibliothek wird in der Hoffnung weiterverbreitet, daß sie nützlich \ sein wird, jedoch OHNE IRGENDEINE GARANTIE, auch ohne die implizierte Garantie \ -der MARKTREIFE oder der VERWENDBARKEIT FÜR EINEN BESTIMMTEN ZWECK. Mehr Details \ +der MARKTREIFE oder der VERWENDBARKEIT FÜR EINEN BESTIMMTEN ZWECK. Mehr Details \ finden Sie in der GNU Lesser General Public License." } diff --git a/programs/progman/En.rc b/programs/progman/En.rc index bd6aaaa4f6c..201decae5c4 100644 --- a/programs/progman/En.rc +++ b/programs/progman/En.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT diff --git a/programs/progman/Es.rc b/programs/progman/Es.rc index 28883540335..391a5e58236 100644 --- a/programs/progman/Es.rc +++ b/programs/progman/Es.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL /* Menu */ diff --git a/programs/progman/Fr.rc b/programs/progman/Fr.rc index 658f21914c0..39b34617e6c 100644 --- a/programs/progman/Fr.rc +++ b/programs/progman/Fr.rc @@ -4,7 +4,7 @@ * Copyright 1996 Ulrich Schmid * French Fr.rc by Pablo Saratxaga * Copyright 2002 Sylvain Petreolle - * Copyright 2006 Jonathan Ernst + * Copyright 2006 Jonathan Ernst * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -21,11 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL /* Menu */ @@ -34,25 +29,25 @@ MAIN_MENU MENU { POPUP "&Fichier" { MENUITEM "&Nouveau...", PM_NEW - MENUITEM "O&uvrir\tEntrée", PM_OPEN - MENUITEM "&Déplacer...\tF7", PM_MOVE, GRAYED + MENUITEM "O&uvrir\tEntrée", PM_OPEN + MENUITEM "&Déplacer...\tF7", PM_MOVE, GRAYED MENUITEM "&Copier...\tF8", PM_COPY, GRAYED MENUITEM "&Supprimer\tSuppr", PM_DELETE - MENUITEM "&Propriétés...\tAlt+Entrée", PM_ATTRIBUTES + MENUITEM "&Propriétés...\tAlt+Entrée", PM_ATTRIBUTES MENUITEM SEPARATOR - MENUITEM "E&xécuter...", PM_EXECUTE + MENUITEM "E&xécuter...", PM_EXECUTE MENUITEM SEPARATOR MENUITEM "&Quitter Windows...", PM_EXIT } POPUP "&Options" { - MENUITEM "Réorg&anisation automatique", PM_AUTO_ARRANGE - MENUITEM "&Réduire à l'utilisation", PM_MIN_ON_RUN + MENUITEM "Réorg&anisation automatique", PM_AUTO_ARRANGE + MENUITEM "&Réduire à l'utilisation", PM_MIN_ON_RUN MENUITEM "&Enregistrer la configuration en quittant", PM_SAVE_SETTINGS } - POPUP "F&enêtres" { + POPUP "F&enêtres" { MENUITEM "&Cascade\tMaj+F5", PM_OVERLAP - MENUITEM "&Mosaïque\tMaj+F4", PM_SIDE_BY_SIDE - MENUITEM "&Réorganiser les icônes", PM_ARRANGE + MENUITEM "&Mosaïque\tMaj+F4", PM_SIDE_BY_SIDE + MENUITEM "&Réorganiser les icônes", PM_ARRANGE } POPUP "Aid&e" { @@ -66,7 +61,7 @@ MAIN_MENU MENU POPUP "&Info..." { MENUITEM "&Licence", PM_LICENSE MENUITEM "AUCUNE &GARANTIE", PM_NO_WARRANTY - MENUITEM "À &propos de Wine", PM_ABOUT_WINE + MENUITEM "À &propos de Wine", PM_ABOUT_WINE } } } @@ -90,13 +85,13 @@ PUSHBUTTON "Aid&e", PM_HELP, 105, 45, 60, 15, WS_TABSTOP DIALOG_MOVE DIALOG 0, 0, 250, 65 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Déplacer un programme" +CAPTION "Déplacer un programme" { -LTEXT "Déplacer le programme :", -1, 5, 5, 90, 15 +LTEXT "Déplacer le programme :", -1, 5, 5, 90, 15 LTEXT "", PM_PROGRAM, 95, 5, 90, 15 -LTEXT "À partir du groupe :", -1, 5, 13, 90, 15 +LTEXT "À partir du groupe :", -1, 5, 13, 90, 15 LTEXT "", PM_FROM_GROUP, 95, 13, 90, 15 -LTEXT "&Vers le groupe :", PM_TO_GROUP_TXT, 5, 28, 140, 15 +LTEXT "&Vers le groupe :", PM_TO_GROUP_TXT, 5, 28, 140, 15 COMBOBOX PM_TO_GROUP, 5, 38, 140, 50, WS_TABSTOP | CBS_DROPDOWNLIST DEFPUSHBUTTON "OK", IDOK, 185, 5, 60, 15, WS_TABSTOP PUSHBUTTON "Annuler", IDCANCEL, 185, 25, 60, 15, WS_TABSTOP @@ -109,11 +104,11 @@ DIALOG_COPY DIALOG 0, 0, 250, 65 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Copier un programme" { -LTEXT "Copier le programme :", -1, 5, 5, 90, 15 +LTEXT "Copier le programme :", -1, 5, 5, 90, 15 LTEXT "", PM_PROGRAM, 95, 5, 90, 15 -LTEXT "À partir du groupe :", -1, 5, 13, 90, 15 +LTEXT "À partir du groupe :", -1, 5, 13, 90, 15 LTEXT "", PM_FROM_GROUP, 95, 13, 90, 15 -LTEXT "&Vers le groupe :", PM_TO_GROUP_TXT, 5, 28, 140, 15 +LTEXT "&Vers le groupe :", PM_TO_GROUP_TXT, 5, 28, 140, 15 COMBOBOX PM_TO_GROUP, 5, 38, 140, 50, WS_TABSTOP | CBS_DROPDOWNLIST DEFPUSHBUTTON "OK", IDOK, 185, 5, 60, 15, WS_TABSTOP PUSHBUTTON "Annuler", IDCANCEL, 185, 25, 60, 15, WS_TABSTOP @@ -124,38 +119,38 @@ PUSHBUTTON "Aid&e", PM_HELP, 185, 45, 60, 15, WS_TABSTO DIALOG_GROUP DIALOG 0, 0, 230, 65 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Propriétés de groupe" +CAPTION "Propriétés de groupe" { -LTEXT "&Nom :", PM_DESCRIPTION_TXT, 05, 20, 59, 10 -EDITTEXT PM_DESCRIPTION, 70, 18, 90, 15, WS_TABSTOP -LTEXT "&Fichier du groupe :", PM_FILE_TXT, 05, 40, 63, 10 -EDITTEXT PM_FILE, 70, 38, 90, 15, WS_TABSTOP -DEFPUSHBUTTON "OK", IDOK, 165, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Annuler", IDCANCEL, 165, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "Aid&e", PM_HELP, 165, 45, 60, 15, WS_TABSTOP +LTEXT "&Nom :", PM_DESCRIPTION_TXT, 05, 18, 50, 10 +EDITTEXT PM_DESCRIPTION, 60, 18, 90, 15, WS_TABSTOP +LTEXT "&Fichier du groupe :", PM_FILE_TXT, 05, 38, 50, 10 +EDITTEXT PM_FILE, 60, 38, 90, 15, WS_TABSTOP +DEFPUSHBUTTON "OK", IDOK, 155, 5, 60, 15, WS_TABSTOP +PUSHBUTTON "Annuler", IDCANCEL, 155, 25, 60, 15, WS_TABSTOP +PUSHBUTTON "Aid&e", PM_HELP, 155, 45, 60, 15, WS_TABSTOP } /* Dialog `Program attributes' */ DIALOG_PROGRAM DIALOG 0, 0, 250, 105 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Propriétés de programme" +CAPTION "Propriétés de programme" { -LTEXT "&Nom :", PM_DESCRIPTION_TXT, 05, 11, 60, 10 +LTEXT "&Nom :", PM_DESCRIPTION_TXT, 05, 10, 60, 10 EDITTEXT PM_DESCRIPTION, 80, 10, 90, 15, WS_TABSTOP -LTEXT "&Ligne de commande :", PM_COMMAND_LINE_TXT, 05, 26, 74, 10 +LTEXT "&Ligne de commande :", PM_COMMAND_LINE_TXT, 05, 25, 60, 10 EDITTEXT PM_COMMAND_LINE, 80, 25, 90, 15, WS_TABSTOP -LTEXT "Répertoire de tra&vail :", PM_DIRECTORY_TXT, 05, 42, 74, 10 +LTEXT "Répertoire de tra&vail :", PM_DIRECTORY_TXT, 05, 40, 60, 10 EDITTEXT PM_DIRECTORY, 80, 40, 90, 15, WS_TABSTOP -LTEXT "&Touche de raccourci :", PM_HOT_KEY_TXT, 05, 56, 74, 10 +LTEXT "&Touche de raccourci :", PM_HOT_KEY_TXT, 05, 55, 60, 10 EDITTEXT PM_HOT_KEY, 80, 55, 90, 15, WS_TABSTOP -ICON "", PM_ICON, 20, 72 +ICON "", PM_ICON, 20, 70 CHECKBOX "", PM_SYMBOL, 80, 75, 10, 10, WS_TABSTOP -LTEXT "Réduire à l'&utilisation", -1, 95, 75, 75, 10 +LTEXT "Réduire à l'&utilisation", -1, 95, 75, 75, 10 DEFPUSHBUTTON "OK", IDOK, 185, 5, 60, 15, WS_TABSTOP PUSHBUTTON "Annuler", IDCANCEL, 185, 25, 60, 15, WS_TABSTOP PUSHBUTTON "Pa&rcourir...", PM_BROWSE, 185, 45, 60, 15, WS_TABSTOP -PUSHBUTTON "&Changer l'icône...", PM_OTHER_SYMBOL, 185, 65, 60, 15, WS_TABSTOP +PUSHBUTTON "&Changer l'icône...", PM_OTHER_SYMBOL, 185, 65, 60, 15, WS_TABSTOP PUSHBUTTON "Aid&e", PM_HELP, 185, 85, 60, 15, WS_TABSTOP } @@ -163,12 +158,12 @@ PUSHBUTTON "Aid&e", PM_HELP, 185, 85, 60, 15, WS DIALOG_SYMBOL DIALOG 0, 0, 200, 85 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Changer l'icône" +CAPTION "Changer l'icône" { -LTEXT "&Nom du fichier :", PM_ICON_FILE_TXT, 5, 7, 56, 10 -EDITTEXT PM_ICON_FILE, 5, 16, 124, 14, WS_TABSTOP -LTEXT "Icône a&ctuelle :", PM_SYMBOL_LIST_TXT, 5, 33, 125, 10 -COMBOBOX PM_SYMBOL_LIST, 5, 43, 125, 50, +LTEXT "&Nom du fichier :", PM_ICON_FILE_TXT, 5, 15, 40, 10 +EDITTEXT PM_ICON_FILE, 45, 15, 85, 15, WS_TABSTOP +LTEXT "Icône a&ctuelle :", PM_SYMBOL_LIST_TXT, 5, 30, 125, 10 +COMBOBOX PM_SYMBOL_LIST, 5, 40, 125, 50, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | CBS_OWNERDRAWFIXED | WS_TABSTOP DEFPUSHBUTTON "OK", IDOK, 135, 5, 60, 15, WS_TABSTOP PUSHBUTTON "Annuler", IDCANCEL, 135, 25, 60, 15, WS_TABSTOP @@ -180,12 +175,12 @@ PUSHBUTTON "Aid&e", PM_HELP, 135, 65, 60, 15, WS_TABSTOP DIALOG_EXECUTE DIALOG 0, 0, 200, 85 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Exécuter un programme" +CAPTION "Exécuter un programme" { -LTEXT "&Ligne de commande :", -1, 05, 15, 120, 10 +LTEXT "&Ligne de commande :", -1, 05, 15, 120, 10 EDITTEXT PM_COMMAND, 05, 25, 120, 15, WS_TABSTOP CHECKBOX "", PM_SYMBOL, 05, 45, 10, 10, WS_TABSTOP -LTEXT "Réduire à l'&utilisation", -1, 18, 46, 106, 10 +LTEXT "Réduire à l'&utilisation", -1, 20, 45, 120, 10 DEFPUSHBUTTON "OK", IDOK, 135, 5, 60, 15, WS_TABSTOP PUSHBUTTON "Annuler", IDCANCEL, 135, 25, 60, 15, WS_TABSTOP PUSHBUTTON "Pa&rcourir...", PM_BROWSE, 135, 45, 60, 15, WS_TABSTOP @@ -196,54 +191,54 @@ PUSHBUTTON "Aid&e", PM_HELP, 135, 65, 60, 15, WS_TABSTOP STRINGTABLE DISCARDABLE { -IDS_PROGRAM_MANAGER, "Gestionnaire de programmes" +IDS_PROGRAM_MANAGER, "Gestionaire de programmes" IDS_ERROR, "ERREUR" IDS_WARNING, "ATTENTION" IDS_INFO, "Information" IDS_DELETE, "Supprimer" -IDS_DELETE_GROUP_s, "Voulez-vous supprimer le groupe « %s » ?" -IDS_DELETE_PROGRAM_s, "Voulez-vous supprimer le programme « %s » ?" -IDS_NOT_IMPLEMENTED, "Non implémenté" -IDS_FILE_READ_ERROR_s, "Impossible d'ouvrir « %s »." -IDS_FILE_WRITE_ERROR_s, "Impossible d'enregistrer « %s »." +IDS_DELETE_GROUP_s, "Voulez-vous supprimer le groupe « %s » ?" +IDS_DELETE_PROGRAM_s, "Voulez-vous supprimer le programme « %s » ?" +IDS_NOT_IMPLEMENTED, "Non implementé" +IDS_FILE_READ_ERROR_s, "Impossible d'ouvrir « %s »." +IDS_FILE_WRITE_ERROR_s, "Impossible d'enregistrer « %s »." IDS_GRPFILE_READ_ERROR_s, "\ -Impossible d'ouvrir le groupe « %s ».\n\ +Impossible d'ouvrir le groupe « %s ».\n\ Voulez-vous que le Gestionnaire de programmes essaie\n\ -de l'ouvrir dans les prochaines sessions ?" -IDS_OUT_OF_MEMORY, "Mémoire insuffisante." +de l'ouvrir dans les prochaines sessions ?" +IDS_OUT_OF_MEMORY, "Mémoire insuffisante." IDS_WINHELP_ERROR, "Impossible d'afficher l'aide." -IDS_UNKNOWN_FEATURE_s, "Caractéristique inconnue dans %s" -IDS_FILE_NOT_OVERWRITTEN_s, "Le fichier « %s » existe. Non écrasé." -IDS_SAVE_GROUP_AS_s, "Groupe enregistré sous « %s » pour éviter l'écrasement du fichier original." +IDS_UNKNOWN_FEATURE_s, "Caractéristique inconnue dans %s" +IDS_FILE_NOT_OVERWRITTEN_s, "Le fichier « %s » existe. Non écrasé." +IDS_SAVE_GROUP_AS_s, "Groupe enregistré sous « %s » pour éviter l'écrasement du fichier original." IDS_NO_HOT_KEY, "Aucun" IDS_ALL_FILES, "Tous fichiers (*.*)" IDS_PROGRAMS, "Programmes" -IDS_LIBRARIES_DLL, "Bibliothèques (*.dll)" -IDS_SYMBOL_FILES, "Icônes" -IDS_SYMBOLS_ICO, "Icônes (*.ico)" +IDS_LIBRARIES_DLL, "Bibliothèques (*.dll)" +IDS_SYMBOL_FILES, "Icônes" +IDS_SYMBOLS_ICO, "Icônes (*.ico)" } STRINGTABLE DISCARDABLE LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL { IDS_LICENSE_CAPTION, "LICENCE" IDS_LICENSE, -"Ce programme est un logiciel libre ; vous pouvez le redistribuer et/ou \ -le modifier suivant les termes de la Licence Générale Publique Limitée GNU \ -telle que publiée par la Free Software Foundation ; soit la version 2.1 \ -de la Licence, soit (à votre gré) toute version ultérieure.\n\ -Ce programme est distribué dans l'espoir qu'il sera utile, mais \ -SANS AUCUNE GARANTIE : sans même la garantie implicite de \ -COMMERCIALISABILITÉ ou d'ADÉQUATION À UN OBJECTIF PARTICULIER. Consultez \ -la Licence Générale Publique Limitée pour plus de détails.\n\ -Vous devriez avoir reçu une copie de la Licence Générale Publique Limitée \ -GNU avec ce programme ; si ce n'est pas le cas, écrivez à la : \ +"Ce programme est un logiciel libre ; vous pouvez le redistribuer et/ou \ +le modifier suivant les termes de la Licence Générale Publique Limitée GNU \ +telle que publiée par la Free Software Foundation ; soit la version 2.1 \ +de la License, soit (à votre gré) toute version ultérieure.\n\ +Ce programme est distribué dans l'espoir qu'il sera utile, mais \ +SANS AUCUNE GARANTIE : sans même la garantie implicite de \ +COMMERCIALISABILITÉ ou d'ADÉQUATION À UN OBJECTIF PARTICULIER. Consultez \ +la Licence Générale Publique Limitée pour plus de détails.\n\ +Vous devriez avoir reçu une copie de la Licence Générale Publique Limitée \ +GNU avec ce programme ; si ce n'est pas le cas, écrivez à la : \ Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, \ MA 02110-1301, USA." IDS_WARRANTY_CAPTION, "AUCUNE GARANTIE" IDS_WARRANTY, -"Ce programme est distribué dans l'espoir qu'il sera utile, mais \ -SANS AUCUNE GARANTIE : sans même la garantie implicite de \ -COMMERCIALISABILITÉ ou d'ADÉQUATION À UN OBJECTIF PARTICULIER. Consultez \ -la Licence Générale Publique Limitée pour plus de détails." +"Ce programme est distribué dans l'espoir qu'il sera utile, mais \ +SANS AUCUNE GARANTIE : sans même la garantie implicite de \ +COMMERCIALISABILITÉ ou d'ADÉQUATION À UN OBJECTIF PARTICULIER. Consultez \ +la Licence Générale Publique Limitée pour plus de détails." } diff --git a/programs/progman/Hu.rc b/programs/progman/Hu.rc index 9d53fb39c5e..678d68d2e1c 100644 --- a/programs/progman/Hu.rc +++ b/programs/progman/Hu.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT diff --git a/programs/progman/It.rc b/programs/progman/It.rc index 9e3437d2e03..0da544c6f08 100644 --- a/programs/progman/It.rc +++ b/programs/progman/It.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL @@ -57,7 +55,7 @@ POPUP "&Aiuto" { MENUITEM "&Tutorial", PM_TUTORIAL MENUITEM SEPARATOR - POPUP "&Informazioni sul Gestore Del Programma" { + POPUP "&Informazioni sul Program Manager" { MENUITEM "&Licenza", PM_LICENSE MENUITEM "&Garanzia", PM_NO_WARRANTY MENUITEM "&Informazioni su WINE", PM_ABOUT_WINE @@ -86,7 +84,7 @@ PUSHBUTTON "&Aiuto", PM_HELP, 105, 45, 60, 15, WS_TABSTOP DIALOG_MOVE DIALOG 0, 0, 250, 65 LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Sposta Programma" +CAPTION "Move Program" { LTEXT "Sposta programma:", -1, 5, 5, 90, 15 LTEXT "", PM_PROGRAM, 95, 5, 90, 15 @@ -110,7 +108,7 @@ LTEXT "Copia programma:", -1, 5, 5, 90, 15 LTEXT "", PM_PROGRAM, 95, 5, 90, 15 LTEXT "Dal gruppo:", -1, 5, 13, 90, 15 LTEXT "", PM_FROM_GROUP, 95, 13, 90, 15 -LTEXT "&Al gruppo:", PM_TO_GROUP_TXT, 5, 28, 140, 15 +LTEXT "&Al grouppo:", PM_TO_GROUP_TXT, 5, 28, 140, 15 COMBOBOX PM_TO_GROUP, 5, 38, 140, 50, WS_TABSTOP | CBS_DROPDOWNLIST DEFPUSHBUTTON "OK", IDOK, 185, 5, 60, 15, WS_TABSTOP PUSHBUTTON "Annulla", IDCANCEL, 185, 25, 60, 15, WS_TABSTOP @@ -197,9 +195,9 @@ PUSHBUTTON "&Aiuto", PM_HELP, 135, 65, 60, 15, WS_TABSTOP STRINGTABLE DISCARDABLE LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL { -IDS_PROGRAM_MANAGER, "Gestore Programma" +IDS_PROGRAM_MANAGER, "Program Manager" IDS_ERROR, "ERRORE" -IDS_WARNING, "ATTENZIONE" +IDS_WARNING, "ATTENZONE" IDS_INFO, "Informazioni" IDS_DELETE, "Elimina" IDS_DELETE_GROUP_s, "Eliminare il gruppo `%s' ?" diff --git a/programs/progman/Ko.rc b/programs/progman/Ko.rc index 5c2cdd17d69..6c749f2935a 100644 --- a/programs/progman/Ko.rc +++ b/programs/progman/Ko.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT diff --git a/programs/progman/Lt.rc b/programs/progman/Lt.rc deleted file mode 100644 index d484c55c7ae..00000000000 --- a/programs/progman/Lt.rc +++ /dev/null @@ -1,244 +0,0 @@ -/* - * Program Manager - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "progman.h" - -/* Menu */ - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -MAIN_MENU MENU -{ - POPUP "&Failas" { - MENUITEM "&Nauja...", PM_NEW - MENUITEM "&Atverti\tEnter", PM_OPEN - MENUITEM "&Perkelti...\tF7", PM_MOVE, GRAYED - MENUITEM "&Kopijuoti...\tF8", PM_COPY, GRAYED - MENUITEM "&Šalinti\tEntf", PM_DELETE - MENUITEM "At&ributai...\tAlt+Enter", PM_ATTRIBUTES - MENUITEM SEPARATOR - MENUITEM "&Vykdyti...", PM_EXECUTE - MENUITEM SEPARATOR - MENUITEM "Iš&eiti...", PM_EXIT - } - POPUP "&Parinktys" { - MENUITEM "Išdėstyti &automatiškai", PM_AUTO_ARRANGE - MENUITEM "&Suskleisti paleidžiant", PM_MIN_ON_RUN - MENUITEM "Išsaugoti &nuostatas išeinant", PM_SAVE_SETTINGS - } - POPUP "&Langai" { - MENUITEM "&Persikloję\tShift+F5", PM_OVERLAP - MENUITEM "&Greta vienas kito\tShift+F4", PM_SIDE_BY_SIDE - MENUITEM "&Išdėstyti piktogramas", PM_ARRANGE - } - POPUP "&Žinynas" { - MENUITEM "&Turinys", PM_CONTENTS - MENUITEM "&Paieška...", PM_SEARCH - MENUITEM SEPARATOR - MENUITEM "Pa&galba apie žinyną", PM_HELPONHELP - MENUITEM "&Mokymo programa", PM_TUTORIAL - MENUITEM SEPARATOR - - POPUP "&Informacija..." { - MENUITEM "&Licencija", PM_LICENSE - MENUITEM "&JOKIŲ GARANTIJŲ", PM_NO_WARRANTY - MENUITEM "&Apie Wine", PM_ABOUT_WINE - } - } -} - -/* Dialog `New' */ - -DIALOG_NEW DIALOG 0, 0, 170, 65 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Nauja" -{ -RADIOBUTTON "", PM_NEW_GROUP, 10, 15, 10, 15 -LTEXT "Programų &grupė", -1, 20, 18, 80, 15 -RADIOBUTTON "", PM_NEW_PROGRAM, 10, 35, 10, 15 -LTEXT "&Programa", -1, 20, 38, 80, 15 -DEFPUSHBUTTON "Gerai", IDOK, 105, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Atsisakyti", IDCANCEL, 105, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "&Žinynas", PM_HELP, 105, 45, 60, 15, WS_TABSTOP -} - -/* Dialog `Move' */ - -DIALOG_MOVE DIALOG 0, 0, 250, 65 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Perkelti programą" -{ -LTEXT "Perkelti programą:", -1, 5, 5, 90, 15 -LTEXT "", PM_PROGRAM, 95, 5, 90, 15 -LTEXT "Iš grupės:", -1, 5, 13, 90, 15 -LTEXT "", PM_FROM_GROUP, 95, 13, 90, 15 -LTEXT "&Į grupę:", PM_TO_GROUP_TXT, 5, 28, 140, 15 -COMBOBOX PM_TO_GROUP, 5, 38, 140, 50, WS_TABSTOP | CBS_DROPDOWNLIST -DEFPUSHBUTTON "Gerai", IDOK, 185, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Atsisakyti", IDCANCEL, 185, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "&Žinynas", PM_HELP, 185, 45, 60, 15, WS_TABSTOP -} - -/* Dialog `Copy' */ - -DIALOG_COPY DIALOG 0, 0, 250, 65 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Kopijuoti programą" -{ -LTEXT "Kopijuoti programą:", -1, 5, 5, 90, 15 -LTEXT "", PM_PROGRAM, 95, 5, 90, 15 -LTEXT "Iš grupės:", -1, 5, 13, 90, 15 -LTEXT "", PM_FROM_GROUP, 95, 13, 90, 15 -LTEXT "&Į grupę:", PM_TO_GROUP_TXT, 5, 28, 140, 15 -COMBOBOX PM_TO_GROUP, 5, 38, 140, 50, WS_TABSTOP | CBS_DROPDOWNLIST -DEFPUSHBUTTON "Gerai", IDOK, 185, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Atsisakyti", IDCANCEL, 185, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "&Žinynas", PM_HELP, 185, 45, 60, 15, WS_TABSTOP -} - -/* Dialog `Group attributes' */ - -DIALOG_GROUP DIALOG 0, 0, 230, 65 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Programų grupės atributai" -{ -LTEXT "&Aprašas:", PM_DESCRIPTION_TXT, 05, 18, 50, 10 -EDITTEXT PM_DESCRIPTION, 60, 18, 90, 15, WS_TABSTOP -LTEXT "&Grupės failas:", PM_FILE_TXT, 05, 38, 50, 10 -EDITTEXT PM_FILE, 60, 38, 90, 15, WS_TABSTOP -DEFPUSHBUTTON "Gerai", IDOK, 155, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Atsisakyti", IDCANCEL, 155, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "&Žinynas", PM_HELP, 155, 45, 60, 15, WS_TABSTOP -} - -/* Dialog `Program attributes' */ - -DIALOG_PROGRAM DIALOG 0, 0, 250, 105 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Programos atributai" -{ -LTEXT "&Aprašas:", PM_DESCRIPTION_TXT, 05, 10, 80, 10 -EDITTEXT PM_DESCRIPTION, 90, 10, 80, 15, WS_TABSTOP -LTEXT "Komandos &eilutė:", PM_COMMAND_LINE_TXT, 05, 25, 80, 10 -EDITTEXT PM_COMMAND_LINE, 90, 25, 80, 15, WS_TABSTOP -LTEXT "&Veikiamasis katalogas:", PM_DIRECTORY_TXT, 05, 40, 80, 10 -EDITTEXT PM_DIRECTORY, 90, 40, 80, 15, WS_TABSTOP -LTEXT "&Klavišų kombinacija:", PM_HOT_KEY_TXT, 05, 55, 80, 10 -EDITTEXT PM_HOT_KEY, 90, 55, 80, 15, WS_TABSTOP -ICON "", PM_ICON, 20, 70 -CHECKBOX "", PM_SYMBOL, 90, 75, 10, 10, WS_TABSTOP -LTEXT "&Suskleisti paleidus", -1, 105, 75, 75, 10 -DEFPUSHBUTTON "Gerai", IDOK, 175, 5, 70, 15, WS_TABSTOP -PUSHBUTTON "Atsisakyti", IDCANCEL, 175, 25, 70, 15, WS_TABSTOP -PUSHBUTTON "Pari&nkti...", PM_BROWSE, 175, 45, 70, 15, WS_TABSTOP -PUSHBUTTON "Keisti &piktogramą...", PM_OTHER_SYMBOL, 175, 65, 70, 15, WS_TABSTOP -PUSHBUTTON "&Žinynas", PM_HELP, 175, 85, 70, 15, WS_TABSTOP -} - -/* Dialog `Symbol' */ - -DIALOG_SYMBOL DIALOG 0, 0, 200, 85 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Keisti piktogramą" -{ -LTEXT "&Failas:", PM_ICON_FILE_TXT, 5, 15, 40, 10 -EDITTEXT PM_ICON_FILE, 45, 15, 85, 15, WS_TABSTOP -LTEXT "Dabartinė &piktograma:", PM_SYMBOL_LIST_TXT, 5, 30, 125, 10 -COMBOBOX PM_SYMBOL_LIST, 5, 40, 125, 50, - CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | CBS_OWNERDRAWFIXED | WS_TABSTOP -DEFPUSHBUTTON "Gerai", IDOK, 135, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Atsisakyti", IDCANCEL, 135, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "Pari&nkti...", PM_BROWSE, 135, 45, 60, 15, WS_TABSTOP -PUSHBUTTON "&Žinynas", PM_HELP, 135, 65, 60, 15, WS_TABSTOP -} - -/* Dialog `Execute' */ - -DIALOG_EXECUTE DIALOG 0, 0, 200, 85 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Vykdyti programą" -{ -LTEXT "&Komandos eilutė:", -1, 05, 15, 120, 10 -EDITTEXT PM_COMMAND, 05, 25, 120, 15, WS_TABSTOP -CHECKBOX "", PM_SYMBOL, 05, 45, 10, 10, WS_TABSTOP -LTEXT "&Suskleisti paleidus", -1, 20, 45, 120, 10 -DEFPUSHBUTTON "Gerai", IDOK, 135, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Atsisakyti", IDCANCEL, 135, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "Pari&nkti...", PM_BROWSE, 135, 45, 60, 15, WS_TABSTOP -PUSHBUTTON "&Žinynas", PM_HELP, 135, 65, 60, 15, WS_TABSTOP -} - -/* Strings */ - -STRINGTABLE DISCARDABLE -{ -IDS_PROGRAM_MANAGER, "Programų tvarkytuvė" -IDS_ERROR, "KLAIDA" -IDS_WARNING, "ĮSPĖJIMAS" -IDS_INFO, "Informacija" -IDS_DELETE, "Šalinti" -IDS_DELETE_GROUP_s, "Šalinti grupę „%s“?" -IDS_DELETE_PROGRAM_s, "Šalinti programą „%s“?" -IDS_NOT_IMPLEMENTED, "Nerealizuota" -IDS_FILE_READ_ERROR_s, "Klaida skaitant „%s“." -IDS_FILE_WRITE_ERROR_s, "Klaida rašant „%s“." -IDS_GRPFILE_READ_ERROR_s, "Nepavyko atidaryti grupės failo „%s“.\n\ - Mėginti atidaryti toliau?" -IDS_OUT_OF_MEMORY, "Trūksta atminties." -IDS_WINHELP_ERROR, "Žinynas neprieinamas." -IDS_UNKNOWN_FEATURE_s, "Nežinoma %s funkcija" -IDS_FILE_NOT_OVERWRITTEN_s, "Failas „%s“ egzistuoja. Neperrašytas." -IDS_SAVE_GROUP_AS_s, "Išsaugoti grupę kaip „%s“, taip neperrašant originalių failų." -IDS_NO_HOT_KEY, "Nėra" -IDS_ALL_FILES, "Visi failai (*.*)" -IDS_PROGRAMS, "Programos" -IDS_LIBRARIES_DLL, "Bibliotekos (*.dll)" -IDS_SYMBOL_FILES, "Piktogramų failai" -IDS_SYMBOLS_ICO, "Piktogramos (*.ico)" -} - -STRINGTABLE DISCARDABLE -{ -IDS_LICENSE_CAPTION, "LICENCIJA" -IDS_LICENSE, -"Ši programa yra laisva programinė įranga; galite ją platinti ir/ar \ -modifikuoti GNU laisvosios bendrosios viešosios licencijos (LGPL) \ -sąlygomis, kurios paskelbtos Laisvosios programinės įrangos fondo \ -(FSF); 2.1-osios arba (Jūsų pasirinkimu) bet kurios vėlesnės \ -licencijos versijos sąlygomis.\n\ -Ši programa yra platinama tikintis, kad ji bus naudinga, bet BE JOKIŲ \ -GARANTIJŲ; net be numanomų PERKAMUMO ar TINKAMUMO KONKREČIAI \ -UŽDUOČIAI garantijų. Išsamią informaciją rasite GNU laisvojoje \ -bendrojoje viešojoje licencijoje.\n\ -Jūs turėjote gauti GNU laisvosios bendrosios viešosios licencijos \ -kopiją kartu su Wine; jei negavote, rašykite adresu \ -Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, \ -Boston, MA 02110-1301, USA." - -IDS_WARRANTY_CAPTION, "JOKIŲ GARANTIJŲ" -IDS_WARRANTY, -"Ši programa yra platinama tikintis, kad ji bus naudinga, bet BE JOKIŲ \ -GARANTIJŲ; net be numanomų PERKAMUMO ar TINKAMUMO KONKREČIAI \ -UŽDUOČIAI garantijų. Išsamią informaciją rasite GNU laisvojoje \ -bendrojoje viešojoje licencijoje." -} diff --git a/programs/progman/Makefile.in b/programs/progman/Makefile.in index 921f9a81c0b..9ed785910e7 100644 --- a/programs/progman/Makefile.in +++ b/programs/progman/Makefile.in @@ -14,27 +14,7 @@ C_SRCS = \ program.c \ string.c -RC_SRCS = \ - Cs.rc \ - Da.rc \ - De.rc \ - En.rc \ - Es.rc \ - Fr.rc \ - Hu.rc \ - It.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc \ - accel.rc +RC_SRCS = rsrc.rc @MAKE_PROG_RULES@ diff --git a/programs/progman/Nl.rc b/programs/progman/Nl.rc index b2ca361b8cc..7b8c8d0f913 100644 --- a/programs/progman/Nl.rc +++ b/programs/progman/Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL diff --git a/programs/progman/No.rc b/programs/progman/No.rc index 618e985daed..1af4170bf2d 100644 --- a/programs/progman/No.rc +++ b/programs/progman/No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL diff --git a/programs/progman/Pl.rc b/programs/progman/Pl.rc index 351930cc384..626618cefcf 100644 --- a/programs/progman/Pl.rc +++ b/programs/progman/Pl.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - /* Menu */ LANGUAGE LANG_POLISH, SUBLANG_DEFAULT diff --git a/programs/progman/Pt.rc b/programs/progman/Pt.rc index 5872a52fbfe..227b767d9ca 100644 --- a/programs/progman/Pt.rc +++ b/programs/progman/Pt.rc @@ -4,7 +4,7 @@ * * Copyright 1999 Gustavo Junior Alves * Copyright 2003 Marcelo Duarte - * Copyright 2004 Américo José Melo + * 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 @@ -21,10 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - -#pragma code_page(65001) - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN /* Menu */ @@ -42,27 +38,27 @@ MAIN_MENU MENU MENUITEM SEPARATOR MENUITEM "Sai&r do Windows...", PM_EXIT } - POPUP "&Opções" { + POPUP "&Opções" { MENUITEM "&Auto organizar", PM_AUTO_ARRANGE - MENUITEM "&Minimizar na execução", PM_MIN_ON_RUN - MENUITEM "&Salvar alterações ao sair", PM_SAVE_SETTINGS + MENUITEM "&Minimizar na execução", PM_MIN_ON_RUN + MENUITEM "&Salvar alterações ao sair", PM_SAVE_SETTINGS } POPUP "&Janelas" { MENUITEM "&Cascata\tShift+F5", PM_OVERLAP MENUITEM "&Lado a lado \tShift+F4", PM_SIDE_BY_SIDE - MENUITEM "&Organizar ícones", PM_ARRANGE + MENUITEM "&Organizar ícones", PM_ARRANGE } POPUP "Aj&uda" { - MENUITEM "&Conteúdo", PM_CONTENTS + MENUITEM "&Conteúdo", PM_CONTENTS MENUITEM "&Pesquisa...", PM_SEARCH MENUITEM SEPARATOR MENUITEM "&Ajuda da ajuda", PM_HELPONHELP MENUITEM "&Tutorial", PM_TUTORIAL MENUITEM SEPARATOR - POPUP "&Informações..." { - MENUITEM "&Licença", PM_LICENSE + POPUP "&Informações..." { + MENUITEM "&Licença", PM_LICENSE MENUITEM "&SEM GARANTIA", PM_NO_WARRANTY MENUITEM "&Sobre o WINE", PM_ABOUT_WINE } @@ -86,27 +82,27 @@ MAIN_MENU MENU MENUITEM SEPARATOR MENUITEM "Sai&r do Windows...", PM_EXIT } - POPUP "&Opções" { + POPUP "&Opções" { MENUITEM "&Auto organizar", PM_AUTO_ARRANGE - MENUITEM "&Minimizar na execução", PM_MIN_ON_RUN - MENUITEM "&Gravar alterações ao sair", PM_SAVE_SETTINGS + MENUITEM "&Minimizar na execução", PM_MIN_ON_RUN + MENUITEM "&Gravar alterações ao sair", PM_SAVE_SETTINGS } POPUP "&Janelas" { MENUITEM "&Cascata\tShift+F5", PM_OVERLAP MENUITEM "&Lado a lado \tShift+F4", PM_SIDE_BY_SIDE - MENUITEM "&Organizar ícones", PM_ARRANGE + MENUITEM "&Organizar ícones", PM_ARRANGE } POPUP "Aj&uda" { - MENUITEM "&Conteúdo", PM_CONTENTS + MENUITEM "&Conteúdo", PM_CONTENTS MENUITEM "&Pesquisa...", PM_SEARCH MENUITEM SEPARATOR MENUITEM "&Ajuda da ajuda", PM_HELPONHELP MENUITEM "&Tutorial", PM_TUTORIAL MENUITEM SEPARATOR - POPUP "&Informações..." { - MENUITEM "&Licença", PM_LICENSE + POPUP "&Informações..." { + MENUITEM "&Licença", PM_LICENSE MENUITEM "&SEM GARANTIA", PM_NO_WARRANTY MENUITEM "&Acerca do WINE", PM_ABOUT_WINE } @@ -180,7 +176,7 @@ DIALOG_GROUP DIALOG 0, 0, 230, 65 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Atributos do grupo de programas" { -LTEXT "&Descrição:", PM_DESCRIPTION_TXT, 05, 18, 50, 10 +LTEXT "&Descrição:", PM_DESCRIPTION_TXT, 05, 18, 50, 10 EDITTEXT PM_DESCRIPTION, 60, 18, 90, 15, WS_TABSTOP LTEXT "&Grupo de arquivo:", PM_FILE_TXT, 05, 38, 50, 10 EDITTEXT PM_FILE, 60, 38, 90, 15, WS_TABSTOP @@ -195,7 +191,7 @@ DIALOG_GROUP DIALOG 0, 0, 230, 65 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Atributos do grupo de programas" { -LTEXT "&Descrição:", PM_DESCRIPTION_TXT, 05, 18, 50, 10 +LTEXT "&Descrição:", PM_DESCRIPTION_TXT, 05, 18, 50, 10 EDITTEXT PM_DESCRIPTION, 60, 18, 90, 15, WS_TABSTOP LTEXT "&Grupo de ficheiro:", PM_FILE_TXT, 05, 38, 50, 10 EDITTEXT PM_FILE, 60, 38, 90, 15, WS_TABSTOP @@ -213,7 +209,7 @@ DIALOG_PROGRAM DIALOG 0, 0, 250, 105 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Atributos de programa" { -LTEXT "&Descrição:", PM_DESCRIPTION_TXT, 05, 10, 60, 10 +LTEXT "&Descrição:", PM_DESCRIPTION_TXT, 05, 10, 60, 10 EDITTEXT PM_DESCRIPTION, 80, 10, 90, 15, WS_TABSTOP LTEXT "&Linha de comando:", PM_COMMAND_LINE_TXT, 05, 25, 60, 10 EDITTEXT PM_COMMAND_LINE, 80, 25, 90, 15, WS_TABSTOP @@ -227,7 +223,7 @@ LTEXT "Executar &minimizado", -1, 95, 75, 75, 10 DEFPUSHBUTTON "OK", IDOK, 185, 5, 60, 15, WS_TABSTOP PUSHBUTTON "Cancelar", IDCANCEL, 185, 25, 60, 15, WS_TABSTOP PUSHBUTTON "P&rocurar...", PM_BROWSE, 185, 45, 60, 15, WS_TABSTOP -PUSHBUTTON "Alt&erar ícone...", PM_OTHER_SYMBOL, 185, 65, 60, 15, WS_TABSTOP +PUSHBUTTON "Alt&erar ícone...", PM_OTHER_SYMBOL, 185, 65, 60, 15, WS_TABSTOP PUSHBUTTON "Aj&uda", PM_HELP, 185, 85, 60, 15, WS_TABSTOP } @@ -238,11 +234,11 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN DIALOG_SYMBOL DIALOG 0, 0, 200, 85 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Alterar ícone" +CAPTION "Alterar ícone" { LTEXT "&Nome do arquivo:", PM_ICON_FILE_TXT, 5, 15, 40, 10 EDITTEXT PM_ICON_FILE, 45, 15, 85, 15, WS_TABSTOP -LTEXT "Ícone &atual:", PM_SYMBOL_LIST_TXT, 5, 30, 125, 10 +LTEXT "Ícone &atual:", PM_SYMBOL_LIST_TXT, 5, 30, 125, 10 COMBOBOX PM_SYMBOL_LIST, 5, 40, 125, 50, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | CBS_OWNERDRAWFIXED | WS_TABSTOP DEFPUSHBUTTON "OK", IDOK, 135, 5, 60, 15, WS_TABSTOP @@ -255,11 +251,11 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE DIALOG_SYMBOL DIALOG 0, 0, 200, 85 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Alterar ícone" +CAPTION "Alterar ícone" { LTEXT "&Nome do ficheiro:", PM_ICON_FILE_TXT, 5, 15, 40, 10 EDITTEXT PM_ICON_FILE, 45, 15, 85, 15, WS_TABSTOP -LTEXT "Ícone &actual:", PM_SYMBOL_LIST_TXT, 5, 30, 125, 10 +LTEXT "Ícone &actual:", PM_SYMBOL_LIST_TXT, 5, 30, 125, 10 COMBOBOX PM_SYMBOL_LIST, 5, 40, 125, 50, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | CBS_OWNERDRAWFIXED | WS_TABSTOP DEFPUSHBUTTON "OK", IDOK, 135, 5, 60, 15, WS_TABSTOP @@ -297,75 +293,51 @@ STRINGTABLE DISCARDABLE IDS_PROGRAM_MANAGER, "Gerenciador de programas" IDS_ERROR, "ERRO" IDS_WARNING, "AVISO" -IDS_INFO, "Informação" +IDS_INFO, "Informação" IDS_DELETE, "Excluir" IDS_DELETE_GROUP_s, "Excluir grupo '%s' ?" IDS_DELETE_PROGRAM_s, "Excluir programa '%s' ?" -IDS_NOT_IMPLEMENTED, "Não implementado" +IDS_NOT_IMPLEMENTED, "Não implementado" IDS_FILE_READ_ERROR_s, "Erro lendo '%s'." IDS_FILE_WRITE_ERROR_s, "Erro escrevendo '%s'." -IDS_GRPFILE_READ_ERROR_s, "O arquivo de grupo '%s' não pode ser aberto.\nDeverá ser tentado outras vezes?" -IDS_OUT_OF_MEMORY, "Sem memória." -IDS_WINHELP_ERROR, "Ajuda não disponível." +IDS_GRPFILE_READ_ERROR_s, "O arquivo de grupo '%s' não pode ser aberto.\nDeverá ser tentado outras vezes?" +IDS_OUT_OF_MEMORY, "Sem memória." +IDS_WINHELP_ERROR, "Ajuda não disponível." IDS_UNKNOWN_FEATURE_s, "Recurso desconhecido em %s" -IDS_FILE_NOT_OVERWRITTEN_s, "Arquivo '%s' existe. Não sobreescrevendo." +IDS_FILE_NOT_OVERWRITTEN_s, "Arquivo '%s' existe. Não sobreescrevendo." IDS_SAVE_GROUP_AS_s, "Salvar grupo como '%s' para prevenir a sobreescrita dos arquivos originais." IDS_NO_HOT_KEY, "Nenhuma" IDS_ALL_FILES, "Todos os arquivos (*.*)" IDS_PROGRAMS, "Programas" IDS_LIBRARIES_DLL, "Bibliotecas (*.dll)" -IDS_SYMBOL_FILES, "Arquivos de ícones" -IDS_SYMBOLS_ICO, "Ícones (*.ico)" +IDS_SYMBOL_FILES, "Arquivos de ícones" +IDS_SYMBOLS_ICO, "Ícones (*.ico)" } LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE DISCARDABLE { -IDS_PROGRAM_MANAGER, "Gerênciador de programas" +IDS_PROGRAM_MANAGER, "Gerênciador de programas" IDS_ERROR, "ERRO" IDS_WARNING, "AVISO" -IDS_INFO, "Informação" +IDS_INFO, "Informação" IDS_DELETE, "Excluir" IDS_DELETE_GROUP_s, "Excluir grupo '%s' ?" IDS_DELETE_PROGRAM_s, "Excluir programa '%s' ?" -IDS_NOT_IMPLEMENTED, "Não implementado" +IDS_NOT_IMPLEMENTED, "Não implementado" IDS_FILE_READ_ERROR_s, "Erro ao ler '%s'." IDS_FILE_WRITE_ERROR_s, "Erro ao escrever '%s'." -IDS_GRPFILE_READ_ERROR_s, "O ficheiro de grupo '%s' não pode ser aberto.\nDeverá tentar outras vezes?" -IDS_OUT_OF_MEMORY, "Sem memória." -IDS_WINHELP_ERROR, "Ajuda não disponível." +IDS_GRPFILE_READ_ERROR_s, "O ficheiro de grupo '%s' não pode ser aberto.\nDeverá tentar outras vezes?" +IDS_OUT_OF_MEMORY, "Sem memória." +IDS_WINHELP_ERROR, "Ajuda não disponível." IDS_UNKNOWN_FEATURE_s, "Recurso desconhecido em %s" -IDS_FILE_NOT_OVERWRITTEN_s, "Ficheiro '%s' existe. Não sobreescrever." +IDS_FILE_NOT_OVERWRITTEN_s, "Ficheiro '%s' existe. Não sobreescrever." IDS_SAVE_GROUP_AS_s, "Gravar grupo como '%s' para prevenir a sobreescrita dos ficheiros originais." IDS_NO_HOT_KEY, "Nenhuma" IDS_ALL_FILES, "Todos os ficheiros (*.*)" IDS_PROGRAMS, "Programas" IDS_LIBRARIES_DLL, "Bibliotecas (*.dll)" -IDS_SYMBOL_FILES, "Ficheiros de ícones" -IDS_SYMBOLS_ICO, "Ícones (*.ico)" -} - -STRINGTABLE DISCARDABLE LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE -{ -IDS_LICENSE_CAPTION, "Licença do Wine" -IDS_LICENSE, -"O Wine é software livre; você pode redistribuí-lo e/ou \ -modificá-lo sob os termos da GNU Lesser General Public \ -License tal como publicado pela Free Software Foundation; seja a \ -versão 2.1 da Licença, ou (por sua escolha) outra versão mais recente.\n\n\ -O Wine é distribuído na esperança que seja útil, \ -mas SEM QUALQUER GARANTIA; nem sequer a garantia implícita de \ -MERCANTIBILIDADE ou FEITO PARA UM PROPÓSITO ESPECÍFICO. veja a GNU \ -Lesser General Public License para mais detalhes.\n\n\ -Deverá ter recebido uma cópia da GNU Lesser General Public \ -License com o Wine; se não, escreva à Free Software \ -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA." - -IDS_WARRANTY_CAPTION, "SEM GARANTIA" -IDS_WARRANTY, -"O Wine é distribuído na esperança que seja útil, \ -mas SEM QUALQUER GARANTIA; nem sequer a garantia implícita de \ -MERCANTIBILIDADE ou FEITO PARA UM PROPÓSITO ESPECÍFICO. veja a GNU \ -Lesser General Public License para mais detalhes." +IDS_SYMBOL_FILES, "Ficheiros de ícones" +IDS_SYMBOLS_ICO, "Ícones (*.ico)" } diff --git a/programs/progman/README b/programs/progman/README new file mode 100644 index 00000000000..8cd4c34bc6c --- /dev/null +++ b/programs/progman/README @@ -0,0 +1,14 @@ +This is a Program Manager for WINE. + +There is a checksum in the Microsoft `*.grp' files. I don't know how +to calculate it. Therefore the group files written by this Program Manager +cannot be used with the Microsoft Program Manager!! + +To prevent overwriting original files: +If there is an existing `*.grp' file this program uses the extension +`.gr' instead. + +It's possible to use an alternate `progman.ini' file by adding to +`wine.conf' something like: +[progman] +progman.ini=/my/wine/path/progman.ini diff --git a/programs/progman/Ru.rc b/programs/progman/Ru.rc index 709b02ca48c..90d6302210a 100644 --- a/programs/progman/Ru.rc +++ b/programs/progman/Ru.rc @@ -19,52 +19,45 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT - /* Menu */ -MAIN_MENU MENU +MAIN_MENU MENU LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT { - POPUP "&Файл" { - MENUITEM "&Создать", PM_NEW - MENUITEM "О&ткрыть...\tEnter", PM_OPEN - MENUITEM "&Переместить...\tF7", PM_MOVE, GRAYED - MENUITEM "&Копировать...\tF8", PM_COPY, GRAYED - MENUITEM "&Удалить\tEntf", PM_DELETE - MENUITEM "&Атрибуты...\tAlt+Enter", PM_ATTRIBUTES + POPUP "&Ôàéë" { + MENUITEM "&Ñîçäàòü", PM_NEW + MENUITEM "Î&òêðûòü...\tEnter", PM_OPEN + MENUITEM "&Ïåðåìåñòèòü...\tF7", PM_MOVE, GRAYED + MENUITEM "&Êîïèðîâàòü...\tF8", PM_COPY, GRAYED + MENUITEM "&Óäàëèòü\tEntf", PM_DELETE + MENUITEM "&Àòðèáóòû...\tAlt+Enter", PM_ATTRIBUTES MENUITEM SEPARATOR - MENUITEM "&Запустить...", PM_EXECUTE + MENUITEM "&Çàïóñòèòü...", PM_EXECUTE MENUITEM SEPARATOR - MENUITEM "Вы&ход из Wine...", PM_EXIT + MENUITEM "Âû&õîä èç Wine...", PM_EXIT } - POPUP "&Параметры" { - MENUITEM "&Автоупорядочение", PM_AUTO_ARRANGE - MENUITEM "&Свернуть при запуске", PM_MIN_ON_RUN - MENUITEM "&Сохранять настройки при выходе", PM_SAVE_SETTINGS + POPUP "&Ïàðàìåòðû" { + MENUITEM "&Àâòîóïîðÿäî÷åíèå", PM_AUTO_ARRANGE + MENUITEM "&Ñâåðíóòü ïðè çàïóñêå", PM_MIN_ON_RUN + MENUITEM "&Ñîõðàíÿòü íàñòðîéêè ïðè âûõîäå", PM_SAVE_SETTINGS } - POPUP "&Окна" { - MENUITEM "&Каскад\tShift+F5", PM_OVERLAP - MENUITEM "&Мозаика\tShift+F4", PM_SIDE_BY_SIDE - MENUITEM "&Упорядочить при выходе", PM_ARRANGE + POPUP "&Îêíà" { + MENUITEM "&Êàñêàä\tShift+F5", PM_OVERLAP + MENUITEM "&Ìîçàèêà\tShift+F4", PM_SIDE_BY_SIDE + MENUITEM "&Óïîðÿäî÷èòü ïðè âûõîäå", PM_ARRANGE } -POPUP "&Справка" { - MENUITEM "&Содержание", PM_CONTENTS - MENUITEM "&Поиск...", PM_SEARCH +POPUP "&Ñïðàâêà" { + MENUITEM "&Ñîäåðæàíèå", PM_CONTENTS + MENUITEM "&Ïîèñê...", PM_SEARCH MENUITEM SEPARATOR - MENUITEM "&Использование справки", PM_HELPONHELP - MENUITEM "&Руководство", PM_TUTORIAL + MENUITEM "&Èñïîëüçîâàíèå ñïðàâêè", PM_HELPONHELP + MENUITEM "&Ðóêîâîäñòâî", PM_TUTORIAL MENUITEM SEPARATOR - POPUP "&Сведения..." { - MENUITEM "&Лицензия", PM_LICENSE - MENUITEM "&БЕЗ ГАРАНТИЙ", PM_NO_WARRANTY - MENUITEM "&О Wine", PM_ABOUT_WINE + POPUP "&Ñâåäåíèÿ..." { + MENUITEM "&Ëèöåíçèÿ", PM_LICENSE + MENUITEM "&ÁÅÇ ÃÀÐÀÍÒÈÉ", PM_NO_WARRANTY + MENUITEM "&Î Wine", PM_ABOUT_WINE } } } @@ -72,150 +65,157 @@ POPUP "&Справка" { /* Dialog `New' */ DIALOG_NEW DIALOG 0, 0, 170, 65 +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Создать программный объект" +CAPTION "Ñîçäàòü ïðîãðàììíûé îáúåêò" { RADIOBUTTON "", PM_NEW_GROUP, 10, 15, 10, 15 -LTEXT "&Группу программ", -1, 20, 18, 80, 15 +LTEXT "&Ãðóïïó ïðîãðàìì", -1, 20, 18, 80, 15 RADIOBUTTON "", PM_NEW_PROGRAM, 10, 35, 10, 15 -LTEXT "&Программный элемент", -1, 20, 38, 80, 15 +LTEXT "&Ïðîãðàììíûé ýëåìåíò", -1, 20, 38, 80, 15 DEFPUSHBUTTON "OK", IDOK, 105, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Отмена", IDCANCEL, 105, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "&Справка", PM_HELP, 105, 45, 60, 15, WS_TABSTOP +PUSHBUTTON "Îòìåíà", IDCANCEL, 105, 25, 60, 15, WS_TABSTOP +PUSHBUTTON "&Ñïðàâêà", PM_HELP, 105, 45, 60, 15, WS_TABSTOP } /* Dialog `Move' */ DIALOG_MOVE DIALOG 0, 0, 250, 65 +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Переместить программу" +CAPTION "Ïåðåìåñòèòü ïðîãðàììó" { -LTEXT "Переместить программу:", -1, 5, 5, 90, 15 +LTEXT "Ïåðåìåñòèòü ïðîãðàììó:", -1, 5, 5, 90, 15 LTEXT "", PM_PROGRAM, 95, 5, 90, 15 -LTEXT "Из группы:", -1, 5, 13, 90, 15 +LTEXT "Èç ãðóïïû:", -1, 5, 13, 90, 15 LTEXT "", PM_FROM_GROUP, 95, 13, 90, 15 -LTEXT "&В группу:", PM_TO_GROUP_TXT, 5, 28, 140, 15 +LTEXT "& ãðóïïó:", PM_TO_GROUP_TXT, 5, 28, 140, 15 COMBOBOX PM_TO_GROUP, 5, 38, 140, 50, WS_TABSTOP | CBS_DROPDOWNLIST DEFPUSHBUTTON "OK", IDOK, 185, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Отмена", IDCANCEL, 185, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "&Справка", PM_HELP, 185, 45, 60, 15, WS_TABSTOP +PUSHBUTTON "Îòìåíà", IDCANCEL, 185, 25, 60, 15, WS_TABSTOP +PUSHBUTTON "&Ñïðàâêà", PM_HELP, 185, 45, 60, 15, WS_TABSTOP } /* Dialog `Copy' */ DIALOG_COPY DIALOG 0, 0, 250, 65 +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Копировать программу" +CAPTION "Êîïèðîâàòü ïðîãðàììó" { -LTEXT "Копировать программу:", -1, 5, 5, 90, 15 +LTEXT "Êîïèðîâàòü ïðîãðàììó:", -1, 5, 5, 90, 15 LTEXT "", PM_PROGRAM, 95, 5, 90, 15 -LTEXT "Из группы:", -1, 5, 13, 90, 15 +LTEXT "Èç ãðóïïû:", -1, 5, 13, 90, 15 LTEXT "", PM_FROM_GROUP, 95, 13, 90, 15 -LTEXT "&В группу:", PM_TO_GROUP_TXT, 5, 28, 140, 15 +LTEXT "& ãðóïïó:", PM_TO_GROUP_TXT, 5, 28, 140, 15 COMBOBOX PM_TO_GROUP, 5, 38, 140, 50, WS_TABSTOP | CBS_DROPDOWNLIST DEFPUSHBUTTON "OK", IDOK, 185, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Отмена", IDCANCEL, 185, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "&Справка", PM_HELP, 185, 45, 60, 15, WS_TABSTOP +PUSHBUTTON "Îòìåíà", IDCANCEL, 185, 25, 60, 15, WS_TABSTOP +PUSHBUTTON "&Ñïðàâêà", PM_HELP, 185, 45, 60, 15, WS_TABSTOP } /* Dialog `Group attributes' */ DIALOG_GROUP DIALOG 0, 0, 230, 65 +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Атрибуты программной группы" +CAPTION "Àòðèáóòû ïðîãðàììíîé ãðóïïû" { -LTEXT "&Описание:", PM_DESCRIPTION_TXT, 05, 18, 50, 10 +LTEXT "&Îïèñàíèå:", PM_DESCRIPTION_TXT, 05, 18, 50, 10 EDITTEXT PM_DESCRIPTION, 60, 18, 90, 15, WS_TABSTOP -LTEXT "&Файл группы:", PM_FILE_TXT, 05, 38, 50, 10 +LTEXT "&Ôàéë ãðóïïû:", PM_FILE_TXT, 05, 38, 50, 10 EDITTEXT PM_FILE, 60, 38, 90, 15, WS_TABSTOP DEFPUSHBUTTON "OK", IDOK, 155, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Отмена", IDCANCEL, 155, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "&Справка", PM_HELP, 155, 45, 60, 15, WS_TABSTOP +PUSHBUTTON "Îòìåíà", IDCANCEL, 155, 25, 60, 15, WS_TABSTOP +PUSHBUTTON "&Ñïðàâêà", PM_HELP, 155, 45, 60, 15, WS_TABSTOP } /* Dialog `Program attributes' */ DIALOG_PROGRAM DIALOG 0, 0, 250, 105 +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Атрибуты программы" +CAPTION "Àòðèáóòû ïðîãðàììû" { -LTEXT "&Описание:", PM_DESCRIPTION_TXT, 05, 10, 60, 10 +LTEXT "&Îïèñàíèå:", PM_DESCRIPTION_TXT, 05, 10, 60, 10 EDITTEXT PM_DESCRIPTION, 80, 10, 90, 15, WS_TABSTOP -LTEXT "&Командная строка:", PM_COMMAND_LINE_TXT, 05, 25, 60, 10 +LTEXT "&Êîìàíäíàÿ ñòðîêà:", PM_COMMAND_LINE_TXT, 05, 25, 60, 10 EDITTEXT PM_COMMAND_LINE, 80, 25, 90, 15, WS_TABSTOP -LTEXT "&Рабочая папка:", PM_DIRECTORY_TXT, 05, 40, 60, 10 +LTEXT "&Ðàáî÷àÿ ïàïêà:", PM_DIRECTORY_TXT, 05, 40, 60, 10 EDITTEXT PM_DIRECTORY, 80, 40, 90, 15, WS_TABSTOP -LTEXT "&Комбинация клавиш:", PM_HOT_KEY_TXT, 05, 55, 60, 10 +LTEXT "&Êîìáèíàöèÿ êëàâèø:", PM_HOT_KEY_TXT, 05, 55, 60, 10 EDITTEXT PM_HOT_KEY, 80, 55, 90, 15, WS_TABSTOP ICON "", PM_ICON, 20, 70 CHECKBOX "", PM_SYMBOL, 80, 75, 10, 10, WS_TABSTOP -LTEXT "В виде &значка", -1, 95, 75, 75, 10 +LTEXT " âèäå &çíà÷êà", -1, 95, 75, 75, 10 DEFPUSHBUTTON "OK", IDOK, 185, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Отмена", IDCANCEL, 185, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "&Обзор...", PM_BROWSE, 185, 45, 60, 15, WS_TABSTOP -PUSHBUTTON "&Другой значок...", PM_OTHER_SYMBOL, 185, 65, 60, 15, WS_TABSTOP -PUSHBUTTON "&Справка", PM_HELP, 185, 85, 60, 15, WS_TABSTOP +PUSHBUTTON "Îòìåíà", IDCANCEL, 185, 25, 60, 15, WS_TABSTOP +PUSHBUTTON "&Îáçîð...", PM_BROWSE, 185, 45, 60, 15, WS_TABSTOP +PUSHBUTTON "&Äðóãîé çíà÷îê...", PM_OTHER_SYMBOL, 185, 65, 60, 15, WS_TABSTOP +PUSHBUTTON "&Ñïðàâêà", PM_HELP, 185, 85, 60, 15, WS_TABSTOP } /* Dialog `Symbol' */ DIALOG_SYMBOL DIALOG 0, 0, 200, 85 +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Выбрать значок" +CAPTION "Âûáðàòü çíà÷îê" { -LTEXT "&Имя файла:", PM_ICON_FILE_TXT, 5, 15, 40, 10 +LTEXT "&Èìÿ ôàéëà:", PM_ICON_FILE_TXT, 5, 15, 40, 10 EDITTEXT PM_ICON_FILE, 45, 15, 85, 15, WS_TABSTOP -LTEXT "&Текущий значок:", PM_SYMBOL_LIST_TXT, 5, 30, 125, 10 +LTEXT "&Òåêóùèé çíà÷îê:", PM_SYMBOL_LIST_TXT, 5, 30, 125, 10 COMBOBOX PM_SYMBOL_LIST, 5, 40, 125, 50, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | CBS_OWNERDRAWFIXED | WS_TABSTOP DEFPUSHBUTTON "OK", IDOK, 135, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Отмена", IDCANCEL, 135, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "&Обзор...", PM_BROWSE, 135, 45, 60, 15, WS_TABSTOP -PUSHBUTTON "&Справка", PM_HELP, 135, 65, 60, 15, WS_TABSTOP +PUSHBUTTON "Îòìåíà", IDCANCEL, 135, 25, 60, 15, WS_TABSTOP +PUSHBUTTON "&Îáçîð...", PM_BROWSE, 135, 45, 60, 15, WS_TABSTOP +PUSHBUTTON "&Ñïðàâêà", PM_HELP, 135, 65, 60, 15, WS_TABSTOP } /* Dialog `Execute' */ DIALOG_EXECUTE DIALOG 0, 0, 200, 85 +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Запустить программу" +CAPTION "Çàïóñòèòü ïðîãðàììó" { -LTEXT "&Командная строка:", -1, 05, 15, 120, 10 +LTEXT "&Êîìàíäíàÿ ñòðîêà:", -1, 05, 15, 120, 10 EDITTEXT PM_COMMAND, 05, 25, 120, 15, WS_TABSTOP CHECKBOX "", PM_SYMBOL, 05, 45, 10, 10, WS_TABSTOP -LTEXT "В виде &значка", -1, 20, 45, 120, 10 +LTEXT " âèäå &çíà÷êà", -1, 20, 45, 120, 10 DEFPUSHBUTTON "OK", IDOK, 135, 5, 60, 15, WS_TABSTOP -PUSHBUTTON "Отмена", IDCANCEL, 135, 25, 60, 15, WS_TABSTOP -PUSHBUTTON "&Обзор...", PM_BROWSE, 135, 45, 60, 15, WS_TABSTOP -PUSHBUTTON "&Справка", PM_HELP, 135, 65, 60, 15, WS_TABSTOP +PUSHBUTTON "Îòìåíà", IDCANCEL, 135, 25, 60, 15, WS_TABSTOP +PUSHBUTTON "&Îáçîð...", PM_BROWSE, 135, 45, 60, 15, WS_TABSTOP +PUSHBUTTON "&Ñïðàâêà", PM_HELP, 135, 65, 60, 15, WS_TABSTOP } /* Strings */ -STRINGTABLE DISCARDABLE +STRINGTABLE DISCARDABLE LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT { -IDS_PROGRAM_MANAGER, "Диспетчер программ" -IDS_ERROR, "ОШИБКА" -IDS_WARNING, "ВНИМАНИЕ" -IDS_INFO, "Сведения" -IDS_DELETE, "Удалить" -IDS_DELETE_GROUP_s, "Удалить группу `%s' ?" -IDS_DELETE_PROGRAM_s, "Удалить программу `%s' ?" -IDS_NOT_IMPLEMENTED, "Ещё не реализовано" -IDS_FILE_READ_ERROR_s, "Ошибка чтения `%s'." -IDS_FILE_WRITE_ERROR_s, "Ошибка записи `%s'." +IDS_PROGRAM_MANAGER, "Äèñïåò÷åð ïðîãðàìì" +IDS_ERROR, "ÎØÈÁÊÀ" +IDS_WARNING, "ÂÍÈÌÀÍÈÅ" +IDS_INFO, "Ñâåäåíèÿ" +IDS_DELETE, "Óäàëèòü" +IDS_DELETE_GROUP_s, "Óäàëèòü ãðóïïó `%s' ?" +IDS_DELETE_PROGRAM_s, "Óäàëèòü ïðîãðàììó `%s' ?" +IDS_NOT_IMPLEMENTED, "Åù¸ íå ðåàëèçîâàíî" +IDS_FILE_READ_ERROR_s, "Îøèáêà ÷òåíèÿ `%s'." +IDS_FILE_WRITE_ERROR_s, "Îøèáêà çàïèñè `%s'." IDS_GRPFILE_READ_ERROR_s, "\ -Файл группы `%s' не может быть открыт.\n\ -Надо ли в следующий раз пытаться это сделать?" -IDS_OUT_OF_MEMORY, "Мало памяти." -IDS_WINHELP_ERROR, "Справка не доступна." -IDS_UNKNOWN_FEATURE_s, "Неизвестное свойство в %s" -IDS_FILE_NOT_OVERWRITTEN_s, "Файл `%s' существует. Он не был перезаписан." -IDS_SAVE_GROUP_AS_s, "Группа сохраняется под именем `%s' во избежание перезаписи оригинала." -IDS_NO_HOT_KEY, "Нет" -IDS_ALL_FILES, "Все файлы (*.*)" -IDS_PROGRAMS, "Программы" -IDS_LIBRARIES_DLL, "Библиотеки (*.dll)" -IDS_SYMBOL_FILES, "Файлы значков" -IDS_SYMBOLS_ICO, "Значки (*.ico)" +Ôàéë ãðóïïû `%s' íå ìîæåò áûòü îòêðûò.\n\ +Íàäî ëè â ñëåäóþùèé ðàç ïûòàòüñÿ ýòî ñäåëàòü?" +IDS_OUT_OF_MEMORY, "Ìàëî ïàìÿòè." +IDS_WINHELP_ERROR, "Ñïðàâêà íå äîñòóïíà." +IDS_UNKNOWN_FEATURE_s, "Íåèçâåñòíîå ñâîéñòâî â %s" +IDS_FILE_NOT_OVERWRITTEN_s, "Ôàéë `%s' ñóùåñòâóåò. Îí íå áûë ïåðåçàïèñàí." +IDS_SAVE_GROUP_AS_s, "Ãðóïïà ñîõðàíÿåòñÿ ïîä èìåíåì `%s' âî èçáåæàíèå ïåðåçàïèñè îðèãèíàëà." +IDS_NO_HOT_KEY, "Íåò" +IDS_ALL_FILES, "Âñå ôàéëû (*.*)" +IDS_PROGRAMS, "Ïðîãðàììû" +IDS_LIBRARIES_DLL, "Áèáëèîòåêè (*.dll)" +IDS_SYMBOL_FILES, "Ôàéëû çíà÷êîâ" +IDS_SYMBOLS_ICO, "Çíà÷êè (*.ico)" } diff --git a/programs/progman/Si.rc b/programs/progman/Si.rc index 17447050681..1d394fd1192 100644 --- a/programs/progman/Si.rc +++ b/programs/progman/Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - #pragma code_page(65001) /* Menu */ @@ -246,3 +244,5 @@ 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." } + +#pragma code_page(default) diff --git a/programs/progman/Sv.rc b/programs/progman/Sv.rc index 0d23948a270..be434974c5d 100644 --- a/programs/progman/Sv.rc +++ b/programs/progman/Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL diff --git a/programs/progman/TODO b/programs/progman/TODO new file mode 100644 index 00000000000..c3685a2d7a8 --- /dev/null +++ b/programs/progman/TODO @@ -0,0 +1,6 @@ +* Microsoft `*.grp' files use a checksum. + Find out how to calculate it. + +* Accelerators + +* Create some icons diff --git a/programs/progman/Tr.rc b/programs/progman/Tr.rc index 6407acd8539..a2963310b42 100644 --- a/programs/progman/Tr.rc +++ b/programs/progman/Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT diff --git a/programs/progman/Zh.rc b/programs/progman/Zh.rc index d78ac760760..d42a3f29595 100644 --- a/programs/progman/Zh.rc +++ b/programs/progman/Zh.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "progman.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -412,3 +410,5 @@ IDS_LIBRARIES_DLL, "動態連接庫 (*.dll)" IDS_SYMBOL_FILES, "圖標檔案" IDS_SYMBOLS_ICO, "圖標 (*.ico)" } + +#pragma code_page(default) diff --git a/programs/progman/accel.rc b/programs/progman/accel.rc index 44edae535c4..c86c0f39fa7 100644 --- a/programs/progman/accel.rc +++ b/programs/progman/accel.rc @@ -16,9 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include "progman.h" - ACCEL ACCELERATORS { VK_RETURN, PM_EXECUTE, VIRTKEY, ALT diff --git a/programs/progman/progman.h b/programs/progman/progman.h index aa22c6d14a2..5f7504ba6ce 100644 --- a/programs/progman/progman.h +++ b/programs/progman/progman.h @@ -26,8 +26,7 @@ #define MAX_PATHNAME_LEN 1024 #define MAX_LANGUAGE_NUMBER (PM_LAST_LANGUAGE - PM_FIRST_LANGUAGE) -#include -#include +#include "windows.h" /* Fallback icon */ #define DEFAULTICON OIC_WINLOGO diff --git a/programs/progman/rsrc.rc b/programs/progman/rsrc.rc new file mode 100644 index 00000000000..d6be7fd1882 --- /dev/null +++ b/programs/progman/rsrc.rc @@ -0,0 +1,42 @@ +/* + * Copyright 1996 Ulrich Schmid + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include +#include + +#include "progman.h" +#include "accel.rc" + +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Es.rc" +#include "Fr.rc" +#include "Hu.rc" +#include "It.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" diff --git a/programs/reg/Da.rc b/programs/reg/Da.rc index 353b94dc0fa..c385d0a0383 100644 --- a/programs/reg/Da.rc +++ b/programs/reg/Da.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "reg.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/reg/De.rc b/programs/reg/De.rc index 0940640306c..9768c606351 100644 --- a/programs/reg/De.rc +++ b/programs/reg/De.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "reg.h" - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -38,3 +36,5 @@ STRINGTABLE STRING_NO_REMOTE, "Fehler: Konnte Schlüssel nicht zum remote Rechner hinzufügen\n" STRING_CANNOT_FIND, "Fehler: Der angegebene Schlüssel oder Wert konnte nicht gefunden werden\n" } + +#pragma code_page(default) diff --git a/programs/reg/En.rc b/programs/reg/En.rc index 10cfa2be3a8..e7134162e99 100644 --- a/programs/reg/En.rc +++ b/programs/reg/En.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "reg.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/reg/Fr.rc b/programs/reg/Fr.rc index 1560c13fab2..671ebf69428 100644 --- a/programs/reg/Fr.rc +++ b/programs/reg/Fr.rc @@ -20,22 +20,17 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "reg.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE { STRING_USAGE, "La syntaxe de cette commande est :\n\nREG [ ADD | DELETE | QUERY ]\nREG commande /?\n" - STRING_ADD_USAGE, "REG ADD nom_de_clé [/v nom_de_valeur | /ve] [/t type] [/s séparateur] [/d données] [/f]\n" - STRING_DELETE_USAGE, "REG DELETE nom_de_clé [/v nom_de_valeur | /ve | /va] [/f]\n" - STRING_QUERY_USAGE, "REG QUERY nom_de_clé [/v nom_de_valeur | /ve] [/s]\n" - STRING_SUCCESS, "L'opération s'est terminée avec succès\n" - STRING_INVALID_KEY, "Erreur : nom de clé non valable\n" - STRING_INVALID_CMDLINE, "Erreur : paramètre de ligne de commande non valable\n" - STRING_NO_REMOTE, "Erreur : impossible d'ajouter des clés à une machine distante\n" - STRING_CANNOT_FIND, "Erreur : le système n'a pas pu trouver la clé ou la valeur de registre spécifiée\n" + STRING_ADD_USAGE, "REG ADD nom_de_clé [/v nom_de_valeur | /ve] [/t type] [/s séparateur] [/d donnée] [/f]\n" + STRING_DELETE_USAGE, "REG DELETE nom_de_clé [/v nom_de_valeur | /ve | /va] [/f]\n" + STRING_QUERY_USAGE, "REG QUERY nom_de_clé [/v nom_de_valeur | /ve] [/s]\n" + STRING_SUCCESS, "L'opération s'est terminée avec succès\n" + STRING_INVALID_KEY, "Erreur : Nom de clé non valable\n" + STRING_INVALID_CMDLINE, "Erreur : Paramètre de ligne de commande non valable\n" + STRING_NO_REMOTE, "Erreur : Impossible d'ajouter des clés à une machine distante\n" + STRING_CANNOT_FIND, "Erreur : Le système n'a pas été en mesure de trouver la clé ou la valeur de registre spécifiée\n" } diff --git a/programs/reg/Ja.rc b/programs/reg/Ja.rc index a2c1434216d..9163132fb9e 100644 --- a/programs/reg/Ja.rc +++ b/programs/reg/Ja.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "reg.h" - /* UTF-8 */ #pragma code_page(65001) @@ -33,3 +31,5 @@ STRINGTABLE STRING_DELETE_USAGE, "REG DELETE キー名 [/v 値名 | /ve | /va] [/f]\n" STRING_QUERY_USAGE, "REG QUERY キー名 [/v 値名 | /ve] [/s]\n" } + +#pragma code_page(default) diff --git a/programs/reg/Ko.rc b/programs/reg/Ko.rc index 46efd9165f4..e9ebbeebfc6 100644 --- a/programs/reg/Ko.rc +++ b/programs/reg/Ko.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "reg.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/reg/Lt.rc b/programs/reg/Lt.rc index 98aea185cbf..d0e0fe37616 100644 --- a/programs/reg/Lt.rc +++ b/programs/reg/Lt.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "reg.h" - /* UTF-8 */ #pragma code_page(65001) @@ -38,3 +36,5 @@ STRINGTABLE STRING_NO_REMOTE, "Klaida: Negalima pridėti raktų nuotoliniame kompiuteryje\n" STRING_CANNOT_FIND, "Klaida: Sistemai nepavyko rasti nurodyto registro rakto ar reikšmės\n" } + +#pragma code_page(default) diff --git a/programs/reg/Makefile.in b/programs/reg/Makefile.in index de4d2c8406e..6fb05f14534 100644 --- a/programs/reg/Makefile.in +++ b/programs/reg/Makefile.in @@ -10,20 +10,7 @@ DELAYIMPORTS = user32 C_SRCS = reg.c -RC_SRCS = \ - Da.rc \ - De.rc \ - En.rc \ - Fr.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Si.rc +RC_SRCS = rsrc.rc @MAKE_PROG_RULES@ diff --git a/programs/reg/Nl.rc b/programs/reg/Nl.rc index c34e39507a5..c6a89f16819 100644 --- a/programs/reg/Nl.rc +++ b/programs/reg/Nl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "reg.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE diff --git a/programs/reg/No.rc b/programs/reg/No.rc index cc43c39518d..5b9a33d5679 100644 --- a/programs/reg/No.rc +++ b/programs/reg/No.rc @@ -1,8 +1,8 @@ /* * REG.EXE - Wine-compatible reg program. - * Norwegian (Bokmål) language support + * Norwegian (Bokmål) language support * - * Copyright 2008-2009 Alexander N. Sørnes + * Copyright 2008 Alexander N. Sørnes * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -19,21 +19,12 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "reg.h" - -#pragma code_page(65001) - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE { - STRING_USAGE, "Programmer kjøres som følger:\n\nREG [ ADD | DELETE | QUERY ]\nREG kommando /?\n" - STRING_ADD_USAGE, "REG ADD nøkkelnavn [/v verdi | /ve] [/t type] [/s separator] [/d data] [/f]\n" - STRING_DELETE_USAGE, "REG DELETE nøkkelnavn [/v verdi | /ve | /va] [/f]\n" - STRING_QUERY_USAGE, "REG QUERY nøkkelnavn [/v verdi | /ve] [/s]\n" - STRING_SUCCESS, "Operasjonen ble utført\n" - STRING_INVALID_KEY, "Feil: Ugyldig nøkkelnavn\n" - STRING_INVALID_CMDLINE, "Feil: Ugyldige parametere på kommandolinjen\n" - STRING_NO_REMOTE, "Feil: Kan ikke legge til nøkler på ekstern maskin\n" - STRING_CANNOT_FIND, "Feil: Systemet klarte ikke finne den angitte registernøkkelen eller -verdien\n" + STRING_USAGE, "Programmer kjøres som følger:\n\nREG [ ADD | DELETE | QUERY ]\nREG kommando /?\n" + STRING_ADD_USAGE, "REG ADD nøkkelnavn [/v verdi | /ve] [/t type] [/s separator] [/d data] [/f]\n" + STRING_DELETE_USAGE, "REG DELETE nøkkelnavn [/v verdi | /ve | /va] [/f]\n" + STRING_QUERY_USAGE, "REG QUERY nøkkelnavn [/v verdi | /ve] [/s]\n" } diff --git a/programs/reg/Pl.rc b/programs/reg/Pl.rc index 01c42445324..51ae0e11bef 100644 --- a/programs/reg/Pl.rc +++ b/programs/reg/Pl.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "reg.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/reg/Pt.rc b/programs/reg/Pt.rc index 0de0e336149..2918883eb40 100644 --- a/programs/reg/Pt.rc +++ b/programs/reg/Pt.rc @@ -20,11 +20,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "reg.h" - -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE +LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE { @@ -32,9 +28,4 @@ STRINGTABLE STRING_ADD_USAGE, "REG ADD nome_chave [/v nome_valor | /ve] [/t tipo] [/s separador] [/d dados] [/f]\n" STRING_DELETE_USAGE, "REG DELETE nome_chave [/v nome_valor | /ve | /va] [/f]\n" STRING_QUERY_USAGE, "REG QUERY nome_chave [/v nome_valor | /ve] [/s]\n" - STRING_SUCCESS, "A operação foi completada com sucesso\n" - STRING_INVALID_KEY, "Erro: Nome de chave inválido\n" - STRING_INVALID_CMDLINE, "Erro: Parâmetros da linha de comandos inválidos\n" - STRING_NO_REMOTE, "Erro: Incapaz de adicionar chaves à máquina remota\n" - STRING_CANNOT_FIND, "Erro: O sistema foi incapaz de encontrar a chave de registo ou valor especificado\n" } diff --git a/programs/reg/Ru.rc b/programs/reg/Ru.rc index cac53a3ce43..0d895a36f7a 100644 --- a/programs/reg/Ru.rc +++ b/programs/reg/Ru.rc @@ -18,17 +18,12 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "reg.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE { - STRING_USAGE, "Использование программы:\n\nREG [ ADD | DELETE | QUERY ]\nREG <команда> /?\n" - STRING_ADD_USAGE, "REG ADD <ключ> [/v <параметр> | /ve] [/t <тип>] [/s <разделитель>] [/d данные] [/f]\n" - STRING_DELETE_USAGE, "REG DELETE <ключ> [/v <параметр> | /ve | /va] [/f]\n" - STRING_QUERY_USAGE, "REG QUERY <ключ> [/v <параметр> | /ve] [/s]\n" + STRING_USAGE, "Èñïîëüçâîâàíèå ïðîãðàììû:\n\nREG [ ADD | DELETE | QUERY ]\nREG <êîìàíäà> /?\n" + STRING_ADD_USAGE, "REG ADD <êëþ÷> [/v <ïàðàìåòð> | /ve] [/t <òèï>] [/s <ðàçäåëèòåü>] [/d äàííûå] [/f]\n" + STRING_DELETE_USAGE, "REG DELETE <êëþ÷> [/v <ïàðàìåòð> | /ve | /va] [/f]\n" + STRING_QUERY_USAGE, "REG QUERY <êëþ÷> [/v <ïàðàìåòð> | /ve] [/s]\n" } diff --git a/programs/reg/Si.rc b/programs/reg/Si.rc index 6f3e01cac06..284dcbba78d 100644 --- a/programs/reg/Si.rc +++ b/programs/reg/Si.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "reg.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -31,9 +29,6 @@ STRINGTABLE STRING_ADD_USAGE, "REG ADD ime_ključa [/v ime_vrednosti | /ve] [/t vrsta] [/s ločilo] [/d podatki] [/f]\n" STRING_DELETE_USAGE, "REG DELETE ime_ključa [/v ime_vrednosti | /ve | /va] [/f]\n" STRING_QUERY_USAGE, "REG QUERY ime_ključa [/v ime_vrednosti | /ve] [/s]\n" - STRING_SUCCESS, "Operacija se je uspešno izvedla\n" - STRING_INVALID_KEY, "Napaka: Napačno ime ključa\n" - STRING_INVALID_CMDLINE, "Napaka: Napačen parameter v ukazni vrstici\n" - STRING_NO_REMOTE, "Napaka: Na morem dodati ključa na oddaljen računalnik\n" - STRING_CANNOT_FIND, "Napaka: Sistem ni našel zahtevanega ključa ali vrednosti\n" } + +#pragma code_page(default) diff --git a/programs/reg/reg.c b/programs/reg/reg.c index a538d819a4b..823b4d956c4 100644 --- a/programs/reg/reg.c +++ b/programs/reg/reg.c @@ -147,14 +147,14 @@ static int reg_add(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, if (key_name[0]=='\\' && key_name[1]=='\\') { reg_message(STRING_NO_REMOTE); - return 1; + return 0; } p = strchrW(key_name,'\\'); if (!p) { reg_message(STRING_INVALID_KEY); - return 1; + return 0; } p++; @@ -162,13 +162,13 @@ static int reg_add(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, if (!root) { reg_message(STRING_INVALID_KEY); - return 1; + return 0; } if(RegCreateKeyW(root,p,&subkey)!=ERROR_SUCCESS) { reg_message(STRING_INVALID_KEY); - return 1; + return 0; } if (value_name || data) @@ -190,7 +190,7 @@ static int reg_add(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, { RegCloseKey(subkey); reg_message(STRING_INVALID_CMDLINE); - return 1; + return 0; } if (data) @@ -203,7 +203,7 @@ static int reg_add(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, RegCloseKey(subkey); reg_message(STRING_SUCCESS); - return 0; + return 1; } static int reg_delete(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, @@ -220,14 +220,14 @@ static int reg_delete(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, if (key_name[0]=='\\' && key_name[1]=='\\') { reg_message(STRING_NO_REMOTE); - return 1; + return 0; } p = strchrW(key_name,'\\'); if (!p) { reg_message(STRING_INVALID_KEY); - return 1; + return 0; } p++; @@ -235,19 +235,19 @@ static int reg_delete(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, if (!root) { reg_message(STRING_INVALID_KEY); - return 1; + return 0; } if (value_name && value_empty) { reg_message(STRING_INVALID_CMDLINE); - return 1; + return 0; } if (value_empty && value_all) { reg_message(STRING_INVALID_CMDLINE); - return 1; + return 0; } if (!force) @@ -260,16 +260,16 @@ static int reg_delete(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, if (RegDeleteTreeW(root,p)!=ERROR_SUCCESS) { reg_message(STRING_CANNOT_FIND); - return 1; + return 0; } reg_message(STRING_SUCCESS); - return 0; + return 1; } if(RegOpenKeyW(root,p,&subkey)!=ERROR_SUCCESS) { reg_message(STRING_CANNOT_FIND); - return 1; + return 0; } if (value_all) @@ -283,7 +283,7 @@ static int reg_delete(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, { RegCloseKey(subkey); reg_message(STRING_INVALID_CMDLINE); - return 1; + return 0; } rc = RegQueryInfoKeyW(subkey, NULL, NULL, NULL, NULL, NULL, NULL, NULL, @@ -292,7 +292,7 @@ static int reg_delete(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, { /* FIXME: failure */ RegCloseKey(subkey); - return 1; + return 0; } maxValue++; szValue = HeapAlloc(GetProcessHeap(),0,maxValue*sizeof(WCHAR)); @@ -320,7 +320,7 @@ static int reg_delete(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, { RegCloseKey(subkey); reg_message(STRING_CANNOT_FIND); - return 1; + return 0; } } else if (value_empty) @@ -330,7 +330,7 @@ static int reg_delete(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, RegCloseKey(subkey); reg_message(STRING_SUCCESS); - return 0; + return 1; } static int reg_query(WCHAR *key_name, WCHAR *value_name, BOOL value_empty, @@ -352,19 +352,16 @@ int wmain(int argc, WCHAR *argvW[]) static const WCHAR queryW[] = {'q','u','e','r','y',0}; static const WCHAR slashDW[] = {'/','d',0}; static const WCHAR slashFW[] = {'/','f',0}; - static const WCHAR slashHW[] = {'/','h',0}; static const WCHAR slashSW[] = {'/','s',0}; static const WCHAR slashTW[] = {'/','t',0}; static const WCHAR slashVW[] = {'/','v',0}; static const WCHAR slashVAW[] = {'/','v','a',0}; static const WCHAR slashVEW[] = {'/','v','e',0}; - static const WCHAR slashHelpW[] = {'/','?',0}; - if (argc < 2 || !lstrcmpW(argvW[1], slashHelpW) - || !lstrcmpiW(argvW[1], slashHW)) + if (argc < 2) { reg_message(STRING_USAGE); - return 0; + return 1; } if (!lstrcmpiW(argvW[1], addW)) @@ -374,14 +371,8 @@ int wmain(int argc, WCHAR *argvW[]) if (argc < 3) { - reg_message(STRING_INVALID_CMDLINE); - return 1; - } - else if (argc == 3 && (!lstrcmpW(argvW[2], slashHelpW) || - !lstrcmpiW(argvW[2], slashHW))) - { reg_message(STRING_ADD_USAGE); - return 0; + return 1; } key_name = argvW[2]; @@ -410,14 +401,8 @@ int wmain(int argc, WCHAR *argvW[]) if (argc < 3) { - reg_message(STRING_INVALID_CMDLINE); - return 1; - } - else if (argc == 3 && (!lstrcmpW(argvW[2], slashHelpW) || - !lstrcmpiW(argvW[2], slashHW))) - { reg_message(STRING_DELETE_USAGE); - return 0; + return 1; } key_name = argvW[2]; @@ -441,14 +426,8 @@ int wmain(int argc, WCHAR *argvW[]) if (argc < 3) { - reg_message(STRING_INVALID_CMDLINE); - return 1; - } - else if (argc == 3 && (!lstrcmpW(argvW[2], slashHelpW) || - !lstrcmpiW(argvW[2], slashHW))) - { reg_message(STRING_QUERY_USAGE); - return 0; + return 1; } key_name = argvW[2]; @@ -463,9 +442,6 @@ int wmain(int argc, WCHAR *argvW[]) } return reg_query(key_name, value_name, value_empty, subkey); } - else - { - reg_message(STRING_INVALID_CMDLINE); - return 1; - } + + return 0; } diff --git a/programs/reg/reg.h b/programs/reg/reg.h index 2221647168c..6d4ae478a1d 100644 --- a/programs/reg/reg.h +++ b/programs/reg/reg.h @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include - /* Translation IDs. */ #define STRING_USAGE 101 #define STRING_ADD_USAGE 102 diff --git a/programs/reg/rsrc.rc b/programs/reg/rsrc.rc new file mode 100644 index 00000000000..aa70a4b9c80 --- /dev/null +++ b/programs/reg/rsrc.rc @@ -0,0 +1,37 @@ +/* + * Copyright 2008 Andrew Riedi + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include + +#include "reg.h" + +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Fr.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Lt.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" diff --git a/programs/regedit/Bg.rc b/programs/regedit/Bg.rc index 3ff32ace9bc..0ac8e5794b4 100644 --- a/programs/regedit/Bg.rc +++ b/programs/regedit/Bg.rc @@ -18,7 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT diff --git a/programs/regedit/Cs.rc b/programs/regedit/Cs.rc index f8741bf7f31..acfb4973f0c 100644 --- a/programs/regedit/Cs.rc +++ b/programs/regedit/Cs.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/programs/regedit/Da.rc b/programs/regedit/Da.rc index d49727de7d1..fd499d0c237 100644 --- a/programs/regedit/Da.rc +++ b/programs/regedit/Da.rc @@ -18,9 +18,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -LANGUAGE LANG_DANISH, SUBLANG_DEFAULT + LANGUAGE LANG_DANISH, SUBLANG_DEFAULT /* * Menu diff --git a/programs/regedit/De.rc b/programs/regedit/De.rc index 84ed865aea7..b84a1e13439 100644 --- a/programs/regedit/De.rc +++ b/programs/regedit/De.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -338,3 +336,5 @@ BEGIN END /*****************************************************************/ + +#pragma code_page(default) diff --git a/programs/regedit/En.rc b/programs/regedit/En.rc index 8d127ad4887..b5d6f6da78b 100644 --- a/programs/regedit/En.rc +++ b/programs/regedit/En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* English Neutral Resources */ LANGUAGE LANG_ENGLISH, SUBLANG_NEUTRAL @@ -97,29 +95,6 @@ BEGIN END END -IDD_ADDFAVORITE DIALOG DISCARDABLE 22, 17, 210, 55 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Add Favourite" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Name:",IDC_STATIC,5,5,119,8 - EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL - DEFPUSHBUTTON "OK",IDOK,120,36,40,15,WS_GROUP - PUSHBUTTON "Cancel",IDCANCEL,165,36,40,15,WS_GROUP -END - -IDD_DELFAVORITE DIALOG DISCARDABLE 22, 17, 210, 90 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Remove Favourite" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Name:",IDC_STATIC,5,5,119,8 - LISTBOX IDC_NAME_LIST,5,15,200,52, WS_BORDER | WS_TABSTOP | LBS_SORT | LBS_NOINTEGRALHEIGHT | WS_VSCROLL - DEFPUSHBUTTON "OK",IDOK,120,72,40,15,WS_GROUP - PUSHBUTTON "Cancel",IDCANCEL,165,72,40,15,WS_GROUP -END - - /* English Default (US) Resources */ LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT diff --git a/programs/regedit/Es.rc b/programs/regedit/Es.rc index c6d3f95e877..0c08a481a6a 100644 --- a/programs/regedit/Es.rc +++ b/programs/regedit/Es.rc @@ -2,7 +2,6 @@ * Regedit resources * * Copyright 2003,2004,2007,2008 José Manuel Ferrer Ortiz - * Copyright 2009 Jaime Andres Rave Torres * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -19,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL /* @@ -286,7 +283,6 @@ BEGIN ID_EDIT_COPYKEYNAME "Copia el nombre de la clave seleccionada al portapapeles" ID_EDIT_FIND "Busca una cadena de texto en una clave, valor o datos" ID_EDIT_FINDNEXT "Busca la siguiente ocurrencia del texto especificado en la búsqueda anterior" - ID_EDIT_EXPORT "Exporta la rama seleccionada del registro a un archivo de texto" END STRINGTABLE DISCARDABLE diff --git a/programs/regedit/Fr.rc b/programs/regedit/Fr.rc index 980866bddbd..9e197cf6a51 100644 --- a/programs/regedit/Fr.rc +++ b/programs/regedit/Fr.rc @@ -1,8 +1,8 @@ /* - * Regedit French resources + * Regedit resources * * Copyright 2002 Robert Dickenson - * Copyright 2003 Vincent Béron + * Copyright 2003 Vincent Béron * Copyright 2005-2009 Jonathan Ernst * * This library is free software; you can redistribute it and/or @@ -20,11 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL /* @@ -33,47 +28,47 @@ LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL IDR_REGEDIT_MENU MENU DISCARDABLE BEGIN - POPUP "&Registre" + POPUP "&Registres" BEGIN - MENUITEM "&Importer un fichier registre...", ID_REGISTRY_IMPORTREGISTRYFILE - MENUITEM "&Exporter un fichier registre...", ID_REGISTRY_EXPORTREGISTRYFILE + MENUITEM "&Importer un fichier de registres...", ID_REGISTRY_IMPORTREGISTRYFILE + MENUITEM "&Exporter un fichier de registres...", ID_REGISTRY_EXPORTREGISTRYFILE MENUITEM SEPARATOR - MENUITEM "Se &connecter à un registre via le réseau...", ID_REGISTRY_CONNECTNETWORKREGISTRY, GRAYED - MENUITEM "Se &déconnecter d'un registre réseau...", ID_REGISTRY_DISCONNECTNETWORKREGISTRY, GRAYED + MENUITEM "&Connecter à des registres via le réseau...", ID_REGISTRY_CONNECTNETWORKREGISTRY, GRAYED + MENUITEM "&Déconnecter de registres réseau...", ID_REGISTRY_DISCONNECTNETWORKREGISTRY, GRAYED MENUITEM SEPARATOR MENUITEM "Im&primer\tCtrl+P", ID_REGISTRY_PRINT, GRAYED MENUITEM SEPARATOR MENUITEM "&Quitter", ID_REGISTRY_EXIT END - POPUP "É&dition" + POPUP "É&dition" BEGIN MENUITEM "&Modifier", ID_EDIT_MODIFY MENUITEM SEPARATOR POPUP "&Nouvelle" BEGIN - MENUITEM "&Clé", ID_EDIT_NEW_KEY + MENUITEM "&Clé", ID_EDIT_NEW_KEY MENUITEM SEPARATOR - MENUITEM "Valeur c&haîne", ID_EDIT_NEW_STRINGVALUE + MENUITEM "Valeur c&haîne", ID_EDIT_NEW_STRINGVALUE MENUITEM "Valeur &binaire", ID_EDIT_NEW_BINARYVALUE - MENUITEM "Valeur &DWORD", ID_EDIT_NEW_DWORDVALUE - MENUITEM "Valeur de chaîne &extensible", ID_EDIT_NEW_MULTI_STRINGVALUE + MENUITEM "Valeur &mot double", ID_EDIT_NEW_DWORDVALUE + MENUITEM "Valeur chaîne &multiple", ID_EDIT_NEW_MULTI_STRINGVALUE END MENUITEM SEPARATOR MENUITEM "&Supprimer\tSuppr", ID_EDIT_DELETE MENUITEM "Ren&ommer\tF2", ID_EDIT_RENAME MENUITEM SEPARATOR - MENUITEM "&Copier le nom de la clé", ID_EDIT_COPYKEYNAME + MENUITEM "&Copier le nom de la clé", ID_EDIT_COPYKEYNAME MENUITEM SEPARATOR MENUITEM "&Rechercher...\tCtrl+F", ID_EDIT_FIND, GRAYED MENUITEM "Rechercher le s&uivant\tF3", ID_EDIT_FINDNEXT, GRAYED END POPUP "&Affichage" BEGIN - MENUITEM "&Barre d'état", ID_VIEW_STATUSBAR + MENUITEM "&Barre d'état", ID_VIEW_STATUSBAR MENUITEM SEPARATOR - MENUITEM "&Séparateur", ID_VIEW_SPLIT + MENUITEM "&Séparateur", ID_VIEW_SPLIT MENUITEM SEPARATOR - MENUITEM "&Rafraîchir\tF5", ID_VIEW_REFRESH + MENUITEM "&Rafraîchir\tF5", ID_VIEW_REFRESH END POPUP "&Signets" BEGIN @@ -84,7 +79,7 @@ BEGIN BEGIN MENUITEM "&Sommaire\tF1", ID_HELP_HELPTOPICS MENUITEM SEPARATOR - MENUITEM "À &propos de l'éditeur du registre", ID_HELP_ABOUT + MENUITEM "À &propos de l'éditeur de registres", ID_HELP_ABOUT END END @@ -93,28 +88,28 @@ BEGIN POPUP "" BEGIN MENUITEM "&Modifier", ID_EDIT_MODIFY - MENUITEM "Modifier les données &binaires", ID_EDIT_MODIFY_BIN + MENUITEM "Modifier données binaires", ID_EDIT_MODIFY_BIN MENUITEM SEPARATOR - MENUITEM "&Supprimer\tDel", ID_EDIT_DELETE + MENUITEM "&Supprimer\tDel", ID_EDIT_DELETE MENUITEM "Ren&ommer", ID_EDIT_RENAME END POPUP "" BEGIN POPUP "&Nouvelle" BEGIN - MENUITEM "&Clé", ID_EDIT_NEW_KEY + MENUITEM "&Clé", ID_EDIT_NEW_KEY MENUITEM SEPARATOR - MENUITEM "Valeur c&haîne", ID_EDIT_NEW_STRINGVALUE + MENUITEM "Valeur c&haîne", ID_EDIT_NEW_STRINGVALUE MENUITEM "Valeur &binaire", ID_EDIT_NEW_BINARYVALUE - MENUITEM "Valeur &DWORD", ID_EDIT_NEW_DWORDVALUE - MENUITEM "Valeur de chaîne &extensible", ID_EDIT_NEW_MULTI_STRINGVALUE + MENUITEM "Valeur &mot double", ID_EDIT_NEW_DWORDVALUE + MENUITEM "Valeur chaîne &multiple", ID_EDIT_NEW_MULTI_STRINGVALUE END MENUITEM SEPARATOR MENUITEM "&Supprimer\tDel", ID_EDIT_DELETE MENUITEM "Ren&ommer\tF2", ID_EDIT_RENAME MENUITEM SEPARATOR MENUITEM "&Exporter...", ID_EDIT_EXPORT - MENUITEM "&Copier le nom de la clé", ID_EDIT_COPYKEYNAME + MENUITEM "&Copier le nom de la clé", ID_EDIT_COPYKEYNAME MENUITEM SEPARATOR MENUITEM "&Rechercher\tCtrl+F", ID_EDIT_FIND, GRAYED END @@ -132,8 +127,8 @@ FONT 8, "MS Shell Dlg" BEGIN GROUPBOX "&Exporter le registre", IDC_EXPORT_BASE, 6, 6, 266, 42, WS_GROUP AUTORADIOBUTTON "&Tout", IDC_EXPORT_ALL, 12, 15, 244, 12 - AUTORADIOBUTTON "Branche &sélectionnée :", IDC_EXPORT_SELECTED, 12, 30, 85, 12 - EDITTEXT IDC_EXPORT_PATH, 100, 30, 166, 12 + AUTORADIOBUTTON "&Sélectionner une branche :", IDC_EXPORT_SELECTED, 12, 30, 70, 12 + EDITTEXT IDC_EXPORT_PATH, 82, 30, 184, 12 END IDD_FIND DIALOG DISCARDABLE 22, 17, 210, 85 @@ -141,26 +136,26 @@ STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU CAPTION "Recherche" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "Rechercher :",IDC_STATIC,5,7,60,8 - EDITTEXT IDC_VALUE_NAME,49,5,115,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL - LTEXT "Regarder dans :",IDC_STATIC,5, 22, 119, 8 - CHECKBOX "Clés", IDC_FIND_KEYS, 5, 34, 90, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX + LTEXT "Rechercher :",IDC_STATIC,5,7,119,8 + EDITTEXT IDC_VALUE_NAME,40,5,125,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL + LTEXT "Regarder dans :",IDC_STATIC,5, 22, 119, 8 + CHECKBOX "Clés", IDC_FIND_KEYS, 5, 34, 90, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX CHECKBOX "Valeurs", IDC_FIND_VALUES, 5, 46, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX - CHECKBOX "Données", IDC_FIND_CONTENT, 5, 58, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX + CHECKBOX "Données", IDC_FIND_CONTENT, 5, 58, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX CHECKBOX "Mot entier seulement", IDC_FIND_WHOLE, 5, 70, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX - DEFPUSHBUTTON "Suivant",IDOK,170,5,35,15,WS_GROUP - PUSHBUTTON "Fermer",IDCANCEL,170,22,35,15, WS_GROUP + DEFPUSHBUTTON "Suivant",IDOK,175,5,30,11,WS_GROUP + PUSHBUTTON "Fermer",IDCANCEL,175,22,30,11, WS_GROUP END -IDD_ADDFAVORITE DIALOG DISCARDABLE 22, 17, 209, 52 +IDD_ADDFAVORITE DIALOG DISCARDABLE 22, 17, 210, 55 STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU CAPTION "Ajouter aux signets" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "Nom du signet :",IDC_STATIC,5,5,119,8 + LTEXT "Nom du signet :",IDC_STATIC,5,5,119,8 EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL - DEFPUSHBUTTON "OK",IDOK,123,33,35,15,WS_GROUP - PUSHBUTTON "Annuler",IDCANCEL,163,33,35,15, WS_GROUP + DEFPUSHBUTTON "OK",IDOK,140,40,30,11,WS_GROUP + PUSHBUTTON "Annuler",IDCANCEL,175,40,30,11, WS_GROUP END IDD_DELFAVORITE DIALOG DISCARDABLE 22, 17, 210, 90 @@ -168,39 +163,39 @@ STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU CAPTION "Supprimer les signets" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "Sélectionnez un ou plusieurs signets :",IDC_STATIC,5,5,119,8 + LTEXT "Sélectionnez un ou plusieurs signets :",IDC_STATIC,5,5,119,8 LISTBOX IDC_NAME_LIST,5,15,200,52, WS_BORDER | WS_TABSTOP | LBS_SORT | LBS_NOINTEGRALHEIGHT | WS_VSCROLL - DEFPUSHBUTTON "OK",IDOK,130,72,35,15,WS_GROUP - PUSHBUTTON "Annuler",IDCANCEL,170,72,35,15, WS_GROUP + DEFPUSHBUTTON "OK",IDOK,140,73,30,11,WS_GROUP + PUSHBUTTON "Annuler",IDCANCEL,175,73,30,11, WS_GROUP END IDD_EDIT_STRING DIALOG DISCARDABLE 22, 17, 210, 75 STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Modification de la chaîne" +CAPTION "Modification de la chaîne" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "Nom de la valeur :",IDC_STATIC,5,5,119,8 + LTEXT "Nom de la valeur :",IDC_STATIC,5,5,119,8 EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL | WS_DISABLED - LTEXT "Données de la valeur :",IDC_STATIC,5,30,119,8 + LTEXT "Données de la valeur :",IDC_STATIC,5,30,119,8 EDITTEXT IDC_VALUE_DATA,5,40,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL - DEFPUSHBUTTON "OK",IDOK,130,57,35,15,WS_GROUP - PUSHBUTTON "Annuler",IDCANCEL,170,57,35,15,WS_GROUP + DEFPUSHBUTTON "OK",IDOK,140,60,30,11,WS_GROUP + PUSHBUTTON "Annuler",IDCANCEL,175,60,30,11,WS_GROUP END -IDD_EDIT_DWORD DIALOG DISCARDABLE 22, 17, 210, 90 +IDD_EDIT_DWORD DIALOG DISCARDABLE 22, 17, 210, 100 STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU CAPTION "Modification de la valeur DWORD" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "Nom de la valeur :",IDC_STATIC,5,5,119,8 + LTEXT "Nom de la valeur :",IDC_STATIC,5,5,119,8 EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL | WS_DISABLED - LTEXT "Données de valeur :",IDC_STATIC,5,30,90,8 + LTEXT "Données de valeur :",IDC_STATIC,5,30,90,8 EDITTEXT IDC_VALUE_DATA,5,40,90,12, WS_BORDER | WS_TABSTOP GROUPBOX "Base", IDC_DWORD_BASE, 120, 30, 85, 37, BS_GROUPBOX - AUTORADIOBUTTON "Hexadécimale", IDC_DWORD_HEX, 130, 40, 60, 10, WS_TABSTOP - AUTORADIOBUTTON "Décimale", IDC_DWORD_DEC, 130, 52, 60, 10, WS_TABSTOP - DEFPUSHBUTTON "OK",IDOK,130,72,35,15,WS_GROUP - PUSHBUTTON "Annuler",IDCANCEL,170,72,35,15,WS_GROUP + AUTORADIOBUTTON "Hexadécimale", IDC_DWORD_HEX, 130, 40, 60, 10, WS_TABSTOP + AUTORADIOBUTTON "Décimale", IDC_DWORD_DEC, 130, 52, 60, 10, WS_TABSTOP + DEFPUSHBUTTON "OK",IDOK,140,80,30,11,WS_GROUP + PUSHBUTTON "Annuler",IDCANCEL,175,80,30,11,WS_GROUP END IDD_EDIT_BINARY DIALOG DISCARDABLE 22, 17, 210, 100 @@ -208,25 +203,25 @@ STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU CAPTION "Modification de la valeur binaire" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "Nom de la valeur :",IDC_STATIC,5,5,119,8 + LTEXT "Nom de la valeur :",IDC_STATIC,5,5,119,8 EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL| WS_DISABLED - LTEXT "Données de la valeur :",IDC_STATIC,5,30,90,8 + LTEXT "Données de la valeur :",IDC_STATIC,5,30,90,8 CONTROL "",IDC_VALUE_DATA,"HexEdit",WS_TABSTOP,4,40,160,40 - DEFPUSHBUTTON "OK",IDOK,130,83,35,15,WS_GROUP - PUSHBUTTON "Annuler",IDCANCEL,170,83,35,15,WS_GROUP + DEFPUSHBUTTON "OK",IDOK,140,80,30,11,WS_GROUP + PUSHBUTTON "Annuler",IDCANCEL,175,80,30,11,WS_GROUP END IDD_EDIT_MULTI_STRING DIALOG DISCARDABLE 22, 17, 210, 175 STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Modification de la chaîne extensible" +CAPTION "Edit Multi String" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "Nom de la valeur :",IDC_STATIC,5,5,119,8 + LTEXT "Nom de la valeur :",IDC_STATIC,5,5,119,8 EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL| WS_DISABLED - LTEXT "Données de la valeur :",IDC_STATIC,5,30,119,8 + LTEXT "Données de la valeur :",IDC_STATIC,5,30,119,8 EDITTEXT IDC_VALUE_DATA,5,40,200,112, WS_BORDER | WS_TABSTOP | WS_HSCROLL | WS_VSCROLL | ES_MULTILINE | ES_WANTRETURN - DEFPUSHBUTTON "OK",IDOK,130,157,35,15,WS_GROUP - PUSHBUTTON "Annuler",IDCANCEL,170,157,35,15,WS_GROUP + DEFPUSHBUTTON "OK",IDOK,140,160,30,11,WS_GROUP + PUSHBUTTON "Annuler",IDCANCEL,175,160,30,11,WS_GROUP END /* @@ -242,68 +237,68 @@ END STRINGTABLE DISCARDABLE BEGIN - IDS_APP_TITLE "Éditeur du registre" + IDS_APP_TITLE "Éditeur de registres" END STRINGTABLE DISCARDABLE BEGIN - ID_REGISTRY_MENU "Contient des commandes pour travailler sur le registres entier" - ID_EDIT_MENU "Contient des commandes pour éditer des valeurs ou des clés" - ID_VIEW_MENU "Contient des commandes pour personnaliser la fenêtre du registre" - ID_FAVORITES_MENU "Contient des commandes pour accéder aux clés fréquemment utilisées" - ID_HELP_MENU "Contient des commandes pour afficher de l'aide et de l'information à propos de l'éditeur du registre" - ID_EDIT_NEW_MENU "Contient des commandes pour créer de nouvelles clés ou valeurs" + ID_REGISTRY_MENU "Contient des commandes pour travailler sur les registres de manière globale" + ID_EDIT_MENU "Contient des commandes pour éditer des valeurs ou des clés" + ID_VIEW_MENU "Contient des commandes pour personnaliser la fenêtre des registres" + ID_FAVORITES_MENU "Contient des commandes pour accéder aux clés fréquemment utilisées" + ID_HELP_MENU "Contient des commandes pour afficher de l'aide et de l'information à propos de l'éditeur de registres" + ID_EDIT_NEW_MENU "Contient des commandes pour créer de nouvelles clés ou valeurs" END STRINGTABLE DISCARDABLE BEGIN - ID_EDIT_MODIFY "Modifie les données d'une valeur" - ID_EDIT_NEW_KEY "Ajoute une nouvelle clé" - ID_EDIT_NEW_STRINGVALUE "Ajoute une nouvelle valeur chaîne" + ID_EDIT_MODIFY "Modifie les données d'une valeur" + ID_EDIT_NEW_KEY "Ajoute une nouvelle clé" + ID_EDIT_NEW_STRINGVALUE "Ajoute une nouvelle valeur chaîne" ID_EDIT_NEW_BINARYVALUE "Ajoute une nouvelle valeur binaire" - ID_EDIT_NEW_DWORDVALUE "Ajoute une nouvelle valeur DWORD" - ID_EDIT_NEW_MULTI_STRINGVALUE "Ajoute une nouvelle valeur chaîne extensible" - ID_REGISTRY_IMPORTREGISTRYFILE "Importe un fichier texte dans le registre" + ID_EDIT_NEW_DWORDVALUE "Ajoute une nouvelle valeur mot double" + ID_EDIT_NEW_MULTI_STRINGVALUE "Ajoute une nouvelle valeur chaîne multiple" + ID_REGISTRY_IMPORTREGISTRYFILE "Importe un fichier texte dans les registres" ID_REGISTRY_EXPORTREGISTRYFILE - "Exporte tout ou partie du registre dans un fichier texte" + "Exporte tout ou une partie des registres dans un fichier texte" ID_REGISTRY_CONNECTNETWORKREGISTRY - "Se connecte au registre d'un ordinateur distant" + "Connecte aux registres d'un ordinateur distant" ID_REGISTRY_DISCONNECTNETWORKREGISTRY - "Se déconnecte du registre d'un ordinateur distant" - ID_REGISTRY_PRINT "Imprime tout ou partie du registre" -/* ID_HELP_HELPTOPICS "Ouvre l'aide de l'éditeur du registre" */ - ID_HELP_ABOUT "Affiche de l'information sur le programme, le numéro de version et le copyright" + "Déconnecte des registres d'un ordinateur distant" + ID_REGISTRY_PRINT "Imprime tout ou une partie des registres" +/* ID_HELP_HELPTOPICS "Ouvre l'aide de l'éditeur de registres" */ + ID_HELP_ABOUT "Affiche de l'information sur le programme, le numéro de version et le copyright" END STRINGTABLE DISCARDABLE BEGIN - ID_REGISTRY_EXIT "Quitte l'éditeur du registre" - ID_FAVORITES_ADDTOFAVORITES "Ajoute des clés à la liste des signets" - ID_FAVORITES_REMOVEFAVORITE "Retire des clés de la liste des signets" - ID_VIEW_STATUSBAR "Montre ou cache la barre d'état" - ID_VIEW_SPLIT "Change la position de la séparation entre les deux panneaux" - ID_VIEW_REFRESH "Actualise la fenêtre" - ID_EDIT_DELETE "Supprime la sélection" - ID_EDIT_RENAME "Renomme la sélection" - ID_EDIT_COPYKEYNAME "Copie le nom de la clé sélectionnée vers le presse-papiers" - ID_EDIT_FIND "Recherche du texte dans une clé, une valeur ou des données" - ID_EDIT_FINDNEXT "Recherche l'occurrence suivante du texte de la dernière recherche" - ID_EDIT_EXPORT "Exporte la branche du registre sélectionnée dans un fichier texte" + ID_REGISTRY_EXIT "Quitte l'éditeur de registres" + ID_FAVORITES_ADDTOFAVORITES "Ajoute des clés à la liste des signets" + ID_FAVORITES_REMOVEFAVORITE "Retire des clés de la liste des signets" + ID_VIEW_STATUSBAR "Montre ou cache la barre d'état" + ID_VIEW_SPLIT "Change la position de la séparation entre les deux panneaux" + ID_VIEW_REFRESH "Rafraîchit la fenêtre" + ID_EDIT_DELETE "Supprime la sélection" + ID_EDIT_RENAME "Renomme la sélection" + ID_EDIT_COPYKEYNAME "Copie le nom de la clé sélectionnée vers le presse-papier" + ID_EDIT_FIND "Recherche du texte dans une clé, une valeur ou des données" + ID_EDIT_FINDNEXT "Recherche l'occurence suivante du texte de la dernière recherche" + ID_EDIT_EXPORT "Exporte la branche du registre sélectionnée dans un fichier texte" END STRINGTABLE DISCARDABLE BEGIN IDS_ERROR "Erreur" - IDS_BAD_KEY "Ne peut pas chercher la clé '%s'" - IDS_BAD_VALUE "Ne peut pas chercher la valeur '%s'" - IDS_UNSUPPORTED_TYPE "Ne peut pas éditer des clés de ce type (%u)" + IDS_BAD_KEY "Ne peut pas questionner la clé '%s'" + IDS_BAD_VALUE "Ne peut pas questionner la valeur '%s'" + IDS_UNSUPPORTED_TYPE "Ne peut pas éditer des clés de ce type (%u)" IDS_TOO_BIG_VALUE "La valeur est trop grande (%u)" IDS_DELETE_BOX_TITLE "Confirmez l'effacement de valeur" - IDS_DELETE_BOX_TEXT "Voulez-vous réellement supprimer la valeur '%s' ?" - IDS_DELETE_BOX_TEXT_MULTIPLE "Voulez-vous réellement supprimer ces valeurs ?" - IDS_NEWKEY "Nouvelle clé #%d" - IDS_NEWVALUE "Nouvelle valeur #%d" - IDS_NOTFOUND "Occurrence de '%s' non trouvée" + IDS_DELETE_BOX_TEXT "Êtes vous sûr vous voulez supprimer la valeur '%s'?" + IDS_DELETE_BOX_TEXT_MULTIPLE "Êtes vous sûr vous voulez supprimer cette valeurs?" + IDS_NEWKEY "Nouvelle Clé #%d" + IDS_NEWVALUE "Nouvelle Valeur #%d" + IDS_NOTFOUND "Occurence de '%s' non trouvée" END STRINGTABLE DISCARDABLE @@ -316,8 +311,8 @@ END STRINGTABLE DISCARDABLE BEGIN IDS_REGISTRY_ROOT_NAME "Poste de travail" - IDS_REGISTRY_DEFAULT_VALUE "(par défaut)" - IDS_REGISTRY_VALUE_NOT_SET "(valeur non définie)" + IDS_REGISTRY_DEFAULT_VALUE "(par défaut)" + IDS_REGISTRY_VALUE_NOT_SET "(valeur non définie)" IDS_REGISTRY_VALUE_CANT_DISPLAY "(impossible d'afficher la valeur)" IDS_REGISTRY_UNKNOWN_TYPE "(%d inconnu)" END diff --git a/programs/regedit/Hu.rc b/programs/regedit/Hu.rc index fb893e1c119..6f2349e5727 100644 --- a/programs/regedit/Hu.rc +++ b/programs/regedit/Hu.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Hungarian Resources */ LANGUAGE LANG_HUNGARIAN, SUBLANG_NEUTRAL diff --git a/programs/regedit/It.rc b/programs/regedit/It.rc index e06aa67676d..f74942a2783 100644 --- a/programs/regedit/It.rc +++ b/programs/regedit/It.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL /* @@ -190,7 +188,7 @@ END IDD_EDIT_BINARY DIALOG DISCARDABLE 22, 17, 210, 100 STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "Modifica Binario" +CAPTION "Edita Binario" FONT 8, "MS Shell Dlg" BEGIN LTEXT "Nome del valore:",IDC_STATIC,5,5,119,8 @@ -266,14 +264,14 @@ BEGIN IDS_ERROR "Errore" IDS_BAD_KEY "Impossibile trovare la chiave '%s'" IDS_BAD_VALUE "Impossibile trovare il valore '%s'" - IDS_UNSUPPORTED_TYPE "Impossibile modificare valori di questo tipo (%u)" + IDS_UNSUPPORTED_TYPE "Impossibile editare valori di questo tipo (%u)" IDS_TOO_BIG_VALUE "Valore troppo grande (%u)" - IDS_DELETE_BOX_TITLE "Confermare Eliminazione del Valore" - IDS_DELETE_BOX_TEXT "Sei sicuro di volere eliminare il valore '%s'?" - IDS_DELETE_BOX_TEXT_MULTIPLE "Sei sicuro di volere eliminare questi valori?" + IDS_DELETE_BOX_TITLE "Confermare Cancellazione del Valore" + IDS_DELETE_BOX_TEXT "Sei sicuro di voler cancellare il valore '%s'?" + IDS_DELETE_BOX_TEXT_MULTIPLE "Are you sure you want to delete these values?" IDS_NEWKEY "Nuova Chiave #%d" IDS_NEWVALUE "Nuovo Valore #%d" - IDS_NOTFOUND "Stringa di ricerca '%s' non trovata" + IDS_NOTFOUND "Search string '%s' not found" END /*****************************************************************/ diff --git a/programs/regedit/Ja.rc b/programs/regedit/Ja.rc index 4175acd29b2..c52567f30e1 100644 --- a/programs/regedit/Ja.rc +++ b/programs/regedit/Ja.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -331,3 +329,5 @@ BEGIN END /*****************************************************************/ + +#pragma code_page(default) diff --git a/programs/regedit/Ko.rc b/programs/regedit/Ko.rc index c9bbfa1ed2b..17905d71c99 100644 --- a/programs/regedit/Ko.rc +++ b/programs/regedit/Ko.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Korean resources */ LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT diff --git a/programs/regedit/Lt.rc b/programs/regedit/Lt.rc index a2dffef60f0..83ff5bbdbb9 100644 --- a/programs/regedit/Lt.rc +++ b/programs/regedit/Lt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -258,7 +256,7 @@ BEGIN ID_EDIT_MODIFY "Modifikuoja reikšmės duomenis" ID_EDIT_NEW_KEY "Prideda naują raktą" ID_EDIT_NEW_STRINGVALUE "Prideda naują eilutės reikšmę" - ID_EDIT_NEW_BINARYVALUE "Prideda naują dvejetainę reikšmę" + ID_EDIT_NEW_BINARYVALUE "Prideda naują dvejeteinę reikšmę" ID_EDIT_NEW_DWORDVALUE "Prideda naują dvigubojo žodžio reikšmę" ID_EDIT_NEW_MULTI_STRINGVALUE "Prideda naują kelių eilučių reikšmę" ID_REGISTRY_IMPORTREGISTRYFILE "Importuoja tekstinį failą į registrą" @@ -277,7 +275,7 @@ BEGIN ID_REGISTRY_EXIT "Išeina iš registro tvarkytuvės" ID_FAVORITES_ADDTOFAVORITES "Prideda pasirinktą raktą į adresyną" ID_FAVORITES_REMOVEFAVORITE "Pašalina nurodytus raktus iš adresyno" - ID_VIEW_STATUSBAR "Parodo arba paslepia būsenos juostą" + ID_VIEW_STATUSBAR "Parodo arba paslėpia būsenos juostą" ID_VIEW_SPLIT "Pakeičia polangių skirtuko poziciją tarp polangių" ID_VIEW_REFRESH "Atnaujina langą" ID_EDIT_DELETE "Šalina atranką" @@ -291,16 +289,16 @@ END STRINGTABLE DISCARDABLE BEGIN IDS_ERROR "Klaida" - IDS_BAD_KEY "Nepavyko perskaityti rakto „%s“" - IDS_BAD_VALUE "Nepavyko perskaityti reikšmės „%s“" + IDS_BAD_KEY "Nepavyko perskaityti rakto '%s'" + IDS_BAD_VALUE "Nepavyko perskaityti reikšmės '%s'" IDS_UNSUPPORTED_TYPE "Šio tipo raktų redaguoti negalima (%u)" IDS_TOO_BIG_VALUE "Reikšmė per didelė (%u)" IDS_DELETE_BOX_TITLE "Reikšmės šalinimo patvirtinimas" - IDS_DELETE_BOX_TEXT "Ar tikrai norite pašalinti reikšmę „%s“?" + IDS_DELETE_BOX_TEXT "Ar tikrai norite pašalinti reikšmę '%s'?" IDS_DELETE_BOX_TEXT_MULTIPLE "Ar tikrai norite pašalinti šias reikšmes?" IDS_NEWKEY "Naujas raktas #%d" IDS_NEWVALUE "Nauja reikšmė #%d" - IDS_NOTFOUND "Ieškoma eilutė „%s“ nerasta" + IDS_NOTFOUND "Ieškoma eilutė '%s' nerasta" END STRINGTABLE DISCARDABLE @@ -313,7 +311,7 @@ END STRINGTABLE DISCARDABLE BEGIN IDS_REGISTRY_ROOT_NAME "Kompiuteris" - IDS_REGISTRY_DEFAULT_VALUE "(numatytoji)" + IDS_REGISTRY_DEFAULT_VALUE "(Numatytoji)" IDS_REGISTRY_VALUE_NOT_SET "(reikšmė nenustatyta)" IDS_REGISTRY_VALUE_CANT_DISPLAY "(negalima parodyti reikšmės)" IDS_REGISTRY_UNKNOWN_TYPE "(nežinomas %d)" @@ -329,3 +327,5 @@ END BEGIN "resource.h\0" END + +#pragma code_page(default) diff --git a/programs/regedit/Makefile.in b/programs/regedit/Makefile.in index b0fba494465..9f872dca66d 100644 --- a/programs/regedit/Makefile.in +++ b/programs/regedit/Makefile.in @@ -22,29 +22,7 @@ C_SRCS = \ regproc.c \ treeview.c -RC_SRCS = \ - Bg.rc \ - Cs.rc \ - Da.rc \ - De.rc \ - En.rc \ - Es.rc \ - Fr.rc \ - Hu.rc \ - It.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc \ - rsrc.rc +RC_SRCS = rsrc.rc SVG_SRCS = regedit.svg diff --git a/programs/regedit/Nl.rc b/programs/regedit/Nl.rc index f02ab650c08..43154ed4995 100644 --- a/programs/regedit/Nl.rc +++ b/programs/regedit/Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL diff --git a/programs/regedit/No.rc b/programs/regedit/No.rc index 055252fc127..66611785be0 100644 --- a/programs/regedit/No.rc +++ b/programs/regedit/No.rc @@ -1,7 +1,7 @@ /* - * Regedit Norwegian Bokmål resources + * Regedit Norwegian Bokmål resources * - * Copyright 2005-2009 Alexander N. Sørnes + * Copyright 2005-2008 Alexander N. Sørnes * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL /* @@ -48,10 +44,10 @@ BEGIN MENUITEM SEPARATOR POPUP "&Ny" BEGIN - MENUITEM "Nø&kkel", ID_EDIT_NEW_KEY + MENUITEM "Nø&kkel", ID_EDIT_NEW_KEY MENUITEM SEPARATOR MENUITEM "&Strengverdi", ID_EDIT_NEW_STRINGVALUE - MENUITEM "&Binærverdi", ID_EDIT_NEW_BINARYVALUE + MENUITEM "&Binærverdi", ID_EDIT_NEW_BINARYVALUE MENUITEM "&DWORD-verdi", ID_EDIT_NEW_DWORDVALUE MENUITEM "&Flerstrengverdi", ID_EDIT_NEW_MULTI_STRINGVALUE END @@ -59,7 +55,7 @@ BEGIN MENUITEM "&Slett\tDel", ID_EDIT_DELETE MENUITEM "&Gi nytt navn\tF2", ID_EDIT_RENAME MENUITEM SEPARATOR - MENUITEM "&Kopier nøkkelnavn", ID_EDIT_COPYKEYNAME + MENUITEM "&Kopier nøkkelnavn", ID_EDIT_COPYKEYNAME MENUITEM SEPARATOR MENUITEM "&Finn\tCtrl+F", ID_EDIT_FIND, GRAYED MENUITEM "Finn &neste\tF3", ID_EDIT_FINDNEXT, GRAYED @@ -90,7 +86,7 @@ BEGIN POPUP "" BEGIN MENUITEM "&Endre", ID_EDIT_MODIFY - MENUITEM "Endre binærdata", ID_EDIT_MODIFY_BIN + MENUITEM "Endre binærdata", ID_EDIT_MODIFY_BIN MENUITEM SEPARATOR MENUITEM "&Slett\tDel", ID_EDIT_DELETE MENUITEM "&Gi nytt navn", ID_EDIT_RENAME @@ -99,10 +95,10 @@ BEGIN BEGIN POPUP "&Ny" BEGIN - MENUITEM "Nø&kkel", ID_EDIT_NEW_KEY + MENUITEM "Nø&kkel", ID_EDIT_NEW_KEY MENUITEM SEPARATOR MENUITEM "&Strengverdi", ID_EDIT_NEW_STRINGVALUE - MENUITEM "&Binærverdi", ID_EDIT_NEW_BINARYVALUE + MENUITEM "&Binærverdi", ID_EDIT_NEW_BINARYVALUE MENUITEM "&DWORD-verdi", ID_EDIT_NEW_DWORDVALUE MENUITEM "&Flerstrengverdi", ID_EDIT_NEW_MULTI_STRINGVALUE END @@ -111,7 +107,7 @@ BEGIN MENUITEM "&Gi nytt navn\tF2", ID_EDIT_RENAME MENUITEM SEPARATOR MENUITEM "&Eksporter...", ID_EDIT_EXPORT - MENUITEM "&Kopier nøkkelnavn", ID_EDIT_COPYKEYNAME + MENUITEM "&Kopier nøkkelnavn", ID_EDIT_COPYKEYNAME MENUITEM SEPARATOR MENUITEM "&Finn\tCtrl+F", ID_EDIT_FIND, GRAYED END @@ -141,7 +137,7 @@ BEGIN LTEXT "Finn:",IDC_STATIC,5,7,119,8 EDITTEXT IDC_VALUE_NAME,40,5,125,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL LTEXT "Finn i:",IDC_STATIC,5, 22, 119, 8 -CHECKBOX "Nøkler", IDC_FIND_KEYS, 5, 34, 90, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX +CHECKBOX "Nøkler", IDC_FIND_KEYS, 5, 34, 90, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX CHECKBOX "Verdinavn", IDC_FIND_VALUES, 5, 46, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX CHECKBOX "Verdiinnhold", IDC_FIND_CONTENT, 5, 58, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX CHECKBOX "Kun hele strenger", IDC_FIND_WHOLE, 5, 70, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX @@ -202,7 +198,7 @@ END IDD_EDIT_BINARY DIALOG DISCARDABLE 22, 17, 170, 100 STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "Rediger binær" +CAPTION "Rediger binær" FONT 8, "MS Shell Dlg" BEGIN LTEXT "Verdinavn:",IDC_STATIC,5,5,119,8 @@ -244,29 +240,29 @@ END STRINGTABLE DISCARDABLE BEGIN - ID_REGISTRY_MENU "Inneholder kommandoer for å arbeide med hele registeret" - ID_EDIT_MENU "Inneholder kommandoer for å redigere verdier og nøkler" - ID_VIEW_MENU "Inneholder kommanoder for å tilpasse registervinduet" - ID_FAVORITES_MENU "Inneholder kommandoer for å få tilgang til nøkler som brukes ofte" - ID_HELP_MENU "Inneholder kommandoer for å vise hjelp og informasjon om Registerredigering" - ID_EDIT_NEW_MENU "Inneholder kommandoer for å opprette nye nøkler eller verdier" + ID_REGISTRY_MENU "Inneholder kommandoer for å arbeide med hele registeret" + ID_EDIT_MENU "Inneholder kommandoer for å redigere verdier og nøkler" + ID_VIEW_MENU "Inneholder kommanoder for å tilpasse registervinduet" + ID_FAVORITES_MENU "Inneholder kommandoer for å få tilgang til nøkler som brukes ofte" + ID_HELP_MENU "Inneholder kommandoer for å vise hjelp og informasjon om Registerredigering" + ID_EDIT_NEW_MENU "Inneholder kommandoer for å opprette nye nøkler eller verdier" END STRINGTABLE DISCARDABLE BEGIN ID_EDIT_MODIFY "Endrer verdiens data" - ID_EDIT_NEW_KEY "Legger til en ny nøkkel" + ID_EDIT_NEW_KEY "Legger til en ny nøkkel" ID_EDIT_NEW_STRINGVALUE "Legger til en ny strengverdi" - ID_EDIT_NEW_BINARYVALUE "Legger til en ny binærverdis" + ID_EDIT_NEW_BINARYVALUE "Legger til en ny binærverdis" ID_EDIT_NEW_DWORDVALUE "Legger til en ny dobbeltord-verdi" ID_EDIT_NEW_MULTI_STRINGVALUE "Legger til en ny flerstrengverdi" ID_REGISTRY_IMPORTREGISTRYFILE "Importerer en tekstfil inn i registeret" ID_REGISTRY_EXPORTREGISTRYFILE "Eksporterer hele eller deler av registeret til en tekstfil" ID_REGISTRY_CONNECTNETWORKREGISTRY - "Kobler til registeret på en annen maskin" + "Kobler til registeret på en annen maskin" ID_REGISTRY_DISCONNECTNETWORKREGISTRY - "Kobler fra registeret på en annen maskin" + "Kobler fra registeret på en annen maskin" ID_REGISTRY_PRINT "Skriver ut hele eller deler av registeret" /* ID_HELP_HELPTOPICS "Viser hjelp til Registerredigering" */ ID_HELP_ABOUT "Viser programinformasjon, versjonnummer og kopirett" @@ -275,32 +271,31 @@ END STRINGTABLE DISCARDABLE BEGIN ID_REGISTRY_EXIT "Avslutter Registerredigering" - ID_FAVORITES_ADDTOFAVORITES "Legger nøkler til i favorittlisten" - ID_FAVORITES_REMOVEFAVORITE "Fjerner nøkler fra favorittlisten" + ID_FAVORITES_ADDTOFAVORITES "Legger nøkler til i favorittlisten" + ID_FAVORITES_REMOVEFAVORITE "Fjerner nøkler fra favorittlisten" ID_VIEW_STATUSBAR "Viser eller skjuler statuslinjens" ID_VIEW_SPLIT "Endrer posisjonen til delingslinjen mellom to ruter" ID_VIEW_REFRESH "Oppdaterer vinduet" ID_EDIT_DELETE "Sletter utvalget" ID_EDIT_RENAME "Gir nytt navn til utvalget" - ID_EDIT_COPYKEYNAME "Kopierer navnet til den valgte nøkkelen til utklippstavlen" - ID_EDIT_FIND "Finner en tekststreng i en nøkkel, verdi eller data" - ID_EDIT_FINDNEXT "Finner neste treff til teksten spesifisert i forrige søk" - ID_EDIT_EXPORT "Eksporterer den valgte greinen av registeret til en tekstfil" + ID_EDIT_COPYKEYNAME "Kopierer navnet til den valgte nøkkelen til utklippstavlen" + ID_EDIT_FIND "Finner en tekststreng i en nøkkel, verdi eller data" + ID_EDIT_FINDNEXT "Finner neste treff til teksten spesifisert i forrige søk" END STRINGTABLE DISCARDABLE BEGIN IDS_ERROR "Feil" - IDS_BAD_KEY "Klarte ikke lese nøkkelen «%s»" - IDS_BAD_VALUE "Klarte ikke lese verdien «%s»" - IDS_UNSUPPORTED_TYPE "Kan ikke redigere nøkler av typen «%u»" + IDS_BAD_KEY "Klarte ikke lese nøkkelen «%s»" + IDS_BAD_VALUE "Klarte ikke lese verdien «%s»" + IDS_UNSUPPORTED_TYPE "Kan ikke redigere nøkler av typen «%u»" IDS_TOO_BIG_VALUE "Verdien er for stor (%u)" IDS_DELETE_BOX_TITLE "Bekreft sletting av verdi" - IDS_DELETE_BOX_TEXT "Virkelig slette verdien «%s»?" + IDS_DELETE_BOX_TEXT "Virkelig slette verdien «%s»?" IDS_DELETE_BOX_TEXT_MULTIPLE "Virkelig slette disse verdiene?" - IDS_NEWKEY "Ny nøkkel #%d" + IDS_NEWKEY "Ny nøkkel #%d" IDS_NEWVALUE "Ny verdi #%d" - IDS_NOTFOUND "Fant ikke søkestrengen «%s»" + IDS_NOTFOUND "Fant ikke søkestrengen «%s»" END STRINGTABLE DISCARDABLE diff --git a/programs/regedit/Pl.rc b/programs/regedit/Pl.rc index a4144384741..a77660c0b33 100644 --- a/programs/regedit/Pl.rc +++ b/programs/regedit/Pl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT /* diff --git a/programs/regedit/Pt.rc b/programs/regedit/Pt.rc index 3c1607e3a29..5dd2438ab6d 100644 --- a/programs/regedit/Pt.rc +++ b/programs/regedit/Pt.rc @@ -2,8 +2,7 @@ * Regedit resources * * Copyright 2003 Marcelo Duarte - * Copyright 2004 Américo José Melo - * Copyright 2009 Ricardo Filipe + * 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 @@ -20,10 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - /* * Menu */ @@ -53,9 +48,9 @@ BEGIN MENUITEM "&Chave", ID_EDIT_NEW_KEY MENUITEM SEPARATOR MENUITEM "Valor &Texto", ID_EDIT_NEW_STRINGVALUE - MENUITEM "Valor &Binário", ID_EDIT_NEW_BINARYVALUE + MENUITEM "Valor &Binário", ID_EDIT_NEW_BINARYVALUE MENUITEM "Valor &DWORD", ID_EDIT_NEW_DWORDVALUE - MENUITEM "Valor de palavras &múltiplas", ID_EDIT_NEW_MULTI_STRINGVALUE + MENUITEM "Valor de palavras &múltiplas", ID_EDIT_NEW_MULTI_STRINGVALUE END MENUITEM SEPARATOR MENUITEM "&Excluir\tDel", ID_EDIT_DELETE @@ -64,7 +59,7 @@ BEGIN MENUITEM "&Copiar nome da chave", ID_EDIT_COPYKEYNAME MENUITEM SEPARATOR MENUITEM "&Localizar\tCtrl+F", ID_EDIT_FIND, GRAYED - MENUITEM "L&ocalizar próxima\tF3", ID_EDIT_FINDNEXT, GRAYED + MENUITEM "L&ocalizar próxima\tF3", ID_EDIT_FINDNEXT, GRAYED END POPUP "E&xibir" BEGIN @@ -112,9 +107,9 @@ BEGIN MENUITEM "&Chave", ID_EDIT_NEW_KEY MENUITEM SEPARATOR MENUITEM "Valor &Texto", ID_EDIT_NEW_STRINGVALUE - MENUITEM "Valor &Binário", ID_EDIT_NEW_BINARYVALUE + MENUITEM "Valor &Binário", ID_EDIT_NEW_BINARYVALUE MENUITEM "Valor &DWORD", ID_EDIT_NEW_DWORDVALUE - MENUITEM "Valor de palavras &múltiplas", ID_EDIT_NEW_MULTI_STRINGVALUE + MENUITEM "Valor de palavras &múltiplas", ID_EDIT_NEW_MULTI_STRINGVALUE END MENUITEM SEPARATOR MENUITEM "&Excluir\tDel", ID_EDIT_DELETE @@ -123,7 +118,7 @@ BEGIN MENUITEM "&Copiar nome da chave", ID_EDIT_COPYKEYNAME MENUITEM SEPARATOR MENUITEM "&Localizar\tCtrl+F", ID_EDIT_FIND, GRAYED - MENUITEM "L&ocalizar próxima\tF3", ID_EDIT_FINDNEXT, GRAYED + MENUITEM "L&ocalizar próxima\tF3", ID_EDIT_FINDNEXT, GRAYED END POPUP "E&xibir" BEGIN @@ -154,7 +149,7 @@ BEGIN POPUP "" BEGIN MENUITEM "&Modificar", ID_EDIT_MODIFY - MENUITEM "Modificar dados binários", ID_EDIT_MODIFY_BIN + MENUITEM "Modificar dados binários", ID_EDIT_MODIFY_BIN MENUITEM SEPARATOR MENUITEM "&Excluir\tDel", ID_EDIT_DELETE MENUITEM "&Renomear", ID_EDIT_RENAME @@ -166,9 +161,9 @@ BEGIN MENUITEM "&Chave", ID_EDIT_NEW_KEY MENUITEM SEPARATOR MENUITEM "Valor &Texto", ID_EDIT_NEW_STRINGVALUE - MENUITEM "Valor &Binário", ID_EDIT_NEW_BINARYVALUE + MENUITEM "Valor &Binário", ID_EDIT_NEW_BINARYVALUE MENUITEM "Valor &DWORD", ID_EDIT_NEW_DWORDVALUE - MENUITEM "Valor de palavras &múltiplas", ID_EDIT_NEW_MULTI_STRINGVALUE + MENUITEM "Valor de palavras &múltiplas", ID_EDIT_NEW_MULTI_STRINGVALUE END MENUITEM SEPARATOR MENUITEM "&Excluir\tDel", ID_EDIT_DELETE @@ -188,55 +183,6 @@ END LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL -IDD_EXPORT_TEMPLATE DIALOG DISCARDABLE 50, 50, 278, 54 -STYLE DS_3DLOOK | DS_CONTROL | WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | - WS_BORDER -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "Exportar registo", IDC_EXPORT_BASE, 6, 6, 266, 42, WS_GROUP - AUTORADIOBUTTON "&Todos", IDC_EXPORT_ALL, 12, 15, 244, 12 - AUTORADIOBUTTON "&Ramo seleccionado:", IDC_EXPORT_SELECTED, 12, 30, 70, 12 - EDITTEXT IDC_EXPORT_PATH, 82, 30, 184, 12 -END - -IDD_FIND DIALOG DISCARDABLE 22, 17, 220, 85 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Procurar" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Procurar:",IDC_STATIC,5,7,119,8 - EDITTEXT IDC_VALUE_NAME,40,5,125,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL - LTEXT "Procurar em:",IDC_STATIC,5, 22, 119, 8 - CHECKBOX "Chaves", IDC_FIND_KEYS, 5, 34, 90, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX - CHECKBOX "Nomes de valor", IDC_FIND_VALUES, 5, 46, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX - CHECKBOX "Conteúdos de valor", IDC_FIND_CONTENT, 5, 58, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX - CHECKBOX "Apenas toda a frase", IDC_FIND_WHOLE, 5, 70, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX - DEFPUSHBUTTON "Procurar",IDOK,175,5,40,15,WS_GROUP - PUSHBUTTON "Fechar",IDCANCEL,175,24,40,15, WS_GROUP -END - -IDD_ADDFAVORITE DIALOG DISCARDABLE 22, 17, 210, 55 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Adicionar Favorito" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Nome:",IDC_STATIC,5,5,119,8 - EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL - DEFPUSHBUTTON "OK",IDOK,120,36,40,15,WS_GROUP - PUSHBUTTON "Cancelar",IDCANCEL,165,36,40,15,WS_GROUP -END - -IDD_DELFAVORITE DIALOG DISCARDABLE 22, 17, 210, 90 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Remover Favorito" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Nome:",IDC_STATIC,5,5,119,8 - LISTBOX IDC_NAME_LIST,5,15,200,52, WS_BORDER | WS_TABSTOP | LBS_SORT | LBS_NOINTEGRALHEIGHT | WS_VSCROLL - DEFPUSHBUTTON "OK",IDOK,120,72,40,15,WS_GROUP - PUSHBUTTON "Cancelar",IDCANCEL,165,72,40,15,WS_GROUP -END - IDD_EDIT_STRING DIALOG DISCARDABLE 22, 17, 210, 75 STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU CAPTION "Editar texto" @@ -250,6 +196,9 @@ BEGIN PUSHBUTTON "Cancelar",IDCANCEL,175,60,30,11,WS_GROUP END + +LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL + IDD_EDIT_DWORD DIALOG DISCARDABLE 22, 17, 210, 100 STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU CAPTION "Editar DWORD" @@ -266,36 +215,13 @@ BEGIN PUSHBUTTON "Cancelar",IDCANCEL,175,80,30,11,WS_GROUP END -IDD_EDIT_BINARY DIALOG DISCARDABLE 22, 17, 170, 100 -STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "Editar Binário" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Nome do valor:",IDC_STATIC,5,5,119,8 - EDITTEXT IDC_VALUE_NAME,5,15,160,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL| WS_DISABLED - LTEXT "Dados do valor:",IDC_STATIC,5,30,90,8 - CONTROL "",IDC_VALUE_DATA,"HexEdit",WS_TABSTOP,5,40,160,40 - DEFPUSHBUTTON "OK",IDOK,80,83,40,15,WS_GROUP - PUSHBUTTON "Cancelar",IDCANCEL,125,83,40,15,WS_GROUP -END - -IDD_EDIT_MULTI_STRING DIALOG DISCARDABLE 22, 17, 210, 175 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Editar Multi-frase" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Nome do valor:",IDC_STATIC,5,5,119,8 - EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL| WS_DISABLED - LTEXT "Dados do valor:",IDC_STATIC,5,30,119,8 - EDITTEXT IDC_VALUE_DATA,5,40,200,112, WS_BORDER | WS_TABSTOP | WS_HSCROLL | WS_VSCROLL | ES_MULTILINE | ES_WANTRETURN - DEFPUSHBUTTON "OK",IDOK,120,156,40,15,WS_GROUP - PUSHBUTTON "Cancelar",IDCANCEL,165,156,40,15,WS_GROUP -END /* * String Table */ +LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL + STRINGTABLE DISCARDABLE BEGIN IDS_LIST_COLUMN_NAME "Nome" @@ -323,24 +249,24 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE DISCARDABLE BEGIN - ID_REGISTRY_MENU "Contém comandos para trabalhar com o Registro inteiro." - ID_EDIT_MENU "Contém comandos para edição de valores ou chaves." - ID_VIEW_MENU "Contém comandos para personalização da janela do Registro." - ID_FAVORITES_MENU "Contém comandos para acessar chaves frequentemente usadas." - ID_HELP_MENU "Contém comandos para exibição da ajuda e informações sobre o Editor do Registro." - ID_EDIT_NEW_MENU "Contém comandos para criação de novas chaves ou valores" + ID_REGISTRY_MENU "Contém comandos para trabalhar com o Registro inteiro." + ID_EDIT_MENU "Contém comandos para edição de valores ou chaves." + ID_VIEW_MENU "Contém comandos para personalização da janela do Registro." + ID_FAVORITES_MENU "Contém comandos para acessar chaves frequentemente usadas." + ID_HELP_MENU "Contém comandos para exibição da ajuda e informações sobre o Editor do Registro." + ID_EDIT_NEW_MENU "Contém comandos para criação de novas chaves ou valores" END LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE DISCARDABLE BEGIN - ID_REGISTRY_MENU "Contém comandos para trabalhar com o Registo inteiro." - ID_EDIT_MENU "Contém comandos para edição de valores ou chaves." - ID_VIEW_MENU "Contém comandos para personalização da janela do Registo." - ID_FAVORITES_MENU "Contém comandos para aceder a chaves frequentemente usadas." - ID_HELP_MENU "Contém comandos para exibição da ajuda e informações sobre o Editor do Registo." - ID_EDIT_NEW_MENU "Contém comandos para criação de novas chaves ou valores" + ID_REGISTRY_MENU "Contém comandos para trabalhar com o Registo inteiro." + ID_EDIT_MENU "Contém comandos para edição de valores ou chaves." + ID_VIEW_MENU "Contém comandos para personalização da janela do Registo." + ID_FAVORITES_MENU "Contém comandos para aceder a chaves frequentemente usadas." + ID_HELP_MENU "Contém comandos para exibição da ajuda e informações sobre o Editor do Registo." + ID_EDIT_NEW_MENU "Contém comandos para criação de novas chaves ou valores" END @@ -351,7 +277,7 @@ BEGIN ID_EDIT_MODIFY "Modifica os dados do valor." ID_EDIT_NEW_KEY "Adiciona uma nova chave" ID_EDIT_NEW_STRINGVALUE "Adiciona um novo valor texto." - ID_EDIT_NEW_BINARYVALUE "Adiciona um novo valor binário." + ID_EDIT_NEW_BINARYVALUE "Adiciona um novo valor binário." ID_EDIT_NEW_DWORDVALUE "Adiciona um novo valor DWORD." ID_REGISTRY_IMPORTREGISTRYFILE "Importa um arquivo texto para o registro." ID_REGISTRY_EXPORTREGISTRYFILE @@ -362,7 +288,7 @@ BEGIN "Desconecta de um registro um computador remoto." ID_REGISTRY_PRINT "Imprime todo ou parte do registro." /* ID_HELP_HELPTOPICS "Abre a ajuda do Editor do Registro." */ - ID_HELP_ABOUT "Exibe informações do programa, número da versão e copyright." + ID_HELP_ABOUT "Exibe informações do programa, número da versão e copyright." END LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE @@ -372,7 +298,7 @@ BEGIN ID_EDIT_MODIFY "Modifica os dados do valor." ID_EDIT_NEW_KEY "Adiciona uma nova chave" ID_EDIT_NEW_STRINGVALUE "Adiciona um novo valor texto." - ID_EDIT_NEW_BINARYVALUE "Adiciona um novo valor binário." + ID_EDIT_NEW_BINARYVALUE "Adiciona um novo valor binário." ID_EDIT_NEW_DWORDVALUE "Adiciona um novo valor DWORD." ID_REGISTRY_IMPORTREGISTRYFILE "Importa um ficheiro de texto para o registo." ID_REGISTRY_EXPORTREGISTRYFILE @@ -383,7 +309,7 @@ BEGIN "Desconecta de um registo um computador remoto." ID_REGISTRY_PRINT "Imprime todo ou parte do registo." /* ID_HELP_HELPTOPICS "Abre a ajuda do Editor de Registo." */ - ID_HELP_ABOUT "Exibe informações do programa, número da versão e direitos de autor." + ID_HELP_ABOUT "Exibe informações do programa, número da versão e direitos de autor." END @@ -395,13 +321,13 @@ BEGIN ID_FAVORITES_ADDTOFAVORITES "Adiciona chaves a lista de favoritos." ID_FAVORITES_REMOVEFAVORITE "Remove chaves da lista de favoritos." ID_VIEW_STATUSBAR "Mostra ou oculta a barra de status." - ID_VIEW_SPLIT "Altera a posição da divisão entre os painéis." + ID_VIEW_SPLIT "Altera a posição da divisão entre os painéis." ID_VIEW_REFRESH "Atualiza a janela." - ID_EDIT_DELETE "Exclui a selecão." - ID_EDIT_RENAME "Renomeia a selecão." - ID_EDIT_COPYKEYNAME "Copia o nome da chave selecionada para a Área de transferência." + ID_EDIT_DELETE "Exclui a selecão." + ID_EDIT_RENAME "Renomeia a selecão." + ID_EDIT_COPYKEYNAME "Copia o nome da chave selecionada para a Área de transferência." ID_EDIT_FIND "Localiza um texto em uma chave, valor ou dado." - ID_EDIT_FINDNEXT "Localiza a próxima ocorrência do texto especificado na pesquisa anterior." + ID_EDIT_FINDNEXT "Localiza a próxima ocorrência do texto especificado na pesquisa anterior." END LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE @@ -409,16 +335,16 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE DISCARDABLE BEGIN ID_REGISTRY_EXIT "Encerra o Editor de Registo." - ID_FAVORITES_ADDTOFAVORITES "Adiciona chaves à lista de favoritos." + ID_FAVORITES_ADDTOFAVORITES "Adiciona chaves à lista de favoritos." ID_FAVORITES_REMOVEFAVORITE "Remove chaves da lista de favoritos." ID_VIEW_STATUSBAR "Mostra ou oculta a barra de status." - ID_VIEW_SPLIT "Altera a posição da divisão entre os painéis." + ID_VIEW_SPLIT "Altera a posição da divisão entre os painéis." ID_VIEW_REFRESH "Actualiza a janela." - ID_EDIT_DELETE "Exclui a selecção." - ID_EDIT_RENAME "Renomeia a selecção." - ID_EDIT_COPYKEYNAME "Copia o nome da chave seleccionada para a Área de transferência." + ID_EDIT_DELETE "Exclui a selecção." + ID_EDIT_RENAME "Renomeia a selecção." + ID_EDIT_COPYKEYNAME "Copia o nome da chave seleccionada para a Área de transferência." ID_EDIT_FIND "Localiza um texto numa chave, valor ou dado." - ID_EDIT_FINDNEXT "Localiza a próxima ocorrência do texto indicado na pesquisa anterior." + ID_EDIT_FINDNEXT "Localiza a próxima ocorrência do texto indicado na pesquisa anterior." END @@ -427,16 +353,16 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE DISCARDABLE BEGIN IDS_ERROR "Erro" - IDS_BAD_KEY "Não pode consultar a chave '%s'" - IDS_BAD_VALUE "Não pode consultar o valor '%s'" - IDS_UNSUPPORTED_TYPE "Não pode editar chaves deste tipo (%u)" - IDS_TOO_BIG_VALUE "Valor é muito grande (%u)" - IDS_DELETE_BOX_TITLE "Confirmar exclusão de valor" + IDS_BAD_KEY "Não pode consultar a chave '%s'" + IDS_BAD_VALUE "Não pode consultar o valor '%s'" + IDS_UNSUPPORTED_TYPE "Não pode editar chaves deste tipo (%u)" + IDS_TOO_BIG_VALUE "Valor é muito grande (%u)" + IDS_DELETE_BOX_TITLE "Confirmar exclusão de valor" IDS_DELETE_BOX_TEXT "Tem certeza que deseja excluir o valor '%s'?" IDS_DELETE_BOX_TEXT_MULTIPLE "Are you sure you want to delete these values?" IDS_NEWKEY "Nova chave #%d" IDS_NEWVALUE "Novo valor #%d" - IDS_NOTFOUND "Chave de busca '%s' não encontrada" + IDS_NOTFOUND "Chave de busca '%s' não encontrada" END LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE @@ -444,32 +370,16 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE DISCARDABLE BEGIN IDS_ERROR "Erro" - IDS_BAD_KEY "Não pode perguntar a chave '%s'" - IDS_BAD_VALUE "Não pode perguntar o valor '%s'" - IDS_UNSUPPORTED_TYPE "Não pode editar chaves deste tipo (%u)" + IDS_BAD_KEY "Não pode perguntar a chave '%s'" + IDS_BAD_VALUE "Não pode perguntar o valor '%s'" + IDS_UNSUPPORTED_TYPE "Não pode editar chaves deste tipo (%u)" IDS_TOO_BIG_VALUE "Valor muito grande (%u)" - IDS_DELETE_BOX_TITLE "Confirmar exclusão de valor" + IDS_DELETE_BOX_TITLE "Confirmar exclusão de valor" IDS_DELETE_BOX_TEXT "Tem certeza que deseja excluir o valor '%s'?" - IDS_DELETE_BOX_TEXT_MULTIPLE "Tem a certeza que deseja excluir estes valores?" + IDS_DELETE_BOX_TEXT_MULTIPLE "Are you sure you want to delete these values?" IDS_NEWKEY "Nova chave #%d" IDS_NEWVALUE "Novo valor #%d" - IDS_NOTFOUND "Chave de pesquisa '%s' não encontrada" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_FILEDIALOG_IMPORT_TITLE "Importar Ficheiro de Registo" - IDS_FILEDIALOG_EXPORT_TITLE "Exportar Ficheiro de Registo" - IDS_FILEDIALOG_FILTER "Ficheiros de Registo\0*.reg\0Ficheiros de Registo Win9x/NT4 (REGEDIT4)\0*.reg\0Todos os Ficheiros (*.*)\0*.*\0\0" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_REGISTRY_ROOT_NAME "Meu Computador" - IDS_REGISTRY_DEFAULT_VALUE "(Omissão)" - IDS_REGISTRY_VALUE_NOT_SET "(valor não dado)" - IDS_REGISTRY_VALUE_CANT_DISPLAY "(não pode mostrar o valor)" - IDS_REGISTRY_UNKNOWN_TYPE "(desconhecido %d)" + IDS_NOTFOUND "Chave de busca '%s' não encontrada" END /*****************************************************************/ diff --git a/programs/regedit/Ru.rc b/programs/regedit/Ru.rc dissimilarity index 69% index 2692c991c1a..a80a62a0873 100644 --- a/programs/regedit/Ru.rc +++ b/programs/regedit/Ru.rc @@ -1,333 +1,328 @@ -/* - * Regedit (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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT - -/* - * Menu - */ - -IDR_REGEDIT_MENU MENU DISCARDABLE -BEGIN - POPUP "&Реестр" - BEGIN - MENUITEM "&Импортировать файл реестра...", ID_REGISTRY_IMPORTREGISTRYFILE - MENUITEM "&Экспортировать файл реестра...", ID_REGISTRY_EXPORTREGISTRYFILE - MENUITEM SEPARATOR - MENUITEM "&Подключить сетевой реестр...", ID_REGISTRY_CONNECTNETWORKREGISTRY, GRAYED - MENUITEM "&Отключить сетевой реестр...", ID_REGISTRY_DISCONNECTNETWORKREGISTRY, GRAYED - MENUITEM SEPARATOR - MENUITEM "&Напечатать\tCtrl+P", ID_REGISTRY_PRINT, GRAYED - MENUITEM SEPARATOR - MENUITEM "В&ыйти", ID_REGISTRY_EXIT - END - POPUP "&Правка" - BEGIN - MENUITEM "&Изменить", ID_EDIT_MODIFY - MENUITEM SEPARATOR - POPUP "Созд&ать" - BEGIN - MENUITEM "Кл&юч", ID_EDIT_NEW_KEY - MENUITEM SEPARATOR - MENUITEM "&Строковое значение", ID_EDIT_NEW_STRINGVALUE - MENUITEM "&Бинарное значение", ID_EDIT_NEW_BINARYVALUE - MENUITEM "&DWORD значение", ID_EDIT_NEW_DWORDVALUE - MENUITEM "&Многостроковое значение", ID_EDIT_NEW_MULTI_STRINGVALUE - END - MENUITEM SEPARATOR - MENUITEM "&Удалить\tDel", ID_EDIT_DELETE - MENUITEM "&Переименовать\tF2", ID_EDIT_RENAME - MENUITEM SEPARATOR - MENUITEM "С&копировать имя ключа", ID_EDIT_COPYKEYNAME - MENUITEM SEPARATOR - MENUITEM "&Найти\tCtrl+F", ID_EDIT_FIND, GRAYED - MENUITEM "Найти &далее\tF3", ID_EDIT_FINDNEXT, GRAYED - END - POPUP "&Вид" - BEGIN - MENUITEM "Строка &состояния", ID_VIEW_STATUSBAR - MENUITEM SEPARATOR - MENUITEM "&Разделить", ID_VIEW_SPLIT - MENUITEM SEPARATOR - MENUITEM "&Обновить\tF5", ID_VIEW_REFRESH - END - POPUP "&Избранное" - BEGIN - MENUITEM "&Добавить в избранное...", ID_FAVORITES_ADDTOFAVORITES - MENUITEM "&Удалить из избранного...", ID_FAVORITES_REMOVEFAVORITE - END - POPUP "&Справка" - BEGIN - MENUITEM "&Содержание", ID_HELP_HELPTOPICS - MENUITEM SEPARATOR - MENUITEM "&О редакторе реестра", ID_HELP_ABOUT - END -END - -IDR_POPUP_MENUS MENU DISCARDABLE -BEGIN - POPUP "" - BEGIN - MENUITEM "&Изменить", ID_EDIT_MODIFY - MENUITEM "Изменить &бинарное значение", ID_EDIT_MODIFY_BIN - MENUITEM SEPARATOR - MENUITEM "&Удалить\tDel", ID_EDIT_DELETE - MENUITEM "&Переименовать", ID_EDIT_RENAME - END - POPUP "" - BEGIN - POPUP "Созд&ать" - BEGIN - MENUITEM "Кл&юч", ID_EDIT_NEW_KEY - MENUITEM SEPARATOR - MENUITEM "&Строковое значение", ID_EDIT_NEW_STRINGVALUE - MENUITEM "&Бинарное значение", ID_EDIT_NEW_BINARYVALUE - MENUITEM "&DWORD значение", ID_EDIT_NEW_DWORDVALUE - MENUITEM "&Многостроковое значение", ID_EDIT_NEW_MULTI_STRINGVALUE - END - MENUITEM SEPARATOR - MENUITEM "&Удалить\tDel", ID_EDIT_DELETE - MENUITEM "&Переименовать\tF2", ID_EDIT_RENAME - MENUITEM SEPARATOR - MENUITEM "&Экспортировать...", ID_EDIT_EXPORT - MENUITEM "С&копировать имя ключа", ID_EDIT_COPYKEYNAME - MENUITEM SEPARATOR - MENUITEM "&Найти\tCtrl+F", ID_EDIT_FIND, GRAYED - END -END - - -/* - * Dialog - */ - -IDD_EXPORT_TEMPLATE DIALOG DISCARDABLE 50, 50, 278, 54 -STYLE DS_3DLOOK | DS_CONTROL | WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | - WS_BORDER -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "Экспорт реестра", IDC_EXPORT_BASE, 6, 6, 266, 42, WS_GROUP - AUTORADIOBUTTON "&Весь реестр", IDC_EXPORT_ALL, 12, 15, 244, 12 - AUTORADIOBUTTON "В&ыбранную ветку:", IDC_EXPORT_SELECTED, 12, 30, 80, 12 - EDITTEXT IDC_EXPORT_PATH, 92, 30, 174, 12 -END - -IDD_FIND DIALOG DISCARDABLE 22, 17, 210, 85 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Поиск" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Найти:",IDC_STATIC,5,7,119,8 - EDITTEXT IDC_VALUE_NAME,40,5,120,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL - LTEXT "Искать в:",IDC_STATIC,5, 22, 119, 8 - CHECKBOX "Ключах", IDC_FIND_KEYS, 5, 34, 90, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX - CHECKBOX "Названиях значений", IDC_FIND_VALUES, 5, 46, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX - CHECKBOX "Содержимом", IDC_FIND_CONTENT, 5, 58, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX - CHECKBOX "Всю строку целиком", IDC_FIND_WHOLE, 5, 70, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX - DEFPUSHBUTTON "Искать",IDOK,170,5,35,11,WS_GROUP - PUSHBUTTON "Закрыть",IDCANCEL,170,22,35,11, WS_GROUP -END - -IDD_ADDFAVORITE DIALOG DISCARDABLE 22, 17, 210, 55 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Добавить избранное" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Имя:",IDC_STATIC,5,5,119,8 - EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL - DEFPUSHBUTTON "OK",IDOK,130,40,30,11,WS_GROUP - PUSHBUTTON "Отменить",IDCANCEL,165,40,40,11, WS_GROUP -END - -IDD_DELFAVORITE DIALOG DISCARDABLE 22, 17, 210, 90 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Удалить избранное" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Имя:",IDC_STATIC,5,5,119,8 - LISTBOX IDC_NAME_LIST,5,15,200,52, WS_BORDER | WS_TABSTOP | LBS_SORT | LBS_NOINTEGRALHEIGHT | WS_VSCROLL - DEFPUSHBUTTON "OK",IDOK,130,73,30,11,WS_GROUP - PUSHBUTTON "Отменить",IDCANCEL,165,73,40,11, WS_GROUP -END - -IDD_EDIT_STRING DIALOG DISCARDABLE 22, 17, 210, 75 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Изменить строку" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Название значения:",IDC_STATIC,5,5,119,8 - EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL| WS_DISABLED - LTEXT "Данные:",IDC_STATIC,5,30,119,8 - EDITTEXT IDC_VALUE_DATA,5,40,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL - DEFPUSHBUTTON "OK",IDOK,130,60,30,11,WS_GROUP - PUSHBUTTON "Отменить",IDCANCEL,165,60,40,11,WS_GROUP -END - -IDD_EDIT_DWORD DIALOG DISCARDABLE 22, 17, 210, 100 -STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "Изменить DWORD" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Название значения:",IDC_STATIC,5,5,119,8 - EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL| WS_DISABLED - LTEXT "Данные:",IDC_STATIC,5,30,90,8 - EDITTEXT IDC_VALUE_DATA,5,40,90,12, WS_BORDER | WS_TABSTOP - GROUPBOX "Исчисление", IDC_DWORD_BASE, 120, 30, 85, 37, BS_GROUPBOX - AUTORADIOBUTTON "16-ти ричное", IDC_DWORD_HEX, 130, 40, 60, 10, WS_TABSTOP - AUTORADIOBUTTON "Десятичное", IDC_DWORD_DEC, 130, 52, 60, 10, WS_TABSTOP - DEFPUSHBUTTON "OK",IDOK,130,80,30,11,WS_GROUP - PUSHBUTTON "Отменить",IDCANCEL,165,80,40,11,WS_GROUP -END - -IDD_EDIT_BINARY DIALOG DISCARDABLE 22, 17, 210, 100 -STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU -CAPTION "Изменить бинарные данные" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Название значения:",IDC_STATIC,5,5,119,8 - EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL| WS_DISABLED - LTEXT "Данные:",IDC_STATIC,5,30,90,8 - CONTROL "",IDC_VALUE_DATA,"HexEdit",WS_TABSTOP,4,40,160,40 - DEFPUSHBUTTON "OK",IDOK,130,80,30,11,WS_GROUP - PUSHBUTTON "Отменить",IDCANCEL,165,80,40,11,WS_GROUP -END - -IDD_EDIT_MULTI_STRING DIALOG DISCARDABLE 22, 17, 210, 175 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Изменить многостроковые данные" -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT "Название значения:",IDC_STATIC,5,5,119,8 - EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL| WS_DISABLED - LTEXT "Данные:",IDC_STATIC,5,30,119,8 - EDITTEXT IDC_VALUE_DATA,5,40,200,112, WS_BORDER | WS_TABSTOP | WS_HSCROLL | WS_VSCROLL | ES_MULTILINE | ES_WANTRETURN - DEFPUSHBUTTON "OK",IDOK,130,160,30,11,WS_GROUP - PUSHBUTTON "Отменить",IDCANCEL,165,160,40,11,WS_GROUP -END - -/* - * String Table - */ - -STRINGTABLE DISCARDABLE -BEGIN - IDS_LIST_COLUMN_NAME "Имя" - IDS_LIST_COLUMN_TYPE "Тип" - IDS_LIST_COLUMN_DATA "Данные" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_APP_TITLE "Редактор реестра" -END - -STRINGTABLE DISCARDABLE -BEGIN - ID_REGISTRY_MENU "Содержит команды для работы с реестром в целом" - ID_EDIT_MENU "Содержит команды для редактирования значений или ключей" - ID_VIEW_MENU "Содержит команды для настройки окна реестра" - ID_FAVORITES_MENU "Содержит команды для доступа к часто используемым ключам" - ID_HELP_MENU "Содержит команды для отображения справки и информации о редакторе реестра" - ID_EDIT_NEW_MENU "Содержит команды для создания новых ключей или значений" -END - -STRINGTABLE DISCARDABLE -BEGIN - ID_EDIT_MODIFY "Изменяет значение параметра" - ID_EDIT_NEW_KEY "Добавляет новый ключ" - ID_EDIT_NEW_STRINGVALUE "Добавляет новое строковое значение" - ID_EDIT_NEW_BINARYVALUE "Добавляет новое бинарное значение" - ID_EDIT_NEW_DWORDVALUE "Добавляет новое DWORD-значение" - ID_EDIT_NEW_MULTI_STRINGVALUE "Добавляет новое многостроковое значение" - ID_REGISTRY_IMPORTREGISTRYFILE "Импортирует текстовой файл в реестр" - ID_REGISTRY_EXPORTREGISTRYFILE - "Экспортирует весь реестр или его часть в текстовой файл" - ID_REGISTRY_CONNECTNETWORKREGISTRY - "Подключается к реестру удалённого компьютера" - ID_REGISTRY_DISCONNECTNETWORKREGISTRY - "Отключается от реестра удалённого компьютера" - ID_REGISTRY_PRINT "Печатает весь реестр или его часть" -/* ID_HELP_HELPTOPICS "Opens registry editor help" */ - ID_HELP_ABOUT "Отображает информацию о программе, номер версии и список авторов" -END - -STRINGTABLE DISCARDABLE -BEGIN - ID_REGISTRY_EXIT "Выход из редактора реестра" - ID_FAVORITES_ADDTOFAVORITES "Добавить ключ в избранное" - ID_FAVORITES_REMOVEFAVORITE "Удалить ключ из избранного" - ID_VIEW_STATUSBAR "Показать или скрыть строку состояния" - ID_VIEW_SPLIT "Изменить позицию разделителя между двумя панелями" - ID_VIEW_REFRESH "Обновляет окно" - ID_EDIT_DELETE "Удаляет выделение" - ID_EDIT_RENAME "Переименовывает выделение" - ID_EDIT_COPYKEYNAME "Копирует имя выделенного ключа в буфер обмена" - ID_EDIT_FIND "Ищет текстовую строку в ключе, значении или данных" - ID_EDIT_FINDNEXT "Ищет следующее совпадение текста, заданного в предыдущем поиске" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_ERROR "Ошибка" - IDS_BAD_KEY "Невозможно запросить ключ '%s'" - IDS_BAD_VALUE "Невозможно запросить значение '%s'" - IDS_UNSUPPORTED_TYPE "Редактирование ключей типа (%u) не поддерживается" - IDS_TOO_BIG_VALUE "Значение слишком велико (%u)" - IDS_DELETE_BOX_TITLE "Подтверждение" - IDS_DELETE_BOX_TEXT "Удалить значение '%s'?" - IDS_DELETE_BOX_TEXT_MULTIPLE "Вы уверены что хотите удалить эти значения?" - IDS_NEWKEY "Новый ключ #%d" - IDS_NEWVALUE "Новое значени #%d" - IDS_NOTFOUND "Искомая строка '%s' не найдена" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_FILEDIALOG_IMPORT_TITLE "Импорт файла реестра" - IDS_FILEDIALOG_EXPORT_TITLE "Экспорт файла реестра" - IDS_FILEDIALOG_FILTER "Все файлы реестра\0*.reg\0Файлы реестра для Win9x/NT4 (REGEDIT4)\0*.reg\0Все файлы (*.*)\0*.*\0\0" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_REGISTRY_ROOT_NAME "Мой Компьютер" - IDS_REGISTRY_DEFAULT_VALUE "(По умолчанию)" - IDS_REGISTRY_VALUE_NOT_SET "(значение не задано)" - IDS_REGISTRY_VALUE_CANT_DISPLAY "(невозможно отобразить)" - IDS_REGISTRY_UNKNOWN_TYPE "(неизвестно %d)" -END - -/*****************************************************************/ - -/* - * TEXTINCLUDE - */ - -1 TEXTINCLUDE DISCARDABLE -BEGIN - "resource.h\0" -END - -/*****************************************************************/ +/* + * Regedit (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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT + +/* + * Menu + */ + +IDR_REGEDIT_MENU MENU DISCARDABLE +BEGIN + POPUP "&Ðååñòð" + BEGIN + MENUITEM "&Èìïîðòèðîâàòü ôàéë ðååñòðà...", ID_REGISTRY_IMPORTREGISTRYFILE + MENUITEM "&Ýêñïîðòèðîâàòü ôàéë ðååñòðà...", ID_REGISTRY_EXPORTREGISTRYFILE + MENUITEM SEPARATOR + MENUITEM "&Ïîäêëþ÷èòü ñåòåâîé ðååñòð...", ID_REGISTRY_CONNECTNETWORKREGISTRY, GRAYED + MENUITEM "&Îòêëþ÷èòü ñåòåâîé ðååñòð...", ID_REGISTRY_DISCONNECTNETWORKREGISTRY, GRAYED + MENUITEM SEPARATOR + MENUITEM "&Íàïå÷àòàòü\tCtrl+P", ID_REGISTRY_PRINT, GRAYED + MENUITEM SEPARATOR + MENUITEM "Â&ûéòè", ID_REGISTRY_EXIT + END + POPUP "&Ïðàâêà" + BEGIN + MENUITEM "&Èçìåíèòü", ID_EDIT_MODIFY + MENUITEM SEPARATOR + POPUP "Ñîçä&àòü" + BEGIN + MENUITEM "Êë&þ÷", ID_EDIT_NEW_KEY + MENUITEM SEPARATOR + MENUITEM "&Ñòðîêîâîå çíà÷åíèå", ID_EDIT_NEW_STRINGVALUE + MENUITEM "&Áèíàðíîå çíà÷åíèå", ID_EDIT_NEW_BINARYVALUE + MENUITEM "&DWORD çíà÷åíèå", ID_EDIT_NEW_DWORDVALUE + MENUITEM "&Ìíîãîñòðîêîâîå çíà÷åíèå", ID_EDIT_NEW_MULTI_STRINGVALUE + END + MENUITEM SEPARATOR + MENUITEM "&Óäàëèòü\tDel", ID_EDIT_DELETE + MENUITEM "&Ïåðåèìåíîâàòü\tF2", ID_EDIT_RENAME + MENUITEM SEPARATOR + MENUITEM "Ñ&êîïèðîâàòü èìÿ êëþ÷à", ID_EDIT_COPYKEYNAME + MENUITEM SEPARATOR + MENUITEM "&Íàéòè\tCtrl+F", ID_EDIT_FIND, GRAYED + MENUITEM "Íàéòè &äàëåå\tF3", ID_EDIT_FINDNEXT, GRAYED + END + POPUP "&Âèä" + BEGIN + MENUITEM "Ñòðîêà &ñîñòîÿíèÿ", ID_VIEW_STATUSBAR + MENUITEM SEPARATOR + MENUITEM "&Ðàçäåëèòü", ID_VIEW_SPLIT + MENUITEM SEPARATOR + MENUITEM "&Îáíîâèòü\tF5", ID_VIEW_REFRESH + END + POPUP "&Èçáðàííîå" + BEGIN + MENUITEM "&Äîáàâèòü â èçáðàííîå...", ID_FAVORITES_ADDTOFAVORITES + MENUITEM "&Óäàëèòü èç èçáðàííîãî...", ID_FAVORITES_REMOVEFAVORITE + END + POPUP "&Ñïðàâêà" + BEGIN + MENUITEM "&Ñîäåðæàíèå", ID_HELP_HELPTOPICS + MENUITEM SEPARATOR + MENUITEM "&Î ðåäàêòîðå ðååñòðà", ID_HELP_ABOUT + END +END + +IDR_POPUP_MENUS MENU DISCARDABLE +BEGIN + POPUP "" + BEGIN + MENUITEM "&Èçìåíèòü", ID_EDIT_MODIFY + MENUITEM "Èçìåíèòü &áèíàðíîå çíà÷åíèå", ID_EDIT_MODIFY_BIN + MENUITEM SEPARATOR + MENUITEM "&Óäàëèòü\tDel", ID_EDIT_DELETE + MENUITEM "&Ïåðåèìåíîâàòü", ID_EDIT_RENAME + END + POPUP "" + BEGIN + POPUP "Ñîçä&àòü" + BEGIN + MENUITEM "Êë&þ÷", ID_EDIT_NEW_KEY + MENUITEM SEPARATOR + MENUITEM "&Ñòðîêîâîå çíà÷åíèå", ID_EDIT_NEW_STRINGVALUE + MENUITEM "&Áèíàðíîå çíà÷åíèå", ID_EDIT_NEW_BINARYVALUE + MENUITEM "&DWORD çíà÷åíèå", ID_EDIT_NEW_DWORDVALUE + MENUITEM "&Ìíîãîñòðîêîâîå çíà÷åíèå", ID_EDIT_NEW_MULTI_STRINGVALUE + END + MENUITEM SEPARATOR + MENUITEM "&Óäàëèòü\tDel", ID_EDIT_DELETE + MENUITEM "&Ïåðåèìåíîâàòü\tF2", ID_EDIT_RENAME + MENUITEM SEPARATOR + MENUITEM "&Ýêñïîðòèðîâàòü...", ID_EDIT_EXPORT + MENUITEM "Ñ&êîïèðîâàòü èìÿ êëþ÷à", ID_EDIT_COPYKEYNAME + MENUITEM SEPARATOR + MENUITEM "&Íàéòè\tCtrl+F", ID_EDIT_FIND, GRAYED + END +END + + +/* + * Dialog + */ + +IDD_EXPORT_TEMPLATE DIALOG DISCARDABLE 50, 50, 278, 54 +STYLE DS_3DLOOK | DS_CONTROL | WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | + WS_BORDER +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Ýêñïîðò ðååñòðà", IDC_EXPORT_BASE, 6, 6, 266, 42, WS_GROUP + AUTORADIOBUTTON "&Âåñü ðååñòð", IDC_EXPORT_ALL, 12, 15, 244, 12 + AUTORADIOBUTTON "Â&ûáðàííóþ âåòêó:", IDC_EXPORT_SELECTED, 12, 30, 80, 12 + EDITTEXT IDC_EXPORT_PATH, 92, 30, 174, 12 +END + +IDD_FIND DIALOG DISCARDABLE 22, 17, 210, 85 +STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +CAPTION "Ïîèñê" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Íàéòè:",IDC_STATIC,5,7,119,8 + EDITTEXT IDC_VALUE_NAME,40,5,120,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL + LTEXT "Èñêàòü â:",IDC_STATIC,5, 22, 119, 8 + CHECKBOX "Êëþ÷àõ", IDC_FIND_KEYS, 5, 34, 90, 10, WS_TABSTOP | WS_GROUP | BS_AUTOCHECKBOX + CHECKBOX "Íàçâàíèÿõ çíà÷åíèé", IDC_FIND_VALUES, 5, 46, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX + CHECKBOX "Ñîäåðæèìîì", IDC_FIND_CONTENT, 5, 58, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX + CHECKBOX "Âñþ ñòðîêó öåëèêîì", IDC_FIND_WHOLE, 5, 70, 90, 10, WS_TABSTOP | BS_AUTOCHECKBOX + DEFPUSHBUTTON "Èñêàòü",IDOK,170,5,35,11,WS_GROUP + PUSHBUTTON "Çàêðûòü",IDCANCEL,170,22,35,11, WS_GROUP +END + +IDD_ADDFAVORITE DIALOG DISCARDABLE 22, 17, 210, 55 +STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +CAPTION "Äîáàâèòü èçáðàííîå" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Èìÿ:",IDC_STATIC,5,5,119,8 + EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL + DEFPUSHBUTTON "OK",IDOK,130,40,30,11,WS_GROUP + PUSHBUTTON "Îòìåíèòü",IDCANCEL,165,40,40,11, WS_GROUP +END + +IDD_DELFAVORITE DIALOG DISCARDABLE 22, 17, 210, 90 +STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +CAPTION "Óäàëèòü èçáðàííîå" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Èìÿ:",IDC_STATIC,5,5,119,8 + LISTBOX IDC_NAME_LIST,5,15,200,52, WS_BORDER | WS_TABSTOP | LBS_SORT | LBS_NOINTEGRALHEIGHT | WS_VSCROLL + DEFPUSHBUTTON "OK",IDOK,130,73,30,11,WS_GROUP + PUSHBUTTON "Îòìåíèòü",IDCANCEL,165,73,40,11, WS_GROUP +END + +IDD_EDIT_STRING DIALOG DISCARDABLE 22, 17, 210, 75 +STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +CAPTION "Èçìåíèòü ñòðîêó" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Íàçâàíèå çíà÷åíèÿ:",IDC_STATIC,5,5,119,8 + EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL| WS_DISABLED + LTEXT "Äàííûå:",IDC_STATIC,5,30,119,8 + EDITTEXT IDC_VALUE_DATA,5,40,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL + DEFPUSHBUTTON "OK",IDOK,130,60,30,11,WS_GROUP + PUSHBUTTON "Îòìåíèòü",IDCANCEL,165,60,40,11,WS_GROUP +END + +IDD_EDIT_DWORD DIALOG DISCARDABLE 22, 17, 210, 100 +STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU +CAPTION "Èçìåíèòü DWORD" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Íàçâàíèå çíà÷åíèÿ:",IDC_STATIC,5,5,119,8 + EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL| WS_DISABLED + LTEXT "Äàííûå:",IDC_STATIC,5,30,90,8 + EDITTEXT IDC_VALUE_DATA,5,40,90,12, WS_BORDER | WS_TABSTOP + GROUPBOX "Èñ÷èñëåíèå", IDC_DWORD_BASE, 120, 30, 85, 37, BS_GROUPBOX + AUTORADIOBUTTON "16-òè ðè÷íîå", IDC_DWORD_HEX, 130, 40, 60, 10, WS_TABSTOP + AUTORADIOBUTTON "Äåñÿòè÷íîå", IDC_DWORD_DEC, 130, 52, 60, 10, WS_TABSTOP + DEFPUSHBUTTON "OK",IDOK,130,80,30,11,WS_GROUP + PUSHBUTTON "Îòìåíèòü",IDCANCEL,165,80,40,11,WS_GROUP +END + +IDD_EDIT_BINARY DIALOG DISCARDABLE 22, 17, 210, 100 +STYLE DS_MODALFRAME | DS_NOIDLEMSG | WS_CAPTION | WS_SYSMENU +CAPTION "Èçìåíèòü áèíàðíûå äàííûå" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Íàçâàíèå çíà÷åíèÿ:",IDC_STATIC,5,5,119,8 + EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL| WS_DISABLED + LTEXT "Äàííûå:",IDC_STATIC,5,30,90,8 + CONTROL "",IDC_VALUE_DATA,"HexEdit",WS_TABSTOP,4,40,160,40 + DEFPUSHBUTTON "OK",IDOK,130,80,30,11,WS_GROUP + PUSHBUTTON "Îòìåíèòü",IDCANCEL,165,80,40,11,WS_GROUP +END + +IDD_EDIT_MULTI_STRING DIALOG DISCARDABLE 22, 17, 210, 175 +STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +CAPTION "Èçìåíèòü ìíîãîñòðîêîâûå äàííûå" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Íàçâàíèå çíà÷åíèÿ:",IDC_STATIC,5,5,119,8 + EDITTEXT IDC_VALUE_NAME,5,15,200,12, WS_BORDER | WS_TABSTOP | ES_AUTOHSCROLL| WS_DISABLED + LTEXT "Äàííûå:",IDC_STATIC,5,30,119,8 + EDITTEXT IDC_VALUE_DATA,5,40,200,112, WS_BORDER | WS_TABSTOP | WS_HSCROLL | WS_VSCROLL | ES_MULTILINE | ES_WANTRETURN + DEFPUSHBUTTON "OK",IDOK,130,160,30,11,WS_GROUP + PUSHBUTTON "Îòìåíèòü",IDCANCEL,165,160,40,11,WS_GROUP +END + +/* + * String Table + */ + +STRINGTABLE DISCARDABLE +BEGIN + IDS_LIST_COLUMN_NAME "Èìÿ" + IDS_LIST_COLUMN_TYPE "Òèï" + IDS_LIST_COLUMN_DATA "Äàííûå" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_APP_TITLE "Ðåäàêòîð ðååñòðà" +END + +STRINGTABLE DISCARDABLE +BEGIN + ID_REGISTRY_MENU "Ñîäåðæèò êîìàíäû äëÿ ðàáîòû ñ ðååñòðîì â öåëîì" + ID_EDIT_MENU "Ñîäåðæèò êîìàíäû äëÿ ðåäàêòèðîâàíèÿ çíà÷åíèé èëè êëþ÷åé" + ID_VIEW_MENU "Ñîäåðæèò êîìàíäû äëÿ íàñòðîéêè îêíà ðååñòðà" + ID_FAVORITES_MENU "Ñîäåðæèò êîìàíäû äëÿ äîñòóïà ê ÷àñòî èñïîëüçóåìûì êëþ÷àì" + ID_HELP_MENU "Ñîäåðæèò êîìàíäû äëÿ îòîáðàæåíèÿ ñïðàâêè è èíôîðìàöèè î ðåäàêòîðå ðååñòðà" + ID_EDIT_NEW_MENU "Ñîäåðæèò êîìàíäû äëÿ ñîçäàíèÿ íîâûõ êëþ÷åé èëè çíà÷åíèé" +END + +STRINGTABLE DISCARDABLE +BEGIN + ID_EDIT_MODIFY "Èçìåíÿåò çíà÷åíèå ïàðàìåòðà" + ID_EDIT_NEW_KEY "Äîáàâëÿåò íîâûé êëþ÷" + ID_EDIT_NEW_STRINGVALUE "Äîáàâëÿåò íîâîå ñòðîêîâîå çíà÷åíèå" + ID_EDIT_NEW_BINARYVALUE "Äîáàâëÿåò íîâîå áèíàðíîå çíà÷åíèå" + ID_EDIT_NEW_DWORDVALUE "Äîáàâëÿåò íîâîå DWORD-çíà÷åíèå" + ID_EDIT_NEW_MULTI_STRINGVALUE "Äîáàâëÿåò íîâîå ìíîãîñòðîêîâîå çíà÷åíèå" + ID_REGISTRY_IMPORTREGISTRYFILE "Èìïîðòèðóåò òåêñòîâîé ôàéë â ðååñòð" + ID_REGISTRY_EXPORTREGISTRYFILE + "Ýêñïîðòèðóåò âåñü ðååñòð èëè åãî ÷àñòü â òåêñòîâîé ôàéë" + ID_REGISTRY_CONNECTNETWORKREGISTRY + "Ïîäêëþ÷àåòñÿ ê ðååñòðó óäàë¸ííîãî êîìïüþòåðà" + ID_REGISTRY_DISCONNECTNETWORKREGISTRY + "Îòêëþ÷àåòñÿ îò ðååñòðà óäàë¸ííîãî êîìïüþòåðà" + ID_REGISTRY_PRINT "Ïå÷àòàåò âåñü ðååñòð èëè åãî ÷àñòü" +/* ID_HELP_HELPTOPICS "Opens registry editor help" */ + ID_HELP_ABOUT "Îòîáðàæàåò èíôîðìàöèþ î ïðîãðàììå, íîìåð âåðñèè è ñïèñîê àâòîðîâ" +END + +STRINGTABLE DISCARDABLE +BEGIN + ID_REGISTRY_EXIT "Âûõîä èç ðåäàêòîðà ðååñòðà" + ID_FAVORITES_ADDTOFAVORITES "Äîáàâèòü êëþ÷ â èçáðàííîå" + ID_FAVORITES_REMOVEFAVORITE "Óäàëèòü êëþ÷ èç èçáðàííîãî" + ID_VIEW_STATUSBAR "Ïîêàçàòü èëè ñêðûòü ñòðîêó ñîñòîÿíèÿ" + ID_VIEW_SPLIT "Èçìåíèòü ïîçèöèþ ðàçäåëèòåëÿ ìåæäó äâóìÿ ïàíåëÿìè" + ID_VIEW_REFRESH "Îáíîâëÿåò îêíî" + ID_EDIT_DELETE "Óäàëÿåò âûäåëåíèå" + ID_EDIT_RENAME "Ïåðåèìåíîâûâàåò âûäåëåíèå" + ID_EDIT_COPYKEYNAME "Êîïèðóåò èìÿ âûäåëåííîãî êëþ÷à â áóôåð îáìåíà" + ID_EDIT_FIND "Èùåò òåêñòîâóþ ñòðîêó â êëþ÷å, çíà÷åíèè èëè äàííûõ" + ID_EDIT_FINDNEXT "Èùåò ñëåäóþùåå ñîâïàäåíèå òåêñòà, çàäàííîãî â ïðåäûäóùåì ïîèñêå" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_ERROR "Îøèáêà" + IDS_BAD_KEY "Íåâîçìîæíî çàïðîñèòü êëþ÷ '%s'" + IDS_BAD_VALUE "Íåâîçìîæíî çàïðîñèòü çíà÷åíèå '%s'" + IDS_UNSUPPORTED_TYPE "Ðåäàêòèðîâàíèå êëþ÷åé òèïà (%u) íå ïîääåðæèâàåòñÿ" + IDS_TOO_BIG_VALUE "Çíà÷åíèå ñëèøêîì âåëèêî (%u)" + IDS_DELETE_BOX_TITLE "Ïîäòâåðæäåíèå" + IDS_DELETE_BOX_TEXT "Óäàëèòü çíà÷åíèå '%s'?" + IDS_DELETE_BOX_TEXT_MULTIPLE "Are you sure you want to delete these values?" + IDS_NEWKEY "Íîâûé êëþ÷ #%d" + IDS_NEWVALUE "Íîâîå çíà÷åíè #%d" + IDS_NOTFOUND "Èñêîìàÿ ñòðîêà '%s' íå íàéäåíà" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_FILEDIALOG_IMPORT_TITLE "Èìïîðò ôàéëà ðååñòðà" + IDS_FILEDIALOG_EXPORT_TITLE "Ýêñïîðò ôàéëà ðååñòðà" + IDS_FILEDIALOG_FILTER "Âñå ôàéëû ðååñòðà\0*.reg\0Ôàéëû ðååñòðà äëÿ Win9x/NT4 (REGEDIT4)\0*.reg\0Âñå ôàéëû (*.*)\0*.*\0\0" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_REGISTRY_ROOT_NAME "Ìîé Êîìïüþòåð" + IDS_REGISTRY_DEFAULT_VALUE "(Ïî óìîë÷àíèþ)" + IDS_REGISTRY_VALUE_NOT_SET "(çíà÷åíèå íå çàäàíî)" + IDS_REGISTRY_VALUE_CANT_DISPLAY "(íåâîçìîæíî îòîáðàçèòü)" + IDS_REGISTRY_UNKNOWN_TYPE "(íåèçâåñòíî %d)" +END + +/*****************************************************************/ + +/* + * TEXTINCLUDE + */ + +1 TEXTINCLUDE DISCARDABLE +BEGIN + "resource.h\0" +END + +/*****************************************************************/ diff --git a/programs/regedit/Si.rc b/programs/regedit/Si.rc index 8c2c1aa558c..9c6cf329acf 100644 --- a/programs/regedit/Si.rc +++ b/programs/regedit/Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -285,7 +283,6 @@ BEGIN ID_EDIT_COPYKEYNAME "Kopira ime izbranega ključa na odložišče" ID_EDIT_FIND "Poišče znakovni niz v ključu, vrednosti ali vsebini vrednosti" ID_EDIT_FINDNEXT "Poišče naslednjo ponovitev iskanega besedila" - ID_EDIT_EXPORT "Izvozi izbrano vejo registra v tekstovno datoteko" END STRINGTABLE DISCARDABLE @@ -331,3 +328,5 @@ BEGIN END /*****************************************************************/ + +#pragma code_page(default) diff --git a/programs/regedit/Sv.rc b/programs/regedit/Sv.rc index 38277399980..dd384d9ada6 100644 --- a/programs/regedit/Sv.rc +++ b/programs/regedit/Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL /* diff --git a/programs/regedit/Tr.rc b/programs/regedit/Tr.rc index 3065628b2e4..2f1bc0468a4 100644 --- a/programs/regedit/Tr.rc +++ b/programs/regedit/Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT /* diff --git a/programs/regedit/Zh.rc b/programs/regedit/Zh.rc index 87561bdf9f6..931be0ec6b7 100644 --- a/programs/regedit/Zh.rc +++ b/programs/regedit/Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -640,3 +638,5 @@ BEGIN END /*****************************************************************/ + +#pragma code_page(default) diff --git a/programs/regedit/childwnd.c b/programs/regedit/childwnd.c index a7e4666cc09..74c8b66ba1b 100644 --- a/programs/regedit/childwnd.c +++ b/programs/regedit/childwnd.c @@ -24,7 +24,6 @@ #include #include "main.h" -#include "regproc.h" #include "wine/debug.h" #include "wine/unicode.h" @@ -34,13 +33,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(regedit); ChildWnd* g_pChildWnd; static int last_split; -static const WCHAR wszLastKey[] = {'L','a','s','t','K','e','y',0}; -static const WCHAR wszKeyName[] = {'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','\\', - 'A','p','p','l','e','t','s','\\','R','e','g','e','d','i','t',0}; - /******************************************************************************* * Local module support methods */ @@ -230,47 +222,6 @@ static BOOL _CmdWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam) } /******************************************************************************* - * get_last_key [internal] - * - * open last key - * - */ -static void get_last_key(HWND hwndTV) -{ - HKEY hkey; - WCHAR wszVal[KEY_MAX_LEN]; - DWORD dwSize = sizeof(wszVal); - - if (RegCreateKeyExW(HKEY_CURRENT_USER, wszKeyName, 0, NULL, 0, KEY_READ, NULL, &hkey, NULL) == ERROR_SUCCESS) - { - if (RegQueryValueExW(hkey, wszLastKey, NULL, NULL, (LPBYTE)wszVal, &dwSize) == ERROR_SUCCESS) - SendMessageW(hwndTV, TVM_SELECTITEM, TVGN_CARET, (LPARAM)FindPathInTree(hwndTV, wszVal)); - - RegCloseKey(hkey); - } -} - -/******************************************************************************* - * set_last_key [internal] - * - * save last key - * - */ -static void set_last_key(HWND hwndTV) -{ - HKEY hkey; - WCHAR *wszVal; - - if (RegCreateKeyExW(HKEY_CURRENT_USER, wszKeyName, 0, NULL, 0, KEY_WRITE, NULL, &hkey, NULL) == ERROR_SUCCESS) - { - wszVal = GetItemFullPath(g_pChildWnd->hTreeWnd, TreeView_GetSelection(g_pChildWnd->hTreeWnd), FALSE); - RegSetValueExW(hkey, wszLastKey, 0, REG_SZ, (LPBYTE)wszVal, KEY_MAX_LEN * sizeof(WCHAR)); - HeapFree(GetProcessHeap(), 0, wszVal); - RegCloseKey(hkey); - } -} - -/******************************************************************************* * * FUNCTION: ChildWndProc(HWND, unsigned, WORD, LONG) * @@ -294,7 +245,6 @@ LRESULT CALLBACK ChildWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa g_pChildWnd->hListWnd = CreateListView(hWnd, LIST_WINDOW/*, g_pChildWnd->szPath*/); g_pChildWnd->nFocusPanel = 1; SetFocus(g_pChildWnd->hTreeWnd); - get_last_key(g_pChildWnd->hTreeWnd); break; case WM_COMMAND: if (!_CmdWndProc(hWnd, message, wParam, lParam)) { @@ -316,7 +266,6 @@ LRESULT CALLBACK ChildWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa } goto def; case WM_DESTROY: - set_last_key(g_pChildWnd->hTreeWnd); HeapFree(GetProcessHeap(), 0, g_pChildWnd); g_pChildWnd = NULL; PostQuitMessage(0); diff --git a/programs/regedit/resource.h b/programs/regedit/resource.h index d1672513cff..c3b8456bd89 100644 --- a/programs/regedit/resource.h +++ b/programs/regedit/resource.h @@ -18,9 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include - #define ID_REGISTRY_MENU 0 #define ID_EDIT_MENU 1 #define ID_VIEW_MENU 2 diff --git a/programs/regedit/rsrc.rc b/programs/regedit/rsrc.rc index 71f4080897e..6627a64f935 100644 --- a/programs/regedit/rsrc.rc +++ b/programs/regedit/rsrc.rc @@ -18,6 +18,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include +#include + #include "resource.h" /* define language neutral resources */ @@ -64,3 +67,27 @@ IDI_REGEDIT ICON DISCARDABLE regedit.ico #define WINE_PRODUCTVERSION_STR "5.2" #include "wine/wine_common_ver.rc" + +/* include localised resources */ + +#include "Bg.rc" +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Es.rc" +#include "Fr.rc" +#include "Hu.rc" +#include "It.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Lt.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" diff --git a/programs/secedit/Makefile.in b/programs/secedit/Makefile.in index 0b356d84edb..58fa913bc61 100644 --- a/programs/secedit/Makefile.in +++ b/programs/secedit/Makefile.in @@ -8,7 +8,7 @@ APPMODE = -mconsole IMPORTS = kernel32 C_SRCS = \ - main.c + main.c \ @MAKE_PROG_RULES@ diff --git a/programs/services/services.c b/programs/services/services.c index 091c6932aea..9bed78423b5 100644 --- a/programs/services/services.c +++ b/programs/services/services.c @@ -349,7 +349,7 @@ struct service_entry *scmdatabase_find_service_by_displayname(struct scmdatabase LIST_FOR_EACH_ENTRY(service, &db->services, struct service_entry, entry) { - if (service->config.lpDisplayName && strcmpiW(name, service->config.lpDisplayName) == 0) + if (strcmpiW(name, service->config.lpDisplayName) == 0) return service; } diff --git a/programs/start/Cs.rc b/programs/start/Cs.rc index fa00dd057c5..1693f8b4b4e 100644 --- a/programs/start/Cs.rc +++ b/programs/start/Cs.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/programs/start/De.rc b/programs/start/De.rc index 39770668e2d..4f54a5389a1 100644 --- a/programs/start/De.rc +++ b/programs/start/De.rc @@ -20,15 +20,11 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL { -STRING_USAGE, "Startet ein Programm, oder öffnet ein Dokument in dem Programm, dass normalerweise für die Dateien mit dieser Dateiendung benutzt wird..\n\ +STRING_USAGE, "Startet ein Programm, oder öffnet ein Dokument in dem Programm, dass normalerweise für die Dateien mit dieser Dateiendung benutzt wird..\n\ Gebrauch:\n\ start [Optionen] Programm_Dateiname [...]\n\ start [Optionen] Dokument_Dateiname\n\ @@ -42,9 +38,9 @@ Optionen:\n\ /L Zeige die Endbenutzerlizenz an.\n\ \n\ start.exe Version 0.2 Copyright (C) 2003, Dan Kegel\n\ -Start kommt ABSOLUT OHNE GARANTIE; für detaillierte Informationen, starte es mit der /L Option.\n\ +Start kommt ABSOLUT OHNE GARANTIE; für detaillierte Informationen, starte es mit der /L Option.\n\ Dies ist freie Software, und du bist willkommen, es unter bestimmten\n\ -Bedingungen weiter zu verbreiten; führe 'start /L' für mehr Details aus.\n\ +Bedingungen weiter zu verbreiten; führe 'start /L' für mehr Details aus.\n\ " STRING_LICENSE, "start.exe version 0.2 Copyright (C) 2003, Dan Kegel\n\ @@ -62,10 +58,10 @@ You should have received a copy of the GNU Lesser Public License\n\ along with this program; if not, write to the Free Software\n\ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.\n\ \n\ -Schau in die Datei COPYING.LIB für Lizenzinformationen.\n\ +Schau in die Datei COPYING.LIB für Lizenzinformationen.\n\ " -STRING_EXECFAIL "Es konnte keine Anwendung gestartet werden, oder es ist keine Anwendung mit der angegebenen Datei verknüpft.\nShellExecuteEx gescheitert" +STRING_EXECFAIL "Es konnte keine Anwendung gestartet werden, oder es ist keine Anwendung mit der angegebenen Datei verknüpft.\nShellExecuteEx gescheitert" STRING_UNIXFAIL "Der angegebene Unix Dateiname konnte nicht in einen DOS Dateinamen umgewandelt werden." } diff --git a/programs/start/En.rc b/programs/start/En.rc index 463b6c20048..0429fe9b8b8 100644 --- a/programs/start/En.rc +++ b/programs/start/En.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT diff --git a/programs/start/Es.rc b/programs/start/Es.rc index 83881c6a985..ac1c6d73ab9 100644 --- a/programs/start/Es.rc +++ b/programs/start/Es.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/programs/start/Fr.rc b/programs/start/Fr.rc index 343398e9f6f..a2c8fd77149 100644 --- a/programs/start/Fr.rc +++ b/programs/start/Fr.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL #pragma code_page(65001) /* UTF-8 */ @@ -71,3 +69,5 @@ STRING_EXECFAIL "Le programme n'a pas pu être lancé, ou il n'y a pas de progra STRING_UNIXFAIL, "Le nom de fichier Unix spécifié n'a pas pu être converti en nom de fichier DOS." } + +#pragma code_page(default) /* Return to default encoding */ diff --git a/programs/start/It.rc b/programs/start/It.rc index 2ba54172d81..42f59ace794 100644 --- a/programs/start/It.rc +++ b/programs/start/It.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE diff --git a/programs/start/Ko.rc b/programs/start/Ko.rc index 4435d5758c0..bc58ebcfab9 100644 --- a/programs/start/Ko.rc +++ b/programs/start/Ko.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE @@ -37,7 +35,7 @@ Options:\n\ /R[estored] Ç®±×¸²À» º¸Åë»óÅ·Π½ÃÀÛ½ÃÅ°±â (ÃÖ¼ÒÈ­µµ ¾Æ´Ï°í ÃÖ´ëÈ­µµ ¾Æ´Ô).\n\ /W[ait] ½ÃÀÛµÈ Ç®±×¸²ÀÌ ³¡³¯ ¶§±îÁö ±â´Ù¸², ³¡³¯ ¶§ Á¾·áÄڵ带 ³²±è.\n\ /Unix À©µµ¿ì ÀͽºÇ÷ξÀÌ À¯´Ð½º ÆÄÀÏÀ̸§À» »ç¿ëÇؼ­ ½ÃÀÛ.\n\ -/ProgIDOpen ÁöÁ¤ÇÑ progID¸¦ »ç¿ëÇؼ­ ¹®¼­ ¿­±â.\n\ +/ProgIDOpen Open a document using the following progID.\n\ /L »ç¿ëÀÚ ¶óÀ̼¾½º º¸¿©ÁÜ\n\ \n\ start.exe version 0.2 Copyright (C) 2003, Dan Kegel\n\ diff --git a/programs/start/Lt.rc b/programs/start/Lt.rc index c25cce0fa37..1717a84a2e2 100644 --- a/programs/start/Lt.rc +++ b/programs/start/Lt.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - /* UTF-8 */ #pragma code_page(65001) @@ -44,7 +42,7 @@ Parametrai:\n\ start.exe versija 0.2 (C) 2003, Dan Kegel\n\ Start pateikiama BE JOKIŲ GARANTIJŲ; detales rasite paleidę su /L parametru.\n\ Ši programa yra laisva programinė įranga; galite ją platinti\n\ -tam tikromis sąlygomis; paleiskite „start /L“ išsamiai informacijai gauti.\n\ +tam tikromis sąlygomis; paleiskite 'start /L' išsamiai informacijai gauti.\n\ " STRING_LICENSE, "start.exe versija 0.2 (C) 2003, Dan Kegel\n\ @@ -71,3 +69,5 @@ STRING_EXECFAIL, "Nepavyko paleisti programos arba nėra programos susietos su n STRING_UNIXFAIL "Nepavyko paversti nurodyto Unix failo pavadinimo į DOS failo pavadinimą." } + +#pragma code_page(default) diff --git a/programs/start/Makefile.in b/programs/start/Makefile.in index a96fbce7e89..976766f3524 100644 --- a/programs/start/Makefile.in +++ b/programs/start/Makefile.in @@ -9,22 +9,7 @@ IMPORTS = shell32 user32 kernel32 C_SRCS = start.c -RC_SRCS = \ - Cs.rc \ - De.rc \ - En.rc \ - Es.rc \ - Fr.rc \ - It.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Si.rc \ - Tr.rc +RC_SRCS = rsrc.rc @MAKE_PROG_RULES@ diff --git a/programs/start/Nl.rc b/programs/start/Nl.rc index 50252fabeec..69012a153c9 100644 --- a/programs/start/Nl.rc +++ b/programs/start/Nl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL diff --git a/programs/start/No.rc b/programs/start/No.rc index 5d2da447557..15b4dbc3845 100644 --- a/programs/start/No.rc +++ b/programs/start/No.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE DISCARDABLE LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL diff --git a/programs/start/Pl.rc b/programs/start/Pl.rc index d2df6eaba83..09b9f51e338 100644 --- a/programs/start/Pl.rc +++ b/programs/start/Pl.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE diff --git a/programs/start/Pt.rc b/programs/start/Pt.rc index 2305509318a..51ff53bec82 100644 --- a/programs/start/Pt.rc +++ b/programs/start/Pt.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE DISCARDABLE diff --git a/programs/start/Ru.rc b/programs/start/Ru.rc index 48248ee2963..97e98540761 100644 --- a/programs/start/Ru.rc +++ b/programs/start/Ru.rc @@ -18,39 +18,34 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT -STRINGTABLE DISCARDABLE +STRINGTABLE DISCARDABLE LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT { -STRING_USAGE, "Запускает программы или открывает документы приложением,\n\ -обычно используемым для файлов с данным расширением.\n\n\ -Использование:\n\ -start [options] имя_файла_программы [...]\n\ -start [options] имя_файла_документа\n\ +STRING_USAGE, "Çàïóñêàåò ïðîãðàììû èëè îòêðûâàåò äîêóìåíòû ïðèëîæåíèåì,\n\ +îáû÷íî èñïîëüçóåìûì äëÿ ôàéëîâ ñ äàííûì ðàñøèðåíèåì.\n\n\ +Èñïîëüçîâàíèå:\n\ +start [options] èìÿ_ôàéëà_ïðîãðàììû [...]\n\ +start [options] èìÿ_ôàéëà_äîêóìåíòà\n\ \n\ -Опции:\n\ -/M[inimized] Запустить программу минимизированной.\n\ -/MAX[imized] Запустить программу максимизированной.\n\ -/R[estored] Запустить программу нормально (не максимизированно и не минимизированно).\n\ -/W[ait] Ожидать завершения запущенной программы и выйти с кодом её выхода.\n\ -/Unix Использовать путь Unix для запуска програмы как виндовс проводник.\n\ +Îïöèè:\n\ +/M[inimized] Çàïóñòèòü ïðîãðàììó ìèíèìèçèðîâàííîé.\n\ +/MAX[imized] Çàïóñòèòü ïðîãðàììó ìàêñèìèçèðîâàííîé.\n\ +/R[estored] Çàïóñòèòü ïðîãðàììó íîðìàëüíî (íå ìàêñèìèçèðîâàííî è íå ìèíèìèçèðîâàííî).\n\ +/W[ait] Îæèäàòü çàâåðøåíèÿ çàïóùåííîé ïðîãðàììû è âûéòè ñ êîäîì å¸ âûõîäà.\n\ +/Unix Èñïîëüçîâàòü ïóòü Unix äëÿ çàïóñêà ïðîãðàìû êàê âèíäîâñ ïðîâîäíèê.\n\ /ProgIDOpen Open a document using the following progID.\n\ -/L Показать лицензию конечного пользователя.\n\ +/L Ïîêàçàòü ëèöåíçèþ êîíå÷íîãî ïîëüçîâàòåëÿ.\n\ \n\ -start.exe версия 0.2 Copyright (C) 2003, Dan Kegel\n\ -Start идет БЕЗ КАКИХ-ЛИБО ГАРАНТИЙ; подробности при запуске с опцией /L.\n\ -Это свободная программа, и вы можете её распространять на определённых\n\ -условиях; подробности при запуске с опцией /L.\n\ +start.exe âåðñèÿ 0.2 Copyright (C) 2003, Dan Kegel\n\ +Start èäåò ÁÅÇ ÊÀÊÈÕ-ËÈÁÎ ÃÀÐÀÍÒÈÉ; ïîäðîáíîñòè ïðè çàïóñêå ñ îïöèåé /L.\n\ +Ýòî ñâîáîäíàÿ ïðîãðàììà, è âû ìîæåòå å¸ ðàñïðîñòðàíÿòü íà îïðåäåë¸ííûõ\n\ +óñëîâèÿõ; ïîäðîáíîñòè ïðè çàïóñêå ñ îïöèåé /L.\n\ " -STRING_LICENSE, "start.exe версия 0.2 Copyright (C) 2003, Dan Kegel\n\ -Это программа распространяется по лицензии GNU Lesser Public License\n\ -и является свободным программным продуктом.\n\ +STRING_LICENSE, "start.exe âåðñèÿ 0.2 Copyright (C) 2003, Dan Kegel\n\ +Ýòî ïðîãðàììà ðàñïðîñòðàíÿåòñÿ ïî ëèöåíçèè GNU Lesser Public License\n\ +è ÿâëÿåòñÿ ñâîáîäíûì ïðîãðàììíûì ïðîäóêòîì.\n\ \n\ This program is free software; you can redistribute it and/or\n\ modify it under the terms of the GNU Lesser Public License\n\ @@ -69,7 +64,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.\n\ See the COPYING.LIB file for license information.\n\ " -STRING_EXECFAIL "Приложение не может быть запущено или не ассоциировано приложений с типом данного документа.\nВызов ShellExecuteEx провалился" +STRING_EXECFAIL "Ïðèëîæåíèå íå ìîæåò áûòü çàïóùåíî èëè íå àññîöèèðîâàíî ïðèëîæåíèé ñ òèïîì äàííîãî äîêóìåíòà.\nÂûçîâ ShellExecuteEx ïðîâàëèëñÿ" -STRING_UNIXFAIL "Невозможно перевести имя программы UNIX в имя DOS." +STRING_UNIXFAIL "Íåâîçìîæíî ïåðåâåñòè èìÿ ïðîãðàììû UNIX â èìÿ DOS." } diff --git a/programs/start/Si.rc b/programs/start/Si.rc index 0ed1ff981bb..e10ddf79d56 100644 --- a/programs/start/Si.rc +++ b/programs/start/Si.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -68,3 +66,5 @@ STRING_EXECFAIL "Programa ni mogoče zagnati ali pa z datoteko te vrste ni povez STRING_UNIXFAIL "Navedenega Unix imena datoteke ni mogoče prevesti v DOS ime datoteke." } + +#pragma code_page(default) diff --git a/programs/start/Tr.rc b/programs/start/Tr.rc index fefc94bdc9e..de7a69d9d41 100644 --- a/programs/start/Tr.rc +++ b/programs/start/Tr.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT diff --git a/programs/start/resources.h b/programs/start/resources.h index fd8641d2c25..f5abd31302a 100644 --- a/programs/start/resources.h +++ b/programs/start/resources.h @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include - #define STRING_USAGE 101 #define STRING_LICENSE 102 #define STRING_EXECFAIL 103 diff --git a/programs/start/rsrc.rc b/programs/start/rsrc.rc new file mode 100644 index 00000000000..abfee945b64 --- /dev/null +++ b/programs/start/rsrc.rc @@ -0,0 +1,39 @@ +/* + * Copyright 2003 Dan Kegel + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include + +#include "resources.h" + +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + +#include "Cs.rc" +#include "De.rc" +#include "En.rc" +#include "Es.rc" +#include "Fr.rc" +#include "It.rc" +#include "Ko.rc" +#include "Lt.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Tr.rc" diff --git a/programs/taskmgr/Da.rc b/programs/taskmgr/Da.rc index fa59e938d8f..fb9bab07a79 100644 --- a/programs/taskmgr/Da.rc +++ b/programs/taskmgr/Da.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT /* diff --git a/programs/taskmgr/De.rc b/programs/taskmgr/De.rc index 0c2f5ee20e6..4f12f728747 100644 --- a/programs/taskmgr/De.rc +++ b/programs/taskmgr/De.rc @@ -3,7 +3,6 @@ * German Language Support * * Copyright 2005 Henning Gerhardt - * Copyright 2009 André Hentschel * * * This library is free software; you can redistribute it and/or @@ -21,10 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL /* @@ -35,7 +30,7 @@ IDR_TASKMANAGER MENU DISCARDABLE BEGIN POPUP "&Datei" BEGIN - MENUITEM "&Neuer Task (Ausführen...)", ID_FILE_NEW + MENUITEM "&Neuer Task (Ausführen...)", ID_FILE_NEW MENUITEM SEPARATOR MENUITEM "Task-Manager &Beenden", ID_FILE_EXIT END @@ -63,10 +58,10 @@ BEGIN END MENUITEM SEPARATOR - MENUITEM "&Große Symbole", ID_VIEW_LARGE + MENUITEM "&Große Symbole", ID_VIEW_LARGE MENUITEM "&Kleine Symbole", ID_VIEW_SMALL MENUITEM "&Details", ID_VIEW_DETAILS, CHECKED - MENUITEM "&Spalten auswählen...", ID_VIEW_SELECTCOLUMNS + MENUITEM "&Spalten auswählen...", ID_VIEW_SELECTCOLUMNS POPUP "&CPU Verlauf" BEGIN MENUITEM "&Ein Graph, Alle CPUs", ID_VIEW_CPUHISTORY_ONEGRAPHALL @@ -78,7 +73,7 @@ BEGIN END POPUP "&Fenster" BEGIN - MENUITEM "&Übereinander", ID_WINDOWS_TILEHORIZONTALLY + MENUITEM "&Übereinander", ID_WINDOWS_TILEHORIZONTALLY MENUITEM "&Nebeneinander", ID_WINDOWS_TILEVERTICALLY MENUITEM "&Minimieren", ID_WINDOWS_MINIMIZE MENUITEM "Ma&ximieren", ID_WINDOWS_MAXIMIZE @@ -89,13 +84,13 @@ BEGIN BEGIN MENUITEM "Task-Manager &Hilfethemen", ID_HELP_TOPICS MENUITEM SEPARATOR - MENUITEM "&Über Task-Manager", ID_HELP_ABOUT + MENUITEM "&Über Task-Manager", ID_HELP_ABOUT END END IDR_WINDOWSMENU MENU DISCARDABLE BEGIN - MENUITEM "&Übereinander", ID_WINDOWS_TILEHORIZONTALLY + MENUITEM "&Übereinander", ID_WINDOWS_TILEHORIZONTALLY MENUITEM "&Nebeneinander", ID_WINDOWS_TILEVERTICALLY MENUITEM "&Minimieren", ID_WINDOWS_MINIMIZE MENUITEM "Ma&ximieren", ID_WINDOWS_MAXIMIZE @@ -107,9 +102,9 @@ IDR_APPLICATION_PAGE_CONTEXT1 MENU DISCARDABLE BEGIN POPUP "DUMMY" BEGIN - MENUITEM "&Neuen Task (Ausführen...)", ID_FILE_NEW + MENUITEM "&Neuen Task (Ausführen...)", ID_FILE_NEW MENUITEM SEPARATOR - MENUITEM "&Große Symbole", ID_VIEW_LARGE + MENUITEM "&Große Symbole", ID_VIEW_LARGE MENUITEM "&Kleine Symbole", ID_VIEW_SMALL MENUITEM "&Details", ID_VIEW_DETAILS, CHECKED END @@ -122,7 +117,7 @@ BEGIN MENUITEM "&Wechseln zu", ID_APPLICATION_PAGE_SWITCHTO MENUITEM "&In den Vordergrund holen", ID_WINDOWS_BRINGTOFRONT MENUITEM SEPARATOR - MENUITEM "&Übereinander", ID_WINDOWS_TILEHORIZONTALLY + MENUITEM "&Übereinander", ID_WINDOWS_TILEHORIZONTALLY MENUITEM "&Nebeneinander", ID_WINDOWS_TILEVERTICALLY MENUITEM "&Minimieren", ID_WINDOWS_MINIMIZE MENUITEM "Ma&ximieren", ID_WINDOWS_MAXIMIZE @@ -138,7 +133,7 @@ BEGIN POPUP "DUMMY" BEGIN MENUITEM "&Wiederherstellen", ID_RESTORE - MENUITEM "&Schließen", ID_FILE_EXIT + MENUITEM "&Schließen", ID_FILE_EXIT MENUITEM SEPARATOR MENUITEM "&Immer im Vordergrund", ID_OPTIONS_ALWAYSONTOP END @@ -153,17 +148,17 @@ BEGIN MENUITEM "&Debuggen", ID_PROCESS_PAGE_DEBUG MENUITEM SEPARATOR - POPUP "Setze &Priorität" + POPUP "Setze &Priorität" BEGIN MENUITEM "&Echtzeit", ID_PROCESS_PAGE_SETPRIORITY_REALTIME MENUITEM "&Hoch", ID_PROCESS_PAGE_SETPRIORITY_HIGH - MENUITEM "&Höher als Normal", ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL + MENUITEM "&Höher als Normal", ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL MENUITEM "&Normal", ID_PROCESS_PAGE_SETPRIORITY_NORMAL MENUITEM "N&iedriger als Normal", ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL MENUITEM "Nie&drig", ID_PROCESS_PAGE_SETPRIORITY_LOW END - MENUITEM "Setze Affinität...", ID_PROCESS_PAGE_SETAFFINITY - MENUITEM "Editiere Debug&kanäle...", ID_PROCESS_PAGE_DEBUGCHANNELS + MENUITEM "Setze Affinität...", ID_PROCESS_PAGE_SETAFFINITY + MENUITEM "Editiere Debug&kanäle...", ID_PROCESS_PAGE_DEBUGCHANNELS END END @@ -266,23 +261,23 @@ END IDD_DEBUG_CHANNELS_DIALOG DIALOG DISCARDABLE 0, 0, 247, 210 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Debugkanäle" +CAPTION "Debugkanäle" FONT 8, "MS Shell Dlg" BEGIN CONTROL "List2",IDC_DEBUG_CHANNELS_LIST,"SysListView32",LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP | LVS_SORTASCENDING,7,7,233,177 - PUSHBUTTON "Schließen",IDOK,171,189,69,14 + PUSHBUTTON "Schließen",IDOK,171,189,69,14 END IDD_AFFINITY_DIALOG DIALOG DISCARDABLE 0, 0, 231, 154 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Prozessoraffinität" +CAPTION "Prozessoraffinität" FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "OK",IDOK,120,133,50,14 PUSHBUTTON "Abbrechen",IDCANCEL,174,133,50,14 - LTEXT "Die Prozessoraffinitätseinstellung kontrolliert, auf welchen CPUs der Prozess die Erlaubnis hat, ausgeführt werden zu können.", + LTEXT "Die Prozessoraffinitätseinstellung kontrolliert, auf welchen CPUs der Prozess die Erlaubnis hat, ausgeführt werden zu können.", IDC_STATIC,5,5,220,16 CONTROL "CPU 0",IDC_CPU0,"Button",BS_AUTOCHECKBOX | WS_TABSTOP, 11,28,37,10 @@ -352,12 +347,12 @@ END IDD_COLUMNS_DIALOG DIALOG DISCARDABLE 0, 0, 245, 199 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Spalten auswählen" +CAPTION "Spalten auswählen" FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "OK",IDOK,84,178,50,14 PUSHBUTTON "Abbrechen",IDCANCEL,138,178,50,14 - LTEXT "Wählen Sie die Spalten aus, die auf der Prozess-Seite des Task-Managers erscheinen sollen", + LTEXT "Wählen Sie die Spalten aus, die auf der Prozess-Seite des Task-Managers erscheinen sollen", IDC_STATIC,7,7,181,17 CONTROL "&Name",IDC_IMAGENAME,"Button",BS_AUTOCHECKBOX | WS_DISABLED | WS_TABSTOP,7,28,56,10 @@ -369,7 +364,7 @@ BEGIN WS_TABSTOP,7,61,48,10 CONTROL "S&peicherauslastung",IDC_MEMORYUSAGE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,72,95,10 - CONTROL "&Veränd. der Speicherauslastung",IDC_MEMORYUSAGEDELTA,"Button", + CONTROL "&Veränd. der Speicherauslastung",IDC_MEMORYUSAGEDELTA,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,7,83,115,10 CONTROL "&Maximale Speicherauslastung",IDC_PEAKMEMORYUSAGE,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,7,94,115,10 @@ -385,15 +380,15 @@ BEGIN WS_TABSTOP,7,149,50,10 CONTROL "Benutzer&name",IDC_USERNAME,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,160,80,10 - CONTROL "Verän&d. der Seitenfehler",IDC_PAGEFAULTSDELTA,"Button", + CONTROL "Verän&d. der Seitenfehler",IDC_PAGEFAULTSDELTA,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,132,28,72,10 - CONTROL "&Größe des virt. Speichers",IDC_VIRTUALMEMORYSIZE,"Button", + CONTROL "&Größe des virt. Speichers",IDC_VIRTUALMEMORYSIZE,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,132,39,105,10 CONTROL "Aus&gelagerter Pool",IDC_PAGEDPOOL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,132,50,90,10 CONTROL "Nich&tausgelagerter Pool",IDC_NONPAGEDPOOL,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,132,61,105,10 - CONTROL "Basisp&riorität",IDC_BASEPRIORITY,"Button", + CONTROL "Basisp&riorität",IDC_BASEPRIORITY,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,132,72,55,10 CONTROL "&Handle-Anzahl",IDC_HANDLECOUNT,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,132,83,59,10 @@ -426,12 +421,12 @@ STRINGTABLE DISCARDABLE BEGIN ID_FILE_NEW "Startet ein neues Programm" ID_OPTIONS_ALWAYSONTOP "Der Task-Manager bleibt immer mit seinen gesamten Fenstern im Vordergrund, bis er minimiert wird" - ID_OPTIONS_MINIMIZEONUSE "Der Task-Manager minimiert sich, wenn eine 'Wechseln zu' Operation ausgeführt wird" + ID_OPTIONS_MINIMIZEONUSE "Der Task-Manager minimiert sich, wenn eine 'Wechseln zu' Operation ausgeführt wird" ID_OPTIONS_HIDEWHENMINIMIZED "Versteckt den Task-Manager, wenn er minimiert ist" - ID_VIEW_REFRESH "Zwingt den Task Manager zu einer Aktualisierung, unabhänig von der Aktualisierungsgeschwindigkeit" - ID_VIEW_LARGE "Zeigt Tasks mit großen Symbolen an" + ID_VIEW_REFRESH "Zwingt den Task Manager zu einer Aktualisierung, unabhänig von der Aktualisierungsgeschwindigkeit" + ID_VIEW_LARGE "Zeigt Tasks mit großen Symbolen an" ID_VIEW_SMALL "Zeigt Tasks mit kleinen Symbolen an" - ID_VIEW_DETAILS "Zeigt detailierte Informationen über jeden einzelnen Task an" + ID_VIEW_DETAILS "Zeigt detailierte Informationen über jeden einzelnen Task an" ID_VIEW_UPDATESPEED_HIGH "Aktualisiert die Anzeige zweimal pro Sekunde" ID_VIEW_UPDATESPEED_NORMAL "Aktualisiert die Anzeige alle 2 Sekunden" ID_VIEW_UPDATESPEED_LOW "Aktualisiert die Anzeige alle 4 Sekunden" @@ -440,7 +435,7 @@ END STRINGTABLE DISCARDABLE BEGIN ID_VIEW_UPDATESPEED_PAUSED "Nicht automatisch aktualisieren" - ID_WINDOWS_TILEHORIZONTALLY "Stellt die Fenster übereinander auf dem Desktop dar" + ID_WINDOWS_TILEHORIZONTALLY "Stellt die Fenster übereinander auf dem Desktop dar" ID_WINDOWS_TILEVERTICALLY "Stellt die Fenster nebeneinander auf dem Desktop dar" ID_WINDOWS_MINIMIZE "Minimiert die Fenster" ID_WINDOWS_MAXIMIZE "Maximiert die Fenster" @@ -459,102 +454,17 @@ END STRINGTABLE DISCARDABLE BEGIN - ID_ENDTASK "Weist die ausgewählten Tasks an, sich zu beenden" - ID_GOTOPROCESS "Wechselt den Fokus zu dem Prozess des ausgewählten Tasks" + ID_ENDTASK "Weist die ausgewählten Tasks an, sich zu beenden" + ID_GOTOPROCESS "Wechselt den Fokus zu dem Prozess des ausgewählten Tasks" ID_RESTORE "Stellt den Task-Manager von seiner versteckten Status wieder her" ID_PROCESS_PAGE_ENDPROCESS "Entfernt den Prozess vom System" ID_PROCESS_PAGE_ENDPROCESSTREE "Entfernt den Prozess und alle seine Kindprozesse vom System" ID_PROCESS_PAGE_DEBUG "Heftet den Debugger an diesen Prozess an" - ID_PROCESS_PAGE_SETAFFINITY "Kontrolliert, auf welchen Prozessoren ein Prozess ausgeführt werden darf" - ID_PROCESS_PAGE_SETPRIORITY_REALTIME "Setzt den Prozess in die ECHTZEIT-Prioritätsklasse" - ID_PROCESS_PAGE_SETPRIORITY_HIGH "Setzt den Prozess in die HOCH-Prioritätsklasse" - ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL "Setzt den Prozess in die HÖHER ALS NORMAL-Prioritätsklasse" - ID_PROCESS_PAGE_SETPRIORITY_NORMAL "Setzt den Prozess in die NORMAL-Prioritätsklasse" - ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL "Setzt den Prozess in die NIEDRIGER ALS NORMAL-Prioritätsklasse" - ID_PROCESS_PAGE_SETPRIORITY_LOW "Setzt den Prozess in die NIEDRIG-Prioritätsklasse" - ID_PROCESS_PAGE_DEBUGCHANNELS "Stellt Debug-Kanäle ein" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_VIEW_LARGE "&Große Symbole" - IDS_VIEW_SMALL "&Kleine Symbole" - IDS_VIEW_DETAILS "&Details" - IDS_WINDOWS "&Windows" - IDS_VIEW_SELECTCOLUMNS "&Spalten auswählen..." - IDS_OPTIONS_SHOW16BITTASKS "&16-bit-Tasks anzeigen" - IDS_VIEW_CPUHISTORY "&CPU Verlauf" - IDS_VIEW_CPUHISTORY_ONEGRAPHALL "&Ein Graph, Alle CPUs" - IDS_VIEW_CPUHISTORY_ONEGRAPHPERCPU "Ein Graph &pro CPU" - IDS_VIEW_SHOWKERNELTIMES "K&ernelzeiten anzeigen" - IDS_APPLICATIONS "Anwendungen" - IDS_PROCESSES "Prozesse" - IDS_PERFORMANCE "Systemleistung" - IDS_STATUS_BAR_CPU_USAGE "CPU-Auslastung: %3d%%" - IDS_STATUS_BAR_PROCESSES "Prozesse: %d" - IDS_STATUS_BAR_MEMORY_USAGE "Speicherauslastung: %dK / %dK" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_IMAGENAME "Name" - IDS_PID "PID (Prozess-ID)" - IDS_CPUUSAGE "CPU-Auslastung" - IDS_CPUTIME "CPU-Zeit" - IDS_MEMORYUSAGE "Speicherauslastung" - IDS_MEMORYUSAGEDELTA "Veränd. der Speicherauslastung" - IDS_PEAKMEMORYUSAGE "Maximale Speicherauslastung" - IDS_PAGEFAULTS "Seitenfehler" - IDS_USEROBJECTS "Benutzer-Objekte" - IDS_IOREADS "E/A (Lesen)" - IDS_IOREADBYTES "E/A-Bytes (Lesen)" - IDS_SESSIONID "Sitzungs-ID" - IDS_USERNAME "Benutzername" - IDS_PAGEFAULTSDELTA "Veränd. der Seiten" - IDS_VIRTUALMEMORYSIZE "Größe des virt. Speichers" - IDS_PAGEDPOOL "Ausgelagerter Pool" - IDS_NONPAGEDPOOL "Nichtausgelagerter Pool" - IDS_BASEPRIORITY "Basispriorität" - IDS_HANDLECOUNT "Handle-Anzahl" - IDS_THREADCOUNT "Thread-Anzahl" - IDS_GDIOBJECTS "GDI-Objekte" - IDS_IOWRITES "E/A (Schreiben)" - IDS_IOWRITEBYTES "E/A-Bytes (Schreiben)" - IDS_IOOTHER "E/A (Andere)" - IDS_IOOTHERBYTES "E/A-Bytes (Andere)" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_WARNING_TITLE "Task Manager Warnung" - IDS_PRIORITY_CHANGE_MESSAGE "WARNUNG: Änderung der Prioritätsklasse dieses Prozesses\n\ - kann zu unerwünschten Ergebnissen und Systeminstabilität\n\ - führen. Sind Sie sicher, dass Sie sie ändern möchten?" - IDS_PRIORITY_UNABLE2CHANGE "Die Priorität kann nicht geändert werden " - IDS_TERMINATE_MESSAGE "WARNUNG: Beenden des Prozesses kann zu unerwünschten\n\ - Ergebnissen und Systeminstabilität, sowie Datenverlust\n\ - führen. Dem Prozess wird es nicht möglich sein geänderte\n\ - Daten oder seinen Zustand zu speichern.\n\ - Sind Sie sicher, dass Sie inh beenden möchten?" - IDS_TERMINATE_UNABLE2TERMINATE "Der Prozess konnte nicht beendet werden" - IDS_DEBUG_MESSAGE "WARNUNG: Den Prozess zu debuggen kann zu Datenverlust\n\ - führen. Sind Sie sicher, dass Sie ihn debuggen möchten?" - IDS_DEBUG_UNABLE2DEBUG "Konnte den Prozess nicht debuggen" - IDS_AFFINITY_ERROR_MESSAGE "Der Prozess muss mindestens mit einem Prozessor affin sein" - IDS_AFFINITY_ERROR_TITLE "Option nicht möglich" - IDS_AFFINITY_UNABLE2ACCESS "Die Prozessoraffinität konnte nicht geändert werden" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_SYSTEM_IDLE_PROCESS "Leerlauf Prozess" - IDS_APPLICATION_NOT_RESPONDING "Anwortet nicht" - IDS_APPLICATION_RUNNING "läuft" - IDS_APPLICATION_TASK "Task" - IDS_APPLICATION_STATUS "Status" - IDS_DEBUG_CHANNEL "Debug Kanäle" - IDS_DEBUG_CHANNEL_FIXME "Fixme" - IDS_DEBUG_CHANNEL_ERR "Err" - IDS_DEBUG_CHANNEL_WARN "Warn" - IDS_DEBUG_CHANNEL_TRACE "Trace" + ID_PROCESS_PAGE_SETAFFINITY "Kontrolliert, auf welchen Prozessoren ein Prozess ausgeführt werden darf" + ID_PROCESS_PAGE_SETPRIORITY_REALTIME "Setzt den Prozess in die ECHTZEIT-Prioritätsklasse" + ID_PROCESS_PAGE_SETPRIORITY_HIGH "Setzt den Prozess in die HOCH-Prioritätsklasse" + ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL "Setzt den Prozess in die HÖHER ALS NORMAL-Prioritätsklasse" + ID_PROCESS_PAGE_SETPRIORITY_NORMAL "Setzt den Prozess in die NORMAL-Prioritätsklasse" + ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL "Setzt den Prozess in die NIEDRIGER ALS NORMAL-Prioritätsklasse" + ID_PROCESS_PAGE_SETPRIORITY_LOW "Setzt den Prozess in die NIEDRIG-Prioritätsklasse" END diff --git a/programs/taskmgr/En.rc b/programs/taskmgr/En.rc index 45aa9258b21..8694588cf79 100644 --- a/programs/taskmgr/En.rc +++ b/programs/taskmgr/En.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT /* @@ -485,90 +483,4 @@ BEGIN ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL "Sets process to the BELOW NORMAL priority class" ID_PROCESS_PAGE_SETPRIORITY_LOW "Sets process to the LOW priority class" - ID_PROCESS_PAGE_DEBUGCHANNELS - "Controls Debug Channels" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_VIEW_LARGE "Lar&ge Icons" - IDS_VIEW_SMALL "S&mall Icons" - IDS_VIEW_DETAILS "&Details" - IDS_WINDOWS "&Windows" - IDS_VIEW_SELECTCOLUMNS "&Select Columns..." - IDS_OPTIONS_SHOW16BITTASKS "&Show 16-bit tasks" - IDS_VIEW_CPUHISTORY "&CPU History" - IDS_VIEW_CPUHISTORY_ONEGRAPHALL "&One Graph, All CPUs" - IDS_VIEW_CPUHISTORY_ONEGRAPHPERCPU "One Graph &Per CPU" - IDS_VIEW_SHOWKERNELTIMES "&Show Kernel Times" - IDS_APPLICATIONS "Applications" - IDS_PROCESSES "Processes" - IDS_PERFORMANCE "Performance" - IDS_STATUS_BAR_CPU_USAGE "CPU Usage: %3d%%" - IDS_STATUS_BAR_PROCESSES "Processes: %d" - IDS_STATUS_BAR_MEMORY_USAGE "Mem Usage: %dK / %dK" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_IMAGENAME "Image Name" - IDS_PID "PID" - IDS_CPUUSAGE "CPU" - IDS_CPUTIME "CPU Time" - IDS_MEMORYUSAGE "Mem Usage" - IDS_MEMORYUSAGEDELTA "Mem Delta" - IDS_PEAKMEMORYUSAGE "Peak Mem Usage" - IDS_PAGEFAULTS "Page Faults" - IDS_USEROBJECTS "USER Objects" - IDS_IOREADS "I/O Reads" - IDS_IOREADBYTES "I/O Read Bytes" - IDS_SESSIONID "Session ID" - IDS_USERNAME "Username" - IDS_PAGEFAULTSDELTA "PF Delta" - IDS_VIRTUALMEMORYSIZE "VM Size" - IDS_PAGEDPOOL "Paged Pool" - IDS_NONPAGEDPOOL "NP Pool" - IDS_BASEPRIORITY "Base Pri" - IDS_HANDLECOUNT "Handles" - IDS_THREADCOUNT "Threads" - IDS_GDIOBJECTS "GDI Objects" - IDS_IOWRITES "I/O Writes" - IDS_IOWRITEBYTES "I/O Write Bytes" - IDS_IOOTHER "I/O Other" - IDS_IOOTHERBYTES "I/O Other Bytes" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_WARNING_TITLE "Task Manager Warning" - IDS_PRIORITY_CHANGE_MESSAGE "WARNING: Changing the priority class of this process may\n\ - cause undesired results including system instability. Are you\n\ - sure you want to change the priority class?" - IDS_PRIORITY_UNABLE2CHANGE "Unable to Change Priority" - IDS_TERMINATE_MESSAGE "WARNING: Terminating a process can cause undesired\n\ - results including loss of data and system instability. The\n\ - process will not be given the chance to save its state or\n\ - data before it is terminated. Are you sure you want to\n\ - terminate the process?" - IDS_TERMINATE_UNABLE2TERMINATE "Unable to Terminate Process" - IDS_DEBUG_MESSAGE "WARNING: Debugging this process may result in loss of data.\n\ - Are you sure you wish to attach the debugger?" - IDS_DEBUG_UNABLE2DEBUG "Unable to Debug Process" - IDS_AFFINITY_ERROR_MESSAGE "The process must have affinity with at least one processor" - IDS_AFFINITY_ERROR_TITLE "Invalid Option" - IDS_AFFINITY_UNABLE2ACCESS "Unable to Access or Set Process Affinity" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_SYSTEM_IDLE_PROCESS "System Idle Process" - IDS_APPLICATION_NOT_RESPONDING "Not Responding" - IDS_APPLICATION_RUNNING "Running" - IDS_APPLICATION_TASK "Task" - IDS_APPLICATION_STATUS "Status" - IDS_DEBUG_CHANNEL "Debug Channels" - IDS_DEBUG_CHANNEL_FIXME "Fixme" - IDS_DEBUG_CHANNEL_ERR "Err" - IDS_DEBUG_CHANNEL_WARN "Warn" - IDS_DEBUG_CHANNEL_TRACE "Trace" END diff --git a/programs/taskmgr/Fr.rc b/programs/taskmgr/Fr.rc index 0c1e2d22321..d1c348808d4 100644 --- a/programs/taskmgr/Fr.rc +++ b/programs/taskmgr/Fr.rc @@ -3,7 +3,6 @@ * French Language Support * * Copyright 2005-2006 Jonathan Ernst - * Copyright 2009 Frédéric Delanoy * * * This library is free software; you can redistribute it and/or @@ -21,11 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL /* @@ -36,25 +30,25 @@ IDR_TASKMANAGER MENU DISCARDABLE BEGIN POPUP "&Fichier" BEGIN - MENUITEM "&Nouvelle tâche (Exécuter...)", ID_FILE_NEW + MENUITEM "&Nouvelle tâche (Exécuter...)", ID_FILE_NEW MENUITEM SEPARATOR - MENUITEM "&Quitter le gestionnaire des tâches", ID_FILE_EXIT + MENUITEM "&Quitter le gestionnaire des tâches", ID_FILE_EXIT END POPUP "&Options" BEGIN - MENUITEM "Toujours &visible", ID_OPTIONS_ALWAYSONTOP + MENUITEM "&Always On Top", ID_OPTIONS_ALWAYSONTOP , CHECKED - MENUITEM "Réd&uire à l'exécution", ID_OPTIONS_MINIMIZEONUSE + MENUITEM "Réd&uire à l'exécution", ID_OPTIONS_MINIMIZEONUSE , CHECKED - MENUITEM "&Masquer l'icône réduite", ID_OPTIONS_HIDEWHENMINIMIZED + MENUITEM "&Masquer l'icône réduite", ID_OPTIONS_HIDEWHENMINIMIZED , CHECKED - MENUITEM "&Montrer les tâches 16 bits", ID_OPTIONS_SHOW16BITTASKS + MENUITEM "&Montrer les tâches 16-bit", ID_OPTIONS_SHOW16BITTASKS , CHECKED END POPUP "&Affichage" BEGIN MENUITEM "&Actualiser maintenant", ID_VIEW_REFRESH - POPUP "&Fréquence d'actualisation" + POPUP "&Fréquence d'actualisation" BEGIN MENUITEM "&Haute", ID_VIEW_UPDATESPEED_HIGH MENUITEM "&Normale", ID_VIEW_UPDATESPEED_NORMAL @@ -64,10 +58,10 @@ BEGIN END MENUITEM SEPARATOR - MENUITEM "G&randes icônes", ID_VIEW_LARGE - MENUITEM "P&etites icônes", ID_VIEW_SMALL - MENUITEM "&Détails", ID_VIEW_DETAILS, CHECKED - MENUITEM "&Sélectionner les colonnes...", ID_VIEW_SELECTCOLUMNS + MENUITEM "G&randes Icônes", ID_VIEW_LARGE + MENUITEM "P&etites Icônes", ID_VIEW_SMALL + MENUITEM "&Détails", ID_VIEW_DETAILS, CHECKED + MENUITEM "&Sélectionner les colonnes...", ID_VIEW_SELECTCOLUMNS POPUP "&Historique du processeur" BEGIN MENUITEM "Un seul graphique pour &tous les processeurs", ID_VIEW_CPUHISTORY_ONEGRAPHALL @@ -75,30 +69,30 @@ BEGIN MENUITEM "Un graphique &par processeur", ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU , CHECKED END - MENUITEM "Aff&icher les temps noyau", ID_VIEW_SHOWKERNELTIMES + MENUITEM "Aff&icher les temps du noyau", ID_VIEW_SHOWKERNELTIMES END - POPUP "Fe&nêtres" + POPUP "&Fenêtres" BEGIN - MENUITEM "Arranger &Horizontalement", ID_WINDOWS_TILEHORIZONTALLY - MENUITEM "Arranger &Verticalement", ID_WINDOWS_TILEVERTICALLY - MENUITEM "&Réduire", ID_WINDOWS_MINIMIZE + MENUITEM "Arranger &Horizontallement", ID_WINDOWS_TILEHORIZONTALLY + MENUITEM "Arranger &Verticallement", ID_WINDOWS_TILEVERTICALLY + MENUITEM "&Réduire", ID_WINDOWS_MINIMIZE MENUITEM "&Agrandir", ID_WINDOWS_MAXIMIZE MENUITEM "&Cascade", ID_WINDOWS_CASCADE MENUITEM "Toujours &visible", ID_WINDOWS_BRINGTOFRONT END POPUP "Aid&e" BEGIN - MENUITEM "Rubriques d'aide du Gestionnaire des tâches", ID_HELP_TOPICS + MENUITEM "Rubriques d'aide du Gestionnaire des tâches", ID_HELP_TOPICS MENUITEM SEPARATOR - MENUITEM "À &propos du Gestionnaire des tâches", ID_HELP_ABOUT + MENUITEM "À &propos du Gestionnaire des tâches", ID_HELP_ABOUT END END IDR_WINDOWSMENU MENU DISCARDABLE BEGIN - MENUITEM "Arranger &Horizontalement", ID_WINDOWS_TILEHORIZONTALLY - MENUITEM "Arranger &Verticalement", ID_WINDOWS_TILEVERTICALLY - MENUITEM "&Réduire", ID_WINDOWS_MINIMIZE + MENUITEM "Arranger &Horizontallement", ID_WINDOWS_TILEHORIZONTALLY + MENUITEM "Arranger &Verticallement", ID_WINDOWS_TILEVERTICALLY + MENUITEM "&Réduire", ID_WINDOWS_MINIMIZE MENUITEM "&Agrandir", ID_WINDOWS_MAXIMIZE MENUITEM "&Cascade", ID_WINDOWS_CASCADE MENUITEM "Toujours &visible", ID_WINDOWS_BRINGTOFRONT @@ -108,11 +102,11 @@ IDR_APPLICATION_PAGE_CONTEXT1 MENU DISCARDABLE BEGIN POPUP "DUMMY" BEGIN - MENUITEM "&Nouvelle Tâche (Exécuter...)", ID_FILE_NEW + MENUITEM "&Nouvelle Tâche (Exécuter...)", ID_FILE_NEW MENUITEM SEPARATOR - MENUITEM "G&randes Icônes", ID_VIEW_LARGE - MENUITEM "P&etites Icônes", ID_VIEW_SMALL - MENUITEM "&Détails", ID_VIEW_DETAILS, CHECKED + MENUITEM "G&randes Icônes", ID_VIEW_LARGE + MENUITEM "P&etites Icônes", ID_VIEW_SMALL + MENUITEM "&Détails", ID_VIEW_DETAILS, CHECKED END END @@ -123,14 +117,14 @@ BEGIN MENUITEM "&Basculer vers", ID_APPLICATION_PAGE_SWITCHTO MENUITEM "Toujours &visible", ID_WINDOWS_BRINGTOFRONT MENUITEM SEPARATOR - MENUITEM "Arranger &Horizontalement", ID_WINDOWS_TILEHORIZONTALLY - MENUITEM "Arranger &Verticalement", ID_WINDOWS_TILEVERTICALLY - MENUITEM "&Réduire", ID_WINDOWS_MINIMIZE + MENUITEM "Arranger &Horizontallement", ID_WINDOWS_TILEHORIZONTALLY + MENUITEM "Arranger &Verticallement", ID_WINDOWS_TILEVERTICALLY + MENUITEM "&Réduire", ID_WINDOWS_MINIMIZE MENUITEM "&Agrandir", ID_WINDOWS_MAXIMIZE MENUITEM "&Cascade", ID_WINDOWS_CASCADE MENUITEM SEPARATOR - MENUITEM "F&in de tâche", ID_APPLICATION_PAGE_ENDTASK - MENUITEM "&Suivre le processus", ID_APPLICATION_PAGE_GOTOPROCESS + MENUITEM "F&in de tâche", ID_APPLICATION_PAGE_ENDTASK + MENUITEM "&Basculer vers", ID_APPLICATION_PAGE_GOTOPROCESS END END @@ -152,25 +146,25 @@ BEGIN MENUITEM "&Terminer le processus", ID_PROCESS_PAGE_ENDPROCESS MENUITEM "Terminer l'&arborescence du processus", ID_PROCESS_PAGE_ENDPROCESSTREE - MENUITEM "&Déboguer", ID_PROCESS_PAGE_DEBUG + MENUITEM "&Déboguer", ID_PROCESS_PAGE_DEBUG MENUITEM SEPARATOR - POPUP "Définir la &priorité" + POPUP "Définir la &priorité" BEGIN - MENUITEM "Temps &réel", ID_PROCESS_PAGE_SETPRIORITY_REALTIME + MENUITEM "Temps &réel", ID_PROCESS_PAGE_SETPRIORITY_REALTIME MENUITEM "&Haute", ID_PROCESS_PAGE_SETPRIORITY_HIGH - MENUITEM "&Supérieure à la normale", ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL + MENUITEM "&Supérieure à la normale", ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL MENUITEM "&Normale", ID_PROCESS_PAGE_SETPRIORITY_NORMAL - MENUITEM "&Inférieure à la normale", ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL + MENUITEM "&Inférieure à la normale", ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL MENUITEM "&Basse", ID_PROCESS_PAGE_SETPRIORITY_LOW END - MENUITEM "Définir l'&affinité...", ID_PROCESS_PAGE_SETAFFINITY - MENUITEM "Modifier les &canaux de débogage...", ID_PROCESS_PAGE_DEBUGCHANNELS + MENUITEM "Définir l'&affinité...", ID_PROCESS_PAGE_SETAFFINITY + MENUITEM "Modifier les &canaux de débogage...", ID_PROCESS_PAGE_DEBUGCHANNELS END END @@ -182,7 +176,7 @@ IDD_TASKMGR_DIALOG DIALOG DISCARDABLE 0, 0, 264, 246 STYLE DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU | WS_THICKFRAME -CAPTION "Gestionnaire des tâches" +CAPTION "Gestionnaire des tâches" MENU IDR_TASKMANAGER FONT 8, "MS Shell Dlg" BEGIN @@ -195,9 +189,9 @@ FONT 8, "MS Shell Dlg" BEGIN CONTROL "List2",IDC_APPLIST,"SysListView32",LVS_REPORT | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,233,177 - PUSHBUTTON "&Nouvelle tâche",IDC_NEWTASK,187,189,55,14 - PUSHBUTTON "&Basculer vers",IDC_SWITCHTO,129,189,55,14,WS_DISABLED - PUSHBUTTON "&Fin de tâche",IDC_ENDTASK,71,189,55,14,WS_DISABLED + PUSHBUTTON "&Nouvelle tâche...",IDC_NEWTASK,187,189,53,14 + PUSHBUTTON "&Basculer vers",IDC_SWITCHTO,131,189,53,14,WS_DISABLED + PUSHBUTTON "&Fin de tâche",IDC_ENDTASK,75,189,53,14,WS_DISABLED END IDD_PROCESS_PAGE DIALOG DISCARDABLE 0, 0, 247, 210 @@ -207,9 +201,9 @@ BEGIN CONTROL "List2",IDC_PROCESSLIST,"SysListView32",LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_OWNERDATA | WS_BORDER | WS_TABSTOP,7,7,233,177 - PUSHBUTTON "&Terminer le processus",IDC_ENDPROCESS,161,189,79,14 - CONTROL "Afficher les processus de &tous les utilisateurs",IDC_SHOWALLPROCESSES, - "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,191,161,10 + PUSHBUTTON "&Terminer le processus",IDC_ENDPROCESS,171,189,69,14 + CONTROL "&Afficher les processus de tous les utilisateurs",IDC_SHOWALLPROCESSES, + "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,191,111,10 END /*IDD_PERFORMANCE_PAGE DIALOGEX 0, 0, 247, 210*/ @@ -217,12 +211,12 @@ IDD_PERFORMANCE_PAGE DIALOGEX DISCARDABLE 0, 0, 247, 210 STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX "Util. processeur",IDC_CPU_USAGE_FRAME,5,5,60,54,WS_TABSTOP, WS_EX_TRANSPARENT - GROUPBOX "Util. mémoire",IDC_MEM_USAGE_FRAME,5,63,60,54,BS_LEFTTEXT, WS_EX_TRANSPARENT + GROUPBOX "Utilisation du processeur",IDC_CPU_USAGE_FRAME,5,5,60,54,WS_TABSTOP, WS_EX_TRANSPARENT + GROUPBOX "Utilisation de la mémoire",IDC_MEM_USAGE_FRAME,5,63,60,54,BS_LEFTTEXT, WS_EX_TRANSPARENT GROUPBOX "Totaux",IDC_TOTALS_FRAME,5,122,111,39,0,WS_EX_TRANSPARENT - GROUPBOX "Charge dédiée (Kio)",IDC_COMMIT_CHARGE_FRAME,5,166,111,39,0,WS_EX_TRANSPARENT - GROUPBOX "Mémoire physique (Kio)",IDC_PHYSICAL_MEMORY_FRAME,131,122,111,39,0,WS_EX_TRANSPARENT - GROUPBOX "Mémoire pour le noyau (Kio)",IDC_KERNEL_MEMORY_FRAME,131,166,111,39,0,WS_EX_TRANSPARENT + GROUPBOX "Charge dédiée (Kio)",IDC_COMMIT_CHARGE_FRAME,5,166,111,39,0,WS_EX_TRANSPARENT + GROUPBOX "Mémoire physique (Kio)",IDC_PHYSICAL_MEMORY_FRAME,131,122,111,39,0,WS_EX_TRANSPARENT + GROUPBOX "Mémoire pour le noyau (Kio)",IDC_KERNEL_MEMORY_FRAME,131,166,111,39,0,WS_EX_TRANSPARENT LTEXT "Handles",IDS_TOTALS_HANDLE_COUNT,12,131,27,8 LTEXT "Threads",IDS_TOTALS_THREAD_COUNT,12,140,27,8 LTEXT "Processus",IDS_TOTALS_PROCESS_COUNT,12,149,34,8 @@ -232,8 +226,8 @@ BEGIN ES_READONLY | ES_NUMBER | NOT WS_BORDER EDITTEXT IDC_TOTALS_PROCESS_COUNT,65,149,45,8,ES_RIGHT | ES_READONLY | ES_NUMBER | NOT WS_BORDER - LTEXT "Total",IDS_COMMIT_CHARGE_TOTAL,12,175,34,8 - LTEXT "Limite",IDS_COMMIT_CHARGE_LIMIT,12,184,34,8 + LTEXT "Total",IDS_COMMIT_CHARGE_TOTAL,12,175,27,8 + LTEXT "Limite",IDS_COMMIT_CHARGE_LIMIT,12,184,15,8 LTEXT "Pic",IDS_COMMIT_CHARGE_PEAK,12,193,34,8 EDITTEXT IDC_COMMIT_CHARGE_TOTAL,65,174,45,8,ES_RIGHT | ES_READONLY | ES_NUMBER | NOT WS_BORDER @@ -241,18 +235,18 @@ BEGIN ES_READONLY | ES_NUMBER | NOT WS_BORDER EDITTEXT IDC_COMMIT_CHARGE_PEAK,65,193,45,8,ES_RIGHT | ES_READONLY | ES_NUMBER | NOT WS_BORDER - LTEXT "Total",IDS_PHYSICAL_MEMORY_TOTAL,137,131,50,8 - LTEXT "Disponible",IDS_PHYSICAL_MEMORY_AVAILABLE,137,140,50,8 - LTEXT "Cache système",IDS_PHYSICAL_MEMORY_SYSTEM_CACHE,137,149,50,8 + LTEXT "Total",IDS_PHYSICAL_MEMORY_TOTAL,137,131,27,8 + LTEXT "Disponible",IDS_PHYSICAL_MEMORY_AVAILABLE,137,140,30,8 + LTEXT "Cache système",IDS_PHYSICAL_MEMORY_SYSTEM_CACHE,137,149,46,8 EDITTEXT IDC_PHYSICAL_MEMORY_TOTAL,185,131,48,8,ES_RIGHT | ES_READONLY | ES_NUMBER | NOT WS_BORDER EDITTEXT IDC_PHYSICAL_MEMORY_AVAILABLE,185,140,48,8,ES_RIGHT | ES_READONLY | ES_NUMBER | NOT WS_BORDER EDITTEXT IDC_PHYSICAL_MEMORY_SYSTEM_CACHE,185,149,48,8,ES_RIGHT | ES_READONLY | ES_NUMBER | NOT WS_BORDER - LTEXT "Total",IDS_KERNEL_MEMORY_TOTAL,137,174,44,8 - LTEXT "Paginée",IDS_KERNEL_MEMORY_PAGED,137,184,44,8 - LTEXT "Non paginée",IDS_KERNEL_MEMORY_NONPAGED,137,193,34,8 + LTEXT "Total",IDS_KERNEL_MEMORY_TOTAL,137,174,27,8 + LTEXT "Paginée",IDS_KERNEL_MEMORY_PAGED,137,184,21,8 + LTEXT "Non paginée",IDS_KERNEL_MEMORY_NONPAGED,137,193,34,8 EDITTEXT IDC_KERNEL_MEMORY_TOTAL,185,174,48,8,ES_RIGHT | ES_READONLY | ES_NUMBER | NOT WS_BORDER EDITTEXT IDC_KERNEL_MEMORY_PAGED,185,184,48,8,ES_RIGHT | @@ -260,20 +254,20 @@ BEGIN EDITTEXT IDC_KERNEL_MEMORY_NONPAGED,185,193,48,8,ES_RIGHT | ES_READONLY | ES_NUMBER | NOT WS_BORDER GROUPBOX "Historique de l'utilisation du processeur",IDC_CPU_USAGE_HISTORY_FRAME,74,5,168,54,0,WS_EX_TRANSPARENT - GROUPBOX "Historique de l'utilisation de la mémoire",IDC_MEMORY_USAGE_HISTORY_FRAME,74,63,168,54,0,WS_EX_TRANSPARENT + GROUPBOX "Historique de l'utilisation de la mémoire",IDC_MEMORY_USAGE_HISTORY_FRAME,74,63,168,54,0,WS_EX_TRANSPARENT PUSHBUTTON "Affichage de l'utilisation du processeur",IDC_CPU_USAGE_GRAPH,12,17,47,37,0, WS_EX_CLIENTEDGE - PUSHBUTTON "Affichage de l'utilisation de la mémoire",IDC_MEM_USAGE_GRAPH,12,75,47,37,0, + PUSHBUTTON "Affichage de l'utilisation de la mémoire",IDC_MEM_USAGE_GRAPH,12,75,47,37,0, WS_EX_CLIENTEDGE PUSHBUTTON "Historique de l'utilisation du processeur",IDC_CPU_USAGE_HISTORY_GRAPH,81,17, 153,37,0,WS_EX_CLIENTEDGE - PUSHBUTTON "Historique de l'utilisation de la mémoire",IDC_MEM_USAGE_HISTORY_GRAPH,81,75, + PUSHBUTTON "Historique de l'utilisation de la mémoire",IDC_MEM_USAGE_HISTORY_GRAPH,81,75, 153,37,0,WS_EX_CLIENTEDGE END IDD_DEBUG_CHANNELS_DIALOG DIALOG DISCARDABLE 0, 0, 247, 210 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Canaux de débogage" +CAPTION "Canaux de débogage" FONT 8, "MS Shell Dlg" BEGIN CONTROL "List2",IDC_DEBUG_CHANNELS_LIST,"SysListView32",LVS_REPORT | @@ -284,12 +278,12 @@ END IDD_AFFINITY_DIALOG DIALOG DISCARDABLE 0, 0, 231, 154 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Affinité du processeur" +CAPTION "Processor Affinity" FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "OK",IDOK,120,133,50,14 PUSHBUTTON "Annuler",IDCANCEL,174,133,50,14 - LTEXT "Le paramètre « affinité du processeur » détermine sur quels processeurs le processus pourra s'exécuter.", + LTEXT "Le paramètre « affinité du processeur » contrôle sur quels processeurs le processus sera autorisé à s'exécuter.", IDC_STATIC,5,5,220,16 CONTROL "CPU 0",IDC_CPU0,"Button",BS_AUTOCHECKBOX | WS_TABSTOP, 11,28,37,10 @@ -357,65 +351,65 @@ BEGIN WS_DISABLED | WS_TABSTOP,175,119,41,10 END -IDD_COLUMNS_DIALOG DIALOG DISCARDABLE 0, 0, 218, 199 +IDD_COLUMNS_DIALOG DIALOG DISCARDABLE 0, 0, 195, 199 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Sélection des colonnes" +CAPTION "Select Columns" FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "OK",IDOK,84,178,50,14 PUSHBUTTON "Annuler",IDCANCEL,138,178,50,14 - LTEXT "Sélectionnez les colonnes qui apparaîtront dans la page Processus du Gestionnaire des tâches.", + LTEXT "Sélectionnez les colonnes qui apparaîtront dans la page Processus du Gestionnaire des tâches.", IDC_STATIC,7,7,181,17 CONTROL "Nom de l'&image",IDC_IMAGENAME,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,7,28,66,10 - CONTROL "&PID (ident. de processus)",IDC_PID,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,7,39,94,10 + WS_DISABLED | WS_TABSTOP,7,28,56,10 + CONTROL "&PID (Process Identifier)",IDC_PID,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,7,39,88,10 CONTROL "Uti&lisation du processeur",IDC_CPUUSAGE,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,50,93,10 - CONTROL "T&emps processeur",IDC_CPUTIME,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,61,70,10 - CONTROL "Utilisation &mémoire",IDC_MEMORYUSAGE,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,72,73,10 - CONTROL "Écart &d'utilisation mémoire",IDC_MEMORYUSAGEDELTA,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,7,83,95,10 - CONTROL "Ma&x. utilisation mémoire",IDC_PEAKMEMORYUSAGE,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,7,94,98,10 - CONTROL "Défauts de pa&ges",IDC_PAGEFAULTS,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,105,73,10 + WS_TABSTOP,7,50,53,10 + CONTROL "T&emps CPU",IDC_CPUTIME,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,7,61,48,10 + CONTROL "Utilisation de la &mémoire",IDC_MEMORYUSAGE,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,7,72,63,10 + CONTROL "Écart &d'utilisation de la mémoire",IDC_MEMORYUSAGEDELTA,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,7,83,82,10 + CONTROL "Utilisation ma&ximale de la mémoire",IDC_PEAKMEMORYUSAGE,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,7,94,82,10 + CONTROL "Erreur&s de page",IDC_PAGEFAULTS,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,7,105,53,10 CONTROL "Objets &USER",IDC_USEROBJECTS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,116,62,10 CONTROL "Lectures E/S",IDC_IOREADS,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,127,59,10 + WS_TABSTOP,7,127,49,10 CONTROL "Octets de lecture E/S",IDC_IOREADBYTES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,7,138,80,10 + BS_AUTOCHECKBOX | WS_TABSTOP,7,138,65,10 CONTROL "Identi&ficateur de session",IDC_SESSIONID,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,149,91,10 + WS_TABSTOP,7,149,50,10 CONTROL "&Nom de l'utilisateur",IDC_USERNAME,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,160,81,10 - CONTROL "É&cart de défauts de pages",IDC_PAGEFAULTSDELTA,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,107,28,106,10 - CONTROL "Taille de la mémoire &virtuelle",IDC_VIRTUALMEMORYSIZE,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,107,39,102,10 - CONTROL "Réserve pa&ginée",IDC_PAGEDPOOL,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,107,50,73,10 - CONTROL "Réserve n&on paginée",IDC_NONPAGEDPOOL,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,107,61,80,10 - CONTROL "P&riorité de base",IDC_BASEPRIORITY,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,107,72,65,10 + WS_TABSTOP,7,160,51,10 + CONTROL "É&cart d'erreurs de pagination",IDC_PAGEFAULTSDELTA,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,107,28,72,10 + CONTROL "Taille de la mémoire &virtuelle",IDC_VIRTUALMEMORYSIZE,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,107,39,77,10 + CONTROL "Réserve pa&ginée",IDC_PAGEDPOOL,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,107,50,53,10 + CONTROL "Réserve n&on paginée",IDC_NONPAGEDPOOL,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,107,61,67,10 + CONTROL "P&riorité de base",IDC_BASEPRIORITY,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,107,72,55,10 CONTROL "Nombre de &handles",IDC_HANDLECOUNT,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,107,83,79,10 + WS_TABSTOP,107,83,59,10 CONTROL "Nombre de &threads",IDC_THREADCOUNT,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,107,94,79,10 + WS_TABSTOP,107,94,59,10 CONTROL "Ob&jets GDI",IDC_GDIOBJECTS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,107,105,55,10 - CONTROL "Écritures E/S",IDC_IOWRITES,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,107,116,59,10 - CONTROL "Octets d'écriture E/S",IDC_IOWRITEBYTES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,107,127,80,10 + CONTROL "Ecritures E/S",IDC_IOWRITES,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,107,116,49,10 + CONTROL "Octets d'écriture E/S",IDC_IOWRITEBYTES,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,107,127,65,10 CONTROL "Autres E/S",IDC_IOOTHER,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,107,138,46,10 CONTROL "Octets d'autres E/S",IDC_IOOTHERBYTES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,107,149,75,10 + BS_AUTOCHECKBOX | WS_TABSTOP,107,149,65,10 END /* @@ -424,22 +418,22 @@ END STRINGTABLE DISCARDABLE BEGIN - IDS_APP_TITLE "Gestionnaire des tâches" - IDC_TASKMGR "Gestionnaire des tâches" - IDS_RUNDLG_CAPTION "Nouvelle tâche..." + IDS_APP_TITLE "Gestionnaire des tâches" + IDC_TASKMGR "Gestionnaire des tâches" + IDS_RUNDLG_CAPTION "Create New Task" END STRINGTABLE DISCARDABLE BEGIN - ID_FILE_NEW "Exécute un nouveau programme" - ID_OPTIONS_ALWAYSONTOP "Le gestionnaire des tâches reste devant toutes les autres fenêtres sauf s'il est réduit" + ID_FILE_NEW "Exécute un nouveau programme" + ID_OPTIONS_ALWAYSONTOP "Le gestionnaire des tâches reste au premier plan de toutes les autres fenêtres sauf s'il est réduit" ID_OPTIONS_MINIMIZEONUSE - "Le gestionnaire des tâches est minimisé quand une opération « Basculer vers » est effectuée" - ID_OPTIONS_HIDEWHENMINIMIZED "Cache le gestionnaire des tâches lorsqu'il est réduit" - ID_VIEW_REFRESH "Force le gestionnaire des tâches à s'actualiser maintenant sans tenir compte du paramètre de fréquence d'actualisation" - ID_VIEW_LARGE "Affiche les tâches en utilisant de grandes icônes" - ID_VIEW_SMALL "Affiche les tâches en utilisant de petites icônes" - ID_VIEW_DETAILS "Affiche des informations sur chacune des tâches" + "Le gestionnaire des tâches est minimisé quand une opération Basculer vers est effectuée" + ID_OPTIONS_HIDEWHENMINIMIZED "Cache le gestionnaire des tâches lorsqu'il est réduit" + ID_VIEW_REFRESH "Force le gestionnaire des tâches à s'actualiser maintenant sans tenir compte du paramètre de fréquence d'actualisation" + ID_VIEW_LARGE "Affiche les tâches en utilisant de grandes icônes" + ID_VIEW_SMALL "Affiche les tâches en utilisant de petites icônes" + ID_VIEW_DETAILS "Affiche des informations sur chacune des tâches" ID_VIEW_UPDATESPEED_HIGH "Actualise l'affichage deux fois par seconde" ID_VIEW_UPDATESPEED_NORMAL "Actualise l'affichage toutes les deux secondes" ID_VIEW_UPDATESPEED_LOW "Actualise l'affichage toutes les quatre secondes" @@ -449,131 +443,45 @@ STRINGTABLE DISCARDABLE BEGIN ID_VIEW_UPDATESPEED_PAUSED "N'actualise pas l'affichage automatiquement" ID_WINDOWS_TILEHORIZONTALLY - "Arrange les fenêtres horizontalement sur le bureau" - ID_WINDOWS_TILEVERTICALLY "Arrange les fenêtres verticalement sur le bureau" - ID_WINDOWS_MINIMIZE "Réduit les fenêtres" - ID_WINDOWS_MAXIMIZE "Agrandit les fenêtres" - ID_WINDOWS_CASCADE "Place les fenêtres en cascade sur le bureau" - ID_WINDOWS_BRINGTOFRONT "Amène la fenêtre au premier plan, mais ne bascule pas vers celle-ci" - ID_HELP_TOPICS "Affiche les rubriques d'aide du gestionnaire des tâches" + "Arrange les fenêtres horizontalement sur le bureau" + ID_WINDOWS_TILEVERTICALLY "Arrange les fenêtres verticalement sur le bureau" + ID_WINDOWS_MINIMIZE "Réduit les fenêtres" + ID_WINDOWS_MAXIMIZE "Agrandit les fenêtres" + ID_WINDOWS_CASCADE "Place les fenêtres en cascade sur le bureau" + ID_WINDOWS_BRINGTOFRONT "Affiche la fenêtre au premier plan, mais ne bascule pas vers celle-ci" + ID_HELP_TOPICS "Affiche les rubriques d'aide du gestionnaire des tâches" ID_HELP_ABOUT "Affiche le informations sur le programme, la version et le copyright" - ID_FILE_EXIT "Quitte le gestionnaire des tâches" + ID_FILE_EXIT "Quitte le gestionnaire des tâches" ID_OPTIONS_SHOW16BITTASKS - "Affiche les tâches 16 bits sous le ntvdm.exe associé" - ID_VIEW_SELECTCOLUMNS "Sélectionne les colonnes à afficher dans la page des processus" - ID_VIEW_SHOWKERNELTIMES "Affiche le temps noyau dans les graphiques de performance" + "Affiche les tâches 16-bit sous le ntvdm.exe associé" + ID_VIEW_SELECTCOLUMNS "Sélectionne quelles colonnes seront affichées dans la page des processus" + ID_VIEW_SHOWKERNELTIMES "Affiche le temps noyau dans les graphiques de performances" ID_VIEW_CPUHISTORY_ONEGRAPHALL - "L'utilisation des processeurs est affichée sur un seul graphique" - ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU "Chaque processeur a son propre graphique" + "L'utilisation des processeurs est affichée sur un seul graphique" + ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU "Chaque processeur à son propre graphique" ID_APPLICATION_PAGE_SWITCHTO - "Amène la tâche à l'avant-plan et bascule vers celle-ci" + "Amène la tâche au premier plan et bascule vers celle-ci" END STRINGTABLE DISCARDABLE BEGIN - ID_ENDTASK "Demande aux tâches sélectionnées de se terminer" - ID_GOTOPROCESS "Bascule vers le processus de la tâche sélectionnée" - ID_RESTORE "Restaure le gestionnaire des tâches" - ID_PROCESS_PAGE_ENDPROCESS "Retire le processus du système" + ID_ENDTASK "Demande à la tâche sélectionner de se terminer" + ID_GOTOPROCESS "Bascule vers le processus de la tâche sélectionnée" + ID_RESTORE "Restaure le gestionnaire des tâches" + ID_PROCESS_PAGE_ENDPROCESS "Retire le processus du système" ID_PROCESS_PAGE_ENDPROCESSTREE - "Retire ce processus et tous ses fils du système" - ID_PROCESS_PAGE_DEBUG "Attache le débogueur à ce processus" + "Retire ce processus et tous ces fils du système" + ID_PROCESS_PAGE_DEBUG "Attache le débuggeur à ce processus" ID_PROCESS_PAGE_SETAFFINITY - "Détermine sur quels processeurs le processus sera autorisé à s'exécuter" + "Contrôle sur quel processeur le processus sera autorisé à s'exécuter" ID_PROCESS_PAGE_SETPRIORITY_REALTIME - "Place le processus dans la classe de priorité TEMPS RÉEL" - ID_PROCESS_PAGE_SETPRIORITY_HIGH "Place le processus dans la classe de priorité HAUTE" + "Place le processus dans la classe de priorité TEMPS RÉEL" + ID_PROCESS_PAGE_SETPRIORITY_HIGH "Place le processus dans la classe de priorité HAUTE" ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL - "Place le processus dans la classe de priorité SUPÉRIEURE À LA NORMALE" + "Place le processus dans la classe de priorité SUPÉRIEURE À LA NORMALE" ID_PROCESS_PAGE_SETPRIORITY_NORMAL - "Place le processus dans la classe de priorité NORMALE" + "Place le processus dans la classe de priorité NORMALE" ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL - "Place le processus dans la classe de priorité INFÉRIEURE À LA NORMALE" - ID_PROCESS_PAGE_SETPRIORITY_LOW "Place le processus dans la classe de priorité BASSE" - ID_PROCESS_PAGE_DEBUGCHANNELS - "Contrôle les canaux de débogage" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_VIEW_LARGE "G&randes icônes" - IDS_VIEW_SMALL "P&etites icônes" - IDS_VIEW_DETAILS "&Détails" - IDS_WINDOWS "Fe&nêtres" - IDS_VIEW_SELECTCOLUMNS "&Sélectionner les colonnes..." - IDS_OPTIONS_SHOW16BITTASKS "&Montrer les tâches 16 bits" - IDS_VIEW_CPUHISTORY "&Historique du processeur" - IDS_VIEW_CPUHISTORY_ONEGRAPHALL "Un seul graphique pour &tous les processeurs" - IDS_VIEW_CPUHISTORY_ONEGRAPHPERCPU "Un graphique &par processeur" - IDS_VIEW_SHOWKERNELTIMES "Aff&icher les temps noyau" - IDS_APPLICATIONS "Applications" - IDS_PROCESSES "Processus" - IDS_PERFORMANCE "Performance" - IDS_STATUS_BAR_CPU_USAGE "Utilisation CPU : %3d%%" - IDS_STATUS_BAR_PROCESSES "Processus : %d" - IDS_STATUS_BAR_MEMORY_USAGE "Utilisation mémoire : %dK / %dK" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_IMAGENAME "Image" - IDS_PID "PID" - IDS_CPUUSAGE "CPU" - IDS_CPUTIME "Temps CPU" - IDS_MEMORYUSAGE "Mémoire" - IDS_MEMORYUSAGEDELTA "Écart util. mémoire" - IDS_PEAKMEMORYUSAGE "Util. mémoire max" - IDS_PAGEFAULTS "Défauts de pages" - IDS_USEROBJECTS "Objets USER" - IDS_IOREADS "Lectures E/S" - IDS_IOREADBYTES "Octets de lecture E/S" - IDS_SESSIONID "ID session" - IDS_USERNAME "Utilisateur" - IDS_PAGEFAULTSDELTA "Écart déf. pages" - IDS_VIRTUALMEMORYSIZE "Mém. virtuelle" - IDS_PAGEDPOOL "Réserve paginée" - IDS_NONPAGEDPOOL "Réserve non paginée" - IDS_BASEPRIORITY "Prio. de base" - IDS_HANDLECOUNT "Handles" - IDS_THREADCOUNT "Threads" - IDS_GDIOBJECTS "Objets GDI" - IDS_IOWRITES "Écritures E/S" - IDS_IOWRITEBYTES "Octets écriture E/S" - IDS_IOOTHER "Autres E/S" - IDS_IOOTHERBYTES "Octets autres E/S" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_WARNING_TITLE "Avertissement du gestionnaire de tâches" - IDS_PRIORITY_CHANGE_MESSAGE "ATTENTION : modifier la classe de priorité de ce processus peut\n\ - causer des résultats imprévus y compris une instabilité système. Êtes-vous\n\ - sûr(e) de vouloir modifier la classe de priorité ?" - IDS_PRIORITY_UNABLE2CHANGE "Impossible de modifier la priorité" - IDS_TERMINATE_MESSAGE "ATTENTION : stopper un processus peut causer des résultats\n\ - imprévus y compris une perte de données ou une instabilité système. Le\n\ - processus n'aura pas l'occasion de sauver son état ou ses\n\ - données avant d'être arrêté. Êtes-vous sûr(e) de vouloir\n\ - stopper le processus ?" - IDS_TERMINATE_UNABLE2TERMINATE "Impossible de stopper le processus" - IDS_DEBUG_MESSAGE "ATTENTION : déboguer ce processus peut causer des pertes de données.\n\ - Voulez-vous réellement attacher le débogueur ?" - IDS_DEBUG_UNABLE2DEBUG "Impossible de déboguer le processus" - IDS_AFFINITY_ERROR_MESSAGE "Le processus doit avoir une affinité avec au moins un processeur" - IDS_AFFINITY_ERROR_TITLE "Option invalide" - IDS_AFFINITY_UNABLE2ACCESS "Impossible d'accéder ou de modifier l'affinité du processus" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_SYSTEM_IDLE_PROCESS "Processus inactifs" - IDS_APPLICATION_NOT_RESPONDING "Ne répond pas" - IDS_APPLICATION_RUNNING "En cours d'exécution" - IDS_APPLICATION_TASK "Tâche" - IDS_APPLICATION_STATUS "Statut" - IDS_DEBUG_CHANNEL "Canaux de débogage" - IDS_DEBUG_CHANNEL_FIXME "Fixme" - IDS_DEBUG_CHANNEL_ERR "Err" - IDS_DEBUG_CHANNEL_WARN "Warn" - IDS_DEBUG_CHANNEL_TRACE "Trace" + "Place le processus dans la classe de priorité INFÉRIEURE À LA NORMALE" + ID_PROCESS_PAGE_SETPRIORITY_LOW "Place le processus dans la classe de priorité BASSE" END diff --git a/programs/taskmgr/Ja.rc b/programs/taskmgr/Ja.rc index 589575db753..e45d5779e4d 100644 --- a/programs/taskmgr/Ja.rc +++ b/programs/taskmgr/Ja.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -489,5 +487,6 @@ BEGIN ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL "プロセスの優先クラスを 通常以下 に設定します。" ID_PROCESS_PAGE_SETPRIORITY_LOW "プロセスの優先クラスを 低 に設定します。" - ID_PROCESS_PAGE_DEBUGCHANNELS "デバッグのチャンネルをコントロールします。" END + +#pragma code_page(default) diff --git a/programs/taskmgr/Ko.rc b/programs/taskmgr/Ko.rc index 45e09110dd5..9d214664ddf 100644 --- a/programs/taskmgr/Ko.rc +++ b/programs/taskmgr/Ko.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT /* @@ -485,89 +483,4 @@ BEGIN ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL "ÀÛ¾÷À» º¸Å뺸´Ù ³·Àº ¼øÀ§ Ŭ·¡½º·Î ¼³Á¤" ID_PROCESS_PAGE_SETPRIORITY_LOW "ÀÛ¾÷À» ³·Àº ¼øÀ§ Ŭ·¡½º·Î ¼³Á¤" - ID_PROCESS_PAGE_DEBUGCHANNELS "µð¹ö±× ä³Î Á¦¾î" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_VIEW_LARGE "Å« ¾ÆÀÌÄÜ(&G)" - IDS_VIEW_SMALL "ÀÛÀº ¾ÆÀÌÄÜ(&M)" - IDS_VIEW_DETAILS "Ç׸ñ(&D)" - IDS_WINDOWS "â(&W)" - IDS_VIEW_SELECTCOLUMNS "Ä÷³ ¼±ÅÃ(&S)..." - IDS_OPTIONS_SHOW16BITTASKS "16ºñÆ® ÀÛ¾÷ º¸¿©ÁÖ±â(&S)" - IDS_VIEW_CPUHISTORY "&CPU ±â·Ï" - IDS_VIEW_CPUHISTORY_ONEGRAPHALL " ¸ðµç CPU¸¦ ÇϳªÀÇ ±×·¡ÇÁ·Î(&O)" - IDS_VIEW_CPUHISTORY_ONEGRAPHPERCPU "CPU¸¶´Ù °¢°¢ÀÇ ±×·¡ÇÁ(&P)" - IDS_VIEW_SHOWKERNELTIMES "Ä¿³Î ½Ã°£ º¸¿©ÁÖ±â(&S)" - IDS_APPLICATIONS "ÇÁ·Î±×·¥" - IDS_PROCESSES "ÀÛ¾÷" - IDS_PERFORMANCE "ÆÛÆ÷¸Õ½º" - IDS_STATUS_BAR_CPU_USAGE "CPU »ç¿ë·®: %3d%%" - IDS_STATUS_BAR_PROCESSES "ÇÁ·Î¼¼½º: %d" - IDS_STATUS_BAR_MEMORY_USAGE "¸Þ¸ð¸® »ç¿ë·®: %dK / %dK" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_IMAGENAME "À̹ÌÁö À̸§" - IDS_PID "PID" - IDS_CPUUSAGE "CPU" - IDS_CPUTIME "CPU ½Ã°£" - IDS_MEMORYUSAGE "¸Þ¸ð¸® »ç¿ë·®" - IDS_MEMORYUSAGEDELTA "¸Þ¸ð¸® µ¨Å¸" - IDS_PEAKMEMORYUSAGE "ÇÇÅ© ¸Þ¸ð¸® »ç¿ë" - IDS_PAGEFAULTS "ÆäÀÌÁö ½ÇÆÐ" - IDS_USEROBJECTS "»ç¿ëÀÚ °´Ã¼" - IDS_IOREADS "I/O Àбâ" - IDS_IOREADBYTES "I/O ÀÐÀº ¹ÙÀÌÆ®" - IDS_SESSIONID "¼¼¼Ç ID" - IDS_USERNAME "»ç¿ëÀÚ À̸§" - IDS_PAGEFAULTSDELTA "PF µ¨Å¸" - IDS_VIRTUALMEMORYSIZE "VM Å©±â" - IDS_PAGEDPOOL "ÆäÀÌÁöµÈ Ç®" - IDS_NONPAGEDPOOL "NP Ǯ" - IDS_BASEPRIORITY "±âº» Pri" - IDS_HANDLECOUNT "ÇÚµé" - IDS_THREADCOUNT "¾²·¹µå" - IDS_GDIOBJECTS "GDI °´Ã¼" - IDS_IOWRITES "I/O ¾²±â" - IDS_IOWRITEBYTES "I/O ¾´ ¹ÙÀÌÆ®" - IDS_IOOTHER "I/O ±âŸ" - IDS_IOOTHERBYTES "I/O ±âŸ ¹ÙÀÌÆ®" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_WARNING_TITLE "ÀÛ¾÷ °ü¸®ÀÚ °æ°í" - IDS_PRIORITY_CHANGE_MESSAGE "°æ°í: ÇÁ·Î¼¼½ºÀÇ ¿ì¼± ¼øÀ§ Ŭ·¡±×¸¦ º¯°æÇÏ´Â °ÍÀº\n\ - ½Ã½ºÅÛ ºÒ¾ÈÁ¤À» Æ÷ÇÔÇؼ­ ¹Ù¶÷Á÷ÇÏÁö ¾ÊÀº °á°ú¸¦ °¡Á® ¿Ã ¼ö ÀÖ½À´Ï´Ù. ´ç½ÅÀº\n\ - ¿ì¼± ¼øÀ§ ¼öÁØÀ» º¯°æÇϽðڽÀ´Ï±î?" - IDS_PRIORITY_UNABLE2CHANGE "¿ì¼±¼øÀ§¸¦ ¹Ù²Ü ¼ö ¾ø½À´Ï´Ù" - IDS_TERMINATE_MESSAGE "°æ°í: ÇÁ·Î¼¼½º¸¦ ÁߴܽÃÅ°´Â °ÍÀº µ¥ÀÌŸ ¼Õ½Ç°ú\n\ - ½Ã½ºÅÛ ºÒ¾ÈÁ¤À» Æ÷ÇÔÇؼ­ ¹Ù¶÷Á÷ÇÏÁö ¾ÊÀº °á°ú¸¦ °¡Á®¿Ã ¼ö\n\ - ÀÖ½À´Ï´Ù. ÀÌ ÇÁ·Î¼¼½º µ¥ÀÌÅͳª »óŸ¦ ÀúÀåÇÒ ±âȸ°¡\n\ - ÁÖ¾îÁö±â Àü¿¡ Á¾·áµÉ °ÍÀÔ´Ï´Ù.\n\ - Á¤¸»·Î ÁߴܽÃÅ°°Ú½À´Ï±î?" - IDS_TERMINATE_UNABLE2TERMINATE "ÇÁ·Î¼¼½º¸¦ ÁߴܽÃų ¼ö ¾ø½À´Ï´Ù" - IDS_DEBUG_MESSAGE "°æ°í: ÇÁ·Î¼¼½º¸¦ µð¹ö±× ÇÏ´Â °ÍÀº µ¥ÀÌÅÍÀÇ ¼Õ½ÇÀ» °¡Á®¿Ã ¼ö ÀÖ½À´Ï´Ù.\n\ - µð¹ö°Å¸¦ »ç¿ëÇϽðڽÀ´Ï±î?" - IDS_DEBUG_UNABLE2DEBUG "ÇÁ·Î¼¼½º¸¦ µð¹ö±× ÇÒ ¼ö ¾ø½À´Ï´Ù" - IDS_AFFINITY_ERROR_MESSAGE " ÀÌ °úÁ¤Àº Àû¾îµµ ÇϳªÀÇ ÇÁ·Î¼¼¼­¿Í µ¿Áú¼ºÀÌ ÀÖ¾î¾ßÇÕ´Ï´Ù" - IDS_AFFINITY_ERROR_TITLE "¿Ã¹Ù¸£Áö ¾ÊÀº ¿É¼Ç" - IDS_AFFINITY_UNABLE2ACCESS "Á¢±ÙÇÒ¼ö ¾ø°Å³ª ÇÁ·Î¼¼½º µ¿Áú¼ºÀ» ¼³Á¤ÇÒ¼ö ¾ø½À´Ï´Ù" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_SYSTEM_IDLE_PROCESS "½Ã½ºÅÛ À¯ÈÞ ÀÛ¾÷" - IDS_APPLICATION_NOT_RESPONDING "¹ÝÀÀÀÌ ¾øÀ½" - IDS_APPLICATION_RUNNING "½ÇÇàÁß" - IDS_APPLICATION_TASK "ŽºÅ©" - IDS_APPLICATION_STATUS "»óÅÂ" - IDS_DEBUG_CHANNEL "µð¹ö±× ä³Î" - IDS_DEBUG_CHANNEL_FIXME " °íÁ¤" - IDS_DEBUG_CHANNEL_ERR " ¿¡·¯" - IDS_DEBUG_CHANNEL_WARN "°æ°í" - IDS_DEBUG_CHANNEL_TRACE "ÃßÀû" END diff --git a/programs/taskmgr/Lt.rc b/programs/taskmgr/Lt.rc deleted file mode 100644 index ac60cc5db72..00000000000 --- a/programs/taskmgr/Lt.rc +++ /dev/null @@ -1,564 +0,0 @@ -/* - * Lithuanian resources for Task Manager - * - * Copyright 2009 Aurimas Fišeras - * - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -/* - Menu -*/ - -IDR_TASKMANAGER MENU DISCARDABLE -BEGIN - POPUP "&Failas" - BEGIN - MENUITEM "&Nauja užduotis (vykdyti...)", ID_FILE_NEW - MENUITEM SEPARATOR - MENUITEM "Iš&eiti iš užduočių tvarkytuvės", ID_FILE_EXIT - END - POPUP "&Parinktys" - BEGIN - MENUITEM "&Visada viršuje", ID_OPTIONS_ALWAYSONTOP - , CHECKED - MENUITEM "&Suskleisti naudojant", ID_OPTIONS_MINIMIZEONUSE - , CHECKED - MENUITEM "S&lėpti, kai suskleista", ID_OPTIONS_HIDEWHENMINIMIZED - , CHECKED - MENUITEM "&Rodyti 16-bitų užduotis", ID_OPTIONS_SHOW16BITTASKS - , CHECKED - END - POPUP "&Rodymas" - BEGIN - MENUITEM "&Atnaujinti dabar", ID_VIEW_REFRESH - POPUP "&Atnaujinimo greitis" - BEGIN - MENUITEM "&Didelis", ID_VIEW_UPDATESPEED_HIGH - MENUITEM "&Normalus", ID_VIEW_UPDATESPEED_NORMAL - , CHECKED - MENUITEM "&Mažas", ID_VIEW_UPDATESPEED_LOW - MENUITEM "&Pristabdyta", ID_VIEW_UPDATESPEED_PAUSED - - END - MENUITEM SEPARATOR - MENUITEM "&Didelės piktogramos", ID_VIEW_LARGE - MENUITEM "&Mažos piktogramos", ID_VIEW_SMALL - MENUITEM "&Išsamus", ID_VIEW_DETAILS, CHECKED - MENUITEM "Iš&rinkti stulpelius...", ID_VIEW_SELECTCOLUMNS - POPUP "&CP istorija" - BEGIN - MENUITEM "&Viena diagrama visiems CP", ID_VIEW_CPUHISTORY_ONEGRAPHALL - - MENUITEM "Po diagramą &kiekvienam CP", ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU - , CHECKED - END - MENUITEM "&Rodyti branduolio laikus", ID_VIEW_SHOWKERNELTIMES - END - POPUP "&Langai" - BEGIN - MENUITEM "Iškloti &gulsčiai", ID_WINDOWS_TILEHORIZONTALLY - MENUITEM "Iškloti &stačiai", ID_WINDOWS_TILEVERTICALLY - MENUITEM "Susk&leisti", ID_WINDOWS_MINIMIZE - MENUITEM "&Išskleisti", ID_WINDOWS_MAXIMIZE - MENUITEM "Išdėstyti pa&kopomis", ID_WINDOWS_CASCADE - MENUITEM "Perkelti į &priekį", ID_WINDOWS_BRINGTOFRONT - END - POPUP "&Žinynas" - BEGIN - MENUITEM "Užduočių tvarkytuvės &žinynas", ID_HELP_TOPICS - MENUITEM SEPARATOR - MENUITEM "&Apie užduočių tvarkytuvę", ID_HELP_ABOUT - END -END - -IDR_WINDOWSMENU MENU DISCARDABLE -BEGIN - MENUITEM "Iškloti &gulsčiai", ID_WINDOWS_TILEHORIZONTALLY - MENUITEM "Iškloti &stačiai", ID_WINDOWS_TILEVERTICALLY - MENUITEM "Susk&leisti", ID_WINDOWS_MINIMIZE - MENUITEM "&Išskleisti", ID_WINDOWS_MAXIMIZE - MENUITEM "Išdėstyti pa&kopomis", ID_WINDOWS_CASCADE - MENUITEM "Perkelti į &priekį", ID_WINDOWS_BRINGTOFRONT -END - -IDR_APPLICATION_PAGE_CONTEXT1 MENU DISCARDABLE -BEGIN - POPUP "DUMMY" - BEGIN - MENUITEM "&Nauja užduotis (vykdyti...)", ID_FILE_NEW - MENUITEM SEPARATOR - MENUITEM "&Didelės piktogramos", ID_VIEW_LARGE - MENUITEM "&Mažos piktogramos", ID_VIEW_SMALL - MENUITEM "&Išsamus", ID_VIEW_DETAILS, CHECKED - END -END - -IDR_APPLICATION_PAGE_CONTEXT2 MENU DISCARDABLE -BEGIN - POPUP "DUMMY" - BEGIN - MENUITEM "Per&jungti į", ID_APPLICATION_PAGE_SWITCHTO - MENUITEM "Perkelti į &priekį", ID_WINDOWS_BRINGTOFRONT - MENUITEM SEPARATOR - MENUITEM "Iškloti &gulsčiai", ID_WINDOWS_TILEHORIZONTALLY - MENUITEM "Iškloti &stačiai", ID_WINDOWS_TILEVERTICALLY - MENUITEM "Susk&leisti", ID_WINDOWS_MINIMIZE - MENUITEM "&Išskleisti", ID_WINDOWS_MAXIMIZE - MENUITEM "Išdėstyti pa&kopomis", ID_WINDOWS_CASCADE - MENUITEM SEPARATOR - MENUITEM "&Baigti užduotį", ID_APPLICATION_PAGE_ENDTASK - MENUITEM "&Eiti į procesą", ID_APPLICATION_PAGE_GOTOPROCESS - END -END - -IDR_TRAY_POPUP MENU DISCARDABLE -BEGIN - POPUP "DUMMY" - BEGIN - MENUITEM "&Atkurti", ID_RESTORE - MENUITEM "&Užverti", ID_FILE_EXIT - MENUITEM SEPARATOR - MENUITEM "&Visada viršuje", ID_OPTIONS_ALWAYSONTOP - END -END - -IDR_PROCESS_PAGE_CONTEXT MENU DISCARDABLE -BEGIN - POPUP "DUMMY" - BEGIN - MENUITEM "&Baigti procesą", ID_PROCESS_PAGE_ENDPROCESS - MENUITEM "Baigti procesų &medį", ID_PROCESS_PAGE_ENDPROCESSTREE - - MENUITEM "&Derinti", ID_PROCESS_PAGE_DEBUG - MENUITEM SEPARATOR - POPUP "Nustatyti &prioritetą" - BEGIN - MENUITEM "&Tikralaikis", ID_PROCESS_PAGE_SETPRIORITY_REALTIME - - MENUITEM "&Aukštas", ID_PROCESS_PAGE_SETPRIORITY_HIGH - - MENUITEM "&ViršNormalaus", ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL - - MENUITEM "&Normalus", ID_PROCESS_PAGE_SETPRIORITY_NORMAL - - MENUITEM "&ŽemiauNormalaus", ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL - - MENUITEM "&Žemas", ID_PROCESS_PAGE_SETPRIORITY_LOW - - END - MENUITEM "Nustatyti &atitikimą...", ID_PROCESS_PAGE_SETAFFINITY - MENUITEM "Redaguoti derinimo &kanalus...", ID_PROCESS_PAGE_DEBUGCHANNELS - END -END - -/* - Dialog -*/ - -IDD_TASKMGR_DIALOG DIALOG DISCARDABLE 0, 0, 264, 246 -STYLE DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | - WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU | - WS_THICKFRAME -CAPTION "Užduočių tvarkytuvė" -MENU IDR_TASKMANAGER -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "Tab1",IDC_TAB,"SysTabControl32",WS_TABSTOP,3,3,257,228 -END - -IDD_APPLICATION_PAGE DIALOG DISCARDABLE 0, 0, 247, 210 -STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "List2",IDC_APPLIST,"SysListView32",LVS_REPORT | - LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,233,177 - PUSHBUTTON "&Nauja užduotis...",IDC_NEWTASK,177,189,63,14 - PUSHBUTTON "Per&jungti į",IDC_SWITCHTO,111,189,63,14,WS_DISABLED - PUSHBUTTON "&Baigti užduotį",IDC_ENDTASK,45,189,63,14,WS_DISABLED -END - -IDD_PROCESS_PAGE DIALOG DISCARDABLE 0, 0, 247, 210 -STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "List2",IDC_PROCESSLIST,"SysListView32",LVS_REPORT | - LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_OWNERDATA | - WS_BORDER | WS_TABSTOP,7,7,233,177 - PUSHBUTTON "&Baigti procesą",IDC_ENDPROCESS,171,189,69,14 - CONTROL "&Rodyti visų naudotojų procesus",IDC_SHOWALLPROCESSES, - "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,191,120,10 -END - -/*IDD_PERFORMANCE_PAGE DIALOGEX 0, 0, 247, 210*/ -IDD_PERFORMANCE_PAGE DIALOGEX DISCARDABLE 0, 0, 247, 210 -STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "CP naudojimas",IDC_CPU_USAGE_FRAME,5,5,60,54,WS_TABSTOP, WS_EX_TRANSPARENT - GROUPBOX "ATM naudojimas",IDC_MEM_USAGE_FRAME,5,63,60,54,BS_LEFTTEXT, WS_EX_TRANSPARENT - GROUPBOX "Sumos",IDC_TOTALS_FRAME,5,122,111,39,0,WS_EX_TRANSPARENT - GROUPBOX "Virtualioji atmintis (K)",IDC_COMMIT_CHARGE_FRAME,5,166,111,39,0,WS_EX_TRANSPARENT - GROUPBOX "Fizinė atmintis (K)",IDC_PHYSICAL_MEMORY_FRAME,131,122,111,39,0,WS_EX_TRANSPARENT - GROUPBOX "Branduolio atmintis (K)",IDC_KERNEL_MEMORY_FRAME,131,166,111,39,0,WS_EX_TRANSPARENT - LTEXT "Rodyklės",IDS_TOTALS_HANDLE_COUNT,12,131,34,8 - LTEXT "Gijos",IDS_TOTALS_THREAD_COUNT,12,140,27,8 - LTEXT "Procesai",IDS_TOTALS_PROCESS_COUNT,12,149,34,8 - EDITTEXT IDC_TOTALS_HANDLE_COUNT,65,131,45,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_TOTALS_THREAD_COUNT,65,140,45,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_TOTALS_PROCESS_COUNT,65,149,45,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - LTEXT "Iš viso",IDS_COMMIT_CHARGE_TOTAL,12,175,27,8 - LTEXT "Riba",IDS_COMMIT_CHARGE_LIMIT,12,184,15,8 - LTEXT "Pikas",IDS_COMMIT_CHARGE_PEAK,12,193,34,8 - EDITTEXT IDC_COMMIT_CHARGE_TOTAL,65,174,45,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_COMMIT_CHARGE_LIMIT,65,184,45,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_COMMIT_CHARGE_PEAK,65,193,45,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - LTEXT "Iš viso",IDS_PHYSICAL_MEMORY_TOTAL,137,131,27,8 - LTEXT "Prieinama",IDS_PHYSICAL_MEMORY_AVAILABLE,137,140,30,8 - LTEXT "Sist. podėlis",IDS_PHYSICAL_MEMORY_SYSTEM_CACHE,137,149,46,8 - EDITTEXT IDC_PHYSICAL_MEMORY_TOTAL,185,131,48,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_PHYSICAL_MEMORY_AVAILABLE,185,140,48,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_PHYSICAL_MEMORY_SYSTEM_CACHE,185,149,48,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - LTEXT "Iš viso",IDS_KERNEL_MEMORY_TOTAL,137,174,27,8 - LTEXT "Sukeičiama",IDS_KERNEL_MEMORY_PAGED,137,184,34,8 - LTEXT "Nesukeičiama",IDS_KERNEL_MEMORY_NONPAGED,137,193,34,8 - EDITTEXT IDC_KERNEL_MEMORY_TOTAL,185,174,48,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_KERNEL_MEMORY_PAGED,185,184,48,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_KERNEL_MEMORY_NONPAGED,185,193,48,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - GROUPBOX "CP naudojimo istorija",IDC_CPU_USAGE_HISTORY_FRAME,74,5,168,54,0,WS_EX_TRANSPARENT - GROUPBOX "Atminties naudojimo istorija",IDC_MEMORY_USAGE_HISTORY_FRAME,74,63,168,54,0,WS_EX_TRANSPARENT - PUSHBUTTON "CP naudojimo rodymas",IDC_CPU_USAGE_GRAPH,12,17,47,37,0, - WS_EX_CLIENTEDGE - PUSHBUTTON "ATM naudojimo rodymas",IDC_MEM_USAGE_GRAPH,12,75,47,37,0, - WS_EX_CLIENTEDGE - PUSHBUTTON "CP naudojimo istorija",IDC_CPU_USAGE_HISTORY_GRAPH,81,17, - 153,37,0,WS_EX_CLIENTEDGE - PUSHBUTTON "ATM naudojimo istorija",IDC_MEM_USAGE_HISTORY_GRAPH,81,75, - 153,37,0,WS_EX_CLIENTEDGE -END - -IDD_DEBUG_CHANNELS_DIALOG DIALOG DISCARDABLE 0, 0, 247, 210 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Derinimo kanalai" -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "List2",IDC_DEBUG_CHANNELS_LIST,"SysListView32",LVS_REPORT | - LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP | - LVS_SORTASCENDING,7,7,233,177 - PUSHBUTTON "Užverti",IDOK,171,189,69,14 -END - -IDD_AFFINITY_DIALOG DIALOG DISCARDABLE 0, 0, 231, 154 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Procesoriaus atitikimas" -FONT 8, "MS Shell Dlg" -BEGIN - DEFPUSHBUTTON "Gerai",IDOK,120,133,50,14 - PUSHBUTTON "Atsisakyti",IDCANCEL,174,133,50,14 - LTEXT "Procesoriaus atitikimo nuostata valdo kuriuos CP procesas galės naudoti vykdymui.", - IDC_STATIC,5,5,220,16 - CONTROL "CP 0",IDC_CPU0,"Button",BS_AUTOCHECKBOX | WS_TABSTOP, - 11,28,37,10 - CONTROL "CP 1",IDC_CPU1,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,41,37,10 - CONTROL "CP 2",IDC_CPU2,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,54,37,10 - CONTROL "CP 3",IDC_CPU3,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,67,37,10 - CONTROL "CP 4",IDC_CPU4,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,80,37,10 - CONTROL "CP 5",IDC_CPU5,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,93,37,10 - CONTROL "CP 6",IDC_CPU6,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,106,37,10 - CONTROL "CP 7",IDC_CPU7,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,119,37,10 - CONTROL "CP 8",IDC_CPU8,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,61,28,37,10 - CONTROL "CP 9",IDC_CPU9,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,61,41,37,10 - CONTROL "CP 10",IDC_CPU10,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,61,54,41,10 - CONTROL "CP 11",IDC_CPU11,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,61,67,41,10 - CONTROL "CP 12",IDC_CPU12,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,61,80,41,10 - CONTROL "CP 13",IDC_CPU13,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,61,93,41,10 - CONTROL "CP 14",IDC_CPU14,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,61,106,41,10 - CONTROL "CP 15",IDC_CPU15,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,61,119,41,10 - CONTROL "CP 16",IDC_CPU16,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,28,41,10 - CONTROL "CP 17",IDC_CPU17,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,41,41,10 - CONTROL "CP 18",IDC_CPU18,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,54,41,10 - CONTROL "CP 19",IDC_CPU19,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,67,41,10 - CONTROL "CP 20",IDC_CPU20,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,80,41,10 - CONTROL "CP 21",IDC_CPU21,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,93,41,10 - CONTROL "CP 22",IDC_CPU22,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,106,41,10 - CONTROL "CP 23",IDC_CPU23,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,119,41,10 - CONTROL "CP 24",IDC_CPU24,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,28,41,10 - CONTROL "CP 25",IDC_CPU25,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,41,41,10 - CONTROL "CP 26",IDC_CPU26,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,54,41,10 - CONTROL "CP 27",IDC_CPU27,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,67,41,10 - CONTROL "CP 28",IDC_CPU28,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,80,41,10 - CONTROL "CP 29",IDC_CPU29,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,93,41,10 - CONTROL "CP 30",IDC_CPU30,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,106,41,10 - CONTROL "CP 31",IDC_CPU31,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,119,41,10 -END - -IDD_COLUMNS_DIALOG DIALOG DISCARDABLE 0, 0, 231, 199 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Stulpelių išrinkimas" -FONT 8, "MS Shell Dlg" -BEGIN - DEFPUSHBUTTON "Gerai",IDOK,84,178,50,14 - PUSHBUTTON "Atsisakyti",IDCANCEL,138,178,50,14 - LTEXT "Išrinkite stulpelius, kurie bus rodomi užduočių tvarkytuvės procesų kortelėje.", - IDC_STATIC,7,7,221,17 - CONTROL "Proceso vardas",IDC_IMAGENAME,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,7,28,108,10 - CONTROL "&PID (proceso identifikatorius)",IDC_PID,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,7,39,108,10 - CONTROL "&CP naudojimas",IDC_CPUUSAGE,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,50,108,10 - CONTROL "CP &laikas",IDC_CPUTIME,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,61,108,10 - CONTROL "&Atminties naudojimas",IDC_MEMORYUSAGE,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,72,108,10 - CONTROL "Atminties naudojimo p&okytis",IDC_MEMORYUSAGEDELTA,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,7,83,108,10 - CONTROL "Atminties naudojimo p&ikas",IDC_PEAKMEMORYUSAGE,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,7,94,108,10 - CONTROL "Puslapių &klaidos",IDC_PAGEFAULTS,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,105,108,10 - CONTROL "&USER objektai",IDC_USEROBJECTS,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,116,108,10 - CONTROL "Į/I skaitymai",IDC_IOREADS,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,127,108,10 - CONTROL "Į/I perskaityta baitų",IDC_IOREADBYTES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,7,138,108,10 - CONTROL "&Sesijos identifikatorius",IDC_SESSIONID,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,149,108,10 - CONTROL "&Naudotojo vardas",IDC_USERNAME,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,160,108,10 - CONTROL "Puslapių klaidų pok&ytis",IDC_PAGEFAULTSDELTA,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,127,28,93,10 - CONTROL "&Virtualios atminties dydis",IDC_VIRTUALMEMORYSIZE,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,127,39,93,10 - CONTROL "Sukeičiamas &telkinys",IDC_PAGEDPOOL,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,127,50,93,10 - CONTROL "Nesukeičiamas t&elkinys",IDC_NONPAGEDPOOL,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,127,61,93,10 - CONTROL "&Bazinis prioritetas",IDC_BASEPRIORITY,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,127,72,93,10 - CONTROL "&Rodyklių skaičius",IDC_HANDLECOUNT,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,127,83,93,10 - CONTROL "&Gijų skaičius",IDC_THREADCOUNT,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,127,94,93,10 - CONTROL "G&DI objektai",IDC_GDIOBJECTS,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,127,105,93,10 - CONTROL "Į/I rašymai",IDC_IOWRITES,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,127,116,93,10 - CONTROL "Į/I įrašyta baitų",IDC_IOWRITEBYTES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,127,127,93,10 - CONTROL "Į/I kiti",IDC_IOOTHER,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,127,138,93,10 - CONTROL "Į/I kitų baitų",IDC_IOOTHERBYTES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,127,149,93,10 -END - -/* - String Table -*/ - -STRINGTABLE DISCARDABLE -BEGIN - IDS_APP_TITLE "Užduočių tvarkytuvė" - IDC_TASKMGR "Užduočių tvarkytuvė" - IDS_RUNDLG_CAPTION "Sukurti naują užduotį" -END - -STRINGTABLE DISCARDABLE -BEGIN - ID_FILE_NEW "Paleidžia naują programą" - ID_OPTIONS_ALWAYSONTOP "Užduočių tvarkytuvės langas lieka priekyje visų kitų langų, nebent suskleidžiamas" - ID_OPTIONS_MINIMIZEONUSE "Užduočių tvarkytuvė yra suskleidžiama, kai įvykdoma operacija „perjungti į“" - ID_OPTIONS_HIDEWHENMINIMIZED "Slepia užduočių tvarkytuvę, kai langas suskleidžiamas" - ID_VIEW_REFRESH "Priverčia užduočių tvarkytuvę atnaujinti ekraną dabar, nepaisant atnaujinimo greičio nuostatos" - ID_VIEW_LARGE "Rodo užduotis didelėmis piktogramomis" - ID_VIEW_SMALL "Rodo užduotis mažomis piktogramomis" - ID_VIEW_DETAILS "Rodo informaciją apie kiekvieną užduotį" - ID_VIEW_UPDATESPEED_HIGH "Atnaujina ekraną du kartus per sekundę" - ID_VIEW_UPDATESPEED_NORMAL "Atnaujina ekraną kas dvi sekundes" - ID_VIEW_UPDATESPEED_LOW "Atnaujina ekraną kas keturias sekundes" -END - -STRINGTABLE DISCARDABLE -BEGIN - ID_VIEW_UPDATESPEED_PAUSED "Automatiškai neatnaujina" - ID_WINDOWS_TILEHORIZONTALLY "Iškloja langus gulsčiai ant darbalaukio" - ID_WINDOWS_TILEVERTICALLY "Iškloja langus stačiai ant darbalaukio" - ID_WINDOWS_MINIMIZE "Suskleidžia langus" - ID_WINDOWS_MAXIMIZE "Išskleidžia langus" - ID_WINDOWS_CASCADE "Išdėsto langus pakopomis ant darbalaukio" - ID_WINDOWS_BRINGTOFRONT "Perkelia langą į priekį, bet į jį neperjungia" - ID_HELP_TOPICS "Rodo užduočių tvarkytuvės žinyną" - ID_HELP_ABOUT "Rodo programos informaciją, versijos numerį ir autoriaus teises" - ID_FILE_EXIT "Išeina iš užduočių tvarkytuvės" - ID_OPTIONS_SHOW16BITTASKS "Rodo 16-bitų užduotis po susietu ntvdm.exe" - ID_VIEW_SELECTCOLUMNS "Išrenka stulpelius, kurie bus matomi procesų puslapyje" - ID_VIEW_SHOWKERNELTIMES "Rodo branduolio laiką našumo diagramose" - ID_VIEW_CPUHISTORY_ONEGRAPHALL "Viena istorijos diagrama rodo bendrą CP naudojimą" - ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU "Kiekvienas CP turi savo atskirą istorijos diagramą" - ID_APPLICATION_PAGE_SWITCHTO "Perkelia užduotį priekio link ir perjungia židinį į ją" -END - -STRINGTABLE DISCARDABLE -BEGIN - ID_ENDTASK "Liepia pažymėtoms užduotims užsidaryti" - ID_GOTOPROCESS "Perjungia židinį į pažymėtos užduoties procesą" - ID_RESTORE "Atkuria užduočių tvarkytuvę iš paslėptos būsenos" - ID_PROCESS_PAGE_ENDPROCESS "Pašalina procesą iš sistemos" - ID_PROCESS_PAGE_ENDPROCESSTREE "Pašalina procesą ir visus jo palikuonis iš sistemos" - ID_PROCESS_PAGE_DEBUG "Prijungia derintuvę prie proceso" - ID_PROCESS_PAGE_SETAFFINITY "Kontroliuoja, kuriuos procesorius procesas galės naudoti vykdymui" - ID_PROCESS_PAGE_SETPRIORITY_REALTIME "Nustato procesui TIKRALAIKĘ prioriteto klasę" - ID_PROCESS_PAGE_SETPRIORITY_HIGH "Nustato procesui AUKŠTĄ prioriteto klasę" - ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL "Nustato procesui prioriteto klasę VIRŠ NORMALIOS" - ID_PROCESS_PAGE_SETPRIORITY_NORMAL "Nustato procesui NORMALIĄ prioriteto klasę" - ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL "Nustato procesui prioriteto klasę ŽEMIAU NORMALIOS" - ID_PROCESS_PAGE_SETPRIORITY_LOW "Nustato procesui ŽEMĄ prioriteto klasę" - ID_PROCESS_PAGE_DEBUGCHANNELS "Kontroliuoja derinimo kanalus" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_VIEW_LARGE "&Didelės piktogramos" - IDS_VIEW_SMALL "&Mažos piktogramos" - IDS_VIEW_DETAILS "&Išsamus" - IDS_WINDOWS "&Langai" - IDS_VIEW_SELECTCOLUMNS "Iš&rinkti stulpelius..." - IDS_OPTIONS_SHOW16BITTASKS "&Rodyti 16-bitų užduotis" - IDS_VIEW_CPUHISTORY "&CP istorija" - IDS_VIEW_CPUHISTORY_ONEGRAPHALL "&Viena diagrama visiems CP" - IDS_VIEW_CPUHISTORY_ONEGRAPHPERCPU "Po diagramą &kiekvienam CP" - IDS_VIEW_SHOWKERNELTIMES "&Rodyti branduolio laikus" - IDS_APPLICATIONS "Programos" - IDS_PROCESSES "Procesai" - IDS_PERFORMANCE "Našumas" - IDS_STATUS_BAR_CPU_USAGE "CP naudojimas: %3d%%" - IDS_STATUS_BAR_PROCESSES "Procesai: %d" - IDS_STATUS_BAR_MEMORY_USAGE "Atminties naudojimas: %dK / %dK" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_IMAGENAME "Proceso vardas" - IDS_PID "PID" - IDS_CPUUSAGE "CP" - IDS_CPUTIME "CP laikas" - IDS_MEMORYUSAGE "Atm naudojimas" - IDS_MEMORYUSAGEDELTA "Atm pokytis" - IDS_PEAKMEMORYUSAGE "Atm naud. pikas" - IDS_PAGEFAULTS "Puslap. klaidos" - IDS_USEROBJECTS "USER objektai" - IDS_IOREADS "I/O skaitymai" - IDS_IOREADBYTES "I/O persk. baitų" - IDS_SESSIONID "Sesijos ID" - IDS_USERNAME "Naudotojas" - IDS_PAGEFAULTSDELTA "PK pokytis" - IDS_VIRTUALMEMORYSIZE "VA dydis" - IDS_PAGEDPOOL "Sukeič. telkinys" - IDS_NONPAGEDPOOL "Nesukeič. telkinys" - IDS_BASEPRIORITY "Baz. prioritetas" - IDS_HANDLECOUNT "Rodyklės" - IDS_THREADCOUNT "Gijos" - IDS_GDIOBJECTS "GDI objektai" - IDS_IOWRITES "I/O rašymai" - IDS_IOWRITEBYTES "I/O įraš. baitų" - IDS_IOOTHER "I/O kiti" - IDS_IOOTHERBYTES "I/O kitų baitų" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_WARNING_TITLE "Užduočių tvarkytuvės įspėjimas" - IDS_PRIORITY_CHANGE_MESSAGE "ĮSPĖJIMAS: Šio proceso prioriteto klasės keitimas gali\n\ - sukelti nepageidaujamų pasekmių, tarp jų sistemos nestabilumą\n\ - Ar tikrai norite pakeisti prioriteto klasę?" - IDS_PRIORITY_UNABLE2CHANGE "Nepavyko pakeisti prioriteto klasės" - IDS_TERMINATE_MESSAGE "ĮSPĖJIMAS: Proceso baigimas gali sukelti nepageidaujamų\n\ - pasekmių, tarp jų duomenų praradimą ar sistemos nestabilumą.\n\ - Procesui nebus suteiktas šansas išsaugoti savo būseną ar\n\ - duomenis prieš jo baigimą. Ar tikrai norite baigti procesą?" - IDS_TERMINATE_UNABLE2TERMINATE "Nepavyko baigti proceso" - IDS_DEBUG_MESSAGE "ĮSPĖJIMAS: Šio proceso derinimas gali sukelti duomenų praradimą.\n\ - Ar tikrai norite prijungti derintuvę?" - IDS_DEBUG_UNABLE2DEBUG "Nepavyko derinti proceso" - IDS_AFFINITY_ERROR_MESSAGE "Procesas privalo naudoti bent vieną procesorių" - IDS_AFFINITY_ERROR_TITLE "Neteisingi parametrai" - IDS_AFFINITY_UNABLE2ACCESS "Nepavyko prieiti prie ar nustatyti proceso atitikimo" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_SYSTEM_IDLE_PROCESS "Sistemos neveikos procesas" - IDS_APPLICATION_NOT_RESPONDING "Neatsako" - IDS_APPLICATION_RUNNING "Vykdoma" - IDS_APPLICATION_TASK "Užduotis" - IDS_APPLICATION_STATUS "Būsena" - IDS_DEBUG_CHANNEL "Derinimo kanalai" - IDS_DEBUG_CHANNEL_FIXME "Fixme (pataisyk)" - IDS_DEBUG_CHANNEL_ERR "Err (klaida)" - IDS_DEBUG_CHANNEL_WARN "Warn (įspėjimas)" - IDS_DEBUG_CHANNEL_TRACE "Trace (pėdsakas)" -END diff --git a/programs/taskmgr/Makefile.in b/programs/taskmgr/Makefile.in index 2f2b40ada0c..153a598af30 100644 --- a/programs/taskmgr/Makefile.in +++ b/programs/taskmgr/Makefile.in @@ -29,24 +29,7 @@ C_SRCS = \ taskmgr.c \ trayicon.c -RC_SRCS = \ - Da.rc \ - De.rc \ - En.rc \ - Fr.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc \ - taskmgr.rc +RC_SRCS = taskmgr.rc @MAKE_PROG_RULES@ diff --git a/programs/taskmgr/Nl.rc b/programs/taskmgr/Nl.rc index 468769f73d4..1529341dcdf 100644 --- a/programs/taskmgr/Nl.rc +++ b/programs/taskmgr/Nl.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL /* @@ -56,7 +54,7 @@ BEGIN MENUITEM "&Normaal", ID_VIEW_UPDATESPEED_NORMAL , CHECKED MENUITEM "&Laag", ID_VIEW_UPDATESPEED_LOW - MENUITEM "&Pauze", ID_VIEW_UPDATESPEED_PAUSED + MENUITEM "&Pause", ID_VIEW_UPDATESPEED_PAUSED END MENUITEM SEPARATOR @@ -199,7 +197,7 @@ BEGIN WS_BORDER | WS_TABSTOP,7,7,233,177 PUSHBUTTON "&Beëindig proces",IDC_ENDPROCESS,171,189,69,14 CONTROL "&Toon processen van alle gebruikers",IDC_SHOWALLPROCESSES, - "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,191,125,10 + "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,191,121,10 END /*IDD_PERFORMANCE_PAGE DIALOGEX 0, 0, 247, 210*/ @@ -378,14 +376,14 @@ BEGIN WS_TABSTOP,7,127,49,10 CONTROL "I/O - Bytes (Lezen)",IDC_IOREADBYTES,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,7,138,75,10 - CONTROL "&Sessie-ID",IDC_SESSIONID,"Button",BS_AUTOCHECKBOX | + CONTROL "&Session-ID",IDC_SESSIONID,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,149,50,10 CONTROL "Gebruikers&naam",IDC_USERNAME,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,160,80,10 CONTROL "Delta van de &page faults",IDC_PAGEFAULTSDELTA,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,132,28,100,10 - CONTROL "&Grootte van virtueel geheugen",IDC_VIRTUALMEMORYSIZE,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,132,39,115,10 + BS_AUTOCHECKBOX | WS_TABSTOP,132,28,72,10 + CONTROL "&Grootte van het virtuele geheugen",IDC_VIRTUALMEMORYSIZE,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,132,39,105,10 CONTROL "&Paged Pool",IDC_PAGEDPOOL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,132,50,90,10 CONTROL "Non&paged Pool",IDC_NONPAGEDPOOL,"Button", @@ -416,7 +414,7 @@ STRINGTABLE DISCARDABLE BEGIN IDS_APP_TITLE "Task Manager" IDC_TASKMGR "Task Manager" - IDS_RUNDLG_CAPTION "Start nieuwe taak" + IDS_RUNDLG_CAPTION "Create New Task" END STRINGTABLE DISCARDABLE @@ -469,89 +467,4 @@ BEGIN ID_PROCESS_PAGE_SETPRIORITY_NORMAL "Zet het proces in de NORMAAL-prioriteitsklasse" ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL "Zet het proces in de LAGER DAN NORMAAL-prioriteitsklasse" ID_PROCESS_PAGE_SETPRIORITY_LOW "Zet het proces in de LAGE-prioriteitsklasse" - ID_PROCESS_PAGE_DEBUGCHANNELS "Beheer van debugkanalen" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_VIEW_LARGE "&Grote symbolen" - IDS_VIEW_SMALL "&Kleine symbolen" - IDS_VIEW_DETAILS "&Details" - IDS_WINDOWS "&Vensters" - IDS_VIEW_SELECTCOLUMNS "&Selecteer kolommen" - IDS_OPTIONS_SHOW16BITTASKS "&Toon 16-bit taken" - IDS_VIEW_CPUHISTORY "&CPU historie" - IDS_VIEW_CPUHISTORY_ONEGRAPHALL "&Eén grafiek, alle CPUs" - IDS_VIEW_CPUHISTORY_ONEGRAPHPERCPU "Eén grafiek &per CPU" - IDS_VIEW_SHOWKERNELTIMES "&Toon kerneltijden" - IDS_APPLICATIONS "Toepassingen" - IDS_PROCESSES "Processen" - IDS_PERFORMANCE "Prestaties" - IDS_STATUS_BAR_CPU_USAGE "CPU-gebruik: %3d%%" - IDS_STATUS_BAR_PROCESSES "Processen: %d" - IDS_STATUS_BAR_MEMORY_USAGE "Geheugengebruik: %dK / %dK" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_IMAGENAME "Procesnaam" - IDS_PID "Process ID" - IDS_CPUUSAGE "CPU-gebruik" - IDS_CPUTIME "CPU-tijd" - IDS_MEMORYUSAGE "Geheugengebruik" - IDS_MEMORYUSAGEDELTA "Delta in geheugengebruik" - IDS_PEAKMEMORYUSAGE "Maximale geheugengebruik" - IDS_PAGEFAULTS "Page Faults" - IDS_USEROBJECTS "USER-objecten" - IDS_IOREADS "I/O (Lezen)" - IDS_IOREADBYTES "I/O - Bytes (Lezen)" - IDS_SESSIONID "Sessie-ID" - IDS_USERNAME "Gebruikersnaam" - IDS_PAGEFAULTSDELTA "Delta van de Page Faults" - IDS_VIRTUALMEMORYSIZE "VM-grootte" - IDS_PAGEDPOOL "Paged Pool" - IDS_NONPAGEDPOOL "NP Pool" - IDS_BASEPRIORITY "Basisprioriteit" - IDS_HANDLECOUNT "Aantal handles" - IDS_THREADCOUNT "Aantal threads" - IDS_GDIOBJECTS "GDI-objecten" - IDS_IOWRITES "I/O (Schrijven)" - IDS_IOWRITEBYTES "I/O - Bytes (Schrijven)" - IDS_IOOTHER "I/O (Anders)" - IDS_IOOTHERBYTES "I/O - Bytes (Anders)" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_WARNING_TITLE "Task Manager Waarschuwing" - IDS_PRIORITY_CHANGE_MESSAGE "WAARSCHUWING: Het veranderen van de prioriteits klasse van dit\n\ - proces kan ongewenste gevolgen hebben zoals instabiliteit van\n\ - het systeem. Weet u zeker dat u de prioriteits klasse wilt veranderen?" - IDS_PRIORITY_UNABLE2CHANGE "Prioriteit kan niet worden verandered" - IDS_TERMINATE_MESSAGE "WAARSCHUWING: Het stoppen van een proces kan ongewenste\n\ - gevolgen hebben zoals verlies van gegevens en instabiliteit\n\ - van het systeem. Het proces zal geen mogelijkheid worden gegeven\n\ - om zijn gegevens of status op te slaan. Weet u zeker dat u dit process\n\ - wilt stoppen?" - IDS_TERMINATE_UNABLE2TERMINATE "Proces kan niet worden gestopt" - IDS_DEBUG_MESSAGE "WAARSCHUWING: Het debuggen van dit proces kan verlies van data tot\n\ - gevolg hebben. Weet u zeker dat u de debugger wilt koppelen?" - IDS_DEBUG_UNABLE2DEBUG "Proces kan niet worden gedebugged" - IDS_AFFINITY_ERROR_MESSAGE "Het proces moet aan tenminste 1 processor worden gekoppeld" - IDS_AFFINITY_ERROR_TITLE "Ongeldige optie" - IDS_AFFINITY_UNABLE2ACCESS "Proces affiniteit kan niet worden gelezen of gezet" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_SYSTEM_IDLE_PROCESS "Niet actief proces" - IDS_APPLICATION_NOT_RESPONDING "Reageert niet" - IDS_APPLICATION_RUNNING "Geactiveerd" - IDS_APPLICATION_TASK "Taak" - IDS_APPLICATION_STATUS "Status" - IDS_DEBUG_CHANNEL "Debugkanalen" - IDS_DEBUG_CHANNEL_FIXME "Fixme" - IDS_DEBUG_CHANNEL_ERR "Err" - IDS_DEBUG_CHANNEL_WARN "Warn" - IDS_DEBUG_CHANNEL_TRACE "Trace" END diff --git a/programs/taskmgr/No.rc b/programs/taskmgr/No.rc index 598b567c70c..f25eadc2696 100644 --- a/programs/taskmgr/No.rc +++ b/programs/taskmgr/No.rc @@ -1,7 +1,7 @@ /* - * Norwegian Bokmål resources for Task Manager + * Norwegian Bokmål resources for Task Manager * - * Copyright 2005-2009 Alexander N. Sørnes + * Copyright 2005 Alexander N. Sørnes * * * This library is free software; you can redistribute it and/or @@ -19,10 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL /* @@ -33,27 +29,27 @@ IDR_TASKMANAGER MENU DISCARDABLE BEGIN POPUP "&Fil" BEGIN - MENUITEM "&Ny oppgave (Kjør...)", ID_FILE_NEW + MENUITEM "&Ny oppgave (Kjør...)", ID_FILE_NEW MENUITEM SEPARATOR MENUITEM "&Avslutt oppgavebehandleren", ID_FILE_EXIT END POPUP "&Innstillinger" BEGIN - MENUITEM "&Alltid øverst", ID_OPTIONS_ALWAYSONTOP + MENUITEM "&Alltid øverst", ID_OPTIONS_ALWAYSONTOP , CHECKED MENUITEM "&Minimer ved bruk", ID_OPTIONS_MINIMIZEONUSE , CHECKED - MENUITEM "S&kjul når minimert", ID_OPTIONS_HIDEWHENMINIMIZED + MENUITEM "S&kjul når minimert", ID_OPTIONS_HIDEWHENMINIMIZED , CHECKED - MENUITEM "Vi&s 16 bit-jobber", ID_OPTIONS_SHOW16BITTASKS + MENUITEM "Vi&s 16-biters jobber", ID_OPTIONS_SHOW16BITTASKS , CHECKED END POPUP "&Vis" BEGIN - MENUITEM "Oppdate&r nå", ID_VIEW_REFRESH + MENUITEM "Oppdate&r nå", ID_VIEW_REFRESH POPUP "&Oppdateringsfrekvens" BEGIN - MENUITEM "&Høy", ID_VIEW_UPDATESPEED_HIGH + MENUITEM "&Høy", ID_VIEW_UPDATESPEED_HIGH MENUITEM "&Normal", ID_VIEW_UPDATESPEED_NORMAL , CHECKED MENUITEM "&Lav", ID_VIEW_UPDATESPEED_LOW @@ -62,7 +58,7 @@ BEGIN END MENUITEM SEPARATOR MENUITEM "S&tore ikoner", ID_VIEW_LARGE - MENUITEM "S&må ikoner", ID_VIEW_SMALL + MENUITEM "S&må ikoner", ID_VIEW_SMALL MENUITEM "&Detaljer", ID_VIEW_DETAILS, CHECKED MENUITEM "&Velg kolonner...", ID_VIEW_SELECTCOLUMNS POPUP "&Prosessorhistorikk" @@ -81,7 +77,7 @@ BEGIN MENUITEM "&Minimer", ID_WINDOWS_MINIMIZE MENUITEM "Ma&ksimer", ID_WINDOWS_MAXIMIZE MENUITEM "&Kortstokk", ID_WINDOWS_CASCADE - MENUITEM "&Vis øverst", ID_WINDOWS_BRINGTOFRONT + MENUITEM "&Vis øverst", ID_WINDOWS_BRINGTOFRONT END POPUP "&Hjelp" BEGIN @@ -98,17 +94,17 @@ BEGIN MENUITEM "&Minimer", ID_WINDOWS_MINIMIZE MENUITEM "Ma&ksimer", ID_WINDOWS_MAXIMIZE MENUITEM "&Kortstokk", ID_WINDOWS_CASCADE - MENUITEM "V&is øverst", ID_WINDOWS_BRINGTOFRONT + MENUITEM "V&is øverst", ID_WINDOWS_BRINGTOFRONT END IDR_APPLICATION_PAGE_CONTEXT1 MENU DISCARDABLE BEGIN POPUP "DUMMY" BEGIN - MENUITEM "&Ny oppgave (Kjør...)", ID_FILE_NEW + MENUITEM "&Ny oppgave (Kjør...)", ID_FILE_NEW MENUITEM SEPARATOR MENUITEM "&Store ikoner", ID_VIEW_LARGE - MENUITEM "S&må ikoner", ID_VIEW_SMALL + MENUITEM "S&må ikoner", ID_VIEW_SMALL MENUITEM "&Detaljer", ID_VIEW_DETAILS, CHECKED END END @@ -118,7 +114,7 @@ BEGIN POPUP "DUMMY" BEGIN MENUITEM "B&ytt til", ID_APPLICATION_PAGE_SWITCHTO - MENUITEM "Vis &øverst", ID_WINDOWS_BRINGTOFRONT + MENUITEM "Vis &øverst", ID_WINDOWS_BRINGTOFRONT MENUITEM SEPARATOR MENUITEM "Still opp &vannrett", ID_WINDOWS_TILEHORIZONTALLY MENUITEM "Still opp &loddrett", ID_WINDOWS_TILEVERTICALLY @@ -127,7 +123,7 @@ BEGIN MENUITEM "&Kortstokk", ID_WINDOWS_CASCADE MENUITEM SEPARATOR MENUITEM "Avslutt oppgav&e", ID_APPLICATION_PAGE_ENDTASK - MENUITEM "&Gå til prosess", ID_APPLICATION_PAGE_GOTOPROCESS + MENUITEM "&Gå til prosess", ID_APPLICATION_PAGE_GOTOPROCESS END END @@ -138,7 +134,7 @@ BEGIN MENUITEM "Gjenopp&rett", ID_RESTORE MENUITEM "Avlut&t", ID_FILE_EXIT MENUITEM SEPARATOR - MENUITEM "&Alltid øverst", ID_OPTIONS_ALWAYSONTOP + MENUITEM "&Alltid øverst", ID_OPTIONS_ALWAYSONTOP END END @@ -149,13 +145,13 @@ BEGIN MENUITEM "Avslutt pros&ess", ID_PROCESS_PAGE_ENDPROCESS MENUITEM "Avslu&tt prosesstre", ID_PROCESS_PAGE_ENDPROCESSTREE - MENUITEM "&Feilsøk", ID_PROCESS_PAGE_DEBUG + MENUITEM "&Feilsøk", ID_PROCESS_PAGE_DEBUG MENUITEM SEPARATOR POPUP "Angi &prioritet" BEGIN MENUITEM "&Samtid", ID_PROCESS_PAGE_SETPRIORITY_REALTIME - MENUITEM "&Høy", ID_PROCESS_PAGE_SETPRIORITY_HIGH + MENUITEM "&Høy", ID_PROCESS_PAGE_SETPRIORITY_HIGH MENUITEM "Over norm&al", ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL @@ -167,7 +163,7 @@ BEGIN END MENUITEM "&Angi slektskap...", ID_PROCESS_PAGE_SETAFFINITY - MENUITEM "&Rediger feilsøkingskanaler...", ID_PROCESS_PAGE_DEBUGCHANNELS + MENUITEM "&Rediger feilsøkingskanaler...", ID_PROCESS_PAGE_DEBUGCHANNELS END END @@ -220,8 +216,8 @@ BEGIN GROUPBOX "Virtuelt minne (K)",IDC_COMMIT_CHARGE_FRAME,5,166,111,39,0,WS_EX_TRANSPARENT GROUPBOX "Fysisk minne (K)",IDC_PHYSICAL_MEMORY_FRAME,131,122,111,39,0,WS_EX_TRANSPARENT GROUPBOX "Kjerneminne (K)",IDC_KERNEL_MEMORY_FRAME,131,166,111,39,0,WS_EX_TRANSPARENT - LTEXT "Håndtak",IDS_TOTALS_HANDLE_COUNT,12,131,27,8 - LTEXT "Tråder",IDS_TOTALS_THREAD_COUNT,12,140,27,8 + LTEXT "Håndtak",IDS_TOTALS_HANDLE_COUNT,12,131,27,8 + LTEXT "Tråder",IDS_TOTALS_THREAD_COUNT,12,140,27,8 LTEXT "Prosesser",IDS_TOTALS_PROCESS_COUNT,12,149,34,8 EDITTEXT IDC_TOTALS_HANDLE_COUNT,65,131,45,8,ES_RIGHT | ES_READONLY | ES_NUMBER | NOT WS_BORDER @@ -270,7 +266,7 @@ END IDD_DEBUG_CHANNELS_DIALOG DIALOG DISCARDABLE 0, 0, 247, 210 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Feilsøkingskanaler" +CAPTION "Feilsøkingskanaler" FONT 8, "MS Shell Dlg" BEGIN CONTROL "List2",IDC_DEBUG_CHANNELS_LIST,"SysListView32",LVS_REPORT | @@ -286,7 +282,7 @@ FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "OK",IDOK,120,133,50,14 PUSHBUTTON "Avbryt",IDCANCEL,174,133,50,14 - LTEXT "Instillingen for prosesslektsskap bestemmer hvilke prosessorer prosessen kan kjøre på.", + LTEXT "Instillingen for prosesslektsskap bestemmer hvilke prosessorer prosessen kan kjøre på.", IDC_STATIC,5,5,220,16 CONTROL "Prosessor 0",IDC_CPU0,"Button",BS_AUTOCHECKBOX | WS_TABSTOP, 11,28,37,10 @@ -361,7 +357,7 @@ FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "OK",IDOK,84,178,50,14 PUSHBUTTON "Avbryt",IDCANCEL,138,178,50,14 - LTEXT "Velg kolonnene som vises på prosessiden i oppgavebehandleren.", + LTEXT "Velg kolonnene som vises på prosessiden i oppgavebehandleren.", IDC_STATIC,7,7,181,17 CONTROL "B&ildenavn",IDC_IMAGENAME,"Button",BS_AUTOCHECKBOX | WS_DISABLED | WS_TABSTOP,7,28,56,10 @@ -375,7 +371,7 @@ BEGIN WS_TABSTOP,7,72,63,10 CONTROL "Minnebruk-&delta",IDC_MEMORYUSAGEDELTA,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,7,83,82,10 - CONTROL "Høyeste minnebru&k",IDC_PEAKMEMORYUSAGE,"Button", + CONTROL "Høyeste minnebru&k",IDC_PEAKMEMORYUSAGE,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,7,94,82,10 CONTROL "Side&feil",IDC_PAGEFAULTS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,105,53,10 @@ -385,13 +381,13 @@ BEGIN WS_TABSTOP,7,127,49,10 CONTROL "I/U leste byte",IDC_IOREADBYTES,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,7,138,65,10 - CONTROL "&Økt-ID",IDC_SESSIONID,"Button",BS_AUTOCHECKBOX | + CONTROL "&Økt-ID",IDC_SESSIONID,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,149,50,10 CONTROL "Bruker&navn",IDC_USERNAME,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,160,51,10 CONTROL "Sidefeil-delt&a",IDC_PAGEFAULTSDELTA,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,107,28,72,10 - CONTROL "Størrelse på &virtuelt minne",IDC_VIRTUALMEMORYSIZE,"Button", + CONTROL "Størrelse på &virtuelt minne",IDC_VIRTUALMEMORYSIZE,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,107,39,77,10 CONTROL "Pa&ginert samling",IDC_PAGEDPOOL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,107,50,53,10 @@ -399,9 +395,9 @@ BEGIN BS_AUTOCHECKBOX | WS_TABSTOP,107,61,67,10 CONTROL "Basisp&rioritet",IDC_BASEPRIORITY,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,107,72,55,10 - CONTROL "Antall &håndtak",IDC_HANDLECOUNT,"Button",BS_AUTOCHECKBOX | + CONTROL "Antall &håndtak",IDC_HANDLECOUNT,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,107,83,59,10 - CONTROL "Antall &tråder",IDC_THREADCOUNT,"Button",BS_AUTOCHECKBOX | + CONTROL "Antall &tråder",IDC_THREADCOUNT,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,107,94,59,10 CONTROL "GDI-objekter",IDC_GDIOBJECTS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,107,105,55,10 @@ -428,14 +424,14 @@ END STRINGTABLE DISCARDABLE BEGIN - ID_FILE_NEW "Kjører et nytt program" + ID_FILE_NEW "Kjører et nytt program" ID_OPTIONS_ALWAYSONTOP "Oppgavebehandleren vises foran andre programmer med mindre den minimeres" ID_OPTIONS_MINIMIZEONUSE - "Oppgavebehandler minimeres når du bytter til en annen prosess" - ID_OPTIONS_HIDEWHENMINIMIZED "Skjul oppgavebehandleren skjules nå rden minimeres" - ID_VIEW_REFRESH "Tving oppgavebehandleren til å oppdatere nå, uansett oppdateringsfrekvens" + "Oppgavebehandler minimeres når du bytter til en annen prosess" + ID_OPTIONS_HIDEWHENMINIMIZED "Skjul oppgavebehandleren skjules nå rden minimeres" + ID_VIEW_REFRESH "Tving oppgavebehandleren til å oppdatere nå, uansett oppdateringsfrekvens" ID_VIEW_LARGE "Viser oppgaver med store ikoner" - ID_VIEW_SMALL "Viser oppgaver med små ikoner" + ID_VIEW_SMALL "Viser oppgaver med små ikoner" ID_VIEW_DETAILS "Viser informasjon om hver oppgave" ID_VIEW_UPDATESPEED_HIGH "Oppdaterer visningen to ganger per sekund" ID_VIEW_UPDATESPEED_NORMAL "Oppdaterer visningen annenhvert sekund" @@ -446,18 +442,18 @@ STRINGTABLE DISCARDABLE BEGIN ID_VIEW_UPDATESPEED_PAUSED "Oppdaterer ikke automatisk" ID_WINDOWS_TILEHORIZONTALLY - "Stiller vinduene opp vannrett på skrivebordet" - ID_WINDOWS_TILEVERTICALLY "Stiller vinduene opp loddrett på skrivebordet" + "Stiller vinduene opp vannrett på skrivebordet" + ID_WINDOWS_TILEVERTICALLY "Stiller vinduene opp loddrett på skrivebordet" ID_WINDOWS_MINIMIZE "Minimerer vinduene" ID_WINDOWS_MAXIMIZE "Maksimerer vinduene" - ID_WINDOWS_CASCADE "Viser vinduene oppå hverandre diagonalt over skrivebordet" + ID_WINDOWS_CASCADE "Viser vinduene oppå hverandre diagonalt over skrivebordet" ID_WINDOWS_BRINGTOFRONT "Henter vinduet fram, men setter det ikke i fokus" ID_HELP_TOPICS "Viser hjelpeemner om oppgavebehandleren" ID_HELP_ABOUT "Viser programinformasjon, versjonnumme og kopirett" ID_FILE_EXIT "Avslutter Oppgavebehandler" ID_OPTIONS_SHOW16BITTASKS "Viser 16-biters programmer under 'ntvdm.exe'" - ID_VIEW_SELECTCOLUMNS "Velger hvilke kolonner som vises på prosessiden" + ID_VIEW_SELECTCOLUMNS "Velger hvilke kolonner som vises på prosessiden" ID_VIEW_SHOWKERNELTIMES "Viser kjernetid i ytelsesgrafene" ID_VIEW_CPUHISTORY_ONEGRAPHALL "En enkelt historikk viser total prosessorbruk" @@ -468,18 +464,18 @@ END STRINGTABLE DISCARDABLE BEGIN - ID_ENDTASK "Gir den valgte oppgaven beskjed om å avslutte" + ID_ENDTASK "Gir den valgte oppgaven beskjed om å avslutte" ID_GOTOPROCESS "Bytter fokus til den valgte oppgavens prosess" ID_RESTORE "Gjenoppretter oppgavebehandleren fra dens skjulte status" ID_PROCESS_PAGE_ENDPROCESS "Fjerner prosessen fra systemet" ID_PROCESS_PAGE_ENDPROCESSTREE "Fjerner denne prosessen og alle etterkommere fra systemet" - ID_PROCESS_PAGE_DEBUG "Legger feilsøkeren til denne prosessen" + ID_PROCESS_PAGE_DEBUG "Legger feilsøkeren til denne prosessen" ID_PROCESS_PAGE_SETAFFINITY - "Kontrollerer hvilke prosessorer prosessen kan kjøre på" + "Kontrollerer hvilke prosessorer prosessen kan kjøre på" ID_PROCESS_PAGE_SETPRIORITY_REALTIME "Gir prosessen til samtidsprioritet" - ID_PROCESS_PAGE_SETPRIORITY_HIGH "Gir prosessen høy prioritet" + ID_PROCESS_PAGE_SETPRIORITY_HIGH "Gir prosessen høy prioritet" ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL "Gir prosessen over normal prioritet" ID_PROCESS_PAGE_SETPRIORITY_NORMAL @@ -487,90 +483,4 @@ BEGIN ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL "Gir prosessen under normal prioritet" ID_PROCESS_PAGE_SETPRIORITY_LOW "Gir prosessen lav prioritet" - ID_PROCESS_PAGE_DEBUGCHANNELS - "Kontrollerer feilsøkingskanaler" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_VIEW_LARGE "&Store ikoner" - IDS_VIEW_SMALL "S&må ikoner" - IDS_VIEW_DETAILS "&Detaljer" - IDS_WINDOWS "&Vinduer" - IDS_VIEW_SELECTCOLUMNS "Velg &kolonner..." - IDS_OPTIONS_SHOW16BITTASKS "Vi&s 16 bit-jobber" - IDS_VIEW_CPUHISTORY "&Prosessorhistorikk" - IDS_VIEW_CPUHISTORY_ONEGRAPHALL "Én graf, alle pr&osessorer" - IDS_VIEW_CPUHISTORY_ONEGRAPHPERCPU "Én graf &per prosessor" - IDS_VIEW_SHOWKERNELTIMES "Vi&s kjernetider" - IDS_APPLICATIONS "Programmer" - IDS_PROCESSES "Prosesser" - IDS_PERFORMANCE "Ytelse" - IDS_STATUS_BAR_CPU_USAGE "Prosessorbruk: %3d%%" - IDS_STATUS_BAR_PROCESSES "Prosesser: %d" - IDS_STATUS_BAR_MEMORY_USAGE "Minnebruk: %dK / %dK" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_IMAGENAME "Bildenavn" - IDS_PID "PID" - IDS_CPUUSAGE "CPU" - IDS_CPUTIME "CPU-tid" - IDS_MEMORYUSAGE "Minnebruk" - IDS_MEMORYUSAGEDELTA "Minnedelta" - IDS_PEAKMEMORYUSAGE "Høyeste minnebruk" - IDS_PAGEFAULTS "Sidefeil" - IDS_USEROBJECTS "USER-objekter" - IDS_IOREADS "I/U leseøkter" - IDS_IOREADBYTES "I/U leste byte" - IDS_SESSIONID "Økt-ID" - IDS_USERNAME "Brukernavn" - IDS_PAGEFAULTSDELTA "PF-delta" - IDS_VIRTUALMEMORYSIZE "VM-størrelse" - IDS_PAGEDPOOL "Paged Pool" - IDS_NONPAGEDPOOL "NP Pool" - IDS_BASEPRIORITY "Basispri." - IDS_HANDLECOUNT "Handles" - IDS_THREADCOUNT "Tråder" - IDS_GDIOBJECTS "GDI-objekter" - IDS_IOWRITES "I/U skriveøkter" - IDS_IOWRITEBYTES "I/U skrevne byte" - IDS_IOOTHER "I/U annet" - IDS_IOOTHERBYTES "I/O annet, byte" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_WARNING_TITLE "Oppgavebehandler - advarsel" - IDS_PRIORITY_CHANGE_MESSAGE "ADVERSEL: Å endre prioritetsklassen for denne prosessen kan\n\ - føre til uønskede resultater, som et ustabilt system. Er du\n\ - sikker på at du vil endre prioritetsklassen?" - IDS_PRIORITY_UNABLE2CHANGE "Klarte ikke endre prioriteten" - IDS_TERMINATE_MESSAGE "ADVERSEL: Å avbryte en prosess kan føre til uønskede\n\ - resultater, som tap av data og et ustabilt system.\n\ - Prosessen vil ikke få anledning til å lagre gjeldende status\n\ - eller data før den avsluttes. Er du sikker på at du\n\ - vil avbryte prosessen?" - IDS_TERMINATE_UNABLE2TERMINATE "Klarte ikke avbryte prosessen" - IDS_DEBUG_MESSAGE "ADVERSEL: Å feilsøke denne prosessen kan føre til tap av data.\n\ - Er du sikker på at du vil koble til feilsøkeren?" - IDS_DEBUG_UNABLE2DEBUG "Klarte ikke feilsøke prosessen" - IDS_AFFINITY_ERROR_MESSAGE "Prosessen må ha tilhørighet til minst én prosessor" - IDS_AFFINITY_ERROR_TITLE "Ugyldig valg" - IDS_AFFINITY_UNABLE2ACCESS "Klarte ikke lese eller endre tilhørighet til prosessor" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_SYSTEM_IDLE_PROCESS "Ledige ressurser" - IDS_APPLICATION_NOT_RESPONDING "Svarer ikke" - IDS_APPLICATION_RUNNING "Kjører" - IDS_APPLICATION_TASK "Oppgave" - IDS_APPLICATION_STATUS "Status" - IDS_DEBUG_CHANNEL "Feilsøkingskanaler" - IDS_DEBUG_CHANNEL_FIXME "Fiks meg" - IDS_DEBUG_CHANNEL_ERR "Feil" - IDS_DEBUG_CHANNEL_WARN "Advarsel" - IDS_DEBUG_CHANNEL_TRACE "Sporing" END diff --git a/programs/taskmgr/Pl.rc b/programs/taskmgr/Pl.rc index 9a38b491aa6..14537096c12 100644 --- a/programs/taskmgr/Pl.rc +++ b/programs/taskmgr/Pl.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT /* diff --git a/programs/taskmgr/Pt.rc b/programs/taskmgr/Pt.rc index 5d257a00856..42ece363052 100644 --- a/programs/taskmgr/Pt.rc +++ b/programs/taskmgr/Pt.rc @@ -20,11 +20,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE +LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL /* Menu @@ -38,9 +34,9 @@ BEGIN MENUITEM SEPARATOR MENUITEM "&Sair", ID_FILE_EXIT END - POPUP "&Opções" + POPUP "&Opções" BEGIN - MENUITEM "&Sempre Visível", ID_OPTIONS_ALWAYSONTOP + MENUITEM "&Sempre Visível", ID_OPTIONS_ALWAYSONTOP , CHECKED MENUITEM "&Executar minimizado", ID_OPTIONS_MINIMIZEONUSE , CHECKED @@ -52,7 +48,7 @@ BEGIN POPUP "&Ver" BEGIN MENUITEM "&Actualizar agora", ID_VIEW_REFRESH - POPUP "&Frequência de actualização" + POPUP "&Frequência de actualização" BEGIN MENUITEM "&Alta", ID_VIEW_UPDATESPEED_HIGH MENUITEM "&Normal", ID_VIEW_UPDATESPEED_NORMAL @@ -66,11 +62,11 @@ BEGIN MENUITEM "Icones &pequenos", ID_VIEW_SMALL MENUITEM "&Detalhes", ID_VIEW_DETAILS, CHECKED MENUITEM "&Seleccionar colunas...", ID_VIEW_SELECTCOLUMNS - POPUP "&Histórico do CPU" + POPUP "&Histórico do CPU" BEGIN - MENUITEM "&Um gráfico, todos os CPUs", ID_VIEW_CPUHISTORY_ONEGRAPHALL + MENUITEM "&Um gráfico, todos os CPUs", ID_VIEW_CPUHISTORY_ONEGRAPHALL - MENUITEM "Um &gráfico por CPU", ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU + MENUITEM "Um &gráfico por CPU", ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU , CHECKED END MENUITEM "&Mostrar tempos do kernel", ID_VIEW_SHOWKERNELTIMES @@ -86,7 +82,7 @@ BEGIN END POPUP "&Ajuda" BEGIN - MENUITEM "&Tópicos de ajuda do Gestor de Tarefas", ID_HELP_TOPICS + MENUITEM "&Tópicos de ajuda do Gestor de Tarefas", ID_HELP_TOPICS MENUITEM SEPARATOR MENUITEM "&Sobre o Gestor de Tarefas", ID_HELP_ABOUT END @@ -139,7 +135,7 @@ BEGIN MENUITEM "&Restaurar", ID_RESTORE MENUITEM "&Fechar", ID_FILE_EXIT MENUITEM SEPARATOR - MENUITEM "&Sempre Visível", ID_OPTIONS_ALWAYSONTOP + MENUITEM "&Sempre Visível", ID_OPTIONS_ALWAYSONTOP END END @@ -148,7 +144,7 @@ BEGIN POPUP "DUMMY" BEGIN MENUITEM "&Terminar Processo", ID_PROCESS_PAGE_ENDPROCESS - MENUITEM "Terminar Árvore de &Processo", ID_PROCESS_PAGE_ENDPROCESSTREE + MENUITEM "Terminar Árvore de &Processo", ID_PROCESS_PAGE_ENDPROCESSTREE MENUITEM "&Depurar", ID_PROCESS_PAGE_DEBUG MENUITEM SEPARATOR @@ -168,7 +164,7 @@ BEGIN END MENUITEM "Definir &Afinidade...", ID_PROCESS_PAGE_SETAFFINITY - MENUITEM "Edi&tar canais de depuração...", ID_PROCESS_PAGE_DEBUGCHANNELS + MENUITEM "Edi&tar canais de depuração...", ID_PROCESS_PAGE_DEBUGCHANNELS END END @@ -207,7 +203,7 @@ BEGIN WS_BORDER | WS_TABSTOP,7,7,233,177 PUSHBUTTON "&Terminar Processo",IDC_ENDPROCESS,171,189,69,14 CONTROL "&Mostrar Processos de todos os utilizadores",IDC_SHOWALLPROCESSES, - "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,191,111,10 + "Botão",BS_AUTOCHECKBOX | WS_TABSTOP,7,191,111,10 END /*IDD_PERFORMANCE_PAGE DIALOGEX 0, 0, 247, 210*/ @@ -215,12 +211,12 @@ IDD_PERFORMANCE_PAGE DIALOGEX DISCARDABLE 0, 0, 247, 210 STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX "Utilização CPU",IDC_CPU_USAGE_FRAME,5,5,60,54,WS_TABSTOP, WS_EX_TRANSPARENT - GROUPBOX "Memória",IDC_MEM_USAGE_FRAME,5,63,60,54,BS_LEFTTEXT, WS_EX_TRANSPARENT + GROUPBOX "Utilização CPU",IDC_CPU_USAGE_FRAME,5,5,60,54,WS_TABSTOP, WS_EX_TRANSPARENT + GROUPBOX "Memória",IDC_MEM_USAGE_FRAME,5,63,60,54,BS_LEFTTEXT, WS_EX_TRANSPARENT GROUPBOX "Totais",IDC_TOTALS_FRAME,5,122,111,39,0,WS_EX_TRANSPARENT GROUPBOX "Commit Charge (K)",IDC_COMMIT_CHARGE_FRAME,5,166,111,39,0,WS_EX_TRANSPARENT - GROUPBOX "Memória Física (K)",IDC_PHYSICAL_MEMORY_FRAME,131,122,111,39,0,WS_EX_TRANSPARENT - GROUPBOX "Memória kernel (K)",IDC_KERNEL_MEMORY_FRAME,131,166,111,39,0,WS_EX_TRANSPARENT + GROUPBOX "Memória Física (K)",IDC_PHYSICAL_MEMORY_FRAME,131,122,111,39,0,WS_EX_TRANSPARENT + GROUPBOX "Memória kernel (K)",IDC_KERNEL_MEMORY_FRAME,131,166,111,39,0,WS_EX_TRANSPARENT LTEXT "Identificadores",IDS_TOTALS_HANDLE_COUNT,12,131,40,8 LTEXT "Threads",IDS_TOTALS_THREAD_COUNT,12,140,27,8 LTEXT "Processos",IDS_TOTALS_PROCESS_COUNT,12,149,34,8 @@ -250,15 +246,15 @@ BEGIN ES_READONLY | ES_NUMBER | NOT WS_BORDER LTEXT "Total",IDS_KERNEL_MEMORY_TOTAL,137,174,27,8 LTEXT "Paginada",IDS_KERNEL_MEMORY_PAGED,137,184,21,8 - LTEXT "Não paginada",IDS_KERNEL_MEMORY_NONPAGED,137,193,34,8 + LTEXT "Não paginada",IDS_KERNEL_MEMORY_NONPAGED,137,193,34,8 EDITTEXT IDC_KERNEL_MEMORY_TOTAL,185,174,48,8,ES_RIGHT | ES_READONLY | ES_NUMBER | NOT WS_BORDER EDITTEXT IDC_KERNEL_MEMORY_PAGED,185,184,48,8,ES_RIGHT | ES_READONLY | ES_NUMBER | NOT WS_BORDER EDITTEXT IDC_KERNEL_MEMORY_NONPAGED,185,193,48,8,ES_RIGHT | ES_READONLY | ES_NUMBER | NOT WS_BORDER - GROUPBOX "Histórico da utilização do CPU", IDC_CPU_USAGE_HISTORY_FRAME, 74,5,168,54,0, WS_EX_TRANSPARENT - GROUPBOX "Histórico da Utilização de Memória Física", IDC_MEMORY_USAGE_HISTORY_FRAME,74,63,168,54,0,WS_EX_TRANSPARENT + GROUPBOX "Histórico da utilização do CPU", IDC_CPU_USAGE_HISTORY_FRAME, 74,5,168,54,0, WS_EX_TRANSPARENT + GROUPBOX "Histórico da Utilização de Memória Física", IDC_MEMORY_USAGE_HISTORY_FRAME,74,63,168,54,0,WS_EX_TRANSPARENT PUSHBUTTON "CPU Usage Display",IDC_CPU_USAGE_GRAPH,12,17,47,37,0, WS_EX_CLIENTEDGE PUSHBUTTON "MEM Usage Display",IDC_MEM_USAGE_GRAPH,12,75,47,37,0, @@ -271,7 +267,7 @@ END IDD_DEBUG_CHANNELS_DIALOG DIALOG DISCARDABLE 0, 0, 247, 210 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Canais de depuração" +CAPTION "Canais de depuração" FONT 8, "MS Shell Dlg" BEGIN CONTROL "List2",IDC_DEBUG_CHANNELS_LIST,"SysListView32",LVS_REPORT | @@ -287,7 +283,7 @@ FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "OK",IDOK,120,133,50,14 PUSHBUTTON "Cancelar",IDCANCEL,174,133,50,14 - LTEXT "A Afinidade do Processador controla em que CPUs o processo é permitido de executar.", + LTEXT "A Afinidade do Processador controla em que CPUs o processo é permitido de executar.", IDC_STATIC,5,5,220,16 CONTROL "CPU 0",IDC_CPU0,"Button",BS_AUTOCHECKBOX | WS_TABSTOP, 11,28,37,10 @@ -362,23 +358,23 @@ FONT 8, "MS Shell Dlg" BEGIN DEFPUSHBUTTON "OK",IDOK,84,178,50,14 PUSHBUTTON "Cancelar",IDCANCEL,138,178,50,14 - LTEXT "Seleccione as colunas que vão aparecer na página de Processos do Gestor de Tarefas.", + LTEXT "Seleccione as colunas que vão aparecer na página de Processos do Gestor de Tarefas.", IDC_STATIC,7,7,181,17 CONTROL "&Nome da Imagem",IDC_IMAGENAME,"Button",BS_AUTOCHECKBOX | WS_DISABLED | WS_TABSTOP,7,28,56,10 CONTROL "&PID (Identificador do Processo)",IDC_PID,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,7,39,88,10 - CONTROL "&Utilização do CPU",IDC_CPUUSAGE,"Button",BS_AUTOCHECKBOX | + CONTROL "&Utilização do CPU",IDC_CPUUSAGE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,50,53,10 CONTROL "&Tempo de CPU",IDC_CPUTIME,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,61,48,10 - CONTROL "U&so de Memória",IDC_MEMORYUSAGE,"Button",BS_AUTOCHECKBOX | + CONTROL "U&so de Memória",IDC_MEMORYUSAGE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,72,63,10 - CONTROL "&Delta do uso de Memória",IDC_MEMORYUSAGEDELTA,"Button", + CONTROL "&Delta do uso de Memória",IDC_MEMORYUSAGEDELTA,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,7,83,82,10 - CONTROL "P&ico do uso de Memória",IDC_PEAKMEMORYUSAGE,"Button", + CONTROL "P&ico do uso de Memória",IDC_PEAKMEMORYUSAGE,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,7,94,82,10 - CONTROL "&Falhas de paginação",IDC_PAGEFAULTS,"Button",BS_AUTOCHECKBOX | + CONTROL "&Falhas de paginação",IDC_PAGEFAULTS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,105,53,10 CONTROL "&Objectos de UTILIZADOR",IDC_USEROBJECTS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,116,62,10 @@ -386,17 +382,17 @@ BEGIN WS_TABSTOP,7,127,49,10 CONTROL "&Bytes de Leitura de E/S",IDC_IOREADBYTES,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,7,138,65,10 - CONTROL "&ID da sessão",IDC_SESSIONID,"Button",BS_AUTOCHECKBOX | + CONTROL "&ID da sessão",IDC_SESSIONID,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,149,50,10 CONTROL "&Nome de utilizador",IDC_USERNAME,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,160,51,10 - CONTROL "D&elta de Falhas de Paginação",IDC_PAGEFAULTSDELTA,"Button", + CONTROL "D&elta de Falhas de Paginação",IDC_PAGEFAULTSDELTA,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,107,28,72,10 - CONTROL "&Tamanho de Memória Virtual",IDC_VIRTUALMEMORYSIZE,"Button", + CONTROL "&Tamanho de Memória Virtual",IDC_VIRTUALMEMORYSIZE,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,107,39,77,10 CONTROL "&Conjunto Paginado",IDC_PAGEDPOOL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,107,50,53,10 - CONTROL "Conjunto Não Paginado",IDC_NONPAGEDPOOL,"Button", + CONTROL "Conjunto Não Paginado",IDC_NONPAGEDPOOL,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,107,61,67,10 CONTROL "Prioridade &Base",IDC_BASEPRIORITY,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,107,72,55,10 @@ -430,14 +426,14 @@ END STRINGTABLE DISCARDABLE BEGIN ID_FILE_NEW "Executa um novo programa" - ID_OPTIONS_ALWAYSONTOP "O Gestor de Tarefas permanece à frente de todas as outras janelas a não ser que esteja minimizado" + ID_OPTIONS_ALWAYSONTOP "O Gestor de Tarefas permanece à frente de todas as outras janelas a não ser que esteja minimizado" ID_OPTIONS_MINIMIZEONUSE - "O Gestor de Tarefas é minimizado quando se efectua uma operação de Mudar Para" - ID_OPTIONS_HIDEWHENMINIMIZED "Esconder o Gestor de Tarefas quando está minimizado" - ID_VIEW_REFRESH "Forçar o Gestor de Tarefas a actualizar agora, independentemente da velocidade de actualização definida." + "O Gestor de Tarefas é minimizado quando se efectua uma operação de Mudar Para" + ID_OPTIONS_HIDEWHENMINIMIZED "Esconder o Gestor de Tarefas quando está minimizado" + ID_VIEW_REFRESH "Forçar o Gestor de Tarefas a actualizar agora, independentemente da velocidade de actualização definida." ID_VIEW_LARGE "Mostra as tarefas usando icones grandes" ID_VIEW_SMALL "Mostra as tarefas usando icones pequenos" - ID_VIEW_DETAILS "Mostra informação sobre cada tarefa" + ID_VIEW_DETAILS "Mostra informação sobre cada tarefa" ID_VIEW_UPDATESPEED_HIGH "Actualiza o display duas vezes por segundo" ID_VIEW_UPDATESPEED_NORMAL "Actualiza o display a cada dois segundos" ID_VIEW_UPDATESPEED_LOW "Actualiza o display a cada quatro segundos" @@ -445,31 +441,31 @@ END STRINGTABLE DISCARDABLE BEGIN - ID_VIEW_UPDATESPEED_PAUSED "Não actualiza automaticamente" + ID_VIEW_UPDATESPEED_PAUSED "Não actualiza automaticamente" ID_WINDOWS_TILEHORIZONTALLY - "Dispõe as janelas em mosaico horizontal pelo desktop" - ID_WINDOWS_TILEVERTICALLY "Dispõe as janelas em mosaico vertical pelo desktop" + "Dispõe as janelas em mosaico horizontal pelo desktop" + ID_WINDOWS_TILEVERTICALLY "Dispõe as janelas em mosaico vertical pelo desktop" ID_WINDOWS_MINIMIZE "Minimiza as janelas" ID_WINDOWS_MAXIMIZE "Maximiza as janelas" - ID_WINDOWS_CASCADE "Dispõe as janelas em cascata diagonal pelo desktop" + ID_WINDOWS_CASCADE "Dispõe as janelas em cascata diagonal pelo desktop" ID_WINDOWS_BRINGTOFRONT "Traz a janela para a frente, mas sem mudar para ela" - ID_HELP_TOPICS "Mostra os tópicos de ajuda do Gestor de Tarefas" - ID_HELP_ABOUT "Mostra informação sobre o programa, versão e direitos de autor" + ID_HELP_TOPICS "Mostra os tópicos de ajuda do Gestor de Tarefas" + ID_HELP_ABOUT "Mostra informação sobre o programa, versão e direitos de autor" ID_FILE_EXIT "Sai do Gestor de Tarefas" ID_OPTIONS_SHOW16BITTASKS "Mostra as tarefas de 16-bits no ntvdm.exe associado" - ID_VIEW_SELECTCOLUMNS "Selecciona as colunas que serão visíveis na página de processos" - ID_VIEW_SHOWKERNELTIMES "Mostra o tempo do kernel nos gráficos de performance" + ID_VIEW_SELECTCOLUMNS "Selecciona as colunas que serão visíveis na página de processos" + ID_VIEW_SHOWKERNELTIMES "Mostra o tempo do kernel nos gráficos de performance" ID_VIEW_CPUHISTORY_ONEGRAPHALL - "Um único gráfico de histórico mostra o uso total do CPU" - ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU "Cada CPU tem o seu gráfico de histórico" + "Um único gráfico de histórico mostra o uso total do CPU" + ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU "Cada CPU tem o seu gráfico de histórico" ID_APPLICATION_PAGE_SWITCHTO "Coloca a tarefa no fundo e muda o foco para ela" END STRINGTABLE DISCARDABLE BEGIN - ID_ENDTASK "Diz às tarefas seleccionadas para fechar" + ID_ENDTASK "Diz às tarefas seleccionadas para fechar" ID_GOTOPROCESS "Muda o foco para o processo da tarefa seleccionada" ID_RESTORE "Restaura o Gestor de Tarefas do seu estado oculto" ID_PROCESS_PAGE_ENDPROCESS "Remove o processo do sistema" @@ -477,7 +473,7 @@ BEGIN "Remove o processo e os seus descendentes do sistema" ID_PROCESS_PAGE_DEBUG "Junta o depurador a este processo" ID_PROCESS_PAGE_SETAFFINITY - "Controla em que processadores o processo ficará autorizado a correr" + "Controla em que processadores o processo ficará autorizado a correr" ID_PROCESS_PAGE_SETPRIORITY_REALTIME "Coloca o processo na classe de prioridade em Tempo Real" ID_PROCESS_PAGE_SETPRIORITY_HIGH "Coloca o processo na classe de prioridade Alta" ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL @@ -487,90 +483,4 @@ BEGIN ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL "Coloca o processo na classe de prioridade Abaixo do Normal" ID_PROCESS_PAGE_SETPRIORITY_LOW "Coloca o processo na classe de prioridade Baixa" - ID_PROCESS_PAGE_DEBUGCHANNELS - "Controla os canais de Depuração" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_VIEW_LARGE "&Icones Grandes" - IDS_VIEW_SMALL "I&cones Pequenos" - IDS_VIEW_DETAILS "&Detalhes" - IDS_WINDOWS "&Janelas" - IDS_VIEW_SELECTCOLUMNS "&Seleccionar colunas..." - IDS_OPTIONS_SHOW16BITTASKS "&Mostrar tarefas 16-bit" - IDS_VIEW_CPUHISTORY "&Histórico do CPU" - IDS_VIEW_CPUHISTORY_ONEGRAPHALL "&Um gráfico, todos os CPUs" - IDS_VIEW_CPUHISTORY_ONEGRAPHPERCPU "Um gráfico &por CPU" - IDS_VIEW_SHOWKERNELTIMES "&Mostrar tempos do núcleo" - IDS_APPLICATIONS "Aplicações" - IDS_PROCESSES "Processos" - IDS_PERFORMANCE "Desempenho" - IDS_STATUS_BAR_CPU_USAGE "Utilização do CPU: %3d%%" - IDS_STATUS_BAR_PROCESSES "Processos: %d" - IDS_STATUS_BAR_MEMORY_USAGE "Utilização da memória: %dK / %dK" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_IMAGENAME "Nome da Imagem" - IDS_PID "PID" - IDS_CPUUSAGE "CPU" - IDS_CPUTIME "Tempo de CPU" - IDS_MEMORYUSAGE "Utilização de Memória" - IDS_MEMORYUSAGEDELTA "Intervalo de Memória" - IDS_PEAKMEMORYUSAGE "Pico de Utilização de Memória" - IDS_PAGEFAULTS "Falhas de Páginas" - IDS_USEROBJECTS "Objectos do Utilizador" - IDS_IOREADS "Leituras I/O" - IDS_IOREADBYTES "Bytes de Leituras I/O" - IDS_SESSIONID "ID da Sessão" - IDS_USERNAME "Nome de Utilizador" - IDS_PAGEFAULTSDELTA "Intervalo de PF" - IDS_VIRTUALMEMORYSIZE "Tamanho da VM" - IDS_PAGEDPOOL "Paged Pool" - IDS_NONPAGEDPOOL "NP Pool" - IDS_BASEPRIORITY "Base Pri" - IDS_HANDLECOUNT "Handles" - IDS_THREADCOUNT "Threads" - IDS_GDIOBJECTS "Objectos GDI" - IDS_IOWRITES "Escritas I/O" - IDS_IOWRITEBYTES "Bytes de Escritas I/O" - IDS_IOOTHER "Outros I/O" - IDS_IOOTHERBYTES "Bytes de Outros I/O" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_WARNING_TITLE "Aviso do Gestor de Tarefas" - IDS_PRIORITY_CHANGE_MESSAGE "AVISO: Mudar a classe de prioridade deste processo pode\n\ - causar resultados indesejáveis incluindo instabilidade do sistema. Tem a\n\ - certeza que quer mudar a classe de prioridade?" - IDS_PRIORITY_UNABLE2CHANGE "Incapaz de mudar a Prioridade" - IDS_TERMINATE_MESSAGE "AVISO: Terminar um processo pode causar resultados\n\ - indesejáveis incluindo perda de dados e instabilidade do sistema.\n\ - O processo não vai poder guardar o seu estado ou\n\ - dados antes de terminar. Tem a certeza que deseja\n\ - terminar o processo?" - IDS_TERMINATE_UNABLE2TERMINATE "Incapaz de Terminar o Processo" - IDS_DEBUG_MESSAGE "AVISO: Depurar este processo pode resultar em perda de dados.\n\ - Tem a certeza que deseja activar o depurador?" - IDS_DEBUG_UNABLE2DEBUG "Incapaz de depurar o processo" - IDS_AFFINITY_ERROR_MESSAGE "O processo tem de ter afinidade com pelo menos um processador" - IDS_AFFINITY_ERROR_TITLE "Opção Inválida" - IDS_AFFINITY_UNABLE2ACCESS "Incapaz de aceder ou alterar a Afinidade do Processo" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_SYSTEM_IDLE_PROCESS "Processo de Sistema Parado" - IDS_APPLICATION_NOT_RESPONDING "Não Responde" - IDS_APPLICATION_RUNNING "A executar" - IDS_APPLICATION_TASK "Tarefa" - IDS_APPLICATION_STATUS "Estado" - IDS_DEBUG_CHANNEL "Canais de Depuração" - IDS_DEBUG_CHANNEL_FIXME "Fixme" - IDS_DEBUG_CHANNEL_ERR "Err" - IDS_DEBUG_CHANNEL_WARN "Warn" - IDS_DEBUG_CHANNEL_TRACE "Trace" END diff --git a/programs/taskmgr/Ru.rc b/programs/taskmgr/Ru.rc dissimilarity index 72% index a90587259eb..e9d657bd23e 100644 --- a/programs/taskmgr/Ru.rc +++ b/programs/taskmgr/Ru.rc @@ -1,567 +1,486 @@ -/* - * Task Manager (Russian resources) - * - * Copyright 2008 Vladimir Pankratov - * - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT - -/* - Menu -*/ - -IDR_TASKMANAGER MENU DISCARDABLE -BEGIN - POPUP "&Файл" - BEGIN - MENUITEM "&Новая задача (Выполнить...)", ID_FILE_NEW - MENUITEM SEPARATOR - MENUITEM "&Завершение диспетчера задач", ID_FILE_EXIT - END - POPUP "&Параметры" - BEGIN - MENUITEM "Пове&рх остальных окон", ID_OPTIONS_ALWAYSONTOP - , CHECKED - MENUITEM "&Сворачивать после обращения", ID_OPTIONS_MINIMIZEONUSE - , CHECKED - MENUITEM "С&крывать свернутое", ID_OPTIONS_HIDEWHENMINIMIZED - , CHECKED - MENUITEM "&Отображать 16-разрядные программы", ID_OPTIONS_SHOW16BITTASKS - , CHECKED - END - POPUP "&Вид" - BEGIN - MENUITEM "&Обновить", ID_VIEW_REFRESH - POPUP "&Скорость обновления" - BEGIN - MENUITEM "&Высокая", ID_VIEW_UPDATESPEED_HIGH - MENUITEM "&Обычная", ID_VIEW_UPDATESPEED_NORMAL - , CHECKED - MENUITEM "&Низкая", ID_VIEW_UPDATESPEED_LOW - MENUITEM "&Приостановить", ID_VIEW_UPDATESPEED_PAUSED - - END - MENUITEM SEPARATOR - MENUITEM "&Крупные значки", ID_VIEW_LARGE - MENUITEM "&Мелкие значки", ID_VIEW_SMALL - MENUITEM "&Таблица", ID_VIEW_DETAILS, CHECKED - MENUITEM "В&ыбрать столбцы...", ID_VIEW_SELECTCOLUMNS - POPUP "&Загрузка ЦП" - BEGIN - MENUITEM "&Один график на все ЦП", ID_VIEW_CPUHISTORY_ONEGRAPHALL - - MENUITEM "&По графику на каждый ЦП", ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU - , CHECKED - END - MENUITEM "&Вывод времени ядра", ID_VIEW_SHOWKERNELTIMES - END - POPUP "&Окна" - BEGIN - MENUITEM "С&лева направо", ID_WINDOWS_TILEHORIZONTALLY - MENUITEM "С&верху вниз", ID_WINDOWS_TILEVERTICALLY - MENUITEM "&Свернуть", ID_WINDOWS_MINIMIZE - MENUITEM "&Развернуть", ID_WINDOWS_MAXIMIZE - MENUITEM "&Каскадом", ID_WINDOWS_CASCADE - MENUITEM "&На передний план", ID_WINDOWS_BRINGTOFRONT - END - POPUP "&Справка" - BEGIN - MENUITEM "&Вызов справки", ID_HELP_TOPICS - MENUITEM SEPARATOR - MENUITEM "&О программе", ID_HELP_ABOUT - END -END - -IDR_WINDOWSMENU MENU DISCARDABLE -BEGIN - MENUITEM "С&лева направо", ID_WINDOWS_TILEHORIZONTALLY - MENUITEM "С&верху вниз", ID_WINDOWS_TILEVERTICALLY - MENUITEM "&Свернуть", ID_WINDOWS_MINIMIZE - MENUITEM "&Развернуть", ID_WINDOWS_MAXIMIZE - MENUITEM "&Каскадом", ID_WINDOWS_CASCADE - MENUITEM "&На передний план", ID_WINDOWS_BRINGTOFRONT -END - -IDR_APPLICATION_PAGE_CONTEXT1 MENU DISCARDABLE -BEGIN - POPUP "DUMMY" - BEGIN - MENUITEM "&Новая задача (Выполнить...)", ID_FILE_NEW - MENUITEM SEPARATOR - MENUITEM "&Крупные значки", ID_VIEW_LARGE - MENUITEM "&Мелкие значки", ID_VIEW_SMALL - MENUITEM "&Таблица", ID_VIEW_DETAILS, CHECKED - END -END - -IDR_APPLICATION_PAGE_CONTEXT2 MENU DISCARDABLE -BEGIN - POPUP "DUMMY" - BEGIN - MENUITEM "&Переключиться", ID_APPLICATION_PAGE_SWITCHTO - MENUITEM "&На передний план", ID_WINDOWS_BRINGTOFRONT - MENUITEM SEPARATOR - MENUITEM "С&лева направо", ID_WINDOWS_TILEHORIZONTALLY - MENUITEM "С&верху вниз", ID_WINDOWS_TILEVERTICALLY - MENUITEM "&Свернуть", ID_WINDOWS_MINIMIZE - MENUITEM "&Развернуть", ID_WINDOWS_MAXIMIZE - MENUITEM "&Каскадом", ID_WINDOWS_CASCADE - MENUITEM SEPARATOR - MENUITEM "Снять &задачу", ID_APPLICATION_PAGE_ENDTASK - MENUITEM "&Перейти к процессам", ID_APPLICATION_PAGE_GOTOPROCESS - END -END - -IDR_TRAY_POPUP MENU DISCARDABLE -BEGIN - POPUP "DUMMY" - BEGIN - MENUITEM "&Восстановить", ID_RESTORE - MENUITEM "&Закрыть", ID_FILE_EXIT - MENUITEM SEPARATOR - MENUITEM "Пове&рх остальных окон", ID_OPTIONS_ALWAYSONTOP - END -END - -IDR_PROCESS_PAGE_CONTEXT MENU DISCARDABLE -BEGIN - POPUP "DUMMY" - BEGIN - MENUITEM "&Завершить процесс", ID_PROCESS_PAGE_ENDPROCESS - MENUITEM "Завершить &дерево процессов", ID_PROCESS_PAGE_ENDPROCESSTREE - - MENUITEM "&Отладка", ID_PROCESS_PAGE_DEBUG - MENUITEM SEPARATOR - POPUP "&Приоритет" - BEGIN - MENUITEM "&Реального времени", ID_PROCESS_PAGE_SETPRIORITY_REALTIME - - MENUITEM "&Высокий", ID_PROCESS_PAGE_SETPRIORITY_HIGH - - MENUITEM "В&ыше среднего", ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL - - MENUITEM "&Средний", ID_PROCESS_PAGE_SETPRIORITY_NORMAL - - MENUITEM "Н&иже среднего", ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL - - MENUITEM "&Низкий", ID_PROCESS_PAGE_SETPRIORITY_LOW - - END - MENUITEM "Задать &соответствие...", ID_PROCESS_PAGE_SETAFFINITY - MENUITEM "Редактировать &каналы отладки...", ID_PROCESS_PAGE_DEBUGCHANNELS - END -END - -/* - Dialog -*/ - -IDD_TASKMGR_DIALOG DIALOG DISCARDABLE 0, 0, 270, 246 -STYLE DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | - WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU | - WS_THICKFRAME -CAPTION "Диспетчер задач" -MENU IDR_TASKMANAGER -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "Tab1",IDC_TAB,"SysTabControl32",WS_TABSTOP,3,3,257,228 -END - -IDD_APPLICATION_PAGE DIALOG DISCARDABLE 0, 0, 247, 210 -STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "List2",IDC_APPLIST,"SysListView32",LVS_REPORT | - LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,233,177 - PUSHBUTTON "&Новая задача...",IDC_NEWTASK,177,189,63,14 - PUSHBUTTON "П&ереключиться",IDC_SWITCHTO,111,189,63,14,WS_DISABLED - PUSHBUTTON "Снять &задачу",IDC_ENDTASK,45,189,63,14,WS_DISABLED -END - -IDD_PROCESS_PAGE DIALOG DISCARDABLE 0, 0, 247, 210 -STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "List2",IDC_PROCESSLIST,"SysListView32",LVS_REPORT | - LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_OWNERDATA | - WS_BORDER | WS_TABSTOP,7,7,233,177 - PUSHBUTTON "&Завершить процесс",IDC_ENDPROCESS,171,189,75,14 - CONTROL "&Отображать процессы всех пользователей",IDC_SHOWALLPROCESSES, - "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,191,160,10 -END - -/*IDD_PERFORMANCE_PAGE DIALOGEX 0, 0, 247, 210*/ -IDD_PERFORMANCE_PAGE DIALOGEX DISCARDABLE 0, 0, 247, 210 -STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "Загрузка ЦП",IDC_CPU_USAGE_FRAME,5,5,60,54,WS_TABSTOP, WS_EX_TRANSPARENT - GROUPBOX "Файл подкачки",IDC_MEM_USAGE_FRAME,5,63,60,54,BS_LEFTTEXT, WS_EX_TRANSPARENT - GROUPBOX "Всего",IDC_TOTALS_FRAME,5,122,111,39,0,WS_EX_TRANSPARENT - GROUPBOX "Выделение памяти (КБ)",IDC_COMMIT_CHARGE_FRAME,5,166,111,39,0,WS_EX_TRANSPARENT - GROUPBOX "Физическая память (КБ)",IDC_PHYSICAL_MEMORY_FRAME,131,122,111,39,0,WS_EX_TRANSPARENT - GROUPBOX "Память ядра (КБ)",IDC_KERNEL_MEMORY_FRAME,131,166,111,39,0,WS_EX_TRANSPARENT - LTEXT "Дескрипторов",IDS_TOTALS_HANDLE_COUNT,12,131,80,8 - LTEXT "Потоков",IDS_TOTALS_THREAD_COUNT,12,140,27,8 - LTEXT "Процессов",IDS_TOTALS_PROCESS_COUNT,12,149,35,8 - EDITTEXT IDC_TOTALS_HANDLE_COUNT,65,131,45,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_TOTALS_THREAD_COUNT,65,140,45,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_TOTALS_PROCESS_COUNT,65,149,45,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - LTEXT "Всего",IDS_COMMIT_CHARGE_TOTAL,12,175,27,8 - LTEXT "Предел",IDS_COMMIT_CHARGE_LIMIT,12,184,50,8 - LTEXT "Пик",IDS_COMMIT_CHARGE_PEAK,12,193,34,8 - EDITTEXT IDC_COMMIT_CHARGE_TOTAL,65,174,45,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_COMMIT_CHARGE_LIMIT,65,184,45,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_COMMIT_CHARGE_PEAK,65,193,45,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - LTEXT "Всего",IDS_PHYSICAL_MEMORY_TOTAL,137,131,27,8 - LTEXT "Доступно",IDS_PHYSICAL_MEMORY_AVAILABLE,137,140,31,8 - LTEXT "Системный кеш",IDS_PHYSICAL_MEMORY_SYSTEM_CACHE,137,149,46,8 - EDITTEXT IDC_PHYSICAL_MEMORY_TOTAL,185,131,48,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_PHYSICAL_MEMORY_AVAILABLE,185,140,48,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_PHYSICAL_MEMORY_SYSTEM_CACHE,185,149,48,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - LTEXT "Всего",IDS_KERNEL_MEMORY_TOTAL,137,174,27,8 - LTEXT "Выгружаемая",IDS_KERNEL_MEMORY_PAGED,137,184,70,8 - LTEXT "Невыгруж.",IDS_KERNEL_MEMORY_NONPAGED,137,193,70,8 - EDITTEXT IDC_KERNEL_MEMORY_TOTAL,185,174,48,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_KERNEL_MEMORY_PAGED,185,184,48,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - EDITTEXT IDC_KERNEL_MEMORY_NONPAGED,185,193,48,8,ES_RIGHT | - ES_READONLY | ES_NUMBER | NOT WS_BORDER - GROUPBOX "Хронология загрузки ЦП",IDC_CPU_USAGE_HISTORY_FRAME,74,5,168,54,0,WS_EX_TRANSPARENT - GROUPBOX "Хронология использования файла подкачки",IDC_MEMORY_USAGE_HISTORY_FRAME,74,63,168,54,0,WS_EX_TRANSPARENT - PUSHBUTTON "Хронология загрузки ЦП",IDC_CPU_USAGE_GRAPH,12,17,47,37,0, - WS_EX_CLIENTEDGE - PUSHBUTTON "Файл подкачки",IDC_MEM_USAGE_GRAPH,12,75,47,37,0, - WS_EX_CLIENTEDGE - PUSHBUTTON "Хронология загрузки ЦП",IDC_CPU_USAGE_HISTORY_GRAPH,81,17, - 153,37,0,WS_EX_CLIENTEDGE - PUSHBUTTON "Файл подкачки",IDC_MEM_USAGE_HISTORY_GRAPH,81,75, - 153,37,0,WS_EX_CLIENTEDGE -END - -IDD_DEBUG_CHANNELS_DIALOG DIALOG DISCARDABLE 0, 0, 247, 210 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Каналы отладки" -FONT 8, "MS Shell Dlg" -BEGIN - CONTROL "List2",IDC_DEBUG_CHANNELS_LIST,"SysListView32",LVS_REPORT | - LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP | - LVS_SORTASCENDING,7,7,233,177 - PUSHBUTTON "Закрыть",IDOK,171,189,69,14 -END - -IDD_AFFINITY_DIALOG DIALOG DISCARDABLE 0, 0, 231, 154 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Соответствие процессоров" -FONT 8, "MS Shell Dlg" -BEGIN - DEFPUSHBUTTON "OK",IDOK,120,133,50,14 - PUSHBUTTON "Отмена",IDCANCEL,174,133,50,14 - LTEXT "Соответствие процессоров определяет, какой ЦП разрешено использовать процессу.", - IDC_STATIC,5,5,220,16 - CONTROL "ЦП 0",IDC_CPU0,"Button",BS_AUTOCHECKBOX | WS_TABSTOP, - 11,28,37,10 - CONTROL "ЦП 1",IDC_CPU1,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,41,37,10 - CONTROL "ЦП 2",IDC_CPU2,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,54,37,10 - CONTROL "ЦП 3",IDC_CPU3,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,67,37,10 - CONTROL "ЦП 4",IDC_CPU4,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,80,37,10 - CONTROL "ЦП 5",IDC_CPU5,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,93,37,10 - CONTROL "ЦП 6",IDC_CPU6,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,106,37,10 - CONTROL "ЦП 7",IDC_CPU7,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,11,119,37,10 - CONTROL "ЦП 8",IDC_CPU8,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,61,28,37,10 - CONTROL "ЦП 9",IDC_CPU9,"Button",BS_AUTOCHECKBOX | WS_DISABLED | - WS_TABSTOP,61,41,37,10 - CONTROL "ЦП 10",IDC_CPU10,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,61,54,41,10 - CONTROL "ЦП 11",IDC_CPU11,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,61,67,41,10 - CONTROL "ЦП 12",IDC_CPU12,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,61,80,41,10 - CONTROL "ЦП 13",IDC_CPU13,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,61,93,41,10 - CONTROL "ЦП 14",IDC_CPU14,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,61,106,41,10 - CONTROL "ЦП 15",IDC_CPU15,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,61,119,41,10 - CONTROL "ЦП 16",IDC_CPU16,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,28,41,10 - CONTROL "ЦП 17",IDC_CPU17,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,41,41,10 - CONTROL "ЦП 18",IDC_CPU18,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,54,41,10 - CONTROL "ЦП 19",IDC_CPU19,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,67,41,10 - CONTROL "ЦП 20",IDC_CPU20,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,80,41,10 - CONTROL "ЦП 21",IDC_CPU21,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,93,41,10 - CONTROL "ЦП 22",IDC_CPU22,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,106,41,10 - CONTROL "ЦП 23",IDC_CPU23,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,116,119,41,10 - CONTROL "ЦП 24",IDC_CPU24,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,28,41,10 - CONTROL "ЦП 25",IDC_CPU25,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,41,41,10 - CONTROL "ЦП 26",IDC_CPU26,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,54,41,10 - CONTROL "ЦП 27",IDC_CPU27,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,67,41,10 - CONTROL "ЦП 28",IDC_CPU28,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,80,41,10 - CONTROL "ЦП 29",IDC_CPU29,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,93,41,10 - CONTROL "ЦП 30",IDC_CPU30,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,106,41,10 - CONTROL "ЦП 31",IDC_CPU31,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,175,119,41,10 -END - -IDD_COLUMNS_DIALOG DIALOG DISCARDABLE 20, 20, 244, 199 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Выбор столбцов" -FONT 8, "MS Shell Dlg" -BEGIN - DEFPUSHBUTTON "OK",IDOK,132,176,50,14 - PUSHBUTTON "Отмена",IDCANCEL,186,176,50,14 - LTEXT "Выберите столбцы, которые появятся на странице процессов диспетчера задач.", - IDC_STATIC,7,4,227,19 - CONTROL "&Имя образа",IDC_IMAGENAME,"Button",BS_AUTOCHECKBOX | - WS_DISABLED | WS_TABSTOP,7,26,105,10 - CONTROL "Иденти&ф. процесса (PID)",IDC_PID,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,7,37,105,10 - CONTROL "&Загрузка ЦП",IDC_CPUUSAGE,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,48,105,10 - CONTROL "&Время ЦП",IDC_CPUTIME,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,59,105,10 - CONTROL "&Память - использование",IDC_MEMORYUSAGE,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,70,105,10 - CONTROL "Память - изме&нение",IDC_MEMORYUSAGEDELTA,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,7,81,105,10 - CONTROL "Память - &максимум",IDC_PEAKMEMORYUSAGE,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,7,92,105,10 - CONTROL "&Ошибок страницы",IDC_PAGEFAULTS,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,103,105,10 - CONTROL "Об&ъекты USER",IDC_USEROBJECTS,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,114,105,10 - CONTROL "Число чтений",IDC_IOREADS,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,125,105,10 - CONTROL "Прочитано байт",IDC_IOREADBYTES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,7,136,105,10 - CONTROL "Код се&анса",IDC_SESSIONID,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,147,105,10 - CONTROL "Им&я пользователя",IDC_USERNAME,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,7,158,105,10 - CONTROL "Ошибок &страницы - изменение",IDC_PAGEFAULTSDELTA,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,118,26,120,10 - CONTROL "Объем вирту&альной памяти",IDC_VIRTUALMEMORYSIZE,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,118,37,120,10 - CONTROL "Вы&гружаемый пул",IDC_PAGEDPOOL,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,118,48,120,10 - CONTROL "Невыгружаемый п&ул",IDC_NONPAGEDPOOL,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,118,59,120,10 - CONTROL "&Базовый приоритет",IDC_BASEPRIORITY,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,118,70,120,10 - CONTROL "Счетчик &дескрипторов",IDC_HANDLECOUNT,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,118,81,120,10 - CONTROL "С&четчик потоков",IDC_THREADCOUNT,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,118,92,120,10 - CONTROL "Объ&екты GDI",IDC_GDIOBJECTS,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,118,103,120,10 - CONTROL "Число записей",IDC_IOWRITES,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,118,114,120,10 - CONTROL "Записано байт",IDC_IOWRITEBYTES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,118,125,120,10 - CONTROL "Прочий ввод-вывод",IDC_IOOTHER,"Button",BS_AUTOCHECKBOX | - WS_TABSTOP,118,136,120,10 - CONTROL "Прочих байт при вводе-выводе",IDC_IOOTHERBYTES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,118,147,120,10 -END - -/* - String Table -*/ - -STRINGTABLE DISCARDABLE -BEGIN - IDS_APP_TITLE "Диспетчер задач" - IDC_TASKMGR "Диспетчер задач" - IDS_RUNDLG_CAPTION "Создать новую задачу" -END - -STRINGTABLE DISCARDABLE -BEGIN - ID_FILE_NEW "Запускает новую программу" - ID_OPTIONS_ALWAYSONTOP "Окно Диспетчера задач отображается поверх других окон, если не свернуто" - ID_OPTIONS_MINIMIZEONUSE - "Окно Диспетчера задач свертывается при выполнении переключения" - ID_OPTIONS_HIDEWHENMINIMIZED "Скрывает свернутое окно Диспетчера задач" - ID_VIEW_REFRESH "Вызывает немедленное обновление окна Диспетчера задач" - ID_VIEW_LARGE "Отображает задачи в виде крупных значков" - ID_VIEW_SMALL "Отображает задачи в виде мелких значков" - ID_VIEW_DETAILS "Отображает дополнительную информацию о задачах" - ID_VIEW_UPDATESPEED_HIGH "Обновляет изображение два раза в секунду" - ID_VIEW_UPDATESPEED_NORMAL "Обновляет изображение один раз в две секунды" - ID_VIEW_UPDATESPEED_LOW "Обновляет изображение один раз в четыре секунды" -END - -STRINGTABLE DISCARDABLE -BEGIN -ID_VIEW_UPDATESPEED_PAUSED "Изображение не обновляется автоматически" - ID_WINDOWS_TILEHORIZONTALLY - "Размещает выбранные окна слева направо" - ID_WINDOWS_TILEVERTICALLY "Размещает выбранные окна одно над другим" - ID_WINDOWS_MINIMIZE "Свертывает окна выбранных задач" - ID_WINDOWS_MAXIMIZE "Развертывает окна на весь рабочий стол" - ID_WINDOWS_CASCADE "Размещает выбранные окна каскадом" - ID_WINDOWS_BRINGTOFRONT "Перемещает окно на передний план, но не активизирует его" - ID_HELP_TOPICS "Открывает окно встроенной справки Диспетчера задач" - ID_HELP_ABOUT "Вывод сведений о программе, ее версии и авторских правах" - ID_FILE_EXIT "Завершает Диспетчер задач" - ID_OPTIONS_SHOW16BITTASKS - "Отображает 16-разрядные задачи, обрабатываемые ntvdm.exe" - ID_VIEW_SELECTCOLUMNS "Определяет список столбцов, отображаемых на вкладке Процессы" - ID_VIEW_SHOWKERNELTIMES "Отображает время ядра на графиках загруженности" - ID_VIEW_CPUHISTORY_ONEGRAPHALL - "Один хронологический график общей загрузки ЦП" - ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU "Каждому ЦП соответствует свой график" - ID_APPLICATION_PAGE_SWITCHTO - "Перемещает задачи на передний план и передает им управление" -END - -STRINGTABLE DISCARDABLE -BEGIN - ID_ENDTASK "Завершает выбранный процесс" - ID_GOTOPROCESS "Переключает фокус на процесс выбранной задачи" - ID_RESTORE "Восстанавливает скрытое окно Диспетчера задач" - ID_PROCESS_PAGE_ENDPROCESS "Удаляет процесс из системы" - ID_PROCESS_PAGE_ENDPROCESSTREE - "Удаляет из системы этот процесс и всех его потомков." - ID_PROCESS_PAGE_DEBUG "Применяет отладчик к этому процессу" - ID_PROCESS_PAGE_SETAFFINITY - "Устанавливает, какие ЦП может использовать процесс" - ID_PROCESS_PAGE_SETPRIORITY_REALTIME - "Устанавливает класс приоритета РЕАЛЬНОГО ВРЕМЕНИ для процесса" - ID_PROCESS_PAGE_SETPRIORITY_HIGH "Устанавливает класс приоритета ВЫСОКИЙ для процесса" - ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL - "Устанавливает класс приоритета ВЫШЕ СРЕДНЕГО для процесса" - ID_PROCESS_PAGE_SETPRIORITY_NORMAL - "Устанавливает класс приоритета СРЕДНИЙ для процесса" - ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL - "Устанавливает класс приоритета НИЖЕ СРЕДНЕГО для процесса" - ID_PROCESS_PAGE_SETPRIORITY_LOW "Устанавливает класс приоритета НИЗКИЙ для процесса" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_VIEW_LARGE "&Крупные значки" - IDS_VIEW_SMALL "&Мелкие значки" - IDS_VIEW_DETAILS "&Таблица" - IDS_WINDOWS "&Окна" - IDS_VIEW_SELECTCOLUMNS "&Выбрать столбцы..." - IDS_OPTIONS_SHOW16BITTASKS "&Отображать 16-разрядные задачи" - IDS_VIEW_CPUHISTORY "&Загрузка ЦП" - IDS_VIEW_CPUHISTORY_ONEGRAPHALL "&Один график на все ЦП" - IDS_VIEW_CPUHISTORY_ONEGRAPHPERCPU "&По графику на каждый ЦП" - IDS_VIEW_SHOWKERNELTIMES "&Вывод времени ядра" - IDS_APPLICATIONS "Приложения" - IDS_PROCESSES "Процессы" - IDS_PERFORMANCE "Быстродействие" - IDS_STATUS_BAR_CPU_USAGE "Загрузка ЦП: %3d%%" - IDS_STATUS_BAR_PROCESSES "Процессов: %d" - IDS_STATUS_BAR_MEMORY_USAGE "Выделение памяти: %dK / %dK" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_IMAGENAME "Имя образа" - IDS_PID "PID" - IDS_CPUUSAGE "ЦП" - IDS_CPUTIME "Время ЦП" - IDS_MEMORYUSAGE "Память" - IDS_MEMORYUSAGEDELTA "Память (изм)" - IDS_PEAKMEMORYUSAGE "Пиковое использование памяти" - IDS_PAGEFAULTS "Ош. стр." - IDS_USEROBJECTS "Объекты USER" - IDS_IOREADS "Число чтений" - IDS_IOREADBYTES "Прочитано байт" - IDS_SESSIONID "Код сеанса" - IDS_USERNAME "Имя пользователя" - IDS_PAGEFAULTSDELTA "Ош. стр. (изм)" - IDS_VIRTUALMEMORYSIZE "Объём виртуальной памяти" - IDS_PAGEDPOOL "Выгр. п." - IDS_NONPAGEDPOOL "Н. выгр. пул." - IDS_BASEPRIORITY "Баз. пр" - IDS_HANDLECOUNT "Дескр." - IDS_THREADCOUNT "Потоков" - IDS_GDIOBJECTS "Объекты GDI" - IDS_IOWRITES "Число записей" - IDS_IOWRITEBYTES "Записано байт" - IDS_IOOTHER "Прочий ввод-вывод" - IDS_IOOTHERBYTES "Прочих байт при вводе-выводе" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_WARNING_TITLE "Предупреждение диспетчера задач" - IDS_PRIORITY_CHANGE_MESSAGE "ВНИМАНИЕ! Изменение класса приоритета этого \n\процесса может привести к нежелательным результатам, \n\в том числе к нестабильной работе системы. Вы \n\действительно хотите изменить класс приоритета?" - IDS_PRIORITY_UNABLE2CHANGE "Невозможно сменить приоритет." - IDS_TERMINATE_MESSAGE "ВНИМАНИЕ! Завершение процесса может \nпривести к нежелательным результатам, в том числе \nк потере данных или к нестабильной работе системы. \nВы действительно хотите завершить процесс?" - IDS_TERMINATE_UNABLE2TERMINATE "Невозможно завершить процесс" - IDS_DEBUG_MESSAGE "ВНИМАНИЕ! Отладка этого процесса может привести к потере данных.\nВы действительно хотите использовать отладчик?" - IDS_AFFINITY_ERROR_MESSAGE "Процессу должен соответствовать хотя бы один ЦП." - IDS_AFFINITY_ERROR_TITLE "Неправильный параметр" - IDS_AFFINITY_UNABLE2ACCESS "Невозможно получить доступ или установить соответствие процесса" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_SYSTEM_IDLE_PROCESS "Бездействие системы" - IDS_APPLICATION_NOT_RESPONDING "Не отвечает" - IDS_APPLICATION_RUNNING "Работает" - IDS_APPLICATION_TASK "Задача" - IDS_APPLICATION_STATUS "Состояние" - IDS_DEBUG_CHANNEL "Каналы отладки" - IDS_DEBUG_CHANNEL_FIXME "Fixme" - IDS_DEBUG_CHANNEL_ERR "Err" - IDS_DEBUG_CHANNEL_WARN "Warn" - IDS_DEBUG_CHANNEL_TRACE "Trace" -END +/* + * Task Manager (Russian resources) + * + * Copyright 2008 Vladimir Pankratov + * + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT + +/* + Menu +*/ + +IDR_TASKMANAGER MENU DISCARDABLE +BEGIN + POPUP "&Ôàéë" + BEGIN + MENUITEM "&Íîâàÿ çàäà÷à (Âûïîëíèòü...)", ID_FILE_NEW + MENUITEM SEPARATOR + MENUITEM "&Çàâåðøåíèå äèñïåò÷åðà çàäà÷", ID_FILE_EXIT + END + POPUP "&Ïàðàìåòðû" + BEGIN + MENUITEM "Ïîâå&ðõ îñòàëüíûõ îêîí", ID_OPTIONS_ALWAYSONTOP + , CHECKED + MENUITEM "&Ñâîðà÷èâàòü ïîñëå îáðàùåíèÿ", ID_OPTIONS_MINIMIZEONUSE + , CHECKED + MENUITEM "Ñ&êðûâàòü ñâåðíóòîå", ID_OPTIONS_HIDEWHENMINIMIZED + , CHECKED + MENUITEM "&Îòîáðàæàòü 16-ðàçðÿäíûå ïðîãðàììû", ID_OPTIONS_SHOW16BITTASKS + , CHECKED + END + POPUP "&Âèä" + BEGIN + MENUITEM "&Îáíîâèòü", ID_VIEW_REFRESH + POPUP "&Ñêîðîñòü îáíîâëåíèÿ" + BEGIN + MENUITEM "&Âûñîêàÿ", ID_VIEW_UPDATESPEED_HIGH + MENUITEM "&Îáû÷íàÿ", ID_VIEW_UPDATESPEED_NORMAL + , CHECKED + MENUITEM "&Íèçêàÿ", ID_VIEW_UPDATESPEED_LOW + MENUITEM "&Ïðèîñòàíîâèòü", ID_VIEW_UPDATESPEED_PAUSED + + END + MENUITEM SEPARATOR + MENUITEM "&Êðóïíûå çíà÷êè", ID_VIEW_LARGE + MENUITEM "&Ìåëêèå çíà÷êè", ID_VIEW_SMALL + MENUITEM "&Òàáëèöà", ID_VIEW_DETAILS, CHECKED + MENUITEM "Â&ûáðàòü ñòîëáöû...", ID_VIEW_SELECTCOLUMNS + POPUP "&Çàãðóçêà ÖÏ" + BEGIN + MENUITEM "&Îäèí ãðàôèê íà âñå ÖÏ", ID_VIEW_CPUHISTORY_ONEGRAPHALL + + MENUITEM "&Ïî ãðàôèêó íà êàæäûé ÖÏ", ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU + , CHECKED + END + MENUITEM "&Âûâîä âðåìåíè ÿäðà", ID_VIEW_SHOWKERNELTIMES + END + POPUP "&Îêíà" + BEGIN + MENUITEM "Ñ&ëåâà íàïðàâî", ID_WINDOWS_TILEHORIZONTALLY + MENUITEM "Ñ&âåðõó âíèç", ID_WINDOWS_TILEVERTICALLY + MENUITEM "&Ñâåðíóòü", ID_WINDOWS_MINIMIZE + MENUITEM "&Ðàçâåðíóòü", ID_WINDOWS_MAXIMIZE + MENUITEM "&Êàñêàäîì", ID_WINDOWS_CASCADE + MENUITEM "&Íà ïåðåäíèé ïëàí", ID_WINDOWS_BRINGTOFRONT + END + POPUP "&Ñïðàâêà" + BEGIN + MENUITEM "&Âûçîâ ñïðàâêè", ID_HELP_TOPICS + MENUITEM SEPARATOR + MENUITEM "&Î ïðîãðàììå", ID_HELP_ABOUT + END +END + +IDR_WINDOWSMENU MENU DISCARDABLE +BEGIN + MENUITEM "Ñ&ëåâà íàïðàâî", ID_WINDOWS_TILEHORIZONTALLY + MENUITEM "Ñ&âåðõó âíèç", ID_WINDOWS_TILEVERTICALLY + MENUITEM "&Ñâåðíóòü", ID_WINDOWS_MINIMIZE + MENUITEM "&Ðàçâåðíóòü", ID_WINDOWS_MAXIMIZE + MENUITEM "&Êàñêàäîì", ID_WINDOWS_CASCADE + MENUITEM "&Íà ïåðåäíèé ïëàí", ID_WINDOWS_BRINGTOFRONT +END + +IDR_APPLICATION_PAGE_CONTEXT1 MENU DISCARDABLE +BEGIN + POPUP "DUMMY" + BEGIN + MENUITEM "&Íîâàÿ çàäà÷à (Âûïîëíèòü...)", ID_FILE_NEW + MENUITEM SEPARATOR + MENUITEM "&Êðóïíûå çíà÷êè", ID_VIEW_LARGE + MENUITEM "&Ìåëêèå çíà÷êè", ID_VIEW_SMALL + MENUITEM "&Òàáëèöà", ID_VIEW_DETAILS, CHECKED + END +END + +IDR_APPLICATION_PAGE_CONTEXT2 MENU DISCARDABLE +BEGIN + POPUP "DUMMY" + BEGIN + MENUITEM "&Ïåðåêëþ÷èòüñÿ", ID_APPLICATION_PAGE_SWITCHTO + MENUITEM "&Íà ïåðåäíèé ïëàí", ID_WINDOWS_BRINGTOFRONT + MENUITEM SEPARATOR + MENUITEM "Ñ&ëåâà íàïðàâî", ID_WINDOWS_TILEHORIZONTALLY + MENUITEM "Ñ&âåðõó âíèç", ID_WINDOWS_TILEVERTICALLY + MENUITEM "&Ñâåðíóòü", ID_WINDOWS_MINIMIZE + MENUITEM "&Ðàçâåðíóòü", ID_WINDOWS_MAXIMIZE + MENUITEM "&Êàñêàäîì", ID_WINDOWS_CASCADE + MENUITEM SEPARATOR + MENUITEM "Ñíÿòü &çàäà÷ó", ID_APPLICATION_PAGE_ENDTASK + MENUITEM "&Ïåðåéòè ê ïðîöåññàì", ID_APPLICATION_PAGE_GOTOPROCESS + END +END + +IDR_TRAY_POPUP MENU DISCARDABLE +BEGIN + POPUP "DUMMY" + BEGIN + MENUITEM "&Âîññòàíîâèòü", ID_RESTORE + MENUITEM "&Çàêðûòü", ID_FILE_EXIT + MENUITEM SEPARATOR + MENUITEM "Ïîâå&ðõ îñòàëüíûõ îêîí", ID_OPTIONS_ALWAYSONTOP + END +END + +IDR_PROCESS_PAGE_CONTEXT MENU DISCARDABLE +BEGIN + POPUP "DUMMY" + BEGIN + MENUITEM "&Çàâåðøèòü ïðîöåññ", ID_PROCESS_PAGE_ENDPROCESS + MENUITEM "Çàâåðøèòü &äåðåâî ïðîöåññîâ", ID_PROCESS_PAGE_ENDPROCESSTREE + + MENUITEM "&Îòëàäêà", ID_PROCESS_PAGE_DEBUG + MENUITEM SEPARATOR + POPUP "&Ïðèîðèòåò" + BEGIN + MENUITEM "&Ðåàëüíîãî âðåìåíè", ID_PROCESS_PAGE_SETPRIORITY_REALTIME + + MENUITEM "&Âûñîêèé", ID_PROCESS_PAGE_SETPRIORITY_HIGH + + MENUITEM "Â&ûøå ñðåäíåãî", ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL + + MENUITEM "&Ñðåäíèé", ID_PROCESS_PAGE_SETPRIORITY_NORMAL + + MENUITEM "Í&èæå ñðåäíåãî", ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL + + MENUITEM "&Íèçêèé", ID_PROCESS_PAGE_SETPRIORITY_LOW + + END + MENUITEM "Çàäàòü &ñîîòâåòñòâèå...", ID_PROCESS_PAGE_SETAFFINITY + MENUITEM "Ðåäàêòèðîâàòü &êàíàëû îòëàäêè...", ID_PROCESS_PAGE_DEBUGCHANNELS + END +END + +/* + Dialog +*/ + +IDD_TASKMGR_DIALOG DIALOG DISCARDABLE 0, 0, 264, 246 +STYLE DS_CENTER | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | + WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU | + WS_THICKFRAME +CAPTION "Äèñïåò÷åð çàäà÷" +MENU IDR_TASKMANAGER +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL "Tab1",IDC_TAB,"SysTabControl32",WS_TABSTOP,3,3,257,228 +END + +IDD_APPLICATION_PAGE DIALOG DISCARDABLE 0, 0, 247, 210 +STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL "List2",IDC_APPLIST,"SysListView32",LVS_REPORT | + LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,233,177 + PUSHBUTTON "&Íîâàÿ çàäà÷à...",IDC_NEWTASK,177,189,63,14 + PUSHBUTTON "Ï&åðåêëþ÷èòüñÿ",IDC_SWITCHTO,111,189,63,14,WS_DISABLED + PUSHBUTTON "Ñíÿòü &çàäà÷ó",IDC_ENDTASK,45,189,63,14,WS_DISABLED +END + +IDD_PROCESS_PAGE DIALOG DISCARDABLE 0, 0, 247, 210 +STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL "List2",IDC_PROCESSLIST,"SysListView32",LVS_REPORT | + LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_OWNERDATA | + WS_BORDER | WS_TABSTOP,7,7,233,177 + PUSHBUTTON "&Çàâåðøèòü ïðîöåññ",IDC_ENDPROCESS,171,189,69,14 + CONTROL "&Îòîáðàæàòü ïðîöåññû âñåõ ïîëüçîâàòåëåé",IDC_SHOWALLPROCESSES, + "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,191,157,10 +END + +/*IDD_PERFORMANCE_PAGE DIALOGEX 0, 0, 247, 210*/ +IDD_PERFORMANCE_PAGE DIALOGEX DISCARDABLE 0, 0, 247, 210 +STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Çàãðóçêà ÖÏ",IDC_CPU_USAGE_FRAME,5,5,60,54,WS_TABSTOP, WS_EX_TRANSPARENT + GROUPBOX "Ôàéë ïîäêà÷êè",IDC_MEM_USAGE_FRAME,5,63,60,54,BS_LEFTTEXT, WS_EX_TRANSPARENT + GROUPBOX "Âñåãî",IDC_TOTALS_FRAME,5,122,111,39,0,WS_EX_TRANSPARENT + GROUPBOX "Âûäåëåíèå ïàìÿòè (ÊÁ)",IDC_COMMIT_CHARGE_FRAME,5,166,111,39,0,WS_EX_TRANSPARENT + GROUPBOX "Ôèçè÷åñêàÿ ïàìÿòü (ÊÁ)",IDC_PHYSICAL_MEMORY_FRAME,131,122,111,39,0,WS_EX_TRANSPARENT + GROUPBOX "Ïàìÿòü ÿäðà (ÊÁ)",IDC_KERNEL_MEMORY_FRAME,131,166,111,39,0,WS_EX_TRANSPARENT + LTEXT "Äåñêðèïòîðîâ",IDS_TOTALS_HANDLE_COUNT,12,131,80,8 + LTEXT "Ïîòîêîâ",IDS_TOTALS_THREAD_COUNT,12,140,27,8 + LTEXT "Ïðîöåññîâ",IDS_TOTALS_PROCESS_COUNT,12,149,35,8 + EDITTEXT IDC_TOTALS_HANDLE_COUNT,65,131,45,8,ES_RIGHT | + ES_READONLY | ES_NUMBER | NOT WS_BORDER + EDITTEXT IDC_TOTALS_THREAD_COUNT,65,140,45,8,ES_RIGHT | + ES_READONLY | ES_NUMBER | NOT WS_BORDER + EDITTEXT IDC_TOTALS_PROCESS_COUNT,65,149,45,8,ES_RIGHT | + ES_READONLY | ES_NUMBER | NOT WS_BORDER + LTEXT "Âñåãî",IDS_COMMIT_CHARGE_TOTAL,12,175,27,8 + LTEXT "Ïðåäåë",IDS_COMMIT_CHARGE_LIMIT,12,184,50,8 + LTEXT "Ïèê",IDS_COMMIT_CHARGE_PEAK,12,193,34,8 + EDITTEXT IDC_COMMIT_CHARGE_TOTAL,65,174,45,8,ES_RIGHT | + ES_READONLY | ES_NUMBER | NOT WS_BORDER + EDITTEXT IDC_COMMIT_CHARGE_LIMIT,65,184,45,8,ES_RIGHT | + ES_READONLY | ES_NUMBER | NOT WS_BORDER + EDITTEXT IDC_COMMIT_CHARGE_PEAK,65,193,45,8,ES_RIGHT | + ES_READONLY | ES_NUMBER | NOT WS_BORDER + LTEXT "Âñåãî",IDS_PHYSICAL_MEMORY_TOTAL,137,131,27,8 + LTEXT "Äîñòóïíî",IDS_PHYSICAL_MEMORY_AVAILABLE,137,140,31,8 + LTEXT "Ñèñòåìíûé êåø",IDS_PHYSICAL_MEMORY_SYSTEM_CACHE,137,149,46,8 + EDITTEXT IDC_PHYSICAL_MEMORY_TOTAL,185,131,48,8,ES_RIGHT | + ES_READONLY | ES_NUMBER | NOT WS_BORDER + EDITTEXT IDC_PHYSICAL_MEMORY_AVAILABLE,185,140,48,8,ES_RIGHT | + ES_READONLY | ES_NUMBER | NOT WS_BORDER + EDITTEXT IDC_PHYSICAL_MEMORY_SYSTEM_CACHE,185,149,48,8,ES_RIGHT | + ES_READONLY | ES_NUMBER | NOT WS_BORDER + LTEXT "Âñåãî",IDS_KERNEL_MEMORY_TOTAL,137,174,27,8 + LTEXT "Âûãðóæàåìàÿ",IDS_KERNEL_MEMORY_PAGED,137,184,70,8 + LTEXT "Íåâûãðóæ.",IDS_KERNEL_MEMORY_NONPAGED,137,193,70,8 + EDITTEXT IDC_KERNEL_MEMORY_TOTAL,185,174,48,8,ES_RIGHT | + ES_READONLY | ES_NUMBER | NOT WS_BORDER + EDITTEXT IDC_KERNEL_MEMORY_PAGED,185,184,48,8,ES_RIGHT | + ES_READONLY | ES_NUMBER | NOT WS_BORDER + EDITTEXT IDC_KERNEL_MEMORY_NONPAGED,185,193,48,8,ES_RIGHT | + ES_READONLY | ES_NUMBER | NOT WS_BORDER + GROUPBOX "Õðîíîëîãèÿ çàãðóçêè ÖÏ",IDC_CPU_USAGE_HISTORY_FRAME,74,5,168,54,0,WS_EX_TRANSPARENT + GROUPBOX "Õðîíîëîãèÿ èñïîëüçîâàíèÿ ôàéëà ïîäêà÷êè",IDC_MEMORY_USAGE_HISTORY_FRAME,74,63,168,54,0,WS_EX_TRANSPARENT + PUSHBUTTON "Õðîíîëîãèÿ çàãðóçêè ÖÏ",IDC_CPU_USAGE_GRAPH,12,17,47,37,0, + WS_EX_CLIENTEDGE + PUSHBUTTON "Ôàéë ïîäêà÷êè",IDC_MEM_USAGE_GRAPH,12,75,47,37,0, + WS_EX_CLIENTEDGE + PUSHBUTTON "Õðîíîëîãèÿ çàãðóçêè ÖÏ",IDC_CPU_USAGE_HISTORY_GRAPH,81,17, + 153,37,0,WS_EX_CLIENTEDGE + PUSHBUTTON "Ôàéë ïîäêà÷êè",IDC_MEM_USAGE_HISTORY_GRAPH,81,75, + 153,37,0,WS_EX_CLIENTEDGE +END + +IDD_DEBUG_CHANNELS_DIALOG DIALOG DISCARDABLE 0, 0, 247, 210 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Êàíàëû îòëàäêè" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL "List2",IDC_DEBUG_CHANNELS_LIST,"SysListView32",LVS_REPORT | + LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP | + LVS_SORTASCENDING,7,7,233,177 + PUSHBUTTON "Çàêðûòü",IDOK,171,189,69,14 +END + +IDD_AFFINITY_DIALOG DIALOG DISCARDABLE 0, 0, 231, 154 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Ñîîòâåòñòâèå ïðîöåññîðîâ" +FONT 8, "MS Shell Dlg" +BEGIN + DEFPUSHBUTTON "OK",IDOK,120,133,50,14 + PUSHBUTTON "Îòìåíà",IDCANCEL,174,133,50,14 + LTEXT "Ñîîòâåòñòâèå ïðîöåññîðîâ îïðåäåëÿåò, êàêîé ÖÏ ðàçðåøåíî èñïîëüçîâàòü ïðîöåññó.", + IDC_STATIC,5,5,220,16 + CONTROL "ÖÏ 0",IDC_CPU0,"Button",BS_AUTOCHECKBOX | WS_TABSTOP, + 11,28,37,10 + CONTROL "ÖÏ 1",IDC_CPU1,"Button",BS_AUTOCHECKBOX | WS_DISABLED | + WS_TABSTOP,11,41,37,10 + CONTROL "ÖÏ 2",IDC_CPU2,"Button",BS_AUTOCHECKBOX | WS_DISABLED | + WS_TABSTOP,11,54,37,10 + CONTROL "ÖÏ 3",IDC_CPU3,"Button",BS_AUTOCHECKBOX | WS_DISABLED | + WS_TABSTOP,11,67,37,10 + CONTROL "ÖÏ 4",IDC_CPU4,"Button",BS_AUTOCHECKBOX | WS_DISABLED | + WS_TABSTOP,11,80,37,10 + CONTROL "ÖÏ 5",IDC_CPU5,"Button",BS_AUTOCHECKBOX | WS_DISABLED | + WS_TABSTOP,11,93,37,10 + CONTROL "ÖÏ 6",IDC_CPU6,"Button",BS_AUTOCHECKBOX | WS_DISABLED | + WS_TABSTOP,11,106,37,10 + CONTROL "ÖÏ 7",IDC_CPU7,"Button",BS_AUTOCHECKBOX | WS_DISABLED | + WS_TABSTOP,11,119,37,10 + CONTROL "ÖÏ 8",IDC_CPU8,"Button",BS_AUTOCHECKBOX | WS_DISABLED | + WS_TABSTOP,61,28,37,10 + CONTROL "ÖÏ 9",IDC_CPU9,"Button",BS_AUTOCHECKBOX | WS_DISABLED | + WS_TABSTOP,61,41,37,10 + CONTROL "ÖÏ 10",IDC_CPU10,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,61,54,41,10 + CONTROL "ÖÏ 11",IDC_CPU11,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,61,67,41,10 + CONTROL "ÖÏ 12",IDC_CPU12,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,61,80,41,10 + CONTROL "ÖÏ 13",IDC_CPU13,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,61,93,41,10 + CONTROL "ÖÏ 14",IDC_CPU14,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,61,106,41,10 + CONTROL "ÖÏ 15",IDC_CPU15,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,61,119,41,10 + CONTROL "ÖÏ 16",IDC_CPU16,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,116,28,41,10 + CONTROL "ÖÏ 17",IDC_CPU17,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,116,41,41,10 + CONTROL "ÖÏ 18",IDC_CPU18,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,116,54,41,10 + CONTROL "ÖÏ 19",IDC_CPU19,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,116,67,41,10 + CONTROL "ÖÏ 20",IDC_CPU20,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,116,80,41,10 + CONTROL "ÖÏ 21",IDC_CPU21,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,116,93,41,10 + CONTROL "ÖÏ 22",IDC_CPU22,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,116,106,41,10 + CONTROL "ÖÏ 23",IDC_CPU23,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,116,119,41,10 + CONTROL "ÖÏ 24",IDC_CPU24,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,175,28,41,10 + CONTROL "ÖÏ 25",IDC_CPU25,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,175,41,41,10 + CONTROL "ÖÏ 26",IDC_CPU26,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,175,54,41,10 + CONTROL "ÖÏ 27",IDC_CPU27,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,175,67,41,10 + CONTROL "ÖÏ 28",IDC_CPU28,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,175,80,41,10 + CONTROL "ÖÏ 29",IDC_CPU29,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,175,93,41,10 + CONTROL "ÖÏ 30",IDC_CPU30,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,175,106,41,10 + CONTROL "ÖÏ 31",IDC_CPU31,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,175,119,41,10 +END + +IDD_COLUMNS_DIALOG DIALOG DISCARDABLE 20, 20, 244, 199 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Âûáîð ñòîëáöîâ" +FONT 8, "MS Shell Dlg" +BEGIN + DEFPUSHBUTTON "OK",IDOK,132,176,50,14 + PUSHBUTTON "Îòìåíà",IDCANCEL,186,176,50,14 + LTEXT "Âûáåðèòå ñòîëáöû, êîòîðûå ïîÿâÿòñÿ íà ñòðàíèöå ïðîöåññîâ äèñïåò÷åðà çàäà÷.", + IDC_STATIC,7,4,227,19 + CONTROL "&Èìÿ îáðàçà",IDC_IMAGENAME,"Button",BS_AUTOCHECKBOX | + WS_DISABLED | WS_TABSTOP,7,26,105,10 + CONTROL "Èäåíòè&ô. ïðîöåññà (PID)",IDC_PID,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,7,37,105,10 + CONTROL "&Çàãðóçêà ÖÏ",IDC_CPUUSAGE,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,7,48,105,10 + CONTROL "&Âðåìÿ ÖÏ",IDC_CPUTIME,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,7,59,105,10 + CONTROL "&Ïàìÿòü - èñïîëüçîâàíèå",IDC_MEMORYUSAGE,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,7,70,105,10 + CONTROL "Ïàìÿòü - èçìå&íåíèå",IDC_MEMORYUSAGEDELTA,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,7,81,105,10 + CONTROL "Ïàìÿòü - &ìàêñèìóì",IDC_PEAKMEMORYUSAGE,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,7,92,105,10 + CONTROL "&Îøèáîê ñòðàíèöû",IDC_PAGEFAULTS,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,7,103,105,10 + CONTROL "Îá&úåêòû USER",IDC_USEROBJECTS,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,7,114,105,10 + CONTROL "×èñëî ÷òåíèé",IDC_IOREADS,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,7,125,105,10 + CONTROL "Ïðî÷èòàíî áàéò",IDC_IOREADBYTES,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,7,136,105,10 + CONTROL "Êîä ñå&àíñà",IDC_SESSIONID,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,7,147,105,10 + CONTROL "Èì&ÿ ïîëüçîâàòåëÿ",IDC_USERNAME,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,7,158,105,10 + CONTROL "Îøèáîê &ñòðàíèöû - èçìåíåíèå",IDC_PAGEFAULTSDELTA,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,118,26,120,10 + CONTROL "Îáúåì âèðòó&àëüíîé ïàìÿòè",IDC_VIRTUALMEMORYSIZE,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,118,37,120,10 + CONTROL "Âû&ãðóæàåìûé ïóë",IDC_PAGEDPOOL,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,118,48,120,10 + CONTROL "Íåâûãðóæàåìûé ï&óë",IDC_NONPAGEDPOOL,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,118,59,120,10 + CONTROL "&Áàçîâûé ïðèîðèòåò",IDC_BASEPRIORITY,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,118,70,120,10 + CONTROL "Ñ÷åò÷èê &äåñêðèïòîðîâ",IDC_HANDLECOUNT,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,118,81,120,10 + CONTROL "Ñ&÷åò÷èê ïîòîêîâ",IDC_THREADCOUNT,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,118,92,120,10 + CONTROL "Îáú&åêòû GDI",IDC_GDIOBJECTS,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,118,103,120,10 + CONTROL "×èñëî çàïèñåé",IDC_IOWRITES,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,118,114,120,10 + CONTROL "Çàïèñàíî áàéò",IDC_IOWRITEBYTES,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,118,125,120,10 + CONTROL "Ïðî÷èé ââîä-âûâîä",IDC_IOOTHER,"Button",BS_AUTOCHECKBOX | + WS_TABSTOP,118,136,120,10 + CONTROL "Ïðî÷èõ áàéò ïðè ââîäå-âûâîäå",IDC_IOOTHERBYTES,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,118,147,120,10 +END + +/* + String Table +*/ + +STRINGTABLE DISCARDABLE +BEGIN + IDS_APP_TITLE "Äèñïåò÷åð çàäà÷" + IDC_TASKMGR "Äèñïåò÷åð çàäà÷" + IDS_RUNDLG_CAPTION "Ñîçäàòü íîâóþ çàäà÷ó" +END + +STRINGTABLE DISCARDABLE +BEGIN + ID_FILE_NEW "Çàïóñêàåò íîâóþ ïðîãðàììó" + ID_OPTIONS_ALWAYSONTOP "Îêíî Äèñïåò÷åðà çàäà÷ îòîáðàæàåòñÿ ïîâåðõ äðóãèõ îêîí, åñëè íå ñâåðíóòî" + ID_OPTIONS_MINIMIZEONUSE + "Îêíî Äèñïåò÷åðà çàäà÷ ñâåðòûâàåòñÿ ïðè âûïîëíåíèè ïåðåêëþ÷åíèÿ" + ID_OPTIONS_HIDEWHENMINIMIZED "Ñêðûâàåò ñâåðíóòîå îêíî Äèñïåò÷åðà çàäà÷" + ID_VIEW_REFRESH "Âûçûâàåò íåìåäëåííîå îáíîâëåíèå îêíà Äèñïåò÷åðà çàäà÷" + ID_VIEW_LARGE "Îòîáðàæàåò çàäà÷è â âèäå êðóïíûõ çíà÷êîâ" + ID_VIEW_SMALL "Îòîáðàæàåò çàäà÷è â âèäå ìåëêèõ çíà÷êîâ" + ID_VIEW_DETAILS "Îòîáðàæàåò äîïîëíèòåëüíóþ èíôîðìàöèþ î çàäà÷àõ" + ID_VIEW_UPDATESPEED_HIGH "Îáíîâëÿåò èçîáðàæåíèå äâà ðàçà â ñåêóíäó" + ID_VIEW_UPDATESPEED_NORMAL "Îáíîâëÿåò èçîáðàæåíèå îäèí ðàç â äâå ñåêóíäû" + ID_VIEW_UPDATESPEED_LOW "Îáíîâëÿåò èçîáðàæåíèå îäèí ðàç â ÷åòûðå ñåêóíäû" +END + +STRINGTABLE DISCARDABLE +BEGIN +ID_VIEW_UPDATESPEED_PAUSED "Èçîáðàæåíèå íå îáíîâëÿåòñÿ àâòîìàòè÷åñêè" + ID_WINDOWS_TILEHORIZONTALLY + "Ðàçìåùàåò âûáðàííûå îêíà ñëåâà íàïðàâî" + ID_WINDOWS_TILEVERTICALLY "Ðàçìåùàåò âûáðàííûå îêíà îäíî íàä äðóãèì" + ID_WINDOWS_MINIMIZE "Ñâåðòûâàåò îêíà âûáðàííûõ çàäà÷" + ID_WINDOWS_MAXIMIZE "Ðàçâåðòûâàåò îêíà íà âåñü ðàáî÷èé ñòîë" + ID_WINDOWS_CASCADE "Ðàçìåùàåò âûáðàííûå îêíà êàñêàäîì" + ID_WINDOWS_BRINGTOFRONT "Ïåðåìåùàåò îêíî íà ïåðåäíèé ïëàí, íî íå àêòèâèçèðóåò åãî" + ID_HELP_TOPICS "Îòêðûâàåò îêíî âñòðîåííîé ñïðàâêè Äèñïåò÷åðà çàäà÷" + ID_HELP_ABOUT "Âûâîä ñâåäåíèé î ïðîãðàììå, åå âåðñèè è àâòîðñêèõ ïðàâàõ" + ID_FILE_EXIT "Çàâåðøàåò Äèñïåò÷åð çàäà÷" + ID_OPTIONS_SHOW16BITTASKS + "Îòîáðàæàåò 16-ðàçðÿäíûå çàäà÷è, îáðàáàòûâàåìûå ntvdm.exe" + ID_VIEW_SELECTCOLUMNS "Îïðåäåëÿåò ñïèñîê ñòîëáöîâ, îòîáðàæàåìûõ íà âêëàäêå Ïðîöåññû" + ID_VIEW_SHOWKERNELTIMES "Îòîáðàæàåò âðåìÿ ÿäðà íà ãðàôèêàõ çàãðóæåííîñòè" + ID_VIEW_CPUHISTORY_ONEGRAPHALL + "Îäèí õðîíîëîãè÷åñêèé ãðàôèê îáùåé çàãðóçêè ÖÏ" + ID_VIEW_CPUHISTORY_ONEGRAPHPERCPU "Êàæäîìó ÖÏ ñîîòâåòñòâóåò ñâîé ãðàôèê" + ID_APPLICATION_PAGE_SWITCHTO + "Ïåðåìåùàåò çàäà÷è íà ïåðåäíèé ïëàí è ïåðåäàåò èì óïðàâëåíèå" +END + +STRINGTABLE DISCARDABLE +BEGIN + ID_ENDTASK "Çàâåðøàåò âûáðàííûé ïðîöåññ" + ID_GOTOPROCESS "Ïåðåêëþ÷àåò ôîêóñ íà ïðîöåññ âûáðàííîé çàäà÷è" + ID_RESTORE "Âîññòàíàâëèâàåò ñêðûòîå îêíî Äèñïåò÷åðà çàäà÷" + ID_PROCESS_PAGE_ENDPROCESS "Óäàëÿåò ïðîöåññ èç ñèñòåìû" + ID_PROCESS_PAGE_ENDPROCESSTREE + "Óäàëÿåò èç ñèñòåìû ýòîò ïðîöåññ è âñåõ åãî ïîòîìêîâ." + ID_PROCESS_PAGE_DEBUG "Ïðèìåíÿåò îòëàä÷èê ê ýòîìó ïðîöåññó" + ID_PROCESS_PAGE_SETAFFINITY + "Óñòàíàâëèâàåò, êàêèå ÖÏ ìîæåò èñïîëüçîâàòü ïðîöåññ" + ID_PROCESS_PAGE_SETPRIORITY_REALTIME + "Óñòàíàâëèâàåò êëàññ ïðèîðèòåòà ÐÅÀËÜÍÎÃÎ ÂÐÅÌÅÍÈ äëÿ ïðîöåññà" + ID_PROCESS_PAGE_SETPRIORITY_HIGH "Óñòàíàâëèâàåò êëàññ ïðèîðèòåòà ÂÛÑÎÊÈÉ äëÿ ïðîöåññà" + ID_PROCESS_PAGE_SETPRIORITY_ABOVENORMAL + "Óñòàíàâëèâàåò êëàññ ïðèîðèòåòà ÂÛØÅ ÑÐÅÄÍÅÃÎ äëÿ ïðîöåññà" + ID_PROCESS_PAGE_SETPRIORITY_NORMAL + "Óñòàíàâëèâàåò êëàññ ïðèîðèòåòà ÑÐÅÄÍÈÉ äëÿ ïðîöåññà" + ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL + "Óñòàíàâëèâàåò êëàññ ïðèîðèòåòà ÍÈÆÅ ÑÐÅÄÍÅÃÎ äëÿ ïðîöåññà" + ID_PROCESS_PAGE_SETPRIORITY_LOW "Óñòàíàâëèâàåò êëàññ ïðèîðèòåòà ÍÈÇÊÈÉ äëÿ ïðîöåññà" +END diff --git a/programs/taskmgr/Si.rc b/programs/taskmgr/Si.rc index 4cfe73f5ef2..670189b4ed8 100644 --- a/programs/taskmgr/Si.rc +++ b/programs/taskmgr/Si.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -488,3 +486,5 @@ BEGIN "Dodeli proces v PODPOVPREČNI prioritetni razred" ID_PROCESS_PAGE_SETPRIORITY_LOW "Dodeli proces v NIZEK prioritetni razred" END + +#pragma code_page(default) diff --git a/programs/taskmgr/Sv.rc b/programs/taskmgr/Sv.rc index a77eb61bc7e..4e177873410 100644 --- a/programs/taskmgr/Sv.rc +++ b/programs/taskmgr/Sv.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL /* diff --git a/programs/taskmgr/Tr.rc b/programs/taskmgr/Tr.rc index 1149bb3bd6b..ac22a611853 100644 --- a/programs/taskmgr/Tr.rc +++ b/programs/taskmgr/Tr.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT /* diff --git a/programs/taskmgr/Zh.rc b/programs/taskmgr/Zh.rc index 969a404bfdb..cd7c0611f6a 100644 --- a/programs/taskmgr/Zh.rc +++ b/programs/taskmgr/Zh.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -933,3 +931,5 @@ BEGIN ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL "將進程設為中等以下優先級" ID_PROCESS_PAGE_SETPRIORITY_LOW "將進程設為低優先級" END + +#pragma code_page(default) diff --git a/programs/taskmgr/affinity.c b/programs/taskmgr/affinity.c index 38dbe7e5bb4..31a4f64a6eb 100644 --- a/programs/taskmgr/affinity.c +++ b/programs/taskmgr/affinity.c @@ -35,7 +35,10 @@ HANDLE hProcessAffinityHandle; -WCHAR wszUnable2Access[255]; +static const WCHAR wszUnable2Access[] = {'U','n','a','b','l','e',' ','t','o',' ', + 'A','c','c','e','s','s',' ','o','r',' ', + 'S','e','t',' ','P','r','o','c','e','s','s',' ', + 'A','f','f','i','n','i','t','y',0}; static INT_PTR CALLBACK AffinityDialogWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) @@ -54,7 +57,6 @@ AffinityDialogWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) if (!GetProcessAffinityMask(hProcessAffinityHandle, &dwProcessAffinityMask, &dwSystemAffinityMask)) { GetLastErrorText(wstrErrorText, sizeof(wstrErrorText)/sizeof(WCHAR)); EndDialog(hDlg, 0); - LoadStringW(hInst, IDS_AFFINITY_UNABLE2ACCESS, wszUnable2Access, sizeof(wszUnable2Access)/sizeof(WCHAR)); MessageBoxW(hMainWnd, wstrErrorText, wszUnable2Access, MB_OK|MB_ICONSTOP); } @@ -290,10 +292,12 @@ AffinityDialogWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) * of it's cpu time. */ if (!dwProcessAffinityMask) { - WCHAR wszErrorMsg[255]; - WCHAR wszErrorTitle[255]; - LoadStringW(hInst, IDS_AFFINITY_ERROR_MESSAGE, wszErrorMsg, sizeof(wszErrorMsg)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_AFFINITY_ERROR_TITLE, wszErrorTitle, sizeof(wszErrorTitle)/sizeof(WCHAR)); + static const WCHAR wszErrorMsg[] = {'T','h','e',' ','p','r','o','c','e','s','s',' ', + 'm','u','s','t',' ','h','a','v','e',' ', + 'a','f','f','i','n','i','t','y',' ', + 'w','i','t','h',' ','a','t',' ','l','e','a','s','t',' ', + 'o','n','e',' ','p','r','o','c','e','s','s','o','r','.',0}; + static const WCHAR wszErrorTitle[] = {'I','n','v','a','l','i','d',' ','O','p','t','i','o','n',0}; MessageBoxW(hDlg, wszErrorMsg, wszErrorTitle, MB_OK|MB_ICONSTOP); return TRUE; } @@ -304,7 +308,6 @@ AffinityDialogWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) if (!SetProcessAffinityMask(hProcessAffinityHandle, dwProcessAffinityMask)) { GetLastErrorText(wstrErrorText, sizeof(wstrErrorText)/sizeof(WCHAR)); EndDialog(hDlg, LOWORD(wParam)); - LoadStringW(hInst, IDS_AFFINITY_UNABLE2ACCESS, wszUnable2Access, sizeof(wszUnable2Access)/sizeof(WCHAR)); MessageBoxW(hMainWnd, wstrErrorText, wszUnable2Access, MB_OK|MB_ICONSTOP); } @@ -340,7 +343,6 @@ void ProcessPage_OnSetAffinity(void) hProcessAffinityHandle = OpenProcess(PROCESS_QUERY_INFORMATION|PROCESS_SET_INFORMATION, FALSE, dwProcessId); if (!hProcessAffinityHandle) { GetLastErrorText(wstrErrorText, sizeof(wstrErrorText)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_AFFINITY_UNABLE2ACCESS, wszUnable2Access, sizeof(wszUnable2Access)/sizeof(WCHAR)); MessageBoxW(hMainWnd, wstrErrorText, wszUnable2Access, MB_OK|MB_ICONSTOP); return; } diff --git a/programs/taskmgr/applpage.c b/programs/taskmgr/applpage.c index b95888783fb..8fb923d0c97 100644 --- a/programs/taskmgr/applpage.c +++ b/programs/taskmgr/applpage.c @@ -417,11 +417,9 @@ static void ApplicationPageOnNotify(WPARAM wParam, LPARAM lParam) LV_DISPINFOW* pnmdi; LPAPPLICATION_PAGE_LIST_ITEM pAPLI; - WCHAR wszNotResponding[255]; - WCHAR wszRunning[255]; + static const WCHAR wszNotResponding[] = {'N','o','t',' ','R','e','s','p','o','n','d','i','n','g',0}; + static const WCHAR wszRunning[] = {'R','u','n','n','i','n','g',0}; - LoadStringW(hInst, IDS_APPLICATION_NOT_RESPONDING, wszNotResponding, sizeof(wszNotResponding)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_APPLICATION_RUNNING, wszRunning, sizeof(wszRunning)/sizeof(WCHAR)); idctrl = (int) wParam; pnmh = (LPNMHDR) lParam; @@ -839,11 +837,9 @@ ApplicationPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) int cx, cy; LVCOLUMNW column; - WCHAR wszTask[255]; - WCHAR wszStatus[255]; - - LoadStringW(hInst, IDS_APPLICATION_TASK, wszTask, sizeof(wszTask)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_APPLICATION_STATUS, wszStatus, sizeof(wszStatus)/sizeof(WCHAR)); + static const WCHAR wszTasks[] = {'T','a','s','k','s',0}; + static WCHAR wszTask[] = {'T','a','s','k',0}; + static WCHAR wszStatus[] = {'S','t','a','t','u','s',0}; switch (message) { case WM_INITDIALOG: @@ -862,6 +858,8 @@ ApplicationPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) hApplicationPageSwitchToButton = GetDlgItem(hDlg, IDC_SWITCHTO); hApplicationPageNewTaskButton = GetDlgItem(hDlg, IDC_NEWTASK); + SetWindowTextW(hApplicationPageListCtrl, wszTasks); + /* Initialize the application page's controls */ column.mask = LVCF_TEXT|LVCF_WIDTH; column.pszText = wszTask; diff --git a/programs/taskmgr/column.c b/programs/taskmgr/column.c index 4216d753025..f64a747dbfb 100644 --- a/programs/taskmgr/column.c +++ b/programs/taskmgr/column.c @@ -35,62 +35,33 @@ UINT ColumnDataHints[25]; /* Column Headers; Begin */ -WCHAR wszImageName[255]; -WCHAR wszPID[255]; -WCHAR wszUserName[255]; -WCHAR wszSessionID[255]; -WCHAR wszCPU[255]; -WCHAR wszCPUTime[255]; -WCHAR wszMemUsage[255]; -WCHAR wszPeakMemUsage[255]; -WCHAR wszMemDelta[255]; -WCHAR wszPageFaults[255]; -WCHAR wszPFDelta[255]; -WCHAR wszVMSize[255]; -WCHAR wszPagedPool[255]; -WCHAR wszNPPool[255]; -WCHAR wszBasePri[255]; -WCHAR wszHandles[255]; -WCHAR wszThreads[255]; -WCHAR wszUSERObjects[255]; -WCHAR wszGDIObjects[255]; -WCHAR wszIOReads[255]; -WCHAR wszIOWrites[255]; -WCHAR wszIOOther[255]; -WCHAR wszIOReadBytes[255]; -WCHAR wszIOWriteBytes[255]; -WCHAR wszIOOtherBytes[255]; +static const WCHAR wszImageName[] = {'I','m','a','g','e',' ','N','a','m','e',0}; +static const WCHAR wszPID[] = {'P','I','D',0}; +static const WCHAR wszUserName[] = {'U','s','e','r','n','a','m','e',0}; +static const WCHAR wszSessionID[] = {'S','e','s','s','i','o','n',' ','I','D',0}; +static const WCHAR wszCPU[] = {'C','P','U',0}; +static const WCHAR wszCPUTime[] = {'C','P','U',' ','T','i','m','e',0}; +static const WCHAR wszMemUsage[] = {'M','e','m',' ','U','s','a','g','e',0}; +static const WCHAR wszPeakMemUsage[] = {'P','e','a','k',' ','M','e','m',' ','U','s','a','g','e',0}; +static const WCHAR wszMemDelta[] = {'M','e','m',' ','D','e','l','t','a',0}; +static const WCHAR wszPageFaults[] = {'P','a','g','e',' ','F','a','u','l','t','s',0}; +static const WCHAR wszPFDelta[] = {'P','F',' ','D','e','l','t','a',0}; +static const WCHAR wszVMSize[] = {'V','M',' ','S','i','z','e',0}; +static const WCHAR wszPagedPool[] = {'P','a','g','e','d',' ','P','o','o','l',0}; +static const WCHAR wszNPPool[] = {'N','P',' ','P','o','o','l',0}; +static const WCHAR wszBasePri[] = {'B','a','s','e',' ','P','r','i',0}; +static const WCHAR wszHandles[] = {'H','a','n','d','l','e','s',0}; +static const WCHAR wszThreads[] = {'T','h','r','e','a','d','s',0}; +static const WCHAR wszUSERObjects[] = {'U','S','E','R',' ','O','b','j','e','c','t','s',0}; +static const WCHAR wszGDIObjects[] = {'G','D','I',' ','O','b','j','e','c','t','s',0}; +static const WCHAR wszIOReads[] = {'I','/','O',' ','R','e','a','d','s',0}; +static const WCHAR wszIOWrites[] = {'I','/','O',' ','W','r','i','t','e','s',0}; +static const WCHAR wszIOOther[] = {'I','/','O',' ','O','t','h','e','r',0}; +static const WCHAR wszIOReadBytes[] = {'I','/','O',' ','R','e','a','d',' ','B','y','t','e','s',0}; +static const WCHAR wszIOWriteBytes[] = {'I','/','O',' ','W','r','i','t','e',' ','B','y','t','e','s',0}; +static const WCHAR wszIOOtherBytes[] = {'I','/','O',' ','O','t','h','e','r',' ','B','y','t','e','s',0}; /* Column Headers; End */ -static void load_column_headers(void) -{ - LoadStringW(hInst, IDS_IMAGENAME, wszImageName, sizeof(wszImageName)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_PID, wszPID, sizeof(wszPID)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_USERNAME, wszUserName, sizeof(wszUserName)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_SESSIONID, wszSessionID, sizeof(wszSessionID)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_CPUUSAGE, wszCPU, sizeof(wszCPU)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_CPUTIME, wszCPUTime, sizeof(wszCPUTime)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_MEMORYUSAGE, wszMemUsage, sizeof(wszMemUsage)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_PEAKMEMORYUSAGE, wszPeakMemUsage, sizeof(wszPeakMemUsage)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_MEMORYUSAGEDELTA, wszMemDelta, sizeof(wszMemDelta)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_PAGEFAULTS, wszPageFaults, sizeof(wszPageFaults)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_PAGEFAULTSDELTA, wszPFDelta, sizeof(wszPFDelta)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_VIRTUALMEMORYSIZE, wszVMSize, sizeof(wszVMSize)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_PAGEDPOOL, wszPagedPool, sizeof(wszPagedPool)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_NONPAGEDPOOL, wszNPPool, sizeof(wszNPPool)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_BASEPRIORITY, wszBasePri, sizeof(wszBasePri)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_HANDLECOUNT, wszHandles, sizeof(wszHandles)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_THREADCOUNT, wszThreads, sizeof(wszThreads)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_USEROBJECTS, wszUSERObjects, sizeof(wszUSERObjects)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_GDIOBJECTS, wszGDIObjects, sizeof(wszGDIObjects)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_IOREADS, wszIOReads, sizeof(wszIOReads)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_IOWRITES, wszIOWrites, sizeof(wszIOWrites)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_IOOTHER, wszIOOther, sizeof(wszIOOther)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_IOREADBYTES, wszIOReadBytes, sizeof(wszIOReadBytes)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_IOWRITEBYTES, wszIOWriteBytes, sizeof(wszIOWriteBytes)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_IOOTHERBYTES, wszIOOtherBytes, sizeof(wszIOOtherBytes)/sizeof(WCHAR)); -} - static int InsertColumn(int nCol, LPCWSTR lpszColumnHeading, int nFormat, int nWidth, int nSubItem) { LVCOLUMNW column; @@ -118,8 +89,6 @@ void AddColumns(void) { int size; - load_column_headers(); - if (TaskManagerSettings.Column_ImageName) InsertColumn(0, wszImageName, LVCFMT_LEFT, TaskManagerSettings.ColumnSizeArray[0], -1); if (TaskManagerSettings.Column_PID) diff --git a/programs/taskmgr/dbgchnl.c b/programs/taskmgr/dbgchnl.c index 77ddb6ca2e1..382675fe6e8 100644 --- a/programs/taskmgr/dbgchnl.c +++ b/programs/taskmgr/dbgchnl.c @@ -224,17 +224,11 @@ static void DebugChannels_OnCreate(HWND hwndDlg) HWND hLV = GetDlgItem(hwndDlg, IDC_DEBUG_CHANNELS_LIST); LVCOLUMNW lvc; - WCHAR debug_channelW[255]; - WCHAR fixmeW[255]; - WCHAR errW[255]; - WCHAR warnW[255]; - WCHAR traceW[255]; - - LoadStringW(hInst, IDS_DEBUG_CHANNEL, debug_channelW, sizeof(debug_channelW)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_DEBUG_CHANNEL_FIXME, fixmeW, sizeof(fixmeW)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_DEBUG_CHANNEL_ERR, errW, sizeof(errW)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_DEBUG_CHANNEL_WARN, warnW, sizeof(warnW)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_DEBUG_CHANNEL_TRACE, traceW, sizeof(traceW)/sizeof(WCHAR)); + static WCHAR debug_channelW[] = {'D','e','b','u','g',' ','C','h','a','n','n','e','l',0}, + fixmeW[] = {'F','i','x','m','e',0}, + errW[] = {'E','r','r',0}, + warnW[] = {'W','a','r','n',0}, + traceW[] = {'T','r','a','c','e',0}; lvc.mask = LVCF_FMT | LVCF_TEXT | LVCF_WIDTH; lvc.fmt = LVCFMT_LEFT; diff --git a/programs/taskmgr/debug.c b/programs/taskmgr/debug.c index cbd3ebf3a62..409a337b57d 100644 --- a/programs/taskmgr/debug.c +++ b/programs/taskmgr/debug.c @@ -47,20 +47,22 @@ void ProcessPage_OnDebug(void) STARTUPINFOW si; HANDLE hDebugEvent; - WCHAR wszWarnTitle[255]; - WCHAR wszUnable2Debug[255]; - WCHAR wszWarnMsg[255]; - + static const WCHAR wszWarnTitle[] = {'T','a','s','k',' ','M','a','n','a','g','e','r',' ', + 'W','a','r','n','i','n','g',0}; + static const WCHAR wszUnable2Debug[] = {'U','n','a','b','l','e',' ','t','o',' ','D','e','b','u','g',' ', + 'P','r','o','c','e','s','s',0}; static const WCHAR wszSubKey[] = {'S','o','f','t','w','a','r','e','\\', 'M','i','c','r','o','s','o','f','t','\\', 'W','i','n','d','o','w','s',' ','N','T','\\', 'C','u','r','r','e','n','t','V','e','r','s','i','o','n','\\', 'A','e','D','e','b','u','g',0}; static const WCHAR wszDebugger[] = {'D','e','b','u','g','g','e','r',0}; - - LoadStringW(hInst, IDS_WARNING_TITLE, wszWarnTitle, sizeof(wszWarnTitle)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_DEBUG_UNABLE2DEBUG, wszUnable2Debug, sizeof(wszUnable2Debug)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_DEBUG_MESSAGE, wszWarnMsg, sizeof(wszWarnMsg)/sizeof(WCHAR)); + static const WCHAR wszWarnMsg[] = {'W','A','R','N','I','N','G',':',' ','D','e','b','u','g','g','i','n','g',' ', + 't','h','i','s',' ','p','r','o','c','e','s','s',' ','m','a','y',' ', + 'r','e','s','u','l','t',' ','i','n',' ','l','o','s','s',' ','o','f',' ', + 'd','a','t','a','.','\n','A','r','e',' ','y','o','u',' ','s','u','r','e',' ', + 'y','o','u',' ','w','i','s','h',' ','t','o',' ','a','t','t','a','c','h',' ', + 't','h','e',' ','d','e','b','u','g','g','e','r','?',0}; for (Index=0; Index<(ULONG)ListView_GetItemCount(hProcessPageListCtrl); Index++) { diff --git a/programs/taskmgr/endproc.c b/programs/taskmgr/endproc.c index 5129ec38f02..241aa6769cc 100644 --- a/programs/taskmgr/endproc.c +++ b/programs/taskmgr/endproc.c @@ -33,16 +33,9 @@ #include "taskmgr.h" #include "perfdata.h" -WCHAR wszWarnMsg[511]; -WCHAR wszWarnTitle[255]; -WCHAR wszUnable2Terminate[255]; - -static void load_message_strings(void) -{ - LoadStringW(hInst, IDS_TERMINATE_MESSAGE, wszWarnMsg, sizeof(wszWarnMsg)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_TERMINATE_UNABLE2TERMINATE, wszUnable2Terminate, sizeof(wszUnable2Terminate)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_WARNING_TITLE, wszWarnTitle, sizeof(wszWarnTitle)/sizeof(WCHAR)); -} +static const WCHAR wszWarnMsg[] = {'W','A','R','N','I','N','G',':',' ','T','e','r','m','i','n','a','t','i','n','g',' ','a',' ','p','r','o','c','e','s','s',' ','c','a','n',' ','c','a','u','s','e',' ','u','n','d','e','s','i','r','e','d','\n','r','e','s','u','l','t','s',' ','i','n','c','l','u','d','i','n','g',' ','l','o','s','s',' ','o','f',' ','d','a','t','a',' ','a','n','d',' ','s','y','s','t','e','m',' ','i','n','s','t','a','b','i','l','i','t','y','.',' ','T','h','e','\n','p','r','o','c','e','s','s',' ','w','i','l','l',' ','n','o','t',' ','b','e',' ','g','i','v','e','n',' ','t','h','e',' ','c','h','a','n','c','e',' ','t','o',' ','s','a','v','e',' ','i','t','s',' ','s','t','a','t','e',' ','o','r','\n','d','a','t','a',' ','b','e','f','o','r','e',' ','i','t',' ','i','s',' ','t','e','r','m','i','n','a','t','e','d','.',' ','A','r','e',' ','y','o','u',' ','s','u','r','e',' ','y','o','u',' ','w','a','n','t',' ','t','o','\n','t','e','r','m','i','n','a','t','e',' ','t','h','e',' ','p','r','o','c','e','s','s','?',0}; +static const WCHAR wszWarnTitle[] = {'T','a','s','k',' ','M','a','n','a','g','e','r',' ','W','a','r','n','i','n','g',0}; +static const WCHAR wszUnable2Terminate[] = {'U','n','a','b','l','e',' ','t','o',' ','T','e','r','m','i','n','a','t','e',' ','P','r','o','c','e','s','s',0}; void ProcessPage_OnEndProcess(void) { @@ -52,8 +45,6 @@ void ProcessPage_OnEndProcess(void) HANDLE hProcess; WCHAR wstrErrorText[256]; - load_message_strings(); - for (Index=0; Index<(ULONG)ListView_GetItemCount(hProcessPageListCtrl); Index++) { lvitem.mask = LVIF_STATE; @@ -101,8 +92,6 @@ void ProcessPage_OnEndProcessTree(void) HANDLE hProcess; WCHAR wstrErrorText[256]; - load_message_strings(); - for (Index=0; Index<(ULONG)ListView_GetItemCount(hProcessPageListCtrl); Index++) { lvitem.mask = LVIF_STATE; diff --git a/programs/taskmgr/perfdata.c b/programs/taskmgr/perfdata.c index c96fdcffea4..5a24ba3bccd 100644 --- a/programs/taskmgr/perfdata.c +++ b/programs/taskmgr/perfdata.c @@ -253,8 +253,7 @@ void PerfDataRefresh(void) lstrcpyW(pPerfData[Idx].ImageName, pSPI->Name.Buffer); else { - WCHAR idleW[255]; - LoadStringW(hInst, IDS_SYSTEM_IDLE_PROCESS, idleW, sizeof(idleW)/sizeof(WCHAR)); + static const WCHAR idleW[] = {'S','y','s','t','e','m',' ','I','d','l','e',' ','P','r','o','c','e','s','s',0}; lstrcpyW(pPerfData[Idx].ImageName, idleW ); } diff --git a/programs/taskmgr/perfpage.c b/programs/taskmgr/perfpage.c index b61fe050385..e5f143592b1 100644 --- a/programs/taskmgr/perfpage.c +++ b/programs/taskmgr/perfpage.c @@ -141,9 +141,8 @@ static DWORD WINAPI PerformancePageRefreshThread(void *lpParameter) WCHAR Text[256]; static const WCHAR wszFormatDigit[] = {'%','d',0}; - WCHAR wszMemUsage[255]; - - LoadStringW(hInst, IDS_STATUS_BAR_MEMORY_USAGE, wszMemUsage, sizeof(wszMemUsage)/sizeof(WCHAR)); + static const WCHAR wszMemUsage[] = {'M','e','m',' ','U','s','a','g','e',':',' ', + '%','d','K',' ','/',' ','%','d','K',0}; /* Create the event */ hPerformancePageEvent = CreateEvent(NULL, TRUE, TRUE, NULL); diff --git a/programs/taskmgr/priority.c b/programs/taskmgr/priority.c index 1a5ea372165..360fe1683ee 100644 --- a/programs/taskmgr/priority.c +++ b/programs/taskmgr/priority.c @@ -41,13 +41,10 @@ static void DoSetPriority(DWORD priority) HANDLE hProcess; WCHAR wstrErrorText[256]; - WCHAR wszWarnMsg[255]; - WCHAR wszWarnTitle[255]; - WCHAR wszUnable2Change[255]; - - LoadStringW(hInst, IDS_PRIORITY_CHANGE_MESSAGE, wszWarnMsg, sizeof(wszWarnMsg)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_WARNING_TITLE, wszWarnTitle, sizeof(wszWarnTitle)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_PRIORITY_UNABLE2CHANGE, wszUnable2Change, sizeof(wszUnable2Change)/sizeof(WCHAR)); + static const WCHAR wszWarnMsg[] = {'W','A','R','N','I','N','G',':',' ','C','h','a','n','g','i','n','g', +' ','t','h','e',' ','p','r','i','o','r','i','t','y',' ','c','l','a','s','s',' ','o','f',' ','t','h','i','s',' ','p','r','o','c','e','s','s',' ','m','a','y','\n','c','a','u','s','e',' ','u','n','d','e','s','i','r','e','d',' ','r','e','s','u','l','t','s',' ','i','n','c','l','u','d','i','n','g',' ','s','y','s','t','e','m',' ','i','n','s','t','a','b','i','l','i','t','y','.',' ','A','r','e',' ','y','o','u','\n','s','u','r','e',' ','y','o','u',' ','w','a','n','t',' ','t','o',' ','c','h','a','n','g','e',' ','t','h','e',' ','p','r','i','o','r','i','t','y',' ','c','l','a','s','s','?',0}; + static const WCHAR wszWarnTitle[] = {'T','a','s','k',' ','M','a','n','a','g','e','r',' ','W','a','r','n','i','n','g',0}; + static const WCHAR wszUnable2Change[] = {'U','n','a','b','l','e',' ','t','o',' ','C','h','a','n','g','e',' ','P','r','i','o','r','i','t','y',0}; for (Index=0; Index<(ULONG)ListView_GetItemCount(hProcessPageListCtrl); Index++) { diff --git a/programs/taskmgr/procpage.c b/programs/taskmgr/procpage.c index c16f3b0ceed..adbf4696039 100644 --- a/programs/taskmgr/procpage.c +++ b/programs/taskmgr/procpage.c @@ -386,12 +386,6 @@ static DWORD WINAPI ProcessPageRefreshThread(void *lpParameter) ULONG OldProcessorUsage = 0; ULONG OldProcessCount = 0; - WCHAR wszCPU_Usage[255]; - WCHAR wszProcesses[255]; - - LoadStringW(hInst, IDS_STATUS_BAR_CPU_USAGE, wszCPU_Usage, sizeof(wszCPU_Usage)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_STATUS_BAR_PROCESSES, wszProcesses, sizeof(wszProcesses)/sizeof(WCHAR)); - /* Create the event */ hProcessPageEvent = CreateEvent(NULL, TRUE, TRUE, NULL); @@ -411,7 +405,7 @@ static DWORD WINAPI ProcessPageRefreshThread(void *lpParameter) return 0; if (dwWaitVal == WAIT_OBJECT_0) { - WCHAR text[256]; + TCHAR text[260]; /* Reset our event */ ResetEvent(hProcessPageEvent); @@ -424,13 +418,13 @@ static DWORD WINAPI ProcessPageRefreshThread(void *lpParameter) if (OldProcessorUsage != PerfDataGetProcessorUsage()) { OldProcessorUsage = PerfDataGetProcessorUsage(); - wsprintfW(text, wszCPU_Usage, OldProcessorUsage); - SendMessageW(hStatusWnd, SB_SETTEXTW, 1, (LPARAM)text); + wsprintf(text, _T("CPU Usage: %3d%%"), OldProcessorUsage); + SendMessage(hStatusWnd, SB_SETTEXT, 1, (LPARAM)text); } if (OldProcessCount != PerfDataGetProcessCount()) { OldProcessCount = PerfDataGetProcessCount(); - wsprintfW(text, wszProcesses, OldProcessCount); - SendMessageW(hStatusWnd, SB_SETTEXTW, 0, (LPARAM)text); + wsprintf(text, _T("Processes: %d"), OldProcessCount); + SendMessage(hStatusWnd, SB_SETTEXT, 0, (LPARAM)text); } } } @@ -466,8 +460,9 @@ ProcessPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) hProcessPageShowAllProcessesButton = GetDlgItem(hDlg, IDC_SHOWALLPROCESSES); /* - * Set the extended window styles for the list control + * Set the title and extended window styles for the list control */ + SetWindowText(hProcessPageListCtrl, _T("Processes")); SendMessage(hProcessPageListCtrl, LVM_SETEXTENDEDLISTVIEWSTYLE, 0, ListView_GetExtendedListViewStyle(hProcessPageListCtrl) | LVS_EX_FULLROWSELECT | LVS_EX_HEADERDRAGDROP); AddColumns(); diff --git a/programs/taskmgr/resource.h b/programs/taskmgr/resource.h index b735ef4c9f8..cc9ac012d22 100644 --- a/programs/taskmgr/resource.h +++ b/programs/taskmgr/resource.h @@ -4,11 +4,6 @@ * Used by taskmgr.rc * */ - -#include -#include -#include - #define IDS_APP_TITLE 103 #define IDC_TASKMGR 109 #define IDS_RUNDLG_CAPTION 110 @@ -187,67 +182,6 @@ #define ID_PROCESS_PAGE_SETPRIORITY_BELOWNORMAL 32813 #define ID_PROCESS_PAGE_SETPRIORITY_LOW 32814 #define ID_PROCESS_PAGE_DEBUGCHANNELS 32815 -#define IDS_VIEW_LARGE 32816 -#define IDS_VIEW_SMALL 32817 -#define IDS_VIEW_DETAILS 32818 -#define IDS_WINDOWS 32819 -#define IDS_VIEW_SELECTCOLUMNS 32820 -#define IDS_OPTIONS_SHOW16BITTASKS 32821 -#define IDS_VIEW_CPUHISTORY 32822 -#define IDS_VIEW_CPUHISTORY_ONEGRAPHALL 32823 -#define IDS_VIEW_CPUHISTORY_ONEGRAPHPERCPU 32824 -#define IDS_VIEW_SHOWKERNELTIMES 32825 -#define IDS_APPLICATIONS 32826 -#define IDS_PROCESSES 32827 -#define IDS_PERFORMANCE 32828 -#define IDS_STATUS_BAR_CPU_USAGE 32829 -#define IDS_STATUS_BAR_PROCESSES 32830 -#define IDS_STATUS_BAR_MEMORY_USAGE 32831 -#define IDS_IMAGENAME 32832 -#define IDS_PID 32833 -#define IDS_CPUUSAGE 32834 -#define IDS_CPUTIME 32835 -#define IDS_MEMORYUSAGE 32836 -#define IDS_MEMORYUSAGEDELTA 32837 -#define IDS_PEAKMEMORYUSAGE 32838 -#define IDS_PAGEFAULTS 32839 -#define IDS_USEROBJECTS 32840 -#define IDS_IOREADS 32841 -#define IDS_IOREADBYTES 32842 -#define IDS_SESSIONID 32843 -#define IDS_USERNAME 32844 -#define IDS_PAGEFAULTSDELTA 32845 -#define IDS_VIRTUALMEMORYSIZE 32846 -#define IDS_PAGEDPOOL 32847 -#define IDS_NONPAGEDPOOL 32848 -#define IDS_BASEPRIORITY 32849 -#define IDS_HANDLECOUNT 32850 -#define IDS_THREADCOUNT 32851 -#define IDS_GDIOBJECTS 32852 -#define IDS_IOWRITES 32853 -#define IDS_IOWRITEBYTES 32854 -#define IDS_IOOTHER 32855 -#define IDS_IOOTHERBYTES 32856 -#define IDS_WARNING_TITLE 32857 -#define IDS_PRIORITY_CHANGE_MESSAGE 32858 -#define IDS_PRIORITY_UNABLE2CHANGE 32859 -#define IDS_TERMINATE_MESSAGE 32860 -#define IDS_TERMINATE_UNABLE2TERMINATE 32861 -#define IDS_DEBUG_MESSAGE 32862 -#define IDS_DEBUG_UNABLE2DEBUG 32863 -#define IDS_AFFINITY_ERROR_MESSAGE 32864 -#define IDS_AFFINITY_ERROR_TITLE 32865 -#define IDS_AFFINITY_UNABLE2ACCESS 32866 -#define IDS_SYSTEM_IDLE_PROCESS 32867 -#define IDS_APPLICATION_NOT_RESPONDING 32868 -#define IDS_APPLICATION_RUNNING 32869 -#define IDS_APPLICATION_TASK 32870 -#define IDS_APPLICATION_STATUS 32871 -#define IDS_DEBUG_CHANNEL 32872 -#define IDS_DEBUG_CHANNEL_FIXME 32873 -#define IDS_DEBUG_CHANNEL_ERR 32874 -#define IDS_DEBUG_CHANNEL_WARN 32875 -#define IDS_DEBUG_CHANNEL_TRACE 32876 #define IDC_STATIC -1 /* diff --git a/programs/taskmgr/taskmgr.c b/programs/taskmgr/taskmgr.c index 01c6926765e..923a445d4f6 100644 --- a/programs/taskmgr/taskmgr.c +++ b/programs/taskmgr/taskmgr.c @@ -122,13 +122,9 @@ static BOOL OnCreate(HWND hWnd) RECT rc; TCITEMW item; - static WCHAR wszApplications[255]; - static WCHAR wszProcesses[255]; - static WCHAR wszPerformance[255]; - - LoadStringW(hInst, IDS_APPLICATIONS, wszApplications, sizeof(wszApplications)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_PROCESSES, wszProcesses, sizeof(wszProcesses)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_PERFORMANCE, wszPerformance, sizeof(wszPerformance)/sizeof(WCHAR)); + static WCHAR wszApplications[] = {'A','p','p','l','i','c','a','t','i','o','n','s',0}; + static WCHAR wszProcesses[] = {'P','r','o','c','e','s','s','e','s',0}; + static WCHAR wszPerformance[] = {'P','e','r','f','o','r','m','a','n','c','e',0}; SendMessageW(hMainWnd, WM_SETICON, ICON_BIG, (LPARAM)LoadIcon(hInst, MAKEINTRESOURCE(IDI_TASKMANAGER))); @@ -527,11 +523,8 @@ static void TaskManager_OnExitMenuLoop(HWND hWnd) int nParts[3]; WCHAR text[256]; - WCHAR wszCPU_Usage[255]; - WCHAR wszProcesses[255]; - - LoadStringW(hInst, IDS_STATUS_BAR_CPU_USAGE, wszCPU_Usage, sizeof(wszCPU_Usage)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_STATUS_BAR_PROCESSES, wszProcesses, sizeof(wszProcesses)/sizeof(WCHAR)); + static const WCHAR wszCPU_Usage[] = {'C','P','U',' ','U','s','a','g','e',':',' ','%','3','d','%','%',0}; + static const WCHAR wszProcesses[] = {'P','r','o','c','e','s','s','e','s',':',' ','%','d',0}; bInMenuLoop = FALSE; /* Update the status bar pane sizes */ @@ -628,27 +621,21 @@ static void TaskManager_OnTabWndSelChange(void) HMENU hViewMenu; HMENU hSubMenu; - WCHAR wszLargeIcons[255]; - WCHAR wszSmallIcons[255]; - WCHAR wszDetails[255]; - WCHAR wszWindows[255]; - WCHAR wszSelectColumns[255]; - WCHAR wszShow16bTasks[255]; - WCHAR wszOneGraphAllCPU[255]; - WCHAR wszOneGraphPerCPU[255]; - WCHAR wszCPUHistory[255]; - WCHAR wszShowKernelTimes[255]; - - LoadStringW(hInst, IDS_VIEW_LARGE, wszLargeIcons, sizeof(wszLargeIcons)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_VIEW_SMALL, wszSmallIcons, sizeof(wszSmallIcons)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_VIEW_DETAILS, wszDetails, sizeof(wszDetails)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_WINDOWS, wszWindows, sizeof(wszWindows)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_VIEW_SELECTCOLUMNS, wszSelectColumns, sizeof(wszSelectColumns)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_OPTIONS_SHOW16BITTASKS, wszShow16bTasks, sizeof(wszShow16bTasks)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_VIEW_CPUHISTORY_ONEGRAPHALL, wszOneGraphAllCPU, sizeof(wszOneGraphAllCPU)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_VIEW_CPUHISTORY_ONEGRAPHPERCPU, wszOneGraphPerCPU, sizeof(wszOneGraphPerCPU)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_VIEW_CPUHISTORY, wszCPUHistory, sizeof(wszCPUHistory)/sizeof(WCHAR)); - LoadStringW(hInst, IDS_VIEW_SHOWKERNELTIMES, wszShowKernelTimes, sizeof(wszShowKernelTimes)/sizeof(WCHAR)); + static const WCHAR wszLargeIcons[] = {'L','a','r','&','g','e',' ','I','c','o','n','s',0}; + static const WCHAR wszSmallIcons[] = {'S','&','m','a','l','l',' ','I','c','o','n','s',0}; + static const WCHAR wszDetails[] = {'&','D','e','t','a','i','l','s',0}; + static const WCHAR wszWindows[] = {'&','W','i','n','d','o','w','s',0}; + static const WCHAR wszSelectColumns[] = {'&','S','e','l','e','c','t',' ', + 'C','o','l','u','m','n','s','.','.','.',0}; + static const WCHAR wszShow16bTasks[] = {'&','S','h','o','w',' ','1','6','-','b','i','t',' ', + 't','a','s','k','s',0}; + static const WCHAR wszOneGraphAllCPU[] = {'&','O','n','e',' ','G','r','a','p','h',',',' ', + 'A','l','l',' ','C','P','U','s',0}; + static const WCHAR wszOneGraphPerCPU[] = {'O','n','e',' ','G','r','a','p','h',' ', + '&','P','e','r',' ','C','P','U',0}; + static const WCHAR wszCPUHistory[] = {'&','C','P','U',' ','H','i','s','t','o','r','y',0}; + static const WCHAR wszShowKernelTimes[] = {'&','S','h','o','w',' ','K','e','r','n','e','l',' ', + 'T','i','m','e','s',0}; hMenu = GetMenu(hMainWnd); hViewMenu = GetSubMenu(hMenu, 2); diff --git a/programs/taskmgr/taskmgr.rc b/programs/taskmgr/taskmgr.rc index fb5b3e88dae..a3851f726bb 100644 --- a/programs/taskmgr/taskmgr.rc +++ b/programs/taskmgr/taskmgr.rc @@ -19,9 +19,29 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include +#include +#include + #include "resource.h" -#pragma code_page(65001) +/* Language resources */ + +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Fr.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL @@ -65,7 +85,7 @@ BEGIN VALUE "FileDescription", "Task Manager by Brian Palmer\0" VALUE "FileVersion", "1.0.0.1\0" VALUE "InternalName", "taskmgr\0" - VALUE "LegalCopyright", "Copyright © Brian Palmer 2000\0" + VALUE "LegalCopyright", "Copyright © Brian Palmer 2000\0" VALUE "OriginalFilename", "taskmgr.exe\0" VALUE "ProductName", "Task Manager by Brian Palmer\0" VALUE "ProductVersion", "1.0.0.1\0" diff --git a/programs/taskmgr/trayicon.c b/programs/taskmgr/trayicon.c index b1379f531a2..35740dd139d 100644 --- a/programs/taskmgr/trayicon.c +++ b/programs/taskmgr/trayicon.c @@ -142,9 +142,7 @@ BOOL TrayIcon_ShellAddTrayIcon(void) NOTIFYICONDATAW nid; HICON hIcon = NULL; BOOL bRetVal; - WCHAR wszCPU_Usage[255]; - - LoadStringW(hInst, IDS_STATUS_BAR_CPU_USAGE, wszCPU_Usage, sizeof(wszCPU_Usage)/sizeof(WCHAR)); + WCHAR wszCPU_Usage[] = {'C','P','U',' ','U','s','a','g','e',':',' ','%','d','%','%',0}; memset(&nid, 0, sizeof(NOTIFYICONDATAW)); @@ -189,9 +187,7 @@ BOOL TrayIcon_ShellUpdateTrayIcon(void) NOTIFYICONDATAW nid; HICON hIcon = NULL; BOOL bRetVal; - WCHAR wszCPU_Usage[255]; - - LoadStringW(hInst, IDS_STATUS_BAR_CPU_USAGE, wszCPU_Usage, sizeof(wszCPU_Usage)/sizeof(WCHAR)); + WCHAR wszCPU_Usage[] = {'C','P','U',' ','U','s','a','g','e',':',' ','%','d','%','%',0}; memset(&nid, 0, sizeof(NOTIFYICONDATAW)); diff --git a/programs/uninstaller/Bg.rc b/programs/uninstaller/Bg.rc index 517f3e2b7a1..45705148187 100644 --- a/programs/uninstaller/Bg.rc +++ b/programs/uninstaller/Bg.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/Cs.rc b/programs/uninstaller/Cs.rc index ed73cd33bf7..69446360eda 100644 --- a/programs/uninstaller/Cs.rc +++ b/programs/uninstaller/Cs.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_CZECH, SUBLANG_NEUTRAL /* Czech strings in CP1250 */ diff --git a/programs/uninstaller/Da.rc b/programs/uninstaller/Da.rc index 696413c4110..1c928d72240 100644 --- a/programs/uninstaller/Da.rc +++ b/programs/uninstaller/Da.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/De.rc b/programs/uninstaller/De.rc index 58f542783dc..a01bd7a8d65 100644 --- a/programs/uninstaller/De.rc +++ b/programs/uninstaller/De.rc @@ -18,13 +18,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { IDS_APPNAME, "Wine Anwendungsentferner" - IDS_UNINSTALLFAILED, "Die Ausführung des Entfernungsbefehls '%s' ist fehlgeschlagen, wahrscheinlich durch eine fehlende, ausführbare Datei.\r\nMöchten Sie, dass der Anwendungseintrag aus der Registry entfernt wird?" + IDS_UNINSTALLFAILED, "Die Ausführung des Entfernungsbefehls '%s' ist fehlgeschlagen, wahrscheinlich durch eine fehlende, ausführbare Datei.\r\nMöchten Sie, dass der Anwendungseintrag aus der Registry entfernt wird?" } diff --git a/programs/uninstaller/En.rc b/programs/uninstaller/En.rc index 728254318b5..f6ce7b2aa0b 100644 --- a/programs/uninstaller/En.rc +++ b/programs/uninstaller/En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/Eo.rc b/programs/uninstaller/Eo.rc index 199356b302a..52153620c1f 100644 --- a/programs/uninstaller/Eo.rc +++ b/programs/uninstaller/Eo.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/Es.rc b/programs/uninstaller/Es.rc index 7862cea676c..0fe7d14763d 100644 --- a/programs/uninstaller/Es.rc +++ b/programs/uninstaller/Es.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/Fi.rc b/programs/uninstaller/Fi.rc index 13bc170cf07..0114990bdb0 100644 --- a/programs/uninstaller/Fi.rc +++ b/programs/uninstaller/Fi.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/Fr.rc b/programs/uninstaller/Fr.rc index 5e0d0f1511e..d9ec2a86cc5 100644 --- a/programs/uninstaller/Fr.rc +++ b/programs/uninstaller/Fr.rc @@ -18,17 +18,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL - STRINGTABLE DISCARDABLE { - IDS_APPNAME, "Désinstalleur d'applications de Wine" - IDS_UNINSTALLFAILED, "Erreur lors de l'excution de la commande de \ -désinstallation « %s ». L'exécutable n'a peut-être pas été trouvé.\ -\nSouhaitez-vous supprimmer l'entrée de la base de registre ?" + IDS_APPNAME, "Désinstalleur d'applications de Wine" + IDS_UNINSTALLFAILED, "Erreur lors de l'excution de la commande de désinstallation « %s ». L'exécutable ne peut peut être pas être trouvé.\r\nSouhaitez-vous supprimmer l'entrée de la base de registre ?" } diff --git a/programs/uninstaller/Hu.rc b/programs/uninstaller/Hu.rc index d58e54dff16..bfd689ca577 100644 --- a/programs/uninstaller/Hu.rc +++ b/programs/uninstaller/Hu.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/It.rc b/programs/uninstaller/It.rc index 3eaad1f684d..af21f6cbc49 100644 --- a/programs/uninstaller/It.rc +++ b/programs/uninstaller/It.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/Ko.rc b/programs/uninstaller/Ko.rc index a14ac3d9664..7300c114b27 100644 --- a/programs/uninstaller/Ko.rc +++ b/programs/uninstaller/Ko.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/Lt.rc b/programs/uninstaller/Lt.rc index 89b42be0dfd..1a3156a6573 100644 --- a/programs/uninstaller/Lt.rc +++ b/programs/uninstaller/Lt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -27,5 +25,7 @@ LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { IDS_APPNAME, "Wine programų šalinimo programa" - IDS_UNINSTALLFAILED, "Nepavyko įvykdyti programos pašalinimo komandos „%s“, greičiausiai dėl trūkstamo vykdomojo failo.\r\nAr norite pašalinti programos šalinimo įrašą iš registro?" + IDS_UNINSTALLFAILED, "Nepavyko įvykdyti programos pašalinimo komandos '%s', greičiausiai dėl trūkstamo vykdomojo failo.\r\nAr norite pašalinti programos šalinimo įrašą iš registro?" } + +#pragma code_page(default) diff --git a/programs/uninstaller/Makefile.in b/programs/uninstaller/Makefile.in index 0c9851c0b65..0f7e0e462e5 100644 --- a/programs/uninstaller/Makefile.in +++ b/programs/uninstaller/Makefile.in @@ -11,30 +11,7 @@ DELAYIMPORTS = shlwapi shell32 user32 gdi32 C_SRCS = \ main.c -RC_SRCS = \ - Bg.rc \ - Cs.rc \ - Da.rc \ - De.rc \ - En.rc \ - Eo.rc \ - Es.rc \ - Fi.rc \ - Fr.rc \ - Hu.rc \ - It.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ro.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc +RC_SRCS = rsrc.rc @MAKE_PROG_RULES@ diff --git a/programs/uninstaller/Nl.rc b/programs/uninstaller/Nl.rc index 97d218417ef..8c645b707eb 100644 --- a/programs/uninstaller/Nl.rc +++ b/programs/uninstaller/Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/No.rc b/programs/uninstaller/No.rc index 470f8d9bb3f..2aaa1ecd2f3 100644 --- a/programs/uninstaller/No.rc +++ b/programs/uninstaller/No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/Pl.rc b/programs/uninstaller/Pl.rc index 174759aad3a..7451e63da0f 100644 --- a/programs/uninstaller/Pl.rc +++ b/programs/uninstaller/Pl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/Pt.rc b/programs/uninstaller/Pt.rc index 01c26f875c5..14c7867133b 100644 --- a/programs/uninstaller/Pt.rc +++ b/programs/uninstaller/Pt.rc @@ -18,8 +18,6 @@ * */ -#include "resource.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/README b/programs/uninstaller/README new file mode 100644 index 00000000000..0e110bfd62e --- /dev/null +++ b/programs/uninstaller/README @@ -0,0 +1,21 @@ +Uninstaller README + +Uninstaller, copyright 2000, Andreas Mohr +Uninstaller is to be distributed under the Wine License +See the Wine License for further information. + +This is an uninstaller for all setup programs that put an uninstall entry +into the registry, such as e.g. InstallShield or the WISE installer. +Its files have been shamelessly ripped from WineMine partially :) + +TODO: + - implement sorting of the uninstall entries + - let the uninstall happen in a separate thread in order to be able to + uninstall several programs concurrently + +KNOWN BUGS: + - minimizing/maximizing is broken (just as with WineMine) + - the icon is, ermm, wrong ;-)) + +UNKNOWN BUGS: + ??? diff --git a/programs/uninstaller/Ro.rc b/programs/uninstaller/Ro.rc index 770b4a69c7c..5f0248879f3 100644 --- a/programs/uninstaller/Ro.rc +++ b/programs/uninstaller/Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -27,3 +25,5 @@ STRINGTABLE DISCARDABLE { IDS_APPNAME, "Programul de dezinstalare de aplicații Wine" IDS_UNINSTALLFAILED, "Execuția comenzi de dezinstalare '%s' a eșuat, probabil din lipsa fișierului executabil.\r\nDoriți să ștergeți înregistrarea de dezinstalare din registru?" } + +#pragma code_page(default) diff --git a/programs/uninstaller/Ru.rc b/programs/uninstaller/Ru.rc index 4e74ee835b5..bada09cafa1 100644 --- a/programs/uninstaller/Ru.rc +++ b/programs/uninstaller/Ru.rc @@ -18,14 +18,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { - IDS_APPNAME, "Удаление приложений WINE" - IDS_UNINSTALLFAILED, "Ошибка выполнения команды удаления '%s', возможно из-за потери файлов приложения.\r\nУдалить информацию об установке из реестра?" + IDS_APPNAME, "Óäàëåíèå ïðèëîæåíèé WINE" + IDS_UNINSTALLFAILED, "Îøèáêà âûïîëíåíèÿ êîìàíäû óäàëåíèÿ '%s', âîçìîæíî èç-çà ïîòåðè ôàéëîâ ïðèëîæåíèÿ.\r\nÓäàëèòü èíôîðìàöèþ îá óñòàíîâêå èç ðååñòðà?" } diff --git a/programs/uninstaller/Si.rc b/programs/uninstaller/Si.rc index 598df642b72..a971ae35b3a 100644 --- a/programs/uninstaller/Si.rc +++ b/programs/uninstaller/Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -28,3 +26,5 @@ STRINGTABLE DISCARDABLE { IDS_APPNAME, "Wine Odstranjevalec programov" IDS_UNINSTALLFAILED, "Izvedba odstranitvenega ukaza '%s' ni uspela, morda zaradi manjkajoče izvršljive datoteke.\r\nAli želite odstraniti odstranitveni ključ iz registra?" } + +#pragma code_page(default) diff --git a/programs/uninstaller/Sv.rc b/programs/uninstaller/Sv.rc index 3365e2e4bf4..00d08103dee 100644 --- a/programs/uninstaller/Sv.rc +++ b/programs/uninstaller/Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/Tr.rc b/programs/uninstaller/Tr.rc index ce31e15ef6e..5a46812552a 100644 --- a/programs/uninstaller/Tr.rc +++ b/programs/uninstaller/Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE DISCARDABLE { diff --git a/programs/uninstaller/Zh.rc b/programs/uninstaller/Zh.rc index 368814c9582..6e0e2beb992 100644 --- a/programs/uninstaller/Zh.rc +++ b/programs/uninstaller/Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -36,3 +34,5 @@ STRINGTABLE DISCARDABLE { IDS_APPNAME, "Wine 應有程式卸載管理器" IDS_UNINSTALLFAILED, "卸載指令執行失敗 '%s', 可能是找不到可執行程式.\r\n你想把這項卸載指令從註冊表中刪除嗎?" } + +#pragma code_page(default) diff --git a/programs/uninstaller/resource.h b/programs/uninstaller/resource.h index 67e1f4b424f..b30be4ecba3 100644 --- a/programs/uninstaller/resource.h +++ b/programs/uninstaller/resource.h @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include - #define IDS_APPNAME 1000 #define IDS_UNINSTALLFAILED 1001 #define MAX_STRING_LEN 255 diff --git a/programs/uninstaller/rsrc.rc b/programs/uninstaller/rsrc.rc new file mode 100644 index 00000000000..799e3f6a290 --- /dev/null +++ b/programs/uninstaller/rsrc.rc @@ -0,0 +1,51 @@ +/* + * Uninstaller (rsrc.rc) + * + * Copyright 2000 Andreas Mohr + * Copyright 2003 Vincent Béron + * Copyright 2003 Ivan Leo Puoti + * Copyright 2004 David Kredba + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include +#include + +#include "resource.h" +#include "Bg.rc" +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Eo.rc" +#include "Es.rc" +#include "Fi.rc" +#include "Fr.rc" +#include "It.rc" +#include "Hu.rc" +#include "Ko.rc" +#include "Lt.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ro.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" diff --git a/programs/view/Cs.rc b/programs/view/Cs.rc index 58ee9ca2583..ca341213e71 100644 --- a/programs/view/Cs.rc +++ b/programs/view/Cs.rc @@ -22,8 +22,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/programs/view/Da.rc b/programs/view/Da.rc index 8996cf83271..91fd214bef9 100644 --- a/programs/view/Da.rc +++ b/programs/view/Da.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT /* diff --git a/programs/view/De.rc b/programs/view/De.rc index 736f7bf1f3d..5e7cf31b4b5 100644 --- a/programs/view/De.rc +++ b/programs/view/De.rc @@ -19,10 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL /* @@ -35,7 +31,7 @@ VIEW MENU BEGIN POPUP "&Datei" BEGIN - MENUITEM "&Öffnen", IDM_OPEN + MENUITEM "&Öffnen", IDM_OPEN MENUITEM "&Beenden", IDM_EXIT END POPUP "&Verschieben" @@ -70,5 +66,5 @@ END STRINGTABLE DISCARDABLE BEGIN - IDS_DESCRIPTION "Regulärer Metafile Betrachter" + IDS_DESCRIPTION "Regulärer Metafile Betrachter" END diff --git a/programs/view/En.rc b/programs/view/En.rc index b2012904bc8..042f303e9f1 100644 --- a/programs/view/En.rc +++ b/programs/view/En.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT /* diff --git a/programs/view/Eo.rc b/programs/view/Eo.rc index bc61a8d2fdb..bcdeba72e8d 100644 --- a/programs/view/Eo.rc +++ b/programs/view/Eo.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT /* diff --git a/programs/view/Es.rc b/programs/view/Es.rc index e0f53f3d7e3..f1b897d8e81 100644 --- a/programs/view/Es.rc +++ b/programs/view/Es.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL /* diff --git a/programs/view/Fr.rc b/programs/view/Fr.rc index bcbb0cacf8b..b2ab0a4cce4 100644 --- a/programs/view/Fr.rc +++ b/programs/view/Fr.rc @@ -4,7 +4,7 @@ * * Copyright 1998 Douglas Ridgway * Copyright 2003 Marcelo Duarte - * Copyright 2003 Vincent Béron + * Copyright 2003 Vincent Béron * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -21,11 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL /* @@ -41,9 +36,9 @@ BEGIN MENUITEM "&Ouvrir", IDM_OPEN MENUITEM "&Quitter", IDM_EXIT END - POPUP "&Déplacement" + POPUP "&Déplacement" BEGIN - MENUITEM "&Mettre à l'échelle", IDM_SET_EXT_TO_WIN + MENUITEM "&Mettre à l'échelle", IDM_SET_EXT_TO_WIN MENUITEM SEPARATOR MENUITEM "&Gauche", IDM_LEFT MENUITEM "&Droite", IDM_RIGHT @@ -73,5 +68,5 @@ END STRINGTABLE DISCARDABLE BEGIN - IDS_DESCRIPTION "Visionneuse de fichiers Metafile réguliers" + IDS_DESCRIPTION "Visionneuse de fichiers Metafile réguliers" END diff --git a/programs/view/It.rc b/programs/view/It.rc index 0839c44dc2b..37747ce3c46 100644 --- a/programs/view/It.rc +++ b/programs/view/It.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL /* diff --git a/programs/view/Ja.rc b/programs/view/Ja.rc index 0b692169502..46c8e11320c 100644 --- a/programs/view/Ja.rc +++ b/programs/view/Ja.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -74,3 +72,5 @@ STRINGTABLE DISCARDABLE BEGIN IDS_DESCRIPTION "標準メタファイル ビュアー" END + +#pragma code_page(default) diff --git a/programs/view/Ko.rc b/programs/view/Ko.rc index 34516265a87..5df207b7ea8 100644 --- a/programs/view/Ko.rc +++ b/programs/view/Ko.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT /* diff --git a/programs/view/Lt.rc b/programs/view/Lt.rc deleted file mode 100644 index fdcf731eba6..00000000000 --- a/programs/view/Lt.rc +++ /dev/null @@ -1,75 +0,0 @@ -/* - * View - * Lithuanian Language Support - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -/* - * - * Menu - * - */ - -VIEW MENU -BEGIN - POPUP "&Failas" - BEGIN - MENUITEM "&Atverti", IDM_OPEN - MENUITEM "Iš&eiti", IDM_EXIT - END - POPUP "&Perkelti" - BEGIN - MENUITEM "&Sutalpinti į langą", IDM_SET_EXT_TO_WIN - MENUITEM SEPARATOR - MENUITEM "&Dešinėn", IDM_LEFT - MENUITEM "&Kairėn", IDM_RIGHT - MENUITEM "&Žemyn", IDM_UP - MENUITEM "&Aukštyn", IDM_DOWN - END -END - - -/* - * - * Accelerator - * - */ - -VIEW ACCELERATORS -BEGIN - "Q", IDM_EXIT, VIRTKEY, CONTROL -END - - -/* - * - * String Table - * - */ - -STRINGTABLE DISCARDABLE -BEGIN - IDS_DESCRIPTION "Įprastinė metafailų žiūryklė" -END diff --git a/programs/view/Makefile.in b/programs/view/Makefile.in index ff345323f34..134a2b4fc20 100644 --- a/programs/view/Makefile.in +++ b/programs/view/Makefile.in @@ -11,28 +11,7 @@ C_SRCS = \ view.c \ winmain.c -RC_SRCS = \ - Cs.rc \ - Da.rc \ - De.rc \ - En.rc \ - Eo.rc \ - Es.rc \ - Fr.rc \ - It.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ro.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc +RC_SRCS = viewrc.rc @MAKE_PROG_RULES@ diff --git a/programs/view/Nl.rc b/programs/view/Nl.rc index 623506b7dad..34a9d4f9318 100644 --- a/programs/view/Nl.rc +++ b/programs/view/Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL /* diff --git a/programs/view/No.rc b/programs/view/No.rc index 4a18853ce98..e7289663b98 100644 --- a/programs/view/No.rc +++ b/programs/view/No.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL /* diff --git a/programs/view/Pl.rc b/programs/view/Pl.rc index 28828d8298e..3f3e93717b7 100644 --- a/programs/view/Pl.rc +++ b/programs/view/Pl.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT /* diff --git a/programs/view/Pt.rc b/programs/view/Pt.rc index 30030809b9c..47aab014002 100644 --- a/programs/view/Pt.rc +++ b/programs/view/Pt.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* * * Menu diff --git a/programs/view/Ro.rc b/programs/view/Ro.rc index 8c05f066e33..b03fe31a452 100644 --- a/programs/view/Ro.rc +++ b/programs/view/Ro.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -71,3 +69,5 @@ STRINGTABLE DISCARDABLE BEGIN IDS_DESCRIPTION "Vizualizator de fișiere metafile normale" END + +#pragma code_page(default) diff --git a/programs/view/Ru.rc b/programs/view/Ru.rc index c914434185c..cbdc28eac8a 100644 --- a/programs/view/Ru.rc +++ b/programs/view/Ru.rc @@ -18,11 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT /* @@ -33,19 +28,19 @@ LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT VIEW MENU BEGIN - POPUP "&Файл" + POPUP "&Ôàéë" BEGIN - MENUITEM "&Открыть", IDM_OPEN - MENUITEM "В&ыход", IDM_EXIT + MENUITEM "&Îòêðûòü", IDM_OPEN + MENUITEM "Â&ûõîä", IDM_EXIT END - POPUP "&Положение" + POPUP "&Ïîëîæåíèå" BEGIN - MENUITEM "&Расширить по окну", IDM_SET_EXT_TO_WIN + MENUITEM "&Ðàñøèðèòü ïî îêíó", IDM_SET_EXT_TO_WIN MENUITEM SEPARATOR - MENUITEM "В&лево", IDM_LEFT - MENUITEM "В&право", IDM_RIGHT - MENUITEM "В&верх", IDM_UP - MENUITEM "В&низ", IDM_DOWN + MENUITEM "Â&ëåâî", IDM_LEFT + MENUITEM "Â&ïðàâî", IDM_RIGHT + MENUITEM "Â&âåðõ", IDM_UP + MENUITEM "Â&íèç", IDM_DOWN END END @@ -70,5 +65,5 @@ END STRINGTABLE DISCARDABLE BEGIN - IDS_DESCRIPTION "Просмоторщик обычных метафайлов" + IDS_DESCRIPTION "Ïðîñìîòîðùèê îáû÷íûõ ìåòàôàéëîâ" END diff --git a/programs/view/Si.rc b/programs/view/Si.rc index 8e6a0f2ea01..8cb4988c068 100644 --- a/programs/view/Si.rc +++ b/programs/view/Si.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -72,3 +70,5 @@ STRINGTABLE DISCARDABLE BEGIN IDS_DESCRIPTION "Program za ogled Metafile slik" END + +#pragma code_page(default) diff --git a/programs/view/Sv.rc b/programs/view/Sv.rc index 2f7eea3a223..b1bb50d9887 100644 --- a/programs/view/Sv.rc +++ b/programs/view/Sv.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL /* diff --git a/programs/view/Tr.rc b/programs/view/Tr.rc index 3e6ea6ff194..38ed8490ae9 100644 --- a/programs/view/Tr.rc +++ b/programs/view/Tr.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT /* diff --git a/programs/view/Zh.rc b/programs/view/Zh.rc index 05067f8fbfb..84bd638481a 100644 --- a/programs/view/Zh.rc +++ b/programs/view/Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -122,3 +120,5 @@ STRINGTABLE DISCARDABLE BEGIN IDS_DESCRIPTION "普通 Metafile 閱讀器" END + +#pragma code_page(default) diff --git a/programs/view/resource.h b/programs/view/resource.h index 79326879fdc..619da492d33 100644 --- a/programs/view/resource.h +++ b/programs/view/resource.h @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include - #define IDS_DESCRIPTION 2 #define IDI_APPICON 101 #define IDM_EXIT 1000 diff --git a/programs/view/viewrc.rc b/programs/view/viewrc.rc new file mode 100644 index 00000000000..7b104fa2375 --- /dev/null +++ b/programs/view/viewrc.rc @@ -0,0 +1,48 @@ +/* + * Copyright 1998 Douglas Ridgway + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include + +#include "resource.h" + +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Eo.rc" +#include "Es.rc" +#include "Fr.rc" +#include "It.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ro.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" + +/* + * Icon + */ + +/*IDI_APPICON ICON DISCARDABLE "view.ico"*/ diff --git a/programs/wineboot/Makefile.in b/programs/wineboot/Makefile.in index 21094575c73..63c6fd86fef 100644 --- a/programs/wineboot/Makefile.in +++ b/programs/wineboot/Makefile.in @@ -12,24 +12,7 @@ C_SRCS = \ shutdown.c \ wineboot.c -RC_SRCS = \ - wineboot_Da.rc \ - wineboot_De.rc \ - wineboot_En.rc \ - wineboot_Es.rc \ - wineboot_Fr.rc \ - wineboot_Ja.rc \ - wineboot_Ko.rc \ - wineboot_Lt.rc \ - wineboot_Nl.rc \ - wineboot_No.rc \ - wineboot_Pl.rc \ - wineboot_Pt.rc \ - wineboot_Ro.rc \ - wineboot_Ru.rc \ - wineboot_Si.rc \ - wineboot_Sv.rc \ - wineboot_Zh.rc +RC_SRCS = wineboot.rc @MAKE_PROG_RULES@ diff --git a/programs/wineboot/resource.h b/programs/wineboot/resource.h index a59454a502c..3838922e41a 100644 --- a/programs/wineboot/resource.h +++ b/programs/wineboot/resource.h @@ -16,8 +16,5 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "windef.h" -#include "winuser.h" - #define IDC_STATIC -1 #define IDD_ENDTASK 100 diff --git a/programs/wineboot/wineboot.rc b/programs/wineboot/wineboot.rc new file mode 100644 index 00000000000..3ca5d017435 --- /dev/null +++ b/programs/wineboot/wineboot.rc @@ -0,0 +1,46 @@ +/* + * WineBoot resources + * + * Copyright (C) 2007 Robert Shearman for CodeWeavers + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + * + */ + +#include "windef.h" +#include "winbase.h" +#include "wingdi.h" +#include "winnls.h" +#include "winuser.h" +#include "commctrl.h" +#include "resource.h" + +#include "wineboot_Da.rc" +#include "wineboot_De.rc" +#include "wineboot_En.rc" +#include "wineboot_Es.rc" +#include "wineboot_Fr.rc" +#include "wineboot_Ja.rc" +#include "wineboot_Ko.rc" +#include "wineboot_Lt.rc" +#include "wineboot_Nl.rc" +#include "wineboot_No.rc" +#include "wineboot_Pl.rc" +#include "wineboot_Pt.rc" +#include "wineboot_Ro.rc" +#include "wineboot_Ru.rc" +#include "wineboot_Si.rc" +#include "wineboot_Sv.rc" +#include "wineboot_Zh.rc" diff --git a/programs/wineboot/wineboot_Da.rc b/programs/wineboot/wineboot_Da.rc index b2730a43fb2..5e5291562a7 100644 --- a/programs/wineboot/wineboot_Da.rc +++ b/programs/wineboot/wineboot_Da.rc @@ -19,8 +19,6 @@ * */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT IDD_ENDTASK DIALOG DISCARDABLE 0, 0, 186, 71 diff --git a/programs/wineboot/wineboot_De.rc b/programs/wineboot/wineboot_De.rc index b65e8f3b517..8582dbf7bf3 100644 --- a/programs/wineboot/wineboot_De.rc +++ b/programs/wineboot/wineboot_De.rc @@ -20,10 +20,6 @@ * */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL IDD_ENDTASK DIALOG DISCARDABLE 0, 0, 186, 71 @@ -35,6 +31,6 @@ BEGIN PUSHBUTTON "Programm beenden",IDOK,51,49,71,15 LTEXT "Ein Abmelden oder Herunterfahren wird simuliert, aber dieses Programm reagiert nicht.", IDC_STATIC,7,7,172,19 - LTEXT "Wenn Sie das Programm beenden, können Sie ungespeicherte Daten verlieren.", + LTEXT "Wenn Sie das Programm beenden, können Sie ungespeicherte Daten verlieren.", IDC_STATIC,7,28,172,19 END diff --git a/programs/wineboot/wineboot_En.rc b/programs/wineboot/wineboot_En.rc index 4070b72a44b..8e06aec1843 100644 --- a/programs/wineboot/wineboot_En.rc +++ b/programs/wineboot/wineboot_En.rc @@ -19,8 +19,6 @@ * */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT IDD_ENDTASK DIALOG DISCARDABLE 0, 0, 186, 71 diff --git a/programs/wineboot/wineboot_Es.rc b/programs/wineboot/wineboot_Es.rc index 359cdd24c1d..229eaba4df5 100644 --- a/programs/wineboot/wineboot_Es.rc +++ b/programs/wineboot/wineboot_Es.rc @@ -18,9 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA * */ - -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL @@ -37,3 +34,5 @@ BEGIN LTEXT "Si termina el programa puede perder los datos no grabados.", IDC_STATIC,7,28,172,15 END + +#pragma code_page(default) diff --git a/programs/wineboot/wineboot_Fr.rc b/programs/wineboot/wineboot_Fr.rc index 6229e9030f1..b24c5d11009 100644 --- a/programs/wineboot/wineboot_Fr.rc +++ b/programs/wineboot/wineboot_Fr.rc @@ -18,9 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA * */ - -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL @@ -37,3 +34,5 @@ BEGIN LTEXT "Si vous arrêtez le programme, vous pouvez perdre toutes les données non enregistrées.", IDC_STATIC,7,28,172,15 END + +#pragma code_page(default) diff --git a/programs/wineboot/wineboot_Ja.rc b/programs/wineboot/wineboot_Ja.rc index cee0bd20439..90f252a3a20 100644 --- a/programs/wineboot/wineboot_Ja.rc +++ b/programs/wineboot/wineboot_Ja.rc @@ -19,8 +19,6 @@ * */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -38,3 +36,5 @@ BEGIN LTEXT "プロセスを終了させると、保存していないデータは全て失われます。", IDC_STATIC,7,28,262,15 END + +#pragma code_page(default) diff --git a/programs/wineboot/wineboot_Ko.rc b/programs/wineboot/wineboot_Ko.rc index 28bcd4b4761..a84d6ac9380 100644 --- a/programs/wineboot/wineboot_Ko.rc +++ b/programs/wineboot/wineboot_Ko.rc @@ -20,8 +20,6 @@ * */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT diff --git a/programs/wineboot/wineboot_Lt.rc b/programs/wineboot/wineboot_Lt.rc index 7db56e9358d..4edf2bc1a81 100644 --- a/programs/wineboot/wineboot_Lt.rc +++ b/programs/wineboot/wineboot_Lt.rc @@ -19,8 +19,6 @@ * */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -38,3 +36,5 @@ BEGIN LTEXT "Jei nutrauksite procesą, tai galite prarasti visus neišsaugotus duomenis.", IDC_STATIC,7,28,172,17 END + +#pragma code_page(default) diff --git a/programs/wineboot/wineboot_Nl.rc b/programs/wineboot/wineboot_Nl.rc index c22a5c5da1f..86fc3376986 100644 --- a/programs/wineboot/wineboot_Nl.rc +++ b/programs/wineboot/wineboot_Nl.rc @@ -19,8 +19,6 @@ * */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL IDD_ENDTASK DIALOG DISCARDABLE 0, 0, 186, 71 diff --git a/programs/wineboot/wineboot_No.rc b/programs/wineboot/wineboot_No.rc index d821945b7fe..b8ce1f5c894 100644 --- a/programs/wineboot/wineboot_No.rc +++ b/programs/wineboot/wineboot_No.rc @@ -19,8 +19,6 @@ * */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL IDD_ENDTASK DIALOG DISCARDABLE 0, 0, 186, 71 diff --git a/programs/wineboot/wineboot_Pl.rc b/programs/wineboot/wineboot_Pl.rc index 3172d366bed..c2460fdf4a4 100644 --- a/programs/wineboot/wineboot_Pl.rc +++ b/programs/wineboot/wineboot_Pl.rc @@ -20,8 +20,6 @@ * */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT IDD_ENDTASK DIALOG DISCARDABLE 0, 0, 186, 71 diff --git a/programs/wineboot/wineboot_Pt.rc b/programs/wineboot/wineboot_Pt.rc index a0338ca6a4d..ae5561d8c74 100644 --- a/programs/wineboot/wineboot_Pt.rc +++ b/programs/wineboot/wineboot_Pt.rc @@ -19,8 +19,6 @@ * */ -#include "resource.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL IDD_ENDTASK DIALOG DISCARDABLE 0, 0, 186, 71 diff --git a/programs/wineboot/wineboot_Ro.rc b/programs/wineboot/wineboot_Ro.rc index 61f670f7af4..56398824f53 100644 --- a/programs/wineboot/wineboot_Ro.rc +++ b/programs/wineboot/wineboot_Ro.rc @@ -20,8 +20,6 @@ * */ -#include "resource.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -38,3 +36,5 @@ BEGIN LTEXT "Prin terminarea acestui proces se pot pierde datele nesalvate.", IDC_STATIC,7,28,172,15 END + +#pragma code_page(default) diff --git a/programs/wineboot/wineboot_Ru.rc b/programs/wineboot/wineboot_Ru.rc index ef777bcb885..cb1a9d38358 100644 --- a/programs/wineboot/wineboot_Ru.rc +++ b/programs/wineboot/wineboot_Ru.rc @@ -19,22 +19,17 @@ * */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT IDD_ENDTASK DIALOG DISCARDABLE 0, 0, 186, 71 STYLE DS_MODALFRAME | DS_NOIDLEMSG | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Ожидание программы" +CAPTION "Îæèäàíèå ïðîãðàììû" FONT 8, "MS Shell Dlg" BEGIN - DEFPUSHBUTTON "Отмена",IDCANCEL,129,49,50,15 - PUSHBUTTON "Завершить Процесс",IDOK,51,49,71,15 - LTEXT "Происходит смена пользователя или выключение, но эта программа не отвечает.", + DEFPUSHBUTTON "Îòìåíà",IDCANCEL,129,49,50,15 + PUSHBUTTON "Çàâåðøèòü Ïðîöåññ",IDOK,51,49,71,15 + LTEXT "Ïðîèñõîäèò ñìåíà ïîëüçîâàòåëÿ èëè âûêëþ÷åíèå, íî ýòà ïðîãðàììà íå îòâå÷àåò.", IDC_STATIC,7,7,172,19 - LTEXT "Если закрыть программу прямо сейчас, то можно потерять все несохраненные данные.", + LTEXT "Åñëè çàêðûòü ïðîãðàììó ïðÿìî ñåé÷àñ, òî ìîæíî ïîòåðÿòü âñå íåñîõðàíåííûå äàííûå.", IDC_STATIC,7,28,172,15 END diff --git a/programs/wineboot/wineboot_Si.rc b/programs/wineboot/wineboot_Si.rc index 366f170761c..1cbc097f0ab 100644 --- a/programs/wineboot/wineboot_Si.rc +++ b/programs/wineboot/wineboot_Si.rc @@ -19,8 +19,6 @@ * */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -37,3 +35,5 @@ BEGIN LTEXT "Če se odločite za končanje programa, lahko izgubite neshranjene podatke.", IDC_STATIC,7,28,172,15 END + +#pragma code_page(default) diff --git a/programs/wineboot/wineboot_Sv.rc b/programs/wineboot/wineboot_Sv.rc index 046432b4299..6877735c372 100644 --- a/programs/wineboot/wineboot_Sv.rc +++ b/programs/wineboot/wineboot_Sv.rc @@ -19,8 +19,6 @@ * */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL IDD_ENDTASK DIALOG DISCARDABLE 0, 0, 186, 71 diff --git a/programs/wineboot/wineboot_Zh.rc b/programs/wineboot/wineboot_Zh.rc index d85f9d49dc3..75c56d335a3 100644 --- a/programs/wineboot/wineboot_Zh.rc +++ b/programs/wineboot/wineboot_Zh.rc @@ -19,8 +19,6 @@ * */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -53,3 +51,5 @@ BEGIN LTEXT "如果你中斷進程,有可能丟失沒有儲存的數據.", IDC_STATIC,7,28,172,15 END + +#pragma code_page(default) diff --git a/programs/winebrowser/main.c b/programs/winebrowser/main.c index b959d38adad..d551c208709 100644 --- a/programs/winebrowser/main.c +++ b/programs/winebrowser/main.c @@ -66,15 +66,6 @@ static char *strdup_unixcp( const WCHAR *str ) return ret; } -static WCHAR *strdupW( const WCHAR *src ) -{ - WCHAR *dst; - if (!src) return NULL; - if ((dst = HeapAlloc( GetProcessHeap(), 0, (strlenW( src ) + 1) * sizeof(WCHAR) ))) - strcpyW( dst, src ); - return dst; -} - /* try to launch a unix app from a comma separated string of app names */ static int launch_app( WCHAR *candidates, const WCHAR *argv1 ) { @@ -338,7 +329,7 @@ int wmain(int argc, WCHAR *argv[]) static const WCHAR mailtoW[] = {'m','a','i','l','t','o',':',0}; static const WCHAR fileW[] = {'f','i','l','e',':',0}; - WCHAR *p, *filenameW = NULL, *fileurlW = NULL, *url = argv[1]; + WCHAR *url = argv[1]; wine_get_unix_file_name_t wine_get_unix_file_name_ptr; int ret = 1; @@ -356,6 +347,7 @@ int wmain(int argc, WCHAR *argv[]) /* handle an RFC1738 file URL */ if (!strncmpiW( url, fileW, 5 )) { + WCHAR *p; DWORD len = strlenW( url ) + 1; if (UrlUnescapeW( url, NULL, &len, URL_UNESCAPE_INPLACE ) != S_OK) @@ -398,38 +390,20 @@ int wmain(int argc, WCHAR *argv[]) else { char *unixpath; - WCHAR c = 0; - - if (!(filenameW = strdupW( url ))) goto done; - if ((p = strchrW( filenameW, '?' )) || (p = strchrW( filenameW, '#' ))) - { - c = *p; - *p = 0; - } - - if ((unixpath = wine_get_unix_file_name_ptr( filenameW ))) + if ((unixpath = wine_get_unix_file_name_ptr( url ))) { struct stat dummy; if (stat( unixpath, &dummy ) >= 0) { - static const WCHAR schemeW[] = {'f','i','l','e',':','/','/',0}; - int len, len_scheme; - - len = len_scheme = strlenW( schemeW ); - len += MultiByteToWideChar( CP_UNIXCP, 0, unixpath, -1, NULL, 0 ); - if (p) - { - *p = c; - len += strlenW( p ); - } - - if (!(fileurlW = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) ))) goto done; + int len; + WCHAR *unixpathW; - strcpyW( fileurlW, schemeW ); - MultiByteToWideChar( CP_UNIXCP, 0, unixpath, -1, fileurlW + len_scheme, len - len_scheme ); - if (p) strcatW( fileurlW, p ); + len = MultiByteToWideChar( CP_UNIXCP, 0, unixpath, -1, NULL, 0 ); + if ((unixpathW = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) ))) + MultiByteToWideChar( CP_UNIXCP, 0, unixpath, -1, unixpathW, len ); - ret = open_http_url( fileurlW ); + ret = open_http_url( unixpathW ); + HeapFree( GetProcessHeap(), 0, unixpathW ); goto done; } } @@ -443,7 +417,5 @@ int wmain(int argc, WCHAR *argv[]) done: HeapFree(GetProcessHeap(), 0, ddeString); - HeapFree( GetProcessHeap(), 0, filenameW ); - HeapFree( GetProcessHeap(), 0, fileurlW ); return ret; } diff --git a/programs/winecfg/Bg.rc b/programs/winecfg/Bg.rc index ce2c8c7fcba..cf9101227d7 100644 --- a/programs/winecfg/Bg.rc +++ b/programs/winecfg/Bg.rc @@ -20,9 +20,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT IDR_WINECFG MENU DISCARDABLE @@ -47,8 +44,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Windows Registration Information ", IDC_STATIC, 15, 110, 230, 55 LTEXT "Owner:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "Organization:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END diff --git a/programs/winecfg/Cs.rc b/programs/winecfg/Cs.rc index 348153c2ffd..88972376e64 100644 --- a/programs/winecfg/Cs.rc +++ b/programs/winecfg/Cs.rc @@ -24,10 +24,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA * */ - -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - /* Czech strings in CP1250 */ LANGUAGE LANG_CZECH, SUBLANG_DEFAULT @@ -50,8 +46,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Windows Registration Information ", IDC_STATIC, 15, 110, 230, 55 LTEXT "Owner:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "Organization:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END diff --git a/programs/winecfg/Da.rc b/programs/winecfg/Da.rc index a604ea31886..a1c9653e95c 100644 --- a/programs/winecfg/Da.rc +++ b/programs/winecfg/Da.rc @@ -20,9 +20,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT IDR_WINECFG MENU DISCARDABLE @@ -44,8 +41,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Windows registreringsoplysninger ", IDC_STATIC, 15, 110, 230, 55 LTEXT "Ejer:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "Organisationen:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END diff --git a/programs/winecfg/De.rc b/programs/winecfg/De.rc index 8f703999851..614247b3b4d 100644 --- a/programs/winecfg/De.rc +++ b/programs/winecfg/De.rc @@ -20,11 +20,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL IDR_WINECFG MENU DISCARDABLE @@ -42,13 +37,13 @@ BEGIN LTEXT PACKAGE_STRING,IDC_STATIC,119,17,120,8 CONTROL IDB_WINE,IDC_STATIC,"Static",SS_BITMAP ,15,17,157,111 LTEXT "http://www.winehq.org/",IDC_STATIC,119,31,106,8 - LTEXT "Diese Bibliothek ist freie Software; Sie dürfen sie unter den Bedingungen der GNU Lesser General Public License, wie von der Free Software Foundation veröffentlicht, weiterverteilen und/oder modifizieren; entweder gemäß Version 2.1 der Lizenz oder (nach Ihrer Option) jeder späteren Version.", + LTEXT "Diese Bibliothek ist freie Software; Sie dürfen sie unter den Bedingungen der GNU Lesser General Public License, wie von der Free Software Foundation veröffentlicht, weiterverteilen und/oder modifizieren; entweder gemäß Version 2.1 der Lizenz oder (nach Ihrer Option) jeder späteren Version.", IDC_STATIC,119,44,124,72 - GROUPBOX " Windows-Registrierungs-Informationen ", IDC_STATIC, 15, 120, 230, 55 - LTEXT "&Eigentümer:", IDC_STATIC, 22, 136, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 136, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "&Organisation:", IDC_STATIC, 22, 150, 50, 20 - EDITTEXT IDC_ABT_ORG, 75, 150, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP + GROUPBOX " Windows-Registrierungs-Informationen ", IDC_STATIC, 15, 110, 230, 55 + LTEXT "Eigentümer:", IDC_STATIC, 22, 126, 40, 20 + LTEXT "Organisation:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP + EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END IDD_APPCFG DIALOG DISCARDABLE 0, 0, 260, 250 @@ -56,11 +51,11 @@ STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN GROUPBOX " Anwendungseinstellungen ",IDC_STATIC, 8,4,244,250 - LTEXT "Wine kann für jede Anwendung eine unterschiedliche Windows-Version nachahmen. Dieser Reiter ist mit den Bibliothek- und Grafik-Reiter verknüpft, damit entweder systemweite oder anwendungsabhängige Einstellungen in diesen Reitern vorgenommen werden können.", + LTEXT "Wine kann für jede Anwendung eine unterschiedliche Windows-Version nachahmen. Dieser Reiter ist mit den Bibliothek- und Grafik-Reiter verknüpft, damit entweder systemweite oder anwendungsabhängige Einstellungen in diesen Reitern vorgenommen werden können.", IDC_STATIC,15,15,227,43 CONTROL "Anwendungen",IDC_APP_LISTVIEW,"SysListView32",WS_BORDER | WS_TABSTOP | LVS_LIST | LVS_SINGLESEL | LVS_SHOWSELALWAYS, 15,58,230,152 - PUSHBUTTON "Anw. &hinzufügen",IDC_APP_ADDAPP, 90,214,75,14 + PUSHBUTTON "Anw. &hinzufügen",IDC_APP_ADDAPP, 90,214,75,14 PUSHBUTTON "Anw. &entfernen",IDC_APP_REMOVEAPP, 170,214,75,14 LTEXT "&Windows Version:",IDC_STATIC,17,236,58,8 COMBOBOX IDC_WINVER,83,234,163,56,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP @@ -71,22 +66,22 @@ STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN GROUPBOX " Fenstereinstellungen ",IDC_STATIC,8,4,244,84 - CONTROL "DirectX-Anwendungen können Maus einfangen",IDC_DX_MOUSE_GRAB,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,20,230,8 + CONTROL "DirectX-Anwendungen können Maus einfangen",IDC_DX_MOUSE_GRAB,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,20,230,8 CONTROL "Erlaube dem Fenstermanager die Fenster zu &dekorieren",IDC_ENABLE_DECORATED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,32,230,8 CONTROL "Erlaube dem Fenstermanager die Fenster zu kontrollieren.",IDC_ENABLE_MANAGED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,44,230,8 CONTROL "Emuliere einen virtuellen Bildschirm",IDC_ENABLE_DESKTOP,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,15,56,230,8 - LTEXT "Desktop-Größe:",IDC_DESKTOP_SIZE,15,70,44,8,WS_DISABLED + LTEXT "Desktop-Größe:",IDC_DESKTOP_SIZE,15,70,44,8,WS_DISABLED LTEXT "X",IDC_DESKTOP_BY,109,70,8,8,WS_DISABLED EDITTEXT IDC_DESKTOP_WIDTH,64,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED EDITTEXT IDC_DESKTOP_HEIGHT,117,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED GROUPBOX " Direct3D ",IDC_STATIC,8,95,244,49 - LTEXT "Unterstützung für Vertex Shader: ",IDC_STATIC,15,110,80,32 + LTEXT "Unterstützung für Vertex Shader: ",IDC_STATIC,15,110,80,32 COMBOBOX IDC_D3D_VSHADER_MODE,100,108,145,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - CONTROL "Pixel Shader aktivieren (wenn von Hardware unterstützt)", IDC_D3D_PSHADER_MODE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,126,230,10 + CONTROL "Pixel Shader aktivieren (wenn von Hardware unterstützt)", IDC_D3D_PSHADER_MODE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,126,230,10 - GROUPBOX " Bildschi&rmauflösung ",IDC_STATIC,8,151,244,93 + GROUPBOX " Bildschi&rmauflösung ",IDC_STATIC,8,151,244,93 CONTROL "", IDC_RES_TRACKBAR, "msctls_trackbar32",WS_TABSTOP,12,161,187,15 EDITTEXT IDC_RES_DPIEDIT,204,161,23,13,ES_NUMBER|WS_TABSTOP LTEXT "dpi",IDC_STATIC,235,163,10,8 @@ -97,13 +92,13 @@ IDD_DLLCFG DIALOG DISCARDABLE 0, 0, 260, 250 STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX " DLL Überschreibung ",IDC_STATIC,8,4,244,240 - LTEXT "DLLs (Dynamic Link Libraries) können einzeln eingestellt werden, entweder Builtin (gestellt durch Wine) oder Native (von Windows oder durch die Anwendung gestellt)." + GROUPBOX " DLL Überschreibung ",IDC_STATIC,8,4,244,240 + LTEXT "DLLs (Dynamic Link Libraries) können einzeln eingestellt werden, entweder Builtin (gestellt durch Wine) oder Native (von Windows oder durch die Anwendung gestellt)." , IDC_STATIC,15,17,228,32 - LTEXT "Neue Überschreibung für:",IDC_STATIC,16,58,100,8 + LTEXT "Neue Überschreibung für:",IDC_STATIC,16,58,100,8 COMBOBOX IDC_DLLCOMBO,16,68,140,14,CBS_DROPDOWN | WS_VSCROLL | WS_TABSTOP | CBS_SORT | CBS_LOWERCASE - PUSHBUTTON "&Hinzufügen ",IDC_DLLS_ADDDLL, 164,68,82,13,BS_DEFPUSHBUTTON - LTEXT "Bestehende Überschreibungen:",IDC_STATIC,16,86,100,8 + PUSHBUTTON "&Hinzufügen ",IDC_DLLS_ADDDLL, 164,68,82,13,BS_DEFPUSHBUTTON + LTEXT "Bestehende Überschreibungen:",IDC_STATIC,16,86,100,8 LISTBOX IDC_DLLS_LIST,16,96,140,140,WS_BORDER | WS_TABSTOP | WS_VSCROLL PUSHBUTTON "&Bearbeiten",IDC_DLLS_EDITDLL,164,96,82,14 PUSHBUTTON "&Entfernen",IDC_DLLS_REMOVEDLL,164,114,82,14 @@ -111,7 +106,7 @@ END IDD_LOADORDER DIALOG DISCARDABLE 80, 90, 110, 92 STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Bearbeite Überschreibung" +CAPTION "Bearbeite Überschreibung" FONT 8, "MS Shell Dlg" BEGIN GROUPBOX " Ladereihenfolge ",IDC_STATIC,8,4,94,66 @@ -132,7 +127,7 @@ BEGIN LTEXT "Failed to connect to the mount manager, the drive configuration cannot be edited.", IDC_STATIC_MOUNTMGR_ERROR, 15,30,220,76 CONTROL "Listview",IDC_LIST_DRIVES,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,18,232,76 - PUSHBUTTON "&Hinzufügen",IDC_BUTTON_ADD,15,98,41,14 + PUSHBUTTON "&Hinzufügen",IDC_BUTTON_ADD,15,98,41,14 PUSHBUTTON "&Entfernen",IDC_BUTTON_REMOVE,60,98,37,14 PUSHBUTTON "&Automatisch", IDC_BUTTON_AUTODETECT,197,98,49,14 @@ -147,7 +142,7 @@ BEGIN LTEXT "Bezeichnung und Seriennummer",IDC_LABELSERIAL_STATIC,15,155,125,10 PUSHBUTTON "&Zeige Erweitert",IDC_BUTTON_SHOW_HIDE_ADVANCED,178,136,68,13 - CONTROL "Automatisch &vom Gerät:",IDC_RADIO_AUTODETECT,"Button", + CONTROL "Automatisch &vom Gerät:",IDC_RADIO_AUTODETECT,"Button", BS_AUTORADIOBUTTON,15,166,93,10 EDITTEXT IDC_EDIT_DEVICE,27,176,169,13,ES_AUTOHSCROLL PUSHBUTTON "Durch&suchen",IDC_BUTTON_BROWSE_DEVICE,201,176,45,13 @@ -167,8 +162,8 @@ STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN GROUPBOX " Treiberauswahl ",IDC_STATIC,8,4,244,195 - LTEXT "Wählen Sie einen Sound-Treiber durch ankreuzen des gewünschten Treibers. Ist kein Treiber ausgewählt, wird der Sound deaktiviert. Die Auswahl mehrerer Treiber ist nicht empfohlen. Ein Treiber kann durch Rechtsklicken konfiguriert werden.",IDC_STATIC,15,15,227,35 - CONTROL "Geräte",IDC_AUDIO_TREE,"SysTreeView32",WS_BORDER | WS_TABSTOP,15,50,140,140 + LTEXT "Wählen Sie einen Sound-Treiber durch ankreuzen des gewünschten Treibers. Ist kein Treiber ausgewählt, wird der Sound deaktiviert. Die Auswahl mehrerer Treiber ist nicht empfohlen. Ein Treiber kann durch Rechtsklicken konfiguriert werden.",IDC_STATIC,15,15,227,35 + CONTROL "Geräte",IDC_AUDIO_TREE,"SysTreeView32",WS_BORDER | WS_TABSTOP,15,50,140,140 PUSHBUTTON "&Test Sound",IDC_AUDIO_TEST,170,50,59,14 PUSHBUTTON "Einstellungen",IDC_AUDIO_CONTROL_PANEL,170,70,59,14 GROUPBOX " DirectSound ",IDC_STATIC,8,205,244,60 @@ -191,22 +186,22 @@ BEGIN PUSHBUTTON "Motiv installieren...",IDC_THEME_INSTALL,152,23,93,14 LTEXT "Farbe:",IDC_THEME_COLORTEXT,15,40,112,8 COMBOBOX IDC_THEME_COLORCOMBO,15,48,112,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Größe:",IDC_THEME_SIZETEXT,135,40,110,8 + LTEXT "Größe:",IDC_THEME_SIZETEXT,135,40,110,8 COMBOBOX IDC_THEME_SIZECOMBO,135,48,110,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP LTEXT "Element:",IDC_STATIC,15,64,112,8 COMBOBOX IDC_SYSPARAM_COMBO,15,74,112,120,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP | CBS_SORT LTEXT "Farbe:",IDC_SYSPARAM_COLOR_TEXT,135,64,25,8,WS_DISABLED PUSHBUTTON "",IDC_SYSPARAM_COLOR,135,74,25,13,WS_DISABLED | BS_OWNERDRAW - LTEXT "Größe:",IDC_SYSPARAM_SIZE_TEXT,166,64,30,8,WS_DISABLED + LTEXT "Größe:",IDC_SYSPARAM_SIZE_TEXT,166,64,30,8,WS_DISABLED EDITTEXT IDC_SYSPARAM_SIZE,166,74,23,13,ES_AUTOHSCROLL | WS_TABSTOP | WS_DISABLED CONTROL "",IDC_SYSPARAM_SIZE_UD,UPDOWN_CLASS,UDS_SETBUDDYINT | WS_DISABLED,187,74,15,13 PUSHBUTTON "Schrift",IDC_SYSPARAM_FONT,208,74,37,13,WS_DISABLED GROUPBOX " Shell-Ordner ",IDC_STATIC,8,114,244,100 CONTROL "Listview",IDC_LIST_SFPATHS,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,126,230,64 - CONTROL "Verknüpfe:",IDC_LINK_SFPATH,"Button",BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED,15,195,50,13 + CONTROL "Verknüpfe:",IDC_LINK_SFPATH,"Button",BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED,15,195,50,13 EDITTEXT IDC_EDIT_SFPATH,65,195,145,13,ES_AUTOHSCROLL|WS_TABSTOP|WS_DISABLED - PUSHBUTTON "Wählen",IDC_BROWSE_SFPATH,215,195,30,13,WS_DISABLED + PUSHBUTTON "Wählen",IDC_BROWSE_SFPATH,215,195,30,13,WS_DISABLED END STRINGTABLE DISCARDABLE @@ -214,26 +209,26 @@ BEGIN IDS_TAB_APPLICATIONS "Anwendungen" IDS_TAB_DLLS "Bibliotheken" IDS_TAB_DRIVES "Laufwerke" - IDS_CHOOSE_PATH "Bitte wählen Sie das Ziel-Unix-Verzeichnis." + IDS_CHOOSE_PATH "Bitte wählen Sie das Ziel-Unix-Verzeichnis." IDS_HIDE_ADVANCED "Verstecke Erweitert" IDS_SHOW_ADVANCED "Zeige Erweitert" IDS_NOTHEME "(Kein Motiv)" IDS_TAB_GRAPHICS "Grafik" IDS_TAB_DESKTOP_INTEGRATION "Desktop-Integration" IDS_TAB_AUDIO "Audio" - IDS_TAB_ABOUT "Über" + IDS_TAB_ABOUT "Über" IDS_WINECFG_TITLE "Wine-Konfiguration" - IDS_WINECFG_TITLE_APP "Wine-Konfiguration für %s" + IDS_WINECFG_TITLE_APP "Wine-Konfiguration für %s" IDS_THEMEFILE "Motiv-Dateien" - IDS_THEMEFILE_SELECT "Motiv-Datei auswählen" - IDS_AUDIO_MISSING "Zur Zeit ist kein Audio Treiber in der Registry eingetragen.\n\nEin bevorzugter Treiber wurde für Sie ausgewählt.\nSie können diesen Treiber nutzen oder einen anderen verfügbaren Treiber auswählen.\n\nSie müssen auf Anwenden klicken, damit die Änderung übernommen wird." + IDS_THEMEFILE_SELECT "Motiv-Datei auswählen" + IDS_AUDIO_MISSING "Zur Zeit ist kein Audio Treiber in der Registry eingetragen.\n\nEin bevorzugter Treiber wurde für Sie ausgewählt.\nSie können diesen Treiber nutzen oder einen anderen verfügbaren Treiber auswählen.\n\nSie müssen auf Anwenden klicken, damit die Änderung übernommen wird." IDS_SHELL_FOLDER "Shell-Ordner" - IDS_LINKS_TO "Verknüpft mit" + IDS_LINKS_TO "Verknüpft mit" END STRINGTABLE DISCARDABLE BEGIN - IDS_DLL_WARNING "Das Ändern der Ladereihenfolge dieser Bibliothek wird nicht empfohlen.\nSind Sie sich sicher, dass Sie dies möchten?" + IDS_DLL_WARNING "Das Ändern der Ladereihenfolge dieser Bibliothek wird nicht empfohlen.\nSind Sie sich sicher, dass Sie dies möchten?" IDS_DLL_WARNING_CAPTION "Achtung: Systembibliothek" IDS_DLL_NATIVE "Native (Windows)" IDS_DLL_BUILTIN "Builtin (Wine)" @@ -243,7 +238,7 @@ BEGIN IDS_DEFAULT_SETTINGS "Standardeinstellungen" IDS_EXECUTABLE_FILTER "Wine-Programme (*.exe,*.exe.so)\0*.exe;*.exe.so\0" IDS_USE_GLOBAL_SETTINGS "Globale Einstellung benutzen" - IDS_SELECT_EXECUTABLE "Ausführbares Programm auswählen" + IDS_SELECT_EXECUTABLE "Ausführbares Programm auswählen" END STRINGTABLE DISCARDABLE @@ -259,12 +254,12 @@ BEGIN IDS_DRIVE_REMOTE "Netzwerkfreigabe" IDS_DRIVE_REMOVABLE "Diskette" IDS_DRIVE_CDROM "CD-ROM" - IDS_DRIVE_LETTERS_EXCEEDED "Sie können keine weiteren Laufwerke mehr hinzufügen.\n\nJedes Laufwerk muss einen Buchstaben besitzen, von A bis Z, deshalb können Sie nicht mehr als 26 haben." + IDS_DRIVE_LETTERS_EXCEEDED "Sie können keine weiteren Laufwerke mehr hinzufügen.\n\nJedes Laufwerk muss einen Buchstaben besitzen, von A bis Z, deshalb können Sie nicht mehr als 26 haben." IDS_SYSTEM_DRIVE_LABEL "Systemlaufwerk" - IDS_CONFIRM_DELETE_C "Sind Sie sich sicher, dass Sie Laufwerk C entfernen möchten?\n\nDie meisten Windows-Anwendungen erwarten, dass ein Laufwerk C existiert und funktionieren ohne nicht richtig. Wenn Sie fortfahren, vergessen Sie nicht, Laufwerk C neu zu erstellen!" + IDS_CONFIRM_DELETE_C "Sind Sie sich sicher, dass Sie Laufwerk C entfernen möchten?\n\nDie meisten Windows-Anwendungen erwarten, dass ein Laufwerk C existiert und funktionieren ohne nicht richtig. Wenn Sie fortfahren, vergessen Sie nicht, Laufwerk C neu zu erstellen!" IDS_COL_DRIVELETTER "Buchst." IDS_COL_DRIVEMAPPING "Zuordnung" - IDS_NO_DRIVE_C "Sie haben kein Laufwerk C. Das ist nicht so gut.\n\nVergessen Sie nicht, im Laufwerke-Reiter „Hinzufügen“ zu klicken um eins zu erstellen!\n" + IDS_NO_DRIVE_C "Sie haben kein Laufwerk C. Das ist nicht so gut.\n\nVergessen Sie nicht, im Laufwerke-Reiter „Hinzufügen“ zu klicken um eins zu erstellen!\n" END STRINGTABLE DISCARDABLE @@ -281,15 +276,15 @@ BEGIN IDS_DRIVER_NAS "NAS-Treiber" IDS_DRIVER_AUDIOIO "Audio-IO-Treiber (Solaris)" IDS_DRIVER_COREAUDIO "CoreAudio-Treiber" - IDS_OPEN_DRIVER_ERROR "Konnte %s nicht öffnen!" + IDS_OPEN_DRIVER_ERROR "Konnte %s nicht öffnen!" IDS_SOUNDDRIVERS "Sound_Treiber" - IDS_DEVICES_WAVEOUT "Wave-Ausgabe-Geräte" - IDS_DEVICES_WAVEIN "Wave-Eingabe-Geräte" - IDS_DEVICES_MIDIOUT "MIDI-Ausgabe-Geräte" - IDS_DEVICES_MIDIIN "MIDI-Ausgabe-Geräte" - IDS_DEVICES_AUX "Aux-Geräte" - IDS_DEVICES_MIXER "Mixer-Geräte" - IDS_UNAVAILABLE_DRIVER "In der Registry wurde ein Treiber gefunden, der nicht verfügbar ist!\n\nSoll „%s“ aus der Registry entfernt werden?" + IDS_DEVICES_WAVEOUT "Wave-Ausgabe-Geräte" + IDS_DEVICES_WAVEIN "Wave-Eingabe-Geräte" + IDS_DEVICES_MIDIOUT "MIDI-Ausgabe-Geräte" + IDS_DEVICES_MIDIIN "MIDI-Ausgabe-Geräte" + IDS_DEVICES_AUX "Aux-Geräte" + IDS_DEVICES_MIXER "Mixer-Geräte" + IDS_UNAVAILABLE_DRIVER "In der Registry wurde ein Treiber gefunden, der nicht verfügbar ist!\n\nSoll „%s“ aus der Registry entfernt werden?" IDS_WARNING "Warnung" END @@ -298,8 +293,8 @@ BEGIN IDC_SYSPARAMS_BUTTON "Steuerelementhintergrund" IDC_SYSPARAMS_BUTTON_TEXT "Steuerelementtext" IDC_SYSPARAMS_DESKTOP "Desktop" - IDC_SYSPARAMS_MENU "Menühintergrund" - IDC_SYSPARAMS_MENU_TEXT "Menütext" + IDC_SYSPARAMS_MENU "Menühintergrund" + IDC_SYSPARAMS_MENU_TEXT "Menütext" IDC_SYSPARAMS_SCROLLBAR "Bildlaufleiste" IDC_SYSPARAMS_SELECTION "Auswahlhintergrund" IDC_SYSPARAMS_SELECTION_TEXT "Auswahltext" @@ -322,9 +317,9 @@ BEGIN IDC_SYSPARAMS_BUTTON_DARK_SHADOW "Dunkler Steuerelementschatten" IDC_SYSPARAMS_BUTTON_LIGHT "Steuerelementerhellung" IDC_SYSPARAMS_BUTTON_ALTERNATE "Alternativer Steuerelementhintergrund" - IDC_SYSPARAMS_HOT_TRACKING "Heiß verfolgtes Element" + IDC_SYSPARAMS_HOT_TRACKING "Heiß verfolgtes Element" IDC_SYSPARAMS_ACTIVE_TITLE_GRADIENT "Gradient der aktiven Titelleiste" IDC_SYSPARAMS_INACTIVE_TITLE_GRADIENT "Gradient der inaktiven Titelleiste" - IDC_SYSPARAMS_MENU_HILIGHT "Menühervorhebung" - IDC_SYSPARAMS_MENUBAR "Menütitelleiste" + IDC_SYSPARAMS_MENU_HILIGHT "Menühervorhebung" + IDC_SYSPARAMS_MENUBAR "Menütitelleiste" END diff --git a/programs/winecfg/En.rc b/programs/winecfg/En.rc index 0ceb60efef1..b165a817876 100644 --- a/programs/winecfg/En.rc +++ b/programs/winecfg/En.rc @@ -22,9 +22,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT IDR_WINECFG MENU DISCARDABLE @@ -45,9 +42,9 @@ BEGIN LTEXT "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.", IDC_STATIC,119,44,124,72 GROUPBOX " Windows Registration Information ", IDC_STATIC, 15, 110, 230, 55 - LTEXT "&Owner:", IDC_STATIC, 22, 126, 40, 20 + LTEXT "Owner:", IDC_STATIC, 22, 126, 40, 20 + LTEXT "Organization:", IDC_STATIC, 22, 140, 50, 20 EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "Organi&zation:", IDC_STATIC, 22, 140, 50, 20 EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END @@ -264,7 +261,7 @@ BEGIN IDS_CONFIRM_DELETE_C "Are you sure you want to delete drive C?\n\nMost Windows applications expect drive C to exist, and will die messily if it doesn't. If you proceed remember to recreate it!" IDS_COL_DRIVELETTER "Letter" IDS_COL_DRIVEMAPPING "Drive Mapping" - IDS_NO_DRIVE_C "You don't have a drive C. This is not so great.\n\nRemember to click 'Add' in the Drives tab to create one!\n" + IDS_NO_DRIVE_C "You don't have a drive C. This is not so great.\n\nRemember to click ‘Add’ in the Drives tab to create one!\n" END STRINGTABLE DISCARDABLE @@ -289,7 +286,7 @@ BEGIN IDS_DEVICES_MIDIIN "MIDI In Devices" IDS_DEVICES_AUX "Aux Devices" IDS_DEVICES_MIXER "Mixer Devices" - IDS_UNAVAILABLE_DRIVER "Found driver in registry that is not available!\n\nRemove '%s' from registry?" + IDS_UNAVAILABLE_DRIVER "Found driver in registry that is not available!\n\nRemove “%s” from registry?" IDS_WARNING "Warning" END @@ -328,70 +325,3 @@ BEGIN IDC_SYSPARAMS_MENU_HILIGHT "Menu Highlight" IDC_SYSPARAMS_MENUBAR "Menu Bar" END - -LANGUAGE LANG_ENGLISH, SUBLANG_NEUTRAL - -IDD_DESKTOP_INTEGRATION DIALOG DISCARDABLE 0, 0, 260, 250 -STYLE WS_CHILD | WS_DISABLED -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Appearance ",IDC_STATIC,8,4,244,106 - LTEXT "&Theme:",IDC_STATIC,15,16,130,8 - COMBOBOX IDC_THEME_THEMECOMBO,15,24,130,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Install theme...",IDC_THEME_INSTALL,152,23,93,14 - LTEXT "&Colour:",IDC_THEME_COLORTEXT,15,40,112,8 - COMBOBOX IDC_THEME_COLORCOMBO,15,48,112,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "&Size:",IDC_THEME_SIZETEXT,135,40,110,8 - COMBOBOX IDC_THEME_SIZECOMBO,135,48,110,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "It&em:",IDC_STATIC,15,64,112,8 - COMBOBOX IDC_SYSPARAM_COMBO,15,74,112,120,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP | CBS_SORT - LTEXT "C&olour:",IDC_SYSPARAM_COLOR_TEXT,135,64,25,8,WS_DISABLED - PUSHBUTTON "",IDC_SYSPARAM_COLOR,135,74,25,13,WS_DISABLED | BS_OWNERDRAW - LTEXT "Si&ze:",IDC_SYSPARAM_SIZE_TEXT,166,64,30,8,WS_DISABLED - EDITTEXT IDC_SYSPARAM_SIZE,166,74,23,13,ES_AUTOHSCROLL | WS_TABSTOP | WS_DISABLED - CONTROL "",IDC_SYSPARAM_SIZE_UD,UPDOWN_CLASS,UDS_SETBUDDYINT | WS_DISABLED,187,74,15,13 - PUSHBUTTON "&Font...",IDC_SYSPARAM_FONT,208,74,37,13,WS_DISABLED - GROUPBOX " Fol&ders ",IDC_STATIC,8,114,244,100 - CONTROL "Listview",IDC_LIST_SFPATHS,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | - LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,126,230,64 - CONTROL "&Link to:",IDC_LINK_SFPATH,"Button",BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED,15,195,50,13 - EDITTEXT IDC_EDIT_SFPATH,65,195,125,13,ES_AUTOHSCROLL|WS_TABSTOP|WS_DISABLED - PUSHBUTTON "B&rowse...",IDC_BROWSE_SFPATH,195,195,50,13,WS_DISABLED -END - - -STRINGTABLE DISCARDABLE -BEGIN - IDC_SYSPARAMS_BUTTON "Controls Background" - IDC_SYSPARAMS_BUTTON_TEXT "Controls Text" - IDC_SYSPARAMS_DESKTOP "Desktop" - IDC_SYSPARAMS_MENU "Menu Background" - IDC_SYSPARAMS_MENU_TEXT "Menu Text" - IDC_SYSPARAMS_SCROLLBAR "Scrollbar" - IDC_SYSPARAMS_SELECTION "Selection Background" - IDC_SYSPARAMS_SELECTION_TEXT "Selection Text" - IDC_SYSPARAMS_TOOLTIP "ToolTip Background" - IDC_SYSPARAMS_TOOLTIP_TEXT "ToolTip Text" - IDC_SYSPARAMS_WINDOW "Window Background" - IDC_SYSPARAMS_WINDOW_TEXT "Window Text" - IDC_SYSPARAMS_ACTIVE_TITLE "Active Title Bar" - IDC_SYSPARAMS_ACTIVE_TITLE_TEXT "Active Title Text" - IDC_SYSPARAMS_INACTIVE_TITLE "Inactive Title Bar" - IDC_SYSPARAMS_INACTIVE_TITLE_TEXT "Inactive Title Text" - IDC_SYSPARAMS_MSGBOX_TEXT "Message Box Text" - IDC_SYSPARAMS_APPWORKSPACE "Application Workspace" - IDC_SYSPARAMS_WINDOW_FRAME "Window Frame" - IDC_SYSPARAMS_ACTIVE_BORDER "Active Border" - IDC_SYSPARAMS_INACTIVE_BORDER "Inactive Border" - IDC_SYSPARAMS_BUTTON_SHADOW "Controls Shadow" - IDC_SYSPARAMS_GRAY_TEXT "Grey Text" - IDC_SYSPARAMS_BUTTON_HILIGHT "Controls Highlight" - IDC_SYSPARAMS_BUTTON_DARK_SHADOW "Controls Dark Shadow" - IDC_SYSPARAMS_BUTTON_LIGHT "Controls Light" - IDC_SYSPARAMS_BUTTON_ALTERNATE "Controls Alternate Background" - IDC_SYSPARAMS_HOT_TRACKING "Hot Tracked Item" - IDC_SYSPARAMS_ACTIVE_TITLE_GRADIENT "Active Title Bar Gradient" - IDC_SYSPARAMS_INACTIVE_TITLE_GRADIENT "Inactive Title Bar Gradient" - IDC_SYSPARAMS_MENU_HILIGHT "Menu Highlight" - IDC_SYSPARAMS_MENUBAR "Menu Bar" -END diff --git a/programs/winecfg/Es.rc b/programs/winecfg/Es.rc index ececfe23d0b..1505a223699 100644 --- a/programs/winecfg/Es.rc +++ b/programs/winecfg/Es.rc @@ -20,9 +20,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL IDR_WINECFG MENU DISCARDABLE @@ -44,8 +41,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Información de Registro de Windows ", IDC_STATIC, 15, 110, 230, 55 LTEXT "Propietario:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "Organización:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END diff --git a/programs/winecfg/Fi.rc b/programs/winecfg/Fi.rc index ed24bf6bca9..e1b158362d1 100644 --- a/programs/winecfg/Fi.rc +++ b/programs/winecfg/Fi.rc @@ -21,9 +21,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT IDR_WINECFG MENU DISCARDABLE @@ -45,8 +42,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Windows Registration Information ", IDC_STATIC, 15, 110, 230, 55 LTEXT "Omistaja:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "Organisaatio:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END diff --git a/programs/winecfg/Fr.rc b/programs/winecfg/Fr.rc dissimilarity index 62% index be2c362bba2..e86644ce135 100644 --- a/programs/winecfg/Fr.rc +++ b/programs/winecfg/Fr.rc @@ -1,332 +1,325 @@ -/* - * WineCfg resources - * French Language Support - * - * Copyright 2005-2007 Jonathan Ernst - * Copyright 2009 Frédéric Delanoy - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - * - */ - -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL - -IDR_WINECFG MENU DISCARDABLE -BEGIN - POPUP "" - BEGIN - MENUITEM "Configurer", IDC_AUDIO_CONFIGURE - END -END - -IDD_ABOUTCFG DIALOGEX 0, 0, 260, 270 -STYLE WS_CHILD -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT PACKAGE_STRING,IDC_STATIC,119,17,120,8 - CONTROL IDB_WINE,IDC_STATIC,"Static",SS_BITMAP ,15,17,157,111 - LTEXT "http://www.winehq.org/",IDC_STATIC,119,31,106,8 - LTEXT "Ce programme est un logiciel libre ; vous pouvez le redistribuer et/ou le modifier suivant les termes de la Licence Générale Publique Limitée, telle que publiée par la Free Software Foundation ; soit la version 2.1 de la Licence, soit (à votre gré) toute version ultérieure." - IDC_STATIC,119,44,124,72 - GROUPBOX "Informations d'enregistrement de Windows ", IDC_STATIC, 15, 113, 230, 55 - LTEXT "&Propriétaire:", IDC_STATIC, 22, 129, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 129, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "&Organisation:", IDC_STATIC, 22, 143, 50, 20 - EDITTEXT IDC_ABT_ORG, 75, 143, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP -END - -IDD_APPCFG DIALOG DISCARDABLE 0, 0, 260, 250 -STYLE WS_CHILD | WS_DISABLED -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Paramètres des applications ",IDC_STATIC, 8,4,244,240 - LTEXT "Wine peut imiter différentes versions de Windows pour chaque application. Cet onglet est lié aux onglets Bibliothèques et Affichage pour vous permettre de changer des paramètres globaux ou par application dans ces onglets.", - IDC_STATIC,15,20,227,40 - CONTROL "Applications",IDC_APP_LISTVIEW,"SysListView32",WS_BORDER | WS_TABSTOP | LVS_LIST | LVS_SINGLESEL | LVS_SHOWSELALWAYS, - 15,60,230,140 - PUSHBUTTON "&Ajouter une application...",IDC_APP_ADDAPP, 16,204,90,14 - PUSHBUTTON "&Supprimer une application",IDC_APP_REMOVEAPP, 110,204,90,14 - LTEXT "Version de &Windows :",IDC_STATIC,17,225,70,8 - COMBOBOX IDC_WINVER,95,224,151,31,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP -END - -IDD_GRAPHCFG DIALOG DISCARDABLE 0, 0, 260, 260 -STYLE WS_CHILD | WS_DISABLED -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Paramètres des fenêtres ",IDC_STATIC,8,4,244,92 - CONTROL "Permettre aux applications DirectX d'&empêcher la souris de quitter leur fenêtre",IDC_DX_MOUSE_GRAB,"Button",BS_AUTOCHECKBOX | WS_TABSTOP | BS_MULTILINE,15,16,230,16 - CONTROL "Permettre au gestionnaire de fenêtres de &décorer les fenêtres",IDC_ENABLE_DECORATED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,36,230,8 - CONTROL "Permettre au gestionnaire de fenêtres de &contrôler les fenêtres",IDC_ENABLE_MANAGED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,50,230,8 - CONTROL "Émuler un bureau virtuel",IDC_ENABLE_DESKTOP,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,15,64,230,8 - LTEXT "Taille du bureau:",IDC_DESKTOP_SIZE,15,78,54,8,WS_DISABLED - LTEXT "X",IDC_DESKTOP_BY,119,78,8,8,WS_DISABLED - EDITTEXT IDC_DESKTOP_WIDTH,74,76,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED - EDITTEXT IDC_DESKTOP_HEIGHT,127,76,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED - - GROUPBOX " Direct3D ",IDC_STATIC,8,103,244,49 - LTEXT "Support du Vertex Shader: ",IDC_STATIC,15,118,90,32 - COMBOBOX IDC_D3D_VSHADER_MODE,110,116,135,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - CONTROL "Utiliser le Pixel Shader (si supporté par le matériel)",IDC_D3D_PSHADER_MODE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,134,230,10 - - GROUPBOX " Résolution de l'écran ",IDC_STATIC,8,159,244,93 - CONTROL "", IDC_RES_TRACKBAR, "msctls_trackbar32",WS_TABSTOP,12,169,187,15 - EDITTEXT IDC_RES_DPIEDIT,204,169,23,13,ES_NUMBER|WS_TABSTOP - LTEXT "dpi",IDC_STATIC,233,171,12,8 /* units shouldn't be translated */ - LTEXT "Ceci est un exemple utilisant du Tahoma 10 points",IDC_RES_FONT_PREVIEW,15,189,230,55 -END - -IDD_DLLCFG DIALOG DISCARDABLE 0, 0, 260, 250 -STYLE WS_CHILD | WS_DISABLED -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Remplacement de DLL ",IDC_STATIC,8,4,244,240 - LTEXT "Il est possible de spécifier si Wine doit utiliser une version native (importée depuis Windows ou installée par l'application) ou bien une version intégrée (distribuée avec Wine) de chaque bibliothèque partagée (DLL) utilisée par un programme." - , IDC_STATIC,16,16,220,32 - LTEXT "&Nouveau remplacement pour :",IDC_STATIC,16,58,100,8 - COMBOBOX IDC_DLLCOMBO,16,68,140,14,CBS_DROPDOWN | WS_VSCROLL | WS_TABSTOP | CBS_SORT | CBS_LOWERCASE - PUSHBUTTON "&Ajouter",IDC_DLLS_ADDDLL, 164,68,82,14,BS_DEFPUSHBUTTON - LTEXT "Remplacements existants :",IDC_STATIC,16,86,100,8 - LISTBOX IDC_DLLS_LIST,16,96,140,140,WS_BORDER | WS_TABSTOP | WS_VSCROLL - PUSHBUTTON "&Modifier",IDC_DLLS_EDITDLL,164,96,82,14 - PUSHBUTTON "&Supprimer",IDC_DLLS_REMOVEDLL,164,114,82,14 -END - -IDD_LOADORDER DIALOG DISCARDABLE 80, 90, 135, 92 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Éditer le remplacement" -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Ordre de chargement ",IDC_STATIC,8,4,120,66 - CONTROL "&intégrée (Wine)",IDC_RAD_BUILTIN,"Button", BS_AUTORADIOBUTTON | WS_GROUP,16,14,77,10 - CONTROL "&native (Windows)",IDC_RAD_NATIVE,"Button", BS_AUTORADIOBUTTON,16,24,77,10 - CONTROL "i&ntégrée puis native",IDC_RAD_BUILTIN_NATIVE,"Button", BS_AUTORADIOBUTTON,16,34,77,10 - CONTROL "n&ative puis intégrée",IDC_RAD_NATIVE_BUILTIN,"Button", BS_AUTORADIOBUTTON,16,44,77,10 - CONTROL "&désactivé",IDC_RAD_DISABLE,"Button", BS_AUTORADIOBUTTON,16,54,77,10 - DEFPUSHBUTTON "OK",IDOK,23,74,45,14,WS_GROUP - PUSHBUTTON "Annuler",IDCANCEL,72,74,45,14,WS_GROUP -END - -IDD_DRIVECFG DIALOG DISCARDABLE 0, 0, 260, 266 -STYLE WS_CHILD | WS_DISABLED -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Assignation des lecteurs ",IDC_STATIC,8,4,244,240 - LTEXT "N'a pu se connecter au gestionnaire de montage : la configuration du lecteur n'a pu être éditée.", IDC_STATIC_MOUNTMGR_ERROR, 15,30,220,76 - CONTROL "Listview",IDC_LIST_DRIVES,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | - LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,18,232,76 - PUSHBUTTON "&Ajouter...",IDC_BUTTON_ADD,15,98,40,14 - PUSHBUTTON "&Supprimer",IDC_BUTTON_REMOVE,58,98,40,14 - PUSHBUTTON "&Détection automatique...",IDC_BUTTON_AUTODETECT,152,98,95,14 - - /* editing drive details */ - LTEXT "&Chemin :",IDC_STATIC_PATH,15,122,30,9 - EDITTEXT IDC_EDIT_PATH,49,120,152,13,ES_AUTOHSCROLL | WS_TABSTOP - PUSHBUTTON "&Parcourir...",IDC_BUTTON_BROWSE_PATH,204,119,43,14 - - LTEXT "&Type :",IDC_STATIC_TYPE,15,137,21,10 - COMBOBOX IDC_COMBO_TYPE,49,135,77,16,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - - LTEXT "Étiquette et numéro de série",IDC_LABELSERIAL_STATIC,15,155,95,10 - - PUSHBUTTON "&Affichage avancé",IDC_BUTTON_SHOW_HIDE_ADVANCED,147,136,100,14 /* doesn't seem to be displayed, ever */ - CONTROL "Détection automatique depuis le &lecteur :",IDC_RADIO_AUTODETECT,"Button", - BS_AUTORADIOBUTTON,15,166,146,10 - EDITTEXT IDC_EDIT_DEVICE,27,176,173,14,ES_AUTOHSCROLL - PUSHBUTTON "&Parcourir...",IDC_BUTTON_BROWSE_DEVICE,204,176,43,14 - CONTROL "Assigner &manuellement :",IDC_RADIO_ASSIGN,"Button", - BS_AUTORADIOBUTTON,15,195,140,10 - - LTEXT "É&tiquette :",IDC_STATIC_LABEL,33,208,40,12 - EDITTEXT IDC_EDIT_LABEL,77,206,67,13,ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "N° de &série :",IDC_STATIC_SERIAL,33,225,40,12 - EDITTEXT IDC_EDIT_SERIAL,77,223,67,13,ES_AUTOHSCROLL | WS_TABSTOP - - CONTROL "Montrer les fichiers cachés",IDC_SHOW_DOT_FILES,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,8,251,230,8 -END - -IDD_AUDIOCFG DIALOG DISCARDABLE 0, 0, 260, 270 -STYLE WS_CHILD | WS_DISABLED -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Sélection du pilote ",IDC_STATIC,8,4,244,195 - LTEXT "Sélectionnez un pilote audio en cochant la case en regard du pilote désiré. Désactivez le son en ne sélectionnant aucun pilote. La sélection de pilotes multiples n'est pas recommandée. Configurez le pilote en effectuant un clic droit dessus.",IDC_STATIC,15,20,227,35 - CONTROL "Matériel",IDC_AUDIO_TREE,"SysTreeView32",WS_BORDER | WS_TABSTOP,15,55,140,139 - PUSHBUTTON "&Tester le son",IDC_AUDIO_TEST,159,56,89,14 - PUSHBUTTON "Panneau de &configuration",IDC_AUDIO_CONTROL_PANEL,159,76,89,14 - GROUPBOX " DirectSound ",IDC_STATIC,8,205,244,60 - LTEXT "Accélération matérielle : ",IDC_STATIC,15,215,80,10 - COMBOBOX IDC_DSOUND_HW_ACCEL,100,213,148,30,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Échantillonage (défaut) :",IDC_STATIC,15,232,80,8 - COMBOBOX IDC_DSOUND_RATES,100,230,38,30,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Bits par échantillon :",IDC_STATIC,153,232,80,8 - COMBOBOX IDC_DSOUND_BITS,223,230,25,30,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - CONTROL "Émulation pilote",IDC_DSOUND_DRV_EMUL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,250,230,10 -END - -IDD_DESKTOP_INTEGRATION DIALOG DISCARDABLE 0, 0, 260, 220 -STYLE WS_CHILD | WS_DISABLED -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Apparence ",IDC_STATIC,8,4,244,93 - LTEXT "&Thème :",IDC_STATIC,15,15,130,8 - COMBOBOX IDC_THEME_THEMECOMBO,15,24,112,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Installer un thème...",IDC_THEME_INSTALL,136,23,93,14 - LTEXT "&Couleur :",IDC_THEME_COLORTEXT,15,40,112,8 - COMBOBOX IDC_THEME_COLORCOMBO,15,49,112,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "T&aille :",IDC_THEME_SIZETEXT,135,40,110,8 - COMBOBOX IDC_THEME_SIZECOMBO,135,49,110,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Élé&ment :",IDC_STATIC,15,64,112,8 - COMBOBOX IDC_SYSPARAM_COMBO,15,74,112,105,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP | CBS_SORT - LTEXT "Couleu&r :",IDC_SYSPARAM_COLOR_TEXT,135,64,25,8,WS_DISABLED - PUSHBUTTON "",IDC_SYSPARAM_COLOR,135,74,25,13,WS_DISABLED | BS_OWNERDRAW - LTEXT "Tai&lle :",IDC_SYSPARAM_SIZE_TEXT,166,64,30,8,WS_DISABLED - EDITTEXT IDC_SYSPARAM_SIZE,166,74,23,13,ES_AUTOHSCROLL | WS_TABSTOP | WS_DISABLED - CONTROL "",IDC_SYSPARAM_SIZE_UD,UPDOWN_CLASS,UDS_SETBUDDYINT | WS_DISABLED,187,74,15,13 - PUSHBUTTON "&Police :",IDC_SYSPARAM_FONT,206,73,38,14,WS_DISABLED - GROUPBOX " Dossiers système ",IDC_STATIC,8,103,244,108 - CONTROL "Listview",IDC_LIST_SFPATHS,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | - LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,118,230,64 - CONTROL "&Lier à :",IDC_LINK_SFPATH,"Button",BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED,15,191,34,13 - EDITTEXT IDC_EDIT_SFPATH,53,191,137,13,ES_AUTOHSCROLL|WS_TABSTOP|WS_DISABLED - PUSHBUTTON "Parcou&rir...",IDC_BROWSE_SFPATH,197,191,49,14,WS_DISABLED -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_TAB_APPLICATIONS "Applications" - IDS_TAB_DLLS "Bibliothèques" - IDS_TAB_DRIVES "Lecteurs" - IDS_CHOOSE_PATH "Veuillez sélectionner le répertoire de destination Unix :" - IDS_HIDE_ADVANCED "Cacher paramètres avancés" - IDS_SHOW_ADVANCED "Montrer paramètres avancés" - IDS_NOTHEME "(Pas de thème)" - IDS_TAB_GRAPHICS "Affichage" - IDS_TAB_DESKTOP_INTEGRATION "Intégration avec le bureau" - IDS_TAB_AUDIO "Audio" - IDS_TAB_ABOUT "À propos" - IDS_WINECFG_TITLE "Configuration de Wine" - IDS_WINECFG_TITLE_APP "Configuration de Wine pour %s" - IDS_THEMEFILE "Fichiers de thèmes" - IDS_THEMEFILE_SELECT "Sélectionnez un fichier de thème" - IDS_AUDIO_MISSING "Aucun pilote audio n'est actuellement défini dans la base de registre.\n\nLe pilote recommandé a été sélectionné pour vous.\nVous pouvez utiliser ce pilote ou en sélectionner un autre si disponible.\n\nVous devez cliquer sur Appliquer pour que la sélection prenne effet." - IDS_SHELL_FOLDER "Dossier système" - IDS_LINKS_TO "Pointe vers" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_DLL_WARNING "Modifier l'ordre de chargement de cette bibliothèque n'est pas recommandé.\nÊtes-vous sûr de vouloir le faire ?" - IDS_DLL_WARNING_CAPTION "Attention : bibliothèque système" - IDS_DLL_NATIVE "native" - IDS_DLL_BUILTIN "intégrée" - IDS_DLL_NATIVE_BUILTIN "native, intégrée" - IDS_DLL_BUILTIN_NATIVE "intégrée, native" - IDS_DLL_DISABLED "désactivée" - IDS_DEFAULT_SETTINGS "Paramètres par défaut" - IDS_EXECUTABLE_FILTER "Programmes de Wine (*.exe,*.exe.so)\0*.exe;*.exe.so\0" - IDS_USE_GLOBAL_SETTINGS "Utiliser les paramètres globaux" - IDS_SELECT_EXECUTABLE "Sélectionnez un fichier exécutable" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_SHADER_MODE_HARDWARE "Matériel" - IDS_SHADER_MODE_NONE "Aucun" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_DRIVE_UNKNOWN "Détection automatique" - IDS_DRIVE_FIXED "Disque dur local" - IDS_DRIVE_REMOTE "Partage réseau" - IDS_DRIVE_REMOVABLE "Lecteur de disquette" - IDS_DRIVE_CDROM "CD-ROM" - IDS_DRIVE_LETTERS_EXCEEDED "Vous ne pouvez pas ajouter plus de lecteurs.\n\nUne lettre de A à Z doit être assignée à chaque lecteur ; vous ne pouvez donc pas en avoir plus de 26." - IDS_SYSTEM_DRIVE_LABEL "Lecteur système" - IDS_CONFIRM_DELETE_C "Êtes-vous sûr de vouloir supprimer le lecteur C ?\n\nLa plupart des applications Windows comptent sur l'existence de ce lecteur et ne fonctionneront pas s'il n'existe pas. Si vous continuez, n'oubliez pas de le recréer !" - IDS_COL_DRIVELETTER "Lettre" - IDS_COL_DRIVEMAPPING "Assignation de lecteur" - IDS_NO_DRIVE_C "Vous ne disposez pas de lecteur C, ce qui peut poser des problèmes.\n\nN'oubliez pas d'en recréer un en cliquant sur le bouton « Ajouter » dans l'onglet « Lecteurs » !\n" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_ACCEL_FULL "Complète" - IDS_ACCEL_STANDARD "Standard" - IDS_ACCEL_BASIC "Basique" - IDS_ACCEL_EMULATION "Émulation" - IDS_DRIVER_PULSE "Pilote PulseAudio" - IDS_DRIVER_ALSA "Pilote ALSA" - IDS_DRIVER_ESOUND "Pilote EsounD" - IDS_DRIVER_OSS "Pilote OSS" - IDS_DRIVER_JACK "Pilote JACK" - IDS_DRIVER_NAS "Pilote NAS" - IDS_DRIVER_AUDIOIO "Pilote Audio IO (Solaris)" - IDS_DRIVER_COREAUDIO "Pilote CoreAudio" - IDS_OPEN_DRIVER_ERROR "Impossible d'ouvrir %s !" - IDS_SOUNDDRIVERS "Pilotes audio" - IDS_DEVICES_WAVEOUT "Périphériques de sortie Wave" - IDS_DEVICES_WAVEIN "Périphériques d'entrée Wave" - IDS_DEVICES_MIDIOUT "Périphériques de sortie MIDI" - IDS_DEVICES_MIDIIN "Périphériques d'entrée MIDI" - IDS_DEVICES_AUX "Périphériques Aux" - IDS_DEVICES_MIXER "Périphériques de mixage" - IDS_UNAVAILABLE_DRIVER "Un pilote non disponible a été trouvé dans la base de registre !\n\nSouhaitez-vous supprimer « %s » de la base de registre ?" - IDS_WARNING "Attention" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDC_SYSPARAMS_BUTTON "Contrôle l'arrière-plan" - IDC_SYSPARAMS_BUTTON_TEXT "Contrôle le texte" - IDC_SYSPARAMS_DESKTOP "Bureau" - IDC_SYSPARAMS_MENU "Arrière-plan du menu" - IDC_SYSPARAMS_MENU_TEXT "Texte du menu" - IDC_SYSPARAMS_SCROLLBAR "Barre de défilement" - IDC_SYSPARAMS_SELECTION "Arrière-plan de la sélection" - IDC_SYSPARAMS_SELECTION_TEXT "Texte de la sélection" - IDC_SYSPARAMS_TOOLTIP "Arrière-plan de l'infobulle" - IDC_SYSPARAMS_TOOLTIP_TEXT "Texte de l'infobulle" - IDC_SYSPARAMS_WINDOW "Arrière-plan de la fenêtre" - IDC_SYSPARAMS_WINDOW_TEXT "Texte de la fenêtre" - IDC_SYSPARAMS_ACTIVE_TITLE "Barre de titre active" - IDC_SYSPARAMS_ACTIVE_TITLE_TEXT "Texte de la barre de titre active" - IDC_SYSPARAMS_INACTIVE_TITLE "Barre de titre inactive" - IDC_SYSPARAMS_INACTIVE_TITLE_TEXT "Texte de la barre de titre inactive" - IDC_SYSPARAMS_MSGBOX_TEXT "Texte de la boîte de messages" - IDC_SYSPARAMS_APPWORKSPACE "Espace de travail de l'application" - IDC_SYSPARAMS_WINDOW_FRAME "Cadre de la fenêtre" - IDC_SYSPARAMS_ACTIVE_BORDER "Bordure active" - IDC_SYSPARAMS_INACTIVE_BORDER "Bordure inactive" - IDC_SYSPARAMS_BUTTON_SHADOW "Ombre des contrôles" - IDC_SYSPARAMS_GRAY_TEXT "Texte gris" - IDC_SYSPARAMS_BUTTON_HILIGHT "Surbrillance des contrôles" - IDC_SYSPARAMS_BUTTON_DARK_SHADOW "Ombre sombre des contrôles" - IDC_SYSPARAMS_BUTTON_LIGHT "Lumière des contrôles" - IDC_SYSPARAMS_BUTTON_ALTERNATE "Arrière-plan alternatif des contrôles" - IDC_SYSPARAMS_HOT_TRACKING "Élément actif" - IDC_SYSPARAMS_ACTIVE_TITLE_GRADIENT "Dégradé de la barre de titre active" - IDC_SYSPARAMS_INACTIVE_TITLE_GRADIENT "Dégradé de la barre de titre inactive" - IDC_SYSPARAMS_MENU_HILIGHT "Surbrillance du menu" - IDC_SYSPARAMS_MENUBAR "Barre de menu" -END +/* + * WineCfg resources + * French Language Support + * + * Copyright 2005-2007 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + * + */ + +LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL + +IDR_WINECFG MENU DISCARDABLE +BEGIN + POPUP "" + BEGIN + MENUITEM "Configurer", IDC_AUDIO_CONFIGURE + END +END + +IDD_ABOUTCFG DIALOGEX 0, 0, 260, 270 +STYLE WS_CHILD +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT PACKAGE_STRING,IDC_STATIC,119,17,120,8 + CONTROL IDB_WINE,IDC_STATIC,"Static",SS_BITMAP ,15,17,157,111 + LTEXT "http://www.winehq.org/",IDC_STATIC,119,31,106,8 + LTEXT "Ce programme est un logiciel libre�; vous pouvez le redistribuer et/ou le modifier suivant les termes de la Licence G�n�rale Publique Limit�e, telle que publi�e par la Free Software Foundation�; soit la version 2.1 de la License, soit (� votre gr�) toute version ult�rieure." + IDC_STATIC,119,44,124,72 + GROUPBOX " Les renseignements pour l'inscription Windows ", IDC_STATIC, 15, 110, 230, 55 + LTEXT "Propri�taire:", IDC_STATIC, 22, 126, 40, 20 + LTEXT "Organisation:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP + EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP +END + +IDD_APPCFG DIALOG DISCARDABLE 0, 0, 260, 250 +STYLE WS_CHILD | WS_DISABLED +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " Param�tres des applications ",IDC_STATIC, 8,4,244,240 + LTEXT "Wine peut imiter diff�rentes versions de Windows pour chaque application. Cet onglet est li� aux onglets Biblioth�ques et Affichage pour vous permettre de changer des param�tres globaux ou par application dans ces onglets.", + IDC_STATIC,15,20,227,40 + CONTROL "Applications",IDC_APP_LISTVIEW,"SysListView32",WS_BORDER | WS_TABSTOP | LVS_LIST | LVS_SINGLESEL | LVS_SHOWSELALWAYS, + 15,60,230,140 + PUSHBUTTON "&Ajouter une application...",IDC_APP_ADDAPP, 70,204,85,14 + PUSHBUTTON "&Enlever une application",IDC_APP_REMOVEAPP, 160,204,85,14 + LTEXT "Version de &Windows :",IDC_STATIC,17,224,70,8 + COMBOBOX IDC_WINVER,95,222,151,56,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP +END + +IDD_GRAPHCFG DIALOG DISCARDABLE 0, 0, 260, 250 +STYLE WS_CHILD | WS_DISABLED +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " Param�tres des fen�tres ",IDC_STATIC,8,4,244,92 + CONTROL "Permettre aux applications DirectX d'emp�cher la souris de quitter leur fen�tre",IDC_DX_MOUSE_GRAB,"Button",BS_AUTOCHECKBOX | WS_TABSTOP | BS_MULTILINE,15,20,230,16 + CONTROL "Permettre au gestionnaire de &fen�tres de &d�corer les fen�tres",IDC_ENABLE_DECORATED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,40,230,8 + CONTROL "Permettre au gestionnaire de &fen�tres de contr�ler les fen�tres",IDC_ENABLE_MANAGED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,52,230,8 + CONTROL "�muler un bureau virtuel",IDC_ENABLE_DESKTOP,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,15,64,230,8 + LTEXT "Taille du bureau:",IDC_DESKTOP_SIZE,15,78,54,8,WS_DISABLED + LTEXT "X",IDC_DESKTOP_BY,119,78,8,8,WS_DISABLED + EDITTEXT IDC_DESKTOP_WIDTH,74,76,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED + EDITTEXT IDC_DESKTOP_HEIGHT,127,76,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED + + GROUPBOX " Direct3D ",IDC_STATIC,8,103,244,49 + LTEXT "Support du Vertex Shader: ",IDC_STATIC,15,118,90,32 + COMBOBOX IDC_D3D_VSHADER_MODE,110,116,135,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + CONTROL "Permettre le Pixel Shader (si support� par le mat�riel)",IDC_D3D_PSHADER_MODE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,134,230,10 + + GROUPBOX " R�solution de l'�cran ",IDC_STATIC,8,159,244,93 + CONTROL "", IDC_RES_TRACKBAR, "msctls_trackbar32",WS_TABSTOP,12,169,187,15 + EDITTEXT IDC_RES_DPIEDIT,204,169,23,13,ES_NUMBER|WS_TABSTOP + LTEXT "ppp",IDC_STATIC,233,171,12,8 + LTEXT "This is a sample text using 10 point Tahoma",IDC_RES_FONT_PREVIEW,15,189,230,55 +END + +IDD_DLLCFG DIALOG DISCARDABLE 0, 0, 260, 250 +STYLE WS_CHILD | WS_DISABLED +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " Surclassage de DLLs ",IDC_STATIC,8,4,244,240 + LTEXT "Il est possible de sp�cifier si Wine doit utiliser une version native (import�e depuis Windows ou install�e par l'application) ou bien une version inclue (distribu�e avec Wine) de chaque DLL (Dynamic Link Libraries) utilis�e par un programme." + , IDC_STATIC,16,16,220,32 + LTEXT "&Nouveau surclassage pour :",IDC_STATIC,16,58,100,8 + COMBOBOX IDC_DLLCOMBO,16,68,140,14,CBS_DROPDOWN | WS_VSCROLL | WS_TABSTOP | CBS_SORT | CBS_LOWERCASE + PUSHBUTTON "&Ajouter",IDC_DLLS_ADDDLL, 164,68,82,13,BS_DEFPUSHBUTTON + LTEXT "Surclassages existants :",IDC_STATIC,16,86,100,8 + LISTBOX IDC_DLLS_LIST,16,96,140,140,WS_BORDER | WS_TABSTOP | WS_VSCROLL + PUSHBUTTON "&Modifier",IDC_DLLS_EDITDLL,164,96,82,14 + PUSHBUTTON "&Supprimer",IDC_DLLS_REMOVEDLL,164,114,82,14 +END + +IDD_LOADORDER DIALOG DISCARDABLE 80, 90, 110, 92 +STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +CAPTION "Edit Override" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " Ordre de chargement ",IDC_STATIC,8,4,94,66 + CONTROL "&Inclue (Wine)",IDC_RAD_BUILTIN,"Button", BS_AUTORADIOBUTTON | WS_GROUP,16,14,75,10 + CONTROL "&Native (Windows)",IDC_RAD_NATIVE,"Button", BS_AUTORADIOBUTTON,16,24,75,10 + CONTROL "&Inclue puis native",IDC_RAD_BUILTIN_NATIVE,"Button", BS_AUTORADIOBUTTON,16,34,75,10 + CONTROL "Nati&ve puis inclue",IDC_RAD_NATIVE_BUILTIN,"Button", BS_AUTORADIOBUTTON,16,44,75,10 + CONTROL "&D�sactiv�",IDC_RAD_DISABLE,"Button", BS_AUTORADIOBUTTON,16,54,75,10 + DEFPUSHBUTTON "OK",IDOK,8,74,45,14,WS_GROUP + PUSHBUTTON "Annuler",IDCANCEL,57,74,45,14,WS_GROUP +END + +IDD_DRIVECFG DIALOG DISCARDABLE 0, 0, 260, 250 +STYLE WS_CHILD | WS_DISABLED +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " Assignation des lecteurs ",IDC_STATIC,8,4,244,240 + LTEXT "Failed to connect to the mount manager, the drive configuration cannot be edited.", IDC_STATIC_MOUNTMGR_ERROR, 15,30,220,76 + CONTROL "Listview",IDC_LIST_DRIVES,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | + LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,18,232,76 + PUSHBUTTON "&Ajouter...",IDC_BUTTON_ADD,15,98,37,14 + PUSHBUTTON "&Supprimer",IDC_BUTTON_REMOVE,56,98,37,14 + PUSHBUTTON "Auto&d�tection...",IDC_BUTTON_AUTODETECT,191,98,55,14 + + /* editing drive details */ + LTEXT "&Chemin :",IDC_STATIC_PATH,15,123,30,9 + EDITTEXT IDC_EDIT_PATH,49,120,152,13,ES_AUTOHSCROLL | WS_TABSTOP + PUSHBUTTON "&Parcourir...",IDC_BUTTON_BROWSE_PATH,206,120,40,13 + + LTEXT "&Type :",IDC_STATIC_TYPE,15,138,21,10 + COMBOBOX IDC_COMBO_TYPE,43,135,77,60,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + + LTEXT "�tiquette et num�ro de s�rie",IDC_LABELSERIAL_STATIC,15,155,95,10 + + PUSHBUTTON "&Affichage avanc�",IDC_BUTTON_SHOW_HIDE_ADVANCED,186,136,60,13 + CONTROL "Autod�tection depuis le &lecteur :",IDC_RADIO_AUTODETECT,"Button", + BS_AUTORADIOBUTTON,15,166,140,10 + EDITTEXT IDC_EDIT_DEVICE,27,176,174,13,ES_AUTOHSCROLL + PUSHBUTTON "&Parcourir...",IDC_BUTTON_BROWSE_DEVICE,206,176,40,13 + CONTROL "Assigner &manuellement :",IDC_RADIO_ASSIGN,"Button", + BS_AUTORADIOBUTTON,15,195,140,10 + + LTEXT "�&tiquette :",IDC_STATIC_LABEL,33,208,40,12 + EDITTEXT IDC_EDIT_LABEL,74,205,67,13,ES_AUTOHSCROLL | WS_TABSTOP + LTEXT "N� de s�rie :",IDC_STATIC_SERIAL,33,225,40,12 + EDITTEXT IDC_EDIT_SERIAL,74,221,67,13,ES_AUTOHSCROLL | WS_TABSTOP + + CONTROL "Montrer les fichiers cach�s",IDC_SHOW_DOT_FILES,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,8,260,230,8 +END + +IDD_AUDIOCFG DIALOG DISCARDABLE 0, 0, 260, 250 +STYLE WS_CHILD | WS_DISABLED +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " S�lection du pilote ",IDC_STATIC,8,4,244,195 + LTEXT "S�lectionnez un pilote audio en cochant la case en regard du pilote d�sir�. D�sactivez le son en ne s�lectionnant aucun pilote. La s�lection de pilotes multiples n'est pas recommand�e. Configurez le pilote en effectuant un click droit dessus.",IDC_STATIC,15,20,227,60 + CONTROL "Mat�riel",IDC_AUDIO_TREE,"SysTreeView32",WS_BORDER | WS_TABSTOP,15,60,140,130 + PUSHBUTTON "&Tester le son",IDC_AUDIO_TEST,160,60,86,14 + PUSHBUTTON "Panneau de configuration",IDC_AUDIO_CONTROL_PANEL,160,80,86,14 + GROUPBOX " DirectSound ",IDC_STATIC,8,205,244,60 + LTEXT "Acc�l�ration mat�rielle : ",IDC_STATIC,15,215,90,10 + COMBOBOX IDC_DSOUND_HW_ACCEL,100,213,50,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + LTEXT "�chantillonage (d�faut) :",IDC_STATIC,15,232,130,8 + COMBOBOX IDC_DSOUND_RATES,100,230,38,76,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + LTEXT "Bits par �chantillon :",IDC_STATIC,153,232,80,8 + COMBOBOX IDC_DSOUND_BITS,223,230,25,56,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + CONTROL "�mulation pilote",IDC_DSOUND_DRV_EMUL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,250,230,10 +END + +IDD_DESKTOP_INTEGRATION DIALOG DISCARDABLE 0, 0, 260, 250 +STYLE WS_CHILD | WS_DISABLED +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " Apparence ",IDC_STATIC,8,4,244,106 + LTEXT "Th�me :",IDC_STATIC,15,16,130,8 + COMBOBOX IDC_THEME_THEMECOMBO,15,24,130,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + PUSHBUTTON "Installer un th�me...",IDC_THEME_INSTALL,152,23,93,14 + LTEXT "Couleur :",IDC_THEME_COLORTEXT,15,40,112,8 + COMBOBOX IDC_THEME_COLORCOMBO,15,48,112,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + LTEXT "Taille :",IDC_THEME_SIZETEXT,135,40,110,8 + COMBOBOX IDC_THEME_SIZECOMBO,135,48,110,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + LTEXT "El�ment :",IDC_STATIC,15,64,112,8 + COMBOBOX IDC_SYSPARAM_COMBO,15,74,112,120,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP | CBS_SORT + LTEXT "Couleur :",IDC_SYSPARAM_COLOR_TEXT,135,64,25,8,WS_DISABLED + PUSHBUTTON "",IDC_SYSPARAM_COLOR,135,74,25,13,WS_DISABLED | BS_OWNERDRAW + LTEXT "Taille :",IDC_SYSPARAM_SIZE_TEXT,166,64,30,8,WS_DISABLED + EDITTEXT IDC_SYSPARAM_SIZE,166,74,23,13,ES_AUTOHSCROLL | WS_TABSTOP | WS_DISABLED + CONTROL "",IDC_SYSPARAM_SIZE_UD,UPDOWN_CLASS,UDS_SETBUDDYINT | WS_DISABLED,187,74,15,13 + PUSHBUTTON "Police :",IDC_SYSPARAM_FONT,208,74,37,13,WS_DISABLED + GROUPBOX " Dossiers syst�me ",IDC_STATIC,8,114,244,100 + CONTROL "Listview",IDC_LIST_SFPATHS,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | + LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,126,230,64 + CONTROL "Li� � :",IDC_LINK_SFPATH,"Button",BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED,15,195,50,13 + EDITTEXT IDC_EDIT_SFPATH,65,195,145,13,ES_AUTOHSCROLL|WS_TABSTOP|WS_DISABLED + PUSHBUTTON "Parcourir",IDC_BROWSE_SFPATH,215,195,30,13,WS_DISABLED +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_TAB_APPLICATIONS "Applications" + IDS_TAB_DLLS "Biblioth�ques" + IDS_TAB_DRIVES "Lecteurs" + IDS_CHOOSE_PATH "Veuillez s�lectionner le r�pertoire de destination." + IDS_HIDE_ADVANCED "Cacher avanc�s" + IDS_SHOW_ADVANCED "Montrer avanc�s" + IDS_NOTHEME "(Pas de th�me)" + IDS_TAB_GRAPHICS "Affichage" + IDS_TAB_DESKTOP_INTEGRATION "Int�gration avec le bureau" + IDS_TAB_AUDIO "Audio" + IDS_TAB_ABOUT "� propos" + IDS_WINECFG_TITLE "Configuration de Wine" + IDS_WINECFG_TITLE_APP "Configuration de Wine pour %s" + IDS_THEMEFILE "Fichiers de th�mes" + IDS_THEMEFILE_SELECT "S�lectionnez un fichier de th�me" + IDS_AUDIO_MISSING "Aucun pilote audio n'est actuellement d�fini.\n\nLe pilote recommand� a �t� s�lectionn� pour vous.\nVous pouvez utiliser ce pilote ou en s�lectionner un autre si disponible.\n\nVous devez cliquer sur Appliquer pour que la s�lection prenne effet." + IDS_SHELL_FOLDER "Dossier syst�me" + IDS_LINKS_TO "Li� �" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_DLL_WARNING "La modification de l'ordre de chargement de cette biblioth�que n'est pas recommand�.\n�tes-vous s�r de vouloir le faire ?" + IDS_DLL_WARNING_CAPTION "Attention : biblioth�que syst�me" + IDS_DLL_NATIVE "native" + IDS_DLL_BUILTIN "inclue" + IDS_DLL_NATIVE_BUILTIN "native, inclue" + IDS_DLL_BUILTIN_NATIVE "inclue, native" + IDS_DLL_DISABLED "d�sactiv�e" + IDS_DEFAULT_SETTINGS "Param�tres par d�faut" + IDS_EXECUTABLE_FILTER "Programmes de Wine (*.exe,*.exe.so)\0*.exe;*.exe.so\0" + IDS_USE_GLOBAL_SETTINGS "Utiliser les param�tres globaux" + IDS_SELECT_EXECUTABLE "S�lectionnez un fichier ex�cutable" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_SHADER_MODE_HARDWARE "Mat�riel" + IDS_SHADER_MODE_NONE "Aucun" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_DRIVE_UNKNOWN "D�tection auto." + IDS_DRIVE_FIXED "Disque dur local" + IDS_DRIVE_REMOTE "Partage r�seau" + IDS_DRIVE_REMOVABLE "Lecteur de disquette" + IDS_DRIVE_CDROM "CD-ROM" + IDS_DRIVE_LETTERS_EXCEEDED "Vous ne pouvez pas ajouter plus de lecteurs.\n\nUne lettre de A � Z doit �tre assign�e � chaque lecteur ; vous ne pouvez donc pas en avoir plus de 26." + IDS_SYSTEM_DRIVE_LABEL "Lecteur syst�me" + IDS_CONFIRM_DELETE_C "�tes-vous s�r de vouloir supprimer le lecteur C�?\n\nLa plupart des applications Windows comptent sur l'existence de ce lecteur et ne fonctionneront pas s'il n'existe pas. Si vous continuez, n'oubliez pas de le recr�er�!" + IDS_COL_DRIVELETTER "Lettre" + IDS_COL_DRIVEMAPPING "Assignation" + IDS_NO_DRIVE_C "Vous ne disposez pas de lecteur C ce qui peut poser des probl�mes.\n\nN'oubliez pas d'en recr�er un en cliquant sur le bouton ��Ajouter�� dans l'onglet ��Lecteurs���!\n" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_ACCEL_FULL "Compl�te" + IDS_ACCEL_STANDARD "Standard" + IDS_ACCEL_BASIC "Basique" + IDS_ACCEL_EMULATION "�mulation" + IDS_DRIVER_PULSE "Pilote PulseAudio" + IDS_DRIVER_ALSA "Pilote ALSA" + IDS_DRIVER_ESOUND "Pilote EsounD" + IDS_DRIVER_OSS "Pilote OSS" + IDS_DRIVER_JACK "Pilote JACK" + IDS_DRIVER_NAS "Pilote NAS" + IDS_DRIVER_AUDIOIO "Pilote Audio IO (Solaris)" + IDS_DRIVER_COREAUDIO "Pilote CoreAudio" + IDS_OPEN_DRIVER_ERROR "Impossible d'ouvrir %s�!" + IDS_SOUNDDRIVERS "Pilotes audio" + IDS_DEVICES_WAVEOUT "P�riph�riques de sortie Wave" + IDS_DEVICES_WAVEIN "P�riph�riques d'entr�e Wave" + IDS_DEVICES_MIDIOUT "P�riph�riques de sortie MIDI" + IDS_DEVICES_MIDIIN "P�riph�riques d'entr�e MIDI" + IDS_DEVICES_AUX "P�riph�riques Aux" + IDS_DEVICES_MIXER "P�riph�riques de mixage" + IDS_UNAVAILABLE_DRIVER "Un pilote non disponible a �t� trouv� dans la base de registre�!\n\nSouhaitez-vous supprimer ��%s�� de la base de registre�?" + IDS_WARNING "Attention" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDC_SYSPARAMS_BUTTON "Contr�le le fond" + IDC_SYSPARAMS_BUTTON_TEXT "Contr�le le texte" + IDC_SYSPARAMS_DESKTOP "Bureau" + IDC_SYSPARAMS_MENU "Fond du menu" + IDC_SYSPARAMS_MENU_TEXT "Texte du menu" + IDC_SYSPARAMS_SCROLLBAR "Barre de d�filement" + IDC_SYSPARAMS_SELECTION "Fond de la s�lection" + IDC_SYSPARAMS_SELECTION_TEXT "Texte de la s�lection" + IDC_SYSPARAMS_TOOLTIP "Fond de l'infobulle" + IDC_SYSPARAMS_TOOLTIP_TEXT "Texte de l'infobulle" + IDC_SYSPARAMS_WINDOW "Fond de la fen�tre" + IDC_SYSPARAMS_WINDOW_TEXT "Texte de la fen�tre" + IDC_SYSPARAMS_ACTIVE_TITLE "Barre de titre active" + IDC_SYSPARAMS_ACTIVE_TITLE_TEXT "Texte de la barre de titre active" + IDC_SYSPARAMS_INACTIVE_TITLE "Barre de titre inactive" + IDC_SYSPARAMS_INACTIVE_TITLE_TEXT "Texte de la barre de titre inactive" + IDC_SYSPARAMS_MSGBOX_TEXT "Texte des bo�tes de messages" + IDC_SYSPARAMS_APPWORKSPACE "Espace de travail de l'application" + IDC_SYSPARAMS_WINDOW_FRAME "Cadre de la fen�tre" + IDC_SYSPARAMS_ACTIVE_BORDER "Bordure active" + IDC_SYSPARAMS_INACTIVE_BORDER "Bordure inactive" + IDC_SYSPARAMS_BUTTON_SHADOW "Ombre des contr�les" + IDC_SYSPARAMS_GRAY_TEXT "Texte gris" + IDC_SYSPARAMS_BUTTON_HILIGHT "Surbrillance des contr�les" + IDC_SYSPARAMS_BUTTON_DARK_SHADOW "Ombre sombre des contr�les" + IDC_SYSPARAMS_BUTTON_LIGHT "Lumi�re des contr�les" + IDC_SYSPARAMS_BUTTON_ALTERNATE "Fond alternatif des contr�les" + IDC_SYSPARAMS_HOT_TRACKING "�l�ment actif" + IDC_SYSPARAMS_ACTIVE_TITLE_GRADIENT "D�grad� de la barre de titre active" + IDC_SYSPARAMS_INACTIVE_TITLE_GRADIENT "D�grad� de la barre de titre inactive" + IDC_SYSPARAMS_MENU_HILIGHT "Surbrillance du menu" + IDC_SYSPARAMS_MENUBAR "Barre de menu" +END diff --git a/programs/winecfg/Hu.rc b/programs/winecfg/Hu.rc index 7756d2b57b2..4131f5fc392 100644 --- a/programs/winecfg/Hu.rc +++ b/programs/winecfg/Hu.rc @@ -20,9 +20,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT IDR_WINECFG MENU DISCARDABLE @@ -44,8 +41,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Windows Registration Information ", IDC_STATIC, 15, 110, 230, 55 LTEXT "Owner:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "Organization:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END diff --git a/programs/winecfg/It.rc b/programs/winecfg/It.rc index aea66df1a0b..8681de5030b 100644 --- a/programs/winecfg/It.rc +++ b/programs/winecfg/It.rc @@ -20,9 +20,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL IDD_ABOUTCFG DIALOGEX 0, 0, 260, 270 @@ -35,9 +32,9 @@ BEGIN LTEXT "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.", IDC_STATIC,119,44,124,72 GROUPBOX " Windows informazioni di registrazione ", IDC_STATIC, 15, 110, 230, 55 - LTEXT "&Proprietario:", IDC_STATIC, 22, 126, 40, 20 + LTEXT "Proprietario:", IDC_STATIC, 22, 126, 40, 20 + LTEXT "Organizzazione:", IDC_STATIC, 22, 140, 50, 20 EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "&Organizzazione:", IDC_STATIC, 22, 140, 50, 20 EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END diff --git a/programs/winecfg/Ja.rc b/programs/winecfg/Ja.rc index d690f7f094f..fce5cda639b 100644 --- a/programs/winecfg/Ja.rc +++ b/programs/winecfg/Ja.rc @@ -22,9 +22,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -49,8 +46,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Windows 登録情報 ", IDC_STATIC, 15, 110, 230, 55 LTEXT "所有者:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "組織:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END @@ -331,3 +328,5 @@ BEGIN IDC_SYSPARAMS_MENU_HILIGHT "Menu Highlight" IDC_SYSPARAMS_MENUBAR "メニュー バー" END + +#pragma code_page(default) diff --git a/programs/winecfg/Ko.rc b/programs/winecfg/Ko.rc index 5c500d507d7..a79cc03df58 100644 --- a/programs/winecfg/Ko.rc +++ b/programs/winecfg/Ko.rc @@ -23,9 +23,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT IDR_WINECFG MENU DISCARDABLE @@ -46,9 +43,9 @@ BEGIN LTEXT "ÀÌ ¶óÀ̺귯¸®´Â ÀÚÀ¯ ¼ÒÇÁÆ®¿þ¾îÀÔ´Ï´Ù. ´ç½ÅÀº ÀÚÀ¯ ¼ÒÇÁÆ®¿þ¾î Àç´Ü(Free Software Foundation)¿¡¼­ ¸¸µç GNU LGPL(Lesser General Public License) ¾Æ·¡¿¡¼­ ÀÌ ÇÁ·Î±×·¥À» Àç¹èÆ÷ ¶Ç´Â ¼öÁ¤ÇÒ ¼ö ÀÖ½À´Ï´Ù. ¶óÀ̼¾½ºÀÇ ¹öÀüÀº 2.1 ¶Ç´Â (¼±ÅÃÀûÀ¸·Î) ±× ÀÌÈÄ ¹öÀüÀ» µû¸£¸é µË´Ï´Ù.", IDC_STATIC,119,44,131,66 GROUPBOX " À©µµ¿ìÁî µî·Ï Á¤º¸ ", IDC_STATIC, 15, 110, 230, 55 - LTEXT "¼ÒÀ¯ÀÚ(&O):", IDC_STATIC, 22, 126, 40, 20 + LTEXT "¼ÒÀ¯ÀÚ:", IDC_STATIC, 22, 126, 40, 20 + LTEXT "´Üü:", IDC_STATIC, 22, 140, 50, 20 EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "´Üü(&Z):", IDC_STATIC, 22, 140, 50, 20 EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END @@ -59,7 +56,7 @@ FONT 9, "MS Shell Dlg" BEGIN GROUPBOX " ÇÁ·Î±×·¥ ¼³Á¤ ",IDC_STATIC, 8,4,244,240 LTEXT "WineÀº °¢°¢ÀÇ ÇÁ·Î±×·¥¿¡ ´ëÇؼ­ ´Ù¸¥ ¹öÀüÀÇ À©µµ¿ìÁ Èä³»³¾ ¼ö ÀÖ½À´Ï´Ù. ÀÌ ÅÇÀº ¶óÀ̺귯¸® ÅÇ, ±×·¡ÇÈ ÅÇ°ú ¿¬°áµÇ¾î À־, À̵é ÅÇÀ» ÀÌ¿ëÇÏ¿© ½Ã½ºÅÛ Àüü ¶Ç´Â ÇÁ·Î±×·¥º°·Î ¼³Á¤ÀÌ °¡´ÉÇÕ´Ï´Ù.", - IDC_STATIC,17,14,227,33 + IDC_STATIC,15,20,227,30 CONTROL "ÇÁ·Î±×·¥",IDC_APP_LISTVIEW,"SysListView32",WS_BORDER | WS_TABSTOP | LVS_LIST | LVS_SINGLESEL | LVS_SHOWSELALWAYS, 15,50,230,150 PUSHBUTTON "ÇÁ·Î±×·¥ Ãß°¡(&A)...",IDC_APP_ADDAPP, 90,204,75,14 @@ -92,7 +89,7 @@ BEGIN CONTROL "", IDC_RES_TRACKBAR, "msctls_trackbar32",WS_TABSTOP,12,161,187,15 EDITTEXT IDC_RES_DPIEDIT,204,161,23,13,ES_NUMBER|WS_TABSTOP LTEXT "dpi",IDC_STATIC,235,163,10,8 - LTEXT "This is a sample text using 10 point Tahoma",IDC_RES_FONT_PREVIEW,15,181,230,55 + LTEXT "This is a sample text using 10 point Tahoma( Ÿȣ¸¶ 10Æ÷ÀÎÆ® ±Û²ÃÀ» »ç¿ëÇÑ »ùÇà ÅؽºÆ®ÀÔ´Ï´Ù",IDC_RES_FONT_PREVIEW,15,181,230,55 END IDD_DLLCFG DIALOG DISCARDABLE 0, 0, 260, 250 @@ -208,7 +205,7 @@ BEGIN LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,126,230,64 CONTROL "¿¬°á À§Ä¡(&L):",IDC_LINK_SFPATH,"Button",BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED,15,195,55,13 EDITTEXT IDC_EDIT_SFPATH,75,195,135,13,ES_AUTOHSCROLL|WS_TABSTOP|WS_DISABLED - PUSHBUTTON "ã±â(&R)...",IDC_BROWSE_SFPATH,215,195,34,13,WS_DISABLED + PUSHBUTTON "ã±â(&R)...",IDC_BROWSE_SFPATH,215,195,30,13,WS_DISABLED END STRINGTABLE DISCARDABLE @@ -228,7 +225,7 @@ BEGIN IDS_WINECFG_TITLE_APP "%s¸¦ À§ÇÑ Wine ¼³Á¤" IDS_THEMEFILE "Å׸¶ ÆÄÀÏ" IDS_THEMEFILE_SELECT "Å׸¶ ÆÄÀÏ ¼±ÅÃ" - IDS_AUDIO_MISSING "ÇöÀç ·¹Áö½ºÆ®¸®¿¡ ¿Àµð¿À µå¶óÀ̹ö°¡ ÁöÁ¤µÇ¾î ÀÖÁö ¾Ê½À´Ï´Ù.\n\nÃßõ µå¶óÀ̹ö°¡ ¼±ÅõǾú½À´Ï´Ù.\nÀÌ µå¶óÀ̹ö¸¦ »ç¿ëÇϰųª °¡´ÉÇÑ ´Ù¸¥ µå¶óÀ̹ö¸¦ ¼±ÅÃÇÒ ¼ö ÀÖ½À´Ï´Ù.\n\n¼±Åà »çÇ×ÀÌ È¿°ú¸¦ ³ªÅ¸³»±â À§Çؼ­´Â Àû¿ë ¹öÆ°À» ´­·¯¾ß ÇÕ´Ï´Ù." + IDS_AUDIO_MISSING "ÇöÀç ·¹Áö½ºÆ®¸®¿¡ ¿Àµð¿À µå¶óÀ̹ö°¡ ÁöÁ¤µÇ¾î ÀÖÁö ¾Ê½À´Ï´Ù.\n\nÃßõ µå¶óÀ̹ö°¡ ¼±Åþú½À´Ï´Ù.\nÀÌ µå¶óÀ̹ö¸¦ »ç¿ëÇϰųª °¡´ÉÇÑ ´Ù¸¥ µå¶óÀ̹ö¸¦ ¼±ÅÃÇÒ ¼ö ÀÖ½À´Ï´Ù.\n\n¼±Åà »çÇ×ÀÌ È¿°ú¸¦ ³ªÅ¸³»±â À§Çؼ­´Â Àû¿ë ¹öÆ°À» ´­·¯¾ß ÇÕ´Ï´Ù." IDS_SHELL_FOLDER "Æú´õ" IDS_LINKS_TO "¿¬°á À§Ä¡" END diff --git a/programs/winecfg/Lt.rc b/programs/winecfg/Lt.rc index 3dd30416941..c14ca576916 100644 --- a/programs/winecfg/Lt.rc +++ b/programs/winecfg/Lt.rc @@ -20,9 +20,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -47,8 +44,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Windows registracijos informacija ", IDC_STATIC, 15, 120, 230, 55 LTEXT "Savininkas:", IDC_STATIC, 22, 136, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 136, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "Organizacija:", IDC_STATIC, 22, 150, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 136, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 150, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END @@ -112,7 +109,7 @@ END IDD_LOADORDER DIALOG DISCARDABLE 80, 90, 110, 92 STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Redaguoti nustelbimą" +CAPTION "Edit Override" FONT 8, "MS Shell Dlg" BEGIN GROUPBOX " Įkėlimo tvarka ",IDC_STATIC,8,4,94,66 @@ -145,7 +142,7 @@ BEGIN LTEXT "&Tipas:",IDC_STATIC_TYPE,15,138,21,10 COMBOBOX IDC_COMBO_TYPE,41,135,77,60,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Vardas ir serijos numeris",IDC_LABELSERIAL_STATIC,15,155,80,10 + LTEXT "Žymė ir numeris",IDC_LABELSERIAL_STATIC,15,155,95,10 PUSHBUTTON "Rodyti papil&domas",IDC_BUTTON_SHOW_HIDE_ADVANCED,180,136,66,13 CONTROL "Automatiškai aptikti iš įrenginio:",IDC_RADIO_AUTODETECT,"Button", @@ -155,7 +152,7 @@ BEGIN CONTROL "P&riskirti rankiniu būdu:",IDC_RADIO_ASSIGN,"Button", BS_AUTORADIOBUTTON,15,195,85,10 - LTEXT "&Vardas:",IDC_STATIC_LABEL,33,208,29,12 + LTEXT "&Žymė:",IDC_STATIC_LABEL,33,208,29,12 EDITTEXT IDC_EDIT_LABEL,63,205,78,13,ES_AUTOHSCROLL | WS_TABSTOP LTEXT "N&umeris:",IDC_STATIC_SERIAL,33,225,29,12 EDITTEXT IDC_EDIT_SERIAL,63,221,78,13,ES_AUTOHSCROLL | WS_TABSTOP @@ -218,7 +215,7 @@ BEGIN IDS_CHOOSE_PATH "Prašome išsirinkti unix paskirties aplanką." IDS_HIDE_ADVANCED "Slėpti papil&domas" IDS_SHOW_ADVANCED "Rodyti papil&domas" - IDS_NOTHEME "(nėra apipavidalinimo)" + IDS_NOTHEME "(Nėra apipavidalinimo)" IDS_TAB_GRAPHICS "Grafika" IDS_TAB_DESKTOP_INTEGRATION "Darbalaukio integravimas" IDS_TAB_AUDIO "Garsas" @@ -227,7 +224,7 @@ BEGIN IDS_WINECFG_TITLE_APP "Wine konfigūravimas: %s" IDS_THEMEFILE "Apipavidalinimo failai" IDS_THEMEFILE_SELECT "Pasirinkite apipavidalinimo failą" - IDS_AUDIO_MISSING "Registre nėra nurodyta garso tvarkyklė.\n\nRekomenduojama tvarkyklė buvo parinkta.\nGalite naudoti šią tvarkyklę ar pasirinkti kitą, jei tokių yra.\n\nTurite paspausti „Vykdyti“, kad pasirinkimas įsigaliotų." + IDS_AUDIO_MISSING "Registre nėra nurodyta garso tvarkyklė.\n\nRekomenduojama tvarkyklė buvo parinkta.\nGalite naudoti šią tvarkyklę ar pasirinkti kitą, jei tokių yra.\n\nTurite paspausti 'Vykdyti', kad pasirinkimas įsigaliotų." IDS_SHELL_FOLDER "Aplankas" IDS_LINKS_TO "Susietas su" END @@ -244,7 +241,7 @@ BEGIN IDS_DEFAULT_SETTINGS "Numatytosios nuostatos" IDS_EXECUTABLE_FILTER "Wine programos (*.exe,*.exe.so)\0*.exe;*.exe.so\0" IDS_USE_GLOBAL_SETTINGS "Naudoti globalias nuostatas" - IDS_SELECT_EXECUTABLE "Pasirinkite vykdomąjį failą" + IDS_SELECT_EXECUTABLE "Pasirikite vykdomąjį failą" END STRINGTABLE DISCARDABLE @@ -262,10 +259,10 @@ BEGIN IDS_DRIVE_CDROM "CD-ROM" IDS_DRIVE_LETTERS_EXCEEDED "Nebegalite pridėti daugiau diskų.\n\nKiekvienas diskas turi turėti raidę, nuo A iki Z, todėl negalite turėti daugiau nei 26" IDS_SYSTEM_DRIVE_LABEL "Sisteminis diskas" - IDS_CONFIRM_DELETE_C "Ar tikrai norite pašalinti C diską?\n\nDaugelis Windows programų mano, kad C diskas egzistuoja ir neveikia, kai jis neegzistuoja. Jei tęsite, nepamirškite atkurti C disko!" + IDS_CONFIRM_DELETE_C "Ar tikrai norite ištrinti C diską?\n\nDaugelis Windows programų mano, kad C diskas egzistuoja ir neveikia, jei jis neegzistuoja. Jei tęsite, nepamirškite atkurti C disko!" IDS_COL_DRIVELETTER "Raidė" IDS_COL_DRIVEMAPPING "Disko atvaizdavimas" - IDS_NO_DRIVE_C "Neturite C disko. Tai nėra gerai.\n\nNepamirškite paspausti „Pridėti“ diskų kortelėje, kad jį sukurtumėte!\n" + IDS_NO_DRIVE_C "Neturite C disko. Tai nėra gerai.\n\nNepamirškite paspausti 'Pridėti' diskų kortelėje, kad jį sukurtumėte!\n" END STRINGTABLE DISCARDABLE @@ -289,7 +286,7 @@ BEGIN IDS_DEVICES_MIDIIN "MIDI In įrenginiai" IDS_DEVICES_AUX "Aux įrenginiai" IDS_DEVICES_MIXER "Mixer įrenginiai" - IDS_UNAVAILABLE_DRIVER "Registre rasta tvarkyklė, kuri yra neprieinama!\n\nPašalinti „%s“ iš registro?" + IDS_UNAVAILABLE_DRIVER "Registre rasta tvarkyklė, kuri yra neprieinama!\n\nPašalinti '%s' iš registro?" IDS_WARNING "Įspėjimas" END @@ -328,3 +325,5 @@ BEGIN IDC_SYSPARAMS_MENU_HILIGHT "Meniu paryškinimas" IDC_SYSPARAMS_MENUBAR "Meniu juosta" END + +#pragma code_page(default) diff --git a/programs/winecfg/Makefile.in b/programs/winecfg/Makefile.in index 787615ba80e..823084f0b2d 100644 --- a/programs/winecfg/Makefile.in +++ b/programs/winecfg/Makefile.in @@ -18,31 +18,7 @@ C_SRCS = \ winecfg.c \ x11drvdlg.c -RC_SRCS = \ - Bg.rc \ - Cs.rc \ - Da.rc \ - De.rc \ - En.rc \ - Es.rc \ - Fi.rc \ - Fr.rc \ - Hu.rc \ - It.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ro.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc \ - winecfg.rc +RC_SRCS = winecfg.rc @MAKE_PROG_RULES@ diff --git a/programs/winecfg/Nl.rc b/programs/winecfg/Nl.rc index 6c43883814f..62068db334f 100644 --- a/programs/winecfg/Nl.rc +++ b/programs/winecfg/Nl.rc @@ -5,7 +5,6 @@ * Copyright 2004 Rein Klazes * Copyright 2005-2006 Paul Vriens * Copyright 2007 Maarten Lankhorst - * Copyright 2009 Vincent Beers * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -23,9 +22,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL IDR_WINECFG MENU DISCARDABLE @@ -47,8 +43,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Windows registratie-informatie ", IDC_STATIC, 15, 110, 230, 55 LTEXT "Eigenaar:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "Organisatie:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END @@ -57,7 +53,7 @@ STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN GROUPBOX " Toepassingsinstellingen ",IDC_STATIC, 8,4,244,240 - LTEXT "Wine geeft de mogelijkheid om per toepassing de Windowsversie in te stellen. Deze tab is gekoppeld aan de Libraries en Graphics tabs om zowel systeemwijde als applicatiespecifieke instellingen in deze tabs mogelijk te maken.", + LTEXT "Wine geeft de mogelijkheid om per toepassing de Windowsversie in te stellen. Deze tab is gekoppeld aan de Libraries en Graphics tabs om zowel systeemwijde als applicatie specifieke instellingen in deze tabs mogelijk te maken.", IDC_STATIC,15,20,227,40 CONTROL "Toepassingen",IDC_APP_LISTVIEW,"SysListView32",WS_BORDER | WS_TABSTOP | LVS_LIST | LVS_SINGLESEL | LVS_SHOWSELALWAYS, 15,60,230,140 @@ -71,7 +67,7 @@ IDD_GRAPHCFG DIALOG DISCARDABLE 0, 0, 260, 250 STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX " Vensterinstellingen ",IDC_STATIC,8,4,244,84 + GROUPBOX " Venster-instellingen ",IDC_STATIC,8,4,244,84 CONTROL "Een DirectX programma kan de muis in een venster vasthouden.",IDC_DX_MOUSE_GRAB,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,20,230,8 CONTROL "Laat de window manager de vensters &decoreren",IDC_ENABLE_DECORATED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,32,230,8 CONTROL "Laat de window manager de vensters beheren",IDC_ENABLE_MANAGED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,44,230,8 @@ -87,11 +83,11 @@ BEGIN COMBOBOX IDC_D3D_VSHADER_MODE,120,108,125,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP CONTROL "Pixel Shader toestaan (indien ondersteund door de hardware)",IDC_D3D_PSHADER_MODE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,126,230,10 - GROUPBOX " Scherm&resolutie ",IDC_STATIC,8,151,244,93 + GROUPBOX " Scherm &Resolutie ",IDC_STATIC,8,151,244,93 CONTROL "", IDC_RES_TRACKBAR, "msctls_trackbar32",WS_TABSTOP,12,161,187,15 EDITTEXT IDC_RES_DPIEDIT,204,161,23,13,ES_NUMBER|WS_TABSTOP LTEXT "dpi",IDC_STATIC,235,163,10,8 - LTEXT "Dit is een tekstvoorbeeld in Tahoma met puntgrootte 10",IDC_RES_FONT_PREVIEW,15,181,230,55 + LTEXT "Dit is een tekst voorbeeld in Tahoma met puntgrootte 10",IDC_RES_FONT_PREVIEW,15,181,230,55 END IDD_DLLCFG DIALOG DISCARDABLE 0, 0, 260, 250 @@ -115,14 +111,14 @@ STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU CAPTION "Edit Override" FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX " Laadvolgorde ",IDC_STATIC,8,4,94,66 + GROUPBOX " Laad volgorde ",IDC_STATIC,8,4,94,66 CONTROL "&Builtin (Wine)",IDC_RAD_BUILTIN,"Button", BS_AUTORADIOBUTTON | WS_GROUP,16,14,75,10 CONTROL "&Native (Windows)",IDC_RAD_NATIVE,"Button", BS_AUTORADIOBUTTON,16,24,75,10 CONTROL "Bui<in dan Native",IDC_RAD_BUILTIN_NATIVE,"Button", BS_AUTORADIOBUTTON,16,34,75,10 CONTROL "Nati&ve dan Builtin",IDC_RAD_NATIVE_BUILTIN,"Button", BS_AUTORADIOBUTTON,16,44,75,10 CONTROL "&Uitzetten",IDC_RAD_DISABLE,"Button", BS_AUTORADIOBUTTON,16,54,75,10 DEFPUSHBUTTON "OK",IDOK,8,74,45,14,WS_GROUP - PUSHBUTTON "Annuleren",IDCANCEL,57,74,45,14,WS_GROUP + PUSHBUTTON "Afbreken",IDCANCEL,57,74,45,14,WS_GROUP END IDD_DRIVECFG DIALOG DISCARDABLE 0, 0, 260, 250 @@ -130,7 +126,7 @@ STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN GROUPBOX " Stations ",IDC_STATIC,8,4,244,240 - LTEXT "Kon niet verbinden met de mount manager, de schijfconfiguratie kan niet worden bewerkt.", IDC_STATIC_MOUNTMGR_ERROR, 15,30,220,76 + LTEXT "Failed to connect to the mount manager, the drive configuration cannot be edited.", IDC_STATIC_MOUNTMGR_ERROR, 15,30,220,76 CONTROL "Listview",IDC_LIST_DRIVES,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,18,232,76 PUSHBUTTON "&Toevoegen",IDC_BUTTON_ADD,15,98,54,14 @@ -147,7 +143,7 @@ BEGIN LTEXT "Naam en serienummer",IDC_LABELSERIAL_STATIC,15,155,131,10 - PUSHBUTTON "&Geavanceerd...",IDC_BUTTON_SHOW_HIDE_ADVANCED,183,136,65,13 + PUSHBUTTON "Toon &Uitgebreid",IDC_BUTTON_SHOW_HIDE_ADVANCED,183,136,65,13 CONTROL "Automatisch detecteren van apparaat:",IDC_RADIO_AUTODETECT,"Button", BS_AUTORADIOBUTTON,15,166,150,10 EDITTEXT IDC_EDIT_DEVICE,27,176,174,13,ES_AUTOHSCROLL @@ -157,29 +153,29 @@ BEGIN LTEXT "&Naam:",IDC_STATIC_LABEL,33,208,60,12 EDITTEXT IDC_EDIT_LABEL,94,205,78,13,ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "S&erienummer:",IDC_STATIC_SERIAL,33,225,60,12 + LTEXT "S&erie nummer:",IDC_STATIC_SERIAL,33,225,60,12 EDITTEXT IDC_EDIT_SERIAL,94,221,78,13,ES_AUTOHSCROLL | WS_TABSTOP - CONTROL "Toon \".\" bestanden",IDC_SHOW_DOT_FILES,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,8,260,230,8 + CONTROL "Toon \".\" files",IDC_SHOW_DOT_FILES,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,8,260,230,8 END IDD_AUDIOCFG DIALOG DISCARDABLE 0, 0, 260, 250 STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX " Stuurprogrammaselectie ",IDC_STATIC,8,4,244,195 - LTEXT "Selecteer een geluidsstuurprogramma door het gewenste stuurprogramma aan te vinken. Zet het geluid uit door geen stuurprogramma te selecteren. Het selecteren van meerdere stuurprogramma's wordt niet aanbevolen. Rechtsklik op een stuurprogramma om het te configureren.",IDC_STATIC,15,20,227,45 + GROUPBOX " Stuurprogramma selectie ",IDC_STATIC,8,4,244,195 + LTEXT "Selecteer een geluids-stuurprogramma door het aanvinken van het gewenste stuurprogramma. Zet het geluid uit door geen stuurprogramma te selecteren. Het selecteren van meerdere stuurprogramma's wordt niet aanbevolen. Configureer een stuurprogramma d.m.v. een rechter muisklik hierop.",IDC_STATIC,15,20,227,45 CONTROL "Apparaten",IDC_AUDIO_TREE,"SysTreeView32",WS_BORDER | WS_TABSTOP,15,65,140,125 PUSHBUTTON "Geluidstest",IDC_AUDIO_TEST,165,65,79,14 PUSHBUTTON "Configuratiescherm",IDC_AUDIO_CONTROL_PANEL,165,85,79,14 GROUPBOX " DirectSound ",IDC_STATIC,8,205,244,60 LTEXT "Hardwareversnelling: ",IDC_STATIC,15,215,90,10 COMBOBOX IDC_DSOUND_HW_ACCEL,100,213,150,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Samplefrequentie:",IDC_STATIC,15,232,70,8 + LTEXT "Monsterfrequentie:",IDC_STATIC,15,232,70,8 COMBOBOX IDC_DSOUND_RATES,90,230,42,76,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Bits per sample:",IDC_STATIC,157,232,60,8 + LTEXT "Bits per monster:",IDC_STATIC,157,232,60,8 COMBOBOX IDC_DSOUND_BITS,220,230,30,56,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - CONTROL "Stuurprogramma-emulatie",IDC_DSOUND_DRV_EMUL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,250,230,10 + CONTROL "Stuurprogramma emulatie",IDC_DSOUND_DRV_EMUL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,250,230,10 END IDD_DESKTOP_INTEGRATION DIALOG DISCARDABLE 0, 0, 260, 250 @@ -203,7 +199,7 @@ BEGIN CONTROL "",IDC_SYSPARAM_SIZE_UD,UPDOWN_CLASS,UDS_SETBUDDYINT | WS_DISABLED,187,74,15,13 PUSHBUTTON "Font",IDC_SYSPARAM_FONT,208,74,37,13,WS_DISABLED GROUPBOX " Shell Folder ",IDC_STATIC,8,114,244,100 /* FIXME */ - CONTROL "Lijstweergave",IDC_LIST_SFPATHS,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | + CONTROL "Listview",IDC_LIST_SFPATHS,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,126,230,64 CONTROL "Verwijs naar:",IDC_LINK_SFPATH,"Button",BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED,15,195,60,13 EDITTEXT IDC_EDIT_SFPATH,75,195,125,13,ES_AUTOHSCROLL|WS_TABSTOP|WS_DISABLED @@ -227,7 +223,7 @@ BEGIN IDS_WINECFG_TITLE_APP "Wine configuratie voor %s" IDS_THEMEFILE "Thema-bestanden" IDS_THEMEFILE_SELECT "Thema-bestanden kiezen" - IDS_AUDIO_MISSING "Op dit moment is er geen stuurprogramma voor geluid gespecificeerd in het register.\n\nEen aanbevolen stuurprogramma is voor u geselecteerd.\nU kunt dit stuurprogramma gebruiken of (indien beschikbaar) een ander selecteren.\n\nKlik op Toepassen om deze selectie te activeren." + IDS_AUDIO_MISSING "Op dit moment is er geen stuurprogramma voor geluid gespecificeerd in de registry.\n\nEen aanbevolen stuurbestand is voor u geselecteerd.\nU kunt dit stuurbestand gebruiken of (indien beschikbaar) een ander selecteren.\n\nKlik op 'Toepassen' om deze selectie te activeren." IDS_SHELL_FOLDER "Persoonlijke map" IDS_LINKS_TO "Verwijst naar" END @@ -236,12 +232,12 @@ STRINGTABLE DISCARDABLE BEGIN IDS_DLL_WARNING "Veranderen van de laadvolgorde van deze bibliotheek wordt niet aanbevolen\n. Weet u zeker dat u dit wilt doen?" IDS_DLL_WARNING_CAPTION "Waarschuwing: systeembibliotheek" - IDS_DLL_NATIVE "native" - IDS_DLL_BUILTIN "builtin" - IDS_DLL_NATIVE_BUILTIN "native, builtin" - IDS_DLL_BUILTIN_NATIVE "builtin, native" - IDS_DLL_DISABLED "uitgeschakeld" - IDS_DEFAULT_SETTINGS "Standaardinstellingen" + IDS_DLL_NATIVE "Native (Windows)" + IDS_DLL_BUILTIN "Builtin (Wine)" + IDS_DLL_NATIVE_BUILTIN "Native dan builtin" + IDS_DLL_BUILTIN_NATIVE "Builtin dan native" + IDS_DLL_DISABLED "Uitgeschakeld" + IDS_DEFAULT_SETTINGS "Standaard instellingen" IDS_EXECUTABLE_FILTER "Wine toepassingen (*.exe,*.exe.so)\0*.exe;*.exe.so\0" IDS_USE_GLOBAL_SETTINGS "Gebruike globale instellingen" IDS_SELECT_EXECUTABLE "Selecteer een uitvoerbaar bestand" @@ -284,13 +280,13 @@ BEGIN IDS_DRIVER_COREAUDIO "CoreAudio Stuurprogramma" IDS_OPEN_DRIVER_ERROR "%s kon niet worden geopend!" IDS_SOUNDDRIVERS "Stuurprogramma's voor geluid" - IDS_DEVICES_WAVEOUT "Wave Out Apparaten" - IDS_DEVICES_WAVEIN "Wave In Apparaten" - IDS_DEVICES_MIDIOUT "MIDI Out Apparaten" - IDS_DEVICES_MIDIIN "MIDI In Apparaten" - IDS_DEVICES_AUX "Aux Apparaten" - IDS_DEVICES_MIXER "Mixer Apparaten" - IDS_UNAVAILABLE_DRIVER "Stuurprogramma in het register is niet beschikbaar!\n\nVerwijder \"%s\" uit het register?" + IDS_DEVICES_WAVEOUT "Wave Out apparaten" + IDS_DEVICES_WAVEIN "Wave In apparaten" + IDS_DEVICES_MIDIOUT "MIDI Out apparaten" + IDS_DEVICES_MIDIIN "MIDI In apparaten" + IDS_DEVICES_AUX "Aux apparaten" + IDS_DEVICES_MIXER "Mixer apparaten" + IDS_UNAVAILABLE_DRIVER "Stuurprogramma in de registry is niet beschikbaar!\n\nVerwijder \"%s\" uit de registry?" IDS_WARNING "Waarschuwing" END @@ -306,24 +302,24 @@ BEGIN IDC_SYSPARAMS_SELECTION_TEXT "Selectie Tekst" IDC_SYSPARAMS_TOOLTIP "ToolTip Achtergrond" IDC_SYSPARAMS_TOOLTIP_TEXT "ToolTip Tekst" - IDC_SYSPARAMS_WINDOW "Venster Achtergrond" - IDC_SYSPARAMS_WINDOW_TEXT "Venster Tekst" - IDC_SYSPARAMS_ACTIVE_TITLE "Actieve Titelbalk" - IDC_SYSPARAMS_ACTIVE_TITLE_TEXT "Actieve Titeltekst" - IDC_SYSPARAMS_INACTIVE_TITLE "Inactieve Titelbalk" - IDC_SYSPARAMS_INACTIVE_TITLE_TEXT "Inactieve Titeltekst" - IDC_SYSPARAMS_MSGBOX_TEXT "Meldingsvenster Tekst" + IDC_SYSPARAMS_WINDOW "Window Achtergrond" + IDC_SYSPARAMS_WINDOW_TEXT "Window Tekst" + IDC_SYSPARAMS_ACTIVE_TITLE "Actieve Titel Balk" + IDC_SYSPARAMS_ACTIVE_TITLE_TEXT "Actieve Titel Tekst" + IDC_SYSPARAMS_INACTIVE_TITLE "Inactieve Titel Balk" + IDC_SYSPARAMS_INACTIVE_TITLE_TEXT "Inactieve Title Tekst" + IDC_SYSPARAMS_MSGBOX_TEXT "Melding Window Tekst" IDC_SYSPARAMS_APPWORKSPACE "Applicatie Werkruimte" - IDC_SYSPARAMS_WINDOW_FRAME "Vensterraamwerk" + IDC_SYSPARAMS_WINDOW_FRAME "Window Raamwerk" IDC_SYSPARAMS_ACTIVE_BORDER "Actieve Rand" IDC_SYSPARAMS_INACTIVE_BORDER "Inactieve Rand" - IDC_SYSPARAMS_BUTTON_SHADOW "Knopschaduw" + IDC_SYSPARAMS_BUTTON_SHADOW "Knoppen Schaduw" IDC_SYSPARAMS_GRAY_TEXT "Grijze Tekst" IDC_SYSPARAMS_BUTTON_HILIGHT "Knoppen Gemarkeerd" IDC_SYSPARAMS_BUTTON_DARK_SHADOW "Knoppen Donkere Schaduw" IDC_SYSPARAMS_BUTTON_LIGHT "Knoppen Licht" IDC_SYSPARAMS_BUTTON_ALTERNATE "Knoppen Alternatieve Achtergrond" - IDC_SYSPARAMS_HOT_TRACKING "Hot-Tracked Onderdeel" + IDC_SYSPARAMS_HOT_TRACKING "'Hot-Tracked' Onderdeel" IDC_SYSPARAMS_ACTIVE_TITLE_GRADIENT "Actieve Titelbalk Verloop" IDC_SYSPARAMS_INACTIVE_TITLE_GRADIENT "Inactieve Titelbalk Verloop" IDC_SYSPARAMS_MENU_HILIGHT "Menu Gemarkeerd" diff --git a/programs/winecfg/No.rc b/programs/winecfg/No.rc index b2a5eaee00c..9dd3572337e 100644 --- a/programs/winecfg/No.rc +++ b/programs/winecfg/No.rc @@ -20,9 +20,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL IDR_WINECFG MENU DISCARDABLE @@ -44,8 +41,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Brukerinformasjon ", IDC_STATIC, 15, 110, 230, 55 LTEXT "Eier:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "Organisasjon:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END diff --git a/programs/winecfg/Pl.rc b/programs/winecfg/Pl.rc index bd968deed02..e3bf093af31 100644 --- a/programs/winecfg/Pl.rc +++ b/programs/winecfg/Pl.rc @@ -23,9 +23,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT IDR_WINECFG MENU DISCARDABLE @@ -47,8 +44,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Windows Registration Information ", IDC_STATIC, 15, 110, 230, 55 LTEXT "Owner:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "Organization:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END diff --git a/programs/winecfg/Pt.rc b/programs/winecfg/Pt.rc index 503fc969051..2e3cef6ebb3 100644 --- a/programs/winecfg/Pt.rc +++ b/programs/winecfg/Pt.rc @@ -3,7 +3,7 @@ * Portuguese Language Support * * Copyright 2003 Marcelo Duarte - * Copyright 2004,2007,2008 Américo José Melo + * Copyright 2004,2007,2008 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 @@ -21,11 +21,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE IDR_WINECFG MENU DISCARDABLE @@ -48,10 +43,10 @@ BEGIN LTEXT "http://www.winehq.org/",IDC_STATIC,119,31,106,8 LTEXT "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.", IDC_STATIC,119,44,124,72 - GROUPBOX " Informações de registro do Windows ", IDC_STATIC, 15, 110, 230, 55 - LTEXT "Proprietário:", IDC_STATIC, 22, 126, 40, 20 + GROUPBOX " Informa��es de registro do Windows ", IDC_STATIC, 15, 110, 230, 55 + LTEXT "Propriet�rio:", IDC_STATIC, 22, 126, 40, 20 + LTEXT "Organiza��o:", IDC_STATIC, 22, 140, 50, 20 EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "Organização:", IDC_STATIC, 22, 140, 50, 20 EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END @@ -64,12 +59,12 @@ BEGIN LTEXT PACKAGE_STRING,IDC_STATIC,119,17,120,8 CONTROL IDB_WINE,IDC_STATIC,"Static", SS_BITMAP, 15,17,157,111 LTEXT "http://www.winehq.org/",IDC_STATIC,119,31,106,8 - LTEXT "Esta biblioteca é de código livre; pode-a redistribuir e/ou modificar nos termos da Licença Publica Geral Lesser GNU como publicado pela Fundação de Programas Livres; também a versão 2.1 da Licença, ou (na sua opinião) qualquer versão posterior.", + LTEXT "Esta biblioteca � de c�digo livre; pode-a redistribuir e/ou modificar nos termos da Licen�a Publica Geral Lesser GNU como publicado pela Funda��o de Programas Livres; tamb�m a vers�o 2.1 da Licen�a, ou (na sua opini�o) qualquer vers�o posterior.", IDC_STATIC,119,44,124,72 - GROUPBOX " Informações de registro do Windows ", IDC_STATIC, 15, 110, 230, 55 - LTEXT "Proprietário:", IDC_STATIC, 22, 126, 40, 20 + GROUPBOX " Informa��es de registro do Windows ", IDC_STATIC, 15, 110, 230, 55 + LTEXT "Propriet�rio:", IDC_STATIC, 22, 126, 40, 20 + LTEXT "Organiza��o:", IDC_STATIC, 22, 140, 50, 20 EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "Organização:", IDC_STATIC, 22, 140, 50, 20 EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END @@ -80,14 +75,14 @@ IDD_APPCFG DIALOG DISCARDABLE 0, 0, 260, 250 STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX " Configurações da aplicação ",IDC_STATIC, 8,4,244,240 - LTEXT "Wine pode imitar vários estilos e versões do Windows para cada aplicação", + GROUPBOX " Configura��es da aplica��o ",IDC_STATIC, 8,4,244,240 + LTEXT "Wine pode imitar v�rios estilos e vers�es do Windows para cada aplica��o", IDC_STATIC,15,20,227,20 - CONTROL "Aplicações",IDC_APP_LISTVIEW,"SysListView32",WS_BORDER | WS_TABSTOP | LVS_LIST | LVS_SINGLESEL | LVS_SHOWSELALWAYS, + CONTROL "Aplica��es",IDC_APP_LISTVIEW,"SysListView32",WS_BORDER | WS_TABSTOP | LVS_LIST | LVS_SINGLESEL | LVS_SHOWSELALWAYS, 15,50,230,150 - PUSHBUTTON "&Adiconar aplicação...",IDC_APP_ADDAPP, 90,204,75,14 - PUSHBUTTON "&Remover aplicação",IDC_APP_REMOVEAPP, 170,204,75,14 - LTEXT "Versão do &Windows:",IDC_STATIC,17,226,58,8 + PUSHBUTTON "&Adiconar aplica��o...",IDC_APP_ADDAPP, 90,204,75,14 + PUSHBUTTON "&Remover aplica��o",IDC_APP_REMOVEAPP, 170,204,75,14 + LTEXT "Vers�o do &Windows:",IDC_STATIC,17,226,58,8 COMBOBOX IDC_WINVER,83,224,163,56,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP END @@ -97,14 +92,14 @@ IDD_APPCFG DIALOG DISCARDABLE 0, 0, 260, 250 STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX " Definições da aplicação ",IDC_STATIC, 8,4,244,240 - LTEXT "O Wine pode imitar vários estilos e versões do Windows para cada aplicação. Esta aba está ligada às abas de Ligações e Gráficos para permitir alterar definições por aplicação ou no sistema assim como também nessas abas.", + GROUPBOX " Defini��es da aplica��o ",IDC_STATIC, 8,4,244,240 + LTEXT "O Wine pode imitar v�rios estilos e vers�es do Windows para cada aplica��o. Esta aba est� ligada �s abas de Liga��es e Gr�ficos para permitir alterar defini��es por aplica��o ou no sistema assim como tamb�m nessas abas.", IDC_STATIC,15,20,227,45 - CONTROL "Aplicações",IDC_APP_LISTVIEW,"SysListView32",WS_BORDER | WS_TABSTOP | LVS_LIST | LVS_SINGLESEL | LVS_SHOWSELALWAYS, + CONTROL "Aplica��es",IDC_APP_LISTVIEW,"SysListView32",WS_BORDER | WS_TABSTOP | LVS_LIST | LVS_SINGLESEL | LVS_SHOWSELALWAYS, 15,55,230,140 - PUSHBUTTON "&Adiconar aplicação...",IDC_APP_ADDAPP, 90,204,75,14 - PUSHBUTTON "&Remover aplicação",IDC_APP_REMOVEAPP, 170,204,75,14 - LTEXT "Versão &Windows:",IDC_STATIC,17,226,58,8 + PUSHBUTTON "&Adiconar aplica��o...",IDC_APP_ADDAPP, 90,204,75,14 + PUSHBUTTON "&Remover aplica��o",IDC_APP_REMOVEAPP, 170,204,75,14 + LTEXT "Vers�o &Windows:",IDC_STATIC,17,226,58,8 COMBOBOX IDC_WINVER,83,224,163,56,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP END @@ -115,13 +110,13 @@ IDD_GRAPHCFG DIALOG DISCARDABLE 0, 0, 260, 250 STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX " Configurações de janela ",IDC_STATIC,8,4,244,84 + GROUPBOX " Configura��es de janela ",IDC_STATIC,8,4,244,84 CONTROL "Programas DirectX podem impedir que o mouse deixe a janela?",IDC_DX_MOUSE_GRAB,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,20,230,8 CONTROL "Allow the window manager to &decorate the windows",IDC_ENABLE_DECORATED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,32,230,8 CONTROL "Allow the &window manager to control the windows",IDC_ENABLE_MANAGED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,44,230,8 - CONTROL "Emular uma área de trabalho virtual",IDC_ENABLE_DESKTOP,"Button", + CONTROL "Emular uma �rea de trabalho virtual",IDC_ENABLE_DESKTOP,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,15,56,230,8 - LTEXT "Tamanho da área de trabalho:",IDC_DESKTOP_SIZE,15,70,44,8,WS_DISABLED + LTEXT "Tamanho da �rea de trabalho:",IDC_DESKTOP_SIZE,15,70,44,8,WS_DISABLED LTEXT "X",IDC_DESKTOP_BY,109,70,8,8,WS_DISABLED EDITTEXT IDC_DESKTOP_WIDTH,64,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED EDITTEXT IDC_DESKTOP_HEIGHT,117,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED @@ -144,13 +139,13 @@ IDD_GRAPHCFG DIALOG DISCARDABLE 0, 0, 260, 250 STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX " Definições da Janela ",IDC_STATIC,8,4,244,184 - CONTROL "Permitir às aplicações DirectX impedir que o &rato deixe a sua janela",IDC_DX_MOUSE_GRAB,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,20,230,8 + GROUPBOX " Defini��es da Janela ",IDC_STATIC,8,4,244,184 + CONTROL "Permitir �s aplica��es DirectX impedir que o &rato deixe a sua janela",IDC_DX_MOUSE_GRAB,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,20,230,8 CONTROL "Allow the window manager to &decorate the windows",IDC_ENABLE_DECORATED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,32,230,8 CONTROL "Permitit ao &gestor de janelas controlar as janelas",IDC_ENABLE_MANAGED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,44,230,8 - CONTROL "Emular um ecrã &virtual",IDC_ENABLE_DESKTOP,"Button", + CONTROL "Emular um ecr� &virtual",IDC_ENABLE_DESKTOP,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,15,56,230,8 - LTEXT "Tamanho do &ecrã:",IDC_DESKTOP_SIZE,15,70,44,8,WS_DISABLED + LTEXT "Tamanho do &ecr�:",IDC_DESKTOP_SIZE,15,70,44,8,WS_DISABLED LTEXT "X",IDC_DESKTOP_BY,109,70,8,8,WS_DISABLED EDITTEXT IDC_DESKTOP_WIDTH,64,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED EDITTEXT IDC_DESKTOP_HEIGHT,117,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED @@ -160,7 +155,7 @@ BEGIN COMBOBOX IDC_D3D_VSHADER_MODE,100,108,145,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP CONTROL "Permitir Sombreamento de &Pontos (se suportado pelo material)",IDC_D3D_PSHADER_MODE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,126,230,10 - GROUPBOX " &Resolução do Ecrã ",IDC_STATIC,8,151,244,93 + GROUPBOX " &Resolu��o do Ecr� ",IDC_STATIC,8,151,244,93 CONTROL "", IDC_RES_TRACKBAR, "msctls_trackbar32",WS_TABSTOP,12,161,187,15 EDITTEXT IDC_RES_DPIEDIT,204,161,23,13,ES_NUMBER|WS_TABSTOP LTEXT "dpi",IDC_STATIC,235,163,10,8 @@ -174,13 +169,13 @@ IDD_DLLCFG DIALOG DISCARDABLE 0, 0, 260, 250 STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX " Substituição de DLL ",IDC_STATIC,8,4,244,240 - LTEXT "As bibliotecas de Ligação Dinâmica pode ser especificadas individualmente para serem embutidas (fornecido pelo Wine) ou nativas (tiradas do Windows ou fornecidas pela aplicação)." + GROUPBOX " Substitui��o de DLL ",IDC_STATIC,8,4,244,240 + LTEXT "As bibliotecas de Liga��o Din�mica pode ser especificadas individualmente para serem embutidas (fornecido pelo Wine) ou nativas (tiradas do Windows ou fornecidas pela aplica��o)." ,IDC_STATIC,16,16,220,32 - LTEXT "&Nova substituição para:",IDC_STATIC,16,58,100,8 + LTEXT "&Nova substitui��o para:",IDC_STATIC,16,58,100,8 COMBOBOX IDC_DLLCOMBO,16,68,140,14,CBS_DROPDOWN | WS_VSCROLL | WS_TABSTOP | CBS_SORT | CBS_LOWERCASE PUSHBUTTON "&Adicionar",IDC_DLLS_ADDDLL, 164,68,82,13,BS_DEFPUSHBUTTON - LTEXT "Substituições E&xistentes:",IDC_STATIC,16,86,100,8 + LTEXT "Substitui��es E&xistentes:",IDC_STATIC,16,86,100,8 LISTBOX IDC_DLLS_LIST,16,96,140,140,WS_BORDER | WS_TABSTOP | WS_VSCROLL PUSHBUTTON "&Editar",IDC_DLLS_EDITDLL,164,96,82,14 PUSHBUTTON "&Remover",IDC_DLLS_REMOVEDLL,164,114,82,14 @@ -191,7 +186,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE IDD_LOADORDER DIALOG DISCARDABLE 80, 90, 110, 92 STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Editar Substituição" +CAPTION "Editar Substitui��o" FONT 8, "MS Shell Dlg" BEGIN GROUPBOX " Ordem de Carregamento ",IDC_STATIC,8,4,94,66 @@ -252,7 +247,6 @@ STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN GROUPBOX " &Unidades ",IDC_STATIC,8,4,244,240 - LTEXT "Falhou a ligação ao gestor de unidades, a configuração da unidade não pode ser editada.", IDC_STATIC_MOUNTMGR_ERROR, 15,30,220,76 CONTROL "Listagem",IDC_LIST_DRIVES,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,18,232,76 PUSHBUTTON "&Adicionar...",IDC_BUTTON_ADD,15,98,44,14 @@ -260,16 +254,16 @@ BEGIN PUSHBUTTON "Auto&detectar...",IDC_BUTTON_AUTODETECT,190,98,56,14 /* editing drive details */ - LTEXT "&Localização:",IDC_STATIC_PATH,15,123,20,9 + LTEXT "&Localiza��o:",IDC_STATIC,15,123,20,9 EDITTEXT IDC_EDIT_PATH,41,120,160,13,ES_AUTOHSCROLL | WS_TABSTOP PUSHBUTTON "&Procurar...",IDC_BUTTON_BROWSE_PATH,206,120,40,13 LTEXT "&Tipo:",IDC_STATIC_TYPE,15,138,21,10 COMBOBOX IDC_COMBO_TYPE,41,135,77,60,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Nome e nº de serie",IDC_LABELSERIAL_STATIC,15,155,95,10 + LTEXT "Nome e n� de serie",IDC_LABELSERIAL_STATIC,15,155,95,10 - PUSHBUTTON "Mostrar &Avançado",IDC_BUTTON_SHOW_HIDE_ADVANCED,186,136,60,13 + PUSHBUTTON "Mostrar &Avan�ado",IDC_BUTTON_SHOW_HIDE_ADVANCED,186,136,60,13 CONTROL "Autodetectar &Dispositivo:",IDC_RADIO_AUTODETECT,"Button", BS_AUTORADIOBUTTON,15,166,93,10 EDITTEXT IDC_EDIT_DEVICE,27,176,174,13,ES_AUTOHSCROLL @@ -279,7 +273,7 @@ BEGIN LTEXT "&Nome:",IDC_STATIC_LABEL,33,208,29,12 EDITTEXT IDC_EDIT_LABEL,63,205,78,13,ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "Nº S&erie:",IDC_STATIC_SERIAL,33,225,29,12 + LTEXT "N� S&erie:",IDC_STATIC_SERIAL,33,225,29,12 EDITTEXT IDC_EDIT_SERIAL,63,221,78,13,ES_AUTOHSCROLL | WS_TABSTOP CONTROL "Mostrar &ficheiros com pontos",IDC_SHOW_DOT_FILES,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,8,260,230,8 @@ -292,19 +286,19 @@ IDD_AUDIOCFG DIALOG DISCARDABLE 0, 0, 260, 250 STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX " Selecção do Controlador ",IDC_STATIC,8,4,244,195 - LTEXT "Seleccione um controlador de som marcando o desejado. Desactive o som não seleccionado qualquer controlador. Não é recomendada a selecção de vários controladores . Configure um controlador seleccionado-o com o clique direito.",IDC_STATIC,15,18,227,35 + GROUPBOX " Selec��o do Controlador ",IDC_STATIC,8,4,244,195 + LTEXT "Seleccione um controlador de som marcando o desejado. Desactive o som n�o seleccionado qualquer controlador. N�o � recomendada a selec��o de v�rios controladores . Configure um controlador seleccionado-o com o clique direito.",IDC_STATIC,15,18,227,35 CONTROL "Dispositivos",IDC_AUDIO_TREE,"SysTreeView32",WS_BORDER | WS_TABSTOP,15,55,140,140 PUSHBUTTON "&Testar Som",IDC_AUDIO_TEST,170,55,65,14 PUSHBUTTON "Painel de &Controlo",IDC_AUDIO_CONTROL_PANEL,170,75,65,14 GROUPBOX " DirectSound ",IDC_STATIC,8,205,244,60 - LTEXT "Aceleração do &Material: ",IDC_STATIC,15,215,90,10 + LTEXT "Acelera��o do &Material: ",IDC_STATIC,15,215,90,10 COMBOBOX IDC_DSOUND_HW_ACCEL,100,213,150,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP LTEXT "Taxa de Amo&stra Predefinida:",IDC_STATIC,15,232,70,8 COMBOBOX IDC_DSOUND_RATES,90,230,42,76,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP LTEXT "&Bits Predefinidos por Amostra:",IDC_STATIC,137,232,80,8 COMBOBOX IDC_DSOUND_BITS,220,230,30,56,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - CONTROL "&Emulação do Controlador",IDC_DSOUND_DRV_EMUL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,250,230,10 + CONTROL "&Emula��o do Controlador",IDC_DSOUND_DRV_EMUL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,250,230,10 END @@ -344,7 +338,7 @@ IDD_DESKTOP_INTEGRATION DIALOG DISCARDABLE 0, 0, 260, 250 STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX " Aparência ",IDC_STATIC,8,4,244,106 + GROUPBOX " Apar�ncia ",IDC_STATIC,8,4,244,106 LTEXT "&Tema:",IDC_STATIC,15,16,130,8 COMBOBOX IDC_THEME_THEMECOMBO,15,24,130,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP PUSHBUTTON "&Instalar tema...",IDC_THEME_INSTALL,152,23,93,14 @@ -352,7 +346,7 @@ BEGIN COMBOBOX IDC_THEME_COLORCOMBO,15,48,112,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP LTEXT "&Tamanho:",IDC_THEME_SIZETEXT,135,40,110,8 COMBOBOX IDC_THEME_SIZECOMBO,135,48,110,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Ít&em:",IDC_STATIC,15,64,112,8 + LTEXT "�t&em:",IDC_STATIC,15,64,112,8 COMBOBOX IDC_SYSPARAM_COMBO,15,74,112,120,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP | CBS_SORT LTEXT "C&or:",IDC_SYSPARAM_COLOR_TEXT,135,64,25,8,WS_DISABLED PUSHBUTTON "",IDC_SYSPARAM_COLOR,135,74,25,13,WS_DISABLED | BS_OWNERDRAW @@ -384,12 +378,12 @@ BEGIN IDS_TAB_DESKTOP_INTEGRATION "Desktop Integration" IDS_TAB_AUDIO "Audio" IDS_TAB_ABOUT "About" - IDS_WINECFG_TITLE "Configuração do Wine" - IDS_WINECFG_TITLE_APP "Configuração do Wine para %s" + IDS_WINECFG_TITLE "Configura��o do Wine" + IDS_WINECFG_TITLE_APP "Configura��o do Wine para %s" IDS_THEMEFILE "Theme files" IDS_THEMEFILE_SELECT "Select a theme file" IDS_AUDIO_MISSING "There is no audio driver currently specified in the registry.\n\nA recommended driver has been selected for you.\nYou can use this driver or select another driver if available.\n\nYou must click Apply for the selection to take effect." - IDS_SHELL_FOLDER "Diretórios" + IDS_SHELL_FOLDER "Diret�rios" IDS_LINKS_TO "Links para" END @@ -397,24 +391,24 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE DISCARDABLE BEGIN - IDS_TAB_APPLICATIONS "Aplicações" + IDS_TAB_APPLICATIONS "Aplica��es" IDS_TAB_DLLS "Bibliotecas" IDS_TAB_DRIVES "Unidades" - IDS_CHOOSE_PATH "Seleccione o directório de destino unix." + IDS_CHOOSE_PATH "Seleccione o direct�rio de destino unix." IDS_HIDE_ADVANCED "&Ocultar" - IDS_SHOW_ADVANCED "&Avançado" + IDS_SHOW_ADVANCED "&Avan�ado" IDS_NOTHEME "(Sem Tema)" - IDS_TAB_GRAPHICS "Gráficos" - IDS_TAB_DESKTOP_INTEGRATION "Integração do Ecrã" - IDS_TAB_AUDIO "Áudio" + IDS_TAB_GRAPHICS "Gr�ficos" + IDS_TAB_DESKTOP_INTEGRATION "Integra��o do Ecr�" + IDS_TAB_AUDIO "�udio" IDS_TAB_ABOUT "Acerca" - IDS_WINECFG_TITLE "Configuração Wine" - IDS_WINECFG_TITLE_APP "Configuração Wine para %s" + IDS_WINECFG_TITLE "Configura��o Wine" + IDS_WINECFG_TITLE_APP "Configura��o Wine para %s" IDS_THEMEFILE "Ficheiros de temas" IDS_THEMEFILE_SELECT "Seleccione um ficheiro de tema" - IDS_AUDIO_MISSING "Não está actualmente nenhum controlador áudio seleccionado no registo.\n\nFoi seleccionado para si um controlador recomendado.\nPode usar este controlador ou seleccionar outro se disponível.\n\nTem que clicar am Aplicar para que a selecção tenha efeito." - IDS_SHELL_FOLDER "Directórios" - IDS_LINKS_TO "Ligações para" + IDS_AUDIO_MISSING "N�o est� actualmente nenhum controlador �udio seleccionado no registo.\n\nFoi seleccionado para si um controlador recomendado.\nPode usar este controlador ou seleccionar outro se dispon�vel.\n\nTem que clicar am Aplicar para que a selec��o tenha efeito." + IDS_SHELL_FOLDER "Direct�rios" + IDS_LINKS_TO "Liga��es para" END @@ -422,17 +416,17 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE DISCARDABLE BEGIN - IDS_DLL_WARNING "Não é recomendado que mude a ordem de carregamento desta biblioteca.\nTem certeza que quer fazer isto?" + IDS_DLL_WARNING "N�o � recomendado que mude a ordem de carregamento desta biblioteca.\nTem certeza que quer fazer isto?" IDS_DLL_WARNING_CAPTION "Aviso: biblioteca do sistema" IDS_DLL_NATIVE "nativa" IDS_DLL_BUILTIN "embutida" IDS_DLL_NATIVE_BUILTIN "nativa, embutida" IDS_DLL_BUILTIN_NATIVE "embutida, nativa" IDS_DLL_DISABLED "desactivada" - IDS_DEFAULT_SETTINGS "Definições Predefinidas" + IDS_DEFAULT_SETTINGS "Defini��es Predefinidas" IDS_EXECUTABLE_FILTER "Programas Wine (*.exe,*.exe.so)\0*.exe;*.exe.so\0" - IDS_USE_GLOBAL_SETTINGS "Usar definições globais" - IDS_SELECT_EXECUTABLE "Seleccionar um ficheiro executável" + IDS_USE_GLOBAL_SETTINGS "Usar defini��es globais" + IDS_SELECT_EXECUTABLE "Seleccionar um ficheiro execut�vel" END @@ -450,16 +444,16 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE DISCARDABLE BEGIN IDS_DRIVE_UNKNOWN "Autodetectar" - IDS_DRIVE_FIXED "Disco rígido local" + IDS_DRIVE_FIXED "Disco r�gido local" IDS_DRIVE_REMOTE "Partilha de rede" IDS_DRIVE_REMOVABLE "Disquete" IDS_DRIVE_CDROM "CD-ROM" - IDS_DRIVE_LETTERS_EXCEEDED "Não pode adicionar mais unidades.\n\nCada unidade tem que ter uma letra, de A a Z, como tal não pode adicionar mais de 26" + IDS_DRIVE_LETTERS_EXCEEDED "N�o pode adicionar mais unidades.\n\nCada unidade tem que ter uma letra, de A a Z, como tal n�o pode adicionar mais de 26" IDS_SYSTEM_DRIVE_LABEL "Unidade do sistema" - IDS_CONFIRM_DELETE_C "Tem certeza que deseja apaga a unidade C?\n\nA maior parte das aplicações Windows esperam que a unidade C exista, e irá danificar-se se não existir. Se continuar lembre-se de recriar a unidade!" + IDS_CONFIRM_DELETE_C "Tem certeza que deseja apaga a unidade C?\n\nA maior parte das aplica��es Windows esperam que a unidade C exista, e ir� danificar-se se n�o existir. Se continuar lembre-se de recriar a unidade!" IDS_COL_DRIVELETTER "Letra" IDS_COL_DRIVEMAPPING "Unidades" - IDS_NO_DRIVE_C "se não tem uma unidade C. Isto não é nada bom.\n\nCertifique-se que clica em ?Adicionar? no seprador Unidades para criar uma!\n" + IDS_NO_DRIVE_C "se n�o tem uma unidade C. Isto n�o � nada bom.\n\nCertifique-se que clica em ?Adicionar? no seprador Unidades para criar uma!\n" END @@ -468,26 +462,26 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE DISCARDABLE BEGIN IDS_ACCEL_FULL "Total" - IDS_ACCEL_STANDARD "Padrão" - IDS_ACCEL_BASIC "Básico" - IDS_ACCEL_EMULATION "Emulação" + IDS_ACCEL_STANDARD "Padr�o" + IDS_ACCEL_BASIC "B�sico" + IDS_ACCEL_EMULATION "Emula��o" IDS_DRIVER_PULSE "Controlador PulseAudio" IDS_DRIVER_ALSA "Controlador ALSA" IDS_DRIVER_ESOUND "Controlador EsounD" IDS_DRIVER_OSS "Controlador OSS" IDS_DRIVER_JACK "Controlador JACK" IDS_DRIVER_NAS "Controlador NAS" - IDS_DRIVER_AUDIOIO "Controlador ES de Áudio (Solaris)" + IDS_DRIVER_AUDIOIO "Controlador ES de �udio (Solaris)" IDS_DRIVER_COREAUDIO "Controlador CoreAudio" - IDS_OPEN_DRIVER_ERROR "Não é possível abrir %s!" + IDS_OPEN_DRIVER_ERROR "N�o � poss�vel abrir %s!" IDS_SOUNDDRIVERS "Controladores de Som" - IDS_DEVICES_WAVEOUT "Dispositivos de Saída Wave" + IDS_DEVICES_WAVEOUT "Dispositivos de Sa�da Wave" IDS_DEVICES_WAVEIN "Dispositivos de Entrada Wave" - IDS_DEVICES_MIDIOUT "Dispositivos de Saída MIDI" + IDS_DEVICES_MIDIOUT "Dispositivos de Sa�da MIDI" IDS_DEVICES_MIDIIN "Dispositivos de Entrada MIDI" IDS_DEVICES_AUX "Dispositivos Auxiliares" IDS_DEVICES_MIXER "Dispositivos Misturadores" - IDS_UNAVAILABLE_DRIVER "Encontrou-se um controlador no registo que não está disponível!\n\nRemover ?%s? do registo?" + IDS_UNAVAILABLE_DRIVER "Encontrou-se um controlador no registo que n�o est� dispon�vel!\n\nRemover ?%s? do registo?" IDS_WARNING "Aviso" END @@ -498,20 +492,20 @@ STRINGTABLE DISCARDABLE BEGIN IDC_SYSPARAMS_BUTTON "Fundo dos Controlos" IDC_SYSPARAMS_BUTTON_TEXT "Texto dos Controlos" - IDC_SYSPARAMS_DESKTOP "Ecrã" + IDC_SYSPARAMS_DESKTOP "Ecr�" IDC_SYSPARAMS_MENU "Fundo do Menu" IDC_SYSPARAMS_MENU_TEXT "Texto do Menu" IDC_SYSPARAMS_SCROLLBAR "Barra de Rolagem" - IDC_SYSPARAMS_SELECTION "Fundo de Selecção" - IDC_SYSPARAMS_SELECTION_TEXT "Texto de Selecção" + IDC_SYSPARAMS_SELECTION "Fundo de Selec��o" + IDC_SYSPARAMS_SELECTION_TEXT "Texto de Selec��o" IDC_SYSPARAMS_TOOLTIP "Fundo das Dicas" IDC_SYSPARAMS_TOOLTIP_TEXT "Texto das Dicas" IDC_SYSPARAMS_WINDOW "Fundo das Janelas" IDC_SYSPARAMS_WINDOW_TEXT "Texto das Janelas" - IDC_SYSPARAMS_ACTIVE_TITLE "Barra de Título Activa" - IDC_SYSPARAMS_ACTIVE_TITLE_TEXT "Texto de Título Activo" - IDC_SYSPARAMS_INACTIVE_TITLE "Barra de Título Inactiva" - IDC_SYSPARAMS_INACTIVE_TITLE_TEXT "Texto de Título Inactivo" + IDC_SYSPARAMS_ACTIVE_TITLE "Barra de T�tulo Activa" + IDC_SYSPARAMS_ACTIVE_TITLE_TEXT "Texto de T�tulo Activo" + IDC_SYSPARAMS_INACTIVE_TITLE "Barra de T�tulo Inactiva" + IDC_SYSPARAMS_INACTIVE_TITLE_TEXT "Texto de T�tulo Inactivo" IDC_SYSPARAMS_MSGBOX_TEXT "Texto da Caixa de Mensagem" IDC_SYSPARAMS_APPWORKSPACE "Application Workspace" IDC_SYSPARAMS_WINDOW_FRAME "Window Frame" diff --git a/programs/winecfg/Ro.rc b/programs/winecfg/Ro.rc index 50317bf9872..31a688981a7 100644 --- a/programs/winecfg/Ro.rc +++ b/programs/winecfg/Ro.rc @@ -20,9 +20,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -44,10 +41,10 @@ BEGIN LTEXT "http://www.winehq.org/",IDC_STATIC,119,31,106,8 LTEXT "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.", IDC_STATIC,119,44,124,72 - GROUPBOX " Informații de înregistrare Windows ", IDC_STATIC, 15, 110, 230, 55 - LTEXT "&Deținătorul:", IDC_STATIC, 22, 126, 40, 20 + GROUPBOX " Windows Registration Information ", IDC_STATIC, 15, 110, 230, 55 + LTEXT "Owner:", IDC_STATIC, 22, 126, 40, 20 + LTEXT "Organization:", IDC_STATIC, 22, 140, 50, 20 EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "Organi&zația:", IDC_STATIC, 22, 140, 50, 20 EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END @@ -71,22 +68,22 @@ STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN GROUPBOX " Setări de fereastră ",IDC_STATIC,8,4,244,84 - CONTROL "Permite aplicațiilor DirectX să rețină &mouse-ul în ferestră",IDC_DX_MOUSE_GRAB,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,20,230,8 - CONTROL "Permite administratorului de ferestre să &decoreze ferestrele",IDC_ENABLE_DECORATED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,32,230,8 - CONTROL "Permite administratorului de ferestre să &administreze ferestrele",IDC_ENABLE_MANAGED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,44,230,8 - CONTROL "&Emulează un ecran virtual",IDC_ENABLE_DESKTOP,"Button", + CONTROL "Permite aplicațiilor DirectX să rețină mouse-ul în ferestră",IDC_DX_MOUSE_GRAB,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,20,230,8 + CONTROL "Permite administratorul de ferestre să &decoreze ferestrele",IDC_ENABLE_DECORATED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,32,230,8 + CONTROL "Permite &administratorul de ferestre să administreze ferestrele",IDC_ENABLE_MANAGED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,44,230,8 + CONTROL "Emulează un ecran virtual",IDC_ENABLE_DESKTOP,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,15,56,230,8 - LTEXT "Mărime ecran:",IDC_DESKTOP_SIZE,15,70,49,8,WS_DISABLED + LTEXT "Mărime ecran:",IDC_DESKTOP_SIZE,15,70,44,8,WS_DISABLED LTEXT "X",IDC_DESKTOP_BY,109,70,8,8,WS_DISABLED EDITTEXT IDC_DESKTOP_WIDTH,64,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED EDITTEXT IDC_DESKTOP_HEIGHT,117,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED GROUPBOX " Direct3D ",IDC_STATIC,8,95,244,49 - LTEXT "Suport de vertex shader: ",IDC_STATIC,15,110,90,32 + LTEXT "Suport pentru vertex shader: ",IDC_STATIC,15,110,80,32 COMBOBOX IDC_D3D_VSHADER_MODE,100,108,145,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP CONTROL "Permite pixel shader (dacă este oferit de hardware)",IDC_D3D_PSHADER_MODE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,126,230,10 - GROUPBOX " Rezoluție ecran ",IDC_STATIC,8,151,244,93 + GROUPBOX " Resoluție ecran ",IDC_STATIC,8,151,244,93 CONTROL "", IDC_RES_TRACKBAR, "msctls_trackbar32",WS_TABSTOP,12,161,187,15 EDITTEXT IDC_RES_DPIEDIT,204,161,23,13,ES_NUMBER|WS_TABSTOP LTEXT "dpi",IDC_STATIC,235,163,10,8 @@ -97,7 +94,7 @@ IDD_DLLCFG DIALOG DISCARDABLE 0, 0, 260, 250 STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX " Suprascrieri DLL ",IDC_STATIC,8,4,244,240 + GROUPBOX " Suprascieri DLL ",IDC_STATIC,8,4,244,240 LTEXT "DLL-urile (Dynamic Link Libraries) pot fi setate individual ca builtin (furnizate de Wine) sau native (din Windows sau furnizate de aplicație)." ,IDC_STATIC,16,16,220,32 LTEXT "Suprascriere nouă pentru librăria:",IDC_STATIC,16,58,100,8 @@ -129,7 +126,7 @@ STYLE WS_CHILD | WS_DISABLED FONT 8, "MS Shell Dlg" BEGIN GROUPBOX " Mapare de discuri ",IDC_STATIC,8,4,244,240 - LTEXT "A eșuat conectarea la managerul de montare, configurația discurilor nu poate fi schimbată.", IDC_STATIC_MOUNTMGR_ERROR, 15,30,220,76 + LTEXT "Failed to connect to the mount manager, the drive configuration cannot be edited.", IDC_STATIC_MOUNTMGR_ERROR, 15,30,220,76 CONTROL "Listview",IDC_LIST_DRIVES,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,18,232,76 PUSHBUTTON "&Adaugă",IDC_BUTTON_ADD,15,98,37,14 @@ -139,27 +136,27 @@ BEGIN /* editing drive details */ LTEXT "&Calea:",IDC_STATIC_PATH,15,123,20,9 EDITTEXT IDC_EDIT_PATH,41,120,160,13,ES_AUTOHSCROLL | WS_TABSTOP - PUSHBUTTON "&Navighează",IDC_BUTTON_BROWSE_PATH,206,120,40,13 + PUSHBUTTON "&Navigează",IDC_BUTTON_BROWSE_PATH,206,120,40,13 LTEXT "&Tipul:",IDC_STATIC_TYPE,15,138,21,10 COMBOBOX IDC_COMBO_TYPE,41,135,82,60,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP LTEXT "Eticheta și numărul de serie",IDC_LABELSERIAL_STATIC,15,155,95,10 - PUSHBUTTON "Afișează opțiunile a&vansate",IDC_BUTTON_SHOW_HIDE_ADVANCED,151,136,95,15 - CONTROL "Detectează automat de la dispozitiv:",IDC_RADIO_AUTODETECT,"Button", + PUSHBUTTON "Afișează opțiunile avan&sate",IDC_BUTTON_SHOW_HIDE_ADVANCED,151,136,95,15 + CONTROL "Detectează automat de la dizpozitiv:",IDC_RADIO_AUTODETECT,"Button", BS_AUTORADIOBUTTON,15,166,128,10 EDITTEXT IDC_EDIT_DEVICE,27,176,174,13,ES_AUTOHSCROLL - PUSHBUTTON "Navighează",IDC_BUTTON_BROWSE_DEVICE,206,176,40,13 + PUSHBUTTON "Na&vigează",IDC_BUTTON_BROWSE_DEVICE,206,176,40,13 CONTROL "Asociază &manual:",IDC_RADIO_ASSIGN,"Button", BS_AUTORADIOBUTTON,15,195,69,10 LTEXT "&Etichetă:",IDC_STATIC_LABEL,33,208,29,12 EDITTEXT IDC_EDIT_LABEL,63,205,78,13,ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "N&umăr de serie:",IDC_STATIC_SERIAL,33,219,29,15 + LTEXT "Număr de s&erie:",IDC_STATIC_SERIAL,33,219,29,15 EDITTEXT IDC_EDIT_SERIAL,63,221,78,13,ES_AUTOHSCROLL | WS_TABSTOP - CONTROL "Afișează &fișierele ascunse",IDC_SHOW_DOT_FILES,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,8,260,230,8 + CONTROL "Afișează fișierele ascunse",IDC_SHOW_DOT_FILES,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,8,260,230,8 END IDD_AUDIOCFG DIALOG DISCARDABLE 0, 0, 260, 250 @@ -170,15 +167,15 @@ BEGIN LTEXT "Alegeți un driver de sunet prin bifarea căsuței corespunzătoare. Sunetul este dezactivat dacă nu alegeți un driver. Selecționarea mai multor drivere nu este recomandată. Configurați un driver cu un clic dreapta pe el.",IDC_STATIC,15,20,227,30 CONTROL "Dispozitive",IDC_AUDIO_TREE,"SysTreeView32",WS_BORDER | WS_TABSTOP,15,50,140,140 PUSHBUTTON "&Testează sunetul",IDC_AUDIO_TEST,170,50,59,14 - PUSHBUTTON "Panou de &control",IDC_AUDIO_CONTROL_PANEL,170,70,59,14 + PUSHBUTTON "Panou de control",IDC_AUDIO_CONTROL_PANEL,170,70,59,14 GROUPBOX " DirectSound ",IDC_STATIC,8,205,244,60 - LTEXT "Accelerație &hardware: ",IDC_STATIC,15,215,90,10 + LTEXT "Accelerație hardware: ",IDC_STATIC,15,215,90,10 COMBOBOX IDC_DSOUND_HW_ACCEL,100,213,150,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "R&ata de eșantionare implicită:",IDC_STATIC,15,232,70,8 + LTEXT "Rata de eșantionare implicită:",IDC_STATIC,15,232,70,8 COMBOBOX IDC_DSOUND_RATES,90,230,42,76,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Nr. implicit &biți/eșantion:",IDC_STATIC,137,232,80,8 + LTEXT "Nr. implicit biți/eșantion:",IDC_STATIC,137,232,80,8 COMBOBOX IDC_DSOUND_BITS,220,230,30,56,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - CONTROL "&Emulare driver",IDC_DSOUND_DRV_EMUL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,250,230,10 + CONTROL "Emulare driver",IDC_DSOUND_DRV_EMUL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,250,230,10 END IDD_DESKTOP_INTEGRATION DIALOG DISCARDABLE 0, 0, 260, 250 @@ -188,7 +185,7 @@ BEGIN GROUPBOX " Aspect ",IDC_STATIC,8,4,244,106 LTEXT "Tematică:",IDC_STATIC,15,16,130,8 COMBOBOX IDC_THEME_THEMECOMBO,15,24,130,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "Instalează o tematică",IDC_THEME_INSTALL,152,23,93,14 + PUSHBUTTON "Instalează tematica",IDC_THEME_INSTALL,152,23,93,14 LTEXT "Culoare:",IDC_THEME_COLORTEXT,15,40,112,8 COMBOBOX IDC_THEME_COLORCOMBO,15,48,112,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP LTEXT "Mărime:",IDC_THEME_SIZETEXT,135,40,110,8 @@ -201,22 +198,22 @@ BEGIN EDITTEXT IDC_SYSPARAM_SIZE,166,74,23,13,ES_AUTOHSCROLL | WS_TABSTOP | WS_DISABLED CONTROL "",IDC_SYSPARAM_SIZE_UD,UPDOWN_CLASS,UDS_SETBUDDYINT | WS_DISABLED,187,74,15,13 PUSHBUTTON "Font",IDC_SYSPARAM_FONT,208,74,37,13,WS_DISABLED - GROUPBOX " Dosare sistem ",IDC_STATIC,8,114,244,100 + GROUPBOX " Shell Folder ",IDC_STATIC,8,114,244,100 CONTROL "Listview",IDC_LIST_SFPATHS,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,126,230,64 - CONTROL "Leagă la:",IDC_LINK_SFPATH,"Button",BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED,15,195,40,13 - EDITTEXT IDC_EDIT_SFPATH,60,195,135,13,ES_AUTOHSCROLL|WS_TABSTOP|WS_DISABLED - PUSHBUTTON "&Navighează",IDC_BROWSE_SFPATH,205,195,40,13,WS_DISABLED + CONTROL "Leagă la:",IDC_LINK_SFPATH,"Button",BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED,15,195,50,13 + EDITTEXT IDC_EDIT_SFPATH,65,195,145,13,ES_AUTOHSCROLL|WS_TABSTOP|WS_DISABLED + PUSHBUTTON "Navigează",IDC_BROWSE_SFPATH,215,195,30,13,WS_DISABLED END STRINGTABLE DISCARDABLE BEGIN IDS_TAB_APPLICATIONS "Aplicații" IDS_TAB_DLLS "Librării" - IDS_TAB_DRIVES "Dispozitive" - IDS_CHOOSE_PATH "Selectați vă rog dosarul unix destinație." - IDS_HIDE_ADVANCED "Ascunde opțiunile a&vansate" - IDS_SHOW_ADVANCED "Afișează opțiunile a&vansate" + IDS_TAB_DRIVES "Dizpozitive" + IDS_CHOOSE_PATH "Select the unix target directory, please." + IDS_HIDE_ADVANCED "Ascunde opțiunile avansate" + IDS_SHOW_ADVANCED "Afișează opțiunile avansate" IDS_NOTHEME "(Fără tematică)" IDS_TAB_GRAPHICS "Grafică" IDS_TAB_DESKTOP_INTEGRATION "Integrare ecran" @@ -226,7 +223,7 @@ BEGIN IDS_WINECFG_TITLE_APP "Setări Wine pentru %s" IDS_THEMEFILE "Fișere de tematică" IDS_THEMEFILE_SELECT "Selectează un fișier de tematică" - IDS_AUDIO_MISSING "Nici un driver audio nu este specificat în registru.\n\nUn driver recomandat a fost ales pentru D-voastră.\nPuteți folosi acest driver ori alegeți un alt driver disponibil.\n\nDați clic pe OK ca să activați setarea." + IDS_AUDIO_MISSING "Un driver audio nu este specificat în registru.\n\nUn driver recomandat a fost ales pentru D-voastră.\nPuteți folosi acest driver ori alegeți un alt driver disponibil.\n\nDați clic pe OK ca să activați setarea." IDS_SHELL_FOLDER "Dosarul de sistem" IDS_LINKS_TO "Legat la" END @@ -255,7 +252,7 @@ END STRINGTABLE DISCARDABLE BEGIN IDS_DRIVE_UNKNOWN "Detectează automat" - IDS_DRIVE_FIXED "Hard disk local" + IDS_DRIVE_FIXED "Hard disk-ul local" IDS_DRIVE_REMOTE "Resursă din rețea" IDS_DRIVE_REMOVABLE "Dischetă" IDS_DRIVE_CDROM "CD-ROM" @@ -269,7 +266,7 @@ END STRINGTABLE DISCARDABLE BEGIN - IDS_ACCEL_FULL "Completă" + IDS_ACCEL_FULL "Complet" IDS_ACCEL_STANDARD "Standard" IDS_ACCEL_BASIC "De bază" IDS_ACCEL_EMULATION "Emulare" @@ -311,8 +308,8 @@ BEGIN IDC_SYSPARAMS_ACTIVE_TITLE_TEXT "Text bară de titlu activă" IDC_SYSPARAMS_INACTIVE_TITLE "Bară de titlu inactivă" IDC_SYSPARAMS_INACTIVE_TITLE_TEXT "Text bară de titlu inactivă" - IDC_SYSPARAMS_MSGBOX_TEXT "Text casetă de mesaje" - IDC_SYSPARAMS_APPWORKSPACE "Spațiul de lucru al aplicației" + IDC_SYSPARAMS_MSGBOX_TEXT "Text MessageBox" + IDC_SYSPARAMS_APPWORKSPACE "Spațiu de lucru al aplicației" IDC_SYSPARAMS_WINDOW_FRAME "Cadru de fereastră" IDC_SYSPARAMS_ACTIVE_BORDER "Margini active" IDC_SYSPARAMS_INACTIVE_BORDER "Margini inactive" @@ -328,3 +325,5 @@ BEGIN IDC_SYSPARAMS_MENU_HILIGHT "Evidențiere meniu" IDC_SYSPARAMS_MENUBAR "Bară de meniu" END + +#pragma code_page(default) diff --git a/programs/winecfg/Ru.rc b/programs/winecfg/Ru.rc dissimilarity index 70% index 7112a13b13c..462cf8ec641 100644 --- a/programs/winecfg/Ru.rc +++ b/programs/winecfg/Ru.rc @@ -1,335 +1,329 @@ -/* - * WineCfg resources - * Russian Language Support - * - * Copyright 2003 Igor Stepin - * Copyright 2006 Vitaliy Margolen - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - * - */ - -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT - -IDR_WINECFG MENU DISCARDABLE -BEGIN - POPUP "" - BEGIN - MENUITEM "Настроить", IDC_AUDIO_CONFIGURE - END -END - -IDD_ABOUTCFG DIALOGEX 0, 0, 260, 270 -STYLE WS_CHILD -FONT 8, "MS Shell Dlg" -BEGIN - LTEXT PACKAGE_STRING,IDC_STATIC,119,17,120,8 - CONTROL IDB_WINE,IDC_STATIC,"Static",SS_BITMAP ,15,17,157,111 - LTEXT "http://www.winehq.org/",IDC_STATIC,119,31,106,8 -/* - LTEXT "Эта библиотека является свободным программным обеспечением; вы можете распространять её и/или модифицировать согласно условиям лицензии GNU Lesser General Public License, опубликованной Free Software Foundation; версии 2.1 лицензии или (на ваше усмотрение) любой более поздней.", -*/ - LTEXT "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.", - IDC_STATIC,119,44,124,72 - GROUPBOX " Регистрационная информация Windows ", IDC_STATIC, 15, 110, 230, 55 - LTEXT "Имя:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "Организация:", IDC_STATIC, 22, 140, 50, 20 - EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP -END - -IDD_APPCFG DIALOG DISCARDABLE 0, 0, 260, 250 -STYLE WS_CHILD | WS_DISABLED -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Настройка приложений ",IDC_STATIC, 8,4,244,240 - LTEXT "Wine может имитировать любую версию Windows для каждого приложения. Эта вкладка связана с вкладками Библиотеки и Графика, что позволяет изменение настроек в этих вкладках как для определённого приложения, так и глобально.", - IDC_STATIC,15,20,227,60 - CONTROL "Приложения",IDC_APP_LISTVIEW,"SysListView32",WS_BORDER | WS_TABSTOP | LVS_LIST | LVS_SINGLESEL | LVS_SHOWSELALWAYS, - 15,65,230,134 - PUSHBUTTON "&Добавить приложение...",IDC_APP_ADDAPP, 68,204,94,14 - PUSHBUTTON "&Удалить приложение",IDC_APP_REMOVEAPP, 164,204,78,14 - LTEXT "&Версия Windows:",IDC_STATIC,17,226,58,8 - COMBOBOX IDC_WINVER,83,224,163,56,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP -END - -IDD_GRAPHCFG DIALOG DISCARDABLE 0, 0, 260, 250 -STYLE WS_CHILD | WS_DISABLED -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Настройки окна ",IDC_STATIC,8,4,244,84 - CONTROL "Разрешить приложению DirectX удерживать мышь в своём окне",IDC_DX_MOUSE_GRAB,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,20,230,8 - CONTROL "Разрешить менеджеру окон &декорировать окна",IDC_ENABLE_DECORATED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,32,230,8 - CONTROL "Разрешить менеджеру окон управлять окнами Wine",IDC_ENABLE_MANAGED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,44,230,8 - CONTROL "Эмулировать виртуальный рабочий стол",IDC_ENABLE_DESKTOP,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,15,56,230,8 - LTEXT "Размер рабочего стола:",IDC_DESKTOP_SIZE,15,70,84,8,WS_DISABLED - LTEXT "X",IDC_DESKTOP_BY,149,70,8,8,WS_DISABLED - EDITTEXT IDC_DESKTOP_WIDTH,104,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED - EDITTEXT IDC_DESKTOP_HEIGHT,157,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED - - GROUPBOX " Direct3D ",IDC_STATIC,8,95,244,49 - LTEXT "Вершинные шейдеры: ",IDC_STATIC,15,110,80,32 - COMBOBOX IDC_D3D_VSHADER_MODE,100,108,145,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - CONTROL "Включить Pixel Shader (если поддерживается оборудованием)",IDC_D3D_PSHADER_MODE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,126,230,10 - - GROUPBOX " Разрешение экрана ",IDC_STATIC,8,151,244,93 - CONTROL "", IDC_RES_TRACKBAR, "msctls_trackbar32",WS_TABSTOP,12,161,187,15 - EDITTEXT IDC_RES_DPIEDIT,204,161,23,13,ES_NUMBER|WS_TABSTOP - LTEXT "dpi",IDC_STATIC,235,163,10,8 - LTEXT "This is a sample text using 10 point Tahoma",IDC_RES_FONT_PREVIEW,15,181,230,55 -END - -IDD_DLLCFG DIALOG DISCARDABLE 0, 0, 260, 250 -STYLE WS_CHILD | WS_DISABLED -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Замещения DLL ",IDC_STATIC,8,4,244,240 - LTEXT "Здесь указывается, какую динамически подключаемую библиотеку (DLL) использовать: встроенную в Wine или стороннюю (из Windows)." - ,IDC_STATIC,16,16,220,32 - LTEXT "Новое замещение для библиотеки:",IDC_STATIC,16,58,160,8 - COMBOBOX IDC_DLLCOMBO,16,68,140,14,CBS_DROPDOWN | WS_VSCROLL | WS_TABSTOP | CBS_SORT | CBS_LOWERCASE - PUSHBUTTON "&Добавить",IDC_DLLS_ADDDLL, 164,68,82,13,BS_DEFPUSHBUTTON - LTEXT "Существующие замещения:",IDC_STATIC,16,86,100,8 - LISTBOX IDC_DLLS_LIST,16,96,140,140,WS_BORDER | WS_TABSTOP | WS_VSCROLL - PUSHBUTTON "&Редактировать",IDC_DLLS_EDITDLL,164,96,82,14 - PUSHBUTTON "&Удалить",IDC_DLLS_REMOVEDLL,164,114,82,14 -END - -IDD_LOADORDER DIALOG DISCARDABLE 80, 90, 150, 92 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Редактировать замещение" -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Порядок загрузки ",IDC_STATIC,8,4,135,66 - CONTROL "&Встроенная (Wine)",IDC_RAD_BUILTIN,"Button", BS_AUTORADIOBUTTON | WS_GROUP,16,14,105,10 - CONTROL "С&торонняя (Windows)",IDC_RAD_NATIVE,"Button", BS_AUTORADIOBUTTON,16,24,105,10 - CONTROL "В&строенная, затем сторонняя",IDC_RAD_BUILTIN_NATIVE,"Button", BS_AUTORADIOBUTTON,16,34,115,10 - CONTROL "Ст&оронняя, затем встроенная",IDC_RAD_NATIVE_BUILTIN,"Button", BS_AUTORADIOBUTTON,16,44,115,10 - CONTROL "&Блокировать",IDC_RAD_DISABLE,"Button", BS_AUTORADIOBUTTON,16,54,105,10 - DEFPUSHBUTTON "OK",IDOK,8,74,45,14,WS_GROUP - PUSHBUTTON "Отмена",IDCANCEL,57,74,45,14,WS_GROUP -END - -IDD_DRIVECFG DIALOG DISCARDABLE 0, 0, 260, 250 -STYLE WS_CHILD | WS_DISABLED -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Настройка дисков ",IDC_STATIC,8,4,244,240 - LTEXT "Невозможно соединиться с mount manager! Конфигурация дисков не будет редактироваться.", IDC_STATIC_MOUNTMGR_ERROR, 15,30,220,76 - CONTROL "Listview",IDC_LIST_DRIVES,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | - LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,18,232,76 - PUSHBUTTON "&Добавить...",IDC_BUTTON_ADD,15,98,45,14 - PUSHBUTTON "&Удалить",IDC_BUTTON_REMOVE,66,98,47,14 - PUSHBUTTON "&Автоопределение...",IDC_BUTTON_AUTODETECT,165,98,80,14 - - /* editing drive details */ - LTEXT "&Путь:",IDC_STATIC_PATH,15,123,20,9 - EDITTEXT IDC_EDIT_PATH,41,120,160,13,ES_AUTOHSCROLL | WS_TABSTOP - PUSHBUTTON "&Обзор...",IDC_BUTTON_BROWSE_PATH,206,120,40,13 - - LTEXT "&Тип:",IDC_STATIC_TYPE,15,138,21,10 - COMBOBOX IDC_COMBO_TYPE,41,135,77,60,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - - LTEXT "Метка и серийный номер",IDC_LABELSERIAL_STATIC,15,155,95,10 - - PUSHBUTTON "Дополнительно...",IDC_BUTTON_SHOW_HIDE_ADVANCED,150,136,96,13 - CONTROL "Автоопределить &c устройства:",IDC_RADIO_AUTODETECT,"Button", - BS_AUTORADIOBUTTON,15,166,150,10 - EDITTEXT IDC_EDIT_DEVICE,27,176,174,13,ES_AUTOHSCROLL - PUSHBUTTON "Об&зор...",IDC_BUTTON_BROWSE_DEVICE,206,176,40,13 - CONTROL "&Назначить вручную:",IDC_RADIO_ASSIGN,"Button", - BS_AUTORADIOBUTTON,15,195,100,10 - - LTEXT "&Метка:",IDC_STATIC_LABEL,33,208,29,12 - EDITTEXT IDC_EDIT_LABEL,103,205,118,13,ES_AUTOHSCROLL | WS_TABSTOP - LTEXT "Серийный номер:",IDC_STATIC_SERIAL,33,225,80,12 - EDITTEXT IDC_EDIT_SERIAL,103,221,118,13,ES_AUTOHSCROLL | WS_TABSTOP - - CONTROL "Показывать файлы, начинающиеся с точки",IDC_SHOW_DOT_FILES,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,8,260,230,8 -END - -IDD_AUDIOCFG DIALOG DISCARDABLE 0, 0, 260, 250 -STYLE WS_CHILD | WS_DISABLED -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Выбор драйвера ",IDC_STATIC,8,4,244,195 - LTEXT "Звуковой драйвер: ",IDC_STATIC,15,20,227,30 - CONTROL "Devices",IDC_AUDIO_TREE,"SysTreeView32",WS_BORDER | WS_TABSTOP,15,50,140,140 - PUSHBUTTON "&Проверить звук",IDC_AUDIO_TEST,170,50,59,14 - PUSHBUTTON "Панель управления",IDC_AUDIO_CONTROL_PANEL,170,70,80,14 - GROUPBOX " DirectSound ",IDC_STATIC,8,205,244,60 - LTEXT "Аппаратное ускорение: ",IDC_STATIC,15,215,90,10 - COMBOBOX IDC_DSOUND_HW_ACCEL,100,213,145,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Частота (герц):",IDC_STATIC,15,232,70,8 - COMBOBOX IDC_DSOUND_RATES,100,230,42,76,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Кодирование (бит):",IDC_STATIC,144,232,80,8 - COMBOBOX IDC_DSOUND_BITS,216,230,30,52,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - CONTROL "Эмуляция драйвера",IDC_DSOUND_DRV_EMUL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,250,230,10 -END - -IDD_DESKTOP_INTEGRATION DIALOG DISCARDABLE 0, 0, 260, 250 -STYLE WS_CHILD | WS_DISABLED -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX " Внешний вид ",IDC_STATIC,8,4,244,106 - LTEXT "Тема:",IDC_STATIC,15,16,130,8 - COMBOBOX IDC_THEME_THEMECOMBO,15,24,130,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "Установить тему...",IDC_THEME_INSTALL,152,23,93,14 - LTEXT "Цвет:",IDC_THEME_COLORTEXT,15,40,112,8 - COMBOBOX IDC_THEME_COLORCOMBO,15,48,112,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Размер:",IDC_THEME_SIZETEXT,135,40,110,8 - COMBOBOX IDC_THEME_SIZECOMBO,135,48,110,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - LTEXT "Элемент:",IDC_STATIC,15,64,112,8 - COMBOBOX IDC_SYSPARAM_COMBO,15,74,112,120,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP | CBS_SORT - LTEXT "Цвет:",IDC_SYSPARAM_COLOR_TEXT,135,64,25,8,WS_DISABLED - PUSHBUTTON "",IDC_SYSPARAM_COLOR,135,74,25,13,WS_DISABLED | BS_OWNERDRAW - LTEXT "Размер:",IDC_SYSPARAM_SIZE_TEXT,166,64,30,8,WS_DISABLED - EDITTEXT IDC_SYSPARAM_SIZE,166,74,23,13,ES_AUTOHSCROLL | WS_TABSTOP | WS_DISABLED - CONTROL "",IDC_SYSPARAM_SIZE_UD,UPDOWN_CLASS,UDS_SETBUDDYINT | WS_DISABLED,187,74,15,13 - PUSHBUTTON "Шрифт",IDC_SYSPARAM_FONT,208,74,37,13,WS_DISABLED - GROUPBOX " Стандартные папки ",IDC_STATIC,8,114,244,100 - CONTROL "Listview",IDC_LIST_SFPATHS,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | - LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,126,230,64 - CONTROL "Направить в:",IDC_LINK_SFPATH,"Button",BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED,15,195,50,13 - EDITTEXT IDC_EDIT_SFPATH,65,195,145,13,ES_AUTOHSCROLL|WS_TABSTOP|WS_DISABLED - PUSHBUTTON "Обзор",IDC_BROWSE_SFPATH,215,195,30,13,WS_DISABLED -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_TAB_APPLICATIONS "Приложения" - IDS_TAB_DLLS "Библиотеки" - IDS_TAB_DRIVES "Диски" - IDS_CHOOSE_PATH "Выберите целевой каталог в системе:" - IDS_HIDE_ADVANCED "Скрыть дополнительные" - IDS_SHOW_ADVANCED "Показать дополнительные" - IDS_NOTHEME "(без темы)" - IDS_TAB_GRAPHICS "Графика" - IDS_TAB_DESKTOP_INTEGRATION "Вид и интеграция" - IDS_TAB_AUDIO "Аудио" - IDS_TAB_ABOUT "О программе" - IDS_WINECFG_TITLE "Настройка Wine" - IDS_WINECFG_TITLE_APP "Настройка Wine для %s" - IDS_THEMEFILE "Файлы тем" - IDS_THEMEFILE_SELECT "Выберите файл с темой" - IDS_AUDIO_MISSING "Конфигурация звукового драйвера не найдена.\n\nВыбран драйвер по умолчанию. При необходимости можно выбрать другой драйвер из списка доступных.\n\nДля сохранения изменений нажмите кнопку Применить." - IDS_SHELL_FOLDER "Стандартные папки" - IDS_LINKS_TO "Связано с" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_DLL_WARNING "Изменение порядка загрузки этой библиотеки не рекомендуется.\nВы действительно хотите изменить порядок?" - IDS_DLL_WARNING_CAPTION "Внимание: системная библиотека" - IDS_DLL_NATIVE "сторонняя" - IDS_DLL_BUILTIN "встроенная" - IDS_DLL_NATIVE_BUILTIN "сторонняя, встроенная" - IDS_DLL_BUILTIN_NATIVE "встроенная, сторонняя" - IDS_DLL_DISABLED "отключена" - IDS_DEFAULT_SETTINGS "Установки по умолчанию" - IDS_EXECUTABLE_FILTER "Программы Wine (*.exe,*.exe.so)\0*.exe;*.exe.so\0" - IDS_USE_GLOBAL_SETTINGS "Использовать по умолчанию" - IDS_SELECT_EXECUTABLE "Выберите исполняемый файл" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_SHADER_MODE_HARDWARE "Включены" - IDS_SHADER_MODE_NONE "Выключены" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_DRIVE_UNKNOWN "Автоопределение" - IDS_DRIVE_FIXED "Жёсткий диск" - IDS_DRIVE_REMOTE "Сетевой диск" - IDS_DRIVE_REMOVABLE "Дисковод" - IDS_DRIVE_CDROM "CD-ROM" - IDS_DRIVE_LETTERS_EXCEEDED "Невозможно создать новый диск.\n\nУ каждого диска должна быть буква - от A до Z, и у Вас уже 26 дисков." - IDS_SYSTEM_DRIVE_LABEL "Системный диск" - IDS_CONFIRM_DELETE_C "Действительно удалить диск C?\n\nБольшинство Windows-программ перестанут работать без диска C. Если Вы всё же решили удалить диск, не забудьте создать новый!" - IDS_COL_DRIVELETTER "Диск" - IDS_COL_DRIVEMAPPING "Путь" - IDS_NO_DRIVE_C "Вы не назначили диск C.\n\nНе забудьте его создать!\n" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDS_ACCEL_FULL "Полное" - IDS_ACCEL_STANDARD "Стандартное" - IDS_ACCEL_BASIC "Минимальное" - IDS_ACCEL_EMULATION "Эмуляция" - IDS_DRIVER_PULSE "PulseAudio драйвер" - IDS_DRIVER_ALSA "ALSA драйвер" - IDS_DRIVER_ESOUND "EsounD драйвер" - IDS_DRIVER_OSS "OSS драйвер" - IDS_DRIVER_JACK "JACK драйвер" - IDS_DRIVER_NAS "NAS драйвер" - IDS_DRIVER_AUDIOIO "Audio IO (Solaris) драйвер" - IDS_DRIVER_COREAUDIO "CoreAudio драйвер" - IDS_OPEN_DRIVER_ERROR "Невозможно открыть %s!" - IDS_SOUNDDRIVERS "Аудио драйвера" - IDS_DEVICES_WAVEOUT "Устройство вывода звука" - IDS_DEVICES_WAVEIN "Устройство ввода звука" - IDS_DEVICES_MIDIOUT "Устройство вывода MIDI" - IDS_DEVICES_MIDIIN "Устройство ввода MIDI" - IDS_DEVICES_AUX "Дополнительное устройство" - IDS_DEVICES_MIXER "Устройство микширования" - IDS_UNAVAILABLE_DRIVER "Драйвер, указанный в реестре, не найден!\n\nУдалить \"%s\" из реестра?" - IDS_WARNING "Внимание" -END - -STRINGTABLE DISCARDABLE -BEGIN - IDC_SYSPARAMS_BUTTON "Элементы управления - фон" - IDC_SYSPARAMS_BUTTON_TEXT "Элементы управления - текст" - IDC_SYSPARAMS_DESKTOP "Стол" - IDC_SYSPARAMS_MENU "Меню - фон" - IDC_SYSPARAMS_MENU_TEXT "Меню - текст" - IDC_SYSPARAMS_SCROLLBAR "Полоса прокрутки" - IDC_SYSPARAMS_SELECTION "Выделение - фон" - IDC_SYSPARAMS_SELECTION_TEXT "Выделение - текст" - IDC_SYSPARAMS_TOOLTIP "Подсказка - фон" - IDC_SYSPARAMS_TOOLTIP_TEXT "Подсказка - текст" - IDC_SYSPARAMS_WINDOW "Содержимое окна - фон" - IDC_SYSPARAMS_WINDOW_TEXT "Содержимое окна - текст" - IDC_SYSPARAMS_ACTIVE_TITLE "Активное окно" - IDC_SYSPARAMS_ACTIVE_TITLE_TEXT "Активное окно - текст" - IDC_SYSPARAMS_INACTIVE_TITLE "Пассивное окно" - IDC_SYSPARAMS_INACTIVE_TITLE_TEXT "Пассивное окно - текст" - IDC_SYSPARAMS_MSGBOX_TEXT "Окно сообщения - текст" - IDC_SYSPARAMS_APPWORKSPACE "Содержимое окна MDI - фон" - IDC_SYSPARAMS_WINDOW_FRAME "Окно - рамка" - IDC_SYSPARAMS_ACTIVE_BORDER "Активное окно - рамка" - IDC_SYSPARAMS_INACTIVE_BORDER "Пассивное окно - рамка" - IDC_SYSPARAMS_BUTTON_SHADOW "Элементы управления - тень" - IDC_SYSPARAMS_GRAY_TEXT "Недоступный элемент" - IDC_SYSPARAMS_BUTTON_HILIGHT "Элементы управления - светлая рамка" - IDC_SYSPARAMS_BUTTON_DARK_SHADOW "Элементы управления - темная тень" - IDC_SYSPARAMS_BUTTON_LIGHT "Элементы управления - свет" - IDC_SYSPARAMS_BUTTON_ALTERNATE "Элементы управления - фон 2" - IDC_SYSPARAMS_HOT_TRACKING "Ссылка, Подсветка" - IDC_SYSPARAMS_ACTIVE_TITLE_GRADIENT "Градиент активного окна" - IDC_SYSPARAMS_INACTIVE_TITLE_GRADIENT "Градиент пассивного окна" - IDC_SYSPARAMS_MENU_HILIGHT "Плоское меню - подсветка" - IDC_SYSPARAMS_MENUBAR "Плоское меню - фон" -END +/* + * WineCfg resources + * Russian Language Support + * + * Copyright 2003 Igor Stepin + * Copyright 2006 Vitaliy Margolen + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + * + */ + +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT + +IDR_WINECFG MENU DISCARDABLE +BEGIN + POPUP "" + BEGIN + MENUITEM "Configure", IDC_AUDIO_CONFIGURE + END +END + +IDD_ABOUTCFG DIALOGEX 0, 0, 260, 270 +STYLE WS_CHILD +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT PACKAGE_STRING,IDC_STATIC,119,17,120,8 + CONTROL IDB_WINE,IDC_STATIC,"Static",SS_BITMAP ,15,17,157,111 + LTEXT "http://www.winehq.org/",IDC_STATIC,119,31,106,8 +/* + LTEXT "��� ���������� �������� ��������� ����������� ������������; �� ������ �������������� �� �/��� �������������� �������� �������� �������� GNU Lesser General Public License, �������������� Free Software Foundation; ������ 2.1 �������� ��� (�� ���� ����������) ����� ����� �������.", +*/ + LTEXT "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.", + IDC_STATIC,119,44,124,72 + GROUPBOX " ��������������� ���������� Windows ", IDC_STATIC, 15, 110, 230, 55 + LTEXT "���:", IDC_STATIC, 22, 126, 40, 20 + LTEXT "�����������:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP + EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP +END + +IDD_APPCFG DIALOG DISCARDABLE 0, 0, 260, 250 +STYLE WS_CHILD | WS_DISABLED +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " ��������� ���������� ",IDC_STATIC, 8,4,244,240 + LTEXT "Wine ����� ����������� ����� ������ Windows ��� ������� ����������. ��� ������� ������� � ��������� ���������� � �������, ��� ��������� ��������� �������� � ���� �������� ��� ��� ������������� ����������, ��� � ���������.", + IDC_STATIC,15,20,227,60 + CONTROL "����������",IDC_APP_LISTVIEW,"SysListView32",WS_BORDER | WS_TABSTOP | LVS_LIST | LVS_SINGLESEL | LVS_SHOWSELALWAYS, + 15,65,230,134 + PUSHBUTTON "&�������� ����������...",IDC_APP_ADDAPP, 68,204,94,14 + PUSHBUTTON "&������� ����������",IDC_APP_REMOVEAPP, 164,204,78,14 + LTEXT "&������ Windows:",IDC_STATIC,17,226,58,8 + COMBOBOX IDC_WINVER,83,224,163,56,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP +END + +IDD_GRAPHCFG DIALOG DISCARDABLE 0, 0, 260, 250 +STYLE WS_CHILD | WS_DISABLED +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " ��������� ���� ",IDC_STATIC,8,4,244,84 + CONTROL "��������� ���������� DirectX ���������� ���� � ����� ����",IDC_DX_MOUSE_GRAB,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,20,230,8 + CONTROL "��������� ��������� ���� &������������ ����",IDC_ENABLE_DECORATED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,32,230,8 + CONTROL "��������� ��������� ���� ��������� ������ Wine",IDC_ENABLE_MANAGED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,44,230,8 + CONTROL "����������� ����������� ������� ����",IDC_ENABLE_DESKTOP,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,15,56,230,8 + LTEXT "������ �������� �����:",IDC_DESKTOP_SIZE,15,70,84,8,WS_DISABLED + LTEXT "X",IDC_DESKTOP_BY,149,70,8,8,WS_DISABLED + EDITTEXT IDC_DESKTOP_WIDTH,104,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED + EDITTEXT IDC_DESKTOP_HEIGHT,157,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED + + GROUPBOX " Direct3D ",IDC_STATIC,8,95,244,49 + LTEXT "��������� �������: ",IDC_STATIC,15,110,80,32 + COMBOBOX IDC_D3D_VSHADER_MODE,100,108,145,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + CONTROL "�������� Pixel Shader (���� �������������� �������������)",IDC_D3D_PSHADER_MODE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,126,230,10 + + GROUPBOX " ���������� ������ ",IDC_STATIC,8,151,244,93 + CONTROL "", IDC_RES_TRACKBAR, "msctls_trackbar32",WS_TABSTOP,12,161,187,15 + EDITTEXT IDC_RES_DPIEDIT,204,161,23,13,ES_NUMBER|WS_TABSTOP + LTEXT "dpi",IDC_STATIC,235,163,10,8 + LTEXT "This is a sample text using 10 point Tahoma",IDC_RES_FONT_PREVIEW,15,181,230,55 +END + +IDD_DLLCFG DIALOG DISCARDABLE 0, 0, 260, 250 +STYLE WS_CHILD | WS_DISABLED +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " ��������� DLL ",IDC_STATIC,8,4,244,240 + LTEXT "����� �����������, ����� ����������� ������������ ���������� (DLL) ������������: ���������� � Wine ��� ��������� (�� Windows)." + ,IDC_STATIC,16,16,220,32 + LTEXT "����� ��������� ��� ����������:",IDC_STATIC,16,58,160,8 + COMBOBOX IDC_DLLCOMBO,16,68,140,14,CBS_DROPDOWN | WS_VSCROLL | WS_TABSTOP | CBS_SORT | CBS_LOWERCASE + PUSHBUTTON "&��������",IDC_DLLS_ADDDLL, 164,68,82,13,BS_DEFPUSHBUTTON + LTEXT "������������ ���������:",IDC_STATIC,16,86,100,8 + LISTBOX IDC_DLLS_LIST,16,96,140,140,WS_BORDER | WS_TABSTOP | WS_VSCROLL + PUSHBUTTON "&�������������",IDC_DLLS_EDITDLL,164,96,82,14 + PUSHBUTTON "&�������",IDC_DLLS_REMOVEDLL,164,114,82,14 +END + +IDD_LOADORDER DIALOG DISCARDABLE 80, 90, 150, 92 +STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +CAPTION "������������� ���������" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " ������� �������� ",IDC_STATIC,8,4,135,66 + CONTROL "&���������� (Wine)",IDC_RAD_BUILTIN,"Button", BS_AUTORADIOBUTTON | WS_GROUP,16,14,105,10 + CONTROL "�&�������� (Windows)",IDC_RAD_NATIVE,"Button", BS_AUTORADIOBUTTON,16,24,105,10 + CONTROL "�&���������, ����� ���������",IDC_RAD_BUILTIN_NATIVE,"Button", BS_AUTORADIOBUTTON,16,34,115,10 + CONTROL "��&�������, ����� ����������",IDC_RAD_NATIVE_BUILTIN,"Button", BS_AUTORADIOBUTTON,16,44,115,10 + CONTROL "&�����������",IDC_RAD_DISABLE,"Button", BS_AUTORADIOBUTTON,16,54,105,10 + DEFPUSHBUTTON "OK",IDOK,8,74,45,14,WS_GROUP + PUSHBUTTON "������",IDCANCEL,57,74,45,14,WS_GROUP +END + +IDD_DRIVECFG DIALOG DISCARDABLE 0, 0, 260, 250 +STYLE WS_CHILD | WS_DISABLED +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " ��������� ������ ",IDC_STATIC,8,4,244,240 + LTEXT "Failed to connect to the mount manager, the drive configuration cannot be edited.", IDC_STATIC_MOUNTMGR_ERROR, 15,30,220,76 + CONTROL "Listview",IDC_LIST_DRIVES,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | + LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,18,232,76 + PUSHBUTTON "&��������...",IDC_BUTTON_ADD,15,98,45,14 + PUSHBUTTON "&�������",IDC_BUTTON_REMOVE,66,98,47,14 + PUSHBUTTON "&���������������...",IDC_BUTTON_AUTODETECT,165,98,80,14 + + /* editing drive details */ + LTEXT "&����:",IDC_STATIC_PATH,15,123,20,9 + EDITTEXT IDC_EDIT_PATH,41,120,160,13,ES_AUTOHSCROLL | WS_TABSTOP + PUSHBUTTON "&�����...",IDC_BUTTON_BROWSE_PATH,206,120,40,13 + + LTEXT "&���:",IDC_STATIC_TYPE,15,138,21,10 + COMBOBOX IDC_COMBO_TYPE,41,135,77,60,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + + LTEXT "����� � �������� �����",IDC_LABELSERIAL_STATIC,15,155,95,10 + + PUSHBUTTON "�������������...",IDC_BUTTON_SHOW_HIDE_ADVANCED,150,136,96,13 + CONTROL "�������������� &c ����������:",IDC_RADIO_AUTODETECT,"Button", + BS_AUTORADIOBUTTON,15,166,150,10 + EDITTEXT IDC_EDIT_DEVICE,27,176,174,13,ES_AUTOHSCROLL + PUSHBUTTON "��&���...",IDC_BUTTON_BROWSE_DEVICE,206,176,40,13 + CONTROL "&��������� �������:",IDC_RADIO_ASSIGN,"Button", + BS_AUTORADIOBUTTON,15,195,100,10 + + LTEXT "&�����:",IDC_STATIC_LABEL,33,208,29,12 + EDITTEXT IDC_EDIT_LABEL,103,205,118,13,ES_AUTOHSCROLL | WS_TABSTOP + LTEXT "�������� �����:",IDC_STATIC_SERIAL,33,225,80,12 + EDITTEXT IDC_EDIT_SERIAL,103,221,118,13,ES_AUTOHSCROLL | WS_TABSTOP + + CONTROL "���������� �����, ������������ � �����",IDC_SHOW_DOT_FILES,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,8,260,230,8 +END + +IDD_AUDIOCFG DIALOG DISCARDABLE 0, 0, 260, 250 +STYLE WS_CHILD | WS_DISABLED +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " ����� �������� ",IDC_STATIC,8,4,244,195 + LTEXT "�������� �������: ",IDC_STATIC,15,20,227,30 + CONTROL "Devices",IDC_AUDIO_TREE,"SysTreeView32",WS_BORDER | WS_TABSTOP,15,50,140,140 + PUSHBUTTON "&��������� ����",IDC_AUDIO_TEST,170,50,59,14 + PUSHBUTTON "������ ����������",IDC_AUDIO_CONTROL_PANEL,170,70,80,14 + GROUPBOX " DirectSound ",IDC_STATIC,8,205,244,60 + LTEXT "���������� ���������: ",IDC_STATIC,15,215,90,10 + COMBOBOX IDC_DSOUND_HW_ACCEL,100,213,145,70,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + LTEXT "������� (����):",IDC_STATIC,15,232,70,8 + COMBOBOX IDC_DSOUND_RATES,100,230,42,76,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + LTEXT "����������� (���):",IDC_STATIC,144,232,80,8 + COMBOBOX IDC_DSOUND_BITS,216,230,30,52,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + CONTROL "�������� ��������",IDC_DSOUND_DRV_EMUL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,250,230,10 +END + +IDD_DESKTOP_INTEGRATION DIALOG DISCARDABLE 0, 0, 260, 250 +STYLE WS_CHILD | WS_DISABLED +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX " ������� ��� ",IDC_STATIC,8,4,244,106 + LTEXT "����:",IDC_STATIC,15,16,130,8 + COMBOBOX IDC_THEME_THEMECOMBO,15,24,130,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + PUSHBUTTON "���������� ����...",IDC_THEME_INSTALL,152,23,93,14 + LTEXT "����:",IDC_THEME_COLORTEXT,15,40,112,8 + COMBOBOX IDC_THEME_COLORCOMBO,15,48,112,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + LTEXT "������:",IDC_THEME_SIZETEXT,135,40,110,8 + COMBOBOX IDC_THEME_SIZECOMBO,135,48,110,14,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + LTEXT "�������:",IDC_STATIC,15,64,112,8 + COMBOBOX IDC_SYSPARAM_COMBO,15,74,112,120,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP | CBS_SORT + LTEXT "����:",IDC_SYSPARAM_COLOR_TEXT,135,64,25,8,WS_DISABLED + PUSHBUTTON "",IDC_SYSPARAM_COLOR,135,74,25,13,WS_DISABLED | BS_OWNERDRAW + LTEXT "������:",IDC_SYSPARAM_SIZE_TEXT,166,64,30,8,WS_DISABLED + EDITTEXT IDC_SYSPARAM_SIZE,166,74,23,13,ES_AUTOHSCROLL | WS_TABSTOP | WS_DISABLED + CONTROL "",IDC_SYSPARAM_SIZE_UD,UPDOWN_CLASS,UDS_SETBUDDYINT | WS_DISABLED,187,74,15,13 + PUSHBUTTON "�����",IDC_SYSPARAM_FONT,208,74,37,13,WS_DISABLED + GROUPBOX " ����������� ����� ",IDC_STATIC,8,114,244,100 + CONTROL "Listview",IDC_LIST_SFPATHS,"SysListView32",LVS_REPORT | LVS_AUTOARRANGE | LVS_ALIGNLEFT | + LVS_SINGLESEL | WS_BORDER | WS_TABSTOP, 15,126,230,64 + CONTROL "��������� �:",IDC_LINK_SFPATH,"Button",BS_AUTOCHECKBOX|WS_TABSTOP|WS_DISABLED,15,195,50,13 + EDITTEXT IDC_EDIT_SFPATH,65,195,145,13,ES_AUTOHSCROLL|WS_TABSTOP|WS_DISABLED + PUSHBUTTON "�����",IDC_BROWSE_SFPATH,215,195,30,13,WS_DISABLED +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_TAB_APPLICATIONS "����������" + IDS_TAB_DLLS "����������" + IDS_TAB_DRIVES "�����" + IDS_CHOOSE_PATH "�������� ������� ������� � �������:" + IDS_HIDE_ADVANCED "������ ��������������" + IDS_SHOW_ADVANCED "�������� ��������������" + IDS_NOTHEME "(��� ����)" + IDS_TAB_GRAPHICS "�������" + IDS_TAB_DESKTOP_INTEGRATION "��� � ����������" + IDS_TAB_AUDIO "�����" + IDS_TAB_ABOUT "� ���������" + IDS_WINECFG_TITLE "��������� Wine" + IDS_WINECFG_TITLE_APP "��������� Wine ��� %s" + IDS_THEMEFILE "����� ���" + IDS_THEMEFILE_SELECT "�������� ���� � �����" + IDS_AUDIO_MISSING "������������ ��������� �������� �� �������.\n\n������ ������� �� ���������. ��� ������������� ����� ������� ������ ������� �� ������ ���������.\n\n��� ���������� ��������� ������� ������ ���������." + IDS_SHELL_FOLDER "����������� �����" + IDS_LINKS_TO "������� �" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_DLL_WARNING "��������� ������� �������� ���� ���������� �� �������������.\n�� ������������� ������ �������� �������?" + IDS_DLL_WARNING_CAPTION "��������: ��������� ����������" + IDS_DLL_NATIVE "���������" + IDS_DLL_BUILTIN "����������" + IDS_DLL_NATIVE_BUILTIN "���������, ����������" + IDS_DLL_BUILTIN_NATIVE "����������, ���������" + IDS_DLL_DISABLED "���������" + IDS_DEFAULT_SETTINGS "��������� �� ���������" + IDS_EXECUTABLE_FILTER "��������� Wine (*.exe,*.exe.so)\0*.exe;*.exe.so\0" + IDS_USE_GLOBAL_SETTINGS "������������ �� ���������" + IDS_SELECT_EXECUTABLE "�������� ����������� ����" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_SHADER_MODE_HARDWARE "��������" + IDS_SHADER_MODE_NONE "���������" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_DRIVE_UNKNOWN "���������������" + IDS_DRIVE_FIXED "Ƹ����� ����" + IDS_DRIVE_REMOTE "������� ����" + IDS_DRIVE_REMOVABLE "��������" + IDS_DRIVE_CDROM "CD-ROM" + IDS_DRIVE_LETTERS_EXCEEDED "���������� ������� ����� ����.\n\n� ������� ����� ������ ���� ����� - �� A �� Z, � � ��� ��� 26 ������." + IDS_SYSTEM_DRIVE_LABEL "��������� ����" + IDS_CONFIRM_DELETE_C "������������� ������� ���� C?\n\n����������� Windows-�������� ���������� �������� ��� ����� C. ���� �� ��� �� ������ ������� ����, �� �������� ������� �����!" + IDS_COL_DRIVELETTER "����" + IDS_COL_DRIVEMAPPING "����" + IDS_NO_DRIVE_C "�� �� ��������� ���� C.\n\n�� �������� ��� �������!\n" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_ACCEL_FULL "������" + IDS_ACCEL_STANDARD "�����������" + IDS_ACCEL_BASIC "�����������" + IDS_ACCEL_EMULATION "��������" + IDS_DRIVER_PULSE "PulseAudio драйвер" + IDS_DRIVER_ALSA "ALSA �������" + IDS_DRIVER_ESOUND "EsounD �������" + IDS_DRIVER_OSS "OSS �������" + IDS_DRIVER_JACK "JACK �������" + IDS_DRIVER_NAS "NAS �������" + IDS_DRIVER_AUDIOIO "Audio IO (Solaris) �������" + IDS_DRIVER_COREAUDIO "CoreAudio �������" + IDS_OPEN_DRIVER_ERROR "���������� ������� %s!" + IDS_SOUNDDRIVERS "����� ��������" + IDS_DEVICES_WAVEOUT "���������� ������ �����" + IDS_DEVICES_WAVEIN "���������� ����� �����" + IDS_DEVICES_MIDIOUT "���������� ������ MIDI" + IDS_DEVICES_MIDIIN "���������� ����� MIDI" + IDS_DEVICES_AUX "�������������� ����������" + IDS_DEVICES_MIXER "���������� ������������" + IDS_UNAVAILABLE_DRIVER "�������, ��������� � �������, �� ������!\n\n������� \"%s\" �� �������?" + IDS_WARNING "��������" +END + +STRINGTABLE DISCARDABLE +BEGIN + IDC_SYSPARAMS_BUTTON "�������� ���������� - ���" + IDC_SYSPARAMS_BUTTON_TEXT "�������� ���������� - �����" + IDC_SYSPARAMS_DESKTOP "����" + IDC_SYSPARAMS_MENU "���� - ���" + IDC_SYSPARAMS_MENU_TEXT "���� - �����" + IDC_SYSPARAMS_SCROLLBAR "������ ���������" + IDC_SYSPARAMS_SELECTION "��������� - ���" + IDC_SYSPARAMS_SELECTION_TEXT "��������� - �����" + IDC_SYSPARAMS_TOOLTIP "��������� - ���" + IDC_SYSPARAMS_TOOLTIP_TEXT "��������� - �����" + IDC_SYSPARAMS_WINDOW "���������� ���� - ���" + IDC_SYSPARAMS_WINDOW_TEXT "���������� ���� - �����" + IDC_SYSPARAMS_ACTIVE_TITLE "�������� ����" + IDC_SYSPARAMS_ACTIVE_TITLE_TEXT "�������� ���� - �����" + IDC_SYSPARAMS_INACTIVE_TITLE "��������� ����" + IDC_SYSPARAMS_INACTIVE_TITLE_TEXT "��������� ���� - �����" + IDC_SYSPARAMS_MSGBOX_TEXT "���� ��������� - �����" + IDC_SYSPARAMS_APPWORKSPACE "���������� ���� MDI - ���" + IDC_SYSPARAMS_WINDOW_FRAME "���� - �����" + IDC_SYSPARAMS_ACTIVE_BORDER "�������� ���� - �����" + IDC_SYSPARAMS_INACTIVE_BORDER "��������� ���� - �����" + IDC_SYSPARAMS_BUTTON_SHADOW "�������� ���������� - ����" + IDC_SYSPARAMS_GRAY_TEXT "����������� �������" + IDC_SYSPARAMS_BUTTON_HILIGHT "�������� ���������� - ������� �����" + IDC_SYSPARAMS_BUTTON_DARK_SHADOW "�������� ���������� - ������ ����" + IDC_SYSPARAMS_BUTTON_LIGHT "�������� ���������� - ����" + IDC_SYSPARAMS_BUTTON_ALTERNATE "�������� ���������� - ��� 2" + IDC_SYSPARAMS_HOT_TRACKING "������, ���������" + IDC_SYSPARAMS_ACTIVE_TITLE_GRADIENT "�������� ��������� ����" + IDC_SYSPARAMS_INACTIVE_TITLE_GRADIENT "�������� ���������� ����" + IDC_SYSPARAMS_MENU_HILIGHT "������� ���� - ���������" + IDC_SYSPARAMS_MENUBAR "������� ���� - ���" +END diff --git a/programs/winecfg/Si.rc b/programs/winecfg/Si.rc index 73544bb7bcc..c8bd35e0a04 100644 --- a/programs/winecfg/Si.rc +++ b/programs/winecfg/Si.rc @@ -20,9 +20,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -46,8 +43,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Podatki o registraciji Oken ", IDC_STATIC, 15, 110, 230, 55 LTEXT "Lastnik:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "Organizacija:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END @@ -328,3 +325,5 @@ BEGIN IDC_SYSPARAMS_MENU_HILIGHT "Meni: osvetljen" IDC_SYSPARAMS_MENUBAR "Meni: vrstica" END + +#pragma code_page(default) diff --git a/programs/winecfg/Sv.rc b/programs/winecfg/Sv.rc index dde6ed5ca71..7efe2c052ca 100644 --- a/programs/winecfg/Sv.rc +++ b/programs/winecfg/Sv.rc @@ -20,9 +20,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL IDR_WINECFG MENU DISCARDABLE @@ -44,8 +41,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Registreringsinformation för Windows ", IDC_STATIC, 15, 110, 230, 55 LTEXT "Ägare:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "Organisation:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END diff --git a/programs/winecfg/Tr.rc b/programs/winecfg/Tr.rc index 4f6ecb34048..1be23c58a2f 100644 --- a/programs/winecfg/Tr.rc +++ b/programs/winecfg/Tr.rc @@ -20,9 +20,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT IDR_WINECFG MENU DISCARDABLE @@ -44,8 +41,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Windows Registration Information ", IDC_STATIC, 15, 110, 230, 55 LTEXT "Owner:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "Organization:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END diff --git a/programs/winecfg/Zh.rc b/programs/winecfg/Zh.rc index 86170496f4f..029a26df6a6 100644 --- a/programs/winecfg/Zh.rc +++ b/programs/winecfg/Zh.rc @@ -21,9 +21,6 @@ * */ -#include "config.h" /* Needed for the PACKAGE_STRING definition */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -48,8 +45,8 @@ BEGIN IDC_STATIC,119,44,124,72 GROUPBOX " Windows 注册信息 ", IDC_STATIC, 15, 110, 230, 55 LTEXT "姓名:", IDC_STATIC, 22, 126, 40, 20 - EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP LTEXT "单位:", IDC_STATIC, 22, 140, 50, 20 + EDITTEXT IDC_ABT_OWNER, 75, 126, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP EDITTEXT IDC_ABT_ORG, 75, 140, 160, 13, ES_AUTOHSCROLL | WS_TABSTOP END @@ -598,3 +595,5 @@ BEGIN IDC_SYSPARAMS_INACTIVE_TITLE "非當前標題欄" IDC_SYSPARAMS_INACTIVE_TITLE_TEXT "非當前標題欄文字" END + +#pragma code_page(default) diff --git a/programs/winecfg/drive.c b/programs/winecfg/drive.c index f536bd64395..1afeced033f 100644 --- a/programs/winecfg/drive.c +++ b/programs/winecfg/drive.c @@ -260,7 +260,7 @@ BOOL load_drives(void) { DWORD i, size = 1024; HANDLE mgr; - WCHAR root[] = {'A',':','\\',0}; + WCHAR root[] = {'A',':',0}; if ((mgr = open_mountmgr()) == INVALID_HANDLE_VALUE) return FALSE; diff --git a/programs/winecfg/drivedetect.c b/programs/winecfg/drivedetect.c index 75bce53a4f4..8e55f562c49 100644 --- a/programs/winecfg/drivedetect.c +++ b/programs/winecfg/drivedetect.c @@ -56,10 +56,8 @@ typedef struct static const DEV_NODES sDeviceNodes[] = { {"/dev/fd", DRIVE_REMOVABLE}, {"/dev/pf", DRIVE_REMOVABLE}, - {"/dev/acd", DRIVE_CDROM}, {"/dev/aztcd", DRIVE_CDROM}, {"/dev/bpcd", DRIVE_CDROM}, - {"/dev/cd", DRIVE_CDROM}, {"/dev/cdrom", DRIVE_CDROM}, {"/dev/cdu535", DRIVE_CDROM}, {"/dev/cdwriter", DRIVE_CDROM}, diff --git a/programs/winecfg/resource.h b/programs/winecfg/resource.h index 05a13def24a..1c4a1e77256 100644 --- a/programs/winecfg/resource.h +++ b/programs/winecfg/resource.h @@ -23,10 +23,6 @@ * */ -#include -#include -#include - #define IDC_STATIC -1 #define IDS_TAB_APPLICATIONS 2 #define IDS_TAB_DLLS 3 diff --git a/programs/winecfg/winecfg.rc b/programs/winecfg/winecfg.rc index df572fd820b..6fdc2323a30 100644 --- a/programs/winecfg/winecfg.rc +++ b/programs/winecfg/winecfg.rc @@ -21,8 +21,40 @@ */ #include "config.h" /* Needed for the PACKAGE_STRING definition */ +#include "windef.h" +#include "winbase.h" +#include "wingdi.h" +#include "winnls.h" +#include "winuser.h" +#include "commctrl.h" #include "resource.h" +#include "Bg.rc" +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Es.rc" +#include "Fi.rc" +#include "Fr.rc" +#include "Hu.rc" +#include "It.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Lt.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ro.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" + +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + /* @makedep: idb_wine.bmp */ IDB_WINE BITMAP idb_wine.bmp diff --git a/programs/wineconsole/Makefile.in b/programs/wineconsole/Makefile.in index 6ef22f7fa24..335dd4b4f0a 100644 --- a/programs/wineconsole/Makefile.in +++ b/programs/wineconsole/Makefile.in @@ -15,26 +15,7 @@ C_SRCS = \ user.c \ wineconsole.c -RC_SRCS = \ - wineconsole_Cs.rc \ - wineconsole_De.rc \ - wineconsole_En.rc \ - wineconsole_Eo.rc \ - wineconsole_Es.rc \ - wineconsole_Fr.rc \ - wineconsole_Hu.rc \ - wineconsole_It.rc \ - wineconsole_Ko.rc \ - wineconsole_Lt.rc \ - wineconsole_Nl.rc \ - wineconsole_No.rc \ - wineconsole_Pl.rc \ - wineconsole_Pt.rc \ - wineconsole_Ru.rc \ - wineconsole_Si.rc \ - wineconsole_Sv.rc \ - wineconsole_Tr.rc \ - wineconsole_Zh.rc +RC_SRCS = wineconsole_res.rc @MAKE_PROG_RULES@ diff --git a/programs/wineconsole/wineconsole_Cs.rc b/programs/wineconsole/wineconsole_Cs.rc index 719d70fe72b..b1a46aca470 100644 --- a/programs/wineconsole/wineconsole_Cs.rc +++ b/programs/wineconsole/wineconsole_Cs.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/programs/wineconsole/wineconsole_De.rc b/programs/wineconsole/wineconsole_De.rc index 0841152bead..e6a21570066 100644 --- a/programs/wineconsole/wineconsole_De.rc +++ b/programs/wineconsole/wineconsole_De.rc @@ -16,10 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE @@ -29,8 +25,8 @@ IDS_DEFAULT, "Stan&dard" IDS_PROPERTIES, "&Eigenschaften" IDS_MARK, "&Markieren" IDS_COPY, "&Kopieren" -IDS_PASTE, "&Einfügen" -IDS_SELECTALL, "&Alles auswählen" +IDS_PASTE, "&Einfügen" +IDS_SELECTALL, "&Alles auswählen" IDS_SCROLL, "Sc&rollen" IDS_SEARCH, "&Suchen" IDS_FNT_DISPLAY, "Jeder Buchstabe ist %ld Pixel breit und %ld Pixel hoch" @@ -39,18 +35,18 @@ IDS_FNT_PREVIEW_2, "" IDS_DLG_TIT_DEFAULT, "Setup - Standardeinstellungen" IDS_DLG_TIT_CURRENT, "Setup - aktuelle Einstellungen" IDS_DLG_TIT_ERROR, "Konfigurationsfehler" -IDS_DLG_ERR_SBWINSIZE, "Die Bildschirmgröße muß größer oder gleich der des Fensters sein" +IDS_DLG_ERR_SBWINSIZE, "Die Bildschirmgröße muß größer oder gleich der des Fensters sein" IDS_CMD_INVALID_EVENT_ID "wineconsole: Kann Event-ID nicht parsen\n" -IDS_CMD_INVALID_BACKEND "wineconsole: Ungültiges backend\n" +IDS_CMD_INVALID_BACKEND "wineconsole: Ungültiges backend\n" IDS_CMD_INVALID_OPTION "wineconsole: Nicht erkannte Befehlszeilenoption\n" IDS_CMD_ABOUT "Startet ein Programm in einer Wine-Konsole.\n" IDS_CMD_LAUNCH_FAILED "wineconsole: Starten des Programms %s fehlgeschlagen.\n"\ - "Der Befehl ist ungültig.\n" + "Der Befehl ist ungültig.\n" IDS_USAGE_HEADER "\nAufruf:\n wineconsole [Optionen] \n\nOptionen:\n" -IDS_USAGE_BACKEND " --backend={user|curses} Auswahl von ‚user‘ erstellt ein neues Fenster,\n"\ - " ‚curses‘ versucht das aktuelle Terminal als Wine-\n"\ +IDS_USAGE_BACKEND " --backend={user|curses} Auswahl von ‚user‘ erstellt ein neues Fenster,\n"\ + " ‚curses‘ versucht das aktuelle Terminal als Wine-\n"\ " Konsole einzurichten\n" IDS_USAGE_COMMAND " Das in der Konsole zu startende Wine-Programm\n" IDS_USAGE_FOOTER "\nBespiel:\n wineconsole cmd\nStartet die Wine-Befehlszeile in einer Wine-Konsole\n\n" @@ -61,23 +57,23 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION " Optionen " FONT 8, "MS Shell Dlg" { - GROUPBOX "Cursorgröße", -1, 10, 11, 60, 44, BS_GROUPBOX + GROUPBOX "Cursorgröße", -1, 10, 11, 60, 44, BS_GROUPBOX AUTORADIOBUTTON "&Klein", IDC_OPT_CURSOR_SMALL, 14, 23, 44, 10, WS_TABSTOP AUTORADIOBUTTON "&Mittel", IDC_OPT_CURSOR_MEDIUM, 14, 33, 44, 10, WS_TABSTOP - AUTORADIOBUTTON "&Groß", IDC_OPT_CURSOR_LARGE, 14, 43, 44, 10, WS_TABSTOP + AUTORADIOBUTTON "&Groß", IDC_OPT_CURSOR_LARGE, 14, 43, 44, 10, WS_TABSTOP GROUPBOX "Steuerung", -1, 75, 11, 125, 44, BS_GROUPBOX - LTEXT "Popup-Menü", -1, 79, 23, 50, 10 + LTEXT "Popup-Menü", -1, 79, 23, 50, 10 AUTOCHECKBOX "&Strg", IDC_OPT_CONF_CTRL, 129, 23, 60, 10, WS_TABSTOP AUTOCHECKBOX "&Umschalt", IDC_OPT_CONF_SHIFT, 129, 33, 60, 10, WS_TABSTOP - LTEXT "QuickEdit", -1, 79, 43, 50, 10 + LTEXT "QuickEdit-Modus", -1, 79, 43, 50, 10 AUTOCHECKBOX "&aktiv", IDC_OPT_QUICK_EDIT, 129, 43, 60, 10, WS_TABSTOP GROUPBOX "Befehlsspeicher", -1, 10, 57, 190, 35, BS_GROUPBOX LTEXT "&Anzahl der Puffer:", -1, 14, 67, 78, 18 EDITTEXT IDC_OPT_HIST_SIZE, 92, 69, 31, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_OPT_HIST_SIZE_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - AUTOCHECKBOX "Alte &Duplikate löschen", IDC_OPT_HIST_NODOUBLE, 130, 67, 65, 18, WS_TABSTOP|BS_MULTILINE + AUTOCHECKBOX "Alte &Duplikate löschen", IDC_OPT_HIST_NODOUBLE, 130, 67, 50, 18, WS_TABSTOP|BS_MULTILINE } IDD_FONT DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 @@ -85,7 +81,7 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION " Schriftart " FONT 8, "MS Shell Dlg" { - LTEXT "Schrift&art", -1, 5, 5, 32, 8 + LTEXT "Schrift&art", -1, 5, 5, 24, 8 LISTBOX IDC_FNT_LIST_FONT, 5, 18, 90, 42, LBS_SORT|WS_VSCROLL LTEXT "F&arbe", -1, 100, 5, 50, 8 CONTROL "", IDC_FNT_COLOR_FG, "WineConColorPreview", 0L, 100, 18, 48, 16 @@ -93,7 +89,7 @@ FONT 8, "MS Shell Dlg" LTEXT "&Grad", -1, 158, 5, 40, 8 LISTBOX IDC_FNT_LIST_SIZE, 158, 18, 40, 60, WS_VSCROLL CONTROL "", IDC_FNT_PREVIEW, "WineConFontPreview", 0L, 5, 60, 109, 40 - LTEXT "", IDC_FNT_FONT_INFO, 128, 70, 80, 24 + LTEXT "", IDC_FNT_FONT_INFO, 128, 76, 80, 18 } IDD_CONFIG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 @@ -101,24 +97,24 @@ STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION " Konfiguration " FONT 8, "MS Shell Dlg" { - GROUPBOX "Fensterpuffergröße", -1, 10, 11, 100, 42, BS_GROUPBOX + GROUPBOX "Fensterpuffergröße", -1, 10, 11, 100, 42, BS_GROUPBOX LTEXT "&Breite :", -1, 14, 25, 54, 9 EDITTEXT IDC_CNF_SB_WIDTH, 68, 23, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_CNF_SB_WIDTH_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - LTEXT "&Höhe :", -1, 14, 39, 54, 9 + LTEXT "&Höhe :", -1, 14, 39, 54, 9 EDITTEXT IDC_CNF_SB_HEIGHT, 68, 37, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_CNF_SB_HEIGHT_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - GROUPBOX "Fenstergröße", -1, 10, 55, 100, 42 + GROUPBOX "Fenstergröße", -1, 10, 55, 100, 42 LTEXT "B&reite :", -1, 14, 69, 54, 9 EDITTEXT IDC_CNF_WIN_WIDTH, 68, 67, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_CNF_WIN_WIDTH_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - LTEXT "Höh&e :", -1, 14, 83, 54, 9 + LTEXT "Höh&e :", -1, 14, 83, 54, 9 EDITTEXT IDC_CNF_WIN_HEIGHT, 68, 81, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_CNF_WIN_HEIGHT_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 GROUPBOX "Programmende", -1, 115, 11, 80, 42, BS_GROUPBOX - AUTOCHECKBOX "Konsole &schließen", IDC_CNF_CLOSE_EXIT, 119, 25, 75, 20, WS_TABSTOP + AUTOCHECKBOX "Konsole &schließen", IDC_CNF_CLOSE_EXIT, 119, 25, 75, 20, WS_TABSTOP GROUPBOX "Edition", -1, 115, 55, 80, 42 COMBOBOX IDC_CNF_EDITION_MODE, 119, 69, 75, 20, CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP @@ -130,8 +126,8 @@ CAPTION "Konsolenparameter" FONT 8, "MS Shell Dlg" { GROUPBOX "", -1, 10, 10, 120, 31, BS_GROUPBOX - AUTORADIOBUTTON "Übernehme diese Einstellungen für spätere Sitzungen", IDC_SAV_SAVE, 14, 15, 110, 10, WS_TABSTOP - AUTORADIOBUTTON "Verändere nur die aktuelle Sitzung", IDC_SAV_SESSION, 14, 27, 110, 10, WS_TABSTOP + AUTORADIOBUTTON "Übernehme diese Einstellungen für spätere Sitzungen", IDC_SAV_SAVE, 14, 15, 110, 10, WS_TABSTOP + AUTORADIOBUTTON "Verändere nur die aktuelle Sitzung", IDC_SAV_SESSION, 14, 27, 110, 10, WS_TABSTOP PUSHBUTTON "OK", IDOK, 20, 45, 35, 12 PUSHBUTTON "Abbrechen", IDCANCEL, 65, 45, 35, 12 diff --git a/programs/wineconsole/wineconsole_En.rc b/programs/wineconsole/wineconsole_En.rc index c9b849add9b..624d0faf246 100644 --- a/programs/wineconsole/wineconsole_En.rc +++ b/programs/wineconsole/wineconsole_En.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE @@ -134,21 +132,3 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "OK", IDOK, 35, 45, 35, 12 PUSHBUTTON "Cancel", IDCANCEL, 80, 45, 35, 12 } - -LANGUAGE LANG_ENGLISH, SUBLANG_NEUTRAL - -IDD_FONT DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION " Font " -FONT 8, "MS Shell Dlg" -{ - LTEXT "&Font", -1, 5, 5, 24, 8 - LISTBOX IDC_FNT_LIST_FONT, 5, 18, 90, 42, LBS_SORT|WS_VSCROLL - LTEXT "&Colour", -1, 100, 5, 50, 8 - CONTROL "", IDC_FNT_COLOR_FG, "WineConColorPreview", 0L, 100, 18, 48, 16 - CONTROL "", IDC_FNT_COLOR_BK, "WineConColorPreview", 0L, 100, 40, 48, 16 - LTEXT "&Size", -1, 158, 5, 40, 8 - LISTBOX IDC_FNT_LIST_SIZE, 158, 18, 40, 60, WS_VSCROLL - CONTROL "", IDC_FNT_PREVIEW, "WineConFontPreview", 0L, 5, 60, 109, 40 - LTEXT "", IDC_FNT_FONT_INFO, 128, 76, 80, 18 -} diff --git a/programs/wineconsole/wineconsole_Eo.rc b/programs/wineconsole/wineconsole_Eo.rc index c60a9d103f1..4d031e1184f 100644 --- a/programs/wineconsole/wineconsole_Eo.rc +++ b/programs/wineconsole/wineconsole_Eo.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - LANGUAGE LANG_ESPERANTO, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/wineconsole/wineconsole_Es.rc b/programs/wineconsole/wineconsole_Es.rc index f1340e49aaa..d26dc9f57d6 100644 --- a/programs/wineconsole/wineconsole_Es.rc +++ b/programs/wineconsole/wineconsole_Es.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL STRINGTABLE diff --git a/programs/wineconsole/wineconsole_Fr.rc b/programs/wineconsole/wineconsole_Fr.rc index 330436bfd42..85d243272ca 100644 --- a/programs/wineconsole/wineconsole_Fr.rc +++ b/programs/wineconsole/wineconsole_Fr.rc @@ -1,7 +1,6 @@ /* * Copyright 2001 Eric Pouech * Copyright 2006 Jonathan Ernst - * Copyright 2009 Frédéric Delanoy * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -18,72 +17,67 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE BEGIN -IDS_EDIT, "É&dition" -IDS_DEFAULT, "Par &défaut" -IDS_PROPERTIES, "&Propriétés" +IDS_EDIT, "É&dition" +IDS_DEFAULT, "Par &défaut" +IDS_PROPERTIES, "&Propriétés" IDS_MARK, "&Marquer" IDS_COPY, "&Copier" IDS_PASTE, "C&oller" -IDS_SELECTALL, "&Sélectionner tout" -IDS_SCROLL, "&Défiler" +IDS_SELECTALL, "&Sélectionner tout" +IDS_SCROLL, "&Défiler" IDS_SEARCH, "C&hercher" -IDS_FNT_DISPLAY, "Chaque caractère a %ld pixels de largeur et %ld pixels de hauteur" +IDS_FNT_DISPLAY, "Chaque caractère a %ld points en largeur et %ld points en hauteur" IDS_FNT_PREVIEW_1, "Ceci est un test" -IDS_FNT_PREVIEW_2, "éèàôë" -IDS_DLG_TIT_DEFAULT, "Configuration par défaut" +IDS_FNT_PREVIEW_2, "éèàôë" +IDS_DLG_TIT_DEFAULT, "Configuration par défaut" IDS_DLG_TIT_CURRENT, "Configuration courante" IDS_DLG_TIT_ERROR, "Erreur de configuration" -IDS_DLG_ERR_SBWINSIZE, "La taille du tampon écran doit être plus grande ou égale à celle du tampon de la fenêtre" +IDS_DLG_ERR_SBWINSIZE, "La taille du tampon écran doit être plus grande que celle de la fenêtre" -IDS_CMD_INVALID_EVENT_ID "wineconsole : impossible de déchiffrer l'identifiant d'événement\n" -IDS_CMD_INVALID_BACKEND "wineconsole : moteur invalide\n" -IDS_CMD_INVALID_OPTION "wineconsole : option de ligne de commande non reconnue\n" -IDS_CMD_ABOUT "Démarre un programme dans une console Wine\n" -IDS_CMD_LAUNCH_FAILED "wineconsole : échec lors du démarrage du programme %s.\n"\ +IDS_CMD_INVALID_EVENT_ID "wineconsole : Impossible d'analyser l'événement\n" +IDS_CMD_INVALID_BACKEND "wineconsole : Moteur invalide\n" +IDS_CMD_INVALID_OPTION "wineconsole : Option de la ligne de commande non reconnue\n" +IDS_CMD_ABOUT "Démarre un programme dans une console Wine\n" +IDS_CMD_LAUNCH_FAILED "wineconsole : Échec lors du démarrage du programme %s.\n"\ "La commande est invalide.\n" IDS_USAGE_HEADER "\nUsage :\n wineconsole [options] \n\nOptions :\n" -IDS_USAGE_BACKEND " --backend={user|curses} Utilisez « user » pour utiliser une nouvelle fenêtre\n"\ - " « curses » pour essayer de convertir le terminal courant en console Wine\n" -IDS_USAGE_COMMAND " Le programme Wine à exécuter dans la console\n" -IDS_USAGE_FOOTER "\nExemple : « wineconsole cmd » démarre l'interpréteur de commandes de Wine dans une console Wine\n\n" +IDS_USAGE_BACKEND " --backend={user|curses} En choisissant « user » une nouvelle fenêtre sera créée, « curses »\n"\ + " essaiera de convertir le terminal courant en console Wine\n" +IDS_USAGE_COMMAND " Le programme Wine à exécuter dans la console\n" +IDS_USAGE_FOOTER "\nExemple :\n wineconsole cmd\nDémarre l'interpréteur de commandes de Wine dans une console Wine\n\n" END -IDD_OPTION DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 214, 105 +IDD_OPTION DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION " Options " FONT 8, "MS Shell Dlg" { - GROUPBOX "Taille du curseur", -1, 10, 11, 63, 49, BS_GROUPBOX - AUTORADIOBUTTON "&Petit", IDC_OPT_CURSOR_SMALL, 14, 25, 44, 10, WS_TABSTOP - AUTORADIOBUTTON "&Moyen", IDC_OPT_CURSOR_MEDIUM, 14, 35, 44, 10, WS_TABSTOP - AUTORADIOBUTTON "&Grand", IDC_OPT_CURSOR_LARGE, 14, 45, 44, 10, WS_TABSTOP - - GROUPBOX "Contrôle", -1, 75, 11, 129, 49, BS_GROUPBOX - LTEXT "Menu contextuel", -1, 83, 23, 53, 10 - AUTOCHECKBOX "&Control", IDC_OPT_CONF_CTRL, 142, 23, 60, 10, WS_TABSTOP - AUTOCHECKBOX "S&hift", IDC_OPT_CONF_SHIFT, 142, 33, 60, 10, WS_TABSTOP - LTEXT "Édition rapide", -1, 83, 48, 53, 10 - AUTOCHECKBOX "&activer", IDC_OPT_QUICK_EDIT, 142, 48, 60, 10, WS_TABSTOP - - GROUPBOX "Historique des commandes", -1, 10, 62, 194, 35, BS_GROUPBOX - LTEXT "&Nombre de commandes mémorisées :", -1, 14, 72, 78, 18 - EDITTEXT IDC_OPT_HIST_SIZE, 94, 74, 31, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER + GROUPBOX "Taille du curseur", -1, 10, 11, 60, 44, BS_GROUPBOX + AUTORADIOBUTTON "&Petit", IDC_OPT_CURSOR_SMALL, 14, 23, 44, 10, WS_TABSTOP + AUTORADIOBUTTON "&Moyen", IDC_OPT_CURSOR_MEDIUM, 14, 33, 44, 10, WS_TABSTOP + AUTORADIOBUTTON "&Grand", IDC_OPT_CURSOR_LARGE, 14, 43, 44, 10, WS_TABSTOP + + GROUPBOX "Contrôle", -1, 75, 11, 125, 44, BS_GROUPBOX + LTEXT "Popup menu", -1, 79, 23, 50, 10 + AUTOCHECKBOX "&Control", IDC_OPT_CONF_CTRL, 129, 23, 60, 10, WS_TABSTOP + AUTOCHECKBOX "S&hift", IDC_OPT_CONF_SHIFT, 129, 33, 60, 10, WS_TABSTOP + LTEXT "Édition rapide", -1, 79, 43, 50, 10 + AUTOCHECKBOX "&activer", IDC_OPT_QUICK_EDIT, 129, 43, 60, 10, WS_TABSTOP + + GROUPBOX "Historique des commandes", -1, 10, 57, 190, 35, BS_GROUPBOX + LTEXT "&Taille de la mémoire tampon :", -1, 14, 67, 78, 18 + EDITTEXT IDC_OPT_HIST_SIZE, 92, 69, 31, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_OPT_HIST_SIZE_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - AUTOCHECKBOX "&Supprimer les doublons", IDC_OPT_HIST_NODOUBLE, 142, 72, 60, 18, WS_TABSTOP|BS_MULTILINE + AUTOCHECKBOX "&Supprimer les doublons", IDC_OPT_HIST_NODOUBLE, 130, 67, 60, 18, WS_TABSTOP|BS_MULTILINE } -IDD_FONT DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 205, 106 +IDD_FONT DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION " Police " FONT 8, "MS Shell Dlg" @@ -94,17 +88,17 @@ FONT 8, "MS Shell Dlg" CONTROL "", IDC_FNT_COLOR_FG, "WineConColorPreview", 0L, 100, 18, 48, 16 CONTROL "", IDC_FNT_COLOR_BK, "WineConColorPreview", 0L, 100, 40, 48, 16 LTEXT "&Taille", -1, 158, 5, 40, 8 - LISTBOX IDC_FNT_LIST_SIZE, 158, 18, 40, 43, WS_VSCROLL + LISTBOX IDC_FNT_LIST_SIZE, 158, 18, 40, 60, WS_VSCROLL CONTROL "", IDC_FNT_PREVIEW, "WineConFontPreview", 0L, 5, 60, 109, 40 - LTEXT "", IDC_FNT_FONT_INFO, 120, 69, 78, 28 + LTEXT "", IDC_FNT_FONT_INFO, 128, 76, 80, 18 } -IDD_CONFIG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 205, 107 +IDD_CONFIG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION " Configuration " FONT 8, "MS Shell Dlg" { - GROUPBOX "Taille mémoire tampon écran", -1, 10, 11, 100, 42, BS_GROUPBOX + GROUPBOX "Taille mémoire tampon écran", -1, 10, 11, 100, 42, BS_GROUPBOX LTEXT "&Largeur :", -1, 14, 25, 54, 9 EDITTEXT IDC_CNF_SB_WIDTH, 68, 23, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_CNF_SB_WIDTH_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 @@ -112,7 +106,7 @@ FONT 8, "MS Shell Dlg" EDITTEXT IDC_CNF_SB_HEIGHT, 68, 37, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_CNF_SB_HEIGHT_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - GROUPBOX "Taille de la fenêtre", -1, 10, 55, 100, 42 + GROUPBOX "Taille de la fenêtre", -1, 10, 55, 100, 42 LTEXT "La&rgeur :", -1, 14, 69, 54, 9 EDITTEXT IDC_CNF_WIN_WIDTH, 68, 67, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_CNF_WIN_WIDTH_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 @@ -121,21 +115,21 @@ FONT 8, "MS Shell Dlg" CONTROL "", IDC_CNF_WIN_HEIGHT_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 GROUPBOX "Fin du programme", -1, 115, 11, 80, 42, BS_GROUPBOX - AUTOCHECKBOX "&Fermer la console", IDC_CNF_CLOSE_EXIT, 119, 25, 70, 20, WS_TABSTOP + AUTOCHECKBOX "&Fermer la console", IDC_CNF_CLOSE_EXIT, 119, 25, 75, 20, WS_TABSTOP - GROUPBOX "Édition", -1, 115, 55, 80, 42 - COMBOBOX IDC_CNF_EDITION_MODE, 119, 69, 73, 13, CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + GROUPBOX "Édition", -1, 115, 55, 80, 42 + COMBOBOX IDC_CNF_EDITION_MODE, 119, 69, 75, 20, CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP } -IDD_SAVE_SETTINGS DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 206, 60 +IDD_SAVE_SETTINGS DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 200, 60 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION -CAPTION "Paramètres de la console" +CAPTION "Paramètres de la console" FONT 8, "MS Shell Dlg" { - GROUPBOX "", -1, 10, 10, 185, 31, BS_GROUPBOX - AUTORADIOBUTTON "Sauver les paramètres pour les prochaines sessions", IDC_SAV_SAVE, 14, 15, 180, 10, WS_TABSTOP - AUTORADIOBUTTON "Appliquer uniquement à la session courante", IDC_SAV_SESSION, 14, 27, 180, 10, WS_TABSTOP + GROUPBOX "", -1, 10, 10, 180, 31, BS_GROUPBOX + AUTORADIOBUTTON "Sauver les paramètres pour les prochaines sessions", IDC_SAV_SAVE, 14, 15, 170, 10, WS_TABSTOP + AUTORADIOBUTTON "Appliquer uniquement à la session courante", IDC_SAV_SESSION, 14, 27, 170, 10, WS_TABSTOP - PUSHBUTTON "OK", IDOK, 55, 45, 35, 12 - PUSHBUTTON "Annuler", IDCANCEL, 120, 45, 35, 12 + PUSHBUTTON "OK", IDOK, 50, 45, 35, 12 + PUSHBUTTON "Annuler", IDCANCEL, 115, 45, 35, 12 } diff --git a/programs/wineconsole/wineconsole_Hu.rc b/programs/wineconsole/wineconsole_Hu.rc index 5a269bf62be..7faf9cc48e7 100644 --- a/programs/wineconsole/wineconsole_Hu.rc +++ b/programs/wineconsole/wineconsole_Hu.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/wineconsole/wineconsole_It.rc b/programs/wineconsole/wineconsole_It.rc index bc1f90149eb..d67205c59b2 100644 --- a/programs/wineconsole/wineconsole_It.rc +++ b/programs/wineconsole/wineconsole_It.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL STRINGTABLE diff --git a/programs/wineconsole/wineconsole_Ko.rc b/programs/wineconsole/wineconsole_Ko.rc index 947859041b6..6b0c8d34bb1 100644 --- a/programs/wineconsole/wineconsole_Ko.rc +++ b/programs/wineconsole/wineconsole_Ko.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/wineconsole/wineconsole_Lt.rc b/programs/wineconsole/wineconsole_Lt.rc deleted file mode 100644 index 311bb1f2f77..00000000000 --- a/programs/wineconsole/wineconsole_Lt.rc +++ /dev/null @@ -1,139 +0,0 @@ -/* - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "wineconsole_res.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE -BEGIN -IDS_EDIT, "&Taisa" -IDS_DEFAULT, "Nustatyti &numatytąsias" -IDS_PROPERTIES, "&Savybės" -IDS_MARK, "&Žymėti" -IDS_COPY, "&Kopijuoti" -IDS_PASTE, "Į&dėti" -IDS_SELECTALL, "&Pažymėti viską" -IDS_SCROLL, "&Slinkti" -IDS_SEARCH, "&Ieškoti" -IDS_FNT_DISPLAY, "Kiekvienas simbolis yra %ld pikselių pločio ir %ld pikselių aukščio" -IDS_FNT_PREVIEW_1, "Čia yra testas" -IDS_FNT_PREVIEW_2, "" -IDS_DLG_TIT_DEFAULT, "Konfigūracija - numatytosios nuostatos" -IDS_DLG_TIT_CURRENT, "Konfigūracija - dabartinės nuostatos" -IDS_DLG_TIT_ERROR, "Konfigūracijos klaida" -IDS_DLG_ERR_SBWINSIZE, "Ekrano buferio dydis turi būti didesnis arba lygus lango buferiui" - -IDS_CMD_INVALID_EVENT_ID "wineconsole: nepavyko išnagrinėti įvykio identifikatoriaus\n" -IDS_CMD_INVALID_BACKEND "wineconsole: neteisinga posistemė\n" -IDS_CMD_INVALID_OPTION "wineconsole: neatpažintas komandinės eilutės parametras\n" -IDS_CMD_ABOUT "Paleidžia programą Wine pulte\n" -IDS_CMD_LAUNCH_FAILED "wineconsole: nepavyko paleisti programos %s.\n"\ - "Neteisinga komanda.\n" - -IDS_USAGE_HEADER "\nNaudojimas:\n wineconsole [parametrai] \n\nParametrai:\n" -IDS_USAGE_BACKEND " --backend={user|curses} „User“ sukurs naują langą, „curses“ mėgins\n"\ - " sukonfigūruoti dabartinį terminalą kaip Wine pultą\n" -IDS_USAGE_COMMAND " Wine programa paleidimui pulte\n" -IDS_USAGE_FOOTER "\nPavyzdys:\n wineconsole cmd\nPaleidžia Wine komandų interpretatorių Wine pulte\n\n" - -END - -IDD_OPTION DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION " Parinktys " -FONT 8, "MS Shell Dlg" -{ - GROUPBOX "Žymeklio dydis", -1, 10, 11, 60, 44, BS_GROUPBOX - AUTORADIOBUTTON "&Mažas", IDC_OPT_CURSOR_SMALL, 14, 23, 44, 10, WS_TABSTOP - AUTORADIOBUTTON "&Vidutinis", IDC_OPT_CURSOR_MEDIUM, 14, 33, 44, 10, WS_TABSTOP - AUTORADIOBUTTON "&Didelis", IDC_OPT_CURSOR_LARGE, 14, 43, 44, 10, WS_TABSTOP - - GROUPBOX "Valdymas", -1, 75, 11, 125, 44, BS_GROUPBOX - LTEXT "Iškylantis meniu", -1, 79, 23, 60, 20 - AUTOCHECKBOX "&Control", IDC_OPT_CONF_CTRL, 149, 23, 50, 10, WS_TABSTOP - AUTOCHECKBOX "S&hift", IDC_OPT_CONF_SHIFT, 149, 33, 50, 10, WS_TABSTOP - LTEXT "Greitas redagavimas", -1, 79, 43, 70, 10 - AUTOCHECKBOX "įjun>i", IDC_OPT_QUICK_EDIT, 149, 43, 50, 10, WS_TABSTOP - - GROUPBOX "Komandų istorija", -1, 10, 57, 190, 35, BS_GROUPBOX - LTEXT "Prisimintų &komandų skaičius:", -1, 14, 67, 78, 18 - EDITTEXT IDC_OPT_HIST_SIZE, 92, 69, 31, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER - CONTROL "", IDC_OPT_HIST_SIZE_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - AUTOCHECKBOX "&Šalinti vienodas", IDC_OPT_HIST_NODOUBLE, 130, 67, 60, 18, WS_TABSTOP|BS_MULTILINE -} - -IDD_FONT DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION " Šriftas " -FONT 8, "MS Shell Dlg" -{ - LTEXT "&Šriftas", -1, 5, 5, 24, 8 - LISTBOX IDC_FNT_LIST_FONT, 5, 18, 90, 42, LBS_SORT|WS_VSCROLL - LTEXT "&Spalva", -1, 100, 5, 50, 8 - CONTROL "", IDC_FNT_COLOR_FG, "WineConColorPreview", 0L, 100, 18, 48, 16 - CONTROL "", IDC_FNT_COLOR_BK, "WineConColorPreview", 0L, 100, 40, 48, 16 - LTEXT "&Dydis", -1, 158, 5, 40, 8 - LISTBOX IDC_FNT_LIST_SIZE, 158, 18, 40, 60, WS_VSCROLL - CONTROL "", IDC_FNT_PREVIEW, "WineConFontPreview", 0L, 5, 60, 109, 40 - LTEXT "", IDC_FNT_FONT_INFO, 124, 76, 80, 27 -} - -IDD_CONFIG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION " Konfigūracija " -FONT 8, "MS Shell Dlg" -{ - GROUPBOX "Buferio dydis", -1, 10, 11, 100, 42, BS_GROUPBOX - LTEXT "&Plotis:", -1, 14, 25, 54, 9 - EDITTEXT IDC_CNF_SB_WIDTH, 68, 23, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER - CONTROL "", IDC_CNF_SB_WIDTH_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - LTEXT "&Aukštis:", -1, 14, 39, 54, 9 - EDITTEXT IDC_CNF_SB_HEIGHT, 68, 37, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER - CONTROL "", IDC_CNF_SB_HEIGHT_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - - GROUPBOX "Lango dydis", -1, 10, 55, 100, 42 - LTEXT "P&lotis:", -1, 14, 69, 54, 9 - EDITTEXT IDC_CNF_WIN_WIDTH, 68, 67, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER - CONTROL "", IDC_CNF_WIN_WIDTH_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - LTEXT "A&ukštis:", -1, 14, 83, 54, 9 - EDITTEXT IDC_CNF_WIN_HEIGHT, 68, 81, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER - CONTROL "", IDC_CNF_WIN_HEIGHT_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - - GROUPBOX "Programos pabaiga", -1, 115, 11, 80, 42, BS_GROUPBOX - AUTOCHECKBOX "Už&daryti pultą", IDC_CNF_CLOSE_EXIT, 119, 25, 72, 20, WS_TABSTOP - - GROUPBOX "Laida", -1, 115, 55, 80, 42 - COMBOBOX IDC_CNF_EDITION_MODE, 119, 69, 72, 20, CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP -} - -IDD_SAVE_SETTINGS DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 170, 60 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION -CAPTION "Pulto parametrai" -FONT 8, "MS Shell Dlg" -{ - GROUPBOX "", -1, 10, 10, 150, 31, BS_GROUPBOX - AUTORADIOBUTTON "Išsaugoti vėlesniems seansams", IDC_SAV_SAVE, 14, 15, 140, 10, WS_TABSTOP - AUTORADIOBUTTON "Keisti tik dabartinį seansą", IDC_SAV_SESSION, 14, 27, 140, 10, WS_TABSTOP - - PUSHBUTTON "Gerai", IDOK, 35, 45, 35, 12 - PUSHBUTTON "Atsisakyti", IDCANCEL, 80, 45, 35, 12 -} diff --git a/programs/wineconsole/wineconsole_Nl.rc b/programs/wineconsole/wineconsole_Nl.rc index d02fe76cd1d..00c77aaafd8 100644 --- a/programs/wineconsole/wineconsole_Nl.rc +++ b/programs/wineconsole/wineconsole_Nl.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE diff --git a/programs/wineconsole/wineconsole_No.rc b/programs/wineconsole/wineconsole_No.rc index 2a11dfbe2bf..6bf5fb3ec88 100644 --- a/programs/wineconsole/wineconsole_No.rc +++ b/programs/wineconsole/wineconsole_No.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE diff --git a/programs/wineconsole/wineconsole_Pl.rc b/programs/wineconsole/wineconsole_Pl.rc index 9ad379925d7..c19d73b1cde 100644 --- a/programs/wineconsole/wineconsole_Pl.rc +++ b/programs/wineconsole/wineconsole_Pl.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/wineconsole/wineconsole_Pt.rc b/programs/wineconsole/wineconsole_Pt.rc index 934607c4beb..8fc6371db94 100644 --- a/programs/wineconsole/wineconsole_Pt.rc +++ b/programs/wineconsole/wineconsole_Pt.rc @@ -3,8 +3,7 @@ * Portuguese Language Support * * Copyright 2003 Marcelo Duarte - * Copyright 2006-2007 Américo José Melo - * Copyright 2009 Ricardo Filipe + * Copyright 2006-2007 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 @@ -21,16 +20,12 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - -#pragma code_page(65001) - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE BEGIN IDS_EDIT, "&Editar" -IDS_DEFAULT, "&Definir padrões" +IDS_DEFAULT, "&Definir padrões" IDS_PROPERTIES, "&Propriedades" IDS_MARK, "&Marcar" IDS_COPY, "&Copiar" @@ -39,11 +34,11 @@ IDS_SELECTALL, "&Selecionar tudo" IDS_SCROLL, "&Rolar" IDS_SEARCH, "&Pesquisar" IDS_FNT_DISPLAY, "Cada caracter tem %ld pixels de largura por %ld pixels de altura" -IDS_FNT_PREVIEW_1, "Este é um teste" +IDS_FNT_PREVIEW_1, "Este é um teste" IDS_FNT_PREVIEW_2, "" -IDS_DLG_TIT_DEFAULT, "Setup - configurações padrões" -IDS_DLG_TIT_CURRENT, "Setup - configurações atuais" -IDS_DLG_TIT_ERROR, "Erro de configuração" +IDS_DLG_TIT_DEFAULT, "Setup - configurações padrões" +IDS_DLG_TIT_CURRENT, "Setup - configurações atuais" +IDS_DLG_TIT_ERROR, "Erro de configuração" IDS_DLG_ERR_SBWINSIZE, "Tamanho do buffer de tela deve ser maior ou igual ao da janela" END @@ -52,7 +47,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE BEGIN IDS_EDIT, "&Editar" -IDS_DEFAULT, "&Definir predefinições" +IDS_DEFAULT, "&Definir predefinições" IDS_PROPERTIES, "&Propriedades" IDS_MARK, "&Marcar" IDS_COPY, "&Copiar" @@ -61,49 +56,36 @@ IDS_SELECTALL, "&Seleccionar tudo" IDS_SCROLL, "&Rolar" IDS_SEARCH, "&Pesquisar" IDS_FNT_DISPLAY, "Cada caracter tem %ld pixels de largura por %ld pixels de altura" -IDS_FNT_PREVIEW_1, "Este é um teste" +IDS_FNT_PREVIEW_1, "Este é um teste" IDS_FNT_PREVIEW_2, "" -IDS_DLG_TIT_DEFAULT, "Configuração - configurações predefinidas" -IDS_DLG_TIT_CURRENT, "Configuração - configurações actuais" -IDS_DLG_TIT_ERROR, "Erro de configuração" -IDS_DLG_ERR_SBWINSIZE, "O tamanho do 'buffer' do ecrã deve ser maior ou igual ao da janela" - -IDS_CMD_INVALID_EVENT_ID "wineconsole: Impossível extrair o id do evento\n" -IDS_CMD_INVALID_BACKEND "wineconsole: Estrutura inválida\n" -IDS_CMD_INVALID_OPTION "wineconsole: Opção de linha de comandos desconhecida\n" -IDS_CMD_ABOUT "Arranca um programa numa consola do Wine\n" -IDS_CMD_LAUNCH_FAILED "wineconsole: O arranque do programa %s falhou.\n"\ - "O comando é inválido.\n" - -IDS_USAGE_HEADER "\nUso:\n wineconsole [opções] \n\nOpções:\n" -IDS_USAGE_BACKEND " --backend={user|curses} Se escolher user vai abrir uma nova janela, curses vai\n"\ - " tentar configurar o terminal actual como uma consola Wine\n" -IDS_USAGE_COMMAND " O programa Wine a lançar na consola\n" -IDS_USAGE_FOOTER "\nExemplo:\n wineconsole cmd\nArranca a linha de comandos do Wine numa consola Wine\n\n" - +IDS_DLG_TIT_DEFAULT, "Configuração - configurações predefinidas" +IDS_DLG_TIT_CURRENT, "Configuração - configurações actuais" +IDS_DLG_TIT_ERROR, "Erro de configuração" +IDS_DLG_ERR_SBWINSIZE, "O tamanho do 'buffer' do ecrã deve ser maior ou igual ao da janela" END + LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN IDD_OPTION DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION " Opções " +CAPTION " Opções " FONT 8, "MS Shell Dlg" { GROUPBOX "Cursor", -1, 10, 11, 60, 44, BS_GROUPBOX AUTORADIOBUTTON "&Pequeno", IDC_OPT_CURSOR_SMALL, 14, 23, 44, 10, WS_TABSTOP - AUTORADIOBUTTON "&Médio", IDC_OPT_CURSOR_MEDIUM, 14, 33, 44, 10, WS_TABSTOP + AUTORADIOBUTTON "&Médio", IDC_OPT_CURSOR_MEDIUM, 14, 33, 44, 10, WS_TABSTOP AUTORADIOBUTTON "&Grande", IDC_OPT_CURSOR_LARGE, 14, 43, 44, 10, WS_TABSTOP GROUPBOX "Controle", -1, 75, 11, 125, 44, BS_GROUPBOX LTEXT "Popup menu", -1, 79, 23, 40, 10 AUTOCHECKBOX "&Controle", IDC_OPT_CONF_CTRL, 129, 23, 60, 10, WS_TABSTOP - AUTOCHECKBOX "&Rotação", IDC_OPT_CONF_SHIFT, 129, 33, 60, 10, WS_TABSTOP - LTEXT "Edição rápida", -1, 79, 43, 50, 10 + AUTOCHECKBOX "&Rotação", IDC_OPT_CONF_SHIFT, 129, 33, 60, 10, WS_TABSTOP + LTEXT "Edição rápida", -1, 79, 43, 50, 10 AUTOCHECKBOX "&Habilitado", IDC_OPT_QUICK_EDIT, 129, 43, 60, 10, WS_TABSTOP - GROUPBOX "Histórico de comandos", -1, 10, 57, 190, 35, BS_GROUPBOX - LTEXT "&Número de comandos rechamados :", -1, 14, 67, 78, 18 + GROUPBOX "Histórico de comandos", -1, 10, 57, 190, 35, BS_GROUPBOX + LTEXT "&Número de comandos rechamados :", -1, 14, 67, 78, 18 EDITTEXT IDC_OPT_HIST_SIZE, 92, 69, 31, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_OPT_HIST_SIZE_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 AUTOCHECKBOX "&Remover duplicados", IDC_OPT_HIST_NODOUBLE, 130, 67, 50, 18, WS_TABSTOP|BS_MULTILINE @@ -113,23 +95,23 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE IDD_OPTION DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION " Opções " +CAPTION " Opções " FONT 8, "MS Shell Dlg" { GROUPBOX "Cursor", -1, 10, 11, 60, 44, BS_GROUPBOX AUTORADIOBUTTON "&Pequeno", IDC_OPT_CURSOR_SMALL, 14, 23, 44, 10, WS_TABSTOP - AUTORADIOBUTTON "&Médio", IDC_OPT_CURSOR_MEDIUM, 14, 33, 44, 10, WS_TABSTOP + AUTORADIOBUTTON "&Médio", IDC_OPT_CURSOR_MEDIUM, 14, 33, 44, 10, WS_TABSTOP AUTORADIOBUTTON "&Grande", IDC_OPT_CURSOR_LARGE, 14, 43, 44, 10, WS_TABSTOP GROUPBOX "Controlo", -1, 75, 11, 125, 44, BS_GROUPBOX LTEXT "Popup Menu", -1, 79, 23, 40, 10 AUTOCHECKBOX "&Controlo", IDC_OPT_CONF_CTRL, 129, 23, 60, 10, WS_TABSTOP - AUTOCHECKBOX "&Rotação", IDC_OPT_CONF_SHIFT, 129, 33, 60, 10, WS_TABSTOP - LTEXT "Edição rápida", -1, 79, 43, 50, 10 + AUTOCHECKBOX "&Rotação", IDC_OPT_CONF_SHIFT, 129, 33, 60, 10, WS_TABSTOP + LTEXT "Edição rápida", -1, 79, 43, 50, 10 AUTOCHECKBOX "&Activado", IDC_OPT_QUICK_EDIT, 129, 43, 60, 10, WS_TABSTOP - GROUPBOX "Histórico de comandos", -1, 10, 57, 190, 35, BS_GROUPBOX - LTEXT "&Número de comandos rechamados :", -1, 14, 67, 78, 18 + GROUPBOX "Histórico de comandos", -1, 10, 57, 190, 35, BS_GROUPBOX + LTEXT "&Número de comandos rechamados :", -1, 14, 67, 78, 18 EDITTEXT IDC_OPT_HIST_SIZE, 92, 69, 31, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_OPT_HIST_SIZE_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 AUTOCHECKBOX "&Remover duplicados", IDC_OPT_HIST_NODOUBLE, 130, 67, 50, 18, WS_TABSTOP|BS_MULTILINE @@ -177,7 +159,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN IDD_CONFIG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION " Configuração " +CAPTION " Configuração " FONT 8, "MS Shell Dlg" { GROUPBOX "Buffer zone", -1, 10, 11, 100, 42, BS_GROUPBOX @@ -199,7 +181,7 @@ FONT 8, "MS Shell Dlg" GROUPBOX "Finalizar programa", -1, 115, 11, 80, 42, BS_GROUPBOX AUTOCHECKBOX "&Fechar o console", IDC_CNF_CLOSE_EXIT, 119, 25, 75, 20, WS_TABSTOP - GROUPBOX "Edição", -1, 115, 55, 80, 42 + GROUPBOX "Edição", -1, 115, 55, 80, 42 COMBOBOX IDC_CNF_EDITION_MODE, 119, 69, 75, 20, CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP } @@ -207,7 +189,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE IDD_CONFIG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION " Configuração " +CAPTION " Configuração " FONT 8, "MS Shell Dlg" { GROUPBOX "Zona do 'buffer'", -1, 10, 11, 100, 42, BS_GROUPBOX @@ -229,7 +211,7 @@ FONT 8, "MS Shell Dlg" GROUPBOX "Finalizar programa", -1, 115, 11, 80, 42, BS_GROUPBOX AUTOCHECKBOX "&Fechar consola", IDC_CNF_CLOSE_EXIT, 119, 25, 75, 20, WS_TABSTOP - GROUPBOX "Edição", -1, 115, 55, 80, 42 + GROUPBOX "Edição", -1, 115, 55, 80, 42 COMBOBOX IDC_CNF_EDITION_MODE, 119, 69, 75, 20, CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP } @@ -238,12 +220,12 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN IDD_SAVE_SETTINGS DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 140, 60 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION -CAPTION "Parâmetros do console" +CAPTION "Parâmetros do console" FONT 8, "MS Shell Dlg" { GROUPBOX "", -1, 10, 10, 120, 31, BS_GROUPBOX - AUTORADIOBUTTON "Manter configurações nas sessões seguintes", IDC_SAV_SAVE, 14, 15, 110, 10, WS_TABSTOP - AUTORADIOBUTTON "Modificar somente sessão atual", IDC_SAV_SESSION, 14, 27, 110, 10, WS_TABSTOP + AUTORADIOBUTTON "Manter configurações nas sessões seguintes", IDC_SAV_SAVE, 14, 15, 110, 10, WS_TABSTOP + AUTORADIOBUTTON "Modificar somente sessão atual", IDC_SAV_SESSION, 14, 27, 110, 10, WS_TABSTOP PUSHBUTTON "OK", IDOK, 20, 45, 35, 12 PUSHBUTTON "Cancelar", IDCANCEL, 65, 45, 35, 12 @@ -253,12 +235,12 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE IDD_SAVE_SETTINGS DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 140, 60 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION -CAPTION "Parâmetros da consola" +CAPTION "Parâmetros da consola" FONT 8, "MS Shell Dlg" { GROUPBOX "", -1, 10, 10, 120, 31, BS_GROUPBOX - AUTORADIOBUTTON "Manter configurações nas sessões seguintes", IDC_SAV_SAVE, 14, 15, 110, 10, WS_TABSTOP - AUTORADIOBUTTON "Modificar apenas a sessão actual", IDC_SAV_SESSION, 14, 27, 110, 10, WS_TABSTOP + AUTORADIOBUTTON "Manter configurações nas sessões seguintes", IDC_SAV_SAVE, 14, 15, 110, 10, WS_TABSTOP + AUTORADIOBUTTON "Modificar apenas a sessão actual", IDC_SAV_SESSION, 14, 27, 110, 10, WS_TABSTOP PUSHBUTTON "OK", IDOK, 20, 45, 35, 12 PUSHBUTTON "Cancelar", IDCANCEL, 65, 45, 35, 12 diff --git a/programs/wineconsole/wineconsole_Ru.rc b/programs/wineconsole/wineconsole_Ru.rc index 0cebb2dc341..0044538fa77 100644 --- a/programs/wineconsole/wineconsole_Ru.rc +++ b/programs/wineconsole/wineconsole_Ru.rc @@ -18,83 +18,78 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE BEGIN -IDS_EDIT, "&Правка" -IDS_DEFAULT, "По &умолчанию" -IDS_PROPERTIES, "С&войства" -IDS_MARK, "&Выделить" -IDS_COPY, "&Копировать" -IDS_PASTE, "&Вставить" -IDS_SELECTALL, "Выделить в&се" -IDS_SCROLL, "Прок&рутить" -IDS_SEARCH, "По&иск" -IDS_FNT_DISPLAY, "Каждый символ %ld пикселей в ширину и %ld пикселей в высоту" -IDS_FNT_PREVIEW_1, "Это тест" +IDS_EDIT, "&Ïðàâêà" +IDS_DEFAULT, "Ïî &óìîë÷àíèþ" +IDS_PROPERTIES, "Ñ&âîéñòâà" +IDS_MARK, "&Âûäåëèòü" +IDS_COPY, "&Êîïèðîâàòü" +IDS_PASTE, "&Âñòàâèòü" +IDS_SELECTALL, "Âûäåëèòü â&ñå" +IDS_SCROLL, "Ïðîê&ðóòèòü" +IDS_SEARCH, "Ïî&èñê" +IDS_FNT_DISPLAY, "Êàæäûé ñèìâîë %ld ïèêñåëåé â øèðèíó è %ld ïèêñåëåé â âûñîòó" +IDS_FNT_PREVIEW_1, "Ýòî òåñò" IDS_FNT_PREVIEW_2, "This is a test" -IDS_DLG_TIT_DEFAULT, "Настройка - Установки по умолчанию" -IDS_DLG_TIT_CURRENT, "Настройка - Текущие установки" -IDS_DLG_TIT_ERROR, "Ошибка настройки" -IDS_DLG_ERR_SBWINSIZE, "Размер буфера экрана должен быть не менее буфера окна" - -IDS_CMD_INVALID_EVENT_ID "wineconsole: Не верно указан код события\n" -IDS_CMD_INVALID_BACKEND "wineconsole: Не известный backend\n" -IDS_CMD_INVALID_OPTION "wineconsole: Указанная опция не найдена\n" -IDS_CMD_ABOUT "Запуск программы в консоли Wine\n" -IDS_CMD_LAUNCH_FAILED "wineconsole: Не удался запуск программы '%s'.\n"\ - "Не верно указанна команда.\n" - -IDS_USAGE_HEADER "\nВызов:\n wineconsole [опции] <команда>\n\nОпции:\n" -IDS_USAGE_BACKEND " --backend={user|curses} Выбор 'user' откроет новое окно с полной поддержкой\n"\ - " всех режимов работы консоли. 'curses' - использует\n"\ - " текущее окно с ограниченной функциональностью\n"\ -IDS_USAGE_COMMAND " <команда> Имя программы для запуска в консоли Wine\n" -IDS_USAGE_FOOTER "\nНапример:\n wineconsole cmd\nЗапустить командный процессор Wine в консоли Wine\n\n" +IDS_DLG_TIT_DEFAULT, "Íàñòðîéêà - Óñòàíîâêè ïî óìîë÷àíèþ" +IDS_DLG_TIT_CURRENT, "Íàñòðîéêà - Òåêóùèå óñòàíîâêè" +IDS_DLG_TIT_ERROR, "Îøèáêà íàñòðîéêè" +IDS_DLG_ERR_SBWINSIZE, "Ðàçìåð áóôåðà ýêðàíà äîëæåí áûòü íå ìåíåå áóôåðà îêíà" + +IDS_CMD_INVALID_EVENT_ID "wineconsole: Íå âåðíî óêàçàí êîä ñîáûòèÿ\n" +IDS_CMD_INVALID_BACKEND "wineconsole: Íå èçâåñòíûé backend\n" +IDS_CMD_INVALID_OPTION "wineconsole: Óêàçàííàÿ îïöèÿ íå íàéäåíà\n" +IDS_CMD_ABOUT "Çàïóñê ïðîãðàììû â êîíñîëè Wine\n" +IDS_CMD_LAUNCH_FAILED "wineconsole: Íå óäàëñÿ çàïóñê ïðîãðàììû '%s'.\n"\ + "Íå âåðíî óêàçàííà êîìàíäà.\n" + +IDS_USAGE_HEADER "\nÂûçîâ:\n wineconsole [îïöèè] <êîìàíà>\n\nÎïöèè:\n" +IDS_USAGE_BACKEND " --backend={user|curses} Âûáîð 'user' îòêðîåò íîâîå îêíî ñ ïîëíîé ïîääåðæêîé\n"\ + " âñåõ ðåæèìîâ ðàáîòû êîíñîëè. 'curses' - èñïîëüçóåò\n"\ + " òåêóùåå îêíî ñ îãðàíè÷åííîé ôóíêöèîíàëüíîñòüþ\n"\ +IDS_USAGE_COMMAND " <êîìàíäà> Èìÿ ïðîãðàììû äëÿ çàïóñêà â êîíñîëè Wine\n" +IDS_USAGE_FOOTER "\nÍàïðèìåð:\n wineconsole cmd\nÇàïóñòèòü êîìàíäíûé ïðîöåññîð Wine â êîíñîëè Wine\n\n" END IDD_OPTION DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION " Опции " +CAPTION " Îïöèè " FONT 8, "MS Shell Dlg" { - GROUPBOX "Размер курсора", -1, 10, 11, 60, 54, BS_GROUPBOX - AUTORADIOBUTTON "&Маленький", IDC_OPT_CURSOR_SMALL, 14, 23, 52, 10, WS_TABSTOP - AUTORADIOBUTTON "&Средний", IDC_OPT_CURSOR_MEDIUM, 14, 33, 52, 10, WS_TABSTOP - AUTORADIOBUTTON "&Большой", IDC_OPT_CURSOR_LARGE, 14, 43, 52, 10, WS_TABSTOP - - GROUPBOX "Управление", -1, 75, 11, 123, 54, BS_GROUPBOX - LTEXT "Всплывающее меню", -1, 79, 23, 50, 20 - AUTOCHECKBOX "&Сtrl", IDC_OPT_CONF_CTRL, 144, 23, 52, 10, WS_TABSTOP + GROUPBOX "Ðàçìåð êóðñîðà", -1, 10, 11, 60, 54, BS_GROUPBOX + AUTORADIOBUTTON "&Ìàëåíüêèé", IDC_OPT_CURSOR_SMALL, 14, 23, 52, 10, WS_TABSTOP + AUTORADIOBUTTON "&Ñðåäíèé", IDC_OPT_CURSOR_MEDIUM, 14, 33, 52, 10, WS_TABSTOP + AUTORADIOBUTTON "&Áîëüøîé", IDC_OPT_CURSOR_LARGE, 14, 43, 52, 10, WS_TABSTOP + + GROUPBOX "Óïðàâëåíèå", -1, 75, 11, 123, 54, BS_GROUPBOX + LTEXT "Âñïëûâàþùåå ìåíþ", -1, 79, 23, 50, 20 + AUTOCHECKBOX "&Ñtrl", IDC_OPT_CONF_CTRL, 144, 23, 52, 10, WS_TABSTOP AUTOCHECKBOX "S&hift", IDC_OPT_CONF_SHIFT, 144, 33, 52, 10, WS_TABSTOP - LTEXT "Быстрое редактирование", -1, 79, 43, 60, 20 - AUTOCHECKBOX "&включить", IDC_OPT_QUICK_EDIT, 144, 51, 52, 10, WS_TABSTOP + LTEXT "Áûñòðîå ðåäàêòèðîâàíèå", -1, 79, 43, 60, 20 + AUTOCHECKBOX "&âêëþ÷èòü", IDC_OPT_QUICK_EDIT, 144, 51, 52, 10, WS_TABSTOP - GROUPBOX "История команд", -1, 10, 67, 189, 35, BS_GROUPBOX - LTEXT "&История команд:", -1, 14, 77, 78, 18 + GROUPBOX "Èñòîðèÿ êîìàíä", -1, 10, 67, 189, 35, BS_GROUPBOX + LTEXT "&Èñòîðèÿ êîìàíä:", -1, 14, 77, 78, 18 EDITTEXT IDC_OPT_HIST_SIZE, 82, 79, 31, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_OPT_HIST_SIZE_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - AUTOCHECKBOX "&Удалять дублирующиеся", IDC_OPT_HIST_NODOUBLE, 120, 77, 70, 18, WS_TABSTOP|BS_MULTILINE + AUTOCHECKBOX "&Óäàëÿòü äóáëèðóþùèåñÿ", IDC_OPT_HIST_NODOUBLE, 120, 77, 70, 18, WS_TABSTOP|BS_MULTILINE } IDD_FONT DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION " Шрифт " +CAPTION " Øðèôò " FONT 8, "MS Shell Dlg" { - LTEXT "&Шрифт", -1, 5, 5, 24, 8 + LTEXT "&Øðèôò", -1, 5, 5, 24, 8 LISTBOX IDC_FNT_LIST_FONT, 5, 18, 90, 42, LBS_SORT|WS_VSCROLL - LTEXT "&Цвет", -1, 100, 5, 50, 8 + LTEXT "&Öâåò", -1, 100, 5, 50, 8 CONTROL "", IDC_FNT_COLOR_FG, "WineConColorPreview", 0L, 100, 18, 48, 16 CONTROL "", IDC_FNT_COLOR_BK, "WineConColorPreview", 0L, 100, 40, 48, 16 - LTEXT "&Размер", -1, 158, 5, 40, 8 + LTEXT "&Ðàçìåð", -1, 158, 5, 40, 8 LISTBOX IDC_FNT_LIST_SIZE, 158, 18, 40, 60, WS_VSCROLL CONTROL "", IDC_FNT_PREVIEW, "WineConFontPreview", 0L, 5, 60, 109, 40 LTEXT "", IDC_FNT_FONT_INFO, 128, 71, 80, 25 @@ -102,41 +97,41 @@ FONT 8, "MS Shell Dlg" IDD_CONFIG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 140, 105 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION " Настройка " +CAPTION " Íàñòðîéêà " FONT 8, "MS Shell Dlg" { - GROUPBOX "Зона буфера", -1, 8, 11, 100, 42, BS_GROUPBOX - LTEXT "&Ширина :", -1, 14, 25, 54, 9 + GROUPBOX "Çîíà áóôåðà", -1, 10, 11, 100, 42, BS_GROUPBOX + LTEXT "&Øèðèíà :", -1, 14, 25, 54, 9 EDITTEXT IDC_CNF_SB_WIDTH, 68, 23, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_CNF_SB_WIDTH_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - LTEXT "&Высота :", -1, 14, 39, 54, 9 + LTEXT "&Âûñîòà :", -1, 14, 39, 54, 9 EDITTEXT IDC_CNF_SB_HEIGHT, 68, 37, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_CNF_SB_HEIGHT_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - GROUPBOX "Размер окна", -1, 8, 55, 100, 42 - LTEXT "Ш&ирина :", -1, 14, 69, 54, 9 + GROUPBOX "Ðàçìåð îêíà", -1, 10, 55, 100, 42 + LTEXT "Ø&èðèíà :", -1, 14, 69, 54, 9 EDITTEXT IDC_CNF_WIN_WIDTH, 68, 67, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_CNF_WIN_WIDTH_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - LTEXT "В&ысота :", -1, 14, 83, 54, 9 + LTEXT "Â&ûñîòà :", -1, 14, 83, 54, 9 EDITTEXT IDC_CNF_WIN_HEIGHT, 68, 81, 36, 12, WS_TABSTOP|WS_BORDER|ES_NUMBER CONTROL "", IDC_CNF_WIN_HEIGHT_UD, "msctls_updown32", UDS_SETBUDDYINT|UDS_ALIGNRIGHT|UDS_AUTOBUDDY|UDS_ARROWKEYS|UDS_NOTHOUSANDS, 0, 0, 0, 0 - GROUPBOX "Завершение программы", -1, 112, 11, 90, 43, BS_GROUPBOX - AUTOCHECKBOX "&Закрывать консоль", IDC_CNF_CLOSE_EXIT, 119, 25, 79, 20, WS_TABSTOP + GROUPBOX "Çàâåðøåíèå ïðîãðàììû", -1, 115, 11, 85, 42, BS_GROUPBOX + AUTOCHECKBOX "&Çàêðûâàòü êîíñîëü", IDC_CNF_CLOSE_EXIT, 119, 25, 75, 20, WS_TABSTOP - GROUPBOX "Редактирование", -1, 112, 55, 90, 42 + GROUPBOX "Ðåäàêòèðîâàíèå", -1, 115, 55, 85, 42 COMBOBOX IDC_CNF_EDITION_MODE, 119, 69, 75, 20, CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP } IDD_SAVE_SETTINGS DIALOG LOADONCALL MOVEABLE DISCARDABLE 20, 20, 198, 70 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION -CAPTION "Параметры консоли" +CAPTION "Ïàðàìåòðû êîíñîëè" FONT 8, "MS Shell Dlg" { GROUPBOX "", -1, 10, 10, 178, 31, BS_GROUPBOX - AUTORADIOBUTTON "Сохранить эти настройки для будущих сессий", IDC_SAV_SAVE, 14, 27, 170, 10, WS_TABSTOP - AUTORADIOBUTTON "Изменить только текущую сессию", IDC_SAV_SESSION, 14, 15, 170, 10, WS_TABSTOP + AUTORADIOBUTTON "Ñîõðàíèòü ýòè íàñòðîéêè äëÿ áóäóùèõ ñåññèé", IDC_SAV_SAVE, 14, 27, 170, 10, WS_TABSTOP + AUTORADIOBUTTON "Èçìåíèòü òîëüêî òåêóùóþ ñåññèþ", IDC_SAV_SESSION, 14, 15, 170, 10, WS_TABSTOP PUSHBUTTON "OK", IDOK, 40, 50, 50, 14 - PUSHBUTTON "Отмена", IDCANCEL, 110, 50, 50, 14 + PUSHBUTTON "Îòìåíà", IDCANCEL, 110, 50, 50, 14 } diff --git a/programs/wineconsole/wineconsole_Si.rc b/programs/wineconsole/wineconsole_Si.rc index 79b909337c6..a39fb1518bb 100644 --- a/programs/wineconsole/wineconsole_Si.rc +++ b/programs/wineconsole/wineconsole_Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -137,3 +135,5 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "V redu", IDOK, 35, 45, 35, 12 PUSHBUTTON "Prekliči", IDCANCEL, 80, 45, 35, 12 } + +#pragma code_page(default) diff --git a/programs/wineconsole/wineconsole_Sv.rc b/programs/wineconsole/wineconsole_Sv.rc index 509e876ccdf..e80719e5c8d 100644 --- a/programs/wineconsole/wineconsole_Sv.rc +++ b/programs/wineconsole/wineconsole_Sv.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL STRINGTABLE diff --git a/programs/wineconsole/wineconsole_Tr.rc b/programs/wineconsole/wineconsole_Tr.rc index 7642405b0fa..3bd0b290611 100644 --- a/programs/wineconsole/wineconsole_Tr.rc +++ b/programs/wineconsole/wineconsole_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/wineconsole/wineconsole_Zh.rc b/programs/wineconsole/wineconsole_Zh.rc index 88375bba53e..b03d052c79d 100644 --- a/programs/wineconsole/wineconsole_Zh.rc +++ b/programs/wineconsole/wineconsole_Zh.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wineconsole_res.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -229,3 +227,5 @@ FONT 9, "MS Shell Dlg" PUSHBUTTON "確定", IDOK, 20, 45, 35, 12 PUSHBUTTON "取消", IDCANCEL, 65, 45, 35, 12 } + +#pragma code_page(default) diff --git a/programs/wineconsole/wineconsole_res.h b/programs/wineconsole/wineconsole_res.h index a128aa97c9d..b5518fc33bb 100644 --- a/programs/wineconsole/wineconsole_res.h +++ b/programs/wineconsole/wineconsole_res.h @@ -18,10 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include -#include - /* strings */ #define IDS_EDIT 0x100 #define IDS_DEFAULT 0x101 diff --git a/programs/wineconsole/wineconsole_res.rc b/programs/wineconsole/wineconsole_res.rc new file mode 100644 index 00000000000..14e1a2dff67 --- /dev/null +++ b/programs/wineconsole/wineconsole_res.rc @@ -0,0 +1,44 @@ +/* + * Copyright 2001 Eric Pouech + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "windef.h" +#include "winbase.h" +#include "wingdi.h" +#include "winuser.h" +#include "winnls.h" +#include "commctrl.h" +#include "wineconsole_res.h" + +#include "wineconsole_Cs.rc" +#include "wineconsole_En.rc" +#include "wineconsole_Eo.rc" +#include "wineconsole_Fr.rc" +#include "wineconsole_De.rc" +#include "wineconsole_Es.rc" +#include "wineconsole_Hu.rc" +#include "wineconsole_It.rc" +#include "wineconsole_Ko.rc" +#include "wineconsole_Nl.rc" +#include "wineconsole_No.rc" +#include "wineconsole_Pl.rc" +#include "wineconsole_Pt.rc" +#include "wineconsole_Ru.rc" +#include "wineconsole_Si.rc" +#include "wineconsole_Sv.rc" +#include "wineconsole_Tr.rc" +#include "wineconsole_Zh.rc" diff --git a/programs/winedbg/Makefile.in b/programs/winedbg/Makefile.in index f23298c2394..b4dd150e1e3 100644 --- a/programs/winedbg/Makefile.in +++ b/programs/winedbg/Makefile.in @@ -22,24 +22,15 @@ C_SRCS = \ info.c \ memory.c \ source.c \ - stack.c \ symbol.c \ + stack.c \ tgt_active.c \ tgt_minidump.c \ tgt_module.c \ types.c \ winedbg.c -RC_SRCS = \ - rsrc_De.rc \ - rsrc_En.rc \ - rsrc_Fr.rc \ - rsrc_Ko.rc \ - rsrc_Lt.rc \ - rsrc_Nl.rc \ - rsrc_Pt.rc \ - rsrc_Ru.rc \ - rsrc_Sv.rc +RC_SRCS = rsrc.rc LEX_SRCS = debug.l BISON_SRCS = dbg.y diff --git a/programs/winedbg/be_i386.c b/programs/winedbg/be_i386.c index c22ef145318..ce2076c6055 100644 --- a/programs/winedbg/be_i386.c +++ b/programs/winedbg/be_i386.c @@ -543,6 +543,9 @@ static unsigned be_i386_is_func_call(const void* insn, ADDRESS64* callee) } return TRUE; + case 0xCD: + WINE_FIXME("Unsupported yet call insn (0x%02x) at %p\n", ch, insn); + /* fall through */ default: return FALSE; } diff --git a/programs/winedbg/crashdlg.c b/programs/winedbg/crashdlg.c index 4a24dccaf89..3b32adb321e 100644 --- a/programs/winedbg/crashdlg.c +++ b/programs/winedbg/crashdlg.c @@ -18,6 +18,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include "resource.h" #include "debugger.h" #include "wingdi.h" #include "winuser.h" @@ -26,7 +27,6 @@ #include "wine/debug.h" #include "wine/unicode.h" -#include "resource.h" #define MAX_PROGRAM_NAME_LENGTH 80 @@ -153,8 +153,6 @@ static INT_PTR WINAPI DlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) BOOL display_crash_dialog(void) { - static const WCHAR winedeviceW[] = {'w','i','n','e','d','e','v','i','c','e','.','e','x','e',0}; - INT_PTR result; /* dbg_curr_process->handle is not set */ HANDLE hProcess; @@ -165,7 +163,6 @@ BOOL display_crash_dialog(void) hProcess = OpenProcess(PROCESS_QUERY_INFORMATION, FALSE, dbg_curr_pid); g_ProgramName = get_program_name(hProcess); CloseHandle(hProcess); - if (!strcmpW( g_ProgramName, winedeviceW )) return TRUE; result = DialogBoxW(GetModuleHandleW(NULL), MAKEINTRESOURCEW(IDD_CRASH_DLG), NULL, DlgProc); if (result == ID_DEBUG) { AllocConsole(); diff --git a/programs/winedbg/resource.h b/programs/winedbg/resource.h index 11c2cb9c11d..49d19ef364c 100644 --- a/programs/winedbg/resource.h +++ b/programs/winedbg/resource.h @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include #define IDD_CRASH_DLG 100 diff --git a/programs/winedbg/rsrc.rc b/programs/winedbg/rsrc.rc new file mode 100644 index 00000000000..50c5efbc2d4 --- /dev/null +++ b/programs/winedbg/rsrc.rc @@ -0,0 +1,31 @@ +/* + * Resources (rsrc.rc) + * + * Copyright 2008 Mikolaj Zalewski + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include +#include + +#include "resource.h" + +#include "rsrc_De.rc" +#include "rsrc_En.rc" +#include "rsrc_Ko.rc" +#include "rsrc_Lt.rc" +#include "rsrc_Nl.rc" +#include "rsrc_Ru.rc" diff --git a/programs/winedbg/rsrc_De.rc b/programs/winedbg/rsrc_De.rc index 360f1569fb8..da04942544f 100644 --- a/programs/winedbg/rsrc_De.rc +++ b/programs/winedbg/rsrc_De.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL @@ -55,3 +53,5 @@ BEGIN IDS_INVALID_PARAMS "Interne Fehler - ungültige Parameter empfangen" IDS_UNIDENTIFIED "(unbekannt)" END + +#pragma code_page(default) diff --git a/programs/winedbg/rsrc_En.rc b/programs/winedbg/rsrc_En.rc index 0919c730554..3d580c4d063 100644 --- a/programs/winedbg/rsrc_En.rc +++ b/programs/winedbg/rsrc_En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT IDM_DEBUG_POPUP MENU diff --git a/programs/winedbg/rsrc_Fr.rc b/programs/winedbg/rsrc_Fr.rc deleted file mode 100644 index 4fb6d42881a..00000000000 --- a/programs/winedbg/rsrc_Fr.rc +++ /dev/null @@ -1,58 +0,0 @@ -/* - * French Language Support - * - * Copyright 2009 Frédéric Delanoy - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL - -IDM_DEBUG_POPUP MENU -BEGIN - POPUP "" - BEGIN - MENUITEM "&Déboguer", ID_DEBUG - END -END - -IDD_CRASH_DLG DIALOGEX 100, 100, 273, 175 -STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Erreur du programme" -FONT 8, "Tahoma" -BEGIN - LTEXT "",IDC_STATIC_BG,0,0,273,52,WS_BORDER,0 - LTEXT "Le programme %s a rencontré un problème sérieux et doit \ - être fermé. Nous somme désolés pour le désagrément subi.", - IDC_STATIC_TXT1,27,10,224,30 - LTEXT "Cela peut être causé par une erreur dans le programme ou un défaut dans Wine. \ - Vous pouvez consulter http://appdb.winehq.org pour obtenir des instructions sur \ - l'exécution de cette application.\n\n\ - Si ce problème ne se produit pas sous Windows et n'a pas déjà été rapporté, \ - vous pouvez le rapporter sur http://bugs.winehq.org.",IDC_STATIC_TXT2,27,60,224,100 - DEFPUSHBUTTON "Fermer", IDOK, 205, 151, 60, 16, WS_TABSTOP -END - -STRINGTABLE -BEGIN - IDS_AUTO_CAPTION "Plantage du programme Wine" - IDS_INVALID_PARAMS "Erreurs internes - paramètres invalides reçus" - IDS_UNIDENTIFIED "(non identifié)" -END diff --git a/programs/winedbg/rsrc_Ko.rc b/programs/winedbg/rsrc_Ko.rc index a68deacdc7f..457212f17a6 100644 --- a/programs/winedbg/rsrc_Ko.rc +++ b/programs/winedbg/rsrc_Ko.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT IDM_DEBUG_POPUP MENU diff --git a/programs/winedbg/rsrc_Lt.rc b/programs/winedbg/rsrc_Lt.rc index 6aa5ca4f481..7b49d8def4b 100644 --- a/programs/winedbg/rsrc_Lt.rc +++ b/programs/winedbg/rsrc_Lt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -56,3 +54,5 @@ BEGIN IDS_INVALID_PARAMS "Vidinės klaidos - gauti neteisingi parametrai" IDS_UNIDENTIFIED "(nenustatytas)" END + +#pragma code_page(default) diff --git a/programs/winedbg/rsrc_Nl.rc b/programs/winedbg/rsrc_Nl.rc index e2e23e8d342..01be67bfe22 100644 --- a/programs/winedbg/rsrc_Nl.rc +++ b/programs/winedbg/rsrc_Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL IDM_DEBUG_POPUP MENU diff --git a/programs/winedbg/rsrc_Pt.rc b/programs/winedbg/rsrc_Pt.rc deleted file mode 100644 index c00c3c18d71..00000000000 --- a/programs/winedbg/rsrc_Pt.rc +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Portuguese Language Support - * - * Copyright 2009 Ricardo Filipe - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE - -IDM_DEBUG_POPUP MENU -BEGIN - POPUP "" - BEGIN - MENUITEM "&Depuração", ID_DEBUG - END -END - -IDD_CRASH_DLG DIALOGEX 100, 100, 273, 175 -STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Erro no programa" -FONT 8, "Tahoma" -BEGIN - LTEXT "",IDC_STATIC_BG,0,0,273,52,WS_BORDER,0 - LTEXT "O programa %s encontrou um problema sério e precisa \ - ser encerrado. Pedimos desculpa pelo incómodo.", - IDC_STATIC_TXT1,27,10,224,30 - LTEXT "Isto pode ter sido causado por um problema no programa ou no Wine. \ - Pode querer visitar http://appdb.winehq.org para dicas de como correr \ - esta aplicação.\n\n\ - Se este problema não existe no Windows e não foi reportado ainda \ - você pode fazê-lo em http://bugs.winehq.org.",IDC_STATIC_TXT2,27,60,224,100 - DEFPUSHBUTTON "Fechar", IDOK, 205, 151, 60, 16, WS_TABSTOP -END - -STRINGTABLE -BEGIN - IDS_AUTO_CAPTION "Erro num programa no Wine" - IDS_INVALID_PARAMS "Erros Internos - recebidos parâmetros inválidos" - IDS_UNIDENTIFIED "(não identificado)" -END diff --git a/programs/winedbg/rsrc_Ru.rc b/programs/winedbg/rsrc_Ru.rc index 281537bf9c3..7fc05bb9cac 100644 --- a/programs/winedbg/rsrc_Ru.rc +++ b/programs/winedbg/rsrc_Ru.rc @@ -18,41 +18,36 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT IDM_DEBUG_POPUP MENU BEGIN POPUP "" BEGIN - MENUITEM "&Отладка", ID_DEBUG + MENUITEM "&Îòëàäêà", ID_DEBUG END END IDD_CRASH_DLG DIALOGEX 100, 100, 273, 175 STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Ошибка программы" +CAPTION "Îøèáêà ïðîãðàììû" FONT 8, "Tahoma" BEGIN LTEXT "",IDC_STATIC_BG,0,0,273,52,WS_BORDER,0 - LTEXT "В программе %s обнаружена серьёзная ошибка и она должна быть \ - закрыта. Приносим извинения за неудобство.", + LTEXT " ïðîãðàììå %s îáíàðóæåíà ñåðü¸çíàÿ îøèáêà è îíà äîëæíà áûòü \ + çàêðûòà. Ïðèíîñèì èçâèíåíèÿ çà íåóäîáñòâî.", IDC_STATIC_TXT1,27,10,224,30 - LTEXT "Ошибка могла быть вызвана проблемой в программе или недоработкой в Wine. \ - Вы можете посетить http://appdb.winehq.org и поискать советы о запуске \ - этой программы.\n\n\ - Если эта проблема не присутствует под Windows и ещё не была зарегистрирована, \ - вы можете сообщить о ней на http://bugs.winehq.org.",IDC_STATIC_TXT2,27,60,224,100 - DEFPUSHBUTTON "Закрыть", IDOK, 205, 151, 60, 16, WS_TABSTOP + LTEXT "Îøèáêà ìîãëà áûòü âûçâàíà ïðîáëåìîé â ïðîãðàììå èëè íåäîðàáîòêîé â Wine. \ + Âû ìîæåòå ïîñåòèòü http://appdb.winehq.org è ïîèñêàòü ñîâåòû î çàïóñêå \ + ýòîé ïðîãðàììû.\n\n\ + Åñëè ýòà ïðîáëåìà íå ïðèñóòñòâóåò ïîä Windows è åù¸ íå áûëà çàðåãèñòðèðîâàíà, \ + âû ìîæåòå ñîîáùèòü î íåé íà http://bugs.winehq.org.",IDC_STATIC_TXT2,27,60,224,100 + DEFPUSHBUTTON "Çàêðûòü", IDOK, 205, 151, 60, 16, WS_TABSTOP END STRINGTABLE BEGIN - IDS_AUTO_CAPTION "Ошибка Wine" - IDS_INVALID_PARAMS "Внутренние ошибки - получены неверные параметры" - IDS_UNIDENTIFIED "(неопределено)" + IDS_AUTO_CAPTION "Îøèáêà Wine" + IDS_INVALID_PARAMS "Âíóòðåííèå îøèáêè - ïîëó÷åíû íåâåðíûå ïàðàìåòðû" + IDS_UNIDENTIFIED "(íåîïðåäåëåíî)" END diff --git a/programs/winedbg/rsrc_Sv.rc b/programs/winedbg/rsrc_Sv.rc deleted file mode 100644 index 7d7da32e6b9..00000000000 --- a/programs/winedbg/rsrc_Sv.rc +++ /dev/null @@ -1,58 +0,0 @@ -/* - * Swedish Language Support - * - * Copyright 2008 Anders Jonsson - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL - -IDM_DEBUG_POPUP MENU -BEGIN - POPUP "" - BEGIN - MENUITEM "&Felsök", ID_DEBUG - END -END - -IDD_CRASH_DLG DIALOGEX 100, 100, 273, 175 -STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Programfel" -FONT 8, "Tahoma" -BEGIN - LTEXT "",IDC_STATIC_BG,0,0,273,52,WS_BORDER,0 - LTEXT "Programmet %s har stött på ett allvarligt problem och \ - måste avslutas. Vi ber om ursäkt för besväret.", - IDC_STATIC_TXT1,27,10,224,30 - LTEXT "Detta kan ha orsakats av ett fel i programmet eller en brist i Wine. \ - Du kan söka på http://appdb.winehq.org efter tips om hur man kör \ - detta program.\n\n\ - Om problemet inte uppstår i Windows och ännu inte har rapporterats \ - så kan du rapportera det på http://bugs.winehq.org.",IDC_STATIC_TXT2,27,60,224,100 - DEFPUSHBUTTON "Stäng", IDOK, 205, 151, 60, 16, WS_TABSTOP -END - -STRINGTABLE -BEGIN - IDS_AUTO_CAPTION "Krasch i Wine-program" - IDS_INVALID_PARAMS "Interna fel - ogiltiga parametrar mottogs" - IDS_UNIDENTIFIED "(oidentifierad)" -END diff --git a/programs/winedbg/types.c b/programs/winedbg/types.c index 9c21bd41dc2..cc981a99948 100644 --- a/programs/winedbg/types.c +++ b/programs/winedbg/types.c @@ -671,10 +671,7 @@ int types_print_type(const struct dbg_type* type, BOOL details) types_get_info(type, TI_GET_TYPE, &subtype.id); subtype.module = type->module; types_print_type(&subtype, details); - if (types_get_info(type, TI_GET_COUNT, &count)) - dbg_printf(" %s[%d]", name, count); - else - dbg_printf(" %s[]", name); + dbg_printf(" %s[]", name); break; case SymTagEnum: dbg_printf("enum %s", name); @@ -699,8 +696,7 @@ int types_print_type(const struct dbg_type* type, BOOL details) int i; fcp->Start = 0; - if (!count) dbg_printf("void"); - else while (count) + while (count) { fcp->Count = min(count, 256); if (types_get_info(type, TI_FINDCHILDREN, fcp)) diff --git a/programs/winedbg/winedbg.c b/programs/winedbg/winedbg.c index 55841486c5e..a75e54803f1 100644 --- a/programs/winedbg/winedbg.c +++ b/programs/winedbg/winedbg.c @@ -587,7 +587,7 @@ static int dbg_winedbg_usage(BOOL advanced) } else dbg_printf("Usage:\n\twinedbg [ [ --gdb ] [ prog-name [ prog-args ] | | file.mdmp | --help ]\n"); - return 0; + return -1; } void dbg_start_interactive(HANDLE hFile) diff --git a/programs/winefile/Cs.rc b/programs/winefile/Cs.rc index ad718638e69..6d2294a87b5 100644 --- a/programs/winefile/Cs.rc +++ b/programs/winefile/Cs.rc @@ -23,8 +23,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/programs/winefile/Da.rc b/programs/winefile/Da.rc index ffc74156574..babc0dab32d 100644 --- a/programs/winefile/Da.rc +++ b/programs/winefile/Da.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT /* Menu */ diff --git a/programs/winefile/De.rc b/programs/winefile/De.rc index e30c5c18116..ae1a80fc3bf 100644 --- a/programs/winefile/De.rc +++ b/programs/winefile/De.rc @@ -21,10 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL /* Menu */ @@ -32,33 +28,33 @@ LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL IDM_WINEFILE MENU FIXED IMPURE { POPUP "&Datei" { - MENUITEM "Ö&ffnen\tEingabetaste", ID_ACTIVATE + 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 "&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 "&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 "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 + POPUP "Da&tenträger" { + MENUITEM "Datenträger &kopieren...", 201 + MENUITEM "Datenträger &benennen...", 202 MENUITEM SEPARATOR - MENUITEM "Datenträger &formatieren...", ID_FORMAT_DISK + MENUITEM "Datenträger &formatieren...", ID_FORMAT_DISK #ifdef _WIN95 MENUITEM "...", -1 /*TODO*/ #endif @@ -69,12 +65,12 @@ IDM_WINEFILE MENU FIXED IMPURE MENUITEM "F&reigeben als...", 254 MENUITEM "Freigabe been&den...", 255 MENUITEM SEPARATOR - MENUITEM "Laufwerk aus&wählen...", 251 + MENUITEM "Laufwerk aus&wählen...", 251 } POPUP "&Verzeichnisse" { - MENUITEM "&Nächste Ebene einblenden\t+",301 + MENUITEM "&Nächste Ebene einblenden\t+",301 MENUITEM "&Zweig einblenden\t*", 302 MENUITEM "Alle &Ebenen einblenden\tStrg+*",303 MENUITEM "Zweig &ausblenden\t-", 304 @@ -95,14 +91,14 @@ IDM_WINEFILE MENU FIXED IMPURE 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 &Größe", ID_VIEW_SORT_SIZE MENUITEM "Nach &Datum", ID_VIEW_SORT_DATE MENUITEM SEPARATOR - MENUITEM "Angaben ausw&ählen...", ID_VIEW_FILTER + MENUITEM "Angaben ausw&ählen...", ID_VIEW_FILTER } POPUP "&Optionen" { - MENUITEM "&Bestätigen...", 501 + MENUITEM "&Bestätigen...", 501 MENUITEM "Schrift&art...", ID_SELECT_FONT MENUITEM "Symbolleiste &definieren...", 512 MENUITEM SEPARATOR @@ -119,13 +115,13 @@ IDM_WINEFILE MENU FIXED IMPURE POPUP "&Sicherheit" { MENUITEM "&Berechtigungen...", 605 - MENUITEM "Über&wachen...", 606 + 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 "Über&lappend\tUmschalt+F5", ID_WINDOW_CASCADE MENUITEM "&Untereinander", ID_WINDOW_TILE_HORZ MENUITEM "&Nebeneinander\tUmschalt+F4", ID_WINDOW_TILE_VERT #ifndef _NO_EXTENSIONS @@ -140,14 +136,14 @@ IDM_WINEFILE MENU FIXED IMPURE MENUITEM "&Suchen...\tF1", ID_HELP MENUITEM "Hilfe &verwenden\tF1", ID_HELP_USING MENUITEM SEPARATOR - MENUITEM "&Info über Winefile...", ID_ABOUT + MENUITEM "&Info über Winefile...", ID_ABOUT } } IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Ausführen" +CAPTION "Ausführen" FONT 8, "MS Shell Dlg" { CONTROL "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10 @@ -161,7 +157,7 @@ FONT 8, "MS Shell Dlg" IDD_SELECT_DESTINATION DIALOG FIXED IMPURE 15, 13, 210, 63 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Ziel auswählen" +CAPTION "Ziel auswählen" FONT 8, "MS Shell Dlg" { CONTROL "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10 @@ -174,7 +170,7 @@ FONT 8, "MS Shell Dlg" IDD_DIALOG_VIEW_TYPE DIALOG DISCARDABLE 15, 13, 161, 97 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Angaben auswählen" +CAPTION "Angaben auswählen" FONT 8, "MS Sans Serif" BEGIN LTEXT "&Name:",-1,7,8,22,10 @@ -196,7 +192,7 @@ END IDD_DIALOG_PROPERTIES DIALOG DISCARDABLE 0, 0, 248, 215 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Eigenschaften für %s" +CAPTION "Eigenschaften für %s" FONT 8, "MS Sans Serif" BEGIN DEFPUSHBUTTON "OK",IDOK,191,7,50,14 @@ -205,16 +201,16 @@ BEGIN 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 + 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 + 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 "&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 @@ -228,7 +224,7 @@ END STRINGTABLE { IDS_FONT_SEL_DLG_NAME "Anwenden der Schriftarteinstellung" - IDS_FONT_SEL_ERROR "Fehler während der Schriftart-Auswahl." + IDS_FONT_SEL_ERROR "Fehler während der Schriftart-Auswahl." } STRINGTABLE @@ -247,10 +243,10 @@ STRINGTABLE STRINGTABLE { IDS_COL_NAME "Name" - IDS_COL_SIZE "Größe" + IDS_COL_SIZE "Größe" IDS_COL_CDATE "CDatum" IDS_COL_ADATE "ZDatum" - IDS_COL_MDATE "ÄDatum" + IDS_COL_MDATE "ÄDatum" IDS_COL_IDX "Index/Inode" IDS_COL_LINKS "Links" IDS_COL_ATTR "Attribute" diff --git a/programs/winefile/En.rc b/programs/winefile/En.rc index 644cf2ff262..dc0ef28f2a8 100644 --- a/programs/winefile/En.rc +++ b/programs/winefile/En.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT /* Menu */ diff --git a/programs/winefile/Es.rc b/programs/winefile/Es.rc index 7e445ee309f..fa82f4fd563 100644 --- a/programs/winefile/Es.rc +++ b/programs/winefile/Es.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL /* Menu */ diff --git a/programs/winefile/Fr.rc b/programs/winefile/Fr.rc index 1b39edcefd5..73d7c8e8f12 100644 --- a/programs/winefile/Fr.rc +++ b/programs/winefile/Fr.rc @@ -23,11 +23,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL /* Menu */ @@ -35,24 +30,24 @@ LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL IDM_WINEFILE MENU FIXED IMPURE { POPUP "&Fichier" { - MENUITEM "&Ouvrir\tEntrée", ID_ACTIVATE - MENUITEM "&Déplacer...\tF7", ID_FILE_MOVE + 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\tSuppr", ID_FILE_DELETE MENUITEM "Re&nommer...", 109 - MENUITEM "&Propriétés...\tAlt+Entrée", ID_EDIT_PROPERTIES + MENUITEM "&Propriétés...\tAlt+Entree", ID_EDIT_PROPERTIES MENUITEM SEPARATOR MENUITEM "Co&mpresser...", 119 - MENUITEM "Décompre&sser...", 120 + MENUITEM "Décompre&sser...", 120 MENUITEM SEPARATOR - MENUITEM "E&xécuter...", ID_EXECUTE + MENUITEM "E&xécuter...", ID_EXECUTE MENUITEM "&Imprimer...", 102 MENUITEM "&Associer...", 103 MENUITEM SEPARATOR - MENUITEM "Créer réper&toire...", 111 + MENUITEM "Créer Réper&toire...", 111 MENUITEM "Rec&hercher...", 104 - MENUITEM "Sélectionner &fichiers...", 116 + MENUITEM "Sélectionner &Fichiers...", 116 MENUITEM SEPARATOR #ifndef _NO_EXTENSIONS MENUITEM "&Quitter\tAlt+X", ID_FILE_EXIT @@ -62,16 +57,16 @@ IDM_WINEFILE MENU FIXED IMPURE } POPUP "&Disque" { - MENUITEM "&Copier disque...", 201 - MENUITEM "&Nommer disque...", 202 + MENUITEM "&Copier Disque...", 201 + MENUITEM "&Nommer Disque...", 202 MENUITEM SEPARATOR - MENUITEM "&Formater disque...", ID_FORMAT_DISK + MENUITEM "&Formater Disque...", ID_FORMAT_DISK #ifdef _WIN95 - MENUITEM "Créer un disque &système...", -1 /*TODO*/ + 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 "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 @@ -79,66 +74,66 @@ IDM_WINEFILE MENU FIXED IMPURE 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 + 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 "&Marquer l'arborescence", 505 + MENUITEM "&Indiquer l'arborescence", 505 } - POPUP "&Affichage" { - MENUITEM "Ar&bre et répertoire", 413 + POPUP "&Vue" { + MENUITEM "Arbre et ré&pertoire", 413 MENUITEM "&Arbre seulement", 411 - MENUITEM "&Répertoire seulement", 412 + MENUITEM "&Répertoire seulement", 412 MENUITEM SEPARATOR - MENUITEM "&Séparer", ID_VIEW_SPLIT + 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 "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 "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 + MENUITEM "Trier par &...", ID_VIEW_FILTER } POPUP "&Options" { MENUITEM "&Confirmation...", 501 MENUITEM "&Police...", ID_SELECT_FONT - MENUITEM "Personnaliser la &barre d'outils...", 512 + 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 + 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 + MENUITEM "P&lein Écran\tCtrl+Shift+S", ID_VIEW_FULLSCREEN #endif MENUITEM SEPARATOR - MENUITEM "&Réduire à l'utilisation", 504 + MENUITEM "&Réduire a l'utilisation", 504 MENUITEM "&Enregistrer la configuration en quittant",511 } - POPUP "&Sécurité" { - MENUITEM "&Accès...", 605 - MENUITEM "&Journalisation...", 606 - MENUITEM "&Propriétaire...", 607 + POPUP "&Sécurité" { + MENUITEM "&Accès...", 605 + MENUITEM "&Surveillance...", 606 + MENUITEM "&Propriétaire...", 607 } - POPUP "Fe&nêtre" { - MENUITEM "Nouvelle &fenêtre", ID_WINDOW_NEW + 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 + MENUITEM "Mosaïque &horizontale", ID_WINDOW_TILE_HORZ + MENUITEM "Mosaïque &verticale\tCtrl+F4",ID_WINDOW_TILE_VERT #ifndef _NO_EXTENSIONS - MENUITEM "Réorganisation aut&omatique", ID_WINDOW_AUTOSORT + MENUITEM "Réorganisation &Automatique", ID_WINDOW_AUTOSORT #endif - MENUITEM "Réorganiser les &icônes", ID_WINDOW_ARRANGE + MENUITEM "Réorganiser les &icônes", ID_WINDOW_ARRANGE MENUITEM "&Actualiser\tF5", ID_REFRESH } @@ -147,20 +142,20 @@ IDM_WINEFILE MENU FIXED IMPURE MENUITEM "&Rechercher dans l'aide\tF1", ID_HELP MENUITEM "&Utiliser l'aide\tF1", ID_HELP_USING MENUITEM SEPARATOR - MENUITEM "À &propos de Winefile", ID_ABOUT + MENUITEM "À &propos de Winefile", ID_ABOUT } } IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Exécuter" +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 + 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, 75, 12 + 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 "Aid&e", 254, 158, 43, 47, 14 @@ -168,65 +163,65 @@ FONT 8, "MS Shell Dlg" IDD_SELECT_DESTINATION DIALOG FIXED IMPURE 15, 13, 210, 63 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Sélectionner la destination" +CAPTION "Sélectionner la destination" FONT 8, "MS Shell Dlg" { CONTROL "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10 - CONTROL "&Chemin :", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10 + CONTROL "&Chemin :", -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 "&Parcourir...", 254, 158, 43, 47, 14 } -IDD_DIALOG_VIEW_TYPE DIALOG DISCARDABLE 15, 13, 161, 100 +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 "&Nom :",-1,7,8,22,10 + LTEXT "&Nom :",-1,7,8,22,10 EDITTEXT IDC_VIEW_PATTERN,31,7,63,12,ES_AUTOHSCROLL - GROUPBOX "Type de fichier ",-1,7,23,87,59 - CONTROL "&Répertoires",IDC_VIEW_TYPE_DIRECTORIES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,13,34,70,10 + 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,45,70,10 + BS_AUTOCHECKBOX | WS_TABSTOP,13,43,70,10 CONTROL "Docu&ments",IDC_VIEW_TYPE_DOCUMENTS,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,13,56,70,10 + BS_AUTOCHECKBOX | WS_TABSTOP,13,54,70,10 CONTROL "&Autres fichiers",IDC_VIEW_TYPE_OTHERS,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,13,67,70,10 - CONTROL "Montrer les fichiers cachés/&système",IDC_VIEW_TYPE_HIDDEN, - "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,86,130,9 + BS_AUTOCHECKBOX | WS_TABSTOP,13,65,70,10 + CONTROL "Montrer les fichiers cachés/&système",IDC_VIEW_TYPE_HIDDEN, + "Button",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" +CAPTION "Propriétés de %s" FONT 8, "MS Sans Serif" BEGIN DEFPUSHBUTTON "OK",IDOK,191,7,50,14 - PUSHBUTTON "Annuler",IDCANCEL,191,25,50,14 - LTEXT "Nom du &fichier :",-1,7,7,59,9 + 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 + 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 + 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 + 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 + 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 + 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 "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 "&Informations de version",-1,7,129,234,79 + 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 @@ -234,8 +229,8 @@ END STRINGTABLE { - IDS_FONT_SEL_DLG_NAME "Application des réglages des polices" - IDS_FONT_SEL_ERROR "Erreur lors de la sélection de la nouvelle police." + 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 @@ -247,7 +242,7 @@ STRINGTABLE IDS_DESKTOP "Bureau" IDS_SHELL "Shell" IDS_TITLEFMT "%s - %s" - IDS_NO_IMPL "Pas encore implémenté" + IDS_NO_IMPL "Pas encore implémenté" IDS_WINE_FILE "Wine File" } @@ -255,13 +250,13 @@ STRINGTABLE { IDS_COL_NAME "Nom" IDS_COL_SIZE "Taille" - IDS_COL_CDATE "Dernier changement de statut (ctime)" - IDS_COL_ADATE "Dernier accès" - IDS_COL_MDATE "Dernière modification" + 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_COL_SEC "Sécurité" IDS_FREE_SPACE_FMT "%s sur %s libre" } diff --git a/programs/winefile/Hu.rc b/programs/winefile/Hu.rc index f7ca49a2bbe..f73f376d875 100644 --- a/programs/winefile/Hu.rc +++ b/programs/winefile/Hu.rc @@ -22,8 +22,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT /* Menu */ diff --git a/programs/winefile/It.rc b/programs/winefile/It.rc index bfbf6f12f57..832d422742b 100644 --- a/programs/winefile/It.rc +++ b/programs/winefile/It.rc @@ -22,8 +22,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL /* Menu */ diff --git a/programs/winefile/Ja.rc b/programs/winefile/Ja.rc index b73486a5dd0..cd68b65a034 100644 --- a/programs/winefile/Ja.rc +++ b/programs/winefile/Ja.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -263,3 +261,5 @@ STRINGTABLE IDS_FREE_SPACE_FMT "%s of %s free" } + +#pragma code_page(default) diff --git a/programs/winefile/Ko.rc b/programs/winefile/Ko.rc index 0a6207a52ca..02821d068da 100644 --- a/programs/winefile/Ko.rc +++ b/programs/winefile/Ko.rc @@ -22,8 +22,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT /* Menu */ diff --git a/programs/winefile/Lt.rc b/programs/winefile/Lt.rc deleted file mode 100644 index 32cec0efea7..00000000000 --- a/programs/winefile/Lt.rc +++ /dev/null @@ -1,263 +0,0 @@ -/* - * WineFile - * Lithuanian Language Support - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -/* Menu */ - -IDM_WINEFILE MENU FIXED IMPURE -{ - POPUP "&Failas" { - MENUITEM "&Atverti\tEnter", ID_ACTIVATE - MENUITEM "Pe&rkelti...\tF7", ID_FILE_MOVE - MENUITEM "&Kopijuoti...\tF8", ID_FILE_COPY - MENUITEM "Iškarpin&ėje...\tF9", 118 - MENUITEM "&Šalinti\tDel", ID_FILE_DELETE - MENUITEM "Per&vadinti...", 109 - MENUITEM "Savy&bės...\tAlt+Enter", ID_EDIT_PROPERTIES - MENUITEM SEPARATOR - MENUITEM "&Glaudinti...", 119 - MENUITEM "Išsk&leisti...", 120 - MENUITEM SEPARATOR - MENUITEM "&Vykdyti...", ID_EXECUTE - MENUITEM "&Spausdinti...", 102 - MENUITEM "Susieti...", 103 - MENUITEM SEPARATOR - MENUITEM "Suk&urti katalogą...", 111 - MENUITEM "&Ieškoti...", 104 - MENUITEM "&Pažymėti failus...", 116 - MENUITEM SEPARATOR -#ifndef _NO_EXTENSIONS - MENUITEM "Iš&eiti\tAlt+X", ID_FILE_EXIT -#else - MENUITEM "Iš&eiti", ID_FILE_EXIT -#endif - } - - POPUP "&Diskas" { - MENUITEM "&Kopijuoti diską...", 201 - MENUITEM "&Pavadinti diską...", 202 - MENUITEM SEPARATOR - MENUITEM "&Ženklinti diską...", ID_FORMAT_DISK -#ifdef _WIN95 - MENUITEM "&Sukurti sisteminį diską...", -1 /*TODO*/ -#endif - MENUITEM SEPARATOR - MENUITEM "Pri&jungti tinklo diską", ID_CONNECT_NETWORK_DRIVE - MENUITEM "&Atjungti tinklo diską", ID_DISCONNECT_NETWORK_DRIVE - MENUITEM SEPARATOR - MENUITEM "&Bendrinti kaip...", 254 - MENUITEM "&Panaikinti bendrumą...", 255 - MENUITEM SEPARATOR - MENUITEM "&Išrinkti diską...", 251 - } - - POPUP "&Katalogai" { - MENUITEM "&Kitas lygis\t+", 301 - MENUITEM "Išskleisti &medį\t*", 302 - MENUITEM "Išskleisti &viską\tStrg+*", 303 - MENUITEM "Suskleisti m&edį\t-", 304 - MENUITEM SEPARATOR - MENUITEM "&Pažymėti vaikus", 505 - } - - POPUP "&Rodymas" { - MENUITEM "&Medis ir katalogai", 413 - MENUITEM "&Tik medis", 411 - MENUITEM "Tik &katalogai", 412 - MENUITEM SEPARATOR - MENUITEM "&Skaidyti", ID_VIEW_SPLIT - MENUITEM SEPARATOR - MENUITEM "&Vardas", ID_VIEW_NAME - MENUITEM "Visa failo &informacija", ID_VIEW_ALL_ATTRIBUTES, CHECKED - MENUITEM "&Dalinė informacija...", ID_VIEW_SELECTED_ATTRIBUTES - MENUITEM SEPARATOR - MENUITEM "&Rikiuoti pagal vardą", ID_VIEW_SORT_NAME - MENUITEM "Rikiuoti &pagal tipą", ID_VIEW_SORT_TYPE - MENUITEM "Rikiuoti pagal d&ydį", ID_VIEW_SORT_SIZE - MENUITEM "Rikiuoti pagal d&atą", ID_VIEW_SORT_DATE - MENUITEM SEPARATOR - MENUITEM "&Filtruoti pagal...", ID_VIEW_FILTER - } - - POPUP "&Parinktys" { - MENUITEM "&Patvirtinimas...", 501 - MENUITEM "&Šriftas...", ID_SELECT_FONT - MENUITEM "Adaptuoti įrankių &juostą...", 512 - MENUITEM SEPARATOR - MENUITEM "&Įrankių juosta", ID_VIEW_TOOL_BAR, CHECKED - MENUITEM "&Diskų juosta", ID_VIEW_DRIVE_BAR, CHECKED - MENUITEM "&Būsenos juosta", ID_VIEW_STATUSBAR, CHECKED -#ifndef _NO_EXTENSIONS - MENUITEM "&Visas ekranas\tCtrl+Shift+S", ID_VIEW_FULLSCREEN -#endif - MENUITEM SEPARATOR - MENUITEM "&Suskleisti vykdant", 504 - MENUITEM "&Išeinant išsaugoti nuostatas", ID_VIEW_SAVESETTINGS - } - - - POPUP "&Saugumas" { - MENUITEM "&Prieiga...", 605 - MENUITEM "&Registravimas...", 606 - MENUITEM "&Savininkas...", 607 - } - - POPUP "&Langas" { - MENUITEM "Naujas &langas", ID_WINDOW_NEW - MENUITEM "Išdėstyti pa&kopomis\tCtrl+F5", ID_WINDOW_CASCADE - MENUITEM "Iškloti &gulsčiai", ID_WINDOW_TILE_HORZ - MENUITEM "Iškloti &stačiai\tCtrl+F4", ID_WINDOW_TILE_VERT -#ifndef _NO_EXTENSIONS - MENUITEM "Išdėstyti &automatiškai", ID_WINDOW_AUTOSORT -#endif - MENUITEM "Išdėstyti si&mbolius", ID_WINDOW_ARRANGE - MENUITEM "At&naujinti\tF5", ID_REFRESH - } - - POPUP "&Žinynas" { - MENUITEM "Žinyno &temos\tF1", ID_HELP - MENUITEM "&Paieška žinyne...\tF1", ID_HELP - MENUITEM "Žinyno &naudojimas\tF1", ID_HELP_USING - MENUITEM SEPARATOR - MENUITEM "&Apie Winefile...", ID_ABOUT - } -} - - -IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Vykdyti" -FONT 8, "MS Shell Dlg" -{ - CONTROL "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10 - CONTROL "&Komanda:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10 - EDITTEXT 201, 3, 29, 134, 12, ES_AUTOHSCROLL - CONTROL "Kaip &simbolį", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12 - DEFPUSHBUTTON "Gerai", 1, 158, 6, 47, 14 - PUSHBUTTON "Atsisakyti", 2, 158, 23, 47, 14 - PUSHBUTTON "&Žinynas", 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 "Išrinkite paskirtį" -FONT 8, "MS Shell Dlg" -{ - CONTROL "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10 - CONTROL "&Kelias:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10 - EDITTEXT 201, 3, 29, 134, 12, ES_AUTOHSCROLL - DEFPUSHBUTTON "Gerai", 1, 158, 6, 47, 14 - PUSHBUTTON "Atsisakyti", 2, 158, 23, 47, 14 - PUSHBUTTON "&Parinkti", 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 "Pagal failo tipą" -FONT 8, "MS Sans Serif" -BEGIN - LTEXT "&Vardas:",-1,7,8,26,10 - EDITTEXT IDC_VIEW_PATTERN,35,7,59,12,ES_AUTOHSCROLL - GROUPBOX "Failų tipai",-1,7,23,87,56 - CONTROL "&Katalogai",IDC_VIEW_TYPE_DIRECTORIES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,13,32,70,10 - CONTROL "&Programos",IDC_VIEW_TYPE_PROGRAMS,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,13,43,70,10 - CONTROL "&Dokumentai",IDC_VIEW_TYPE_DOCUMENTS,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,13,54,70,10 - CONTROL "Kiti &failai",IDC_VIEW_TYPE_OTHERS,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,13,65,70,10 - CONTROL "Rodyti paslėptus/&sisteminius failus",IDC_VIEW_TYPE_HIDDEN, - "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,81,122,9 - DEFPUSHBUTTON "Gerai",IDOK,104,7,50,14 - PUSHBUTTON "Atsisakyti",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 "%s savybės" -FONT 8, "MS Sans Serif" -BEGIN - DEFPUSHBUTTON "Gerai",IDOK,191,7,50,14 - PUSHBUTTON "Atsisakyti",IDCANCEL,191,29,50,14 - LTEXT "&Failo vardas:",-1,7,7,59,9 - EDITTEXT IDC_STATIC_PROP_FILENAME,71,7,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP - LTEXT "Visas &kelias:",-1,7,18,59,9 - EDITTEXT IDC_STATIC_PROP_PATH,71,18,120,9, ES_READONLY | NOT WS_BORDER | WS_TABSTOP - LTEXT "Pask. keitimas:",-1,7,29,59,9 - EDITTEXT IDC_STATIC_PROP_LASTCHANGE,71,29,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP - LTEXT "Versija:",-1,7,40,59,9 - EDITTEXT IDC_STATIC_PROP_VERSION,71,40,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP - LTEXT "&Autoriaus teisės:",-1,7,51,59,9 - EDITTEXT IDC_STATIC_PROP_COPYRIGHT,71,51,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP - LTEXT "Dydis:",-1,7,62,59,9 - EDITTEXT IDC_STATIC_PROP_SIZE,71,62,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP - GROUPBOX "Požymiai",-1,7,79,158,46 - CONTROL "&Tik skaitymui",IDC_CHECK_READONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,91,68,9 - CONTROL "&Paslėptas",IDC_CHECK_HIDDEN,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,92,91,68,9 - CONTROL "&Archyvuotinas",IDC_CHECK_ARCHIVE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,101,68,9 - CONTROL "&Sisteminis",IDC_CHECK_SYSTEM,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,92,101,68,9 - CONTROL "Su&glaudintas",IDC_CHECK_COMPRESSED,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,17,111,68,9 - GROUPBOX "&Versijos informacija",-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 "Pritaikomos šrifto nuostatos" - IDS_FONT_SEL_ERROR "Klaida parenkant naują šriftą." -} - -STRINGTABLE -{ - IDS_WINEFILE "Wine failų tvarkytuvė" - IDS_ERROR "Klaida" - IDS_ROOT_FS "šakninė fs" - IDS_UNIXFS "unix fs" - IDS_DESKTOP "Darbalaukis" - IDS_SHELL "Apvalkalas" - IDS_TITLEFMT "%s - %s" - IDS_NO_IMPL "Dar nerealizuota" - IDS_WINE_FILE "Wine failas" -} - -STRINGTABLE -{ - IDS_COL_NAME "Vardas" - IDS_COL_SIZE "Dydis" - IDS_COL_CDATE "KData" - IDS_COL_ADATE "PData" - IDS_COL_MDATE "MData" - IDS_COL_IDX "Indeksas/Inode" - IDS_COL_LINKS "Saitai" - IDS_COL_ATTR "Požymiai" - IDS_COL_SEC "Saugumas" - - IDS_FREE_SPACE_FMT "%s iš %s laisva" -} diff --git a/programs/winefile/Makefile.in b/programs/winefile/Makefile.in index bd808b5908f..804e349de28 100644 --- a/programs/winefile/Makefile.in +++ b/programs/winefile/Makefile.in @@ -11,28 +11,7 @@ C_SRCS = \ splitpath.c \ winefile.c -RC_SRCS = \ - Cs.rc \ - Da.rc \ - De.rc \ - En.rc \ - Es.rc \ - Fr.rc \ - Hu.rc \ - It.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc \ - rsrc.rc +RC_SRCS = rsrc.rc SVG_SRCS = winefile.svg diff --git a/programs/winefile/Nl.rc b/programs/winefile/Nl.rc index 8f6f7f16825..06eef8e347b 100644 --- a/programs/winefile/Nl.rc +++ b/programs/winefile/Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL /* Menu */ diff --git a/programs/winefile/No.rc b/programs/winefile/No.rc index eec8b82c8f5..04f8509ad84 100644 --- a/programs/winefile/No.rc +++ b/programs/winefile/No.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL /* Menu */ diff --git a/programs/winefile/Pl.rc b/programs/winefile/Pl.rc index 50247e3181a..31316172f55 100644 --- a/programs/winefile/Pl.rc +++ b/programs/winefile/Pl.rc @@ -22,8 +22,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT /* Menu */ diff --git a/programs/winefile/Pt.rc b/programs/winefile/Pt.rc index d95b0d5b5ac..d23038dabeb 100644 --- a/programs/winefile/Pt.rc +++ b/programs/winefile/Pt.rc @@ -3,7 +3,7 @@ * Portuguese Language Support * * Copyright 2003 Marcelo Duarte - * Copyright 2004,2007 Américo José Melo + * Copyright 2004,2007 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 @@ -20,9 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) /* Menu */ @@ -75,18 +72,18 @@ IDM_WINEFILE MENU FIXED IMPURE MENUITEM "Selecionar &unidade...", 251 } - POPUP "Á&rvore" { - MENUITEM "&Próximo nível\t+", 301 + 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 + MENUITEM "&Indicar subníveis", 505 } POPUP "&Exibir" { - MENUITEM "Á&rvore e pasta", 413 - MENUITEM "S&omente árvore", 411 + MENUITEM "Á&rvore e pasta", 413 + MENUITEM "S&omente árvore", 411 MENUITEM "So&mente pasta", 412 MENUITEM SEPARATOR MENUITEM "&Dividir", ID_VIEW_SPLIT @@ -103,8 +100,8 @@ IDM_WINEFILE MENU FIXED IMPURE MENUITEM "Classificar &por...", ID_VIEW_FILTER } - POPUP "&Opções" { - MENUITEM "&Confirmação...", 501 + POPUP "&Opções" { + MENUITEM "&Confirmação...", 501 MENUITEM "&Fonte...", ID_SELECT_FONT MENUITEM "&Personalizar barra de ferramentas...", 512 MENUITEM SEPARATOR @@ -116,11 +113,11 @@ IDM_WINEFILE MENU FIXED IMPURE #endif MENUITEM SEPARATOR MENUITEM "&Minimizar durante o uso", 504 - MENUITEM "&Salvar configurações ao sair",511 + MENUITEM "&Salvar configurações ao sair",511 } - POPUP "&Segurança" { + POPUP "&Segurança" { MENUITEM "&Acesso...", 605 MENUITEM "&Logging...", 606 MENUITEM "&Owner...", 607 @@ -134,12 +131,12 @@ IDM_WINEFILE MENU FIXED IMPURE #ifndef _NO_EXTENSIONS MENUITEM "Organizar automaticamente", ID_WINDOW_AUTOSORT #endif - MENUITEM "&Organizar ícones", ID_WINDOW_ARRANGE + MENUITEM "&Organizar ícones", ID_WINDOW_ARRANGE MENUITEM "&Atualizar\tF5", ID_REFRESH } POPUP "Aj&uda" { - MENUITEM "&Tópicos da ajuda\tF1", ID_HELP + MENUITEM "&Tópicos da ajuda\tF1", ID_HELP MENUITEM "Pesquisar...", ID_HELP MENUITEM "&Usando a ajuda", ID_HELP_USING MENUITEM SEPARATOR @@ -155,7 +152,7 @@ IDM_WINEFILE MENU FIXED IMPURE MENUITEM "A&brir\tEnter", ID_ACTIVATE MENUITEM "&Mover...\tF7", ID_FILE_MOVE MENUITEM "&Copiar...\tF8", ID_FILE_COPY - MENUITEM "&Na Area de Transferência...\tF9", 118 + MENUITEM "&Na Area de Transferência...\tF9", 118 MENUITEM "E&xcluir\tDel", ID_FILE_DELETE MENUITEM "Re&nomear...", 109 MENUITEM "&Propriedades...\tAlt+Enter", ID_EDIT_PROPERTIES @@ -196,18 +193,18 @@ IDM_WINEFILE MENU FIXED IMPURE MENUITEM "Seleccionar &unidade...", 251 } - POPUP "Á&rvore" { - MENUITEM "&Próximo nível\t+", 301 + 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 + MENUITEM "&Indicar subníveis", 505 } POPUP "&Exibir" { - MENUITEM "Á&rvore e pasta", 413 - MENUITEM "A&penas árvore", 411 + MENUITEM "Á&rvore e pasta", 413 + MENUITEM "A&penas árvore", 411 MENUITEM "Ap&enas pasta", 412 MENUITEM SEPARATOR MENUITEM "&Dividir", ID_VIEW_SPLIT @@ -224,8 +221,8 @@ IDM_WINEFILE MENU FIXED IMPURE MENUITEM "Classificar &por...", ID_VIEW_FILTER } - POPUP "&Opções" { - MENUITEM "&Confirmação...", 501 + POPUP "&Opções" { + MENUITEM "&Confirmação...", 501 MENUITEM "&Tipo de Letra...", ID_SELECT_FONT MENUITEM "&Personalizar barra de ferramentas...", 512 MENUITEM SEPARATOR @@ -233,17 +230,17 @@ IDM_WINEFILE MENU FIXED IMPURE MENUITEM "&Barra de unidades", ID_VIEW_DRIVE_BAR, CHECKED MENUITEM "B&arra de e&stado", ID_VIEW_STATUSBAR, CHECKED #ifndef _NO_EXTENSIONS - MENUITEM "Ecrã Completo\tCtrl+Shift+S", ID_VIEW_FULLSCREEN + MENUITEM "Ecrã Completo\tCtrl+Shift+S", ID_VIEW_FULLSCREEN #endif MENUITEM SEPARATOR MENUITEM "&Minimizar durante o uso", 504 - MENUITEM "&Gravar configurações ao sair",511 + MENUITEM "&Gravar configurações ao sair",511 } - POPUP "&Segurança" { + POPUP "&Segurança" { MENUITEM "&Acesso...", 605 - MENUITEM "&Autenticação...", 606 + MENUITEM "&Autenticação...", 606 MENUITEM "&Dono...", 607 } @@ -255,12 +252,12 @@ IDM_WINEFILE MENU FIXED IMPURE #ifndef _NO_EXTENSIONS MENUITEM "Organizar automaticamente", ID_WINDOW_AUTOSORT #endif - MENUITEM "&Organizar ícones", ID_WINDOW_ARRANGE + MENUITEM "&Organizar ícones", ID_WINDOW_ARRANGE MENUITEM "&Actualizar\tF5", ID_REFRESH } POPUP "Aj&uda" { - MENUITEM "&Tópicos da ajuda\tF1", ID_HELP + MENUITEM "&Tópicos da ajuda\tF1", ID_HELP MENUITEM "Pesquisar...", ID_HELP MENUITEM "&Usar a ajuda", ID_HELP_USING MENUITEM SEPARATOR @@ -305,74 +302,23 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE IDD_SELECT_DESTINATION DIALOG FIXED IMPURE 15, 13, 210, 63 STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Seleccionar destino" +CAPTION "Selecionar destino" FONT 8, "MS Shell Dlg" { CONTROL "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10 - CONTROL "&Localização:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10 + CONTROL "&Localização:", -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 } -IDD_DIALOG_VIEW_TYPE DIALOG DISCARDABLE 15, 13, 161, 97 -STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Por tipo de ficheiro" -FONT 8, "MS Sans Serif" -BEGIN - LTEXT "&Nome:",-1,7,8,22,10 - EDITTEXT IDC_VIEW_PATTERN,31,7,63,12,ES_AUTOHSCROLL - GROUPBOX "Tipo de ficheiro",-1,7,23,87,56 - CONTROL "&Directórios",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 "&Outros ficheiros",IDC_VIEW_TYPE_OTHERS,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,13,65,70,10 - CONTROL "&Mostrar ficheiros ocultos/sistema",IDC_VIEW_TYPE_HIDDEN, - "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,81,106,9 - DEFPUSHBUTTON "OK",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 "Propriedades de %s" -FONT 8, "MS Sans Serif" -BEGIN - DEFPUSHBUTTON "OK",IDOK,191,7,50,14 - PUSHBUTTON "Cancelar",IDCANCEL,191,29,50,14 - LTEXT "&Nome do ficheiro:",-1,7,7,59,9 - EDITTEXT IDC_STATIC_PROP_FILENAME,71,7,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP - LTEXT "&Localização Completa:",-1,7,18,59,9 - EDITTEXT IDC_STATIC_PROP_PATH,71,18,120,9, ES_READONLY | NOT WS_BORDER | WS_TABSTOP - LTEXT "Última alteração:",-1,7,29,59,9 - EDITTEXT IDC_STATIC_PROP_LASTCHANGE,71,29,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP - LTEXT "Versão:",-1,7,40,59,9 - EDITTEXT IDC_STATIC_PROP_VERSION,71,40,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP - LTEXT "Direitos de autor:",-1,7,51,59,9 - EDITTEXT IDC_STATIC_PROP_COPYRIGHT,71,51,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP - LTEXT "Tamanho:",-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 "&Apenas de leitura",IDC_CHECK_READONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,91,68,9 - CONTROL "&Ocultos",IDC_CHECK_HIDDEN,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,92,91,68,9 - CONTROL "&Arquivos",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 "&Comprimidos",IDC_CHECK_COMPRESSED,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,17,111,68,9 - GROUPBOX "&Informação de versão",-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 LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE { - IDS_FONT_SEL_DLG_NAME "Aplicando configurações de fonte" + IDS_FONT_SEL_DLG_NAME "Aplicando configurações de fonte" IDS_FONT_SEL_ERROR "Erro enquanto seleciona nova fonte." } @@ -380,12 +326,12 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE STRINGTABLE { - IDS_FONT_SEL_DLG_NAME "A aplicar configurações do tipo de letra" + IDS_FONT_SEL_DLG_NAME "A aplicar configurações do tipo de letra" IDS_FONT_SEL_ERROR "Erro ao seleccionar novo tipo de letra." } -LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE { @@ -393,24 +339,47 @@ STRINGTABLE IDS_ERROR "Erro" IDS_ROOT_FS "root fs" IDS_UNIXFS "unixfs" - IDS_DESKTOP "Área de trabalho" - IDS_SHELL "Linha de comandos" + IDS_DESKTOP "Área de trabalho" + IDS_SHELL "Shell" IDS_TITLEFMT "%s - %s" - IDS_NO_IMPL "Ainda não implementado" - IDS_WINE_FILE "Ficheiro Wine" + IDS_NO_IMPL "Ainda não implementado" + IDS_WINE_FILE "Wine File" + IDS_COL_NAME "Nome" + IDS_COL_SIZE "Tamanho" + IDS_COL_CDATE "CData" + IDS_COL_ADATE "AData" + IDS_COL_MDATE "MData" + IDS_COL_IDX "Índice/Inode" } +LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE + STRINGTABLE { + IDS_WINEFILE "Winefile" + IDS_ERROR "Erro" + IDS_ROOT_FS "root fs" + IDS_UNIXFS "unixfs" + IDS_DESKTOP "Ecrã" + IDS_SHELL "Linha de Comandos" + IDS_TITLEFMT "%s - %s" + IDS_NO_IMPL "Ainda não implementado" + IDS_WINE_FILE "Ficheiro Wine" IDS_COL_NAME "Nome" IDS_COL_SIZE "Tamanho" IDS_COL_CDATE "CData" IDS_COL_ADATE "AData" IDS_COL_MDATE "MData" - IDS_COL_IDX "Índice/Inode" - IDS_COL_LINKS "Ligações" + IDS_COL_IDX "Índice/Inode" +} + +LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL + +STRINGTABLE +{ + IDS_COL_LINKS "Ligações" IDS_COL_ATTR "Atributos" - IDS_COL_SEC "Segurança" + IDS_COL_SEC "Segurança" - IDS_FREE_SPACE_FMT "%s de %s livre" + IDS_FREE_SPACE_FMT "%s of %s free" } diff --git a/programs/winefile/Ru.rc b/programs/winefile/Ru.rc dissimilarity index 66% index 6969f360e10..dd07152b491 100644 --- a/programs/winefile/Ru.rc +++ b/programs/winefile/Ru.rc @@ -1,262 +1,257 @@ -/* - * WineFile (Russian resources) - * - * Copyright 2003 Igor Stepin - * Copyright 2007 Konstantin Kondratyuk (Etersoft) - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT - -/* 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 - } -} - - -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 -} -IDD_SELECT_DESTINATION 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 - DEFPUSHBUTTON "OK", 1, 158, 6, 47, 14 - PUSHBUTTON "Отмена", 2, 158, 23, 47, 14 - PUSHBUTTON "&Обзор", 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 "По типу файлов" -FONT 8, "MS Sans Serif" -BEGIN - LTEXT "&Имя:",-1,7,8,22,10 - EDITTEXT IDC_VIEW_PATTERN,31,7,63,12,ES_AUTOHSCROLL - GROUPBOX "Тип файла",-1,7,23,87,56 - CONTROL "&Каталоги",IDC_VIEW_TYPE_DIRECTORIES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,13,32,70,10 - CONTROL "&Программы",IDC_VIEW_TYPE_PROGRAMS,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,13,43,70,10 - CONTROL "&Документы",IDC_VIEW_TYPE_DOCUMENTS,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,13,54,70,10 - CONTROL "Другие &файлы",IDC_VIEW_TYPE_OTHERS,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,13,65,70,10 - CONTROL "Показать скрытые/&системные файлы",IDC_VIEW_TYPE_HIDDEN, - "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,81,106,9 - DEFPUSHBUTTON "OK",IDOK,104,7,50,14 - PUSHBUTTON "Отмена",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 "Свойства %s" -FONT 8, "MS Sans Serif" -BEGIN - DEFPUSHBUTTON "OK",IDOK,191,7,50,14 - PUSHBUTTON "Отмена",IDCANCEL,191,29,50,14 - LTEXT "Имя &файла:",-1,7,7,59,9 - EDITTEXT IDC_STATIC_PROP_FILENAME,71,7,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP - LTEXT "&Полный путь:",-1,7,18,59,9 - EDITTEXT IDC_STATIC_PROP_PATH,71,18,120,9, ES_READONLY | NOT WS_BORDER | WS_TABSTOP - LTEXT "Последнее изменение:",-1,7,29,59,9 - EDITTEXT IDC_STATIC_PROP_LASTCHANGE,71,29,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP - LTEXT "Версия:",-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 "Размер:",-1,7,62,59,9 - EDITTEXT IDC_STATIC_PROP_SIZE,71,62,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP - GROUPBOX "Атрибуты",-1,7,79,158,46 - CONTROL "&Только для чтения",IDC_CHECK_READONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,91,68,9 - CONTROL "С&крытый",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 "&Системный",IDC_CHECK_SYSTEM,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,92,101,68,9 - CONTROL "С&жатый",IDC_CHECK_COMPRESSED,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,17,111,68,9 - GROUPBOX "&Информация о версии",-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 "Применение параметров настройки шрифта" - IDS_FONT_SEL_ERROR "Ошибка при выборе нового шрифта." -} - -STRINGTABLE -{ - IDS_WINEFILE "Winefile" - IDS_ERROR "Ошибка" - IDS_ROOT_FS "Корневая файловая система" - IDS_UNIXFS "Основная файловая система" - IDS_DESKTOP "Рабочий стол" - IDS_SHELL "Shell" - IDS_TITLEFMT "%s - %s" - IDS_NO_IMPL "Ещё не реализовано" - IDS_WINE_FILE "Wine File" -} - -STRINGTABLE -{ - IDS_COL_NAME "Имя" - IDS_COL_SIZE "Размер" - IDS_COL_CDATE "Дата создания" - IDS_COL_ADATE "Дата последнего доступа" - IDS_COL_MDATE "Дата последнего изменения" - IDS_COL_IDX "Index/Inode" - IDS_COL_LINKS "Ссылки" - IDS_COL_ATTR "Атрибуты" - IDS_COL_SEC "Безопасность" - - IDS_FREE_SPACE_FMT "%s из %s свободно" -} +/* + * WineFile (Russian resources) + * + * Copyright 2003 Igor Stepin + * Copyright 2007 Konstantin Kondratyuk (Etersoft) + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT + +/* 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 + } +} + + +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 +} +IDD_SELECT_DESTINATION 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 + DEFPUSHBUTTON "OK", 1, 158, 6, 47, 14 + PUSHBUTTON "Îòìåíà", 2, 158, 23, 47, 14 + PUSHBUTTON "&Îáçîð", 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 "Ïî òèïó ôàéëîâ" +FONT 8, "MS Sans Serif" +BEGIN + LTEXT "&Èìÿ:",-1,7,8,22,10 + EDITTEXT IDC_VIEW_PATTERN,31,7,63,12,ES_AUTOHSCROLL + GROUPBOX "Òèï ôàéëà",-1,7,23,87,56 + CONTROL "&Êàòàëîãè",IDC_VIEW_TYPE_DIRECTORIES,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,13,32,70,10 + CONTROL "&Ïðîãðàììû",IDC_VIEW_TYPE_PROGRAMS,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,13,43,70,10 + CONTROL "&Äîêóìåíòû",IDC_VIEW_TYPE_DOCUMENTS,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,13,54,70,10 + CONTROL "Äðóãèå &ôàéëû",IDC_VIEW_TYPE_OTHERS,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,13,65,70,10 + CONTROL "Ïîêàçàòü ñêðûòûå/&ñèñòåìíûå ôàéëû",IDC_VIEW_TYPE_HIDDEN, + "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,81,106,9 + DEFPUSHBUTTON "OK",IDOK,104,7,50,14 + PUSHBUTTON "Îòìåíà",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 "Ñâîéñòâà %s" +FONT 8, "MS Sans Serif" +BEGIN + DEFPUSHBUTTON "OK",IDOK,191,7,50,14 + PUSHBUTTON "Îòìåíà",IDCANCEL,191,29,50,14 + LTEXT "Èìÿ &ôàéëà:",-1,7,7,59,9 + EDITTEXT IDC_STATIC_PROP_FILENAME,71,7,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP + LTEXT "&Ïîëíûé ïóòü:",-1,7,18,59,9 + EDITTEXT IDC_STATIC_PROP_PATH,71,18,120,9, ES_READONLY | NOT WS_BORDER | WS_TABSTOP + LTEXT "Ïîñëåäíåå èçìåíåíèå:",-1,7,29,59,9 + EDITTEXT IDC_STATIC_PROP_LASTCHANGE,71,29,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP + LTEXT "Âåðñèÿ:",-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 "Ðàçìåð:",-1,7,62,59,9 + EDITTEXT IDC_STATIC_PROP_SIZE,71,62,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP + GROUPBOX "Àòðèáóòû",-1,7,79,158,46 + CONTROL "&Òîëüêî äëÿ ÷òåíèÿ",IDC_CHECK_READONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,91,68,9 + CONTROL "Ñ&êðûòûé",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 "&Ñèñòåìíûé",IDC_CHECK_SYSTEM,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,92,101,68,9 + CONTROL "Ñ&æàòûé",IDC_CHECK_COMPRESSED,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,17,111,68,9 + GROUPBOX "&Èíôîðìàöèÿ î âåðñèè",-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 "Ïðèìåíåíèå ïàðàìåòðîâ íàñòðîéêè øðèôòà" + IDS_FONT_SEL_ERROR "Îøèáêà ïðè âûáîðå íîâîãî øðèôòà." +} + +STRINGTABLE +{ + IDS_WINEFILE "Winefile" + IDS_ERROR "Îøèáêà" + IDS_ROOT_FS "Êîðíåâàÿ ôàéëîâàÿ ñèñòåìà" + IDS_UNIXFS "Îñíîâíàÿ ôàéëîâàÿ ñèñòåìà" + IDS_DESKTOP "Ðàáî÷èé ñòîë" + IDS_SHELL "Shell" + IDS_TITLEFMT "%s - %s" + IDS_NO_IMPL "Åù¸ íå ðåàëèçîâàíî" + IDS_WINE_FILE "Wine File" +} + +STRINGTABLE +{ + IDS_COL_NAME "Èìÿ" + IDS_COL_SIZE "Ðàçìåð" + IDS_COL_CDATE "Äàòà ñîçäàíèÿ" + IDS_COL_ADATE "Äàòà ïîñëåäíåãî äîñòóïà" + IDS_COL_MDATE "Äàòà ïîñëåäíåãî èçìåíåíèÿ" + IDS_COL_IDX "Index/Inode" + IDS_COL_LINKS "Ññûëêè" + IDS_COL_ATTR "Àòðèáóòû" + IDS_COL_SEC "Áåçîïàñíîñòü" + + IDS_FREE_SPACE_FMT "%s èç %s ñâîáîäíî" +} diff --git a/programs/winefile/Si.rc b/programs/winefile/Si.rc index 2010f5912aa..5aa006d9f40 100644 --- a/programs/winefile/Si.rc +++ b/programs/winefile/Si.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -260,3 +258,5 @@ STRINGTABLE IDS_FREE_SPACE_FMT "Prosto: %s od %s" } + +#pragma code_page(default) diff --git a/programs/winefile/Sv.rc b/programs/winefile/Sv.rc index 4deddd953a0..6905c5e0713 100644 --- a/programs/winefile/Sv.rc +++ b/programs/winefile/Sv.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL /* Menu */ diff --git a/programs/winefile/Tr.rc b/programs/winefile/Tr.rc index 8735264ceb8..3a75a7e001f 100644 --- a/programs/winefile/Tr.rc +++ b/programs/winefile/Tr.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT /* Menu */ diff --git a/programs/winefile/Zh.rc b/programs/winefile/Zh.rc index 8eb3300cc3f..aba7221c19d 100644 --- a/programs/winefile/Zh.rc +++ b/programs/winefile/Zh.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -300,3 +298,5 @@ FONT 9, "MS Shell Dlg" PUSHBUTTON "取消", 2, 158, 23, 47, 14 PUSHBUTTON "幫助(&H)", 254, 158, 43, 47, 14 } + +#pragma code_page(default) diff --git a/programs/winefile/resource.h b/programs/winefile/resource.h index 7c14871d31c..1e843e52b39 100644 --- a/programs/winefile/resource.h +++ b/programs/winefile/resource.h @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include /* images */ diff --git a/programs/winefile/rsrc.rc b/programs/winefile/rsrc.rc index c921271969e..d331ad6e8c0 100644 --- a/programs/winefile/rsrc.rc +++ b/programs/winefile/rsrc.rc @@ -16,6 +16,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include +#include + #include "resource.h" /* define language neutral resources */ @@ -49,3 +52,25 @@ IDB_DRIVEBAR BITMAP DISCARDABLE drivebar.bmp /* @makedep: images.bmp */ IDB_IMAGES BITMAP DISCARDABLE images.bmp + +/* include localised resources */ + +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Es.rc" +#include "Fr.rc" +#include "Hu.rc" +#include "It.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" diff --git a/programs/winemenubuilder/winemenubuilder.c b/programs/winemenubuilder/winemenubuilder.c index 15ce483f287..cd3506bec0f 100644 --- a/programs/winemenubuilder/winemenubuilder.c +++ b/programs/winemenubuilder/winemenubuilder.c @@ -692,20 +692,11 @@ static unsigned short crc16(const char* string) return crc; } -static char *strdupA( const char *str ) -{ - char *ret; - - if (!str) return NULL; - if ((ret = HeapAlloc( GetProcessHeap(), 0, strlen(str) + 1 ))) strcpy( ret, str ); - return ret; -} - static char* heap_printf(const char *format, ...) { va_list args; int size = 4096; - char *buffer, *ret; + char *buffer; int n; va_start(args, format); @@ -724,9 +715,7 @@ static char* heap_printf(const char *format, ...) HeapFree(GetProcessHeap(), 0, buffer); } va_end(args); - ret = HeapReAlloc(GetProcessHeap(), 0, buffer, strlen(buffer) + 1 ); - if (!ret) ret = buffer; - return ret; + return buffer; } static BOOL create_directories(char *directory) @@ -750,7 +739,7 @@ static BOOL create_directories(char *directory) } /* extract an icon from an exe or icon file; helper for IPersistFile_fnSave */ -static char *extract_icon( LPCWSTR path, int index, const char *destFilename, BOOL bWait ) +static char *extract_icon( LPCWSTR path, int index, BOOL bWait ) { unsigned short crc; char *iconsdir = NULL, *ico_path = NULL, *ico_name, *xpm_path = NULL; @@ -796,32 +785,18 @@ static char *extract_icon( LPCWSTR path, int index, const char *destFilename, BO crc=crc16(ico_path); /* Try to treat the source file as an exe */ - if (destFilename) - xpm_path=heap_printf("%s/%s.png",iconsdir,destFilename); - else - xpm_path=heap_printf("%s/%04x_%s.%d.png",iconsdir,crc,ico_name,index); - if (xpm_path == NULL) - { - WINE_ERR("could not extract icon %s, out of memory\n", wine_dbgstr_a(ico_name)); - return NULL; - } - + xpm_path=HeapAlloc(GetProcessHeap(), 0, strlen(iconsdir)+1+4+1+strlen(ico_name)+1+12+1+3); + sprintf(xpm_path,"%s/%04x_%s.%d.png",iconsdir,crc,ico_name,index); if (ExtractFromEXEDLL( path, index, xpm_path )) goto end; /* Must be something else, ignore the index in that case */ - if (destFilename) - sprintf(xpm_path,"%s/%s.png",iconsdir,destFilename); - else - sprintf(xpm_path,"%s/%04x_%s.png",iconsdir,crc,ico_name); + sprintf(xpm_path,"%s/%04x_%s.png",iconsdir,crc,ico_name); if (ExtractFromICO( path, xpm_path)) goto end; if (!bWait) { - if (destFilename) - sprintf(xpm_path,"%s/%s.xpm",iconsdir,destFilename); - else - sprintf(xpm_path,"%s/%04x_%s.xpm",iconsdir,crc,ico_name); + sprintf(xpm_path,"%s/%04x_%s.xpm",iconsdir,crc,ico_name); if (create_default_icon( xpm_path, ico_path )) goto end; } @@ -931,10 +906,10 @@ static BOOL write_menu_file(const char *unix_link, const char *filename) while (1) { - tempfilename = heap_printf("%s/wine-menu-XXXXXX", xdg_config_dir); + tempfilename = tempnam(xdg_config_dir, "_wine"); if (tempfilename) { - int tempfd = mkstemps(tempfilename, 0); + int tempfd = open(tempfilename, O_EXCL | O_CREAT | O_WRONLY, 0666); if (tempfd >= 0) { tempfile = fdopen(tempfd, "w"); @@ -945,10 +920,10 @@ static BOOL write_menu_file(const char *unix_link, const char *filename) } else if (errno == EEXIST) { - HeapFree(GetProcessHeap(), 0, tempfilename); + free(tempfilename); continue; } - HeapFree(GetProcessHeap(), 0, tempfilename); + free(tempfilename); } return FALSE; } @@ -1006,7 +981,7 @@ end: ret = (rename(tempfilename, menuPath) == 0); if (!ret && tempfilename) remove(tempfilename); - HeapFree(GetProcessHeap(), 0, tempfilename); + free(tempfilename); if (ret) { HKEY hkey = open_menus_reg_key(); @@ -1440,8 +1415,8 @@ static BOOL add_mimes(const char *xdg_data_dir, struct list *mime_types) if (mime_type_entry) { *pos = 0; - mime_type_entry->mimeType = strdupA(line); - mime_type_entry->glob = strdupA(pos + 1); + mime_type_entry->mimeType = heap_printf("%s", line); + mime_type_entry->glob = heap_printf("%s", pos + 1); if (mime_type_entry->mimeType && mime_type_entry->glob) list_add_tail(mime_types, &mime_type_entry->entry); else @@ -1491,7 +1466,7 @@ static BOOL build_native_mime_types(const char *xdg_data_home, struct list **mim if (xdg_data_dirs == NULL) xdg_data_dirs = heap_printf("/usr/local/share/:/usr/share/"); else - xdg_data_dirs = strdupA(xdg_data_dirs); + xdg_data_dirs = heap_printf("%s", xdg_data_dirs); if (xdg_data_dirs) { @@ -1554,7 +1529,7 @@ static BOOL match_glob(struct list *native_mime_types, const char *extension, if (*match != NULL) { - *match = strdupA(*match); + *match = heap_printf("%s", *match); if (*match == NULL) return FALSE; } @@ -1717,7 +1692,6 @@ static void update_association(LPCWSTR extension, LPCSTR mimeType, LPCWSTR progI static BOOL cleanup_associations(void) { - static const WCHAR openW[] = {'o','p','e','n',0}; HKEY assocKey; BOOL hasChanged = FALSE; if ((assocKey = open_associations_reg_key())) @@ -1755,7 +1729,7 @@ static BOOL cleanup_associations(void) done = TRUE; goto end; } - command = assoc_query(ASSOCSTR_COMMAND, extensionW, openW); + command = assoc_query(ASSOCSTR_COMMAND, extensionW, NULL); if (command == NULL) { char *desktopFile = reg_get_valA(assocKey, extensionA, "DesktopFile"); @@ -1867,7 +1841,6 @@ static BOOL write_freedesktop_association_entry(const char *desktopPath, const c static BOOL generate_associations(const char *xdg_data_home, const char *packages_dir, const char *applications_dir) { - static const WCHAR openW[] = {'o','p','e','n',0}; struct list *nativeMimeTypes = NULL; LSTATUS ret = 0; int i; @@ -1932,6 +1905,17 @@ static BOOL generate_associations(const char *xdg_data_home, const char *package } iconW = assoc_query(ASSOCSTR_DEFAULTICON, extensionW, NULL); + if (iconW) + { + WCHAR *comma = strrchrW(iconW, ','); + int index = 0; + if (comma) + { + *comma = 0; + index = atoiW(comma + 1); + } + iconA = extract_icon(iconW, index, FALSE); + } contentTypeW = assoc_query(ASSOCSTR_CONTENTTYPE, extensionW, NULL); @@ -1950,19 +1934,18 @@ static BOOL generate_associations(const char *xdg_data_home, const char *package /* Gnome seems to ignore the tag in MIME packages, * and the default name is more intuitive anyway. */ - if (iconW) + if (iconA) { char *flattened_mime = slashes_to_minuses(mimeTypeA); if (flattened_mime) { - int index = 0; - WCHAR *comma = strrchrW(iconW, ','); - if (comma) + char *dstIconPath = heap_printf("%s/icons/%s%s", xdg_data_dir, + flattened_mime, strrchr(iconA, '.')); + if (dstIconPath) { - *comma = 0; - index = atoiW(comma + 1); + rename(iconA, dstIconPath); + HeapFree(GetProcessHeap(), 0, dstIconPath); } - iconA = extract_icon(iconW, index, flattened_mime, FALSE); HeapFree(GetProcessHeap(), 0, flattened_mime); } } @@ -1977,7 +1960,7 @@ static BOOL generate_associations(const char *xdg_data_home, const char *package } } - commandW = assoc_query(ASSOCSTR_COMMAND, extensionW, openW); + commandW = assoc_query(ASSOCSTR_COMMAND, extensionW, NULL); if (commandW == NULL) /* no command => no application is associated */ goto end; @@ -2113,9 +2096,9 @@ static BOOL InvokeShellLinker( IShellLinkW *sl, LPCWSTR link, BOOL bWait ) /* extract the icon */ if( szIconPath[0] ) - icon_name = extract_icon( szIconPath , iIconId, NULL, bWait ); + icon_name = extract_icon( szIconPath , iIconId, bWait ); else - icon_name = extract_icon( szPath, iIconId, NULL, bWait ); + icon_name = extract_icon( szPath, iIconId, bWait ); /* fail - try once again after parent process exit */ if( !icon_name ) @@ -2540,16 +2523,29 @@ static void RefreshFileTypeAssociations(void) hasChanged |= cleanup_associations(); if (hasChanged) { - const char *argv[3]; - - argv[0] = "update-mime-database"; - argv[1] = mime_dir; - argv[2] = NULL; - spawnvp( _P_NOWAIT, argv[0], argv ); + char *command = heap_printf("update-mime-database %s", mime_dir); + if (command) + { + system(command); + HeapFree(GetProcessHeap(), 0, command); + } + else + { + WINE_ERR("out of memory\n"); + goto end; + } - argv[0] = "update-desktop-database"; - argv[1] = applications_dir; - spawnvp( _P_NOWAIT, argv[0], argv ); + command = heap_printf("update-desktop-database %s/applications", xdg_data_dir); + if (command) + { + system(command); + HeapFree(GetProcessHeap(), 0, command); + } + else + { + WINE_ERR("out of memory\n"); + goto end; + } } end: @@ -2675,7 +2671,7 @@ static BOOL init_xdg(void) { create_directories(xdg_config_dir); if (getenv("XDG_DATA_HOME")) - xdg_data_dir = strdupA(getenv("XDG_DATA_HOME")); + xdg_data_dir = heap_printf("%s", getenv("XDG_DATA_HOME")); else xdg_data_dir = heap_printf("%s/.local/share", getenv("HOME")); if (xdg_data_dir) @@ -2718,12 +2714,12 @@ int PASCAL WinMain (HINSTANCE hInstance, HINSTANCE prev, LPSTR cmdline, int show if( !lstrcmpA( token, "-a" ) ) { RefreshFileTypeAssociations(); - continue; + break; } if( !lstrcmpA( token, "-r" ) ) { cleanup_menus(); - continue; + break; } if( !lstrcmpA( token, "-w" ) ) bWait = TRUE; diff --git a/programs/winemine/Cs.rc b/programs/winemine/Cs.rc index bfe977016d3..c4f3cc33a63 100644 --- a/programs/winemine/Cs.rc +++ b/programs/winemine/Cs.rc @@ -22,8 +22,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ diff --git a/programs/winemine/Da.rc b/programs/winemine/Da.rc index 2027e7642db..3e5631fc0c6 100644 --- a/programs/winemine/Da.rc +++ b/programs/winemine/Da.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT STRINGTABLE { diff --git a/programs/winemine/De.rc b/programs/winemine/De.rc index 0b8fcc5026e..d1066f9f208 100644 --- a/programs/winemine/De.rc +++ b/programs/winemine/De.rc @@ -19,10 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE { @@ -38,16 +34,16 @@ MENU_WINEMINE MENU DISCARDABLE MENUITEM SEPARATOR MENUITEM "&Merker", IDM_MARKQ MENUITEM SEPARATOR - MENUITEM "&Anfänger", IDM_BEGINNER + MENUITEM "&Anfänger", IDM_BEGINNER MENUITEM "&Fortgeschrittene", IDM_ADVANCED MENUITEM "&Experten", IDM_EXPERT - MENUITEM "Benutzer&definiert...", IDM_CUSTOM + MENUITEM "Benutzer&definiert", IDM_CUSTOM MENUITEM SEPARATOR MENUITEM "&Beenden\tAlt+X", IDM_EXIT } POPUP "&Info" { MENUITEM "&Beste Zeiten", IDM_TIMES - MENUITEM "&Über", IDM_ABOUT + MENUITEM "&Über", IDM_ABOUT } } @@ -57,7 +53,7 @@ STYLE DS_MODALFRAME | DS_3DLOOK | CAPTION "Beste Zeiten" { GROUPBOX "Beste Zeiten", -1, 10, 10, 140, 45 - LTEXT "Anfänger", -1, 20, 20, 40, 8 + LTEXT "Anfänger", -1, 20, 20, 40, 8 LTEXT "Fortgeschrittene", -1, 20, 30, 40, 8 LTEXT "Experten", -1, 20, 40, 40, 8 LTEXT "999", IDC_TIME1, 70, 20, 15, 8 @@ -72,7 +68,7 @@ CAPTION "Beste Zeiten" DLG_CONGRATS DIALOG DISCARDABLE 0, 0, 160, 60 STYLE DS_MODALFRAME | DS_3DLOOK | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_POPUP -CAPTION "Herzlichen Glückwunsch!" +CAPTION "Herzlichen Glückwunsch!" { LTEXT "Bitte geben Sie Ihren Namen ein", -1, 10, 10, 150, 10 EDITTEXT IDC_EDITNAME, 25, 20, 110, 12 diff --git a/programs/winemine/En.rc b/programs/winemine/En.rc index dfb37e5c7c3..c0f2550415b 100644 --- a/programs/winemine/En.rc +++ b/programs/winemine/En.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE { @@ -40,12 +38,12 @@ MENU_WINEMINE MENU DISCARDABLE MENUITEM "&Beginner", IDM_BEGINNER MENUITEM "&Advanced", IDM_ADVANCED MENUITEM "&Expert", IDM_EXPERT - MENUITEM "&Custom...", IDM_CUSTOM + MENUITEM "&Custom", IDM_CUSTOM MENUITEM SEPARATOR MENUITEM "E&xit\tAlt+X", IDM_EXIT } POPUP "&Info" { - MENUITEM "&Fastest Times...", IDM_TIMES + MENUITEM "&Fastest Times", IDM_TIMES MENUITEM "&About", IDM_ABOUT } } diff --git a/programs/winemine/Es.rc b/programs/winemine/Es.rc index 0b08162359b..c36b522bc9b 100644 --- a/programs/winemine/Es.rc +++ b/programs/winemine/Es.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL STRINGTABLE { diff --git a/programs/winemine/Fi.rc b/programs/winemine/Fi.rc index 6252d2cca5a..ceee60399a7 100644 --- a/programs/winemine/Fi.rc +++ b/programs/winemine/Fi.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT STRINGTABLE { diff --git a/programs/winemine/Fr.rc b/programs/winemine/Fr.rc index 6ab5b23403b..e2a9372b053 100644 --- a/programs/winemine/Fr.rc +++ b/programs/winemine/Fr.rc @@ -4,8 +4,8 @@ * * Copyright 2000 Joshua Thielen * Copyright 2003 Marcelo Duarte - * Copyright 2003 Vincent Béron - * Copyright 2006 Jonathan Ernst + * Copyright 2003 Vincent Béron + * Copyright 2006 Jonathan Ernst * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -22,15 +22,10 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL STRINGTABLE { - IDS_APPNAME, "Démineur de Wine" + IDS_APPNAME, "Démineur Wine" IDS_NOBODY, "Anonyme" IDS_ABOUT, "Copyright 2000 Joshua Thielen" } @@ -40,29 +35,29 @@ MENU_WINEMINE MENU DISCARDABLE POPUP "&Options" { MENUITEM "&Nouveau\tF2", IDM_NEW MENUITEM SEPARATOR - MENUITEM "&Marquage des cases suspectes", IDM_MARKQ + MENUITEM "Points d'interro&gation", IDM_MARKQ MENUITEM SEPARATOR - MENUITEM "&Débutant", IDM_BEGINNER - MENUITEM "&Avancé", IDM_ADVANCED + MENUITEM "&Débutant", IDM_BEGINNER + MENUITEM "&Avancé", IDM_ADVANCED MENUITEM "&Expert", IDM_EXPERT - MENUITEM "&Personnalisé...", IDM_CUSTOM + MENUITEM "&Personnalisé...", IDM_CUSTOM MENUITEM SEPARATOR MENUITEM "&Quitter\tAlt+X", IDM_EXIT } POPUP "&Info" { - MENUITEM "Meilleurs &temps", IDM_TIMES - MENUITEM "À &propos", IDM_ABOUT + MENUITEM "&Temps les plus rapides", IDM_TIMES + MENUITEM "À &propos", IDM_ABOUT } } DLG_TIMES DIALOG DISCARDABLE 0, 0, 160, 80 STYLE DS_MODALFRAME | DS_3DLOOK | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_POPUP -CAPTION "Meilleurs temps" +CAPTION "Temps les plus rapides" { - GROUPBOX "Meilleurs temps", -1, 10, 10, 140, 45 - LTEXT "Débutant", -1, 20, 20, 40, 8 - LTEXT "Avancé", -1, 20, 30, 40, 8 + GROUPBOX "Temps les plus rapides", -1, 10, 10, 140, 45 + LTEXT "Débutant", -1, 20, 20, 40, 8 + LTEXT "Avancé", -1, 20, 30, 40, 8 LTEXT "Expert", -1, 20, 40, 40, 8 LTEXT "999", IDC_TIME1, 70, 20, 15, 8 LTEXT "999", IDC_TIME2, 70, 30, 15, 8 @@ -76,9 +71,9 @@ CAPTION "Meilleurs temps" DLG_CONGRATS DIALOG DISCARDABLE 0, 0, 160, 60 STYLE DS_MODALFRAME | DS_3DLOOK | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_POPUP -CAPTION "Félicitations !" +CAPTION "Félicitations !" { - LTEXT "Veuillez saisir votre nom :", -1, 25, 10, 150, 10 + LTEXT "Veuillez saisir votre nom", -1, 10, 10, 150, 10 EDITTEXT IDC_EDITNAME, 25, 20, 110, 12 DEFPUSHBUTTON "OK", IDOK, 60, 40, 40, 15 } @@ -86,14 +81,14 @@ CAPTION "Félicitations !" DLG_CUSTOM DIALOG DISCARDABLE 0, 0, 100, 100 STYLE DS_MODALFRAME | DS_3DLOOK | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_POPUP -CAPTION "Grille personnalisée" +CAPTION "Grille personnalisée" { - LTEXT "Lignes", -1, 5, 5, 30, 10 + LTEXT "Rangées", -1, 5, 5, 30, 10 LTEXT "Colonnes", -1, 5, 35, 30, 10 LTEXT "Mines", -1, 5, 65, 30, 10 - EDITTEXT IDC_EDITROWS, 5, 15, 30, 12, ES_NUMBER - EDITTEXT IDC_EDITCOLS, 5, 45, 30, 12, ES_NUMBER - EDITTEXT IDC_EDITMINES, 5, 75, 30, 12, ES_NUMBER - DEFPUSHBUTTON "OK", IDOK, 44, 30, 50, 15 - PUSHBUTTON "Annuler", IDCANCEL, 44, 50, 50, 15 + EDITTEXT IDC_EDITROWS, 5, 15, 20, 12, ES_NUMBER + EDITTEXT IDC_EDITCOLS, 5, 45, 20, 12, ES_NUMBER + EDITTEXT IDC_EDITMINES, 5, 75, 20, 12, ES_NUMBER + DEFPUSHBUTTON "OK", IDOK, 40, 30, 50, 15 + PUSHBUTTON "Annuler", IDCANCEL, 40, 50, 50, 15 } diff --git a/programs/winemine/It.rc b/programs/winemine/It.rc index a799fa491ce..f3152ba4f22 100644 --- a/programs/winemine/It.rc +++ b/programs/winemine/It.rc @@ -21,13 +21,11 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL STRINGTABLE { IDS_APPNAME, "WineMine" - IDS_NOBODY, "Nessuno" + IDS_NOBODY, "Nobody" IDS_ABOUT, "Copyright 2000 Joshua Thielen" } @@ -41,7 +39,7 @@ MENU_WINEMINE MENU DISCARDABLE MENUITEM "&Principiante", IDM_BEGINNER MENUITEM "&Avanzato", IDM_ADVANCED MENUITEM "&Esperto", IDM_EXPERT - MENUITEM "&Personalizza", IDM_CUSTOM + MENUITEM "&Presonalizza", IDM_CUSTOM MENUITEM SEPARATOR MENUITEM "E&sci\tAlt+X", IDM_EXIT } diff --git a/programs/winemine/Ja.rc b/programs/winemine/Ja.rc index d4edbcb16cb..28530ac9590 100644 --- a/programs/winemine/Ja.rc +++ b/programs/winemine/Ja.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -95,3 +93,5 @@ CAPTION "盤面の変更" DEFPUSHBUTTON "OK", IDOK, 40, 30, 50, 15 PUSHBUTTON "Cancel", IDCANCEL, 40, 50, 50, 15 } + +#pragma code_page(default) diff --git a/programs/winemine/Ko.rc b/programs/winemine/Ko.rc index bc532e9a4af..c27d6e3eef2 100644 --- a/programs/winemine/Ko.rc +++ b/programs/winemine/Ko.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE { diff --git a/programs/winemine/Lt.rc b/programs/winemine/Lt.rc index 908e776b1e5..692717df727 100644 --- a/programs/winemine/Lt.rc +++ b/programs/winemine/Lt.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* UTF-8 */ #pragma code_page(65001) @@ -42,7 +40,7 @@ MENU_WINEMINE MENU DISCARDABLE MENUITEM "P&radedantis", IDM_BEGINNER MENUITEM "&Pažengęs", IDM_ADVANCED MENUITEM "Ek&spertas", IDM_EXPERT - MENUITEM "Pasirin&ktas...", IDM_CUSTOM + MENUITEM "Pasirin&ktas", IDM_CUSTOM MENUITEM SEPARATOR MENUITEM "Iš&eiti\tAlt+X", IDM_EXIT } @@ -94,3 +92,5 @@ CAPTION "Pasirinktas žaidimas" DEFPUSHBUTTON "Gerai", IDOK, 40, 30, 50, 15 PUSHBUTTON "Atsisakyti", IDCANCEL, 40, 50, 50, 15 } + +#pragma code_page(default) diff --git a/programs/winemine/Makefile.in b/programs/winemine/Makefile.in index 7146d922233..64f8599c568 100644 --- a/programs/winemine/Makefile.in +++ b/programs/winemine/Makefile.in @@ -8,32 +8,10 @@ IMPORTS = user32 gdi32 advapi32 kernel32 DELAYIMPORTS = shell32 C_SRCS = \ - dialog.c \ + dialog.c \ main.c -RC_SRCS = \ - Cs.rc \ - Da.rc \ - De.rc \ - En.rc \ - Es.rc \ - Fi.rc \ - Fr.rc \ - It.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ro.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc \ - rsrc.rc +RC_SRCS = rsrc.rc SVG_SRCS = winemine.svg diff --git a/programs/winemine/Nl.rc b/programs/winemine/Nl.rc index 18bbda6b7ed..6d0cf3cff2f 100644 --- a/programs/winemine/Nl.rc +++ b/programs/winemine/Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE { diff --git a/programs/winemine/No.rc b/programs/winemine/No.rc index 7e06eef0f1a..c3ab3d1f2d0 100644 --- a/programs/winemine/No.rc +++ b/programs/winemine/No.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE { diff --git a/programs/winemine/Pl.rc b/programs/winemine/Pl.rc index 7830eab628d..2d924c5c97f 100644 --- a/programs/winemine/Pl.rc +++ b/programs/winemine/Pl.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE { diff --git a/programs/winemine/Pt.rc b/programs/winemine/Pt.rc index 9c20abba1d8..a8f581aaa44 100644 --- a/programs/winemine/Pt.rc +++ b/programs/winemine/Pt.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN STRINGTABLE { diff --git a/programs/winemine/README b/programs/winemine/README new file mode 100644 index 00000000000..711b5f9c1e3 --- /dev/null +++ b/programs/winemine/README @@ -0,0 +1,17 @@ +WineMine README + +WineMine, copyright March 2000, Joshua Thielen +WineMine is distributed under the terms of the LGPL. + + +This is minesweeper for wine... +Enjoy. I wrote it because it rhymes ;). + +KNOWN BUGS: + No help file. + + Starting a new game causes the window to drop one pixel (Peter Hunnisett) + I don't know if it's a window manager problem (KDE) + +UNKNOWN BUGS: + ??? diff --git a/programs/winemine/Ro.rc b/programs/winemine/Ro.rc index af0ea37ceb0..9d601ae4253 100644 --- a/programs/winemine/Ro.rc +++ b/programs/winemine/Ro.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -93,3 +91,5 @@ CAPTION "Joc personalizat" DEFPUSHBUTTON "OK", IDOK, 40, 30, 50, 15 PUSHBUTTON "Renunţă", IDCANCEL, 40, 50, 50, 15 } + +#pragma code_page(default) diff --git a/programs/winemine/Ru.rc b/programs/winemine/Ru.rc index d990fe5643f..f13fd7ee779 100644 --- a/programs/winemine/Ru.rc +++ b/programs/winemine/Ru.rc @@ -19,11 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE { @@ -34,33 +29,33 @@ STRINGTABLE { MENU_WINEMINE MENU DISCARDABLE { - POPUP "&Игра" { - MENUITEM "&Новая игра\tF2", IDM_NEW + POPUP "&Èãðà" { + MENUITEM "&Íîâàÿ èãðà\tF2", IDM_NEW MENUITEM SEPARATOR - MENUITEM "&Вопросительные знаки", IDM_MARKQ + MENUITEM "&Âîïðîñèòåëüíûå çíàêè", IDM_MARKQ MENUITEM SEPARATOR - MENUITEM "Нови&чок", IDM_BEGINNER - MENUITEM "&Мастер", IDM_ADVANCED - MENUITEM "&Эксперт", IDM_EXPERT - MENUITEM "Нестандартные &параметры", IDM_CUSTOM + MENUITEM "Íîâè&÷îê", IDM_BEGINNER + MENUITEM "&Ìàñòåð", IDM_ADVANCED + MENUITEM "&Ýêñïåðò", IDM_EXPERT + MENUITEM "Íåñòàíäàðòíûå &ïàðàìåòðû", IDM_CUSTOM MENUITEM SEPARATOR - MENUITEM "&Закрыть\tAlt+X", IDM_EXIT + MENUITEM "&Çàêðûòü\tAlt+X", IDM_EXIT } - POPUP "&Справка" { - MENUITEM "&Лучшее время", IDM_TIMES - MENUITEM "&О программе", IDM_ABOUT + POPUP "&Ñïðàâêà" { + MENUITEM "&Ëó÷øåå âðåìÿ", IDM_TIMES + MENUITEM "&Î ïðîãðàììå", IDM_ABOUT } } DLG_TIMES DIALOG DISCARDABLE 0, 0, 160, 80 STYLE DS_MODALFRAME | DS_3DLOOK | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_POPUP -CAPTION "Лучшее время" +CAPTION "Ëó÷øåå âðåìÿ" { - GROUPBOX "Лучшее время", -1, 10, 10, 140, 45 - LTEXT "Новичок", -1, 20, 20, 40, 8 - LTEXT "Мастер", -1, 20, 30, 40, 8 - LTEXT "Эксперт", -1, 20, 40, 40, 8 + GROUPBOX "Ëó÷øåå âðåìÿ", -1, 10, 10, 140, 45 + LTEXT "Íîâè÷îê", -1, 20, 20, 40, 8 + LTEXT "Ìàñòåð", -1, 20, 30, 40, 8 + LTEXT "Ýêñïåðò", -1, 20, 40, 40, 8 LTEXT "999", IDC_TIME1, 70, 20, 15, 8 LTEXT "999", IDC_TIME2, 70, 30, 15, 8 LTEXT "999", IDC_TIME3, 70, 40, 15, 8 @@ -73,9 +68,9 @@ CAPTION "Лучшее время" DLG_CONGRATS DIALOG DISCARDABLE 0, 0, 160, 60 STYLE DS_MODALFRAME | DS_3DLOOK | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_POPUP -CAPTION "Поздравляю!" +CAPTION "Ïîçäðàâëÿþ!" { - LTEXT "Пожалуйста, введите Ваше имя", -1, 10, 10, 150, 10 + LTEXT "Ïîæàëóéñòà, ââåäèòå Âàøå èìÿ", -1, 10, 10, 150, 10 EDITTEXT IDC_EDITNAME, 25, 20, 110, 12 DEFPUSHBUTTON "OK", IDOK, 60, 40, 40, 15 } @@ -83,14 +78,14 @@ CAPTION "Поздравляю!" DLG_CUSTOM DIALOG DISCARDABLE 0, 0, 140, 100 STYLE DS_MODALFRAME | DS_3DLOOK | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_POPUP -CAPTION "Нестандартные параметры" +CAPTION "Íåñòàíäàðòíûå ïàðàìåòðû" { - LTEXT "По вертикали", -1, 5, 5, 70, 10 - LTEXT "По горизонтали", -1, 5, 35, 70, 10 - LTEXT "Число мин", -1, 5, 65, 70, 10 + LTEXT "Ïî âåðòèêàëè", -1, 5, 5, 70, 10 + LTEXT "Ïî ãîðèçîíòàëè", -1, 5, 35, 70, 10 + LTEXT "×èñëî ìèí", -1, 5, 65, 70, 10 EDITTEXT IDC_EDITROWS, 5, 15, 20, 12, ES_NUMBER EDITTEXT IDC_EDITCOLS, 5, 45, 20, 12, ES_NUMBER EDITTEXT IDC_EDITMINES, 5, 75, 20, 12, ES_NUMBER DEFPUSHBUTTON "OK", IDOK, 80, 30, 50, 15 - PUSHBUTTON "Отмена", IDCANCEL, 80, 50, 50, 15 + PUSHBUTTON "Îòìåíà", IDCANCEL, 80, 50, 50, 15 } diff --git a/programs/winemine/Si.rc b/programs/winemine/Si.rc index dab867a8d1d..77148c5e2d6 100644 --- a/programs/winemine/Si.rc +++ b/programs/winemine/Si.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -93,3 +91,5 @@ CAPTION "Poljubna igra" DEFPUSHBUTTON "V redu", IDOK, 40, 30, 50, 15 PUSHBUTTON "Prekliči", IDCANCEL, 40, 50, 50, 15 } + +#pragma code_page(default) diff --git a/programs/winemine/Sv.rc b/programs/winemine/Sv.rc deleted file mode 100644 index 498feb71613..00000000000 --- a/programs/winemine/Sv.rc +++ /dev/null @@ -1,98 +0,0 @@ -/* - * WineMine - * Swedish Language Support - * - * Copyright 2000 Joshua Thielen - * Copyright 2003 Marcelo Duarte - * Copyright 2008 Daniel Nylander - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resource.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL - -STRINGTABLE { - IDS_APPNAME, "Minor" - IDS_NOBODY, "Ingen" - IDS_ABOUT, "Copyright 2000 Joshua Thielen" -} - -MENU_WINEMINE MENU DISCARDABLE -{ - POPUP "A<ernativ" { - MENUITEM "&Nytt\tF2", IDM_NEW - MENUITEM SEPARATOR - MENUITEM "&Markera fråga", IDM_MARKQ - MENUITEM SEPARATOR - MENUITEM "Ny&börjare", IDM_BEGINNER - MENUITEM "&Avancerad", IDM_ADVANCED - MENUITEM "&Expert", IDM_EXPERT - MENUITEM "An&passad...", IDM_CUSTOM - MENUITEM SEPARATOR - MENUITEM "A&vsluta\tAlt+X", IDM_EXIT - } - POPUP "&Info" { - MENUITEM "&Snabbaste tider...", IDM_TIMES - MENUITEM "&Om", IDM_ABOUT - } -} - -DLG_TIMES DIALOG DISCARDABLE 0, 0, 160, 80 -STYLE DS_MODALFRAME | DS_3DLOOK | - WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_POPUP -CAPTION "Snabbaste tider" -{ - GROUPBOX "Snabbaste tider", -1, 10, 10, 140, 45 - LTEXT "Nybörjare", -1, 20, 20, 40, 8 - LTEXT "Avancerad", -1, 20, 30, 40, 8 - LTEXT "Expert", -1, 20, 40, 40, 8 - LTEXT "999", IDC_TIME1, 70, 20, 15, 8 - LTEXT "999", IDC_TIME2, 70, 30, 15, 8 - LTEXT "999", IDC_TIME3, 70, 40, 15, 8 - LTEXT "", IDC_NAME1, 90, 20, 55, 8 - LTEXT "", IDC_NAME2, 90, 30, 55, 8 - LTEXT "", IDC_NAME3, 90, 40, 55, 8 - DEFPUSHBUTTON "OK", IDOK, 55, 60, 50, 15 -} - -DLG_CONGRATS DIALOG DISCARDABLE 0, 0, 160, 60 -STYLE DS_MODALFRAME | DS_3DLOOK | - WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_POPUP -CAPTION "Gratulerar!" -{ - LTEXT "Ange ditt namn", -1, 10, 10, 150, 10 - EDITTEXT IDC_EDITNAME, 25, 20, 110, 12 - DEFPUSHBUTTON "OK", IDOK, 60, 40, 40, 15 -} - -DLG_CUSTOM DIALOG DISCARDABLE 0, 0, 100, 100 -STYLE DS_MODALFRAME | DS_3DLOOK | - WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_POPUP -CAPTION "Anpassat spel" -{ - LTEXT "Rader", -1, 5, 5, 30, 10 - LTEXT "Kolumner", -1, 5, 35, 35, 10 - LTEXT "Minor", -1, 5, 65, 30, 10 - EDITTEXT IDC_EDITROWS, 5, 15, 20, 12, ES_NUMBER - EDITTEXT IDC_EDITCOLS, 5, 45, 20, 12, ES_NUMBER - EDITTEXT IDC_EDITMINES, 5, 75, 20, 12, ES_NUMBER - DEFPUSHBUTTON "OK", IDOK, 40, 30, 50, 15 - PUSHBUTTON "Avbryt", IDCANCEL, 40, 50, 50, 15 -} diff --git a/programs/winemine/Tr.rc b/programs/winemine/Tr.rc index 174fbdad196..b09f77de053 100644 --- a/programs/winemine/Tr.rc +++ b/programs/winemine/Tr.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE { diff --git a/programs/winemine/Zh.rc b/programs/winemine/Zh.rc index e28a2044c52..99777c2731b 100644 --- a/programs/winemine/Zh.rc +++ b/programs/winemine/Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resource.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -164,3 +162,5 @@ CAPTION "自定義遊戲" DEFPUSHBUTTON "確定", IDOK, 40, 30, 50, 15 PUSHBUTTON "取消", IDCANCEL, 40, 50, 50, 15 } + +#pragma code_page(default) diff --git a/programs/winemine/resource.h b/programs/winemine/resource.h index c3272a29d7d..982c5166ef0 100644 --- a/programs/winemine/resource.h +++ b/programs/winemine/resource.h @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include #define ID_TIMER 1000 diff --git a/programs/winemine/rsrc.rc b/programs/winemine/rsrc.rc index ce5bcf94f0d..09f5cd38cbb 100644 --- a/programs/winemine/rsrc.rc +++ b/programs/winemine/rsrc.rc @@ -19,8 +19,32 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include +#include + #include "resource.h" +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Es.rc" +#include "Fi.rc" +#include "Fr.rc" +#include "It.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Lt.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ro.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Tr.rc" +#include "Zh.rc" + LANGUAGE LANG_NEUTRAL,SUBLANG_NEUTRAL IDA_WINEMINE ACCELERATORS DISCARDABLE diff --git a/programs/winetest/Makefile.in b/programs/winetest/Makefile.in index 9e43465b8fa..bd1251fda19 100644 --- a/programs/winetest/Makefile.in +++ b/programs/winetest/Makefile.in @@ -7,6 +7,8 @@ APPMODE = -mconsole IMPORTS = uuid comctl32 version user32 gdi32 advapi32 wsock32 kernel32 DELAYIMPORTS = ole32 +EXTRARCFLAGS = -DBUILD_SHA1=\"`GIT_DIR=$(TOPSRCDIR)/.git git rev-parse HEAD 2>/dev/null`\" + C_SRCS = \ gui.c \ main.c \ @@ -18,21 +20,25 @@ RC_SRCS = \ SVG_SRCS = winetest.svg -ALL_TEST_DIRS = @ALL_TEST_DIRS@ +@MAKE_PROG_RULES@ -TESTBINS = $(ALL_TEST_DIRS:%/tests=%_test.exe) -TESTRCS = build.rc $(TESTBINS:.exe=.rc) -EXTRA_OBJS = $(TESTRCS:.rc=.res) +ALL_TEST_DIRS = @ALL_TEST_DIRS@ -@MAKE_PROG_RULES@ +TESTBINS = $(ALL_TEST_DIRS:%/tests=%_test.exe) @ALL_WINETEST_DEPENDS@ +# Special rules + +winetest.res: $(TESTBINS) + +tests.rc: Makefile.in $(TOPOBJDIR)/config.status + (for i in $(TESTBINS); do echo "$$i TESTRES \"$$i\""; done) >$@ || ($(RM) $@ && false) + clean:: - $(RM) winetest-dist.exe $(TESTBINS) $(TESTRCS) + $(RM) tests.rc dist.res winetest-dist.exe $(TESTBINS) -build.rc: dummy - build="STRINGTABLE { 1 \"`GIT_DIR=$(TOPSRCDIR)/.git git rev-parse HEAD 2>/dev/null`\" }" && (echo $$build | cmp -s - $@) || echo $$build >$@ || ($(RM) $@ && exit 1) +depend: tests.rc # Rules for building distributable executable @@ -47,3 +53,5 @@ winetest-dist.exe winetest-dist.exe.so: $(OBJS) dist.res Makefile.in dist.res: build.nfo @DEPENDENCIES@ # everything below this line is overwritten by make depend + +winetest.res: tests.rc diff --git a/programs/winetest/README b/programs/winetest/README new file mode 100644 index 00000000000..90e8accd8a9 --- /dev/null +++ b/programs/winetest/README @@ -0,0 +1,22 @@ + Wine Test Shell + ~~~~~~~~~~~~~~~ + +Winetest is a single-executable version of all the DLL conformance +test programs suitable for unattended testing and report submission. +People assigned to build winetest must take care of the following +files, which are only used by 'make dist': + +* build.id + +Contains a single (either CR or CR-LF) terminated line providing the +build identification. The accepted characters are [-.0-9a-zA-Z]. + +* tests.url + +Also contains a single terminated line providing the archive URL of +the testing suite being built. + +* build.nfo + +Contains a block of terminated lines providing miscellaneous +information about the build, like eg. the tools being used. diff --git a/programs/winetest/main.c b/programs/winetest/main.c index 887fbfab871..66daa65baa2 100644 --- a/programs/winetest/main.c +++ b/programs/winetest/main.c @@ -284,13 +284,13 @@ static const char* get_test_source_file(const char* test, const char* subtest) return buffer; } -static void* extract_rcdata (LPCTSTR name, LPCTSTR type, DWORD* size) +static void* extract_rcdata (LPTSTR name, int type, DWORD* size) { HRSRC rsrc; HGLOBAL hdl; LPVOID addr; - if (!(rsrc = FindResource (NULL, name, type)) || + if (!(rsrc = FindResource (NULL, name, MAKEINTRESOURCE(type))) || !(*size = SizeofResource (0, rsrc)) || !(hdl = LoadResource (0, rsrc)) || !(addr = LockResource (hdl))) @@ -308,7 +308,7 @@ extract_test (struct wine_test *test, const char *dir, LPTSTR res_name) HANDLE hfile; DWORD written; - code = extract_rcdata (res_name, "TESTRES", &size); + code = extract_rcdata (res_name, TESTRES, &size); if (!code) report (R_FATAL, "Can't find test resource %s: %d", res_name, GetLastError ()); test->name = heap_strdup( res_name ); @@ -682,7 +682,7 @@ run_tests (char *logname, char *outdir) xprintf ("Archive: -\n"); /* no longer used */ xprintf ("Tag: %s\n", tag); xprintf ("Build info:\n"); - strres = extract_rcdata ("BUILD_INFO", "STRINGRES", &strsize); + strres = extract_rcdata (MAKEINTRESOURCE(BUILD_INFO), STRINGRES, &strsize); while (strres) { eol = memchr (strres, '\n', strsize); if (!eol) { @@ -701,7 +701,8 @@ run_tests (char *logname, char *outdir) xprintf ("Dll info:\n" ); report (R_STATUS, "Counting tests"); - if (!EnumResourceNames (NULL, "TESTRES", EnumTestFileProc, (LPARAM)&nr_of_files)) + if (!EnumResourceNames (NULL, MAKEINTRESOURCE(TESTRES), + EnumTestFileProc, (LPARAM)&nr_of_files)) report (R_FATAL, "Can't enumerate test files: %d", GetLastError ()); wine_tests = heap_alloc (nr_of_files * sizeof wine_tests[0]); @@ -716,7 +717,8 @@ run_tests (char *logname, char *outdir) report (R_PROGRESS, 0, nr_of_files); nr_of_files = 0; nr_of_tests = 0; - if (!EnumResourceNames (NULL, "TESTRES", extract_test_proc, (LPARAM)tempdir)) + if (!EnumResourceNames (NULL, MAKEINTRESOURCE(TESTRES), + extract_test_proc, (LPARAM)tempdir)) report (R_FATAL, "Can't enumerate test files: %d", GetLastError ()); @@ -799,7 +801,7 @@ static void extract_only (const char *target_dir) nr_of_files = 0; report (R_STATUS, "Counting tests"); - if (!EnumResourceNames (NULL, "TESTRES", EnumTestFileProc, (LPARAM)&nr_of_files)) + if (!EnumResourceNames (NULL, MAKEINTRESOURCE(TESTRES), EnumTestFileProc, (LPARAM)&nr_of_files)) report (R_FATAL, "Can't enumerate test files: %d", GetLastError ()); wine_tests = heap_alloc (nr_of_files * sizeof wine_tests[0] ); @@ -807,7 +809,7 @@ static void extract_only (const char *target_dir) report (R_STATUS, "Extracting tests"); report (R_PROGRESS, 0, nr_of_files); nr_of_files = 0; - if (!EnumResourceNames (NULL, "TESTRES", extract_only_proc, (LPARAM)target_dir)) + if (!EnumResourceNames (NULL, MAKEINTRESOURCE(TESTRES), extract_only_proc, (LPARAM)target_dir)) report (R_FATAL, "Can't enumerate test files: %d", GetLastError ()); report (R_DELTA, 0, "Extracting: Done"); diff --git a/programs/winetest/resource.h b/programs/winetest/resource.h index b0f1646ba57..667650834f8 100644 --- a/programs/winetest/resource.h +++ b/programs/winetest/resource.h @@ -43,3 +43,12 @@ #define IDC_ABOUT 4001 #define IDS_BUILD_ID 1 + +/* Resource types */ + +#define TESTRES 1000 +#define STRINGRES 1001 + +/* String resources */ + +#define BUILD_INFO 10001 diff --git a/programs/winetest/winetest.rc b/programs/winetest/winetest.rc index 52c34308182..4d406f2f409 100644 --- a/programs/winetest/winetest.rc +++ b/programs/winetest/winetest.rc @@ -24,6 +24,13 @@ #include "resource.h" +#ifdef BUILD_SHA1 +STRINGTABLE +BEGIN + IDS_BUILD_ID BUILD_SHA1 +END +#endif + IDD_TAG DIALOG 0, 0, 150, 65 STYLE WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "No tag supplied" @@ -75,3 +82,5 @@ END /* @makedep: winetest.ico */ IDI_WINE ICON "winetest.ico" + +#include "tests.rc" diff --git a/programs/winhlp32/Bg.rc b/programs/winhlp32/Bg.rc index e6d3143db24..c59d4e24625 100644 --- a/programs/winhlp32/Bg.rc +++ b/programs/winhlp32/Bg.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT diff --git a/programs/winhlp32/Cs.rc b/programs/winhlp32/Cs.rc index a8f8db31a26..15cbf02693d 100644 --- a/programs/winhlp32/Cs.rc +++ b/programs/winhlp32/Cs.rc @@ -21,8 +21,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Czech strings in CP1250 */ /* Menu */ diff --git a/programs/winhlp32/Da.rc b/programs/winhlp32/Da.rc index fc15eeba7d5..927fc32079f 100644 --- a/programs/winhlp32/Da.rc +++ b/programs/winhlp32/Da.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_DANISH, SUBLANG_DEFAULT diff --git a/programs/winhlp32/De.rc b/programs/winhlp32/De.rc index fa59b42ce96..c8ee650ccca 100644 --- a/programs/winhlp32/De.rc +++ b/programs/winhlp32/De.rc @@ -19,16 +19,12 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - -#pragma code_page(65001) - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL { POPUP "&Datei" { - MENUITEM "Ö&ffnen...", MNID_FILE_OPEN + MENUITEM "Ö&ffnen...", MNID_FILE_OPEN MENUITEM SEPARATOR MENUITEM "Thema &drucken", MNID_FILE_PRINT MENUITEM "Drucker&einrichtung...", MNID_FILE_SETUP @@ -65,7 +61,7 @@ MAIN_MENU MENU LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL MENUITEM SEPARATOR MENUITEM "&Info...", MNID_HELP_ABOUT #ifdef WINELIB - MENUITEM "&Über WINE", MNID_HELP_WINE + MENUITEM "&Über WINE", MNID_HELP_WINE #endif } } @@ -98,7 +94,7 @@ STID_NOT_IMPLEMENTED, "Nicht implementiert" STID_HLPFILE_ERROR_s, "Fehler beim Lesen der Hilfe-Datei `%s'" STID_INDEX, "&Inhalt" STID_CONTENTS, "Summary" -STID_BACK, "&Zurück" +STID_BACK, "&Zurück" STID_ALL_FILES, "Alle Dateien (*.*)" STID_HELP_FILES_HLP, "Hilfe-Dateien (*.hlp)" STID_FILE_NOT_FOUND_s "'%s' konnte nicht gefunden werden. Wollen Sie selber nach dieser Datei suchen?" @@ -113,11 +109,11 @@ BEGIN MENUITEM "Anmerken...", MNID_CTXT_ANNOTATE MENUITEM "Kopieren", MNID_CTXT_COPY MENUITEM "Drucken...", MNID_CTXT_PRINT -POPUP "Schriftgröße" +POPUP "Schriftgröße" BEGIN MENUITEM "Klein", MNID_CTXT_FONTS_SMALL MENUITEM "Normal", MNID_CTXT_FONTS_NORMAL -MENUITEM "Groß", MNID_CTXT_FONTS_LARGE +MENUITEM "Groß", MNID_CTXT_FONTS_LARGE END POPUP "Hilfe immer sichtbar" BEGIN diff --git a/programs/winhlp32/En.rc b/programs/winhlp32/En.rc index a4e9d8add4e..2a11e1a33c2 100644 --- a/programs/winhlp32/En.rc +++ b/programs/winhlp32/En.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT @@ -68,51 +66,6 @@ MAIN_MENU MENU LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT } } -MAIN_MENU MENU LANGUAGE LANG_ENGLISH, SUBLANG_NEUTRAL -{ - POPUP "&File" { - MENUITEM "&Open", MNID_FILE_OPEN - MENUITEM SEPARATOR - MENUITEM "&Print", MNID_FILE_PRINT - MENUITEM "Printer &setup...", MNID_FILE_SETUP - MENUITEM SEPARATOR - MENUITEM "E&xit", MNID_FILE_EXIT - } - POPUP "&Edit" { - MENUITEM "&Copy...", MNID_EDIT_COPYDLG - MENUITEM SEPARATOR - MENUITEM "&Annotate...", MNID_EDIT_ANNOTATE - } - POPUP "&Bookmark" { - MENUITEM "&Define...", MNID_BKMK_DEFINE - } - POPUP "&Options" { - POPUP "Help always visible" - BEGIN - MENUITEM "Default", MNID_OPTS_HELP_DEFAULT - MENUITEM "Visible", MNID_OPTS_HELP_VISIBLE - MENUITEM "Non visible", MNID_OPTS_HELP_NONVISIBLE - END - MENUITEM "History", MNID_OPTS_HISTORY - POPUP "Fonts" - BEGIN - MENUITEM "Small", MNID_OPTS_FONTS_SMALL - MENUITEM "Normal", MNID_OPTS_FONTS_NORMAL - MENUITEM "Large", MNID_OPTS_FONTS_LARGE - END - MENUITEM "Use system colours", MNID_OPTS_SYSTEM_COLORS - } - POPUP "&Help" { - MENUITEM "Help &on help", MNID_HELP_HELPON - MENUITEM "Always on &top", MNID_HELP_HELPTOP - MENUITEM SEPARATOR - MENUITEM "&Info...", MNID_HELP_ABOUT -#ifdef WINELIB - MENUITEM "&About Wine", MNID_HELP_WINE -#endif - } -} - IDD_INDEX DIALOG DISCARDABLE 0, 0, 200, 190 LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU FONT 8, "MS Shell Dlg" @@ -170,26 +123,3 @@ BEGIN MENUITEM "Use system colors", MNID_CTXT_SYSTEM_COLORS END END - -CONTEXT_MENU MENU LANGUAGE LANG_ENGLISH, SUBLANG_NEUTRAL -BEGIN - POPUP "" - BEGIN - MENUITEM "Annotation...", MNID_CTXT_ANNOTATE - MENUITEM "Copy", MNID_CTXT_COPY - MENUITEM "Print...", MNID_CTXT_PRINT - POPUP "Fonts" - BEGIN - MENUITEM "Small", MNID_CTXT_FONTS_SMALL - MENUITEM "Normal", MNID_CTXT_FONTS_NORMAL - MENUITEM "Large", MNID_CTXT_FONTS_LARGE - END - POPUP "Help always visible" - BEGIN - MENUITEM "Default", MNID_CTXT_HELP_DEFAULT - MENUITEM "Visible", MNID_CTXT_HELP_VISIBLE - MENUITEM "Non visible", MNID_CTXT_HELP_NONVISIBLE - END - MENUITEM "Use system colours", MNID_CTXT_SYSTEM_COLORS - END -END diff --git a/programs/winhlp32/Eo.rc b/programs/winhlp32/Eo.rc index adf288da7f0..adb98160912 100644 --- a/programs/winhlp32/Eo.rc +++ b/programs/winhlp32/Eo.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Cxapelitaj literoj estas en Latin-3 iso8859-3 */ /* Menu */ diff --git a/programs/winhlp32/Es.rc b/programs/winhlp32/Es.rc index e752950bcd9..eee0e17e26a 100644 --- a/programs/winhlp32/Es.rc +++ b/programs/winhlp32/Es.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL diff --git a/programs/winhlp32/Fi.rc b/programs/winhlp32/Fi.rc index 5585619e4ed..a1564e68adf 100644 --- a/programs/winhlp32/Fi.rc +++ b/programs/winhlp32/Fi.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT diff --git a/programs/winhlp32/Fr.rc b/programs/winhlp32/Fr.rc index cedb0f694b7..0c5eea63f12 100644 --- a/programs/winhlp32/Fr.rc +++ b/programs/winhlp32/Fr.rc @@ -20,11 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - -/* UTF-8 */ -#pragma code_page(65001) - /* Menu */ LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL @@ -39,18 +34,18 @@ MAIN_MENU MENU MENUITEM SEPARATOR MENUITEM "&Quitter", MNID_FILE_EXIT } - POPUP "É&dition" { + POPUP "É&dition" { MENUITEM "&Copier...", MNID_EDIT_COPYDLG MENUITEM SEPARATOR - MENUITEM "&Annoter...", MNID_EDIT_ANNOTATE + MENUITEM "&Annotation...", MNID_EDIT_ANNOTATE } - POPUP "&Signets" { - MENUITEM "&Définir...", MNID_BKMK_DEFINE + POPUP "&Signet" { + MENUITEM "&Définir...", MNID_BKMK_DEFINE } POPUP "&Options" { POPUP "Aide toujours visible" BEGIN - MENUITEM "Par défaut", MNID_OPTS_HELP_DEFAULT + MENUITEM "Par défaut", MNID_OPTS_HELP_DEFAULT MENUITEM "Visible", MNID_OPTS_HELP_VISIBLE MENUITEM "Non visible", MNID_OPTS_HELP_NONVISIBLE END @@ -61,7 +56,7 @@ MAIN_MENU MENU MENUITEM "Normale", MNID_OPTS_FONTS_NORMAL MENUITEM "Grande", MNID_OPTS_FONTS_LARGE END - MENUITEM "Utiliser les couleurs système", MNID_OPTS_SYSTEM_COLORS + MENUITEM "Utiliser les couleurs système", MNID_OPTS_SYSTEM_COLORS } POPUP "Aid&e" { MENUITEM "&Utiliser l'aide", MNID_HELP_HELPON @@ -69,7 +64,7 @@ MAIN_MENU MENU MENUITEM SEPARATOR MENUITEM "&Info...", MNID_HELP_ABOUT #ifdef WINELIB - MENUITEM "À &propos de Wine", MNID_HELP_WINE + MENUITEM "À &propos de Wine", MNID_HELP_WINE #endif } } @@ -87,7 +82,7 @@ STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU FONT 8, "MS Shell Dlg" CAPTION "Recherche" { - LTEXT "Pas encore implémenté", -1, 10, 10, 180, 150 + LTEXT "Pas encore implémenté", -1, 10, 10, 180, 150 } /* Strings */ @@ -97,15 +92,15 @@ STID_WINE_HELP, "Aide de Wine" STID_WHERROR, "ERREUR" STID_WARNING, "ATTENTION" STID_INFO, "Information" -STID_NOT_IMPLEMENTED, "Non implémenté" -STID_HLPFILE_ERROR_s, "Une erreur est survenue en lisant le fichier d'aide « %s »" +STID_NOT_IMPLEMENTED, "Non implémenté" +STID_HLPFILE_ERROR_s, "Une erreur est survenue en lisant le fichier d'aide « %s »" STID_INDEX, "&Index" STID_CONTENTS, "Sommaire" -STID_BACK, "&Précédent" -STID_ALL_FILES, "Tous les fichiers (*.*)" +STID_BACK, "&Précédent" +STID_ALL_FILES, "Tous fichiers (*.*)" STID_HELP_FILES_HLP, "Fichiers d'aide (*.hlp)" -STID_FILE_NOT_FOUND_s "Impossible de trouver « %s ». Souhaitez-vous rechercher ce fichier vous-même ?" -STID_NO_RICHEDIT "La bibliothèque RichEdit n'a pu être localisée... Abandon" +STID_FILE_NOT_FOUND_s "Impossible de trouver « %s ». Souhaitez-vous rechercher ce fichier vous-même ?" +STID_NO_RICHEDIT "La bibliothèque RichEdit n'a pu être localisée... Abandon" STID_PSH_INDEX, "Rubriques d'aide : " } @@ -124,10 +119,10 @@ BEGIN END POPUP "Aide toujours visible" BEGIN - MENUITEM "Par défaut", MNID_CTXT_HELP_DEFAULT + MENUITEM "Par défaut", MNID_CTXT_HELP_DEFAULT MENUITEM "Visible", MNID_CTXT_HELP_VISIBLE MENUITEM "Non visible", MNID_CTXT_HELP_NONVISIBLE END - MENUITEM "Utiliser les couleurs système", MNID_CTXT_SYSTEM_COLORS + MENUITEM "Utiliser les couleurs système", MNID_CTXT_SYSTEM_COLORS END END diff --git a/programs/winhlp32/Hu.rc b/programs/winhlp32/Hu.rc index ef3a1ee2bc3..39beb19c641 100644 --- a/programs/winhlp32/Hu.rc +++ b/programs/winhlp32/Hu.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT diff --git a/programs/winhlp32/It.rc b/programs/winhlp32/It.rc index 5d1abb8c92c..c929727791b 100644 --- a/programs/winhlp32/It.rc +++ b/programs/winhlp32/It.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL @@ -41,21 +39,21 @@ MAIN_MENU MENU LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL POPUP "&Segnalibro" { MENUITEM "&Definisci...", MNID_BKMK_DEFINE } - POPUP "&Opzioni" { - POPUP "Aiuto sempre visibile" + POPUP "&Options" { + POPUP "Help always visible" BEGIN - MENUITEM "Predefinito", MNID_OPTS_HELP_DEFAULT - MENUITEM "Visibile", MNID_OPTS_HELP_VISIBLE - MENUITEM "Non visibile", MNID_OPTS_HELP_NONVISIBLE + MENUITEM "Default", MNID_OPTS_HELP_DEFAULT + MENUITEM "Visible", MNID_OPTS_HELP_VISIBLE + MENUITEM "Non visible", MNID_OPTS_HELP_NONVISIBLE END - MENUITEM "Cronologia", MNID_OPTS_HISTORY - POPUP "Caratteri" + MENUITEM "History", MNID_OPTS_HISTORY + POPUP "Fonts" BEGIN - MENUITEM "Piccolo", MNID_OPTS_FONTS_SMALL - MENUITEM "Normale", MNID_OPTS_FONTS_NORMAL - MENUITEM "Grande", MNID_OPTS_FONTS_LARGE + MENUITEM "Small", MNID_OPTS_FONTS_SMALL + MENUITEM "Normal", MNID_OPTS_FONTS_NORMAL + MENUITEM "Large", MNID_OPTS_FONTS_LARGE END - MENUITEM "Usa colori di sistema", MNID_OPTS_SYSTEM_COLORS + MENUITEM "Use system colors", MNID_OPTS_SYSTEM_COLORS } POPUP "&?" { MENUITEM "&Aiuto sulla guida", MNID_HELP_HELPON @@ -63,7 +61,7 @@ MAIN_MENU MENU LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL MENUITEM SEPARATOR MENUITEM "&Informazioni su...", MNID_HELP_ABOUT #ifdef WINELIB - MENUITEM "&Informazioni su WINE", MNID_HELP_WINE + MENUITEM "&Informazion su WINE", MNID_HELP_WINE #endif } } @@ -78,12 +76,12 @@ STID_WARNING, "ATTENZIONE" STID_INFO, "Informazione" STID_NOT_IMPLEMENTED, "Non ancora implementato" STID_HLPFILE_ERROR_s, "Errore di lettura del file della Guida `%s'" -STID_INDEX, "Indice" +STID_INDEX, "Index" STID_CONTENTS, "&Sommario" STID_BACK, "&Precedente" STID_ALL_FILES, "Tutti i file (*.*)" STID_HELP_FILES_HLP, "File della Guida (*.hlp)" -STID_FILE_NOT_FOUND_s "Non è stato possibile trovare '%s'. Vuoi cercare questo file?" -STID_NO_RICHEDIT "Non è stato possibile trovare un'implementazione richedit... Annullando" -STID_PSH_INDEX, "Argomenti di aiuto: " +STID_FILE_NOT_FOUND_s "Cannot find '%s'. Do you want to find this file yourself?" +STID_NO_RICHEDIT "Cannot find a richedit implementation... Aborting" +STID_PSH_INDEX, "Help topics: " } diff --git a/programs/winhlp32/Ja.rc b/programs/winhlp32/Ja.rc index b73d18dd192..bd88b5d6fad 100644 --- a/programs/winhlp32/Ja.rc +++ b/programs/winhlp32/Ja.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* UTF-8 */ #pragma code_page(65001) @@ -128,3 +126,5 @@ BEGIN MENUITEM "システム カラーを使う", MNID_CTXT_SYSTEM_COLORS END END + +#pragma code_page(default) diff --git a/programs/winhlp32/Ko.rc b/programs/winhlp32/Ko.rc index 8b4c785ed0c..68931789c60 100644 --- a/programs/winhlp32/Ko.rc +++ b/programs/winhlp32/Ko.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT diff --git a/programs/winhlp32/Lt.rc b/programs/winhlp32/Lt.rc deleted file mode 100644 index f8e78681aae..00000000000 --- a/programs/winhlp32/Lt.rc +++ /dev/null @@ -1,131 +0,0 @@ -/* - * Help Viewer - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "winhelp_res.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -/* Menu */ - -MAIN_MENU MENU -{ - POPUP "&Failas" { - MENUITEM "&Atverti", MNID_FILE_OPEN - MENUITEM SEPARATOR - MENUITEM "&Spausdinti", MNID_FILE_PRINT - MENUITEM "Spaus&dintuvo nuostatos...", MNID_FILE_SETUP - MENUITEM SEPARATOR - MENUITEM "Iš&eiti", MNID_FILE_EXIT - } - POPUP "&Taisa" { - MENUITEM "&Kopijuoti...", MNID_EDIT_COPYDLG - MENUITEM SEPARATOR - MENUITEM "Ko&mentuoti...", MNID_EDIT_ANNOTATE - } - POPUP "&Adresynas" { - MENUITEM "&Apibrėžti...", MNID_BKMK_DEFINE - } - POPUP "&Parinktys" { - POPUP "Žinynas visuomet matomas" - BEGIN - MENUITEM "Numatyta", MNID_OPTS_HELP_DEFAULT - MENUITEM "Matomas", MNID_OPTS_HELP_VISIBLE - MENUITEM "Nematomas", MNID_OPTS_HELP_NONVISIBLE - END - MENUITEM "Istorija", MNID_OPTS_HISTORY - POPUP "Šriftas" - BEGIN - MENUITEM "&Mažas", MNID_OPTS_FONTS_SMALL - MENUITEM "&Normalus", MNID_OPTS_FONTS_NORMAL - MENUITEM "&Didelis", MNID_OPTS_FONTS_LARGE - END - MENUITEM "Naudoti &sistemos spalvas", MNID_OPTS_SYSTEM_COLORS - } - POPUP "&Žinynas" { - MENUITEM "Pa&galba apie žinyną", MNID_HELP_HELPON - MENUITEM "&Visada viršuje", MNID_HELP_HELPTOP - MENUITEM SEPARATOR - MENUITEM "&Informacija...", MNID_HELP_ABOUT -#ifdef WINELIB - MENUITEM "&Apie Wine", MNID_HELP_WINE -#endif - } -} - -IDD_INDEX DIALOG DISCARDABLE 0, 0, 200, 190 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -FONT 8, "MS Shell Dlg" -CAPTION "Indeksas" -{ - LISTBOX IDC_INDEXLIST, 10, 10, 180, 150, LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_BORDER -} - -IDD_SEARCH DIALOG DISCARDABLE 0, 0, 200, 190 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -FONT 8, "MS Shell Dlg" -CAPTION "Paieška" -{ - LTEXT "Dar nerealizuota", -1, 10, 10, 180, 150 -} - -/* Strings */ -STRINGTABLE DISCARDABLE -{ -STID_WINE_HELP, "Wine žinynas" -STID_WHERROR, "KLAIDA" -STID_WARNING, "ĮSPĖJIMAS" -STID_INFO, "Informacija" -STID_NOT_IMPLEMENTED, "Nerealizuota" -STID_HLPFILE_ERROR_s, "Klaida skaitant žinyno failą „%s“" -STID_INDEX, "&Rodyklė" -STID_CONTENTS, "Santrauka" -STID_BACK, "&Atgal" -STID_ALL_FILES, "Visi failai (*.*)" -STID_HELP_FILES_HLP, "Žinyno failai (*.hlp)" -STID_FILE_NOT_FOUND_s "Nepavyko rasti „%s“. Ar norite rasti šį failą patys?" -STID_NO_RICHEDIT "Nepavyko rasti RichEdit realizacijos... Nutraukiama" -STID_PSH_INDEX, "Žinyno temos: " -} - -CONTEXT_MENU MENU -BEGIN - POPUP "" - BEGIN - MENUITEM "Komentuoti...", MNID_CTXT_ANNOTATE - MENUITEM "Kopijuoti", MNID_CTXT_COPY - MENUITEM "Spausdinti...", MNID_CTXT_PRINT - POPUP "Šriftas" - BEGIN - MENUITEM "Mažas", MNID_CTXT_FONTS_SMALL - MENUITEM "Normalus", MNID_CTXT_FONTS_NORMAL - MENUITEM "Didelis", MNID_CTXT_FONTS_LARGE - END - POPUP "Žinynas visuomet matomas" - BEGIN - MENUITEM "Numatyta", MNID_CTXT_HELP_DEFAULT - MENUITEM "Matomas", MNID_CTXT_HELP_VISIBLE - MENUITEM "Nematomas", MNID_CTXT_HELP_NONVISIBLE - END - MENUITEM "Naudoti sistemos spalvas", MNID_CTXT_SYSTEM_COLORS - END -END diff --git a/programs/winhlp32/Makefile.in b/programs/winhlp32/Makefile.in index d9635583fc0..479656433be 100644 --- a/programs/winhlp32/Makefile.in +++ b/programs/winhlp32/Makefile.in @@ -18,34 +18,7 @@ LEX_SRCS = macro.lex.l EXTRARCFLAGS = -DWINELIB -RC_SRCS = \ - Bg.rc \ - Cs.rc \ - Da.rc \ - De.rc \ - En.rc \ - Eo.rc \ - Es.rc \ - Fi.rc \ - Fr.rc \ - Hu.rc \ - It.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Rm.rc \ - Ru.rc \ - Si.rc \ - Sk.rc \ - Sv.rc \ - Tr.rc \ - Wa.rc \ - Zh.rc \ - rsrc.rc +RC_SRCS = rsrc.rc SVG_SRCS = winhelp.svg diff --git a/programs/winhlp32/Nl.rc b/programs/winhlp32/Nl.rc index 029d58265b9..6a8747a859e 100644 --- a/programs/winhlp32/Nl.rc +++ b/programs/winhlp32/Nl.rc @@ -19,10 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - -#pragma code_page(65001) - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL @@ -36,28 +32,28 @@ MAIN_MENU MENU LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL MENUITEM "&Afsluiten", MNID_FILE_EXIT } POPUP "&Bewerken" { - MENUITEM "&Kopiëren...", MNID_EDIT_COPYDLG + MENUITEM "&Kopiëren...", MNID_EDIT_COPYDLG MENUITEM SEPARATOR MENUITEM "&Annoteren...", MNID_EDIT_ANNOTATE } POPUP "&Favorieten" { MENUITEM "&Aanmaken...", MNID_BKMK_DEFINE } - POPUP "&Opties" { - POPUP "Help altijd zichtbaar" + POPUP "&Options" { + POPUP "Help always visible" BEGIN - MENUITEM "Standaard", MNID_OPTS_HELP_DEFAULT - MENUITEM "Zichtbaar", MNID_OPTS_HELP_VISIBLE - MENUITEM "Niet zichtbaar", MNID_OPTS_HELP_NONVISIBLE + MENUITEM "Default", MNID_OPTS_HELP_DEFAULT + MENUITEM "Visible", MNID_OPTS_HELP_VISIBLE + MENUITEM "Non visible", MNID_OPTS_HELP_NONVISIBLE END - MENUITEM "Historie", MNID_OPTS_HISTORY - POPUP "Lettertype" + MENUITEM "History", MNID_OPTS_HISTORY + POPUP "Fonts" BEGIN - MENUITEM "Klein", MNID_OPTS_FONTS_SMALL - MENUITEM "Standaard", MNID_OPTS_FONTS_NORMAL - MENUITEM "Groot", MNID_OPTS_FONTS_LARGE + MENUITEM "Small", MNID_OPTS_FONTS_SMALL + MENUITEM "Normal", MNID_OPTS_FONTS_NORMAL + MENUITEM "Large", MNID_OPTS_FONTS_LARGE END - MENUITEM "Gebruik systeemkleuren", MNID_OPTS_SYSTEM_COLORS + MENUITEM "Use system colors", MNID_OPTS_SYSTEM_COLORS } POPUP "&Help" { MENUITEM "Hulp &bij help", MNID_HELP_HELPON @@ -65,7 +61,7 @@ MAIN_MENU MENU LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL MENUITEM SEPARATOR MENUITEM "&Info...", MNID_HELP_ABOUT #ifdef WINELIB - MENUITEM "&Over Wine", MNID_HELP_WINE + MENUITEM "&Over WINE", MNID_HELP_WINE #endif } } @@ -83,26 +79,26 @@ STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU FONT 8, "MS Shell Dlg" CAPTION "Zoeken" { - LTEXT "Nog niet geïmplementeerd", -1, 10, 10, 180, 150 + LTEXT "Nog niet geimplementeerd", -1, 10, 10, 180, 150 } /* Strings */ STRINGTABLE DISCARDABLE LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL { -STID_WINE_HELP, "Wine Help" +STID_WINE_HELP, "WINE Help" STID_WHERROR, "FOUT" STID_WARNING, "WAARSCHUWING" STID_INFO, "Informatie" -STID_NOT_IMPLEMENTED, "Niet geïmplementeerd" -STID_HLPFILE_ERROR_s, "Fout bij het lezen van het helpbestand '%s'" -STID_INDEX, "Inde&x" -STID_CONTENTS, "&Inhoudsopgave" +STID_NOT_IMPLEMENTED, "Niet geïmplementeerd" +STID_HLPFILE_ERROR_s, "Fout bij het lezen van het helpbestand `%s'" +STID_INDEX, "&Inhoud" +STID_CONTENTS, "Summary" STID_BACK, "&Terug" STID_ALL_FILES, "Alle bestanden (*.*)" STID_HELP_FILES_HLP, "Helpbestanden (*.hlp)" STID_FILE_NOT_FOUND_s "Kan '%s' niet openen. Wilt u zelf dit bestand zoeken?" -STID_NO_RICHEDIT "Kan geen richedit implementatie vinden... Actie afgebroken" -STID_PSH_INDEX, "Help onderwerpen: " +STID_NO_RICHEDIT "Cannot find a richedit implementation... Aborting" +STID_PSH_INDEX, "Help topics: " } CONTEXT_MENU MENU LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL @@ -110,7 +106,7 @@ BEGIN POPUP "" BEGIN MENUITEM "Annotering...", MNID_CTXT_ANNOTATE - MENUITEM "Kopiëren", MNID_CTXT_COPY + MENUITEM "Kopiëren", MNID_CTXT_COPY MENUITEM "Print...", MNID_CTXT_PRINT POPUP "Lettertypes" BEGIN diff --git a/programs/winhlp32/No.rc b/programs/winhlp32/No.rc index 2cf2a782372..5f3e3101c46 100644 --- a/programs/winhlp32/No.rc +++ b/programs/winhlp32/No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL diff --git a/programs/winhlp32/Pl.rc b/programs/winhlp32/Pl.rc index 75047892180..17d5d22e346 100644 --- a/programs/winhlp32/Pl.rc +++ b/programs/winhlp32/Pl.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_POLISH, SUBLANG_DEFAULT diff --git a/programs/winhlp32/Pt.rc b/programs/winhlp32/Pt.rc index 28933a22a6f..fd27a65b55f 100644 --- a/programs/winhlp32/Pt.rc +++ b/programs/winhlp32/Pt.rc @@ -6,8 +6,7 @@ * Portuguese translation by Gustavo Junior Alves * Copyright 2002 Sylvain Petreolle * Copyright 2003 Marcelo Duarte - * Copyright 2004,2007 Américo José Melo - * Copyright 2009 Ricardo Filipe + * Copyright 2004,2007 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 @@ -24,10 +23,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - -#pragma code_page(65001) - /* Menu */ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN @@ -68,9 +63,9 @@ MAIN_MENU MENU } POPUP "Aj&uda" { MENUITEM "Ajuda &na ajuda", MNID_HELP_HELPON - MENUITEM "Sempre &visível", MNID_HELP_HELPTOP + MENUITEM "Sempre &visível", MNID_HELP_HELPTOP MENUITEM SEPARATOR - MENUITEM "&Informações...", MNID_HELP_ABOUT + MENUITEM "&Informações...", MNID_HELP_ABOUT #ifdef WINELIB MENUITEM "&Sobre WINE", MNID_HELP_WINE #endif @@ -97,49 +92,33 @@ MAIN_MENU MENU POPUP "In&dicador" { MENUITEM "&Definir...", MNID_BKMK_DEFINE } - POPUP "&Opções" { - POPUP "Ajuda sempre visível" + POPUP "&Options" { + POPUP "Help always visible" BEGIN - MENUITEM "Omissão", MNID_OPTS_HELP_DEFAULT - MENUITEM "Visível", MNID_OPTS_HELP_VISIBLE - MENUITEM "Invisível", MNID_OPTS_HELP_NONVISIBLE + MENUITEM "Default", MNID_OPTS_HELP_DEFAULT + MENUITEM "Visible", MNID_OPTS_HELP_VISIBLE + MENUITEM "Non visible", MNID_OPTS_HELP_NONVISIBLE END - MENUITEM "Histórico", MNID_OPTS_HISTORY - POPUP "Tipos de Letra" + MENUITEM "History", MNID_OPTS_HISTORY + POPUP "Fonts" BEGIN - MENUITEM "Pequeno", MNID_OPTS_FONTS_SMALL + MENUITEM "Small", MNID_OPTS_FONTS_SMALL MENUITEM "Normal", MNID_OPTS_FONTS_NORMAL - MENUITEM "Grande", MNID_OPTS_FONTS_LARGE + MENUITEM "Large", MNID_OPTS_FONTS_LARGE END - MENUITEM "Usar cores do sistema", MNID_OPTS_SYSTEM_COLORS + MENUITEM "Use system colors", MNID_OPTS_SYSTEM_COLORS } POPUP "Aj&uda" { MENUITEM "Ajuda &na ajuda", MNID_HELP_HELPON - MENUITEM "Sempre &visível", MNID_HELP_HELPTOP + MENUITEM "Sempre &visível", MNID_HELP_HELPTOP MENUITEM SEPARATOR - MENUITEM "&Informações...", MNID_HELP_ABOUT + MENUITEM "&Informações...", MNID_HELP_ABOUT #ifdef WINELIB MENUITEM "&Acerca do WINE", MNID_HELP_WINE #endif } } -IDD_INDEX DIALOG DISCARDABLE 0, 0, 200, 190 LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -FONT 8, "MS Shell Dlg" -CAPTION "Índice" -{ - LISTBOX IDC_INDEXLIST, 10, 10, 180, 150, LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_BORDER -} - -IDD_SEARCH DIALOG DISCARDABLE 0, 0, 200, 190 LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -FONT 8, "MS Shell Dlg" -CAPTION "Procura" -{ - LTEXT "Ainda não implementado", -1, 10, 10, 180, 150 -} - /* Strings */ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN @@ -149,10 +128,10 @@ STRINGTABLE DISCARDABLE STID_WINE_HELP, "Ajuda WINE" STID_WHERROR, "ERRO" STID_WARNING, "AVISO" -STID_INFO, "Informação" -STID_NOT_IMPLEMENTED, "Não implementado" +STID_INFO, "Informação" +STID_NOT_IMPLEMENTED, "Não implementado" STID_HLPFILE_ERROR_s, "Erro encontrado na leitura do arquivo de ajuda '%s'" -STID_INDEX, "&Conteúdo" +STID_INDEX, "&Conteúdo" STID_CONTENTS, "Summary" STID_BACK, "&Voltar" STID_ALL_FILES, "Todos os arquivos (*.*)" @@ -169,38 +148,15 @@ STRINGTABLE DISCARDABLE STID_WINE_HELP, "Ajuda WINE" STID_WHERROR, "ERRO" STID_WARNING, "AVISO" -STID_INFO, "Informação" -STID_NOT_IMPLEMENTED, "Não implementado" +STID_INFO, "Informação" +STID_NOT_IMPLEMENTED, "Não implementado" STID_HLPFILE_ERROR_s, "Erro encontrado na leitura do ficheiro de ajuda '%s'" -STID_INDEX, "&Conteúdo" -STID_CONTENTS, "Sumário" +STID_INDEX, "&Conteúdo" +STID_CONTENTS, "Summary" STID_BACK, "&Voltar" STID_ALL_FILES, "Todos os ficheiros (*.*)" STID_HELP_FILES_HLP, "Ficheiros de ajuda (*.hlp)" -STID_FILE_NOT_FOUND_s "Não é possível encontrar '%s'. Deseja procurar este ficheiro você mesmo?" -STID_NO_RICHEDIT "Não foi possível encontrar uma implementação do richedit... A abortar" -STID_PSH_INDEX, "Tópicos de ajuda: " +STID_FILE_NOT_FOUND_s "Não é possível encontrar '%s'. Deseja procurar este ficheiro você mesmo?" +STID_NO_RICHEDIT "Cannot find a richedit implementation... Aborting" +STID_PSH_INDEX, "Help topics: " } - -CONTEXT_MENU MENU LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE -BEGIN - POPUP "" - BEGIN - MENUITEM "Anotação...", MNID_CTXT_ANNOTATE - MENUITEM "Copiar", MNID_CTXT_COPY - MENUITEM "Imprimir...", MNID_CTXT_PRINT - POPUP "Tipos de letra" - BEGIN - MENUITEM "Pequeno", MNID_CTXT_FONTS_SMALL - MENUITEM "Normal", MNID_CTXT_FONTS_NORMAL - MENUITEM "Grande", MNID_CTXT_FONTS_LARGE - END - POPUP "Ajuda sempre visível" - BEGIN - MENUITEM "Omissão", MNID_CTXT_HELP_DEFAULT - MENUITEM "Visível", MNID_CTXT_HELP_VISIBLE - MENUITEM "Invisível", MNID_CTXT_HELP_NONVISIBLE - END - MENUITEM "Usar cores do sistema", MNID_CTXT_SYSTEM_COLORS - END -END diff --git a/programs/winhlp32/Rm.rc b/programs/winhlp32/Rm.rc index ece7bb17c4d..1339b39e189 100644 --- a/programs/winhlp32/Rm.rc +++ b/programs/winhlp32/Rm.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* FIXME: This file is in the Vallader Romansh dialect and not in the official Rumantsch Grischun. */ diff --git a/programs/winhlp32/Ru.rc b/programs/winhlp32/Ru.rc dissimilarity index 70% index 165094f4720..af0097b7eea 100644 --- a/programs/winhlp32/Ru.rc +++ b/programs/winhlp32/Ru.rc @@ -1,123 +1,116 @@ -/* - * Help Viewer (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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "winhelp_res.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT - -/* Menu */ - -MAIN_MENU MENU -{ - POPUP "&Файл" { - MENUITEM "&Открыть", MNID_FILE_OPEN - MENUITEM SEPARATOR - MENUITEM "&Печатать", MNID_FILE_PRINT - MENUITEM "Настройка &принтера...", MNID_FILE_SETUP - MENUITEM SEPARATOR - MENUITEM "&Выход", MNID_FILE_EXIT - } - POPUP "&Правка" { - MENUITEM "&Копировать...", MNID_EDIT_COPYDLG - MENUITEM SEPARATOR - MENUITEM "&Заметки...", MNID_EDIT_ANNOTATE - } - POPUP "&Закладка" { - MENUITEM "&Определить...", MNID_BKMK_DEFINE - } - POPUP "&Настройки" { - POPUP "Видимость окна справки" - BEGIN - MENUITEM "По умолчанию", MNID_OPTS_HELP_DEFAULT - MENUITEM "Наверху", MNID_OPTS_HELP_VISIBLE - MENUITEM "Не наверху", MNID_OPTS_HELP_NONVISIBLE - END - MENUITEM "История", MNID_OPTS_HISTORY - POPUP "Шрифт" - BEGIN - MENUITEM "Мелкий", MNID_OPTS_FONTS_SMALL - MENUITEM "Обычный", MNID_OPTS_FONTS_NORMAL - MENUITEM "Крупный", MNID_OPTS_FONTS_LARGE - END - MENUITEM "Использовать системные цвета", MNID_OPTS_SYSTEM_COLORS - } - POPUP "&Справка" { - MENUITEM "Помощь &по помощи", MNID_HELP_HELPON - MENUITEM "Всегда &сверху", MNID_HELP_HELPTOP - MENUITEM SEPARATOR - MENUITEM "&Информация...", MNID_HELP_ABOUT -#ifdef WINELIB - MENUITEM "&О Wine", MNID_HELP_WINE -#endif - } -} - -IDD_INDEX DIALOG DISCARDABLE 0, 0, 200, 190 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -FONT 8, "MS Shell Dlg" -CAPTION "Указатель" -{ - LISTBOX IDC_INDEXLIST, 10, 10, 180, 150, LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_BORDER -} - -/* Strings */ -STRINGTABLE DISCARDABLE -{ -STID_WINE_HELP, "Справка WINE" -STID_WHERROR, "ОШИБКА" -STID_WARNING, "ВНИМАНИЕ" -STID_INFO, "Информация" -STID_NOT_IMPLEMENTED, "Не реализованно" -STID_HLPFILE_ERROR_s, "Ошибка при чтении файла помощи `%s'" -STID_INDEX, "&Содержание" -STID_CONTENTS, "Начало" -STID_BACK, "&Назад" -STID_ALL_FILES, "Все файлы (*.*)" -STID_HELP_FILES_HLP, "Файлы справки (*.hlp)" -STID_FILE_NOT_FOUND_s "Не могу найти '%s'. Вы хотите найти этот файл самостоятельно?" -STID_NO_RICHEDIT "Не могу найти richedit" -STID_PSH_INDEX, "Содержание: " -} - -CONTEXT_MENU MENU -BEGIN - POPUP "" - BEGIN - MENUITEM "Заметки...", MNID_CTXT_ANNOTATE - MENUITEM "Копировать", MNID_CTXT_COPY - MENUITEM "Печать...", MNID_CTXT_PRINT - POPUP "Шрифт" - BEGIN - MENUITEM "Мелкий", MNID_CTXT_FONTS_SMALL - MENUITEM "Обычный", MNID_CTXT_FONTS_NORMAL - MENUITEM "Крупный", MNID_CTXT_FONTS_LARGE - END - POPUP "Видимость окна справки" - BEGIN - MENUITEM "По умолчанию", MNID_CTXT_HELP_DEFAULT - MENUITEM "Наверху", MNID_CTXT_HELP_VISIBLE - MENUITEM "Не наверху", MNID_CTXT_HELP_NONVISIBLE - END - MENUITEM "Использовать системные цвета", MNID_CTXT_SYSTEM_COLORS - END -END +/* + * Help Viewer (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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +/* Menu */ + +MAIN_MENU MENU LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT +{ + POPUP "&Ôàéë" { + MENUITEM "&Îòêðûòü", MNID_FILE_OPEN + MENUITEM SEPARATOR + MENUITEM "&Ïå÷àòàòü", MNID_FILE_PRINT + MENUITEM "Íàñòðîéêà &ïðèíòåðà...", MNID_FILE_SETUP + MENUITEM SEPARATOR + MENUITEM "&Âûõîä", MNID_FILE_EXIT + } + POPUP "&Ïðàâêà" { + MENUITEM "&Êîïèðîâàòü...", MNID_EDIT_COPYDLG + MENUITEM SEPARATOR + MENUITEM "&Çàìåòêè...", MNID_EDIT_ANNOTATE + } + POPUP "&Çàêëàäêà" { + MENUITEM "&Îïðåäåëèòü...", MNID_BKMK_DEFINE + } + POPUP "&Íàñòðîéêè" { + POPUP "Âèäèìîñòü îêíà ñïðàâêè" + BEGIN + MENUITEM "Ïî óìîë÷àíèþ", MNID_OPTS_HELP_DEFAULT + MENUITEM "Íàâåðõó", MNID_OPTS_HELP_VISIBLE + MENUITEM "Íå íàâåðõó", MNID_OPTS_HELP_NONVISIBLE + END + MENUITEM "Èñòîðèÿ", MNID_OPTS_HISTORY + POPUP "Øðèôò" + BEGIN + MENUITEM "Ìåëêèé", MNID_OPTS_FONTS_SMALL + MENUITEM "Îáû÷íûé", MNID_OPTS_FONTS_NORMAL + MENUITEM "Êðóïíûé", MNID_OPTS_FONTS_LARGE + END + MENUITEM "Èñïîëüçîâàòü ñèñòåìíûå öâåòà", MNID_OPTS_SYSTEM_COLORS + } + POPUP "&Ñïðàâêà" { + MENUITEM "Ïîìîùü &ïî ïîìîùè", MNID_HELP_HELPON + MENUITEM "Âñåãäà &ñâåðõó", MNID_HELP_HELPTOP + MENUITEM SEPARATOR + MENUITEM "&Èíôîðìàöèÿ...", MNID_HELP_ABOUT +#ifdef WINELIB + MENUITEM "&Î Wine", MNID_HELP_WINE +#endif + } +} + +IDD_INDEX DIALOG DISCARDABLE 0, 0, 200, 190 LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT +STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +FONT 8, "MS Shell Dlg" +CAPTION "Óêàçàòåëü" +{ + LISTBOX IDC_INDEXLIST, 10, 10, 180, 150, LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_BORDER +} + +/* Strings */ +STRINGTABLE DISCARDABLE LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT +{ +STID_WINE_HELP, "Ñïðàâêà WINE" +STID_WHERROR, "ÎØÈÁÊÀ" +STID_WARNING, "ÂÍÈÌÀÍÈÅ" +STID_INFO, "Èíôîðìàöèÿ" +STID_NOT_IMPLEMENTED, "Íå ðåàëèçîâàííî" +STID_HLPFILE_ERROR_s, "Îøèáêà ïðè ÷òåíèè ôàéëà ïîìîùè `%s'" +STID_INDEX, "&Ñîäåðæàíèå" +STID_CONTENTS, "Íà÷àëî" +STID_BACK, "&Íàçàä" +STID_ALL_FILES, "Âñå ôàéëû (*.*)" +STID_HELP_FILES_HLP, "Ôàéëû ñïðàâêè (*.hlp)" +STID_FILE_NOT_FOUND_s "Íå ìîãó íàéòè '%s'. Âû õîòèòå íàéòè ýòîò ôàéë ñàìîñòîÿòåëüíî?" +STID_NO_RICHEDIT "Íå ìîãó íàéòè richedit" +STID_PSH_INDEX, "Ñîäåðæàíèå: " +} + +CONTEXT_MENU MENU LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT +BEGIN + POPUP "" + BEGIN + MENUITEM "Çàìåòêè...", MNID_CTXT_ANNOTATE + MENUITEM "Êîïèðîâàòü", MNID_CTXT_COPY + MENUITEM "Ïå÷àòü...", MNID_CTXT_PRINT + POPUP "Øðèôò" + BEGIN + MENUITEM "Ìåëêèé", MNID_CTXT_FONTS_SMALL + MENUITEM "Îáû÷íûé", MNID_CTXT_FONTS_NORMAL + MENUITEM "Êðóïíûé", MNID_CTXT_FONTS_LARGE + END + POPUP "Âèäèìîñòü îêíà ñïðàâêè" + BEGIN + MENUITEM "Ïî óìîë÷àíèþ", MNID_CTXT_HELP_DEFAULT + MENUITEM "Íàâåðõó", MNID_CTXT_HELP_VISIBLE + MENUITEM "Íå íàâåðõó", MNID_CTXT_HELP_NONVISIBLE + END + MENUITEM "Èñïîëüçîâàòü ñèñòåìíûå öâåòà", MNID_CTXT_SYSTEM_COLORS + END +END diff --git a/programs/winhlp32/Si.rc b/programs/winhlp32/Si.rc index 527b45431ee..a742cafe05b 100644 --- a/programs/winhlp32/Si.rc +++ b/programs/winhlp32/Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - #pragma code_page(65001) /* Menu */ @@ -126,3 +124,5 @@ BEGIN MENUITEM "Uporabi sistemske barve", MNID_CTXT_SYSTEM_COLORS END END + +#pragma code_page(default) diff --git a/programs/winhlp32/Sk.rc b/programs/winhlp32/Sk.rc index 1b45e1fe89e..f8338323dee 100644 --- a/programs/winhlp32/Sk.rc +++ b/programs/winhlp32/Sk.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - MAIN_MENU MENU LANGUAGE LANG_SLOVAK, SUBLANG_DEFAULT { POPUP "&Súbor" { diff --git a/programs/winhlp32/Sv.rc b/programs/winhlp32/Sv.rc index 935b618909b..d3893284cae 100644 --- a/programs/winhlp32/Sv.rc +++ b/programs/winhlp32/Sv.rc @@ -22,8 +22,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL diff --git a/programs/winhlp32/Tr.rc b/programs/winhlp32/Tr.rc index 876f33caa2f..bbff7236580 100644 --- a/programs/winhlp32/Tr.rc +++ b/programs/winhlp32/Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Menu */ MAIN_MENU MENU LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT diff --git a/programs/winhlp32/Wa.rc b/programs/winhlp32/Wa.rc index f19ac84e4c3..1e44e4770fc 100644 --- a/programs/winhlp32/Wa.rc +++ b/programs/winhlp32/Wa.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - #ifdef LANG_WALON /* Menu */ diff --git a/programs/winhlp32/Zh.rc b/programs/winhlp32/Zh.rc index ed20356cf47..c0ed0176d77 100644 --- a/programs/winhlp32/Zh.rc +++ b/programs/winhlp32/Zh.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "winhelp_res.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -160,3 +158,5 @@ STID_FILE_NOT_FOUND_s "不能開啟檔案 '%s'. 你想要自己找這個檔案 STID_NO_RICHEDIT "找不到 richedit... 終止" STID_PSH_INDEX, "幫助內容: " } + +#pragma code_page(default) diff --git a/programs/winhlp32/macro.c b/programs/winhlp32/macro.c index fdec6b3dfa5..c2fc3ccc710 100644 --- a/programs/winhlp32/macro.c +++ b/programs/winhlp32/macro.c @@ -446,13 +446,10 @@ static void CALLBACK MACRO_GotoMark(LPCSTR str) void CALLBACK MACRO_HelpOn(void) { - WINHELP_WINDOW *win = MACRO_CurrentWindow(); - LPCSTR file = NULL; + LPCSTR file; WINE_TRACE("()\n"); - if (win && win->page && win->page->file) - file = win->page->file->help_on_file; - + file = MACRO_CurrentWindow()->page->file->help_on_file; if (!file) file = (Globals.wVersion > 4) ? "winhlp32.hlp" : "winhelp.hlp"; diff --git a/programs/winhlp32/rsrc.rc b/programs/winhlp32/rsrc.rc index 39652f4d2cb..2d258148fd4 100644 --- a/programs/winhlp32/rsrc.rc +++ b/programs/winhlp32/rsrc.rc @@ -19,7 +19,37 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include +#include + +#include "winhelp.h" #include "winhelp_res.h" /* @makedep: winhelp.ico */ IDI_WINHELP ICON DISCARDABLE winhelp.ico + +#include "Bg.rc" +#include "Cs.rc" +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Eo.rc" +#include "Es.rc" +#include "Fi.rc" +#include "Fr.rc" +#include "Hu.rc" +#include "It.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Rm.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sk.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Wa.rc" +#include "Zh.rc" diff --git a/programs/winhlp32/winhelp.c b/programs/winhlp32/winhelp.c index 4c2d1ff6f94..08d3875aba1 100644 --- a/programs/winhlp32/winhelp.c +++ b/programs/winhlp32/winhelp.c @@ -167,7 +167,7 @@ BOOL WINHELP_GetOpenFileName(LPSTR lpszFile, int len) lpszFile[0]='\0'; openfilename.lStructSize = sizeof(OPENFILENAME); - openfilename.hwndOwner = (Globals.active_win ? Globals.active_win->hMainWnd : 0); + openfilename.hwndOwner = NULL; openfilename.hInstance = Globals.hInstance; openfilename.lpstrFilter = szzFilter; openfilename.lpstrCustomFilter = 0; @@ -1736,7 +1736,7 @@ int PASCAL WinMain(HINSTANCE hInstance, HINSTANCE prev, LPSTR cmdline, int show) WINHELP_GetWindowInfo(hlpfile, wndname), show); /* Message loop */ - while ((Globals.win_list || Globals.active_popup) && GetMessage(&msg, 0, 0, 0)) + while (GetMessage(&msg, 0, 0, 0)) { TranslateMessage(&msg); DispatchMessage(&msg); diff --git a/programs/winhlp32/winhelp_res.h b/programs/winhlp32/winhelp_res.h index ba2f9799d25..e1c72ff54e0 100644 --- a/programs/winhlp32/winhelp_res.h +++ b/programs/winhlp32/winhelp_res.h @@ -1,6 +1,3 @@ -#include -#include - #define MNID_FILE_OPEN 0x101 #define MNID_FILE_PRINT 0x104 #define MNID_FILE_SETUP 0x106 diff --git a/programs/wordpad/Da.rc b/programs/wordpad/Da.rc index 34789469e5e..d09e90f9b72 100644 --- a/programs/wordpad/Da.rc +++ b/programs/wordpad/Da.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - LANGUAGE LANG_DANISH, SUBLANG_DEFAULT IDM_MAINMENU MENU DISCARDABLE diff --git a/programs/wordpad/De.rc b/programs/wordpad/De.rc index 18181b2efba..a2fcceb61c4 100644 --- a/programs/wordpad/De.rc +++ b/programs/wordpad/De.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -246,3 +244,5 @@ BEGIN STRING_PRINTING_NOT_IMPLEMENTED, "Drucken ist nicht implementiert" STRING_MAX_TAB_STOPS, "Es können nur maximal 32 Tabstopps definiert werden." END + +#pragma code_page(default) diff --git a/programs/wordpad/En.rc b/programs/wordpad/En.rc index b6ade3aaf3d..dd099e13349 100644 --- a/programs/wordpad/En.rc +++ b/programs/wordpad/En.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT IDM_MAINMENU MENU DISCARDABLE @@ -179,14 +177,10 @@ END STRINGTABLE DISCARDABLE BEGIN - STRING_ALL_FILES, "All documents (*.*)" + STRING_RICHTEXT_FILES_RTF, "Rich text format (*.rtf)" STRING_TEXT_FILES_TXT, "Text documents (*.txt)" STRING_TEXT_FILES_UNICODE_TXT, "Unicode text document (*.txt)" - STRING_RICHTEXT_FILES_RTF, "Rich text format (*.rtf)" - STRING_NEWFILE_RICHTEXT, "Rich text document" - STRING_NEWFILE_TXT, "Text document" - STRING_NEWFILE_TXT_UNICODE, "Unicode text document" - STRING_PRINTER_FILES_PRN, "Printer files (*.PRN)" + STRING_ALL_FILES, "All documents (*.*)" END STRINGTABLE DISCARDABLE @@ -198,6 +192,18 @@ END STRINGTABLE DISCARDABLE BEGIN + STRING_NEWFILE_RICHTEXT, "Rich text document" + STRING_NEWFILE_TXT, "Text document" + STRING_NEWFILE_TXT_UNICODE, "Unicode text document" +END + +STRINGTABLE DISCARDABLE +BEGIN + STRING_PRINTER_FILES_PRN, "Printer files (*.PRN)" +END + +STRINGTABLE DISCARDABLE +BEGIN STRING_VIEWPROPS_TITLE, "Options" STRING_VIEWPROPS_TEXT, "Text" STRING_VIEWPROPS_RICHTEXT, "Rich text" @@ -211,7 +217,11 @@ BEGIN STRING_PREVIEW_TWOPAGES, "Two pages" STRING_PREVIEW_ONEPAGE, "One page" STRING_PREVIEW_CLOSE, "Close" - STRING_UNITS_CM, "cm" +END + +STRINGTABLE DISCARDABLE +BEGIN + STRING_UNITS_CM, "cm" END STRINGTABLE DISCARDABLE @@ -232,12 +242,3 @@ BEGIN STRING_PRINTING_NOT_IMPLEMENTED, "Printing not implemented" STRING_MAX_TAB_STOPS, "Cannot add more than 32 tab stops." END - -LANGUAGE LANG_ENGLISH, SUBLANG_NEUTRAL - -STRINGTABLE DISCARDABLE -BEGIN - STRING_ALIGN_LEFT, "Left" - STRING_ALIGN_RIGHT, "Right" - STRING_ALIGN_CENTER, "Centre" -END diff --git a/programs/wordpad/Fr.rc b/programs/wordpad/Fr.rc index 9691c0b0cc3..72f7c70e845 100644 --- a/programs/wordpad/Fr.rc +++ b/programs/wordpad/Fr.rc @@ -16,11 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL IDM_MAINMENU MENU DISCARDABLE @@ -33,44 +28,44 @@ BEGIN MENUITEM "Enregistrer &sous...", ID_FILE_SAVEAS MENUITEM SEPARATOR MENUITEM "&Imprimer...\tCtrl+P", ID_PRINT - MENUITEM "A&perçu avant impression...", ID_PREVIEW + MENUITEM "A&perçu avant impression...", ID_PREVIEW MENUITEM "&Mise en page...", ID_PRINTSETUP MENUITEM SEPARATOR MENUITEM "&Quitter", ID_FILE_EXIT END - POPUP "É&dition" + POPUP "É&dition" BEGIN MENUITEM "&Annuler\tCtrl+Z", ID_EDIT_UNDO - MENUITEM "&Rétablir\tCtrl+Y", ID_EDIT_REDO + MENUITEM "&Rétablir\tCtrl+Y", ID_EDIT_REDO MENUITEM SEPARATOR MENUITEM "&Couper\tCtrl+X", ID_EDIT_CUT MENUITEM "Co&pier\tCtrl+C", ID_EDIT_COPY MENUITEM "C&oller\tCtrl+V", ID_EDIT_PASTE MENUITEM "&Effacer\tDel", ID_EDIT_CLEAR - MENUITEM "&Sélectionner tout\tCtrl+A", ID_EDIT_SELECTALL + MENUITEM "&Sélectionner tout\tCtrl+A", ID_EDIT_SELECTALL MENUITEM SEPARATOR MENUITEM "&Rechercher...\tCrtl+F", ID_FIND MENUITEM "Rechercher le &suivant\tF3", ID_FIND_NEXT MENUITEM "&Remplacer...\tCtrl+H", ID_REPLACE MENUITEM SEPARATOR - MENUITEM "Lecture &seule", ID_EDIT_READONLY - MENUITEM "&Modifié", ID_EDIT_MODIFIED + MENUITEM "Lecture-&seule", ID_EDIT_READONLY + MENUITEM "&Modifié", ID_EDIT_MODIFIED MENUITEM SEPARATOR - POPUP "&Avancé" + POPUP "&Avancés" BEGIN - MENUITEM "&Information sélection", ID_EDIT_SELECTIONINFO - MENUITEM "&Format caractères", ID_EDIT_CHARFORMAT - MENUITEM "&Déf. format car.", ID_EDIT_DEFCHARFORMAT + MENUITEM "&Information sélection", ID_EDIT_SELECTIONINFO + MENUITEM "&Format caractères", ID_EDIT_CHARFORMAT + MENUITEM "&Déf. format car.", ID_EDIT_DEFCHARFORMAT MENUITEM "Format paragrap&he", ID_EDIT_PARAFORMAT - MENUITEM "Texte &complet", ID_EDIT_GETTEXT + MENUITEM "&Recevoir texte", ID_EDIT_GETTEXT END END POPUP "&Affichage" BEGIN MENUITEM "&Barre d'outils", ID_TOGGLE_TOOLBAR MENUITEM "&Barre de format", ID_TOGGLE_FORMATBAR - MENUITEM "&Règle", ID_TOGGLE_RULER - MENUITEM "&Barre d'état", ID_TOGGLE_STATUSBAR + MENUITEM "&Règle", ID_TOGGLE_RULER + MENUITEM "&Barre d'état", ID_TOGGLE_STATUSBAR MENUITEM SEPARATOR MENUITEM "&Options...", ID_VIEWPROPERTIES END @@ -81,18 +76,18 @@ BEGIN POPUP "Forma&t" BEGIN MENUITEM "&Police...", ID_FONTSETTINGS - MENUITEM "Pu&ces" ID_BULLET - MENUITEM "Para&graphe..." ID_PARAFORMAT + MENUITEM "&Puces" ID_BULLET + MENUITEM "&Paragraphe..." ID_PARAFORMAT MENUITEM "&Tabulations..." ID_TABSTOPS - POPUP "&Arrière-plan" + POPUP "&Fond" BEGIN - MENUITEM "&Système\tCtrl+1", ID_BACK_1 - MENUITEM "&Jaune pâle\tCtrl+2", ID_BACK_2 + MENUITEM "&Système\tCtrl+1", ID_BACK_1 + MENUITEM "&Jaunasse\tCtrl+2", ID_BACK_2 END END POPUP "Aid&e" BEGIN - MENUITEM "À &propos du Wordpad de Wine" ID_ABOUT + MENUITEM "À &propos du Wordpad de Wine" ID_ABOUT END END @@ -104,8 +99,8 @@ BEGIN MENUITEM "Co&pier", ID_EDIT_COPY MENUITEM "C&oller", ID_EDIT_PASTE MENUITEM SEPARATOR - MENUITEM "P&uces" ID_BULLET - MENUITEM "Para&graphe" ID_PARAFORMAT + MENUITEM "&Puces" ID_BULLET + MENUITEM "&Paragraphe" ID_PARAFORMAT END END @@ -141,7 +136,7 @@ BEGIN EDITTEXT IDC_PARA_LEFT, 55, 20, 60, 13 LTEXT "Droite", -1, 15, 40, 40, 13 EDITTEXT IDC_PARA_RIGHT, 55, 38, 60, 13 - LTEXT "Première ligne", -1, 15, 58, 40, 18 + LTEXT "Première ligne", -1, 15, 58, 40, 18 EDITTEXT IDC_PARA_FIRST, 55, 56, 60, 13 LTEXT "Alignement", -1, 15, 87, 40, 13 COMBOBOX IDC_PARA_ALIGN, 55, 85, 60, 60, CBS_DROPDOWNLIST @@ -154,13 +149,13 @@ STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU Caption "Tabulations" FONT 8, "MS SHell DLg" BEGIN - GROUPBOX "Taquets de tabulation", -1, 10, 10, 120, 90 + GROUPBOX "Arrêts de tabulation", -1, 10, 10, 120, 90 COMBOBOX IDC_TABSTOPS, 20, 20, 100, 60, CBS_SIMPLE - DEFPUSHBUTTON "A&jouter", ID_TAB_ADD, 20, 80, 45, 15 + DEFPUSHBUTTON "&Ajouter", ID_TAB_ADD, 20, 80, 45, 15 PUSHBUTTON "&Supprimer", ID_TAB_DEL, 72, 80, 45, 15 - PUSHBUTTON "&OK", IDOK, 137, 15, 56, 15 - PUSHBUTTON "&Annuler", IDCANCEL, 137, 33, 56, 15 - PUSHBUTTON "Supprimer &tous", ID_TAB_EMPTY, 137, 51, 56, 15 + PUSHBUTTON "&OK", IDOK, 137, 15, 50, 15 + PUSHBUTTON "&Annuler", IDCANCEL, 137, 33, 50, 15 + PUSHBUTTON "Supprimer &tous", ID_TAB_EMPTY, 137, 51, 50, 15 END IDD_FORMATOPTS DIALOG DISCARDABLE 0, 0, 280, 110 @@ -168,23 +163,23 @@ STYLE DS_SYSMODAL Caption "" FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX "Passage à la ligne automatique", -1, 10, 10, 140, 85 - RADIOBUTTON "&Aucun", IDC_PAGEFMT_WN, 18, 25, 127, 15 - RADIOBUTTON "Au niveau de la bordure de fe&nêtre", IDC_PAGEFMT_WW, 18, 45, 127, 15 - RADIOBUTTON "Au niveau de la &marge", IDC_PAGEFMT_WM, 18, 65, 127, 15 - GROUPBOX "Barres d'outils", -1, 156, 10, 115, 85 - CHECKBOX "&Barre d'outils", IDC_PAGEFMT_TB, 166, 20, 80, 15 - CHECKBOX "Barre de &format", IDC_PAGEFMT_FB, 166, 38, 80, 15 - CHECKBOX "&Règle", IDC_PAGEFMT_RU, 166, 56, 80, 15 - CHECKBOX "Barre de &statut", IDC_PAGEFMT_SB, 166, 74, 80, 15 + GROUPBOX "Enveloppement de ligne", -1, 10, 10, 170, 85 + RADIOBUTTON "No line wrapping", IDC_PAGEFMT_WN, 18, 25, 145, 15 + RADIOBUTTON "Enveloppe le texte à partir de la bordure de fenêtre", IDC_PAGEFMT_WW, 18, 45, 145, 15 + RADIOBUTTON "Enveloppe le texte à partir de la &marge", IDC_PAGEFMT_WM, 18, 65, 145, 15 + GROUPBOX "Barres d'outils", -1, 170, 10, 120, 85 + CHECKBOX "&Barre d'outils", IDC_PAGEFMT_TB, 180, 20, 80, 15 + CHECKBOX "Barre de &format", IDC_PAGEFMT_FB, 180, 38, 80, 15 + CHECKBOX "&Règle", IDC_PAGEFMT_RU, 180, 56, 80, 15 + CHECKBOX "Barre de &statut", IDC_PAGEFMT_SB, 180, 74, 80, 15 LTEXT "", IDC_PAGEFMT_ID, 0,0,0,0 END STRINGTABLE DISCARDABLE BEGIN - STRING_RICHTEXT_FILES_RTF, "Format de texte enrichi (*.rtf)" + STRING_RICHTEXT_FILES_RTF, "Documents texte riche (*.rtf)" STRING_TEXT_FILES_TXT, "Documents texte (*.txt)" - STRING_TEXT_FILES_UNICODE_TXT, "Documents texte Unicode (*.txt)" + STRING_TEXT_FILES_UNICODE_TXT, "Documents texte unicode (*.txt)" STRING_ALL_FILES, "Tous les documents (*.*)" END @@ -197,9 +192,9 @@ END STRINGTABLE DISCARDABLE BEGIN - STRING_NEWFILE_RICHTEXT, "Format de texte enrichi (RTF)" + STRING_NEWFILE_RICHTEXT, "Document texte riche" STRING_NEWFILE_TXT, "Document texte" - STRING_NEWFILE_TXT_UNICODE, "Document texte Unicode" + STRING_NEWFILE_TXT_UNICODE, "Document texte unicode" END STRINGTABLE DISCARDABLE @@ -218,7 +213,7 @@ STRINGTABLE DISCARDABLE BEGIN STRING_PREVIEW_PRINT, "Imprimer" STRING_PREVIEW_NEXTPAGE, "Page suivante" - STRING_PREVIEW_PREVPAGE, "Page précédente" + STRING_PREVIEW_PREVPAGE, "Page précédente" STRING_PREVIEW_TWOPAGES, "Deux pages" STRING_PREVIEW_ONEPAGE, "Une page" STRING_PREVIEW_CLOSE, "Fermer" @@ -232,18 +227,18 @@ END STRINGTABLE DISCARDABLE BEGIN STRING_DEFAULT_FILENAME, "Document" - STRING_PROMPT_SAVE_CHANGES, "Enregistrer les modifications de « %s » ?" - STRING_SEARCH_FINISHED, "Recherche terminée dans le document." - STRING_LOAD_RICHED_FAILED, "Impossible de charger la bibliothèque RichEdit." + STRING_PROMPT_SAVE_CHANGES, "Enregistrer les modifications de « %s » ?" + STRING_SEARCH_FINISHED, "Recherche terminée dans le document." + STRING_LOAD_RICHED_FAILED, "Impossible de charger la bibliothèque RichEdit." STRING_SAVE_LOSEFORMATTING, "Vous avez choisi d'enregistrer en texte simple, " \ "ce qui causera la perte de tout formattage. " \ - "Voulez-vous vraiment continuer ?" + "Voulez-vous vraiment continuer ?" STRING_INVALID_NUMBER, "Format de nombre invalide" - STRING_OLE_STORAGE_NOT_SUPPORTED, "Les documents conteneur OLE ne sont pas supportés" + STRING_OLE_STORAGE_NOT_SUPPORTED, "Les documents conteneur OLE ne sont pas supportés" STRING_WRITE_FAILED, "Impossible d'enregistrer le fichier." - STRING_WRITE_ACCESS_DENIED, "Vous ne disposez pas des accès nécessaires à l'enregistrement du fichier." + STRING_WRITE_ACCESS_DENIED, "Vous ne disposez pas des accès nécessaires à l'enregistrement du fichier." STRING_OPEN_FAILED, "Impossible d'ouvrir le fichier." - STRING_OPEN_ACCESS_DENIED, "Vous ne disposez pas des accès nécessaires à l'ouverture du fichier." - STRING_PRINTING_NOT_IMPLEMENTED, "L'impression n'est pas implémentée" + STRING_OPEN_ACCESS_DENIED, "Vous ne disposez pas des accès nécessaires à l'ouverture du fichier." + STRING_PRINTING_NOT_IMPLEMENTED, "L'impression n'est pas implémentée" STRING_MAX_TAB_STOPS, "Impossible d'ajouter plus de 32 taquets de tabulation." END diff --git a/programs/wordpad/Hu.rc b/programs/wordpad/Hu.rc index 74926e1e597..94ceda5a789 100644 --- a/programs/wordpad/Hu.rc +++ b/programs/wordpad/Hu.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT IDM_MAINMENU MENU DISCARDABLE diff --git a/programs/wordpad/Ja.rc b/programs/wordpad/Ja.rc index fc21c5a4e74..09e48aafdf5 100644 --- a/programs/wordpad/Ja.rc +++ b/programs/wordpad/Ja.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - /* UTF-8 */ #pragma code_page(65001) @@ -244,6 +242,6 @@ BEGIN STRING_WRITE_ACCESS_DENIED, "ファイルに保存する権限がありません。" STRING_OPEN_FAILED, "ファイルを開けません。" STRING_OPEN_ACCESS_DENIED, "ファイルを開く権限がありません。" - STRING_PRINTING_NOT_IMPLEMENTED, "プリントが実装されていません。" - STRING_MAX_TAB_STOPS, "32以上なタブを追加できません。" END + +#pragma code_page(default) diff --git a/programs/wordpad/Ko.rc b/programs/wordpad/Ko.rc index 58235857018..7bfaf00e767 100644 --- a/programs/wordpad/Ko.rc +++ b/programs/wordpad/Ko.rc @@ -17,7 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT diff --git a/programs/wordpad/Lt.rc b/programs/wordpad/Lt.rc deleted file mode 100644 index 91fbfcaba91..00000000000 --- a/programs/wordpad/Lt.rc +++ /dev/null @@ -1,249 +0,0 @@ -/* - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "wordpad.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -IDM_MAINMENU MENU DISCARDABLE -BEGIN - POPUP "&Failas" - BEGIN - MENUITEM "&Naujas...\tCtrl+N", ID_FILE_NEW - MENUITEM "&Atverti...\tCtrl+O", ID_FILE_OPEN - MENUITEM "&Išsaugoti\tCtrl+S", ID_FILE_SAVE - MENUITEM "Išsaugoti &kaip...", ID_FILE_SAVEAS - MENUITEM SEPARATOR - MENUITEM "S&pausdinti...\tCtrl+P", ID_PRINT - MENUITEM "Spaudinio pe&ržiūra...", ID_PREVIEW - MENUITEM "Puslapio n&uostatos...", ID_PRINTSETUP - MENUITEM SEPARATOR - MENUITEM "Iš&eiti", ID_FILE_EXIT - END - POPUP "&Taisa" - BEGIN - MENUITEM "&Atšaukti\tCtrl+Z", ID_EDIT_UNDO - MENUITEM "&Grąžinti\tCtrl+Y", ID_EDIT_REDO - MENUITEM SEPARATOR - MENUITEM "&Iškirpti\tCtrl+X", ID_EDIT_CUT - MENUITEM "&Kopijuoti\tCtrl+C", ID_EDIT_COPY - MENUITEM "Į&dėti\tCtrl+V", ID_EDIT_PASTE - MENUITEM "&Šalinti\tDEL", ID_EDIT_CLEAR - MENUITEM "&Pažymėti viską\tCtrl+A", ID_EDIT_SELECTALL - MENUITEM SEPARATOR - MENUITEM "I&eškoti...\tCrtl+F", ID_FIND - MENUITEM "Iešk&oti kito\tF3", ID_FIND_NEXT - MENUITEM "Pa&keisti...\tCtrl+H", ID_REPLACE - MENUITEM SEPARATOR - MENUITEM "Tik skait&ymui", ID_EDIT_READONLY - MENUITEM "&Modifikuotas", ID_EDIT_MODIFIED - MENUITEM SEPARATOR - POPUP "Papi&ldomi" - BEGIN - MENUITEM "Žymėjimo &informacija", ID_EDIT_SELECTIONINFO - MENUITEM "Rašmenų &formatas", ID_EDIT_CHARFORMAT - MENUITEM "&Numatytas rašmenų formatas", ID_EDIT_DEFCHARFORMAT - MENUITEM "&Pastraipos formatas", ID_EDIT_PARAFORMAT - MENUITEM "&Gauti tekstą", ID_EDIT_GETTEXT - END - END - POPUP "&Rodymas" - BEGIN - MENUITEM "&Įrankių juosta", ID_TOGGLE_TOOLBAR - MENUITEM "&Formatų juosta", ID_TOGGLE_FORMATBAR - MENUITEM "&Liniuotė", ID_TOGGLE_RULER - MENUITEM "&Būsenos juosta", ID_TOGGLE_STATUSBAR - MENUITEM SEPARATOR - MENUITEM "&Parinktys...", ID_VIEWPROPERTIES - END - POPUP "Įter&pimas" - BEGIN - MENUITEM "&Data ir laikas...", ID_DATETIME - END - POPUP "F&ormatas" - BEGIN - MENUITEM "&Šriftas...", ID_FONTSETTINGS - MENUITEM "&Ženkleliai" ID_BULLET - MENUITEM "&Pastraipa..." ID_PARAFORMAT - MENUITEM "&Tabuliavimo žymės..." ID_TABSTOPS - POPUP "&Fonas" - BEGIN - MENUITEM "&Sistemos\tCtrl+1", ID_BACK_1 - MENUITEM "&Gelsvas\tCtrl+2", ID_BACK_2 - END - END - POPUP "&Žinynas" - BEGIN - MENUITEM "&Apie Wine Wordpad" ID_ABOUT - END -END - -IDM_POPUP MENU DISCARDABLE -BEGIN - POPUP "" - BEGIN - MENUITEM "&Iškirpti", ID_EDIT_CUT - MENUITEM "&Kopijuoti", ID_EDIT_COPY - MENUITEM "Į&dėti", ID_EDIT_PASTE - MENUITEM SEPARATOR - MENUITEM "&Ženkleliai" ID_BULLET - MENUITEM "&Pastraipa..." ID_PARAFORMAT - END -END - -IDD_DATETIME DIALOG DISCARDABLE 30, 20, 130, 80 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Data ir laikas" -FONT 10, "MS Sans Serif" -BEGIN - LTEXT "Galimi formatai",-1,3,2,100,15 - LISTBOX IDC_DATETIME,3,12,80,65,LBS_NOINTEGRALHEIGHT | LBS_NOTIFY - PUSHBUTTON "&Gerai",IDOK,87,12,40,12 - PUSHBUTTON "&Atsisakyti",IDCANCEL,87,26,40,12 -END - -IDD_NEWFILE DIALOG DISCARDABLE 30, 20, 140, 80 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Naujas" -FONT 10, "MS Sans Serif" -BEGIN - LTEXT "Naujo dokumento tipas",-1,3,2,100,15 - LISTBOX IDC_NEWFILE,3,12,90,65,LBS_NOINTEGRALHEIGHT - PUSHBUTTON "&Gerai",IDOK,97,12,40,12 - PUSHBUTTON "&Atsisakyti",IDCANCEL,97,26,40,12 -END - -IDD_PARAFORMAT DIALOG DISCARDABLE 30, 20, 200, 110 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -Caption "Pastraipos formatas" -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "Įtrauka", -1, 10, 10, 120, 68 - LTEXT "Iš kairės", -1, 15, 22, 45, 13 - EDITTEXT IDC_PARA_LEFT, 60, 20, 55, 13 - LTEXT "Iš dešinės", -1, 15, 40, 45, 13 - EDITTEXT IDC_PARA_RIGHT, 60, 38, 55, 13 - LTEXT "Pirmoji eilutė", -1, 15, 58, 45, 13 - EDITTEXT IDC_PARA_FIRST, 60, 56, 55, 13 - LTEXT "Lygiuotė", -1, 15, 87, 40, 13 - COMBOBOX IDC_PARA_ALIGN, 55, 85, 60, 60, CBS_DROPDOWNLIST - PUSHBUTTON "&Gerai", IDOK, 137, 15, 50, 15 - PUSHBUTTON "&Atsisakyti", IDCANCEL, 137, 33, 50, 15 -END - -IDD_TABSTOPS DIALOG DISCARDABLE 30, 20, 200, 110 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -Caption "Tabuliavimo žymės" -FONT 8, "MS SHell DLg" -BEGIN - GROUPBOX "Tabuliavimo pozicija", -1, 10, 10, 120, 90 - COMBOBOX IDC_TABSTOPS, 20, 20, 100, 60, CBS_SIMPLE - DEFPUSHBUTTON "&Pridėti", ID_TAB_ADD, 20, 80, 45, 15 - PUSHBUTTON "Pa&šalinti", ID_TAB_DEL, 72, 80, 45, 15 - PUSHBUTTON "&Gerai", IDOK, 137, 15, 50, 15 - PUSHBUTTON "&Atsisakyti", IDCANCEL, 137, 33, 50, 15 - PUSHBUTTON "Pašalinti &visas", ID_TAB_EMPTY, 137, 51, 50, 15 -END - -IDD_FORMATOPTS DIALOG DISCARDABLE 0, 0, 280, 110 -STYLE DS_SYSMODAL -Caption "" -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "Eilutės skaidymas", -1, 10, 10, 130, 85 - RADIOBUTTON "&Eilutės neskaidomos", IDC_PAGEFMT_WN, 18, 25, 117, 15 - RADIOBUTTON "Skaidyti tekstą prie lango &rėmelio", IDC_PAGEFMT_WW, 18, 45, 117, 15 - RADIOBUTTON "Skaidyti tekstą prie ¶štės", IDC_PAGEFMT_WM, 18, 65, 117, 15 - GROUPBOX "Įrankių juostos", -1, 150, 10, 120, 85 - CHECKBOX "Įran&kių juosta", IDC_PAGEFMT_TB, 160, 20, 80, 15 - CHECKBOX "&Formatų juosta", IDC_PAGEFMT_FB, 160, 38, 80, 15 - CHECKBOX "&Liniuotė", IDC_PAGEFMT_RU, 160, 56, 80, 15 - CHECKBOX "&Būsenos juosta", IDC_PAGEFMT_SB, 160, 74, 80, 15 - LTEXT "", IDC_PAGEFMT_ID, 0,0,0,0 -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_RICHTEXT_FILES_RTF, "Raiškiojo teksto dokumentai (*.rtf)" - STRING_TEXT_FILES_TXT, "Tekstiniai dokumentai (*.txt)" - STRING_TEXT_FILES_UNICODE_TXT, "Teksto unikodu dokumentai (*.txt)" - STRING_ALL_FILES, "Visi dokumentai (*.*)" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_ALIGN_LEFT, "Kairinė" - STRING_ALIGN_RIGHT, "Dešininė" - STRING_ALIGN_CENTER, "Centrinė" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_NEWFILE_RICHTEXT, "Raiškiojo teksto dokumentas" - STRING_NEWFILE_TXT, "Tekstinis dokumentas" - STRING_NEWFILE_TXT_UNICODE, "Teksto unikodu dokumentas" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_PRINTER_FILES_PRN, "Spausdintuvo failai (*.PRN)" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_VIEWPROPS_TITLE, "Parinktys" - STRING_VIEWPROPS_TEXT, "Tekstas" - STRING_VIEWPROPS_RICHTEXT, "Raiškusis tekstas" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_PREVIEW_PRINT, "Spausdinti" - STRING_PREVIEW_NEXTPAGE, "Tolesnis puslapis" - STRING_PREVIEW_PREVPAGE, "Ankstesnis puslapis" - STRING_PREVIEW_TWOPAGES, "Du puslapiai" - STRING_PREVIEW_ONEPAGE, "Vienas puslapis" - STRING_PREVIEW_CLOSE, "Užverti" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_UNITS_CM, "cm" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_DEFAULT_FILENAME, "Dokumentas" - STRING_PROMPT_SAVE_CHANGES, "Išsaugoti „%s“ pakeitimus?" - STRING_SEARCH_FINISHED, "Paieška dokumente baigta." - STRING_LOAD_RICHED_FAILED, "Nepavyko įkelti RichEdit bibliotekos." - STRING_SAVE_LOSEFORMATTING, "Jūs pasirinkote išsaugoti paprasto teksto formatu, " \ - "todėl bus prarastas visas formatavimas. " \ - "Ar tikrai norite tai padaryti?" - STRING_INVALID_NUMBER, "Neteisingas skaičiaus formatas" - STRING_OLE_STORAGE_NOT_SUPPORTED, "OLE saugyklos dokumentai yra nepalaikomi" - STRING_WRITE_FAILED, "Nepavyko išsaugoti failo." - STRING_WRITE_ACCESS_DENIED, "Jūs neturite prieigos failui išsaugoti." - STRING_OPEN_FAILED, "Nepavyko atverti failo." - STRING_OPEN_ACCESS_DENIED, "Jūs neturite prieigos failui atverti." - STRING_PRINTING_NOT_IMPLEMENTED, "Spausdinimas nerealizuotas" - STRING_MAX_TAB_STOPS, "Negalima pridėti daugiau negu 32-jų tabuliavimo pozicijų." -END diff --git a/programs/wordpad/Makefile.in b/programs/wordpad/Makefile.in index e7f5b085703..461da31d7ae 100644 --- a/programs/wordpad/Makefile.in +++ b/programs/wordpad/Makefile.in @@ -14,25 +14,7 @@ C_SRCS = \ registry.c \ wordpad.c -RC_SRCS = \ - Da.rc \ - De.rc \ - En.rc \ - Fr.rc \ - Hu.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Si.rc \ - Sv.rc \ - Tr.rc \ - Zh.rc \ - rsrc.rc +RC_SRCS = rsrc.rc SVG_SRCS = wordpad.svg diff --git a/programs/wordpad/Nl.rc b/programs/wordpad/Nl.rc index 10729e41df5..c91e028c3e4 100644 --- a/programs/wordpad/Nl.rc +++ b/programs/wordpad/Nl.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL IDM_MAINMENU MENU DISCARDABLE @@ -180,14 +178,10 @@ END STRINGTABLE DISCARDABLE BEGIN - STRING_ALL_FILES, "Alle documenten (*.*)" + STRING_RICHTEXT_FILES_RTF, "Rich text formaat (*.rtf)" STRING_TEXT_FILES_TXT, "Tekst documenten (*.txt)" STRING_TEXT_FILES_UNICODE_TXT, "Unicode tekst document (*.txt)" - STRING_RICHTEXT_FILES_RTF, "Rich text formaat (*.rtf)" - STRING_NEWFILE_RICHTEXT, "Rich tekst document" - STRING_NEWFILE_TXT, "Tekst document" - STRING_NEWFILE_TXT_UNICODE, "Unicode tekst document" - STRING_PRINTER_FILES_PRN, "Printer bestanden (*.PRN)" + STRING_ALL_FILES, "Alle documenten (*.*)" END STRINGTABLE DISCARDABLE @@ -199,6 +193,18 @@ END STRINGTABLE DISCARDABLE BEGIN + STRING_NEWFILE_RICHTEXT, "Rich tekst document" + STRING_NEWFILE_TXT, "Tekst document" + STRING_NEWFILE_TXT_UNICODE, "Unicode tekst document" +END + +STRINGTABLE DISCARDABLE +BEGIN + STRING_PRINTER_FILES_PRN, "Printer bestanden (*.PRN)" +END + +STRINGTABLE DISCARDABLE +BEGIN STRING_VIEWPROPS_TITLE, "Opties" STRING_VIEWPROPS_TEXT, "Tekst" STRING_VIEWPROPS_RICHTEXT, "Rich tekst" diff --git a/programs/wordpad/No.rc b/programs/wordpad/No.rc index 5a4fdbf8c30..6261c6fb81d 100644 --- a/programs/wordpad/No.rc +++ b/programs/wordpad/No.rc @@ -1,5 +1,5 @@ /* - * Copyright 2006-2009 by Alexander N. Sørnes + * Copyright 2006-2008 by Alexander N. Sørnes * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -16,10 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - -#pragma code_page(65001) - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL IDM_MAINMENU MENU DISCARDABLE @@ -27,12 +23,12 @@ BEGIN POPUP "&Fil" BEGIN MENUITEM "&Ny...\tCtrl+N", ID_FILE_NEW - MENUITEM "&Åpne...\tCtrl+O", ID_FILE_OPEN + MENUITEM "&Åpne...\tCtrl+O", ID_FILE_OPEN MENUITEM "&Lagre\tCtrl+S", ID_FILE_SAVE MENUITEM "Lagre &som...", ID_FILE_SAVEAS MENUITEM SEPARATOR MENUITEM "&Skriv ut...\tCtrl+P", ID_PRINT - MENUITEM "&Forhåndsvisning...", ID_PREVIEW + MENUITEM "&Forhåndsvisning...", ID_PREVIEW MENUITEM "&Utskriftformat...", ID_PRINTSETUP MENUITEM SEPARATOR MENUITEM "&Avslutt", ID_FILE_EXIT @@ -48,8 +44,8 @@ BEGIN MENUITEM "&Fjern\tDEL", ID_EDIT_CLEAR MENUITEM "&Merk alt\tCtrl+A", ID_EDIT_SELECTALL MENUITEM SEPARATOR - MENUITEM "&Søk etter...\tCrtl+F", ID_FIND - MENUITEM "Søk etter &neste\tF3", ID_FIND_NEXT + MENUITEM "&Søk etter...\tCrtl+F", ID_FIND + MENUITEM "Søk etter &neste\tF3", ID_FIND_NEXT MENUITEM "E&rstatt...\tCtrl+H", ID_REPLACE MENUITEM SEPARATOR MENUITEM "S&krivebeskyttet", ID_EDIT_READONLY @@ -57,7 +53,7 @@ BEGIN MENUITEM SEPARATOR POPUP "&Ekstra" BEGIN - MENUITEM "&Info om merket område", ID_EDIT_SELECTIONINFO + MENUITEM "&Info om merket område", ID_EDIT_SELECTIONINFO MENUITEM "Tegn&format", ID_EDIT_CHARFORMAT MENUITEM "Stan&dard tegnformat", ID_EDIT_DEFCHARFORMAT MENUITEM "&Avsnittformat", ID_EDIT_PARAFORMAT @@ -66,7 +62,7 @@ BEGIN END POPUP "&Vis" BEGIN - MENUITEM "Verk&tøylinje", ID_TOGGLE_TOOLBAR + MENUITEM "Verk&tøylinje", ID_TOGGLE_TOOLBAR MENUITEM "&Formatlinje", ID_TOGGLE_FORMATBAR MENUITEM "&Linjal", ID_TOGGLE_RULER MENUITEM "&Statuslinje", ID_TOGGLE_STATUSBAR @@ -138,9 +134,9 @@ BEGIN GROUPBOX "Innrykk", -1, 10, 10, 120, 68 LTEXT "Venstre", -1, 15, 22, 40, 13 EDITTEXT IDC_PARA_LEFT, 55, 20, 60, 13 - LTEXT "Høyre", -1, 15, 40, 40, 13 + LTEXT "Høyre", -1, 15, 40, 40, 13 EDITTEXT IDC_PARA_RIGHT, 55, 38, 60, 13 - LTEXT "Første linje", -1, 15, 58, 40, 13 + LTEXT "Første linje", -1, 15, 58, 40, 13 EDITTEXT IDC_PARA_FIRST, 55, 56, 60, 13 LTEXT "Justering", -1, 15, 87, 40, 13 COMBOBOX IDC_PARA_ALIGN, 55, 85, 60, 60, CBS_DROPDOWNLIST @@ -171,8 +167,8 @@ BEGIN RADIOBUTTON "No line wrapping", IDC_PAGEFMT_WN, 18, 25, 117, 15 RADIOBUTTON "Bryt tekst etter v&indusbredden", IDC_PAGEFMT_WW, 18, 45, 117, 15 RADIOBUTTON "Bryt tekst etter &margen", IDC_PAGEFMT_WM, 18, 65, 117, 15 - GROUPBOX "Verktøylinjer", -1, 150, 10, 120, 85 - CHECKBOX "&Verktøylinje", IDC_PAGEFMT_TB, 160, 20, 80, 15 + GROUPBOX "Verktøylinjer", -1, 150, 10, 120, 85 + CHECKBOX "&Verktøylinje", IDC_PAGEFMT_TB, 160, 20, 80, 15 CHECKBOX "&Formatlinje", IDC_PAGEFMT_FB, 160, 38, 80, 15 CHECKBOX "&Linjal", IDC_PAGEFMT_RU, 160, 56, 80, 15 CHECKBOX "&Statuslinje", IDC_PAGEFMT_SB, 160, 74, 80, 15 @@ -197,7 +193,7 @@ END STRINGTABLE DISCARDABLE BEGIN STRING_ALIGN_LEFT, "Venstrestilt" - STRING_ALIGN_RIGHT, "Høyrestilt" + STRING_ALIGN_RIGHT, "Høyrestilt" STRING_ALIGN_CENTER, "Midtstilt" END @@ -219,7 +215,7 @@ BEGIN STRING_PREVIEW_NEXTPAGE, "Neste side" STRING_PREVIEW_PREVPAGE, "Forrige side" STRING_PREVIEW_TWOPAGES, "To sider" - STRING_PREVIEW_ONEPAGE, "Én side" + STRING_PREVIEW_ONEPAGE, "Én side" STRING_PREVIEW_CLOSE, "Lukk" END @@ -231,18 +227,16 @@ END STRINGTABLE DISCARDABLE BEGIN STRING_DEFAULT_FILENAME, "Dokument" - STRING_PROMPT_SAVE_CHANGES, "Lagre endringer i «%s»?" - STRING_SEARCH_FINISHED, "Ferdig med å søke i dokumentet." + STRING_PROMPT_SAVE_CHANGES, "Lagre endringer i «%s»?" + STRING_SEARCH_FINISHED, "Ferdig med å søke i dokumentet." STRING_LOAD_RICHED_FAILED, "Klarte ikke laste RichEdit-biblioteket." - STRING_SAVE_LOSEFORMATTING, "Du har valgt å lagre i rent tekstformat, noe som " \ - "vil føre til at all formatering går tapt. Er du " \ - "sikker på at du vil fortsette?" + STRING_SAVE_LOSEFORMATTING, "Du har valgt å lagre i rent tekstformat, noe som " \ + "vil føre til at all formatering går tapt. Er du " \ + "sikker på at du vil fortsette?" STRING_INVALID_NUMBER, "Ugyldig tallformat" STRING_OLE_STORAGE_NOT_SUPPORTED, "OLE storage documents are not supported" STRING_WRITE_FAILED, "Klarte ikke lagre filen." - STRING_WRITE_ACCESS_DENIED, "Du har ikke tilgang til å lagre filen." - STRING_OPEN_FAILED, "Klarte ikke åpne filen." - STRING_OPEN_ACCESS_DENIED, "Du har ikke tilgang til å åpne filen." - STRING_PRINTING_NOT_IMPLEMENTED, "Utskriftfunksjonen er ikke laget ennå." - STRING_MAX_TAB_STOPS, "Kan ikke legge til mer enn 32 tabulatorstopp." + STRING_WRITE_ACCESS_DENIED, "Du har ikke tilgang til å lagre filen." + STRING_OPEN_FAILED, "Klarte ikke åpne filen." + STRING_OPEN_ACCESS_DENIED, "Du har ikke tilgang til å åpne filen." END diff --git a/programs/wordpad/Pl.rc b/programs/wordpad/Pl.rc index ab72104e5d0..47ff1bd0e3f 100644 --- a/programs/wordpad/Pl.rc +++ b/programs/wordpad/Pl.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT IDM_MAINMENU MENU DISCARDABLE diff --git a/programs/wordpad/Pt.rc b/programs/wordpad/Pt.rc index fd512c9f1aa..b246c700bcd 100644 --- a/programs/wordpad/Pt.rc +++ b/programs/wordpad/Pt.rc @@ -18,11 +18,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - -#pragma code_page(65001) - -LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE +LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL IDM_MAINMENU MENU DISCARDABLE BEGIN @@ -34,8 +30,8 @@ BEGIN MENUITEM "Guardar &como...", ID_FILE_SAVEAS MENUITEM SEPARATOR MENUITEM "&Imprimir...\tCtrl+P", ID_PRINT - MENUITEM "&Pré visualizar...", ID_PREVIEW - MENUITEM "C&onfigurar página...", ID_PRINTSETUP + MENUITEM "&Pré visualizar...", ID_PREVIEW + MENUITEM "C&onfigurar página...", ID_PRINTSETUP MENUITEM SEPARATOR MENUITEM "&Sair", ID_FILE_EXIT END @@ -59,21 +55,21 @@ BEGIN MENUITEM SEPARATOR POPUP "E&xtras" BEGIN - MENUITEM "&Informação da selecção", ID_EDIT_SELECTIONINFO + MENUITEM "&Informação da selecção", ID_EDIT_SELECTIONINFO MENUITEM "&Formato dos caracteres", ID_EDIT_CHARFORMAT MENUITEM "&Definir formato dos caracteres", ID_EDIT_DEFCHARFORMAT - MENUITEM "F&ormato dos parágrafos", ID_EDIT_PARAFORMAT + MENUITEM "F&ormato dos parágrafos", ID_EDIT_PARAFORMAT MENUITEM "&Buscar texto", ID_EDIT_GETTEXT END END POPUP "&Ver" BEGIN MENUITEM "&Barra de Ferramentas", ID_TOGGLE_TOOLBAR - MENUITEM "Barra de &Formatação", ID_TOGGLE_FORMATBAR - MENUITEM "&Régua", ID_TOGGLE_RULER + MENUITEM "Barra de &Formatação", ID_TOGGLE_FORMATBAR + MENUITEM "&Régua", ID_TOGGLE_RULER MENUITEM "Barra de &Estado", ID_TOGGLE_STATUSBAR MENUITEM SEPARATOR - MENUITEM "&Opções...", ID_VIEWPROPERTIES + MENUITEM "&Opções...", ID_VIEWPROPERTIES END POPUP "&Inserir" BEGIN @@ -83,8 +79,8 @@ BEGIN BEGIN MENUITEM "&Tipo de Letra...", ID_FONTSETTINGS MENUITEM "&Lista de marcas" ID_BULLET - MENUITEM "&Parágrafo..." ID_PARAFORMAT - MENUITEM "T&abulações..." ID_TABSTOPS + MENUITEM "&Parágrafo..." ID_PARAFORMAT + MENUITEM "T&abulações..." ID_TABSTOPS POPUP "&Fundo" BEGIN MENUITEM "&Sistema\tCtrl+1", ID_BACK_1 @@ -106,7 +102,7 @@ BEGIN MENUITEM "Co&lar", ID_EDIT_PASTE MENUITEM SEPARATOR MENUITEM "&Lista de marcas" ID_BULLET - MENUITEM "&Parágrafo..." ID_PARAFORMAT + MENUITEM "&Parágrafo..." ID_PARAFORMAT END END @@ -115,7 +111,7 @@ STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU CAPTION "Data e hora" FONT 10, "MS Sans Serif" BEGIN - LTEXT "Formatos Disponíveis",-1,3,2,100,15 + LTEXT "Formatos Disponíveis",-1,3,2,100,15 LISTBOX IDC_DATETIME,3,12,80,65,LBS_NOINTEGRALHEIGHT | LBS_NOTIFY PUSHBUTTON "&OK",IDOK,87,12,40,12 PUSHBUTTON "&Cancelar",IDCANCEL,87,26,40,12 @@ -134,10 +130,10 @@ END IDD_PARAFORMAT DIALOG DISCARDABLE 30, 20, 200, 110 STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -Caption "Parágrafo" +Caption "Parágrafo" FONT 8, "MS Shell Dlg" BEGIN - GROUPBOX "Identação", -1, 10, 10, 120, 68 + GROUPBOX "Identação", -1, 10, 10, 120, 68 LTEXT "Esquerda", -1, 15, 22, 40, 13 EDITTEXT IDC_PARA_LEFT, 55, 20, 60, 13 LTEXT "Direita", -1, 15, 40, 40, 13 @@ -152,10 +148,10 @@ END IDD_TABSTOPS DIALOG DISCARDABLE 30, 20, 200, 110 STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -Caption "Tabulações" +Caption "Tabulações" FONT 8, "MS SHell DLg" BEGIN - GROUPBOX "Marca de tabulação", -1, 10, 10, 120, 90 + GROUPBOX "Marca de tabulação", -1, 10, 10, 120, 90 COMBOBOX IDC_TABSTOPS, 20, 20, 100, 60, CBS_SIMPLE DEFPUSHBUTTON "&Adicionar", ID_TAB_ADD, 20, 80, 45, 15 PUSHBUTTON "&Remover", ID_TAB_DEL, 72, 80, 45, 15 @@ -171,12 +167,12 @@ FONT 8, "MS Shell Dlg" BEGIN GROUPBOX "Moldar o texto", -1, 10, 10, 130, 85 RADIOBUTTON "&Sem moldagem", IDC_PAGEFMT_WN, 18, 25, 117, 15 - RADIOBUTTON "&Moldar à janela", IDC_PAGEFMT_WW, 18, 45, 117, 15 - RADIOBUTTON "Moldar pela &régua", IDC_PAGEFMT_WM, 18, 65, 117, 15 + RADIOBUTTON "&Moldar à janela", IDC_PAGEFMT_WW, 18, 45, 117, 15 + RADIOBUTTON "Moldar pela &régua", IDC_PAGEFMT_WM, 18, 65, 117, 15 GROUPBOX "Barras de Ferramentas", -1, 150, 10, 120, 85 CHECKBOX "&Barra de Ferramentas", IDC_PAGEFMT_TB, 160, 20, 90, 15 - CHECKBOX "Barra de &Formatação", IDC_PAGEFMT_FB, 160, 38, 90, 15 - CHECKBOX "&Régua", IDC_PAGEFMT_RU, 160, 56, 90, 15 + CHECKBOX "Barra de &Formatação", IDC_PAGEFMT_FB, 160, 38, 90, 15 + CHECKBOX "&Régua", IDC_PAGEFMT_RU, 160, 56, 90, 15 CHECKBOX "Barra de &Estado", IDC_PAGEFMT_SB, 160, 74, 90, 15 LTEXT "", IDC_PAGEFMT_ID, 0,0,0,0 END @@ -210,7 +206,7 @@ END STRINGTABLE DISCARDABLE BEGIN - STRING_VIEWPROPS_TITLE, "Opções" + STRING_VIEWPROPS_TITLE, "Opções" STRING_VIEWPROPS_TEXT, "Texto" STRING_VIEWPROPS_RICHTEXT, "Rich text" END @@ -218,10 +214,10 @@ END STRINGTABLE DISCARDABLE BEGIN STRING_PREVIEW_PRINT, "Imprimir" - STRING_PREVIEW_NEXTPAGE, "Próxima página" - STRING_PREVIEW_PREVPAGE, "Página anterior" - STRING_PREVIEW_TWOPAGES, "Duas páginas" - STRING_PREVIEW_ONEPAGE, "Uma página" + STRING_PREVIEW_NEXTPAGE, "Próxima página" + STRING_PREVIEW_PREVPAGE, "Página anterior" + STRING_PREVIEW_TWOPAGES, "Duas páginas" + STRING_PREVIEW_ONEPAGE, "Uma página" STRING_PREVIEW_CLOSE, "Fechar" END @@ -233,18 +229,17 @@ END STRINGTABLE DISCARDABLE BEGIN STRING_DEFAULT_FILENAME, "Documento" - STRING_PROMPT_SAVE_CHANGES, "Guardar alterações a '%s'?" + STRING_PROMPT_SAVE_CHANGES, "Guardar alterações a '%s'?" STRING_SEARCH_FINISHED, "Acabou a pesquisa do documento." STRING_LOAD_RICHED_FAILED, "Falhou o carregamento da biblioteca RichEdit." STRING_SAVE_LOSEFORMATTING, "Escolheu guardar em formato de texto simples, " \ - "o que vai anular todas as formatações. " \ + "o que vai anular todas as formatações. " \ "Tem a certeza que quer fazer isto?" - STRING_INVALID_NUMBER, "Formato de número inválido" - STRING_OLE_STORAGE_NOT_SUPPORTED, "Documentos OLE não são suportados" - STRING_WRITE_FAILED, "Não foi possível guardar o ficheiro." - STRING_WRITE_ACCESS_DENIED, "Não tem permissões para guardar o ficheiro." - STRING_OPEN_FAILED, "Não foi possível abrir o ficheiro." - STRING_OPEN_ACCESS_DENIED, "Não tem permissões para abrir o ficheiro." - STRING_PRINTING_NOT_IMPLEMENTED, "Impressão não implementada" - STRING_MAX_TAB_STOPS, "Não pode adicionar mais de 32 tabs." + STRING_INVALID_NUMBER, "Formato de número inválido" + STRING_OLE_STORAGE_NOT_SUPPORTED, "Documentos OLE não são suportados" + STRING_WRITE_FAILED, "Não foi possível guardar o ficheiro." + STRING_WRITE_ACCESS_DENIED, "Não tem permissões para guardar o ficheiro." + STRING_OPEN_FAILED, "Não foi possível abrir o ficheiro." + STRING_OPEN_ACCESS_DENIED, "Não tem permissões para abrir o ficheiro." + STRING_PRINTING_NOT_IMPLEMENTED, "Impressão não implementada" END diff --git a/programs/wordpad/Ru.rc b/programs/wordpad/Ru.rc dissimilarity index 71% index c48b16f910d..e4371993991 100644 --- a/programs/wordpad/Ru.rc +++ b/programs/wordpad/Ru.rc @@ -1,244 +1,239 @@ -/* - * Copyright 2006 by Phil Krylov - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "wordpad.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT - -IDM_MAINMENU MENU DISCARDABLE -BEGIN - POPUP "&Файл" - BEGIN - MENUITEM "Созд&ать...\tCtrl+N",ID_FILE_NEW - MENUITEM "&Открыть...\tCtrl+O",ID_FILE_OPEN - MENUITEM "&Сохранить\tCtrl+S", ID_FILE_SAVE - MENUITEM "Сохранить &как...", ID_FILE_SAVEAS - MENUITEM SEPARATOR - MENUITEM "&Печать...\tCtrl+P", ID_PRINT - MENUITEM "Пред&варительный просмотр...", ID_PREVIEW - MENUITEM "&Макет страницы...", ID_PRINTSETUP - MENUITEM SEPARATOR - MENUITEM "В&ыход", ID_FILE_EXIT - END - POPUP "&Правка" - BEGIN - MENUITEM "&Отменить\tCtrl+Z", ID_EDIT_UNDO - MENUITEM "&Повторить\tCtrl+Y", ID_EDIT_REDO - MENUITEM SEPARATOR - MENUITEM "&Вырезать\tCtrl+X", ID_EDIT_CUT - MENUITEM "&Копировать\tCtrl+C", ID_EDIT_COPY - MENUITEM "&Вставить\tCtrl+V", ID_EDIT_PASTE - MENUITEM "&Удалить\tDEL", ID_EDIT_CLEAR - MENUITEM "Выделить в&се\tCtrl+A", ID_EDIT_SELECTALL - MENUITEM SEPARATOR - MENUITEM "&Найти...\tCrtl+F", ID_FIND - MENUITEM "На&йти далее\tF3", ID_FIND_NEXT - MENUITEM "&Заменить...\tCtrl+H", ID_REPLACE - MENUITEM SEPARATOR - MENUITEM "&Только для чтения", ID_EDIT_READONLY - MENUITEM "&Изменен", ID_EDIT_MODIFIED - MENUITEM SEPARATOR - POPUP "&Дополнительно" - BEGIN - MENUITEM "&Информация о выделении", ID_EDIT_SELECTIONINFO - MENUITEM "&Формат символов", ID_EDIT_CHARFORMAT - MENUITEM "Формат символов &по умолчанию", ID_EDIT_DEFCHARFORMAT - MENUITEM "Формат &абзаца", ID_EDIT_PARAFORMAT - MENUITEM "П&олучить текст", ID_EDIT_GETTEXT - END - END - POPUP "&Вид" - BEGIN - MENUITEM "Панель &инструментов", ID_TOGGLE_TOOLBAR - MENUITEM "П&анель форматирования", ID_TOGGLE_FORMATBAR - MENUITEM "&Линейка", ID_TOGGLE_RULER - MENUITEM "&Строка состояния", ID_TOGGLE_STATUSBAR - MENUITEM SEPARATOR - MENUITEM "&Параметры...", ID_VIEWPROPERTIES - END - POPUP "Вст&авка" - BEGIN - MENUITEM "&Дата и время...", ID_DATETIME - END - POPUP "Фор&мат" - BEGIN - MENUITEM "&Шрифт...", ID_FONTSETTINGS - MENUITEM "&Маркер" ID_BULLET - MENUITEM "&Абзац..." ID_PARAFORMAT - MENUITEM "&Табуляция..." ID_TABSTOPS - POPUP "&Фон" - BEGIN - MENUITEM "&Системный\tCtrl+1", ID_BACK_1 - MENUITEM "&Желтоватый PostThat\tCtrl+2", ID_BACK_2 - END - END - POPUP "&Справка" - BEGIN - MENUITEM "&О Wine Wordpad" ID_ABOUT - END -END - -IDM_POPUP MENU DISCARDABLE -BEGIN - POPUP "" - BEGIN - MENUITEM "&Вырезать\tCtrl+X", ID_EDIT_CUT - MENUITEM "&Копировать\tCtrl+C", ID_EDIT_COPY - MENUITEM "Вст&авить", ID_EDIT_PASTE - MENUITEM SEPARATOR - MENUITEM "&Маркер" ID_BULLET - MENUITEM "&Абзац..." ID_PARAFORMAT - END -END - -IDD_DATETIME DIALOG DISCARDABLE 30, 20, 130, 80 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Дата и время" -FONT 10, "MS Sans Serif" -BEGIN - LTEXT "Доступные форматы",-1,3,2,100,15 - LISTBOX IDC_DATETIME,3,12,80,65,LBS_NOINTEGRALHEIGHT | LBS_NOTIFY - PUSHBUTTON "&ОК",IDOK,87,12,40,12 - PUSHBUTTON "О&тмена",IDCANCEL,87,26,40,12 -END - -IDD_NEWFILE DIALOG DISCARDABLE 30, 20, 140, 80 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -CAPTION "Новый документ" -FONT 10, "MS Sans Serif" -BEGIN - LTEXT "Тип создаваемого документа",-1,3,2,100,15 - LISTBOX IDC_NEWFILE,3,12,90,65,LBS_NOINTEGRALHEIGHT - PUSHBUTTON "&ОК",IDOK,97,12,40,12 - PUSHBUTTON "О&тмена",IDCANCEL,97,26,40,12 -END - -IDD_PARAFORMAT DIALOG DISCARDABLE 30, 20, 200, 110 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -Caption "Абзац" -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "Отступ", -1, 10, 10, 120, 68 - LTEXT "Слева", -1, 15, 22, 40, 13 - EDITTEXT IDC_PARA_LEFT, 55, 20, 60, 13 - LTEXT "Справа", -1, 15, 40, 40, 13 - EDITTEXT IDC_PARA_RIGHT, 55, 38, 60, 13 - LTEXT "Первая строка", -1, 15, 58, 40, 13 - EDITTEXT IDC_PARA_FIRST, 55, 56, 60, 13 - LTEXT "Выравнивание", -1, 15, 87, 40, 13 - COMBOBOX IDC_PARA_ALIGN, 55, 85, 60, 60, CBS_DROPDOWNLIST - PUSHBUTTON "&ОК", IDOK, 137, 15, 50, 15 - PUSHBUTTON "О&тмена", IDCANCEL, 137, 33, 50, 15 -END - -IDD_TABSTOPS DIALOG DISCARDABLE 30, 20, 200, 110 -STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU -Caption "Табуляция" -FONT 8, "MS SHell DLg" -BEGIN - GROUPBOX "Позиции табуляции", -1, 10, 10, 120, 90 - COMBOBOX IDC_TABSTOPS, 20, 20, 100, 60, CBS_SIMPLE - DEFPUSHBUTTON "&Установить", ID_TAB_ADD, 20, 80, 45, 15 - PUSHBUTTON "О&чистить", ID_TAB_DEL, 72, 80, 45, 15 - PUSHBUTTON "&ОК", IDOK, 137, 15, 50, 15 - PUSHBUTTON "О&тмена", IDCANCEL, 137, 33, 50, 15 - PUSHBUTTON "Очистить &все", ID_TAB_EMPTY, 137, 51, 50, 15 -END - -IDD_FORMATOPTS DIALOG DISCARDABLE 0, 0, 280, 110 -STYLE DS_SYSMODAL -Caption "" -FONT 8, "MS Shell Dlg" -BEGIN - GROUPBOX "Перенос по словам", -1, 10, 10, 130, 85 - RADIOBUTTON "No line wrapping", IDC_PAGEFMT_WN, 18, 25, 117, 15 - RADIOBUTTON "В границах &окна", IDC_PAGEFMT_WW, 18, 45, 117, 15 - RADIOBUTTON "В границах &полей", IDC_PAGEFMT_WM, 18, 65, 117, 15 - GROUPBOX "Панели", -1, 150, 10, 120, 85 - CHECKBOX "&Инструментов", IDC_PAGEFMT_TB, 160, 20, 80, 15 - CHECKBOX "&Форматирования", IDC_PAGEFMT_FB, 160, 38, 80, 15 - CHECKBOX "&Линейка", IDC_PAGEFMT_RU, 160, 56, 80, 15 - CHECKBOX "&Строка состояния", IDC_PAGEFMT_SB, 160, 74, 80, 15 - LTEXT "", IDC_PAGEFMT_ID, 0,0,0,0 -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_RICHTEXT_FILES_RTF, "Файлы RTF (*.rtf)" - STRING_TEXT_FILES_TXT, "Текстовые документы (*.txt)" - STRING_TEXT_FILES_UNICODE_TXT, "Документы Unicode (*.txt)" - STRING_ALL_FILES, "Все документы (*.*)" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_ALIGN_LEFT, "По левому краю" - STRING_ALIGN_RIGHT, "По правому краю" - STRING_ALIGN_CENTER, "По центру" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_NEWFILE_RICHTEXT, "Файл RTF" - STRING_NEWFILE_TXT, "Текстовый документ" - STRING_NEWFILE_TXT_UNICODE, "Документ в формате Unicode" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_PRINTER_FILES_PRN, "Файлы принтера (*.PRN)" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_VIEWPROPS_TITLE, "Настройки" - STRING_VIEWPROPS_TEXT, "Текст" - STRING_VIEWPROPS_RICHTEXT, "Файл RTF" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_PREVIEW_PRINT, "Печать" - STRING_PREVIEW_NEXTPAGE, "Следующая страница" - STRING_PREVIEW_PREVPAGE, "Предыдущая страница" - STRING_PREVIEW_TWOPAGES, "Two pages" - STRING_PREVIEW_ONEPAGE, "One page" - STRING_PREVIEW_CLOSE, "Закрыть" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_UNITS_CM, "см" -END - -STRINGTABLE DISCARDABLE -BEGIN - STRING_DEFAULT_FILENAME, "Document" - STRING_PROMPT_SAVE_CHANGES, "Сохранить изменения в '%s'?" - STRING_SEARCH_FINISHED, "Поиск в документе завершен." - STRING_LOAD_RICHED_FAILED, "Ошибка загрузки библиотеки RichEdit." - STRING_SAVE_LOSEFORMATTING, "Сохранение документа в виде неформатированного текста, " \ - "приведет к потере форматирования. Подтверждаете выполнение" \ - "этой операции?" - STRING_INVALID_NUMBER, "Неправильный числовой формат" - STRING_OLE_STORAGE_NOT_SUPPORTED, "OLE storage документы не поддерживаются" - STRING_PRINTING_NOT_IMPLEMENTED, "Печать не поддерживается" -END +/* + * Copyright 2006 by Phil Krylov + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT + +IDM_MAINMENU MENU DISCARDABLE +BEGIN + POPUP "&Ôàéë" + BEGIN + MENUITEM "Ñîçä&àòü...\tCtrl+N",ID_FILE_NEW + MENUITEM "&Îòêðûòü...\tCtrl+O",ID_FILE_OPEN + MENUITEM "&Ñîõðàíèòü\tCtrl+S", ID_FILE_SAVE + MENUITEM "Ñîõðàíèòü &êàê...", ID_FILE_SAVEAS + MENUITEM SEPARATOR + MENUITEM "&Ïå÷àòü...\tCtrl+P", ID_PRINT + MENUITEM "Ïðåä&âàðèòåëüíûé ïðîñìîòð...", ID_PREVIEW + MENUITEM "&Ìàêåò ñòðàíèöû...", ID_PRINTSETUP + MENUITEM SEPARATOR + MENUITEM "Â&ûõîä", ID_FILE_EXIT + END + POPUP "&Ïðàâêà" + BEGIN + MENUITEM "&Îòìåíèòü\tCtrl+Z", ID_EDIT_UNDO + MENUITEM "&Ïîâòîðèòü\tCtrl+Y", ID_EDIT_REDO + MENUITEM SEPARATOR + MENUITEM "&Âûðåçàòü\tCtrl+X", ID_EDIT_CUT + MENUITEM "&Êîïèðîâàòü\tCtrl+C", ID_EDIT_COPY + MENUITEM "&Âñòàâèòü\tCtrl+V", ID_EDIT_PASTE + MENUITEM "&Óäàëèòü\tDEL", ID_EDIT_CLEAR + MENUITEM "Âûäåëèòü â&ñå\tCtrl+A", ID_EDIT_SELECTALL + MENUITEM SEPARATOR + MENUITEM "&Íàéòè...\tCrtl+F", ID_FIND + MENUITEM "Íà&éòè äàëåå\tF3", ID_FIND_NEXT + MENUITEM "&Çàìåíèòü...\tCtrl+H", ID_REPLACE + MENUITEM SEPARATOR + MENUITEM "&Òîëüêî äëÿ ÷òåíèÿ", ID_EDIT_READONLY + MENUITEM "&Èçìåíåí", ID_EDIT_MODIFIED + MENUITEM SEPARATOR + POPUP "&Äîïîëíèòåëüíî" + BEGIN + MENUITEM "&Èíôîðìàöèÿ î âûäåëåíèè", ID_EDIT_SELECTIONINFO + MENUITEM "&Ôîðìàò ñèìâîëîâ", ID_EDIT_CHARFORMAT + MENUITEM "Ôîðìàò ñèìâîëîâ &ïî óìîë÷àíèþ", ID_EDIT_DEFCHARFORMAT + MENUITEM "Ôîðìàò &àáçàöà", ID_EDIT_PARAFORMAT + MENUITEM "Ï&îëó÷èòü òåêñò", ID_EDIT_GETTEXT + END + END + POPUP "&Âèä" + BEGIN + MENUITEM "Ïàíåëü &èíñòðóìåíòîâ", ID_TOGGLE_TOOLBAR + MENUITEM "Ï&àíåëü ôîðìàòèðîâàíèÿ", ID_TOGGLE_FORMATBAR + MENUITEM "&Ëèíåéêà", ID_TOGGLE_RULER + MENUITEM "&Ñòðîêà ñîñòîÿíèÿ", ID_TOGGLE_STATUSBAR + MENUITEM SEPARATOR + MENUITEM "&Ïàðàìåòðû...", ID_VIEWPROPERTIES + END + POPUP "Âñò&àâêà" + BEGIN + MENUITEM "&Äàòà è âðåìÿ...", ID_DATETIME + END + POPUP "Ôîð&ìàò" + BEGIN + MENUITEM "&Øðèôò...", ID_FONTSETTINGS + MENUITEM "&Ìàðêåð" ID_BULLET + MENUITEM "&Àáçàö..." ID_PARAFORMAT + MENUITEM "&Òàáóëÿöèÿ..." ID_TABSTOPS + POPUP "&Ôîí" + BEGIN + MENUITEM "&Ñèñòåìíûé\tCtrl+1", ID_BACK_1 + MENUITEM "&Æåëòîâàòûé PostThat\tCtrl+2", ID_BACK_2 + END + END + POPUP "&Ñïðàâêà" + BEGIN + MENUITEM "&Î Wine Wordpad" ID_ABOUT + END +END + +IDM_POPUP MENU DISCARDABLE +BEGIN + POPUP "" + BEGIN + MENUITEM "&Âûðåçàòü\tCtrl+X", ID_EDIT_CUT + MENUITEM "&Êîïèðîâàòü\tCtrl+C", ID_EDIT_COPY + MENUITEM "Âñò&àâèòü", ID_EDIT_PASTE + MENUITEM SEPARATOR + MENUITEM "&Ìàðêåð" ID_BULLET + MENUITEM "&Àáçàö..." ID_PARAFORMAT + END +END + +IDD_DATETIME DIALOG DISCARDABLE 30, 20, 130, 80 +STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +CAPTION "Äàòà è âðåìÿ" +FONT 10, "MS Sans Serif" +BEGIN + LTEXT "Äîñòóïíûå ôîðìàòû",-1,3,2,100,15 + LISTBOX IDC_DATETIME,3,12,80,65,LBS_NOINTEGRALHEIGHT | LBS_NOTIFY + PUSHBUTTON "&ÎÊ",IDOK,87,12,40,12 + PUSHBUTTON "Î&òìåíà",IDCANCEL,87,26,40,12 +END + +IDD_NEWFILE DIALOG DISCARDABLE 30, 20, 140, 80 +STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +CAPTION "Íîâûé äîêóìåíò" +FONT 10, "MS Sans Serif" +BEGIN + LTEXT "Òèï ñîçäàâàåìîãî äîêóìåíòà",-1,3,2,100,15 + LISTBOX IDC_NEWFILE,3,12,90,65,LBS_NOINTEGRALHEIGHT + PUSHBUTTON "&ÎÊ",IDOK,97,12,40,12 + PUSHBUTTON "Î&òìåíà",IDCANCEL,97,26,40,12 +END + +IDD_PARAFORMAT DIALOG DISCARDABLE 30, 20, 200, 110 +STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +Caption "Àáçàö" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Îòñòóï", -1, 10, 10, 120, 68 + LTEXT "Ñëåâà", -1, 15, 22, 40, 13 + EDITTEXT IDC_PARA_LEFT, 55, 20, 60, 13 + LTEXT "Ñïðàâà", -1, 15, 40, 40, 13 + EDITTEXT IDC_PARA_RIGHT, 55, 38, 60, 13 + LTEXT "Ïåðâàÿ ñòðîêà", -1, 15, 58, 40, 13 + EDITTEXT IDC_PARA_FIRST, 55, 56, 60, 13 + LTEXT "Âûðàâíèâàíèå", -1, 15, 87, 40, 13 + COMBOBOX IDC_PARA_ALIGN, 55, 85, 60, 60, CBS_DROPDOWNLIST + PUSHBUTTON "&ÎÊ", IDOK, 137, 15, 50, 15 + PUSHBUTTON "Î&òìåíà", IDCANCEL, 137, 33, 50, 15 +END + +IDD_TABSTOPS DIALOG DISCARDABLE 30, 20, 200, 110 +STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU +Caption "Òàáóëÿöèÿ" +FONT 8, "MS SHell DLg" +BEGIN + GROUPBOX "Ïîçèöèè òàáóëÿöèè", -1, 10, 10, 120, 90 + COMBOBOX IDC_TABSTOPS, 20, 20, 100, 60, CBS_SIMPLE + DEFPUSHBUTTON "&Óñòàíîâèòü", ID_TAB_ADD, 20, 80, 45, 15 + PUSHBUTTON "Î&÷èñòèòü", ID_TAB_DEL, 72, 80, 45, 15 + PUSHBUTTON "&ÎÊ", IDOK, 137, 15, 50, 15 + PUSHBUTTON "Î&òìåíà", IDCANCEL, 137, 33, 50, 15 + PUSHBUTTON "Î÷èñòèòü &âñå", ID_TAB_EMPTY, 137, 51, 50, 15 +END + +IDD_FORMATOPTS DIALOG DISCARDABLE 0, 0, 280, 110 +STYLE DS_SYSMODAL +Caption "" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Ïåðåíîñ ïî ñëîâàì", -1, 10, 10, 130, 85 + RADIOBUTTON "No line wrapping", IDC_PAGEFMT_WN, 18, 25, 117, 15 + RADIOBUTTON " ãðàíèöàõ &îêíà", IDC_PAGEFMT_WW, 18, 45, 117, 15 + RADIOBUTTON " ãðàíèöàõ &ïîëåé", IDC_PAGEFMT_WM, 18, 65, 117, 15 + GROUPBOX "Ïàíåëè", -1, 150, 10, 120, 85 + CHECKBOX "&Èíñòðóìåíòîâ", IDC_PAGEFMT_TB, 160, 20, 80, 15 + CHECKBOX "&Ôîðìàòèðîâàíèÿ", IDC_PAGEFMT_FB, 160, 38, 80, 15 + CHECKBOX "&Ëèíåéêà", IDC_PAGEFMT_RU, 160, 56, 80, 15 + CHECKBOX "&Ñòðîêà ñîñòîÿíèÿ", IDC_PAGEFMT_SB, 160, 74, 80, 15 + LTEXT "", IDC_PAGEFMT_ID, 0,0,0,0 +END + +STRINGTABLE DISCARDABLE +BEGIN + STRING_RICHTEXT_FILES_RTF, "Ôàéëû RTF (*.rtf)" + STRING_TEXT_FILES_TXT, "Òåêñòîâûå äîêóìåíòû (*.txt)" + STRING_TEXT_FILES_UNICODE_TXT, "Äîêóìåíòû Unicode (*.txt)" + STRING_ALL_FILES, "Âñå äîêóìåíòû (*.*)" +END + +STRINGTABLE DISCARDABLE +BEGIN + STRING_ALIGN_LEFT, "Ïî ëåâîìó êðàþ" + STRING_ALIGN_RIGHT, "Ïî ïðàâîìó êðàþ" + STRING_ALIGN_CENTER, "Ïî öåíòðó" +END + +STRINGTABLE DISCARDABLE +BEGIN + STRING_NEWFILE_RICHTEXT, "Ôàéë RTF" + STRING_NEWFILE_TXT, "Òåêñòîâûé äîêóìåíò" + STRING_NEWFILE_TXT_UNICODE, "Äîêóìåíò â ôîðìàòå Unicode" +END + +STRINGTABLE DISCARDABLE +BEGIN + STRING_PRINTER_FILES_PRN, "Ôàéëû ïðèíòåðà (*.PRN)" +END + +STRINGTABLE DISCARDABLE +BEGIN + STRING_VIEWPROPS_TITLE, "Íàñòðîéêè" + STRING_VIEWPROPS_TEXT, "Òåêñò" + STRING_VIEWPROPS_RICHTEXT, "Ôàéë RTF" +END + +STRINGTABLE DISCARDABLE +BEGIN + STRING_PREVIEW_PRINT, "Ïå÷àòü" + STRING_PREVIEW_NEXTPAGE, "Ñëåäóþùàÿ ñòðàíèöà" + STRING_PREVIEW_PREVPAGE, "Ïðåäûäóùàÿ ñòðàíèöà" + STRING_PREVIEW_TWOPAGES, "Two pages" + STRING_PREVIEW_ONEPAGE, "One page" + STRING_PREVIEW_CLOSE, "Çàêðûòü" +END + +STRINGTABLE DISCARDABLE +BEGIN + STRING_UNITS_CM, "ñì" +END + +STRINGTABLE DISCARDABLE +BEGIN + STRING_DEFAULT_FILENAME, "Document" + STRING_PROMPT_SAVE_CHANGES, "Ñîõðàíèòü èçìåíåíèÿ â '%s'?" + STRING_SEARCH_FINISHED, "Ïîèñê â äîêóìåíòå çàâåðøåí." + STRING_LOAD_RICHED_FAILED, "Îøèáêà çàãðóçêè áèáëèîòåêè RichEdit." + STRING_SAVE_LOSEFORMATTING, "Ñîõðàíåíèå äîêóìåíòà â âèäå íåôîðìàòèðîâàííîãî òåêñòà, " \ + "ïðèâåäåò ê ïîòåðå ôîðìàòèðîâàíèÿ. Ïîäòâåðæäàåòå âûïîëíåíèå" \ + "ýòîé îïåðàöèè?" + STRING_INVALID_NUMBER, "Íåïðàâèëüíûé ÷èñëîâîé ôîðìàò" + STRING_OLE_STORAGE_NOT_SUPPORTED, "OLE storage äîêóìåíòû íå ïîääåðæèâàþòñÿ" + STRING_PRINTING_NOT_IMPLEMENTED, "Ïå÷àòü íå ïîääåðæèâàåòñÿ" +END diff --git a/programs/wordpad/Si.rc b/programs/wordpad/Si.rc index 1b6d37fd41c..3be81b82c45 100644 --- a/programs/wordpad/Si.rc +++ b/programs/wordpad/Si.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -244,6 +242,7 @@ BEGIN STRING_WRITE_ACCESS_DENIED, "Nimate pravic za shranjevanje te datoteke." STRING_OPEN_FAILED, "Napaka pri odpiranju datoteke." STRING_OPEN_ACCESS_DENIED, "Nimate pravic za odpiranje te datoteke." - STRING_PRINTING_NOT_IMPLEMENTED, "Tiskanje (še) ni na voljo" - STRING_MAX_TAB_STOPS, "Ne morem vstaviti več kot 32 položajev tabulatorja." + STRING_PRINTING_NOT_IMPLEMENTED, "Tiskanje (še) ni na voljo" END + +#pragma code_page(default) diff --git a/programs/wordpad/Sv.rc b/programs/wordpad/Sv.rc index d94e6e3d190..4bb2ae24557 100644 --- a/programs/wordpad/Sv.rc +++ b/programs/wordpad/Sv.rc @@ -16,8 +16,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -246,3 +244,5 @@ BEGIN STRING_PRINTING_NOT_IMPLEMENTED, "Utskrift ej implementerat." STRING_MAX_TAB_STOPS, "Kan ej lägga till mer än 32 tabbstopp." END + +#pragma code_page(default) diff --git a/programs/wordpad/Tr.rc b/programs/wordpad/Tr.rc index 92290371d37..7df9a36fb7a 100644 --- a/programs/wordpad/Tr.rc +++ b/programs/wordpad/Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT IDM_MAINMENU MENU DISCARDABLE diff --git a/programs/wordpad/Zh.rc b/programs/wordpad/Zh.rc index d8ceec43a1a..5c11ab79963 100644 --- a/programs/wordpad/Zh.rc +++ b/programs/wordpad/Zh.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "wordpad.h" - /* Chinese text is encoded in UTF-8 */ #pragma code_page(65001) @@ -471,3 +469,5 @@ BEGIN STRING_OPEN_FAILED, "不能開啟檔案." STRING_OPEN_ACCESS_DENIED, "你沒有開啟檔案的權力." END + +#pragma code_page(default) diff --git a/programs/wordpad/rsrc.rc b/programs/wordpad/rsrc.rc index ac159da8916..1a77fe27be1 100644 --- a/programs/wordpad/rsrc.rc +++ b/programs/wordpad/rsrc.rc @@ -17,6 +17,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include +#include + #include "wordpad.h" MAINACCELTABLE ACCELERATORS @@ -60,3 +63,20 @@ IDI_WRI ICON "wri.ico" /* @makedep: txt.ico */ IDI_TXT ICON "txt.ico" + +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Fr.rc" +#include "Hu.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" +#include "Tr.rc" +#include "Zh.rc" diff --git a/programs/wordpad/wordpad.h b/programs/wordpad/wordpad.h index b51bec8fcb0..ece183fc1c2 100644 --- a/programs/wordpad/wordpad.h +++ b/programs/wordpad/wordpad.h @@ -17,9 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include -#include - #define MAX_STRING_LEN 255 #define TWIPS_PER_INCH 1440 @@ -172,24 +169,24 @@ #define STRING_NEWFILE_TXT 1405 #define STRING_NEWFILE_TXT_UNICODE 1406 -#define STRING_PRINTER_FILES_PRN 1407 +#define STRING_ALIGN_LEFT 1407 +#define STRING_ALIGN_RIGHT 1408 +#define STRING_ALIGN_CENTER 1409 -#define STRING_ALIGN_LEFT 1416 -#define STRING_ALIGN_RIGHT 1417 -#define STRING_ALIGN_CENTER 1418 +#define STRING_PRINTER_FILES_PRN 1410 -#define STRING_VIEWPROPS_TITLE 1432 -#define STRING_VIEWPROPS_TEXT 1433 -#define STRING_VIEWPROPS_RICHTEXT 1434 +#define STRING_VIEWPROPS_TITLE 1411 +#define STRING_VIEWPROPS_TEXT 1412 +#define STRING_VIEWPROPS_RICHTEXT 1413 -#define STRING_PREVIEW_PRINT 1448 -#define STRING_PREVIEW_NEXTPAGE 1449 -#define STRING_PREVIEW_PREVPAGE 1450 -#define STRING_PREVIEW_TWOPAGES 1451 -#define STRING_PREVIEW_ONEPAGE 1452 -#define STRING_PREVIEW_CLOSE 1453 +#define STRING_PREVIEW_PRINT 1414 +#define STRING_PREVIEW_NEXTPAGE 1415 +#define STRING_PREVIEW_PREVPAGE 1416 +#define STRING_PREVIEW_TWOPAGES 1417 +#define STRING_PREVIEW_ONEPAGE 1418 +#define STRING_PREVIEW_CLOSE 1419 -#define STRING_UNITS_CM 1454 +#define STRING_UNITS_CM 1420 #define STRING_DEFAULT_FILENAME 1700 #define STRING_PROMPT_SAVE_CHANGES 1701 diff --git a/programs/write/De.rc b/programs/write/De.rc index db175a02d56..c2afa0848ae 100644 --- a/programs/write/De.rc +++ b/programs/write/De.rc @@ -17,10 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - -#pragma code_page(65001) - LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL STRINGTABLE diff --git a/programs/write/En.rc b/programs/write/En.rc index 715957846c1..5215db51dc8 100644 --- a/programs/write/En.rc +++ b/programs/write/En.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/write/Fr.rc b/programs/write/Fr.rc index a81dffda827..0258efc8142 100644 --- a/programs/write/Fr.rc +++ b/programs/write/Fr.rc @@ -17,9 +17,6 @@ * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ - -#include "resources.h" - #pragma code_page(65001) LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL @@ -28,3 +25,5 @@ STRINGTABLE { IDS_FAILED, "Wordpad n'a pas pu être démarré" } + +#pragma code_page(default) diff --git a/programs/write/Ja.rc b/programs/write/Ja.rc index 5c9a8259a97..237a53d5c48 100644 --- a/programs/write/Ja.rc +++ b/programs/write/Ja.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - /* UTF-8 */ #pragma code_page(65001) @@ -29,3 +27,5 @@ STRINGTABLE { IDS_FAILED, "Wordpad の起動に失敗しました" } + +#pragma code_page(default) diff --git a/programs/write/Ko.rc b/programs/write/Ko.rc index 3e076c2d101..f78ea13b286 100644 --- a/programs/write/Ko.rc +++ b/programs/write/Ko.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/write/Lt.rc b/programs/write/Lt.rc deleted file mode 100644 index 5cef934fbc7..00000000000 --- a/programs/write/Lt.rc +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Lithuanian language support - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "resources.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE -{ - IDS_FAILED, "Nepavyko paleisti Wordpad" -} diff --git a/programs/write/Makefile.in b/programs/write/Makefile.in index be459b6b8fb..eb9e0cafb35 100644 --- a/programs/write/Makefile.in +++ b/programs/write/Makefile.in @@ -9,21 +9,7 @@ IMPORTS = user32 gdi32 kernel32 C_SRCS = write.c -RC_SRCS = \ - De.rc \ - En.rc \ - Fr.rc \ - Ja.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ro.rc \ - Ru.rc \ - Si.rc \ - Sv.rc +RC_SRCS = rsrc.rc @MAKE_PROG_RULES@ diff --git a/programs/write/Nl.rc b/programs/write/Nl.rc index 6910cde8baa..5f1611ed851 100644 --- a/programs/write/Nl.rc +++ b/programs/write/Nl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL STRINGTABLE diff --git a/programs/write/No.rc b/programs/write/No.rc index b20abc3d56c..9b5a4bd8fc7 100644 --- a/programs/write/No.rc +++ b/programs/write/No.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL STRINGTABLE diff --git a/programs/write/Pl.rc b/programs/write/Pl.rc index 6a3c8ae3199..fc06b897f40 100644 --- a/programs/write/Pl.rc +++ b/programs/write/Pl.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_POLISH, SUBLANG_DEFAULT STRINGTABLE diff --git a/programs/write/Pt.rc b/programs/write/Pt.rc index 95fad3463f4..e2ba2eb978d 100644 --- a/programs/write/Pt.rc +++ b/programs/write/Pt.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL STRINGTABLE diff --git a/programs/write/Ro.rc b/programs/write/Ro.rc index f6a7b65665f..8a33118eb7f 100644 --- a/programs/write/Ro.rc +++ b/programs/write/Ro.rc @@ -17,8 +17,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) @@ -27,3 +25,5 @@ STRINGTABLE { IDS_FAILED, "Execuția Wordpad a eșuat" } + +#pragma code_page(default) diff --git a/programs/write/Ru.rc b/programs/write/Ru.rc index 008011f2720..653d426b2cc 100644 --- a/programs/write/Ru.rc +++ b/programs/write/Ru.rc @@ -18,14 +18,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - -/* UTF-8 */ -#pragma code_page(65001) - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE { - IDS_FAILED, "Не удалось запустить Wordpad" + IDS_FAILED, "Íå óäàëîñü çàïóñòèòü Wordpad" } diff --git a/programs/write/Si.rc b/programs/write/Si.rc index 9d3e5fe1520..d7e2226a0ca 100644 --- a/programs/write/Si.rc +++ b/programs/write/Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT #pragma code_page(65001) @@ -28,3 +26,5 @@ STRINGTABLE { IDS_FAILED, "Zagon programa Wordpad ni uspel" } + +#pragma code_page(default) diff --git a/programs/write/Sv.rc b/programs/write/Sv.rc index 7cfa2acea01..dea65213e0f 100644 --- a/programs/write/Sv.rc +++ b/programs/write/Sv.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "resources.h" - LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL STRINGTABLE diff --git a/programs/write/resources.h b/programs/write/resources.h index 73ef91aa40f..e99e5b19a40 100644 --- a/programs/write/resources.h +++ b/programs/write/resources.h @@ -16,6 +16,4 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include - #define IDS_FAILED 101 diff --git a/programs/write/rsrc.rc b/programs/write/rsrc.rc new file mode 100644 index 00000000000..6c22aa573cd --- /dev/null +++ b/programs/write/rsrc.rc @@ -0,0 +1,37 @@ +/* + * Copyright 2007 Mikolaj Zalewski + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include + +#include "resources.h" + +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + +#include "De.rc" +#include "En.rc" +#include "Fr.rc" +#include "Ja.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ro.rc" +#include "Ru.rc" +#include "Si.rc" +#include "Sv.rc" diff --git a/programs/xcopy/Da.rc b/programs/xcopy/Da.rc index 6a15a4440b2..239b3a71d63 100644 --- a/programs/xcopy/Da.rc +++ b/programs/xcopy/Da.rc @@ -19,7 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "xcopy.h" LANGUAGE LANG_DANISH, SUBLANG_DEFAULT diff --git a/programs/xcopy/De.rc b/programs/xcopy/De.rc index c13addfdaaa..1af64183b49 100644 --- a/programs/xcopy/De.rc +++ b/programs/xcopy/De.rc @@ -20,9 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "xcopy.h" - -#pragma code_page(65001) LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL @@ -30,16 +27,16 @@ STRINGTABLE { STRING_INVPARMS, "Falsche Parameteranzahl - xcopy /? zeigt Hilfe an\n" STRING_INVPARM, "Unbekannter Parameter '%s' - xcopy /? zeigt Hilfe an\n" - STRING_PAUSE, "Eingabetaste betätigen, um mit dem Kopieren zu beginnen\n" - STRING_SIMCOPY, "%d Datei(en) würden kopiert\n" + STRING_PAUSE, "Eingabetaste betätigen, um mit dem Kopieren zu beginnen\n" + STRING_SIMCOPY, "%d Datei(en) würden kopiert\n" STRING_COPY, "%d Datei(en) kopiert\n" STRING_QISDIR, "Ist '%s' eine Datei oder ein Verzeichnis\n" \ "am Zielsort?\n" \ "(D - Datei, V - Verzeichnis)\n" STRING_SRCPROMPT,"%s? (Ja|Nein)\n" - STRING_OVERWRITE,"%s überschreiben? (Ja|Nein|Alle)\n" + STRING_OVERWRITE,"%s überschreiben? (Ja|Nein|Alle)\n" STRING_COPYFAIL, "Kopieren von '%s' nach '%s' fehlgeschlagen. Fehlernummer: %d\n" - STRING_OPENFAIL, "Fehler beim Öffnen von '%s'\n" + STRING_OPENFAIL, "Fehler beim Öffnen von '%s'\n" STRING_READFAIL, "Fehler beim Lesen von '%s'\n" STRING_YES_CHAR, "J" STRING_NO_CHAR, "N" @@ -61,20 +58,20 @@ Mit:\n\ [/S] Kopiere Verzeichnisse und Unterverzeichnisse\n\ [/E] Kopiere Verzeichnisse und Unterverzeichnisse, auch leere\n\ [/Q] Zeige die Dateinamen beim Kopieren nicht an\n\ -[/F] Zeige vollständige Dateinamen von Quelle und Ziel an\n\ -[/L] Simulation: Zeige die Namen der Datein, die kopiert würden\n\ -[/W] Wartet vor Beginn des Kopierens auf Bestätigung\n\ +[/F] Zeige vollständige Dateinamen von Quelle und Ziel an\n\ +[/L] Simulation: Zeige die Namen der Datein, die kopiert würden\n\ +[/W] Wartet vor Beginn des Kopierens auf Bestätigung\n\ [/T] Erzeuge eine leere Verzeichnisstruktur, ohne Dateien zu kopieren\n\ -[/Y] Keine Nachfrage vor dem Überschreiben von Dateien\n\ -[/-Y] Nachrage vor dem Überschreiben von Dateien\n\ -[/P] Fragt für jede Quelldatei, ob sie kopiert werden soll\n\ +[/Y] Keine Nachfrage vor dem Überschreiben von Dateien\n\ +[/-Y] Nachrage vor dem Überschreiben von Dateien\n\ +[/P] Fragt für jede Quelldatei, ob sie kopiert werden soll\n\ [/N] Kopiert die Dateien unter ihrem Kurznamen\n\ [/U] Kopiert nur Dateien, die am Ziel bereits existieren\n\ -[/R] Überschreibt schreibgeschützte Dateien\n\ +[/R] Überschreibt schreibgeschützte Dateien\n\ [/H] Kopiere auch versteckte und Systemdateien\n\ [/C] Nach Fehlern den Kopiervorgang fortsetzen\n\ [/A] Nur Dateien mit Archivbit kopieren\n\ -[/M] Nur Dateien mit Archivbit kopieren, danach Archivbit löschen\n\ +[/M] Nur Dateien mit Archivbit kopieren, danach Archivbit löschen\n\ [/D | /D:m-d-y] Kopiere neue Dateien und Dateien, die neuer als das\n\ \t\tangegebene Datum sind. Wird kein Datum angegegebn, werden nur\n\ \t\tQuelldateien kopiert, die neuer sind als die Zieldatei\n\n" diff --git a/programs/xcopy/En.rc b/programs/xcopy/En.rc index 83ef291c9df..33324ac9f4e 100644 --- a/programs/xcopy/En.rc +++ b/programs/xcopy/En.rc @@ -19,7 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "xcopy.h" LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT diff --git a/programs/xcopy/Fr.rc b/programs/xcopy/Fr.rc index 047b4b3f739..7fe8f691cb4 100644 --- a/programs/xcopy/Fr.rc +++ b/programs/xcopy/Fr.rc @@ -18,9 +18,6 @@ * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ - -#include "xcopy.h" - #pragma code_page(65001) @@ -33,12 +30,12 @@ STRINGTABLE STRING_PAUSE, "Appuyez sur ENTRÉE pour démarrer la copie\n" STRING_SIMCOPY, "%d fichier(s) seront copiés\n" STRING_COPY, "%d fichier(s) copiés\n" - STRING_QISDIR, "« %s » est-il un fichier ou un répertoire\n" \ + STRING_QISDIR, "Est-ce que « %s » est un fichier ou un répertoire\n" \ "dans la destination ?\n" \ "(F - Fichier, R - Répertoire)\n" STRING_SRCPROMPT,"%s ? (Oui|Non)\n" STRING_OVERWRITE,"Écraser %s ? (Oui|Non|Tous)\n" - STRING_COPYFAIL, "La copie de « %s » vers « %s » a échoué avec le code de retour %d\n" + STRING_COPYFAIL, "La copie de « %s » vers « %s » a échoué avec le c/r %d\n" STRING_OPENFAIL, "Impossible d'ouvrir « %s »\n" STRING_READFAIL, "Impossible de lire « %s »\n" STRING_YES_CHAR, "O" @@ -48,36 +45,38 @@ STRINGTABLE STRING_DIR_CHAR, "R" STRING_HELP, -"XCOPY - Copie les fichiers ou répertoires sources vers une destination\n\ +"XCOPY - Copie les fichiers ou répertoires source vers une destination\n\ \n\ Syntaxe :\n\ -XCOPY source [destination] [/I] [/S] [/Q] [/F] [/L] [/W] [/T] [/N] [/U]\n\ +XCOPY source [dest] [/I] [/S] [/Q] [/F] [/L] [/W] [/T] [/N] [/U]\n\ \t [/R] [/H] [/C] [/P] [/A] [/M] [/E] [/D] [/Y] [/-Y]\n\ \n\ -où :\n\ +Où :\n\ \n\ [/I] Suppose que la destination est un répertoire si elle n'existe pas et que l'on copie plus\n\ \td'un fichier\n\ [/S] Copie les répertoires et sous-répertoires\n\ [/E] Copie les répertoires et sous-répertoires, y compris ceux qui sont vides\n\ [/Q] Ne pas afficher la liste des fichiers copiés (mode silencieux)\n\ -[/F] Afficher les source et destination complètes lors de la copie\n\ -[/L] Simuler la copie, en montrant le nom des fichiers qui seraient copiés\n\ +[/F] Afficher la source et la destination complète lors de la copie\n\ +[/L] Simuler l'opération, en montrant le nom des fichiers qui auraient été copiés\n\ [/W] Demande avant de démarrer la copie\n\ -[/T] Créer une structure de répertoires vides, mais ne pas copier les fichiers\n\ +[/T] Créer une structure de répertoires vides, mais ne copie pas les fichiers\n\ [/Y] Ne demande pas de confirmation lors de l'écrasement des fichiers\n\ [/-Y] Demande une confirmation lors de l'écrasement des fichiers\n\ -[/P] Interroge l'utilisateur avant de copier chaque fichier source\n\ -[/N] Copie en utilisant les noms courts\n\ +[/P] Demande avant de copier chaque fichier source\n\ +[/N] Copie en utilisant des noms courts\n\ [/U] Copie uniquement les fichiers qui existent déjà dans la destination\n\ [/R] Écrase même les fichiers en lecture seule\n\ [/H] Inclure les fichiers cachés et système dans la copie\n\ [/C] Continue même si une erreur survient pendant la copie\n\ [/A] Copie uniquement les fichiers qui ont l'attribut archive défini\n\ -[/M] Copie uniquement les fichiers qui ont l'attribut archive défini ; supprime\n\ +[/M] Copie uniquement les fichiers qui ont l'attribut archive défini, supprime\n\ \tensuite l'attribut\n\ -[/D | /D:m-d-y] Copie uniquement les nouveaux fichiers, ou ceux modifiés après la date spécifiée.\n\ -\t\tSi aucune date n'est spécifiée, copie uniquement lorsque le fichier de destination est plus ancien\n\ +[/D | /D:m-d-y] Copie uniquement les fichiers nouveaux ou ceux modifiés après la date spécifiée.\n\ +\t\tSi aucune date n'est spécifiée, copie uniquement lorsque le fichier de destination est plus vieux\n\ \t\tque le fichier source\n\n" } + +#pragma code_page(default) diff --git a/programs/xcopy/Ko.rc b/programs/xcopy/Ko.rc index 6a5071cae86..a3a89f99e24 100644 --- a/programs/xcopy/Ko.rc +++ b/programs/xcopy/Ko.rc @@ -20,7 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "xcopy.h" LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT diff --git a/programs/xcopy/Lt.rc b/programs/xcopy/Lt.rc deleted file mode 100644 index 9d431de08fa..00000000000 --- a/programs/xcopy/Lt.rc +++ /dev/null @@ -1,83 +0,0 @@ -/* - * XCOPY - Wine-compatible xcopy program - * Lithuanian language support - * - * Copyright 2009 Aurimas Fišeras - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "xcopy.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL - -STRINGTABLE -{ - STRING_INVPARMS, "Neteisingas parametrų skaičius - pagalba: xcopy /?\n" - STRING_INVPARM, "Neteisingas parametras „%s“ - pagalba: xcopy /?\n" - STRING_PAUSE, "Spauskite kopijavimui pradėti\n" - STRING_SIMCOPY, "bus nukopijuota failų: %d\n" - STRING_COPY, "nukopijuota failų: %d\n" - STRING_QISDIR, "Ar „%s“ yra failas, ar katalogas,\n" \ - "ar paskirtis?\n" \ - "(F - failas, K - katalogas)\n" - STRING_SRCPROMPT,"%s? (Taip|Ne)\n" - STRING_OVERWRITE,"Perrašyti %s? (Taip|Ne|Visus)\n" - STRING_COPYFAIL, "„%s“ kopijavimas į „%s“ nepavyko su r/c %d\n" - STRING_OPENFAIL, "Nepavyko atverti „%s“\n" - STRING_READFAIL, "Klaida skaitant „%s“\n" - STRING_YES_CHAR, "T" - STRING_NO_CHAR, "N" - STRING_ALL_CHAR, "V" - STRING_FILE_CHAR,"F" - STRING_DIR_CHAR, "K" - - STRING_HELP, -"XCOPY - Kopijuoja šaltinio failus ir katalogų medžius į paskirties vietą\n\ -\n\ -Sintaksė:\n\ -XCOPY šaltinis [paskirtis] [/I] [/S] [/Q] [/F] [/L] [/W] [/T] [/N] [/U]\n\ -\t [/R] [/H] [/C] [/P] [/A] [/M] [/E] [/D] [/Y] [/-Y]\n\ -\n\ -Kur:\n\ -\n\ -[/I] Tarti, kad katalogas, jei paskirtis neegzistuoja ir kopijuojami\n\ -\t2 ar daugiau failų\n\ -[/S] Kopijuoti katalogus ir pakatalogius\n\ -[/E] Kopijuoti katalogus ir pakatalogius, taip pat ir tuščius\n\ -[/Q] Kopijuojant nerodyti vardų, kopijuoti tyliai.\n\ -[/F] Kopijuojant rodyti pilnus šaltinio ir paskirties vardus\n\ -[/L] Modeliuoti veikimą rodant failus, kurie būtų kopijuojami\n\ -[/W] Raginti prieš pradedant kopijavimo operaciją\n\ -[/T] Sukuria tuščią katalogų struktūrą, bet nekopijuoja jokių failų\n\ -[/Y] Nerodyti raginimų, kai perrašomi failai\n\ -[/-Y] Įjungti raginimus, kai perrašomi failai\n\ -[/P] Ragina prieš kopijuojant kiekvieną šaltinio failą\n\ -[/N] Kopijuoti naudojant trumpus vardus\n\ -[/U] Kopijuoti tik tuos failus, kurie jau egzistuoja paskirties vietoje\n\ -[/R] Perrašyti visus nekeičiamus failus\n\ -[/H] Kopijuoti paslėptus ir sisteminius failus\n\ -[/C] Tęsti, net jei įvyksta klaida kopijuojant\n\ -[/A] Kopijuoti tik failus su nustatytu archyvavimo požymiu\n\ -[/M] Kopijuoti tik failus su nustatytu archyvavimo požymiu, pašalinti\n\ -\tarchyvavimo požymį\n\ -[/D | /D:m-d-y] Kopijuoti naujus failus arba modifikuotos po nurodytos datos.\n\ -\t\tJei data nenurodyta, kopijuoti tik jei paskirties failas yra\n\ -\t\tsenesnis už šaltinio failą\n\n" - -} diff --git a/programs/xcopy/Makefile.in b/programs/xcopy/Makefile.in index b46a97f9f0a..7e9b26e8dd8 100644 --- a/programs/xcopy/Makefile.in +++ b/programs/xcopy/Makefile.in @@ -12,19 +12,7 @@ MODCFLAGS = @BUILTINFLAG@ C_SRCS = \ xcopy.c -RC_SRCS = \ - Da.rc \ - De.rc \ - En.rc \ - Fr.rc \ - Ko.rc \ - Lt.rc \ - Nl.rc \ - No.rc \ - Pl.rc \ - Pt.rc \ - Ru.rc \ - Si.rc +RC_SRCS = rsrc.rc @MAKE_PROG_RULES@ diff --git a/programs/xcopy/Nl.rc b/programs/xcopy/Nl.rc index b9db305843f..f994cdd8f7e 100644 --- a/programs/xcopy/Nl.rc +++ b/programs/xcopy/Nl.rc @@ -19,7 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "xcopy.h" LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL diff --git a/programs/xcopy/No.rc b/programs/xcopy/No.rc index a3c223fc1e2..ddcccf78fef 100644 --- a/programs/xcopy/No.rc +++ b/programs/xcopy/No.rc @@ -19,7 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "xcopy.h" LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL diff --git a/programs/xcopy/Pl.rc b/programs/xcopy/Pl.rc index 8b224eccfd6..3d094a933ed 100644 --- a/programs/xcopy/Pl.rc +++ b/programs/xcopy/Pl.rc @@ -20,7 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "xcopy.h" LANGUAGE LANG_POLISH, SUBLANG_DEFAULT diff --git a/programs/xcopy/Pt.rc b/programs/xcopy/Pt.rc index d8254d5e1fb..47e9609bd7f 100644 --- a/programs/xcopy/Pt.rc +++ b/programs/xcopy/Pt.rc @@ -19,7 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "xcopy.h" LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL diff --git a/programs/xcopy/Ru.rc b/programs/xcopy/Ru.rc dissimilarity index 73% index 154c999d357..1d86ff46f8c 100644 --- a/programs/xcopy/Ru.rc +++ b/programs/xcopy/Ru.rc @@ -1,86 +1,82 @@ -/* - * XCOPY - Wine-compatible xcopy program - * Russian language support - * - * Copyright (C) 2007 J. Edmeades - * Copyright (C) 2007 Kirill K. Smirnov - * - * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "xcopy.h" - -/* UTF-8 */ -#pragma code_page(65001) - -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT - -STRINGTABLE -{ - STRING_INVPARMS, -"Недопустимое число параметров - попробуйте 'xcopy /?' для получения\n\ -подробного описания.\n" - STRING_INVPARM, -"Недопустимый параметр '%s' - попробуйте 'xcopy /?' для получения подробного\n\ -описания.\n" - STRING_PAUSE, "Нажмите клавишу , чтобы начать копирование.\n" - STRING_SIMCOPY, "%d файл(ов) было бы скопировано.\n" - STRING_COPY, "%d файл(ов) скопировано.\n" - STRING_QISDIR, "'%s' является файлом или папкой?\n" \ - "(F - Файл, D - Папка)\n" - STRING_SRCPROMPT,"%s? (Yes|No)\n" - STRING_OVERWRITE,"Переписать %s? (Yes|No|All)\n" - STRING_COPYFAIL, "При копировании '%s' в '%s' произошла ошибка: %d\n" - STRING_OPENFAIL, "Невозможно открыть '%s'\n" - STRING_READFAIL, "При чтении '%s' произошла ошибка\n" - STRING_YES_CHAR, "Y" - STRING_NO_CHAR, "N" - STRING_ALL_CHAR, "A" - STRING_FILE_CHAR,"F" - STRING_DIR_CHAR, "D" - - STRING_HELP, -"XCOPY - Копирует файлы и деревья папок\n\ -\n\ -Синтаксис:\n\ -XCOPY source [dest] [/I] [/S] [/Q] [/F] [/L] [/W] [/T] [/N] [/U]\n\ -\t [/R] [/H] [/C] [/P] [/A] [/M] [/E] [/D] [/Y] [/-Y]\n\ -\n\ -Где:\n\ -\n\ -[/I] Если конечная папка отсутствует и копируется более одного файла,\n\ - то предполагается папка в качестве места назначения.\n\ -[/S] Копирует папки и подпапки.\n\ -[/E] Копирует папки и подпапки, включая пустые.\n\ -[/Q] Не отображает имена копируемых файлов.\n\ -[/F] Отображает полные имена исходных и конечных файлов.\n\ -[/L] Выводит список файлов, которые будут скопированы.\n\ -[/W] Запрашивает подтверждение перед началом копирования.\n\ -[/T] Создает структуру папок, но не копирует файлы.\n\ -[/Y] Подавляет запрос на подтверждение перезаписи файлов.\n\ -[/-Y] Запрашивает подтверждение на перезапись файлов.\n\ -[/P] Запрашивает подтверждение для каждого копируемого файла.\n\ -[/N] Использует короткие имена файлов при копировании.\n\ -[/U] Копирует только те файлы, которые уже существуют в конечной папке.\n\ -[/R] Перезаписывает файлы, доступные только для чтения.\n\ -[/H] Копирует скрытые и системные файлы.\n\ -[/C] Продолжает работу, даже если произошла ошибка.\n\ -[/A] Копирует только те файлы, для которых установлен атрибут \"архивный\".\n\ -[/M] Копирует только те файлы, для которых установлен атрибут \"архивный\",\n\ - при этом атрибут удаляется.\n\ -[/D | /D:m-d-y] Копирует только новые файлы или те, которые были изменены\n\ - после указанной даты. Если дата не указана, копирует только\n\ - те файлы, которые новее в исходной папке.\n" -} +/* + * XCOPY - Wine-compatible xcopy program + * Russian language support + * + * Copyright (C) 2007 J. Edmeades + * Copyright (C) 2007 Kirill K. Smirnov + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + + +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT + +STRINGTABLE +{ + STRING_INVPARMS, +"Íåäîïóñòèìîå ÷èñëî ïàðàìåòðîâ - ïîïðîáóéòå 'xcopy /?' äëÿ ïîëó÷åíèÿ\n\ +ïîäðîáíîãî îïèñàíèÿ.\n" + STRING_INVPARM, +"Íåäîïóñòèìûé ïàðàìåòð '%s' - ïîïðîáóéòå 'xcopy /?' äëÿ ïîëó÷åíèÿ ïîäðîáíîãî\n\ +îïèñàíèÿ.\n" + STRING_PAUSE, "Íàæìèòå êëàâèøó , ÷òîáû íà÷àòü êîïèðîâàíèå.\n" + STRING_SIMCOPY, "%d ôàéë(îâ) áûëî áû ñêîïèðîâàíî.\n" + STRING_COPY, "%d ôàéë(îâ) ñêîïèðîâàíî.\n" + STRING_QISDIR, "'%s' ÿâëÿåòñÿ ôàéëîì èëè ïàïêîé?\n" \ + "(F - Ôàéë, D - Ïàïêà)\n" + STRING_SRCPROMPT,"%s? (Yes|No)\n" + STRING_OVERWRITE,"Ïåðåïèñàòü %s? (Yes|No|All)\n" + STRING_COPYFAIL, "Ïðè êîïèðîâàíèè '%s' â '%s' ïðîèçîøëà îøèáêà: %d\n" + STRING_OPENFAIL, "Íåâîçìîæíî îòêðûòü '%s'\n" + STRING_READFAIL, "Ïðè ÷òåíèè '%s' ïðîèçîøëà îøèáêà\n" + STRING_YES_CHAR, "Y" + STRING_NO_CHAR, "N" + STRING_ALL_CHAR, "A" + STRING_FILE_CHAR,"F" + STRING_DIR_CHAR, "D" + + STRING_HELP, +"XCOPY - Êîïèðóåò ôàéëû è äåðåâüÿ ïàïîê\n\ +\n\ +Ñèíòàêñèñ:\n\ +XCOPY source [dest] [/I] [/S] [/Q] [/F] [/L] [/W] [/T] [/N] [/U]\n\ +\t [/R] [/H] [/C] [/P] [/A] [/M] [/E] [/D] [/Y] [/-Y]\n\ +\n\ +Ãäå:\n\ +\n\ +[/I] Åñëè êîíå÷íàÿ ïàïêà îòñóòñòâóåò è êîïèðóåòñÿ áîëåå îäíîãî ôàéëà,\n\ + òî ïðåäïîëàãàåòñÿ ïàïêà â êà÷åñòâå ìåñòà íàçíà÷åíèÿ.\n\ +[/S] Êîïèðóåò ïàïêè è ïîäïàïêè.\n\ +[/E] Êîïèðóåò ïàïêè è ïîäïàïêè, âêëþ÷àÿ ïóñòûå.\n\ +[/Q] Íå îòîáðàæàåò èìåíà êîïèðóåìûõ ôàéëîâ.\n\ +[/F] Îòîáðàæàåò ïîëíûå èìåíà èñõîäíûõ è êîíå÷íûõ ôàéëîâ.\n\ +[/L] Âûâîäèò ñïèñîê ôàéëîâ, êîòîðûå áóäóò ñêîïèðîâàíû.\n\ +[/W] Çàïðàøèâàåò ïîäòâåðæäåíèå ïåðåä íà÷àëîì êîïèðîâàíèÿ.\n\ +[/T] Ñîçäàåò ñòðóêòóðó ïàïîê, íî íå êîïèðóåò ôàéëû.\n\ +[/Y] Ïîäàâëÿåò çàïðîñ íà ïîäòâåðæäåíèå ïåðåçàïèñè ôàéëîâ.\n\ +[/-Y] Çàïðàøèâàåò ïîäòâåðæäåíèå íà ïåðåçàïèñü ôàéëîâ.\n\ +[/P] Çàïðàøèâàåò ïîäòâåðæäåíèå äëÿ êàæäîãî êîïèðóåìîãî ôàéëà.\n\ +[/N] Èñïîëüçóåò êîðîòêèå èìåíà ôàéëîâ ïðè êîïèðîâàíèè.\n\ +[/U] Êîïèðóåò òîëüêî òå ôàéëû, êîòîðûå óæå ñóùåñòâóþò â êîíå÷íîé ïàïêå.\n\ +[/R] Ïåðåçàïèñûâàåò ôàéëû, äîñòóïíûå òîëüêî äëÿ ÷òåíèÿ.\n\ +[/H] Êîïèðóåò ñêðûòûå è ñèñòåìíûå ôàéëû.\n\ +[/C] Ïðîäîëæàåò ðàáîòó, äàæå åñëè ïðîèçîøëà îøèáêà.\n\ +[/A] Êîïèðóåò òîëüêî òå ôàéëû, äëÿ êîòîðûõ óñòàíîâëåí àòðèáóò \"àðõèâíûé\".\n\ +[/M] Êîïèðóåò òîëüêî òå ôàéëû, äëÿ êîòîðûõ óñòàíîâëåí àòðèáóò \"àðõèâíûé\",\n\ + ïðè ýòîì àòðèáóò óäàëÿåòñÿ.\n\ +[/D | /D:m-d-y] Êîïèðóåò òîëüêî íîâûå ôàéëû èëè òå, êîòîðûå áûëè èçìåíåíû\n\ + ïîñëå óêàçàííîé äàòû. Åñëè äàòà íå óêàçàíà, êîïèðóåò òîëüêî\n\ + òå ôàéëû, êîòîðûå íîâåå â èñõîäíîé ïàïêå.\n" +} diff --git a/programs/xcopy/Si.rc b/programs/xcopy/Si.rc index 1013837f402..092282c1636 100644 --- a/programs/xcopy/Si.rc +++ b/programs/xcopy/Si.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "xcopy.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -80,3 +78,5 @@ Where:\n\ \t\tod izvora\n\n" } + +#pragma code_page(default) diff --git a/programs/xcopy/rsrc.rc b/programs/xcopy/rsrc.rc new file mode 100644 index 00000000000..dcbc81152d1 --- /dev/null +++ b/programs/xcopy/rsrc.rc @@ -0,0 +1,35 @@ +/* + * Copyright 2007 Jason Edmeades + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include + +#include "xcopy.h" + +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + +#include "Da.rc" +#include "De.rc" +#include "En.rc" +#include "Fr.rc" +#include "Ko.rc" +#include "Nl.rc" +#include "No.rc" +#include "Pl.rc" +#include "Pt.rc" +#include "Ru.rc" +#include "Si.rc" diff --git a/programs/xcopy/xcopy.h b/programs/xcopy/xcopy.h index 1c933951284..ee4bd910cde 100644 --- a/programs/xcopy/xcopy.h +++ b/programs/xcopy/xcopy.h @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include - /* Local #defines */ #define RC_OK 0 #define RC_NOFILES 1 diff --git a/server/change.c b/server/change.c index 773fa1c3575..63985f4bc67 100644 --- a/server/change.c +++ b/server/change.c @@ -65,10 +65,7 @@ /* inotify support */ -#ifdef HAVE_SYS_INOTIFY_H -#include -#define USE_INOTIFY -#elif defined(__linux__) && defined(__i386__) +#if defined(__linux__) && defined(__i386__) #define SYS_inotify_init 291 #define SYS_inotify_add_watch 292 @@ -117,7 +114,7 @@ static inline int inotify_add_watch( int fd, const char *name, unsigned int mask return ret; } -static inline int inotify_rm_watch( int fd, int wd ) +static inline int inotify_remove_watch( int fd, int wd ) { int ret; __asm__ __volatile__( "pushl %%ebx;\n\t" @@ -571,7 +568,7 @@ static void free_inode( struct inode *inode ) if (inode->wd != -1) { - inotify_rm_watch( get_unix_fd( inotify_fd ), inode->wd ); + inotify_remove_watch( get_unix_fd( inotify_fd ), inode->wd ); list_remove( &inode->wd_entry ); } list_remove( &inode->ino_entry ); diff --git a/server/file.c b/server/file.c index 98017b9fe2f..dc93b4bcfdf 100644 --- a/server/file.c +++ b/server/file.c @@ -602,8 +602,8 @@ void file_set_error(void) case ENOSPC: set_error( STATUS_DISK_FULL ); break; case EACCES: case ESRCH: - case EROFS: case EPERM: set_error( STATUS_ACCESS_DENIED ); break; + case EROFS: set_error( STATUS_MEDIA_WRITE_PROTECTED ); break; case EBUSY: set_error( STATUS_FILE_LOCK_CONFLICT ); break; case ENOENT: set_error( STATUS_NO_SUCH_FILE ); break; case EISDIR: set_error( STATUS_FILE_IS_A_DIRECTORY ); break; diff --git a/server/process.c b/server/process.c index 2b8d8f6cc64..8a4fb15a711 100644 --- a/server/process.c +++ b/server/process.c @@ -1068,7 +1068,6 @@ DECL_HANDLER(get_process_info) reply->peb = process->peb; reply->start_time = process->start_time; reply->end_time = process->end_time; - reply->cpu = process->cpu; release_object( process ); } } diff --git a/server/protocol.def b/server/protocol.def index e871736f75f..8ae653bea3a 100644 --- a/server/protocol.def +++ b/server/protocol.def @@ -660,7 +660,6 @@ typedef union timeout_t end_time; /* process end time */ int exit_code; /* process exit code */ int priority; /* priority class */ - cpu_type_t cpu; /* CPU that this process is running on */ @END diff --git a/server/request.h b/server/request.h index 4fc3bd6a3c2..f85756c8f89 100644 --- a/server/request.h +++ b/server/request.h @@ -694,8 +694,7 @@ C_ASSERT( FIELD_OFFSET(struct get_process_info_reply, start_time) == 32 ); C_ASSERT( FIELD_OFFSET(struct get_process_info_reply, end_time) == 40 ); C_ASSERT( FIELD_OFFSET(struct get_process_info_reply, exit_code) == 48 ); C_ASSERT( FIELD_OFFSET(struct get_process_info_reply, priority) == 52 ); -C_ASSERT( FIELD_OFFSET(struct get_process_info_reply, cpu) == 56 ); -C_ASSERT( sizeof(struct get_process_info_reply) == 64 ); +C_ASSERT( sizeof(struct get_process_info_reply) == 56 ); C_ASSERT( FIELD_OFFSET(struct set_process_info_request, handle) == 12 ); C_ASSERT( FIELD_OFFSET(struct set_process_info_request, mask) == 16 ); C_ASSERT( FIELD_OFFSET(struct set_process_info_request, priority) == 20 ); diff --git a/server/trace.c b/server/trace.c index d24f653251b..6781ef7f39e 100644 --- a/server/trace.c +++ b/server/trace.c @@ -1152,7 +1152,6 @@ static void dump_get_process_info_reply( const struct get_process_info_reply *re dump_timeout( ", end_time=", &req->end_time ); fprintf( stderr, ", exit_code=%d", req->exit_code ); fprintf( stderr, ", priority=%d", req->priority ); - dump_cpu_type( ", cpu=", &req->cpu ); } static void dump_set_process_info_request( const struct set_process_info_request *req ) diff --git a/tools/Makefile.in b/tools/Makefile.in index b711a7b75d4..ea4e0078228 100644 --- a/tools/Makefile.in +++ b/tools/Makefile.in @@ -27,7 +27,7 @@ C_SRCS = \ make_ctests.c \ makedep.c \ relpath.c \ - sfnt2fnt.c + sfnt2fnt.c \ INSTALLSUBDIRS = \ widl \ diff --git a/tools/make_makefiles b/tools/make_makefiles index fb156979007..91f7d39335e 100755 --- a/tools/make_makefiles +++ b/tools/make_makefiles @@ -74,9 +74,8 @@ my @ignores = ( "dlls/*/tests/testlist.c", "include/config.h", "include/stamp-h", + "programs/winetest/tests.rc", "programs/winetest/*_test.exe", - "programs/winetest/*_test.rc", - "programs/winetest/build.rc", ); # Source files and their resulting target to ignore @@ -109,38 +108,17 @@ my %exported_wine_headers = ( my %private_idl_headers = ( "axcore.idl" => 1, "axextend.idl" => 1, - "binres.idl" => 1, - "crtrow.idl" => 1, - "dbccmd.idl" => 1, - "dbcses.idl" => 1, - "dbdsad.idl" => 1, "dbinit.idl" => 1, "dbprop.idl" => 1, "dbs.idl" => 1, "devenum.idl" => 1, "dyngraph.idl" => 1, - "opnrst.idl" => 1, - "sesprp.idl" => 1, "vmrender.idl" => 1, "wine/wined3d.idl" => 1, "wine/winedxgi.idl" => 1, ); -my %ignored_source_files = ( - "dlls/wineps.drv/afm2c.c" => 1, - "dlls/wineps.drv/mkagl.c" => 1, - "programs/winetest/dist.rc" => 1, -); - -my (@all_files, @makefiles, %makefiles); - -sub dirname($) -{ - my $ret = shift; - return "" unless $ret =~ /\//; - $ret =~ s!/[^/]*$!!; - return $ret; -} +my (@makefiles, %makefiles); # update a file if changed sub update_file($) @@ -200,49 +178,6 @@ sub replace_in_file($$$@) return update_file($file); } -# replace a variable in a makefile -sub replace_makefile_variable($$) -{ - my ($file, $var) = @_; - my $make = $makefiles{$file}; - - return unless defined ${$make}{"=$var"}; - - my @values = @{${$make}{"=$var"}}; - ${$make}{$var} = \@values; - - open NEW_FILE, ">$file.in.new" or die "cannot create $file.in.new"; - - open OLD_FILE, "$file.in" or die "cannot open $file.in"; - while () - { - if (/^\s*($var\s+)=/) - { - # try to preserve formatting - my $prefix = $1; - my $multiline = /\\$/ || (@values > 1); - while (/\\$/) - { - $_ = ; - last unless $_; - } - if ($multiline) - { - print NEW_FILE "$var = \\\n\t" . join(" \\\n\t", sort @values) . "\n"; - } - else - { - print NEW_FILE "$prefix= @values\n"; - } - next; - } - print NEW_FILE $_; - } - close OLD_FILE; - close NEW_FILE; - return update_file("$file.in"); -} - # parse the specified makefile to identify the rules file sub parse_makefile($) { @@ -256,9 +191,7 @@ sub parse_makefile($) while () { chomp; - next if (/^\s*#/); while (/\\$/) { chop; $_ .= ; chomp; } # merge continued lines - next if (/^\s*$/); if (/^\@(MAKE.*RULES)\@/) { @@ -266,12 +199,12 @@ sub parse_makefile($) $make{"=rules"} = $makerules{$var}; next; } - if (/^\s*(MODULE|IMPORTLIB|TESTDLL)\s*=\s*(.*)/) + if (/^(MODULE|IMPORTLIB|TESTDLL)\s*=\s*(.*)/) { $make{$1} = $2; next; } - if (/^\s*(BISON_SRCS|LEX_SRCS|IDL_[CHIPS]_SRCS|IDL_TLB_SRCS|IMPLIB_SRCS|C_SRCS|MC_SRCS|RC_SRCS|SVG_SRCS|C_SRCS16|RC_SRCS16|SPEC_SRCS16|EXTRA_OBJS16|MANPAGES|PROGRAMS)\s*=\s*(.*)/) + if (/^(BISON_SRCS|LEX_SRCS|IDL_[CHIPS]_SRCS|IDL_TLB_SRCS|IMPLIB_SRCS|MC_SRCS|RC_SRCS|RC_SRCS16|RC_BINARIES|SPEC_SRCS16|EXTRA_OBJS16|MANPAGES|PROGRAMS)\s*=\s*(.*)/) { my @list = split(/\s+/, $2); $make{$1} = \@list; @@ -281,30 +214,6 @@ sub parse_makefile($) return %make; } -# assign source files to their respective makefile -sub assign_sources_to_makefiles() -{ - foreach my $file (@all_files) - { - next if defined $ignored_source_files{$file}; - my $dir = dirname( $file ); - - while ($dir && !defined $makefiles{"$dir/Makefile"}) { $dir = dirname( $dir ); } - next unless $dir; - - die "no makefile found for $file\n" unless defined $makefiles{"$dir/Makefile"}; - - my $make = $makefiles{"$dir/Makefile"}; - my $basename = substr( $file, length($dir) + 1 ); - - if ($basename =~ /\.c$/) { push @{${$make}{"=C_SRCS"}}, $basename; } - elsif ($basename =~ /\.l$/) { push @{${$make}{"=LEX_SRCS"}}, $basename; } - elsif ($basename =~ /\.y$/) { push @{${$make}{"=BISON_SRCS"}}, $basename; } - elsif ($basename =~ /\.rc$/) { push @{${$make}{"=RC_SRCS"}}, $basename; } - elsif ($basename =~ /\.rc$/) { push @{${$make}{"=RC_SRCS"}}, $basename; } - elsif ($basename =~ /\.svg$/) { push @{${$make}{"=SVG_SRCS"}}, $basename; } - } -} ################################################################ # update the makefile list in configure.ac @@ -347,20 +256,6 @@ sub update_makefiles(@) push @lines, "WINE_CONFIG_MAKEFILE([$file],[$rules]$args)\n"; } - # update the source variables in all the makefiles - - foreach my $file (sort @_) - { - my %make = %{$makefiles{$file}}; - - replace_makefile_variable( $file, "LEX_SRCS" ); - replace_makefile_variable( $file, "BISON_SRCS" ); - replace_makefile_variable( $file, "MC_SRCS" ); - replace_makefile_variable( $file, "SVG_SRCS" ); - replace_makefile_variable( $file, "C_SRCS" ) unless defined $make{"C_SRCS16"}; - replace_makefile_variable( $file, "RC_SRCS" ) unless defined $make{"RC_SRCS16"}; - } - push @lines, "\ndnl Build dependencies for test files compiled into winetest\n"; replace_in_file( "configure.ac", '^WINE_CONFIG_MAKERULES', '^dnl Build dependencies for test files compiled into winetest$', @lines); } @@ -596,8 +491,9 @@ sub update_dlls(@) sub update_includes() { + return unless -d ".git"; my (@h_srcs, @private_idl_srcs, @public_idl_srcs, @tlb_srcs, %subdirs); - my @includes = map { (my $ret = $_) =~ s/^include\///; $ret; } grep /^include\//, @all_files; + my @includes = map { s/^include\///; $_; } split /\0/, `git ls-files -c -z include`; foreach my $incl (@includes) { if ($incl =~ /(.*)\//) { $subdirs{$1} = 1; } @@ -665,10 +561,14 @@ sub update_gitignore(@) } -die "needs to be run from a git checkout" unless -d ".git"; - -@all_files = split /\0/, `git ls-files -c -z`; -@makefiles = map { my $ret = $_; $ret =~ s/\.in$//; $ret; } grep /Makefile.in$/, @all_files; +if (-d ".git") +{ + @makefiles = map { s/\.in$//; $_; } split /\0/, `git ls-files -c -z Makefile.in \\*/Makefile.in`; +} +else +{ + @makefiles = map { s/^\.\/(.*)\.in/$1/; $_; } split(/\s/,`find . -name Makefile.in -print`); +} foreach my $file (sort values %makerules, @makefiles) { @@ -676,7 +576,6 @@ foreach my $file (sort values %makerules, @makefiles) $makefiles{$file} = \%make; } -assign_sources_to_makefiles(); update_makefiles( @makefiles ); push @ignores, update_includes(); push @ignores, update_ignores( @makefiles ); diff --git a/tools/makedep.c b/tools/makedep.c index e2ca5ad9e85..4194073890b 100644 --- a/tools/makedep.c +++ b/tools/makedep.c @@ -53,14 +53,6 @@ typedef struct _INCL_FILE static struct list sources = LIST_INIT(sources); static struct list includes = LIST_INIT(includes); -typedef struct _OBJECT_EXTENSION -{ - struct list entry; - const char *extension; -} OBJECT_EXTENSION; - -static struct list object_extensions = LIST_INIT(object_extensions); - typedef struct _INCL_PATH { struct list entry; @@ -226,18 +218,6 @@ static char *get_line( FILE *file ) } /******************************************************************* - * add_object_extension - * - * Add an extension for object files. - */ -static void add_object_extension( const char *ext ) -{ - OBJECT_EXTENSION *object_extension = xmalloc( sizeof(*object_extension) ); - list_add_tail( &object_extensions, &object_extension->entry ); - object_extension->extension = ext; -} - -/******************************************************************* * add_include_path * * Add a directory to the include path. @@ -877,10 +857,7 @@ static int output_src( FILE *file, INCL_FILE *pFile, int *column ) } else { - OBJECT_EXTENSION *ext; - LIST_FOR_EACH_ENTRY( ext, &object_extensions, OBJECT_EXTENSION, entry ) - *column += fprintf( file, "%s.%s ", obj, ext->extension ); - *column += fprintf( file, ": %s", pFile->filename ); + *column += fprintf( file, "%s.o: %s", obj, pFile->filename ); } } free( obj ); @@ -996,9 +973,6 @@ static void parse_option( const char *opt ) if (opt[2]) Separator = opt + 2; else Separator = NULL; break; - case 'x': - if (opt[2]) add_object_extension( opt + 2 ); - break; default: fprintf( stderr, "Unknown option '%s'\n", opt ); fprintf( stderr, Usage, ProgramName ); @@ -1034,10 +1008,6 @@ int main( int argc, char *argv[] ) if (src_dir && !strcmp( src_dir, "." )) src_dir = NULL; if (top_src_dir && top_obj_dir && !strcmp( top_src_dir, top_obj_dir )) top_src_dir = NULL; - /* set the default extension list for object files */ - if (list_empty( &object_extensions )) - add_object_extension( "o" ); - /* get rid of absolute paths that don't point into the source dir */ LIST_FOR_EACH_ENTRY_SAFE( path, next, &paths, INCL_PATH, entry ) { diff --git a/tools/widl/typegen.c b/tools/widl/typegen.c index d297eb28d59..b60a53c105c 100644 --- a/tools/widl/typegen.c +++ b/tools/widl/typegen.c @@ -59,7 +59,6 @@ struct expr_eval_routine const expr_t *expr; }; -static unsigned int field_memsize(const type_t *type, unsigned int *offset); static unsigned int fields_memsize(const var_list_t *fields, unsigned int *align); static unsigned int write_struct_tfs(FILE *file, type_t *type, const char *name, unsigned int *tfsoff); static int write_embedded_types(FILE *file, const attr_list_t *attrs, type_t *type, @@ -979,13 +978,14 @@ static unsigned int write_conf_or_var_desc(FILE *file, const type_t *structure, if (fields) LIST_FOR_EACH_ENTRY( var, fields, const var_t, entry ) { - unsigned int size = field_memsize( var->type, &offset ); + unsigned int align = 0; + /* FIXME: take alignment into account */ if (var->name && !strcmp(var->name, subexpr->u.sval)) { correlation_variable = var->type; break; } - offset += size; + offset += type_memsize(var->type, &align); } if (!correlation_variable) error("write_conf_or_var_desc: couldn't find variable %s in structure\n", @@ -1081,18 +1081,9 @@ static unsigned int write_conf_or_var_desc(FILE *file, const type_t *structure, return 4; } -/* return size and start offset of a data field based on current offset */ -static unsigned int field_memsize(const type_t *type, unsigned int *offset) -{ - unsigned int align = 0; - unsigned int size = type_memsize( type, &align ); - - *offset = ROUND_SIZE( *offset, align ); - return size; -} - static unsigned int fields_memsize(const var_list_t *fields, unsigned int *align) { + int have_align = FALSE; unsigned int size = 0; const var_t *v; @@ -1101,7 +1092,11 @@ static unsigned int fields_memsize(const var_list_t *fields, unsigned int *align { unsigned int falign = 0; unsigned int fsize = type_memsize(v->type, &falign); - if (*align < falign) *align = falign; + if (!have_align) + { + *align = falign; + have_align = TRUE; + } size = ROUND_SIZE(size, falign); size += fsize; } @@ -1133,7 +1128,7 @@ static unsigned int union_memsize(const var_list_t *fields, unsigned int *pmaxa) int get_padding(const var_list_t *fields) { unsigned short offset = 0; - unsigned int salign = 1; + int salign = -1; const var_t *f; if (!fields) @@ -1144,7 +1139,8 @@ int get_padding(const var_list_t *fields) type_t *ft = f->type; unsigned int align = 0; unsigned int size = type_memsize(ft, &align); - if (align > salign) salign = align; + if (salign == -1) + salign = align; offset = ROUND_SIZE(offset, align); offset += size; } @@ -1194,11 +1190,14 @@ unsigned int type_memsize(const type_t *t, unsigned int *align) case TYPE_ENUM: switch (get_enum_fc(t)) { - case RPC_FC_ENUM16: case RPC_FC_ENUM32: size = 4; if (size > *align) *align = size; break; + case RPC_FC_ENUM16: + size = 2; + if (size > *align) *align = size; + break; default: error("type_memsize: Unknown enum type\n"); size = 0; @@ -1518,15 +1517,12 @@ static void write_descriptors(FILE *file, type_t *type, unsigned int *tfsoff) if (fs) LIST_FOR_EACH_ENTRY(f, fs, var_t, entry) { + unsigned int align = 0; type_t *ft = f->type; - unsigned int size = field_memsize( ft, &offset ); if (type_get_type(ft) == TYPE_UNION && is_attr(f->attrs, ATTR_SWITCHIS)) { - short reloff; unsigned int absoff = ft->typestring_offset; - if (is_attr(ft->attrs, ATTR_SWITCHTYPE)) - absoff += 8; /* we already have a corr descr, skip it */ - reloff = absoff - (*tfsoff + 6); + short reloff = absoff - (*tfsoff + 6); print_file(file, 0, "/* %d */\n", *tfsoff); print_file(file, 2, "0x%x,\t/* FC_NON_ENCAPSULATED_UNION */\n", RPC_FC_NON_ENCAPSULATED_UNION); print_file(file, 2, "0x%x,\t/* FIXME: always FC_LONG */\n", RPC_FC_LONG); @@ -1536,7 +1532,9 @@ static void write_descriptors(FILE *file, type_t *type, unsigned int *tfsoff) reloff, reloff, absoff); *tfsoff += 8; } - offset += size; + + /* FIXME: take alignment into account */ + offset += type_memsize(ft, &align); } } @@ -2201,19 +2199,19 @@ static void write_struct_members(FILE *file, const type_t *type, { const var_t *field; unsigned short offset = 0; - unsigned int salign = 1; + int salign = -1; int padding; var_list_t *fields = type_struct_get_fields(type); if (fields) LIST_FOR_EACH_ENTRY( field, fields, const var_t, entry ) { type_t *ft = field->type; - unsigned int align = 0; - unsigned int size = type_memsize(ft, &align); - if (salign < align) salign = align; - if (!is_conformant_array(ft) || type_array_is_decl_as_ptr(ft)) { + unsigned int align = 0; + unsigned int size = type_memsize(ft, &align); + if (salign == -1) + salign = align; if ((align - 1) & offset) { unsigned char fc = 0; @@ -2511,7 +2509,6 @@ static unsigned int write_union_tfs(FILE *file, type_t *type, unsigned int *tfso *tfsoff += write_conf_or_var_desc(file, NULL, *tfsoff, st, &dummy_expr ); print_file(file, 2, "NdrFcShort(0x2),\t/* Offset= 2 (%u) */\n", *tfsoff + 2); *tfsoff += 2; - print_file(file, 0, "/* %u */\n", *tfsoff); } print_file(file, 2, "NdrFcShort(0x%hx),\t/* %d */\n", size, size); diff --git a/tools/winapi/c_function.pm b/tools/winapi/c_function.pm index 773c6b2ded6..c7645764bf2 100644 --- a/tools/winapi/c_function.pm +++ b/tools/winapi/c_function.pm @@ -22,7 +22,7 @@ use strict; sub new($) { - my ($proto) = @_; + my $proto = shift; my $class = ref($proto) || $proto; my $self = {}; bless ($self, $class); @@ -37,100 +37,170 @@ sub new($) sub file($;$) { - my ($self, $filename) = @_; - $self->{file} = $filename if (defined $filename); - return $self->{file}; + my $self = shift; + my $file = \${$self->{FILE}}; + + local $_ = shift; + + if(defined($_)) { $$file = $_; } + + return $$file; } -sub begin_line($$) +sub begin_line($;$) { - my ($self, $begin_line) = @_; - $self->{begin_line} = $begin_line if (defined $begin_line); - return $self->{begin_line}; + my $self = shift; + my $begin_line = \${$self->{BEGIN_LINE}}; + + local $_ = shift; + + if(defined($_)) { $$begin_line = $_; } + + return $$begin_line; } sub begin_column($;$) { - my ($self, $begin_column) = @_; - $self->{begin_column} = $begin_column if (defined $begin_column); - return $self->{begin_column}; + my $self = shift; + my $begin_column = \${$self->{BEGIN_COLUMN}}; + + local $_ = shift; + + if(defined($_)) { $$begin_column = $_; } + + return $$begin_column; } sub end_line($;$) { - my ($self, $end_line) = @_; - $self->{end_line} = $end_line if (defined $end_line); - return $self->{end_line}; + my $self = shift; + my $end_line = \${$self->{END_LINE}}; + + local $_ = shift; + + if(defined($_)) { $$end_line = $_; } + + return $$end_line; } sub end_column($;$) { - my ($self, $end_column) = @_; - $self->{end_column} = $end_column if (defined $end_column); - return $self->{end_column}; + my $self = shift; + my $end_column = \${$self->{END_COLUMN}}; + + local $_ = shift; + + if(defined($_)) { $$end_column = $_; } + + return $$end_column; } sub linkage($;$) { - my ($self, $linkage) = @_; - $self->{linkage} = $linkage if (defined $linkage); - return $self->{linkage}; + my $self = shift; + my $linkage = \${$self->{LINKAGE}}; + + local $_ = shift; + + if(defined($_)) { $$linkage = $_; } + + return $$linkage; } sub return_type($;$) { - my ($self, $return_type) = @_; - $self->{return_type} = $return_type if (defined $return_type); - return $self->{return_type}; + my $self = shift; + my $return_type = \${$self->{RETURN_TYPE}}; + + local $_ = shift; + + if(defined($_)) { $$return_type = $_; } + + return $$return_type; } sub calling_convention($;$) { - my ($self, $calling_convention) = @_; - $self->{calling_convention} = $calling_convention if (defined $calling_convention); - return $self->{calling_convention}; + my $self = shift; + my $calling_convention = \${$self->{CALLING_CONVENTION}}; + + local $_ = shift; + + if(defined($_)) { $$calling_convention = $_; } + + return $$calling_convention; } sub name($;$) { - my ($self, $name) = @_; - $self->{name} = $name if (defined $name); - return $self->{name}; + my $self = shift; + my $name = \${$self->{NAME}}; + + local $_ = shift; + + if(defined($_)) { $$name = $_; } + + return $$name; } sub argument_types($;$) { - my ($self, $argument_types) = @_; - $self->{argument_types} = $argument_types if (defined $argument_types); - return $self->{argument_types}; + my $self = shift; + my $argument_types = \${$self->{ARGUMENT_TYPES}}; + + local $_ = shift; + + if(defined($_)) { $$argument_types = $_; } + + return $$argument_types; } sub argument_names($;$) { - my ($self, $argument_names) = @_; - $self->{argument_names} = $argument_names if (defined $argument_names); - return $self->{argument_names}; + my $self = shift; + my $argument_names = \${$self->{ARGUMENT_NAMES}}; + + local $_ = shift; + + if(defined($_)) { $$argument_names = $_; } + + return $$argument_names; } sub statements_line($;$) { - my ($self, $statements_line) = @_; - $self->{statements_line} = $statements_line if (defined $statements_line); - return $self->{statements_line}; + my $self = shift; + my $statements_line = \${$self->{STATEMENTS_LINE}}; + + local $_ = shift; + + if(defined($_)) { $$statements_line = $_; } + + return $$statements_line; } sub statements_column($;$) { - my ($self, $statements_column) = @_; - $self->{statements_column} = $statements_column if (defined $statements_column); - return $self->{statements_column}; + my $self = shift; + my $statements_column = \${$self->{STATEMENTS_COLUMN}}; + + local $_ = shift; + + if(defined($_)) { $$statements_column = $_; } + + return $$statements_column; } sub statements($;$) { - my ($self, $statements) = @_; - $self->{statements} = $statements if (defined $statements); - return $self->{statements}; + my $self = shift; + my $statements = \${$self->{STATEMENTS}}; + + local $_ = shift; + + if(defined($_)) { $$statements = $_; } + + return $$statements; } 1; diff --git a/tools/winapi/c_parser.pm b/tools/winapi/c_parser.pm index e927fb9f60e..1de62ee3afc 100644 --- a/tools/winapi/c_parser.pm +++ b/tools/winapi/c_parser.pm @@ -50,96 +50,155 @@ sub parse_c_typedef($$$$); sub parse_c_variable($$$$$$$); -sub new($$) -{ - my ($proto, $filename) = @_; +######################################################################## +# new +# +sub new($$) { + my $proto = shift; my $class = ref($proto) || $proto; - my $self = {FILE => $filename, - CREATE_FUNCTION => sub { return new c_function; }, - CREATE_TYPE => sub { return new c_type; }, - FOUND_COMMENT => sub { return 1; }, - FOUND_DECLARATION => sub { return 1; }, - FOUND_FUNCTION => sub { return 1; }, - FOUND_FUNCTION_CALL => sub { return 1; }, - FOUND_LINE => sub { return 1; }, - FOUND_PREPROCESSOR => sub { return 1; }, - FOUND_STATEMENT => sub { return 1; }, - FOUND_TYPE => sub { return 1; }, - FOUND_VARIABLE => sub { return 1; } - }; + my $self = {}; bless ($self, $class); + + my $file = \${$self->{FILE}}; + my $create_function = \${$self->{CREATE_FUNCTION}}; + my $create_type = \${$self->{CREATE_TYPE}}; + my $found_comment = \${$self->{FOUND_COMMENT}}; + my $found_declaration = \${$self->{FOUND_DECLARATION}}; + my $found_function = \${$self->{FOUND_FUNCTION}}; + my $found_function_call = \${$self->{FOUND_FUNCTION_CALL}}; + my $found_line = \${$self->{FOUND_LINE}}; + my $found_preprocessor = \${$self->{FOUND_PREPROCESSOR}}; + my $found_statement = \${$self->{FOUND_STATEMENT}}; + my $found_type = \${$self->{FOUND_TYPE}}; + my $found_variable = \${$self->{FOUND_VARIABLE}}; + + $$file = shift; + + $$create_function = sub { return new c_function; }; + $$create_type = sub { return new c_type; }; + $$found_comment = sub { return 1; }; + $$found_declaration = sub { return 1; }; + $$found_function = sub { return 1; }; + $$found_function_call = sub { return 1; }; + $$found_line = sub { return 1; }; + $$found_preprocessor = sub { return 1; }; + $$found_statement = sub { return 1; }; + $$found_type = sub { return 1; }; + $$found_variable = sub { return 1; }; + return $self; } - -# -# Callback setters +######################################################################## +# set_found_comment_callback # +sub set_found_comment_callback($$) { + my $self = shift; -sub set_found_comment_callback($$) -{ - my ($self, $found_comment) = @_; - $self->{FOUND_COMMENT} = $found_comment; + my $found_comment = \${$self->{FOUND_COMMENT}}; + + $$found_comment = shift; } -sub set_found_declaration_callback($$) -{ - my ($self, $found_declaration) = @_; - $self->{FOUND_DEClARATION} = $found_declaration; +######################################################################## +# set_found_declaration_callback +# +sub set_found_declaration_callback($$) { + my $self = shift; + + my $found_declaration = \${$self->{FOUND_DECLARATION}}; + + $$found_declaration = shift; } - sub set_found_function_callback($$) -{ - my ($self, $found_function) = @_; - $self->{FOUND_FUNCTION} = $found_function; +######################################################################## +# set_found_function_callback +# +sub set_found_function_callback($$) { + my $self = shift; + + my $found_function = \${$self->{FOUND_FUNCTION}}; + + $$found_function = shift; } -sub set_found_function_call_callback($$) -{ - my ($self, $found_function_call) = @_; - $self->{FOUND_FUNCTION_CALL} = $found_function_call; +######################################################################## +# set_found_function_call_callback +# +sub set_found_function_call_callback($$) { + my $self = shift; + + my $found_function_call = \${$self->{FOUND_FUNCTION_CALL}}; + + $$found_function_call = shift; } -sub set_found_line_callback($$) -{ - my ($self, $found_line) = @_; - $self->{FOUND_LINE} = $found_line; +######################################################################## +# set_found_line_callback +# +sub set_found_line_callback($$) { + my $self = shift; + + my $found_line = \${$self->{FOUND_LINE}}; + + $$found_line = shift; } -sub set_found_preprocessor_callback($$) -{ - my ($self, $found_preprocessor) = @_; - $self->{FOUND_PREPROCESSOR} = $found_preprocessor; +######################################################################## +# set_found_preprocessor_callback +# +sub set_found_preprocessor_callback($$) { + my $self = shift; + + my $found_preprocessor = \${$self->{FOUND_PREPROCESSOR}}; + + $$found_preprocessor = shift; } -sub set_found_statement_callback($$) -{ - my ($self, $found_statement) = @_; - $self->{FOUND_STATEMENT} = $found_statement; +######################################################################## +# set_found_statement_callback +# +sub set_found_statement_callback($$) { + my $self = shift; + + my $found_statement = \${$self->{FOUND_STATEMENT}}; + + $$found_statement = shift; } -sub set_found_type_callback($$) -{ - my ($self, $found_type) = @_; - $self->{FOUND_TYPE} = $found_type; +######################################################################## +# set_found_type_callback +# +sub set_found_type_callback($$) { + my $self = shift; + + my $found_type = \${$self->{FOUND_TYPE}}; + + $$found_type = shift; } -sub set_found_variable_callback($$) -{ - my ($self, $found_variable) = @_; - $self->{FOUND_VARIABLE} = $found_variable; +######################################################################## +# set_found_variable_callback +# +sub set_found_variable_callback($$) { + my $self = shift; + + my $found_variable = \${$self->{FOUND_VARIABLE}}; + + $$found_variable = shift; } ######################################################################## # _format_c_type -sub _format_c_type($$) -{ - my ($self, $type) = @_; - $type =~ s/^\s*(.*?)\s*$/$1/; +sub _format_c_type($$) { + my $self = shift; - if ($type =~ /^(\w+(?:\s*\*)*)\s*\(\s*\*\s*\)\s*\(\s*(.*?)\s*\)$/s) { + local $_ = shift; + s/^\s*(.*?)\s*$/$1/; + + if (/^(\w+(?:\s*\*)*)\s*\(\s*\*\s*\)\s*\(\s*(.*?)\s*\)$/s) { my $return_type = $1; my @arguments = split(/\s*,\s*/, $2); foreach my $argument (@arguments) { @@ -150,10 +209,10 @@ sub _format_c_type($$) } } - $type = "$return_type (*)(" . join(", ", @arguments) . ")"; + $_ = "$return_type (*)(" . join(", ", @arguments) . ")"; } - - return $type; + + return $_; } @@ -161,33 +220,46 @@ sub _format_c_type($$) # _parse_c_warning # # FIXME: Use caller (See man perlfunc) -sub _parse_c_warning($$$$$$) -{ - my ($self, $curlines, $line, $column, $context, $message) = @_; + +sub _parse_c_warning($$$$$$) { + my $self = shift; + + local $_ = shift; + my $line = shift; + my $column = shift; + my $context = shift; + my $message = shift; + + my $file = \${$self->{FILE}}; $message = "warning" if !$message; my $current = ""; - if ($curlines) { - my @lines = split(/\n/, $curlines); + if($_) { + my @lines = split(/\n/, $_); $current .= $lines[0] . "\n" if $lines[0]; $current .= $lines[1] . "\n" if $lines[1]; } if($current) { - $output->write("$self->{FILE}:$line." . ($column + 1) . ": $context: $message: \\\n$current"); + $output->write("$$file:$line." . ($column + 1) . ": $context: $message: \\\n$current"); } else { - $output->write("$self->{FILE}:$line." . ($column + 1) . ": $context: $message\n"); + $output->write("$$file:$line." . ($column + 1) . ": $context: $message\n"); } } ######################################################################## # _parse_c_error -sub _parse_c_error($$$$$$) -{ - my ($self, $curlines, $line, $column, $context, $message) = @_; +sub _parse_c_error($$$$$$) { + my $self = shift; + + local $_ = shift; + my $line = shift; + my $column = shift; + my $context = shift; + my $message = shift; $message = "parse error" if !$message; @@ -197,7 +269,7 @@ sub _parse_c_error($$$$$$) $output->prefix(""); } - $self->_parse_c_warning($curlines, $line, $column, $context, $message); + $self->_parse_c_warning($_, $line, $column, $context, $message); exit 1; } @@ -205,72 +277,59 @@ sub _parse_c_error($$$$$$) ######################################################################## # _update_c_position -sub _update_c_position($$$$) -{ - my ($self, $source, $refline, $refcolumn) = @_; +sub _update_c_position($$$$) { + my $self = shift; + + local $_ = shift; + my $refline = shift; + my $refcolumn = shift; + my $line = $$refline; my $column = $$refcolumn; - while ($source) - { - if ($source =~ s/^[^\n\t\'\"]*//s) - { + while($_) { + if(s/^[^\n\t\'\"]*//s) { $column += length($&); } - if ($source =~ s/^\'//) - { + if(s/^\'//) { $column++; - while ($source =~ /^./ && $source !~ s/^\'//) - { - $source =~ s/^([^\'\\]*)//s; + while(/^./ && !s/^\'//) { + s/^([^\'\\]*)//s; $column += length($1); - if ($source =~ s/^\\//) - { + if(s/^\\//) { $column++; - if ($source =~ s/^(.)//s) - { + if(s/^(.)//s) { $column += length($1); - if ($1 eq "0") - { - $source =~ s/^(\d{0,3})//s; + if($1 eq "0") { + s/^(\d{0,3})//s; $column += length($1); } } } } $column++; - } - elsif ($source =~ s/^\"//) - { + } elsif(s/^\"//) { $column++; - while ($source =~ /^./ && $source !~ s/^\"//) - { - $source =~ s/^([^\"\\]*)//s; + while(/^./ && !s/^\"//) { + s/^([^\"\\]*)//s; $column += length($1); - if ($source =~ s/^\\//) - { + if(s/^\\//) { $column++; - if ($source =~ s/^(.)//s) - { + if(s/^(.)//s) { $column += length($1); - if ($1 eq "0") - { - $source =~ s/^(\d{0,3})//s; + if($1 eq "0") { + s/^(\d{0,3})//s; $column += length($1); } } } } $column++; - } - elsif ($source =~ s/^\n//) - { + } elsif(s/^\n//) { $line++; $column = 0; - } - elsif ($source =~ s/^\t//) - { + } elsif(s/^\t//) { $column = $column + 8 - $column % 8; } } @@ -402,15 +461,33 @@ sub __parse_c_until_one_of($$$$$$$) { return 1; } -sub _parse_c_until_one_of($$$$$$) -{ - my ($self, $characters, $refcurrent, $refline, $refcolumn, $match) = @_; +######################################################################## +# _parse_c_until_one_of + +sub _parse_c_until_one_of($$$$$$) { + my $self = shift; + + my $characters = shift; + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; + my $match = shift; + return $self->__parse_c_until_one_of($characters, 0, $refcurrent, $refline, $refcolumn, $match); } -sub _parse_c_on_same_level_until_one_of($$$$$$) -{ - my ($self, $characters, $refcurrent, $refline, $refcolumn, $match) = @_; +######################################################################## +# _parse_c_on_same_level_until_one_of + +sub _parse_c_on_same_level_until_one_of($$$$$$) { + my $self = shift; + + my $characters = shift; + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; + my $match = shift; + return $self->__parse_c_until_one_of($characters, 1, $refcurrent, $refline, $refcolumn, $match); } @@ -478,10 +555,16 @@ sub parse_c_block($$$$$$$) { return 1; } +######################################################################## +# parse_c_declaration + sub parse_c_declaration($$$$) { my ($self, $refcurrent, $refline, $refcolumn) = @_; + my $found_declaration = \${$self->{FOUND_DECLARATION}}; + my $found_function = \${$self->{FOUND_FUNCTION}}; + local $_ = $$refcurrent; my $line = $$refline; my $column = $$refcolumn; @@ -495,7 +578,7 @@ sub parse_c_declaration($$$$) my $end_column = $begin_column; $self->_update_c_position($_, \$end_line, \$end_column); - if(!$self->{FOUND_DECLARATION}($begin_line, $begin_column, $end_line, $end_column, $_)) { + if(!&$$found_declaration($begin_line, $begin_column, $end_line, $end_column, $_)) { return 1; } @@ -540,7 +623,7 @@ sub parse_c_declaration($$$$) } elsif($self->parse_c_variable(\$_, \$line, \$column, \$linkage, \$type, \$name)) { # Nothing } elsif($self->parse_c_function(\$_, \$line, \$column, \$function)) { - if($self->{FOUND_FUNCTION}($function)) + if(&$$found_function($function)) { my $statements = $function->statements; my $statements_line = $function->statements_line; @@ -563,9 +646,18 @@ sub parse_c_declaration($$$$) return 1; } -sub _parse_c($$$$$$) -{ - my ($self, $pattern, $refcurrent, $refline, $refcolumn, $refmatch) = @_; +######################################################################## +# _parse_c + +sub _parse_c($$$$$$) { + my $self = shift; + + my $pattern = shift; + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; + + my $refmatch = shift; local $_ = $$refcurrent; my $line = $$refline; @@ -590,9 +682,15 @@ sub _parse_c($$$$$$) return 1; } -sub parse_c_enum($$$$) -{ - my ($self, $refcurrent, $refline, $refcolumn) = @_; +######################################################################## +# parse_c_enum + +sub parse_c_enum($$$$) { + my $self = shift; + + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; local $_ = $$refcurrent; my $line = $$refline; @@ -657,9 +755,18 @@ sub parse_c_enum($$$$) $$refcolumn = $column; } -sub parse_c_expression($$$$) -{ - my ($self, $refcurrent, $refline, $refcolumn) = @_; + +######################################################################## +# parse_c_expression + +sub parse_c_expression($$$$) { + my $self = shift; + + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; + + my $found_function_call = \${$self->{FOUND_FUNCTION_CALL}}; local $_ = $$refcurrent; my $line = $$refline; @@ -682,7 +789,7 @@ sub parse_c_expression($$$$) return 0; } - if($self->{FOUND_FUNCTION_CALL}($begin_line, $begin_column, $line, $column, $name, \@arguments)) + if(&$$found_function_call($begin_line, $begin_column, $line, $column, $name, \@arguments)) { while(defined(my $argument = shift @arguments) && defined(my $argument_line = shift @argument_lines) && @@ -705,9 +812,18 @@ sub parse_c_expression($$$$) return 1; } -sub parse_c_file($$$$) -{ - my ($self, $refcurrent, $refline, $refcolumn) = @_; +######################################################################## +# parse_c_file + +sub parse_c_file($$$$) { + my $self = shift; + + my $found_comment = \${$self->{FOUND_COMMENT}}; + my $found_line = \${$self->{FOUND_LINE}}; + + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; local $_ = $$refcurrent; my $line = $$refline; @@ -732,9 +848,9 @@ sub parse_c_file($$$$) $self->_parse_c_until_one_of("#/\\(\\)\\[\\]\\{\\};", \$_, \$line, \$column, \$match); if($line != $previous_line) { - $self->{FOUND_LINE}($line); + &$$found_line($line); } else { - # $self->{FOUND_LINE}("$line.$column"); + # &$$found_line("$line.$column"); } $previous_line = $line; $previous_column = $column; @@ -796,8 +912,12 @@ sub parse_c_file($$$$) next; } + } elsif ($declaration =~ s/^(?:DEFINE_SHLGUID)\s*\(.*?\)//s) { + $self->_update_c_position($&, \$declaration_line, \$declaration_column); } elsif ($declaration =~ s/^(?:DECL_WINELIB_TYPE_AW|DECLARE_HANDLE(?:16)?|TYPE_MARSHAL)\(\s*(\w+)\s*\)\s*//s) { $self->_update_c_position($&, \$declaration_line, \$declaration_column); + } elsif ($declaration =~ s/^ICOM_DEFINE\(\s*(\w+)\s*,\s*(\w+)\s*\)\s*//s) { + $self->_update_c_position($&, \$declaration_line, \$declaration_column); } } else { my $blank_lines = 0; @@ -882,7 +1002,7 @@ sub parse_c_file($$$$) } if(s/^\/\*.*?\*\///s) { - $self->{FOUND_COMMENT}($line, $column + 1, $&); + &$$found_comment($line, $column + 1, $&); local $_ = $&; while(s/^.*?\n//) { $blank_lines++; @@ -891,7 +1011,7 @@ sub parse_c_file($$$$) $column += length($_); } } elsif(s/^\/\/(.*?)\n//) { - $self->{FOUND_COMMENT}($line, $column + 1, $&); + &$$found_comment($line, $column + 1, $&); $blank_lines++; } elsif(s/^\///) { if(!$if0) { @@ -967,7 +1087,7 @@ sub parse_c_file($$$$) $declaration_line = $line; $declaration_column = $column; } elsif($column == 1 && !$extern_c) { - $self->_parse_c_warning("", $line, $column, "file", "inner } ends on column 1"); + $self->_parse_c_error("", $line, $column, "file", "inner } ends on column 1"); } } elsif(s/^;//) { $declaration .= $&; @@ -996,9 +1116,20 @@ sub parse_c_file($$$$) return 1; } -sub parse_c_function($$$$$) -{ - my ($self, $refcurrent, $refline, $refcolumn, $reffunction) = @_; +######################################################################## +# parse_c_function + +sub parse_c_function($$$$$) { + my $self = shift; + + my $file = \${$self->{FILE}}; + my $create_function = \${$self->{CREATE_FUNCTION}}; + + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; + + my $reffunction = shift; local $_ = $$refcurrent; my $line = $$refline; @@ -1105,9 +1236,9 @@ sub parse_c_function($$$$$) $$refline = $line; $$refcolumn = $column; - my $function = $self->{CREATE_FUNCTION}(); + my $function = &$$create_function; - $function->file($self->{FILE}); + $function->file($$file); $function->begin_line($begin_line); $function->begin_column($begin_column); $function->end_line($end_line); @@ -1131,9 +1262,20 @@ sub parse_c_function($$$$$) return 1; } -sub parse_c_function_call($$$$$$$$) -{ - my ($self, $refcurrent, $refline, $refcolumn, $refname, $refarguments, $refargument_lines, $refargument_columns) = @_; +######################################################################## +# parse_c_function_call + +sub parse_c_function_call($$$$$$$$) { + my $self = shift; + + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; + + my $refname = shift; + my $refarguments = shift; + my $refargument_lines = shift; + my $refargument_columns = shift; local $_ = $$refcurrent; my $line = $$refline; @@ -1168,10 +1310,17 @@ sub parse_c_function_call($$$$$$$$) return 1; } +######################################################################## +# parse_c_preprocessor -sub parse_c_preprocessor($$$$) -{ - my ($self, $refcurrent, $refline, $refcolumn) = @_; +sub parse_c_preprocessor($$$$) { + my $self = shift; + + my $found_preprocessor = \${$self->{FOUND_PREPROCESSOR}}; + + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; local $_ = $$refcurrent; my $line = $$refline; @@ -1182,7 +1331,7 @@ sub parse_c_preprocessor($$$$) my $begin_line = $line; my $begin_column = $column + 1; - if(!$self->{FOUND_PREPROCESSOR}($begin_line, $begin_column, "$_")) { + if(!&$$found_preprocessor($begin_line, $begin_column, "$_")) { return 1; } @@ -1209,9 +1358,17 @@ sub parse_c_preprocessor($$$$) return 1; } -sub parse_c_statement($$$$) -{ - my ($self, $refcurrent, $refline, $refcolumn) = @_; +######################################################################## +# parse_c_statement + +sub parse_c_statement($$$$) { + my $self = shift; + + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; + + my $found_function_call = \${$self->{FOUND_FUNCTION_CALL}}; local $_ = $$refcurrent; my $line = $$refline; @@ -1285,9 +1442,17 @@ sub parse_c_statement($$$$) return 1; } -sub parse_c_statements($$$$) -{ - my ($self, $refcurrent, $refline, $refcolumn) = @_; +######################################################################## +# parse_c_statements + +sub parse_c_statements($$$$) { + my $self = shift; + + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; + + my $found_function_call = \${$self->{FOUND_FUNCTION_CALL}}; local $_ = $$refcurrent; my $line = $$refline; @@ -1374,9 +1539,21 @@ sub parse_c_statements($$$$) return 1; } -sub parse_c_struct_union($$$$$$$$$) -{ - my ($self, $refcurrent, $refline, $refcolumn, $refkind, $ref_name, $reffield_type_names, $reffield_names, $refnames) = @_; +######################################################################## +# parse_c_struct_union + +sub parse_c_struct_union($$$$$$$$$) { + my $self = shift; + + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; + + my $refkind = shift; + my $ref_name = shift; + my $reffield_type_names = shift; + my $reffield_names = shift; + my $refnames = shift; local $_ = $$refcurrent; my $line = $$refline; @@ -1390,13 +1567,15 @@ sub parse_c_struct_union($$$$$$$$$) $self->_parse_c_until_one_of("\\S", \$_, \$line, \$column); - if (!s/^(interface|struct|union)\s+((?:MSVCRT|WS)\(\s*\w+\s*\)|\w+)?\s*\{\s*//s) { + if (!s/^(interface\s+|struct\s+|union\s+)((?:MSVCRT|WS)\(\s*\w+\s*\)|\w+)?\s*\{\s*//s) { return 0; } $kind = $1; $_name = $2 || ""; $self->_update_c_position($&, \$line, \$column); + + $kind =~ s/\s+//g; my $match; while ($_ && $self->_parse_c_on_same_level_until_one_of(';', \$_, \$line, \$column, \$match)) @@ -1458,11 +1637,20 @@ sub parse_c_struct_union($$$$$$$$$) return 1; } -sub parse_c_tuple($$$$$$$) -{ - my ($self, $refcurrent, $refline, $refcolumn, - # FIXME: Should not write directly - $items, $item_lines, $item_columns) = @_; +######################################################################## +# parse_c_tuple + +sub parse_c_tuple($$$$$$$) { + my $self = shift; + + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; + + # FIXME: Should not write directly + my $items = shift; + my $item_lines = shift; + my $item_columns = shift; local $_ = $$refcurrent; @@ -1525,9 +1713,17 @@ sub parse_c_tuple($$$$$$$) return 1; } -sub parse_c_type($$$$$) -{ - my ($self, $refcurrent, $refline, $refcolumn, $reftype) = @_; +######################################################################## +# parse_c_type + +sub parse_c_type($$$$$) { + my $self = shift; + + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; + + my $reftype = shift; local $_ = $$refcurrent; my $line = $$refline; @@ -1557,72 +1753,100 @@ sub parse_c_type($$$$$) return 1; } -sub parse_c_typedef($$$$) -{ - my ($self, $refcurrent, $refline, $refcolumn) = @_; +######################################################################## +# parse_c_typedef + +sub parse_c_typedef($$$$) { + my $self = shift; + + my $create_type = \${$self->{CREATE_TYPE}}; + my $found_type = \${$self->{FOUND_TYPE}}; + my $preprocessor_condition = \${$self->{PREPROCESSOR_CONDITION}}; + + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; local $_ = $$refcurrent; my $line = $$refline; my $column = $$refcolumn; + my $type; + if (!$self->_parse_c("typedef", \$_, \$line, \$column)) { return 0; } - my ($kind, $name, @field_type_names, @field_names, @names); - my ($linkage, $type_name); - if ($self->parse_c_enum(\$_, \$line, \$column)) -{ - # Nothing to do - } - elsif ($self->parse_c_struct_union(\$_, \$line, \$column, - \$kind, \$name, \@field_type_names, \@field_names, \@names)) + my $finished = 0; + + if ($finished) { + # Nothing + } elsif ($self->parse_c_enum(\$_, \$line, \$column)) { + $finished = 1; + } + + my $kind; + my $_name; + my @field_type_names; + my @field_names; + my @names; + if ($finished) { + # Nothing + } elsif ($self->parse_c_struct_union(\$_, \$line, \$column, + \$kind, \$_name, \@field_type_names, \@field_names, \@names)) { my $base_name; - foreach my $_name (@names) + foreach my $name (@names) { - if ($_name =~ /^\w+$/) + if ($name =~ /^\w+$/) { - $base_name = $_name; + $base_name = $name; last; } } - $base_name="$kind $name" if (!defined $base_name and defined $name); + $base_name="$kind $_name" if (!defined $base_name and defined $_name); $base_name=$kind if (!defined $base_name); - foreach my $_name (@names) { - if ($_name =~ /^\w+$/) { - my $type = $self->{CREATE_TYPE}(); + foreach my $name (@names) { + if ($name =~ /^\w+$/) { + my $type = &$$create_type(); $type->kind($kind); - $type->_name($name); - $type->name($_name); + $type->_name($_name); + $type->name($name); $type->field_type_names([@field_type_names]); $type->field_names([@field_names]); - $self->{FOUND_TYPE}($type); - } elsif ($_name =~ /^(\*+)\s*(?:RESTRICTED_POINTER\s+)?(\w+)$/) { + &$$found_type($type); + } elsif ($name =~ /^(\*+)\s*(?:RESTRICTED_POINTER\s+)?(\w+)$/) { my $type_name = "$base_name $1"; - $_name = $2; + $name = $2; - my $type = $self->{CREATE_TYPE}(); + my $type = &$$create_type(); $type->kind(""); - $type->name($_name); + $type->name($name); $type->field_type_names([$type_name]); $type->field_names([""]); - $self->{FOUND_TYPE}($type); + &$$found_type($type); } else { $self->_parse_c_error($_, $line, $column, "typedef 2"); } } + + $finished = 1; } - elsif ($self->parse_c_variable(\$_, \$line, \$column, \$linkage, \$type_name, \$name)) - { + + my $linkage; + my $type_name; + my $name; + if ($finished) { + # Nothing + } elsif ($self->parse_c_variable(\$_, \$line, \$column, \$linkage, \$type_name, \$name)) { $type_name =~ s/\s+/ /g; if(defined($type_name) && defined($name)) { - my $type = $self->{CREATE_TYPE}(); + my $type = &$$create_type(); if (length($name) == 0) { $self->_parse_c_error($_, $line, $column, "typedef"); @@ -1633,7 +1857,7 @@ sub parse_c_typedef($$$$) $type->field_type_names([$type_name]); $type->field_names([""]); - $self->{FOUND_TYPE}($type); + &$$found_type($type); } } else { $self->_parse_c_error($_, $line, $column, "typedef"); @@ -1646,9 +1870,21 @@ sub parse_c_typedef($$$$) return 1; } -sub parse_c_variable($$$$$$$) -{ - my ($self, $refcurrent, $refline, $refcolumn, $reflinkage, $reftype, $refname) = @_; +######################################################################## +# parse_c_variable + +sub parse_c_variable($$$$$$$) { + my $self = shift; + + my $found_variable = \${$self->{FOUND_VARIABLE}}; + + my $refcurrent = shift; + my $refline = shift; + my $refcolumn = shift; + + my $reflinkage = shift; + my $reftype = shift; + my $refname = shift; local $_ = $$refcurrent; my $line = $$refline; @@ -1688,120 +1924,126 @@ sub parse_c_variable($$$$$$$) } } - return 0 if(/^$/); + my $finished = 0; - finished: while (1) - { - if (s/^(enum\s+|interface\s+|struct\s+|union\s+)((?:MSVCRT|WS)\(\s*\w+\s*\)|\w+)?\s*\{\s*//s) { - my $kind = $1; - my $_name = $2; - $self->_update_c_position($&, \$line, \$column); - - if(defined($_name)) { - $type = "$kind $_name { }"; - } else { - $type = "$kind { }"; - } + if($finished) { + # Nothing + } elsif(/^$/) { + return 0; + } elsif (s/^(enum\s+|interface\s+|struct\s+|union\s+)((?:MSVCRT|WS)\(\s*\w+\s*\)|\w+)?\s*\{\s*//s) { + my $kind = $1; + my $_name = $2; + $self->_update_c_position($&, \$line, \$column); - last finished; - } elsif(s/^((?:enum\s+|interface\s+|struct\s+|union\s+)?\w+\b(?:\s+DECLSPEC_ALIGN\(.*?\)|\s*(?:const\s*|volatile\s*)?\*)*)\s*(\w+)\s*(\[.*?\]$|:\s*(\d+)$|\{)?//s) { - $type = "$sign$1"; - $name = $2; - - if (defined($3)) { - my $bits = $4; - local $_ = $3; - if (/^\[/) { - $type .= $_; - } elsif (/^:/) { - $type .= ":$bits"; - } elsif (/^\{/) { - # Nothing - } - } + if(defined($_name)) { + $type = "$kind $_name { }"; + } else { + $type = "$kind { }"; + } - $type = $self->_format_c_type($type); - - last finished; - } elsif(s/^((?:enum\s+|interface\s+|struct\s+|union\s+)?\w+\b(?:\s*\*)*)\s*:\s*(\d+)$//s) { - $type = "$sign$1:$2"; - $name = ""; - $type = $self->_format_c_type($type); - - last finished; - } elsif(s/^((?:enum\s+|interface\s+|struct\s+|union\s+)?\w+\b(?:\s*\*)*\s*\(\s*(?:$CALL_CONVENTION)?(?:\s*\*)*)\s*(\w+)\s*(\)\s*\(.*?\))$//s) { - $type = $self->_format_c_type("$sign$1$3"); - $name = $2; - - last finished; - } elsif($self->_parse_c('DEFINE_GUID', \$_, \$line, \$column, \$match)) { # Windows specific - $type = $match; - last finished; - } else { - $self->_parse_c_warning($_, $line, $column, "variable", "'$_'"); - last finished; - } + $finished = 1; + } elsif(s/^((?:enum\s+|interface\s+|struct\s+|union\s+)?\w+\b(?:\s+DECLSPEC_ALIGN\(.*?\)|\s*(?:const\s*|volatile\s*)?\*)*)\s*(\w+)\s*(\[.*?\]$|:\s*(\d+)$|\{)?//s) { + $type = "$sign$1"; + $name = $2; + + if (defined($3)) { + my $bits = $4; + local $_ = $3; + if (/^\[/) { + $type .= $_; + } elsif (/^:/) { + $type .= ":$bits"; + } elsif (/^\{/) { + # Nothing + } + } - if($self->_parse_c('SEQ_DEFINEBUF', \$_, \$line, \$column, \$match)) { # Linux specific - $type = $match; - last finished; - } elsif($self->_parse_c('DEFINE_REGS_ENTRYPOINT_\w+|DPQ_DECL_\w+|HANDLER_DEF|IX86_ONLY', # Wine specific - \$_, \$line, \$column, \$match)) - { - $type = $match; - last finished; - } elsif($self->_parse_c('(?:struct\s+)?ICOM_VTABLE\s*\(\w+\)', \$_, \$line, \$column, \$match)) { - $type = $match; - last finished; - } elsif(s/^(enum|interface|struct|union)(?:\s+(\w+))?\s*\{.*?\}\s*//s) { - my $kind = $1; - my $_name = $2; - $self->_update_c_position($&, \$line, \$column); - - if(defined($_name)) { - $type = "struct $_name { }"; - } else { - $type = "struct { }"; - } - } elsif(s/^((?:enum\s+|interface\s+|struct\s+|union\s+)?\w+)\s*(?:\*\s*)*//s) { - $type = $&; - $type =~ s/\s//g; - } else { - return 0; - } + $type = $self->_format_c_type($type); - # $output->write("*** $type: '$_'\n"); + $finished = 1; + } elsif(s/^((?:enum\s+|interface\s+|struct\s+|union\s+)?\w+\b(?:\s*\*)*)\s*:\s*(\d+)$//s) { + $type = "$sign$1:$2"; + $name = ""; + $type = $self->_format_c_type($type); - # $self->_parse_c_warning($_, $line, $column, "variable2", ""); + $finished = 1; + } elsif(s/^((?:enum\s+|interface\s+|struct\s+|union\s+)?\w+\b(?:\s*\*)*\s*\(\s*(?:$CALL_CONVENTION)?(?:\s*\*)*)\s*(\w+)\s*(\)\s*\(.*?\))$//s) { + $type = $self->_format_c_type("$sign$1$3"); + $name = $2; - if(s/^WINAPI\s*//) { - $self->_update_c_position($&, \$line, \$column); - } + $finished = 1; + } elsif($self->_parse_c('DEFINE_GUID', \$_, \$line, \$column, \$match)) { # Windows specific + $type = $match; + $finished = 1; + } else { + $self->_parse_c_warning($_, $line, $column, "variable", "'$_'"); + $finished = 1; + } - if(s/^(\((?:$CALL_CONVENTION)?\s*\*?\s*(?:$CALL_CONVENTION)?\w+\s*(?:\[[^\]]*\]\s*)*\))\s*\(//) { - $self->_update_c_position($&, \$line, \$column); + if($finished) { + # Nothing + } elsif($self->_parse_c('SEQ_DEFINEBUF', \$_, \$line, \$column, \$match)) { # Linux specific + $type = $match; + $finished = 1; + } elsif($self->_parse_c('DEFINE_REGS_ENTRYPOINT_\w+|DPQ_DECL_\w+|HANDLER_DEF|IX86_ONLY', # Wine specific + \$_, \$line, \$column, \$match)) + { + $type = $match; + $finished = 1; + } elsif($self->_parse_c('(?:struct\s+)?ICOM_VTABLE\s*\(\w+\)', \$_, \$line, \$column, \$match)) { + $type = $match; + $finished = 1; + } elsif(s/^(enum|interface|struct|union)(?:\s+(\w+))?\s*\{.*?\}\s*//s) { + my $kind = $1; + my $_name = $2; + $self->_update_c_position($&, \$line, \$column); + + if(defined($_name)) { + $type = "struct $_name { }"; + } else { + $type = "struct { }"; + } + } elsif(s/^((?:enum\s+|interface\s+|struct\s+|union\s+)?\w+)\s*(?:\*\s*)*//s) { + $type = $&; + $type =~ s/\s//g; + } else { + return 0; + } - $name = $1; - $name =~ s/\s//g; + # $output->write("*** $type: '$_'\n"); - $self->_parse_c_until_one_of("\\)", \$_, \$line, \$column); - if(s/^\)//) { $column++; } - $self->_parse_c_until_one_of("\\S", \$_, \$line, \$column); + # $self->_parse_c_warning($_, $line, $column, "variable2", ""); - if(!s/^(?:=\s*|,\s*|$)//) { - return 0; - } - } elsif(s/^(?:\*\s*)*(?:const\s+|volatile\s+)?(\w+)\s*(?:\[[^\]]*\]\s*)*\s*(?:=\s*|,\s*|$)//) { - $self->_update_c_position($&, \$line, \$column); - - $name = $1; - $name =~ s/\s//g; - } elsif(/^$/) { - $name = ""; - } else { - return 0; - } - last finished; + if($finished) { + # Nothing + } elsif(s/^WINAPI\s*//) { + $self->_update_c_position($&, \$line, \$column); + } + + if($finished) { + # Nothing + } elsif(s/^(\((?:$CALL_CONVENTION)?\s*\*?\s*(?:$CALL_CONVENTION)?\w+\s*(?:\[[^\]]*\]\s*)*\))\s*\(//) { + $self->_update_c_position($&, \$line, \$column); + + $name = $1; + $name =~ s/\s//g; + + $self->_parse_c_until_one_of("\\)", \$_, \$line, \$column); + if(s/^\)//) { $column++; } + $self->_parse_c_until_one_of("\\S", \$_, \$line, \$column); + + if(!s/^(?:=\s*|,\s*|$)//) { + return 0; + } + } elsif(s/^(?:\*\s*)*(?:const\s+|volatile\s+)?(\w+)\s*(?:\[[^\]]*\]\s*)*\s*(?:=\s*|,\s*|$)//) { + $self->_update_c_position($&, \$line, \$column); + + $name = $1; + $name =~ s/\s//g; + } elsif(/^$/) { + $name = ""; + } else { + return 0; } # $output->write("$type: $name: '$_'\n"); @@ -1814,7 +2056,10 @@ sub parse_c_variable($$$$$$$) $$reftype = $type; $$refname = $name; - $self->{FOUND_VARIABLE}($begin_line, $begin_column, $linkage, $type, $name); + if(&$$found_variable($begin_line, $begin_column, $linkage, $type, $name)) + { + # Nothing + } return 1; } diff --git a/tools/winapi/c_type.pm b/tools/winapi/c_type.pm index 4e54270625e..0cf81bb0f43 100644 --- a/tools/winapi/c_type.pm +++ b/tools/winapi/c_type.pm @@ -24,42 +24,57 @@ use output qw($output); sub _refresh($); -sub new($) -{ - my ($proto) = @_; +sub new($) { + my $proto = shift; my $class = ref($proto) || $proto; my $self = {}; - bless $self, $class; + bless ($self, $class); return $self; } +######################################################################## +# set_find_align_callback # -# Callback setters -# +sub set_find_align_callback($$) { + my $self = shift; -sub set_find_align_callback($$) -{ - my ($self, $find_align) = @_; - $self->{FIND_ALIGN} = $find_align; + my $find_align = \${$self->{FIND_ALIGN}}; + + $$find_align = shift; } -sub set_find_kind_callback($$) -{ - my ($self, $find_kind) = @_; - $self->{FIND_KIND} = $find_kind; +######################################################################## +# set_find_kind_callback +# +sub set_find_kind_callback($$) { + my $self = shift; + + my $find_kind = \${$self->{FIND_KIND}}; + + $$find_kind = shift; } -sub set_find_size_callback($$) -{ - my ($self, $find_size) = @_; - $self->{FIND_SIZE} = $find_size; +######################################################################## +# set_find_size_callback +# +sub set_find_size_callback($$) { + my $self = shift; + + my $find_size = \${$self->{FIND_SIZE}}; + + $$find_size = shift; } -sub set_find_count_callback($$) -{ - my ($self, $find_count) = @_; - $self->{FIND_COUNT} = $find_count; +######################################################################## +# set_find_count_callback +# +sub set_find_count_callback($$) { + my $self = shift; + + my $find_count = \${$self->{FIND_COUNT}}; + + $$find_count = shift; } @@ -69,60 +84,79 @@ sub set_find_count_callback($$) sub kind($;$) { - my ($self, $kind) = @_; - if (defined $kind) - { - $self->{KIND} = $kind; - $self->{DIRTY} = 1; + my $self = shift; + my $kind = \${$self->{KIND}}; + my $dirty = \${$self->{DIRTY}}; + + local $_ = shift; + + if(defined($_)) { $$kind = $_; $$dirty = 1; } + + if (!defined($$kind)) { + $self->_refresh(); } - $self->_refresh() if (!defined $self->{KIND}); - return $self->{KIND}; + + return $$kind; } sub _name($;$) { - my ($self, $_name) = @_; - if (defined $_name) - { - $self->{_NAME} = $_name; - $self->{DIRTY} = 1; - } - return $self->{_NAME}; + my $self = shift; + my $_name = \${$self->{_NAME}}; + my $dirty = \${$self->{DIRTY}}; + + local $_ = shift; + + if(defined($_)) { $$_name = $_; $$dirty = 1; } + + return $$_name; } sub name($;$) { - my ($self, $name) = @_; - if (defined $name) - { - $self->{NAME} = $name; - $self->{DIRTY} = 1; + my $self = shift; + my $name = \${$self->{NAME}}; + my $dirty = \${$self->{DIRTY}}; + + local $_ = shift; + + if(defined($_)) { $$name = $_; $$dirty = 1; } + + if($$name) { + return $$name; + } else { + my $kind = \${$self->{KIND}}; + my $_name = \${$self->{_NAME}}; + + return "$$kind $$_name"; } - return $self->{NAME} if ($self->{NAME}); - return "$self->{KIND} $self->{_NAME}"; } sub pack($;$) { - my ($self, $pack) = @_; - if (defined $pack) - { - $self->{PACK} = $pack; - $self->{DIRTY} = 1; - } - return $self->{PACK}; + my $self = shift; + my $pack = \${$self->{PACK}}; + my $dirty = \${$self->{DIRTY}}; + + local $_ = shift; + + if(defined($_)) { $$pack = $_; $$dirty = 1; } + + return $$pack; } -sub align($) -{ - my ($self) = @_; +sub align($) { + my $self = shift; + + my $align = \${$self->{ALIGN}}; + $self->_refresh(); - return $self->{ALIGN}; + + return $$align; } -sub fields($) -{ - my ($self) = @_; +sub fields($) { + my $self = shift; my $count = $self->field_count; @@ -134,73 +168,107 @@ sub fields($) return @fields; } -sub field_base_sizes($) -{ - my ($self) = @_; +sub field_base_sizes($) { + my $self = shift; + my $field_base_sizes = \${$self->{FIELD_BASE_SIZES}}; + $self->_refresh(); - return $self->{FIELD_BASE_SIZES}; + + return $$field_base_sizes; } -sub field_aligns($) -{ - my ($self) = @_; +sub field_aligns($) { + my $self = shift; + my $field_aligns = \${$self->{FIELD_ALIGNS}}; + $self->_refresh(); - return $self->{FIELD_ALIGNS}; + + return $$field_aligns; } -sub field_count($) -{ - my ($self) = @_; - return scalar @{$self->{FIELD_TYPE_NAMES}}; +sub field_count($) { + my $self = shift; + my $field_type_names = \${$self->{FIELD_TYPE_NAMES}}; + + my @field_type_names = @{$$field_type_names}; + my $count = scalar(@field_type_names); + + return $count; } sub field_names($;$) { - my ($self, $field_names) = @_; - if (defined $field_names) - { - $self->{FIELD_NAMES} = $field_names; - $self->{DIRTY} = 1; - } - return $self->{FIELD_NAMES}; + my $self = shift; + my $field_names = \${$self->{FIELD_NAMES}}; + my $dirty = \${$self->{DIRTY}}; + + local $_ = shift; + + if(defined($_)) { $$field_names = $_; $$dirty = 1; } + + return $$field_names; } -sub field_offsets($) -{ - my ($self) = @_; +sub field_offsets($) { + my $self = shift; + my $field_offsets = \${$self->{FIELD_OFFSETS}}; + $self->_refresh(); - return $self->{FIELD_OFFSETS}; + + return $$field_offsets; } -sub field_sizes($) -{ - my ($self) = @_; +sub field_sizes($) { + my $self = shift; + my $field_sizes = \${$self->{FIELD_SIZES}}; + $self->_refresh(); - return $self->{FIELD_SIZES}; + + return $$field_sizes; } sub field_type_names($;$) { - my ($self, $field_type_names) = @_; - if (defined $field_type_names) - { - $self->{FIELD_TYPE_NAMES} = $field_type_names; - $self->{DIRTY} = 1; - } - return $self->{FIELD_TYPE_NAMES}; + my $self = shift; + my $field_type_names = \${$self->{FIELD_TYPE_NAMES}}; + my $dirty = \${$self->{DIRTY}}; + + local $_ = shift; + + if(defined($_)) { $$field_type_names = $_; $$dirty = 1; } + + return $$field_type_names; } -sub size($) -{ - my ($self) = @_; +sub size($) { + my $self = shift; + + my $size = \${$self->{SIZE}}; + $self->_refresh(); - return $self->{SIZE}; + + return $$size; } -sub _refresh($) -{ - my ($self) = @_; - return if (!$self->{DIRTY}); +sub _refresh($) { + my $self = shift; + + my $dirty = \${$self->{DIRTY}}; + + return if !$$dirty; + + my $find_align = \${$self->{FIND_ALIGN}}; + my $find_kind = \${$self->{FIND_KIND}}; + my $find_size = \${$self->{FIND_SIZE}}; + my $find_count = \${$self->{FIND_COUNT}}; + + my $align = \${$self->{ALIGN}}; + my $kind = \${$self->{KIND}}; + my $size = \${$self->{SIZE}}; + my $field_aligns = \${$self->{FIELD_ALIGNS}}; + my $field_base_sizes = \${$self->{FIELD_BASE_SIZES}}; + my $field_offsets = \${$self->{FIELD_OFFSETS}}; + my $field_sizes = \${$self->{FIELD_SIZES}}; my $pack = $self->pack; $pack = 8 if !defined($pack); @@ -212,8 +280,7 @@ sub _refresh($) my $bitfield_bits = 0; my $n = 0; - foreach my $field ($self->fields()) - { + foreach my $field ($self->fields) { my $type_name = $field->type_name; my $bits; @@ -228,18 +295,17 @@ sub _refresh($) { $declspec_align=$1; } - my $base_size = $self->{FIND_SIZE}($type_name); + my $base_size = &$$find_size($type_name); my $type_size=$base_size; if (defined $count) { - $count=$self->{FIND_COUNT}($count) if ($count !~ /^\d+$/); + $count=&$$find_count($count) if ($count !~ /^\d+$/); if (!defined $count) { $type_size=undef; } else { - print STDERR "$type_name -> type_size=undef, count=$count\n" if (!defined $type_size); $type_size *= int($count); } } @@ -262,35 +328,35 @@ sub _refresh($) } } - $self->{ALIGN} = $self->{FIND_ALIGN}($type_name); - $self->{ALIGN} = $declspec_align if (defined $declspec_align); + $$align = &$$find_align($type_name); + $$align=$declspec_align if (defined $declspec_align); - if (defined $self->{ALIGN}) + if (defined $$align) { - $self->{ALIGN} = $pack if ($self->{ALIGN} > $pack); - $max_field_align = $self->{ALIGN} if ($self->{ALIGN}) > $max_field_align; + $$align = $pack if $$align > $pack; + $max_field_align = $$align if $$align > $max_field_align; - if ($offset % $self->{ALIGN} != 0) { - $offset = (int($offset / $self->{ALIGN}) + 1) * $self->{ALIGN}; + if ($offset % $$align != 0) { + $offset = (int($offset / $$align) + 1) * $$align; } } - if ($self->{KIND} !~ /^(?:struct|union)$/) + if ($$kind !~ /^(?:struct|union)$/) { - $self->{KIND} = $self->{FIND_KIND}($type_name) || ""; + $$kind = &$$find_kind($type_name) || ""; } if (!$type_size) { - $self->{ALIGN} = undef; - $self->{SIZE} = undef; + $$align = undef; + $$size = undef; return; } - $self->{FIELD_ALIGNS}->[$n] = $self->{ALIGN}; - $self->{FIELD_BASE_SIZES}->[$n] = $base_size; - $self->{FIELD_OFFSETS}->[$n] = $offset; - $self->{FIELD_SIZES}->[$n] = $type_size; + $$$field_aligns[$n] = $$align; + $$$field_base_sizes[$n] = $base_size; + $$$field_offsets[$n] = $offset; + $$$field_sizes[$n] = $type_size; $offset += $type_size; if ($bits) @@ -301,66 +367,94 @@ sub _refresh($) $n++; } - $self->{ALIGN} = $pack; - $self->{ALIGN} = $max_field_align if ($max_field_align < $pack); + $$align = $pack; + $$align = $max_field_align if $max_field_align < $pack; - $self->{SIZE} = $offset; - if ($self->{KIND} =~ /^(?:struct|union)$/) { - if ($self->{SIZE} % $self->{ALIGN} != 0) { - $self->{SIZE} = (int($self->{SIZE} / $self->{ALIGN}) + 1) * $self->{ALIGN}; + $$size = $offset; + if ($$kind =~ /^(?:struct|union)$/) { + if ($$size % $$align != 0) { + $$size = (int($$size / $$align) + 1) * $$align; } } - $self->{DIRTY} = 0; + $$dirty = 0; } package c_type_field; -sub new($$$) -{ - my ($proto, $type, $number) = @_; +sub new($$$) { + my $proto = shift; my $class = ref($proto) || $proto; - my $self = {TYPE=> $type, - NUMBER => $number - }; - bless $self, $class; + my $self = {}; + bless ($self, $class); + + my $type = \${$self->{TYPE}}; + my $number = \${$self->{NUMBER}}; + + $$type = shift; + $$number = shift; + return $self; } -sub align($) -{ - my ($self) = @_; - return $self->{TYPE}->field_aligns()->[$self->{NUMBER}]; +sub align($) { + my $self = shift; + my $type = \${$self->{TYPE}}; + my $number = \${$self->{NUMBER}}; + + my $field_aligns = $$type->field_aligns; + + return $$field_aligns[$$number]; } -sub base_size($) -{ - my ($self) = @_; - return $self->{TYPE}->field_base_sizes()->[$self->{NUMBER}]; +sub base_size($) { + my $self = shift; + my $type = \${$self->{TYPE}}; + my $number = \${$self->{NUMBER}}; + + my $field_base_sizes = $$type->field_base_sizes; + + return $$field_base_sizes[$$number]; } -sub name($) -{ - my ($self) = @_; - return $self->{TYPE}->field_names()->[$self->{NUMBER}]; +sub name($) { + my $self = shift; + my $type = \${$self->{TYPE}}; + my $number = \${$self->{NUMBER}}; + + my $field_names = $$type->field_names; + + return $$field_names[$$number]; } -sub offset($) -{ - my ($self) = @_; - return $self->{TYPE}->field_offsets()->[$self->{NUMBER}]; +sub offset($) { + my $self = shift; + my $type = \${$self->{TYPE}}; + my $number = \${$self->{NUMBER}}; + + my $field_offsets = $$type->field_offsets; + + return $$field_offsets[$$number]; } -sub size($) -{ - my ($self) = @_; - return $self->{TYPE}->field_sizes()->[$self->{NUMBER}]; +sub size($) { + my $self = shift; + my $type = \${$self->{TYPE}}; + my $number = \${$self->{NUMBER}}; + + my $field_sizes = $$type->field_sizes; + + return $$field_sizes[$$number]; } -sub type_name($) -{ - my ($self) = @_; - return $self->{TYPE}->field_type_names()->[$self->{NUMBER}]; +sub type_name($) { + my $self = shift; + my $type = \${$self->{TYPE}}; + my $number = \${$self->{NUMBER}}; + + my $field_type_names = $$type->field_type_names; + + return $$field_type_names[$$number]; } 1; diff --git a/tools/wine.inf.in b/tools/wine.inf.in index 050d3e53cf2..4d2999ec86b 100644 --- a/tools/wine.inf.in +++ b/tools/wine.inf.in @@ -403,7 +403,7 @@ HKLM,%CurrentVersion%,"RegisteredOwner",2,"" HKLM,%CurrentVersion%\Controls Folder\PowerCfg,"DiskSpinDownMax",,"3600" HKLM,%CurrentVersion%\Controls Folder\PowerCfg,"DiskSpinDownMin",,"3" HKLM,%CurrentVersion%\Controls Folder\PowerCfg,"LastID",,"5" -HKLM,%CurrentVersion%\RunServices,"winemenubuilder",2,"winemenubuilder -a -r" +HKLM,%CurrentVersion%\Run,"winemenubuilder",2,"winemenubuilder -a" HKLM,%CurrentVersion%\Setup,"BootDir",,"%30%" HKLM,%CurrentVersion%\Setup,"SharedDir",,"%25%" HKLM,%CurrentVersion%\Uninstall,,,"" @@ -2427,10 +2427,7 @@ HKLM,%CurrentVersion%\Telephony\Country List\998,"SameAreaRule",,"G" 11,,rsaenh.dll,1 11,,shdocvw.dll,1 11,,urlmon.dll,1 -11,,wbemprox.dll,1 -11,,windowscodecs.dll,1 11,,wintrust.dll,1 -11,,wmiutils.dll,1 11,,wuapi.dll,1 [FakeDllsSection] diff --git a/tools/winebuild/main.c b/tools/winebuild/main.c index 77cfc451cb3..941923113db 100644 --- a/tools/winebuild/main.c +++ b/tools/winebuild/main.c @@ -244,7 +244,7 @@ static const char usage_str[] = " --def Build a .def file from a .spec file\n" " --exe Build a .c file for an executable\n" " --relay16 Build the 16-bit relay assembly routines\n" -" --relay32 Build the 32-bit relay assembly routines\n" +" --relay32 Build the 32-bit relay assembly routines\n\n" " --resources Build a .o file for the resource files\n\n" "The mode options are mutually exclusive; you must specify one and only one.\n\n"; diff --git a/tools/winebuild/res16.c b/tools/winebuild/res16.c index 8a26ae27906..a957ca857fa 100644 --- a/tools/winebuild/res16.c +++ b/tools/winebuild/res16.c @@ -168,7 +168,7 @@ void load_res16_file( const char *name, DLLSPEC *spec ) void *base; struct stat st; - if ((fd = open( name, O_RDONLY | O_BINARY )) == -1) fatal_perror( "Cannot open %s", name ); + if ((fd = open( name, O_RDONLY )) == -1) fatal_perror( "Cannot open %s", name ); if ((fstat( fd, &st ) == -1)) fatal_perror( "Cannot stat %s", name ); if (!st.st_size) fatal_error( "%s is an empty file\n", name ); #ifdef HAVE_MMAP diff --git a/tools/winebuild/res32.c b/tools/winebuild/res32.c index d03d16f7f17..ed902bb1d4a 100644 --- a/tools/winebuild/res32.c +++ b/tools/winebuild/res32.c @@ -218,28 +218,6 @@ static void put_string( const struct string_id *str ) } } -static void dump_res_data( const struct resource *res ) -{ - unsigned int i = 0; - unsigned int size = (res->data_size + 3) & ~3; - - if (!size) return; - - file_pos = res->data; - file_end = (const unsigned char *)res->data + size; - - output( "\t.long " ); - while (size > 4) - { - if ((i++ % 16) == 15) output( "0x%08x\n\t.long ", get_dword() ); - else output( "0x%08x,", get_dword() ); - size -= 4; - } - output( "0x%08x\n", get_dword() ); - size -= 4; - assert( file_pos == file_end ); -} - /* check the file header */ /* all values must be zero except header size */ static int check_header(void) @@ -291,7 +269,7 @@ int load_res32_file( const char *name, DLLSPEC *spec ) void *base; struct stat st; - if ((fd = open( name, O_RDONLY | O_BINARY )) == -1) fatal_perror( "Cannot open %s", name ); + if ((fd = open( name, O_RDONLY )) == -1) fatal_perror( "Cannot open %s", name ); if ((fstat( fd, &st ) == -1)) fatal_perror( "Cannot stat %s", name ); if (!st.st_size) fatal_error( "%s is an empty file\n", name ); #ifdef HAVE_MMAP @@ -537,7 +515,7 @@ void output_resources( DLLSPEC *spec ) { output( "\n\t.align %d\n", get_alignment(get_ptr_size()) ); output( ".L__wine_spec_res_%d:\n", i ); - dump_res_data( res ); + dump_bytes( res->data, (res->data_size + 3) & ~3 ); } output( ".L__wine_spec_resources_end:\n" ); output( "\t.byte 0\n" ); @@ -563,7 +541,8 @@ void output_res_o_file( DLLSPEC *spec ) { unsigned int i, total_size; unsigned char *data; - char *res_file = NULL; + char *res_file, *cmd; + const char *prog; int fd, err; if (!spec->nb_resources) fatal_error( "--resources mode needs at least one resource file as input\n" ); @@ -599,7 +578,7 @@ void output_res_o_file( DLLSPEC *spec ) unsigned int header_size = get_resource_header_size( &spec->resources[i] ); put_dword( spec->resources[i].data_size ); - put_dword( (header_size + 3) & ~3 ); + put_dword( header_size ); put_string( &spec->resources[i].type ); put_string( &spec->resources[i].name ); if ((unsigned long)file_out_pos & 2) put_word( 0 ); @@ -614,32 +593,20 @@ void output_res_o_file( DLLSPEC *spec ) } assert( file_out_pos == file_out_end ); - /* if the output file name is a .res too, don't run the results through windres */ - if (strendswith( output_file_name, ".res")) - { - if ((fd = open( output_file_name, O_WRONLY|O_CREAT|O_TRUNC, 0666 )) == -1) - fatal_error( "Cannot create %s\n", output_file_name ); - } - else - { - res_file = get_temp_file_name( output_file_name, ".res" ); - if ((fd = open( res_file, O_WRONLY|O_CREAT|O_TRUNC, 0600 )) == -1) - fatal_error( "Cannot create %s\n", res_file ); - } + res_file = get_temp_file_name( output_file_name, ".res" ); + if ((fd = open( res_file, O_WRONLY|O_CREAT|O_TRUNC, 0600 )) == -1) + fatal_error( "Cannot create %s\n", res_file ); if (write( fd, data, total_size ) != total_size) fatal_error( "Error writing to %s\n", res_file ); close( fd ); free( data ); - if (res_file) - { - const char *prog = get_windres_command(); - char *cmd = xmalloc( strlen(prog) + strlen(res_file) + strlen(output_file_name) + 9 ); - sprintf( cmd, "%s -i %s -o %s", prog, res_file, output_file_name ); - if (verbose) fprintf( stderr, "%s\n", cmd ); - err = system( cmd ); - if (err) fatal_error( "%s failed with status %d\n", prog, err ); - free( cmd ); - } + prog = get_windres_command(); + cmd = xmalloc( strlen(prog) + strlen(res_file) + strlen(output_file_name) + 9 ); + sprintf( cmd, "%s -i %s -o %s", prog, res_file, output_file_name ); + if (verbose) fprintf( stderr, "%s\n", cmd ); + err = system( cmd ); + if (err) fatal_error( "%s failed with status %d\n", prog, err ); + free( cmd ); output_file_name = NULL; /* so we don't try to assemble it */ } diff --git a/tools/winebuild/spec16.c b/tools/winebuild/spec16.c index 679c4de39c9..4bccd0c860b 100644 --- a/tools/winebuild/spec16.c +++ b/tools/winebuild/spec16.c @@ -887,6 +887,7 @@ void output_spec16_file( DLLSPEC *spec16 ) output_stubs( spec16 ); output_exports( spec32 ); output_imports( spec16 ); + output_resources( spec16 ); if (spec16->main_module) { output( "\n\t%s\n", get_asm_string_section() ); diff --git a/tools/winedump/pdb.c b/tools/winedump/pdb.c index 24ca4e42788..421711350f0 100644 --- a/tools/winedump/pdb.c +++ b/tools/winedump/pdb.c @@ -456,7 +456,6 @@ static void pdb_dump_types(struct pdb_reader* reader) case 19951122: case 19961031: /* VC 5.0 / 6.0 */ case 19990903: /* VC 7.0 */ - case 20040203: /* VC 8.0 */ break; default: printf("-Unknown type info version %d\n", types->version); diff --git a/tools/winegcc/winegcc.c b/tools/winegcc/winegcc.c index b33763086e9..c2fb4f3d491 100644 --- a/tools/winegcc/winegcc.c +++ b/tools/winegcc/winegcc.c @@ -830,20 +830,18 @@ static void build(struct options* opts) for ( j = 0 ; j < opts->winebuild_args->size ; j++ ) strarray_add(spec_args, opts->winebuild_args->base[j]); - /* add resource files */ - for ( j = 0; j < files->size; j++ ) - if (files->base[j][1] == 'r') strarray_add(spec_args, files->base[j]); - - /* add other files */ - strarray_add(spec_args, "--"); for ( j = 0; j < files->size; j++ ) { + const char* name = files->base[j] + 2; switch(files->base[j][1]) { + case 'r': + strarray_add(spec_args, files->base[j]); + break; case 'd': case 'a': case 'o': - strarray_add(spec_args, files->base[j] + 2); + strarray_add(spec_args, name); break; } } diff --git a/tools/wmc/mcl.c b/tools/wmc/mcl.c index 7be41d51925..be016914c77 100644 --- a/tools/wmc/mcl.c +++ b/tools/wmc/mcl.c @@ -155,7 +155,7 @@ void set_codepage(int cp) { codepage = cp; codepage_def = find_codepage(codepage); - if(!codepage_def && codepage != CP_UTF8) + if(!codepage_def) xyyerror("Codepage %d not found; cannot process\n", codepage); } @@ -200,10 +200,8 @@ try_again: xyyerror(err_fatalread); else if(!cptr) return 0; - if (codepage_def) - n = wine_cp_mbstowcs(codepage_def, 0, xlatebuffer, strlen(xlatebuffer)+1, inputbuffer, INPUTBUFFER_SIZE); - else - n = wine_utf8_mbstowcs(0, xlatebuffer, strlen(xlatebuffer)+1, inputbuffer, INPUTBUFFER_SIZE); + assert(codepage_def != NULL); + n = wine_cp_mbstowcs(codepage_def, 0, xlatebuffer, strlen(xlatebuffer)+1, inputbuffer, INPUTBUFFER_SIZE); if(n < 0) internal_error(__FILE__, __LINE__, "Could not translate to unicode (%d)\n", n); if(n <= 1) diff --git a/tools/wmc/mcy.y b/tools/wmc/mcy.y index 5de67c943c8..2887df56b6d 100644 --- a/tools/wmc/mcy.y +++ b/tools/wmc/mcy.y @@ -251,12 +251,12 @@ cmaps : cmap ; cmap : clan '=' tNUMBER ':' tNUMBER { - static const char err_nocp[] = "Codepage %d not builtin; cannot convert\n"; + static const char err_nocp[] = "Codepage %d not builtin; cannot convert"; if(find_cpxlat($1)) xyyerror("Codepage translation already defined for language 0x%x\n", $1); - if($3 && $3 != CP_UTF8 && !find_codepage($3)) + if($3 && !find_codepage($3)) xyyerror(err_nocp, $3); - if($5 && $5 != CP_UTF8 && !find_codepage($5)) + if($5 && !find_codepage($5)) xyyerror(err_nocp, $5); add_cpxlat($1, $3, $5); } diff --git a/tools/wmc/write.c b/tools/wmc/write.c index 7f9784f8438..7df242466d3 100644 --- a/tools/wmc/write.c +++ b/tools/wmc/write.c @@ -100,17 +100,11 @@ static char *dup_u2c(int cp, const WCHAR *uc) int len; char *cptr; const union cptable *cpdef = find_codepage(cp); - - if(cpdef) - len = wine_cp_wcstombs(cpdef, 0, uc, unistrlen(uc)+1, NULL, 0, NULL, NULL); - else - len = wine_utf8_wcstombs(0, uc, unistrlen(uc)+1, NULL, 0); + if(!cpdef) + internal_error(__FILE__, __LINE__, "Codepage %d not found (vanished?)\n", cp); + len = wine_cp_wcstombs(cpdef, 0, uc, unistrlen(uc)+1, NULL, 0, NULL, NULL); cptr = xmalloc(len); - if (cpdef) - len = wine_cp_wcstombs(cpdef, 0, uc, unistrlen(uc)+1, cptr, len, NULL, NULL); - else - len = wine_utf8_wcstombs(0, uc, unistrlen(uc)+1, cptr, len); - if (len < 0) + if((len = wine_cp_wcstombs(cpdef, 0, uc, unistrlen(uc)+1, cptr, len, NULL, NULL)) < 0) internal_error(__FILE__, __LINE__, "Buffer overflow? code %d\n", len); return cptr; } @@ -391,18 +385,11 @@ static char *make_string(WCHAR *uc, int len, int codepage) int mlen; const union cptable *cpdef = find_codepage(codepage); - if (cpdef) - mlen = wine_cp_wcstombs(cpdef, 0, uc, unistrlen(uc)+1, NULL, 0, NULL, NULL); - else - mlen = wine_utf8_wcstombs(0, uc, unistrlen(uc)+1, NULL, 0); + assert(cpdef != NULL); + mlen = wine_cp_wcstombs(cpdef, 0, uc, unistrlen(uc)+1, NULL, 0, NULL, NULL); cc = tmp = xmalloc(mlen); - if (cpdef) { - if((i = wine_cp_wcstombs(cpdef, 0, uc, unistrlen(uc)+1, tmp, mlen, NULL, NULL)) < 0) - internal_error(__FILE__, __LINE__, "Buffer overflow? code %d\n", i); - } else { - if((i = wine_utf8_wcstombs(0, uc, unistrlen(uc)+1, tmp, mlen)) < 0) - internal_error(__FILE__, __LINE__, "Buffer overflow? code %d\n", i); - } + if((i = wine_cp_wcstombs(cpdef, 0, uc, unistrlen(uc)+1, tmp, mlen, NULL, NULL)) < 0) + internal_error(__FILE__, __LINE__, "Buffer overflow? code %d\n", i); *cptr++ = ' '; *cptr++ = '"'; for(i = b = 0; i < len; i++, cc++) diff --git a/tools/wrc/parser.l b/tools/wrc/parser.l index cafa35ad587..bddc309554c 100644 --- a/tools/wrc/parser.l +++ b/tools/wrc/parser.l @@ -121,8 +121,6 @@ cident [a-zA-Z_][0-9a-zA-Z_]* /* Always update the current character position within a line */ #define YY_USER_ACTION char_number+=yyleng; wanted_id = want_id; want_id = 0; -#define YY_USER_INIT current_codepage = -1; - static void addcchar(char c); static void addwchar(WCHAR s); static string_t *get_buffered_cstring(void); @@ -573,7 +571,7 @@ L\" { } {ws}+ want_id = wanted_id; /* Eat whitespace */ -[ -~] return yytext[0]; +. return yytext[0]; <*>.|\n { /* Catch all rule to find any unmatched text */ @@ -582,11 +580,10 @@ L\" { line_number++; char_number = 1; } - parser_error("Unmatched text '%c' (0x%02x) YY_START=%d", - isprint((unsigned char)*yytext) ? *yytext : '.', *yytext, YY_START); + parser_warning("Unmatched text '%c' (0x%02x) YY_START=%d\n", + isprint(*yytext & 0xff) ? *yytext : '.', *yytext, YY_START); } -<> current_codepage = -1; yyterminate(); %% /* These dup functions copy the enclosed '\0' from diff --git a/tools/wrc/parser.y b/tools/wrc/parser.y index d9054751da1..512d27223f5 100644 --- a/tools/wrc/parser.y +++ b/tools/wrc/parser.y @@ -169,12 +169,12 @@ int want_nl = 0; /* Signal flex that we need the next newline */ int want_id = 0; /* Signal flex that we need the next identifier */ -static stringtable_t *tagstt; /* Stringtable tag. +stringtable_t *tagstt; /* Stringtable tag. * It is set while parsing a stringtable to one of * the stringtables in the sttres list or a new one * if the language was not parsed before. */ -static stringtable_t *sttres; /* Stringtable resources. This holds the list of +stringtable_t *sttres; /* Stringtable resources. This holds the list of * stringtables with different lanuages */ static int dont_want_id = 0; /* See language parsing for details */ @@ -358,7 +358,7 @@ static int rsrcid_to_token(int lookahead); resource_file : resources { - resource_t *rsc, *head; + resource_t *rsc; /* First add stringtables to the resource-list */ rsc = build_stt_resources(sttres); /* 'build_stt_resources' returns a head and $1 is a tail */ @@ -384,20 +384,8 @@ resource_file } else $1 = rsc; - - /* Final statements before were done */ - if ((head = get_resource_head($1)) != NULL) - { - if (resource_top) /* append to existing resources */ - { - resource_t *tail = resource_top; - while (tail->next) tail = tail->next; - tail->next = head; - head->prev = tail; - } - else resource_top = head; - } - sttres = NULL; + /* Final statement before were done */ + resource_top = get_resource_head($1); } ; diff --git a/tools/wrc/wrc.c b/tools/wrc/wrc.c index 6a856eb7f91..05bd3f8c65b 100644 --- a/tools/wrc/wrc.c +++ b/tools/wrc/wrc.c @@ -55,7 +55,7 @@ #endif static const char usage[] = - "Usage: wrc [options...] [infile[.rc|.res]]\n" + "Usage: wrc [options...] [infile[.rc|.res]] [outfile]\n" " -D id[=val] Define preprocessor identifier id=val\n" " -E Preprocess only\n" " -F target Ignored for compatibility with windres\n" @@ -132,7 +132,6 @@ int extensions = 1; /* * Language setting for resources (-l option) */ -static language_t *defaultlanguage; language_t *currentlanguage = NULL; /* @@ -175,42 +174,29 @@ int getopt (int argc, char *const *argv, const char *optstring); static void cleanup_files(void); static void segvhandler(int sig); -enum long_options_values -{ - LONG_OPT_NOSTDINC = 1, - LONG_OPT_TMPFILE, - LONG_OPT_NOTMPFILE, - LONG_OPT_PREPROCESSOR, - LONG_OPT_VERSION, - LONG_OPT_DEBUG, - LONG_OPT_ENDIANESS, - LONG_OPT_PEDANTIC, - LONG_OPT_VERIFY_TRANSL -}; - static const char short_options[] = "D:Ef:F:hi:I:J:l:o:O:rU:v"; static const struct option long_options[] = { - { "debug", 1, 0, LONG_OPT_DEBUG }, + { "debug", 1, 0, 6 }, { "define", 1, 0, 'D' }, - { "endianess", 1, 0, LONG_OPT_ENDIANESS }, + { "endianess", 1, 0, 7 }, { "help", 0, 0, 'h' }, { "include-dir", 1, 0, 'I' }, { "input", 1, 0, 'i' }, { "input-format", 1, 0, 'J' }, { "language", 1, 0, 'l' }, - { "no-use-temp-file", 0, 0, LONG_OPT_NOTMPFILE }, - { "nostdinc", 0, 0, LONG_OPT_NOSTDINC }, + { "no-use-temp-file", 0, 0, 3 }, + { "nostdinc", 0, 0, 1 }, { "output", 1, 0, 'o' }, { "output-format", 1, 0, 'O' }, - { "pedantic", 0, 0, LONG_OPT_PEDANTIC }, - { "preprocessor", 1, 0, LONG_OPT_PREPROCESSOR }, + { "pedantic", 0, 0, 8 }, + { "preprocessor", 1, 0, 4 }, { "target", 1, 0, 'F' }, { "undefine", 1, 0, 'U' }, - { "use-temp-file", 0, 0, LONG_OPT_TMPFILE }, + { "use-temp-file", 0, 0, 2 }, { "verbose", 0, 0, 'v' }, - { "verify-translations", 0, 0, LONG_OPT_VERIFY_TRANSL }, - { "version", 0, 0, LONG_OPT_VERSION }, + { "verify-translations", 0, 0, 9 }, + { "version", 0, 0, 5 }, { 0, 0, 0, 0 } }; @@ -246,71 +232,6 @@ static void exit_on_signal( int sig ) exit(1); /* this will call the atexit functions */ } -/* load a single input file */ -static int load_file( const char *input_name, const char *output_name ) -{ - int ret; - - /* Run the preprocessor on the input */ - if(!no_preprocess) - { - /* - * Preprocess the input to a temp-file, or stdout if - * no output was given. - */ - - chat("Starting preprocess\n"); - - if (!preprocess_only) - { - ret = wpp_parse_temp( input_name, output_name, &temp_name ); - } - else if (output_name) - { - FILE *output; - - if (!(output = fopen( output_name, "w" ))) - fatal_perror( "Could not open %s for writing", output_name ); - ret = wpp_parse( input_name, output ); - fclose( output ); - } - else - { - ret = wpp_parse( input_name, stdout ); - } - - if (ret) return ret; - - if(preprocess_only) - { - output_name = NULL; - exit(0); - } - - input_name = temp_name; - } - - /* Reset the language */ - currentlanguage = dup_language( defaultlanguage ); - - /* Go from .rc to .res */ - chat("Starting parse\n"); - - if(!(parser_in = fopen(input_name, "rb"))) - fatal_perror("Could not open %s for input", input_name); - - ret = parser_parse(); - fclose(parser_in); - if (temp_name) - { - unlink( temp_name ); - temp_name = NULL; - } - free( currentlanguage ); - return ret; -} - - int main(int argc,char *argv[]) { extern char* optarg; @@ -319,10 +240,9 @@ int main(int argc,char *argv[]) int opti = 0; int stdinc = 1; int lose = 0; - int nb_files = 0; + int ret; int i; int cmdlen; - char **files = xmalloc( argc * sizeof(*files) ); signal(SIGSEGV, segvhandler); signal( SIGTERM, exit_on_signal ); @@ -359,27 +279,27 @@ int main(int argc,char *argv[]) { switch(optc) { - case LONG_OPT_NOSTDINC: + case 1: stdinc = 0; break; - case LONG_OPT_TMPFILE: + case 2: if (debuglevel) warning("--use-temp-file option not yet supported, ignored.\n"); break; - case LONG_OPT_NOTMPFILE: + case 3: if (debuglevel) warning("--no-use-temp-file option not yet supported, ignored.\n"); break; - case LONG_OPT_PREPROCESSOR: + case 4: if (strcmp(optarg, "cat") == 0) no_preprocess = 1; else fprintf(stderr, "-P option not yet supported, ignored.\n"); break; - case LONG_OPT_VERSION: + case 5: printf(version_string); exit(0); break; - case LONG_OPT_DEBUG: + case 6: debuglevel = strtol(optarg, NULL, 0); break; - case LONG_OPT_ENDIANESS: + case 7: switch(optarg[0]) { case 'n': @@ -399,11 +319,11 @@ int main(int argc,char *argv[]) lose++; } break; - case LONG_OPT_PEDANTIC: + case 8: pedantic = 1; wpp_set_pedantic(1); break; - case LONG_OPT_VERIFY_TRANSL: + case 9: verify_translations_mode = 1; break; case 'D': @@ -419,7 +339,8 @@ int main(int argc,char *argv[]) printf(usage); exit(0); case 'i': - files[nb_files++] = optarg; + if (!input_name) input_name = strdup(optarg); + else error("Too many input files.\n"); break; case 'I': wpp_add_include_path(optarg); @@ -434,7 +355,7 @@ int main(int argc,char *argv[]) lan = strtol(optarg, NULL, 0); if (get_language_codepage(PRIMARYLANGID(lan), SUBLANGID(lan)) == -1) error("Language %04x is not supported\n", lan); - defaultlanguage = new_language(PRIMARYLANGID(lan), SUBLANGID(lan)); + currentlanguage = new_language(PRIMARYLANGID(lan), SUBLANGID(lan)); } break; case 'f': @@ -481,6 +402,20 @@ int main(int argc,char *argv[]) wpp_add_include_path(INCLUDEDIR"/msvcrt"); wpp_add_include_path(INCLUDEDIR"/windows"); } + + /* Check for input file on command-line */ + if(optind < argc) + { + if (!input_name) input_name = argv[optind++]; + else error("Too many input files.\n"); + } + + /* Check for output file on command-line */ + if(optind < argc) + { + if (!output_name) output_name = argv[optind++]; + else error("Too many output files.\n"); + } /* Kill io buffering when some kind of debuglevel is enabled */ if(debuglevel) @@ -497,23 +432,68 @@ int main(int argc,char *argv[]) (debuglevel & DEBUGLEVEL_PPMSG) != 0 ); /* Check if the user set a language, else set default */ - if(!defaultlanguage) - defaultlanguage = new_language(0, 0); + if(!currentlanguage) + currentlanguage = new_language(0, 0); + /* Generate appropriate outfile names */ + if(!output_name && !preprocess_only) + { + output_name = dup_basename(input_name, ".rc"); + strcat(output_name, ".res"); + } atexit(cleanup_files); - while (optind < argc) files[nb_files++] = argv[optind++]; + /* Run the preprocessor on the input */ + if(!no_preprocess) + { + /* + * Preprocess the input to a temp-file, or stdout if + * no output was given. + */ + + chat("Starting preprocess\n"); + + if (!preprocess_only) + { + ret = wpp_parse_temp( input_name, output_name, &temp_name ); + } + else if (output_name) + { + FILE *output; + + if (!(output = fopen( output_name, "w" ))) + fatal_perror( "Could not open %s for writing", output_name ); + ret = wpp_parse( input_name, output ); + fclose( output ); + } + else + { + ret = wpp_parse( input_name, stdout ); + } + + if(ret) + exit(1); /* Error during preprocess */ + + if(preprocess_only) + { + output_name = NULL; + exit(0); + } + + input_name = temp_name; + } - for (i = 0; i < nb_files; i++) - { - input_name = files[i]; - if(!output_name && !preprocess_only) - { - output_name = dup_basename(input_name, ".rc"); - strcat(output_name, ".res"); - } - if (load_file( input_name, output_name )) exit(1); - } + /* Go from .rc to .res */ + chat("Starting parse\n"); + + if(!(parser_in = fopen(input_name, "rb"))) + fatal_perror("Could not open %s for input", input_name); + + ret = parser_parse(); + + if(input_name) fclose(parser_in); + + if(ret) exit(1); /* Error during parse */ if(debuglevel & DEBUGLEVEL_DUMP) dump_resources(resource_top); diff --git a/tools/wrc/wrc.man.in b/tools/wrc/wrc.man.in index 5c8d0c0974d..7dfefc025ba 100644 --- a/tools/wrc/wrc.man.in +++ b/tools/wrc/wrc.man.in @@ -3,7 +3,7 @@ .SH NAME wrc \- Wine Resource Compiler .SH SYNOPSIS -.BI "wrc " "[options] " "[inputfiles]" +.BI "wrc " "[options] " "[inputfile]" .SH DESCRIPTION .B wrc compiles resources from \fBinputfile\fR @@ -14,7 +14,7 @@ preprocessor before the resources are compiled. See \fBPREPROCESSOR\fR below. .PP .B wrc -takes a series of \fBinputfile\fR as argument. The resources are read from +takes only one \fBinputfile\fR as argument. The resources are read from standard input if no inputfile is given. If the output file is not specified with \fI-o\fR, then \fBwrc\fR will write the output to \fBinputfile.res\fR with \fB.rc\fR stripped, or to \fBwrc.tab.res\fR if -- 2.11.4.GIT