[Gcblue-commits] gcb_wx/src/sim Game.cpp,1.77,1.78 tcNetworkView.cpp,1.12,1.13 tcSimState.cpp,1.42,1
Status: Alpha
Brought to you by:
ddcforge
|
From: Dewitt C. <ddc...@us...> - 2004-05-09 20:40:33
|
Update of /cvsroot/gcblue/gcb_wx/src/sim In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1643/src/sim Modified Files: Game.cpp tcNetworkView.cpp tcSimState.cpp Log Message: Index: tcSimState.cpp =================================================================== RCS file: /cvsroot/gcblue/gcb_wx/src/sim/tcSimState.cpp,v retrieving revision 1.42 retrieving revision 1.43 diff -C2 -d -r1.42 -r1.43 *** tcSimState.cpp 8 May 2004 21:25:26 -0000 1.42 --- tcSimState.cpp 9 May 2004 20:40:23 -0000 1.43 *************** *** 2035,2038 **** --- 2035,2039 ---- s.Format("tcSimState size: %d kB",sizeof(tcSimState)/1024); WTL(s.GetBuffer()); + } /********************************************************************/ *************** *** 2042,2044 **** if (goalTracker) delete goalTracker; } ! /********************************************************************/ \ No newline at end of file --- 2043,2045 ---- if (goalTracker) delete goalTracker; } ! /********************************************************************/ Index: tcNetworkView.cpp =================================================================== RCS file: /cvsroot/gcblue/gcb_wx/src/sim/tcNetworkView.cpp,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** tcNetworkView.cpp 8 May 2004 21:25:26 -0000 1.12 --- tcNetworkView.cpp 9 May 2004 20:40:23 -0000 1.13 *************** *** 71,80 **** DrawStatusBox(pGraphics); - if (tcMultiplayerInterface::Get()->IsChatTextAvail()) - { - chatBox->Print(tcMultiplayerInterface::Get()->GetChatText().c_str()); - } - - ReleaseGraphics(pGraphics); --- 71,74 ---- *************** *** 289,292 **** --- 283,287 ---- current = root->FirstChild("ChatBox"); chatBox = new tcConsoleBox(this, current); + tcMultiplayerInterface::Get()->AddChatSubscriber(chatBox); // add chat text edit box Index: Game.cpp =================================================================== RCS file: /cvsroot/gcblue/gcb_wx/src/sim/Game.cpp,v retrieving revision 1.77 retrieving revision 1.78 diff -C2 -d -r1.77 -r1.78 *** Game.cpp 8 May 2004 21:25:26 -0000 1.77 --- Game.cpp 9 May 2004 20:40:23 -0000 1.78 *************** *** 49,52 **** --- 49,53 ---- #include "tcNetworkView.h" #include "network/tcMultiplayerInterface.h" + #include "tcChatBox.h" #if defined(_MSC_VER) *************** *** 217,220 **** --- 218,222 ---- viewer->SetActive(false); popupControl->SetActive(false); + chatBox->SetActive(false); // undo initialization *************** *** 391,394 **** --- 393,400 ---- editControl->SetActive(false); + chatBox = new tcChatBox(glCanvas, NULL, wxPoint(200, 200), wxSize(300, 180)); + chatBox->SetActive(false); + chatBox->MoveToTop(); + mcDatabase.LoadDBCSV(); // uncomment the SaveDBCSV line to save copy of database to _out suffix, *************** *** 561,565 **** briefingConsoleLeft->SetWrap(48); briefingConsoleLeft->SetActive(false); - briefingConsoleLeft->SetSkipCount(tcOptions::Get()->renderSkipCount); briefingConsoleLeft->SetDelayedTextEffect(true); briefingConsoleLeft->LoadBackgroundImage("briefing_left.jpg"); --- 567,570 ---- *************** *** 581,585 **** briefingConsoleBottom->SetWrap(100); briefingConsoleBottom->SetActive(false); - briefingConsoleBottom->SetSkipCount(tcOptions::Get()->renderSkipCount); briefingConsoleBottom->LoadBackgroundImage("briefing_bottom.jpg"); briefingConsoleBottom->Print(" "); // need this to get it to display --- 586,589 ---- *************** *** 687,691 **** infoConsole->SetWrap(28); infoConsole->SetActive(false); - infoConsole->SetSkipCount(tcOptions::Get()->renderSkipCount); --- 691,694 ---- *************** *** 705,709 **** hookInfo->AttachUserInfo(&mcUserInfo); hookInfo->SetActive(false); - hookInfo->SetSkipCount(tcOptions::Get()->renderSkipCount); // objectControl init --- 708,711 ---- *************** *** 723,727 **** objectControl->AttachOptions(tcOptions::Get()); objectControl->AttachUserInfo(&mcUserInfo); - objectControl->SetSkipCount(tcOptions::Get()->renderSkipCount); /* ** tcOOBView init * **/ --- 725,728 ---- *************** *** 744,748 **** oobView->AttachSimState(simState); oobView->mnAlliance = mcUserInfo.GetOwnAlliance(); // TODO: make this configurable - oobView->SetSkipCount(tcOptions::Get()->renderSkipCount); // popupControl init --- 745,748 ---- *************** *** 1095,1098 **** --- 1095,1099 ---- scenarioSelectView->SetActive(false); networkView->SetActive(false); + chatBox->SetActive(false); } *************** *** 1195,1198 **** --- 1196,1203 ---- } if (popupControl->mbActive) popupControl->Draw(); + if (chatBox->mbActive) + { + chatBox->Draw(); + } } else if (meScreenMode == TACTICALBRIEF) *************** *** 1209,1213 **** oobView->SetActive(false); viewer->SetActive(mb3DActive); - if (drawTacticalMap) { --- 1214,1217 ---- *************** *** 1219,1222 **** --- 1223,1230 ---- briefingConsoleBottom->Draw(); } + if (chatBox->mbActive) + { + chatBox->Draw(); + } } else if (meScreenMode == OPTIONS) *************** *** 1232,1235 **** --- 1240,1244 ---- objectControl->SetActive(false); viewer->SetActive(false); + chatBox->SetActive(false); optionsView->Draw(); } *************** *** 1246,1249 **** --- 1255,1259 ---- objectControl->SetActive(false); viewer->SetActive(false); + chatBox->SetActive(false); networkView->Draw(); } *************** *** 1610,1613 **** --- 1620,1627 ---- } return; + case 'c': // toggle chat box + chatBox->SetActive(!chatBox->mbActive); + if (chatBox->mbActive) chatBox->MoveToTop(); + return; case 'A': accelerateTime--; |