Flex Tree样式: 如何修改Tree的Icon

Categories: Flex; Tagged with: ; @ March 12th, 2009 10:50

image

可以通过设定Tree的样式来更改Tree的icon. 如下

		_treeLAAndSub = new Tree();
		_treeLAAndSub.iconField = "[email protected]#[email protected]#$";
		_treeLAAndSub.setStyle("folderClosedIcon", ImagesForActions.iconImport);	//文件夹关闭时
		_treeLAAndSub.setStyle("folderOpenIcon", ImagesForActions.iconExport);	//文件夹打开

		_treeLAAndSub.setStyle("defaultLeafIcon", ImagesForActions.iconCopy);	// 叶子
		_treeLAAndSub.setStyle("disclosureOpenIcon", ImagesForActions.iconRemove);	//文件夹打开时旁边的图示
		_treeLAAndSub.setStyle("disclosureClosedIcon", ImagesForActions.iconAdd);	//文件夹关闭时旁边的图示

<->



// Proudly powered by Apache, PHP, MySQL, WordPress, Bootstrap, etc,.