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


Java Target类代码示例

本文整理汇总了Java中com.github.amlcurran.showcaseview.targets.Target的典型用法代码示例。如果您正苦于以下问题:Java Target类的具体用法?Java Target怎么用?Java Target使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


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

示例1: setShowcase

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
public void setShowcase(final Target target, final boolean animate) {
    postDelayed(new Runnable() {
        @Override
        public void run() {

            if (!shotStateStore.hasShot()) {

                updateBitmap();
                Point targetPoint = target.getPoint();
                if (targetPoint != null) {
                    hasNoTarget = false;
                    if (animate) {
                        animationFactory.animateTargetToPoint(ShowcaseView.this, targetPoint);
                    } else {
                        setShowcasePosition(targetPoint);
                    }
                } else {
                    hasNoTarget = true;
                    invalidate();
                }

            }
        }
    }, 100);
}
 
开发者ID:yeloapp,项目名称:yelo-android,代码行数:26,代码来源:ShowcaseView.java

示例2: build

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
public static AutolaunchingQuestionViewShowcaser build(Activity activity, AndroidQuestionView questionView) {
    ShowcaseView showcaseView = new ShowcaseView.Builder(activity)
            .setStyle(R.style.CustomShowcaseTheme)
            .singleShot((long)R.id.question_activity_showcase_id)
            .build();
    showcaseView.setDetailTextAlignment(Layout.Alignment.ALIGN_CENTER);
    AutolaunchingQuestionViewShowcaser.ToolbarTargetFactory toolbarTargetFactory = new AutolaunchingQuestionViewShowcaser.ToolbarTargetFactory() {
        @Override
        public Target createToolbarTarget(Toolbar toolbar, int targetId) {
            return new QuestionActivity.ToolbarActionItemTarget(toolbar, targetId);
        }
    };
    AutolaunchingQuestionViewShowcaser.ViewTargetFactory viewTargetFactory = new AutolaunchingQuestionViewShowcaser.ViewTargetFactory() {
        @Override
        public Target createTarget(View targetView) {
            return new ViewTarget(targetView);
        }
    };
    return new AutolaunchingQuestionViewShowcaser(activity.getApplicationContext(), toolbarTargetFactory, viewTargetFactory, new AMLShowcaseViewAdapter(showcaseView), questionView);
}
 
开发者ID:etp404,项目名称:frenchverbinator,代码行数:21,代码来源:QuestionActivityShowcaserBuilder.java

示例3: initializingShowCaseView

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
private void initializingShowCaseView(){
    showcaseView = new ShowcaseView.Builder(this)
            .setTarget(Target.NONE)
            .setOnClickListener(this)
            .setContentTitle(getString(R.string.tutorialOption))
            .setContentText(R.string.initialMessageTutorial)
            .setStyle(R.style.Transparency)
            .build();

    showcaseView.setButtonText(getString(R.string.next));
}
 
开发者ID:fga-gpp-mds,项目名称:2016.2-MissaoNascente,代码行数:12,代码来源:TutorialScreenActivity.java

示例4: addShowcase

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
protected void addShowcase(Target target, int titleId, int textId) {
    if (target == null) {
        Log.i(tag(), "addShowcase: NULL target!");
        return;
    }
    ShowcaseStep step = new ShowcaseStep();
    step.target = target;
    step.title = titleId;
    step.text = textId;
    showcaseSteps.add(step);
}
 
开发者ID:tarzasai,项目名称:Uoccin,代码行数:12,代码来源:BaseActivity.java

示例5: createViewTarget

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
public static ShowcaseHelpPageModel.TargetWrapper createViewTarget(final Activity activity, final int viewId) {
	return new ShowcaseHelpPageModel.TargetWrapper() {
		@Override
		public Target getTarget() {
			return new ViewTarget(activity.findViewById(viewId));
		}
	};
}
 
开发者ID:Neraud,项目名称:PADListener,代码行数:9,代码来源:TargetBuilder.java

示例6: createActionViewTarget

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
public static ShowcaseHelpPageModel.TargetWrapper createActionViewTarget(final Activity activity, final ActionViewTarget.Type actionViewTargetType) {
	return new ShowcaseHelpPageModel.TargetWrapper() {
		@Override
		public Target getTarget() {
			return new ActionViewTarget(activity, actionViewTargetType);
		}
	};
}
 
开发者ID:Neraud,项目名称:PADListener,代码行数:9,代码来源:TargetBuilder.java

示例7: ShowcaseHolder

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
public ShowcaseHolder(Target target, String text, int btnPosition) {
    this.target = target;
    this.text = text;
    this.btnPosition = btnPosition;
}
 
