rem: var dtCreated = item.getProperty("CREATED"); var bAdd = (dtCreated == null || dtCreated.compare(dtFrom) >= 0); modifiedItems.push( item.id ); if (bAdd) {   this_.log( "new item: " + item.id ); if (destCal) { syncState.acquire(); destCal.addItem( item, addItemListener ); } if (calObserver) calObserver.onAddItem( item ); 
add:   for each ( var mid in modifiedItems ) { if (item.id == mid) { this_.log( "skipping deletion of " + item.id ); return; 
context:                         function( item ) {                            var dtCreated = item.getProperty("CREATED");                            var bAdd = (dtCreated == null ||                                        dtCreated.compare(dtFrom) >= 0);                            modifiedItems.push( item.id );                            if (bAdd) {                                // xxx todo: verify whether exceptions                                //           have been written                                this_.log( "new item: " + item.id );                                if (destCal) {                                    syncState.acquire();                                    destCal.addItem( item, addItemListener );                                }                                if (calObserver)                                    calObserver.onAddItem( item );                            }                            else {                                this_.log( "modified item: " + item.id );                                if (destCal) {                                    syncState.acquire();                                    destCal.modifyItem( item, null,                                                        modifyItemListener );                                }                                if (calObserver)                                    calObserver.onModifyItem( item, null );                            }                        } );
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/171daff7e25672d3c0d0ee0c5ca0366c3f9501ff/calWcapCalendarItems.js/clean/calendar/providers/wcap/calWcapCalendarItems.js