/* 
   Name: resources.rc
   Author: Kip Warner
   Description: Resource script...
   Copyright: Yes
*/

#include <windows.h>
#include "resources.h"
#include "../prototypes.h"

// Icon and cursor...
IDI_ICON        ICON    LOADONCALL DISCARDABLE "resources/icon.ico"

// Logo...
ID_LOGOBOX      BITMAP  LOADONCALL DISCARDABLE "resources/logo.bmp"

// Swap.exe (for self upgrades)...
IDE_SWAP        EXE     "resources/swap.exe"

// Options dialog box...
OptionsBox DIALOG DISCARDABLE 32, 32, 320, 192
CAPTION "Options"
STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
FONT 8, "Lucida Console"
    BEGIN

        // Buttons...
        DEFPUSHBUTTON   "OK", IDOK, 265, 135, 50, 14
        PUSHBUTTON      "Default", IDD_DEFAULT, 265, 152, 50, 14

        // "Interface" groupbox and contents...
        GROUPBOX "Interface...", IDC_STATIC, 5, 5, 100, 65
                AUTOCHECKBOX  "Cool progress bar",  IDD_INTERFACE_SMOOTH_PROGRESS_BAR, 10, 20, 85, 10
                AUTOCHECKBOX  "Cheesy Dev-C++ theme",IDD_INTERFACE_DEV_THEME, 10, 35, 90, 10, WS_DISABLED
                AUTOCHECKBOX  "Enable previews",    IDD_INTERFACE_PREVIEWS, 10, 50, 85, 10

        // "Only show me" groupbox and contents...
        GROUPBOX "List...", IDC_STATIC, 5, 75, 100, 110
                AUTOCHECKBOX  "Packages (.DevPak)", IDD_LIST_PACKAGES, 10, 90, 85, 10
                AUTOCHECKBOX  "Patches",            IDD_LIST_PATCHES, 10, 105, 85, 10
                AUTOCHECKBOX  "Language files",     IDD_LIST_LANGUAGES, 10, 120, 85, 10
                COMBOBOX      "",                   IDD_LIST_LANGUAGES_LIST, 30, 133, 65, 60, CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL
                AUTOCHECKBOX  "Help files",         IDD_LIST_HELP, 10, 150, 85, 10
                AUTOCHECKBOX  "Other stuff",        IDD_LIST_OTHER, 10, 165, 85, 10

        // "Advanced" group box and contents...
        GROUPBOX "Advanced...",  IDC_STATIC, 110, 5, 205, 123
            AUTOCHECKBOX "Generate debug log",      IDD_ADVANCED_DEBUG_LOG, 115, 20, 90, 10
            PUSHBUTTON   "Edit install log",        IDD_ADVANCED_EDIT_INSTALL_LOG, 115, 35, 90, 15
            PUSHBUTTON   "Manual self-update",      IDD_ADVANCED_MANUAL_UPDATE, 115, 55, 90, 15
            AUTOCHECKBOX "Use proxy",               IDD_ADVANCED_PROXY_FLAG, 115, 75, 90, 10
            LTEXT        "Server:",                 IDC_STATIC, 115, 95, 35, 10
            EDITTEXT     "hostname",                IDD_ADVANCED_PROXY_SERVER, 155, 95, 140, 12, ES_AUTOHSCROLL
            LTEXT        "Port:",                   IDC_STATIC, 115,110, 35, 10
            EDITTEXT     "8010",                    IDD_ADVANCED_PROXY_PORT, 155,110, 20, 12, ES_AUTOHSCROLL

        // Description box...
        EDITTEXT "ERROR",
                 IDD_OPTION_DESCRIPTION, 110, 135, 150, 50, ES_READONLY | ES_LEFT | 
                 ES_MULTILINE | WS_VSCROLL

    END

// About dialog box...
AboutBox DIALOG DISCARDABLE 32, 32, 160, 300
STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
CAPTION "About"
FONT 8, "Lucida Console"
    BEGIN
        DEFPUSHBUTTON   "OK", IDOK, 25, 280, 50, 14
        PUSHBUTTON      "User Manual", IDD_USER_MANUAL, 85, 280, 50, 14
        ICON            IDI_ICON, IDC_STATIC, 7, 7, 21, 20

        LTEXT           "vUpdate - by Vertigo", IDC_STATIC, 40, 12,  100, 8
        LTEXT           VUPDATE_VERSION_CHAR, IDC_STATIC, 40, 22,  100, 8
        
        PUSHBUTTON      "Programmer: Kip Warner", IDD_PROGRAMMER, 7, 50, 145, 12, BS_LEFT 
        PUSHBUTTON      "E-Mail:     kip@zero47.com", IDD_EMAIL, 7, 62, 145, 12, BS_LEFT 
        PUSHBUTTON      "ICQ:        29008229", IDD_ICQ, 7, 74, 145, 12, BS_LEFT 
        PUSHBUTTON      "URL:        http://www.zero47.com", IDD_URL, 7, 86, 145, 12, BS_LEFT

        CTEXT           """Software for the BBS generation""", IDC_STATIC, 7, 110, 144, 8
        
        EDITTEXT        "ERROR", IDD_LICENSE, 7, 130, 146, 140, WS_BORDER | ES_READONLY | ES_LEFT | ES_MULTILINE | WS_VSCROLL
    END

    // special thx to game over for being patient and always listening
    // Stock class code, the only way to play...

// SelfUpdate dialog box...
SelfUpdate DIALOG DISCARDABLE 32, 32, 110, 180
STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
CAPTION "Self Upgrade"
FONT 8, "Lucida Console"
    BEGIN
        LTEXT           "You have...", IDC_STATIC, 5, 5, 100, 10
        EDITTEXT        ""            VUPDATE_VERSION_CHAR, IDD_LOCAL_VERSION, 5, 15, 100, 10, WS_DISABLED
        
        LTEXT           "Available...", IDC_STATIC, 5, 35, 100, 10
        EDITTEXT        "ERROR", IDD_AVAILABLE_VERSION, 5, 45, 100, 10, WS_DISABLED
        
        LTEXT           "What's new?", IDC_STATIC, 5, 65, 100, 10
        EDITTEXT        "ERROR", IDD_UPDATE_COMMENTS, 5, 75, 100, 80, WS_BORDER | ES_READONLY | ES_LEFT | ES_MULTILINE | WS_VSCROLL

        DEFPUSHBUTTON   "Upgrade", IDYES, 5, 160, 45, 14
        PUSHBUTTON      "Cancel", IDNO, 60, 160, 45, 14
    END

// Exe image version stuff...
1 VERSIONINFO
FILEVERSION VUPDATE_FILE_VERSION
PRODUCTVERSION VUPDATE_FILE_VERSION
FILETYPE VFT_APP
    BEGIN                                     
      BLOCK "StringFileInfo"
      BEGIN
        BLOCK "040904E4"                      // &H0409 = LANG_ID English, &H04E4 = charset ANSI
        BEGIN
          VALUE "CompanyName",      "Vertigo"
          VALUE "FileDescription",  "vUpdate - The world's most pimpin webupdater (sometimes)"
          VALUE "FileVersion",      VUPDATE_VERSION_CHAR
          VALUE "InternalName",     "vUpdate"
          VALUE "LegalTradeMarks",  "Vertigo - Software for the BBS generation."
          VALUE "OriginalFilename", "vUpdate.exe"
          VALUE "ProductName",      "vUpdate"
          VALUE "ProductVersion",   VUPDATE_VERSION_CHAR
        END
      END
      BLOCK "VarFileInfo"
      BEGIN
        VALUE "Translation", 0x0409, 1252
      END
    END

