summaryrefslogtreecommitdiffstats
path: root/win
diff options
context:
space:
mode:
authorchengyemao <chengyemao>2005-01-09 00:22:48 (GMT)
committerchengyemao <chengyemao>2005-01-09 00:22:48 (GMT)
commit3d51fc76a503f6fbd5914a482da68aa6e5e7b933 (patch)
tree24980a63597070d37e5d66697e8242e41861d842 /win
parentfb63b2cd6068138fe2c79a830392832f598250ae (diff)
downloadtk-3d51fc76a503f6fbd5914a482da68aa6e5e7b933.zip
tk-3d51fc76a503f6fbd5914a482da68aa6e5e7b933.tar.gz
tk-3d51fc76a503f6fbd5914a482da68aa6e5e7b933.tar.bz2
Modified to keep consistent state of an embedded window
Diffstat (limited to 'win')
-rw-r--r--win/tkWinWm.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/win/tkWinWm.c b/win/tkWinWm.c
index 7593863..1e875d2 100644
--- a/win/tkWinWm.c
+++ b/win/tkWinWm.c
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkWinWm.c,v 1.88 2005/01/07 15:18:03 chengyemao Exp $
+ * RCS: @(#) $Id: tkWinWm.c,v 1.89 2005/01/09 00:22:48 chengyemao Exp $
*/
#include "tkWinInt.h"
@@ -2222,6 +2222,7 @@ UpdateWrapper(winPtr)
|SWP_NOOWNERZORDER);
}
TkpWmSetState(winPtr, state);
+ wmPtr->hints.initial_state = state;
if (hSmallIcon != NULL) {
SendMessage(wmPtr->wrapper,WM_SETICON,ICON_SMALL,(LPARAM)hSmallIcon);
@@ -2240,6 +2241,10 @@ UpdateWrapper(winPtr)
*/
if (winPtr->flags & TK_EMBEDDED) {
+ if(state != SendMessage(wmPtr->wrapper, TK_STATE, state, 0)) {
+ TkpWmSetState(winPtr, NormalState);
+ wmPtr->hints.initial_state = NormalState;
+ }
XMapWindow(winPtr->display, winPtr->window);
}