/* Copyright (c) Oracle Corporation 1996.  All Rights Reserved */

/*****************************************************************************
  NAME
    Flang50.ins - V3 installation script for Dev2000 Forms Language Supplement

  DESCRIPTION
    This script installs Forms Language Supplement.

  MODIFIED      MM/DD/YY        REASON
  pgupta        08/14/97        Created
  majain        01/18/99        modified to add new groups (lang-6.0.8.10.0)
*****************************************************************************/

{
    if(not(doit))
    {
       if(member(selected_products, w32formsl60))
       {
          information_dialog("Language Supplement Files are not required if English is chosen");
       }
    }
    if (doit)
    {

        /*****************************
        Set the VRF-INS script ratchet
        ******************************/
        ins_ratchet = "6.0.0.0.0";

        execute("%installer_home%%dir_separator%%operating_system%.ins");

        permit_retry_operations  = TRUE;
        permit_ignore_operations = TRUE;
        permit_process_operations= TRUE;

        win32_register_OCSM_product();


        if(child_in_control)
            if(install_parent)
                install(product_parent(current_product));
        /***********************************/
        /***************************************************************
         Registering map variables except Installer_home and oracle_home
        ****************************************************************/
         win32_register_map_variable("FORMS60");
         win32_register_map_variable("DOC60");

        /******************
        Install the product
        *******************/
        ui_product(instantiate(display_product_label));

        ui_action(instantiate(install_files));
        copy(deinst);
        if(install_frunres)
            {
                ui_action(instantiate(install_files));
                copy(frunres, nls_abbreviation);
                win32_register_OCSM_group(frunres,"nls_abbreviation",'MEDMODE);
            }
         if(install_frunweb)
            {
                ui_action(instantiate(install_files));
                copy(frunweb, nls_abbreviation);
                win32_register_OCSM_group(frunweb,"nls_abbreviation",'MEDMODE);
            }

        if(install_fdesres)
            {
                ui_action(instantiate(install_files));
                copy(fdesres, nls_abbreviation);
                win32_register_OCSM_group(fdesres,"nls_abbreviation",'MEDMODE);
            }

        if(install_fmsg)
            {
                ui_action(instantiate(install_files));
                copy(fmsg,nls_abbreviation);
                win32_register_OCSM_group(fmsg,"nls_abbreviation",'MEDMODE);
            }



        if(install_fhelp)
            {
                ui_action(instantiate(install_files));
                copy(fhelp,nls_abbreviation);
                win32_register_OCSM_group(fhelp,"nls_abbreviation",'MEDMODE);
            }



        if(install_fcuesnd)
            {
                ui_action(instantiate(install_files));
                copy(fcuesnd,nls_abbreviation);
                win32_register_OCSM_group(fcuesnd,"nls_abbreviation",'MEDMODE);
            }

if (operating_system == "nt") {

      if(registered("w32frunw60")|| member(selected_products,w32frunw60))
       {	   
		    ui_action(instantiate(install_files));
                copy(fservlet,nls_abbreviation);
                /*win32_register_OCSM_group(frunw,"nls_abbreviation",'MEDMODE);*/
       }
   }


       /******************/

        /*********************************
        Register and Reference the product
        and remove delold
        **********************************/
        EXECUTE_SCRIPT = "REGISTER_REFERENCE_PRODUCT";
        execute("%installer_home%%dir_separator%d2kr2ins.usr");
      /************************************************/

         permit_retry_operations = FALSE;
        /***********************************/


        /*****************************************/

        permit_retry_operations = TRUE;


        /*********************
        Reference dependencies
        **********************/
        ui_action(instantiate(reference_dependencies));

        {reference(current_product,product_parent(current_product));}  /* reference parent */
        ['UNREGISTERED_PRODUCT: continue();]

        /*********************/
        permit_retry_operations = FALSE;

    }
    [
         'UNREGISTERED_PRODUCT: continue();
         'CANCEL: signal('FAILURE, instantiate(halt_installation));
    ]
}
