Jump to content


Photo

ChannelSelection modifications


  • Please log in to reply
229 replies to this topic

#1 Dimitrij

  • PLi® Core member
  • 10,328 posts

+350
Excellent

Posted 25 February 2012 - 11:36

Step 1.
Multi language title (thank ims)

GigaBlue UHD Quad 4K /Lunix3-4K/Duo 4K


Re: ChannelSelection modifications #2 Taykun345

  • Senior Member
  • 1,297 posts

+41
Good

Posted 25 February 2012 - 11:46

Whats the purpose of this? We can translate Channel Selection or ?
Army MoodBlue HD skin modification by me: https://github.com/T...-MoodBlueHD-mod
Matrix10 MH-HD2 skin modification by me: https://github.com/B...-MX-HD2-OpenPli
MetrixHD skin modification by me: https://github.com/T...xHD-WPstyle-mod
Slovenian translation for OpenPLi E2: https://github.com/T...ion-for-OpenPLi

Re: ChannelSelection modifications #3 ims

  • PLi® Core member
  • 13,785 posts

+214
Excellent

Posted 25 February 2012 - 12:05

Yes. If you have there in .po file strings: "Channel selection" and "User - bouquets" and are translated, then you will have there in channel selection translated this 2 strings.
Kdo nic nedělá, nic nezkazí!

Re: ChannelSelection modifications #4 Dimitrij

  • PLi® Core member
  • 10,328 posts

+350
Excellent

Posted 10 March 2012 - 10:09

Step 2 and 3 and 4
- startup service after leaving standby mode
-services count
-add HD-channels list
P.S.As always, thanks for the help vlamo

GigaBlue UHD Quad 4K /Lunix3-4K/Duo 4K


Re: ChannelSelection modifications #5 MartiniB

  • Senior Member
  • 49 posts

0
Neutral

Posted 20 March 2012 - 22:13

fantastic!
option `services count` have missed for long years sinc moved from E1 dream to E2 dream

can devolopers search some other way implement this important feature dirrectly into Enigma2 cause trough python it is so slow -
on every time presing green key have to wait 9 seconds (red key spends 4sec)

Step5
- change path separator in title for easyer reading
if end_ref is not None:
	 if Len > 2:
# -	  titleStr += '/../'
# +
	  titleStr += ' \xbb..\xbb '
# + END
	 else:
# -	  titleStr += '/'
# +
	  titleStr += ' \xbb '
# + END

Step6
- feat request: change location(order) of "Current transponder" to top or botomn

Re: ChannelSelection modifications #6 MartiniB

  • Senior Member
  • 49 posts

0
Neutral

Posted 21 March 2012 - 22:13

have add feature which will count only selected Folder's types
in case i have large services list will leave only for `*** New` folders
another feature is hide `*** New` folders where none services present

!!! not jet adopted for OpenPLI, there changes which i made NN2(DMM experimental) files
changes in /usr/lib/enigma2/python/Screens>ChannelSelection.py
.
..
...
# +
def getServicesCount(self, root_ref):
  count = 0
  serviceHandler = eServiceCenter.getInstance()
  list = serviceHandler.list(root_ref)
  if list is not None:
   while True:
	s = list.getNext()
	if not s.valid(): break
	count += 1
  return count
# + END
def showSatellites(self):
  if not self.pathChangeDisabled:
   refstr = '%s FROM SATELLITES ORDER BY satellitePosition'%(self.service_types)
   if not self.preEnterPath(refstr):
	ref = eServiceReference(refstr)
	justSet=False
	prev = None
	if self.isBasePathEqual(ref):
	 if self.isPrevPathEqual(ref):
	  justSet=True
	 prev = self.pathUp(justSet)
	else:
	 currentRoot = self.getRoot()
	 if currentRoot is None or currentRoot != ref:
	  justSet=True
	  self.clearPath()
	  self.enterPath(ref, True)
	if justSet:
	 serviceHandler = eServiceCenter.getInstance()
	 servicelist = serviceHandler.list(ref)
	 if not servicelist is None:
	  while True:
	   service = servicelist.getNext()
	   if not service.valid(): #check if end of list
		break
	   unsigned_orbpos = service.getUnsignedData(4) >> 16
	   orbpos = service.getData(4) >> 16
	   if orbpos < 0:
		orbpos += 3600
# +
	   skip = 0
	   cntstr = ""
# + END
	   if service.getPath().find("FROM PROVIDER") != -1:
		service_type = _("Providers")
	   elif service.getPath().find("flags == %d" %(FLAG_SERVICE_NEW_FOUND)) != -1:
