var gAboutToggleState = true;
var gServicesToggleState = true;

function changeText(lang)
{	
	if (lang == 'he') 
	{
		document.getElementById('aboutText').innerHTML = 
		"<div id=\"aboutTextHebrew\" style=\"position:absolute; top:0px; left:0px; width:100%; height:100%;\">" +
				"<div id=\"iloopBlogEventMiddleBG\" style=\"background:url(./img/Blog_BG_Middle.png);position:absolute;left:-10px; top:33px;width:690px;height:550px;\">" +
				"</div>" +
				"<div id=\"iloopBlogEventBottomBG\" style=\"background:url(./img/Blog_BG_Bottom.png);position:absolute; left:-10px; top:583px;width:690px;height:58px;\">" +
				"</div>" +	
				"<div id=\"copyrightID\" style=\"position:absolute; top:138px; left:100px; width:100%; height:100%;\">" +
					"<p class=\"copyRight\">Copyright &copy; 2009 Mobile-Pond. All rights reserved</p>" +		
				"</div>" +							
				"<div style=\"position:absolute;left: 0px;top: -10px; width:660px; height:550px;\">" +							
						"<div style=\"padding: 10px 30px; width: 900px;\">" +
							"<div class=\"aboutTranslateSection\" style=\"position:absolute;left: 530px;top: 10px;\">" +
								"<a href=\"javascript:changeText('en');\" class=\"aboutTranslate\">English</a>" +
								"<font class=\"aboutTranslate\"> | </font>" +
								"<a href=\"javascript:changeText('he');\" class=\"aboutTranslate\">עברית</a>" +
							"</div>" +
							"<br/>" +
							"<font class=\"myTitle\">פרופיל החברה<br></font>" +
							"<font class=\"mobilePondTitleText\"><br>מובייל פונד</font>" +
							"<font class=\"mobilePondContentText\"> עוסקת בפיתוח אפליקציות למכשירי אייפון ואייפוד טאצ\'.<br> החברה יוצרת אפליקציות אייפון מקוריות וכן מספקת שירותי פיתוח עבור עסקים ויחידים. </font>" +
							"<font class=\"mobilePondTitleText\"><br><br>למובייל פונד</font>" +
							"<font class=\"mobilePondContentText\"> מעל שנה של ניסיון מוכח בפיתוח אפליקציות אייפון. אנו גאים במיוחד באפליקציה<br> המקורית שפיתחנו - Photogene. כלי מקצועי לעריכת תמונות באייפון. מאז ששוחררה לראשונה<br> לפני שנה, ממשיכה Photogene להיות אחד מיישומי הצילום האהובים והפופולריים ב-AppStore<br> ואף בילתה מספר שבועות בטבלת ה-top 25 של ארה\"בֿֿֿֿֿֿ. באפריל 2009 הצטרפה Photogene לנבחרת<br> המצומצמת של אפליקציות המככבות בפרסומות הטלוויזיה של אפל.</font>" +						
							"<a href=\"javascript:slideToggleElem('#boxAboutUs',true);\" class=\"readMoreLink\">" +
								"<br/><br/>+ קרא עוד" +				
							"</a>" +
							"<div id=\"boxAboutUs\">" +																
								"<font class=\"mobilePondTitleText\"><br><br>בנוסף לפיתוחים עצמאיים,</font>" +
								"<font class=\"mobilePondContentText\"> למובייל פונד ניסיון עשיר בפיתוח אפליקציות בהזמנה.<br> אנו מלווים את הלקוחות שלנו משלב האיפיון ועד שיחרור האפליקציה לחנות. מספקים ייעוץ שוטף<br> עוד בשלב התכנון הראשוני, ומקפידים על סטנדרט טכני גבוה בפיתוח עצמו. דוגמא מצויינת<br> לפרוייקט כזה הוא !Flood-It, משחק אסטרטגיה ממכר שפותח עבור חברת LabPixies.<br> האפליקציה רשמה מעל ל- 1.5 מליון הורדות וטיפסה למקום השני ברשימת האפליקציות<br> החינמיות המורדות ביותר בארה\"ב.</font>" +
								"<font class=\"mobilePondTitleText\"><br><br>מובייל פונד היא אחת החברות הראשונות</font>" +
								"<font class=\"mobilePondContentText\"> שהציעו שירותי פיתוח לאייפון ולה ניסיון ייחודי בפיתוח<br> מגוון של יישומים. עד כה פיתחה מובייל פונד 2 אפליקציות מקוריות (ועוד אחת בשלבי סיום)<br> וכ-5 אפליקציות בהזמנה. <br>מובייל פונד מונה 3 עובדים. החברה הוקמה ע\"י עומר שור - בעל נסיון של 12 שנים בפיתוח תוכנה,<br> מתוכם 5 שנים בפיתוח אפליקציות לסלולר. עד שנת 2008 הוא שימש כמוביל פרוייקטים<br> בסמסונג טלקום ישראל.</font>" +
							"</div>" +
							"<img id=\"separator\" src=\"./img/Separator_horiz.jpg\" style=\"position:absolute;left: 20px;top: 330px;\" border=\"0\"/>" +
							"<br/><br/><br/><br/><br/><br/><br/>" +
							"<font class=\"myTitle\">שירותים<br></font>" +
							"<font class=\"mobilePondTitleText\"><br/>מובייל פונד </font>" +
							"<font class=\"mobilePondContentText\">מציעה שירות של בניית אפליקציות אייפון ברמה גבוהה לפי הזמנה. <br/>כמו כן החברה מציעה שירותי ייעוץ והכוונה לחברות ויחידים המעוניינים לבנות<br/> ולשווק אפליקציות ב- AppStore.</font>" +														
							"<a href=\"javascript:slideToggleElem('#boxServices',false);\" class=\"readMoreLink\">" +
								"<br/><br/>+קרא עוד" +
							"</a>" +
							"<div id=\"boxServices\">" +
								"<font class=\"mobilePondTitleText\"><br/><br/>פיתוח לאייפון: <br/></font>" +
								"<font class=\"mobilePondContentText\">&nbsp;&nbsp;&nbsp;&nbsp;• ליווי החל משלב הרעיון. אנו מספקים ייעוץ טכני ראשוני וכן ייעוץ לגבי חוויית המשתמש:<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;כיצד לממש את הרעיון שלכם בצורה האופטימלית על הפלטפורמה הייחודית הזו.<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;• תכנון, מימוש ובדיקות. ביצוע פרויקט הפיתוח מתחילתו ועד סופו כולל עיצוב הממשק וה-GUI<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;ובקרת האיכות.<br/>" +									
									"&nbsp;&nbsp;&nbsp;&nbsp;• עזרה וליווי במהלך הגשת הפרוייקט לחנות.<br/>" +									
									"&nbsp;&nbsp;&nbsp;&nbsp;• תמיכה ושידרוגים לפרוייקטים קיימים והתאמתם לגירסאות תוכנה וחומרה חדשות מבית אפל.<br/>" +									 
								"</font>" +
								"<font class=\"mobilePondTitleText\"><br/><br/>ייעוץ והכוונה: <br/></font>" +
								"<font class=\"mobilePondContentText\">מעבר לצד הטכני של הפיתוח, מובייל פונד צברה ניסיון עשיר בלוגיסטיקות הכרוכות בעבודה<br/> מול אפל וה-AppStore. אנו מספקים שירותי ייעוץ והכוונה:<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;• בדיקה ראשונית האם פרוייקט מסויים הוא ישים מבחינה טכנית על האייפון.<br/>" +									
									"&nbsp;&nbsp;&nbsp;&nbsp;• ייעוץ לגבי עשה ואל תעשה בחנות. כיצד למזער את הסיכון שהאפליקציה תידחה ע\"י אפל.<br/>" +									 
									"&nbsp;&nbsp;&nbsp;&nbsp;• הכוונה ראשונית לצוות הפיתוח - כיצד מפתחים לאייפון? מאיפה מתחילים?<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;מהם כלי הפיתוח ומהם פרוצדורות ההרשמה.<br/>" +									
									"&nbsp;&nbsp;&nbsp;&nbsp;• ייעוץ שיווקי: מידע עיסקי על עולם ה-AppStore ועצות וטיפים כיצד לקדם את האפליקציה.<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;מהו המודל העיסקי המומלץ על מנת להפיק רווחים מקסימליים.<br/>" +
								"</font>" +
							"</div>" +	
						"</div>" +																
					"</div>" +						
				"</div><!-- end of slider dv-->" +							
			"</div><!-- end of aboutText -->";					
	} 
	else if(lang == 'en')
	{
		document.getElementById('aboutText').innerHTML = 
		"<div id=\"aboutText\" style=\"position:absolute; top:0px; left:0px; width:100%; height:100%;\">" +
				"<div id=\"iloopBlogEventMiddleBG\" style=\"background:url(./img/Blog_BG_Middle.png);position:absolute;left:-10px; top:33px;width:690px;height:550px;\">" +
				"</div>" +
				"<div id=\"iloopBlogEventBottomBG\" style=\"background:url(./img/Blog_BG_Bottom.png);position:absolute; left:-10px; top:583px;width:690px;height:58px;\">" +
				"</div>" +	
				"<div id=\"copyrightID\" style=\"position:absolute; top:138px; left:100px; width:100%; height:100%;\">" +
					"<p class=\"copyRight\">Copyright &copy; 2009 Mobile-Pond. All rights reserved</p>" +		
				"</div>" +							
				"<div style=\"position:absolute;left: 0px;top: -10px; width:660px; height:550px;\">" +
						"<div style=\"padding: 10px 30px; width: 900px;\">" +
							"<div class=\"aboutTranslateSection\" style=\"position:absolute;left: 530px;top: 10px;\">" +
								"<a href=\"javascript:changeText('en');\" class=\"aboutTranslate\">English</a>" +
								"<font class=\"aboutTranslate\"> | </font>" +
								"<a href=\"javascript:changeText('he');\" class=\"aboutTranslate\">עברית</a>" +
							"</div>" +
							"<br/>" +
							"<font class=\"myTitle\">About Us<br></font>" +
							"<font class=\"mobilePondTitleText\"><br/>Mobile Pond</font>" +
								"<font class=\"mobilePondContentText\">" +
									" designs and develops applications for iPhone and iPod Touch.<br/>" +
									"We create original iPhone apps, and also provide development services for companies<br/>and individuals.<br/>" +
								"</font>" +
								"<font class=\"mobilePondTitleText\"><br/>Mobile Pond</font>" +
								"<font class=\"mobilePondContentText\">" +
									" has more than 1 year of proven experience developing iPhone	applications.<br/>" +
									"We are very proud of our own developed application - Photogene, a professional tool<br/>" +
									"for editing photos on the iPhone. Since its release over a year ago, Photogene remained<br/>" +
									"one of the most popular and beloved photo apps in the AppStore – and has spent<br/>" +
									"several weeks in the top 25 paid apps. Photogene was also selected by Apple as one<br/>" +
									"of the extraordinary applications to be featured in their TV ads.<br/>" +
								"</font>" +						
							"<a href=\"javascript:slideToggleElem('#boxAboutUs',true);\" class=\"readMoreLink\">" +
								"<br/>+ Read more" +				
							"</a>" +
							"<div id=\"boxAboutUs\">" +																
								"<font class=\"mobilePondTitleText\"><br/>Besides our in-house developed applications,</font>" +
								"<font class=\"mobilePondContentText\">" +
									" we have lots of experience developing<br/>" +
									"custom projects. We provide the solutions that match our clients specifications and needs<br/>" +
									"with a commitment to the highest professional standards.<br/>" +
									"A great example would be Flood-It!, an addictive strategy game we developed for LabPixies<br/>" +
									"- a leading provider of personalized web gadgets. Flood-It! was downloaded by over 1.5<br/>" + 
									"million iPhone and iPod users and has made it to #2 in the top free charts of the US<br/>" + 
									"AppStore." + 
								"</font>" +
								"<font class=\"mobilePondTitleText\"><br/><br/>Having being among the first</font>" +
								"<font class=\"mobilePondContentText\"> to develop native iPhone applications we have a unique<br/>" + 
								"experience developing a variety of different apps.<br/>" + 
								"To date, Mobile-Pond has released 2 original apps to the AppStore (we have one more<br/>" +
								"in final stages of development) and 5 commissioned apps." + 
								"</font>" + 
								"<font class=\"mobilePondTitleText\"><br/><br/>Our team</font>" +
								"<font class=\"mobilePondContentText\"> consists of 3 employees. The company was founded by Omer Shoor. Omer has<br/>" + 
								"12 years of software development experience – over 5 of which in the mobile industry." + 
								"</font>" +
								"</font>" +
							"</div>" +
							"<img id=\"separator\" src=\"./img/Separator_horiz.jpg\" style=\"position:absolute;left: 20px;top: 330px;\" border=\"0\"/>" +
							"<br/><br/><br/><br/><br/>" +
							"<font class=\"myTitle\">Services<br></font>" +
							"<font class=\"mobilePondTitleText\"><br/>Mobile Pond</font>" +
							"<font class=\"mobilePondContentText\"> offers development services for building custom iPhone apps, as well as<br/></font>" + 
							"<font class=\"mobilePondContentText\">technical and marketing consulting. We can help you create a first class iPhone app<br/></font>" +
							"<font class=\"mobilePondContentText\">and publish it on the AppStore.</font>" +							
							"<a href=\"javascript:slideToggleElem('#boxServices',false);\" class=\"readMoreLink\">" +
								"<br/><br/>+ Read more" +
							"</a>" +
							"<div id=\"boxServices\">" +
								"<font class=\"mobilePondTitleText\"><br/><br/>➔ iPhone development<br/></font>" +
								"<font class=\"mobilePondContentText\">" +
									"Using our in-depth experience and knowledge, we can guide you through the process<br/>" +
									"of creating your own custom iPhone application:<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;• Application concept creation: turn your idea into an iPhone application.<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;We will help you to create the specifications for your project so you can get the most<br/>" +
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;out of the iPhone features and maximize the unique iPhone experience in a way<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;that will meet your product requirements.<br/>" +
									"&nbsp;&nbsp;&nbsp;&nbsp;• Complete development cycle of your product: from UI and GUI design, through<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;project implementation to QA and deployment.<br/>" +
									"&nbsp;&nbsp;&nbsp;&nbsp;• Application distribution and support: we will help you through the process of<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;publishing your application on the AppStore.<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;• Maintenance and new features: after a project is published, we can provide<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;ongoing maintenance services such as adding new functionality or adapting it to<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;new operating systems and devices from Apple.<br/>" + 
								"</font>" +
								"<font class=\"mobilePondTitleText\"><br/><br/>➔ Consulting<br/></font>" +
								"<font class=\"mobilePondContentText\">" +
									"Apart from the technological side of iPhone applications development, Mobile Pond<br/>" + 
									"has lots of experience with Apple's app store procedures and logistics.<br/>" + 
									"We can lead you in the right direction and help you understand every aspect of the<br/>" + 
									"iPhone application development cycle - as part of the process of creating your<br/>" + 
									"product with us or as a separated consultancy service.<br/>" + 
									"We provide impartial advice and information to our customers on the most important<br/>" + 
									"issues:<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;• Check the feasibility of your project and adapt it, if necessary, to fit the iPhone<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;platform. See if your idea is applicable and if it has a chance of being rejected<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from the app store.<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;• Technical research for iPhone development: We will tell you how to equip your<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;product with the most suitable technology.<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;• We can also help you get started with your own in-house development: how to<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;begin? What is the development environment? Where do I find on-line<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;resources? etc.<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;• Marketing information and best practice business models for maximizing your<br/>" + 
									"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;revenues from your apps.<br/>" +
								"</font>" +
							"</div>" +	
						"</div>" +																
					"</div>" +					
				"</div><!-- end of slider dv-->" +							
			"</div><!-- end of aboutText -->";	
	}		
	$('#boxAboutUs').hide();
    $('#boxServices').hide();	
	gAboutToggleState = true;
	gServicesToggleState = true;
}


