diff --git a/ChangeLog b/ChangeLog index 87ce41c..7fc5ce6 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2006-01-16 Michael Hutchinson + + * config.in, INSTALL: update dependencies for new Toolbox + *config.in: check for missing build directories, check for installed_chrome.txt + 2005-09-17 Michael Hutchinson * INSTALL: updated instructions regarding Mozilla extensions diff --git a/INSTALL b/INSTALL index 60ec7b8..91eed4d 100644 --- a/INSTALL +++ b/INSTALL @@ -5,7 +5,7 @@ You will need: Gtk# 2.5.5.99 Gecko# 0.10 GCC 3.3 - Gtk+ 2.6.4 + developer headers + Gtk+ 2.6 + developer headers Mozilla 1.7.10 + developer headers Newer versions should work; if they don't, it's a bug. @@ -34,7 +34,7 @@ You can run AspNetEdit out of the build directory with the command make run -However, the Mozilla extension must be installed first, so this command is only useful for running updated builds of the Mono-based components without reinstalling the whole application. +However, the Mozilla extension *must* be installed first, so this command is only useful for running updated builds of the Mono-based components without reinstalling the whole application. diff --git a/configure.in b/configure.in index 793b03c..f1a1648 100644 --- a/configure.in +++ b/configure.in @@ -6,17 +6,32 @@ AM_MAINTAINER_MODE AC_PROG_INSTALL AC_PROG_CXX -dnl pkg-config +### Dependency version numbers + +MONO_REQUIRED_VERSION=1.1.9 +GTKSHARP_REQUIRED_VERSION=2.5.5.99 +GECKOSHARP_REQUIRED_VERSION=0.10 + +GTK_VERSION=2.6.0 +MOZILLA_VERSION=1.6 + + +### Check for pkg-config AC_PATH_PROG(PKG_CONFIG, pkg-config, no) if test "x$PKG_CONFIG" = "xno"; then AC_MSG_ERROR([You need to install pkg-config]) fi -dnl C# compiler +### Check mono version +PKG_CHECK_MODULES(MONO, mono >= $MONO_REQUIRED_VERSION) + +#Check for C# compiler AC_PATH_PROG(CSC, csc, no) AC_PATH_PROG(MCS, mcs, no) AC_PATH_PROG(MONO, mono, no) +### Find a c# compiler + CS="C#" if test "x$CSC" = "xno" -a "x$MCS" = "xno" ; then dnl AC_MSG_ERROR([You need to install a C# compiler]) @@ -33,25 +48,44 @@ fi AC_SUBST(MCS) - MCS_OPTIONS="-d:TRACE" AC_SUBST(MCS_OPTIONS) -dnl c# dependencies -GTKSHARP_REQUIRED_VERSION=2.3.5.99 -GECKOSHARP_REQUIRED_VERSION=0.10 + +### Check c# dependencies + PKG_CHECK_MODULES(GTKSHARP, gtk-sharp-2.0 >= $GTKSHARP_REQUIRED_VERSION) PKG_CHECK_MODULES(GECKOSHARP, gecko-sharp-2.0 >= $GECKOSHARP_REQUIRED_VERSION) -dnl c++ dependencies -GTK_VERSION=2.4.0 -MOZILLA_VERSION=1.6 +### Check c++ dependencies PKG_CHECK_MODULES(JSGLUEDEPS, mozilla-xpcom >= $MOZILLA_VERSION gtk+-2.0 >= $GTK_VERSION mozilla-gtkmozembed >= $MOZILLA_VERSION) -dnl Mozilla directory to install chrome +### Find the Mozilla directory to install chrome MOZILLA_HOME="`$PKG_CONFIG --variable=libdir mozilla-gtkmozembed`" AC_SUBST(MOZILLA_HOME) +AC_MSG_CHECKING(for installed-chrome.txt) +INSTALLED_CHROME="$MOZILLA_HOME/chrome/installed-chrome.txt" +if test -f "$INSTALLED_CHROME"; then + AC_MSG_RESULT(yes) + AC_SUBST(INSTALLED_CHROME) +else + AC_MSG_RESULT(no) + AC_MSG_ERROR([Your Mozilla installation has an unexpected structure]) +fi + +### Create build directories, as tarballs seem to ignore them despite being in svn +AC_MSG_CHECKING(for build directory) +if test -d build ; then + AC_MSG_RESULT(yes) +else + AC_MSG_RESULT(no) + echo "Creating build directories..." + mkdir build + mkdir build/lib +fi + + AC_OUTPUT([ Makefile diff --git a/src/aspnetedit/ChangeLog b/src/aspnetedit/ChangeLog new file mode 100644 index 0000000..b8583fc --- /dev/null +++ b/src/aspnetedit/ChangeLog @@ -0,0 +1,3 @@ +2006-01-16 Michael Hutchinson + + * SampleHost.cs: Refresh toolbox - no-one noticed breakage! diff --git a/src/aspnetedit/SampleHost.cs b/src/aspnetedit/SampleHost.cs index 3c49257..23ec111 100644 --- a/src/aspnetedit/SampleHost.cs +++ b/src/aspnetedit/SampleHost.cs @@ -202,7 +202,7 @@ namespace AspNetEdit.SampleHost toolboxService.AddToolboxItem (new TextToolboxItem ("", "Input [Submit]"), "Html"); toolboxService.AddToolboxItem (new TextToolboxItem ("", "Input [Reset]"), "Html"); toolboxService.AddToolboxItem (new TextToolboxItem ("", "Input [Button]"), "Html"); - toolbox.UpdateCategories (); + toolbox.Refresh (); #endregion diff --git a/src/aspnetedit/aspnetedit.mdp b/src/aspnetedit/aspnetedit.mdp index 51da703..46199c5 100644 --- a/src/aspnetedit/aspnetedit.mdp +++ b/src/aspnetedit/aspnetedit.mdp @@ -16,12 +16,14 @@ + + diff --git a/src/chrome/ChangeLog b/src/chrome/ChangeLog index b2b60c1..9d14139 100644 --- a/src/chrome/ChangeLog +++ b/src/chrome/ChangeLog @@ -1,3 +1,8 @@ +2006-01-16 Michael Hutchinson + + * Makefile.am: find installed-chrome.txt in correct location + + 2005-10-5 Michael Hutchinson * Makefile.am: Added .js files from Blago's reorganisation to the chrome deployment diff --git a/src/chrome/Makefile.am b/src/chrome/Makefile.am index 5816794..977fe49 100644 --- a/src/chrome/Makefile.am +++ b/src/chrome/Makefile.am @@ -1,6 +1,6 @@ packagename = aspdesigner chromedir = $(MOZILLA_HOME)/chrome/$(packagename) -chrome_install_file = /var/lib/mozilla/chrome/installed-chrome.txt +chrome_install_file = $(MOZILLA_HOME)/chrome/installed-chrome.txt chrome_install_text = "content,install,url,resource:/chrome/aspdesigner/content/" \ "locale,install,url,resource:/chrome/aspdesigner/locale/en-US/" @@ -23,12 +23,11 @@ locale_files = \ $(srcdir)/locale/contents.rdf install-data-hook: - if test -f $(chrome_install_file); then f=$(chrome_install_file); else f=/opt/mozilla/lib/chrome/installed-chrome.txt; fi; \ - cp $$f /tmp/chrome.old; \ - sudo bash -c "sed -e'/aspdesigner/d' /tmp/chrome.old > $$f"; \ + cp $(INSTALLED_CHROME) /tmp/chrome.old; \ + sudo bash -c "sed -e'/aspdesigner/d' /tmp/chrome.old > $(INSTALLED_CHROME)"; \ for CHRM in $(chrome_install_text); do \ - cp $$f /tmp/chrome.old; \ - sudo bash -c "sed -e'\$$a$$CHRM' /tmp/chrome.old > $$f"; \ + cp $(INSTALLED_CHROME) /tmp/chrome.old; \ + sudo bash -c "sed -e'\$$a$$CHRM' /tmp/chrome.old > $(INSTALLED_CHROME)"; \ rm /tmp/chrome.old; \ done; diff --git a/src/editor/AspNetEdit.Editor.ComponentModel/ChangeLog b/src/editor/AspNetEdit.Editor.ComponentModel/ChangeLog index eba5c9a..4645cb3 100644 --- a/src/editor/AspNetEdit.Editor.ComponentModel/ChangeLog +++ b/src/editor/AspNetEdit.Editor.ComponentModel/ChangeLog @@ -1,3 +1,7 @@ +2006-01-16 Michael Hutchinson + + * MenuCommandService.cs, WebFormPage.cs, Document.cs: Reduce trivial warnings + 2005-11-28 Michael Hutchinson * Document.cs, DesignerHost.cs: avoid duplicating controls in container when loading and unloading diff --git a/src/editor/AspNetEdit.Editor.ComponentModel/Document.cs b/src/editor/AspNetEdit.Editor.ComponentModel/Document.cs index f6c9df2..660bd39 100644 --- a/src/editor/AspNetEdit.Editor.ComponentModel/Document.cs +++ b/src/editor/AspNetEdit.Editor.ComponentModel/Document.cs @@ -77,10 +77,10 @@ namespace AspNetEdit.Editor.ComponentModel this.document = DeserializeAndAdd (reader.ReadToEnd ()); } catch (ParseException ex) { - this.document = string.Format ("

