Changeset 85 for branches


Ignore:
Timestamp:
04/25/05 03:50:03 (14 years ago)
Author:
yermol
Message:

Fixed exceptions on closed trace window.
each domain now opens it's own trace window.
updated README files and index.html

Location:
branches/unified_backend
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • branches/unified_backend/README_DEVELOPERS.txt

    r84 r85  
    138138that has been stripped. (this has served me extremely well in formVista development) 
    139139 
     140It's important to note that each domain Xinha is run on will open it's own 
     141debugging trace window. (for instance, if you are working on two copies on different 
     142servers they will not be able to share a single debugging window. This is because 
     143a script in one domain cannot write into a window opened by another domain). 
     144 
     145You should be aware that Xinha intecepts some events on reload or page change 
     146which means that there are debugging messages that are output by the currently 
     147loaded script on the page when you click reload or change pages. (This took me 
     148a while to track down). Often times I would close the trace window and then 
     149do a reload noticing exceptions listed in the javascript console. Took forever 
     150to figure out these exceptions were not being generated by the new page but  
     151instead by the old page. See DDT.prototype._ddt() in ddt.js for more insights. 
     152 
    140153---------------------------------------------------------- 
    141154                      Coding Style 
  • branches/unified_backend/RELEASE_NOTES.txt

    r84 r85  
    1414  useable.  
    1515 
     16. a separate popup trace window is opened for each domain to avoid: 
     17 
     18  Error: uncaught exception: Permission denied to get property Window.DDT_STATUS 
     19 
    1620. the debug buttons have been removed. 
    1721 
     
    2226BUGS/ISSUES 
    2327 
    24 . under FireFox the popup debugging window is not well formed and produces 
    25   an error. 
     28. this code has not been tested using MSIE. 
    2629 
    27 . there is a javascript exception in the popup trace window support. 
    28  
    29 . this code has not been tested using MSIE. 
  • branches/unified_backend/ddt.js

    r84 r85  
    4545//      .       now uses a popup window for all messages. 
    4646//              writing to a textarea was simply too slow. 
     47// 
     48// 2005-04-24 YmL: 
     49// .    popup window name now includes location.host so we can have multiple 
     50//              instance of Xinha running on different domains. Avoids: 
     51// 
     52//      Error: uncaught exception: Permission denied to get property Window.DDT_STATUS 
     53// .    setting the title of the debug window so you can tell which domain it refers to. 
    4754// ----------------------------- 
    4855 
     
    106113        { 
    107114 
    108         // open the popup window 
    109  
    110         this.popup = window.open( "", "ddt_popup", 
     115        // open the popup window.  
     116        // 
     117        // IMPORTANT: because we are likely to copy a debugging version of Xinha  
     118        // onto different sites and possibly run them at the same time, each domain  
     119        // instance of Xinha will need it's own popup window .. this is because one  
     120        // domain cannot write to a window opened by another domain.  
     121        // 
     122        // We'll just use the hostname here to make the window name unique. 
     123 
     124        this.popup = window.open( "", "ddt_popup_" + location.host, 
    111125                              "toolbar=no,menubar=no,personalbar=no,width=800,height=450," + 
    112126                              "scrollbars=no,resizable=yes,modal=yes,dependable=yes"); 
     
    115129        // sharing the same window. 
    116130 
    117         if ( typeof this.popup.document.getElementsByTagName("p")[0] == 'undefined' ) 
    118                 { 
    119  
    120                 var content = "<html><body><p>DDT</p><p><a href=\"javascript:document.write( '<hr>');\">ADD SEPARATOR</a></p></body></html>"; 
     131        if ( typeof this.popup.DDT_STATUS == 'undefined' ) 
     132                { 
     133 
     134                var content = "<html><head><title>Trace Messages for '" + location.host + "'</title></head><body><p>DDT</p><p><a href=\"javascript:document.write( '<hr>');\">ADD SEPARATOR</a></p></body></html>"; 
    121135                this.popup.document.write( content ); 
    122136 
     
    126140                this.popup.document.body.appendChild( header ); 
    127141 
     142                this.popup.DDT_STATUS = "ok"; 
     143 
    128144                }       // end of if the popup document hadn't been created. 
    129145 
     
    175191if ( this.state == "on" ) 
    176192        { 
    177         this.popup.document.write( "(" + this.name + ") " + file + ":" + line + " - " + msg + "<br>\n" ); 
     193 
     194        // fireFox will generate an exception if the window is closed. 
     195 
     196        try 
     197                { 
     198                this.popup.document.write( "(" + this.name + ") " + file + ":" + line + " - " + msg + "<br>\n" ); 
     199                } 
     200        catch( e ) 
     201                { 
     202 
     203                // chances are the window was closed. For the moment we'll ignore this. 
     204                // 
     205                // alert( "exception on write of message '" + msg + "' e== '" + e.toString() + "'" ); 
     206                } 
    178207        } 
    179208 
     
    192221{ 
    193222 
    194 this._ddt( "ddt.js","194", file, line, msg ); 
     223this._ddt( "ddt.js","208", file, line, msg ); 
    195224 
    196225for (var x in obj) 
  • branches/unified_backend/examples/simple_example.html

    r84 r85  
    4747 
    4848  startupDDT._ddtOn(); 
    49  
    5049  </script> 
    5150   
  • branches/unified_backend/htmlarea.js

    r84 r85  
    3131 
    3232// sections marked with DDT open and close brackets are stripped out by  
    33 // the make_runtime.sh utility. Individual _ddt() calls are also automatically 
     33// the make_runtime.php utility. Individual _ddt() calls are also automatically 
    3434// stripped out. 
    3535 
     
    20502050HTMLArea.getHTML = function(root, outputRoot, editor) 
    20512051  { 
     2052 
     2053  HTMLArea._ddt( "htmlarea.js","2073", "getHTML(): top" ); 
     2054 
    20522055  try 
    20532056    { 
     
    38843887HTMLArea.prototype.setMode = function(mode)  
    38853888  { 
     3889 
     3890  this.ddt._ddt( "htmlarea.js","3887", "setMode(): setting mode to '" + mode + "'" ); 
     3891 
    38863892  if (typeof mode == "undefined")  
    38873893    { 
     
    39613967  { 
    39623968 
    3963   this.ddt._ddt( "htmlarea.js","3963", "setFullHTML(): top" ); 
     3969  this.ddt._ddt( "htmlarea.js","3966", "setFullHTML(): top" ); 
    39643970 
    39653971  var save_multiline = RegExp.multiline; 
     
    40084014  { 
    40094015 
    4010   this.ddt._ddt( "htmlarea.js","4010", "registerPlugin(): top" ); 
     4016  this.ddt._ddt( "htmlarea.js","4013", "registerPlugin(): top" ); 
    40114017 
    40124018  var plugin = arguments[0]; 
     
    40304036  { 
    40314037 
    4032   this.ddt._ddt( "htmlarea.js","4032", "registerPlugin2(): top" ); 
     4038  this.ddt._ddt( "htmlarea.js","4035", "registerPlugin2(): top" ); 
    40334039 
    40344040  if (typeof plugin == "string") 
     
    40384044    { 
    40394045 
    4040          this.ddt._ddt( "htmlarea.js","4040", "registerPlugin2(): INTERNAL ERROR: plugin is undefined. " ); 
     4046         this.ddt._ddt( "htmlarea.js","4043", "registerPlugin2(): INTERNAL ERROR: plugin is undefined. " ); 
    40414047 
    40424048    /* FIXME: This should never happen. But why does it do? */ 
     
    41124118  var editor = this; 
    41134119 
    4114   this.ddt._ddt( "htmlarea.js","4114", "_wordClean(): top" ); 
     4120  this.ddt._ddt( "htmlarea.js","4117", "_wordClean(): top" ); 
    41154121 
    41164122  var stats =  
     
    42294235  // this.forceRedraw(); 
    42304236 
    4231   this.ddt._ddt( "htmlarea.js","4231", "_wordClean(): bottom" ); 
     4237  this.ddt._ddt( "htmlarea.js","4234", "_wordClean(): bottom" ); 
    42324238 
    42334239  this.updateToolbar(); 
     
    42444250  { 
    42454251 
    4246   this.ddt._ddt( "htmlarea.js","4246", "_clearFonts(): top" ); 
     4252  this.ddt._ddt( "htmlarea.js","4249", "_clearFonts(): top" ); 
    42474253   
    42484254  var D = this.getInnerHTML(); 
     
    42824288  { 
    42834289 
    4284   this.ddt._ddt( "htmlarea.js","4284", "_splitBlock(): top" ); 
     4290  this.ddt._ddt( "htmlarea.js","4287", "_splitBlock(): top" ); 
    42854291 
    42864292  this._doc.execCommand('formatblock', false, '<div>'); 
     
    42964302  { 
    42974303 
    4298   this.ddt._ddt( "htmlarea.js","4298", "forceRedraw(): top" ); 
     4304  this.ddt._ddt( "htmlarea.js","4301", "forceRedraw(): top" ); 
    42994305 
    43004306  this._doc.body.style.visibility = "hidden"; 
     
    43144320  { 
    43154321 
    4316   this.ddt._ddt( "htmlarea.js","4316", "focusEditor(): top _editMode is '" + this._editMode + "'" ); 
     4322  this.ddt._ddt( "htmlarea.js","4319", "focusEditor(): top _editMode is '" + this._editMode + "'" ); 
    43174323 
    43184324  switch (this._editMode)  
     
    43624368  { 
    43634369 
    4364   this.ddt._ddt( "htmlarea.js","4364", "_undoTakeSnapshot(): top" ); 
     4370  this.ddt._ddt( "htmlarea.js","4367", "_undoTakeSnapshot(): top" ); 
    43654371 
    43664372  ++this._undoPos; 
     
    43994405  { 
    44004406 
    4401   this.ddt._ddt( "htmlarea.js","4401", "undo(): top" ); 
     4407  this.ddt._ddt( "htmlarea.js","4404", "undo(): top" ); 
    44024408 
    44034409  if (this._undoPos > 0)  
     
    44184424  { 
    44194425 
    4420   this.ddt._ddt( "htmlarea.js","4420", "redo(): top" ); 
     4426  this.ddt._ddt( "htmlarea.js","4423", "redo(): top" ); 
    44214427 
    44224428  if (this._undoPos < this._undoQueue.length - 1)  
     
    44374443  { 
    44384444 
    4439   this.ddt._ddt( "htmlarea.js","4439", "disableToolbar(): top" ); 
     4445  this.ddt._ddt( "htmlarea.js","4442", "disableToolbar(): top" ); 
    44404446 
    44414447  if(typeof except == 'undefined') 
     
    44694475  { 
    44704476 
    4471   this.ddt._ddt( "htmlarea.js","4471", "enableToolbar(): top" ); 
     4477  this.ddt._ddt( "htmlarea.js","4474", "enableToolbar(): top" ); 
    44724478 
    44734479  this.updateToolbar(); 
     
    44864492  var ancestors = null; 
    44874493 
    4488   this.ddt._ddt( "htmlarea.js","4488", "updateToolbar(): top" ); 
     4494  this.ddt._ddt( "htmlarea.js","4491", "updateToolbar(): top" ); 
    44894495 
    44904496  if (!text)  
     
    45004506                    { 
    45014507 
    4502                          this.ddt._ddt( "htmlarea.js","4502", "updateToolbar(): INTERNAL ERROR" ); 
     4508                         this.ddt._ddt( "htmlarea.js","4505", "updateToolbar(): INTERNAL ERROR" ); 
    45034509 
    45044510          // hell knows why we get here; this 
     
    45824588                    { 
    45834589 
    4584                          this.ddt._ddt( "htmlarea.js","4584", "updateToolbar(): INTERNAL ERROR" ); 
     4590                         this.ddt._ddt( "htmlarea.js","4587", "updateToolbar(): INTERNAL ERROR" ); 
    45854591 
    45864592          // the impossible really happens. 
     
    48014807    } 
    48024808 
    4803   this.ddt._ddt( "htmlarea.js","4803", "updateToolbar(): end" ); 
     4809  this.ddt._ddt( "htmlarea.js","4806", "updateToolbar(): end" ); 
    48044810 
    48054811  }  // end of updateToolbar() 
     
    48174823  { 
    48184824 
    4819   this.ddt._ddt( "htmlarea.js","4819", "insertNodeAtSelection(): top" ); 
     4825  this.ddt._ddt( "htmlarea.js","4822", "insertNodeAtSelection(): top" ); 
    48204826 
    48214827  if (!HTMLArea.is_ie)  
     
    48904896  { 
    48914897 
    4892   this.ddt._ddt( "htmlarea.js","4892", "getParentElement(): top" ); 
     4898  this.ddt._ddt( "htmlarea.js","4895", "getParentElement(): top" ); 
    48934899 
    48944900  if (typeof sel == 'undefined') 
     
    49574963  { 
    49584964 
    4959   this.ddt._ddt( "htmlarea.js","4959", "getAllAncestors(): top" ); 
     4965  this.ddt._ddt( "htmlarea.js","4962", "getAllAncestors(): top" ); 
    49604966 
    49614967  var p = this.getParentElement(); 
     
    49834989  { 
    49844990 
    4985   this.ddt._ddt( "htmlarea.js","4985", "_getFirstAncestor(): top" ); 
     4991  this.ddt._ddt( "htmlarea.js","4988", "_getFirstAncestor(): top" ); 
    49864992 
    49874993  var prnt = this._activeElement(sel); 
     
    50385044  { 
    50395045 
    5040   this.ddt._ddt( "htmlarea.js","5040", "_activeElement(): top" ); 
     5046  this.ddt._ddt( "htmlarea.js","5043", "_activeElement(): top" ); 
    50415047 
    50425048  if(sel == null) return null; 
    50435049  if ( this._selectionEmpty(sel) )  
    50445050    { 
    5045          this.ddt._ddt( "htmlarea.js", "5046", "_activeElement(): _selectionEmpty returned true. Returning null" ); 
     5051         this.ddt._ddt( "htmlarea.js","5048", "_activeElement(): _selectionEmpty returned true. Returning null" ); 
    50465052    return null; 
    50475053         } 
     
    51015107      { 
    51025108 
    5103                 this.ddt._ddt( "htmlarea.js","5099", "_activeElement(): selection is not collapsed" ); 
     5109                this.ddt._ddt( "htmlarea.js","5106", "_activeElement(): selection is not collapsed" ); 
    51045110 
    51055111      if(sel.anchorNode.nodeType == 1) 
    51065112        { 
    5107                   this.ddt._ddt( "htmlarea.js","5099", "_activeElement(): nodeType is 1. Returning sel.anchorNode" ); 
     5113                  this.ddt._ddt( "htmlarea.js","5110", "_activeElement(): nodeType is 1. Returning sel.anchorNode" ); 
    51085114 
    51095115        return sel.anchorNode; 
     
    51115117      } 
    51125118 
    5113     this.ddt._ddt( "htmlarea.js","5099", "_activeElement(): bottom" ); 
     5119    this.ddt._ddt( "htmlarea.js","5116", "_activeElement(): bottom" ); 
    51145120 
    51155121    return null; 
     
    51275133  { 
    51285134 
    5129   this.ddt._ddt( "htmlarea.js","5117", "_selectionEmpty(): top" ); 
     5135  this.ddt._ddt( "htmlarea.js","5132", "_selectionEmpty(): top" ); 
    51305136 
    51315137  if (!sel)  
    51325138    { 
    5133          this.ddt._ddt( "htmlarea.js","5131", "_selectionEmpty(): no selection" ); 
     5139         this.ddt._ddt( "htmlarea.js","5136", "_selectionEmpty(): no selection" ); 
    51345140    return true; 
    51355141         } 
     
    51415147  else if(typeof sel.isCollapsed != 'undefined') 
    51425148    { 
    5143          this.ddt._ddt( "htmlarea.js", "5141", "_selectionEmpty(): isCollapsed" ); 
     5149         this.ddt._ddt( "htmlarea.js","5146", "_selectionEmpty(): isCollapsed" ); 
    51445150    return sel.isCollapsed; 
    51455151    } 
    51465152 
    5147   this.ddt._ddt( "htmlarea.js", "5141", "_selectionEmpty(): bottom. returning true." ); 
     5153  this.ddt._ddt( "htmlarea.js","5150", "_selectionEmpty(): bottom. returning true." ); 
    51485154 
    51495155  return true; 
     
    51605166  { 
    51615167 
    5162   this.ddt._ddt( "htmlarea.js","5143", "_getAncestorBlock(): top" ); 
     5168  this.ddt._ddt( "htmlarea.js","5165", "_getAncestorBlock(): top" ); 
    51635169 
    51645170  // Scan upwards to find a block level element that we can change or apply to 
     
    52175223  { 
    52185224 
    5219   this.ddt._ddt( "htmlarea.js","5200", "_createImplicitBlock(): top" ); 
     5225  this.ddt._ddt( "htmlarea.js","5222", "_createImplicitBlock(): top" ); 
    52205226 
    52215227  // expand it until we reach a block element in either direction 
     
    53635369  { 
    53645370 
    5365   this.ddt._ddt( "htmlarea.js","5346", "selectNodeContents(): top" ); 
     5371  this.ddt._ddt( "htmlarea.js","5368", "selectNodeContents(): top" ); 
    53665372 
    53675373  this.focusEditor(); 
     
    54245430  { 
    54255431 
    5426   this.ddt._ddt( "htmlarea.js","5407", "insertHTML(): top" ); 
     5432  this.ddt._ddt( "htmlarea.js","5429", "insertHTML(): top" ); 
    54275433 
    54285434  var sel = this._getSelection(); 
     
    54615467  { 
    54625468 
    5463   this.ddt._ddt( "htmlarea.js","5444", "surroundHTML(): top" ); 
     5469  this.ddt._ddt( "htmlarea.js","5466", "surroundHTML(): top" ); 
    54645470 
    54655471  var html = this.getSelectedHTML(); 
     
    54785484  { 
    54795485 
    5480   this.ddt._ddt( "htmlarea.js","5461", "getSelectedHTML(): top" ); 
     5486  this.ddt._ddt( "htmlarea.js","5483", "getSelectedHTML(): top" ); 
    54815487 
    54825488  var sel = this._getSelection(); 
     
    56385644  { 
    56395645 
    5640   this.ddt._ddt( "htmlarea.js","5621", "_insertImage(): top" ); 
     5646  this.ddt._ddt( "htmlarea.js","5643", "_insertImage(): top" ); 
    56415647 
    56425648  var editor = this;    // for nested functions 
     
    57215727  { 
    57225728 
    5723   this.ddt._ddt( "htmlarea.js","5704", "_insertTable(): top" ); 
     5729  this.ddt._ddt( "htmlarea.js","5726", "_insertTable(): top" ); 
    57245730 
    57255731  var sel = this._getSelection(); 
     
    58135819  { 
    58145820 
    5815   this.ddt._ddt( "htmlarea.js","5796", "_comboSelected(): top" ); 
     5821  this.ddt._ddt( "htmlarea.js","5818", "_comboSelected(): top" ); 
    58165822 
    58175823  this.focusEditor(); 
     
    58535859  { 
    58545860 
    5855   this.ddt._ddt( "htmlarea.js","5836", "execCommand(): top with cmdId '" + cmdID + "'" ); 
     5861  this.ddt._ddt( "htmlarea.js","5858", "execCommand(): top with cmdId '" + cmdID + "'" ); 
    58565862 
    58575863  var editor = this;    // for nested functions 
     
    59845990  { 
    59855991 
    5986   this.ddt._ddt( "htmlarea.js","5967", "_editorEvent(): top with event type '" + ev.type + "'" ); 
     5992  this.ddt._ddt( "htmlarea.js","5989", "_editorEvent(): top with event type '" + ev.type + "'" ); 
    59875993 
    59885994  var editor = this; 
     
    60096015    { 
    60106016 
    6011     this.ddt._ddt( "htmlarea.js","5992", "_editorEvent(): keyEvent" ); 
     6017    this.ddt._ddt( "htmlarea.js","6014", "_editorEvent(): keyEvent" ); 
    60126018 
    60136019         // loop over all the plugins and pass this event to any that have  
     
    60276033                  { 
    60286034 
    6029                   this.ddt._ddt( "htmlarea.js","6010", "_editorEvent(): keyEvent - invoking onKeyPress method in plugin '" + ( plugin.name ? plugin.name : "unknown" ) + "'" ); 
     6035                  this.ddt._ddt( "htmlarea.js","6032", "_editorEvent(): keyEvent - invoking onKeyPress method in plugin '" + ( plugin.name ? plugin.name : "unknown" ) + "'" ); 
    60306036                                                                                                                                                                                                                                                                                                                                  
    60316037        if (plugin.onKeyPress(ev)) 
    60326038          { 
    60336039 
    6034                          this.ddt._ddt( "htmlarea.js","6015", "_editorEvent(): keyEvent - onKeyPress() returned false. Returning false" ); 
     6040                         this.ddt._ddt( "htmlarea.js","6037", "_editorEvent(): keyEvent - onKeyPress() returned false. Returning false" ); 
    60356041          return false; 
    60366042                         } 
     
    60446050    { 
    60456051 
    6046          this.ddt._ddt( "htmlarea.js","6027", "_editorEvent(): control key key event" ); 
     6052         this.ddt._ddt( "htmlarea.js","6049", "_editorEvent(): control key key event" ); 
    60476053 
    60486054    var sel = null; 
     
    60556061      case 'a': 
    60566062 
    6057                   this.ddt._ddt( "htmlarea.js","6038", "_editorEvent(): cntrl-a select all" ); 
     6063                  this.ddt._ddt( "htmlarea.js","6060", "_editorEvent(): cntrl-a select all" ); 
    60586064 
    60596065        if (!HTMLArea.is_ie)  
     
    60746080      case 'b':  
    60756081                   
    6076                   this.ddt._ddt( "htmlarea.js","6057", "_editorEvent(): cntrl-b bold" ); 
     6082                  this.ddt._ddt( "htmlarea.js","6079", "_editorEvent(): cntrl-b bold" ); 
    60776083                  cmd = "bold";  
    60786084                  break; 
     
    60806086      case 'i':  
    60816087                   
    6082                   this.ddt._ddt( "htmlarea.js","6063", "_editorEvent(): cntrl-i italics" ); 
     6088                  this.ddt._ddt( "htmlarea.js","6085", "_editorEvent(): cntrl-i italics" ); 
    60836089                  cmd = "italic";  
    60846090                  break; 
     
    60866092      case 'u':  
    60876093                 
    6088                   this.ddt._ddt( "htmlarea.js","6069", "_editorEvent(): cntrl-u underline" ); 
     6094                  this.ddt._ddt( "htmlarea.js","6091", "_editorEvent(): cntrl-u underline" ); 
    60896095                  cmd = "underline";  
    60906096                  break; 
     
    60926098      case 's':  
    60936099                 
    6094                   this.ddt._ddt( "htmlarea.js","6075", "_editorEvent(): cntrl-s strikethrough" ); 
     6100                  this.ddt._ddt( "htmlarea.js","6097", "_editorEvent(): cntrl-s strikethrough" ); 
    60956101                  cmd = "strikethrough";  
    60966102                  break; 
     
    60986104      case 'l':  
    60996105                 
    6100                   this.ddt._ddt( "htmlarea.js","6081", "_editorEvent(): cntrl-l justify left" ); 
     6106                  this.ddt._ddt( "htmlarea.js","6103", "_editorEvent(): cntrl-l justify left" ); 
    61016107                  cmd = "justifyleft";  
    61026108                  break; 
     
    61046110      case 'e':  
    61056111                   
    6106                   this.ddt._ddt( "htmlarea.js","6087", "_editorEvent(): cntrl-e justify center" ); 
     6112                  this.ddt._ddt( "htmlarea.js","6109", "_editorEvent(): cntrl-e justify center" ); 
    61076113                  cmd = "justifycenter";  
    61086114                  break; 
     
    61106116      case 'r':  
    61116117                 
    6112                   this.ddt._ddt( "htmlarea.js","6093", "_editorEvent(): cntrl-r justify right" ); 
     6118                  this.ddt._ddt( "htmlarea.js","6115", "_editorEvent(): cntrl-r justify right" ); 
    61136119                  cmd = "justifyright";  
    61146120                  break; 
     
    61166122      case 'j':  
    61176123                 
    6118                   this.ddt._ddt( "htmlarea.js","6099", "_editorEvent(): cntrl-j justify full" ); 
     6124                  this.ddt._ddt( "htmlarea.js","6121", "_editorEvent(): cntrl-j justify full" ); 
    61196125                  cmd = "justifyfull";  
    61206126                  break; 
     
    61226128      case 'z':  
    61236129                 
    6124                   this.ddt._ddt( "htmlarea.js","6105", "_editorEvent(): cntrl-z undo" ); 
     6130                  this.ddt._ddt( "htmlarea.js","6127", "_editorEvent(): cntrl-z undo" ); 
    61256131                  cmd = "undo";  
    61266132                  break; 
     
    61286134      case 'y':  
    61296135                 
    6130                   this.ddt._ddt( "htmlarea.js","6111", "_editorEvent(): cntrl-y redo" ); 
     6136                  this.ddt._ddt( "htmlarea.js","6133", "_editorEvent(): cntrl-y redo" ); 
    61316137                  cmd = "redo";  
    61326138                  break; 
     
    61346140      case 'v':  
    61356141                 
    6136                   this.ddt._ddt( "htmlarea.js","6117", "_editorEvent(): cntrl-v paste" ); 
     6142                  this.ddt._ddt( "htmlarea.js","6139", "_editorEvent(): cntrl-v paste" ); 
    61376143                  if (HTMLArea.is_ie || editor.config.htmlareaPaste)  
    61386144                    {  
     
    61446150                 
    61456151                   
    6146                   this.ddt._ddt( "htmlarea.js","6127", "_editorEvent(): cntrl-n format block" ); 
     6152                  this.ddt._ddt( "htmlarea.js","6149", "_editorEvent(): cntrl-n format block" ); 
    61476153                  cmd = "formatblock";  
    61486154                  value = HTMLArea.is_ie ? "<p>" : "p";  
     
    61516157      case '0':  
    61526158                 
    6153                   this.ddt._ddt( "htmlarea.js","6134", "_editorEvent(): cntrl-O kill word" ); 
     6159                  this.ddt._ddt( "htmlarea.js","6156", "_editorEvent(): cntrl-O kill word" ); 
    61546160                  cmd = "killword";  
    61556161                  break; 
     
    61636169      case '6': 
    61646170 
    6165                   this.ddt._ddt( "htmlarea.js","6146", "_editorEvent(): cntrl-[1-6] heading" ); 
     6171                  this.ddt._ddt( "htmlarea.js","6168", "_editorEvent(): cntrl-[1-6] heading" ); 
    61666172        cmd = "formatblock"; 
    61676173        value = "h" + key; 
     
    61746180    if (cmd)  
    61756181           { 
    6176       this.ddt._ddt( "htmlarea.js","6157", "_editorEvent(): executing simple command '" + cmd + "'" ); 
     6182      this.ddt._ddt( "htmlarea.js","6179", "_editorEvent(): executing simple command '" + cmd + "'" ); 
    61776183      // execute simple command 
    61786184      this.execCommand(cmd, false, value); 
     
    62376243          { 
    62386244 
    6239                          this.ddt._ddt( "htmlarea.js","6220", "_editorEvent(): entered a space" ); 
     6245                         this.ddt._ddt( "htmlarea.js","6242", "_editorEvent(): entered a space" ); 
    62406246 
    62416247          if(s && s.isCollapsed && s.anchorNode.nodeType == 3 && s.anchorNode.data.length > 3 && s.anchorNode.data.indexOf('.') >= 0) 
     
    62806286          { 
    62816287 
    6282                          this.ddt._ddt( "htmlarea.js","6263", "_editorEvent(): keycode is '" + ev.keyCode + "' which (normal key) is '" + ev.which + "'" ); 
     6288                         this.ddt._ddt( "htmlarea.js","6285", "_editorEvent(): keycode is '" + ev.keyCode + "' which (normal key) is '" + ev.which + "'" ); 
    62836289 
    62846290                         // is it an escape character or ... 
     
    62986304                                // backspace or period?  
    62996305 
    6300             this.ddt._ddt( "htmlarea.js","6281", "_editorEvent(): normal key or backspace or period" ); 
     6306            this.ddt._ddt( "htmlarea.js","6303", "_editorEvent(): normal key or backspace or period" ); 
    63016307 
    63026308            this._unlinkOnUndo = false; 
     
    63096315              if (!a)  
    63106316                                    { 
    6311                                          this.ddt._ddt( "htmlarea.js","6292", "_editorEvent(): not an anchor" ); 
     6317                                         this.ddt._ddt( "htmlarea.js","6314", "_editorEvent(): not an anchor" ); 
    63126318                                         break; // not an anchor 
    63136319                                         } 
     
    63596365      case 13: // KEY enter 
    63606366 
    6361                  this.ddt._ddt( "htmlarea.js","6342", "_editorEvent(): enter key handling" ); 
     6367                 this.ddt._ddt( "htmlarea.js","6364", "_editorEvent(): enter key handling" ); 
    63626368 
    63636369        if (HTMLArea.is_gecko && !ev.shiftKey && this.config.mozParaHandler == 'dirty' ) 
     
    63716377      case 46: // KEY delete 
    63726378 
    6373                  this.ddt._ddt( "htmlarea.js","6354", "_editorEvent(): delete or backspace handling" ); 
     6379                 this.ddt._ddt( "htmlarea.js","6376", "_editorEvent(): delete or backspace handling" ); 
    63746380 
    63756381        if (HTMLArea.is_gecko && !ev.shiftKey)  
     
    63996405    }, 100); 
    64006406 
    6401   this.ddt._ddt( "htmlarea.js","6382", "_editorEvent(): bottom" ); 
     6407  this.ddt._ddt( "htmlarea.js","6404", "_editorEvent(): bottom" ); 
    64026408 
    64036409  };  // end of _editorEvent() 
     
    64116417HTMLArea.prototype.convertNode = function(el, newTagName)  
    64126418  { 
    6413   this.ddt._ddt( "htmlarea.js","6394", "convertNode(): top" ); 
     6419  this.ddt._ddt( "htmlarea.js","6416", "convertNode(): top" ); 
    64146420 
    64156421  var newel = this._doc.createElement(newTagName); 
     
    64576463  { 
    64586464 
    6459   this.ddt._ddt( "htmlarea.js","6440", "dom_checkBackspace(): top" ); 
     6465  this.ddt._ddt( "htmlarea.js","6462", "dom_checkBackspace(): top" ); 
    64606466 
    64616467  var self = this; 
     
    67246730  { 
    67256731 
    6726   this.ddt._ddt( "htmlarea.js","6707", "scrollToElement(): top" ); 
     6732  this.ddt._ddt( "htmlarea.js","6729", "scrollToElement(): top" ); 
    67276733 
    67286734  if(HTMLArea.is_gecko) 
     
    67596765HTMLArea.prototype.getHTML = function()  
    67606766  { 
     6767 
     6768  this.ddt._ddt( "htmlarea.js", "6768", "getHTML() - prototype version - top" ); 
     6769 
    67616770  var html = ''; 
    67626771  switch (this._editMode)  
     
    67976806  { 
    67986807 
    6799   this.ddt._ddt( "htmlarea.js","6780", "outwardHtml(): top" ); 
     6808  this.ddt._ddt( "htmlarea.js","6802", "outwardHtml(): top" ); 
    68006809 
    68016810  html = html.replace(/<(\/?)b(\s|>|\/)/ig, "<$1strong$2"); 
     
    68306839  { 
    68316840 
    6832   this.ddt._ddt( "htmlarea.js","6813", "inwardHtml(): top" ); 
     6841  this.ddt._ddt( "htmlarea.js","6835", "inwardHtml(): top" ); 
    68336842 
    68346843  // Midas uses b and i instead of strong and em, um, hello, 
     
    68646873  { 
    68656874 
    6866   this.ddt._ddt( "htmlarea.js","6847", "outwardSpecialReplacements(): top" ); 
     6875  this.ddt._ddt( "htmlarea.js","6869", "outwardSpecialReplacements(): top" ); 
    68676876 
    68686877  for(var i in this.config.specialReplacements) 
     
    68886897HTMLArea.prototype.inwardSpecialReplacements = function(html) 
    68896898  { 
    6890   this.ddt._ddt( "htmlarea.js","6871", "inwardSpecialReplacements(): top" ); 
     6899  this.ddt._ddt( "htmlarea.js","6893", "inwardSpecialReplacements(): top" ); 
    68916900 
    68926901  // alert("inward"); 
     
    69166925  { 
    69176926 
    6918   this.ddt._ddt( "htmlarea.js","6899", "fixRelativeLinks(): top" ); 
     6927  this.ddt._ddt( "htmlarea.js","6921", "fixRelativeLinks(): top" ); 
    69196928 
    69206929  if (typeof this.config.stripSelfNamedAnchors != 'undefined' && this.config.stripSelfNamedAnchors) 
     
    69626971  { 
    69636972 
    6964   this.ddt._ddt( "htmlarea.js","6945", "stripBaseURL(): top" ); 
     6973  this.ddt._ddt( "htmlarea.js","6967", "stripBaseURL(): top" ); 
    69656974 
    69666975  var baseurl = this.config.baseURL; 
     
    69906999  { 
    69917000 
    6992   this.ddt._ddt( "htmlarea.js","6973", "getInnerHTML(): top" ); 
     7001  this.ddt._ddt( "htmlarea.js","6995", "getInnerHTML(): top" ); 
    69937002 
    69947003  if(!this._doc.body) return ''; 
     
    70277036  { 
    70287037   
    7029   this.ddt._ddt( "htmlarea.js","7010", "setHTML(): top" ); 
     7038  this.ddt._ddt( "htmlarea.js","7032", "setHTML(): top" ); 
    70307039 
    70317040  switch (this._editMode)  
     
    70997108  { 
    71007109 
    7101   this.ddt._ddt( "htmlarea.js","7082", "_createRange(): top" ); 
     7110  this.ddt._ddt( "htmlarea.js","7104", "_createRange(): top" ); 
    71027111 
    71037112  if (HTMLArea.is_ie)  
     
    71357144  { 
    71367145 
    7137   this.ddt._ddt( "htmlarea.js","7118", "notifyOn(): top" ); 
     7146  this.ddt._ddt( "htmlarea.js","7140", "notifyOn(): top" ); 
    71387147 
    71397148  if(typeof this._notifyListeners[ev] == 'undefined') 
     
    71557164  { 
    71567165 
    7157   this.ddt._ddt( "htmlarea.js","7138", "notifyOf(): top" ); 
     7166  this.ddt._ddt( "htmlarea.js","7160", "notifyOf(): top" ); 
    71587167 
    71597168  if(this._notifyListeners[ev]) 
     
    71827191  { 
    71837192 
    7184   this.ddt._ddt( "htmlarea.js","7165", "_popupDialog(): top with url '" + url + "' action '" + action + "'" ); 
     7193  this.ddt._ddt( "htmlarea.js","7187", "_popupDialog(): top with url '" + url + "' action '" + action + "'" ); 
    71857194 
    71867195  Dialog(this.popupURL(url), action, init); 
     
    72757284  { 
    72767285 
    7277   this.ddt._ddt( "htmlarea.js","7258", "registerPlugins(): top" ); 
     7286  this.ddt._ddt( "htmlarea.js","7280", "registerPlugins(): top" ); 
    72787287 
    72797288  if(plugin_names) 
  • branches/unified_backend/index.html

    r72 r85  
    6262<p> 
    6363Xinha (pronounced like the <a class="ext-link" title="http://images.google.co.nz/images?q=xena&amp;hl=en&amp;btnG=Google+Search" href="http://images.google.co.nz/images?q=xena&amp;hl=en&amp;btnG=Google+Search">Warrior Princess</a>) stands for &#34;Xinha is not htmlarea&#34;.  It began as a stop-gap fork of the <a class="ext-link" title="http://InteractiveTools.com/" href="http://InteractiveTools.com/">InteractiveTools.Com</a> <a class="ext-link" title="http://www.htmlarea.com/" href="http://www.htmlarea.com/">htmlArea</a> WYSIWYG editor, but due to popular demand it has spawned into Xinha, a generally better version of htmlArea version 3, with a much cooler name.  See the <a href="http://xinha.python-hosting.com/wiki/Examples">Examples</a> to have a play with the latest release of Xinha. 
     64<br><br> 
     65The main branch of Xinha is maintained by James Sleeman of <a href="http://code.gogo.co.nz">Gogo Code</a>.  
    6466 
    6567</p> 
    66 <h2>Unified Backend Branch - snapshot of 2005-04-15</h2> 
     68<h2>Unified Backend Branch - snapshot of 2005-04-24</h2> 
    6769 
    6870<p> 
    69 This version of Xinha is known as the unified backend branch. The purpose of this  
    70 branch is modify the standard Xinha distribution such that all client to server requests 
    71 are routed through a single unified backend script. This should lead to a more  
    72 maintainable codebase.  
     71This version of Xinha is known as the unified backend branch. This work is 
     72sponsored by <a href="http://www.dtlink.com">DTLink, LLC</a> of College Park, Maryland,  
     73USA and is maintained by Yermo Lamers. These changes are, of course, released under the  
     74same terms as Xinha itself.<br><br> 
     75 
     76The original purpose of this branch was to modify the standard Xinha distribution such  
     77that all client to server requests are routed through a single unified backend script.  
     78As part of that effort alot of cleanup work has been done. Changes include reorganizing  
     79the codebase, adding JSDoc headers, adding an extensive debugging trace system,  
     80fixing various bugs and adding a number of management scripts. 
     81<br> 
     82<br> 
     83If you have questions or need help please post in the Xinha discussion  
     84forum. Or you can contact me directly via:<br><br> 
     85 
     86<a href="http://www.formvista.com/contact.html">http://www.formvista.com/contact.html</a> 
     87 
    7388</p> 
    7489 
     
    7792</p> 
    7893 
    79 <ul><li><a href="./docs/index.html">Programmers Documenation</a></li></ul> 
     94<h2>Examples in the local examples directory</h2> 
     95<b>(Turn off Popup Blockers to see the debugging trace window.)</b> 
     96<ul><li><a href="./examples/full_example.html">Full Featured Demo with menu to choose plugins</a></li> 
     97<li><a href="./examples/simple_example.html">Minimal Simple Demo</a></li> 
     98</ul> 
     99 
     100<h2>Programmers Documentation</h2> 
     101<ul><li><a href="./docs/index.html">Programmers Documentation</a></li></ul> 
    80102 
    81103<h2>Status - only partially functional.</h2> 
     
    94116<li>debug trace message panel - to turn trace messages on/off on a plugin by plugin basis</li> 
    95117<li>buildruntime.php script to strip out comments and trace messages</li> 
    96 <li>ddtpreproc.php to process js files to include line numbers and filenames</li> 
    97118<li>fix enterparagraph</li> 
    98 </ul> 
    99  
    100  
    101 <h2>Examples in the local examples directory</h2> 
    102 <ul><li><a href="./examples/full_example.html">Full Featured Demo with menu to choose plugins</a></li> 
    103 <li><a href="./examples/simple_example.html">Simple Demo with just 2 plugins.</a></li> 
    104119</ul> 
    105120 
  • branches/unified_backend/popups/about.html

    r84 r85  
    1717this file will match the version of the repository. 
    1818 
    19 [@@77@@] 
     19[@@78@@] 
    2020 
    2121--> 
Note: See TracChangeset for help on using the changeset viewer.