HistoryCompleter: Keep list in order/allow empty entries
HistoryCompleter: Keep list in order/allow empty entries

The HistoryCompleter ctor sets the initial lineedit value to the first
entry, thus adjust the code to store the most recent value, even if that
was already in the history.

Also allow empty entries in the history.

Change-Id: I1e88fb9eb1474896732d49583e5fc6b7acda0500
Reviewed-by: Orgad Shaneh <2b010cbad792a0c0a8175f752f93f83941fc6bc1@gmail.com>
Reviewed-by: hjk <6fac1c92f5b9c7890a04d7f8a9d8912d16355eac@ovi.com>

kuba1/qtcreator,danimo/qt-creator,maui-packages/qt-creator,xianian/qt-creator,darksylinc/qt-creator,duythanhphan/qt-creator,AltarBeastiful/qt-creator,farseerri/git_code,darksylinc/qt-creator,AltarBeastiful/qt-creator,kuba1/qtcreator,malikcjm/qtcreator,farseerri/git_code,xianian/qt-creator,xianian/qt-creator,xianian/qt-creator,omniacreator/qtcreator,martyone/sailfish-qtcreator,farseerri/git_code,xianian/qt-creator,kuba1/qtcreator,xianian/qt-creator,martyone/sailfish-qtcreator,AltarBeastiful/qt-creator,Distrotech/qtcreator,duythanhphan/qt-creator,amyvmiwei/qt-creator,amyvmiwei/qt-creator,duythanhphan/qt-creator,malikcjm/qtcreator,martyone/sailfish-qtcreator,duythanhphan/qt-creator,farseerri/git_code,AltarBeastiful/qt-creator,omniacreator/qtcreator,Distrotech/qtcreator,kuba1/qtcreator,kuba1/qtcreator,AltarBeastiful/qt-creator,danimo/qt-creator,darksylinc/qt-creator,richardmg/qtcreator,darksylinc/qt-creator,Distrotech/qtcreator,richardmg/qtcreator,xianian/qt-creator,kuba1/qtcreator,omniacreator/qtcreator,farseerri/git_code,danimo/qt-creator,colede/qtcreator,xianian/qt-creator,richardmg/qtcreator,amyvmiwei/qt-creator,danimo/qt-creator,martyone/sailfish-qtcreator,kuba1/qtcreator,farseerri/git_code,colede/qtcreator,malikcjm/qtcreator,omniacreator/qtcreator,amyvmiwei/qt-creator,amyvmiwei/qt-creator,duythanhphan/qt-creator,richardmg/qtcreator,Distrotech/qtcreator,maui-packages/qt-creator,richardmg/qtcreator,maui-packages/qt-creator,Distrotech/qtcreator,AltarBeastiful/qt-creator,colede/qtcreator,martyone/sailfish-qtcreator,omniacreator/qtcreator,maui-packages/qt-creator,martyone/sailfish-qtcreator,danimo/qt-creator,malikcjm/qtcreator,kuba1/qtcreator,richardmg/qtcreator,darksylinc/qt-creator,amyvmiwei/qt-creator,danimo/qt-creator,amyvmiwei/qt-creator,duythanhphan/qt-creator,richardmg/qtcreator,darksylinc/qt-creator,danimo/qt-creator,martyone/sailfish-qtcreator,AltarBeastiful/qt-creator,AltarBeastiful/qt-creator,Distrotech/qtcreator,malikcjm/qtcreator,martyone/sailfish-qtcreator,malikcjm/qtcreator,colede/qtcreator,colede/qtcreator,darksylinc/qt-creator,maui-packages/qt-creator,colede/qtcreator,duythanhphan/qt-creator,farseerri/git_code,xianian/qt-creator,maui-packages/qt-creator,kuba1/qtcreator,danimo/qt-creator,amyvmiwei/qt-creator,omniacreator/qtcreator,farseerri/git_code,maui-packages/qt-creator,Distrotech/qtcreator,colede/qtcreator,martyone/sailfish-qtcreator,darksylinc/qt-creator,omniacreator/qtcreator,malikcjm/qtcreator,danimo/qt-creator