Exemplo n.º 1
0
LRESULT AccountEditorDialog::OnDoubleClick(int, NMHDR*, BOOL&)
{
	BOOL handled = FALSE;
	OnEdit(0, 0, 0, handled);

	return 0;
}
Exemplo n.º 2
0
//--------------------------------------------------------------------------------------
//!
//--------------------------------------------------------------------------------------
void tWorkProfilesDialog::CreateActions()
{
    m_pEditAct = new tAction( tr( "Edit" ) );
    Connect( m_pEditAct, SIGNAL( triggered() ), this, SLOT( OnEdit() ) );
    m_ActionList << m_pEditAct;

    m_pDeleteAct = new tAction( tr( "Delete" ) );
    m_pDeleteAct->setEnabled(false);
    Connect( m_pDeleteAct, SIGNAL( triggered() ), this, SLOT( OnDelete() ) );
    m_ActionList << m_pDeleteAct;

    m_pSettingsAct = new tAction( tr( "Settings" )  + "..." );
    Connect( m_pSettingsAct, SIGNAL( triggered() ), this, SLOT( OnSettings() ) );
    m_ActionList << m_pSettingsAct;

    m_pDeleteAllAct = new tAction( tr( "Delete all" ), this );
    Connect( m_pDeleteAllAct, SIGNAL( triggered() ), this, SLOT( DeleteAllProfiles() ) );
    m_ActionList << m_pDeleteAllAct;

    if ( HasTitleCloseButton() == false )
    {
        m_pCloseAct = new tAction( tr( "Close" ), this );
        Connect( m_pCloseAct, SIGNAL( triggered() ), this, SLOT( accept() ) );
        m_ActionList << m_pCloseAct;
    }
}
Exemplo n.º 3
0
void BreakpointDlg::OnItemRightClick(wxListEvent& e)
{
    m_selectedItem = e.m_itemIndex;
    wxCommandEvent c;
    m_selectedItem = e.m_itemIndex;
    OnEdit(c);
}
Exemplo n.º 4
0
void AccelEditor::OnListDblClick(NMHDR *pNMHDR, LRESULT *pResult)
{
	if (m_currents.GetFirstSelectedItemPosition())
		OnEdit();
	else
		OnNew();
	*pResult = 0;
}
Exemplo n.º 5
0
void tAutopilotAdvancedDialog::OnGustResponseEnableChanged( bool enabled )
{
    m_pGustMinEdit->setEnabled( enabled );
    m_pGustResponseRateEdit->setEnabled( enabled );
    m_pTWAReponseEdit->setEnabled( enabled );

    OnEdit();
}
Exemplo n.º 6
0
BOOL CALLBACK SetupDlgFunc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam) {

	switch (uMsg) {
	case WM_INITDIALOG:
		return InitDialog(hWnd);

	case WM_NOTIFY:
		OnNotify(hWnd, wParam, lParam);
		break;

	case WM_COMMAND:
		switch (LOWORD(wParam))	{
		case IDOK:
			OnOK(hWnd);
			EndDialog(hWnd, IDOK);
			break;

		case IDCANCEL:
			EndDialog(hWnd, IDCANCEL);
			break;
		
		case IDC_ADD:		// アイテムの追加
			OnEdit(hWnd, TRUE);
			break;

		case IDC_MODIFY:	// アイテムの変更
			OnEdit(hWnd, FALSE);
			break;
		
		case IDC_DELETE:	// アイテムの削除
			OnDelete(hWnd);
			break;
		
		case IDC_OPENFILE:	// ファイルの参照
			OnOpenFile(hWnd);
			break;
		}
	}
	return FALSE;
}
Exemplo n.º 7
0
LRESULT CEditWnd::HandleMessage(UINT uMsg, WPARAM wParam, LPARAM lParam)
{
    LRESULT lRes = 0;
    BOOL bHandled = TRUE;
	if (uMsg == WM_KILLFOCUS) 
	{
		lRes = OnKillFocus(uMsg, wParam, lParam, bHandled);
	}
    else if (uMsg == OCM_COMMAND) 
	{
		if (GET_WM_COMMAND_CMD(wParam, lParam) == EN_CHANGE) 
		{
			lRes = OnEditChanged(uMsg, wParam, lParam, bHandled);
		}
        else if (GET_WM_COMMAND_CMD(wParam, lParam) == EN_UPDATE) 
		{
            RECT rcClient;
            ::GetClientRect(m_hWnd, &rcClient);
            ::InvalidateRect(m_hWnd, &rcClient, FALSE);
        }
	}
	else if (uMsg == WM_KEYDOWN && TCHAR(wParam) == VK_RETURN) 
	{
        m_pOwner->GetManager()->SendNotify(m_pOwner, _T("return"));
    }
	else if (uMsg == WM_KEYDOWN) 
	{
		lRes = OnEdit(uMsg, wParam, lParam, bHandled);
	}
    else if( uMsg == OCM__BASE + WM_CTLCOLOREDIT  || uMsg == OCM__BASE + WM_CTLCOLORSTATIC ) 
	{
        if (m_pOwner->GetNativeEditBkColor() == 0xFFFFFFFF) return NULL;
        //
		// TODO: Change Edit backgournd color
		//
		::SetBkMode((HDC)wParam, TRANSPARENT);
        DWORD dwTextColor = m_pOwner->GetTextColor();
        ::SetTextColor((HDC)wParam, RGB(GetBValue(dwTextColor),GetGValue(dwTextColor),GetRValue(dwTextColor)));
        if (m_hBkBrush == NULL) 
		{
            DWORD clrColor = m_pOwner->GetNativeEditBkColor();
            m_hBkBrush = ::CreateSolidBrush(RGB(GetBValue(clrColor), GetGValue(clrColor), GetRValue(clrColor)));
        }
        return (LRESULT)m_hBkBrush;
    }
    else bHandled = FALSE;
    if (!bHandled) return CWindowWnd::HandleMessage(uMsg, wParam, lParam);
    return lRes;
}
Exemplo n.º 8
0
//-----------------------------------------------------------------------------
//!
//-----------------------------------------------------------------------------
void tWorkProfilesDialog::keyPressEvent( QKeyEvent* pEvent )
{
    switch( pEvent->key() )
    {
    case Key::Enter:
    case Key::Rotary:
        if( pEvent->isAutoRepeat() )
        {
            break;
        }
        OnEdit();
        pEvent->accept();
        break;

    default:
        tDialog::keyPressEvent( pEvent );
        break;
    }
}
Exemplo n.º 9
0
void WorkspacePanel::OnActivate(wxTreeEvent& event)
{
	OnEdit(event);
}
Exemplo n.º 10
0
BOOL AccelEditor::PreTranslateMessage(MSG *pMsg)
{
	CWnd *pFocus = GetFocus();
	if (pFocus == &m_currents)
	{
		if (pMsg->message == WM_KEYDOWN)
		{
			switch (pMsg->wParam)
			{
			case VK_ESCAPE:
				m_currents.SetItemState(-1, 0, LVIS_SELECTED);
				CheckListSelections();
				break;
			case VK_RETURN:
			case VK_INSERT:
				// kludge to workaround CKeyboardEdit::PreTranslateMessage()
				break;
			case VK_DELETE:
			case VK_BACK:
				OnRemove();
				break;
			case VK_F6:
			case VK_LEFT:
				m_commands.SetFocus();
				break;
			case VK_RIGHT:
				GetDlgItem(ID_OK)->SetFocus();
			default:
				return ResizeDlg::PreTranslateMessage(pMsg);
			}
			return TRUE;
		}
		else if (pMsg->message == WM_KEYUP)	// kludge to workaround CKeyboardEdit::PreTranslateMessage()
		{
			switch (pMsg->wParam)
			{
			case VK_RETURN:
				OnEdit();
				break;
			case VK_INSERT:
				OnNew();
				break;
			default:
				return ResizeDlg::PreTranslateMessage(pMsg);
			}
			return TRUE;
		}
	}
	else if (pFocus == &m_commands)
	{
		if (pMsg->message == WM_KEYDOWN)
		{
			switch (pMsg->wParam)
			{
			case VK_F6:
				m_currents.SetFocus();
				break;
			case VK_RIGHT:
				if (!m_commands.ItemHasChildren(m_commands.GetSelectedItem()))
				{
					m_currents.SetFocus();
					break;
				}
				// fall through
			default:
				return ResizeDlg::PreTranslateMessage(pMsg);
			}
			return TRUE;
		}
	}

	return ResizeDlg::PreTranslateMessage(pMsg);
}
Exemplo n.º 11
0
PlacePageDialog::PlacePageDialog(QWidget * parent, place_page::Info const & info,
                                 search::ReverseGeocoder::Address const & address)
  : QDialog(parent)
{
  QGridLayout * grid = new QGridLayout();
  int row = 0;
  {  // Coordinates.
    grid->addWidget(new QLabel("lat, lon"), row, 0);
    ms::LatLon const ll = info.GetLatLon();
    string const llstr =
        strings::to_string_dac(ll.lat, 7) + ", " + strings::to_string_dac(ll.lon, 7);
    QLabel * label = new QLabel(llstr.c_str());
    label->setTextInteractionFlags(Qt::TextSelectableByMouse);
    grid->addWidget(label, row++, 1);
  }
  {
    grid->addWidget(new QLabel("CountryId"), row, 0);
    QLabel * label = new QLabel(QString::fromStdString(info.GetCountryId()));
    label->setTextInteractionFlags(Qt::TextSelectableByMouse);
    grid->addWidget(label, row++, 1);
  }
  // Title/Name/Custom Name.
  if (!info.GetTitle().empty())
  {
    grid->addWidget(new QLabel("Title"), row, 0);
    QLabel * label = new QLabel(QString::fromStdString(info.GetTitle()));
    label->setTextInteractionFlags(Qt::TextSelectableByMouse);
    grid->addWidget(label, row++, 1);
  }
  // Subtitle.
  if (info.IsFeature())
  {
    grid->addWidget(new QLabel("Subtitle"), row, 0);
    QLabel * label = new QLabel(QString::fromStdString(info.GetSubtitle()));
    label->setTextInteractionFlags(Qt::TextSelectableByMouse);
    grid->addWidget(label, row++, 1);
  }
  {  // Address.
    grid->addWidget(new QLabel("Address"), row, 0);
    QLabel * label = new QLabel(QString::fromStdString(address.FormatAddress()));
    label->setTextInteractionFlags(Qt::TextSelectableByMouse);
    grid->addWidget(label, row++, 1);
  }
  if (info.IsBookmark())
  {
    grid->addWidget(new QLabel("Bookmark"), row, 0);
    grid->addWidget(new QLabel("Yes"), row++, 1);
  }
  if (info.IsMyPosition())
  {
    grid->addWidget(new QLabel("MyPosition"), row, 0);
    grid->addWidget(new QLabel("Yes"), row++, 1);
  }
  if (info.HasApiUrl())
  {
    grid->addWidget(new QLabel("Api URL"), row, 0);
    grid->addWidget(new QLabel(QString::fromStdString(info.GetApiUrl())), row++, 1);
  }
  if (info.IsFeature())
  {
    grid->addWidget(new QLabel("Feature ID"), row, 0);
    grid->addWidget(new QLabel(QString::fromStdString(DebugPrint(info.GetID()))), row++, 1);

    grid->addWidget(new QLabel("Raw Types"), row, 0);
    QLabel * label = new QLabel(QString::fromStdString(DebugPrint(info.GetTypes())));
    label->setTextInteractionFlags(Qt::TextSelectableByMouse);
    grid->addWidget(label, row++, 1);
  }
  for (auto const prop : info.AvailableProperties())
  {
    QString k;
    string v;
    bool link = false;
    switch (prop)
    {
    case osm::Props::Phone:
      k = "Phone";
      v = info.GetPhone();
      break;
    case osm::Props::Fax:
      k = "Fax";
      v = info.GetFax();
      break;
    case osm::Props::Email:
      k = "Email";
      v = info.GetEmail();
      link = true;
      break;
    case osm::Props::Website:
      k = "Website";
      v = info.GetWebsite();
      link = true;
      break;
    case osm::Props::Internet:
      k = "Internet";
      v = DebugPrint(info.GetInternet());
      break;
    case osm::Props::Cuisine:
      k = "Cuisine";
      v = strings::JoinStrings(info.GetCuisines(), ", ");
      break;
    case osm::Props::OpeningHours:
      k = "OpeningHours";
      v = info.GetOpeningHours();
      break;
    case osm::Props::Stars:
      k = "Stars";
      v = GenerateStars(info.GetStars());
      break;
    case osm::Props::Operator:
      k = "Operator";
      v = info.GetOperator();
      break;
    case osm::Props::Elevation:
      k = "Elevation";
      v = info.GetElevationFormatted();
      break;
    case osm::Props::Wikipedia:
      k = "Wikipedia";
      v = info.GetWikipediaLink();
      link = true;
      break;
    case osm::Props::Flats:
      k = "Flats";
      v = info.GetFlats();
      break;
    case osm::Props::BuildingLevels:
      k = "Building Levels";
      v = info.GetBuildingLevels();
      break;
    case osm::Props::Level:
      k = "Level";
      v = info.GetLevel();
      break;
    }
    grid->addWidget(new QLabel(k), row, 0);
    QLabel * label = new QLabel(QString::fromStdString(v));
    label->setTextInteractionFlags(Qt::TextSelectableByMouse);
    if (link)
    {
      label->setOpenExternalLinks(true);
      label->setTextInteractionFlags(Qt::TextBrowserInteraction);
      label->setText(QString::fromStdString("<a href=\"" + v + "\">" + v + "</a>"));
    }
    grid->addWidget(label, row++, 1);
  }

  QDialogButtonBox * dbb = new QDialogButtonBox();
  QPushButton * closeButton = new QPushButton("Close");
  closeButton->setDefault(true);
  connect(closeButton, SIGNAL(clicked()), this, SLOT(OnClose()));
  dbb->addButton(closeButton, QDialogButtonBox::RejectRole);

  if (info.ShouldShowEditPlace())
  {
    QPushButton * editButton = new QPushButton("Edit Place");
    connect(editButton, SIGNAL(clicked()), this, SLOT(OnEdit()));
    dbb->addButton(editButton, QDialogButtonBox::AcceptRole);
  }
  grid->addWidget(dbb);
  setLayout(grid);

  string const title = string("Place Page") + (info.IsBookmark() ? " (bookmarked)" : "");
  setWindowTitle(title.c_str());
}
Exemplo n.º 12
0
tLaylinesDialogTarget::tLaylinesDialogTarget( tSailingSettings& sailingSettings, QWidget* pParent )
: tSaveCancelDialog( tDialog::Partial, pParent )
, m_pTrueWindAngleCombo( 0 )
, m_pUpwindAngleLabel( 0 )
, m_pUpwindAngleEdit( 0 )
, m_pDownwindAngleLabel( 0 )
, m_pDownwindAngleEdit( 0 )
, m_pUpwindSpeedLabel( 0 )
, m_pUpwindSpeedEdit( 0 )
, m_pDownwindSpeedLabel( 0 )
, m_pDownwindSpeedEdit( 0 )
, m_SailingSettings( sailingSettings )
{
    setWindowTitle( tr("Targets") );

    // True Wind Angle
    QLabel* pTwaLabel = new QLabel( tr("True wind angle"), this );
    int initialIndex = static_cast<int>( m_SailingSettings.LaylineTargetAngleOption() );

    m_pTrueWindAngleCombo = new tComboBox( m_SailingSettings.LaylineTargetAngleOptionList(), initialIndex, this ); 
    Connect( m_pTrueWindAngleCombo, SIGNAL( currentIndexChanged(int) ), this, SLOT( OnEdit() ) );
    
    m_pUpwindAngleLabel = new QLabel( tr( "Upwind true wind angle (°)" ), this );
    m_pUpwindAngleEdit = new tIntEdit( m_SailingSettings.LaylineUpwindAngle(), 5, 85, this );
    Connect( m_pUpwindAngleEdit, SIGNAL( EditingFinished(int) ), this, SLOT( OnEdit() ) );

    m_pDownwindAngleLabel = new QLabel( tr( "Downwind true wind angle (°)" ), this );
    m_pDownwindAngleEdit = new tIntEdit( m_SailingSettings.LaylineDownwindAngle(), 95, 175, this );
    Connect( m_pDownwindAngleEdit, SIGNAL( EditingFinished(int) ), this, SLOT( OnEdit() ) );

    tConvert* pConvert = tConvert::Instance();
    const float cMaxTargetSpeedUserUnits = pConvert->BaseToUser( UNITS_BOAT_SPEED, cMaxTargetSpeed );
    const QString speedUnitsString = pConvert->GetUnitsString( UNITS_BOAT_SPEED );

    float currentValueInBaseUnits = m_SailingSettings.TargetUpwindSpeed();
    float currentValueInUserUnits = pConvert->BaseToUser( UNITS_BOAT_SPEED, currentValueInBaseUnits );
    m_pUpwindSpeedLabel = new QLabel( QString( tr( "Upwind speed (%1)" ) ).arg( speedUnitsString ), this );
    m_pUpwindSpeedEdit = new tDoubleEdit( currentValueInUserUnits, 0.0, cMaxTargetSpeedUserUnits, 1, this ); 
    Connect( m_pUpwindSpeedEdit, SIGNAL( EditingFinished() ), this, SLOT( OnEdit() ) );

    currentValueInBaseUnits = m_SailingSettings.TargetDownwindSpeed();
    currentValueInUserUnits = pConvert->BaseToUser( UNITS_BOAT_SPEED, currentValueInBaseUnits );
    m_pDownwindSpeedLabel = new QLabel( QString( tr( "Downwind speed (%1)" ) ).arg( speedUnitsString ), this );
    m_pDownwindSpeedEdit = new tDoubleEdit( currentValueInUserUnits, 0.0, cMaxTargetSpeedUserUnits, 1, this ); 
    Connect( m_pDownwindSpeedEdit, SIGNAL( EditingFinished() ), this, SLOT( OnEdit() ) );

    // Main layout
    QGridLayout* pMainLayout = new QGridLayout( this );
    int row = 0;

    pMainLayout->addWidget( pTwaLabel, row, 0 );
    pMainLayout->addWidget( m_pTrueWindAngleCombo, row++, 1 );
    pMainLayout->addWidget( m_pUpwindAngleLabel, row, 0 );
    pMainLayout->addWidget( m_pUpwindAngleEdit, row++, 1 );
    pMainLayout->addWidget( m_pDownwindAngleLabel, row, 0 );
    pMainLayout->addWidget( m_pDownwindAngleEdit, row++, 1 );

    pMainLayout->addWidget( m_pUpwindSpeedLabel, row, 0 );
    pMainLayout->addWidget( m_pUpwindSpeedEdit, row++, 1 );
    pMainLayout->addWidget( m_pDownwindSpeedLabel, row, 0 );
    pMainLayout->addWidget( m_pDownwindSpeedEdit, row++, 1 );

    setLayout( pMainLayout );

    Connect( m_pTrueWindAngleCombo, SIGNAL( currentIndexChanged(int) ), this, SLOT( UpdateEnabled() ) );
    UpdateEnabled();
}
Exemplo n.º 13
0
void COverallDataView::OnRMenuEdit()
{
	OnEdit();
}
Exemplo n.º 14
0
//-----------------------------------------------------------------------------
//! Constructor for a dialog
//-----------------------------------------------------------------------------
tAutopilotAdvancedDialog::tAutopilotAdvancedDialog( tPilotController& pilotDevice, QWidget* pParent )
: tSaveCancelDialog( tDialog::Full, pParent )
, m_PilotDevice(pilotDevice)
{
    setWindowTitle( tr( "Advanced" ) );

    tPilotH5000AdvancedInterface::tH5000AdvancedParameters h5000AdvancedParameters;
    m_PilotDevice.GetH5000AdvancedInterface()->GetH5000AdvancedParameters( &h5000AdvancedParameters );

    // Gust response
    tLabel* pGustResponseLbl = new tLabel( QString( tr( "Gust response" ) ), this );

    // Gust response - enable
    tLabel* pGustResponseEnableLbl = new tLabel( QString( tr( "Enable" ) ), this );
    m_pGustResponseCheck = new tCheckBox( false, this );
    m_pGustResponseCheck->setChecked( h5000AdvancedParameters.gustResponse );
    Connect( m_pGustResponseCheck, SIGNAL( toggled( bool ) ), this, SLOT( OnGustResponseEnableChanged( bool ) ) );

    // Gust response - Gust MIN
    tLabel* pGustMinLbl = new tLabel( QString( tr( "Gust MIN" ) ), this );
    m_pGustMinEdit = new tIntEdit( h5000AdvancedParameters.gustMin, 1, 10, this );
    m_pGustMinEdit->setFixedWidth( 100 );
    m_pGustMinEdit->setEnabled( m_pGustResponseCheck->isChecked() );
    Connect( m_pGustMinEdit, SIGNAL( EditingFinished( int ) ), this, SLOT( OnEdit() ) );

    // Gust response - Response rate
    tLabel* pGuestResponseRateLbl = new tLabel( QString( tr( "Response rate" ) ), this );
    m_pGustResponseRateEdit = new tIntEdit( h5000AdvancedParameters.gustResponseRate, 1, 10, this );
    m_pGustResponseRateEdit->setFixedWidth( 100 );
    m_pGustResponseRateEdit->setEnabled( m_pGustResponseCheck->isChecked() );
    Connect( m_pGustResponseRateEdit, SIGNAL( EditingFinished( int ) ), this, SLOT( OnEdit() ) );
    
    // Gust response - TWA response
    tLabel* pTWAResponseLbl = new tLabel( QString( tr( "TWA response" ) ), this );
    m_pTWAReponseEdit = new tDoubleEdit( h5000AdvancedParameters.TWAResponse, 1.0F, 5.0F, 1, this );
    m_pTWAReponseEdit->setFixedWidth( 100 );
    m_pTWAReponseEdit->setEnabled( m_pGustResponseCheck->isChecked() );
    Connect( m_pTWAReponseEdit, SIGNAL( EditingFinished() ), this, SLOT( OnEdit() ) );
    
    // TWS response
    tLabel* pTWSResponseLbl = new tLabel( QString( tr( "TWS response" ) ), this );

    // TWS response - enable
    tLabel* pTWSResponseEnableLbl = new tLabel( QString( tr( "Enable" ) ), this );
    m_pTWSCheck = new tCheckBox( false, this );
    m_pTWSCheck->setChecked( h5000AdvancedParameters.TWSResponse );
    Connect( m_pTWSCheck, SIGNAL( toggled( bool ) ), this, SLOT( OnTWSResponseEnableChanged( bool ) ) );

    // TWS response - Response rate
    tLabel* pTWSResponseRateLbl = new tLabel( QString( tr( "Response rate" ) ), this );
    m_pTWSResponseRateEdit = new tIntEdit( h5000AdvancedParameters.TWSResponseRate, 1, 10, this );
    m_pTWSResponseRateEdit->setFixedWidth( 100 );
    m_pTWSResponseRateEdit->setEnabled( m_pTWSCheck->isChecked() );
    Connect( m_pTWSResponseRateEdit, SIGNAL( EditingFinished( int ) ), this, SLOT( OnEdit() ) );
    
    // Heel compensation
    tLabel* pHeelCompensationLbl = new tLabel( QString( tr( "Heel compensation" ) ), this );

    // Heel compensation - enable
    tLabel* pHeelCompensationEnableLbl = new tLabel( QString( tr( "Enable" ) ), this );
    m_pHeelCompensationCheck = new tCheckBox( false, this );
    m_pHeelCompensationCheck->setChecked( h5000AdvancedParameters.heelCompensation );
    Connect( m_pHeelCompensationCheck, SIGNAL( toggled( bool ) ), this, SLOT( OnHeelCompensationEnableChanged( bool ) ) );

    // Heel compensation - Response rate
    tLabel* pHeelCompensationResponseRateLbl = new tLabel( QString( tr( "Response rate" ) ), this );
    m_pHeelCompensationResponseRateEdit = new tIntEdit( h5000AdvancedParameters.heelCompensationRate, 1, 10, this );
    m_pHeelCompensationResponseRateEdit->setFixedWidth( 100 );
    m_pHeelCompensationResponseRateEdit->setEnabled( m_pHeelCompensationCheck->isChecked() );
    Connect( m_pHeelCompensationResponseRateEdit, SIGNAL( EditingFinished( int ) ), this, SLOT( OnEdit() ) );
    
    int row( 0 );
    QGridLayout* pGridLayout = new QGridLayout( this );

    // Gust response
    pGridLayout->addWidget( pGustResponseLbl, row++, 0 ); 
    pGridLayout->addWidget( pGustResponseEnableLbl, row, 0, Qt::AlignRight  ); 
    pGridLayout->addWidget( m_pGustResponseCheck, row++, 1 );
    pGridLayout->addWidget( pGustMinLbl, row, 0, Qt::AlignRight  ); 
    pGridLayout->addWidget( m_pGustMinEdit, row++, 1 );
    pGridLayout->addWidget( pGuestResponseRateLbl, row, 0, Qt::AlignRight  ); 
    pGridLayout->addWidget( m_pGustResponseRateEdit, row++, 1 );
    pGridLayout->addWidget( pTWAResponseLbl, row, 0, Qt::AlignRight  ); 
    pGridLayout->addWidget( m_pTWAReponseEdit, row++, 1 );

    // TWS response
    pGridLayout->addWidget( pTWSResponseLbl, row++, 0 ); 
    pGridLayout->addWidget( pTWSResponseEnableLbl, row, 0, Qt::AlignRight  ); 
    pGridLayout->addWidget( m_pTWSCheck, row++, 1 );
    pGridLayout->addWidget( pTWSResponseRateLbl, row, 0, Qt::AlignRight  ); 
    pGridLayout->addWidget( m_pTWSResponseRateEdit, row++, 1 );

    // Heel compensation
    pGridLayout->addWidget( pHeelCompensationLbl, row++, 0 ); 
    pGridLayout->addWidget( pHeelCompensationEnableLbl, row, 0, Qt::AlignRight  ); 
    pGridLayout->addWidget( m_pHeelCompensationCheck, row++, 1 );
    pGridLayout->addWidget( pHeelCompensationResponseRateLbl, row, 0, Qt::AlignRight  ); 
    pGridLayout->addWidget( m_pHeelCompensationResponseRateEdit, row++, 1 );

    setLayout( pGridLayout );

    m_pGustResponseCheck->setFocus();

    Connect ( m_PilotDevice.GetH5000AdvancedInterface(), SIGNAL( H5000AdvancedParametersChanged( tPilotH5000AdvancedInterface::tH5000AdvancedParameters ) ),
              this, SLOT( OnH5000AdvancedParametersChanged( tPilotH5000AdvancedInterface::tH5000AdvancedParameters ) ) );
}
Exemplo n.º 15
0
void tAutopilotAdvancedDialog::OnHeelCompensationEnableChanged( bool enabled )
{
    m_pHeelCompensationResponseRateEdit->setEnabled( enabled );

    OnEdit();
}
Exemplo n.º 16
0
void tAutopilotAdvancedDialog::OnTWSResponseEnableChanged( bool enabled )
{
    m_pTWSResponseRateEdit->setEnabled( enabled );

    OnEdit();
}