diff --git a/lvc/src/SshConnection.h b/lvc/src/SshConnection.h --- a/lvc/src/SshConnection.h +++ b/lvc/src/SshConnection.h @@ -1,42 +1,46 @@ #pragma once #if HAS_LIBSSH -#include "lgi/common/Ssh.h" -#include "lgi/common/EventTargetThread.h" -#include "lgi/common/Uri.h" + #include "lgi/common/Ssh.h" + #include "lgi/common/EventTargetThread.h" + #include "lgi/common/Uri.h" + + class SshConnection : public LSsh, public LEventTargetThread + { + int GuiHnd; + LUri Host; + LAutoPtr c; + LString Uri, Prompt; + AppPriv *d; + + LMessage::Result OnEvent(LMessage *Msg); + LStream *GetConsole(); + bool WaitPrompt(LStream *c, LString *Data = NULL, const char *Debug = NULL); -class SshConnection : public LSsh, public LEventTargetThread -{ - int GuiHnd; - LUri Host; - LAutoPtr c; - LString Uri, Prompt; - AppPriv *d; + public: + enum LoggingType + { + LogNone, + LogInfo, + LogDebug + }; - LMessage::Result OnEvent(LMessage *Msg); - LStream *GetConsole(); - bool WaitPrompt(LStream *c, LString *Data = NULL, const char *Debug = NULL); - -public: - enum LoggingType - { - LogNone, - LogInfo, - LogDebug + LHashTbl,VersionCtrl> Types; + LArray TypeNotify; + + SshConnection(LTextLog *log, const char *uri, const char *prompt); + bool DetectVcs(VcFolder *Fld); + bool Command(VcFolder *Fld, LString Exe, LString Args, ParseFn Parser, ParseParams *Params, LoggingType Logging); + + // This is the GUI thread message handler + static bool HandleMsg(LMessage *m); }; - LHashTbl,VersionCtrl> Types; - LArray TypeNotify; - - SshConnection(LTextLog *log, const char *uri, const char *prompt); - bool DetectVcs(VcFolder *Fld); - bool Command(VcFolder *Fld, LString Exe, LString Args, ParseFn Parser, ParseParams *Params, LoggingType Logging); - - // This is the GUI thread message handler - static bool HandleMsg(LMessage *m); -}; - #else -#warning "Building without libssh." + #ifdef _MSC_VER + #pragma message("Building without libssh.") + #else + #warning "Building without libssh." + #endif #endif \ No newline at end of file