Skip to content

Commit 0d40de0

Browse files
author
Dr.Best
committed
update some missing plugin icons (and some minor cleanups)
1 parent eddd59f commit 0d40de0

File tree

12 files changed

+114
-76
lines changed

12 files changed

+114
-76
lines changed

dreamirc/src/Makefile.am

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ installdir = $(libdir)/enigma2/python/Plugins/Extensions/dreamIRC
22

33
install_PYTHON = *.py
44

5-
install_DATA = *.xml LICENSE
5+
install_DATA = *.xml plugin.png LICENSE
66

77
SUBDIRS = protocols
88

dreamirc/src/plugin.png

7.07 KB
Loading

filebrowser/src/Makefile.am

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
installdir = $(libdir)/enigma2/python/Plugins/Extensions/Filebrowser
22

33
install_PYTHON = __init__.py plugin.py
4-
install_DATA = maintainer.info LICENSE
4+
install_DATA = maintainer.info LICENSE filebrowser.svg

filebrowser/src/filebrowser.svg

Lines changed: 1 addition & 0 deletions
Loading

filebrowser/src/plugin.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -348,7 +348,7 @@ def start_from_pluginmenu(session,**kwargs):
348348

349349
def Plugins(path,**kwargs):
350350
desc_mainmenu = PluginDescriptor(name=pname, description=pdesc, where = PluginDescriptor.WHERE_MENU, fnc = start_from_mainmenu)
351-
desc_pluginmenu = PluginDescriptor(name=pname, description=pdesc, where = PluginDescriptor.WHERE_PLUGINMENU, fnc = start_from_pluginmenu)
351+
desc_pluginmenu = PluginDescriptor(name=pname, description=pdesc, where = PluginDescriptor.WHERE_PLUGINMENU,icon = "filebrowser.svg", fnc = start_from_pluginmenu)
352352
desc_extensionmenu = PluginDescriptor(name=pname, description=pdesc, where = PluginDescriptor.WHERE_EXTENSIONSMENU, fnc = start_from_pluginmenu)
353353
desc_filescan = PluginDescriptor(name=pname, where = PluginDescriptor.WHERE_FILESCAN, fnc = start_from_filescan)
354354
list = []

ftpbrowser/src/FTPBrowser.py

Lines changed: 40 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
from __future__ import print_function
22

33
# Core
4-
from enigma import RT_HALIGN_LEFT, eListboxPythonMultiContent
4+
from enigma import RT_HALIGN_LEFT, RT_VALIGN_CENTER, getDesktop, eListboxPythonMultiContent
55

66
# Tools
7-
from Tools.Directories import SCOPE_SKIN_IMAGE, resolveFilename
7+
from Tools.Directories import SCOPE_SKIN_IMAGE, SCOPE_CURRENT_SKIN, resolveFilename
88
from Tools.LoadPixmap import LoadPixmap
99
from Tools.Notifications import AddPopup, AddNotificationWithCallback
1010

@@ -23,6 +23,7 @@
2323
from Components.FileList import FileList, FileEntryComponent, EXTENSIONS
2424
from Components.Sources.StaticText import StaticText
2525
from VariableProgressSource import VariableProgressSource
26+
from skin import componentSizes
2627

2728
# FTP Client
2829
from twisted.internet import reactor, defer
@@ -37,6 +38,14 @@
3738
import re
3839

3940
def FTPFileEntryComponent(file, directory):
41+
sizes = componentSizes[componentSizes.FILE_LIST]
42+
tx = sizes.get("textX", 35)
43+
ty = sizes.get("textY", 0)
44+
tw = sizes.get("textWidth", 1000)
45+
th = sizes.get("textHeight", 25)
46+
pxw = sizes.get("pixmapWidth", 20)
47+
pxh = sizes.get("pixmapHeight", 20)
48+
4049
isDir = True if file['filetype'] == 'd' else False
4150
name = file['filename']
4251
absolute = directory + name
@@ -45,10 +54,10 @@ def FTPFileEntryComponent(file, directory):
4554

4655
res = [
4756
(absolute, isDir, file['size']),
48-
(eListboxPythonMultiContent.TYPE_TEXT, 35, 1, 470, 20, 0, RT_HALIGN_LEFT, name)
57+
(eListboxPythonMultiContent.TYPE_TEXT, tx, ty, tw, th, 0, RT_HALIGN_LEFT|RT_VALIGN_CENTER, name)
4958
]
5059
if isDir:
51-
png = LoadPixmap(resolveFilename(SCOPE_SKIN_IMAGE, "extensions/directory.png"))
60+
png = LoadPixmap(resolveFilename(SCOPE_CURRENT_SKIN, "extensions/directory.png"))
5261
else:
5362
extension = name.split('.')
5463
extension = extension[-1].lower()
@@ -57,7 +66,7 @@ def FTPFileEntryComponent(file, directory):
5766
else:
5867
png = None
5968
if png is not None:
60-
res.append((eListboxPythonMultiContent.TYPE_PIXMAP_ALPHATEST, 10, 2, 20, 20, png))
69+
res.append((eListboxPythonMultiContent.TYPE_PIXMAP_ALPHATEST, 10, (th-pxh)/2, pxw, pxh, png))
6170

6271
return res
6372

@@ -132,23 +141,32 @@ def listFailed(self, *args):
132141

