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


Java LinearLayout.startAnimation方法代码示例

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


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

示例1: initDisPlay

import android.widget.LinearLayout; //导入方法依赖的package包/类
private void initDisPlay() {
    tvSkip = findViewById(R.id.tv_skip);
    tvSkip.setOnClickListener(new View.OnClickListener() {
        @Override
        public void onClick(View v) {
            skip();
        }
    });
    View contentView = findViewById(R.id.content_view);
    if (DisplayUtil.hasVirtualNavigationBar(this)) {
        contentView.setPadding(0, 0, 0, DisplayUtil.getNavigationBarHeight(this));
    }
    TextView tvVersionName = findViewById(R.id.tv_version_name);
    tvVersionName.setText(BuildConfig.VERSION_NAME);
    LinearLayout llWelcome = (LinearLayout) findViewById(R.id.ll_welcome);
    TextView tvDate = findViewById(R.id.tv_date);
    SimpleDateFormat format2 = new SimpleDateFormat("yyyy年MM月dd日,EEEE");
    tvDate.setText(format2.format(new Date()));
    Animation animation = AnimationUtils.loadAnimation(this, R.anim.alpha_in);
    llWelcome.startAnimation(animation);
}
 
开发者ID:z-chu,项目名称:FriendBook,代码行数:22,代码来源:StartActivity.java

示例2: onLoadSuccess

import android.widget.LinearLayout; //导入方法依赖的package包/类
public void onLoadSuccess(Fragment fragment,ShowRefreshViewListener showRefreshViewListener){
    if (hashMap_fragment_loadView.containsKey(fragment)){
        if (!hashMap_fragment_isSuccess.get(fragment)){
            hashMap_fragment_isSuccess.remove(fragment);
            hashMap_fragment_isSuccess.put(fragment,true);
            View loadView=hashMap_fragment_loadView.get(fragment);
            LinearLayout loadretry_parent=(LinearLayout)loadView.findViewById(R.id.loadretry_parent);
            AlphaAnimation alphaAnimation = new AlphaAnimation(1,0);
            alphaAnimation.setDuration(loadRetryRefreshConfig.getEndAnimTime());
            loadretry_parent.startAnimation(alphaAnimation);
            loadretry_parent.setVisibility(View.GONE);
        }else{
            showRefreshViewListener.colseRefreshView();
        }
    }
}
 
开发者ID:NoEndToLF,项目名称:Gif-Load-ReTry-Refresh,代码行数:17,代码来源:LoadReTryRefreshManager.java

示例3: StartAnimations

import android.widget.LinearLayout; //导入方法依赖的package包/类
private void StartAnimations() {
        Animation anim = AnimationUtils.loadAnimation(this, R.anim.alpha);
        anim.reset();
        LinearLayout l = (LinearLayout) findViewById(R.id.lin_lay);
        l.clearAnimation();
        l.startAnimation(anim);

        anim = AnimationUtils.loadAnimation(this, R.anim.translate);
        anim.reset();
        ImageView iv = (ImageView) findViewById(R.id.bard_splash);
        iv.clearAnimation();
        iv.startAnimation(anim);

    splashTread = new Thread() {
        @Override
        public void run() {
            try {
                int waited = 0;
                // Splash screen pause time
                while (waited < 3500) {
                    sleep(100);
                    waited += 100;
                }
                Intent intent = new Intent(SplashActivity.this,
                        MainActivity.class);
                intent.setFlags(Intent.FLAG_ACTIVITY_NO_ANIMATION);
                startActivity(intent);
                SplashActivity.this.finish();
            } catch (InterruptedException e) {
                // do nothing
            } finally {
                SplashActivity.this.finish();
            }

        }
    };
    splashTread.start();

}
 
开发者ID:ma8642,项目名称:FindSpot,代码行数:40,代码来源:SplashActivity.java

示例4: initializeComponent

import android.widget.LinearLayout; //导入方法依赖的package包/类
private void initializeComponent(View view) {

        RelativeLayout rlParent = view.findViewById(library.imagepicker.R.id.dialog_image_picker_rl_parent);
        TextView tvGallery = view.findViewById(library.imagepicker.R.id.dialog_image_picker_tv_gallery);
        TextView tvCamera = view.findViewById(library.imagepicker.R.id.dialog_image_picker_tv_camera);
        TextView tvCancel = view.findViewById(library.imagepicker.R.id.dialog_image_picker_tv_cancel);
        LinearLayout llAnimateLayout = view.findViewById(library.imagepicker.R.id.dialog_image_picker_ll_dialog);

        Animation animation = AnimationUtils.loadAnimation(getActivity(), library.imagepicker.R.anim.bottom_up);
        llAnimateLayout.startAnimation(animation);
        llAnimateLayout.setVisibility(View.VISIBLE);

        rlParent.setOnClickListener(this);
        tvGallery.setOnClickListener(this);
        tvCamera.setOnClickListener(this);
        tvCancel.setOnClickListener(this);
    }
 
开发者ID:KaranMavadhiya,项目名称:Android_ImagePicker,代码行数:18,代码来源:ImagePickerDialog.java

示例5: StartAnimations

import android.widget.LinearLayout; //导入方法依赖的package包/类
private void StartAnimations() {


        Animation anim = AnimationUtils.loadAnimation(this, R.anim.alpha);
        anim.reset();
        LinearLayout l = (LinearLayout) findViewById(R.id.lin_lay);
        l.clearAnimation();
        l.startAnimation(anim);
        anim = AnimationUtils.loadAnimation(this, R.anim.rotate);
        anim.reset();

        ImageView iv = (ImageView) findViewById(R.id.splash);

        iv.clearAnimation();
        iv.startAnimation(anim);

        splashTread = new Thread() {
            @Override
            public void run() {
                try {
                    int waited = 0;
                    while (waited < 3500) {
                        sleep(100);
                        waited += 100;
                    }
                    Intent intent = new Intent(Splashscreen.this,
                            MainActivity.class);
                    intent.setFlags(Intent.FLAG_ACTIVITY_NO_ANIMATION);

                    startActivity(intent);
                    Splashscreen.this.finish();

                } catch (InterruptedException e) {

                } finally {
                    Splashscreen.this.finish();
                }
            }
        };
        splashTread.start();
    }
 
开发者ID:lmartire,项目名称:DoApp,代码行数:42,代码来源:Splashscreen.java


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