var imgList = new Array();
var vartextdata;

function initVar(){
  imgList[0] = new imgData( "imgList[0]", "../images/var/var01_01.jpg", 411, 600, "../images/var/svar01_01.jpg", "Turpan, Xinjiang China" );
  imgList[0].addImg( "../images/var/var01_02.jpg", 633, 436, "../images/var/svar01_02.jpg", "Turpan, Xinjiang China" );
  imgList[0].addImg( "../images/var/var01_03.jpg", 635, 436, "../images/var/svar01_03.jpg", "Turpan, Xinjiang China" );
  imgList[0].addImg( "../images/var/var01_04.jpg", 594, 436, "../images/var/svar01_04.jpg", "Turpan, Xinjiang China" );
  imgList[0].addImg( "../images/var/var01_05.jpg", 636, 436, "../images/var/svar01_05.jpg", "Turpan, Xinjiang China" );
  
  imgList[1] = new imgData( "imgList[1]", "../images/var/var02_01.jpg", 640, 436, "../images/var/svar02_01.jpg", "Xian, China" );
  imgList[1].addImg( "../images/var/var02_02.jpg", 640, 436, "../images/var/svar02_02.jpg", "Xian, China" );
  
  imgList[2] = new imgData( "imgList[2]", "../images/var/var03_01.jpg", 640, 436, "../images/var/svar03_01.jpg", "Laos" );
  imgList[2].addImg( "../images/var/var03_02.jpg", 640, 436, "../images/var/svar03_02.jpg", "Muang Sing, Laos" );
  imgList[2].addImg( "../images/var/var03_03.jpg", 408, 600, "../images/var/svar03_03.jpg", "Muang Sing, Laos" );
  imgList[2].addImg( "../images/var/var03_04.jpg", 640, 436, "../images/var/svar03_04.jpg", "Mekong River, Laos" );
  
  imgList[3] = new imgData( "imgList[3]", "../images/var/var04_01.jpg", 640, 436, "../images/var/svar04_01.jpg", "Myanmer" );
  imgList[3].addImg( "../images/var/var04_02.jpg", 640, 436, "../images/var/svar04_02.jpg", "Myanmer" );
  imgList[3].addImg( "../images/var/var04_03.jpg", 640, 436, "../images/var/svar04_03.jpg", "Myanmer" );
  imgList[3].addImg( "../images/var/var04_04.jpg", 640, 436, "../images/var/svar04_04.jpg", "Myanmer" );
  
  imgList[4] = new imgData( "imgList[4]", "../images/var/var05_01.jpg", 640, 436, "../images/var/svar05_01.jpg", "Angkor, Cambodia" );
  imgList[4].addImg( "../images/var/var05_02.jpg", 640, 436, "../images/var/svar05_02.jpg", "Angkor, Cambodia" );
  imgList[4].addImg( "../images/var/var05_03.jpg", 640, 436, "../images/var/svar05_05.jpg", "Angkor, Cambodia" );
  imgList[4].addImg( "../images/var/var05_04.jpg", 640, 436, "../images/var/svar05_04.jpg", "Angkor, Cambodia" );
  
  imgList[5] = new imgData( "imgList[5]", "../images/var/var06_01.jpg", 640, 436, "../images/var/svar06_01.jpg", "Toul Sleng Museum, Cambodia" );
  imgList[5].addImg( "../images/var/var06_02.jpg", 640, 436, "../images/var/svar06_02.jpg", "Toul Sleng Museum, Cambodia" );
  imgList[5].addImg( "../images/var/var06_03.jpg", 640, 436, "../images/var/svar06_03.jpg", "Toul Sleng Museum, Cambodia" );
  
  imgList[6] = new imgData( "imgList[6]", "../images/var/var07_01.jpg", 640, 436, "../images/var/svar07_01.jpg", "Saigon, Viet Nam" );
  
  imgList[7] = new imgData( "imgList[7]", "../images/var/var08_01.jpg", 640, 436, "../images/var/svar08_01.jpg", "Hanoi, Viet Nam" );
  imgList[7].addImg( "../images/var/var08_02.jpg", 640, 436, "../images/var/svar08_02.jpg", "Hanoi, Viet Nam"  );
  imgList[7].addImg( "../images/var/var08_03.jpg", 640, 436, "../images/var/svar08_03.jpg", "Hanoi, Viet Nam"  );
  imgList[7].addImg( "../images/var/var08_04.jpg", 640, 436, "../images/var/svar08_04.jpg", "Hanoi, Viet Nam"  );
  
  imgList[8] = new imgData( "imgList[8]", "../images/var/var09_01.jpg", 640, 436, "../images/var/svar09_01.jpg", "England" );
  imgList[8].addImg( "../images/var/var09_02.jpg", 408, 600, "../images/var/svar09_02.jpg", "London, England" );
  imgList[8].addImg( "../images/var/var09_03.jpg", 408, 600, "../images/var/svar09_03.jpg", "London, England" );
  imgList[8].addImg( "../images/var/var09_04.jpg", 640, 436, "../images/var/svar09_04.jpg", "Wales" );
  imgList[8].addImg( "../images/var/var09_05.jpg", 640, 436, "../images/var/svar09_05.jpg", "London, England" );
  imgList[8].addImg( "../images/var/var09_06.jpg", 408, 600, "../images/var/svar09_06.jpg", "England" );
  
  imgList[9] = new imgData( "imgList[9]", "../images/var/var10_01.jpg", 408, 600, "../images/var/svar10_01.jpg", "Edinburgh, Scotland" );
  imgList[9].addImg( "../images/var/var10_02.jpg", 408, 600, "../images/var/svar10_02.jpg", "Edinburgh, Scotland" );
  imgList[9].addImg( "../images/var/var10_03.jpg", 640, 436, "../images/var/svar10_03.jpg", "Edinburgh, Scotland" );
  imgList[9].addImg( "../images/var/var10_04.jpg", 408, 600, "../images/var/svar10_04.jpg", "Edinburgh, Scotland" );
  
  imgList[10] = new imgData( "imgList[10]", "../images/var/var11_01.jpg", 640, 436, "../images/var/svar11_01.jpg", "Paris, France" );
  imgList[10].addImg( "../images/var/var11_02.jpg", 640, 436, "../images/var/svar11_02.jpg", "Paris, France" );
  imgList[10].addImg( "../images/var/var11_03.jpg", 640, 436, "../images/var/svar11_03.jpg", "Paris, France" );
  imgList[10].addImg( "../images/var/var11_04.jpg", 640, 436, "../images/var/svar11_04.jpg", "Paris, France" );
  
  vartextdata = new displayText( "imgexp2", "imgexp1" );
  vartextdata.addData( "* Turpan, Xinjiang", 
                       "- September 1996", 
                       "The Uyghur oasis, where Buddhism and Islam crossed, on the Silk Route", 
                       "Photograph -", 
                       "Turfan is a nice touristy small city. There are many attractions in the oasis. This isn't a story about the famous city.\n" +
                       "I went to develop a monochrome file in Urumuqi. A laborer in a magazine that we trust saw the film and " +
                       "was thinking a moment. He asked me to come after 2 days. I came there in the day without any worry. He tell me to wait for a day.\n" +
                       "I received pictures. A monochrome might be merely a old fashion. A old is going to be dumped, it's natural.\n" +
                       "The boy and girl in Turpan who are drawn in the picture are sexy for me."
                     );
  vartextdata.addData( "* Xi'an, China", 
                       "- January 1997", 
                       "The gate city from Central Asia on the Silk Route", 
                       "The begining and the end -", 
                       "Someone left for the west, I arrived at the station from the west where my friends saw me off. " +
                       "I listened to news on a radio in a bus, A temperature was below zero in the former capital city. It was cold for me who was going to the south. " +
                       "I walked on the streets with a sense of nostalgia where Hui (Chinese Muslims) lives. " +
                       "I usually prefered Hui restaurant, Chinese, Uyghur when I was alone. " +
                       "It's thought that the origin was Arabic or Persian married with Chinese. I didn't have any friends of Hui, but their vague give me a relief also in the city. "
                     );
  vartextdata.addData( "* The north of Laos", 
                       "- January 1997", 
                       "Mountainous districts, where minorities are living", 
                       "In villages -", 
                       "They wore beautiful clothes. May I take a photo of you. When I asked about it, they requested money. I felt not so good. I dislike the my mind. " +
                       "If someone criticizes tourists for that they are behaving just like in zoo, he must know a arrogant mind first. " +
                       "I looked a part of the lives that were as same as others, and people have a feeling for beauties and others. " +
                       "Must know that everyone has a own history and culture. To smoke opium is one of the culture of them. " +
                       "I thought that strangers must not deny it. I didn't like a slovenly face of a man who was smoking. " +
                       "I am contradicting. There were normal and problems."
                     );
  vartextdata.addData( "* Myanmer", 
                       "- February 1997", 
                       "The complex country, which is between India and China, in the west of Indochina", 
                       "Tea and cigar -", 
                       ""
                     );
  vartextdata.addData( "* Angkor, Cambodia", 
                       "- March 1997", 
                       "Temples, were built between the 9th and 13th centuries by kings of Khmer", 
                       "Slaves -", 
                       ""
                     );
  vartextdata.addData( "* Toul Sleng Museum", 
                       "- March 1997", 
                       "The school, where the genocide was committed by the Khmer Rouge", 
                       "Selections -", 
                       ""
                     );
  vartextdata.addData( "* Saigon, Viet Nam", 
                       "- March 1997", 
                       "The largest city, the economic center in Viet Nam", 
                       "Attractions of Saigon -", 
                       ""
                     );
  vartextdata.addData( "* Hanoi, Viet Nam", 
                       "- March 1997", 
                       "The capital city in Viet Nam, in the North", 
                       "A Clumsy city -", 
                       ""
                     );
  vartextdata.addData( "* United Kingdom", 
                       "- July,August 2000", 
                       "The place, where Anglo-Saxon lives", 
                       "The destination -", 
                       ""
                     );
  vartextdata.addData( "* Edinburgh, Scotland", 
                       "- August 2000", 
                       "Festivals period in summer\n(The Fringe Festival and The Military Tattoo)",
                       "A street performer -", 
                       ""
                     );
  vartextdata.addData( "* Paris, France", 
                       "- August 2000", 
                       "The capital city of the independent country in West Europe", 
                       "Future -", 
                       ""
                     );
}
initVar();

varmenuid = "varmenu";
idmenusel = "varmenus";

function markMenu( index ){
  var obj1 = document.getElementById( idmenusel ).style;
  var obj2 = document.getElementById( varmenuid + (index+1) ).style;
  obj1.left = obj2.left;
}

var current_page = 0;
function showTitle( index ){
  vartextdata.showTitleonly( index );
}

function restoreTitle(){
  vartextdata.showTitle( current_page );
}
  
function showImg( index ){
  
  markMenu( index );
  vartextdata.showTitle( index, true );
  current_page = index;
  imgList[index].showTn( "picmenu", "#AA9773" );
  imgList[index].showImg( 0 );
}