Ventoy2Disk update:

1. Add UDF filesytem option.
2. Add Cluster Size option.
3. Support FAT32 for disk bigger than 32GB.
4. Fix the format fail issue.
5. Add a tip bubble with cluster size when mouse hover on the file system type string.
6. The secure boot lock character can not show in early Windows, change it to a yellow icon.
pull/1996/head
longpanda 1 year ago
parent 118bedd546
commit ee04af5243

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -56,6 +56,9 @@
"STR_INSTALL_YES_TIP1":"تحذير: سيتم فقدان البيانات!",
"STR_INSTALL_YES_TIP2":"يرجى إدخال YES في مربع النص في الأسفل للتأكيد بأنك تريد عمل تثبيت جديد بدلاً من التحديث.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
@ -116,6 +119,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
@ -176,7 +183,10 @@
"STR_INSTALL_YES_TIP1":"경고: 데이터가 손실됩니다!",
"STR_INSTALL_YES_TIP2":"업그레이드 대신 새로 설치할지 확인하려면 아래 입력란에 YES를 입력하십시오.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -236,6 +246,9 @@
"STR_INSTALL_YES_TIP1":"警告: 所有数据将会丢失!",
"STR_INSTALL_YES_TIP2":"请在下面文本框中输入 YES 以确认你是要进行安装而不是升级。",
"STR_PART_VENTOY_FS":"Ventoy 分区文件系统类型",
"STR_PART_FS":"文件系统",
"STR_PART_CLUSTER":"簇大小",
"STR_PART_CLUSTER_DEFAULT":"系统默认值",
"STRXXX":""
},
@ -296,7 +309,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -355,7 +371,10 @@
"STR_MENU_PART_RESIZE": "გთხოვთ, შეიყვანოთ YES ქვემოთ მოცემულ ტექსტურ ველში, რათა დაადასტუროთ... გსურთ განახლების ნაცვლად განახორციელოთ ახალი ინსტალაცია.",
"STR_PART_RESIZE_TIP": "Ventoy ჩეეცდება დააყენოს არა-დესტრუქციული რამდენადაც შეეცდება. გსურს გაგრძელება?",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX": ""
},
{
@ -415,7 +434,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -475,7 +497,10 @@
"STR_INSTALL_YES_TIP1":"Ostrzeżenie: Dane zostaną utracone!",
"STR_INSTALL_YES_TIP2":"Wpisz YES w poniższym polu tekstowym, aby potwierdzić, że naprawdę chcesz przeprowadzić nową instalację zamiast aktualizacji.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -535,7 +560,10 @@
"STR_INSTALL_YES_TIP1":"Aviso: Os dados serão perdidos!",
"STR_INSTALL_YES_TIP2":"Por favor, digite YES na caixa de texto abaixo para confirmar que você realmente quer fazer uma nova instalação em vez de atualização.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -595,7 +623,10 @@
"STR_INSTALL_YES_TIP1":"Uyarı: Tüm verileriniz kaybolacak!",
"STR_INSTALL_YES_TIP2":"Güncelleme yapmak yerine,yeni bir kurulum yapmak istediğinizi doğrulamak için lütfen aşağıdaki metin kutusuna YES yazın.",
"STR_PART_VENTOY_FS":"Ventoy bölümü Dosya Sistemi",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -655,7 +686,10 @@
"STR_INSTALL_YES_TIP1":"Warnung: Die Daten gehen verloren!",
"STR_INSTALL_YES_TIP2":"Bitte bestätigen Sie in der unteren Textbox mit YES, dass Sie anstelle eines Upgrades eine frische Installation durchführen möchten.",
"STR_PART_VENTOY_FS":"Dateisystem für die Ventoy-Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -715,7 +749,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -775,6 +812,9 @@
"STR_INSTALL_YES_TIP1":"Attention : les données seront perdues !",
"STR_INSTALL_YES_TIP2":"Veuillez saisir YES dans la zone de texte ci-dessous pour confirmer que vous souhaitez bien effectuer une nouvelle installation au lieu d'une mise à niveau.",
"STR_PART_VENTOY_FS":"Système de fichiers pour la partition Ventoy",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
@ -835,6 +875,9 @@
"STR_INSTALL_YES_TIP1":"Varování: Data budou ztracena!",
"STR_INSTALL_YES_TIP2":"Do níže uvedeného textového pole zadejte YES a potvrďte, že skutečně chcete provést novou instalaci namísto aktualizace.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
@ -894,7 +937,10 @@
"STR_INSTALL_YES_TIP1":"Varovanie: Dôjde k strate údajov!",
"STR_INSTALL_YES_TIP2":"Prosím, zadajte YES v textovom poli nižšie, čím potvrdíte, že naozaj chcete vykonať novú inštaláciu miesto aktualizácie.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -954,7 +1000,10 @@
"STR_INSTALL_YES_TIP1":"Advertencia: ¡Los datos se perderán!",
"STR_INSTALL_YES_TIP2":"Por favor ingresa YES en el cuadro de texto a continuación para confirmar que realmente quieres realizar una instalación nueva en vez de actualizar.",
"STR_PART_VENTOY_FS":"Sistema de archivos para partición de Ventoy",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1014,7 +1063,10 @@
"STR_INSTALL_YES_TIP1":"Advertencia: ¡Los datos se perderán!",
"STR_INSTALL_YES_TIP2":"Por favor, escriba YES en el cuadro de texto a continuación para confirmar que realmente quiere realizar una nueva instalación de Ventoy en vez de actualizarlo.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1074,6 +1126,9 @@
"STR_INSTALL_YES_TIP1":"Предупреждение: Данные будут потеряны!",
"STR_INSTALL_YES_TIP2":"Пожалуйста, введите YES в текстовое поле ниже, чтобы подтвердить, что вы действительно хотите выполнить новую установку вместо обновления.",
"STR_PART_VENTOY_FS":"Файловая система для Ventoy раздела",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
@ -1134,7 +1189,10 @@
"STR_INSTALL_YES_TIP1":"সতর্কতা: ডেটা হারিয়ে যাবে!",
"STR_INSTALL_YES_TIP2":"আপনি আপগ্রেড করার পরিবর্তে একটি নতুন ইনস্টল করতে চান তা নিশ্চিত করতে দয়া করে নীচের পাঠ্য বাক্সে Yes লিখুন৷।",
"STR_PART_VENTOY_FS":"Ventoy পার্টিশনের জন্য ফাইল সিস্টেম",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1194,7 +1252,10 @@
"STR_INSTALL_YES_TIP1":"चेतावनी: डेटा खो जाएगा!",
"STR_INSTALL_YES_TIP2":"यह पुष्टि करने के लिए कि आप वास्तव में अपग्रेड के बजाय एक नया इंस्टॉल करना चाहते हैं, कृपया नीचे दिए टेक्स्ट बॉक्स में Yes दर्ज करें।",
"STR_PART_VENTOY_FS":"Ventoy विभाजन के लिए फाइल सिस्टम",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1254,7 +1315,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1314,7 +1378,10 @@
"STR_INSTALL_YES_TIP1":"Atenție: Datele se vor pierde!",
"STR_INSTALL_YES_TIP2":"Introduceți DA în caseta de text de mai jos pentru a confirma că într-adevăr doriți să faceți o nouă instalare în loc să faceți upgrade.",
"STR_PART_VENTOY_FS":"Sistem de fișiere pentru partiția Ventoy",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1374,7 +1441,10 @@
"STR_INSTALL_YES_TIP1":"警告: データが消去されます",
"STR_INSTALL_YES_TIP2":"Ventoyを更新するのではなく新規に導入するということを確認するために下の入力欄に「YES」と入力してください。",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1434,7 +1504,10 @@
"STR_INSTALL_YES_TIP1":"Attenzione: i dati verranno persi!",
"STR_INSTALL_YES_TIP2":"Digita YES nella casella di testo qui sotto per confermare che vuoi davvero eseguire un'installazione pulita anziché un aggiornamento.",
"STR_PART_VENTOY_FS":"File System per partizione Ventoy",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1494,7 +1567,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1554,7 +1630,10 @@
"STR_INSTALL_YES_TIP1":"Figyelmeztetés: Az adatok elvesznek!",
"STR_INSTALL_YES_TIP2":"Írja a YES szót az alábbi szövegmezőbe, hogy megerősítse, valóban új telepítést szeretne végrehajtani a frissítés helyett.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1614,7 +1693,10 @@
"STR_INSTALL_YES_TIP1":"警告:資料將會遺失!",
"STR_INSTALL_YES_TIP2":"請在下方的文字輸入框輸入 YES 來證實您想要進行全新安裝取代升級。",
"STR_PART_VENTOY_FS":"Ventoy 分割區文件系統",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1674,7 +1756,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1734,7 +1819,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1794,6 +1882,9 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
@ -1854,6 +1945,9 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
@ -1914,7 +2008,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -1974,7 +2071,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -2034,6 +2134,9 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
@ -2094,7 +2197,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -2154,6 +2260,9 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
@ -2214,7 +2323,10 @@
"STR_INSTALL_YES_TIP1":"Peringatan: Data akan hilang!",
"STR_INSTALL_YES_TIP2":"Silakan ketik YES pada kotak tulis di bawah untuk meyakinkan bahwa anda memang untuk melakukan pemasangan baru ketimbang memperbaruinya",
"STR_PART_VENTOY_FS":"Berkas Sistem Untuk Partisi Ventoy",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -2274,7 +2386,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -2334,7 +2449,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -2394,7 +2512,10 @@
"STR_INSTALL_YES_TIP1":"Προειδοποίηση: Τα δεδομένα θα χαθούν!",
"STR_INSTALL_YES_TIP2":"Εισαγάγετε ΝΑΙ στο παρακάτω πλαίσιο κειμένου για να επιβεβαιώσετε ότι όντως θέλετε να κάνετε μια νέα εγκατάσταση αντί για αναβάθμιση.",
"STR_PART_VENTOY_FS":"Σύστημα αρχείων για το διαμέρισμα Ventoy",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -2454,7 +2575,10 @@
"STR_INSTALL_YES_TIP1":"Varning: Data kommer att gå förlorade!",
"STR_INSTALL_YES_TIP2":"Skriv YES i textrutan nedan för att bekräfta att du verkligen vill göra en nyinstallation i stället för att uppgradera.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -2514,7 +2638,10 @@
"STR_INSTALL_YES_TIP1":"Pozor: Podatki bodo izbrisani!",
"STR_INSTALL_YES_TIP2":"Prosim vtipkajte YES v spodnje okno da potrdite čisto inštalacijo in ne zgolj nadgradnje.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -2574,6 +2701,9 @@
"STR_INSTALL_YES_TIP1":"Внимание: Ще има загуба на данни!",
"STR_INSTALL_YES_TIP2":"Въведете „YES“ в полето отдолу, за да потвърдите, че искате да извършите нова инсталация вместо обновяване.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
@ -2634,7 +2764,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -2694,7 +2827,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -2754,7 +2890,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -2814,7 +2953,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
@ -2875,7 +3017,10 @@
"STR_INSTALL_YES_TIP1":"Warning: Data will be lost!",
"STR_INSTALL_YES_TIP2":"Please enter YES in the text box below to confirm that you indeed want to do a fresh install instead of upgrade.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
},
{
@ -2935,6 +3080,9 @@
"STR_INSTALL_YES_TIP1":"எச்சரிக்கை: தரவு தொலைந்து போகும்!",
"STR_INSTALL_YES_TIP2":"மேம்படுத்துவதற்குப் பதிலாக புதிதாக நிறுவ விரும்புகிறீர்கள் என்பதை உறுதிப்படுத்த, கீழே உள்ள உரைப் பெட்டியில் ஆம் என உள்ளிடவும்.",
"STR_PART_VENTOY_FS":"File System For Ventoy Partition",
"STR_PART_FS":"File System",
"STR_PART_CLUSTER":"Cluster Size",
"STR_PART_CLUSTER_DEFAULT":"System Default Value",
"STRXXX":""
}