133142
class FTPBrowser(Screen, Protocol, InfoBarNotifications, HelpableScreen):
134143
skin = """
135-
<screen name="FTPBrowser" position="center,center" size="600,440" title="FTP Browser">
136-
<ePixmap position="0,0" size="140,40" pixmap="skin_default/buttons/red.png" transparent="1" alphatest="on" />
137-
<ePixmap position="140,0" size="140,40" pixmap="skin_default/buttons/green.png" transparent="1" alphatest="on" />
138-
<ePixmap position="280,0" size="140,40" pixmap="skin_default/buttons/yellow.png" transparent="1" alphatest="on" />
139-
<ePixmap position="420,0" size="140,40" pixmap="skin_default/buttons/blue.png" transparent="1" alphatest="on" />
140-
<ePixmap position="565,10" size="35,25" pixmap="skin_default/buttons/key_menu.png" alphatest="on" />
141-
<widget source="key_red" render="Label" position="0,0" zPosition="1" size="140,40" valign="center" halign="center" font="Regular;21" transparent="1" foregroundColor="white" shadowColor="black" shadowOffset="-1,-1" />
142-
<widget source="key_green" render="Label" position="140,0" zPosition="1" size="140,40" valign="center" halign="center" font="Regular;21" transparent="1" foregroundColor="white" shadowColor="black" shadowOffset="-1,-1" />
143-
<widget source="key_yellow" render="Label" position="280,0" zPosition="1" size="140,40" valign="center" halign="center" font="Regular;21" transparent="1" foregroundColor="white" shadowColor="black" shadowOffset="-1,-1" />
144-
<widget source="key_blue" render="Label" position="420,0" zPosition="1" size="140,40" valign="center" halign="center" font="Regular;21" transparent="1" foregroundColor="white" shadowColor="black" shadowOffset="-1,-1" />
145-
<widget source="localText" render="Label" position="10,50" size="200,20" font="Regular;18" />
146-
<widget name="local" position="10,80" size="290,320" scrollbarMode="showOnDemand" />
147-
<widget source="remoteText" render="Label" position="300,50" size="200,20" font="Regular;18" />
148-
<widget name="remote" position="300,80" size="290,320" scrollbarMode="showOnDemand" />
149-
<widget source="eta" render="Label" position="20,410" size="200,30" font="Regular;23" />
150-
<widget source="speed" render="Label" position="380,410" size="200,30" halign="right" font="Regular;23" />
151-
<widget source="progress" render="Progress" position="20,440" size="560,10" />
144+
<screen name="FTPBrowser" position="center,80" size="1200,610" title="FTP Browser">
145+
<ePixmap pixmap="skin_default/buttons/red.png" position="10,5" size="200,40" />
146+
<ePixmap pixmap="skin_default/buttons/green.png" position="210,5" size="200,40" />
147+
<ePixmap pixmap="skin_default/buttons/yellow.png" position="410,5" size="200,40" />
148+
<ePixmap pixmap="skin_default/buttons/blue.png" position="610,5" size="200,40" />
149+
<widget source="key_red" render="Label" position="10,5" size="200,40" zPosition="1" font="Regular;20" halign="center" valign="center" backgroundColor="#9f1313" transparent="1" foregroundColor="white" shadowColor="black" shadowOffset="-2,-2" />
150+
<widget source="key_green" render="Label" position="210,5" size="200,40" zPosition="1" font="Regular;20" halign="center" valign="center" backgroundColor="#1f771f" transparent="1" foregroundColor="white" shadowColor="black" shadowOffset="-2,-2" />
151+
<widget source="key_yellow" render="Label" position="410,5" size="200,40" zPosition="1" font="Regular;20" halign="center" valign="center" backgroundColor="#a08500" transparent="1" foregroundColor="white" shadowColor="black" shadowOffset="-2,-2" />
152+
<widget source="key_blue" render="Label" position="610,5" size="200,40" zPosition="1" font="Regular;20" halign="center" valign="center" backgroundColor="#18188b" transparent="1" foregroundColor="white" shadowColor="black" shadowOffset="-2,-2" />
153+
<widget source="global.CurrentTime" render="Label" position="1130,12" size="60,25" font="Regular;22" halign="right">
154+
<convert type="ClockToText">Default</convert>
155+
</widget>
156+
<widget source="global.CurrentTime" render="Label" position="820,12" size="300,25" font="Regular;22" halign="right">
157+
<convert type="ClockToText">Format:%A %d. %B</convert>
158+
</widget>
159+
<eLabel position="10,50" size="1180,1" backgroundColor="grey" />
160+
<widget source="localText" foregroundColor="yellow" render="Label" position="20,55" size="500,30" font="Regular;24" />
161+
<widget name="local" position="20,90" size="580,450" enableWrapAround="1" scrollbarMode="showOnDemand" />
162+
<widget source="remoteText" foregroundColor="yellow" render="Label" position="610,55" size="500,30" font="Regular;24" />
163+
<widget name="remote" position="610,90" size="580,450" enableWrapAround="1" scrollbarMode="showOnDemand" />
164+
<eLabel backgroundColor="grey" position="604,60" size="2,480" />
165+
<eLabel position="10,550" size="1180,1" backgroundColor="grey" />
166+
<widget source="eta" render="Label" position="20,560" size="300,30" font="Regular;22" />
167+
<widget source="speed" render="Label" position="350,560" size="300,30" font="Regular;22" />
168+
<widget source="progress" render="Progress" position="20,590" size="650,10" />
169+
<ePixmap pixmap="skin_default/icons/menu.png" position="1130,575" size="60,30" />
152170
</screen>"""
153171

154172
def __init__(self, session):

0 commit comments

Comments
 (0)