DEADSOFTWARE

AddResource: Fix non-ANSI encoding
authorbinarymaster <x86corez@gmail.com>
Thu, 28 Sep 2017 13:39:32 +0000 (16:39 +0300)
committerbinarymaster <x86corez@gmail.com>
Thu, 28 Sep 2017 13:39:32 +0000 (16:39 +0300)
src/editor/f_addresource.pas
src/editor/f_addresource_texture.pas
src/editor/f_main.pas

index 514cf5cdfa6e42c8f6ed9f3d535425d79801da33..edca4ed817570b631ebabe9260132922159974da 100644 (file)
@@ -114,7 +114,7 @@ begin
 
 // Внешний WAD:
   if cbWADList.Text <> _lc[I_WAD_SPECIAL_MAP] then
-     FileName := EditorDir+'wads/'+utf2win(cbWADList.Text)
+     FileName := EditorDir+'wads/'+cbWADList.Text
   else // WAD карты:
     begin
       g_ProcessResourceStr(OpenedMap, fn, sn, rn);
@@ -149,7 +149,7 @@ begin
 
 // Внешний WAD:
   if cbWADList.Text <> _lc[I_WAD_SPECIAL_MAP] then
-    FileName := EditorDir+'wads/'+utf2win(cbWADList.Text)
+    FileName := EditorDir+'wads/'+cbWADList.Text
   else // WAD карты:
     begin
       g_ProcessResourceStr(OpenedMap, fn, sn, rn);
@@ -197,7 +197,7 @@ begin
     SectionName := utf2win(cbSectionsList.Text);
 
   if cbWADList.Text[1] <> '<' then
-    FileName := utf2win(cbWADList.Text)
+    FileName := cbWADList.Text
   else
     FileName := '';
 
index f3b3fade582900933aa608f587fe3c23e9479b12..6c3840d627d290c4dd44f1261a09c24a7f377031 100644 (file)
@@ -488,7 +488,7 @@ begin
   for i := 0 to lbResourcesList.Count-1 do
     if lbResourcesList.Selected[i] then
     begin
-      AddTexture(utf2win(cbWADlist.Text), utf2win(cbSectionsList.Text),
+      AddTexture(cbWADlist.Text, utf2win(cbSectionsList.Text),
                  utf2win(lbResourcesList.Items[i]), False);
       lbResourcesList.Selected[i] := False;
     end;
index 90652570f29530fb3330912e0865815499e7b582..8bdab7d638cc7c829574a91ebb9c7a3bc960a1cd 100644 (file)
@@ -1909,7 +1909,7 @@ begin
     else
       begin // Внешний WAD
         FileName := EditorDir+'wads/'+aWAD;
-        ResourceName := aWAD+':'+SectionName+'\'+aTex;
+        ResourceName := utf2win(aWAD)+':'+SectionName+'\'+aTex;
       end;
 
   ok := True;