This maybe not Raspberry Pi specific.
You actually commented out listen_addresses
completely.
I'd try listen_addresses='*'
or set it to your DHCP or public IP. Then restart the postgres server.
http://www.cyberciti.biz/tips/postgres-allow-remote-access-tcp-connection.html