/*
CLASS {NATIVE_Localize_str|_CSharp}, NATIVE, UNTESTED :

IMPORT: {System_functions} .

*/

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;

using AL4;

namespace AL4_project
{
public class NATIVE_Localize_str
{
    
    /*
    //{ get strings stored by a compiler }
    
    FUN Set_path_directory_lang|uage_files( STR Dir|ectory_path ),
        NATIVE :
        "    Methods_C_NATIVE_Localize_str.directory_lang = X_Dir;" .
        
    FUN Get_path_directory_lang ==> STR, NATIVE :
        "    RESULT = Methods_C_NATIVE_Localize_str.directory_lang;" .
    
    FUN Get_untranslated_strings( STR S|trings_array[] ), NATIVE:
        S[].Clear
        NATIVE @ "    NATIVE_Localize_str.do_Get_untranslated_strings(X_S);" .
        
    */
    public static void do_Get_untranslated_strings(ArrayStr X_S)
    {
//?{Localize_str}
            for (int i = 0; i < AL4_system.Localize_str.Length; i++)
                if (AL4_system.Localize_str[i] == "" ||
                	AL4_system.Localize_str[i] == " #QU#QU ") 
                {
                    if (AL4_system.Localize_name[i][0] != '[')
                        X_S.Add("[" + AL4_system.Localize_name[i]
                        + "]");
                    else X_S.Add(AL4_system.Localize_name[i]);
                }
                else X_S.Add(AL4_system.Localize_name[i] +
                    "=" + AL4_system.Localize_str[i]);
//.
    }
    /*
    
        
    FUN Set_translated_strings( STR N|ames_array[], STR S|trings_array[]), 
        NATIVE :
       @"   for (int i = 0; i < X_S.Count; i++)"
        "       if (i < AL4_system.Localize_name.Length)"
        "       {"
        "           AL4_system.Localize_name[i] = X_N[i];"
        "           AL4_system.Localize_str[i] = X_S[i];"
        "       }"
        "       else break;" .
        
    FUN Are_untranslated_saved ==> BOOL, NATIVE :
        "RESULT = Methods_C_NATIVE_Localize_str.untranslated_saved;" .
        
    FUN Set_untranslated_saved( BOOL Sav|ed_flag ), NATIVE :
        "Methods_C_NATIVE_Localize_str.untranslated_saved = X_Sav;" .
        
    NATIVE: @ "public static bool untranslated_saved;"
               "public static string directory_lang = "#QU#QU";" .
        
    FUN Path_translated_strings ==> STR :
        RESULT = Get_application_data_dir .
        
    */

}
}
/*
END
*/

