Home > Software engineering >  Parent window controls the picture dialog box or controls?
Parent window controls the picture dialog box or controls?

Time:09-24

CodePudding user response:

Use spy++ see,

CodePudding user response:

Since the draw control CListCtrl? (ICON style)

CodePudding user response:

CButton (icon) is placed, CStatic (controls) images, custom painting, a lot can do similar effect

CodePudding user response:

If I do will use ListCtrl

CodePudding user response:

Elder sister, static function and class as static variables has been memory? Till the end of the program just released
reference 1st floor schlafenhamster response:
with spy++ see,

CodePudding user response:

Class static function belongs to the class with class static variables, not belong to the class instance, going to class destructor (out) before release

CodePudding user response:

If not custom painting, it should be a dialog

CodePudding user response:

ListView

CodePudding user response:

Static function in the memory of 4 bytes,,,
refer to 6th floor schlafenhamster response:
static function and class static variable belongs to the class, not belong to the class instance, going to class destructor (out) to release

CodePudding user response:

Class static function in 4 bytes of memory? Won't you? A function pointer is 4 bytes.
What are you in the disassembly?

CodePudding user response:

If the function is no Prolog and Eliplog (naked) this function can be only a ret assembly bytes;

 
__declspec (naked) void __stdcall _WaveEffect (int waveType, int param1, int param2, int param3)
{
The __asm
{
Push ebp
Mov ebp, esp
Add the esp, 0 fffffff8h
Push ebx
Push eax
Lea ebx, g_WaveObj
Mov eax, [waveType]
The or eax, eax
JNZ short jnzTyp
; WClose=0
And [ebx + WAVE_OBJECT. DwFlag], NOT (F_WO_EFFECT);
Mov [ebx + WAVE_OBJECT dwEffectType], eax
JMP short typ0Ret
JnzTyp:
CMP eax, 2; Wlaunch
JNZ short jnz2
; Wain=1; Wlaunch=2
Mov eax, [param1]
Mov [ebx + WAVE_OBJECT dwEff2XAdd], eax
Mov [ebx + WAVE_OBJECT dwEff2YAdd], eax
Mov eax, [ebx + WAVE_OBJECT dwBmpWidth]
Dec eax
Dec eax
Push eax. DwMax
Push ebx. LpWaveObject
Call _WaveRandom
Inc eax
Mov [ebx + WAVE_OBJECT dwEff2X], eax
Mov eax, [ebx + WAVE_OBJECT dwBmpHeight]
Dec eax
Dec eax
Push eax. DwMax
Push ebx. LpWaveObject
Call _WaveRandom
Inc eax
Mov [ebx + WAVE_OBJECT dwEff2Y], eax
; JMP short jnz2
Jnz2:;//end switch
Push [waveType]
Pop [ebx + WAVE_OBJECT dwEffectType]
Push [param1]
Pop [ebx + WAVE_OBJECT dwEffectParam1]
Push [param2]
Pop [ebx + WAVE_OBJECT dwEffectParam2]
Push [param3]
Pop [ebx + WAVE_OBJECT dwEffectParam3]
/[ebx + WAVE_OBJECT dwFlag], F_WO_EFFECT
Typ0Ret:
Pop eax
Pop ebx
Leave
Retn 10 h
}
}


In addition to understand the namespace "class structure"
  • Related