@ -27,7 +27,7 @@ Most type of OS supported(Windows/WinPE/Linux/Unix/ChromeOS/Vmware/Xen...) <br/>
Windows 7, Windows 8, Windows 8.1, Windows 10, Windows 11, Windows Server 2012, Windows Server 2012 R2, Windows Server 2016, Windows Server 2019, Windows Server 2022, WinPE
**Linux**
Debian, Ubuntu, CentOS(6/7/8/9), RHEL(6/7/8/9), Deepin, Fedora, Rocky Linux, AlmaLinux, EuroLinux(6/7/8/9), openEuler, OpenAnolis, SLES, openSUSE, MX Linux, Manjaro, Linux Mint, Endless OS, Elementary OS, Solus, Linx, Zorin, antiX, PClinuxOS, Arch, ArcoLinux, ArchLabs, BlackArch, Obarun, Artix Linux, Puppy Linux, Tails, Slax, Kali, Mageia, Slackware, Q4OS, Archman, Gentoo, Pentoo, NixOS, Kylin, openKylin, Ubuntu Kylin, Lubuntu, Xubuntu, Kubuntu, Ubuntu MATE, Ubuntu Budgie, Ubuntu Studio, Bluestar, OpenMandriva, ExTiX, Netrunner, ALT Linux, Nitrux, Peppermint, KDE neon, Linux Lite, Parrot OS, Qubes, Pop OS, ROSA, Void Linux, Star Linux, EndeavourOS, MakuluLinux, Voyager, Feren, ArchBang, LXLE, Knoppix, Calculate Linux, Clear Linux, Pure OS, Oracle Linux, Trident, Septor, Porteus, Devuan, GoboLinux, 4MLinux, Simplicity Linux, Zeroshell, Android-x86, netboot.xyz, Slitaz, SuperGrub2Disk, Proxmox VE, Kaspersky Rescue, SystemRescueCD, MemTest86, MemTest86+, MiniTool Partition Wizard, Parted Magic, veket, Sabayon, Scientific, alpine, ClearOS, CloneZilla, Berry Linux, Trisquel, Ataraxia Linux, Minimal Linux Live, BackBox Linux, Emmabuntüs, ESET SysRescue Live,Nova Linux, AV Linux, RoboLinux, NuTyX, IPFire, SELKS, ZStack, Enso Linux, Security Onion, Network Security Toolkit, Absolute Linux, TinyCore, Springdale Linux, Frost Linux, Shark Linux, LinuxFX, Snail Linux, Astra Linux, Namib Linux, Resilient Linux, Virage Linux, Blackweb Security OS, R-DriveImage, O-O.DiskImage, Macrium, ToOpPy LINUX, GNU Guix, YunoHost, foxclone, siduction, Adelie Linux, Elive, Pardus, CDlinux, AcademiX, Austrumi, Zenwalk, Anarchy, DuZeru, BigLinux, OpenMediaVault, Ubuntu DP, Exe GNU/Linux, 3CX Phone System, KANOTIX, Grml, Karoshi, PrimTux, ArchStrike, CAELinux, Cucumber, Fatdog, ForLEx, Hanthana, Kwort, MiniNo, Redcore, Runtu, Asianux, Clu Linux Live, Uruk, OB2D, BlueOnyx, Finnix, HamoniKR, Parabola, LinHES, LinuxConsole, BEE free, Untangle, Pearl, Thinstation, TurnKey, tuxtrans, Neptune, HefftorLinux, GeckoLinux, Mabox Linux, Zentyal, Maui, Reborn OS, SereneLinux , SkyWave Linux, Kaisen Linux, Regata OS, TROM-Jaro, DRBL Linux, Chalet OS, Chapeau, Desa OS, BlankOn, OpenMamba, Frugalware, Kibojoe Linux, Revenge OS, Tsurugi Linux, Drauger OS, Hash Linux, gNewSense, Ikki Boot, SteamOS, Hyperbola, VyOS, EasyNAS, SuperGamer, Live Raizo, Swift Linux, RebeccaBlackOS, Daphile, CRUX, Univention, Ufficio Zero, Rescuezilla, Phoenix OS, Garuda Linux, Mll, NethServer, OSGeoLive, Easy OS, Volumio, FreedomBox, paldo, UBOS, Recalbox, batocera, Lakka, LibreELEC, Pardus Topluluk, Pinguy, KolibriOS, Elastix, Arya, Omoikane, Omarine, Endian Firewall, Hamara, Rocks Cluster, MorpheusArch, Redo, Slackel, SME Server, APODIO, Smoothwall, Dragora, Linspire, Secure-K OS, Peach OSI, Photon, Plamo, SuperX, Bicom, Ploplinux, HP SPP, LliureX, Freespire, DietPi, BOSS, Webconverger, Lunar, TENS, Source Mage, RancherOS, T2, Vine, Pisi, blackPanther, mAid, Acronis, Active.Boot, AOMEI, Boot.Repair, CAINE, DaRT, EasyUEFI, R-Drive, PrimeOS, Avira Rescue System, bitdefender, Checkra1n Linux, Lenovo Diagnostics, Clover, Bliss-OS, Lenovo BIOS Update, Arcabit Rescue Disk, MiyoLinux, TeLOS, Kerio Control, RED OS, OpenWrt, MocaccinoOS, EasyStartup, Pyabr, Refracta, Eset SysRescue, Linpack Xtreme, Archcraft, NHVBOOT, pearOS, SeaTools, Easy Recovery Essentional, iKuai, StorageCraft SCRE, ZFSBootMenu, TROMjaro, BunsenLabs, Todo en Uno, ChallengerOS, Nobara, Holo, CachyOS, ......
Debian, Ubuntu, CentOS(6/7/8/9), RHEL(6/7/8/9), Deepin, Fedora, Rocky Linux, AlmaLinux, EuroLinux(6/7/8/9), openEuler, OpenAnolis, SLES, openSUSE, MX Linux, Manjaro, Linux Mint, Endless OS, Elementary OS, Solus, Linx, Zorin, antiX, PClinuxOS, Arch, ArcoLinux, ArchLabs, BlackArch, Obarun, Artix Linux, Puppy Linux, Tails, Slax, Kali, Mageia, Slackware, Q4OS, Archman, Gentoo, Pentoo, NixOS, Kylin, openKylin, Ubuntu Kylin, KylinSec, Lubuntu, Xubuntu, Kubuntu, Ubuntu MATE, Ubuntu Budgie, Ubuntu Studio, Bluestar, OpenMandriva, ExTiX, Netrunner, ALT Linux, Nitrux, Peppermint, KDE neon, Linux Lite, Parrot OS, Qubes, Pop OS, ROSA, Void Linux, Star Linux, EndeavourOS, MakuluLinux, Voyager, Feren, ArchBang, LXLE, Knoppix, Calculate Linux, Clear Linux, Pure OS, Oracle Linux, Trident, Septor, Porteus, Devuan, GoboLinux, 4MLinux, Simplicity Linux, Zeroshell, Android-x86, netboot.xyz, Slitaz, SuperGrub2Disk, Proxmox VE, Kaspersky Rescue, SystemRescueCD, MemTest86, MemTest86+, MiniTool Partition Wizard, Parted Magic, veket, Sabayon, Scientific, alpine, ClearOS, CloneZilla, Berry Linux, Trisquel, Ataraxia Linux, Minimal Linux Live, BackBox Linux, Emmabuntüs, ESET SysRescue Live,Nova Linux, AV Linux, RoboLinux, NuTyX, IPFire, SELKS, ZStack, Enso Linux, Security Onion, Network Security Toolkit, Absolute Linux, TinyCore, Springdale Linux, Frost Linux, Shark Linux, LinuxFX, Snail Linux, Astra Linux, Namib Linux, Resilient Linux, Virage Linux, Blackweb Security OS, R-DriveImage, O-O.DiskImage, Macrium, ToOpPy LINUX, GNU Guix, YunoHost, foxclone, siduction, Adelie Linux, Elive, Pardus, CDlinux, AcademiX, Austrumi, Zenwalk, Anarchy, DuZeru, BigLinux, OpenMediaVault, Ubuntu DP, Exe GNU/Linux, 3CX Phone System, KANOTIX, Grml, Karoshi, PrimTux, ArchStrike, CAELinux, Cucumber, Fatdog, ForLEx, Hanthana, Kwort, MiniNo, Redcore, Runtu, Asianux, Clu Linux Live, Uruk, OB2D, BlueOnyx, Finnix, HamoniKR, Parabola, LinHES, LinuxConsole, BEE free, Untangle, Pearl, Thinstation, TurnKey, tuxtrans, Neptune, HefftorLinux, GeckoLinux, Mabox Linux, Zentyal, Maui, Reborn OS, SereneLinux , SkyWave Linux, Kaisen Linux, Regata OS, TROM-Jaro, DRBL Linux, Chalet OS, Chapeau, Desa OS, BlankOn, OpenMamba, Frugalware, Kibojoe Linux, Revenge OS, Tsurugi Linux, Drauger OS, Hash Linux, gNewSense, Ikki Boot, SteamOS, Hyperbola, VyOS, EasyNAS, SuperGamer, Live Raizo, Swift Linux, RebeccaBlackOS, Daphile, CRUX, Univention, Ufficio Zero, Rescuezilla, Phoenix OS, Garuda Linux, Mll, NethServer, OSGeoLive, Easy OS, Volumio, FreedomBox, paldo, UBOS, Recalbox, batocera, Lakka, LibreELEC, Pardus Topluluk, Pinguy, KolibriOS, Elastix, Arya, Omoikane, Omarine, Endian Firewall, Hamara, Rocks Cluster, MorpheusArch, Redo, Slackel, SME Server, APODIO, Smoothwall, Dragora, Linspire, Secure-K OS, Peach OSI, Photon, Plamo, SuperX, Bicom, Ploplinux, HP SPP, LliureX, Freespire, DietPi, BOSS, Webconverger, Lunar, TENS, Source Mage, RancherOS, T2, Vine, Pisi, blackPanther, mAid, Acronis, Active.Boot, AOMEI, Boot.Repair, CAINE, DaRT, EasyUEFI, R-Drive, PrimeOS, Avira Rescue System, bitdefender, Checkra1n Linux, Lenovo Diagnostics, Clover, Bliss-OS, Lenovo BIOS Update, Arcabit Rescue Disk, MiyoLinux, TeLOS, Kerio Control, RED OS, OpenWrt, MocaccinoOS, EasyStartup, Pyabr, Refracta, Eset SysRescue, Linpack Xtreme, Archcraft, NHVBOOT, pearOS, SeaTools, Easy Recovery Essentional, iKuai, StorageCraft SCRE, ZFSBootMenu, TROMjaro, BunsenLabs, Todo en Uno, ChallengerOS, Nobara, Holo, CachyOS, ......
**Unix**
DragonFly FreeBSD pfSense GhostBSD FreeNAS TrueNAS XigmaNAS FuryBSD OPNsense HardenedBSD MidnightBSD ClonOS EmergencyBootKit

