valadoc r25 - in trunk/src: doclets/devhelp/doclet doclets/html/doclet doclets/valadoc.org/doclet libvaladoc valadoc



Author: flobrosch
Date: Wed Dec 24 13:00:07 2008
New Revision: 25
URL: http://svn.gnome.org/viewvc/valadoc?rev=25&view=rev

Log:

minor fixes



Modified:
   trunk/src/doclets/devhelp/doclet/template.vala
   trunk/src/doclets/html/doclet/template.vala
   trunk/src/doclets/valadoc.org/doclet/template.vala
   trunk/src/libvaladoc/parser.vala
   trunk/src/valadoc/Makefile.am
   trunk/src/valadoc/valadoc.vala

Modified: trunk/src/doclets/devhelp/doclet/template.vala
==============================================================================
--- trunk/src/doclets/devhelp/doclet/template.vala	(original)
+++ trunk/src/doclets/devhelp/doclet/template.vala	Wed Dec 24 13:00:07 2008
@@ -185,10 +185,6 @@
 		this.devhelp = new DevhelpFormat ( settings.pkg_name, "" );
 	}
 
-	private string vala_file_package_name;
-	private bool visited_non_package = false;
-
-
 	public override void visit_package ( Package file ) {
 		string pkg_name = file.name;
 		string path = this.settings.get_real_path () + pkg_name + "/";

Modified: trunk/src/doclets/html/doclet/template.vala
==============================================================================
--- trunk/src/doclets/html/doclet/template.vala	(original)
+++ trunk/src/doclets/html/doclet/template.vala	Wed Dec 24 13:00:07 2008
@@ -70,7 +70,7 @@
 	}
 
 
-
+/*
 	private string get_full_path ( Basic element ) {
 		if ( element.name == null )
 			return "";
@@ -95,7 +95,7 @@
 		str.append_unichar ( '/' );
 		return str.str;
 	}
-
+*/
 	public Valadoc.Settings settings {
 		construct set;
 		protected get;
@@ -104,7 +104,7 @@
 	public override void initialisation ( Settings settings ) {
 		this.settings = settings;
 
-		var rt = DirUtils.create ( this.settings.path, 0777 );
+		DirUtils.create ( this.settings.path, 0777 );
 		this.langlet = new Valadoc.LangletIndex ( settings );
 	}
 
@@ -135,7 +135,7 @@
 
 		this.current_path = this.settings.path + this.package_name + "/";
 
-		var rt = DirUtils.create ( this.current_path, 0777 );
+		DirUtils.create ( this.current_path, 0777 );
 		GLib.FileStream sfile = GLib.FileStream.open ( this.current_path + "index.html", "w" );
 		this.write_file_header ( sfile, this.get_css_link ( ), file.name );
 		this.write_navi_file ( sfile, file, file );
@@ -148,7 +148,7 @@
 		this.current_path = null;
 	}
 
-
+/*
 	private bool is_depency ( string dep ) {
 		foreach ( string file in this.settings.files ) {
 			if ( dep == file )
@@ -156,7 +156,7 @@
 		}
 		return true;
 	}
-
+*/
 	private Gee.ArrayList<Package> files = new Gee.ArrayList<Package> ();
 	private Package source_package;
 
