var $AdfDhtmlPollPeer$$ = $AdfRichUIPeer$$.$createPeerClass$($AdfRichUIPeer$$, "AdfDhtmlPollPeer");
$goog$exportSymbol$$("AdfDhtmlPollPeer", $AdfDhtmlPollPeer$$);
$AdfDhtmlPollPeer$$.$ASYNCHRONOUS_UPDATES_ON_DEMAND$ = "onDemand";
$goog$exportSymbol$$("AdfDhtmlPollPeer.ASYNCHRONOUS_UPDATES_ON_DEMAND", $AdfDhtmlPollPeer$$.$ASYNCHRONOUS_UPDATES_ON_DEMAND$);
$AdfDhtmlPollPeer$$.$COMPONENT_QUEUE$ = [];
$goog$exportSymbol$$("AdfDhtmlPollPeer.COMPONENT_QUEUE", $AdfDhtmlPollPeer$$.$COMPONENT_QUEUE$);
$AdfDhtmlPollPeer$$.$InitSubclass$ = function $$AdfDhtmlPollPeer$$$$InitSubclass$$() {
  this.$_INTERVAL_ID$ = "_afrInterval";
  $AdfRichUIPeer$$.$addComponentPropertyChanges$(this, AdfRichPoll.INTERVAL);
};
$goog$exportSymbol$$("AdfDhtmlPollPeer.InitSubclass", $AdfDhtmlPollPeer$$.$InitSubclass$);
$AdfDhtmlPollPeer$$.prototype.$initialize$ = function $$AdfDhtmlPollPeer$$$$$initialize$$($component$$1843$$) {
  $AdfDhtmlPollPeer$$.$superclass$.$initialize$.call(this, $component$$1843$$);
  $AdfDhtmlPollPeer$$.$_setInterval$($component$$1843$$);
  $AdfPage$$.$PAGE$.$__getUserInactivityTimeoutHelper$().$registerPollComponent$($component$$1843$$);
};
$AdfObject$$.$exportPrototypeSymbol$("AdfDhtmlPollPeer.prototype.initialize", {$initialize$:$AdfDhtmlPollPeer$$.prototype.$initialize$});
$AdfDhtmlPollPeer$$.$_clearInterval$ = function $$AdfDhtmlPollPeer$$$$_clearInterval$$($component$$1844_intervalId$$) {
  if ($component$$1844_intervalId$$ = $component$$1844_intervalId$$[$AdfDhtmlPollPeer$$.$_INTERVAL_ID$]) {
    this[$AdfDhtmlPollPeer$$.$_INTERVAL_ID$] = void 0, window.clearInterval($component$$1844_intervalId$$);
  }
};
$AdfDhtmlPollPeer$$.$_setInterval$ = function $$AdfDhtmlPollPeer$$$$_setInterval$$($component$$1845$$) {
  var $interval_intervalId$$1$$ = $component$$1845$$.getInterval();
  if (0 <= $interval_intervalId$$1$$) {
    var $callback$$118$$ = $component$$1845$$.$createCallback$(this.$_queuePoll$), $interval_intervalId$$1$$ = window.setInterval($callback$$118$$, $interval_intervalId$$1$$);
    $component$$1845$$[$AdfDhtmlPollPeer$$.$_INTERVAL_ID$] = $interval_intervalId$$1$$;
  }
};
$AdfDhtmlPollPeer$$.prototype.$ComponentIntervalChanged$ = function $$AdfDhtmlPollPeer$$$$$ComponentIntervalChanged$$($component$$1846$$) {
  $AdfDhtmlPollPeer$$.$_clearInterval$($component$$1846$$);
  $AdfDhtmlPollPeer$$.$_setInterval$($component$$1846$$);
  return !0;
};
$AdfObject$$.$exportPrototypeSymbol$("AdfDhtmlPollPeer.prototype.ComponentIntervalChanged", {$ComponentIntervalChanged$:$AdfDhtmlPollPeer$$.prototype.$ComponentIntervalChanged$});
$AdfDhtmlPollPeer$$.prototype.$ComponentRemoved$ = function $$AdfDhtmlPollPeer$$$$$ComponentRemoved$$($component$$1847$$) {
  $AdfDhtmlPollPeer$$.$_clearInterval$($component$$1847$$);
  $AdfPage$$.$PAGE$.$__getUserInactivityTimeoutHelper$().$unregisterPollComponent$($component$$1847$$);
  $AdfDhtmlPollPeer$$.$superclass$.$ComponentRemoved$.call(this, $component$$1847$$);
};
$AdfObject$$.$exportPrototypeSymbol$("AdfDhtmlPollPeer.prototype.ComponentRemoved", {$ComponentRemoved$:$AdfDhtmlPollPeer$$.prototype.$ComponentRemoved$});
$AdfDhtmlPollPeer$$.$_queuePoll$ = function $$AdfDhtmlPollPeer$$$$_queuePoll$$() {
  var $helper$$5$$ = $AdfPage$$.$PAGE$.$__getUserInactivityTimeoutHelper$();
  $helper$$5$$ && $helper$$5$$.$hasTimedOut$() || ($AdfPage$$.$PAGE$.$getAsynchronousUpdatesState$() == $AdfDhtmlPollPeer$$.$ASYNCHRONOUS_UPDATES_ON_DEMAND$ ? $AdfDhtmlPollPeer$$.$_cacheComponent$(this) : $AdfPollEvent$$.$queue$(this));
};
$AdfDhtmlPollPeer$$.$_cacheComponent$ = function $$AdfDhtmlPollPeer$$$$_cacheComponent$$($clientId$$384_component$$1848$$) {
  $clientId$$384_component$$1848$$ = $clientId$$384_component$$1848$$.$getClientId$();
  -1 == $AdfCollections$$.indexOf($AdfDhtmlPollPeer$$.$COMPONENT_QUEUE$, $clientId$$384_component$$1848$$) && $AdfDhtmlPollPeer$$.$COMPONENT_QUEUE$.push($clientId$$384_component$$1848$$);
};
