当前位置: 首页>>代码示例>>Java>>正文


Java AccessibilityRecordCompat.obtain方法代码示例

本文整理汇总了Java中android.support.v4.view.accessibility.AccessibilityRecordCompat.obtain方法的典型用法代码示例。如果您正苦于以下问题:Java AccessibilityRecordCompat.obtain方法的具体用法?Java AccessibilityRecordCompat.obtain怎么用?Java AccessibilityRecordCompat.obtain使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在android.support.v4.view.accessibility.AccessibilityRecordCompat的用法示例。


在下文中一共展示了AccessibilityRecordCompat.obtain方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override
public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
    super.onInitializeAccessibilityEvent(host, event);
    event.setClassName(DirectionalViewpager.class.getName());
    AccessibilityRecordCompat recordCompat = null;
    if (isHorizontal()) {
        recordCompat =
                AccessibilityEventCompat.asRecord(event);
    } else {
        recordCompat = AccessibilityRecordCompat.obtain();
    }
    recordCompat.setScrollable(canScroll());
    if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED
            && mAdapter != null) {
        recordCompat.setItemCount(mAdapter.getCount());
        recordCompat.setFromIndex(mCurItem);
        recordCompat.setToIndex(mCurItem);
    }
}
 
开发者ID:weiwenqiang,项目名称:GitHub,代码行数:20,代码来源:DirectionalViewpager.java

示例2: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override
public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
    super.onInitializeAccessibilityEvent(host, event);
    event.setClassName(ViewPager.class.getName());
    final AccessibilityRecordCompat recordCompat = AccessibilityRecordCompat.obtain();
    recordCompat.setScrollable(canScroll());
    if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED
            && mAdapter != null) {
        recordCompat.setItemCount(mAdapter.getCount());
        recordCompat.setFromIndex(mCurItem);
        recordCompat.setToIndex(mCurItem);
    }
}
 
开发者ID:weiwenqiang,项目名称:GitHub,代码行数:14,代码来源:VerticalViewPager.java

示例3: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override
public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
    super.onInitializeAccessibilityEvent(host, event);
    event.setClassName(XCCycleViewPager.class.getName());
    final AccessibilityRecordCompat recordCompat = AccessibilityRecordCompat.obtain();
    recordCompat.setScrollable(canScroll());
    if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED
            && mAdapter != null) {
        recordCompat.setItemCount(mAdapter.getCount());
        recordCompat.setFromIndex(mCurItem);
        recordCompat.setToIndex(mCurItem);
    }
}
 
开发者ID:ruiqiao2017,项目名称:Renrentou,代码行数:14,代码来源:XCCycleViewPager.java

示例4: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override
public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
	super.onInitializeAccessibilityEvent(host, event);
	event.setClassName(CustomViewPager.class.getName());
	final AccessibilityRecordCompat recordCompat = AccessibilityRecordCompat.obtain();
	recordCompat.setScrollable(canScroll());
	if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED
		&& mAdapter != null) {
		recordCompat.setItemCount(mAdapter.getCount());
		recordCompat.setFromIndex(mCurItem);
		recordCompat.setToIndex(mCurItem);
	}
}
 
开发者ID:fengshihao,项目名称:WebPager,代码行数:14,代码来源:CustomViewPager.java

示例5: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override
public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
    super.onInitializeAccessibilityEvent(host, event);
    event.setClassName(ViewPagerEx.class.getName());
    final AccessibilityRecordCompat recordCompat = AccessibilityRecordCompat.obtain();
    recordCompat.setScrollable(canScroll());
    if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED
            && mAdapter != null) {
        recordCompat.setItemCount(mAdapter.getCount());
        recordCompat.setFromIndex(mCurItem);
        recordCompat.setToIndex(mCurItem);
    }
}
 
开发者ID:sega4revenge,项目名称:Sega,代码行数:14,代码来源:ViewPagerEx.java

示例6: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override
public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
    super.onInitializeAccessibilityEvent(host, event);
    event.setClassName(VelocityViewPager.class.getName());
    final AccessibilityRecordCompat recordCompat = AccessibilityRecordCompat.obtain();
    recordCompat.setScrollable(canScroll());
    if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED
            && mAdapter != null) {
        recordCompat.setItemCount(mAdapter.getCount());
        recordCompat.setFromIndex(mCurItem);
        recordCompat.setToIndex(mCurItem);
    }
}
 
开发者ID:reyanshmishra,项目名称:Rey-MusicPlayer,代码行数:14,代码来源:VelocityViewPager.java

示例7: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override
public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
    super.onInitializeAccessibilityEvent(host, event);
    event.setClassName(SmoothViewPager.class.getName());
    final AccessibilityRecordCompat recordCompat = AccessibilityRecordCompat.obtain();
    recordCompat.setScrollable(canScroll());
    if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED
            && mAdapter != null) {
        recordCompat.setItemCount(mAdapter.getCount());
        recordCompat.setFromIndex(mCurItem);
        recordCompat.setToIndex(mCurItem);
    }
}
 
开发者ID:OpenLauncherTeam,项目名称:openlauncher,代码行数:14,代码来源:SmoothViewPager.java

示例8: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override
public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
    super.onInitializeAccessibilityEvent(host, event);
    event.setClassName(ViewPager.class.getName());
    final AccessibilityRecordCompat recordCompat =
            AccessibilityRecordCompat.obtain();
    recordCompat.setScrollable(canScroll());
    if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED
            && mAdapter != null) {
        recordCompat.setItemCount(mAdapter.getCount());
        recordCompat.setFromIndex(mCurItem);
        recordCompat.setToIndex(mCurItem);
    }
}
 
