Changeset 164

Show
Ignore:
Timestamp:
07/04/08 14:24:45 (2 months ago)
Author:
cyrusdaboo
Message:

Color the calendar inbox when it has contents.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • Mulberry/branches/v4.1d1/MacOS/Sources/Application/Calendar/Calendar_View/Calendar_Store_View/CCalendarStoreTable.cp

    r163 r164  
    755755                        Style text_style = normal; 
    756756 
    757                         text_color = CPreferences::sPrefs->mMboxClosedStyle.GetValue().color; 
    758                         color_set = true; 
    759                         text_style = text_style | CPreferences::sPrefs->mMboxClosedStyle.GetValue().style & 0x007F; 
    760                         strike =  strike || ((CPreferences::sPrefs->mMboxClosedStyle.GetValue().style & 0x0080) != 0); 
     757                        if (node->IsSubscribed()) 
     758                        { 
     759                                iCal::CICalendar* cal = node->GetCalendar(); 
     760                                if (node->IsInbox() && (cal != NULL) && cal->HasData()) 
     761                                { 
     762                                        text_color = CPreferences::sPrefs->mMboxUnseenStyle.GetValue().color; 
     763                                        color_set = true; 
     764                                        text_style = text_style | CPreferences::sPrefs->mMboxUnseenStyle.GetValue().style & 0x007F; 
     765                                        strike =  strike || ((CPreferences::sPrefs->mMboxUnseenStyle.GetValue().style & 0x0080) != 0); 
     766                                } 
     767                                else 
     768                                {                                
     769                                        text_color = CPreferences::sPrefs->mMboxFavouriteStyle.GetValue().color; 
     770                                        color_set = true; 
     771                                        text_style = text_style | CPreferences::sPrefs->mMboxFavouriteStyle.GetValue().style & 0x007F; 
     772                                        strike =  strike || ((CPreferences::sPrefs->mMboxFavouriteStyle.GetValue().style & 0x0080) != 0); 
     773                                } 
     774                        } 
     775                        if (!color_set) 
     776                        { 
     777                                text_color = CPreferences::sPrefs->mMboxClosedStyle.GetValue().color; 
     778                                color_set = true; 
     779                                text_style = text_style | CPreferences::sPrefs->mMboxClosedStyle.GetValue().style & 0x007F; 
     780                                strike =  strike || ((CPreferences::sPrefs->mMboxClosedStyle.GetValue().style & 0x0080) != 0); 
     781                        } 
    761782 
    762783                        ::RGBForeColor(&text_color);