Browse Source

Corrections UTF-8

master
Maxime Wack 11 years ago
parent
commit
fb68b9e77f
4 changed files with 22 additions and 15 deletions
  1. +12
    -5
      CosMoS/bdd.cpp
  2. +1
    -1
      CosMoS/bdd.h
  3. +1
    -1
      CosMoS/cosmos.cpp
  4. +8
    -8
      CosMoS/cosmosGUI.cpp

+ 12
- 5
CosMoS/bdd.cpp View File

@@ -7,7 +7,7 @@ class_bdd::class_bdd(const wxString& path_in)
createEmpty();
else if ((rc=sqlite3_open_v2(_C(path), &db, SQLITE_OPEN_READWRITE, NULL)) != SQLITE_OK)
{
wxMessageBox("Erreur lors de l'ouverture de la base de données", "Erreur", wxICON_ERROR | wxOK);
wxMessageBox(_T("Erreur lors de l'ouverture de la base de données"), "Erreur", wxICON_ERROR | wxOK);
exit(0);
}
}
@@ -26,14 +26,21 @@ void class_bdd::createEmpty()
rc += sqlite3_exec(db, "CREATE TABLE Correc(orig TEXT PRIMARY KEY, dest TEXT);", NULL, NULL, NULL);
if (rc)
{
wxMessageBox("Erreur lors de la création de la base de données", "Erreur", wxICON_ERROR | wxOK);
wxMessageBox(_T("Erreur lors de la création de la base de données"), "Erreur", wxICON_ERROR | wxOK);
exit(0);
}
wxMessageBox("La base de données est vide,\nveuillez importer des données !");
wxMessageBox(_T("La base de données est vide,\nveuillez importer des données !"));
}

void class_bdd::import(const wxString& importfile)
void class_bdd::import(const wxString& filename)
{
wxTextFile importfile;
if (!importfile.Open(filename))
wxMessageBox("Erreur lors du chargement du fichier", "Erreur", wxICON_ERROR | wxOK);
else
{
wxMessageBox(wxString::Format("%i",importfile.GetLineCount()), "Nb lignes", wxOK);
importfile.Close();
}
}

+ 1
- 1
CosMoS/bdd.h View File

@@ -26,7 +26,7 @@ class class_bdd
public:
class_bdd(const wxString& path_in);
~class_bdd();
void import(const wxString& importfile);
void import(const wxString& filename);
};



+ 1
- 1
CosMoS/cosmos.cpp View File

@@ -9,7 +9,7 @@ cosmosGUI( parent )
if (configuration->IsFirstTime())
{
wxMessageBox("Vous lancez CosMoS pour la première fois,\nveuillez configurer le chemin de la base\nainsi que les paramètres de connexion");
wxMessageBox(_T("Vous lancez CosMoS pour la première fois,\nveuillez configurer le chemin de la base\nainsi que les paramètres de connexion"));
fenetre_options->ShowModal();
}



+ 8
- 8
CosMoS/cosmosGUI.cpp View File

@@ -44,7 +44,7 @@ cosmosGUI::cosmosGUI( wxWindow* parent, wxWindowID id, const wxString& title, co
menu_Edit = new wxMenu();
wxMenuItem* menuitem_Optionsprog;
menuitem_Optionsprog = new wxMenuItem( menu_Edit, wxID_PROPERTIES, "Options générales", wxEmptyString, wxITEM_NORMAL );
menuitem_Optionsprog = new wxMenuItem( menu_Edit, wxID_PROPERTIES, _T("Options générales"), wxEmptyString, wxITEM_NORMAL );
menuitem_Optionsprog->SetBitmap( wxBitmap(optionsgales_xpm) );
menu_Edit->Append( menuitem_Optionsprog );
@@ -57,12 +57,12 @@ cosmosGUI::cosmosGUI( wxWindow* parent, wxWindowID id, const wxString& title, co
toolbar = this->CreateToolBar( wxTB_FLAT|wxTB_HORIZONTAL, wxID_ANY );
toolbar->AddTool( wxID_OPEN, "Importer base", wxBitmap(import_xpm), wxNullBitmap, wxITEM_NORMAL, "Importer la base CONSTAT", wxEmptyString );
toolbar->AddTool( wxID_SAVE, "Exporter base", wxBitmap(export_xpm), wxNullBitmap, wxITEM_NORMAL, "Exporter les résultats", wxEmptyString );
toolbar->AddTool( wxID_SAVE, "Exporter base", wxBitmap(export_xpm), wxNullBitmap, wxITEM_NORMAL, _T("Exporter les résultats"), wxEmptyString );
toolbar->AddSeparator();
toolbar->AddTool( wxID_NEW, "Lancer", wxBitmap(play_xpm), wxNullBitmap, wxITEM_NORMAL, "Lancer la recherche", wxEmptyString );
toolbar->AddTool( wxID_FIND, "Options", wxBitmap(optionsrche_xpm), wxNullBitmap, wxITEM_NORMAL, "Options de recherche", wxEmptyString );
toolbar->AddSeparator();
toolbar->AddTool( wxID_DUPLICATE, "Corrections", wxBitmap(correc_xpm), wxNullBitmap, wxITEM_NORMAL, "Ouvrir l'éditeur de corrections", wxEmptyString );
toolbar->AddTool( wxID_DUPLICATE, "Corrections", wxBitmap(correc_xpm), wxNullBitmap, wxITEM_NORMAL, _T("Ouvrir l'éditeur de corrections"), wxEmptyString );
toolbar->AddSeparator();
searchctrl = new wxSearchCtrl( toolbar, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_PROCESS_ENTER );
#ifndef __WXMAC__
@@ -101,13 +101,13 @@ cosmosGUI::cosmosGUI( wxWindow* parent, wxWindowID id, const wxString& title, co
grid_Consults->SetColLabelValue( 0, "Publication ?" );
grid_Consults->SetColLabelValue( 1, _T("Consultant associé ?") );
grid_Consults->SetColLabelValue( 2, "Publication CHU ?" );
grid_Consults->SetColLabelValue( 3, "N° Dossier" );
grid_Consults->SetColLabelValue( 3, _T("N° Dossier") );
grid_Consults->SetColLabelValue( 4, "Nom(s) demandeur(s)" );
grid_Consults->SetColLabelValue( 5, "Prénom(s) demandeur(s)" );
grid_Consults->SetColLabelValue( 5, _T("Prénom(s) demandeur(s)") );
grid_Consults->SetColLabelValue( 6, "Nom(s) responsable(s)" );
grid_Consults->SetColLabelValue( 7, "Thème" );
grid_Consults->SetColLabelValue( 8, "Date dernière consultation" );
grid_Consults->SetColLabelValue( 9, "Résultats" );
grid_Consults->SetColLabelValue( 7, _T("Thème") );
grid_Consults->SetColLabelValue( 8, _T("Date dernière consultation") );
grid_Consults->SetColLabelValue( 9, _T("Résultats") );
grid_Consults->SetColLabelAlignment( wxALIGN_CENTRE, wxALIGN_CENTRE );
// Rows


Loading…
Cancel
Save