Je rencontre un problème bizarre.
Je dois mettre une fenêtre en TopMost.
Si je fais ça, ca fonctionne très bien :
// --------------------------------
SetWindowPos( hwd_win32 ,
HWND_TOPMOST ,
0,0,0,0 ,
SWP_NOMOVE|SWP_NOSIZE|SWP_NOACTIVATE
) )
// --------------------------------
Par contre, si je fais ça, ca ne fonctionne pas :
// --------------------------------
LONG oldStyle = GetWindowLong( hwd_win32 , GWL_EXSTYLE );
SetWindowLong(
hwd_win32 ,
GWL_EXSTYLE ,
oldStyle | WS_EX_TOPMOST //& (!WS_EX_APPWINDOW)
)
// --------------------------------
Comprends pas pourquoi !?
Je vous remercie par avance pour vos réponses ô combien toujours
éclairantes !
Cette action est irreversible, confirmez la suppression du commentaire ?
Signaler le commentaire
Veuillez sélectionner un problème
Nudité
Violence
Harcèlement
Fraude
Vente illégale
Discours haineux
Terrorisme
Autre
domi
tsalm wrote:
Par contre, si je fais ça, ca ne fonctionne pas : // -------------------------------- LONG oldStyle = GetWindowLong( hwd_win32 , GWL_EXSTYLE ); SetWindowLong( hwd_win32 , GWL_EXSTYLE , oldStyle | WS_EX_TOPMOST //& (!WS_EX_APPWINDOW) ) // --------------------------------
Comprends pas pourquoi !?
C'est normal, çà n'a pas été prévu pour ça. C'est dans la doc MSDN :
WS_EX_TOPMOST To add or remove this style, use the SetWindowPos function.
tsalm wrote:
Par contre, si je fais ça, ca ne fonctionne pas :
// --------------------------------
LONG oldStyle = GetWindowLong( hwd_win32 , GWL_EXSTYLE );
SetWindowLong(
hwd_win32 ,
GWL_EXSTYLE ,
oldStyle | WS_EX_TOPMOST //& (!WS_EX_APPWINDOW)
)
// --------------------------------
Comprends pas pourquoi !?
C'est normal, çà n'a pas été prévu pour ça.
C'est dans la doc MSDN :
WS_EX_TOPMOST
To add or remove this style, use the SetWindowPos function.
Par contre, si je fais ça, ca ne fonctionne pas : // -------------------------------- LONG oldStyle = GetWindowLong( hwd_win32 , GWL_EXSTYLE ); SetWindowLong( hwd_win32 , GWL_EXSTYLE , oldStyle | WS_EX_TOPMOST //& (!WS_EX_APPWINDOW) ) // --------------------------------
Comprends pas pourquoi !?
C'est normal, çà n'a pas été prévu pour ça. C'est dans la doc MSDN :
WS_EX_TOPMOST To add or remove this style, use the SetWindowPos function.
tsalm
On 23 août, 21:54, domi wrote:
tsalm wrote: > Par contre, si je fais ça, ca ne fonctionne pas : > // -------------------------------- > LONG oldStyle = GetWindowLong( hwd_win32 , GWL_EXSTYLE ); > SetWindowLong( > hwd_win32 , > GWL_EXSTYLE , > oldStyle | WS_EX_TOPMOST //& (!WS_EX_APPWINDOW) > ) > // --------------------------------
> Comprends pas pourquoi !?
C'est normal, çà n'a pas été prévu pour ça. C'est dans la doc MSDN :
WS_EX_TOPMOST To add or remove this style, use the SetWindowPos function.
Ok merci
On 23 août, 21:54, domi <d...@domi.com> wrote:
tsalm wrote:
> Par contre, si je fais ça, ca ne fonctionne pas :
> // --------------------------------
> LONG oldStyle = GetWindowLong( hwd_win32 , GWL_EXSTYLE );
> SetWindowLong(
> hwd_win32 ,
> GWL_EXSTYLE ,
> oldStyle | WS_EX_TOPMOST //& (!WS_EX_APPWINDOW)
> )
> // --------------------------------
> Comprends pas pourquoi !?
C'est normal, çà n'a pas été prévu pour ça.
C'est dans la doc MSDN :
WS_EX_TOPMOST
To add or remove this style, use the SetWindowPos function.