]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/dbgrid.cpp
Added support for static (inlined) wxImages with
[wxWidgets.git] / src / common / dbgrid.cpp
index cb3cd9c99eadc321957276794f3afaf944f62e29..bdb5aa196a9486cfc4a4fcdeb724b54df5635d4d 100644 (file)
@@ -276,11 +276,14 @@ wxString wxDbGridTableBase::GetTypeName(int WXUNUSED(row), int col)
             switch(m_data->GetColDefs()[(m_ColInfo[col].DbCol)].SqlCtype)
             {
                 case SQL_C_CHAR:
+                case SQL_C_WCHAR:
                     return wxGRID_VALUE_STRING;
+                case SQL_C_SHORT:
                 case SQL_C_SSHORT:
                     return wxGRID_VALUE_NUMBER;
                 case SQL_C_USHORT:
                     return wxGRID_VALUE_NUMBER;
+                case SQL_C_LONG:
                 case SQL_C_SLONG:
                     return wxGRID_VALUE_NUMBER;
                 case SQL_C_ULONG:
@@ -320,7 +323,7 @@ bool wxDbGridTableBase::CanGetValueAs(int row, int col, const wxString& typeName
         return true;
     }
 
-    if (m_data->IsColNull(m_ColInfo[col].DbCol))
+    if (m_data->IsColNull((UWORD)m_ColInfo[col].DbCol))
     {
         return false;
     }
@@ -508,7 +511,7 @@ void* wxDbGridTableBase::GetValueAsCustom(int row, int col, const wxString& type
         wxFAIL_MSG (_T("You can not use GetValueAsCustom for virtual columns"));
         return NULL;
     }
-    if (m_data->IsColNull(m_ColInfo[col].DbCol))
+    if (m_data->IsColNull((UWORD)m_ColInfo[col].DbCol))
         return NULL;
 
     if (typeName == wxGRID_VALUE_DATETIME)
@@ -580,7 +583,7 @@ bool wxDbGridTableBase::IsEmptyCell(int row, int col)
     wxLogDebug(wxT("IsEmtpyCell on %i,%i"),row,col);
 
     ValidateRow(row);
-    return m_data->IsColNull(m_ColInfo[col].DbCol);
+    return m_data->IsColNull((UWORD)m_ColInfo[col].DbCol);
 }