Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'e2/master'
- Loading branch information
Showing
29 changed files
with
477 additions
and
365 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Description: ChannelSelectionShortTitle Converter | ||
Depends: enigma2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
SUBDIRS = src |
39 changes: 39 additions & 0 deletions
39
channelselectionshorttitle/src/ChannelSelectionShortTitle.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
# | ||
# ChannelSelectionShortTitle - Converter | ||
# | ||
# Coded by Dr.Best (c) 2013 | ||
# Support: www.dreambox-tools.info | ||
# E-Mail: dr.best@dreambox-tools.info | ||
# | ||
# This plugin is open source but it is NOT free software. | ||
# | ||
# This plugin may only be distributed to and executed on hardware which | ||
# is licensed by Dream Multimedia GmbH. | ||
# In other words: | ||
# It's NOT allowed to distribute any parts of this plugin or its source code in ANY way | ||
# to hardware which is NOT licensed by Dream Multimedia GmbH. | ||
# It's NOT allowed to execute this plugin and its source code or even parts of it in ANY way | ||
# on hardware which is NOT licensed by Dream Multimedia GmbH. | ||
# | ||
# If you want to use or modify the code or parts of it, | ||
# you have to keep MY license and inform me about the modifications by mail. | ||
# | ||
|
||
from Components.Converter.Converter import Converter | ||
from Components.Element import cached | ||
from Components.config import config | ||
|
||
class ChannelSelectionShortTitle(Converter, object): | ||
def __init__(self, type): | ||
Converter.__init__(self, type) | ||
|
||
@cached | ||
def getText(self): | ||
title = self.source.text | ||
t = " (%s) " % config.servicelist.lastmode.value.upper() | ||
pos = title.find(t) | ||
if pos != -1: | ||
title = title[pos+len(t):] | ||
return title | ||
|
||
text = property(getText) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
installdir = $(libdir)/enigma2/python/Plugins/SkinComponents/ChannelSelectionShortTitle | ||
converterinstalldir = $(libdir)/enigma2/python/Components/Converter | ||
install_DATA = README | ||
converterinstall_PYTHON = ChannelSelectionShortTitle.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
Description: ChannelSelectionShortTitle Converter | ||
This converter truncates the original title of ChannelSelection --> "title (MODE)" will be cut off | ||
|
||
Usage: | ||
<widget backgroundColor="secondBG" font="Regular;24" position="70,5" render="Label" size="850,80" source="Title" transparent="1" valign="center" zPosition="1"> | ||
<convert type="ChannelSelectionShortTitle"/> | ||
</widget> | ||
|
||
|
||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Description: EventPosition Converter using ePositionGauge for event data | ||
Depends: enigma2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
SUBDIRS = src |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
# -*- coding: utf-8 -*- | ||
# | ||
# EventPosition - Converter | ||
# | ||
# Coded by Dr.Best (c) 2013 | ||
# Support: www.dreambox-tools.info | ||
# E-Mail: dr.best@dreambox-tools.info | ||
# | ||
# This plugin is open source but it is NOT free software. | ||
# | ||
# This plugin may only be distributed to and executed on hardware which | ||
# is licensed by Dream Multimedia GmbH. | ||
# In other words: | ||
# It's NOT allowed to distribute any parts of this plugin or its source code in ANY way | ||
# to hardware which is NOT licensed by Dream Multimedia GmbH. | ||
# It's NOT allowed to execute this plugin and its source code or even parts of it in ANY way | ||
# on hardware which is NOT licensed by Dream Multimedia GmbH. | ||
# | ||
# If you want to use or modify the code or parts of it, | ||
# you have to keep MY license and inform me about the modifications by mail. | ||
# | ||
|
||
from Converter import Converter | ||
from Poll import Poll | ||
from Components.Element import cached | ||
from time import time | ||
|
||
class EventPosition(Poll, Converter, object): | ||
def __init__(self, type): | ||
Poll.__init__(self) | ||
Converter.__init__(self, type) | ||
self.poll_interval = 30*1000 | ||
self.poll_enabled = True | ||
|
||
@cached | ||
def getPosition(self): | ||
event = self.source.event | ||
if event is None: | ||
return None | ||
now = int(time()) | ||
start_time = event.getBeginTime() | ||
duration = event.getDuration() | ||
if start_time <= now <= (start_time + duration) and duration > 0: | ||
return now - start_time | ||
else: | ||
return 0 | ||
|
||
@cached | ||
def getLength(self): | ||
event = self.source.event | ||
if event is None: | ||
return None | ||
return event.getDuration() | ||
|
||
@cached | ||
def getCutlist(self): | ||
return [] | ||
|
||
|
||
position = property(getPosition) | ||
length = property(getLength) | ||
cutlist = property(getCutlist) | ||
|
||
|
||
def changed(self, what): | ||
if what[0] != self.CHANGED_CLEAR: | ||
self.downstream_elements.changed(what) | ||
if len(self.downstream_elements): | ||
if not self.source.event and self.downstream_elements[0].visible: | ||
self.downstream_elements[0].visible = False | ||
elif self.source.event and not self.downstream_elements[0].visible: | ||
self.downstream_elements[0].visible = True |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
installdir = $(libdir)/enigma2/python/Plugins/SkinComponents/EventPosition | ||
converterinstalldir = $(libdir)/enigma2/python/Components/Converter | ||
install_DATA = README | ||
converterinstall_PYTHON = EventPosition.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
Description: EventPosition Converter using ePositionGauge for event data | ||
|
||
Usage example: | ||
|
||
<widget pointer="Vali.HD.warp/shinybar.png:8,5" position="235,566" size="100,12" render="PositionGauge" source="session.Event_Now" transparent="1" zPosition="1"> | ||
<convert type="EventPosition"/> | ||
</widget> | ||
|
||
|
||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
from __init__ import _ | ||
Version = "V2.9r0" | ||
Version = "V2.9r2" | ||
# globale Variablen | ||
ZielRPM = 0 | ||
AktVLT = 0 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.