neil / rpms / anaconda

Forked from rpms/anaconda a year ago
Clone
765c7a
From 9efb90902967e207bdca8ac61ab92de54fbae9fe Mon Sep 17 00:00:00 2001
765c7a
From: Martin Kolman <mkolman@redhat.com>
765c7a
Date: Fri, 11 Sep 2020 15:27:59 +0200
765c7a
Subject: [PATCH 2/2] Fix CDN button visibility
765c7a
765c7a
Only show the Red Hat CDN button if the Subscription
765c7a
module appears to be running. To achieve that, we do
765c7a
the same thing as with the HMC button - the CDN
765c7a
button invisible by default. And enable it only if it
765c7a
looks like the Subscription module is running.
765c7a
765c7a
(cherry picked from commit: aca297587ab8bdd7342fa056273bfff379bc0a0b)
765c7a
765c7a
Resolves: rhbz#1903178
765c7a
765c7a
https://github.com/rhinstaller/anaconda/pull/3020
765c7a
https://github.com/M4rtinK/anaconda/commit/c29802a2be591a4cdcc91ba86b74fc4d01087b72
765c7a
---
765c7a
 pyanaconda/ui/gui/spokes/installation_source.glade | 2 +-
765c7a
 pyanaconda/ui/gui/spokes/installation_source.py    | 4 ++--
765c7a
 2 files changed, 3 insertions(+), 3 deletions(-)
765c7a
765c7a
diff --git a/pyanaconda/ui/gui/spokes/installation_source.glade b/pyanaconda/ui/gui/spokes/installation_source.glade
765c7a
index a23f8be714..e53fa230ca 100644
765c7a
--- a/pyanaconda/ui/gui/spokes/installation_source.glade
765c7a
+++ b/pyanaconda/ui/gui/spokes/installation_source.glade
765c7a
@@ -633,9 +633,9 @@
765c7a
                             <child>
765c7a
                               <object class="GtkRadioButton" id="cdnRadioButton">
765c7a
                                 <property name="label" translatable="yes" context="GUI|Software Source">Red Hat _CDN</property>
765c7a
-                                <property name="visible">True</property>
765c7a
                                 <property name="can_focus">True</property>
765c7a
                                 <property name="receives_default">False</property>
765c7a
+                                <property name="no_show_all">True</property>
765c7a
                                 <property name="margin_left">12</property>
765c7a
                                 <property name="use_underline">True</property>
765c7a
                                 <property name="xalign">0</property>
765c7a
diff --git a/pyanaconda/ui/gui/spokes/installation_source.py b/pyanaconda/ui/gui/spokes/installation_source.py
765c7a
index 6aab9b387a..d0d4da72b9 100644
765c7a
--- a/pyanaconda/ui/gui/spokes/installation_source.py
765c7a
+++ b/pyanaconda/ui/gui/spokes/installation_source.py
765c7a
@@ -854,9 +854,9 @@ class SourceSpoke(NormalSpoke, GUISpokeInputCheckHandler, SourceSwitchHandler):
765c7a
     def _initialize(self):
765c7a
         threadMgr.wait(constants.THREAD_PAYLOAD)
765c7a
 
765c7a
-        # If there is no Subscriptiopn DBus module, disable the CDN radio button
765c7a
+        # If there is the Subscriptiopn DBus module, make the CDN radio button visible
765c7a
         if is_module_available(SUBSCRIPTION):
765c7a
-            gtk_call_once(self._cdn_button.set_no_show_all, True)
765c7a
+            gtk_call_once(self._cdn_button.set_no_show_all, False)
765c7a
 
765c7a
         # Get the current source.
765c7a
         source_proxy = self.payload.get_source_proxy()
765c7a
-- 
765c7a
2.29.2
765c7a