I'm trying to open a user specified file from a bash script, I'm using gnome-open at the moment but want the script to block on the open call till the default viewer is finished. For example:

#!/bin/bash
#some operation
gnome-open /tmp/$onlyfilename
#operate on changed file in /tmp

Can anyone suggest an alternative to gnome-open that blocks till the default viewer is finished instead of falling through to the next commands? Suggestions would be highly appreciated.