@ -109,17 +109,175 @@ BOOL DISK_ShrinkVolume(int DriveIndex, const char* VolumeGuid, CHAR DriveLetter,
return ret;
}
BOOL DISK_FormatVolume(char DriveLetter, int fs)
// Output command
typedef struct
{
DWORD Lines;
PCHAR Output;
} TEXTOUTPUT, * PTEXTOUTPUT;
// Callback command types
typedef enum
{
PROGRESS,
DONEWITHSTRUCTURE,
UNKNOWN2,
UNKNOWN3,
UNKNOWN4,
UNKNOWN5,
INSUFFICIENTRIGHTS,
UNKNOWN7,
UNKNOWN8,
UNKNOWN9,
UNKNOWNA,
DONE,
UNKNOWNC,
UNKNOWND,
OUTPUT,
STRUCTUREPROGRESS
} CALLBACKCOMMAND;
// FMIFS callback definition
typedef BOOLEAN(__stdcall* PFMIFSCALLBACK)(CALLBACKCOMMAND Command, DWORD SubAction, PVOID ActionInfo);
// Chkdsk command in FMIFS
typedef VOID(__stdcall* PCHKDSK)(PWCHAR DriveRoot,
PWCHAR Format,
BOOL CorrectErrors,
BOOL Verbose,
BOOL CheckOnlyIfDirty,
BOOL ScanDrive,
PVOID Unused2,
PVOID Unused3,
PFMIFSCALLBACK Callback);
// media flags
#define FMIFS_HARDDISK 0xC
#define FMIFS_FLOPPY 0x8
// Format command in FMIFS
typedef VOID(__stdcall* PFORMATEX)(PWCHAR DriveRoot,
DWORD MediaFlag,
PWCHAR Format,
PWCHAR Label,
BOOL QuickFormat,
DWORD ClusterSize,
PFMIFSCALLBACK Callback);
// FormatExCallback
static int g_dll_format_error = 0;
BOOLEAN __stdcall FormatExCallback(CALLBACKCOMMAND Command, DWORD Modifier, PVOID Argument)
{
PDWORD percent;
PBOOLEAN status;
switch (Command)
{
case PROGRESS:
percent = (PDWORD)Argument;
Log("Format percent: %d \n", *percent);
break;
case OUTPUT:
break;
case DONE:
status = (PBOOLEAN)Argument;
if (*status == FALSE)
{
g_dll_format_error = 1;
}
else
{
}
break;
}
return TRUE;
}
BOOL DLL_FormatVolume(char DriveLetter, int fs, DWORD ClusterSize)
{
PWCHAR Label = L"Ventoy";
PWCHAR Format = NULL;
WCHAR RootDirectory[MAX_PATH] = { 0 };
HMODULE ifsModule;
PFORMATEX FormatEx;
ifsModule = LoadLibraryA("fmifs.dll");
if (NULL == ifsModule)
{
Log("LoadLibrary fmifs.dll failed %u", LASTERR);
return FALSE;
}
Log("Find ifsModule");
FormatEx = (PFORMATEX)GetProcAddress(ifsModule, "FormatEx");
if (FormatEx == NULL)
{
Log("Failed to get FormatEx handler\n");
return FALSE;
}
Log("Find FormatEx=%p", FormatEx);
RootDirectory[0] = DriveLetter;
RootDirectory[1] = L':';
RootDirectory[2] = L'\\';
RootDirectory[3] = (WCHAR)0;
DWORD media;
DWORD driveType;
driveType = GetDriveTypeW(RootDirectory);
if (driveType != DRIVE_FIXED)
media = FMIFS_FLOPPY;
if (driveType == DRIVE_FIXED)
media = FMIFS_HARDDISK;
Format = GetVentoyFsFmtNameByTypeW(fs);
g_dll_format_error = 0;
Log("Call FormatEx Function for %C: %s ClusterSize=%u(%uKB)", DriveLetter, GetVentoyFsFmtNameByTypeA(fs), ClusterSize, ClusterSize / 1024);
FormatEx(RootDirectory, media, Format, Label, TRUE, ClusterSize, FormatExCallback);
FreeLibrary(ifsModule);
if (g_dll_format_error)
{
Log("Format failed by DLL");
return FALSE;
}
Log("Format success by DLL");
return TRUE;
}
BOOL DISK_FormatVolume(char DriveLetter, int fs, UINT64 VolumeSize)
{
DWORD ClusterSize = 0;
BOOL ret = FALSE;
//ret = VDS_FormatVolume(DriveLetter, fs);
ClusterSize = (DWORD)GetClusterSize();
Log("DISK_FormatVolume %C:\\ %s VolumeSize=%llu ClusterSize=%u(%uKB)",
DriveLetter, GetVentoyFsNameByType(fs), (ULONGLONG)VolumeSize, ClusterSize, ClusterSize/1024);
ret = DLL_FormatVolume(DriveLetter, fs, ClusterSize);
if (!ret)
{
//ret = DSPT_FormatVolume(DriveLetter, fs);
ret = VDS_FormatVolume(DriveLetter, fs, ClusterSize);
if (!ret)
{
ret = PSHELL_FormatVolume(DriveLetter, fs);
ret = DSPT_FormatVolume(DriveLetter, fs, ClusterSize);
if (!ret)
{
ret = PSHELL_FormatVolume(DriveLetter, fs, ClusterSize);
}
}
}

@ -30,6 +30,7 @@ typedef struct VDS_PARA
ULONG NameLen;
ULONGLONG Offset;
CHAR DriveLetter;
DWORD ClusterSize;
}VDS_PARA;
//DISK API
@ -39,7 +40,7 @@ BOOL DISK_ChangeVtoyEFIAttr(int DriveIndex, UINT64 Offset, UINT64 Attr);
BOOL DISK_ChangeVtoyEFI2ESP(int DriveIndex, UINT64 Offset);
BOOL DISK_ChangeVtoyEFI2Basic(int DriveIndex, UINT64 Offset);
BOOL DISK_ShrinkVolume(int DriveIndex, const char* VolumeGuid, CHAR DriveLetter, UINT64 OldBytes, UINT64 ReduceBytes);
BOOL DISK_FormatVolume(char DriveLetter, int fs);
BOOL DISK_FormatVolume(char DriveLetter, int fs, UINT64 VolumeSize);
//VDS com
@ -51,11 +52,11 @@ BOOL VDS_ChangeVtoyEFI2ESP(int DriveIndex, UINT64 Offset);
BOOL VDS_ChangeVtoyEFI2Basic(int DriveIndex, UINT64 Offset);
BOOL VDS_ShrinkVolume(int DriveIndex, const char* VolumeGuid, CHAR DriveLetter, UINT64 OldBytes, UINT64 ReduceBytes);
BOOL VDS_IsLastAvaliable(void);
BOOL VDS_FormatVolume(char DriveLetter, int fs);
BOOL VDS_FormatVolume(char DriveLetter, int fs, DWORD ClusterSize);
//diskpart.exe
BOOL DSPT_CleanDisk(int DriveIndex);
BOOL DSPT_FormatVolume(char DriveLetter, int fs);
BOOL DSPT_FormatVolume(char DriveLetter, int fs, DWORD ClusterSize);
//powershell.exe
BOOL PSHELL_CleanDisk(int DriveIndex);
@ -63,7 +64,7 @@ BOOL PSHELL_DeleteVtoyEFIPartition(int DriveIndex, UINT64 EfiPartOffset);
BOOL PSHELL_ChangeVtoyEFI2ESP(int DriveIndex, UINT64 Offset);
BOOL PSHELL_ChangeVtoyEFI2Basic(int DriveIndex, UINT64 Offset);
BOOL PSHELL_ShrinkVolume(int DriveIndex, const char* VolumeGuid, CHAR DriveLetter, UINT64 OldBytes, UINT64 ReduceBytes);
BOOL PSHELL_FormatVolume(char DriveLetter, int fs);
BOOL PSHELL_FormatVolume(char DriveLetter, int fs, DWORD ClusterSize);
//
// Internel define

