<?xml version="1.0" ?>
<klip>
    <owner>
        <author>DevGalaxy.com</author>
        <copyright>Copyright (c) 2004-2005 DevGalaxy.com. All Rights Reserved</copyright>
        <email>admin@devgalaxy.com</email>
        <web>http://www.devgalaxy.com</web>
    </owner>
    <identity>
        <title>DevGalaxy.com - Latest Software Releases</title>
        <uniqueid>http://www.devgalaxy.com/feed/B4627E22</uniqueid>
        <version>http://www.devgalaxy.com</version>
        <lastmodified>2008.41.09:1041</lastmodified>
        <description>DevGalaxy.com - Latest Software Releases</description>
        <keywords>free download, upload, utilities, windows, mac, internet, macintosh, software, application, applications, app, downloadable, dl, shareware, freeware, demo, osx, linux, xp, windows, 95, 98, 2000, win, winfiles, file, files, downloads, zip, downloader, exe</keywords>
    </identity>
    <locations>
        <defaultlink>http://www.devgalaxy.com</defaultlink>
        <contentsource>http://www.devgalaxy.com/feed/rss_all.xml</contentsource>
        <icon>http://www.devgalaxy.com/feed/icon16.gif</icon>
        <banner>http://www.devgalaxy.com/feed/klip/banner.jpg</banner>
        <help />
        <kliplocation>http://www.devgalaxy.com/feed/devgalaxy.klip</kliplocation>
    </locations>
    <setup>
        <refresh>240</refresh>
        <referer />
        <country>us</country>
        <language>en</language>
        <codepage />
    </setup>
    <messages>
        <loading>DevGalaxy.com loading feed...</loading>
        <nodata>No data available.</nodata>
    </messages>	<klipscript>
		<![CDATA[

var categories = new Array (

	"+All Software Categories", "http://www.devgalaxy.com/feed/rss_all.xml",
	"Audio", "http://www.devgalaxy.com/feed/rss_audio.xml",
	"Business & Finance", "http://www.devgalaxy.com/feed/rss_business.xml",
	"Graphic & Photo", "http://www.devgalaxy.com/feed/rss_graphic.xml",
	"Desktop Enhancements", "http://www.devgalaxy.com/feed/rss_desktop.xml",
	"Developer Tools", "http://www.devgalaxy.com/feed/rss_developer.xml",
	"Drivers", "http://www.devgalaxy.com/feed/rss_drivers.xml",
	"Games", "http://www.devgalaxy.com/feed/rss_games.xml",
	"Home & Education", "http://www.devgalaxy.com/feed/rss_home.xml",
	"Internet & Communications", "http://www.devgalaxy.com/feed/rss_internet.xml",
	"IS/IT", "http://www.devgalaxy.com/feed/rss_isit.xml",
	"Mobile & PAD", "http://www.devgalaxy.com/feed/rss_mobile.xml",
	"Utilities", "http://www.devgalaxy.com/feed/rss_utilities.xml",
	"Video", "http://www.devgalaxy.com/feed/rss_video.xml",
	"Web Authoring", "http://www.devgalaxy.com/feed/rss_web.xml"
);

var checkbox_objects = new Array ();

function onLoad ()
{
	Setup.addTab ("Categories");

	Setup[0].addText ('Select from the following categories:');
	configured = (Prefs.getPref ('configured') == 'true');
	for (var i = 0; i < categories.length / 2; i++)
	{
		is_checked = (categories [2*i][0] == '+');
		if (!configured && is_checked)
		{
			Prefs.setPref ("cbx"+i, 'true');
		}
		checkbox_objects[i] = Setup[0].addCheckbox (is_checked?categories [2*i].substring (1):categories [2*i]);
		checkbox_objects[i].onClick = cbxClick;
		checkbox_objects[i].idx = i;
		checkbox_objects[i].checked = (configured?(Prefs.getPref ("cbx"+i) == 'true'):is_checked);
	}
}

function cbxClick (state)
{
	Prefs.setPref ('configured', 'true');
	Prefs.setPref ("cbx"+this.idx, (state?"true":"false"));
	for (var i = 0; i < Items.length; ++i)
	{
		if (Items[i].extra == '' + this.idx)
		{
			if (state)
			{
				Items[i].hidden = false;
				
			}
			else
			{
				Items[i].hidden = true;
			}
		}
	}
	if (state)
	{
		Klip.requestRefresh ();
	}
}

function onRefresh ()
{

	for (var i = 0; i < Items.length; i++)
	{
		Items[i].tagged = true;
	}
	result = false;
	for (var i = 0; i < checkbox_objects.length; i++)
	{
		if (checkbox_objects[i].checked)
		{
			result = getData (categories[2*i+1], ''+i) || result;
		}
	}
	return result;
}

function getData (url, idx)
{
	req = Engines.HTTP.newRequest (url);
	if (req.send ())
	{
		Engines.KlipFood.process (req.response);
		for (var i = 0; i < Items.length; i++)
		{
			if (!Items[i].tagged)
			{
				Items[i].extra = idx;
				Items[i].tagged = true;
			}
		}
		return true;
	}
	return false;
}
		]]>
	</klipscript></klip>

