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

📄 wm.txt

📁 STM32F103ZET6+UCOSII+UCGUI源码
💻 TXT
📖 第 1 页 / 共 5 页
字号:
000022  f7fffffe          BL       WM__GetClientRectWin
;;;1672       break;
000026  e014              B        |L5.82|
                  |L5.40|
000028  2922              CMP      r1,#0x22              ;1669
00002a  d00f              BEQ      |L5.76|
00002c  2928              CMP      r1,#0x28              ;1669
00002e  d110              BNE      |L5.82|
000030  4628              MOV      r0,r5                 ;1669
000032  e8bd4070          POP      {r4-r6,lr}            ;1669
000036  2100              MOVS     r1,#0                 ;1669
000038  f7ffbffe          B.W      WM_InvalidateRect
                  |L5.60|
;;;1673     case WM_GET_CLIENT_WINDOW:      /* return handle to client window. For most windows, there is no seperate client window, so it is the same handle */
;;;1674       pMsg->Data.v = (int)hWin;
;;;1675       return;                       /* Message handled */
00003c  60a5              STR      r5,[r4,#8]
;;;1676     case WM_KEY:
;;;1677       WM_SendToParent(hWin, pMsg);
;;;1678       return;                       /* Message handled */
;;;1679      case WM_GET_BKCOLOR:
;;;1680       pMsg->Data.Color = GUI_INVALID_COLOR;
;;;1681       return;                       /* Message handled */
;;;1682     case WM_NOTIFY_ENABLE:
;;;1683       WM_InvalidateWindow(hWin);    
;;;1684       return;                       /* Message handled */
;;;1685     }
;;;1686     /* Message not handled. If it queries something, we return 0 to be on the safe side. */
;;;1687     pMsg->Data.v = 0;
;;;1688     pMsg->Data.p = 0;
;;;1689   }
00003e  bd70              POP      {r4-r6,pc}
                  |L5.64|
000040  4621              MOV      r1,r4                 ;1677
000042  4628              MOV      r0,r5                 ;1677
000044  e8bd4070          POP      {r4-r6,lr}            ;1677
000048  f7ffbffe          B.W      WM_SendToParent
                  |L5.76|
00004c  f06f4070          MVN      r0,#0xf0000000        ;1680
000050  e000              B        |L5.84|
                  |L5.82|
000052  2000              MOVS     r0,#0                 ;1687
                  |L5.84|
