Rabbit Remote Control 0.1.0-bate14
Loading...
Searching...
No Matches
CBackendVnc Class Reference
Inheritance diagram for CBackendVnc:
Collaboration diagram for CBackendVnc:

Public Slots

virtual void slotConnected ()
virtual void slotDisConnected ()
virtual void slotReadyRead ()
virtual void slotClipBoardChanged () override
void slotChannelError (int nErr, const QString &szErr)
Public Slots inherited from CBackendDesktop
virtual void slotClipBoardChanged ()=0
 Be called when the clip board change.
virtual void slotMousePressEvent (QMouseEvent *event, QPoint pos)
virtual void slotMouseReleaseEvent (QMouseEvent *event, QPoint pos)
virtual void slotMouseMoveEvent (QMouseEvent *event, QPoint pos)
virtual void slotWheelEvent (QWheelEvent *event, QPoint pos)
virtual void slotKeyPressEvent (QKeyEvent *event)
virtual void slotKeyReleaseEvent (QKeyEvent *event)
virtual void slotInputMethodEvent (QInputMethodEvent *event)

Public Member Functions

 CBackendVnc (COperateDesktop *pOperate)
virtual void initDone () override
virtual void authSuccess () override
virtual void resizeFramebuffer () override
virtual void getUserPasswd (bool secure, std::string *user, std::string *password) override
virtual int getX509File (std::string *ca, std::string *crl) override
virtual bool showMsgBox (rfb::MsgBoxFlags flags, const char *title, const char *text) override
virtual void setName (const char *name) override
virtual void framebufferUpdateStart () override
virtual void framebufferUpdateEnd () override
virtual void setColourMapEntries (int firstColour, int nColours, uint16_t *rgbs) override
virtual void bell () override
virtual void setLEDState (unsigned int state) override
virtual void setCursor (int width, int height, const rfb::Point &hotspot, const uint8_t *data) override
virtual void setCursorPos (const rfb::Point &pos) override
virtual void fence (uint32_t flags, unsigned int len, const uint8_t data[]) override
virtual void handleClipboardRequest () override
virtual void handleClipboardAnnounce (bool available) override
virtual void handleClipboardData (const char *data) override
Public Member Functions inherited from CBackendDesktop
 CBackendDesktop (COperateDesktop *pOperate=nullptr)
virtual bool event (QEvent *event) override
Public Member Functions inherited from CBackend
 CBackend (COperate *pOperate=nullptr, bool bStopSignal=true)
 CBackend.
virtual int Start ()
 Start.
virtual int Stop ()
 Stop.

Protected Member Functions

virtual void mousePressEvent (QMouseEvent *event) override
virtual void mouseReleaseEvent (QMouseEvent *event) override
virtual void mouseMoveEvent (QMouseEvent *event) override
virtual void wheelEvent (QWheelEvent *event) override
virtual void keyPressEvent (QKeyEvent *event) override
virtual void keyReleaseEvent (QKeyEvent *event) override
virtual void InputMethodEvent (QInputMethodEvent *event) override
virtual OnInitReturnValue OnInit () override
 Initialization.
virtual int OnClean () override
 Clean.
virtual int OnProcess () override
 Specific operation processing of plug-in connection.
virtual int WakeUp () override
 Wake up backend thread(background thread).

Private Member Functions

quint32 TranslateRfbKey (quint32 inkey, bool modifier)
 CBackendVnc::TranslateRfbKey.
QString ConnectInformation ()
int SetPara ()
void autoSelectFormatAndEncoding ()
void updatePixelFormat ()
int SocketInit ()
int SetChannelConnect (QSharedPointer< CChannel > channel)
int IceInit ()
int SSHInit ()

Private Attributes

QSharedPointer< CChannelm_DataChannel
QSharedPointer< rdr::InStream > m_InStream
QSharedPointer< rdr::OutStream > m_OutStream
COperateDesktopm_pOperate
CParameterVncm_pPara
CSecurityLevel::Levels m_SecurityLevel

