Mozile 0.7 Change Log

Mozile 0.7.2:
 General -
- The 0.7 license can now be found at http://mozile.mosdev.org/license2.html
- Major refactoring of Mozile code, breaking the monolithic Mozile object down into several smaller objects. Interfaces have often changed radically, so the new code is not compatible with previous versions!
- mozile.js has been simplified and clarified. It is incompatible with previous version of Mozile! However the format should not change much from now on.
- Any modules written for previous versions will probably be broken! A better versioning system is expected in the future, but otherwise the interface should be relatively stable now.
- New unit tests have been written for all the classes. Not all methods are covered yet.
- The Mozile Extension has been rewritten to use XPCNativeWrappers, so the security risk from using the extension should be small.
 Specifics -
- New MozileResource class handles external resources using elements such as <script/>. Subclasses include MozileScriptResource (script tags), MozileLinkResource (link tags), and MozileStyleResource (style tags).
- New MozileComponent class defines common operations for other classes, such as option getting, setting, and parsing. Subclasses include MozileModule, MozileEditor, MozileInterface, MozileCommand, and MozileMediator.
- MozileCommand was one of the few OO parts of previous versions. It is now a subclass of MozileComponent, and it and its subclasses have all been refactored to match the other new classes.
- New MozileCommandSeparator is a new dummy command which is rendered as a toolbar-separator or a menu-separator depending on the context.
- New MozileModule handles the loading of modules. All of the modules have been refactored to take advantage of this new class.
- New MozileEditor now handles all editing operations. This class will be expanded in future work.
- New MozileInterface handles popups and dialogs, either using a resource from within the page or grabbing one with XMLHTTPRequest.
- New MozileMediator is a catch-all class following the Mediator design-pattern. Like the old Mozile object, there should be a single global instance of this object, which all the other objects rely on.
- New MozileExtension handles the extension logic.
- saveCharset, saveEntities, and saveConversion have been ported from 0.6 to 0.7 following Max's SaveOptions01.pdf documentation. Note that nsISaveAsCharset requires privileges to execute, which cannot be assumed in Mozile 0.7 as they could in 0.6. You can set saveCharset, saveEntities, and saveConversion options in the configuration strings locally for for save modules and globally in the mozileOptions.
- HTTPPost module has been reworked for Mozile 0.7, and should now conform with the behaviour of HTTPPost in Mozile 0.6 according to Max's PostSave05.html documentation. In particular the MozileID feature has been implemented. The key difference is that the HTTPPost module does not run privileged, so it cannot convert character sets like in 0.6. 
- LocalFile does run privileged, and will now convert character sets. Also, if the current document uses the "file:" protocol, the module will quietly try to save the content back to that file.
- The toolbar will now overflow onto multiple lines if the window is too narrow.
- Editors, whether they are blocks or inline, will no longer split when then "enter" key is pressed.
 New Mozile Options:
