/*
   Bacula(R) - The Network Backup Solution

   Copyright (C) 2000-2020 Kern Sibbald

   The original author of Bacula is Kern Sibbald, with contributions
   from many others, a complete list can be found in the file AUTHORS.

   You may use this file and others of this release according to the
   license defined in the LICENSE file, which includes the Affero General
   Public License, v3.0 ("AGPLv3") and some additional permissions and
   terms pursuant to its AGPLv3 Section 7.

   This notice must be preserved when any source code is
   conveyed and/or propagated.

   Bacula(R) is a registered trademark of Kern Sibbald.
*/
/*
 * Generic version of Bacula resource 
 * 
 */

#include <winuser.h>
#include <winver.h>
#include "res.h"
#include "../../version.h"

/********************************************************************
 *
 * Icons
 *
 * Icon with lowest ID value placed first to ensure application icon
 * remains consistent on all systems.
 */
IDI_BACULA          ICON    "../libwin32/bacula.ico"
IDI_IDLE            ICON    "../libwin32/idle.ico"
IDI_RUNNING         ICON    "../libwin32/running.ico"
IDI_JOB_ERROR       ICON    "../libwin32/error.ico"
IDI_JOB_WARNING     ICON    "../libwin32/warn.ico"

/********************************************************************        
 *
 * Menu
 *
 */
IDR_TRAYMENU MENU
BEGIN
    POPUP "tray"
    BEGIN
        MENUITEM "&Status",            ID_STATUS
        MENUITEM SEPARATOR
        MENUITEM "&About Bacula",      ID_ABOUT
//      MENUITEM SEPARATOR
//      MENUITEM "&Close Bacula",      ID_CLOSE
    END
END


/********************************************************************
 *
 * Version
 */

#ifdef _DEBUG
#define FILEFLAGS_ARG VS_FF_DEBUG
#else
#define FILEFLAGS_ARG 0x0L
#endif
#ifdef _WIN64
#define FILEDESCRIPTION_ARG "Bacula(R) File daemon for Win64\0"
#define PRODUCTNAME_ARG "Bacula(R) - Win64 Version\0"
#else
#define FILEDESCRIPTION_ARG "Bacula(R) File daemon for Win32\0"
#define PRODUCTNAME_ARG "Bacula(R) - Win32 Version\0"
#endif

VS_VERSION_INFO VERSIONINFO
    FILEVERSION VER_MAJOR,VER_MINOR,VER_BUILD,VER_REVISION
    PRODUCTVERSION VER_MAJOR,VER_MINOR,VER_BUILD,VER_REVISION
    FILEFLAGSMASK 0x3fL
    FILEFLAGS FILEFLAGS_ARG
    FILEOS VOS_NT_WINDOWS32
    FILETYPE VFT_APP
    FILESUBTYPE 0x0L
    BEGIN
        BLOCK "StringFileInfo"
        BEGIN
            BLOCK "040904e4"
            BEGIN
                VALUE "Comments", "by Kern Sibbald\0"
                VALUE "CompanyName", "Bacula Systems(R) SA\0"
                VALUE "FileDescription", FILEDESCRIPTION_ARG
                VALUE "ProductName", PRODUCTNAME_ARG
                VALUE "FileVersion", VERSION
                VALUE "InternalName", "Bacula\0"
                VALUE "LegalCopyright", "Copyright (C) 1999-2021 Kern Sibbald.\0"
                VALUE "LegalTrademarks", "Bacula Systems(R)\0"
                VALUE "ProductVersion", VERSION
            END
        END
        BLOCK "VarFileInfo"
        BEGIN
            VALUE "Translation", 0x0409, 1252
        END
    END
/* End of Version info */



/***********************************************************************
 *
 * Bitmap
 *
 */
IDB_BACULABMP           BITMAP  DISCARDABLE     "../libwin32/bacula.bmp"

/***********************************************************************
 *
 * String Table
 */
STRINGTABLE 
BEGIN
    IDI_BACULA              "Bacula"
END

/***********************************************************************
 *
 * About Dialog
 */
IDD_ABOUT DIALOG  0, 0, 250, 145
#if !defined(MINGW64) && !defined(HAVE_MINGW_W64)
STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU
#endif
CAPTION "About Bacula"
FONT 8, "MS Sans Serif"
BEGIN
#if !defined(MINGW64) && !defined(HAVE_MINGW_W64)
    DEFPUSHBUTTON   "OK",IDOK,190,120,50,15
#endif
//  CONTROL         "\3", IDC_BACULABMP,"Static",SS_ICON | SS_CENTERIMAGE |
//                  SS_SUNKEN,7,5,73,65
#if !defined(HAVE_MINGW) && !defined(MINGW64) && !defined(HAVE_MINGW_W64)
    CONTROL         IDB_BACULABMP,IDB_BACULABMP,"Static",SS_BITMAP|SS_SUNKEN,7,5,32,32
#endif

    LTEXT           "      by Kern Sibbald",-1,134,38,78,10
    LTEXT           "For more information, see:",-1,115,60,100,10
    LTEXT           "         www.bacula.org",-1,115,70,100,10
    LTEXT           "Copyright (C) 1999-2021, Kern Sibbald",-1,7,120,175,10
    LTEXT           "Licensed by Kern Sibbald.",-1,7,130,175,10
    RTEXT           "Build Date:",-1,108,24,42,8
    RTEXT           "Bacula Version:",-1,100,9,50,8
    LTEXT           VERSION,-1,159,10,65,8
    LTEXT           BDATE,-1,159,24,65,10

END

/************************************************************************
 *
 * Status Dialog
 */
IDD_STATUS DIALOGEX 0, 0, 411, 244
#if !defined(MINGW64) && !defined(HAVE_MINGW_W64)
STYLE DS_SETFONT | DS_3DLOOK | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_THICKFRAME
#endif
CAPTION "Bacula Status"
FONT 8, "Courier New"
BEGIN
#if !defined(MINGW64) && !defined(HAVE_MINGW_W64)
    DEFPUSHBUTTON   "&OK",IDOK,355,5,51,15
    EDITTEXT        IDC_TEXTDISPLAY, 2, 2, 350, 240, WS_VSCROLL | WS_HSCROLL | WS_BORDER | ES_READONLY | ES_MULTILINE
#endif
END
