📄 listview.txt
字号:
|L14.356|
000164 f7fffffe BL LCD_SetColor
;;;218 }
;;;219 /* Clear background */
;;;220 GUI_ClearRect(Rect.x0, Rect.y0, Rect.x1, Rect.y1);
000168 f9bd3026 LDRSH r3,[sp,#0x26]
00016c f9bd2024 LDRSH r2,[sp,#0x24]
000170 f9bd1022 LDRSH r1,[sp,#0x22]
000174 f9bd0020 LDRSH r0,[sp,#0x20]
000178 f7fffffe BL GUI_ClearRect
;;;221 /* Draw text */
;;;222 Rect.x0 += LBorder;
00017c f8bd0020 LDRH r0,[sp,#0x20]
000180 9905 LDR r1,[sp,#0x14]
000182 4408 ADD r0,r0,r1
000184 f8ad0020 STRH r0,[sp,#0x20]
;;;223 Rect.x1 -= RBorder;
000188 f8bd0024 LDRH r0,[sp,#0x24]
00018c 9904 LDR r1,[sp,#0x10]
00018e 1a40 SUBS r0,r0,r1
000190 f8ad0024 STRH r0,[sp,#0x24]
;;;224 Align = *((int*)GUI_ARRAY_GetpItem(&pObj->AlignArray, j));
000194 4639 MOV r1,r7
000196 f104002e ADD r0,r4,#0x2e
00019a f7fffffe BL GUI_ARRAY_GetpItem
;;;225 GUI_DispStringInRect(pItem->acText, &Rect, Align);
00019e 6802 LDR r2,[r0,#0]
0001a0 a908 ADD r1,sp,#0x20
0001a2 1ca8 ADDS r0,r5,#2
0001a4 f7fffffe BL GUI_DispStringInRect
;;;226 if (pItem->hItemInfo) {
0001a8 8828 LDRH r0,[r5,#0]
0001aa b138 CBZ r0,|L14.444|
;;;227 LCD_SetBkColor(pObj->Props.aBkColor[ColorIndex]);
0001ac e002 B |L14.436|
|L14.430|
0001ae e016 B |L14.478|
|L14.432|
0001b0 e01c B |L14.492|
|L14.434|
0001b2 e013 B |L14.476|
|L14.436|
0001b4 f8d90034 LDR r0,[r9,#0x34]
0001b8 f7fffffe BL LCD_SetBkColor
|L14.444|
0001bc 4655 MOV r5,r10
0001be 1c7f ADDS r7,r7,#1 ;199
|L14.448|
0001c0 9806 LDR r0,[sp,#0x18] ;199
0001c2 4287 CMP r7,r0 ;199
0001c4 dba2 BLT |L14.268|
|L14.454|
;;;228 }
;;;229 }
;;;230 xPos += Width;
;;;231 }
;;;232 /* Clear unused area to the right of items */
;;;233 if (xPos <= ClipRect.x1) {
0001c6 f9bd202c LDRSH r2,[sp,#0x2c]
0001ca 42aa CMP r2,r5
0001cc db06 BLT |L14.476|
;;;234 GUI_ClearRect(xPos, Rect.y0, ClipRect.x1, Rect.y1);
0001ce f9bd3026 LDRSH r3,[sp,#0x26]
0001d2 f9bd1022 LDRSH r1,[sp,#0x22]
0001d6 4628 MOV r0,r5
0001d8 f7fffffe BL GUI_ClearRect
|L14.476|
0001dc 9d0d LDR r5,[sp,#0x34]
|L14.478|
0001de f1080001 ADD r0,r8,#1 ;175
|L14.482|
0001e2 9901 LDR r1,[sp,#4] ;175
0001e4 4680 MOV r8,r0 ;175
0001e6 4288 CMP r0,r1 ;175
0001e8 f6ffaf5b BLT |L14.162|
|L14.492|
;;;235 }
;;;236 }
;;;237 yPos += RowDistY;
;;;238 }
;;;239 }
;;;240 /* Clear unused area below items */
;;;241 if (yPos <= ClipRect.y1) {
0001ec f9bd002e LDRSH r0,[sp,#0x2e]
0001f0 42a8 CMP r0,r5
0001f2 db0b BLT |L14.524|
;;;242 LCD_SetBkColor(pObj->Props.aBkColor[0]);
0001f4 6b60 LDR r0,[r4,#0x34]
0001f6 f7fffffe BL LCD_SetBkColor
;;;243 GUI_ClearRect(ClipRect.x0, yPos, ClipRect.x1, ClipRect.y1);
0001fa f9bd302e LDRSH r3,[sp,#0x2e]
0001fe f9bd202c LDRSH r2,[sp,#0x2c]
000202 f9bd0028 LDRSH r0,[sp,#0x28]
000206 4629 MOV r1,r5
000208 f7fffffe BL GUI_ClearRect
|L14.524|
;;;244 }
;;;245 /* Draw grid */
;;;246 if (pObj->ShowGrid) {
00020c 6da0 LDR r0,[r4,#0x58]
00020e b3f0 CBZ r0,|L14.654|
;;;247 LCD_SetColor(pObj->Props.GridColor);
000210 6ce0 LDR r0,[r4,#0x4c]
000212 f7fffffe BL LCD_SetColor
;;;248 yPos = HEADER_GetHeight(pObj->hHeader) + EffectSize - 1;
000216 f9b40028 LDRSH r0,[r4,#0x28]
00021a f7fffffe BL HEADER_GetHeight
00021e 9903 LDR r1,[sp,#0xc]
000220 1845 ADDS r5,r0,r1
000222 1e6d SUBS r5,r5,#1
;;;249 for (i = 0; i < NumVisRows; i++) {
000224 2600 MOVS r6,#0
000226 e011 B |L14.588|
|L14.552|
;;;250 yPos += RowDistY;
000228 9802 LDR r0,[sp,#8]
00022a 4405 ADD r5,r5,r0
;;;251 /* Break when all other rows are outside the drawing area */
;;;252 if (yPos > ClipRect.y1) {
00022c f9bd002e LDRSH r0,[sp,#0x2e]
000230 42a8 CMP r0,r5
000232 db0e BLT |L14.594|
;;;253 break;
;;;254 }
;;;255 /* Make sure that we draw only when row is in drawing area */
;;;256 if (yPos >= ClipRect.y0) {
000234 f9bd002a LDRSH r0,[sp,#0x2a]
000238 42a8 CMP r0,r5
00023a dc06 BGT |L14.586|
;;;257 GUI_DrawHLine(yPos, ClipRect.x0, ClipRect.x1);
00023c f9bd202c LDRSH r2,[sp,#0x2c]
000240 f9bd1028 LDRSH r1,[sp,#0x28]
000244 4628 MOV r0,r5
000246 f7fffffe BL GUI_DrawHLine
|L14.586|
00024a 1c76 ADDS r6,r6,#1 ;249
|L14.588|
00024c 9807 LDR r0,[sp,#0x1c] ;249
00024e 4286 CMP r6,r0 ;249
000250 dbea BLT |L14.552|
|L14.594|
;;;258 }
;;;259 }
;;;260 xPos = EffectSize - pObj->ScrollStateH.v;
000252 6fa1 LDR r1,[r4,#0x78]
000254 9803 LDR r0,[sp,#0xc]
;;;261 for (i = 0; i < NumColumns; i++) {
000256 2600 MOVS r6,#0
000258 1a45 SUBS r5,r0,r1 ;260
00025a e015 B |L14.648|
|L14.604|
;;;262 xPos += HEADER_GetItemWidth(pObj->hHeader, i);
00025c f9b40028 LDRSH r0,[r4,#0x28]
000260 4631 MOV r1,r6
000262 f7fffffe BL HEADER_GetItemWidth
000266 4405 ADD r5,r5,r0
;;;263 /* Break when all other columns are outside the drawing area */
;;;264 if (xPos > ClipRect.x1) {
000268 f9bd002c LDRSH r0,[sp,#0x2c]
00026c 42a8 CMP r0,r5
00026e db10 BLT |L14.658|
;;;265 break;
;;;266 }
;;;267 /* Make sure that we draw only when column is in drawing area */
;;;268 if (xPos >= ClipRect.x0) {
000270 f9bd0028 LDRSH r0,[sp,#0x28]
000274 42a8 CMP r0,r5
000276 dc06 BGT |L14.646|
;;;269 GUI_DrawVLine(xPos, ClipRect.y0, ClipRect.y1);
000278 f9bd202e LDRSH r2,[sp,#0x2e]
00027c f9bd102a LDRSH r1,[sp,#0x2a]
000280 4628 MOV r0,r5
000282 f7fffffe BL GUI_DrawVLine
|L14.646|
000286 1c76 ADDS r6,r6,#1 ;261
|L14.648|
000288 9806 LDR r0,[sp,#0x18] ;261
00028a 4286 CMP r6,r0 ;261
00028c e000 B |L14.656|
|L14.654|
00028e e000 B |L14.658|
|L14.656|
000290 dbe4 BLT |L14.604|
|L14.658|
;;;270 }
;;;271 }
;;;272 }
;;;273 /* Draw the effect */
;;;274 WIDGET__EFFECT_DrawDown(&pObj->Widget);
000292 4620 MOV r0,r4
000294 f7fffffe BL WIDGET__EFFECT_DrawDown
;;;275 }
000298 b00f ADD sp,sp,#0x3c
00029a e8bd8ff0 POP {r4-r11,pc}
;;;276
ENDP
AREA ||i._SetSelFromPos||, CODE, READONLY, ALIGN=1
_SetSelFromPos PROC
;;;310 */
;;;311 static void _SetSelFromPos(LISTVIEW_Handle hObj, LISTVIEW_Obj* pObj, const GUI_PID_STATE* pState) {
000000 e92d41fc PUSH {r2-r8,lr}
000004 4607 MOV r7,r0
000006 460d MOV r5,r1
000008 4614 MOV r4,r2
;;;312 GUI_RECT Rect;
;;;313 int x, y, HeaderHeight;
;;;314 HeaderHeight = HEADER_GetHeight(pObj->hHeader);
00000a f9b10028 LDRSH r0,[r1,#0x28]
00000e f7fffffe BL HEADER_GetHeight
000012 4606 MOV r6,r0
;;;315 WM_GetInsideRectExScrollbar(hObj, &Rect);
000014 4669 MOV r1,sp
000016 4638 MOV r0,r7
000018 f7fffffe BL WM_GetInsideRectExScrollbar
;;;316 x = pState->x - Rect.x0;
;;;317 y = pState->y - Rect.y0 - HeaderHeight;
00001c f9bd2002 LDRSH r2,[sp,#2]
000020 6863 LDR r3,[r4,#4]
000022 6820 LDR r0,[r4,#0] ;316
000024 eba30302 SUB r3,r3,r2
000028 f9bd1000 LDRSH r1,[sp,#0] ;316
00002c eba30406 SUB r4,r3,r6
;;;318 Rect.x1 -= Rect.x0;
000030 f8bd3004 LDRH r3,[sp,#4]
000034 1a40 SUBS r0,r0,r1 ;316
000036 eba30101 SUB r1,r3,r1
00003a b209 SXTH r1,r1
00003c f8ad1004 STRH r1,[sp,#4]
;;;319 Rect.y1 -= Rect.y0;
000040 f8bd3006 LDRH r3,[sp,#6]
000044 eba30202 SUB r2,r3,r2
000048 b212 SXTH r2,r2
00004a f8ad2006 STRH r2,[sp,#6]
;;;320 if ((x >= 0) && (x <= Rect.x1) && (y >= 0) && (y <= (Rect.y1 - HeaderHeight))) {
00004e d417 BMI |L15.128|
000050 4281 CMP r1,r0
000052 db15 BLT |L15.128|
000054 2c00 CMP r4,#0
000056 db13 BLT |L15.128|
000058 1b90 SUBS r0,r2,r6
00005a 42a0 CMP r0,r4
00005c db10 BLT |L15.128|
;;;321 unsigned Sel;
;;;322 Sel = (y / LISTVIEW__GetRowDistY(pObj)) + pObj->ScrollStateV.v;
00005e 4628 MOV r0,r5
000060 f7fffffe BL LISTVIEW__GetRowDistY
000064 fbb4f0f0 UDIV r0,r4,r0
000068 6ee9 LDR r1,[r5,#0x6c]
00006a 1844 ADDS r4,r0,r1
;;;323 if (Sel < GUI_ARRAY_GetNumItems(&pObj->RowArray)) {
00006c f105002a ADD r0,r5,#0x2a
000070 f7fffffe BL GUI_ARRAY_GetNumItems
000074 42a0 CMP r0,r4
000076 d903 BLS |L15.128|
;;;324 LISTVIEW_SetSel(hObj, Sel);
000078 4621 MOV r1,r4
00007a 4638 MOV r0,r7
00007c f7fffffe BL LISTVIEW_SetSel
|L15.128|
;;;325 }
;;;326 }
;;;327 }
000080 e8bd81fc POP {r2-r8,pc}
;;;328
ENDP
AREA ||.data||, DATA, ALIGN=2
LISTVIEW_DefaultProps
DCD 0x00ffffff
DCD 0x00808080
DCD 0x00ff0000
DCD 0x00000000
DCD 0x00ffffff
DCD 0x00ffffff
DCD 0x00d3d3d3
DCD GUI_Font13_1
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -