Steelhead,
As long as your database supports the mysql_select_db thing you should be able to add the same user permissions from your forum to your gallery database. That would be the easy thing add that mysql user to the proguide_gallery database and then change the query in pppanel.php to this
mysql_select_db ("proguide_gallery")or die("Could not select database");
$query = "SELECT id,cat,title,bigimage,medsize FROM {$pp_prefix}photos WHERE userid = {$user['U_Number']} ORDER BY date DESC LIMIT $page,16";
$result = mysql_query($query);
$sth = $dbh -> do_query($query);
$numrows = $dbh -> total_rows($sth);