* remove toggle_source_view plugin and related command implementations * drop built-in sibling focus/move commands from core * simplify EditorsContainer (Paned → Box) and editor initialization * refactor source view creation to return (scrolled_window, source_view) * add source view lifecycle events (remove/removed) * rename GetNewCommandSystemEvent → CreateCommandSystemEvent * update CommandsController to handle command system creation and cleanup * ensure command systems are removed with their source views * improve focus border handling across sibling chains * clean up imports to use absolute core.* paths * update keybindings to remove deprecated split navigation commands
48 lines
1.1 KiB
Python
48 lines
1.1 KiB
Python
# Python imports
|
|
|
|
# Lib imports
|
|
import gi
|
|
gi.require_version('Gtk', '3.0')
|
|
from gi.repository import Gtk
|
|
|
|
# Application imports
|
|
from core.widgets.separator_widget import Separator
|
|
|
|
from .code.code_container import CodeContainer
|
|
|
|
|
|
|
|
class LeftContainer(Gtk.Box):
|
|
def __init__(self):
|
|
super(LeftContainer, self).__init__()
|
|
|
|
self._setup_styling()
|
|
self._setup_signals()
|
|
self._subscribe_to_events()
|
|
|
|
self.show()
|
|
|
|
|
|
def _setup_styling(self):
|
|
self.ctx = self.get_style_context()
|
|
self.ctx.add_class("left-container")
|
|
|
|
self.set_orientation(Gtk.Orientation.HORIZONTAL)
|
|
self.set_vexpand(True)
|
|
|
|
def _setup_signals(self):
|
|
self.connect("show", self._handle_show)
|
|
|
|
def _subscribe_to_events(self):
|
|
...
|
|
|
|
def _handle_show(self, widget):
|
|
self.disconnect_by_func( self._handle_show )
|
|
self._load_widgets()
|
|
|
|
def _load_widgets(self):
|
|
widget_registery.expose_object("left-container", self)
|
|
|
|
self.add( Separator("separator-left", 1) )
|
|
self.add( CodeContainer() )
|