Ajax calls from the theme directory

You should never edit any files in the wp-admin directory. All ajax related to your theme, should be inside your theme directory. You can place your PHP code in any file, functions.php, or include some new file there you will retrive only ajax cals, that will be better.