]> git.saurik.com Git - wxWidgets.git/blobdiff - src/generic/filedlgg.cpp
changed case of the cursor names to be consistent with wx.rc
[wxWidgets.git] / src / generic / filedlgg.cpp
index 3d0b66d391dcc0d8803baa94563871f8d7cc1938..69335d597f4bd1225b4e033b221fefc0f2a58092 100644 (file)
@@ -343,8 +343,9 @@ void wxFileData::MakeItem( wxListItem &item )
 
     if (IsLink())
     {
-        wxColour *dg = wxTheColourDatabase->FindColour( _T("MEDIUM GREY") );
-        item.SetTextColour(*dg);
+        wxColour dg = wxTheColourDatabase->Find( _T("MEDIUM GREY") );
+        if ( dg.Ok() )
+            item.SetTextColour(dg);
     }
     item.m_data = (long)this;
 }
@@ -490,7 +491,6 @@ void wxFileCtrl::UpdateFiles()
     FreeAllItemsData();
     DeleteAllItems();
 
-    wxFileData *fd = (wxFileData *) NULL;
     wxListItem item;
     item.m_itemId = 0;
     item.m_col = 0;
@@ -504,7 +504,7 @@ void wxFileCtrl::UpdateFiles()
 
         for (n=0; n<count; n++)
             {
-            fd = new wxFileData(paths[n], names[n], wxFileData::is_drive, icons[n]);
+            wxFileData *fd = new wxFileData(paths[n], names[n], wxFileData::is_drive, icons[n]);
                 Add(fd, item);
                 item.m_itemId++;
             }
@@ -519,7 +519,7 @@ void wxFileCtrl::UpdateFiles()
 #ifdef __UNIX__
             if (p.IsEmpty()) p = wxT("/");
 #endif // __UNIX__
-            fd = new wxFileData(p, wxT(".."), wxFileData::is_dir, wxFileIconsTable::folder);
+            wxFileData *fd = new wxFileData(p, wxT(".."), wxFileData::is_dir, wxFileIconsTable::folder);
             Add(fd, item);
             item.m_itemId++;
         }
@@ -546,7 +546,7 @@ void wxFileCtrl::UpdateFiles()
             cont = dir.GetFirst(&f, wxEmptyString, wxDIR_DIRS | hiddenFlag);
             while (cont)
             {
-                fd = new wxFileData(dirPrefix + f, f, wxFileData::is_dir, wxFileIconsTable::folder);
+                wxFileData *fd = new wxFileData(dirPrefix + f, f, wxFileData::is_dir, wxFileIconsTable::folder);
                 Add(fd, item);
                 item.m_itemId++;
                 cont = dir.GetNext(&f);
@@ -561,7 +561,7 @@ void wxFileCtrl::UpdateFiles()
                                         wxDIR_FILES | hiddenFlag);
                 while (cont)
                 {
-                    fd = new wxFileData(dirPrefix + f, f, wxFileData::is_file, wxFileIconsTable::file);
+                    wxFileData *fd = new wxFileData(dirPrefix + f, f, wxFileData::is_file, wxFileIconsTable::file);
                     Add(fd, item);
                     item.m_itemId++;
                     cont = dir.GetNext(&f);