Changeset 15 in flair-src for trunk/lib/FlairFilter/src/UavMultiplex.cpp


Ignore:
Timestamp:
04/08/16 15:40:57 (8 years ago)
Author:
Bayard Gildas
Message:

sources reformatted with flair-format-dir script

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/FlairFilter/src/UavMultiplex.cpp

    r10 r15  
    2727using namespace flair::gui;
    2828
    29 namespace flair
    30 {
    31 namespace filter
    32 {
     29namespace flair {
     30namespace filter {
    3331
    34 UavMultiplex::UavMultiplex(const core::FrameworkManager* parent,std::string name) : IODevice(parent,name)
    35 {
    36     pimpl_=new UavMultiplex_impl(parent,this,name);
     32UavMultiplex::UavMultiplex(const core::FrameworkManager *parent,
     33                           std::string name)
     34    : IODevice(parent, name) {
     35  pimpl_ = new UavMultiplex_impl(parent, this, name);
    3736}
    3837
    39 UavMultiplex::~UavMultiplex(void)
    40 {
    41     delete pimpl_;
     38UavMultiplex::~UavMultiplex(void) { delete pimpl_; }
     39
     40void UavMultiplex::Update(core::Time time) {
     41  pimpl_->input->SetDataTime(time);
     42  UpdateFrom(pimpl_->input);
    4243}
    4344
    44 void UavMultiplex::Update(core::Time time)
    45 {
    46     pimpl_->input->SetDataTime(time);
    47     UpdateFrom(pimpl_->input);
     45void UavMultiplex::SetMultiplexComboBox(string name, int index) {
     46  pimpl_->SetMultiplexComboBox(name, index);
    4847}
    4948
    50 void UavMultiplex::SetMultiplexComboBox(string name,int index)
    51 {
    52     pimpl_->SetMultiplexComboBox(name,index);
     49int UavMultiplex::MultiplexValue(int index) const {
     50  return pimpl_->MultiplexValue(index);
    5351}
    5452
    55 int UavMultiplex::MultiplexValue(int index) const
    56 {
    57     return pimpl_->MultiplexValue(index);
     53TabWidget *UavMultiplex::GetTabWidget(void) const { return pimpl_->tabwidget; }
     54
     55Layout *UavMultiplex::GetLayout(void) const { return pimpl_->setup_tab; }
     56
     57void UavMultiplex::LockUserInterface(void) const {
     58  pimpl_->setup_tab->setEnabled(false);
    5859}
    5960
    60 TabWidget* UavMultiplex::GetTabWidget(void) const
    61 {
    62     return pimpl_->tabwidget;
     61void UavMultiplex::UnlockUserInterface(void) const {
     62  pimpl_->setup_tab->setEnabled(true);
    6363}
    6464
    65 Layout* UavMultiplex::GetLayout(void) const
    66 {
    67     return pimpl_->setup_tab;
     65void UavMultiplex::SetRoll(float value) {
     66  pimpl_->input->SetValue(0, 0, value);
    6867}
    6968
    70 void UavMultiplex::LockUserInterface(void) const
    71 {
    72     pimpl_->setup_tab->setEnabled(false);
     69void UavMultiplex::SetPitch(float value) {
     70  pimpl_->input->SetValue(1, 0, value);
    7371}
    7472
    75 void UavMultiplex::UnlockUserInterface(void) const
    76 {
    77     pimpl_->setup_tab->setEnabled(true);
     73void UavMultiplex::SetYaw(float value) { pimpl_->input->SetValue(2, 0, value); }
     74
     75void UavMultiplex::SetThrust(float value) {
     76  pimpl_->input->SetValue(3, 0, value);
    7877}
    7978
    80 void UavMultiplex::SetRoll(float value)
    81 {
    82     pimpl_->input->SetValue(0,0,value);
     79void UavMultiplex::SetRollTrim(float value) {
     80  pimpl_->input->SetValue(4, 0, value);
    8381}
    8482
    85 void UavMultiplex::SetPitch(float value)
    86 {
    87     pimpl_->input->SetValue(1,0,value);
     83void UavMultiplex::SetPitchTrim(float value) {
     84  pimpl_->input->SetValue(5, 0, value);
    8885}
    8986
    90 void UavMultiplex::SetYaw(float value)
    91 {
    92     pimpl_->input->SetValue(2,0,value);
    93 }
    94 
    95 void UavMultiplex::SetThrust(float value)
    96 {
    97     pimpl_->input->SetValue(3,0,value);
    98 }
    99 
    100 void UavMultiplex::SetRollTrim(float value)
    101 {
    102     pimpl_->input->SetValue(4,0,value);
    103 }
    104 
    105 void UavMultiplex::SetPitchTrim(float value)
    106 {
    107     pimpl_->input->SetValue(5,0,value);
    108 }
    109 
    110 void UavMultiplex::SetYawTrim(float value)
    111 {
    112     pimpl_->input->SetValue(6,0,value);
     87void UavMultiplex::SetYawTrim(float value) {
     88  pimpl_->input->SetValue(6, 0, value);
    11389}
    11490
Note: See TracChangeset for help on using the changeset viewer.