Additional Inherited Members

Signals inherited from CBackendDesktop
void sigSetDesktopSize (int width, int height)
void sigServerName (const QString &szName)
void sigUpdateRect (const QRect &r, const QImage &image)
 Notify the CFrmView update image.
void sigUpdateRect (const QImage &image)
 Notify the CFrmView update image.
void sigUpdateCursor (const QCursor &cursor)
void sigUpdateCursorPosition (const QPoint &pos)
void sigUpdateLedState (unsigned int state)
void sigSetClipboard (QMimeData *data)
Signals inherited from CBackend
void sigRunning ()
 Emitted when the plugin is successfully started.
void sigStop ()
 Notify the user to stop.
void sigFinished ()
 Successful stopped signal.
void sigError (const int nError, const QString &szError=QString())
 Triggered when an error is generated.
void sigInformation (const QString &szInfo)
 Triggering from a background thread displays information in the main thread without blocking the background thread.
void sigShowMessageBox (const QString &szTitle, const QString &szMessage, const QMessageBox::Icon &icon=QMessageBox::Information)
 Trigger the display of a message dialog (QMessageBox) in the main thread from a background thread without blocking the background thread.
void sigBlockShowMessageBox (const QString &szTitle, const QString &szMessage, QMessageBox::StandardButtons buttons, QMessageBox::StandardButton &nRet, bool &checkBox, QString checkBoxContext=QString())
 Block background threads and display message dialogs in foreground threads (QMessageBox).
void sigBlockInputDialog (const QString &szTitle, const QString &szLable, const QString &szMessage, QString &szText)
 Block background threads and display input dialogs in foreground threads (QInputDialog).
void sigBlockShowWidget (const QString &className, int &nRet, void *pContext)
 Blocks the background thread and displays the window in the foreground thread.
void sigSecurityLevel (CSecurityLevel::Levels level)
 Triggered when the security level changes.
Protected Types inherited from CBackend
enum class  OnInitReturnValue { Fail = -1 , Success = 0 , UseOnProcess = Success , NotUseOnProcess = 1 }
Protected Slots inherited from CBackend
virtual void slotTimeOut ()
 a non-Qt event loop (that is, normal loop processing), It call OnProcess(), and start timer.

Detailed Description

Definition at line 23 of file BackendVnc.h.

Constructor & Destructor Documentation

◆ CBackendVnc()

CBackendVnc::CBackendVnc ( COperateDesktop * pOperate)
explicit

Definition at line 98 of file BackendVnc.cpp.

◆ ~CBackendVnc()

CBackendVnc::~CBackendVnc ( )
overridevirtual

Definition at line 128 of file BackendVnc.cpp.

Member Function Documentation

◆ authSuccess()

void CBackendVnc::authSuccess ( )
overridevirtual

Definition at line 1319 of file BackendVnc.cpp.

◆ bell()

void CBackendVnc::bell ( )
overridevirtual

Definition at line 644 of file BackendVnc.cpp.

◆ ConnectInformation()

QString CBackendVnc::ConnectInformation ( )
private

Definition at line 964 of file BackendVnc.cpp.

◆ fence()

void CBackendVnc::fence ( uint32_t flags,
unsigned int len,
const uint8_t data[] )
overridevirtual

Definition at line 678 of file BackendVnc.cpp.

◆ framebufferUpdateEnd()

void CBackendVnc::framebufferUpdateEnd ( )
overridevirtual

Definition at line 767 of file BackendVnc.cpp.

◆ framebufferUpdateStart()

void CBackendVnc::framebufferUpdateStart ( )
overridevirtual

Definition at line 757 of file BackendVnc.cpp.

◆ getUserPasswd()

void CBackendVnc::getUserPasswd ( bool secure,
std::string * user,
std::string * password )
overridevirtual

Definition at line 691 of file BackendVnc.cpp.

◆ getX509File()