@ -86,7 +86,7 @@ BOOL DSPT_CleanDisk(int DriveIndex)
return DSPT_CommProc(CmdBuf);
}
BOOL DSPT_FormatVolume(char DriveLetter, int fs)
BOOL DSPT_FormatVolume(char DriveLetter, int fs, DWORD ClusterSize)
{
const char* fsname = NULL;
CHAR CmdBuf[256];
@ -98,15 +98,18 @@ BOOL DSPT_FormatVolume(char DriveLetter, int fs)
return FALSE;
}
if (fs == 1)
fsname = GetVentoyFsFmtNameByTypeA(fs);
if (ClusterSize > 0)
{
fsname = "NTFS";
sprintf_s(CmdBuf, sizeof(CmdBuf), "select volume %C:\r\nformat FS=%s LABEL=Ventoy UNIT=%u QUICK OVERRIDE\r\n", DriveLetter, fsname, ClusterSize);
}
else
{
fsname = "FAT32";
sprintf_s(CmdBuf, sizeof(CmdBuf), "select volume %C:\r\nformat FS=%s LABEL=Ventoy QUICK OVERRIDE\r\n", DriveLetter, fsname);
}
Log("Diskpart cmd:<%s>", CmdBuf);
sprintf_s(CmdBuf, sizeof(CmdBuf), "select volume %C:\r\nformat FS=%s LABEL=Ventoy QUICK OVERRIDE\r\n", DriveLetter, fsname);
return DSPT_CommProc(CmdBuf);
}

