Hugintrunk
0.1
|
#include <MyExternalCmdExecDialog.h>
Public Member Functions | |
MyExecPanel (wxWindow *parent) | |
void | KillProcess () |
void | PauseProcess (bool pause=true) |
function to pause running process, argument pause defaults to true - to resume, set it to false More... | |
void | ContinueProcess () |
long | GetPid () |
int | ExecWithRedirect (wxString command) |
int | ExecQueue (HuginQueue::CommandQueue *queue) |
void | OnTimer (wxTimerEvent &event) |
void | OnProcessTerminated (MyPipedProcess *process, int pid, int status) |
bool | SaveLog (const wxString &filename) |
save the content of the window into a given log file More... | |
void | CopyLogToClipboard () |
copy the content of the log window into the clipboard More... | |
wxArrayString | GetLogAsArrayString () |
returns the output More... | |
void | AddString (const wxString &s) |
display the string in the panel More... | |
virtual | ~MyExecPanel () |
Public Member Functions inherited from MyProcessListener | |
virtual | ~MyProcessListener () |
Private Member Functions | |
void | AddToOutput (wxInputStream &s) |
void | DoAsyncExec (const wxString &cmd) |
void | AddAsyncProcess (MyPipedProcess *process) |
void | RemoveAsyncProcess (MyPipedProcess *process) |
int | ExecNextQueue () |
execute next command in queue More... | |
Private Attributes | |
long | m_pidLast |
wxTextCtrl * | m_textctrl |
long | m_lastLineStart |
MyProcessesArray | m_running |
wxTimer | m_timerIdleWakeUp |
HuginQueue::CommandQueue * | m_queue |
size_t | m_queueLength |
bool | m_checkReturnCode |
wxExecuteEnv | m_executeEnv |
wxStopWatch | m_stopWatch |
Definition at line 54 of file MyExternalCmdExecDialog.h.
|
explicit |
Definition at line 78 of file MyExternalCmdExecDialog.cpp.
|
virtual |
Definition at line 502 of file MyExternalCmdExecDialog.cpp.
References m_textctrl.
|
private |
Definition at line 308 of file MyExternalCmdExecDialog.cpp.
References m_running, and m_timerIdleWakeUp.
Referenced by ExecWithRedirect().
void MyExecPanel::AddString | ( | const wxString & | s | ) |
display the string in the panel
Definition at line 523 of file MyExternalCmdExecDialog.cpp.
References m_lastLineStart, and m_textctrl.
Referenced by MyExecDialog::AddString(), ExecNextQueue(), and RunStitchPanel::StitchProject().
|
private |
Definition at line 339 of file MyExternalCmdExecDialog.cpp.
References DEBUG_TRACE, m_lastLineStart, and m_textctrl.
Referenced by OnProcessTerminated(), and OnTimer().
void MyExecPanel::ContinueProcess | ( | ) |
Definition at line 187 of file MyExternalCmdExecDialog.cpp.
References PauseProcess().
Referenced by RunStitchPanel::ContinueStitch().
void MyExecPanel::CopyLogToClipboard | ( | ) |
copy the content of the log window into the clipboard
Definition at line 512 of file MyExternalCmdExecDialog.cpp.
References m_textctrl.
Referenced by RawImportProgress::OnProcessReferenceTerminate(), MyExecDialog::OnProcessTerminate(), and RawImportProgress::OnProcessTerminate().
|
private |
|
private |
execute next command in queue
Definition at line 279 of file MyExternalCmdExecDialog.cpp.
References AddString(), HuginQueue::NormalCommand::CheckReturnCode(), ExecWithRedirect(), HuginQueue::NormalCommand::GetCommand(), HuginQueue::NormalCommand::GetComment(), m_checkReturnCode, m_queue, m_queueLength, and hugin_utils::roundi().
Referenced by ExecQueue(), and OnProcessTerminated().
int MyExecPanel::ExecQueue | ( | HuginQueue::CommandQueue * | queue | ) |
Definition at line 245 of file MyExternalCmdExecDialog.cpp.
References ExecNextQueue(), m_executeEnv, m_queue, m_queueLength, and m_stopWatch.
Referenced by RunStitchPanel::DetectProject(), MyExecDialog::ExecQueue(), RawImportProgress::OnInitDialog(), RawImportProgress::OnProcessReferenceTerminate(), and RunStitchPanel::StitchProject().
int MyExecPanel::ExecWithRedirect | ( | wxString | command | ) |
Definition at line 197 of file MyExternalCmdExecDialog.cpp.
References AddAsyncProcess(), m_executeEnv, and m_pidLast.
Referenced by ExecNextQueue(), and MyExecDialog::ExecWithRedirect().
wxArrayString MyExecPanel::GetLogAsArrayString | ( | ) |
returns the output
Definition at line 518 of file MyExternalCmdExecDialog.cpp.
References m_textctrl.
Referenced by RawImportProgress::OnProcessReferenceTerminate().
long MyExecPanel::GetPid | ( | ) |
Definition at line 192 of file MyExternalCmdExecDialog.cpp.
References m_pidLast.
Referenced by RunStitchPanel::GetPid().
void MyExecPanel::KillProcess | ( | ) |
Definition at line 98 of file MyExternalCmdExecDialog.cpp.
References DEBUG_DEBUG, and m_pidLast.
Referenced by RunStitchPanel::CancelStitch(), MyExecDialog::OnCancel(), and RawImportProgress::OnCancel().
|
virtual |
Implements MyProcessListener.
Definition at line 454 of file MyExternalCmdExecDialog.cpp.
References AddToOutput(), DEBUG_TRACE, ExecNextQueue(), m_checkReturnCode, m_queue, m_stopWatch, m_textctrl, RemoveAsyncProcess(), and hugin_utils::roundi().
void MyExecPanel::OnTimer | ( | wxTimerEvent & | event | ) |
Definition at line 399 of file MyExternalCmdExecDialog.cpp.
References AddToOutput(), DEBUG_DEBUG, DEBUG_TRACE, m_pidLast, and m_running.
void MyExecPanel::PauseProcess | ( | bool | pause = true | ) |
function to pause running process, argument pause defaults to true - to resume, set it to false
Definition at line 125 of file MyExternalCmdExecDialog.cpp.
References m_pidLast.
Referenced by ContinueProcess(), and RunStitchPanel::PauseStitch().
|
private |
Definition at line 323 of file MyExternalCmdExecDialog.cpp.
References m_running, and m_timerIdleWakeUp.
Referenced by OnProcessTerminated().
bool MyExecPanel::SaveLog | ( | const wxString & | filename | ) |
save the content of the window into a given log file
Definition at line 507 of file MyExternalCmdExecDialog.cpp.
References m_textctrl.
Referenced by RunStitchPanel::SaveLog().
|
private |
Definition at line 112 of file MyExternalCmdExecDialog.h.
Referenced by ExecNextQueue(), and OnProcessTerminated().
|
private |
Definition at line 113 of file MyExternalCmdExecDialog.h.
Referenced by ExecQueue(), and ExecWithRedirect().
|
private |
Definition at line 102 of file MyExternalCmdExecDialog.h.
Referenced by AddString(), and AddToOutput().
|
private |
Definition at line 99 of file MyExternalCmdExecDialog.h.
Referenced by ExecWithRedirect(), GetPid(), KillProcess(), OnTimer(), and PauseProcess().
|
private |
Definition at line 109 of file MyExternalCmdExecDialog.h.
Referenced by ExecNextQueue(), ExecQueue(), and OnProcessTerminated().
|
private |
Definition at line 110 of file MyExternalCmdExecDialog.h.
Referenced by ExecNextQueue(), and ExecQueue().
|
private |
Definition at line 104 of file MyExternalCmdExecDialog.h.
Referenced by AddAsyncProcess(), OnTimer(), and RemoveAsyncProcess().
|
private |
Definition at line 114 of file MyExternalCmdExecDialog.h.
Referenced by ExecQueue(), and OnProcessTerminated().
|
private |
Definition at line 101 of file MyExternalCmdExecDialog.h.
Referenced by AddString(), AddToOutput(), CopyLogToClipboard(), GetLogAsArrayString(), OnProcessTerminated(), SaveLog(), and ~MyExecPanel().
|
private |
Definition at line 107 of file MyExternalCmdExecDialog.h.
Referenced by AddAsyncProcess(), and RemoveAsyncProcess().