Traditionally a router connects networks at the IP level (layer 3). A firewall can do the same but adds security policies to the mix.
I don't know that the terms really matter so much anymore as you can have a router that performs stateful security functions, firewalls that can route, and switches that can perform routing duties.
I guess where one would break out that this device is a router, that device is a firewall, etc comes with scale.
For example, one can collapse our border router and SSG firewall into a new SRX firewall chassis that we are deploying. We have deployed EX switches that work as both switch and router. We have deployed SRX firewalls that perform security duties, routing, and switch duties.
At a certain traffic load it makes sense to either purchase larger devices and at an even larger load it makes sense to scale the router being a routing device, the firewall being a security device, etc.
For example, an EX2200 can do some routing but you may not want to use it for full on BGP peering. A scenario like that might use a larger EX switch or you would go for a J/M/etc actual router.