$(document).ready(function()
{
  $('#boxAboutUs').hide();
  $('#boxServices').hide();
  $.preloadCssImages();  
});

function setAboutCategoryParams(middleHeight, bottomTop, copyrightTop, separatorTop, sliderHeight)
{
	$('#iloopBlogEventMiddleBG').animate({height: middleHeight});
	$('#iloopBlogEventBottomBG').animate({top: bottomTop});
	$('#copyrightID').animate({top: copyrightTop});
	$('#separator').animate({top: separatorTop});
	$('#slider').animate({height: sliderHeight});
}

function scaleAboutCategoryAboutUs()
{	
	setAboutCategoryParams(805,838,388,620,848);
}

function scaleAboutCategoryServices()
{	
	setAboutCategoryParams(1175,1208,768,330,1198);				
}

function restoreAboutCategory()
{	
	setAboutCategoryParams(550,583,138,330,540);				
}

function scaleAboutCategoryBothOpen()
{
	setAboutCategoryParams(1525,1558,1118,620,1548);
}

function slideToggleElem(elemID,isAbout)
{
	$(elemID).slideToggle();
	if(isAbout)
	{
		if(gAboutToggleState && gServicesToggleState)
		{
			scaleAboutCategoryAboutUs();
		}
		else if(gAboutToggleState && !gServicesToggleState)
		{
			scaleAboutCategoryBothOpen();
		}
		else if(!gAboutToggleState && !gServicesToggleState)
		{
			scaleAboutCategoryServices();
		}
		else
		{
			restoreAboutCategory();
		}
		gAboutToggleState = !gAboutToggleState;
	}
	else //services
	{
		if(gServicesToggleState && gAboutToggleState)
		{
			scaleAboutCategoryServices();
		}
		else if(gServicesToggleState && !gAboutToggleState)
		{
			scaleAboutCategoryBothOpen();
		}
		else if(!gServicesToggleState && !gAboutToggleState)
		{
			scaleAboutCategoryAboutUs();
		}
		else
		{
			restoreAboutCategory();
		}
		gServicesToggleState = !gServicesToggleState;
	}	
}			
