1 diff -ur abridge-0.4.0/src/floatwindow.cpp abridge-0.4.0-patched/src/floatwindow.cpp
2 --- abridge-0.4.0/src/floatwindow.cpp 2003-03-03 15:30:21.000000000 -0500
3 +++ abridge-0.4.0-patched/src/floatwindow.cpp 2006-01-31 00:38:51.909199250 -0500
5 FloatWindow::~FloatWindow() {
8 -void FloatWindow::OnMove(const wxMoveEvent& event) {
9 +void FloatWindow::OnMove(wxMoveEvent& event) {
11 Move(GetParent()->GetPosition() + GetRelativePosition());
13 diff -ur abridge-0.4.0/src/floatwindow.h abridge-0.4.0-patched/src/floatwindow.h
14 --- abridge-0.4.0/src/floatwindow.h 2003-03-03 15:30:20.000000000 -0500
15 +++ abridge-0.4.0-patched/src/floatwindow.h 2006-01-31 00:39:05.434044500 -0500
18 virtual ~FloatWindow();
20 - void OnMove(const wxMoveEvent& event);
21 + void OnMove(wxMoveEvent& event);
22 void OnActivate(wxActivateEvent& event);
26 void MoveToPosition();
27 void DisallowOneMove();
29 - virtual wxPoint GetRelativePosition() = NULL;
30 - virtual void SetRelativePosition(wxPoint p) = NULL;
31 + virtual wxPoint GetRelativePosition() = 0;
32 + virtual void SetRelativePosition(wxPoint p) = 0;
34 static void InitStaticVariables() {};
36 diff -ur abridge-0.4.0/src/ftpfilecache.cpp abridge-0.4.0-patched/src/ftpfilecache.cpp
37 --- abridge-0.4.0/src/ftpfilecache.cpp 2003-03-03 15:30:21.000000000 -0500
38 +++ abridge-0.4.0-patched/src/ftpfilecache.cpp 2006-01-31 00:38:00.974016000 -0500
42 wxFileInputStream *in_stream = new wxFileInputStream(filename);
43 - if (!in_stream || (in_stream->LastError() != wxStream_NOERROR)) {
44 + if (!in_stream || (in_stream->GetLastError() != wxSTREAM_NO_ERROR)) {
45 DebugMsg("error opening file '" + filename + "' for reading");
48 DebugMsg("Successfully opened file '" + filename + "' for reading");
50 - long the_size=in_stream->StreamSize();
51 + long the_size=in_stream->GetSize();
53 DebugMsg("Aaack the file is empty");
58 in_stream = ftp.GetInputStream(m_remotefilename);
59 - if (!in_stream || in_stream->LastError() != wxStream_NOERROR) {
60 + if (!in_stream || in_stream->GetLastError() != wxSTREAM_NO_ERROR) {
61 DebugMsg("Problem finding file" + m_remotefilename);
64 DebugMsg("Reading file " + m_remotefilename);
65 wxFileOutputStream *out_stream = new wxFileOutputStream(m_localfilename);
66 - if (!out_stream || out_stream->LastError() != wxStream_NOERROR) {
67 + if (!out_stream || out_stream->GetLastError() != wxSTREAM_NO_ERROR) {
68 DebugMsg("error opening file '" + m_localfilename + "' for output");
73 wxOutputStream *out_stream;
74 wxFileInputStream *in_stream = new wxFileInputStream(m_localfilename);
75 - if (!in_stream || in_stream->LastError() != wxStream_NOERROR) {
76 + if (!in_stream || in_stream->GetLastError() != wxSTREAM_NO_ERROR) {
77 DebugMsg("error opening file " + m_localfilename + "for reading");
83 out_stream = ftp.GetOutputStream(m_remotefilename);
84 - if (!out_stream || out_stream->LastError() != wxStream_NOERROR) {
85 + if (!out_stream || out_stream->GetLastError() != wxSTREAM_NO_ERROR) {
86 DebugMsg("Problem creating remote file " + m_remotefilename);
87 DebugMsg("Perhaps " + m_remotefilename + " is already on server?");
89 diff -ur abridge-0.4.0/src/playerprefs.cpp abridge-0.4.0-patched/src/playerprefs.cpp
90 --- abridge-0.4.0/src/playerprefs.cpp 2003-03-03 15:30:21.000000000 -0500
91 +++ abridge-0.4.0-patched/src/playerprefs.cpp 2006-01-31 00:29:19.017395750 -0500
93 if (my_image.LoadFile(hello)) {
94 DebugMsg("Found image file " + hello);
95 my_image.Rescale(64,64);
96 - m_playerpic_bitmap->SetBitmap(my_image.ConvertToBitmap());
97 + m_playerpic_bitmap->SetBitmap(wxBitmap(my_image));
101 diff -ur abridge-0.4.0/src/prefmacros.cpp abridge-0.4.0-patched/src/prefmacros.cpp
102 --- abridge-0.4.0/src/prefmacros.cpp 2003-03-03 15:30:21.000000000 -0500
103 +++ abridge-0.4.0-patched/src/prefmacros.cpp 2006-01-31 00:30:08.456485500 -0500
105 if (my_image.LoadFile(filename)) {
106 DebugMsg("Found image file " + filename);
107 my_image.Rescale(64,64);
108 - return my_image.ConvertToBitmap();
109 + return wxBitmap(my_image);
111 DebugMsg("Deleting bad image file");
112 wxRemoveFile(filename);
113 diff -ur abridge-0.4.0/src/suit.cpp abridge-0.4.0-patched/src/suit.cpp
114 --- abridge-0.4.0/src/suit.cpp 2003-03-21 09:35:11.000000000 -0500
115 +++ abridge-0.4.0-patched/src/suit.cpp 2006-01-31 00:53:05.182525500 -0500
117 temp_dc.SelectObject(weemap);
118 if (usd) temp_dc.Blit(0,0,w,2*h, &dc, x, y-h);
119 else temp_dc.Blit(0,0,w,2*h, &dc, x, y);
120 - wxImage myim(weemap);
121 + wxImage myim(weemap.ConvertToImage());
122 myim.Rescale(4*w, 4*2*h);
123 if (usd) myim = myim.Rotate90().Rotate90();
124 - wxBitmap bigmap = myim.ConvertToBitmap();
125 + wxBitmap bigmap(myim);
126 temp_dc.SelectObject(bigmap);
127 if (is_red) temp_dc.SetTextForeground( *wxRED );
128 else temp_dc.SetTextForeground( *wxBLACK );
130 wxFont *f = wxTheFontList->FindOrCreateFont(--i, wxSWISS, wxNORMAL, wxNORMAL);
132 temp_dc.DrawText(num, 0, -lead);
133 - wxImage tm_im(bigmap);
134 + wxImage tm_im(bigmap.ConvertToImage());
135 if (usd) tm_im = tm_im.Rotate90().Rotate90();
137 - wxBitmap aabm = anti_alias(tm_im).ConvertToBitmap();
138 + wxBitmap aabm(anti_alias(tm_im));
140 aadc.SelectObject(aabm);
141 if (usd) dc.Blit(x,y-h, w, 2*h, &aadc, 0, 0, wxAND);
144 temp_dc.SelectObject(weemap);
145 temp_dc.Blit(0,0,w,h, &dc, x, y);
146 - wxImage myim(weemap);
147 + wxImage myim(weemap.ConvertToImage());
148 myim.Rescale(4*w, 4*h);
149 - wxBitmap bigmap = myim.ConvertToBitmap();
150 + wxBitmap bigmap(myim);
151 temp_dc.SelectObject(bigmap);
152 DrawSuitOnBM(temp_dc, m_suit, 4*w, 4*h);
153 - wxImage tm_im(bigmap);
154 + wxImage tm_im(bigmap.ConvertToImage());
155 if (usd) tm_im.Mirror(false);
157 - wxBitmap aabm = anti_alias(tm_im).ConvertToBitmap();
158 + wxBitmap aabm(anti_alias(tm_im));
160 aadc.SelectObject(aabm);
161 dc.Blit(x,y, w, h, &aadc, 0, 0, wxCOPY);
162 diff -ur abridge-0.4.0/src/table.cpp abridge-0.4.0-patched/src/table.cpp
163 --- abridge-0.4.0/src/table.cpp 2003-03-21 09:35:11.000000000 -0500
164 +++ abridge-0.4.0-patched/src/table.cpp 2006-01-31 00:45:34.742374750 -0500
166 // include config.h for VERSION
169 + // EVT_MENU(wxID_CLOSE, aBridgeTable::OnCloseWindow)
170 BEGIN_EVENT_TABLE(aBridgeTable, wxFrame)
171 EVT_MENU(CLAIM, aBridgeTable::Claim)
172 EVT_MENU(SHOWBID, aBridgeTable::ShowBids)
173 EVT_MENU(SHOWSCORES, aBridgeTable::ShowScores)
174 EVT_MENU(SHOWLAST, aBridgeTable::ShowLastTrick)
175 - EVT_MENU(wxID_CLOSE, aBridgeTable::OnCloseWindow)
176 EVT_MOVE(aBridgeTable::OnMove)
177 EVT_CLOSE(aBridgeTable::OnCloseWindow)
178 EVT_TEXT_ENTER(TALK, aBridgeTable::Talk)
183 -void aBridgeTable::OnMove(const wxMoveEvent& event) {
184 +void aBridgeTable::OnMove(wxMoveEvent& event) {
185 if (m_lasttrick) m_lasttrick->ParentMoved();
186 if (m_game) m_game->TableMoved();
187 if (m_scorewin) m_scorewin->ParentMoved();
188 diff -ur abridge-0.4.0/src/table.h abridge-0.4.0-patched/src/table.h
189 --- abridge-0.4.0/src/table.h 2003-03-03 15:30:21.000000000 -0500
190 +++ abridge-0.4.0-patched/src/table.h 2006-01-31 00:24:01.097527000 -0500
192 virtual ~aBridgeTable();
194 void OnCloseWindow(wxCloseEvent& event);
195 - void OnMove(const wxMoveEvent& event);
196 + void OnMove(wxMoveEvent& event);
199 void ShowBids(wxCommandEvent& event);