England's Test match opener Zak Crawley says a shift in mentality has helped him to improve his form.