Index: libs/libmythtv/videosource.h
===================================================================
--- libs/libmythtv/videosource.h	(revision 12253)
+++ libs/libmythtv/videosource.h	(working copy)
@@ -588,7 +588,8 @@
 {
     Q_OBJECT
   public:
-    CardInput(bool is_dtv_card, bool is_dvb_card, int cardid);
+    CardInput(bool is_dtv_card, bool is_dvb_card,
+              bool is_new_input, int cardid);
     ~CardInput();
 
     int getInputID(void) const { return id->intValue(); };
@@ -605,7 +606,6 @@
   public slots:
     void channelScanner();
     void sourceFetch();
-    void diseqcConfig();
     void SetSourceID(const QString &sourceid);
 
   private:
Index: libs/libmythtv/cardutil.cpp
===================================================================
--- libs/libmythtv/cardutil.cpp	(revision 12253)
+++ libs/libmythtv/cardutil.cpp	(working copy)
@@ -766,7 +766,7 @@
     QStringList::iterator it = inputs.begin();
     for (; it != inputs.end(); ++it)
     {
-        CardInput* cardinput = new CardInput(is_dtv, false, cardid);
+        CardInput* cardinput = new CardInput(is_dtv, false, false, cardid);
         cardinput->loadByInput(rcardid, (*it));
         cardinput->SetChildCardID((parentid) ? cardid : 0);
         inputLabels.push_back(
@@ -787,7 +787,7 @@
         InputNames::const_iterator it;
         for (it = list.begin(); it != list.end(); ++it)
         {
-            CardInput *cardinput = new CardInput(is_dtv, true, rcardid);
+            CardInput *cardinput = new CardInput(is_dtv, true, false, rcardid);
             cardinput->loadByInput(rcardid, *it);
             cardinput->SetChildCardID(parentid ? cardid : 0);
             inputLabels.push_back(
@@ -799,7 +799,7 @@
         // plus add one "new" input
         if (needs_conf)
         {
-            CardInput *newcard = new CardInput(is_dtv, true, rcardid);
+            CardInput *newcard = new CardInput(is_dtv, true, true, rcardid);
             QString newname = QString("DVBInput #%1").arg(list.size() + 1);
             newcard->loadByInput(rcardid, newname);
             newcard->SetChildCardID((parentid) ? cardid : 0);
Index: libs/libmythtv/videosource.cpp
===================================================================
--- libs/libmythtv/videosource.cpp	(revision 12253)
+++ libs/libmythtv/videosource.cpp	(working copy)
@@ -1736,12 +1736,25 @@
     };
 };
 
-CardInput::CardInput(bool isDTVcard, bool isDVBcard, int _cardid) :
+CardInput::CardInput(bool isDTVcard,  bool isDVBcard,
+                     bool isNewInput, int _cardid) :
+    id(new ID()),
+    cardid(new CardID(*this)),
+    childid(),
+    inputname(new InputName(*this)),
+    sourceid(new SourceID(*this)),
+    startchan(new StartingChannel(*this)),
+    scan(new TransButtonSetting()),
+    srcfetch(new TransButtonSetting()),
     externalInputSettings(new DiSEqCDevSettings())
 {
-    (void) _cardid;
+    addChild(id);
 
-    addChild(id = new ID());
+    if (CardUtil::IsInNeedOfExternalInputConf(_cardid))
+    {
+        addChild(new DTVDeviceConfigGroup(*externalInputSettings,
+                                          _cardid, isNewInput));
+    }
 
     ConfigurationGroup *group =
         new VerticalConfigurationGroup(false, false, true, true);
@@ -1750,11 +1763,11 @@
 
     HorizontalConfigurationGroup *ci;
     ci = new HorizontalConfigurationGroup(false, false);
-    ci->addChild(cardid = new CardID(*this));
-    ci->addChild(inputname = new InputName(*this));
+    ci->addChild(cardid);
+    ci->addChild(inputname);
     group->addChild(ci);
     group->addChild(new InputDisplayName(*this));
-    group->addChild(sourceid = new SourceID(*this));
+    group->addChild(sourceid);
     if (!isDVBcard)
     {
         group->addChild(new ExternalChannelCommand(*this));
@@ -1770,30 +1783,19 @@
         group->addChild(chgroup);
     }
 
-#ifdef USING_DVB
     if (isDVBcard)
     {
-        TransButtonSetting *diseqc = new TransButtonSetting();
-        diseqc->setLabel(tr("DVB-S"));
-        diseqc->setHelpText(tr("Input and satellite settings."));
-        diseqc->setVisible(CardUtil::IsInNeedOfExternalInputConf(_cardid));
-        group->addChild(diseqc);
-        connect(diseqc, SIGNAL(pressed()), SLOT(diseqcConfig()));
-   
         ConfigurationGroup *chgroup = 
             new HorizontalConfigurationGroup(false, false, true, true);
         chgroup->addChild(new RadioServices(*this));
         chgroup->addChild(new DishNetEIT(*this));
         group->addChild(chgroup);
     }
-#endif
 
-    scan = new TransButtonSetting();
     scan->setLabel(tr("Scan for channels"));
     scan->setHelpText(
         tr("Use channel scanner to find channels for this input."));
 
-    srcfetch = new TransButtonSetting();
     srcfetch->setLabel(tr("Fetch channels from listings source"));
     srcfetch->setHelpText(
         tr("This uses the listings data source to "
@@ -1806,7 +1808,6 @@
     sgrp->addChild(srcfetch);
     group->addChild(sgrp);
 
-    startchan = new StartingChannel(*this);
     group->addChild(startchan);
     group->addChild(new InputPriority(*this));
 
@@ -1922,15 +1923,6 @@
     }
 }
 
-void CardInput::diseqcConfig(void)
-{
-#ifdef USING_DVB
-    DTVDeviceConfigWizard wizard(*externalInputSettings,
-                                 cardid->getValue().toUInt());
-    wizard.exec();
-#endif // USING_DVB
-}
-
 QString CardInputDBStorage::whereClause(MSqlBindings& bindings) 
 {
     QString cardinputidTag(":WHERECARDINPUTID");
Index: libs/libmythtv/diseqcsettings.cpp
===================================================================
--- libs/libmythtv/diseqcsettings.cpp	(revision 12253)
+++ libs/libmythtv/diseqcsettings.cpp	(working copy)
@@ -356,8 +356,20 @@
     return str;
 }
 
-static double AngleToFloat(const QString &angle)
+static double AngleToEdit(double angle, QString &hemi)
 {
+    if (angle > 0.0)
+    {
+        hemi = "E";
+        return angle;
+    }
+
+    hemi = "W";
+    return -angle;
+}
+
+static double AngleToFloat(const QString &angle, bool translated = true)
+{
     if (angle.length() < 2)
         return 0.0;
 
@@ -366,8 +378,12 @@
     if (postfix.isLetter())
     {
         pos = angle.left(angle.length() - 1).toDouble();
-        if (postfix.upper() == DeviceTree::tr("W", "Western Hemisphere"))
+        if ((translated &&
+             (postfix.upper() == DeviceTree::tr("W", "Western Hemisphere"))) ||
+            (!translated && (postfix.upper() == "W")))
+        {
             pos = -pos;
+        }
     }
     else
         pos = angle.toDouble();
@@ -1163,63 +1179,79 @@
 
 //////////////////////////////////////// USALSRotorSetting
 
-class USALSRotorSetting : public LineEditSetting, public Storage
+class USALSRotorSetting : public HorizontalConfigurationGroup
 {
   public:
     USALSRotorSetting(DiSEqCDevDevice &node, DiSEqCDevSettings &settings) :
-        LineEditSetting(this), m_node(node), m_settings(settings)
+        HorizontalConfigurationGroup(false, false, true, true),
+        numeric(new TransLineEditSetting()),
+        hemisphere(new TransComboBoxSetting(false)),
+        m_node(node), m_settings(settings)
     {
-        setLabel(node.GetDescription());
-        QString help = DeviceTree::tr(
-            "The longitude of the satellite you are aiming at, in degrees. "
-            "In the Western hemisphere use 'W' as the suffix. "
-            "In the Eastern hemisphere use 'E' as the suffix. ");
-        setHelpText(help);
+        QString help =
+            DeviceTree::tr(
+                "Locates the satelite you wish to point to "
+                "with the longitude along the Clarke Belt of"
+                "the satellite [-180..180] and its hemisphere.");
+
+        numeric->setLabel(DeviceTree::tr("Longitude (degrees)"));
+        numeric->setHelpText(help);
+        hemisphere->setLabel(DeviceTree::tr("Hemisphere"));
+        hemisphere->addSelection(DeviceTree::tr("Eastern"), "E", false);
+        hemisphere->addSelection(DeviceTree::tr("Western"), "W", true);
+        hemisphere->setHelpText(help);
+
+        addChild(numeric);
+        addChild(hemisphere);
     }
 
     virtual void load(void)
     {
-        setValue(AngleToString(m_settings.GetValue(m_node.GetDeviceID())));
+        double  val  = m_settings.GetValue(m_node.GetDeviceID());
+        QString hemi = QString::null;
+        double  eval = AngleToEdit(val, hemi);
+        numeric->setValue(QString::number(eval));
+        hemisphere->setValue(hemisphere->getValueIndex(hemi));
     }
 
     virtual void save(void)
     {
-        m_settings.SetValue(m_node.GetDeviceID(), AngleToFloat(getValue()));
+        QString val = QString::number(numeric->getValue().toDouble());
+        val += hemisphere->getValue();
+        m_settings.SetValue(m_node.GetDeviceID(), AngleToFloat(val, false));
     }
 
     virtual void save(QString /*destination*/) { }
 
   private:
-    DiSEqCDevDevice   &m_node;
-    DiSEqCDevSettings &m_settings;
+    TransLineEditSetting *numeric;
+    TransComboBoxSetting *hemisphere;
+    DiSEqCDevDevice      &m_node;
+    DiSEqCDevSettings    &m_settings;
 };
 
-//////////////////////////////////////// DTVDeviceConfigWizard
+//////////////////////////////////////// DTVDeviceConfigGroup
 
-DTVDeviceConfigWizard::DTVDeviceConfigWizard(DiSEqCDevSettings &settings,
-                                             uint cardid)
-    : m_settings(settings)
+DTVDeviceConfigGroup::DTVDeviceConfigGroup(
+    DiSEqCDevSettings &settings, uint cardid, bool switches_enabled) :
+    VerticalConfigurationGroup(false, false, true, true),
+    m_settings(settings), m_switches_enabled(switches_enabled)
 {
-    ConfigurationGroup *group =
-        new VerticalConfigurationGroup(false, false);
-    group->setLabel(DeviceTree::tr("DTV Device Configuration"));
+    setLabel(DeviceTree::tr("DTV Device Configuration"));
 
     // load
     m_tree.Load(cardid);
 
     // initial UI setup
-    AddNodes(*group, m_tree.Root());
-    SelectNodes();
-
-    addChild(group);
+    AddNodes(this, QString::null, m_tree.Root());
 }
 
-DTVDeviceConfigWizard::~DTVDeviceConfigWizard(void)
+DTVDeviceConfigGroup::~DTVDeviceConfigGroup(void)
 {
 }
 
-void DTVDeviceConfigWizard::AddNodes(ConfigurationGroup &group,
-                                     DiSEqCDevDevice    *node)
+void DTVDeviceConfigGroup::AddNodes(
+    ConfigurationGroup *group, const QString &trigger, DiSEqCDevDevice *node)
 {
     if (!node)
         return;
@@ -1229,8 +1261,7 @@
     {
         case DiSEqCDevDevice::kTypeSwitch:
             setting = new SwitchSetting(*node, m_settings);
-            connect(setting, SIGNAL(valueChanged(const QString&)),
-                    SLOT(SelectNodes()));
+            setting->setEnabled(m_switches_enabled);
             break;
         case DiSEqCDevDevice::kTypeRotor:
         {
@@ -1245,36 +1276,60 @@
             break;
     }
 
-    if (setting)
+    if (!setting)
     {
-        // add this node
-        m_devs[node->GetDeviceID()] = setting;
-        group.addChild(setting);
+        AddChild(group, trigger, new TransLabelSetting());
+        return;
     }
 
-    // add children
+    m_devs[node->GetDeviceID()] = setting;
+
     uint num_ch = node->GetChildCount();
-    for (uint ch = 0; ch < num_ch; ch++)
-        AddNodes(group, node->GetChild(ch));
-}
+    if (DiSEqCDevDevice::kTypeSwitch == node->GetDeviceType())
+    {
+        bool useframe = (node != m_tree.Root());
+        bool zerospace = !useframe;
+        TriggeredConfigurationGroup *cgrp = new TriggeredConfigurationGroup(
+            false, useframe, true, true, false, false, true, zerospace);
 
-void DTVDeviceConfigWizard::SelectNodes(void)
-{
-    ConfigurationWizard::save();
+        cgrp->addChild(setting);
+        cgrp->setTrigger(setting);
 
-    QMap<uint,bool> active;
-    DiSEqCDevDevice *node = m_tree.Root();
-    while (node)
+        for (uint i = 0; i < num_ch; i++)
+            AddNodes(cgrp, QString::number(i), node->GetChild(i));
+
+        AddChild(group, trigger, cgrp);
+        return;
+    }
+
+    if (!num_ch)
     {
-        active[node->GetDeviceID()] = true;
-        node = node->GetSelectedChild(m_settings);
+        AddChild(group, trigger, setting);
+        return;
     }
 
-    devid_to_setting_t::iterator it = m_devs.begin();
-    for (; it != m_devs.end(); ++it)
-        (*it)->setEnabled(active[it.key()]);
+    VerticalConfigurationGroup *cgrp =
+        new VerticalConfigurationGroup(false, false, true, true);
+
+    AddChild(cgrp, QString::null, setting);
+    for (uint i = 0; i < num_ch; i++)
+        AddNodes(cgrp, QString::null, node->GetChild(i));
+
+    AddChild(group, trigger, cgrp);
 }
 
+void DTVDeviceConfigGroup::AddChild(
+    ConfigurationGroup *group, const QString &trigger, Setting *setting)
+{
+    TriggeredConfigurationGroup *grp =
+        dynamic_cast<TriggeredConfigurationGroup*>(group);
+
+    if (grp && !trigger.isEmpty())
+        grp->addTarget(trigger, setting);
+    else
+        group->addChild(setting);
+}
+
 //////////////////////////////////////// Database Upgrade
 
 enum OLD_DISEQC_TYPES
Index: libs/libmythtv/diseqcsettings.h
===================================================================
--- libs/libmythtv/diseqcsettings.h	(revision 12253)
+++ libs/libmythtv/diseqcsettings.h	(working copy)
@@ -133,24 +133,25 @@
     virtual int exec(void);
 };
 
-class DTVDeviceConfigWizard : public QObject, public ConfigurationWizard
+class DTVDeviceConfigGroup : public VerticalConfigurationGroup
 {
-    Q_OBJECT
-
   public:
-    DTVDeviceConfigWizard(DiSEqCDevSettings &settings, uint cardid);
-    ~DTVDeviceConfigWizard(void);
+    DTVDeviceConfigGroup(DiSEqCDevSettings &settings, uint cardid,
+                         bool switches_enabled);
+    ~DTVDeviceConfigGroup(void);
     
-  public slots:
-    void SelectNodes(void);
-  
   protected:
-    void AddNodes(ConfigurationGroup &group, DiSEqCDevDevice *node);
+    void AddNodes(ConfigurationGroup *group, const QString &trigger,
+                  DiSEqCDevDevice *node);
+
+    void AddChild(ConfigurationGroup *group, const QString &trigger,
+                  Setting *setting);
     
   private:
     DiSEqCDevTree       m_tree;
     DiSEqCDevSettings  &m_settings;
     devid_to_setting_t  m_devs;
+    bool                m_switches_enabled;
 };
 
 #endif // _DISEQCSETTINGS_H_