# +
		if "..New" in config.usage.show_services_count_for_folders.value or config.usage.hide_empty_newfound_folders.value:
		 cnt = self.getServicesCount(service)
		 if cnt == 0 and config.usage.hide_empty_newfound_folders.value:
		  skip = 1
		 else:
		  cntstr = " (%d)"%(cnt)
# + END
		service_type = _("New")
	   elif service.getPath().find("numCAIDs") != -1:
# +
		if "..FTA" in config.usage.show_services_count_for_folders.value:
		 cntstr = " (%d)"%(self.getServicesCount(service))
# + END
		service_type = _("Services") + " FTA"
	   else:
# +
		if "..Simple" in config.usage.show_services_count_for_folders.value:
		 cntstr = " (%d)"%(self.getServicesCount(service))
# + END
		service_type = _("Services")
	   try:
		# why we need this cast?
		service_name = str(nimmanager.getSatDescription(orbpos))
	   except:
		if unsigned_orbpos == 0xFFFF: #Cable
		 service_name = _("Cable")
		elif unsigned_orbpos == 0xEEEE: #Terrestrial
		 service_name = _("Terrestrial")
		else:
		 if orbpos > 1800: # west
		  orbpos = 3600 - orbpos
		  h = _("W")
		 else:
		  h = _("E")
		 service_name = ("%d.%d" + h) % (orbpos / 10, orbpos % 10)
# -	   service.setName("%s - %s" % (service_name, service_type))
# -	   self.servicelist.addService(service)
# +
	   if not skip:
		service.setName("%s - %s%s" %(service_name, service_type, cntstr))
		self.servicelist.addService(service)
# + END
	  cur_ref = self.session.nav.getCurrentlyPlayingServiceReference()
	  if cur_ref:
	   pos = self.service_types.rfind(':')
	   refstr = '%s (channelID == %08x%04x%04x) && %s ORDER BY name' %(self.service_types[:pos+1],
		cur_ref.getUnsignedData(4), # NAMESPACE
		cur_ref.getUnsignedData(2), # TSID
		cur_ref.getUnsignedData(3), # ONID
		self.service_types[pos+1:])
	   ref = eServiceReference(refstr)
	   ref.setName(_("Current Transponder"))
	   self.servicelist.addService(ref)
	  self.servicelist.finishFill()
	  if prev is not None:
	   self.setCurrentSelection(prev)
...
..
.
changes in /usr/lib/enigma2/python/Components>UsageConfig.py
.
..
...
def InitUsageConfig():
config.usage = ConfigSubsection();
# +
config.usage.toggle_show_close_automatically = ConfigYesNo(default = False)
config.usage.show_services_count_for_folders = ConfigSet(default=["..New"], choices = ["..New", "..FTA", "..HD", "..Simple"])
config.usage.hide_empty_newfound_folders = ConfigYesNo(default = True)
# + END
...
..
.
changes in /usr/share/enigma2>setup.xml
.
..
...
   <item level="0" text="Infobar timeout">config.usage.infobar_timeout</item>
   <item level="0" text="Auto Hide manual activated Infobar">config.usage.toggle_show_close_automatically</item>
   <item level="1" text="12V output" requires="12V_Output">config.usage.output_12V</item>
   <item level="0" text="Show event-progress in channel selection">config.usage.show_event_progress_in_servicelist</item>
   <item level="0" text="Show Services Count for Folders">config.usage.show_services_count_for_folders</item>
   <item level="0" text="Hide Empty NewFound folders">config.usage.hide_empty_newfound_folders</item>
   <item level="2" text="Show infobar on channel change">config.usage.show_infobar_on_zap</item>
...
..
.

Attached Files



Re: ChannelSelection modifications #7 littlesat

  • PLi® Core member
  • 57,173 posts

+698
Excellent

Posted 22 March 2012 - 08:10

We have last scanned bouquet instead already for a long time.... WIthout any settings or so required.... I think this is even better ;)

In addition we cannot take over code from DMM due to licence issues....

Edited by littlesat, 22 March 2012 - 08:11.

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W


Re: ChannelSelection modifications #8 Rob van der Does

  • Senior Member
  • 7,766 posts

+184
Excellent

Posted 22 March 2012 - 08:27

'Last scanned' is very awkward: on doing a new scan the previous results are gone (consistent with the naming 'last', but not very handy).

Re: ChannelSelection modifications #9 Robinson

  • Senior Member
  • 2,621 posts

+30
Good

Posted 22 March 2012 - 08:39

'Last scanned' is very awkward

For me, personally, "Last scanned" is a very useful feature of OpenPLi.