开发者ID:smartufpa,项目名称:SmartUFPA,代码行数:6,代码来源:ShowcaseHolder.java

示例8: getTarget

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
public Target getTarget() {
    return target;
}
 
开发者ID:smartufpa,项目名称:SmartUFPA,代码行数:4,代码来源:ShowcaseHolder.java

示例9: moveShowCaseCircle

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
private void moveShowCaseCircle(Target currentTarget,String title,String text, int position){
    showcaseView.forceTextPosition(position);
    showcaseView.setShowcase(currentTarget,true);
    showcaseView.setContentTitle(title);
    showcaseView.setContentText(text);
}
 
开发者ID:fga-gpp-mds,项目名称:2016.2-MissaoNascente,代码行数:7,代码来源:TutorialScreenActivity.java

示例10: setupShowcaseView

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
private void setupShowcaseView() {
    if (showcaseView == null) return;
    if (showcaseView.getShowcaseTag() != SHOWCASE_ID_ONBOARDING) return;

    switch(showcaseCounter) {
        case 0:
            showcaseView.setShowcase(Target.NONE, true);
            showcaseView.setContentTitle(mContext.getString(R.string.welcome_screen_title1));
            showcaseView.setContentText(mContext.getString(R.string.welcome_screen_text1));
            showcaseView.setBlockAllTouches(true);
            showcaseView.showButton();
            break;
        case 1:
            showcaseView.setShowcase(new ViewTarget(menuIcon), true);
            showcaseView.setContentTitle(mContext.getString(R.string.welcome_screen_title2));
            showcaseView.setContentText(mContext.getString(R.string.welcome_screen_text2));
            showcaseView.setBlockAllTouches(false);
            showcaseView.setBlocksTouches(true);
            showcaseView.showButton();
            break;
        case 2:
            Point size = utility.getDisplaySize();
            showcaseView.setShowcase(new PointTarget(size.x/2, 20), true);
            showcaseView.setBlockAllTouches(false);
            showcaseView.setContentTitle(mContext.getString(R.string.welcome_screen_title3));
            showcaseView.setContentText(mContext.getString(R.string.welcome_screen_text3));
            showcaseView.showButton();
            break;
        case 3:
            setAlpha(clockLayout, 1.f, 500);
            showcaseView.setShowcase(new ViewTarget(clockLayout), true);
            showcaseView.setContentTitle(mContext.getString(R.string.welcome_screen_title4));
            showcaseView.setContentText(mContext.getString(R.string.welcome_screen_text4));
            showcaseView.setBlockAllTouches(false);
            showcaseView.setBlocksTouches(true);
            //showcaseView.setBlockAllTouches(true);
            showcaseView.showButton();
            break;
        default:
            showcaseView.hide();
            break;
    }
}
 
开发者ID:firebirdberlin,项目名称:nightdream,代码行数:44,代码来源:NightDreamUI.java

示例11: setTarget

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
public void setTarget(final Target target) {
    setShowcase(target, false);
}
 
开发者ID:yeloapp,项目名称:yelo-android,代码行数:4,代码来源:ShowcaseView.java

示例12: Builder

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
public Builder(Activity activity, boolean useNewStyle) {
    this.activity = activity;
    this.showcaseView = new ShowcaseView(activity, useNewStyle);
    this.showcaseView.setTarget(Target.NONE);
}
 
开发者ID:yeloapp,项目名称:yelo-android,代码行数:6,代码来源:ShowcaseView.java

示例13: setContentTextForView

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
@Override
public void setContentTextForView(String contentText, Target view) {
    showcaseView.setContentText(contentText);
    showcaseView.setTarget(view);
}
 
开发者ID:etp404,项目名称:frenchverbinator,代码行数:6,代码来源:AMLShowcaseViewAdapter.java

示例14: setContentTextForView

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
@Override
public void setContentTextForView(String contentTitle, Target viewTarget) {
    viewsTargeted.add(viewTarget);
    contentTitles.add(contentTitle);

}
 
开发者ID:etp404,项目名称:frenchverbinator,代码行数:7,代码来源:ShowcaseTests.java

示例15: createToolbarTarget

import com.github.amlcurran.showcaseview.targets.Target; //导入依赖的package包/类
@Override
public Target createToolbarTarget(android.support.v7.widget.Toolbar toolbar, int targetId) {
    return new FakeToolbarTarget(toolbar, targetId);
}
 
开发者ID:etp404,项目名称:frenchverbinator,代码行数:5,代码来源:ShowcaseTests.java


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