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

/*****************************************************************************
  NAME
    fdes60.ins - V3 installation script for Oracle Forms 6.0 Designer

  DESCRIPTION
    This script installs Oracle Forms 6.0 Designer.

  MODIFIED      MM/DD/YY        REASON
*****************************************************************************/

{
    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;

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

        ui_action(instantiate(install_files));
        copy(deinst);

        /***********************************************
        Display "NETWORK COMPUTING ARCHITECTURE" billboard if not
        already displayed, and if Developer release
        ************************************************/
        if(exists("%installer_home%%dir_separator%d2bb_03.bmp"))
        {
            if(not(DEV2K_BB03))
            {
                DEV2K_BB03 = TRUE;
                ui_graphics("%installer_home%%dir_separator%d2bb_03.bmp");
            }
        }
        /***********************************************/

        ui_action(instantiate(install_exe));
        copy(exe);


        /************************************************************
        Delete the Old Program Group if present and Install the new
        Program Group
        *************************************************************/

        if(exists("%ORACLE_HOME%/bin/ifbld60.exe"))
        {
          D2KIF60_GROUP = D2K60_GROUP_OLD;
          windows_delete_icons(exe);
          D2KIF60_GROUP = D2KIF60_GROUP_NEW;
        }
        /*************************************************************/

        ui_action(instantiate(install_dll));
        copy(dll);

        ui_action(instantiate(install_files));
        copy(res);
        copy(ue);

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

        permit_retry_operations = FALSE;

        /*********************************
        Install Forms Runtime, if required
        **********************************/
        while(not(empty(component_products_to_install)))
        {
            install(first(component_products_to_install));
            component_products_to_install = rest(component_products_to_install);
        }
        /*********************************/

        /************************
        Install required products
        *************************/
        while(not(empty(required_products_to_install)))
        {
            install(first(required_products_to_install));
            required_products_to_install = rest(required_products_to_install);
        }
        /*******************/

        /*********************************
        Install FORMS  Language Supplement
        **********************************/
        if(child_in_control)
        {
            install_fdes = TRUE;
            install(w32formsl60);
        }
        /******************************************************
        Display the "Object Orientation You Can Use" billboard
        if not already displayed, and if Developer release
        *******************************************************/
        if(exists("%installer_home%%dir_separator%d2bb_07.bmp"))
        {
            if(not(DEV2K_BB07))
            {
                DEV2K_BB07 = TRUE;
                ui_graphics("%installer_home%%dir_separator%d2bb_07.bmp");
            }
        }
        /******************************************************/


        /************************
        Install required products
        *************************/
        while(not(empty(required_products_to_install)))
        {
            install(first(required_products_to_install));
            required_products_to_install = rest(required_products_to_install);
        }
        /*******************/
        /************************************************************/
        permit_retry_operations = TRUE;

        /***************************************************************
         Registering map variables except Installer_home and oracle_home
        ****************************************************************/
         win32_register_map_variable("FORMS60");
         win32_register_map_variable("DOC60");
         win32_register_map_variable("D2KIF60_GROUP");

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

        /*********************
        Reference Dependencies
        **********************/
        ui_action(instantiate(reference_dependencies));
        {reference(current_product,product_parent(current_product));}  /* reference parent */
        ['UNREGISTERED_PRODUCT: continue();]

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

        {reference(w32ge60, current_product);}                     /* reference chart wizard */
        ['UNREGISTERED_PRODUCT: continue();]

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

        {reference(w32d2kdoc60, current_product);}                           /* reference Online Documentation */
        ['UNREGISTERED_PRODUCT: continue();]


        {reference(w32d2kqt60, current_product);}                           /* reference quick tour */
        ['UNREGISTERED_PRODUCT: continue();]


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

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

        permit_retry_operations = FALSE;

    } /*END if doit*/
    [
        'UNREGISTERED_PRODUCT: continue();
        'CANCEL: signal('FAILURE, instantiate(halt_installation));
    ]
} /*END fdes60.ins*/
