]> ruin.nu Git - hbs.git/blobdiff - bs/ui/infoview.ui.h
much better indenting.. (thnx vim ;)
[hbs.git] / bs / ui / infoview.ui.h
index 1a7d70d4d473669b41ba6d2f24d71c550b490adc..14ee7ed09b3365d31233f2e4d80d33f57e85eeb8 100644 (file)
@@ -10,42 +10,42 @@ void InfoView::destroy()
 
 void InfoView::setRaces( std::vector<QString> races)
 {
-    for (std::vector<QString>::iterator i = races.begin(); i != races.end(); ++i)
-    {
-       RaceCombo->insertItem((*i));
-    }
-    if ( RaceCombo->count() != 0)
-       NewButton->setEnabled(true);
+       for (std::vector<QString>::iterator i = races.begin(); i != races.end(); ++i)
+       {
+               RaceCombo->insertItem((*i));
+       }
+       if ( RaceCombo->count() != 0)
+               NewButton->setEnabled(true);
 }
 
 void InfoView::setEta( int eta )
 {
-    EtaSpin->setValue(eta);
+       EtaSpin->setValue(eta);
 }
 
 void InfoView::setFleetName( QString name )
 {
-    NameLine->setText(name);
-    m_Name = name;
-    if (m_Name == "Home Planet" && m_Group == "Friendly")
-    {
-       GroupCombo->setEnabled(false);
-       BattleCombo->setEnabled(false);
+       NameLine->setText(name);
+       m_Name = name;
+       if (m_Name == "Home Planet" && m_Group == "Friendly")
+       {
+               GroupCombo->setEnabled(false);
+               BattleCombo->setEnabled(false);
+               ApplyButton->setEnabled(true);
+               NewButton->setEnabled(false);
+               RemoveButton->setEnabled(false);
+               return;
+       }
+       GroupCombo->setEnabled(true);
+       BattleCombo->setEnabled(true);
        ApplyButton->setEnabled(true);
-       NewButton->setEnabled(false);
-       RemoveButton->setEnabled(false);
-       return;
-    }
-    GroupCombo->setEnabled(true);
-    BattleCombo->setEnabled(true);
-    ApplyButton->setEnabled(true);
-    NewButton->setEnabled(true);
-    RemoveButton->setEnabled(true);
+       NewButton->setEnabled(true);
+       RemoveButton->setEnabled(true);
 }
 
 void InfoView::setRace( QString name )
 {
-    RaceCombo->setCurrentText(name);
+       RaceCombo->setCurrentText(name);
 }
 
 void InfoView::InfoView_destroyed( QObject * )
@@ -55,108 +55,108 @@ void InfoView::InfoView_destroyed( QObject * )
 
 void InfoView::CancelButton_clicked()
 {
-    emit cancel();
+       emit cancel();
 }
 
 void InfoView::NewButton_clicked()
 {
-    emit add();
+       emit add();
 }
 
 void InfoView::RemoveButton_clicked()
 {
-    emit remove();
+       emit remove();
 }
 
 void InfoView::setGroup( QString s )
 {
-    GroupCombo->setCurrentText(s);
-    m_Group = s;
+       GroupCombo->setCurrentText(s);
+       m_Group = s;
 }
 
 void InfoView::setBattles( std::vector<QString> battles )
 {
-    BattleCombo->clear();
-    
-    for (std::vector<QString>::iterator i = battles.begin(); i != battles.end(); ++i)
-    {
-       BattleCombo->insertItem(*i);
-    }
+       BattleCombo->clear();
+
+       for (std::vector<QString>::iterator i = battles.begin(); i != battles.end(); ++i)
+       {
+               BattleCombo->insertItem(*i);
+       }
 }
 
 void InfoView::setBattle( QString s )
 {
-    BattleCombo->setCurrentText(s);
-    m_Battle = s;
+       BattleCombo->setCurrentText(s);
+       m_Battle = s;
 }
 
 void InfoView::enableNameChange( bool b )
 {
-    NameLine->setReadOnly(!b);
+       NameLine->setReadOnly(!b);
 }
 
 void InfoView::enableRemove( bool b )
 {
-    RemoveButton->setEnabled(b);
+       RemoveButton->setEnabled(b);
 }
 
 void InfoView::ApplyButton_clicked()
 {
-    emit apply();
+       emit apply();
 }
 
 QString InfoView::battle()
 {
-    return BattleCombo->currentText();
+       return BattleCombo->currentText();
 }
 
 int InfoView::eta()
 {
-    return EtaSpin->value();
+       return EtaSpin->value();
 }
 
 QString InfoView::fleetName()
 {
-    return NameLine->text();
+       return NameLine->text();
 }
 
 QString InfoView::group()
 {
-    return GroupCombo->currentText();
+       return GroupCombo->currentText();
 }
 
 QString InfoView::race()
 {
-    return RaceCombo->currentText();
+       return RaceCombo->currentText();
 }
 
 void InfoView::slotNameChanged( const QString & s )
 {
-    if (s != "Home Planet" && m_Name == "Home Planet" && m_Group == "Friendly")
-    {
-       GroupCombo->setEnabled(true);
-       BattleCombo->setEnabled(true);
-       ApplyButton->setEnabled(false);
-       NewButton->setEnabled(true);
-    }
-    if (s == "Home Planet" && m_Name == "Home Planet" && m_Group == "Friendly")
-    {
-       GroupCombo->setEnabled(false);
-       GroupCombo->setCurrentText(m_Group);
-       BattleCombo->setEnabled(false);
-       BattleCombo->setCurrentText(m_Battle);
-       ApplyButton->setEnabled(true);
-       NewButton->setEnabled(false);
-    }
+       if (s != "Home Planet" && m_Name == "Home Planet" && m_Group == "Friendly")
+       {
+               GroupCombo->setEnabled(true);
+               BattleCombo->setEnabled(true);
+               ApplyButton->setEnabled(false);
+               NewButton->setEnabled(true);
+       }
+       if (s == "Home Planet" && m_Name == "Home Planet" && m_Group == "Friendly")
+       {
+               GroupCombo->setEnabled(false);
+               GroupCombo->setCurrentText(m_Group);
+               BattleCombo->setEnabled(false);
+               BattleCombo->setCurrentText(m_Battle);
+               ApplyButton->setEnabled(true);
+               NewButton->setEnabled(false);
+       }
 }
 
 
 int InfoView::stays()
 {
-    return StaySpin->value();
+       return StaySpin->value();
 }
 
 void InfoView::setStays( int ticks )
 {
-    StaySpin->setValue(ticks);
+       StaySpin->setValue(ticks);
 }