开发者ID:joy-inc,项目名称:core-ui,代码行数:15,代码来源:VerticalViewPager.java

示例9: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override
public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
    super.onInitializeAccessibilityEvent(host, event);
    event.setClassName(OrientationViewPager.class.getName());
    final AccessibilityRecordCompat recordCompat = AccessibilityRecordCompat.obtain();
    recordCompat.setScrollable(canScroll());
    if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED
            && mAdapter != null) {
        recordCompat.setItemCount(mAdapter.getCount());
        recordCompat.setFromIndex(mCurItem);
        recordCompat.setToIndex(mCurItem);
    }
}
 
开发者ID:m4coding,项目名称:Orientation-ViewPager,代码行数:14,代码来源:OrientationViewPager.java

示例10: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
  super.onInitializeAccessibilityEvent(host, event);
  event.setClassName(ViewPager.class.getName());
  final AccessibilityRecordCompat recordCompat = AccessibilityRecordCompat.obtain();
  recordCompat.setScrollable(canScroll());
  if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED && mAdapter != null) {
    recordCompat.setItemCount(mAdapter.getCount());
    recordCompat.setFromIndex(mCurItem);
    recordCompat.setToIndex(mCurItem);
  }
}
 
开发者ID:smuyyh,项目名称:SprintNBA,代码行数:12,代码来源:VerticalViewPager.java

示例11: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override
public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
    super.onInitializeAccessibilityEvent(host, event);
    event.setClassName(FuckViewPager.class.getName());
    final AccessibilityRecordCompat recordCompat = AccessibilityRecordCompat.obtain();
    recordCompat.setScrollable(canScroll());
    if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED
            && mAdapter != null) {
        recordCompat.setItemCount(mAdapter.getCount());
        recordCompat.setFromIndex(mCurItem);
        recordCompat.setToIndex(mCurItem);
    }
}
 
开发者ID:tianyuan168326,项目名称:nono-android,代码行数:14,代码来源:FuckViewPager.java

示例12: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
public final void onInitializeAccessibilityEvent(View paramView, AccessibilityEvent paramAccessibilityEvent)
{
  super.onInitializeAccessibilityEvent(paramView, paramAccessibilityEvent);
  paramAccessibilityEvent.setClassName(ViewPager.class.getName());
  AccessibilityRecordCompat localAccessibilityRecordCompat = AccessibilityRecordCompat.obtain();
  localAccessibilityRecordCompat.setScrollable(canScroll());
  if ((paramAccessibilityEvent.getEventType() == 4096) && (ViewPager.this.mAdapter != null))
  {
    localAccessibilityRecordCompat.setItemCount(ViewPager.this.mAdapter.getCount());
    localAccessibilityRecordCompat.setFromIndex(ViewPager.this.mCurItem);
    localAccessibilityRecordCompat.setToIndex(ViewPager.this.mCurItem);
  }
}
 
开发者ID:ChiangC,项目名称:FMTech,代码行数:14,代码来源:ViewPager.java

示例13: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override
public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
    super.onInitializeAccessibilityEvent(host, event);
    event.setClassName(VerticalViewPager.class.getName());
    final AccessibilityRecordCompat recordCompat = AccessibilityRecordCompat.obtain();
    recordCompat.setScrollable(canScroll());
    if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED
            && mAdapter != null) {
        recordCompat.setItemCount(mAdapter.getCount());
        recordCompat.setFromIndex(mCurItem);
        recordCompat.setToIndex(mCurItem);
    }
}
 
开发者ID:juliome10,项目名称:DoubleViewPager,代码行数:14,代码来源:VerticalViewPager.java

示例14: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override
public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
    super.onInitializeAccessibilityEvent(host, event);
    event.setClassName(MyViewPager.class.getName());
    final AccessibilityRecordCompat recordCompat = AccessibilityRecordCompat.obtain();
    recordCompat.setScrollable(canScroll());
    if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED
            && mAdapter != null) {
        recordCompat.setItemCount(mAdapter.getCount());
        recordCompat.setFromIndex(mCurItem);
        recordCompat.setToIndex(mCurItem);
    }
}
 
开发者ID:yy1300326388,项目名称:ViewPagerWithAnimations,代码行数:14,代码来源:MyViewPager.java

示例15: onInitializeAccessibilityEvent

import android.support.v4.view.accessibility.AccessibilityRecordCompat; //导入方法依赖的package包/类
@Override
public void onInitializeAccessibilityEvent(View host, AccessibilityEvent event) {
    super.onInitializeAccessibilityEvent(host, event);
    event.setClassName(ViewPager.class.getName());
    final AccessibilityRecordCompat recordCompat = AccessibilityRecordCompat.obtain();
    recordCompat.setScrollable(canScroll());
    if (event.getEventType() == AccessibilityEventCompat.TYPE_VIEW_SCROLLED && mAdapter != null) {
        recordCompat.setItemCount(mAdapter.getCount());
        recordCompat.setFromIndex(mCurItem);
        recordCompat.setToIndex(mCurItem);
    }
}
 
开发者ID:gzsll,项目名称:TLint,代码行数:13,代码来源:VerticalViewPager.java


注:本文中的android.support.v4.view.accessibility.AccessibilityRecordCompat.obtain方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。