Commit graph

412 commits

Author SHA1 Message Date
Mas Ahmad Muhammad b8dd046ee4
[TRANSLATION] Add and update Indonesian translations (#2506)
- CMDUTILS: attrib, label (update translation)
- USETUP (add translation)
- HOTPLUG (add translation)
- CONSRV  (update translation)
- USERSRV (update translation)
- USER32  (update translation)
- ACLUI  (update translation)
- LICCPA  (update translation)
- SUBST  (update translation)
- REGSVR32  (update translation)
- REGEDIT-CLB  (update translation)
- ACPPAGE  (update translation)
- TIMEDATE  (update translation)
- SOLITAIRE  (update translation)
- FDEBUG  (update translation)
- SYSSETUP (update translation)
2020-04-09 18:49:45 +02:00
Julen Urizar Compains f7cab5a1d4
[TRANSLATION] Multiple minor fixes and addings. (#2516)
- Applications: eventvwr, fltmgr, servman.
- rosapps: arping, CTM, fontsub, fraginator, imagesoft, systeminfo, vcdcontroltool, vgafontedit.
- CPLs: desk.cpl.
- ReactOS Setup GUI app.
- Screensavers: butterflies, maze, Starfield.
- System: NTVDM, printing/monitors/localmon; the freeze dialog in user32, the error strings in usersrv.
2020-04-09 18:13:46 +02:00
Joachim Henze 1fdf06c563 [USETUP] de-DE Whitespace nitpicking CORE-16792
To harmonize it to 3 separator-spaces how it is done
historically in other dlgs.
2020-04-06 21:28:45 +02:00
Joachim Henze 75edf1071a [USETUP] de-DE Fix typo CORE-16792
Fix typo in my last changeset
0.4.14-dev-1323-g
d079342e0a
2020-04-06 20:55:18 +02:00
Joachim Henze d079342e0a [USETUP] de-DE Overhaul german translation CORE-16792 2020-04-06 20:49:44 +02:00
Joachim Henze 7ed0701983 [USETUP] de-DE Split a line of text into two parts CORE-16791 2020-04-06 17:11:45 +02:00
Julen Urizar Compains d6e0fe78e7
[TRANSLATION] Updating Spanish translation (#2503)
Updating translation for:
notepad, reactos, usetup, explorer, netshell, msgina, setupapi, shell32.

- Complete and Fix the SPANISH TRANSLATION on Setup
- Correct the random names, fixing the denominations, translate of the English words, and fixing random and incorrect denominations like "Cabinet" or "distribuciones".
- Fixed the notepad shortcuts of "Save" (Ctrl+g) and "Replace".
2020-04-06 13:17:20 +02:00
Julen Urizar Compains 58d2b1f3f6
[TRANSLATION][USETUP] Update Spanish translation of USetup. (#2497)
Correct the random names, fixing the denominations, translate of the English words, and fixing random and incorrect denominations like "Cabinet" or "distribuciones".
2020-04-04 13:10:34 +02:00
Tibor Lajos Füzi 432a5ddc7f
[TRANSLATION] Update Hungarian translation of usetup, syssetup, explorer, netshell, userenv, shortcuts (#2442) 2020-03-20 17:52:46 +01:00
Serge Gautherie c8dd5e7720
[USETUP] Fix ' \n' typos, in *.h (#2415)
Addendum to PR #2387.
2020-03-07 00:51:13 +01:00
Serge Gautherie 92aabb07fb
[REACTOS] Fix remaining ' \n' typos, in *.rc (#2393)
Addendum to commit 554c41e4 (#2387).
Co-authored-by: Hermès BÉLUSCA - MAÏTO <hermes.belusca-maito@reactos.org>
2020-03-06 19:08:25 +01:00
Katayama Hirofumi MZ b539dd1c5a
[USETUP][BOOTDATA] Include optional CJK standard fonts (#2336)
This PR enables the developers to include the CJK standard fonts into ReactOS by adding them in Folder modules/optional. This feature is for test purpose only. You may not use the fonts illegally.
The embeddable font files are: mingliu.ttc, simsun.ttc, mssong.ttf, msgothic.ttc, msmincho.ttc, gulim.ttc and batang.ttc.
CORE-9619
2020-02-14 10:47:20 +09:00
Bișoc George dac560f81a [USETUP] Remove redundant TEXT_STYLE_NORMAL flag on empty MUI entry field (#2275) 2020-01-26 17:38:58 +01:00
Hervé Poussineau 043ce2c832 [SETUPLIB] Fix possible out-of-bound buffer if BootStore->Type is unknown/invalid 2020-01-22 20:57:38 +01:00
Bișoc George 2bf4180c80 [USETUP] Implement resource ID text based strings for MUI (#2193)
CORE-12683

Supersedes PR #612.

* [USETUP] Implement the internal MUI routines for text manipulation based on its ID and implement text resource based IDs

USETUP (the 1st stage text mode setup module) bases upon MUI (Multilingual User Interface) sub-component of USETUP which is responsible for the ability into translating the MUI pages (each page having corresponding properties like X, Y coordinates, text flags and text string buffer) in various languages.
The only problem, as of now, is that whenever you want to modify a certain property of a page, such as removing a text from the said page in the screen, you've got to rely on using CONSOLE_* specific functions and calling with hardcoded parameters, namely the coordinates.

This can become a problem as not every localized (translated) MUI page has the same properties for each language and this could lead to various issues. Therefore, assigning each entry with an ID you can remove a text by only giving its ID (and the entry page number) without having the need to specify the coordinates
as the internal MUI routine, MUIGetEntry(), automatically retrieves the entry with respective data fields.

The following commit implements:

- MUIGetEntry()
- MUIClearText()
- MUIClearStyledText()
- MUISetText()
- MUISetStyledText()
- Now the X and Y coordinate members of MUI_ENTRY are of SHORT integer type, for the sake of the general code as most of the coordination values, even the COORD structure itself, has the coordination points as SHORTs and not BYTEs.

The following MUI functions will be used to manipulate text based resources depending on their ID from the corresponding MUI entry.

* [USETUP] Make CONSOLE_ClearTextXY function public so that we can use across other files.

* [USETUP] Implement the IDs for each text MUI entry in locale files.

This mechanism follows the same principle of resource IDs in Win32 applications. Static text is merely a resource that doesn't get changed programmatically for whole of its lifetime whereas dynamic resources can change during the lifetime of the program depending on the algorithm (for example, hide that piece of text and set another one, etc.).

* [USETUP] Remove the "Press ENTER to continue" message prompt when the partition formatting begins.
2020-01-19 17:58:13 +01:00
Timo Kreuzer e084a7ae83 [SETUP] Don't free a DLL that is still in use by a different thread 2020-01-03 11:32:07 +01:00
Hermès Bélusca-Maïto 51cb3cc6b2
[SETUPLIB] Register the \DosDevices\?: drive letter from installation time in the correct SYSTEM\MountedDevices registry key, i.e. the one of the ReactOS being currently installed.
CORE-15575

However I now hit a separate bug (see the report) that still prevent the
drive letter to be correctly assigned at reboot.
2019-12-26 17:16:14 +01:00
Hermès Bélusca-Maïto bfd8a84865
[BLUE] Improve initialization and interfacing with INBV.
CORE-15901

This fixes display reset transition when an external module acquired
INBV ownership and then released it, similarly to what was done in
commit 0ad65796 for VIDEOPRT.

For this a backup screenbuffer is used to store the contents of the
screen just before an INBV screen acquire transition, and these contents
are restored when it is detected that INBV ownership has been released.
Also, the active text font associated with the active console code-page
is restored, as well as the cursor state and shape.

In addition, any user of BLUE.SYS is now required to explicitly issue
a new IOCTL_CONSOLE_RESET_SCREEN to either enable or disable the screen.
This allows avoiding nasty unwanted screen mode switches when a handle
to the \Device\BlueScreen device is opened but no screen mode switch was
actually wanted - This "fixes" this annoyance on ReactOS and Windows,
when these are running witha VGA-compatible video driver and one wants
to look at properties of the \Device\BlueScreen device using
Sysinternals' WinObj.

Following this, we don't need to check anymore for explicit INBV
ownership by issuing calls to InbvCheckDisplayOwnership(), but instead
we check whether the screen has beeen manually enabled using the
aforementioned IOCTL. This partly supersedes commit 8b553a4b, and allows
fixing the second bug, namely that if we start ReactOS without the
/NOGUIBOOT option (and thus, INBV is active during boot), USETUP would
not show up anything because BLUE.SYS wouldn't display anything on screen.
See CORE-15901.

[USETUP][CONSRV] Call IOCTL_CONSOLE_RESET_SCREEN to tell BlueScreen device to enable the screen.
2019-12-15 03:37:52 +01:00
Serge Gautherie 99f8ccdc7f [SETUPLIB] Fix 'MAX_USHORT' typo in a comment (#2144) 2019-12-10 13:16:46 +01:00
Tibor Lajos Füzi 74ec76df08 [TRANSLATION] Fix hungarian translation for usetup & syssetup to use formal addressing / conjugation (#2138) 2019-12-09 02:09:31 +01:00
Tibor Lajos Füzi a3398a8e80 [USETUP] Hungarian translation fix (#2026) 2019-11-10 23:36:51 +01:00
Tibor Lajos Füzi dde7113cfc [USETUP] Hungarian translation (#2002) 2019-10-28 15:26:30 +01:00
Robert Naumann ffa8ff7574 [SETUP/LIB] Fix wrong if() logic. CID1441307 2019-10-23 17:23:05 +02:00
Katayama Hirofumi MZ 92443b4444
[USETUP] Improve Japanese translation (#1918) 2019-09-21 23:07:07 +09:00
Adam Słaboń c81af08f51 [TRANSLATION] Polish translation update (#1916)
Added translation for netstat, utilman and netplwiz. Updated translation of find, reg, rapps, regedit, sndvol32, usetup, hivesys, mmsys, openglcfg, powercfg, sysdm, shellext, browseui, devmgr, msgina, netcfgx, shell32, syssetup, shortcuts and vcdcontroltool.
2019-09-20 21:51:47 +02:00
Timo Kreuzer 85616bc8b2 [SETUP] Add support for archtitcure specific inf sections and use it for x64 computer type 2019-09-08 10:42:16 +02:00
Katayama Hirofumi MZ bfea773ee5 [SETUPLIB][USETUP] Fix build about switch 2019-08-25 12:07:31 +09:00
Hermès Bélusca-Maïto 59acff79e5
[SETUPLIB][USETUP] Slightly modify how and when the HW system partition is detected and used.
CORE-16274

SETUPLIB:
=========

- Find the system partition initially when we create the list of
  partitions.

- Split the old CheckActiveSystemPartition() helper in two helpers:
  FindSupportedSystemPartition() and SetActivePartition(). This allows
  simplifying slightly the former one, and allows the user, in an
  interactive situation, to decide whether the "supported system
  partition" found can actually be used or not.

- Remove the "OriginalSystemPartition" hack in the PARTLIST structure.
- Add a note regarding the SystemPartition member in PARTLIST.

USETUP:
=======

- Use the introduced helpers from above. If the "system" partition we
  are going to use, in case we install ReactOS on a fixed disk, is *NOT*
  the same as the original one (e.g. because it is detected to be not
  supported by ReactOS...), display an informative screen to the user
  and let him confirm whether or not he wants to change the partition.

If we install on a fixed disk, try to find a supported system partition
on the system. Otherwise if we install on a removable disk, use the
install partition as the system partition instead.

This allows providing a fix for CORE-16274.
2019-08-25 02:38:53 +02:00
Hermès Bélusca-Maïto 626c654a10
[SETUPLIB][USETUP] Code simplifications & fixes.
SETUPLIB:
=========

- Remove useless HiddenSectors member in PARTENTRY structure.
- InsertDiskRegion() helper returns a BOOLEAN success.
- CreateInsertBlankRegion() helper sets LogicalPartition.

- Simplify the InitializePartitionEntry() helper so that its PartEntry
  parameter is clearly the one that is being initialized (i.e. converted
  from a blank region to) an actual partition, and use the helper
  CreateInsertBlankRegion(). The calculations for the StartSector and
  SectorCount are exactly equivalent with the old version of this
  function. Also make it return a BOOLEAN success instead.
  + Add some extra validation checks.
  + Adjust CreatePrimaryPartition(), CreateExtendedPartition() and
    CreateLogicalPartition() in this regard.

- Better handling of "RAW"-mounted partitions: treat them as
  "Unformatted" only if they are RAW *AND* their PartitionType is one of
  those associated with FAT file-system. Otherwise we cannot decide
  whether they are indeed unformatted or have an unknown file-system on
  them, therefore treat them as the latter.
  In this regard, the IsSupportedActivePartition() helper should not
  look for FileSystem == RAW but instead only look whether the partition
  is Unformatted.

  This should help with situations similar to the one described in CORE-16274
  where a partition with a genuine file-system but not recognized by
  ReactOS (because we currently do not have the EXT2/3/4 filesystem
  driver loaded during 1st-stage setup due to commit 5a650f6b) and
  therefore mounted as RAW, was thought to be unformatted.

USETUP:
=======
- Use the "global" SystemPartition pointer: this is the "system"
  partition we will actually use. It can be different from the actual
  one of the computer, for example when we install ReactOS on a
  removable disk. This allows also to simplify the code.

- Remove the single-used DestinationDriveLetter variable.

- Remove BuildInstallPaths() helper and use InitDestinationPaths()
  directly instead.

- Always mention the disk where the partition being formatted is.
- Cleanup old code comments, add assertions here & there...
2019-08-25 02:38:52 +02:00
Bișoc George 2fbff73792 [USETUP] Localize the rest of the hardcoded error message strings 2019-08-17 21:34:39 +02:00
Timo Kreuzer 7611cc2b12 [REACTOS] Fix SIZE_T related warnings 2019-08-15 14:20:00 +02:00
Katayama Hirofumi MZ 10c08e1d62
[SETUP][BOOTDATA][INF] Helvetica-to-Arial substitutes (#1809)
Set the destinations of "Helvetica" font substitutes to "Arial". CORE-16264
2019-08-07 19:02:38 +09:00
Katayama Hirofumi MZ 257aed0e69
[SETUP][BOOTDATA][INF] Delete Tahoma-to-Tahoma substitutes (#1808)
Delete loopy Tahoma-to-Tahoma font substitutes. CORE-16264
2019-08-07 19:01:25 +09:00
Katayama Hirofumi MZ 3f1ab92d3a
[SETUP][INF] Helvetica must be substitute to Arial font (#1803)
Helvetica must be font substitute to Arial font.

- Change some Helvetica substitutes to "Arial" from "Liberation Sans". Not all Helvetica. Some languages are lacking support.
2019-08-05 19:55:00 +09:00
Katayama Hirofumi MZ 5bbc2c6308
[SETUP][INF] Fix font substitutes (#1794)
Fix font substitutes. CORE-16264

- Modify muifonts.h.
- Modify font.inf.
2019-08-04 16:10:15 +09:00
Katayama Hirofumi MZ dc1aa8010a
[FONTS][SETUP][BOOTDATA] Add Lucida Console font (#1793)
Add "Lucida Console" fonts. CORE-16264

- Add "Lucida Console" font by duplicating "DejaVu Sans Mono" font and renaming it.
- Delete some "Lucida Console" font substitutes.
- Add LICENSE file.

I used FontForge to rename it. Its family name is "Lucida Console". Its display name is "Lucida Console". Its font filename is lucon.ttf. The Underline Positions are hacked by adding an integer value for workaround of FontForge's bug.
2019-08-04 15:38:45 +09:00
Katayama Hirofumi MZ 04a361d091
[FONTS][SETUP] Add Trebuchet MS fonts (#1791)
Add "Trebuchet MS" fonts. CORE-16272

- Add "Trebuchet MS", "Trebuchet MS Bold", "Trebuchet MS Bold Italic" and "Trebuchet MS Italic" fonts by duplicating "Open Sans" fonts and renaming them.
- Delete some "Trebuchet MS" font substitutes.
- Add LICENSE file.

I made these font files by using FontForge. Their family name is "Trebuchet MS". Their display names are "Trebuchet MS", "Trebuchet MS Bold", "Trebuchet MS Bold Italic" and "Trebuchet MS Italic". Their font filenames are trebuc.ttf, trebucbd.ttf, trebucbi.ttf and trebucit.ttf. The Underline Positions are hacked by adding an integer value for workaround of FontForge's bug.
2019-08-04 12:11:55 +09:00
Katayama Hirofumi MZ dbb4432b25
[FONTS][SETUP][BOOTDATA] Add Times New Roman fonts (#1790)
Add "Times New Roman" fonts. CORE-16272

- Add "Times New Roman" and "Times New Roman Italic" fonts by duplicating "Liberation Serif" fonts and renaming them.
- Delete some "Times New Roman" font substitutes.
- Add LICENSE file.

I made these font files by using FontForge. Their family name is "Times New Roman". Their display names are "Times New Roman", "Times New Roman Bold", "Times New Roman Bold Italic" and "Times New Roman Italic". Their font filenames are times.ttf, timesbd.ttf, timesbi.ttf and timesi.ttf. The Underline Positions are hacked by adding an integer value for workaround of FontForge's bug.
2019-08-04 11:22:51 +09:00
Katayama Hirofumi MZ 23faa89d09
[FONTS][SETUP] Add Franklin Gothic Medium fonts (#1786)
Add "Franklin Gothic Medium" fonts. CORE-16272

- Add "Franklin Gothic Medium" and "Franklin Gothic Medium Italic" fonts by duplicating Alexei Vanyashin's "Libre Franklin" fonts and renaming them.
- Delete some "Franklin Gothic Medium" font substitutes.
- Add LICENSE file.

I made these font files by using FontForge. Their family name is "Franklin Gothic Medium". Their display names are "Franklin Gothic Medium" and "Franklin Gothic Medium Italic". Their font filenames are framd.ttf and framdit.ttf. The Underline Positions are hacked by adding an integer value for workaround of FontForge's bug.

Alexei Vanyashin's "Libre Franklin" fonts are available at https://github.com/alexeiva/Libre-Franklin .
2019-08-03 19:03:27 +09:00
Katayama Hirofumi MZ bb1878157b
[FONTS][SETUP] Add Palatino Linotype fonts (#1785)
Add "Palatino Linotype" fonts. CORE-16272

- Add "Palatino Linotype", "Palatino Linotype Bold", "Palatino Linotype Bold Italic" and "Palatino Linotype Italic" fonts by duplicating "DejaVu Serif" fonts and renaming them.
- Delete some "Palatino Linotype" font substitutes.
- Add LICENSE file.

I made these font files by using FontForge. Their family name is "Palatino Linotype". Their display names are "Palatino Linotype", "Palatino Linotype Bold", "Palatino Linotype Bold Italic" and "Palatino Linotype Italic". Their font filenames are pala.ttf, palab.ttf, palabi.ttf and palai.ttf. The Underline Positions are hacked by adding an integer value for workaround of FontForge's bug.
2019-08-03 16:24:32 +09:00
Katayama Hirofumi MZ e282f99ce5
[FONTS][SETUP] Add Geogia fonts (#1784)
Add "Geogia" fonts. CORE-16272

- Add "Geogia", "Geogia Bold", "Geogia Bold Italic" and "Geogia Italic" fonts by duplicating FreeSerif fonts and renaming them.
- Delete some "Geogia" font substitutes.
- Add LICENSE file.

I made these font files by using FontForge. Their family name is "Geogia". Their display names are "Geogia", "Geogia Bold", "Geogia Bold Italic" and "Geogia Italic". Their font filenames are georgia.ttf, georgiab.ttf, georgiaz.ttf and georgiai.ttf. The Underline Positions are hacked by adding an integer value for workaround of FontForge's bug.
2019-08-03 10:43:09 +09:00
Katayama Hirofumi MZ faa3237d46
[FONTS][BOOTDATA][SETUP] Add Courier New fonts (#1783)
Add "Courier New" fonts. CORE-16272

- Add "Courier New", "Courier New Bold", "Courier New Bold Italic" and "Courier New Italic" fonts by duplicating FreeMono fonts and renaming them.
- Delete some "Courier New" font substitutes.
- Add LICENSE file.

I made these font files by using FontForge. Their family name is "Courier New". Their display names are "Courier New", "Courier New Bold", "Courier New Bold Italic" and "Courier New Italic". Their font filenames are cour.ttf, courbd.ttf, courbi.ttf and couri.ttf. The Underline Positions are hacked by adding an integer value for workaround of FontForge's bug.
2019-08-03 09:05:14 +09:00
Katayama Hirofumi MZ 1463f4b02a
[FONTS][SETUP][BOOTDATA] Add Arial fonts (#1781)
Add Arial fonts. CORE-16272

- Add "Arial", "Arial Bold", "Arial Bold Italic" and "Arial Italic" fonts by duplicating Liberation Sans fonts and renaming them.
- Disable some Arial font substitutes.
- Add LICENSE file.

I made these font files by using FontForge. Their family name is "Arial". Their display names are "Arial", "Arial Bold", "Arial Bold Italic" and "Arial Italic". Their font filenames are arial.ttf, arialbd.ttf, arialbi.ttf and ariali.ttf. The Underline Positions are hacked by adding an integer value for workaround of FontForge's bug.
2019-08-02 20:37:53 +09:00
Katayama Hirofumi MZ 4cfe7f84bb
[SETUP] Add codepage-specific font substitutes (#1772)
Add codepage-specific font substitutes for i18n. CORE-16266
2019-07-31 17:43:08 +09:00
Katayama Hirofumi MZ f054844f33
[SETUP] Sort font substitutes (#1770)
Sort the font substitute setting lists in base/setup/lib/muifonts.h .
2019-07-30 22:05:11 +09:00
Katayama Hirofumi MZ d31e814314
[SETUP] Delete 'Comic Sans MS' font substitutes (#1769)
Enable real 'Comic Sans MS' font by deleting the 'Comic Sans MS' font substitutes. CORE-16251
2019-07-30 19:09:23 +09:00
Oleg Dubinskiy 6ee7cba77b [USETUP] Use "L" key instead of "D" for deleting partitions at 1st setup stage 2019-07-27 13:18:34 +02:00
Shy Zedaka 112127593b [TRANSLATION] Hebrew Translations For Setup (#1750) 2019-07-24 19:56:48 +02:00
Joachim Henze 5dbc677cdd [BOOTDATA][SETUP] Fix regression CORE-16200 font rendering
By removing font substitution for 'Microsoft Sans Serif'.
Thanks to the patches author Katayama Hirofumi MZ.

This is a partial revert of the guilty rev
master guilty 0.4.13-dev-9-g
811faed421

RC guilty 0.4.12-RC-13-g
8d3def0529

VBox test result:
https://reactos.org/testman/compare.php?ids=68497,68499

The same fix has been applied before to 0.4.12-RC-44-g
ca0e00e8af
2019-07-16 22:51:42 +02:00
Jose Carlos Jesus 69454b4302 [TRANSLATION] Add Portuguese (neutral) translation. (#1702)
Add Portuguese (neutral) translation for intl.cpl, main.cpl, msgina.dll, msports.dll, welcome.exe and rundll32.exe, and fix the one in mshtml.dll .
2019-07-15 00:07:50 +02:00
Mas Ahmad Muhammad e189abe754
[SETUP_WELCOME] Update Indonesian translation. 2019-06-20 17:31:53 +02:00
Mas Ahmad Muhammad d863ed20cc
[SETUP_REACTOS] Add Indonesian translation. 2019-06-20 17:31:45 +02:00
Eric Kohl 6866c0aede [NTOSKRNL][USETUP][UMPNPMGR] Pass user response data to NtPlugPlayControl(PlugPlayControlUserResponse).
- Windows requires 16 bytes of response data.
- Add the PLUGPLAY_CONTROL_USER_RESPONSE_DATA type.
- Usetup and Umpnpmgr must fail if NtPlugPlayControl(PlugPlayControlUserResponse) does not return STATUS_SUCCESS.
2019-06-12 13:48:27 +02:00
Timo Kreuzer 6129fbaf1e [USETUP] Use RtlStringCbPrintfA instead of sprintf
Fixes GCC 8 warning:
base/setup/usetup/usetup.c:3407:78: error: '%S' directive writing up to 521 bytes into a region of size 200 [-Werror=format-overflow=]
                 "Setup is currently unable to check a partition formatted in %S.\n"
                                                                              ^~
base/setup/usetup/usetup.c:3406:9: note: 'sprintf' output between 128 and 649 bytes into a destination of size 260
         sprintf(Buffer,
         ^~~~~~~~~~~~~~~
                 "Setup is currently unable to check a partition formatted in %S.\n"
                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                 "\n"
                 ~~~~
                 "  \x07  Press ENTER to continue Setup.\n"
                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                 "  \x07  Press F3 to quit Setup.",
                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                 PartEntry->FileSystem);
                 ~~~~~~~~~~~~~~~~~~~~~~
2019-05-27 13:22:40 +02:00
Jose Carlos Jesus 7f5e960e32
[TRANSLATIONS] Update/Add Portuguese translations.
Translations for: reactos/setup, usetup, syssetup, netshell, shell32.
2019-05-26 21:19:31 +02:00
Oleg Dubinskiy 3b0e093aba [SETUP] Fix controls position in 1st stage GUI setup for Russian translation 2019-05-23 23:29:46 +02:00
Jose Carlos Jesus 73d7fd1415
[TRANSLATIONS] Update/Add Portuguese translations. (#1564)
Translations for: deskadp, deskmon, reactos/setup, usetup, syssetup.

Co-Authored-By: Bișoc George <fraizeraust99@gmail.com>
2019-05-19 17:04:47 +02:00
Timo Kreuzer d2feba3d53 [TREELIST] Fix 64 bit warnings 2019-04-13 14:07:50 +02:00
Katayama Hirofumi MZ 811faed421
[GDI32][NTGDI][SETUP] Fix font enumeration part 2 (#1492)
Eliminate some bugs about font enumeration. CORE-15755

- Add "Microsoft Sans Serif" font substitution.
- Fix and improve the treatment of the nominal font names.
- Split IntGetFontFamilyInfo function from NtGdiGetFontFamilyInfo.
- Add DoFontSystemUnittest function for font system unittest to GDI32.
- Call DoFontSystemUnittest function at CreateFontIndirectW first call.
2019-04-11 11:46:52 +09:00
Adam Słaboń 7047aa80ef [TRANSLATION] Polish translation update
Polish translation update for calc, fltmc, magnify, notepad, osk, sndvol32, usetup, fdebug, appwiz, mmsys, sysdm, acppage, ziplfdr, browseui, cryptui, jscript, shell32, themeui and inf. Added translation for cyrptext, vcdcontroltool, and (not yet complete) getuname.
2019-04-05 10:34:10 +02:00
Hermès Bélusca-Maïto 47a1acedf7
[SETUPLIB][USETUP] Improve disk HW numbering, removable disk support, and "super-floppy" partitioning.
Nowadays more and more people try to install ReactOS from removable
drives (e.g. USB sticks) onto fixed HDDs, or try to install it into
USB sticks too.

Both fixed and removable drives, as well as partitions on these, are
represented in NT using the same device name format:

  \Device\HarddiskM\PartitionN ,

with an increasing disk number M. Using this number for building the
corresponding firmware-specific ARC multi(x)disk(y)rdisk(z) path used
by the NT/ROS loader (FreeLdr, ...) is then prone to error since there
may have  been  removable drives  inserted  and  accounted for in the
calculation  of  the disk number.  These drives must be  correctly
subtracted in order to generate the correct ARC path, valid once all
the removable drives have been ejected (which should also be the
situation seen from the BIOS when booting up, except of course if you
boot on a USB stick).

This problem is now solved. Note that it matters only for the disks
that have also been enumerated by the firmware (BIOS; Int 13h). We
don't have to care about the other drives, since the ARC path will be
of a different format and will not use the disk number (instead, the
SCSI coordinates are used).

We also try to enumerate all the disks found in all the possible disk
adapters and  controllers enumerated  in the Hardware registry tree
(and that are visible by FreeLdr) in order to cover all.

Finally, we detect whether a disk reports as  a "super-floppy",  i.e.
an unpartitioned disk with a valid VBR. This is indeed how a standard
floppy disk looks like, or how USB sticks are partitioned on Windows.
Such disk is reported has having only one single partition starting at
the beginning of the disk, with partition number == 0, its type being
FAT16 non-bootable.
This allows us to forbid creating any new partitions on such disks.
Note that accessing either \Device\HarddiskN\Partition0 or Partition1
on such a disk returns the same data.
Note also that on the contrary, regular MBR-partitioned disks would
report at least four partitions entries, instead of just one.

The other improvements are:

- Do *NOT* write any MBR on a disk partitioned as "super-floppy".
  CORE-13703

- Fix the computed disk identifier, of format: %08x-%08x-%c .
  The numbers are respectively the checksum of the first sector, and
  the disk signature. The terminating letter is A or X, depending
  whether the first sector ends with 0x55AA/0xAA55 or not (see also
  commit 5053f1f5).

- Warn if the user attempts to install ReactOS on a disk that is not
  visible by the  firmware of his computer,  because it may not be
  bootable.
2019-03-12 02:17:11 +01:00
Hermès Bélusca-Maïto 1d51b56882
[USETUP] Use for-loops; simplify the code. 2019-03-11 00:05:37 +01:00
Hermès Bélusca-Maïto 84f3e2df5d
[SETUPLIB][USETUP] Remove CurrentDisk/Partition from the partlist lib code, and move these into the UI code.
- Add also some validation ASSERTs and simplify the code here and there.

- The installation partition is called "InstallPartition", while the
  global "CurrentPartition" is the disk region currently selected in
  the partition UI list, on which prtitioning operations are effectued.

- Extend CheckActiveSystemPartition() to use an optional alternative
  disk or partition in case the actual system partition (present in the
  first disk) cannot be used, e.g. because we don't support writes on it.
2019-03-11 00:05:37 +01:00
Hermès Bélusca-Maïto 0d9ebb67ce
[SETUPLIB] Improve the discovery of the active system partition.
CORE-7749, CORE-6305, CORE-13205
2019-03-11 00:05:36 +01:00
Hermès Bélusca-Maïto a543103068
[USETUP] Improve the formatter & check-disk state machine. CORE-7749
- Find or set the active system partition only once, when we start the
  formatting stage. If the system partition is to be created in some
  non-partitioned space, we create it.

- A file-system check is always scheduled for both the system and the
  installation partitions.

- If the system partition was already formatted (which usually means
  that it already existed on the system), don't ask for formatting it.

  CORE-13205

- For each partition to be formatted, the file-system menu list is
  re-created, in order to display only the FSes that are compatible
  with the selected partition, and allow to give the user the choice
  to keep the existing file-system only if the selected partition was
  already formatted.

- Check whether the user attempts to delete the partition on which
  the installation source is present, only if it is not "new" and is
  formatted.

- Check first whether the current partition is the system partition,
  before displaying the CONFIRM_DELETE_SYSTEM_PARTITION_PAGE.
2019-03-10 15:41:25 +01:00
Hermès Bélusca-Maïto 29cc1843d0
[SETUPLIB][USETUP] Minor improvements.
- Make some partitioning functions not dependent on the selected "CurrentPartition".
- Add some sanity checks.
- Improve some of the "is-partitioned" checks.
2019-03-10 15:41:20 +01:00
Hermès Bélusca-Maïto c1fbc2d651
[SETUPLIB][USETUP] Factor out the usage of FS provider structures.
Similarly to FMIFS this structure should be private. Instead file-system
names are passed to the helper functions, allowing to use the names
returned by the FS drivers. The names are then internally mapped to the
corresponding FS providers.

In particular this allows to handle the "RAW" file-system and to assign
the 'Unformatted' flag to partitions having this FS.

Finally this helps us refining the checks performed to see whether the
current "active" system partition uses a supported file-system.
2019-03-10 15:41:05 +01:00
Bișoc George 35f7267a97 [USETUP] Check the status value of BuildInstallPaths() (#1349) 2019-02-13 15:22:28 +01:00
Bișoc George 8bde4de2d6 [USETUP][REACTOS] Check the status return value of InitDestinationPaths() (#1264)
- Within the function's body code, check the status values returned by the called functions.
- Change the BuildInstallPaths's function type to NTSTATUS instead of VOID (and check the status of InitDestinationPaths() as well.
2019-02-10 16:43:51 +01:00
Luo Yufan 02eeee15f0 [SETUP][INF] Add font substitute for CJK. (#1346)
Fix CJK font problem in Royale theme in ReactOS.

The reason for this PR is similar to the previous one (#1127).
CORE-15738
2019-02-10 15:46:19 +01:00
Luo Yufan 96d1cd2b62 [TRANSLATION] Update Chinese translation. 2019-02-03 13:17:13 +01:00
Arnav Bhatt f5960cea70 [SETUP] GUI setup Hindi translation (#951) 2019-02-02 14:41:31 +01:00
Katayama Hirofumi MZ 8886a2261a [USETUP] Improve lang/ReadMe.txt 2019-01-30 14:59:10 +09:00
Katayama Hirofumi MZ 232cf9f0b6
[USETUP] Follow-up ro-RO.h and add lang/ReadMe.txt (#1321)
- Add lang/ReadMe.txt for code7bit description.
- Follow up ro-RO.h file (#1317).
2019-01-29 23:55:45 +09:00
Ștefan Fulea 092b67c723 [TRANSLATION] Improve the existing translated contents 2019-01-29 13:48:48 +01:00
Ștefan Fulea 211ad8c73d [TRANSLATION] Update the existing romanian resources
This includes both newly added and previously left untranslated strings.
2019-01-29 13:48:48 +01:00
Yaroslav Kibysh 8d15720b31 [USETUP] Implement handling Home/End keys in Boot Loader Page (#1265) 2019-01-19 18:44:13 +01:00
Luo Yufan 980d8b1b12 [TRANSLATION] Update Chinese translation. (#1227)
Update Chinese and Traditional Chinese translations.
2019-01-08 13:42:17 +01:00
Pierre Schweitzer 0150bb964a
[SETUP] Silence some noisy DPRINT1 2019-01-01 10:08:02 +01:00
Hermès Bélusca-Maïto 7d6cbea42d
[USETUP] Fix the strings given to the printf-like functions (addendum to a3168373). 2018-12-30 15:26:44 +01:00
Pierre Schweitzer 4ed6b1ffca
[SETUP] Add support for selecting FS type in unattended setups
By default, we still fallback to FAT if nothing asked, or if there
is an invalid input.
0 is FAT, 1 is BtrFS. This can be grown as soon as we add more IFS.
2018-12-28 20:36:47 +01:00
Luo Yufan 0a3f6f3b47 [TRANSLATION] Update Chinese translation. (#1187)
[REG][REACTOS][EXPLORER][APPWIZ][CONSOLE][INETCPL][INPUT]
[INTL][OPENGLCFG][TIMEDATE][DEVCPUX][COMCTL32][COMDLG32]
[MSGINA][NETCFGX][NETID][SETUPAPI][SHELL32][SYSSETUP]
Update Simplified and Traditional Chinese translations.
2018-12-25 17:28:36 +09:00
Hermès Bélusca-Maïto 02e4ff8eb3
[USETUP] Add SETUP_INIT_PAGE in the list of virtual pages. 2018-12-23 21:02:08 +01:00
Hermès Bélusca-Maïto d23fa54488
[USETUP] Modify the integrated user-mode PnP manager along the lines of UMPNPMGR, so that we can wait until all the queued device installations finish before continuing the installation further.
Add a corresponding please-wait page and update the translations.
2018-12-23 20:37:14 +01:00
Hermès Bélusca-Maïto 9f1c8ac020
[USETUP] Check for invalid INF handles before doing operations. 2018-12-23 20:37:13 +01:00
Katayama Hirofumi MZ 6d63d76655
[USETUP][NTDLL_APITEST][KBDROST] Allow non-Latin codepage users to build ReactOS on MSVC (Retrial of #1150) (#1168)
- The converter is code7bit I made. code7bit: https://github.com/katahiromz/code7bit
- This converter converts non-clean characters in string literals.
- However I couldn't erase a ton of codepage C4819 warnings.
- CORE-15447

You can edit an European source file as follows:
- Right click the file in the Solution Explorer.
- Select "Open With...".
- Choose "C++ Source Code Editor (with encoding)".
- Choose "Central European (Windows) - Codepage 1260".
2018-12-20 17:25:32 +09:00
Baruch Rutman 3d991ea5a7 [TRANSLATION][USETUP] Complete Hebrew translation (#1163)
- Code-page 862, Hebrew text is in visual order.
- Use escape sequences for quotation marks.
2018-12-19 13:20:18 +01:00
Yaroslav Kibysh 8540ab04d7 [TRANSLATION] Ukrainian Translation Update & OEM-866 Code Page Problem (#1133)
Also add the Ї ї Є є characters to the VGA font for code page 866.
2018-12-18 18:38:42 +01:00
Hermès Bélusca-Maïto a3168373eb
[SETUPLIB] Detect GPT-partitioned disks but don't use them since we don't support them at the moment.
- Add checks for GPT disks and either fail or ignore the disk,
  depending on the operation being executed.

[USETUP][REACTOS] Display the disk style more accurately.
2018-12-14 23:32:31 +01:00
Luo Yufan b0b81e54e9 [SETUP][FONT] Add font substitute of Ubuntu font for CJK
CORE-15179
2018-12-14 02:54:13 +09:00
Hermès Bélusca-Maïto 8bed4adf56
[SETUPLIB] Use for-loops instead of while-loops to enumerate linked lists in the partition code. 2018-12-10 00:27:58 +01:00
Hermès Bélusca-Maïto 7df9296692
[SETUPLIB] Partitioning code fixes and improvements.
CORE-7749

- Correctly insert discovered partitions in sorted order of StartSector,
  and verify that they do not overlap (-> check for broken partitioning).

May help for CORE-10898.

- Use the correct reported partition numbers that may be modified after
  partitioning changes, and that need to be used when opening
  \Device\Harddisk'M'\Partition'N' files. This is achieving by
  retrieving the returned value of the IOCTL_DISK_SET_DRIVE_LAYOUT call.

  Distinguish them from the "on-disk" partition numbers that are the ones
  that enumerate the partition in partition-table order (and is the order
  known by e.g. the BIOS), and that should be used to construct the
  destination ARC path.

May help for CORE-4870, CORE-13205.

- Simplify a lot of duplicated code by using helper functions.
2018-12-10 00:27:56 +01:00
Stanislav Motylkov f851b82570 [USETUP] Update russian translation
Addendum to 03b7e13, 29ace9c and a5bcd95.
2018-12-08 23:36:06 +01:00
Ștefan Fulea b0ab61e6c3
[BOOTDATA][SETUPLIB] Setup the Romanian Stdandard Keyboard layout. (#861)
Adjust the miscellaneous files to activate the Romanian Standard
Keyboard layout in the OS and set it as default for Romanian.

CORE-15056
2018-12-08 18:53:18 +01:00
Hermès Bélusca-Maïto 79bc82206f
[SETUPLIB] Re-enable the filesystem detection code based on recognition by FSDs. 2018-11-25 15:03:52 +01:00
Hermès Bélusca-Maïto 9504a38f52
[SETUPLIB] Dismount a disk partition before deleting it. 2018-11-25 15:03:47 +01:00
Hermès Bélusca-Maïto a31d2f820a
[SETUPLIB] Improve the Freeldr timeout INI setting hack-fix. Dedicated to Mark Jansen ;-) CORE-15193 2018-11-24 02:45:03 +01:00
Hermès Bélusca-Maïto 70fa2e2eb4
[SETUPLIB][USETUP] Additional partition validity checks.
Always perform the partition validity checks when creating new
primary/extended/logical partitions, and also when a new partition
is automatically created when unpartitioned space is selected for
ReactOS installation.

CORE-12246
2018-11-18 21:13:36 +01:00
Hermès Bélusca-Maïto f527e23aa7
[SETUPLIB] Lock the BTRFS volume before installing the new bootsector code.
CORE-15334 CORE-15339

The BTRFS driver requires the volume to be locked in order to modify
the first sectors of the partition, even though they are outside the
file-system space / in the reserved area (they are situated before
the super-block at 0x1000) and is in principle allowed by the NT
storage stack.
So we lock here in order to write the bootsector at sector 0.
If locking fails, we ignore and continue nonetheless.

See also the following links for reference:
https://stackoverflow.com/a/12928934
https://docs.microsoft.com/en-us/windows/desktop/api/fileapi/nf-fileapi-writefile
https://support.microsoft.com/en-us/help/942448/changes-to-the-file-system-and-to-the-storage-stack-to-restrict-direct
2018-11-11 21:55:48 +01:00
Hermès Bélusca-Maïto bfb2b88f82
[SETUPLIB] Use proper file share access when opening partitions for raw access. 2018-11-11 21:47:37 +01:00
Luo Yufan 5cdee1ab82 [TRANSLATION] Update Simplified Chinese translation. (#1028) 2018-11-11 17:57:12 +01:00
Adam Słaboń b8044d6783 [TRANSLATION] Polish translation update (#1029)
Translated missing strings and improved existing translations.
2018-11-11 17:55:01 +01:00
Pierre Schweitzer 26408b02f1
[SETUP] Align partition start at 2048 minimum
This will allow compatibility with modern OSes and
modern disk management utilities.
It will also improve performances by properly aligning
partition start.
And it will let enough room at the begin of the disk
for 3rd party bootloaders.

WARNING: this is not compatible with previous partition
model, and old one will likely not be compatible. You'll
have to erase your whole partition table and start from
scratch.
2018-11-11 17:38:37 +01:00
Luo Yufan 91e032f9b1 [TRANSLATION] Update Simplified Chinese translation. (#1025) 2018-11-09 15:31:53 +01:00
Ercan Ersoy ea47d95b05 [OSK][RAPPS][USETUP] Turkish translations update. (#1024) 2018-11-09 15:13:03 +01:00
Ercan Ersoy bb0de60a4e [USETUP] Fix and add Turkish translation. (#1020) 2018-11-08 13:25:45 +01:00
Hermès Bélusca-Maïto 073c09e491
[USETUP] Display the chosen filesystem name in case of bootcode installation failure.
Simplified implementation of the proposed solution by George Bișoc
and revised by Victor Perevertkin from PR #952.

NOTE: For whatever reason ERROR_INSTALL_BOOTCODE and ERROR_WRITE_BOOT
seem to be redundant with each other. To be investigated...
2018-11-08 01:02:21 +01:00
Bișoc George 4c6370de16 [USETUP] Remove the PARTITION_EXT2 constant and use PARTITION_LINUX in favour since PARTITION_EXT2 is just an alias to PARTITION_LINUX
And since we're here, add PARTITION_LINUX_EXT to ReactOS I/O controls header (rosioctl.h).
2018-11-07 23:16:29 +01:00
Bișoc George 538f9d6aae [USETUP] When choosing BTRFS for the partition, don't think of it as Ext2 but just a Linux partition
Most of Linux filesystems have the MBR ID assigned as 0x83 and when the user chooses BTRFS upon partitions page wizard, we're thinking of the partition as having Ext2 filesystem which is wrong and misleading.
2018-11-07 23:16:29 +01:00
Joann Mõndresku b63e2d5046 [TRANSLATIONS] Style fixes for Estonian 2018-11-07 22:10:27 +01:00
Ercan Ersoy 2e562fd690 [WELCOME] Fix some Turkish translations. 2018-11-07 22:09:17 +01:00
Ercan Ersoy 7c0c3a1bd5 [REACTOS] Fix and add Turkish translations. 2018-11-07 22:09:17 +01:00
Hermès Bélusca-Maïto bbc4bb2d08
[REACTOS] Add features/usability additions.
- Interface the TreeList code and populate it with the list of
  discovered disks and partitions. Code is adapted from USETUP.
  Also display the names of the disks.

- Display some installation settings summary, before doing the
  installation proper.

- Force the user to select a checkbox when (s)he acknowledges that
  ReactOS is alpha-quality software and may break on his/her computer
  or corrupt his/her data.

- Improve wizard pages transitions and buttons enabling/disabling.

- Press Shift-F10 to start a command-line (as in the 2nd-stage setup
  in syssetup.dll).

- Use some explicit UNICODE functions/macros.
2018-11-06 00:09:16 +01:00
Hermès Bélusca-Maïto a531843245
[REACTOS] Add two icons (drive and partition) for the drive list. 2018-11-06 00:09:15 +01:00
Hermès Bélusca-Maïto 6b1e7b182a
[REACTOS] Update translations and add dialog controls for Setup Summary dialog. 2018-11-06 00:09:15 +01:00
Hermès Bélusca-Maïto 2fdfb411b6
[REACTOS] Add a TreeList control (TreeView with columns).
Add the TreeList control from Anton Zechner and Sébastien Kirche
from https://github.com/sebkirche/treelist (under GPL-3.0+) as a
*TEMPORARY* solution until a better-suited control for ReactOS is
developed.

- Compilation fixes for the TreeList control.
2018-11-06 00:09:14 +01:00
Hermès Bélusca-Maïto e282ec39a2
[SETUPLIB] Retrieve and store the machine (architecture) ID of the discovered NTOS installations. Will be used later. 2018-11-06 00:09:13 +01:00
Hermès Bélusca-Maïto f41750ab7f
[SETUPLIB][USETUP] Partition code improvements.
- SETUPLIB and USETUP: Convert PARTENTRY::DriveLetter to WCHAR.

- SETUPLIB: Retrieve volume label.

- SETUPLIB and USETUP: Move the partition types (IDs) table from
  USETUP to SETUPLIB so that they can share it with the 1st-stage
  GUI installer too. Also take the opportunity to update the table
  with information from http://www.win.tue.nl/~aeb/partitions/partition_types-1.html
  and cross-checked with the list from Paragon Hard-Disk Manager.

- USETUP: Simplify PrintPartitionData().
- Add some code comments.
2018-11-06 00:09:02 +01:00
Hermès Bélusca-Maïto 7c3570f9f5
[REACTOS] Add helpers and modify ConvertNtPathToWin32Path() to make it use a cache of NT/Win32 path mappings.
This increases performance for each time the SETUPLIB calls (using NT paths)
Win32 SetupAPI functions which of course only accept Win32 paths.

- Handle also the fact that a NT path to convert may start with
  \Device\HarddiskX\PartitionY\..., which can be a symlink to
  \Device\HarddiskVolumeN\... on some systems. In that case, the
  Win32 path mapping should be done slightly differently.

- Add support for network mapped drives.
2018-11-06 00:04:30 +01:00
Hermès Bélusca-Maïto dd2fe4e126
[REACTOS] Diverse UI improvements.
- Improve UI usage and wizard transitions (Work In Progress).
- Add interfacing code that display installation status.
- When the user attempts to cancel the installation during file copying,
  pause the file copying, and restart it if the user changes it mind and
  wants to continue the installation. Otherwise file copying is properly
  halted.
2018-11-06 00:04:29 +01:00
Hermès Bélusca-Maïto 86f31289ef
[BOOTDATA][SETUPLIB][REACTOS] INF support fixes.
- BOOTDATA: Use standard INF signature string, so that they can be
  opened successfully using ReactOS' or Windows' setupapi.dll with
  the INF_STYLE_WIN4 style.

- SETUPLIB: Use the correct INF_STYLE_* INF styles in SpInfOpenInfFile() calls.

- REACTOS : Switch thread locale to user-specified LocaleId when calling
  SetupOpenInfFileW(), so that the correct localized strings are used.
2018-11-06 00:04:19 +01:00
Hermès Bélusca-Maïto 42758b303b
[SETUPLIB] Fixes and improvements for the file copying code.
- In PrepareCopyInfFile(), explicitly use AddSectionToCopyQueueCab()
  to retrieve the files from the CAB INF.

  Otherwise if one continued to use and rely on AddSectionToCopyQueue()
  to do this job instead, bad things could happen like, re-enumerating
  twice or more (and adding them to the file queue) the same files.
  This is because in the new code AddSectionToCopyQueue() can be called
  many times to deal with different SIF file sections. The old code then
  called AddSectionToCopyQueueCab() in turn, but on the same list...
  Now the steps performed are clear, and everything works as intended.

- Simplify the code that computes the full source and destination paths
  for the files to be copied and directories to be created, using helper
  functions.

- Compute the source file and target location from the TXTSETUP.SIF
  entries in a NT-compatible manner.
2018-11-05 23:35:14 +01:00
Hermès Bélusca-Maïto 3d137b05d1
[SETUPLIB][USETUP] Move all the code that performs file copying into the SETUPLIB. 2018-11-05 23:18:47 +01:00
Hermès Bélusca-Maïto f894631472
[SETUPLIB][USETUP] Add support for setup error handling. 2018-11-05 12:03:19 +01:00
Thomas Faber 8bb1b39f66
[REACTOS] Don't include another module's PCH aka fix build. 2018-11-02 11:14:09 +01:00
Hermès Bélusca-Maïto 8cbaca5724
[REACTOS] Temporarily exclude the 1st-stage GUI setup from build, until I (or someone else) finds the correct way to fix the GCC builds. 2018-11-01 23:20:27 +01:00
Hermès Bélusca-Maïto 1b0c26e21c
[SETUPLIB][USETUP] Minor improvements.
- Use adequate access flag when opening symbolic links.
- Simplify the prototype of UpdateRegistry() since now both Setup INF
  handle and settings lists are inside the USETUP_DATA structure.
2018-11-01 18:55:45 +01:00
Hermès Bélusca-Maïto 13998a15c9
[USETUP] Improve SetupCommitFileQueueW() to make it compatible with its Win32 counterpart.
This means, call in the correct order the user callback with the correct
parameters (in particular the correct paths for file copy operations),
and check also for the callback returned value to know whether or not to
continue the file operations.
2018-11-01 18:55:44 +01:00
Hermès Bélusca-Maïto 8f1ab791fa
[SETUPLIB][REACTOS][USETUP] Further improve the interfacing with INF and File-Queue APIs.
This allows using some of the SetupApi.dll functions when SETUPLIB is
used in the (Win32) GUI 1st-stage installer "REACTOS", while using the
custom implemented NT-aware functions in "USETUP".
2018-11-01 18:55:43 +01:00
Hermès Bélusca-Maïto 44c101c9dc
[USETUP] Improvements for the File-queues code.
- Add support for delete and move/rename operations, which are needed
  for implementing ReactOS upgrading support.

- Use cabinet contexts.
- Use standard LIST_ENTRY structures for implementing the lists.

- Move the path-building hack code in SetupCommitFileQueueW() that had
  been introduced in r66604 (97bb83f) out of the file-queues code.

- Make the function prototypes compatible with win32's setupapi functions.
- Fix the format of the data passed to the custom notification handler.
- Adjust the file-copy callback to correctly use its arguments (setupapi-compatible).
2018-11-01 18:55:35 +01:00
Hermès Bélusca-Maïto 9169e881aa
[USETUP] Refactor the cabinet handling code to place all the global state variables into a CABINET_CONTEXT structure.
Place also all the private cabinet definitions into the .c, keeping
into the header file only the "public" structures and function prototypes.
2018-10-28 23:57:06 +01:00
Hermès Bélusca-Maïto 1a173dfdb2
[SETUPLIB][REACTOS][USETUP] Re-organize the setup state variables and some helpers.
- Move a great deal of global variables into the USETUP_DATA structure
  (the SetupInf, the SetupFileQueue, the generic lists...).

- Place the common setup initialization code into an InitializeSetup()
  routine, and the cleanup code into FinishSetup().

- Implement the setup-code part support for the TXTSETUP.SIF setup
  source path override variables "SetupSourceDevice" and "SetupSourcePath"
  (see CORE-9023); support for them in SETUPLDR will be added later.
2018-10-28 23:40:28 +01:00
Hermès Bélusca-Maïto 9016b5f3ef
[SETUPLIB] Silence noisy DPRINTs. 2018-10-28 23:40:26 +01:00
Hermès Bélusca-Maïto 4bf9f6fa4a
[SETUP:REACTOS] Populate the list of existing installations.
- In the 1st-stage GUI setup, display the list of existing discovered
  NTOS installations, with its name, installation path and vendor name,
  and an associated icon.
2018-10-28 19:00:01 +01:00
Hermès Bélusca-Maïto f7ee1e2ffd
[SETUP:REACTOS] Add a wizard page to select which existing OS installation to upgrade. 2018-10-28 18:59:56 +01:00
Hermès Bélusca-Maïto 82117d2192
[SETUP:REACTOS] Adapt the 1st-stage GUI setup to compile with the setuplib.
svn path=/branches/setup_improvements/; revision=75544

[SETUP:REACTOS] More interfacing of the 1st-stage GUI installer with the setuplib.

- Add a ConvertNtPathToWin32Path() helper function that allows converting
  NT paths like: \Device\CdRom0\i386\txtsetup.sif file into a Win32 path
  that the Win32 versions of the SetupApi functions (e.g. SetupOpenInfFileW)
  can accept.
  Note that RtlNtPathNameToDosPathName() cannot be used here because this
  function only works for NT paths within the \DosDevices\ (or \??\) NTObj
  directory, and not in other directories.

- Use this helper function in the implementation of SetupOpenInfFileExW.
  Now the txtsetup.sif function can be loaded by setuplib *when being used*
  by the 1st-stage GUI installer!

- Remove deprecated code.

svn path=/branches/setup_improvements/; revision=75668
svn path=/branches/setup_improvements/; revision=75721
svn path=/branches/setup_improvements/; revision=75750
2018-10-28 18:59:47 +01:00
Hermès Bélusca-Maïto 9c64b57dc9
[SETUPLIB][USETUP] Move the remaining (directory-creation) functions from usetup's filesup to setuplib.
They will be used later in the library.
2018-10-28 18:17:34 +01:00
Hermès Bélusca-Maïto a972948051
[SETUPLIB][USETUP] Remove the deprecated GenericListHasSingleEntry() function and use instead GetNumberOfListEntries().
- Few FIXMEs get fixed in the process.
- Add some diagnostic ASSERTs.
2018-10-28 15:04:33 +01:00
Hermès Bélusca-Maïto a635aa8475
[SETUPLIB] Properly cleanup the temporary registry keys created for setting up the registry.
This includes also to remove the created symlinks.
Symlinks deletion is special, as one has to open first the symlink
itself (and not its target), then remove the "SymbolicLinkTarget" value
before really deleting the key. Of course everything must be done under
proper access rights.

Additional changes:
- Change prototype BOOLEAN CmpLinkKeyToHive(...) to NTSTATUS CreateSymLinkKey(...).
- Silence few DPRINTs.
- Document some FIXMEs that I need to inspect later on ReactOS.
- HKEY --> HANDLE.
2018-10-28 14:42:01 +01:00
Hermès Bélusca-Maïto 6c2d3dee04
[SETUPLIB][USETUP] Move the registry-update procedure into setuplib.
- It can therefore be also used by the 1st-stage GUI setup.
- Rename some function parameters to clarify what they should be.

Based on:
svn path=/branches/setup_improvements/; revision=75750
2018-10-28 14:42:00 +01:00
Hermès Bélusca-Maïto dae658088a
[USETUP] Introduce some -V functions for CONSOLE_ConOutPrintf, CONSOLE_SetStatusText and CONSOLE_SetStatusTextX.
Additions:
- Use explicit __cdecl calling convention for variadic functions.
- Fix also the whitespace in consup.h.

svn path=/branches/setup_improvements/; revision=75749
2018-10-28 14:41:57 +01:00
Hermès Bélusca-Maïto f80ec8b822
[SETUPLIB] Store the vendor name for each discovered NTOS installation.
Take also the opportunity to simplify a little bit the code.
2018-10-28 01:58:59 +02:00
Hermès Bélusca-Maïto a5bcd956fa
[USETUP] Add new file-operation-related messages for deletion, moving and renaming. 2018-10-28 01:58:55 +02:00
Hermès Bélusca-Maïto a7afba7703
[SETUPLIB] Remove a deprecated error number (that gets merged with ERROR_TXTSETUP_SECTION).
[USETUP] Improve usage of ERROR_TXTSETUP_SECTION and ERROR_CABINET_SECTION error codes, correctly display associated error message, and remove a deprecated string.
2018-10-28 01:43:56 +02:00
Hermès Bélusca-Maïto 4b148bcaf2
[USETUP] Remove now-redundant file (already used with SETUPLIB). 2018-10-28 01:32:37 +02:00
Hermès Bélusca-Maïto 1f4cb0977a
[SETUPLIB][USETUP] Don't store UI-related display strings in GENERIC_LIST_ENTRY-ies, + other code adaptations.
- Apart from allowing a UI cache variable that may be used when
  displaying GENERIC_LIST_ENTRY-ies, do not store any display strings
  associated to these list entries. They should be instead computed only
  when initializing a list UI (or a combo-box or list control if the
  code is used in Win32 environment).
  For this matter a callback is provided to InitGenericListUi() that
  does the job of computing the displayed string corresponding to a
  given GENERIC_LIST_ENTRY.

- Simplify the calls to InitGenericListUi(), and refactor the
  RestoreGenericListUiState() function.

- Use for-loops for iterating over GENERIC_LIST items.

- Adapt the storage data format for lists of settings items.

- The txtsetup.sif INF format specified in LoadSetupInf() should not be
  INF_STYLE_WIN4 (to be investigated...).
2018-10-28 01:32:15 +02:00
Hermès Bélusca-Maïto 765994c9e3
[SETUPLIB][USETUP] Bring some suggestions from PR #59 in.
- Use OBJ_CASE_INSENSITIVE when initializing object attributes
  (no actual reason why to keep case sensitivity there).

- Check the success of a RtlStringCchPrintfW call in EnumerateReactOSEntries().

- Explicitly check for returned STATUS_NOT_SUPPORTED from ChkdskPartition()
  or FormatPartition(), and display an appropriate error message.

- Remove some left-over comments but also explain why I kept some
  commented code (mainly for future reference).
2018-10-28 01:08:57 +02:00
Hermès Bélusca-Maïto a7a11dd60d
[SETUPLIB] Improve the bootloader 'validity' checks -- Addendum to f06734e5 (r74512).
Adapted from PR #89 by Serge Gautherie.
This should improve the situation described in CORE-12672 and CORE-4870.
2018-10-28 00:59:46 +02:00
Hermès Bélusca-Maïto ad9e57895d
[SETUPLIB] Improve an alternate code implementation.
Comment about the status of two '#if 0'.

[SETUPLIB] Fix some uninitialized variables (caught by clang-cl).
Also, initialize NtName->Length in return paths in ResolveArcNameManually().
2018-10-28 00:59:45 +02:00
Hermès Bélusca-Maïto c3ab29682a
[USETUP] Move the SetupExtractFile() function to where it is (only) used.
svn path=/branches/setup_improvements/; revision=75762
2018-10-28 00:59:44 +02:00