mirror of
https://github.com/DYefremov/DemonEditor.git
synced 2025-12-21 16:09:41 +01:00
added prototype of playing current service
This commit is contained in:
@@ -134,6 +134,7 @@ class Application(Gtk.Application):
|
||||
"on_epg_list_configuration": self.on_epg_list_configuration,
|
||||
"on_iptv_list_configuration": self.on_iptv_list_configuration,
|
||||
"on_play_stream": self.on_play_stream,
|
||||
"on_play_current_service": self.on_play_current_service,
|
||||
"on_player_play": self.on_player_play,
|
||||
"on_player_stop": self.on_player_stop,
|
||||
"on_player_previous": self.on_player_previous,
|
||||
@@ -227,6 +228,7 @@ class Application(Gtk.Application):
|
||||
self._data_count_label = builder.get_object("data_count_label")
|
||||
self._save_header_button = builder.get_object("save_header_button")
|
||||
self._save_header_button.bind_property("sensitive", builder.get_object("save_menu_button"), "sensitive")
|
||||
self._signal_level_bar.bind_property("visible", builder.get_object("play_current_event_box"), "visible")
|
||||
# Force ctrl press event for view. Multiple selections in lists only with Space key(as in file managers)!!!
|
||||
self._services_view.connect("key-press-event", self.force_ctrl)
|
||||
self._fav_view.connect("key-press-event", self.force_ctrl)
|
||||
@@ -1540,6 +1542,10 @@ class Application(Gtk.Application):
|
||||
def on_play_stream(self, item=None):
|
||||
self.on_player_play()
|
||||
|
||||
def on_play_current_service(self, item, event):
|
||||
if event.button == Gdk.BUTTON_PRIMARY and event.type == Gdk.EventType.BUTTON_PRESS:
|
||||
self.on_watch()
|
||||
|
||||
@run_idle
|
||||
def on_player_play(self, item=None):
|
||||
path, column = self._fav_view.get_cursor()
|
||||
|
||||
@@ -2804,6 +2804,19 @@ Author: Dmitriy Yefremov
|
||||
<property name="can_focus">False</property>
|
||||
<property name="halign">start</property>
|
||||
<property name="margin_left">10</property>
|
||||
<property name="spacing">2</property>
|
||||
<child>
|
||||
<object class="GtkImage" id="info_image">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="stock">gtk-info</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="receiver_info_label">
|
||||
<property name="visible">True</property>
|
||||
@@ -2817,7 +2830,7 @@ Author: Dmitriy Yefremov
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">0</property>
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
@@ -2834,7 +2847,19 @@ Author: Dmitriy Yefremov
|
||||
<property name="halign">center</property>
|
||||
<property name="spacing">2</property>
|
||||
<child>
|
||||
<object class="GtkLabel" id="label2">
|
||||
<object class="GtkImage" id="ip_status_image">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="stock">gtk-connect</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="ip_status_label">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="halign">center</property>
|
||||
@@ -2846,7 +2871,7 @@ Author: Dmitriy Yefremov
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">0</property>
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
@@ -2861,7 +2886,7 @@ Author: Dmitriy Yefremov
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">1</property>
|
||||
<property name="position">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
@@ -2876,9 +2901,31 @@ Author: Dmitriy Yefremov
|
||||
<object class="GtkBox" id="signal_box">
|
||||
<property name="can_focus">False</property>
|
||||
<property name="halign">end</property>
|
||||
<property name="valign">center</property>
|
||||
<property name="margin_left">10</property>
|
||||
<property name="margin_right">10</property>
|
||||
<property name="spacing">5</property>
|
||||
<child>
|
||||
<object class="GtkEventBox" id="play_current_event_box">
|
||||
<property name="can_focus">False</property>
|
||||
<signal name="button-press-event" handler="on_play_current_service" swapped="no"/>
|
||||
<child>
|
||||
<object class="GtkImage" id="play_current_service_image">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="tooltip_text" translatable="yes">Play</property>
|
||||
<property name="halign">center</property>
|
||||
<property name="valign">center</property>
|
||||
<property name="stock">gtk-media-play</property>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="service_name_label">
|
||||
<property name="visible">True</property>
|
||||
|
||||
Reference in New Issue
Block a user