AdfDhtmlTimelineSeriesPeer.prototype.HandleComponentMouseOver=function(a){if(AdfTimelineUtils.supportsTouch())a=a.getNativeEvent(),AdfAgent.AGENT.preventDefault(a);else if(a=a.getNativeEventTarget(),null!=a&&(a=this.GetRowKeyAndItem(a,this.getDomElement()),null!=a)){var b=a[1];this.isItemSelectionEnabled()&&this.highlightItem(b);if(this.isGroupItem(b)&&(a=b.lastChild,4!=parseInt(a.style.top))){var c={top:4};c.left=b.firstChild.offsetLeft+4;b={};b.element=a;b.properties=c;b.duration="0.1s";b.timingFunction=
"linear";a=[];a.push(b);AdfDvtAnimator.ANIMATOR.animate(this,a,100,null,null)}}};
AdfDhtmlTimelineSeriesPeer.prototype.HandleComponentMouseOut=function(a){if(!AdfTimelineUtils.supportsTouch()&&(a=a.getNativeEventTarget(),a=this.GetRowKeyAndItem(a,this.getDomElement()),null!=a)){var b=a[1];this.unhighlightItem(b);if(this.isGroupItem(b)&&(a=b.lastChild,1!=parseInt(a.style.top))){var c={top:1};c.left=b.firstChild.offsetLeft+1;b={};b.element=a;b.properties=c;b.duration="0.1s";b.timingFunction="linear";a=[];a.push(b);AdfDvtAnimator.ANIMATOR.animate(this,a,100,null,null)}}};
AdfDhtmlTimelineSeriesPeer.prototype.highlightItem=function(a,b){if(!AdfDhtmlCommonUtils.containsCSSClassName(a.firstChild,AdfDhtmlTimelineSeriesPeer._SELECTED_CLASS)){this.addStyle(a,AdfDhtmlTimelineSeriesPeer._HIGHLIGHTED_CLASS);if(!b){var c=this.getTimelineOverviewPeer();null!=c&&c.highlightItem(a.id)}this.isAllowOverlap(this.getComponent())&&(a.style.zIndex=1E3)}};
AdfDhtmlTimelineSeriesPeer.prototype.unhighlightItem=function(a,b){this.removeStyle(a,AdfDhtmlTimelineSeriesPeer._HIGHLIGHTED_CLASS);if(!b&&!AdfDhtmlCommonUtils.containsCSSClassName(a.firstChild,AdfDhtmlTimelineSeriesPeer._SELECTED_CLASS)){var c=this.getTimelineOverviewPeer();null!=c&&c.unhighlightItem(a.id)}this.isAllowOverlap(this.getComponent())&&1E3==a.style.zIndex&&(a.style.zIndex="")};
AdfDhtmlTimelineSeriesPeer.prototype._updateComponentSelectionState=function(a){var b=this.getComponent();(a=a.getAttribute("_selState"))&&b.setProperty("selectedRowKeys",a,!1,AdfUIComponent.PROPAGATE_NEVER)};AdfDhtmlTimelineSeriesPeer.prototype.handleItemClick=function(a,b,c){this.isItemSelectionEnabled()&&(a=AdfAgent.AGENT.isSelectionToggle(a),this.doItemSelection(a,b,c))};
AdfDhtmlTimelineSeriesPeer.prototype.isItemSelectionEnabled=function(){var a=this.getComponent().getParent().getItemSelection();return a&&a.toLowerCase()!=AdfDhtmlTimelineSeriesPeer._SELECTION_NONE};AdfDhtmlTimelineSeriesPeer.prototype.isMultipleItemSelect=function(){var a=this.getComponent().getParent().getItemSelection();return a&&-1!=a.toLowerCase().indexOf(AdfDhtmlTimelineSeriesPeer._SELECTION_MULTIPLE)};
AdfDhtmlTimelineSeriesPeer.prototype.doItemSelection=function(a,b,c,d){this.isMultipleItemSelect()&&a?(this._anchorRowKey=b,this._selIsSelected(b)?this._selUnselectItem(b,c):this._selSelectItem(b,c,!1,!1,d)):(this._anchorRowKey=b,this._selIsOnlySelection(b)||(this.suppressSelectionEventDelivery(!0),this.getTimelinePeer().selUnselectAllForAllSeries(),this.suppressSelectionEventDelivery(!1),this._selSelectItem(b,c,!1,!1,d)));this.getTimelinePeer().setLastRowKey(b,c,this.getComponent().getClientId());
AdfDhtmlTimelineSeriesPeer.isIE9()||this.getDomElement().focus()};AdfDhtmlTimelineSeriesPeer.prototype.suppressSelectionEventDelivery=function(a){this._suppressSelectionEventDelivery=a};AdfDhtmlTimelineSeriesPeer.prototype.canDeliverSelectionEvent=function(){return!this._suppressSelectionEventDelivery};AdfDhtmlTimelineSeriesPeer.prototype._selIsSelected=function(a){return this.getComponent().getSelectedRowKeys()[a]};
AdfDhtmlTimelineSeriesPeer.prototype._selIsOnlySelection=function(a){var b=this.getComponent().getSelectedRowKeys(),c=b[a];if(c)for(var d in b)if(d!=a){c=!1;break}return c};AdfDhtmlTimelineSeriesPeer.prototype._selUnselectAll=function(a){this._normalSelectionUpdate(AdfDhtmlTimelineSeriesPeer._SEL_UPDATE_ALL_UNSELECT,!0);this._updateTimelineSelectionState({});a||(a=this.getTimelineOverviewPeer(),null!=a&&a.removeAllSelectedMarkers())};
AdfDhtmlTimelineSeriesPeer.prototype._normalSelectionUpdate=function(a,b,c){var d=this.getDatabody();if(null!=d&&(1==b&&(this._highlightedRowKey=null),null==c&&(c=this.getComponent().getSelectedRowKeys()),c&&!AdfCollections.isEmpty(c)))for(var d=d.childNodes,e=AdfAgent.getAgent(),f=0;f<d.length;f++){var g=d[f].childNodes;if(g)for(var h=0;h<g.length;h++){var l=g[h],m=e.getAttribute(l,AdfDhtmlTimelineSeriesPeer._ROW_KEY);if(null!=m&&(0!=b||this._highlightedRowKey!=m))switch(a){case AdfDhtmlTimelineSeriesPeer._SEL_UPDATE_ALL_SELECT:this._selHighlightItem(l);
break;case AdfDhtmlTimelineSeriesPeer._SEL_UPDATE_ALL_UNSELECT:this._selUnhighlightItem(l);break;case AdfDhtmlTimelineSeriesPeer._SEL_UPDATE_ALL_UPDATE:c[m]?this._selHighlightItem(l):this._selUnhighlightItem(l)}}}};AdfDhtmlTimelineSeriesPeer.prototype._selUnselectItem=function(a,b,c){this._selUnhighlightItem(b);var d={};AdfCollections.copyInto(d,this.getComponent().getSelectedRowKeys());delete d[a];this._updateTimelineSelectionState(d);c||(a=this.getTimelineOverviewPeer(),null!=a&&a.selUnselectItem(b.id))};
AdfDhtmlTimelineSeriesPeer.prototype._selSelectItem=function(a,b,c,d,e){this._selHighlightItem(b);if(!c){c=this.getComponent();var f={};AdfCollections.copyInto(f,c.getSelectedRowKeys());f[a]=!0;this._updateTimelineSelectionState(f);"none"==this.getTimelinePeer().getGlassPane().style.display&&this.scrollItemIntoView(b,e)}d||(a=this.getTimelineOverviewPeer(),null!=a&&a.selSelectItem(b.id))};
AdfDhtmlTimelineSeriesPeer.prototype._selHighlightItem=function(a){this.addStyle(a,AdfDhtmlTimelineSeriesPeer._SELECTED_CLASS);this.removeStyle(a,AdfDhtmlTimelineSeriesPeer._HIGHLIGHTED_CLASS);this.isInActiveHeirarchy()?this.removeStyle(a,AdfDhtmlTimelineSeriesPeer._INACTIVE_CLASS):this.addStyle(a,AdfDhtmlTimelineSeriesPeer._INACTIVE_CLASS);this.isAllowOverlap(this.getComponent())&&(a.style.zIndex=999)};
AdfDhtmlTimelineSeriesPeer.prototype._selUnhighlightItem=function(a){AdfAssert.assertDomNode(a);this.removeStyle(a,AdfDhtmlTimelineSeriesPeer._INACTIVE_CLASS);this.removeStyle(a,AdfDhtmlTimelineSeriesPeer._SELECTED_CLASS);this.removeStyle(a,AdfDhtmlTimelineSeriesPeer._HIGHLIGHTED_CLASS);this.removeStyle(a,AdfDhtmlTimelineSeriesPeer._FOCUSED_CLASS);this.isAllowOverlap(this.getComponent())&&(a.style.zIndex="")};
AdfDhtmlTimelineSeriesPeer.prototype._selClearAllStylesOnItem=function(a){this.removeStyle(a,AdfDhtmlTimelineSeriesPeer._INACTIVE_CLASS);this.removeStyle(a,AdfDhtmlTimelineSeriesPeer._SELECTED_CLASS);this.removeStyle(a,AdfDhtmlTimelineSeriesPeer._HIGHLIGHTED_CLASS);this.removeStyle(a,AdfDhtmlTimelineSeriesPeer._FOCUSED_CLASS);this.isAllowOverlap(this.getComponent())&&(a.style.zIndex="")};
AdfDhtmlTimelineSeriesPeer.prototype._updateTimelineSelectionState=function(a){AdfLogger.LOGGER.finer("Update Timeline selection state to:",a);this.getComponent().setSelectedRowKeys(a)};
AdfDhtmlTimelineSeriesPeer.prototype.addStyle=function(a,b){AdfAssert.assertDomNode(a);var c=a.firstChild,d=null;if(c.nextSibling){var d=c.nextSibling,e=d.nextSibling;if(this.hasDuration(a))var f=e.nextSibling;e.firstChild&&(e=e.firstChild)}AdfAssert.assertDomNode(c);d&&(AdfAssert.assertDomNode(d),AdfAssert.assertDomNode(e));AdfDhtmlCommonUtils.addCSSClassName(c,b);d&&(AdfDhtmlCommonUtils.addCSSClassName(d,b),AdfDhtmlCommonUtils.addCSSClassName(e,b),f&&AdfDhtmlCommonUtils.addCSSClassName(f,b),(AdfDhtmlTimelineSeriesPeer.isIE7()||
AdfDhtmlTimelineSeriesPeer.isIE8())&&null!=e.nextSibling&&AdfDhtmlCommonUtils.addCSSClassName(e.nextSibling,b));this.isGroupItem(a)&&AdfDhtmlCommonUtils.addCSSClassName(a.lastChild,b)};
AdfDhtmlTimelineSeriesPeer.prototype.removeStyle=function(a,b){AdfAssert.assertDomNode(a);var c=a.firstChild,d=null;if(c.nextSibling){var d=c.nextSibling,e=d.nextSibling;if(this.hasDuration(a))var f=e.nextSibling;e.firstChild&&(e=e.firstChild)}AdfAssert.assertDomNode(c);d&&(AdfAssert.assertDomNode(d),AdfAssert.assertDomNode(e));AdfDhtmlCommonUtils.removeCSSClassName(c,b);d&&(AdfDhtmlCommonUtils.removeCSSClassName(d,b),AdfDhtmlCommonUtils.removeCSSClassName(e,b),f&&AdfDhtmlCommonUtils.removeCSSClassName(f,
b),(AdfDhtmlTimelineSeriesPeer.isIE7()||AdfDhtmlTimelineSeriesPeer.isIE8())&&null!=e.nextSibling&&AdfDhtmlCommonUtils.removeCSSClassName(e.nextSibling,b));this.isGroupItem(a)&&AdfDhtmlCommonUtils.removeCSSClassName(a.lastChild,b)};