~ubuntu-branches/ubuntu/trusty/monodevelop/trusty-proposed

« back to all changes in this revision

Viewing changes to src/addins/AspNet/MonoDevelop.AspNet/MonoDevelop.AspNet.Gui/BaseHtmlEditorExtension.cs

  • Committer: Package Import Robot
  • Author(s): Jo Shields
  • Date: 2013-05-12 09:46:03 UTC
  • mto: This revision was merged to the branch mainline in revision 29.
  • Revision ID: package-import@ubuntu.com-20130512094603-mad323bzcxvmcam0
Tags: upstream-4.0.5+dfsg
ImportĀ upstreamĀ versionĀ 4.0.5+dfsg

Show diffs side-by-side

added added

removed removed

Lines of Context:
38
38
 
39
39
using MonoDevelop.AspNet;
40
40
using MonoDevelop.AspNet.Parser;
41
 
using MonoDevelop.AspNet.Parser.Dom;
42
41
using MonoDevelop.AspNet.StateEngine;
43
42
using MonoDevelop.Html;
44
43
using MonoDevelop.DesignerSupport;
101
100
                protected override void GetElementCompletions (CompletionDataList list)
102
101
                {
103
102
                        XName parentName = GetParentElementName (0);
104
 
                        AddHtmlTagCompletionData (list, Schema, parentName.ToLower ());
 
103
                        AddHtmlTagCompletionData (list, Schema, parentName);
105
104
                        AddMiscBeginTags (list);
106
105
                        
107
106
                        //FIXME: don't show this after any elements
108
107
                        if (DocType == null)
109
 
                                list.Add ("!DOCTYPE", "md-literal", GettextCatalog.GetString ("Character data"));
 
108
                                list.Add ("!DOCTYPE", "md-literal", GettextCatalog.GetString ("Document type"));
110
109
                }
111
110
                
112
111
                protected override CompletionDataList GetDocTypeCompletions ()
145
144
                                return;
146
145
                        
147
146
                        if (parentName.IsValid) {
148
 
                                list.AddRange (schema.CompletionProvider.GetChildElementCompletionData (parentName.FullName));
 
147
                                list.AddRange (schema.CompletionProvider.GetChildElementCompletionData (parentName.FullName.ToLower ()));
149
148
                        } else {
150
149
                                list.AddRange (schema.CompletionProvider.GetElementCompletionData ());
151
150
                        }                       
155
154
                    XName tagName, Dictionary<string, string> existingAtts)
156
155
                {
157
156
                        //add atts only if they're not aready in the tag
158
 
                        foreach (CompletionData datum in schema.CompletionProvider.GetAttributeCompletionData (tagName.FullName))
 
157
                        foreach (var datum in schema.CompletionProvider.GetAttributeCompletionData (tagName.FullName.ToLower ()))
159
158
                                if (existingAtts == null || !existingAtts.ContainsKey (datum.DisplayText))
160
159
                                        list.Add (datum);
161
160
                }