diff options
| author | ghost <andreas.monzner@multimedia-labs.de> | 2010-10-06 11:51:51 +0200 |
|---|---|---|
| committer | ghost <andreas.monzner@multimedia-labs.de> | 2010-10-06 11:51:51 +0200 |
| commit | 0e903a5d9d38bd48c792c095d786fc40091a47fa (patch) | |
| tree | 69dbf87e1271863b24e836c6b85540361351c2f2 | |
| parent | e88b76f7f7e0a111a2bba1573e23378a3eb88917 (diff) | |
| parent | 2a8f4bb347c3cf4075bfa45cae2220d4562f74ee (diff) | |
| download | enigma2-0e903a5d9d38bd48c792c095d786fc40091a47fa.tar.gz enigma2-0e903a5d9d38bd48c792c095d786fc40091a47fa.zip | |
Merge branch 'bug_487_service_selection_event_text_color'
| -rw-r--r-- | lib/python/Components/ServiceList.py | 4 | ||||
| -rw-r--r-- | lib/service/listboxservice.cpp | 10 | ||||
| -rw-r--r-- | lib/service/listboxservice.h | 2 |
3 files changed, 16 insertions, 0 deletions
diff --git a/lib/python/Components/ServiceList.py b/lib/python/Components/ServiceList.py index 3452e27d..cd055a82 100644 --- a/lib/python/Components/ServiceList.py +++ b/lib/python/Components/ServiceList.py @@ -72,6 +72,10 @@ class ServiceList(HTMLComponent, GUIComponent): self.l.setColor(eListboxServiceContent.serviceEventProgressbarBorderColor, parseColor(value)) elif attrib == "colorEventProgressbarBorderSelected": self.l.setColor(eListboxServiceContent.serviceEventProgressbarBorderColorSelected, parseColor(value)) + elif attrib == "colorServiceDescription": + self.l.setColor(eListboxServiceContent.serviceDescriptionColor, parseColor(value)) + elif attrib == "colorServiceDescriptionSelected": + self.l.setColor(eListboxServiceContent.serviceDescriptionColorSelected, parseColor(value)) elif attrib == "picServiceEventProgressbar": pic = LoadPixmap(resolveFilename(SCOPE_CURRENT_SKIN, value)) if pic: diff --git a/lib/service/listboxservice.cpp b/lib/service/listboxservice.cpp index f8ac0ff2..cc8c32b5 100644 --- a/lib/service/listboxservice.cpp +++ b/lib/service/listboxservice.cpp @@ -531,12 +531,15 @@ void eListboxServiceContent::paint(gPainter &painter, eWindowStyle &style, const bool paintProgress = false; ePtr<eServiceEvent> evt; + bool serviceAvail = true; + if (!marked && isPlayable && service_info && m_is_playable_ignore.valid() && !service_info->isPlayable(*m_cursor, m_is_playable_ignore)) { if (m_color_set[serviceNotAvail]) painter.setForegroundColor(m_color[serviceNotAvail]); else painter.setForegroundColor(gRGB(0xbbbbbb)); + serviceAvail = false; } if (selected && local_style && local_style->m_selection) @@ -592,6 +595,13 @@ void eListboxServiceContent::paint(gPainter &painter, eWindowStyle &style, const if (!name.length()) continue; text = '(' + evt->getEventName() + ')'; + if (serviceAvail) + { + if (!selected && m_color_set[serviceDescriptionColor]) + painter.setForegroundColor(m_color[serviceDescriptionColor]); + else if (selected && m_color_set[serviceDescriptionColorSelected]) + painter.setForegroundColor(m_color[serviceDescriptionColorSelected]); + } } else continue; diff --git a/lib/service/listboxservice.h b/lib/service/listboxservice.h index 982d7e14..589afba6 100644 --- a/lib/service/listboxservice.h +++ b/lib/service/listboxservice.h @@ -90,6 +90,8 @@ public: serviceEventProgressbarColorSelected, serviceEventProgressbarBorderColor, serviceEventProgressbarBorderColorSelected, + serviceDescriptionColor, + serviceDescriptionColorSelected, colorElements }; |
