Question: I want to make a link that goes to wp-login.php for whatever domain I'm at now. Something like:

```
<a href="http://<script>document.write(document.domain);</script>/wp-login.php">Login</a>

```

But I don't know how to write / format that properly.

Answer: 
This block of code will add a button right next to the "Insert into post" one. When clicked, it will send selected images to WP editor, each wrapped inside your template HTML:

```
var wpMediaFramePost = wp.media.view.MediaFrame.Post;
wp.media.view.MediaFrame.Post = wpMediaFramePost.extend(
{
    mainInsertToolbar: function( view )
    {
        "use strict";

        wpMediaFramePost.prototype.mainInsertToolbar.call(this, view);

        var controller = this;

        this.selectionStatusToolbar( view );

        view.set( "customInsertIntoPost", {
            style: "primary",
            priority: 80,
            text: "Insert selected images into post",
            requires: { selection: true },

            click: function()
            {
                var state = controller.state(),
                    selection = state.get("selection")._byId,
                    template = _.template('<li><img src="<%= imagePath %>" alt="<%= altText %>" /></li>'),
                    output = "<ul>";

                _.each(selection, function( item )
                {
                    if( item.attributes.type === "image" )
                    {
                        output += template({
                            imagePath: item.attributes.sizes.full.url,
                            altText: item.attributes.alt
                        });
                    }
                });

                output += "</ul>";

                send_to_editor(output);
            }
        });
    }
});

```

Adding a custom button is not a problem. But selecting "all images" could be a bit tricky because WP 3.5 media browser loads attachments bit by bit. I'll look into it, but I recommend selecting attachments manually.
I do not have a full answer to your question, but here is a good start.
To customize the new Media Manager, you should study the javascript Backbone code in `wp-includes/js/media-views.js`. 
For exemple, here is a small plugin that adds a "Select All" button to the "Insert from URL" Toolbar :

`custom.php`:

```
add_action('admin_enqueue_scripts', 'custom_add_script');
function custom_add_script(){
    wp_enqueue_script('custom', plugins_url('custom.js', __FILE__), array('media-views'), false, true);
}

```

`custom.js`:

```
var originalToolbar = wp.media.view.Toolbar.Embed;
wp.media.view.Toolbar.Embed = originalToolbar.extend({
    // code modified from media-views.js, l 2500
    initialize: function() {

        this.options.items = _.defaults( this.options.items || {}, {
            // keep the original button
            select: {
                style:    'primary',
                text:     wp.media.view.l10n.insertIntoPost,
                priority: 80,
                click:    this.clickSelect,
                requires: false
            },
            // and add a new one
            selectAll: {
                text: 'Select All',
                style: 'primary',
                priority: 80,
                requires: false,
                click: this.selectAll
            }
        });

        wp.media.view.Toolbar.Select.prototype.initialize.apply( this, arguments );
    },

    selectAll: function(){
        console.log('select All');
    }
});

```

For the "Custom insert into post" button, I suggest to use the gallery shortcode instead. The UI already exist to select the desired images and insert the shortcode at the right place in tinymce. All you have to do is to write your own gallery shortcode format. 

Take a look at `gallery_shortcode` function in `wp-includes/media.php` and use the `post_gallery` filter.