@ -1417,19 +1417,20 @@ BOOL VDS_ShrinkVolume(int DriveIndex, const char* VolumeGuid, CHAR DriveLetter,
STATIC BOOL VDS_CallBack_FormatVolume(void* pInterface, VDS_DISK_PROP* pDiskProp, UINT64 data)
{
int fs;
HRESULT hr, hr2;
ULONG completed;
IVdsAsync* pAsync;
IVdsVolumeMF3* pVolume = (IVdsVolumeMF3*)pInterface;
WCHAR* pFs = NULL;
WCHAR FsNTFS[32] = L"NTFS";
WCHAR FsFAT32[32] = L"FAT32";
VDS_PARA* VdsPara = (VDS_PARA*)data;
pFs = (VdsPara->Attr == 1) ? FsNTFS : FsFAT32;
Log("VDS_CallBack_FormatVolume (%C:) (%llu) ...", VdsPara->DriveLetter, (ULONGLONG)VdsPara->Attr);
fs = (int)VdsPara->Attr;
pFs = GetVentoyFsFmtNameByTypeW(fs);
Log("VDS_CallBack_FormatVolume (%C:) (%s) ClusterSize:%u ...", VdsPara->DriveLetter, GetVentoyFsFmtNameByTypeA(fs), VdsPara->ClusterSize);
hr = IVdsVolumeMF3_FormatEx2(pVolume, pFs, 0, 0, L"Ventoy", VDS_FSOF_FORCE | VDS_FSOF_QUICK, &pAsync);
hr = IVdsVolumeMF3_FormatEx2(pVolume, pFs, 0, VdsPara->ClusterSize, L"Ventoy", VDS_FSOF_FORCE | VDS_FSOF_QUICK, &pAsync);
while (SUCCEEDED(hr))
{
hr = IVdsAsync_QueryStatus(pAsync, &hr2, &completed);
@ -1465,7 +1466,7 @@ STATIC BOOL VDS_CallBack_FormatVolume(void* pInterface, VDS_DISK_PROP* pDiskProp
return TRUE;
}
BOOL VDS_FormatVolume(char DriveLetter, int fs)
BOOL VDS_FormatVolume(char DriveLetter, int fs, DWORD ClusterSize)
{
int i;
BOOL ret = FALSE;
@ -1495,6 +1496,7 @@ BOOL VDS_FormatVolume(char DriveLetter, int fs)
Para.Attr = fs;
Para.DriveLetter = DriveLetter;
Para.ClusterSize = ClusterSize;
ret = VDS_VolumeCommProc(INTF_VOLUME_MF3, wGuid, VDS_CallBack_FormatVolume, (UINT64)&Para);
Log("VDS_FormatVolume %C: <%s> ret:%d (%s)", DriveLetter, VolumeGuid, ret, ret ? "SUCCESS" : "FAIL");

@ -256,25 +256,27 @@ BOOL PSHELL_ShrinkVolume(int DriveIndex, const char* VolumeGuid, CHAR DriveLette
return ret;
}
BOOL PSHELL_FormatVolume(char DriveLetter, int fs)
BOOL PSHELL_FormatVolume(char DriveLetter, int fs, DWORD ClusterSize)
{
BOOL ret;
const char* fsname = NULL;
CHAR CmdBuf[512];
if (fs == 1)
fsname = GetVentoyFsFmtNameByTypeA(fs);
if (ClusterSize > 0)
{
fsname = "NTFS";
sprintf_s(CmdBuf, sizeof(CmdBuf),
"format-volume -DriveLetter %C -FileSystem %s -AllocationUnitSize %u -Force -NewFileSystemLabel Ventoy",
DriveLetter, fsname, ClusterSize);
}
else
{
fsname = "FAT32";
sprintf_s(CmdBuf, sizeof(CmdBuf),
"format-volume -DriveLetter %C -FileSystem %s -Force -NewFileSystemLabel Ventoy",
DriveLetter, fsname);
}
sprintf_s(CmdBuf, sizeof(CmdBuf),
"format-volume -DriveLetter %C -FileSystem %s -Force -NewFileSystemLabel Ventoy",
DriveLetter, fsname);
ret = PSHELL_CommProc(CmdBuf);
Log("PSHELL_FormatVolume %C: ret:%d (%s)", DriveLetter, ret, ret ? "SUCCESS" : "FAIL");
return ret;

@ -19,6 +19,7 @@
*/
#include <Windows.h>
#include <versionhelpers.h>
#include "Ventoy2Disk.h"
#include "Language.h"
@ -33,13 +34,3 @@ const TCHAR * GetString(enum STR_ID ID)
return NULL;
}
};
static const UINT16 g_unicode_icon[UNICODE_BUTT][3] =
{
{ 0xD83D, 0xDD12, 0x0000 },
};
const UINT16 * GetUnicodeIcon(icon)
{
return g_unicode_icon[icon];
}

@ -88,6 +88,10 @@ typedef enum STR_ID
STR_PART_VENTOY_FS, //50
STR_PART_FS, //51
STR_PART_CLUSTER, //52
STR_PART_CLUSTER_DEFAULT, //53
STR_ID_MAX
}STR_ID;
@ -151,13 +155,4 @@ const TCHAR * GetString(enum STR_ID ID);
#define _G(a) GetString(a)
typedef enum UNICODE_ICON
{
UNICODE_LOCK = 0,
UNICODE_BUTT
}UNICODE_ICON;
const UINT16 * GetUnicodeIcon(icon);
#define _UICON(i) GetUnicodeIcon(i)
#endif

@ -1106,6 +1106,79 @@ static int WriteGrubStage1ToPhyDrive(HANDLE hDrive, int PartStyle)
}
static int FormatPart1LargeFAT32(UINT64 DiskSizeBytes, int CluserSize)
{
MKFS_PARM Option;
FRESULT Ret;
FATFS FS;
Option.fmt = FM_FAT32;
Option.n_fat = 1;
Option.align = 8;
Option.n_root = 1;
if (CluserSize == 0)
{
// < 32GB select 32KB as cluster size
// > 32GB select 128KB as cluster size
if (DiskSizeBytes / 1024 / 1024 / 1024 <= 32)
{
Option.au_size = 32768;
}
else
{
Option.au_size = 131072;
}
}
else
{
Option.au_size = CluserSize;
}
Log("Formatting Part1 large FAT32 ClusterSize:%u(%uKB) ...", CluserSize, CluserSize / 1024);
disk_io_reset_write_error();
Ret = f_mkfs(TEXT("0:"), &Option, 0, 8 * 1024 * 1024);
if (FR_OK == Ret)
{
if (disk_io_is_write_error())
{
Log("Formatting Part1 large FAT32 failed, write error.");
return 1;
}
Log("Formatting Part1 large FAT32 success, now set label");
Ret = f_mount(&FS, TEXT("0:"), 1);
if (FR_OK == Ret)
{
Log("f_mount SUCCESS");
Ret = f_setlabel(TEXT("0:Ventoy"));
if (FR_OK == Ret)
{
Log("f_setlabel SUCCESS");
Ret = f_unmount(TEXT("0:"));
Log("f_unmount %d %s", Ret, (FR_OK == Ret) ? "SUCCESS" : "FAILED");
}
else
{
Log("f_setlabel failed %d", Ret);
}
}
else
{
Log("f_mount failed %d", Ret);
}
return 0;
}
else
{
Log("Formatting Part1 large FAT32 failed");
return 1;
}
}
static int FormatPart1exFAT(UINT64 DiskSizeBytes)
{
@ -1636,6 +1709,7 @@ int InstallVentoy2PhyDrive(PHY_DRIVE_INFO *pPhyDrive, int PartStyle, int TryId)
UINT64 Part1StartSector = 0;
UINT64 Part1SectorCount = 0;
UINT64 Part2StartSector = 0;
BOOL LargeFAT32 = FALSE;
Log("#####################################################");
Log("InstallVentoy2PhyDrive try%d %s PhyDrive%d <<%s %s %dGB>>", TryId,
@ -1737,13 +1811,28 @@ int InstallVentoy2PhyDrive(PHY_DRIVE_INFO *pPhyDrive, int PartStyle, int TryId)
Sleep(1000 * 5);
}
Log("Formatting part1 exFAT ...");
if (0 != FormatPart1exFAT(pPhyDrive->SizeInBytes))
if (GetVentoyFsType() == VTOY_FS_FAT32 && (Part1SectorCount * 512 >= FAT32_MAX_LIMIT))
{
Log("FormatPart1exFAT failed.");
rc = 1;
goto End;
Log("Formatting part1 large FAT32 ...");
LargeFAT32 = TRUE;
if (0 != FormatPart1LargeFAT32(pPhyDrive->SizeInBytes, GetClusterSize()))
{
Log("FormatPart1LargeFAT32 failed.");
rc = 1;
goto End;
}
}
else
{
Log("Formatting part1 exFAT ...");
if (0 != FormatPart1exFAT(pPhyDrive->SizeInBytes))
{
Log("FormatPart1exFAT failed.");
rc = 1;
goto End;
}
}
PROGRESS_BAR_SET_POS(PT_FORMAT_PART2);
Log("Writing part2 FAT img ...");
@ -1867,21 +1956,34 @@ End:
}
}
if (GetVentoyFsType() > 0)
if (state)
{
if (state)
if (LargeFAT32)
{
Log("No need to reformat for large FAT32");
pPhyDrive->VentoyFsClusterSize = GetVolumeClusterSize(MountDrive);
}
else if (DISK_FormatVolume(MountDrive, GetVentoyFsType(), Part1SectorCount * 512))
{
Log("Reformat %C:\\ to %s", MountDrive, GetVentoyFsName());
DISK_FormatVolume(MountDrive, GetVentoyFsType());
Log("Reformat %C:\\ to %s SUCCESS", MountDrive, GetVentoyFsName());
pPhyDrive->VentoyFsClusterSize = GetVolumeClusterSize(MountDrive);
if ((GetVentoyFsType() != VTOY_FS_UDF) && (pPhyDrive->VentoyFsClusterSize < 2048))
{
for (i = 0; i < 10; i++)
{
Log("### Invalid cluster size %d ###", pPhyDrive->VentoyFsClusterSize);
}
}
}
else
{
Log("Can not reformat %s to %s", DriveName, GetVentoyFsName());
Log("Reformat %C:\\ to %s FAILED", MountDrive, GetVentoyFsName());
}
}
else
{
Log("No need to reformat ventoy partition");
Log("Can not reformat %s to %s", DriveName, GetVentoyFsName());
}
Log("OK\n");