{0}

{1}

", ex.Title, ex.Message); + this.document = ConstructErrorDocument (ex.Title, ex.Message); } catch (Exception ex) { - this.document = string.Format ("

{0}

{1}

{2}

", "Error loading document", ex.Message, ex.StackTrace); + this.document = ConstructErrorDocument ("Error loading document", ex.Message + ex.StackTrace); } GetView (); @@ -367,7 +367,7 @@ namespace AspNetEdit.Editor.ComponentModel #endregion - private string ErrorDocument(string errorTitle, string errorDetails) + private string ConstructErrorDocument (string errorTitle, string errorDetails) { return "

" + errorTitle diff --git a/src/editor/AspNetEdit.Editor.ComponentModel/MenuCommandService.cs b/src/editor/AspNetEdit.Editor.ComponentModel/MenuCommandService.cs index b2cde47..c3acccf 100644 --- a/src/editor/AspNetEdit.Editor.ComponentModel/MenuCommandService.cs +++ b/src/editor/AspNetEdit.Editor.ComponentModel/MenuCommandService.cs @@ -105,7 +105,7 @@ namespace AspNetEdit.Editor.ComponentModel // Delegate doesn't accept the data pointer...?! this.x = x; this.y = y; - contextMenu.Popup(null, null, new MenuPositionFunc (positionFunc), new System.IntPtr (), 2, Gtk.Global.CurrentEventTime); + contextMenu.Popup(null, null, new MenuPositionFunc (positionFunc), 2, Gtk.Global.CurrentEventTime); } private void positionFunc (Gtk.Menu menu, out int x, out int y, out bool pushIn) diff --git a/src/editor/AspNetEdit.Editor.ComponentModel/WebFormPage.cs b/src/editor/AspNetEdit.Editor.ComponentModel/WebFormPage.cs index 4754236..6752961 100644 --- a/src/editor/AspNetEdit.Editor.ComponentModel/WebFormPage.cs +++ b/src/editor/AspNetEdit.Editor.ComponentModel/WebFormPage.cs @@ -44,7 +44,7 @@ namespace AspNetEdit.Editor.ComponentModel { internal class WebFormPage : System.Web.UI.Page { - private HttpRequest httpRequest; + //private HttpRequest httpRequest; public WebFormPage () { diff --git a/src/editor/AspNetEdit.Editor.Persistence/ChangeLog b/src/editor/AspNetEdit.Editor.Persistence/ChangeLog index a7313e5..97b14e1 100644 --- a/src/editor/AspNetEdit.Editor.Persistence/ChangeLog +++ b/src/editor/AspNetEdit.Editor.Persistence/ChangeLog @@ -1,3 +1,7 @@ +2006-01-16 Michael Hutchinson + + * DesignTimeParser.cs: Reduce trivial warnings + 2005-11-28 Michael Hutchinson * ServerControlParsingObject.cs: Add child collection objects to parent control diff --git a/src/editor/AspNetEdit.Editor.Persistence/DesignTimeParser.cs b/src/editor/AspNetEdit.Editor.Persistence/DesignTimeParser.cs index 2cf1907..62b585f 100644 --- a/src/editor/AspNetEdit.Editor.Persistence/DesignTimeParser.cs +++ b/src/editor/AspNetEdit.Editor.Persistence/DesignTimeParser.cs @@ -116,22 +116,22 @@ namespace AspNetEdit.Editor.Persistence break; case TagType.CodeRender: throw new NotImplementedException ("Code render expressions have not yet been implemented: " + location.PlainText); - break; + //break; case TagType.CodeRenderExpression: throw new NotImplementedException ("Code render expressions have not yet been implemented: " + location.PlainText); - break; + //break; case TagType.DataBinding: throw new NotImplementedException("Data binding expressions have not yet been implemented: " + location.PlainText); - break; + //break; case TagType.Directive: ProcessDirective (tagid, attributes); break; case TagType.Include: throw new NotImplementedException ("Server-side includes have not yet been implemented: " + location.PlainText); - break; + //break; case TagType.ServerComment: throw new NotImplementedException ("Server comments have not yet been implemented: " + location.PlainText); - break; + //break; case TagType.Tag: //TODO: don't do this for XHTML if ((string.Compare (tagid, "br", true) == 0) @@ -149,7 +149,7 @@ namespace AspNetEdit.Editor.Persistence break; case TagType.Text: throw new NotImplementedException("Text tagtypes have not yet been implemented: " + location.PlainText); - break; + //break; } } diff --git a/src/editor/AspNetEdit.Editor.UI/ChangeLog b/src/editor/AspNetEdit.Editor.UI/ChangeLog index 2814ac7..b536066 100644 --- a/src/editor/AspNetEdit.Editor.UI/ChangeLog +++ b/src/editor/AspNetEdit.Editor.UI/ChangeLog @@ -1,3 +1,8 @@ +2006-01-16 Michael Hutchinson + + * ToolboxItem.cs: cleanup redundant file + * RootDesignerView.cs: make exception more informative + 2005-11-28 Michael Hutchinson * Toolbox.cs: initial migration to GTK# TreeView @@ -8,4 +13,4 @@ 2005-09-18 Michael Hutchinson - * Toolbox.cs: Use System.Web.UI.ToolboxDataAttribute when inserting Web Controls, if present \ No newline at end of file + * Toolbox.cs: Use System.Web.UI.ToolboxDataAttribute when inserting Web Controls, if present diff --git a/src/editor/AspNetEdit.Editor.UI/RootDesignerView.cs b/src/editor/AspNetEdit.Editor.UI/RootDesignerView.cs index 7da4f88..6149eea 100644 --- a/src/editor/AspNetEdit.Editor.UI/RootDesignerView.cs +++ b/src/editor/AspNetEdit.Editor.UI/RootDesignerView.cs @@ -183,7 +183,7 @@ namespace AspNetEdit.Editor.UI internal void RenameControl (string oldName, string newName) { - throw new NotImplementedException (); + throw new NotImplementedException ("Renaming controls not supported yet"); } internal string GetDocument () diff --git a/src/editor/editor.mdp b/src/editor/editor.mdp index e536ab3..1a5051f 100644 --- a/src/editor/editor.mdp +++ b/src/editor/editor.mdp @@ -16,6 +16,10 @@ + + + + @@ -38,7 +42,6 @@ - @@ -57,6 +60,11 @@ + + + + + @@ -72,5 +80,6 @@ + \ No newline at end of file diff --git a/src/jscall/jscall.mdp b/src/jscall/jscall.mdp index 46d0d81..5e7de48 100644 --- a/src/jscall/jscall.mdp +++ b/src/jscall/jscall.mdp @@ -16,6 +16,10 @@ + + + + @@ -27,6 +31,10 @@ + + + + diff --git a/src/propertygrid/AspNetEdit.UI.Editors/StringEditor.cs b/src/propertygrid/AspNetEdit.UI.Editors/StringEditor.cs index 9555ced..3d630ad 100644 --- a/src/propertygrid/AspNetEdit.UI.Editors/StringEditor.cs +++ b/src/propertygrid/AspNetEdit.UI.Editors/StringEditor.cs @@ -75,13 +75,23 @@ namespace AspNetEdit.UI.PropertyEditors { //Catching all exceptions is bad, but converter can throw all sorts of exception //with invalid entries. We just want to ignore bad entries. + string text = ((Entry) sender).Text; try { - string text = ((Entry) sender).Text; //if value was null and new value is empty, leave as null if (!(text == "" && parentRow.PropertyValue== null)) parentRow.PropertyValue = parentRow.PropertyDescriptor.Converter.ConvertFromString (((Entry) sender).Text); } - catch (Exception ex) { } + catch (Exception ex) + { + //we want to give a helpful error message: even if we ignore these exceptions + //most of the time, the error may still be useful when debugging controls + System.Diagnostics.Trace.WriteLine ( + "PropertyGrid String Editor: TypeConverter could not convert string \"" + text + + "\" to " + parentRow.PropertyDescriptor.PropertyType.ToString () + + " for property \"" + parentRow.PropertyDescriptor.DisplayName + "\".\n" + + "Error details: "+ ex.Message + ); + } } public override bool DialogueEdit { diff --git a/src/propertygrid/propertygrid.mdp b/src/propertygrid/propertygrid.mdp index 4d8547d..2dd982c 100644 --- a/src/propertygrid/propertygrid.mdp +++ b/src/propertygrid/propertygrid.mdp @@ -16,6 +16,8 @@ + + @@ -43,6 +45,9 @@ + + +