|
|
|
@ -17,6 +17,7 @@ WIDTH = 720 / 2
|
|
|
|
|
HEIGHT = 1440 / 2
|
|
|
|
|
BTN_HEIGHT = 40
|
|
|
|
|
SPACER_HEIGHT = 10
|
|
|
|
|
SCROLL_RATE = 5
|
|
|
|
|
|
|
|
|
|
BM_BTN_STYLE = wx.BOTTOM | wx.EXPAND | wx.LEFT | wx.TOP
|
|
|
|
|
BTN_STYLE = wx.BORDER_NONE | wx.BU_AUTODRAW | wx.BU_EXACTFIT | wx.BU_NOTEXT
|
|
|
|
@ -40,7 +41,7 @@ class Cast(wx.Frame):
|
|
|
|
|
self, -1, style=wx.VSCROLL
|
|
|
|
|
)
|
|
|
|
|
self.m_control = None
|
|
|
|
|
self.m_panel.SetupScrolling()
|
|
|
|
|
self.m_panel.SetupScrolling(rate_y=SCROLL_RATE,scrollToTop=True)
|
|
|
|
|
self.m_panel.SetSizer(self.m_sizer)
|
|
|
|
|
self.m_providers: list[ChannelProvider] = [
|
|
|
|
|
ChannelProvider(
|
|
|
|
@ -97,7 +98,7 @@ class Cast(wx.Frame):
|
|
|
|
|
self.m_sizer.Add(btn_sizer)
|
|
|
|
|
provider_index += 1
|
|
|
|
|
|
|
|
|
|
self.m_panel.SetupScrolling()
|
|
|
|
|
self.m_panel.SetupScrolling(rate_y=SCROLL_RATE,scrollToTop=True)
|
|
|
|
|
self.m_panel.SetSizer(self.m_sizer)
|
|
|
|
|
self.m_sizer.Fit(self)
|
|
|
|
|
self.m_sizer.Layout()
|
|
|
|
@ -118,7 +119,7 @@ class Cast(wx.Frame):
|
|
|
|
|
self.m_sizer.Add(btn_sizer)
|
|
|
|
|
channel_index += 1
|
|
|
|
|
|
|
|
|
|
self.m_panel.SetupScrolling()
|
|
|
|
|
self.m_panel.SetupScrolling(rate_y=SCROLL_RATE,scrollToTop=True)
|
|
|
|
|
self.m_panel.SetSizer(self.m_sizer)
|
|
|
|
|
self.m_sizer.Fit(self)
|
|
|
|
|
self.m_sizer.Layout()
|
|
|
|
@ -159,7 +160,7 @@ class Cast(wx.Frame):
|
|
|
|
|
self.m_sizer.Add(inner_sizer)
|
|
|
|
|
self.m_sizer.AddSpacer(SPACER_HEIGHT)
|
|
|
|
|
self.m_index = self.m_index + 1
|
|
|
|
|
self.m_panel.SetupScrolling()
|
|
|
|
|
self.m_panel.SetupScrolling(rate_y=SCROLL_RATE,scrollToTop=True)
|
|
|
|
|
self.m_panel.SetSizer(self.m_sizer)
|
|
|
|
|
self.m_sizer.Fit(self)
|
|
|
|
|
self.m_sizer.Layout()
|
|
|
|
@ -222,7 +223,7 @@ class Cast(wx.Frame):
|
|
|
|
|
|
|
|
|
|
self.Bind(wx.media.EVT_MEDIA_FINISHED, self.show_video_list)
|
|
|
|
|
self.load_uri(uri)
|
|
|
|
|
self.m_panel.SetupScrolling()
|
|
|
|
|
self.m_panel.SetupScrolling(rate_y=SCROLL_RATE,scrollToTop=True)
|
|
|
|
|
self.m_panel.SetSizer(self.m_sizer)
|
|
|
|
|
self.m_sizer.Fit(self)
|
|
|
|
|
self.m_sizer.Layout()
|
|
|
|
@ -249,7 +250,7 @@ class Cast(wx.Frame):
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
self.m_sizer.Add(btn)#, wx.ALIGN_CENTER_VERTICAL)
|
|
|
|
|
self.m_panel.SetupScrolling()
|
|
|
|
|
self.m_panel.SetupScrolling(rate_y=SCROLL_RATE,scrollToTop=True)
|
|
|
|
|
self.m_panel.SetSizer(self.m_sizer)
|
|
|
|
|
self.m_sizer.Fit(self)
|
|
|
|
|
self.m_sizer.Layout()
|
|
|
|
|