- Load Just-In-Time. "loadJIT=true" option will load core.js but will wait to load all other files until they are needed. Defaults to "false".
- Activate On Focus. "activateOnFocus=false" will require you to use the mozile.startEditing() method to enable editing. Also available are mozile.isEditable() and mozile.stopEditing() methods. The default for this option is "true".
- Replace Anchors. "replaceAnchors=true" will replace all the "a" elements in the current editor with "mozileAnchorReplacement" elements that have identical attributes. Replacement takes place when the editor is focussed and the anchor elements are restored when the editor is blurred. The effect is that anchor elements can no longer steal the focus, and users can click on them without leaving the page. Default is "true".
- Default Interval. "defaultInterval=100" will set all window.setInterval operations to use 100 milliseconds. The toolbar and interfaces use intervals to reposition themselves. Default is "100".
- Not Versions. Format for the "notversion" option has changed from allowing multiple "notversion" entries to allowing a single "notversions=[1.0.2,1.0.5]" array. Other options needing multiple values follow this format now.
- Save Character Set. "saveCharset=UTF-8" will make Mozile try to convert the character set. Note that this requires privileges which are not always available. Default is the document character set.
- Save Entities. "saveEntities=[html40latin1,html40symbols]" sets the options for entity conversion. See the docs for all options. Note that this requires privileges which are not always available. Default is none.
- Save Conversion. "saveConversion=[entitybeforecharset,questionmark]" sets the conversion options. See the docs for all options. Note that this requires privileges which are not always available. Default is none.
- CopyCutPaste has been modified. Now a keyboard "copy" command, no matter what privileges Mozile has, should copy to the system clipboard. Pasting from the system clipboard requires privileges or enhancement by the Mozile Extension.
- Mozile Extension UI has been reworked, and should be a lot less annoying.
- Mozile Extension now communicates with Mozile instances inside the browser windows using attributes of the "Mozile-Core-core.js" script element. The setSharedData and getSharedData operations manipulate the attributes, while the watchSharedData method watches for changes and executes code when changes occur. Right now the watchers updates at 100ms intervals. This may be faster than necessary.
- Mozile Extension now includes editable "enhancements" which are operations that can be requested from the document. The only default enhancement is "getClipboard" which asks the Mozile Extension to send the current system clipboard contents. A "save to local file" enhancement is planned. The user-definable enhancements are the only access Mozile documents get to the Extension.
- Changed mozileBuild.py script to generate "full.html" files from the XML source with all documentation on a single page.
- Extension now uses chrome.manifest files, which specify xpcnativewrappers=yes.
- New image files generated, "Mozile" and "Mozile9" in 32, 24, 20, an 16 px sizes.


Mozile 0.7.1:
- Add a chrome.manifest file with the xpcnativewrappers=no option. This should allow the extension to work properly in Firefox 1.5.
- Supress alert in extension.js that was so annoying.
- Fixed more files with bad line-endings. All line-endings should be Unix style LF.
- Fixed Mozile.makeDocumentEditable() to make it register the editor and set the tabIndex attribute.
- Fixed Mozile.saveToDialog bug where source would not display if the editor was enhanced by the Mozile extension. 
- Fixed copy, cut, and paste commands to return true. This makes sure that undo/redo work properly for them.

Mozile 0.7.0 Final:
- Added -moz-user-select: text to createEditor commands
- Looked at a bug with FF 1.5 causing the statusbar layout orientation to swicth between horizontal and vertical. Still haven't figured out why, but when the Mozile toolbarPosition=absolute option is set the problem disappears.
- Added mousedown listeners to the toolbar widget in interface.xml, in order to work around a bug in FF 1.5 where you would try to press a statusbar button and the statusbar would hide before the click event was triggered.
- Added Max's PHP and Lars' JSP demo code to the HTTPPost module.
- Rearranged the mozile.js file for easier configuration by adding the mozileOptions variable to the top.
- Changed test suites to work around a bizarre FF 1.5 problem: JsUnit test functions are being executed in reverse order!

