⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 wm.txt

📁 STM32F103ZET6+UCOSII+UCGUI源码
💻 TXT
📖 第 1 页 / 共 5 页
字号:
;;;685        }
;;;686        WM_UNLOCK();
;;;687      }
;;;688    }
000020  bd70              POP      {r4-r6,pc}
;;;689    
                          ENDP


                          AREA ||i.WM_SetDefault||, CODE, READONLY, ALIGN=2

                  WM_SetDefault PROC
;;;1283   */
;;;1284   void WM_SetDefault(void) {
000000  b510              PUSH     {r4,lr}
;;;1285     GL_SetDefault();
000002  f7fffffe          BL       GL_SetDefault
;;;1286     GUI_Context.WM__pUserClipRect = NULL;   /* No add. clipping */
000006  4902              LDR      r1,|L16.16|
000008  2000              MOVS     r0,#0
;;;1287   }
00000a  6388              STR      r0,[r1,#0x38]  ; GUI_Context
00000c  bd10              POP      {r4,pc}
;;;1288   
                          ENDP

00000e  0000              DCW      0x0000
                  |L16.16|
                          DCD      GUI_Context

                          AREA ||i.WM__ActivateClipRect||, CODE, READONLY, ALIGN=2

                  WM__ActivateClipRect PROC
;;;320    */
;;;321    void  WM__ActivateClipRect(void) {
000000  b51c              PUSH     {r2-r4,lr}
;;;322      if (WM_IsActive) {
000002  4c0d              LDR      r4,|L17.56|
000004  7820              LDRB     r0,[r4,#0]  ; WM_IsActive
000006  b120              CBZ      r0,|L17.18|
;;;323        _SetClipRectUserIntersect(&_ClipContext.CurRect);
000008  e8bd401c          POP      {r2-r4,lr}
00000c  480b              LDR      r0,|L17.60|
00000e  f7ffbffe          B.W      _SetClipRectUserIntersect
                  |L17.18|
;;;324      } else {    /* Window manager disabled, typically because meory device is active */
;;;325        GUI_RECT r;
;;;326        WM_Obj *pAWin;
;;;327        pAWin = WM_H2P(GUI_Context.hAWin);
000012  480b              LDR      r0,|L17.64|
000014  f9b0003c          LDRSH    r0,[r0,#0x3c]  ; GUI_Context
000018  f7fffffe          BL       GUI_ALLOC_h2p
;;;328        r = pAWin->Rect;
00001c  c803              LDM      r0,{r0,r1}
;;;329        #if WM_SUPPORT_TRANSPARENCY
;;;330          if (WM__hATransWindow) {
00001e  e9cd0100          STRD     r0,r1,[sp,#0]
000022  f9b41012          LDRSH    r1,[r4,#0x12]  ; WM__hATransWindow
000026  b111              CBZ      r1,|L17.46|
;;;331            WM__ClipAtParentBorders(&r, WM__hATransWindow);
000028  4668              MOV      r0,sp
00002a  f7fffffe          BL       WM__ClipAtParentBorders
                  |L17.46|
;;;332          }
;;;333        #endif
;;;334        /* Take UserClipRect into account */
;;;335        _SetClipRectUserIntersect(&r);
00002e  4668              MOV      r0,sp
000030  f7fffffe          BL       _SetClipRectUserIntersect
;;;336      }
;;;337    }
000034  bd1c              POP      {r2-r4,pc}
;;;338    
                          ENDP

000036  0000              DCW      0x0000
                  |L17.56|
                          DCD      ||.data||
                  |L17.60|
                          DCD      ||area_number.47||+0x8
                  |L17.64|
                          DCD      GUI_Context

                          AREA ||i.WM__Client2Screen||, CODE, READONLY, ALIGN=1

                  WM__Client2Screen PROC
;;;476    */
;;;477    void WM__Client2Screen(const WM_Obj* pWin, GUI_RECT *pRect) {
000000  460b              MOV      r3,r1
;;;478      GUI_MoveRect(pRect, pWin->Rect.x0, pWin->Rect.y0);
000002  f9b02002          LDRSH    r2,[r0,#2]
000006  f9b01000          LDRSH    r1,[r0,#0]
00000a  4618              MOV      r0,r3
00000c  f7ffbffe          B.W      GUI_MoveRect
;;;479    }
;;;480    
                          ENDP


                          AREA ||i.WM__ClipAtParentBorders||, CODE, READONLY, ALIGN=2

                  WM__ClipAtParentBorders PROC
;;;287    */
;;;288    int WM__ClipAtParentBorders(GUI_RECT* pRect, WM_HWIN hWin) {
000000  e92d41f0          PUSH     {r4-r8,lr}
000004  4607              MOV      r7,r0
000006  460e              MOV      r6,r1
                  |L19.8|
;;;289      WM_Obj* pWin;
;;;290    
;;;291      /* Iterate up the window hierarchy.
;;;292         If the window is invisible, we are done.
;;;293         Clip at parent boarders.
;;;294         We are done with iterating if hWin has no parent.
;;;295      */
;;;296      do {
;;;297        pWin = WM_H2P(hWin);
000008  4630              MOV      r0,r6
00000a  f7fffffe          BL       GUI_ALLOC_h2p
00000e  4604              MOV      r4,r0
;;;298        if ((pWin->Status & WM_SF_ISVIS) == 0) {
000010  8b80              LDRH     r0,[r0,#0x1c]
000012  0780              LSLS     r0,r0,#30
000014  d510              BPL      |L19.56|
;;;299          return 0;                     /* Invisible */
;;;300        }
;;;301        GUI__IntersectRect(pRect, &pWin->Rect);  /* And clip on borders */
000016  4621              MOV      r1,r4
000018  4638              MOV      r0,r7
00001a  f7fffffe          BL       GUI__IntersectRect
;;;302        if (pWin->hParent == 0) {
00001e  f9b45016          LDRSH    r5,[r4,#0x16]
000022  b10d              CBZ      r5,|L19.40|
;;;303          break;   /* hWin is now the top level window which has no parent */
;;;304        }
;;;305        hWin = pWin->hParent;                    /* Go one level up (parent)*/
000024  462e              MOV      r6,r5
;;;306      } while (1);                               /* Only way out is in the loop. Required for efficiency, no bug, even though some compilers may complain. */
000026  e7ef              B        |L19.8|
                  |L19.40|
000028  4804              LDR      r0,|L19.60|
00002a  f9b00000          LDRSH    r0,[r0,#0]  ; WM__ahDesktopWin
00002e  42b0              CMP      r0,r6
000030  d102              BNE      |L19.56|
;;;307      
;;;308      /* Now check if the top level window is a desktop window. If it is not,
;;;309        then the window is not visible.
;;;310      */
;;;311      if (_DesktopHandle2Index(hWin) < 0) {
;;;312        return 0;           /* No desktop - (unattached) - Nothing to draw */
;;;313      }
;;;314      return 1;               /* Something may be visible */
000032  2001              MOVS     r0,#1
                  |L19.52|
;;;315    }
000034  e8bd81f0          POP      {r4-r8,pc}
                  |L19.56|
000038  2000              MOVS     r0,#0                 ;312
00003a  e7fb              B        |L19.52|
;;;316    
                          ENDP

                  |L19.60|
                          DCD      ||.data||+0xa

                          AREA ||i.WM__DetachWindow||, CODE, READONLY, ALIGN=1

                  WM__DetachWindow PROC
;;;439    */
;;;440    void WM__DetachWindow(WM_HWIN hWin) {
000000  b570              PUSH     {r4-r6,lr}
000002  4605              MOV      r5,r0
;;;441      WM_Obj* pWin;
;;;442      WM_HWIN hParent;
;;;443      pWin = WM_H2P(hWin);
000004  f7fffffe          BL       GUI_ALLOC_h2p
000008  4604              MOV      r4,r0
;;;444      hParent = pWin->hParent;
00000a  8ac0              LDRH     r0,[r0,#0x16]
;;;445      if (hParent) {
00000c  2800              CMP      r0,#0
00000e  d007              BEQ      |L20.32|
;;;446        WM__RemoveWindowFromList(hWin);
000010  4628              MOV      r0,r5
000012  f7fffffe          BL       WM__RemoveWindowFromList
;;;447        /* Clear area used by this window */
;;;448        WM_InvalidateArea(&pWin->Rect);
000016  4620              MOV      r0,r4
000018  f7fffffe          BL       WM_InvalidateArea
;;;449        pWin->hParent = 0;
00001c  2000              MOVS     r0,#0
00001e  82e0              STRH     r0,[r4,#0x16]
                  |L20.32|
;;;450      }
;;;451    }
000020  bd70              POP      {r4-r6,pc}
;;;452    
                          ENDP


                          AREA ||i.WM__GetClientRectWin||, CODE, READONLY, ALIGN=1

                  WM__GetClientRectWin PROC
;;;707    */
;;;708    void WM__GetClientRectWin(const WM_Obj* pWin, GUI_RECT* pRect) {
000000  2200              MOVS     r2,#0
;;;709      pRect->x0 = pRect->y0 = 0;
000002  804a              STRH     r2,[r1,#2]
000004  800a              STRH     r2,[r1,#0]
;;;710      pRect->x1 = pWin->Rect.x1 - pWin->Rect.x0;
000006  8882              LDRH     r2,[r0,#4]
000008  8803              LDRH     r3,[r0,#0]
00000a  1ad2              SUBS     r2,r2,r3
00000c  808a              STRH     r2,[r1,#4]
;;;711      pRect->y1 = pWin->Rect.y1 - pWin->Rect.y0;
00000e  88c2              LDRH     r2,[r0,#6]
000010  8840              LDRH     r0,[r0,#2]
000012  1a10              SUBS     r0,r2,r0
000014  80c8              STRH     r0,[r1,#6]
;;;712    }
000016  4770              BX       lr
;;;713    
                          ENDP


                          AREA ||i.WM__GetNextIVR||, CODE, READONLY, ALIGN=2

                  WM__GetNextIVR PROC
;;;1167   */
;;;1168   int  WM__GetNextIVR(void) {
000000  b510              PUSH     {r4,lr}
;;;1169     #if GUI_SUPPORT_CURSOR
;;;1170       static char _CursorHidden;
;;;1171     #endif
;;;1172     /* If WM is not active, we have no rectangles to return */
;;;1173     if (WM_IsActive==0) {
000002  480c              LDR      r0,|L22.52|
000004  7800              LDRB     r0,[r0,#0]  ; WM_IsActive
000006  b908              CBNZ     r0,|L22.12|
                  |L22.8|
;;;1174       return 0;
000008  2000              MOVS     r0,#0
;;;1175     }
;;;1176     if (_ClipContext.EntranceCnt > 1) {
;;;1177       _ClipContext.EntranceCnt--;
;;;1178       return 0;
;;;1179     }
;;;1180     #if GUI_SUPPORT_CURSOR
;;;1181       if (_CursorHidden) {
;;;1182         _CursorHidden = 0;
;;;1183         (*GUI_CURSOR_pfTempUnhide) ();
;;;1184       }
;;;1185     #endif
;;;1186     ++_ClipContext.Cnt;
;;;1187     /* Find next rectangle and use it as ClipRect */
;;;1188     if (!_FindNext_IVR()) {
;;;1189       _ClipContext.EntranceCnt--;  /* This search is over ! */
;;;1190       return 0;        /* Could not find an other one ! */
;;;1191     }
;;;1192     WM__ActivateClipRect();
;;;1193     /* Hide cursor if necessary */
;;;1194     #if GUI_SUPPORT_CURSOR
;;;1195       if (GUI_CURSOR_pfTempHide) {
;;;1196         _CursorHidden = (*GUI_CURSOR_pfTempHide) ( &_ClipContext.CurRect);
;;;1197       }
;;;1198     #endif
;;;1199     return 1;
;;;1200   }
00000a  bd10              POP      {r4,pc}
                  |L22.12|
00000c  4c0a              LDR      r4,|L22.56|
00000e  6960              LDR      r0,[r4,#0x14]         ;1176  ; _ClipContext
000010  2801              CMP      r0,#1                 ;1176
000012  dd02              BLE      |L22.26|
                  |L22.20|
000014  1e40              SUBS     r0,r0,#1              ;1177
000016  6160              STR      r0,[r4,#0x14]         ;1178  ; _ClipContext
000018  e7f6              B        |L22.8|
                  |L22.26|
00001a  6920              LDR      r0,[r4,#0x10]         ;1186  ; _ClipContext
00001c  1c40              ADDS     r0,r0,#1              ;1186
00001e  6120              STR      r0,[r4,#0x10]         ;1188  ; _ClipContext
000020  f7fffffe          BL       _FindNext_IVR
000024  b908              CBNZ     r0,|L22.42|
000026  6960              LDR      r0,[r4,#0x14]         ;1190  ; _ClipContext
000028  e7f4              B        |L22.20|
                  |L22.42|
00002a  f7fffffe          BL       WM__ActivateClipRect
00002e  2001              MOVS     r0,#1                 ;1199
000030  bd10              POP      {r4,pc}
;;;1201   
                          ENDP

000032  0000              DCW      0x0000
                  |L22.52|
                          DCD      ||.data||
                  |L22.56|
                          DCD      ||area_number.47||

                          AREA ||i.WM__InitIVRSearch||, CODE, READONLY, ALIGN=2

                  WM__InitIVRSearch PROC
;;;1213   */
;;;1214   int WM__InitIVRSearch(const GUI_RECT* pMaxRect) {

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -