|
@@ -39,6 +39,8 @@ namespace GFGGame
|
|
|
private List<EffectUI> _effectUIList = new List<EffectUI>();
|
|
|
private UI_ButtonModle1[] _btns;
|
|
|
private bool firstIn;
|
|
|
+ //用于标记自动检测打开界面流程已执行完毕
|
|
|
+ private bool AutoShowCompleted;
|
|
|
|
|
|
public override void Dispose()
|
|
|
{
|
|
@@ -190,6 +192,7 @@ namespace GFGGame
|
|
|
Timers.inst.AddUpdate(Update);
|
|
|
Update(null);
|
|
|
|
|
|
+ //让主界面先显示出来,其他逐步处理
|
|
|
Timers.inst.Remove(OnShowLater);
|
|
|
Timers.inst.Add(0.1f, 1, OnShowLater);
|
|
|
|
|
@@ -219,6 +222,7 @@ namespace GFGGame
|
|
|
Timers.inst.Remove(CheckGuide);
|
|
|
Timers.inst.Remove(UpdateAdListTime);
|
|
|
Timers.inst.Remove(OnShowLater);
|
|
|
+ Timers.inst.Remove(OnRedDotChangedLater);
|
|
|
}
|
|
|
|
|
|
private void OnShowLater(object param)
|
|
@@ -836,7 +840,12 @@ namespace GFGGame
|
|
|
|
|
|
private void OnRedDotChanged()
|
|
|
{
|
|
|
- Timers.inst.CallLater(OnRedDotChangedLater);
|
|
|
+ //暂时用这种方法优化下,红点的实现要重构!!!
|
|
|
+ //LogHelper.LogEditor("MainUIView UpdateRedDot OnRedDotChanged");
|
|
|
+ if (!GameGlobal.AfterDataInited) return;
|
|
|
+ if (!AutoShowCompleted) return;
|
|
|
+ Timers.inst.Remove(OnRedDotChangedLater);
|
|
|
+ Timers.inst.Add(0.1f, 1, OnRedDotChangedLater);
|
|
|
}
|
|
|
|
|
|
private void OnRedDotChangedLater(object o)
|
|
@@ -846,8 +855,6 @@ namespace GFGGame
|
|
|
|
|
|
private void UpdateRedDot()
|
|
|
{
|
|
|
- return;
|
|
|
- if (firstIn) return;
|
|
|
LogHelper.LogEditor("MainUIView UpdateRedDot");
|
|
|
_valueBarController.UpRead();
|
|
|
RedDotController.Instance.SetComRedDot(_btnGongGao, RedDotDataManager.Instance.GetNoticeRed(), "", -9, 12);
|
|
@@ -1021,6 +1028,8 @@ namespace GFGGame
|
|
|
ViewManager.Show<FieldFightEndView>();
|
|
|
return;
|
|
|
}
|
|
|
+ AutoShowCompleted = true;
|
|
|
+ OnRedDotChanged();
|
|
|
}
|
|
|
|
|
|
}
|