MCPcopy Create free account
hub / github.com/KangLin/RabbitRemoteControl / SetParameter

Method SetParameter

Src/OperateDesktop.cpp:451–485  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

449}
450
451int COperateDesktop::SetParameter(CParameterBase *p)
452{
453 Q_ASSERT(!m_pPara);
454 m_pPara = p;
455 if(GetParameter())
456 {
457 bool check = false;
458 check = connect(GetParameter(), SIGNAL(sigNameChanged()),
459 this, SLOT(slotUpdateName()));
460 Q_ASSERT(check);
461 check = connect(GetParameter(), SIGNAL(sigShowServerNameChanged()),
462 this, SLOT(slotUpdateName()));
463 Q_ASSERT(check);
464 check = connect(GetParameter(), &CParameter::sigChanged,
465 this, [&](){
466 emit this->sigUpdateParameters(this);
467 });
468 Q_ASSERT(check);
469 CFrmViewer* pViewer = m_pFrmViewer;
470 if(pViewer) {
471 check = connect(GetParameter(), SIGNAL(sigZoomFactorChanged(double)),
472 pViewer, SLOT(slotSetZoomFactor(double)));
473 Q_ASSERT(check);
474 check = connect(
475 GetParameter(),
476 SIGNAL(sigAdaptWindowsChanged(CFrmViewer::ADAPT_WINDOWS)),
477 pViewer, SLOT(slotSetAdaptWindows(CFrmViewer::ADAPT_WINDOWS)));
478 Q_ASSERT(check);
479 check = connect(GetParameter(), SIGNAL(sigEnableInputMethod(bool)),
480 pViewer, SLOT(slotEnableInputMethod(bool)));
481 Q_ASSERT(check);
482 }
483 }
484 return 0;
485}
486
487int COperateDesktop::LoadAdaptWindows()
488{

Callers 3

GetSettingsWidgetsMethod · 0.45
SetContextMethod · 0.45
SetUserMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected