All pastes #405528 Raw Edit

Untitled

public text v1 · immutable
·published 2007-03-21 20:13 UTC
rendered paste body
public class ResourceFolderExtension: NodeBuilderExtension
{
	public override bool CanBuildNode (Type dataType)
	{
		return typeof(ResourceFolder).IsAssignableFrom (dataType);
	}

	public override void GetNodeAttributes (ITreeNavigator parentNode, object dataObject, ref NodeAttributes attributes)
	{
		if (parentNode.GetParentDataItem (typeof(TranslationProject), true) != null)
			attributes |= NodeAttributes.Hidden;
	}
}