int CBackendVnc::getX509File ( std::string * ca,
std::string * crl )
overridevirtual

Definition at line 712 of file BackendVnc.cpp.

◆ handleClipboardAnnounce()

void CBackendVnc::handleClipboardAnnounce ( bool available)
overridevirtual

Definition at line 1301 of file BackendVnc.cpp.

◆ handleClipboardData()

void CBackendVnc::handleClipboardData ( const char * data)
overridevirtual

Definition at line 1309 of file BackendVnc.cpp.

◆ handleClipboardRequest()

void CBackendVnc::handleClipboardRequest ( )
overridevirtual

Definition at line 1269 of file BackendVnc.cpp.

◆ IceInit()

int CBackendVnc::IceInit ( )
private

Definition at line 220 of file BackendVnc.cpp.

◆ initDone()

void CBackendVnc::initDone ( )
overridevirtual

Definition at line 602 of file BackendVnc.cpp.

◆ InputMethodEvent()

void CBackendVnc::InputMethodEvent ( QInputMethodEvent * event)
overrideprotectedvirtual

Implements CBackendDesktop.

Definition at line 960 of file BackendVnc.cpp.

◆ keyPressEvent()

void CBackendVnc::keyPressEvent ( QKeyEvent * event)
overrideprotectedvirtual

Implements CBackendDesktop.

Definition at line 924 of file BackendVnc.cpp.

◆ keyReleaseEvent()

void CBackendVnc::keyReleaseEvent ( QKeyEvent * event)
overrideprotectedvirtual

Implements CBackendDesktop.

Definition at line 942 of file BackendVnc.cpp.

◆ mouseMoveEvent()

void CBackendVnc::mouseMoveEvent ( QMouseEvent * event)
overrideprotectedvirtual

Implements CBackendDesktop.

Definition at line 851 of file BackendVnc.cpp.

◆ mousePressEvent()

void CBackendVnc::mousePressEvent ( QMouseEvent * event)
overrideprotectedvirtual

Implements CBackendDesktop.

Definition at line 809 of file BackendVnc.cpp.

◆ mouseReleaseEvent()

void CBackendVnc::mouseReleaseEvent ( QMouseEvent * event)
overrideprotectedvirtual

Implements CBackendDesktop.

Definition at line 836 of file BackendVnc.cpp.

◆ OnClean()

int CBackendVnc::OnClean ( )
overrideprotectedvirtual

Clean.

See also
Stop()

Implements CBackend.

Definition at line 431 of file BackendVnc.cpp.

◆ OnInit()

CBackendVnc::OnInitReturnValue CBackendVnc::OnInit ( )
overrideprotectedvirtual

Initialization.

Returns
CBackend::OnInitReturnValue
  • OnInitReturnValue::Fail: error
  • OnInitReturnValue::Success/OnInitReturnValue::UseOnProcess: Use OnProcess() (non-Qt event loop)
  • OnInitReturnValue::NotUseOnProcess: Don't use OnProcess() (qt event loop)
See also
Start()

Implements CBackend.

Definition at line 198 of file BackendVnc.cpp.

◆ OnProcess()

int CBackendVnc::OnProcess ( )
overrideprotectedvirtual

Specific operation processing of plug-in connection.

Because of it is a non-Qt event loop, so wait in here.

Returns
  • >= 0: continue, Interval call time (msec)
  • = -1: stop
  • < -1: error
See also
CConnect::Connect() CConnect::slotTimeOut()

Reimplemented from CBackend.

Definition at line 456 of file BackendVnc.cpp.

◆ resizeFramebuffer()

void CBackendVnc::resizeFramebuffer ( )
overridevirtual

Definition at line 623 of file BackendVnc.cpp.

◆ SetChannelConnect()

int CBackendVnc::SetChannelConnect ( QSharedPointer< CChannel > channel)
private

Definition at line 405 of file BackendVnc.cpp.

◆ setColourMapEntries()