000054  60a0              STR      r0,[r4,#8]            ;1687
000056  bd70              POP      {r4-r6,pc}
;;;1690   
                          ENDP


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

                  WM_DeleteWindow PROC
;;;899    */
;;;900    void WM_DeleteWindow (WM_HWIN hWin) {
000000  b570              PUSH     {r4-r6,lr}
000002  0004              MOVS     r4,r0
;;;901      WM_Obj* pWin;
;;;902      if (!hWin) {
000004  d049              BEQ      |L6.154|
;;;903        return;
;;;904      }
;;;905      WM_ASSERT_NOT_IN_PAINT();
;;;906      WM_LOCK();
;;;907      if (WM__IsWindow(hWin)) {
000006  4620              MOV      r0,r4
000008  f7fffffe          BL       WM__IsWindow
00000c  2800              CMP      r0,#0
00000e  d044              BEQ      |L6.154|
;;;908        pWin = WM_H2P(hWin);
000010  4620              MOV      r0,r4
000012  f7fffffe          BL       GUI_ALLOC_h2p
000016  4605              MOV      r5,r0
000018  4e20              LDR      r6,|L6.156|
00001a  2000              MOVS     r0,#0
00001c  82b0              STRH     r0,[r6,#0x14]
;;;909        ResetNextDrawWin();              /* Make sure the window will no longer receive drawing messages */
;;;910      /* Make sure that focus is set to an existing window */
;;;911        if (WM__hWinFocus == hWin) {
00001e  f9b61010          LDRSH    r1,[r6,#0x10]  ; WM__hWinFocus
000022  42a1              CMP      r1,r4
000024  d100              BNE      |L6.40|
;;;912          WM__hWinFocus = 0;
000026  8230              STRH     r0,[r6,#0x10]
                  |L6.40|
;;;913        }
;;;914        if (WM__hCapture == hWin) {
000028  f9b6100e          LDRSH    r1,[r6,#0xe]  ; WM__hCapture
00002c  42a1              CMP      r1,r4
00002e  d100              BNE      |L6.50|
;;;915          WM__hCapture = 0;
000030  81f0              STRH     r0,[r6,#0xe]
                  |L6.50|
000032  69b1              LDR      r1,[r6,#0x18]  ; WM__pFirstCriticalHandle
000034  e006              B        |L6.68|
000036  bf00              NOP      
                  |L6.56|
000038  f9b12004          LDRSH    r2,[r1,#4]
00003c  42a2              CMP      r2,r4
00003e  d100              BNE      |L6.66|
000040  8088              STRH     r0,[r1,#4]
                  |L6.66|
000042  6809              LDR      r1,[r1,#0]
                  |L6.68|
000044  2900              CMP      r1,#0
000046  d1f7              BNE      |L6.56|
;;;916        }
;;;917        /* check if critical handles are affected. If so, reset the window handle to 0 */
;;;918        _CheckCriticalHandles(hWin);
;;;919        /* Inform parent */
;;;920        WM_NotifyParent(hWin, WM_NOTIFICATION_CHILD_DELETED);
000048  2107              MOVS     r1,#7
00004a  4620              MOV      r0,r4
00004c  f7fffffe          BL       WM_NotifyParent
;;;921        /* Delete all children */
;;;922        _DeleteAllChildren(pWin->hFirstChild);
000050  f9b50018          LDRSH    r0,[r5,#0x18]
000054  f7fffffe          BL       _DeleteAllChildren
;;;923        #if WM_SUPPORT_NOTIFY_VIS_CHANGED
;;;924          WM__SendMsgNoData(hWin, WM_NOTIFY_VIS_CHANGED);             /* Notify window that visibility may have changed */
;;;925        #endif
;;;926        /* Send WM_DELETE message to window in order to inform window itself */
;;;927        WM__SendMsgNoData(hWin, WM_DELETE);     /* tell window about it */
000058  210b              MOVS     r1,#0xb
00005a  4620              MOV      r0,r4
00005c  f7fffffe          BL       WM__SendMsgNoData
;;;928        WM__DetachWindow(hWin);
000060  4620              MOV      r0,r4
000062  f7fffffe          BL       WM__DetachWindow
;;;929        /* Remove window from window stack */
;;;930        WM__RemoveFromLinList(hWin);
000066  4620              MOV      r0,r4
000068  f7fffffe          BL       WM__RemoveFromLinList
;;;931        /* Handle transparency counter if necessary */
;;;932        #if WM_SUPPORT_TRANSPARENCY
;;;933          if (pWin->Status & WM_SF_HASTRANS) {
00006c  8ba8              LDRH     r0,[r5,#0x1c]
00006e  07c1              LSLS     r1,r0,#31
000070  d002              BEQ      |L6.120|
;;;934            WM__TransWindowCnt--;
000072  6a71              LDR      r1,[r6,#0x24]  ; WM__TransWindowCnt
000074  1e49              SUBS     r1,r1,#1
000076  6271              STR      r1,[r6,#0x24]  ; WM__TransWindowCnt
                  |L6.120|
;;;935          }
;;;936        #endif
;;;937        /* Make sure window is no longer counted as invalid */
;;;938        if (pWin->Status & WM_SF_INVALID) {
000078  0680              LSLS     r0,r0,#26
00007a  d502              BPL      |L6.130|
;;;939          WM__NumInvalidWindows--;
00007c  88f0              LDRH     r0,[r6,#6]  ; WM__NumInvalidWindows
00007e  1e40              SUBS     r0,r0,#1
000080  80f0              STRH     r0,[r6,#6]
                  |L6.130|
;;;940        }
;;;941      /* Free window memory */
;;;942        WM__NumWindows--;
000082  88b0              LDRH     r0,[r6,#4]  ; WM__NumWindows
000084  1e40              SUBS     r0,r0,#1
000086  80b0              STRH     r0,[r6,#4]
;;;943        GUI_ALLOC_Free(hWin);
000088  4620              MOV      r0,r4
00008a  f7fffffe          BL       GUI_ALLOC_Free
;;;944      /* Select a valid window */
;;;945        WM_SelectWindow(WM__FirstWin);
00008e  f9b60008          LDRSH    r0,[r6,#8]  ; WM__FirstWin
000092  e8bd4070          POP      {r4-r6,lr}
000096  f7ffbffe          B.W      WM_SelectWindow
                  |L6.154|
;;;946      } else {
;;;947        GUI_DEBUG_WARN("WM_DeleteWindow: Invalid handle");
;;;948      }
;;;949      WM_UNLOCK();
;;;950    }
00009a  bd70              POP      {r4-r6,pc}
;;;951    
                          ENDP

                  |L6.156|
                          DCD      ||.data||

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

                  WM_Exec PROC
;;;1591   */
;;;1592   int WM_Exec(void) {
000000  b510              PUSH     {r4,lr}
;;;1593     int r = 0;
000002  2400              MOVS     r4,#0
;;;1594     while (WM_Exec1()) {
000004  e000              B        |L7.8|
                  |L7.6|
;;;1595       r = 1;                  /* We have done something */
000006  2401              MOVS     r4,#1
                  |L7.8|
000008  f7fffffe          BL       WM_Exec1
00000c  2800              CMP      r0,#0                 ;1594
00000e  d1fa              BNE      |L7.6|
;;;1596     }
;;;1597     return r;
000010  4620              MOV      r0,r4
;;;1598   }
000012  bd10              POP      {r4,pc}
;;;1599   
                          ENDP


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

                  WM_Exec1 PROC
;;;1566   */
;;;1567   int WM_Exec1(void) {
000000  b5f0              PUSH     {r4-r7,lr}
;;;1568     /* Poll PID if necessary */
;;;1569     if (WM_pfPollPID) {
000002  4e1a              LDR      r6,|L8.108|
000004  b099              SUB      sp,sp,#0x64           ;1567
000006  6a30              LDR      r0,[r6,#0x20]  ; WM_pfPollPID
000008  b100              CBZ      r0,|L8.12|
;;;1570       WM_pfPollPID();
00000a  4780              BLX      r0
                  |L8.12|
;;;1571     }
;;;1572     if (WM_pfHandlePID) {
00000c  4818              LDR      r0,|L8.112|
00000e  6800              LDR      r0,[r0,#0]  ; WM_pfHandlePID
000010  b108              CBZ      r0,|L8.22|
;;;1573       if (WM_pfHandlePID())
000012  4780              BLX      r0
000014  b910              CBNZ     r0,|L8.28|
                  |L8.22|
;;;1574         return 1;               /* We have done something ... */
;;;1575     }
;;;1576     if (GUI_PollKeyMsg()) {
000016  f7fffffe          BL       GUI_PollKeyMsg
00001a  b110              CBZ      r0,|L8.34|
                  |L8.28|
;;;1577       return 1;               /* We have done something ... */
00001c  2001              MOVS     r0,#1
                  |L8.30|
;;;1578     }
;;;1579     if (WM_IsActive && WM__NumInvalidWindows) {
;;;1580       WM_LOCK();
;;;1581       _DrawNext();
;;;1582       WM_UNLOCK();
;;;1583       return 1;               /* We have done something ... */
;;;1584     }
;;;1585     return 0;                  /* There was nothing to do ... */
;;;1586   }
00001e  b019              ADD      sp,sp,#0x64
000020  bdf0              POP      {r4-r7,pc}
                  |L8.34|
000022  7830              LDRB     r0,[r6,#0]            ;1579  ; WM_IsActive
000024  b300              CBZ      r0,|L8.104|
000026  88f0              LDRH     r0,[r6,#6]            ;1579  ; WM__NumInvalidWindows
000028  b1f0              CBZ      r0,|L8.104|
00002a  f9b65008          LDRSH    r5,[r6,#8]            ;1579  ; WM__FirstWin
00002e  f9b60014          LDRSH    r0,[r6,#0x14]         ;1579  ; NextDrawWin
000032  2401              MOVS     r4,#1                 ;1579
000034  b100              CBZ      r0,|L8.56|
000036  4605              MOV      r5,r0                 ;1579
                  |L8.56|
000038  a801              ADD      r0,sp,#4              ;1579
00003a  f7fffffe          BL       GUI_SaveContext_W_M
00003e  e00b              B        |L8.88|
                  |L8.64|
000040  4628              MOV      r0,r5                 ;1579
000042  f7fffffe          BL       GUI_ALLOC_h2p
000046  4607              MOV      r7,r0                 ;1579
000048  4601              MOV      r1,r0                 ;1579
00004a  4628              MOV      r0,r5                 ;1579
00004c  f7fffffe          BL       _Paint
000050  b100              CBZ      r0,|L8.84|
000052  1e64              SUBS     r4,r4,#1              ;1579
                  |L8.84|
000054  f9b75014          LDRSH    r5,[r7,#0x14]         ;1579
                  |L8.88|
000058  b10d              CBZ      r5,|L8.94|
00005a  2c00              CMP      r4,#0                 ;1579
00005c  d1f0              BNE      |L8.64|
                  |L8.94|
00005e  82b5              STRH     r5,[r6,#0x14]         ;1579
000060  a801              ADD      r0,sp,#4              ;1579
000062  f7fffffe          BL       GUI_RestoreContext
000066  e7d9              B        |L8.28|
                  |L8.104|
000068  2000              MOVS     r0,#0                 ;1585
00006a  e7d8              B        |L8.30|
;;;1587   
                          ENDP

                  |L8.108|
                          DCD      ||.data||
                  |L8.112|
                          DCD      WM_pfHandlePID

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

                  WM_GetActiveWindow PROC
;;;993    */
;;;994    WM_HWIN WM_GetActiveWindow(void) {
000000  4801              LDR      r0,|L9.8|
;;;995      return GUI_Context.hAWin;
000002  f9b0003c          LDRSH    r0,[r0,#0x3c]  ; GUI_Context

⌨️ 快捷键说明

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