Permalink
Browse files

Fix compile errors, use toLatin1 instead of the deprecated toAscii() …

…for Qt5
  • Loading branch information...
exiaoy committed Jul 13, 2013
1 parent 6aa70ce commit 15842d4885b3dfdf1c7113c6d142df9cd93b33b6
Showing with 3 additions and 3 deletions.
  1. +2 −2 abstractlogview.cpp
  2. +1 −1 crawlerwidget.cpp
@@ -497,14 +497,14 @@ void AbstractLogView::keyPressEvent( QKeyEvent* keyEvent )
else if ( keyEvent->key() == Qt::Key_End )
jumpToRightOfScreen();
else {
const char character = (keyEvent->text())[0].toAscii();
const char character = (keyEvent->text())[0].toLatin1();
if ( ( character >= '0' ) && ( character <= '9' ) ) {
// Adds the digit to the timed buffer
digitsBuffer_.add( character );
}
else {
switch ( (keyEvent->text())[0].toAscii() ) {
switch ( (keyEvent->text())[0].toLatin1() ) {
case 'j':
{
int delta = qMax( 1, digitsBuffer_.content() );
@@ -342,7 +342,7 @@ void CrawlerWidget::keyPressEvent( QKeyEvent* keyEvent )
{
LOG(logDEBUG4) << "keyPressEvent received";
switch ( (keyEvent->text())[0].toAscii() ) {
switch ( (keyEvent->text())[0].toLatin1() ) {
case '/':
case '?':
displayQuickFindBar();

0 comments on commit 15842d4

Please sign in to comment.