@ -251,10 +251,34 @@ static BOOL IsVentoyPhyDrive(int PhyDrive, UINT64 SizeBytes, MBR_HEAD *pMBR, UIN
return TRUE;
}
int GetVolumeClusterSize(char Drive)
{
CHAR Volume[32] = { 0 };
DWORD SectorsPerCluster = 0;
DWORD BytesPerSector = 0;
DWORD NumberOfFreeClusters = 0;
DWORD TotalNumberOfClusters = 0;
sprintf_s(Volume, sizeof(Volume), "%C:\\", Drive);
if (GetDiskFreeSpaceA(Volume, &SectorsPerCluster, &BytesPerSector, &NumberOfFreeClusters, &TotalNumberOfClusters))
{
Log("GetVolumeClusterSize %s SUCCESS %u %u %u", Volume, SectorsPerCluster, BytesPerSector, SectorsPerCluster * BytesPerSector);
return (int)(SectorsPerCluster * BytesPerSector);
}
else
{
Log("GetVolumeClusterSize %s failed err:%u", Volume, LASTERR);
}
return 0;
}
static int GetVentoyFsNameInPhyDrive(PHY_DRIVE_INFO* CurDrive)
{
int i = 0;
UINT64 Offset;
CHAR Volume[128] = { 0 };
CHAR FsName[MAX_PATH] = { 0 };
@ -276,6 +300,8 @@ static int GetVentoyFsNameInPhyDrive(PHY_DRIVE_INFO* CurDrive)
if (Volume[0])
{
CurDrive->VentoyFsClusterSize = GetVolumeClusterSize(Volume[0]);
if (GetVolumeInformationA(Volume, NULL, 0, NULL, NULL, NULL, FsName, MAX_PATH))
{
if (_stricmp(FsName, "exFAT") == 0)

@ -23,7 +23,20 @@
#include <stdio.h>
typedef enum VTOY_FS
{
VTOY_FS_EXFAT = 0,
VTOY_FS_NTFS,
VTOY_FS_FAT32,
VTOY_FS_UDF,
VTOY_FS_BUTT
}VTOY_FS;
#define FAT32_MAX_LIMIT (32 * 1073741824ULL)
#define SIZE_1KB (1024)
#define SIZE_1GB (1024 * 1024 * 1024)
#define SIZE_1TB (1024ULL * 1024ULL * 1024ULL * 1024ULL)
#define SIZE_1MB (1024 * 1024)
#define SIZE_2MB (2048 * 1024)
#define VENTOY_EFI_PART_SIZE (32 * SIZE_1MB)
@ -160,6 +173,7 @@ typedef struct PHY_DRIVE_INFO
CHAR DriveLetters[64];
int VentoyFsClusterSize;
CHAR VentoyFsType[16];
CHAR VentoyVersion[32];
@ -251,6 +265,7 @@ int INIT unxz(unsigned char *in, int in_size,
unsigned char *out, int *in_used,
void(*error)(char *x));
void disk_io_set_param(HANDLE Handle, UINT64 SectorCount);
int GetVolumeClusterSize(char Drive);
extern BOOL g_InputYes;
INT_PTR CALLBACK YesDialogProc(HWND hWnd, UINT Message, WPARAM wParam, LPARAM lParam);
@ -259,7 +274,14 @@ int GetReservedSpaceInMB(void);
int IsPartNeed4KBAlign(void);
int GetVentoyFsType(void);
void SetVentoyFsType(int fs);
int GetClusterSize(void);
void SetClusterSize(int ClusterSize);
WCHAR* GetClusterSizeTip(void);
void FormatClusterSizeTip(int Size, WCHAR* pBuf, size_t len);
const char* GetVentoyFsName(void);
const char* GetVentoyFsNameByType(int fs);
CHAR* GetVentoyFsFmtNameByTypeA(int fs);
WCHAR* GetVentoyFsFmtNameByTypeW(int fs);
int FindProcessOccupyDisk(HANDLE hDrive, PHY_DRIVE_INFO *pPhyDrive);
int VentoyFillMBRLocation(UINT64 DiskSizeInBytes, UINT32 StartSectorId, UINT32 SectorCount, PART_TABLE *Table);
int ClearVentoyFromPhyDrive(HWND hWnd, PHY_DRIVE_INFO *pPhyDrive, char *pDrvLetter);
@ -270,8 +292,6 @@ BOOL PartResizePreCheck(PHY_DRIVE_INFO** ppPhyDrive);
liCurrentPosition.QuadPart = pos; \
SetFilePointerEx(hDrive, liCurrentPosition, &liCurrentPosition, FILE_BEGIN)\
#define SECURE_ICON_STRING _UICON(UNICODE_LOCK)
extern int g_WriteImage;
#define VTSI_IMG_MAGIC 0x0000594F544E4556ULL // "VENTOY\0\0"

@ -400,6 +400,7 @@
<Image Include="res\icon2.ico" />
<Image Include="Res\refresh.ico" />
<Image Include="Res\secure.ico" />
<Image Include="Res\secure2.ico" />
<Image Include="Res\ventoy.ico" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />

@ -180,5 +180,8 @@
<Image Include="Res\secure.ico">
<Filter>资源文件</Filter>
</Image>
<Image Include="Res\secure2.ico">
<Filter>资源文件</Filter>
</Image>
</ItemGroup>
</Project>
Loading…
Cancel
Save