<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="http://www.fustrate.com/dev/sources/Other/modification.xsl"?>
<!DOCTYPE modification SYSTEM "http://www.simplemachines.org/xml/modification">
<modification xmlns="http://www.simplemachines.org/xml/modification" xmlns:smf="http://www.simplemachines.org/">
	<id>fustrate:null</id>
	<version>0</version>

	<file name="$themedir/Display.template.php">
		<operation>
			<search position="replace"><![CDATA[
					<img src="', $settings['images_url'], '/topic/', $context['poll']['is_locked'] ? 'normal_poll_locked' : 'normal_poll', '.gif" alt="" align="bottom" /> ', $txt['poll'], ']]></search>
			<add><![CDATA[
					<span class="normal_poll">', $context['poll']['is_locked'] ? '
						<span class="locked"></span>' : '', '
					</span> ', $txt['poll'], ']]></add>
		</operation>

		<operation>
			<search position="replace"><![CDATA[
					<img src="', $settings['images_url'], '/topic/', $context['class'], '.gif" align="bottom" alt="" />]]></search>
			<add><![CDATA[
					<span class="', $context['class_separated']['base'], '">', !empty($context['class_separated']['attributes']) ? '
						<span class="' . implode('_', $context['class_separated']['attributes']) . '"></span>' : '', '
					</span>]]></add>
		</operation>
	</file>

	<file name="$themedir/Help.template.php">
		<operation>
			<search position="replace"><![CDATA[
							<td class="windowbg2" valign="middle" align="center" width="5%"><img src="', $settings['images_url'], '/topic/my_normal_poll.gif" alt="" /></td>]]></search>
			<add><![CDATA[
							<td class="windowbg2" valign="middle" align="center" width="5%">
								<span class="normal_poll">
									<span class="my"></span>
								</span>
							</td>]]></add>
		</operation>

		<operation>
			<search position="replace"><![CDATA[
					<td class="smalltext" align="left" style="padding-top: 1ex;"><img src="', $settings['images_url'], '/topic/my_normal_post.gif" alt="" align="middle" />&nbsp; ', $txt['manual_index_normal_post'], '<br />
					<img src="', $settings['images_url'], '/topic/normal_post.gif" alt="" align="middle" />&nbsp; ', $txt['manual_index_normal_topic'], '<br />
					<img src="', $settings['images_url'], '/topic/hot_post.gif" alt="" align="middle" />&nbsp; ', $txt['manual_index_hot_post'], '<br />
					<img src="', $settings['images_url'], '/topic/veryhot_post.gif" alt="" align="middle" />&nbsp; ', $txt['manual_index_very_hot_post'], '</td>
					<td class="smalltext" align="left" valign="top" style="padding-top: 1ex;"><img src="', $settings['images_url'], '/topic/normal_post_locked.gif" alt="" align="middle" />&nbsp; ', $txt['manual_index_locked'], '<br />
					<img src="', $settings['images_url'], '/topic/normal_post_sticky.gif" alt="" align="middle" />&nbsp; ', $txt['manual_index_sticky'], '<br />
					<img src="', $settings['images_url'], '/topic/normal_poll.gif" alt="" align="middle" />&nbsp; ', $txt['manual_index_poll'], '</td>]]></search>
			<add><![CDATA[
					<td class="smalltext" align="left" style="padding-top: 1ex; line-height: 2em;">
						<span class="normal_post">
							<span class="my"></span>
						</span>&nbsp; ', $txt['manual_index_normal_post'], '<br />
						<span class="normal_post"></span>&nbsp; ', $txt['manual_index_normal_topic'], '<br />
						<span class="hot_post"></span>&nbsp; ', $txt['manual_index_hot_post'], '<br />
						<span class="veryhot_post"></span>&nbsp; ', $txt['manual_index_very_hot_post'], '
					</td>
					<td class="smalltext" align="left" valign="top" style="padding-top: 1ex; line-height: 2em;">
						<span class="normal_post">
							<span class="locked"></span>
						</span>&nbsp; ', $txt['manual_index_locked'], '<br />
						<span class="normal_post">
							<span class="sticky"></span>
						</span>&nbsp; ', $txt['manual_index_sticky'], '<br />
						<span class="normal_poll"></span>&nbsp; ', $txt['manual_index_poll'], '
					</td>]]></add>
		</operation>

		<operation>
			<search position="replace"><![CDATA[
					<td valign="middle" align="left" width="2%" style="padding-left: 6px;"><img src="', $settings['images_url'], '/topic/normal_post.gif" alt="" align="middle" /></td>]]></search>
			<add><![CDATA[
					<td valign="middle" align="left" width="2%" style="padding-left: 6px;">
						<span class="normal_post"></span>
					</td>]]></add>
		</operation>
	</file>

	<file name="$themedir/MessageIndex.template.php">
		<operation>
			<search position="replace"><![CDATA[
								<img src="', $settings['images_url'], '/topic/', $topic['class'], '.gif" alt="" />]]></search>
			<add><![CDATA[
								<span class="', $topic['class_separated']['base'], '">', !empty($topic['class_separated']['attributes']) ? '
									<span class="' . implode('_', $topic['class_separated']['attributes']) . '"></span>' : '', '
								</span>]]></add>
		</operation>

		<operation>
			<search position="replace"><![CDATA[
			echo '
			<p class="align_left smalltext">
				', !empty($modSettings['enableParticipation']) && $context['user']['is_logged'] ? '
				<img src="' . $settings['images_url'] . '/topic/my_normal_post.gif" alt="" align="middle" /> ' . $txt['participation_caption'] . '<br />' : '', '
				<img src="' . $settings['images_url'] . '/topic/normal_post.gif" alt="" align="middle" /> ' . $txt['normal_topic'] . '<br />
				<img src="' . $settings['images_url'] . '/topic/hot_post.gif" alt="" align="middle" /> ' . sprintf($txt['hot_topics'], $modSettings['hotTopicPosts']) . '<br />
				<img src="' . $settings['images_url'] . '/topic/veryhot_post.gif" alt="" align="middle" /> ' . sprintf($txt['very_hot_topics'], $modSettings['hotTopicVeryPosts']) . '
			</p>
			<p class="smalltext">
				<img src="' . $settings['images_url'] . '/icons/quick_lock.gif" alt="" align="middle" /> ' . $txt['locked_topic'] . '<br />' . ($modSettings['enableStickyTopics'] == '1' ? '
				<img src="' . $settings['images_url'] . '/icons/quick_sticky.gif" alt="" align="middle" /> ' . $txt['sticky_topic'] . '<br />' : '') . ($modSettings['pollMode'] == '1' ? '
				<img src="' . $settings['images_url'] . '/topic/normal_poll.gif" alt="" align="middle" /> ' . $txt['poll'] : '') . '
			</p>';]]></search>
			<add><![CDATA[
			echo '
			<p class="align_left smalltext">
				', !empty($modSettings['enableParticipation']) && $context['user']['is_logged'] ? '
				<span class="normal_post">
					<span class="my"></span>
				</span> ' . $txt['participation_caption'] . '<br />' : '', '
				<span class="normal_post"></span> ' . $txt['normal_topic'] . '<br />
				<span class="hot_post"></span> ' . sprintf($txt['hot_topics'], $modSettings['hotTopicPosts']) . '<br />
				<span class="veryhot_post"></span> ' . sprintf($txt['very_hot_topics'], $modSettings['hotTopicVeryPosts']) . '
			</p>
			<p class="smalltext">
				<img src="' . $settings['images_url'] . '/icons/quick_lock.gif" alt="" align="middle" /> ' . $txt['locked_topic'] . '<br />' . ($modSettings['enableStickyTopics'] == '1' ? '
				<img src="' . $settings['images_url'] . '/icons/quick_sticky.gif" alt="" align="middle" /> ' . $txt['sticky_topic'] . '<br />' : '') . ($modSettings['pollMode'] == '1' ? '
				<span class="normal_poll"></span> ' . $txt['poll'] : '') . '
			</p>';]]></add>
		</operation>
	</file>

	<file name="$themedir/Recent.template.php">
		<operation>
			<search position="replace"><![CDATA[
							<img src="', $settings['images_url'], '/topic/', $topic['class'], '.gif" alt="" />]]></search>
			<add><![CDATA[
							<span class="', $topic['class_separated']['base'], '">', !empty($topic['class_separated']['attributes']) ? '
								<span class="' . implode('_', $topic['class_separated']['attributes']) . '"></span>' : '', '
							</span>]]></add>
		</operation>

		<operation>
			<search position="replace"><![CDATA[
			<p class="smalltext align_left">
				', !empty($modSettings['enableParticipation']) ? '
				<img src="' . $settings['images_url'] . '/topic/my_normal_post.gif" alt="" align="middle" /> ' . $txt['participation_caption'] . '<br />' : '', '
				<img src="' . $settings['images_url'] . '/topic/normal_post.gif" alt="" align="middle" /> ' . $txt['normal_topic'] . '<br />
				<img src="' . $settings['images_url'] . '/topic/hot_post.gif" alt="" align="middle" /> ' . sprintf($txt['hot_topics'], $modSettings['hotTopicPosts']) . '<br />
				<img src="' . $settings['images_url'] . '/topic/veryhot_post.gif" alt="" align="middle" /> ' . sprintf($txt['very_hot_topics'], $modSettings['hotTopicVeryPosts']) . '
			</p>
			<p class="smalltext align_left">
				<img src="' . $settings['images_url'] . '/icons/quick_lock.gif" alt="" align="middle" /> ' . $txt['locked_topic'] . '<br />' . ($modSettings['enableStickyTopics'] == '1' ? '
				<img src="' . $settings['images_url'] . '/icons/quick_sticky.gif" alt="" align="middle" /> ' . $txt['sticky_topic'] . '<br />' : '') . ($modSettings['pollMode'] == '1' ? '
				<img src="' . $settings['images_url'] . '/topic/normal_poll.gif" alt="" align="middle" /> ' . $txt['poll'] : '') . '
			</p>]]></search>
			<add><![CDATA[
			<p class="smalltext align_left">
				', !empty($modSettings['enableParticipation']) ? '
				<span class="normal_post">
					<span class="my"></span>
				</span> ' . $txt['participation_caption'] . '<br />' : '', '
				<span class="normal_post"></span> ' . $txt['normal_topic'] . '<br />
				<span class="hot_post"></span> ' . sprintf($txt['hot_topics'], $modSettings['hotTopicPosts']) . '<br />
				<span class="veryhot_post"></span> ' . sprintf($txt['very_hot_topics'], $modSettings['hotTopicVeryPosts']) . '
			</p>
			<p class="smalltext align_left">
				<img src="' . $settings['images_url'] . '/icons/quick_lock.gif" alt="" align="middle" /> ' . $txt['locked_topic'] . '<br />' . ($modSettings['enableStickyTopics'] == '1' ? '
				<img src="' . $settings['images_url'] . '/icons/quick_sticky.gif" alt="" align="middle" /> ' . $txt['sticky_topic'] . '<br />' : '') . ($modSettings['pollMode'] == '1' ? '
				<span class="normal_poll">
					</span>
				</span> ' . $txt['poll'] : '') . '
			</p>]]></add>
		</operation>

		<operation>
			<search position="replace"><![CDATA[
							<img src="', $settings['images_url'], '/topic/', $topic['class'], '.gif" alt="" />]]></search>
			<add><![CDATA[
							<span class="', $topic['class_separated']['base'], '">', !empty($topic['class_separated']['attributes']) ? '
								<span class="' . implode('_', $topic['class_separated']['attributes']) . '"></span>' : '', '
							</span>]]></add>
		</operation>

		<operation>
			<search position="replace"><![CDATA[
			<p class="smalltext align_left">
				', !empty($modSettings['enableParticipation']) ? '
				<img src="' . $settings['images_url'] . '/topic/my_normal_post.gif" alt="" align="middle" /> ' . $txt['participation_caption'] . '<br />' : '', '
				<img src="' . $settings['images_url'] . '/topic/normal_post.gif" alt="" align="middle" /> ' . $txt['normal_topic'] . '<br />
				<img src="' . $settings['images_url'] . '/topic/hot_post.gif" alt="" align="middle" /> ' . sprintf($txt['hot_topics'], $modSettings['hotTopicPosts']) . '<br />
				<img src="' . $settings['images_url'] . '/topic/veryhot_post.gif" alt="" align="middle" /> ' . sprintf($txt['very_hot_topics'], $modSettings['hotTopicVeryPosts']) . '
			</p>
			<p class="smalltext align_left">
				<img src="' . $settings['images_url'] . '/icons/quick_lock.gif" alt="" align="middle" /> ' . $txt['locked_topic'] . '<br />' . ($modSettings['enableStickyTopics'] == '1' ? '
				<img src="' . $settings['images_url'] . '/icons/quick_sticky.gif" alt="" align="middle" /> ' . $txt['sticky_topic'] . '<br />' : '') . ($modSettings['pollMode'] == '1' ? '
				<img src="' . $settings['images_url'] . '/topic/normal_poll.gif" alt="" align="middle" /> ' . $txt['poll'] : '') . '
			</p>]]></search>
			<add><![CDATA[
			<p class="smalltext align_left">
				', !empty($modSettings['enableParticipation']) ? '
				<span class="normal_post">
					<span class="my"></span>
				</span> ' . $txt['participation_caption'] . '<br />' : '', '
				<span class="normal_post"></span> ' . $txt['normal_topic'] . '<br />
				<span class="hot_post"></span> ' . sprintf($txt['hot_topics'], $modSettings['hotTopicPosts']) . '<br />
				<span class="veryhot_post"></span> ' . sprintf($txt['very_hot_topics'], $modSettings['hotTopicVeryPosts']) . '
			</p>
			<p class="smalltext align_left">
				<img src="' . $settings['images_url'] . '/icons/quick_lock.gif" alt="" align="middle" /> ' . $txt['locked_topic'] . '<br />' . ($modSettings['enableStickyTopics'] == '1' ? '
				<img src="' . $settings['images_url'] . '/icons/quick_sticky.gif" alt="" align="middle" /> ' . $txt['sticky_topic'] . '<br />' : '') . ($modSettings['pollMode'] == '1' ? '
				<span class="normal_poll"></span> ' . $txt['poll'] : '') . '
			</p>]]></add>
		</operation>
	</file>

	<file name="$themedir/Search.template.php">
		<operation>
			<search position="replace"><![CDATA[
								<img src="', $settings['images_url'], '/topic/', $topic['class'], '.gif" alt="" /></td>]]></search>
			<add><![CDATA[
								<span class="', $topic['class_separated']['base'], '">', !empty($topic['class_separated']['attributes']) ? '
									<span class="' . implode('_', $topic['class_separated']['attributes']) . '"></span>' : '', '
								</span></td>]]></add>
		</operation>
	</file>

	<file name="$sourcedir/MessageIndex.php">
		<operation>
			<search position="replace"><![CDATA[
				$context['topics'][$row['id_topic']]['is_posted_in'] = true;
				$context['topics'][$row['id_topic']]['class'] = 'my_' . $context['topics'][$row['id_topic']]['class'];]]></search>
			<add><![CDATA[
				$context['topics'][$row['id_topic']]['is_posted_in'] = true;
				$context['topics'][$row['id_topic']]['class_separated']['attributes'] = array_merge(array('my'), $context['topics'][$row['id_topic']]['class_separated']['attributes']);]]></add>
		</operation>
	</file>

	<file name="$sourcedir/Recent.php">
		<operation>
			<search position="replace"><![CDATA[
				$context['topics'][$row['id_topic']]['is_posted_in'] = true;
				$context['topics'][$row['id_topic']]['class'] = 'my_' . $context['topics'][$row['id_topic']]['class'];]]></search>
			<add><![CDATA[
				$context['topics'][$row['id_topic']]['is_posted_in'] = true;
				$context['topics'][$row['id_topic']]['class_separated']['attributes'] = array_merge(array('my'), $context['topics'][$row['id_topic']]['class_separated']['attributes']);]]></add>
		</operation>
	</file>

	<file name="$sourcedir/Search.php">
		<operation>
			<search position="replace"><![CDATA[
	if ($output['posted_in'])
		$output['class'] = 'my_' . $output['class'];]]></search>
			<add><![CDATA[
	if ($output['posted_in'])
		$output['class_separated']['attributes'] = array_merge(array('my'), $output['class_separated']['attributes']);]]></add>
		</operation>
	</file>

	<file name="$sourcedir/Subs.php">
		<operation>
			<search position="replace"><![CDATA[
function determineTopicClass(&$topic_context)
{
	// Set topic class depending on locked status and number of replies.
	if ($topic_context['is_very_hot'])
		$topic_context['class'] = 'veryhot';
	elseif ($topic_context['is_hot'])
		$topic_context['class'] = 'hot';
	else
		$topic_context['class'] = 'normal';

	$topic_context['class'] .= $topic_context['is_poll'] ? '_poll' : '_post';

	if ($topic_context['is_locked'])
		$topic_context['class'] .= '_locked';

	if ($topic_context['is_sticky'])
		$topic_context['class'] .= '_sticky';

	// This is so old themes will still work.
	$topic_context['extended_class'] = &$topic_context['class'];
}]]></search>
			<add><![CDATA[
function determineTopicClass(&$topic_context)
{
	// Set topic class depending on locked status and number of replies.
	if ($topic_context['is_very_hot'])
		$topic_context['class'] = 'veryhot';
	elseif ($topic_context['is_hot'])
		$topic_context['class'] = 'hot';
	else
		$topic_context['class'] = 'normal';

	$topic_context['class'] .= $topic_context['is_poll'] ? '_poll' : '_post';

	$topic_context['class_separated']['base'] = $topic_context['class'];

	if ($topic_context['is_locked'])
	{
		$topic_context['class'] .= '_locked';
		$topic_context['class_separated']['attributes'][] = 'locked';
	}

	if ($topic_context['is_sticky'])
	{
		$topic_context['class'] .= '_sticky';
		$topic_context['class_separated']['attributes'][] = 'sticky';
	}

	// This is so old themes will still work.
	$topic_context['extended_class'] = &$topic_context['class'];
}]]></add>
		</operation>
	</file>

	<file name="$themedir/css/index.css">
		<operation>
			<search position="replace"><![CDATA[
.description, .plainbox
{
	padding: 0.5em 1em 1em 1em;
	font-size: 0.9em;
	line-height: 1.4em;]]></search>
			<add><![CDATA[
.description, .plainbox
{
	padding: 0.5em 1em 1em 1em;
	font-size: 0.9em;
	line-height: 2em;]]></add>
		</operation>

		<operation>
			<search position="end" />
			<add><![CDATA[
.veryhot_post, .hot_post, .normal_post, .veryhot_poll, .hot_poll, .normal_poll
{
	float: left;
	display: block;
	height: 20px;
	width: 30px;
}
.veryhot_post span, .hot_post span, .normal_post span, .veryhot_poll span, .hot_poll span, .normal_poll span
{
	display: block;
	height: 20px;
	width: 30px;
	margin: 0;
	padding: 0;
}

.veryhot_post
{
	background: url(../images/theme/topic_icons.png) no-repeat 0 0;
}
.hot_post
{
	background: url(../images/theme/topic_icons.png) no-repeat -40px 0;
}
.normal_post
{
	background: url(../images/theme/topic_icons.png) no-repeat -80px 0;
}
.veryhot_poll
{
	background: url(../images/theme/topic_icons.png) no-repeat -120px 0;
}
.hot_poll
{
	background: url(../images/theme/topic_icons.png) no-repeat -160px 0;
}
.normal_poll
{
	background: url(../images/theme/topic_icons.png) no-repeat -200px 0;
}
.my
{
	background: url(../images/theme/topic_icons.png) no-repeat -240px 0;
}
.locked
{
	background: url(../images/theme/topic_icons.png) no-repeat -280px 0;
}
.sticky
{
	background: url(../images/theme/topic_icons.png) no-repeat -320px 0;
}
.my_locked
{
	background: url(../images/theme/topic_icons.png) no-repeat -360px 0;
}
.my_sticky
{
	background: url(../images/theme/topic_icons.png) no-repeat -400px 0;
}
.locked_sticky
{
	background: url(../images/theme/topic_icons.png) no-repeat -440px 0;
}
.my_locked_sticky
{
	background: url(../images/theme/topic_icons.png) no-repeat -480px 0;
}]]></add>
		</operation>
	</file>
</modification>
