widgets/choice_radio: improve style

parent 9dfbac49
...@@ -4,8 +4,10 @@ from .BaseWidget import BaseWidget ...@@ -4,8 +4,10 @@ from .BaseWidget import BaseWidget
class RadioChoiceWidget(BaseWidget): class RadioChoiceWidget(BaseWidget):
def create_row(self): def create_row(self):
main_box = Adw.PreferencesRow() self.row = Adw.PreferencesRow(
self.row = main_box activatable=False,
focusable=False
)
content_box = Gtk.Box( content_box = Gtk.Box(
orientation=Gtk.Orientation.VERTICAL, orientation=Gtk.Orientation.VERTICAL,
...@@ -15,7 +17,7 @@ class RadioChoiceWidget(BaseWidget): ...@@ -15,7 +17,7 @@ class RadioChoiceWidget(BaseWidget):
margin_start=12, margin_start=12,
margin_end=12 margin_end=12
) )
main_box.set_child(content_box) self.row.set_child(content_box)
title_horizontal_box = Gtk.Box( title_horizontal_box = Gtk.Box(
orientation=Gtk.Orientation.HORIZONTAL, orientation=Gtk.Orientation.HORIZONTAL,
...@@ -90,7 +92,6 @@ class RadioChoiceWidget(BaseWidget): ...@@ -90,7 +92,6 @@ class RadioChoiceWidget(BaseWidget):
halign=Gtk.Align.START, halign=Gtk.Align.START,
active=(value == current_value) active=(value == current_value)
) )
radio.add_css_class("selection-mode")
if group: if group:
radio.set_group(group) radio.set_group(group)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment