move snippet list generation to OnFileReadyToParse
add missing import and remove unused ones
style fixes; more comments