add special color for marked and selected
authorFelix Domke <tmbinc@elitedvb.net>
Mon, 27 Feb 2006 21:11:19 +0000 (21:11 +0000)
committerFelix Domke <tmbinc@elitedvb.net>
Mon, 27 Feb 2006 21:11:19 +0000 (21:11 +0000)
data/skin.xml
lib/gui/ewindowstyle.cpp
lib/gui/ewindowstyle.h
lib/gui/ewindowstyleskinned.cpp
lib/gui/ewindowstyleskinned.h
lib/service/listboxservice.cpp

index 5064665..6898563 100644 (file)
@@ -21,6 +21,8 @@
                        <color name="ListboxSelectedForeground" color="#ffffff" />
                        <color name="ListboxMarkedBackground" color="#ff0000" />
                        <color name="ListboxMarkedForeground" color="#ffffff" />
+                       <color name="ListboxMarkedAndSelectedBackground" color="#800000" />
+                       <color name="ListboxMarkedAndSelectedForeground" color="#ffffff" />
                        <color name="WindowTitleForeground" color="#ffffff" />
                        <color name="WindowTitleBackground" color="#33294a6b" />
                        <borderset name="bsWindow">
index 86ff8a4..4cfaa8d 100644 (file)
@@ -109,6 +109,10 @@ void eWindowStyleSimple::setStyle(gPainter &painter, int what)
                painter.setForegroundColor(gColor(0x2F));
                painter.setBackgroundColor(gColor(0x2A));
                break;
+       case styleListboxMarkedAndSelected:
+               painter.setForegroundColor(gColor(0x3F));
+               painter.setBackgroundColor(gColor(0x3A));
+               break;
        }
 }
 
index 04d9d44..3c9c805 100644 (file)
@@ -18,7 +18,8 @@ public:
                styleLabel,
                styleListboxSelected,
                styleListboxNormal,
-               styleListboxMarked
+               styleListboxMarked,
+               styleListboxMarkedAndSelected
        };
        
        virtual void drawFrame(gPainter &painter, const eRect &frame, int type) = 0;
index 5da4696..a3cc3c5 100644 (file)
@@ -70,6 +70,10 @@ void eWindowStyleSkinned::setStyle(gPainter &painter, int what)
                painter.setForegroundColor(m_color[colListboxMarkedForeground]);
                painter.setBackgroundColor(m_color[colListboxMarkedBackground]);
                break;
+       case styleListboxMarkedAndSelected:
+               painter.setForegroundColor(m_color[colListboxMarkedAndSelectedForeground]);
+               painter.setBackgroundColor(m_color[colListboxMarkedAndSelectedBackground]);
+               break;
        }
 }
 
index 17988f6..1c16a7b 100644 (file)
@@ -61,6 +61,8 @@ public:
                colListboxSelectedForeground,
                colListboxMarkedBackground,
                colListboxMarkedForeground,
+               colListboxMarkedAndSelectedBackground,
+               colListboxMarkedAndSelectedForeground,
                
                colWindowTitleForeground,
                colWindowTitleBackground,
index 13538e9..c869b49 100644 (file)
@@ -358,7 +358,7 @@ void eListboxServiceContent::paint(gPainter &painter, eWindowStyle &style, const
        if (m_current_marked && selected)
                style.setStyle(painter, eWindowStyle::styleListboxMarked);
        else if (cursorValid() && isMarked(*m_cursor))
-               style.setStyle(painter, eWindowStyle::styleListboxMarked);
+               style.setStyle(painter, selected ? eWindowStyle::styleListboxMarkedAndSelected : eWindowStyle::styleListboxMarked);
        else
                style.setStyle(painter, selected ? eWindowStyle::styleListboxSelected : eWindowStyle::styleListboxNormal);
        painter.clear();