[gui] separate ListView code