<?xml version="1.0"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>Page comments</title>
		<link>http://www.ssbits.com/home/</link>
		<atom:link href="http://www.ssbits.com/home/" rel="self" type="application/rss+xml" />
		<description></description>

		
		<item>
			<title></title>
			<link>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_1252</link>
			<description>i feel the silverstripe admin ui needs to be improved in this regard, many CMS systems have right click options on the page tree and other places, making it much easier to add subpages, copy, delete, move and so on.
I allways recommend SS to my clients based on the fact that i love the interface, but then again, so much to improve still.
Looking at SS 3.0 alpha 2 it does not look like this is being improved, i really hope it is - wish i was better at PHP/ SilverStripe so i could contribute :-(

Thanks for yet another usefull post</description>
			<pubDate></pubDate>
			<dc:creator>RSSName</dc:creator>
			<guid>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_1252</guid>
		</item>
		
		<item>
			<title></title>
			<link>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_891</link>
			<description>Looking at this... I'm pondering...

This should be combined with a custom branding. I always use a name like ZZBranding (last in line, thus, my CSS etc. will always overrule any other setting).

There's lots of improvements to do with custom branding!
*article to come?*</description>
			<pubDate></pubDate>
			<dc:creator>RSSName</dc:creator>
			<guid>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_891</guid>
		</item>
		
		<item>
			<title></title>
			<link>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_460</link>
			<description>Hi Aram, 

Thanks for your reply! I will look into it</description>
			<pubDate></pubDate>
			<dc:creator>RSSName</dc:creator>
			<guid>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_460</guid>
		</item>
		
		<item>
			<title></title>
			<link>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_458</link>
			<description>Hi Jeroen,

I actually just copied the field definition from SiteTree::getCMSFields().

I'll add a snipped at some point to show you how to do it :)

Aram

</description>
			<pubDate></pubDate>
			<dc:creator>RSSName</dc:creator>
			<guid>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_458</guid>
		</item>
		
		<item>
			<title></title>
			<link>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_453</link>
			<description>Thanks, this comes in handy! I was wondering; how did you get the URLSegment field on your main tab?</description>
			<pubDate></pubDate>
			<dc:creator>RSSName</dc:creator>
			<guid>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_453</guid>
		</item>
		
		<item>
			<title></title>
			<link>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_431</link>
			<description>Awsome thanks Chris, your fixes are a massive improvement! Added to the post :)

The only one I left out was the full width of the tools as for some reason it was overflowing the sidebar over the blue divider and looked kind of messy and given that the tools form is limited in width anyway, I didn't feel it added any extra functionality.

Anyway thanks again, it's a actually now a pretty solid solution! 

Aram</description>
			<pubDate></pubDate>
			<dc:creator>RSSName</dc:creator>
			<guid>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_431</guid>
		</item>
		
		<item>
			<title></title>
			<link>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_430</link>
			<description>Must learn to fully test before I comment next time... One final issue is that the toolbar ends up full width and if you open up the insert link/image/flash dialog on the right the toolbar sits over the top of this. You could set the #sitetree_holder #TreeTools to some max-width value, or do what I have done which is to push the #contentPanel higher in the stacking order so it's on top:

#contentPanel {
	z-index: 100;
}</description>
			<pubDate></pubDate>
			<dc:creator>RSSName</dc:creator>
			<guid>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_430</guid>
		</item>
		
		<item>
			<title></title>
			<link>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_429</link>
			<description>Last comment, I promise :) I've just been messing around with this all morning...

After setting the margin-top with Javascript, call:
fixHeight_left();
To sort out the positioning of the Page Tree, Page Version History and Site Reports toggle things.

It also helps if onload the margin is set. This deals with x-browser/os issues with how big the toolbar is depending on font and select box sizes. Just putting it in document.ready doesn't seem to quite work so I've put it in that and then done a setTimout and it seems to work ok. FInal JS code:


function setSitetreeHolderMarginTop() {
	jQuery(&quot;#sitetree_holder&quot;).css(&quot;margin-top&quot;, jQuery(&quot;#TreeTools&quot;).height()+&quot;px&quot;);
	fixHeight_left();
}

jQuery('#TreeActions button').live('click', function() {
	setSitetreeHolderMarginTop();
});

jQuery(document).ready(function() {
	setTimeout('setSitetreeHolderMarginTop()', 1000);
});

Tested in Chrome and FF 3.6 on Mac.</description>
			<pubDate></pubDate>
			<dc:creator>RSSName</dc:creator>
			<guid>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_429</guid>
		</item>
		
		<item>
			<title></title>
			<link>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_428</link>
			<description>Looking at it again, it can be a margin-top instead of a border-top (I was using a border at the start to sue a colour to see what was happening).

So revise the stuff with border-top to:

#sitetree_holder {
	margin-top: 82px;
}

and

jQuery('#sitetree_holder').css('margin-top', jQuery('#TreeTools').height()+'px');</description>
			<pubDate></pubDate>
			<dc:creator>RSSName</dc:creator>
			<guid>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_428</guid>
		</item>
		
		<item>
			<title></title>
			<link>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_427</link>
			<description>Improvements to solve a few issues...

Revised CSS:
#sitetree_holder {
	border-top: 82px solid transparent;
}
#sitetree_holder #TreeTools {
	position: fixed;
	top: 64px;
	left: 4px;
}
#sitetree_holder #TreeTools form {
	width: 169px;
}

Create a Javascript file and include LeftAndMain::require_javascript(...)


jQuery('#TreeActions button').live('click', function() {
	jQuery('#sitetree_holder').css('border-top', jQuery('#TreeTools').height()+'px'+' solid transparent');
});

The tool bar remains full width no matter how wide #left is, and the scroll bar and sitetree remain present under it. The bit of Javascript resizes the top border depending on the height of the toolbar so there's no need to allow for extra padding/border. Note that I've only tested this in Chrome.

I had tried to do something like what you've done here in the past but it never worked. Thanks to you we have a solution.</description>
			<pubDate></pubDate>
			<dc:creator>RSSName</dc:creator>
			<guid>http://www.ssbits.com/snippets/2011/making-the-tree-tools-sticky/#PageComment_427</guid>
		</item>
		

	</channel>
</rss>