Set version and icon in mission compiler frontend

feature/version-resources
kaetemi 6 years ago
parent 77bceea45d
commit 88ca583290

@ -1,5 +1,7 @@
FILE(GLOB SRC *.cpp *.h *.rc *.rc2)
SOURCE_GROUP("" FILES ${SRC})
ENABLE_LANGUAGE(RC)
ADD_DEFINITIONS(${MFC_DEFINITIONS})
SET(CMAKE_MFC_FLAG 2)

@ -1,8 +1,10 @@
FILE(GLOB SRC *.cpp *.h)
FILE(GLOB SRC *.cpp *.h *.rc *.rc2 res/*.rc2 res/*.ico)
SOURCE_GROUP("" FILES ${SRC})
ADD_DEFINITIONS(${MFC_DEFINITIONS})
SET(CMAKE_MFC_FLAG 2)
ADD_EXECUTABLE(ryzom_mission_compiler_fe WIN32 ${SRC} mission_compiler_fe.rc)
ADD_EXECUTABLE(ryzom_mission_compiler_fe WIN32 ${SRC})
TARGET_LINK_LIBRARIES(ryzom_mission_compiler_fe nelmisc nelligo ryzom_mission_compiler_lib)

@ -1,21 +1,5 @@
// Ryzom - MMORPG Framework <http://dev.ryzom.com/projects/ryzom/>
// Copyright (C) 2010 Winch Gate Property Limited
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
//{{NO_DEPENDENCIES}}
// Microsoft Developer Studio generated include file.
// Microsoft Visual C++ generated include file.
// Used by mission_compiler_fe.rc
//
#define IDM_ABOUTBOX 0x0010
@ -28,6 +12,7 @@
#define IDR_MENU1 131
#define IDD_DIALOG_ADD_PATH 132
#define IDD_DIALOG_MODE 133
#define IDS_VERSIONTEXT 140
#define IDC_LIST_SRC 1000
#define IDC_LIST_DST 1001
#define IDC_ADD 1002

@ -1,4 +1,4 @@
//Microsoft Developer Studio generated resource script.
// Microsoft Visual C++ generated resource script.
//
#include "resource.h"
@ -16,25 +16,15 @@
// English resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
#ifdef _WIN32
LANGUAGE LANG_ENGLISH, SUBLANG_NEUTRAL
#pragma code_page(1252)
#endif //_WIN32
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
/////////////////////////////////////////////////////////////////////////////
//
// Menu
//
IDR_MENU1 MENU DISCARDABLE
IDR_MENU1 MENU
BEGIN
POPUP "Special"
BEGIN
@ -49,76 +39,25 @@ END
// Dialog
//
IDD_DIALOG_ADD_PATH DIALOG DISCARDABLE 0, 0, 283, 46
STYLE WS_POPUP | WS_CAPTION
IDD_DIALOG_ADD_PATH DIALOG 0, 0, 283, 46
STYLE DS_SETFONT | WS_POPUP | WS_CAPTION
CAPTION "Init compiler..."
FONT 8, "MS Sans Serif"
BEGIN
EDITTEXT IDC_ADD_PATH,7,7,269,32,ES_MULTILINE | ES_AUTOVSCROLL |
ES_AUTOHSCROLL | ES_READONLY
END
/////////////////////////////////////////////////////////////////////////////
//
// DESIGNINFO
//
#ifdef APSTUDIO_INVOKED
GUIDELINES DESIGNINFO DISCARDABLE
BEGIN
IDD_DIALOG_ADD_PATH, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 276
TOPMARGIN, 7
BOTTOMMARGIN, 39
END
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
IDR_MAINFRAME ICON DISCARDABLE "res\\mission_compiler_fe.ico"
IDI_ICON_FILTER ICON DISCARDABLE "res\\icon_fil.ico"
/////////////////////////////////////////////////////////////////////////////
//
// Dialog
//
IDD_ABOUTBOX DIALOG DISCARDABLE 0, 0, 235, 55
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "About mission_compiler_fe"
FONT 8, "MS Sans Serif"
BEGIN
ICON IDR_MAINFRAME,IDC_STATIC,11,17,20,20
LTEXT "mission_compiler_fe version 1.0",IDC_STATIC,40,10,119,8,
SS_NOPREFIX
LTEXT "Copyright (C) 2004",IDC_STATIC,40,25,119,8
DEFPUSHBUTTON "OK",IDOK,178,7,50,14,WS_GROUP
EDITTEXT IDC_ADD_PATH,7,7,269,32,ES_MULTILINE | ES_AUTOVSCROLL | ES_AUTOHSCROLL | ES_READONLY
END
IDD_MISSION_COMPILER_FE_DIALOG DIALOGEX 0, 0, 361, 322
STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
EXSTYLE WS_EX_APPWINDOW
CAPTION "Primitive tool"
MENU IDR_MENU1
FONT 8, "MS Sans Serif"
FONT 8, "MS Sans Serif", 0, 0, 0x1
BEGIN
DEFPUSHBUTTON "&COMPILE",IDC_COMPILE,155,242,50,14,WS_DISABLED
PUSHBUTTON "&QUIT",IDCANCEL,156,301,50,14
LISTBOX IDC_LIST_SRC,7,125,136,190,LBS_SORT |
LBS_NOINTEGRALHEIGHT | LBS_EXTENDEDSEL | WS_VSCROLL |
WS_HSCROLL | WS_TABSTOP
LISTBOX IDC_LIST_DST,218,113,136,202,LBS_SORT |
LBS_NOINTEGRALHEIGHT | LBS_EXTENDEDSEL | WS_VSCROLL |
WS_TABSTOP
LISTBOX IDC_LIST_SRC,7,125,136,190,LBS_SORT | LBS_NOINTEGRALHEIGHT | LBS_EXTENDEDSEL | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP
LISTBOX IDC_LIST_DST,218,113,136,202,LBS_SORT | LBS_NOINTEGRALHEIGHT | LBS_EXTENDEDSEL | WS_VSCROLL | WS_TABSTOP
CTEXT "Available Primitive files",IDC_STATIC,7,90,136,11
CTEXT "Selected primitive",IDC_STATIC,218,90,136,15
PUSHBUTTON ">>",IDC_ADD,156,128,50,16
@ -127,49 +66,37 @@ BEGIN
PUSHBUTTON "ALL >>",IDC_ADD_ALL,156,146,50,16
EDITTEXT IDC_FILTER,32,104,112,14,ES_AUTOHSCROLL
ICON IDI_ICON_FILTER,IDC_STATIC,8,104,21,20,SS_REALSIZEIMAGE
DEFPUSHBUTTON "COMPILE &PUBLISH",IDC_PUBLISH,155,259,50,26,
BS_MULTILINE | WS_DISABLED
DEFPUSHBUTTON "COMPILE &PUBLISH",IDC_PUBLISH,155,259,50,26,BS_MULTILINE | WS_DISABLED
PUSHBUTTON "&VALIDATE",IDC_VALIDATE,155,225,50,14,WS_DISABLED
EDITTEXT IDC_DATA_DIRECTORY,89,7,265,15,ES_AUTOHSCROLL
LTEXT "",IDC_PATH_WARNING,105,28,235,8
GROUPBOX "Publish to the following servers",IDC_STATIC,62,38,254,
45
CONTROL "Server 1",IDC_CHECK_SRV1,"Button",BS_AUTOCHECKBOX |
WS_DISABLED | WS_TABSTOP,74,50,41,10
CONTROL "Server 2",IDC_CHECK_SRV2,"Button",BS_AUTOCHECKBOX |
WS_DISABLED | WS_TABSTOP,74,66,41,10
CONTROL "Server 3",IDC_CHECK_SRV3,"Button",BS_AUTOCHECKBOX |
WS_DISABLED | WS_TABSTOP,126,50,41,10
CONTROL "Server4",IDC_CHECK_SRV4,"Button",BS_AUTOCHECKBOX |
WS_DISABLED | WS_TABSTOP,126,66,41,10
CONTROL "Server 5",IDC_CHECK_SRV5,"Button",BS_AUTOCHECKBOX |
WS_DISABLED | WS_TABSTOP,188,50,41,10
CONTROL "Server 6",IDC_CHECK_SRV6,"Button",BS_AUTOCHECKBOX |
WS_DISABLED | WS_TABSTOP,188,66,41,10
CONTROL "Server 7",IDC_CHECK_SRV7,"Button",BS_AUTOCHECKBOX |
WS_DISABLED | WS_TABSTOP,252,50,39,11
CONTROL "Server 8",IDC_CHECK_SRV8,"Button",BS_AUTOCHECKBOX |
WS_DISABLED | WS_TABSTOP,252,64,42,13
GROUPBOX "Publish to the following servers",IDC_STATIC,62,38,254,45
CONTROL "Server 1",IDC_CHECK_SRV1,"Button",BS_AUTOCHECKBOX | WS_DISABLED | WS_TABSTOP,74,50,41,10
CONTROL "Server 2",IDC_CHECK_SRV2,"Button",BS_AUTOCHECKBOX | WS_DISABLED | WS_TABSTOP,74,66,41,10
CONTROL "Server 3",IDC_CHECK_SRV3,"Button",BS_AUTOCHECKBOX | WS_DISABLED | WS_TABSTOP,126,50,41,10
CONTROL "Server4",IDC_CHECK_SRV4,"Button",BS_AUTOCHECKBOX | WS_DISABLED | WS_TABSTOP,126,66,41,10
CONTROL "Server 5",IDC_CHECK_SRV5,"Button",BS_AUTOCHECKBOX | WS_DISABLED | WS_TABSTOP,188,50,41,10
CONTROL "Server 6",IDC_CHECK_SRV6,"Button",BS_AUTOCHECKBOX | WS_DISABLED | WS_TABSTOP,188,66,41,10
CONTROL "Server 7",IDC_CHECK_SRV7,"Button",BS_AUTOCHECKBOX | WS_DISABLED | WS_TABSTOP,252,50,39,11
CONTROL "Server 8",IDC_CHECK_SRV8,"Button",BS_AUTOCHECKBOX | WS_DISABLED | WS_TABSTOP,252,64,42,13
END
IDD_COMPIL DIALOG DISCARDABLE 0, 0, 294, 178
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION
IDD_COMPIL DIALOG 0, 0, 294, 178
STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION
CAPTION "Compilation status"
FONT 8, "MS Sans Serif"
BEGIN
EDITTEXT IDC_COMPIL_LOG,7,7,280,148,ES_MULTILINE | ES_READONLY |
WS_VSCROLL | WS_HSCROLL
EDITTEXT IDC_COMPIL_LOG,7,7,280,148,ES_MULTILINE | ES_READONLY | WS_VSCROLL | WS_HSCROLL
PUSHBUTTON "Ok",IDOK,228,158,59,16,WS_DISABLED
END
IDD_DIALOG_MODE DIALOG DISCARDABLE 0, 0, 155, 76
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
IDD_DIALOG_MODE DIALOG 0, 0, 155, 76
STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Choose Tool Mode"
FONT 8, "MS Sans Serif"
BEGIN
DEFPUSHBUTTON "Compile mission",ID_MODE_COMPILE,7,14,141,23
PUSHBUTTON "Publish primitive",ID_MODE_PUBLISH,7,46,141,23,
WS_DISABLED
PUSHBUTTON "Publish primitive",ID_MODE_PUBLISH,7,46,141,23,WS_DISABLED
END
@ -179,41 +106,29 @@ END
//
#ifdef APSTUDIO_INVOKED
GUIDELINES DESIGNINFO DISCARDABLE
GUIDELINES DESIGNINFO
BEGIN
IDD_ABOUTBOX, DIALOG
IDD_DIALOG_ADD_PATH, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 228
RIGHTMARGIN, 276
TOPMARGIN, 7
BOTTOMMARGIN, 48
BOTTOMMARGIN, 39
END
END
#endif // APSTUDIO_INVOKED
IDD_MISSION_COMPILER_FE_DIALOG, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 354
TOPMARGIN, 7
BOTTOMMARGIN, 315
END
IDD_COMPIL, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 287
TOPMARGIN, 7
BOTTOMMARGIN, 174
END
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
IDD_DIALOG_MODE, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 148
TOPMARGIN, 7
BOTTOMMARGIN, 69
END
END
#endif // APSTUDIO_INVOKED
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
IDR_MAINFRAME ICON "res\\red_pill.ico"
IDI_ICON_FILTER ICON "res\\icon_fil.ico"
#ifdef APSTUDIO_INVOKED
@ -222,18 +137,18 @@ END
// TEXTINCLUDE
//
1 TEXTINCLUDE DISCARDABLE
1 TEXTINCLUDE
BEGIN
"resource.h\0"
END
2 TEXTINCLUDE DISCARDABLE
2 TEXTINCLUDE
BEGIN
"#include ""afxres.h""\r\n"
"\0"
END
3 TEXTINCLUDE DISCARDABLE
3 TEXTINCLUDE
BEGIN
"#define _AFX_NO_SPLITTER_RESOURCES\r\n"
"#define _AFX_NO_OLE_RESOURCES\r\n"
@ -248,63 +163,22 @@ BEGIN
"#include ""res\\mission_compiler_fe.rc2"" // non-Microsoft Visual C++ edited resources\r\n"
"#include ""l.fra\\afxres.rc"" // Standard components\r\n"
"#endif\r\n"
"\r\n"
"#include ""version.rc2""\r\n"
"\0"
END
#endif // APSTUDIO_INVOKED
#ifndef _MAC
/////////////////////////////////////////////////////////////////////////////
//
// Version
//
VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,0,0,1
PRODUCTVERSION 1,0,0,1
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
#else
FILEFLAGS 0x0L
#endif
FILEOS 0x4L
FILETYPE 0x1L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "040C04B0"
BEGIN
VALUE "CompanyName", "\0"
VALUE "FileDescription", "Application MFC mission_compiler_fe\0"
VALUE "FileVersion", "1, 0, 0, 1\0"
VALUE "InternalName", "mission_compiler_fe\0"
VALUE "LegalCopyright", "Copyright (C) 2004\0"
VALUE "LegalTrademarks", "\0"
VALUE "OriginalFilename", "mission_compiler_fe.EXE\0"
VALUE "ProductName", "Application mission_compiler_fe\0"
VALUE "ProductVersion", "1, 0, 0, 1\0"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x40c, 1200
END
END
#endif // !_MAC
/////////////////////////////////////////////////////////////////////////////
//
// String Table
//
STRINGTABLE DISCARDABLE
STRINGTABLE
BEGIN
IDS_ABOUTBOX "&A propos de mission_compiler_fe..."
IDS_ABOUTBOX "&About Ryzom Mission Compiler..."
END
#endif // English resources
@ -331,6 +205,8 @@ LANGUAGE 12, 1
#include "l.fra\afxres.rc" // Standard components
#endif
#include "version.rc2"
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

@ -0,0 +1,67 @@
#ifndef NL_VERSION_RC2
#define NL_VERSION_RC2
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
LANGUAGE LANG_ENGLISH, SUBLANG_NEUTRAL
#pragma code_page(65001)
#include <windows.h>
#include "config.h"
#ifdef _DEBUG
#define NL_FILEEXT "_d"
#else
#define NL_FILEEXT ""
#endif
VS_VERSION_INFO VERSIONINFO
FILEVERSION NL_VERSION_RC
PRODUCTVERSION NL_VERSION_RC
FILEFLAGSMASK VS_FFI_FILEFLAGSMASK
#ifdef _DEBUG
FILEFLAGS VS_FF_DEBUG
#else
FILEFLAGS 0x0L
#endif
FILEOS VOS_NT_WINDOWS32
FILETYPE VFT_APP
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "040904b0"
BEGIN
VALUE "CompanyName", AUTHOR
VALUE "FileDescription", "Ryzom Mission Compiler Frontend"
VALUE "FileVersion", NL_VERSION
VALUE "LegalCopyright", COPYRIGHT
VALUE "OriginalFilename", "ryzom_mission_compiler_fe" NL_FILEEXT ".exe"
VALUE "ProductName", "Ryzom Tools"
VALUE "ProductVersion", NL_PRODUCT_VERSION
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x9, 1200
END
END
STRINGTABLE
BEGIN
IDS_VERSIONTEXT "Ryzom Mission Compiler Frontend " NL_VERSION
END
IDD_ABOUTBOX DIALOG DISCARDABLE 0, 0, 235, 55
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "About Ryzom Mission Compiler Frontend"
FONT 8, "MS Sans Serif"
BEGIN
ICON IDR_MAINFRAME,IDC_STATIC,11,17,20,20
LTEXT IDS_VERSIONTEXT,IDC_STATIC,40,10,119,8,SS_NOPREFIX
LTEXT COPYRIGHT,IDC_STATIC,40,25,119,8
DEFPUSHBUTTON "OK",IDOK,178,7,50,14,WS_GROUP
END
#endif /* #if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) */
#endif /* #ifndef NL_VERSION_RC2 */
Loading…
Cancel
Save