from "cvs diff -uN" in the www module

This diff will also add <a href> links to menu items, enabling users to
open new tabs/windows from the menu items

Also, how do you want your patches? (I did cvs diff in the www root...)

/Sven
Index: JSZenMenu.js
===================================================================
RCS file: /var/cvs/FlightGear-0.9/www/JSZenMenu.js,v
retrieving revision 1.2
diff -u -r1.2 JSZenMenu.js
--- JSZenMenu.js	31 Dec 2007 16:22:57 -0000	1.2
+++ JSZenMenu.js	27 Feb 2008 10:33:04 -0000
@@ -52,7 +52,10 @@
 			tmpArr=new Array("<img src=\""+root+th+"/"+m.a[i].img+"\">",m.a[i].v,"<img src=\""+root+th+"/"+m.a[i].i2+"\">");
 			if(or==0) m.a[i].o=0;
 			var clic = "";
-			if(m.a[i].l!="#")clic=" --- ";
+			if(m.a[i].l!="#"){
+				clic=" --- ";
+				tmpArr[1]='<a href="'+m.a[i].l+'">' + tmpArr[1] + '</a>';
+			}
 			sstr+=s2+"<tr id=\""+m.a[i].Id+n+"\" class=\""+th+"\" ::: "+clic+" >";
 			if(m.a[i].a!=null){
 				if(or==0)
@@ -210,7 +213,11 @@
 	gen(m,th,name,orient,root);
 	if (m.a!=null){
 		var obj=getObj(id);
-		obj.innerHTML=sstr.replace(/---/g," onClick=\"hidems("+name+",'"+th+"',this.id,'"+name+"');\" ").replace(/:::/g," onMouseOver=\"playMenu("+name+",this.id,'"+th+"','"+name+"');\"  ");
+		var str = sstr;
+		str=str.replace(/---/g," onClick=\"hidems("+name+",'"+th+"',this.id,'"+name+"');\" ");
+		str=str.replace(/:::/g," onMouseOver=\"playMenu("+name+",this.id,'"+th+"','"+name+"');\"  ");
+		obj.innerHTML=str;
+		//obj.innerHTML=sstr.replace(/---/g," onClick=\"hidems("+name+",'"+th+"',this.id,'"+name+"');\" ").replace(/:::/g," onMouseOver=\"playMenu("+name+",this.id,'"+th+"','"+name+"');\"  ");
 		getObj(p+m.a[0].Id+name).style.visibility='visible';
 		if(pos==null)pos='static';
 			getObj(p+m.a[0].Id+name).style.position=pos;
Index: ZMFGTheme/theme.css
===================================================================
RCS file: /var/cvs/FlightGear-0.9/www/ZMFGTheme/theme.css,v
retrieving revision 1.1
diff -u -r1.1 theme.css
--- ZMFGTheme/theme.css	21 Dec 2007 19:16:35 -0000	1.1
+++ ZMFGTheme/theme.css	27 Feb 2008 10:33:04 -0000
@@ -9,7 +9,7 @@
 }
 
 /* submenu text items */
-.ZMFGThemeTABLE, .ZMFGThemeTABLEV, .ZMFGThemeTABLEH, .ZMFGThemeTD {
+.ZMFGThemeTABLE, .ZMFGThemeTABLEV, .ZMFGThemeTABLEH, .ZMFGThemeTD, .ZMFGThemeTABLE a {
 	font-family:Verdana, Arial, Helvetica, sans-serif;
 	font-size:13px;
 	font-weight:bold;
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel

Reply via email to