Remove magic numbers

This commit is contained in:
Asdow
2026-01-04 14:57:55 +02:00
parent cc984b09f6
commit b1c076416c
2 changed files with 6 additions and 5 deletions
+5 -3
View File
@@ -187,9 +187,11 @@ UINT32 guiEmailWarning;
#define SUBJECT_LINE_Y VIEWER_Y+42
#define SUBJECT_LINE_WIDTH 278-47
//max number of lines can be shown in an opened email messagebox
#define MAX_EMAIL_LINES 20
// maximum size of a email message page, so not to overrun the bottom of the screen
#define MAX_EMAIL_MESSAGE_PAGE_SIZE ( GetFontHeight( MESSAGE_FONT ) + MESSAGE_GAP ) * 20
#define MAX_EMAIL_MESSAGE_PAGE_SIZE ( GetFontHeight( MESSAGE_FONT ) + MESSAGE_GAP ) * MAX_EMAIL_LINES
enum{
PREVIOUS_BUTTON=0,
NEXT_BUTTON,
@@ -5475,7 +5477,7 @@ UINT32 cnt;
void PreProcessEmail( EmailPtr pMail )
{
RecordPtr pTempRecord, pCurrentRecord, pLastRecord , pTempList;
CHAR16 pString[ 512 ];
CHAR16 pString[MAIL_STRING_SIZE];
INT32 iCounter = 0, iHeight = 0, iOffSet = 0;
BOOLEAN fGoingOffCurrentPage = FALSE;
INT32 iYPositionOnPage = 0;
+1 -2
View File
@@ -5,8 +5,7 @@
#include "soldier profile type.h"
// defines
#define MAX_EMAIL_LINES 10 //max number of lines can be shown in a message
#define MAX_MESSAGES_PAGE 18 // max number of messages per page
#define MAX_MESSAGES_PAGE 18 // max number of emails per page in inbox
//---ja25 ub
#ifdef JA2UB