diff --git a/base/applications/regedit/lang/tr-TR.rc b/base/applications/regedit/lang/tr-TR.rc index e8dbcd76d5f..86a7b72529d 100644 --- a/base/applications/regedit/lang/tr-TR.rc +++ b/base/applications/regedit/lang/tr-TR.rc @@ -242,7 +242,7 @@ BEGIN LTEXT "Husûsî Sürücü", IDC_DRIVER_EXCLUSIVE, 72, 240, 54, 8, WS_DISABLED RTEXT "Arayüz Türü:", IDC_STATIC, 144, 220, 58, 8 LTEXT "", IDC_INTERFACETYPE, 205, 220, 66, 8 - RTEXT "Veri Yolu Numarası:", IDC_STATIC, 151, 230, 51, 8 + RTEXT "Veriyolu Numarası:", IDC_STATIC, 151, 230, 51, 8 LTEXT "", IDC_BUSNUMBER, 205, 230, 66, 8 RTEXT "Sürüm:", IDC_STATIC, 151, 240, 51, 8 LTEXT "", IDC_VERSION, 205, 240, 66, 8 @@ -404,7 +404,7 @@ END STRINGTABLE BEGIN - IDS_BUSNUMBER "Veri Yolu Numarası" + IDS_BUSNUMBER "Veriyolu Numarası" IDS_INTERFACE "Arayüz" IDS_DMA_CHANNEL "Yol" IDS_DMA_PORT "Giriş" @@ -444,15 +444,15 @@ BEGIN IDS_BUS_TURBOCHANNEL "TURBOChannel" IDS_BUS_PCIBUS "PCI" IDS_BUS_VMEBUS "VME" - IDS_BUS_NUBUS "Nu Veri Yolu" + IDS_BUS_NUBUS "Nu Veriyolu" IDS_BUS_PCMCIABUS "PCMCIA" - IDS_BUS_CBUS "C Veri Yolu" - IDS_BUS_MPIBUS "MPI Veri Yolu" - IDS_BUS_MPSABUS "MPSA Veri Yolu" + IDS_BUS_CBUS "C Veriyolu" + IDS_BUS_MPIBUS "MPI Veriyolu" + IDS_BUS_MPSABUS "MPSA Veriyolu" IDS_BUS_PROCESSORINTERNAL "İç İşlemci" - IDS_BUS_INTERNALPOWERBUS "İç Güç Veri Yolu" - IDS_BUS_PNPISABUS "PnP-ISA Veri Yolu" - IDS_BUS_PNPBUS "PnP Veri Yolu" + IDS_BUS_INTERNALPOWERBUS "İç Güç Veriyolu" + IDS_BUS_PNPISABUS "PnP-ISA Veriyolu" + IDS_BUS_PNPBUS "PnP Veriyolu" IDS_BUS_UNKNOWNTYPE "Bilinmeyen Arayüz Türü" END diff --git a/base/setup/usetup/CMakeLists.txt b/base/setup/usetup/CMakeLists.txt index a2c3404f983..a53984ebb8e 100644 --- a/base/setup/usetup/CMakeLists.txt +++ b/base/setup/usetup/CMakeLists.txt @@ -32,14 +32,13 @@ list(APPEND SOURCE settings.c usetup.h) +if(CMAKE_C_COMPILER_ID STREQUAL "Clang") + #FIXME: Investigate Clang "illegal character encoding in string literal" warning + set_property(SOURCE mui.c APPEND_STRING PROPERTY COMPILE_FLAGS " -Wno-invalid-source-encoding") +endif() + add_executable(usetup ${SOURCE} usetup.rc) - -target_link_libraries(usetup - zlib - inflib - ext2lib - vfatlib) - +target_link_libraries(usetup zlib inflib ext2lib vfatlib) set_module_type(usetup nativecui) add_importlibs(usetup ntdll) add_pch(usetup usetup.h SOURCE) diff --git a/base/setup/usetup/errorcode.h b/base/setup/usetup/errorcode.h index 0acfbd67b1f..b845b3502d0 100644 --- a/base/setup/usetup/errorcode.h +++ b/base/setup/usetup/errorcode.h @@ -67,12 +67,8 @@ typedef enum ERROR_ADDING_KBLAYOUTS, ERROR_UPDATE_GEOID, ERROR_INSUFFICIENT_DISKSPACE, - ERROR_PARTITION_TABLE_FULL, ERROR_ONLY_ONE_EXTENDED, - ERROR_NOT_BEHIND_EXTENDED, - ERROR_EXTENDED_NOT_LAST, - ERROR_LAST_ERROR_CODE }ERROR_NUMBER; diff --git a/base/setup/usetup/lang/bg-BG.h b/base/setup/usetup/lang/bg-BG.h index 80aaaa867d1..1bf0e213a8d 100644 --- a/base/setup/usetup/lang/bg-BG.h +++ b/base/setup/usetup/lang/bg-BG.h @@ -1524,19 +1524,6 @@ MUI_ERROR bgBGErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/cs-CZ.h b/base/setup/usetup/lang/cs-CZ.h index 2f77d54881d..74555d0eeb2 100644 --- a/base/setup/usetup/lang/cs-CZ.h +++ b/base/setup/usetup/lang/cs-CZ.h @@ -1519,19 +1519,6 @@ MUI_ERROR csCZErrorEntries[] = "\n" " * Pokraujte stisknutm libovoln klvesy." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "Nen mon vytvoit oddl za rozenm oddlem.\n" - "\n" - " * Pokraujte stisknutm libovoln klvesy." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "Rozen oddl mus bt vdy posledn oddl\n" - "v tabulce oddl.\n" - "\n" - " * Pokraujte stisknutm libovoln klvesy." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/de-DE.h b/base/setup/usetup/lang/de-DE.h index ab58aae6ab7..f1d422f540b 100644 --- a/base/setup/usetup/lang/de-DE.h +++ b/base/setup/usetup/lang/de-DE.h @@ -1516,19 +1516,6 @@ MUI_ERROR deDEErrorEntries[] = "\n" " * Eine beliebige Taste zum Fortsetzen drcken." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "Sie knnen hinter einer erweiterten Partition keine weitere Partition anlegen.\n" - "\n" - " * Eine beliebige Taste zum Fortsetzen drcken." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "Eine erweiterte Partition muss immer die letzte Partition in \n" - "einer Partitionstabelle sein.\n" - "\n" - " * Eine beliebige Taste zum Fortsetzen drcken." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/el-GR.h b/base/setup/usetup/lang/el-GR.h index 82d83d4dd4c..4c7b79e1e56 100644 --- a/base/setup/usetup/lang/el-GR.h +++ b/base/setup/usetup/lang/el-GR.h @@ -1536,19 +1536,6 @@ MUI_ERROR elGRErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/en-US.h b/base/setup/usetup/lang/en-US.h index 7f752f39a8f..d4e7d5f802f 100644 --- a/base/setup/usetup/lang/en-US.h +++ b/base/setup/usetup/lang/en-US.h @@ -1511,19 +1511,6 @@ MUI_ERROR enUSErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/es-ES.h b/base/setup/usetup/lang/es-ES.h index d8bad41c343..b96a269a86d 100644 --- a/base/setup/usetup/lang/es-ES.h +++ b/base/setup/usetup/lang/es-ES.h @@ -1519,19 +1519,6 @@ MUI_ERROR esESErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/et-EE.h b/base/setup/usetup/lang/et-EE.h index e90023d4651..fe7463322ac 100644 --- a/base/setup/usetup/lang/et-EE.h +++ b/base/setup/usetup/lang/et-EE.h @@ -1509,19 +1509,6 @@ MUI_ERROR etEEErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/fr-FR.h b/base/setup/usetup/lang/fr-FR.h index c4dac549943..50220c3fe94 100644 --- a/base/setup/usetup/lang/fr-FR.h +++ b/base/setup/usetup/lang/fr-FR.h @@ -1524,19 +1524,6 @@ MUI_ERROR frFRErrorEntries[] = "\n" " * Appuyer sur une touche pour continuer." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "Impossible de crer une partition prcdant une partition tendue.\n" - "\n" - " * Appuyer sur une touche pour continuer." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "Une partition tendue doit toujours tre place en dernier\n" - "dans la table de partition.\n" - "\n" - " * Appuyer sur une touche pour continuer." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/he-IL.h b/base/setup/usetup/lang/he-IL.h index b4a3945f232..74f14761a15 100644 --- a/base/setup/usetup/lang/he-IL.h +++ b/base/setup/usetup/lang/he-IL.h @@ -1512,19 +1512,6 @@ MUI_ERROR heILErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/it-IT.h b/base/setup/usetup/lang/it-IT.h index e911a748ed1..2c7fc543cdb 100644 --- a/base/setup/usetup/lang/it-IT.h +++ b/base/setup/usetup/lang/it-IT.h @@ -1513,19 +1513,6 @@ MUI_ERROR itITErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/ja-JP.h b/base/setup/usetup/lang/ja-JP.h index 691406625fe..f4aa3cb6dc9 100644 --- a/base/setup/usetup/lang/ja-JP.h +++ b/base/setup/usetup/lang/ja-JP.h @@ -1513,19 +1513,6 @@ MUI_ERROR jaJPErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/lt-LT.h b/base/setup/usetup/lang/lt-LT.h index 7a7b4f746a5..ef7e9640dca 100644 --- a/base/setup/usetup/lang/lt-LT.h +++ b/base/setup/usetup/lang/lt-LT.h @@ -1521,19 +1521,6 @@ MUI_ERROR ltLTErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/nl-NL.h b/base/setup/usetup/lang/nl-NL.h index 167e1095b0d..cc775851d37 100644 --- a/base/setup/usetup/lang/nl-NL.h +++ b/base/setup/usetup/lang/nl-NL.h @@ -1557,19 +1557,6 @@ MUI_ERROR nlNLErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/pl-PL.h b/base/setup/usetup/lang/pl-PL.h index 7cecd01647f..cb83abb1b62 100644 --- a/base/setup/usetup/lang/pl-PL.h +++ b/base/setup/usetup/lang/pl-PL.h @@ -1521,19 +1521,6 @@ MUI_ERROR plPLErrorEntries[] = "\n" " * Nacinij dowolny klawisz, aby kontynuowa." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "Nie moesz utworzy partycji za partycj rozszerzon.\n" - "\n" - " * Nacinij dowolny klawisz, aby kontynuowa." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "Partycja rozszerzona musi by zawsze ostatni\n" - "partycj w tabeli partycji.\n" - "\n" - " * Nacinij dowolny klawisz, aby kontynuowa." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/pt-BR.h b/base/setup/usetup/lang/pt-BR.h index 19ad6719180..e1b0c113d60 100644 --- a/base/setup/usetup/lang/pt-BR.h +++ b/base/setup/usetup/lang/pt-BR.h @@ -1549,19 +1549,6 @@ MUI_ERROR ptBRErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/ro-RO.h b/base/setup/usetup/lang/ro-RO.h index 558011d80b8..13980d63bf1 100644 --- a/base/setup/usetup/lang/ro-RO.h +++ b/base/setup/usetup/lang/ro-RO.h @@ -1529,7 +1529,7 @@ MUI_ERROR roROErrorEntries[] = { //ERROR_CABINET_SECTION, "Nu se poate gsi seciunea de directoare\n" - "n fiierul cabinet.", + "n fiierul cabinet.", "ENTER = Repornire calculator" }, { @@ -1540,7 +1540,7 @@ MUI_ERROR roROErrorEntries[] = { //ERROR_FIND_SETUPDATA, "Nu se poate gsi seciunea pentru date de\n" - "instalare din fiierul TXTSETUP.SIF.", + "instalare din fiierul TXTSETUP.SIF.", "ENTER = Repornire calculator" }, { @@ -1561,7 +1561,7 @@ MUI_ERROR roROErrorEntries[] = { //ERROR_ADDING_KBLAYOUTS, "A euat includerea n registre a configuraiei\n" - "de tastatur.", + "de tastatur.", "ENTER = Repornire calculator" }, { @@ -1572,7 +1572,7 @@ MUI_ERROR roROErrorEntries[] = { //ERROR_INSUFFICIENT_DISKSPACE, "Pe partiia selectat nu exist suficient\n" - "spaiu liber." + "spaiu liber." " * Tastai pentru a continua.", NULL }, @@ -1589,19 +1589,6 @@ MUI_ERROR roROErrorEntries[] = "\n" " * Tastai pentru a continua." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "Nu se poate crea o partiie dup o partiie extins.\n" - "\n" - " * Tastai pentru a continua." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "O partiie extins trebuie s fie ntotdeauna\n" - "ultima partiie din tabela de partiii.\n" - "\n" - " * Tastai pentru a continua." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/ru-RU.h b/base/setup/usetup/lang/ru-RU.h index d8385038bd2..87d976e2e8e 100644 --- a/base/setup/usetup/lang/ru-RU.h +++ b/base/setup/usetup/lang/ru-RU.h @@ -1513,19 +1513,6 @@ MUI_ERROR ruRUErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/sk-SK.h b/base/setup/usetup/lang/sk-SK.h index 1373b270101..f2213cbd1b0 100644 --- a/base/setup/usetup/lang/sk-SK.h +++ b/base/setup/usetup/lang/sk-SK.h @@ -1523,19 +1523,6 @@ MUI_ERROR skSKErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/sq-AL.h b/base/setup/usetup/lang/sq-AL.h index 906fd89e5f7..4dbd396218a 100644 --- a/base/setup/usetup/lang/sq-AL.h +++ b/base/setup/usetup/lang/sq-AL.h @@ -1516,19 +1516,6 @@ MUI_ERROR sqALErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/sv-SE.h b/base/setup/usetup/lang/sv-SE.h index c9101b628a8..d763b603f27 100644 --- a/base/setup/usetup/lang/sv-SE.h +++ b/base/setup/usetup/lang/sv-SE.h @@ -1519,19 +1519,6 @@ MUI_ERROR svSEErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/tr-TR.h b/base/setup/usetup/lang/tr-TR.h index 5488f830a15..bc49c1c38b2 100644 --- a/base/setup/usetup/lang/tr-TR.h +++ b/base/setup/usetup/lang/tr-TR.h @@ -1499,19 +1499,6 @@ MUI_ERROR trTRErrorEntries[] = "\n" " * Srdrmek iin bir dmeye basnz." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "Bir geniletilmi blm arkasnda bir blm oluturamazsnz.\n" - "\n" - " * Srdrmek iin bir dmeye basnz." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "Bir geniletilmi blm, her zaman bir blm\n" - "tablosunda son blm olmaldr.\n" - "\n" - " * Srdrmek iin bir dmeye basnz." - }, { NULL, NULL diff --git a/base/setup/usetup/lang/uk-UA.h b/base/setup/usetup/lang/uk-UA.h index aa723b0308b..517736faeb4 100644 --- a/base/setup/usetup/lang/uk-UA.h +++ b/base/setup/usetup/lang/uk-UA.h @@ -1519,19 +1519,6 @@ MUI_ERROR ukUAErrorEntries[] = "\n" " * Press any key to continue." }, - { - //ERROR_NOT_BEHIND_EXTENDED, - "You can not create a partition behind an extended partition.\n" - "\n" - " * Press any key to continue." - }, - { - //ERROR_EXTENDED_NOT_LAST, - "An extended partition must always be the last\n" - "partition in a partition table.\n" - "\n" - " * Press any key to continue." - }, { NULL, NULL diff --git a/base/setup/usetup/partlist.c b/base/setup/usetup/partlist.c index 0e28213e995..0e0bbc991ab 100644 --- a/base/setup/usetup/partlist.c +++ b/base/setup/usetup/partlist.c @@ -2054,7 +2054,8 @@ ScrollDownPartitionList( { /* Primary or extended partition */ - if (IsContainerPartition(List->CurrentPartition->PartitionType)) + if (List->CurrentPartition->IsPartitioned == TRUE && + IsContainerPartition(List->CurrentPartition->PartitionType)) { /* First logical partition */ PartListEntry = List->CurrentDisk->LogicalPartListHead.Flink; @@ -2147,7 +2148,8 @@ ScrollUpPartitionList( { PartEntry = CONTAINING_RECORD(PartListEntry, PARTENTRY, ListEntry); - if (IsContainerPartition(PartEntry->PartitionType)) + if (PartEntry->IsPartitioned == TRUE && + IsContainerPartition(PartEntry->PartitionType)) { PartListEntry = List->CurrentDisk->LogicalPartListHead.Blink; PartEntry = CONTAINING_RECORD(PartListEntry, PARTENTRY, ListEntry); @@ -2171,7 +2173,8 @@ ScrollUpPartitionList( { PartEntry = CONTAINING_RECORD(PartListEntry, PARTENTRY, ListEntry); - if (IsContainerPartition(PartEntry->PartitionType)) + if (PartEntry->IsPartitioned == TRUE && + IsContainerPartition(PartEntry->PartitionType)) { PartListEntry = DiskEntry->LogicalPartListHead.Blink; if (PartListEntry != &DiskEntry->LogicalPartListHead) @@ -2697,6 +2700,7 @@ DeleteCurrentPartition( { /* Nothing to merge but change current entry */ PartEntry->IsPartitioned = FALSE; + PartEntry->PartitionType = PARTITION_ENTRY_UNUSED; PartEntry->FormatState = Unformatted; PartEntry->DriveLetter = 0; } @@ -2999,41 +3003,6 @@ SetMountedDeviceValues( } -static -BOOLEAN -IsLastPrimaryPartiton( - IN PPARTENTRY PartEntry) -{ - return (PartEntry->ListEntry.Flink == &PartEntry->DiskEntry->PrimaryPartListHead); -} - - -static -BOOLEAN -IsPreviousPartitionExtended( - IN PPARTENTRY PartEntry, - IN PDISKENTRY DiskEntry) -{ - PPARTENTRY PrevPartEntry; - PLIST_ENTRY Entry; - - Entry = PartEntry->ListEntry.Blink; - - while (Entry != &DiskEntry->PrimaryPartListHead) - { - PrevPartEntry = CONTAINING_RECORD(Entry, PARTENTRY, ListEntry); - - if (IsContainerPartition(PrevPartEntry->PartitionType)) - return TRUE; - - Entry = Entry->Blink; - } - - return FALSE; - -} - - static ULONG GetPrimaryPartitionCount( @@ -3075,10 +3044,6 @@ PrimaryPartitionCreationChecks( if (GetPrimaryPartitionCount(DiskEntry) > 4) return ERROR_PARTITION_TABLE_FULL; - /* Fail if this partiton is located behind an extended partition */ - if (IsPreviousPartitionExtended(PartEntry, DiskEntry)) - return ERROR_NOT_BEHIND_EXTENDED; - return ERROR_SUCCESS; } @@ -3105,10 +3070,6 @@ ExtendedPartitionCreationChecks( if (DiskEntry->ExtendedPartition != NULL) return ERROR_ONLY_ONE_EXTENDED; - /* Fail if the partition is not the last list entry */ - if (!IsLastPrimaryPartiton(PartEntry)) - return ERROR_EXTENDED_NOT_LAST; - return ERROR_SUCCESS; } diff --git a/base/system/services/database.c b/base/system/services/database.c index 4ae8473a2de..476c627800f 100644 --- a/base/system/services/database.c +++ b/base/system/services/database.c @@ -1339,6 +1339,11 @@ ScmWaitForServiceConnect(PSERVICE Service) #ifdef USE_ASYNCHRONOUS_IO OVERLAPPED Overlapped = {0}; #endif +#if 0 + LPCWSTR lpErrorStrings[3]; + WCHAR szBuffer1[20]; + WCHAR szBuffer2[20]; +#endif DPRINT("ScmWaitForServiceConnect()\n"); @@ -1370,6 +1375,18 @@ ScmWaitForServiceConnect(PSERVICE Service) DPRINT1("CancelIo() failed (Error: %lu)\n", GetLastError()); } +#if 0 + _ultow(PipeTimeout, szBuffer1, 10); + lpErrorStrings[0] = Service->lpDisplayName; + lpErrorStrings[1] = szBuffer1; + + ScmLogEvent(EVENT_CONNECTION_TIMEOUT, + EVENTLOG_ERROR_TYPE, + 2, + lpErrorStrings); +#endif + DPRINT1("Log EVENT_CONNECTION_TIMEOUT by %S\n", Service->lpDisplayName); + return ERROR_SERVICE_REQUEST_TIMEOUT; } else if (dwError == WAIT_OBJECT_0) @@ -1425,6 +1442,17 @@ ScmWaitForServiceConnect(PSERVICE Service) DPRINT1("CancelIo() failed (Error: %lu)\n", GetLastError()); } +#if 0 + _ultow(PipeTimeout, szBuffer1, 10); + lpErrorStrings[0] = szBuffer1; + + ScmLogEvent(EVENT_READFILE_TIMEOUT, + EVENTLOG_ERROR_TYPE, + 1, + lpErrorStrings); +#endif + DPRINT1("Log EVENT_READFILE_TIMEOUT by %S\n", Service->lpDisplayName); + return ERROR_SERVICE_REQUEST_TIMEOUT; } else if (dwError == WAIT_OBJECT_0) @@ -1456,18 +1484,24 @@ ScmWaitForServiceConnect(PSERVICE Service) return dwError; } } - else - { - if (dwProcessId != Service->lpImage->dwProcessId) - { -/* - LPWSTR Strings[3] - ScmLogError(EVENT_SERVICE_DIFFERENT_PID_CONNECTED, - 3, - lpStrings); -*/ - } + if (dwProcessId != Service->lpImage->dwProcessId) + { +#if 0 + _ultow(Service->lpImage->dwProcessId, szBuffer1, 10); + _ultow(dwProcessId, szBuffer2, 10); + + lpErrorStrings[0] = Service->lpDisplayName; + lpErrorStrings[1] = szBuffer1; + lpErrorStrings[2] = szBuffer2; + + ScmLogEvent(EVENT_SERVICE_DIFFERENT_PID_CONNECTED, + EVENTLOG_WARNING_TYPE, + 3, + lpErrorStrings); +#endif + + DPRINT1("Log EVENT_SERVICE_DIFFERENT_PID_CONNECTED by %S\n", Service->lpDisplayName); } DPRINT("ScmWaitForServiceConnect() done\n"); diff --git a/base/system/services/services.h b/base/system/services/services.h index 604e7e454d1..dde3d12c8f6 100644 --- a/base/system/services/services.h +++ b/base/system/services/services.h @@ -6,6 +6,7 @@ #define _SERVICES_H #include +#include #define WIN32_NO_STATUS #define _INC_WINDOWS diff --git a/base/system/winlogon/CMakeLists.txt b/base/system/winlogon/CMakeLists.txt index 9a82f501c08..079fe92eac6 100644 --- a/base/system/winlogon/CMakeLists.txt +++ b/base/system/winlogon/CMakeLists.txt @@ -1,16 +1,24 @@ +include_directories( + ${REACTOS_SOURCE_DIR}/include/reactos/idl + ${CMAKE_CURRENT_BINARY_DIR}) + +add_rpc_files(server ${REACTOS_SOURCE_DIR}/include/reactos/idl/winreg.idl) + list(APPEND SOURCE environment.c + rpcserver.c sas.c screensaver.c setup.c winlogon.c wlx.c - winlogon.h) + winlogon.h + ${CMAKE_CURRENT_BINARY_DIR}/winreg_s.c) add_executable(winlogon ${SOURCE} winlogon.rc) target_link_libraries(winlogon wine) set_module_type(winlogon win32gui) -add_importlibs(winlogon user32 advapi32 userenv secur32 msvcrt kernel32 ntdll) +add_importlibs(winlogon user32 advapi32 userenv secur32 rpcrt4 msvcrt kernel32 ntdll) add_pch(winlogon winlogon.h SOURCE) add_cd_file(TARGET winlogon DESTINATION reactos/system32 FOR all) diff --git a/base/system/winlogon/rpcserver.c b/base/system/winlogon/rpcserver.c new file mode 100644 index 00000000000..9c713184839 --- /dev/null +++ b/base/system/winlogon/rpcserver.c @@ -0,0 +1,570 @@ +/* + * COPYRIGHT: See COPYING in the top level directory + * PROJECT: ReactOS Winlogon + * FILE: base/system/winlogon/rpcserver.c + * PURPOSE: RPC server interface for the remote registry calls + * PROGRAMMERS: Eric Kohl + */ + +/* INCLUDES *****************************************************************/ + +#include "winlogon.h" + +#include +#include + + +/* FUNCTIONS *****************************************************************/ + +BOOL +StartRpcServer(VOID) +{ + RPC_STATUS Status; + + TRACE("ScmStartRpcServer() called\n"); + + Status = RpcServerUseProtseqEpW(L"ncacn_np", + 10, + L"\\pipe\\winreg", + NULL); + if (Status != RPC_S_OK) + { + ERR("RpcServerUseProtseqEpW() failed (Status %lx)\n", Status); + return FALSE; + } + + Status = RpcServerRegisterIf(winreg_v1_0_s_ifspec, + NULL, + NULL); + if (Status != RPC_S_OK) + { + ERR("RpcServerRegisterIf() failed (Status %lx)\n", Status); + return FALSE; + } + + Status = RpcServerListen(1, 20, TRUE); + if (Status != RPC_S_OK) + { + ERR("RpcServerListen() failed (Status %lx)\n", Status); + return FALSE; + } + + TRACE("StartRpcServer() done\n"); + return TRUE; +} + + +void __RPC_FAR * __RPC_USER MIDL_user_allocate(SIZE_T len) +{ + return HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, len); +} + + +void __RPC_USER MIDL_user_free(void __RPC_FAR * ptr) +{ + HeapFree(GetProcessHeap(), 0, ptr); +} + + +void __RPC_USER RPC_HKEY_rundown(RPC_HKEY hSCObject) +{ +} + + +/* Function 0 */ +error_status_t +WINAPI +OpenClassesRoot( + PREGISTRY_SERVER_NAME ServerName, + REGSAM samDesired, + PRPC_HKEY phKey) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 1 */ +error_status_t +WINAPI +OpenCurrentUser( + PREGISTRY_SERVER_NAME ServerName, + REGSAM samDesired, + PRPC_HKEY phKey) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 2 */ +error_status_t +WINAPI +OpenLocalMachine( + PREGISTRY_SERVER_NAME ServerName, + REGSAM samDesired, + PRPC_HKEY phKey) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 3 */ +error_status_t +WINAPI +OpenPerformanceData( + PREGISTRY_SERVER_NAME ServerName, + REGSAM samDesired, + PRPC_HKEY phKey) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 4 */ +error_status_t +WINAPI +OpenUsers( + PREGISTRY_SERVER_NAME ServerName, + REGSAM samDesired, + PRPC_HKEY phKey) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 5 */ +error_status_t +WINAPI +BaseRegCloseKey( + PRPC_HKEY hKey) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 6 */ +error_status_t +WINAPI +BaseRegCreateKey( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpSubKey, + PRPC_UNICODE_STRING lpClass, + DWORD dwOptions, + REGSAM samDesired, + PRPC_SECURITY_ATTRIBUTES lpSecurityAttributes, + PRPC_HKEY phkResult, + LPDWORD lpdwDisposition) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 7 */ +error_status_t +WINAPI +BaseRegDeleteKey( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpSubKey) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 8 */ +error_status_t +WINAPI +BaseRegDeleteValue( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpValueName) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 9 */ +error_status_t +WINAPI +BaseRegEnumKey( + RPC_HKEY hKey, + DWORD dwIndex, + PRPC_UNICODE_STRING lpNameIn, + PRPC_UNICODE_STRING lpNameOut, + PRPC_UNICODE_STRING lpClassIn, + PRPC_UNICODE_STRING *lplpClassOut, + PFILETIME lpftLastWriteTime) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 10 */ +error_status_t +WINAPI +BaseRegEnumValue( + RPC_HKEY hKey, + DWORD dwIndex, + PRPC_UNICODE_STRING lpValueNameIn, + PRPC_UNICODE_STRING lpValueNameOut, + LPDWORD lpType, + LPBYTE lpData, + LPDWORD lpcbData, + LPDWORD lpcbLen) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 11 */ +error_status_t +__stdcall +BaseRegFlushKey( + RPC_HKEY hKey) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 12 */ +error_status_t +__stdcall +BaseRegGetKeySecurity( + RPC_HKEY hKey, + SECURITY_INFORMATION SecurityInformation, + PRPC_SECURITY_DESCRIPTOR pRpcSecurityDescriptorIn, + PRPC_SECURITY_DESCRIPTOR pRpcSecurityDescriptorOut) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 13 */ +error_status_t +__stdcall +BaseRegLoadKey( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpSubKey, + PRPC_UNICODE_STRING lpFile) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 14 */ +void +__stdcall +Opnum14NotImplemented( + handle_t IDL_handle) +{ + TRACE("\n"); +} + + +/* Function 15 */ +error_status_t +__stdcall +BaseRegOpenKey( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpSubKey, + DWORD dwOptions, + REGSAM samDesired, + PRPC_HKEY phkResult) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 16 */ +error_status_t +__stdcall +BaseRegQueryInfoKey( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpClassIn, + PRPC_UNICODE_STRING lpClassOut, + LPDWORD lpcSubKeys, + LPDWORD lpcbMaxSubKeyLen, + LPDWORD lpcbMaxClassLen, + LPDWORD lpcValues, + LPDWORD lpcbMaxValueNameLen, + LPDWORD lpcbMaxValueLen, + LPDWORD lpcbSecurityDescriptor, + PFILETIME lpftLastWriteTime) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 17 */ +error_status_t +__stdcall +BaseRegQueryValue( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpValueName, + LPDWORD lpType, + LPBYTE lpData, + LPDWORD lpcbData, + LPDWORD lpcbLen) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 18 */ +error_status_t +__stdcall +BaseRegReplaceKey( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpSubKey, + PRPC_UNICODE_STRING lpNewFile, + PRPC_UNICODE_STRING lpOldFile) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 19 */ +error_status_t +__stdcall +BaseRegRestoreKey( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpFile, + DWORD Flags) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 20 */ +error_status_t +__stdcall +BaseRegSaveKey( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpFile, + PRPC_SECURITY_ATTRIBUTES pSecurityAttributes) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 21 */ +error_status_t +__stdcall +BaseRegSetKeySecurity( + RPC_HKEY hKey, + SECURITY_INFORMATION SecurityInformation, + PRPC_SECURITY_DESCRIPTOR pRpcSecurityDescriptor) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 22 */ +error_status_t +__stdcall +BaseRegSetValue( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpValueName, + DWORD dwType, + LPBYTE lpData, + DWORD cbData) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 23 */ +error_status_t +__stdcall +BaseRegUnLoadKey( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpSubKey) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 24 */ +ULONG +__stdcall +BaseInitiateSystemShutdown( + PREGISTRY_SERVER_NAME ServerName, + PRPC_UNICODE_STRING lpMessage, + ULONG dwTimeout, + BOOLEAN bForceAppsClosed, + BOOLEAN bRebootAfterShutdown) +{ + TRACE("BaseInitiateSystemShutdown()\n"); + return ERROR_SUCCESS; +} + + +/* Function 25 */ +ULONG +__stdcall +BaseAbortSystemShutdown( + PREGISTRY_SERVER_NAME ServerName) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 26 */ +error_status_t +__stdcall +BaseRegGetVersion( + RPC_HKEY hKey, + LPDWORD lpdwVersion) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 27 */ +error_status_t +__stdcall +OpenCurrentConfig( + PREGISTRY_SERVER_NAME ServerName, + REGSAM samDesired, + PRPC_HKEY phKey) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 28 */ +void +__stdcall +Opnum28NotImplemented( + handle_t IDL_handle) +{ + TRACE("\n"); +} + + +/* Function 29 */ +error_status_t +__stdcall +BaseRegQueryMultipleValues( + RPC_HKEY hKey, + PRVALENT val_listIn, + PRVALENT val_listOut, + DWORD num_vals, + char *lpvalueBuf, + LPDWORD ldwTotsize) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 30 */ +ULONG +__stdcall +BaseInitiateSystemShutdownEx( + PREGISTRY_SERVER_NAME ServerName, + PRPC_UNICODE_STRING lpMessage, + ULONG dwTimeout, + BOOLEAN bForceAppsClosed, + BOOLEAN bRebootAfterShutdown, + ULONG dwReason) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 31 */ +error_status_t +__stdcall +BaseRegSaveKeyEx( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpFile, + PRPC_SECURITY_ATTRIBUTES pSecurityAttributes, + DWORD Flags) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 32 */ +error_status_t +__stdcall +OpenPerformanceText( + PREGISTRY_SERVER_NAME ServerName, + REGSAM samDesired, + PRPC_HKEY phKey) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 33 */ +error_status_t +__stdcall +OpenPerformanceNlsText( + PREGISTRY_SERVER_NAME ServerName, + REGSAM samDesired, + PRPC_HKEY phKey) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 34 */ +error_status_t +__stdcall +BaseRegQueryMultipleValues2( + RPC_HKEY hKey, + PRVALENT val_listIn, + PRVALENT val_listOut, + DWORD num_vals, + char *lpvalueBuf, + LPDWORD ldwTotsize, + LPDWORD ldwRequiredSize) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + + +/* Function 35 */ +error_status_t +__stdcall +BaseRegDeleteKeyEx( + RPC_HKEY hKey, + PRPC_UNICODE_STRING lpSubKey, + REGSAM AccessMask, + DWORD Reserved) +{ + TRACE("\n"); + return ERROR_SUCCESS; +} + +/* EOF */ diff --git a/base/system/winlogon/winlogon.c b/base/system/winlogon/winlogon.c index 76f0c394f6a..4bc48215239 100644 --- a/base/system/winlogon/winlogon.c +++ b/base/system/winlogon/winlogon.c @@ -356,6 +356,13 @@ WinMain( ExitProcess(1); } + if (!StartRpcServer()) + { + ERR("WL: Could not start the RPC server\n"); + NtRaiseHardError(STATUS_SYSTEM_PROCESS_TERMINATED, 0, 0, NULL, OptionOk, &HardErrorResponse); + ExitProcess(1); + } + if (!StartServicesManager()) { ERR("WL: Could not start services.exe\n"); diff --git a/base/system/winlogon/winlogon.h b/base/system/winlogon/winlogon.h index 228b5e1794f..ba5a3e4a036 100644 --- a/base/system/winlogon/winlogon.h +++ b/base/system/winlogon/winlogon.h @@ -259,6 +259,10 @@ extern PWLSESSION WLSession; BOOL CreateUserEnvironment(IN PWLSESSION Session); +/* rpcserver.c */ +BOOL +StartRpcServer(VOID); + /* sas.c */ BOOL SetDefaultLanguage(IN BOOL UserProfile); diff --git a/boot/bootdata/hivedef.inf b/boot/bootdata/hivedef.inf index 4e3c512c070..cb6fdef3d54 100644 --- a/boot/bootdata/hivedef.inf +++ b/boot/bootdata/hivedef.inf @@ -1645,7 +1645,7 @@ HKCU,"SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon","Shell",0x00020000, HKCU,"SOFTWARE\Microsoft\Windows\CurrentVersion\Policies",,0x00000012 HKCU,"SOFTWARE\Microsoft\Windows\CurrentVersion\Run",,0x00000012 -HKCU,"Software\Microsoft\Windows\CurrentVersion\Telephony",,0x00000012 +HKCU,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony",,0x00000012 HKCU,"SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall",,0x00000012 HKCU,"SOFTWARE\Microsoft\Windows NT",,0x00000012 @@ -1711,8 +1711,8 @@ HKCU,"SOFTWARE\ReactOS\Debug","SpyInclude",0x00020000,"INCLUDEALL" ;HKCU,"SOFTWARE\ReactOS\Debug","SpyExcludeDWP",0x00020000,"" ; Internet Explorer -HKCU,Software\Wine\MSHTML,"GeckoUrl",,"http://source.winehq.org/winegecko.php" -HKCU,Software\Wine\MSHTML,"GeckoCabDir",0x00020000,"%SystemRoot%\" +HKCU,"SOFTWARE\Wine\MSHTML","GeckoUrl",,"http://source.winehq.org/winegecko.php" +HKCU,"SOFTWARE\Wine\MSHTML","GeckoCabDir",0x00020000,"%SystemRoot%\" HKCU,"SOFTWARE\Microsoft\Internet Explorer\Main","Start Page",0x00000000,"http://www.reactos.org" diff --git a/boot/bootdata/hivesys.inf b/boot/bootdata/hivesys.inf index be1ca6678a6..448964fa16e 100644 --- a/boot/bootdata/hivesys.inf +++ b/boot/bootdata/hivesys.inf @@ -1982,7 +1982,7 @@ HKLM,"SYSTEM\CurrentControlSet\Services\Vga","ImagePath",0x00020000,"system32\dr HKLM,"SYSTEM\CurrentControlSet\Services\Vga","Start",0x00010001,0x00000004 HKLM,"SYSTEM\CurrentControlSet\Services\Vga","Type",0x00010001,0x00000001 HKLM,"SYSTEM\CurrentControlSet\Services\Vga","Tag",0x00010001,0x00000002 -HKLM,"SYSTEM\CurrentControlSet\Hardware Profiles\Current\System\CurrentControlSet\Services\VGA\Device0","VgaCompatible",0x00010001,1 +HKLM,"SYSTEM\CurrentControlSet\Hardware Profiles\Current\System\CurrentControlSet\Services\Vga\Device0","VgaCompatible",0x00010001,1 HKLM,"SYSTEM\CurrentControlSet\Hardware Profiles\Current\System\CurrentControlSet\Services\Vga\Device0","InstalledDisplayDrivers",0x00010000,"vgaddi" HKLM,"SYSTEM\CurrentControlSet\Hardware Profiles\Current\System\CurrentControlSet\Services\Vga\Device0","DefaultSettings.VRefresh",0x00010001,1 diff --git a/cmake/gcc.cmake b/cmake/gcc.cmake index 9b92c7f8c2e..bcfb0c709d4 100644 --- a/cmake/gcc.cmake +++ b/cmake/gcc.cmake @@ -9,6 +9,11 @@ if(NOT DEFINED SEPARATE_DBG) set(SEPARATE_DBG FALSE) endif() +# Dwarf based builds (no rsym) +if(NOT DEFINED NO_ROSSYM) + set(NO_ROSSYM FALSE) +endif() + if(NOT DEFINED USE_PSEH3) set(USE_PSEH3 1) endif() @@ -194,6 +199,14 @@ if(SEPARATE_DBG) " -o " "${OBJCOPY} --only-keep-debug ${REACTOS_BINARY_DIR}/symbols/${SYMBOL_FILE}" "${OBJCOPY} --strip-debug ") +elseif(NO_ROSSYM) + # Dwarf-based build + message(STATUS "Generating a dwarf-based build (no rsym)") + set(CMAKE_C_LINK_EXECUTABLE " ${CMAKE_C_FLAGS} -o ") + set(CMAKE_CXX_LINK_EXECUTABLE " ${CMAKE_CXX_FLAGS} -o ") + set(CMAKE_C_CREATE_SHARED_LIBRARY " ${CMAKE_C_FLAGS} -o ") + set(CMAKE_CXX_CREATE_SHARED_LIBRARY " ${CMAKE_CXX_FLAGS} -o ") + set(CMAKE_RC_CREATE_SHARED_LIBRARY " ${CMAKE_C_FLAGS} -o ") else() # Normal rsym build get_target_property(RSYM native-rsym IMPORTED_LOCATION_NOCONFIG) diff --git a/dll/win32/advapi32/CMakeLists.txt b/dll/win32/advapi32/CMakeLists.txt index 245749882c9..71dc694f739 100644 --- a/dll/win32/advapi32/CMakeLists.txt +++ b/dll/win32/advapi32/CMakeLists.txt @@ -28,6 +28,7 @@ list(APPEND SOURCE misc/msi.c misc/shutdown.c misc/sysfunc.c + reg/hkcr.c reg/reg.c sec/ac.c sec/audit.c diff --git a/dll/win32/advapi32/reg/hkcr.c b/dll/win32/advapi32/reg/hkcr.c new file mode 100644 index 00000000000..95032817931 --- /dev/null +++ b/dll/win32/advapi32/reg/hkcr.c @@ -0,0 +1,801 @@ +/* + * COPYRIGHT: See COPYING in the top level directory + * PROJECT: ReactOS system libraries + * FILE: lib/advapi32/reg/hkcr.c + * PURPOSE: Registry functions - HKEY_CLASSES_ROOT abstraction + * PROGRAMMER: Jerôme Gardou (jerome.gardou@reactos.org) + */ + +#include + +#include +#include + +#include "reg.h" + +WINE_DEFAULT_DEBUG_CHANNEL(reg); + +static const UNICODE_STRING HKLM_ClassesPath = RTL_CONSTANT_STRING(L"\\Registry\\Machine\\Software\\Classes"); + +static +LONG +GetKeyName(HKEY hKey, PUNICODE_STRING KeyName) +{ + UNICODE_STRING InfoName; + PKEY_NAME_INFORMATION NameInformation; + ULONG InfoLength; + NTSTATUS Status; + + /* Get info length */ + InfoLength = 0; + Status = NtQueryKey(hKey, KeyNameInformation, NULL, 0, &InfoLength); + if (Status != STATUS_BUFFER_TOO_SMALL) + { + ERR("NtQueryKey returned unexpected Status: 0x%08x\n", Status); + return RtlNtStatusToDosError(Status); + } + + /* Get it for real */ + NameInformation = RtlAllocateHeap(RtlGetProcessHeap(), 0, InfoLength); + if (NameInformation == NULL) + { + ERR("Failed to allocate %lu bytes", InfoLength); + return ERROR_NOT_ENOUGH_MEMORY; + } + + Status = NtQueryKey(hKey, KeyNameInformation, NameInformation, InfoLength, &InfoLength); + if (!NT_SUCCESS(Status)) + { + RtlFreeHeap(RtlGetProcessHeap(), 0, NameInformation); + ERR("NtQueryKey failed: 0x%08x\n", Status); + return RtlNtStatusToDosError(Status); + } + + /* Make it a proper UNICODE_STRING */ + InfoName.Length = NameInformation->NameLength; + InfoName.MaximumLength = NameInformation->NameLength; + InfoName.Buffer = NameInformation->Name; + + Status = RtlDuplicateUnicodeString(RTL_DUPLICATE_UNICODE_STRING_NULL_TERMINATE, &InfoName, KeyName); + if (!NT_SUCCESS(Status)) + { + RtlFreeHeap(RtlGetProcessHeap(), 0, NameInformation); + ERR("RtlDuplicateUnicodeString failed: 0x%08x\n", Status); + return RtlNtStatusToDosError(Status); + } + + RtlFreeHeap(RtlGetProcessHeap(), 0, NameInformation); + + return ERROR_SUCCESS; +} + +static +LONG +GetKeySam( + _In_ HKEY hKey, + _Out_ REGSAM* RegSam) +{ + NTSTATUS Status; + OBJECT_BASIC_INFORMATION ObjectInfo; + + Status = NtQueryObject(hKey, ObjectBasicInformation, &ObjectInfo, sizeof(ObjectInfo), NULL); + if (!NT_SUCCESS(Status)) + { + ERR("NtQueryObject failed, Status %x08x\n", Status); + return RtlNtStatusToDosError(Status); + } + + *RegSam = ObjectInfo.GrantedAccess; + return ERROR_SUCCESS; +} + +/* + * Gets a HKLM key from an HKCU key. + */ +static +LONG +GetFallbackHKCRKey( + _In_ HKEY hKey, + _Out_ HKEY* MachineKey, + _In_ BOOL MustCreate) +{ + UNICODE_STRING KeyName; + LPWSTR SubKeyName; + LONG ErrorCode; + REGSAM SamDesired; + + /* Get the key name */ + ErrorCode = GetKeyName(hKey, &KeyName); + if (ErrorCode != ERROR_SUCCESS) + return ErrorCode; + + /* See if we really need a conversion */ + if (RtlPrefixUnicodeString(&HKLM_ClassesPath, &KeyName, TRUE)) + { + RtlFreeUnicodeString(&KeyName); + *MachineKey = hKey; + return ERROR_SUCCESS; + } + + SubKeyName = KeyName.Buffer + 15; /* 15 == wcslen(L"\\Registry\\User\\") */ + /* Skip the user token */ + while (*SubKeyName++ != L'\\') + { + if (!*SubKeyName) + { + ERR("Key name %S is invalid!\n", KeyName.Buffer); + return ERROR_INTERNAL_ERROR; + } + } + + /* Use the same access mask than the original key */ + ErrorCode = GetKeySam(hKey, &SamDesired); + if (ErrorCode != ERROR_SUCCESS) + { + RtlFreeUnicodeString(&KeyName); + return ErrorCode; + } + + if (MustCreate) + { + ErrorCode = RegCreateKeyExW( + HKEY_LOCAL_MACHINE, + SubKeyName, + 0, + NULL, + 0, + SamDesired, + NULL, + MachineKey, + NULL); + } + else + { + /* Open the key. */ + ErrorCode = RegOpenKeyExW( + HKEY_LOCAL_MACHINE, + SubKeyName, + 0, + SamDesired, + MachineKey); + } + + RtlFreeUnicodeString(&KeyName); + + return ErrorCode; +} + +/* Get the HKCU key (if it exists) from an HKCR key */ +static +LONG +GetPreferredHKCRKey( + _In_ HKEY hKey, + _Out_ HKEY* PreferredKey) +{ + UNICODE_STRING KeyName; + LPWSTR SubKeyName; + LONG ErrorCode; + REGSAM SamDesired; + + /* Get the key name */ + ErrorCode = GetKeyName(hKey, &KeyName); + if (ErrorCode != ERROR_SUCCESS) + return ErrorCode; + + /* See if we really need a conversion */ + if (!RtlPrefixUnicodeString(&HKLM_ClassesPath, &KeyName, TRUE)) + { + RtlFreeUnicodeString(&KeyName); + *PreferredKey = hKey; + return ERROR_SUCCESS; + } + + /* 18 == wcslen(L"\\Registry\\Machine\\") */ + SubKeyName = KeyName.Buffer + 18; + + /* Use the same access mask than the original key */ + ErrorCode = GetKeySam(hKey, &SamDesired); + if (ErrorCode != ERROR_SUCCESS) + { + RtlFreeUnicodeString(&KeyName); + return ErrorCode; + } + + /* Open the key. */ + ErrorCode = RegOpenKeyExW( + HKEY_CURRENT_USER, + SubKeyName, + 0, + SamDesired, + PreferredKey); + + RtlFreeUnicodeString(&KeyName); + + return ErrorCode; +} + +/* HKCR version of RegCreateKeyExW. */ +LONG +WINAPI +CreateHKCRKey( + _In_ HKEY hKey, + _In_ LPCWSTR lpSubKey, + _In_ DWORD Reserved, + _In_opt_ LPWSTR lpClass, + _In_ DWORD dwOptions, + _In_ REGSAM samDesired, + _In_opt_ LPSECURITY_ATTRIBUTES lpSecurityAttributes, + _Out_ PHKEY phkResult, + _Out_opt_ LPDWORD lpdwDisposition) +{ + LONG ErrorCode; + HKEY QueriedKey, TestKey; + + ASSERT(IsHKCRKey(hKey)); + + /* Remove the HKCR flag while we're working */ + hKey = (HKEY)(((ULONG_PTR)hKey) & ~0x2); + + ErrorCode = GetPreferredHKCRKey(hKey, &QueriedKey); + + if (ErrorCode == ERROR_FILE_NOT_FOUND) + { + /* The current key doesn't exist on HKCU side, so we can only create it in HKLM */ + ErrorCode = RegCreateKeyExW( + hKey, + lpSubKey, + Reserved, + lpClass, + dwOptions, + samDesired, + lpSecurityAttributes, + phkResult, + lpdwDisposition); + if (ErrorCode == ERROR_SUCCESS) + MakeHKCRKey(phkResult); + return ErrorCode; + } + + if (ErrorCode != ERROR_SUCCESS) + { + /* Somehow we failed for another reason (maybe deleted key or whatever) */ + return ErrorCode; + } + + /* See if the subkey already exists in HKCU. */ + ErrorCode = RegOpenKeyExW(QueriedKey, lpSubKey, 0, 0, &TestKey); + if (ErrorCode != ERROR_FILE_NOT_FOUND) + { + if (ErrorCode == ERROR_SUCCESS) + { + /* Great. Close the test one and do the real create operation */ + RegCloseKey(TestKey); + ErrorCode = RegCreateKeyExW( + QueriedKey, + lpSubKey, + Reserved, + lpClass, + dwOptions, + samDesired, + lpSecurityAttributes, + phkResult, + lpdwDisposition); + if (ErrorCode == ERROR_SUCCESS) + MakeHKCRKey(phkResult); + } + if (QueriedKey != hKey) + RegCloseKey(QueriedKey); + + return ERROR_SUCCESS; + } + + if (QueriedKey != hKey) + RegCloseKey(QueriedKey); + + /* So we must do the create operation in HKLM, creating the missing parent keys if needed. */ + ErrorCode = GetFallbackHKCRKey(hKey, &QueriedKey, TRUE); + if (ErrorCode != ERROR_SUCCESS) + return ErrorCode; + + /* Do the key creation */ + ErrorCode = RegCreateKeyEx( + QueriedKey, + lpSubKey, + Reserved, + lpClass, + dwOptions, + samDesired, + lpSecurityAttributes, + phkResult, + lpdwDisposition); + + if (QueriedKey != hKey) + RegCloseKey(QueriedKey); + + if (ErrorCode == ERROR_SUCCESS) + MakeHKCRKey(phkResult); + + return ErrorCode; +} + +/* Same as RegOpenKeyExW, but for HKEY_CLASSES_ROOT subkeys */ +LONG +WINAPI +OpenHKCRKey( + _In_ HKEY hKey, + _In_ LPCWSTR lpSubKey, + _In_ DWORD ulOptions, + _In_ REGSAM samDesired, + _In_ PHKEY phkResult) +{ + HKEY QueriedKey; + LONG ErrorCode; + + ASSERT(IsHKCRKey(hKey)); + + /* Remove the HKCR flag while we're working */ + hKey = (HKEY)(((ULONG_PTR)hKey) & ~0x2); + + ErrorCode = GetPreferredHKCRKey(hKey, &QueriedKey); + + if (ErrorCode == ERROR_FILE_NOT_FOUND) + { + /* The key doesn't exist on HKCU side, no chance for a subkey */ + ErrorCode = RegOpenKeyExW(hKey, lpSubKey, ulOptions, samDesired, phkResult); + if (ErrorCode == ERROR_SUCCESS) + MakeHKCRKey(phkResult); + return ErrorCode; + } + + if (ErrorCode != ERROR_SUCCESS) + { + /* Somehow we failed for another reason (maybe deleted key or whatever) */ + return ErrorCode; + } + + /* Try on the HKCU side */ + ErrorCode = RegOpenKeyExW(QueriedKey, lpSubKey, ulOptions, samDesired, phkResult); + if (ErrorCode == ERROR_SUCCESS) + MakeHKCRKey(phkResult); + + /* Close it if we must */ + if (QueriedKey != hKey) + { + RegCloseKey(QueriedKey); + } + + /* Anything else than ERROR_FILE_NOT_FOUND means that we found it, even if it is with failures. */ + if (ErrorCode != ERROR_FILE_NOT_FOUND) + return ErrorCode; + + /* If we're here, we must open from HKLM key. */ + ErrorCode = GetFallbackHKCRKey(hKey, &QueriedKey, FALSE); + if (ErrorCode != ERROR_SUCCESS) + { + /* Maybe the key doesn't exist in the HKLM view */ + return ErrorCode; + } + + ErrorCode = RegOpenKeyExW(QueriedKey, lpSubKey, ulOptions, samDesired, phkResult); + if (ErrorCode == ERROR_SUCCESS) + MakeHKCRKey(phkResult); + + /* Close it if we must */ + if (QueriedKey != hKey) + { + RegCloseKey(QueriedKey); + } + + return ErrorCode; +} + +/* HKCR version of RegDeleteKeyExW */ +LONG +WINAPI +DeleteHKCRKey( + _In_ HKEY hKey, + _In_ LPCWSTR lpSubKey, + _In_ REGSAM RegSam, + _In_ DWORD Reserved) +{ + HKEY QueriedKey; + LONG ErrorCode; + + ASSERT(IsHKCRKey(hKey)); + + /* Remove the HKCR flag while we're working */ + hKey = (HKEY)(((ULONG_PTR)hKey) & ~0x2); + + ErrorCode = GetPreferredHKCRKey(hKey, &QueriedKey); + + if (ErrorCode == ERROR_FILE_NOT_FOUND) + { + /* The key doesn't exist on HKCU side, no chance for a subkey */ + return RegDeleteKeyExW(hKey, lpSubKey, RegSam, Reserved); + } + + if (ErrorCode != ERROR_SUCCESS) + { + /* Somehow we failed for another reason (maybe deleted key or whatever) */ + return ErrorCode; + } + + ErrorCode = RegDeleteKeyExW(QueriedKey, lpSubKey, RegSam, Reserved); + + /* Close it if we must */ + if (QueriedKey != hKey) + { + /* The original key is on the machine view */ + RegCloseKey(QueriedKey); + } + + /* Anything else than ERROR_FILE_NOT_FOUND means that we found it, even if it is with failures. */ + if (ErrorCode != ERROR_FILE_NOT_FOUND) + return ErrorCode; + + /* If we're here, we must open from HKLM key. */ + ErrorCode = GetFallbackHKCRKey(hKey, &QueriedKey, FALSE); + if (ErrorCode != ERROR_SUCCESS) + { + /* Maybe the key doesn't exist in the HKLM view */ + return ErrorCode; + } + + ErrorCode = RegDeleteKeyExW(QueriedKey, lpSubKey, RegSam, Reserved); + + /* Close it if we must */ + if (QueriedKey != hKey) + { + RegCloseKey(QueriedKey); + } + + return ErrorCode; +} + +/* HKCR version of RegQueryValueExW */ +LONG +WINAPI +QueryHKCRValue( + _In_ HKEY hKey, + _In_ LPCWSTR Name, + _In_ LPDWORD Reserved, + _In_ LPDWORD Type, + _In_ LPBYTE Data, + _In_ LPDWORD Count) +{ + HKEY QueriedKey; + LONG ErrorCode; + + ASSERT(IsHKCRKey(hKey)); + + /* Remove the HKCR flag while we're working */ + hKey = (HKEY)(((ULONG_PTR)hKey) & ~0x2); + + ErrorCode = GetPreferredHKCRKey(hKey, &QueriedKey); + + if (ErrorCode == ERROR_FILE_NOT_FOUND) + { + /* The key doesn't exist on HKCU side, no chance for a value in it */ + return RegQueryValueExW(hKey, Name, Reserved, Type, Data, Count); + } + + if (ErrorCode != ERROR_SUCCESS) + { + /* Somehow we failed for another reason (maybe deleted key or whatever) */ + return ErrorCode; + } + + ErrorCode = RegQueryValueExW(QueriedKey, Name, Reserved, Type, Data, Count); + + /* Close it if we must */ + if (QueriedKey != hKey) + { + /* The original key is on the machine view */ + RegCloseKey(QueriedKey); + } + + /* Anything else than ERROR_FILE_NOT_FOUND means that we found it, even if it is with failures. */ + if (ErrorCode != ERROR_FILE_NOT_FOUND) + return ErrorCode; + + /* If we're here, we must open from HKLM key. */ + ErrorCode = GetFallbackHKCRKey(hKey, &QueriedKey, FALSE); + if (ErrorCode != ERROR_SUCCESS) + { + /* Maybe the key doesn't exist in the HKLM view */ + return ErrorCode; + } + + ErrorCode = RegQueryValueExW(QueriedKey, Name, Reserved, Type, Data, Count); + + /* Close it if we must */ + if (QueriedKey != hKey) + { + RegCloseKey(QueriedKey); + } + + return ErrorCode; +} + +/* HKCR version of RegSetValueExW */ +LONG +WINAPI +SetHKCRValue( + _In_ HKEY hKey, + _In_ LPCWSTR Name, + _In_ DWORD Reserved, + _In_ DWORD Type, + _In_ CONST BYTE* Data, + _In_ DWORD DataSize) +{ + HKEY QueriedKey; + LONG ErrorCode; + + ASSERT(IsHKCRKey(hKey)); + + /* Remove the HKCR flag while we're working */ + hKey = (HKEY)(((ULONG_PTR)hKey) & ~0x2); + + ErrorCode = GetPreferredHKCRKey(hKey, &QueriedKey); + + if (ErrorCode == ERROR_FILE_NOT_FOUND) + { + /* The key doesn't exist on HKCU side, no chance to put a value in it */ + return RegSetValueExW(hKey, Name, Reserved, Type, Data, DataSize); + } + + if (ErrorCode != ERROR_SUCCESS) + { + /* Somehow we failed for another reason (maybe deleted key or whatever) */ + return ErrorCode; + } + + /* Check if the value already exists in the preferred key */ + ErrorCode = RegQueryValueExW(QueriedKey, Name, NULL, NULL, NULL, NULL); + if (ErrorCode != ERROR_FILE_NOT_FOUND) + { + if (ErrorCode == ERROR_SUCCESS) + { + /* Yes, so we have the right to modify it */ + ErrorCode = RegSetValueExW(QueriedKey, Name, Reserved, Type, Data, DataSize); + } + if (QueriedKey != hKey) + RegCloseKey(QueriedKey); + return ErrorCode; + } + if (QueriedKey != hKey) + RegCloseKey(QueriedKey); + + /* So we must set the value in the HKLM version */ + ErrorCode = GetPreferredHKCRKey(hKey, &QueriedKey); + if (ErrorCode == ERROR_FILE_NOT_FOUND) + { + /* No choice: put this in HKCU */ + return RegSetValueExW(hKey, Name, Reserved, Type, Data, DataSize); + } + else if (ErrorCode != ERROR_SUCCESS) + { + return ErrorCode; + } + + ErrorCode = RegSetValueExW(QueriedKey, Name, Reserved, Type, Data, DataSize); + + if (QueriedKey != hKey) + RegCloseKey(QueriedKey); + + return ErrorCode; +} + +/* HKCR version of RegEnumKeyExW */ +LONG +WINAPI +EnumHKCRKey( + _In_ HKEY hKey, + _In_ DWORD dwIndex, + _Out_ LPWSTR lpName, + _Inout_ LPDWORD lpcbName, + _Reserved_ LPDWORD lpReserved, + _Out_opt_ LPWSTR lpClass, + _Inout_opt_ LPDWORD lpcbClass, + _Out_opt_ PFILETIME lpftLastWriteTime) +{ + HKEY PreferredKey, FallbackKey; + DWORD NumPreferredSubKeys; + DWORD MaxFallbackSubKeyLen; + DWORD FallbackIndex; + WCHAR* FallbackSubKeyName = NULL; + LONG ErrorCode; + + ASSERT(IsHKCRKey(hKey)); + + /* Remove the HKCR flag while we're working */ + hKey = (HKEY)(((ULONG_PTR)hKey) & ~0x2); + + /* Get the preferred key */ + ErrorCode = GetPreferredHKCRKey(hKey, &PreferredKey); + if (ErrorCode != ERROR_SUCCESS) + { + if (ErrorCode == ERROR_FILE_NOT_FOUND) + { + /* Only the HKLM key exists */ + return RegEnumKeyExW( + hKey, + dwIndex, + lpName, + lpcbName, + lpReserved, + lpClass, + lpcbClass, + lpftLastWriteTime); + } + return ErrorCode; + } + + /* Get the fallback key */ + ErrorCode = GetFallbackHKCRKey(hKey, &FallbackKey, FALSE); + if (ErrorCode != ERROR_SUCCESS) + { + if (PreferredKey != hKey) + RegCloseKey(PreferredKey); + if (ErrorCode == ERROR_FILE_NOT_FOUND) + { + /* Only the HKCU key exists */ + return RegEnumKeyExW( + hKey, + dwIndex, + lpName, + lpcbName, + lpReserved, + lpClass, + lpcbClass, + lpftLastWriteTime); + } + return ErrorCode; + } + + /* Get some info on the HKCU side */ + ErrorCode = RegQueryInfoKeyW( + PreferredKey, + NULL, + NULL, + NULL, + &NumPreferredSubKeys, + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, + NULL); + if (ErrorCode != ERROR_SUCCESS) + goto Exit; + + if (dwIndex < NumPreferredSubKeys) + { + /* HKCU side takes precedence */ + ErrorCode = RegEnumKeyExW( + PreferredKey, + dwIndex, + lpName, + lpcbName, + lpReserved, + lpClass, + lpcbClass, + lpftLastWriteTime); + goto Exit; + } + + /* Here it gets tricky. We must enumerate the values from the HKLM side, + * without reporting those which are present on the HKCU side */ + + /* Squash out the indices from HKCU */ + dwIndex -= NumPreferredSubKeys; + + /* Get some info */ + ErrorCode = RegQueryInfoKeyW( + FallbackKey, + NULL, + NULL, + NULL, + NULL, + &MaxFallbackSubKeyLen, + NULL, + NULL, + NULL, + NULL, + NULL, + NULL); + if (ErrorCode != ERROR_SUCCESS) + { + ERR("Could not query info of key %p (Err: %d)\n", FallbackKey, ErrorCode); + goto Exit; + } + + ERR("Maxfallbacksubkeylen: %d\n", MaxFallbackSubKeyLen); + + /* Allocate our buffer */ + FallbackSubKeyName = RtlAllocateHeap( + RtlGetProcessHeap(), 0, (MaxFallbackSubKeyLen + 1) * sizeof(WCHAR)); + if (!FallbackSubKeyName) + { + ErrorCode = ERROR_NOT_ENOUGH_MEMORY; + goto Exit; + } + + /* We must begin at the very first subkey of the fallback key, + * and then see if we meet keys that already are in the preferred key. + * In that case, we must bump dwIndex, as otherwise we would enumerate a key we already + * saw in a previous call. + */ + FallbackIndex = 0; + while (TRUE) + { + HKEY PreferredSubKey; + DWORD FallbackSubkeyLen = MaxFallbackSubKeyLen; + + /* Try enumerating */ + ErrorCode = RegEnumKeyExW( + FallbackKey, + FallbackIndex, + FallbackSubKeyName, + &FallbackSubkeyLen, + NULL, + NULL, + NULL, + NULL); + if (ErrorCode != ERROR_SUCCESS) + { + /* Most likely ERROR_NO_MORE_ITEMS */ + ERR("Returning %d.\n", ErrorCode); + goto Exit; + } + FallbackSubKeyName[FallbackSubkeyLen] = L'\0'; + + /* See if there is such a value on HKCU side */ + ErrorCode = RegOpenKeyExW( + PreferredKey, + FallbackSubKeyName, + 0, + 0, + &PreferredSubKey); + + if (ErrorCode == ERROR_SUCCESS) + { + RegCloseKey(PreferredSubKey); + /* So we already enumerated it on HKCU side. */ + dwIndex++; + } + else if (ErrorCode != ERROR_FILE_NOT_FOUND) + { + ERR("Got error %d while querying for %s on HKCU side.\n", ErrorCode, FallbackSubKeyName); + goto Exit; + } + + /* See if we caught up */ + if (FallbackIndex == dwIndex) + break; + + FallbackIndex++; + } + + /* We can finally enumerate on the fallback side */ + ErrorCode = RegEnumKeyExW( + FallbackKey, + dwIndex, + lpName, + lpcbName, + lpReserved, + lpClass, + lpcbClass, + lpftLastWriteTime); + +Exit: + if (PreferredKey != hKey) + RegCloseKey(PreferredKey); + if (FallbackKey != hKey) + RegCloseKey(FallbackKey); + if (FallbackSubKeyName) + RtlFreeHeap(RtlGetProcessHeap(), 0, FallbackSubKeyName); + + return ErrorCode; +} diff --git a/dll/win32/advapi32/reg/reg.c b/dll/win32/advapi32/reg/reg.c index bd9ae62c9f0..38061cccaaa 100644 --- a/dll/win32/advapi32/reg/reg.c +++ b/dll/win32/advapi32/reg/reg.c @@ -18,6 +18,8 @@ #include #include +#include "reg.h" + WINE_DEFAULT_DEBUG_CHANNEL(reg); /* DEFINES ******************************************************************/ @@ -231,10 +233,11 @@ CloseDefaultKeys(VOID) static NTSTATUS -OpenClassesRootKey(PHANDLE KeyHandle) +OpenClassesRootKey(_Out_ PHANDLE KeyHandle) { OBJECT_ATTRIBUTES Attributes; UNICODE_STRING KeyName = RTL_CONSTANT_STRING(L"\\Registry\\Machine\\Software\\CLASSES"); + NTSTATUS Status; TRACE("OpenClassesRootKey()\n"); @@ -243,9 +246,17 @@ OpenClassesRootKey(PHANDLE KeyHandle) OBJ_CASE_INSENSITIVE, NULL, NULL); - return NtOpenKey(KeyHandle, - MAXIMUM_ALLOWED, - &Attributes); + Status = NtOpenKey(KeyHandle, + MAXIMUM_ALLOWED, + &Attributes); + + if (!NT_SUCCESS(Status)) + return Status; + + /* Mark it as HKCR */ + MakeHKCRKey((HKEY*)KeyHandle); + + return Status; } @@ -1013,75 +1024,58 @@ CreateNestedKey(PHKEY KeyHandle, * @implemented */ LONG WINAPI -RegCreateKeyExA(HKEY hKey, - LPCSTR lpSubKey, - DWORD Reserved, - LPSTR lpClass, - DWORD dwOptions, - REGSAM samDesired, - LPSECURITY_ATTRIBUTES lpSecurityAttributes, - PHKEY phkResult, - LPDWORD lpdwDisposition) +RegCreateKeyExA( + _In_ HKEY hKey, + _In_ LPCSTR lpSubKey, + _In_ DWORD Reserved, + _In_ LPSTR lpClass, + _In_ DWORD dwOptions, + _In_ REGSAM samDesired, + _In_ LPSECURITY_ATTRIBUTES lpSecurityAttributes, + _Out_ PHKEY phkResult, + _Out_ LPDWORD lpdwDisposition) { UNICODE_STRING SubKeyString; UNICODE_STRING ClassString; - OBJECT_ATTRIBUTES ObjectAttributes; - HANDLE ParentKey; - ULONG Attributes = OBJ_CASE_INSENSITIVE; - NTSTATUS Status; + DWORD ErrorCode; - TRACE("RegCreateKeyExA() called\n"); + RtlInitEmptyUnicodeString(&ClassString, NULL, 0); + RtlInitEmptyUnicodeString(&SubKeyString, NULL, 0); - if (lpSecurityAttributes && lpSecurityAttributes->nLength != sizeof(SECURITY_ATTRIBUTES)) - return ERROR_INVALID_USER_BUFFER; - - /* get the real parent key */ - Status = MapDefaultKey(&ParentKey, - hKey); - if (!NT_SUCCESS(Status)) + if (lpClass) { - return RtlNtStatusToDosError(Status); + if (!RtlCreateUnicodeStringFromAsciiz(&ClassString, lpClass)) + { + ErrorCode = ERROR_NOT_ENOUGH_MEMORY; + goto Exit; + } } - TRACE("ParentKey %p\n", ParentKey); - - if (lpClass != NULL) + if (lpSubKey) { - RtlCreateUnicodeStringFromAsciiz(&ClassString, - lpClass); + if (!RtlCreateUnicodeStringFromAsciiz(&SubKeyString, lpSubKey)) + { + ErrorCode = ERROR_NOT_ENOUGH_MEMORY; + goto Exit; + } } - if (dwOptions & REG_OPTION_OPEN_LINK) - Attributes |= OBJ_OPENLINK; + ErrorCode = RegCreateKeyExW( + hKey, + SubKeyString.Buffer, + Reserved, + ClassString.Buffer, + dwOptions, + samDesired, + lpSecurityAttributes, + phkResult, + lpdwDisposition); - RtlCreateUnicodeStringFromAsciiz(&SubKeyString, - (LPSTR)lpSubKey); - InitializeObjectAttributes(&ObjectAttributes, - &SubKeyString, - Attributes, - (HANDLE)ParentKey, - lpSecurityAttributes ? (PSECURITY_DESCRIPTOR)lpSecurityAttributes->lpSecurityDescriptor : NULL); - Status = CreateNestedKey(phkResult, - &ObjectAttributes, - (lpClass == NULL)? NULL : &ClassString, - dwOptions, - samDesired, - lpdwDisposition); +Exit: RtlFreeUnicodeString(&SubKeyString); - if (lpClass != NULL) - { - RtlFreeUnicodeString(&ClassString); - } + RtlFreeUnicodeString(&ClassString); - ClosePredefKey(ParentKey); - - TRACE("Status %x\n", Status); - if (!NT_SUCCESS(Status)) - { - return RtlNtStatusToDosError(Status); - } - - return ERROR_SUCCESS; + return ErrorCode; } @@ -1090,16 +1084,18 @@ RegCreateKeyExA(HKEY hKey, * * @implemented */ -LONG WINAPI -RegCreateKeyExW(HKEY hKey, - LPCWSTR lpSubKey, - DWORD Reserved, - LPWSTR lpClass, - DWORD dwOptions, - REGSAM samDesired, - LPSECURITY_ATTRIBUTES lpSecurityAttributes, - PHKEY phkResult, - LPDWORD lpdwDisposition) +LONG +WINAPI +RegCreateKeyExW( + _In_ HKEY hKey, + _In_ LPCWSTR lpSubKey, + _In_ DWORD Reserved, + _In_opt_ LPWSTR lpClass, + _In_ DWORD dwOptions, + _In_ REGSAM samDesired, + _In_opt_ LPSECURITY_ATTRIBUTES lpSecurityAttributes, + _Out_ PHKEY phkResult, + _Out_opt_ LPDWORD lpdwDisposition) { UNICODE_STRING SubKeyString; UNICODE_STRING ClassString; @@ -1123,6 +1119,22 @@ RegCreateKeyExW(HKEY hKey, TRACE("ParentKey %p\n", ParentKey); + if (IsHKCRKey(ParentKey)) + { + LONG ErrorCode = CreateHKCRKey( + ParentKey, + lpSubKey, + Reserved, + lpClass, + dwOptions, + samDesired, + lpSecurityAttributes, + phkResult, + lpdwDisposition); + ClosePredefKey(ParentKey); + return ErrorCode; + } + if (dwOptions & REG_OPTION_OPEN_LINK) Attributes |= OBJ_OPENLINK; @@ -1203,59 +1215,13 @@ RegCreateKeyW(HKEY hKey, * * @implemented */ -LONG WINAPI -RegDeleteKeyA(HKEY hKey, - LPCSTR lpSubKey) +LONG +WINAPI +RegDeleteKeyA( + _In_ HKEY hKey, + _In_ LPCSTR lpSubKey) { - OBJECT_ATTRIBUTES ObjectAttributes; - UNICODE_STRING SubKeyName; - HANDLE ParentKey; - HANDLE TargetKey; - NTSTATUS Status; - - /* Make sure we got a subkey */ - if (!lpSubKey) - { - /* Fail */ - return ERROR_INVALID_PARAMETER; - } - - Status = MapDefaultKey(&ParentKey, - hKey); - if (!NT_SUCCESS(Status)) - { - return RtlNtStatusToDosError(Status); - } - - RtlCreateUnicodeStringFromAsciiz(&SubKeyName, - (LPSTR)lpSubKey); - InitializeObjectAttributes(&ObjectAttributes, - &SubKeyName, - OBJ_CASE_INSENSITIVE, - ParentKey, - NULL); - - Status = NtOpenKey(&TargetKey, - DELETE, - &ObjectAttributes); - RtlFreeUnicodeString(&SubKeyName); - if (!NT_SUCCESS(Status)) - { - goto Cleanup; - } - - Status = NtDeleteKey(TargetKey); - NtClose (TargetKey); - -Cleanup: - ClosePredefKey(ParentKey); - - if (!NT_SUCCESS(Status)) - { - return RtlNtStatusToDosError(Status); - } - - return ERROR_SUCCESS; + return RegDeleteKeyExA(hKey, lpSubKey, 0, 0); } @@ -1264,57 +1230,13 @@ Cleanup: * * @implemented */ -LONG WINAPI -RegDeleteKeyW(HKEY hKey, - LPCWSTR lpSubKey) +LONG +WINAPI +RegDeleteKeyW( + _In_ HKEY hKey, + _In_ LPCWSTR lpSubKey) { - OBJECT_ATTRIBUTES ObjectAttributes; - UNICODE_STRING SubKeyName; - HANDLE ParentKey; - HANDLE TargetKey; - NTSTATUS Status; - - /* Make sure we got a subkey */ - if (!lpSubKey) - { - /* Fail */ - return ERROR_INVALID_PARAMETER; - } - - Status = MapDefaultKey(&ParentKey, - hKey); - if (!NT_SUCCESS(Status)) - { - return RtlNtStatusToDosError(Status); - } - - RtlInitUnicodeString(&SubKeyName, - (LPWSTR)lpSubKey); - InitializeObjectAttributes(&ObjectAttributes, - &SubKeyName, - OBJ_CASE_INSENSITIVE, - ParentKey, - NULL); - Status = NtOpenKey(&TargetKey, - DELETE, - &ObjectAttributes); - if (!NT_SUCCESS(Status)) - { - goto Cleanup; - } - - Status = NtDeleteKey(TargetKey); - NtClose(TargetKey); - -Cleanup: - ClosePredefKey(ParentKey); - - if (!NT_SUCCESS(Status)) - { - return RtlNtStatusToDosError(Status); - } - - return ERROR_SUCCESS; + return RegDeleteKeyExW(hKey, lpSubKey, 0, 0); } @@ -1325,66 +1247,28 @@ Cleanup: */ LONG WINAPI -RegDeleteKeyExA(HKEY hKey, - LPCSTR lpSubKey, - REGSAM samDesired, - DWORD Reserved) +RegDeleteKeyExA( + _In_ HKEY hKey, + _In_ LPCSTR lpSubKey, + _In_ REGSAM samDesired, + _In_ DWORD Reserved) { - OBJECT_ATTRIBUTES ObjectAttributes; + LONG ErrorCode; UNICODE_STRING SubKeyName; - HANDLE ParentKey; - HANDLE TargetKey; - NTSTATUS Status; - /* Make sure we got a subkey */ - if (!lpSubKey) + if (lpSubKey) { - /* Fail */ - return ERROR_INVALID_PARAMETER; + if (!RtlCreateUnicodeStringFromAsciiz(&SubKeyName, lpSubKey)) + return ERROR_NOT_ENOUGH_MEMORY; } + else + RtlInitEmptyUnicodeString(&SubKeyName, NULL, 0); - Status = MapDefaultKey(&ParentKey, - hKey); - if (!NT_SUCCESS(Status)) - { - return RtlNtStatusToDosError(Status); - } + ErrorCode = RegDeleteKeyExW(hKey, SubKeyName.Buffer, samDesired, Reserved); - if (samDesired & KEY_WOW64_32KEY) - ERR("Wow64 not yet supported!\n"); - - if (samDesired & KEY_WOW64_64KEY) - ERR("Wow64 not yet supported!\n"); - - RtlCreateUnicodeStringFromAsciiz(&SubKeyName, - (LPSTR)lpSubKey); - InitializeObjectAttributes(&ObjectAttributes, - &SubKeyName, - OBJ_CASE_INSENSITIVE, - ParentKey, - NULL); - - Status = NtOpenKey(&TargetKey, - DELETE, - &ObjectAttributes); RtlFreeUnicodeString(&SubKeyName); - if (!NT_SUCCESS(Status)) - { - goto Cleanup; - } - Status = NtDeleteKey(TargetKey); - NtClose (TargetKey); - -Cleanup: - ClosePredefKey(ParentKey); - - if (!NT_SUCCESS(Status)) - { - return RtlNtStatusToDosError(Status); - } - - return ERROR_SUCCESS; + return ErrorCode; } @@ -1395,10 +1279,11 @@ Cleanup: */ LONG WINAPI -RegDeleteKeyExW(HKEY hKey, - LPCWSTR lpSubKey, - REGSAM samDesired, - DWORD Reserved) +RegDeleteKeyExW( + _In_ HKEY hKey, + _In_ LPCWSTR lpSubKey, + _In_ REGSAM samDesired, + _In_ DWORD Reserved) { OBJECT_ATTRIBUTES ObjectAttributes; UNICODE_STRING SubKeyName; @@ -1420,6 +1305,13 @@ RegDeleteKeyExW(HKEY hKey, return RtlNtStatusToDosError(Status); } + if (IsHKCRKey(ParentKey)) + { + LONG ErrorCode = DeleteHKCRKey(ParentKey, lpSubKey, samDesired, Reserved); + ClosePredefKey(ParentKey); + return ErrorCode; + } + if (samDesired & KEY_WOW64_32KEY) ERR("Wow64 not yet supported!\n"); @@ -2554,166 +2446,81 @@ RegEnumKeyW(HKEY hKey, * * @implemented */ -LONG WINAPI -RegEnumKeyExA(HKEY hKey, - DWORD dwIndex, - LPSTR lpName, - LPDWORD lpcbName, - LPDWORD lpReserved, - LPSTR lpClass, - LPDWORD lpcbClass, - PFILETIME lpftLastWriteTime) +LONG +WINAPI +RegEnumKeyExA( + _In_ HKEY hKey, + _In_ DWORD dwIndex, + _Out_ LPSTR lpName, + _Inout_ LPDWORD lpcbName, + _Reserved_ LPDWORD lpReserved, + _Out_opt_ LPSTR lpClass, + _Inout_opt_ LPDWORD lpcbClass, + _Out_opt_ PFILETIME lpftLastWriteTime) { - union - { - KEY_NODE_INFORMATION Node; - KEY_BASIC_INFORMATION Basic; - } *KeyInfo; - - UNICODE_STRING StringU; - ANSI_STRING StringA; - LONG ErrorCode = ERROR_SUCCESS; - DWORD NameLength; - DWORD ClassLength = 0; - DWORD BufferSize; - ULONG ResultSize; - HANDLE KeyHandle; - NTSTATUS Status; - - TRACE("RegEnumKeyExA(hKey 0x%x, dwIndex %d, lpName 0x%x, *lpcbName %d, lpClass 0x%x, lpcbClass %d)\n", - hKey, dwIndex, lpName, *lpcbName, lpClass, lpcbClass ? *lpcbClass : 0); - - if ((lpClass) && (!lpcbClass)) - { - return ERROR_INVALID_PARAMETER; - } - - Status = MapDefaultKey(&KeyHandle, hKey); - if (!NT_SUCCESS(Status)) - { - return RtlNtStatusToDosError(Status); - } + WCHAR* NameBuffer = NULL; + WCHAR* ClassBuffer = NULL; + DWORD NameLength, ClassLength; + LONG ErrorCode; + /* Allocate our buffers */ if (*lpcbName > 0) { - NameLength = min (*lpcbName - 1 , REG_MAX_NAME_SIZE) * sizeof (WCHAR); - } - else - { - NameLength = 0; + NameLength = *lpcbName; + NameBuffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, *lpcbName * sizeof(WCHAR)); + if (NameBuffer == NULL) + { + ErrorCode = ERROR_NOT_ENOUGH_MEMORY; + goto Exit; + } } if (lpClass) { if (*lpcbClass > 0) { - ClassLength = min (*lpcbClass -1, REG_MAX_NAME_SIZE) * sizeof(WCHAR); + ClassLength = *lpcbClass; + ClassBuffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, *lpcbClass * sizeof(WCHAR)); + if (ClassBuffer == NULL) + { + ErrorCode = ERROR_NOT_ENOUGH_MEMORY; + goto Exit; + } } - else - { - ClassLength = 0; - } - - /* The class name should start at a dword boundary */ - BufferSize = ((sizeof(KEY_NODE_INFORMATION) + NameLength + 3) & ~3) + ClassLength; } - else + + /* Do the actual call */ + ErrorCode = RegEnumKeyExW( + hKey, + dwIndex, + NameBuffer, + lpcbName, + lpReserved, + ClassBuffer, + lpcbClass, + lpftLastWriteTime); + + if (ErrorCode != ERROR_SUCCESS) + goto Exit; + + /* Convert the strings */ + RtlUnicodeToMultiByteN(lpName, *lpcbName, 0, NameBuffer, *lpcbName * sizeof(WCHAR)); + /* NULL terminate if we can */ + if (NameLength > *lpcbName) + lpName[*lpcbName] = '\0'; + + if (lpClass) { - BufferSize = sizeof(KEY_BASIC_INFORMATION) + NameLength; + RtlUnicodeToMultiByteN(lpClass, *lpcbClass, 0, NameBuffer, *lpcbClass * sizeof(WCHAR)); + if (ClassLength > *lpcbClass) + lpClass[*lpcbClass] = '\0'; } - KeyInfo = RtlAllocateHeap (ProcessHeap, 0, BufferSize); - if (KeyInfo == NULL) - { - ErrorCode = ERROR_OUTOFMEMORY; - goto Cleanup; - } - - Status = NtEnumerateKey(KeyHandle, - (ULONG)dwIndex, - lpClass == NULL ? KeyBasicInformation : KeyNodeInformation, - KeyInfo, - BufferSize, - &ResultSize); - TRACE("NtEnumerateKey() returned status 0x%X\n", Status); - if (!NT_SUCCESS(Status)) - { - ErrorCode = RtlNtStatusToDosError (Status); - } - else - { - if (lpClass == NULL) - { - if (KeyInfo->Basic.NameLength > NameLength) - { - ErrorCode = ERROR_BUFFER_OVERFLOW; - } - else - { - StringU.Buffer = KeyInfo->Basic.Name; - StringU.Length = KeyInfo->Basic.NameLength; - StringU.MaximumLength = KeyInfo->Basic.NameLength; - } - } - else - { - if (KeyInfo->Node.NameLength > NameLength || - KeyInfo->Node.ClassLength > ClassLength) - { - ErrorCode = ERROR_BUFFER_OVERFLOW; - } - else - { - StringA.Buffer = lpClass; - StringA.Length = 0; - StringA.MaximumLength = *lpcbClass; - StringU.Buffer = (PWCHAR)((ULONG_PTR)KeyInfo->Node.Name + KeyInfo->Node.ClassOffset); - StringU.Length = KeyInfo->Node.ClassLength; - StringU.MaximumLength = KeyInfo->Node.ClassLength; - RtlUnicodeStringToAnsiString (&StringA, &StringU, FALSE); - lpClass[StringA.Length] = 0; - *lpcbClass = StringA.Length; - StringU.Buffer = KeyInfo->Node.Name; - StringU.Length = KeyInfo->Node.NameLength; - StringU.MaximumLength = KeyInfo->Node.NameLength; - } - } - - if (ErrorCode == ERROR_SUCCESS) - { - StringA.Buffer = lpName; - StringA.Length = 0; - StringA.MaximumLength = *lpcbName; - RtlUnicodeStringToAnsiString (&StringA, &StringU, FALSE); - lpName[StringA.Length] = 0; - *lpcbName = StringA.Length; - if (lpftLastWriteTime != NULL) - { - if (lpClass == NULL) - { - lpftLastWriteTime->dwLowDateTime = KeyInfo->Basic.LastWriteTime.u.LowPart; - lpftLastWriteTime->dwHighDateTime = KeyInfo->Basic.LastWriteTime.u.HighPart; - } - else - { - lpftLastWriteTime->dwLowDateTime = KeyInfo->Node.LastWriteTime.u.LowPart; - lpftLastWriteTime->dwHighDateTime = KeyInfo->Node.LastWriteTime.u.HighPart; - } - } - } - } - - /*TRACE("Key Namea0 Length %d\n", StringU.Length);*/ /* BUGBUG could be uninitialized */ - TRACE("Key Name1 Length %d\n", NameLength); - TRACE("Key Name Length %d\n", *lpcbName); - TRACE("Key Name %s\n", lpName); - - RtlFreeHeap(ProcessHeap, - 0, - KeyInfo); - -Cleanup: - ClosePredefKey(KeyHandle); +Exit: + if (NameBuffer) + RtlFreeHeap(RtlGetProcessHeap(), 0, NameBuffer); + if (ClassBuffer) + RtlFreeHeap(RtlGetProcessHeap(), 0, ClassBuffer); return ErrorCode; } @@ -2724,15 +2531,17 @@ Cleanup: * * @implemented */ -LONG WINAPI -RegEnumKeyExW(HKEY hKey, - DWORD dwIndex, - LPWSTR lpName, - LPDWORD lpcbName, - LPDWORD lpReserved, - LPWSTR lpClass, - LPDWORD lpcbClass, - PFILETIME lpftLastWriteTime) +LONG +WINAPI +RegEnumKeyExW( + _In_ HKEY hKey, + _In_ DWORD dwIndex, + _Out_ LPWSTR lpName, + _Inout_ LPDWORD lpcbName, + _Reserved_ LPDWORD lpReserved, + _Out_opt_ LPWSTR lpClass, + _Inout_opt_ LPDWORD lpcbClass, + _Out_opt_ PFILETIME lpftLastWriteTime) { union { @@ -2755,6 +2564,21 @@ RegEnumKeyExW(HKEY hKey, return RtlNtStatusToDosError(Status); } + if (IsHKCRKey(KeyHandle)) + { + ErrorCode = EnumHKCRKey( + KeyHandle, + dwIndex, + lpName, + lpcbName, + lpReserved, + lpClass, + lpcbClass, + lpftLastWriteTime); + ClosePredefKey(KeyHandle); + return ErrorCode; + } + if (*lpcbName > 0) { NameLength = min (*lpcbName - 1, REG_MAX_NAME_SIZE) * sizeof (WCHAR); @@ -2873,120 +2697,139 @@ Cleanup: * @implemented */ LONG WINAPI -RegEnumValueA(HKEY hKey, - DWORD index, - LPSTR value, - LPDWORD val_count, - LPDWORD reserved, - LPDWORD type, - LPBYTE data, - LPDWORD count) +RegEnumValueA( + _In_ HKEY hKey, + _In_ DWORD dwIndex, + _Out_ LPSTR lpName, + _Inout_ LPDWORD lpcbName, + _Reserved_ LPDWORD lpdwReserved, + _Out_opt_ LPDWORD lpdwType, + _Out_opt_ LPBYTE lpData, + _Out_opt_ LPDWORD lpcbData) { - HANDLE KeyHandle; - NTSTATUS status; - ULONG total_size; - char buffer[256], *buf_ptr = buffer; - KEY_VALUE_FULL_INFORMATION *info = (KEY_VALUE_FULL_INFORMATION *)buffer; - static const int info_size = FIELD_OFFSET( KEY_VALUE_FULL_INFORMATION, Name ); + WCHAR* NameBuffer; + DWORD NameBufferSize, NameLength; + LONG ErrorCode; + DWORD LocalType = REG_NONE; + BOOL NameOverflow = FALSE; - //TRACE("(%p,%ld,%p,%p,%p,%p,%p,%p)\n", - // hkey, index, value, val_count, reserved, type, data, count ); - - /* NT only checks count, not val_count */ - if ((data && !count) || reserved) + /* Do parameter checks now, once and for all. */ + if ((lpData && !lpcbData) || lpdwReserved) return ERROR_INVALID_PARAMETER; - status = MapDefaultKey(&KeyHandle, hKey); - if (!NT_SUCCESS(status)) + /* Get the size of the buffer we must use for the first call ro RegEnumValueW */ + ErrorCode = RegQueryInfoKeyW( + hKey, NULL, NULL, NULL, NULL, NULL, NULL, NULL, &NameBufferSize, NULL, NULL, NULL); + if (ErrorCode != ERROR_SUCCESS) + return ErrorCode; + + /* Allocate the buffer for the unicode name */ + NameBuffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, NameBufferSize * sizeof(WCHAR)); + if (NameBuffer == NULL) { - return RtlNtStatusToDosError(status); + return ERROR_NOT_ENOUGH_MEMORY; } - total_size = info_size + (MAX_PATH + 1) * sizeof(WCHAR); - if (data) total_size += *count; - total_size = min( sizeof(buffer), total_size ); - - status = NtEnumerateValueKey( KeyHandle, index, KeyValueFullInformation, - buffer, total_size, &total_size ); - if (status && (status != STATUS_BUFFER_OVERFLOW) && (status != STATUS_BUFFER_TOO_SMALL)) goto done; - - /* we need to fetch the contents for a string type even if not requested, - * because we need to compute the length of the ASCII string. */ - if (value || data || is_string(info->Type)) + /* + * This code calls RegEnumValueW twice, because we need to know the type of the enumerated value. + * So for the first call, we check if we overflow on the name, as we have no way of knowing if this + * is an overflow on the data or on the name during the the second call. So the first time, we make the + * call with the supplied value. This is merdique, but this is how it is. + */ + NameLength = *lpcbName; + ErrorCode = RegEnumValueW( + hKey, + dwIndex, + NameBuffer, + &NameLength, + NULL, + &LocalType, + NULL, + NULL); + if (ErrorCode != ERROR_SUCCESS) { - /* retry with a dynamically allocated buffer */ - while ((status == STATUS_BUFFER_OVERFLOW) || (status == STATUS_BUFFER_TOO_SMALL)) + if (ErrorCode == ERROR_MORE_DATA) + NameOverflow = TRUE; + else + goto Exit; + } + + if (is_string(LocalType) && lpcbData) + { + /* We must allocate a buffer to get the unicode data */ + DWORD DataBufferSize = *lpcbData * sizeof(WCHAR); + WCHAR* DataBuffer = NULL; + DWORD DataLength = *lpcbData; + LPSTR DataStr = (LPSTR)lpData; + + if (lpData) + DataBuffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, *lpcbData * sizeof(WCHAR)); + + /* Do the real call */ + ErrorCode = RegEnumValueW( + hKey, + dwIndex, + NameBuffer, + &NameBufferSize, + lpdwReserved, + lpdwType, + (LPBYTE)DataBuffer, + &DataBufferSize); + + *lpcbData = DataBufferSize / sizeof(WCHAR); + + if (ErrorCode != ERROR_SUCCESS) { - if (buf_ptr != buffer) HeapFree( GetProcessHeap(), 0, buf_ptr ); - if (!(buf_ptr = HeapAlloc( GetProcessHeap(), 0, total_size ))) - { - status = STATUS_INSUFFICIENT_RESOURCES; - goto done; - } - info = (KEY_VALUE_FULL_INFORMATION *)buf_ptr; - status = NtEnumerateValueKey( KeyHandle, index, KeyValueFullInformation, - buf_ptr, total_size, &total_size ); + RtlFreeHeap(RtlGetProcessHeap(), 0, DataBuffer); + goto Exit; } - if (status) goto done; - - if (is_string(info->Type)) + /* Copy the data whatever the error code is */ + if (lpData) { - ULONG len; - RtlUnicodeToMultiByteSize( &len, (WCHAR *)(buf_ptr + info->DataOffset), - info->DataLength ); - if (data && len) - { - if (len > *count) status = STATUS_BUFFER_OVERFLOW; - else - { - RtlUnicodeToMultiByteN( (PCHAR)data, len, NULL, (WCHAR *)(buf_ptr + info->DataOffset), - info->DataLength ); - /* if the type is REG_SZ and data is not 0-terminated - * and there is enough space in the buffer NT appends a \0 */ - if (len < *count && data[len-1]) data[len] = 0; - } - } - info->DataLength = len; - } - else if (data) - { - if (info->DataLength > *count) status = STATUS_BUFFER_OVERFLOW; - else memcpy( data, buf_ptr + info->DataOffset, info->DataLength ); + /* Do the data conversion */ + RtlUnicodeToMultiByteN(DataStr, DataLength, 0, DataBuffer, DataBufferSize); + /* NULL-terminate if there is enough room */ + if ((DataLength > *lpcbData) && (DataStr[*lpcbData - 1] != '\0')) + DataStr[*lpcbData] = '\0'; } - if (value && !status) - { - ULONG len; + RtlFreeHeap(RtlGetProcessHeap(), 0, DataBuffer); + } + else + { + /* No data conversion needed. Do the call with provided buffers */ + ErrorCode = RegEnumValueW( + hKey, + dwIndex, + NameBuffer, + &NameBufferSize, + lpdwReserved, + lpdwType, + lpData, + lpcbData); - RtlUnicodeToMultiByteSize( &len, info->Name, info->NameLength ); - if (len >= *val_count) - { - status = STATUS_BUFFER_OVERFLOW; - if (*val_count) - { - len = *val_count - 1; - RtlUnicodeToMultiByteN( value, len, NULL, info->Name, info->NameLength ); - value[len] = 0; - } - } - else - { - RtlUnicodeToMultiByteN( value, len, NULL, info->Name, info->NameLength ); - value[len] = 0; - *val_count = len; - } + if (ErrorCode != ERROR_SUCCESS) + { + goto Exit; } } - else status = STATUS_SUCCESS; - if (type) *type = info->Type; - if (count) *count = info->DataLength; + if (NameOverflow) + { + ErrorCode = ERROR_MORE_DATA; + goto Exit; + } - done: - if (buf_ptr != buffer) HeapFree( GetProcessHeap(), 0, buf_ptr ); - ClosePredefKey(KeyHandle); - return RtlNtStatusToDosError(status); + /* Convert the name string */ + RtlUnicodeToMultiByteN(lpName, *lpcbName, lpcbName, NameBuffer, NameBufferSize * sizeof(WCHAR)); + ((PSTR)lpName)[*lpcbName] = '\0'; + +Exit: + if (NameBuffer) + RtlFreeHeap(RtlGetProcessHeap(), 0, NameBuffer); + + return ErrorCode; } @@ -3200,15 +3043,32 @@ RegLoadKeyA(HKEY hKey, UNICODE_STRING KeyName; LONG ErrorCode; - RtlCreateUnicodeStringFromAsciiz(&KeyName, - (LPSTR)lpSubKey); - RtlCreateUnicodeStringFromAsciiz(&FileName, - (LPSTR)lpFile); + RtlInitEmptyUnicodeString(&KeyName, NULL, 0); + RtlInitEmptyUnicodeString(&FileName, NULL, 0); + + if (lpSubKey) + { + if (!RtlCreateUnicodeStringFromAsciiz(&KeyName, lpSubKey)) + { + ErrorCode = ERROR_NOT_ENOUGH_MEMORY; + goto Exit; + } + } + + if (lpFile) + { + if (!RtlCreateUnicodeStringFromAsciiz(&FileName, lpFile)) + { + ErrorCode = ERROR_NOT_ENOUGH_MEMORY; + goto Exit; + } + } ErrorCode = RegLoadKeyW(hKey, KeyName.Buffer, FileName.Buffer); +Exit: RtlFreeUnicodeString(&FileName); RtlFreeUnicodeString(&KeyName); @@ -3452,54 +3312,30 @@ RegOpenKeyW(HKEY hKey, * @implemented */ LONG WINAPI -RegOpenKeyExA(HKEY hKey, - LPCSTR lpSubKey, - DWORD ulOptions, - REGSAM samDesired, - PHKEY phkResult) +RegOpenKeyExA( + _In_ HKEY hKey, + _In_ LPCSTR lpSubKey, + _In_ DWORD ulOptions, + _In_ REGSAM samDesired, + _Out_ PHKEY phkResult) { - OBJECT_ATTRIBUTES ObjectAttributes; UNICODE_STRING SubKeyString; - HANDLE KeyHandle; - NTSTATUS Status; - ULONG Attributes = OBJ_CASE_INSENSITIVE; - LONG ErrorCode = ERROR_SUCCESS; + LONG ErrorCode; TRACE("RegOpenKeyExA hKey 0x%x lpSubKey %s ulOptions 0x%x samDesired 0x%x phkResult %p\n", hKey, lpSubKey, ulOptions, samDesired, phkResult); - if (!phkResult) + + if (lpSubKey) { - return ERROR_INVALID_PARAMETER; + if (!RtlCreateUnicodeStringFromAsciiz(&SubKeyString, lpSubKey)) + return ERROR_NOT_ENOUGH_MEMORY; } + else + RtlInitEmptyUnicodeString(&SubKeyString, NULL, 0); - Status = MapDefaultKey(&KeyHandle, - hKey); - if (!NT_SUCCESS(Status)) - { - return RtlNtStatusToDosError(Status); - } + ErrorCode = RegOpenKeyExW(hKey, SubKeyString.Buffer, ulOptions, samDesired, phkResult); - if (ulOptions & REG_OPTION_OPEN_LINK) - Attributes |= OBJ_OPENLINK; - - RtlCreateUnicodeStringFromAsciiz(&SubKeyString, - (LPSTR)lpSubKey); - InitializeObjectAttributes(&ObjectAttributes, - &SubKeyString, - Attributes, - KeyHandle, - NULL); - - Status = NtOpenKey((PHANDLE)phkResult, - samDesired, - &ObjectAttributes); RtlFreeUnicodeString(&SubKeyString); - if (!NT_SUCCESS(Status)) - { - ErrorCode = RtlNtStatusToDosError(Status); - } - - ClosePredefKey(KeyHandle); return ErrorCode; } @@ -3537,6 +3373,13 @@ RegOpenKeyExW(HKEY hKey, return RtlNtStatusToDosError(Status); } + if (IsHKCRKey(KeyHandle)) + { + ErrorCode = OpenHKCRKey(KeyHandle, lpSubKey, ulOptions, samDesired, phkResult); + ClosePredefKey(KeyHandle); + return ErrorCode; + } + if (ulOptions & REG_OPTION_OPEN_LINK) Attributes |= OBJ_OPENLINK; @@ -3554,11 +3397,13 @@ RegOpenKeyExW(HKEY hKey, Status = NtOpenKey((PHANDLE)phkResult, samDesired, &ObjectAttributes); + if (!NT_SUCCESS(Status)) { ErrorCode = RtlNtStatusToDosError(Status); } + ClosePredefKey(KeyHandle); return ErrorCode; @@ -4118,102 +3963,89 @@ RegQueryReflectionKey(IN HKEY hBase, */ LONG WINAPI -RegQueryValueExA(HKEY hkeyorg, - LPCSTR name, - LPDWORD reserved, - LPDWORD type, - LPBYTE data, - LPDWORD count) +RegQueryValueExA( + _In_ HKEY hkeyorg, + _In_ LPCSTR name, + _In_ LPDWORD reserved, + _Out_opt_ LPDWORD type, + _Out_opt_ LPBYTE data, + _Inout_opt_ LPDWORD count) { - HANDLE hkey; - NTSTATUS status; - ANSI_STRING nameA; UNICODE_STRING nameW; - DWORD total_size, datalen = 0; - char buffer[256], *buf_ptr = buffer; - KEY_VALUE_PARTIAL_INFORMATION *info = (KEY_VALUE_PARTIAL_INFORMATION *)buffer; - static const int info_size = offsetof( KEY_VALUE_PARTIAL_INFORMATION, Data ); + DWORD DataLength; + DWORD ErrorCode; + DWORD BufferSize = 0; + WCHAR* Buffer; + CHAR* DataStr = (CHAR*)data; + DWORD LocalType; - TRACE("(%p,%s,%p,%p,%p,%p=%d)\n", - hkeyorg, debugstr_a(name), reserved, type, data, count, count ? *count : 0 ); + /* Validate those parameters, the rest will be done with the first RegQueryValueExW call */ + if ((data && !count) || reserved) + return ERROR_INVALID_PARAMETER; - if ((data && !count) || reserved) return ERROR_INVALID_PARAMETER; - status = MapDefaultKey(&hkey, hkeyorg); - if (!NT_SUCCESS(status)) + if (name) { - return RtlNtStatusToDosError(status); + if (!RtlCreateUnicodeStringFromAsciiz(&nameW, name)) + return ERROR_NOT_ENOUGH_MEMORY; + } + else + RtlInitEmptyUnicodeString(&nameW, NULL, 0); + + ErrorCode = RegQueryValueExW(hkeyorg, nameW.Buffer, NULL, &LocalType, NULL, &BufferSize); + if (ErrorCode != ERROR_SUCCESS) + { + if ((!data) && count) + *count = 0; + RtlFreeUnicodeString(&nameW); + return ErrorCode; } - if (count) datalen = *count; - if (!data && count) *count = 0; - - RtlInitAnsiString( &nameA, name ); - if ((status = RtlAnsiStringToUnicodeString( &nameW, &nameA, TRUE ))) + /* See if we can directly handle the call without caring for conversion */ + if (!is_string(LocalType) || !count) { - ClosePredefKey(hkey); - return RtlNtStatusToDosError(status); + ErrorCode = RegQueryValueExW(hkeyorg, nameW.Buffer, reserved, type, data, count); + RtlFreeUnicodeString(&nameW); + return ErrorCode; } - status = NtQueryValueKey( hkey, &nameW, KeyValuePartialInformation, - buffer, sizeof(buffer), &total_size ); - if (status && status != STATUS_BUFFER_OVERFLOW) goto done; - - /* we need to fetch the contents for a string type even if not requested, - * because we need to compute the length of the ASCII string. */ - if (data || is_string(info->Type)) + /* Allocate a unicode string to get the data */ + Buffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, BufferSize); + if (!Buffer) { - /* retry with a dynamically allocated buffer */ - while (status == STATUS_BUFFER_OVERFLOW) - { - if (buf_ptr != buffer) HeapFree( GetProcessHeap(), 0, buf_ptr ); - if (!(buf_ptr = HeapAlloc( GetProcessHeap(), 0, total_size ))) - { - status = STATUS_NO_MEMORY; - goto done; - } - info = (KEY_VALUE_PARTIAL_INFORMATION *)buf_ptr; - status = NtQueryValueKey( hkey, &nameW, KeyValuePartialInformation, - buf_ptr, total_size, &total_size ); - } - - if (status) goto done; - - if (is_string(info->Type)) - { - DWORD len; - - RtlUnicodeToMultiByteSize( &len, (WCHAR *)(buf_ptr + info_size), - total_size - info_size ); - if (data && len) - { - if (len > datalen) status = STATUS_BUFFER_OVERFLOW; - else - { - RtlUnicodeToMultiByteN( (char*)data, len, NULL, (WCHAR *)(buf_ptr + info_size), - total_size - info_size ); - /* if the type is REG_SZ and data is not 0-terminated - * and there is enough space in the buffer NT appends a \0 */ - if (len < datalen && data[len-1]) data[len] = 0; - } - } - total_size = len + info_size; - } - else if (data) - { - if (total_size - info_size > datalen) status = STATUS_BUFFER_OVERFLOW; - else memcpy( data, buf_ptr + info_size, total_size - info_size ); - } + RtlFreeUnicodeString(&nameW); + return ERROR_NOT_ENOUGH_MEMORY; } - else status = STATUS_SUCCESS; - if (type) *type = info->Type; - if (count) *count = total_size - info_size; + ErrorCode = RegQueryValueExW(hkeyorg, nameW.Buffer, reserved, type, (LPBYTE)Buffer, &BufferSize); + if (ErrorCode != ERROR_SUCCESS) + { + RtlFreeHeap(RtlGetProcessHeap(), 0, Buffer); + RtlFreeUnicodeString(&nameW); + return ErrorCode; + } - done: - if (buf_ptr != buffer) HeapFree( GetProcessHeap(), 0, buf_ptr ); - RtlFreeUnicodeString( &nameW ); - ClosePredefKey(hkey); - return RtlNtStatusToDosError(status); + /* We don't need this anymore */ + RtlFreeUnicodeString(&nameW); + + DataLength = *count; + RtlUnicodeToMultiByteSize(count, Buffer, BufferSize); + + if ((!data) || (DataLength < *count)) + { + RtlFreeHeap(RtlGetProcessHeap(), 0, Buffer); + return data ? ERROR_MORE_DATA : ERROR_SUCCESS; + } + + /* We can finally do the conversion */ + RtlUnicodeToMultiByteN(DataStr, DataLength, NULL, Buffer, BufferSize); + + /* NULL-terminate if there is enough room */ + if ((DataLength > *count) && (DataStr[*count - 1] != '\0')) + DataStr[*count] = '\0'; + + RtlFreeHeap(RtlGetProcessHeap(), 0, Buffer); + + return ERROR_SUCCESS; } @@ -4224,12 +4056,13 @@ RegQueryValueExA(HKEY hkeyorg, */ LONG WINAPI -RegQueryValueExW(HKEY hkeyorg, - LPCWSTR name, - LPDWORD reserved, - LPDWORD type, - LPBYTE data, - LPDWORD count) +RegQueryValueExW( + _In_ HKEY hkeyorg, + _In_ LPCWSTR name, + _In_ LPDWORD reserved, + _In_ LPDWORD type, + _In_ LPBYTE data, + _In_ LPDWORD count) { HANDLE hkey; NTSTATUS status; @@ -4251,6 +4084,13 @@ RegQueryValueExW(HKEY hkeyorg, return RtlNtStatusToDosError(status); } + if (IsHKCRKey(hkey)) + { + LONG ErrorCode = QueryHKCRValue(hkey, name, reserved, type, data, count); + ClosePredefKey(hkey); + return ErrorCode; + } + RtlInitUnicodeString( &name_str, name ); if (data) total_size = min( sizeof(buffer), *count + info_size ); @@ -4397,18 +4237,43 @@ RegReplaceKeyA(HKEY hKey, UNICODE_STRING OldFile; LONG ErrorCode; - RtlCreateUnicodeStringFromAsciiz(&SubKey, - (PCSZ)lpSubKey); - RtlCreateUnicodeStringFromAsciiz(&OldFile, - (PCSZ)lpOldFile); - RtlCreateUnicodeStringFromAsciiz(&NewFile, - (PCSZ)lpNewFile); + RtlInitEmptyUnicodeString(&SubKey, NULL, 0); + RtlInitEmptyUnicodeString(&OldFile, NULL, 0); + RtlInitEmptyUnicodeString(&NewFile, NULL, 0); + + if (lpSubKey) + { + if (!RtlCreateUnicodeStringFromAsciiz(&SubKey, lpSubKey)) + { + ErrorCode = ERROR_NOT_ENOUGH_MEMORY; + goto Exit; + } + } + + if (lpOldFile) + { + if (!RtlCreateUnicodeStringFromAsciiz(&OldFile, lpOldFile)) + { + ErrorCode = ERROR_NOT_ENOUGH_MEMORY; + goto Exit; + } + } + + if (lpNewFile) + { + if (!RtlCreateUnicodeStringFromAsciiz(&NewFile, lpNewFile)) + { + ErrorCode = ERROR_NOT_ENOUGH_MEMORY; + goto Exit; + } + } ErrorCode = RegReplaceKeyW(hKey, SubKey.Buffer, NewFile.Buffer, OldFile.Buffer); +Exit: RtlFreeUnicodeString(&OldFile); RtlFreeUnicodeString(&NewFile); RtlFreeUnicodeString(&SubKey); @@ -4565,8 +4430,13 @@ RegRestoreKeyA(HKEY hKey, UNICODE_STRING FileName; LONG ErrorCode; - RtlCreateUnicodeStringFromAsciiz(&FileName, - (PCSZ)lpFile); + if (lpFile) + { + if (!RtlCreateUnicodeStringFromAsciiz(&FileName, lpFile)) + return ERROR_NOT_ENOUGH_MEMORY; + } + else + RtlInitEmptyUnicodeString(&FileName, NULL, 0); ErrorCode = RegRestoreKeyW(hKey, FileName.Buffer, @@ -4666,8 +4536,14 @@ RegSaveKeyA(HKEY hKey, UNICODE_STRING FileName; LONG ErrorCode; - RtlCreateUnicodeStringFromAsciiz(&FileName, - (LPSTR)lpFile); + if (lpFile) + { + if (!RtlCreateUnicodeStringFromAsciiz(&FileName, lpFile)) + return ERROR_NOT_ENOUGH_MEMORY; + } + else + RtlInitEmptyUnicodeString(&FileName, NULL, 0); + ErrorCode = RegSaveKeyW(hKey, FileName.Buffer, lpSecurityAttributes); @@ -4771,8 +4647,14 @@ RegSaveKeyExA(HKEY hKey, UNICODE_STRING FileName; LONG ErrorCode; - RtlCreateUnicodeStringFromAsciiz(&FileName, - (LPSTR)lpFile); + if (lpFile) + { + if (!RtlCreateUnicodeStringFromAsciiz(&FileName, lpFile)) + return ERROR_NOT_ENOUGH_MEMORY; + } + else + RtlInitEmptyUnicodeString(&FileName, NULL, 0); + ErrorCode = RegSaveKeyExW(hKey, FileName.Buffer, lpSecurityAttributes, @@ -4943,18 +4825,34 @@ RegSetValueExA(HKEY hKey, * * @implemented */ -LONG WINAPI -RegSetValueExW(HKEY hKey, - LPCWSTR lpValueName, - DWORD Reserved, - DWORD dwType, - CONST BYTE* lpData, - DWORD cbData) +LONG +WINAPI +RegSetValueExW( + _In_ HKEY hKey, + _In_ LPCWSTR lpValueName, + _In_ DWORD Reserved, + _In_ DWORD dwType, + _In_ CONST BYTE* lpData, + _In_ DWORD cbData) { UNICODE_STRING ValueName; HANDLE KeyHandle; NTSTATUS Status; + Status = MapDefaultKey(&KeyHandle, + hKey); + if (!NT_SUCCESS(Status)) + { + return RtlNtStatusToDosError(Status); + } + + if (IsHKCRKey(KeyHandle)) + { + LONG ErrorCode = SetHKCRValue(KeyHandle, lpValueName, Reserved, dwType, lpData, cbData); + ClosePredefKey(KeyHandle); + return ErrorCode; + } + if (is_string(dwType) && (cbData != 0)) { PWSTR pwsData = (PWSTR)lpData; @@ -4970,18 +4868,12 @@ RegSetValueExW(HKEY hKey, } _SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER) { - _SEH2_YIELD(return ERROR_NOACCESS); + ClosePredefKey(KeyHandle); + return ERROR_NOACCESS; } _SEH2_END; } - Status = MapDefaultKey(&KeyHandle, - hKey); - if (!NT_SUCCESS(Status)) - { - return RtlNtStatusToDosError(Status); - } - RtlInitUnicodeString(&ValueName, lpValueName); Status = NtSetValueKey(KeyHandle, @@ -5109,8 +5001,13 @@ RegUnLoadKeyA(HKEY hKey, UNICODE_STRING KeyName; DWORD ErrorCode; - RtlCreateUnicodeStringFromAsciiz(&KeyName, - (LPSTR)lpSubKey); + if (lpSubKey) + { + if (!RtlCreateUnicodeStringFromAsciiz(&KeyName, lpSubKey)) + return ERROR_NOT_ENOUGH_MEMORY; + } + else + RtlInitEmptyUnicodeString(&KeyName, NULL, 0); ErrorCode = RegUnLoadKeyW(hKey, KeyName.Buffer); diff --git a/dll/win32/advapi32/reg/reg.h b/dll/win32/advapi32/reg/reg.h new file mode 100644 index 00000000000..6f53cc2a331 --- /dev/null +++ b/dll/win32/advapi32/reg/reg.h @@ -0,0 +1,86 @@ +/* + * COPYRIGHT: See COPYING in the top level directory + * PROJECT: ReactOS system libraries + * FILE: lib/advapi32/reg/reg.c + * PURPOSE: Registry functions + */ + +#pragma once + +/* FUNCTIONS ****************************************************************/ +FORCEINLINE +BOOL +IsHKCRKey(_In_ HKEY hKey) +{ + return ((ULONG_PTR)hKey & 0x2) != 0; +} + +FORCEINLINE +void +MakeHKCRKey(_Inout_ HKEY* hKey) +{ + *hKey = (HKEY)((ULONG_PTR)(*hKey) | 0x2); +} + +LONG +WINAPI +CreateHKCRKey( + _In_ HKEY hKey, + _In_ LPCWSTR lpSubKey, + _In_ DWORD Reserved, + _In_opt_ LPWSTR lpClass, + _In_ DWORD dwOptions, + _In_ REGSAM samDesired, + _In_opt_ LPSECURITY_ATTRIBUTES lpSecurityAttributes, + _Out_ PHKEY phkResult, + _Out_opt_ LPDWORD lpdwDisposition); + +LONG +WINAPI +OpenHKCRKey( + _In_ HKEY hKey, + _In_ LPCWSTR lpSubKey, + _In_ DWORD ulOptions, + _In_ REGSAM samDesired, + _In_ PHKEY phkResult); + +LONG +WINAPI +DeleteHKCRKey( + _In_ HKEY hKey, + _In_ LPCWSTR lpSubKey, + _In_ REGSAM RegSam, + _In_ DWORD Reserved); + +LONG +WINAPI +QueryHKCRValue( + _In_ HKEY hKey, + _In_ LPCWSTR Name, + _In_ LPDWORD Reserved, + _In_ LPDWORD Type, + _In_ LPBYTE Data, + _In_ LPDWORD Count); + +LONG +WINAPI +SetHKCRValue( + _In_ HKEY hKey, + _In_ LPCWSTR Name, + _In_ DWORD Reserved, + _In_ DWORD Type, + _In_ CONST BYTE* Data, + _In_ DWORD DataSize); + +LONG +WINAPI +EnumHKCRKey( + _In_ HKEY hKey, + _In_ DWORD dwIndex, + _Out_ LPWSTR lpName, + _Inout_ LPDWORD lpcbName, + _Reserved_ LPDWORD lpReserved, + _Out_opt_ LPWSTR lpClass, + _Inout_opt_ LPDWORD lpcbClass, + _Out_opt_ PFILETIME lpftLastWriteTime); + diff --git a/dll/win32/comdlg32/lang/cdlg_Tr.rc b/dll/win32/comdlg32/lang/cdlg_Tr.rc index 9f1ae77f124..4ab43385465 100644 --- a/dll/win32/comdlg32/lang/cdlg_Tr.rc +++ b/dll/win32/comdlg32/lang/cdlg_Tr.rc @@ -33,7 +33,7 @@ Onu değiştirmek ister misiniz?" / : < > |" IDS_PATHNOTEXISTING "Kütük yolu yok." IDS_FILENOTEXISTING "Kütük yok." - IDS_INVALID_FOLDERNAME "The selection contains a non-folder object" + IDS_INVALID_FOLDERNAME "Seçim dizin olmayan bir nesne içeriyor." } STRINGTABLE @@ -136,7 +136,7 @@ STRINGTABLE IDS_SAVE "Sakla" IDS_SAVE_AS "Ayrı Sakla" IDS_OPEN_FILE "Kütük Aç" - IDS_SELECT_FOLDER "Select Folder" + IDS_SELECT_FOLDER "Dizin Seç" } /* diff --git a/dll/win32/crypt32/lang/crypt32_Tr.rc b/dll/win32/crypt32/lang/crypt32_Tr.rc index 3a9cef893a4..8591f8a2568 100644 --- a/dll/win32/crypt32/lang/crypt32_Tr.rc +++ b/dll/win32/crypt32/lang/crypt32_Tr.rc @@ -148,7 +148,7 @@ STRINGTABLE IDS_KEY_PACK_LICENSES "Anahtar Paketi Rusatları" IDS_LICENSE_SERVER "Ruhsat Sunucusu Doğrulaması" IDS_SMART_CARD_LOGON "Akıllı Kartla Oturum Açma" - IDS_DIGITAL_RIGHTS "Sayılık Hakları" + IDS_DIGITAL_RIGHTS "Sayılık Yetkileri" IDS_QUALIFIED_SUBORDINATION "Nitelikli Bağlılık" IDS_KEY_RECOVERY "Anahtar Kurtarma" IDS_DOCUMENT_SIGNING "Belge İmzâlama" diff --git a/dll/win32/cryptui/lang/cryptui_Tr.rc b/dll/win32/cryptui/lang/cryptui_Tr.rc index ef2066cab23..5d6833bdc1b 100644 --- a/dll/win32/cryptui/lang/cryptui_Tr.rc +++ b/dll/win32/cryptui/lang/cryptui_Tr.rc @@ -136,7 +136,7 @@ STRINGTABLE IDS_PURPOSE_KEY_RECOVERY "Anahtar Kurtarma" IDS_PURPOSE_DOCUMENT_SIGNING "Belge İmzâlama" IDS_PURPOSE_LIFETIME_SIGNING "Yaşam Boyu İmzâlama" - IDS_PURPOSE_DRM "Sayılık Hakları" + IDS_PURPOSE_DRM "Sayılık Yetkileri" IDS_PURPOSE_LICENSES "Anahtar Paketi Ruhsatları" IDS_PURPOSE_LICENSE_SERVER "Ruhsat Sunucusu Doğrulaması" IDS_PURPOSE_ENROLLMENT_AGENT "Onay Belgesi İstek Yardımcısı" diff --git a/dll/win32/devmgr/lang/tr-TR.rc b/dll/win32/devmgr/lang/tr-TR.rc index 4e8413fa39b..080110ae4fb 100644 --- a/dll/win32/devmgr/lang/tr-TR.rc +++ b/dll/win32/devmgr/lang/tr-TR.rc @@ -40,7 +40,7 @@ STRINGTABLE BEGIN IDS_DEV_NO_PROBLEM "Bu aygıt düzgün çalışıyor." IDS_DEV_NOT_CONFIGURED "Bu aygıt doğru yapılandırılmamış." - IDS_DEV_DEVLOADER_FAILED "Bilgisayar, iki %1 veri yolu türü bildirdiğinden dolayı ReactOS bu aygıt için sürücüyü yükleyemedi." + IDS_DEV_DEVLOADER_FAILED "Bilgisayar, iki %1 veriyolu türü bildirdiğinden dolayı ReactOS bu aygıt için sürücüyü yükleyemedi." IDS_DEV_DEVLOADER_FAILED2 "Bu aygıt için %1 aygıt yükleyicisi/yükleyicileri aygıt sürücüsünü yükleyemedi." IDS_DEV_OUT_OF_MEMORY "Bu aygıt için sürücü kötü olabilir veyâ dizgeniz, bellekte veyâ başka kaynaklarda yavaş çalışıyor olabilir." IDS_DEV_ENTRY_IS_WRONG_TYPE "Sürücülerinin kötü olabilmesinden veyâ değer defterinizin bozuk olabilmesinden dolayı bu aygıt düzgün çalışmıyor." @@ -111,7 +111,7 @@ BEGIN IDS_PROP_CSCONFIGFLAGS "CSConfig İmleri" IDS_PROP_EJECTIONRELATIONS "Çıkarma İlişkileri" IDS_PROP_REMOVALRELATIONS "Kaldırma İlişkileri" - IDS_PROP_BUSRELATIONS "Veri Yolu İlişkileri" + IDS_PROP_BUSRELATIONS "Veriyolu İlişkileri" IDS_PROP_DEVUPPERFILTERS "Üst Aygıt Süzgeçleri" IDS_PROP_DEVLOWERFILTERS "Alt Aygıt Süzgeçleri" IDS_PROP_CLASSUPPERFILTERS "Üst Sınıf Süzgeçleri" diff --git a/dll/win32/framedyn/CMakeLists.txt b/dll/win32/framedyn/CMakeLists.txt index f3f59e5009b..ab758b58be4 100644 --- a/dll/win32/framedyn/CMakeLists.txt +++ b/dll/win32/framedyn/CMakeLists.txt @@ -1,11 +1,7 @@ set_cpp(WITH_RUNTIME WITH_EXCEPTIONS) -if(NOT MSVC) - spec2def(framedyn.dll framedyn_gcc.spec ADD_IMPORTLIB) -else() - spec2def(framedyn.dll framedyn_msvc.spec ADD_IMPORTLIB) -endif() +spec2def(framedyn.dll framedyn.spec ADD_IMPORTLIB) list(APPEND SOURCE main.c @@ -13,18 +9,16 @@ list(APPEND SOURCE ${CMAKE_CURRENT_BINARY_DIR}/framedyn.def) if(MSVC) - add_asm_files(framedyn_asm fix_exports_msvc.s) + add_compile_flags("/Zc:wchar_t-") endif() -add_library(framedyn SHARED ${SOURCE} ${framedyn_asm}) +add_library(framedyn SHARED ${SOURCE}) set_module_type(framedyn win32dll UNICODE) add_importlibs(framedyn oleaut32 msvcrt kernel32 ntdll) add_cd_file(TARGET framedyn DESTINATION reactos/system32/wbem FOR all) -if(MSVC) - add_asm_files(framedynex_asm alias_msvc.s) -else() +if(NOT MSVC) add_asm_files(framedynex_asm alias_gcc.s) endif() add_library(framedynex ${framedynex_asm}) diff --git a/dll/win32/framedyn/alias_gcc.s b/dll/win32/framedyn/alias_gcc.s index 57640a25af1..ce2c12709d8 100644 --- a/dll/win32/framedyn/alias_gcc.s +++ b/dll/win32/framedyn/alias_gcc.s @@ -24,6 +24,7 @@ DEFINE_ALIAS(__ZN8CHStringC1EPKw, ??0CHString@@QAE@PBG@Z) DEFINE_ALIAS(__ZN8CHStringC1EPKwi, ??0CHString@@QAE@PBGH@Z) DEFINE_ALIAS(__ZN8CHStringC1Ewi, ??0CHString@@QAE@GH@Z) DEFINE_ALIAS(__ZN8CHStringC1Ev, ??0CHString@@QAE@XZ) +DEFINE_ALIAS(__ZN8CHStringC2Ev, ??0CHString@@QAE@XZ) // CHString::CHString(void) DEFINE_ALIAS(__ZNK8CHString7CollateEPKw, ?Collate@CHString@@QBEHPBG@Z) DEFINE_ALIAS(__ZNK8CHString7CompareEPKw, ?Compare@CHString@@QBEHPBG@Z) DEFINE_ALIAS(__ZNK8CHString13CompareNoCaseEPKw, ?CompareNoCase@CHString@@QBEHPBG@Z) @@ -62,7 +63,7 @@ DEFINE_ALIAS(__ZN8CHString7ReleaseEv, ?Release@CHString@@IAEXXZ) DEFINE_ALIAS(__ZN8CHString13ReleaseBufferEi, ?ReleaseBuffer@CHString@@QAEXH@Z) DEFINE_ALIAS(__ZNK8CHString11ReverseFindEw, ?ReverseFind@CHString@@QBEHG@Z) DEFINE_ALIAS(__ZNK8CHString5RightEi, ?Right@CHString@@QBE?AV1@H@Z) -DEFINE_ALIAS(__ZN8CHString10SafeStrlenEPKw, ?SafeStrlen@CHString@@KGHPBG@Z) +DEFINE_ALIAS(__ZN8CHString10SafeStrlenEPKw@4, ?SafeStrlen@CHString@@KGHPBG@Z) DEFINE_ALIAS(__ZN8CHString5SetAtEiw, ?SetAt@CHString@@QAEXHG@Z) DEFINE_ALIAS(__ZNK8CHString13SpanExcludingEPKw, ?SpanExcluding@CHString@@QBE?AV1@PBG@Z) DEFINE_ALIAS(__ZNK8CHString13SpanIncludingEPKw, ?SpanIncluding@CHString@@QBE?AV1@PBG@Z) @@ -82,7 +83,8 @@ DEFINE_ALIAS(__ZN8CHStringaSEPKh, ??4CHString@@QAEABV0@PBE@Z) DEFINE_ALIAS(__ZN8CHStringaSEPKw, ??4CHString@@QAEABV0@PBG@Z) DEFINE_ALIAS(__ZN8CHStringaSEw, ??4CHString@@QAEABV0@G@Z) DEFINE_ALIAS(__ZNK8CHStringixEi, ??ACHString@@QBEGH@Z) -DEFINE_ALIAS(__ZN8CHStringD1Ev, ??1CHString@@QAE@XZ) +DEFINE_ALIAS(__ZN8CHStringD1Ev, ??1CHString@@QAE@XZ) // CHString::~CHString() complete object destructor +DEFINE_ALIAS(__ZN8CHStringD2Ev, ??1CHString@@QAE@XZ) // CHString::~CHString() base object destructor DEFINE_ALIAS(__ZplwRK8CHString, ??H@YG?AVCHString@@GABV0@@Z) DEFINE_ALIAS(__ZplRK8CHStringw, ??H@YG?AVCHString@@ABV0@G@Z) DEFINE_ALIAS(__ZplRK8CHStringPKw, ??H@YG?AVCHString@@ABV0@PBG@Z) diff --git a/dll/win32/framedyn/alias_msvc.s b/dll/win32/framedyn/alias_msvc.s deleted file mode 100644 index 3ad77fabc67..00000000000 --- a/dll/win32/framedyn/alias_msvc.s +++ /dev/null @@ -1,48 +0,0 @@ -#include - -.code64 -.align 4 - -MACRO(DEFINE_ALIAS, alias, orig) -EXTERN &orig:ABS -ALIAS <&alias> = <&orig> -ENDM - -DEFINE_ALIAS ?AllocSysString@CHString@@QBEPA_WXZ, ?AllocSysString@CHString@@QBEPAGXZ -DEFINE_ALIAS ?AssignCopy@CHString@@IAEXHPB_W@Z, ?AssignCopy@CHString@@IAEXHPBG@Z -DEFINE_ALIAS ??0CHString@@QAE@PB_W@Z, ??0CHString@@QAE@PBG@Z -DEFINE_ALIAS ??0CHString@@QAE@PB_WH@Z, ??0CHString@@QAE@PBGH@Z -DEFINE_ALIAS ??0CHString@@QAE@_WH@Z, ??0CHString@@QAE@GH@Z -DEFINE_ALIAS ?Collate@CHString@@QBEHPB_W@Z, ?Collate@CHString@@QBEHPBG@Z -DEFINE_ALIAS ?Compare@CHString@@QBEHPB_W@Z, ?Compare@CHString@@QBEHPBG@Z -DEFINE_ALIAS ?CompareNoCase@CHString@@QBEHPB_W@Z, ?CompareNoCase@CHString@@QBEHPBG@Z -DEFINE_ALIAS ?ConcatCopy@CHString@@IAEXHPB_WH0@Z, ?ConcatCopy@CHString@@IAEXHPBGH0@Z -DEFINE_ALIAS ?ConcatInPlace@CHString@@IAEXHPB_W@Z, ?ConcatInPlace@CHString@@IAEXHPBG@Z -DEFINE_ALIAS ?Find@CHString@@QBEHPB_W@Z, ?Find@CHString@@QBEHPBG@Z -DEFINE_ALIAS ?Find@CHString@@QBEH_W@Z, ?Find@CHString@@QBEHG@Z -DEFINE_ALIAS ?FindOneOf@CHString@@QBEHPB_W@Z, ?FindOneOf@CHString@@QBEHPBG@Z -DEFINE_ALIAS ?Format@CHString@@QAAXPB_WZZ, ?Format@CHString@@QAAXPBGZZ -DEFINE_ALIAS ?FormatMessageW@CHString@@QAAXPB_WZZ, ?FormatMessageW@CHString@@QAAXPBGZZ -DEFINE_ALIAS ?FormatV@CHString@@QAEXPB_WPAD@Z, ?FormatV@CHString@@QAEXPBGPAD@Z -DEFINE_ALIAS ?GetAt@CHString@@QBE_WH@Z, ?GetAt@CHString@@QBEGH@Z -DEFINE_ALIAS ?GetBuffer@CHString@@QAEPA_WH@Z, ?GetBuffer@CHString@@QAEPAGH@Z -DEFINE_ALIAS ?GetBufferSetLength@CHString@@QAEPA_WH@Z, ?GetBufferSetLength@CHString@@QAEPAGH@Z -DEFINE_ALIAS ?LoadStringW@CHString@@IAEHIPA_WI@Z, ?LoadStringW@CHString@@IAEHIPAGI@Z -DEFINE_ALIAS ?LockBuffer@CHString@@QAEPA_WXZ, ?LockBuffer@CHString@@QAEPAGXZ -DEFINE_ALIAS ?ReverseFind@CHString@@QBEH_W@Z, ?ReverseFind@CHString@@QBEHG@Z -DEFINE_ALIAS ?SafeStrlen@CHString@@KGHPB_W@Z, ?SafeStrlen@CHString@@KGHPBG@Z -DEFINE_ALIAS ?SetAt@CHString@@QAEXH_W@Z, ?SetAt@CHString@@QAEXHG@Z -DEFINE_ALIAS ?SpanExcluding@CHString@@QBE?AV1@PB_W@Z, ?SpanExcluding@CHString@@QBE?AV1@PBG@Z -DEFINE_ALIAS ?SpanIncluding@CHString@@QBE?AV1@PB_W@Z, ?SpanIncluding@CHString@@QBE?AV1@PBG@Z -DEFINE_ALIAS ??BCHString@@QBEPB_WXZ, ??BCHString@@QBEPBGXZ -DEFINE_ALIAS ??YCHString@@QAEABV0@PB_W@Z, ??YCHString@@QAEABV0@PBG@Z -DEFINE_ALIAS ??YCHString@@QAEABV0@_W@Z, ??YCHString@@QAEABV0@G@Z -DEFINE_ALIAS ??4CHString@@QAEABV0@PB_W@Z, ??4CHString@@QAEABV0@PBG@Z -DEFINE_ALIAS ??4CHString@@QAEABV0@_W@Z, ??4CHString@@QAEABV0@G@Z -DEFINE_ALIAS ??ACHString@@QBE_WH@Z, ??ACHString@@QBEGH@Z -DEFINE_ALIAS ??H@YG?AVCHString@@_WABV0@@Z, ??H@YG?AVCHString@@GABV0@@Z -DEFINE_ALIAS ??H@YG?AVCHString@@ABV0@_W@Z, ??H@YG?AVCHString@@ABV0@G@Z -DEFINE_ALIAS ??H@YG?AVCHString@@ABV0@PB_W@Z, ??H@YG?AVCHString@@ABV0@PBG@Z -DEFINE_ALIAS ??H@YG?AVCHString@@PB_WABV0@@Z, ??H@YG?AVCHString@@PBGABV0@@Z - -END diff --git a/dll/win32/framedyn/fix_exports_msvc.s b/dll/win32/framedyn/fix_exports_msvc.s deleted file mode 100644 index 8e67a059a9a..00000000000 --- a/dll/win32/framedyn/fix_exports_msvc.s +++ /dev/null @@ -1,48 +0,0 @@ -#include - -.code64 -.align 4 - -MACRO(DEFINE_ALIAS, alias, orig) -EXTERN &orig:ABS -ALIAS <&alias> = <&orig> -ENDM - -DEFINE_ALIAS ?AllocSysString@CHString@@QBEPAGXZ, ?AllocSysString@CHString@@QBEPA_WXZ -DEFINE_ALIAS ?AssignCopy@CHString@@IAEXHPBG@Z, ?AssignCopy@CHString@@IAEXHPB_W@Z -DEFINE_ALIAS ??0CHString@@QAE@PBG@Z, ??0CHString@@QAE@PB_W@Z -DEFINE_ALIAS ??0CHString@@QAE@PBGH@Z, ??0CHString@@QAE@PB_WH@Z -DEFINE_ALIAS ??0CHString@@QAE@GH@Z, ??0CHString@@QAE@_WH@Z -DEFINE_ALIAS ?Collate@CHString@@QBEHPBG@Z, ?Collate@CHString@@QBEHPB_W@Z -DEFINE_ALIAS ?Compare@CHString@@QBEHPBG@Z, ?Compare@CHString@@QBEHPB_W@Z -DEFINE_ALIAS ?CompareNoCase@CHString@@QBEHPBG@Z, ?CompareNoCase@CHString@@QBEHPB_W@Z -DEFINE_ALIAS ?ConcatCopy@CHString@@IAEXHPBGH0@Z, ?ConcatCopy@CHString@@IAEXHPB_WH0@Z -DEFINE_ALIAS ?ConcatInPlace@CHString@@IAEXHPBG@Z, ?ConcatInPlace@CHString@@IAEXHPB_W@Z -DEFINE_ALIAS ?Find@CHString@@QBEHPBG@Z, ?Find@CHString@@QBEHPB_W@Z -DEFINE_ALIAS ?Find@CHString@@QBEHG@Z, ?Find@CHString@@QBEH_W@Z -DEFINE_ALIAS ?FindOneOf@CHString@@QBEHPBG@Z, ?FindOneOf@CHString@@QBEHPB_W@Z -DEFINE_ALIAS ?Format@CHString@@QAAXPBGZZ, ?Format@CHString@@QAAXPB_WZZ -DEFINE_ALIAS ?FormatMessageW@CHString@@QAAXPBGZZ, ?FormatMessageW@CHString@@QAAXPB_WZZ -DEFINE_ALIAS ?FormatV@CHString@@QAEXPBGPAD@Z, ?FormatV@CHString@@QAEXPB_WPAD@Z -DEFINE_ALIAS ?GetAt@CHString@@QBEGH@Z, ?GetAt@CHString@@QBE_WH@Z -DEFINE_ALIAS ?GetBuffer@CHString@@QAEPAGH@Z, ?GetBuffer@CHString@@QAEPA_WH@Z -DEFINE_ALIAS ?GetBufferSetLength@CHString@@QAEPAGH@Z, ?GetBufferSetLength@CHString@@QAEPA_WH@Z -DEFINE_ALIAS ?LoadStringW@CHString@@IAEHIPAGI@Z, ?LoadStringW@CHString@@IAEHIPA_WI@Z -DEFINE_ALIAS ?LockBuffer@CHString@@QAEPAGXZ, ?LockBuffer@CHString@@QAEPA_WXZ -DEFINE_ALIAS ?ReverseFind@CHString@@QBEHG@Z, ?ReverseFind@CHString@@QBEH_W@Z -DEFINE_ALIAS ?SafeStrlen@CHString@@KGHPBG@Z, ?SafeStrlen@CHString@@KGHPB_W@Z -DEFINE_ALIAS ?SetAt@CHString@@QAEXHG@Z, ?SetAt@CHString@@QAEXH_W@Z -DEFINE_ALIAS ?SpanExcluding@CHString@@QBE?AV1@PBG@Z, ?SpanExcluding@CHString@@QBE?AV1@PB_W@Z -DEFINE_ALIAS ?SpanIncluding@CHString@@QBE?AV1@PBG@Z, ?SpanIncluding@CHString@@QBE?AV1@PB_W@Z -DEFINE_ALIAS ??BCHString@@QBEPBGXZ, ??BCHString@@QBEPB_WXZ -DEFINE_ALIAS ??YCHString@@QAEABV0@PBG@Z, ??YCHString@@QAEABV0@PB_W@Z -DEFINE_ALIAS ??YCHString@@QAEABV0@G@Z, ??YCHString@@QAEABV0@_W@Z -DEFINE_ALIAS ??4CHString@@QAEABV0@PBG@Z, ??4CHString@@QAEABV0@PB_W@Z -DEFINE_ALIAS ??4CHString@@QAEABV0@G@Z, ??4CHString@@QAEABV0@_W@Z -DEFINE_ALIAS ??ACHString@@QBEGH@Z, ??ACHString@@QBE_WH@Z -DEFINE_ALIAS ??H@YG?AVCHString@@GABV0@@Z, ??H@YG?AVCHString@@_WABV0@@Z -DEFINE_ALIAS ??H@YG?AVCHString@@ABV0@G@Z, ??H@YG?AVCHString@@ABV0@_W@Z -DEFINE_ALIAS ??H@YG?AVCHString@@ABV0@PBG@Z, ??H@YG?AVCHString@@ABV0@PB_W@Z -DEFINE_ALIAS ??H@YG?AVCHString@@PBGABV0@@Z, ??H@YG?AVCHString@@PB_WABV0@@Z - -END diff --git a/dll/win32/framedyn/framedyn_gcc.spec b/dll/win32/framedyn/framedyn.spec similarity index 97% rename from dll/win32/framedyn/framedyn_gcc.spec rename to dll/win32/framedyn/framedyn.spec index c9b0cc22e7e..d3a9052b19d 100644 --- a/dll/win32/framedyn/framedyn_gcc.spec +++ b/dll/win32/framedyn/framedyn.spec @@ -68,7 +68,7 @@ @ thiscall ??4CHString@@QAEABV0@PBG@Z(wstr) _ZN8CHStringaSEPKw @ thiscall ??4CHString@@QAEABV0@G@Z(long) _ZN8CHStringaSEw @ thiscall ??ACHString@@QBEGH@Z(long) _ZNK8CHStringixEi -@ thiscall ??1CHString@@QAE@XZ() _ZN8CHStringD1Ev +@ thiscall ??1CHString@@QAE@XZ() _ZN8CHStringD1Ev # complete object destructor, identical to _ZN8CHStringD2Ev aka base object destructor @ stdcall ??H@YG?AVCHString@@GABV0@@Z(long ptr) _ZplwRK8CHString @ stdcall ??H@YG?AVCHString@@ABV0@G@Z(ptr long) _ZplRK8CHStringw @ stdcall ??H@YG?AVCHString@@ABV0@PBG@Z(ptr wstr) _ZplRK8CHStringPKw diff --git a/dll/win32/framedyn/framedyn_msvc.spec b/dll/win32/framedyn/framedyn_msvc.spec deleted file mode 100644 index 1fcb0b85af1..00000000000 --- a/dll/win32/framedyn/framedyn_msvc.spec +++ /dev/null @@ -1,76 +0,0 @@ -@ thiscall ?AllocBeforeWrite@CHString@@IAEXH@Z(long) -@ thiscall ?AllocBuffer@CHString@@IAEXH@Z(long) -@ thiscall ?AllocCopy@CHString@@IBEXAAV1@HHH@Z(ptr long long long) -@ thiscall ?AllocSysString@CHString@@QBEPAGXZ() -@ thiscall ?AssignCopy@CHString@@IAEXHPBG@Z(long wstr) -@ thiscall ??0CHString@@QAE@ABV0@@Z(ptr) -@ thiscall ??0CHString@@QAE@PBD@Z(str) -@ thiscall ??0CHString@@QAE@PBE@Z(str) -@ thiscall ??0CHString@@QAE@PBG@Z(wstr) -@ thiscall ??0CHString@@QAE@PBGH@Z(wstr long) -@ thiscall ??0CHString@@QAE@GH@Z(long long) -@ thiscall ??0CHString@@QAE@XZ() -@ thiscall ?Collate@CHString@@QBEHPBG@Z(wstr) -@ thiscall ?Compare@CHString@@QBEHPBG@Z(wstr) -@ thiscall ?CompareNoCase@CHString@@QBEHPBG@Z(wstr) -@ thiscall ?ConcatCopy@CHString@@IAEXHPBGH0@Z(long wstr long wstr) -@ thiscall ?ConcatInPlace@CHString@@IAEXHPBG@Z(long wstr) -@ thiscall ?CopyBeforeWrite@CHString@@IAEXXZ() -@ thiscall ?Empty@CHString@@QAEXXZ() -@ thiscall ?Find@CHString@@QBEHPBG@Z(wstr) -@ thiscall ?Find@CHString@@QBEHG@Z(long) -@ thiscall ?FindOneOf@CHString@@QBEHPBG@Z(wstr) -@ thiscall ?Format@CHString@@QAAXIZZ(long long long) -@ thiscall ?Format@CHString@@QAAXPBGZZ(long wstr long) -@ thiscall ?FormatMessageW@CHString@@QAAXIZZ(long long long) -@ thiscall ?FormatMessageW@CHString@@QAAXPBGZZ(long ptr long) -@ thiscall ?FormatV@CHString@@QAEXPBGPAD@Z(wstr long) -@ thiscall ?FreeExtra@CHString@@QAEXXZ() -@ thiscall ?GetAllocLength@CHString@@QBEHXZ() -@ thiscall ?GetAt@CHString@@QBEGH@Z(long) -@ thiscall ?GetBuffer@CHString@@QAEPAGH@Z(long) -@ thiscall ?GetBufferSetLength@CHString@@QAEPAGH@Z(long) -@ thiscall ?GetData@CHString@@IBEPAUCHStringData@@XZ() -@ thiscall ?GetLength@CHString@@QBEHXZ() -@ thiscall ?Init@CHString@@IAEXXZ() -@ thiscall ?IsEmpty@CHString@@QBEHXZ() -@ thiscall ?Left@CHString@@QBE?AV1@H@Z(long) -@ thiscall ?LoadStringW@CHString@@QAEHI@Z(long) -@ thiscall ?LoadStringW@CHString@@IAEHIPAGI@Z(long wstr long) -@ thiscall ?LockBuffer@CHString@@QAEPAGXZ() -@ thiscall ?MakeLower@CHString@@QAEXXZ() -@ thiscall ?MakeReverse@CHString@@QAEXXZ() -@ thiscall ?MakeUpper@CHString@@QAEXXZ() -@ thiscall ?Mid@CHString@@QBE?AV1@H@Z(long) -@ thiscall ?Mid@CHString@@QBE?AV1@HH@Z(long long) -@ thiscall ?Release@CHString@@KGXPAUCHStringData@@@Z(ptr) -@ thiscall ?Release@CHString@@IAEXXZ() -@ thiscall ?ReleaseBuffer@CHString@@QAEXH@Z(long) -@ thiscall ?ReverseFind@CHString@@QBEHG@Z(long) -@ thiscall ?Right@CHString@@QBE?AV1@H@Z(long) -@ stdcall ?SafeStrlen@CHString@@KGHPBG@Z(wstr) -@ thiscall ?SetAt@CHString@@QAEXHG@Z(long long) -@ thiscall ?SpanExcluding@CHString@@QBE?AV1@PBG@Z(long wstr) -@ thiscall ?SpanIncluding@CHString@@QBE?AV1@PBG@Z(long wstr) -@ thiscall ?TrimLeft@CHString@@QAEXXZ() -@ thiscall ?TrimRight@CHString@@QAEXXZ() -@ thiscall ?UnlockBuffer@CHString@@QAEXXZ() -@ thiscall ??BCHString@@QBEPBGXZ(ptr) -@ thiscall ??YCHString@@QAEABV0@ABV0@@Z(ptr) -@ thiscall ??YCHString@@QAEABV0@D@Z(long) -@ thiscall ??YCHString@@QAEABV0@PBG@Z(wstr) -@ thiscall ??YCHString@@QAEABV0@G@Z(long) -@ thiscall ??4CHString@@QAEABV0@PAV0@@Z(ptr) -@ thiscall ??4CHString@@QAEABV0@ABV0@@Z(ptr) -@ thiscall ??4CHString@@QAEABV0@PBD@Z(str) -@ thiscall ??4CHString@@QAEABV0@D@Z(long) -@ thiscall ??4CHString@@QAEABV0@PBE@Z(str) -@ thiscall ??4CHString@@QAEABV0@PBG@Z(wstr) -@ thiscall ??4CHString@@QAEABV0@G@Z(long) -@ thiscall ??ACHString@@QBEGH@Z(long) -@ thiscall ??1CHString@@QAE@XZ() -@ stdcall ??H@YG?AVCHString@@GABV0@@Z(long ptr) -@ stdcall ??H@YG?AVCHString@@ABV0@G@Z(ptr long) -@ stdcall ??H@YG?AVCHString@@ABV0@PBG@Z(ptr wstr) -@ stdcall ??H@YG?AVCHString@@PBGABV0@@Z(wstr ptr) -@ stdcall ??H@YG?AVCHString@@ABV0@0@Z(ptr ptr) diff --git a/dll/win32/hhctrl.ocx/lang/Tr.rc b/dll/win32/hhctrl.ocx/lang/Tr.rc index acfc878f45d..b7d08a83ab4 100644 --- a/dll/win32/hhctrl.ocx/lang/Tr.rc +++ b/dll/win32/hhctrl.ocx/lang/Tr.rc @@ -28,8 +28,8 @@ BEGIN IDS_SEARCH "&Ara" IDS_FAVORITES "&Yer İmleri" - IDS_HIDETABS "Hide &Tabs" - IDS_SHOWTABS "Show &Tabs" + IDS_HIDETABS "&Sekmeleri Gizle" + IDS_SHOWTABS "&Sekmeleri Göster" END STRINGTABLE @@ -51,12 +51,12 @@ MENU_POPUP MENU POPUP "" /* Options */ { MENUITEM "", IDTB_EXPAND - MENUITEM "S&ync", IDTB_SYNC - MENUITEM "&Back", IDTB_BACK - MENUITEM "&Forward", IDTB_FORWARD - MENUITEM "&Home", IDTB_HOME - MENUITEM "&Stop", IDTB_STOP - MENUITEM "&Refresh", IDTB_REFRESH - MENUITEM "&Print...", IDTB_PRINT + MENUITEM "&Eşitle", IDTB_SYNC + MENUITEM "&Geri", IDTB_BACK + MENUITEM "&İleri", IDTB_FORWARD + MENUITEM "E&v", IDTB_HOME + MENUITEM "&Dur", IDTB_STOP + MENUITEM "&Yenile", IDTB_REFRESH + MENUITEM "Y&azdır...", IDTB_PRINT } } diff --git a/dll/win32/hnetcfg/CMakeLists.txt b/dll/win32/hnetcfg/CMakeLists.txt index b42abf08d44..6aa4f10ad4e 100644 --- a/dll/win32/hnetcfg/CMakeLists.txt +++ b/dll/win32/hnetcfg/CMakeLists.txt @@ -27,6 +27,7 @@ list(APPEND hnetcfg_rc_deps set_source_files_properties(hnetcfg.rc PROPERTIES OBJECT_DEPENDS "${hnetcfg_rc_deps}") set_module_type(hnetcfg win32dll) +add_dependencies(hnetcfg stdole2) target_link_libraries(hnetcfg wine uuid) add_importlibs(hnetcfg ole32 oleaut32 advapi32 msvcrt kernel32 ntdll) add_pch(hnetcfg hnetcfg_private.h SOURCE) diff --git a/dll/win32/itss/CMakeLists.txt b/dll/win32/itss/CMakeLists.txt index 48616208612..5d1e100856c 100644 --- a/dll/win32/itss/CMakeLists.txt +++ b/dll/win32/itss/CMakeLists.txt @@ -24,4 +24,5 @@ set_module_type(itss win32dll) target_link_libraries(itss uuid wine) add_importlibs(itss urlmon shlwapi ole32 msvcrt kernel32 ntdll) add_pch(itss precomp.h SOURCE) +add_dependencies(itss wineheaders) add_cd_file(TARGET itss DESTINATION reactos/system32 FOR all) diff --git a/dll/win32/jscript/lang/jscript_Tr.rc b/dll/win32/jscript/lang/jscript_Tr.rc index 4065005ae9c..7488efbd18f 100644 --- a/dll/win32/jscript/lang/jscript_Tr.rc +++ b/dll/win32/jscript/lang/jscript_Tr.rc @@ -22,24 +22,24 @@ STRINGTABLE { IDS_TO_PRIMITIVE "Nesneyi ilk türe dönüştürmede yanlışlık." IDS_INVALID_CALL_ARG "Geçersiz yordam çağrısı ya da geçersiz yordam değiştirgeni." - IDS_SUBSCRIPT_OUT_OF_RANGE "Subscript out of range" - IDS_OBJECT_REQUIRED "Object required" + IDS_SUBSCRIPT_OUT_OF_RANGE "Alt indis aralık dışında." + IDS_OBJECT_REQUIRED "Nesne gerekli." IDS_CREATE_OBJ_ERROR "Öz devinim sunucusu nesne oluşturamıyor." IDS_NO_PROPERTY "Nesne bu husûsiyeti/yöntemi desteklemiyor." - IDS_UNSUPPORTED_ACTION "Object doesn't support this action" + IDS_UNSUPPORTED_ACTION "Nesne bu işlemi desteklemiyor." IDS_ARG_NOT_OPT "Değiştirgen seçimlik değil." IDS_SYNTAX_ERROR "Söz dizimi yanlışlığı." IDS_SEMICOLON """;"" bekleniyordu." IDS_LBRACKET """("" bekleniyordu." IDS_RBRACKET """)"" bekleniyordu." - IDS_INVALID_CHAR "Invalid character" + IDS_INVALID_CHAR "Geçersiz damga." IDS_UNTERMINATED_STR "Sonlandırılmamış dizgi değişmezi." - IDS_MISPLACED_RETURN "'return' statement outside of function" - IDS_INVALID_BREAK "Can't have 'break' outside of loop" - IDS_INVALID_CONTINUE "Can't have 'continue' outside of loop" - IDS_LABEL_REDEFINED "Label redefined" - IDS_LABEL_NOT_FOUND "Label not found" - IDS_DISABLED_CC "Conditional compilation is turned off" + IDS_MISPLACED_RETURN """return"" deyişi işlecin dışında." + IDS_INVALID_BREAK "Döngü dışında ""break"" olamaz." + IDS_INVALID_CONTINUE "Döngü dışında ""continue"" olamaz." + IDS_LABEL_REDEFINED "Etiket yeniden tanımlandı." + IDS_LABEL_NOT_FOUND "Etiket bulunamadı." + IDS_DISABLED_CC "Koşullu derleme kapalı." IDS_NOT_FUNC "İşleç bekleniyordu." IDS_NOT_DATE """[nesne]"" bir zaman nesnesi değil." IDS_NOT_NUM "Sayı bekleniyordu." @@ -47,14 +47,14 @@ STRINGTABLE IDS_ILLEGAL_ASSIGN "Geçersiz atama." IDS_UNDEFINED """|"" tanımlı değil." IDS_NOT_BOOL "Boole nesnesi bekleniyordu." - IDS_INVALID_DELETE "Cannot delete '|'" - IDS_NOT_VBARRAY "VBArray object expected" + IDS_INVALID_DELETE """|"" silinemez." + IDS_NOT_VBARRAY "VBArray nesnesi bekleniyordu." IDS_JSCRIPT_EXPECTED "JScript nesnesi bekleniyordu." IDS_REGEXP_SYNTAX_ERROR "Düzenli deyişte söz dizimi yanlışlığı." - IDS_URI_INVALID_CODING "URI to be decoded is incorrect" + IDS_URI_INVALID_CODING "Çözülecek URI geçersiz." IDS_URI_INVALID_CHAR "Kodlanacak URI geçersiz damgalar içeriyor." - IDS_FRACTION_DIGITS_OUT_OF_RANGE "Number of fraction digits is out of range" - IDS_PRECISION_OUT_OF_RANGE "Precision is out of range" + IDS_FRACTION_DIGITS_OUT_OF_RANGE "Kesir basamaklarının sayısı aralık dışında." + IDS_PRECISION_OUT_OF_RANGE "Duyarlılık aralık dışında." IDS_INVALID_LENGTH "Dizi büyüklüğü bir sonlu artı tam sayı olmalı." IDS_ARRAY_EXPECTED "Dizi nesnesi bekleniyordu." } diff --git a/dll/win32/lsasrv/session.c b/dll/win32/lsasrv/session.c index 8f967426cd8..67673be8442 100644 --- a/dll/win32/lsasrv/session.c +++ b/dll/win32/lsasrv/session.c @@ -314,8 +314,6 @@ LsapGetLogonSessionData(IN OUT PLSA_API_MSG RequestMsg) goto done; } - //TRACE("MemSize: %lu\n", MemSize); - MemSize = Length; Status = NtAllocateVirtualMemory(ProcessHandle, &ClientBaseAddress, diff --git a/dll/win32/msacm32/CMakeLists.txt b/dll/win32/msacm32/CMakeLists.txt index 4a3e8ab466d..c2101421182 100644 --- a/dll/win32/msacm32/CMakeLists.txt +++ b/dll/win32/msacm32/CMakeLists.txt @@ -15,6 +15,7 @@ list(APPEND SOURCE add_library(msacm32 SHARED ${SOURCE} + msacm.rc ${CMAKE_CURRENT_BINARY_DIR}/msacm32.def) set_module_type(msacm32 win32dll ENTRYPOINT DllMain 12 UNICODE) diff --git a/dll/win32/msacm32/imaadp32/Makefile.in b/dll/win32/msacm32/imaadp32/Makefile.in deleted file mode 100644 index 79cc94e4aee..00000000000 --- a/dll/win32/msacm32/imaadp32/Makefile.in +++ /dev/null @@ -1,12 +0,0 @@ -TOPSRCDIR = @top_srcdir@ -TOPOBJDIR = ../../.. -SRCDIR = @srcdir@ -VPATH = @srcdir@ -MODULE = imaadp32.acm -IMPORTS = winmm user32 kernel32 - -C_SRCS = imaadp32.c - -@MAKE_DLL_RULES@ - -### Dependencies: diff --git a/dll/win32/msacm32/imaadp32/imaadp32.acm.spec b/dll/win32/msacm32/imaadp32/imaadp32.acm.spec deleted file mode 100644 index a0ba1c7e701..00000000000 --- a/dll/win32/msacm32/imaadp32/imaadp32.acm.spec +++ /dev/null @@ -1 +0,0 @@ -@ stdcall DriverProc (long long long long long) ADPCM_DriverProc diff --git a/dll/win32/msacm32/imaadp32/imaadp32.c b/dll/win32/msacm32/imaadp32/imaadp32.c deleted file mode 100644 index 573d583b27b..00000000000 --- a/dll/win32/msacm32/imaadp32/imaadp32.c +++ /dev/null @@ -1,938 +0,0 @@ -/* - * IMA ADPCM handling - * - * Copyright (C) 2001,2002 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 Street, Fifth Floor, Boston, MA 02110-1301 USA - */ - -#include -#include -#include -#include "windef.h" -#include "winbase.h" -#include "wingdi.h" -#include "winuser.h" -#include "winnls.h" -#include "mmsystem.h" -#include "mmreg.h" -#include "msacm.h" -#include "msacmdrv.h" -#include "wine/debug.h" - -/* see http://www.pcisys.net/~melanson/codecs/adpcm.txt for the details */ - -WINE_DEFAULT_DEBUG_CHANNEL(adpcm); - -/*********************************************************************** - * ADPCM_drvOpen - */ -static DWORD ADPCM_drvOpen(LPCSTR str) -{ - return 1; -} - -/*********************************************************************** - * ADPCM_drvClose - */ -static DWORD ADPCM_drvClose(DWORD dwDevID) -{ - return 1; -} - -typedef struct tagAcmAdpcmData -{ - void (*convert)(PACMDRVSTREAMINSTANCE adsi, - const unsigned char*, LPDWORD, unsigned char*, LPDWORD); - /* IMA encoding only */ - BYTE stepIndexL; - BYTE stepIndexR; - /* short sample; */ -} AcmAdpcmData; - -/* table to list all supported formats... those are the basic ones. this - * also helps given a unique index to each of the supported formats - */ -typedef struct -{ - int nChannels; - int nBits; - int rate; -} Format; - -static Format PCM_Formats[] = -{ - {1, 8, 8000}, {2, 8, 8000}, {1, 16, 8000}, {2, 16, 8000}, - {1, 8, 11025}, {2, 8, 11025}, {1, 16, 11025}, {2, 16, 11025}, - {1, 8, 22050}, {2, 8, 22050}, {1, 16, 22050}, {2, 16, 22050}, - {1, 8, 44100}, {2, 8, 44100}, {1, 16, 44100}, {2, 16, 44100}, -}; - -static Format ADPCM_Formats[] = -{ - {1, 4, 8000}, {2, 4, 8000}, {1, 4, 11025}, {2, 4, 11025}, - {1, 4, 22050}, {2, 4, 22050}, {1, 4, 44100}, {2, 4, 44100}, -}; - -#define NUM_PCM_FORMATS (sizeof(PCM_Formats) / sizeof(PCM_Formats[0])) -#define NUM_ADPCM_FORMATS (sizeof(ADPCM_Formats) / sizeof(ADPCM_Formats[0])) - -/*********************************************************************** - * ADPCM_GetFormatIndex - */ -static DWORD ADPCM_GetFormatIndex(LPWAVEFORMATEX wfx) -{ - int i, hi; - Format* fmts; - - switch (wfx->wFormatTag) - { - case WAVE_FORMAT_PCM: - hi = NUM_PCM_FORMATS; - fmts = PCM_Formats; - break; - case WAVE_FORMAT_IMA_ADPCM: - hi = NUM_ADPCM_FORMATS; - fmts = ADPCM_Formats; - break; - default: - return 0xFFFFFFFF; - } - - for (i = 0; i < hi; i++) - { - if (wfx->nChannels == fmts[i].nChannels && - wfx->nSamplesPerSec == fmts[i].rate && - wfx->wBitsPerSample == fmts[i].nBits) - return i; - } - - return 0xFFFFFFFF; -} - -/*********************************************************************** - * R16 - * - * Read a 16 bit sample (correctly handles endianess) - */ -static inline short R16(const unsigned char* src) -{ - return (short)((unsigned short)src[0] | ((unsigned short)src[1] << 8)); -} - -/*********************************************************************** - * W16 - * - * Write a 16 bit sample (correctly handles endianess) - */ -static inline void W16(unsigned char* dst, short s) -{ - dst[0] = LOBYTE(s); - dst[1] = HIBYTE(s); -} - -/* IMA (or DVI) APDCM codec routines */ - -static const unsigned IMA_StepTable[89] = -{ - 7, 8, 9, 10, 11, 12, 13, 14, - 16, 17, 19, 21, 23, 25, 28, 31, - 34, 37, 41, 45, 50, 55, 60, 66, - 73, 80, 88, 97, 107, 118, 130, 143, - 157, 173, 190, 209, 230, 253, 279, 307, - 337, 371, 408, 449, 494, 544, 598, 658, - 724, 796, 876, 963, 1060, 1166, 1282, 1411, - 1552, 1707, 1878, 2066, 2272, 2499, 2749, 3024, - 3327, 3660, 4026, 4428, 4871, 5358, 5894, 6484, - 7132, 7845, 8630, 9493, 10442, 11487, 12635, 13899, - 15289, 16818, 18500, 20350, 22385, 24623, 27086, 29794, - 32767 -}; - -static const int IMA_IndexTable[16] = -{ - -1, -1, -1, -1, 2, 4, 6, 8, - -1, -1, -1, -1, 2, 4, 6, 8 -}; - -static inline void clamp_step_index(int* stepIndex) -{ - if (*stepIndex < 0 ) *stepIndex = 0; - if (*stepIndex > 88) *stepIndex = 88; -} - -static inline void clamp_sample(int* sample) -{ - if (*sample < -32768) *sample = -32768; - if (*sample > 32767) *sample = 32767; -} - -static inline void process_nibble(unsigned char code, int* stepIndex, int* sample) -{ - unsigned step; - int diff; - - code &= 0x0F; - - step = IMA_StepTable[*stepIndex]; - diff = step >> 3; - if (code & 1) diff += step >> 2; - if (code & 2) diff += step >> 1; - if (code & 4) diff += step; - if (code & 8) *sample -= diff; - else *sample += diff; - clamp_sample(sample); - *stepIndex += IMA_IndexTable[code]; - clamp_step_index(stepIndex); -} - -static inline unsigned char generate_nibble(int in, int* stepIndex, int* sample) -{ - int effdiff, diff = in - *sample; - unsigned step; - unsigned char code; - - if (diff < 0) - { - diff = -diff; - code = 8; - } - else - { - code = 0; - } - - step = IMA_StepTable[*stepIndex]; - effdiff = (step >> 3); - if (diff >= step) - { - code |= 4; - diff -= step; - effdiff += step; - } - step >>= 1; - if (diff >= step) - { - code |= 2; - diff -= step; - effdiff += step; - } - step >>= 1; - if (diff >= step) - { - code |= 1; - effdiff += step; - } - if (code & 8) *sample -= effdiff; - else *sample += effdiff; - clamp_sample(sample); - *stepIndex += IMA_IndexTable[code]; - clamp_step_index(stepIndex); - return code; -} - -static void cvtSSima16K(PACMDRVSTREAMINSTANCE adsi, - const unsigned char* src, LPDWORD nsrc, - unsigned char* dst, LPDWORD ndst) -{ - int i; - int sampleL, sampleR; - int stepIndexL, stepIndexR; - int nsamp_blk = ((LPIMAADPCMWAVEFORMAT)adsi->pwfxSrc)->wSamplesPerBlock; - int nsamp; - /* compute the number of entire blocks we can decode... - * it's the min of the number of entire blocks in source buffer and the number - * of entire blocks in destination buffer - */ - DWORD nblock = min(*nsrc / adsi->pwfxSrc->nBlockAlign, - *ndst / (nsamp_blk * 2 * 2)); - - *nsrc = nblock * adsi->pwfxSrc->nBlockAlign; - *ndst = nblock * (nsamp_blk * 2 * 2); - - nsamp_blk--; /* remove the sample in block header */ - for (; nblock > 0; nblock--) - { - const unsigned char* in_src = src; - - /* handle headers first */ - sampleL = R16(src); - stepIndexL = (unsigned)*(src + 2); - clamp_step_index(&stepIndexL); - src += 4; - W16(dst, sampleL); dst += 2; - - sampleR = R16(src); - stepIndexR = (unsigned)*(src + 2); - clamp_step_index(&stepIndexR); - src += 4; - W16(dst, sampleR); dst += 2; - - for (nsamp = nsamp_blk; nsamp > 0; nsamp -= 8) - { - for (i = 0; i < 4; i++) - { - process_nibble(*src, &stepIndexL, &sampleL); - W16(dst + (2 * i + 0) * 4 + 0, sampleL); - process_nibble(*src++ >> 4, &stepIndexL, &sampleL); - W16(dst + (2 * i + 1) * 4 + 0, sampleL); - } - for (i = 0; i < 4; i++) - { - process_nibble(*src , &stepIndexR, &sampleR); - W16(dst + (2 * i + 0) * 4 + 2, sampleR); - process_nibble(*src++ >>4, &stepIndexR, &sampleR); - W16(dst + (2 * i + 1) * 4 + 2, sampleR); - } - dst += 32; - } - /* we have now to realign the source pointer on block */ - src = in_src + adsi->pwfxSrc->nBlockAlign; - } -} - -static void cvtMMima16K(PACMDRVSTREAMINSTANCE adsi, - const unsigned char* src, LPDWORD nsrc, - unsigned char* dst, LPDWORD ndst) -{ - int sample; - int stepIndex; - int nsamp_blk = ((LPIMAADPCMWAVEFORMAT)adsi->pwfxSrc)->wSamplesPerBlock; - int nsamp; - /* compute the number of entire blocks we can decode... - * it's the min of the number of entire blocks in source buffer and the number - * of entire blocks in destination buffer - */ - DWORD nblock = min(*nsrc / adsi->pwfxSrc->nBlockAlign, - *ndst / (nsamp_blk * 2)); - - *nsrc = nblock * adsi->pwfxSrc->nBlockAlign; - *ndst = nblock * nsamp_blk * 2; - - nsamp_blk--; /* remove the sample in block header */ - for (; nblock > 0; nblock--) - { - const unsigned char* in_src = src; - - /* handle header first */ - sample = R16(src); - stepIndex = (unsigned)*(src + 2); - clamp_step_index(&stepIndex); - src += 4; - W16(dst, sample); dst += 2; - - for (nsamp = nsamp_blk; nsamp > 0; nsamp -= 2) - { - process_nibble(*src, &stepIndex, &sample); - W16(dst, sample); dst += 2; - process_nibble(*src++ >> 4, &stepIndex, &sample); - W16(dst, sample); dst += 2; - } - /* we have now to realign the source pointer on block */ - src = in_src + adsi->pwfxSrc->nBlockAlign; - } -} - -static void cvtSS16imaK(PACMDRVSTREAMINSTANCE adsi, - const unsigned char* src, LPDWORD nsrc, - unsigned char* dst, LPDWORD ndst) -{ - int stepIndexL, stepIndexR; - int sampleL, sampleR; - BYTE code1, code2; - int nsamp_blk = ((LPIMAADPCMWAVEFORMAT)adsi->pwfxDst)->wSamplesPerBlock; - int i, nsamp; - /* compute the number of entire blocks we can decode... - * it's the min of the number of entire blocks in source buffer and the number - * of entire blocks in destination buffer - */ - DWORD nblock = min(*nsrc / (nsamp_blk * 2 * 2), - *ndst / adsi->pwfxDst->nBlockAlign); - - *nsrc = nblock * (nsamp_blk * 2 * 2); - *ndst = nblock * adsi->pwfxDst->nBlockAlign; - - stepIndexL = ((AcmAdpcmData*)adsi->dwDriver)->stepIndexL; - stepIndexR = ((AcmAdpcmData*)adsi->dwDriver)->stepIndexR; - - nsamp_blk--; /* so that we won't count the sample in header while filling the block */ - - for (; nblock > 0; nblock--) - { - char* in_dst = dst; - - /* generate header */ - sampleL = R16(src); src += 2; - W16(dst, sampleL); dst += 2; - *dst = (unsigned char)(unsigned)stepIndexL; - dst += 2; - - sampleR = R16(src); src += 2; - W16(dst, sampleR); dst += 2; - *dst = (unsigned char)(unsigned)stepIndexR; - dst += 2; - - for (nsamp = nsamp_blk; nsamp > 0; nsamp -= 8) - { - for (i = 0; i < 4; i++) - { - code1 = generate_nibble(R16(src + (2 * i + 0) * 2 + 0), - &stepIndexL, &sampleL); - code2 = generate_nibble(R16(src + (2 * i + 1) * 2 + 0), - &stepIndexL, &sampleL); - *dst++ = (code1 << 4) | code2; - } - for (i = 0; i < 4; i++) - { - code1 = generate_nibble(R16(src + (2 * i + 0) * 2 + 1), - &stepIndexR, &sampleR); - code2 = generate_nibble(R16(src + (2 * i + 1) * 2 + 1), - &stepIndexR, &sampleR); - *dst++ = (code1 << 4) | code2; - } - src += 32; - } - dst = in_dst + adsi->pwfxDst->nBlockAlign; - } - ((AcmAdpcmData*)adsi->dwDriver)->stepIndexL = stepIndexL; - ((AcmAdpcmData*)adsi->dwDriver)->stepIndexR = stepIndexR; -} - -static void cvtMM16imaK(PACMDRVSTREAMINSTANCE adsi, - const unsigned char* src, LPDWORD nsrc, - unsigned char* dst, LPDWORD ndst) -{ - int stepIndex; - int sample; - BYTE code1, code2; - int nsamp_blk = ((LPIMAADPCMWAVEFORMAT)adsi->pwfxDst)->wSamplesPerBlock; - int nsamp; - /* compute the number of entire blocks we can decode... - * it's the min of the number of entire blocks in source buffer and the number - * of entire blocks in destination buffer - */ - DWORD nblock = min(*nsrc / (nsamp_blk * 2), - *ndst / adsi->pwfxDst->nBlockAlign); - - *nsrc = nblock * (nsamp_blk * 2); - *ndst = nblock * adsi->pwfxDst->nBlockAlign; - - stepIndex = ((AcmAdpcmData*)adsi->dwDriver)->stepIndexL; - nsamp_blk--; /* so that we won't count the sample in header while filling the block */ - - for (; nblock > 0; nblock--) - { - char* in_dst = dst; - - /* generate header */ - /* FIXME: what about the last effective sample from previous block ??? */ - /* perhaps something like: - * sample += R16(src); - * clamp_sample(sample); - * and with : - * + saving the sample in adsi->dwDriver when all blocks are done - + + reset should set the field in adsi->dwDriver to 0 too - */ - sample = R16(src); src += 2; - W16(dst, sample); dst += 2; - *dst = (unsigned char)(unsigned)stepIndex; - dst += 2; - - for (nsamp = nsamp_blk; nsamp > 0; nsamp -= 2) - { - code1 = generate_nibble(R16(src), &stepIndex, &sample); - src += 2; - code2 = generate_nibble(R16(src), &stepIndex, &sample); - src += 2; - *dst++ = (code1 << 4) | code2; - } - dst = in_dst + adsi->pwfxDst->nBlockAlign; - } - ((AcmAdpcmData*)adsi->dwDriver)->stepIndexL = stepIndex; -} - -/*********************************************************************** - * ADPCM_DriverDetails - * - */ -static LRESULT ADPCM_DriverDetails(PACMDRIVERDETAILSW add) -{ - add->fccType = ACMDRIVERDETAILS_FCCTYPE_AUDIOCODEC; - add->fccComp = ACMDRIVERDETAILS_FCCCOMP_UNDEFINED; - add->wMid = 0xFF; - add->wPid = 0x00; - add->vdwACM = 0x01000000; - add->vdwDriver = 0x01000000; - add->fdwSupport = ACMDRIVERDETAILS_SUPPORTF_CODEC; - add->cFormatTags = 2; /* PCM, IMA ADPCM */ - add->cFilterTags = 0; - add->hicon = NULL; - MultiByteToWideChar( CP_ACP, 0, "WINE-ADPCM", -1, - add->szShortName, sizeof(add->szShortName)/sizeof(WCHAR) ); - MultiByteToWideChar( CP_ACP, 0, "Wine IMA ADPCM converter", -1, - add->szLongName, sizeof(add->szLongName)/sizeof(WCHAR) ); - MultiByteToWideChar( CP_ACP, 0, "Brought to you by the Wine team...", -1, - add->szCopyright, sizeof(add->szCopyright)/sizeof(WCHAR) ); - MultiByteToWideChar( CP_ACP, 0, "Refer to LICENSE file", -1, - add->szLicensing, sizeof(add->szLicensing)/sizeof(WCHAR) ); - add->szFeatures[0] = 0; - - return MMSYSERR_NOERROR; -} - -/*********************************************************************** - * ADPCM_FormatTagDetails - * - */ -static LRESULT ADPCM_FormatTagDetails(PACMFORMATTAGDETAILSW aftd, DWORD dwQuery) -{ - static WCHAR szPcm[]={'P','C','M',0}; - static WCHAR szImaAdPcm[]={'I','M','A',' ','A','d','P','C','M',0}; - - switch (dwQuery) - { - case ACM_FORMATTAGDETAILSF_INDEX: - if (aftd->dwFormatTagIndex >= 2) return ACMERR_NOTPOSSIBLE; - break; - case ACM_FORMATTAGDETAILSF_LARGESTSIZE: - if (aftd->dwFormatTag == WAVE_FORMAT_UNKNOWN) - { - aftd->dwFormatTagIndex = 1; /* WAVE_FORMAT_IMA_ADPCM is bigger than PCM */ - break; - } - /* fall thru */ - case ACM_FORMATTAGDETAILSF_FORMATTAG: - switch (aftd->dwFormatTag) - { - case WAVE_FORMAT_PCM: aftd->dwFormatTagIndex = 0; break; - case WAVE_FORMAT_IMA_ADPCM: aftd->dwFormatTagIndex = 1; break; - default: return ACMERR_NOTPOSSIBLE; - } - break; - default: - WARN("Unsupported query %08lx\n", dwQuery); - return MMSYSERR_NOTSUPPORTED; - } - - aftd->fdwSupport = ACMDRIVERDETAILS_SUPPORTF_CODEC; - switch (aftd->dwFormatTagIndex) - { - case 0: - aftd->dwFormatTag = WAVE_FORMAT_PCM; - aftd->cbFormatSize = sizeof(PCMWAVEFORMAT); - aftd->cStandardFormats = NUM_PCM_FORMATS; - lstrcpyW(aftd->szFormatTag, szPcm); - break; - case 1: - aftd->dwFormatTag = WAVE_FORMAT_IMA_ADPCM; - aftd->cbFormatSize = sizeof(IMAADPCMWAVEFORMAT); - aftd->cStandardFormats = NUM_ADPCM_FORMATS; - lstrcpyW(aftd->szFormatTag, szImaAdPcm); - break; - } - return MMSYSERR_NOERROR; -} - -/*********************************************************************** - * ADPCM_FormatDetails - * - */ -static LRESULT ADPCM_FormatDetails(PACMFORMATDETAILSW afd, DWORD dwQuery) -{ - switch (dwQuery) - { - case ACM_FORMATDETAILSF_FORMAT: - if (ADPCM_GetFormatIndex(afd->pwfx) == 0xFFFFFFFF) return ACMERR_NOTPOSSIBLE; - break; - case ACM_FORMATDETAILSF_INDEX: - afd->pwfx->wFormatTag = afd->dwFormatTag; - switch (afd->dwFormatTag) - { - case WAVE_FORMAT_PCM: - if (afd->dwFormatIndex >= NUM_PCM_FORMATS) return ACMERR_NOTPOSSIBLE; - afd->pwfx->nChannels = PCM_Formats[afd->dwFormatIndex].nChannels; - afd->pwfx->nSamplesPerSec = PCM_Formats[afd->dwFormatIndex].rate; - afd->pwfx->wBitsPerSample = PCM_Formats[afd->dwFormatIndex].nBits; - /* native MSACM uses a PCMWAVEFORMAT structure, so cbSize is not accessible - * afd->pwfx->cbSize = 0; - */ - afd->pwfx->nBlockAlign = - (afd->pwfx->nChannels * afd->pwfx->wBitsPerSample) / 8; - afd->pwfx->nAvgBytesPerSec = - afd->pwfx->nSamplesPerSec * afd->pwfx->nBlockAlign; - break; - case WAVE_FORMAT_IMA_ADPCM: - if (afd->dwFormatIndex >= NUM_ADPCM_FORMATS) return ACMERR_NOTPOSSIBLE; - afd->pwfx->nChannels = ADPCM_Formats[afd->dwFormatIndex].nChannels; - afd->pwfx->nSamplesPerSec = ADPCM_Formats[afd->dwFormatIndex].rate; - afd->pwfx->wBitsPerSample = ADPCM_Formats[afd->dwFormatIndex].nBits; - afd->pwfx->nBlockAlign = 1024; - /* we got 4 bits per sample */ - afd->pwfx->nAvgBytesPerSec = - (afd->pwfx->nSamplesPerSec * 4) / 8; - if (afd->cbwfx >= sizeof(WAVEFORMATEX)) - afd->pwfx->cbSize = sizeof(WORD); - if (afd->cbwfx >= sizeof(IMAADPCMWAVEFORMAT)) - ((IMAADPCMWAVEFORMAT*)afd->pwfx)->wSamplesPerBlock = (1024 - 4 * afd->pwfx->nChannels) * (2 / afd->pwfx->nChannels) + 1; - break; - default: - WARN("Unsupported tag %08lx\n", afd->dwFormatTag); - return MMSYSERR_INVALPARAM; - } - break; - default: - WARN("Unsupported query %08lx\n", dwQuery); - return MMSYSERR_NOTSUPPORTED; - } - afd->fdwSupport = ACMDRIVERDETAILS_SUPPORTF_CODEC; - afd->szFormat[0] = 0; /* let MSACM format this for us... */ - - return MMSYSERR_NOERROR; -} - -/*********************************************************************** - * ADPCM_FormatSuggest - * - */ -static LRESULT ADPCM_FormatSuggest(PACMDRVFORMATSUGGEST adfs) -{ - /* some tests ... */ - if (adfs->cbwfxSrc < sizeof(PCMWAVEFORMAT) || - adfs->cbwfxDst < sizeof(PCMWAVEFORMAT) || - ADPCM_GetFormatIndex(adfs->pwfxSrc) == 0xFFFFFFFF) return ACMERR_NOTPOSSIBLE; - /* FIXME: should do those tests against the real size (according to format tag */ - - /* If no suggestion for destination, then copy source value */ - if (!(adfs->fdwSuggest & ACM_FORMATSUGGESTF_NCHANNELS)) - adfs->pwfxDst->nChannels = adfs->pwfxSrc->nChannels; - if (!(adfs->fdwSuggest & ACM_FORMATSUGGESTF_NSAMPLESPERSEC)) - adfs->pwfxDst->nSamplesPerSec = adfs->pwfxSrc->nSamplesPerSec; - - if (!(adfs->fdwSuggest & ACM_FORMATSUGGESTF_WBITSPERSAMPLE)) - { - if (adfs->pwfxSrc->wFormatTag == WAVE_FORMAT_PCM) - adfs->pwfxDst->wBitsPerSample = 4; - else - adfs->pwfxDst->wBitsPerSample = 16; - } - if (!(adfs->fdwSuggest & ACM_FORMATSUGGESTF_WFORMATTAG)) - { - if (adfs->pwfxSrc->wFormatTag == WAVE_FORMAT_PCM) - adfs->pwfxDst->wFormatTag = WAVE_FORMAT_IMA_ADPCM; - else - adfs->pwfxDst->wFormatTag = WAVE_FORMAT_PCM; - } - - /* check if result is ok */ - if (ADPCM_GetFormatIndex(adfs->pwfxDst) == 0xFFFFFFFF) return ACMERR_NOTPOSSIBLE; - - /* recompute other values */ - switch (adfs->pwfxDst->wFormatTag) - { - case WAVE_FORMAT_PCM: - adfs->pwfxDst->nBlockAlign = (adfs->pwfxDst->nChannels * adfs->pwfxDst->wBitsPerSample) / 8; - adfs->pwfxDst->nAvgBytesPerSec = adfs->pwfxDst->nSamplesPerSec * adfs->pwfxDst->nBlockAlign; - break; - case WAVE_FORMAT_IMA_ADPCM: - adfs->pwfxDst->nBlockAlign = 1024; - /* FIXME: not handling header overhead */ - adfs->pwfxDst->nAvgBytesPerSec = ((adfs->pwfxDst->nSamplesPerSec * 4) / 8) * adfs->pwfxSrc->nChannels; - ((IMAADPCMWAVEFORMAT*)adfs->pwfxDst)->wSamplesPerBlock = (1024 - 4 * adfs->pwfxSrc->nChannels) * (2 / adfs->pwfxSrc->nChannels) + 1; - TRACE("setting spb=%u\n", ((IMAADPCMWAVEFORMAT*)adfs->pwfxDst)->wSamplesPerBlock); - break; - default: - FIXME("\n"); - break; - } - - return MMSYSERR_NOERROR; -} - -/*********************************************************************** - * ADPCM_Reset - * - */ -static void ADPCM_Reset(PACMDRVSTREAMINSTANCE adsi, AcmAdpcmData* aad) -{ - aad->stepIndexL = aad->stepIndexR = 0; -} - -/*********************************************************************** - * ADPCM_StreamOpen - * - */ -static LRESULT ADPCM_StreamOpen(PACMDRVSTREAMINSTANCE adsi) -{ - AcmAdpcmData* aad; - unsigned nspb; - - assert(!(adsi->fdwOpen & ACM_STREAMOPENF_ASYNC)); - - if (ADPCM_GetFormatIndex(adsi->pwfxSrc) == 0xFFFFFFFF || - ADPCM_GetFormatIndex(adsi->pwfxDst) == 0xFFFFFFFF) - return ACMERR_NOTPOSSIBLE; - - aad = HeapAlloc(GetProcessHeap(), 0, sizeof(AcmAdpcmData)); - if (aad == 0) return MMSYSERR_NOMEM; - - adsi->dwDriver = (DWORD)aad; - - if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_PCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_PCM) - { - goto theEnd; - } - else if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_IMA_ADPCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_PCM) - { - /* resampling or mono <=> stereo not available - * ADPCM algo only define 16 bit per sample output - */ - if (adsi->pwfxSrc->nSamplesPerSec != adsi->pwfxDst->nSamplesPerSec || - adsi->pwfxSrc->nChannels != adsi->pwfxDst->nChannels || - adsi->pwfxDst->wBitsPerSample != 16) - goto theEnd; - - nspb = ((LPIMAADPCMWAVEFORMAT)adsi->pwfxSrc)->wSamplesPerBlock; - TRACE("spb=%u\n", nspb); - - /* we check that in a block, after the header, samples are present on - * 4-sample packet pattern - * we also check that the block alignement is bigger than the expected size - */ - if (((nspb - 1) & 3) != 0) goto theEnd; - if ((((nspb - 1) / 2) + 4) * adsi->pwfxSrc->nChannels < adsi->pwfxSrc->nBlockAlign) - goto theEnd; - - /* adpcm decoding... */ - if (adsi->pwfxDst->wBitsPerSample == 16 && adsi->pwfxDst->nChannels == 2) - aad->convert = cvtSSima16K; - if (adsi->pwfxDst->wBitsPerSample == 16 && adsi->pwfxDst->nChannels == 1) - aad->convert = cvtMMima16K; - } - else if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_PCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_IMA_ADPCM) - { - if (adsi->pwfxSrc->nSamplesPerSec != adsi->pwfxDst->nSamplesPerSec || - adsi->pwfxSrc->nChannels != adsi->pwfxDst->nChannels || - adsi->pwfxSrc->wBitsPerSample != 16) - goto theEnd; - - nspb = ((LPIMAADPCMWAVEFORMAT)adsi->pwfxDst)->wSamplesPerBlock; - TRACE("spb=%u\n", nspb); - - /* we check that in a block, after the header, samples are present on - * 4-sample packet pattern - * we also check that the block alignement is bigger than the expected size - */ - if (((nspb - 1) & 3) != 0) goto theEnd; - if ((((nspb - 1) / 2) + 4) * adsi->pwfxDst->nChannels < adsi->pwfxDst->nBlockAlign) - goto theEnd; - - /* adpcm coding... */ - if (adsi->pwfxSrc->wBitsPerSample == 16 && adsi->pwfxSrc->nChannels == 2) - aad->convert = cvtSS16imaK; - if (adsi->pwfxSrc->wBitsPerSample == 16 && adsi->pwfxSrc->nChannels == 1) - aad->convert = cvtMM16imaK; - } - else goto theEnd; - ADPCM_Reset(adsi, aad); - - return MMSYSERR_NOERROR; - - theEnd: - HeapFree(GetProcessHeap(), 0, aad); - adsi->dwDriver = 0L; - return MMSYSERR_NOTSUPPORTED; -} - -/*********************************************************************** - * ADPCM_StreamClose - * - */ -static LRESULT ADPCM_StreamClose(PACMDRVSTREAMINSTANCE adsi) -{ - HeapFree(GetProcessHeap(), 0, (void*)adsi->dwDriver); - return MMSYSERR_NOERROR; -} - -/*********************************************************************** - * ADPCM_round - * - */ -static inline DWORD ADPCM_round(DWORD a, DWORD b, DWORD c) -{ - assert(a && b && c); - /* to be sure, always return an entire number of c... */ - return ((double)a * (double)b + (double)c - 1) / (double)c; -} - -/*********************************************************************** - * ADPCM_StreamSize - * - */ -static LRESULT ADPCM_StreamSize(PACMDRVSTREAMINSTANCE adsi, PACMDRVSTREAMSIZE adss) -{ - switch (adss->fdwSize) - { - case ACM_STREAMSIZEF_DESTINATION: - /* cbDstLength => cbSrcLength */ - if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_PCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_IMA_ADPCM) - { - /* don't take block overhead into account, doesn't matter too much */ - adss->cbSrcLength = adss->cbDstLength * 4; - } - else if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_IMA_ADPCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_PCM) - { - FIXME("misses the block header overhead\n"); - adss->cbSrcLength = 256 + adss->cbDstLength / 4; - } - else - { - return MMSYSERR_NOTSUPPORTED; - } - break; - case ACM_STREAMSIZEF_SOURCE: - /* cbSrcLength => cbDstLength */ - if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_PCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_IMA_ADPCM) - { - FIXME("misses the block header overhead\n"); - adss->cbDstLength = 256 + adss->cbSrcLength / 4; - } - else if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_IMA_ADPCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_PCM) - { - /* don't take block overhead into account, doesn't matter too much */ - adss->cbDstLength = adss->cbSrcLength * 4; - } - else - { - return MMSYSERR_NOTSUPPORTED; - } - break; - default: - WARN("Unsupported query %08lx\n", adss->fdwSize); - return MMSYSERR_NOTSUPPORTED; - } - return MMSYSERR_NOERROR; -} - -/*********************************************************************** - * ADPCM_StreamConvert - * - */ -static LRESULT ADPCM_StreamConvert(PACMDRVSTREAMINSTANCE adsi, PACMDRVSTREAMHEADER adsh) -{ - AcmAdpcmData* aad = (AcmAdpcmData*)adsi->dwDriver; - DWORD nsrc = adsh->cbSrcLength; - DWORD ndst = adsh->cbDstLength; - - if (adsh->fdwConvert & - ~(ACM_STREAMCONVERTF_BLOCKALIGN| - ACM_STREAMCONVERTF_END| - ACM_STREAMCONVERTF_START)) - { - FIXME("Unsupported fdwConvert (%08lx), ignoring it\n", adsh->fdwConvert); - } - /* ACM_STREAMCONVERTF_BLOCKALIGN - * currently all conversions are block aligned, so do nothing for this flag - * ACM_STREAMCONVERTF_END - * no pending data, so do nothing for this flag - */ - if ((adsh->fdwConvert & ACM_STREAMCONVERTF_START)) - { - ADPCM_Reset(adsi, aad); - } - - aad->convert(adsi, adsh->pbSrc, &nsrc, adsh->pbDst, &ndst); - adsh->cbSrcLengthUsed = nsrc; - adsh->cbDstLengthUsed = ndst; - - return MMSYSERR_NOERROR; -} - -/************************************************************************** - * ADPCM_DriverProc [exported] - */ -LRESULT CALLBACK ADPCM_DriverProc(DWORD dwDevID, HDRVR hDriv, UINT wMsg, - LPARAM dwParam1, LPARAM dwParam2) -{ - TRACE("(%08lx %08lx %04x %08lx %08lx);\n", - dwDevID, (DWORD)hDriv, wMsg, dwParam1, dwParam2); - - switch (wMsg) - { - case DRV_LOAD: return 1; - case DRV_FREE: return 1; - case DRV_OPEN: return ADPCM_drvOpen((LPSTR)dwParam1); - case DRV_CLOSE: return ADPCM_drvClose(dwDevID); - case DRV_ENABLE: return 1; - case DRV_DISABLE: return 1; - case DRV_QUERYCONFIGURE: return 1; - case DRV_CONFIGURE: MessageBoxA(0, "MSACM IMA ADPCM filter !", "Wine Driver", MB_OK); return 1; - case DRV_INSTALL: return DRVCNF_RESTART; - case DRV_REMOVE: return DRVCNF_RESTART; - - case ACMDM_DRIVER_NOTIFY: - /* no caching from other ACM drivers is done so far */ - return MMSYSERR_NOERROR; - - case ACMDM_DRIVER_DETAILS: - return ADPCM_DriverDetails((PACMDRIVERDETAILSW)dwParam1); - - case ACMDM_FORMATTAG_DETAILS: - return ADPCM_FormatTagDetails((PACMFORMATTAGDETAILSW)dwParam1, dwParam2); - - case ACMDM_FORMAT_DETAILS: - return ADPCM_FormatDetails((PACMFORMATDETAILSW)dwParam1, dwParam2); - - case ACMDM_FORMAT_SUGGEST: - return ADPCM_FormatSuggest((PACMDRVFORMATSUGGEST)dwParam1); - - case ACMDM_STREAM_OPEN: - return ADPCM_StreamOpen((PACMDRVSTREAMINSTANCE)dwParam1); - - case ACMDM_STREAM_CLOSE: - return ADPCM_StreamClose((PACMDRVSTREAMINSTANCE)dwParam1); - - case ACMDM_STREAM_SIZE: - return ADPCM_StreamSize((PACMDRVSTREAMINSTANCE)dwParam1, (PACMDRVSTREAMSIZE)dwParam2); - - case ACMDM_STREAM_CONVERT: - return ADPCM_StreamConvert((PACMDRVSTREAMINSTANCE)dwParam1, (PACMDRVSTREAMHEADER)dwParam2); - - case ACMDM_HARDWARE_WAVE_CAPS_INPUT: - case ACMDM_HARDWARE_WAVE_CAPS_OUTPUT: - /* this converter is not a hardware driver */ - case ACMDM_FILTERTAG_DETAILS: - case ACMDM_FILTER_DETAILS: - /* this converter is not a filter */ - case ACMDM_STREAM_RESET: - /* only needed for asynchronous driver... we aren't, so just say it */ - return MMSYSERR_NOTSUPPORTED; - case ACMDM_STREAM_PREPARE: - case ACMDM_STREAM_UNPREPARE: - /* nothing special to do here... so don't do anything */ - return MMSYSERR_NOERROR; - - default: - return DefDriverProc(dwDevID, hDriv, wMsg, dwParam1, dwParam2); - } - return 0; -} diff --git a/dll/win32/msacm32/lang/msacm_Bg.rc b/dll/win32/msacm32/lang/msacm_Bg.rc index 4b81a16f07b..7cea6ae5491 100644 --- a/dll/win32/msacm32/lang/msacm_Bg.rc +++ b/dll/win32/msacm32/lang/msacm_Bg.rc @@ -18,9 +18,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT +LANGUAGE LANG_BULGARIAN, SUBLANG_DEFAULT -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION " " FONT 8, "MS Shell Dlg" @@ -28,29 +28,24 @@ BEGIN LTEXT "&:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 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, 150, 14, 70, 14 + PUSHBUTTON "&", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&", -1, 5, 76, 44, 8, NOT WS_GROUP -#if 0 - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, - CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP | - CBS_OWNERDRAWFIXED | CBS_HASSTRINGS -#else - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP -#endif - DEFPUSHBUTTON "", IDOK, 48, 80, 40, 14 - PUSHBUTTON "", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + + PUSHBUTTON "&", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "", IDOK, 115, 100, 50, 14 + PUSHBUTTON "", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Cs.rc b/dll/win32/msacm32/lang/msacm_Cs.rc index 8c18f00683e..beaece53bf0 100644 --- a/dll/win32/msacm32/lang/msacm_Cs.rc +++ b/dll/win32/msacm32/lang/msacm_Cs.rc @@ -24,7 +24,7 @@ LANGUAGE LANG_CZECH, SUBLANG_DEFAULT /* Czech strings in CP1250 */ -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Vbr zvuku" FONT 8, "MS Shell Dlg" @@ -32,24 +32,24 @@ BEGIN LTEXT "&Nzev:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Uloit jako", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "Odeb&rat", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "&Uloit jako", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "Odeb&rat", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Formt:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Formt:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Atributy:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Atributy:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Storno", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "P&omoc", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "P&omoc", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Storno", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Da.rc b/dll/win32/msacm32/lang/msacm_Da.rc index d42b4ba20a6..b2411b5e1c1 100644 --- a/dll/win32/msacm32/lang/msacm_Da.rc +++ b/dll/win32/msacm32/lang/msacm_Da.rc @@ -20,7 +20,7 @@ LANGUAGE LANG_DANISH, SUBLANG_DEFAULT -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Lyd valg" FONT 8, "MS Shell Dlg" @@ -28,24 +28,24 @@ BEGIN LTEXT "&Navn:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "Gem &som...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "Fje&rn", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "Gem &som...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "Fje&rn", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Format:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Format:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Attributter:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Attributter:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Annuller", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Hjlp", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Hjlp", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Annuller", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_De.rc b/dll/win32/msacm32/lang/msacm_De.rc index fa964b6c636..aa3158122ad 100644 --- a/dll/win32/msacm32/lang/msacm_De.rc +++ b/dll/win32/msacm32/lang/msacm_De.rc @@ -22,7 +22,7 @@ LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Soundauswahl" FONT 8, "MS Shell Dlg" @@ -30,24 +30,24 @@ BEGIN LTEXT "&Name:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "Speichern &unter...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Entfernen", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "Speichern &unter...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Entfernen", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Format:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Format:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Attribute:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Attribute:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Abbrechen", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Hilfe", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Hilfe", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Abbrechen", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_El.rc b/dll/win32/msacm32/lang/msacm_El.rc index 7aa1eae87b0..4e9f9dfdbd4 100644 --- a/dll/win32/msacm32/lang/msacm_El.rc +++ b/dll/win32/msacm32/lang/msacm_El.rc @@ -15,12 +15,12 @@ * * You should 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 Street, Fifth Floor, Boston, MA 02110-1301 USA + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ LANGUAGE LANG_GREEK, SUBLANG_DEFAULT -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION " " FONT 8, "MS Shell Dlg" @@ -28,29 +28,24 @@ BEGIN LTEXT "&:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 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, 150, 14, 70, 14 + PUSHBUTTON "&", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&:", -1, 5, 76, 44, 8, NOT WS_GROUP -#if 0 - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, - CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP | - CBS_OWNERDRAWFIXED | CBS_HASSTRINGS -#else - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, 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 "&", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_En.rc b/dll/win32/msacm32/lang/msacm_En.rc index dee98caa680..4417159d475 100644 --- a/dll/win32/msacm32/lang/msacm_En.rc +++ b/dll/win32/msacm32/lang/msacm_En.rc @@ -20,7 +20,7 @@ LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Sound Selection" FONT 8, "MS Shell Dlg" @@ -28,24 +28,24 @@ BEGIN LTEXT "&Name:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Save As...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Remove", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "&Save As...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Remove", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Format:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Format:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Attributes:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Attributes:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Cancel", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Help", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Help", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Cancel", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Es.rc b/dll/win32/msacm32/lang/msacm_Es.rc index b18338fb471..754ecbf43ef 100644 --- a/dll/win32/msacm32/lang/msacm_Es.rc +++ b/dll/win32/msacm32/lang/msacm_Es.rc @@ -20,7 +20,7 @@ LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Seleccin de sonido" FONT 8, "MS Shell Dlg" @@ -28,24 +28,24 @@ BEGIN LTEXT "&Nombre:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Guardar como...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Eliminar", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "&Guardar como...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Eliminar", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Formato:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Formato:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "A&tributos:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "A&tributos:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "Aceptar", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Cancelar", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Ayuda", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Ayuda", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "Aceptar", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Cancelar", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Fr.rc b/dll/win32/msacm32/lang/msacm_Fr.rc index 6b61dbb9764..091d611962e 100644 --- a/dll/win32/msacm32/lang/msacm_Fr.rc +++ b/dll/win32/msacm32/lang/msacm_Fr.rc @@ -25,7 +25,7 @@ LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 250, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Sélection du son" FONT 8, "MS Shell Dlg" @@ -33,24 +33,24 @@ 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, 135, 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, 150, 14, 70, 14 + PUSHBUTTON "&Supprimer", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Format :", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Format :", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 48, 39, 197, 15, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Attributs :", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Attributs :", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 48, 57, 197, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Annuler", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "Aid&e", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "Aid&e", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Annuler", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_He.rc b/dll/win32/msacm32/lang/msacm_He.rc index 600ee4ef989..b444e7ef806 100644 --- a/dll/win32/msacm32/lang/msacm_He.rc +++ b/dll/win32/msacm32/lang/msacm_He.rc @@ -25,7 +25,7 @@ LANGUAGE LANG_HEBREW, SUBLANG_DEFAULT -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "בחירת שמע" FONT 8, "MS Shell Dlg" @@ -33,24 +33,24 @@ BEGIN LTEXT "שם:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 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, 150, 14, 70, 14 + PUSHBUTTON "הסר", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "פורמט:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "פורמט:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "מאפיינים:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "מאפיינים:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "אישור", IDOK, 48, 80, 40, 14 - PUSHBUTTON "ביטול", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "עזרה", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "עזרה", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "אישור", IDOK, 115, 100, 50, 14 + PUSHBUTTON "ביטול", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Hu.rc b/dll/win32/msacm32/lang/msacm_Hu.rc index 02ed5f9da61..9ef0dba2e7a 100644 --- a/dll/win32/msacm32/lang/msacm_Hu.rc +++ b/dll/win32/msacm32/lang/msacm_Hu.rc @@ -20,7 +20,7 @@ LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Hang kivlaszts" FONT 8, "MS Shell Dlg" @@ -28,24 +28,24 @@ BEGIN LTEXT "&Nv:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Ments msknt...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Eltvolts", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "&Ments msknt...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Eltvolts", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Formtum:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Formtum:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Attribtumok:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Attribtumok:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Mgse", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Sg", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Sg", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Mgse", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_It.rc b/dll/win32/msacm32/lang/msacm_It.rc index f2c8ff65026..3215528e89c 100644 --- a/dll/win32/msacm32/lang/msacm_It.rc +++ b/dll/win32/msacm32/lang/msacm_It.rc @@ -21,7 +21,7 @@ LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Selezione dell'audio" FONT 8, "MS Shell Dlg" @@ -29,24 +29,24 @@ BEGIN LTEXT "&Nome:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Salva con nome...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Rimuovi", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "&Salva con nome...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Rimuovi", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Formato:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Formato:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Attributi:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Attributi:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Annulla", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Aiuto", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Aiuto", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Annulla", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Ja.rc b/dll/win32/msacm32/lang/msacm_Ja.rc index 420b8c0bffe..c9052571145 100644 --- a/dll/win32/msacm32/lang/msacm_Ja.rc +++ b/dll/win32/msacm32/lang/msacm_Ja.rc @@ -23,7 +23,7 @@ LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "サウンドの選択" FONT 9, "MS Shell Dlg" @@ -31,24 +31,24 @@ BEGIN LTEXT "名前(&N):", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "名前を付けて保存(&S)...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "削除(&R)", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "名前を付けて保存(&S)...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "削除(&R)", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "フォーマット(&F):", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "フォーマット(&F):", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "属性(&A):", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "属性(&A):", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "キャンセル", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "ヘルプ(&H)", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "ヘルプ(&H)", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "キャンセル", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Ko.rc b/dll/win32/msacm32/lang/msacm_Ko.rc index ee960c7aae4..11429bf3bf0 100644 --- a/dll/win32/msacm32/lang/msacm_Ko.rc +++ b/dll/win32/msacm32/lang/msacm_Ko.rc @@ -20,7 +20,7 @@ LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION " " FONT 9, "MS Shell Dlg" @@ -28,24 +28,24 @@ BEGIN LTEXT "̸(&N):", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 97, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "ٸ ̸ (&S)...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 103, 14, 70, 14 - PUSHBUTTON "(&R)", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "ٸ ̸ (&S)...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "(&R)", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "(&F):", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "(&F):", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "Ӽ(&A):", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "Ӽ(&A):", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "Ȯ", IDOK, 48, 80, 40, 14 - PUSHBUTTON "", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "(&H)", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "(&H)", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "Ȯ", IDOK, 115, 100, 50, 14 + PUSHBUTTON "", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Lt.rc b/dll/win32/msacm32/lang/msacm_Lt.rc index d5d34f29a31..87b0ce08465 100644 --- a/dll/win32/msacm32/lang/msacm_Lt.rc +++ b/dll/win32/msacm32/lang/msacm_Lt.rc @@ -23,7 +23,7 @@ LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Garso parinkimas" FONT 8, "MS Shell Dlg" @@ -31,24 +31,24 @@ BEGIN LTEXT "&Pavadinimas:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 100, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "Išsaugoti k&aip...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 110, 14, 60, 14 - PUSHBUTTON "Pa&šalinti", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "Išsaugoti k&aip...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "Pa&šalinti", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Formatas:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Formatas:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "A&tributai:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "A&tributai:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "Gerai", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Atsisakyti", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Žinynas", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Žinynas", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "Gerai", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Atsisakyti", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Nl.rc b/dll/win32/msacm32/lang/msacm_Nl.rc index 16e9cf87367..eef524ca0a2 100644 --- a/dll/win32/msacm32/lang/msacm_Nl.rc +++ b/dll/win32/msacm32/lang/msacm_Nl.rc @@ -20,7 +20,7 @@ LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Geluidskeuze" FONT 8, "MS Shell Dlg" @@ -28,24 +28,24 @@ BEGIN LTEXT "&Naam:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Opslaan als...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Verwijderen", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "&Opslaan als...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Verwijderen", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Formaat:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Formaat:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Attributen:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Attributen:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Annuleren", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Help", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Help", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Annuleren", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_No.rc b/dll/win32/msacm32/lang/msacm_No.rc index da083908b6d..534dd3a6b28 100644 --- a/dll/win32/msacm32/lang/msacm_No.rc +++ b/dll/win32/msacm32/lang/msacm_No.rc @@ -20,7 +20,7 @@ LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Lydutvalg" FONT 8, "MS Shell Dlg" @@ -28,24 +28,24 @@ BEGIN LTEXT "&Navn:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "Lagre &som...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "Fje&rn", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "Lagre &som...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "Fje&rn", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Format:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Format:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Attributter:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Attributter:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Avbryt", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Hjelp", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Hjelp", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Avbryt", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Pl.rc b/dll/win32/msacm32/lang/msacm_Pl.rc index c24c8ec28ed..896fc403fa2 100644 --- a/dll/win32/msacm32/lang/msacm_Pl.rc +++ b/dll/win32/msacm32/lang/msacm_Pl.rc @@ -21,7 +21,7 @@ LANGUAGE LANG_POLISH, SUBLANG_DEFAULT -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 235, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Wybr dwiku" FONT 8, "MS Shell Dlg" @@ -29,24 +29,24 @@ BEGIN LTEXT "&Nazwa:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Zapisz jako...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 50, 14 - PUSHBUTTON "&Usu", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 180, 14, 50, 14 + PUSHBUTTON "&Zapisz jako...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Usu", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Format:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Format:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 180, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Atrybuty:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Atrybuty:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 180, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 53, 80, 40, 14 - PUSHBUTTON "Anuluj", IDCANCEL, 97, 80, 40, 14 - PUSHBUTTON "&Pomoc", IDD_ACMFORMATCHOOSE_BTN_HELP, 141, 80, 40, 14 + PUSHBUTTON "&Pomoc", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Anuluj", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Pt.rc b/dll/win32/msacm32/lang/msacm_Pt.rc index bde9e16ef3d..dc0d6333964 100644 --- a/dll/win32/msacm32/lang/msacm_Pt.rc +++ b/dll/win32/msacm32/lang/msacm_Pt.rc @@ -24,7 +24,7 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Seleção de som" FONT 8, "MS Shell Dlg" @@ -32,31 +32,31 @@ BEGIN LTEXT "&Nome:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Salvar como...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Remover", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "&Salvar como...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Remover", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Formato:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Formato:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Atributos:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Atributos:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Cancelar", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "Aj&uda", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "Aj&uda", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Cancelar", IDCANCEL, 170, 100, 50, 14 END LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Selecção de som" FONT 8, "MS Shell Dlg" @@ -64,24 +64,24 @@ BEGIN LTEXT "&Nome:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Gravar como...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Remover", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "&Gravar como...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Remover", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Formato:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Formato:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Atributos:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Atributos:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Cancelar", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "Aj&uda", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "Aj&uda", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Cancelar", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Ro.rc b/dll/win32/msacm32/lang/msacm_Ro.rc index 396de42f3b2..cd5ec0d33ed 100644 --- a/dll/win32/msacm32/lang/msacm_Ro.rc +++ b/dll/win32/msacm32/lang/msacm_Ro.rc @@ -22,32 +22,32 @@ LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Selecție sunet" FONT 8, "MS Shell Dlg" BEGIN - LTEXT "N&ume:", -1, 5, 5, 115, 8, NOT WS_GROUP + LTEXT "N&ume:", -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 + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, + CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "Pă&strare ca…", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Elimină", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "Pă&strare ca…", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Elimină", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "F&ormat:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "F&ormat:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, - CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, + CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Atribute:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Atribute:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, - CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, + CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "Con&firmă", IDOK, 48, 80, 40, 14 - PUSHBUTTON "A&nulează", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Manual…", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Manual…", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "Con&firmă", IDOK, 115, 100, 50, 14 + PUSHBUTTON "A&nulează", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Ru.rc b/dll/win32/msacm32/lang/msacm_Ru.rc index 5d900b450ea..b9832de4fa0 100644 --- a/dll/win32/msacm32/lang/msacm_Ru.rc +++ b/dll/win32/msacm32/lang/msacm_Ru.rc @@ -23,7 +23,7 @@ LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Выбор звука" FONT 8, "MS Shell Dlg" @@ -31,24 +31,24 @@ BEGIN LTEXT "&Имя:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 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, 150, 14, 70, 14 + PUSHBUTTON "&Удалить", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Формат:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Формат:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Свойства:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Свойства:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Отмена", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Помощь", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Помощь", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Отмена", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Si.rc b/dll/win32/msacm32/lang/msacm_Si.rc index a8b5b2f3e9f..aa3d76a90ac 100644 --- a/dll/win32/msacm32/lang/msacm_Si.rc +++ b/dll/win32/msacm32/lang/msacm_Si.rc @@ -22,7 +22,7 @@ LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Izbira zvoka" FONT 8, "MS Shell Dlg" @@ -30,24 +30,24 @@ BEGIN LTEXT "&Ime:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Shrani kot ...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Odstrani", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "&Shrani kot ...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Odstrani", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Format:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Format:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Lastnosti:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Lastnosti:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "V redu", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Prekliči", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Pomoč", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Pomoč", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "V redu", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Prekliči", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Sq.rc b/dll/win32/msacm32/lang/msacm_Sq.rc index be040012e38..3ffe24bb324 100644 --- a/dll/win32/msacm32/lang/msacm_Sq.rc +++ b/dll/win32/msacm32/lang/msacm_Sq.rc @@ -20,7 +20,7 @@ LANGUAGE LANG_ALBANIAN, SUBLANG_NEUTRAL -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Përzgjedhja Zërit" FONT 8, "MS Shell Dlg" @@ -28,24 +28,24 @@ BEGIN LTEXT "&Emri:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Ruaj Si...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Hiq", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "&Ruaj Si...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Hiq", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Formati:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Formati:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Atributet:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Atributet:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Anulo", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Ndihmë", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Ndihmë", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Anulo", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Sv.rc b/dll/win32/msacm32/lang/msacm_Sv.rc index 70a0a4d169b..4562b3fb1bb 100644 --- a/dll/win32/msacm32/lang/msacm_Sv.rc +++ b/dll/win32/msacm32/lang/msacm_Sv.rc @@ -20,7 +20,7 @@ LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Ljudval" FONT 8, "MS Shell Dlg" @@ -28,24 +28,24 @@ BEGIN LTEXT "&Namn:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "&Spara som...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Ta bort", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "&Spara som...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Ta bort", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Format:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Format:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Attribut:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Attribut:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Avbryt", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Hjlp", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Hjlp", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Avbryt", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Tr.rc b/dll/win32/msacm32/lang/msacm_Tr.rc index a8eb16632b5..6b6547d5abe 100644 --- a/dll/win32/msacm32/lang/msacm_Tr.rc +++ b/dll/win32/msacm32/lang/msacm_Tr.rc @@ -20,7 +20,7 @@ LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Ses Seçme" FONT 8, "MS Shell Dlg" @@ -28,24 +28,24 @@ BEGIN LTEXT "&Ad:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "Ay&rı Sakla...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "&Kaldır", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "Ay&rı Sakla...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "&Kaldır", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Biçim:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Biçim:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Öz Nitelikler:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Öz Nitelikler:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "Tamam", IDOK, 48, 80, 40, 14 - PUSHBUTTON "İptal", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Yardım", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Yardım", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "Tamam", IDOK, 115, 100, 50, 14 + PUSHBUTTON "İptal", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Uk.rc b/dll/win32/msacm32/lang/msacm_Uk.rc index 0476f0e4c08..2fa7b7fae41 100644 --- a/dll/win32/msacm32/lang/msacm_Uk.rc +++ b/dll/win32/msacm32/lang/msacm_Uk.rc @@ -23,7 +23,7 @@ LANGUAGE LANG_UKRAINIAN, SUBLANG_DEFAULT -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Sound Selection" FONT 8, "MS Shell Dlg" @@ -31,24 +31,24 @@ BEGIN LTEXT "&Ім'я:", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 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, 150, 14, 70, 14 + PUSHBUTTON "&Видалити", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "&Формат:", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "&Формат:", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "&Властивості:", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "&Властивості:", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "OK", IDOK, 48, 80, 40, 14 - PUSHBUTTON "Скасувати", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "&Довідка", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "&Довідка", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "OK", IDOK, 115, 100, 50, 14 + PUSHBUTTON "Скасувати", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/lang/msacm_Zh.rc b/dll/win32/msacm32/lang/msacm_Zh.rc index 8238fa8734c..829a714e174 100644 --- a/dll/win32/msacm32/lang/msacm_Zh.rc +++ b/dll/win32/msacm32/lang/msacm_Zh.rc @@ -23,7 +23,7 @@ LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "声音选择" FONT 9, "MS Shell Dlg" @@ -31,31 +31,31 @@ BEGIN LTEXT "名称(&N):", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "保存为(&S)...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "删除(&R)", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "保存为(&S)...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "删除(&R)", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "格式(&F):", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "格式(&F):", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "属性(&A):", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "属性(&A):", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "确定", IDOK, 48, 80, 40, 14 - PUSHBUTTON "取消", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "帮助(&H)", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "帮助(&H)", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "确定", IDOK, 115, 100, 50, 14 + PUSHBUTTON "取消", IDCANCEL, 170, 100, 50, 14 END LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_TRADITIONAL -DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 100 +DLG_ACMFORMATCHOOSE_ID DIALOG 10, 20, 225, 118 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "聲音選擇" FONT 9, "MS Shell Dlg" @@ -63,24 +63,24 @@ BEGIN LTEXT "名稱(&N):", -1, 5, 5, 115, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 115, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_CUSTOM, 5, 15, 135, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - PUSHBUTTON "儲存為(&S)...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 125, 14, 45, 14 - PUSHBUTTON "刪除(&R)", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 175, 14, 45, 14 + PUSHBUTTON "儲存為(&S)...", IDD_ACMFORMATCHOOSE_BTN_SETNAME, 150, 14, 70, 14 + PUSHBUTTON "刪除(&R)", IDD_ACMFORMATCHOOSE_BTN_DELNAME, 150, 32, 70, 14 - LTEXT "格式(&F):", -1, 5, 41, 44, 8, NOT WS_GROUP + LTEXT "格式(&F):", -1, 5, 56, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 39, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMATTAG, 50, 54, 170, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | WS_TABSTOP - LTEXT "屬性(&A):", -1, 5, 59, 44, 8, NOT WS_GROUP + LTEXT "屬性(&A):", -1, 5, 76, 44, 8, NOT WS_GROUP - COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 57, 170, 60, + COMBOBOX IDD_ACMFORMATCHOOSE_CMB_FORMAT, 50, 74, 170, 60, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP - DEFPUSHBUTTON "確定", IDOK, 48, 80, 40, 14 - PUSHBUTTON "取消", IDCANCEL, 92, 80, 40, 14 - PUSHBUTTON "幫助(&H)", IDD_ACMFORMATCHOOSE_BTN_HELP, 136, 80, 40, 14 + PUSHBUTTON "幫助(&H)", IDD_ACMFORMATCHOOSE_BTN_HELP, 5, 100, 50, 14 + DEFPUSHBUTTON "確定", IDOK, 115, 100, 50, 14 + PUSHBUTTON "取消", IDCANCEL, 170, 100, 50, 14 END diff --git a/dll/win32/msacm32/msacm.rc b/dll/win32/msacm32/msacm.rc index d0843efa669..09ae78d9322 100644 --- a/dll/win32/msacm32/msacm.rc +++ b/dll/win32/msacm32/msacm.rc @@ -18,10 +18,9 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ -#include "windef.h" -#include "winbase.h" -#include "winuser.h" -#include "wineacm.h" +#include +#include +#include #ifdef LANGUAGE_BG_BG #include "lang/msacm_Bg.rc" diff --git a/dll/win32/msacm32/msadp32/Makefile.in b/dll/win32/msacm32/msadp32/Makefile.in deleted file mode 100644 index c331f654c86..00000000000 --- a/dll/win32/msacm32/msadp32/Makefile.in +++ /dev/null @@ -1,12 +0,0 @@ -TOPSRCDIR = @top_srcdir@ -TOPOBJDIR = ../../.. -SRCDIR = @srcdir@ -VPATH = @srcdir@ -MODULE = msadp32.acm -IMPORTS = winmm user32 kernel32 - -C_SRCS = msadp32.c - -@MAKE_DLL_RULES@ - -### Dependencies: diff --git a/dll/win32/msacm32/msadp32/msadp32.acm.spec b/dll/win32/msacm32/msadp32/msadp32.acm.spec deleted file mode 100644 index a0ba1c7e701..00000000000 --- a/dll/win32/msacm32/msadp32/msadp32.acm.spec +++ /dev/null @@ -1 +0,0 @@ -@ stdcall DriverProc (long long long long long) ADPCM_DriverProc diff --git a/dll/win32/msacm32/msadp32/msadp32.c b/dll/win32/msacm32/msadp32/msadp32.c deleted file mode 100644 index af96117790b..00000000000 --- a/dll/win32/msacm32/msadp32/msadp32.c +++ /dev/null @@ -1,781 +0,0 @@ -/* - * MS ADPCM handling - * - * Copyright (C) 2002 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 Street, Fifth Floor, Boston, MA 02110-1301 USA - */ - -#include -#include -#include -#include "windef.h" -#include "winbase.h" -#include "wingdi.h" -#include "winuser.h" -#include "winnls.h" -#include "mmsystem.h" -#include "mmreg.h" -#include "msacm.h" -#include "msacmdrv.h" -#include "wine/debug.h" - -/* see http://www.pcisys.net/~melanson/codecs/adpcm.txt for the details */ - -WINE_DEFAULT_DEBUG_CHANNEL(adpcm); - -/*********************************************************************** - * ADPCM_drvOpen - */ -static DWORD ADPCM_drvOpen(LPCSTR str) -{ - return 1; -} - -/*********************************************************************** - * ADPCM_drvClose - */ -static DWORD ADPCM_drvClose(DWORD dwDevID) -{ - return 1; -} - -typedef struct tagAcmAdpcmData -{ - void (*convert)(PACMDRVSTREAMINSTANCE adsi, - const unsigned char*, LPDWORD, unsigned char*, LPDWORD); -} AcmAdpcmData; - -/* table to list all supported formats... those are the basic ones. this - * also helps given a unique index to each of the supported formats - */ -typedef struct -{ - int nChannels; - int nBits; - int rate; -} Format; - -static Format PCM_Formats[] = -{ - {1, 8, 8000}, {2, 8, 8000}, {1, 16, 8000}, {2, 16, 8000}, - {1, 8, 11025}, {2, 8, 11025}, {1, 16, 11025}, {2, 16, 11025}, - {1, 8, 22050}, {2, 8, 22050}, {1, 16, 22050}, {2, 16, 22050}, - {1, 8, 44100}, {2, 8, 44100}, {1, 16, 44100}, {2, 16, 44100}, -}; - -static Format ADPCM_Formats[] = -{ - {1, 4, 8000}, {2, 4, 8000}, {1, 4, 11025}, {2, 4, 11025}, - {1, 4, 22050}, {2, 4, 22050}, {1, 4, 44100}, {2, 4, 44100}, -}; - -#define NUM_PCM_FORMATS (sizeof(PCM_Formats) / sizeof(PCM_Formats[0])) -#define NUM_ADPCM_FORMATS (sizeof(ADPCM_Formats) / sizeof(ADPCM_Formats[0])) - -static int MS_Delta[] = -{ - 230, 230, 230, 230, 307, 409, 512, 614, - 768, 614, 512, 409, 307, 230, 230, 230 -}; - - -static ADPCMCOEFSET MSADPCM_CoeffSet[] = -{ - {256, 0}, {512, -256}, {0, 0}, {192, 64}, {240, 0}, {460, -208}, {392, -232} -}; - -/*********************************************************************** - * ADPCM_GetFormatIndex - */ -static DWORD ADPCM_GetFormatIndex(WAVEFORMATEX* wfx) -{ - int i, hi; - Format* fmts; - - switch (wfx->wFormatTag) - { - case WAVE_FORMAT_PCM: - hi = NUM_PCM_FORMATS; - fmts = PCM_Formats; - break; - case WAVE_FORMAT_ADPCM: - hi = NUM_ADPCM_FORMATS; - fmts = ADPCM_Formats; - break; - default: - return 0xFFFFFFFF; - } - - for (i = 0; i < hi; i++) - { - if (wfx->nChannels == fmts[i].nChannels && - wfx->nSamplesPerSec == fmts[i].rate && - wfx->wBitsPerSample == fmts[i].nBits) - return i; - } - - return 0xFFFFFFFF; -} - -static void init_wfx_adpcm(ADPCMWAVEFORMAT* awfx) -{ - register WAVEFORMATEX* pwfx = &awfx->wfx; - - /* we assume wFormatTag, nChannels, nSamplesPerSec and wBitsPerSample - * have been initialized... */ - - if (pwfx->wFormatTag != WAVE_FORMAT_ADPCM) {FIXME("wrong FT\n"); return;} - if (ADPCM_GetFormatIndex(pwfx) == 0xFFFFFFFF) {FIXME("wrong fmt\n"); return;} - - switch (pwfx->nSamplesPerSec) - { - case 8000: pwfx->nBlockAlign = 256; break; - case 11025: pwfx->nBlockAlign = 256; break; - case 22050: pwfx->nBlockAlign = 512; break; - default: - case 44100: pwfx->nBlockAlign = 1024; break; - } - pwfx->cbSize = 2 * sizeof(WORD) + 7 * sizeof(ADPCMCOEFSET); - /* 7 is the size of the block head (which contains two samples) */ - - awfx->wSamplesPerBlock = (pwfx->nBlockAlign - (7 * pwfx->nChannels)) * (2 / pwfx->nChannels) + 2; - pwfx->nAvgBytesPerSec = (pwfx->nSamplesPerSec * pwfx->nBlockAlign) / awfx->wSamplesPerBlock; - awfx->wNumCoef = 7; - memcpy(awfx->aCoef, MSADPCM_CoeffSet, 7 * sizeof(ADPCMCOEFSET)); -} - -/*********************************************************************** - * R16 - * - * Read a 16 bit sample (correctly handles endianess) - */ -static inline short R16(const unsigned char* src) -{ - return (short)((unsigned short)src[0] | ((unsigned short)src[1] << 8)); -} - -/*********************************************************************** - * W16 - * - * Write a 16 bit sample (correctly handles endianess) - */ -static inline void W16(unsigned char* dst, short s) -{ - dst[0] = LOBYTE(s); - dst[1] = HIBYTE(s); -} - -static inline void clamp_sample(int* sample) -{ - if (*sample < -32768) *sample = -32768; - if (*sample > 32767) *sample = 32767; -} - -static inline void process_nibble(unsigned nibble, int* idelta, - int* sample1, int* sample2, - const ADPCMCOEFSET* coeff) -{ - int sample; - int snibble; - - /* nibble is in fact a signed 4 bit integer => propagate sign if needed */ - snibble = (nibble & 0x08) ? (nibble - 16) : nibble; - sample = ((*sample1 * coeff->iCoef1) + (*sample2 * coeff->iCoef2)) / 256 + - snibble * *idelta; - clamp_sample(&sample); - - *sample2 = *sample1; - *sample1 = sample; - *idelta = ((MS_Delta[nibble] * *idelta) / 256); - if (*idelta < 16) *idelta = 16; -} - -static void cvtSSms16K(PACMDRVSTREAMINSTANCE adsi, - const unsigned char* src, LPDWORD nsrc, - unsigned char* dst, LPDWORD ndst) -{ - int ideltaL, ideltaR; - int sample1L, sample2L; - int sample1R, sample2R; - ADPCMCOEFSET coeffL, coeffR; - int nsamp; - int nsamp_blk = ((ADPCMWAVEFORMAT*)adsi->pwfxSrc)->wSamplesPerBlock; - DWORD nblock = min(*nsrc / adsi->pwfxSrc->nBlockAlign, - *ndst / (nsamp_blk * 2 * 2)); - - *nsrc = nblock * adsi->pwfxSrc->nBlockAlign; - *ndst = nblock * nsamp_blk * 2 * 2; - - nsamp_blk -= 2; /* see below for samples from block head */ - for (; nblock > 0; nblock--) - { - const unsigned char* in_src = src; - - assert(*src <= 6); - coeffL = MSADPCM_CoeffSet[*src++]; - assert(*src <= 6); - coeffR = MSADPCM_CoeffSet[*src++]; - - ideltaL = R16(src); src += 2; - ideltaR = R16(src); src += 2; - sample1L = R16(src); src += 2; - sample1R = R16(src); src += 2; - sample2L = R16(src); src += 2; - sample2R = R16(src); src += 2; - - /* store samples from block head */ - W16(dst, sample2L); dst += 2; - W16(dst, sample2R); dst += 2; - W16(dst, sample1L); dst += 2; - W16(dst, sample1R); dst += 2; - - for (nsamp = nsamp_blk; nsamp > 0; nsamp--) - { - process_nibble(*src >> 4, &ideltaL, &sample1L, &sample2L, &coeffL); - W16(dst, sample1L); dst += 2; - process_nibble(*src++ & 0x0F, &ideltaR, &sample1R, &sample2R, &coeffR); - W16(dst, sample1R); dst += 2; - } - src = in_src + adsi->pwfxSrc->nBlockAlign; - } -} - -static void cvtMMms16K(PACMDRVSTREAMINSTANCE adsi, - const unsigned char* src, LPDWORD nsrc, - unsigned char* dst, LPDWORD ndst) -{ - int idelta; - int sample1, sample2; - ADPCMCOEFSET coeff; - int nsamp; - int nsamp_blk = ((ADPCMWAVEFORMAT*)adsi->pwfxSrc)->wSamplesPerBlock; - DWORD nblock = min(*nsrc / adsi->pwfxSrc->nBlockAlign, - *ndst / (nsamp_blk * 2)); - - *nsrc = nblock * adsi->pwfxSrc->nBlockAlign; - *ndst = nblock * nsamp_blk * 2; - - nsamp_blk -= 2; /* see below for samples from block head */ - for (; nblock > 0; nblock--) - { - const unsigned char* in_src = src; - - assert(*src <= 6); - coeff = MSADPCM_CoeffSet[*src++]; - - idelta = R16(src); src += 2; - sample1 = R16(src); src += 2; - sample2 = R16(src); src += 2; - - /* store samples from block head */ - W16(dst, sample2); dst += 2; - W16(dst, sample1); dst += 2; - - for (nsamp = nsamp_blk; nsamp > 0; nsamp -= 2) - { - process_nibble(*src >> 4, &idelta, &sample1, &sample2, &coeff); - W16(dst, sample1); dst += 2; - process_nibble(*src++ & 0x0F, &idelta, &sample1, &sample2, &coeff); - W16(dst, sample1); dst += 2; - } - src = in_src + adsi->pwfxSrc->nBlockAlign; - } -} - -#if 0 -static void cvtSS16msK(PACMDRVSTREAMINSTANCE adsi, - const unsigned char* src, LPDWORD nsrc, - unsigned char* dst, LPDWORD ndst) -{ -} - -static void cvtMM16msK(PACMDRVSTREAMINSTANCE adsi, - const unsigned char* src, LPDWORD nsrc, - unsigned char* dst, LPDWORD ndst) -{ -} -#endif - -/*********************************************************************** - * ADPCM_DriverDetails - * - */ -static LRESULT ADPCM_DriverDetails(PACMDRIVERDETAILSW add) -{ - add->fccType = ACMDRIVERDETAILS_FCCTYPE_AUDIOCODEC; - add->fccComp = ACMDRIVERDETAILS_FCCCOMP_UNDEFINED; - add->wMid = 0xFF; - add->wPid = 0x00; - add->vdwACM = 0x01000000; - add->vdwDriver = 0x01000000; - add->fdwSupport = ACMDRIVERDETAILS_SUPPORTF_CODEC; - add->cFormatTags = 2; /* PCM, MS ADPCM */ - add->cFilterTags = 0; - add->hicon = NULL; - MultiByteToWideChar( CP_ACP, 0, "WINE-MS ADPCM", -1, - add->szShortName, sizeof(add->szShortName)/sizeof(WCHAR) ); - MultiByteToWideChar( CP_ACP, 0, "Wine MS ADPCM converter", -1, - add->szLongName, sizeof(add->szLongName)/sizeof(WCHAR) ); - MultiByteToWideChar( CP_ACP, 0, "Brought to you by the Wine team...", -1, - add->szCopyright, sizeof(add->szCopyright)/sizeof(WCHAR) ); - MultiByteToWideChar( CP_ACP, 0, "Refer to LICENSE file", -1, - add->szLicensing, sizeof(add->szLicensing)/sizeof(WCHAR) ); - add->szFeatures[0] = 0; - - return MMSYSERR_NOERROR; -} - -/*********************************************************************** - * ADPCM_FormatTagDetails - * - */ -static LRESULT ADPCM_FormatTagDetails(PACMFORMATTAGDETAILSW aftd, DWORD dwQuery) -{ - static WCHAR szPcm[]={'P','C','M',0}; - static WCHAR szMsAdPcm[]={'M','S',' ','A','d','P','C','M',0}; - - switch (dwQuery) - { - case ACM_FORMATTAGDETAILSF_INDEX: - if (aftd->dwFormatTagIndex >= 2) return ACMERR_NOTPOSSIBLE; - break; - case ACM_FORMATTAGDETAILSF_LARGESTSIZE: - if (aftd->dwFormatTag == WAVE_FORMAT_UNKNOWN) - { - aftd->dwFormatTagIndex = 1; /* WAVE_FORMAT_ADPCM is bigger than PCM */ - break; - } - /* fall thru */ - case ACM_FORMATTAGDETAILSF_FORMATTAG: - switch (aftd->dwFormatTag) - { - case WAVE_FORMAT_PCM: aftd->dwFormatTagIndex = 0; break; - case WAVE_FORMAT_ADPCM: aftd->dwFormatTagIndex = 1; break; - default: return ACMERR_NOTPOSSIBLE; - } - break; - default: - WARN("Unsupported query %08lx\n", dwQuery); - return MMSYSERR_NOTSUPPORTED; - } - - aftd->fdwSupport = ACMDRIVERDETAILS_SUPPORTF_CODEC; - switch (aftd->dwFormatTagIndex) - { - case 0: - aftd->dwFormatTag = WAVE_FORMAT_PCM; - aftd->cbFormatSize = sizeof(PCMWAVEFORMAT); - aftd->cStandardFormats = NUM_PCM_FORMATS; - lstrcpyW(aftd->szFormatTag, szPcm); - break; - case 1: - aftd->dwFormatTag = WAVE_FORMAT_ADPCM; - aftd->cbFormatSize = sizeof(ADPCMWAVEFORMAT) + (7 - 1) * sizeof(ADPCMCOEFSET); - aftd->cStandardFormats = NUM_ADPCM_FORMATS; - lstrcpyW(aftd->szFormatTag, szMsAdPcm); - break; - } - return MMSYSERR_NOERROR; -} - -/*********************************************************************** - * ADPCM_FormatDetails - * - */ -static LRESULT ADPCM_FormatDetails(PACMFORMATDETAILSW afd, DWORD dwQuery) -{ - switch (dwQuery) - { - case ACM_FORMATDETAILSF_FORMAT: - if (ADPCM_GetFormatIndex(afd->pwfx) == 0xFFFFFFFF) return ACMERR_NOTPOSSIBLE; - break; - case ACM_FORMATDETAILSF_INDEX: - afd->pwfx->wFormatTag = afd->dwFormatTag; - switch (afd->dwFormatTag) - { - case WAVE_FORMAT_PCM: - if (afd->dwFormatIndex >= NUM_PCM_FORMATS) return ACMERR_NOTPOSSIBLE; - afd->pwfx->nChannels = PCM_Formats[afd->dwFormatIndex].nChannels; - afd->pwfx->nSamplesPerSec = PCM_Formats[afd->dwFormatIndex].rate; - afd->pwfx->wBitsPerSample = PCM_Formats[afd->dwFormatIndex].nBits; - /* native MSACM uses a PCMWAVEFORMAT structure, so cbSize is not accessible - * afd->pwfx->cbSize = 0; - */ - afd->pwfx->nBlockAlign = - (afd->pwfx->nChannels * afd->pwfx->wBitsPerSample) / 8; - afd->pwfx->nAvgBytesPerSec = - afd->pwfx->nSamplesPerSec * afd->pwfx->nBlockAlign; - break; - case WAVE_FORMAT_ADPCM: - if (afd->dwFormatIndex >= NUM_ADPCM_FORMATS) return ACMERR_NOTPOSSIBLE; - if (afd->cbwfx < sizeof(ADPCMWAVEFORMAT) + (7 - 1) * sizeof(ADPCMCOEFSET)) - return ACMERR_NOTPOSSIBLE; - afd->pwfx->nChannels = ADPCM_Formats[afd->dwFormatIndex].nChannels; - afd->pwfx->nSamplesPerSec = ADPCM_Formats[afd->dwFormatIndex].rate; - afd->pwfx->wBitsPerSample = ADPCM_Formats[afd->dwFormatIndex].nBits; - init_wfx_adpcm((ADPCMWAVEFORMAT*)afd->pwfx); - break; - default: - WARN("Unsupported tag %08lx\n", afd->dwFormatTag); - return MMSYSERR_INVALPARAM; - } - break; - default: - WARN("Unsupported query %08lx\n", dwQuery); - return MMSYSERR_NOTSUPPORTED; - } - afd->fdwSupport = ACMDRIVERDETAILS_SUPPORTF_CODEC; - afd->szFormat[0] = 0; /* let MSACM format this for us... */ - - return MMSYSERR_NOERROR; -} - -/*********************************************************************** - * ADPCM_FormatSuggest - * - */ -static LRESULT ADPCM_FormatSuggest(PACMDRVFORMATSUGGEST adfs) -{ - /* some tests ... */ - if (adfs->cbwfxSrc < sizeof(PCMWAVEFORMAT) || - adfs->cbwfxDst < sizeof(PCMWAVEFORMAT) || - ADPCM_GetFormatIndex(adfs->pwfxSrc) == 0xFFFFFFFF) return ACMERR_NOTPOSSIBLE; - /* FIXME: should do those tests against the real size (according to format tag */ - - /* If no suggestion for destination, then copy source value */ - if (!(adfs->fdwSuggest & ACM_FORMATSUGGESTF_NCHANNELS)) - adfs->pwfxDst->nChannels = adfs->pwfxSrc->nChannels; - if (!(adfs->fdwSuggest & ACM_FORMATSUGGESTF_NSAMPLESPERSEC)) - adfs->pwfxDst->nSamplesPerSec = adfs->pwfxSrc->nSamplesPerSec; - - if (!(adfs->fdwSuggest & ACM_FORMATSUGGESTF_WBITSPERSAMPLE)) - { - if (adfs->pwfxSrc->wFormatTag == WAVE_FORMAT_PCM) - adfs->pwfxDst->wBitsPerSample = 4; - else - adfs->pwfxDst->wBitsPerSample = 16; - } - if (!(adfs->fdwSuggest & ACM_FORMATSUGGESTF_WFORMATTAG)) - { - if (adfs->pwfxSrc->wFormatTag == WAVE_FORMAT_PCM) - adfs->pwfxDst->wFormatTag = WAVE_FORMAT_ADPCM; - else - adfs->pwfxDst->wFormatTag = WAVE_FORMAT_PCM; - } - - /* check if result is ok */ - if (ADPCM_GetFormatIndex(adfs->pwfxDst) == 0xFFFFFFFF) return ACMERR_NOTPOSSIBLE; - - /* recompute other values */ - switch (adfs->pwfxDst->wFormatTag) - { - case WAVE_FORMAT_PCM: - adfs->pwfxDst->nBlockAlign = (adfs->pwfxDst->nChannels * adfs->pwfxDst->wBitsPerSample) / 8; - adfs->pwfxDst->nAvgBytesPerSec = adfs->pwfxDst->nSamplesPerSec * adfs->pwfxDst->nBlockAlign; - break; - case WAVE_FORMAT_ADPCM: - init_wfx_adpcm((ADPCMWAVEFORMAT*)adfs->pwfxDst); - break; - default: - FIXME("\n"); - break; - } - - return MMSYSERR_NOERROR; -} - -/*********************************************************************** - * ADPCM_Reset - * - */ -static void ADPCM_Reset(PACMDRVSTREAMINSTANCE adsi, AcmAdpcmData* aad) -{ -} - -/*********************************************************************** - * ADPCM_StreamOpen - * - */ -static LRESULT ADPCM_StreamOpen(PACMDRVSTREAMINSTANCE adsi) -{ - AcmAdpcmData* aad; - - assert(!(adsi->fdwOpen & ACM_STREAMOPENF_ASYNC)); - - if (ADPCM_GetFormatIndex(adsi->pwfxSrc) == 0xFFFFFFFF || - ADPCM_GetFormatIndex(adsi->pwfxDst) == 0xFFFFFFFF) - return ACMERR_NOTPOSSIBLE; - - aad = HeapAlloc(GetProcessHeap(), 0, sizeof(AcmAdpcmData)); - if (aad == 0) return MMSYSERR_NOMEM; - - adsi->dwDriver = (DWORD)aad; - - if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_PCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_PCM) - { - goto theEnd; - } - else if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_ADPCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_PCM) - { - /* resampling or mono <=> stereo not available - * ADPCM algo only define 16 bit per sample output - */ - if (adsi->pwfxSrc->nSamplesPerSec != adsi->pwfxDst->nSamplesPerSec || - adsi->pwfxSrc->nChannels != adsi->pwfxDst->nChannels || - adsi->pwfxDst->wBitsPerSample != 16) - goto theEnd; - -#if 0 - { - unsigned int nspb = ((IMAADPCMWAVEFORMAT*)adsi->pwfxSrc)->wSamplesPerBlock; - FIXME("spb=%u\n", nspb); - - /* we check that in a block, after the header, samples are present on - * 4-sample packet pattern - * we also check that the block alignement is bigger than the expected size - */ - if (((nspb - 1) & 3) != 0) goto theEnd; - if ((((nspb - 1) / 2) + 4) * adsi->pwfxSrc->nChannels < adsi->pwfxSrc->nBlockAlign) - goto theEnd; - } -#endif - - /* adpcm decoding... */ - if (adsi->pwfxDst->wBitsPerSample == 16 && adsi->pwfxDst->nChannels == 2) - aad->convert = cvtSSms16K; - if (adsi->pwfxDst->wBitsPerSample == 16 && adsi->pwfxDst->nChannels == 1) - aad->convert = cvtMMms16K; - } - else if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_PCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_ADPCM) - { - if (adsi->pwfxSrc->nSamplesPerSec != adsi->pwfxDst->nSamplesPerSec || - adsi->pwfxSrc->nChannels != adsi->pwfxDst->nChannels || - adsi->pwfxSrc->wBitsPerSample != 16) - goto theEnd; -#if 0 - nspb = ((IMAADPCMWAVEFORMAT*)adsi->pwfxDst)->wSamplesPerBlock; - FIXME("spb=%u\n", nspb); - - /* we check that in a block, after the header, samples are present on - * 4-sample packet pattern - * we also check that the block alignement is bigger than the expected size - */ - if (((nspb - 1) & 3) != 0) goto theEnd; - if ((((nspb - 1) / 2) + 4) * adsi->pwfxDst->nChannels < adsi->pwfxDst->nBlockAlign) - goto theEnd; -#endif -#if 0 - /* adpcm coding... */ - if (adsi->pwfxSrc->wBitsPerSample == 16 && adsi->pwfxSrc->nChannels == 2) - aad->convert = cvtSS16msK; - if (adsi->pwfxSrc->wBitsPerSample == 16 && adsi->pwfxSrc->nChannels == 1) - aad->convert = cvtMM16msK; -#endif - FIXME("We don't support encoding yet\n"); - goto theEnd; - } - else goto theEnd; - ADPCM_Reset(adsi, aad); - - return MMSYSERR_NOERROR; - - theEnd: - HeapFree(GetProcessHeap(), 0, aad); - adsi->dwDriver = 0L; - return MMSYSERR_NOTSUPPORTED; -} - -/*********************************************************************** - * ADPCM_StreamClose - * - */ -static LRESULT ADPCM_StreamClose(PACMDRVSTREAMINSTANCE adsi) -{ - HeapFree(GetProcessHeap(), 0, (void*)adsi->dwDriver); - return MMSYSERR_NOERROR; -} - -/*********************************************************************** - * ADPCM_round - * - */ -static inline DWORD ADPCM_round(DWORD a, DWORD b, DWORD c) -{ - assert(a && b && c); - /* to be sure, always return an entire number of c... */ - return ((double)a * (double)b + (double)c - 1) / (double)c; -} - -/*********************************************************************** - * ADPCM_StreamSize - * - */ -static LRESULT ADPCM_StreamSize(PACMDRVSTREAMINSTANCE adsi, PACMDRVSTREAMSIZE adss) -{ - switch (adss->fdwSize) - { - case ACM_STREAMSIZEF_DESTINATION: - /* cbDstLength => cbSrcLength */ - if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_PCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_ADPCM) - { - /* don't take block overhead into account, doesn't matter too much */ - adss->cbSrcLength = adss->cbDstLength * 4; - } - else if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_ADPCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_PCM) - { - FIXME("misses the block header overhead\n"); - adss->cbSrcLength = 256 + adss->cbDstLength / 4; - } - else - { - return MMSYSERR_NOTSUPPORTED; - } - break; - case ACM_STREAMSIZEF_SOURCE: - /* cbSrcLength => cbDstLength */ - if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_PCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_ADPCM) - { - FIXME("misses the block header overhead\n"); - adss->cbDstLength = 256 + adss->cbSrcLength / 4; - } - else if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_ADPCM && - adsi->pwfxDst->wFormatTag == WAVE_FORMAT_PCM) - { - /* don't take block overhead into account, doesn't matter too much */ - adss->cbDstLength = adss->cbSrcLength * 4; - } - else - { - return MMSYSERR_NOTSUPPORTED; - } - break; - default: - WARN("Unsupported query %08lx\n", adss->fdwSize); - return MMSYSERR_NOTSUPPORTED; - } - return MMSYSERR_NOERROR; -} - -/*********************************************************************** - * ADPCM_StreamConvert - * - */ -static LRESULT ADPCM_StreamConvert(PACMDRVSTREAMINSTANCE adsi, PACMDRVSTREAMHEADER adsh) -{ - AcmAdpcmData* aad = (AcmAdpcmData*)adsi->dwDriver; - DWORD nsrc = adsh->cbSrcLength; - DWORD ndst = adsh->cbDstLength; - - if (adsh->fdwConvert & - ~(ACM_STREAMCONVERTF_BLOCKALIGN| - ACM_STREAMCONVERTF_END| - ACM_STREAMCONVERTF_START)) - { - FIXME("Unsupported fdwConvert (%08lx), ignoring it\n", adsh->fdwConvert); - } - /* ACM_STREAMCONVERTF_BLOCKALIGN - * currently all conversions are block aligned, so do nothing for this flag - * ACM_STREAMCONVERTF_END - * no pending data, so do nothing for this flag - */ - if ((adsh->fdwConvert & ACM_STREAMCONVERTF_START)) - { - ADPCM_Reset(adsi, aad); - } - - aad->convert(adsi, adsh->pbSrc, &nsrc, adsh->pbDst, &ndst); - adsh->cbSrcLengthUsed = nsrc; - adsh->cbDstLengthUsed = ndst; - - return MMSYSERR_NOERROR; -} - -/************************************************************************** - * ADPCM_DriverProc [exported] - */ -LRESULT CALLBACK ADPCM_DriverProc(DWORD dwDevID, HDRVR hDriv, UINT wMsg, - LPARAM dwParam1, LPARAM dwParam2) -{ - TRACE("(%08lx %08lx %04x %08lx %08lx);\n", - dwDevID, (DWORD)hDriv, wMsg, dwParam1, dwParam2); - - switch (wMsg) - { - case DRV_LOAD: return 1; - case DRV_FREE: return 1; - case DRV_OPEN: return ADPCM_drvOpen((LPSTR)dwParam1); - case DRV_CLOSE: return ADPCM_drvClose(dwDevID); - case DRV_ENABLE: return 1; - case DRV_DISABLE: return 1; - case DRV_QUERYCONFIGURE: return 1; - case DRV_CONFIGURE: MessageBoxA(0, "MSACM MS ADPCM filter !", "Wine Driver", MB_OK); return 1; - case DRV_INSTALL: return DRVCNF_RESTART; - case DRV_REMOVE: return DRVCNF_RESTART; - - case ACMDM_DRIVER_NOTIFY: - /* no caching from other ACM drivers is done so far */ - return MMSYSERR_NOERROR; - - case ACMDM_DRIVER_DETAILS: - return ADPCM_DriverDetails((PACMDRIVERDETAILSW)dwParam1); - - case ACMDM_FORMATTAG_DETAILS: - return ADPCM_FormatTagDetails((PACMFORMATTAGDETAILSW)dwParam1, dwParam2); - - case ACMDM_FORMAT_DETAILS: - return ADPCM_FormatDetails((PACMFORMATDETAILSW)dwParam1, dwParam2); - - case ACMDM_FORMAT_SUGGEST: - return ADPCM_FormatSuggest((PACMDRVFORMATSUGGEST)dwParam1); - - case ACMDM_STREAM_OPEN: - return ADPCM_StreamOpen((PACMDRVSTREAMINSTANCE)dwParam1); - - case ACMDM_STREAM_CLOSE: - return ADPCM_StreamClose((PACMDRVSTREAMINSTANCE)dwParam1); - - case ACMDM_STREAM_SIZE: - return ADPCM_StreamSize((PACMDRVSTREAMINSTANCE)dwParam1, (PACMDRVSTREAMSIZE)dwParam2); - - case ACMDM_STREAM_CONVERT: - return ADPCM_StreamConvert((PACMDRVSTREAMINSTANCE)dwParam1, (PACMDRVSTREAMHEADER)dwParam2); - - case ACMDM_HARDWARE_WAVE_CAPS_INPUT: - case ACMDM_HARDWARE_WAVE_CAPS_OUTPUT: - /* this converter is not a hardware driver */ - case ACMDM_FILTERTAG_DETAILS: - case ACMDM_FILTER_DETAILS: - /* this converter is not a filter */ - case ACMDM_STREAM_RESET: - /* only needed for asynchronous driver... we aren't, so just say it */ - return MMSYSERR_NOTSUPPORTED; - case ACMDM_STREAM_PREPARE: - case ACMDM_STREAM_UNPREPARE: - /* nothing special to do here... so don't do anything */ - return MMSYSERR_NOERROR; - - default: - return DefDriverProc(dwDevID, hDriv, wMsg, dwParam1, dwParam2); - } - return 0; -} diff --git a/dll/win32/mscms/profile.c b/dll/win32/mscms/profile.c index f3cd1339148..c142a492ad3 100644 --- a/dll/win32/mscms/profile.c +++ b/dll/win32/mscms/profile.c @@ -357,8 +357,6 @@ BOOL WINAPI GetColorProfileElement( HPROFILE handle, TAGTYPE type, DWORD offset, ret = get_tag_data( profile, type, offset, buffer, size ); *ref = cmsTagLinkedTo( profile->cmsprofile, type ) != 0; release_profile( profile ); - return ret; - #endif /* HAVE_LCMS2 */ return ret; } @@ -1235,8 +1233,6 @@ BOOL WINAPI SetColorProfileElement( HPROFILE handle, TAGTYPE type, DWORD offset, } ret = set_tag_data( profile, type, offset, buffer, size ); release_profile( profile ); - return ret; - #endif /* HAVE_LCMS2 */ return ret; } diff --git a/dll/win32/msctf/inputprocessor.c b/dll/win32/msctf/inputprocessor.c index f7561a959bc..6770a97ce8a 100644 --- a/dll/win32/msctf/inputprocessor.c +++ b/dll/win32/msctf/inputprocessor.c @@ -42,7 +42,7 @@ typedef struct tagInputProcessorProfilesSink { typedef struct tagInputProcessorProfiles { ITfInputProcessorProfiles ITfInputProcessorProfiles_iface; ITfSource ITfSource_iface; - /* const ITfInputProcessorProfileMgrVtbl *InputProcessorProfileMgrVtbl; */ + ITfInputProcessorProfileMgr ITfInputProcessorProfileMgr_iface; /* const ITfInputProcessorProfilesExVtbl *InputProcessorProfilesExVtbl; */ /* const ITfInputProcessorProfileSubstituteLayoutVtbl *InputProcessorProfileSubstituteLayoutVtbl; */ LONG refCount; @@ -75,9 +75,107 @@ typedef struct tagEnumTfLanguageProfiles { ITfCategoryMgr *catmgr; } EnumTfLanguageProfiles; +typedef struct { + IEnumTfInputProcessorProfiles IEnumTfInputProcessorProfiles_iface; + LONG ref; +} EnumTfInputProcessorProfiles; + static HRESULT ProfilesEnumGuid_Constructor(IEnumGUID **ppOut); static HRESULT EnumTfLanguageProfiles_Constructor(LANGID langid, IEnumTfLanguageProfiles **ppOut); +static inline EnumTfInputProcessorProfiles *impl_from_IEnumTfInputProcessorProfiles(IEnumTfInputProcessorProfiles *iface) +{ + return CONTAINING_RECORD(iface, EnumTfInputProcessorProfiles, IEnumTfInputProcessorProfiles_iface); +} + +static HRESULT WINAPI EnumTfInputProcessorProfiles_QueryInterface(IEnumTfInputProcessorProfiles *iface, + REFIID riid, void **ppv) +{ + EnumTfInputProcessorProfiles *This = impl_from_IEnumTfInputProcessorProfiles(iface); + + if(IsEqualGUID(riid, &IID_IUnknown)) { + TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); + *ppv = &This->IEnumTfInputProcessorProfiles_iface; + }else if(IsEqualGUID(riid, &IID_IEnumTfInputProcessorProfiles)) { + TRACE("(%p)->(IID_IEnumTfInputProcessorProfiles %p)\n", This, ppv); + *ppv = &This->IEnumTfInputProcessorProfiles_iface; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); + return E_NOINTERFACE; + } + + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; +} + +static ULONG WINAPI EnumTfInputProcessorProfiles_AddRef(IEnumTfInputProcessorProfiles *iface) +{ + EnumTfInputProcessorProfiles *This = impl_from_IEnumTfInputProcessorProfiles(iface); + LONG ref = InterlockedIncrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); + + return ref; +} + +static ULONG WINAPI EnumTfInputProcessorProfiles_Release(IEnumTfInputProcessorProfiles *iface) +{ + EnumTfInputProcessorProfiles *This = impl_from_IEnumTfInputProcessorProfiles(iface); + LONG ref = InterlockedDecrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); + + if(!ref) + HeapFree(GetProcessHeap(), 0, This); + + return ref; +} + +static HRESULT WINAPI EnumTfInputProcessorProfiles_Clone(IEnumTfInputProcessorProfiles *iface, + IEnumTfInputProcessorProfiles **ret) +{ + EnumTfInputProcessorProfiles *This = impl_from_IEnumTfInputProcessorProfiles(iface); + FIXME("(%p)->(%p)\n", This, ret); + return E_NOTIMPL; +} + +static HRESULT WINAPI EnumTfInputProcessorProfiles_Next(IEnumTfInputProcessorProfiles *iface, ULONG count, + TF_INPUTPROCESSORPROFILE *profile, ULONG *fetch) +{ + EnumTfInputProcessorProfiles *This = impl_from_IEnumTfInputProcessorProfiles(iface); + + FIXME("(%p)->(%u %p %p)\n", This, count, profile, fetch); + + if(fetch) + *fetch = 0; + return S_FALSE; +} + +static HRESULT WINAPI EnumTfInputProcessorProfiles_Reset(IEnumTfInputProcessorProfiles *iface) +{ + EnumTfInputProcessorProfiles *This = impl_from_IEnumTfInputProcessorProfiles(iface); + FIXME("(%p)\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI EnumTfInputProcessorProfiles_Skip(IEnumTfInputProcessorProfiles *iface, ULONG count) +{ + EnumTfInputProcessorProfiles *This = impl_from_IEnumTfInputProcessorProfiles(iface); + FIXME("(%p)->(%u)\n", This, count); + return E_NOTIMPL; +} + +static const IEnumTfInputProcessorProfilesVtbl EnumTfInputProcessorProfilesVtbl = { + EnumTfInputProcessorProfiles_QueryInterface, + EnumTfInputProcessorProfiles_AddRef, + EnumTfInputProcessorProfiles_Release, + EnumTfInputProcessorProfiles_Clone, + EnumTfInputProcessorProfiles_Next, + EnumTfInputProcessorProfiles_Reset, + EnumTfInputProcessorProfiles_Skip +}; + static inline InputProcessorProfiles *impl_from_ITfInputProcessorProfiles(ITfInputProcessorProfiles *iface) { return CONTAINING_RECORD(iface, InputProcessorProfiles, ITfInputProcessorProfiles_iface); @@ -149,28 +247,31 @@ static void add_userkey( REFCLSID rclsid, LANGID langid, RegCloseKey(key); } -static HRESULT WINAPI InputProcessorProfiles_QueryInterface(ITfInputProcessorProfiles *iface, REFIID iid, LPVOID *ppvOut) +static HRESULT WINAPI InputProcessorProfiles_QueryInterface(ITfInputProcessorProfiles *iface, REFIID iid, void **ppv) { InputProcessorProfiles *This = impl_from_ITfInputProcessorProfiles(iface); - *ppvOut = NULL; if (IsEqualIID(iid, &IID_IUnknown) || IsEqualIID(iid, &IID_ITfInputProcessorProfiles)) { - *ppvOut = &This->ITfInputProcessorProfiles_iface; + *ppv = &This->ITfInputProcessorProfiles_iface; + } + else if (IsEqualIID(iid, &IID_ITfInputProcessorProfileMgr)) + { + *ppv = &This->ITfInputProcessorProfileMgr_iface; } else if (IsEqualIID(iid, &IID_ITfSource)) { - *ppvOut = &This->ITfSource_iface; + *ppv = &This->ITfSource_iface; } - - if (*ppvOut) + else { - ITfInputProcessorProfiles_AddRef(iface); - return S_OK; + *ppv = NULL; + WARN("unsupported interface: %s\n", debugstr_guid(iid)); + return E_NOINTERFACE; } - WARN("unsupported interface: %s\n", debugstr_guid(iid)); - return E_NOINTERFACE; + ITfInputProcessorProfiles_AddRef(iface); + return S_OK; } static ULONG WINAPI InputProcessorProfiles_AddRef(ITfInputProcessorProfiles *iface) @@ -663,6 +764,125 @@ static const ITfInputProcessorProfilesVtbl InputProcessorProfilesVtbl = InputProcessorProfiles_SubstituteKeyboardLayout }; +static inline InputProcessorProfiles *impl_from_ITfInputProcessorProfileMgr(ITfInputProcessorProfileMgr *iface) +{ + return CONTAINING_RECORD(iface, InputProcessorProfiles, ITfInputProcessorProfileMgr_iface); +} + +static HRESULT WINAPI InputProcessorProfileMgr_QueryInterface(ITfInputProcessorProfileMgr *iface, REFIID riid, void **ppv) +{ + InputProcessorProfiles *This = impl_from_ITfInputProcessorProfileMgr(iface); + return ITfInputProcessorProfiles_QueryInterface(&This->ITfInputProcessorProfiles_iface, riid, ppv); +} + +static ULONG WINAPI InputProcessorProfileMgr_AddRef(ITfInputProcessorProfileMgr *iface) +{ + InputProcessorProfiles *This = impl_from_ITfInputProcessorProfileMgr(iface); + return ITfInputProcessorProfiles_AddRef(&This->ITfInputProcessorProfiles_iface); +} + +static ULONG WINAPI InputProcessorProfileMgr_Release(ITfInputProcessorProfileMgr *iface) +{ + InputProcessorProfiles *This = impl_from_ITfInputProcessorProfileMgr(iface); + return ITfInputProcessorProfiles_Release(&This->ITfInputProcessorProfiles_iface); +} + +static HRESULT WINAPI InputProcessorProfileMgr_ActivateProfile(ITfInputProcessorProfileMgr *iface, DWORD dwProfileType, + LANGID langid, REFCLSID clsid, REFGUID guidProfile, HKL hkl, DWORD dwFlags) +{ + InputProcessorProfiles *This = impl_from_ITfInputProcessorProfileMgr(iface); + FIXME("(%p)->(%d %x %s %s %p %x)\n", This, dwProfileType, langid, debugstr_guid(clsid), + debugstr_guid(guidProfile), hkl, dwFlags); + return E_NOTIMPL; +} + +static HRESULT WINAPI InputProcessorProfileMgr_DeactivateProfile(ITfInputProcessorProfileMgr *iface, DWORD dwProfileType, + LANGID langid, REFCLSID clsid, REFGUID guidProfile, HKL hkl, DWORD dwFlags) +{ + InputProcessorProfiles *This = impl_from_ITfInputProcessorProfileMgr(iface); + FIXME("(%p)->(%d %x %s %s %p %x)\n", This, dwProfileType, langid, debugstr_guid(clsid), + debugstr_guid(guidProfile), hkl, dwFlags); + return E_NOTIMPL; +} + +static HRESULT WINAPI InputProcessorProfileMgr_GetProfile(ITfInputProcessorProfileMgr *iface, DWORD dwProfileType, + LANGID langid, REFCLSID clsid, REFGUID guidProfile, HKL hkl, TF_INPUTPROCESSORPROFILE *pProfile) +{ + InputProcessorProfiles *This = impl_from_ITfInputProcessorProfileMgr(iface); + FIXME("(%p)->(%d %x %s %s %p %p)\n", This, dwProfileType, langid, debugstr_guid(clsid), + debugstr_guid(guidProfile), hkl, pProfile); + return E_NOTIMPL; +} + +static HRESULT WINAPI InputProcessorProfileMgr_EnumProfiles(ITfInputProcessorProfileMgr *iface, LANGID langid, + IEnumTfInputProcessorProfiles **ppEnum) +{ + InputProcessorProfiles *This = impl_from_ITfInputProcessorProfileMgr(iface); + EnumTfInputProcessorProfiles *enum_profiles; + + TRACE("(%p)->(%x %p)\n", This, langid, ppEnum); + + enum_profiles = HeapAlloc(GetProcessHeap(), 0, sizeof(*enum_profiles)); + if(!enum_profiles) + return E_OUTOFMEMORY; + + enum_profiles->IEnumTfInputProcessorProfiles_iface.lpVtbl = &EnumTfInputProcessorProfilesVtbl; + enum_profiles->ref = 1; + + *ppEnum = &enum_profiles->IEnumTfInputProcessorProfiles_iface; + return S_OK; +} + +static HRESULT WINAPI InputProcessorProfileMgr_ReleaseInputProcessor(ITfInputProcessorProfileMgr *iface, REFCLSID rclsid, + DWORD dwFlags) +{ + InputProcessorProfiles *This = impl_from_ITfInputProcessorProfileMgr(iface); + FIXME("(%p)->(%s %x)\n", This, debugstr_guid(rclsid), dwFlags); + return E_NOTIMPL; +} + +static HRESULT WINAPI InputProcessorProfileMgr_RegisterProfile(ITfInputProcessorProfileMgr *iface, REFCLSID rclsid, + LANGID langid, REFGUID guidProfile, const WCHAR *pchDesc, ULONG cchDesc, const WCHAR *pchIconFile, + ULONG cchFile, ULONG uIconIndex, HKL hklsubstitute, DWORD dwPreferredLayout, BOOL bEnabledByDefault, + DWORD dwFlags) +{ + InputProcessorProfiles *This = impl_from_ITfInputProcessorProfileMgr(iface); + FIXME("(%p)->(%s %x %s %s %d %s %u %u %p %x %x %x)\n", This, debugstr_guid(rclsid), langid, debugstr_guid(guidProfile), + debugstr_w(pchDesc), cchDesc, debugstr_w(pchIconFile), cchFile, uIconIndex, hklsubstitute, dwPreferredLayout, + bEnabledByDefault, dwFlags); + return E_NOTIMPL; +} + +static HRESULT WINAPI InputProcessorProfileMgr_UnregisterProfile(ITfInputProcessorProfileMgr *iface, REFCLSID rclsid, + LANGID langid, REFGUID guidProfile, DWORD dwFlags) +{ + InputProcessorProfiles *This = impl_from_ITfInputProcessorProfileMgr(iface); + FIXME("(%p)->(%s %x %s %x)\n", This, debugstr_guid(rclsid), langid, debugstr_guid(guidProfile), dwFlags); + return E_NOTIMPL; +} + +static HRESULT WINAPI InputProcessorProfileMgr_GetActiveProfile(ITfInputProcessorProfileMgr *iface, REFGUID catid, + TF_INPUTPROCESSORPROFILE *pProfile) +{ + InputProcessorProfiles *This = impl_from_ITfInputProcessorProfileMgr(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_guid(catid), pProfile); + return E_NOTIMPL; +} + +static const ITfInputProcessorProfileMgrVtbl InputProcessorProfileMgrVtbl = { + InputProcessorProfileMgr_QueryInterface, + InputProcessorProfileMgr_AddRef, + InputProcessorProfileMgr_Release, + InputProcessorProfileMgr_ActivateProfile, + InputProcessorProfileMgr_DeactivateProfile, + InputProcessorProfileMgr_GetProfile, + InputProcessorProfileMgr_EnumProfiles, + InputProcessorProfileMgr_ReleaseInputProcessor, + InputProcessorProfileMgr_RegisterProfile, + InputProcessorProfileMgr_UnregisterProfile, + InputProcessorProfileMgr_GetActiveProfile +}; + /***************************************************** * ITfSource functions *****************************************************/ @@ -760,6 +980,7 @@ HRESULT InputProcessorProfiles_Constructor(IUnknown *pUnkOuter, IUnknown **ppOut This->ITfInputProcessorProfiles_iface.lpVtbl= &InputProcessorProfilesVtbl; This->ITfSource_iface.lpVtbl = &InputProcessorProfilesSourceVtbl; + This->ITfInputProcessorProfileMgr_iface.lpVtbl = &InputProcessorProfileMgrVtbl; This->refCount = 1; This->currentLanguage = GetUserDefaultLCID(); diff --git a/dll/win32/mshtml/binding.h b/dll/win32/mshtml/binding.h index 63ac8828327..13478ce226a 100644 --- a/dll/win32/mshtml/binding.h +++ b/dll/win32/mshtml/binding.h @@ -16,6 +16,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#pragma once + typedef struct nsWineURI nsWineURI; /* Keep sync with request_method_strings in nsio.c */ diff --git a/dll/win32/mshtml/conpoint.c b/dll/win32/mshtml/conpoint.c index e2e8d754767..9ed3dd2e883 100644 --- a/dll/win32/mshtml/conpoint.c +++ b/dll/win32/mshtml/conpoint.c @@ -18,23 +18,120 @@ #include "mshtml_private.h" -static const char *debugstr_cp_guid(REFIID riid) +typedef struct { + IEnumConnections IEnumConnections_iface; + + LONG ref; + + unsigned iter; + ConnectionPoint *cp; +} EnumConnections; + +static inline EnumConnections *impl_from_IEnumConnections(IEnumConnections *iface) { -#define X(x) \ - if(IsEqualGUID(riid, &x)) \ - return #x - - X(IID_IPropertyNotifySink); - X(DIID_HTMLDocumentEvents); - X(DIID_HTMLDocumentEvents2); - X(DIID_HTMLTableEvents); - X(DIID_HTMLTextContainerEvents); - -#undef X - - return debugstr_guid(riid); + return CONTAINING_RECORD(iface, EnumConnections, IEnumConnections_iface); } +static HRESULT WINAPI EnumConnections_QueryInterface(IEnumConnections *iface, REFIID riid, void **ppv) +{ + EnumConnections *This = impl_from_IEnumConnections(iface); + + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + + if(IsEqualGUID(riid, &IID_IUnknown)) { + *ppv = &This->IEnumConnections_iface; + }else if(IsEqualGUID(riid, &IID_IEnumConnections)) { + *ppv = &This->IEnumConnections_iface; + }else { + WARN("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + *ppv = NULL; + return E_NOINTERFACE; + } + + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; +} + +static ULONG WINAPI EnumConnections_AddRef(IEnumConnections *iface) +{ + EnumConnections *This = impl_from_IEnumConnections(iface); + ULONG ref = InterlockedIncrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); + + return ref; +} + +static ULONG WINAPI EnumConnections_Release(IEnumConnections *iface) +{ + EnumConnections *This = impl_from_IEnumConnections(iface); + ULONG ref = InterlockedDecrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); + + if(!ref) { + IConnectionPoint_Release(&This->cp->IConnectionPoint_iface); + heap_free(This); + } + + return ref; +} + +static HRESULT WINAPI EnumConnections_Next(IEnumConnections *iface, ULONG cConnections, CONNECTDATA *rgcd, ULONG *pcFetched) +{ + EnumConnections *This = impl_from_IEnumConnections(iface); + ULONG fetched = 0; + + TRACE("(%p)->(%d %p %p)\n", This, cConnections, rgcd, pcFetched); + + while(fetched < cConnections && This->iter < This->cp->sinks_size) { + if(!This->cp->sinks[This->iter].unk) { + This->iter++; + continue; + } + + rgcd[fetched].pUnk = This->cp->sinks[This->iter].unk; + rgcd[fetched].dwCookie = ++This->iter; + IUnknown_AddRef(rgcd[fetched].pUnk); + fetched++; + } + + if(pcFetched) + *pcFetched = fetched; + return fetched == cConnections ? S_OK : S_FALSE; +} + +static HRESULT WINAPI EnumConnections_Skip(IEnumConnections *iface, ULONG cConnections) +{ + EnumConnections *This = impl_from_IEnumConnections(iface); + FIXME("(%p)->(%d)\n", This, cConnections); + return E_NOTIMPL; +} + +static HRESULT WINAPI EnumConnections_Reset(IEnumConnections *iface) +{ + EnumConnections *This = impl_from_IEnumConnections(iface); + FIXME("(%p)\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI EnumConnections_Clone(IEnumConnections *iface, IEnumConnections **ppEnum) +{ + EnumConnections *This = impl_from_IEnumConnections(iface); + FIXME("(%p)->(%p)\n", This, ppEnum); + return E_NOTIMPL; +} + +static const IEnumConnectionsVtbl EnumConnectionsVtbl = { + EnumConnections_QueryInterface, + EnumConnections_AddRef, + EnumConnections_Release, + EnumConnections_Next, + EnumConnections_Skip, + EnumConnections_Reset, + EnumConnections_Clone +}; + static inline ConnectionPoint *impl_from_IConnectionPoint(IConnectionPoint *iface) { return CONTAINING_RECORD(iface, ConnectionPoint, IConnectionPoint_iface); @@ -45,23 +142,20 @@ static HRESULT WINAPI ConnectionPoint_QueryInterface(IConnectionPoint *iface, { ConnectionPoint *This = impl_from_IConnectionPoint(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IConnectionPoint_iface; }else if(IsEqualGUID(&IID_IConnectionPoint, riid)) { - TRACE("(%p)->(IID_IConnectionPoint %p)\n", This, ppv); *ppv = &This->IConnectionPoint_iface; + }else { + *ppv = NULL; + WARN("Unsupported interface %s\n", debugstr_mshtml_guid(riid)); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("Unsupported interface %s\n", debugstr_guid(riid)); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI ConnectionPoint_AddRef(IConnectionPoint *iface) @@ -162,8 +256,23 @@ static HRESULT WINAPI ConnectionPoint_EnumConnections(IConnectionPoint *iface, IEnumConnections **ppEnum) { ConnectionPoint *This = impl_from_IConnectionPoint(iface); - FIXME("(%p)->(%p)\n", This, ppEnum); - return E_NOTIMPL; + EnumConnections *ret; + + TRACE("(%p)->(%p)\n", This, ppEnum); + + ret = heap_alloc(sizeof(*ret)); + if(!ret) + return E_OUTOFMEMORY; + + ret->IEnumConnections_iface.lpVtbl = &EnumConnectionsVtbl; + ret->ref = 1; + ret->iter = 0; + + IConnectionPoint_AddRef(&This->IConnectionPoint_iface); + ret->cp = This; + + *ppEnum = &ret->IEnumConnections_iface; + return S_OK; } static const IConnectionPointVtbl ConnectionPointVtbl = @@ -283,7 +392,7 @@ static HRESULT WINAPI ConnectionPointContainer_FindConnectionPoint(IConnectionPo ConnectionPointContainer *This = impl_from_IConnectionPointContainer(iface); ConnectionPoint *cp; - TRACE("(%p)->(%s %p)\n", This, debugstr_cp_guid(riid), ppCP); + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppCP); if(This->forward_container) return IConnectionPointContainer_FindConnectionPoint(&This->forward_container->IConnectionPointContainer_iface, @@ -291,7 +400,7 @@ static HRESULT WINAPI ConnectionPointContainer_FindConnectionPoint(IConnectionPo cp = get_cp(This, riid, TRUE); if(!cp) { - FIXME("unsupported riid %s\n", debugstr_cp_guid(riid)); + FIXME("unsupported riid %s\n", debugstr_mshtml_guid(riid)); *ppCP = NULL; return CONNECT_E_NOCONNECTION; } diff --git a/dll/win32/mshtml/dispex.c b/dll/win32/mshtml/dispex.c index 33a131852b0..8d91dd60cd0 100644 --- a/dll/win32/mshtml/dispex.c +++ b/dll/win32/mshtml/dispex.c @@ -129,7 +129,7 @@ static HRESULT get_typeinfo(tid_t tid, ITypeInfo **typeinfo) hres = ITypeLib_GetTypeInfoOfGuid(typelib, tid_ids[tid], &ti); if(FAILED(hres)) { - ERR("GetTypeInfoOfGuid(%s) failed: %08x\n", debugstr_guid(tid_ids[tid]), hres); + ERR("GetTypeInfoOfGuid(%s) failed: %08x\n", debugstr_mshtml_guid(tid_ids[tid]), hres); return hres; } @@ -616,7 +616,7 @@ static HRESULT typeinfo_invoke(DispatchEx *This, func_info_t *func, WORD flags, hres = IUnknown_QueryInterface(This->outer, tid_ids[func->tid], (void**)&unk); if(FAILED(hres)) { - ERR("Could not get iface %s: %08x\n", debugstr_guid(tid_ids[func->tid]), hres); + ERR("Could not get iface %s: %08x\n", debugstr_mshtml_guid(tid_ids[func->tid]), hres); return E_FAIL; } @@ -702,6 +702,37 @@ static HRESULT function_value(DispatchEx *dispex, LCID lcid, WORD flags, DISPPAR return E_UNEXPECTED; hres = typeinfo_invoke(This->obj, This->info, flags, params, res, ei); break; + case DISPATCH_PROPERTYGET: { + unsigned name_len; + WCHAR *ptr; + BSTR str; + + static const WCHAR func_prefixW[] = + {'\n','f','u','n','c','t','i','o','n',' '}; + static const WCHAR func_suffixW[] = + {'(',')',' ','{','\n',' ',' ',' ',' ','[','n','a','t','i','v','e',' ','c','o','d','e',']','\n','}','\n'}; + + /* FIXME: This probably should be more generic. Also we should try to get IID_IActiveScriptSite and SID_GetCaller. */ + if(!caller) + return E_ACCESSDENIED; + + name_len = SysStringLen(This->info->name); + ptr = str = SysAllocStringLen(NULL, name_len + (sizeof(func_prefixW)+sizeof(func_suffixW))/sizeof(WCHAR)); + if(!str) + return E_OUTOFMEMORY; + + memcpy(ptr, func_prefixW, sizeof(func_prefixW)); + ptr += sizeof(func_prefixW)/sizeof(WCHAR); + + memcpy(ptr, This->info->name, name_len*sizeof(WCHAR)); + ptr += name_len; + + memcpy(ptr, func_suffixW, sizeof(func_suffixW)); + + V_VT(res) = VT_BSTR; + V_BSTR(res) = str; + return S_OK; + } default: FIXME("Unimplemented flags %x\n", flags); hres = E_NOTIMPL; @@ -1184,6 +1215,7 @@ static HRESULT invoke_builtin_prop(DispatchEx *This, DISPID id, LCID lcid, WORD switch(flags) { case DISPATCH_PROPERTYPUT: + case DISPATCH_PROPERTYPUT | DISPATCH_PROPERTYPUTREF: if(res) V_VT(res) = VT_EMPTY; hres = builtin_propput(This, func, dp, caller); @@ -1203,7 +1235,7 @@ static HRESULT invoke_builtin_prop(DispatchEx *This, DISPID id, LCID lcid, WORD if(flags != (DISPATCH_PROPERTYGET|DISPATCH_METHOD) || dp->cArgs) { if(V_VT(&v) != VT_DISPATCH) { - FIXME("Not a function %s\n", debugstr_variant(&v)); + FIXME("Not a function %s flags %08x\n", debugstr_variant(&v), flags); VariantClear(&v); return E_FAIL; } diff --git a/dll/win32/mshtml/editor.c b/dll/win32/mshtml/editor.c index f2dc56473e8..3c5aa27766b 100644 --- a/dll/win32/mshtml/editor.c +++ b/dll/win32/mshtml/editor.c @@ -246,7 +246,7 @@ static void remove_child_attr(nsIDOMElement *elem, LPCWSTR tag, nsAString *attr_ static void get_font_size(HTMLDocument *This, WCHAR *ret) { nsISelection *nsselection = get_ns_selection(This); - nsIDOMElement *elem = NULL; + nsIDOMHTMLElement *elem = NULL; nsIDOMNode *node = NULL, *tmp_node; nsAString tag_str; LPCWSTR tag; @@ -267,36 +267,29 @@ static void get_font_size(HTMLDocument *This, WCHAR *ret) break; if(node_type == ELEMENT_NODE) { - nsIDOMNode_QueryInterface(node, &IID_nsIDOMElement, (void**)&elem); + nsIDOMNode_QueryInterface(node, &IID_nsIDOMHTMLElement, (void**)&elem); nsAString_Init(&tag_str, NULL); - nsIDOMElement_GetTagName(elem, &tag_str); + nsIDOMHTMLElement_GetTagName(elem, &tag_str); nsAString_GetData(&tag_str, &tag); if(!strcmpiW(tag, fontW)) { - nsAString size_str, val_str; - LPCWSTR val; + nsAString val_str; + const PRUnichar *val; TRACE("found font tag %p\n", elem); - nsAString_InitDepend(&size_str, sizeW); - nsAString_Init(&val_str, NULL); - - nsIDOMElement_GetAttribute(elem, &size_str, &val_str); - nsAString_GetData(&val_str, &val); - + get_elem_attr_value(elem, sizeW, &val_str, &val); if(*val) { TRACE("found size %s\n", debugstr_w(val)); strcpyW(ret, val); } - nsAString_Finish(&size_str); nsAString_Finish(&val_str); } nsAString_Finish(&tag_str); - - nsIDOMElement_Release(elem); + nsIDOMHTMLElement_Release(elem); } if(*ret) diff --git a/dll/win32/mshtml/htmlanchor.c b/dll/win32/mshtml/htmlanchor.c index 85332c043f1..c08776acbad 100644 --- a/dll/win32/mshtml/htmlanchor.c +++ b/dll/win32/mshtml/htmlanchor.c @@ -81,8 +81,9 @@ HTMLOuterWindow *get_target_window(HTMLOuterWindow *window, nsAString *target_st if(!strcmpiW(target, _parentW)) { if(!window->parent) { - WARN("Window has no parent\n"); - return NULL; + WARN("Window has no parent, treat as self\n"); + IHTMLWindow2_AddRef(&window->base.IHTMLWindow2_iface); + return window; } IHTMLWindow2_AddRef(&window->parent->base.IHTMLWindow2_iface); diff --git a/dll/win32/mshtml/htmlattr.c b/dll/win32/mshtml/htmlattr.c index 4eb734d2f81..465ce061c54 100644 --- a/dll/win32/mshtml/htmlattr.c +++ b/dll/win32/mshtml/htmlattr.c @@ -28,16 +28,16 @@ static HRESULT WINAPI HTMLDOMAttribute_QueryInterface(IHTMLDOMAttribute *iface, { HTMLDOMAttribute *This = impl_from_IHTMLDOMAttribute(iface); + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLDOMAttribute_iface; }else if(IsEqualGUID(&IID_IHTMLDOMAttribute, riid)) { - TRACE("(%p)->(IID_IHTMLDOMAttribute %p)\n", This, ppv); *ppv = &This->IHTMLDOMAttribute_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; }else { - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); + WARN("%s not supported\n", debugstr_mshtml_guid(riid)); *ppv = NULL; return E_NOINTERFACE; } @@ -123,11 +123,25 @@ static HRESULT WINAPI HTMLDOMAttribute_get_nodeName(IHTMLDOMAttribute *iface, BS return IDispatchEx_GetMemberName(&This->elem->node.dispex.IDispatchEx_iface, This->dispid, p); } -static HRESULT WINAPI HTMLDOMAttribute_put_nodeName(IHTMLDOMAttribute *iface, VARIANT v) +static HRESULT WINAPI HTMLDOMAttribute_put_nodeValue(IHTMLDOMAttribute *iface, VARIANT v) { HTMLDOMAttribute *This = impl_from_IHTMLDOMAttribute(iface); - FIXME("(%p)->(%s)\n", This, debugstr_variant(&v)); - return E_NOTIMPL; + DISPID dispidNamed = DISPID_PROPERTYPUT; + DISPPARAMS dp = {&v, &dispidNamed, 1, 1}; + EXCEPINFO ei; + VARIANT ret; + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + + if(!This->elem) { + FIXME("NULL This->elem\n"); + return E_UNEXPECTED; + } + + memset(&ei, 0, sizeof(ei)); + + return IDispatchEx_InvokeEx(&This->elem->node.dispex.IDispatchEx_iface, This->dispid, LOCALE_SYSTEM_DEFAULT, + DISPATCH_PROPERTYPUT, &dp, &ret, &ei, NULL); } static HRESULT WINAPI HTMLDOMAttribute_get_nodeValue(IHTMLDOMAttribute *iface, VARIANT *p) @@ -201,7 +215,7 @@ static const IHTMLDOMAttributeVtbl HTMLDOMAttributeVtbl = { HTMLDOMAttribute_GetIDsOfNames, HTMLDOMAttribute_Invoke, HTMLDOMAttribute_get_nodeName, - HTMLDOMAttribute_put_nodeName, + HTMLDOMAttribute_put_nodeValue, HTMLDOMAttribute_get_nodeValue, HTMLDOMAttribute_get_specified }; diff --git a/dll/win32/mshtml/htmlcurstyle.c b/dll/win32/mshtml/htmlcurstyle.c index cc1fd9c7914..94491ff0734 100644 --- a/dll/win32/mshtml/htmlcurstyle.c +++ b/dll/win32/mshtml/htmlcurstyle.c @@ -55,34 +55,28 @@ static HRESULT WINAPI HTMLCurrentStyle_QueryInterface(IHTMLCurrentStyle *iface, { HTMLCurrentStyle *This = impl_from_IHTMLCurrentStyle(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLCurrentStyle_iface; }else if(IsEqualGUID(&IID_IHTMLCurrentStyle, riid)) { - TRACE("(%p)->(IID_IHTMLCurrentStyle %p)\n", This, ppv); *ppv = &This->IHTMLCurrentStyle_iface; }else if(IsEqualGUID(&IID_IHTMLCurrentStyle2, riid)) { - TRACE("(%p)->(IID_IHTMLCurrentStyle2 %p)\n", This, ppv); *ppv = &This->IHTMLCurrentStyle2_iface; }else if(IsEqualGUID(&IID_IHTMLCurrentStyle3, riid)) { - TRACE("(%p)->(IID_IHTMLCurrentStyle3 %p)\n", This, ppv); *ppv = &This->IHTMLCurrentStyle3_iface; }else if(IsEqualGUID(&IID_IHTMLCurrentStyle4, riid)) { - TRACE("(%p)->(IID_IHTMLCurrentStyle4 %p)\n", This, ppv); *ppv = &This->IHTMLCurrentStyle4_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("unsupported %s\n", debugstr_mshtml_guid(riid)); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("unsupported %s\n", debugstr_guid(riid)); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLCurrentStyle_AddRef(IHTMLCurrentStyle *iface) @@ -785,8 +779,8 @@ static HRESULT WINAPI HTMLCurrentStyle_get_overflowY(IHTMLCurrentStyle *iface, B static HRESULT WINAPI HTMLCurrentStyle_get_textTransform(IHTMLCurrentStyle *iface, BSTR *p) { HTMLCurrentStyle *This = impl_from_IHTMLCurrentStyle(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + TRACE("(%p)->(%p)\n", This, p); + return get_nsstyle_attr(This->nsstyle, STYLEID_TEXT_TRANSFORM, p, 0); } static const IHTMLCurrentStyleVtbl HTMLCurrentStyleVtbl = { diff --git a/dll/win32/mshtml/htmldoc.c b/dll/win32/mshtml/htmldoc.c index a6516be34d3..cebd25fd69d 100644 --- a/dll/win32/mshtml/htmldoc.c +++ b/dll/win32/mshtml/htmldoc.c @@ -1555,8 +1555,17 @@ static HRESULT WINAPI HTMLDocument_get_onerrorupdate(IHTMLDocument2 *iface, VARI static HRESULT WINAPI HTMLDocument_toString(IHTMLDocument2 *iface, BSTR *String) { HTMLDocument *This = impl_from_IHTMLDocument2(iface); - FIXME("(%p)->(%p)\n", This, String); - return E_NOTIMPL; + + static const WCHAR objectW[] = {'[','o','b','j','e','c','t',']',0}; + + TRACE("(%p)->(%p)\n", This, String); + + if(!String) + return E_INVALIDARG; + + *String = SysAllocString(objectW); + return *String ? S_OK : E_OUTOFMEMORY; + } static HRESULT WINAPI HTMLDocument_createStyleSheet(IHTMLDocument2 *iface, BSTR bstrHref, @@ -2585,8 +2594,21 @@ static HRESULT WINAPI HTMLDocument5_get_doctype(IHTMLDocument5 *iface, IHTMLDOMN static HRESULT WINAPI HTMLDocument5_get_implementation(IHTMLDocument5 *iface, IHTMLDOMImplementation **p) { HTMLDocument *This = impl_from_IHTMLDocument5(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + HTMLDocumentNode *doc_node = This->doc_node; + + TRACE("(%p)->(%p)\n", This, p); + + if(!doc_node->dom_implementation) { + HRESULT hres; + + hres = create_dom_implementation(&doc_node->dom_implementation); + if(FAILED(hres)) + return hres; + } + + IHTMLDOMImplementation_AddRef(doc_node->dom_implementation); + *p = doc_node->dom_implementation; + return S_OK; } static HRESULT WINAPI HTMLDocument5_createAttribute(IHTMLDocument5 *iface, BSTR bstrattrName, @@ -3841,7 +3863,7 @@ static ULONG WINAPI SupportErrorInfo_Release(ISupportErrorInfo *iface) static HRESULT WINAPI SupportErrorInfo_InterfaceSupportsErrorInfo(ISupportErrorInfo *iface, REFIID riid) { - FIXME("(%p)->(%s)\n", iface, debugstr_guid(riid)); + FIXME("(%p)->(%s)\n", iface, debugstr_mshtml_guid(riid)); return S_FALSE; } @@ -4113,106 +4135,81 @@ static BOOL htmldoc_qi(HTMLDocument *This, REFIID riid, void **ppv) { *ppv = NULL; - if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown, %p)\n", This, ppv); + if(IsEqualGUID(&IID_IUnknown, riid)) *ppv = &This->IHTMLDocument2_iface; - }else if(IsEqualGUID(&IID_IDispatch, riid)) { - TRACE("(%p)->(IID_IDispatch, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IDispatch, riid)) *ppv = &This->IDispatchEx_iface; - }else if(IsEqualGUID(&IID_IDispatchEx, riid)) { - TRACE("(%p)->(IID_IDispatchEx, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IDispatchEx, riid)) *ppv = &This->IDispatchEx_iface; - }else if(IsEqualGUID(&IID_IHTMLDocument, riid)) { - TRACE("(%p)->(IID_IHTMLDocument, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IHTMLDocument, riid)) *ppv = &This->IHTMLDocument2_iface; - }else if(IsEqualGUID(&IID_IHTMLDocument2, riid)) { - TRACE("(%p)->(IID_IHTMLDocument2, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IHTMLDocument2, riid)) *ppv = &This->IHTMLDocument2_iface; - }else if(IsEqualGUID(&IID_IHTMLDocument3, riid)) { - TRACE("(%p)->(IID_IHTMLDocument3, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IHTMLDocument3, riid)) *ppv = &This->IHTMLDocument3_iface; - }else if(IsEqualGUID(&IID_IHTMLDocument4, riid)) { - TRACE("(%p)->(IID_IHTMLDocument4, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IHTMLDocument4, riid)) *ppv = &This->IHTMLDocument4_iface; - }else if(IsEqualGUID(&IID_IHTMLDocument5, riid)) { - TRACE("(%p)->(IID_IHTMLDocument5, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IHTMLDocument5, riid)) *ppv = &This->IHTMLDocument5_iface; - }else if(IsEqualGUID(&IID_IHTMLDocument6, riid)) { - TRACE("(%p)->(IID_IHTMLDocument6, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IHTMLDocument6, riid)) *ppv = &This->IHTMLDocument6_iface; - }else if(IsEqualGUID(&IID_IHTMLDocument7, riid)) { - TRACE("(%p)->(IID_IHTMLDocument7, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IHTMLDocument7, riid)) *ppv = &This->IHTMLDocument7_iface; - }else if(IsEqualGUID(&IID_IPersist, riid)) { - TRACE("(%p)->(IID_IPersist, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IPersist, riid)) *ppv = &This->IPersistFile_iface; - }else if(IsEqualGUID(&IID_IPersistMoniker, riid)) { - TRACE("(%p)->(IID_IPersistMoniker, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IPersistMoniker, riid)) *ppv = &This->IPersistMoniker_iface; - }else if(IsEqualGUID(&IID_IPersistFile, riid)) { - TRACE("(%p)->(IID_IPersistFile, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IPersistFile, riid)) *ppv = &This->IPersistFile_iface; - }else if(IsEqualGUID(&IID_IMonikerProp, riid)) { - TRACE("(%p)->(IID_IMonikerProp, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IMonikerProp, riid)) *ppv = &This->IMonikerProp_iface; - }else if(IsEqualGUID(&IID_IOleObject, riid)) { - TRACE("(%p)->(IID_IOleObject, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IOleObject, riid)) *ppv = &This->IOleObject_iface; - }else if(IsEqualGUID(&IID_IOleDocument, riid)) { - TRACE("(%p)->(IID_IOleDocument, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IOleDocument, riid)) *ppv = &This->IOleDocument_iface; - }else if(IsEqualGUID(&IID_IOleDocumentView, riid)) { - TRACE("(%p)->(IID_IOleDocumentView, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IOleDocumentView, riid)) *ppv = &This->IOleDocumentView_iface; - }else if(IsEqualGUID(&IID_IOleInPlaceActiveObject, riid)) { - TRACE("(%p)->(IID_IOleInPlaceActiveObject, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IOleInPlaceActiveObject, riid)) *ppv = &This->IOleInPlaceActiveObject_iface; - }else if(IsEqualGUID(&IID_IViewObject, riid)) { - TRACE("(%p)->(IID_IViewObject, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IViewObject, riid)) *ppv = &This->IViewObjectEx_iface; - }else if(IsEqualGUID(&IID_IViewObject2, riid)) { - TRACE("(%p)->(IID_IViewObject2, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IViewObject2, riid)) *ppv = &This->IViewObjectEx_iface; - }else if(IsEqualGUID(&IID_IViewObjectEx, riid)) { - TRACE("(%p)->(IID_IViewObjectEx, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IViewObjectEx, riid)) *ppv = &This->IViewObjectEx_iface; - }else if(IsEqualGUID(&IID_IOleWindow, riid)) { - TRACE("(%p)->(IID_IOleWindow, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IOleWindow, riid)) *ppv = &This->IOleInPlaceActiveObject_iface; - }else if(IsEqualGUID(&IID_IOleInPlaceObject, riid)) { - TRACE("(%p)->(IID_IOleInPlaceObject, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IOleInPlaceObject, riid)) *ppv = &This->IOleInPlaceObjectWindowless_iface; - }else if(IsEqualGUID(&IID_IOleInPlaceObjectWindowless, riid)) { - TRACE("(%p)->(IID_IOleInPlaceObjectWindowless, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IOleInPlaceObjectWindowless, riid)) *ppv = &This->IOleInPlaceObjectWindowless_iface; - }else if(IsEqualGUID(&IID_IServiceProvider, riid)) { - TRACE("(%p)->(IID_IServiceProvider, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IServiceProvider, riid)) *ppv = &This->IServiceProvider_iface; - }else if(IsEqualGUID(&IID_IOleCommandTarget, riid)) { - TRACE("(%p)->(IID_IOleCommandTarget, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IOleCommandTarget, riid)) *ppv = &This->IOleCommandTarget_iface; - }else if(IsEqualGUID(&IID_IOleControl, riid)) { - TRACE("(%p)->(IID_IOleControl, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IOleControl, riid)) *ppv = &This->IOleControl_iface; - }else if(IsEqualGUID(&IID_IHlinkTarget, riid)) { - TRACE("(%p)->(IID_IHlinkTarget, %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IHlinkTarget, riid)) *ppv = &This->IHlinkTarget_iface; - }else if(IsEqualGUID(&IID_IConnectionPointContainer, riid)) { - TRACE("(%p)->(IID_IConnectionPointContainer %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IConnectionPointContainer, riid)) *ppv = &This->cp_container.IConnectionPointContainer_iface; - }else if(IsEqualGUID(&IID_IPersistStreamInit, riid)) { - TRACE("(%p)->(IID_IPersistStreamInit %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IPersistStreamInit, riid)) *ppv = &This->IPersistStreamInit_iface; - }else if(IsEqualGUID(&DIID_DispHTMLDocument, riid)) { - TRACE("(%p)->(DIID_DispHTMLDocument %p)\n", This, ppv); + else if(IsEqualGUID(&DIID_DispHTMLDocument, riid)) *ppv = &This->IHTMLDocument2_iface; - }else if(IsEqualGUID(&IID_ISupportErrorInfo, riid)) { - TRACE("(%p)->(IID_ISupportErrorInfo %p)\n", This, ppv); + else if(IsEqualGUID(&IID_ISupportErrorInfo, riid)) *ppv = &This->ISupportErrorInfo_iface; - }else if(IsEqualGUID(&IID_IPersistHistory, riid)) { - TRACE("(%p)->(IID_IPersistHistory %p)\n", This, ppv); + else if(IsEqualGUID(&IID_IPersistHistory, riid)) *ppv = &This->IPersistHistory_iface; - }else if(IsEqualGUID(&CLSID_CMarkup, riid)) { + else if(IsEqualGUID(&IID_IObjectWithSite, riid)) + *ppv = &This->IObjectWithSite_iface; + else if(IsEqualGUID(&IID_IOleContainer, riid)) + *ppv = &This->IOleContainer_iface; + else if(IsEqualGUID(&IID_IObjectSafety, riid)) + *ppv = &This->IObjectSafety_iface; + else if(IsEqualGUID(&IID_IProvideClassInfo, riid)) + *ppv = &This->IProvideClassInfo_iface; + else if(IsEqualGUID(&CLSID_CMarkup, riid)) { FIXME("(%p)->(CLSID_CMarkup %p)\n", This, ppv); *ppv = NULL; }else if(IsEqualGUID(&IID_IRunnableObject, riid)) { @@ -4230,18 +4227,6 @@ static BOOL htmldoc_qi(HTMLDocument *This, REFIID riid, void **ppv) }else if(IsEqualGUID(&IID_IStdMarshalInfo, riid)) { TRACE("(%p)->(IID_IStdMarshalInfo %p) returning NULL\n", This, ppv); *ppv = NULL; - }else if(IsEqualGUID(&IID_IObjectWithSite, riid)) { - TRACE("(%p)->(IID_IObjectWithSite %p)\n", This, ppv); - *ppv = &This->IObjectWithSite_iface; - }else if(IsEqualGUID(&IID_IOleContainer, riid)) { - TRACE("(%p)->(IID_IOleContainer %p)\n", This, ppv); - *ppv = &This->IOleContainer_iface; - }else if(IsEqualGUID(&IID_IObjectSafety, riid)) { - TRACE("(%p)->(IID_IObjectSafety %p)\n", This, ppv); - *ppv = &This->IObjectSafety_iface; - }else if(IsEqualGUID(&IID_IProvideClassInfo, riid)) { - TRACE("(%p)->(IID_IProvideClassInfo, %p)\n", This, ppv); - *ppv = &This->IProvideClassInfo_iface; }else { return FALSE; } @@ -4304,15 +4289,15 @@ static HRESULT HTMLDocumentNode_QI(HTMLDOMNode *iface, REFIID riid, void **ppv) { HTMLDocumentNode *This = impl_from_HTMLDOMNode(iface); + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + if(htmldoc_qi(&This->basedoc, riid, ppv)) return *ppv ? S_OK : E_NOINTERFACE; - if(IsEqualGUID(&IID_IInternetHostSecurityManager, riid)) { - TRACE("(%p)->(IID_IInternetHostSecurityManager %p)\n", This, ppv); + if(IsEqualGUID(&IID_IInternetHostSecurityManager, riid)) *ppv = &This->IInternetHostSecurityManager_iface; - }else { + else return HTMLDOMNode_QI(&This->node, riid, ppv); - } IUnknown_AddRef((IUnknown*)*ppv); return S_OK; @@ -4344,11 +4329,7 @@ static void HTMLDocumentNode_destructor(HTMLDOMNode *iface) This->nsnode_selector = NULL; } - if(This->nsdoc) { - assert(!This->window); - release_document_mutation(This); - nsIDOMHTMLDocument_Release(This->nsdoc); - }else if(This->window) { + if(!This->nsdoc && This->window) { /* document fragments own reference to inner window */ IHTMLWindow2_Release(&This->window->base.IHTMLWindow2_iface); This->window = NULL; @@ -4595,19 +4576,19 @@ static HRESULT WINAPI CustomDoc_QueryInterface(ICustomDoc *iface, REFIID riid, v { HTMLDocumentObj *This = impl_from_ICustomDoc(iface); + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + if(htmldoc_qi(&This->basedoc, riid, ppv)) return *ppv ? S_OK : E_NOINTERFACE; if(IsEqualGUID(&IID_ICustomDoc, riid)) { - TRACE("(%p)->(IID_ICustomDoc %p)\n", This, ppv); *ppv = &This->ICustomDoc_iface; }else if(IsEqualGUID(&IID_ITargetContainer, riid)) { - TRACE("(%p)->(IID_ITargetContainer %p)\n", This, ppv); *ppv = &This->ITargetContainer_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; }else { - FIXME("Unimplemented interface %s\n", debugstr_guid(riid)); + FIXME("Unimplemented interface %s\n", debugstr_mshtml_guid(riid)); *ppv = NULL; return E_NOINTERFACE; } @@ -4744,7 +4725,7 @@ HRESULT HTMLDocument_Create(IUnknown *pUnkOuter, REFIID riid, void** ppvObject) nsresult nsres; HRESULT hres; - TRACE("(%p %s %p)\n", pUnkOuter, debugstr_guid(riid), ppvObject); + TRACE("(%p %s %p)\n", pUnkOuter, debugstr_mshtml_guid(riid), ppvObject); doc = heap_alloc_zero(sizeof(HTMLDocumentObj)); if(!doc) diff --git a/dll/win32/mshtml/htmlelem.c b/dll/win32/mshtml/htmlelem.c index 88b5ebfee7c..2ee352bd081 100644 --- a/dll/win32/mshtml/htmlelem.c +++ b/dll/win32/mshtml/htmlelem.c @@ -138,6 +138,68 @@ HRESULT replace_node_by_html(nsIDOMHTMLDocument *nsdoc, nsIDOMNode *nsnode, cons return hres; } +nsresult get_elem_attr_value(nsIDOMHTMLElement *nselem, const WCHAR *name, nsAString *val_str, const PRUnichar **val) +{ + nsAString name_str; + nsresult nsres; + + nsAString_InitDepend(&name_str, name); + nsAString_Init(val_str, NULL); + nsres = nsIDOMHTMLElement_GetAttribute(nselem, &name_str, val_str); + nsAString_Finish(&name_str); + if(NS_FAILED(nsres)) { + ERR("GetAttribute(%s) failed: %08x\n", debugstr_w(name), nsres); + nsAString_Finish(val_str); + return nsres; + } + + nsAString_GetData(val_str, val); + return NS_OK; +} + +HRESULT elem_string_attr_getter(HTMLElement *elem, const WCHAR *name, BOOL use_null, BSTR *p) +{ + const PRUnichar *val; + nsAString val_str; + nsresult nsres; + HRESULT hres = S_OK; + + nsres = get_elem_attr_value(elem->nselem, name, &val_str, &val); + if(NS_FAILED(nsres)) + return E_FAIL; + + TRACE("%s: returning %s\n", debugstr_w(name), debugstr_w(val)); + + if(*val || !use_null) { + *p = SysAllocString(val); + if(!*p) + hres = E_OUTOFMEMORY; + }else { + *p = NULL; + } + nsAString_Finish(&val_str); + return hres; +} + +HRESULT elem_string_attr_setter(HTMLElement *elem, const WCHAR *name, const WCHAR *value) +{ + nsAString name_str, val_str; + nsresult nsres; + + nsAString_InitDepend(&name_str, name); + nsAString_InitDepend(&val_str, value); + nsres = nsIDOMHTMLElement_SetAttribute(elem->nselem, &name_str, &val_str); + nsAString_Finish(&name_str); + nsAString_Finish(&val_str); + + if(NS_FAILED(nsres)) { + WARN("SetAttribute failed: %08x\n", nsres); + return E_FAIL; + } + + return S_OK; +} + typedef struct { DispatchEx dispex; @@ -771,30 +833,53 @@ static HRESULT WINAPI HTMLElement_get_onselectstart(IHTMLElement *iface, VARIANT static HRESULT WINAPI HTMLElement_scrollIntoView(IHTMLElement *iface, VARIANT varargStart) { HTMLElement *This = impl_from_IHTMLElement(iface); - FIXME("(%p)->(%s)\n", This, debugstr_variant(&varargStart)); - return E_NOTIMPL; + cpp_bool start = TRUE; + nsresult nsres; + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&varargStart)); + + switch(V_VT(&varargStart)) { + case VT_EMPTY: + case VT_ERROR: + break; + case VT_BOOL: + start = V_BOOL(&varargStart) != VARIANT_FALSE; + break; + default: + FIXME("Unsupported argument %s\n", debugstr_variant(&varargStart)); + } + + if(!This->nselem) { + FIXME("Unsupported for comments\n"); + return E_NOTIMPL; + } + + nsres = nsIDOMHTMLElement_ScrollIntoView(This->nselem, start, 1); + assert(nsres == NS_OK); + + return S_OK; } static HRESULT WINAPI HTMLElement_contains(IHTMLElement *iface, IHTMLElement *pChild, VARIANT_BOOL *pfResult) { HTMLElement *This = impl_from_IHTMLElement(iface); - HTMLElement *child; - cpp_bool result; - nsresult nsres; + cpp_bool result = FALSE; TRACE("(%p)->(%p %p)\n", This, pChild, pfResult); - child = unsafe_impl_from_IHTMLElement(pChild); - if(!child) { - ERR("not our element\n"); - return E_FAIL; - } + if(pChild) { + HTMLElement *child; + nsresult nsres; - nsres = nsIDOMNode_Contains(This->node.nsnode, child->node.nsnode, &result); - if(NS_FAILED(nsres)) { - ERR("failed\n"); - return E_FAIL; + child = unsafe_impl_from_IHTMLElement(pChild); + if(!child) { + ERR("not our element\n"); + return E_FAIL; + } + + nsres = nsIDOMNode_Contains(This->node.nsnode, child->node.nsnode, &result); + assert(nsres == NS_OK); } *pfResult = result ? VARIANT_TRUE : VARIANT_FALSE; @@ -804,8 +889,10 @@ static HRESULT WINAPI HTMLElement_contains(IHTMLElement *iface, IHTMLElement *pC static HRESULT WINAPI HTMLElement_get_sourceIndex(IHTMLElement *iface, LONG *p) { HTMLElement *This = impl_from_IHTMLElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_elem_source_index(This, p); } static HRESULT WINAPI HTMLElement_get_recordNumber(IHTMLElement *iface, VARIANT *p) @@ -1547,37 +1634,26 @@ HRESULT HTMLElement_QI(HTMLDOMNode *iface, REFIID riid, void **ppv) { HTMLElement *This = impl_from_HTMLDOMNode(iface); - *ppv = NULL; - if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLElement_iface; }else if(IsEqualGUID(&IID_IDispatch, riid)) { - TRACE("(%p)->(IID_IDispatch %p)\n", This, ppv); *ppv = &This->IHTMLElement_iface; }else if(IsEqualGUID(&IID_IHTMLElement, riid)) { - TRACE("(%p)->(IID_IHTMLElement %p)\n", This, ppv); *ppv = &This->IHTMLElement_iface; }else if(IsEqualGUID(&IID_IHTMLElement2, riid)) { - TRACE("(%p)->(IID_IHTMLElement2 %p)\n", This, ppv); *ppv = &This->IHTMLElement2_iface; }else if(IsEqualGUID(&IID_IHTMLElement3, riid)) { - TRACE("(%p)->(IID_IHTMLElement3 %p)\n", This, ppv); *ppv = &This->IHTMLElement3_iface; }else if(IsEqualGUID(&IID_IHTMLElement4, riid)) { - TRACE("(%p)->(IID_IHTMLElement4 %p)\n", This, ppv); *ppv = &This->IHTMLElement4_iface; }else if(IsEqualGUID(&IID_IConnectionPointContainer, riid)) { - TRACE("(%p)->(IID_IConnectionPointContainer %p)\n", This, ppv); *ppv = &This->cp_container.IConnectionPointContainer_iface; + }else { + return HTMLDOMNode_QI(&This->node, riid, ppv); } - if(*ppv) { - IHTMLElement_AddRef(&This->IHTMLElement_iface); - return S_OK; - } - - return HTMLDOMNode_QI(&This->node, riid, ppv); + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } void HTMLElement_destructor(HTMLDOMNode *iface) @@ -1896,25 +1972,23 @@ static HRESULT WINAPI HTMLFiltersCollection_QueryInterface(IHTMLFiltersCollectio { HTMLFiltersCollection *This = impl_from_IHTMLFiltersCollection(iface); - TRACE("%p %s %p\n", This, debugstr_guid( riid ), ppv ); + TRACE("%p %s %p\n", This, debugstr_mshtml_guid(riid), ppv ); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLFiltersCollection_iface; }else if(IsEqualGUID(&IID_IHTMLFiltersCollection, riid)) { TRACE("(%p)->(IID_IHTMLFiltersCollection %p)\n", This, ppv); *ppv = &This->IHTMLFiltersCollection_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + FIXME("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - FIXME("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLFiltersCollection_AddRef(IHTMLFiltersCollection *iface) @@ -2082,31 +2156,24 @@ static HRESULT WINAPI HTMLAttributeCollection_QueryInterface(IHTMLAttributeColle { HTMLAttributeCollection *This = impl_from_IHTMLAttributeCollection(iface); - *ppv = NULL; - if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLAttributeCollection_iface; }else if(IsEqualGUID(&IID_IHTMLAttributeCollection, riid)) { - TRACE("(%p)->(IID_IHTMLAttributeCollection %p)\n", This, ppv); *ppv = &This->IHTMLAttributeCollection_iface; }else if(IsEqualGUID(&IID_IHTMLAttributeCollection2, riid)) { - TRACE("(%p)->(IID_IHTMLAttributeCollection2 %p)\n", This, ppv); *ppv = &This->IHTMLAttributeCollection2_iface; }else if(IsEqualGUID(&IID_IHTMLAttributeCollection3, riid)) { - TRACE("(%p)->(IID_IHTMLAttributeCollection3 %p)\n", This, ppv); *ppv = &This->IHTMLAttributeCollection3_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLAttributeCollection_AddRef(IHTMLAttributeCollection *iface) diff --git a/dll/win32/mshtml/htmlelem2.c b/dll/win32/mshtml/htmlelem2.c index b2cf30f209d..765766e9161 100644 --- a/dll/win32/mshtml/htmlelem2.c +++ b/dll/win32/mshtml/htmlelem2.c @@ -36,16 +36,16 @@ static HRESULT WINAPI HTMLRect_QueryInterface(IHTMLRect *iface, REFIID riid, voi { HTMLRect *This = impl_from_IHTMLRect(iface); + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLRect_iface; }else if(IsEqualGUID(&IID_IHTMLRect, riid)) { - TRACE("(%p)->(IID_IHTMLRect %p)\n", This, ppv); *ppv = &This->IHTMLRect_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; }else { - FIXME("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); + FIXME("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); *ppv = NULL; return E_NOINTERFACE; } diff --git a/dll/win32/mshtml/htmlelem3.c b/dll/win32/mshtml/htmlelem3.c index c5b4faaeca5..547f1963f2b 100644 --- a/dll/win32/mshtml/htmlelem3.c +++ b/dll/win32/mshtml/htmlelem3.c @@ -160,15 +160,34 @@ static HRESULT WINAPI HTMLElement3_setActive(IHTMLElement3 *iface) static HRESULT WINAPI HTMLElement3_put_contentEditable(IHTMLElement3 *iface, BSTR v) { HTMLElement *This = impl_from_IHTMLElement3(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + nsresult nsres; + nsAString str; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + nsAString_InitDepend(&str, v); + nsres = nsIDOMHTMLElement_SetContentEditable(This->nselem, &str); + nsAString_Finish(&str); + + if (NS_FAILED(nsres)){ + ERR("SetContentEditable(%s) failed!\n", debugstr_w(v)); + return E_FAIL; + } + + return S_OK; } static HRESULT WINAPI HTMLElement3_get_contentEditable(IHTMLElement3 *iface, BSTR *p) { HTMLElement *This = impl_from_IHTMLElement3(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsresult nsres; + nsAString str; + + TRACE("(%p)->(%p)\n", This, p); + + nsAString_Init(&str, NULL); + nsres = nsIDOMHTMLElement_GetContentEditable(This->nselem, &str); + return return_nsstr(nsres, &str, p); } static HRESULT WINAPI HTMLElement3_get_isContentEditable(IHTMLElement3 *iface, VARIANT_BOOL *p) @@ -524,15 +543,19 @@ static HRESULT WINAPI HTMLElement4_Invoke(IHTMLElement4 *iface, DISPID dispIdMem static HRESULT WINAPI HTMLElement4_put_onmousewheel(IHTMLElement4 *iface, VARIANT v) { HTMLElement *This = impl_from_IHTMLElement4(iface); - FIXME("(%p)->(%s)\n", This, debugstr_variant(&v)); - return E_NOTIMPL; + + FIXME("(%p)->(%s) semi-stub\n", This, debugstr_variant(&v)); + + return set_node_event(&This->node, EVENTID_MOUSEWHEEL, &v); } static HRESULT WINAPI HTMLElement4_get_onmousewheel(IHTMLElement4 *iface, VARIANT *p) { HTMLElement *This = impl_from_IHTMLElement4(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_node_event(&This->node, EVENTID_MOUSEWHEEL, p); } static HRESULT WINAPI HTMLElement4_normalize(IHTMLElement4 *iface) diff --git a/dll/win32/mshtml/htmlelemcol.c b/dll/win32/mshtml/htmlelemcol.c index 75596e89003..b52c8d96f0e 100644 --- a/dll/win32/mshtml/htmlelemcol.c +++ b/dll/win32/mshtml/htmlelemcol.c @@ -28,6 +28,15 @@ typedef struct { LONG ref; } HTMLElementCollection; +typedef struct { + IEnumVARIANT IEnumVARIANT_iface; + + LONG ref; + + ULONG iter; + HTMLElementCollection *col; +} HTMLElementCollectionEnum; + typedef struct { HTMLElement **buf; DWORD len; @@ -73,6 +82,118 @@ static inline BOOL is_elem_node(nsIDOMNode *node) return type == ELEMENT_NODE || type == COMMENT_NODE; } +static inline HTMLElementCollectionEnum *impl_from_IEnumVARIANT(IEnumVARIANT *iface) +{ + return CONTAINING_RECORD(iface, HTMLElementCollectionEnum, IEnumVARIANT_iface); +} + +static HRESULT WINAPI HTMLElementCollectionEnum_QueryInterface(IEnumVARIANT *iface, REFIID riid, void **ppv) +{ + HTMLElementCollectionEnum *This = impl_from_IEnumVARIANT(iface); + + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + + if(IsEqualGUID(riid, &IID_IUnknown)) { + *ppv = &This->IEnumVARIANT_iface; + }else if(IsEqualGUID(riid, &IID_IEnumVARIANT)) { + *ppv = &This->IEnumVARIANT_iface; + }else { + FIXME("Unsupported iface %s\n", debugstr_mshtml_guid(riid)); + *ppv = NULL; + return E_NOINTERFACE; + } + + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; +} + +static ULONG WINAPI HTMLElementCollectionEnum_AddRef(IEnumVARIANT *iface) +{ + HTMLElementCollectionEnum *This = impl_from_IEnumVARIANT(iface); + LONG ref = InterlockedIncrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); + + return ref; +} + +static ULONG WINAPI HTMLElementCollectionEnum_Release(IEnumVARIANT *iface) +{ + HTMLElementCollectionEnum *This = impl_from_IEnumVARIANT(iface); + LONG ref = InterlockedDecrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); + + if(!ref) { + IHTMLElementCollection_Release(&This->col->IHTMLElementCollection_iface); + heap_free(This); + } + + return ref; +} + +static HRESULT WINAPI HTMLElementCollectionEnum_Next(IEnumVARIANT *iface, ULONG celt, VARIANT *rgVar, ULONG *pCeltFetched) +{ + HTMLElementCollectionEnum *This = impl_from_IEnumVARIANT(iface); + ULONG fetched = 0; + + TRACE("(%p)->(%d %p %p)\n", This, celt, rgVar, pCeltFetched); + + while(This->iter+fetched < This->col->len && fetched < celt) { + V_VT(rgVar+fetched) = VT_DISPATCH; + V_DISPATCH(rgVar+fetched) = (IDispatch*)&This->col->elems[This->iter+fetched]->IHTMLElement_iface; + IDispatch_AddRef(V_DISPATCH(rgVar+fetched)); + fetched++; + } + + This->iter += fetched; + if(pCeltFetched) + *pCeltFetched = fetched; + return fetched == celt ? S_OK : S_FALSE; +} + +static HRESULT WINAPI HTMLElementCollectionEnum_Skip(IEnumVARIANT *iface, ULONG celt) +{ + HTMLElementCollectionEnum *This = impl_from_IEnumVARIANT(iface); + + TRACE("(%p)->(%d)\n", This, celt); + + if(This->iter + celt > This->col->len) { + This->iter = This->col->len; + return S_FALSE; + } + + This->iter += celt; + return S_OK; +} + +static HRESULT WINAPI HTMLElementCollectionEnum_Reset(IEnumVARIANT *iface) +{ + HTMLElementCollectionEnum *This = impl_from_IEnumVARIANT(iface); + + TRACE("(%p)->()\n", This); + + This->iter = 0; + return S_OK; +} + +static HRESULT WINAPI HTMLElementCollectionEnum_Clone(IEnumVARIANT *iface, IEnumVARIANT **ppEnum) +{ + HTMLElementCollectionEnum *This = impl_from_IEnumVARIANT(iface); + FIXME("(%p)->(%p)\n", This, ppEnum); + return E_NOTIMPL; +} + +static const IEnumVARIANTVtbl HTMLElementCollectionEnumVtbl = { + HTMLElementCollectionEnum_QueryInterface, + HTMLElementCollectionEnum_AddRef, + HTMLElementCollectionEnum_Release, + HTMLElementCollectionEnum_Next, + HTMLElementCollectionEnum_Skip, + HTMLElementCollectionEnum_Reset, + HTMLElementCollectionEnum_Clone +}; + static inline HTMLElementCollection *impl_from_IHTMLElementCollection(IHTMLElementCollection *iface) { return CONTAINING_RECORD(iface, HTMLElementCollection, IHTMLElementCollection_iface); @@ -83,25 +204,20 @@ static HRESULT WINAPI HTMLElementCollection_QueryInterface(IHTMLElementCollectio { HTMLElementCollection *This = impl_from_IHTMLElementCollection(iface); - *ppv = NULL; - if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLElementCollection_iface; }else if(IsEqualGUID(&IID_IHTMLElementCollection, riid)) { - TRACE("(%p)->(IID_IHTMLElementCollection %p)\n", This, ppv); *ppv = &This->IHTMLElementCollection_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + FIXME("Unsupported iface %s\n", debugstr_mshtml_guid(riid)); + return E_NOINTERFACE; } - if(*ppv) { - IHTMLElementCollection_AddRef(&This->IHTMLElementCollection_iface); - return S_OK; - } - - FIXME("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IHTMLElementCollection_AddRef(&This->IHTMLElementCollection_iface); + return S_OK; } static ULONG WINAPI HTMLElementCollection_AddRef(IHTMLElementCollection *iface) @@ -197,8 +313,23 @@ static HRESULT WINAPI HTMLElementCollection_get__newEnum(IHTMLElementCollection IUnknown **p) { HTMLElementCollection *This = impl_from_IHTMLElementCollection(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + HTMLElementCollectionEnum *ret; + + TRACE("(%p)->(%p)\n", This, p); + + ret = heap_alloc(sizeof(*ret)); + if(!ret) + return E_OUTOFMEMORY; + + ret->IEnumVARIANT_iface.lpVtbl = &HTMLElementCollectionEnumVtbl; + ret->ref = 1; + ret->iter = 0; + + IHTMLElementCollection_AddRef(&This->IHTMLElementCollection_iface); + ret->col = This; + + *p = (IUnknown*)&ret->IEnumVARIANT_iface; + return S_OK; } static BOOL is_elem_id(HTMLElement *elem, LPCWSTR name) @@ -224,7 +355,7 @@ static BOOL is_elem_id(HTMLElement *elem, LPCWSTR name) static BOOL is_elem_name(HTMLElement *elem, LPCWSTR name) { const PRUnichar *str; - nsAString nsstr, nsname; + nsAString nsstr; BOOL ret = FALSE; nsresult nsres; @@ -241,15 +372,12 @@ static BOOL is_elem_name(HTMLElement *elem, LPCWSTR name) return TRUE; } - nsAString_InitDepend(&nsname, nameW); - nsres = nsIDOMHTMLElement_GetAttribute(elem->nselem, &nsname, &nsstr); - nsAString_Finish(&nsname); + nsres = get_elem_attr_value(elem->nselem, nameW, &nsstr, &str); if(NS_SUCCEEDED(nsres)) { - nsAString_GetData(&nsstr, &str); ret = !strcmpiW(str, name); + nsAString_Finish(&nsstr); } - nsAString_Finish(&nsstr); return ret; } @@ -605,6 +733,75 @@ IHTMLElementCollection *create_collection_from_htmlcol(HTMLDocumentNode *doc, ns return HTMLElementCollection_Create(buf.buf, buf.len); } +HRESULT get_elem_source_index(HTMLElement *elem, LONG *ret) +{ + elem_vector_t buf = {NULL, 0, 8}; + nsIDOMNode *parent_node, *iter; + UINT16 parent_type; + HTMLDOMNode *node; + int i; + nsresult nsres; + HRESULT hres; + + iter = elem->node.nsnode; + nsIDOMNode_AddRef(iter); + + /* Find document or document fragment parent. */ + while(1) { + nsres = nsIDOMNode_GetParentNode(iter, &parent_node); + nsIDOMNode_Release(iter); + assert(nsres == NS_OK); + if(!parent_node) + break; + + nsres = nsIDOMNode_GetNodeType(parent_node, &parent_type); + assert(nsres == NS_OK); + + if(parent_type != ELEMENT_NODE) { + if(parent_type != DOCUMENT_NODE && parent_type != DOCUMENT_FRAGMENT_NODE) + FIXME("Unexpected parent_type %d\n", parent_type); + break; + } + + iter = parent_node; + } + + if(!parent_node) { + *ret = -1; + return S_OK; + } + + hres = get_node(elem->node.doc, parent_node, TRUE, &node); + nsIDOMNode_Release(parent_node); + if(FAILED(hres)) + return hres; + + + /* Create all children collection and find the element in it. + * This could be optimized if we ever find the reason. */ + buf.buf = heap_alloc(buf.size*sizeof(*buf.buf)); + if(!buf.buf) { + IHTMLDOMNode_Release(&node->IHTMLDOMNode_iface); + return E_OUTOFMEMORY; + } + + create_all_list(elem->node.doc, node, &buf); + + for(i=0; i < buf.len; i++) { + if(buf.buf[i] == elem) + break; + } + IHTMLDOMNode_Release(&node->IHTMLDOMNode_iface); + heap_free(buf.buf); + if(i == buf.len) { + FIXME("The element is not in parent's child list?\n"); + return E_UNEXPECTED; + } + + *ret = i; + return S_OK; +} + static IHTMLElementCollection *HTMLElementCollection_Create(HTMLElement **elems, DWORD len) { HTMLElementCollection *ret = heap_alloc_zero(sizeof(HTMLElementCollection)); diff --git a/dll/win32/mshtml/htmlevent.c b/dll/win32/mshtml/htmlevent.c index b6278cd3a0f..300e738ee67 100644 --- a/dll/win32/mshtml/htmlevent.c +++ b/dll/win32/mshtml/htmlevent.c @@ -94,6 +94,9 @@ static const WCHAR onmouseoverW[] = {'o','n','m','o','u','s','e','o','v','e','r' static const WCHAR mouseupW[] = {'m','o','u','s','e','u','p',0}; static const WCHAR onmouseupW[] = {'o','n','m','o','u','s','e','u','p',0}; +static const WCHAR mousewheelW[] = {'m','o','u','s','e','w','h','e','e','l',0}; +static const WCHAR onmousewheelW[] = {'o','n','m','o','u','s','e','w','h','e','e','l',0}; + static const WCHAR pasteW[] = {'p','a','s','t','e',0}; static const WCHAR onpasteW[] = {'o','n','p','a','s','t','e',0}; @@ -190,6 +193,8 @@ static const event_info_t event_info[] = { EVENT_DEFAULTLISTENER|EVENT_BUBBLE}, {mouseupW, onmouseupW, EVENTT_MOUSE, DISPID_EVMETH_ONMOUSEUP, EVENT_DEFAULTLISTENER|EVENT_BUBBLE}, + {mousewheelW, onmousewheelW, EVENTT_MOUSE, DISPID_EVMETH_ONMOUSEWHEEL, + 0}, {pasteW, onpasteW, EVENTT_NONE, DISPID_EVMETH_ONPASTE, EVENT_CANCELABLE}, {readystatechangeW, onreadystatechangeW, EVENTT_NONE, DISPID_EVMETH_ONREADYSTATECHANGE, @@ -201,7 +206,7 @@ static const event_info_t event_info[] = { {selectstartW, onselectstartW, EVENTT_MOUSE, DISPID_EVMETH_ONSELECTSTART, EVENT_CANCELABLE}, {submitW, onsubmitW, EVENTT_HTML, DISPID_EVMETH_ONSUBMIT, - EVENT_DEFAULTLISTENER|EVENT_BUBBLE|EVENT_CANCELABLE} + EVENT_DEFAULTLISTENER|EVENT_BUBBLE|EVENT_CANCELABLE|EVENT_HASDEFAULTHANDLERS} }; eventid_t str_to_eid(LPCWSTR str) @@ -251,25 +256,22 @@ static HRESULT WINAPI HTMLEventObj_QueryInterface(IHTMLEventObj *iface, REFIID r { HTMLEventObj *This = impl_from_IHTMLEventObj(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLEventObj_iface; }else if(IsEqualGUID(&IID_IHTMLEventObj, riid)) { - TRACE("(%p)->(IID_IHTMLEventObj %p)\n", This, ppv); *ppv = &This->IHTMLEventObj_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLEventObj_AddRef(IHTMLEventObj *iface) @@ -1314,16 +1316,8 @@ static HRESULT ensure_nsevent_handler(HTMLDocumentNode *doc, event_target_t *eve return S_OK; if(event_info[eid].flags & EVENT_BIND_TO_BODY) { - nsIDOMHTMLElement *nsbody; - nsresult nsres; - - nsres = nsIDOMHTMLDocument_GetBody(doc->nsdoc, &nsbody); - if(NS_SUCCEEDED(nsres) && nsbody) { - nsnode = (nsIDOMNode*)nsbody; - }else { - ERR("GetBody failed: %08x\n", nsres); - return E_UNEXPECTED; - } + nsnode = doc->node.nsnode; + nsIDOMNode_AddRef(nsnode); } doc->event_vector[eid] = TRUE; @@ -1509,24 +1503,19 @@ void update_cp_events(HTMLInnerWindow *window, event_target_t **event_target_ptr } } -void check_event_attr(HTMLDocumentNode *doc, nsIDOMElement *nselem) +void check_event_attr(HTMLDocumentNode *doc, nsIDOMHTMLElement *nselem) { const PRUnichar *attr_value; - nsAString attr_name_str, attr_value_str; + nsAString attr_value_str; IDispatch *disp; HTMLDOMNode *node; int i; nsresult nsres; HRESULT hres; - nsAString_Init(&attr_value_str, NULL); - nsAString_Init(&attr_name_str, NULL); - for(i=0; i < EVENTID_LAST; i++) { - nsAString_SetData(&attr_name_str, event_info[i].attr_name); - nsres = nsIDOMElement_GetAttribute(nselem, &attr_name_str, &attr_value_str); + nsres = get_elem_attr_value(nselem, event_info[i].attr_name, &attr_value_str, &attr_value); if(NS_SUCCEEDED(nsres)) { - nsAString_GetData(&attr_value_str, &attr_value); if(!*attr_value) continue; @@ -1541,11 +1530,9 @@ void check_event_attr(HTMLDocumentNode *doc, nsIDOMElement *nselem) } IDispatch_Release(disp); } + nsAString_Finish(&attr_value_str); } } - - nsAString_Finish(&attr_value_str); - nsAString_Finish(&attr_name_str); } HRESULT doc_init_events(HTMLDocumentNode *doc) diff --git a/dll/win32/mshtml/htmlevent.h b/dll/win32/mshtml/htmlevent.h index 528eded8f16..01b9d9fca44 100644 --- a/dll/win32/mshtml/htmlevent.h +++ b/dll/win32/mshtml/htmlevent.h @@ -16,6 +16,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#pragma once + typedef enum { EVENTID_ABORT, EVENTID_BEFOREUNLOAD, @@ -39,6 +41,7 @@ typedef enum { EVENTID_MOUSEOUT, EVENTID_MOUSEOVER, EVENTID_MOUSEUP, + EVENTID_MOUSEWHEEL, EVENTID_PASTE, EVENTID_READYSTATECHANGE, EVENTID_RESIZE, @@ -49,7 +52,7 @@ typedef enum { } eventid_t; eventid_t str_to_eid(LPCWSTR) DECLSPEC_HIDDEN; -void check_event_attr(HTMLDocumentNode*,nsIDOMElement*) DECLSPEC_HIDDEN; +void check_event_attr(HTMLDocumentNode*,nsIDOMHTMLElement*) DECLSPEC_HIDDEN; void release_event_target(event_target_t*) DECLSPEC_HIDDEN; void fire_event(HTMLDocumentNode*,eventid_t,BOOL,nsIDOMNode*,nsIDOMEvent*,IDispatch*) DECLSPEC_HIDDEN; HRESULT set_event_handler(event_target_t**,HTMLDocumentNode*,eventid_t,VARIANT*) DECLSPEC_HIDDEN; diff --git a/dll/win32/mshtml/htmlform.c b/dll/win32/mshtml/htmlform.c index 7eba35cee25..26677baddfb 100644 --- a/dll/win32/mshtml/htmlform.c +++ b/dll/win32/mshtml/htmlform.c @@ -270,15 +270,36 @@ static HRESULT WINAPI HTMLFormElement_get_elements(IHTMLFormElement *iface, IDis static HRESULT WINAPI HTMLFormElement_put_target(IHTMLFormElement *iface, BSTR v) { HTMLFormElement *This = impl_from_IHTMLFormElement(iface); - FIXME("(%p)->(%s)\n", This, wine_dbgstr_w(v)); - return E_NOTIMPL; + nsAString str; + nsresult nsres; + + TRACE("(%p)->(%s)\n", This, wine_dbgstr_w(v)); + + nsAString_InitDepend(&str, v); + + nsres = nsIDOMHTMLFormElement_SetTarget(This->nsform, &str); + + nsAString_Finish(&str); + if (NS_FAILED(nsres)) { + ERR("Set Target(%s) failed: %08x\n", wine_dbgstr_w(v), nsres); + return E_FAIL; + } + + return S_OK; } static HRESULT WINAPI HTMLFormElement_get_target(IHTMLFormElement *iface, BSTR *p) { HTMLFormElement *This = impl_from_IHTMLFormElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsAString str; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsAString_Init(&str, NULL); + nsres = nsIDOMHTMLFormElement_GetTarget(This->nsform, &str); + + return return_nsstr(nsres, &str, p); } static HRESULT WINAPI HTMLFormElement_put_name(IHTMLFormElement *iface, BSTR v) @@ -420,8 +441,16 @@ static HRESULT WINAPI HTMLFormElement_submit(IHTMLFormElement *iface) static HRESULT WINAPI HTMLFormElement_reset(IHTMLFormElement *iface) { HTMLFormElement *This = impl_from_IHTMLFormElement(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; + nsresult nsres; + + TRACE("(%p)->()\n", This); + nsres = nsIDOMHTMLFormElement_Reset(This->nsform); + if (NS_FAILED(nsres)) { + ERR("Reset failed: %08x\n", nsres); + return E_FAIL; + } + + return S_OK; } static HRESULT WINAPI HTMLFormElement_put_length(IHTMLFormElement *iface, LONG v) @@ -552,7 +581,7 @@ static HRESULT HTMLFormElement_get_dispid(HTMLDOMNode *iface, { HTMLFormElement *This = impl_from_HTMLDOMNode(iface); nsIDOMHTMLCollection *elements; - nsAString nsname, nsstr; + nsAString nsstr, name_str; UINT32 len, i; nsresult nsres; HRESULT hres = DISP_E_UNKNOWNNAME; @@ -588,7 +617,6 @@ static HRESULT HTMLFormElement_get_dispid(HTMLDOMNode *iface, } } - nsAString_InitDepend(&nsname, nameW); nsAString_Init(&nsstr, NULL); for(i = 0; i < len; ++i) { nsIDOMNode *nsitem; @@ -628,21 +656,22 @@ static HRESULT HTMLFormElement_get_dispid(HTMLDOMNode *iface, } /* compare by name attr */ - nsres = nsIDOMHTMLElement_GetAttribute(nshtml_elem, &nsname, &nsstr); + nsres = get_elem_attr_value(nshtml_elem, nameW, &name_str, &str); nsIDOMHTMLElement_Release(nshtml_elem); - nsAString_GetData(&nsstr, &str); - if(!strcmpiW(str, name)) { - /* FIXME: using index for dispid */ - *pid = MSHTML_DISPID_CUSTOM_MIN + i; - hres = S_OK; - break; + if(NS_SUCCEEDED(nsres)) { + if(!strcmpiW(str, name)) { + nsAString_Finish(&name_str); + /* FIXME: using index for dispid */ + *pid = MSHTML_DISPID_CUSTOM_MIN + i; + hres = S_OK; + break; + } + nsAString_Finish(&name_str); } } - nsAString_Finish(&nsname); + nsAString_Finish(&nsstr); - nsIDOMHTMLCollection_Release(elements); - return hres; } @@ -669,12 +698,24 @@ static HRESULT HTMLFormElement_invoke(HTMLDOMNode *iface, return S_OK; } +static HRESULT HTMLFormElement_handle_event(HTMLDOMNode *iface, eventid_t eid, nsIDOMEvent *event, BOOL *prevent_default) +{ + HTMLFormElement *This = impl_from_HTMLDOMNode(iface); + + if(eid == EVENTID_SUBMIT) { + *prevent_default = TRUE; + return IHTMLFormElement_submit(&This->IHTMLFormElement_iface); + } + + return HTMLElement_handle_event(&This->element.node, eid, event, prevent_default); +} + static const NodeImplVtbl HTMLFormElementImplVtbl = { HTMLFormElement_QI, HTMLElement_destructor, HTMLElement_cpc, HTMLElement_clone, - HTMLElement_handle_event, + HTMLFormElement_handle_event, HTMLElement_get_attr_col, NULL, NULL, diff --git a/dll/win32/mshtml/htmlhead.c b/dll/win32/mshtml/htmlhead.c index fb81ae5e9f7..80f748bc4cd 100644 --- a/dll/win32/mshtml/htmlhead.c +++ b/dll/win32/mshtml/htmlhead.c @@ -121,12 +121,12 @@ static HRESULT HTMLTitleElement_QI(HTMLDOMNode *iface, REFIID riid, void **ppv) { HTMLTitleElement *This = HTMLTitleElement_from_HTMLDOMNode(iface); - if(IsEqualGUID(&IID_IHTMLTitleElement, riid)) { - TRACE("(%p)->(IID_IHTMLTitleElement %p)\n", This, ppv); + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + + if(IsEqualGUID(&IID_IHTMLTitleElement, riid)) *ppv = &This->IHTMLTitleElement_iface; - }else { + else return HTMLElement_QI(&This->element.node, riid, ppv); - } IUnknown_AddRef((IUnknown*)*ppv); return S_OK; @@ -281,12 +281,12 @@ static HRESULT HTMLHeadElement_QI(HTMLDOMNode *iface, REFIID riid, void **ppv) { HTMLHeadElement *This = impl_from_HTMLDOMNode(iface); - if(IsEqualGUID(&IID_IHTMLHeadElement, riid)) { - TRACE("(%p)->(IID_IHTMLHeadElement %p)\n", This, ppv); + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + + if(IsEqualGUID(&IID_IHTMLHeadElement, riid)) *ppv = &This->IHTMLHeadElement_iface; - }else { + else return HTMLElement_QI(&This->element.node, riid, ppv); - } IUnknown_AddRef((IUnknown*)*ppv); return S_OK; diff --git a/dll/win32/mshtml/htmlimg.c b/dll/win32/mshtml/htmlimg.c index c8e9d10c0ac..861fbda5804 100644 --- a/dll/win32/mshtml/htmlimg.c +++ b/dll/win32/mshtml/htmlimg.c @@ -87,15 +87,37 @@ static HRESULT WINAPI HTMLImgElement_Invoke(IHTMLImgElement *iface, DISPID dispI static HRESULT WINAPI HTMLImgElement_put_isMap(IHTMLImgElement *iface, VARIANT_BOOL v) { HTMLImgElement *This = impl_from_IHTMLImgElement(iface); - FIXME("(%p)->(%x)\n", This, v); - return E_NOTIMPL; + nsresult nsres; + + TRACE("(%p)->(%x)\n", This, v); + + nsres = nsIDOMHTMLImageElement_SetIsMap(This->nsimg, v != VARIANT_FALSE); + if (NS_FAILED(nsres)) { + ERR("Set IsMap failed: %08x\n", nsres); + return E_FAIL; + } + + return S_OK; } static HRESULT WINAPI HTMLImgElement_get_isMap(IHTMLImgElement *iface, VARIANT_BOOL *p) { HTMLImgElement *This = impl_from_IHTMLImgElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + cpp_bool b; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + if (p == NULL) + return E_INVALIDARG; + + nsres = nsIDOMHTMLImageElement_GetIsMap(This->nsimg, &b); + if (NS_FAILED(nsres)) { + ERR("Get IsMap failed: %08x\n", nsres); + return E_FAIL; + } + *p = b ? VARIANT_TRUE : VARIANT_FALSE; + return S_OK; } static HRESULT WINAPI HTMLImgElement_put_useMap(IHTMLImgElement *iface, BSTR v) @@ -375,15 +397,35 @@ static HRESULT WINAPI HTMLImgElement_get_loop(IHTMLImgElement *iface, VARIANT *p static HRESULT WINAPI HTMLImgElement_put_align(IHTMLImgElement *iface, BSTR v) { HTMLImgElement *This = impl_from_IHTMLImgElement(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + nsAString str; + nsresult nsres; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + nsAString_InitDepend(&str, v); + + nsres = nsIDOMHTMLImageElement_SetAlign(This->nsimg, &str); + nsAString_Finish(&str); + if (NS_FAILED(nsres)){ + ERR("Set Align(%s) failed: %08x\n", debugstr_w(v), nsres); + return E_FAIL; + } + + return S_OK; } static HRESULT WINAPI HTMLImgElement_get_align(IHTMLImgElement *iface, BSTR *p) { HTMLImgElement *This = impl_from_IHTMLImgElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsAString str; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsAString_Init(&str, NULL); + nsres = nsIDOMHTMLImageElement_GetAlign(This->nsimg, &str); + + return return_nsstr(nsres, &str, p); } static HRESULT WINAPI HTMLImgElement_put_onload(IHTMLImgElement *iface, VARIANT v) @@ -690,24 +732,22 @@ static HRESULT WINAPI HTMLImageElementFactory_QueryInterface(IHTMLImageElementFa { HTMLImageElementFactory *This = impl_from_IHTMLImageElementFactory(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_Unknown %p)\n", This, ppv); *ppv = &This->IHTMLImageElementFactory_iface; }else if(IsEqualGUID(&IID_IHTMLImageElementFactory, riid)) { - TRACE("(%p)->(IID_IHTMLImageElementFactory %p)\n", This, ppv); *ppv = &This->IHTMLImageElementFactory_iface; - }else if(dispex_query_interface(&This->dispex, riid, ppv)) + }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; - - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + return E_NOINTERFACE; } - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLImageElementFactory_AddRef(IHTMLImageElementFactory *iface) @@ -737,16 +777,14 @@ static HRESULT WINAPI HTMLImageElementFactory_GetTypeInfoCount(IHTMLImageElement UINT *pctinfo) { HTMLImageElementFactory *This = impl_from_IHTMLImageElementFactory(iface); - FIXME("(%p)->(%p)\n", This, pctinfo); - return E_NOTIMPL; + return IDispatchEx_GetTypeInfoCount(&This->dispex.IDispatchEx_iface, pctinfo); } static HRESULT WINAPI HTMLImageElementFactory_GetTypeInfo(IHTMLImageElementFactory *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo) { HTMLImageElementFactory *This = impl_from_IHTMLImageElementFactory(iface); - FIXME("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo); - return E_NOTIMPL; + return IDispatchEx_GetTypeInfo(&This->dispex.IDispatchEx_iface, iTInfo, lcid, ppTInfo); } static HRESULT WINAPI HTMLImageElementFactory_GetIDsOfNames(IHTMLImageElementFactory *iface, @@ -754,9 +792,7 @@ static HRESULT WINAPI HTMLImageElementFactory_GetIDsOfNames(IHTMLImageElementFac DISPID *rgDispId) { HTMLImageElementFactory *This = impl_from_IHTMLImageElementFactory(iface); - FIXME("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, - cNames, lcid, rgDispId); - return E_NOTIMPL; + return IDispatchEx_GetIDsOfNames(&This->dispex.IDispatchEx_iface, riid, rgszNames, cNames, lcid, rgDispId); } static HRESULT WINAPI HTMLImageElementFactory_Invoke(IHTMLImageElementFactory *iface, @@ -765,9 +801,8 @@ static HRESULT WINAPI HTMLImageElementFactory_Invoke(IHTMLImageElementFactory *i UINT *puArgErr) { HTMLImageElementFactory *This = impl_from_IHTMLImageElementFactory(iface); - FIXME("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid), - lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); - return E_NOTIMPL; + return IDispatchEx_Invoke(&This->dispex.IDispatchEx_iface, dispIdMember, riid, lcid, wFlags, + pDispParams, pVarResult, pExcepInfo, puArgErr); } static LONG var_to_size(const VARIANT *v) diff --git a/dll/win32/mshtml/htmlinput.c b/dll/win32/mshtml/htmlinput.c index 62ed4e6f02e..73b70f11166 100644 --- a/dll/win32/mshtml/htmlinput.c +++ b/dll/win32/mshtml/htmlinput.c @@ -241,22 +241,66 @@ static HRESULT WINAPI HTMLInputElement_get_disabled(IHTMLInputElement *iface, VA static HRESULT WINAPI HTMLInputElement_get_form(IHTMLInputElement *iface, IHTMLFormElement **p) { HTMLInputElement *This = impl_from_IHTMLInputElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsIDOMHTMLFormElement *nsform; + HTMLDOMNode *node; + HRESULT hres; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMHTMLInputElement_GetForm(This->nsinput, &nsform); + if (NS_FAILED(nsres) || nsform == NULL) { + ERR("GetForm failed: %08x, nsform: %p\n", nsres, nsform); + *p = NULL; + return E_FAIL; + } + + hres = get_node(This->element.node.doc, (nsIDOMNode*)nsform, TRUE, &node); + nsIDOMHTMLFormElement_Release(nsform); + if (FAILED(hres)) + return hres; + + hres = IHTMLDOMNode_QueryInterface(&node->IHTMLDOMNode_iface, &IID_IHTMLElement, (void**)p); + + node_release(node); + return hres; } static HRESULT WINAPI HTMLInputElement_put_size(IHTMLInputElement *iface, LONG v) { HTMLInputElement *This = impl_from_IHTMLInputElement(iface); - FIXME("(%p)->(%d)\n", This, v); - return E_NOTIMPL; + UINT32 val = v; + nsresult nsres; + + TRACE("(%p)->(%d)\n", This, v); + if (v <= 0) + return CTL_E_INVALIDPROPERTYVALUE; + + nsres = nsIDOMHTMLInputElement_SetSize(This->nsinput, val); + if (NS_FAILED(nsres)) { + ERR("Set Size(%u) failed: %08x\n", val, nsres); + return E_FAIL; + } + return S_OK; } static HRESULT WINAPI HTMLInputElement_get_size(IHTMLInputElement *iface, LONG *p) { HTMLInputElement *This = impl_from_IHTMLInputElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + UINT32 val; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + if (p == NULL) + return E_INVALIDARG; + + nsres = nsIDOMHTMLInputElement_GetSize(This->nsinput, &val); + if (NS_FAILED(nsres)) { + ERR("Get Size failed: %08x\n", nsres); + return E_FAIL; + } + *p = val; + return S_OK; } static HRESULT WINAPI HTMLInputElement_put_maxLength(IHTMLInputElement *iface, LONG v) @@ -375,15 +419,33 @@ static HRESULT WINAPI HTMLInputElement_get_defaultValue(IHTMLInputElement *iface static HRESULT WINAPI HTMLInputElement_put_readOnly(IHTMLInputElement *iface, VARIANT_BOOL v) { HTMLInputElement *This = impl_from_IHTMLInputElement(iface); - FIXME("(%p)->(%x)\n", This, v); - return E_NOTIMPL; + nsresult nsres; + + TRACE("(%p)->(%x)\n", This, v); + + nsres = nsIDOMHTMLInputElement_SetReadOnly(This->nsinput, v != VARIANT_FALSE); + if (NS_FAILED(nsres)) { + ERR("Set ReadOnly Failed: %08x\n", nsres); + return E_FAIL; + } + return S_OK; } static HRESULT WINAPI HTMLInputElement_get_readOnly(IHTMLInputElement *iface, VARIANT_BOOL *p) { HTMLInputElement *This = impl_from_IHTMLInputElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsresult nsres; + cpp_bool b; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMHTMLInputElement_GetReadOnly(This->nsinput, &b); + if (NS_FAILED(nsres)) { + ERR("Get ReadOnly Failed: %08x\n", nsres); + return E_FAIL; + } + *p = b ? VARIANT_TRUE : VARIANT_FALSE; + return S_OK; } static HRESULT WINAPI HTMLInputElement_createTextRange(IHTMLInputElement *iface, IHTMLTxtRange **range) @@ -1320,29 +1382,10 @@ static HRESULT WINAPI HTMLLabelElement_put_htmlFor(IHTMLLabelElement *iface, BST static HRESULT WINAPI HTMLLabelElement_get_htmlFor(IHTMLLabelElement *iface, BSTR *p) { HTMLLabelElement *This = impl_from_IHTMLLabelElement(iface); - nsAString for_str, val_str; - nsresult nsres; - HRESULT hres; TRACE("(%p)->(%p)\n", This, p); - nsAString_InitDepend(&for_str, forW); - nsAString_Init(&val_str, NULL); - nsres = nsIDOMHTMLElement_GetAttribute(This->element.nselem, &for_str, &val_str); - nsAString_Finish(&for_str); - if(NS_SUCCEEDED(nsres)) { - const PRUnichar *val; - - nsAString_GetData(&val_str, &val); - *p = SysAllocString(val); - hres = *p ? S_OK : E_OUTOFMEMORY; - }else { - ERR("GetAttribute failed: %08x\n", nsres); - hres = E_FAIL; - } - - nsAString_Finish(&val_str); - return hres; + return elem_string_attr_getter(&This->element, forW, FALSE, p); } static HRESULT WINAPI HTMLLabelElement_put_accessKey(IHTMLLabelElement *iface, BSTR v) diff --git a/dll/win32/mshtml/htmllink.c b/dll/win32/mshtml/htmllink.c index 4b9d3bdb198..0b845e792b1 100644 --- a/dll/win32/mshtml/htmllink.c +++ b/dll/win32/mshtml/htmllink.c @@ -147,15 +147,33 @@ static HRESULT WINAPI HTMLLinkElement_get_rel(IHTMLLinkElement *iface, BSTR *p) static HRESULT WINAPI HTMLLinkElement_put_rev(IHTMLLinkElement *iface, BSTR v) { HTMLLinkElement *This = impl_from_IHTMLLinkElement(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + nsAString nsstr; + nsresult nsres; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + nsAString_InitDepend(&nsstr, v); + nsres = nsIDOMHTMLLinkElement_SetRev(This->nslink, &nsstr); + nsAString_Finish(&nsstr); + if(NS_FAILED(nsres)) { + ERR("SetRev failed: %08x\n", nsres); + return E_FAIL; + } + + return S_OK; } static HRESULT WINAPI HTMLLinkElement_get_rev(IHTMLLinkElement *iface, BSTR *p) { HTMLLinkElement *This = impl_from_IHTMLLinkElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsAString nsstr; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsAString_Init(&nsstr, NULL); + nsres = nsIDOMHTMLLinkElement_GetRev(This->nslink, &nsstr); + return return_nsstr(nsres, &nsstr, p); } static HRESULT WINAPI HTMLLinkElement_put_type(IHTMLLinkElement *iface, BSTR v) @@ -272,15 +290,35 @@ static HRESULT WINAPI HTMLLinkElement_get_disabled(IHTMLLinkElement *iface, VARI static HRESULT WINAPI HTMLLinkElement_put_media(IHTMLLinkElement *iface, BSTR v) { HTMLLinkElement *This = impl_from_IHTMLLinkElement(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + nsresult nsres; + nsAString str; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + nsAString_InitDepend(&str, v); + + nsres = nsIDOMHTMLLinkElement_SetMedia(This->nslink, &str); + nsAString_Finish(&str); + + if(NS_FAILED(nsres)) { + ERR("Set Media(%s) failed: %08x\n", debugstr_w(v), nsres); + return E_FAIL; + } + return S_OK; } static HRESULT WINAPI HTMLLinkElement_get_media(IHTMLLinkElement *iface, BSTR *p) { HTMLLinkElement *This = impl_from_IHTMLLinkElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsresult nsres; + nsAString str; + + TRACE("(%p)->(%p)\n", This, p); + + nsAString_Init(&str, NULL); + nsres = nsIDOMHTMLLinkElement_GetMedia(This->nslink, &str); + + return return_nsstr(nsres, &str, p); } static const IHTMLLinkElementVtbl HTMLLinkElementVtbl = { diff --git a/dll/win32/mshtml/htmllocation.c b/dll/win32/mshtml/htmllocation.c index e2a0edda1a1..32a91ffcc99 100644 --- a/dll/win32/mshtml/htmllocation.c +++ b/dll/win32/mshtml/htmllocation.c @@ -63,25 +63,22 @@ static HRESULT WINAPI HTMLLocation_QueryInterface(IHTMLLocation *iface, REFIID r { HTMLLocation *This = impl_from_IHTMLLocation(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLLocation_iface; }else if(IsEqualGUID(&IID_IHTMLLocation, riid)) { - TRACE("(%p)->(IID_IHTMLLocation %p)\n", This, ppv); *ppv = &This->IHTMLLocation_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLLocation_AddRef(IHTMLLocation *iface) @@ -560,8 +557,8 @@ static HRESULT WINAPI HTMLLocation_replace(IHTMLLocation *iface, BSTR bstr) static HRESULT WINAPI HTMLLocation_assign(IHTMLLocation *iface, BSTR bstr) { HTMLLocation *This = impl_from_IHTMLLocation(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(bstr)); - return E_NOTIMPL; + TRACE("(%p)->(%s)\n", This, debugstr_w(bstr)); + return IHTMLLocation_put_href(iface, bstr); } static HRESULT WINAPI HTMLLocation_toString(IHTMLLocation *iface, BSTR *String) diff --git a/dll/win32/mshtml/htmlmeta.c b/dll/win32/mshtml/htmlmeta.c index d6274ef3da4..c9d3fefb572 100644 --- a/dll/win32/mshtml/htmlmeta.c +++ b/dll/win32/mshtml/htmlmeta.c @@ -91,19 +91,11 @@ static HRESULT WINAPI HTMLMetaElement_put_httpEquiv(IHTMLMetaElement *iface, BST static HRESULT WINAPI HTMLMetaElement_get_httpEquiv(IHTMLMetaElement *iface, BSTR *p) { HTMLMetaElement *This = impl_from_IHTMLMetaElement(iface); - nsAString httpequiv_str, val_str; - nsresult nsres; - static const PRUnichar httpEquivW[] = {'h','t','t','p','-','e','q','u','i','v',0}; TRACE("(%p)->(%p)\n", This, p); - nsAString_InitDepend(&httpequiv_str, httpEquivW); - nsAString_Init(&val_str, NULL); - nsres = nsIDOMHTMLElement_GetAttribute(This->element.nselem, &httpequiv_str, &val_str); - nsAString_Finish(&httpequiv_str); - - return return_nsstr(nsres, &val_str, p); + return elem_string_attr_getter(&This->element, httpEquivW, TRUE, p); } static HRESULT WINAPI HTMLMetaElement_put_content(IHTMLMetaElement *iface, BSTR v) @@ -116,19 +108,11 @@ static HRESULT WINAPI HTMLMetaElement_put_content(IHTMLMetaElement *iface, BSTR static HRESULT WINAPI HTMLMetaElement_get_content(IHTMLMetaElement *iface, BSTR *p) { HTMLMetaElement *This = impl_from_IHTMLMetaElement(iface); - nsAString content_str, val_str; - nsresult nsres; - static const PRUnichar contentW[] = {'c','o','n','t','e','n','t',0}; TRACE("(%p)->(%p)\n", This, p); - nsAString_InitDepend(&content_str, contentW); - nsAString_Init(&val_str, NULL); - nsres = nsIDOMHTMLElement_GetAttribute(This->element.nselem, &content_str, &val_str); - nsAString_Finish(&content_str); - - return return_nsstr(nsres, &val_str, p); + return elem_string_attr_getter(&This->element, contentW, TRUE, p); } static HRESULT WINAPI HTMLMetaElement_put_name(IHTMLMetaElement *iface, BSTR v) @@ -141,19 +125,11 @@ static HRESULT WINAPI HTMLMetaElement_put_name(IHTMLMetaElement *iface, BSTR v) static HRESULT WINAPI HTMLMetaElement_get_name(IHTMLMetaElement *iface, BSTR *p) { HTMLMetaElement *This = impl_from_IHTMLMetaElement(iface); - nsAString name_str, val_str; - nsresult nsres; - static const PRUnichar nameW[] = {'n','a','m','e',0}; TRACE("(%p)->(%p)\n", This, p); - nsAString_InitDepend(&name_str, nameW); - nsAString_Init(&val_str, NULL); - nsres = nsIDOMHTMLElement_GetAttribute(This->element.nselem, &name_str, &val_str); - nsAString_Finish(&name_str); - - return return_nsstr(nsres, &val_str, p); + return elem_string_attr_getter(&This->element, nameW, TRUE, p); } static HRESULT WINAPI HTMLMetaElement_put_url(IHTMLMetaElement *iface, BSTR v) @@ -170,18 +146,24 @@ static HRESULT WINAPI HTMLMetaElement_get_url(IHTMLMetaElement *iface, BSTR *p) return E_NOTIMPL; } +static const WCHAR charsetW[] = {'c','h','a','r','s','e','t',0}; + static HRESULT WINAPI HTMLMetaElement_put_charset(IHTMLMetaElement *iface, BSTR v) { HTMLMetaElement *This = impl_from_IHTMLMetaElement(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + return elem_string_attr_setter(&This->element, charsetW, v); } static HRESULT WINAPI HTMLMetaElement_get_charset(IHTMLMetaElement *iface, BSTR *p) { HTMLMetaElement *This = impl_from_IHTMLMetaElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return elem_string_attr_getter(&This->element, charsetW, TRUE, p); } static const IHTMLMetaElementVtbl HTMLMetaElementVtbl = { diff --git a/dll/win32/mshtml/htmlnode.c b/dll/win32/mshtml/htmlnode.c index 0b3f0f8d425..0768eb1da84 100644 --- a/dll/win32/mshtml/htmlnode.c +++ b/dll/win32/mshtml/htmlnode.c @@ -33,6 +33,155 @@ typedef struct { nsIDOMNodeList *nslist; } HTMLDOMChildrenCollection; +typedef struct { + IEnumVARIANT IEnumVARIANT_iface; + + LONG ref; + + ULONG iter; + HTMLDOMChildrenCollection *col; +} HTMLDOMChildrenCollectionEnum; + +static inline HTMLDOMChildrenCollectionEnum *impl_from_IEnumVARIANT(IEnumVARIANT *iface) +{ + return CONTAINING_RECORD(iface, HTMLDOMChildrenCollectionEnum, IEnumVARIANT_iface); +} + +static HRESULT WINAPI HTMLDOMChildrenCollectionEnum_QueryInterface(IEnumVARIANT *iface, REFIID riid, void **ppv) +{ + HTMLDOMChildrenCollectionEnum *This = impl_from_IEnumVARIANT(iface); + + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + + if(IsEqualGUID(riid, &IID_IUnknown)) { + *ppv = &This->IEnumVARIANT_iface; + }else if(IsEqualGUID(riid, &IID_IEnumVARIANT)) { + *ppv = &This->IEnumVARIANT_iface; + }else { + FIXME("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + *ppv = NULL; + return E_NOINTERFACE; + } + + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; +} + +static ULONG WINAPI HTMLDOMChildrenCollectionEnum_AddRef(IEnumVARIANT *iface) +{ + HTMLDOMChildrenCollectionEnum *This = impl_from_IEnumVARIANT(iface); + LONG ref = InterlockedIncrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); + + return ref; +} + +static ULONG WINAPI HTMLDOMChildrenCollectionEnum_Release(IEnumVARIANT *iface) +{ + HTMLDOMChildrenCollectionEnum *This = impl_from_IEnumVARIANT(iface); + LONG ref = InterlockedDecrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); + + if(!ref) { + IHTMLDOMChildrenCollection_Release(&This->col->IHTMLDOMChildrenCollection_iface); + heap_free(This); + } + + return ref; +} + +static ULONG get_enum_len(HTMLDOMChildrenCollectionEnum *This) +{ + ULONG len; + nsresult nsres; + + nsres = nsIDOMNodeList_GetLength(This->col->nslist, &len); + assert(nsres == NS_OK); + return len; +} + +static HRESULT WINAPI HTMLDOMChildrenCollectionEnum_Next(IEnumVARIANT *iface, ULONG celt, VARIANT *rgVar, ULONG *pCeltFetched) +{ + HTMLDOMChildrenCollectionEnum *This = impl_from_IEnumVARIANT(iface); + ULONG fetched = 0, len; + nsIDOMNode *nsnode; + HTMLDOMNode *node; + nsresult nsres; + HRESULT hres; + + TRACE("(%p)->(%d %p %p)\n", This, celt, rgVar, pCeltFetched); + + len = get_enum_len(This); + + while(This->iter+fetched < len && fetched < celt) { + nsres = nsIDOMNodeList_Item(This->col->nslist, This->iter+fetched, &nsnode); + assert(nsres == NS_OK); + + hres = get_node(This->col->doc, nsnode, TRUE, &node); + nsIDOMNode_Release(nsnode); + if(FAILED(hres)) { + ERR("get_node failed: %08x\n", hres); + break; + } + + V_VT(rgVar+fetched) = VT_DISPATCH; + IHTMLDOMNode_AddRef(&node->IHTMLDOMNode_iface); + V_DISPATCH(rgVar+fetched) = (IDispatch*)&node->IHTMLDOMNode_iface; + fetched++; + } + + This->iter += fetched; + if(pCeltFetched) + *pCeltFetched = fetched; + return fetched == celt ? S_OK : S_FALSE; +} + +static HRESULT WINAPI HTMLDOMChildrenCollectionEnum_Skip(IEnumVARIANT *iface, ULONG celt) +{ + HTMLDOMChildrenCollectionEnum *This = impl_from_IEnumVARIANT(iface); + ULONG len; + + TRACE("(%p)->(%d)\n", This, celt); + + len = get_enum_len(This); + if(This->iter + celt > len) { + This->iter = len; + return S_FALSE; + } + + This->iter += celt; + return S_OK; +} + +static HRESULT WINAPI HTMLDOMChildrenCollectionEnum_Reset(IEnumVARIANT *iface) +{ + HTMLDOMChildrenCollectionEnum *This = impl_from_IEnumVARIANT(iface); + + TRACE("(%p)->()\n", This); + + This->iter = 0; + return S_OK; +} + +static HRESULT WINAPI HTMLDOMChildrenCollectionEnum_Clone(IEnumVARIANT *iface, IEnumVARIANT **ppEnum) +{ + HTMLDOMChildrenCollectionEnum *This = impl_from_IEnumVARIANT(iface); + FIXME("(%p)->(%p)\n", This, ppEnum); + return E_NOTIMPL; +} + +static const IEnumVARIANTVtbl HTMLDOMChildrenCollectionEnumVtbl = { + HTMLDOMChildrenCollectionEnum_QueryInterface, + HTMLDOMChildrenCollectionEnum_AddRef, + HTMLDOMChildrenCollectionEnum_Release, + HTMLDOMChildrenCollectionEnum_Next, + HTMLDOMChildrenCollectionEnum_Skip, + HTMLDOMChildrenCollectionEnum_Reset, + HTMLDOMChildrenCollectionEnum_Clone +}; + static inline HTMLDOMChildrenCollection *impl_from_IHTMLDOMChildrenCollection(IHTMLDOMChildrenCollection *iface) { return CONTAINING_RECORD(iface, HTMLDOMChildrenCollection, IHTMLDOMChildrenCollection_iface); @@ -42,25 +191,22 @@ static HRESULT WINAPI HTMLDOMChildrenCollection_QueryInterface(IHTMLDOMChildrenC { HTMLDOMChildrenCollection *This = impl_from_IHTMLDOMChildrenCollection(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLDOMChildrenCollection_iface; }else if(IsEqualGUID(&IID_IHTMLDOMChildrenCollection, riid)) { - TRACE("(%p)->(IID_IHTMLDOMChildrenCollection %p)\n", This, ppv); *ppv = &This->IHTMLDOMChildrenCollection_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLDOMChildrenCollection_AddRef(IHTMLDOMChildrenCollection *iface) @@ -131,11 +277,26 @@ static HRESULT WINAPI HTMLDOMChildrenCollection_get_length(IHTMLDOMChildrenColle return S_OK; } -static HRESULT WINAPI HTMLDOMChildrenCollection__newEnum(IHTMLDOMChildrenCollection *iface, IUnknown **p) +static HRESULT WINAPI HTMLDOMChildrenCollection_get__newEnum(IHTMLDOMChildrenCollection *iface, IUnknown **p) { HTMLDOMChildrenCollection *This = impl_from_IHTMLDOMChildrenCollection(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + HTMLDOMChildrenCollectionEnum *ret; + + TRACE("(%p)->(%p)\n", This, p); + + ret = heap_alloc(sizeof(*ret)); + if(!ret) + return E_OUTOFMEMORY; + + ret->IEnumVARIANT_iface.lpVtbl = &HTMLDOMChildrenCollectionEnumVtbl; + ret->ref = 1; + ret->iter = 0; + + IHTMLDOMChildrenCollection_AddRef(&This->IHTMLDOMChildrenCollection_iface); + ret->col = This; + + *p = (IUnknown*)&ret->IEnumVARIANT_iface; + return S_OK; } static HRESULT WINAPI HTMLDOMChildrenCollection_item(IHTMLDOMChildrenCollection *iface, LONG index, IDispatch **ppItem) @@ -181,7 +342,7 @@ static const IHTMLDOMChildrenCollectionVtbl HTMLDOMChildrenCollectionVtbl = { HTMLDOMChildrenCollection_GetIDsOfNames, HTMLDOMChildrenCollection_Invoke, HTMLDOMChildrenCollection_get_length, - HTMLDOMChildrenCollection__newEnum, + HTMLDOMChildrenCollection_get__newEnum, HTMLDOMChildrenCollection_item }; @@ -316,6 +477,8 @@ static ULONG WINAPI HTMLDOMNode_Release(IHTMLDOMNode *iface) TRACE("(%p) ref=%d\n", This, ref); if(!ref) { + if(This->vtbl->unlink) + This->vtbl->unlink(This); This->vtbl->destructor(This); release_dispex(&This->dispex); heap_free(This); @@ -984,47 +1147,34 @@ static nsXPCOMCycleCollectionParticipant node_ccp; HRESULT HTMLDOMNode_QI(HTMLDOMNode *This, REFIID riid, void **ppv) { - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLDOMNode_iface; }else if(IsEqualGUID(&IID_IDispatch, riid)) { - TRACE("(%p)->(IID_IDispatch %p)\n", This, ppv); *ppv = &This->IHTMLDOMNode_iface; - }else if(IsEqualGUID(&IID_IDispatchEx, riid)) { - if(This->dispex.data) { - TRACE("(%p)->(IID_IDispatchEx %p)\n", This, ppv); - *ppv = &This->dispex.IDispatchEx_iface; - }else { - FIXME("(%p)->(IID_IDispatchEx %p)\n", This, ppv); - return E_NOINTERFACE; - } + }else if(IsEqualGUID(&IID_IDispatchEx, riid) && This->dispex.data) { + *ppv = &This->dispex.IDispatchEx_iface; }else if(IsEqualGUID(&IID_IHTMLDOMNode, riid)) { - TRACE("(%p)->(IID_IHTMLDOMNode %p)\n", This, ppv); *ppv = &This->IHTMLDOMNode_iface; }else if(IsEqualGUID(&IID_IHTMLDOMNode2, riid)) { - TRACE("(%p)->(IID_IHTMLDOMNode2 %p)\n", This, ppv); *ppv = &This->IHTMLDOMNode2_iface; }else if(IsEqualGUID(&IID_nsXPCOMCycleCollectionParticipant, riid)) { - TRACE("(%p)->(IID_nsXPCOMCycleCollectionParticipant %p)\n", This, ppv); *ppv = &node_ccp; return NS_OK; }else if(IsEqualGUID(&IID_nsCycleCollectionISupports, riid)) { - TRACE("(%p)->(IID_nsCycleCollectionISupports %p)\n", This, ppv); *ppv = &This->IHTMLDOMNode_iface; return NS_OK; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } void HTMLDOMNode_destructor(HTMLDOMNode *This) diff --git a/dll/win32/mshtml/htmloption.c b/dll/win32/mshtml/htmloption.c index 4621c4a83b7..9e75500e1c6 100644 --- a/dll/win32/mshtml/htmloption.c +++ b/dll/win32/mshtml/htmloption.c @@ -352,26 +352,24 @@ static HRESULT WINAPI HTMLOptionElementFactory_QueryInterface(IHTMLOptionElement { HTMLOptionElementFactory *This = impl_from_IHTMLOptionElementFactory(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLOptionElementFactory_iface; }else if(IsEqualGUID(&IID_IDispatch, riid)) { - TRACE("(%p)->(IID_IDispatch %p)\n", This, ppv); *ppv = &This->IHTMLOptionElementFactory_iface; }else if(IsEqualGUID(&IID_IHTMLOptionElementFactory, riid)) { - TRACE("(%p)->(IID_IHTMLOptionElementFactory %p)\n", This, ppv); *ppv = &This->IHTMLOptionElementFactory_iface; + }else if(dispex_query_interface(&This->dispex, riid, ppv)) { + return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLOptionElementFactory_AddRef(IHTMLOptionElementFactory *iface) @@ -391,8 +389,10 @@ static ULONG WINAPI HTMLOptionElementFactory_Release(IHTMLOptionElementFactory * TRACE("(%p) ref=%d\n", This, ref); - if(!ref) + if(!ref) { + release_dispex(&This->dispex); heap_free(This); + } return ref; } @@ -400,16 +400,14 @@ static ULONG WINAPI HTMLOptionElementFactory_Release(IHTMLOptionElementFactory * static HRESULT WINAPI HTMLOptionElementFactory_GetTypeInfoCount(IHTMLOptionElementFactory *iface, UINT *pctinfo) { HTMLOptionElementFactory *This = impl_from_IHTMLOptionElementFactory(iface); - FIXME("(%p)->(%p)\n", This, pctinfo); - return E_NOTIMPL; + return IDispatchEx_GetTypeInfoCount(&This->dispex.IDispatchEx_iface, pctinfo); } static HRESULT WINAPI HTMLOptionElementFactory_GetTypeInfo(IHTMLOptionElementFactory *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo) { HTMLOptionElementFactory *This = impl_from_IHTMLOptionElementFactory(iface); - FIXME("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo); - return E_NOTIMPL; + return IDispatchEx_GetTypeInfo(&This->dispex.IDispatchEx_iface, iTInfo, lcid, ppTInfo); } static HRESULT WINAPI HTMLOptionElementFactory_GetIDsOfNames(IHTMLOptionElementFactory *iface, REFIID riid, @@ -417,9 +415,7 @@ static HRESULT WINAPI HTMLOptionElementFactory_GetIDsOfNames(IHTMLOptionElementF LCID lcid, DISPID *rgDispId) { HTMLOptionElementFactory *This = impl_from_IHTMLOptionElementFactory(iface); - FIXME("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, - lcid, rgDispId); - return E_NOTIMPL; + return IDispatchEx_GetIDsOfNames(&This->dispex.IDispatchEx_iface, riid, rgszNames, cNames, lcid, rgDispId); } static HRESULT WINAPI HTMLOptionElementFactory_Invoke(IHTMLOptionElementFactory *iface, DISPID dispIdMember, @@ -427,9 +423,8 @@ static HRESULT WINAPI HTMLOptionElementFactory_Invoke(IHTMLOptionElementFactory VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr) { HTMLOptionElementFactory *This = impl_from_IHTMLOptionElementFactory(iface); - FIXME("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid), - lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); - return E_NOTIMPL; + return IDispatchEx_Invoke(&This->dispex.IDispatchEx_iface, dispIdMember, riid, lcid, wFlags, pDispParams, + pVarResult, pExcepInfo, puArgErr); } static HRESULT WINAPI HTMLOptionElementFactory_create(IHTMLOptionElementFactory *iface, @@ -495,6 +490,18 @@ static const IHTMLOptionElementFactoryVtbl HTMLOptionElementFactoryVtbl = { HTMLOptionElementFactory_create }; +static const tid_t HTMLOptionElementFactory_iface_tids[] = { + IHTMLOptionElementFactory_tid, + 0 +}; + +static dispex_static_data_t HTMLOptionElementFactory_dispex = { + NULL, + IHTMLOptionElementFactory_tid, + NULL, + HTMLOptionElementFactory_iface_tids +}; + HRESULT HTMLOptionElementFactory_Create(HTMLInnerWindow *window, HTMLOptionElementFactory **ret_ptr) { HTMLOptionElementFactory *ret; @@ -507,6 +514,9 @@ HRESULT HTMLOptionElementFactory_Create(HTMLInnerWindow *window, HTMLOptionEleme ret->ref = 1; ret->window = window; + init_dispex(&ret->dispex, (IUnknown*)&ret->IHTMLOptionElementFactory_iface, + &HTMLOptionElementFactory_dispex); + *ret_ptr = ret; return S_OK; } diff --git a/dll/win32/mshtml/htmlscreen.c b/dll/win32/mshtml/htmlscreen.c index eef50a1ade6..ac0d774517b 100644 --- a/dll/win32/mshtml/htmlscreen.c +++ b/dll/win32/mshtml/htmlscreen.c @@ -34,25 +34,22 @@ static HRESULT WINAPI HTMLScreen_QueryInterface(IHTMLScreen *iface, REFIID riid, { HTMLScreen *This = impl_from_IHTMLScreen(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLScreen_iface; }else if(IsEqualGUID(&IID_IHTMLScreen, riid)) { - TRACE("(%p)->(IID_IHTMLScreen %p)\n", This, ppv); *ppv = &This->IHTMLScreen_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLScreen_AddRef(IHTMLScreen *iface) @@ -83,24 +80,22 @@ static ULONG WINAPI HTMLScreen_Release(IHTMLScreen *iface) static HRESULT WINAPI HTMLScreen_GetTypeInfoCount(IHTMLScreen *iface, UINT *pctinfo) { HTMLScreen *This = impl_from_IHTMLScreen(iface); - FIXME("(%p)\n", This); - return E_NOTIMPL; + return IDispatchEx_GetTypeInfoCount(&This->dispex.IDispatchEx_iface, pctinfo); } static HRESULT WINAPI HTMLScreen_GetTypeInfo(IHTMLScreen *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo) { HTMLScreen *This = impl_from_IHTMLScreen(iface); - FIXME("(%p)\n", This); - return E_NOTIMPL; + return IDispatchEx_GetTypeInfo(&This->dispex.IDispatchEx_iface, iTInfo, lcid, ppTInfo); } static HRESULT WINAPI HTMLScreen_GetIDsOfNames(IHTMLScreen *iface, REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId) { HTMLScreen *This = impl_from_IHTMLScreen(iface); - FIXME("(%p)\n", This); - return E_NOTIMPL; + return IDispatchEx_GetIDsOfNames(&This->dispex.IDispatchEx_iface, riid, rgszNames, cNames, + lcid, rgDispId); } static HRESULT WINAPI HTMLScreen_Invoke(IHTMLScreen *iface, DISPID dispIdMember, @@ -108,8 +103,8 @@ static HRESULT WINAPI HTMLScreen_Invoke(IHTMLScreen *iface, DISPID dispIdMember, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr) { HTMLScreen *This = impl_from_IHTMLScreen(iface); - FIXME("(%p)\n", This); - return E_NOTIMPL; + return IDispatchEx_Invoke(&This->dispex.IDispatchEx_iface, dispIdMember, riid, lcid, wFlags, + pDispParams, pVarResult, pExcepInfo, puArgErr); } static HRESULT WINAPI HTMLScreen_get_colorDepth(IHTMLScreen *iface, LONG *p) diff --git a/dll/win32/mshtml/htmlscript.h b/dll/win32/mshtml/htmlscript.h index 8a0c1e56a87..a9b477f1c3d 100644 --- a/dll/win32/mshtml/htmlscript.h +++ b/dll/win32/mshtml/htmlscript.h @@ -16,6 +16,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#pragma once + typedef struct { HTMLElement element; diff --git a/dll/win32/mshtml/htmlselect.c b/dll/win32/mshtml/htmlselect.c index 3acc2f78890..f27a6616872 100644 --- a/dll/win32/mshtml/htmlselect.c +++ b/dll/win32/mshtml/htmlselect.c @@ -392,8 +392,14 @@ static HRESULT WINAPI HTMLSelectElement_add(IHTMLSelectElement *iface, IHTMLElem static HRESULT WINAPI HTMLSelectElement_remove(IHTMLSelectElement *iface, LONG index) { HTMLSelectElement *This = impl_from_IHTMLSelectElement(iface); - FIXME("(%p)->(%d)\n", This, index); - return E_NOTIMPL; + nsresult nsres; + TRACE("(%p)->(%d)\n", This, index); + nsres = nsIDOMHTMLSelectElement_select_Remove(This->nsselect, index); + if(NS_FAILED(nsres)) { + ERR("Remove failed: %08x\n", nsres); + return E_FAIL; + } + return S_OK; } static HRESULT WINAPI HTMLSelectElement_put_length(IHTMLSelectElement *iface, LONG v) diff --git a/dll/win32/mshtml/htmlstorage.c b/dll/win32/mshtml/htmlstorage.c index d6b11c127b1..eeefdffda20 100644 --- a/dll/win32/mshtml/htmlstorage.c +++ b/dll/win32/mshtml/htmlstorage.c @@ -33,25 +33,22 @@ static HRESULT WINAPI HTMLStorage_QueryInterface(IHTMLStorage *iface, REFIID rii { HTMLStorage *This = impl_from_IHTMLStorage(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLStorage_iface; }else if(IsEqualGUID(&IID_IHTMLStorage, riid)) { - TRACE("(%p)->(IID_IHTMLStorage %p)\n", This, ppv); *ppv = &This->IHTMLStorage_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLStorage_AddRef(IHTMLStorage *iface) diff --git a/dll/win32/mshtml/htmlstyle.c b/dll/win32/mshtml/htmlstyle.c index c838a42107a..28beb51550d 100644 --- a/dll/win32/mshtml/htmlstyle.c +++ b/dll/win32/mshtml/htmlstyle.c @@ -20,6 +20,8 @@ static const WCHAR attrBackground[] = {'b','a','c','k','g','r','o','u','n','d',0}; +static const WCHAR attrBackgroundAttachment[] = + {'b','a','c','k','g','r','o','u','n','d','-','a','t','t','a','c','h','m','e','n','t',0}; static const WCHAR attrBackgroundColor[] = {'b','a','c','k','g','r','o','u','n','d','-','c','o','l','o','r',0}; static const WCHAR attrBackgroundImage[] = @@ -109,8 +111,12 @@ static const WCHAR attrLetterSpacing[] = {'l','e','t','t','e','r','-','s','p','a','c','i','n','g',0}; static const WCHAR attrLineHeight[] = {'l','i','n','e','-','h','e','i','g','h','t',0}; +static const WCHAR attrListStyle[] = + {'l','i','s','t','-','s','t','y','l','e',0}; static const WCHAR attrListStyleType[] = {'l','i','s','t','-','s','t','y','l','e','-','t','y','p','e',0}; +static const WCHAR attrListStylePosition[] = + {'l','i','s','t','-','s','t','y','l','e','-','p','o','s','i','t','i','o','n',0}; static const WCHAR attrMargin[] = {'m','a','r','g','i','n',0}; static const WCHAR attrMarginBottom[] = @@ -123,6 +129,8 @@ static const WCHAR attrMarginTop[] = {'m','a','r','g','i','n','-','t','o','p',0}; static const WCHAR attrMinHeight[] = {'m','i','n','-','h','e','i','g','h','t',0}; +static const WCHAR attrMinWidth[] = + {'m','i','n','-','w','i','d','t','h',0}; static const WCHAR attrOutline[] = {'o','u','t','l','i','n','e',0}; static const WCHAR attrOverflow[] = @@ -149,12 +157,16 @@ static const WCHAR attrPosition[] = {'p','o','s','i','t','i','o','n',0}; static const WCHAR attrRight[] = {'r','i','g','h','t',0}; +static const WCHAR attrTableLayout[] = + {'t','a','b','l','e','-','l','a','y','o','u','t',0}; static const WCHAR attrTextAlign[] = {'t','e','x','t','-','a','l','i','g','n',0}; static const WCHAR attrTextDecoration[] = {'t','e','x','t','-','d','e','c','o','r','a','t','i','o','n',0}; static const WCHAR attrTextIndent[] = {'t','e','x','t','-','i','n','d','e','n','t',0}; +static const WCHAR attrTextTransform[] = + {'t','e','x','t','-','t','r','a','n','s','f','o','r','m',0}; static const WCHAR attrTop[] = {'t','o','p',0}; static const WCHAR attrVerticalAlign[] = @@ -182,6 +194,7 @@ typedef struct { static const style_tbl_entry_t style_tbl[] = { {attrBackground, DISPID_IHTMLSTYLE_BACKGROUND}, + {attrBackgroundAttachment, DISPID_IHTMLSTYLE_BACKGROUNDATTACHMENT}, {attrBackgroundColor, DISPID_IHTMLSTYLE_BACKGROUNDCOLOR}, {attrBackgroundImage, DISPID_IHTMLSTYLE_BACKGROUNDIMAGE}, {attrBackgroundPosition, DISPID_IHTMLSTYLE_BACKGROUNDPOSITION}, @@ -226,6 +239,8 @@ static const style_tbl_entry_t style_tbl[] = { {attrLeft, DISPID_IHTMLSTYLE_LEFT}, {attrLetterSpacing, DISPID_IHTMLSTYLE_LETTERSPACING}, {attrLineHeight, DISPID_IHTMLSTYLE_LINEHEIGHT}, + {attrListStyle, DISPID_IHTMLSTYLE_LISTSTYLE}, + {attrListStylePosition, DISPID_IHTMLSTYLE_LISTSTYLEPOSITION}, {attrListStyleType, DISPID_IHTMLSTYLE_LISTSTYLETYPE}, {attrMargin, DISPID_IHTMLSTYLE_MARGIN}, {attrMarginBottom, DISPID_IHTMLSTYLE_MARGINBOTTOM}, @@ -233,6 +248,7 @@ static const style_tbl_entry_t style_tbl[] = { {attrMarginRight, DISPID_IHTMLSTYLE_MARGINRIGHT}, {attrMarginTop, DISPID_IHTMLSTYLE_MARGINTOP}, {attrMinHeight, DISPID_IHTMLSTYLE4_MINHEIGHT}, + {attrMinWidth, DISPID_IHTMLSTYLE5_MINWIDTH}, {attrOutline, DISPID_IHTMLSTYLE6_OUTLINE}, {attrOverflow, DISPID_IHTMLSTYLE_OVERFLOW}, {attrOverflowX, DISPID_IHTMLSTYLE2_OVERFLOWX}, @@ -246,9 +262,11 @@ static const style_tbl_entry_t style_tbl[] = { {attrPageBreakBefore, DISPID_IHTMLSTYLE_PAGEBREAKBEFORE}, {attrPosition, DISPID_IHTMLSTYLE2_POSITION}, {attrRight, DISPID_IHTMLSTYLE2_RIGHT}, + {attrTableLayout, DISPID_IHTMLSTYLE2_TABLELAYOUT}, {attrTextAlign, DISPID_IHTMLSTYLE_TEXTALIGN}, {attrTextDecoration, DISPID_IHTMLSTYLE_TEXTDECORATION}, {attrTextIndent, DISPID_IHTMLSTYLE_TEXTINDENT}, + {attrTextTransform, DISPID_IHTMLSTYLE_TEXTTRANSFORM}, {attrTop, DISPID_IHTMLSTYLE_TOP}, {attrVerticalAlign, DISPID_IHTMLSTYLE_VERTICALALIGN}, {attrVisibility, DISPID_IHTMLSTYLE_VISIBILITY}, @@ -649,6 +667,9 @@ static HRESULT get_nsstyle_pixel_val(HTMLStyle *This, styleid_t sid, LONG *p) nsAString str_value; HRESULT hres; + if(!p) + return E_POINTER; + nsAString_Init(&str_value, NULL); hres = get_nsstyle_attr_nsval(This->nsstyle, sid, &str_value); @@ -713,40 +734,32 @@ static HRESULT WINAPI HTMLStyle_QueryInterface(IHTMLStyle *iface, REFIID riid, v { HTMLStyle *This = impl_from_IHTMLStyle(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLStyle_iface; }else if(IsEqualGUID(&IID_IHTMLStyle, riid)) { - TRACE("(%p)->(IID_IHTMLStyle %p)\n", This, ppv); *ppv = &This->IHTMLStyle_iface; }else if(IsEqualGUID(&IID_IHTMLStyle2, riid)) { - TRACE("(%p)->(IID_IHTMLStyle2 %p)\n", This, ppv); *ppv = &This->IHTMLStyle2_iface; }else if(IsEqualGUID(&IID_IHTMLStyle3, riid)) { - TRACE("(%p)->(IID_IHTMLStyle3 %p)\n", This, ppv); *ppv = &This->IHTMLStyle3_iface; }else if(IsEqualGUID(&IID_IHTMLStyle4, riid)) { - TRACE("(%p)->(IID_IHTMLStyle4 %p)\n", This, ppv); *ppv = &This->IHTMLStyle4_iface; }else if(IsEqualGUID(&IID_IHTMLStyle5, riid)) { - TRACE("(%p)->(IID_IHTMLStyle5 %p)\n", This, ppv); *ppv = &This->IHTMLStyle5_iface; }else if(IsEqualGUID(&IID_IHTMLStyle6, riid)) { - TRACE("(%p)->(IID_IHTMLStyle6 %p)\n", This, ppv); *ppv = &This->IHTMLStyle6_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("unsupported iface %s\n", debugstr_mshtml_guid(riid)); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("unsupported %s\n", debugstr_guid(riid)); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLStyle_AddRef(IHTMLStyle *iface) @@ -1059,15 +1072,19 @@ static HRESULT WINAPI HTMLStyle_get_backgroundRepeat(IHTMLStyle *iface, BSTR *p) static HRESULT WINAPI HTMLStyle_put_backgroundAttachment(IHTMLStyle *iface, BSTR v) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + return set_style_attr(This, STYLEID_BACKGROUND_ATTACHMENT, v, 0); } static HRESULT WINAPI HTMLStyle_get_backgroundAttachment(IHTMLStyle *iface, BSTR *p) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_style_attr(This, STYLEID_BACKGROUND_ATTACHMENT, p); } static HRESULT WINAPI HTMLStyle_put_backgroundPosition(IHTMLStyle *iface, BSTR v) @@ -1441,15 +1458,19 @@ static HRESULT WINAPI HTMLStyle_get_verticalAlign(IHTMLStyle *iface, VARIANT *p) static HRESULT WINAPI HTMLStyle_put_textTransform(IHTMLStyle *iface, BSTR v) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + return set_style_attr(This, STYLEID_TEXT_TRANSFORM, v, 0); } static HRESULT WINAPI HTMLStyle_get_textTransform(IHTMLStyle *iface, BSTR *p) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_style_attr(This, STYLEID_TEXT_TRANSFORM, p); } static HRESULT WINAPI HTMLStyle_put_textAlign(IHTMLStyle *iface, BSTR v) @@ -1473,29 +1494,37 @@ static HRESULT WINAPI HTMLStyle_get_textAlign(IHTMLStyle *iface, BSTR *p) static HRESULT WINAPI HTMLStyle_put_textIndent(IHTMLStyle *iface, VARIANT v) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(%s)\n", This, debugstr_variant(&v)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + + return set_nsstyle_attr_var(This->nsstyle, STYLEID_TEXT_INDENT, &v, ATTR_FIX_PX); } static HRESULT WINAPI HTMLStyle_get_textIndent(IHTMLStyle *iface, VARIANT *p) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_nsstyle_attr_var(This->nsstyle, STYLEID_TEXT_INDENT, p, 0); } static HRESULT WINAPI HTMLStyle_put_lineHeight(IHTMLStyle *iface, VARIANT v) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(%s)\n", This, debugstr_variant(&v)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + + return set_nsstyle_attr_var(This->nsstyle, STYLEID_LINE_HEIGHT, &v, 0); } static HRESULT WINAPI HTMLStyle_get_lineHeight(IHTMLStyle *iface, VARIANT *p) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_nsstyle_attr_var(This->nsstyle, STYLEID_LINE_HEIGHT, p, 0); } static HRESULT WINAPI HTMLStyle_put_marginTop(IHTMLStyle *iface, VARIANT v) @@ -2172,15 +2201,19 @@ static HRESULT WINAPI HTMLStyle_get_listStyleType(IHTMLStyle *iface, BSTR *p) static HRESULT WINAPI HTMLStyle_put_listStylePosition(IHTMLStyle *iface, BSTR v) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + return set_style_attr(This, STYLEID_LISTSTYLEPOSITION, v, 0); } static HRESULT WINAPI HTMLStyle_get_listStylePosition(IHTMLStyle *iface, BSTR *p) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_style_attr(This, STYLEID_LISTSTYLEPOSITION, p); } static HRESULT WINAPI HTMLStyle_put_listStyleImage(IHTMLStyle *iface, BSTR v) @@ -2200,15 +2233,19 @@ static HRESULT WINAPI HTMLStyle_get_listStyleImage(IHTMLStyle *iface, BSTR *p) static HRESULT WINAPI HTMLStyle_put_listStyle(IHTMLStyle *iface, BSTR v) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + return set_style_attr(This, STYLEID_LIST_STYLE, v, 0); } static HRESULT WINAPI HTMLStyle_get_listStyle(IHTMLStyle *iface, BSTR *p) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_style_attr(This, STYLEID_LIST_STYLE, p); } static HRESULT WINAPI HTMLStyle_put_whiteSpace(IHTMLStyle *iface, BSTR v) @@ -2406,15 +2443,19 @@ static HRESULT WINAPI HTMLStyle_get_cssText(IHTMLStyle *iface, BSTR *p) static HRESULT WINAPI HTMLStyle_put_pixelTop(IHTMLStyle *iface, LONG v) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; + + TRACE("(%p)->(%d)\n", This, v); + + return set_style_pxattr(This->nsstyle, STYLEID_TOP, v); } static HRESULT WINAPI HTMLStyle_get_pixelTop(IHTMLStyle *iface, LONG *p) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_nsstyle_pixel_val(This, STYLEID_TOP, p); } static HRESULT WINAPI HTMLStyle_put_pixelLeft(IHTMLStyle *iface, LONG v) @@ -2447,22 +2488,28 @@ static HRESULT WINAPI HTMLStyle_put_pixelWidth(IHTMLStyle *iface, LONG v) static HRESULT WINAPI HTMLStyle_get_pixelWidth(IHTMLStyle *iface, LONG *p) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_nsstyle_pixel_val(This, STYLEID_WIDTH, p); } static HRESULT WINAPI HTMLStyle_put_pixelHeight(IHTMLStyle *iface, LONG v) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; + + TRACE("(%p)->(%d)\n", This, v); + + return set_style_pxattr(This->nsstyle, STYLEID_HEIGHT, v); } static HRESULT WINAPI HTMLStyle_get_pixelHeight(IHTMLStyle *iface, LONG *p) { HTMLStyle *This = impl_from_IHTMLStyle(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_nsstyle_pixel_val(This, STYLEID_HEIGHT, p); } static HRESULT WINAPI HTMLStyle_put_posTop(IHTMLStyle *iface, float v) diff --git a/dll/win32/mshtml/htmlstyle.h b/dll/win32/mshtml/htmlstyle.h index 030d8a1026c..a15dd234bb8 100644 --- a/dll/win32/mshtml/htmlstyle.h +++ b/dll/win32/mshtml/htmlstyle.h @@ -16,6 +16,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#pragma once + struct HTMLStyle { DispatchEx dispex; IHTMLStyle IHTMLStyle_iface; @@ -34,6 +36,7 @@ struct HTMLStyle { /* NOTE: Make sure to keep in sync with style_tbl in htmlstyle.c */ typedef enum { STYLEID_BACKGROUND, + STYLEID_BACKGROUND_ATTACHMENT, STYLEID_BACKGROUND_COLOR, STYLEID_BACKGROUND_IMAGE, STYLEID_BACKGROUND_POSITION, @@ -78,6 +81,8 @@ typedef enum { STYLEID_LEFT, STYLEID_LETTER_SPACING, STYLEID_LINE_HEIGHT, + STYLEID_LIST_STYLE, + STYLEID_LISTSTYLEPOSITION, STYLEID_LISTSTYLETYPE, STYLEID_MARGIN, STYLEID_MARGIN_BOTTOM, @@ -85,6 +90,7 @@ typedef enum { STYLEID_MARGIN_RIGHT, STYLEID_MARGIN_TOP, STYLEID_MIN_HEIGHT, + STYLEID_MIN_WIDTH, STYLEID_OUTLINE, STYLEID_OVERFLOW, STYLEID_OVERFLOW_X, @@ -98,9 +104,11 @@ typedef enum { STYLEID_PAGE_BREAK_BEFORE, STYLEID_POSITION, STYLEID_RIGHT, + STYLEID_TABLE_LAYOUT, STYLEID_TEXT_ALIGN, STYLEID_TEXT_DECORATION, STYLEID_TEXT_INDENT, + STYLEID_TEXT_TRANSFORM, STYLEID_TOP, STYLEID_VERTICAL_ALIGN, STYLEID_VISIBILITY, diff --git a/dll/win32/mshtml/htmlstyle2.c b/dll/win32/mshtml/htmlstyle2.c index 17b09c8f852..5b685a288a6 100644 --- a/dll/win32/mshtml/htmlstyle2.c +++ b/dll/win32/mshtml/htmlstyle2.c @@ -78,15 +78,19 @@ static HRESULT WINAPI HTMLStyle2_Invoke(IHTMLStyle2 *iface, DISPID dispIdMember, static HRESULT WINAPI HTMLStyle2_put_tableLayout(IHTMLStyle2 *iface, BSTR v) { HTMLStyle *This = impl_from_IHTMLStyle2(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + return set_nsstyle_attr(This->nsstyle, STYLEID_TABLE_LAYOUT, v, 0); } static HRESULT WINAPI HTMLStyle2_get_tableLayout(IHTMLStyle2 *iface, BSTR *p) { HTMLStyle *This = impl_from_IHTMLStyle2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_nsstyle_attr(This->nsstyle, STYLEID_TABLE_LAYOUT, p, 0); } static HRESULT WINAPI HTMLStyle2_put_borderCollapse(IHTMLStyle2 *iface, BSTR v) diff --git a/dll/win32/mshtml/htmlstyle3.c b/dll/win32/mshtml/htmlstyle3.c index 7e6bbc6a616..743c09a7a5b 100644 --- a/dll/win32/mshtml/htmlstyle3.c +++ b/dll/win32/mshtml/htmlstyle3.c @@ -530,15 +530,19 @@ static HRESULT WINAPI HTMLStyle5_get_maxHeight(IHTMLStyle5 *iface, VARIANT *p) static HRESULT WINAPI HTMLStyle5_put_minWidth(IHTMLStyle5 *iface, VARIANT v) { HTMLStyle *This = impl_from_IHTMLStyle5(iface); - FIXME("(%p)->(%s)\n", This, debugstr_variant(&v)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + + return set_nsstyle_attr_var(This->nsstyle, STYLEID_MIN_WIDTH, &v, ATTR_FIX_PX); } static HRESULT WINAPI HTMLStyle5_get_minWidth(IHTMLStyle5 *iface, VARIANT *p) { HTMLStyle *This = impl_from_IHTMLStyle5(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_nsstyle_attr_var(This->nsstyle, STYLEID_MIN_WIDTH, p, 0); } static HRESULT WINAPI HTMLStyle5_put_maxWidth(IHTMLStyle5 *iface, VARIANT v) diff --git a/dll/win32/mshtml/htmlstylesheet.c b/dll/win32/mshtml/htmlstylesheet.c index 526168ff462..e978732586f 100644 --- a/dll/win32/mshtml/htmlstylesheet.c +++ b/dll/win32/mshtml/htmlstylesheet.c @@ -37,6 +37,7 @@ struct HTMLStyleSheetsCollection { }; struct HTMLStyleSheetRulesCollection { + DispatchEx dispex; IHTMLStyleSheetRulesCollection IHTMLStyleSheetRulesCollection_iface; LONG ref; @@ -54,21 +55,22 @@ static HRESULT WINAPI HTMLStyleSheetRulesCollection_QueryInterface(IHTMLStyleShe { HTMLStyleSheetRulesCollection *This = impl_from_IHTMLStyleSheetRulesCollection(iface); + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLStyleSheetRulesCollection_iface; }else if(IsEqualGUID(&IID_IHTMLStyleSheetRulesCollection, riid)) { - TRACE("(%p)->(IID_IHTMLStyleSheetRulesCollection %p)\n", This, ppv); *ppv = &This->IHTMLStyleSheetRulesCollection_iface; + }else if(dispex_query_interface(&This->dispex, riid, ppv)) { + return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + FIXME("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - FIXME("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLStyleSheetRulesCollection_AddRef(IHTMLStyleSheetRulesCollection *iface) @@ -89,6 +91,7 @@ static ULONG WINAPI HTMLStyleSheetRulesCollection_Release(IHTMLStyleSheetRulesCo TRACE("(%p) ref=%d\n", This, ref); if(!ref) { + release_dispex(&This->dispex); if(This->nslist) nsIDOMCSSRuleList_Release(This->nslist); heap_free(This); @@ -101,25 +104,22 @@ static HRESULT WINAPI HTMLStyleSheetRulesCollection_GetTypeInfoCount( IHTMLStyleSheetRulesCollection *iface, UINT *pctinfo) { HTMLStyleSheetRulesCollection *This = impl_from_IHTMLStyleSheetRulesCollection(iface); - FIXME("(%p)->(%p)\n", This, pctinfo); - return E_NOTIMPL; + return IDispatchEx_GetTypeInfoCount(&This->dispex.IDispatchEx_iface, pctinfo); } static HRESULT WINAPI HTMLStyleSheetRulesCollection_GetTypeInfo(IHTMLStyleSheetRulesCollection *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo) { HTMLStyleSheetRulesCollection *This = impl_from_IHTMLStyleSheetRulesCollection(iface); - FIXME("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo); - return E_NOTIMPL; + return IDispatchEx_GetTypeInfo(&This->dispex.IDispatchEx_iface, iTInfo, lcid, ppTInfo); } static HRESULT WINAPI HTMLStyleSheetRulesCollection_GetIDsOfNames(IHTMLStyleSheetRulesCollection *iface, REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId) { HTMLStyleSheetRulesCollection *This = impl_from_IHTMLStyleSheetRulesCollection(iface); - FIXME("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, - lcid, rgDispId); - return E_NOTIMPL; + return IDispatchEx_GetIDsOfNames(&This->dispex.IDispatchEx_iface, riid, rgszNames, cNames, + lcid, rgDispId); } static HRESULT WINAPI HTMLStyleSheetRulesCollection_Invoke(IHTMLStyleSheetRulesCollection *iface, @@ -127,9 +127,8 @@ static HRESULT WINAPI HTMLStyleSheetRulesCollection_Invoke(IHTMLStyleSheetRulesC VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr) { HTMLStyleSheetRulesCollection *This = impl_from_IHTMLStyleSheetRulesCollection(iface); - FIXME("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid), - lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); - return E_NOTIMPL; + return IDispatchEx_Invoke(&This->dispex.IDispatchEx_iface, dispIdMember, riid, lcid, wFlags, + pDispParams, pVarResult, pExcepInfo, puArgErr); } static HRESULT WINAPI HTMLStyleSheetRulesCollection_get_length(IHTMLStyleSheetRulesCollection *iface, @@ -172,6 +171,17 @@ static const IHTMLStyleSheetRulesCollectionVtbl HTMLStyleSheetRulesCollectionVtb HTMLStyleSheetRulesCollection_item }; +static const tid_t HTMLStyleSheetRulesCollection_iface_tids[] = { + IHTMLStyleSheetRulesCollection_tid, + 0 +}; +static dispex_static_data_t HTMLStyleSheetRulesCollection_dispex = { + NULL, + DispHTMLStyleSheetRulesCollection_tid, + NULL, + HTMLStyleSheetRulesCollection_iface_tids +}; + static IHTMLStyleSheetRulesCollection *HTMLStyleSheetRulesCollection_Create(nsIDOMCSSRuleList *nslist) { HTMLStyleSheetRulesCollection *ret; @@ -181,6 +191,8 @@ static IHTMLStyleSheetRulesCollection *HTMLStyleSheetRulesCollection_Create(nsID ret->ref = 1; ret->nslist = nslist; + init_dispex(&ret->dispex, (IUnknown*)&ret->IHTMLStyleSheetRulesCollection_iface, &HTMLStyleSheetRulesCollection_dispex); + if(nslist) nsIDOMCSSRuleList_AddRef(nslist); @@ -197,28 +209,24 @@ static HRESULT WINAPI HTMLStyleSheetsCollection_QueryInterface(IHTMLStyleSheetsC { HTMLStyleSheetsCollection *This = impl_from_IHTMLStyleSheetsCollection(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLStyleSheetsCollection_iface; }else if(IsEqualGUID(&IID_IDispatch, riid)) { - TRACE("(%p)->(IID_IDispatch %p)\n", This, ppv); *ppv = &This->IHTMLStyleSheetsCollection_iface; }else if(IsEqualGUID(&IID_IHTMLStyleSheetsCollection, riid)) { - TRACE("(%p)->(IID_IHTMLStyleSheetsCollection %p)\n", This, ppv); *ppv = &This->IHTMLStyleSheetsCollection_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("unsupported %s\n", debugstr_mshtml_guid(riid)); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("unsupported %s\n", debugstr_guid(riid)); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLStyleSheetsCollection_AddRef(IHTMLStyleSheetsCollection *iface) @@ -239,6 +247,7 @@ static ULONG WINAPI HTMLStyleSheetsCollection_Release(IHTMLStyleSheetsCollection TRACE("(%p) ref=%d\n", This, ref); if(!ref) { + release_dispex(&This->dispex); if(This->nslist) nsIDOMStyleSheetList_Release(This->nslist); heap_free(This); @@ -389,28 +398,24 @@ static HRESULT WINAPI HTMLStyleSheet_QueryInterface(IHTMLStyleSheet *iface, REFI { HTMLStyleSheet *This = impl_from_IHTMLStyleSheet(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLStyleSheet_iface; }else if(IsEqualGUID(&IID_IDispatch, riid)) { - TRACE("(%p)->(IID_IDispatch %p)\n", This, ppv); *ppv = &This->IHTMLStyleSheet_iface; }else if(IsEqualGUID(&IID_IHTMLStyleSheet, riid)) { - TRACE("(%p)->(IID_IHTMLStyleSheet %p)\n", This, ppv); *ppv = &This->IHTMLStyleSheet_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("unsupported %s\n", debugstr_mshtml_guid(riid)); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("unsupported %s\n", debugstr_guid(riid)); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLStyleSheet_AddRef(IHTMLStyleSheet *iface) @@ -430,8 +435,12 @@ static ULONG WINAPI HTMLStyleSheet_Release(IHTMLStyleSheet *iface) TRACE("(%p) ref=%d\n", This, ref); - if(!ref) + if(!ref) { + release_dispex(&This->dispex); + if(This->nsstylesheet) + nsIDOMCSSStyleSheet_Release(This->nsstylesheet); heap_free(This); + } return ref; } @@ -447,7 +456,6 @@ static HRESULT WINAPI HTMLStyleSheet_GetTypeInfo(IHTMLStyleSheet *iface, UINT iT LCID lcid, ITypeInfo **ppTInfo) { HTMLStyleSheet *This = impl_from_IHTMLStyleSheet(iface); - TRACE("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo); return IDispatchEx_GetTypeInfo(&This->dispex.IDispatchEx_iface, iTInfo, lcid, ppTInfo); } @@ -456,7 +464,6 @@ static HRESULT WINAPI HTMLStyleSheet_GetIDsOfNames(IHTMLStyleSheet *iface, REFII LCID lcid, DISPID *rgDispId) { HTMLStyleSheet *This = impl_from_IHTMLStyleSheet(iface); - TRACE("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId); return IDispatchEx_GetIDsOfNames(&This->dispex.IDispatchEx_iface, riid, rgszNames, cNames, lcid, rgDispId); } @@ -465,8 +472,6 @@ static HRESULT WINAPI HTMLStyleSheet_Invoke(IHTMLStyleSheet *iface, DISPID dispI VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr) { HTMLStyleSheet *This = impl_from_IHTMLStyleSheet(iface); - TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid), - lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); return IDispatchEx_Invoke(&This->dispex.IDispatchEx_iface, dispIdMember, riid, lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); } diff --git a/dll/win32/mshtml/htmltable.c b/dll/win32/mshtml/htmltable.c index a1eb77f8a70..ffe5a585eba 100644 --- a/dll/win32/mshtml/htmltable.c +++ b/dll/win32/mshtml/htmltable.c @@ -43,6 +43,57 @@ static inline HTMLTable *impl_from_IHTMLTable3(IHTMLTable3 *iface) return CONTAINING_RECORD(iface, HTMLTable, IHTMLTable3_iface); } +static HRESULT var2str(const VARIANT *p, nsAString *nsstr) +{ + BSTR str; + BOOL ret; + HRESULT hres; + + switch(V_VT(p)) { + case VT_BSTR: + return nsAString_Init(nsstr, V_BSTR(p))? + S_OK : E_OUTOFMEMORY; + case VT_R8: + hres = VarBstrFromR8(V_R8(p), 0, 0, &str); + break; + case VT_R4: + hres = VarBstrFromR4(V_R4(p), 0, 0, &str); + break; + case VT_I4: + hres = VarBstrFromI4(V_I4(p), 0, 0, &str); + break; + default: + FIXME("unsupported arg %s\n", debugstr_variant(p)); + return E_NOTIMPL; + } + if (FAILED(hres)) + return hres; + + ret = nsAString_Init(nsstr, str); + SysFreeString(str); + return ret ? S_OK : E_OUTOFMEMORY; +} + +static HRESULT nsstr_to_truncated_bstr(const nsAString *nsstr, BSTR *ret_ptr) +{ + const PRUnichar *str, *ptr, *end = NULL; + BSTR ret; + + nsAString_GetData(nsstr, &str); + + for(ptr = str; isdigitW(*ptr); ptr++); + if(*ptr == '.') { + for(end = ptr++; isdigitW(*ptr); ptr++); + if(*ptr) + end = NULL; + } + + ret = end ? SysAllocStringLen(str, end-str) : SysAllocString(str); + + *ret_ptr = ret; + return ret ? S_OK : E_OUTOFMEMORY; +} + static HRESULT WINAPI HTMLTable_QueryInterface(IHTMLTable *iface, REFIID riid, void **ppv) { @@ -128,15 +179,34 @@ static HRESULT WINAPI HTMLTable_get_border(IHTMLTable *iface, VARIANT *p) static HRESULT WINAPI HTMLTable_put_frame(IHTMLTable *iface, BSTR v) { HTMLTable *This = impl_from_IHTMLTable(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + nsAString str; + nsresult nsres; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + nsAString_InitDepend(&str, v); + nsres = nsIDOMHTMLTableElement_SetFrame(This->nstable, &str); + nsAString_Finish(&str); + + if (NS_FAILED(nsres)) { + ERR("SetFrame(%s) failed: %08x\n", debugstr_w(v), nsres); + return E_FAIL; + } + return S_OK; } static HRESULT WINAPI HTMLTable_get_frame(IHTMLTable *iface, BSTR *p) { HTMLTable *This = impl_from_IHTMLTable(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsAString str; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsAString_Init(&str, NULL); + nsres = nsIDOMHTMLTableElement_GetFrame(This->nstable, &str); + + return return_nsstr(nsres, &str, p); } static HRESULT WINAPI HTMLTable_put_rules(IHTMLTable *iface, BSTR v) @@ -237,11 +307,11 @@ static HRESULT WINAPI HTMLTable_put_bgColor(IHTMLTable *iface, VARIANT v) TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); - nsAString_InitDepend(&val, V_BSTR(&v)); - variant_to_nscolor(&v, &val); + if(!variant_to_nscolor(&v, &val)) + return S_OK; + nsres = nsIDOMHTMLTableElement_SetBgColor(This->nstable, &val); nsAString_Finish(&val); - if (NS_FAILED(nsres)){ ERR("Set BgColor(%s) failed!\n", debugstr_variant(&v)); return E_FAIL; @@ -381,15 +451,52 @@ static HRESULT WINAPI HTMLTable_get_rows(IHTMLTable *iface, IHTMLElementCollecti static HRESULT WINAPI HTMLTable_put_width(IHTMLTable *iface, VARIANT v) { HTMLTable *This = impl_from_IHTMLTable(iface); - FIXME("(%p)->(%s)\n", This, debugstr_variant(&v)); - return E_NOTIMPL; + nsAString val; + HRESULT hres; + nsresult nsres; + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + hres = var2str(&v, &val); + + if (FAILED(hres)){ + ERR("Set Width(%s) failed when initializing a nsAString, err = %08x\n", + debugstr_variant(&v), hres); + return hres; + } + + nsres = nsIDOMHTMLTableElement_SetWidth(This->nstable, &val); + nsAString_Finish(&val); + + if (NS_FAILED(nsres)){ + ERR("Set Width(%s) failed, err = %08x\n", debugstr_variant(&v), nsres); + return E_FAIL; + } + return S_OK; } static HRESULT WINAPI HTMLTable_get_width(IHTMLTable *iface, VARIANT *p) { HTMLTable *This = impl_from_IHTMLTable(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsAString val; + BSTR bstr; + nsresult nsres; + HRESULT hres; + + TRACE("(%p)->(%p)\n", This, p); + nsAString_Init(&val, NULL); + nsres = nsIDOMHTMLTableElement_GetWidth(This->nstable, &val); + if (NS_FAILED(nsres)){ + ERR("Get Width failed!\n"); + nsAString_Finish(&val); + return E_FAIL; + } + + hres = nsstr_to_truncated_bstr(&val, &bstr); + nsAString_Finish(&val); + + V_VT(p) = VT_BSTR; + V_BSTR(p) = bstr; + return hres; } static HRESULT WINAPI HTMLTable_put_height(IHTMLTable *iface, VARIANT v) @@ -520,15 +627,41 @@ static HRESULT WINAPI HTMLTable_deleteCaption(IHTMLTable *iface) static HRESULT WINAPI HTMLTable_insertRow(IHTMLTable *iface, LONG index, IDispatch **row) { HTMLTable *This = impl_from_IHTMLTable(iface); - FIXME("(%p)->(%d %p)\n", This, index, row); - return E_NOTIMPL; + nsIDOMHTMLElement *nselem; + HTMLElement *elem; + nsresult nsres; + HRESULT hres; + + TRACE("(%p)->(%d %p)\n", This, index, row); + nsres = nsIDOMHTMLTableElement_InsertRow(This->nstable, index, &nselem); + if(NS_FAILED(nsres)) { + ERR("Insert Row at %d failed: %08x\n", index, nsres); + return E_FAIL; + } + + hres = HTMLTableRow_Create(This->element.node.doc, nselem, &elem); + nsIDOMHTMLElement_Release(nselem); + if (FAILED(hres)) { + ERR("Create TableRow failed: %08x\n", hres); + return hres; + } + + *row = (IDispatch *)&elem->IHTMLElement_iface; + return S_OK; } static HRESULT WINAPI HTMLTable_deleteRow(IHTMLTable *iface, LONG index) { HTMLTable *This = impl_from_IHTMLTable(iface); - FIXME("(%p)->(%d)\n", This, index); - return E_NOTIMPL; + nsresult nsres; + + TRACE("(%p)->(%d)\n", This, index); + nsres = nsIDOMHTMLTableElement_DeleteRow(This->nstable, index); + if(NS_FAILED(nsres)) { + ERR("Delete Row failed: %08x\n", nsres); + return E_FAIL; + } + return S_OK; } static HRESULT WINAPI HTMLTable_get_readyState(IHTMLTable *iface, BSTR *p) @@ -767,15 +900,35 @@ static HRESULT WINAPI HTMLTable3_Invoke(IHTMLTable3 *iface, DISPID dispIdMember, static HRESULT WINAPI HTMLTable3_put_summary(IHTMLTable3 *iface, BSTR v) { HTMLTable *This = impl_from_IHTMLTable3(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + nsAString str; + nsresult nsres; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + nsAString_InitDepend(&str, v); + + nsres = nsIDOMHTMLTableElement_SetSummary(This->nstable, &str); + + nsAString_Finish(&str); + if (NS_FAILED(nsres)) { + ERR("Set summary(%s) failed: %08x\n", debugstr_w(v), nsres); + return E_FAIL; + } + return S_OK; } static HRESULT WINAPI HTMLTable3_get_summary(IHTMLTable3 *iface, BSTR * p) { HTMLTable *This = impl_from_IHTMLTable3(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsAString str; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsAString_Init(&str, NULL); + nsres = nsIDOMHTMLTableElement_GetSummary(This->nstable, &str); + + return return_nsstr(nsres, &str, p); } static const IHTMLTable3Vtbl HTMLTable3Vtbl = { @@ -812,10 +965,10 @@ static HRESULT HTMLTable_QI(HTMLDOMNode *iface, REFIID riid, void **ppv) *ppv = &This->IHTMLTable_iface; }else if(IsEqualGUID(&IID_IHTMLTable2, riid)) { TRACE("(%p)->(IID_IHTMLTable2 %p)\n", This, ppv); - *ppv = &This->IHTMLTable_iface; + *ppv = &This->IHTMLTable2_iface; }else if(IsEqualGUID(&IID_IHTMLTable3, riid)) { TRACE("(%p)->(IID_IHTMLTable3 %p)\n", This, ppv); - *ppv = &This->IHTMLTable_iface; + *ppv = &This->IHTMLTable3_iface; } if(*ppv) { @@ -844,6 +997,8 @@ static const NodeImplVtbl HTMLTableImplVtbl = { static const tid_t HTMLTable_iface_tids[] = { HTMLELEMENT_TIDS, IHTMLTable_tid, + IHTMLTable2_tid, + IHTMLTable3_tid, 0 }; @@ -865,6 +1020,8 @@ HRESULT HTMLTable_Create(HTMLDocumentNode *doc, nsIDOMHTMLElement *nselem, HTMLE ret->element.node.vtbl = &HTMLTableImplVtbl; ret->IHTMLTable_iface.lpVtbl = &HTMLTableVtbl; + ret->IHTMLTable2_iface.lpVtbl = &HTMLTable2Vtbl; + ret->IHTMLTable3_iface.lpVtbl = &HTMLTable3Vtbl; HTMLElement_Init(&ret->element, doc, nselem, &HTMLTable_dispex); diff --git a/dll/win32/mshtml/htmltablecell.c b/dll/win32/mshtml/htmltablecell.c index e18a99cdf7e..b8b81c5d902 100644 --- a/dll/win32/mshtml/htmltablecell.c +++ b/dll/win32/mshtml/htmltablecell.c @@ -22,6 +22,8 @@ typedef struct { HTMLElement element; IHTMLTableCell IHTMLTableCell_iface; + + nsIDOMHTMLTableCellElement *nscell; } HTMLTableCell; static inline HTMLTableCell *impl_from_IHTMLTableCell(IHTMLTableCell *iface) @@ -112,15 +114,33 @@ static HRESULT WINAPI HTMLTableCell_get_colSpan(IHTMLTableCell *iface, LONG *p) static HRESULT WINAPI HTMLTableCell_put_align(IHTMLTableCell *iface, BSTR v) { HTMLTableCell *This = impl_from_IHTMLTableCell(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + nsAString str; + nsresult nsres; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + nsAString_InitDepend(&str, v); + nsres = nsIDOMHTMLTableCellElement_SetAlign(This->nscell, &str); + nsAString_Finish(&str); + if (NS_FAILED(nsres)) { + ERR("Set Align failed: %08x\n", nsres); + return E_FAIL; + } + return S_OK; } static HRESULT WINAPI HTMLTableCell_get_align(IHTMLTableCell *iface, BSTR *p) { HTMLTableCell *This = impl_from_IHTMLTableCell(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsAString str; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsAString_Init(&str, NULL); + nsres = nsIDOMHTMLTableCellElement_GetAlign(This->nscell, &str); + + return return_nsstr(nsres, &str, p); } static HRESULT WINAPI HTMLTableCell_put_vAlign(IHTMLTableCell *iface, BSTR v) @@ -140,15 +160,47 @@ static HRESULT WINAPI HTMLTableCell_get_vAlign(IHTMLTableCell *iface, BSTR *p) static HRESULT WINAPI HTMLTableCell_put_bgColor(IHTMLTableCell *iface, VARIANT v) { HTMLTableCell *This = impl_from_IHTMLTableCell(iface); - FIXME("(%p)->(%s)\n", This, debugstr_variant(&v)); - return E_NOTIMPL; + nsAString strColor; + nsresult nsres; + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + + if(!variant_to_nscolor(&v, &strColor)) + return S_OK; + + nsres = nsIDOMHTMLTableCellElement_SetBgColor(This->nscell, &strColor); + nsAString_Finish(&strColor); + if(NS_FAILED(nsres)) { + ERR("SetBgColor(%s) failed: %08x\n", debugstr_variant(&v), nsres); + return E_FAIL; + } + + return S_OK; } static HRESULT WINAPI HTMLTableCell_get_bgColor(IHTMLTableCell *iface, VARIANT *p) { HTMLTableCell *This = impl_from_IHTMLTableCell(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsAString strColor; + nsresult nsres; + HRESULT hres; + + TRACE("(%p)->(%p)\n", This, p); + + nsAString_Init(&strColor, NULL); + nsres = nsIDOMHTMLTableCellElement_GetBgColor(This->nscell, &strColor); + + if(NS_SUCCEEDED(nsres)) { + const PRUnichar *color; + nsAString_GetData(&strColor, &color); + V_VT(p) = VT_BSTR; + hres = nscolor_to_str(color, &V_BSTR(p)); + }else { + ERR("GetBgColor failed: %08x\n", nsres); + hres = E_FAIL; + } + nsAString_Finish(&strColor); + return hres; } static HRESULT WINAPI HTMLTableCell_put_noWrap(IHTMLTableCell *iface, VARIANT_BOOL v) @@ -252,8 +304,16 @@ static HRESULT WINAPI HTMLTableCell_get_height(IHTMLTableCell *iface, VARIANT *p static HRESULT WINAPI HTMLTableCell_get_cellIndex(IHTMLTableCell *iface, LONG *p) { HTMLTableCell *This = impl_from_IHTMLTableCell(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + nsres = nsIDOMHTMLTableCellElement_GetCellIndex(This->nscell, p); + if (NS_FAILED(nsres)) { + ERR("Get CellIndex failed: %08x\n", nsres); + return E_FAIL; + } + + return S_OK; } static const IHTMLTableCellVtbl HTMLTableCellVtbl = { @@ -349,6 +409,7 @@ static dispex_static_data_t HTMLTableCell_dispex = { HRESULT HTMLTableCell_Create(HTMLDocumentNode *doc, nsIDOMHTMLElement *nselem, HTMLElement **elem) { HTMLTableCell *ret; + nsresult nsres; ret = heap_alloc_zero(sizeof(*ret)); if(!ret) @@ -359,6 +420,12 @@ HRESULT HTMLTableCell_Create(HTMLDocumentNode *doc, nsIDOMHTMLElement *nselem, H HTMLElement_Init(&ret->element, doc, nselem, &HTMLTableCell_dispex); + nsres = nsIDOMHTMLElement_QueryInterface(nselem, &IID_nsIDOMHTMLTableCellElement, (void**)&ret->nscell); + + /* Share nscell reference with nsnode */ + assert(nsres == NS_OK && (nsIDOMNode*)ret->nscell == ret->element.node.nsnode); + nsIDOMNode_Release(ret->element.node.nsnode); + *elem = &ret->element; return S_OK; } diff --git a/dll/win32/mshtml/htmltablerow.c b/dll/win32/mshtml/htmltablerow.c index 0d053fa9f69..c4aae4cb40b 100644 --- a/dll/win32/mshtml/htmltablerow.c +++ b/dll/win32/mshtml/htmltablerow.c @@ -161,8 +161,9 @@ static HRESULT WINAPI HTMLTableRow_put_bgColor(IHTMLTableRow *iface, VARIANT v) TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); - nsAString_InitDepend(&val, V_BSTR(&v)); - variant_to_nscolor(&v, &val); + if (!variant_to_nscolor(&v, &val)) + return S_OK; + nsres = nsIDOMHTMLTableRowElement_SetBgColor(This->nsrow, &val); nsAString_Finish(&val); @@ -293,15 +294,41 @@ static HRESULT WINAPI HTMLTableRow_get_cells(IHTMLTableRow *iface, IHTMLElementC static HRESULT WINAPI HTMLTableRow_insertCell(IHTMLTableRow *iface, LONG index, IDispatch **row) { HTMLTableRow *This = impl_from_IHTMLTableRow(iface); - FIXME("(%p)->(%d %p)\n", This, index, row); - return E_NOTIMPL; + nsIDOMHTMLElement *nselem; + HTMLElement *elem; + nsresult nsres; + HRESULT hres; + + TRACE("(%p)->(%d %p)\n", This, index, row); + nsres = nsIDOMHTMLTableRowElement_InsertCell(This->nsrow, index, &nselem); + if(NS_FAILED(nsres)) { + ERR("Insert Cell at %d failed: %08x\n", index, nsres); + return E_FAIL; + } + + hres = HTMLTableCell_Create(This->element.node.doc, nselem, &elem); + nsIDOMHTMLElement_Release(nselem); + if (FAILED(hres)) { + ERR("Create TableCell failed: %08x\n", hres); + return hres; + } + + *row = (IDispatch *)&elem->IHTMLElement_iface; + return S_OK; } static HRESULT WINAPI HTMLTableRow_deleteCell(IHTMLTableRow *iface, LONG index) { HTMLTableRow *This = impl_from_IHTMLTableRow(iface); - FIXME("(%p)->(%d)\n", This, index); - return E_NOTIMPL; + nsresult nsres; + + TRACE("(%p)->(%d)\n", This, index); + nsres = nsIDOMHTMLTableRowElement_DeleteCell(This->nsrow, index); + if(NS_FAILED(nsres)) { + ERR("Delete Cell failed: %08x\n", nsres); + return E_FAIL; + } + return S_OK; } static const IHTMLTableRowVtbl HTMLTableRowVtbl = { diff --git a/dll/win32/mshtml/htmlwindow.c b/dll/win32/mshtml/htmlwindow.c index 4493437cb63..c7b537b6d74 100644 --- a/dll/win32/mshtml/htmlwindow.c +++ b/dll/win32/mshtml/htmlwindow.c @@ -117,59 +117,45 @@ static HRESULT WINAPI HTMLWindow2_QueryInterface(IHTMLWindow2 *iface, REFIID rii { HTMLWindow *This = impl_from_IHTMLWindow2(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLWindow2_iface; }else if(IsEqualGUID(&IID_IDispatch, riid)) { - TRACE("(%p)->(IID_IDispatch %p)\n", This, ppv); *ppv = &This->IHTMLWindow2_iface; }else if(IsEqualGUID(&IID_IDispatchEx, riid)) { - TRACE("(%p)->(IID_IDispatchEx %p)\n", This, ppv); *ppv = &This->IDispatchEx_iface; }else if(IsEqualGUID(&IID_IHTMLFramesCollection2, riid)) { - TRACE("(%p)->(IID_IHTMLFramesCollection2 %p)\n", This, ppv); *ppv = &This->IHTMLWindow2_iface; }else if(IsEqualGUID(&IID_IHTMLWindow2, riid)) { - TRACE("(%p)->(IID_IHTMLWindow2 %p)\n", This, ppv); *ppv = &This->IHTMLWindow2_iface; }else if(IsEqualGUID(&IID_IHTMLWindow3, riid)) { - TRACE("(%p)->(IID_IHTMLWindow3 %p)\n", This, ppv); *ppv = &This->IHTMLWindow3_iface; }else if(IsEqualGUID(&IID_IHTMLWindow4, riid)) { - TRACE("(%p)->(IID_IHTMLWindow4 %p)\n", This, ppv); *ppv = &This->IHTMLWindow4_iface; }else if(IsEqualGUID(&IID_IHTMLWindow5, riid)) { - TRACE("(%p)->(IID_IHTMLWindow5 %p)\n", This, ppv); *ppv = &This->IHTMLWindow5_iface; }else if(IsEqualGUID(&IID_IHTMLWindow6, riid)) { - TRACE("(%p)->(IID_IHTMLWindow6 %p)\n", This, ppv); *ppv = &This->IHTMLWindow6_iface; }else if(IsEqualGUID(&IID_IHTMLPrivateWindow, riid)) { - TRACE("(%p)->(IID_IHTMLPrivateWindow %p)\n", This, ppv); *ppv = &This->IHTMLPrivateWindow_iface; }else if(IsEqualGUID(&IID_IServiceProvider, riid)) { - TRACE("(%p)->(IID_IServiceProvider %p)\n", This, ppv); *ppv = &This->IServiceProvider_iface; }else if(IsEqualGUID(&IID_ITravelLogClient, riid)) { - TRACE("(%p)->(IID_ITravelLogClient %p)\n", This, ppv); *ppv = &This->ITravelLogClient_iface; }else if(IsEqualGUID(&IID_IObjectIdentity, riid)) { - TRACE("(%p)->(IID_IObjectIdentity %p)\n", This, ppv); *ppv = &This->IObjectIdentity_iface; }else if(dispex_query_interface(&This->inner_window->dispex, riid, ppv)) { assert(!*ppv); return E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLWindow2_AddRef(IHTMLWindow2 *iface) @@ -254,6 +240,9 @@ static void release_inner_window(HTMLInnerWindow *This) IOmHistory_Release(&This->history->IOmHistory_iface); } + if(This->session_storage) + IHTMLStorage_Release(This->session_storage); + if(This->mon) IMoniker_Release(This->mon); @@ -1000,8 +989,10 @@ static HRESULT WINAPI HTMLWindow2_get_window(IHTMLWindow2 *iface, IHTMLWindow2 * static HRESULT WINAPI HTMLWindow2_navigate(IHTMLWindow2 *iface, BSTR url) { HTMLWindow *This = impl_from_IHTMLWindow2(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(url)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_w(url)); + + return navigate_url(This->outer_window, url, This->outer_window->uri, BINDING_NAVIGATED); } static HRESULT WINAPI HTMLWindow2_put_onfocus(IHTMLWindow2 *iface, VARIANT v) @@ -1284,8 +1275,17 @@ static HRESULT WINAPI HTMLWindow2_blur(IHTMLWindow2 *iface) static HRESULT WINAPI HTMLWindow2_scroll(IHTMLWindow2 *iface, LONG x, LONG y) { HTMLWindow *This = impl_from_IHTMLWindow2(iface); - FIXME("(%p)->(%d %d)\n", This, x, y); - return E_NOTIMPL; + nsresult nsres; + + TRACE("(%p)->(%d %d)\n", This, x, y); + + nsres = nsIDOMWindow_Scroll(This->outer_window->nswindow, x, y); + if(NS_FAILED(nsres)) { + ERR("ScrollBy failed: %08x\n", nsres); + return E_FAIL; + } + + return S_OK; } static HRESULT WINAPI HTMLWindow2_get_clientInformation(IHTMLWindow2 *iface, IOmNavigator **p) @@ -2383,8 +2383,7 @@ static HRESULT WINAPI WindowDispEx_GetIDsOfNames(IDispatchEx *iface, REFIID riid UINT i; HRESULT hres; - WARN("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, - lcid, rgDispId); + WARN("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId); for(i=0; i < cNames; i++) { /* We shouldn't use script's IDispatchEx here, so we shouldn't use GetDispID */ @@ -2662,7 +2661,7 @@ static HRESULT WINAPI HTMLWindowSP_QueryService(IServiceProvider *iface, REFGUID return IHTMLWindow2_QueryInterface(&This->IHTMLWindow2_iface, riid, ppv); } - TRACE("(%p)->(%s %s %p)\n", This, debugstr_guid(guidService), debugstr_guid(riid), ppv); + TRACE("(%p)->(%s %s %p)\n", This, debugstr_mshtml_guid(guidService), debugstr_mshtml_guid(riid), ppv); if(!This->outer_window->doc_obj) return E_NOINTERFACE; diff --git a/dll/win32/mshtml/ifacewrap.c b/dll/win32/mshtml/ifacewrap.c index 24edf9dff7e..cc22246a72b 100644 --- a/dll/win32/mshtml/ifacewrap.c +++ b/dll/win32/mshtml/ifacewrap.c @@ -39,7 +39,7 @@ static HRESULT WINAPI wrapper_QueryInterface(IUnknown *iface, REFIID riid, void { iface_wrapper_t *This = impl_from_IUnknown(iface); - TRACE("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); return IUnknown_QueryInterface(This->ref_unk, riid, ppv); } diff --git a/dll/win32/mshtml/ipwindow.c b/dll/win32/mshtml/ipwindow.c index a110998ebf1..d2c4d72b2d0 100644 --- a/dll/win32/mshtml/ipwindow.c +++ b/dll/win32/mshtml/ipwindow.c @@ -33,20 +33,18 @@ static HRESULT WINAPI InPlaceFrame_QueryInterface(IOleInPlaceFrame *iface, { InPlaceFrame *This = impl_from_IOleInPlaceFrame(iface); + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IOleInPlaceFrame_iface; }else if(IsEqualGUID(&IID_IOleWindow, riid)) { - TRACE("(%p)->(IID_IOleWindow %p)\n", This, ppv); *ppv = &This->IOleInPlaceFrame_iface; }else if(IsEqualGUID(&IID_IOleInPlaceUIWindow, riid)) { - TRACE("(%p)->(IID_IOleInPlaceUIWindow %p)\n", This, ppv); *ppv = &This->IOleInPlaceFrame_iface; }else if(IsEqualGUID(&IID_IOleInPlaceFrame, riid)) { - TRACE("(%p)->(IID_IOleInPlaceFrame %p)\n", This, ppv); *ppv = &This->IOleInPlaceFrame_iface; }else { - WARN("Unsopported interface %s\n", debugstr_guid(riid)); + WARN("Unsopported interface %s\n", debugstr_mshtml_guid(riid)); *ppv = NULL; return E_NOINTERFACE; } @@ -217,17 +215,16 @@ static HRESULT WINAPI InPlaceUIWindow_QueryInterface(IOleInPlaceUIWindow *iface, { InPlaceUIWindow *This = impl_from_IOleInPlaceUIWindow(iface); + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IOleInPlaceUIWindow_iface; }else if(IsEqualGUID(&IID_IOleWindow, riid)) { - TRACE("(%p)->(IID_IOleWindow %p)\n", This, ppv); *ppv = &This->IOleInPlaceUIWindow_iface; }else if(IsEqualGUID(&IID_IOleInPlaceUIWindow, riid)) { - TRACE("(%p)->(IID_IOleInPlaceUIWindow %p)\n", This, ppv); *ppv = &This->IOleInPlaceUIWindow_iface; }else { - WARN("Unsopported interface %s\n", debugstr_guid(riid)); + WARN("Unsopported interface %s\n", debugstr_mshtml_guid(riid)); *ppv = NULL; return E_NOINTERFACE; } diff --git a/dll/win32/mshtml/lang/Da.rc b/dll/win32/mshtml/lang/Da.rc index 19efe336181..eec15f95064 100644 --- a/dll/win32/mshtml/lang/Da.rc +++ b/dll/win32/mshtml/lang/Da.rc @@ -34,18 +34,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "HTML dokument" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Hyperlink" FONT 8, "MS Shell Dlg" { GROUPBOX "Information om Hyperlink'en", -1, 5, 5, 190, 55 - LTEXT "&Type:", -1, 10, 22, 20, 10 + LTEXT "&Type:", -1, 10, 22, 24, 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, 24, 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 "Annuller", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Annuller", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -54,6 +54,6 @@ 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 "Annuller", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Annuller", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/De.rc b/dll/win32/mshtml/lang/De.rc index 09615acb4f4..5352db2e0d3 100644 --- a/dll/win32/mshtml/lang/De.rc +++ b/dll/win32/mshtml/lang/De.rc @@ -33,18 +33,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "HTML-Dokument" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Hyperlink" FONT 8, "MS Shell Dlg" { GROUPBOX "Hyperlink-Eigenschaften", -1, 5, 5, 190, 55 - LTEXT "&Typ:", -1, 10, 22, 20, 10 + LTEXT "&Type:", -1, 10, 22, 24, 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, 24, 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 "Abbrechen", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Abbrechen", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -53,6 +53,6 @@ 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 "Abbrechen", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Abbrechen", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Es.rc b/dll/win32/mshtml/lang/Es.rc index 6363f9a4ba2..9dbcd424064 100644 --- a/dll/win32/mshtml/lang/Es.rc +++ b/dll/win32/mshtml/lang/Es.rc @@ -31,18 +31,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "Documento HTML" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Enlace" FONT 8, "MS Shell Dlg" { GROUPBOX "Informacin sobre el enlace", -1, 5, 5, 190, 55 - LTEXT "&Tipo:", -1, 10, 22, 20, 10 + LTEXT "&Tipo:", -1, 10, 22, 24, 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, 24, 10 EDITTEXT IDC_URL, 35, 40, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Aceptar", IDOK, 200, 10, 45, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Anular", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Aceptar", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Anular", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -51,6 +51,6 @@ 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 "Aceptar", IDOK, 40, 65, 45, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Cancelar", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Aceptar", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Cancelar", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Fr.rc b/dll/win32/mshtml/lang/Fr.rc index 7862c0be875..96471f27c85 100644 --- a/dll/win32/mshtml/lang/Fr.rc +++ b/dll/win32/mshtml/lang/Fr.rc @@ -36,18 +36,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "Document HTML" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU 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, 24, 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, 24, 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 + PUSHBUTTON "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Annuler", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -56,6 +56,6 @@ 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 "Annuler", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Annuler", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/He.rc b/dll/win32/mshtml/lang/He.rc index 8c2dc2f9ca7..11094db56db 100644 --- a/dll/win32/mshtml/lang/He.rc +++ b/dll/win32/mshtml/lang/He.rc @@ -31,18 +31,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "מסמך HTML" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "קישור" FONT 8, "MS Shell Dlg" { GROUPBOX "מידע קישור", -1, 5, 5, 190, 55 - LTEXT "סוג:", -1, 10, 22, 20, 10 + LTEXT "סוג:", -1, 10, 22, 24, 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, 24, 10 EDITTEXT IDC_URL, 35, 40, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - PUSHBUTTON "אישור", IDOK, 200, 10, 45, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "ביטול", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "אישור", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "ביטול", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -51,6 +51,6 @@ 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 "אישור", IDOK, 40, 65, 45, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "ביטול", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "אישור", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "ביטול", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Hu.rc b/dll/win32/mshtml/lang/Hu.rc index e17589b0a6f..11a71d66577 100644 --- a/dll/win32/mshtml/lang/Hu.rc +++ b/dll/win32/mshtml/lang/Hu.rc @@ -32,18 +32,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "HTML dokumentum" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Hiperhivatkozás" FONT 8, "MS Shell Dlg" { GROUPBOX "Hiperhivatkozás információ", -1, 5, 5, 190, 55 - LTEXT "&Típus:", -1, 10, 22, 20, 10 + LTEXT "&Típus:", -1, 10, 22, 24, 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, 24, 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 "Mégse", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Mégse", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -52,6 +52,6 @@ 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 "Mégse", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Mégse", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/It.rc b/dll/win32/mshtml/lang/It.rc index 23ad33fb69e..6f833e63ee4 100644 --- a/dll/win32/mshtml/lang/It.rc +++ b/dll/win32/mshtml/lang/It.rc @@ -32,18 +32,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "Documento HTML" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Hyperlink" FONT 8, "MS Shell Dlg" { GROUPBOX "Informazioni sull'hyperlink", -1, 5, 5, 190, 55 - LTEXT "&Tipo:", -1, 10, 22, 20, 10 + LTEXT "&Tipo:", -1, 10, 22, 24, 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, 24, 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 "Annulla", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Annulla", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -52,6 +52,6 @@ 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 "Annulla", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Annulla", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Ja.rc b/dll/win32/mshtml/lang/Ja.rc index d2c519b900b..4bda8c94e3f 100644 --- a/dll/win32/mshtml/lang/Ja.rc +++ b/dll/win32/mshtml/lang/Ja.rc @@ -32,18 +32,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "HTML 文書" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "ハイパーリンク" FONT 9, "MS Shell Dlg" { GROUPBOX "ハイパーリンクの情報", -1, 5, 5, 190, 55 - LTEXT "種類(&T):", -1, 10, 22, 20, 10 + LTEXT "種類(&T):", -1, 10, 22, 24, 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, 24, 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 "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "キャンセル", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -52,6 +52,6 @@ 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 + PUSHBUTTON "OK", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "キャンセル", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Ko.rc b/dll/win32/mshtml/lang/Ko.rc index f7c76423644..706bafa6890 100644 --- a/dll/win32/mshtml/lang/Ko.rc +++ b/dll/win32/mshtml/lang/Ko.rc @@ -30,26 +30,26 @@ STRINGTABLE IDS_HTMLDOCUMENT "HTML " } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "۸ũ" FONT 9, "MS Shell Dlg" { - GROUPBOX "۸ũ ", -1, 5, 5, 190, 55 - LTEXT "(&T):", -1, 10, 22, 24, 10 - COMBOBOX IDC_TYPE, 35, 20, 45, 100, WS_TABSTOP | WS_GROUP | WS_VSCROLL | CBS_DROPDOWNLIST | CBS_HASSTRINGS - LTEXT "ּ(&U):", -1, 10, 42, 24, 10 - EDITTEXT IDC_URL, 35, 40, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Ȯ", IDOK, 200, 10, 45, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + GROUPBOX "۸ũ ", -1, 5, 5, 190, 55 + LTEXT "(&T):", -1, 10, 22, 24, 10 + COMBOBOX IDC_TYPE, 35, 20, 45, 100, WS_TABSTOP | WS_GROUP | WS_VSCROLL | CBS_DROPDOWNLIST | CBS_HASSTRINGS + LTEXT "ּ(&U):", -1, 10, 42, 24, 10 + EDITTEXT IDC_URL, 35, 40, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Ȯ", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU 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 "Ȯ", IDOK, 40, 65, 45, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + 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 "Ȯ", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Lt.rc b/dll/win32/mshtml/lang/Lt.rc index af08a0396cc..f6c5256c05d 100644 --- a/dll/win32/mshtml/lang/Lt.rc +++ b/dll/win32/mshtml/lang/Lt.rc @@ -32,18 +32,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "HTML dokumentas" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Saitas" FONT 8, "MS Shell Dlg" { GROUPBOX "Saito informacija", -1, 5, 5, 190, 55 - LTEXT "&Tipas:", -1, 10, 22, 20, 10 + LTEXT "&Tipas:", -1, 10, 22, 24, 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, 24, 10 EDITTEXT IDC_URL, 35, 40, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Gerai", IDOK, 200, 10, 45, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Atsisakyti", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Gerai", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Atsisakyti", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -52,6 +52,6 @@ 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 "Gerai", IDOK, 40, 65, 45, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Atsisakyti", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Gerai", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Atsisakyti", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Nl.rc b/dll/win32/mshtml/lang/Nl.rc index a62b52ddec7..7b518ffbc4f 100644 --- a/dll/win32/mshtml/lang/Nl.rc +++ b/dll/win32/mshtml/lang/Nl.rc @@ -31,18 +31,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "HTML document" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Webverwijzing" FONT 8, "MS Shell Dlg" { GROUPBOX "Webverwijzing Informatie", -1, 5, 5, 190, 55 - LTEXT "&Type:", -1, 10, 22, 20, 10 + LTEXT "&Type:", -1, 10, 22, 24, 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, 24, 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 "Annuleren", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Annuleren", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -51,6 +51,6 @@ 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 "Annuleren", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Annuleren", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/No.rc b/dll/win32/mshtml/lang/No.rc index 458d7316bab..48c77d41a1e 100644 --- a/dll/win32/mshtml/lang/No.rc +++ b/dll/win32/mshtml/lang/No.rc @@ -33,18 +33,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "HTML-dokument" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Hyperkobling" FONT 8, "MS Shell Dlg" { GROUPBOX "Informasjon om koblingen", -1, 5, 5, 190, 55 - LTEXT "&Type:", -1, 10, 22, 20, 10 + LTEXT "&Type:", -1, 10, 22, 24, 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, 24, 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 "Avbryt", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Avbryt", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -53,6 +53,6 @@ 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 "Avbryt", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Avbryt", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Pl.rc b/dll/win32/mshtml/lang/Pl.rc index b41d20249f1..3e06d3f521d 100644 --- a/dll/win32/mshtml/lang/Pl.rc +++ b/dll/win32/mshtml/lang/Pl.rc @@ -31,18 +31,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "Dokument HTML" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Hipercze" FONT 8, "MS Shell Dlg" { GROUPBOX "Wasnoci hipercza", -1, 5, 5, 190, 55 - LTEXT "&Typ:", -1, 10, 22, 20, 10 + LTEXT "&Typ:", -1, 10, 22, 24, 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, 24, 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 "Anuluj", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Anuluj", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -51,6 +51,6 @@ 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 "Anuluj", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Anuluj", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Pt.rc b/dll/win32/mshtml/lang/Pt.rc index c3492057c0a..481f6fbb156 100644 --- a/dll/win32/mshtml/lang/Pt.rc +++ b/dll/win32/mshtml/lang/Pt.rc @@ -32,34 +32,34 @@ STRINGTABLE IDS_HTMLDOCUMENT "Documento HTML" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Hiperlink" FONT 8, "MS Shell Dlg" { GROUPBOX "Informação do Hiperlink", -1, 5, 5, 190, 55 - LTEXT "&Tipo:", -1, 10, 22, 20, 10 + LTEXT "&Tipo:", -1, 10, 22, 24, 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, 24, 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 "Cancelar", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Cancelar", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Hiperligação" FONT 8, "MS Shell Dlg" { GROUPBOX "Informação da Hiperligação", -1, 5, 5, 190, 55 - LTEXT "&Tipo:", -1, 10, 22, 20, 10 + LTEXT "&Tipo:", -1, 10, 22, 24, 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, 24, 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 "Cancelar", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Cancelar", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } @@ -71,6 +71,6 @@ 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 + PUSHBUTTON "OK", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Cancelar", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Ro.rc b/dll/win32/mshtml/lang/Ro.rc index 6eaaed88039..67db55df4ab 100644 --- a/dll/win32/mshtml/lang/Ro.rc +++ b/dll/win32/mshtml/lang/Ro.rc @@ -33,18 +33,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "Document HTML" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Hiperlegătură" FONT 8, "MS Shell Dlg" { GROUPBOX "Informații de hiperlegătură", -1, 5, 5, 190, 55 - LTEXT "&Tip:", -1, 10, 22, 20, 10 + LTEXT "&Tip:", -1, 10, 22, 24, 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, 24, 10 EDITTEXT IDC_URL, 35, 40, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Con&firmă", IDOK, 200, 10, 45, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "A&nulează", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Con&firmă", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "A&nulează", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -53,6 +53,6 @@ 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 "Con&firmă", IDOK, 40, 65, 45, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "A&nulează", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Con&firmă", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "A&nulează", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Ru.rc b/dll/win32/mshtml/lang/Ru.rc index 675b40735ca..cb98ccf1047 100644 --- a/dll/win32/mshtml/lang/Ru.rc +++ b/dll/win32/mshtml/lang/Ru.rc @@ -32,18 +32,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "Документ HTML" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Ссылка" FONT 8, "MS Shell Dlg" { GROUPBOX "Информация о ссылке", -1, 5, 5, 190, 55 - LTEXT "&Тип:", -1, 10, 22, 20, 10 + LTEXT "&Тип:", -1, 10, 22, 24, 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, 24, 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 "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Отмена", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -52,6 +52,6 @@ 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 + PUSHBUTTON "OK", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Отмена", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Si.rc b/dll/win32/mshtml/lang/Si.rc index 8c7d8d4222d..0dba787f591 100644 --- a/dll/win32/mshtml/lang/Si.rc +++ b/dll/win32/mshtml/lang/Si.rc @@ -31,18 +31,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "HTML dokument" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Hiperpovezava" FONT 8, "MS Shell Dlg" { GROUPBOX "Lastnosti hiperpovezave", -1, 5, 5, 190, 55 - LTEXT "&Vrsta:", -1, 10, 22, 20, 10 + LTEXT "&Vrsta:", -1, 10, 22, 24, 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, 24, 10 EDITTEXT IDC_URL, 35, 40, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - PUSHBUTTON "V redu", IDOK, 200, 10, 45, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "Prekliči", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "V redu", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Prekliči", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -51,6 +51,6 @@ 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 + PUSHBUTTON "V redu", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Prekliči", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Sv.rc b/dll/win32/mshtml/lang/Sv.rc index b07f2b2f17a..00e0ce073dd 100644 --- a/dll/win32/mshtml/lang/Sv.rc +++ b/dll/win32/mshtml/lang/Sv.rc @@ -29,18 +29,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "HTML-dokument" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Hyperlnk" FONT 8, "MS Shell Dlg" { GROUPBOX "Lnkinformation", -1, 5, 5, 190, 55 - LTEXT "&Typ:", -1, 10, 22, 20, 10 + LTEXT "&Typ:", -1, 10, 22, 24, 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, 24, 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 "Avbryt", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Avbryt", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -49,6 +49,6 @@ 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 "Avbryt", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Avbryt", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Uk.rc b/dll/win32/mshtml/lang/Uk.rc index 3defa4ae9c5..b59dbde2494 100644 --- a/dll/win32/mshtml/lang/Uk.rc +++ b/dll/win32/mshtml/lang/Uk.rc @@ -33,18 +33,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "Документ HTML" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "Гіперпосилання" FONT 8, "MS Shell Dlg" { GROUPBOX "Дані про Гіперпосилання", -1, 5, 5, 190, 55 - LTEXT "&Тип:", -1, 10, 22, 20, 10 + LTEXT "&Тип:", -1, 10, 22, 24, 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, 24, 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 "OK", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Скасувати", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -53,6 +53,6 @@ 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 + PUSHBUTTON "OK", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Скасувати", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/lang/Zh.rc b/dll/win32/mshtml/lang/Zh.rc index 7a151006ed0..1be734391ff 100644 --- a/dll/win32/mshtml/lang/Zh.rc +++ b/dll/win32/mshtml/lang/Zh.rc @@ -35,18 +35,18 @@ STRINGTABLE IDS_HTMLDOCUMENT "HTML 文件" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "超链接" FONT 9, "MS Shell Dlg" { GROUPBOX "超链接信息", -1, 5, 5, 190, 55 - LTEXT "类型(&T):", -1, 10, 22, 20, 10 + LTEXT "类型(&T):", -1, 10, 22, 24, 10 COMBOBOX IDC_TYPE, 35, 20, 45, 100, WS_TABSTOP | WS_GROUP | WS_VSCROLL | CBS_DROPDOWNLIST | CBS_HASSTRINGS - LTEXT "网址(&U):", -1, 10, 42, 20, 10 + LTEXT "网址(&U):", -1, 10, 42, 24, 10 EDITTEXT IDC_URL, 35, 40, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - PUSHBUTTON "确定", IDOK, 200, 10, 45, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "取消", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "确定", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "取消", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP } ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 @@ -55,8 +55,8 @@ 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 "确定", IDOK, 40, 65, 45, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "取消", IDCANCEL, 115, 65, 45, 15, WS_GROUP | WS_TABSTOP + PUSHBUTTON "确定", IDOK, 40, 65, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "取消", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_TRADITIONAL @@ -72,16 +72,26 @@ STRINGTABLE IDS_HTMLDOCUMENT "HTML 檔案" } -IDD_HYPERLINK DIALOG 0, 0, 250, 65 +IDD_HYPERLINK DIALOG 0, 0, 255, 65 STYLE DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU CAPTION "超鏈接" FONT 9, "MS Shell Dlg" { GROUPBOX "超鏈接資訊", -1, 5, 5, 190, 55 - LTEXT "類型(&T):", -1, 10, 22, 20, 10 + LTEXT "類型(&T):", -1, 10, 22, 24, 10 COMBOBOX IDC_TYPE, 35, 20, 45, 100, WS_TABSTOP | WS_GROUP | WS_VSCROLL | CBS_DROPDOWNLIST | CBS_HASSTRINGS - LTEXT "網址(&U):", -1, 10, 42, 20, 10 + LTEXT "網址(&U):", -1, 10, 42, 24, 10 EDITTEXT IDC_URL, 35, 40, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_GROUP | WS_TABSTOP - PUSHBUTTON "確定", IDOK, 200, 10, 45, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP - PUSHBUTTON "取消", IDCANCEL, 200, 28, 45, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "確定", IDOK, 200, 10, 50, 14, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "取消", IDCANCEL, 200, 28, 50, 14, WS_GROUP | WS_TABSTOP +} + +ID_PROMPT_DIALOG DIALOG 0, 0, 200, 90 +STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +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, 50, 15, BS_DEFPUSHBUTTON | WS_GROUP | WS_TABSTOP + PUSHBUTTON "Cancel", IDCANCEL, 110, 65, 50, 15, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/mshtml/loadopts.c b/dll/win32/mshtml/loadopts.c index 8239286f1ca..2de979bb965 100644 --- a/dll/win32/mshtml/loadopts.c +++ b/dll/win32/mshtml/loadopts.c @@ -44,26 +44,22 @@ static HRESULT WINAPI HtmlLoadOptions_QueryInterface(IHtmlLoadOptions *iface, { HTMLLoadOptions *This = impl_from_IHtmlLoadOptions(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHtmlLoadOptions_iface; }else if(IsEqualGUID(&IID_IOptionArray, riid)) { - TRACE("(%p)->(IID_IOptionArray %p)\n", This, ppv); *ppv = &This->IHtmlLoadOptions_iface; }else if(IsEqualGUID(&IID_IHtmlLoadOptions, riid)) { - TRACE("(%p)->(IID_IHtmlLoadOptions %p)\n", This, ppv); *ppv = &This->IHtmlLoadOptions_iface; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IHtmlLoadOptions_AddRef(&This->IHtmlLoadOptions_iface); - return S_OK; - } - - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HtmlLoadOptions_AddRef(IHtmlLoadOptions *iface) @@ -179,9 +175,11 @@ HRESULT HTMLLoadOptions_Create(IUnknown *pUnkOuter, REFIID riid, void** ppv) HTMLLoadOptions *ret; HRESULT hres; - TRACE("(%p %s %p)\n", pUnkOuter, debugstr_guid(riid), ppv); + TRACE("(%p %s %p)\n", pUnkOuter, debugstr_mshtml_guid(riid), ppv); ret = heap_alloc(sizeof(HTMLLoadOptions)); + if(!ret) + return E_OUTOFMEMORY; ret->IHtmlLoadOptions_iface.lpVtbl = &HtmlLoadOptionsVtbl; ret->ref = 1; @@ -189,6 +187,5 @@ HRESULT HTMLLoadOptions_Create(IUnknown *pUnkOuter, REFIID riid, void** ppv) hres = IHtmlLoadOptions_QueryInterface(&ret->IHtmlLoadOptions_iface, riid, ppv); IHtmlLoadOptions_Release(&ret->IHtmlLoadOptions_iface); - return hres; } diff --git a/dll/win32/mshtml/main.c b/dll/win32/mshtml/main.c index 320341f8a11..d0fb5e2c06b 100644 --- a/dll/win32/mshtml/main.c +++ b/dll/win32/mshtml/main.c @@ -186,7 +186,7 @@ static HRESULT WINAPI ClassFactory_QueryInterface(IClassFactory *iface, REFGUID return S_OK; } - WARN("not supported iid %s\n", debugstr_guid(riid)); + WARN("not supported iid %s\n", debugstr_mshtml_guid(riid)); *ppvObject = NULL; return E_NOINTERFACE; } @@ -259,25 +259,25 @@ static HRESULT ClassFactory_Create(REFIID riid, void **ppv, CreateInstanceFunc f HRESULT WINAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID *ppv) { if(IsEqualGUID(&CLSID_HTMLDocument, rclsid)) { - TRACE("(CLSID_HTMLDocument %s %p)\n", debugstr_guid(riid), ppv); + TRACE("(CLSID_HTMLDocument %s %p)\n", debugstr_mshtml_guid(riid), ppv); return ClassFactory_Create(riid, ppv, HTMLDocument_Create); }else if(IsEqualGUID(&CLSID_AboutProtocol, rclsid)) { - TRACE("(CLSID_AboutProtocol %s %p)\n", debugstr_guid(riid), ppv); + TRACE("(CLSID_AboutProtocol %s %p)\n", debugstr_mshtml_guid(riid), ppv); return ProtocolFactory_Create(rclsid, riid, ppv); }else if(IsEqualGUID(&CLSID_JSProtocol, rclsid)) { - TRACE("(CLSID_JSProtocol %s %p)\n", debugstr_guid(riid), ppv); + TRACE("(CLSID_JSProtocol %s %p)\n", debugstr_mshtml_guid(riid), ppv); return ProtocolFactory_Create(rclsid, riid, ppv); }else if(IsEqualGUID(&CLSID_MailtoProtocol, rclsid)) { - TRACE("(CLSID_MailtoProtocol %s %p)\n", debugstr_guid(riid), ppv); + TRACE("(CLSID_MailtoProtocol %s %p)\n", debugstr_mshtml_guid(riid), ppv); return ProtocolFactory_Create(rclsid, riid, ppv); }else if(IsEqualGUID(&CLSID_ResProtocol, rclsid)) { - TRACE("(CLSID_ResProtocol %s %p)\n", debugstr_guid(riid), ppv); + TRACE("(CLSID_ResProtocol %s %p)\n", debugstr_mshtml_guid(riid), ppv); return ProtocolFactory_Create(rclsid, riid, ppv); }else if(IsEqualGUID(&CLSID_SysimageProtocol, rclsid)) { - TRACE("(CLSID_SysimageProtocol %s %p)\n", debugstr_guid(riid), ppv); + TRACE("(CLSID_SysimageProtocol %s %p)\n", debugstr_mshtml_guid(riid), ppv); return ProtocolFactory_Create(rclsid, riid, ppv); }else if(IsEqualGUID(&CLSID_HTMLLoadOptions, rclsid)) { - TRACE("(CLSID_HTMLLoadOptions %s %p)\n", debugstr_guid(riid), ppv); + TRACE("(CLSID_HTMLLoadOptions %s %p)\n", debugstr_mshtml_guid(riid), ppv); return ClassFactory_Create(riid, ppv, HTMLLoadOptions_Create); } @@ -499,3 +499,68 @@ HRESULT WINAPI DllUnregisterServer(void) if(SUCCEEDED(hres)) hres = register_server(FALSE); return hres; } + +const char *debugstr_mshtml_guid(const GUID *iid) +{ +#define X(x) if(IsEqualGUID(iid, &x)) return #x + X(DIID_HTMLDocumentEvents); + X(DIID_HTMLDocumentEvents2); + X(DIID_HTMLTableEvents); + X(DIID_HTMLTextContainerEvents); + X(IID_IConnectionPoint); + X(IID_IConnectionPointContainer); + X(IID_ICustomDoc); + X(IID_IDispatch); + X(IID_IDispatchEx); + X(IID_IEnumConnections); + X(IID_IEnumVARIANT); + X(IID_IHlinkTarget); + X(IID_IHTMLDocument6); + X(IID_IHTMLDocument7); + X(IID_IHTMLFramesCollection2); + X(IID_IHTMLPrivateWindow); + X(IID_IHtmlLoadOptions); + X(IID_IInternetHostSecurityManager); + X(IID_IMonikerProp); + X(IID_IObjectIdentity); + X(IID_IObjectSafety); + X(IID_IObjectWithSite); + X(IID_IOleContainer); + X(IID_IOleCommandTarget); + X(IID_IOleControl); + X(IID_IOleDocument); + X(IID_IOleDocumentView); + X(IID_IOleInPlaceActiveObject); + X(IID_IOleInPlaceFrame); + X(IID_IOleInPlaceObject); + X(IID_IOleInPlaceObjectWindowless); + X(IID_IOleInPlaceUIWindow); + X(IID_IOleObject); + X(IID_IOleWindow); + X(IID_IOptionArray); + X(IID_IPersist); + X(IID_IPersistFile); + X(IID_IPersistHistory); + X(IID_IPersistMoniker); + X(IID_IPersistStreamInit); + X(IID_IPropertyNotifySink); + X(IID_IProvideClassInfo); + X(IID_IServiceProvider); + X(IID_ISupportErrorInfo); + X(IID_ITargetContainer); + X(IID_ITravelLogClient); + X(IID_IUnknown); + X(IID_IViewObject); + X(IID_IViewObject2); + X(IID_IViewObjectEx); + X(IID_nsCycleCollectionISupports); + X(IID_nsXPCOMCycleCollectionParticipant); +#define XIID(x) X(IID_##x); +#define XDIID(x) X(DIID_##x); + TID_LIST +#undef XIID +#undef XDIID +#undef X + + return debugstr_guid(iid); +} diff --git a/dll/win32/mshtml/mshtml_private.h b/dll/win32/mshtml/mshtml_private.h index d5beb2565a9..0559f94366f 100644 --- a/dll/win32/mshtml/mshtml_private.h +++ b/dll/win32/mshtml/mshtml_private.h @@ -129,6 +129,7 @@ typedef struct event_target_t event_target_t; XDIID(DispHTMLStyle) \ XDIID(DispHTMLStyleElement) \ XDIID(DispHTMLStyleSheet) \ + XDIID(DispHTMLStyleSheetRulesCollection) \ XDIID(DispHTMLStyleSheetsCollection) \ XDIID(DispHTMLTable) \ XDIID(DispHTMLTableCell) \ @@ -157,6 +158,7 @@ typedef struct event_target_t event_target_t; XIID(IHTMLDocument5) \ XIID(IHTMLDOMAttribute) \ XIID(IHTMLDOMChildrenCollection) \ + XIID(IHTMLDOMImplementation) \ XIID(IHTMLDOMNode) \ XIID(IHTMLDOMNode2) \ XIID(IHTMLDOMTextNode) \ @@ -188,6 +190,7 @@ typedef struct event_target_t event_target_t; XIID(IHTMLObjectElement) \ XIID(IHTMLObjectElement2) \ XIID(IHTMLOptionElement) \ + XIID(IHTMLOptionElementFactory) \ XIID(IHTMLPluginsCollection) \ XIID(IHTMLRect) \ XIID(IHTMLScreen) \ @@ -202,6 +205,7 @@ typedef struct event_target_t event_target_t; XIID(IHTMLStyle6) \ XIID(IHTMLStyleElement) \ XIID(IHTMLStyleSheet) \ + XIID(IHTMLStyleSheetRulesCollection) \ XIID(IHTMLStyleSheetsCollection) \ XIID(IHTMLTable) \ XIID(IHTMLTable2) \ @@ -338,6 +342,7 @@ typedef struct { } global_prop_t; typedef struct { + DispatchEx dispex; IHTMLOptionElementFactory IHTMLOptionElementFactory_iface; LONG ref; @@ -750,6 +755,8 @@ struct HTMLDocumentNode { BOOL content_ready; event_target_t *body_event_target; + IHTMLDOMImplementation *dom_implementation; + ICatInformation *catmgr; nsDocumentEventListener *nsevent_listener; BOOL *event_vector; @@ -780,6 +787,7 @@ HRESULT HTMLLocation_Create(HTMLInnerWindow*,HTMLLocation**) DECLSPEC_HIDDEN; IOmNavigator *OmNavigator_Create(void) DECLSPEC_HIDDEN; HRESULT HTMLScreen_Create(IHTMLScreen**) DECLSPEC_HIDDEN; HRESULT create_history(HTMLInnerWindow*,OmHistory**) DECLSPEC_HIDDEN; +HRESULT create_dom_implementation(IHTMLDOMImplementation**) DECLSPEC_HIDDEN; HRESULT create_storage(IHTMLStorage**) DECLSPEC_HIDDEN; @@ -845,7 +853,6 @@ void nsACString_Finish(nsACString*) DECLSPEC_HIDDEN; BOOL nsAString_Init(nsAString*,const PRUnichar*) DECLSPEC_HIDDEN; void nsAString_InitDepend(nsAString*,const PRUnichar*) DECLSPEC_HIDDEN; -void nsAString_SetData(nsAString*,const PRUnichar*) DECLSPEC_HIDDEN; UINT32 nsAString_GetData(const nsAString*,const PRUnichar**) DECLSPEC_HIDDEN; void nsAString_Finish(nsAString*) DECLSPEC_HIDDEN; HRESULT return_nsstr(nsresult,nsAString*,BSTR*) DECLSPEC_HIDDEN; @@ -976,6 +983,11 @@ HRESULT wrap_iface(IUnknown*,IUnknown*,IUnknown**) DECLSPEC_HIDDEN; IHTMLElementCollection *create_all_collection(HTMLDOMNode*,BOOL) DECLSPEC_HIDDEN; IHTMLElementCollection *create_collection_from_nodelist(HTMLDocumentNode*,nsIDOMNodeList*) DECLSPEC_HIDDEN; IHTMLElementCollection *create_collection_from_htmlcol(HTMLDocumentNode*,nsIDOMHTMLCollection*) DECLSPEC_HIDDEN; +HRESULT get_elem_source_index(HTMLElement*,LONG*) DECLSPEC_HIDDEN; + +nsresult get_elem_attr_value(nsIDOMHTMLElement*,const WCHAR*,nsAString*,const PRUnichar**) DECLSPEC_HIDDEN; +HRESULT elem_string_attr_getter(HTMLElement*,const WCHAR*,BOOL,BSTR*) DECLSPEC_HIDDEN; +HRESULT elem_string_attr_setter(HTMLElement*,const WCHAR*,const WCHAR*) DECLSPEC_HIDDEN; /* commands */ typedef struct { @@ -1043,7 +1055,7 @@ void remove_target_tasks(LONG) DECLSPEC_HIDDEN; HRESULT set_task_timer(HTMLInnerWindow*,DWORD,BOOL,IDispatch*,LONG*) DECLSPEC_HIDDEN; HRESULT clear_task_timer(HTMLInnerWindow*,BOOL,DWORD) DECLSPEC_HIDDEN; -const char *debugstr_variant(const VARIANT*) DECLSPEC_HIDDEN; +const char *debugstr_mshtml_guid(const GUID*) DECLSPEC_HIDDEN; DEFINE_GUID(CLSID_AboutProtocol, 0x3050F406, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B); DEFINE_GUID(CLSID_JSProtocol, 0x3050F3B2, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B); diff --git a/dll/win32/mshtml/mutation.c b/dll/win32/mshtml/mutation.c index dfdc326f5b2..50872b28a60 100644 --- a/dll/win32/mshtml/mutation.c +++ b/dll/win32/mshtml/mutation.c @@ -617,16 +617,16 @@ static void NSAPI nsDocumentObserver_BindToDocument(nsIDocumentObserver *iface, nsIDOMHTMLIFrameElement *nsiframe; nsIDOMHTMLFrameElement *nsframe; nsIDOMHTMLScriptElement *nsscript; + nsIDOMHTMLElement *nselem; nsIDOMComment *nscomment; - nsIDOMElement *nselem; nsresult nsres; TRACE("(%p)->(%p %p)\n", This, aDocument, aContent); - nsres = nsIContent_QueryInterface(aContent, &IID_nsIDOMElement, (void**)&nselem); + nsres = nsIContent_QueryInterface(aContent, &IID_nsIDOMHTMLElement, (void**)&nselem); if(NS_SUCCEEDED(nsres)) { check_event_attr(This, nselem); - nsIDOMElement_Release(nselem); + nsIDOMHTMLElement_Release(nselem); } nsres = nsIContent_QueryInterface(aContent, &IID_nsIDOMComment, (void**)&nscomment); diff --git a/dll/win32/mshtml/navigate.c b/dll/win32/mshtml/navigate.c index 3f278fab586..563d6df80e7 100644 --- a/dll/win32/mshtml/navigate.c +++ b/dll/win32/mshtml/navigate.c @@ -969,7 +969,7 @@ HRESULT bind_mon_to_wstr(HTMLInnerWindow *window, IMoniker *mon, WCHAR **ret) break; } - MultiByteToWideChar(CP_ACP, 0, bsc->buf, bsc->bsc.readed, text, len); + MultiByteToWideChar(cp, 0, bsc->buf, bsc->bsc.readed, text, len); text[len] = 0; } } diff --git a/dll/win32/mshtml/npplugin.c b/dll/win32/mshtml/npplugin.c index 5e7a16b88c9..9c84df473fb 100644 --- a/dll/win32/mshtml/npplugin.c +++ b/dll/win32/mshtml/npplugin.c @@ -194,10 +194,11 @@ typedef struct _NPPluginFuncs { NPP_LostFocusPtr lostfocus; } NPPluginFuncs; -static nsIDOMElement *get_dom_element(NPP instance) +static nsIDOMHTMLElement *get_dom_element(NPP instance) { nsISupports *instance_unk = (nsISupports*)instance->ndata; nsIPluginInstance *plugin_instance; + nsIDOMHTMLElement *html_elem; nsIDOMElement *elem; nsresult nsres; @@ -214,17 +215,24 @@ static nsIDOMElement *get_dom_element(NPP instance) return NULL; } - return elem; + nsres = nsIDOMElement_QueryInterface(elem, &IID_nsIDOMHTMLElement, (void**)&html_elem); + nsIDOMElement_Release(elem); + if(NS_FAILED(nsres)) { + ERR("Could not get nsIDOMHTMLElement iface: %08x\n", nsres); + return NULL; + } + + return html_elem; } -static HTMLInnerWindow *get_elem_window(nsIDOMElement *elem) +static HTMLInnerWindow *get_elem_window(nsIDOMHTMLElement *elem) { nsIDOMWindow *nswindow; nsIDOMDocument *nsdoc; HTMLOuterWindow *window; nsresult nsres; - nsres = nsIDOMElement_GetOwnerDocument(elem, &nsdoc); + nsres = nsIDOMHTMLElement_GetOwnerDocument(elem, &nsdoc); if(NS_FAILED(nsres)) return NULL; @@ -270,29 +278,22 @@ static BOOL parse_classid(const PRUnichar *classid, CLSID *clsid) return SUCCEEDED(hres); } -static BOOL get_elem_clsid(nsIDOMElement *elem, CLSID *clsid) +static BOOL get_elem_clsid(nsIDOMHTMLElement *elem, CLSID *clsid) { - nsAString attr_str, val_str; + const PRUnichar *val; + nsAString val_str; nsresult nsres; BOOL ret = FALSE; static const PRUnichar classidW[] = {'c','l','a','s','s','i','d',0}; - nsAString_InitDepend(&attr_str, classidW); - nsAString_Init(&val_str, NULL); - nsres = nsIDOMElement_GetAttribute(elem, &attr_str, &val_str); - nsAString_Finish(&attr_str); + nsres = get_elem_attr_value(elem, classidW, &val_str, &val); if(NS_SUCCEEDED(nsres)) { - const PRUnichar *val; - - nsAString_GetData(&val_str, &val); if(*val) ret = parse_classid(val, clsid); - }else { - ERR("GetAttribute failed: %08x\n", nsres); + nsAString_Finish(&val_str); } - nsAString_Finish(&val_str); return ret; } @@ -512,35 +513,28 @@ static void install_codebase(const WCHAR *url) WARN("FAILED: %08x\n", hres); } -static void check_codebase(HTMLInnerWindow *window, nsIDOMElement *nselem) +static void check_codebase(HTMLInnerWindow *window, nsIDOMHTMLElement *nselem) { - nsAString attr_str, val_str; BOOL is_on_list = FALSE; install_entry_t *iter; + const PRUnichar *val; + nsAString val_str; IUri *uri = NULL; nsresult nsres; HRESULT hres; static const PRUnichar codebaseW[] = {'c','o','d','e','b','a','s','e',0}; - nsAString_InitDepend(&attr_str, codebaseW); - nsAString_Init(&val_str, NULL); - nsres = nsIDOMElement_GetAttribute(nselem, &attr_str, &val_str); - nsAString_Finish(&attr_str); + nsres = get_elem_attr_value(nselem, codebaseW, &val_str, &val); if(NS_SUCCEEDED(nsres)) { - const PRUnichar *val; - - nsAString_GetData(&val_str, &val); if(*val) { hres = CoInternetCombineUrlEx(window->base.outer_window->uri, val, 0, &uri, 0); if(FAILED(hres)) uri = NULL; } - }else { - ERR("GetAttribute failed: %08x\n", nsres); + nsAString_Finish(&val_str); } - nsAString_Finish(&val_str); if(!uri) return; @@ -582,7 +576,7 @@ static void check_codebase(HTMLInnerWindow *window, nsIDOMElement *nselem) IUri_Release(uri); } -static IUnknown *create_activex_object(HTMLInnerWindow *window, nsIDOMElement *nselem, CLSID *clsid) +static IUnknown *create_activex_object(HTMLInnerWindow *window, nsIDOMHTMLElement *nselem, CLSID *clsid) { IClassFactoryEx *cfex; IClassFactory *cf; @@ -628,7 +622,7 @@ static IUnknown *create_activex_object(HTMLInnerWindow *window, nsIDOMElement *n static NPError CDECL NPP_New(NPMIMEType pluginType, NPP instance, UINT16 mode, INT16 argc, char **argn, char **argv, NPSavedData *saved) { - nsIDOMElement *nselem; + nsIDOMHTMLElement *nselem; HTMLInnerWindow *window; IUnknown *obj; CLSID clsid; @@ -645,7 +639,7 @@ static NPError CDECL NPP_New(NPMIMEType pluginType, NPP instance, UINT16 mode, I window = get_elem_window(nselem); if(!window) { ERR("Could not get element's window object\n"); - nsIDOMElement_Release(nselem); + nsIDOMHTMLElement_Release(nselem); return NPERR_GENERIC_ERROR; } @@ -654,7 +648,7 @@ static NPError CDECL NPP_New(NPMIMEType pluginType, NPP instance, UINT16 mode, I PluginHost *host; HRESULT hres; - hres = create_plugin_host(window->doc, nselem, obj, &clsid, &host); + hres = create_plugin_host(window->doc, (nsIDOMElement*)nselem, obj, &clsid, &host); IUnknown_Release(obj); if(SUCCEEDED(hres)) instance->pdata = host; @@ -664,7 +658,7 @@ static NPError CDECL NPP_New(NPMIMEType pluginType, NPP instance, UINT16 mode, I err = NPERR_GENERIC_ERROR; } - nsIDOMElement_Release(nselem); + nsIDOMHTMLElement_Release(nselem); return err; } diff --git a/dll/win32/mshtml/nsembed.c b/dll/win32/mshtml/nsembed.c index b8de1a4caa7..4f1bffdf964 100644 --- a/dll/win32/mshtml/nsembed.c +++ b/dll/win32/mshtml/nsembed.c @@ -423,8 +423,10 @@ static BOOL install_wine_gecko(void) static void set_environment(LPCWSTR gre_path) { - WCHAR path_env[MAX_PATH], buf[20]; - int len, debug_level = 0; + size_t len, gre_path_len; + int debug_level = 0; + WCHAR *path, buf[20]; + const WCHAR *ptr; static const WCHAR pathW[] = {'P','A','T','H',0}; static const WCHAR warnW[] = {'w','a','r','n',0}; @@ -434,13 +436,6 @@ static void set_environment(LPCWSTR gre_path) {'N','S','P','R','_','L','O','G','_','M','O','D','U','L','E','S',0}; static const WCHAR debug_formatW[] = {'a','l','l',':','%','d',0}; - /* We have to modify PATH as XPCOM loads other DLLs from this directory. */ - GetEnvironmentVariableW(pathW, path_env, sizeof(path_env)/sizeof(WCHAR)); - len = strlenW(path_env); - path_env[len++] = ';'; - strcpyW(path_env+len, gre_path); - SetEnvironmentVariableW(pathW, path_env); - SetEnvironmentVariableW(xpcom_debug_breakW, warnW); if(TRACE_ON(gecko)) @@ -452,6 +447,23 @@ static void set_environment(LPCWSTR gre_path) sprintfW(buf, debug_formatW, debug_level); SetEnvironmentVariableW(nspr_log_modulesW, buf); + + len = GetEnvironmentVariableW(pathW, NULL, 0); + gre_path_len = strlenW(gre_path); + path = heap_alloc((len+gre_path_len+1)*sizeof(WCHAR)); + if(!path) + return; + GetEnvironmentVariableW(pathW, path, len); + + /* We have to modify PATH as xul.dll loads other DLLs from this directory. */ + if(!(ptr = strstrW(path, gre_path)) + || (ptr > path && *(ptr-1) != ';') + || (ptr[gre_path_len] && ptr[gre_path_len] != ';')) { + if(len) + path[len-1] = ';'; + strcpyW(path+len, gre_path); + SetEnvironmentVariableW(pathW, path); + } } static BOOL load_xul(const PRUnichar *gre_path) @@ -825,11 +837,6 @@ void nsAString_InitDepend(nsAString *str, const PRUnichar *data) NS_StringContainerInit2(str, data, PR_UINT32_MAX, NS_STRING_CONTAINER_INIT_DEPEND); } -void nsAString_SetData(nsAString *str, const PRUnichar *data) -{ - NS_StringSetData(str, data, PR_UINT32_MAX); -} - UINT32 nsAString_GetData(const nsAString *str, const PRUnichar **data) { return NS_StringGetData(str, data, NULL); diff --git a/dll/win32/mshtml/nsiface.idl b/dll/win32/mshtml/nsiface.idl index c0959f52768..a5275e70f12 100644 --- a/dll/win32/mshtml/nsiface.idl +++ b/dll/win32/mshtml/nsiface.idl @@ -1791,7 +1791,7 @@ interface nsIDOMHTMLSelectElement : nsIDOMHTMLElement nsresult Item(uint32_t index, nsIDOMNode **_retval); nsresult NamedItem(const nsAString *name, nsIDOMNode **_retval); nsresult Add(nsIDOMHTMLElement *element, nsIVariant *before); - nsresult Remove(int32_t index); + nsresult select_Remove(int32_t index); nsresult GetSelectedIndex(int32_t *aSelectedIndex); nsresult SetSelectedIndex(int32_t aSelectedIndex); nsresult GetValue(nsAString *aValue); @@ -2070,6 +2070,44 @@ interface nsIDOMHTMLTableRowElement : nsIDOMHTMLElement nsresult DeleteCell(int32_t index); } +[ + object, + uuid(1fb22137-c231-4eae-9ca4-557bb0852d89), + local +] +interface nsIDOMHTMLTableCellElement : nsIDOMHTMLElement +{ + nsresult GetCellIndex(int32_t *aCellIndex); + nsresult GetAbbr(nsAString *aAbbr); + nsresult SetAbbr(const nsAString *aAbbr); + nsresult GetAlign(nsAString *aAlign); + nsresult SetAlign(const nsAString *aAlign); + nsresult GetAxis(nsAString *aAxis); + nsresult SetAxis(const nsAString *aAxis); + nsresult GetBgColor(nsAString *aBgColor); + nsresult SetBgColor(const nsAString *aBgColor); + nsresult GetCh(nsAString *aCh); + nsresult SetCh(const nsAString *aCh); + nsresult GetChOff(nsAString *aChOff); + nsresult SetChOff(const nsAString *aChOff); + nsresult GetColSpan(int32_t *aColSpan); + nsresult SetColSpan(int32_t aColSpan); + nsresult GetHeaders(nsAString *aHeaders); + nsresult SetHeaders(const nsAString *aHeaders); + nsresult GetHeight(nsAString *aHeight); + nsresult SetHeight(const nsAString *aHeight); + nsresult GetNoWrap(bool *aNoWrap); + nsresult SetNoWrap(bool aNoWrap); + nsresult GetRowSpan(int32_t *aRowSpan); + nsresult SetRowSpan(int32_t aRowSpan); + nsresult GetScope(nsAString *aScope); + nsresult SetScope(const nsAString *aScope); + nsresult GetVAlign(nsAString *aVAlign); + nsresult SetVAlign(const nsAString *aVAlign); + nsresult GetWidth(nsAString *aWidth); + nsresult SetWidth(const nsAString *aWidth); +} + [ object, uuid(21ffbe98-51f5-499e-8d6f-612ae798c1e1), @@ -2180,23 +2218,6 @@ interface nsIDOMHTMLObjectElement : nsIDOMHTMLElement nsresult SetCustomValidity(const nsAString *error); } -[ - object, - uuid(f85e1b05-6dc4-442d-bea8-7cf551f9bc9f), - local -] -interface nsIDOMHTMLParamElement : nsIDOMHTMLElement -{ - nsresult GetName(nsAString *aName); - nsresult SetName(const nsAString *aName); - nsresult GetType(nsAString *aType); - nsresult SetType(const nsAString *aType); - nsresult GetValue(nsAString *aValue); - nsresult SetValue(const nsAString *aValue); - nsresult GetValueType(nsAString *aValueType); - nsresult SetValueType(const nsAString *aValueType); -} - [ object, uuid(e81273e1-d440-4dd3-9073-8199f7a9525e), diff --git a/dll/win32/mshtml/nsio.c b/dll/win32/mshtml/nsio.c index e507aec74be..ddce504e6a8 100644 --- a/dll/win32/mshtml/nsio.c +++ b/dll/win32/mshtml/nsio.c @@ -2606,10 +2606,27 @@ static nsresult NSAPI nsURL_SetFilePath(nsIFileURL *iface, const nsACString *aFi static nsresult NSAPI nsURL_GetQuery(nsIFileURL *iface, nsACString *aQuery) { nsWineURI *This = impl_from_nsIFileURL(iface); + WCHAR *ptr; + BSTR query; + nsresult nsres; + HRESULT hres; TRACE("(%p)->(%p)\n", This, aQuery); - return get_uri_string(This, Uri_PROPERTY_QUERY, aQuery); + if(!ensure_uri(This)) + return NS_ERROR_UNEXPECTED; + + hres = IUri_GetQuery(This->uri, &query); + if(FAILED(hres)) + return NS_ERROR_FAILURE; + + ptr = query; + if(ptr && *ptr == '?') + ptr++; + + nsres = return_wstr_nsacstr(aQuery, ptr, -1); + SysFreeString(query); + return nsres; } static nsresult NSAPI nsURL_SetQuery(nsIFileURL *iface, const nsACString *aQuery) diff --git a/dll/win32/mshtml/oleobj.c b/dll/win32/mshtml/oleobj.c index 23b3784c6bd..7f17179a14a 100644 --- a/dll/win32/mshtml/oleobj.c +++ b/dll/win32/mshtml/oleobj.c @@ -354,7 +354,7 @@ static HRESULT WINAPI OleObject_SetClientSite(IOleObject *iface, IOleClientSite (void**)&uihandler2); if(SUCCEEDED(hres)) { hres = IDocHostUIHandler2_GetOverrideKeyPath(uihandler2, &override_key_path, 0); - if(hres == S_OK && override_key_path && override_key_path[0]) { + if(hres == S_OK && override_key_path) { if(override_key_path[0]) { /*FIXME: use override_key_path */ FIXME("override_key_path = %s\n", debugstr_w(override_key_path)); diff --git a/dll/win32/mshtml/omnavigator.c b/dll/win32/mshtml/omnavigator.c index 5bb23c75c38..8362bb6015e 100644 --- a/dll/win32/mshtml/omnavigator.c +++ b/dll/win32/mshtml/omnavigator.c @@ -41,6 +41,148 @@ typedef struct { HTMLMimeTypesCollection *mime_types; } OmNavigator; +typedef struct { + DispatchEx dispex; + IHTMLDOMImplementation IHTMLDOMImplementation_iface; + + LONG ref; +} HTMLDOMImplementation; + +static inline HTMLDOMImplementation *impl_from_IHTMLDOMImplementation(IHTMLDOMImplementation *iface) +{ + return CONTAINING_RECORD(iface, HTMLDOMImplementation, IHTMLDOMImplementation_iface); +} + +static HRESULT WINAPI HTMLDOMImplementation_QueryInterface(IHTMLDOMImplementation *iface, REFIID riid, void **ppv) +{ + HTMLDOMImplementation *This = impl_from_IHTMLDOMImplementation(iface); + + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + + if(IsEqualGUID(&IID_IUnknown, riid) || IsEqualGUID(&IID_IHTMLDOMImplementation, riid)) { + *ppv = &This->IHTMLDOMImplementation_iface; + }else if(dispex_query_interface(&This->dispex, riid, ppv)) { + return *ppv ? S_OK : E_NOINTERFACE; + }else { + WARN("Unsupported interface %s\n", debugstr_mshtml_guid(riid)); + *ppv = NULL; + return E_NOINTERFACE; + } + + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; +} + +static ULONG WINAPI HTMLDOMImplementation_AddRef(IHTMLDOMImplementation *iface) +{ + HTMLDOMImplementation *This = impl_from_IHTMLDOMImplementation(iface); + LONG ref = InterlockedIncrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); + + return ref; +} + +static ULONG WINAPI HTMLDOMImplementation_Release(IHTMLDOMImplementation *iface) +{ + HTMLDOMImplementation *This = impl_from_IHTMLDOMImplementation(iface); + LONG ref = InterlockedDecrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); + + if(!ref) { + release_dispex(&This->dispex); + heap_free(This); + } + + return ref; +} + +static HRESULT WINAPI HTMLDOMImplementation_GetTypeInfoCount(IHTMLDOMImplementation *iface, UINT *pctinfo) +{ + HTMLDOMImplementation *This = impl_from_IHTMLDOMImplementation(iface); + + return IDispatchEx_GetTypeInfoCount(&This->dispex.IDispatchEx_iface, pctinfo); +} + +static HRESULT WINAPI HTMLDOMImplementation_GetTypeInfo(IHTMLDOMImplementation *iface, UINT iTInfo, + LCID lcid, ITypeInfo **ppTInfo) +{ + HTMLDOMImplementation *This = impl_from_IHTMLDOMImplementation(iface); + + return IDispatchEx_GetTypeInfo(&This->dispex.IDispatchEx_iface, iTInfo, lcid, ppTInfo); +} + +static HRESULT WINAPI HTMLDOMImplementation_GetIDsOfNames(IHTMLDOMImplementation *iface, REFIID riid, + LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId) +{ + HTMLDOMImplementation *This = impl_from_IHTMLDOMImplementation(iface); + + return IDispatchEx_GetIDsOfNames(&This->dispex.IDispatchEx_iface, riid, rgszNames, + cNames, lcid, rgDispId); +} + +static HRESULT WINAPI HTMLDOMImplementation_Invoke(IHTMLDOMImplementation *iface, DISPID dispIdMember, + REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, + EXCEPINFO *pExcepInfo, UINT *puArgErr) +{ + HTMLDOMImplementation *This = impl_from_IHTMLDOMImplementation(iface); + + return IDispatchEx_Invoke(&This->dispex.IDispatchEx_iface, dispIdMember, riid, + lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); +} + +static HRESULT WINAPI HTMLDOMImplementation_hasFeature(IHTMLDOMImplementation *iface, BSTR feature, + VARIANT version, VARIANT_BOOL *pfHasFeature) +{ + HTMLDOMImplementation *This = impl_from_IHTMLDOMImplementation(iface); + + FIXME("(%p)->(%s %s %p) returning false\n", This, debugstr_w(feature), debugstr_variant(&version), pfHasFeature); + + *pfHasFeature = VARIANT_FALSE; + return S_OK; +} + +static const IHTMLDOMImplementationVtbl HTMLDOMImplementationVtbl = { + HTMLDOMImplementation_QueryInterface, + HTMLDOMImplementation_AddRef, + HTMLDOMImplementation_Release, + HTMLDOMImplementation_GetTypeInfoCount, + HTMLDOMImplementation_GetTypeInfo, + HTMLDOMImplementation_GetIDsOfNames, + HTMLDOMImplementation_Invoke, + HTMLDOMImplementation_hasFeature +}; + +static const tid_t HTMLDOMImplementation_iface_tids[] = { + IHTMLDOMImplementation_tid, + 0 +}; +static dispex_static_data_t HTMLDOMImplementation_dispex = { + NULL, + IHTMLDOMImplementation_tid, + NULL, + HTMLDOMImplementation_iface_tids +}; + +HRESULT create_dom_implementation(IHTMLDOMImplementation **ret) +{ + HTMLDOMImplementation *dom_implementation; + + dom_implementation = heap_alloc_zero(sizeof(*dom_implementation)); + if(!dom_implementation) + return E_OUTOFMEMORY; + + dom_implementation->IHTMLDOMImplementation_iface.lpVtbl = &HTMLDOMImplementationVtbl; + dom_implementation->ref = 1; + + init_dispex(&dom_implementation->dispex, (IUnknown*)&dom_implementation->IHTMLDOMImplementation_iface, + &HTMLDOMImplementation_dispex); + + *ret = &dom_implementation->IHTMLDOMImplementation_iface; + return S_OK; +} + static inline OmHistory *impl_from_IOmHistory(IOmHistory *iface) { return CONTAINING_RECORD(iface, OmHistory, IOmHistory_iface); diff --git a/dll/win32/mshtml/pluginhost.h b/dll/win32/mshtml/pluginhost.h index 5cc5ad0f553..bbf44899470 100644 --- a/dll/win32/mshtml/pluginhost.h +++ b/dll/win32/mshtml/pluginhost.h @@ -16,6 +16,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#pragma once + typedef struct HTMLPluginContainer HTMLPluginContainer; typedef struct PHEventSink PHEventSink; diff --git a/dll/win32/mshtml/propbag.c b/dll/win32/mshtml/propbag.c index d0595d0740f..501018f912d 100644 --- a/dll/win32/mshtml/propbag.c +++ b/dll/win32/mshtml/propbag.c @@ -253,15 +253,18 @@ static const IPropertyBag2Vtbl PropertyBag2Vtbl = { static HRESULT fill_props(nsIDOMHTMLElement *nselem, PropertyBag *prop_bag) { - nsIDOMHTMLParamElement *nsparam; + const PRUnichar *name, *value; nsAString name_str, value_str; nsIDOMHTMLCollection *params; + nsIDOMHTMLElement *param_elem; UINT32 length, i; nsIDOMNode *nsnode; nsresult nsres; HRESULT hres = S_OK; + static const PRUnichar nameW[] = {'n','a','m','e',0}; static const PRUnichar paramW[] = {'p','a','r','a','m',0}; + static const PRUnichar valueW[] = {'v','a','l','u','e',0}; nsAString_InitDepend(&name_str, paramW); nsres = nsIDOMHTMLElement_GetElementsByTagName(nselem, &name_str, ¶ms); @@ -280,31 +283,25 @@ static HRESULT fill_props(nsIDOMHTMLElement *nselem, PropertyBag *prop_bag) break; } - nsres = nsIDOMNode_QueryInterface(nsnode, &IID_nsIDOMHTMLParamElement, (void**)&nsparam); + nsres = nsIDOMNode_QueryInterface(nsnode, &IID_nsIDOMHTMLElement, (void**)¶m_elem); nsIDOMNode_Release(nsnode); if(NS_FAILED(nsres)) { hres = E_FAIL; break; } - nsAString_Init(&name_str, NULL); - nsres = nsIDOMHTMLParamElement_GetName(nsparam, &name_str); + nsres = get_elem_attr_value(param_elem, nameW, &name_str, &name); if(NS_SUCCEEDED(nsres)) { - nsAString_Init(&value_str, NULL); - nsres = nsIDOMHTMLParamElement_GetValue(nsparam, &value_str); + nsres = get_elem_attr_value(param_elem, valueW, &value_str, &value); if(NS_SUCCEEDED(nsres)) { - const PRUnichar *name, *value; - - nsAString_GetData(&name_str, &name); - nsAString_GetData(&value_str, &value); - hres = add_prop(prop_bag, name, value); + nsAString_Finish(&value_str); } - nsAString_Finish(&value_str); + + nsAString_Finish(&name_str); } - nsAString_Finish(&name_str); - nsIDOMHTMLParamElement_Release(nsparam); + nsIDOMHTMLElement_Release(param_elem); if(FAILED(hres)) break; if(NS_FAILED(nsres)) { diff --git a/dll/win32/mshtml/script.c b/dll/win32/mshtml/script.c index 0a92def95ce..d3937c71155 100644 --- a/dll/win32/mshtml/script.c +++ b/dll/win32/mshtml/script.c @@ -764,7 +764,7 @@ static void parse_script_elem(ScriptHost *script_host, HTMLScriptElement *script return; } }else { - ERR("GetAttribute(event) failed: %08x\n", nsres); + ERR("GetEvent failed: %08x\n", nsres); } nsAString_Finish(&event_str); @@ -829,7 +829,8 @@ static BOOL get_guid_from_language(LPCWSTR type, GUID *guid) static BOOL get_script_guid(HTMLInnerWindow *window, nsIDOMHTMLScriptElement *nsscript, GUID *guid) { - nsAString attr_str, val_str; + const PRUnichar *language; + nsAString val_str; BOOL ret = FALSE; nsresult nsres; @@ -851,26 +852,17 @@ static BOOL get_script_guid(HTMLInnerWindow *window, nsIDOMHTMLScriptElement *ns ERR("GetType failed: %08x\n", nsres); } - nsAString_InitDepend(&attr_str, languageW); - nsres = nsIDOMHTMLScriptElement_GetAttribute(nsscript, &attr_str, &val_str); - nsAString_Finish(&attr_str); + nsres = get_elem_attr_value((nsIDOMHTMLElement*)nsscript, languageW, &val_str, &language); if(NS_SUCCEEDED(nsres)) { - const PRUnichar *language; - - nsAString_GetData(&val_str, &language); - if(*language) { ret = get_guid_from_language(language, guid); }else { *guid = get_default_script_guid(window); ret = TRUE; } - }else { - ERR("GetAttribute(language) failed: %08x\n", nsres); + nsAString_Finish(&val_str); } - nsAString_Finish(&val_str); - return ret; } diff --git a/dll/win32/msimg32/msimg32_main.c b/dll/win32/msimg32/msimg32_main.c index 80df7fe225a..d5198b1dbce 100644 --- a/dll/win32/msimg32/msimg32_main.c +++ b/dll/win32/msimg32/msimg32_main.c @@ -28,18 +28,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(msimg32); -/*********************************************************************** - * DllInitialize (MSIMG32.@) - * - * MSIMG32 initialisation routine. - */ -BOOL WINAPI DllMain( HINSTANCE inst, DWORD reason, LPVOID reserved ) -{ - if (reason == DLL_PROCESS_ATTACH) DisableThreadLibraryCalls( inst ); - return TRUE; -} - - /****************************************************************************** * vSetDdrawflag (MSIMG32.@) */ diff --git a/dll/win32/msisip/main.c b/dll/win32/msisip/main.c index a7180d10737..421e9ab1c4e 100644 --- a/dll/win32/msisip/main.c +++ b/dll/win32/msisip/main.c @@ -85,6 +85,7 @@ HRESULT WINAPI DllRegisterServer(void) prov.pwszVerifyFuncName = verifyIndirectData; prov.pwszRemoveFuncName = removeSignedDataMsg; prov.pwszIsFunctionNameFmt2 = isMyTypeOfFile; + prov.pwszGetCapFuncName = NULL; return CryptSIPAddProvider(&prov) ? S_OK : S_FALSE; } diff --git a/dll/win32/msrle32/lang/msrle_Da.rc b/dll/win32/msrle32/lang/msrle_Da.rc index f2835a0cb2c..a6016770e44 100644 --- a/dll/win32/msrle32/lang/msrle_Da.rc +++ b/dll/win32/msrle32/lang/msrle_Da.rc @@ -26,5 +26,5 @@ STRINGTABLE { IDS_NAME "WINE-MS-RLE" IDS_DESCRIPTION "Wine MS-RLE videokodeks" - IDS_ABOUT "Wine MS-RLE videokodeks\nOphavsret 2002 tilhrer Michael Gnnewig" + IDS_ABOUT "Wine MS-RLE videokodeks\nOphavsret 2002 tilhrer Michael Gnnewig" } diff --git a/dll/win32/msrle32/lang/msrle_Ro.rc b/dll/win32/msrle32/lang/msrle_Ro.rc index 90ec4f2a2d4..d0ac98670f3 100644 --- a/dll/win32/msrle32/lang/msrle_Ro.rc +++ b/dll/win32/msrle32/lang/msrle_Ro.rc @@ -25,7 +25,7 @@ LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL STRINGTABLE { - IDS_NAME "WINE-MS-RLE" - IDS_DESCRIPTION "Codecul video Wine MS-RLE" - IDS_ABOUT "Codecul video Wine MS-RLE\nCopyright 2002 by Michael Günnewig" + IDS_NAME "WINE-MS-RLE" + IDS_DESCRIPTION "Codecul video Wine MS-RLE" + IDS_ABOUT "Codecul video Wine MS-RLE\nCopyright 2002 by Michael Günnewig" } diff --git a/dll/win32/msvfw32/drawdib.c b/dll/win32/msvfw32/drawdib.c index cc22b4444ef..9253278cc54 100644 --- a/dll/win32/msvfw32/drawdib.c +++ b/dll/win32/msvfw32/drawdib.c @@ -236,9 +236,18 @@ BOOL VFWAPI DrawDibBegin(HDRAWDIB hdd, DWORD dwSize; /* No compression */ TRACE("Not compressed!\n"); - dwSize = lpbi->biSize + num_colours(lpbi)*sizeof(RGBQUAD); - whdd->lpbiOut = HeapAlloc(GetProcessHeap(), 0, dwSize); - memcpy(whdd->lpbiOut, lpbi, dwSize); + if (lpbi->biHeight <= 0) + { + /* we don't draw inverted DIBs */ + TRACE("detected inverted DIB\n"); + ret = FALSE; + } + else + { + dwSize = lpbi->biSize + num_colours(lpbi)*sizeof(RGBQUAD); + whdd->lpbiOut = HeapAlloc(GetProcessHeap(), 0, dwSize); + memcpy(whdd->lpbiOut, lpbi, dwSize); + } } if (ret) @@ -322,6 +331,8 @@ BOOL VFWAPI DrawDibDraw(HDRAWDIB hdd, HDC hdc, { TRACE("Something changed!\n"); ret = DrawDibBegin(hdd, hdc, dxDst, dyDst, lpbi, dxSrc, dySrc, 0); + if (!ret) + return ret; } #undef CHANGED @@ -334,12 +345,6 @@ BOOL VFWAPI DrawDibDraw(HDRAWDIB hdd, HDC hdc, if (!(wFlags & DDF_UPDATE)) { - DWORD biSizeImage = lpbi->biSizeImage; - - /* biSizeImage may be set to 0 for BI_RGB (uncompressed) bitmaps */ - if ((lpbi->biCompression == BI_RGB) && (biSizeImage == 0)) - biSizeImage = ((lpbi->biWidth * lpbi->biBitCount + 31) / 32) * 4 * lpbi->biHeight; - if (lpbi->biCompression) { DWORD flags = 0; @@ -353,6 +358,8 @@ BOOL VFWAPI DrawDibDraw(HDRAWDIB hdd, HDC hdc, } else { + /* BI_RGB: lpbi->biSizeImage isn't reliable */ + DWORD biSizeImage = ((lpbi->biWidth * lpbi->biBitCount + 31) / 32) * 4 * lpbi->biHeight; memcpy(whdd->lpvbits, lpBits, biSizeImage); } } diff --git a/dll/win32/msvfw32/lang/msvfw32_Da.rc b/dll/win32/msvfw32/lang/msvfw32_Da.rc index a5eb41d343a..331dcd458fd 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Da.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Da.rc @@ -20,34 +20,34 @@ LANGUAGE LANG_DANISH, SUBLANG_DEFAULT -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Video komprimering" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK",IDOK,129,2,49,14 - PUSHBUTTON "Annuller",IDCANCEL,129,18,49,14 - - LTEXT "&Komprimerer:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "&Opstning...",882,129,36,49,14 - PUSHBUTTON "O&m...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "Komprimeringskvalite&t:",886,9,34,80,8 - - CONTROL "Keyframe for hvert",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "billede",889,103,62,26,10 - - CONTROL "&Datahastighed",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/s",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Fulde billeder (ukomprimeret)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Video komprimering" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "Annuller",IDCANCEL,154,18,52,14 + + LTEXT "&Komprimerer:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "&Opstning...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "O&m...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "Komprimeringskvalite&t:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "Keyframe for hvert",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "billede",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Datahastighed",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/s",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_De.rc b/dll/win32/msvfw32/lang/msvfw32_De.rc index 0024db45e25..4aa4f562504 100644 --- a/dll/win32/msvfw32/lang/msvfw32_De.rc +++ b/dll/win32/msvfw32/lang/msvfw32_De.rc @@ -21,34 +21,34 @@ LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Videokompression" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK",IDOK,129,2,49,14 - PUSHBUTTON "Abbrechen",IDCANCEL,129,18,49,14 - - LTEXT "&Komprimierer:",-1,9,6,105,8 - 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 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "Komprimierungsqualität:",886,9,34,80,8 - - CONTROL "Ein &Key-Frame alle",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "Frames",889,103,62,26,10 - - CONTROL "&Datenrate",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 { IDS_FULLFRAMES "Vollständige Frames (Unkomprimiert)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Videokompression" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "Abbrechen",IDCANCEL,154,18,52,14 + + LTEXT "&Komprimierer:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "Kon&figurieren",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&Über...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "Komprimierungsqualität:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "Ein &Key-Frame alle",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "Frames",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Datenrate",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "kB/Sek",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_En.rc b/dll/win32/msvfw32/lang/msvfw32_En.rc index e1ed5c35c37..695dc6c13f3 100644 --- a/dll/win32/msvfw32/lang/msvfw32_En.rc +++ b/dll/win32/msvfw32/lang/msvfw32_En.rc @@ -18,34 +18,34 @@ LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Video Compression" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK",IDOK,129,2,49,14 - PUSHBUTTON "Cancel",IDCANCEL,129,18,49,14 - - LTEXT "&Compressor:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "Con&figure...",882,129,36,49,14 - PUSHBUTTON "&About...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "Compression &Quality:",886,9,34,80,8 - - CONTROL "&Key Frame Every",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "frames",889,103,62,26,10 - - CONTROL "&Data Rate",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/sec",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Full Frames (Uncompressed)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Video Compression" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "Cancel",IDCANCEL,154,18,52,14 + + LTEXT "&Compressor:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "Con&figure...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&About",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "Compression &Quality:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "&Key Frame Every",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "frames",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Data Rate",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "kB/s",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Es.rc b/dll/win32/msvfw32/lang/msvfw32_Es.rc index 813463d8c2b..418dde10842 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Es.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Es.rc @@ -21,34 +21,34 @@ LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Compresión de vídeo" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "Aceptar",IDOK,129,2,49,14 - PUSHBUTTON "Cancelar",IDCANCEL,129,18,49,14 - - LTEXT "&Compresor:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "C&onfigurar...",882,129,36,49,14 - PUSHBUTTON "&Acerca de...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "C&alidad de compresión:",886,9,34,80,8 - - CONTROL "C&uadro clave cada",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "cuadros",889,103,62,26,10 - - CONTROL "&Tasa de datos",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/s",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Cuadros completos (no comprimidos)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Compresión de vídeo" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "Aceptar",IDOK,154,2,52,14 + PUSHBUTTON "Cancelar",IDCANCEL,154,18,52,14 + + LTEXT "&Compresor:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "C&onfigurar...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&Acerca de...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "C&alidad de compresión:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "C&uadro clave cada",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "cuadros",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Tasa de datos",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/s",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Fr.rc b/dll/win32/msvfw32/lang/msvfw32_Fr.rc index 28b2841dc90..d216d0f06c9 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Fr.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Fr.rc @@ -21,34 +21,34 @@ LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 208, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Compression vidéo" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK",IDOK,150,2,49,14 - PUSHBUTTON "Annuler",IDCANCEL,150,18,49,14 - - LTEXT "&Compresseur :",-1,9,6,131,8 - COMBOBOX 880,9,16,135,15,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "Con&figurer...",882,150,36,49,14 - PUSHBUTTON "À &propos",883,150,52,49,14 - - SCROLLBAR 884,9,44,133,9,WS_TABSTOP - - LTEXT "&Qualité de compression :",886,9,34,131,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 "&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 -} - STRINGTABLE { IDS_FULLFRAMES "Images complètes (non compressées)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Compression vidéo" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "Annuler",IDCANCEL,154,18,52,14 + + LTEXT "&Compresseur :",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "Con&figurer...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "À &propos",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "&Qualité de compression :",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "Image &clé toutes les",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "images",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Débit de données",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "Kio/sec",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_He.rc b/dll/win32/msvfw32/lang/msvfw32_He.rc index 0394c0e0888..df91befc237 100644 --- a/dll/win32/msvfw32/lang/msvfw32_He.rc +++ b/dll/win32/msvfw32/lang/msvfw32_He.rc @@ -20,34 +20,34 @@ LANGUAGE LANG_HEBREW, SUBLANG_DEFAULT -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "דחיסת וידאו" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "אישור",IDOK,129,2,49,14 - PUSHBUTTON "ביטול",IDCANCEL,129,18,49,14 - - LTEXT "דוחס:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "הגדרה...",882,129,36,49,14 - PUSHBUTTON "אודות...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "איכות דחיסה:",886,9,34,80,8 - - CONTROL "&Key Frame Every",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "שקופיות:",889,103,62,26,10 - - CONTROL "קצב מידע",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "ק""ב/שניה",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "שקופיות מלאות (לא דחוס)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "דחיסת וידאו" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "אישור",IDOK,154,2,52,14 + PUSHBUTTON "ביטול",IDCANCEL,154,18,52,14 + + LTEXT "דוחס:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "הגדרה...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "אודות...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "איכות דחיסה:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "&Key Frame Every",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "שקופיות:",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "קצב מידע",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "ק""ב/שניה",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Hu.rc b/dll/win32/msvfw32/lang/msvfw32_Hu.rc index 7038ed0d514..2e46f697317 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Hu.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Hu.rc @@ -18,34 +18,34 @@ LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Video tmrts" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK",IDOK,129,2,49,14 - PUSHBUTTON "Mgse",IDCANCEL,129,18,49,14 - - LTEXT "&Tmrt:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "Bell&ts...",882,129,36,49,14 - PUSHBUTTON "&About...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "Tmrtsi mins&g:",886,9,34,80,8 - - CONTROL "&Kulcs kpkocka minden",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "kpkocknknt",889,103,62,26,10 - - CONTROL "A&dat arny",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/sec",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Teljes kpkockk (tmrtetlen)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Video tmrts" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "Mgse",IDCANCEL,154,18,52,14 + + LTEXT "&Tmrt:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "Bell&ts...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&About",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "Tmrtsi mins&g:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "&Kulcs kpkocka minden",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "kpkocknknt",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "A&dat arny",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/sec",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_It.rc b/dll/win32/msvfw32/lang/msvfw32_It.rc index 67481e5b68c..c0c81af039c 100644 --- a/dll/win32/msvfw32/lang/msvfw32_It.rc +++ b/dll/win32/msvfw32/lang/msvfw32_It.rc @@ -21,34 +21,34 @@ LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Compressione video" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK",IDOK,129,2,49,14 - PUSHBUTTON "Annulla",IDCANCEL,129,18,49,14 - - LTEXT "&Compressore:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "Con&figura...",882,129,36,49,14 - PUSHBUTTON "&Informazioni...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "&Qualità della compressione:",886,9,34,80,8 - - CONTROL "&Key Frame Every",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "frames",889,103,62,26,10 - - CONTROL "&Data Rate",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/sec",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Frames completi (non compresso)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Compressione video" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "Annulla",IDCANCEL,154,18,52,14 + + LTEXT "&Compressore:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "Con&figura...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&Informazioni...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "&Qualità della compressione:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "&Key Frame Every",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "frames",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Data Rate",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/sec",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Ko.rc b/dll/win32/msvfw32/lang/msvfw32_Ko.rc index aaf0ae67689..d5c0ad3f8a6 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Ko.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Ko.rc @@ -19,34 +19,34 @@ LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION " " -FONT 9, "MS Shell Dlg" -{ - DEFPUSHBUTTON "Ȯ",IDOK,129,2,49,14 - PUSHBUTTON "",IDCANCEL,129,18,49,14 - - LTEXT "(&C):",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "(&F)...",882,129,36,49,14 - PUSHBUTTON "(&A)...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT " ǰ(&Q):",886,9,34,80,8 - - CONTROL " Ű (&K)",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "",889,103,62,26,10 - - CONTROL "Ÿ (&D)",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/sec",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "ä ()" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION " " +FONT 9, "MS Shell Dlg" +{ + DEFPUSHBUTTON "Ȯ",IDOK,154,2,52,14 + PUSHBUTTON "",IDCANCEL,154,18,52,14 + + LTEXT "(&C):",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "(&F)...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "(&A)...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT " ǰ(&Q):",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL " Ű (&K)",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "Ÿ (&D)",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/sec",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Lt.rc b/dll/win32/msvfw32/lang/msvfw32_Lt.rc index 2db5576097d..5729d4d6220 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Lt.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Lt.rc @@ -21,34 +21,34 @@ LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL -ICM_CHOOSE_COMPRESSOR DIALOG 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 { IDS_FULLFRAMES "Pilni kadrai (neglaudinti)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Vaizdų glaudinimas" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "Gerai",IDOK,154,2,52,14 + PUSHBUTTON "Atsisakyti",IDCANCEL,154,18,52,14 + + LTEXT "&Metodas:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "Kon&figūruoti...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&Apie...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "Glaudinimo &kokybė:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "&Rakt. kadras kas",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "kadrų",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Duomenų sparta",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/sek",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Nl.rc b/dll/win32/msvfw32/lang/msvfw32_Nl.rc index e0372596c50..946708c0485 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Nl.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Nl.rc @@ -18,34 +18,34 @@ LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Video Compressie" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK",IDOK,129,2,49,14 - PUSHBUTTON "Annuleren",IDCANCEL,129,18,49,14 - - LTEXT "&Compressor:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "Con&figureer...",882,129,36,49,14 - PUSHBUTTON "&Over...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "Compressie &Kwaliteit:",886,9,34,80,8 - - CONTROL "&Key Frame Elke",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "frames",889,103,62,26,10 - - CONTROL "&Data Snelheid",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/sec",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Volledige Frames (Ongecomprimeerd)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Video Compressie" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "Annuleren",IDCANCEL,154,18,52,14 + + LTEXT "&Compressor:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "Con&figureer...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&Over...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "Compressie &Kwaliteit:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "&Key Frame Elke",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "frames",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Data Snelheid",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/sec",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_No.rc b/dll/win32/msvfw32/lang/msvfw32_No.rc index 4dcc1416937..5af2b372d04 100644 --- a/dll/win32/msvfw32/lang/msvfw32_No.rc +++ b/dll/win32/msvfw32/lang/msvfw32_No.rc @@ -18,34 +18,34 @@ LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Videokomprimering" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK",IDOK,129,2,49,14 - PUSHBUTTON "Avbryt",IDCANCEL,129,18,49,14 - - LTEXT "&Komprimerer:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "&Oppsett...",882,129,36,49,14 - PUSHBUTTON "O&m...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "Komprimeringskvalite&t:",886,9,34,80,8 - - CONTROL "N&kkelbilde for hvert",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "bilde",889,103,62,26,10 - - CONTROL "&Datahastighet",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/s",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Fulle bilder (ukomprimert)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Videokomprimering" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "Avbryt",IDCANCEL,154,18,52,14 + + LTEXT "&Komprimerer:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "&Oppsett...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "O&m...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "Komprimeringskvalite&t:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "N&kkelbilde for hvert",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "bilde",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Datahastighet",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/s",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Pl.rc b/dll/win32/msvfw32/lang/msvfw32_Pl.rc index 0a3675e054c..593072a0492 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Pl.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Pl.rc @@ -19,34 +19,34 @@ LANGUAGE LANG_POLISH, SUBLANG_DEFAULT -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 207, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Kompresja wideo" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "&OK",IDOK,146,2,52,14 - PUSHBUTTON "&Anuluj",IDCANCEL,146,18,52,14 - - LTEXT "Typ &kompresji:",-1,9,6,128,8 - COMBOBOX 880,9,16,128,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "Kon&figuruj...",882,146,36,52,14 - PUSHBUTTON "&Informacje...",883,146,52,52,14 - - SCROLLBAR 884,9,44,128,9,WS_TABSTOP - - LTEXT "&Jako kompresji:",886,9,34,97,8 - - CONTROL "&Ramka kluczowa co",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,81,12 - EDITTEXT 888,88,60,22,12 - LTEXT "ramek",889,114,62,31,10 - - CONTROL "&Strumie",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,81,12 - EDITTEXT 895,88,76,22,12 - LTEXT "KB/s",896,114,78,31,10 -} - STRINGTABLE { IDS_FULLFRAMES "Pene ramki (bez kompresji)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Kompresja wideo" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "&Anuluj",IDCANCEL,154,18,52,14 + + LTEXT "Typ &kompresji:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "Kon&figuruj...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&Informacje...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "&Jako kompresji:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "&Ramka kluczowa co",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "ramek",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Strumie",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/s",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Pt.rc b/dll/win32/msvfw32/lang/msvfw32_Pt.rc index e6b4f9b3022..681129c8357 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Pt.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Pt.rc @@ -18,34 +18,34 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Compresso de vdeo" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK",IDOK,129,2,49,14 - PUSHBUTTON "Cancelar",IDCANCEL,129,18,49,14 - - LTEXT "&Compressor:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "Con&figurar...",882,129,36,49,14 - PUSHBUTTON "&Sobre...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "&Qualidade de compresso:",886,9,34,80,8 - - CONTROL "&Imagem chave todos os",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "frames",889,103,62,26,10 - - CONTROL "&Cadncia de dados",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/sec",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Imagens Completas (Descomprimidas)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Compresso de vdeo" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "Cancelar",IDCANCEL,154,18,52,14 + + LTEXT "&Compressor:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "Con&figurar...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&Sobre...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "&Qualidade de compresso:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "&Imagem chave todos os",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "frames",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Cadncia de dados",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/sec",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Ro.rc b/dll/win32/msvfw32/lang/msvfw32_Ro.rc index 2f6e5934e18..687b50c4805 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Ro.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Ro.rc @@ -19,38 +19,38 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL - #pragma code_page(65001) -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 200, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Compresie video" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "Con&firmă", IDOK,140,2,51,14 - PUSHBUTTON "A&nulează", IDCANCEL,140,18,51,14 - - LTEXT "Co&mpresor:", -1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "&Configurare…", 882,140,36,51,14 - PUSHBUTTON "&Despre…", 883,140,52,51,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "C&alitatea compresiei:", 886,9,34,80,8 - - CONTROL "Cadru c&heie la fiecare", 887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,82,12 - EDITTEXT 888,93,60,22,12 - LTEXT "cadre", 889,118,62,22,10 - - CONTROL "&Rata de date", 894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,70,12 - EDITTEXT 895,93,76,22,12 - LTEXT "ko/s", 896,118,78,22,10 -} +LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL STRINGTABLE { IDS_FULLFRAMES "Cadre întregi (necomprimate)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Compresie video" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "Con&firmă",IDOK,154,2,52,14 + PUSHBUTTON "A&nulează",IDCANCEL,154,18,52,14 + + LTEXT "Co&mpresor:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "&Configurare…",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&Despre…",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "C&alitatea compresiei:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "Cadru c&heie la fiecare",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "cadre",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Rata de date",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "ko/s",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Ru.rc b/dll/win32/msvfw32/lang/msvfw32_Ru.rc index 66520158a8c..4bedeacc346 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Ru.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Ru.rc @@ -21,34 +21,34 @@ LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Сжатие видео" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK",IDOK,129,2,49,14 - PUSHBUTTON "Отмена",IDCANCEL,129,18,49,14 - - LTEXT "&Алгоритм сжатия:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "&Настройки...",882,129,36,49,14 - PUSHBUTTON "&Информация...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "&Качество сжатия:",886,9,34,80,8 - - CONTROL "Кл&ючевой кадр каждые",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "кадр(ов)",889,103,62,26,10 - - CONTROL "&Поток данных",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "КБ/сек",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Кадры целиком (Без компрессии)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Сжатие видео" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "Отмена",IDCANCEL,154,18,52,14 + + LTEXT "&Алгоритм сжатия:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "&Настройки...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&Информация...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "&Качество сжатия:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "Кл&ючевой кадр каждые",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "кадр(ов)",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Поток данных",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "КБ/сек",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Si.rc b/dll/win32/msvfw32/lang/msvfw32_Si.rc index 2cd211d3efe..ff374cb9d82 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Si.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Si.rc @@ -20,34 +20,34 @@ LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Stiskanje videa" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "V redu",IDOK,129,2,49,14 - PUSHBUTTON "Prekliči",IDCANCEL,129,18,49,14 - - LTEXT "&Kodek za stiskanje:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "&Nastavitve ...",882,129,36,49,14 - PUSHBUTTON "&O ...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "Kakovost &stiskanja:",886,9,34,80,8 - - CONTROL "&Ključna slika na vsakih",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "slik",889,103,62,26,10 - - CONTROL "&Pretok podatkov",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "kb/s",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Polne slike (nestisnjeno)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Stiskanje videa" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "V redu",IDOK,154,2,52,14 + PUSHBUTTON "Prekliči",IDCANCEL,154,18,52,14 + + LTEXT "&Kodek za stiskanje:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "&Nastavitve ...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&O ...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "Kakovost &stiskanja:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "&Ključna slika na vsakih",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "slik",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Pretok podatkov",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "kb/s",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Sq.rc b/dll/win32/msvfw32/lang/msvfw32_Sq.rc index 425b7a28b17..db459254160 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Sq.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Sq.rc @@ -21,34 +21,34 @@ LANGUAGE LANG_ALBANIAN, SUBLANG_NEUTRAL -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Video Ngjeshje" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK",IDOK,129,2,49,14 - PUSHBUTTON "Anulo",IDCANCEL,129,18,49,14 - - LTEXT "Ngjeshje:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "Kon&figuro...",882,129,36,49,14 - PUSHBUTTON "Rreth...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "Kualitet Ngjeshje:",886,9,34,80,8 - - CONTROL "Frame çdo çeles",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "frames",889,103,62,26,10 - - CONTROL "&Data Rate",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/sec",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Frames te plote (pa-gnjeshur)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Video Ngjeshje" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "Anulo",IDCANCEL,154,18,52,14 + + LTEXT "Ngjeshje:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "Kon&figuro...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "Rreth...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "Kualitet Ngjeshje:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "Frame çdo çeles",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "frames",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Data Rate",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/sec",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Sv.rc b/dll/win32/msvfw32/lang/msvfw32_Sv.rc index c329279ec88..48d77729cc2 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Sv.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Sv.rc @@ -18,34 +18,34 @@ LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Videokomprimering" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK",IDOK,129,2,49,14 - PUSHBUTTON "Avbryt",IDCANCEL,129,18,49,14 - - LTEXT "&Komprimering:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "Kon&figurera...",882,129,36,49,14 - PUSHBUTTON "&Om...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "Komprimeringsk&valitet:",886,9,34,80,8 - - CONTROL "&Nyckelbildrutor varje",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "frames",889,103,62,26,10 - - CONTROL "&Datafrekvens",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/s",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Hela bildrutor (okomprimerat)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Videokomprimering" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "Avbryt",IDCANCEL,154,18,52,14 + + LTEXT "&Komprimering:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "Kon&figurera...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&Om...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "Komprimeringsk&valitet:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "&Nyckelbildrutor varje",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "frames",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Datafrekvens",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/s",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Tr.rc b/dll/win32/msvfw32/lang/msvfw32_Tr.rc index bd9761837ca..6aaa96a3cd2 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Tr.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Tr.rc @@ -20,34 +20,34 @@ LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Vidyo Sıkıştırma" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "Tamam",IDOK,129,2,49,14 - PUSHBUTTON "İptal",IDCANCEL,129,18,49,14 - - LTEXT "&Sıkıştırıcı:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "&Yapılandır...",882,129,36,49,14 - PUSHBUTTON "&Üzerine...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "S&ıkıştırma Niteliği:",886,9,34,80,8 - - CONTROL "&Her Anahtar Kare",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "kare",889,103,62,26,10 - - CONTROL "&Veri Oranı",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/sn",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Tüm Kareler (Sıkıştırılmamış)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Vidyo Sıkıştırma" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "Tamam",IDOK,154,2,52,14 + PUSHBUTTON "İptal",IDCANCEL,154,18,52,14 + + LTEXT "&Sıkıştırıcı:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "&Yapılandır...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&Üzerine...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "S&ıkıştırma Niteliği:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "&Her Anahtar Kare",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "kare",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Veri Oranı",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/sn",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Uk.rc b/dll/win32/msvfw32/lang/msvfw32_Uk.rc index 38828690d06..762bfcd5531 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Uk.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Uk.rc @@ -22,34 +22,34 @@ LANGUAGE LANG_UKRAINIAN, SUBLANG_DEFAULT -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "Стиснення Відео" -FONT 8, "MS Shell Dlg" -{ - DEFPUSHBUTTON "OK",IDOK,129,2,49,14 - PUSHBUTTON "Скасувати",IDCANCEL,129,18,49,14 - - LTEXT "&Алгоритм стиснення:",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "Налаштува&ти...",882,129,36,49,14 - PUSHBUTTON "&Інформація...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "&Якість Стиснення:",886,9,34,80,8 - - CONTROL "&Ключовий кадр кожні",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "кадрів",889,103,62,26,10 - - CONTROL "&Потік даних",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/sec",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "Кадри повністю (Без стиснення)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Стиснення Відео" +FONT 8, "MS Shell Dlg" +{ + DEFPUSHBUTTON "OK",IDOK,154,2,52,14 + PUSHBUTTON "Скасувати",IDCANCEL,154,18,52,14 + + LTEXT "&Алгоритм стиснення:",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "Налаштува&ти...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "&Інформація...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "&Якість Стиснення:",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "&Ключовий кадр кожні",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "кадрів",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "&Потік даних",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/sec",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/lang/msvfw32_Zh.rc b/dll/win32/msvfw32/lang/msvfw32_Zh.rc index 92ba6362ea1..48246a9d15c 100644 --- a/dll/win32/msvfw32/lang/msvfw32_Zh.rc +++ b/dll/win32/msvfw32/lang/msvfw32_Zh.rc @@ -23,68 +23,68 @@ LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 -STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "视频压缩" -FONT 9, "MS Shell Dlg" -{ - DEFPUSHBUTTON "确定",IDOK,129,2,49,14 - PUSHBUTTON "取消",IDCANCEL,129,18,49,14 - - LTEXT "压缩器(&C):",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - - PUSHBUTTON "配置(&F)...",882,129,36,49,14 - PUSHBUTTON "关于(&A)...",883,129,52,49,14 - - SCROLLBAR 884,9,44,111,9,WS_TABSTOP - - LTEXT "压缩质量(&Q):",886,9,34,80,8 - - CONTROL "关键帧/每(&K)",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "帧",889,103,62,26,10 - - CONTROL "数据速度(&D)",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/sec",896,102,78,26,10 -} - STRINGTABLE { IDS_FULLFRAMES "全帧(未压缩)" } -LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_TRADITIONAL - -ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 187, 95 +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU -CAPTION "視頻壓縮" +CAPTION "视频压缩" FONT 9, "MS Shell Dlg" { - DEFPUSHBUTTON "確定",IDOK,129,2,49,14 - PUSHBUTTON "取消",IDCANCEL,129,18,49,14 + DEFPUSHBUTTON "确定",IDOK,154,2,52,14 + PUSHBUTTON "取消",IDCANCEL,154,18,52,14 - LTEXT "壓縮器(&C):",-1,9,6,105,8 - COMBOBOX 880,9,16,111,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + LTEXT "压缩器(&C):",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP - PUSHBUTTON "配置(&F)...",882,129,36,49,14 - PUSHBUTTON "關於(&A)...",883,129,52,49,14 + PUSHBUTTON "配置(&F)...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "关于(&A)...",IDC_ABOUT,154,52,52,14 - SCROLLBAR 884,9,44,111,9,WS_TABSTOP + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP - LTEXT "壓縮質量(&Q):",886,9,34,80,8 + LTEXT "压缩质量(&Q):",IDC_QUALITY_TXT,9,34,135,8 - CONTROL "關鍵幀/每(&K)",887,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,66,12 - EDITTEXT 888,78,60,22,12 - LTEXT "幀",889,103,62,26,10 + CONTROL "关键帧/每(&K)",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "帧",IDC_KEYFRAME_FRAMES,123,62,26,10 - CONTROL "數據速度(&D)",894,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,66,12 - EDITTEXT 895,78,76,22,12 - LTEXT "KB/sec",896,102,78,26,10 + CONTROL "数据速度(&D)",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/sec",IDC_DATARATE_KB,123,78,26,10 } +LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_TRADITIONAL + STRINGTABLE { IDS_FULLFRAMES "全幀(未壓縮)" } + +ICM_CHOOSE_COMPRESSOR DIALOG 36, 24, 210, 95 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "視頻壓縮" +FONT 9, "MS Shell Dlg" +{ + DEFPUSHBUTTON "確定",IDOK,154,2,52,14 + PUSHBUTTON "取消",IDCANCEL,154,18,52,14 + + LTEXT "壓縮器(&C):",-1,9,6,135,8 + COMBOBOX IDC_COMP_LIST,9,16,135,67,CBS_DROPDOWNLIST|WS_VSCROLL|WS_TABSTOP + + PUSHBUTTON "配置(&F)...",IDC_CONFIGURE,154,36,52,14 + PUSHBUTTON "關於(&A)...",IDC_ABOUT,154,52,52,14 + + SCROLLBAR IDC_QUALITY_SCROLL,9,44,135,10,WS_TABSTOP + + LTEXT "壓縮質量(&Q):",IDC_QUALITY_TXT,9,34,135,8 + + CONTROL "關鍵幀/每(&K)",IDC_KEYFRAME_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,60,86,12 + EDITTEXT IDC_KEYFRAME,98,60,22,12 + LTEXT "幀",IDC_KEYFRAME_FRAMES,123,62,26,10 + + CONTROL "數據速度(&D)",IDC_DATARATE_CHECKBOX,"Button",BS_AUTOCHECKBOX|WS_TABSTOP,9,76,86,12 + EDITTEXT IDC_DATARATE,98,76,22,12 + LTEXT "KB/sec",IDC_DATARATE_KB,123,78,26,10 +} diff --git a/dll/win32/msvfw32/msvideo_main.c b/dll/win32/msvfw32/msvideo_main.c index 0b6442003ce..f76b42aa2f1 100644 --- a/dll/win32/msvfw32/msvideo_main.c +++ b/dll/win32/msvfw32/msvideo_main.c @@ -59,7 +59,7 @@ struct _reg_driver static reg_driver* reg_driver_list = NULL; -/* This one is a macro such that it works for both ASCII and Unicode */ +/* This one is a macro in order to work for both ASCII and Unicode */ #define fourcc_to_string(str, fcc) do { \ (str)[0] = LOBYTE(LOWORD(fcc)); \ (str)[1] = HIBYTE(LOWORD(fcc)); \ diff --git a/dll/win32/msvfw32/msvideo_private.h b/dll/win32/msvfw32/msvideo_private.h index f06d4f17de6..f0afd711d05 100644 --- a/dll/win32/msvfw32/msvideo_private.h +++ b/dll/win32/msvfw32/msvideo_private.h @@ -34,7 +34,6 @@ #include #define ICM_CHOOSE_COMPRESSOR 1 -#define IDC_COMP_LIST 880 /* HIC struct (same layout as Win95 one) */ typedef struct tagWINE_HIC { diff --git a/dll/win32/msvfw32/resource.h b/dll/win32/msvfw32/resource.h index 2309c61014c..fae893b73fb 100644 --- a/dll/win32/msvfw32/resource.h +++ b/dll/win32/msvfw32/resource.h @@ -18,6 +18,7 @@ #pragma once +#define IDC_COMP_LIST 880 #define IDS_FULLFRAMES 901 #define IDC_CONFIGURE 882 diff --git a/dll/win32/msxml/Makefile.in b/dll/win32/msxml/Makefile.in deleted file mode 100644 index a50888d1f59..00000000000 --- a/dll/win32/msxml/Makefile.in +++ /dev/null @@ -1,9 +0,0 @@ -MODULE = msxml.dll - -C_SRCS = main.c - -IDL_TLB_SRCS = msxml_tlb.idl - -RC_SRCS = rsrc.rc - -@MAKE_DLL_RULES@ diff --git a/dll/win32/msxml2/Makefile.in b/dll/win32/msxml2/Makefile.in deleted file mode 100644 index 418de00c7ff..00000000000 --- a/dll/win32/msxml2/Makefile.in +++ /dev/null @@ -1,7 +0,0 @@ -MODULE = msxml2.dll - -C_SRCS = main.c - -IDL_TLB_SRCS = msxml2_tlb.idl - -@MAKE_DLL_RULES@ diff --git a/dll/win32/msxml3/domdoc.c b/dll/win32/msxml3/domdoc.c index 0fca3e0a499..76aa5fb9019 100644 --- a/dll/win32/msxml3/domdoc.c +++ b/dll/win32/msxml3/domdoc.c @@ -1825,12 +1825,18 @@ static HRESULT WINAPI domdoc_createEntityReference( xmlChar* tagName_to_XPath(const BSTR tagName) { xmlChar *query, *tmp; + static const xmlChar everything[] = "/descendant::node()"; static const xmlChar mod_pre[] = "*[local-name()='"; static const xmlChar mod_post[] = "']"; static const xmlChar prefix[] = "descendant::"; const WCHAR *tokBegin, *tokEnd; int len; + /* Special case - empty tagname - means select all nodes, + except document itself. */ + if (!*tagName) + return xmlStrdup(everything); + query = xmlStrdup(prefix); tokBegin = tagName; diff --git a/dll/win32/msxml3/element.c b/dll/win32/msxml3/element.c index 120530c800c..84a23a5a7a7 100644 --- a/dll/win32/msxml3/element.c +++ b/dll/win32/msxml3/element.c @@ -1263,7 +1263,12 @@ static HRESULT WINAPI domelem_setAttribute( xmlFree(local); if (ns) - return xmlStrEqual(ns->href, xml_value) ? S_OK : E_INVALIDARG; + { + int cmp = xmlStrEqual(ns->href, xml_value); + heap_free(xml_value); + heap_free(xml_name); + return cmp ? S_OK : E_INVALIDARG; + } } if (!xmlSetNsProp(element, NULL, xml_name, xml_value)) diff --git a/dll/win32/msxml3/msxml_private.h b/dll/win32/msxml3/msxml_private.h index ee457691000..add547c084c 100644 --- a/dll/win32/msxml3/msxml_private.h +++ b/dll/win32/msxml3/msxml_private.h @@ -205,22 +205,6 @@ static inline LPWSTR heap_strdupW(LPCWSTR str) return ret; } -static inline LPSTR heap_strdupWtoA(LPCWSTR str) -{ - LPSTR ret = NULL; - - if(str) { - DWORD len = WideCharToMultiByte(CP_ACP, 0, str, -1, NULL, 0, NULL, NULL); - ret = heap_alloc(len+1); - if(!ret) - return NULL; - - WideCharToMultiByte(CP_ACP, 0, str, -1, ret, len+1, NULL, NULL); - } - - return ret; -} - /* XSLProcessor parameter list */ struct xslprocessor_par { @@ -560,8 +544,6 @@ HRESULT create_moniker_from_url(LPCWSTR, IMoniker**) DECLSPEC_HIDDEN; HRESULT bind_url(IMoniker*, HRESULT (*onDataAvailable)(void*,char*,DWORD), void*, bsc_t**) DECLSPEC_HIDDEN; HRESULT detach_bsc(bsc_t*) DECLSPEC_HIDDEN; -const char *debugstr_variant(const VARIANT*) DECLSPEC_HIDDEN; - /* Error Codes - not defined anywhere in the public headers */ #define E_XML_ELEMENT_UNDECLARED 0xC00CE00D #define E_XML_ELEMENT_ID_NOT_FOUND 0xC00CE00E diff --git a/dll/win32/msxml3/node.c b/dll/win32/msxml3/node.c index cf15f8585a5..088436a22db 100644 --- a/dll/win32/msxml3/node.c +++ b/dll/win32/msxml3/node.c @@ -52,6 +52,8 @@ MAKE_FUNCPTR(xsltParseStylesheetDoc); MAKE_FUNCPTR(xsltQuoteUserParams); MAKE_FUNCPTR(xsltSaveResultTo); # undef MAKE_FUNCPTR +#else +WINE_DECLARE_DEBUG_CHANNEL(winediag); #endif static const IID IID_xmlnode = {0x4f2f4ba2,0xb822,0x11df,{0x8b,0x8a,0x68,0x50,0xdf,0xd7,0x20,0x85}}; @@ -1289,7 +1291,8 @@ HRESULT node_transform_node_params(const xmlnode *This, IXMLDOMNode *stylesheet, return hr; #else - FIXME("libxslt headers were not found at compile time\n"); + ERR_(winediag)("libxslt headers were not found at compile time. Expect problems.\n"); + return E_NOTIMPL; #endif } diff --git a/dll/win32/msxml3/saxreader.c b/dll/win32/msxml3/saxreader.c index dc38cb90b97..dc02f19e1b9 100644 --- a/dll/win32/msxml3/saxreader.c +++ b/dll/win32/msxml3/saxreader.c @@ -279,8 +279,8 @@ typedef struct struct list elements; BSTR namespaceUri; - int attributesSize; - int nb_attributes; + int attr_alloc_count; + int attr_count; struct _attributes { BSTR szLocalname; @@ -1084,11 +1084,16 @@ static HRESULT WINAPI isaxattributes_getLength( { saxlocator *This = impl_from_ISAXAttributes( iface ); - *length = This->nb_attributes; + *length = This->attr_count; TRACE("Length set to %d\n", *length); return S_OK; } +static inline BOOL is_valid_attr_index(const saxlocator *locator, int index) +{ + return index < locator->attr_count && index >= 0; +} + static HRESULT WINAPI isaxattributes_getURI( ISAXAttributes* iface, int index, @@ -1098,7 +1103,7 @@ static HRESULT WINAPI isaxattributes_getURI( saxlocator *This = impl_from_ISAXAttributes( iface ); TRACE("(%p)->(%d)\n", This, index); - if(index >= This->nb_attributes || index < 0) return E_INVALIDARG; + if(!is_valid_attr_index(This, index)) return E_INVALIDARG; if(!url || !size) return E_POINTER; *size = SysStringLen(This->attributes[index].szURI); @@ -1111,36 +1116,36 @@ static HRESULT WINAPI isaxattributes_getURI( static HRESULT WINAPI isaxattributes_getLocalName( ISAXAttributes* iface, - int nIndex, + int index, const WCHAR **pLocalName, int *pLocalNameLength) { saxlocator *This = impl_from_ISAXAttributes( iface ); - TRACE("(%p)->(%d)\n", This, nIndex); + TRACE("(%p)->(%d)\n", This, index); - if(nIndex>=This->nb_attributes || nIndex<0) return E_INVALIDARG; + if(!is_valid_attr_index(This, index)) return E_INVALIDARG; if(!pLocalName || !pLocalNameLength) return E_POINTER; - *pLocalNameLength = SysStringLen(This->attributes[nIndex].szLocalname); - *pLocalName = This->attributes[nIndex].szLocalname; + *pLocalNameLength = SysStringLen(This->attributes[index].szLocalname); + *pLocalName = This->attributes[index].szLocalname; return S_OK; } static HRESULT WINAPI isaxattributes_getQName( ISAXAttributes* iface, - int nIndex, + int index, const WCHAR **pQName, int *pQNameLength) { saxlocator *This = impl_from_ISAXAttributes( iface ); - TRACE("(%p)->(%d)\n", This, nIndex); + TRACE("(%p)->(%d)\n", This, index); - if(nIndex>=This->nb_attributes || nIndex<0) return E_INVALIDARG; + if(!is_valid_attr_index(This, index)) return E_INVALIDARG; if(!pQName || !pQNameLength) return E_POINTER; - *pQNameLength = SysStringLen(This->attributes[nIndex].szQName); - *pQName = This->attributes[nIndex].szQName; + *pQNameLength = SysStringLen(This->attributes[index].szQName); + *pQName = This->attributes[index].szQName; return S_OK; } @@ -1158,7 +1163,7 @@ static HRESULT WINAPI isaxattributes_getName( saxlocator *This = impl_from_ISAXAttributes( iface ); TRACE("(%p)->(%d)\n", This, index); - if(index>=This->nb_attributes || index<0) return E_INVALIDARG; + if(!is_valid_attr_index(This, index)) return E_INVALIDARG; if(!uri || !pUriLength || !localName || !pLocalNameSize || !QName || !pQNameLength) return E_POINTER; @@ -1189,7 +1194,7 @@ static HRESULT WINAPI isaxattributes_getIndexFromName( if(!pUri || !pLocalName || !index) return E_POINTER; - for(i=0; inb_attributes; i++) + for(i=0; iattr_count; i++) { if(cUriLength!=SysStringLen(This->attributes[i].szURI) || cocalNameLength!=SysStringLen(This->attributes[i].szLocalname)) @@ -1221,7 +1226,7 @@ static HRESULT WINAPI isaxattributes_getIndexFromQName( if(!pQName || !index) return E_POINTER; if(!nQNameLength) return E_INVALIDARG; - for(i=0; inb_attributes; i++) + for(i=0; iattr_count; i++) { if(nQNameLength!=SysStringLen(This->attributes[i].szQName)) continue; if(memcmp(pQName, This->attributes[i].szQName, sizeof(WCHAR)*nQNameLength)) continue; @@ -1283,7 +1288,7 @@ static HRESULT WINAPI isaxattributes_getValue( saxlocator *This = impl_from_ISAXAttributes( iface ); TRACE("(%p)->(%d)\n", This, index); - if(index>=This->nb_attributes || index<0) return E_INVALIDARG; + if(!is_valid_attr_index(This, index)) return E_INVALIDARG; if(!value || !nValue) return E_POINTER; *nValue = SysStringLen(This->attributes[index].szValue); @@ -1401,7 +1406,7 @@ static void free_attribute_values(saxlocator *locator) { int i; - for (i = 0; i < locator->nb_attributes; i++) + for (i = 0; i < locator->attr_count; i++) { SysFreeString(locator->attributes[i].szLocalname); locator->attributes[i].szLocalname = NULL; @@ -1428,19 +1433,19 @@ static HRESULT SAXAttributes_populate(saxlocator *locator, if ((locator->saxreader->features & NamespacePrefixes) == 0) nb_namespaces = 0; - locator->nb_attributes = nb_namespaces + nb_attributes; - if(locator->nb_attributes > locator->attributesSize) + locator->attr_count = nb_namespaces + nb_attributes; + if(locator->attr_count > locator->attr_alloc_count) { - int new_size = locator->attributesSize * 2; + int new_size = locator->attr_count * 2; attrs = heap_realloc_zero(locator->attributes, new_size * sizeof(struct _attributes)); if(!attrs) { free_attribute_values(locator); - locator->nb_attributes = 0; + locator->attr_count = 0; return E_OUTOFMEMORY; } locator->attributes = attrs; - locator->attributesSize = new_size; + locator->attr_alloc_count = new_size; } else { @@ -1684,7 +1689,7 @@ static void libxmlEndElementNS( if (!saxreader_has_handler(This, SAXContentHandler)) { free_attribute_values(This); - This->nb_attributes = 0; + This->attr_count = 0; free_element_entry(element); return; } @@ -1706,7 +1711,7 @@ static void libxmlEndElementNS( element->qname, SysStringLen(element->qname)); free_attribute_values(This); - This->nb_attributes = 0; + This->attr_count = 0; if (sax_callback_failed(This, hr)) { @@ -2304,7 +2309,7 @@ static ULONG WINAPI isaxlocator_Release( SysFreeString(This->systemId); SysFreeString(This->namespaceUri); - for(index=0; indexattributesSize; index++) + for(index = 0; index < This->attr_alloc_count; index++) { SysFreeString(This->attributes[index].szLocalname); SysFreeString(This->attributes[index].szValue); @@ -2440,9 +2445,9 @@ static HRESULT SAXLocator_create(saxreader *reader, saxlocator **ppsaxlocator, B return E_OUTOFMEMORY; } - locator->attributesSize = 8; - locator->nb_attributes = 0; - locator->attributes = heap_alloc_zero(sizeof(struct _attributes)*locator->attributesSize); + locator->attr_alloc_count = 8; + locator->attr_count = 0; + locator->attributes = heap_alloc_zero(sizeof(struct _attributes)*locator->attr_alloc_count); if(!locator->attributes) { ISAXXMLReader_Release(&reader->ISAXXMLReader_iface); diff --git a/dll/win32/msxml3/schema.c b/dll/win32/msxml3/schema.c index 8bd78ff0061..73dfdae5e94 100644 --- a/dll/win32/msxml3/schema.c +++ b/dll/win32/msxml3/schema.c @@ -1038,8 +1038,6 @@ HRESULT cache_from_doc_ns(IXMLDOMSchemaCollection2 *iface, xmlnode *node) { int pos = 0, len = xmlXPathNodeSetGetLength(nodeset->nodesetval); - if (len == 0) return S_OK; - while (pos < len) { xmlNodePtr node = xmlXPathNodeSetItem(nodeset->nodesetval, pos); @@ -1173,11 +1171,14 @@ static HRESULT WINAPI schema_cache_Invoke(IXMLDOMSchemaCollection2* iface, static HRESULT WINAPI schema_cache_add(IXMLDOMSchemaCollection2* iface, BSTR uri, VARIANT var) { schema_cache* This = impl_from_IXMLDOMSchemaCollection2(iface); - xmlChar* name = uri ? xmlchar_from_wchar(uri) : xmlchar_from_wchar(emptyW); + xmlChar* name; + TRACE("(%p)->(%s %s)\n", This, debugstr_w(uri), debugstr_variant(&var)); if (This->read_only) return E_FAIL; + name = uri ? xmlchar_from_wchar(uri) : xmlchar_from_wchar(emptyW); + switch (V_VT(&var)) { case VT_NULL: @@ -1297,11 +1298,13 @@ static HRESULT WINAPI schema_cache_get(IXMLDOMSchemaCollection2* iface, BSTR uri static HRESULT WINAPI schema_cache_remove(IXMLDOMSchemaCollection2* iface, BSTR uri) { schema_cache* This = impl_from_IXMLDOMSchemaCollection2(iface); - xmlChar* name = uri ? xmlchar_from_wchar(uri) : xmlchar_from_wchar(emptyW); + xmlChar* name; + TRACE("(%p)->(%s)\n", This, debugstr_w(uri)); if (This->version == MSXML6) return E_NOTIMPL; + name = uri ? xmlchar_from_wchar(uri) : xmlchar_from_wchar(emptyW); cache_remove_entry(This, name); heap_free(name); return S_OK; diff --git a/dll/win32/msxml3/xslpattern.tab.c b/dll/win32/msxml3/xslpattern.tab.c index 9e75e8be3cd..66c8dd9a663 100644 --- a/dll/win32/msxml3/xslpattern.tab.c +++ b/dll/win32/msxml3/xslpattern.tab.c @@ -1,21 +1,19 @@ +/* A Bison parser, made by GNU Bison 3.0.2. */ -/* A Bison parser, made by GNU Bison 2.4.1. */ +/* Bison implementation for Yacc-like parsers in C + + Copyright (C) 1984, 1989-1990, 2000-2013 Free Software Foundation, Inc. -/* Skeleton implementation for Bison's Yacc-like parsers in C - - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 - Free Software Foundation, Inc. - This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. - + This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. - + You should have received a copy of the GNU General Public License along with this program. If not, see . */ @@ -28,7 +26,7 @@ special exception, which will cause the skeleton and the resulting Bison output files to be licensed under the GNU General Public License without this special exception. - + This special exception was added by the Free Software Foundation in version 2.2 of Bison. */ @@ -46,7 +44,7 @@ #define YYBISON 1 /* Bison version. */ -#define YYBISON_VERSION "2.4.1" +#define YYBISON_VERSION "3.0.2" /* Skeleton name. */ #define YYSKELETON_NAME "yacc.c" @@ -60,23 +58,17 @@ /* Pull parsers. */ #define YYPULL 1 -/* Using locations. */ -#define YYLSP_NEEDED 0 /* Substitute the variable and function names. */ #define yyparse xslpattern_parse #define yylex xslpattern_lex #define yyerror xslpattern_error -#define yylval xslpattern_lval -#define yychar xslpattern_char #define yydebug xslpattern_debug #define yynerrs xslpattern_nerrs /* Copy the first part of user declarations. */ - -/* Line 189 of yacc.c */ -#line 21 "xslpattern.y" +#line 21 "xslpattern.y" /* yacc.c:339 */ #include "precomp.h" @@ -116,14 +108,15 @@ static void xslpattern_error(parser_param* param, void const* scanner, char cons } +#line 115 "xslpattern.tab.c" /* yacc.c:339 */ -/* Line 189 of yacc.c */ -#line 125 "xslpattern.tab.c" - -/* Enabling traces. */ -#ifndef YYDEBUG -# define YYDEBUG 0 -#endif +# ifndef YY_NULLPTR +# if defined __cplusplus && 201103L <= __cplusplus +# define YY_NULLPTR nullptr +# else +# define YY_NULLPTR 0 +# endif +# endif /* Enabling verbose error messages. */ #ifdef YYERROR_VERBOSE @@ -133,62 +126,65 @@ static void xslpattern_error(parser_param* param, void const* scanner, char cons # define YYERROR_VERBOSE 0 #endif -/* Enabling the token table. */ -#ifndef YYTOKEN_TABLE -# define YYTOKEN_TABLE 0 + +/* Debug traces. */ +#ifndef YYDEBUG +# define YYDEBUG 0 +#endif +#if YYDEBUG +extern int xslpattern_debug; #endif - -/* Tokens. */ +/* Token type. */ #ifndef YYTOKENTYPE # define YYTOKENTYPE - /* Put the tokens into the symbol table, so that GDB and other debuggers - know about them. */ - enum yytokentype { - TOK_Parent = 258, - TOK_Self = 259, - TOK_DblFSlash = 260, - TOK_FSlash = 261, - TOK_Axis = 262, - TOK_Colon = 263, - TOK_OpAnd = 264, - TOK_OpOr = 265, - TOK_OpNot = 266, - TOK_OpEq = 267, - TOK_OpIEq = 268, - TOK_OpNEq = 269, - TOK_OpINEq = 270, - TOK_OpLt = 271, - TOK_OpILt = 272, - TOK_OpGt = 273, - TOK_OpIGt = 274, - TOK_OpLEq = 275, - TOK_OpILEq = 276, - TOK_OpGEq = 277, - TOK_OpIGEq = 278, - TOK_OpAll = 279, - TOK_OpAny = 280, - TOK_NCName = 281, - TOK_Literal = 282, - TOK_Number = 283 - }; + enum yytokentype + { + TOK_Parent = 258, + TOK_Self = 259, + TOK_DblFSlash = 260, + TOK_FSlash = 261, + TOK_Axis = 262, + TOK_Colon = 263, + TOK_OpAnd = 264, + TOK_OpOr = 265, + TOK_OpNot = 266, + TOK_OpEq = 267, + TOK_OpIEq = 268, + TOK_OpNEq = 269, + TOK_OpINEq = 270, + TOK_OpLt = 271, + TOK_OpILt = 272, + TOK_OpGt = 273, + TOK_OpIGt = 274, + TOK_OpLEq = 275, + TOK_OpILEq = 276, + TOK_OpGEq = 277, + TOK_OpIGEq = 278, + TOK_OpAll = 279, + TOK_OpAny = 280, + TOK_NCName = 281, + TOK_Literal = 282, + TOK_Number = 283 + }; #endif - - +/* Value type. */ #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED typedef int YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 -# define yystype YYSTYPE /* obsolescent; will be withdrawn */ # define YYSTYPE_IS_DECLARED 1 #endif + +int xslpattern_parse (parser_param* p, void* scanner); + + + /* Copy the second part of user declarations. */ - -/* Line 264 of yacc.c */ -#line 195 "xslpattern.tab.c" +#line 191 "xslpattern.tab.c" /* yacc.c:358 */ #ifdef short # undef short @@ -202,11 +198,8 @@ typedef unsigned char yytype_uint8; #ifdef YYTYPE_INT8 typedef YYTYPE_INT8 yytype_int8; -#elif (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -typedef signed char yytype_int8; #else -typedef short int yytype_int8; +typedef signed char yytype_int8; #endif #ifdef YYTYPE_UINT16 @@ -226,8 +219,7 @@ typedef short int yytype_int16; # define YYSIZE_T __SIZE_TYPE__ # elif defined size_t # define YYSIZE_T size_t -# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) +# elif ! defined YYSIZE_T # include /* INFRINGES ON USER NAME SPACE */ # define YYSIZE_T size_t # else @@ -238,41 +230,70 @@ typedef short int yytype_int16; #define YYSIZE_MAXIMUM ((YYSIZE_T) -1) #ifndef YY_ -# if YYENABLE_NLS +# if defined YYENABLE_NLS && YYENABLE_NLS # if ENABLE_NLS # include /* INFRINGES ON USER NAME SPACE */ -# define YY_(msgid) dgettext ("bison-runtime", msgid) +# define YY_(Msgid) dgettext ("bison-runtime", Msgid) # endif # endif # ifndef YY_ -# define YY_(msgid) msgid +# define YY_(Msgid) Msgid +# endif +#endif + +#ifndef YY_ATTRIBUTE +# if (defined __GNUC__ \ + && (2 < __GNUC__ || (__GNUC__ == 2 && 96 <= __GNUC_MINOR__))) \ + || defined __SUNPRO_C && 0x5110 <= __SUNPRO_C +# define YY_ATTRIBUTE(Spec) __attribute__(Spec) +# else +# define YY_ATTRIBUTE(Spec) /* empty */ +# endif +#endif + +#ifndef YY_ATTRIBUTE_PURE +# define YY_ATTRIBUTE_PURE YY_ATTRIBUTE ((__pure__)) +#endif + +#ifndef YY_ATTRIBUTE_UNUSED +# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__)) +#endif + +#if !defined _Noreturn \ + && (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112) +# if defined _MSC_VER && 1200 <= _MSC_VER +# define _Noreturn __declspec (noreturn) +# else +# define _Noreturn YY_ATTRIBUTE ((__noreturn__)) # endif #endif /* Suppress unused-variable warnings by "using" E. */ #if ! defined lint || defined __GNUC__ -# define YYUSE(e) ((void) (e)) +# define YYUSE(E) ((void) (E)) #else -# define YYUSE(e) /* empty */ +# define YYUSE(E) /* empty */ #endif -/* Identity function, used to suppress warnings about constant conditions. */ -#ifndef lint -# define YYID(n) (n) +#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__ +/* Suppress an incorrect diagnostic about yylval being uninitialized. */ +# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \ + _Pragma ("GCC diagnostic push") \ + _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\ + _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") +# define YY_IGNORE_MAYBE_UNINITIALIZED_END \ + _Pragma ("GCC diagnostic pop") #else -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -static int -YYID (int yyi) -#else -static int -YYID (yyi) - int yyi; +# define YY_INITIAL_VALUE(Value) Value #endif -{ - return yyi; -} +#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN +# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN +# define YY_IGNORE_MAYBE_UNINITIALIZED_END #endif +#ifndef YY_INITIAL_VALUE +# define YY_INITIAL_VALUE(Value) /* Nothing. */ +#endif + #if ! defined yyoverflow || YYERROR_VERBOSE @@ -291,11 +312,11 @@ YYID (yyi) # define alloca _alloca # else # define YYSTACK_ALLOC alloca -# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) +# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS # include /* INFRINGES ON USER NAME SPACE */ -# ifndef _STDLIB_H -# define _STDLIB_H 1 + /* Use EXIT_SUCCESS as a witness for stdlib.h. */ +# ifndef EXIT_SUCCESS +# define EXIT_SUCCESS 0 # endif # endif # endif @@ -303,8 +324,8 @@ YYID (yyi) # endif # ifdef YYSTACK_ALLOC - /* Pacify GCC's `empty if-body' warning. */ -# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0)) + /* Pacify GCC's 'empty if-body' warning. */ +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0) # ifndef YYSTACK_ALLOC_MAXIMUM /* The OS might guarantee only one guard page at the bottom of the stack, and a page size can be as small as 4096 bytes. So we cannot safely @@ -318,25 +339,23 @@ YYID (yyi) # ifndef YYSTACK_ALLOC_MAXIMUM # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM # endif -# if (defined __cplusplus && ! defined _STDLIB_H \ +# if (defined __cplusplus && ! defined EXIT_SUCCESS \ && ! ((defined YYMALLOC || defined malloc) \ - && (defined YYFREE || defined free))) + && (defined YYFREE || defined free))) # include /* INFRINGES ON USER NAME SPACE */ -# ifndef _STDLIB_H -# define _STDLIB_H 1 +# ifndef EXIT_SUCCESS +# define EXIT_SUCCESS 0 # endif # endif # ifndef YYMALLOC # define YYMALLOC malloc -# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) +# if ! defined malloc && ! defined EXIT_SUCCESS void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ # endif # endif # ifndef YYFREE # define YYFREE free -# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) +# if ! defined free && ! defined EXIT_SUCCESS void free (void *); /* INFRINGES ON USER NAME SPACE */ # endif # endif @@ -346,7 +365,7 @@ void free (void *); /* INFRINGES ON USER NAME SPACE */ #if (! defined yyoverflow \ && (! defined __cplusplus \ - || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) + || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) /* A type that is properly aligned for any stack member. */ union yyalloc @@ -364,44 +383,48 @@ union yyalloc ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + YYSTACK_GAP_MAXIMUM) -/* Copy COUNT objects from FROM to TO. The source and destination do - not overlap. */ -# ifndef YYCOPY -# if defined __GNUC__ && 1 < __GNUC__ -# define YYCOPY(To, From, Count) \ - __builtin_memcpy (To, From, (Count) * sizeof (*(From))) -# else -# define YYCOPY(To, From, Count) \ - do \ - { \ - YYSIZE_T yyi; \ - for (yyi = 0; yyi < (Count); yyi++) \ - (To)[yyi] = (From)[yyi]; \ - } \ - while (YYID (0)) -# endif -# endif +# define YYCOPY_NEEDED 1 /* Relocate STACK from its old location to the new one. The local variables YYSIZE and YYSTACKSIZE give the old and new number of elements in the stack, and YYPTR gives the new location of the stack. Advance YYPTR to a properly aligned location for the next stack. */ -# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ - do \ - { \ - YYSIZE_T yynewbytes; \ - YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ - Stack = &yyptr->Stack_alloc; \ - yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ - yyptr += yynewbytes / sizeof (*yyptr); \ - } \ - while (YYID (0)) +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (0) #endif +#if defined YYCOPY_NEEDED && YYCOPY_NEEDED +/* Copy COUNT objects from SRC to DST. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if defined __GNUC__ && 1 < __GNUC__ +# define YYCOPY(Dst, Src, Count) \ + __builtin_memcpy (Dst, Src, (Count) * sizeof (*(Src))) +# else +# define YYCOPY(Dst, Src, Count) \ + do \ + { \ + YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (Dst)[yyi] = (Src)[yyi]; \ + } \ + while (0) +# endif +# endif +#endif /* !YYCOPY_NEEDED */ + /* YYFINAL -- State number of the termination state. */ -#define YYFINAL 57 +#define YYFINAL 58 /* YYLAST -- Last index in YYTABLE. */ #define YYLAST 176 @@ -410,18 +433,20 @@ union yyalloc /* YYNNTS -- Number of nonterminals. */ #define YYNNTS 39 /* YYNRULES -- Number of rules. */ -#define YYNRULES 103 -/* YYNRULES -- Number of states. */ -#define YYNSTATES 156 +#define YYNRULES 104 +/* YYNSTATES -- Number of states. */ +#define YYNSTATES 157 -/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ +/* YYTRANSLATE[YYX] -- Symbol number corresponding to YYX as returned + by yylex, with out-of-bounds checking. */ #define YYUNDEFTOK 2 #define YYMAXUTOK 283 -#define YYTRANSLATE(YYX) \ +#define YYTRANSLATE(YYX) \ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) -/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ +/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM + as returned by yylex, without out-of-bounds checking. */ static const yytype_uint8 yytranslate[] = { 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, @@ -456,77 +481,24 @@ static const yytype_uint8 yytranslate[] = }; #if YYDEBUG -/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in - YYRHS. */ -static const yytype_uint16 yyprhs[] = -{ - 0, 0, 3, 5, 7, 9, 13, 15, 17, 19, - 22, 24, 26, 28, 32, 34, 38, 41, 44, 46, - 48, 50, 53, 56, 58, 60, 62, 66, 70, 72, - 75, 77, 81, 83, 85, 87, 89, 92, 96, 98, - 100, 102, 104, 106, 108, 110, 112, 114, 118, 122, - 124, 126, 131, 135, 139, 141, 143, 145, 149, 151, - 155, 159, 161, 163, 166, 168, 170, 174, 176, 178, - 182, 184, 186, 190, 194, 198, 202, 204, 206, 210, - 214, 218, 222, 226, 230, 234, 238, 240, 242, 245, - 248, 251, 253, 257, 261, 265, 269, 273, 277, 281, - 285, 289, 293, 297 -}; - -/* YYRHS -- A `-1'-separated list of the rules' RHS. */ -static const yytype_int8 yyrhs[] = -{ - 39, 0, -1, 57, -1, 41, -1, 42, -1, 26, - 8, 26, -1, 26, -1, 45, -1, 44, -1, 6, - 45, -1, 6, -1, 54, -1, 46, -1, 45, 6, - 46, -1, 55, -1, 47, 49, 51, -1, 49, 51, - -1, 47, 49, -1, 49, -1, 48, -1, 56, -1, - 26, 7, -1, 29, 40, -1, 50, -1, 60, -1, - 30, -1, 26, 8, 30, -1, 26, 8, 26, -1, - 42, -1, 51, 52, -1, 52, -1, 31, 53, 32, - -1, 28, -1, 58, -1, 48, -1, 26, -1, 5, - 45, -1, 45, 5, 46, -1, 3, -1, 4, -1, - 66, -1, 60, -1, 75, -1, 73, -1, 71, -1, - 69, -1, 67, -1, 33, 57, 34, -1, 64, 35, - 60, -1, 27, -1, 28, -1, 40, 33, 61, 34, - -1, 40, 33, 34, -1, 62, 36, 61, -1, 62, - -1, 57, -1, 64, -1, 63, 37, 64, -1, 43, - -1, 65, 6, 45, -1, 65, 5, 45, -1, 65, - -1, 59, -1, 65, 52, -1, 68, -1, 67, -1, - 66, 10, 68, -1, 70, -1, 69, -1, 68, 9, - 70, -1, 72, -1, 71, -1, 70, 12, 72, -1, - 70, 13, 72, -1, 70, 14, 72, -1, 70, 15, - 72, -1, 74, -1, 73, -1, 72, 16, 74, -1, - 72, 17, 74, -1, 72, 18, 74, -1, 72, 19, - 74, -1, 72, 20, 74, -1, 72, 21, 74, -1, - 72, 22, 74, -1, 72, 23, 74, -1, 63, -1, - 75, -1, 11, 74, -1, 25, 57, -1, 24, 76, - -1, 24, -1, 64, 12, 64, -1, 64, 14, 64, - -1, 64, 16, 64, -1, 64, 20, 64, -1, 64, - 18, 64, -1, 64, 22, 64, -1, 64, 13, 64, - -1, 64, 15, 64, -1, 64, 17, 64, -1, 64, - 21, 64, -1, 64, 19, 64, -1, 64, 23, 64, - -1 -}; - -/* YYRLINE[YYN] -- source line where rule number YYN was defined. */ + /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */ static const yytype_uint16 yyrline[] = { 0, 86, 86, 96, 97, 99, 108, 119, 120, 122, 129, 134, 136, 137, 145, 148, 157, 164, 171, 172, - 173, 175, 182, 192, 193, 195, 200, 206, 225, 233, - 239, 241, 250, 256, 257, 258, 261, 269, 278, 283, - 292, 294, 295, 296, 297, 298, 299, 301, 309, 317, - 318, 321, 380, 411, 418, 420, 423, 424, 433, 434, - 442, 450, 452, 453, 462, 463, 465, 474, 475, 477, - 486, 487, 489, 497, 508, 516, 528, 529, 531, 539, - 550, 558, 569, 577, 588, 596, 610, 611, 613, 621, - 629, 637, 643, 650, 657, 664, 671, 678, 685, 695, - 705, 715, 725, 735 + 173, 175, 182, 189, 197, 198, 200, 205, 211, 230, + 238, 244, 246, 255, 261, 262, 263, 266, 274, 283, + 288, 297, 299, 300, 301, 302, 303, 304, 306, 314, + 322, 323, 326, 385, 416, 423, 425, 428, 429, 438, + 439, 447, 455, 457, 458, 467, 468, 470, 479, 480, + 482, 491, 492, 494, 502, 513, 521, 533, 534, 536, + 544, 555, 563, 574, 582, 593, 601, 615, 616, 618, + 626, 634, 642, 648, 655, 662, 669, 676, 683, 690, + 700, 710, 720, 730, 740 }; #endif -#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE +#if YYDEBUG || YYERROR_VERBOSE || 0 /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. First, the terminals, then, starting at YYNTOKENS, nonterminals. */ static const char *const yytname[] = @@ -546,13 +518,13 @@ static const char *const yytname[] = "PrimaryExpr", "FunctionCall", "Arguments", "Argument", "UnionExpr", "PathExpr", "FilterExpr", "OrExpr", "BoolOrExpr", "AndExpr", "BoolAndExpr", "EqualityExpr", "BoolEqualityExpr", "RelationalExpr", - "BoolRelationalExpr", "UnaryExpr", "BoolUnaryExpr", "AllExpr", 0 + "BoolRelationalExpr", "UnaryExpr", "BoolUnaryExpr", "AllExpr", YY_NULLPTR }; #endif # ifdef YYPRINT -/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to - token YYLEX-NUM. */ +/* YYTOKNUM[NUM] -- (External) token number corresponding to the + (internal) symbol number NUM (which must be that of a token). */ static const yytype_uint16 yytoknum[] = { 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, @@ -562,153 +534,128 @@ static const yytype_uint16 yytoknum[] = }; # endif -/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ -static const yytype_uint8 yyr1[] = +#define YYPACT_NINF -34 + +#define yypact_value_is_default(Yystate) \ + (!!((Yystate) == (-34))) + +#define YYTABLE_NINF -67 + +#define yytable_value_is_error(Yytable_value) \ + 0 + + /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing + STATE-NUM. */ +static const yytype_int16 yypact[] = { - 0, 38, 39, 40, 40, 41, 42, 43, 43, 44, - 44, 44, 45, 45, 45, 46, 46, 46, 46, 46, - 46, 47, 48, 49, 49, 50, 50, 50, 50, 51, - 51, 52, 53, 53, 53, 53, 54, 55, 56, 56, - 57, 58, 58, 58, 58, 58, 58, 59, 59, 59, - 59, 60, 60, 61, 61, 62, 63, 63, 64, 64, - 64, 64, 65, 65, 66, 66, 67, 68, 68, 69, - 70, 70, 71, 71, 71, 71, 72, 72, 73, 73, - 73, 73, 73, 73, 73, 73, 74, 74, 75, 75, - 75, 75, 76, 76, 76, 76, 76, 76, 76, 76, - 76, 76, 76, 76 + 20, -34, -34, 25, 25, 20, 106, 20, 0, -34, + -34, -21, -34, 20, 10, -17, -34, -12, -34, -34, + 52, -34, -8, -34, 28, -34, -34, -34, -34, -34, + -34, -34, -10, 27, 35, 55, -34, 21, -34, 58, + -34, 136, -34, -34, -34, 52, 52, -34, 128, -34, + -34, -34, 26, 59, -34, -34, -34, 40, -34, 9, + 25, 25, 105, 28, 97, 28, -34, 106, 88, 25, + 25, -34, 20, 20, 20, 20, 20, 20, 20, 20, + 20, 20, 20, 20, 20, 20, 106, 106, 106, 106, + 106, 106, 106, 106, 106, 106, 106, 106, 82, -34, + 90, -34, -34, -34, 83, 84, -34, -34, 28, 99, + 86, 87, 96, -34, 129, 55, 119, 130, 132, 133, + 134, -34, 27, -34, 52, 52, -34, 58, 136, 136, + 136, 136, -34, -34, -34, -34, -34, -34, -34, -34, + 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, + 27, 27, -34, -34, 20, -34, -34 }; -/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ -static const yytype_uint8 yyr2[] = -{ - 0, 2, 1, 1, 1, 3, 1, 1, 1, 2, - 1, 1, 1, 3, 1, 3, 2, 2, 1, 1, - 1, 2, 2, 1, 1, 1, 3, 3, 1, 2, - 1, 3, 1, 1, 1, 1, 2, 3, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 3, 3, 1, - 1, 4, 3, 3, 1, 1, 1, 3, 1, 3, - 3, 1, 1, 2, 1, 1, 3, 1, 1, 3, - 1, 1, 3, 3, 3, 3, 1, 1, 3, 3, - 3, 3, 3, 3, 3, 3, 1, 1, 2, 2, - 2, 1, 3, 3, 3, 3, 3, 3, 3, 3, - 3, 3, 3, 3 -}; - -/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state - STATE-NUM when YYTABLE doesn't specify something else to do. Zero - means the default is an error. */ + /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM. + Performed when YYTABLE does not specify something else to do. Zero + means the default is an error. */ static const yytype_uint8 yydefact[] = { - 0, 38, 39, 0, 10, 0, 91, 0, 6, 49, - 50, 0, 25, 0, 0, 0, 3, 28, 58, 8, - 7, 12, 0, 19, 18, 23, 11, 14, 20, 2, - 62, 24, 86, 56, 61, 40, 65, 64, 68, 67, - 71, 70, 77, 76, 87, 36, 9, 88, 0, 90, - 89, 21, 0, 6, 22, 4, 0, 1, 0, 0, - 0, 6, 17, 0, 16, 30, 0, 0, 0, 0, - 63, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 39, 40, 0, 10, 0, 92, 0, 6, 50, + 51, 0, 26, 0, 0, 0, 3, 29, 59, 8, + 7, 12, 0, 19, 18, 24, 11, 14, 20, 2, + 63, 25, 87, 57, 62, 41, 66, 65, 69, 68, + 72, 71, 78, 77, 88, 37, 9, 89, 0, 91, + 90, 21, 0, 6, 23, 22, 4, 0, 1, 0, + 0, 0, 6, 17, 0, 16, 31, 0, 0, 0, + 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 27, 26, 0, - 47, 52, 55, 0, 54, 37, 13, 15, 6, 50, - 19, 0, 33, 24, 0, 46, 68, 71, 77, 87, - 29, 57, 48, 60, 59, 66, 69, 72, 73, 74, - 75, 78, 79, 80, 81, 82, 83, 84, 85, 92, - 98, 93, 99, 94, 100, 96, 102, 95, 101, 97, - 103, 5, 51, 0, 31, 53 + 0, 0, 0, 0, 0, 0, 0, 0, 28, 27, + 0, 48, 53, 56, 0, 55, 38, 13, 15, 6, + 51, 19, 0, 34, 25, 0, 47, 69, 72, 78, + 88, 30, 58, 49, 61, 60, 67, 70, 73, 74, + 75, 76, 79, 80, 81, 82, 83, 84, 85, 86, + 93, 99, 94, 100, 95, 101, 97, 103, 96, 102, + 98, 104, 5, 52, 0, 32, 54 }; -/* YYDEFGOTO[NTERM-NUM]. */ + /* YYPGOTO[NTERM-NUM]. */ +static const yytype_int16 yypgoto[] = +{ + -34, -34, 126, -34, -5, -34, -34, -1, 44, -34, + 74, 138, -34, 104, -33, -34, -34, -34, -34, 4, + -34, -34, -4, 15, -34, -34, -6, -34, 107, 108, + 98, 109, 95, 110, 2, 111, 14, 112, -34 +}; + + /* YYDEFGOTO[NTERM-NUM]. */ static const yytype_int8 yydefgoto[] = { -1, 14, 15, 16, 17, 18, 19, 20, 21, 22, - 23, 24, 25, 64, 65, 111, 26, 27, 28, 102, - 112, 30, 31, 103, 104, 32, 33, 34, 35, 36, + 23, 24, 25, 65, 66, 112, 26, 27, 28, 103, + 113, 30, 31, 104, 105, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 49 }; -/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing - STATE-NUM. */ -#define YYPACT_NINF -34 -static const yytype_int16 yypact[] = -{ - 21, -34, -34, 26, 26, 21, 105, 21, 0, -34, - -34, -16, -34, 21, 16, -12, -34, 11, -34, -34, - 53, -34, -21, -34, -3, -34, -34, -34, -34, -34, - -34, -34, -14, 28, 35, 51, -34, 64, -34, 57, - -34, 135, -34, -34, -34, 53, 53, -34, 127, -34, - -34, -34, -8, 95, -34, -34, 70, -34, 9, 26, - 26, 104, -3, 96, -3, -34, 105, -16, 26, 26, - -34, 21, 21, 21, 21, 21, 21, 21, 21, 21, - 21, 21, 21, 21, 21, 105, 105, 105, 105, 105, - 105, 105, 105, 105, 105, 105, 105, 80, -34, 88, - -34, -34, -34, 81, 82, -34, -34, -3, 98, 84, - 85, 87, -34, 128, 51, 117, 129, 131, 132, 133, - -34, 28, -34, 53, 53, -34, 57, 135, 135, 135, - 135, -34, -34, -34, -34, -34, -34, -34, -34, 28, - 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, - 28, -34, -34, 21, -34, -34 -}; - -/* YYPGOTO[NTERM-NUM]. */ -static const yytype_int8 yypgoto[] = -{ - -34, -34, 125, -34, -5, -34, -34, -1, 5, -34, - 65, 115, -34, 97, -33, -34, -34, -34, -34, 4, - -34, -34, -10, 13, -34, -34, -6, -34, 106, 107, - 100, 109, 101, 111, 2, 112, 14, 113, -34 -}; - -/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If - positive, shift that token. If negative, reduce the rule which - number is the opposite. If zero, do what YYDEFACT says. - If YYTABLE_NINF, syntax error. */ -#define YYTABLE_NINF -66 + /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If + positive, shift that token. If negative, reduce the rule whose + number is the opposite. If YYTABLE_NINF, syntax error. */ static const yytype_int16 yytable[] = { - 48, 70, 45, 46, 29, 61, 55, 51, 52, 12, - 53, 50, 1, 2, 3, 4, 57, 56, 97, 47, - 5, 58, 98, 66, 1, 2, 3, 4, 63, 1, - 2, 120, 5, 6, 7, 8, 9, 10, 11, 12, - 68, 69, 13, 101, -4, 6, 7, 8, 9, 10, - 11, 12, 8, 113, 13, 11, 12, 122, 59, 60, - 121, 71, 55, 67, 105, 106, 63, 123, 124, 73, - 74, 75, 76, 72, 120, 127, 128, 129, 130, 139, + 48, 71, 45, 46, 29, 53, 56, 51, 52, 54, + 58, 50, 1, 2, 3, 4, 59, 57, 62, 47, + 5, -4, 12, 1, 2, 3, 4, 67, 1, 2, + 73, 5, 121, 6, 7, 8, 9, 10, 11, 12, + 69, 70, 13, 102, 6, 7, 8, 9, 10, 11, + 12, 8, 98, 13, 11, 12, 99, 60, 61, 64, + 114, 122, 68, 56, 123, 72, 64, 100, 124, 125, + 74, 75, 76, 77, 101, 121, 128, 129, 130, 131, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, - 150, 131, 132, 133, 134, 135, 136, 137, 138, 1, - 2, 3, 4, 99, 100, 51, 52, 5, 1, 2, - 3, 4, 52, -5, 151, 152, -32, -34, 153, 154, - 6, 7, 108, 9, 109, 11, 12, -65, 110, 13, - -35, 8, 9, 10, 11, 12, 54, 62, 13, 85, + 150, 151, 132, 133, 134, 135, 136, 137, 138, 139, + 1, 2, 3, 4, 106, 107, 51, 52, 5, 1, + 2, 3, 4, 52, 53, -5, 152, 153, -33, -35, + 154, 6, 7, 109, 9, 110, 11, 12, 155, -66, + 13, -36, 8, 9, 10, 11, 12, 55, 111, 13, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, - 96, 77, 78, 79, 80, 81, 82, 83, 84, 107, - -41, -45, 67, -44, -43, -42, 155, 0, 0, 114, - 115, 125, 116, 126, 117, 118, 119 + 96, 97, 78, 79, 80, 81, 82, 83, 84, 85, + 63, -42, -46, 68, -45, -44, -43, 108, 127, 156, + 126, 115, 116, 117, 118, 119, 120 }; -static const yytype_int16 yycheck[] = +static const yytype_uint8 yycheck[] = { 6, 34, 3, 4, 0, 26, 11, 7, 8, 30, - 26, 7, 3, 4, 5, 6, 0, 13, 26, 5, - 11, 33, 30, 37, 3, 4, 5, 6, 31, 3, - 4, 64, 11, 24, 25, 26, 27, 28, 29, 30, - 5, 6, 33, 34, 33, 24, 25, 26, 27, 28, - 29, 30, 26, 63, 33, 29, 30, 67, 5, 6, - 66, 10, 67, 35, 59, 60, 31, 68, 69, 12, - 13, 14, 15, 9, 107, 73, 74, 75, 76, 85, + 0, 7, 3, 4, 5, 6, 33, 13, 26, 5, + 11, 33, 30, 3, 4, 5, 6, 37, 3, 4, + 9, 11, 65, 24, 25, 26, 27, 28, 29, 30, + 5, 6, 33, 34, 24, 25, 26, 27, 28, 29, + 30, 26, 26, 33, 29, 30, 30, 5, 6, 31, + 64, 67, 35, 68, 68, 10, 31, 8, 69, 70, + 12, 13, 14, 15, 34, 108, 74, 75, 76, 77, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, - 96, 77, 78, 79, 80, 81, 82, 83, 84, 3, - 4, 5, 6, 8, 34, 7, 8, 11, 3, 4, - 5, 6, 8, 33, 26, 34, 32, 32, 36, 32, - 24, 25, 26, 27, 28, 29, 30, 10, 63, 33, - 32, 26, 27, 28, 29, 30, 11, 22, 33, 12, - 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, - 23, 16, 17, 18, 19, 20, 21, 22, 23, 62, - 32, 32, 35, 32, 32, 32, 153, -1, -1, 63, - 63, 71, 63, 72, 63, 63, 63 + 96, 97, 78, 79, 80, 81, 82, 83, 84, 85, + 3, 4, 5, 6, 60, 61, 7, 8, 11, 3, + 4, 5, 6, 8, 26, 33, 26, 34, 32, 32, + 36, 24, 25, 26, 27, 28, 29, 30, 32, 10, + 33, 32, 26, 27, 28, 29, 30, 11, 64, 33, + 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, + 22, 23, 16, 17, 18, 19, 20, 21, 22, 23, + 22, 32, 32, 35, 32, 32, 32, 63, 73, 154, + 72, 64, 64, 64, 64, 64, 64 }; -/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing - symbol of state STATE-NUM. */ + /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing + symbol of state STATE-NUM. */ static const yytype_uint8 yystos[] = { 0, 3, 4, 5, 6, 11, 24, 25, 26, 27, @@ -716,108 +663,86 @@ static const yytype_uint8 yystos[] = 45, 46, 47, 48, 49, 50, 54, 55, 56, 57, 59, 60, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 45, 45, 74, 64, 76, - 57, 7, 8, 26, 40, 42, 57, 0, 33, 5, - 6, 26, 49, 31, 51, 52, 37, 35, 5, 6, - 52, 10, 9, 12, 13, 14, 15, 16, 17, 18, - 19, 20, 21, 22, 23, 12, 13, 14, 15, 16, - 17, 18, 19, 20, 21, 22, 23, 26, 30, 8, - 34, 34, 57, 61, 62, 46, 46, 51, 26, 28, - 48, 53, 58, 60, 66, 67, 69, 71, 73, 75, - 52, 64, 60, 45, 45, 68, 70, 72, 72, 72, - 72, 74, 74, 74, 74, 74, 74, 74, 74, 64, + 57, 7, 8, 26, 30, 40, 42, 57, 0, 33, + 5, 6, 26, 49, 31, 51, 52, 37, 35, 5, + 6, 52, 10, 9, 12, 13, 14, 15, 16, 17, + 18, 19, 20, 21, 22, 23, 12, 13, 14, 15, + 16, 17, 18, 19, 20, 21, 22, 23, 26, 30, + 8, 34, 34, 57, 61, 62, 46, 46, 51, 26, + 28, 48, 53, 58, 60, 66, 67, 69, 71, 73, + 75, 52, 64, 60, 45, 45, 68, 70, 72, 72, + 72, 72, 74, 74, 74, 74, 74, 74, 74, 74, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, - 64, 26, 34, 36, 32, 61 + 64, 64, 26, 34, 36, 32, 61 }; -#define yyerrok (yyerrstatus = 0) -#define yyclearin (yychar = YYEMPTY) -#define YYEMPTY (-2) -#define YYEOF 0 + /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ +static const yytype_uint8 yyr1[] = +{ + 0, 38, 39, 40, 40, 41, 42, 43, 43, 44, + 44, 44, 45, 45, 45, 46, 46, 46, 46, 46, + 46, 47, 48, 48, 49, 49, 50, 50, 50, 50, + 51, 51, 52, 53, 53, 53, 53, 54, 55, 56, + 56, 57, 58, 58, 58, 58, 58, 58, 59, 59, + 59, 59, 60, 60, 61, 61, 62, 63, 63, 64, + 64, 64, 64, 65, 65, 66, 66, 67, 68, 68, + 69, 70, 70, 71, 71, 71, 71, 72, 72, 73, + 73, 73, 73, 73, 73, 73, 73, 74, 74, 75, + 75, 75, 75, 76, 76, 76, 76, 76, 76, 76, + 76, 76, 76, 76, 76 +}; -#define YYACCEPT goto yyacceptlab -#define YYABORT goto yyabortlab -#define YYERROR goto yyerrorlab + /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */ +static const yytype_uint8 yyr2[] = +{ + 0, 2, 1, 1, 1, 3, 1, 1, 1, 2, + 1, 1, 1, 3, 1, 3, 2, 2, 1, 1, + 1, 2, 2, 2, 1, 1, 1, 3, 3, 1, + 2, 1, 3, 1, 1, 1, 1, 2, 3, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 3, 3, + 1, 1, 4, 3, 3, 1, 1, 1, 3, 1, + 3, 3, 1, 1, 2, 1, 1, 3, 1, 1, + 3, 1, 1, 3, 3, 3, 3, 1, 1, 3, + 3, 3, 3, 3, 3, 3, 3, 1, 1, 2, + 2, 2, 1, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 3 +}; -/* Like YYERROR except do call yyerror. This remains here temporarily - to ease the transition to the new meaning of YYERROR, for GCC. - Once GCC version 2 has supplanted version 1, this can go. */ +#define yyerrok (yyerrstatus = 0) +#define yyclearin (yychar = YYEMPTY) +#define YYEMPTY (-2) +#define YYEOF 0 + +#define YYACCEPT goto yyacceptlab +#define YYABORT goto yyabortlab +#define YYERROR goto yyerrorlab -#define YYFAIL goto yyerrlab #define YYRECOVERING() (!!yyerrstatus) -#define YYBACKUP(Token, Value) \ -do \ - if (yychar == YYEMPTY && yylen == 1) \ - { \ - yychar = (Token); \ - yylval = (Value); \ - yytoken = YYTRANSLATE (yychar); \ - YYPOPSTACK (1); \ - goto yybackup; \ - } \ - else \ - { \ +#define YYBACKUP(Token, Value) \ +do \ + if (yychar == YYEMPTY) \ + { \ + yychar = (Token); \ + yylval = (Value); \ + YYPOPSTACK (yylen); \ + yystate = *yyssp; \ + goto yybackup; \ + } \ + else \ + { \ yyerror (p, scanner, YY_("syntax error: cannot back up")); \ - YYERROR; \ - } \ -while (YYID (0)) + YYERROR; \ + } \ +while (0) + +/* Error token number */ +#define YYTERROR 1 +#define YYERRCODE 256 -#define YYTERROR 1 -#define YYERRCODE 256 - - -/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N]. - If N is 0, then set CURRENT to the empty location which ends - the previous symbol: RHS[0] (always defined). */ - -#define YYRHSLOC(Rhs, K) ((Rhs)[K]) -#ifndef YYLLOC_DEFAULT -# define YYLLOC_DEFAULT(Current, Rhs, N) \ - do \ - if (YYID (N)) \ - { \ - (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ - (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ - (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ - (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ - } \ - else \ - { \ - (Current).first_line = (Current).last_line = \ - YYRHSLOC (Rhs, 0).last_line; \ - (Current).first_column = (Current).last_column = \ - YYRHSLOC (Rhs, 0).last_column; \ - } \ - while (YYID (0)) -#endif - - -/* YY_LOCATION_PRINT -- Print the location on the stream. - This macro was not mandated originally: define only if we know - we won't break user code: when these are the locations we know. */ - -#ifndef YY_LOCATION_PRINT -# if YYLTYPE_IS_TRIVIAL -# define YY_LOCATION_PRINT(File, Loc) \ - fprintf (File, "%d.%d-%d.%d", \ - (Loc).first_line, (Loc).first_column, \ - (Loc).last_line, (Loc).last_column) -# else -# define YY_LOCATION_PRINT(File, Loc) ((void) 0) -# endif -#endif - - -/* YYLEX -- calling `yylex' with the right arguments. */ - -#ifdef YYLEX_PARAM -# define YYLEX yylex (&yylval, YYLEX_PARAM) -#else -# define YYLEX yylex (&yylval, scanner) -#endif /* Enable debugging if requested. */ #if YYDEBUG @@ -827,58 +752,48 @@ while (YYID (0)) # define YYFPRINTF fprintf # endif -# define YYDPRINTF(Args) \ -do { \ - if (yydebug) \ - YYFPRINTF Args; \ -} while (YYID (0)) +# define YYDPRINTF(Args) \ +do { \ + if (yydebug) \ + YYFPRINTF Args; \ +} while (0) -# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ -do { \ - if (yydebug) \ - { \ - YYFPRINTF (stderr, "%s ", Title); \ - yy_symbol_print (stderr, \ - Type, Value, p, scanner); \ - YYFPRINTF (stderr, "\n"); \ - } \ -} while (YYID (0)) +/* This macro is provided for backward compatibility. */ +#ifndef YY_LOCATION_PRINT +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +#endif -/*--------------------------------. -| Print this symbol on YYOUTPUT. | -`--------------------------------*/ +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ +do { \ + if (yydebug) \ + { \ + YYFPRINTF (stderr, "%s ", Title); \ + yy_symbol_print (stderr, \ + Type, Value, p, scanner); \ + YYFPRINTF (stderr, "\n"); \ + } \ +} while (0) + + +/*----------------------------------------. +| Print this symbol's value on YYOUTPUT. | +`----------------------------------------*/ -/*ARGSUSED*/ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) static void yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, parser_param* p, void* scanner) -#else -static void -yy_symbol_value_print (yyoutput, yytype, yyvaluep, p, scanner) - FILE *yyoutput; - int yytype; - YYSTYPE const * const yyvaluep; - parser_param* p; - void* scanner; -#endif { - if (!yyvaluep) - return; + FILE *yyo = yyoutput; + YYUSE (yyo); YYUSE (p); YYUSE (scanner); + if (!yyvaluep) + return; # ifdef YYPRINT if (yytype < YYNTOKENS) YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); -# else - YYUSE (yyoutput); # endif - switch (yytype) - { - default: - break; - } + YYUSE (yytype); } @@ -886,24 +801,11 @@ yy_symbol_value_print (yyoutput, yytype, yyvaluep, p, scanner) | Print this symbol on YYOUTPUT. | `--------------------------------*/ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) static void yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, parser_param* p, void* scanner) -#else -static void -yy_symbol_print (yyoutput, yytype, yyvaluep, p, scanner) - FILE *yyoutput; - int yytype; - YYSTYPE const * const yyvaluep; - parser_param* p; - void* scanner; -#endif { - if (yytype < YYNTOKENS) - YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); - else - YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); + YYFPRINTF (yyoutput, "%s %s (", + yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]); yy_symbol_value_print (yyoutput, yytype, yyvaluep, p, scanner); YYFPRINTF (yyoutput, ")"); @@ -914,16 +816,8 @@ yy_symbol_print (yyoutput, yytype, yyvaluep, p, scanner) | TOP (included). | `------------------------------------------------------------------*/ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) static void yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) -#else -static void -yy_stack_print (yybottom, yytop) - yytype_int16 *yybottom; - yytype_int16 *yytop; -#endif { YYFPRINTF (stderr, "Stack now"); for (; yybottom <= yytop; yybottom++) @@ -934,51 +828,42 @@ yy_stack_print (yybottom, yytop) YYFPRINTF (stderr, "\n"); } -# define YY_STACK_PRINT(Bottom, Top) \ -do { \ - if (yydebug) \ - yy_stack_print ((Bottom), (Top)); \ -} while (YYID (0)) +# define YY_STACK_PRINT(Bottom, Top) \ +do { \ + if (yydebug) \ + yy_stack_print ((Bottom), (Top)); \ +} while (0) /*------------------------------------------------. | Report that the YYRULE is going to be reduced. | `------------------------------------------------*/ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) static void -yy_reduce_print (YYSTYPE *yyvsp, int yyrule, parser_param* p, void* scanner) -#else -static void -yy_reduce_print (yyvsp, yyrule, p, scanner) - YYSTYPE *yyvsp; - int yyrule; - parser_param* p; - void* scanner; -#endif +yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, int yyrule, parser_param* p, void* scanner) { + unsigned long int yylno = yyrline[yyrule]; int yynrhs = yyr2[yyrule]; int yyi; - unsigned long int yylno = yyrline[yyrule]; YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", - yyrule - 1, yylno); + yyrule - 1, yylno); /* The symbols being reduced. */ for (yyi = 0; yyi < yynrhs; yyi++) { YYFPRINTF (stderr, " $%d = ", yyi + 1); - yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], - &(yyvsp[(yyi + 1) - (yynrhs)]) - , p, scanner); + yy_symbol_print (stderr, + yystos[yyssp[yyi + 1 - yynrhs]], + &(yyvsp[(yyi + 1) - (yynrhs)]) + , p, scanner); YYFPRINTF (stderr, "\n"); } } -# define YY_REDUCE_PRINT(Rule) \ -do { \ - if (yydebug) \ - yy_reduce_print (yyvsp, Rule, p, scanner); \ -} while (YYID (0)) +# define YY_REDUCE_PRINT(Rule) \ +do { \ + if (yydebug) \ + yy_reduce_print (yyssp, yyvsp, Rule, p, scanner); \ +} while (0) /* Nonzero means print parse trace. It is left uninitialized so that multiple parsers can coexist. */ @@ -992,7 +877,7 @@ int yydebug; /* YYINITDEPTH -- initial size of the parser's stacks. */ -#ifndef YYINITDEPTH +#ifndef YYINITDEPTH # define YYINITDEPTH 200 #endif @@ -1007,7 +892,6 @@ int yydebug; # define YYMAXDEPTH 10000 #endif - #if YYERROR_VERBOSE @@ -1016,15 +900,8 @@ int yydebug; # define yystrlen strlen # else /* Return the length of YYSTR. */ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) static YYSIZE_T yystrlen (const char *yystr) -#else -static YYSIZE_T -yystrlen (yystr) - const char *yystr; -#endif { YYSIZE_T yylen; for (yylen = 0; yystr[yylen]; yylen++) @@ -1040,16 +917,8 @@ yystrlen (yystr) # else /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in YYDEST. */ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) static char * yystpcpy (char *yydest, const char *yysrc) -#else -static char * -yystpcpy (yydest, yysrc) - char *yydest; - const char *yysrc; -#endif { char *yyd = yydest; const char *yys = yysrc; @@ -1079,27 +948,27 @@ yytnamerr (char *yyres, const char *yystr) char const *yyp = yystr; for (;;) - switch (*++yyp) - { - case '\'': - case ',': - goto do_not_strip_quotes; + switch (*++yyp) + { + case '\'': + case ',': + goto do_not_strip_quotes; - case '\\': - if (*++yyp != '\\') - goto do_not_strip_quotes; - /* Fall through. */ - default: - if (yyres) - yyres[yyn] = *yyp; - yyn++; - break; + case '\\': + if (*++yyp != '\\') + goto do_not_strip_quotes; + /* Fall through. */ + default: + if (yyres) + yyres[yyn] = *yyp; + yyn++; + break; - case '"': - if (yyres) - yyres[yyn] = '\0'; - return yyn; - } + case '"': + if (yyres) + yyres[yyn] = '\0'; + return yyn; + } do_not_strip_quotes: ; } @@ -1110,202 +979,180 @@ yytnamerr (char *yyres, const char *yystr) } # endif -/* Copy into YYRESULT an error message about the unexpected token - YYCHAR while in state YYSTATE. Return the number of bytes copied, - including the terminating null byte. If YYRESULT is null, do not - copy anything; just return the number of bytes that would be - copied. As a special case, return 0 if an ordinary "syntax error" - message will do. Return YYSIZE_MAXIMUM if overflow occurs during - size calculation. */ -static YYSIZE_T -yysyntax_error (char *yyresult, int yystate, int yychar) +/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message + about the unexpected token YYTOKEN for the state stack whose top is + YYSSP. + + Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is + not large enough to hold the message. In that case, also set + *YYMSG_ALLOC to the required number of bytes. Return 2 if the + required number of bytes is too large to store. */ +static int +yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, + yytype_int16 *yyssp, int yytoken) { - int yyn = yypact[yystate]; + YYSIZE_T yysize0 = yytnamerr (YY_NULLPTR, yytname[yytoken]); + YYSIZE_T yysize = yysize0; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + /* Internationalized format string. */ + const char *yyformat = YY_NULLPTR; + /* Arguments of yyformat. */ + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + /* Number of reported tokens (one for the "unexpected", one per + "expected"). */ + int yycount = 0; - if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) - return 0; - else + /* There are many possibilities here to consider: + - If this state is a consistent state with a default action, then + the only way this function was invoked is if the default action + is an error action. In that case, don't check for expected + tokens because there are none. + - The only way there can be no lookahead present (in yychar) is if + this state is a consistent state with a default action. Thus, + detecting the absence of a lookahead is sufficient to determine + that there is no unexpected or expected token to report. In that + case, just report a simple "syntax error". + - Don't assume there isn't a lookahead just because this state is a + consistent state with a default action. There might have been a + previous inconsistent state, consistent state with a non-default + action, or user semantic action that manipulated yychar. + - Of course, the expected token list depends on states to have + correct lookahead information, and it depends on the parser not + to perform extra reductions after fetching a lookahead from the + scanner and before detecting a syntax error. Thus, state merging + (from LALR or IELR) and default reductions corrupt the expected + token list. However, the list is correct for canonical LR with + one exception: it will still contain any token that will not be + accepted due to an error action in a later state. + */ + if (yytoken != YYEMPTY) { - int yytype = YYTRANSLATE (yychar); - YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); - YYSIZE_T yysize = yysize0; - YYSIZE_T yysize1; - int yysize_overflow = 0; - enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; - char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; - int yyx; + int yyn = yypact[*yyssp]; + yyarg[yycount++] = yytname[yytoken]; + if (!yypact_value_is_default (yyn)) + { + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. In other words, skip the first -YYN actions for + this state because they are default actions. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yyx; -# if 0 - /* This is so xgettext sees the translatable formats that are - constructed on the fly. */ - YY_("syntax error, unexpected %s"); - YY_("syntax error, unexpected %s, expecting %s"); - YY_("syntax error, unexpected %s, expecting %s or %s"); - YY_("syntax error, unexpected %s, expecting %s or %s or %s"); - YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); -# endif - char *yyfmt; - char const *yyf; - static char const yyunexpected[] = "syntax error, unexpected %s"; - static char const yyexpecting[] = ", expecting %s"; - static char const yyor[] = " or %s"; - char yyformat[sizeof yyunexpected - + sizeof yyexpecting - 1 - + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) - * (sizeof yyor - 1))]; - char const *yyprefix = yyexpecting; - - /* Start YYX at -YYN if negative to avoid negative indexes in - YYCHECK. */ - int yyxbegin = yyn < 0 ? -yyn : 0; - - /* Stay within bounds of both yycheck and yytname. */ - int yychecklim = YYLAST - yyn + 1; - int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; - int yycount = 1; - - yyarg[0] = yytname[yytype]; - yyfmt = yystpcpy (yyformat, yyunexpected); - - for (yyx = yyxbegin; yyx < yyxend; ++yyx) - if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) - { - if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) - { - yycount = 1; - yysize = yysize0; - yyformat[sizeof yyunexpected - 1] = '\0'; - break; - } - yyarg[yycount++] = yytname[yyx]; - yysize1 = yysize + yytnamerr (0, yytname[yyx]); - yysize_overflow |= (yysize1 < yysize); - yysize = yysize1; - yyfmt = yystpcpy (yyfmt, yyprefix); - yyprefix = yyor; - } - - yyf = YY_(yyformat); - yysize1 = yysize + yystrlen (yyf); - yysize_overflow |= (yysize1 < yysize); - yysize = yysize1; - - if (yysize_overflow) - return YYSIZE_MAXIMUM; - - if (yyresult) - { - /* Avoid sprintf, as that infringes on the user's name space. - Don't have undefined behavior even if the translation - produced a string with the wrong number of "%s"s. */ - char *yyp = yyresult; - int yyi = 0; - while ((*yyp = *yyf) != '\0') - { - if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) - { - yyp += yytnamerr (yyp, yyarg[yyi++]); - yyf += 2; - } - else - { - yyp++; - yyf++; - } - } - } - return yysize; + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR + && !yytable_value_is_error (yytable[yyx + yyn])) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + break; + } + yyarg[yycount++] = yytname[yyx]; + { + YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]); + if (! (yysize <= yysize1 + && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) + return 2; + yysize = yysize1; + } + } + } } + + switch (yycount) + { +# define YYCASE_(N, S) \ + case N: \ + yyformat = S; \ + break + YYCASE_(0, YY_("syntax error")); + YYCASE_(1, YY_("syntax error, unexpected %s")); + YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s")); + YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s")); + YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s")); + YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s")); +# undef YYCASE_ + } + + { + YYSIZE_T yysize1 = yysize + yystrlen (yyformat); + if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) + return 2; + yysize = yysize1; + } + + if (*yymsg_alloc < yysize) + { + *yymsg_alloc = 2 * yysize; + if (! (yysize <= *yymsg_alloc + && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM)) + *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM; + return 1; + } + + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + { + char *yyp = *yymsg; + int yyi = 0; + while ((*yyp = *yyformat) != '\0') + if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyformat += 2; + } + else + { + yyp++; + yyformat++; + } + } + return 0; } #endif /* YYERROR_VERBOSE */ - /*-----------------------------------------------. | Release the memory associated to this symbol. | `-----------------------------------------------*/ -/*ARGSUSED*/ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) static void yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, parser_param* p, void* scanner) -#else -static void -yydestruct (yymsg, yytype, yyvaluep, p, scanner) - const char *yymsg; - int yytype; - YYSTYPE *yyvaluep; - parser_param* p; - void* scanner; -#endif { YYUSE (yyvaluep); YYUSE (p); YYUSE (scanner); - if (!yymsg) yymsg = "Deleting"; YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); - switch (yytype) - { - - default: - break; - } + YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN + YYUSE (yytype); + YY_IGNORE_MAYBE_UNINITIALIZED_END } -/* Prevent warnings from -Wmissing-prototypes. */ -#ifdef YYPARSE_PARAM -#if defined __STDC__ || defined __cplusplus -int yyparse (void *YYPARSE_PARAM); -#else -int yyparse (); -#endif -#else /* ! YYPARSE_PARAM */ -#if defined __STDC__ || defined __cplusplus -int yyparse (parser_param* p, void* scanner); -#else -int yyparse (); -#endif -#endif /* ! YYPARSE_PARAM */ +/*----------. +| yyparse. | +`----------*/ - -/*-------------------------. -| yyparse or yypush_parse. | -`-------------------------*/ - -#ifdef YYPARSE_PARAM -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) -int -yyparse (void *YYPARSE_PARAM) -#else -int -yyparse (YYPARSE_PARAM) - void *YYPARSE_PARAM; -#endif -#else /* ! YYPARSE_PARAM */ -#if (defined __STDC__ || defined __C99__FUNC__ \ - || defined __cplusplus || defined _MSC_VER) int yyparse (parser_param* p, void* scanner) -#else -int -yyparse (p, scanner) - parser_param* p; - void* scanner; -#endif -#endif { /* The lookahead symbol. */ int yychar; + /* The semantic value of the lookahead symbol. */ -YYSTYPE yylval; +/* Default value used for initialization, for pacifying older GCCs + or non-GCC compilers. */ +YY_INITIAL_VALUE (static YYSTYPE yyval_default;) +YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default); /* Number of syntax errors so far. */ int yynerrs; @@ -1315,10 +1162,10 @@ YYSTYPE yylval; int yyerrstatus; /* The stacks and their tools: - `yyss': related to states. - `yyvs': related to semantic values. + 'yyss': related to states. + 'yyvs': related to semantic values. - Refer to the stacks thru separate pointers, to allow yyoverflow + Refer to the stacks through separate pointers, to allow yyoverflow to reallocate them elsewhere. */ /* The state stack. */ @@ -1336,7 +1183,7 @@ YYSTYPE yylval; int yyn; int yyresult; /* Lookahead token as an internal (translated) token number. */ - int yytoken; + int yytoken = 0; /* The variables used to return semantic value and location from the action routines. */ YYSTYPE yyval; @@ -1354,9 +1201,8 @@ YYSTYPE yylval; Keep to zero when no symbol should be popped. */ int yylen = 0; - yytoken = 0; - yyss = yyssa; - yyvs = yyvsa; + yyssp = yyss = yyssa; + yyvsp = yyvs = yyvsa; yystacksize = YYINITDEPTH; YYDPRINTF ((stderr, "Starting parse\n")); @@ -1365,14 +1211,6 @@ YYSTYPE yylval; yyerrstatus = 0; yynerrs = 0; yychar = YYEMPTY; /* Cause a token to be read. */ - - /* Initialize stack pointers. - Waste one element of value and location stack - so that they stay on the same level as the state stack. - The wasted elements are never initialized. */ - yyssp = yyss; - yyvsp = yyvs; - goto yysetstate; /*------------------------------------------------------------. @@ -1393,23 +1231,23 @@ YYSTYPE yylval; #ifdef yyoverflow { - /* Give user a chance to reallocate the stack. Use copies of - these so that the &'s don't force the real ones into - memory. */ - YYSTYPE *yyvs1 = yyvs; - yytype_int16 *yyss1 = yyss; + /* Give user a chance to reallocate the stack. Use copies of + these so that the &'s don't force the real ones into + memory. */ + YYSTYPE *yyvs1 = yyvs; + yytype_int16 *yyss1 = yyss; - /* Each stack pointer address is followed by the size of the - data in use in that stack, in bytes. This used to be a - conditional around just the two extra args, but that might - be undefined if yyoverflow is a macro. */ - yyoverflow (YY_("memory exhausted"), - &yyss1, yysize * sizeof (*yyssp), - &yyvs1, yysize * sizeof (*yyvsp), - &yystacksize); + /* Each stack pointer address is followed by the size of the + data in use in that stack, in bytes. This used to be a + conditional around just the two extra args, but that might + be undefined if yyoverflow is a macro. */ + yyoverflow (YY_("memory exhausted"), + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yystacksize); - yyss = yyss1; - yyvs = yyvs1; + yyss = yyss1; + yyvs = yyvs1; } #else /* no yyoverflow */ # ifndef YYSTACK_RELOCATE @@ -1417,22 +1255,22 @@ YYSTYPE yylval; # else /* Extend the stack our own way. */ if (YYMAXDEPTH <= yystacksize) - goto yyexhaustedlab; + goto yyexhaustedlab; yystacksize *= 2; if (YYMAXDEPTH < yystacksize) - yystacksize = YYMAXDEPTH; + yystacksize = YYMAXDEPTH; { - yytype_int16 *yyss1 = yyss; - union yyalloc *yyptr = - (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); - if (! yyptr) - goto yyexhaustedlab; - YYSTACK_RELOCATE (yyss_alloc, yyss); - YYSTACK_RELOCATE (yyvs_alloc, yyvs); + yytype_int16 *yyss1 = yyss; + union yyalloc *yyptr = + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); + if (! yyptr) + goto yyexhaustedlab; + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); # undef YYSTACK_RELOCATE - if (yyss1 != yyssa) - YYSTACK_FREE (yyss1); + if (yyss1 != yyssa) + YYSTACK_FREE (yyss1); } # endif #endif /* no yyoverflow */ @@ -1441,10 +1279,10 @@ YYSTYPE yylval; yyvsp = yyvs + yysize - 1; YYDPRINTF ((stderr, "Stack size increased to %lu\n", - (unsigned long int) yystacksize)); + (unsigned long int) yystacksize)); if (yyss + yystacksize - 1 <= yyssp) - YYABORT; + YYABORT; } YYDPRINTF ((stderr, "Entering state %d\n", yystate)); @@ -1464,7 +1302,7 @@ yybackup: /* First try to decide what to do without reference to lookahead token. */ yyn = yypact[yystate]; - if (yyn == YYPACT_NINF) + if (yypact_value_is_default (yyn)) goto yydefault; /* Not known => get a lookahead token if don't already have one. */ @@ -1473,7 +1311,7 @@ yybackup: if (yychar == YYEMPTY) { YYDPRINTF ((stderr, "Reading a token: ")); - yychar = YYLEX; + yychar = yylex (&yylval, scanner); } if (yychar <= YYEOF) @@ -1495,8 +1333,8 @@ yybackup: yyn = yytable[yyn]; if (yyn <= 0) { - if (yyn == 0 || yyn == YYTABLE_NINF) - goto yyerrlab; + if (yytable_value_is_error (yyn)) + goto yyerrlab; yyn = -yyn; goto yyreduce; } @@ -1513,7 +1351,9 @@ yybackup: yychar = YYEMPTY; yystate = yyn; + YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN *++yyvsp = yylval; + YY_IGNORE_MAYBE_UNINITIALIZED_END goto yynewstate; @@ -1536,7 +1376,7 @@ yyreduce: yylen = yyr2[yyn]; /* If YYLEN is nonzero, implement the default value of the action: - `$$ = $1'. + '$$ = $1'. Otherwise, the following line sets YYVAL to garbage. This behavior is undocumented and Bison @@ -1550,875 +1390,832 @@ yyreduce: switch (yyn) { case 2: - -/* Line 1455 of yacc.c */ -#line 87 "xslpattern.y" +#line 87 "xslpattern.y" /* yacc.c:1646 */ { - p->out = (yyvsp[(1) - (1)]); - ;} + p->out = (yyvsp[0]); + } +#line 1401 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 5: - -/* Line 1455 of yacc.c */ -#line 100 "xslpattern.y" +#line 100 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got PrefixedName: \"%s:%s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); + TRACE("Got PrefixedName: \"%s:%s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); (yyval)=xmlStrcat((yyval),U(":")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1413 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 6: - -/* Line 1455 of yacc.c */ -#line 109 "xslpattern.y" +#line 109 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got UnprefixedName: \"%s\"\n", (yyvsp[(1) - (1)])); - (yyval)=(yyvsp[(1) - (1)]); - ;} + TRACE("Got UnprefixedName: \"%s\"\n", (yyvsp[0])); + (yyval)=(yyvsp[0]); + } +#line 1422 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 9: - -/* Line 1455 of yacc.c */ -#line 123 "xslpattern.y" +#line 123 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got AbsoluteLocationPath: \"/%s\"\n", (yyvsp[(2) - (2)])); + TRACE("Got AbsoluteLocationPath: \"/%s\"\n", (yyvsp[0])); (yyval)=xmlStrdup(U("/")); - (yyval)=xmlStrcat((yyval),(yyvsp[(2) - (2)])); - xmlFree((yyvsp[(2) - (2)])); - ;} + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1433 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 10: - -/* Line 1455 of yacc.c */ -#line 130 "xslpattern.y" +#line 130 "xslpattern.y" /* yacc.c:1646 */ { TRACE("Got AbsoluteLocationPath: \"/\"\n"); (yyval)=xmlStrdup(U("/")); - ;} + } +#line 1442 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 13: - -/* Line 1455 of yacc.c */ -#line 138 "xslpattern.y" +#line 138 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got RelativeLocationPath: \"%s/%s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); + TRACE("Got RelativeLocationPath: \"%s/%s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); (yyval)=xmlStrcat((yyval),U("/")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1454 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 15: - -/* Line 1455 of yacc.c */ -#line 149 "xslpattern.y" +#line 149 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got Step: \"%s%s%s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(2) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),(yyvsp[(2) - (3)])); - xmlFree((yyvsp[(2) - (3)])); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + TRACE("Got Step: \"%s%s%s\"\n", (yyvsp[-2]), (yyvsp[-1]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),(yyvsp[-1])); + xmlFree((yyvsp[-1])); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1467 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 16: - -/* Line 1455 of yacc.c */ -#line 158 "xslpattern.y" +#line 158 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got Step: \"%s%s\"\n", (yyvsp[(1) - (2)]), (yyvsp[(2) - (2)])); - (yyval)=(yyvsp[(1) - (2)]); - (yyval)=xmlStrcat((yyval),(yyvsp[(2) - (2)])); - xmlFree((yyvsp[(2) - (2)])); - ;} + TRACE("Got Step: \"%s%s\"\n", (yyvsp[-1]), (yyvsp[0])); + (yyval)=(yyvsp[-1]); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1478 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 17: - -/* Line 1455 of yacc.c */ -#line 165 "xslpattern.y" +#line 165 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got Step: \"%s%s\"\n", (yyvsp[(1) - (2)]), (yyvsp[(2) - (2)])); - (yyval)=(yyvsp[(1) - (2)]); - (yyval)=xmlStrcat((yyval),(yyvsp[(2) - (2)])); - xmlFree((yyvsp[(2) - (2)])); - ;} + TRACE("Got Step: \"%s%s\"\n", (yyvsp[-1]), (yyvsp[0])); + (yyval)=(yyvsp[-1]); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1489 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 21: - -/* Line 1455 of yacc.c */ -#line 176 "xslpattern.y" +#line 176 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got AxisSpecifier: \"%s::\"\n", (yyvsp[(1) - (2)])); - (yyval)=(yyvsp[(1) - (2)]); + TRACE("Got AxisSpecifier: \"%s::\"\n", (yyvsp[-1])); + (yyval)=(yyvsp[-1]); (yyval)=xmlStrcat((yyval),U("::")); - ;} + } +#line 1499 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 22: - -/* Line 1455 of yacc.c */ -#line 183 "xslpattern.y" +#line 183 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got Attribute: \"@%s\"\n", (yyvsp[(2) - (2)])); + TRACE("Got Attribute: \"@%s\"\n", (yyvsp[0])); (yyval)=xmlStrdup(U("@")); - (yyval)=xmlStrcat((yyval),(yyvsp[(2) - (2)])); - xmlFree((yyvsp[(2) - (2)])); - ;} + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1510 "xslpattern.tab.c" /* yacc.c:1646 */ break; - case 25: - -/* Line 1455 of yacc.c */ -#line 196 "xslpattern.y" + case 23: +#line 190 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got NameTest: \"*\"\n"); - (yyval)=xmlStrdup(U("*")); - ;} + TRACE("Got All attributes pattern: \"@*\"\n"); + (yyval)=xmlStrdup(U("@*")); + } +#line 1519 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 26: - -/* Line 1455 of yacc.c */ -#line 201 "xslpattern.y" +#line 201 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got NameTest: \"%s:*\"\n", (yyvsp[(1) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U(":*")); - ;} + TRACE("Got NameTest: \"*\"\n"); + (yyval)=xmlStrdup(U("*")); + } +#line 1528 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 27: +#line 206 "xslpattern.y" /* yacc.c:1646 */ + { + TRACE("Got NameTest: \"%s:*\"\n", (yyvsp[-2])); + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U(":*")); + } +#line 1538 "xslpattern.tab.c" /* yacc.c:1646 */ + break; -/* Line 1455 of yacc.c */ -#line 207 "xslpattern.y" + case 28: +#line 212 "xslpattern.y" /* yacc.c:1646 */ { /* PrefixedName */ - xmlChar const* registeredNsURI = xmlXPathNsLookup(p->ctx, (yyvsp[(1) - (3)])); - TRACE("Got PrefixedName: \"%s:%s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); + xmlChar const* registeredNsURI = xmlXPathNsLookup(p->ctx, (yyvsp[-2])); + TRACE("Got PrefixedName: \"%s:%s\"\n", (yyvsp[-2]), (yyvsp[0])); if (registeredNsURI) (yyval)=xmlStrdup(U("")); else (yyval)=xmlStrdup(NameTest_mod_pre); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (3)])); - xmlFree((yyvsp[(1) - (3)])); + (yyval)=xmlStrcat((yyval),(yyvsp[-2])); + xmlFree((yyvsp[-2])); (yyval)=xmlStrcat((yyval),U(":")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); if (!registeredNsURI) (yyval)=xmlStrcat((yyval),NameTest_mod_post); - ;} - break; - - case 28: - -/* Line 1455 of yacc.c */ -#line 226 "xslpattern.y" - { - (yyval)=xmlStrdup(NameTest_mod_pre); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (1)])); - xmlFree((yyvsp[(1) - (1)])); - (yyval)=xmlStrcat((yyval),NameTest_mod_post); - ;} + } +#line 1561 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 29: - -/* Line 1455 of yacc.c */ -#line 234 "xslpattern.y" +#line 231 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=(yyvsp[(1) - (2)]); - (yyval)=xmlStrcat((yyval),(yyvsp[(2) - (2)])); - xmlFree((yyvsp[(2) - (2)])); - ;} + (yyval)=xmlStrdup(NameTest_mod_pre); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + (yyval)=xmlStrcat((yyval),NameTest_mod_post); + } +#line 1572 "xslpattern.tab.c" /* yacc.c:1646 */ break; - case 31: - -/* Line 1455 of yacc.c */ -#line 242 "xslpattern.y" + case 30: +#line 239 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got Predicate: \"[%s]\"\n", (yyvsp[(2) - (3)])); - (yyval)=xmlStrdup(U("[")); - (yyval)=xmlStrcat((yyval),(yyvsp[(2) - (3)])); - xmlFree((yyvsp[(2) - (3)])); - (yyval)=xmlStrcat((yyval),U("]")); - ;} + (yyval)=(yyvsp[-1]); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1582 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 32: - -/* Line 1455 of yacc.c */ -#line 251 "xslpattern.y" +#line 247 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=xmlStrdup(U("index()=")); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (1)])); - xmlFree((yyvsp[(1) - (1)])); - ;} + TRACE("Got Predicate: \"[%s]\"\n", (yyvsp[-1])); + (yyval)=xmlStrdup(U("[")); + (yyval)=xmlStrcat((yyval),(yyvsp[-1])); + xmlFree((yyvsp[-1])); + (yyval)=xmlStrcat((yyval),U("]")); + } +#line 1594 "xslpattern.tab.c" /* yacc.c:1646 */ break; - case 36: - -/* Line 1455 of yacc.c */ -#line 262 "xslpattern.y" + case 33: +#line 256 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got AbbreviatedAbsoluteLocationPath: \"//%s\"\n", (yyvsp[(2) - (2)])); - (yyval)=xmlStrdup(U("//")); - (yyval)=xmlStrcat((yyval),(yyvsp[(2) - (2)])); - xmlFree((yyvsp[(2) - (2)])); - ;} + (yyval)=xmlStrdup(U("index()=")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1604 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 37: - -/* Line 1455 of yacc.c */ -#line 270 "xslpattern.y" +#line 267 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got AbbreviatedRelativeLocationPath: \"%s//%s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U("//")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + TRACE("Got AbbreviatedAbsoluteLocationPath: \"//%s\"\n", (yyvsp[0])); + (yyval)=xmlStrdup(U("//")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1615 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 38: - -/* Line 1455 of yacc.c */ -#line 279 "xslpattern.y" +#line 275 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got AbbreviatedStep: \"..\"\n"); - (yyval)=xmlStrdup(U("..")); - ;} + TRACE("Got AbbreviatedRelativeLocationPath: \"%s//%s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U("//")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1627 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 39: +#line 284 "xslpattern.y" /* yacc.c:1646 */ + { + TRACE("Got AbbreviatedStep: \"..\"\n"); + (yyval)=xmlStrdup(U("..")); + } +#line 1636 "xslpattern.tab.c" /* yacc.c:1646 */ + break; -/* Line 1455 of yacc.c */ -#line 284 "xslpattern.y" + case 40: +#line 289 "xslpattern.y" /* yacc.c:1646 */ { TRACE("Got AbbreviatedStep: \".\"\n"); (yyval)=xmlStrdup(U(".")); - ;} - break; - - case 47: - -/* Line 1455 of yacc.c */ -#line 302 "xslpattern.y" - { - TRACE("Got PrimaryExpr: \"(%s)\"\n", (yyvsp[(1) - (3)])); - (yyval)=xmlStrdup(U("(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(2) - (3)])); - xmlFree((yyvsp[(2) - (3)])); - (yyval)=xmlStrcat((yyval),U(")")); - ;} + } +#line 1645 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 48: - -/* Line 1455 of yacc.c */ -#line 310 "xslpattern.y" +#line 307 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got PrimaryExpr: \"%s!%s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U("/")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + TRACE("Got PrimaryExpr: \"(%s)\"\n", (yyvsp[-2])); + (yyval)=xmlStrdup(U("(")); + (yyval)=xmlStrcat((yyval),(yyvsp[-1])); + xmlFree((yyvsp[-1])); + (yyval)=xmlStrcat((yyval),U(")")); + } +#line 1657 "xslpattern.tab.c" /* yacc.c:1646 */ break; - case 51: - -/* Line 1455 of yacc.c */ -#line 322 "xslpattern.y" + case 49: +#line 315 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got FunctionCall: \"%s(%s)\"\n", (yyvsp[(1) - (4)]), (yyvsp[(3) - (4)])); - if (xmlStrEqual((yyvsp[(1) - (4)]),U("ancestor"))) + TRACE("Got PrimaryExpr: \"%s!%s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U("/")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1669 "xslpattern.tab.c" /* yacc.c:1646 */ + break; + + case 52: +#line 327 "xslpattern.y" /* yacc.c:1646 */ + { + TRACE("Got FunctionCall: \"%s(%s)\"\n", (yyvsp[-3]), (yyvsp[-1])); + if (xmlStrEqual((yyvsp[-3]),U("ancestor"))) { - (yyval)=(yyvsp[(1) - (4)]); + (yyval)=(yyvsp[-3]); (yyval)=xmlStrcat((yyval),U("::")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (4)])); - xmlFree((yyvsp[(3) - (4)])); + (yyval)=xmlStrcat((yyval),(yyvsp[-1])); + xmlFree((yyvsp[-1])); } - else if (xmlStrEqual((yyvsp[(1) - (4)]),U("attribute"))) + else if (xmlStrEqual((yyvsp[-3]),U("attribute"))) { - if (is_literal((yyvsp[(3) - (4)]))) + if (is_literal((yyvsp[-1]))) { (yyval)=xmlStrdup(U("@*[name()=")); - xmlFree((yyvsp[(1) - (4)])); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (4)])); - xmlFree((yyvsp[(3) - (4)])); + xmlFree((yyvsp[-3])); + (yyval)=xmlStrcat((yyval),(yyvsp[-1])); + xmlFree((yyvsp[-1])); (yyval)=xmlStrcat((yyval),U("]")); } else { /* XML_XPATH_INVALID_TYPE */ (yyval)=xmlStrdup(U("error(1211, 'Error: attribute(")); - xmlFree((yyvsp[(1) - (4)])); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (4)])); - xmlFree((yyvsp[(3) - (4)])); + xmlFree((yyvsp[-3])); + (yyval)=xmlStrcat((yyval),(yyvsp[-1])); + xmlFree((yyvsp[-1])); (yyval)=xmlStrcat((yyval),U("): invalid argument')")); } } - else if (xmlStrEqual((yyvsp[(1) - (4)]),U("element"))) + else if (xmlStrEqual((yyvsp[-3]),U("element"))) { - if (is_literal((yyvsp[(3) - (4)]))) + if (is_literal((yyvsp[-1]))) { (yyval)=xmlStrdup(U("node()[nodeType()=1][name()=")); - xmlFree((yyvsp[(1) - (4)])); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (4)])); - xmlFree((yyvsp[(3) - (4)])); + xmlFree((yyvsp[-3])); + (yyval)=xmlStrcat((yyval),(yyvsp[-1])); + xmlFree((yyvsp[-1])); (yyval)=xmlStrcat((yyval),U("]")); } else { /* XML_XPATH_INVALID_TYPE */ (yyval)=xmlStrdup(U("error(1211, 'Error: element(")); - xmlFree((yyvsp[(1) - (4)])); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (4)])); - xmlFree((yyvsp[(3) - (4)])); + xmlFree((yyvsp[-3])); + (yyval)=xmlStrcat((yyval),(yyvsp[-1])); + xmlFree((yyvsp[-1])); (yyval)=xmlStrcat((yyval),U("): invalid argument')")); } } else { - (yyval)=(yyvsp[(1) - (4)]); + (yyval)=(yyvsp[-3]); (yyval)=xmlStrcat((yyval),U("(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (4)])); - xmlFree((yyvsp[(3) - (4)])); + (yyval)=xmlStrcat((yyval),(yyvsp[-1])); + xmlFree((yyvsp[-1])); (yyval)=xmlStrcat((yyval),U(")")); } - ;} - break; - - case 52: - -/* Line 1455 of yacc.c */ -#line 381 "xslpattern.y" - { - TRACE("Got FunctionCall: \"%s()\"\n", (yyvsp[(1) - (3)])); - /* comment() & node() work the same in XPath */ - if (xmlStrEqual((yyvsp[(1) - (3)]),U("attribute"))) - { - (yyval)=xmlStrdup(U("@*")); - xmlFree((yyvsp[(1) - (3)])); - } - else if (xmlStrEqual((yyvsp[(1) - (3)]),U("element"))) - { - (yyval)=xmlStrdup(U("node()[nodeType()=1]")); - xmlFree((yyvsp[(1) - (3)])); - } - else if (xmlStrEqual((yyvsp[(1) - (3)]),U("pi"))) - { - (yyval)=xmlStrdup(U("processing-instruction()")); - xmlFree((yyvsp[(1) - (3)])); - } - else if (xmlStrEqual((yyvsp[(1) - (3)]),U("textnode"))) - { - (yyval)=xmlStrdup(U("text()")); - xmlFree((yyvsp[(1) - (3)])); - } - else - { - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U("()")); - } - ;} + } +#line 1732 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 53: - -/* Line 1455 of yacc.c */ -#line 412 "xslpattern.y" +#line 386 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=(yyvsp[(1) - (3)]); + TRACE("Got FunctionCall: \"%s()\"\n", (yyvsp[-2])); + /* comment() & node() work the same in XPath */ + if (xmlStrEqual((yyvsp[-2]),U("attribute"))) + { + (yyval)=xmlStrdup(U("@*")); + xmlFree((yyvsp[-2])); + } + else if (xmlStrEqual((yyvsp[-2]),U("element"))) + { + (yyval)=xmlStrdup(U("node()[nodeType()=1]")); + xmlFree((yyvsp[-2])); + } + else if (xmlStrEqual((yyvsp[-2]),U("pi"))) + { + (yyval)=xmlStrdup(U("processing-instruction()")); + xmlFree((yyvsp[-2])); + } + else if (xmlStrEqual((yyvsp[-2]),U("textnode"))) + { + (yyval)=xmlStrdup(U("text()")); + xmlFree((yyvsp[-2])); + } + else + { + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U("()")); + } + } +#line 1766 "xslpattern.tab.c" /* yacc.c:1646 */ + break; + + case 54: +#line 417 "xslpattern.y" /* yacc.c:1646 */ + { + (yyval)=(yyvsp[-2]); (yyval)=xmlStrcat((yyval),U(",")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1777 "xslpattern.tab.c" /* yacc.c:1646 */ break; - case 57: - -/* Line 1455 of yacc.c */ -#line 425 "xslpattern.y" + case 58: +#line 430 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got UnionExpr: \"%s|%s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); + TRACE("Got UnionExpr: \"%s|%s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); (yyval)=xmlStrcat((yyval),U("|")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} - break; - - case 59: - -/* Line 1455 of yacc.c */ -#line 435 "xslpattern.y" - { - TRACE("Got PathExpr: \"%s/%s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U("/")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1789 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 60: - -/* Line 1455 of yacc.c */ -#line 443 "xslpattern.y" +#line 440 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got PathExpr: \"%s//%s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); + TRACE("Got PathExpr: \"%s/%s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U("/")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1801 "xslpattern.tab.c" /* yacc.c:1646 */ + break; + + case 61: +#line 448 "xslpattern.y" /* yacc.c:1646 */ + { + TRACE("Got PathExpr: \"%s//%s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); (yyval)=xmlStrcat((yyval),U("//")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1813 "xslpattern.tab.c" /* yacc.c:1646 */ break; - case 63: - -/* Line 1455 of yacc.c */ -#line 454 "xslpattern.y" + case 64: +#line 459 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got FilterExpr: \"%s%s\"\n", (yyvsp[(1) - (2)]), (yyvsp[(2) - (2)])); - (yyval)=(yyvsp[(1) - (2)]); - (yyval)=xmlStrcat((yyval),(yyvsp[(2) - (2)])); - xmlFree((yyvsp[(2) - (2)])); - ;} + TRACE("Got FilterExpr: \"%s%s\"\n", (yyvsp[-1]), (yyvsp[0])); + (yyval)=(yyvsp[-1]); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1824 "xslpattern.tab.c" /* yacc.c:1646 */ break; - case 66: - -/* Line 1455 of yacc.c */ -#line 466 "xslpattern.y" + case 67: +#line 471 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got OrExpr: \"%s $or$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); + TRACE("Got OrExpr: \"%s $or$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); (yyval)=xmlStrcat((yyval),U(" or ")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1836 "xslpattern.tab.c" /* yacc.c:1646 */ break; - case 69: - -/* Line 1455 of yacc.c */ -#line 478 "xslpattern.y" + case 70: +#line 483 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got AndExpr: \"%s $and$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); + TRACE("Got AndExpr: \"%s $and$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); (yyval)=xmlStrcat((yyval),U(" and ")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} - break; - - case 72: - -/* Line 1455 of yacc.c */ -#line 490 "xslpattern.y" - { - TRACE("Got EqualityExpr: \"%s $eq$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U("=")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1848 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 73: - -/* Line 1455 of yacc.c */ -#line 498 "xslpattern.y" +#line 495 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got EqualityExpr: \"%s $ieq$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=xmlStrdup(U("OP_IEq(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (3)])); - xmlFree((yyvsp[(1) - (3)])); - (yyval)=xmlStrcat((yyval),U(",")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - (yyval)=xmlStrcat((yyval),U(")")); - ;} + TRACE("Got EqualityExpr: \"%s $eq$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U("=")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1860 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 74: - -/* Line 1455 of yacc.c */ -#line 509 "xslpattern.y" +#line 503 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got EqualityExpr: \"%s $ne$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U("!=")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + TRACE("Got EqualityExpr: \"%s $ieq$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=xmlStrdup(U("OP_IEq(")); + (yyval)=xmlStrcat((yyval),(yyvsp[-2])); + xmlFree((yyvsp[-2])); + (yyval)=xmlStrcat((yyval),U(",")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + (yyval)=xmlStrcat((yyval),U(")")); + } +#line 1875 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 75: - -/* Line 1455 of yacc.c */ -#line 517 "xslpattern.y" +#line 514 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got EqualityExpr: \"%s $ine$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=xmlStrdup(U("OP_INEq(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (3)])); - xmlFree((yyvsp[(1) - (3)])); - (yyval)=xmlStrcat((yyval),U(",")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - (yyval)=xmlStrcat((yyval),U(")")); - ;} + TRACE("Got EqualityExpr: \"%s $ne$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U("!=")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1887 "xslpattern.tab.c" /* yacc.c:1646 */ break; - case 78: - -/* Line 1455 of yacc.c */ -#line 532 "xslpattern.y" + case 76: +#line 522 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got RelationalExpr: \"%s $lt$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U("<")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + TRACE("Got EqualityExpr: \"%s $ine$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=xmlStrdup(U("OP_INEq(")); + (yyval)=xmlStrcat((yyval),(yyvsp[-2])); + xmlFree((yyvsp[-2])); + (yyval)=xmlStrcat((yyval),U(",")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + (yyval)=xmlStrcat((yyval),U(")")); + } +#line 1902 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 79: - -/* Line 1455 of yacc.c */ -#line 540 "xslpattern.y" +#line 537 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got RelationalExpr: \"%s $ilt$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=xmlStrdup(U("OP_ILt(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (3)])); - xmlFree((yyvsp[(1) - (3)])); - (yyval)=xmlStrcat((yyval),U(",")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - (yyval)=xmlStrcat((yyval),U(")")); - ;} + TRACE("Got RelationalExpr: \"%s $lt$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U("<")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1914 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 80: - -/* Line 1455 of yacc.c */ -#line 551 "xslpattern.y" +#line 545 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got RelationalExpr: \"%s $gt$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U(">")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + TRACE("Got RelationalExpr: \"%s $ilt$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=xmlStrdup(U("OP_ILt(")); + (yyval)=xmlStrcat((yyval),(yyvsp[-2])); + xmlFree((yyvsp[-2])); + (yyval)=xmlStrcat((yyval),U(",")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + (yyval)=xmlStrcat((yyval),U(")")); + } +#line 1929 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 81: - -/* Line 1455 of yacc.c */ -#line 559 "xslpattern.y" +#line 556 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got RelationalExpr: \"%s $igt$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=xmlStrdup(U("OP_IGt(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (3)])); - xmlFree((yyvsp[(1) - (3)])); - (yyval)=xmlStrcat((yyval),U(",")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - (yyval)=xmlStrcat((yyval),U(")")); - ;} + TRACE("Got RelationalExpr: \"%s $gt$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U(">")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1941 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 82: - -/* Line 1455 of yacc.c */ -#line 570 "xslpattern.y" +#line 564 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got RelationalExpr: \"%s $le$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U("<=")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + TRACE("Got RelationalExpr: \"%s $igt$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=xmlStrdup(U("OP_IGt(")); + (yyval)=xmlStrcat((yyval),(yyvsp[-2])); + xmlFree((yyvsp[-2])); + (yyval)=xmlStrcat((yyval),U(",")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + (yyval)=xmlStrcat((yyval),U(")")); + } +#line 1956 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 83: - -/* Line 1455 of yacc.c */ -#line 578 "xslpattern.y" +#line 575 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got RelationalExpr: \"%s $ile$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=xmlStrdup(U("OP_ILEq(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (3)])); - xmlFree((yyvsp[(1) - (3)])); - (yyval)=xmlStrcat((yyval),U(",")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - (yyval)=xmlStrcat((yyval),U(")")); - ;} + TRACE("Got RelationalExpr: \"%s $le$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U("<=")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1968 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 84: - -/* Line 1455 of yacc.c */ -#line 589 "xslpattern.y" +#line 583 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got RelationalExpr: \"%s $ge$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U(">=")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + TRACE("Got RelationalExpr: \"%s $ile$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=xmlStrdup(U("OP_ILEq(")); + (yyval)=xmlStrcat((yyval),(yyvsp[-2])); + xmlFree((yyvsp[-2])); + (yyval)=xmlStrcat((yyval),U(",")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + (yyval)=xmlStrcat((yyval),U(")")); + } +#line 1983 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 85: - -/* Line 1455 of yacc.c */ -#line 597 "xslpattern.y" +#line 594 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got RelationalExpr: \"%s $ige$ %s\"\n", (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); - (yyval)=xmlStrdup(U("OP_IGEq(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (3)])); - xmlFree((yyvsp[(1) - (3)])); - (yyval)=xmlStrcat((yyval),U(",")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - (yyval)=xmlStrcat((yyval),U(")")); - ;} + TRACE("Got RelationalExpr: \"%s $ge$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U(">=")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 1995 "xslpattern.tab.c" /* yacc.c:1646 */ break; - case 88: - -/* Line 1455 of yacc.c */ -#line 614 "xslpattern.y" + case 86: +#line 602 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got UnaryExpr: \"$not$ %s\"\n", (yyvsp[(2) - (2)])); - (yyval)=xmlStrdup(U(" not(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(2) - (2)])); - xmlFree((yyvsp[(2) - (2)])); + TRACE("Got RelationalExpr: \"%s $ige$ %s\"\n", (yyvsp[-2]), (yyvsp[0])); + (yyval)=xmlStrdup(U("OP_IGEq(")); + (yyval)=xmlStrcat((yyval),(yyvsp[-2])); + xmlFree((yyvsp[-2])); + (yyval)=xmlStrcat((yyval),U(",")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); (yyval)=xmlStrcat((yyval),U(")")); - ;} + } +#line 2010 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 89: - -/* Line 1455 of yacc.c */ -#line 622 "xslpattern.y" +#line 619 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got UnaryExpr: \"$any$ %s\"\n", (yyvsp[(2) - (2)])); - (yyval)=xmlStrdup(U("boolean(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(2) - (2)])); - xmlFree((yyvsp[(2) - (2)])); + TRACE("Got UnaryExpr: \"$not$ %s\"\n", (yyvsp[0])); + (yyval)=xmlStrdup(U(" not(")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); (yyval)=xmlStrcat((yyval),U(")")); - ;} + } +#line 2022 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 90: - -/* Line 1455 of yacc.c */ -#line 630 "xslpattern.y" +#line 627 "xslpattern.y" /* yacc.c:1646 */ { - TRACE("Got UnaryExpr: \"$all$ %s\"\n", (yyvsp[(2) - (2)])); - (yyval)=xmlStrdup(U("not(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(2) - (2)])); - xmlFree((yyvsp[(2) - (2)])); + TRACE("Got UnaryExpr: \"$any$ %s\"\n", (yyvsp[0])); + (yyval)=xmlStrdup(U("boolean(")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); (yyval)=xmlStrcat((yyval),U(")")); - ;} + } +#line 2034 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 91: - -/* Line 1455 of yacc.c */ -#line 638 "xslpattern.y" +#line 635 "xslpattern.y" /* yacc.c:1646 */ { - FIXME("Unrecognized $all$ expression - ignoring\n"); - (yyval)=xmlStrdup(U("")); - ;} + TRACE("Got UnaryExpr: \"$all$ %s\"\n", (yyvsp[0])); + (yyval)=xmlStrdup(U("not(")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + (yyval)=xmlStrcat((yyval),U(")")); + } +#line 2046 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 92: - -/* Line 1455 of yacc.c */ -#line 644 "xslpattern.y" +#line 643 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U("!=")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + FIXME("Unrecognized $all$ expression - ignoring\n"); + (yyval)=xmlStrdup(U("")); + } +#line 2055 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 93: - -/* Line 1455 of yacc.c */ -#line 651 "xslpattern.y" +#line 649 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U("=")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U("!=")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 2066 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 94: - -/* Line 1455 of yacc.c */ -#line 658 "xslpattern.y" +#line 656 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U(">=")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U("=")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 2077 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 95: - -/* Line 1455 of yacc.c */ -#line 665 "xslpattern.y" +#line 663 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U(">")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U(">=")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 2088 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 96: - -/* Line 1455 of yacc.c */ -#line 672 "xslpattern.y" +#line 670 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U("<=")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U(">")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 2099 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 97: - -/* Line 1455 of yacc.c */ -#line 679 "xslpattern.y" +#line 677 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=(yyvsp[(1) - (3)]); - (yyval)=xmlStrcat((yyval),U("<")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - ;} + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U("<=")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 2110 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 98: - -/* Line 1455 of yacc.c */ -#line 686 "xslpattern.y" +#line 684 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=xmlStrdup(U("OP_INEq(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (3)])); - xmlFree((yyvsp[(1) - (3)])); - (yyval)=xmlStrcat((yyval),U(",")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); - (yyval)=xmlStrcat((yyval),U(")")); - ;} + (yyval)=(yyvsp[-2]); + (yyval)=xmlStrcat((yyval),U("<")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + } +#line 2121 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 99: - -/* Line 1455 of yacc.c */ -#line 696 "xslpattern.y" +#line 691 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=xmlStrdup(U("OP_IEq(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (3)])); - xmlFree((yyvsp[(1) - (3)])); + (yyval)=xmlStrdup(U("OP_INEq(")); + (yyval)=xmlStrcat((yyval),(yyvsp[-2])); + xmlFree((yyvsp[-2])); (yyval)=xmlStrcat((yyval),U(",")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); (yyval)=xmlStrcat((yyval),U(")")); - ;} + } +#line 2135 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 100: - -/* Line 1455 of yacc.c */ -#line 706 "xslpattern.y" +#line 701 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=xmlStrdup(U("OP_IGEq(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (3)])); - xmlFree((yyvsp[(1) - (3)])); + (yyval)=xmlStrdup(U("OP_IEq(")); + (yyval)=xmlStrcat((yyval),(yyvsp[-2])); + xmlFree((yyvsp[-2])); (yyval)=xmlStrcat((yyval),U(",")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); (yyval)=xmlStrcat((yyval),U(")")); - ;} + } +#line 2149 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 101: - -/* Line 1455 of yacc.c */ -#line 716 "xslpattern.y" +#line 711 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=xmlStrdup(U("OP_IGt(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (3)])); - xmlFree((yyvsp[(1) - (3)])); + (yyval)=xmlStrdup(U("OP_IGEq(")); + (yyval)=xmlStrcat((yyval),(yyvsp[-2])); + xmlFree((yyvsp[-2])); (yyval)=xmlStrcat((yyval),U(",")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); (yyval)=xmlStrcat((yyval),U(")")); - ;} + } +#line 2163 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 102: - -/* Line 1455 of yacc.c */ -#line 726 "xslpattern.y" +#line 721 "xslpattern.y" /* yacc.c:1646 */ { - (yyval)=xmlStrdup(U("OP_ILEq(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (3)])); - xmlFree((yyvsp[(1) - (3)])); + (yyval)=xmlStrdup(U("OP_IGt(")); + (yyval)=xmlStrcat((yyval),(yyvsp[-2])); + xmlFree((yyvsp[-2])); (yyval)=xmlStrcat((yyval),U(",")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); (yyval)=xmlStrcat((yyval),U(")")); - ;} + } +#line 2177 "xslpattern.tab.c" /* yacc.c:1646 */ break; case 103: +#line 731 "xslpattern.y" /* yacc.c:1646 */ + { + (yyval)=xmlStrdup(U("OP_ILEq(")); + (yyval)=xmlStrcat((yyval),(yyvsp[-2])); + xmlFree((yyvsp[-2])); + (yyval)=xmlStrcat((yyval),U(",")); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); + (yyval)=xmlStrcat((yyval),U(")")); + } +#line 2191 "xslpattern.tab.c" /* yacc.c:1646 */ + break; -/* Line 1455 of yacc.c */ -#line 736 "xslpattern.y" + case 104: +#line 741 "xslpattern.y" /* yacc.c:1646 */ { (yyval)=xmlStrdup(U("OP_ILt(")); - (yyval)=xmlStrcat((yyval),(yyvsp[(1) - (3)])); - xmlFree((yyvsp[(1) - (3)])); + (yyval)=xmlStrcat((yyval),(yyvsp[-2])); + xmlFree((yyvsp[-2])); (yyval)=xmlStrcat((yyval),U(",")); - (yyval)=xmlStrcat((yyval),(yyvsp[(3) - (3)])); - xmlFree((yyvsp[(3) - (3)])); + (yyval)=xmlStrcat((yyval),(yyvsp[0])); + xmlFree((yyvsp[0])); (yyval)=xmlStrcat((yyval),U(")")); - ;} + } +#line 2205 "xslpattern.tab.c" /* yacc.c:1646 */ break; - -/* Line 1455 of yacc.c */ -#line 2423 "xslpattern.tab.c" +#line 2209 "xslpattern.tab.c" /* yacc.c:1646 */ default: break; } + /* User semantic actions sometimes alter yychar, and that requires + that yytoken be updated with the new translation. We take the + approach of translating immediately before every use of yytoken. + One alternative is translating here after every semantic action, + but that translation would be missed if the semantic action invokes + YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or + if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an + incorrect destructor might then be invoked immediately. In the + case of YYERROR or YYBACKUP, subsequent parser actions might lead + to an incorrect destructor call or verbose syntax error message + before the lookahead is translated. */ YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); YYPOPSTACK (yylen); @@ -2427,7 +2224,7 @@ yyreduce: *++yyvsp = yyval; - /* Now `shift' the result of the reduction. Determine what state + /* Now 'shift' the result of the reduction. Determine what state that goes to, based on the state we popped back to and the rule number reduced by. */ @@ -2442,10 +2239,14 @@ yyreduce: goto yynewstate; -/*------------------------------------. -| yyerrlab -- here on detecting error | -`------------------------------------*/ +/*--------------------------------------. +| yyerrlab -- here on detecting error. | +`--------------------------------------*/ yyerrlab: + /* Make sure we have latest lookahead translation. See comments at + user semantic actions for why this is necessary. */ + yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar); + /* If not already recovering from an error, report this error. */ if (!yyerrstatus) { @@ -2453,37 +2254,36 @@ yyerrlab: #if ! YYERROR_VERBOSE yyerror (p, scanner, YY_("syntax error")); #else +# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \ + yyssp, yytoken) { - YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); - if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) - { - YYSIZE_T yyalloc = 2 * yysize; - if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) - yyalloc = YYSTACK_ALLOC_MAXIMUM; - if (yymsg != yymsgbuf) - YYSTACK_FREE (yymsg); - yymsg = (char *) YYSTACK_ALLOC (yyalloc); - if (yymsg) - yymsg_alloc = yyalloc; - else - { - yymsg = yymsgbuf; - yymsg_alloc = sizeof yymsgbuf; - } - } - - if (0 < yysize && yysize <= yymsg_alloc) - { - (void) yysyntax_error (yymsg, yystate, yychar); - yyerror (p, scanner, yymsg); - } - else - { - yyerror (p, scanner, YY_("syntax error")); - if (yysize != 0) - goto yyexhaustedlab; - } + char const *yymsgp = YY_("syntax error"); + int yysyntax_error_status; + yysyntax_error_status = YYSYNTAX_ERROR; + if (yysyntax_error_status == 0) + yymsgp = yymsg; + else if (yysyntax_error_status == 1) + { + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc); + if (!yymsg) + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + yysyntax_error_status = 2; + } + else + { + yysyntax_error_status = YYSYNTAX_ERROR; + yymsgp = yymsg; + } + } + yyerror (p, scanner, yymsgp); + if (yysyntax_error_status == 2) + goto yyexhaustedlab; } +# undef YYSYNTAX_ERROR #endif } @@ -2492,20 +2292,20 @@ yyerrlab: if (yyerrstatus == 3) { /* If just tried and failed to reuse lookahead token after an - error, discard it. */ + error, discard it. */ if (yychar <= YYEOF) - { - /* Return failure if at end of input. */ - if (yychar == YYEOF) - YYABORT; - } + { + /* Return failure if at end of input. */ + if (yychar == YYEOF) + YYABORT; + } else - { - yydestruct ("Error: discarding", - yytoken, &yylval, p, scanner); - yychar = YYEMPTY; - } + { + yydestruct ("Error: discarding", + yytoken, &yylval, p, scanner); + yychar = YYEMPTY; + } } /* Else will try to reuse lookahead token after shifting the error @@ -2524,7 +2324,7 @@ yyerrorlab: if (/*CONSTCOND*/ 0) goto yyerrorlab; - /* Do not reclaim the symbols of the rule which action triggered + /* Do not reclaim the symbols of the rule whose action triggered this YYERROR. */ YYPOPSTACK (yylen); yylen = 0; @@ -2537,35 +2337,37 @@ yyerrorlab: | yyerrlab1 -- common code for both syntax error and YYERROR. | `-------------------------------------------------------------*/ yyerrlab1: - yyerrstatus = 3; /* Each real token shifted decrements this. */ + yyerrstatus = 3; /* Each real token shifted decrements this. */ for (;;) { yyn = yypact[yystate]; - if (yyn != YYPACT_NINF) - { - yyn += YYTERROR; - if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) - { - yyn = yytable[yyn]; - if (0 < yyn) - break; - } - } + if (!yypact_value_is_default (yyn)) + { + yyn += YYTERROR; + if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) + { + yyn = yytable[yyn]; + if (0 < yyn) + break; + } + } /* Pop the current state because it cannot handle the error token. */ if (yyssp == yyss) - YYABORT; + YYABORT; yydestruct ("Error: popping", - yystos[yystate], yyvsp, p, scanner); + yystos[yystate], yyvsp, p, scanner); YYPOPSTACK (1); yystate = *yyssp; YY_STACK_PRINT (yyss, yyssp); } + YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN *++yyvsp = yylval; + YY_IGNORE_MAYBE_UNINITIALIZED_END /* Shift the error token. */ @@ -2589,7 +2391,7 @@ yyabortlab: yyresult = 1; goto yyreturn; -#if !defined(yyoverflow) || YYERROR_VERBOSE +#if !defined yyoverflow || YYERROR_VERBOSE /*-------------------------------------------------. | yyexhaustedlab -- memory exhaustion comes here. | `-------------------------------------------------*/ @@ -2601,16 +2403,21 @@ yyexhaustedlab: yyreturn: if (yychar != YYEMPTY) - yydestruct ("Cleanup: discarding lookahead", - yytoken, &yylval, p, scanner); - /* Do not reclaim the symbols of the rule which action triggered + { + /* Make sure we have latest lookahead translation. See comments at + user semantic actions for why this is necessary. */ + yytoken = YYTRANSLATE (yychar); + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval, p, scanner); + } + /* Do not reclaim the symbols of the rule whose action triggered this YYABORT or YYACCEPT. */ YYPOPSTACK (yylen); YY_STACK_PRINT (yyss, yyssp); while (yyssp != yyss) { yydestruct ("Cleanup: popping", - yystos[*yyssp], yyvsp, p, scanner); + yystos[*yyssp], yyvsp, p, scanner); YYPOPSTACK (1); } #ifndef yyoverflow @@ -2621,15 +2428,9 @@ yyreturn: if (yymsg != yymsgbuf) YYSTACK_FREE (yymsg); #endif - /* Make sure YYID is used. */ - return YYID (yyresult); + return yyresult; } - - - -/* Line 1675 of yacc.c */ -#line 747 "xslpattern.y" +#line 752 "xslpattern.y" /* yacc.c:1906 */ #endif /* HAVE_LIBXML2 */ - diff --git a/dll/win32/msxml3/xslpattern.tab.h b/dll/win32/msxml3/xslpattern.tab.h index b09c0d57292..a9e30f34fb2 100644 --- a/dll/win32/msxml3/xslpattern.tab.h +++ b/dll/win32/msxml3/xslpattern.tab.h @@ -1,21 +1,19 @@ +/* A Bison parser, made by GNU Bison 3.0.2. */ -/* A Bison parser, made by GNU Bison 2.4.1. */ +/* Bison interface for Yacc-like parsers in C + + Copyright (C) 1984, 1989-1990, 2000-2013 Free Software Foundation, Inc. -/* Skeleton interface for Bison's Yacc-like parsers in C - - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 - Free Software Foundation, Inc. - This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. - + This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. - + You should have received a copy of the GNU General Public License along with this program. If not, see . */ @@ -28,55 +26,63 @@ special exception, which will cause the skeleton and the resulting Bison output files to be licensed under the GNU General Public License without this special exception. - + This special exception was added by the Free Software Foundation in version 2.2 of Bison. */ - -/* Tokens. */ -#ifndef YYTOKENTYPE -# define YYTOKENTYPE - /* Put the tokens into the symbol table, so that GDB and other debuggers - know about them. */ - enum yytokentype { - TOK_Parent = 258, - TOK_Self = 259, - TOK_DblFSlash = 260, - TOK_FSlash = 261, - TOK_Axis = 262, - TOK_Colon = 263, - TOK_OpAnd = 264, - TOK_OpOr = 265, - TOK_OpNot = 266, - TOK_OpEq = 267, - TOK_OpIEq = 268, - TOK_OpNEq = 269, - TOK_OpINEq = 270, - TOK_OpLt = 271, - TOK_OpILt = 272, - TOK_OpGt = 273, - TOK_OpIGt = 274, - TOK_OpLEq = 275, - TOK_OpILEq = 276, - TOK_OpGEq = 277, - TOK_OpIGEq = 278, - TOK_OpAll = 279, - TOK_OpAny = 280, - TOK_NCName = 281, - TOK_Literal = 282, - TOK_Number = 283 - }; +#ifndef YY_XSLPATTERN_XSLPATTERN_TAB_H_INCLUDED +# define YY_XSLPATTERN_XSLPATTERN_TAB_H_INCLUDED +/* Debug traces. */ +#ifndef YYDEBUG +# define YYDEBUG 0 +#endif +#if YYDEBUG +extern int xslpattern_debug; #endif +/* Token type. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + enum yytokentype + { + TOK_Parent = 258, + TOK_Self = 259, + TOK_DblFSlash = 260, + TOK_FSlash = 261, + TOK_Axis = 262, + TOK_Colon = 263, + TOK_OpAnd = 264, + TOK_OpOr = 265, + TOK_OpNot = 266, + TOK_OpEq = 267, + TOK_OpIEq = 268, + TOK_OpNEq = 269, + TOK_OpINEq = 270, + TOK_OpLt = 271, + TOK_OpILt = 272, + TOK_OpGt = 273, + TOK_OpIGt = 274, + TOK_OpLEq = 275, + TOK_OpILEq = 276, + TOK_OpGEq = 277, + TOK_OpIGEq = 278, + TOK_OpAll = 279, + TOK_OpAny = 280, + TOK_NCName = 281, + TOK_Literal = 282, + TOK_Number = 283 + }; +#endif - +/* Value type. */ #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED typedef int YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 -# define yystype YYSTYPE /* obsolescent; will be withdrawn */ # define YYSTYPE_IS_DECLARED 1 #endif +int xslpattern_parse (parser_param* p, void* scanner); +#endif /* !YY_XSLPATTERN_XSLPATTERN_TAB_H_INCLUDED */ diff --git a/dll/win32/msxml3/xslpattern.y b/dll/win32/msxml3/xslpattern.y index 4e3b699e550..9adb3186ae6 100644 --- a/dll/win32/msxml3/xslpattern.y +++ b/dll/win32/msxml3/xslpattern.y @@ -186,6 +186,11 @@ static void xslpattern_error(parser_param* param, void const* scanner, char cons $$=xmlStrcat($$,$2); xmlFree($2); } + | '@' '*' + { + TRACE("Got All attributes pattern: \"@*\"\n"); + $$=xmlStrdup(U("@*")); + } ; /* [2.3] Node Tests */ diff --git a/dll/win32/msxml4/Makefile.in b/dll/win32/msxml4/Makefile.in deleted file mode 100644 index c4115b2a181..00000000000 --- a/dll/win32/msxml4/Makefile.in +++ /dev/null @@ -1,12 +0,0 @@ -EXTRADEFS = -DCOM_NO_WINDOWS_H -MODULE = msxml4.dll -IMPORTS = ole32 advapi32 - -C_SRCS = \ - main.c - -IDL_TLB_SRCS = msxml4_tlb.idl - -RC_SRCS = rsrc.rc - -@MAKE_DLL_RULES@ diff --git a/dll/win32/msxml6/Makefile.in b/dll/win32/msxml6/Makefile.in deleted file mode 100644 index 4a7f756ce68..00000000000 --- a/dll/win32/msxml6/Makefile.in +++ /dev/null @@ -1,12 +0,0 @@ -EXTRADEFS = -DCOM_NO_WINDOWS_H -MODULE = msxml6.dll -IMPORTS = oleaut32 ole32 advapi32 - -C_SRCS = \ - main.c - -RC_SRCS = rsrc.rc - -IDL_TLB_SRCS = msxml6_tlb.idl - -@MAKE_DLL_RULES@ diff --git a/dll/win32/ole32/compobj.c b/dll/win32/ole32/compobj.c index 070e55e6180..276143a2a48 100644 --- a/dll/win32/ole32/compobj.c +++ b/dll/win32/ole32/compobj.c @@ -314,7 +314,7 @@ static const WCHAR classes_rootW[] = static HKEY classes_root_hkey; /* create the special HKEY_CLASSES_ROOT key */ -static HKEY create_classes_root_hkey(void) +static HKEY create_classes_root_hkey(DWORD access) { HKEY hkey, ret = 0; OBJECT_ATTRIBUTES attr; @@ -327,23 +327,39 @@ static HKEY create_classes_root_hkey(void) attr.SecurityDescriptor = NULL; attr.SecurityQualityOfService = NULL; RtlInitUnicodeString( &name, classes_rootW ); - if (create_key( &hkey, MAXIMUM_ALLOWED, &attr )) return 0; + if (create_key( &hkey, access, &attr )) return 0; TRACE( "%s -> %p\n", debugstr_w(attr.ObjectName->Buffer), hkey ); - if (!(ret = InterlockedCompareExchangePointer( (void **)&classes_root_hkey, hkey, 0 ))) - ret = hkey; + if (!(access & KEY_WOW64_64KEY)) + { + if (!(ret = InterlockedCompareExchangePointer( (void **)&classes_root_hkey, hkey, 0 ))) + ret = hkey; + else + NtClose( hkey ); /* somebody beat us to it */ + } else - NtClose( hkey ); /* somebody beat us to it */ + ret = hkey; return ret; } /* map the hkey from special root to normal key if necessary */ -static inline HKEY get_classes_root_hkey( HKEY hkey ) +static inline HKEY get_classes_root_hkey( HKEY hkey, REGSAM access ) { HKEY ret = hkey; + const BOOL is_win64 = sizeof(void*) > sizeof(int); + const BOOL force_wow32 = is_win64 && (access & KEY_WOW64_32KEY); - if (hkey == HKEY_CLASSES_ROOT && !(ret = classes_root_hkey)) - ret = create_classes_root_hkey(); + if (hkey == HKEY_CLASSES_ROOT && + ((access & KEY_WOW64_64KEY) || !(ret = classes_root_hkey))) + ret = create_classes_root_hkey(MAXIMUM_ALLOWED | (access & KEY_WOW64_64KEY)); + if (force_wow32 && ret && ret == classes_root_hkey) + { + static const WCHAR wow6432nodeW[] = {'W','o','w','6','4','3','2','N','o','d','e',0}; + access &= ~KEY_WOW64_32KEY; + if (create_classes_key(classes_root_hkey, wow6432nodeW, access, &hkey)) + return 0; + ret = hkey; + } return ret; } @@ -353,7 +369,7 @@ LSTATUS create_classes_key( HKEY hkey, const WCHAR *name, REGSAM access, HKEY *r OBJECT_ATTRIBUTES attr; UNICODE_STRING nameW; - if (!(hkey = get_classes_root_hkey( hkey ))) return ERROR_INVALID_HANDLE; + if (!(hkey = get_classes_root_hkey( hkey, access ))) return ERROR_INVALID_HANDLE; attr.Length = sizeof(attr); attr.RootDirectory = hkey; @@ -371,7 +387,7 @@ LSTATUS open_classes_key( HKEY hkey, const WCHAR *name, REGSAM access, HKEY *ret OBJECT_ATTRIBUTES attr; UNICODE_STRING nameW; - if (!(hkey = get_classes_root_hkey( hkey ))) return ERROR_INVALID_HANDLE; + if (!(hkey = get_classes_root_hkey( hkey, access ))) return ERROR_INVALID_HANDLE; attr.Length = sizeof(attr); attr.RootDirectory = hkey; @@ -1174,7 +1190,7 @@ DWORD apartment_release(struct apartment *apt) return ret; } -/* The given OXID must be local to this process: +/* The given OXID must be local to this process: * * The ref parameter is here mostly to ensure people remember that * they get one, you should normally take a ref for thread safety. @@ -1639,14 +1655,27 @@ static BOOL WINAPI register_class( INIT_ONCE *once, void *param, void **context * already been created */ HRESULT apartment_createwindowifneeded(struct apartment *apt) { +#ifndef __REACTOS__ + static INIT_ONCE class_init_once = INIT_ONCE_STATIC_INIT; +#endif + if (apt->multi_threaded) return S_OK; if (!apt->win) { +#ifndef __REACTOS__ + HWND hwnd; + + InitOnceExecuteOnce( &class_init_once, register_class, NULL, NULL ); + + hwnd = CreateWindowW(wszAptWinClass, NULL, 0, 0, 0, 0, 0, + HWND_MESSAGE, 0, hProxyDll, NULL); +#else HWND hwnd = CreateWindowW(wszAptWinClass, NULL, 0, 0, 0, 0, 0, HWND_MESSAGE, 0, hProxyDll, NULL); +#endif if (!hwnd) { ERR("CreateWindow failed with error %d\n", GetLastError()); @@ -2054,7 +2083,11 @@ HRESULT WINAPI CoDisconnectObject( LPUNKNOWN lpUnk, DWORD reserved ) */ HRESULT WINAPI CoCreateGuid(GUID *pguid) { - DWORD status = UuidCreate(pguid); + DWORD status; + + if(!pguid) return E_INVALIDARG; + + status = UuidCreate(pguid); if (status == RPC_S_OK || status == RPC_S_UUID_LOCAL_ONLY) return S_OK; return HRESULT_FROM_WIN32( status ); } @@ -2474,6 +2507,28 @@ HRESULT WINAPI CLSIDFromProgIDEx(LPCOLESTR progid, LPCLSID clsid) return CLSIDFromProgID(progid, clsid); } +static HRESULT get_ps_clsid_from_registry(const WCHAR* path, REGSAM access, CLSID *pclsid) +{ + HKEY hkey; + WCHAR value[CHARS_IN_GUID]; + DWORD len; + + access |= KEY_READ; + + if (open_classes_key(HKEY_CLASSES_ROOT, path, access, &hkey)) + return REGDB_E_IIDNOTREG; + + len = sizeof(value); + if (ERROR_SUCCESS != RegQueryValueExW(hkey, NULL, NULL, NULL, (BYTE *)value, &len)) + return REGDB_E_IIDNOTREG; + RegCloseKey(hkey); + + if (CLSIDFromString(value, pclsid) != NOERROR) + return REGDB_E_IIDNOTREG; + + return S_OK; +} + /***************************************************************************** * CoGetPSClsid [OLE32.@] * @@ -2483,7 +2538,7 @@ HRESULT WINAPI CLSIDFromProgIDEx(LPCOLESTR progid, LPCLSID clsid) * PARAMS * riid [I] Interface whose proxy/stub CLSID is to be returned. * pclsid [O] Where to store returned proxy/stub CLSID. - * + * * RETURNS * S_OK * E_OUTOFMEMORY @@ -2515,12 +2570,12 @@ HRESULT WINAPI CoGetPSClsid(REFIID riid, CLSID *pclsid) static const WCHAR wszInterface[] = {'I','n','t','e','r','f','a','c','e','\\',0}; static const WCHAR wszPSC[] = {'\\','P','r','o','x','y','S','t','u','b','C','l','s','i','d','3','2',0}; WCHAR path[ARRAYSIZE(wszInterface) - 1 + CHARS_IN_GUID - 1 + ARRAYSIZE(wszPSC)]; - WCHAR value[CHARS_IN_GUID]; - LONG len; - HKEY hkey; APARTMENT *apt = COM_CurrentApt(); struct registered_psclsid *registered_psclsid; ACTCTX_SECTION_KEYED_DATA data; + HRESULT hr; + REGSAM opposite = (sizeof(void*) > sizeof(int)) ? KEY_WOW64_32KEY : KEY_WOW64_64KEY; + BOOL is_wow64; TRACE("() riid=%s, pclsid=%p\n", debugstr_guid(riid), pclsid); @@ -2559,31 +2614,17 @@ HRESULT WINAPI CoGetPSClsid(REFIID riid, CLSID *pclsid) StringFromGUID2(riid, path + ARRAYSIZE(wszInterface) - 1, CHARS_IN_GUID); strcpyW(path + ARRAYSIZE(wszInterface) - 1 + CHARS_IN_GUID - 1, wszPSC); - /* Open the key.. */ - if (open_classes_key(HKEY_CLASSES_ROOT, path, KEY_READ, &hkey)) - { + hr = get_ps_clsid_from_registry(path, 0, pclsid); + if (FAILED(hr) && (opposite == KEY_WOW64_32KEY || + (IsWow64Process(GetCurrentProcess(), &is_wow64) && is_wow64))) + hr = get_ps_clsid_from_registry(path, opposite, pclsid); + + if (hr == S_OK) + TRACE ("() Returning CLSID=%s\n", debugstr_guid(pclsid)); + else WARN("No PSFactoryBuffer object is registered for IID %s\n", debugstr_guid(riid)); - return REGDB_E_IIDNOTREG; - } - /* ... Once we have the key, query the registry to get the - value of CLSID as a string, and convert it into a - proper CLSID structure to be passed back to the app */ - len = sizeof(value); - if (ERROR_SUCCESS != RegQueryValueW(hkey, NULL, value, &len)) - { - RegCloseKey(hkey); - return REGDB_E_IIDNOTREG; - } - RegCloseKey(hkey); - - /* We have the CLSID we want back from the registry as a string, so - let's convert it into a CLSID structure */ - if (CLSIDFromString(value, pclsid) != NOERROR) - return REGDB_E_IIDNOTREG; - - TRACE ("() Returning CLSID=%s\n", debugstr_guid(pclsid)); - return S_OK; + return hr; } /***************************************************************************** @@ -2595,7 +2636,7 @@ HRESULT WINAPI CoGetPSClsid(REFIID riid, CLSID *pclsid) * PARAMS * riid [I] Interface whose proxy/stub CLSID is to be registered. * rclsid [I] CLSID of the proxy/stub. - * + * * RETURNS * Success: S_OK * Failure: E_OUTOFMEMORY @@ -3159,6 +3200,7 @@ HRESULT WINAPI DECLSPEC_HOTPATCH CoCreateInstance( HRESULT hres; LPCLASSFACTORY lpclf = 0; APARTMENT *apt; + CLSID clsid; TRACE("(rclsid=%s, pUnkOuter=%p, dwClsContext=%08x, riid=%s, ppv=%p)\n", debugstr_guid(rclsid), pUnkOuter, dwClsContext, debugstr_guid(iid), ppv); @@ -3166,6 +3208,10 @@ HRESULT WINAPI DECLSPEC_HOTPATCH CoCreateInstance( if (ppv==0) return E_POINTER; + hres = CoGetTreatAsClass(rclsid, &clsid); + if(FAILED(hres)) + clsid = *rclsid; + *ppv = 0; if (!(apt = COM_CurrentApt())) @@ -3181,7 +3227,7 @@ HRESULT WINAPI DECLSPEC_HOTPATCH CoCreateInstance( /* * The Standard Global Interface Table (GIT) object is a process-wide singleton. */ - if (IsEqualIID(rclsid, &CLSID_StdGlobalInterfaceTable)) + if (IsEqualIID(&clsid, &CLSID_StdGlobalInterfaceTable)) { IGlobalInterfaceTable *git = get_std_git(); hres = IGlobalInterfaceTable_QueryInterface(git, iid, ppv); @@ -3191,13 +3237,13 @@ HRESULT WINAPI DECLSPEC_HOTPATCH CoCreateInstance( return S_OK; } - if (IsEqualCLSID(rclsid, &CLSID_ManualResetEvent)) + if (IsEqualCLSID(&clsid, &CLSID_ManualResetEvent)) return ManualResetEvent_Construct(pUnkOuter, iid, ppv); /* * Get a class factory to construct the object we want. */ - hres = CoGetClassObject(rclsid, + hres = CoGetClassObject(&clsid, dwClsContext, NULL, &IID_IClassFactory, @@ -3214,11 +3260,11 @@ HRESULT WINAPI DECLSPEC_HOTPATCH CoCreateInstance( if (FAILED(hres)) { if (hres == CLASS_E_NOAGGREGATION && pUnkOuter) - FIXME("Class %s does not support aggregation\n", debugstr_guid(rclsid)); + FIXME("Class %s does not support aggregation\n", debugstr_guid(&clsid)); else FIXME("no instance created for interface %s of class %s, hres is 0x%08x\n", debugstr_guid(iid), - debugstr_guid(rclsid),hres); + debugstr_guid(&clsid),hres); } return hres; @@ -3321,7 +3367,7 @@ HRESULT WINAPI CoGetInstanceFromFile( init_multi_qi(count, results); - /* optionaly get CLSID from a file */ + /* optionally get CLSID from a file */ if (!rclsid) { hr = GetClassFile(filename, &clsid); @@ -3383,7 +3429,7 @@ HRESULT WINAPI CoGetInstanceFromIStorage( init_multi_qi(count, results); - /* optionaly get CLSID from a file */ + /* optionally get CLSID from a file */ if (!rclsid) { memset(&stat.clsid, 0, sizeof(stat.clsid)); @@ -3577,14 +3623,14 @@ HRESULT WINAPI CoLockObjectExternal( if (!apt) return CO_E_NOTINITIALIZED; stubmgr = get_stub_manager_from_object(apt, pUnk); - + if (stubmgr) { if (fLock) stub_manager_ext_addref(stubmgr, 1, FALSE); else stub_manager_ext_release(stubmgr, 1, FALSE, fLastUnlockReleases); - + stub_manager_int_release(stubmgr); return S_OK; @@ -3730,7 +3776,8 @@ HRESULT WINAPI CoTreatAsClass(REFCLSID clsidOld, REFCLSID clsidNew) res = COM_OpenKeyForCLSID(clsidOld, NULL, KEY_READ | KEY_WRITE, &hkey); if (FAILED(res)) goto done; - if (!memcmp( clsidOld, clsidNew, sizeof(*clsidOld) )) + + if (IsEqualGUID( clsidOld, clsidNew )) { if (!RegQueryValueW(hkey, wszAutoTreatAs, auto_treat_as, &auto_treat_as_size) && CLSIDFromString(auto_treat_as, &id) == S_OK) @@ -3743,15 +3790,28 @@ HRESULT WINAPI CoTreatAsClass(REFCLSID clsidOld, REFCLSID clsidNew) } else { - RegDeleteKeyW(hkey, wszTreatAs); + if(RegDeleteKeyW(hkey, wszTreatAs)) + res = REGDB_E_WRITEREGDB; goto done; } } - else if (!StringFromGUID2(clsidNew, szClsidNew, ARRAYSIZE(szClsidNew)) && - !RegSetValueW(hkey, wszTreatAs, REG_SZ, szClsidNew, sizeof(szClsidNew))) + else { - res = REGDB_E_WRITEREGDB; - goto done; + if(IsEqualGUID(clsidNew, &CLSID_NULL)){ + RegDeleteKeyW(hkey, wszTreatAs); + }else{ + if(!StringFromGUID2(clsidNew, szClsidNew, ARRAYSIZE(szClsidNew))){ + WARN("StringFromGUID2 failed\n"); + res = E_FAIL; + goto done; + } + + if(RegSetValueW(hkey, wszTreatAs, REG_SZ, szClsidNew, sizeof(szClsidNew)) != ERROR_SUCCESS){ + WARN("RegSetValue failed\n"); + res = REGDB_E_WRITEREGDB; + goto done; + } + } } done: @@ -4037,7 +4097,7 @@ HRESULT WINAPI CoAllowSetForegroundWindow(IUnknown *pUnk, void *pvReserved) FIXME("(%p, %p): stub\n", pUnk, pvReserved); return S_OK; } - + /*********************************************************************** * CoQueryProxyBlanket [OLE32.@] * @@ -4987,13 +5047,19 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID reserved) switch(fdwReason) { case DLL_PROCESS_ATTACH: hProxyDll = hinstDLL; +#ifdef __REACTOS__ COMPOBJ_InitProcess(); +#endif break; case DLL_PROCESS_DETACH: if (reserved) break; release_std_git(); +#ifdef __REACTOS__ COMPOBJ_UninitProcess(); +#else + UnregisterClassW( wszAptWinClass, hProxyDll ); +#endif RPC_UnregisterAllChannelHooks(); COMPOBJ_DllList_Free(); DeleteCriticalSection(&csRegisteredClassList); diff --git a/dll/win32/ole32/filelockbytes.c b/dll/win32/ole32/filelockbytes.c index e151e55e652..d45cc3fccf8 100644 --- a/dll/win32/ole32/filelockbytes.c +++ b/dll/win32/ole32/filelockbytes.c @@ -29,7 +29,6 @@ typedef struct FileLockBytesImpl { ILockBytes ILockBytes_iface; LONG ref; - ULARGE_INTEGER filesize; HANDLE hfile; DWORD flProtect; LPWSTR pwcsName; @@ -88,8 +87,6 @@ HRESULT FileLockBytesImpl_Construct(HANDLE hFile, DWORD openFlags, LPCWSTR pwcsN This->ILockBytes_iface.lpVtbl = &FileLockBytesImpl_Vtbl; This->ref = 1; This->hfile = hFile; - This->filesize.u.LowPart = GetFileSize(This->hfile, - &This->filesize.u.HighPart); This->flProtect = GetProtectMode(openFlags); if(pwcsName) { @@ -109,8 +106,6 @@ HRESULT FileLockBytesImpl_Construct(HANDLE hFile, DWORD openFlags, LPCWSTR pwcsN else This->pwcsName = NULL; - TRACE("file len %u\n", This->filesize.u.LowPart); - *pLockBytes = &This->ILockBytes_iface; return S_OK; @@ -228,7 +223,6 @@ static HRESULT WINAPI FileLockBytesImpl_WriteAt( ULONG* pcbWritten) /* [out] */ { FileLockBytesImpl* This = impl_from_ILockBytes(iface); - ULONG size_needed = ulOffset.u.LowPart + cb; ULONG bytes_left = cb; const BYTE *writePtr = pv; BOOL ret; @@ -246,27 +240,19 @@ static HRESULT WINAPI FileLockBytesImpl_WriteAt( if (pcbWritten) *pcbWritten = 0; - if (size_needed > This->filesize.u.LowPart) - { - ULARGE_INTEGER newSize; - newSize.u.HighPart = 0; - newSize.u.LowPart = size_needed; - ILockBytes_SetSize(iface, newSize); - } - offset.QuadPart = ulOffset.QuadPart; ret = SetFilePointerEx(This->hfile, offset, NULL, FILE_BEGIN); if (!ret) - return STG_E_READFAULT; + return STG_E_WRITEFAULT; while (bytes_left) { ret = WriteFile(This->hfile, writePtr, bytes_left, &cbWritten, NULL); if (!ret) - return STG_E_READFAULT; + return STG_E_WRITEFAULT; if (pcbWritten) *pcbWritten += cbWritten; @@ -296,10 +282,7 @@ static HRESULT WINAPI FileLockBytesImpl_SetSize(ILockBytes* iface, ULARGE_INTEGE HRESULT hr = S_OK; LARGE_INTEGER newpos; - if (This->filesize.u.LowPart == newSize.u.LowPart) - return hr; - - TRACE("from %u to %u\n", This->filesize.u.LowPart, newSize.u.LowPart); + TRACE("new size %u\n", newSize.u.LowPart); newpos.QuadPart = newSize.QuadPart; if (SetFilePointerEx(This->hfile, newpos, NULL, FILE_BEGIN)) @@ -307,22 +290,82 @@ static HRESULT WINAPI FileLockBytesImpl_SetSize(ILockBytes* iface, ULARGE_INTEGE SetEndOfFile(This->hfile); } - This->filesize = newSize; return hr; } +static HRESULT get_lock_error(void) +{ + switch (GetLastError()) + { + case ERROR_LOCK_VIOLATION: return STG_E_LOCKVIOLATION; break; + case ERROR_ACCESS_DENIED: return STG_E_ACCESSDENIED; break; + case ERROR_NOT_SUPPORTED: return STG_E_INVALIDFUNCTION; break; + default: + FIXME("no mapping for error %d\n", GetLastError()); + return STG_E_INVALIDFUNCTION; + } +} + static HRESULT WINAPI FileLockBytesImpl_LockRegion(ILockBytes* iface, ULARGE_INTEGER libOffset, ULARGE_INTEGER cb, DWORD dwLockType) { - FIXME("stub\n"); - return E_NOTIMPL; + FileLockBytesImpl* This = impl_from_ILockBytes(iface); + OVERLAPPED ol; + DWORD lock_flags = LOCKFILE_FAIL_IMMEDIATELY; + + TRACE("ofs %u count %u flags %x\n", libOffset.u.LowPart, cb.u.LowPart, dwLockType); + + if (dwLockType & LOCK_WRITE) + return STG_E_INVALIDFUNCTION; + + if (dwLockType & (LOCK_EXCLUSIVE|LOCK_ONLYONCE)) + lock_flags |= LOCKFILE_EXCLUSIVE_LOCK; + + ol.hEvent = 0; + ol.u.s.Offset = libOffset.u.LowPart; + ol.u.s.OffsetHigh = libOffset.u.HighPart; + + if (LockFileEx(This->hfile, lock_flags, 0, cb.u.LowPart, cb.u.HighPart, &ol)) + return S_OK; + return get_lock_error(); +} + +HRESULT FileLockBytesImpl_LockRegionSync(ILockBytes* iface, + ULARGE_INTEGER libOffset, ULARGE_INTEGER cb) +{ + FileLockBytesImpl* This = impl_from_ILockBytes(iface); + OVERLAPPED ol; + + if (iface->lpVtbl != &FileLockBytesImpl_Vtbl) + return E_NOTIMPL; + + ol.hEvent = 0; + ol.u.s.Offset = libOffset.u.LowPart; + ol.u.s.OffsetHigh = libOffset.u.HighPart; + + if (LockFileEx(This->hfile, LOCKFILE_EXCLUSIVE_LOCK, 0, cb.u.LowPart, cb.u.HighPart, &ol)) + return S_OK; + return get_lock_error(); } static HRESULT WINAPI FileLockBytesImpl_UnlockRegion(ILockBytes* iface, ULARGE_INTEGER libOffset, ULARGE_INTEGER cb, DWORD dwLockType) { - FIXME("stub\n"); - return E_NOTIMPL; + FileLockBytesImpl* This = impl_from_ILockBytes(iface); + OVERLAPPED ol; + + TRACE("ofs %u count %u flags %x\n", libOffset.u.LowPart, cb.u.LowPart, dwLockType); + + if (dwLockType & LOCK_WRITE) + return STG_E_INVALIDFUNCTION; + + ol.hEvent = 0; + ol.u.s.Offset = libOffset.u.LowPart; + ol.u.s.OffsetHigh = libOffset.u.HighPart; + + if (UnlockFileEx(This->hfile, 0, cb.u.LowPart, cb.u.HighPart, &ol)) + return S_OK; + return get_lock_error(); } static HRESULT WINAPI FileLockBytesImpl_Stat(ILockBytes* iface, @@ -341,7 +384,8 @@ static HRESULT WINAPI FileLockBytesImpl_Stat(ILockBytes* iface, pstatstg->pwcsName = NULL; pstatstg->type = STGTY_LOCKBYTES; - pstatstg->cbSize = This->filesize; + + pstatstg->cbSize.u.LowPart = GetFileSize(This->hfile, &pstatstg->cbSize.u.HighPart); /* FIXME: If the implementation is exported, we'll need to set other fields. */ return S_OK; diff --git a/dll/win32/ole32/filemoniker.c b/dll/win32/ole32/filemoniker.c index 95e0e13e2c8..e3b5ab973e2 100644 --- a/dll/win32/ole32/filemoniker.c +++ b/dll/win32/ole32/filemoniker.c @@ -588,22 +588,11 @@ FileMonikerImpl_BindToStorage(IMoniker* iface, IBindCtx* pbc, IMoniker* pmkToLef /* get the file name */ IMoniker_GetDisplayName(iface,pbc,pmkToLeft,&filePath); - /* verify if the file contains a storage object */ - res=StgIsStorageFile(filePath); + res=StgOpenStorage(filePath,NULL,STGM_READWRITE|STGM_SHARE_DENY_WRITE,NULL,0,&pstg); - if(res==S_OK){ + if (SUCCEEDED(res)) + *ppvObject=pstg; - res=StgOpenStorage(filePath,NULL,STGM_READWRITE|STGM_SHARE_DENY_WRITE,NULL,0,&pstg); - - if (SUCCEEDED(res)){ - - *ppvObject=pstg; - - IStorage_AddRef(pstg); - - return res; - } - } CoTaskMemFree(filePath); } else diff --git a/dll/win32/ole32/ole2.c b/dll/win32/ole32/ole2.c index 363dfc845be..9d7a19ee03e 100644 --- a/dll/win32/ole32/ole2.c +++ b/dll/win32/ole32/ole2.c @@ -2179,7 +2179,9 @@ static LRESULT WINAPI OLEDD_DragTrackerWindowProc( case WM_MBUTTONDOWN: case WM_RBUTTONDOWN: { - OLEDD_TrackStateChange((TrackerWindowInfo*)GetWindowLongPtrA(hwnd, 0)); + TrackerWindowInfo *trackerInfo = (TrackerWindowInfo*)GetWindowLongPtrA(hwnd, 0); + if (trackerInfo->trackingDone) break; + OLEDD_TrackStateChange(trackerInfo); break; } case WM_DESTROY: @@ -2843,6 +2845,8 @@ static inline HRESULT PROPVARIANT_ValidateType(VARTYPE vt) case VT_LPWSTR: case VT_FILETIME: case VT_BLOB: + case VT_DISPATCH: + case VT_UNKNOWN: case VT_STREAM: case VT_STORAGE: case VT_STREAMED_OBJECT: @@ -2919,6 +2923,8 @@ HRESULT WINAPI PropVariantClear(PROPVARIANT * pvar) /* [in/out] */ case VT_UINT: case VT_FILETIME: break; + case VT_DISPATCH: + case VT_UNKNOWN: case VT_STREAM: case VT_STREAMED_OBJECT: case VT_STORAGE: @@ -3032,6 +3038,8 @@ HRESULT WINAPI PropVariantCopy(PROPVARIANT *pvarDest, /* [out] */ case VT_DATE: case VT_FILETIME: break; + case VT_DISPATCH: + case VT_UNKNOWN: case VT_STREAM: case VT_STREAMED_OBJECT: case VT_STORAGE: diff --git a/dll/win32/ole32/stg_stream.c b/dll/win32/ole32/stg_stream.c index e5e696308ab..10ddafe1c06 100644 --- a/dll/win32/ole32/stg_stream.c +++ b/dll/win32/ole32/stg_stream.c @@ -151,7 +151,7 @@ static HRESULT WINAPI StgStreamImpl_Read( /* * Advance the pointer for the number of positions read. */ - This->currentPosition.u.LowPart += *pcbRead; + This->currentPosition.QuadPart += *pcbRead; } TRACE("<-- %08x\n", res); @@ -232,12 +232,12 @@ static HRESULT WINAPI StgStreamImpl_Write( /* * Advance the position pointer for the number of positions written. */ - This->currentPosition.u.LowPart += *pcbWritten; + This->currentPosition.QuadPart += *pcbWritten; if (SUCCEEDED(res)) res = StorageBaseImpl_Flush(This->parentStorage); - TRACE("<-- S_OK, written %u\n", *pcbWritten); + TRACE("<-- %08x, written %u\n", res, *pcbWritten); return res; } diff --git a/dll/win32/ole32/storage32.c b/dll/win32/ole32/storage32.c index fd59674acf6..7c4bb214bab 100644 --- a/dll/win32/ole32/storage32.c +++ b/dll/win32/ole32/storage32.c @@ -83,6 +83,7 @@ static const IStorageVtbl Storage32InternalImpl_Vtbl; /* Method definitions for the Storage32InternalImpl class. */ static StorageInternalImpl* StorageInternalImpl_Construct(StorageBaseImpl* parentStorage, DWORD openFlags, DirRef storageDirEntry); +static HRESULT StorageImpl_Refresh(StorageImpl *This, BOOL new_object, BOOL create); static void StorageImpl_Destroy(StorageBaseImpl* iface); static void StorageImpl_Invalidate(StorageBaseImpl* iface); static HRESULT StorageImpl_Flush(StorageBaseImpl* iface); @@ -91,8 +92,9 @@ static BOOL StorageImpl_WriteBigBlock(StorageImpl* This, ULONG blockIndex, const static void StorageImpl_SetNextBlockInChain(StorageImpl* This, ULONG blockIndex, ULONG nextBlock); static HRESULT StorageImpl_LoadFileHeader(StorageImpl* This); static void StorageImpl_SaveFileHeader(StorageImpl* This); +static HRESULT StorageImpl_LockRegionSync(StorageImpl *This, ULARGE_INTEGER offset, ULARGE_INTEGER cb, DWORD dwLockType); -static void Storage32Impl_AddBlockDepot(StorageImpl* This, ULONG blockIndex); +static void Storage32Impl_AddBlockDepot(StorageImpl* This, ULONG blockIndex, ULONG depotIndex); static ULONG Storage32Impl_AddExtBlockDepot(StorageImpl* This); static ULONG Storage32Impl_GetNextExtendedBlock(StorageImpl* This, ULONG blockIndex); static ULONG Storage32Impl_GetExtDepotBlock(StorageImpl* This, ULONG depotIndex); @@ -172,10 +174,31 @@ typedef struct TransactedSnapshotImpl * Changes are committed to the transacted parent. */ StorageBaseImpl *transactedParent; + + /* The transaction signature from when we last committed */ + ULONG lastTransactionSig; } TransactedSnapshotImpl; +typedef struct TransactedSharedImpl +{ + struct StorageBaseImpl base; + + /* + * Snapshot and uncommitted changes go here. + */ + TransactedSnapshotImpl *scratch; + + /* + * Changes are committed to the transacted parent. + */ + StorageBaseImpl *transactedParent; + + /* The transaction signature from when we last committed */ + ULONG lastTransactionSig; +} TransactedSharedImpl; + /* Generic function to create a transacted wrapper for a direct storage object. */ -static HRESULT Storage_ConstructTransacted(StorageBaseImpl* parent, StorageBaseImpl** result); +static HRESULT Storage_ConstructTransacted(StorageBaseImpl* parent, BOOL toplevel, StorageBaseImpl** result); /* OLESTREAM memory structure to use for Get and Put Routines */ /* Used for OleConvertIStorageToOLESTREAM and OleConvertOLESTREAMToIStorage */ @@ -311,9 +334,9 @@ static void IEnumSTATSTGImpl_Destroy(IEnumSTATSTGImpl* This); ** Block Functions */ -static ULONG StorageImpl_GetBigBlockOffset(StorageImpl* This, ULONG index) +static ULONGLONG StorageImpl_GetBigBlockOffset(StorageImpl* This, ULONG index) { - return (index+1) * This->bigBlockSize; + return (ULONGLONG)(index+1) * This->bigBlockSize; } /************************************************************************ @@ -647,7 +670,7 @@ static HRESULT WINAPI StorageBaseImpl_OpenStorage( { if (grfMode & STGM_TRANSACTED) { - res = Storage_ConstructTransacted(&newStorage->base, &newTransactedStorage); + res = Storage_ConstructTransacted(&newStorage->base, FALSE, &newTransactedStorage); if (FAILED(res)) { @@ -1280,8 +1303,7 @@ static HRESULT StorageImpl_CreateDirEntry( /* * initialize the size used by the directory stream */ - newSize.u.HighPart = 0; - newSize.u.LowPart = storage->bigBlockSize * blockCount; + newSize.QuadPart = (ULONGLONG)storage->bigBlockSize * blockCount; /* * add a block to the directory stream @@ -2560,7 +2582,6 @@ static HRESULT StorageImpl_StreamWriteAt(StorageBaseImpl *base, DirRef index, if (FAILED(hr)) return hr; /* Grow the stream if necessary */ - newSize.QuadPart = 0; newSize.QuadPart = offset.QuadPart + size; if (newSize.QuadPart > data.size.QuadPart) @@ -2621,6 +2642,108 @@ static HRESULT StorageImpl_StreamLink(StorageBaseImpl *base, DirRef dst, return hr; } +static HRESULT StorageImpl_GetTransactionSig(StorageBaseImpl *base, + ULONG* result, BOOL refresh) +{ + StorageImpl *This = (StorageImpl*)base; + HRESULT hr=S_OK; + DWORD oldTransactionSig = This->transactionSig; + + if (refresh) + { + ULARGE_INTEGER offset; + ULONG bytes_read; + BYTE data[4]; + + offset.u.HighPart = 0; + offset.u.LowPart = OFFSET_TRANSACTIONSIG; + hr = StorageImpl_ReadAt(This, offset, data, 4, &bytes_read); + + if (SUCCEEDED(hr)) + { + StorageUtl_ReadDWord(data, 0, &This->transactionSig); + + if (oldTransactionSig != This->transactionSig) + { + /* Someone else wrote to this, so toss all cached information. */ + TRACE("signature changed\n"); + + hr = StorageImpl_Refresh(This, FALSE, FALSE); + } + + if (FAILED(hr)) + This->transactionSig = oldTransactionSig; + } + } + + *result = This->transactionSig; + + return hr; +} + +static HRESULT StorageImpl_SetTransactionSig(StorageBaseImpl *base, + ULONG value) +{ + StorageImpl *This = (StorageImpl*)base; + + This->transactionSig = value; + StorageImpl_SaveFileHeader(This); + + return S_OK; +} + +static HRESULT StorageImpl_LockTransaction(StorageBaseImpl *base, BOOL write) +{ + StorageImpl *This = (StorageImpl*)base; + HRESULT hr; + ULARGE_INTEGER offset, cb; + + if (write) + { + /* Synchronous grab of second priority range, the commit lock, and the + * lock-checking lock. */ + offset.QuadPart = RANGELOCK_TRANSACTION_FIRST; + cb.QuadPart = RANGELOCK_TRANSACTION_LAST - RANGELOCK_TRANSACTION_FIRST + 1; + } + else + { + offset.QuadPart = RANGELOCK_COMMIT; + cb.QuadPart = 1; + } + + hr = StorageImpl_LockRegionSync(This, offset, cb, LOCK_ONLYONCE); + + if (hr == STG_E_INVALIDFUNCTION) + hr = S_OK; + + return hr; +} + +static HRESULT StorageImpl_UnlockTransaction(StorageBaseImpl *base, BOOL write) +{ + StorageImpl *This = (StorageImpl*)base; + HRESULT hr; + ULARGE_INTEGER offset, cb; + + if (write) + { + offset.QuadPart = RANGELOCK_TRANSACTION_FIRST; + cb.QuadPart = RANGELOCK_TRANSACTION_LAST - RANGELOCK_TRANSACTION_FIRST + 1; + } + else + { + offset.QuadPart = RANGELOCK_COMMIT; + cb.QuadPart = 1; + } + + hr = ILockBytes_UnlockRegion(This->lockBytes, offset, cb, LOCK_ONLYONCE); + + if (hr == STG_E_INVALIDFUNCTION) + hr = S_OK; + + return hr; +} + static HRESULT StorageImpl_GetFilename(StorageBaseImpl* iface, LPWSTR *result) { StorageImpl *This = (StorageImpl*) iface; @@ -2721,69 +2844,163 @@ static const StorageBaseImplVtbl StorageImpl_BaseVtbl = StorageImpl_StreamReadAt, StorageImpl_StreamWriteAt, StorageImpl_StreamSetSize, - StorageImpl_StreamLink + StorageImpl_StreamLink, + StorageImpl_GetTransactionSig, + StorageImpl_SetTransactionSig, + StorageImpl_LockTransaction, + StorageImpl_UnlockTransaction }; -static HRESULT StorageImpl_Construct( - HANDLE hFile, - LPCOLESTR pwcsName, - ILockBytes* pLkbyt, - DWORD openFlags, - BOOL fileBased, - BOOL create, - ULONG sector_size, - StorageImpl** result) +static HRESULT StorageImpl_LockRegionSync(StorageImpl *This, ULARGE_INTEGER offset, + ULARGE_INTEGER cb, DWORD dwLockType) { - StorageImpl* This; - HRESULT hr = S_OK; + HRESULT hr; + int delay = 0; + + /* if it's a FileLockBytesImpl use LockFileEx in blocking mode */ + if (SUCCEEDED(FileLockBytesImpl_LockRegionSync(This->lockBytes, offset, cb))) + return S_OK; + + /* otherwise we have to fake it based on an async lock */ + do + { + hr = ILockBytes_LockRegion(This->lockBytes, offset, cb, dwLockType); + + if (hr == STG_E_ACCESSDENIED || hr == STG_E_LOCKVIOLATION) + { + Sleep(delay); + if (delay < 150) delay++; + } + } while (hr == STG_E_ACCESSDENIED || hr == STG_E_LOCKVIOLATION); + + return hr; +} + +static HRESULT StorageImpl_CheckLockRange(StorageImpl *This, ULONG start, + ULONG end, HRESULT fail_hr) +{ + HRESULT hr; + ULARGE_INTEGER offset, cb; + + offset.QuadPart = start; + cb.QuadPart = 1 + end - start; + + hr = ILockBytes_LockRegion(This->lockBytes, offset, cb, LOCK_ONLYONCE); + if (SUCCEEDED(hr)) ILockBytes_UnlockRegion(This->lockBytes, offset, cb, LOCK_ONLYONCE); + + if (hr == STG_E_ACCESSDENIED || hr == STG_E_LOCKVIOLATION) + return fail_hr; + else + return S_OK; +} + +static HRESULT StorageImpl_LockOne(StorageImpl *This, ULONG start, ULONG end) +{ + HRESULT hr=S_OK; + int i, j; + ULARGE_INTEGER offset, cb; + + cb.QuadPart = 1; + + for (i=start; i<=end; i++) + { + offset.QuadPart = i; + hr = ILockBytes_LockRegion(This->lockBytes, offset, cb, LOCK_ONLYONCE); + if (hr != STG_E_ACCESSDENIED && hr != STG_E_LOCKVIOLATION) + break; + } + + if (SUCCEEDED(hr)) + { + for (j=0; jlocked_bytes)/sizeof(This->locked_bytes[0]); j++) + { + if (This->locked_bytes[j] == 0) + { + This->locked_bytes[j] = i; + break; + } + } + } + + return hr; +} + +static HRESULT StorageImpl_GrabLocks(StorageImpl *This, DWORD openFlags) +{ + HRESULT hr; + ULARGE_INTEGER offset; + ULARGE_INTEGER cb; + DWORD share_mode = STGM_SHARE_MODE(openFlags); + + if (openFlags & STGM_NOSNAPSHOT) + { + /* STGM_NOSNAPSHOT implies deny write */ + if (share_mode == STGM_SHARE_DENY_READ) share_mode = STGM_SHARE_EXCLUSIVE; + else if (share_mode != STGM_SHARE_EXCLUSIVE) share_mode = STGM_SHARE_DENY_WRITE; + } + + /* Wrap all other locking inside a single lock so we can check ranges safely */ + offset.QuadPart = RANGELOCK_CHECKLOCKS; + cb.QuadPart = 1; + hr = StorageImpl_LockRegionSync(This, offset, cb, LOCK_ONLYONCE); + + /* If the ILockBytes doesn't support locking that's ok. */ + if (FAILED(hr)) return S_OK; + + hr = S_OK; + + /* First check for any conflicting locks. */ + if (SUCCEEDED(hr) && (openFlags & STGM_PRIORITY) == STGM_PRIORITY) + hr = StorageImpl_CheckLockRange(This, RANGELOCK_COMMIT, RANGELOCK_COMMIT, STG_E_LOCKVIOLATION); + + if (SUCCEEDED(hr) && (STGM_ACCESS_MODE(openFlags) != STGM_WRITE)) + hr = StorageImpl_CheckLockRange(This, RANGELOCK_DENY_READ_FIRST, RANGELOCK_DENY_READ_LAST, STG_E_SHAREVIOLATION); + + if (SUCCEEDED(hr) && (STGM_ACCESS_MODE(openFlags) != STGM_READ)) + hr = StorageImpl_CheckLockRange(This, RANGELOCK_DENY_WRITE_FIRST, RANGELOCK_DENY_WRITE_LAST, STG_E_SHAREVIOLATION); + + if (SUCCEEDED(hr) && (share_mode == STGM_SHARE_DENY_READ || share_mode == STGM_SHARE_EXCLUSIVE)) + hr = StorageImpl_CheckLockRange(This, RANGELOCK_READ_FIRST, RANGELOCK_READ_LAST, STG_E_LOCKVIOLATION); + + if (SUCCEEDED(hr) && (share_mode == STGM_SHARE_DENY_WRITE || share_mode == STGM_SHARE_EXCLUSIVE)) + hr = StorageImpl_CheckLockRange(This, RANGELOCK_WRITE_FIRST, RANGELOCK_WRITE_LAST, STG_E_LOCKVIOLATION); + + /* Then grab our locks. */ + if (SUCCEEDED(hr) && (openFlags & STGM_PRIORITY) == STGM_PRIORITY) + { + hr = StorageImpl_LockOne(This, RANGELOCK_PRIORITY1_FIRST, RANGELOCK_PRIORITY1_LAST); + if (SUCCEEDED(hr)) + hr = StorageImpl_LockOne(This, RANGELOCK_PRIORITY2_FIRST, RANGELOCK_PRIORITY2_LAST); + } + + if (SUCCEEDED(hr) && (STGM_ACCESS_MODE(openFlags) != STGM_WRITE)) + hr = StorageImpl_LockOne(This, RANGELOCK_READ_FIRST, RANGELOCK_READ_LAST); + + if (SUCCEEDED(hr) && (STGM_ACCESS_MODE(openFlags) != STGM_READ)) + hr = StorageImpl_LockOne(This, RANGELOCK_WRITE_FIRST, RANGELOCK_WRITE_LAST); + + if (SUCCEEDED(hr) && (share_mode == STGM_SHARE_DENY_READ || share_mode == STGM_SHARE_EXCLUSIVE)) + hr = StorageImpl_LockOne(This, RANGELOCK_DENY_READ_FIRST, RANGELOCK_DENY_READ_LAST); + + if (SUCCEEDED(hr) && (share_mode == STGM_SHARE_DENY_WRITE || share_mode == STGM_SHARE_EXCLUSIVE)) + hr = StorageImpl_LockOne(This, RANGELOCK_DENY_WRITE_FIRST, RANGELOCK_DENY_WRITE_LAST); + + if (SUCCEEDED(hr) && (openFlags & STGM_NOSNAPSHOT) == STGM_NOSNAPSHOT) + hr = StorageImpl_LockOne(This, RANGELOCK_NOSNAPSHOT_FIRST, RANGELOCK_NOSNAPSHOT_LAST); + + offset.QuadPart = RANGELOCK_CHECKLOCKS; + cb.QuadPart = 1; + ILockBytes_UnlockRegion(This->lockBytes, offset, cb, LOCK_ONLYONCE); + + return hr; +} + +static HRESULT StorageImpl_Refresh(StorageImpl *This, BOOL new_object, BOOL create) +{ + HRESULT hr=S_OK; DirEntry currentEntry; DirRef currentEntryRef; - - if ( FAILED( validateSTGM(openFlags) )) - return STG_E_INVALIDFLAG; - - This = HeapAlloc(GetProcessHeap(), 0, sizeof(StorageImpl)); - if (!This) - return E_OUTOFMEMORY; - - memset(This, 0, sizeof(StorageImpl)); - - list_init(&This->base.strmHead); - - list_init(&This->base.storageHead); - - This->base.IStorage_iface.lpVtbl = &Storage32Impl_Vtbl; - This->base.IPropertySetStorage_iface.lpVtbl = &IPropertySetStorage_Vtbl; - This->base.IDirectWriterLock_iface.lpVtbl = &DirectWriterLockVtbl; - This->base.baseVtbl = &StorageImpl_BaseVtbl; - This->base.openFlags = (openFlags & ~STGM_CREATE); - This->base.ref = 1; - This->base.create = create; - - if (openFlags == (STGM_DIRECT_SWMR|STGM_READWRITE|STGM_SHARE_DENY_WRITE)) - This->base.lockingrole = SWMR_Writer; - else if (openFlags == (STGM_DIRECT_SWMR|STGM_READ|STGM_SHARE_DENY_NONE)) - This->base.lockingrole = SWMR_Reader; - else - This->base.lockingrole = SWMR_None; - - This->base.reverted = FALSE; - - /* - * Initialize the big block cache. - */ - This->bigBlockSize = sector_size; - This->smallBlockSize = DEF_SMALL_BLOCK_SIZE; - if (hFile) - hr = FileLockBytesImpl_Construct(hFile, openFlags, pwcsName, &This->lockBytes); - else - { - This->lockBytes = pLkbyt; - ILockBytes_AddRef(pLkbyt); - } - - if (FAILED(hr)) - goto end; + BlockChainStream *blockChainStream; if (create) { @@ -2809,7 +3026,7 @@ static HRESULT StorageImpl_Construct( This->rootStartBlock = 1; This->smallBlockLimit = LIMIT_TO_USE_SMALL_BLOCK; This->smallBlockDepotStart = BLOCK_END_OF_CHAIN; - if (sector_size == 4096) + if (This->bigBlockSize == 4096) This->bigBlockSizeBits = MAX_BIG_BLOCK_SIZE_BITS; else This->bigBlockSizeBits = MIN_BIG_BLOCK_SIZE_BITS; @@ -2843,7 +3060,7 @@ static HRESULT StorageImpl_Construct( if (FAILED(hr)) { - goto end; + return hr; } } @@ -2870,8 +3087,7 @@ static HRESULT StorageImpl_Construct( This->extBigBlockDepotLocations = HeapAlloc(GetProcessHeap(), 0, sizeof(ULONG) * cache_size); if (!This->extBigBlockDepotLocations) { - hr = E_OUTOFMEMORY; - goto end; + return E_OUTOFMEMORY; } This->extBigBlockDepotLocationsSize = cache_size; @@ -2881,8 +3097,7 @@ static HRESULT StorageImpl_Construct( if (current_block == BLOCK_END_OF_CHAIN) { WARN("File has too few extended big block depot blocks.\n"); - hr = STG_E_DOCFILECORRUPT; - goto end; + return STG_E_DOCFILECORRUPT; } This->extBigBlockDepotLocations[i] = current_block; current_block = Storage32Impl_GetNextExtendedBlock(This, current_block); @@ -2897,20 +3112,24 @@ static HRESULT StorageImpl_Construct( /* * Create the block chain abstractions. */ - if(!(This->rootBlockChain = + if(!(blockChainStream = BlockChainStream_Construct(This, &This->rootStartBlock, DIRENTRY_NULL))) { - hr = STG_E_READFAULT; - goto end; + return STG_E_READFAULT; } + if (!new_object) + BlockChainStream_Destroy(This->rootBlockChain); + This->rootBlockChain = blockChainStream; - if(!(This->smallBlockDepotChain = + if(!(blockChainStream = BlockChainStream_Construct(This, &This->smallBlockDepotStart, DIRENTRY_NULL))) { - hr = STG_E_READFAULT; - goto end; + return STG_E_READFAULT; } + if (!new_object) + BlockChainStream_Destroy(This->smallBlockDepotChain); + This->smallBlockDepotChain = blockChainStream; /* * Write the root storage entry (memory only) @@ -2963,20 +3182,96 @@ static HRESULT StorageImpl_Construct( if (FAILED(hr)) { - hr = STG_E_READFAULT; - goto end; + return STG_E_READFAULT; } /* * Create the block chain abstraction for the small block root chain. */ - if(!(This->smallBlockRootChain = + if(!(blockChainStream = BlockChainStream_Construct(This, NULL, This->base.storageDirEntry))) { - hr = STG_E_READFAULT; + return STG_E_READFAULT; + } + if (!new_object) + BlockChainStream_Destroy(This->smallBlockRootChain); + This->smallBlockRootChain = blockChainStream; + + if (!new_object) + { + int i; + for (i=0; iblockChainCache[i]); + This->blockChainCache[i] = NULL; + } } -end: + return hr; +} + +static HRESULT StorageImpl_Construct( + HANDLE hFile, + LPCOLESTR pwcsName, + ILockBytes* pLkbyt, + DWORD openFlags, + BOOL fileBased, + BOOL create, + ULONG sector_size, + StorageImpl** result) +{ + StorageImpl* This; + HRESULT hr = S_OK; + + if ( FAILED( validateSTGM(openFlags) )) + return STG_E_INVALIDFLAG; + + This = HeapAlloc(GetProcessHeap(), 0, sizeof(StorageImpl)); + if (!This) + return E_OUTOFMEMORY; + + memset(This, 0, sizeof(StorageImpl)); + + list_init(&This->base.strmHead); + + list_init(&This->base.storageHead); + + This->base.IStorage_iface.lpVtbl = &Storage32Impl_Vtbl; + This->base.IPropertySetStorage_iface.lpVtbl = &IPropertySetStorage_Vtbl; + This->base.IDirectWriterLock_iface.lpVtbl = &DirectWriterLockVtbl; + This->base.baseVtbl = &StorageImpl_BaseVtbl; + This->base.openFlags = (openFlags & ~STGM_CREATE); + This->base.ref = 1; + This->base.create = create; + + if (openFlags == (STGM_DIRECT_SWMR|STGM_READWRITE|STGM_SHARE_DENY_WRITE)) + This->base.lockingrole = SWMR_Writer; + else if (openFlags == (STGM_DIRECT_SWMR|STGM_READ|STGM_SHARE_DENY_NONE)) + This->base.lockingrole = SWMR_Reader; + else + This->base.lockingrole = SWMR_None; + + This->base.reverted = FALSE; + + /* + * Initialize the big block cache. + */ + This->bigBlockSize = sector_size; + This->smallBlockSize = DEF_SMALL_BLOCK_SIZE; + if (hFile) + hr = FileLockBytesImpl_Construct(hFile, openFlags, pwcsName, &This->lockBytes); + else + { + This->lockBytes = pLkbyt; + ILockBytes_AddRef(pLkbyt); + } + + if (SUCCEEDED(hr)) + hr = StorageImpl_GrabLocks(This, openFlags); + + if (SUCCEEDED(hr)) + hr = StorageImpl_Refresh(This, TRUE, create); + if (FAILED(hr)) { IStorage_Release(&This->base.IStorage_iface); @@ -3019,6 +3314,17 @@ static void StorageImpl_Destroy(StorageBaseImpl* iface) for (i=0; iblockChainCache[i]); + for (i=0; ilocked_bytes)/sizeof(This->locked_bytes[0]); i++) + { + ULARGE_INTEGER offset, cb; + cb.QuadPart = 1; + if (This->locked_bytes[i] != 0) + { + offset.QuadPart = This->locked_bytes[i]; + ILockBytes_UnlockRegion(This->lockBytes, offset, cb, LOCK_ONLYONCE); + } + } + if (This->lockBytes) ILockBytes_Release(This->lockBytes); HeapFree(GetProcessHeap(), 0, This); @@ -3092,7 +3398,7 @@ static ULONG StorageImpl_GetNextFreeBigBlock( /* * Add a block depot. */ - Storage32Impl_AddBlockDepot(This, depotBlockIndexPos); + Storage32Impl_AddBlockDepot(This, depotBlockIndexPos, depotIndex); This->bigBlockDepotCount++; This->bigBlockDepotStart[depotIndex] = depotBlockIndexPos; @@ -3135,7 +3441,7 @@ static ULONG StorageImpl_GetNextFreeBigBlock( /* * Add a block depot and mark it in the extended block. */ - Storage32Impl_AddBlockDepot(This, depotBlockIndexPos); + Storage32Impl_AddBlockDepot(This, depotBlockIndexPos, depotIndex); This->bigBlockDepotCount++; Storage32Impl_SetExtDepotBlock(This, depotIndex, depotBlockIndexPos); @@ -3200,14 +3506,24 @@ static ULONG StorageImpl_GetNextFreeBigBlock( * This will create a depot block, essentially it is a block initialized * to BLOCK_UNUSEDs. */ -static void Storage32Impl_AddBlockDepot(StorageImpl* This, ULONG blockIndex) +static void Storage32Impl_AddBlockDepot(StorageImpl* This, ULONG blockIndex, ULONG depotIndex) { BYTE blockBuffer[MAX_BIG_BLOCK_SIZE]; + ULONG rangeLockIndex = RANGELOCK_FIRST / This->bigBlockSize - 1; + ULONG blocksPerDepot = This->bigBlockSize / sizeof(ULONG); + ULONG rangeLockDepot = rangeLockIndex / blocksPerDepot; /* * Initialize blocks as free */ memset(blockBuffer, BLOCK_UNUSED, This->bigBlockSize); + + /* Reserve the range lock sector */ + if (depotIndex == rangeLockDepot) + { + ((ULONG*)blockBuffer)[rangeLockIndex % blocksPerDepot] = BLOCK_END_OF_CHAIN; + } + StorageImpl_WriteBigBlock(This, blockIndex, blockBuffer); } @@ -3504,6 +3820,13 @@ static void StorageImpl_SetNextBlockInChain( assert(depotBlockCount < This->bigBlockDepotCount); assert(blockIndex != nextBlock); + if (blockIndex == (RANGELOCK_FIRST / This->bigBlockSize) - 1) + /* This should never happen (storage file format spec forbids it), but + * older versions of Wine may have generated broken files. We don't want to + * assert and potentially lose data, but we do want to know if this ever + * happens in a newly-created file. */ + ERR("Using range lock page\n"); + if (depotBlockCount < COUNT_BBDEPOTINHEADER) { depotBlockIndexPos = This->bigBlockDepotStart[depotBlockCount]; @@ -3590,6 +3913,11 @@ static HRESULT StorageImpl_LoadFileHeader( OFFSET_ROOTSTARTBLOCK, &This->rootStartBlock); + StorageUtl_ReadDWord( + headerBigBlock, + OFFSET_TRANSACTIONSIG, + &This->transactionSig); + StorageUtl_ReadDWord( headerBigBlock, OFFSET_SMALLBLOCKLIMIT, @@ -3748,6 +4076,11 @@ static void StorageImpl_SaveFileHeader( OFFSET_ROOTSTARTBLOCK, This->rootStartBlock); + StorageUtl_WriteDWord( + headerBigBlock, + OFFSET_TRANSACTIONSIG, + This->transactionSig); + StorageUtl_WriteDWord( headerBigBlock, OFFSET_SMALLBLOCKLIMIT, @@ -3801,8 +4134,7 @@ HRESULT StorageImpl_ReadRawDirEntry(StorageImpl *This, ULONG index, BYTE *buffer HRESULT hr; ULONG bytesRead; - offset.u.HighPart = 0; - offset.u.LowPart = index * RAW_DIRENTRY_SIZE; + offset.QuadPart = (ULONGLONG)index * RAW_DIRENTRY_SIZE; hr = BlockChainStream_ReadAt( This->rootBlockChain, @@ -3829,8 +4161,7 @@ HRESULT StorageImpl_WriteRawDirEntry(StorageImpl *This, ULONG index, const BYTE ULARGE_INTEGER offset; ULONG bytesRead; - offset.u.HighPart = 0; - offset.u.LowPart = index * RAW_DIRENTRY_SIZE; + offset.QuadPart = (ULONGLONG)index * RAW_DIRENTRY_SIZE; return BlockChainStream_WriteAt( This->rootBlockChain, @@ -3912,6 +4243,11 @@ void UpdateRawDirEntry(BYTE *buffer, const DirEntry *newData) buffer, OFFSET_PS_SIZE, newData->size.u.LowPart); + + StorageUtl_WriteDWord( + buffer, + OFFSET_PS_SIZE_HIGH, + newData->size.u.HighPart); } /****************************************************************************** @@ -3995,7 +4331,10 @@ HRESULT StorageImpl_ReadDirEntry( OFFSET_PS_SIZE, &buffer->size.u.LowPart); - buffer->size.u.HighPart = 0; + StorageUtl_ReadDWord( + currentEntry, + OFFSET_PS_SIZE_HIGH, + &buffer->size.u.HighPart); } return readRes; @@ -4026,8 +4365,7 @@ static HRESULT StorageImpl_ReadBigBlock( DWORD read=0; HRESULT hr; - ulOffset.u.HighPart = 0; - ulOffset.u.LowPart = StorageImpl_GetBigBlockOffset(This, blockIndex); + ulOffset.QuadPart = StorageImpl_GetBigBlockOffset(This, blockIndex); hr = StorageImpl_ReadAt(This, ulOffset, buffer, This->bigBlockSize, &read); @@ -4052,9 +4390,8 @@ static BOOL StorageImpl_ReadDWordFromBigBlock( DWORD read; DWORD tmp; - ulOffset.u.HighPart = 0; - ulOffset.u.LowPart = StorageImpl_GetBigBlockOffset(This, blockIndex); - ulOffset.u.LowPart += offset; + ulOffset.QuadPart = StorageImpl_GetBigBlockOffset(This, blockIndex); + ulOffset.QuadPart += offset; StorageImpl_ReadAt(This, ulOffset, &tmp, sizeof(DWORD), &read); *value = lendian32toh(tmp); @@ -4069,8 +4406,7 @@ static BOOL StorageImpl_WriteBigBlock( ULARGE_INTEGER ulOffset; DWORD wrote; - ulOffset.u.HighPart = 0; - ulOffset.u.LowPart = StorageImpl_GetBigBlockOffset(This, blockIndex); + ulOffset.QuadPart = StorageImpl_GetBigBlockOffset(This, blockIndex); StorageImpl_WriteAt(This, ulOffset, buffer, This->bigBlockSize, &wrote); return (wrote == This->bigBlockSize); @@ -4085,9 +4421,8 @@ static BOOL StorageImpl_WriteDWordToBigBlock( ULARGE_INTEGER ulOffset; DWORD wrote; - ulOffset.u.HighPart = 0; - ulOffset.u.LowPart = StorageImpl_GetBigBlockOffset(This, blockIndex); - ulOffset.u.LowPart += offset; + ulOffset.QuadPart = StorageImpl_GetBigBlockOffset(This, blockIndex); + ulOffset.QuadPart += offset; value = htole32(value); StorageImpl_WriteAt(This, ulOffset, &value, sizeof(DWORD), &wrote); @@ -4342,6 +4677,106 @@ static HRESULT StorageBaseImpl_CopyStream( return hr; } +static HRESULT StorageBaseImpl_DupStorageTree( + StorageBaseImpl *dst, DirRef *dst_entry, + StorageBaseImpl *src, DirRef src_entry) +{ + HRESULT hr; + DirEntry data; + BOOL has_stream=FALSE; + + if (src_entry == DIRENTRY_NULL) + { + *dst_entry = DIRENTRY_NULL; + return S_OK; + } + + hr = StorageBaseImpl_ReadDirEntry(src, src_entry, &data); + if (SUCCEEDED(hr)) + { + has_stream = (data.stgType == STGTY_STREAM && data.size.QuadPart != 0); + data.startingBlock = BLOCK_END_OF_CHAIN; + data.size.QuadPart = 0; + + hr = StorageBaseImpl_DupStorageTree(dst, &data.leftChild, src, data.leftChild); + } + + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_DupStorageTree(dst, &data.rightChild, src, data.rightChild); + + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_DupStorageTree(dst, &data.dirRootEntry, src, data.dirRootEntry); + + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_CreateDirEntry(dst, &data, dst_entry); + + if (SUCCEEDED(hr) && has_stream) + hr = StorageBaseImpl_CopyStream(dst, *dst_entry, src, src_entry); + + return hr; +} + +static HRESULT StorageBaseImpl_CopyStorageTree( + StorageBaseImpl *dst, DirRef dst_entry, + StorageBaseImpl *src, DirRef src_entry) +{ + HRESULT hr; + DirEntry src_data, dst_data; + DirRef new_root_entry; + + hr = StorageBaseImpl_ReadDirEntry(src, src_entry, &src_data); + + if (SUCCEEDED(hr)) + { + hr = StorageBaseImpl_DupStorageTree(dst, &new_root_entry, src, src_data.dirRootEntry); + } + + if (SUCCEEDED(hr)) + { + hr = StorageBaseImpl_ReadDirEntry(dst, dst_entry, &dst_data); + dst_data.clsid = src_data.clsid; + dst_data.ctime = src_data.ctime; + dst_data.mtime = src_data.mtime; + dst_data.dirRootEntry = new_root_entry; + } + + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_WriteDirEntry(dst, dst_entry, &dst_data); + + return hr; +} + +static HRESULT StorageBaseImpl_DeleteStorageTree(StorageBaseImpl *This, DirRef entry, BOOL include_siblings) +{ + HRESULT hr; + DirEntry data; + ULARGE_INTEGER zero; + + if (entry == DIRENTRY_NULL) + return S_OK; + + zero.QuadPart = 0; + + hr = StorageBaseImpl_ReadDirEntry(This, entry, &data); + + if (SUCCEEDED(hr) && include_siblings) + hr = StorageBaseImpl_DeleteStorageTree(This, data.leftChild, TRUE); + + if (SUCCEEDED(hr) && include_siblings) + hr = StorageBaseImpl_DeleteStorageTree(This, data.rightChild, TRUE); + + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_DeleteStorageTree(This, data.dirRootEntry, TRUE); + + if (SUCCEEDED(hr) && data.stgType == STGTY_STREAM) + hr = StorageBaseImpl_StreamSetSize(This, entry, zero); + + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_DestroyDirEntry(This, entry); + + return hr; +} + static DirRef TransactedSnapshotImpl_FindFreeEntry(TransactedSnapshotImpl *This) { DirRef result=This->firstFreeEntry; @@ -4696,6 +5131,7 @@ static HRESULT WINAPI TransactedSnapshotImpl_Commit( DirEntry data; ULARGE_INTEGER zero; HRESULT hr; + ULONG transactionSig; zero.QuadPart = 0; @@ -4705,89 +5141,116 @@ static HRESULT WINAPI TransactedSnapshotImpl_Commit( if ( STGM_ACCESS_MODE( This->base.openFlags ) == STGM_READ ) return STG_E_ACCESSDENIED; - /* To prevent data loss, we create the new structure in the file before we - * delete the old one, so that in case of errors the old data is intact. We - * shouldn't do this if STGC_OVERWRITE is set, but that flag should only be - * needed in the rare situation where we have just enough free disk space to - * overwrite the existing data. */ - - root_entry = &This->entries[This->base.storageDirEntry]; - - if (!root_entry->read) - return S_OK; - - hr = TransactedSnapshotImpl_CopyTree(This); - if (FAILED(hr)) return hr; - - if (root_entry->data.dirRootEntry == DIRENTRY_NULL) - dir_root_ref = DIRENTRY_NULL; - else - dir_root_ref = This->entries[root_entry->data.dirRootEntry].newTransactedParentEntry; - - hr = StorageBaseImpl_Flush(This->transactedParent); - - /* Update the storage to use the new data in one step. */ - if (SUCCEEDED(hr)) - hr = StorageBaseImpl_ReadDirEntry(This->transactedParent, - root_entry->transactedParentEntry, &data); - + hr = StorageBaseImpl_LockTransaction(This->transactedParent, TRUE); + if (hr == E_NOTIMPL) hr = S_OK; if (SUCCEEDED(hr)) { - data.dirRootEntry = dir_root_ref; - data.clsid = root_entry->data.clsid; - data.ctime = root_entry->data.ctime; - data.mtime = root_entry->data.mtime; - - hr = StorageBaseImpl_WriteDirEntry(This->transactedParent, - root_entry->transactedParentEntry, &data); - } - - /* Try to flush after updating the root storage, but if the flush fails, keep - * going, on the theory that it'll either succeed later or the subsequent - * writes will fail. */ - StorageBaseImpl_Flush(This->transactedParent); - - if (SUCCEEDED(hr)) - { - /* Destroy the old now-orphaned data. */ - for (i=0; ientries_size; i++) + hr = StorageBaseImpl_GetTransactionSig(This->transactedParent, &transactionSig, TRUE); + if (SUCCEEDED(hr)) { - TransactedDirEntry *entry = &This->entries[i]; - if (entry->inuse) + if (transactionSig != This->lastTransactionSig) { - if (entry->deleted) + ERR("file was externally modified\n"); + hr = STG_E_NOTCURRENT; + } + + if (SUCCEEDED(hr)) + { + This->lastTransactionSig = transactionSig+1; + hr = StorageBaseImpl_SetTransactionSig(This->transactedParent, This->lastTransactionSig); + } + } + else if (hr == E_NOTIMPL) + hr = S_OK; + + if (FAILED(hr)) goto end; + + /* To prevent data loss, we create the new structure in the file before we + * delete the old one, so that in case of errors the old data is intact. We + * shouldn't do this if STGC_OVERWRITE is set, but that flag should only be + * needed in the rare situation where we have just enough free disk space to + * overwrite the existing data. */ + + root_entry = &This->entries[This->base.storageDirEntry]; + + if (!root_entry->read) + goto end; + + hr = TransactedSnapshotImpl_CopyTree(This); + if (FAILED(hr)) goto end; + + if (root_entry->data.dirRootEntry == DIRENTRY_NULL) + dir_root_ref = DIRENTRY_NULL; + else + dir_root_ref = This->entries[root_entry->data.dirRootEntry].newTransactedParentEntry; + + hr = StorageBaseImpl_Flush(This->transactedParent); + + /* Update the storage to use the new data in one step. */ + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_ReadDirEntry(This->transactedParent, + root_entry->transactedParentEntry, &data); + + if (SUCCEEDED(hr)) + { + data.dirRootEntry = dir_root_ref; + data.clsid = root_entry->data.clsid; + data.ctime = root_entry->data.ctime; + data.mtime = root_entry->data.mtime; + + hr = StorageBaseImpl_WriteDirEntry(This->transactedParent, + root_entry->transactedParentEntry, &data); + } + + /* Try to flush after updating the root storage, but if the flush fails, keep + * going, on the theory that it'll either succeed later or the subsequent + * writes will fail. */ + StorageBaseImpl_Flush(This->transactedParent); + + if (SUCCEEDED(hr)) + { + /* Destroy the old now-orphaned data. */ + for (i=0; ientries_size; i++) + { + TransactedDirEntry *entry = &This->entries[i]; + if (entry->inuse) { - StorageBaseImpl_StreamSetSize(This->transactedParent, - entry->transactedParentEntry, zero); - StorageBaseImpl_DestroyDirEntry(This->transactedParent, - entry->transactedParentEntry); - memset(entry, 0, sizeof(TransactedDirEntry)); - This->firstFreeEntry = min(i, This->firstFreeEntry); - } - else if (entry->read && entry->transactedParentEntry != entry->newTransactedParentEntry) - { - if (entry->transactedParentEntry != DIRENTRY_NULL) + if (entry->deleted) + { + StorageBaseImpl_StreamSetSize(This->transactedParent, + entry->transactedParentEntry, zero); StorageBaseImpl_DestroyDirEntry(This->transactedParent, entry->transactedParentEntry); - if (entry->stream_dirty) - { - StorageBaseImpl_StreamSetSize(This->scratch, entry->stream_entry, zero); - StorageBaseImpl_DestroyDirEntry(This->scratch, entry->stream_entry); - entry->stream_dirty = FALSE; + memset(entry, 0, sizeof(TransactedDirEntry)); + This->firstFreeEntry = min(i, This->firstFreeEntry); + } + else if (entry->read && entry->transactedParentEntry != entry->newTransactedParentEntry) + { + if (entry->transactedParentEntry != DIRENTRY_NULL) + StorageBaseImpl_DestroyDirEntry(This->transactedParent, + entry->transactedParentEntry); + if (entry->stream_dirty) + { + StorageBaseImpl_StreamSetSize(This->scratch, entry->stream_entry, zero); + StorageBaseImpl_DestroyDirEntry(This->scratch, entry->stream_entry); + entry->stream_dirty = FALSE; + } + entry->dirty = FALSE; + entry->transactedParentEntry = entry->newTransactedParentEntry; } - entry->dirty = FALSE; - entry->transactedParentEntry = entry->newTransactedParentEntry; } } } - } - else - { - TransactedSnapshotImpl_DestroyTemporaryCopy(This, DIRENTRY_NULL); - } + else + { + TransactedSnapshotImpl_DestroyTemporaryCopy(This, DIRENTRY_NULL); + } - if (SUCCEEDED(hr)) - hr = StorageBaseImpl_Flush(This->transactedParent); + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_Flush(This->transactedParent); +end: + StorageBaseImpl_UnlockTransaction(This->transactedParent, TRUE); + } return hr; } @@ -5082,6 +5545,28 @@ static HRESULT TransactedSnapshotImpl_StreamLink(StorageBaseImpl *base, return S_OK; } +static HRESULT TransactedSnapshotImpl_GetTransactionSig(StorageBaseImpl *base, + ULONG* result, BOOL refresh) +{ + return E_NOTIMPL; +} + +static HRESULT TransactedSnapshotImpl_SetTransactionSig(StorageBaseImpl *base, + ULONG value) +{ + return E_NOTIMPL; +} + +static HRESULT TransactedSnapshotImpl_LockTransaction(StorageBaseImpl *base, BOOL write) +{ + return E_NOTIMPL; +} + +static HRESULT TransactedSnapshotImpl_UnlockTransaction(StorageBaseImpl *base, BOOL write) +{ + return E_NOTIMPL; +} + static const IStorageVtbl TransactedSnapshotImpl_Vtbl = { StorageBaseImpl_QueryInterface, @@ -5117,7 +5602,11 @@ static const StorageBaseImplVtbl TransactedSnapshotImpl_BaseVtbl = TransactedSnapshotImpl_StreamReadAt, TransactedSnapshotImpl_StreamWriteAt, TransactedSnapshotImpl_StreamSetSize, - TransactedSnapshotImpl_StreamLink + TransactedSnapshotImpl_StreamLink, + TransactedSnapshotImpl_GetTransactionSig, + TransactedSnapshotImpl_SetTransactionSig, + TransactedSnapshotImpl_LockTransaction, + TransactedSnapshotImpl_UnlockTransaction }; static HRESULT TransactedSnapshotImpl_Construct(StorageBaseImpl *parentStorage, @@ -5144,6 +5633,9 @@ static HRESULT TransactedSnapshotImpl_Construct(StorageBaseImpl *parentStorage, (*result)->base.openFlags = parentStorage->openFlags; + /* This cannot fail, except with E_NOTIMPL in which case we don't care */ + StorageBaseImpl_GetTransactionSig(parentStorage, &(*result)->lastTransactionSig, FALSE); + /* Create a new temporary storage to act as the scratch file. */ hr = StgCreateDocfile(NULL, STGM_READWRITE|STGM_SHARE_EXCLUSIVE|STGM_CREATE|STGM_DELETEONRELEASE, 0, &scratch); @@ -5182,16 +5674,362 @@ static HRESULT TransactedSnapshotImpl_Construct(StorageBaseImpl *parentStorage, return E_OUTOFMEMORY; } -static HRESULT Storage_ConstructTransacted(StorageBaseImpl *parentStorage, - StorageBaseImpl** result) +static void TransactedSharedImpl_Invalidate(StorageBaseImpl* This) { - static int fixme=0; - - if (parentStorage->openFlags & (STGM_NOSCRATCH|STGM_NOSNAPSHOT) && !fixme++) + if (!This->reverted) { + TRACE("Storage invalidated (stg=%p)\n", This); + + This->reverted = TRUE; + + StorageBaseImpl_DeleteAll(This); + } +} + +static void TransactedSharedImpl_Destroy( StorageBaseImpl *iface) +{ + TransactedSharedImpl* This = (TransactedSharedImpl*) iface; + + TransactedSharedImpl_Invalidate(&This->base); + IStorage_Release(&This->transactedParent->IStorage_iface); + IStorage_Release(&This->scratch->base.IStorage_iface); + HeapFree(GetProcessHeap(), 0, This); +} + +static HRESULT TransactedSharedImpl_Flush(StorageBaseImpl* iface) +{ + /* We only need to flush when committing. */ + return S_OK; +} + +static HRESULT TransactedSharedImpl_GetFilename(StorageBaseImpl* iface, LPWSTR *result) +{ + TransactedSharedImpl* This = (TransactedSharedImpl*) iface; + + return StorageBaseImpl_GetFilename(This->transactedParent, result); +} + +static HRESULT TransactedSharedImpl_CreateDirEntry(StorageBaseImpl *base, + const DirEntry *newData, DirRef *index) +{ + TransactedSharedImpl* This = (TransactedSharedImpl*) base; + + return StorageBaseImpl_CreateDirEntry(&This->scratch->base, + newData, index); +} + +static HRESULT TransactedSharedImpl_WriteDirEntry(StorageBaseImpl *base, + DirRef index, const DirEntry *data) +{ + TransactedSharedImpl* This = (TransactedSharedImpl*) base; + + return StorageBaseImpl_WriteDirEntry(&This->scratch->base, + index, data); +} + +static HRESULT TransactedSharedImpl_ReadDirEntry(StorageBaseImpl *base, + DirRef index, DirEntry *data) +{ + TransactedSharedImpl* This = (TransactedSharedImpl*) base; + + return StorageBaseImpl_ReadDirEntry(&This->scratch->base, + index, data); +} + +static HRESULT TransactedSharedImpl_DestroyDirEntry(StorageBaseImpl *base, + DirRef index) +{ + TransactedSharedImpl* This = (TransactedSharedImpl*) base; + + return StorageBaseImpl_DestroyDirEntry(&This->scratch->base, + index); +} + +static HRESULT TransactedSharedImpl_StreamReadAt(StorageBaseImpl *base, + DirRef index, ULARGE_INTEGER offset, ULONG size, void *buffer, ULONG *bytesRead) +{ + TransactedSharedImpl* This = (TransactedSharedImpl*) base; + + return StorageBaseImpl_StreamReadAt(&This->scratch->base, + index, offset, size, buffer, bytesRead); +} + +static HRESULT TransactedSharedImpl_StreamWriteAt(StorageBaseImpl *base, + DirRef index, ULARGE_INTEGER offset, ULONG size, const void *buffer, ULONG *bytesWritten) +{ + TransactedSharedImpl* This = (TransactedSharedImpl*) base; + + return StorageBaseImpl_StreamWriteAt(&This->scratch->base, + index, offset, size, buffer, bytesWritten); +} + +static HRESULT TransactedSharedImpl_StreamSetSize(StorageBaseImpl *base, + DirRef index, ULARGE_INTEGER newsize) +{ + TransactedSharedImpl* This = (TransactedSharedImpl*) base; + + return StorageBaseImpl_StreamSetSize(&This->scratch->base, + index, newsize); +} + +static HRESULT TransactedSharedImpl_StreamLink(StorageBaseImpl *base, + DirRef dst, DirRef src) +{ + TransactedSharedImpl* This = (TransactedSharedImpl*) base; + + return StorageBaseImpl_StreamLink(&This->scratch->base, + dst, src); +} + +static HRESULT TransactedSharedImpl_GetTransactionSig(StorageBaseImpl *base, + ULONG* result, BOOL refresh) +{ + return E_NOTIMPL; +} + +static HRESULT TransactedSharedImpl_SetTransactionSig(StorageBaseImpl *base, + ULONG value) +{ + return E_NOTIMPL; +} + +static HRESULT TransactedSharedImpl_LockTransaction(StorageBaseImpl *base, BOOL write) +{ + return E_NOTIMPL; +} + +static HRESULT TransactedSharedImpl_UnlockTransaction(StorageBaseImpl *base, BOOL write) +{ + return E_NOTIMPL; +} + +static HRESULT WINAPI TransactedSharedImpl_Commit( + IStorage* iface, + DWORD grfCommitFlags) /* [in] */ +{ + TransactedSharedImpl* This = (TransactedSharedImpl*)impl_from_IStorage(iface); + DirRef new_storage_ref, prev_storage_ref; + DirEntry src_data, dst_data; + HRESULT hr; + ULONG transactionSig; + + TRACE("(%p,%x)\n", iface, grfCommitFlags); + + /* Cannot commit a read-only transacted storage */ + if ( STGM_ACCESS_MODE( This->base.openFlags ) == STGM_READ ) + return STG_E_ACCESSDENIED; + + hr = StorageBaseImpl_LockTransaction(This->transactedParent, TRUE); + if (hr == E_NOTIMPL) hr = S_OK; + if (SUCCEEDED(hr)) + { + hr = StorageBaseImpl_GetTransactionSig(This->transactedParent, &transactionSig, TRUE); + if (SUCCEEDED(hr)) + { + if ((grfCommitFlags & STGC_ONLYIFCURRENT) && transactionSig != This->lastTransactionSig) + hr = STG_E_NOTCURRENT; + + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_SetTransactionSig(This->transactedParent, transactionSig+1); + } + else if (hr == E_NOTIMPL) + hr = S_OK; + + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_ReadDirEntry(&This->scratch->base, This->scratch->base.storageDirEntry, &src_data); + + /* FIXME: If we're current, we should be able to copy only the changes in scratch. */ + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_DupStorageTree(This->transactedParent, &new_storage_ref, &This->scratch->base, src_data.dirRootEntry); + + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_Flush(This->transactedParent); + + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_ReadDirEntry(This->transactedParent, This->transactedParent->storageDirEntry, &dst_data); + + if (SUCCEEDED(hr)) + { + prev_storage_ref = dst_data.dirRootEntry; + dst_data.dirRootEntry = new_storage_ref; + dst_data.clsid = src_data.clsid; + dst_data.ctime = src_data.ctime; + dst_data.mtime = src_data.mtime; + hr = StorageBaseImpl_WriteDirEntry(This->transactedParent, This->transactedParent->storageDirEntry, &dst_data); + } + + if (SUCCEEDED(hr)) + { + /* Try to flush after updating the root storage, but if the flush fails, keep + * going, on the theory that it'll either succeed later or the subsequent + * writes will fail. */ + StorageBaseImpl_Flush(This->transactedParent); + + hr = StorageBaseImpl_DeleteStorageTree(This->transactedParent, prev_storage_ref, TRUE); + } + + if (SUCCEEDED(hr)) + hr = StorageBaseImpl_Flush(This->transactedParent); + + StorageBaseImpl_UnlockTransaction(This->transactedParent, TRUE); + + if (SUCCEEDED(hr)) + hr = IStorage_Commit(&This->scratch->base.IStorage_iface, STGC_DEFAULT); + + if (SUCCEEDED(hr)) + { + This->lastTransactionSig = transactionSig+1; + } + } + + return hr; +} + +static HRESULT WINAPI TransactedSharedImpl_Revert( + IStorage* iface) +{ + TransactedSharedImpl* This = (TransactedSharedImpl*)impl_from_IStorage(iface); + + TRACE("(%p)\n", iface); + + /* Destroy the open objects. */ + StorageBaseImpl_DeleteAll(&This->base); + + return IStorage_Revert(&This->scratch->base.IStorage_iface); +} + +static const IStorageVtbl TransactedSharedImpl_Vtbl = +{ + StorageBaseImpl_QueryInterface, + StorageBaseImpl_AddRef, + StorageBaseImpl_Release, + StorageBaseImpl_CreateStream, + StorageBaseImpl_OpenStream, + StorageBaseImpl_CreateStorage, + StorageBaseImpl_OpenStorage, + StorageBaseImpl_CopyTo, + StorageBaseImpl_MoveElementTo, + TransactedSharedImpl_Commit, + TransactedSharedImpl_Revert, + StorageBaseImpl_EnumElements, + StorageBaseImpl_DestroyElement, + StorageBaseImpl_RenameElement, + StorageBaseImpl_SetElementTimes, + StorageBaseImpl_SetClass, + StorageBaseImpl_SetStateBits, + StorageBaseImpl_Stat +}; + +static const StorageBaseImplVtbl TransactedSharedImpl_BaseVtbl = +{ + TransactedSharedImpl_Destroy, + TransactedSharedImpl_Invalidate, + TransactedSharedImpl_Flush, + TransactedSharedImpl_GetFilename, + TransactedSharedImpl_CreateDirEntry, + TransactedSharedImpl_WriteDirEntry, + TransactedSharedImpl_ReadDirEntry, + TransactedSharedImpl_DestroyDirEntry, + TransactedSharedImpl_StreamReadAt, + TransactedSharedImpl_StreamWriteAt, + TransactedSharedImpl_StreamSetSize, + TransactedSharedImpl_StreamLink, + TransactedSharedImpl_GetTransactionSig, + TransactedSharedImpl_SetTransactionSig, + TransactedSharedImpl_LockTransaction, + TransactedSharedImpl_UnlockTransaction +}; + +static HRESULT TransactedSharedImpl_Construct(StorageBaseImpl *parentStorage, + TransactedSharedImpl** result) +{ + HRESULT hr; + + *result = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(TransactedSharedImpl)); + if (*result) + { + IStorage *scratch; + + (*result)->base.IStorage_iface.lpVtbl = &TransactedSharedImpl_Vtbl; + + /* This is OK because the property set storage functions use the IStorage functions. */ + (*result)->base.IPropertySetStorage_iface.lpVtbl = parentStorage->IPropertySetStorage_iface.lpVtbl; + (*result)->base.baseVtbl = &TransactedSharedImpl_BaseVtbl; + + list_init(&(*result)->base.strmHead); + + list_init(&(*result)->base.storageHead); + + (*result)->base.ref = 1; + + (*result)->base.openFlags = parentStorage->openFlags; + + hr = StorageBaseImpl_LockTransaction(parentStorage, FALSE); + + if (SUCCEEDED(hr)) + { + STGOPTIONS stgo; + + /* This cannot fail, except with E_NOTIMPL in which case we don't care */ + StorageBaseImpl_GetTransactionSig(parentStorage, &(*result)->lastTransactionSig, FALSE); + + stgo.usVersion = 1; + stgo.reserved = 0; + stgo.ulSectorSize = 4096; + stgo.pwcsTemplateFile = NULL; + + /* Create a new temporary storage to act as the scratch file. */ + hr = StgCreateStorageEx(NULL, STGM_READWRITE|STGM_SHARE_EXCLUSIVE|STGM_CREATE|STGM_DELETEONRELEASE|STGM_TRANSACTED, + STGFMT_DOCFILE, 0, &stgo, NULL, &IID_IStorage, (void**)&scratch); + (*result)->scratch = (TransactedSnapshotImpl*)impl_from_IStorage(scratch); + + if (SUCCEEDED(hr)) + { + hr = StorageBaseImpl_CopyStorageTree(&(*result)->scratch->base, (*result)->scratch->base.storageDirEntry, + parentStorage, parentStorage->storageDirEntry); + + if (SUCCEEDED(hr)) + { + hr = IStorage_Commit(scratch, STGC_DEFAULT); + + (*result)->base.storageDirEntry = (*result)->scratch->base.storageDirEntry; + (*result)->transactedParent = parentStorage; + } + + if (FAILED(hr)) + IStorage_Release(scratch); + } + + StorageBaseImpl_UnlockTransaction(parentStorage, FALSE); + } + + if (FAILED(hr)) HeapFree(GetProcessHeap(), 0, *result); + + return hr; + } + else + return E_OUTOFMEMORY; +} + +static HRESULT Storage_ConstructTransacted(StorageBaseImpl *parentStorage, + BOOL toplevel, StorageBaseImpl** result) +{ + static int fixme_flags=STGM_NOSCRATCH|STGM_NOSNAPSHOT; + + if (parentStorage->openFlags & fixme_flags) + { + fixme_flags &= ~parentStorage->openFlags; FIXME("Unimplemented flags %x\n", parentStorage->openFlags); } + if (toplevel && !(parentStorage->openFlags & STGM_NOSNAPSHOT) && + STGM_SHARE_MODE(parentStorage->openFlags) != STGM_SHARE_DENY_WRITE && + STGM_SHARE_MODE(parentStorage->openFlags) != STGM_SHARE_EXCLUSIVE) + { + /* Need to create a temp file for the snapshot */ + return TransactedSharedImpl_Construct(parentStorage, (TransactedSharedImpl**)result); + } + return TransactedSnapshotImpl_Construct(parentStorage, (TransactedSnapshotImpl**)result); } @@ -5215,7 +6053,7 @@ static HRESULT Storage_Construct( if (openFlags & STGM_TRANSACTED) { - hr = Storage_ConstructTransacted(&newStorage->base, &newTransactedStorage); + hr = Storage_ConstructTransacted(&newStorage->base, TRUE, &newTransactedStorage); if (FAILED(hr)) IStorage_Release(&newStorage->base.IStorage_iface); else @@ -5341,6 +6179,28 @@ static HRESULT StorageInternalImpl_StreamLink(StorageBaseImpl *base, dst, src); } +static HRESULT StorageInternalImpl_GetTransactionSig(StorageBaseImpl *base, + ULONG* result, BOOL refresh) +{ + return E_NOTIMPL; +} + +static HRESULT StorageInternalImpl_SetTransactionSig(StorageBaseImpl *base, + ULONG value) +{ + return E_NOTIMPL; +} + +static HRESULT StorageInternalImpl_LockTransaction(StorageBaseImpl *base, BOOL write) +{ + return E_NOTIMPL; +} + +static HRESULT StorageInternalImpl_UnlockTransaction(StorageBaseImpl *base, BOOL write) +{ + return E_NOTIMPL; +} + /****************************************************************************** ** ** Storage32InternalImpl_Commit @@ -5691,7 +6551,11 @@ static const StorageBaseImplVtbl StorageInternalImpl_BaseVtbl = StorageInternalImpl_StreamReadAt, StorageInternalImpl_StreamWriteAt, StorageInternalImpl_StreamSetSize, - StorageInternalImpl_StreamLink + StorageInternalImpl_StreamLink, + StorageInternalImpl_GetTransactionSig, + StorageInternalImpl_SetTransactionSig, + StorageInternalImpl_LockTransaction, + StorageInternalImpl_UnlockTransaction }; /****************************************************************************** @@ -6145,8 +7009,8 @@ HRESULT BlockChainStream_ReadAt(BlockChainStream* This, void* buffer, ULONG* bytesRead) { - ULONG blockNoInSequence = offset.u.LowPart / This->parentStorage->bigBlockSize; - ULONG offsetInBlock = offset.u.LowPart % This->parentStorage->bigBlockSize; + ULONG blockNoInSequence = offset.QuadPart / This->parentStorage->bigBlockSize; + ULONG offsetInBlock = offset.QuadPart % This->parentStorage->bigBlockSize; ULONG bytesToReadInBuffer; ULONG blockIndex; BYTE* bufferWalker; @@ -6193,8 +7057,7 @@ HRESULT BlockChainStream_ReadAt(BlockChainStream* This, if (!cachedBlock) { /* Not in cache, and we're going to read past the end of the block. */ - ulOffset.u.HighPart = 0; - ulOffset.u.LowPart = StorageImpl_GetBigBlockOffset(This->parentStorage, blockIndex) + + ulOffset.QuadPart = StorageImpl_GetBigBlockOffset(This->parentStorage, blockIndex) + offsetInBlock; StorageImpl_ReadAt(This->parentStorage, @@ -6243,8 +7106,8 @@ HRESULT BlockChainStream_WriteAt(BlockChainStream* This, const void* buffer, ULONG* bytesWritten) { - ULONG blockNoInSequence = offset.u.LowPart / This->parentStorage->bigBlockSize; - ULONG offsetInBlock = offset.u.LowPart % This->parentStorage->bigBlockSize; + ULONG blockNoInSequence = offset.QuadPart / This->parentStorage->bigBlockSize; + ULONG offsetInBlock = offset.QuadPart % This->parentStorage->bigBlockSize; ULONG bytesToWrite; ULONG blockIndex; const BYTE* bufferWalker; @@ -6278,8 +7141,7 @@ HRESULT BlockChainStream_WriteAt(BlockChainStream* This, if (!cachedBlock) { /* Not in cache, and we're going to write past the end of the block. */ - ulOffset.u.HighPart = 0; - ulOffset.u.LowPart = StorageImpl_GetBigBlockOffset(This->parentStorage, blockIndex) + + ulOffset.QuadPart = StorageImpl_GetBigBlockOffset(This->parentStorage, blockIndex) + offsetInBlock; StorageImpl_WriteAt(This->parentStorage, @@ -6331,9 +7193,9 @@ static BOOL BlockChainStream_Shrink(BlockChainStream* This, /* * Figure out how many blocks are needed to contain the new size */ - numBlocks = newSize.u.LowPart / This->parentStorage->bigBlockSize; + numBlocks = newSize.QuadPart / This->parentStorage->bigBlockSize; - if ((newSize.u.LowPart % This->parentStorage->bigBlockSize) != 0) + if ((newSize.QuadPart % This->parentStorage->bigBlockSize) != 0) numBlocks++; if (numBlocks) @@ -6462,9 +7324,9 @@ static BOOL BlockChainStream_Enlarge(BlockChainStream* This, /* * Figure out how many blocks are needed to contain this stream */ - newNumBlocks = newSize.u.LowPart / This->parentStorage->bigBlockSize; + newNumBlocks = newSize.QuadPart / This->parentStorage->bigBlockSize; - if ((newSize.u.LowPart % This->parentStorage->bigBlockSize) != 0) + if ((newSize.QuadPart % This->parentStorage->bigBlockSize) != 0) newNumBlocks++; /* @@ -6539,10 +7401,10 @@ BOOL BlockChainStream_SetSize( { ULARGE_INTEGER size = BlockChainStream_GetSize(This); - if (newSize.u.LowPart == size.u.LowPart) + if (newSize.QuadPart == size.QuadPart) return TRUE; - if (newSize.u.LowPart < size.u.LowPart) + if (newSize.QuadPart < size.QuadPart) { BlockChainStream_Shrink(This, newSize); } @@ -6584,10 +7446,8 @@ static ULARGE_INTEGER BlockChainStream_GetSize(BlockChainStream* This) * size of them */ ULARGE_INTEGER result; - result.u.HighPart = 0; - - result.u.LowPart = - BlockChainStream_GetCount(This) * + result.QuadPart = + (ULONGLONG)BlockChainStream_GetCount(This) * This->parentStorage->bigBlockSize; return result; @@ -6672,8 +7532,7 @@ static HRESULT SmallBlockChainStream_GetNextBlockInChain( *nextBlockInChain = BLOCK_END_OF_CHAIN; - offsetOfBlockInDepot.u.HighPart = 0; - offsetOfBlockInDepot.u.LowPart = blockIndex * sizeof(ULONG); + offsetOfBlockInDepot.QuadPart = (ULONGLONG)blockIndex * sizeof(ULONG); /* * Read those bytes in the buffer from the small block file. @@ -6714,8 +7573,7 @@ static void SmallBlockChainStream_SetNextBlockInChain( DWORD buffer; ULONG bytesWritten; - offsetOfBlockInDepot.u.HighPart = 0; - offsetOfBlockInDepot.u.LowPart = blockIndex * sizeof(ULONG); + offsetOfBlockInDepot.QuadPart = (ULONGLONG)blockIndex * sizeof(ULONG); StorageUtl_WriteDWord((BYTE *)&buffer, 0, nextBlock); @@ -6770,7 +7628,7 @@ static ULONG SmallBlockChainStream_GetNextFreeBlock( */ while (nextBlockIndex != BLOCK_UNUSED) { - offsetOfBlockInDepot.u.LowPart = blockIndex * sizeof(ULONG); + offsetOfBlockInDepot.QuadPart = (ULONGLONG)blockIndex * sizeof(ULONG); res = BlockChainStream_ReadAt( This->parentStorage->smallBlockDepotChain, @@ -6798,14 +7656,14 @@ static ULONG SmallBlockChainStream_GetNextFreeBlock( ULARGE_INTEGER newSize, offset; ULONG bytesWritten; - newSize.QuadPart = (count + 1) * This->parentStorage->bigBlockSize; + newSize.QuadPart = (ULONGLONG)(count + 1) * This->parentStorage->bigBlockSize; BlockChainStream_Enlarge(This->parentStorage->smallBlockDepotChain, newSize); /* * Initialize all the small blocks to free */ memset(smallBlockDepot, BLOCK_UNUSED, This->parentStorage->bigBlockSize); - offset.QuadPart = count * This->parentStorage->bigBlockSize; + offset.QuadPart = (ULONGLONG)count * This->parentStorage->bigBlockSize; BlockChainStream_WriteAt(This->parentStorage->smallBlockDepotChain, offset, This->parentStorage->bigBlockSize, smallBlockDepot, &bytesWritten); @@ -6823,7 +7681,7 @@ static ULONG SmallBlockChainStream_GetNextFreeBlock( */ blocksRequired = (blockIndex / smallBlocksPerBigBlock) + 1; - size_required.QuadPart = blocksRequired * This->parentStorage->bigBlockSize; + size_required.QuadPart = (ULONGLONG)blocksRequired * This->parentStorage->bigBlockSize; old_size = BlockChainStream_GetSize(This->parentStorage->smallBlockRootChain); @@ -6917,11 +7775,10 @@ HRESULT SmallBlockChainStream_ReadAt( /* * Calculate the offset of the small block in the small block file. */ - offsetInBigBlockFile.u.HighPart = 0; - offsetInBigBlockFile.u.LowPart = - blockIndex * This->parentStorage->smallBlockSize; + offsetInBigBlockFile.QuadPart = + (ULONGLONG)blockIndex * This->parentStorage->smallBlockSize; - offsetInBigBlockFile.u.LowPart += offsetInBlock; + offsetInBigBlockFile.QuadPart += offsetInBlock; /* * Read those bytes in the buffer from the small block file. @@ -7013,11 +7870,10 @@ HRESULT SmallBlockChainStream_WriteAt( /* * Calculate the offset of the small block in the small block file. */ - offsetInBigBlockFile.u.HighPart = 0; - offsetInBigBlockFile.u.LowPart = - blockIndex * This->parentStorage->smallBlockSize; + offsetInBigBlockFile.QuadPart = + (ULONGLONG)blockIndex * This->parentStorage->smallBlockSize; - offsetInBigBlockFile.u.LowPart += offsetInBlock; + offsetInBigBlockFile.QuadPart += offsetInBlock; /* * Write those bytes in the buffer to the small block file. @@ -7034,9 +7890,9 @@ HRESULT SmallBlockChainStream_WriteAt( /* * Step to the next big block. */ - if(FAILED(SmallBlockChainStream_GetNextBlockInChain(This, blockIndex, - &blockIndex))) - return FALSE; + res = SmallBlockChainStream_GetNextBlockInChain(This, blockIndex, &blockIndex); + if (FAILED(res)) + return res; bufferWalker += bytesWrittenToBigBlockFile; size -= bytesWrittenToBigBlockFile; *bytesWritten += bytesWrittenToBigBlockFile; @@ -7378,7 +8234,7 @@ static HRESULT create_storagefile( /* * Interpret the STGM value grfMode */ - shareMode = FILE_SHARE_READ | FILE_SHARE_WRITE; + shareMode = GetShareModeFromSTGM(grfMode); accessMode = GetAccessModeFromSTGM(grfMode); if (grfMode & STGM_DELETEONRELEASE) @@ -7386,13 +8242,6 @@ static HRESULT create_storagefile( else fileAttributes = FILE_ATTRIBUTE_NORMAL | FILE_FLAG_RANDOM_ACCESS; - if (STGM_SHARE_MODE(grfMode) && !(grfMode & STGM_SHARE_DENY_NONE)) - { - static int fixme; - if (!fixme++) - FIXME("Storage share mode not implemented.\n"); - } - *ppstgOpen = 0; hFile = CreateFileW(pwcsName, @@ -7633,13 +8482,6 @@ HRESULT WINAPI StgOpenStorage( return STG_E_INVALIDFLAG; grfMode &= ~0xf0; /* remove the existing sharing mode */ grfMode |= STGM_SHARE_DENY_NONE; - - /* STGM_PRIORITY stops other IStorage objects on the same file from - * committing until the STGM_PRIORITY IStorage is closed. it also - * stops non-transacted mode StgOpenStorage calls with write access from - * succeeding. obviously, both of these cannot be achieved through just - * file share flags */ - FIXME("STGM_PRIORITY mode not implemented correctly\n"); } /* @@ -8074,6 +8916,10 @@ static HRESULT validateSTGM(DWORD stgm) case STGM_SHARE_DENY_WRITE: case STGM_SHARE_EXCLUSIVE: break; + case 0: + if (!(stgm & STGM_TRANSACTED)) + return E_FAIL; + break; default: return E_FAIL; } @@ -8129,14 +8975,16 @@ static DWORD GetShareModeFromSTGM(DWORD stgm) { switch (STGM_SHARE_MODE(stgm)) { + case 0: + assert(stgm & STGM_TRANSACTED); + /* fall-through */ case STGM_SHARE_DENY_NONE: return FILE_SHARE_READ | FILE_SHARE_WRITE; case STGM_SHARE_DENY_READ: return FILE_SHARE_WRITE; case STGM_SHARE_DENY_WRITE: - return FILE_SHARE_READ; case STGM_SHARE_EXCLUSIVE: - return 0; + return FILE_SHARE_READ; } ERR("Invalid share mode!\n"); assert(0); diff --git a/dll/win32/ole32/storage32.h b/dll/win32/ole32/storage32.h index 939a2e08f99..c6b34f0efbc 100644 --- a/dll/win32/ole32/storage32.h +++ b/dll/win32/ole32/storage32.h @@ -42,6 +42,7 @@ static const ULONG OFFSET_SMALLBLOCKSIZEBITS = 0x00000020; static const ULONG OFFSET_DIRSECTORCOUNT = 0x00000028; static const ULONG OFFSET_BBDEPOTCOUNT = 0x0000002C; static const ULONG OFFSET_ROOTSTARTBLOCK = 0x00000030; +static const ULONG OFFSET_TRANSACTIONSIG = 0x00000034; static const ULONG OFFSET_SMALLBLOCKLIMIT = 0x00000038; static const ULONG OFFSET_SBDEPOTSTART = 0x0000003C; static const ULONG OFFSET_SBDEPOTCOUNT = 0x00000040; @@ -61,6 +62,7 @@ static const ULONG OFFSET_PS_MTIMELOW = 0x0000006C; static const ULONG OFFSET_PS_MTIMEHIGH = 0x00000070; static const ULONG OFFSET_PS_STARTBLOCK = 0x00000074; static const ULONG OFFSET_PS_SIZE = 0x00000078; +static const ULONG OFFSET_PS_SIZE_HIGH = 0x0000007C; static const WORD DEF_BIG_BLOCK_SIZE_BITS = 0x0009; static const WORD MIN_BIG_BLOCK_SIZE_BITS = 0x0009; static const WORD MAX_BIG_BLOCK_SIZE_BITS = 0x000c; @@ -147,6 +149,8 @@ struct DirEntry HRESULT FileLockBytesImpl_Construct(HANDLE hFile, DWORD openFlags, LPCWSTR pwcsName, ILockBytes **pLockBytes) DECLSPEC_HIDDEN; +HRESULT FileLockBytesImpl_LockRegionSync(ILockBytes* iface, ULARGE_INTEGER libOffset, ULARGE_INTEGER cb) DECLSPEC_HIDDEN; + /************************************************************************* * Ole Convert support */ @@ -237,6 +241,10 @@ struct StorageBaseImplVtbl { HRESULT (*StreamWriteAt)(StorageBaseImpl*,DirRef,ULARGE_INTEGER,ULONG,const void*,ULONG*); HRESULT (*StreamSetSize)(StorageBaseImpl*,DirRef,ULARGE_INTEGER); HRESULT (*StreamLink)(StorageBaseImpl*,DirRef,DirRef); + HRESULT (*GetTransactionSig)(StorageBaseImpl*,ULONG*,BOOL); + HRESULT (*SetTransactionSig)(StorageBaseImpl*,ULONG); + HRESULT (*LockTransaction)(StorageBaseImpl*,BOOL); + HRESULT (*UnlockTransaction)(StorageBaseImpl*,BOOL); }; static inline void StorageBaseImpl_Destroy(StorageBaseImpl *This) @@ -314,6 +322,28 @@ static inline HRESULT StorageBaseImpl_StreamLink(StorageBaseImpl *This, return This->baseVtbl->StreamLink(This, dst, src); } +static inline HRESULT StorageBaseImpl_GetTransactionSig(StorageBaseImpl *This, + ULONG* result, BOOL refresh) +{ + return This->baseVtbl->GetTransactionSig(This, result, refresh); +} + +static inline HRESULT StorageBaseImpl_SetTransactionSig(StorageBaseImpl *This, + ULONG value) +{ + return This->baseVtbl->SetTransactionSig(This, value); +} + +static inline HRESULT StorageBaseImpl_LockTransaction(StorageBaseImpl *This, BOOL write) +{ + return This->baseVtbl->LockTransaction(This, write); +} + +static inline HRESULT StorageBaseImpl_UnlockTransaction(StorageBaseImpl *This, BOOL write) +{ + return This->baseVtbl->UnlockTransaction(This, write); +} + /**************************************************************************** * StorageBaseImpl stream list handlers */ @@ -350,6 +380,7 @@ struct StorageImpl ULONG extBigBlockDepotLocationsSize; ULONG extBigBlockDepotCount; ULONG bigBlockDepotStart[COUNT_BBDEPOTINHEADER]; + ULONG transactionSig; ULONG extBlockDepotCached[MAX_BIG_BLOCK_SIZE / 4]; ULONG indexExtBlockDepotCached; @@ -373,6 +404,8 @@ struct StorageImpl UINT blockChainToEvict; ILockBytes* lockBytes; + + ULONG locked_bytes[8]; }; HRESULT StorageImpl_ReadRawDirEntry( @@ -459,6 +492,54 @@ StgStreamImpl* StgStreamImpl_Construct( DirRef dirEntry) DECLSPEC_HIDDEN; +/* Range lock constants. + * + * The storage format reserves the region from 0x7fffff00-0x7fffffff for + * locking and synchronization. Unfortunately, the spec doesn't say which bytes + * within that range are used, and for what. These are guesses based on testing. + * In particular, ends of ranges may be wrong. + + 0x0 through 0x57: Unknown. Causes read-only exclusive opens to fail. + 0x58 through 0x6b: Priority mode. + 0x6c through 0x7f: No snapshot mode. + 0x80: Commit lock. + 0x81 through 0x91: Priority mode, again. Not sure why it uses two regions. + 0x92: Lock-checking lock. Held while opening so ranges can be tested without + causing spurious failures if others try to grab or test those ranges at the + same time. + 0x93 through 0xa6: Read mode. + 0xa7 through 0xba: Write mode. + 0xbb through 0xce: Deny read. + 0xcf through 0xe2: Deny write. + 0xe2 through 0xff: Unknown. Causes read-only exclusive opens to fail. +*/ + +#define RANGELOCK_UNK1_FIRST 0x7fffff00 +#define RANGELOCK_UNK1_LAST 0x7fffff57 +#define RANGELOCK_PRIORITY1_FIRST 0x7fffff58 +#define RANGELOCK_PRIORITY1_LAST 0x7fffff6b +#define RANGELOCK_NOSNAPSHOT_FIRST 0x7fffff6c +#define RANGELOCK_NOSNAPSHOT_LAST 0x7fffff7f +#define RANGELOCK_COMMIT 0x7fffff80 +#define RANGELOCK_PRIORITY2_FIRST 0x7fffff81 +#define RANGELOCK_PRIORITY2_LAST 0x7fffff91 +#define RANGELOCK_CHECKLOCKS 0x7fffff92 +#define RANGELOCK_READ_FIRST 0x7fffff93 +#define RANGELOCK_READ_LAST 0x7fffffa6 +#define RANGELOCK_WRITE_FIRST 0x7fffffa7 +#define RANGELOCK_WRITE_LAST 0x7fffffba +#define RANGELOCK_DENY_READ_FIRST 0x7fffffbb +#define RANGELOCK_DENY_READ_LAST 0x7fffffce +#define RANGELOCK_DENY_WRITE_FIRST 0x7fffffcf +#define RANGELOCK_DENY_WRITE_LAST 0x7fffffe2 +#define RANGELOCK_UNK2_FIRST 0x7fffffe3 +#define RANGELOCK_UNK2_LAST 0x7fffffff +#define RANGELOCK_TRANSACTION_FIRST RANGELOCK_COMMIT +#define RANGELOCK_TRANSACTION_LAST RANGELOCK_CHECKLOCKS +#define RANGELOCK_FIRST RANGELOCK_UNK1_FIRST +#define RANGELOCK_LAST RANGELOCK_UNK2_LAST + + /****************************************************************************** * Endian conversion macros */ diff --git a/dll/win32/oleacc/CMakeLists.txt b/dll/win32/oleacc/CMakeLists.txt index 173ecd55882..a2c10078b9d 100644 --- a/dll/win32/oleacc/CMakeLists.txt +++ b/dll/win32/oleacc/CMakeLists.txt @@ -4,9 +4,11 @@ include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) spec2def(oleacc.dll oleacc.spec ADD_IMPORTLIB) list(APPEND SOURCE + client.c main.c - ${CMAKE_CURRENT_BINARY_DIR}/oleacc_stubs.c - ${CMAKE_CURRENT_BINARY_DIR}/oleacc.def) + propservice.c + window.c + oleacc_private.h) add_typelib(oleacc_classes.idl) @@ -16,8 +18,15 @@ list(APPEND oleacc_rc_deps set_source_files_properties(oleacc.rc PROPERTIES OBJECT_DEPENDS "${oleacc_rc_deps}") -add_library(oleacc SHARED ${SOURCE} oleacc.rc) +add_library(oleacc SHARED + ${SOURCE} + oleacc.rc + ${CMAKE_CURRENT_BINARY_DIR}/oleacc_stubs.c + ${CMAKE_CURRENT_BINARY_DIR}/oleacc.def) + +add_dependencies(oleacc stdole2) set_module_type(oleacc win32dll) -target_link_libraries(oleacc wine) -add_importlibs(oleacc user32 msvcrt kernel32 ntdll) +target_link_libraries(oleacc uuid wine) +add_importlibs(oleacc oleaut32 ole32 user32 msvcrt kernel32 ntdll) +add_pch(oleacc oleacc_private.h SOURCE) add_cd_file(TARGET oleacc DESTINATION reactos/system32 FOR all) diff --git a/dll/win32/oleacc/client.c b/dll/win32/oleacc/client.c new file mode 100644 index 00000000000..0629feb4434 --- /dev/null +++ b/dll/win32/oleacc/client.c @@ -0,0 +1,509 @@ +/* + * Copyright 2014 Piotr 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 "oleacc_private.h" + +typedef struct { + IAccessible IAccessible_iface; + IOleWindow IOleWindow_iface; + + LONG ref; + + HWND hwnd; +} Client; + +static inline Client* impl_from_Client(IAccessible *iface) +{ + return CONTAINING_RECORD(iface, Client, IAccessible_iface); +} + +static HRESULT WINAPI Client_QueryInterface(IAccessible *iface, REFIID riid, void **ppv) +{ + Client *This = impl_from_Client(iface); + + TRACE("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); + + if(IsEqualIID(riid, &IID_IAccessible) || + IsEqualIID(riid, &IID_IDispatch) || + IsEqualIID(riid, &IID_IUnknown)) { + *ppv = iface; + }else if(IsEqualIID(riid, &IID_IOleWindow)) { + *ppv = &This->IOleWindow_iface; + }else { + WARN("no interface: %s\n", debugstr_guid(riid)); + *ppv = NULL; + return E_NOINTERFACE; + } + + IAccessible_AddRef(iface); + return S_OK; +} + +static ULONG WINAPI Client_AddRef(IAccessible *iface) +{ + Client *This = impl_from_Client(iface); + ULONG ref = InterlockedIncrement(&This->ref); + + TRACE("(%p) ref = %u\n", This, ref); + return ref; +} + +static ULONG WINAPI Client_Release(IAccessible *iface) +{ + Client *This = impl_from_Client(iface); + ULONG ref = InterlockedDecrement(&This->ref); + + TRACE("(%p) ref = %u\n", This, ref); + + if(!ref) + heap_free(This); + return ref; +} + +static HRESULT WINAPI Client_GetTypeInfoCount(IAccessible *iface, UINT *pctinfo) +{ + Client *This = impl_from_Client(iface); + FIXME("(%p)->(%p)\n", This, pctinfo); + return E_NOTIMPL; +} + +static HRESULT WINAPI Client_GetTypeInfo(IAccessible *iface, + UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo) +{ + Client *This = impl_from_Client(iface); + FIXME("(%p)->(%u %x %p)\n", This, iTInfo, lcid, ppTInfo); + return E_NOTIMPL; +} + +static HRESULT WINAPI Client_GetIDsOfNames(IAccessible *iface, REFIID riid, + LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId) +{ + Client *This = impl_from_Client(iface); + FIXME("(%p)->(%s %p %u %x %p)\n", This, debugstr_guid(riid), + rgszNames, cNames, lcid, rgDispId); + return E_NOTIMPL; +} + +static HRESULT WINAPI Client_Invoke(IAccessible *iface, DISPID dispIdMember, + REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, + VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr) +{ + Client *This = impl_from_Client(iface); + FIXME("(%p)->(%x %s %x %x %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid), + lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); + return E_NOTIMPL; +} + +static HRESULT WINAPI Client_get_accParent(IAccessible *iface, IDispatch **ppdispParent) +{ + Client *This = impl_from_Client(iface); + + TRACE("(%p)->(%p)\n", This, ppdispParent); + + return AccessibleObjectFromWindow(This->hwnd, OBJID_WINDOW, + &IID_IDispatch, (void**)ppdispParent); +} + +static HRESULT WINAPI Client_get_accChildCount(IAccessible *iface, LONG *pcountChildren) +{ + Client *This = impl_from_Client(iface); + HWND cur; + + TRACE("(%p)->(%p)\n", This, pcountChildren); + + *pcountChildren = 0; + for(cur = GetWindow(This->hwnd, GW_CHILD); cur; cur = GetWindow(cur, GW_HWNDNEXT)) + (*pcountChildren)++; + + return S_OK; +} + +static HRESULT WINAPI Client_get_accChild(IAccessible *iface, + VARIANT varChildID, IDispatch **ppdispChild) +{ + Client *This = impl_from_Client(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_variant(&varChildID), ppdispChild); + return E_NOTIMPL; +} + +static HRESULT WINAPI Client_get_accName(IAccessible *iface, VARIANT varID, BSTR *pszName) +{ + Client *This = impl_from_Client(iface); + WCHAR name[1024]; + UINT i, len; + + TRACE("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pszName); + + *pszName = NULL; + if(convert_child_id(&varID) != CHILDID_SELF || !IsWindow(This->hwnd)) + return E_INVALIDARG; + + len = SendMessageW(This->hwnd, WM_GETTEXT, sizeof(name)/sizeof(WCHAR), (LPARAM)name); + if(!len) + return S_FALSE; + + for(i=0; i(%s %p)\n", This, debugstr_variant(&varID), pszValue); + + *pszValue = NULL; + if(convert_child_id(&varID) != CHILDID_SELF) + return E_INVALIDARG; + return S_FALSE; +} + +static HRESULT WINAPI Client_get_accDescription(IAccessible *iface, + VARIANT varID, BSTR *pszDescription) +{ + Client *This = impl_from_Client(iface); + + TRACE("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pszDescription); + + *pszDescription = NULL; + if(convert_child_id(&varID) != CHILDID_SELF) + return E_INVALIDARG; + return S_FALSE; +} + +static HRESULT WINAPI Client_get_accRole(IAccessible *iface, VARIANT varID, VARIANT *pvarRole) +{ + Client *This = impl_from_Client(iface); + + TRACE("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pvarRole); + + if(convert_child_id(&varID) != CHILDID_SELF) { + V_VT(pvarRole) = VT_EMPTY; + return E_INVALIDARG; + } + + V_VT(pvarRole) = VT_I4; + V_I4(pvarRole) = ROLE_SYSTEM_CLIENT; + return S_OK; +} + +static HRESULT WINAPI Client_get_accState(IAccessible *iface, VARIANT varID, VARIANT *pvarState) +{ + Client *This = impl_from_Client(iface); + LONG style; + + TRACE("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pvarState); + + if(convert_child_id(&varID) != CHILDID_SELF) { + V_VT(pvarState) = VT_EMPTY; + return E_INVALIDARG; + } + + V_VT(pvarState) = VT_I4; + V_I4(pvarState) = 0; + + style = GetWindowLongW(This->hwnd, GWL_STYLE); + if(style & WS_DISABLED) + V_I4(pvarState) |= STATE_SYSTEM_UNAVAILABLE; + else if(IsWindow(This->hwnd)) + V_I4(pvarState) |= STATE_SYSTEM_FOCUSABLE; + if(GetFocus() == This->hwnd) + V_I4(pvarState) |= STATE_SYSTEM_FOCUSED; + if(!(style & WS_VISIBLE)) + V_I4(pvarState) |= STATE_SYSTEM_INVISIBLE; + return S_OK; +} + +static HRESULT WINAPI Client_get_accHelp(IAccessible *iface, VARIANT varID, BSTR *pszHelp) +{ + Client *This = impl_from_Client(iface); + + TRACE("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pszHelp); + + *pszHelp = NULL; + if(convert_child_id(&varID) != CHILDID_SELF) + return E_INVALIDARG; + return S_FALSE; +} + +static HRESULT WINAPI Client_get_accHelpTopic(IAccessible *iface, + BSTR *pszHelpFile, VARIANT varID, LONG *pidTopic) +{ + Client *This = impl_from_Client(iface); + FIXME("(%p)->(%p %s %p)\n", This, pszHelpFile, debugstr_variant(&varID), pidTopic); + return E_NOTIMPL; +} + +static HRESULT WINAPI Client_get_accKeyboardShortcut(IAccessible *iface, + VARIANT varID, BSTR *pszKeyboardShortcut) +{ + static const WCHAR shortcut_fmt[] = {'A','l','t','+','!',0}; + Client *This = impl_from_Client(iface); + WCHAR name[1024]; + UINT i, len; + + TRACE("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pszKeyboardShortcut); + + *pszKeyboardShortcut = NULL; + if(convert_child_id(&varID) != CHILDID_SELF) + return E_INVALIDARG; + + len = SendMessageW(This->hwnd, WM_GETTEXT, sizeof(name)/sizeof(WCHAR), (LPARAM)name); + for(i=0; i= len) + return S_FALSE; + + *pszKeyboardShortcut = SysAllocString(shortcut_fmt); + if(!*pszKeyboardShortcut) + return E_OUTOFMEMORY; + + (*pszKeyboardShortcut)[4] = name[i+1]; + return S_OK; +} + +static HRESULT WINAPI Client_get_accFocus(IAccessible *iface, VARIANT *pvarID) +{ + Client *This = impl_from_Client(iface); + FIXME("(%p)->(%p)\n", This, pvarID); + return E_NOTIMPL; +} + +static HRESULT WINAPI Client_get_accSelection(IAccessible *iface, VARIANT *pvarID) +{ + Client *This = impl_from_Client(iface); + FIXME("(%p)->(%p)\n", This, pvarID); + return E_NOTIMPL; +} + +static HRESULT WINAPI Client_get_accDefaultAction(IAccessible *iface, + VARIANT varID, BSTR *pszDefaultAction) +{ + Client *This = impl_from_Client(iface); + + TRACE("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pszDefaultAction); + + *pszDefaultAction = NULL; + if(convert_child_id(&varID) != CHILDID_SELF) + return E_INVALIDARG; + return S_FALSE; +} + +static HRESULT WINAPI Client_accSelect(IAccessible *iface, LONG flagsSelect, VARIANT varID) +{ + Client *This = impl_from_Client(iface); + FIXME("(%p)->(%x %s)\n", This, flagsSelect, debugstr_variant(&varID)); + return E_NOTIMPL; +} + +static HRESULT WINAPI Client_accLocation(IAccessible *iface, LONG *pxLeft, + LONG *pyTop, LONG *pcxWidth, LONG *pcyHeight, VARIANT varID) +{ + Client *This = impl_from_Client(iface); + RECT rect; + POINT pt; + + TRACE("(%p)->(%p %p %p %p %s)\n", This, pxLeft, pyTop, + pcxWidth, pcyHeight, debugstr_variant(&varID)); + + *pxLeft = *pyTop = *pcxWidth = *pcyHeight = 0; + if(convert_child_id(&varID) != CHILDID_SELF) + return E_INVALIDARG; + + if(!GetClientRect(This->hwnd, &rect)) + return S_OK; + + pt.x = rect.left, + pt.y = rect.top; + MapWindowPoints(This->hwnd, NULL, &pt, 1); + *pxLeft = pt.x; + *pyTop = pt.y; + + pt.x = rect.right; + pt.y = rect.bottom; + MapWindowPoints(This->hwnd, NULL, &pt, 1); + *pcxWidth = pt.x - *pxLeft; + *pcyHeight = pt.y - *pyTop; + return S_OK; +} + +static HRESULT WINAPI Client_accNavigate(IAccessible *iface, + LONG navDir, VARIANT varStart, VARIANT *pvarEnd) +{ + Client *This = impl_from_Client(iface); + FIXME("(%p)->(%d %s %p)\n", This, navDir, debugstr_variant(&varStart), pvarEnd); + return E_NOTIMPL; +} + +static HRESULT WINAPI Client_accHitTest(IAccessible *iface, + LONG xLeft, LONG yTop, VARIANT *pvarID) +{ + Client *This = impl_from_Client(iface); + HWND child; + POINT pt; + + TRACE("(%p)->(%d %d %p)\n", This, xLeft, yTop, pvarID); + + V_VT(pvarID) = VT_I4; + V_I4(pvarID) = 0; + + pt.x = xLeft; + pt.y = yTop; + if(!IsWindowVisible(This->hwnd) || !ScreenToClient(This->hwnd, &pt)) + return S_OK; + + child = ChildWindowFromPointEx(This->hwnd, pt, CWP_SKIPINVISIBLE); + if(!child || child==This->hwnd) + return S_OK; + + V_VT(pvarID) = VT_DISPATCH; + return AccessibleObjectFromWindow(child, OBJID_WINDOW, + &IID_IDispatch, (void**)&V_DISPATCH(pvarID)); +} + +static HRESULT WINAPI Client_accDoDefaultAction(IAccessible *iface, VARIANT varID) +{ + Client *This = impl_from_Client(iface); + FIXME("(%p)->(%s)\n", This, debugstr_variant(&varID)); + return E_NOTIMPL; +} + +static HRESULT WINAPI Client_put_accName(IAccessible *iface, VARIANT varID, BSTR pszName) +{ + Client *This = impl_from_Client(iface); + FIXME("(%p)->(%s %s)\n", This, debugstr_variant(&varID), debugstr_w(pszName)); + return E_NOTIMPL; +} + +static HRESULT WINAPI Client_put_accValue(IAccessible *iface, VARIANT varID, BSTR pszValue) +{ + Client *This = impl_from_Client(iface); + FIXME("(%p)->(%s %s)\n", This, debugstr_variant(&varID), debugstr_w(pszValue)); + return E_NOTIMPL; +} + +static const IAccessibleVtbl ClientVtbl = { + Client_QueryInterface, + Client_AddRef, + Client_Release, + Client_GetTypeInfoCount, + Client_GetTypeInfo, + Client_GetIDsOfNames, + Client_Invoke, + Client_get_accParent, + Client_get_accChildCount, + Client_get_accChild, + Client_get_accName, + Client_get_accValue, + Client_get_accDescription, + Client_get_accRole, + Client_get_accState, + Client_get_accHelp, + Client_get_accHelpTopic, + Client_get_accKeyboardShortcut, + Client_get_accFocus, + Client_get_accSelection, + Client_get_accDefaultAction, + Client_accSelect, + Client_accLocation, + Client_accNavigate, + Client_accHitTest, + Client_accDoDefaultAction, + Client_put_accName, + Client_put_accValue +}; + +static inline Client* impl_from_Client_OleWindow(IOleWindow *iface) +{ + return CONTAINING_RECORD(iface, Client, IOleWindow_iface); +} + +static HRESULT WINAPI Client_OleWindow_QueryInterface(IOleWindow *iface, REFIID riid, void **ppv) +{ + Client *This = impl_from_Client_OleWindow(iface); + return IAccessible_QueryInterface(&This->IAccessible_iface, riid, ppv); +} + +static ULONG WINAPI Client_OleWindow_AddRef(IOleWindow *iface) +{ + Client *This = impl_from_Client_OleWindow(iface); + return IAccessible_AddRef(&This->IAccessible_iface); +} + +static ULONG WINAPI Client_OleWindow_Release(IOleWindow *iface) +{ + Client *This = impl_from_Client_OleWindow(iface); + return IAccessible_Release(&This->IAccessible_iface); +} + +static HRESULT WINAPI Client_OleWindow_GetWindow(IOleWindow *iface, HWND *phwnd) +{ + Client *This = impl_from_Client_OleWindow(iface); + + TRACE("(%p)->(%p)\n", This, phwnd); + + *phwnd = This->hwnd; + return S_OK; +} + +static HRESULT WINAPI Client_OleWindow_ContextSensitiveHelp(IOleWindow *iface, BOOL fEnterMode) +{ + Client *This = impl_from_Client_OleWindow(iface); + FIXME("(%p)->(%x)\n", This, fEnterMode); + return E_NOTIMPL; +} + +static const IOleWindowVtbl ClientOleWindowVtbl = { + Client_OleWindow_QueryInterface, + Client_OleWindow_AddRef, + Client_OleWindow_Release, + Client_OleWindow_GetWindow, + Client_OleWindow_ContextSensitiveHelp +}; + +HRESULT create_client_object(HWND hwnd, const IID *iid, void **obj) +{ + Client *client; + HRESULT hres; + + if(!IsWindow(hwnd)) + return E_FAIL; + + client = heap_alloc_zero(sizeof(Client)); + if(!client) + return E_OUTOFMEMORY; + + client->IAccessible_iface.lpVtbl = &ClientVtbl; + client->IOleWindow_iface.lpVtbl = &ClientOleWindowVtbl; + client->ref = 1; + client->hwnd = hwnd; + + hres = IAccessible_QueryInterface(&client->IAccessible_iface, iid, obj); + IAccessible_Release(&client->IAccessible_iface); + return hres; +} diff --git a/dll/win32/oleacc/lang/oleacc_De.rc b/dll/win32/oleacc/lang/oleacc_De.rc index cc0bb0df805..44620ad3a94 100644 --- a/dll/win32/oleacc/lang/oleacc_De.rc +++ b/dll/win32/oleacc/lang/oleacc_De.rc @@ -18,8 +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 @@ -91,4 +89,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "Trenn-Schaltfläche" ROLE_SYSTEM_IPADDRESS "IP-Adresse" ROLE_SYSTEM_OUTLINEBUTTON "Gliederungsschaltfläche" /* outline kann aber auch umrahmen heißen... */ + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_En.rc b/dll/win32/oleacc/lang/oleacc_En.rc index 37d3a557495..f1b12efa851 100644 --- a/dll/win32/oleacc/lang/oleacc_En.rc +++ b/dll/win32/oleacc/lang/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 @@ -89,4 +87,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "split button" ROLE_SYSTEM_IPADDRESS "IP address" ROLE_SYSTEM_OUTLINEBUTTON "outline button" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_Fr.rc b/dll/win32/oleacc/lang/oleacc_Fr.rc index ef21c088452..65a0f2236d3 100644 --- a/dll/win32/oleacc/lang/oleacc_Fr.rc +++ b/dll/win32/oleacc/lang/oleacc_Fr.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - /* UTF-8 */ #pragma code_page(65001) @@ -93,4 +91,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "bouton avec menu" ROLE_SYSTEM_IPADDRESS "adresse IP" ROLE_SYSTEM_OUTLINEBUTTON "bouton de résumé" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_He.rc b/dll/win32/oleacc/lang/oleacc_He.rc index 985af397a33..fdc516c1bd9 100644 --- a/dll/win32/oleacc/lang/oleacc_He.rc +++ b/dll/win32/oleacc/lang/oleacc_He.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - LANGUAGE LANG_HEBREW, SUBLANG_DEFAULT STRINGTABLE @@ -91,4 +89,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "split button" ROLE_SYSTEM_IPADDRESS "כתובת IP" ROLE_SYSTEM_OUTLINEBUTTON "outline button" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_Hu.rc b/dll/win32/oleacc/lang/oleacc_Hu.rc index 63ce7410b3b..5d50a9989ee 100644 --- a/dll/win32/oleacc/lang/oleacc_Hu.rc +++ b/dll/win32/oleacc/lang/oleacc_Hu.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) @@ -92,4 +90,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "felosztott gomb" ROLE_SYSTEM_IPADDRESS "IP cím" ROLE_SYSTEM_OUTLINEBUTTON "körvonalazott gomb" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_It.rc b/dll/win32/oleacc/lang/oleacc_It.rc index 97456932e83..3f8d10db2bd 100644 --- a/dll/win32/oleacc/lang/oleacc_It.rc +++ b/dll/win32/oleacc/lang/oleacc_It.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - /* UTF-8 */ #pragma code_page(65001) @@ -93,4 +91,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "pulsante di menù combinato" ROLE_SYSTEM_IPADDRESS "indirizzo IP" ROLE_SYSTEM_OUTLINEBUTTON "pulsante dello schema" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_Ko.rc b/dll/win32/oleacc/lang/oleacc_Ko.rc index 19d5d381a8d..c0d6715f881 100644 --- a/dll/win32/oleacc/lang/oleacc_Ko.rc +++ b/dll/win32/oleacc/lang/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 @@ -90,4 +88,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON " " ROLE_SYSTEM_IPADDRESS "IP ּ" ROLE_SYSTEM_OUTLINEBUTTON "ܰ " + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_Lt.rc b/dll/win32/oleacc/lang/oleacc_Lt.rc index c6d57b8b44b..60f4087cbac 100644 --- a/dll/win32/oleacc/lang/oleacc_Lt.rc +++ b/dll/win32/oleacc/lang/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) @@ -92,4 +90,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "išskleidimo mygtukas" ROLE_SYSTEM_IPADDRESS "IP adresas" ROLE_SYSTEM_OUTLINEBUTTON "plano mygtukas" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_Nl.rc b/dll/win32/oleacc/lang/oleacc_Nl.rc index ccef803da84..1f707159f05 100644 --- a/dll/win32/oleacc/lang/oleacc_Nl.rc +++ b/dll/win32/oleacc/lang/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 @@ -89,4 +87,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "splitsknop" ROLE_SYSTEM_IPADDRESS "IP-adres" ROLE_SYSTEM_OUTLINEBUTTON "omtrekknop" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_No.rc b/dll/win32/oleacc/lang/oleacc_No.rc index 6eb25d11c3a..e05ae900c5b 100644 --- a/dll/win32/oleacc/lang/oleacc_No.rc +++ b/dll/win32/oleacc/lang/oleacc_No.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) @@ -92,4 +90,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "oppdelt knapp" ROLE_SYSTEM_IPADDRESS "IP-adresse" ROLE_SYSTEM_OUTLINEBUTTON "utheving for knapp" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_Pl.rc b/dll/win32/oleacc/lang/oleacc_Pl.rc index 87e3917b1ac..bbd1bf7c7d7 100644 --- a/dll/win32/oleacc/lang/oleacc_Pl.rc +++ b/dll/win32/oleacc/lang/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 @@ -89,4 +87,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "przycisk rozdzielania" ROLE_SYSTEM_IPADDRESS "adres IP" ROLE_SYSTEM_OUTLINEBUTTON "przycisk zarysu" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_Pt.rc b/dll/win32/oleacc/lang/oleacc_Pt.rc index d692ddd631a..f09868a4214 100644 --- a/dll/win32/oleacc/lang/oleacc_Pt.rc +++ b/dll/win32/oleacc/lang/oleacc_Pt.rc @@ -19,8 +19,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - #pragma code_page(65001) LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN @@ -92,6 +90,39 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "split button" ROLE_SYSTEM_IPADDRESS "endereço IP" ROLE_SYSTEM_OUTLINEBUTTON "outline button" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE @@ -163,4 +194,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "split button" ROLE_SYSTEM_IPADDRESS "endereço IP" ROLE_SYSTEM_OUTLINEBUTTON "outline button" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_Ro.rc b/dll/win32/oleacc/lang/oleacc_Ro.rc index 1081e5ac705..87ff65e92e6 100644 --- a/dll/win32/oleacc/lang/oleacc_Ro.rc +++ b/dll/win32/oleacc/lang/oleacc_Ro.rc @@ -18,77 +18,108 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL #pragma code_page(65001) STRINGTABLE { - 0 "obiect necunoscut" /* undocumented */ - ROLE_SYSTEM_TITLEBAR "bară de titlu" - ROLE_SYSTEM_MENUBAR "bară de meniu" - ROLE_SYSTEM_SCROLLBAR "bară de defilare" - ROLE_SYSTEM_GRIP "ghidaj" - ROLE_SYSTEM_SOUND "sunet" - ROLE_SYSTEM_CURSOR "cursor" - ROLE_SYSTEM_CARET "circumflex" - ROLE_SYSTEM_ALERT "atenționare" - ROLE_SYSTEM_WINDOW "fereastră" - ROLE_SYSTEM_CLIENT "client" - ROLE_SYSTEM_MENUPOPUP "meniu contextual" - ROLE_SYSTEM_MENUITEM "element de meniu" - ROLE_SYSTEM_TOOLTIP "indiciu" - ROLE_SYSTEM_APPLICATION "aplicație" - ROLE_SYSTEM_DOCUMENT "document" - ROLE_SYSTEM_PANE "panou" - ROLE_SYSTEM_CHART "diagramă" - ROLE_SYSTEM_DIALOG "dialog" - ROLE_SYSTEM_BORDER "margine" - ROLE_SYSTEM_GROUPING "grupare" - ROLE_SYSTEM_SEPARATOR "separator" - ROLE_SYSTEM_TOOLBAR "panou de instrumente" - ROLE_SYSTEM_STATUSBAR "bară de stare" - ROLE_SYSTEM_TABLE "tabel" - ROLE_SYSTEM_COLUMNHEADER "antet de coloană" - ROLE_SYSTEM_ROWHEADER "antet de rând" - ROLE_SYSTEM_COLUMN "coloană" - ROLE_SYSTEM_ROW "rând" - ROLE_SYSTEM_CELL "celulă" - ROLE_SYSTEM_LINK "adresă" - ROLE_SYSTEM_HELPBALLOON "balon de ajutor" - ROLE_SYSTEM_CHARACTER "caracter" - ROLE_SYSTEM_LIST "listă" - ROLE_SYSTEM_LISTITEM "element din listă" - ROLE_SYSTEM_OUTLINE "contur" - ROLE_SYSTEM_OUTLINEITEM "conturare element" - ROLE_SYSTEM_PAGETAB "compartiment" - ROLE_SYSTEM_PROPERTYPAGE "pagină de proprietăți" - ROLE_SYSTEM_INDICATOR "indicator" - ROLE_SYSTEM_GRAPHIC "grafică" - ROLE_SYSTEM_STATICTEXT "text static" - ROLE_SYSTEM_TEXT "text" - ROLE_SYSTEM_PUSHBUTTON "buton de comandă" - ROLE_SYSTEM_CHECKBUTTON "buton de bifare" - ROLE_SYSTEM_RADIOBUTTON "buton radio" - ROLE_SYSTEM_COMBOBOX "listă derulantă" - ROLE_SYSTEM_DROPLIST "listă verticală" - ROLE_SYSTEM_PROGRESSBAR "bară de progres" - ROLE_SYSTEM_DIAL "apelator" - ROLE_SYSTEM_HOTKEYFIELD "câmp de tastă rapidă" - ROLE_SYSTEM_SLIDER "glisor" - ROLE_SYSTEM_SPINBUTTON "căsuță incrementală" - ROLE_SYSTEM_DIAGRAM "diagramă" - ROLE_SYSTEM_ANIMATION "animație" - ROLE_SYSTEM_EQUATION "ecuație" - ROLE_SYSTEM_BUTTONDROPDOWN "buton listă verticală" - ROLE_SYSTEM_BUTTONMENU "buton meniu" + 0 "obiect necunoscut" /* undocumented */ + ROLE_SYSTEM_TITLEBAR "bară de titlu" + ROLE_SYSTEM_MENUBAR "bară de meniu" + ROLE_SYSTEM_SCROLLBAR "bară de defilare" + ROLE_SYSTEM_GRIP "ghidaj" + ROLE_SYSTEM_SOUND "sunet" + ROLE_SYSTEM_CURSOR "cursor" + ROLE_SYSTEM_CARET "circumflex" + ROLE_SYSTEM_ALERT "atenționare" + ROLE_SYSTEM_WINDOW "fereastră" + ROLE_SYSTEM_CLIENT "client" + ROLE_SYSTEM_MENUPOPUP "meniu contextual" + ROLE_SYSTEM_MENUITEM "element de meniu" + ROLE_SYSTEM_TOOLTIP "indiciu" + ROLE_SYSTEM_APPLICATION "aplicație" + ROLE_SYSTEM_DOCUMENT "document" + ROLE_SYSTEM_PANE "panou" + ROLE_SYSTEM_CHART "diagramă" + ROLE_SYSTEM_DIALOG "dialog" + ROLE_SYSTEM_BORDER "margine" + ROLE_SYSTEM_GROUPING "grupare" + ROLE_SYSTEM_SEPARATOR "separator" + ROLE_SYSTEM_TOOLBAR "panou de instrumente" + ROLE_SYSTEM_STATUSBAR "bară de stare" + ROLE_SYSTEM_TABLE "tabel" + ROLE_SYSTEM_COLUMNHEADER "antet de coloană" + ROLE_SYSTEM_ROWHEADER "antet de rând" + ROLE_SYSTEM_COLUMN "coloană" + ROLE_SYSTEM_ROW "rând" + ROLE_SYSTEM_CELL "celulă" + ROLE_SYSTEM_LINK "adresă" + ROLE_SYSTEM_HELPBALLOON "balon de ajutor" + ROLE_SYSTEM_CHARACTER "caracter" + ROLE_SYSTEM_LIST "listă" + ROLE_SYSTEM_LISTITEM "element din listă" + ROLE_SYSTEM_OUTLINE "contur" + ROLE_SYSTEM_OUTLINEITEM "conturare element" + ROLE_SYSTEM_PAGETAB "compartiment" + ROLE_SYSTEM_PROPERTYPAGE "pagină de proprietăți" + ROLE_SYSTEM_INDICATOR "indicator" + ROLE_SYSTEM_GRAPHIC "grafică" + ROLE_SYSTEM_STATICTEXT "text static" + ROLE_SYSTEM_TEXT "text" + ROLE_SYSTEM_PUSHBUTTON "buton de comandă" + ROLE_SYSTEM_CHECKBUTTON "buton de bifare" + ROLE_SYSTEM_RADIOBUTTON "buton radio" + ROLE_SYSTEM_COMBOBOX "listă derulantă" + ROLE_SYSTEM_DROPLIST "listă verticală" + ROLE_SYSTEM_PROGRESSBAR "bară de progres" + ROLE_SYSTEM_DIAL "apelator" + ROLE_SYSTEM_HOTKEYFIELD "câmp de tastă rapidă" + ROLE_SYSTEM_SLIDER "glisor" + ROLE_SYSTEM_SPINBUTTON "căsuță incrementală" + ROLE_SYSTEM_DIAGRAM "diagramă" + ROLE_SYSTEM_ANIMATION "animație" + ROLE_SYSTEM_EQUATION "ecuație" + ROLE_SYSTEM_BUTTONDROPDOWN "buton listă verticală" + ROLE_SYSTEM_BUTTONMENU "buton meniu" ROLE_SYSTEM_BUTTONDROPDOWNGRID "buton listă verticală de grilă" - ROLE_SYSTEM_WHITESPACE "spațiu gol" - ROLE_SYSTEM_PAGETABLIST "listă de file" - ROLE_SYSTEM_CLOCK "ceas" - ROLE_SYSTEM_SPLITBUTTON "buton separare" - ROLE_SYSTEM_IPADDRESS "adresă IP" - ROLE_SYSTEM_OUTLINEBUTTON "buton contur" + ROLE_SYSTEM_WHITESPACE "spațiu gol" + ROLE_SYSTEM_PAGETABLIST "listă de file" + ROLE_SYSTEM_CLOCK "ceas" + ROLE_SYSTEM_SPLITBUTTON "buton separare" + ROLE_SYSTEM_IPADDRESS "adresă IP" + ROLE_SYSTEM_OUTLINEBUTTON "buton contur" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_Ru.rc b/dll/win32/oleacc/lang/oleacc_Ru.rc index d3ed5c871b0..050c707d825 100644 --- a/dll/win32/oleacc/lang/oleacc_Ru.rc +++ b/dll/win32/oleacc/lang/oleacc_Ru.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT STRINGTABLE @@ -89,4 +87,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "кнопка разделения" ROLE_SYSTEM_IPADDRESS "IP-адрес" ROLE_SYSTEM_OUTLINEBUTTON "кнопка контура" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_Si.rc b/dll/win32/oleacc/lang/oleacc_Si.rc index 2622901b9db..cee2ab3a5cd 100644 --- a/dll/win32/oleacc/lang/oleacc_Si.rc +++ b/dll/win32/oleacc/lang/oleacc_Si.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - #pragma code_page(65001) LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT @@ -91,4 +89,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "deljeni gumb" ROLE_SYSTEM_IPADDRESS "IP naslov" ROLE_SYSTEM_OUTLINEBUTTON "gumb orisa" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_Sq.rc b/dll/win32/oleacc/lang/oleacc_Sq.rc index 6ab38a91c57..1f5171c55f1 100644 --- a/dll/win32/oleacc/lang/oleacc_Sq.rc +++ b/dll/win32/oleacc/lang/oleacc_Sq.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - LANGUAGE LANG_ALBANIAN, SUBLANG_NEUTRAL STRINGTABLE @@ -89,4 +87,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "buton ndarës" ROLE_SYSTEM_IPADDRESS "adresa IP" ROLE_SYSTEM_OUTLINEBUTTON "buton plani" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_Tr.rc b/dll/win32/oleacc/lang/oleacc_Tr.rc index 41ce38eaa42..b2968f114a3 100644 --- a/dll/win32/oleacc/lang/oleacc_Tr.rc +++ b/dll/win32/oleacc/lang/oleacc_Tr.rc @@ -18,8 +18,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE @@ -89,4 +87,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "ayırma düğmesi" ROLE_SYSTEM_IPADDRESS "IP adresi" ROLE_SYSTEM_OUTLINEBUTTON "anaçizgi düğmesi" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/lang/oleacc_Uk.rc b/dll/win32/oleacc/lang/oleacc_Uk.rc index 10cead739f8..55da93f56da 100644 --- a/dll/win32/oleacc/lang/oleacc_Uk.rc +++ b/dll/win32/oleacc/lang/oleacc_Uk.rc @@ -20,8 +20,6 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "oleacc.h" - /* UTF-8 */ #pragma code_page(65001) @@ -94,4 +92,37 @@ STRINGTABLE ROLE_SYSTEM_SPLITBUTTON "кнопка поділу" ROLE_SYSTEM_IPADDRESS "IP адреса" ROLE_SYSTEM_OUTLINEBUTTON "кпопка плану" + + IDS_STATE_NORMAL "normal" + IDS_STATE_UNAVAILABLE "unavailable" + IDS_STATE_SELECTED "selected" + IDS_STATE_FOCUSED "focused" + IDS_STATE_PRESSED "pressed" + IDS_STATE_CHECKED "checked" + IDS_STATE_MIXED "mixed" + IDS_STATE_READONLY "read only" + IDS_STATE_HOTTRACKED "hot tracked" + IDS_STATE_DEFAULT "default" + IDS_STATE_EXPANDED "expanded" + IDS_STATE_COLLAPSED "collapsed" + IDS_STATE_BUSY "busy" + IDS_STATE_FLOATING "floating" + IDS_STATE_MARQUEED "marqueed" + IDS_STATE_ANIMATED "animated" + IDS_STATE_INVISIBLE "invisible" + IDS_STATE_OFFSCREEN "offscreen" + IDS_STATE_SIZEABLE "sizeable" + IDS_STATE_MOVEABLE "moveable" + IDS_STATE_SELFVOICING "self voicing" + IDS_STATE_FOCUSABLE "focusable" + IDS_STATE_SELECTABLE "selectable" + IDS_STATE_LINKED "linked" + IDS_STATE_TRAVERSED "traversed" + IDS_STATE_MULTISELECTABLE "multi selectable" + IDS_STATE_EXTSELECTABLE "extended selectable" + IDS_STATE_ALERT_LOW "alert low" + IDS_STATE_ALERT_MEDIUM "alert medium" + IDS_STATE_ALERT_HIGH "alert high" + IDS_STATE_PROTECTED "protected" + IDS_STATE_HASPOPUP "has popup" } diff --git a/dll/win32/oleacc/main.c b/dll/win32/oleacc/main.c index 148dd87e642..a3739888765 100644 --- a/dll/win32/oleacc/main.c +++ b/dll/win32/oleacc/main.c @@ -18,42 +18,306 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#define WIN32_NO_STATUS -#define _INC_WINDOWS -#define COM_NO_WINDOWS_H +#include "oleacc_private.h" -#include -#include -#include -//#include "winuser.h" -#include -#include +#include +#include #include -#include -WINE_DEFAULT_DEBUG_CHANNEL(oleacc); +#include "resource.h" + +static const WCHAR lresult_atom_prefix[] = {'w','i','n','e','_','o','l','e','a','c','c',':'}; + +static const WCHAR menuW[] = {'#','3','2','7','6','8',0}; +static const WCHAR desktopW[] = {'#','3','2','7','6','9',0}; +static const WCHAR dialogW[] = {'#','3','2','7','7','0',0}; +static const WCHAR winswitchW[] = {'#','3','2','7','7','1',0}; +static const WCHAR mdi_clientW[] = {'M','D','I','C','l','i','e','n','t',0}; +static const WCHAR richeditW[] = {'R','I','C','H','E','D','I','T',0}; +static const WCHAR richedit20aW[] = {'R','i','c','h','E','d','i','t','2','0','A',0}; +static const WCHAR richedit20wW[] = {'R','i','c','h','E','d','i','t','2','0','W',0}; + +typedef HRESULT (WINAPI *accessible_create)(HWND, const IID*, void**); + +static struct { + const WCHAR *name; + DWORD idx; + accessible_create create_client; + accessible_create create_window; +} builtin_classes[] = { + {WC_LISTBOXW, 0x10000, NULL, NULL}, + {menuW, 0x10001, NULL, NULL}, + {WC_BUTTONW, 0x10002, NULL, NULL}, + {WC_STATICW, 0x10003, NULL, NULL}, + {WC_EDITW, 0x10004, NULL, NULL}, + {WC_COMBOBOXW, 0x10005, NULL, NULL}, + {dialogW, 0x10006, NULL, NULL}, + {winswitchW, 0x10007, NULL, NULL}, + {mdi_clientW, 0x10008, NULL, NULL}, + {desktopW, 0x10009, NULL, NULL}, + {WC_SCROLLBARW, 0x1000a, NULL, NULL}, + {STATUSCLASSNAMEW, 0x1000b, NULL, NULL}, + {TOOLBARCLASSNAMEW, 0x1000c, NULL, NULL}, + {PROGRESS_CLASSW, 0x1000d, NULL, NULL}, + {ANIMATE_CLASSW, 0x1000e, NULL, NULL}, + {WC_TABCONTROLW, 0x1000f, NULL, NULL}, + {HOTKEY_CLASSW, 0x10010, NULL, NULL}, + {WC_HEADERW, 0x10011, NULL, NULL}, + {TRACKBAR_CLASSW, 0x10012, NULL, NULL}, + {WC_LISTVIEWW, 0x10013, NULL, NULL}, + {UPDOWN_CLASSW, 0x10016, NULL, NULL}, + {TOOLTIPS_CLASSW, 0x10018, NULL, NULL}, + {WC_TREEVIEWW, 0x10019, NULL, NULL}, + {MONTHCAL_CLASSW, 0, NULL, NULL}, + {DATETIMEPICK_CLASSW, 0, NULL, NULL}, + {WC_IPADDRESSW, 0, NULL, NULL}, + {richeditW, 0x1001c, NULL, NULL}, + {richedit20aW, 0, NULL, NULL}, + {richedit20wW, 0, NULL, NULL}, +}; static HINSTANCE oleacc_handle = 0; -HRESULT WINAPI CreateStdAccessibleObject( HWND hwnd, LONG idObject, - REFIID riidInterface, void** ppvObject ) +int convert_child_id(VARIANT *v) { - FIXME("%p %d %s %p\n", hwnd, idObject, + switch(V_VT(v)) { + case VT_I4: + return V_I4(v); + default: + FIXME("unhandled child ID variant type: %d\n", V_VT(v)); + return -1; + } +} + +static accessible_create get_builtin_accessible_obj(HWND hwnd, LONG objid) +{ + WCHAR class_name[64]; + int i, idx; + + if(!RealGetWindowClassW(hwnd, class_name, sizeof(class_name)/sizeof(WCHAR))) + return NULL; + TRACE("got window class: %s\n", debugstr_w(class_name)); + + for(i=0; i +#include + +#include "resource.h" 1 TYPELIB "oleacc_classes.tlb" 1 WINE_REGISTRY "oleacc_classes.rgs" +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + +#define WINE_FILEDESCRIPTION_STR "Wine OLE Accessibility" +#define WINE_FILENAME_STR "oleacc.dll" +#define WINE_FILEVERSION 7,0,0,0 +#define WINE_FILEVERSION_STR "7.0.0.0" +#define WINE_PRODUCTVERSION 6,1,7600,16385 +#define WINE_PRODUCTVERSION_STR "6.1.6700.16385" + +#include + #ifdef LANGUAGE_EN_US #include "lang/oleacc_En.rc" #endif diff --git a/dll/win32/oleacc/oleacc.spec b/dll/win32/oleacc/oleacc.spec index 68514546fc3..9f3a9a06ee6 100644 --- a/dll/win32/oleacc/oleacc.spec +++ b/dll/win32/oleacc/oleacc.spec @@ -9,13 +9,14 @@ @ stdcall -private DllRegisterServer() @ stdcall -private DllUnregisterServer() @ stdcall GetOleaccVersionInfo(ptr ptr) +@ stdcall GetProcessHandleFromHwnd(ptr) @ stdcall GetRoleTextA(long ptr long) @ stdcall GetRoleTextW(long ptr long) -@ stub GetStateTextA -@ stub GetStateTextW -@ stub IID_IAccessible -@ stub IID_IAccessibleHandler -@ stub LIBID_Accessibility +@ stdcall GetStateTextA(long ptr long) +@ stdcall GetStateTextW(long ptr long) +@ extern IID_IAccessible +@ extern IID_IAccessibleHandler +@ extern LIBID_Accessibility @ stdcall LresultFromObject(ptr long ptr) @ stdcall ObjectFromLresult(long ptr long ptr) -@ stub WindowFromAccessibleObject +@ stdcall WindowFromAccessibleObject(ptr ptr) diff --git a/dll/win32/oleacc/oleacc_private.h b/dll/win32/oleacc/oleacc_private.h new file mode 100644 index 00000000000..726aa4979dd --- /dev/null +++ b/dll/win32/oleacc/oleacc_private.h @@ -0,0 +1,51 @@ +/* + * Copyright 2014 Piotr 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 _OLEACC_PRIVATE_H_ +#define _OLEACC_PRIVATE_H_ + +#define WIN32_NO_STATUS +#define _INC_WINDOWS +#define COM_NO_WINDOWS_H + +#define COBJMACROS + +#include +#include +#include +#include + +#include +WINE_DEFAULT_DEBUG_CHANNEL(oleacc); + +HRESULT create_client_object(HWND, const IID*, void**) DECLSPEC_HIDDEN; +HRESULT create_window_object(HWND, const IID*, void**) DECLSPEC_HIDDEN; + +int convert_child_id(VARIANT *v) DECLSPEC_HIDDEN; + +static inline void * __WINE_ALLOC_SIZE(1) heap_alloc_zero(size_t len) +{ + return HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, len); +} + +static inline BOOL heap_free(void *mem) +{ + return HeapFree(GetProcessHeap(), 0, mem); +} + +#endif /* _OLEACC_PRIVATE_H_ */ diff --git a/dll/win32/oleacc/propservice.c b/dll/win32/oleacc/propservice.c new file mode 100644 index 00000000000..58a113dde34 --- /dev/null +++ b/dll/win32/oleacc/propservice.c @@ -0,0 +1,248 @@ +/* + * Copyright 2014 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 "oleacc_private.h" + +static HRESULT WINAPI AccPropServices_QueryInterface(IAccPropServices *iface, REFIID riid, void **ppv) +{ + if(IsEqualGUID(&IID_IUnknown, riid)) { + TRACE("(IID_IUnknown %p)\n", ppv); + *ppv = iface; + }else if(IsEqualGUID(&IID_IAccPropServices, riid)) { + TRACE("(IID_IAccPropServices %p)\n", ppv); + *ppv = iface; + }else { + FIXME("Unknown iface %s\n", debugstr_guid(riid)); + *ppv = NULL; + return E_NOINTERFACE; + } + + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; +} + +static ULONG WINAPI AccPropServices_AddRef(IAccPropServices *iface) +{ + return 2; +} + +static ULONG WINAPI AccPropServices_Release(IAccPropServices *iface) +{ + return 1; +} + +static HRESULT WINAPI AccPropServices_SetPropValue(IAccPropServices *iface, const BYTE *pIDString, + DWORD dwIDStringLen, MSAAPROPID idProp, VARIANT var) +{ + FIXME("(%p %u %s %s)\n", pIDString, dwIDStringLen, debugstr_guid(&idProp), debugstr_variant(&var)); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_SetPropServer(IAccPropServices *iface, const BYTE *pIDString, + DWORD dwIDStringLen, const MSAAPROPID *paProps, int cProps, IAccPropServer *pServer, AnnoScope AnnoScope) +{ + FIXME("(%p %u %p %d %p %u)\n", pIDString, dwIDStringLen, paProps, cProps, pServer, AnnoScope); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_ClearProps(IAccPropServices *iface, const BYTE *pIDString, + DWORD dwIDStringLen, const MSAAPROPID *paProps, int cProps) +{ + FIXME("(%p %u %p %d)\n", pIDString, dwIDStringLen, paProps, cProps); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_SetHwndProp(IAccPropServices *iface, HWND hwnd, DWORD idObject, + DWORD idChild, MSAAPROPID idProp, VARIANT var) +{ + FIXME("(%p %u %u %s %s)\n", hwnd, idObject, idChild, debugstr_guid(&idProp), debugstr_variant(&var)); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_SetHwndPropStr(IAccPropServices *iface, HWND hwnd, DWORD idObject, + DWORD idChild, MSAAPROPID idProp, LPWSTR str) +{ + FIXME("(%p %u %u %s %s)\n", hwnd, idObject, idChild, debugstr_guid(&idProp), debugstr_w(str)); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_SetHwndPropServer(IAccPropServices *iface, HWND hwnd, DWORD idObject, + DWORD idChild, const MSAAPROPID *paProps, int cProps, IAccPropServer *pServer, AnnoScope AnnoScope) +{ + FIXME("(%p %u %u %p %d %p %u)\n", hwnd, idObject, idChild, paProps, cProps, pServer, AnnoScope); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_ClearHwndProps(IAccPropServices *iface, HWND hwnd, DWORD idObject, + DWORD idChild, const MSAAPROPID *paProps, int cProps) +{ + FIXME("(%p %u %u %p %d)\n", hwnd, idObject, idChild, paProps, cProps); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_ComposeHwndIdentityString(IAccPropServices *iface, HWND hwnd, + DWORD idObject, DWORD idChild, BYTE **ppIDString, DWORD *pdwIDStringLen) +{ + FIXME("(%p %u %u %p %p)\n", hwnd, idObject, idChild, ppIDString, pdwIDStringLen); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_DecomposeHwndIdentityString(IAccPropServices *iface, const BYTE *pIDString, + DWORD dwIDStringLen, HWND *phwnd, DWORD *pidObject, DWORD *pidChild) +{ + FIXME("(%p %u %p %p %p)\n", pIDString, dwIDStringLen, phwnd, pidObject, pidChild); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_SetHmenuProp(IAccPropServices *iface, HMENU hmenu, DWORD idChild, + MSAAPROPID idProp, VARIANT var) +{ + FIXME("(%p %u %s %s)\n", hmenu, idChild, debugstr_guid(&idProp), debugstr_variant(&var)); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_SetHmenuPropStr(IAccPropServices *iface, HMENU hmenu, DWORD idChild, + MSAAPROPID idProp, LPWSTR str) +{ + FIXME("(%p %u %s %s)\n", hmenu, idChild, debugstr_guid(&idProp), debugstr_w(str)); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_SetHmenuPropServer(IAccPropServices *iface, HMENU hmenu, DWORD idChild, + const MSAAPROPID *paProps, int cProps, IAccPropServer *pServer, AnnoScope AnnoScope) +{ + FIXME("(%p %u %p %d %p %u)\n", hmenu, idChild, paProps, cProps, pServer, AnnoScope); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_ClearHmenuProps(IAccPropServices *iface, HMENU hmenu, DWORD idChild, + const MSAAPROPID *paProps, int cProps) +{ + FIXME("(%p %u %p %d)\n", hmenu, idChild, paProps, cProps); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_ComposeHmenuIdentityString(IAccPropServices *iface, HMENU hmenu, DWORD idChild, + BYTE **ppIDString, DWORD *pdwIDStringLen) +{ + FIXME("(%p %u %p %p)\n", hmenu, idChild, ppIDString, pdwIDStringLen); + return E_NOTIMPL; +} + +static HRESULT WINAPI AccPropServices_DecomposeHmenuIdentityString(IAccPropServices *iface, const BYTE *pIDString, + DWORD dwIDStringLen, HMENU *phmenu, DWORD *pidChild) +{ + FIXME("(%p %u %p %p\n", pIDString, dwIDStringLen, phmenu, pidChild); + return E_NOTIMPL; +} + +static const IAccPropServicesVtbl AccPropServicesVtbl = { + AccPropServices_QueryInterface, + AccPropServices_AddRef, + AccPropServices_Release, + AccPropServices_SetPropValue, + AccPropServices_SetPropServer, + AccPropServices_ClearProps, + AccPropServices_SetHwndProp, + AccPropServices_SetHwndPropStr, + AccPropServices_SetHwndPropServer, + AccPropServices_ClearHwndProps, + AccPropServices_ComposeHwndIdentityString, + AccPropServices_DecomposeHwndIdentityString, + AccPropServices_SetHmenuProp, + AccPropServices_SetHmenuPropStr, + AccPropServices_SetHmenuPropServer, + AccPropServices_ClearHmenuProps, + AccPropServices_ComposeHmenuIdentityString, + AccPropServices_DecomposeHmenuIdentityString +}; + +static IAccPropServices AccPropServices = { &AccPropServicesVtbl }; + +static HRESULT WINAPI ClassFactory_QueryInterface(IClassFactory *iface, REFIID riid, void **ppv) +{ + *ppv = NULL; + + if(IsEqualGUID(&IID_IUnknown, riid)) { + TRACE("(%p)->(IID_IUnknown %p)\n", iface, ppv); + *ppv = iface; + }else if(IsEqualGUID(&IID_IClassFactory, riid)) { + TRACE("(%p)->(IID_IClassFactory %p)\n", iface, ppv); + *ppv = iface; + } + + if(*ppv) { + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; + } + + FIXME("(%p)->(%s %p)\n", iface, debugstr_guid(riid), ppv); + return E_NOINTERFACE; +} + +static ULONG WINAPI ClassFactory_AddRef(IClassFactory *iface) +{ + TRACE("(%p)\n", iface); + return 2; +} + +static ULONG WINAPI ClassFactory_Release(IClassFactory *iface) +{ + TRACE("(%p)\n", iface); + return 1; +} + +static HRESULT WINAPI ClassFactory_LockServer(IClassFactory *iface, BOOL fLock) +{ + TRACE("(%p)->(%x)\n", iface, fLock); + return S_OK; +} + +static HRESULT WINAPI CAccPropServices_CreateInstance(IClassFactory *iface, IUnknown *outer, + REFIID riid, void **ppv) +{ + TRACE("(%p %s %p)\n", outer, debugstr_guid(riid), ppv); + + if(outer) { + *ppv = NULL; + return CLASS_E_NOAGGREGATION; + } + + return IAccPropServices_QueryInterface(&AccPropServices, riid, ppv); +} + +static const IClassFactoryVtbl CAccPropServicesFactoryVtbl = { + ClassFactory_QueryInterface, + ClassFactory_AddRef, + ClassFactory_Release, + CAccPropServices_CreateInstance, + ClassFactory_LockServer +}; + +static IClassFactory CAccPropServicesFactory = { &CAccPropServicesFactoryVtbl }; + +HRESULT WINAPI DllGetClassObject(REFCLSID rclsid, REFIID iid, void **ppv) +{ + if(IsEqualGUID(&CLSID_CAccPropServices, rclsid)) { + TRACE("(CLSID_CAccPropServices %s %p)\n", debugstr_guid(iid), ppv); + return IClassFactory_QueryInterface(&CAccPropServicesFactory, iid, ppv); + } + + FIXME("%s %s %p: stub\n", debugstr_guid(rclsid), debugstr_guid(iid), ppv); + return E_NOTIMPL; +} diff --git a/dll/win32/oleacc/resource.h b/dll/win32/oleacc/resource.h new file mode 100644 index 00000000000..d97697b6fcd --- /dev/null +++ b/dll/win32/oleacc/resource.h @@ -0,0 +1,50 @@ +/* + * Copyright 2014 Piotr 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 + */ + +#define IDS_STATE_NORMAL 0x1000 +#define IDS_STATE_UNAVAILABLE 0x1001 +#define IDS_STATE_SELECTED 0x1002 +#define IDS_STATE_FOCUSED 0x1003 +#define IDS_STATE_PRESSED 0x1004 +#define IDS_STATE_CHECKED 0x1005 +#define IDS_STATE_MIXED 0x1006 +#define IDS_STATE_READONLY 0x1007 +#define IDS_STATE_HOTTRACKED 0x1008 +#define IDS_STATE_DEFAULT 0x1009 +#define IDS_STATE_EXPANDED 0x100a +#define IDS_STATE_COLLAPSED 0x100b +#define IDS_STATE_BUSY 0x100c +#define IDS_STATE_FLOATING 0x100d +#define IDS_STATE_MARQUEED 0x100e +#define IDS_STATE_ANIMATED 0x100f +#define IDS_STATE_INVISIBLE 0x1010 +#define IDS_STATE_OFFSCREEN 0x1011 +#define IDS_STATE_SIZEABLE 0x1012 +#define IDS_STATE_MOVEABLE 0x1013 +#define IDS_STATE_SELFVOICING 0x1014 +#define IDS_STATE_FOCUSABLE 0x1015 +#define IDS_STATE_SELECTABLE 0x1016 +#define IDS_STATE_LINKED 0x1017 +#define IDS_STATE_TRAVERSED 0x1018 +#define IDS_STATE_MULTISELECTABLE 0x1019 +#define IDS_STATE_EXTSELECTABLE 0x101a +#define IDS_STATE_ALERT_LOW 0x101b +#define IDS_STATE_ALERT_MEDIUM 0x101c +#define IDS_STATE_ALERT_HIGH 0x101d +#define IDS_STATE_PROTECTED 0x101e +#define IDS_STATE_HASPOPUP 0x101f diff --git a/dll/win32/oleacc/window.c b/dll/win32/oleacc/window.c new file mode 100644 index 00000000000..a659adaad8e --- /dev/null +++ b/dll/win32/oleacc/window.c @@ -0,0 +1,361 @@ +/* + * Copyright 2014 Piotr 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 "oleacc_private.h" + +typedef struct { + IAccessible IAccessible_iface; + IOleWindow IOleWindow_iface; + + LONG ref; +} Window; + +static inline Window* impl_from_Window(IAccessible *iface) +{ + return CONTAINING_RECORD(iface, Window, IAccessible_iface); +} + +static HRESULT WINAPI Window_QueryInterface(IAccessible *iface, REFIID riid, void **ppv) +{ + Window *This = impl_from_Window(iface); + + TRACE("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); + + if(IsEqualIID(riid, &IID_IAccessible) || + IsEqualIID(riid, &IID_IDispatch) || + IsEqualIID(riid, &IID_IUnknown)) { + *ppv = iface; + }else if(IsEqualIID(riid, &IID_IOleWindow)) { + *ppv = &This->IOleWindow_iface; + }else { + WARN("no interface: %s\n", debugstr_guid(riid)); + *ppv = NULL; + return E_NOINTERFACE; + } + + IAccessible_AddRef(iface); + return S_OK; +} + +static ULONG WINAPI Window_AddRef(IAccessible *iface) +{ + Window *This = impl_from_Window(iface); + ULONG ref = InterlockedIncrement(&This->ref); + + TRACE("(%p) ref = %u\n", This, ref); + return ref; +} + +static ULONG WINAPI Window_Release(IAccessible *iface) +{ + Window *This = impl_from_Window(iface); + ULONG ref = InterlockedDecrement(&This->ref); + + TRACE("(%p) ref = %u\n", This, ref); + + if(!ref) + heap_free(This); + return ref; +} + +static HRESULT WINAPI Window_GetTypeInfoCount(IAccessible *iface, UINT *pctinfo) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%p)\n", This, pctinfo); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_GetTypeInfo(IAccessible *iface, + UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%u %x %p)\n", This, iTInfo, lcid, ppTInfo); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_GetIDsOfNames(IAccessible *iface, REFIID riid, + LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%s %p %u %x %p)\n", This, debugstr_guid(riid), + rgszNames, cNames, lcid, rgDispId); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_Invoke(IAccessible *iface, DISPID dispIdMember, + REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, + VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%x %s %x %x %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid), + lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accParent(IAccessible *iface, IDispatch **ppdispParent) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%p)\n", This, ppdispParent); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accChildCount(IAccessible *iface, LONG *pcountChildren) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%p)\n", This, pcountChildren); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accChild(IAccessible *iface, + VARIANT varChildID, IDispatch **ppdispChild) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_variant(&varChildID), ppdispChild); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accName(IAccessible *iface, VARIANT varID, BSTR *pszName) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pszName); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accValue(IAccessible *iface, VARIANT varID, BSTR *pszValue) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pszValue); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accDescription(IAccessible *iface, + VARIANT varID, BSTR *pszDescription) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pszDescription); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accRole(IAccessible *iface, VARIANT varID, VARIANT *pvarRole) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pvarRole); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accState(IAccessible *iface, VARIANT varID, VARIANT *pvarState) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pvarState); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accHelp(IAccessible *iface, VARIANT varID, BSTR *pszHelp) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pszHelp); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accHelpTopic(IAccessible *iface, + BSTR *pszHelpFile, VARIANT varID, LONG *pidTopic) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%p %s %p)\n", This, pszHelpFile, debugstr_variant(&varID), pidTopic); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accKeyboardShortcut(IAccessible *iface, + VARIANT varID, BSTR *pszKeyboardShortcut) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pszKeyboardShortcut); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accFocus(IAccessible *iface, VARIANT *pvarID) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%p)\n", This, pvarID); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accSelection(IAccessible *iface, VARIANT *pvarID) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%p)\n", This, pvarID); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_get_accDefaultAction(IAccessible *iface, + VARIANT varID, BSTR *pszDefaultAction) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_variant(&varID), pszDefaultAction); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_accSelect(IAccessible *iface, LONG flagsSelect, VARIANT varID) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%x %s)\n", This, flagsSelect, debugstr_variant(&varID)); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_accLocation(IAccessible *iface, LONG *pxLeft, + LONG *pyTop, LONG *pcxWidth, LONG *pcyHeight, VARIANT varID) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%p %p %p %p %s)\n", This, pxLeft, pyTop, + pcxWidth, pcyHeight, debugstr_variant(&varID)); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_accNavigate(IAccessible *iface, + LONG navDir, VARIANT varStart, VARIANT *pvarEnd) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%d %s %p)\n", This, navDir, debugstr_variant(&varStart), pvarEnd); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_accHitTest(IAccessible *iface, + LONG xLeft, LONG yTop, VARIANT *pvarID) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%d %d %p)\n", This, xLeft, yTop, pvarID); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_accDoDefaultAction(IAccessible *iface, VARIANT varID) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%s)\n", This, debugstr_variant(&varID)); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_put_accName(IAccessible *iface, VARIANT varID, BSTR pszName) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%s %s)\n", This, debugstr_variant(&varID), debugstr_w(pszName)); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_put_accValue(IAccessible *iface, VARIANT varID, BSTR pszValue) +{ + Window *This = impl_from_Window(iface); + FIXME("(%p)->(%s %s)\n", This, debugstr_variant(&varID), debugstr_w(pszValue)); + return E_NOTIMPL; +} + +static const IAccessibleVtbl WindowVtbl = { + Window_QueryInterface, + Window_AddRef, + Window_Release, + Window_GetTypeInfoCount, + Window_GetTypeInfo, + Window_GetIDsOfNames, + Window_Invoke, + Window_get_accParent, + Window_get_accChildCount, + Window_get_accChild, + Window_get_accName, + Window_get_accValue, + Window_get_accDescription, + Window_get_accRole, + Window_get_accState, + Window_get_accHelp, + Window_get_accHelpTopic, + Window_get_accKeyboardShortcut, + Window_get_accFocus, + Window_get_accSelection, + Window_get_accDefaultAction, + Window_accSelect, + Window_accLocation, + Window_accNavigate, + Window_accHitTest, + Window_accDoDefaultAction, + Window_put_accName, + Window_put_accValue +}; + +static inline Window* impl_from_Window_OleWindow(IOleWindow *iface) +{ + return CONTAINING_RECORD(iface, Window, IOleWindow_iface); +} + +static HRESULT WINAPI Window_OleWindow_QueryInterface(IOleWindow *iface, REFIID riid, void **ppv) +{ + Window *This = impl_from_Window_OleWindow(iface); + return IAccessible_QueryInterface(&This->IAccessible_iface, riid, ppv); +} + +static ULONG WINAPI Window_OleWindow_AddRef(IOleWindow *iface) +{ + Window *This = impl_from_Window_OleWindow(iface); + return IAccessible_AddRef(&This->IAccessible_iface); +} + +static ULONG WINAPI Window_OleWindow_Release(IOleWindow *iface) +{ + Window *This = impl_from_Window_OleWindow(iface); + return IAccessible_Release(&This->IAccessible_iface); +} + +static HRESULT WINAPI Window_OleWindow_GetWindow(IOleWindow *iface, HWND *phwnd) +{ + Window *This = impl_from_Window_OleWindow(iface); + FIXME("(%p)->(%p)\n", This, phwnd); + return E_NOTIMPL; +} + +static HRESULT WINAPI Window_OleWindow_ContextSensitiveHelp(IOleWindow *iface, BOOL fEnterMode) +{ + Window *This = impl_from_Window_OleWindow(iface); + FIXME("(%p)->(%x)\n", This, fEnterMode); + return E_NOTIMPL; +} + +static const IOleWindowVtbl WindowOleWindowVtbl = { + Window_OleWindow_QueryInterface, + Window_OleWindow_AddRef, + Window_OleWindow_Release, + Window_OleWindow_GetWindow, + Window_OleWindow_ContextSensitiveHelp +}; + +HRESULT create_window_object(HWND hwnd, const IID *iid, void **obj) +{ + Window *window; + HRESULT hres; + + if(!IsWindow(hwnd)) + return E_FAIL; + + window = heap_alloc_zero(sizeof(Window)); + if(!window) + return E_OUTOFMEMORY; + + window->IAccessible_iface.lpVtbl = &WindowVtbl; + window->IOleWindow_iface.lpVtbl = &WindowOleWindowVtbl; + window->ref = 1; + + hres = IAccessible_QueryInterface(&window->IAccessible_iface, iid, obj); + IAccessible_Release(&window->IAccessible_iface); + return hres; +} diff --git a/dll/win32/oleaut32/recinfo.c b/dll/win32/oleaut32/recinfo.c index f10755eff2d..607cf6f5d85 100644 --- a/dll/win32/oleaut32/recinfo.c +++ b/dll/win32/oleaut32/recinfo.c @@ -166,7 +166,7 @@ static ULONG WINAPI IRecordInfoImpl_Release(IRecordInfo *iface) int i; for(i=0; in_vars; i++) SysFreeString(This->fields[i].name); - HeapFree(GetProcessHeap(), 0, This->name); + SysFreeString(This->name); HeapFree(GetProcessHeap(), 0, This->fields); ITypeInfo_Release(This->pTypeInfo); HeapFree(GetProcessHeap(), 0, This); diff --git a/dll/win32/oleaut32/tmarshal.c b/dll/win32/oleaut32/tmarshal.c index 40647964801..bef37bc6a6d 100644 --- a/dll/win32/oleaut32/tmarshal.c +++ b/dll/win32/oleaut32/tmarshal.c @@ -248,11 +248,13 @@ static HRESULT _get_typeinfo_for_iid(REFIID riid, ITypeInfo**ti) { HRESULT hres; HKEY ikey; + REGSAM opposite = (sizeof(void*) == 8) ? KEY_WOW64_32KEY : KEY_WOW64_64KEY; + BOOL is_wow64; char tlguid[200],typelibkey[300],interfacekey[300],ver[100]; char tlfn[260]; OLECHAR tlfnW[260]; DWORD tlguidlen, verlen, type; - LONG tlfnlen; + LONG tlfnlen, err; ITypeLib *tl; sprintf( interfacekey, "Interface\\{%08x-%04x-%04x-%02x%02x-%02x%02x%02x%02x%02x%02x}\\Typelib", @@ -261,9 +263,14 @@ _get_typeinfo_for_iid(REFIID riid, ITypeInfo**ti) { riid->Data4[4], riid->Data4[5], riid->Data4[6], riid->Data4[7] ); - if (RegOpenKeyA(HKEY_CLASSES_ROOT,interfacekey,&ikey)) { - ERR("No %s key found.\n",interfacekey); - return E_FAIL; + err = RegOpenKeyExA(HKEY_CLASSES_ROOT,interfacekey,0,KEY_READ,&ikey); + if (err && (opposite == KEY_WOW64_32KEY || (IsWow64Process(GetCurrentProcess(), &is_wow64) + && is_wow64))) { + err = RegOpenKeyExA(HKEY_CLASSES_ROOT,interfacekey,0,KEY_READ|opposite,&ikey); + } + if (err) { + ERR("No %s key found.\n",interfacekey); + return E_FAIL; } tlguidlen = sizeof(tlguid); if (RegQueryValueExA(ikey,NULL,NULL,&type,(LPBYTE)tlguid,&tlguidlen)) { @@ -694,7 +701,7 @@ serialize_param( hres = xbuf_add(buf,(LPBYTE)arg,sizeof(DWORD)); return hres; case VT_VARIANT: { - if (debugout) TRACE_(olerelay)("Vt(%s%s)(",debugstr_vt(V_VT((VARIANT *)arg)),debugstr_vf(V_VT((VARIANT *)arg))); + if (debugout) TRACE_(olerelay)("%s", debugstr_variant((VARIANT *)arg)); if (writeit) { ULONG flags = MAKELONG(MSHCTX_DIFFERENTMACHINE, NDR_LOCAL_DATA_REPRESENTATION); diff --git a/dll/win32/oleaut32/typelib.c b/dll/win32/oleaut32/typelib.c index 95d29864545..0a91a209b08 100644 --- a/dll/win32/oleaut32/typelib.c +++ b/dll/win32/oleaut32/typelib.c @@ -581,12 +581,17 @@ HRESULT WINAPI LoadRegTypeLib( TLIBATTR *attr; res = ITypeLib_GetLibAttr(*ppTLib, &attr); - if (res == S_OK && (attr->wMajorVerNum != wVerMajor || attr->wMinorVerNum < wVerMinor)) + if (res == S_OK) { + BOOL mismatch = attr->wMajorVerNum != wVerMajor || attr->wMinorVerNum < wVerMinor; ITypeLib_ReleaseTLibAttr(*ppTLib, attr); - ITypeLib_Release(*ppTLib); - *ppTLib = NULL; - res = TYPE_E_LIBNOTREGISTERED; + + if (mismatch) + { + ITypeLib_Release(*ppTLib); + *ppTLib = NULL; + res = TYPE_E_LIBNOTREGISTERED; + } } } } @@ -872,6 +877,24 @@ HRESULT WINAPI RegisterTypeLib( return res; } +static void TLB_unregister_interface(GUID *guid, REGSAM flag) +{ + WCHAR subKeyName[50]; + HKEY subKey; + + /* the path to the type */ + get_interface_key( guid, subKeyName ); + + /* Delete its bits */ + if (RegOpenKeyExW(HKEY_CLASSES_ROOT, subKeyName, 0, KEY_WRITE | flag, &subKey) != ERROR_SUCCESS) + return; + + RegDeleteKeyW(subKey, ProxyStubClsidW); + RegDeleteKeyW(subKey, ProxyStubClsid32W); + RegDeleteKeyW(subKey, TypeLibW); + RegCloseKey(subKey); + RegDeleteKeyExW(HKEY_CLASSES_ROOT, subKeyName, flag, 0); +} /****************************************************************************** * UnRegisterTypeLib [OLEAUT32.186] @@ -897,7 +920,6 @@ HRESULT WINAPI UnRegisterTypeLib( DWORD i = 0; BOOL deleteOtherStuff; HKEY key = NULL; - HKEY subKey = NULL; TYPEATTR* typeAttr = NULL; TYPEKIND kind; ITypeInfo* typeInfo = NULL; @@ -956,19 +978,16 @@ HRESULT WINAPI UnRegisterTypeLib( if ((kind == TKIND_INTERFACE && (typeAttr->wTypeFlags & TYPEFLAG_FOLEAUTOMATION)) || kind == TKIND_DISPATCH) { - /* the path to the type */ - get_interface_key( &typeAttr->guid, subKeyName ); + BOOL is_wow64; + REGSAM opposite = (sizeof(void*) == 8 ? KEY_WOW64_32KEY : KEY_WOW64_64KEY); - /* Delete its bits */ - if (RegOpenKeyExW(HKEY_CLASSES_ROOT, subKeyName, 0, KEY_WRITE, &subKey) != ERROR_SUCCESS) - goto enddeleteloop; + TLB_unregister_interface(&typeAttr->guid, 0); - RegDeleteKeyW(subKey, ProxyStubClsidW); - RegDeleteKeyW(subKey, ProxyStubClsid32W); - RegDeleteKeyW(subKey, TypeLibW); - RegCloseKey(subKey); - subKey = NULL; - RegDeleteKeyW(HKEY_CLASSES_ROOT, subKeyName); + /* unregister TLBs into the opposite registry view, too */ + if(opposite == KEY_WOW64_32KEY || + (IsWow64Process(GetCurrentProcess(), &is_wow64) && is_wow64)) { + TLB_unregister_interface(&typeAttr->guid, opposite); + } } enddeleteloop: @@ -1014,7 +1033,6 @@ enddeleteloop: end: SysFreeString(tlibPath); if (typeLib) ITypeLib_Release(typeLib); - if (subKey) RegCloseKey(subKey); if (key) RegCloseKey(key); return result; } @@ -1571,61 +1589,6 @@ static void dump_TLBImplType(const TLBImplType * impl, UINT n) } } -static void dump_Variant(const VARIANT * pvar) -{ - SYSTEMTIME st; - - TRACE("%p->{%s%s", pvar, debugstr_VT(pvar), debugstr_VF(pvar)); - - if (pvar) - { - if (V_ISBYREF(pvar) || V_TYPE(pvar) == VT_UNKNOWN || - V_TYPE(pvar) == VT_DISPATCH || V_TYPE(pvar) == VT_RECORD) - { - TRACE(",%p", V_BYREF(pvar)); - } - else if (V_ISARRAY(pvar) || V_ISVECTOR(pvar)) - { - TRACE(",%p", V_ARRAY(pvar)); - } - else switch (V_TYPE(pvar)) - { - case VT_I1: TRACE(",%d", V_I1(pvar)); break; - case VT_UI1: TRACE(",%d", V_UI1(pvar)); break; - case VT_I2: TRACE(",%d", V_I2(pvar)); break; - case VT_UI2: TRACE(",%d", V_UI2(pvar)); break; - case VT_INT: - case VT_I4: TRACE(",%d", V_I4(pvar)); break; - case VT_UINT: - case VT_UI4: TRACE(",%d", V_UI4(pvar)); break; - case VT_I8: TRACE(",0x%08x,0x%08x", (ULONG)(V_I8(pvar) >> 32), - (ULONG)(V_I8(pvar) & 0xffffffff)); break; - case VT_UI8: TRACE(",0x%08x,0x%08x", (ULONG)(V_UI8(pvar) >> 32), - (ULONG)(V_UI8(pvar) & 0xffffffff)); break; - case VT_R4: TRACE(",%3.3e", V_R4(pvar)); break; - case VT_R8: TRACE(",%3.3e", V_R8(pvar)); break; - case VT_BOOL: TRACE(",%s", V_BOOL(pvar) ? "TRUE" : "FALSE"); break; - case VT_BSTR: TRACE(",%s", debugstr_w(V_BSTR(pvar))); break; - case VT_CY: TRACE(",0x%08x,0x%08x", V_CY(pvar).s.Hi, - V_CY(pvar).s.Lo); break; - case VT_DATE: - if(!VariantTimeToSystemTime(V_DATE(pvar), &st)) - TRACE(","); - else - TRACE(",%04d/%02d/%02d %02d:%02d:%02d", st.wYear, st.wMonth, st.wDay, - st.wHour, st.wMinute, st.wSecond); - break; - case VT_ERROR: - case VT_VOID: - case VT_USERDEFINED: - case VT_EMPTY: - case VT_NULL: break; - default: TRACE(",?"); break; - } - } - TRACE("}\n"); -} - static void dump_DispParms(const DISPPARAMS * pdp) { unsigned int index; @@ -1643,7 +1606,7 @@ static void dump_DispParms(const DISPPARAMS * pdp) { TRACE("args:\n"); for (index = 0; index < pdp->cArgs; index++) - dump_Variant( &pdp->rgvarg[index] ); + TRACE(" [%d] %s\n", index, debugstr_variant(pdp->rgvarg+index)); } } @@ -6832,8 +6795,7 @@ DispCallFunc( args[argspos++] = V_UI4(arg); break; } - TRACE("arg %u: type %d\n",i,prgvt[i]); - dump_Variant(arg); + TRACE("arg %u: type %s %s\n", i, debugstr_vt(prgvt[i]), debugstr_variant(arg)); } switch (vtReturn) @@ -6873,7 +6835,7 @@ DispCallFunc( return DISP_E_BADCALLEE; } if (vtReturn != VT_VARIANT) V_VT(pvargResult) = vtReturn; - TRACE("retval: "); dump_Variant(pvargResult); + TRACE("retval: %s\n", debugstr_variant(pvargResult)); return S_OK; #elif defined(__x86_64__) @@ -6922,8 +6884,7 @@ DispCallFunc( args[argspos++] = V_UI8(arg); break; } - TRACE("arg %u: type %d\n",i,prgvt[i]); - dump_Variant(arg); + TRACE("arg %u: type %s %s\n", i, debugstr_vt(prgvt[i]), debugstr_variant(arg)); } switch (vtReturn) @@ -6950,7 +6911,7 @@ DispCallFunc( } heap_free( args ); if (vtReturn != VT_VARIANT) V_VT(pvargResult) = vtReturn; - TRACE("retval: "); dump_Variant(pvargResult); + TRACE("retval: %s\n", debugstr_variant(pvargResult)); return S_OK; #else @@ -7145,7 +7106,7 @@ static HRESULT WINAPI ITypeInfo_fnInvoke( } else if (src_arg) { - dump_Variant(src_arg); + TRACE("%s\n", debugstr_variant(src_arg)); if(rgvt[i]!=V_VT(src_arg)) { @@ -7222,9 +7183,8 @@ static HRESULT WINAPI ITypeInfo_fnInvoke( if (FAILED(hres)) { - ERR("failed to convert param %d to %s%s from %s%s\n", i, - debugstr_vt(rgvt[i]), debugstr_vf(rgvt[i]), - debugstr_VT(src_arg), debugstr_VF(src_arg)); + ERR("failed to convert param %d to %s from %s\n", i, + debugstr_vt(rgvt[i]), debugstr_variant(src_arg)); break; } prgpvarg[i] = &rgvarg[i]; @@ -7316,11 +7276,7 @@ static HRESULT WINAPI ITypeInfo_fnInvoke( continue; else if (wParamFlags & PARAMFLAG_FRETVAL) { - if (TRACE_ON(ole)) - { - TRACE("[retval] value: "); - dump_Variant(prgpvarg[i]); - } + TRACE("[retval] value: %s\n", debugstr_variant(prgpvarg[i])); if (pVarResult) { @@ -7409,8 +7365,7 @@ static HRESULT WINAPI ITypeInfo_fnInvoke( } if (V_VT(&varresult) != VT_ERROR) { - TRACE("varresult value: "); - dump_Variant(&varresult); + TRACE("varresult value: %s\n", debugstr_variant(&varresult)); if (pVarResult) { diff --git a/dll/win32/oleaut32/varformat.c b/dll/win32/oleaut32/varformat.c index 7d092ee9050..39737422c6b 100644 --- a/dll/win32/oleaut32/varformat.c +++ b/dll/win32/oleaut32/varformat.c @@ -1187,9 +1187,8 @@ static HRESULT VARIANT_FormatNumber(LPVARIANT pVarIn, LPOLESTR lpszFormat, const BYTE* pToken = NULL; HRESULT hRes = S_OK; - TRACE("(%p->(%s%s),%s,%p,0x%08x,%p,0x%08x)\n", pVarIn, debugstr_VT(pVarIn), - debugstr_VF(pVarIn), debugstr_w(lpszFormat), rgbTok, dwFlags, pbstrOut, - lcid); + TRACE("(%s,%s,%p,0x%08x,%p,0x%08x)\n", debugstr_variant(pVarIn), debugstr_w(lpszFormat), + rgbTok, dwFlags, pbstrOut, lcid); V_VT(&vString) = VT_EMPTY; V_VT(&vBool) = VT_BOOL; @@ -1598,9 +1597,8 @@ static HRESULT VARIANT_FormatDate(LPVARIANT pVarIn, LPOLESTR lpszFormat, const BYTE* pToken = NULL; HRESULT hRes; - TRACE("(%p->(%s%s),%s,%p,0x%08x,%p,0x%08x)\n", pVarIn, debugstr_VT(pVarIn), - debugstr_VF(pVarIn), debugstr_w(lpszFormat), rgbTok, dwFlags, pbstrOut, - lcid); + TRACE("(%s,%s,%p,0x%08x,%p,0x%08x)\n", debugstr_variant(pVarIn), + debugstr_w(lpszFormat), rgbTok, dwFlags, pbstrOut, lcid); V_VT(&vDate) = VT_EMPTY; @@ -1940,9 +1938,8 @@ static HRESULT VARIANT_FormatString(LPVARIANT pVarIn, LPOLESTR lpszFormat, BOOL bUpper = FALSE; HRESULT hRes = S_OK; - TRACE("(%p->(%s%s),%s,%p,0x%08x,%p,0x%08x)\n", pVarIn, debugstr_VT(pVarIn), - debugstr_VF(pVarIn), debugstr_w(lpszFormat), rgbTok, dwFlags, pbstrOut, - lcid); + TRACE("%s,%s,%p,0x%08x,%p,0x%08x)\n", debugstr_variant(pVarIn), debugstr_w(lpszFormat), + rgbTok, dwFlags, pbstrOut, lcid); V_VT(&vStr) = VT_EMPTY; @@ -2154,9 +2151,8 @@ HRESULT WINAPI VarFormat(LPVARIANT pVarIn, LPOLESTR lpszFormat, BYTE buff[256]; HRESULT hres; - TRACE("(%p->(%s%s),%s,%d,%d,0x%08x,%p)\n", pVarIn, debugstr_VT(pVarIn), - debugstr_VF(pVarIn), debugstr_w(lpszFormat), nFirstDay, nFirstWeek, - dwFlags, pbstrOut); + TRACE("(%s,%s,%d,%d,0x%08x,%p)\n", debugstr_variant(pVarIn), debugstr_w(lpszFormat), + nFirstDay, nFirstWeek, dwFlags, pbstrOut); if (!pbstrOut) return E_INVALIDARG; @@ -2205,8 +2201,7 @@ HRESULT WINAPI VarFormatDateTime(LPVARIANT pVarIn, INT nFormat, ULONG dwFlags, B static WCHAR szEmpty[] = { '\0' }; const BYTE* lpFmt = NULL; - TRACE("(%p->(%s%s),%d,0x%08x,%p)\n", pVarIn, debugstr_VT(pVarIn), - debugstr_VF(pVarIn), nFormat, dwFlags, pbstrOut); + TRACE("%s,%d,0x%08x,%p)\n", debugstr_variant(pVarIn), nFormat, dwFlags, pbstrOut); if (!pVarIn || !pbstrOut || nFormat < 0 || nFormat > 4) return E_INVALIDARG; @@ -2258,8 +2253,8 @@ HRESULT WINAPI VarFormatNumber(LPVARIANT pVarIn, INT nDigits, INT nLeading, INT HRESULT hRet; VARIANT vStr; - TRACE("(%p->(%s%s),%d,%d,%d,%d,0x%08x,%p)\n", pVarIn, debugstr_VT(pVarIn), - debugstr_VF(pVarIn), nDigits, nLeading, nParens, nGrouping, dwFlags, pbstrOut); + TRACE("(%s,%d,%d,%d,%d,0x%08x,%p)\n", debugstr_variant(pVarIn), nDigits, nLeading, + nParens, nGrouping, dwFlags, pbstrOut); if (!pVarIn || !pbstrOut || nDigits > 9) return E_INVALIDARG; @@ -2369,9 +2364,8 @@ HRESULT WINAPI VarFormatPercent(LPVARIANT pVarIn, INT nDigits, INT nLeading, INT HRESULT hRet; VARIANT vDbl; - TRACE("(%p->(%s%s),%d,%d,%d,%d,0x%08x,%p)\n", pVarIn, debugstr_VT(pVarIn), - debugstr_VF(pVarIn), nDigits, nLeading, nParens, nGrouping, - dwFlags, pbstrOut); + TRACE("(%s,%d,%d,%d,%d,0x%08x,%p)\n", debugstr_variant(pVarIn), nDigits, nLeading, + nParens, nGrouping, dwFlags, pbstrOut); if (!pVarIn || !pbstrOut || nDigits > 9) return E_INVALIDARG; @@ -2443,8 +2437,8 @@ HRESULT WINAPI VarFormatCurrency(LPVARIANT pVarIn, INT nDigits, INT nLeading, HRESULT hRet; VARIANT vStr; - TRACE("(%p->(%s%s),%d,%d,%d,%d,0x%08x,%p)\n", pVarIn, debugstr_VT(pVarIn), - debugstr_VF(pVarIn), nDigits, nLeading, nParens, nGrouping, dwFlags, pbstrOut); + TRACE("(%s,%d,%d,%d,%d,0x%08x,%p)\n", debugstr_variant(pVarIn), nDigits, nLeading, + nParens, nGrouping, dwFlags, pbstrOut); if (!pVarIn || !pbstrOut || nDigits > 9) return E_INVALIDARG; diff --git a/dll/win32/oleaut32/variant.c b/dll/win32/oleaut32/variant.c index e6f6372102a..3c7e810f8f0 100644 --- a/dll/win32/oleaut32/variant.c +++ b/dll/win32/oleaut32/variant.c @@ -29,7 +29,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(variant); -const char * const wine_vtypes[VT_CLSID+1] = +static const char * const variant_types[] = { "VT_EMPTY","VT_NULL","VT_I2","VT_I4","VT_R4","VT_R8","VT_CY","VT_DATE", "VT_BSTR","VT_DISPATCH","VT_ERROR","VT_BOOL","VT_VARIANT","VT_UNKNOWN", @@ -39,10 +39,11 @@ const char * const wine_vtypes[VT_CLSID+1] = "VT_RECORD","VT_INT_PTR","VT_UINT_PTR","39","40","41","42","43","44","45", "46","47","48","49","50","51","52","53","54","55","56","57","58","59","60", "61","62","63","VT_FILETIME","VT_BLOB","VT_STREAM","VT_STORAGE", - "VT_STREAMED_OBJECT","VT_STORED_OBJECT","VT_BLOB_OBJECT","VT_CF","VT_CLSID" + "VT_STREAMED_OBJECT","VT_STORED_OBJECT","VT_BLOB_OBJECT","VT_CF","VT_CLSID", + "VT_VERSIONED_STREAM" }; -const char * const wine_vflags[16] = +static const char * const variant_flags[16] = { "", "|VT_VECTOR", @@ -52,14 +53,14 @@ const char * const wine_vflags[16] = "|VT_VECTOR|VT_ARRAY", "|VT_ARRAY|VT_BYREF", "|VT_VECTOR|VT_ARRAY|VT_BYREF", - "|VT_HARDTYPE", - "|VT_VECTOR|VT_HARDTYPE", - "|VT_ARRAY|VT_HARDTYPE", - "|VT_VECTOR|VT_ARRAY|VT_HARDTYPE", - "|VT_BYREF|VT_HARDTYPE", - "|VT_VECTOR|VT_ARRAY|VT_HARDTYPE", - "|VT_ARRAY|VT_BYREF|VT_HARDTYPE", - "|VT_VECTOR|VT_ARRAY|VT_BYREF|VT_HARDTYPE", + "|VT_RESERVED", + "|VT_VECTOR|VT_RESERVED", + "|VT_ARRAY|VT_RESERVED", + "|VT_VECTOR|VT_ARRAY|VT_RESERVED", + "|VT_BYREF|VT_RESERVED", + "|VT_VECTOR|VT_ARRAY|VT_RESERVED", + "|VT_ARRAY|VT_BYREF|VT_RESERVED", + "|VT_VECTOR|VT_ARRAY|VT_BYREF|VT_RESERVED", }; /* Convert a variant from one type to another */ @@ -70,9 +71,8 @@ static inline HRESULT VARIANT_Coerce(VARIANTARG* pd, LCID lcid, USHORT wFlags, VARTYPE vtFrom = V_TYPE(ps); DWORD dwFlags = 0; - TRACE("(%p->(%s%s),0x%08x,0x%04x,%p->(%s%s),%s%s)\n", pd, debugstr_VT(pd), - debugstr_VF(pd), lcid, wFlags, ps, debugstr_VT(ps), debugstr_VF(ps), - debugstr_vt(vt), debugstr_vf(vt)); + TRACE("(%s,0x%08x,0x%04x,%s,%s)\n", debugstr_variant(pd), lcid, wFlags, + debugstr_variant(ps), debugstr_vt(vt)); if (vt == VT_BSTR || vtFrom == VT_BSTR) { @@ -567,7 +567,7 @@ HRESULT VARIANT_ClearInd(VARIANTARG *pVarg) { HRESULT hres; - TRACE("(%p->(%s%s))\n", pVarg, debugstr_VT(pVarg), debugstr_VF(pVarg)); + TRACE("(%s)\n", debugstr_variant(pVarg)); hres = VARIANT_ValidateType(V_VT(pVarg)); if (FAILED(hres)) @@ -639,7 +639,7 @@ HRESULT WINAPI VariantClear(VARIANTARG* pVarg) { HRESULT hres; - TRACE("(%p->(%s%s))\n", pVarg, debugstr_VT(pVarg), debugstr_VF(pVarg)); + TRACE("(%s)\n", debugstr_variant(pVarg)); hres = VARIANT_ValidateType(V_VT(pVarg)); @@ -739,9 +739,7 @@ HRESULT WINAPI VariantCopy(VARIANTARG* pvargDest, VARIANTARG* pvargSrc) { HRESULT hres = S_OK; - TRACE("(%p->(%s%s),%p->(%s%s))\n", pvargDest, debugstr_VT(pvargDest), - debugstr_VF(pvargDest), pvargSrc, debugstr_VT(pvargSrc), - debugstr_VF(pvargSrc)); + TRACE("(%s,%s)\n", debugstr_variant(pvargDest), debugstr_variant(pvargSrc)); if (V_TYPE(pvargSrc) == VT_CLSID || /* VT_CLSID is a special case */ FAILED(VARIANT_ValidateType(V_VT(pvargSrc)))) @@ -804,7 +802,7 @@ static inline size_t VARIANT_DataSize(const VARIANT* pv) case VT_CY: return sizeof(CY); case VT_ERROR: return sizeof(SCODE); } - TRACE("Shouldn't be called for vt %s%s!\n", debugstr_VT(pv), debugstr_VF(pv)); + TRACE("Shouldn't be called for variant %s!\n", debugstr_variant(pv)); return 0; } @@ -842,9 +840,7 @@ HRESULT WINAPI VariantCopyInd(VARIANT* pvargDest, VARIANTARG* pvargSrc) VARTYPE vt; HRESULT hres = S_OK; - TRACE("(%p->(%s%s),%p->(%s%s))\n", pvargDest, debugstr_VT(pvargDest), - debugstr_VF(pvargDest), pvargSrc, debugstr_VT(pvargSrc), - debugstr_VF(pvargSrc)); + TRACE("(%s,%s)\n", debugstr_variant(pvargDest), debugstr_variant(pvargSrc)); if (!V_ISBYREF(pvargSrc)) return VariantCopy(pvargDest, pvargSrc); @@ -930,8 +926,7 @@ VariantCopyInd_Return: if (pSrc != pvargSrc) VariantClear(pSrc); - TRACE("returning 0x%08x, %p->(%s%s)\n", hres, pvargDest, - debugstr_VT(pvargDest), debugstr_VF(pvargDest)); + TRACE("returning 0x%08x, %s\n", hres, debugstr_variant(pvargDest)); return hres; } @@ -985,10 +980,8 @@ HRESULT WINAPI VariantChangeTypeEx(VARIANTARG* pvargDest, VARIANTARG* pvargSrc, { HRESULT res = S_OK; - TRACE("(%p->(%s%s),%p->(%s%s),0x%08x,0x%04x,%s%s)\n", pvargDest, - debugstr_VT(pvargDest), debugstr_VF(pvargDest), pvargSrc, - debugstr_VT(pvargSrc), debugstr_VF(pvargSrc), lcid, wFlags, - debugstr_vt(vt), debugstr_vf(vt)); + TRACE("(%s,%s,0x%08x,0x%04x,%s)\n", debugstr_variant(pvargDest), + debugstr_variant(pvargSrc), lcid, wFlags, debugstr_vt(vt)); if (vt == VT_CLSID) res = DISP_E_BADVARTYPE; @@ -1026,7 +1019,7 @@ HRESULT WINAPI VariantChangeTypeEx(VARIANTARG* pvargDest, VARIANTARG* pvargSrc, if (SUCCEEDED(res)) { V_VT(&vTmp) = vt; - VariantCopy(pvargDest, &vTmp); + res = VariantCopy(pvargDest, &vTmp); } VariantClear(&vTmp); VariantClear(&vSrcDeref); @@ -1036,8 +1029,7 @@ HRESULT WINAPI VariantChangeTypeEx(VARIANTARG* pvargDest, VARIANTARG* pvargSrc, } } - TRACE("returning 0x%08x, %p->(%s%s)\n", res, pvargDest, - debugstr_VT(pvargDest), debugstr_VF(pvargDest)); + TRACE("returning 0x%08x, %s\n", res, debugstr_variant(pvargDest)); return res; } @@ -1343,7 +1335,7 @@ INT WINAPI VariantTimeToSystemTime(double dateIn, LPSYSTEMTIME lpSt) HRESULT WINAPI VarDateFromUdateEx(UDATE *pUdateIn, LCID lcid, ULONG dwFlags, DATE *pDateOut) { UDATE ud; - double dateVal, dateSign; + double dateVal = 0; TRACE("(%p->%d/%d/%d %d:%d:%d:%d %d %d,0x%08x,0x%08x,%p)\n", pUdateIn, pUdateIn->st.wMonth, pUdateIn->st.wDay, pUdateIn->st.wYear, @@ -1353,6 +1345,8 @@ HRESULT WINAPI VarDateFromUdateEx(UDATE *pUdateIn, LCID lcid, ULONG dwFlags, DAT if (lcid != MAKELCID(MAKELANGID(LANG_ENGLISH, SUBLANG_ENGLISH_US), SORT_DEFAULT)) FIXME("lcid possibly not handled, treating as en-us\n"); + if (dwFlags & ~(VAR_TIMEVALUEONLY|VAR_DATEVALUEONLY)) + FIXME("unsupported flags: %x\n", dwFlags); ud = *pUdateIn; @@ -1363,15 +1357,18 @@ HRESULT WINAPI VarDateFromUdateEx(UDATE *pUdateIn, LCID lcid, ULONG dwFlags, DAT return E_INVALIDARG; /* Date */ - dateVal = VARIANT_DateFromJulian(VARIANT_JulianFromDMY(ud.st.wYear, ud.st.wMonth, ud.st.wDay)); + if (!(dwFlags & VAR_TIMEVALUEONLY)) + dateVal = VARIANT_DateFromJulian(VARIANT_JulianFromDMY(ud.st.wYear, ud.st.wMonth, ud.st.wDay)); - /* Sign */ - dateSign = (dateVal < 0.0) ? -1.0 : 1.0; + if ((dwFlags & VAR_TIMEVALUEONLY) || !(dwFlags & VAR_DATEVALUEONLY)) + { + double dateSign = (dateVal < 0.0) ? -1.0 : 1.0; - /* Time */ - dateVal += ud.st.wHour / 24.0 * dateSign; - dateVal += ud.st.wMinute / 1440.0 * dateSign; - dateVal += ud.st.wSecond / 86400.0 * dateSign; + /* Time */ + dateVal += ud.st.wHour / 24.0 * dateSign; + dateVal += ud.st.wMinute / 1440.0 * dateSign; + dateVal += ud.st.wSecond / 86400.0 * dateSign; + } TRACE("Returning %g\n", dateVal); *pDateOut = dateVal; @@ -2517,8 +2514,7 @@ HRESULT WINAPI VarCat(LPVARIANT left, LPVARIANT right, LPVARIANT out) leftvt = V_VT(left); rightvt = V_VT(right); - TRACE("(%p->(%s%s),%p->(%s%s),%p)\n", left, debugstr_VT(left), - debugstr_VF(left), right, debugstr_VT(right), debugstr_VF(right), out); + TRACE("%s,%s,%p)\n", debugstr_variant(left), debugstr_variant(right), out); if (!str_true[0]) { VARIANT_GetLocalisedText(LOCALE_USER_DEFAULT, IDS_FALSE, str_false); @@ -2761,8 +2757,7 @@ HRESULT WINAPI VarCmp(LPVARIANT left, LPVARIANT right, LCID lcid, DWORD flags) DWORD xmask; HRESULT rc; - TRACE("(%p->(%s%s),%p->(%s%s),0x%08x,0x%08x)\n", left, debugstr_VT(left), - debugstr_VF(left), right, debugstr_VT(right), debugstr_VF(right), lcid, flags); + TRACE("(%s,%s,0x%08x,0x%08x)\n", debugstr_variant(left), debugstr_variant(right), lcid, flags); lvt = V_VT(left) & VT_TYPEMASK; rvt = V_VT(right) & VT_TYPEMASK; @@ -2966,8 +2961,7 @@ HRESULT WINAPI VarAnd(LPVARIANT left, LPVARIANT right, LPVARIANT result) VariantInit(&tempLeft); VariantInit(&tempRight); - TRACE("(%p->(%s%s),%p->(%s%s),%p)\n", left, debugstr_VT(left), - debugstr_VF(left), right, debugstr_VT(right), debugstr_VF(right), result); + TRACE("(%s,%s,%p)\n", debugstr_variant(left), debugstr_variant(right), result); /* Handle VT_DISPATCH by storing and taking address of returned value */ if ((V_VT(left) & VT_TYPEMASK) == VT_DISPATCH) @@ -3012,7 +3006,6 @@ HRESULT WINAPI VarAnd(LPVARIANT left, LPVARIANT right, LPVARIANT result) else if (leftvt == VT_I4 || rightvt == VT_I4 || leftvt == VT_UINT || rightvt == VT_UINT || leftvt == VT_INT || rightvt == VT_INT || - leftvt == VT_UINT || rightvt == VT_UINT || leftvt == VT_R4 || rightvt == VT_R4 || leftvt == VT_R8 || rightvt == VT_R8 || leftvt == VT_CY || rightvt == VT_CY || @@ -3221,9 +3214,7 @@ HRESULT WINAPI VarAdd(LPVARIANT left, LPVARIANT right, LPVARIANT result) vt_ERROR, vt_ERROR, vt_UI1, vt_ERROR, vt_ERROR, vt_I8 }; - TRACE("(%p->(%s%s),%p->(%s%s),%p)\n", left, debugstr_VT(left), - debugstr_VF(left), right, debugstr_VT(right), debugstr_VF(right), - result); + TRACE("(%s,%s,%p)\n", debugstr_variant(left), debugstr_variant(right), result); VariantInit(&lv); VariantInit(&rv); @@ -3377,7 +3368,7 @@ end: VariantClear(&tv); VariantClear(&tempLeft); VariantClear(&tempRight); - TRACE("returning 0x%8x (variant type %s)\n", hres, debugstr_VT(result)); + TRACE("returning 0x%8x %s\n", hres, debugstr_variant(result)); return hres; } @@ -3434,9 +3425,7 @@ HRESULT WINAPI VarMul(LPVARIANT left, LPVARIANT right, LPVARIANT result) vt_ERROR, vt_ERROR, vt_UI1, vt_ERROR, vt_ERROR, vt_I8 }; - TRACE("(%p->(%s%s),%p->(%s%s),%p)\n", left, debugstr_VT(left), - debugstr_VF(left), right, debugstr_VT(right), debugstr_VF(right), - result); + TRACE("(%s,%s,%p)\n", debugstr_variant(left), debugstr_variant(right), result); VariantInit(&lv); VariantInit(&rv); @@ -3568,7 +3557,7 @@ end: VariantClear(&tv); VariantClear(&tempLeft); VariantClear(&tempRight); - TRACE("returning 0x%8x (variant type %s)\n", hres, debugstr_VT(result)); + TRACE("returning 0x%8x %s\n", hres, debugstr_variant(result)); return hres; } @@ -3600,8 +3589,7 @@ HRESULT WINAPI VarDiv(LPVARIANT left, LPVARIANT right, LPVARIANT result) VariantInit(&lv); VariantInit(&rv); - TRACE("(%p->(%s%s),%p->(%s%s),%p)\n", left, debugstr_VT(left), - debugstr_VF(left), right, debugstr_VT(right), debugstr_VF(right), result); + TRACE("(%s,%s,%p)\n", debugstr_variant(left), debugstr_variant(right), result); /* Handle VT_DISPATCH by storing and taking address of returned value */ if ((V_VT(left) & VT_TYPEMASK) == VT_DISPATCH) @@ -3731,7 +3719,7 @@ end: VariantClear(&rv); VariantClear(&tempLeft); VariantClear(&tempRight); - TRACE("returning 0x%8x (variant type %s)\n", hres, debugstr_VT(result)); + TRACE("returning 0x%8x %s\n", hres, debugstr_variant(result)); return hres; } @@ -3763,8 +3751,7 @@ HRESULT WINAPI VarSub(LPVARIANT left, LPVARIANT right, LPVARIANT result) VariantInit(&tempLeft); VariantInit(&tempRight); - TRACE("(%p->(%s%s),%p->(%s%s),%p)\n", left, debugstr_VT(left), - debugstr_VF(left), right, debugstr_VT(right), debugstr_VF(right), result); + TRACE("(%s,%s,%p)\n", debugstr_variant(left), debugstr_variant(right), result); if ((V_VT(left) & VT_TYPEMASK) == VT_DISPATCH && (V_VT(left)&(~VT_TYPEMASK)) == 0 && @@ -3998,7 +3985,7 @@ end: VariantClear(&rv); VariantClear(&tempLeft); VariantClear(&tempRight); - TRACE("returning 0x%8x (variant type %s)\n", hres, debugstr_VT(result)); + TRACE("returning 0x%8x %s\n", hres, debugstr_variant(result)); return hres; } @@ -4034,9 +4021,7 @@ HRESULT WINAPI VarOr(LPVARIANT pVarLeft, LPVARIANT pVarRight, LPVARIANT pVarOut) VariantInit(&varRight); VariantInit(&varStr); - TRACE("(%p->(%s%s),%p->(%s%s),%p)\n", pVarLeft, debugstr_VT(pVarLeft), - debugstr_VF(pVarLeft), pVarRight, debugstr_VT(pVarRight), - debugstr_VF(pVarRight), pVarOut); + TRACE("(%s,%s,%p)\n", debugstr_variant(pVarLeft), debugstr_variant(pVarRight), pVarOut); /* Handle VT_DISPATCH by storing and taking address of returned value */ if ((V_VT(pVarLeft) & VT_TYPEMASK) == VT_DISPATCH) @@ -4343,8 +4328,7 @@ HRESULT WINAPI VarAbs(LPVARIANT pVarIn, LPVARIANT pVarOut) VariantInit(&temp); - TRACE("(%p->(%s%s),%p)\n", pVarIn, debugstr_VT(pVarIn), - debugstr_VF(pVarIn), pVarOut); + TRACE("(%s,%p)\n", debugstr_variant(pVarIn), pVarOut); /* Handle VT_DISPATCH by storing and taking address of returned value */ if ((V_VT(pVarIn) & VT_TYPEMASK) == VT_DISPATCH && ((V_VT(pVarIn) & ~VT_TYPEMASK) == 0)) @@ -4447,8 +4431,7 @@ HRESULT WINAPI VarFix(LPVARIANT pVarIn, LPVARIANT pVarOut) VariantInit(&temp); - TRACE("(%p->(%s%s),%p)\n", pVarIn, debugstr_VT(pVarIn), - debugstr_VF(pVarIn), pVarOut); + TRACE("(%s,%p)\n", debugstr_variant(pVarIn), pVarOut); /* Handle VT_DISPATCH by storing and taking address of returned value */ if ((V_VT(pVarIn) & VT_TYPEMASK) == VT_DISPATCH && ((V_VT(pVarIn) & ~VT_TYPEMASK) == 0)) @@ -4554,8 +4537,7 @@ HRESULT WINAPI VarInt(LPVARIANT pVarIn, LPVARIANT pVarOut) VariantInit(&temp); - TRACE("(%p->(%s%s),%p)\n", pVarIn, debugstr_VT(pVarIn), - debugstr_VF(pVarIn), pVarOut); + TRACE("(%s,%p)\n", debugstr_variant(pVarIn), pVarOut); /* Handle VT_DISPATCH by storing and taking address of returned value */ if ((V_VT(pVarIn) & VT_TYPEMASK) == VT_DISPATCH && ((V_VT(pVarIn) & ~VT_TYPEMASK) == 0)) @@ -4629,9 +4611,7 @@ HRESULT WINAPI VarXor(LPVARIANT pVarLeft, LPVARIANT pVarRight, LPVARIANT pVarOut double d; HRESULT hRet; - TRACE("(%p->(%s%s),%p->(%s%s),%p)\n", pVarLeft, debugstr_VT(pVarLeft), - debugstr_VF(pVarLeft), pVarRight, debugstr_VT(pVarRight), - debugstr_VF(pVarRight), pVarOut); + TRACE("(%s,%s,%p)\n", debugstr_variant(pVarLeft), debugstr_variant(pVarRight), pVarOut); if (V_EXTRA_TYPE(pVarLeft) || V_EXTRA_TYPE(pVarRight) || V_VT(pVarLeft) > VT_UINT || V_VT(pVarRight) > VT_UINT || @@ -4808,9 +4788,7 @@ HRESULT WINAPI VarEqv(LPVARIANT pVarLeft, LPVARIANT pVarRight, LPVARIANT pVarOut { HRESULT hRet; - TRACE("(%p->(%s%s),%p->(%s%s),%p)\n", pVarLeft, debugstr_VT(pVarLeft), - debugstr_VF(pVarLeft), pVarRight, debugstr_VT(pVarRight), - debugstr_VF(pVarRight), pVarOut); + TRACE("(%s,%s,%p)\n", debugstr_variant(pVarLeft), debugstr_variant(pVarRight), pVarOut); hRet = VarXor(pVarLeft, pVarRight, pVarOut); if (SUCCEEDED(hRet)) @@ -4867,8 +4845,7 @@ HRESULT WINAPI VarNeg(LPVARIANT pVarIn, LPVARIANT pVarOut) VariantInit(&temp); - TRACE("(%p->(%s%s),%p)\n", pVarIn, debugstr_VT(pVarIn), - debugstr_VF(pVarIn), pVarOut); + TRACE("(%s,%p)\n", debugstr_variant(pVarIn), pVarOut); /* Handle VT_DISPATCH by storing and taking address of returned value */ if ((V_VT(pVarIn) & VT_TYPEMASK) == VT_DISPATCH && ((V_VT(pVarIn) & ~VT_TYPEMASK) == 0)) @@ -4997,8 +4974,7 @@ HRESULT WINAPI VarNot(LPVARIANT pVarIn, LPVARIANT pVarOut) VariantInit(&temp); - TRACE("(%p->(%s%s),%p)\n", pVarIn, debugstr_VT(pVarIn), - debugstr_VF(pVarIn), pVarOut); + TRACE("(%s,%p)\n", debugstr_variant(pVarIn), pVarOut); /* Handle VT_DISPATCH by storing and taking address of returned value */ if ((V_VT(pVarIn) & VT_TYPEMASK) == VT_DISPATCH && ((V_VT(pVarIn) & ~VT_TYPEMASK) == 0)) @@ -5122,7 +5098,7 @@ HRESULT WINAPI VarRound(LPVARIANT pVarIn, int deci, LPVARIANT pVarOut) VariantInit(&temp); - TRACE("(%p->(%s%s),%d)\n", pVarIn, debugstr_VT(pVarIn), debugstr_VF(pVarIn), deci); + TRACE("(%s,%d)\n", debugstr_variant(pVarIn), deci); /* Handle VT_DISPATCH by storing and taking address of returned value */ if ((V_VT(pVarIn) & VT_TYPEMASK) == VT_DISPATCH && ((V_VT(pVarIn) & ~VT_TYPEMASK) == 0)) @@ -5227,10 +5203,7 @@ VarRound_Exit: V_VT(pVarOut) = VT_EMPTY; VariantClear(&temp); - TRACE("returning 0x%08x (%s%s),%f\n", hRet, debugstr_VT(pVarOut), - debugstr_VF(pVarOut), (V_VT(pVarOut) == VT_R4) ? V_R4(pVarOut) : - (V_VT(pVarOut) == VT_R8) ? V_R8(pVarOut) : 0); - + TRACE("returning 0x%08x %s\n", hRet, debugstr_variant(pVarOut)); return hRet; } @@ -5260,8 +5233,7 @@ HRESULT WINAPI VarIdiv(LPVARIANT left, LPVARIANT right, LPVARIANT result) VARIANT lv,rv; VARIANT tempLeft, tempRight; - TRACE("(%p->(%s%s),%p->(%s%s),%p)\n", left, debugstr_VT(left), - debugstr_VF(left), right, debugstr_VT(right), debugstr_VF(right), result); + TRACE("(%s,%s,%p)\n", debugstr_variant(left), debugstr_variant(right), result); VariantInit(&lv); VariantInit(&rv); @@ -5419,8 +5391,7 @@ HRESULT WINAPI VarMod(LPVARIANT left, LPVARIANT right, LPVARIANT result) VariantInit(&lv); VariantInit(&rv); - TRACE("(%p->(%s%s),%p->(%s%s),%p)\n", left, debugstr_VT(left), - debugstr_VF(left), right, debugstr_VT(right), debugstr_VF(right), result); + TRACE("(%s,%s,%p)\n", debugstr_variant(left), debugstr_variant(right), result); /* Handle VT_DISPATCH by storing and taking address of returned value */ if ((V_VT(left) & VT_TYPEMASK) == VT_DISPATCH) @@ -5658,8 +5629,7 @@ HRESULT WINAPI VarPow(LPVARIANT left, LPVARIANT right, LPVARIANT result) VARTYPE rightExtraFlags,leftExtraFlags,ExtraFlags; VARIANT tempLeft, tempRight; - TRACE("(%p->(%s%s),%p->(%s%s),%p)\n", left, debugstr_VT(left), debugstr_VF(left), - right, debugstr_VT(right), debugstr_VF(right), result); + TRACE("(%s,%s,%p)\n", debugstr_variant(left), debugstr_variant(right), result); VariantInit(&dl); VariantInit(&dr); @@ -5779,8 +5749,7 @@ HRESULT WINAPI VarImp(LPVARIANT left, LPVARIANT right, LPVARIANT result) VariantInit(&tempLeft); VariantInit(&tempRight); - TRACE("(%p->(%s%s),%p->(%s%s),%p)\n", left, debugstr_VT(left), - debugstr_VF(left), right, debugstr_VT(right), debugstr_VF(right), result); + TRACE("(%s,%s,%p)\n", debugstr_variant(left), debugstr_variant(right), result); /* Handle VT_DISPATCH by storing and taking address of returned value */ if ((V_VT(left) & VT_TYPEMASK) == VT_DISPATCH) diff --git a/dll/win32/oleaut32/variant.h b/dll/win32/oleaut32/variant.h index dceac5c7e56..79239f861f7 100644 --- a/dll/win32/oleaut32/variant.h +++ b/dll/win32/oleaut32/variant.h @@ -45,15 +45,6 @@ #define VTBIT_VARIANT (1 << VT_VARIANT) #define VTBIT_15 (1 << 15) /* no variant type with this number */ -extern const char * const wine_vtypes[] DECLSPEC_HIDDEN; -#define debugstr_vt(v) (((v)&VT_TYPEMASK) <= VT_CLSID ? wine_vtypes[((v)&VT_TYPEMASK)] : \ - ((v)&VT_TYPEMASK) == VT_BSTR_BLOB ? "VT_BSTR_BLOB": "Invalid") -#define debugstr_VT(v) (!(v) ? "(null)" : debugstr_vt(V_TYPE((v)))) - -extern const char * const wine_vflags[] DECLSPEC_HIDDEN; -#define debugstr_vf(v) (wine_vflags[((v)&VT_EXTRA_TYPE)>>12]) -#define debugstr_VF(v) (!(v) ? "(null)" : debugstr_vf(V_EXTRA_TYPE(v))) - /* Size constraints */ #define I1_MAX 0x7f #define I1_MIN ((-I1_MAX)-1) diff --git a/dll/win32/oleaut32/vartype.c b/dll/win32/oleaut32/vartype.c index a3103872844..5a8f0d1d4b6 100644 --- a/dll/win32/oleaut32/vartype.c +++ b/dll/win32/oleaut32/vartype.c @@ -4154,6 +4154,8 @@ static HRESULT VARIANT_DI_FromR4(float source, VARIANT_DI * dest); static HRESULT VARIANT_DI_FromR8(double source, VARIANT_DI * dest); static void VARIANT_DIFromDec(const DECIMAL * from, VARIANT_DI * to); static void VARIANT_DecFromDI(const VARIANT_DI * from, DECIMAL * to); +static unsigned char VARIANT_int_divbychar(DWORD * p, unsigned int n, unsigned char divisor); +static BOOL VARIANT_int_iszero(const DWORD * p, unsigned int n); /************************************************************************ * VarDecFromR4 (OLEAUT32.193) @@ -4429,12 +4431,13 @@ HRESULT WINAPI VarDecFromUI8(ULONG64 ullIn, DECIMAL* pDecOut) /* Make two DECIMALS the same scale; used by math functions below */ static HRESULT VARIANT_DecScale(const DECIMAL** ppDecLeft, const DECIMAL** ppDecRight, - DECIMAL* pDecOut) + DECIMAL pDecOut[2]) { static DECIMAL scaleFactor; + unsigned char remainder; DECIMAL decTemp; + VARIANT_DI di; int scaleAmount, i; - HRESULT hRet = S_OK; if (DEC_SIGN(*ppDecLeft) & ~DECIMAL_NEG || DEC_SIGN(*ppDecRight) & ~DECIMAL_NEG) return E_INVALIDARG; @@ -4449,27 +4452,62 @@ static HRESULT VARIANT_DecScale(const DECIMAL** ppDecLeft, if (scaleAmount > 0) { decTemp = *(*ppDecRight); /* Left is bigger - scale the right hand side */ - *ppDecRight = pDecOut; + *ppDecRight = &pDecOut[0]; } else { decTemp = *(*ppDecLeft); /* Right is bigger - scale the left hand side */ - *ppDecLeft = pDecOut; - i = scaleAmount = -scaleAmount; + *ppDecLeft = &pDecOut[0]; + i = -scaleAmount; } - if (DEC_SCALE(&decTemp) + scaleAmount > DEC_MAX_SCALE) - return DISP_E_OVERFLOW; /* Can't scale up */ - - /* Multiply up the value to be scaled by the correct amount */ - while (SUCCEEDED(hRet) && i--) + /* Multiply up the value to be scaled by the correct amount (if possible) */ + while (i > 0 && SUCCEEDED(VarDecMul(&decTemp, &scaleFactor, &pDecOut[0]))) { - /* Note we are multiplying by a value with a scale of 0, so we don't recurse */ - hRet = VarDecMul(&decTemp, &scaleFactor, pDecOut); - decTemp = *pDecOut; + decTemp = pDecOut[0]; + i--; } - DEC_SCALE(pDecOut) += scaleAmount; /* Set the new scale */ - return hRet; + + if (!i) + { + DEC_SCALE(&pDecOut[0]) += (scaleAmount > 0) ? scaleAmount : (-scaleAmount); + return S_OK; /* Same scale */ + } + + /* Scaling further not possible, reduce accuracy of other argument */ + pDecOut[0] = decTemp; + if (scaleAmount > 0) + { + DEC_SCALE(&pDecOut[0]) += scaleAmount - i; + VARIANT_DIFromDec(*ppDecLeft, &di); + *ppDecLeft = &pDecOut[1]; + } + else + { + DEC_SCALE(&pDecOut[0]) += (-scaleAmount) - i; + VARIANT_DIFromDec(*ppDecRight, &di); + *ppDecRight = &pDecOut[1]; + } + + di.scale -= i; + remainder = 0; + while (i-- > 0 && !VARIANT_int_iszero(di.bitsnum, sizeof(di.bitsnum)/sizeof(DWORD))) + { + remainder = VARIANT_int_divbychar(di.bitsnum, sizeof(di.bitsnum)/sizeof(DWORD), 10); + if (remainder > 0) WARN("losing significant digits (remainder %u)...\n", remainder); + } + + /* round up the result - native oleaut32 does this */ + if (remainder >= 5) { + for (remainder = 1, i = 0; i < sizeof(di.bitsnum)/sizeof(DWORD) && remainder; i++) { + ULONGLONG digit = di.bitsnum[i] + 1; + remainder = (digit > 0xFFFFFFFF) ? 1 : 0; + di.bitsnum[i] = digit & 0xFFFFFFFF; + } + } + + VARIANT_DecFromDI(&di, &pDecOut[1]); + return S_OK; } /* Add two unsigned 32 bit values with overflow */ @@ -4544,9 +4582,9 @@ static inline int VARIANT_DecCmp(const DECIMAL *pDecLeft, const DECIMAL *pDecRig HRESULT WINAPI VarDecAdd(const DECIMAL* pDecLeft, const DECIMAL* pDecRight, DECIMAL* pDecOut) { HRESULT hRet; - DECIMAL scaled; + DECIMAL scaled[2]; - hRet = VARIANT_DecScale(&pDecLeft, &pDecRight, &scaled); + hRet = VARIANT_DecScale(&pDecLeft, &pDecRight, scaled); if (SUCCEEDED(hRet)) { diff --git a/dll/win32/rasdlg/lang/tr-TR.rc b/dll/win32/rasdlg/lang/tr-TR.rc new file mode 100644 index 00000000000..fa9178be6f8 --- /dev/null +++ b/dll/win32/rasdlg/lang/tr-TR.rc @@ -0,0 +1,2375 @@ +/* TRANSLATOR: 2014 Erdem Ersoy (eersoy93) (erdemersoy@live.com) */ + +LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT + +102 DIALOGEX 0, 0, 255, 265 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Başka Telefon Numaraları" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Bu bağlantıyı yapmak için kullanmak istediğiniz başka telefon numaralarını belirtiniz.", 1018, 7, 5, 243, 16 + LTEXT "&Telefon Numaraları:", 1019, 7, 27, 238, 8 + CONTROL "", 1012, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x0000848D, 7, 38, 217, 144 + PUSHBUTTON "&Yukarı Taşı", 1017, 230, 40, 18, 16, BS_ICON + PUSHBUTTON "&Aşağı Taşı", 1015, 230, 61, 18, 16, BS_ICON + PUSHBUTTON "&Ekle...", 1013, 7, 187, 70, 14 + PUSHBUTTON "&Düzenle...", 1016, 81, 187, 70, 14 + PUSHBUTTON "&Sil", 1014, 154, 187, 70, 14 + AUTOCHECKBOX "E&ğer Numara Olamıyorsa Bir Sonraki Numarayı Dene", 1011, 8, 210, 243, 10, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "&Başarılı Numarayı Dizelgenin En Üstüne Taşı", 1010, 8, 228, 243, 10, BS_TOP | BS_MULTILINE + DEFPUSHBUTTON "Tamam", 1, 122, 245, 60, 14 + PUSHBUTTON "İptal", 2, 188, 245, 60, 14 +END + +103 DIALOGEX 6, 18, 250, 170 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION +CAPTION "Ağ Bağlantıları" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "", 1029, 5, 5, 241, 35, NOT WS_GROUP + LTEXT "&Bağlantılar:", -1, 5, 46, 238, 10 + CONTROL "List1", 1677, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x0000440D, 5, 57, 240, 57 + AUTOCHECKBOX "B&ir Dahaki Kez Oturum Açana Dek Bana Bir Daha Sorma", 1022, 8, 125, 235, 10 + PUSHBUTTON "&Ayarlar", 1026, 7, 149, 60, 14 + DEFPUSHBUTTON "Ba&ğlan...", 1024, 117, 149, 60, 14 + PUSHBUTTON "İptal", 1025, 183, 149, 60, 14 +END + +104 DIALOGEX 6, 18, 269, 263 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Line Bundling Errors" +FONT 8, "MS Shell Dlg" +BEGIN + ICON 32516, 1031, 7, 7, 20, 20 + LTEXT "One or more additional lines did not connect. ", 1033, 37, 8, 216, 20 + CONTROL "", 1032, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x00008401, 37, 83, 224, 136 + AUTOCHECKBOX "&Do not attempt failed lines in the future", 1030, 38, 226, 222, 10 + DEFPUSHBUTTON "&Accept", 1, 135, 242, 60, 14 + PUSHBUTTON "&Hang Up", 2, 201, 242, 60, 14 + LTEXT "If only a single line connected, the server may not be configured to accept multi-link calls. Check 'Do not attempt failed lines' to avoid unnecessary connection charges in such a case.", -1, 37, 36, 224, 44 +END + +105 DIALOGEX 0, 0, 261, 253 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Advanced Security Settings" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Logon security", 1547, 7, 33, 246, 191 + LTEXT "&Data encryption:", 1546, 7, 5, 247, 10 + COMBOBOX 1495, 7, 17, 247, 76, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + AUTORADIOBUTTON "Use &Extensible Authentication Protocol (EAP)", 1544, 17, 47, 226, 8, WS_GROUP + LTEXT "EAP Type", -1, 18, 64, 35, 8, NOT WS_VISIBLE | NOT WS_GROUP + COMBOBOX 1034, 53, 62, 191, 42, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP + PUSHBUTTON "P&roperties", 1035, 184, 77, 60, 14 + AUTORADIOBUTTON "Allow these &protocols", 1545, 17, 92, 224, 10 + AUTOCHECKBOX "&Unencrypted password (PAP)", 1491, 28, 105, 215, 10, BS_TOP | BS_MULTILINE | WS_GROUP + AUTOCHECKBOX "&Shiva Password Authentication Protocol (SPAP)", 1496, 28, 119, 214, 10, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "&Challenge Handshake Authentication Protocol (CHAP)", 1494, 28, 133, 215, 10, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "&MS CHAP (MS-CHAP)", 1493, 28, 148, 212, 10, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "Allow older MS-CHAP version for &Win 95 servers", 200, 46, 162, 198, 10, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "M&icrosoft CHAP Version 2 (MS-CHAP v2)", 1492, 28, 176, 200, 10, BS_TOP | BS_MULTILINE + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 28, 189, 208, 1 + AUTOCHECKBOX "&For MS-CHAP based protocols, automatically use my ReactOS logon name and password (and domain if any)", 1549, 28, 195, 213, 24, BS_TOP | BS_MULTILINE + DEFPUSHBUTTON "OK", 1, 127, 232, 60, 14 + PUSHBUTTON "Cancel", 2, 192, 232, 60, 14 +END + +106 DIALOGEX 6, 18, 255, 109 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Connection Complete" +FONT 8, "MS Shell Dlg" +BEGIN + DEFPUSHBUTTON "OK", 1, 97, 91, 60, 14 + ICON 563, 1046, 7, 7, 20, 20 + LTEXT "'Connection name' is now connected.", 1047, 40, 7, 212, 16 + LTEXT "To check the status of this connection or disconnect, right-click its icon in the Network Connections folder, or click its icon on the taskbar (if present).", -1, 40, 30, 212, 34 + AUTOCHECKBOX "&Do not display this message again", 1045, 40, 69, 212, 10, BS_TOP | BS_MULTILINE +END + +107 DIALOGEX 0, 0, 258, 167 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Phone number", 1053, 7, 5, 243, 92 + LTEXT "&Area code:", 1055, 18, 17, 54, 8 + COMBOBOX 1049, 17, 30, 55, 129, CBS_DROPDOWN | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "&Phone number:", 1057, 77, 17, 166, 8, NOT WS_GROUP + EDITTEXT 1051, 77, 30, 163, 14, ES_AUTOHSCROLL + LTEXT "&Country/region code:", 1056, 18, 48, 221, 8, NOT WS_GROUP + COMBOBOX 1054, 17, 61, 224, 93, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP + AUTOCHECKBOX "&Use dialing rules", 1048, 20, 81, 219, 10, BS_TOP | BS_MULTILINE + GROUPBOX "Co&mment", 1052, 7, 102, 243, 36 + EDITTEXT 1050, 17, 115, 224, 14, ES_AUTOHSCROLL + DEFPUSHBUTTON "OK", 1, 127, 147, 60, 14 + PUSHBUTTON "Cancel", 2, 191, 147, 60, 14 +END + +108 DIALOGEX 6, 18, 222, 104 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Change Password" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Your password on the remote network has expired. Enter passwords, then press OK to set a new one.", 1062, 7, 5, 210, 24 + LTEXT "&New password:", 1064, 8, 43, 108, 8 + EDITTEXT 1060, 118, 38, 98, 14, ES_PASSWORD | ES_AUTOHSCROLL + LTEXT "&Confirm new password:", 1061, 8, 61, 102, 8 + EDITTEXT 1058, 118, 57, 98, 14, ES_PASSWORD | ES_AUTOHSCROLL + DEFPUSHBUTTON "OK", 1, 90, 84, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 154, 84, 60, 14 +END + +109 DIALOGEX 6, 18, 223, 122 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Change Password" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Your password on the remote network has expired. Enter passwords, then press OK to set a new one.", 1062, 7, 5, 212, 29 + LTEXT "&Old password:", 1063, 7, 42, 108, 8 + EDITTEXT 1059, 116, 38, 100, 14, ES_PASSWORD | ES_AUTOHSCROLL + LTEXT "&New password:", 1064, 7, 60, 108, 8 + EDITTEXT 1060, 116, 56, 100, 14, ES_PASSWORD | ES_AUTOHSCROLL + LTEXT "&Confirm new password:", 1061, 7, 78, 108, 8 + EDITTEXT 1058, 116, 74, 100, 14, ES_PASSWORD | ES_AUTOHSCROLL + DEFPUSHBUTTON "OK", 1, 92, 101, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 156, 101, 60, 14 +END + +110 DIALOGEX 12, 16, 230, 105 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Callback" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "You have 'Set By Caller' callback privilege on the server. Press OK and the server will call you back at the number below. Press Cancel to skip callback.", 1066, 5, 5, 221, 39, SS_NOPREFIX + LTEXT "&Enter your modem's phone number:", 1067, 5, 46, 222, 8, NOT WS_GROUP + EDITTEXT 1065, 5, 57, 221, 14, ES_AUTOHSCROLL + DEFPUSHBUTTON "OK", 1, 100, 85, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 164, 85, 60, 14 +END + +111 DIALOGEX 6, 19, 265, 135 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Error Connecting to %1" +FONT 8, "MS Shell Dlg" +BEGIN + ICON 32515, 1068, 7, 7, 20, 20, WS_GROUP + LTEXT "", 1070, 34, 7, 226, 105 + DEFPUSHBUTTON "Do not dial=88", 1, 4, 117, 128, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 136, 117, 60, 14 + PUSHBUTTON "&More Info", 1069, 200, 117, 60, 14 +END + +112 DIALOGEX 6, 18, 263, 219 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Automatic Dialing And Hanging Up" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "ReactOS can automatically dial and hang up devices depending on how much information is being sent and received.", 1085, 9, 7, 253, 30 + GROUPBOX "Automatic dialing", -1, 6, 38, 249, 71 + LTEXT "Dial another line when this connection meets both of the following conditions:", 1083, 16, 51, 237, 16, NOT WS_GROUP + LTEXT "Activity at &least:", -1, 16, 73, 100, 8 + COMBOBOX 1079, 117, 70, 60, 100, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "&Duration at least:", 1084, 16, 92, 99, 8, NOT WS_GROUP + COMBOBOX 1080, 117, 89, 90, 162, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + GROUPBOX "Automatic hangup", -1, 6, 113, 248, 81 + LTEXT "Hang up any device used for this connection when it meets both of the following conditions:", 1086, 16, 127, 230, 18, NOT WS_GROUP + LTEXT "Activity no &more than:", -1, 16, 150, 92, 8 + COMBOBOX 1081, 115, 146, 60, 100, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "D&uration at least:", 1087, 16, 168, 92, 8, NOT WS_GROUP + COMBOBOX 1082, 115, 166, 90, 151, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + DEFPUSHBUTTON "OK", 1, 131, 199, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 194, 199, 60, 14 +END + +113 DIALOGEX 21, 46, 225, 65 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION +CAPTION "Connecting %1..." +FONT 8, "MS Shell Dlg" +BEGIN + ICON 563, 1417, 7, 7, 20, 20 + LTEXT "", 1097, 36, 7, 185, 35, SS_NOPREFIX + PUSHBUTTON "Cancel", 2, 83, 47, 60, 14 +END + +114 DIALOGEX 6, 18, 225, 60 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Dial-Up Networking" +FONT 8, "MS Shell Dlg" +BEGIN + ICON 563, 1098, 7, 6, 20, 20, WS_GROUP + LTEXT "The autodial attempt failed. Do you want to disable autodial from this location?", 1099, 40, 6, 181, 34, NOT WS_GROUP + PUSHBUTTON "&Yes", 1, 60, 42, 50, 14 + DEFPUSHBUTTON "&No", 2, 115, 42, 50, 14 +END + +115 DIALOGEX 0, 0, 263, 124 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 263, 50 + LTEXT "D&ial:", 1412, 9, 60, 68, 8 + COMBOBOX 1416, 88, 56, 165, 112, CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "Dialing &from:", 1415, 9, 77, 71, 8 + COMBOBOX 1414, 88, 75, 89, 112, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP + PUSHBUTTON "Dialing &Rules", 1108, 181, 75, 72, 14 + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 8, 96, 245, 1 + DEFPUSHBUTTON "&Dial", 1590, 8, 103, 61, 14 + PUSHBUTTON "Cancel", 1591, 70, 103, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 132, 103, 60, 14 + PUSHBUTTON "&Help", 1592, 194, 103, 60, 14 +END + +116 DIALOGEX 0, 0, 265, 176 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 265, 50 + LTEXT "&User name:", 1413, 8, 60, 88, 8 + EDITTEXT 1104, 103, 57, 154, 14, ES_AUTOHSCROLL + LTEXT "&Password:", 1112, 8, 79, 88, 8 + EDITTEXT 1103, 103, 76, 154, 14, ES_PASSWORD | ES_AUTOHSCROLL + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN, 8, 97, 248, 1 + AUTOCHECKBOX "&Save this user name and password for the following users:", 1101, 14, 105, 239, 13, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "Me o&nly", 1622, 26, 120, 226, 11, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "&Anyone who uses this computer", 1623, 26, 134, 229, 11, BS_LEFT | BS_TOP | BS_MULTILINE + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 8, 149, 248, 1 + DEFPUSHBUTTON "&Dial", 1590, 8, 156, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 1591, 71, 156, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 133, 156, 60, 14 + PUSHBUTTON "&Help", 1592, 195, 156, 60, 14 +END + +117 DIALOGEX 0, 0, 263, 192 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 265, 50 + LTEXT "&User name:", 1413, 9, 61, 92, 8 + EDITTEXT 1104, 102, 57, 154, 14, ES_AUTOHSCROLL + LTEXT "&Password:", 1112, 9, 80, 92, 8 + EDITTEXT 1103, 102, 76, 154, 14, ES_PASSWORD | ES_AUTOHSCROLL + LTEXT "Do&main:", 1110, 9, 99, 91, 8 + EDITTEXT 1102, 102, 95, 154, 14, ES_UPPERCASE | ES_AUTOHSCROLL + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN, 9, 116, 247, 1 + AUTOCHECKBOX "&Save this user name and password for the following users:", 1101, 12, 123, 243, 13, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "Me o&nly", 1622, 25, 137, 229, 11, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "&Anyone who uses this computer", 1623, 25, 151, 230, 11, BS_LEFT | BS_TOP | BS_MULTILINE + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 9, 167, 247, 1 + DEFPUSHBUTTON "&Dial", 1590, 8, 173, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 1591, 71, 173, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 133, 173, 60, 14 + PUSHBUTTON "&Help", 1592, 195, 173, 60, 14 +END + +118 DIALOGEX 0, 0, 265, 220 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 265, 50 + LTEXT "&User name:", 1413, 10, 61, 92, 8 + EDITTEXT 1104, 104, 57, 154, 14, ES_AUTOHSCROLL + LTEXT "&Password:", 1112, 10, 80, 92, 8 + EDITTEXT 1103, 104, 76, 154, 14, ES_PASSWORD | ES_AUTOHSCROLL + LTEXT "Do&main:", 1110, 10, 100, 92, 8 + EDITTEXT 1102, 104, 95, 154, 14, ES_UPPERCASE | ES_AUTOHSCROLL + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN, 11, 116, 247, 1 + AUTOCHECKBOX "&Save this user name and password for the following users:", 1101, 16, 124, 239, 13, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "Me o&nly", 1622, 29, 139, 225, 11, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "&Anyone who uses this computer", 1623, 29, 152, 225, 11, BS_LEFT | BS_TOP | BS_MULTILINE + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 167, 247, 1 + LTEXT "D&ial:", 1412, 10, 177, 90, 8 + COMBOBOX 1416, 102, 173, 154, 112, CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 192, 247, 1 + DEFPUSHBUTTON "&Dial", 1590, 10, 199, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 1591, 72, 199, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 134, 199, 60, 14 + PUSHBUTTON "&Help", 1592, 196, 199, 60, 14 +END + +119 DIALOGEX 0, 0, 265, 200 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 265, 50 + LTEXT "&User name:", 1413, 10, 62, 91, 8 + EDITTEXT 1104, 104, 58, 154, 14, ES_AUTOHSCROLL + LTEXT "&Password:", 1112, 10, 81, 92, 8 + EDITTEXT 1103, 104, 77, 154, 14, ES_PASSWORD | ES_AUTOHSCROLL + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN, 10, 97, 247, 1 + AUTOCHECKBOX "&Save this user name and password for the following users:", 1101, 12, 103, 243, 13, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "Me o&nly", 1622, 24, 117, 229, 11, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "&Anyone who uses this computer", 1623, 24, 132, 229, 11, BS_LEFT | BS_TOP | BS_MULTILINE + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 147, 247, 1 + LTEXT "D&ial:", 1412, 13, 157, 88, 8 + COMBOBOX 1416, 103, 154, 154, 112, CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 173, 247, 1 + DEFPUSHBUTTON "&Dial", 1590, 10, 180, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 1591, 72, 180, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 134, 180, 60, 14 + PUSHBUTTON "&Help", 1592, 197, 180, 60, 14 +END + +121 DIALOGEX 6, 18, 230, 131 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "ISDN Configuration" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Line type:", 1155, 9, 9, 65, 8 + COMBOBOX 1153, 76, 7, 148, 42, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_VSCROLL | WS_TABSTOP + AUTOCHECKBOX "&Negotiate line type", 1150, 23, 26, 199, 10, BS_TOP | BS_MULTILINE | WS_GROUP + GROUPBOX " ", 1152, 8, 48, 214, 51, WS_GROUP + AUTOCHECKBOX "&Use old proprietary protocol", 1149, 17, 48, 102, 10, BS_TOP | BS_MULTILINE + LTEXT "&Channels to use:", 1154, 16, 65, 100, 8, NOT WS_GROUP + EDITTEXT 1151, 119, 61, 94, 14, ES_AUTOHSCROLL + AUTOCHECKBOX "&Enable hardware compression", 1148, 16, 82, 198, 10, BS_TOP | BS_MULTILINE + PUSHBUTTON "OK", 1, 99, 109, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 163, 109, 60, 14 +END + +122 DIALOGEX 6, 18, 220, 68 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "ISDN Configure" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Line type:", 1155, 9, 11, 55, 8 + COMBOBOX 1153, 67, 7, 148, 43, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_VSCROLL | WS_TABSTOP + AUTOCHECKBOX "&Negotiate line type", 1150, 21, 28, 194, 10, BS_TOP | BS_MULTILINE | WS_GROUP + PUSHBUTTON "OK", 1, 90, 49, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 154, 49, 60, 14 +END + +123 DIALOGEX 11, 20, 350, 275 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + EDITTEXT 1161, 5, 5, 338, 236, ES_MULTILINE | ES_AUTOVSCROLL | WS_VSCROLL | WS_GROUP + LTEXT "I&P address:", 1163, 7, 253, 68, 8 + CONTROL "", 1160, "RASIPADDRESS", WS_TABSTOP, 76, 250, 117, 14 + DEFPUSHBUTTON "", 1162, 197, 252, 16, 13, NOT WS_VISIBLE | WS_GROUP | NOT WS_TABSTOP + PUSHBUTTON "&Done", 1, 219, 252, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 283, 252, 60, 14 +END + +124 DIALOGEX 6, 17, 350, 266 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + EDITTEXT 1161, 5, 4, 340, 236, ES_MULTILINE | ES_AUTOVSCROLL | WS_VSCROLL | WS_GROUP + DEFPUSHBUTTON "", 1162, 7, 247, 50, 14, NOT WS_VISIBLE | WS_GROUP | NOT WS_TABSTOP + PUSHBUTTON "&Done", 1, 222, 247, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 286, 247, 60, 14 +END + +125 DIALOGEX 12, 16, 261, 190 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Modem Configuration" +FONT 8, "MS Shell Dlg" +BEGIN + ICON 15102, 1238, 7, 7, 20, 20 + LTEXT "Modem", -1, 25, 27, 24, 8, NOT WS_VISIBLE | NOT WS_GROUP + EDITTEXT 1235, 40, 7, 214, 16, ES_AUTOHSCROLL | ES_READONLY | NOT WS_BORDER + LTEXT "&Maximum speed (bps):", 1243, 7, 36, 110, 8 + COMBOBOX 1239, 119, 34, 136, 186, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "Modem &protocol", 1244, 7, 52, 111, 8 + COMBOBOX 1245, 119, 50, 136, 186, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + GROUPBOX "Hardware features", 1237, 6, 70, 248, 61, WS_GROUP + AUTOCHECKBOX "E&nable hardware flow control", 1232, 19, 82, 217, 10, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "En&able modem error control", 1231, 19, 98, 217, 10, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "Enable m&odem compression", 1229, 19, 115, 217, 10, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "&Show terminal window", 1234, 8, 136, 246, 10, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "Enable mo&dem speaker", 1230, 8, 151, 247, 10, BS_TOP | BS_MULTILINE | WS_GROUP + DEFPUSHBUTTON "OK", 1, 129, 171, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 194, 171, 60, 14 +END + +126 DIALOGEX 0, 0, 270, 117 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Select Network Component Type" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Click the type of network component you want to install:", -1, 8, 7, 258, 8 + CONTROL "", 1251, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x0000C04D, 8, 20, 188, 58 + GROUPBOX "", -1, 8, 81, 188, 30 + LTEXT "", 1250, 12, 90, 177, 17 + DEFPUSHBUTTON "&Add...", 1252, 205, 20, 60, 14 + PUSHBUTTON "Cancel", 2, 205, 38, 60, 14 +END + +127 DIALOGEX 16, 20, 260, 135 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "NetWare or Compatible Connections" +FONT 8, "MS Shell Dlg" +BEGIN + ICON 32515, 1278, 7, 7, 21, 20, WS_GROUP + LTEXT "You have connections to a NetWare compatible network. These connections will be closed when the PPP IPX connection is established.", 1279, 42, 7, 215, 37 + LTEXT "Before dialing, to avoid data loss, either close all files using these connections or uncheck IPX on this entry's Network Protocol settings.", 1280, 42, 46, 215, 38, NOT WS_GROUP + AUTOCHECKBOX "&Do not display this message in the future", 1277, 42, 86, 215, 10, BS_TOP | BS_MULTILINE | WS_GROUP + DEFPUSHBUTTON "OK", 1, 65, 112, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 134, 112, 60, 14 +END + +128 DIALOGEX 7, 22, 236, 90 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Manual Dial" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Pick up the handset and dial (or ask the operator to dial). After dialing is complete, click OK. Listen to handset until silent, and then hang up.", 1281, 8, 8, 219, 32 + LTEXT "Phone number:", 1282, 8, 46, 91, 8 + LTEXT "", 1283, 103, 46, 126, 8, NOT WS_GROUP + DEFPUSHBUTTON "OK", 1, 104, 70, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 168, 70, 60, 14 +END + +129 DIALOGEX 6, 20, 260, 85 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Network Protocol Connection Result" +FONT 8, "MS Shell Dlg" +BEGIN + ICON 32516, 1328, 7, 7, 21, 20, WS_GROUP + LTEXT "", 1329, 38, 7, 216, 24, NOT WS_GROUP + AUTOCHECKBOX "&Do not request the failed protocols next time", 1327, 40, 44, 215, 10, BS_TOP | BS_MULTILINE | WS_GROUP + PUSHBUTTON "&Accept", 1, 129, 64, 60, 14 + PUSHBUTTON "&Hang Up", 2, 193, 64, 60, 14 +END + +133 DIALOGEX 6, 18, 231, 211 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "X.25 Logon Settings" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Select your X.25 network provider and type the X.121 address of the remote server:", 1408, 7, 4, 220, 27 + LTEXT "&Network:", 1410, 9, 35, 213, 8, NOT WS_GROUP + COMBOBOX 1406, 9, 46, 215, 125, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "X.121&address:", 1407, 9, 66, 213, 8, NOT WS_GROUP + EDITTEXT 1402, 8, 77, 215, 14, ES_AUTOHSCROLL + GROUPBOX "Optional", 1405, 8, 95, 215, 79 + LTEXT "&User data:", 1411, 19, 109, 182, 8, NOT WS_GROUP + EDITTEXT 1404, 19, 120, 193, 14, ES_AUTOHSCROLL + LTEXT "&Facilities:", 1409, 19, 138, 182, 8, NOT WS_GROUP + EDITTEXT 1403, 19, 149, 193, 14, ES_AUTOHSCROLL + DEFPUSHBUTTON "OK", 1, 100, 189, 60, 14 + PUSHBUTTON "Cancel", 2, 164, 189, 60, 14 +END + +146 DIALOGEX 6, 18, 230, 210 +STYLE DS_SHELLFONT | WS_CHILD | WS_VISIBLE | WS_CAPTION +CAPTION "Autodial" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "If you are disconnected from a network, autodial attempts to connect to a network whenever you try to access remote information.", -1, 7, 4, 219, 32 + LTEXT "&Enable autodial by location:", 1006, 8, 42, 213, 8 + CONTROL "", 1004, "SYSLISTVIEW32", WS_BORDER | WS_GROUP | WS_TABSTOP | 0x0000C401, 7, 53, 216, 109 + AUTOCHECKBOX "Al&ways ask me before autodialing", 1496, 8, 170, 218, 9, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "&Disable autodial while I am logged on", 1550, 8, 185, 217, 9, BS_TOP | BS_MULTILINE +END + +147 DIALOGEX 6, 18, 230, 215 +STYLE DS_SHELLFONT | WS_CHILD | WS_VISIBLE | WS_CAPTION +CAPTION "Dialing" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "These preferences apply to 'Login using Dial-Up Networking' at Ctrl-Alt-Del login. You, as an administrator, have access to this sheet.", 1007, 7, 4, 221, 40, NOT WS_GROUP + LTEXT "&Number of redial attempts:", 1005, 7, 55, 154, 8 + EDITTEXT 1001, 164, 52, 60, 14, ES_AUTOHSCROLL + LTEXT "&Seconds between redial attempts:", 1009, 7, 73, 156, 8, NOT WS_GROUP + EDITTEXT 1003, 164, 70, 60, 14, ES_AUTOHSCROLL + LTEXT "I&dle seconds before hanging up:", 1008, 7, 91, 154, 8, NOT WS_GROUP + EDITTEXT 1002, 164, 88, 60, 14, ES_AUTOHSCROLL +END + +148 DIALOGEX 6, 18, 230, 215 +STYLE DS_SHELLFONT | WS_CHILD | WS_VISIBLE | WS_CAPTION +CAPTION "Callback" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "When you dial into a server, it may offer to call you back to reduce your phone charges. Specify whether you want callback. (Callback is not supported for virtual private network (VPN) connections.)", 1043, 8, 4, 219, 43 + AUTORADIOBUTTON "&No callback", 1041, 7, 48, 219, 10, BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "A&sk me during dialing when the server offers", 1040, 7, 61, 219, 10, BS_TOP | BS_MULTILINE + AUTORADIOBUTTON "Al&ways call me back at the number(s) below:", 1042, 7, 74, 219, 10, BS_TOP | BS_MULTILINE + CONTROL "", 1037, "SYSLISTVIEW32", WS_BORDER | WS_GROUP | WS_TABSTOP | 0x00008401, 16, 88, 204, 94 + PUSHBUTTON "&Edit...", 1039, 96, 190, 60, 14 + PUSHBUTTON "&Delete", 1038, 159, 190, 60, 14 +END + +149 DIALOGEX 6, 18, 317, 142 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "You need to set the dial-in credentials that remote routers will use when connecting to this interface. A user account will be created on this router with the information that you enter here.", 1094, 8, 5, 307, 35 + LTEXT "&User name:", 1078, 8, 47, 124, 8, NOT WS_GROUP + EDITTEXT 1074, 135, 45, 175, 12, ES_AUTOHSCROLL | WS_DISABLED + LTEXT "&Password:", 1077, 8, 68, 124, 8, NOT WS_GROUP + EDITTEXT 1073, 135, 66, 175, 12, ES_PASSWORD | ES_AUTOHSCROLL + LTEXT "&Confirm password:", 1075, 8, 90, 124, 8, NOT WS_GROUP + EDITTEXT 1071, 135, 87, 175, 12, ES_PASSWORD | ES_AUTOHSCROLL +END + +150 DIALOGEX 6, 18, 321, 144 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "You need to set the dial out credentials that this interface will use when connecting to the remote router. These credentials must match the dial in credentials configured on the remote router.", 1094, 8, 5, 308, 33 + LTEXT "&User name:", 1096, 8, 43, 130, 8, NOT WS_GROUP + EDITTEXT 1091, 140, 40, 175, 12, ES_AUTOHSCROLL + LTEXT "&Domain:", 1093, 8, 63, 130, 8, NOT WS_GROUP + EDITTEXT 1089, 140, 60, 175, 12, ES_UPPERCASE | ES_AUTOHSCROLL + LTEXT "&Password:", 1095, 8, 81, 130, 8, NOT WS_GROUP + EDITTEXT 1090, 140, 78, 175, 12, ES_PASSWORD | ES_AUTOHSCROLL + LTEXT "&Confirm password:", 1092, 8, 99, 130, 8, NOT WS_GROUP + EDITTEXT 1088, 140, 96, 175, 12, ES_PASSWORD | ES_AUTOHSCROLL +END + +153 DIALOGEX 0, 0, 315, 140 +STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Type a name you want for this connection:", -1, 8, 4, 190, 8 + EDITTEXT 1114, 8, 17, 190, 12, ES_AUTOHSCROLL + LTEXT "Click Finish to save it in the Network Connections folder.", -1, 8, 38, 193, 8 + LTEXT "To edit this connection later, select it, click the File menu, and then click Properties.", -1, 8, 58, 193, 16 +END + +155 DIALOGEX 0, 0, 231, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +CAPTION "General" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Connec&t using:", 1124, 7, 5, 219, 8 + CONTROL "", 1128, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x00004C0D, 7, 17, 198, 44, WS_EX_CLIENTEDGE + PUSHBUTTON "&Up", 1132, 210, 18, 16, 14, BS_ICON + PUSHBUTTON "&Down", 1131, 210, 36, 16, 14, BS_ICON + AUTOCHECKBOX "A&ll devices call the same numbers", 1119, 9, 66, 133, 14, BS_TOP | BS_MULTILINE + PUSHBUTTON "C&onfigure...", 1130, 144, 66, 60, 14 + GROUPBOX "Sample type", 1125, 8, 84, 215, 100, WS_GROUP + LTEXT "Ar&ea code:", 1133, 17, 102, 52, 8 + COMBOBOX 1122, 17, 112, 52, 110, CBS_DROPDOWN | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "&Phone number:", 1135, 71, 102, 139, 8 + EDITTEXT 1123, 73, 112, 79, 14, ES_AUTOHSCROLL + PUSHBUTTON "Alter&nates", 1129, 154, 112, 60, 14 + LTEXT "Country/re&gion code:", 1134, 17, 132, 197, 8 + COMBOBOX 1126, 17, 143, 193, 130, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP + AUTOCHECKBOX "U&se dialing rules", 1121, 17, 163, 132, 14, BS_TOP | BS_MULTILINE + PUSHBUTTON "Dialing &Rules", 1136, 151, 161, 60, 14 + AUTOCHECKBOX "Sho&w icon in notification area when connected", 1120, 10, 192, 214, 19, BS_TOP | BS_MULTILINE +END + +156 DIALOGEX 0, 0, 231, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +CAPTION "General" +FONT 8, "MS Shell Dlg" +BEGIN + PUSHBUTTON "C&onfigure...", 1130, 164, 38, 60, 14 + GROUPBOX "Sample text", 1125, 8, 55, 217, 100, WS_GROUP + LTEXT "Ar&ea code:", 1133, 17, 72, 48, 8 + COMBOBOX 1122, 17, 83, 48, 119, CBS_DROPDOWN | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "&Phone number:", 1135, 71, 72, 146, 8 + EDITTEXT 1123, 71, 83, 81, 14, ES_AUTOHSCROLL + PUSHBUTTON "Alter&nates", 1129, 155, 83, 63, 14 + LTEXT "Country/re&gion code:", 1134, 17, 103, 193, 8 + COMBOBOX 1126, 17, 114, 201, 130, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP + AUTOCHECKBOX "U&se dialing rules", 1121, 19, 134, 136, 12, BS_TOP | BS_MULTILINE + PUSHBUTTON "Dialing &Rules", 1136, 157, 132, 60, 14 + AUTOCHECKBOX "Sho&w icon in notification area when connected", 1120, 12, 164, 209, 18, BS_TOP | BS_MULTILINE + LTEXT "Connect using:", 1124, 8, 5, 217, 8 + CONTROL "", 1127, "SYSLISTVIEW32", WS_DISABLED | WS_BORDER | 0x0000EC0D, 7, 18, 217, 15 +END + +157 DIALOGEX 6, 18, 235, 160 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Appearance" +FONT 8, "MS Shell Dlg" +BEGIN + AUTOCHECKBOX "&Preview phone numbers before dialing", 1142, 8, 10, 224, 10, WS_GROUP + AUTOCHECKBOX "Show &location setting before dialing", 1139, 8, 27, 224, 10 + AUTOCHECKBOX "Allo&w location edits during login", 1140, 21, 43, 212, 10 + AUTOCHECKBOX "Show &connection progress while dialing", 1143, 8, 59, 224, 10 + AUTOCHECKBOX "Clo&se on dial", 1137, 8, 76, 224, 10 + AUTOCHECKBOX "All&ow phonebook edits during login", 1141, 8, 94, 224, 10 + AUTOCHECKBOX "&Use wizard to create new phonebook entries", 1144, 22, 111, 210, 10 +END + +158 DIALOGEX 6, 18, 235, 160 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Appearance" +FONT 8, "MS Shell Dlg" +BEGIN + AUTOCHECKBOX "&Preview phone numbers before dialing", 1142, 8, 10, 223, 10, WS_GROUP + AUTOCHECKBOX "Show &location setting before dialing", 1139, 8, 27, 206, 10 + AUTOCHECKBOX "Start dial-up networking &monitor before dialing", 1138, 8, 44, 226, 10 + AUTOCHECKBOX "Show &connection progress while dialing", 1143, 8, 61, 224, 10 + AUTOCHECKBOX "Clo&se on dial", 1137, 8, 79, 220, 10 + AUTOCHECKBOX "&Use wizard to create new phonebook entries", 1144, 8, 97, 220, 10 + AUTOCHECKBOX "Always prompt &before auto-dialing", 1136, 8, 114, 220, 10 +END + +160 DIALOGEX 6, 18, 320, 145 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_CHILD | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Select a name for this demand dial interface. A common practice is to name interfaces after the network or router to which they connect.", 1158, 7, 5, 309, 29 + LTEXT "&Interface name:", 1159, 17, 41, 285, 8, NOT WS_GROUP + EDITTEXT 1157, 17, 53, 284, 12, ES_AUTOHSCROLL + AUTOCHECKBOX "I &know all about demand-dial interfaces and would rather edit the properties directly", 1156, 24, 100, 258, 31, BS_TOP | BS_MULTILINE | NOT WS_VISIBLE | WS_DISABLED +END + +162 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | WS_CHILD | WS_CAPTION +CAPTION "Security" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Security options", 1580, 8, 3, 215, 139 + AUTORADIOBUTTON "&Typical (recommended settings)", 1540, 14, 16, 201, 9, BS_NOTIFY | WS_GROUP + AUTORADIOBUTTON "A&dvanced (custom settings)", 1541, 14, 102, 198, 8, BS_NOTIFY + LTEXT "&Validate my identity as follows:", 1537, 26, 29, 187, 8, NOT WS_GROUP + COMBOBOX 1178, 26, 40, 184, 78, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + AUTOCHECKBOX "A&utomatically use my ReactOS logon name and password (and domain if any)", 1174, 26, 58, 184, 20, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "Requ&ire data encryption (disconnect if none)", 1169, 26, 82, 183, 10, BS_TOP | BS_MULTILINE + LTEXT "Using these settings requires a knowledge of security protocols.", 1539, 15, 114, 134, 20 + PUSHBUTTON "&Settings...", 1180, 151, 115, 60, 14 + GROUPBOX "Interactive logon and scripting", 1177, 8, 146, 215, 62, WS_GROUP + AUTOCHECKBOX "S&how terminal window", 1173, 14, 159, 198, 11, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "&Run script:", 1172, 14, 172, 57, 10, BS_TOP | BS_MULTILINE + COMBOBOX 1179, 72, 171, 140, 104, CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + PUSHBUTTON "&Edit...", 1182, 87, 187, 60, 14 + PUSHBUTTON "&Browse...", 1181, 151, 187, 60, 14 +END + +163 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "You have more than one dial-up device on your computer.", -1, 6, 3, 307, 13 + LTEXT "&Select the devices to use in this connection:", -1, 6, 15, 307, 11 + CONTROL "", 1228, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x0000C415, 7, 28, 304, 77 +END + +165 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Networking" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Typ&e of dial-up server I am calling:", 1583, 7, 4, 219, 8 + COMBOBOX 1418, 7, 17, 215, 46, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + PUSHBUTTON "&Settings", 1419, 160, 35, 60, 14 + LTEXT "This c&onnection uses the following items:", 1684, 8, 64, 219, 10 + CONTROL "", 1251, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x0000C40D, 7, 75, 216, 53 + PUSHBUTTON "I&nstall...", 1252, 7, 133, 67, 14 + PUSHBUTTON "&Uninstall", 1254, 80, 133, 67, 14 + PUSHBUTTON "P&roperties", 1253, 153, 133, 67, 14 + GROUPBOX "Description", 1585, 9, 158, 213, 43 + LTEXT "", 1250, 18, 167, 195, 25 +END + +166 DIALOGEX 6, 18, 320, 145 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Enter the IP address of a DNS or WINS server on the remote network, or leave as 0.0.0.0 if you expect the remote router to provide them, or do not know.", 1275, 7, 2, 311, 25 + LTEXT "&DNS server:", 1274, 7, 29, 160, 8, NOT WS_GROUP + CONTROL "", 1272, "RASIPADDRESS", WS_TABSTOP, 21, 41, 85, 12 + LTEXT "&WINS server:", 1276, 7, 65, 166, 8, NOT WS_GROUP + CONTROL "", 1273, "RASIPADDRESS", WS_TABSTOP, 21, 77, 85, 12 +END + +167 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | WS_CHILD | WS_CAPTION +CAPTION "Options" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Dialing options", 1289, 7, 2, 213, 64 + AUTOCHECKBOX "&Display progress while connecting", 1284, 16, 14, 201, 10 + AUTOCHECKBOX "&Prompt for name and password, certificate, etc.", 1554, 16, 27, 201, 10 + AUTOCHECKBOX "Include &ReactOS logon domain", 1555, 16, 39, 201, 10 + AUTOCHECKBOX "Prompt for phone &number", 1285, 16, 52, 200, 10, BS_TOP | BS_MULTILINE + GROUPBOX "Redialing options", 1290, 6, 72, 213, 79 + LTEXT "&Redial attempts:", 1300, 16, 87, 123, 8 + EDITTEXT 1287, 141, 84, 69, 14, ES_AUTOHSCROLL | ES_NUMBER + LTEXT "&Time between redial attempts:", 1301, 16, 103, 123, 8 + COMBOBOX 1292, 141, 101, 70, 123, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "Idle ti&me before hanging up:", 1299, 16, 120, 123, 8 + COMBOBOX 1291, 141, 116, 70, 108, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + AUTOCHECKBOX "Redial if &line is dropped", 1286, 16, 136, 199, 10, BS_TOP | BS_MULTILINE + GROUPBOX "Multiple devices", 1288, 7, 156, 213, 32 + COMBOBOX 1551, 16, 169, 128, 45, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + PUSHBUTTON "C&onfigure...", 1293, 150, 168, 60, 14 + PUSHBUTTON "&X.25", 1295, 7, 194, 50, 14 + PUSHBUTTON "&Virtual ""tunnel"" connection", 1294, 62, 194, 120, 14, NOT WS_VISIBLE | WS_DISABLED +END + +168 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION +CAPTION "New Connection Wizard" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Type the phone number below. ", -1, 7, 4, 306, 14 + LTEXT "&Phone number:", 1308, 7, 19, 130, 8 + EDITTEXT 1304, 7, 30, 304, 14, ES_AUTOHSCROLL + LTEXT "You might need to include a ""1"" or the area code, or both. If you are not sure you need the extra numbers, dial the phone number on your telephone. If you hear a modem sound, the number dialed is correct.", -1, 20, 50, 291, 53 +END + +169 DIALOGEX 6, 18, 235, 135 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Phonebook" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Use this phonebook:", 1326, 8, 8, 222, 8 + AUTORADIOBUTTON "The &system phonebook", 1325, 14, 22, 216, 10, WS_GROUP + AUTORADIOBUTTON "My &personal phonebook", 1324, 14, 34, 216, 10 + AUTORADIOBUTTON "This a<ernate phonebook:", 1323, 14, 46, 217, 10 + COMBOBOX 1321, 26, 61, 201, 77, CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | WS_GROUP | NOT WS_TABSTOP + PUSHBUTTON "&Browse...", 1322, 167, 81, 60, 14 +END + +170 DIALOGEX 6, 18, 235, 135 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Phonebook" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Use this phonebook:", 1326, 8, 8, 223, 8 + AUTORADIOBUTTON "The &system phonebook", 1325, 14, 22, 217, 10, WS_GROUP + AUTORADIOBUTTON "This a<ernate phonebook:", 1323, 14, 36, 216, 10 + COMBOBOX 1321, 26, 51, 203, 77, CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | WS_GROUP | NOT WS_TABSTOP + PUSHBUTTON "&Browse...", 1322, 169, 69, 60, 14 +END + +171 DIALOGEX 6, 18, 317, 144 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Enter this router's IP address on the remote network or if you expect the remote router to provide the address, leave as 0.0.0.0. Usually the operator of the remote network or router will tell you what to use.", 1331, 5, 4, 308, 35 + LTEXT "My &IP address:", 1332, 4, 51, 100, 8, NOT WS_GROUP + CONTROL "", 1330, "RASIPADDRESS", WS_TABSTOP, 21, 62, 104, 12 + LTEXT "Note: If you have a network adapter installed, you should NOT choose the same address as your network adapter.", 1333, 5, 94, 306, 36, NOT WS_GROUP +END + +172 DIALOGEX 6, 18, 317, 144 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Some dial-up servers and routers require an interactive login after connecting. You can run a script automatically to respond for you.", 1339, 5, 3, 309, 27 + AUTOCHECKBOX "Show &terminal window", 1462, 15, 31, 162, 10 + AUTOCHECKBOX "&Run script:", 1463, 15, 45, 58, 10 + COMBOBOX 1334, 30, 60, 275, 88, CBS_DROPDOWN | CBS_AUTOHSCROLL | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP + PUSHBUTTON "&Edit...", 1335, 180, 77, 60, 14 + PUSHBUTTON "&Browse...", 1465, 244, 77, 60, 14 +END + +173 DIALOGEX 6, 18, 230, 215 +STYLE DS_SHELLFONT | WS_CHILD | WS_VISIBLE | WS_CAPTION +CAPTION "Dialing" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Dialing policy", 1344, 9, 4, 213, 53, WS_GROUP + LTEXT "&Number of redial attempts:", 1349, 16, 22, 140, 8, NOT WS_GROUP + EDITTEXT 1340, 158, 19, 56, 14, ES_AUTOHSCROLL + LTEXT "&Seconds between redial attempts:", 1351, 16, 38, 140, 8, NOT WS_GROUP + EDITTEXT 1342, 158, 36, 56, 14, ES_AUTOHSCROLL + GROUPBOX "Connection type", 1343, 9, 63, 213, 56, WS_GROUP + LTEXT "Idl&e seconds before hanging up:", 1350, 28, 88, 124, 8, NOT WS_GROUP + AUTORADIOBUTTON "&Demand dial connection", 1347, 16, 78, 135, 10, WS_GROUP + AUTORADIOBUTTON "&Persistent connection", 1348, 16, 103, 199, 10, NOT WS_TABSTOP, WS_EX_TRANSPARENT + EDITTEXT 1341, 159, 85, 56, 14, ES_AUTOHSCROLL + PUSHBUTTON "&Callback...", 1345, 150, 125, 70, 14, WS_GROUP + PUSHBUTTON "&Multiple Lines...", 1346, 74, 125, 70, 14 +END + +174 DIALOGEX 0, 0, 215, 226 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Router" +FONT 8, "MS Shell Dlg" +BEGIN + CTEXT "NYI...need spec from KCrocker", -1, 57, 86, 106, 28 +END + +175 DIALOGEX 6, 18, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Completing the demand dial interface wizard.", 1352, 122, 5, 192, 32 + LTEXT "To create this interface and enable it on the router, click Finish.", 1354, 122, 41, 192, 26, NOT WS_GROUP + LTEXT "To edit this interface in the Routing and RemoteAccess Manager, select it in Routing Interfaces and press Properties.", 1355, 122, 68, 190, 39, NOT WS_GROUP +END + +179 DIALOGEX 6, 18, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Select the &modem or adapter this interface will use.", 1356, 7, 4, 306, 11 + CONTROL "", 1355, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x0000C415, 6, 15, 305, 80 + LTEXT "The list shows devices set up for routing.", 1357, 15, 98, 288, 37, NOT WS_GROUP +END + +180 DIALOGEX 6, 18, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Enter the phone number of the dial-up server or router you are calling. Alternate phone numbers, if any, are dialed automatically if the primary number cannot be reached.", 1360, 7, 4, 305, 42 + LTEXT "&Phone number or address:", 1361, 7, 50, 275, 8, NOT WS_GROUP + EDITTEXT 1358, 7, 62, 304, 14, ES_AUTOHSCROLL + PUSHBUTTON "Alternates...", 1359, 250, 80, 60, 14 +END + +181 DIALOGEX 6, 18, 230, 215 +STYLE DS_SHELLFONT | WS_CHILD | WS_VISIBLE | WS_CAPTION +CAPTION "Security" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Authentication and encryption policy", 1367, 6, 8, 216, 103, WS_GROUP + AUTORADIOBUTTON "A&ccept any authentication including clear text", 1370, 16, 20, 195, 10, BS_TOP | BS_MULTILINE + AUTORADIOBUTTON "Acc&ept only encrypted authentication", 1373, 16, 36, 195, 10, BS_TOP | BS_MULTILINE + AUTORADIOBUTTON "Accept &only MS encrypted authentication", 1374, 16, 52, 195, 10, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "&Require data encryption", 1363, 27, 65, 184, 10, BS_TOP | BS_MULTILINE | WS_GROUP + AUTOCHECKBOX "Require &strong data encryption", 1364, 41, 80, 172, 10, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "Use t&wo-way authentication", 1362, 17, 95, 194, 10, BS_TOP | BS_MULTILINE + PUSHBUTTON "&Unsave Password", 1369, 59, 117, 80, 14, WS_GROUP + PUSHBUTTON "Ad&vanced...", 1368, 142, 117, 80, 14, NOT WS_VISIBLE | WS_DISABLED + AUTOCHECKBOX "&Detect file and print sharing before dialing", 1365, 7, 198, 218, 10, BS_TOP | BS_MULTILINE | NOT WS_VISIBLE | WS_DISABLED +END + +182 DIALOGEX 6, 18, 248, 148 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Security" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Authentication and encryption policy", 1367, 7, 8, 200, 98, WS_GROUP + AUTORADIOBUTTON "Accept any authentication including &clear text", 1370, 14, 24, 183, 10 + AUTORADIOBUTTON "Accept only &encrypted authentication", 1373, 14, 39, 183, 10 + AUTORADIOBUTTON "Accept only &MS encrypted authentication", 1374, 14, 53, 184, 10 + AUTOCHECKBOX "Require &data encryption", 1363, 33, 67, 165, 10, WS_GROUP + AUTOCHECKBOX "Require &strong data encryption", 1364, 48, 79, 152, 10 + AUTOCHECKBOX "&Use current username and password ", 1366, 31, 91, 165, 10 + PUSHBUTTON "Unsave &password", 1369, 6, 114, 100, 14, WS_GROUP + PUSHBUTTON "&Advanced...", 1368, 109, 114, 60, 14, NOT WS_VISIBLE | WS_DISABLED + AUTOCHECKBOX "Detect &file and print sharing before dialing", 1365, 14, 134, 193, 10, NOT WS_VISIBLE | WS_DISABLED +END + +183 DIALOGEX 6, 18, 317, 144 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Check all that apply:", 1388, 7, 4, 296, 9 + AUTOCHECKBOX "Route &IP packets on this interface.", 1386, 20, 19, 285, 11, BS_LEFT | BS_TOP | BS_MULTILINE + AUTOCHECKBOX "Route IP&X packets on this interface.", 1387, 20, 35, 287, 11, BS_LEFT | BS_TOP | BS_MULTILINE + AUTOCHECKBOX "&Add a user account so a remote router can dial in.", 1382, 20, 52, 287, 11, BS_LEFT | BS_TOP | BS_MULTILINE + AUTOCHECKBOX "Send a &plain-text password if that is the only way to connect.", 1385, 20, 70, 287, 11, BS_LEFT | BS_TOP | BS_MULTILINE + AUTOCHECKBOX "&Use scripting to complete the connection with the remote router.", 1384, 20, 87, 289, 22, BS_LEFT | BS_TOP | BS_MULTILINE +END + +184 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED +FONT 8, "MS Shell Dlg" +BEGIN +END + +186 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION +CAPTION "New Connection Wizard" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "A connection that is created for your use only is saved in your user account and is not available unless you are logged on.", -1, 7, 4, 306, 23 + LTEXT "Create this connection for:", -1, 14, 27, 288, 12 + AUTORADIOBUTTON "&Anyone's use", 1400, 26, 40, 265, 10, BS_TOP | BS_MULTILINE | NOT WS_TABSTOP + AUTORADIOBUTTON "&My use only", 1401, 26, 55, 265, 10, BS_TOP | BS_MULTILINE | NOT WS_TABSTOP +END + +498 DIALOGEX 12, 16, 215, 126 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "ReactOS was unable to connect to the network using the user name and password you provided. Please re-enter the user name and password.", 1396, 7, 6, 206, 36 + LTEXT "&User name:", 1399, 8, 51, 49, 8 + EDITTEXT 1394, 66, 46, 143, 14, ES_AUTOHSCROLL + LTEXT "&Password:", 1397, 8, 70, 49, 8, NOT WS_GROUP + EDITTEXT 1393, 66, 64, 143, 14, ES_PASSWORD | ES_AUTOHSCROLL + AUTOCHECKBOX "&Save password", 1391, 66, 84, 143, 10 + CONTROL "", 1398, "STATIC", SS_ETCHEDHORZ | WS_GROUP, 7, 98, 200, 1 + DEFPUSHBUTTON "OK", 1, 81, 104, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 145, 104, 60, 14 +END + +500 DIALOGEX 12, 16, 215, 173 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "ReactOS was unable to connect to the network using the user name and password you provided. Please re-enter the user name and password.", 1396, 7, 6, 209, 26 + LTEXT "&User name:", 1399, 7, 72, 44, 8 + EDITTEXT 1394, 97, 69, 115, 14, ES_AUTOHSCROLL + LTEXT "&Password:", 1397, 7, 90, 45, 8, NOT WS_GROUP + EDITTEXT 1393, 97, 87, 115, 14, ES_PASSWORD | ES_AUTOHSCROLL + LTEXT "&Domain:", 1395, 7, 108, 53, 8, NOT WS_GROUP + EDITTEXT 1392, 97, 105, 115, 14, ES_UPPERCASE | ES_AUTOHSCROLL + AUTOCHECKBOX "&Save user name and password", 1391, 85, 125, 123, 10, BS_TOP | BS_MULTILINE + DEFPUSHBUTTON "OK", 1, 87, 146, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 151, 146, 60, 14 + CONTROL "", 1398, "STATIC", SS_ETCHEDHORZ | WS_GROUP, 7, 140, 205, 1 + LTEXT "You can enter a domain name or leave the domain field empty.\n(Domain names are not required for connections to the Internet)", -1, 8, 38, 209, 26 +END + +502 DIALOGEX 20, 60, 215, 73 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "PPP Settings" +FONT 8, "MS Shell Dlg" +BEGIN + AUTOCHECKBOX "&Enable LCP extensions", 1423, 9, 7, 200, 10, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "E&nable software compression", 1424, 9, 22, 201, 10, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "Negotiate &multi-link for single link connections", 1557, 9, 37, 202, 10, BS_TOP | BS_MULTILINE + DEFPUSHBUTTON "OK", 1, 82, 53, 60, 14 + PUSHBUTTON "Cancel", 2, 148, 53, 60, 14 +END + +509 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +CAPTION "New Connection Wizard" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Choose the role you want for this computer:", -1, 10, 5, 275, 9 + AUTORADIOBUTTON "&Host", 1483, 31, 20, 265, 10, BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "&Guest", 1484, 31, 44, 265, 10, BS_TOP | BS_MULTILINE + LTEXT "This computer has the information you want to access.", -1, 43, 31, 253, 13, NOT WS_GROUP | WS_TABSTOP + LTEXT "This computer is used to access information on the host computer.", -1, 43, 56, 253, 23, NOT WS_GROUP +END + +511 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Select a device:", -1, 8, 5, 261, 8 + COMBOBOX 1485, 9, 18, 302, 62, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP +END + +528 DIALOGEX 0, 0, 227, 215 +STYLE DS_SHELLFONT | WS_CHILD | WS_CAPTION +CAPTION "Connections" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Logon privileges", 1582, 8, 10, 213, 63 + LTEXT "Non-administrators may be allowed to create or modify connections before logging on.", 1581, 16, 21, 194, 30 + AUTOCHECKBOX "Allo&w creating and modifying connections before logon", 1497, 16, 56, 195, 10, BS_TOP | BS_MULTILINE +END + +532 DIALOGEX 0, 0, 263, 263 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Router Callback" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "When you dial into a router, it may offer to call you back to reduce your phone charges or to increase security. Specify whether you want callback or not.", 1043, 7, 5, 253, 24 + AUTORADIOBUTTON "&No callback", 1501, 9, 36, 252, 10, BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "Al&ways call me back at the number(s) below:", 1502, 9, 48, 252, 10, BS_TOP | BS_MULTILINE, WS_EX_TRANSPARENT + CONTROL "", 1503, "SYSLISTVIEW32", WS_BORDER | WS_GROUP | WS_TABSTOP | 0x00008401, 15, 63, 240, 143 + PUSHBUTTON "&Edit...", 1504, 131, 213, 60, 14 + PUSHBUTTON "&Delete", 1505, 194, 213, 60, 14 + CONTROL "", -1, "STATIC", SS_ETCHEDHORZ, 7, 233, 249, 1 + DEFPUSHBUTTON "OK", 1, 132, 242, 60, 14 + PUSHBUTTON "Cancel", 2, 196, 242, 60, 14 +END + +534 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | WS_CHILD | WS_CAPTION +CAPTION "Options" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Connection type", 1289, 7, 7, 215, 55 + AUTORADIOBUTTON "&Demand dial", 1506, 16, 20, 199, 9, BS_TOP | BS_MULTILINE | WS_GROUP | NOT WS_TABSTOP + LTEXT "Idle ti&me before hanging up:", 1299, 27, 33, 99, 8, NOT WS_GROUP + COMBOBOX 1291, 144, 30, 70, 108, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + AUTORADIOBUTTON "&Persistent connection", 1507, 16, 47, 197, 9, BS_TOP | BS_MULTILINE | NOT WS_TABSTOP + GROUPBOX "Dialing policy", 1290, 7, 66, 215, 48 + LTEXT "&Redial attempts:", 1300, 14, 79, 123, 8 + EDITTEXT 1287, 143, 76, 70, 14, ES_AUTOHSCROLL | ES_NUMBER + LTEXT "A&verage redial intervals:", 1301, 14, 96, 123, 8 + COMBOBOX 1292, 143, 94, 70, 123, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + GROUPBOX "Multiple devices", 1288, 7, 116, 215, 35 + COMBOBOX 1551, 16, 130, 128, 41, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + PUSHBUTTON "C&onfigure...", 1293, 150, 129, 65, 14 + PUSHBUTTON "Call&back", 1302, 8, 195, 60, 14 + PUSHBUTTON "&X.25", 1295, 73, 195, 50, 14 +END + +539 DIALOGEX 0, 0, 265, 110 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 265, 50 + LTEXT "&User name:", 1413, 14, 64, 84, 8 + EDITTEXT 1104, 102, 62, 154, 14, ES_AUTOHSCROLL + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 9, 82, 247, 1 + DEFPUSHBUTTON "&Dial", 1590, 8, 89, 60, 14 + PUSHBUTTON "Cancel", 1591, 71, 89, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 133, 89, 60, 14 + PUSHBUTTON "&Help", 1592, 195, 89, 60, 14 +END + +540 DIALOGEX 0, 0, 265, 133 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 265, 50 + LTEXT "&User name:", 1413, 10, 64, 90, 8 + EDITTEXT 1104, 105, 60, 154, 14, ES_AUTOHSCROLL + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 7, 80, 252, 1 + LTEXT "D&ial:", 1412, 10, 91, 92, 10 + COMBOBOX 1416, 105, 88, 154, 112, CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 7, 107, 251, 1 + DEFPUSHBUTTON "&Dial", 1590, 8, 113, 60, 14 + PUSHBUTTON "Cancel", 1591, 71, 113, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 134, 113, 60, 14 + PUSHBUTTON "&Help", 1592, 197, 113, 60, 14 +END + +541 DIALOGEX 0, 0, 265, 157 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 265, 50 + LTEXT "&User name:", 1413, 10, 67, 87, 8 + EDITTEXT 1104, 103, 63, 154, 14, ES_AUTOHSCROLL + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 9, 84, 248, 1 + LTEXT "D&ial:", 1412, 11, 96, 48, 8 + COMBOBOX 1416, 103, 92, 154, 112, CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "Dialing &from:", 1415, 10, 114, 46, 8 + COMBOBOX 1414, 103, 110, 87, 112, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP + PUSHBUTTON "Dialing &Rules", 1108, 193, 110, 64, 14 + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 7, 130, 250, 1 + DEFPUSHBUTTON "&Dial", 1590, 6, 136, 60, 14 + PUSHBUTTON "Cancel", 1591, 69, 136, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 132, 136, 60, 14 + PUSHBUTTON "&Help", 1592, 196, 136, 60, 14 +END + +544 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION +CAPTION "New Connection Wizard" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Internet Connection Sharing allows other computers on your local network to access external resources through this connection.", -1, 10, 5, 300, 22 + AUTOCHECKBOX "&Enable Internet Connection Sharing for this connection", 1512, 21, 31, 272, 10 + LTEXT "To dial this connection automatically when a computer on your local network attempts to access external resources, select the following check box.", 1514, 10, 56, 294, 22 + AUTOCHECKBOX "Enab&le on-demand dialing", 1513, 21, 86, 260, 10 +END + +545 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION +CAPTION "New Connection Wizard" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Shared access allows other computers on your local network to access external resources through this dial-up connection. You can enable shared access for one connection and one local network at a time.", -1, 10, 5, 300, 25 + LTEXT "&Select the local network that will access resources through this connection:", -1, 21, 35, 285, 8 + COMBOBOX 1522, 21, 48, 231, 56, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP +END + +546 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "You can configure this connection to use your smart card to log you into the remote network. Select whether to use your smart card with this connection.", -1, 10, 5, 303, 22 + AUTORADIOBUTTON "&Use my smart card ", 1524, 26, 29, 264, 12, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP | NOT WS_TABSTOP + AUTORADIOBUTTON "&Do not use my smart card ", 1525, 26, 44, 261, 16, BS_LEFT | BS_TOP | BS_MULTILINE | NOT WS_TABSTOP +END + +547 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +CAPTION "Demand Dial Interface Wizard" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Welcome to the Demand Dial Interface Wizard.", 1530, 122, 8, 192, 32 + LTEXT "Using this wizard you can create a demand dial interface to connect this router to other routers.", 1531, 122, 43, 192, 37 + LTEXT "Press Next to continue.", 1532, 122, 85, 191, 29 +END + +548 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + AUTORADIOBUTTON "Connect using a &modem, ISDN adapter, or other physical device.", 1531, 21, 17, 290, 15, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP | NOT WS_TABSTOP + AUTORADIOBUTTON "Connect using &virtual private networking (VPN)", 1532, 21, 38, 291, 15, BS_LEFT | BS_TOP | BS_MULTILINE | NOT WS_TABSTOP + AUTORADIOBUTTON "Connect using PPP over Ethernet (PPPoE)", 1688, 21, 58, 290, 12, NOT WS_TABSTOP +END + +550 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_CHILD | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Enter the name or IP address of the router to which you are connecting.", 1535, 10, 8, 289, 18 + LTEXT "&Host name or IP address (such as reactos.org or 145.52.0.1):", 1537, 21, 35, 285, 8 + EDITTEXT 1536, 21, 47, 285, 14, ES_AUTOHSCROLL +END + +551 DIALOGEX 0, 0, 265, 127 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 265, 50 + LTEXT "&User name:", 1413, 12, 62, 89, 8 + EDITTEXT 1104, 104, 58, 154, 14, ES_AUTOHSCROLL + LTEXT "Do&main:", 1110, 12, 82, 90, 8 + EDITTEXT 1102, 104, 79, 154, 14, ES_UPPERCASE | ES_AUTOHSCROLL + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 99, 248, 1 + DEFPUSHBUTTON "&Dial", 1590, 9, 106, 61, 14 + PUSHBUTTON "Cancel", 1591, 72, 106, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 135, 106, 60, 14 + PUSHBUTTON "&Help", 1592, 198, 106, 60, 14 +END + +552 DIALOGEX 0, 0, 265, 159 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 265, 50 + LTEXT "&User name:", 1413, 10, 67, 91, 10 + EDITTEXT 1104, 104, 64, 154, 14, ES_AUTOHSCROLL + LTEXT "Do&main:", 1110, 10, 86, 91, 8 + EDITTEXT 1102, 104, 83, 154, 14, ES_UPPERCASE | ES_AUTOHSCROLL + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 103, 248, 1 + LTEXT "D&ial:", 1412, 10, 115, 91, 8 + COMBOBOX 1416, 104, 111, 154, 112, CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 132, 248, 1 + DEFPUSHBUTTON "&Dial", 1590, 8, 139, 60, 14 + PUSHBUTTON "Cancel", 1591, 71, 139, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 134, 139, 60, 14 + PUSHBUTTON "&Help", 1592, 198, 139, 60, 14 +END + +553 DIALOGEX 0, 0, 265, 183 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 265, 50 + LTEXT "&User name:", 1413, 10, 68, 92, 10 + EDITTEXT 1104, 104, 65, 154, 14, ES_AUTOHSCROLL + LTEXT "Do&main:", 1110, 10, 90, 91, 8 + EDITTEXT 1102, 104, 86, 154, 14, ES_UPPERCASE | ES_AUTOHSCROLL + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 106, 248, 1 + LTEXT "D&ial:", 1412, 10, 118, 92, 8 + COMBOBOX 1416, 104, 114, 154, 112, CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "Dialing &from:", 1415, 10, 137, 91, 8 + COMBOBOX 1414, 104, 134, 87, 112, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP + PUSHBUTTON "Dialing &Rules", 1108, 194, 134, 65, 14 + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 154, 248, 1 + DEFPUSHBUTTON "&Dial", 1590, 8, 162, 60, 14 + PUSHBUTTON "Cancel", 1591, 71, 162, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 134, 162, 60, 14 + PUSHBUTTON "&Help", 1592, 198, 162, 60, 14 +END + +554 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +CAPTION "General" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Connec&t using:", 1124, 7, 4, 193, 8 + CONTROL "", 1128, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x00004C0D, 7, 17, 195, 44, WS_EX_CLIENTEDGE + PUSHBUTTON "&Up", 1132, 208, 18, 16, 14, BS_ICON + PUSHBUTTON "&Down", 1131, 208, 36, 16, 14, BS_ICON + AUTOCHECKBOX "A&ll devices call the same numbers", 1119, 7, 65, 131, 21, BS_TOP | BS_MULTILINE + PUSHBUTTON "C&onfigure...", 1130, 140, 66, 60, 14 + GROUPBOX "Sample type", 1125, 7, 87, 213, 56, WS_GROUP + LTEXT "&Phone number:", 1135, 19, 102, 191, 8 + EDITTEXT 1123, 17, 112, 138, 14, ES_AUTOHSCROLL + PUSHBUTTON "Alter&nates", 1129, 161, 112, 50, 14 + AUTOCHECKBOX "Sho&w icon in notification area when connected", 1120, 11, 194, 212, 20, BS_TOP | BS_MULTILINE +END + +555 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +CAPTION "General" +FONT 8, "MS Shell Dlg" +BEGIN + PUSHBUTTON "C&onfigure...", 1130, 160, 38, 60, 14 + LTEXT "&Phone number:", 1135, 8, 72, 194, 8 + EDITTEXT 1123, 8, 83, 148, 14, ES_AUTOHSCROLL + PUSHBUTTON "Alter&nates", 1129, 160, 83, 60, 14 + AUTOCHECKBOX "Sho&w icon in notification area when connected", 1120, 11, 194, 213, 10, BS_TOP | BS_MULTILINE + LTEXT "Connec&t using:", 1124, 8, 5, 214, 8 + CONTROL "", 1127, "SYSLISTVIEW32", WS_DISABLED | WS_BORDER | 0x0000EC0D, 7, 18, 214, 15 +END + +556 DIALOGEX 0, 0, 220, 165 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Program Settings" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Description of program running on your network:", -1, 7, 5, 203, 8 + EDITTEXT 1565, 7, 17, 206, 14, ES_AUTOHSCROLL + LTEXT "&Internet server port number:", -1, 7, 35, 202, 8 + EDITTEXT 1566, 7, 47, 113, 14, ES_AUTOHSCROLL | ES_NUMBER + AUTORADIOBUTTON "&TCP", 1548, 128, 49, 30, 10, NOT WS_TABSTOP + AUTORADIOBUTTON "&UDP", 1567, 166, 49, 31, 10, NOT WS_TABSTOP + LTEXT "&Listen for Internet server responses on port or port range:\n(for example: 1024-1209, 1300-1310, 1450)", -1, 7, 70, 207, 22 + LTEXT "T&CP:", -1, 7, 100, 28, 8 + EDITTEXT 1569, 50, 97, 162, 14, ES_AUTOHSCROLL + LTEXT "UD&P:", -1, 7, 121, 30, 8 + EDITTEXT 1551, 50, 117, 162, 14, ES_AUTOHSCROLL + DEFPUSHBUTTON "OK", 1, 90, 144, 60, 14 + PUSHBUTTON "Cancel", 2, 154, 144, 60, 14 +END + +557 DIALOGEX 0, 0, 217, 164 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Service Settings" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Description of service:", -1, 7, 5, 203, 8 + EDITTEXT 1552, 7, 18, 205, 14, ES_AUTOHSCROLL + LTEXT "&Name or IP address (for example 192.168.0.12) of the computer hosting this service on your network:", -1, 7, 37, 208, 16 + EDITTEXT 1556, 7, 57, 203, 14, ES_AUTOHSCROLL + LTEXT "&Port number where this service resides:", -1, 7, 85, 203, 8 + EDITTEXT 1553, 7, 97, 113, 14, ES_AUTOHSCROLL | ES_NUMBER + AUTORADIOBUTTON "&TCP", 1554, 128, 99, 30, 10, NOT WS_TABSTOP + AUTORADIOBUTTON "&UDP", 1555, 166, 99, 31, 10, NOT WS_TABSTOP + DEFPUSHBUTTON "OK", 1, 86, 143, 60, 14 + PUSHBUTTON "Cancel", 2, 150, 143, 60, 14 +END + +558 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Programs" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "The Internet connection on this computer has been customized to allow the following programs to run properly over your network:", -1, 7, 7, 218, 28 + CONTROL "List1", 1558, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x0000441D, 7, 37, 215, 155, WS_EX_CLIENTEDGE + PUSHBUTTON "A&dd...", 1538, 7, 197, 67, 14 + PUSHBUTTON "Edi&t...", 1559, 80, 197, 67, 14 + PUSHBUTTON "D&elete", 1568, 153, 197, 67, 14 +END + +559 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Services" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Select the services running on your network that Internet users can access.", -1, 7, 5, 216, 22 + LTEXT "Services:", -1, 7, 27, 143, 8 + CONTROL "List1", 1560, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x0000441D, 7, 37, 215, 155, WS_EX_CLIENTEDGE + PUSHBUTTON "A&dd...", 1561, 7, 197, 67, 14 + PUSHBUTTON "Edi&t...", 1563, 80, 197, 67, 14 + PUSHBUTTON "D&elete", 1562, 153, 197, 67, 14 +END + +560 DIALOGEX 6, 18, 240, 88 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Initial Connection" +FONT 8, "MS Shell Dlg" +BEGIN + DEFPUSHBUTTON "&Yes", 6, 68, 68, 50, 14 + PUSHBUTTON "&No", 7, 125, 68, 50, 14 + ICON 32516, 1575, 7, 7, 20, 20 + LTEXT "", 1576, 40, 7, 190, 33 + AUTOCHECKBOX "&Don't display this reminder again", 1579, 40, 48, 192, 11, BS_TOP | BS_MULTILINE +END + +567 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION +CAPTION "New Connection Wizard" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Type the name of your service in the following text box. If you leave the text box blank, ReactOS will automatically detect and configure your service when you connect.", -1, 10, 7, 301, 25 + LTEXT "&Service name (optional):", -1, 22, 32, 229, 8 + EDITTEXT 1593, 22, 44, 275, 14, ES_AUTOHSCROLL +END + +568 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +CAPTION "General" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Service name:", 1686, 7, 5, 217, 10 + EDITTEXT 1594, 7, 17, 217, 14, ES_AUTOHSCROLL + AUTOCHECKBOX "Sho&w icon in notification area when connected", 1120, 9, 196, 215, 8 +END + +569 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | WS_CHILD | WS_CAPTION +CAPTION "Security" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Security options", 1580, 8, 4, 213, 151 + AUTORADIOBUTTON "&Typical (recommended settings)", 1540, 14, 16, 197, 9, BS_NOTIFY | WS_GROUP + AUTORADIOBUTTON "A&dvanced (custom settings)", 1541, 14, 100, 197, 8, BS_NOTIFY + LTEXT "&Validate my identity as follows:", 1537, 26, 29, 183, 8, NOT WS_GROUP + COMBOBOX 1178, 26, 40, 184, 78, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + AUTOCHECKBOX "A&utomatically use my ReactOS logon name and password (and domain if any)", 1174, 26, 59, 182, 20, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "Requ&ire data encryption (disconnect if none)", 1169, 26, 83, 182, 10, BS_TOP | BS_MULTILINE + LTEXT "Using these settings requires a knowledge of security protocols.", 1539, 26, 111, 136, 20 + PUSHBUTTON "&Settings...", 1180, 151, 134, 60, 14 + PUSHBUTTON "I&PSec Settings...", 1598, 126, 163, 85, 14 +END + +570 DIALOGEX 0, 0, 265, 126 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "IPSec Settings" +FONT 8, "MS Shell Dlg" +BEGIN + DEFPUSHBUTTON "OK", 1, 151, 104, 50, 14 + PUSHBUTTON "Cancel", 2, 207, 104, 50, 14 + AUTOCHECKBOX "&Use pre-shared key for authentication", 1604, 21, 15, 217, 10 + LTEXT "&Key:", 1602, 20, 31, 44, 12 + EDITTEXT 1605, 66, 30, 172, 12, ES_AUTOHSCROLL + AUTOCHECKBOX "Allow certificiates from my user store in addition to machine certificates", 1606, 20, 50, 242, 13, WS_DISABLED + AUTOCHECKBOX "Use a specific certificate", 1607, 20, 67, 239, 10, WS_DISABLED + PUSHBUTTON "Select", 1608, 31, 84, 50, 14, WS_DISABLED + COMBOBOX 1610, 91, 84, 135, 30, CBS_DROPDOWN | CBS_SORT | WS_DISABLED | WS_VSCROLL | NOT WS_TABSTOP +END + +571 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Security Logging" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Logging Options:", -1, 6, 8, 216, 47 + AUTOCHECKBOX "Log unsuccessful &inbound connection attempts", 1642, 14, 22, 201, 10 + AUTOCHECKBOX "Log successful &outbound connections", 1641, 14, 37, 200, 10 + GROUPBOX "Log file options:", -1, 7, 64, 215, 91 + LTEXT "&Name:", -1, 14, 78, 199, 8 + EDITTEXT 1674, 14, 90, 199, 14, ES_READONLY + PUSHBUTTON "&Browse...", 1639, 153, 108, 60, 14 + LTEXT "&Size limit:", -1, 14, 133, 67, 8 + EDITTEXT 1640, 86, 130, 50, 14, ES_AUTOHSCROLL | ES_NUMBER + LTEXT "KB", -1, 140, 133, 20, 8 + PUSHBUTTON "&Restore Defaults", 1643, 135, 197, 85, 14 +END + +572 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "ICMP" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Internet Control Message Protocol (ICMP) allows the computers on a network to share error and status information. Select the requests for information from the Internet that this computer will respond to:", -1, 7, 5, 215, 37 + CONTROL "IList1", 1644, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x0000440D, 7, 45, 215, 100, WS_EX_CLIENTEDGE + GROUPBOX "Description:", -1, 7, 153, 215, 55 + LTEXT "", 1645, 14, 171, 199, 32 +END + +574 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Advanced" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "", 575, 7, 60, 213, 100 +END + +577 DIALOGEX 0, 0, 312, 144 +STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION +CAPTION "New Connection Wizard" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Type the name of the ISP in the following text box.", 1681, 10, 3, 296, 11 + LTEXT "N&ame:", 1690, 18, 20, 127, 10 + EDITTEXT 1680, 17, 32, 222, 14, ES_AUTOHSCROLL + LTEXT "The name you type here will be the name of the connection you are creating.", 1683, 17, 52, 282, 42 +END + +580 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_CHILD | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + AUTORADIOBUTTON "&Automatic selection", 1534, 21, 20, 288, 11, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP | NOT WS_TABSTOP + AUTORADIOBUTTON "&Point to Point Tunneling Protocol (PPTP)", 1532, 21, 39, 290, 11, BS_LEFT | BS_TOP | BS_MULTILINE | NOT WS_TABSTOP + AUTORADIOBUTTON "&Layer 2 Tunneling Protocol (L2TP)", 1533, 21, 56, 286, 11, BS_LEFT | BS_TOP | BS_MULTILINE | NOT WS_TABSTOP +END + +1420 DIALOGEX 0, 0, 265, 108 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 265, 50 + LTEXT "D&ial:", 1412, 14, 63, 86, 8 + COMBOBOX 1416, 104, 60, 154, 112, CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 80, 248, 1 + DEFPUSHBUTTON "&Dial", 1590, 9, 87, 60, 14 + PUSHBUTTON "Cancel", 1591, 72, 87, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 135, 87, 60, 14 + PUSHBUTTON "&Help", 1592, 198, 87, 60, 14 +END + +1421 DIALOGEX 0, 0, 265, 223 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 265, 50 + LTEXT "&User name:", 1413, 10, 61, 90, 8 + EDITTEXT 1104, 104, 58, 154, 14, ES_AUTOHSCROLL + LTEXT "&Password:", 1112, 11, 81, 90, 8 + EDITTEXT 1103, 104, 77, 154, 14, ES_PASSWORD | ES_AUTOHSCROLL + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN, 10, 98, 248, 1 + AUTOCHECKBOX "&Save this user name and password for the following users:", 1101, 14, 105, 242, 13, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "Me o&nly", 1622, 26, 119, 225, 11, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "&Anyone who uses this computer", 1623, 26, 133, 225, 11, BS_LEFT | BS_TOP | BS_MULTILINE + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 149, 248, 1 + LTEXT "D&ial:", 1412, 14, 161, 87, 8 + COMBOBOX 1416, 104, 157, 154, 112, CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "Dialing &from:", 1415, 14, 178, 88, 8 + COMBOBOX 1414, 104, 175, 87, 112, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP + PUSHBUTTON "Dialing &Rules", 1108, 193, 175, 65, 14 + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 196, 248, 1 + DEFPUSHBUTTON "&Dial", 1590, 9, 202, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 1591, 72, 202, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 135, 202, 60, 14 + PUSHBUTTON "&Help", 1592, 198, 202, 60, 14 +END + +1422 DIALOGEX 0, 0, 265, 242 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Connect %1" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL 1678, 1100, "STATIC", SS_BITMAP, 0, 0, 265, 50 + LTEXT "&User name:", 1413, 10, 67, 91, 8 + EDITTEXT 1104, 104, 63, 154, 14, ES_AUTOHSCROLL + LTEXT "&Password:", 1112, 10, 85, 92, 8 + EDITTEXT 1103, 104, 82, 154, 14, ES_PASSWORD | ES_AUTOHSCROLL + LTEXT "Do&main:", 1110, 10, 104, 92, 8 + EDITTEXT 1102, 104, 101, 154, 14, ES_UPPERCASE | ES_AUTOHSCROLL + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN, 10, 121, 248, 1 + AUTOCHECKBOX "&Save this user name and password for the following users:", 1101, 12, 127, 242, 13, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "Me o&nly", 1622, 24, 141, 227, 11, BS_LEFT | BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "&Anyone who uses this computer", 1623, 24, 155, 230, 11, BS_LEFT | BS_TOP | BS_MULTILINE + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 170, 248, 1 + LTEXT "D&ial:", 1412, 14, 182, 87, 8 + COMBOBOX 1416, 104, 178, 154, 112, CBS_DROPDOWN | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "Dialing &from:", 1415, 14, 198, 87, 8 + COMBOBOX 1414, 104, 195, 87, 112, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP + PUSHBUTTON "Dialing &Rules", 1108, 193, 195, 65, 14 + CONTROL "", -1, "STATIC", SS_LEFTNOWORDWRAP | SS_SUNKEN | WS_GROUP, 10, 215, 248, 1 + DEFPUSHBUTTON "&Dial", 1590, 8, 221, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 1591, 71, 221, 60, 14 + PUSHBUTTON "Pr&operties", 1107, 134, 221, 60, 14 + PUSHBUTTON "&Help", 1592, 198, 221, 60, 14 +END + +1425 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +CAPTION "General" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Host name or IP address of destination (such as reactos.org or 145.52.0.1):", 1430, 7, 5, 217, 18 + EDITTEXT 1427, 7, 25, 215, 14, ES_AUTOHSCROLL + GROUPBOX "First connect", 1431, 9, 48, 213, 78 + LTEXT "ReactOS can first connect the public network, such as the Internet, before trying to establish this virtual connection.", 1432, 17, 63, 199, 24 + AUTOCHECKBOX "&Dial another connection first:", 1428, 19, 89, 183, 10 + COMBOBOX 1429, 29, 103, 182, 87, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP + AUTOCHECKBOX "Sho&w icon in notification area when connected", 1120, 10, 192, 213, 13 +END + +1426 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | WS_CHILD | WS_CAPTION +CAPTION "Options" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Dialing options", 1289, 8, 7, 214, 56 + AUTOCHECKBOX "&Display progress while connecting", 1284, 16, 17, 199, 10 + AUTOCHECKBOX "&Prompt for name and password, certificate, etc.", 1554, 16, 32, 199, 10 + AUTOCHECKBOX "Include &ReactOS logon domain", 1555, 16, 47, 178, 10 + GROUPBOX "Redialing options", 1290, 8, 68, 214, 89 + LTEXT "&Redial attempts:", 1300, 16, 81, 121, 8 + EDITTEXT 1287, 140, 77, 70, 14, ES_AUTOHSCROLL | ES_NUMBER + LTEXT "&Time between redial attempts:", 1301, 16, 99, 121, 8 + COMBOBOX 1292, 141, 95, 70, 123, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "Idle ti&me before hanging up:", 1299, 16, 117, 121, 8 + COMBOBOX 1291, 141, 113, 70, 108, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + AUTOCHECKBOX "Redial if &line is dropped", 1286, 16, 138, 199, 10, BS_TOP | BS_MULTILINE +END + +1427 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Type the host name or Internet Protocol (IP) address of the computer to which you are connecting.", -1, 10, 6, 275, 16 + LTEXT "&Host name or IP address (for example, reactos.org or 145.52.0.1 ):", -1, 21, 28, 277, 11 + EDITTEXT 1433, 21, 42, 275, 14, ES_AUTOHSCROLL +END + +1428 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION +CAPTION "New Connection Wizard" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "ReactOS can automatically dial the initial connection to the Internet or other public network, before establishing the virtual connection.", -1, 10, 6, 275, 24 + AUTORADIOBUTTON "&Do not dial the initial connection.", 1509, 32, 31, 271, 10, BS_TOP | BS_MULTILINE | NOT WS_TABSTOP + AUTORADIOBUTTON "&Automatically dial this initial connection:", 1510, 32, 45, 269, 10, BS_TOP | BS_MULTILINE | NOT WS_TABSTOP + COMBOBOX 1435, 43, 62, 253, 87, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP +END + +1436 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +CAPTION "General" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Select a device:", 1597, 8, 5, 213, 8 + COMBOBOX 1437, 7, 17, 217, 166, CBS_DROPDOWNLIST | CBS_AUTOHSCROLL | WS_VSCROLL | NOT WS_TABSTOP + AUTOCHECKBOX "Sho&w icon in notification area when connected", 1120, 11, 195, 213, 10, BS_TOP | BS_MULTILINE + PUSHBUTTON "C&onfigure...", 1130, 160, 34, 60, 14 +END + +1448 DIALOGEX 10, 20, 265, 71 +STYLE DS_SHELLFONT | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +CAPTION "Network Connections" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "C&hoose a network connection:", 1456, 7, 7, 251, 10 + COMBOBOX 1457, 8, 18, 250, 140, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL | NOT WS_TABSTOP + DEFPUSHBUTTON "&Connect...", 1449, 7, 50, 60, 14 + PUSHBUTTON "Cancel", 1455, 70, 50, 60, 14 + PUSHBUTTON "&New...", 1459, 134, 50, 60, 14 + PUSHBUTTON "P&roperties", 1460, 198, 50, 60, 14 +END + +1466 DIALOGEX 6, 18, 265, 262 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Sample text", 1469, 7, 7, 251, 8 + EDITTEXT 1470, 7, 17, 193, 14, ES_AUTOHSCROLL + PUSHBUTTON "&Add", 1471, 77, 36, 60, 14 + PUSHBUTTON "&Replace", 1472, 141, 36, 60, 14 + LTEXT "Sample text", 1473, 7, 57, 193, 8 + LISTBOX 1474, 7, 68, 193, 145, WS_VSCROLL | WS_TABSTOP + PUSHBUTTON "", 1475, 206, 68, 51, 14, BS_BITMAP | WS_GROUP + PUSHBUTTON "&Down", 1476, 206, 86, 51, 14, BS_BITMAP + PUSHBUTTON "D&elete", 1477, 141, 215, 60, 14 + CONTROL "", 1479, "STATIC", SS_ETCHEDHORZ, 7, 233, 249, 1 + PUSHBUTTON "OK", 1, 132, 242, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 196, 242, 60, 14 +END + +1467 DIALOGEX 6, 18, 263, 263 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Sample text", 1469, 7, 7, 197, 8 + EDITTEXT 1470, 7, 17, 193, 14, ES_AUTOHSCROLL + PUSHBUTTON "&Add", 1471, 76, 36, 60, 14 + PUSHBUTTON "&Replace", 1472, 141, 36, 60, 14 + LTEXT "Sample text", 1473, 7, 57, 193, 8 + LISTBOX 1474, 7, 68, 193, 135, WS_VSCROLL | WS_TABSTOP + PUSHBUTTON "&Up", 1475, 206, 68, 51, 14, BS_BITMAP | WS_GROUP + PUSHBUTTON "&Down", 1476, 206, 86, 51, 14, BS_BITMAP + PUSHBUTTON "D&elete", 1477, 141, 204, 60, 14 + AUTOCHECKBOX "Sample text", 1478, 7, 225, 249, 10, BS_TOP | BS_MULTILINE + PUSHBUTTON "OK", 1, 132, 242, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 196, 242, 60, 14 +END + +1468 DIALOGEX 6, 18, 263, 263 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_VISIBLE | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Sample text", 1469, 7, 5, 249, 8 + EDITTEXT 1470, 7, 17, 249, 14, ES_AUTOHSCROLL + PUSHBUTTON "&Add", 1471, 132, 36, 60, 14 + PUSHBUTTON "&Replace", 1472, 196, 36, 60, 14 + LTEXT "Sample text", 1473, 7, 55, 251, 8 + LISTBOX 1474, 7, 68, 249, 140, LBS_STANDARD | WS_TABSTOP + PUSHBUTTON "D&elete", 1477, 196, 214, 60, 14, WS_GROUP + CONTROL "", 1479, "STATIC", SS_ETCHEDHORZ, 7, 233, 249, 1 + PUSHBUTTON "OK", 1, 132, 242, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 196, 242, 60, 14 +END + +1469 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION +CAPTION "New Connection Wizard" +FONT 8, "MS Shell Dlg" +BEGIN + AUTORADIOBUTTON "Dial-up to &private network.", 1488, 24, 9, 116, 10, NOT WS_TABSTOP + AUTORADIOBUTTON "Connect to a private network &through the Internet.", 1489, 24, 34, 206, 10, NOT WS_TABSTOP + AUTORADIOBUTTON "&Connect directly to another computer.", 1490, 24, 59, 157, 10, NOT WS_TABSTOP + AUTORADIOBUTTON "Connect to the network via b&roadband", 1491, 24, 83, 273, 10, NOT WS_TABSTOP + LTEXT "Connect using my phone line (modem or ISDN).", -1, 45, 21, 156, 8 + LTEXT "Create a Virtual Private Network (VPN) connection or tunnel through the internet.", -1, 45, 46, 266, 8 + LTEXT "Connect using my serial, parallel, or infrared port.", -1, 45, 71, 266, 8 + LTEXT "Connect through my broadband connection.", -1, 45, 95, 266, 8 +END + +1480 DIALOGEX 0, 0, 230, 61 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Phone Number Editor" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Please enter the new phone number:", 1481, 7, 7, 218, 8 + EDITTEXT 1482, 7, 17, 217, 15, ES_AUTOHSCROLL + DEFPUSHBUTTON "OK", 1, 99, 40, 60, 14 + PUSHBUTTON "Cancel", 2, 163, 40, 60, 14 +END + +1481 DIALOGEX 0, 0, 321, 157 +STYLE DS_SHELLFONT | WS_CHILD | WS_DISABLED | WS_CAPTION +CAPTION "New Connection Wizard" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Type an ISP account name and password, then write down this information and store it in a safe place. (If you have forgotten an existing account name or password, contact your ISP.)", 1689, 10, 4, 308, 25 + LTEXT "&User name:", 1636, 23, 35, 89, 15 + EDITTEXT 1614, 115, 34, 190, 15, ES_AUTOHSCROLL + LTEXT "&Password:", 1637, 23, 55, 90, 13 + EDITTEXT 1615, 115, 54, 190, 15, ES_PASSWORD | ES_AUTOHSCROLL + LTEXT "&Confirm password:", 1638, 23, 74, 88, 13 + EDITTEXT 1616, 115, 73, 190, 15, ES_PASSWORD | ES_AUTOHSCROLL + AUTOCHECKBOX "U&se this account name and password when anyone connects to the Internet from this computer", 1596, 23, 91, 291, 17, BS_LEFT | BS_TOP | BS_MULTILINE + AUTOCHECKBOX "&Make this the default Internet connection", 1595, 23, 112, 288, 14 + AUTOCHECKBOX "&Turn on Internet Connection Firewall for this connection", 1682, 23, 133, 290, 14 +END + +1660 DIALOGEX 0, 0, 258, 78 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Internet Connection Firewall" +FONT 8, "MS Shell Dlg" +BEGIN + ICON 32515, -1, 7, 7, 20, 20 + LTEXT "Turning off the Internet Connection Firewall could expose your computer to unauthorized access over the Internet. Are you sure you want to turn it off?", -1, 44, 5, 212, 24 + AUTOCHECKBOX "&Do not show this dialog again", 1662, 42, 40, 210, 10 + DEFPUSHBUTTON "&Yes", 6, 74, 60, 50, 14 + PUSHBUTTON "&No", 7, 128, 60, 50, 14 +END + +7000 DIALOGEX 0, 0, 215, 103 +STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_CAPTION +CAPTION "General" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&User name:", -1, 7, 8, 90, 12, SS_CENTERIMAGE + EDITTEXT 7001, 101, 7, 108, 14, ES_AUTOHSCROLL + LTEXT "&Full name:", -1, 7, 26, 90, 12 + EDITTEXT 7002, 101, 25, 108, 14, ES_AUTOHSCROLL + LTEXT "&Password:", -1, 7, 44, 90, 12 + EDITTEXT 7003, 101, 43, 108, 14, ES_PASSWORD | ES_AUTOHSCROLL + LTEXT "&Confirm password:", -1, 7, 62, 91, 12 + EDITTEXT 7004, 101, 61, 108, 14, ES_PASSWORD | ES_AUTOHSCROLL + PUSHBUTTON "OK", 1, 84, 82, 60, 14 + PUSHBUTTON "Cancel", 2, 149, 82, 60, 14 +END + +7005 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_CONTEXTHELP | WS_CHILD | WS_CAPTION +CAPTION "Callback" +FONT 8, "MS Shell Dlg" +BEGIN + AUTORADIOBUTTON "&Do not allow callback", 7009, 9, 7, 219, 10, BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "All&ow the caller to set the callback number", 7006, 9, 20, 218, 10, BS_TOP | BS_MULTILINE | NOT WS_TABSTOP + AUTORADIOBUTTON "Al&ways use the following callback number:", 7007, 9, 34, 217, 10, BS_TOP | BS_MULTILINE | NOT WS_TABSTOP + EDITTEXT 7008, 19, 49, 204, 14, ES_AUTOHSCROLL | WS_GROUP +END + +7010 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_CONTEXTHELP | WS_CHILD | WS_CAPTION +CAPTION "General" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Incoming connections", -1, 7, 4, 214, 110, WS_GROUP + LTEXT "Allow incoming connections on these devices.", -1, 17, 17, 195, 8 + LTEXT "&Devices:", -1, 17, 29, 29, 8 + CONTROL "", 7011, "SYSLISTVIEW32", WS_BORDER | WS_GROUP | WS_TABSTOP | 0x00004405, 17, 41, 193, 47, WS_EX_CLIENTEDGE + AUTOCHECKBOX "&Enable multilink", 7012, 17, 96, 121, 10, BS_TOP | BS_MULTILINE | WS_GROUP + PUSHBUTTON "P&roperties", 7013, 145, 94, 65, 14, WS_GROUP + GROUPBOX "Virtual private network", -1, 6, 122, 214, 49, WS_GROUP + AUTOCHECKBOX "Allo&w others to make private connections to my computer by tunneling through the Internet or other network", 7014, 17, 137, 195, 27, BS_TOP | BS_MULTILINE | WS_GROUP + AUTOCHECKBOX "&Show icon in notification area when connected", 7015, 12, 184, 209, 10, BS_TOP | BS_MULTILINE | WS_GROUP +END + +7016 DIALOGEX 0, 0, 265, 190 +STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Incoming TCP/IP Properties" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Network access", -1, 6, 5, 252, 32 + AUTOCHECKBOX "Allow &callers to access my local area network", 7017, 20, 20, 228, 9, BS_LEFT | BS_TOP | BS_MULTILINE + GROUPBOX "TCP/IP address assignment", -1, 6, 42, 250, 122 + AUTORADIOBUTTON "&Assign TCP/IP addresses automatically using DHCP", 7019, 20, 54, 231, 10, BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "S&pecify TCP/IP addresses", 7020, 20, 71, 231, 10, BS_TOP | BS_MULTILINE + LTEXT "&From:", -1, 29, 88, 53, 8 + CONTROL "", 7018, "RASIPADDRESS", WS_GROUP | WS_TABSTOP, 90, 85, 103, 13 + LTEXT "&To:", -1, 29, 105, 53, 8 + CONTROL "", 7021, "RASIPADDRESS", WS_GROUP | WS_TABSTOP, 90, 102, 103, 13 + LTEXT "Total:", -1, 29, 124, 53, 10 + LTEXT "", 7024, 90, 121, 150, 14, 0, WS_EX_STATICEDGE + AUTOCHECKBOX "Allo&w calling computer to specify its own IP address", 7022, 20, 144, 231, 10, BS_TOP | BS_MULTILINE | WS_GROUP + DEFPUSHBUTTON "OK", 1, 133, 169, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 197, 169, 60, 14 +END + +7025 DIALOGEX 0, 0, 250, 157 +STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Incoming IPX Properties" +FONT 8, "MS Shell Dlg" +BEGIN + GROUPBOX "Network access", -1, 8, 6, 234, 32 + AUTOCHECKBOX "Allow &callers to access my local area network", 7032, 18, 19, 194, 12, BS_LEFT | BS_TOP | BS_MULTILINE + GROUPBOX "Network number assignment", -1, 8, 43, 234, 87 + AUTOCHECKBOX "&Assign same network number to all computers", 7028, 17, 56, 203, 10, BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "Assi&gn network numbers automatically", 7026, 28, 68, 191, 10, BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "&Specify network numbers:", 7027, 28, 81, 189, 10, BS_TOP | BS_MULTILINE | NOT WS_TABSTOP + EDITTEXT 7029, 40, 92, 154, 14, ES_UPPERCASE | WS_GROUP + AUTOCHECKBOX "Allo&w callers to specify their own node numbers", 7031, 17, 113, 208, 11, BS_TOP | BS_MULTILINE | WS_GROUP + DEFPUSHBUTTON "OK", 1, 116, 136, 60, 14, WS_GROUP + PUSHBUTTON "Cancel", 2, 181, 136, 60, 14 +END + +7033 DIALOGEX 0, 0, 220, 50 +STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Incoming Protocol Properties" +FONT 8, "MS Shell Dlg" +BEGIN + AUTOCHECKBOX "Allow &callers to access my local area network", 7034, 7, 7, 208, 18, BS_LEFT | BS_TOP | BS_MULTILINE + DEFPUSHBUTTON "OK", 1, 86, 30, 60, 14 + PUSHBUTTON "Cancel", 2, 151, 30, 60, 14 +END + +7035 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_CAPTION +CAPTION "Networking" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Network components:", -1, 7, 7, 217, 9 + CONTROL "", 7036, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x0000440D, 7, 17, 215, 89, WS_EX_CLIENTEDGE + PUSHBUTTON "&Install...", 7037, 9, 110, 67, 14, WS_GROUP + PUSHBUTTON "&Uninstall", 7038, 80, 110, 67, 14, WS_GROUP + PUSHBUTTON "P&roperties", 7039, 153, 110, 67, 14, WS_GROUP + GROUPBOX "Description", -1, 7, 138, 213, 69 + LTEXT "", 7040, 17, 150, 193, 48 +END + +7042 DIALOGEX 0, 0, 230, 215 +STYLE DS_SHELLFONT | DS_CONTEXTHELP | WS_CHILD | WS_CAPTION +CAPTION "Users" +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Users allowed to connect:", -1, 7, 5, 213, 8 + CONTROL "", 7043, "SYSLISTVIEW32", WS_BORDER | WS_GROUP | WS_TABSTOP | 0x0000440D, 7, 19, 214, 83, WS_EX_CLIENTEDGE + PUSHBUTTON "&New...", 7044, 7, 107, 67, 14, WS_GROUP + PUSHBUTTON "&Delete", 7045, 80, 107, 67, 14, WS_GROUP + PUSHBUTTON "P&roperties", 7046, 153, 107, 67, 14, WS_GROUP + AUTOCHECKBOX "Re&quire all users to secure their passwords and data.", 7048, 8, 151, 217, 12, BS_TOP | BS_MULTILINE + AUTOCHECKBOX "Al&ways allow directly connected devices such as palmtop computers to connect without providing a password.", 7049, 8, 169, 217, 23, BS_TOP | BS_MULTILINE + LTEXT "Note that other factors, such as a disabled user account, may affect a user's ability to connect.", -1, 9, 126, 212, 23 +END + +7049 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Select the check box next to each user who should be allowed a connection to this computer. Note that other factors, such as a disabled user account, may affect a user's ability to connect.", -1, 10, 1, 275, 27 + LTEXT "&Users allowed to connect:", -1, 10, 28, 275, 8 + CONTROL "", 7043, "SYSLISTVIEW32", WS_BORDER | WS_GROUP | WS_TABSTOP | 0x0000440D, 10, 42, 275, 73 + PUSHBUTTON "&Add...", 7044, 10, 122, 65, 14, WS_GROUP + PUSHBUTTON "&Remove", 7045, 79, 122, 65, 14, WS_GROUP + PUSHBUTTON "&Properties", 7046, 147, 122, 65, 14, WS_GROUP +END + +7050 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Select the check box next to each device you want to use for incoming connections.", -1, 10, 4, 299, 10 + LTEXT "&Connection devices:", -1, 10, 16, 275, 8 + CONTROL "", 7011, "SYSLISTVIEW32", WS_BORDER | WS_GROUP | WS_TABSTOP | 0x0000440D, 10, 26, 297, 87 + PUSHBUTTON "P&roperties", 7013, 243, 120, 65, 14, WS_GROUP +END + +7051 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Select the check box next to each type of networking software that should be enabled for incoming connections.", -1, 10, 1, 288, 20 + LTEXT "Networking &software:", -1, 10, 24, 274, 8 + CONTROL "", 7036, "SYSLISTVIEW32", WS_BORDER | WS_TABSTOP | 0x0000440D, 10, 34, 286, 33 + PUSHBUTTON "&Install...", 7037, 108, 71, 60, 14, WS_GROUP + PUSHBUTTON "&Uninstall", 7038, 172, 71, 60, 14, WS_GROUP + PUSHBUTTON "&Properties", 7039, 236, 71, 60, 14, WS_GROUP + LTEXT "", 7040, 21, 105, 273, 38 + LTEXT "Description:", -1, 21, 95, 275, 8 +END + +7052 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "Virtual private connections to your computer through the Internet are possible only if your computer has a known name or IP address on the Internet.", -1, 10, 4, 290, 20 + AUTORADIOBUTTON "&Allow virtual private connections", 7053, 29, 63, 265, 10, BS_TOP | BS_MULTILINE | WS_GROUP + AUTORADIOBUTTON "&Do not allow virtual private connections", 7054, 29, 78, 265, 10, BS_TOP | BS_MULTILINE | NOT WS_TABSTOP + LTEXT "Do you want to allow virtual private connections to this computer?", -1, 17, 49, 275, 8 + LTEXT " If you allow VPN connections, ReactOS will modify the Internet Connection Firewall to allow your computer to send and receive VPN packets.", -1, 10, 25, 293, 25 +END + +7055 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN + LTEXT "&Device for this connection:", -1, 23, 24, 275, 8 + COMBOBOX 7056, 22, 36, 275, 125, CBS_DROPDOWNLIST | WS_VSCROLL | NOT WS_TABSTOP + LTEXT "Devices other than the one you select will not be affected and may be used for other purposes.", -1, 10, 4, 275, 17 + PUSHBUTTON "&Properties", 7061, 232, 53, 65, 14, WS_GROUP +END + +7379 DIALOGEX 0, 0, 317, 143 +STYLE DS_SHELLFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION +FONT 8, "MS Shell Dlg" +BEGIN +END + +19900 DIALOGEX 0, 0, 156, 44 +STYLE DS_SHELLFONT | WS_POPUP | WS_CAPTION +CAPTION "Dial-Up Networking" +FONT 8, "MS Shell Dlg" +BEGIN + ICON 563, 19901, 10, 10, 18, 20 + LTEXT "Waiting for services to start...", 19902, 34, 16, 120, 8 +END + +STRINGTABLE +BEGIN + 187 "&No, do not dial\0" + 188 "You (or a program) have requested information from %1. Which connection do you want to use?\0" + 189 "Add Alternate Phone Number\0" + 190 "Dial only first available device\0" + 191 "Dial all devices\0" + 192 "Dial devices only as needed\0" + 193 "Enter a user name and password with access to the remote network domain.\0" + 194 "Network Address Translation (NAT) is currently installed as a routing protocol,\nand must be removed before enabling Internet Connection Sharing.\nTo remove Network Address Translation, open the Routing and Remote Access Manager\nsnapin and expand the router's entry in the left pane.\nDelete the Network Address Translation routing protocol from the list of IP\nrouting protocols.\0" + 195 "The area code must contain only the digits 0 to 9.\0" + 196 "The entry name must contain at least one non-blank character and cannot begin with a period. Choose a different name.\0" + 197 "You must choose a value from %1 to %2 for this field.\0" + 198 "The custom authentication configuration DLL could not be loaded. Make sure the custom authentication package is correctly installed.\0" + 199 "The connection selected was established by the Multiprotocol router.\nPlease use the 'Routing and RAS Admin' tool to hang up the connection.\0" + 200 "Comment\0" + 201 "The custom authentication package configuration failed.\0" + 202 "TCP/IP is not installed or is disabled for Routing and Remote Access. In Control Panel, start Network, go to the Services page, choose 'Routing and Remote Access Service' Properties, and press the Network button.\0" + 203 "IPX is not installed or is disabled for Routing and Remote Access. You can install/enable IPX by viewing the properties of any connection in ""Connections"" folder.\0" + 204 "Remove the selected device(s) from the list?\0" + 205 "Delete %1 from the phonebook?\0" + 206 "Disconnect from %1?\0" + 207 "A file named %1 already exists. Overwrite it?\0" + 208 "Syntax errors were found in the script. Do you wish to view the error log?\0" + 209 "'%1' is now connected. \0" + 210 "Right-click the Dial-Up Networking Monitor on the task bar to hang up or check the status of your connection.\0" + 212 "Connected successfully.\0" + 213 "The custom authentication method selected must be initialized by pressing Properties.\0" + 214 "lnk\0" + 215 "Dial-up shortcut files (*.rnk)\0" + 216 "*.rnk\0" + 217 "Create Dial-Up Shortcut\0" + 218 "Link to %1 failed. Reconnect pending...\0" + 219 "Cannot retrieve framing information.\0" + 220 "Cannot retrieve port information.\0" + 221 "Cannot retrieve projection information.\0" + 222 "Cannot load connection list.\0" + 223 "Client:\0" + 224 "Details\0" + 225 "Device:\0" + 226 "Network:\0" + 227 "(not connected)\0" + 228 "&Connect...\0" + 229 "Hang &Up\0" + 230 "Dial-up Connection\0" + 231 "Modem configuration set to defaults\0" + 232 "COM1\0" + 233 "Remote Router\0" + 234 "Modem or device\0" + 235 "Please enter a username for this interface's account on the remote router.\0" + 236 "An entry named %1 already exists. Choose a different name.\0" + 237 "You may want to allow sending your password without encryption.\0" + 238 "Password Encryption\0" + 239 "The wizard is ready to create your connection.\0" + 240 "Finished\0" + 241 "Phone &number:\0" + 242 "Call Me Back At\0" + 243 "Edit Alternate Phone Number\0" + 244 "Since this connection is currently active, some settings will not take effect until the next time you dial it.\0" + 245 "There are no connections available to all users. You must logon before dialing.\0" + 246 "The phonebook is empty.\n\nPress OK to add an entry.\0" + 247 "Due to import/export restrictions, data encryption is not available in this version of ReactOS.\0" + 248 "Please enter an X.25 address on the next screen.\0" + 249 "Error %1: %2\0" + 250 "%1\n\nError %2: %3\0" + 251 "%1\n\nError %2: %3\nDiagnostic: %4\0" + 252 "%1\n\nError %2: %3\nFail Code: %4\0" + 253 "%1\n\nError %2: %3\n\nPress F1 for more information.\0" + 254 "%1\n\nError %2: %3\nName: %4\0" + 255 "%1\n\n%4\0" + 256 "%1\n\nError %2: %3\nResponse: %4\0" + 257 "Fail Code: 0x%1\n\0" + 258 "Name: %1\n\0" + 259 "%1 CP reported error %2: %3\n\0" + 260 "%1 CP connected successfully.\n\0" + 261 "You can choose which dial-up protocol to use.\0" + 262 "Choose Dial-up Protocol\0" + 263 "Press Finish to save '%1'.\0" + 264 "netcfg.hlp\0" + 265 "&Move successful number to the top of the list on connection\0" + 266 "&New phone number:\0" + 267 "&Phone numbers:\0" + 268 "Phone Numbers\0" + 269 "You may enter a fixed IP address.\0" + 270 "IP Address\0" + 271 "The Internet protocols (TCP/IP), are not installed or are disabled for Remote Access. In Control Panel, start Network, go to the Services page, choose 'Remote Access Service' Properties, and press the Network button.\0" + 272 "TCP/IP\0" + 273 "IPSec, default policy\0" + 274 "IPX/SPX or compatible\0" + 275 " (the current location)\0" + 276 "ISDN\0" + 277 "All available ISDN lines multi-linked\0" + 278 "64K Digital\0" + 279 "56K Digital\0" + 280 "56K Voice\0" + 281 "You may need a special procedure before connecting.\0" + 282 "Choose Logon Options\0" + 283 "%d%%\0" + 284 "Phone number for %s\0" + 285 "&New location:\0" + 286 "&Locations:\0" + 287 "Locations\0" + 288 "This is the device that will be used to make the connection.\0" + 289 "Select a Device\0" + 290 "Multiple Lines cannot be bundled unless you are calling a PPP server.\0" + 291 "Modem\0" + 292 "The modem is not installed.\0" + 293 "MS Point-to-Point Encryption, 128 bit RSA/RC4\0" + 294 "MS Point-to-Point Encryption, 40 bit RSA/RC4\0" + 295 "Multiple Lines\0" + 296 "(Press Configure to set)\0" + 297 "You may enter fixed DNS and WINS addresses.\0" + 298 "Name Server Addresses\0" + 299 "Down-level RAS\0" + 300 "PPP\0" + 301 "PPP multi-link\0" + 302 "SLIP\0" + 303 "NetBEUI\0" + 304 "A personal phonebook has been created and initialized with the contents of the system phonebook.\0" + 305 "No alternate phonebook is selected.\0" + 306 "That device cannot be dynamically configured.\0" + 307 "The entry cannot be deleted because it is connected.\0" + 308 "No entry is selected. Press the New button to create an entry.\0" + 309 "A non-zero IP address must be supplied when 'specify an IP address' is selected.\0" + 310 "An X.25 Address is required when an X.25 dial-up network or X.25 device is selected.\0" + 311 "(none)\0" + 312 "'%1' is already in the list.\0" + 313 "Secure my password and my data\0" + 314 "The %1 protocol cannot be selected because it is not installed or is disabled for Remote Access. To change, in Control Panel start Network, choose Services page, Remote Access Properties, and press the Network button.\0" + 315 "Cannot save password.\0" + 316 "Cannot display data.\0" + 317 "Cannot get auto-dial information.\0" + 318 "Cannot load dialog.\0" + 319 "Cannot disable shared access.\0" + 320 "Cannot load property page.\0" + 321 "Cannot load phonebook.\0" + 322 "Cannot load RAS Manager port information.\0" + 323 "Cannot read user preferences from registry.\0" + 324 "Cannot load script information.\0" + 325 "Cannot view script.log with notepad.exe\0" + 326 "Cannot edit switch.inf with notepad.exe\0" + 327 "Cannot load TAPI information.\0" + 328 "Cannot load X.25 information.\0" + 329 "Cannot create new phonebook.\0" + 330 "Cannot enable shared access.\0" + 331 "Cannot connect the phonebook entry.\0" + 332 "Cannot get send/receive buffer.\0" + 333 "Cannot get status information for a port.\0" + 334 "Cannot retrieve protocol information.\0" + 335 "Cannot receive buffer from device.\0" + 336 "Cannot send buffer to device.\0" + 337 "Cannot retrieve data.\0" + 338 "Cannot save TAPI information.\0" + 339 "Cannot save data.\0" + 340 "The script has halted.\0" + 341 "The script has halted due to an error. Do you wish to view the error log?\0" + 342 "Cannot set auto-dial information.\0" + 343 "Cannot delete saved password.\0" + 344 "Cannot write phonebook.\0" + 345 "Writing preferences to registry\0" + 346 "Cannot write the shortcut file.\0" + 347 "OK\0" + 348 "What is your ISP's phone number?\0" + 349 "Phone Number to Dial\0" + 350 "The Password and Confirm password fields do not match.\0" + 351 "The New Password and Confirm New Password fields do not match.\0" + 352 "pbk\0" + 353 "Phonebook files (*.pbk)\0" + 354 "*.pbk\0" + 355 "Open Phonebook\0" + 356 "Clone Phonebook Entry\0" + 357 "Edit Phonebook Entry\0" + 358 "New Phonebook Entry\0" + 359 "Phone number\0" + 360 "Phone numbers\0" + 361 "Network Connections\0" + 362 "You must select at least one network protocol.\0" + 363 "Before you can call PPP servers you must install a network protocol with the Control Network applet.\0" + 364 "&New prefix:\0" + 365 "&Prefixes:\0" + 366 "Phone Number Prefixes\0" + 367 "One or more requested network protocols did not connect successfully.\n\n\0" + 368 "Press Accept to use the connection as is, or Hang Up to disconnect.\0" + 369 "Point-to-point protocol settings to use when %1 initiates a demand dial connection on interface %2:\0" + 370 "[To change the saved password, click here]\0" + 405 "NetBEUI protocol is required to call older RAS servers.\0" + 406 "Before you can call older RAS servers you must install the NetBEUI protocol. NetBEUI can be installed with the Control Panel Network applet.\0" + 407 "&Redial\0" + 408 "You have chosen to disable one or more transports. Doing so requires the routing managers and routing protocols for the disabled transports to be removed from this demand-dial interface.\nClick Yes if you want to conti \n \n\n\n\n\n\nnue, or No if you want to re-enable the transports.\0" + 409 "Internet Connection Sharing\0" + 410 "Demand-dial interface dial-in account.\0" + 411 "You now need to set the dial-out credentials that interface '%1' will use when connecting to the remote router. These credentials must match the dial-in credentials configured on the remote router. When connecting to a \n \n\n\n\n\n\nWin NT4/2000 router, the user name must also match the interface name of the remote router.\0" + 412 "mpradmin.hlp\0" + 413 "&Move successful number or address to the top of the list on connection\0" + 414 "&New phone number or address:\0" + 415 "&Phone numbers or addresses:\0" + 416 "Numbers and Addresses\0" + 417 "PPP: Win 95/98/NT4/2000, Internet\0" + 418 "None\0" + 419 "SLIP: Unix Connection\0" + 420 "All devices connected.\0" + 421 "Receiving registration result...\0" + 422 "Sending callback information...\0" + 423 "Sending new password...\0" + 424 "Calculating link speed...\0" + 425 "Checking authentication status...\0" + 426 "Registering your computer on the network...\0" + 427 "Retrying authentication...\0" + 428 "Verifying username and password...\0" + 429 "Authenticated.\0" + 430 "Connecting through %1...\0" + 431 "Dialing...\0" + 432 "Modems connecting...\0" + 433 "Connecting over cable...\0" + 434 "Dialing %1...\0" + 435 "Connecting over X.25 to %1...\0" + 436 "Postconnecting through %1...\0" + 437 "Preconnecting through %1...\0" + 438 "Connected.\0" + 439 "Device connected.\0" + 440 "Disconnected.\0" + 441 "Modem connected.\0" + 442 "Cable connected.\0" + 443 "Opening port...\0" + 444 "X.25 connected.\0" + 445 "Port opened.\0" + 446 "Postconnect complete.\0" + 447 "Preconnect complete.\0" + 448 "Preparing for callback...\0" + 449 "Checking network protocol connections...\0" + 450 "Verifying username and password...\0" + 451 "Connected, bundling additional lines\0" + 452 "Unknown state.\0" + 453 "Waiting for callback...\0" + 454 "Waiting for modem reset...\0" + 455 "Make the phone number change permanent?\0" + 456 "scp\0" + 457 "*.scp\0" + 458 "Dial-up script files (*.scp)\0" + 459 "Browse Dial-Up Scripts\0" + 460 "You must check at least one modem or adapter.\0" + 461 "Phone number\0" + 462 "TCP/IP protocol is required to call SLIP servers.\0" + 463 "Before you can call SLIP servers you must install the TCP/IP protocol. TCP/IP can be installed with the Control Panel Network applet.\0" + 464 "Status\0" + 465 "&New suffix:\0" + 466 "&Suffixes:\0" + 467 "Phone Number Suffixes\0" + 468 "You can go on to choose special settings, if necessary.\0" + 469 "Custom Settings\0" + 470 "Manual Modem Command Terminal\0" + 471 "After Dial Terminal\0" + 472 "Before Dial Terminal\0" + 473 "SLIP Login Terminal\0" + 474 "10 minutes\0" + 475 "10 seconds\0" + 476 "1 hour\0" + 477 "1 minute\0" + 478 "24 hours\0" + 479 "2 hours\0" + 480 "2 minutes\0" + 481 "30 minutes\0" + 482 "30 seconds\0" + 483 "3 seconds\0" + 484 "4 hours\0" + 485 "4 minutes\0" + 486 "5 minutes\0" + 487 "5 seconds\0" + 488 "8 hours\0" + 489 "never\0" + 490 "You can make the new connection available to any user or only to yourself.\0" + 491 "Connection Availability\0" + 492 "Discard multiple line settings for the entry?\0" + 493 "Unavailable device\0" + 494 "Logon Preferences\0" + 495 "Dial-up Preferences\0" + 496 "X.25\0" + 497 "X.25 PAD\0" + 498 "You can let other computers access resources through this dial-up connection.\0" + 499 "VPN Server Selection\0" + 500 "Cannot enable on-demand dialing.\0" + 501 "What is the name or address of the VPN server?\0" + 502 "Cannot disable on-demand dialing.\0" + 503 "Public Network\0" + 504 "ReactOS can make sure the public network is connected first.\0" + 505 "VPN1\0" + 506 "Internet Connection Sharing\0" + 507 "You can let a local network access resources through this dial-up connection.\0" + 508 "Host or Guest?\0" + 509 "Internet Connection Sharing is currently enabled for connection '%1'.\n\nIt will now be enabled for connection '%2' instead.\0" + 510 "To connect two computers, your computer must be identified as either a host or a guest.\0" + 511 "When Internet Connection Sharing is enabled, your LAN adapter will be set to use IP address 192.168.0.1. Your computer may lose connectivity with other computers on your network. If these other computers have static IP addresses, you should set them to obtain their IP addresses automatically. Are you sure you want to enable Internet Connection Sharing?\0" + 512 "Select a Device\0" + 513 "This is the device that will be used to make the connection.\0" + 514 "&Connect\0" + 515 "Let the server determine encryption\0" + 516 "Always encrypt my data\0" + 517 "Use MPPE-40 data encryption\0" + 518 "Use MPPE-128 data encryption\0" + 519 "The current encryption selection requires MS-CHAP or EAP authentication.\0" + 520 "Custom Authentication Message\0" + 521 "Connecting to %1...\0" + 522 "Connection Name\0" + 523 "Automatic\0" + 524 "PPTP VPN\0" + 525 "L2TP IPSec VPN\0" + 526 "Select the type of the connection.\0" + 527 "Type of Connection\0" + 528 "hh.exe netcfg.chm::/trouble_all.htm\0" + 529 "Virtual Private Connection\0" + 530 "Use any form of authentication required including clear text. Do not encrypt data.\0" + 531 "Use any form of authentication that requires passwords to be encrypted. Do not encrypt data.\0" + 532 "Please type a name for the entry.\0" + 533 "Encrypt passwords and data.\0" + 534 "Please type a port number between 1 and 65535.\0" + 535 "Specify custom authentication and data encryption with the Settings button.\0" + 536 "Use any form of authentication that requires encrypted passwords. Do not encrypt data.\0" + 537 "Encrypt passwords and data.\0" + 538 "Specify custom authentication and data encryption with the Settings button.\0" + 539 "The port number is already used by another entry.\nPlease enter a unique port number.\0" + 540 "Please enter one or more ports for incoming responses.\0" + 541 "Please select the entry to be deleted.\0" + 542 "1 second\0" + 543 "Please select the entry to be modified.\0" + 549 "What is the name of the other computer you are connecting to?\0" + 576 "20 minutes\0" + 579 "Specify a name for this connection to your workplace.\0" + 581 "Network Application Settings\0" + 582 "Type a name for this connection in the following box.\0" + 583 "Type the name of the other computer in the following box.\0" + 584 "Type the name of your ISP in the following box.\0" + 585 "What is the name of the service that provides your Internet connection?\0" + 586 "Please type the IP address of the server computer on the private network.\0" + 587 "Advanced Settings\0" + 588 "The entry name begins with a period. or contains some invalid characters. \nChoose a different name.\0" + 589 "Properties\0" + 1512 "Communications Port\0" + 1523 " channel\0" + 1526 "Smart Cards\0" + 1527 "You can use your smart card with this connection.\0" + 1528 "Direct Connection\0" + 1529 "Please select a device for this connection.\0" + 1530 "Verdana Bold\0" + 1531 "12\0" + 1532 "Connection Type\0" + 1533 "Select the type of demand dial interface you want to create.\0" + 1534 "Select a device\0" + 1535 "This is the device that will be used to make the connection.\0" + 1536 "Phone Number\0" + 1537 "Enter the phone number of the remote server or router you are calling.\0" + 1538 "VPN Type\0" + 1539 "Select the type of VPN interface you want to create.\0" + 1540 "Destination Address\0" + 1541 "What is the name or address of the remote router?\0" + 1544 "IP Address\0" + 1545 "Configure this router's IP address for this interface.\0" + 1546 "Name Server Addresses\0" + 1547 "Configure DNS and WINS addresses for use by this interface.\0" + 1548 "Router Scripting\0" + 1549 "You can set up a scripting for connecting to the remote router.\0" + 1550 "Dial In Credentials\0" + 1551 "Configure the user name and password that the remote router will use when it dials in to this server.\0" + 1552 "Dial Out Credentials\0" + 1553 "Configure the user name and password to be used when connecting to the remote router.\0" + 1554 "Interface Name\0" + 1555 "Select the name by which this new interface will be known.\0" + 1556 "No available devices\0" + 1557 "A user account named %1 already exists on the local computer. Should the demand dial interface be configured to use this user account?\0" + 1558 "There are no security protocol settings for SLIP server connections.\0" + 1559 "Allow unsecured password\0" + 1560 "Require secured password\0" + 1561 "Use smart card\0" + 1562 "You must select at least one password authentication protocol.\0" + 1563 "No encryption allowed (server will disconnect if it requires encryption)\0" + 1564 "Optional encryption (connect even if no encryption)\0" + 1565 "Require encryption (disconnect if server declines)\0" + 1566 "Maximum strength encryption (disconnect if server declines)\0" + 1567 " (encryption enabled)\0" + 1568 "Internet Account Information\0" + 1569 "You will need an account name and password to sign in to your Internet account.\0" + 1570 "The selected EAP package does not provide encryption keys. Select an EAP package that does provide keys or select not to encrypt.\0" + 1571 "The current encryption selection requires EAP or some version of MS-CHAP logon security methods.\0" + 1572 "Protocols and Security\0" + 1573 "Select transports and security options for this connection.\0" + 1574 "The protocols you have selected include PAP, SPAP, and/or CHAP. If one of these is negotiated, data encryption will not occur. Do you want to keep these settings?\0" + 1575 "To connect to '%1', you must first be connected to '%2'. Do you want to connect to '%2' now?\0" + 1576 "Connecting over parallel cable...\0" + 1577 "Connecting over infrared...\0" + 1578 "Parallel cable connected.\0" + 1579 "Infrared connected.\0" + 1580 "This connection was configured to use a data encryption strength that is not supported by the installed software. The security properties of this connection have been reset to the available encryption strengths.\0" + 1581 "Typ&e of VPN:\0" + 1582 "Please enter a user name.\0" + 1583 "This user name and password will be saved for your own use. There is already a user name and password saved for all other users of this connection. Do you want to delete the user name and password saved for all other users?\0" + 1584 "For example, you could type the name of your workplace or the name of a server you will connect to.\0" + 1585 "Account Information\0" + 1586 "The controls on this property sheet are disabled because the system must first be rebooted before any configuration changes can be made.\0" + 1587 "The controls on this property sheet are disabled because one or more other Network property sheets are already open. To use these controls, close all these property sheets and then reopen this one.\0" + 1588 "Some of the controls on this property sheet are disabled because you do not have sufficient privileges to access them.\0" + 1589 "The following message was received from your service provider:\r\n\r\n%1\0" + 1590 "Reconnect %1\0" + 1591 "Service Name\0" + 1592 "What is the name of the service that provides your broadband connection?\0" + 1593 "You will need an account name and password to sign on to your account\0" + 1594 "PPPOE1-0\0" + 1595 "Point-to-Point Protocol over Ethernet (PPPoE)\0" + 1596 "Type of &broadband connection to make:\0" + 1611 "Broadband Connection\0" + 1612 "You have selected to use a preshared key but you have not entered one. \nPlease enter a preshared key.\0" + 1613 "Cannot Commit Credentials\0" + 1634 "Because the Windows Management Instrumentation (WMI) service has been disabled, ReactOS cannot display the properties of this connection or the home network.\n\nTo configure the properties of this connection or your home network, you must first enable the WMI service. To do this, in the Administrative Tools control panel, double-click Services, right-click Windows Management Instrumentation, and then click Start.\0" + 1635 "ReactOS cannot display the properties of this connection. The Windows Management Instrumentation (WMI) information might be corrupted. To correct this, use System Restore to restore ReactOS to an earlier time (called a restore point). System Restore is located in the System Tools folder in Accessories.\0" + 1646 "Allow incoming echo request\0" + 1647 "Allow incoming timestamp request\0" + 1648 "Allow incoming mask request\0" + 1649 "Allow incoming router request\0" + 1650 "Allow outgoing destination unreachable\0" + 1651 "Allow outgoing source quench\0" + 1652 "Allow outgoing parameter problem\0" + 1653 "Allow outgoing time exceeded\0" + 1654 "Allow redirect\0" + 1655 "log\0" + 1656 "*.log\0" + 1657 "Firewall log files (*.log)\0" + 1658 "Browse\0" + 1663 "Select a private network connection\0" + 1664 "To enable Internet Connection Sharing a connection must be selected for the private network. Please select a connection from the list of available connections.\0" + 1665 "Messages sent to this computer will be repeated back to the sender. This is commonly used for troubleshooting, for example, to ping a machine.\0" + 1666 "Data sent to this computer can be acknowledged with a confirmation message indicating the time that the data was received.\0" + 1667 "This computer will listen for and respond to requests for more information about the public network to which it is attached.\0" + 1668 "This computer will respond to requests for information about the routes it recognizes.\0" + 1669 "Data sent over the Internet that fails to reach this computer due to an error will be discarded and acknowledged with a ""destination unreachable"" message explaining the failure.\0" + 1670 "When this computer's ability to process incoming data cannot keep up with the rate of a transmission, data will be dropped and the sender will be asked to slow down.\0" + 1671 "When this computer discards data it has received due to a problematic header, it will reply to the sender with a ""bad header"" error message.\0" + 1672 "When this computer discards an incomplete data transmission because the entire transmission required more time than allowed, it will reply to the sender with a ""time expired"" message.\0" + 1673 "Data sent from this computer will be rerouted if the default path changes.\0" + 1675 "The value entered for the log file size is not valid. Enter a value between 1 and 32767 k.\0" + 1685 "Your user account does not have permission to use this connection. Usually, this is because you are logged in as Guest.\0" + 1686 "Type an account name and password. (If you have forgotten an existing account name or password, contact your network administrator.)\0" + 1687 "Computer N&ame\0" + 1688 "ISP N&ame\0" + 1689 "Company N&ame\0" + 1690 "What is the phone number you will use to make this connection?\n\0" + 7301 "Incoming TCP/IP Properties\0" + 7302 "You must choose a value from %1 to %2 for this field.\0" + 7306 "Incoming Connections Error\0" + 7307 "Incoming Connections General Error\0" + 7308 "Incoming Connections\0" + 7309 "Incoming Connections Networking Error\0" + 7310 "Incoming Connections Multilink Status Error\0" + 7311 "Incoming Connections Error\0" + 7312 "Incoming Connections Initialization Error\0" + 7313 "Incoming Connections TCP/IP Properties Error\0" + 7314 "Incoming Connections IPX Properties Error\0" + 7315 "Incoming Connections Error\0" + 7316 "Generic\0" + 7317 "Device\0" + 7318 "Miscellaneous Database\0" + 7319 "User Database\0" + 7320 "Protocol Database\0" + 7321 "You must enter a logon name for the new user or press cancel.\0" + 7322 "The password you entered was too short.\0" + 7323 "The passwords entered are not the same. Please re-enter them.\0" + 7324 "An internal error has occured. \0" + 7325 "Listview\0" + 7326 "An error has occurred while attempting to commit the changes you have made to the local user database. \0" + 7327 "You have insufficient priveleges to add a user to the local system database. \0" + 7328 "The user you are trying create already exists in the local user database.\0" + 7329 "The user was not added to the local user database because the password you entered was rejected.\0" + 7330 "Unable to reload the system user database because of an internal error.\0" + 7331 "An internal error has occurred: The local user database handle is corrupt.\0" + 7332 "Unable to load the resources neccessary to display the user tab.\0" + 7333 "An internal error occured while attempting to rollback the changes you made to the local user database. \0" + 7334 "The device database handle is corrupt.\0" + 7335 "Unable to load the resources neccessary to display the general tab.\0" + 7336 "An error has occurred while attempting to commit some of the device/vpn related changes you have made. \0" + 7337 "An internal error occured.\0" + 7338 "An internal error occurred: The networking component database handle is corrupt.\0" + 7339 "An internal error has occurred. \0" + 7340 "An error has occurred while attempting to commit the changes you have made to the networking components.\0" + 7341 "An internal error occured.\0" + 7342 "Unable to commit the changes you made to the TCP/IP protocol to the system. \0" + 7343 "Unable to save the changes you made to the IPX protocol to the system. \0" + 7344 "Unable to display the TCP/IP properties.\0" + 7345 "Unable to display the IPX properties.\0" + 7346 "Unable to load TCP/IP properties from the system. \0" + 7347 "Unable to load IPX properties from the system. \0" + 7348 "Incoming Connections depend on the Routing and Remote Access service which was unable to start. For more information, check the system event log.\0" + 7349 "Unable to allow the editing of networking components at this time because they are currently being modified elsewhere.\0" + 7350 "The new user you entered was not added to the local user database because the name or password entered violated a system policy (it was too large, too small, or ill-formed). \0" + 7351 "The system is unable to delete the requested user. \0" + 7352 "Unable to remove the selected network component because it is in use.\0" + 7353 "Incoming Connections Warning\0" + 7354 "Any users that you delete will be permanently removed from the system even if cancel is pressed. Are you sure you want to permanently remove %s? \0" + 7355 "You are about to switch to a system management console. This Incoming Connections property sheet will be closed and any changes you may have made will be committed to the system. Is it ok to continue?\0" + 7356 "Your Network Mask value has been changed. A zero bit in a mask can only be followed by other zero bits. For example, a Network Mask value, expressed in decimal dotted notation, of 255.255.0.0, is valid, but 255.0.255.0 is not. \n\0" + 7357 "User Permissions\0" + 7358 "You can specify the users who can connect to this computer.\0" + 7359 "Devices for Incoming Connections\0" + 7360 "You can choose the devices your computer uses to accept incoming connections.\0" + 7361 "Incoming Virtual Private Network (VPN) Connection\0" + 7362 "Another computer can connect to yours through a VPN connection\0" + 7363 "Networking Software\0" + 7364 "Networking software allows this computer to accept connections from other kinds of computers.\0" + 7365 "Completing the New Connection Wizard\0" + 7366 " \0" + 7367 "Incoming Connections\0" + 7371 "No hardware capable of accepting calls is installed.\0" + 7372 " \0" + 7373 "Assign specified &network number:\0" + 7374 "Assign &network numbers sequentially from:\0" + 7375 "New User\0" + 7376 "Connection Device\0" + 7377 "What device do you want to use to make this connection?\0" + 7378 "No devices capable of accepting direct connections are currently installed.\0" + 7379 "New Incoming Connection Warning\0" + 7380 "Because this Win 2000 Server belongs to or controls a domain, you must use the Routing and Remote Access system console to configure this machine to receive incoming connections. Cancel changes and switch to this console?\n\0" + 7381 "A&ssign network number automatically\0" + 7382 "A&ssign network numbers automatically\0" + 7383 "Incoming Connections can not issue the ipx network numbers 00000000 or FFFFFFFF. Please either change the assigned network numbers or use automatic network number assignment.\0" + 7384 "to\0" + 7385 "Communications Port (%s)\0" + 7386 "Network Connections does not display some specialized options for inbound connections that have been set using the Local User Manager or Remote Access Policy consoles. For complete and correct information on incoming connections, you will need to use these consoles.\0" + 7387 "The user callback mode you have selected requires you to enter a valid callback number.\0" + 7388 "ReactOS must reboot to complete the operation. Is it ok to reboot now?\0" + 7389 "The currently selected device has no configuration options available.\0" + 7390 "Invalid Range\0" + 7391 "You have requested that '%1' be disabled for Incoming Connections. In order to disable this, you must stop the 'Server' service. Once stopped, any shared directories or printers on this computer will no longer be available to any other computer. Do you want to bring up a system console that will allow you to stop the 'Server' service?\r\n\nUnder Computer Management, click System Tools and then click Services. In the right pane, right-click Server and click stop.\0" + 7392 "This serial port is not enabled for use in a direct connection to another computer. It will be enabled after you complete this wizard. You can then configure the port speed and other properties by right-clicking the icon for this connection and selecting Properties.\n\0" + 7393 "Incoming Connections\0" + 7394 "The IP address pool you've entered is invalid.\0" + 7395 "The mask provided is invalid.\0" + 7396 "The start address entered for the TCP/IP pool is invalid. It must lie between 1.0.0.0 and 224.0.0.0 and it must not be in the form 127.x.x.x.\0" + 7397 "The TCP/IP pool entered is invalid because the address is more specific than the mask.\0" + 7398 "The start address must be less than the end address.\0" + 7399 "The Routing and Remote Access Service is in the process of stopping. Until it stops, the Incoming Connections option is not available. Please wait a few moments and retry.\0" + 7400 "%s (%s)\0" + 7401 "%s (%d channels)\0" + 7402 "Incoming Connection VPN (PPTP)\0" + 7403 "Incoming Connection VPN (L2TP)\0" + 7404 "IP Security (IKE)\0" + 7405 "127.0.0.1\0" + 7406 "You do not have sufficient privileges to set up Incoming Connections\0" + 29900 "Cannot load the Remote Access Connection Manager service.\0" + 29901 "Cannot load the file MPRAPI.DLL in the system32 directory.\0" +END diff --git a/dll/win32/rasdlg/rasdlg.rc b/dll/win32/rasdlg/rasdlg.rc index 79395a59f50..07b1de0fb2e 100644 --- a/dll/win32/rasdlg/rasdlg.rc +++ b/dll/win32/rasdlg/rasdlg.rc @@ -61,6 +61,9 @@ #ifdef LANGUAGE_SQ_AL #include "lang/sq-AL.rc" #endif +#ifdef LANGUAGE_TR_TR + #include "lang/tr-TR.rc" +#endif #ifdef LANGUAGE_UK_UA #include "lang/uk-UA.rc" #endif diff --git a/dll/win32/samsrv/lang/tr-TR.rc b/dll/win32/samsrv/lang/tr-TR.rc index 841faeaa75d..123247e03fd 100644 --- a/dll/win32/samsrv/lang/tr-TR.rc +++ b/dll/win32/samsrv/lang/tr-TR.rc @@ -10,9 +10,9 @@ BEGIN IDS_ALIAS_ADMINISTRATORS_NAME "Yöneticiler" IDS_ALIAS_ADMINISTRATORS_COMMENT "Yöneticiler, bilgisayara veyâ etki alanına kısıtlı olmayan erişime iyedir." IDS_ALIAS_GUESTS_NAME "Konuklar" - IDS_ALIAS_GUESTS_COMMENT "Konuklar, ön tanımlı olarak Kullanıcılar takımının üyeleriyle eşit haklara iyedir." + IDS_ALIAS_GUESTS_COMMENT "Konuklar, ön tanımlı olarak Kullanıcılar takımının üyeleriyle eşit yetkilere iyedir." IDS_ALIAS_POWER_USERS_NAME "Güçlü Kullanıcılar" - IDS_ALIAS_POWER_USERS_COMMENT "Güçlü Kullanıcılar, birtakım kısıtlamalarla çoğu yönetim haklarına iyedir." + IDS_ALIAS_POWER_USERS_COMMENT "Güçlü Kullanıcılar, birtakım kısıtlamalarla çoğu yönetim yetkilerine iyedir." IDS_ALIAS_USERS_NAME "Kullanıcılar" IDS_ALIAS_USERS_COMMENT "Kullanıcılar, dizge değişiklikleri yapmaktan alıkonulmuştur." /* diff --git a/dll/win32/shlwapi/lang/shlwapi_Da.rc b/dll/win32/shlwapi/lang/shlwapi_Da.rc index 2ce6736f102..602312d648f 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Da.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Da.rc @@ -20,20 +20,6 @@ LANGUAGE LANG_DANISH, SUBLANG_DEFAULT -IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 -STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Fejl!" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 - LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 - CHECKBOX "Vis ikke denne besked igen", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Annuller", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Ja", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Nej", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP -} - STRINGTABLE { IDS_BYTES_FORMAT "%ld bytes" @@ -41,3 +27,17 @@ STRINGTABLE IDS_TIME_INTERVAL_MINUTES " min" IDS_TIME_INTERVAL_SECONDS " sec" } + +IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 +STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Fejl" +FONT 8, "MS Shell Dlg" +{ + LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 + LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 + CHECKBOX "Vis ikke denne besked igen", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + PUSHBUTTON "&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Annuller", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Ja", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Nej", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP +} diff --git a/dll/win32/shlwapi/lang/shlwapi_De.rc b/dll/win32/shlwapi/lang/shlwapi_De.rc index b5f5eb03efe..d40dac6f1fc 100644 --- a/dll/win32/shlwapi/lang/shlwapi_De.rc +++ b/dll/win32/shlwapi/lang/shlwapi_De.rc @@ -22,20 +22,6 @@ LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL -IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 -STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Fehler!" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 - LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 - CHECKBOX "&Diesen Dialog nicht mehr anzeigen", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Abbrechen", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Ja", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Nein", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP -} - STRINGTABLE { IDS_BYTES_FORMAT "%ld Bytes" @@ -43,3 +29,17 @@ STRINGTABLE IDS_TIME_INTERVAL_MINUTES " Min" IDS_TIME_INTERVAL_SECONDS " Sek" } + +IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 +STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Fehler" +FONT 8, "MS Shell Dlg" +{ + LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 + LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 + CHECKBOX "&Diesen Dialog nicht mehr anzeigen", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + PUSHBUTTON "&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Abbrechen", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Ja", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Nein", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP +} diff --git a/dll/win32/shlwapi/lang/shlwapi_En.rc b/dll/win32/shlwapi/lang/shlwapi_En.rc index d3f2e395e11..e9e774f1792 100644 --- a/dll/win32/shlwapi/lang/shlwapi_En.rc +++ b/dll/win32/shlwapi/lang/shlwapi_En.rc @@ -20,20 +20,6 @@ LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT -IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 -STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Error!" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 - LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 - CHECKBOX "Don't show me th&is message again", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Cancel", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Yes", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&No", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP -} - STRINGTABLE { IDS_BYTES_FORMAT "%ld bytes" @@ -41,3 +27,17 @@ STRINGTABLE IDS_TIME_INTERVAL_MINUTES " min" IDS_TIME_INTERVAL_SECONDS " sec" } + +IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 +STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Error" +FONT 8, "MS Shell Dlg" +{ + LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 + LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 + CHECKBOX "Don't show me th&is message again", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + PUSHBUTTON "OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "Cancel", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Yes", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&No", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP +} diff --git a/dll/win32/shlwapi/lang/shlwapi_Es.rc b/dll/win32/shlwapi/lang/shlwapi_Es.rc index 64cdd69b817..cd7835f6644 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Es.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Es.rc @@ -20,9 +20,17 @@ LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld bytes" + IDS_TIME_INTERVAL_HOURS " hr" + IDS_TIME_INTERVAL_MINUTES " min" + IDS_TIME_INTERVAL_SECONDS " sec" +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Error!" +CAPTION "Error" FONT 8, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -33,11 +41,3 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "&S", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&No", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld bytes" - IDS_TIME_INTERVAL_HOURS " hr" - IDS_TIME_INTERVAL_MINUTES " min" - IDS_TIME_INTERVAL_SECONDS " sec" -} diff --git a/dll/win32/shlwapi/lang/shlwapi_Fi.rc b/dll/win32/shlwapi/lang/shlwapi_Fi.rc index 7ca9fcad241..4bb001971d2 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Fi.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Fi.rc @@ -20,9 +20,17 @@ LANGUAGE LANG_FINNISH, SUBLANG_DEFAULT +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld bytes" + IDS_TIME_INTERVAL_HOURS " hr" + IDS_TIME_INTERVAL_MINUTES " min" + IDS_TIME_INTERVAL_SECONDS " sec" +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Virhe!" +CAPTION "Virhe" FONT 8, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -33,11 +41,3 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "&Kyll", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Ei", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld bytes" - IDS_TIME_INTERVAL_HOURS " hr" - IDS_TIME_INTERVAL_MINUTES " min" - IDS_TIME_INTERVAL_SECONDS " sec" -} diff --git a/dll/win32/shlwapi/lang/shlwapi_Fr.rc b/dll/win32/shlwapi/lang/shlwapi_Fr.rc index 2354e396ad0..31cbb0262dc 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Fr.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Fr.rc @@ -23,20 +23,6 @@ LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL -IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 -STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Erreur !" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 - LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 - CHECKBOX "Ne plus me montrer ce message", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Annuler", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Oui", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Non", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP -} - STRINGTABLE { IDS_BYTES_FORMAT "%ld bytes" @@ -44,3 +30,17 @@ STRINGTABLE IDS_TIME_INTERVAL_MINUTES " min" IDS_TIME_INTERVAL_SECONDS " s" } + +IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 +STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Erreur" +FONT 8, "MS Shell Dlg" +{ + LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 + LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 + CHECKBOX "Ne plus me montrer ce message", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + PUSHBUTTON "&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Annuler", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Oui", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Non", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP +} diff --git a/dll/win32/shlwapi/lang/shlwapi_He.rc b/dll/win32/shlwapi/lang/shlwapi_He.rc index 7266c30b1ad..3c2cda60dc4 100644 --- a/dll/win32/shlwapi/lang/shlwapi_He.rc +++ b/dll/win32/shlwapi/lang/shlwapi_He.rc @@ -22,9 +22,17 @@ LANGUAGE LANG_HEBREW, SUBLANG_DEFAULT +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld בית" + IDS_TIME_INTERVAL_HOURS " שעות" + IDS_TIME_INTERVAL_MINUTES " דקות" + IDS_TIME_INTERVAL_SECONDS " שניות" +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "שגיאה!" +CAPTION "שגיאה" FONT 8, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -35,11 +43,3 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "כן", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "לא", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld בית" - IDS_TIME_INTERVAL_HOURS " שעות" - IDS_TIME_INTERVAL_MINUTES " דקות" - IDS_TIME_INTERVAL_SECONDS " שניות" -} diff --git a/dll/win32/shlwapi/lang/shlwapi_Hu.rc b/dll/win32/shlwapi/lang/shlwapi_Hu.rc index f9b8866a777..37b6f292b8c 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Hu.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Hu.rc @@ -23,9 +23,17 @@ LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld bájt" + IDS_TIME_INTERVAL_HOURS " óra" + IDS_TIME_INTERVAL_MINUTES " perc" + IDS_TIME_INTERVAL_SECONDS " mp" +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Hiba!" +CAPTION "Hiba" FONT 8, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -36,11 +44,3 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "&Igen", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Nem", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld bájt" - IDS_TIME_INTERVAL_HOURS " óra" - IDS_TIME_INTERVAL_MINUTES " perc" - IDS_TIME_INTERVAL_SECONDS " mp" -} diff --git a/dll/win32/shlwapi/lang/shlwapi_It.rc b/dll/win32/shlwapi/lang/shlwapi_It.rc index 304c0ee01cf..23cda413b65 100644 --- a/dll/win32/shlwapi/lang/shlwapi_It.rc +++ b/dll/win32/shlwapi/lang/shlwapi_It.rc @@ -20,20 +20,6 @@ LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL -IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 -STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Errore!" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 - LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 - CHECKBOX "Non mostrare nuovamente &questo messaggio", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Annulla", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Si", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&No", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP -} - STRINGTABLE { IDS_BYTES_FORMAT "%ld bytes" @@ -41,3 +27,17 @@ STRINGTABLE IDS_TIME_INTERVAL_MINUTES " min" IDS_TIME_INTERVAL_SECONDS " sec" } + +IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 +STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Errore" +FONT 8, "MS Shell Dlg" +{ + LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 + LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 + CHECKBOX "Non mostrare nuovamente &questo messaggio", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + PUSHBUTTON "&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Annulla", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Si", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&No", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP +} diff --git a/dll/win32/shlwapi/lang/shlwapi_Ja.rc b/dll/win32/shlwapi/lang/shlwapi_Ja.rc index 2e4d725d19e..bd3e6605937 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Ja.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Ja.rc @@ -23,9 +23,17 @@ LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld bytes" + IDS_TIME_INTERVAL_HOURS " hr" + IDS_TIME_INTERVAL_MINUTES " min" + IDS_TIME_INTERVAL_SECONDS " sec" +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "エラー!" +CAPTION "エラー" FONT 9, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -36,11 +44,3 @@ FONT 9, "MS Shell Dlg" PUSHBUTTON "はい(&Y)", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "いいえ(&N)", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld bytes" - IDS_TIME_INTERVAL_HOURS " hr" - IDS_TIME_INTERVAL_MINUTES " min" - IDS_TIME_INTERVAL_SECONDS " sec" -} diff --git a/dll/win32/shlwapi/lang/shlwapi_Ko.rc b/dll/win32/shlwapi/lang/shlwapi_Ko.rc index 2c8793ea44b..d973ebdf20a 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Ko.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Ko.rc @@ -20,9 +20,17 @@ LANGUAGE LANG_KOREAN, SUBLANG_DEFAULT +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld Ʈ" + IDS_TIME_INTERVAL_HOURS "" + IDS_TIME_INTERVAL_MINUTES " " + IDS_TIME_INTERVAL_SECONDS " " +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "!" +CAPTION "" FONT 9, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -33,12 +41,3 @@ FONT 9, "MS Shell Dlg" PUSHBUTTON "(&Y)", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "ƴϿ(&N)", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld Ʈ" - IDS_TIME_INTERVAL_HOURS "" - IDS_TIME_INTERVAL_MINUTES " " - IDS_TIME_INTERVAL_SECONDS " " -} diff --git a/dll/win32/shlwapi/lang/shlwapi_Lt.rc b/dll/win32/shlwapi/lang/shlwapi_Lt.rc index 7dd490965f9..3bc3f794bd4 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Lt.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Lt.rc @@ -23,20 +23,6 @@ LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL -IDD_ERR_DIALOG DIALOG 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 { IDS_BYTES_FORMAT "%ld baitai" @@ -44,3 +30,17 @@ STRINGTABLE IDS_TIME_INTERVAL_MINUTES " min" IDS_TIME_INTERVAL_SECONDS " sek" } + +IDD_ERR_DIALOG DIALOG 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 "&Gerai", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Atsisakyti", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Taip", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Ne", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP +} diff --git a/dll/win32/shlwapi/lang/shlwapi_Nl.rc b/dll/win32/shlwapi/lang/shlwapi_Nl.rc index 0203c88094e..f533db7b226 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Nl.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Nl.rc @@ -20,20 +20,6 @@ LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL -IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 -STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Fout!" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 - LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 - CHECKBOX "Deze boodschap &niet opnieuw tonen", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Annuleren", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Ja", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Nee", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP -} - STRINGTABLE { IDS_BYTES_FORMAT "%ld bytes" @@ -41,3 +27,17 @@ STRINGTABLE IDS_TIME_INTERVAL_MINUTES " min" IDS_TIME_INTERVAL_SECONDS " sec" } + +IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 +STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Fout" +FONT 8, "MS Shell Dlg" +{ + LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 + LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 + CHECKBOX "Deze boodschap &niet opnieuw tonen", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + PUSHBUTTON "&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Annuleren", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Ja", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Nee", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP +} diff --git a/dll/win32/shlwapi/lang/shlwapi_No.rc b/dll/win32/shlwapi/lang/shlwapi_No.rc index cce32f074da..b4de67aacae 100644 --- a/dll/win32/shlwapi/lang/shlwapi_No.rc +++ b/dll/win32/shlwapi/lang/shlwapi_No.rc @@ -20,6 +20,14 @@ LANGUAGE LANG_NORWEGIAN, SUBLANG_NORWEGIAN_BOKMAL +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld byte" + IDS_TIME_INTERVAL_HOURS " hr" + IDS_TIME_INTERVAL_MINUTES " min" + IDS_TIME_INTERVAL_SECONDS " sec" +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Feil" @@ -28,16 +36,8 @@ FONT 8, "MS Shell Dlg" LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 CHECKBOX "&Ikke vis denne meldingen igjen", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Avbryt", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Ja", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Nei", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP -} - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld byte" - IDS_TIME_INTERVAL_HOURS " hr" - IDS_TIME_INTERVAL_MINUTES " min" - IDS_TIME_INTERVAL_SECONDS " sec" + PUSHBUTTON "&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Avbryt", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Ja", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Nei", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } diff --git a/dll/win32/shlwapi/lang/shlwapi_Pl.rc b/dll/win32/shlwapi/lang/shlwapi_Pl.rc index 1f3298f9827..8d0b13aa57d 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Pl.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Pl.rc @@ -21,20 +21,6 @@ LANGUAGE LANG_POLISH, SUBLANG_DEFAULT -IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 -STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Bd!" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 - LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 - CHECKBOX "Nie pokazuj w&icej tego komunikatu", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Anuluj", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Tak", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Nie", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP -} - STRINGTABLE { IDS_BYTES_FORMAT "%ld bajtw" @@ -42,3 +28,17 @@ STRINGTABLE IDS_TIME_INTERVAL_MINUTES " min." IDS_TIME_INTERVAL_SECONDS " s" } + +IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 +STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Bd" +FONT 8, "MS Shell Dlg" +{ + LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 + LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 + CHECKBOX "Nie pokazuj w&icej tego komunikatu", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + PUSHBUTTON "&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Anuluj", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Tak", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Nie", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP +} diff --git a/dll/win32/shlwapi/lang/shlwapi_Pt.rc b/dll/win32/shlwapi/lang/shlwapi_Pt.rc index 5f799583771..eb801b19d5f 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Pt.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Pt.rc @@ -24,9 +24,17 @@ LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld bytes" + IDS_TIME_INTERVAL_HOURS " hr" + IDS_TIME_INTERVAL_MINUTES " min" + IDS_TIME_INTERVAL_SECONDS " seg" +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Erro!" +CAPTION "Erro" FONT 8, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -37,11 +45,3 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "&Sim", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Não", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld bytes" - IDS_TIME_INTERVAL_HOURS " hr" - IDS_TIME_INTERVAL_MINUTES " min" - IDS_TIME_INTERVAL_SECONDS " seg" -} diff --git a/dll/win32/shlwapi/lang/shlwapi_Ro.rc b/dll/win32/shlwapi/lang/shlwapi_Ro.rc index ad7d830d250..e8b7faf692a 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Ro.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Ro.rc @@ -18,13 +18,21 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#pragma code_page(65001) + LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL -#pragma code_page(65001) +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld octeți" + IDS_TIME_INTERVAL_HOURS " ore" + IDS_TIME_INTERVAL_MINUTES " min" + IDS_TIME_INTERVAL_SECONDS " sec" +} IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Eroare!" +CAPTION "Eroare" FONT 8, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -35,11 +43,3 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "&Da", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "N&u", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld octeți" - IDS_TIME_INTERVAL_HOURS " ore" - IDS_TIME_INTERVAL_MINUTES " min" - IDS_TIME_INTERVAL_SECONDS " sec" -} diff --git a/dll/win32/shlwapi/lang/shlwapi_Ru.rc b/dll/win32/shlwapi/lang/shlwapi_Ru.rc index bda962c7467..f1d1bfc1434 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Ru.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Ru.rc @@ -23,9 +23,17 @@ LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld байт" + IDS_TIME_INTERVAL_HOURS " час" + IDS_TIME_INTERVAL_MINUTES " мин" + IDS_TIME_INTERVAL_SECONDS " сек" +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Ошибка!" +CAPTION "Ошибка" FONT 8, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -36,11 +44,3 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "&Да", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Нет", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld байт" - IDS_TIME_INTERVAL_HOURS " час" - IDS_TIME_INTERVAL_MINUTES " мин" - IDS_TIME_INTERVAL_SECONDS " сек" -} diff --git a/dll/win32/shlwapi/lang/shlwapi_Si.rc b/dll/win32/shlwapi/lang/shlwapi_Si.rc index bbd1d0c6e7a..cf8233abc33 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Si.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Si.rc @@ -22,9 +22,17 @@ LANGUAGE LANG_SLOVENIAN, SUBLANG_DEFAULT +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld bajtov" + IDS_TIME_INTERVAL_HOURS " ur" + IDS_TIME_INTERVAL_MINUTES " min" + IDS_TIME_INTERVAL_SECONDS " sek" +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Napak!" +CAPTION "Napak" FONT 8, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -35,11 +43,3 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "&Da", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Ne", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld bajtov" - IDS_TIME_INTERVAL_HOURS " ur" - IDS_TIME_INTERVAL_MINUTES " min" - IDS_TIME_INTERVAL_SECONDS " sek" -} diff --git a/dll/win32/shlwapi/lang/shlwapi_Sk.rc b/dll/win32/shlwapi/lang/shlwapi_Sk.rc index 8c2287749c4..c42c3789123 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Sk.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Sk.rc @@ -20,9 +20,17 @@ LANGUAGE LANG_SLOVAK, SUBLANG_DEFAULT +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld bajtov" + IDS_TIME_INTERVAL_HOURS " hod." + IDS_TIME_INTERVAL_MINUTES " min." + IDS_TIME_INTERVAL_SECONDS " s" +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Chyba!" +CAPTION "Chyba" FONT 8, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -33,11 +41,3 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "n&o", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Nie", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld bajtov" - IDS_TIME_INTERVAL_HOURS " hod." - IDS_TIME_INTERVAL_MINUTES " min." - IDS_TIME_INTERVAL_SECONDS " s" -} diff --git a/dll/win32/shlwapi/lang/shlwapi_Sq.rc b/dll/win32/shlwapi/lang/shlwapi_Sq.rc index 94e2456e314..5ee98af0c3c 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Sq.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Sq.rc @@ -20,20 +20,6 @@ LANGUAGE LANG_ALBANIAN, SUBLANG_NEUTRAL -IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 -STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Gabim!" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 - LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 - CHECKBOX "Mos më tregoni këtë mesazh përsëri", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Anulo", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Po", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Jo", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP -} - STRINGTABLE { IDS_BYTES_FORMAT "%ld bytes" @@ -41,3 +27,17 @@ STRINGTABLE IDS_TIME_INTERVAL_MINUTES " min" IDS_TIME_INTERVAL_SECONDS " sek" } + +IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 +STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Gabim" +FONT 8, "MS Shell Dlg" +{ + LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 + LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 + CHECKBOX "Mos më tregoni këtë mesazh përsëri", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + PUSHBUTTON "&OK", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Anulo", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Po", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Jo", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP +} diff --git a/dll/win32/shlwapi/lang/shlwapi_Sv.rc b/dll/win32/shlwapi/lang/shlwapi_Sv.rc index f3f6e734e5a..e5c69946883 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Sv.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Sv.rc @@ -20,9 +20,17 @@ LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld byte" + IDS_TIME_INTERVAL_HOURS " h" + IDS_TIME_INTERVAL_MINUTES " min" + IDS_TIME_INTERVAL_SECONDS " s" +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Fel!" +CAPTION "Fel" FONT 8, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -33,11 +41,3 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "&Ja", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Nej", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld byte" - IDS_TIME_INTERVAL_HOURS " h" - IDS_TIME_INTERVAL_MINUTES " min" - IDS_TIME_INTERVAL_SECONDS " s" -} diff --git a/dll/win32/shlwapi/lang/shlwapi_Tr.rc b/dll/win32/shlwapi/lang/shlwapi_Tr.rc index df1b0fdd9f0..e018dc11f4f 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Tr.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Tr.rc @@ -20,20 +20,6 @@ LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT -IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 -STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Yanlışlık!" -FONT 8, "MS Shell Dlg" -{ - LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 - LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 - CHECKBOX "&Bana Bu İletiyi Bir Daha Gösterme", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Tamam", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&İptal", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Evet", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP - PUSHBUTTON L"&Hayır", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP -} - STRINGTABLE { IDS_BYTES_FORMAT "%ld çoklu" @@ -41,3 +27,17 @@ STRINGTABLE IDS_TIME_INTERVAL_MINUTES " dakîka" IDS_TIME_INTERVAL_SECONDS " sâniye" } + +IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 +STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Yanlışlık" +FONT 8, "MS Shell Dlg" +{ + LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 + LTEXT "", IDS_ERR_USER_MSG, 15, 5, 210, 8 + CHECKBOX "&Bana Bu İletiyi Bir Daha Gösterme", IDC_ERR_DONT_SHOW, 5, 20, 210, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Tamam", IDOK, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&İptal", IDCANCEL, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Evet", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP + PUSHBUTTON "&Hayır", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP +} diff --git a/dll/win32/shlwapi/lang/shlwapi_Uk.rc b/dll/win32/shlwapi/lang/shlwapi_Uk.rc index 0760fd71c22..bdd80e9a160 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Uk.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Uk.rc @@ -23,9 +23,17 @@ LANGUAGE LANG_UKRAINIAN, SUBLANG_DEFAULT +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld байт" + IDS_TIME_INTERVAL_HOURS " год" + IDS_TIME_INTERVAL_MINUTES " хв" + IDS_TIME_INTERVAL_SECONDS " сек." +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Помилка!" +CAPTION "Помилка" FONT 8, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -36,11 +44,3 @@ FONT 8, "MS Shell Dlg" PUSHBUTTON "&Так", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "&Ні", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld байт" - IDS_TIME_INTERVAL_HOURS " год" - IDS_TIME_INTERVAL_MINUTES " хв" - IDS_TIME_INTERVAL_SECONDS " сек." -} diff --git a/dll/win32/shlwapi/lang/shlwapi_Zh.rc b/dll/win32/shlwapi/lang/shlwapi_Zh.rc index e9f12855ea6..1d3b0487b20 100644 --- a/dll/win32/shlwapi/lang/shlwapi_Zh.rc +++ b/dll/win32/shlwapi/lang/shlwapi_Zh.rc @@ -23,9 +23,17 @@ LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED +STRINGTABLE +{ + IDS_BYTES_FORMAT "%ld 字节" + IDS_TIME_INTERVAL_HOURS " 小时" + IDS_TIME_INTERVAL_MINUTES " 分" + IDS_TIME_INTERVAL_SECONDS " 秒" +} + IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "错误!" +CAPTION "错误" FONT 9, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -37,19 +45,19 @@ FONT 9, "MS Shell Dlg" PUSHBUTTON "否(&N)", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } +LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_TRADITIONAL + STRINGTABLE { - IDS_BYTES_FORMAT "%ld 字节" - IDS_TIME_INTERVAL_HOURS " 小时" + IDS_BYTES_FORMAT "%ld 字節" + IDS_TIME_INTERVAL_HOURS " 小時" IDS_TIME_INTERVAL_MINUTES " 分" IDS_TIME_INTERVAL_SECONDS " 秒" } -LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_TRADITIONAL - IDD_ERR_DIALOG DIALOG 0, 0, 220, 60 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "錯誤!" +CAPTION "錯誤" FONT 9, "MS Shell Dlg" { LTEXT "", IDS_ERR_USER_MSG2, 15, 5, 28, 20 @@ -60,11 +68,3 @@ FONT 9, "MS Shell Dlg" PUSHBUTTON "是(&Y)", IDYES, 105, 40, 50, 14, WS_GROUP | WS_TABSTOP PUSHBUTTON "否(&N)", IDNO, 160, 40, 50, 14, WS_GROUP | WS_TABSTOP } - -STRINGTABLE -{ - IDS_BYTES_FORMAT "%ld 字節" - IDS_TIME_INTERVAL_HOURS " 小時" - IDS_TIME_INTERVAL_MINUTES " 分" - IDS_TIME_INTERVAL_SECONDS " 秒" -} diff --git a/dll/win32/shlwapi/ordinal.c b/dll/win32/shlwapi/ordinal.c index 83f683879ee..ad5ffa38a60 100644 --- a/dll/win32/shlwapi/ordinal.c +++ b/dll/win32/shlwapi/ordinal.c @@ -1,4 +1,4 @@ -/* +/* * SHLWAPI ordinal functions * * Copyright 1997 Marcus Meissner @@ -52,13 +52,24 @@ BOOL WINAPI SHAboutInfoW(LPWSTR,DWORD); */ /************************************************************************* - * SHLWAPI_DupSharedHandle + * @ [SHLWAPI.11] + * + * Copy a sharable memory handle from one process to another. + * + * PARAMS + * hShared [I] Shared memory handle to duplicate + * dwSrcProcId [I] ID of the process owning hShared + * dwDstProcId [I] ID of the process wanting the duplicated handle + * dwAccess [I] Desired DuplicateHandle() access + * dwOptions [I] Desired DuplicateHandle() options + * + * RETURNS + * Success: A handle suitable for use by the dwDstProcId process. + * Failure: A NULL handle. * - * Internal implementation of SHLWAPI_11. */ -static HANDLE SHLWAPI_DupSharedHandle(HANDLE hShared, DWORD dwDstProcId, - DWORD dwSrcProcId, DWORD dwAccess, - DWORD dwOptions) +HANDLE WINAPI SHMapHandle(HANDLE hShared, DWORD dwSrcProcId, DWORD dwDstProcId, + DWORD dwAccess, DWORD dwOptions) { HANDLE hDst, hSrc; DWORD dwMyProcId = GetCurrentProcessId(); @@ -71,7 +82,7 @@ static HANDLE SHLWAPI_DupSharedHandle(HANDLE hShared, DWORD dwDstProcId, if (dwDstProcId == dwMyProcId) hDst = GetCurrentProcess(); else - hDst = OpenProcess(PROCESS_DUP_HANDLE, FALSE, dwDstProcId); + hDst = OpenProcess(PROCESS_DUP_HANDLE, 0, dwDstProcId); if (hDst) { @@ -79,7 +90,7 @@ static HANDLE SHLWAPI_DupSharedHandle(HANDLE hShared, DWORD dwDstProcId, if (dwSrcProcId == dwMyProcId) hSrc = GetCurrentProcess(); else - hSrc = OpenProcess(PROCESS_DUP_HANDLE, FALSE, dwSrcProcId); + hSrc = OpenProcess(PROCESS_DUP_HANDLE, 0, dwSrcProcId); if (hSrc) { @@ -148,9 +159,8 @@ HANDLE WINAPI SHAllocShared(LPCVOID lpvData, DWORD dwSize, DWORD dwProcId) /* Release view. All further views mapped will be opaque */ UnmapViewOfFile(pMapped); - hRet = SHLWAPI_DupSharedHandle(hMap, dwProcId, - GetCurrentProcessId(), FILE_MAP_ALL_ACCESS, - DUPLICATE_SAME_ACCESS); + hRet = SHMapHandle(hMap, GetCurrentProcessId(), dwProcId, + FILE_MAP_ALL_ACCESS, DUPLICATE_SAME_ACCESS); } CloseHandle(hMap); @@ -175,32 +185,18 @@ PVOID WINAPI SHLockShared(HANDLE hShared, DWORD dwProcId) { HANDLE hDup; LPVOID pMapped; - DWORD thisProcessId = GetCurrentProcessId(); TRACE("(%p %d)\n", hShared, dwProcId); - if (dwProcId != thisProcessId) - { - /* Get handle to shared memory for current process */ - hDup = SHLWAPI_DupSharedHandle(hShared, dwProcId, GetCurrentProcessId(), - FILE_MAP_ALL_ACCESS, 0); - } - else - { - hDup = hShared; - } + /* Get handle to shared memory for current process */ + hDup = SHMapHandle(hShared, dwProcId, GetCurrentProcessId(), FILE_MAP_ALL_ACCESS, 0); /* Get View */ pMapped = MapViewOfFile(hDup, FILE_MAP_READ | FILE_MAP_WRITE, 0, 0, 0); - - if (dwProcId != thisProcessId) - { - CloseHandle(hDup); - } + CloseHandle(hDup); if (pMapped) - return (char *) pMapped + sizeof(DWORD); /* Hide size */ - + return (char *) pMapped + sizeof(DWORD); /* Hide size */ return NULL; } @@ -244,39 +240,12 @@ BOOL WINAPI SHFreeShared(HANDLE hShared, DWORD dwProcId) TRACE("(%p %d)\n", hShared, dwProcId); /* Get a copy of the handle for our process, closing the source handle */ - hClose = SHLWAPI_DupSharedHandle(hShared, dwProcId, GetCurrentProcessId(), - FILE_MAP_ALL_ACCESS, DUPLICATE_CLOSE_SOURCE); + hClose = SHMapHandle(hShared, dwProcId, GetCurrentProcessId(), + FILE_MAP_ALL_ACCESS,DUPLICATE_CLOSE_SOURCE); /* Close local copy */ return CloseHandle(hClose); } -/************************************************************************* - * @ [SHLWAPI.11] - * - * Copy a sharable memory handle from one process to another. - * - * PARAMS - * hShared [I] Shared memory handle to duplicate - * dwDstProcId [I] ID of the process wanting the duplicated handle - * dwSrcProcId [I] ID of the process owning hShared - * dwAccess [I] Desired DuplicateHandle() access - * dwOptions [I] Desired DuplicateHandle() options - * - * RETURNS - * Success: A handle suitable for use by the dwDstProcId process. - * Failure: A NULL handle. - * - */ -HANDLE WINAPI SHMapHandle(HANDLE hShared, DWORD dwDstProcId, DWORD dwSrcProcId, - DWORD dwAccess, DWORD dwOptions) -{ - HANDLE hRet; - - hRet = SHLWAPI_DupSharedHandle(hShared, dwDstProcId, dwSrcProcId, - dwAccess, dwOptions); - return hRet; -} - /************************************************************************* * @ [SHLWAPI.13] * diff --git a/dll/win32/shlwapi/path.c b/dll/win32/shlwapi/path.c index 40a2a853d95..f80e1f4b766 100644 --- a/dll/win32/shlwapi/path.c +++ b/dll/win32/shlwapi/path.c @@ -137,7 +137,7 @@ LPSTR WINAPI PathCombineA(LPSTR lpszDest, LPCSTR lpszDir, LPCSTR lpszFile) if (!lpszDest) return NULL; if (!lpszDir && !lpszFile) - goto fail; + goto fail; if (lpszDir) if (!MultiByteToWideChar(CP_ACP,0,lpszDir,-1,szDir,MAX_PATH)) @@ -3360,7 +3360,7 @@ HRESULT WINAPI PathCreateFromUrlW(LPCWSTR pszUrl, LPWSTR pszPath, len = src - pszUrl; StrCpyNW(dst, pszUrl, len + 1); dst += len; - if (isalphaW(src[1]) && (src[2] == ':' || src[2] == '|')) + if (*src && isalphaW(src[1]) && (src[2] == ':' || src[2] == '|')) { /* 'Forget' to add a trailing '/', just like Windows */ src++; diff --git a/dll/win32/shlwapi/reg.c b/dll/win32/shlwapi/reg.c index 6a52ea8e90c..8b573a3b4e2 100644 --- a/dll/win32/shlwapi/reg.c +++ b/dll/win32/shlwapi/reg.c @@ -198,31 +198,48 @@ LONG WINAPI SHRegCloseUSKey( /************************************************************************* * SHRegCreateUSKeyA [SHLWAPI.@] * - * Create or open a user-specific registry key. - * - * PARAMS - * pszPath [I] Key name to create or open. - * samDesired [I] Wanted security access. - * hRelativeUSKey [I] Base path if pszPath is relative. NULL otherwise. - * phNewUSKey [O] Receives a handle to the new or opened key. - * dwFlags [I] Base key under which the key should be opened. - * - * RETURNS - * Success: ERROR_SUCCESS - * Failure: Nonzero error code from winerror.h + * See SHRegCreateUSKeyW. */ -LONG WINAPI SHRegCreateUSKeyA(LPCSTR pszPath, REGSAM samDesired, HUSKEY hRelativeUSKey, - PHUSKEY phNewUSKey, DWORD dwFlags) +LONG WINAPI SHRegCreateUSKeyA(LPCSTR path, REGSAM samDesired, HUSKEY relative_key, + PHUSKEY new_uskey, DWORD flags) { - FIXME("(%s, 0x%08x, %p, %p, 0x%08x) stub\n", debugstr_a(pszPath), samDesired, - hRelativeUSKey, phNewUSKey, dwFlags); - return ERROR_SUCCESS; + WCHAR *pathW; + LONG ret; + + TRACE("(%s, 0x%08x, %p, %p, 0x%08x)\n", debugstr_a(path), samDesired, relative_key, + new_uskey, flags); + + if (path) + { + INT len = MultiByteToWideChar(CP_ACP, 0, path, -1, NULL, 0); + pathW = HeapAlloc(GetProcessHeap(), 0, len*sizeof(WCHAR)); + if (!pathW) + return ERROR_NOT_ENOUGH_MEMORY; + MultiByteToWideChar(CP_ACP, 0, path, -1, pathW, len); + } + else + pathW = NULL; + + ret = SHRegCreateUSKeyW(pathW, samDesired, relative_key, new_uskey, flags); + HeapFree(GetProcessHeap(), 0, pathW); + return ret; } /************************************************************************* * SHRegCreateUSKeyW [SHLWAPI.@] * - * See SHRegCreateUSKeyA. + * Create or open a user-specific registry key. + * + * PARAMS + * path [I] Key name to create or open. + * samDesired [I] Wanted security access. + * relative_key [I] Base path if 'path' is relative. NULL otherwise. + * new_uskey [O] Receives a handle to the new or opened key. + * flags [I] Base key under which the key should be opened. + * + * RETURNS + * Success: ERROR_SUCCESS + * Failure: Nonzero error code from winerror.h */ LONG WINAPI SHRegCreateUSKeyW(LPCWSTR path, REGSAM samDesired, HUSKEY relative_key, PHUSKEY new_uskey, DWORD flags) diff --git a/dll/win32/wbemdisp/CMakeLists.txt b/dll/win32/wbemdisp/CMakeLists.txt index c750c91329c..d30ee33a9ee 100644 --- a/dll/win32/wbemdisp/CMakeLists.txt +++ b/dll/win32/wbemdisp/CMakeLists.txt @@ -26,7 +26,7 @@ add_library(wbemdisp SHARED set_module_type(wbemdisp win32dll) target_link_libraries(wbemdisp uuid wine) -add_dependencies(wbemdisp wbemdisp_idlheader) +add_dependencies(wbemdisp stdole2 wbemdisp_idlheader) add_importlibs(wbemdisp oleaut32 msvcrt kernel32 ntdll) add_pch(wbemdisp wbemdisp_private.h SOURCE) add_cd_file(TARGET wbemdisp DESTINATION reactos/system32/wbem FOR all) diff --git a/dll/win32/wldap32/lang/wldap32_Tr.rc b/dll/win32/wldap32/lang/wldap32_Tr.rc index 1b7fd1e01ad..47ce7c3f094 100644 --- a/dll/win32/wldap32/lang/wldap32_Tr.rc +++ b/dll/win32/wldap32/lang/wldap32_Tr.rc @@ -1,7 +1,7 @@ /* * Turkish resources for WLDAP32 * - * Copyright 2006 Fatih Aşıcı + * Copyrights: 2006 Fatih Aşıcı, 2014 Erdem Ersoy (eersoy93) (erdemersoy@live.com) * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -23,27 +23,27 @@ LANGUAGE LANG_TURKISH, SUBLANG_DEFAULT STRINGTABLE { 0 "Başarılı" - 1 "İşlem Hatası" - 2 "İletişim Kuralı Hatası" - 3 "Zaman Sınırı Aşıldı" - 4 "Boyut Sınırı Aşıldı" + 1 "İşlem Yanlışlığı" + 2 "İletişim Kâidesi Yanlışlığı" + 3 "Zaman Hududu Aşıldı" + 4 "Boyut Hududu Aşıldı" 5 "Karşılaştırma Yanlış" 6 "Karşılaştırma Doğru" - 7 "Yetkilendirme Yöntemi Desteklenmiyor" - 8 "Güçlü Yerkilendirme Gerekli" + 7 "Kimlik Doğrulaması Yöntemi Desteklenmiyor" + 8 "Güçlü Kimlik Doğrulaması Gerekli" 9 "Başvuru (v2)" 10 "Başvuru" - 11 "Yönetim Sınırı Aşıldı" - 12 "Kullanılabilir Olmayan Kritik Uzantı" - 13 "Gizli Olarak Gerekli" + 11 "Yönetim Hududu Aşıldı" + 12 "Olmayan Önemli Eklenti" + 13 "Gizlilik Gerekli" 14 "" 15 "" - 16 "Böyle Bir Öznitelik Yok" + 16 "Böyle Öz Nitelik Yok" 17 "Tanımlanmamış Tür" 18 "Uygunsuz Eşleşme" - 19 "Kısıtlama İhlali" - 20 "Varolan Öznitelik Veya Değer" - 21 "Geçersiz Sözdizimi" + 19 "Kısıtlama Çiğnemi" + 20 "Var Olan Öz Nitelik ya da Değer" + 21 "Geçersiz Söz Dizimi" 22 "" 23 "" 24 "" @@ -54,11 +54,11 @@ STRINGTABLE 29 "" 30 "" 31 "" - 32 "Böyle Bir Nesne Yok" - 33 "Takma Ad Sorunu" - 34 "Geçersiz DN Sözdizimi" - 35 "Yaprak Konumunda" - 36 "Takma Ad Başvuru Sorunu" + 32 "Böyle Nesne Yok" + 33 "Başka Ad Sorunu" + 34 "Geçersiz DN Söz Dizimi" + 35 "Alt Düzey" + 36 "Başka Ad Başvurudan Ayırma Sorunu" 37 "" 38 "" 39 "" @@ -70,11 +70,11 @@ STRINGTABLE 45 "" 46 "" 47 "" - 48 "Uygunsuz Yetkilendirme" - 49 "Geçersiz Belgeler" - 50 "Geçersiz Yetkiler" - 51 "Meşgul" - 52 "Kullanılabilir Değil" + 48 "Uygunsuz Kimlik Doğrulaması" + 49 "Geçersiz Kimlik Bilgileri" + 50 "Eksik Yetkiler" + 51 "Dolu" + 52 "Kullanılamaz" 53 "Yürütmeye İsteksiz" 54 "Döngü Algılandı" 55 "" @@ -82,18 +82,18 @@ STRINGTABLE 57 "" 58 "" 59 "" - 60 "Sıralama Denetimi Eksik" - 61 "Eksik Dizin Aralığı Hatası" + 60 "Dizme Denetimi Eksik" + 61 "Dizin Aralığı Yanlışlığı" 62 "" 63 "" - 64 "Adlandırma İhlali" - 65 "Nesne Sınıfı İhlali" - 66 "Yaprak olmayan konumda izinli değil" - 67 "RDN üzerinde izin verilmiyor" - 68 "Zaten Var" - 69 "Nesne Sınıfı Modülleri Yok" + 64 "Adlandırma Çiğnemi" + 65 "Nesne Sınıfı Çiğnemi" + 66 "Alt Düzey Olmayan Üzerinde İzinli Değil" + 67 "RDN üzerinde İzinli Değil" + 68 "Önceden Var" + 69 "Nesne Sınıfı Kipleri Yok" 70 "Sonuçlar Çok Büyük" - 71 "Birden Fazla DSA Etkilenir" + 71 "Çoklu DSA'ları Etkiler" 72 "" 73 "" 74 "" @@ -102,22 +102,22 @@ STRINGTABLE 77 "" 78 "" 79 "" - 80 "Diğer" - 81 "Sunucu Kapalı" - 82 "Yerel Hata" - 83 "Kodlama Hatası" - 84 "Kod Çözme Hatası" - 85 "Zaman Aşımı" - 86 "Yazar Bilinmiyor" - 87 "Süzme Hatası" + 80 "Başka" + 81 "Sunucu Devre Dışı" + 82 "Yerli Yanlışlık" + 83 "Kodlama Yanlışlığı" + 84 "Çözme Yanlışlığı" + 85 "Süre Aşımı" + 86 "Yetkili Bilinmiyor" + 87 "Süzgeç Yanlışlığı" 88 "Kullanıcı İptal Etti" - 89 "Parametre Hatası" + 89 "Değişken Yanlışlığı" 90 "Bellek Yok" - 91 "LDAP sunucusuna bağlanamıyor" - 92 "İşlem LDAP iletişim kuralının bu sürümünce desteklenmiyor." - 93 "İletide belirtilen denetim bulunamadı" - 94 "İletide sonuç yok" - 95 "Dönen diğer sonuçlar" - 96 "Başvuruları işlerken dön" - 97 "Paketin gönderildiği yönlendirici sınırı aşıldı" + 91 "LDAP Sunucusuna Bağlanılamıyor" + 92 "İşlem LDAP İletişim Kâidesinin Bu Sürümünce Desteklenmiyor" + 93 "İletide Belirtilen Denetim Bulunamadı" + 94 "İletide Sonuç Yok" + 95 "Daha Çok Sonuç Dönürüldü" + 96 "Başvuruları İşlerken Dön" + 97 "Başvuru Atlama Hududu Aşıldı" } diff --git a/dll/win32/ws2_32/misc/ns.c b/dll/win32/ws2_32/misc/ns.c index 1ac0bc83811..dfee38de871 100644 --- a/dll/win32/ws2_32/misc/ns.c +++ b/dll/win32/ws2_32/misc/ns.c @@ -1496,7 +1496,7 @@ inet_addr(IN CONST CHAR FAR* cp) p = (PCHAR)cp; - if (!p || !WSAINITIALIZED) + if (!p) { WSASetLastError(WSAEFAULT); return INADDR_NONE; diff --git a/drivers/filters/mountmgr/device.c b/drivers/filters/mountmgr/device.c index 4ee8096c7e6..de6b6350c33 100644 --- a/drivers/filters/mountmgr/device.c +++ b/drivers/filters/mountmgr/device.c @@ -653,7 +653,7 @@ MountMgrNextDriveLetter(IN PDEVICE_EXTENSION DeviceExtension, PMOUNTMGR_DRIVE_LETTER_TARGET DriveLetterTarget; MOUNTMGR_DRIVE_LETTER_INFORMATION DriveLetterInformation; - Stack = IoGetNextIrpStackLocation(Irp); + Stack = IoGetCurrentIrpStackLocation(Irp); /* Validate input */ if (Stack->Parameters.DeviceIoControl.InputBufferLength < sizeof(MOUNTMGR_DRIVE_LETTER_TARGET) || @@ -845,7 +845,7 @@ MountMgrQueryDosVolumePath(IN PDEVICE_EXTENSION DeviceExtension, PSYMLINK_INFORMATION SymlinkInformation; PASSOCIATED_DEVICE_ENTRY AssociatedDevice; - Stack = IoGetNextIrpStackLocation(Irp); + Stack = IoGetCurrentIrpStackLocation(Irp); /* Validate input size */ if (Stack->Parameters.DeviceIoControl.InputBufferLength < sizeof(MOUNTMGR_TARGET_NAME)) @@ -1075,7 +1075,7 @@ MountMgrKeepLinksWhenOffline(IN PDEVICE_EXTENSION DeviceExtension, PMOUNTMGR_TARGET_NAME Target; PDEVICE_INFORMATION DeviceInformation; - Stack = IoGetNextIrpStackLocation(Irp); + Stack = IoGetCurrentIrpStackLocation(Irp); /* Validate input */ if (Stack->Parameters.DeviceIoControl.InputBufferLength < sizeof(MOUNTMGR_TARGET_NAME)) @@ -1119,7 +1119,7 @@ MountMgrVolumeArrivalNotification(IN PDEVICE_EXTENSION DeviceExtension, UNICODE_STRING SymbolicName; PMOUNTMGR_TARGET_NAME Target; - Stack = IoGetNextIrpStackLocation(Irp); + Stack = IoGetCurrentIrpStackLocation(Irp); /* Validate input */ if (Stack->Parameters.DeviceIoControl.InputBufferLength < sizeof(MOUNTMGR_TARGET_NAME)) @@ -1162,7 +1162,7 @@ MountMgrQueryPoints(IN PDEVICE_EXTENSION DeviceExtension, PMOUNTMGR_MOUNT_POINT MountPoint; UNICODE_STRING SymbolicName, DeviceName; - Stack = IoGetNextIrpStackLocation(Irp); + Stack = IoGetCurrentIrpStackLocation(Irp); /* Validate input... */ if (Stack->Parameters.DeviceIoControl.InputBufferLength < sizeof(MOUNTMGR_MOUNT_POINT)) @@ -1310,7 +1310,7 @@ MountMgrDeletePoints(IN PDEVICE_EXTENSION DeviceExtension, PMOUNTMGR_MOUNT_POINTS MountPoints; UNICODE_STRING SymbolicName, DeviceName; - Stack = IoGetNextIrpStackLocation(Irp); + Stack = IoGetCurrentIrpStackLocation(Irp); /* Validate input */ if (Stack->Parameters.DeviceIoControl.InputBufferLength < sizeof(MOUNTMGR_MOUNT_POINT)) @@ -1489,7 +1489,7 @@ MountMgrVolumeMountPointChanged(IN PDEVICE_EXTENSION DeviceExtension, POBJECT_NAME_INFORMATION ObjectNameInfoPtr = NULL; UNICODE_STRING SourceVolumeName, TargetDeviceName; - Stack = IoGetNextIrpStackLocation(Irp); + Stack = IoGetCurrentIrpStackLocation(Irp); /* Validate input */ if (Stack->Parameters.DeviceIoControl.InputBufferLength < sizeof(MOUNTMGR_VOLUME_MOUNT_POINT)) @@ -1722,7 +1722,7 @@ MountMgrDeviceControl(IN PDEVICE_OBJECT DeviceObject, NTSTATUS Status, LockStatus; PDEVICE_EXTENSION DeviceExtension; - Stack = IoGetNextIrpStackLocation(Irp); + Stack = IoGetCurrentIrpStackLocation(Irp); DeviceExtension = DeviceObject->DeviceExtension; KeWaitForSingleObject(&(DeviceExtension->DeviceLock), Executive, KernelMode, FALSE, NULL); diff --git a/drivers/filters/mountmgr/mountmgr.c b/drivers/filters/mountmgr/mountmgr.c index f623976a74e..c24f58a28c3 100644 --- a/drivers/filters/mountmgr/mountmgr.c +++ b/drivers/filters/mountmgr/mountmgr.c @@ -1331,9 +1331,9 @@ MountMgrMountedDeviceArrival(IN PDEVICE_EXTENSION DeviceExtension, DeviceInformation->SuggestedDriveLetter = 0; } /* Else, it's time to set up one */ - else if (!DeviceExtension->NoAutoMount && !DeviceInformation->Removable && - DeviceExtension->AutomaticDriveLetter && HasGptDriveLetter && - DeviceInformation->SuggestedDriveLetter && + else if ((DeviceExtension->NoAutoMount || DeviceInformation->Removable) && + DeviceExtension->AutomaticDriveLetter && + (HasGptDriveLetter || DeviceInformation->SuggestedDriveLetter) && !HasNoDriveLetterEntry(UniqueId)) { /* Create a new drive letter */ diff --git a/drivers/hid/kbdhid/kbdhid.c b/drivers/hid/kbdhid/kbdhid.c index 017ed532ffc..dd504eccb68 100644 --- a/drivers/hid/kbdhid/kbdhid.c +++ b/drivers/hid/kbdhid/kbdhid.c @@ -368,60 +368,60 @@ KbdHid_InternalDeviceControl( switch (IoStack->Parameters.DeviceIoControl.IoControlCode) { case IOCTL_KEYBOARD_QUERY_ATTRIBUTES: - /* verify output buffer length */ - if (IoStack->Parameters.DeviceIoControl.OutputBufferLength < sizeof(MOUSE_ATTRIBUTES)) - { - /* invalid request */ - DPRINT1("[MOUHID] IOCTL_MOUSE_QUERY_ATTRIBUTES Buffer too small\n"); - Irp->IoStatus.Status = STATUS_BUFFER_TOO_SMALL; - IoCompleteRequest(Irp, IO_NO_INCREMENT); - return STATUS_BUFFER_TOO_SMALL; - } + /* verify output buffer length */ + if (IoStack->Parameters.DeviceIoControl.OutputBufferLength < sizeof(MOUSE_ATTRIBUTES)) + { + /* invalid request */ + DPRINT1("[MOUHID] IOCTL_MOUSE_QUERY_ATTRIBUTES Buffer too small\n"); + Irp->IoStatus.Status = STATUS_BUFFER_TOO_SMALL; + IoCompleteRequest(Irp, IO_NO_INCREMENT); + return STATUS_BUFFER_TOO_SMALL; + } - /* get output buffer */ - Attributes = Irp->AssociatedIrp.SystemBuffer; + /* get output buffer */ + Attributes = Irp->AssociatedIrp.SystemBuffer; - /* copy attributes */ + /* copy attributes */ RtlCopyMemory(Attributes, &DeviceExtension->Attributes, sizeof(KEYBOARD_ATTRIBUTES)); - /* complete request */ - Irp->IoStatus.Information = sizeof(MOUSE_ATTRIBUTES); - Irp->IoStatus.Status = STATUS_SUCCESS; - IoCompleteRequest(Irp, IO_NO_INCREMENT); - return STATUS_SUCCESS; + /* complete request */ + Irp->IoStatus.Information = sizeof(MOUSE_ATTRIBUTES); + Irp->IoStatus.Status = STATUS_SUCCESS; + IoCompleteRequest(Irp, IO_NO_INCREMENT); + return STATUS_SUCCESS; case IOCTL_INTERNAL_KEYBOARD_CONNECT: - /* verify input buffer length */ - if (IoStack->Parameters.DeviceIoControl.InputBufferLength < sizeof(CONNECT_DATA)) - { - /* invalid request */ - Irp->IoStatus.Status = STATUS_INVALID_PARAMETER; - IoCompleteRequest(Irp, IO_NO_INCREMENT); - return STATUS_INVALID_PARAMETER; - } + /* verify input buffer length */ + if (IoStack->Parameters.DeviceIoControl.InputBufferLength < sizeof(CONNECT_DATA)) + { + /* invalid request */ + Irp->IoStatus.Status = STATUS_INVALID_PARAMETER; + IoCompleteRequest(Irp, IO_NO_INCREMENT); + return STATUS_INVALID_PARAMETER; + } - /* is it already connected */ - if (DeviceExtension->ClassService) - { - /* already connected */ - Irp->IoStatus.Status = STATUS_SHARING_VIOLATION; - IoCompleteRequest(Irp, IO_NO_INCREMENT); - return STATUS_SHARING_VIOLATION; - } + /* is it already connected */ + if (DeviceExtension->ClassService) + { + /* already connected */ + Irp->IoStatus.Status = STATUS_SHARING_VIOLATION; + IoCompleteRequest(Irp, IO_NO_INCREMENT); + return STATUS_SHARING_VIOLATION; + } - /* get connect data */ - Data = IoStack->Parameters.DeviceIoControl.Type3InputBuffer; + /* get connect data */ + Data = IoStack->Parameters.DeviceIoControl.Type3InputBuffer; - /* store connect details */ - DeviceExtension->ClassDeviceObject = Data->ClassDeviceObject; - DeviceExtension->ClassService = Data->ClassService; + /* store connect details */ + DeviceExtension->ClassDeviceObject = Data->ClassDeviceObject; + DeviceExtension->ClassService = Data->ClassService; - /* completed successfully */ - Irp->IoStatus.Status = STATUS_SUCCESS; - IoCompleteRequest(Irp, IO_NO_INCREMENT); - return STATUS_SUCCESS; + /* completed successfully */ + Irp->IoStatus.Status = STATUS_SUCCESS; + IoCompleteRequest(Irp, IO_NO_INCREMENT); + return STATUS_SUCCESS; case IOCTL_INTERNAL_KEYBOARD_DISCONNECT: /* not implemented */ @@ -444,11 +444,11 @@ KbdHid_InternalDeviceControl( case IOCTL_KEYBOARD_QUERY_INDICATORS: if (IoStack->Parameters.DeviceIoControl.OutputBufferLength < sizeof(KEYBOARD_INDICATOR_PARAMETERS)) { - /* invalid parameter */ - Irp->IoStatus.Status = STATUS_INVALID_PARAMETER; - IoCompleteRequest(Irp, IO_NO_INCREMENT); - return STATUS_INVALID_PARAMETER; - } + /* invalid parameter */ + Irp->IoStatus.Status = STATUS_INVALID_PARAMETER; + IoCompleteRequest(Irp, IO_NO_INCREMENT); + return STATUS_INVALID_PARAMETER; + } /* copy indicators */ RtlCopyMemory(Irp->AssociatedIrp.SystemBuffer, @@ -464,10 +464,10 @@ KbdHid_InternalDeviceControl( case IOCTL_KEYBOARD_QUERY_TYPEMATIC: if (IoStack->Parameters.DeviceIoControl.OutputBufferLength < sizeof(KEYBOARD_TYPEMATIC_PARAMETERS)) { - /* invalid parameter */ - Irp->IoStatus.Status = STATUS_INVALID_PARAMETER; - IoCompleteRequest(Irp, IO_NO_INCREMENT); - return STATUS_INVALID_PARAMETER; + /* invalid parameter */ + Irp->IoStatus.Status = STATUS_INVALID_PARAMETER; + IoCompleteRequest(Irp, IO_NO_INCREMENT); + return STATUS_INVALID_PARAMETER; } /* copy indicators */ @@ -477,17 +477,17 @@ KbdHid_InternalDeviceControl( /* done */ Irp->IoStatus.Status = STATUS_SUCCESS; - Irp->IoStatus.Information = sizeof(KEYBOARD_TYPEMATIC_PARAMETERS); - IoCompleteRequest(Irp, IO_NO_INCREMENT); + Irp->IoStatus.Information = sizeof(KEYBOARD_TYPEMATIC_PARAMETERS); + IoCompleteRequest(Irp, IO_NO_INCREMENT); return STATUS_SUCCESS; case IOCTL_KEYBOARD_SET_INDICATORS: if (IoStack->Parameters.DeviceIoControl.InputBufferLength < sizeof(KEYBOARD_INDICATOR_PARAMETERS)) { - /* invalid parameter */ - Irp->IoStatus.Status = STATUS_INVALID_PARAMETER; - IoCompleteRequest(Irp, IO_NO_INCREMENT); - return STATUS_INVALID_PARAMETER; + /* invalid parameter */ + Irp->IoStatus.Status = STATUS_INVALID_PARAMETER; + IoCompleteRequest(Irp, IO_NO_INCREMENT); + return STATUS_INVALID_PARAMETER; } /* copy indicators */ @@ -504,10 +504,10 @@ KbdHid_InternalDeviceControl( case IOCTL_KEYBOARD_SET_TYPEMATIC: if (IoStack->Parameters.DeviceIoControl.InputBufferLength < sizeof(KEYBOARD_TYPEMATIC_PARAMETERS)) { - /* invalid parameter */ - Irp->IoStatus.Status = STATUS_INVALID_PARAMETER; - IoCompleteRequest(Irp, IO_NO_INCREMENT); - return STATUS_INVALID_PARAMETER; + /* invalid parameter */ + Irp->IoStatus.Status = STATUS_INVALID_PARAMETER; + IoCompleteRequest(Irp, IO_NO_INCREMENT); + return STATUS_INVALID_PARAMETER; } /* copy indicators */ @@ -523,10 +523,10 @@ KbdHid_InternalDeviceControl( case IOCTL_KEYBOARD_QUERY_INDICATOR_TRANSLATION: /* not implemented */ - DPRINT1("IOCTL_KEYBOARD_QUERY_INDICATOR_TRANSLATION not implemented\n"); - Irp->IoStatus.Status = STATUS_NOT_IMPLEMENTED; - IoCompleteRequest(Irp, IO_NO_INCREMENT); - return STATUS_NOT_IMPLEMENTED; + DPRINT1("IOCTL_KEYBOARD_QUERY_INDICATOR_TRANSLATION not implemented\n"); + Irp->IoStatus.Status = STATUS_NOT_IMPLEMENTED; + IoCompleteRequest(Irp, IO_NO_INCREMENT); + return STATUS_NOT_IMPLEMENTED; } /* unknown control code */ diff --git a/drivers/network/tcpip/tcpip/main.c b/drivers/network/tcpip/tcpip/main.c index 58f7fe816e0..b49b6fe0652 100644 --- a/drivers/network/tcpip/tcpip/main.c +++ b/drivers/network/tcpip/tcpip/main.c @@ -165,9 +165,9 @@ NTSTATUS TiCreateFileObject( TI_DbgPrint(MIN_TRACE, ("AddressCount: %d\n", Address->TAAddressCount)); if( Address->TAAddressCount == 1 ) { - TI_DbgPrint(MIN_TRACE, ("AddressLength: %\n", + TI_DbgPrint(MIN_TRACE, ("AddressLength: %u\n", Address->Address[0].AddressLength)); - TI_DbgPrint(MIN_TRACE, ("AddressType: %\n", + TI_DbgPrint(MIN_TRACE, ("AddressType: %u\n", Address->Address[0].AddressType)); } diff --git a/include/crt/crtdefs.h b/include/crt/crtdefs.h index d2934f9daa1..8c21d4129b6 100644 --- a/include/crt/crtdefs.h +++ b/include/crt/crtdefs.h @@ -316,7 +316,7 @@ extern "C" { #ifndef _WCHAR_T_DEFINED #define _WCHAR_T_DEFINED -#ifndef __cplusplus +#if defined(_MSC_VER) || !defined(__cplusplus) typedef unsigned short wchar_t; #endif #endif diff --git a/include/crt/rtcapi.h b/include/crt/rtcapi.h index 44b7f873af9..0aeb8afa431 100644 --- a/include/crt/rtcapi.h +++ b/include/crt/rtcapi.h @@ -23,11 +23,6 @@ extern "C" { #define _RTC_ERRTYPE_IGNORE -1 #define _RTC_ERRTYPE_ASK -2 -#ifndef _WCHAR_T_DEFINED -#define _WCHAR_T_DEFINED - typedef unsigned short wchar_t; -#endif - typedef int (__cdecl *_RTC_error_fn)(int,const char *,int,const char *,const char *,...); typedef int (__cdecl *_RTC_error_fnW)(int,const wchar_t *,int,const wchar_t *,const wchar_t *,...); diff --git a/include/crt/wctype.h b/include/crt/wctype.h index f50582093e6..249f10f9dc8 100644 --- a/include/crt/wctype.h +++ b/include/crt/wctype.h @@ -18,21 +18,6 @@ extern "C" { #endif -#ifndef _CRTIMP -#define _CRTIMP __declspec(dllimport) -#endif - -#ifndef _WCHAR_T_DEFINED - typedef unsigned short wchar_t; -#define _WCHAR_T_DEFINED -#endif - -#ifndef _WCTYPE_T_DEFINED - typedef unsigned short wint_t; - typedef unsigned short wctype_t; -#define _WCTYPE_T_DEFINED -#endif - #ifndef WEOF #define WEOF (wint_t)(0xFFFF) #endif diff --git a/include/psdk/docobj.idl b/include/psdk/docobj.idl index c77e546081b..119d4eab84e 100644 --- a/include/psdk/docobj.idl +++ b/include/psdk/docobj.idl @@ -275,7 +275,18 @@ interface IOleCommandTarget : IUnknown OLECMDID_OPTICAL_GETZOOMRANGE = 64, OLECMDID_WINDOWSTATECHANGED = 65, OLECMDID_ACTIVEXINSTALLSCOPE = 66, - OLECMDID_UPDATETRAVELENTRY_DATARECOVERY = 67 + OLECMDID_UPDATETRAVELENTRY_DATARECOVERY = 67, + OLECMDID_SHOWTASKDLG = 68, + OLECMDID_POPSTATEEVENT = 69, + OLECMDID_VIEWPORT_MODE = 70, + OLECMDID_LAYOUT_VIEWPORT_WIDTH = 71, + OLECMDID_VISUAL_VIEWPORT_EXCLUDE_BOTTOM = 72, + OLECMDID_USER_OPTICAL_ZOOM = 73, + OLECMDID_PAGEAVAILABLE = 74, + OLECMDID_GETUSERSCALABLE = 75, + OLECMDID_UPDATE_CARET = 76, + OLECMDID_ENABLE_VISIBILITY = 77, + OLECMDID_MEDIA_PLAYBACK = 78 } OLECMDID; HRESULT QueryStatus( diff --git a/include/psdk/msacmdlg.h b/include/psdk/msacmdlg.h index d58b107c8c7..b0af3a28ad4 100644 --- a/include/psdk/msacmdlg.h +++ b/include/psdk/msacmdlg.h @@ -18,6 +18,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#pragma once + #define DLG_ACMFORMATCHOOSE_ID 70 #define IDD_ACMFORMATCHOOSE_BTN_HELP 9 #define IDD_ACMFORMATCHOOSE_CMB_CUSTOM 100 @@ -33,4 +35,3 @@ #define IDD_ACMFILTERCHOOSE_CMB_FILTER 102 #define IDD_ACMFILTERCHOOSE_BTN_SETNAME 103 #define IDD_ACMFILTERCHOOSE_BTN_DELNAME 104 - diff --git a/include/psdk/msctf.idl b/include/psdk/msctf.idl index ecb696e0e80..bce38ab7b21 100644 --- a/include/psdk/msctf.idl +++ b/include/psdk/msctf.idl @@ -33,6 +33,8 @@ 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("HRESULT WINAPI TF_CreateLangBarMgr(ITfLangBarMgr **pppbm);") +cpp_quote("HRESULT WINAPI TF_CreateLangBarItemMgr(ITfLangBarItemMgr **pplbim);") +cpp_quote("HRESULT WINAPI TF_InvalidAssemblyListCacheIfExist(void);") 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);") @@ -79,6 +81,11 @@ cpp_quote("#define TF_MOD_LSHIFT 0x0100") cpp_quote("#define TF_MOD_ON_KEYUP 0x0200") cpp_quote("#define TF_MOD_IGNORE_ALL_MODIFIER 0x0400") +cpp_quote("#define TF_PROFILETYPE_INPUTPROCESSOR 0x0001") +cpp_quote("#define TF_PROFILETYPE_KEYBOARDLAYOUT 0x0002") + +cpp_quote("#define TF_IPSINK_FLAG_ACTIVE 0x0001") + interface ITfDocumentMgr; interface ITfContext; interface IEnumTfDocumentMgrs; @@ -99,6 +106,20 @@ interface ITfEditRecord; interface ITfCompositionView; interface ITfKeyEventSink; +cpp_quote("#if 0") +typedef [uuid(4f5d560f-5ab5-4dde-8c4d-404592857ab0)] UINT_PTR HKL; +cpp_quote("#endif") + +typedef [uuid(e26d9e1d-691e-4f29-90d7-338dcf1f8cef)] struct TF_PERSISTENT_PROPERTY_HEADER_ACP +{ + GUID guidType; + LONG ichStart; + LONG cch; + ULONG cb; + DWORD dwPrivate; + CLSID clsidTIP; +} TF_PERSISTENT_PROPERTY_HEADER_ACP; + typedef [uuid(e1b5808d-1e46-4c19-84dc-68c5f5978cc8)] struct TF_LANGUAGEPROFILE { CLSID clsid; @@ -307,6 +328,8 @@ interface ITfContext : IUnknown }; +const DWORD TF_INVALID_COOKIE = 0xffffffff; + [ object, uuid(4ea48a35-60ae-446f-8fd6-e6a8d82459f7), @@ -421,6 +444,105 @@ interface ITfInputProcessorProfiles : IUnknown [in] HKL hKL); }; +typedef [uuid(44d2825a-10e5-43b2-877f-6cb2f43b7e7e)] +struct TF_INPUTPROCESSORPROFILE { + DWORD dwProfileType; + LANGID langid; + CLSID clsid; + GUID guidProfile; + GUID catid; + HKL hklSubstitute; + DWORD dwCaps; + HKL hkl; + DWORD dwFlags; +} TF_INPUTPROCESSORPROFILE; + +[ + object, + uuid(71c6e74d-0f28-11d8-a82a-00065b84435c), + pointer_default(unique) +] +interface IEnumTfInputProcessorProfiles : IUnknown +{ + HRESULT Clone( + [out] IEnumTfInputProcessorProfiles **ppEnum); + + HRESULT Next( + [in] ULONG ulCount, + [out, size_is(ulCount), length_is(*pcFetch)] TF_INPUTPROCESSORPROFILE *pProfile, + [out] ULONG *pcFetch); + + HRESULT Reset(); + + HRESULT Skip( + [in] ULONG ulCount); +} + +[ + object, + uuid(71c6e74c-0f28-11d8-a82a-00065b84435c), + pointer_default(unique) +] +interface ITfInputProcessorProfileMgr : IUnknown +{ + HRESULT ActivateProfile( + [in] DWORD dwProfileType, + [in] LANGID langid, + [in] REFCLSID clsid, + [in] REFGUID guidProfile, + [in] HKL hkl, + [in] DWORD dwFlags); + + HRESULT DeactivateProfile( + [in] DWORD dwProfileType, + [in] LANGID langid, + [in] REFCLSID clsid, + [in] REFGUID guidProfile, + [in] HKL hkl, + [in] DWORD dwFlags); + + HRESULT GetProfile( + [in] DWORD dwProfileType, + [in] LANGID langid, + [in] REFCLSID clsid, + [in] REFGUID guidProfile, + [in] HKL hkl, + [out] TF_INPUTPROCESSORPROFILE *pProfile); + + + HRESULT EnumProfiles( + [in] LANGID langid, + [out] IEnumTfInputProcessorProfiles **ppEnum); + + HRESULT ReleaseInputProcessor( + [in] REFCLSID rclsid, + [in] DWORD dwFlags); + + HRESULT RegisterProfile( + [in] REFCLSID rclsid, + [in] LANGID langid, + [in] REFGUID guidProfile, + [in, size_is(cchDesc)] const WCHAR *pchDesc, + [in] ULONG cchDesc, + [in, size_is(cchFile)] const WCHAR *pchIconFile, + [in] ULONG cchFile, + [in] ULONG uIconIndex, + [in] HKL hklsubstitute, + [in] DWORD dwPreferredLayout, + [in] BOOL bEnabledByDefault, + [in] DWORD dwFlags); + + HRESULT UnregisterProfile( + [in] REFCLSID rclsid, + [in] LANGID langid, + [in] REFGUID guidProfile, + [in] DWORD dwFlags); + + HRESULT GetActiveProfile( + [in] REFGUID catid, + [out] TF_INPUTPROCESSORPROFILE *pProfile); +} + typedef [uuid(c4cc07f1-80cc-4a7b-bc54-98512782cbe3)] enum { TF_LS_NONE = 0, @@ -615,6 +737,19 @@ interface ITfContextOwnerCompositionSink : IUnknown [in] ITfCompositionView *pComposition); }; +[ + object, + uuid(b246cb75-a93e-4652-bf8c-b3fe0cfd7e57), + pointer_default(unique) +] +interface ITfActiveLanguageProfileNotifySink : IUnknown +{ + HRESULT OnActivated( + [in] REFCLSID clsid, + [in] REFGUID guidProfile, + [in] BOOL fActivated); +} + [ object, uuid(3d61bf11-ac5f-42c8-a4cb-931bcc28c744), @@ -1193,6 +1328,51 @@ interface ITfContextOwnerCompositionServices : ITfContextComposition HRESULT TerminateComposition([in] ITfCompositionView *pComposition); } +[ + object, + uuid(4ef89150-0807-11d3-8df0-00105a2799b5), + pointer_default(unique) +] +interface ITfPersistentPropertyLoaderACP : IUnknown +{ + HRESULT LoadProperty( + [in] const TF_PERSISTENT_PROPERTY_HEADER_ACP *pHdr, + [out] IStream **ppStream); +} + +[ + object, + uuid(b23eb630-3e1c-11d3-a745-0050040ab407), + pointer_default(unique) +] +interface ITfContextOwnerServices : IUnknown +{ + HRESULT OnLayoutChange(); + + HRESULT OnStatusChange([in] DWORD dwFlags); + + HRESULT OnAttributeChange([in] REFGUID rguidAttribute); + + HRESULT Serialize( + [in] ITfProperty *pProp, + [in] ITfRange *pRange, + [out] TF_PERSISTENT_PROPERTY_HEADER_ACP *pHdr, + [in] IStream *pStream); + + HRESULT Unserialize( + [in] ITfProperty *pProp, + [in] const TF_PERSISTENT_PROPERTY_HEADER_ACP *pHdr, + [in] IStream *pStream, + [in] ITfPersistentPropertyLoaderACP *pLoader); + + HRESULT ForceLoadProperty([in] ITfProperty *pProp); + + HRESULT CreateRange( + [in] LONG acpStart, + [in] LONG acpEnd, + [out] ITfRangeACP **ppRange); +} + [ object, uuid(17d49a3d-f8b8-4b2f-b254-52319dd64c53), @@ -1362,139 +1542,62 @@ interface ITfThreadFocusSink : IUnknown [ object, - uuid(101d6610-0990-11d3-8df0-00105a2799b5), + uuid(71c6e74e-0f28-11d8-a82a-00065b84435c), pointer_default(unique) ] -interface ITfFunctionProvider : IUnknown +interface ITfInputProcessorProfileActivationSink : IUnknown { - HRESULT GetType( - [out] GUID *pguid); - - HRESULT GetDescription( - [out] BSTR *pbstrDesc); - - HRESULT GetFunction( - [in] REFGUID rguid, - [in] REFIID riid, - [out, iid_is(riid)] IUnknown **ppunk); + HRESULT OnActivated( + [in] DWORD dwProfileType, + [in] LANGID langid, + [in] REFCLSID clsid, + [in] REFGUID catid, + [in] REFGUID guidProfile, + [in] HKL hkl, + [in] DWORD dwFlags); } [ - object, - uuid(e4b24db0-0990-11d3-8df0-00105a2799b5), - pointer_default(unique) + object, + local, + uuid(a1adaaa2-3a24-449d-ac96-5183e7f5c217), + pointer_default(unique) ] -interface IEnumTfFunctionProviders : IUnknown +interface ITfMouseSink : IUnknown { - HRESULT Clone( - [out] IEnumTfFunctionProviders **ppEnum); - - HRESULT Next( - [in] ULONG ulCount, - [out, size_is(ulCount), length_is(*pcFetch)] ITfFunctionProvider **ppCmdobj, - [out] ULONG *pcFetch); - - HRESULT Reset(); - - HRESULT Skip( - [in] ULONG ulCount); -}; - -[ - object, - uuid(2433bf8e-0f9b-435c-ba2c-180611978c30), - pointer_default(unique) -] -interface ITfContextView : IUnknown -{ - HRESULT GetRangeFromPoint( - [in] TfEditCookie ec, - [in] const POINT *ppt, - [in] DWORD dwFlags, - [out] ITfRange **ppRange); - - HRESULT GetTextExt( - [in] TfEditCookie ec, - [in] ITfRange *pRange, - [out] RECT *prc, - [out] BOOL *pfClipped); - - HRESULT GetScreenExt( - [out] RECT *prc); - - HRESULT GetWnd( - [out] HWND *phwnd); -}; - -[ - object, - uuid(f0c0f8dd-cf38-44e1-bb0f-68cf0d551c78), - pointer_default(unique) -] -interface IEnumTfContextViews : IUnknown -{ - HRESULT Clone( - [out] IEnumTfContextViews **ppEnum); - - HRESULT Next( - [in] ULONG ulCount, - [out, size_is(ulCount), length_is(*pcFetched)] ITfContextView **rgViews, - [out] ULONG *pcFetched); - - HRESULT Reset(); - - HRESULT Skip( - [in] ULONG ulCount); -}; - -[ - object, - uuid(19188cb0-aca9-11d2-afc5-00105a2799b5), - pointer_default(unique) -] -interface IEnumTfProperties : IUnknown -{ - HRESULT Clone( - [out] IEnumTfProperties **ppEnum); - - HRESULT Next( - [in] ULONG ulCount, - [out, size_is(ulCount), length_is(*pcFetched)] ITfProperty **ppProp, - [out] ULONG *pcFetched); - - HRESULT Reset(); - - HRESULT Skip( - [in] ULONG ulCount); + HRESULT OnMouseEvent( + [in] ULONG uEdge, + [in] ULONG uQuadrant, + [in] DWORD dwBtnStatus, + [out] BOOL *pfEaten); } [ - object, - uuid(463a506d-6992-49d2-9b88-93d55e70bb16), - pointer_default(unique) + object, + uuid(09d146cd-a544-4132-925b-7afa8ef322d0), + pointer_default(unique) ] -interface ITfRangeBackup : IUnknown +interface ITfMouseTracker : IUnknown { - HRESULT Restore( - [in] TfEditCookie ec, - [in] ITfRange *pRange); -}; + HRESULT AdviseMouseSink( + [in] ITfRange *range, + [in] ITfMouseSink *pSink, + [out] DWORD *pdwCookie); + + HRESULT UnadviseMouseSink([in] DWORD dwCookie); +} [ - object, - uuid(42d4d099-7c1a-4a89-b836-6c6f22160df0), - pointer_default(unique) + object, + uuid(3bdd78e2-c16e-47fd-b883-ce6facc1a208), + pointer_default(unique) ] -interface ITfEditRecord : IUnknown +interface ITfMouseTrackerACP : IUnknown { - const DWORD TF_GTP_INCL_TEXT = 0x1; + HRESULT AdviseMouseSink( + [in] ITfRangeACP *range, + [in] ITfMouseSink *pSink, + [out] DWORD *pdwCookie); - HRESULT GetSelectionStatus( - [out] BOOL *pfChanged); - - HRESULT GetTextAndPropertyUpdates( - [in] DWORD dwFlags, - [in, size_is(cProperties)] const GUID **prgProperties, - [in] ULONG cProperties, - [out] IEnumTfRanges **ppEnum); -}; + HRESULT UnadviseMouseSink([in] DWORD dwCookie); +} diff --git a/include/psdk/ntdef.h b/include/psdk/ntdef.h index 6b1d0933094..9a028b6c639 100644 --- a/include/psdk/ntdef.h +++ b/include/psdk/ntdef.h @@ -461,10 +461,6 @@ typedef unsigned char UCHAR, *PUCHAR; typedef unsigned short USHORT, *PUSHORT; typedef unsigned long ULONG, *PULONG; -typedef CONST UCHAR *PCUCHAR; -typedef CONST USHORT *PCUSHORT; -typedef CONST ULONG *PCULONG; - typedef double DOUBLE; /* Signed Types */ @@ -800,6 +796,26 @@ typedef struct _GROUP_AFFINITY { #define RTL_CONST_CAST(type) (type) #endif +#ifdef __cplusplus +#define DEFINE_ENUM_FLAG_OPERATORS(_ENUMTYPE) \ +extern "C++" { \ + inline _ENUMTYPE operator|(_ENUMTYPE a, _ENUMTYPE b) { return _ENUMTYPE(((int)a) | ((int)b)); } \ + inline _ENUMTYPE &operator|=(_ENUMTYPE &a, _ENUMTYPE b) { return (_ENUMTYPE &)(((int &)a) |= ((int)b)); } \ + inline _ENUMTYPE operator&(_ENUMTYPE a, _ENUMTYPE b) { return _ENUMTYPE(((int)a) & ((int)b)); } \ + inline _ENUMTYPE &operator&=(_ENUMTYPE &a, _ENUMTYPE b) { return (_ENUMTYPE &)(((int &)a) &= ((int)b)); } \ + inline _ENUMTYPE operator~(_ENUMTYPE a) { return _ENUMTYPE(~((int)a)); } \ + inline _ENUMTYPE operator^(_ENUMTYPE a, _ENUMTYPE b) { return _ENUMTYPE(((int)a) ^ ((int)b)); } \ + inline _ENUMTYPE &operator^=(_ENUMTYPE &a, _ENUMTYPE b) { return (_ENUMTYPE &)(((int &)a) ^= ((int)b)); } \ +} +#else +#define DEFINE_ENUM_FLAG_OPERATORS(_ENUMTYPE) +#endif + +#define COMPILETIME_OR_2FLAGS(a,b) ((UINT)(a)|(UINT)(b)) +#define COMPILETIME_OR_3FLAGS(a,b,c) ((UINT)(a)|(UINT)(b)|(UINT)(c)) +#define COMPILETIME_OR_4FLAGS(a,b,c,d) ((UINT)(a)|(UINT)(b)|(UINT)(c)|(UINT)(d)) +#define COMPILETIME_OR_5FLAGS(a,b,c,d,e) ((UINT)(a)|(UINT)(b)|(UINT)(c)|(UINT)(d)|(UINT)(e)) + /* Type Limits */ #define MINCHAR 0x80 #define MAXCHAR 0x7f @@ -1401,9 +1417,23 @@ typedef struct _GROUP_AFFINITY { #define LOCALE_NEUTRAL MAKELCID(MAKELANGID(LANG_NEUTRAL, SUBLANG_NEUTRAL), SORT_DEFAULT) #define LOCALE_INVARIANT MAKELCID(MAKELANGID(LANG_INVARIANT, SUBLANG_NEUTRAL), SORT_DEFAULT) +typedef _Return_type_success_(return >= 0) LONG NTSTATUS; +typedef NTSTATUS *PNTSTATUS; + +#ifndef __SECSTATUS_DEFINED__ +typedef long SECURITY_STATUS; +#define __SECSTATUS_DEFINED__ +#endif + /* Physical Addresses are always treated as 64-bit wide */ typedef LARGE_INTEGER PHYSICAL_ADDRESS, *PPHYSICAL_ADDRESS; +#define TIME LARGE_INTEGER +#define _TIME _LARGE_INTEGER +#define PTIME PLARGE_INTEGER +#define LowTime LowPart +#define HighTime HighPart + /* Used to store a non-float 8 byte aligned structure */ typedef struct _QUAD { @@ -1414,6 +1444,17 @@ typedef struct _QUAD } DUMMYUNIONNAME; } QUAD, *PQUAD, UQUAD, *PUQUAD; +#if (_WIN32_WINNT >= 0x0600) || (defined(__cplusplus) && defined(WINDOWS_ENABLE_CPLUSPLUS)) +typedef CONST UCHAR *PCUCHAR; +typedef CONST USHORT *PCUSHORT; +typedef CONST ULONG *PCULONG; +typedef CONST UQUAD *PCUQUAD; +typedef CONST SCHAR *PCSCHAR; +#endif /* (/_WIN32_WINNT >= 0x0600) */ +#if (_WIN32_WINNT >= 0x0600) +typedef CONST NTSTATUS *PCNTSTATUS; +#endif /* (/_WIN32_WINNT >= 0x0600) */ + /* String Types */ typedef struct _STRING { USHORT Length; @@ -1528,6 +1569,8 @@ typedef struct _OBJECT_ATTRIBUTES64 { } OBJECT_ATTRIBUTES64, *POBJECT_ATTRIBUTES64; typedef CONST OBJECT_ATTRIBUTES64 *PCOBJECT_ATTRIBUTES64; +#define OBJ_HANDLE_TAGBITS 0x00000003L + /* Values for the Attributes member */ #define OBJ_INHERIT 0x00000002L #define OBJ_PERMANENT 0x00000010L @@ -1561,6 +1604,37 @@ typedef CONST OBJECT_ATTRIBUTES64 *PCOBJECT_ATTRIBUTES64; #define RTL_INIT_OBJECT_ATTRIBUTES(n, a) \ RTL_CONSTANT_OBJECT_ATTRIBUTES(n, a) +#ifdef _MSC_VER + #pragma warning(push) + #pragma warning(disable:4214) /* Bit fields of other types than int */ +#endif /* _MSC_VER */ +typedef struct _RTL_BALANCED_NODE +{ + _ANONYMOUS_UNION union + { + struct _RTL_BALANCED_NODE *Children[2]; + _ANONYMOUS_STRUCT struct + { + struct _RTL_BALANCED_NODE *Left; + struct _RTL_BALANCED_NODE *Right; + } DUMMYSTRUCTNAME; + } DUMMYUNIONNAME; + _ANONYMOUS_UNION union + { + UCHAR Red : 1; + UCHAR Balance : 2; + ULONG_PTR ParentValue; + } DUMMYUNIONNAME2; +} RTL_BALANCED_NODE, *PRTL_BALANCED_NODE; +#ifdef _MSC_VER + #pragma warning(pop) +#endif /* _MSC_VER */ + +#define RTL_BALANCED_NODE_RESERVED_PARENT_MASK 3 +#define RTL_BALANCED_NODE_GET_PARENT_POINTER(Node) \ + ((PRTL_BALANCED_NODE)((Node)->ParentValue & \ + ~RTL_BALANCED_NODE_RESERVED_PARENT_MASK)) + /* Product Types */ typedef enum _NT_PRODUCT_TYPE { NtProductWinNt = 1, @@ -1583,6 +1657,28 @@ typedef enum _WAIT_TYPE { WaitAny } WAIT_TYPE; +#ifndef MIDL_PASS +FORCEINLINE +VOID +ListEntry32To64( + _In_ PLIST_ENTRY32 ListEntry32, + _Out_ PLIST_ENTRY64 ListEntry64) +{ + ListEntry64->Flink = (ULONG)ListEntry32->Flink; + ListEntry64->Blink = (ULONG)ListEntry32->Blink; +} + +FORCEINLINE +VOID +ListEntry64To32( + _In_ PLIST_ENTRY64 ListEntry64, + _Out_ PLIST_ENTRY32 ListEntry32) +{ + ListEntry32->Flink = ListEntry64->Flink & 0xFFFFFFFF; + ListEntry32->Blink = ListEntry64->Blink & 0xFFFFFFFF; +} +#endif /* !MIDL_PASS */ + #ifdef __cplusplus } // extern "C" #endif diff --git a/include/psdk/oleacc.idl b/include/psdk/oleacc.idl index 241eb00ea30..97b78587811 100644 --- a/include/psdk/oleacc.idl +++ b/include/psdk/oleacc.idl @@ -18,6 +18,11 @@ import "oaidl.idl"; +#ifndef __WIDL__ +#define threading(model) +#endif + +cpp_quote("#define NAVDIR_MIN 0") cpp_quote("#define NAVDIR_UP 1") cpp_quote("#define NAVDIR_DOWN 2") cpp_quote("#define NAVDIR_LEFT 3") @@ -26,6 +31,7 @@ cpp_quote("#define NAVDIR_NEXT 5") cpp_quote("#define NAVDIR_PREVIOUS 6") cpp_quote("#define NAVDIR_FIRSTCHILD 7") cpp_quote("#define NAVDIR_LASTCHILD 8") +cpp_quote("#define NAVDIR_MAX 9") cpp_quote("#define ROLE_SYSTEM_TITLEBAR 1") cpp_quote("#define ROLE_SYSTEM_MENUBAR 2") @@ -100,6 +106,45 @@ cpp_quote("#define SELFLAG_ADDSELECTION 0x08") cpp_quote("#define SELFLAG_REMOVESELECTION 0x10") cpp_quote("#define SELFLAG_VALID 0x1f") +cpp_quote("#ifndef STATE_SYSTEM_UNAVAILABLE") +cpp_quote("#define STATE_SYSTEM_NORMAL 0x00000000") +cpp_quote("#define STATE_SYSTEM_UNAVAILABLE 0x00000001") +cpp_quote("#define STATE_SYSTEM_SELECTED 0x00000002") +cpp_quote("#define STATE_SYSTEM_FOCUSED 0x00000004") +cpp_quote("#define STATE_SYSTEM_PRESSED 0x00000008") +cpp_quote("#define STATE_SYSTEM_CHECKED 0x00000010") +cpp_quote("#define STATE_SYSTEM_MIXED 0x00000020") +cpp_quote("#define STATE_SYSTEM_INDETERMINATE STATE_SYSTEM_MIXED") +cpp_quote("#define STATE_SYSTEM_READONLY 0x00000040") +cpp_quote("#define STATE_SYSTEM_HOTTRACKED 0x00000080") +cpp_quote("#define STATE_SYSTEM_DEFAULT 0x00000100") +cpp_quote("#define STATE_SYSTEM_EXPANDED 0x00000200") +cpp_quote("#define STATE_SYSTEM_COLLAPSED 0x00000400") +cpp_quote("#define STATE_SYSTEM_BUSY 0x00000800") +cpp_quote("#define STATE_SYSTEM_FLOATING 0x00001000") +cpp_quote("#define STATE_SYSTEM_MARQUEED 0x00002000") +cpp_quote("#define STATE_SYSTEM_ANIMATED 0x00004000") +cpp_quote("#define STATE_SYSTEM_INVISIBLE 0x00008000") +cpp_quote("#define STATE_SYSTEM_OFFSCREEN 0x00010000") +cpp_quote("#define STATE_SYSTEM_SIZEABLE 0x00020000") +cpp_quote("#define STATE_SYSTEM_MOVEABLE 0x00040000") +cpp_quote("#define STATE_SYSTEM_SELFVOICING 0x00080000") +cpp_quote("#define STATE_SYSTEM_FOCUSABLE 0x00100000") +cpp_quote("#define STATE_SYSTEM_SELECTABLE 0x00200000") +cpp_quote("#define STATE_SYSTEM_LINKED 0x00400000") +cpp_quote("#define STATE_SYSTEM_TRAVERSED 0x00800000") +cpp_quote("#define STATE_SYSTEM_MULTISELECTABLE 0x01000000") +cpp_quote("#define STATE_SYSTEM_EXTSELECTABLE 0x02000000") +cpp_quote("#define STATE_SYSTEM_ALERT_LOW 0x04000000") +cpp_quote("#define STATE_SYSTEM_ALERT_MEDIUM 0x08000000") +cpp_quote("#define STATE_SYSTEM_ALERT_HIGH 0x10000000") +cpp_quote("#define STATE_SYSTEM_PROTECTED 0x20000000") +cpp_quote("#define STATE_SYSTEM_VALID 0x7FFFFFFF") +cpp_quote("#endif") +cpp_quote("#ifndef STATE_SYSTEM_HASPOPUP") +cpp_quote("#define STATE_SYSTEM_HASPOPUP 0x40000000") +cpp_quote("#endif") + typedef GUID MSAAPROPID; typedef enum AnnoScope @@ -262,7 +307,8 @@ library Accessibility interface IAccPropServices; [ - uuid(b5f8350b-0548-48b1-a6ee-88bd00b4a5e7) + uuid(b5f8350b-0548-48b1-a6ee-88bd00b4a5e7), + threading(apartment) ] coclass CAccPropServices { @@ -270,7 +316,6 @@ library Accessibility } }; -cpp_quote("DEFINE_GUID(LIBID_Accessibility, 0x1ea4dbf0, 0x3c3b, 0x11cf, 0x81, 0x0c, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71);") cpp_quote("DEFINE_GUID(CLSID_AccPropServices, 0xb5f8350b, 0x0548, 0x48b1, 0xa6, 0xee, 0x88, 0xbd, 0x00, 0xb4, 0xa5, 0xe7);") cpp_quote("DEFINE_GUID(IIS_IsOleaccProxy, 0x902697fa, 0x80e4, 0x4560, 0x80, 0x2a, 0xa1, 0x3f, 0x22, 0xa6, 0x47, 0x09);") diff --git a/include/psdk/winddi.h b/include/psdk/winddi.h index 85b5278d095..4346cbdf701 100644 --- a/include/psdk/winddi.h +++ b/include/psdk/winddi.h @@ -29,6 +29,7 @@ #error video.h cannot be included with winddi.h #else +//#include #include #include #include @@ -42,11 +43,63 @@ extern "C" { #endif #if defined(_ENGINE_EXPORT_) -#define ENGAPI + #define ENGAPI #else -#define ENGAPI DECLSPEC_IMPORT + #define ENGAPI DECLSPEC_IMPORT #endif +#ifndef _NO_DDRAWINT_NO_COM + +#if !defined(EXTERN_C) + #ifdef __cplusplus + #define EXTERN_C extern "C" + #define __EXTERN_C extern "C" + #else + #define EXTERN_C extern + #define __EXTERN_C + #endif +#endif /* !defined(EXTERN_C) */ + +#if !defined(DEFINE_GUID) + #ifdef INITGUID + #define DEFINE_GUID(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ + __EXTERN_C const GUID name = { l, w1, w2, { b1, b2, b3, b4, b5, b6, b7, b8 } } + #else /* !INITGUID */ + #define DEFINE_GUID(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ + EXTERN_C const GUID FAR name + #endif /* !INITGUID */ +#endif /* !defined(DEFINE_GUID) */ + +#if !defined(DEFINE_GUIDEX) + #define DEFINE_GUIDEX(name) EXTERN_C const CDECL GUID name +#endif /* !defined(DEFINE_GUIDEX) */ + +#if !defined(STATICGUIDOF) + #define STATICGUIDOF(guid) STATIC_##guid +#endif /* !defined(STATICGUIDOF) */ + +#if !defined(GUID_DEFINED) + #define GUID_DEFINED + typedef struct _GUID + { + ULONG Data1; + USHORT Data2; + USHORT Data3; + UCHAR Data4[8]; + } GUID; +#endif /* !defined(GUID_DEFINED) */ + +#if !defined(IsEqualGUID) + #define IsEqualGUID(guid1, guid2) \ + (!memcmp((guid1), (guid2), sizeof(GUID))) +#endif /* !defined(IsEqualGUID) */ + +#ifndef IsEqualIID + #define IsEqualIID IsEqualGUID +#endif /* !defined(IsEqualIID) */ + +#endif /* !_NO_DDRAWINT_NO_COM */ + #define DDI_DRIVER_VERSION_NT4 0x00020000 #define DDI_DRIVER_VERSION_SP3 0x00020003 #define DDI_DRIVER_VERSION_NT5 0x00030000 @@ -85,6 +138,9 @@ DECLARE_HANDLE(HSURF); DECLARE_HANDLE(DHSURF); DECLARE_HANDLE(DHPDEV); DECLARE_HANDLE(HDRVOBJ); +DECLARE_HANDLE(HSEMAPHORE); + +typedef _Return_type_success_(return >= 0) long NTSTATUS; #ifndef _NTDDVDEO_ typedef struct _ENG_EVENT *PEVENT; @@ -108,6 +164,14 @@ typedef struct _ENG_EVENT *PEVENT; #define DN_DEVICE_ORIGIN 2 #define DN_SLEEP_MODE 3 #define DN_DRAWING_BEGIN 4 +#if (NTDDI_VERSION >= NTDDI_WIN8) +#define DN_ASSOCIATE_WINDOW 5 +#define DN_COMPOSITION_CHANGED 6 +#define DN_DRAWING_BEGIN_APIBITMAP 7 +#define DN_SURFOBJ_DESTRUCTION 8 +#endif /* (NTDDI_VERSION >= NTDDI_WIN8) */ + +#define SGI_EXTRASPACE 0 #define DCR_SOLID 0 #define DCR_DRIVER 1 @@ -124,6 +188,10 @@ typedef struct _ENG_EVENT *PEVENT; #define FXTOLCEILING(x) ((x + 0x0F) >> 4) #define FXTOLROUND(x) ((((x) >> 3) + 1) >> 1) +#define SIZEOFDV(cAxes) (offsetof(DESIGNVECTOR, dvValues) + (cAxes) * sizeof(LONG)) +#define SIZEOFAXIW(cAxes) (offsetof(AXESLISTW, axlAxisInfo) + (cAxes) * sizeof(AXISINFOW)) +#define SIZEOFAXIA(cAxes) (offsetof(AXESLISTA, axlAxisInfo) + (cAxes) * sizeof(AXISINFOA)) + typedef struct _POINTE { FLOATL x; FLOATL y; @@ -306,6 +374,17 @@ typedef struct _DEVHTADJDATA { #define GCAPS2_ICD_MULTIMON 0x00000100 #define GCAPS2_MOUSETRAILS 0x00000200 #define GCAPS2_RESERVED1 0x00000400 +#if (NTDDI_VERSION >= NTDDI_VISTA) +#define GCAPS2_EXCLUDELAYERED 0x00000800 +#define GCAPS2_INCLUDEAPIBITMAPS 0x00001000 +#define GCAPS2_SHOWHIDDENPOINTER 0x00002000 +#endif /* (NTDDI_VERSION >= NTDDI_VISTA) */ +#if (NTDDI_VERSION >= NTDDI_WIN7) +#define GCAPS2_CLEARTYPE 0x00004000 +#endif /* (NTDDI_VERSION >= NTDDI_WIN7) */ +#if (NTDDI_VERSION >= NTDDI_WIN8) +#define GCAPS2_ACC_DRIVER 0x00008000 +#endif /* (NTDDI_VERSION >= NTDDI_WIN8) */ typedef struct _DEVINFO { FLONG flGraphicsCaps; @@ -465,8 +544,11 @@ typedef struct _DRVENABLEDATA { DRVFN *pdrvfn; } DRVENABLEDATA, *PDRVENABLEDATA; -DECLARE_HANDLE(HSEMAPHORE); +/* Font file status values */ +#define FF_SIGNATURE_VERIFIED 0x00000001L +#define FF_IGNORED_SIGNATURE 0x00000002L + /* Obsolete in Windows 2000 and later */ typedef struct { DWORD nSize; HDC hdc; @@ -569,6 +651,22 @@ typedef struct _FD_KERNINGPAIR { FWORD fwdKern; } FD_KERNINGPAIR; + /* Obsolete in Windows 2000 and later */ +typedef struct _LIGATURE { + ULONG culSize; + LPWSTR pwsz; + ULONG chglyph; + HGLYPH ahglyph[1]; +} LIGATURE, *PLIGATURE; + + /* Obsolete in Windows 2000 and later */ +typedef struct _FD_LIGATURE { + ULONG culThis; + ULONG ulType; + ULONG cLigatures; + LIGATURE alig[1]; +} FD_LIGATURE; + #if defined(_X86_) && !defined(USERMODE_DRIVER) typedef struct _FLOATOBJ { @@ -654,6 +752,11 @@ typedef struct _FONTINFO { #define FO_NOCLEARTYPE 0x02000000 #define FO_CLEARTYPE_X 0x10000000 #define FO_CLEARTYPE_Y 0x20000000 +#define FO_CLEARTYPENATURAL_X 0x40000000 + +#define FD_NEGATIVE_FONT 1L /* Obsolete in Windows 2000 and later */ +#define FO_DEVICE_FONT 1L +#define FO_OUTLINE_CAPABLE 2L typedef struct _FONTOBJ { ULONG iUniq; @@ -842,6 +945,9 @@ typedef struct _PATHDATA { #define PO_ELLIPSE 0x00000002 #define PO_ALL_INTEGERS 0x00000004 #define PO_ENUM_AS_INTEGERS 0x00000008 +#if (NTDDI_VERSION >= NTDDI_WIN7) +#define PO_WIDENED 0x00000010 +#endif /* (NTDDI_VERSION >= NTDDI_WIN7) */ typedef struct _PATHOBJ { FLONG fl; @@ -932,7 +1038,7 @@ typedef struct _IFIEXTRA { #define FM_INFO_IGNORE_TC_RA_ABLE 0x40000000 #define FM_INFO_TECH_TYPE1 0x80000000 -#define MAXCHARSETS 16 +#define MAXCHARSETS 16 /* Obsolete in Windows 2000 and later */ /* IFIMETRICS.ulPanoseCulture constants */ #define FM_PANOSE_CULTURE_LATIN 0x0 @@ -1079,7 +1185,21 @@ typedef struct _STROBJ { #define BMF_NOTSYSMEM 0x0020 #define BMF_WINDOW_BLT 0x0040 #define BMF_UMPDMEM 0x0080 +#if (NTDDI_VERSION >= NTDDI_WIN7) +#define BMF_TEMP_ALPHA 0x0100 +#endif /* (NTDDI_VERSION >= NTDDI_WIN7) */ +#if (NTDDI_VERSION >= NTDDI_WIN8) +#define BMF_ACC_NOTIFY 0x8000 +#define BMF_RMT_ENTER 0x4000 +#endif /* (NTDDI_VERSION >= NTDDI_WIN8) */ + +#if (NTDDI_VERSION >= NTDDI_WIN8) +#define BMF_RESERVED 0x3E00 +#elif (NTDDI_VERSION >= NTDDI_WIN7) +#define BMF_RESERVED 0xFE00 +#else #define BMF_RESERVED 0xFF00 +#endif typedef struct _SURFOBJ { DHSURF dhsurf; @@ -1237,6 +1357,9 @@ EngAcquireSemaphore( #define FL_ZERO_MEMORY 0x00000001 #define FL_NONPAGED_MEMORY 0x00000002 +#if (NTDDI_VERSION >= NTDDI_WIN7) +#define FL_NON_SESSION 0x00000004 +#endif /* (NTDDI_VERSION >= NTDDI_WIN7) */ #ifdef USERMODE_DRIVER @@ -1244,7 +1367,7 @@ EngAcquireSemaphore( #define EngAllocPrivateUserMem(psl, cj, tag) ((PVOID)GlobalAlloc(GMEM_FIXED, cj)) #define EngAllocUserMem(cj, tag) ((PVOID)GlobalAlloc(GMEM_FIXED, cj)) -#else +#else /* !USERMODE_DRIVER */ _Must_inspect_result_ _When_(fl & FL_ZERO_MEMORY, _Ret_opt_bytecount_(cjMemSize)) @@ -1276,7 +1399,7 @@ EngAllocUserMem( _In_ SIZE_T cjMemSize, _In_ ULONG ulTag); -#endif /* USERMODE_DRIVER */ +#endif /* !USERMODE_DRIVER */ ENGAPI BOOL @@ -1350,6 +1473,7 @@ APIENTRY EngClearEvent( _In_ PEVENT pEvent); +_Success_(return != 0) ENGAPI FD_GLYPHSET* APIENTRY @@ -1377,8 +1501,8 @@ EngCopyBits( _In_ SURFOBJ *psoSrc, _In_opt_ CLIPOBJ *pco, _In_opt_ XLATEOBJ *pxlo, - _In_ RECTL *prclDest, - _In_ POINTL *pptlSrc); + _In_ __in_data_source(USER_MODE) RECTL *prclDest, + _In_ __in_data_source(USER_MODE) POINTL *pptlSrc); ENGAPI HBITMAP @@ -1567,9 +1691,9 @@ APIENTRY EngDeviceIoControl( _In_ HANDLE hDevice, _In_ DWORD dwIoControlCode, - _In_opt_bytecount_(cjInBufferSize) LPVOID lpInBuffer, + _In_reads_bytes_opt_(cjInBufferSize) LPVOID lpInBuffer, _In_ DWORD cjInBufferSize, - _Out_opt_bytecap_(cjOutBufferSize) LPVOID lpOutBuffer, + _Out_writes_bytes_opt_(cjOutBufferSize) LPVOID lpOutBuffer, _In_ DWORD cjOutBufferSize, _Out_ LPDWORD lpBytesReturned); @@ -1587,6 +1711,18 @@ EngDitherColor( _When_(iMode == DM_MONOCHROME, _Out_writes_bytes_(8)) ULONG *pul); +/* Obsolete in Windows 2000 and later */ +ENGAPI +HRESULT +APIENTRY +EngDxIoctl( + _In_ ULONG ulIoctl, + _Inout_ PVOID pBuffer, + _In_ ULONG ulBufferSize); + +#ifdef USERMODE_DRIVER +#define EngEnumForms EnumForms +#else /* !USERMODE_DRIVER */ ENGAPI BOOL APIENTRY @@ -1597,6 +1733,7 @@ EngEnumForms( _In_ DWORD cbBuf, _Out_ LPDWORD pcbNeeded, _Out_ LPDWORD pcReturned); +#endif /* !USERMODE_DRIVER */ ENGAPI BOOL @@ -1618,12 +1755,16 @@ EngFillPath( _In_ MIX mix, _In_ FLONG flOptions); +#ifdef USERMODE_DRIVER +#define EngFindImageProcAddress(h, procname) ((PVOID) GetProcAddress(h, procname)) +#else /* !USERMODE_DRIVER */ ENGAPI PVOID APIENTRY EngFindImageProcAddress( _In_ HANDLE hModule, _In_ LPSTR lpProcName); +#endif /* !USERMODE_DRIVER */ ENGAPI PVOID @@ -1735,6 +1876,12 @@ EngGetFilePath( _In_ HANDLE h, _Out_ WCHAR (*pDest)[MAX_PATH+1]); +#ifdef USERMODE_DRIVER +#define EngGetForm GetForm +#define EngGetLastError GetLastError +#define EngGetPrinter GetPrinter +#define EngGetPrinterData GetPrinterData +#else /* !USERMODE_DRIVER */ ENGAPI BOOL APIENTRY @@ -1746,14 +1893,10 @@ EngGetForm( _In_ DWORD cbBuf, _Out_ LPDWORD pcbNeeded); -#ifdef USERMODE_DRIVER -#define EngGetLastError GetLastError -#else ENGAPI ULONG APIENTRY EngGetLastError(VOID); -#endif ENGAPI BOOL @@ -1775,6 +1918,7 @@ EngGetPrinterData( _Out_writes_bytes_opt_(cjSize) LPBYTE pData, _In_ DWORD cjSize, _Out_ LPDWORD pcjNeeded); +#endif /* !USERMODE_DRIVER */ ENGAPI LPWSTR @@ -1782,6 +1926,9 @@ APIENTRY EngGetPrinterDataFileName( _In_ HDEV hdev); +#ifdef USERMODE_DRIVER +#define EngGetPrinterDriver GetPrinterDriver +#else /* !USERMODE_DRIVER */ ENGAPI BOOL APIENTRY @@ -1792,6 +1939,7 @@ EngGetPrinterDriver( _Out_writes_bytes_opt_(cjBufSize) BYTE *lpbDrvInfo, _In_ DWORD cjBufSize, _Out_ DWORD *pcjNeeded); +#endif /* !USERMODE_DRIVER */ ENGAPI HANDLE @@ -1867,11 +2015,15 @@ EngLineTo( _In_opt_ RECTL *prclBounds, _In_ MIX mix); +#ifdef USERMODE_DRIVER +#define EngLoadImage(pwszDriver) ((HANDLE)LoadLibraryW(pwszDriver)) +#else /* !USERMODE_DRIVER */ ENGAPI HANDLE APIENTRY EngLoadImage( _In_ LPWSTR pwszDriver); +#endif /* !USERMODE_DRIVER */ ENGAPI HANDLE @@ -1929,6 +2081,7 @@ EngMapFile( _In_ ULONG cjSize, _Out_ ULONG_PTR *piFile); +__drv_preferredFunction("EngMapFontFileFD", "Obsolete") ENGAPI BOOL APIENTRY @@ -1961,6 +2114,7 @@ EngMarkBandingSurface( /* EngModifySurface.flSurface constants */ #define MS_NOTSYSTEMMEMORY 0x00000001 #define MS_SHAREDACCESS 0x00000002 +#define MS_CDDDEVICEBITMAP 0x00000004 ENGAPI BOOL @@ -2024,7 +2178,7 @@ EngPaint( _In_ CLIPOBJ *pco, _In_ BRUSHOBJ *pbo, _In_ POINTL *pptlBrushOrg, - _In_ MIX mix); + _In_ __in_data_source(USER_MODE) MIX mix); ENGAPI BOOL @@ -2040,18 +2194,14 @@ EngPlgBlt( _In_ POINTFIX *pptfx, _In_ RECTL *prcl, _When_(psoMsk, _In_) POINTL *pptl, - _In_ ULONG iMode); + _In_ __in_data_source(USER_MODE) ULONG iMode); ENGAPI VOID APIENTRY EngProbeForRead( _In_reads_bytes_(Length) PVOID Address, -#if (NTDDI_VERSION <= NTDDI_WINXP) - _In_ ULONG Length, -#else _In_ SIZE_T Length, -#endif _In_ ULONG Alignment); ENGAPI @@ -2059,11 +2209,7 @@ VOID APIENTRY EngProbeForReadAndWrite( _Inout_updates_bytes_(Length) PVOID Address, -#if (NTDDI_VERSION <= NTDDI_WINXP) - _In_ ULONG Length, -#else _In_ SIZE_T Length, -#endif _In_ ULONG Alignment); typedef enum _ENG_DEVICE_ATTRIBUTE { @@ -2082,6 +2228,13 @@ EngQueryDeviceAttribute( _Out_writes_bytes_(cjOutSize) PVOID pvOut, _In_ ULONG cjOutSize); +/* Obsolete in Windows 2000 and later */ +DECLSPEC_DEPRECATED_DDK +BOOL APIENTRY +EngQueryEMFInfo( + _In_ HDEV hdev, + _Out_ EMFINFO *pEMFInfo); + ENGAPI LARGE_INTEGER APIENTRY @@ -2125,6 +2278,11 @@ typedef enum _ENG_SYSTEM_ATTRIBUTE { #define QSA_MMX 0x00000100 #define QSA_SSE 0x00002000 #define QSA_3DNOW 0x00004000 +#if (NTDDI_VERSION >= NTDDI_VISTA) +#define QSA_SSE1 QSA_SSE +#define QSA_SSE2 0x00010000 +#define QSA_SSE3 0x00080000 +#endif /* (NTDDI_VERSION >= NTDDI_VISTA) */ _Check_return_ _Success_(return) @@ -2147,6 +2305,43 @@ APIENTRY EngReleaseSemaphore( _In_ HSEMAPHORE hsem); +#if defined(_M_AMD64) && (NTDDI_VERSION >= NTDDI_VISTA) + +_Check_return_ +_Success_(return) +_Kernel_float_restored_ +_At_(*pBuffer, _Kernel_requires_resource_held_(EngFloatState) + _Kernel_releases_resource_(EngFloatState)) +ENGAPI +BOOL +APIENTRY +EngRestoreFloatingPointState( + _In_reads_(_Inexpressible_(statesize)) + PVOID pBuffer) +{ + UNREFERENCED_PARAMETER(pBuffer); + return TRUE; +} + +_Check_return_ +_Success_(((pBuffer != NULL && cjBufferSize != 0) && return == 1) || + ((pBuffer == NULL || cjBufferSize == 0) && return > 0)) +_When_(pBuffer != NULL && cjBufferSize != 0 && return == 1, _Kernel_float_saved_ + _At_(*pBuffer, _Post_valid_ _Kernel_acquires_resource_(EngFloatState))) +_On_failure_(_Post_satisfies_(return == 0)) +ENGAPI +ULONG +APIENTRY +EngSaveFloatingPointState( + _At_(*pBuffer, _Kernel_requires_resource_not_held_(EngFloatState)) + _Out_writes_bytes_opt_(cjBufferSize) PVOID pBuffer, + _Inout_ ULONG cjBufferSize) +{ + return ((((pBuffer) == NULL) || ((cjBufferSize) == 0)) ? 8 : TRUE); +} + +#else /* !(defined(_M_AMD64) && (NTDDI_VERSION >= NTDDI_VISTA)) */ + _Check_return_ _Success_(return) _Kernel_float_restored_ @@ -2173,6 +2368,9 @@ EngSaveFloatingPointState( _Out_writes_bytes_opt_(cjBufferSize) PVOID pBuffer, _Inout_ ULONG cjBufferSize); + +#endif /* defined(_M_AMD64) && (NTDDI_VERSION >= NTDDI_VISTA) */ + ENGAPI HANDLE APIENTRY @@ -2188,13 +2386,13 @@ EngSetEvent( #ifdef USERMODE_DRIVER #define EngSetLastError SetLastError -#else +#else /* !USERMODE_DRIVER */ ENGAPI VOID APIENTRY EngSetLastError( _In_ ULONG iError); -#endif +#endif /* !USERMODE_DRIVER */ ENGAPI ULONG @@ -2211,6 +2409,7 @@ EngSetPointerShape( _In_ RECTL *prcl, _In_ FLONG fl); +__drv_preferredFunction("(see documentation)", "Obsolete, always returns false. ") ENGAPI BOOL APIENTRY @@ -2221,6 +2420,9 @@ EngSetPointerTag( _Reserved_ XLATEOBJ *pxlo, _In_ FLONG fl); +#ifdef USERMODE_DRIVER +#define EngSetPrinterData SetPrinterData +#else /* !USERMODE_DRIVER */ ENGAPI DWORD APIENTRY @@ -2230,6 +2432,7 @@ EngSetPrinterData( _In_ DWORD dwType, _In_reads_bytes_(cjPrinterData) LPBYTE lpbPrinterData, _In_ DWORD cjPrinterData); +#endif /* !USERMODE_DRIVER */ typedef int (CDECL *SORTCOMP)(const void *pv1, const void *pv2); @@ -2288,8 +2491,8 @@ EngStrokeAndFillPath( _In_ LINEATTRS *plineattrs, _In_ BRUSHOBJ *pboFill, _In_ POINTL *pptlBrushOrg, - _In_ MIX mixFill, - _In_ FLONG flOptions); + _In_ __in_data_source(USER_MODE) MIX mixFill, + _In_ __in_data_source(USER_MODE) FLONG flOptions); ENGAPI BOOL @@ -2342,11 +2545,15 @@ EngUnicodeToMultiByteN( _In_reads_bytes_(cjUnicodeString) PWSTR pwszUnicodeString, _In_ ULONG cjUnicodeString); +#ifdef USERMODE_DRIVER +#define EngUnloadImage(h) FreeLibrary((HMODULE) (h)) +#else /* !USERMODE_DRIVER */ ENGAPI VOID APIENTRY EngUnloadImage( _In_ HANDLE hModule); +#endif /* !USERMODE_DRIVER */ ENGAPI BOOL @@ -2378,6 +2585,7 @@ APIENTRY EngUnmapFile( _In_ ULONG_PTR iFile); +__drv_preferredFunction("EngUnmapFontFileFD", "Obsolete") ENGAPI VOID APIENTRY @@ -2413,6 +2621,9 @@ EngWideCharToMultiByte( _Out_z_bytecap_(cjMultiByteString) LPSTR pszMultiByteString, _In_ INT cjMultiByteString); +#ifdef USERMODE_DRIVER +#define EngWritePrinter WritePrinter +#else /* !USERMODE_DRIVER */ ENGAPI BOOL APIENTRY @@ -2421,6 +2632,7 @@ EngWritePrinter( _In_reads_bytes_(cjBuf) LPVOID pvBuf, _In_ DWORD cjBuf, _Out_ LPDWORD pcWritten); +#endif /* !USERMODE_DRIVER */ #if defined(_X86_) && !defined(USERMODE_DRIVER) ENGAPI @@ -2684,6 +2896,7 @@ FONTOBJ_vGetInfo( _Out_bytecap_(cjSize) FONTINFO *pfi); #if (NTDDI_VERSION <= NTDDI_WINXP) + /* Obsolete in Windows 2000 and later */ GAMMA_TABLES* APIENTRY FONTOBJ_pGetGammaTables( @@ -2892,6 +3105,14 @@ XFORMOBJ_bApplyXform( _In_reads_bytes_(cPoints * sizeof(POINTL)) PVOID pvIn, _Out_writes_bytes_(cPoints * sizeof(POINTL)) PVOID pvOut); +/* Obsolete in Windows 2000 and later */ +DECLSPEC_DEPRECATED_DDK +ENGAPI +HANDLE +APIENTRY +XFORMOBJ_cmGetTransform( + XFORMOBJ *pxo); + #if !defined(USERMODE_DRIVER) ENGAPI ULONG @@ -2945,6 +3166,223 @@ APIENTRY XLATEOBJ_piVector( _In_ XLATEOBJ *pxlo); +#if (NTDDI_VERSION >= NTDDI_WINXPSP2) + +ENGAPI +VOID +APIENTRY +EngBugCheckEx( + _In_ ULONG BugCheckCode, + _In_ ULONG_PTR P1, + _In_ ULONG_PTR P2, + _In_ ULONG_PTR P3, + _In_ ULONG_PTR P4); + +#endif /* (NTDDI_VERSION >= NTDDI_WINXPSP2) */ + +#if (NTDDI_VERSION >= NTDDI_VISTA) + +ENGAPI +HANDLE +APIENTRY +EngCreateRectRgn( + _In_ INT left, + _In_ INT top, + _In_ INT right, + _In_ INT bottom); + +ENGAPI +VOID +APIENTRY +EngDeleteRgn( + _In_ HANDLE hrgn); + +ENGAPI +INT +APIENTRY +EngCombineRgn( + _In_ HANDLE hrgnTrg, + _In_ HANDLE hrgnSrc1, + _In_ HANDLE hrgnSrc2, + _In_ INT iMode); + +ENGAPI +INT +APIENTRY +EngCopyRgn( + _In_ HANDLE hrgnDst, + _In_ HANDLE hrgnSrc); + +ENGAPI +INT +APIENTRY +EngIntersectRgn( + _In_ HANDLE hrgnResult, + _In_ HANDLE hRgnA, + _In_ HANDLE hRgnB); + +ENGAPI +INT +APIENTRY +EngSubtractRgn( + _In_ HANDLE hrgnResult, + _In_ HANDLE hRgnA, + _In_ HANDLE hRgnB); + +ENGAPI +INT +APIENTRY +EngUnionRgn( + _In_ HANDLE hrgnResult, + _In_ HANDLE hRgnA, + _In_ HANDLE hRgnB); + +ENGAPI +INT +APIENTRY +EngXorRgn( + _In_ HANDLE hrgnResult, + _In_ HANDLE hRgnA, + _In_ HANDLE hRgnB); + +ENGAPI +BOOL +APIENTRY +EngRectInRgn( + _In_ HANDLE hrgn, + _In_ LPRECT prcl); + +ENGAPI +BOOL +APIENTRY +EngEqualRgn( + _In_ HANDLE hrgn1, + _In_ HANDLE hrgn2); + +ENGAPI +DWORD +APIENTRY +EngGetRgnData( + _In_ HANDLE hrgn, + _In_ DWORD nCount, + _Out_cap_(nCount) LPRGNDATA lpRgnData); + +ENGAPI +BOOL +APIENTRY +EngSetRectRgn( + _In_ HANDLE hrgn, + _In_ INT left, + _In_ INT top, + _In_ INT right, + _In_ INT bottom); + +ENGAPI +INT +APIENTRY +EngGetRgnBox( + _In_ HANDLE hrgn, + _Out_ LPRECT prcl); + +ENGAPI +INT +APIENTRY +EngOffsetRgn( + _In_ HANDLE hrgn, + _In_ INT x, + _In_ INT y); + +ENGAPI +VOID +APIENTRY +EngRenderHint( + _In_ DHPDEV dhpdev, + _In_ ULONG NotifyCode, + _In_ SIZE_T Length, + _In_reads_bytes_opt_(Length) PVOID Data); + +ENGAPI +VOID +APIENTRY +EngAcquireSemaphoreShared( + _In_ HSEMAPHORE hsem); + +ENGAPI +BOOL +APIENTRY +EngAcquireSemaphoreNoWait( + _In_ HSEMAPHORE hsem); + +ENGAPI +BOOL +APIENTRY +EngAcquireSemaphoreSharedNoWait( + _In_ HSEMAPHORE hsem); + +ENGAPI +BOOL +APIENTRY +EngIsSemaphoreSharedByCurrentThread( + _In_ HSEMAPHORE hsem); + +DECLARE_HANDLE(HFASTMUTEX); + +ENGAPI +HFASTMUTEX +APIENTRY +EngCreateFastMutex( + VOID); + +ENGAPI +VOID +APIENTRY +EngDeleteFastMutex( + _In_ HFASTMUTEX hfm); + +ENGAPI +VOID +APIENTRY +EngAcquireFastMutex( + _In_ HFASTMUTEX hfm); + +ENGAPI +VOID +APIENTRY +EngReleaseFastMutex( + _In_ HFASTMUTEX hfm); + +ENGAPI +BOOL +APIENTRY +EngUpdateDeviceSurface( + _In_ SURFOBJ *pso, + _Inout_ CLIPOBJ **ppco); + +#endif /* (NTDDI_VERSION >= NTDDI_VISTA) */ + +#if (NTDDI_VERSION >= NTDDI_WIN7) + +ENGAPI +HBITMAP +APIENTRY +EngCreateRedirectionDeviceBitmap( + __in_data_source(USER_MODE) DHSURF dhsurf, + __in_data_source(USER_MODE) SIZEL sizl, + _In_ ULONG iFormatCompat); + +VOID +APIENTRY +EngCTGetGammaTable( + _In_ ULONG ulGamma, + _Out_ CONST BYTE** pGammaTable, + _Out_ CONST BYTE** pInverseGammaTable); + +ULONG +APIENTRY +EngCTGetCurrentGamma( + _In_ HDEV hdev); + +#endif /* (NTDDI_VERSION >= NTDDI_WIN7) */ /* Graphics Driver Functions */ @@ -3382,7 +3820,6 @@ extern FN_DrvQueryFont DrvQueryFont; #define QC_OUTLINES 0x00000001 #define QC_1BIT 0x00000002 #define QC_4BIT 0x00000004 - #define QC_FONTDRIVERCAPS (QC_OUTLINES | QC_1BIT | QC_4BIT) typedef LONG @@ -3578,6 +4015,9 @@ extern FN_DrvSetPixelFormat DrvSetPixelFormat; #define SPS_ANIMATESTART 0x00000004L #define SPS_ANIMATEUPDATE 0x00000008L #define SPS_ALPHA 0x00000010L +#define SPS_RESERVED 0x00000020L /* Force s/w cursor rendering */ +#define SPS_RESERVED1 0x00000040L /* Force show/hide system cursor */ +#define SPS_FLAGSMASK 0x000000FFL #define SPS_LENGTHMASK 0x00000F00L #define SPS_FREQMASK 0x000FF000L @@ -3776,6 +4216,192 @@ typedef BOOL //DECLSPEC_DEPRECATED_DDK typedef FN_DrvQuerySpoolType *PFN_DrvQuerySpoolType; extern FN_DrvQuerySpoolType DrvQuerySpoolType; +typedef LONG +(APIENTRY FN_DrvQueryTrueTypeSection)( + ULONG, + ULONG, + ULONG, + HANDLE *, + PTRDIFF *); +typedef FN_DrvQueryTrueTypeSection *PFN_DrvQueryTrueTypeSection; +extern FN_DrvQueryTrueTypeSection DrvQueryTrueTypeSection; + +DECLSPEC_DEPRECATED_DDK +typedef VOID +(APIENTRY FN_DrvMovePanning)( + _In_ LONG x, + _In_ LONG y, + _In_ FLONG fl); +typedef FN_DrvMovePanning *PFN_DrvMovePanning; +extern FN_DrvMovePanning DrvMovePanning; + +#if (NTDDI_VERSION >= NTDDI_VISTA) + +typedef LONG +(APIENTRY FN_DrvRenderHint)( + _In_ DHPDEV dhpdev, + _In_ ULONG NotifyCode, + _In_ SIZE_T Length, + _In_reads_bytes_opt_(Length) PVOID Data); +typedef FN_DrvRenderHint *PFN_DrvRenderHint; +extern FN_DrvRenderHint DrvRenderHint; + +typedef struct _DRH_APIBITMAPDATA +{ + SURFOBJ *pso; + BOOL b; +} DRH_APIBITMAPDATA, *PDRH_APIBITMAPDATA; + +#define DRH_APIBITMAP 0x00000001 + +typedef HANDLE +(APIENTRY FN_EngCreateRectRgn)( + _In_ INT left, + _In_ INT top, + _In_ INT right, + _In_ INT bottom); +typedef FN_EngCreateRectRgn *PFN_EngCreateRectRgn; + +typedef VOID +(APIENTRY FN_EngDeleteRgn)( + HANDLE hrgn); +typedef FN_EngDeleteRgn *PFN_EngDeleteRgn; + +typedef INT +(APIENTRY FN_EngCombineRgn)( + _In_ HANDLE hrgnTrg, + _In_ HANDLE hrgnSrc1, + _In_ HANDLE hrgnSrc2, + _In_ INT iMode); +typedef FN_EngCombineRgn *PFN_EngCombineRgn; + +typedef INT +(APIENTRY FN_EngCopyRgn)( + _In_ HANDLE hrgnDst, + _In_ HANDLE hrgnSrc); +typedef FN_EngCopyRgn *PFN_EngCopyRgn; + +typedef INT +(APIENTRY FN_EngIntersectRgn)( + _In_ HANDLE hrgnResult, + _In_ HANDLE hRgnA, + _In_ HANDLE hRgnB); +typedef FN_EngIntersectRgn *PFN_EngIntersectRgn; + +typedef INT +(APIENTRY FN_EngSubtractRgn)( + _In_ HANDLE hrgnResult, + _In_ HANDLE hRgnA, + _In_ HANDLE hRgnB); +typedef FN_EngSubtractRgn *PFN_EngSubtractRgn; + +typedef INT +(APIENTRY FN_EngUnionRgn)( + _In_ HANDLE hrgnResult, + _In_ HANDLE hRgnA, + _In_ HANDLE hRgnB); +typedef FN_EngUnionRgn *PFN_EngUnionRgn; + +typedef INT +(APIENTRY FN_EngXorRgn)( + _In_ HANDLE hrgnResult, + _In_ HANDLE hRgnA, + _In_ HANDLE hRgnB); +typedef FN_EngXorRgn *PFN_EngXorRgn; + +#endif /* (NTDDI_VERSION >= NTDDI_VISTA) */ + +#if (NTDDI_VERSION >= NTDDI_WIN7) + +/* DrvCreateDeviceBitmapEx() flags */ +#define CDBEX_REDIRECTION 0x00000001 +#define CDBEX_DXINTEROP 0x00000002 + +typedef HBITMAP +(APIENTRY FN_DrvCreateDeviceBitmapEx)( + _In_ DHPDEV dhpdev, + _In_ SIZEL sizl, + _In_ ULONG iFormat, + _In_ DWORD Flags, + _In_ DHSURF dhsurfGroup, + _In_ DWORD DxFormat, +#if (NTDDI_VERSION >= NTDDI_WIN8) + _In_ DWORD SubresourceIndex, +#endif /* (NTDDI_VERSION >= NTDDI_WIN8) */ + _Out_ HANDLE* phSharedSurface); +typedef FN_DrvCreateDeviceBitmapEx *PFN_DrvCreateDeviceBitmapEx; +extern DrvCreateDeviceBitmapEx DrvCreateDeviceBitmapEx + +typedef VOID +(APIENTRY FN_DrvDeleteDeviceBitmapEx)( + _Inout_ DHSURF); +typedef FN_DrvDeleteDeviceBitmapEx *PFN_DrvDeleteDeviceBitmapEx; +extern FN_DrvDeleteDeviceBitmapEx DrvDeleteDeviceBitmapEx; + +typedef BOOL +(APIENTRY FN_DrvAssociateSharedSurface)( + _In_ SURFOBJ* psoSurf, + _In_ HANDLE hPhysicalSurface, + _In_ HANDLE hLogicalSurface, + _In_ SIZEL sizl); +typedef FN_DrvAssociateSharedSurface *PFN_DrvAssociateSharedSurface; +extern FN_DrvAssociateSharedSurface DrvAssociateSharedSurface; + +typedef LONG +(APIENTRY FN_DrvSynchronizeRedirectionBitmaps)( + _In_ DHPDEV dhpdev, + _Out_ UINT64* puiFenceID); +typedef FN_DrvSynchronizeRedirectionBitmaps *PFN_DrvSynchronizeRedirectionBitmaps; +extern FN_DrvSynchronizeRedirectionBitmaps DrvSynchronizeRedirectionBitmaps; + +#define WINDDI_MAX_BROADCAST_CONTEXT 64 +typedef struct tagCDDDXGK_REDIRBITMAPPRESENTINFO +{ + UINT NumDirtyRects; + PRECT DirtyRect; + UINT NumContexts; + HANDLE hContext[WINDDI_MAX_BROADCAST_CONTEXT+1]; +} CDDDXGK_REDIRBITMAPPRESENTINFO; + +typedef BOOL +(APIENTRY FN_DrvAccumulateD3DDirtyRect)( + _In_ SURFOBJ* psoSurf, + _In_ CDDDXGK_REDIRBITMAPPRESENTINFO* pDirty); +typedef FN_DrvAccumulateD3DDirtyRect *PFN_DrvAccumulateD3DDirtyRect; +extern FN_DrvAccumulateD3DDirtyRect DrvAccumulateD3DDirtyRect; + +typedef BOOL +(APIENTRY FN_DrvStartDxInterop)( + _In_ SURFOBJ* psoSurf, + _In_ BOOL bDiscard, + _In_ PVOID KernelModeDeviceHandle); +typedef FN_DrvStartDxInterop *PFN_DrvStartDxInterop; +extern FN_DrvStartDxInterop DrvStartDxInterop; + +typedef BOOL +(APIENTRY FN_DrvEndDxInterop)( + _In_ SURFOBJ* psoSurf, + _In_ BOOL bDiscard, + _Out_ BOOL* bDeviceLost, + _In_ PVOID KernelModeDeviceHandle); +typedef FN_DrvEndDxInterop *PFN_DrvEndDxInterop; +extern FN_DrvEndDxInterop DrvEndDxInterop; + +typedef VOID +(APIENTRY FN_DrvLockDisplayArea)( + _In_ DHPDEV dhpdev, + _In_opt_ RECTL *prcl); +typedef FN_DrvLockDisplayArea *PFN_DrvLockDisplayArea; +extern FN_DrvLockDisplayArea DrvLockDisplayArea; + +typedef VOID +(APIENTRY FN_DrvUnlockDisplayArea)( + _In_ DHPDEV dhpdev, + _In_opt_ RECTL *prcl); +typedef FN_DrvUnlockDisplayArea *PFN_DrvUnlockDisplayArea; +extern FN_DrvUnlockDisplayArea DrvUnlockDisplayArea; + +#endif /* (NTDDI_VERSION >= NTDDI_WIN7) */ #ifdef __cplusplus } diff --git a/include/psdk/winnt.h b/include/psdk/winnt.h index f847726bd84..0d733ac35d2 100644 --- a/include/psdk/winnt.h +++ b/include/psdk/winnt.h @@ -729,6 +729,26 @@ typedef struct _GROUP_AFFINITY { #define RTL_CONST_CAST(type) (type) #endif +#ifdef __cplusplus +#define DEFINE_ENUM_FLAG_OPERATORS(_ENUMTYPE) \ +extern "C++" { \ + inline _ENUMTYPE operator|(_ENUMTYPE a, _ENUMTYPE b) { return _ENUMTYPE(((int)a) | ((int)b)); } \ + inline _ENUMTYPE &operator|=(_ENUMTYPE &a, _ENUMTYPE b) { return (_ENUMTYPE &)(((int &)a) |= ((int)b)); } \ + inline _ENUMTYPE operator&(_ENUMTYPE a, _ENUMTYPE b) { return _ENUMTYPE(((int)a) & ((int)b)); } \ + inline _ENUMTYPE &operator&=(_ENUMTYPE &a, _ENUMTYPE b) { return (_ENUMTYPE &)(((int &)a) &= ((int)b)); } \ + inline _ENUMTYPE operator~(_ENUMTYPE a) { return _ENUMTYPE(~((int)a)); } \ + inline _ENUMTYPE operator^(_ENUMTYPE a, _ENUMTYPE b) { return _ENUMTYPE(((int)a) ^ ((int)b)); } \ + inline _ENUMTYPE &operator^=(_ENUMTYPE &a, _ENUMTYPE b) { return (_ENUMTYPE &)(((int &)a) ^= ((int)b)); } \ +} +#else +#define DEFINE_ENUM_FLAG_OPERATORS(_ENUMTYPE) +#endif + +#define COMPILETIME_OR_2FLAGS(a,b) ((UINT)(a)|(UINT)(b)) +#define COMPILETIME_OR_3FLAGS(a,b,c) ((UINT)(a)|(UINT)(b)|(UINT)(c)) +#define COMPILETIME_OR_4FLAGS(a,b,c,d) ((UINT)(a)|(UINT)(b)|(UINT)(c)|(UINT)(d)) +#define COMPILETIME_OR_5FLAGS(a,b,c,d,e) ((UINT)(a)|(UINT)(b)|(UINT)(c)|(UINT)(d)|(UINT)(e)) + /* Type Limits */ #define MINCHAR 0x80 #define MAXCHAR 0x7f @@ -1424,21 +1444,6 @@ typedef struct _GROUP_AFFINITY { #define ACE_OBJECT_TYPE_PRESENT 0x00000001 #define ACE_INHERITED_OBJECT_TYPE_PRESENT 0x00000002 -#ifdef __cplusplus -#define DEFINE_ENUM_FLAG_OPERATORS(ENUMTYPE) \ -extern "C++" { \ - inline ENUMTYPE operator | (ENUMTYPE a, ENUMTYPE b) { return ENUMTYPE(((int)a)|((int)b)); } \ - inline ENUMTYPE operator |= (ENUMTYPE &a, ENUMTYPE b) { return (ENUMTYPE &)(((int &)a) |= ((int)b)); } \ - inline ENUMTYPE operator & (ENUMTYPE a, ENUMTYPE b) { return ENUMTYPE(((int)a)&((int)b)); } \ - inline ENUMTYPE operator &= (ENUMTYPE &a, ENUMTYPE b) { return (ENUMTYPE &)(((int &)a) &= ((int)b)); } \ - inline ENUMTYPE operator ~ (ENUMTYPE a) { return (ENUMTYPE)(~((int)a)); } \ - inline ENUMTYPE operator ^ (ENUMTYPE a, ENUMTYPE b) { return ENUMTYPE(((int)a)^((int)b)); } \ - inline ENUMTYPE operator ^= (ENUMTYPE &a, ENUMTYPE b) { return (ENUMTYPE &)(((int &)a) ^= ((int)b)); } \ -} -#else -# define DEFINE_ENUM_FLAG_OPERATORS(ENUMTYPE) /* */ -#endif - /* also in ddk/ntifs.h */ #define COMPRESSION_FORMAT_NONE (0x0000) #define COMPRESSION_FORMAT_DEFAULT (0x0001) diff --git a/include/reactos/idl/winreg.acf b/include/reactos/idl/winreg.acf new file mode 100644 index 00000000000..dbab62af61b --- /dev/null +++ b/include/reactos/idl/winreg.acf @@ -0,0 +1,6 @@ +[ + explicit_handle +] +interface winreg +{ +} \ No newline at end of file diff --git a/include/reactos/idl/winreg.idl b/include/reactos/idl/winreg.idl new file mode 100644 index 00000000000..c9784708347 --- /dev/null +++ b/include/reactos/idl/winreg.idl @@ -0,0 +1,363 @@ +/* + * Directory Service Setup interface definition + */ + +#include + +typedef [context_handle] HANDLE RPC_HKEY; +typedef RPC_HKEY *PRPC_HKEY; + +typedef [handle] PWCHAR PREGISTRY_SERVER_NAME; + +typedef struct value_ent +{ + PRPC_UNICODE_STRING ve_valuename; + DWORD ve_valuelen; + LPDWORD ve_valueptr; + DWORD ve_type; +} RVALENT, *PRVALENT; + +typedef ULONG REGSAM; + +typedef struct _RPC_SECURITY_DESCRIPTOR +{ + [size_is(cbInSecurityDescriptor), length_is(cbOutSecurityDescriptor)] PBYTE lpSecurityDescriptor; + DWORD cbInSecurityDescriptor; + DWORD cbOutSecurityDescriptor; +} RPC_SECURITY_DESCRIPTOR, *PRPC_SECURITY_DESCRIPTOR; + +typedef struct _RPC_SECURITY_ATTRIBUTES +{ + DWORD nLength; + RPC_SECURITY_DESCRIPTOR RpcSecurityDescriptor; + BOOLEAN bInheritHandle; +} RPC_SECURITY_ATTRIBUTES, *PRPC_SECURITY_ATTRIBUTES; + +[ + uuid(338CD001-2244-31F1-AAAA-900038001003), + version(1.0), + pointer_default(unique), + endpoint("ncacn_np:[\\pipe\\winreg]") +#ifndef __midl + ,explicit_handle +#endif +] +interface winreg +{ + /* Function 0 */ + error_status_t + __stdcall + OpenClassesRoot( + [in, unique] PREGISTRY_SERVER_NAME ServerName, + [in] REGSAM samDesired, + [out] PRPC_HKEY phKey); + + /* Function 1 */ + error_status_t + __stdcall + OpenCurrentUser( + [in, unique] PREGISTRY_SERVER_NAME ServerName, + [in] REGSAM samDesired, + [out] PRPC_HKEY phKey); + + /* Function 2 */ + error_status_t + __stdcall + OpenLocalMachine( + [in, unique] PREGISTRY_SERVER_NAME ServerName, + [in] REGSAM samDesired, + [out] PRPC_HKEY phKey); + + /* Function 3 */ + error_status_t + __stdcall + OpenPerformanceData( + [in, unique] PREGISTRY_SERVER_NAME ServerName, + [in] REGSAM samDesired, + [out] PRPC_HKEY phKey); + + /* Function 4 */ + error_status_t + __stdcall + OpenUsers( + [in, unique] PREGISTRY_SERVER_NAME ServerName, + [in] REGSAM samDesired, + [out] PRPC_HKEY phKey); + + /* Function 5 */ + error_status_t + __stdcall + BaseRegCloseKey( + [in, out] PRPC_HKEY hKey); + + /* Function 6 */ + error_status_t + __stdcall + BaseRegCreateKey( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpSubKey, + [in] PRPC_UNICODE_STRING lpClass, + [in] DWORD dwOptions, + [in] REGSAM samDesired, + [in, unique] PRPC_SECURITY_ATTRIBUTES lpSecurityAttributes, + [out] PRPC_HKEY phkResult, + [in, out, unique] LPDWORD lpdwDisposition); + + /* Function 7 */ + error_status_t + __stdcall + BaseRegDeleteKey( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpSubKey); + + /* Function 8 */ + error_status_t + __stdcall + BaseRegDeleteValue( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpValueName); + + /* Function 9 */ + error_status_t + __stdcall + BaseRegEnumKey( + [in] RPC_HKEY hKey, + [in] DWORD dwIndex, + [in] PRPC_UNICODE_STRING lpNameIn, + [out] PRPC_UNICODE_STRING lpNameOut, + [in, unique] PRPC_UNICODE_STRING lpClassIn, + [out] PRPC_UNICODE_STRING *lplpClassOut, + [in, out, unique] PFILETIME lpftLastWriteTime); + + /* Function 10 */ + error_status_t + __stdcall + BaseRegEnumValue( + [in] RPC_HKEY hKey, + [in] DWORD dwIndex, + [in] PRPC_UNICODE_STRING lpValueNameIn, + [out] PRPC_UNICODE_STRING lpValueNameOut, + [in, out, unique] LPDWORD lpType, + [in, out, unique, size_is(lpcbData ? *lpcbData : 0), length_is(lpcbLen ? *lpcbLen : 0)] LPBYTE lpData, /* range(0, 0x4000000) */ + [in, out, unique] LPDWORD lpcbData, + [in, out, unique] LPDWORD lpcbLen); + + /* Function 11 */ + error_status_t + __stdcall + BaseRegFlushKey( + [in] RPC_HKEY hKey); + + /* Function 12 */ + error_status_t + __stdcall + BaseRegGetKeySecurity( + [in] RPC_HKEY hKey, + [in] SECURITY_INFORMATION SecurityInformation, + [in] PRPC_SECURITY_DESCRIPTOR pRpcSecurityDescriptorIn, + [out] PRPC_SECURITY_DESCRIPTOR pRpcSecurityDescriptorOut); + + /* Function 13 */ + error_status_t + __stdcall + BaseRegLoadKey( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpSubKey, + [in] PRPC_UNICODE_STRING lpFile); + + /* Function 14 */ + void + __stdcall + Opnum14NotImplemented(void); + + /* Function 15 */ + error_status_t + __stdcall + BaseRegOpenKey( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpSubKey, + [in] DWORD dwOptions, + [in] REGSAM samDesired, + [out] PRPC_HKEY phkResult); + + /* Function 16 */ + error_status_t + __stdcall + BaseRegQueryInfoKey( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpClassIn, + [out] PRPC_UNICODE_STRING lpClassOut, + [out] LPDWORD lpcSubKeys, + [out] LPDWORD lpcbMaxSubKeyLen, + [out] LPDWORD lpcbMaxClassLen, + [out] LPDWORD lpcValues, + [out] LPDWORD lpcbMaxValueNameLen, + [out] LPDWORD lpcbMaxValueLen, + [out] LPDWORD lpcbSecurityDescriptor, + [out] PFILETIME lpftLastWriteTime); + + /* Function 17 */ + error_status_t + __stdcall + BaseRegQueryValue( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpValueName, + [in, out, unique] LPDWORD lpType, + [in, out, unique, size_is(lpcbData ? *lpcbData : 0), length_is(lpcbLen ? *lpcbLen : 0)] LPBYTE lpData, /* range(0, 0x4000000) */ + [in, out, unique] LPDWORD lpcbData, + [in, out, unique] LPDWORD lpcbLen); + + /* Function 18 */ + error_status_t + __stdcall + BaseRegReplaceKey( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpSubKey, + [in] PRPC_UNICODE_STRING lpNewFile, + [in] PRPC_UNICODE_STRING lpOldFile); + + /* Function 19 */ + error_status_t + __stdcall + BaseRegRestoreKey( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpFile, + [in] DWORD Flags); + + /* Function 20 */ + error_status_t + __stdcall + BaseRegSaveKey( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpFile, + [in, unique] PRPC_SECURITY_ATTRIBUTES pSecurityAttributes); + + /* Function 21 */ + error_status_t + __stdcall + BaseRegSetKeySecurity( + [in] RPC_HKEY hKey, + [in] SECURITY_INFORMATION SecurityInformation, + [in] PRPC_SECURITY_DESCRIPTOR pRpcSecurityDescriptor); + + /* Function 22 */ + error_status_t + __stdcall + BaseRegSetValue( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpValueName, + [in] DWORD dwType, + [in, size_is(cbData)] LPBYTE lpData, + [in] DWORD cbData); + + /* Function 23 */ + error_status_t + __stdcall + BaseRegUnLoadKey( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpSubKey); + + /* Function 24 */ + ULONG + __stdcall + BaseInitiateSystemShutdown( + [in, unique] PREGISTRY_SERVER_NAME ServerName, + [in, unique] PRPC_UNICODE_STRING lpMessage, + [in] ULONG dwTimeout, + [in] BOOLEAN bForceAppsClosed, + [in] BOOLEAN bRebootAfterShutdown); + + /* Function 25 */ + ULONG + __stdcall + BaseAbortSystemShutdown( + [in, unique] PREGISTRY_SERVER_NAME ServerName); + + /* Function 26 */ + error_status_t + __stdcall + BaseRegGetVersion( + [in] RPC_HKEY hKey, + [out] LPDWORD lpdwVersion); + + /* Function 27 */ + error_status_t + __stdcall + OpenCurrentConfig( + [in, unique] PREGISTRY_SERVER_NAME ServerName, + [in] REGSAM samDesired, + [out] PRPC_HKEY phKey); + + /* Function 28 */ + void + __stdcall + Opnum28NotImplemented(void); + + /* Function 29 */ + error_status_t + __stdcall + BaseRegQueryMultipleValues( + [in] RPC_HKEY hKey, + [in, size_is(num_vals), length_is(num_vals)] PRVALENT val_listIn, + [out, size_is(num_vals), length_is(num_vals)] PRVALENT val_listOut, + [in] DWORD num_vals, + [in, out, unique, size_is(*ldwTotsize), length_is(*ldwTotsize)] char *lpvalueBuf, + [in, out, ref] LPDWORD ldwTotsize); + + /* Function 30 */ + ULONG + __stdcall + BaseInitiateSystemShutdownEx( + [in, unique] PREGISTRY_SERVER_NAME ServerName, + [in, unique] PRPC_UNICODE_STRING lpMessage, + [in] ULONG dwTimeout, + [in] BOOLEAN bForceAppsClosed, + [in] BOOLEAN bRebootAfterShutdown, + [in] ULONG dwReason); + + /* Function 31 */ + error_status_t + __stdcall + BaseRegSaveKeyEx( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpFile, + [in, unique] PRPC_SECURITY_ATTRIBUTES pSecurityAttributes, + [in] DWORD Flags); + + /* Function 32 */ + error_status_t + __stdcall + OpenPerformanceText( + [in, unique] PREGISTRY_SERVER_NAME ServerName, + [in] REGSAM samDesired, + [out] PRPC_HKEY phKey); + + /* Function 33 */ + error_status_t + __stdcall + OpenPerformanceNlsText( + [in, unique] PREGISTRY_SERVER_NAME ServerName, + [in] REGSAM samDesired, + [out] PRPC_HKEY phKey); + + /* Function 34 */ + error_status_t + __stdcall + BaseRegQueryMultipleValues2( + [in] RPC_HKEY hKey, + [in, size_is(num_vals), length_is(num_vals)] PRVALENT val_listIn, + [out, size_is(num_vals), length_is(num_vals)] PRVALENT val_listOut, + [in] DWORD num_vals, + [in, out, unique, size_is(*ldwTotsize), length_is(*ldwTotsize)] char *lpvalueBuf, + [in] LPDWORD ldwTotsize, + [out] LPDWORD ldwRequiredSize); + + /* Function 35 */ + error_status_t + __stdcall + BaseRegDeleteKeyEx( + [in] RPC_HKEY hKey, + [in] PRPC_UNICODE_STRING lpSubKey, + [in] REGSAM AccessMask, + [in] DWORD Reserved); +} diff --git a/include/reactos/wine/test.h b/include/reactos/wine/test.h index e0253f7ced3..82080ef404c 100644 --- a/include/reactos/wine/test.h +++ b/include/reactos/wine/test.h @@ -306,7 +306,11 @@ void winetest_set_location( const char* file, int line ) int broken( int condition ) { - return (strcmp(winetest_platform, "windows") == 0) && condition; + return ((strcmp(winetest_platform, "windows") == 0) +#ifndef USE_WINE_TODOS + || (strcmp(winetest_platform, "reactos") == 0) +#endif + ) && condition; } /* @@ -411,7 +415,11 @@ void __winetest_cdecl winetest_win_skip( const char *msg, ... ) { __winetest_va_list valist; __winetest_va_start(valist, msg); - if ((strcmp(winetest_platform, "windows") == 0) || (strcmp(winetest_platform, "reactos") == 0)) + if ((strcmp(winetest_platform, "windows") == 0) +#ifndef USE_WINE_TODOS + || (strcmp(winetest_platform, "reactos") == 0) +#endif + ) winetest_vskip(msg, valist); else winetest_vok(0, msg, valist); diff --git a/include/xdk/ntbasedef.h b/include/xdk/ntbasedef.h index 130742ab782..30b2c1e2f6d 100644 --- a/include/xdk/ntbasedef.h +++ b/include/xdk/ntbasedef.h @@ -352,10 +352,6 @@ typedef unsigned char UCHAR, *PUCHAR; typedef unsigned short USHORT, *PUSHORT; typedef unsigned long ULONG, *PULONG; -typedef CONST UCHAR *PCUCHAR; -typedef CONST USHORT *PCUSHORT; -typedef CONST ULONG *PCULONG; - typedef double DOUBLE; $endif(_NTDEF_) @@ -712,6 +708,26 @@ typedef struct _GROUP_AFFINITY { #define RTL_CONST_CAST(type) (type) #endif +#ifdef __cplusplus +#define DEFINE_ENUM_FLAG_OPERATORS(_ENUMTYPE) \ +extern "C++" { \ + inline _ENUMTYPE operator|(_ENUMTYPE a, _ENUMTYPE b) { return _ENUMTYPE(((int)a) | ((int)b)); } \ + inline _ENUMTYPE &operator|=(_ENUMTYPE &a, _ENUMTYPE b) { return (_ENUMTYPE &)(((int &)a) |= ((int)b)); } \ + inline _ENUMTYPE operator&(_ENUMTYPE a, _ENUMTYPE b) { return _ENUMTYPE(((int)a) & ((int)b)); } \ + inline _ENUMTYPE &operator&=(_ENUMTYPE &a, _ENUMTYPE b) { return (_ENUMTYPE &)(((int &)a) &= ((int)b)); } \ + inline _ENUMTYPE operator~(_ENUMTYPE a) { return _ENUMTYPE(~((int)a)); } \ + inline _ENUMTYPE operator^(_ENUMTYPE a, _ENUMTYPE b) { return _ENUMTYPE(((int)a) ^ ((int)b)); } \ + inline _ENUMTYPE &operator^=(_ENUMTYPE &a, _ENUMTYPE b) { return (_ENUMTYPE &)(((int &)a) ^= ((int)b)); } \ +} +#else +#define DEFINE_ENUM_FLAG_OPERATORS(_ENUMTYPE) +#endif + +#define COMPILETIME_OR_2FLAGS(a,b) ((UINT)(a)|(UINT)(b)) +#define COMPILETIME_OR_3FLAGS(a,b,c) ((UINT)(a)|(UINT)(b)|(UINT)(c)) +#define COMPILETIME_OR_4FLAGS(a,b,c,d) ((UINT)(a)|(UINT)(b)|(UINT)(c)|(UINT)(d)) +#define COMPILETIME_OR_5FLAGS(a,b,c,d,e) ((UINT)(a)|(UINT)(b)|(UINT)(c)|(UINT)(d)|(UINT)(e)) + /* Type Limits */ #define MINCHAR 0x80 #define MAXCHAR 0x7f diff --git a/include/xdk/ntdef.template.h b/include/xdk/ntdef.template.h index fc1df37a19e..36d24b6b6a5 100644 --- a/include/xdk/ntdef.template.h +++ b/include/xdk/ntdef.template.h @@ -117,9 +117,23 @@ $define(USHORT=USHORT) $define(UCHAR=UCHAR) $include(ntbasedef.h) +typedef _Return_type_success_(return >= 0) LONG NTSTATUS; +typedef NTSTATUS *PNTSTATUS; + +#ifndef __SECSTATUS_DEFINED__ +typedef long SECURITY_STATUS; +#define __SECSTATUS_DEFINED__ +#endif + /* Physical Addresses are always treated as 64-bit wide */ typedef LARGE_INTEGER PHYSICAL_ADDRESS, *PPHYSICAL_ADDRESS; +#define TIME LARGE_INTEGER +#define _TIME _LARGE_INTEGER +#define PTIME PLARGE_INTEGER +#define LowTime LowPart +#define HighTime HighPart + /* Used to store a non-float 8 byte aligned structure */ typedef struct _QUAD { @@ -130,6 +144,17 @@ typedef struct _QUAD } DUMMYUNIONNAME; } QUAD, *PQUAD, UQUAD, *PUQUAD; +#if (_WIN32_WINNT >= 0x0600) || (defined(__cplusplus) && defined(WINDOWS_ENABLE_CPLUSPLUS)) +typedef CONST UCHAR *PCUCHAR; +typedef CONST USHORT *PCUSHORT; +typedef CONST ULONG *PCULONG; +typedef CONST UQUAD *PCUQUAD; +typedef CONST SCHAR *PCSCHAR; +#endif /* (/_WIN32_WINNT >= 0x0600) */ +#if (_WIN32_WINNT >= 0x0600) +typedef CONST NTSTATUS *PCNTSTATUS; +#endif /* (/_WIN32_WINNT >= 0x0600) */ + /* String Types */ typedef struct _STRING { USHORT Length; @@ -244,6 +269,8 @@ typedef struct _OBJECT_ATTRIBUTES64 { } OBJECT_ATTRIBUTES64, *POBJECT_ATTRIBUTES64; typedef CONST OBJECT_ATTRIBUTES64 *PCOBJECT_ATTRIBUTES64; +#define OBJ_HANDLE_TAGBITS 0x00000003L + /* Values for the Attributes member */ #define OBJ_INHERIT 0x00000002L #define OBJ_PERMANENT 0x00000010L @@ -277,6 +304,37 @@ typedef CONST OBJECT_ATTRIBUTES64 *PCOBJECT_ATTRIBUTES64; #define RTL_INIT_OBJECT_ATTRIBUTES(n, a) \ RTL_CONSTANT_OBJECT_ATTRIBUTES(n, a) +#ifdef _MSC_VER + #pragma warning(push) + #pragma warning(disable:4214) /* Bit fields of other types than int */ +#endif /* _MSC_VER */ +typedef struct _RTL_BALANCED_NODE +{ + _ANONYMOUS_UNION union + { + struct _RTL_BALANCED_NODE *Children[2]; + _ANONYMOUS_STRUCT struct + { + struct _RTL_BALANCED_NODE *Left; + struct _RTL_BALANCED_NODE *Right; + } DUMMYSTRUCTNAME; + } DUMMYUNIONNAME; + _ANONYMOUS_UNION union + { + UCHAR Red : 1; + UCHAR Balance : 2; + ULONG_PTR ParentValue; + } DUMMYUNIONNAME2; +} RTL_BALANCED_NODE, *PRTL_BALANCED_NODE; +#ifdef _MSC_VER + #pragma warning(pop) +#endif /* _MSC_VER */ + +#define RTL_BALANCED_NODE_RESERVED_PARENT_MASK 3 +#define RTL_BALANCED_NODE_GET_PARENT_POINTER(Node) \ + ((PRTL_BALANCED_NODE)((Node)->ParentValue & \ + ~RTL_BALANCED_NODE_RESERVED_PARENT_MASK)) + /* Product Types */ typedef enum _NT_PRODUCT_TYPE { NtProductWinNt = 1, @@ -299,6 +357,28 @@ typedef enum _WAIT_TYPE { WaitAny } WAIT_TYPE; +#ifndef MIDL_PASS +FORCEINLINE +VOID +ListEntry32To64( + _In_ PLIST_ENTRY32 ListEntry32, + _Out_ PLIST_ENTRY64 ListEntry64) +{ + ListEntry64->Flink = (ULONG)ListEntry32->Flink; + ListEntry64->Blink = (ULONG)ListEntry32->Blink; +} + +FORCEINLINE +VOID +ListEntry64To32( + _In_ PLIST_ENTRY64 ListEntry64, + _Out_ PLIST_ENTRY32 ListEntry32) +{ + ListEntry32->Flink = ListEntry64->Flink & 0xFFFFFFFF; + ListEntry32->Blink = ListEntry64->Blink & 0xFFFFFFFF; +} +#endif /* !MIDL_PASS */ + #ifdef __cplusplus } // extern "C" #endif diff --git a/include/xdk/winnt_old.h b/include/xdk/winnt_old.h index a8221d44d35..b108fab9030 100644 --- a/include/xdk/winnt_old.h +++ b/include/xdk/winnt_old.h @@ -93,21 +93,6 @@ #define ACE_OBJECT_TYPE_PRESENT 0x00000001 #define ACE_INHERITED_OBJECT_TYPE_PRESENT 0x00000002 -#ifdef __cplusplus -#define DEFINE_ENUM_FLAG_OPERATORS(ENUMTYPE) \ -extern "C++" { \ - inline ENUMTYPE operator | (ENUMTYPE a, ENUMTYPE b) { return ENUMTYPE(((int)a)|((int)b)); } \ - inline ENUMTYPE operator |= (ENUMTYPE &a, ENUMTYPE b) { return (ENUMTYPE &)(((int &)a) |= ((int)b)); } \ - inline ENUMTYPE operator & (ENUMTYPE a, ENUMTYPE b) { return ENUMTYPE(((int)a)&((int)b)); } \ - inline ENUMTYPE operator &= (ENUMTYPE &a, ENUMTYPE b) { return (ENUMTYPE &)(((int &)a) &= ((int)b)); } \ - inline ENUMTYPE operator ~ (ENUMTYPE a) { return (ENUMTYPE)(~((int)a)); } \ - inline ENUMTYPE operator ^ (ENUMTYPE a, ENUMTYPE b) { return ENUMTYPE(((int)a)^((int)b)); } \ - inline ENUMTYPE operator ^= (ENUMTYPE &a, ENUMTYPE b) { return (ENUMTYPE &)(((int &)a) ^= ((int)b)); } \ -} -#else -# define DEFINE_ENUM_FLAG_OPERATORS(ENUMTYPE) /* */ -#endif - /* also in ddk/ntifs.h */ #define COMPRESSION_FORMAT_NONE (0x0000) #define COMPRESSION_FORMAT_DEFAULT (0x0001) diff --git a/lib/fast486/opcodes.c b/lib/fast486/opcodes.c index 9f153fa2d31..dd3a0ccf3d6 100644 --- a/lib/fast486/opcodes.c +++ b/lib/fast486/opcodes.c @@ -5469,7 +5469,7 @@ FAST486_OPCODE_HANDLER(Fast486OpcodeMovs) Segment = State->SegmentOverride; } - if (State->PrefixFlags & FAST486_PREFIX_REP) + if (State->PrefixFlags & (FAST486_PREFIX_REP | FAST486_PREFIX_REPNZ)) { if ((AddressSize && (State->GeneralRegs[FAST486_REG_ECX].Long == 0)) || (!AddressSize && (State->GeneralRegs[FAST486_REG_ECX].LowWord == 0))) @@ -5537,7 +5537,7 @@ FAST486_OPCODE_HANDLER(Fast486OpcodeMovs) } // FIXME: This method is slow! - if (State->PrefixFlags & FAST486_PREFIX_REP) + if (State->PrefixFlags & (FAST486_PREFIX_REP | FAST486_PREFIX_REPNZ)) { if (AddressSize) { @@ -5727,7 +5727,7 @@ FAST486_OPCODE_HANDLER(Fast486OpcodeStos) if (Opcode == 0xAA) DataSize = sizeof(UCHAR); else DataSize = OperandSize ? sizeof(ULONG) : sizeof(USHORT); - if (State->PrefixFlags & FAST486_PREFIX_REP) + if (State->PrefixFlags & (FAST486_PREFIX_REP | FAST486_PREFIX_REPNZ)) { UCHAR Block[STRING_BLOCK_SIZE]; ULONG Count = AddressSize ? State->GeneralRegs[FAST486_REG_ECX].Long @@ -5870,7 +5870,7 @@ FAST486_OPCODE_HANDLER(Fast486OpcodeLods) if (Opcode == 0xAC) DataSize = sizeof(UCHAR); else DataSize = OperandSize ? sizeof(ULONG) : sizeof(USHORT); - if (State->PrefixFlags & FAST486_PREFIX_REP) + if (State->PrefixFlags & (FAST486_PREFIX_REP | FAST486_PREFIX_REPNZ)) { ULONG Count = AddressSize ? State->GeneralRegs[FAST486_REG_ECX].Long : State->GeneralRegs[FAST486_REG_ECX].LowWord; @@ -6056,7 +6056,7 @@ FAST486_OPCODE_HANDLER(Fast486OpcodeIns) if (Opcode == 0x6C) DataSize = sizeof(UCHAR); else DataSize = OperandSize ? sizeof(ULONG) : sizeof(USHORT); - if (State->PrefixFlags & FAST486_PREFIX_REP) + if (State->PrefixFlags & (FAST486_PREFIX_REP | FAST486_PREFIX_REPNZ)) { UCHAR Block[STRING_BLOCK_SIZE]; ULONG Count = AddressSize ? State->GeneralRegs[FAST486_REG_ECX].Long @@ -6197,7 +6197,7 @@ FAST486_OPCODE_HANDLER(Fast486OpcodeOuts) if (Opcode == 0x6E) DataSize = sizeof(UCHAR); else DataSize = OperandSize ? sizeof(ULONG) : sizeof(USHORT); - if (State->PrefixFlags & FAST486_PREFIX_REP) + if (State->PrefixFlags & (FAST486_PREFIX_REP | FAST486_PREFIX_REPNZ)) { UCHAR Block[STRING_BLOCK_SIZE]; ULONG Count = AddressSize ? State->GeneralRegs[FAST486_REG_ECX].Long diff --git a/lib/sdk/dxguid/CMakeLists.txt b/lib/sdk/dxguid/CMakeLists.txt index 22cb45ea753..4211c0f0198 100644 --- a/lib/sdk/dxguid/CMakeLists.txt +++ b/lib/sdk/dxguid/CMakeLists.txt @@ -3,4 +3,4 @@ add_library(dxguid dxguid-mingw.c) add_library(dx10guid dx10guid.c) add_dependencies(dxguid psdk) -add_dependencies(dx10guid psdk) +add_dependencies(dx10guid psdk d3d_idl_headers) diff --git a/media/doc/README.WINE b/media/doc/README.WINE index 0eb34450c99..d860bc11f5a 100644 --- a/media/doc/README.WINE +++ b/media/doc/README.WINE @@ -111,38 +111,38 @@ reactos/dll/win32/mlang # Synced to Wine-1.7.17 reactos/dll/win32/mmdevapi # Synced to Wine-1.7.27 reactos/dll/win32/mpr # Synced to Wine-1.7.27 reactos/dll/win32/mprapi # Synced to Wine-1.7.17 -reactos/dll/win32/msacm32 # Synced to Wine-1.7.17 +reactos/dll/win32/msacm32 # Synced to Wine-1.7.27 reactos/dll/win32/msacm32/msacm32.drv # Synced to Wine-1.7.17 reactos/dll/win32/msadp32.acm # Synced to Wine-1.7.17 reactos/dll/win32/mscat32 # Synced to Wine-1.7.17 -reactos/dll/win32/mscms # Synced to Wine-1.7.17 +reactos/dll/win32/mscms # Synced to Wine-1.7.27 reactos/dll/win32/mscoree # Synced to Wine-1.5.4 -reactos/dll/win32/msctf # Synced to Wine-1.7.17 +reactos/dll/win32/msctf # Synced to Wine-1.7.27 reactos/dll/win32/msftedit # Synced to Wine-1.7.17 reactos/dll/win32/msg711.acm # Synced to Wine-1.7.17 reactos/dll/win32/msgsm32.acm # Synced to Wine-1.7.17 -reactos/dll/win32/mshtml # Synced to Wine-1.7.17 +reactos/dll/win32/mshtml # Synced to Wine-1.7.27 reactos/dll/win32/mshtml.tlb # Synced to Wine-1.7.17 reactos/dll/win32/msi # Synced to Wine-1.7.27 -reactos/dll/win32/msimg32 # Synced to Wine-1.7.17 +reactos/dll/win32/msimg32 # Synced to Wine-1.7.27 reactos/dll/win32/msimtf # Synced to Wine-1.7.17 -reactos/dll/win32/msisip # Synced to Wine-1.7.17 +reactos/dll/win32/msisip # Synced to Wine-1.7.27 reactos/dll/win32/msisys.ocx # Synced to Wine-1.7.17 reactos/dll/win32/msnet32 # Synced to Wine-1.7.17 reactos/dll/win32/mspatcha # Synced to Wine-1.7.27 -reactos/dll/win32/msrle32 # Synced to Wine-1.7.17 +reactos/dll/win32/msrle32 # Synced to Wine-1.7.27 reactos/dll/win32/mssign32 # Synced to Wine-1.7.17 reactos/dll/win32/mssip32 # Synced to Wine-1.7.17 reactos/dll/win32/mstask # Synced to Wine-1.7.17 reactos/dll/win32/msvcrt20 # Out of sync reactos/dll/win32/msvcrt40 # Out of sync -reactos/dll/win32/msvfw32 # Synced to Wine-1.7.17 +reactos/dll/win32/msvfw32 # Synced to Wine-1.7.27 reactos/dll/win32/msvidc32 # Synced to Wine-1.7.17 -reactos/dll/win32/msxml # Synced to Wine-1.7.17 -reactos/dll/win32/msxml2 # Synced to Wine-1.7.17 -reactos/dll/win32/msxml3 # Synced to Wine-1.7.17 -reactos/dll/win32/msxml4 # Synced to Wine-1.7.17 -reactos/dll/win32/msxml6 # Synced to Wine-1.7.17 +reactos/dll/win32/msxml # Synced to Wine-1.7.27 +reactos/dll/win32/msxml2 # Synced to Wine-1.7.27 +reactos/dll/win32/msxml3 # Synced to Wine-1.7.27 +reactos/dll/win32/msxml4 # Synced to Wine-1.7.27 +reactos/dll/win32/msxml6 # Synced to Wine-1.7.27 reactos/dll/win32/nddeapi # Synced to Wine-1.7.17 reactos/dll/win32/netapi32 # Forked at Wine-1.3.34 reactos/dll/win32/ntdsapi # Synced to Wine-1.7.17 @@ -150,9 +150,9 @@ reactos/dll/win32/ntprint # Synced to Wine-1.7.17 reactos/dll/win32/objsel # Synced to Wine-1.7.17 reactos/dll/win32/odbc32 # Synced to Wine-1.7.17. Depends on port of Linux ODBC. reactos/dll/win32/odbccp32 # Synced to Wine-1.7.17 -reactos/dll/win32/ole32 # Synced to Wine-1.7.17 -reactos/dll/win32/oleacc # Synced to Wine-1.7.17 -reactos/dll/win32/oleaut32 # Synced to Wine-1.7.17 +reactos/dll/win32/ole32 # Synced to Wine-1.7.27 +reactos/dll/win32/oleacc # Synced to Wine-1.7.27 +reactos/dll/win32/oleaut32 # Synced to Wine-1.7.27 reactos/dll/win32/olecli32 # Synced to Wine-1.7.17 reactos/dll/win32/oledlg # Synced to Wine-1.7.17 reactos/dll/win32/olepro32 # Synced to Wine-1.7.17 @@ -185,7 +185,7 @@ reactos/dll/win32/shdoclc # Synced to Wine-1.7.17 reactos/dll/win32/shdocvw # Synced to Wine-1.7.17 reactos/dll/win32/shell32 # Forked at Wine-20071011 reactos/dll/win32/shfolder # Synced to Wine-1.7.17 -reactos/dll/win32/shlwapi # Synced to Wine-1.7.17 +reactos/dll/win32/shlwapi # Synced to Wine-1.7.27 reactos/dll/win32/slbcsp # Synced to Wine-1.7.17 reactos/dll/win32/snmpapi # Synced to Wine-1.7.17 reactos/dll/win32/softpub # Synced to Wine-1.7.17 diff --git a/ntoskrnl/config/cmapi.c b/ntoskrnl/config/cmapi.c index e3b18049ff5..dd140824663 100644 --- a/ntoskrnl/config/cmapi.c +++ b/ntoskrnl/config/cmapi.c @@ -1556,12 +1556,13 @@ CmpQueryNameInformation( /* Do the real copy */ KeyNameInfo->NameLength = 0; CurrentKcb = Kcb; - while (CurrentKcb) - { - ULONG NameLength; - _SEH2_TRY + _SEH2_TRY + { + while (CurrentKcb) { + ULONG NameLength; + if (CurrentKcb->NameBlock->Compressed) { NameLength = CmpCompressedNameSize(CurrentKcb->NameBlock->Name, CurrentKcb->NameBlock->NameLength); @@ -1585,15 +1586,15 @@ CmpQueryNameInformation( /* Add path separator */ KeyNameInfo->Name[NeededLength/sizeof(WCHAR)] = OBJ_NAME_PATH_SEPARATOR; KeyNameInfo->NameLength += NameLength + sizeof(OBJ_NAME_PATH_SEPARATOR); - } - _SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER) - { - return _SEH2_GetExceptionCode(); - } - _SEH2_END; - CurrentKcb = CurrentKcb->ParentKcb; + CurrentKcb = CurrentKcb->ParentKcb; + } } + _SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER) + { + return _SEH2_GetExceptionCode(); + } + _SEH2_END; /* Make sure we copied everything */ ASSERT(NeededLength == 0); diff --git a/subsystems/ntvdm/CMakeLists.txt b/subsystems/ntvdm/CMakeLists.txt index 92b03b43a82..2793b0b5415 100644 --- a/subsystems/ntvdm/CMakeLists.txt +++ b/subsystems/ntvdm/CMakeLists.txt @@ -14,6 +14,9 @@ list(APPEND SOURCE bios/kbdbios.c bios/rom.c bios/vidbios.c + cpu/bop.c + cpu/callback.c + cpu/cpu.c hardware/cmos.c hardware/keyboard.c hardware/mouse.c @@ -27,10 +30,9 @@ list(APPEND SOURCE dos/dos32krnl/dosfiles.c dos/mouse32.c dos/dem.c - bop.c - callback.c clock.c emulator.c + int32.c io.c registers.c utils.c diff --git a/subsystems/ntvdm/bios/bios.c b/subsystems/ntvdm/bios/bios.c index accd3f1cc5e..ad04e48fbb2 100644 --- a/subsystems/ntvdm/bios/bios.c +++ b/subsystems/ntvdm/bios/bios.c @@ -11,8 +11,8 @@ #define NDEBUG #include "emulator.h" -#include "callback.h" -#include "bop.h" +#include "cpu/callback.h" +#include "cpu/bop.h" #include "bios.h" #include "bios32/bios32.h" diff --git a/subsystems/ntvdm/bios/bios32/bios32.c b/subsystems/ntvdm/bios/bios32/bios32.c index f6138d92792..46d139f5f36 100644 --- a/subsystems/ntvdm/bios/bios32/bios32.c +++ b/subsystems/ntvdm/bios/bios32/bios32.c @@ -14,8 +14,9 @@ #include #include "emulator.h" -#include "callback.h" -#include "bop.h" +#include "cpu/cpu.h" // for EMULATOR_FLAG_CF +#include "int32.h" +// #include "bop.h" #include "../bios.h" #include "../rom.h" diff --git a/subsystems/ntvdm/bios/bios32/bios32p.h b/subsystems/ntvdm/bios/bios32/bios32p.h index 3ffd39d4c28..060f0f71d76 100644 --- a/subsystems/ntvdm/bios/bios32/bios32p.h +++ b/subsystems/ntvdm/bios/bios32/bios32p.h @@ -14,7 +14,7 @@ #include "ntvdm.h" #include "../bios.h" -/**/ #include "callback.h" /**/ +/**/ #include "int32.h" /**/ /* DEFINES ********************************************************************/ diff --git a/subsystems/ntvdm/bios/bios32/kbdbios32.c b/subsystems/ntvdm/bios/bios32/kbdbios32.c index 0782f3e719f..db9ba5aa59d 100644 --- a/subsystems/ntvdm/bios/bios32/kbdbios32.c +++ b/subsystems/ntvdm/bios/bios32/kbdbios32.c @@ -11,7 +11,8 @@ #define NDEBUG #include "emulator.h" -#include "callback.h" +#include "cpu/cpu.h" // for EMULATOR_FLAG_ZF +#include "int32.h" #include "kbdbios32.h" #include "../kbdbios.h" @@ -205,7 +206,8 @@ static VOID WINAPI BiosKeyboardIrq(LPWORD Stack) * In return, if CF is set we continue processing the scan code * stored in AL, and if not, we skip it. */ - BYTE CF, AX; + BYTE CF; + WORD AX; CF = getCF(); AX = getAX(); diff --git a/subsystems/ntvdm/bios/bios32/moubios32.c b/subsystems/ntvdm/bios/bios32/moubios32.c index 720182cd70c..235709ed539 100644 --- a/subsystems/ntvdm/bios/bios32/moubios32.c +++ b/subsystems/ntvdm/bios/bios32/moubios32.c @@ -11,7 +11,6 @@ #define NDEBUG #include "emulator.h" -#include "callback.h" #include "moubios32.h" #include "bios32p.h" diff --git a/subsystems/ntvdm/bios/bios32/vidbios32.c b/subsystems/ntvdm/bios/bios32/vidbios32.c index 732776c2db6..97783815f3a 100644 --- a/subsystems/ntvdm/bios/bios32/vidbios32.c +++ b/subsystems/ntvdm/bios/bios32/vidbios32.c @@ -13,7 +13,7 @@ #define NDEBUG #include "emulator.h" -#include "callback.h" +#include "int32.h" #include "vidbios32.h" #include "../vidbios.h" diff --git a/subsystems/ntvdm/bios/kbdbios.c b/subsystems/ntvdm/bios/kbdbios.c index 72550869f9d..007d2566100 100644 --- a/subsystems/ntvdm/bios/kbdbios.c +++ b/subsystems/ntvdm/bios/kbdbios.c @@ -11,8 +11,7 @@ #define NDEBUG #include "emulator.h" -#include "callback.h" -#include "bop.h" +#include "cpu/bop.h" #include "bios.h" // #include "kbdbios.h" diff --git a/subsystems/ntvdm/bios/rom.c b/subsystems/ntvdm/bios/rom.c index e4dbc6bf5f6..52864c1efbd 100644 --- a/subsystems/ntvdm/bios/rom.c +++ b/subsystems/ntvdm/bios/rom.c @@ -11,7 +11,7 @@ #define NDEBUG #include "emulator.h" -#include "callback.h" +#include "cpu/callback.h" #include "utils.h" #include "rom.h" diff --git a/subsystems/ntvdm/bios/vidbios.c b/subsystems/ntvdm/bios/vidbios.c index 444e7e1a8a5..c6cfc0d3904 100644 --- a/subsystems/ntvdm/bios/vidbios.c +++ b/subsystems/ntvdm/bios/vidbios.c @@ -12,8 +12,8 @@ #define NDEBUG #include "emulator.h" -#include "callback.h" -#include "bop.h" +#include "cpu/cpu.h" +#include "cpu/bop.h" #include "bios.h" // #include "vidbios.h" @@ -651,6 +651,782 @@ static CONST COLORREF VgaPalette[VGA_MAX_COLORS] = #endif +static CONST UCHAR Font8x8[VGA_FONT_CHARACTERS * 8] = +{ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x7E, 0x81, 0xA5, 0x81, 0xBD, 0x99, 0x81, 0x7E, + 0x7E, 0xFF, 0xDB, 0xFF, 0xC3, 0xE7, 0xFF, 0x7E, + 0x6C, 0xFE, 0xFE, 0xFE, 0x7C, 0x38, 0x10, 0x00, + 0x10, 0x38, 0x7C, 0xFE, 0x7C, 0x38, 0x10, 0x00, + 0x38, 0x7C, 0x38, 0xFE, 0xFE, 0x92, 0x10, 0x7C, + 0x00, 0x10, 0x38, 0x7C, 0xFE, 0x7C, 0x38, 0x7C, + 0x00, 0x00, 0x18, 0x3C, 0x3C, 0x18, 0x00, 0x00, + 0xFF, 0xFF, 0xE7, 0xC3, 0xC3, 0xE7, 0xFF, 0xFF, + 0x00, 0x3C, 0x66, 0x42, 0x42, 0x66, 0x3C, 0x00, + 0xFF, 0xC3, 0x99, 0xBD, 0xBD, 0x99, 0xC3, 0xFF, + 0x0F, 0x07, 0x0F, 0x7D, 0xCC, 0xCC, 0xCC, 0x78, + 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x18, 0x7E, 0x18, + 0x3F, 0x33, 0x3F, 0x30, 0x30, 0x70, 0xF0, 0xE0, + 0x7F, 0x63, 0x7F, 0x63, 0x63, 0x67, 0xE6, 0xC0, + 0x99, 0x5A, 0x3C, 0xE7, 0xE7, 0x3C, 0x5A, 0x99, + 0x80, 0xE0, 0xF8, 0xFE, 0xF8, 0xE0, 0x80, 0x00, + 0x02, 0x0E, 0x3E, 0xFE, 0x3E, 0x0E, 0x02, 0x00, + 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x7E, 0x3C, 0x18, + 0x66, 0x66, 0x66, 0x66, 0x66, 0x00, 0x66, 0x00, + 0x7F, 0xDB, 0xDB, 0x7B, 0x1B, 0x1B, 0x1B, 0x00, + 0x3E, 0x63, 0x38, 0x6C, 0x6C, 0x38, 0x86, 0xFC, + 0x00, 0x00, 0x00, 0x00, 0x7E, 0x7E, 0x7E, 0x00, + 0x18, 0x3C, 0x7E, 0x18, 0x7E, 0x3C, 0x18, 0xFF, + 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, 0x18, 0x00, + 0x18, 0x18, 0x18, 0x18, 0x7E, 0x3C, 0x18, 0x00, + 0x00, 0x18, 0x0C, 0xFE, 0x0C, 0x18, 0x00, 0x00, + 0x00, 0x30, 0x60, 0xFE, 0x60, 0x30, 0x00, 0x00, + 0x00, 0x00, 0xC0, 0xC0, 0xC0, 0xFE, 0x00, 0x00, + 0x00, 0x24, 0x66, 0xFF, 0x66, 0x24, 0x00, 0x00, + 0x00, 0x18, 0x3C, 0x7E, 0xFF, 0xFF, 0x00, 0x00, + 0x00, 0xFF, 0xFF, 0x7E, 0x3C, 0x18, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0x3C, 0x3C, 0x18, 0x18, 0x00, 0x18, 0x00, + 0x6C, 0x6C, 0x6C, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x6C, 0x6C, 0xFE, 0x6C, 0xFE, 0x6C, 0x6C, 0x00, + 0x18, 0x7E, 0xC0, 0x7C, 0x06, 0xFC, 0x18, 0x00, + 0x00, 0xC6, 0xCC, 0x18, 0x30, 0x66, 0xC6, 0x00, + 0x38, 0x6C, 0x38, 0x76, 0xDC, 0xCC, 0x76, 0x00, + 0x30, 0x30, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0x30, 0x60, 0x60, 0x60, 0x30, 0x18, 0x00, + 0x60, 0x30, 0x18, 0x18, 0x18, 0x30, 0x60, 0x00, + 0x00, 0x66, 0x3C, 0xFF, 0x3C, 0x66, 0x00, 0x00, + 0x00, 0x18, 0x18, 0x7E, 0x18, 0x18, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x30, + 0x00, 0x00, 0x00, 0x7E, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, + 0x06, 0x0C, 0x18, 0x30, 0x60, 0xC0, 0x80, 0x00, + 0x7C, 0xCE, 0xDE, 0xF6, 0xE6, 0xC6, 0x7C, 0x00, + 0x30, 0x70, 0x30, 0x30, 0x30, 0x30, 0xFC, 0x00, + 0x78, 0xCC, 0x0C, 0x38, 0x60, 0xCC, 0xFC, 0x00, + 0x78, 0xCC, 0x0C, 0x38, 0x0C, 0xCC, 0x78, 0x00, + 0x1C, 0x3C, 0x6C, 0xCC, 0xFE, 0x0C, 0x1E, 0x00, + 0xFC, 0xC0, 0xF8, 0x0C, 0x0C, 0xCC, 0x78, 0x00, + 0x38, 0x60, 0xC0, 0xF8, 0xCC, 0xCC, 0x78, 0x00, + 0xFC, 0xCC, 0x0C, 0x18, 0x30, 0x30, 0x30, 0x00, + 0x78, 0xCC, 0xCC, 0x78, 0xCC, 0xCC, 0x78, 0x00, + 0x78, 0xCC, 0xCC, 0x7C, 0x0C, 0x18, 0x70, 0x00, + 0x00, 0x18, 0x18, 0x00, 0x00, 0x18, 0x18, 0x00, + 0x00, 0x18, 0x18, 0x00, 0x00, 0x18, 0x18, 0x30, + 0x18, 0x30, 0x60, 0xC0, 0x60, 0x30, 0x18, 0x00, + 0x00, 0x00, 0x7E, 0x00, 0x7E, 0x00, 0x00, 0x00, + 0x60, 0x30, 0x18, 0x0C, 0x18, 0x30, 0x60, 0x00, + 0x3C, 0x66, 0x0C, 0x18, 0x18, 0x00, 0x18, 0x00, + 0x7C, 0xC6, 0xDE, 0xDE, 0xDC, 0xC0, 0x7C, 0x00, + 0x30, 0x78, 0xCC, 0xCC, 0xFC, 0xCC, 0xCC, 0x00, + 0xFC, 0x66, 0x66, 0x7C, 0x66, 0x66, 0xFC, 0x00, + 0x3C, 0x66, 0xC0, 0xC0, 0xC0, 0x66, 0x3C, 0x00, + 0xF8, 0x6C, 0x66, 0x66, 0x66, 0x6C, 0xF8, 0x00, + 0xFE, 0x62, 0x68, 0x78, 0x68, 0x62, 0xFE, 0x00, + 0xFE, 0x62, 0x68, 0x78, 0x68, 0x60, 0xF0, 0x00, + 0x3C, 0x66, 0xC0, 0xC0, 0xCE, 0x66, 0x3A, 0x00, + 0xCC, 0xCC, 0xCC, 0xFC, 0xCC, 0xCC, 0xCC, 0x00, + 0x78, 0x30, 0x30, 0x30, 0x30, 0x30, 0x78, 0x00, + 0x1E, 0x0C, 0x0C, 0x0C, 0xCC, 0xCC, 0x78, 0x00, + 0xE6, 0x66, 0x6C, 0x78, 0x6C, 0x66, 0xE6, 0x00, + 0xF0, 0x60, 0x60, 0x60, 0x62, 0x66, 0xFE, 0x00, + 0xC6, 0xEE, 0xFE, 0xFE, 0xD6, 0xC6, 0xC6, 0x00, + 0xC6, 0xE6, 0xF6, 0xDE, 0xCE, 0xC6, 0xC6, 0x00, + 0x38, 0x6C, 0xC6, 0xC6, 0xC6, 0x6C, 0x38, 0x00, + 0xFC, 0x66, 0x66, 0x7C, 0x60, 0x60, 0xF0, 0x00, + 0x7C, 0xC6, 0xC6, 0xC6, 0xD6, 0x7C, 0x0E, 0x00, + 0xFC, 0x66, 0x66, 0x7C, 0x6C, 0x66, 0xE6, 0x00, + 0x7C, 0xC6, 0xE0, 0x78, 0x0E, 0xC6, 0x7C, 0x00, + 0xFC, 0xB4, 0x30, 0x30, 0x30, 0x30, 0x78, 0x00, + 0xCC, 0xCC, 0xCC, 0xCC, 0xCC, 0xCC, 0xFC, 0x00, + 0xCC, 0xCC, 0xCC, 0xCC, 0xCC, 0x78, 0x30, 0x00, + 0xC6, 0xC6, 0xC6, 0xC6, 0xD6, 0xFE, 0x6C, 0x00, + 0xC6, 0xC6, 0x6C, 0x38, 0x6C, 0xC6, 0xC6, 0x00, + 0xCC, 0xCC, 0xCC, 0x78, 0x30, 0x30, 0x78, 0x00, + 0xFE, 0xC6, 0x8C, 0x18, 0x32, 0x66, 0xFE, 0x00, + 0x78, 0x60, 0x60, 0x60, 0x60, 0x60, 0x78, 0x00, + 0xC0, 0x60, 0x30, 0x18, 0x0C, 0x06, 0x02, 0x00, + 0x78, 0x18, 0x18, 0x18, 0x18, 0x18, 0x78, 0x00, + 0x10, 0x38, 0x6C, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, + 0x30, 0x30, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x00, + 0xE0, 0x60, 0x60, 0x7C, 0x66, 0x66, 0xDC, 0x00, + 0x00, 0x00, 0x78, 0xCC, 0xC0, 0xCC, 0x78, 0x00, + 0x1C, 0x0C, 0x0C, 0x7C, 0xCC, 0xCC, 0x76, 0x00, + 0x00, 0x00, 0x78, 0xCC, 0xFC, 0xC0, 0x78, 0x00, + 0x38, 0x6C, 0x64, 0xF0, 0x60, 0x60, 0xF0, 0x00, + 0x00, 0x00, 0x76, 0xCC, 0xCC, 0x7C, 0x0C, 0xF8, + 0xE0, 0x60, 0x6C, 0x76, 0x66, 0x66, 0xE6, 0x00, + 0x30, 0x00, 0x70, 0x30, 0x30, 0x30, 0x78, 0x00, + 0x0C, 0x00, 0x1C, 0x0C, 0x0C, 0xCC, 0xCC, 0x78, + 0xE0, 0x60, 0x66, 0x6C, 0x78, 0x6C, 0xE6, 0x00, + 0x70, 0x30, 0x30, 0x30, 0x30, 0x30, 0x78, 0x00, + 0x00, 0x00, 0xCC, 0xFE, 0xFE, 0xD6, 0xD6, 0x00, + 0x00, 0x00, 0xB8, 0xCC, 0xCC, 0xCC, 0xCC, 0x00, + 0x00, 0x00, 0x78, 0xCC, 0xCC, 0xCC, 0x78, 0x00, + 0x00, 0x00, 0xDC, 0x66, 0x66, 0x7C, 0x60, 0xF0, + 0x00, 0x00, 0x76, 0xCC, 0xCC, 0x7C, 0x0C, 0x1E, + 0x00, 0x00, 0xDC, 0x76, 0x62, 0x60, 0xF0, 0x00, + 0x00, 0x00, 0x7C, 0xC0, 0x70, 0x1C, 0xF8, 0x00, + 0x10, 0x30, 0xFC, 0x30, 0x30, 0x34, 0x18, 0x00, + 0x00, 0x00, 0xCC, 0xCC, 0xCC, 0xCC, 0x76, 0x00, + 0x00, 0x00, 0xCC, 0xCC, 0xCC, 0x78, 0x30, 0x00, + 0x00, 0x00, 0xC6, 0xC6, 0xD6, 0xFE, 0x6C, 0x00, + 0x00, 0x00, 0xC6, 0x6C, 0x38, 0x6C, 0xC6, 0x00, + 0x00, 0x00, 0xCC, 0xCC, 0xCC, 0x7C, 0x0C, 0xF8, + 0x00, 0x00, 0xFC, 0x98, 0x30, 0x64, 0xFC, 0x00, + 0x1C, 0x30, 0x30, 0xE0, 0x30, 0x30, 0x1C, 0x00, + 0x18, 0x18, 0x18, 0x00, 0x18, 0x18, 0x18, 0x00, + 0xE0, 0x30, 0x30, 0x1C, 0x30, 0x30, 0xE0, 0x00, + 0x76, 0xDC, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x10, 0x38, 0x6C, 0xC6, 0xC6, 0xFE, 0x00, + 0x7C, 0xC6, 0xC0, 0xC6, 0x7C, 0x0C, 0x06, 0x7C, + 0x00, 0xCC, 0x00, 0xCC, 0xCC, 0xCC, 0x76, 0x00, + 0x1C, 0x00, 0x78, 0xCC, 0xFC, 0xC0, 0x78, 0x00, + 0x7E, 0x81, 0x3C, 0x06, 0x3E, 0x66, 0x3B, 0x00, + 0xCC, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x00, + 0xE0, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x00, + 0x30, 0x30, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC0, 0x78, 0x0C, 0x38, + 0x7E, 0x81, 0x3C, 0x66, 0x7E, 0x60, 0x3C, 0x00, + 0xCC, 0x00, 0x78, 0xCC, 0xFC, 0xC0, 0x78, 0x00, + 0xE0, 0x00, 0x78, 0xCC, 0xFC, 0xC0, 0x78, 0x00, + 0xCC, 0x00, 0x70, 0x30, 0x30, 0x30, 0x78, 0x00, + 0x7C, 0x82, 0x38, 0x18, 0x18, 0x18, 0x3C, 0x00, + 0xE0, 0x00, 0x70, 0x30, 0x30, 0x30, 0x78, 0x00, + 0xC6, 0x10, 0x7C, 0xC6, 0xFE, 0xC6, 0xC6, 0x00, + 0x30, 0x30, 0x00, 0x78, 0xCC, 0xFC, 0xCC, 0x00, + 0x1C, 0x00, 0xFC, 0x60, 0x78, 0x60, 0xFC, 0x00, + 0x00, 0x00, 0x7F, 0x0C, 0x7F, 0xCC, 0x7F, 0x00, + 0x3E, 0x6C, 0xCC, 0xFE, 0xCC, 0xCC, 0xCE, 0x00, + 0x78, 0x84, 0x00, 0x78, 0xCC, 0xCC, 0x78, 0x00, + 0x00, 0xCC, 0x00, 0x78, 0xCC, 0xCC, 0x78, 0x00, + 0x00, 0xE0, 0x00, 0x78, 0xCC, 0xCC, 0x78, 0x00, + 0x78, 0x84, 0x00, 0xCC, 0xCC, 0xCC, 0x76, 0x00, + 0x00, 0xE0, 0x00, 0xCC, 0xCC, 0xCC, 0x76, 0x00, + 0x00, 0xCC, 0x00, 0xCC, 0xCC, 0x7C, 0x0C, 0xF8, + 0xC3, 0x18, 0x3C, 0x66, 0x66, 0x3C, 0x18, 0x00, + 0xCC, 0x00, 0xCC, 0xCC, 0xCC, 0xCC, 0x78, 0x00, + 0x18, 0x18, 0x7E, 0xC0, 0xC0, 0x7E, 0x18, 0x18, + 0x38, 0x6C, 0x64, 0xF0, 0x60, 0xE6, 0xFC, 0x00, + 0xCC, 0xCC, 0x78, 0x30, 0xFC, 0x30, 0xFC, 0x30, + 0xF8, 0xCC, 0xCC, 0xFA, 0xC6, 0xCF, 0xC6, 0xC3, + 0x0E, 0x1B, 0x18, 0x3C, 0x18, 0x18, 0xD8, 0x70, + 0x1C, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x00, + 0x38, 0x00, 0x70, 0x30, 0x30, 0x30, 0x78, 0x00, + 0x00, 0x1C, 0x00, 0x78, 0xCC, 0xCC, 0x78, 0x00, + 0x00, 0x1C, 0x00, 0xCC, 0xCC, 0xCC, 0x76, 0x00, + 0x00, 0xF8, 0x00, 0xB8, 0xCC, 0xCC, 0xCC, 0x00, + 0xFC, 0x00, 0xCC, 0xEC, 0xFC, 0xDC, 0xCC, 0x00, + 0x3C, 0x6C, 0x6C, 0x3E, 0x00, 0x7E, 0x00, 0x00, + 0x38, 0x6C, 0x6C, 0x38, 0x00, 0x7C, 0x00, 0x00, + 0x18, 0x00, 0x18, 0x18, 0x30, 0x66, 0x3C, 0x00, + 0x00, 0x00, 0x00, 0xFC, 0xC0, 0xC0, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xFC, 0x0C, 0x0C, 0x00, 0x00, + 0xC6, 0xCC, 0xD8, 0x36, 0x6B, 0xC2, 0x84, 0x0F, + 0xC3, 0xC6, 0xCC, 0xDB, 0x37, 0x6D, 0xCF, 0x03, + 0x18, 0x00, 0x18, 0x18, 0x3C, 0x3C, 0x18, 0x00, + 0x00, 0x33, 0x66, 0xCC, 0x66, 0x33, 0x00, 0x00, + 0x00, 0xCC, 0x66, 0x33, 0x66, 0xCC, 0x00, 0x00, + 0x22, 0x88, 0x22, 0x88, 0x22, 0x88, 0x22, 0x88, + 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, + 0xDB, 0xF6, 0xDB, 0x6F, 0xDB, 0x7E, 0xD7, 0xED, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0xF8, 0x18, 0x18, 0x18, + 0x18, 0x18, 0xF8, 0x18, 0xF8, 0x18, 0x18, 0x18, + 0x36, 0x36, 0x36, 0x36, 0xF6, 0x36, 0x36, 0x36, + 0x00, 0x00, 0x00, 0x00, 0xFE, 0x36, 0x36, 0x36, + 0x00, 0x00, 0xF8, 0x18, 0xF8, 0x18, 0x18, 0x18, + 0x36, 0x36, 0xF6, 0x06, 0xF6, 0x36, 0x36, 0x36, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x00, 0x00, 0xFE, 0x06, 0xF6, 0x36, 0x36, 0x36, + 0x36, 0x36, 0xF6, 0x06, 0xFE, 0x00, 0x00, 0x00, + 0x36, 0x36, 0x36, 0x36, 0xFE, 0x00, 0x00, 0x00, + 0x18, 0x18, 0xF8, 0x18, 0xF8, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xF8, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x1F, 0x00, 0x00, 0x00, + 0x18, 0x18, 0x18, 0x18, 0xFF, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xFF, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x1F, 0x18, 0x18, 0x18, + 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x00, + 0x18, 0x18, 0x18, 0x18, 0xFF, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x1F, 0x18, 0x1F, 0x18, 0x18, 0x18, + 0x36, 0x36, 0x36, 0x36, 0x37, 0x36, 0x36, 0x36, + 0x36, 0x36, 0x37, 0x30, 0x3F, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3F, 0x30, 0x37, 0x36, 0x36, 0x36, + 0x36, 0x36, 0xF7, 0x00, 0xFF, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFF, 0x00, 0xF7, 0x36, 0x36, 0x36, + 0x36, 0x36, 0x37, 0x30, 0x37, 0x36, 0x36, 0x36, + 0x00, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0x00, 0x00, + 0x36, 0x36, 0xF7, 0x00, 0xF7, 0x36, 0x36, 0x36, + 0x18, 0x18, 0xFF, 0x00, 0xFF, 0x00, 0x00, 0x00, + 0x36, 0x36, 0x36, 0x36, 0xFF, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFF, 0x00, 0xFF, 0x18, 0x18, 0x18, + 0x00, 0x00, 0x00, 0x00, 0xFF, 0x36, 0x36, 0x36, + 0x36, 0x36, 0x36, 0x36, 0x3F, 0x00, 0x00, 0x00, + 0x18, 0x18, 0x1F, 0x18, 0x1F, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x1F, 0x18, 0x1F, 0x18, 0x18, 0x18, + 0x00, 0x00, 0x00, 0x00, 0x3F, 0x36, 0x36, 0x36, + 0x36, 0x36, 0x36, 0x36, 0xFF, 0x36, 0x36, 0x36, + 0x18, 0x18, 0xFF, 0x18, 0xFF, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0xF8, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x1F, 0x18, 0x18, 0x18, + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, + 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, + 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, + 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x76, 0xDC, 0xC8, 0xDC, 0x76, 0x00, + 0x00, 0x78, 0xCC, 0xF8, 0xCC, 0xF8, 0xC0, 0xC0, + 0x00, 0xFC, 0xCC, 0xC0, 0xC0, 0xC0, 0xC0, 0x00, + 0x00, 0x00, 0xFE, 0x6C, 0x6C, 0x6C, 0x6C, 0x00, + 0xFC, 0xCC, 0x60, 0x30, 0x60, 0xCC, 0xFC, 0x00, + 0x00, 0x00, 0x7E, 0xD8, 0xD8, 0xD8, 0x70, 0x00, + 0x00, 0x66, 0x66, 0x66, 0x66, 0x7C, 0x60, 0xC0, + 0x00, 0x76, 0xDC, 0x18, 0x18, 0x18, 0x18, 0x00, + 0xFC, 0x30, 0x78, 0xCC, 0xCC, 0x78, 0x30, 0xFC, + 0x38, 0x6C, 0xC6, 0xFE, 0xC6, 0x6C, 0x38, 0x00, + 0x38, 0x6C, 0xC6, 0xC6, 0x6C, 0x6C, 0xEE, 0x00, + 0x1C, 0x30, 0x18, 0x7C, 0xCC, 0xCC, 0x78, 0x00, + 0x00, 0x00, 0x7E, 0xDB, 0xDB, 0x7E, 0x00, 0x00, + 0x06, 0x0C, 0x7E, 0xDB, 0xDB, 0x7E, 0x60, 0xC0, + 0x38, 0x60, 0xC0, 0xF8, 0xC0, 0x60, 0x38, 0x00, + 0x78, 0xCC, 0xCC, 0xCC, 0xCC, 0xCC, 0xCC, 0x00, + 0x00, 0x7E, 0x00, 0x7E, 0x00, 0x7E, 0x00, 0x00, + 0x18, 0x18, 0x7E, 0x18, 0x18, 0x00, 0x7E, 0x00, + 0x60, 0x30, 0x18, 0x30, 0x60, 0x00, 0xFC, 0x00, + 0x18, 0x30, 0x60, 0x30, 0x18, 0x00, 0xFC, 0x00, + 0x0E, 0x1B, 0x1B, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x18, 0xD8, 0xD8, 0x70, + 0x18, 0x18, 0x00, 0x7E, 0x00, 0x18, 0x18, 0x00, + 0x00, 0x76, 0xDC, 0x00, 0x76, 0xDC, 0x00, 0x00, + 0x38, 0x6C, 0x6C, 0x38, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x0F, 0x0C, 0x0C, 0x0C, 0xEC, 0x6C, 0x3C, 0x1C, + 0x58, 0x6C, 0x6C, 0x6C, 0x6C, 0x00, 0x00, 0x00, + 0x70, 0x98, 0x30, 0x60, 0xF8, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3C, 0x3C, 0x3C, 0x3C, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 +}; + +static CONST UCHAR Font8x16[VGA_FONT_CHARACTERS * 16] = +{ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7E, 0x81, 0xA5, 0x81, 0x81, 0xBD, + 0x99, 0x81, 0x81, 0x7E, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xFE, 0xFE, 0xD6, 0xFE, 0xFE, + 0xBA, 0xC6, 0xFE, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x6C, 0xEE, 0xFE, 0xFE, 0xFE, + 0xFE, 0x7C, 0x38, 0x10, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x10, 0x38, 0x7C, 0xFE, 0x7C, + 0x38, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x10, 0x38, 0x38, 0x10, 0x6C, + 0xEE, 0x6C, 0x10, 0x38, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x10, 0x38, 0x7C, 0x7C, 0xFE, 0xFE, + 0xFE, 0x6C, 0x10, 0x38, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x3C, 0x3C, + 0x3C, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE7, 0xC3, 0xC3, + 0xC3, 0xE7, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0x00, 0x00, 0x00, 0x00, 0x18, 0x3C, 0x66, 0x66, + 0x66, 0x3C, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xFF, 0xFF, 0xFF, 0xFF, 0xE7, 0xC3, 0x99, 0x99, + 0x99, 0xC3, 0xE7, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0x00, 0x00, 0x1E, 0x0E, 0x1E, 0x36, 0x78, 0xCC, + 0xCC, 0xCC, 0xCC, 0x78, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x18, + 0x7E, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x1E, 0x1A, 0x1E, 0x18, 0x18, 0x18, + 0x18, 0x78, 0xF8, 0x70, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3E, 0x36, 0x3E, 0x36, 0x36, 0x76, + 0xF6, 0x66, 0x0E, 0x1E, 0x0C, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0xDB, 0x7E, 0x3C, 0x66, 0x66, + 0x3C, 0x7E, 0xDB, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x80, 0xE0, 0xF0, 0xFC, 0xFE, + 0xFC, 0xF0, 0xE0, 0x80, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x02, 0x0E, 0x3E, 0x7E, 0xFE, + 0x7E, 0x3E, 0x0E, 0x02, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, + 0x18, 0x7E, 0x3C, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, + 0x66, 0x00, 0x66, 0x66, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7F, 0xDB, 0xDB, 0xDB, 0xDB, 0x7B, + 0x1B, 0x1B, 0x1B, 0x1B, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC6, 0x60, 0x7C, 0xF6, + 0xDE, 0x7C, 0x0C, 0xC6, 0xC6, 0x7C, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xFE, 0xFE, 0xFE, 0xFE, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, + 0x7E, 0x3C, 0x18, 0x7E, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x7E, 0x3C, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x0E, 0xFF, + 0x0E, 0x0C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x70, 0xFE, + 0x70, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC0, 0xC0, + 0xC0, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x24, 0x66, 0xFF, + 0x66, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x10, 0x38, 0x38, 0x38, 0x7C, + 0x7C, 0xFE, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xFE, 0xFE, 0x7C, 0x7C, 0x7C, + 0x38, 0x38, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x3C, 0x3C, 0x3C, 0x3C, 0x18, + 0x18, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x36, 0x36, 0x36, 0x36, 0x14, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x6C, 0x6C, 0x6C, 0xFE, 0x6C, 0x6C, + 0xFE, 0x6C, 0x6C, 0x6C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x18, 0x7C, 0xC6, 0xC0, 0x78, + 0x3C, 0x06, 0xC6, 0x7C, 0x18, 0x18, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x62, 0x66, 0x0C, + 0x18, 0x30, 0x66, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x38, 0x6C, 0x38, 0x30, 0x76, 0x7E, + 0xCC, 0xCC, 0xCC, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0C, 0x0C, 0x0C, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x0C, 0x18, 0x30, 0x30, 0x30, 0x30, + 0x30, 0x30, 0x18, 0x0C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x30, 0x18, 0x0C, 0x0C, 0x0C, 0x0C, + 0x0C, 0x0C, 0x18, 0x30, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x6C, 0x38, 0xFE, + 0x38, 0x6C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x7E, + 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0C, 0x0C, 0x0C, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x02, 0x06, 0x0C, 0x18, + 0x30, 0x60, 0xC0, 0x80, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC6, 0xCE, 0xDE, 0xF6, + 0xE6, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x78, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x7E, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC6, 0x06, 0x0C, 0x18, + 0x30, 0x60, 0xC6, 0xFE, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0x06, 0x06, 0x3C, 0x06, + 0x06, 0x06, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x0C, 0x1C, 0x3C, 0x6C, 0xCC, 0xCC, + 0xFE, 0x0C, 0x0C, 0x1E, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFE, 0xC0, 0xC0, 0xC0, 0xFC, 0x06, + 0x06, 0x06, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC0, 0xC0, 0xFC, 0xC6, + 0xC6, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFE, 0xC6, 0x06, 0x0C, 0x18, 0x30, + 0x30, 0x30, 0x30, 0x30, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC6, 0xC6, 0x7C, 0xC6, + 0xC6, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC6, 0xC6, 0xC6, 0x7E, + 0x06, 0x06, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x0C, 0x00, + 0x00, 0x0C, 0x0C, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x0C, 0x00, + 0x00, 0x0C, 0x0C, 0x0C, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x0C, 0x18, 0x30, 0x60, 0xC0, + 0x60, 0x30, 0x18, 0x0C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, 0x00, + 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x60, 0x30, 0x18, 0x0C, 0x06, + 0x0C, 0x18, 0x30, 0x60, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC6, 0x0C, 0x18, 0x18, + 0x18, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC6, 0xC6, 0xDE, 0xDE, + 0xDE, 0xDC, 0xC0, 0x7E, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x38, 0x6C, 0xC6, 0xC6, 0xC6, 0xFE, + 0xC6, 0xC6, 0xC6, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFC, 0x66, 0x66, 0x66, 0x7C, 0x66, + 0x66, 0x66, 0x66, 0xFC, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3C, 0x66, 0xC2, 0xC0, 0xC0, 0xC0, + 0xC0, 0xC2, 0x66, 0x3C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xF8, 0x6C, 0x66, 0x66, 0x66, 0x66, + 0x66, 0x66, 0x6C, 0xF8, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFE, 0x66, 0x60, 0x64, 0x7C, 0x64, + 0x60, 0x60, 0x66, 0xFE, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFE, 0x66, 0x60, 0x64, 0x7C, 0x64, + 0x60, 0x60, 0x60, 0xF0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC6, 0xC0, 0xC0, 0xC0, + 0xCE, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xC6, 0xC6, 0xC6, 0xC6, 0xFE, 0xC6, + 0xC6, 0xC6, 0xC6, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3C, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3C, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0xD8, 0xD8, 0x70, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xC6, 0xC6, 0xCC, 0xD8, 0xF0, 0xF0, + 0xD8, 0xCC, 0xC6, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xF0, 0x60, 0x60, 0x60, 0x60, 0x60, + 0x60, 0x62, 0x66, 0xFE, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xC6, 0xC6, 0xEE, 0xEE, 0xFE, 0xD6, + 0xD6, 0xD6, 0xC6, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xC6, 0xC6, 0xE6, 0xE6, 0xF6, 0xDE, + 0xCE, 0xCE, 0xC6, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC6, 0xC6, 0xC6, 0xC6, + 0xC6, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFC, 0x66, 0x66, 0x66, 0x66, 0x7C, + 0x60, 0x60, 0x60, 0xF0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC6, 0xC6, 0xC6, 0xC6, + 0xC6, 0xD6, 0xD6, 0x7C, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFC, 0x66, 0x66, 0x66, 0x7C, 0x78, + 0x6C, 0x66, 0x66, 0xE6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC0, 0xC0, 0x70, 0x1C, + 0x06, 0x06, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7E, 0x5A, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xC6, 0xC6, 0xC6, 0xC6, 0xC6, 0xC6, + 0xC6, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xC6, 0xC6, 0xC6, 0xC6, 0xC6, 0xC6, + 0xC6, 0x6C, 0x38, 0x10, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xC6, 0xC6, 0xC6, 0xD6, 0xD6, 0xD6, + 0xFE, 0xEE, 0xC6, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xC6, 0xC6, 0xC6, 0x6C, 0x38, 0x38, + 0x6C, 0xC6, 0xC6, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3C, + 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFE, 0xC6, 0x86, 0x0C, 0x18, 0x30, + 0x60, 0xC2, 0xC6, 0xFE, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0x60, 0x60, 0x60, 0x60, 0x60, + 0x60, 0x60, 0x60, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0xC0, 0x60, 0x30, + 0x18, 0x0C, 0x06, 0x02, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, + 0x0C, 0x0C, 0x0C, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x10, 0x38, 0x6C, 0xC6, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0x00, + 0x00, 0x18, 0x18, 0x18, 0x0C, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x0C, 0x7C, + 0xCC, 0xCC, 0xDC, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xE0, 0x60, 0x60, 0x7C, 0x66, 0x66, + 0x66, 0x66, 0x66, 0xFC, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x7C, 0xC6, 0xC0, + 0xC0, 0xC0, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x1C, 0x0C, 0x0C, 0x7C, 0xCC, 0xCC, + 0xCC, 0xCC, 0xCC, 0x7E, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x7C, 0xC6, 0xC6, + 0xFE, 0xC0, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x1C, 0x36, 0x30, 0x30, 0xFC, 0x30, + 0x30, 0x30, 0x30, 0x78, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x76, 0xCE, 0xC6, + 0xC6, 0xCE, 0x76, 0x06, 0xC6, 0x7C, 0x00, 0x00, + 0x00, 0x00, 0xE0, 0x60, 0x60, 0x7C, 0x66, 0x66, + 0x66, 0x66, 0x66, 0xE6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x18, 0x00, 0x38, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x0C, 0x0C, 0x00, 0x1C, 0x0C, 0x0C, + 0x0C, 0x0C, 0x0C, 0xCC, 0xCC, 0x78, 0x00, 0x00, + 0x00, 0x00, 0xE0, 0x60, 0x60, 0x66, 0x66, 0x6C, + 0x78, 0x6C, 0x66, 0xE6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x1C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x6C, 0xFE, 0xD6, + 0xD6, 0xC6, 0xC6, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xDC, 0x66, 0x66, + 0x66, 0x66, 0x66, 0x66, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x7C, 0xC6, 0xC6, + 0xC6, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xDC, 0x66, 0x66, + 0x66, 0x66, 0x7C, 0x60, 0x60, 0xF0, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x76, 0xCC, 0xCC, + 0xCC, 0xCC, 0x7C, 0x0C, 0x0C, 0x1E, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xDC, 0x66, 0x60, + 0x60, 0x60, 0x60, 0xF0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x7C, 0xC6, 0xC0, + 0x7C, 0x06, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x30, 0x30, 0x30, 0xFC, 0x30, 0x30, + 0x30, 0x30, 0x36, 0x1C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xCC, 0xCC, 0xCC, + 0xCC, 0xCC, 0xCC, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xC6, 0xC6, 0xC6, + 0xC6, 0x6C, 0x38, 0x10, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xC6, 0xC6, 0xD6, + 0xD6, 0xD6, 0xFE, 0x6C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xC6, 0xC6, 0x6C, + 0x38, 0x6C, 0xC6, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xC6, 0xC6, 0xC6, + 0xC6, 0xCE, 0x76, 0x06, 0xC6, 0x7C, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, 0x86, 0x0C, + 0x18, 0x30, 0x62, 0xFE, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x0E, 0x18, 0x18, 0x18, 0x70, 0x18, + 0x18, 0x18, 0x18, 0x0E, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x00, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x70, 0x18, 0x18, 0x18, 0x0E, 0x18, + 0x18, 0x18, 0x18, 0x70, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x76, 0xDC, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x38, 0x38, + 0x6C, 0x6C, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3C, 0x66, 0xC0, 0xC0, 0xC0, 0xC6, + 0x66, 0x3C, 0x18, 0x0C, 0xCC, 0x38, 0x00, 0x00, + 0x00, 0x00, 0xC6, 0x00, 0x00, 0xC6, 0xC6, 0xC6, + 0xC6, 0xC6, 0xCE, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0C, 0x18, 0x30, 0x00, 0x7C, 0xC6, 0xC6, + 0xFE, 0xC0, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x30, 0x78, 0xCC, 0x00, 0x78, 0x0C, 0x7C, + 0xCC, 0xCC, 0xDC, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xCC, 0x00, 0x00, 0x78, 0x0C, 0x7C, + 0xCC, 0xCC, 0xDC, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x30, 0x18, 0x00, 0x78, 0x0C, 0x7C, + 0xCC, 0xCC, 0xDC, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x38, 0x6C, 0x38, 0x00, 0x78, 0x0C, 0x7C, + 0xCC, 0xCC, 0xDC, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x7C, 0xC6, 0xC0, 0xC0, + 0xC6, 0x7C, 0x18, 0x0C, 0x6C, 0x38, 0x00, 0x00, + 0x00, 0x30, 0x78, 0xCC, 0x00, 0x7C, 0xC6, 0xC6, + 0xFE, 0xC0, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xCC, 0x00, 0x00, 0x7C, 0xC6, 0xC6, + 0xFE, 0xC0, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x30, 0x18, 0x0C, 0x00, 0x7C, 0xC6, 0xC6, + 0xFE, 0xC0, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x66, 0x00, 0x00, 0x38, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x18, 0x3C, 0x66, 0x00, 0x38, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xC6, 0x00, 0x38, 0x6C, 0xC6, 0xC6, 0xC6, + 0xFE, 0xC6, 0xC6, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x38, 0x6C, 0x38, 0x00, 0x38, 0x6C, 0xC6, 0xC6, + 0xFE, 0xC6, 0xC6, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x0C, 0x18, 0x30, 0x00, 0xFE, 0x60, 0x60, 0x7C, + 0x60, 0x60, 0x60, 0xFE, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x66, 0xDB, 0x1B, 0x7F, + 0xD8, 0xD8, 0xDF, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7E, 0xD8, 0xD8, 0xD8, 0xD8, 0xFE, + 0xD8, 0xD8, 0xD8, 0xDE, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x30, 0x78, 0xCC, 0x00, 0x7C, 0xC6, 0xC6, + 0xC6, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xC6, 0x00, 0x00, 0x7C, 0xC6, 0xC6, + 0xC6, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x30, 0x18, 0x0C, 0x00, 0x7C, 0xC6, 0xC6, + 0xC6, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x30, 0x78, 0xCC, 0x00, 0xC6, 0xC6, 0xC6, + 0xC6, 0xC6, 0xCE, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x30, 0x18, 0x00, 0xC6, 0xC6, 0xC6, + 0xC6, 0xC6, 0xCE, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x18, 0x00, 0x3C, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xC6, 0x00, 0x7C, 0xC6, 0xC6, 0xC6, 0xC6, + 0xC6, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xC6, 0x00, 0xC6, 0xC6, 0xC6, 0xC6, 0xC6, + 0xC6, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x18, 0x7C, 0xC6, 0xC0, 0xC0, + 0xC6, 0x7C, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x38, 0x6C, 0x60, 0x60, 0xF0, 0x60, 0x60, + 0x60, 0x66, 0xF6, 0x6C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x18, 0x7E, + 0x18, 0x3C, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3E, 0x63, 0x63, 0x30, 0x1C, 0x06, + 0x63, 0x63, 0x3E, 0x00, 0x1C, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x3E, 0x63, 0x38, + 0x0E, 0x63, 0x3E, 0x00, 0x1C, 0x00, 0x00, 0x00, + 0x00, 0x0C, 0x18, 0x30, 0x00, 0x78, 0x0C, 0x7C, + 0xCC, 0xCC, 0xDC, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0C, 0x18, 0x30, 0x00, 0x38, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0C, 0x18, 0x30, 0x00, 0x7C, 0xC6, 0xC6, + 0xC6, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x18, 0x30, 0x60, 0x00, 0xCC, 0xCC, 0xCC, + 0xCC, 0xCC, 0xDC, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x76, 0xDC, 0x00, 0xBC, 0x66, 0x66, + 0x66, 0x66, 0x66, 0xE6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x76, 0xDC, 0x00, 0xC6, 0xC6, 0xE6, 0xF6, + 0xDE, 0xCE, 0xC6, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x21, 0x1E, 0x00, 0x1E, 0x33, 0x60, 0x60, + 0x67, 0x63, 0x33, 0x1D, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x42, 0x3C, 0x00, 0x3B, 0x66, 0x66, 0x66, + 0x3E, 0x06, 0x66, 0x3C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x30, 0x30, 0x00, 0x30, 0x30, 0x30, + 0x60, 0xC6, 0xC6, 0x7C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7E, + 0x60, 0x60, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7E, + 0x06, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x60, 0x62, 0x66, 0x6C, 0x18, 0x30, + 0x60, 0xDC, 0x36, 0x0C, 0x18, 0x3E, 0x00, 0x00, + 0x00, 0x60, 0x60, 0x62, 0x66, 0x6C, 0x18, 0x36, + 0x6E, 0xDE, 0x36, 0x7E, 0x06, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x18, 0x00, 0x18, 0x18, 0x3C, + 0x3C, 0x3C, 0x3C, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x36, 0x6C, 0xD8, + 0x6C, 0x36, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xD8, 0x6C, 0x36, + 0x6C, 0xD8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, + 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, + 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, + 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, + 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, + 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xF8, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x18, 0xF8, 0x18, 0xF8, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xF6, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x18, 0xF8, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x36, 0x36, 0x36, 0x36, 0x36, 0xF6, 0x06, 0xF6, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, 0x06, 0xF6, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x36, 0x36, 0x36, 0x36, 0x36, 0xF6, 0x06, 0xFE, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xFE, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0x18, 0x18, 0x18, 0x18, 0xF8, 0x18, 0xF8, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x1F, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xFF, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x1F, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xFF, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x1F, 0x18, 0x1F, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x37, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x37, 0x30, 0x3F, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x30, 0x37, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x36, 0x36, 0x36, 0x36, 0x36, 0xF7, 0x00, 0xFF, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xF7, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x37, 0x30, 0x37, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xFF, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x36, 0x36, 0x36, 0x36, 0x36, 0xF7, 0x00, 0xF7, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x18, 0x18, 0x18, 0x18, 0x18, 0xFF, 0x00, 0xFF, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xFF, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xFF, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x3F, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x1F, 0x18, 0x1F, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x1F, 0x18, 0x1F, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3F, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xFF, + 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, + 0x18, 0x18, 0x18, 0x18, 0x18, 0xFF, 0x18, 0xFF, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xF8, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1F, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, + 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, + 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, + 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x76, 0xDC, 0xD8, 0xD8, + 0xD8, 0xD8, 0xDC, 0x76, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x78, 0xCC, 0xCC, 0xD8, 0xFC, 0xC6, + 0xC6, 0xC6, 0xC6, 0xCC, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFE, 0x66, 0x62, 0x60, 0x60, 0x60, + 0x60, 0x60, 0x60, 0x60, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, 0x6C, 0x6C, + 0x6C, 0x6C, 0x6C, 0x6C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFE, 0xC6, 0x62, 0x30, 0x18, 0x18, + 0x30, 0x62, 0xC6, 0xFE, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x7E, 0xD8, 0xCC, + 0xCC, 0xCC, 0xD8, 0x70, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x66, 0x66, 0x66, 0x66, + 0x66, 0x7C, 0x60, 0xC0, 0x80, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x76, 0xDC, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xFE, 0x38, 0x38, 0x6C, 0xC6, 0xC6, + 0x6C, 0x38, 0x38, 0xFE, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x38, 0x6C, 0xC6, 0xC6, 0xFE, + 0xC6, 0xC6, 0x6C, 0x38, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x38, 0x6C, 0xC6, 0xC6, 0xC6, 0xC6, + 0x6C, 0x6C, 0x6C, 0xEE, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3E, 0x60, 0x60, 0x3C, 0x66, 0xC6, + 0xC6, 0xC6, 0xCC, 0x78, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x7E, 0xDB, 0xDB, + 0xDB, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x02, 0x06, 0x7C, 0xCE, 0xDE, 0xF6, + 0xF6, 0x7C, 0x60, 0xC0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x1C, 0x30, 0x60, 0x60, 0x7C, + 0x60, 0x60, 0x30, 0x1C, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7C, 0xC6, 0xC6, 0xC6, 0xC6, 0xC6, + 0xC6, 0xC6, 0xC6, 0xC6, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xFE, 0x00, 0x00, 0xFE, + 0x00, 0x00, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x7E, 0x18, + 0x18, 0x00, 0x00, 0x7E, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x30, 0x18, 0x0C, 0x06, 0x0C, 0x18, + 0x30, 0x00, 0x00, 0x7E, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x0C, 0x18, 0x30, 0x60, 0x30, 0x18, + 0x0C, 0x00, 0x00, 0x7E, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0C, 0x1E, 0x1A, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, + 0x18, 0x18, 0x58, 0x78, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x7E, + 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x76, 0xDC, + 0x00, 0x76, 0xDC, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x78, 0xCC, 0xCC, 0x78, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x1F, 0x18, 0x18, 0x18, 0x18, 0x18, + 0xD8, 0xD8, 0x78, 0x38, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xD8, 0x6C, 0x6C, 0x6C, 0x6C, 0x6C, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x70, 0xD8, 0x18, 0x30, 0x60, 0xF8, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x7E, 0x7E, 0x7E, + 0x7E, 0x7E, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +}; + /* PRIVATE FUNCTIONS **********************************************************/ static VOID VidBiosReadWindow(LPWORD Buffer, SMALL_RECT Rectangle, BYTE Page) @@ -1003,11 +1779,23 @@ BYTE VidBiosGetVideoMode(VOID) static BOOLEAN VidBiosSetVideoMode(BYTE ModeNumber) { BYTE Page; - COORD Resolution; - PVGA_REGISTERS VgaMode = VideoModes[ModeNumber]; + BOOLEAN DoNotClear = !!(ModeNumber & 0x80); + PVGA_REGISTERS VgaMode; - DPRINT1("Switching to mode %Xh; VgaMode = 0x%p\n", ModeNumber, VgaMode); + /* Retrieve the real mode number and check its validity */ + ModeNumber &= 0x7F; + // if (ModeNumber >= sizeof(VideoModes)/sizeof(VideoModes[0])) + if (ModeNumber > BIOS_MAX_VIDEO_MODE) + { + DPRINT1("VidBiosSetVideoMode -- Mode %02Xh invalid\n", ModeNumber); + return FALSE; + } + + VgaMode = VideoModes[ModeNumber]; + + DPRINT1("Switching to mode %02Xh %s clearing the screen; VgaMode = 0x%p\n", + ModeNumber, (DoNotClear ? "without" : "and"), VgaMode); if (!VgaSetRegisters(VgaMode)) return FALSE; @@ -1019,8 +1807,7 @@ static BOOLEAN VidBiosSetVideoMode(BYTE ModeNumber) * See Ralf Brown: http://www.ctyme.com/intr/rb-0069.htm * for more information. */ - // if ((ModeNumber & 0x08) == 0) VgaClearMemory(); - VgaClearMemory(); + if (!DoNotClear) VgaClearMemory(); // Bda->CrtModeControl; // Bda->CrtColorPaletteMask; @@ -1339,7 +2126,7 @@ VOID WINAPI VidBiosVideoService(LPWORD Stack) if (Bda->VideoMode < 4 || Bda->VideoMode > 6) { DPRINT1("BIOS Function INT 10h, AH = 0Bh, BH = 0x%02X is unsupported for non-CGA modes\n", - getAH(), getBH()); + getBH()); break; } @@ -1620,6 +2407,42 @@ VOID WINAPI VidBiosVideoService(LPWORD Stack) break; } + /* Font Control */ + case 0x11: + { + switch (getAL()) + { + case 0x30: + { + USHORT Offsets[] = + { + FONT_8x8_HIGH_OFFSET, /* 00h - INT 0x1F pointer */ + 0, /* 01h - NOT IMPLEMENTED - INT 0x43 pointer */ + 0, /* 02h - NOT IMPLEMENTED - 8x14 font */ + FONT_8x8_OFFSET, /* 03h - 8x8 font */ + FONT_8x8_HIGH_OFFSET, /* 04h - 8x8 font, upper half */ + 0, /* 05h - NOT IMPLEMENTED - 9x14 font */ + FONT_8x16_OFFSET, /* 06h - 8x16 font */ + 0, /* 07h - NOT IMPLEMENTED - 9x16 font */ + }; + + /* Return the data */ + setES(VIDEO_BIOS_DATA_SEG); + setBP(Offsets[getBH() & 7]); + + break; + } + + default: + { + DPRINT1("BIOS Font Control Sub-command AL = 0x%02X NOT IMPLEMENTED\n", + getAL()); + } + } + + break; + } + /* Alternate Function Select */ case 0x12: { @@ -1691,16 +2514,26 @@ VOID VidBiosDetachFromConsole(VOID) Attached = FALSE; } - BOOLEAN VidBiosInitialize(VOID) { /* Some interrupts are in fact addresses to tables */ ((PULONG)BaseAddress)[0x1D] = (ULONG)NULL; - ((PULONG)BaseAddress)[0x1F] = (ULONG)NULL; + ((PULONG)BaseAddress)[0x1F] = MAKELONG(FONT_8x8_HIGH_OFFSET, VIDEO_BIOS_DATA_SEG); // ((PULONG)BaseAddress)[0x42] = (ULONG)NULL; ((PULONG)BaseAddress)[0x43] = (ULONG)NULL; ((PULONG)BaseAddress)[0x44] = (ULONG)NULL; + /* Fill the tables */ + RtlMoveMemory(SEG_OFF_TO_PTR(VIDEO_BIOS_DATA_SEG, FONT_8x8_OFFSET), + Font8x8, + sizeof(Font8x8)); + RtlMoveMemory(SEG_OFF_TO_PTR(VIDEO_BIOS_DATA_SEG, FONT_8x16_OFFSET), + Font8x16, + sizeof(Font8x16)); + + /* Write the default font to the VGA font plane */ + VgaWriteFont(0, Font8x16, 16); + /* Initialize the VGA BDA data */ Bda->VGAOptions = 0x30; /* 256 KB Video RAM */ Bda->VGASwitches = 0x09; /* High-resolution */ diff --git a/subsystems/ntvdm/bios/vidbios.h b/subsystems/ntvdm/bios/vidbios.h index 5e291471115..a0f50e5e028 100644 --- a/subsystems/ntvdm/bios/vidbios.h +++ b/subsystems/ntvdm/bios/vidbios.h @@ -26,6 +26,11 @@ #define GRAPHICS_VIDEO_SEG 0xA000 #define TEXT_VIDEO_SEG 0xB800 +#define VIDEO_BIOS_DATA_SEG 0xC000 + +#define FONT_8x8_OFFSET 0x0000 +#define FONT_8x8_HIGH_OFFSET 0x0400 +#define FONT_8x16_OFFSET 0x0800 enum { diff --git a/subsystems/ntvdm/callback.c b/subsystems/ntvdm/callback.c deleted file mode 100644 index 47bacbb3314..00000000000 --- a/subsystems/ntvdm/callback.c +++ /dev/null @@ -1,310 +0,0 @@ -/* - * COPYRIGHT: GPL - See COPYING in the top level directory - * PROJECT: ReactOS Virtual DOS Machine - * FILE: callback.c - * PURPOSE: 16 and 32-bit Callbacks Support - * PROGRAMMERS: Aleksandar Andrejevic - * Hermes Belusca-Maito (hermes.belusca@sfr.fr) - */ - -/******************************************************************************\ -| WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! -| -| Callbacks support supposes implicitely that the callbacks are used -| in the SAME thread as the CPU thread, otherwise messing in parallel -| with the CPU registers is 100% prone to bugs!! -\******************************************************************************/ - -/* INCLUDES *******************************************************************/ - -#define NDEBUG - -#include "emulator.h" -#include "callback.h" - -#include "bop.h" -#include - -/* PRIVATE VARIABLES **********************************************************/ - -/* - * This is the list of registered 32-bit Interrupt handlers. - */ -static EMULATOR_INT32_PROC Int32Proc[EMULATOR_MAX_INT32_NUM] = { NULL }; - -/* BOP Identifiers */ -#define BOP_CONTROL 0xFF // Control BOP Handler - #define BOP_CONTROL_DEFFUNC 0x00 // Default Control BOP Function - #define BOP_CONTROL_INT32 0xFF // 32-bit Interrupt dispatcher - // function code for the Control BOP Handler - -#define BOP(num) LOBYTE(EMULATOR_BOP), HIBYTE(EMULATOR_BOP), (num) -#define UnSimulate16(trap) \ -do { \ - *(PUSHORT)(trap) = EMULATOR_BOP; \ - (trap) += sizeof(USHORT); \ - *(trap) = BOP_UNSIMULATE; \ -} while(0) -// #define UnSimulate16 MAKELONG(EMULATOR_BOP, BOP_UNSIMULATE) // BOP(BOP_UNSIMULATE) - -#define CALL16_TRAMPOLINE_SIZE (1 * sizeof(ULONGLONG)) -#define INT16_TRAMPOLINE_SIZE (1 * sizeof(ULONGLONG)) - -// -// WARNING WARNING!! -// -// If you modify the code stubs here, think also -// about updating them in int32.c too!! -// - -/* 16-bit generic interrupt code for calling a 32-bit interrupt handler */ -static BYTE Int16To32[] = -{ - 0xFA, // cli - - /* Push the value of the interrupt to be called */ - 0x6A, 0xFF, // push i (patchable to 0x6A, 0xIntNum) - - /* The BOP Sequence */ -// BOP_SEQ: - 0xF8, // clc - BOP(BOP_CONTROL), // Control BOP - BOP_CONTROL_INT32, // 32-bit Interrupt dispatcher - - 0x73, 0x04, // jnc EXIT (offset +4) - - 0xFB, // sti - - // HACK: The following instruction should be HLT! - 0x90, // nop - - 0xEB, 0xF5, // jmp BOP_SEQ (offset -11) - -// EXIT: - 0x44, 0x44, // inc sp, inc sp - 0xCF, // iret -}; -const ULONG Int16To32StubSize = sizeof(Int16To32); - -/* PUBLIC FUNCTIONS ***********************************************************/ - -VOID -InitializeContext(IN PCALLBACK16 Context, - IN USHORT Segment, - IN USHORT Offset) -{ - Context->TrampolineFarPtr = MAKELONG(Offset, Segment); - Context->TrampolineSize = max(CALL16_TRAMPOLINE_SIZE, - INT16_TRAMPOLINE_SIZE); - Context->Segment = Segment; - Context->NextOffset = Offset + Context->TrampolineSize; -} - -VOID -Call16(IN USHORT Segment, - IN USHORT Offset) -{ - /* Save CS:IP */ - USHORT OrgCS = getCS(); - USHORT OrgIP = getIP(); - - /* Set the new CS:IP */ - setCS(Segment); - setIP(Offset); - - DPRINT("Call16(%04X:%04X)\n", Segment, Offset); - - /* Start CPU simulation */ - EmulatorSimulate(); - - /* Restore CS:IP */ - setCS(OrgCS); - setIP(OrgIP); -} - - - -ULONG -RegisterCallback16(IN ULONG FarPtr, - IN LPBYTE CallbackCode, - IN SIZE_T CallbackSize, - OUT PSIZE_T CodeSize OPTIONAL) -{ - LPBYTE CodeStart = (LPBYTE)FAR_POINTER(FarPtr); - LPBYTE Code = CodeStart; - - SIZE_T OurCodeSize = CallbackSize; - - if (CallbackCode == NULL) CallbackSize = 0; - - if (CallbackCode) - { - /* 16-bit interrupt code */ - RtlCopyMemory(Code, CallbackCode, CallbackSize); - Code += CallbackSize; - } - - /* Return the real size of the code if needed */ - if (CodeSize) *CodeSize = OurCodeSize; // == (ULONG_PTR)Code - (ULONG_PTR)CodeStart; - - // /* Return the entry-point address for 32-bit calls */ - // return (ULONG_PTR)(CodeStart + CallbackSize); - return OurCodeSize; -} - -VOID -RunCallback16(IN PCALLBACK16 Context, - IN ULONG FarPtr) -{ - PUCHAR TrampolineBase = (PUCHAR)FAR_POINTER(Context->TrampolineFarPtr); - PUCHAR Trampoline = TrampolineBase; - UCHAR OldTrampoline[CALL16_TRAMPOLINE_SIZE]; - - /* Save the old trampoline */ - ((PULONGLONG)&OldTrampoline)[0] = ((PULONGLONG)TrampolineBase)[0]; - - DPRINT1("RunCallback16(0x%p)\n", FarPtr); - - /* Build the generic entry-point for 16-bit far calls */ - *Trampoline++ = 0x9A; // Call far seg:off - *(PULONG)Trampoline = FarPtr; - Trampoline += sizeof(ULONG); - UnSimulate16(Trampoline); - - /* Perform the call */ - Call16(HIWORD(Context->TrampolineFarPtr), - LOWORD(Context->TrampolineFarPtr)); - - /* Restore the old trampoline */ - ((PULONGLONG)TrampolineBase)[0] = ((PULONGLONG)&OldTrampoline)[0]; -} - - - -ULONG -RegisterInt16(IN ULONG FarPtr, - IN BYTE IntNumber, - IN LPBYTE CallbackCode, - IN SIZE_T CallbackSize, - OUT PSIZE_T CodeSize OPTIONAL) -{ - /* Get a pointer to the IVT and set the corresponding entry (far pointer) */ - LPDWORD IntVecTable = (LPDWORD)SEG_OFF_TO_PTR(0x0000, 0x0000); - IntVecTable[IntNumber] = FarPtr; - - /* Register the 16-bit callback */ - return RegisterCallback16(FarPtr, - CallbackCode, - CallbackSize, - CodeSize); -} - -ULONG -RegisterInt32(IN ULONG FarPtr, - IN BYTE IntNumber, - IN EMULATOR_INT32_PROC IntHandler, - OUT PSIZE_T CodeSize OPTIONAL) -{ - /* Array for holding our copy of the 16-bit interrupt callback */ - BYTE IntCallback[sizeof(Int16To32)/sizeof(BYTE)]; - - /* Check whether the 32-bit interrupt was already registered */ -#if 0 - if (Int32Proc[IntNumber] != NULL) - { - DPRINT1("RegisterInt32: Interrupt 0x%02X already registered!\n", IntNumber); - return 0; - } -#endif - - /* Register the 32-bit interrupt handler */ - Int32Proc[IntNumber] = IntHandler; - - /* Copy the generic 16-bit interrupt callback and patch it */ - RtlCopyMemory(IntCallback, Int16To32, sizeof(Int16To32)); - IntCallback[2] = IntNumber; - - /* Register the 16-bit interrupt callback */ - return RegisterInt16(FarPtr, - IntNumber, - IntCallback, - sizeof(IntCallback), - CodeSize); -} - -VOID -Int32Call(IN PCALLBACK16 Context, - IN BYTE IntNumber) -{ - PUCHAR TrampolineBase = (PUCHAR)FAR_POINTER(Context->TrampolineFarPtr); - PUCHAR Trampoline = TrampolineBase; - UCHAR OldTrampoline[INT16_TRAMPOLINE_SIZE]; - - DPRINT("Int32Call(0x%02X)\n", IntNumber); - - /* Save the old trampoline */ - ((PULONGLONG)&OldTrampoline)[0] = ((PULONGLONG)TrampolineBase)[0]; - - /* Build the generic entry-point for 16-bit calls */ - if (IntNumber == 0x03) - { - /* We are redefining for INT 03h */ - *Trampoline++ = 0xCC; // Call INT 03h - /** *Trampoline++ = 0x90; // nop **/ - } - else - { - /* Normal interrupt */ - *Trampoline++ = 0xCD; // Call INT XXh - *Trampoline++ = IntNumber; - } - UnSimulate16(Trampoline); - - /* Perform the call */ - Call16(HIWORD(Context->TrampolineFarPtr), - LOWORD(Context->TrampolineFarPtr)); - - /* Restore the old trampoline */ - ((PULONGLONG)TrampolineBase)[0] = ((PULONGLONG)&OldTrampoline)[0]; -} - - - -VOID WINAPI Int32Dispatch(LPWORD Stack) -{ - /* Get the interrupt number */ - BYTE IntNum = LOBYTE(Stack[STACK_INT_NUM]); - - /* Call the 32-bit Interrupt handler */ - if (Int32Proc[IntNum] != NULL) - Int32Proc[IntNum](Stack); - else - DPRINT1("Unhandled 32-bit interrupt: 0x%02X, AX = 0x%04X\n", IntNum, getAX()); -} - -static VOID WINAPI ControlBop(LPWORD Stack) -{ - /* Get the Function Number and skip it */ - BYTE FuncNum = *(PBYTE)SEG_OFF_TO_PTR(getCS(), getIP()); - setIP(getIP() + 1); - - switch (FuncNum) - { - case BOP_CONTROL_INT32: - Int32Dispatch(Stack); - break; - - default: - // DPRINT1("Unassigned Control BOP Function: 0x%02X\n", FuncNum); - DisplayMessage(L"Unassigned Control BOP Function: 0x%02X", FuncNum); - break; - } -} - -VOID InitializeCallbacks(VOID) -{ - /* Register the Control BOP */ - RegisterBop(BOP_CONTROL, ControlBop); -} - -/* EOF */ diff --git a/subsystems/ntvdm/clock.c b/subsystems/ntvdm/clock.c index c283d325388..46241f40db4 100644 --- a/subsystems/ntvdm/clock.c +++ b/subsystems/ntvdm/clock.c @@ -12,6 +12,7 @@ #define NDEBUG #include "emulator.h" +#include "cpu/cpu.h" // #include "clock.h" @@ -62,7 +63,7 @@ UINT Irq12Counter = 0; VOID ClockUpdate(VOID) { - extern BOOLEAN CpuSimulate; + extern BOOLEAN CpuRunning; UINT i; #ifdef WORKING_TIMER @@ -137,9 +138,9 @@ VOID ClockUpdate(VOID) VgaHorizontalRetrace(); /* Continue CPU emulation */ - for (i = 0; VdmRunning && CpuSimulate && (i < STEPS_PER_CYCLE); i++) + for (i = 0; VdmRunning && CpuRunning && (i < STEPS_PER_CYCLE); i++) { - EmulatorStep(); + CpuStep(); #ifdef IPS_DISPLAY Cycles++; #endif diff --git a/subsystems/ntvdm/bop.c b/subsystems/ntvdm/cpu/bop.c similarity index 94% rename from subsystems/ntvdm/bop.c rename to subsystems/ntvdm/cpu/bop.c index 88a41dde9ef..d4f2430c61b 100644 --- a/subsystems/ntvdm/bop.c +++ b/subsystems/ntvdm/cpu/bop.c @@ -9,7 +9,7 @@ /* INCLUDES *******************************************************************/ -// #define NDEBUG +#define NDEBUG #include "emulator.h" #include "bop.h" @@ -44,7 +44,7 @@ VOID WINAPI EmulatorBiosOperation(PFAST486_STATE State, UCHAR BopCode) if (BopProc[BopCode] != NULL) BopProc[BopCode](Stack); else - DPRINT("Invalid BOP code: 0x%02X\n", BopCode); + DPRINT1("Invalid BOP code: 0x%02X\n", BopCode); } /* EOF */ diff --git a/subsystems/ntvdm/bop.h b/subsystems/ntvdm/cpu/bop.h similarity index 100% rename from subsystems/ntvdm/bop.h rename to subsystems/ntvdm/cpu/bop.h diff --git a/subsystems/ntvdm/cpu/callback.c b/subsystems/ntvdm/cpu/callback.c new file mode 100644 index 00000000000..0a71e88bf4f --- /dev/null +++ b/subsystems/ntvdm/cpu/callback.c @@ -0,0 +1,143 @@ +/* + * COPYRIGHT: GPL - See COPYING in the top level directory + * PROJECT: ReactOS Virtual DOS Machine + * FILE: callback.c + * PURPOSE: 16 and 32-bit Callbacks Support + * PROGRAMMERS: Aleksandar Andrejevic + * Hermes Belusca-Maito (hermes.belusca@sfr.fr) + */ + +/******************************************************************************\ +| WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! +| +| Callbacks support supposes implicitely that the callbacks are used +| in the SAME thread as the CPU thread, otherwise messing in parallel +| with the CPU registers is 100% prone to bugs!! +\******************************************************************************/ + +/* INCLUDES *******************************************************************/ + +#define NDEBUG + +#include "cpu.h" +#include "callback.h" +#include "emulator.h" + +#include "bop.h" +#include + +/* PRIVATE VARIABLES **********************************************************/ + +#define TRAMPOLINE_SIZE sizeof(ULONGLONG) + +static BYTE Yield[] = +{ + 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, + 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, // 13x nop + BOP(BOP_UNSIMULATE), // UnSimulate16 BOP +}; +C_ASSERT(sizeof(Yield) == 16 * sizeof(BYTE)); + +/* PUBLIC FUNCTIONS ***********************************************************/ + +VOID +InitializeContextEx(IN PCALLBACK16 Context, + IN ULONG TrampolineSize, + IN USHORT Segment, + IN USHORT Offset) +{ + Context->TrampolineFarPtr = MAKELONG(Offset, Segment); + Context->TrampolineSize = max(TRAMPOLINE_SIZE, TrampolineSize); + Context->Segment = Segment; + Context->NextOffset = Offset + Context->TrampolineSize; +} + +VOID +InitializeContext(IN PCALLBACK16 Context, + IN USHORT Segment, + IN USHORT Offset) +{ + InitializeContextEx(Context, + TRAMPOLINE_SIZE, + Segment, + Offset); +} + +VOID +Call16(IN USHORT Segment, + IN USHORT Offset) +{ + /* Save CS:IP */ + USHORT OrgCS = getCS(); + USHORT OrgIP = getIP(); + + /* Set the new CS:IP */ + setCS(Segment); + setIP(Offset); + + DPRINT("Call16(%04X:%04X)\n", Segment, Offset); + + /* Start CPU simulation */ + CpuSimulate(); + + /* Restore CS:IP */ + setCS(OrgCS); + setIP(OrgIP); +} + +VOID +RunCallback16(IN PCALLBACK16 Context, + IN ULONG FarPtr) +{ + PUCHAR TrampolineBase = (PUCHAR)FAR_POINTER(Context->TrampolineFarPtr); + PUCHAR Trampoline = TrampolineBase; + UCHAR OldTrampoline[TRAMPOLINE_SIZE]; + + /* Save the old trampoline */ + ((PULONGLONG)&OldTrampoline)[0] = ((PULONGLONG)TrampolineBase)[0]; + + DPRINT("RunCallback16(0x%p)\n", FarPtr); + + /* Build the generic entry-point for 16-bit far calls */ + *Trampoline++ = 0x9A; // Call far seg:off + *(PULONG)Trampoline = FarPtr; + Trampoline += sizeof(ULONG); + UnSimulate16(Trampoline); + + /* Perform the call */ + Call16(HIWORD(Context->TrampolineFarPtr), + LOWORD(Context->TrampolineFarPtr)); + + /* Restore the old trampoline */ + ((PULONGLONG)TrampolineBase)[0] = ((PULONGLONG)&OldTrampoline)[0]; +} + +ULONG +RegisterCallback16(IN ULONG FarPtr, + IN LPBYTE CallbackCode, + IN SIZE_T CallbackSize, + OUT PSIZE_T CodeSize OPTIONAL) +{ + LPBYTE CodeStart = (LPBYTE)FAR_POINTER(FarPtr); + LPBYTE Code = CodeStart; + + SIZE_T OurCodeSize = CallbackSize; + + if (CallbackCode == NULL) CallbackSize = 0; + + if (CallbackCode) + { + /* 16-bit interrupt code */ + RtlCopyMemory(Code, CallbackCode, CallbackSize); + Code += CallbackSize; + } + + /* Return the real size of the code if needed */ + if (CodeSize) *CodeSize = OurCodeSize; // == (ULONG_PTR)Code - (ULONG_PTR)CodeStart; + + // /* Return the entry-point address for 32-bit calls */ + // return (ULONG_PTR)(CodeStart + CallbackSize); + return OurCodeSize; +} + +/* EOF */ diff --git a/subsystems/ntvdm/callback.h b/subsystems/ntvdm/cpu/callback.h similarity index 61% rename from subsystems/ntvdm/callback.h rename to subsystems/ntvdm/cpu/callback.h index 264e67fe6d0..265669f3611 100644 --- a/subsystems/ntvdm/callback.h +++ b/subsystems/ntvdm/cpu/callback.h @@ -12,8 +12,14 @@ /* DEFINES ********************************************************************/ -/* 32-bit Interrupt Identifiers */ -#define EMULATOR_MAX_INT32_NUM 0xFF + 1 +#define BOP(num) LOBYTE(EMULATOR_BOP), HIBYTE(EMULATOR_BOP), (num) +#define UnSimulate16(trap) \ +do { \ + *(PUSHORT)(trap) = EMULATOR_BOP; \ + (trap) += sizeof(USHORT); \ + *(trap) = BOP_UNSIMULATE; \ +} while(0) +// #define UnSimulate16 MAKELONG(EMULATOR_BOP, BOP_UNSIMULATE) // BOP(BOP_UNSIMULATE) typedef struct _CALLBACK16 { @@ -23,11 +29,23 @@ typedef struct _CALLBACK16 USHORT NextOffset; } CALLBACK16, *PCALLBACK16; -extern const ULONG Int16To32StubSize; +// +// WARNING WARNING!! +// If you're changing the indices here, you then need to +// also fix the BOP code in callback.c !!!!!!!!!!!!!!!!! +// +#define STACK_INT_NUM 0 +#define STACK_IP 1 +#define STACK_CS 2 +#define STACK_FLAGS 3 /* FUNCTIONS ******************************************************************/ -typedef VOID (WINAPI *EMULATOR_INT32_PROC)(LPWORD Stack); +VOID +InitializeContextEx(IN PCALLBACK16 Context, + IN ULONG TrampolineSize, + IN USHORT Segment, + IN USHORT Offset); VOID InitializeContext(IN PCALLBACK16 Context, @@ -38,36 +56,16 @@ VOID Call16(IN USHORT Segment, IN USHORT Offset); +VOID +RunCallback16(IN PCALLBACK16 Context, + IN ULONG FarPtr); + ULONG RegisterCallback16(IN ULONG FarPtr, IN LPBYTE CallbackCode, IN SIZE_T CallbackSize, OUT PSIZE_T CodeSize OPTIONAL); -VOID -RunCallback16(IN PCALLBACK16 Context, - IN ULONG FarPtr); - -ULONG -RegisterInt16(IN ULONG FarPtr, - IN BYTE IntNumber, - IN LPBYTE CallbackCode, - IN SIZE_T CallbackSize, - OUT PSIZE_T CodeSize OPTIONAL); - -ULONG -RegisterInt32(IN ULONG FarPtr, - IN BYTE IntNumber, - IN EMULATOR_INT32_PROC IntHandler, - OUT PSIZE_T CodeSize OPTIONAL); - -VOID -Int32Call(IN PCALLBACK16 Context, - IN BYTE IntNumber); - -VOID WINAPI Int32Dispatch(LPWORD Stack); -VOID InitializeCallbacks(VOID); - #endif // _CALLBACK_H_ /* EOF */ diff --git a/subsystems/ntvdm/cpu/cpu.c b/subsystems/ntvdm/cpu/cpu.c new file mode 100644 index 00000000000..bd744093c43 --- /dev/null +++ b/subsystems/ntvdm/cpu/cpu.c @@ -0,0 +1,191 @@ +/* + * COPYRIGHT: GPL - See COPYING in the top level directory + * PROJECT: ReactOS Virtual DOS Machine + * FILE: emulator.c + * PURPOSE: Minimal x86 machine emulator for the VDM + * PROGRAMMERS: Aleksandar Andrejevic + */ + +/* INCLUDES *******************************************************************/ + +#define NDEBUG + +#include "cpu.h" + +#include "emulator.h" +#include "callback.h" +#include "bop.h" +#include + +#include "clock.h" +#include "bios/rom.h" +#include "hardware/cmos.h" +#include "hardware/keyboard.h" +#include "hardware/mouse.h" +#include "hardware/pic.h" +#include "hardware/ps2.h" +#include "hardware/speaker.h" +#include "hardware/timer.h" +#include "hardware/vga.h" + +#include "io.h" + +/* PRIVATE VARIABLES **********************************************************/ + +FAST486_STATE EmulatorContext; +BOOLEAN CpuRunning = FALSE; + +/* No more than 'MaxCpuCallLevel' recursive CPU calls are allowed */ +static const INT MaxCpuCallLevel = 32; +static INT CpuCallLevel = 0; + +// BOOLEAN VdmRunning = TRUE; + +#if 0 +LPCWSTR ExceptionName[] = +{ + L"Division By Zero", + L"Debug", + L"Unexpected Error", + L"Breakpoint", + L"Integer Overflow", + L"Bound Range Exceeded", + L"Invalid Opcode", + L"FPU Not Available" +}; +#endif + +// /* BOP Identifiers */ +// #define BOP_DEBUGGER 0x56 // Break into the debugger from a 16-bit app + +/* PRIVATE FUNCTIONS **********************************************************/ + +#if 0 +VOID EmulatorException(BYTE ExceptionNumber, LPWORD Stack) +{ + WORD CodeSegment, InstructionPointer; + PBYTE Opcode; + + ASSERT(ExceptionNumber < 8); + + /* Get the CS:IP */ + InstructionPointer = Stack[STACK_IP]; + CodeSegment = Stack[STACK_CS]; + Opcode = (PBYTE)SEG_OFF_TO_PTR(CodeSegment, InstructionPointer); + + /* Display a message to the user */ + DisplayMessage(L"Exception: %s occured at %04X:%04X\n" + L"Opcode: %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X", + ExceptionName[ExceptionNumber], + CodeSegment, + InstructionPointer, + Opcode[0], + Opcode[1], + Opcode[2], + Opcode[3], + Opcode[4], + Opcode[5], + Opcode[6], + Opcode[7], + Opcode[8], + Opcode[9]); + + /* Stop the VDM */ + EmulatorTerminate(); + return; +} +#endif + +// FIXME: This function assumes 16-bit mode!!! +VOID CpuExecute(WORD Segment, WORD Offset) +{ + /* Tell Fast486 to move the instruction pointer */ + Fast486ExecuteAt(&EmulatorContext, Segment, Offset); +} + +VOID CpuStep(VOID) +{ + /* Dump the state for debugging purposes */ + // Fast486DumpState(&EmulatorContext); + + /* Execute the next instruction */ + Fast486StepInto(&EmulatorContext); +} + +VOID CpuSimulate(VOID) +{ + if (CpuCallLevel > MaxCpuCallLevel) + { + DisplayMessage(L"Too many CPU levels of recursion (%d, expected maximum %d)", + CpuCallLevel, MaxCpuCallLevel); + + /* Stop the VDM */ + EmulatorTerminate(); + return; + } + CpuCallLevel++; + + CpuRunning = TRUE; + while (VdmRunning && CpuRunning) ClockUpdate(); + + CpuCallLevel--; + if (CpuCallLevel < 0) CpuCallLevel = 0; + + /* This takes into account for reentrance */ + CpuRunning = TRUE; +} + +VOID CpuUnsimulate(VOID) +{ + /* Stop simulation */ + CpuRunning = FALSE; +} + +static VOID WINAPI CpuUnsimulateBop(LPWORD Stack) +{ + CpuUnsimulate(); +} + +#if 0 +VOID EmulatorTerminate(VOID) +{ + /* Stop the VDM */ + VdmRunning = FALSE; +} +#endif + +/* PUBLIC FUNCTIONS ***********************************************************/ + +BOOLEAN CpuInitialize(VOID) +{ + // /* Initialize the internal clock */ + // if (!ClockInitialize()) + // { + // wprintf(L"FATAL: Failed to initialize the clock\n"); + // return FALSE; + // } + + /* Initialize the CPU */ + Fast486Initialize(&EmulatorContext, + EmulatorReadMemory, + EmulatorWriteMemory, + EmulatorReadIo, + EmulatorWriteIo, + NULL, + EmulatorBiosOperation, + EmulatorIntAcknowledge, + NULL /* TODO: Use a TLB */); + + /* Initialize the software callback system and register the emulator BOPs */ + // RegisterBop(BOP_DEBUGGER , EmulatorDebugBreakBop); + RegisterBop(BOP_UNSIMULATE, CpuUnsimulateBop); + + return TRUE; +} + +VOID CpuCleanup(VOID) +{ + // Fast486Cleanup(); +} + +/* EOF */ diff --git a/subsystems/ntvdm/cpu/cpu.h b/subsystems/ntvdm/cpu/cpu.h new file mode 100644 index 00000000000..fd51b49da4c --- /dev/null +++ b/subsystems/ntvdm/cpu/cpu.h @@ -0,0 +1,79 @@ +/* + * COPYRIGHT: GPL - See COPYING in the top level directory + * PROJECT: ReactOS Virtual DOS Machine + * FILE: emulator.h + * PURPOSE: Minimal x86 machine emulator for the VDM + * PROGRAMMERS: Aleksandar Andrejevic + */ + +#ifndef _CPU_H_ +#define _CPU_H_ + +/* INCLUDES *******************************************************************/ + +#include "ntvdm.h" +#include + +/* DEFINES ********************************************************************/ + +/* FLAGS */ +#define EMULATOR_FLAG_CF (1 << 0) +#define EMULATOR_FLAG_PF (1 << 2) +#define EMULATOR_FLAG_AF (1 << 4) +#define EMULATOR_FLAG_ZF (1 << 6) +#define EMULATOR_FLAG_SF (1 << 7) +#define EMULATOR_FLAG_TF (1 << 8) +#define EMULATOR_FLAG_IF (1 << 9) +#define EMULATOR_FLAG_DF (1 << 10) +#define EMULATOR_FLAG_OF (1 << 11) +#define EMULATOR_FLAG_NT (1 << 14) +#define EMULATOR_FLAG_RF (1 << 16) +#define EMULATOR_FLAG_VM (1 << 17) +#define EMULATOR_FLAG_AC (1 << 18) +#define EMULATOR_FLAG_VIF (1 << 19) +#define EMULATOR_FLAG_VIP (1 << 20) +#define EMULATOR_FLAG_ID (1 << 21) + +#if 0 +enum +{ + EMULATOR_EXCEPTION_DIVISION_BY_ZERO, + EMULATOR_EXCEPTION_DEBUG, + EMULATOR_EXCEPTION_NMI, + EMULATOR_EXCEPTION_BREAKPOINT, + EMULATOR_EXCEPTION_OVERFLOW, + EMULATOR_EXCEPTION_BOUND, + EMULATOR_EXCEPTION_INVALID_OPCODE, + EMULATOR_EXCEPTION_NO_FPU, + EMULATOR_EXCEPTION_DOUBLE_FAULT, + EMULATOR_EXCEPTION_FPU_SEGMENT, + EMULATOR_EXCEPTION_INVALID_TSS, + EMULATOR_EXCEPTION_NO_SEGMENT, + EMULATOR_EXCEPTION_STACK_SEGMENT, + EMULATOR_EXCEPTION_GPF, + EMULATOR_EXCEPTION_PAGE_FAULT +}; +#endif +extern FAST486_STATE EmulatorContext; +// extern BOOLEAN VdmRunning; + +/* FUNCTIONS ******************************************************************/ + +#if 0 +VOID EmulatorException(BYTE ExceptionNumber, LPWORD Stack); +#endif + +VOID CpuExecute(WORD Segment, WORD Offset); +VOID CpuStep(VOID); +VOID CpuSimulate(VOID); +VOID CpuUnsimulate(VOID); +#if 0 +VOID EmulatorTerminate(VOID); +#endif + +BOOLEAN CpuInitialize(VOID); +VOID CpuCleanup(VOID); + +#endif // _CPU_H_ + +/* EOF */ diff --git a/subsystems/ntvdm/dos/dem.c b/subsystems/ntvdm/dos/dem.c index 4b75d85c69e..13fde993e59 100644 --- a/subsystems/ntvdm/dos/dem.c +++ b/subsystems/ntvdm/dos/dem.c @@ -18,7 +18,7 @@ #include "utils.h" #include "dem.h" -#include "bop.h" +#include "cpu/bop.h" #include "bios/bios.h" #include "mouse32.h" @@ -70,7 +70,7 @@ static VOID WINAPI DosSystemBop(LPWORD Stack) ulDosKernelSize, &ulDosKernelSize); - DPRINT1("Windows NT DOS loading %s at 0x%04X:0x%04X, size 0x%x ; GetLastError() = %u\n", + DPRINT1("Windows NT DOS loading %s at %04X:%04X, size 0x%X ; GetLastError() = %u\n", (Success ? "succeeded" : "failed"), getDI(), 0x0000, ulDosKernelSize, @@ -211,7 +211,7 @@ BOOLEAN DosInitialize(IN LPCSTR DosKernelFileName) ulDosBiosSize, &ulDosBiosSize); - DPRINT1("DOS BIOS loading %s at 0x%04X:0x%04X, size 0x%x ; GetLastError() = %u\n", + DPRINT1("DOS BIOS loading %s at %04X:%04X, size 0x%X ; GetLastError() = %u\n", (Success ? "succeeded" : "failed"), 0x0070, 0x0000, ulDosBiosSize, diff --git a/subsystems/ntvdm/dos/dos32krnl/bios.c b/subsystems/ntvdm/dos/dos32krnl/bios.c index b70be3b2be7..428807e0699 100644 --- a/subsystems/ntvdm/dos/dos32krnl/bios.c +++ b/subsystems/ntvdm/dos/dos32krnl/bios.c @@ -11,7 +11,7 @@ #define NDEBUG #include "emulator.h" -#include "callback.h" +#include "int32.h" #include "dos.h" diff --git a/subsystems/ntvdm/dos/dos32krnl/dos.c b/subsystems/ntvdm/dos/dos32krnl/dos.c index f3e73fdef03..db5bc14f85a 100644 --- a/subsystems/ntvdm/dos/dos32krnl/dos.c +++ b/subsystems/ntvdm/dos/dos32krnl/dos.c @@ -12,7 +12,8 @@ #define NDEBUG #include "emulator.h" -#include "callback.h" +#include "cpu/cpu.h" +#include "int32.h" #include "dos.h" #include "dos/dem.h" @@ -1062,8 +1063,8 @@ DWORD DosLoadExecutable(IN DOS_EXEC_TYPE LoadType, /* Execute */ CurrentPsp = Segment; DiskTransferArea = MAKELONG(0x80, Segment); - EmulatorExecute(Segment + Header->e_cs + (sizeof(DOS_PSP) >> 4), - Header->e_ip); + CpuExecute(Segment + Header->e_cs + (sizeof(DOS_PSP) >> 4), + Header->e_ip); } } else @@ -1121,7 +1122,7 @@ DWORD DosLoadExecutable(IN DOS_EXEC_TYPE LoadType, /* Execute */ CurrentPsp = Segment; DiskTransferArea = MAKELONG(0x80, Segment); - EmulatorExecute(Segment, 0x100); + CpuExecute(Segment, 0x100); } } @@ -1165,7 +1166,7 @@ DWORD DosStartProcess(IN LPCSTR ExecutablePath, /* Start simulation */ SetEvent(VdmTaskEvent); - EmulatorSimulate(); + CpuSimulate(); /* Detach from the console */ VidBiosDetachFromConsole(); // FIXME: And in fact, detach the full NTVDM UI from the console @@ -1344,7 +1345,7 @@ Done: if (CurrentPsp == SYSTEM_PSP) { ResetEvent(VdmTaskEvent); - EmulatorUnsimulate(); + CpuUnsimulate(); } } @@ -1374,8 +1375,8 @@ Done: DosErrorLevel = MAKEWORD(ReturnCode, 0x00); /* Return control to the parent process */ - EmulatorExecute(HIWORD(PspBlock->TerminateAddress), - LOWORD(PspBlock->TerminateAddress)); + CpuExecute(HIWORD(PspBlock->TerminateAddress), + LOWORD(PspBlock->TerminateAddress)); } BOOLEAN DosHandleIoctl(BYTE ControlCode, WORD FileHandle) @@ -1405,15 +1406,18 @@ BOOLEAN DosHandleIoctl(BYTE ControlCode, WORD FileHandle) { /* Console input */ InfoWord |= 1 << 0; + + /* It is a device */ + InfoWord |= 1 << 7; } else if (Handle == DosSystemFileTable[DOS_OUTPUT_HANDLE].Handle) { /* Console output */ InfoWord |= 1 << 1; - } - /* It is a device */ - InfoWord |= 1 << 7; + /* It is a device */ + InfoWord |= 1 << 7; + } /* Return the device information word */ setDX(InfoWord); @@ -1752,7 +1756,8 @@ VOID WINAPI DosInt21h(LPWORD Stack) case 0x25: { ULONG FarPointer = MAKELONG(getDX(), getDS()); - DPRINT1("Setting interrupt 0x%x ...\n", getAL()); + DPRINT1("Setting interrupt 0x%02X to %04X:%04X ...\n", + getAL(), HIWORD(FarPointer), LOWORD(FarPointer)); /* Write the new far pointer to the IDT */ ((PULONG)BaseAddress)[getAL()] = FarPointer; @@ -1837,8 +1842,9 @@ VOID WINAPI DosInt21h(LPWORD Stack) * Return DOS OEM number: * 0x00 for IBM PC-DOS * 0x02 for packaged MS-DOS + * 0xFF for NT DOS */ - setBH(0x02); + setBH(0xFF); } if (LOBYTE(PspBlock->DosVersion) >= 5 && getAL() == 0x01) @@ -2576,6 +2582,14 @@ VOID WINAPI DosInt21h(LPWORD Stack) break; } + /* Get Extended Error Information */ + case 0x59: + { + DPRINT1("INT 21h, AH = 59h, BX = %04Xh - Get Extended Error Information is UNIMPLEMENTED\n", + getBX()); + break; + } + /* Create Temporary File */ case 0x5A: { @@ -2772,6 +2786,10 @@ VOID WINAPI DosInt21h(LPWORD Stack) /* Extended Open/Create */ case 0x6C: { + WORD FileHandle; + WORD CreationStatus; + WORD ErrorCode; + /* Check for AL == 00 */ if (getAL() != 0x00) { @@ -2780,10 +2798,31 @@ VOID WINAPI DosInt21h(LPWORD Stack) break; } - // TODO!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - // FIXME: Extend and merge DosOpenFile and DosCreateFile into - // a single wrapper around CreateFileA, which acts as: - // http://www.ctyme.com/intr/rb-3179.htm + /* + * See Ralf Brown: http://www.ctyme.com/intr/rb-3179.htm + * for the full detailed description. + * + * WARNING: BH contains some extended flags that are NOT SUPPORTED. + */ + + ErrorCode = DosCreateFileEx(&FileHandle, + &CreationStatus, + (LPCSTR)SEG_OFF_TO_PTR(getDS(), getSI()), + getBL(), + getDL(), + getCX()); + + if (ErrorCode == ERROR_SUCCESS) + { + Stack[STACK_FLAGS] &= ~EMULATOR_FLAG_CF; + setCX(CreationStatus); + setAX(FileHandle); + } + else + { + Stack[STACK_FLAGS] |= EMULATOR_FLAG_CF; + setAX(ErrorCode); + } break; } @@ -2806,7 +2845,7 @@ VOID WINAPI DosBreakInterrupt(LPWORD Stack) /* Stop the VDM task */ ResetEvent(VdmTaskEvent); - EmulatorUnsimulate(); + CpuUnsimulate(); } VOID WINAPI DosFastConOut(LPWORD Stack) diff --git a/subsystems/ntvdm/dos/dos32krnl/dos.h b/subsystems/ntvdm/dos/dos32krnl/dos.h index abbef7e142d..0a0181760d5 100644 --- a/subsystems/ntvdm/dos/dos32krnl/dos.h +++ b/subsystems/ntvdm/dos/dos32krnl/dos.h @@ -13,7 +13,7 @@ #include "ntvdm.h" -/**/ #include "callback.h" /**/ +/**/ #include "int32.h" /**/ /* DEFINES ********************************************************************/ @@ -192,11 +192,31 @@ BOOL IsConsoleHandle(HANDLE hHandle); WORD DosOpenHandle(HANDLE Handle); HANDLE DosGetRealHandle(WORD DosHandle); -WORD DosCreateFile(LPWORD Handle, LPCSTR FilePath, WORD CreationFlags, WORD Attributes); -WORD DosOpenFile(LPWORD Handle, LPCSTR FilePath, BYTE AccessShareModes); -WORD DosReadFile(WORD FileHandle, LPVOID Buffer, WORD Count, LPWORD BytesRead); -WORD DosWriteFile(WORD FileHandle, LPVOID Buffer, WORD Count, LPWORD BytesWritten); -WORD DosSeekFile(WORD FileHandle, LONG Offset, BYTE Origin, LPDWORD NewOffset); +WORD DosCreateFileEx(LPWORD Handle, + LPWORD CreationStatus, + LPCSTR FilePath, + BYTE AccessShareModes, + WORD CreateActionFlags, + WORD Attributes); +WORD DosCreateFile(LPWORD Handle, + LPCSTR FilePath, + DWORD CreationDisposition, + WORD Attributes); +WORD DosOpenFile(LPWORD Handle, + LPCSTR FilePath, + BYTE AccessShareModes); +WORD DosReadFile(WORD FileHandle, + LPVOID Buffer, + WORD Count, + LPWORD BytesRead); +WORD DosWriteFile(WORD FileHandle, + LPVOID Buffer, + WORD Count, + LPWORD BytesWritten); +WORD DosSeekFile(WORD FileHandle, + LONG Offset, + BYTE Origin, + LPDWORD NewOffset); BOOL DosFlushFileBuffers(WORD FileHandle); VOID DosInitializePsp(WORD PspSegment, LPCSTR CommandLine, WORD ProgramSize, WORD Environment); diff --git a/subsystems/ntvdm/dos/dos32krnl/dosfiles.c b/subsystems/ntvdm/dos/dos32krnl/dosfiles.c index e5560b2264d..9bf4d0839b8 100644 --- a/subsystems/ntvdm/dos/dos32krnl/dosfiles.c +++ b/subsystems/ntvdm/dos/dos32krnl/dosfiles.c @@ -12,36 +12,254 @@ #define NDEBUG #include "emulator.h" -// #include "callback.h" #include "dos.h" #include "dos/dem.h" #include "bios/bios.h" -/* PRIVATE VARIABLES **********************************************************/ - /* PUBLIC FUNCTIONS ***********************************************************/ -WORD DosCreateFile(LPWORD Handle, LPCSTR FilePath, WORD CreationFlags, WORD Attributes) +WORD DosCreateFileEx(LPWORD Handle, + LPWORD CreationStatus, + LPCSTR FilePath, + BYTE AccessShareModes, + WORD CreateActionFlags, + WORD Attributes) +{ + WORD LastError; + HANDLE FileHandle; + WORD DosHandle; + ACCESS_MASK AccessMode = 0; + DWORD ShareMode = 0; + DWORD CreationDisposition = 0; + BOOL InheritableFile = FALSE; + SECURITY_ATTRIBUTES SecurityAttributes; + + DPRINT1("DosCreateFileEx: FilePath \"%s\", AccessShareModes 0x%04X, CreateActionFlags 0x%04X, Attributes 0x%04X\n", + FilePath, AccessShareModes, CreateActionFlags, Attributes); + + // + // The article about OpenFile API: http://msdn.microsoft.com/en-us/library/windows/desktop/aa365430(v=vs.85).aspx + // explains what are those AccessShareModes (see the uStyle flag). + // + + /* Parse the access mode */ + switch (AccessShareModes & 0x03) + { + /* Read-only */ + case 0: + AccessMode = GENERIC_READ; + break; + + /* Write only */ + case 1: + AccessMode = GENERIC_WRITE; + break; + + /* Read and write */ + case 2: + AccessMode = GENERIC_READ | GENERIC_WRITE; + break; + + /* Invalid */ + default: + return ERROR_INVALID_PARAMETER; + } + + /* Parse the share mode */ + switch ((AccessShareModes >> 4) & 0x07) + { + /* Compatibility mode */ + case 0: + ShareMode = FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE; + break; + + /* No sharing "DenyAll" */ + case 1: + ShareMode = 0; + break; + + /* No write share "DenyWrite" */ + case 2: + ShareMode = FILE_SHARE_READ; + break; + + /* No read share "DenyRead" */ + case 3: + ShareMode = FILE_SHARE_WRITE; + break; + + /* Full share "DenyNone" */ + case 4: + ShareMode = FILE_SHARE_READ | FILE_SHARE_WRITE; + break; + + /* Invalid */ + default: + return ERROR_INVALID_PARAMETER; + } + + /* + * Parse the creation action flags: + * + * Bitfields for action: + * Bit(s) Description + * + * 7-4 Action if file does not exist. + * 0000 Fail + * 0001 Create + * + * 3-0 Action if file exists. + * 0000 Fail + * 0001 Open + * 0010 Replace/open + */ + switch (CreateActionFlags) + { + /* If the file exists, fail, otherwise, fail also */ + case 0x00: + // A special case is used after the call to CreateFileA if it succeeds, + // in order to close the opened handle and return an adequate error. + CreationDisposition = OPEN_EXISTING; + break; + + /* If the file exists, open it, otherwise, fail */ + case 0x01: + CreationDisposition = OPEN_EXISTING; + break; + + /* If the file exists, replace it, otherwise, fail */ + case 0x02: + CreationDisposition = TRUNCATE_EXISTING; + break; + + /* If the file exists, fail, otherwise, create it */ + case 0x10: + CreationDisposition = CREATE_NEW; + break; + + /* If the file exists, open it, otherwise, create it */ + case 0x11: + CreationDisposition = OPEN_ALWAYS; + break; + + /* If the file exists, replace it, otherwise, create it */ + case 0x12: + CreationDisposition = CREATE_ALWAYS; + break; + + /* Invalid */ + default: + return ERROR_INVALID_PARAMETER; + } + + /* Check for inheritance */ + InheritableFile = ((AccessShareModes & 0x80) == 0); + + /* Assign default security attributes to the file, and set the inheritance flag */ + SecurityAttributes.nLength = sizeof(SecurityAttributes); + SecurityAttributes.lpSecurityDescriptor = NULL; + SecurityAttributes.bInheritHandle = InheritableFile; + + /* Open the file */ + FileHandle = CreateFileA(FilePath, + AccessMode, + ShareMode, + &SecurityAttributes, + CreationDisposition, + Attributes, + NULL); + + LastError = (WORD)GetLastError(); + + if (FileHandle == INVALID_HANDLE_VALUE) + { + /* Return the error code */ + return LastError; + } + + /* + * Special case: CreateActionFlags == 0, we must fail because + * the file exists (if it didn't exist we already failed). + */ + if (CreateActionFlags == 0) + { + /* Close the file and return the error code */ + CloseHandle(FileHandle); + return ERROR_FILE_EXISTS; + } + + /* Set the creation status */ + switch (CreateActionFlags) + { + case 0x01: + *CreationStatus = 0x01; // The file was opened + break; + + case 0x02: + *CreationStatus = 0x03; // The file was replaced + break; + + case 0x10: + *CreationStatus = 0x02; // The file was created + break; + + case 0x11: + { + if (LastError == ERROR_ALREADY_EXISTS) + *CreationStatus = 0x01; // The file was opened + else + *CreationStatus = 0x02; // The file was created + + break; + } + + case 0x12: + { + if (LastError == ERROR_ALREADY_EXISTS) + *CreationStatus = 0x03; // The file was replaced + else + *CreationStatus = 0x02; // The file was created + + break; + } + } + + /* Open the DOS handle */ + DosHandle = DosOpenHandle(FileHandle); + + if (DosHandle == INVALID_DOS_HANDLE) + { + /* Close the file and return the error code */ + CloseHandle(FileHandle); + return ERROR_TOO_MANY_OPEN_FILES; + } + + /* It was successful */ + *Handle = DosHandle; + return ERROR_SUCCESS; +} + +WORD DosCreateFile(LPWORD Handle, + LPCSTR FilePath, + DWORD CreationDisposition, + WORD Attributes) { HANDLE FileHandle; WORD DosHandle; - DPRINT("DosCreateFile: FilePath \"%s\", CreationFlags 0x%04X, Attributes 0x%04X\n", - FilePath, - CreationFlags, - Attributes); + DPRINT("DosCreateFile: FilePath \"%s\", CreationDisposition 0x%04X, Attributes 0x%04X\n", + FilePath, CreationDisposition, Attributes); /* Create the file */ FileHandle = CreateFileA(FilePath, GENERIC_READ | GENERIC_WRITE, FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE, NULL, - CreationFlags, + CreationDisposition, Attributes, NULL); - if (FileHandle == INVALID_HANDLE_VALUE) { /* Return the error code */ @@ -53,10 +271,8 @@ WORD DosCreateFile(LPWORD Handle, LPCSTR FilePath, WORD CreationFlags, WORD Attr if (DosHandle == INVALID_DOS_HANDLE) { - /* Close the handle */ + /* Close the file and return the error code */ CloseHandle(FileHandle); - - /* Return the error code */ return ERROR_TOO_MANY_OPEN_FILES; } @@ -65,7 +281,9 @@ WORD DosCreateFile(LPWORD Handle, LPCSTR FilePath, WORD CreationFlags, WORD Attr return ERROR_SUCCESS; } -WORD DosOpenFile(LPWORD Handle, LPCSTR FilePath, BYTE AccessShareModes) +WORD DosOpenFile(LPWORD Handle, + LPCSTR FilePath, + BYTE AccessShareModes) { HANDLE FileHandle; ACCESS_MASK AccessMode = 0; @@ -75,83 +293,67 @@ WORD DosOpenFile(LPWORD Handle, LPCSTR FilePath, BYTE AccessShareModes) WORD DosHandle; DPRINT("DosOpenFile: FilePath \"%s\", AccessShareModes 0x%04X\n", - FilePath, - AccessShareModes); + FilePath, AccessShareModes); + + // + // The article about OpenFile API: http://msdn.microsoft.com/en-us/library/windows/desktop/aa365430(v=vs.85).aspx + // explains what are those AccessShareModes (see the uStyle flag). + // /* Parse the access mode */ switch (AccessShareModes & 0x03) { + /* Read-only */ case 0: - { - /* Read-only */ AccessMode = GENERIC_READ; break; - } + /* Write only */ case 1: - { - /* Write only */ AccessMode = GENERIC_WRITE; break; - } + /* Read and write */ case 2: - { - /* Read and write */ AccessMode = GENERIC_READ | GENERIC_WRITE; break; - } + /* Invalid */ default: - { - /* Invalid */ return ERROR_INVALID_PARAMETER; - } } /* Parse the share mode */ switch ((AccessShareModes >> 4) & 0x07) { + /* Compatibility mode */ case 0: - { - /* Compatibility mode */ ShareMode = FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE; break; - } + /* No sharing "DenyAll" */ case 1: - { - /* No sharing "DenyAll" */ ShareMode = 0; break; - } + /* No write share "DenyWrite" */ case 2: - { - /* No write share "DenyWrite" */ ShareMode = FILE_SHARE_READ; break; - } + /* No read share "DenyRead" */ case 3: - { - /* No read share "DenyRead" */ ShareMode = FILE_SHARE_WRITE; break; - } + /* Full share "DenyNone" */ case 4: - { - /* Full share "DenyNone" */ ShareMode = FILE_SHARE_READ | FILE_SHARE_WRITE; break; - } + /* Invalid */ default: - { - /* Invalid */ return ERROR_INVALID_PARAMETER; - } } /* Check for inheritance */ @@ -170,7 +372,6 @@ WORD DosOpenFile(LPWORD Handle, LPCSTR FilePath, BYTE AccessShareModes) OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL); - if (FileHandle == INVALID_HANDLE_VALUE) { /* Return the error code */ @@ -182,10 +383,8 @@ WORD DosOpenFile(LPWORD Handle, LPCSTR FilePath, BYTE AccessShareModes) if (DosHandle == INVALID_DOS_HANDLE) { - /* Close the handle */ + /* Close the file and return the error code */ CloseHandle(FileHandle); - - /* Return the error code */ return ERROR_TOO_MANY_OPEN_FILES; } @@ -194,7 +393,10 @@ WORD DosOpenFile(LPWORD Handle, LPCSTR FilePath, BYTE AccessShareModes) return ERROR_SUCCESS; } -WORD DosReadFile(WORD FileHandle, LPVOID Buffer, WORD Count, LPWORD BytesRead) +WORD DosReadFile(WORD FileHandle, + LPVOID Buffer, + WORD Count, + LPWORD BytesRead) { WORD Result = ERROR_SUCCESS; DWORD BytesRead32 = 0; @@ -259,7 +461,10 @@ WORD DosReadFile(WORD FileHandle, LPVOID Buffer, WORD Count, LPWORD BytesRead) return Result; } -WORD DosWriteFile(WORD FileHandle, LPVOID Buffer, WORD Count, LPWORD BytesWritten) +WORD DosWriteFile(WORD FileHandle, + LPVOID Buffer, + WORD Count, + LPWORD BytesWritten) { WORD Result = ERROR_SUCCESS; DWORD BytesWritten32 = 0; @@ -317,7 +522,10 @@ WORD DosWriteFile(WORD FileHandle, LPVOID Buffer, WORD Count, LPWORD BytesWritte return Result; } -WORD DosSeekFile(WORD FileHandle, LONG Offset, BYTE Origin, LPDWORD NewOffset) +WORD DosSeekFile(WORD FileHandle, + LONG Offset, + BYTE Origin, + LPDWORD NewOffset) { WORD Result = ERROR_SUCCESS; DWORD FilePointer; diff --git a/subsystems/ntvdm/dos/mouse32.c b/subsystems/ntvdm/dos/mouse32.c index e825dfe2c52..5b0a526844e 100644 --- a/subsystems/ntvdm/dos/mouse32.c +++ b/subsystems/ntvdm/dos/mouse32.c @@ -11,7 +11,8 @@ #define NDEBUG #include "emulator.h" -#include "callback.h" +#include "cpu/cpu.h" +#include "int32.h" #include "mouse32.h" #include "bios/bios.h" diff --git a/subsystems/ntvdm/emulator.c b/subsystems/ntvdm/emulator.c index 06d1e234676..84e41bd6942 100644 --- a/subsystems/ntvdm/emulator.c +++ b/subsystems/ntvdm/emulator.c @@ -11,7 +11,13 @@ #define NDEBUG #include "emulator.h" -#include "callback.h" + +#include "cpu/callback.h" +#include "cpu/cpu.h" +#include "cpu/bop.h" +#include + +#include "int32.h" #include "clock.h" #include "bios/rom.h" @@ -24,21 +30,11 @@ #include "hardware/timer.h" #include "hardware/vga.h" -#include "bop.h" #include "vddsup.h" #include "io.h" -#include - /* PRIVATE VARIABLES **********************************************************/ -FAST486_STATE EmulatorContext; -BOOLEAN CpuSimulate = FALSE; - -/* No more than 'MaxCpuCallLevel' recursive CPU calls are allowed */ -static const INT MaxCpuCallLevel = 32; -static INT CpuCallLevel = 0; - LPVOID BaseAddress = NULL; BOOLEAN VdmRunning = TRUE; @@ -176,51 +172,6 @@ VOID EmulatorException(BYTE ExceptionNumber, LPWORD Stack) return; } -// FIXME: This function assumes 16-bit mode!!! -VOID EmulatorExecute(WORD Segment, WORD Offset) -{ - /* Tell Fast486 to move the instruction pointer */ - Fast486ExecuteAt(&EmulatorContext, Segment, Offset); -} - -VOID EmulatorStep(VOID) -{ - /* Dump the state for debugging purposes */ - // Fast486DumpState(&EmulatorContext); - - /* Execute the next instruction */ - Fast486StepInto(&EmulatorContext); -} - -VOID EmulatorSimulate(VOID) -{ - if (CpuCallLevel > MaxCpuCallLevel) - { - DisplayMessage(L"Too many CPU levels of recursion (%d, expected maximum %d)", - CpuCallLevel, MaxCpuCallLevel); - - /* Stop the VDM */ - EmulatorTerminate(); - return; - } - CpuCallLevel++; - - CpuSimulate = TRUE; - while (VdmRunning && CpuSimulate) ClockUpdate(); - - CpuCallLevel--; - if (CpuCallLevel < 0) CpuCallLevel = 0; - - /* This takes into account for reentrance */ - CpuSimulate = TRUE; -} - -VOID EmulatorUnsimulate(VOID) -{ - /* Stop simulation */ - CpuSimulate = FALSE; -} - VOID EmulatorTerminate(VOID) { /* Stop the VDM */ @@ -250,11 +201,6 @@ static VOID WINAPI EmulatorDebugBreakBop(LPWORD Stack) DebugBreak(); } -static VOID WINAPI EmulatorUnsimulateBop(LPWORD Stack) -{ - EmulatorUnsimulate(); -} - static BYTE WINAPI Port61hRead(ULONG Port) { return Port61hState; @@ -559,6 +505,8 @@ BOOLEAN EmulatorInitialize(HANDLE ConsoleInput, HANDLE ConsoleOutput) /* Initialize I/O ports */ /* Initialize RAM */ + /* Initialize the CPU */ + /* Initialize the internal clock */ if (!ClockInitialize()) { @@ -567,15 +515,16 @@ BOOLEAN EmulatorInitialize(HANDLE ConsoleInput, HANDLE ConsoleOutput) } /* Initialize the CPU */ - Fast486Initialize(&EmulatorContext, - EmulatorReadMemory, - EmulatorWriteMemory, - EmulatorReadIo, - EmulatorWriteIo, - NULL, - EmulatorBiosOperation, - EmulatorIntAcknowledge, - NULL /* TODO: Use a TLB */); + CpuInitialize(); + // Fast486Initialize(&EmulatorContext, + // EmulatorReadMemory, + // EmulatorWriteMemory, + // EmulatorReadIo, + // EmulatorWriteIo, + // NULL, + // EmulatorBiosOperation, + // EmulatorIntAcknowledge, + // NULL /* TODO: Use a TLB */); /* Initialize DMA */ @@ -626,9 +575,9 @@ BOOLEAN EmulatorInitialize(HANDLE ConsoleInput, HANDLE ConsoleOutput) } /* Initialize the software callback system and register the emulator BOPs */ - InitializeCallbacks(); + InitializeInt32(); RegisterBop(BOP_DEBUGGER , EmulatorDebugBreakBop); - RegisterBop(BOP_UNSIMULATE, EmulatorUnsimulateBop); + // RegisterBop(BOP_UNSIMULATE, CpuUnsimulateBop); /* Initialize VDD support */ VDDSupInitialize(); @@ -651,7 +600,7 @@ VOID EmulatorCleanup(VOID) // PitCleanup(); // PicCleanup(); - // Fast486Cleanup(); + CpuCleanup(); /* Free the memory allocated for the 16-bit address space */ if (BaseAddress != NULL) HeapFree(GetProcessHeap(), 0, BaseAddress); @@ -663,7 +612,7 @@ VOID WINAPI VDDSimulate16(VOID) { - EmulatorSimulate(); + CpuSimulate(); } VOID diff --git a/subsystems/ntvdm/emulator.h b/subsystems/ntvdm/emulator.h index b405c00355e..4b4928e3313 100644 --- a/subsystems/ntvdm/emulator.h +++ b/subsystems/ntvdm/emulator.h @@ -16,35 +16,6 @@ /* DEFINES ********************************************************************/ -/* FLAGS */ -#define EMULATOR_FLAG_CF (1 << 0) -#define EMULATOR_FLAG_PF (1 << 2) -#define EMULATOR_FLAG_AF (1 << 4) -#define EMULATOR_FLAG_ZF (1 << 6) -#define EMULATOR_FLAG_SF (1 << 7) -#define EMULATOR_FLAG_TF (1 << 8) -#define EMULATOR_FLAG_IF (1 << 9) -#define EMULATOR_FLAG_DF (1 << 10) -#define EMULATOR_FLAG_OF (1 << 11) -#define EMULATOR_FLAG_NT (1 << 14) -#define EMULATOR_FLAG_RF (1 << 16) -#define EMULATOR_FLAG_VM (1 << 17) -#define EMULATOR_FLAG_AC (1 << 18) -#define EMULATOR_FLAG_VIF (1 << 19) -#define EMULATOR_FLAG_VIP (1 << 20) -#define EMULATOR_FLAG_ID (1 << 21) - -// -// WARNING WARNING!! -// If you're changing the indices here, you then need to -// also fix the BOP code in callback.c !!!!!!!!!!!!!!!!! -// -#define STACK_INT_NUM 0 -#define STACK_IP 1 -#define STACK_CS 2 -#define STACK_FLAGS 3 - - /* Basic Memory Management */ #define MEM_ALIGN_UP(ptr, align) MEM_ALIGN_DOWN((ULONG_PTR)(ptr) + (align) - 1l, (align)) #define MEM_ALIGN_DOWN(ptr, align) (PVOID)((ULONG_PTR)(ptr) & ~((align) - 1l)) @@ -92,7 +63,7 @@ enum EMULATOR_EXCEPTION_PAGE_FAULT }; -extern FAST486_STATE EmulatorContext; +// extern FAST486_STATE EmulatorContext; extern LPVOID BaseAddress; extern BOOLEAN VdmRunning; @@ -123,10 +94,6 @@ UCHAR WINAPI EmulatorIntAcknowledge VOID EmulatorException(BYTE ExceptionNumber, LPWORD Stack); -VOID EmulatorExecute(WORD Segment, WORD Offset); -VOID EmulatorStep(VOID); -VOID EmulatorSimulate(VOID); -VOID EmulatorUnsimulate(VOID); VOID EmulatorTerminate(VOID); VOID EmulatorInterrupt(BYTE Number); diff --git a/subsystems/ntvdm/hardware/vga.c b/subsystems/ntvdm/hardware/vga.c index 4b96de0963b..2200c574981 100644 --- a/subsystems/ntvdm/hardware/vga.c +++ b/subsystems/ntvdm/hardware/vga.c @@ -1914,8 +1914,28 @@ VOID VgaResetPalette(VOID) PaletteChanged = TRUE; } +VOID VgaWriteFont(UINT FontNumber, CONST UCHAR *FontData, UINT Height) +{ + UINT i, j; + PUCHAR FontMemory = (PUCHAR)&VgaMemory[VGA_BANK_SIZE * VGA_FONT_BANK + (FontNumber * VGA_FONT_SIZE)]; + ASSERT(Height <= VGA_MAX_FONT_HEIGHT); + for (i = 0 ; i < VGA_FONT_CHARACTERS; i++) + { + /* Write the character */ + for (j = 0; j < Height; j++) + { + FontMemory[i * VGA_MAX_FONT_HEIGHT + j] = FontData[i * Height + j]; + } + + /* Clear the unused part */ + for (j = Height; j < VGA_MAX_FONT_HEIGHT; j++) + { + FontMemory[i * VGA_MAX_FONT_HEIGHT + j] = 0; + } + } +} VOID ScreenEventHandler(PWINDOW_BUFFER_SIZE_RECORD ScreenEvent) { diff --git a/subsystems/ntvdm/hardware/vga.h b/subsystems/ntvdm/hardware/vga.h index 51ecb04c5be..6c99fb9a538 100644 --- a/subsystems/ntvdm/hardware/vga.h +++ b/subsystems/ntvdm/hardware/vga.h @@ -25,6 +25,10 @@ #define VGA_DAC_TO_COLOR(x) (((x) << 2) | ((x) >> 4)) #define VGA_COLOR_TO_DAC(x) ((x) >> 2) #define VGA_INTERLACE_HIGH_BIT (1 << 13) +#define VGA_FONT_BANK 2 +#define VGA_FONT_CHARACTERS 256 +#define VGA_MAX_FONT_HEIGHT 32 +#define VGA_FONT_SIZE (VGA_FONT_CHARACTERS * VGA_MAX_FONT_HEIGHT) /* Register I/O ports */ @@ -259,6 +263,7 @@ DWORD VgaGetVideoLimitAddress(VOID); COORD VgaGetDisplayResolution(VOID); VOID VgaRefreshDisplay(VOID); VOID VgaHorizontalRetrace(VOID); +VOID VgaWriteFont(UINT FontNumber, CONST UCHAR *FontData, UINT Height); VOID VgaReadMemory(DWORD Address, LPBYTE Buffer, DWORD Size); VOID VgaWriteMemory(DWORD Address, LPBYTE Buffer, DWORD Size); VOID VgaClearMemory(VOID); diff --git a/subsystems/ntvdm/int32.c b/subsystems/ntvdm/int32.c index e139c85d44f..86bd226cd7f 100644 --- a/subsystems/ntvdm/int32.c +++ b/subsystems/ntvdm/int32.c @@ -9,30 +9,60 @@ /* INCLUDES *******************************************************************/ -// #define NDEBUG +#define NDEBUG #include "emulator.h" #include "int32.h" -#include "bop.h" +#include "cpu/bop.h" +#include /* PRIVATE VARIABLES **********************************************************/ /* * This is the list of registered 32-bit Interrupt handlers. */ -EMULATOR_INT32_PROC Int32Proc[EMULATOR_MAX_INT32_NUM] = { NULL }; +static EMULATOR_INT32_PROC Int32Proc[EMULATOR_MAX_INT32_NUM] = { NULL }; /* BOP Identifiers */ #define BOP_CONTROL 0xFF // Control BOP Handler #define BOP_CONTROL_DEFFUNC 0x00 // Default Control BOP Function + #define BOP_CONTROL_INT32 0xFF // 32-bit Interrupt dispatcher -/* 32-bit Interrupt dispatcher function code for the Control BOP Handler */ -#define BOP_CONTROL_INT32 0xFF +#define INT16_TRAMPOLINE_SIZE sizeof(ULONGLONG) // == TRAMPOLINE_SIZE + +/* 16-bit generic interrupt code for calling a 32-bit interrupt handler */ +static BYTE Int16To32[] = +{ + 0xFA, // cli + + /* Push the value of the interrupt to be called */ + 0x6A, 0xFF, // push i (patchable to 0x6A, 0xIntNum) + + /* The BOP Sequence */ +// BOP_SEQ: + 0xF8, // clc + BOP(BOP_CONTROL), // Control BOP + BOP_CONTROL_INT32, // 32-bit Interrupt dispatcher + + 0x73, 0x04, // jnc EXIT (offset +4) + + 0xFB, // sti + + // HACK: The following instruction should be HLT! + 0x90, // nop + + 0xEB, 0xF5, // jmp BOP_SEQ (offset -11) + +// EXIT: + 0x44, 0x44, // inc sp, inc sp + 0xCF, // iret +}; +const ULONG Int16To32StubSize = sizeof(Int16To32); /* PUBLIC FUNCTIONS ***********************************************************/ -VOID WINAPI Int32Dispatch(LPWORD Stack) +static VOID WINAPI Int32Dispatch(LPWORD Stack) { /* Get the interrupt number */ BYTE IntNum = LOBYTE(Stack[STACK_INT_NUM]); @@ -41,88 +71,127 @@ VOID WINAPI Int32Dispatch(LPWORD Stack) if (Int32Proc[IntNum] != NULL) Int32Proc[IntNum](Stack); else - DPRINT("Unhandled 32-bit interrupt: 0x%02X, AX = 0x%04X\n", IntNum, getAX()); + DPRINT1("Unhandled 32-bit interrupt: 0x%02X, AX = 0x%04X\n", IntNum, getAX()); } -VOID WINAPI ControlBop(LPWORD Stack) +static VOID WINAPI ControlBop(LPWORD Stack) { /* Get the Function Number and skip it */ BYTE FuncNum = *(PBYTE)SEG_OFF_TO_PTR(getCS(), getIP()); setIP(getIP() + 1); - if (FuncNum == BOP_CONTROL_INT32) - Int32Dispatch(Stack); - else - DPRINT("Unassigned Control BOP Function: 0x%02X\n", FuncNum); + switch (FuncNum) + { + case BOP_CONTROL_INT32: + Int32Dispatch(Stack); + break; + + default: + // DPRINT1("Unassigned Control BOP Function: 0x%02X\n", FuncNum); + DisplayMessage(L"Unassigned Control BOP Function: 0x%02X", FuncNum); + break; + } } -VOID InitializeInt32(WORD BiosSegment) +ULONG +RegisterInt16(IN ULONG FarPtr, + IN BYTE IntNumber, + IN LPBYTE CallbackCode, + IN SIZE_T CallbackSize, + OUT PSIZE_T CodeSize OPTIONAL) { - // - // WARNING WARNING!! - // - // If you modify the code stubs here, think also - // about updating them in callback.c too!! - // + /* Get a pointer to the IVT and set the corresponding entry (far pointer) */ + LPDWORD IntVecTable = (LPDWORD)SEG_OFF_TO_PTR(0x0000, 0x0000); + IntVecTable[IntNumber] = FarPtr; - LPDWORD IntVecTable = (LPDWORD)BaseAddress; - LPBYTE BiosCode = (LPBYTE)SEG_OFF_TO_PTR(BiosSegment, 0); - USHORT i; - WORD BopSeqOffset, Offset = 0; + /* Register the 16-bit callback */ + return RegisterCallback16(FarPtr, + CallbackCode, + CallbackSize, + CodeSize); +} - /* Generate ISR stubs and fill the IVT */ - for (i = 0x00; i <= 0xFF; i++) +ULONG +RegisterInt32(IN ULONG FarPtr, + IN BYTE IntNumber, + IN EMULATOR_INT32_PROC IntHandler, + OUT PSIZE_T CodeSize OPTIONAL) +{ + /* Array for holding our copy of the 16-bit interrupt callback */ + BYTE IntCallback[sizeof(Int16To32)/sizeof(BYTE)]; + + /* Check whether the 32-bit interrupt was already registered */ +#if 0 + if (Int32Proc[IntNumber] != NULL) { - Offset = INT_HANDLER_OFFSET + (i << 4); - IntVecTable[i] = MAKELONG(Offset, BiosSegment); - - BiosCode[Offset++] = 0xFA; // cli - - BiosCode[Offset++] = 0x6A; // push i - BiosCode[Offset++] = (UCHAR)i; - - BopSeqOffset = COMMON_STUB_OFFSET - (Offset + 3); - - BiosCode[Offset++] = 0xE9; // jmp near BOP_SEQ - BiosCode[Offset++] = LOBYTE(BopSeqOffset); - BiosCode[Offset++] = HIBYTE(BopSeqOffset); + DPRINT1("RegisterInt32: Interrupt 0x%02X already registered!\n", IntNumber); + return 0; } +#endif - /* Write the common stub code */ - Offset = COMMON_STUB_OFFSET; + /* Register the 32-bit interrupt handler */ + Int32Proc[IntNumber] = IntHandler; -// BOP_SEQ: - BiosCode[Offset++] = 0xF8; // clc + /* Copy the generic 16-bit interrupt callback and patch it */ + RtlCopyMemory(IntCallback, Int16To32, sizeof(Int16To32)); + IntCallback[2] = IntNumber; - BiosCode[Offset++] = LOBYTE(EMULATOR_BOP); // BOP sequence - BiosCode[Offset++] = HIBYTE(EMULATOR_BOP); - BiosCode[Offset++] = BOP_CONTROL; // Control BOP - BiosCode[Offset++] = BOP_CONTROL_INT32; // 32-bit Interrupt dispatcher + /* Register the 16-bit interrupt callback */ + return RegisterInt16(FarPtr, + IntNumber, + IntCallback, + sizeof(IntCallback), + CodeSize); +} - BiosCode[Offset++] = 0x73; // jnc EXIT (offset +4) - BiosCode[Offset++] = 0x04; +VOID +Int32Call(IN PCALLBACK16 Context, + IN BYTE IntNumber) +{ + /* + * TODO: This function has almost the same code as RunCallback16. + * Something that may be nice is to have a common interface to + * build the trampoline... + */ - BiosCode[Offset++] = 0xFB; // sti + PUCHAR TrampolineBase = (PUCHAR)FAR_POINTER(Context->TrampolineFarPtr); + PUCHAR Trampoline = TrampolineBase; + UCHAR OldTrampoline[INT16_TRAMPOLINE_SIZE]; - // HACK: The following instruction should be HLT! - BiosCode[Offset++] = 0x90; // nop + DPRINT("Int32Call(0x%02X)\n", IntNumber); - BiosCode[Offset++] = 0xEB; // jmp BOP_SEQ (offset -11) - BiosCode[Offset++] = 0xF5; + ASSERT(Context->TrampolineSize == INT16_TRAMPOLINE_SIZE); -// EXIT: - BiosCode[Offset++] = 0x44; // inc sp - BiosCode[Offset++] = 0x44; // inc sp + /* Save the old trampoline */ + ((PULONGLONG)&OldTrampoline)[0] = ((PULONGLONG)TrampolineBase)[0]; - BiosCode[Offset++] = 0xCF; // iret + /* Build the generic entry-point for 16-bit calls */ + if (IntNumber == 0x03) + { + /* We are redefining for INT 03h */ + *Trampoline++ = 0xCC; // Call INT 03h + /** *Trampoline++ = 0x90; // nop **/ + } + else + { + /* Normal interrupt */ + *Trampoline++ = 0xCD; // Call INT XXh + *Trampoline++ = IntNumber; + } + UnSimulate16(Trampoline); + /* Perform the call */ + Call16(HIWORD(Context->TrampolineFarPtr), + LOWORD(Context->TrampolineFarPtr)); + + /* Restore the old trampoline */ + ((PULONGLONG)TrampolineBase)[0] = ((PULONGLONG)&OldTrampoline)[0]; +} + +VOID InitializeInt32(VOID) +{ /* Register the Control BOP */ RegisterBop(BOP_CONTROL, ControlBop); } -VOID RegisterInt32(BYTE IntNumber, EMULATOR_INT32_PROC IntHandler) -{ - Int32Proc[IntNumber] = IntHandler; -} - /* EOF */ diff --git a/subsystems/ntvdm/int32.h b/subsystems/ntvdm/int32.h index d6cced23348..d9dc9f8c774 100644 --- a/subsystems/ntvdm/int32.h +++ b/subsystems/ntvdm/int32.h @@ -10,21 +10,39 @@ #ifndef _INT32_H_ #define _INT32_H_ +/* INCLUDES *******************************************************************/ + +#include "cpu/callback.h" + /* DEFINES ********************************************************************/ /* 32-bit Interrupt Identifiers */ #define EMULATOR_MAX_INT32_NUM 0xFF + 1 -#define INT_HANDLER_OFFSET 0x1000 -#define COMMON_STUB_OFFSET 0x2000 +extern const ULONG Int16To32StubSize; /* FUNCTIONS ******************************************************************/ typedef VOID (WINAPI *EMULATOR_INT32_PROC)(LPWORD Stack); -VOID WINAPI Int32Dispatch(LPWORD Stack); -VOID InitializeInt32(WORD BiosSegment); -VOID RegisterInt32(BYTE IntNumber, EMULATOR_INT32_PROC IntHandler); +ULONG +RegisterInt16(IN ULONG FarPtr, + IN BYTE IntNumber, + IN LPBYTE CallbackCode, + IN SIZE_T CallbackSize, + OUT PSIZE_T CodeSize OPTIONAL); + +ULONG +RegisterInt32(IN ULONG FarPtr, + IN BYTE IntNumber, + IN EMULATOR_INT32_PROC IntHandler, + OUT PSIZE_T CodeSize OPTIONAL); + +VOID +Int32Call(IN PCALLBACK16 Context, + IN BYTE IntNumber); + +VOID InitializeInt32(VOID); #endif // _INT32_H_ diff --git a/subsystems/ntvdm/registers.c b/subsystems/ntvdm/registers.c index d3d5ce16675..57aca7faae4 100644 --- a/subsystems/ntvdm/registers.c +++ b/subsystems/ntvdm/registers.c @@ -11,24 +11,10 @@ #define NDEBUG #include "emulator.h" +#include "cpu/cpu.h" /* PUBLIC FUNCTIONS ***********************************************************/ -static inline BOOLEAN EmulatorGetFlag(ULONG Flag) -{ - return (EmulatorContext.Flags.Long & Flag) ? TRUE : FALSE; -} - -static inline VOID EmulatorSetFlag(ULONG Flag) -{ - EmulatorContext.Flags.Long |= Flag; -} - -static inline VOID EmulatorClearFlag(ULONG Flag) -{ - EmulatorContext.Flags.Long &= ~Flag; -} - VOID EmulatorSetStack(WORD Segment, DWORD Offset) { Fast486SetStack(&EmulatorContext, Segment, Offset); @@ -405,7 +391,7 @@ VOID WINAPI setEIP(ULONG Value) { - EmulatorExecute(getCS(), Value); + CpuExecute(getCS(), Value); } USHORT @@ -419,7 +405,7 @@ VOID WINAPI setIP(USHORT Value) { - EmulatorExecute(getCS(), Value); + CpuExecute(getCS(), Value); } @@ -514,136 +500,112 @@ ULONG WINAPI getCF(VOID) { - return EmulatorGetFlag(EMULATOR_FLAG_CF); + return EmulatorContext.Flags.Cf; } VOID WINAPI setCF(ULONG Flag) { - if (Flag & 1) - EmulatorSetFlag(EMULATOR_FLAG_CF); - else - EmulatorClearFlag(EMULATOR_FLAG_CF); + EmulatorContext.Flags.Cf = !!(Flag & 1); } ULONG WINAPI getPF(VOID) { - return EmulatorGetFlag(EMULATOR_FLAG_PF); + return EmulatorContext.Flags.Pf; } VOID WINAPI setPF(ULONG Flag) { - if (Flag & 1) - EmulatorSetFlag(EMULATOR_FLAG_PF); - else - EmulatorClearFlag(EMULATOR_FLAG_PF); + EmulatorContext.Flags.Pf = !!(Flag & 1); } ULONG WINAPI getAF(VOID) { - return EmulatorGetFlag(EMULATOR_FLAG_AF); + return EmulatorContext.Flags.Af; } VOID WINAPI setAF(ULONG Flag) { - if (Flag & 1) - EmulatorSetFlag(EMULATOR_FLAG_AF); - else - EmulatorClearFlag(EMULATOR_FLAG_AF); + EmulatorContext.Flags.Af = !!(Flag & 1); } ULONG WINAPI getZF(VOID) { - return EmulatorGetFlag(EMULATOR_FLAG_ZF); + return EmulatorContext.Flags.Zf; } VOID WINAPI setZF(ULONG Flag) { - if (Flag & 1) - EmulatorSetFlag(EMULATOR_FLAG_ZF); - else - EmulatorClearFlag(EMULATOR_FLAG_ZF); + EmulatorContext.Flags.Zf = !!(Flag & 1); } ULONG WINAPI getSF(VOID) { - return EmulatorGetFlag(EMULATOR_FLAG_SF); + return EmulatorContext.Flags.Sf; } VOID WINAPI setSF(ULONG Flag) { - if (Flag & 1) - EmulatorSetFlag(EMULATOR_FLAG_SF); - else - EmulatorClearFlag(EMULATOR_FLAG_SF); + EmulatorContext.Flags.Sf = !!(Flag & 1); } ULONG WINAPI getIF(VOID) { - return EmulatorGetFlag(EMULATOR_FLAG_IF); + return EmulatorContext.Flags.If; } VOID WINAPI setIF(ULONG Flag) { - if (Flag & 1) - EmulatorSetFlag(EMULATOR_FLAG_IF); - else - EmulatorClearFlag(EMULATOR_FLAG_IF); + EmulatorContext.Flags.If = !!(Flag & 1); } ULONG WINAPI getDF(VOID) { - return EmulatorGetFlag(EMULATOR_FLAG_DF); + return EmulatorContext.Flags.Df; } VOID WINAPI setDF(ULONG Flag) { - if (Flag & 1) - EmulatorSetFlag(EMULATOR_FLAG_DF); - else - EmulatorClearFlag(EMULATOR_FLAG_DF); + EmulatorContext.Flags.Df = !!(Flag & 1); } ULONG WINAPI getOF(VOID) { - return EmulatorGetFlag(EMULATOR_FLAG_OF); + return EmulatorContext.Flags.Of; } VOID WINAPI setOF(ULONG Flag) { - if (Flag & 1) - EmulatorSetFlag(EMULATOR_FLAG_OF); - else - EmulatorClearFlag(EMULATOR_FLAG_OF); + EmulatorContext.Flags.Of = !!(Flag & 1); } diff --git a/subsystems/ntvdm/vddsup.c b/subsystems/ntvdm/vddsup.c index 92a0ff1ac3b..0997216c08a 100644 --- a/subsystems/ntvdm/vddsup.c +++ b/subsystems/ntvdm/vddsup.c @@ -13,8 +13,7 @@ #include "emulator.h" #include "vddsup.h" -#include "bop.h" - +#include "cpu/bop.h" #include typedef VOID (WINAPI *VDD_PROC)(VOID); diff --git a/win32ss/gdi/eng/ldevobj.c b/win32ss/gdi/eng/ldevobj.c index 2dcac3fb704..ff7fea01501 100644 --- a/win32ss/gdi/eng/ldevobj.c +++ b/win32ss/gdi/eng/ldevobj.c @@ -292,6 +292,7 @@ LDEVOBJ_pvFindImageProcAddress( pExportDir = pldev->pGdiDriverInfo->ExportSectionPointer; if (!pExportDir) { + ERR("LDEVOBJ_pvFindImageProcAddress: no export section found\n"); return NULL; } diff --git a/win32ss/gdi/ntgdi/dcobjs.c b/win32ss/gdi/ntgdi/dcobjs.c index 4772e9456df..72b34c25a85 100644 --- a/win32ss/gdi/ntgdi/dcobjs.c +++ b/win32ss/gdi/ntgdi/dcobjs.c @@ -318,6 +318,28 @@ NtGdiSelectPen( return hOrgPen; } +BOOL +NTAPI +DC_bIsBitmapCompatible(PDC pdc, PSURFACE psurf) +{ + ULONG cBitsPixel; + + /* Must be an API bitmap */ + if (!(psurf->flags & API_BITMAP)) return FALSE; + + /* DIB sections are always compatible */ + if (psurf->hSecure != NULL) return TRUE; + + /* Get the bit depth of the bitmap */ + cBitsPixel = gajBitsPerFormat[psurf->SurfObj.iBitmapFormat]; + + /* 1 BPP is compatible */ + if ((cBitsPixel == 1) || (cBitsPixel == pdc->ppdev->gdiinfo.cBitsPixel)) + return TRUE; + + return FALSE; +} + /* * @implemented */ @@ -332,7 +354,6 @@ NtGdiSelectBitmap( PSURFACE psurfNew, psurfOld; PREGION VisRgn; HDC hdcOld; - ULONG cBitsPixel; ASSERT_NOGDILOCKS(); /* Verify parameters */ @@ -395,10 +416,7 @@ NtGdiSelectBitmap( } /* Check if the bitmap is compatile with the dc */ - cBitsPixel = gajBitsPerFormat[psurfNew->SurfObj.iBitmapFormat]; - if ((cBitsPixel != 1) && - (cBitsPixel != pdc->ppdev->gdiinfo.cBitsPixel) && - (psurfNew->hSecure == NULL)) + if (!DC_bIsBitmapCompatible(pdc, psurfNew)) { /* Dereference the bitmap, unlock the DC and fail. */ SURFACE_ShareUnlockSurface(psurfNew); diff --git a/win32ss/reactx/ntddraw/eng.c b/win32ss/reactx/ntddraw/eng.c index 529ada6b4c0..47bb4367396 100644 --- a/win32ss/reactx/ntddraw/eng.c +++ b/win32ss/reactx/ntddraw/eng.c @@ -122,7 +122,7 @@ EngFreePrivateUserMem(PDD_SURFACE_LOCAL psl, * This function is no longer used in Windows NT 2000/XP/2003 * *--*/ -DWORD +HRESULT APIENTRY EngDxIoctl(ULONG ulIoctl, PVOID pBuffer,