Please note that the post_Type query variable is not set for standard types (page, post and attachment, see WP_QUery class file line 2396 on trac), only for custom post types, so this is how you can test for each type,
add_filter( 'posts_where' , 'posts_where', 10, 2);
function posts_where( $args, $wp_query_obj ) {
$type = $wp_query_obj->query_vars['post_type'];
switch(true){
case 'any'==$type: //query any type (see codex for more details).
break;
case !empty($type) && is_array($type):
//multiple post types define
break;
case !empty($type):
//post type is a custom post.
//this is where you would check for your post type,
if ($type == 'property') {
$args .= ' AND latitude.meta_key="wp_gp_latitude" ';
$args .= ' AND longitude.meta_key="wp_gp_longitude" ';
}
break;
case $wp_query_obj->is_attachment():
//post type is empty but is a media.
$type="attachemnt";
break;
case $wp_query_obj->is_page():
//post type is empty but is a page.
$type="page";
break;
default:
//post type is empty and not an attachment nor a page, so is a post.
$type="post";
break;
}
return $where;
}
for more information on the WP_Query object and its methods, see the codex page.