ET9000, OpenPLi 4.0, 13E, 19E

HD51, OpenPLi 6.2, 75E - 30W


Re: ChannelSelection modifications #10 daddelfalk

  • Senior Member
  • 489 posts

+17
Neutral

Posted 22 March 2012 - 08:50

Hi,

and such a query elif service.getPath().find("numCAIDs") != -1:
i guess it won't work, as it is not included in openpli..

Re: ChannelSelection modifications #11 MartiniB

  • Senior Member
  • 49 posts

0
Neutral

Posted 22 March 2012 - 09:15

in case function `def getServicesCount(self, root_ref)` i have stollen here i would only share my optimisations,
developers have to read only lines between markers `# +` and `# + END`
methods/options `Hide empty NewFound folder` and `count services for only selected folders` can be compatible in OpenPLI

Re: ChannelSelection modifications #12 littlesat

  • PLi® Core member
  • 57,173 posts

+698
Excellent

Posted 22 March 2012 - 09:22

Do all patches work in PLi? Did you test it?

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W


Re: ChannelSelection modifications #13 MartiniB

  • Senior Member
  • 49 posts

0
Neutral

Posted 22 March 2012 - 10:00

.
..
....
!!! not jet adopted for OpenPLI, there changes which i made NN2(DMM experimental) files
....
..



Re: ChannelSelection modifications #14 littlesat

  • PLi® Core member
  • 57,173 posts

+698
Excellent

Posted 22 March 2012 - 10:12

But are you willing to make such changes for PLi....

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W


Re: ChannelSelection modifications #15 andyblac

  • Senior Member
  • 465 posts

+18
Neutral

Posted 22 March 2012 - 18:12

would be nice if you could the add encryption symbol to the item in the list, so we can quickly see what is fta or encrypted.

Re: ChannelSelection modifications #16 korsan

  • Senior Member
  • 404 posts

+5
Neutral

Posted 22 March 2012 - 23:55

@Dima73,
Excellent work.

Posted Image

I have a couple suggestions maybe you may like it:
1) Like MartiniB mentioned, hide sats with zero/empty in NEW?
2) Highlighting HD channels in 'all services and user bouquets' with a different foreground color, marked or make them bold? (Maybe include an option to customize this in a skin?)

H9.Twin  :::  H9.2H :::  H9.S ::: HD1265 ::: H2H :::::::::: WaveFrontier T90: 1W, 3, 7, 13, 16, 19, 23, 28, 42E ::::::::::


Re: ChannelSelection modifications #17 Dimitrij

  • PLi® Core member
  • 10,328 posts

+350
Excellent

Posted 23 March 2012 - 06:39

@korsan
>1) Like MartiniB mentioned, hide sats with zero/empty in NEW?

This will require changes to multiple files.
You will do to change them after each update?
For example, I do not want to.

Edited by Dima73, 23 March 2012 - 06:39.

GigaBlue UHD Quad 4K /Lunix3-4K/Duo 4K


Re: ChannelSelection modifications #18 littlesat

  • PLi® Core member
  • 57,173 posts

+698
Excellent

Posted 23 March 2012 - 10:06

And now a clear patch.... not something with # +START and so on....

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W


Re: ChannelSelection modifications #19 MartiniB

  • Senior Member
  • 49 posts

0
Neutral

Posted 23 March 2012 - 11:49

@Littlesat
have find free hour yesterday and installed OpenPLI on one box,
noticed there arent present *.py files,
then how can i compare with original PLI's /usr/lib/enigma2/python/Screens/ChannelSelection.py ?

for images where *.py files are present i have wrote my own /usr/script/python_patcher.sh and /usr/script/skin_patcher.sh
which i run after each online update, then my made changes restored
http://www.dream-mul...&threadID=12560

@Dima73> This will require changes to multiple files. You will do to change them after each update? For example, I do not want to.
multiple modules change requered only when turn On turn Off option is supported, you can chose Hide Allways case
btw `turn On turn Off option` have made just because 9 seconds on open Sat list is too much long time
if counting can be made another/faster way then that sub options will not be necesary at all

Re: ChannelSelection modifications #20 littlesat

  • PLi® Core member
  • 57,173 posts

+698
Excellent

Posted 23 March 2012 - 13:25

noticed there arent present *.py files,

opkg install enigma2-src does the trick... And all our sources are on http://openpli.git.s...itweb-index.cgi.

To do this right you do not work with patcher.sh files.... but with real diffs/patches created with git.

At least post your endresulting py file....

Edited by littlesat, 23 March 2012 - 13:26.

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W



1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users