Mozile 0.7.0-preview2:
- Fixed MozileCore.js Mozile.initializeToolbar() to use the rootCommandList.
- Fixed a bug in MozileCore.js Mozile.cleanUp() involving the removal of moziletoolbar elements.
- Changed MozileCore.js Node.isBlock() regular expression to include -moz-box as a kind of block.
- Changed name of "widgets.xbl" to "widgets.xml", and fixed all references in MozileCore.js.
- Changed core/widgets.xml editor's constructor to wrap the editor in an "html:wrapper" element, with 'tabindex="12345"', which fixes a major bug in Firefox 1.1 development version Deer Park Alpha 2. This might have to be revised again later.
- Fixed Mozile.initializeToolbar() in MozileCore.js and XHTMLBasic.js to append the rootCommandList box instead of copying it. Fixes a toolbar problem in Deer Park where every other button was ignored.
- Tweaked the toolbar to center better (widgets.css, widgets.xml). I'd like the buttons to flow onto new lines when the window is narrow, but that isn't working right now.
- Changed Mozile.moduleList to include the module's configArray as its value instead of just the version string. The Mozile.registerModule() method now fails if it does not find a moduleList entry with the appropriate id.
- Changed the functions in core/debug.xul to look for key-value arrays instead of numbered ones, and changed all the debugging arrays (everywhere) to match this.
- Added a statusbar which pops up at the bottom of the screen, and a Mozile.status function, which feeds messages to the status bar and also to the debugList.
- Added saving functionality. The Mozile.saveList tracks the various saving methods. Mozile.saveAs() opens the save.xul dialog. When it's done it stes the Mozile.saveFlag to true. The next time Mozile.showToolbar is called(when an editor is focussed?) Mozile.save() is called, which sets the Mozile.saveConfig and calls Mozile.saveConfig["function"].
- Moved all of the Mozile dialogs into XBL, and made them popup within the document using CSS. This prevents numerous problems with popup blockers.
- Split the MozileCore.js file into two parts: core.js and interface.js. The first can be used alone for very basic editing, while the second supports MozileCommands, MozileCOmmandLists, the toolbar and statusbar, and Mozile dialogs. Also broke widgets.xml into core.xml (basic editor XBL) and interface XBL (for toolbar, statusbar, and dialogs). Finally, widgets.css is not interface.css. There is a new variable in mozile.js called "mozileInterface", which when set to false disables all modules and interface elements, and loads only the core/core.js file.
- Fixed the toXML/toHTML functions so that they output XML declarations, doctype declarations, and processing instructions, as well as the serialized documentElement. Because the Mozile.cleanUp() method wasn't catching the Mozile-Core-core.js script tag.
- Added a Mozile.makeDocumentEditable() method, which attaches event listeners directly to the document rather than using XBL. This requires me to move all of the Mozile.handleEvent methods into the global scope as mozileHandleEvent. I also added mozileHandleFocus() and mozileHandleBlur() functions.
- Added some basic performance testing code.
- Rearranged the index files for the testing directory. Now there's an "index.xml" file for listing the tests, and "index.xsl" for making it nice to look at.
- Optimized the mozileHandleKeypress(), Mozile.deletion(), and Mozile.seekIP() code. Managed to cut 20-25% off of the execution time. Mozile.seelIP() is much cleaner.
- Created "semantic" option for XHTMLBasic module. When "semantic=true" (which is the default) the bold command uses "strong", and italic command uses "em", for better semantic XHTML. Else it uses "b" and "i".
- Added all of the XPI stuff. This includes XUL overlays for Firefox and Mozilla, new options dialog, new JavaScript to load all the Mozile code into the browser, and a new "enhance" functionality, which over-rides functions defined by Mozile Server-Side in order to provide enhanced privileges. Although the user is appropriately warned of the security risks in this, I'm still concerned about security issues.
- Changed licensing blocks on all the files that only I (James Overton) have changed, to reflect the fact that this is a complete rewrite of Mozile, and does not depend on the original Playsophy code. I should have done this before, but it's done now.
- Added LocalFile save module, taking the lead from the Save Text Area extension (http://www.benya.com/software/savetextarea/) to see how it's done.
- Added an HTTP POST save module, reusing Max's code from Mozile 0.6.
- Added a "toolbarPosition" option to the Mozile object configuration. Values can be "absolute" or "fixed", which changes the CSS positioning of the toolbars. Default is "abolute", which looks better and works just as well in Firefox 1.0.x, but it slows Deer Park (1.6.x) down significantly. I've added a window.setInterval which calls Mozile.moveToolbar every 100 milliseconds, whenever Mozile.toolbarUpdateFrequency==2. This might need to be changed.
- Connected a code compressor called JSMin (http://www.crockford.com/javascript/jsmin.html) to the mozileBuild.py script. Now all the JavaScript files in the standard builds (non-developer) are compressed before they are packaged.


Mozile 0.7.0-preview:
- Initial Release