flat assembler
Message board for the users of flat assembler.

Index > Windows > Win 10 after ShowWindow,SW_HIDE i not see window on panel !

Author
Thread Post new topic Reply to topic
Roman



Joined: 21 Apr 2012
Posts: 1839
Roman 16 Dec 2020, 13:10
Fasmw 1.73 64 bit program.
Very interesting.

I create window.
Do Msg 'dd' and see my window
Then i do ShowWindow,[hwnd],SW_HIDE
My window hidden, but i not see on window panel my window icon !

Then i do Sleep,2000
And do ShowWindow,[hwnd],1
And my window now see on screen.
https://www.youtube.com/watch?v=ZYNuB2ixpB0&feature=youtu.be&ab_channel=Roman8139

My problem not see on windows 10 panel my window icon !
Because i want click on windows 10 panel and show my window again !
Post 16 Dec 2020, 13:10
View user's profile Send private message Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1839
Roman 16 Dec 2020, 13:17
But if i click on my window hidden button i see in windows 10 panel my window icon.
Post 16 Dec 2020, 13:17
View user's profile Send private message Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1839
Roman 16 Dec 2020, 13:20
My WndProc:
Code:
proc WindowProc uses rbx rsi rdi, hwnd,wmsg,wparam,lparam


       mov     [hwnd],rcx
;       mov     [wmsg],edx
       mov     [wparam],r8
;       mov     [lparam],r9
        cmp edx,WM_CREATE
        jnz .rr
   
        ret
.rr:
        cmp edx,WM_KILLFOCUS
        jnz .0
        mov  byte [FocusWinLost],1
        ret
.0:     cmp edx,WM_SETFOCUS
        jnz .0b
        mov  byte [FocusWinLost],0
        ret
.0b:
    rept 0 {
        cmp edx, WM_PAINT
            jnz .1
              invoke BeginPaint,[hwnd], ps ;*=mozno bez             
              invoke EndPaint,[hwnd], ps   ;*
              ret
          .1:
          }
;KeyPr
        cmp edx, WM_KEYDOWN
            cmp [wparam],VK_ESCAPE
            jz  .wmdestroy
            ;jnz .zznoescp
         ;jnz  .4
              mov eax,dword [wparam]
              ;cmp dword [KeyPr],0
              ;jnz .4
              mov dword [KeyPr],eax
              mov eax,1
              ;jmp .defwndproc
              ;cmp eax,VK_F6
              ;jnz .v
              ;Msg 'VK_F6'
              ;mov dword [KeyPr],0
 ;.v:        ;ret                    ;tut iz-za ret exit iz progi !
    .4:
            cmp edx, WM_LBUTTONDOWN
            jnz .02
            mov [mous_btn],1
            ;invoke  MessageBox,0,'ok',0,0
            ret
.02:        cmp edx, WM_LBUTTONUP
            jnz .03
            mov [mous_btn],0
            ret
.03:         cmp edx, WM_RBUTTONDOWN
            jnz .02b
            mov [mous_rbtn],1
            ;invoke  MessageBox,0,'ok',0,0
            ret
.02b:       cmp edx, WM_RBUTTONUP
            jnz .03b
            mov [mous_rbtn],0
            ret
.03b:
;mouse wheel
        cmp edx, WM_MOUSEWHEEL
            jnz .2
            mov ax,word [wparam+2]
            test ax,ax
            jl .WheelDwn
            mov     byte [MousWheel], 1     ;Mous koleso krutili v pered
            ret
      .WheelDwn:
            mov     byte [MousWheel], 2     ;Mous koleso krutili nazad
            ret
  .2:
        cmp     edx,WM_DESTROY
        je      .wmdestroy
  .defwndproc:
        invoke  DefWindowProc,rcx,rdx,r8,r9
        jmp     .finish
  .wmdestroy:
        ;invoke  PostQuitMessage,dword 0    ;bugi i net exit Msg-a !
        mov     [CloseWin],1
        xor     eax,eax
  .finish:
        ret                           
    
Post 16 Dec 2020, 13:20
View user's profile Send private message Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1839
Roman 20 Dec 2020, 12:33
Need write SW_MINIMIZE
SW_HIDE work correct !
Post 20 Dec 2020, 12:33
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.