@@ -194,7 +194,7 @@
 
 	public override void visit_property ( Property prop ) {
 		string path = this.current_path + prop.name + "/";
-		var rt = DirUtils.create ( path, 0777 );
+		DirUtils.create ( path, 0777 );
 		this.directory_level++;
 
 		GLib.FileStream file = GLib.FileStream.open ( path + "index.html", "w");
@@ -210,7 +210,7 @@
 	public override void visit_constant ( Constant constant, ConstantHandler parent ) {
 		string path = this.current_path + constant.name + "/";
 
-		var rt = DirUtils.create ( path, 0777 );
+		DirUtils.create ( path, 0777 );
 		this.directory_level++;
 		GLib.FileStream file = GLib.FileStream.open ( path + "index.html", "w");
 		this.write_file_header ( file, this.get_css_link ( ), constant.name );
@@ -223,7 +223,7 @@
 
 	public override void visit_field ( Field field, FieldHandler parent ) {
 		string path = this.current_path + field.name + "/";
-		var rt = DirUtils.create ( path, 0777 );
+		DirUtils.create ( path, 0777 );
 		this.directory_level++;
 		GLib.FileStream file = GLib.FileStream.open ( path + "index.html", "w");
 		this.write_file_header ( file, this.get_css_link ( ), field.name );
@@ -236,7 +236,7 @@
 
 	public override void visit_delegate ( Delegate del ) {
 		string path = this.current_path + del.name + "/";
-		var rt = DirUtils.create ( path, 0777 );
+		DirUtils.create ( path, 0777 );
 
 		this.directory_level++;
 		GLib.FileStream file = GLib.FileStream.open ( path + "index.html", "w");
@@ -252,7 +252,7 @@
 		string path = this.current_path + sig.name + "/";
 		this.directory_level++;
 
-		var rt = DirUtils.create ( path, 0777 );
+		DirUtils.create ( path, 0777 );
 
 		GLib.FileStream file = GLib.FileStream.open ( path + "index.html", "w");
 		this.write_file_header ( file, this.get_css_link ( ), sig.name );
@@ -266,7 +266,7 @@
 
 	public override void visit_method ( Method m, Valadoc.MethodHandler parent ) {
 		string path = this.current_path + m.name + "/";
-		var rt = DirUtils.create ( path, 0777 );
+		DirUtils.create ( path, 0777 );
 
 		this.directory_level++;
 		GLib.FileStream file = GLib.FileStream.open ( path + "index.html", "w");
@@ -292,7 +292,7 @@
 			this.current_path = tmp;
 		}
 
-		var rt = DirUtils.create ( this.current_path, 0777 );
+		DirUtils.create ( this.current_path, 0777 );
 		GLib.FileStream file = GLib.FileStream.open ( this.current_path + "index.html", "w" );
 		this.write_file_header ( file, this.get_css_link ( ), ns.name );
 		this.write_navi_namespace ( file, ns );
@@ -321,7 +321,7 @@
 		this.directory_level++;
 
 		this.current_path += en.name + "/";
-		var rt = DirUtils.create ( this.current_path, 0777 );
+		DirUtils.create ( this.current_path, 0777 );
 
 		en.visit_enum_values ( this );
 		en.visit_methods ( this );
@@ -342,7 +342,7 @@
 		this.directory_level++;
 
 		this.current_path += errdom.name + "/";
-		var rt = DirUtils.create ( this.current_path, 0777 );
+		DirUtils.create ( this.current_path, 0777 );
 
 		errdom.visit_methods ( this );
 
@@ -362,7 +362,7 @@
 		this.directory_level++;
 
 		this.current_path += stru.name + "/";
-		var rt = DirUtils.create ( this.current_path, 0777 );
+		DirUtils.create ( this.current_path, 0777 );
 
 		stru.visit_construction_methods ( this );
 		stru.visit_methods ( this );
@@ -385,7 +385,7 @@
 		this.directory_level++;
 
 		this.current_path += cl.name + "/";
-		var rt = DirUtils.create ( this.current_path, 0777 );
+		DirUtils.create ( this.current_path, 0777 );
 
 		cl.visit_construction_methods ( this );
 		cl.visit_classes ( this );
@@ -414,7 +414,7 @@
 		this.directory_level++;
 
 		this.current_path += iface.name + "/";
-		var rt = DirUtils.create ( this.current_path, 0777 );
+		DirUtils.create ( this.current_path, 0777 );
 
 		iface.visit_classes ( this );
 		iface.visit_structs ( this );

Modified: trunk/src/doclets/valadoc.org/doclet/template.vala
==============================================================================
--- trunk/src/doclets/valadoc.org/doclet/template.vala	(original)
+++ trunk/src/doclets/valadoc.org/doclet/template.vala	Wed Dec 24 13:00:07 2008
@@ -91,7 +91,7 @@
 	public override void initialisation ( Settings settings ) {
 		this.settings = settings;
 
-		var rt = DirUtils.create ( this.settings.path, 0777 );
+		DirUtils.create ( this.settings.path, 0777 );
 		this.langlet = new Valadoc.LangletIndex ( settings );
 	}
 
@@ -109,7 +109,7 @@
 
 		string new_path = this.settings.path + package_name + "/";
 
-		var rt = DirUtils.create ( new_path, 0777 );
+		DirUtils.create ( new_path, 0777 );
 
 		GLib.FileStream nav = GLib.FileStream.open ( new_path + "navi.html", "w" );
 		this.write_navi_file ( nav, file, file );
@@ -137,7 +137,7 @@
 			this.current_path = tmp;
 		}
 
-		var rt = DirUtils.create ( this.current_path, 0777 );
+		DirUtils.create ( this.current_path, 0777 );
 
 		GLib.FileStream navi = GLib.FileStream.open ( this.current_path + "navi.html", "w" );
 		this.write_navi_namespace ( navi, ns );
@@ -165,7 +165,7 @@
 	public override void visit_interface ( Interface iface ) {
 		string old_path = this.current_path;
 		this.current_path += iface.name + "/";
-		var rt = DirUtils.create ( this.current_path, 0777 );
+		DirUtils.create ( this.current_path, 0777 );
 
 		iface.visit_classes ( this );
 		iface.visit_structs ( this );
@@ -193,7 +193,7 @@
 	public override void visit_class ( Class cl ) {
 		string old_path = this.current_path;
 		this.current_path += cl.name + "/";
-		var rt = DirUtils.create ( this.current_path, 0777 );
+		DirUtils.create ( this.current_path, 0777 );
 
 		cl.visit_construction_methods ( this );
 		cl.visit_classes ( this );
@@ -224,7 +224,7 @@
 	public override void visit_struct ( Struct stru ) {
 		string old_path = this.current_path;
 		this.current_path += stru.name + "/";
-		var rt = DirUtils.create ( this.current_path, 0777 );
+		DirUtils.create ( this.current_path, 0777 );
 
 		stru.visit_construction_methods ( this );
 		stru.visit_methods ( this );
@@ -252,7 +252,7 @@
 	public override void visit_error_domain ( ErrorDomain errdom ) {
 		string old_path = this.current_path;
 		this.current_path += errdom.name + "/";
-		var rt = DirUtils.create ( this.current_path, 0777 );
+		DirUtils.create ( this.current_path, 0777 );
 
 		errdom.visit_methods ( this );
 
@@ -274,7 +274,7 @@
 	public override void visit_enum ( Enum en ) {
 		string old_path = this.current_path;
 		this.current_path += en.name + "/";
-		var rt = DirUtils.create ( this.current_path, 0777 );
+		DirUtils.create ( this.current_path, 0777 );
 
 		en.visit_enum_values ( this );
 		en.visit_methods ( this );
@@ -296,7 +296,7 @@
 
 	public override void visit_property ( Property prop ) {
 		string path = this.current_path + prop.name + "/";
-		var rt = DirUtils.create ( path, 0777 );
+		DirUtils.create ( path, 0777 );
 
 		GLib.FileStream cname = GLib.FileStream.open ( path + "cname", "w" );
 		if ( prop.parent is Class ) {
@@ -318,7 +318,7 @@
 
 	public override void visit_constant ( Constant constant, ConstantHandler parent ) {
 		string path = this.current_path + constant.name + "/";
-		var rt = DirUtils.create ( path, 0777 );
+		DirUtils.create ( path, 0777 );
 
 		GLib.FileStream navi = GLib.FileStream.open ( path + "navi.html", "w" );
 		this.write_navi_constant ( navi, constant );
@@ -331,7 +331,7 @@
 
 	public override void visit_field ( Field field, FieldHandler parent ) {
 		string path = this.current_path + field.name + "/";
-		var rt = DirUtils.create ( path, 0777 );
+		DirUtils.create ( path, 0777 );
 
 		GLib.FileStream cname = GLib.FileStream.open ( path + "cname", "w" );
 		if ( field.parent is Class ) {
@@ -365,7 +365,7 @@
 
 	public override void visit_delegate ( Delegate del ) {
 		string path = this.current_path + del.name + "/";
-		var rt = DirUtils.create ( path, 0777 );
+		DirUtils.create ( path, 0777 );
 
 		GLib.FileStream cname = GLib.FileStream.open ( path + "cname", "w" );
 		cname.puts ( del.get_cname() );
@@ -382,7 +382,7 @@
 
 	public override void visit_signal ( Signal sig ) {
 		string path = this.current_path + sig.name + "/";
-		var rt = DirUtils.create ( path, 0777 );
+		DirUtils.create ( path, 0777 );
 
 		GLib.FileStream cname = GLib.FileStream.open ( path + "cname", "w" );
 		if ( sig.parent is Class ) {
@@ -404,8 +404,7 @@
 
 	public override void visit_method ( Method m, Valadoc.MethodHandler parent ) {
 		string path = this.current_path + m.name + "/";
-		string full_name = m.full_name ();
-		var rt = DirUtils.create ( path, 0777 );
+		DirUtils.create ( path, 0777 );
 
 		GLib.FileStream cname = GLib.FileStream.open ( path + "cname", "w" );
 		cname.puts ( m.get_cname () );

Modified: trunk/src/libvaladoc/parser.vala
==============================================================================
--- trunk/src/libvaladoc/parser.vala	(original)
+++ trunk/src/libvaladoc/parser.vala	Wed Dec 24 13:00:07 2008
@@ -970,7 +970,6 @@
 
 	private bool parse_cell_attribute ( ref TextPosition pos, ref TextVerticalPosition hpos, ref int size, ref int dsize ) {
 		weak string str = this.str.offset ( this.pos );
-		int startpos = this.pos;
 
 		if ( str.has_prefix ( ")(" ) ) {
 			pos = TextPosition.CENTER;
@@ -1181,7 +1180,6 @@
 					return ;
 				}
 				this.skip_newline ();
-				int reallinestartpos = this.pos;
 				this.next_nonspace_char ();
 				switch ( str[pos+1] ) {
 				case '\n':
@@ -1511,7 +1509,6 @@
 				}
 				break;
 			case '\n':
-				int linepos = this.pos;
 				this.skip_newline ();
 				this.next_nonspace_char ();
 

Modified: trunk/src/valadoc/Makefile.am
==============================================================================
--- trunk/src/valadoc/Makefile.am	(original)
+++ trunk/src/valadoc/Makefile.am	Wed Dec 24 13:00:07 2008
@@ -1,16 +1,48 @@
+# src/Makefile.am
+
 NULL =
 
-vapidir = $(datadir)/vala/vapi
 
-valadoc-1.0.vapi: ../libvaladoc/valadoc-1.0.vapi
-	cat ../libvaladoc/valadoc-1.0.vapi > valadoc-1.0.vapi
+AM_CFLAGS =                             \
+	-DPACKAGE_DATADIR=\"$(libdir)/valadoc/plugins/\" \
+	-DPACKAGE_VERSION=\"$(VERSION)\"    \
+	-I ../libvaladoc/                   \
+	$(GLIB_CFLAGS)                      \
+	$(LIBVALA_CFLAGS)                   \
+	$(GMODULE_CFLAGS)                   \
+	$(LIBGVC_CFLAGS)                    \
+	$(NULL)
+
+
+
+
+bin_PROGRAMS = valadoc
 
-dist_vapi_DATA =     \
-	valadoc-1.0.vapi \
-	valadoc-1.0.deps \
+BUILT_SOURCES = valadoc.vala.stamp
+
+valadoc_VALASOURCES = \
+	valadoc.vala      \
+    $(NULL)
+
+
+valadoc_SOURCES = \
+	$(valadoc_VALASOURCES:.vala=.c) \
+	$(valadoc_VALASOURCES:.vala=.h) \
 	$(NULL)
 
-dist_noinst_DATA = \
+
+valadoc_LDADD =                 \
+	../libvaladoc/libvaladoc.la \
+	$(GLIB_LIBS)                \
+	$(LIBVALA_LIBS)             \
+	$(GMODULE_LIBS)             \
+	$(LIBGVC_LIBS)              \
 	$(NULL)
 
 
+valadoc.vala.stamp: $(libvaladoc_VALASOURCES)
+	$(VALAC) -C --pkg gmodule-2.0 --pkg config --vapidir ../vapi --pkg valadoc-1.0 --basedir $(top_srcdir)/src/valadoc/ valadoc.vala --disable-non-null --save-temps $^
+	touch $@
+
+EXTRA_DIST = $(valadoc_VALASOURCES)  valadoc.vala.stamp 
+

Modified: trunk/src/valadoc/valadoc.vala
==============================================================================
--- trunk/src/valadoc/valadoc.vala	(original)
+++ trunk/src/valadoc/valadoc.vala	Wed Dec 24 13:00:07 2008
@@ -91,30 +91,6 @@
 		}
 	}
 
-	// remove
-	private Gee.ArrayList<string> sort_sources ( ) {
-		var to_doc = new Gee.ArrayList<string>();
-
-		if ( tsources != null ) {
-			foreach ( string str in this.tsources ) {
-				string rpath = realpath ( str );
-				if ( str.has_suffix ( ".vala" ) || str.has_suffix ( ".gs" ) )
-					this.sources.add ( str );
-				else
-					this.packages.add ( str );
-
-				to_doc.add ( rpath );
-			}
-		}
-
-		if ( tpackages != null ) {
-			foreach ( string str in this.tpackages ) {
-				this.packages.add ( str );
-			}
-		}
-
-		return to_doc;
-	}
 /*
 	private bool check_doclet_structure ( string realpath ) {
 		bool tmp = FileUtils.test ( realpath, FileTest.IS_DIR );



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]