當前位置: 首頁>>代碼示例>>Java>>正文


Java AccessibilityEventCompat.getContentChangeTypes方法代碼示例

本文整理匯總了Java中android.support.v4.view.accessibility.AccessibilityEventCompat.getContentChangeTypes方法的典型用法代碼示例。如果您正苦於以下問題:Java AccessibilityEventCompat.getContentChangeTypes方法的具體用法?Java AccessibilityEventCompat.getContentChangeTypes怎麽用?Java AccessibilityEventCompat.getContentChangeTypes使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在android.support.v4.view.accessibility.AccessibilityEventCompat的用法示例。


在下文中一共展示了AccessibilityEventCompat.getContentChangeTypes方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: shouldDeferAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityEventCompat; //導入方法依賴的package包/類
/**
 * Returns true if an accessibility event should not be dispatched now. This happens when an
 * accessibility request arrives while RecyclerView does not have a stable state which is very
 * hard to handle for a LayoutManager. Instead, this method records necessary information about
 * the event and dispatches a window change event after the critical section is finished.
 *
 * @return True if the accessibility event should be postponed.
 */
boolean shouldDeferAccessibilityEvent(AccessibilityEvent event) {
    if (isComputingLayout()) {
        int type = 0;
        if (event != null) {
            type = AccessibilityEventCompat.getContentChangeTypes(event);
        }
        if (type == 0) {
            type = AccessibilityEventCompat.CONTENT_CHANGE_TYPE_UNDEFINED;
        }
        mEatenAccessibilityChangeFlags |= type;
        return true;
    }
    return false;
}
 
開發者ID:MLNO,項目名稱:airgram,代碼行數:23,代碼來源:RecyclerView.java

示例2: shouldDeferAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityEventCompat; //導入方法依賴的package包/類
boolean shouldDeferAccessibilityEvent(AccessibilityEvent event) {
    if (!isComputingLayout()) {
        return false;
    }
    int type = 0;
    if (event != null) {
        type = AccessibilityEventCompat.getContentChangeTypes(event);
    }
    if (type == 0) {
        type = 0;
    }
    this.mEatenAccessibilityChangeFlags |= type;
    return true;
}
 
開發者ID:JackChan1999,項目名稱:letv,代碼行數:15,代碼來源:RecyclerView.java

示例3: sendAccessibilityEventUnchecked

import android.support.v4.view.accessibility.AccessibilityEventCompat; //導入方法依賴的package包/類
public void sendAccessibilityEventUnchecked(AccessibilityEvent paramAccessibilityEvent)
{
  boolean bool = isComputingLayout();
  int i = 0;
  if (bool) {
    if (paramAccessibilityEvent == null) {
      break label60;
    }
  }
  label60:
  for (int j = AccessibilityEventCompat.getContentChangeTypes(paramAccessibilityEvent);; j = 0)
  {
    int k = 0;
    if (j == 0) {}
    for (;;)
    {
      this.mEatenAccessibilityChangeFlags = (k | this.mEatenAccessibilityChangeFlags);
      i = 1;
      if (i != 0) {
        return;
      }
      super.sendAccessibilityEventUnchecked(paramAccessibilityEvent);
      return;
      k = j;
    }
  }
}
 
開發者ID:ChiangC,項目名稱:FMTech,代碼行數:28,代碼來源:RecyclerView.java


注:本文中的android.support.v4.view.accessibility.AccessibilityEventCompat.getContentChangeTypes方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。