Пример #1
0
  @Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    initActionBar();

    setAbContentView(R.layout.activity_filternear);
    FinalActivity.initInjectedView(this);
    setLogo(R.drawable.button_back_selector);
    addRightButtonView(R.drawable.button_gou_selector)
        .setOnClickListener(
            new OnClickListener() {

              @Override
              public void onClick(View v) {
                // TODO Auto-generated method stub
                getData();
                Intent intent = new Intent();
                intent.putExtra("sex", sex);
                intent.putExtra("age", age);
                intent.putExtra("job", job);
                intent.putExtra("game_name", game_name);
                intent.putExtra("constellate", constellate);
                intent.putExtra("last_active_time", last_active_time);
                setResult(RESULT_OK, intent);
                finish();
              }
            });
    setTitleText("自定义筛选");
    act = this;
    init();
    initDialog();
  }
Пример #2
0
  @Override
  protected void onDestroy() {
    super.onDestroy();
    NotificationManager messageNotificatioManager =
        (NotificationManager) getSystemService(NOTIFICATION_SERVICE);
    messageNotificatioManager.cancelAll();
    mApplication.stopLocation();

    stopService(new Intent(this, DownloadService.class));
  }
Пример #3
0
 @Override
 protected void onCreate(Bundle savedInstanceState) {
   super.onCreate(savedInstanceState);
   initActionBar();
   setAbContentView(R.layout.activity_user_set_about);
   FinalActivity.initInjectedView(this);
   setLogo(R.drawable.button_back_selector);
   setTitleText("¹ØÓÚ");
   init();
 }
Пример #4
0
  @Override
  public void onResume() {
    super.onResume();
    new Handler()
        .postDelayed(
            new Runnable() {

              @Override
              public void run() {
                changeItem(currIndex);
              }
            },
            200);
  }
Пример #5
0
  @Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.page_frame);
    ExitApplication.getInstance().addActivity(this);

    Intent downloadIntent = new Intent(this, DownloadService.class); // 开启下载服务
    startService(downloadIntent);

    mTabPager = (MyViewPager) findViewById(R.id.vPager);
    mTabPager.setOffscreenPageLimit(1);
    main_bottom = (FrameLayout) findViewById(R.id.main_bottom);

    mTabPager.setOnTouchListener(
        new OnTouchListener() {

          @Override
          public boolean onTouch(View v, MotionEvent event) {
            return true;
          }
        });

    iv_tab2 = findViewById(R.id.img_2);
    badge = new BadgeView(this, iv_tab2);
    badge.setText("1");

    page1 = new NearFragment();
    page2 = new MessageFragment();
    page3 = new ContactFragment();
    page4 = new GameFragment();
    page5 = new UserFragment();

    pagerItemList = new ArrayList<Fragment>();
    pagerItemList.add(page1);
    pagerItemList.add(page2);
    pagerItemList.add(page3);
    pagerItemList.add(page4);
    pagerItemList.add(page5);
    pagerCount = pagerItemList.size();
    FragmentManager mFragmentManager = this.getSupportFragmentManager();
    CustomFragmentPagerAdapter mFragmentPagerAdapter =
        new CustomFragmentPagerAdapter(mFragmentManager, pagerItemList);
    mTabPager.setAdapter(mFragmentPagerAdapter);
    mTabPager.setOffscreenPageLimit(2);
    mTabPager.setOnPageChangeListener(new MyOnPageChangeListener());
  }
Пример #6
0
 @Override
 protected void onResume() {
   // TODO Auto-generated method stub
   super.onResume();
   adapter.notifyDataSetChanged();
 }
Пример #7
0
 @Override
 protected void onActivityResult(int arg0, int arg1, Intent arg2) {
   super.onActivityResult(arg0, arg1, arg2);
 }
Пример #8
0
 @Override
 public void onPause() {
   super.onPause();
 }
Пример #9
0
 @Override
 public void onBackPressed() {
   imageLoader.stop();
   super.onBackPressed();
 }