void CBackendVnc::setColourMapEntries ( int firstColour,
int nColours,
uint16_t * rgbs )
overridevirtual

Definition at line 639 of file BackendVnc.cpp.

◆ setCursor()

void CBackendVnc::setCursor ( int width,
int height,
const rfb::Point & hotspot,
const uint8_t * data )
overridevirtual

Definition at line 656 of file BackendVnc.cpp.

◆ setCursorPos()

void CBackendVnc::setCursorPos ( const rfb::Point & pos)
overridevirtual

Definition at line 672 of file BackendVnc.cpp.

◆ setLEDState()

void CBackendVnc::setLEDState ( unsigned int state)
overridevirtual

Definition at line 649 of file BackendVnc.cpp.

◆ setName()

void CBackendVnc::setName ( const char * name)
overridevirtual

Definition at line 745 of file BackendVnc.cpp.

◆ SetPara()

int CBackendVnc::SetPara ( )
private

Definition at line 133 of file BackendVnc.cpp.

◆ showMsgBox()

bool CBackendVnc::showMsgBox ( rfb::MsgBoxFlags flags,
const char * title,
const char * text )
overridevirtual

Definition at line 722 of file BackendVnc.cpp.

◆ slotChannelError

void CBackendVnc::slotChannelError ( int nErr,
const QString & szErr )
slot

Definition at line 592 of file BackendVnc.cpp.

◆ slotClipBoardChanged

void CBackendVnc::slotClipBoardChanged ( )
overridevirtualslot

Definition at line 1260 of file BackendVnc.cpp.

◆ slotConnected

void CBackendVnc::slotConnected ( )
virtualslot

Definition at line 482 of file BackendVnc.cpp.

◆ slotDisConnected

void CBackendVnc::slotDisConnected ( )
virtualslot

Definition at line 519 of file BackendVnc.cpp.

◆ slotReadyRead

void CBackendVnc::slotReadyRead ( )
virtualslot

Definition at line 536 of file BackendVnc.cpp.

◆ SocketInit()

int CBackendVnc::SocketInit ( )
private

Definition at line 265 of file BackendVnc.cpp.

◆ SSHInit()

int CBackendVnc::SSHInit ( )
private

Definition at line 374 of file BackendVnc.cpp.

◆ TranslateRfbKey()

quint32 CBackendVnc::TranslateRfbKey ( quint32 inkey,
bool modifier )
private

◆ updatePixelFormat()

void CBackendVnc::updatePixelFormat ( )
private

Definition at line 781 of file BackendVnc.cpp.

◆ WakeUp()

int CBackendVnc::WakeUp ( )
overrideprotectedvirtual

Wake up backend thread(background thread).

When it is block(a non-Qt event loop)

Note
The caller is main thread(UI thread)

Implements CBackend.

Definition at line 470 of file BackendVnc.cpp.

◆ wheelEvent()

void CBackendVnc::wheelEvent ( QWheelEvent * event)
overrideprotectedvirtual

Implements CBackendDesktop.

Definition at line 878 of file BackendVnc.cpp.

Member Data Documentation

◆ m_DataChannel

QSharedPointer<CChannel> CBackendVnc::m_DataChannel
private

Definition at line 87 of file BackendVnc.h.

◆ m_InStream

QSharedPointer<rdr::InStream> CBackendVnc::m_InStream
private

Definition at line 88 of file BackendVnc.h.

◆ m_OutStream

QSharedPointer<rdr::OutStream> CBackendVnc::m_OutStream
private

Definition at line 89 of file BackendVnc.h.

◆ m_pOperate

COperateDesktop* CBackendVnc::m_pOperate
private

Definition at line 95 of file BackendVnc.h.

◆ m_pPara

CParameterVnc* CBackendVnc::m_pPara
private

Definition at line 96 of file BackendVnc.h.

◆ m_SecurityLevel

CSecurityLevel::Levels CBackendVnc::m_SecurityLevel
private

Definition at line 107 of file BackendVnc.h.


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