X-Git-Url: http://Server1/repobrowser/?a=blobdiff_plain;f=source%2Fcontacteditor%2FfrmContactEditor-Logo.cpp;h=ce5649abd0818ffb1c8252bf330c31edcb7d5a34;hb=bfe817b5bfae33a1eb666c463643ec119cd1d66d;hp=e75a6a0f571eb0a9c0333032428fad65c445d7f9;hpb=fb9cf55d990f7419dd7ae3ce9fdaadf07059b9cb;p=xestiaab%2F.git diff --git a/source/contacteditor/frmContactEditor-Logo.cpp b/source/contacteditor/frmContactEditor-Logo.cpp index e75a6a0..ce5649a 100644 --- a/source/contacteditor/frmContactEditor-Logo.cpp +++ b/source/contacteditor/frmContactEditor-Logo.cpp @@ -28,7 +28,7 @@ void frmContactEditor::LoadLogo( wxListEvent& event ) long longSelected = -1; int intSelectedData = 0; - if (!GetSelectedItem(lboLogos, + if (lboLogos->GetItemCount() == 0 || !GetSelectedItem(lboLogos, &longSelected, &intSelectedData)){ return; @@ -86,12 +86,9 @@ void frmContactEditor::AddLogo( wxCommandEvent& event ) { // Bring up the window to add a logo. - - int intResult = 0; - + frmContactEditorPicture *frameCELogo = new frmContactEditorPicture ( this ); frameCELogo->SetEditorMode(FALSE); - intResult = GetLastInt(&ContactEditorData.LogosList); frameCELogo->SetupPointers(&ContactEditorData.LogosList, &ContactEditorData.LogosListAltID, &ContactEditorData.LogosListPID, @@ -118,7 +115,7 @@ void frmContactEditor::ModifyLogo( wxCommandEvent& event ) long longSelected = -1; int intSelectedData = 0; - if (!GetSelectedItem(lboLogos, + if (lboLogos->GetItemCount() == 0 || !GetSelectedItem(lboLogos, &longSelected, &intSelectedData)){ return; @@ -152,7 +149,7 @@ void frmContactEditor::DeleteLogo( wxCommandEvent& event ) long longSelected = -1; int intSelectedData = 0; - if (!GetSelectedItem(lboLogos, + if (lboLogos->GetItemCount() == 0 || !GetSelectedItem(lboLogos, &longSelected, &intSelectedData)){ return; @@ -181,7 +178,7 @@ void frmContactEditor::SaveLogo( wxCommandEvent &event ) long longSelected = -1; int intSelectedData = 0; - if (!GetSelectedItem(lboLogos, + if (lboLogos->GetItemCount() == 0 || !GetSelectedItem(lboLogos, &longSelected, &intSelectedData)){