Ver Fonte

手动合并代码

hexiaojie há 1 ano atrás
pai
commit
6e6368f51a

+ 3 - 3
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/ActivityAfternoonTea/UI_ActivityTeaMainUI.cs

@@ -7,7 +7,7 @@ namespace UI.ActivityAfternoonTea
     public partial class UI_ActivityTeaMainUI
     {
         public GComponent target;
-        public GLoader m_Top_img;
+        public GLoader m_Bg;
         public GButton m_btnBack;
         public GLoader m_BgOne;
         public GLoader m_titleBg;
@@ -68,7 +68,7 @@ namespace UI.ActivityAfternoonTea
 
         private void Init(GComponent comp)
         {
-            m_Top_img = (GLoader)comp.GetChild("Top_img");
+            m_Bg = (GLoader)comp.GetChild("Bg");
             m_btnBack = (GButton)comp.GetChild("btnBack");
             m_BgOne = (GLoader)comp.GetChild("BgOne");
             m_titleBg = (GLoader)comp.GetChild("titleBg");
@@ -85,7 +85,7 @@ namespace UI.ActivityAfternoonTea
         }
         public void Dispose(bool disposeTarget = false)
         {
-            m_Top_img = null;
+            m_Bg = null;
             m_btnBack = null;
             m_BgOne = null;
             m_titleBg = null;

+ 6 - 3
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/ActivityDay7/UI_ActivityDay7UI.cs

@@ -7,7 +7,8 @@ namespace UI.ActivityDay7
     public partial class UI_ActivityDay7UI
     {
         public GComponent target;
-        public GLoader m_Top_img1;
+        public GLoader m_loaBg;
+        public GLoader m_Top_img;
         public GLoader m_Top_img2;
         public GButton m_btnBack;
         public GTextField m_TimeStr;
@@ -66,7 +67,8 @@ namespace UI.ActivityDay7
 
         private void Init(GComponent comp)
         {
-            m_Top_img1 = (GLoader)comp.GetChild("Top_img1");
+            m_loaBg = (GLoader)comp.GetChild("loaBg");
+            m_Top_img = (GLoader)comp.GetChild("Top_img");
             m_Top_img2 = (GLoader)comp.GetChild("Top_img2");
             m_btnBack = (GButton)comp.GetChild("btnBack");
             m_TimeStr = (GTextField)comp.GetChild("TimeStr");
@@ -81,7 +83,8 @@ namespace UI.ActivityDay7
         }
         public void Dispose(bool disposeTarget = false)
         {
-            m_Top_img1 = null;
+            m_loaBg = null;
+            m_Top_img = null;
             m_Top_img2 = null;
             m_btnBack = null;
             m_TimeStr = null;

+ 1 - 4
GameClient/Assets/Game/HotUpdate/Game.HotUpdate.asmdef

@@ -9,10 +9,7 @@
         "GUID:6e5063adab271564ba0098a06a8cebda",
         "GUID:d9a5d47c553a04a28a7d21a3f3fc8dc3",
         "GUID:9b1c19877f4294a9cb33ff38fc9f1c83",
-        "GUID:f22fac247a56d2d41b687bb0d900e54e",
-        "GUID:60bfecf5cb232594891bc622f40d6bed",
-        "GUID:08d1c582746949b40ba6a45cdb776bdf",
-        "GUID:98c047f00cf7d4cbb8028bf242da48b5"
+        "GUID:f22fac247a56d2d41b687bb0d900e54e"
     ],
     "includePlatforms": [],
     "excludePlatforms": [],

+ 3 - 2
GameClient/Assets/Game/HotUpdate/Views/ActivityDay7/ActivityDay7View.cs

@@ -33,7 +33,7 @@ namespace GFGGame
             }
             base.Dispose();
         }
-        
+
         protected override void OnInit()
         {
             base.OnInit();
@@ -42,9 +42,10 @@ namespace GFGGame
             viewCom = _ui.target;
             isfullScreen = true;
             isReturnView = true;
+
             bringToFontOnClick = false;
             _ui.m_btnBack.onClick.Add(OnBtnBackClick);
-            //_ui.bg.url = ResPathUtil.GetBgImgPath("cp_beijing");
+            _ui.m_loaBg.url = ResPathUtil.GetBgImgPath("cp_beijing");
             _ui.m_DayList.itemRenderer = DayListRenderer;
             _ui.m_comTaskList.m_TaskList.itemRenderer = TaskListRenderer;
             _ui.m_tip.onClick.Add(RuleController.ShowRuleView);

+ 0 - 6
GameClient/Assets/Game/HotUpdate/Views/Notice/NoticeView.cs

@@ -176,12 +176,6 @@ namespace GFGGame
 
         }
 
-        public override void Refresh()
-        {
-            base.Refresh();
-            Debug.LogError(1);
-        }
-
         /// <summary>
         /// 系统公告 1
         /// </summary>

+ 11 - 2
GameClient/Assets/Game/HotUpdate/Views/UIView.cs

@@ -233,7 +233,16 @@ namespace GFGGame
 
         private void MakeFullScreen(GObject ui)
         {
-            MakeUIFullScreen(ui);
+            // 摘星界面特殊处理
+            if (viewName == "LuckyBoxView")
+            {
+                ui.MakeFullScreen();
+            }
+            else
+            {
+                MakeUIFullScreen(ui);
+            }
+            
             ui.AddRelation(GRoot.inst, RelationType.Size);
         }
 
@@ -303,7 +312,7 @@ namespace GFGGame
             // 还原不需要适配的UI
             for (int i = 0; i < listTopImg.Count; i++)
             {
-                listTopImg[i].SetSize(listTopImg[i].width, heightList[i]);
+                listTopImg[i].SetSize(listTopImg[i].width, heightList[i] + offsetY * 2);
                 listTopImg[i].SetXY(listTopImg[i].x, listTopImg[i].y - offsetY);
             }
 

+ 13 - 5
GameClient/Assets/Game/HotUpdate/Views/ViewGlobal.cs

@@ -38,17 +38,25 @@ namespace GFGGame
         /// <returns></returns>
         static float GetTopOffset()
         {
-            int designOffset = (Screen.safeArea.height == Screen.height ? 0 : 90);
-            return Screen.height - Screen.safeArea.height - Screen.safeArea.y - designOffset;
+            // 标准分辨率下 设计图顶部留了80像素的偏移
+            int designOffset = ((Screen.safeArea.height + Screen.safeArea.y) 
+                == Screen.height ? 0 : (int)Mathf.Round(80 * UIContentScaler.scaleFactor));
+            
+            // 设置最低偏移是设计图顶部的偏移量
+            return Mathf.Max(0, Screen.height - Screen.safeArea.height - Screen.safeArea.y - designOffset);
         }
 
+        /// <summary>
+        /// 获取画布根据分辨率适配后的,顶部的实际高度
+        /// </summary>
+        /// <returns></returns>
         public static float GetRealTopOffset()
         {
             return Screen.height / UIContentScaler.scaleFactor - GetUIHeight();
         }
 
         /// <summary>
-        /// 获取UI适配后的高度
+        /// 获取画布根据分辨率适配后的UI高度
         /// </summary>
         /// <returns></returns>
         public static float GetUIHeight()
@@ -83,9 +91,9 @@ namespace GFGGame
 
         public static bool IsFullScreenPic(string name)
         {
-            foreach(string s in fullScreenPicNames)
+            foreach (string s in fullScreenPicNames)
             {
-                if(name == s)
+                if (name == s)
                     return true;
             }
             return false;