Update file-gallery-media.js

add `attach` button to attachment view.
replace attachment template with new version by removing the exiting one and renaming a previously inserted new version.
(see file-gallery.php)
Update file-gallery.php

add replacement attachment template for media modals using `print_media_templates` hook.
Update file-gallery.css

add css for `attach` button in media modals, additional css for toggle unused currently
Update attachments.php

minor bug fix for response if two of two selected items are already attached.
Update file-gallery-media.js

force refresh of library view
Update file-gallery.php

integrate duplicate filtering for new media modals (filter modified to allow currently attached copies and hide the originals)
Update file-gallery.js

force media modal to refresh data to reflect changes to attachments
image
regress refresh code, handled in file-gallery-media.js
refresh view and reset selection on open to reflect possible attachment changes made via fg
Merge pull request #12 from shaddowgh/master

duplicate filtering and attachment indicator