Git: Preserve check state for untracked files

Untracked files always appear last, so filename comparison fails for
them.

Change-Id: I6e0addaddec7ca423b3d63e3e71fe00dbc6ca95e
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>