From 70bfcd7c2cb0fdc6e087870c4d41b0c5a83d2b5c Mon Sep 17 00:00:00 2001 From: Julian Smart Date: Wed, 8 Jan 2003 09:13:02 +0000 Subject: [PATCH] Elminated streams from scoredlg.cpp git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@18635 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- demos/forty/scoredg.cpp | 28 ++++++++-------------------- 1 file changed, 8 insertions(+), 20 deletions(-) diff --git a/demos/forty/scoredg.cpp b/demos/forty/scoredg.cpp index fddbc0e3c4..39f8f5eacb 100644 --- a/demos/forty/scoredg.cpp +++ b/demos/forty/scoredg.cpp @@ -27,16 +27,6 @@ #include "wx/wx.h" #endif -#if wxUSE_IOSTREAMH -#if defined(__WXMSW__) && !defined(__GNUWIN32__) && !defined(__MWERKS__) -#include -#else -#include -#endif -#else -#include -//using namespace std; -#endif #include "scorefil.h" #include "scoredg.h" @@ -66,9 +56,9 @@ ScoreCanvas::ScoreCanvas(wxWindow* parent, ScoreFile* scoreFile) : wxArrayString players; scoreFile->GetPlayerList( players); - ostrstream os; + wxString os; - os << "Player\tWins\tGames\tScore\n"; + os << wxT("Player\tWins\tGames\tScore\n"); for (unsigned int i = 0; i < players.Count(); i++) { int wins, games, score; @@ -79,15 +69,13 @@ ScoreCanvas::ScoreCanvas(wxWindow* parent, ScoreFile* scoreFile) : average = (2 * score + games) / (2 * games); } - os << players[i] << '\t' - << wins << '\t' - << games << '\t' - << average << '\n'; + os << players[i] << wxT('\t') + << wins << wxT('\t') + << games << wxT('\t') + << average << wxT('\n'); } - os << '\0'; - char* str = os.str(); - m_text = str; - delete str; + os << wxT('\0'); + m_text = os; } ScoreCanvas::~ScoreCanvas()