aboutsummaryrefslogtreecommitdiffstats
path: root/src/newt/native/WindowsWindow.c
diff options
context:
space:
mode:
authorDmitri Trembovetski <[email protected]>2009-04-10 19:27:58 +0000
committerDmitri Trembovetski <[email protected]>2009-04-10 19:27:58 +0000
commitda57c2c820d1cad4365a6a24018a90f46eb29a5f (patch)
treeaf54e2035fb768c37e4feb4038be7cb9df08acbb /src/newt/native/WindowsWindow.c
parent16767ef62eec3e843c80b7b546a0b38860190fb7 (diff)
Newt fixes for Windows implementation: implemented undecorated window style
git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1900 232f8b59-042b-4e1e-8c03-345bb8c30851
Diffstat (limited to 'src/newt/native/WindowsWindow.c')
-rwxr-xr-xsrc/newt/native/WindowsWindow.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/newt/native/WindowsWindow.c b/src/newt/native/WindowsWindow.c
index 5fa5cf9ba..a742f5acf 100755
--- a/src/newt/native/WindowsWindow.c
+++ b/src/newt/native/WindowsWindow.c
@@ -161,7 +161,6 @@ static LRESULT CALLBACK wndProc(HWND wnd, UINT message,
(*env)->CallVoidMethod(env, window, sizeChangedID, (jint) rc.right, (jint) rc.bottom);
break;
- // FIXME: define constants for the mouse buttons and modifiers
case WM_LBUTTONDOWN:
(*env)->CallVoidMethod(env, window, sendMouseEventID, (jint) EVENT_MOUSE_PRESSED,
ConvertModifiers(wParam), (jint) LOWORD(lParam), (jint) HIWORD(lParam), (jint) 1);
@@ -303,11 +302,12 @@ JNIEXPORT jlong JNICALL Java_com_sun_javafx_newt_windows_WindowsWindow_RegisterW
/*
* Class: com_sun_javafx_newt_windows_WindowsWindow
* Method: CreateWindow
- * Signature: (Ljava/lang/String;JJIIII)J
+ * Signature: (Ljava/lang/String;JJZIIII)J
*/
JNIEXPORT jlong JNICALL Java_com_sun_javafx_newt_windows_WindowsWindow_CreateWindow
(JNIEnv *env, jobject obj, jstring windowClassName, jlong hInstance, jlong visualID,
- jint jx, jint jy, jint defaultWidth, jint defaultHeight)
+ jboolean bIsUndecorated,
+ jint jx, jint jy, jint defaultWidth, jint defaultHeight)
{
const TCHAR* wndClassName = NULL;
DWORD windowStyle = WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_VISIBLE;
@@ -331,7 +331,11 @@ JNIEXPORT jlong JNICALL Java_com_sun_javafx_newt_windows_WindowsWindow_CreateWin
#else
x = CW_USEDEFAULT;
y = 0;
- windowStyle |= WS_OVERLAPPEDWINDOW;
+ if (bIsUndecorated) {
+ windowStyle |= WS_POPUP | WS_SYSMENU | WS_MAXIMIZEBOX | WS_MINIMIZEBOX;
+ } else {
+ windowStyle |= WS_OVERLAPPEDWINDOW;
+ }
#endif
(void) visualID; // FIXME: use the visualID ..