// License: wxWindows licence
///////////////////////////////////////////////////////////////////////////////
-#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
-#pragma implementation "progdlg.h"
-#endif
-
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#ifdef __BORLANDC__
-#pragma hdrstop
+ #pragma hdrstop
#endif
+#if wxUSE_PROGRESSDLG
+
+#include "wx/progdlg.h"
+
#ifndef WX_PRECOMP
#include "wx/string.h"
+ #include "wx/msgdlg.h"
#endif //WX_PRECOMP
-#if wxUSE_PROGRESSDLG
-
-#include "wx/progdlg.h"
-#include "wx/msgdlg.h"
+#include <Progress.h>
+#include <SysEvtMgr.h>
IMPLEMENT_CLASS(wxProgressDialog, wxDialog)
{
if(m_prgFrame)
{
- PrgStopDialog(m_prgFrame, false);
+ PrgStopDialog((ProgressType *)m_prgFrame, false);
m_prgFrame = NULL;
}
}
EventType event;
+ ProgressType *prg = (ProgressType *)m_prgFrame;
do
{
EvtGetEvent(&event, 0);
- Boolean handled = PrgHandleEvent(m_prgFrame, &event);
- if (!PrgHandleEvent(m_prgFrame, &event))
- if( PrgUserCancel(m_prgFrame) )
+ Boolean handled = PrgHandleEvent(prg, &event);
+ if (!PrgHandleEvent(prg, &event))
+ if( PrgUserCancel(prg) )
return false;
}
while(event.eType != sysEventNilEvent);
- PrgUpdateDialog(m_prgFrame, 0, 0, "", true);
+ PrgUpdateDialog(prg, 0, 0, "", true);
m_activeSkip = m_canSkip && true;
return false;
}
-Boolean wxProgressDialog::Callback(PrgCallbackData *data)
+Boolean wxProgressDialog::Callback(void *data)
{
- strncpy( data->textP, m_msg.ToAscii() , data->textLen - 1 );
- data->textChanged = true;
- data->displaySkipBtn = m_canSkip;
- data->barMaxValue = (uint32_t)m_max;
- data->barCurValue = (uint32_t)m_cur;
- data->delay = (m_max == m_cur);
+ PrgCallbackData *palmData = (PrgCallbackData *)data;
+ strncpy( palmData->textP, m_msg.ToAscii() , palmData->textLen - 1 );
+ palmData->textChanged = true;
+#ifdef __WXPALMOS6__
+ palmData->displaySkipBtn = m_canSkip;
+#endif // __WXPALMOS6__
+ palmData->barMaxValue = (uint32_t)m_max;
+ palmData->barCurValue = (uint32_t)m_cur;
+ palmData->delay = (m_max == m_cur);
return true;
}