QmlJS: Fix type lookup issue.
QmlJS: Fix type lookup issue.

0c0ffab1bbc56e6cc381eeba3dc1227793d766cd accidentally always returned
null if the type was not an enum.

Change-Id: Ie16d96e59cefa50c345cddb4a053fd8b60ba3cd6
Reviewed-on: http://codereview.qt.nokia.com/1693
Reviewed-by: Leandro T. C. Melo <8f144cd741810d8c7b648cacf5b9b2f4e2ebcc1b@nokia.com>

bakaiadam/collaborative_qt_creator,darksylinc/qt-creator,kuba1/qtcreator,amyvmiwei/qt-creator,danimo/qt-creator,duythanhphan/qt-creator,martyone/sailfish-qtcreator,syntheticpp/qt-creator,martyone/sailfish-qtcreator,KDAB/KDAB-Creator,duythanhphan/qt-creator,dmik/qt-creator-os2,syntheticpp/qt-creator,malikcjm/qtcreator,ostash/qt-creator-i18n-uk,dmik/qt-creator-os2,danimo/qt-creator,colede/qtcreator,malikcjm/qtcreator,amyvmiwei/qt-creator,xianian/qt-creator,danimo/qt-creator,amyvmiwei/qt-creator,azat/qtcreator,martyone/sailfish-qtcreator,KDAB/KDAB-Creator,colede/qtcreator,KDE/android-qt-creator,bakaiadam/collaborative_qt_creator,Distrotech/qtcreator,farseerri/git_code,hdweiss/qt-creator-visualizer,amyvmiwei/qt-creator,danimo/qt-creator,jonnor/qt-creator,kuba1/qtcreator,syntheticpp/qt-creator,colede/qtcreator,kuba1/qtcreator,hdweiss/qt-creator-visualizer,AltarBeastiful/qt-creator,syntheticpp/qt-creator,KDE/android-qt-creator,KDAB/KDAB-Creator,malikcjm/qtcreator,amyvmiwei/qt-creator,KDAB/KDAB-Creator,azat/qtcreator,AltarBeastiful/qt-creator,colede/qtcreator,maui-packages/qt-creator,colede/qtcreator,AltarBeastiful/qt-creator,danimo/qt-creator,duythanhphan/qt-creator,jonnor/qt-creator,darksylinc/qt-creator,dmik/qt-creator-os2,darksylinc/qt-creator,dmik/qt-creator-os2,amyvmiwei/qt-creator,duythanhphan/qt-creator,malikcjm/qtcreator,xianian/qt-creator,richardmg/qtcreator,colede/qtcreator,Distrotech/qtcreator,darksylinc/qt-creator,martyone/sailfish-qtcreator,farseerri/git_code,dmik/qt-creator-os2,jonnor/qt-creator,darksylinc/qt-creator,bakaiadam/collaborative_qt_creator,maui-packages/qt-creator,ostash/qt-creator-i18n-uk,danimo/qt-creator,KDAB/KDAB-Creator,bakaiadam/collaborative_qt_creator,syntheticpp/qt-creator,ostash/qt-creator-i18n-uk,martyone/sailfish-qtcreator,Distrotech/qtcreator,bakaiadam/collaborative_qt_creator,kuba1/qtcreator,xianian/qt-creator,omniacreator/qtcreator,AltarBeastiful/qt-creator,omniacreator/qtcreator,martyone/sailfish-qtcreator,malikcjm/qtcreator,xianian/qt-creator,omniacreator/qtcreator,azat/qtcreator,farseerri/git_code,ostash/qt-creator-i18n-uk,richardmg/qtcreator,KDE/android-qt-creator,KDE/android-qt-creator,azat/qtcreator,azat/qtcreator,AltarBeastiful/qt-creator,martyone/sailfish-qtcreator,dmik/qt-creator-os2,Distrotech/qtcreator,duythanhphan/qt-creator,colede/qtcreator,syntheticpp/qt-creator,darksylinc/qt-creator,omniacreator/qtcreator,kuba1/qtcreator,syntheticpp/qt-creator,omniacreator/qtcreator,richardmg/qtcreator,farseerri/git_code,hdweiss/qt-creator-visualizer,duythanhphan/qt-creator,xianian/qt-creator,KDE/android-qt-creator,darksylinc/qt-creator,kuba1/qtcreator,martyone/sailfish-qtcreator,xianian/qt-creator,maui-packages/qt-creator,omniacreator/qtcreator,maui-packages/qt-creator,jonnor/qt-creator,ostash/qt-creator-i18n-uk,farseerri/git_code,danimo/qt-creator,xianian/qt-creator,amyvmiwei/qt-creator,kuba1/qtcreator,amyvmiwei/qt-creator,jonnor/qt-creator,martyone/sailfish-qtcreator,KDE/android-qt-creator,darksylinc/qt-creator,xianian/qt-creator,omniacreator/qtcreator,duythanhphan/qt-creator,hdweiss/qt-creator-visualizer,hdweiss/qt-creator-visualizer,Distrotech/qtcreator,KDE/android-qt-creator,malikcjm/qtcreator,maui-packages/qt-creator,jonnor/qt-creator,richardmg/qtcreator,xianian/qt-creator,kuba1/qtcreator,farseerri/git_code,dmik/qt-creator-os2,kuba1/qtcreator,maui-packages/qt-creator,malikcjm/qtcreator,ostash/qt-creator-i18n-uk,AltarBeastiful/qt-creator,hdweiss/qt-creator-visualizer,maui-packages/qt-creator,bakaiadam/collaborative_qt_creator,azat/qtcreator,KDE/android-qt-creator,farseerri/git_code,Distrotech/qtcreator,farseerri/git_code,AltarBeastiful/qt-creator,bakaiadam/collaborative_qt_creator,Distrotech/qtcreator,richardmg/qtcreator,richardmg/qtcreator,richardmg/qtcreator,danimo/qt-creator,AltarBeastiful/qt-creator,ostash/qt-creator-i18n-uk,KDAB/KDAB-Creator,danimo/qt-creator