Hugin trunk 0.1
Loading...
Searching...
No Matches
Public Member Functions | Private Member Functions | Private Attributes | List of all members
MyExecPanel Class Reference

#include <MyExternalCmdExecDialog.h>

Inheritance diagram for MyExecPanel:
Inheritance graph

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
 
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
 
void CopyLogToClipboard ()
 copy the content of the log window into the clipboard
 
wxArrayString GetLogAsArrayString ()
 returns the output
 
void AddString (const wxString &s)
 display the string in the panel
 
void ClearOutput ()
 clear the output
 
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
 

Private Attributes

long m_pidLast
 
wxTextCtrl * m_textctrl
 
long m_lastLineStart
 
MyProcessesArray m_running
 
wxTimer m_timerIdleWakeUp
 
HuginQueue::CommandQueuem_queue
 
size_t m_queueLength
 
bool m_checkReturnCode
 
wxExecuteEnv m_executeEnv
 
wxStopWatch m_stopWatch
 

Detailed Description

Definition at line 54 of file MyExternalCmdExecDialog.h.

Constructor & Destructor Documentation

◆ MyExecPanel()

MyExecPanel::MyExecPanel ( wxWindow *  parent)
explicit

◆ ~MyExecPanel()

MyExecPanel::~MyExecPanel ( )
virtual

Definition at line 499 of file MyExternalCmdExecDialog.cpp.

References m_queue, and m_textctrl.

Member Function Documentation

◆ AddAsyncProcess()

void MyExecPanel::AddAsyncProcess ( MyPipedProcess process)
private

Definition at line 305 of file MyExternalCmdExecDialog.cpp.

References m_running, m_timerIdleWakeUp, and threshold().

Referenced by ExecWithRedirect().

◆ AddString()

void MyExecPanel::AddString ( const wxString s)

◆ AddToOutput()

void MyExecPanel::AddToOutput ( wxInputStream s)
private

Definition at line 336 of file MyExternalCmdExecDialog.cpp.

References DEBUG_TRACE, m_lastLineStart, m_textctrl, and threshold().

Referenced by OnProcessTerminated(), and OnTimer().

◆ ClearOutput()

void MyExecPanel::ClearOutput ( )

◆ ContinueProcess()

void MyExecPanel::ContinueProcess ( )

Definition at line 184 of file MyExternalCmdExecDialog.cpp.

References PauseProcess().

Referenced by RunStitchPanel::ContinueStitch().

◆ CopyLogToClipboard()

void MyExecPanel::CopyLogToClipboard ( )

copy the content of the log window into the clipboard

Definition at line 518 of file MyExternalCmdExecDialog.cpp.

References m_textctrl.

Referenced by RawImportProgress::OnProcessReferenceTerminate(), RawImportProgress::OnProcessTerminate(), and MyExecDialog::OnProcessTerminate().

◆ DoAsyncExec()

void MyExecPanel::DoAsyncExec ( const wxString cmd)
private

◆ ExecNextQueue()

int MyExecPanel::ExecNextQueue ( )
private

◆ ExecQueue()

int MyExecPanel::ExecQueue ( HuginQueue::CommandQueue queue)

◆ ExecWithRedirect()

int MyExecPanel::ExecWithRedirect ( wxString  command)

◆ GetLogAsArrayString()

wxArrayString MyExecPanel::GetLogAsArrayString ( )

returns the output

Definition at line 524 of file MyExternalCmdExecDialog.cpp.

References m_textctrl, and threshold().

Referenced by RawImportProgress::OnProcessReferenceTerminate().

◆ GetPid()

long MyExecPanel::GetPid ( )

Definition at line 189 of file MyExternalCmdExecDialog.cpp.

References m_pidLast.

Referenced by RunStitchPanel::GetPid().

◆ KillProcess()

void MyExecPanel::KillProcess ( )

◆ OnProcessTerminated()

void MyExecPanel::OnProcessTerminated ( MyPipedProcess process,
int  pid,
int  status 
)
virtual

◆ OnTimer()

void MyExecPanel::OnTimer ( wxTimerEvent event)

Definition at line 396 of file MyExternalCmdExecDialog.cpp.

References AddToOutput(), DEBUG_DEBUG, DEBUG_TRACE, m_pidLast, m_running, and threshold().

Referenced by MyExecPanel().

◆ PauseProcess()

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 122 of file MyExternalCmdExecDialog.cpp.

References m_pidLast, and threshold().

Referenced by ContinueProcess(), and RunStitchPanel::PauseStitch().

◆ RemoveAsyncProcess()

void MyExecPanel::RemoveAsyncProcess ( MyPipedProcess process)
private

Definition at line 320 of file MyExternalCmdExecDialog.cpp.

References m_running, m_timerIdleWakeUp, and threshold().

Referenced by OnProcessTerminated().

◆ SaveLog()

bool MyExecPanel::SaveLog ( const wxString filename)

save the content of the window into a given log file

Returns
true if log was saved successful

Definition at line 513 of file MyExternalCmdExecDialog.cpp.

References m_textctrl.

Referenced by RunStitchPanel::SaveLog().

Member Data Documentation

◆ m_checkReturnCode

bool MyExecPanel::m_checkReturnCode
private

Definition at line 114 of file MyExternalCmdExecDialog.h.

Referenced by ExecNextQueue(), and OnProcessTerminated().

◆ m_executeEnv

wxExecuteEnv MyExecPanel::m_executeEnv
private

Definition at line 115 of file MyExternalCmdExecDialog.h.

Referenced by ExecQueue(), and ExecWithRedirect().

◆ m_lastLineStart

long MyExecPanel::m_lastLineStart
private

Definition at line 104 of file MyExternalCmdExecDialog.h.

Referenced by AddString(), AddToOutput(), ClearOutput(), and MyExecPanel().

◆ m_pidLast

long MyExecPanel::m_pidLast
private

◆ m_queue

HuginQueue::CommandQueue* MyExecPanel::m_queue
private

◆ m_queueLength

size_t MyExecPanel::m_queueLength
private

Definition at line 112 of file MyExternalCmdExecDialog.h.

Referenced by ExecNextQueue(), and ExecQueue().

◆ m_running

MyProcessesArray MyExecPanel::m_running
private

Definition at line 106 of file MyExternalCmdExecDialog.h.

Referenced by AddAsyncProcess(), OnTimer(), and RemoveAsyncProcess().

◆ m_stopWatch

wxStopWatch MyExecPanel::m_stopWatch
private

◆ m_textctrl

wxTextCtrl* MyExecPanel::m_textctrl
private

◆ m_timerIdleWakeUp

wxTimer MyExecPanel::m_timerIdleWakeUp
private

Definition at line 109 of file MyExternalCmdExecDialog.h.

Referenced by AddAsyncProcess(), and RemoveAsyncProcess().


The documentation for this class was generated from the following files: