Make Send/Receive dialog work on Linux

Reimplemented dialog without jQuery so that it works on Linux.