Skip to content

Commit

Permalink
qt5: toAscii() -> toLatin1()
Browse files Browse the repository at this point in the history
  • Loading branch information
rp- committed Feb 13, 2014
1 parent 402f622 commit 202b6c9
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion libs/qhexedit/src/qhexedit_p.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -437,7 +437,7 @@ void QHexEditPrivate::keyPressEvent(QKeyEvent *event)
if (!_readOnly)
{
/* Hex input */
int key = int(event->text()[0].toAscii());
int key = int(event->text()[0].toLatin1());
if ((key>='0' && key<='9') || (key>='a' && key <= 'f'))
{
if (getSelectionBegin() != getSelectionEnd())
Expand Down
2 changes: 1 addition & 1 deletion src/EditDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ void EditDialog::checkDataType()
{
// Check if data is text only
ui->comboEditor->setVisible(true);
if(QString(hexEdit->data()).toAscii() == hexEdit->data()) // Any proper way??
if(QString(hexEdit->data()).toLatin1() == hexEdit->data()) // Any proper way??
{
ui->editorStack->setCurrentIndex(0);

Expand Down
4 changes: 2 additions & 2 deletions src/ImportCsvDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -207,12 +207,12 @@ void ImportCsvDialog::checkInput()
char ImportCsvDialog::currentQuoteChar()
{
if(ui->comboQuote->currentText().length())
return ui->comboQuote->currentText().at(0).toAscii();
return ui->comboQuote->currentText().at(0).toLatin1();
else
return 0;
}

char ImportCsvDialog::currentSeparatorChar()
{
return ui->comboSeparator->currentText() == tr("Tab") ? '\t' : ui->comboSeparator->currentText().at(0).toAscii();
return ui->comboSeparator->currentText() == tr("Tab") ? '\t' : ui->comboSeparator->currentText().at(0).toLatin1();
}

0 comments on commit 202b6c9

Please sign in to comment.