I've just finished the documentation of a DHTML abstraction component I've written. Here's the page:
http://www.depressedpress.com/Content/Development/JavaScript/Extensions/DP_PanelManager/ I know - there are a lot of these around now. They're all good, but I also think that many of them (YUI, DOJO, etc) tend to 1) do way more than most everyone needs and 2) tend to "dominate" the development process such that once you start using them you're forced to use other aspects of them to do any real work. My goal is to make small, self-contained components that take the confusion out of basic functionality without adding any extra requirements to the app. The basic premise here is that you create a "PanelManager" which can create "Panels". Panels are just HTML elements (DIVs, P, whatever). Once created (either from scratch or from existing elements) the Panel gains a mess of simple, cross-browser (I've tested IE 6 and 7, FireFox 2 and Opera 9) methods to do: +) Event Management (add and remove multiple event handles for any panel). +) Size, Position and Opacity (set, get and shift (adjust relatively) these values with optional animation of the change). +) Visibility (control visibility and display) +) Order (control z-index) In addition the core PanelManager object gives you simple methods to obtain window and canvas size and mouse position. Unlike many other options this component makes the tools to work with panels direct methods of the panel. Once the panel is created you never need to reference it as such again. You can say, for example (in this example "myPanel" is the HTML ID of a DIV): document.getElementById("myPanel").setPosition([100,100]); All methods have been designed to work together. The output from any method that returns a position can be used as input to any method that accepts a position. Same for size and opacity. To place one panel at the same position as another you might do this: MyPanel1 = document.getElementById("myPanel1"); MyPanel2 = document.getElementById("myPanel2"); MyPanel1.setPosition(MyPanel2.getPosition()); I'm actually really loving this thing and so far it's been working great on a few personal projects, but I'd love some external opinions. The component is pretty feature-rich (thus the length of the documentation) but if you work your way all the way to the bottom there are examples to see. Thanks in advance, Jim Davis ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| ColdFusion MX7 and Flex 2 Build sales & marketing dashboard RIAâs for your business. Upgrade now http://www.adobe.com/products/coldfusion/flex2?sdid=RVJT Archive: http://www.houseoffusion.com/groups/CF-Community/message.cfm/messageid:232524 Subscription: http://www.houseoffusion.com/groups/CF-Community/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.5
