@Override protected void onActivityResult(int arg0, int arg1, Intent arg2) { super.onActivityResult(arg0, arg1, arg2); if (arg1 == RESULT_OK) { if (downloadGameInfo != null) { MyGameActivity.addToMyGameList(ThirdGameDetailActivity.this, downloadGameInfo); } } }
@Override protected void onDestroy() { super.onDestroy(); unregistReceiver(); if (ScreenShot.screenShotBmp != null) { ScreenShot.screenShotBmp.recycle(); ScreenShot.screenShotBmp = null; } }
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); requestWindowFeature(Window.FEATURE_NO_TITLE); getWindow() .setFlags( WindowManager.LayoutParams.FLAG_FULLSCREEN | WindowManager.LayoutParams.FLAG_ALT_FOCUSABLE_IM, WindowManager.LayoutParams.FLAG_FULLSCREEN | WindowManager.LayoutParams.FLAG_ALT_FOCUSABLE_IM); setContentView(R.layout.activity_third_game_detail); ScaleViewUtils.init(this); ScaleViewUtils.scaleView(getWindow().getDecorView()); setBlackTitle(false); icon = (ImageView) findViewById(R.id.iv_icon); gameSize = (TextView) findViewById(R.id.tv_game_size); handleType = (TextView) findViewById(R.id.tv_game_handle); gameName = (TextView) findViewById(R.id.tv_game_name); gameDesc = (TextView) findViewById(R.id.tv_game_desc); gameDesc.setMovementMethod(ScrollingMovementMethod.getInstance()); gameDesc.setOnFocusChangeListener(onFocusChangeListener); mRecyclerView = (RecyclerView) findViewById(R.id.rv_game_source); LayoutManager layoutManager = new LinearLayoutManager(this, LinearLayoutManager.HORIZONTAL, false); mRecyclerView.setLayoutManager(layoutManager); mAdapter = new GameSourceAdapter(this, mRecyclerView, mImageFetcher); mRecyclerView.setAdapter(mAdapter); // gameSourceLayout = (LinearLayout)findViewById(R.id.ll_game_source); contentView = (RelativeLayout) findViewById(R.id.rl_desc); loadingView = (LoadingView) findViewById(R.id.contentLoading); loadingView.setDataView(contentView); if (getIntent() != null) { mGameId = getIntent().getStringExtra(GAMEID); } if (mGameId != null && mGameId != "") { Log.i("life", "mGameId:" + mGameId); getData(mGameId); } registReceiver(); }
@Override protected void onResume() { super.onResume(); setTitleData(); }