Merge branch '2.3' of https://git.oschina.net/dreamhua/GH-ASSISTv1.45 into 2.3
Conflicts: app/src/main/java/com/gh/gamecenter/download/GameUpdateFragmentAdapter.java
This commit is contained in:
@ -5,6 +5,7 @@ import android.content.Intent;
|
||||
import android.content.SharedPreferences;
|
||||
import android.content.pm.ApplicationInfo;
|
||||
import android.content.pm.PackageInfo;
|
||||
import android.graphics.Color;
|
||||
import android.net.Uri;
|
||||
import android.os.Build;
|
||||
import android.os.Bundle;
|
||||
@ -559,17 +560,17 @@ public class MainActivity extends BaseFragmentActivity implements OnClickListene
|
||||
// 获取已安装游戏
|
||||
private void getInstalledListFromServer() {
|
||||
ArrayList<String> list = PackageUtils.getAllPackageName(getApplicationContext());
|
||||
if (list.isEmpty()) {
|
||||
if (isNewFirstLaunch) { // 延迟0.3s,防止页面未注册eventbus,接收消息失败
|
||||
handler.postDelayed(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
EventBus.getDefault().post(new EBUISwitch("NewsFragment", -1)); //通知更新推荐关注小版块
|
||||
}
|
||||
}, 300);
|
||||
}
|
||||
return;
|
||||
}
|
||||
// if (list.isEmpty()) {
|
||||
// if (isNewFirstLaunch) { // 延迟0.3s,防止页面未注册eventbus,接收消息失败
|
||||
// handler.postDelayed(new Runnable() {
|
||||
// @Override
|
||||
// public void run() {
|
||||
// EventBus.getDefault().post(new EBUISwitch("NewsFragment", -1)); //通知更新推荐关注小版块
|
||||
// }
|
||||
// }, 300);
|
||||
// }
|
||||
// return;
|
||||
// }
|
||||
|
||||
PackageManager.init(list);
|
||||
|
||||
@ -653,9 +654,9 @@ public class MainActivity extends BaseFragmentActivity implements OnClickListene
|
||||
* 更新关注列表数据
|
||||
*/
|
||||
private void update() {
|
||||
if (isNewFirstLaunch) {
|
||||
EventBus.getDefault().post(new EBUISwitch("NewsFragment", -1)); //通知更新推荐关注小版块
|
||||
}
|
||||
// if (isNewFirstLaunch) {
|
||||
// EventBus.getDefault().post(new EBUISwitch("NewsFragment", -1)); //通知更新推荐关注小版块
|
||||
// }
|
||||
new Thread(){
|
||||
@Override
|
||||
public void run() {
|
||||
@ -1069,9 +1070,9 @@ public class MainActivity extends BaseFragmentActivity implements OnClickListene
|
||||
ivGame.setImageResource(R.drawable.ic_game_unselect);
|
||||
ivNews.setImageResource(R.drawable.ic_news_unselect);
|
||||
ivPersonal.setImageResource(R.drawable.ic_user_unselect);
|
||||
tvGame.setTextColor(getResources().getColor(R.color.title));
|
||||
tvNews.setTextColor(getResources().getColor(R.color.title));
|
||||
tvPersonal.setTextColor(getResources().getColor(R.color.title));
|
||||
tvGame.setTextColor(Color.parseColor("#a7a8b2"));
|
||||
tvNews.setTextColor(Color.parseColor("#a7a8b2"));
|
||||
tvPersonal.setTextColor(Color.parseColor("#a7a8b2"));
|
||||
}
|
||||
|
||||
// 将所有的Fragment都置为隐藏状态。
|
||||
|
||||
Reference in New Issue
Block a user