| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
OSX El Capitan 10.11.1 using JRE 1.8.0_66:
Animated NEWT GLWindow flickers at resize.
While at live resize the animation thread renders
into the live resized NSView which causes flickering on OSX 10.11.
Resolution is to pause animation during live resize
and resume at its end.
|
|
|
|
|
|
|
|
|
|
|
|
| |
- The NSWindow level must be set at window creation
- Levels are
- aontop: kCGMaximumWindowLevel
- aonbottom: kCGDesktopIconWindowLevel (w/ input)
- normal: NSNormalWindowLevel
- Hence we need to recreate the NSWindow if toggling the state,
similar to opaque .. etc.
|
|
|
|
|
|
|
|
|
|
|
| |
screen
- On OSX (similar to X11) a created window with size > screen
will get resized to fit screen size implicitly.
- Fix detects insets, position and size after onscreen window creation.
- Patch also merges insets and size change java callback
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Adopt to bug 1147, commit 2c88b6dfd4eb7e2cd9a50fa48e08ecafc980931a.
Using the native unique deviceID makes monitor identification more robust.
This also allows us simplify
displayID -> NSScreen-idx -> MonitorDevice
into
displayID -> MonitorDevice
and to survive a primary monitor change.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
NEWT Support / Fix JAWT getPixelScale deadlock
- NativeWindow/Surface/NEWT API DOC: Define Coordinate System of Window and Screen
- OSXUtil: Add getPixelScale(..) via Screen index and 'windowOrView'
- JAWTWindow/JAWTUtil.getPixelScale(..): Use pre-fetched AWT GraphicsConfiguration to solve AWT-TreeLock (deadlock)
- [Virtual] Viewport of MonitorDevice and Screen:
- Properly calculate and expose [virtual] viewport in window and pixel units
- OSX Monitor viewports in pixel units are 'reconstructed'
- Window/Viewport to Monitor selection shall be perfomed via window units (unique)
- OSX NEWT Window create/init (native): Use given size and coordinates even in fullscreen mode
Don't override by quering NSScreen coordinates, trust given values.
- Fix test cases, i.e. usage of pixel- and window-units
|
|
|
|
|
|
|
|
|
|
|
| |
*Common_GetJNIEnv()/_ReleaseJNIEnv() Methods and Usage / Check arguments ..
Since we still don't use inter-module native code sharing, align the JNIEnv get/release methods and usage.
Most beneficary here is OSX and the GLDebugMessageHandle,
both managed the JVM handle on their own - removed now.
Also ensuring that *Common_init(..) is called for all modules on all platforms.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
and Issues
- Refine Display.PointerIcon: Complete type allowing re-creation
- Add associated Display reference
- Add used IOUtil.ClassResources reference
- Add isValid()/validate() methods for recreation
- Refine API doc
- Move Display.destroyPointerIcon(PointerIcon) -> PointerIcon.destroy()
- Move DisplayImpl.PointerIconImpl -> PointerIconImpl (own source file)
- Creation/Destruction and setting of PointerIcon happens on EDT
- DisplayImpl.shutdownAll() and Display.destroy() calls destroyAllPointerIconFromList
- WindowDriver.setPointerIconImpl: Validates PointerIconImpl (i.e. re-creates if required)
- Fix 'initial' window.setPointerIcon(..) before createNative(..),
tested w/ TestGearsES2NEWT
- OSX Native Code:
- Move mouse and pointer-state handling from NewtMacWindow -> NewtView class
to retain states (pointer handle, pointer visibility, etc) when reparenting.
Reparenting will move an exisiting NewtView into a new NewtMacWindow.
- Enable all mouse move events:
- NewtView::mouseEnter [nsWin makeFirstResponder: nsView];
- NewtView::mouseExited if( !mouseConfined ) { [nsView resignFirstResponder]; }
- NewtView::mouseMoved issued [myCurser set] if required, fixing
OSX issue not updating NSCursor properly.
- MacWindow:
- Test NewtMacWindow, NewtView and NSCursor handles before usage
- Fix DBG_PRINT(..) warnings
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Pointer Icons
- Utilizing JOGL's PNG decoder for all icons, if available.
- Application/window icons:
- Providing default application/window icons in 16x16 and 32x32 size
- NewtFactory.setWindowIcons(..) or property 'newt.window.icons' maybe used to override default icons.
- Using icons at application/window instantiation
- Display.PointerIcons:
- NativeWindow Win32 WindowClass no more references a default cursor
in favor of fine grained cursor control [in NEWT]
- Display provides create/destroy methods,
where display destruction also releases open PointerIcon references.
- Window.setPointerIcon(..) sets custom PointerIcon
- Implemented Platforms
- X11
- Windows
- OSX
- Manual Test: TestGearsES2NEWT (Press 'c')
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Assume having focus in fullscreen-mode
- Reset NSApp's presentationOptions @ windowClose0()
Commit 69c334448cfe8af553fd97689137ecf8f996b378 started using the [NSApp setPresentationOptions: opts]
but missed to reset to defaults @ windowClose0();
- Assume having focus in fullscreen-mode
NewtMacWindow::windowDidBecomeKey()' is not always called in fullscreen-mode!
Note: OSX Fullscreen from a browser still shows the browser title-bar
until mouse-click. Don't know how to avoid this. Minor issue..
|
|
|
|
| |
favor of proper WM incl. ALT-TAB app-switching
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Support for all monitor devices and their available modes
- X11: Use RandR 1.3 if available
- Retrieve information
- Changing a monitor device's mode
- Support for dedicated and spannig fullscreen
- See <http://jogamp.org/files/screenshots/newt-mmonitor/html/>
- TODO:
- X11 RandR does _not_ relayout the virtual screen size
and neither the CRT's viewport.
We may need to relayout them if they were covering a seamless region
to achieve same experience!
- OSX: No machine to attach a secondary CRT -> TEST!
- Tested Manually for Regressions
- Linux ARMv6hf (Rasp-Pi/BCM, Panda/X11)
- Android (Huawei, Kindle)
- Tested Manually and junit:
- X11/Linux
- NV, ATI-Catalyst w/ 2 CRTs
- VBox w/ 4 CRTs
- Win/Windows
- NV, w/ 2 CRTs
- VBox w/ 4 CRTs
- X11/OpenIndiana, NV, 1 CRT
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
on main-thread w/o blocking; NEWT/WindowImpl: Volatile multithreaded mutable values
Similar to commits:
28c6472335b924080d638b33a28f8f4eedb459b1
f354fb204d8973453c538dda78a2c82c87be61dc
main-thread operations cannot block main-thread.
Luckily we are able to create the NSWindow and NSView instance uninitialized (deferred) on the current thread,
while issuing their initialization on the main-thread w/o blocking.
Further more a size glitch is fixed, which didn't take the title bar into account.
+++
NEWT/WindowImpl: Volatile multithreaded mutable values
Since position, size and other attributes might get changes off-thread, these fields needs to be volatile.
|
|
|
|
|
|
| |
screen position (Fixes resize -> position)
- Tested w/ NEWT GearsES2 and Java6 and Java7 on OSX
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
KeyEvent handling while distinguish keyCode (kbd layout independent) and keySym (kbd layout dependent)
API Changes:
- Virtual key codes and symbols are of type short.
- KeyEvent.keySymbol() shall return a layout dependent value (Bug 641)
- Method returns former keyCode() value, which was layout dependent.
- Returns 'short' value
- KeyEvent.keyCode() returns a short value, instead of int
- KeyEvent.keyCode() shall return a layout independent value (Bug 641)
- To ease implementation, we only 'require' the scan code to be mapped to a 'US Keyboard layout',
which allows reusing layout dependent code while preserving the goal to have a fixed physical key association
- Implementation status:
- Windows OK
- X11 TODO
- OSX: 50/50 TODO
- Using layout independent 'action keys'
- Using layout dependent 'printable keys'
- returning above semantics for both, keyCode and keySym
- Android 50/50 TODO
- Returning the layout independent keyCode
- Mapping probably incomplete
- KeyEvent.EVENT_KEY_TYPED and KeyListener.keyTyped(KeyEvent) (Bug 688)
- Marked DEPRECATED
- No more called for auto-repeat events
- Synthesized in WindowImpl.consumeKeyEvent(..): No more injection by native- or java driver code
- NEWTEvent.eventType: int -> short
- field, as well as all method involving eventType changed to short.
- NEWTEvent.isSystemEvent: REMOVED
- Never used as well as never being implemented properly
Internal Changes:
- Simplified keyEvent driver code
- Especially the Windows native driver's mapping code
could be simplified using scanCode and MapVirtualKeyEx
- NEWT Event Factories: hashMap -> switch/case
Unit Tests:
-
- Added NewtCanvasAWT Offscreen Layer Tests
important to test the AWT -> NEWT translation on OSX/CALayer:
- TestNewtKeyCodeModifiersAWT
- TestNewtKeyCodesAWT
- TestNewtKeyEventAutoRepeatAWT
- TestNewtKeyEventOrderAWT
- TestNewtKeyPressReleaseUnmaskRepeatAWT
|
|
|
|
|
|
|
| |
- X11: Add VK_QUOTE mapping
- OSX: Add single shift, ctrl alt key press;
Fix mapping: Command -> Windows, Option -> ALT, add BACK_QUOTE and QUOTE.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- NEWT/WindowImpl:
- 'void windowDestroyNotify()' -> 'boolean windowDestroyNotify(boolean force)', allowing to signal a forced close,
as well as replying whether the window has been closed. (called by native code)
- destroy(): set states before releasing the window lock
- NEWT/X11: Pass windowDeleteAtom for reconfigure window, in case of reparenting child to top-level
- NEWT/OSX:
- Add 'BOOL windowShouldClose()' impl., ie. having a chance to reject the close attempt
- Common impl. for 'windowShouldClose' and 'windowWillClose' -> 'windowClosingImpl'
utilizing new 'windowDestroyNotify' code (see above).
Fixes bug 560.
- NEWT/JOGLNewtApplet1Run: Refine out-of browser window behavior for window-close button
- default: move NEWT window back to browser parent
- closeable: close NEWT window
- jogl-test-applets: Add NApplet-Closeable test (Applet out-of browser window is closable)
|
|
|
|
|
|
|
|
| |
case it's already in destruction (destroyNotifySend via windowWillClose())
This fixes the double release crash of the NSWindow, at the end of an application.
Tested on OSX 10.6.8 and 10.7.3.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
lostFocus (resignKeyWindow) when in fullscreen mode; Ignore invalid key release/type events.
- Cleanup 'javaWindowObject' @ window-close & avoid NPE
Ensure that the direct window.close() impl. removes the global reference
and that all use cases check for NULL pointer.
- Disable lostFocus (resignKeyWindow) when in fullscreen mode
Similar to the X11 KDE bug, OS X delivers a lostFocus event
which we prevent from being processed in fullscreen mode.
- Ignore invalid key release/type events
In case of offscreen/onscreen switching (fullscreen/reparenting) via destroy/create,
the still pressed key would be send to the new window and repeat the action (key typed).
State validation discards the double processing.
|
|
|
|
| |
Remove warning of unused var
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
focus/isInside
On OS X 10.6.8 the lack of responder method declarations (mouseEntered, ..)
lead to ignore the impl. callbacks.
'isMouseInside' cannot rely on 'mouseExit'/'mouseEntered' when
setMouseInvisible() is being called, deduce it manually.
focusLost == mouseExit (OS X behavior), hence focusGained needs
to set mouse invisible/visible in case it's requested.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Allow negative window position, using flag 'autoPosition' to mark a custom user position.
This impacts Windows and X11 window creation code, which supports native auto positioning.
- Screen: Validate Screen-Index.
In 'big-desktop' mode the Screen index is always 0. This is true for X11 with
Xinerama enabled and MS-Windows in general.
Platforms w/o multiple Screen support always use index 0.
- X11: Separate X11 Display/Screen/Window native code in their respective C files
- Windows test scripts: use '%*' to catch all arguments
- Add missing (c)
|
|
|
|
|
| |
Attempt to fix the shared-context-multithreading bug (eg. TestSharedContextVBOES2NEWT2)
via proper locking .. but seems not to be sufficient (yet).
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
instance ; Applet's on OS X are working
Generalize OffscreenLayerSurface
- Using new OffscreenLayerSurface allows using this functionality in a clean manner,
ie. no 'dirty' usage of MacOSXJAWTWindow in a JOGL GL class.
- 'Promoting' OffscreenLayerSurface functionality to JAWTWindow
and it's handling to GLDrawableFactoryImpl::createGLDrawable().
- Move MacOSXCGLDrawableFactory's "MacOSXJAWTWindow getLayeredSurfaceHost(NativeSurface surface)"
to NativeWindowFactory "OffscreenLayerSurface getOffscreenLayerSurface(NativeSurface surface, boolean ifEnabled)"
Use local JAWT instance
- Only w/ a local JAWT instance per JAWTWindow it is possible to switch between
offscreen-layer and onscreen. We also have to determing offscreen-layer lazy
at surface lock, since only at that time we have knowledge whether it's an Applet
or not.
+++
ContextUpdater:
Use local pthread mutex, add DEBUG output
JAWTWindow/NewtCanvasAWT:
Adding methods to request offscreen-layer-surface (if supported),
besides 'if applet' this may trigger the new functionality.
+++
Applet's on OS X are working:
- OS X 10.6.4
- Safari:
- Hangs for a while at start .. whole screen freezes .. approx. 10s
- Sometimes crashes when Applet stops - after all our resources are released!
- Keyboard input isn't assigned sometimes.
- Otherwise .. works well, incl. offscreen/onscreen parenting
- Firefox 8.0:
- Hangs for a while at start .. whole screen freezes .. approx. 10s
- Sometimes crashes when Applet stops - after all our resources are released!
- Keyboard input is never assigned.
- Otherwise .. works well, incl. offscreen/onscreen parenting
- OS X 10.7
- Safari:
- Sometimes crashes when Applet stops - after all our resources are released!
- Keyboard input isn't assigned sometimes.
- Otherwise .. works well, incl. offscreen/onscreen parenting
- Firefox 8.0:
- Sometimes crashes when Applet stops - after all our resources are released!
- Keyboard input is never assigned.
- Otherwise .. works well, incl. offscreen/onscreen parenting
|
|
|
|
|
|
|
|
|
| |
- Use proper OSX types for NS/CGL prototypes (gluegen) and impl.
- Impl layeredSurface (native):
- OSXUtil: NSView backing creation
- OSXUtil: AttachJAWTSurfaceLayer
- CGL: NSOpenGLLayer type impl. and hook
|
|
|
|
|
|
|
|
| |
needsDisplay/displayIfNeeded, ..
- Add 'soft' pthread locking (blockin) - impacts: needsDisplay/displayIfNeeded, ..
- needsDisplay/displayIfNeeded also respects destroyNotifySend (ignore action if set)
|
| |
|
|
|
|
| |
sendFocusLost/sendFocusGained -> focusChanged
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
windowRepaint() callback
- act on positionChanged(..) only for realized windows,
otherwise we could end in an AWT deadlock (AWT parent window).
- add view parenting calls (addSubView/removeFromSuperview)
- attachToParent after view configuration
- allow concurrently view draw
- add windowRepaint() callback (native -> java)
- add more debug tracing
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
behavior/tests)
- Old code was just requesting the focus and made the window upfront
and notifying a gained focus to WindowImpl. (hack)
- Using proper requestFocus impl. issuing focusAction() and utilizing native
focus gained/lost messages. This distinguish between 'makeKey' and 'orderFront'.
Also requesting and accepting (view) first responder role, which is a precursor
to proper gained/lost focus handling on OSX.
- NEWTCanvasAWT: Adding 'steal AWT focus':
+++
void requestFocus() {
super.requestFocus(); // AWT
< steal AWT focus >
NEWTChild.requestFocus()
}
+++
Helps make the focus traversal between NEWT/AWT more reliable.
Happend on OSX that AWT (NewtCanvasAWT instance) didn't release the focus
after NEWT child gained the same.
We are not able to use the 'focusAction()' here (disabled in this code path)
due to AWT-EDT blocking and recursive focus changes. The latter is also
intendend to request the AWT focus first ..
- AWT/NEWT focus test 01 passes on OSX
|
|
|
|
| |
warp) - cleanup pos/coord translations
|
|
|
|
|
|
|
|
|
|
|
|
| |
pos/size notifications
Newt/MacWindow
- remove redundant manual window-move/set-size code
- Use local getLocationOnScreen(..), fixes positionChanged(..)
- setFrameTopLeftPoint(..) use totalHeight (w/ insets)
- create: don't 'retain' the window reference (ref counter)
- close: release view,
- cache insets - to be used @ create
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
'defer' 1st argument
- Adapt to GlueGen's Lock ChangeSet: e4baba27507ce78e64a150ec6f69fb96f5721a34
- All java callbacks for native have 'defer' 1st argument.
This allows enqueuing resulting events to the EDT if required,
ie. the native thread may not be 'compatible' (MacOSX).
- MacOSX-Native: enqueue key/mouse events and defer:=true for all java callbacks
Since we are comming from a 3rd-party thread (AWT/NSApp-MainThread)
we shall not abuse it.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Feature related:
- Added always-on-top
- Added translucency
- Child Window Position
- AWT parent: manual traverse up the tree and calc position on screen
(Problem: the parent view rect is not at the proper position,
but covers the whole frame)
EDTUtil related:
- Works now w/ AWT ot headless (again)
- OSX native JNI callbacks gathering JNIEnv properly
and attaches/detaches thread.
- AWT case: using AWT-Event which properly dispatches our cocoa events
- MainThread (headless) case: Fork off thread w/ main class
and kick off NSApp run().
This leads to same behavior as w/ AWT case.
- Using DefaultEDTUtil
- Cleanup MainThread (implements EDTUtil)
- Currently not used as EDTUtil (osx), just as launcher
- Removed EDTUtil impl code, reuse DefaultEDTUtil
- Cleanup AWTEDTUtil (implements EDTUtil)
- Currently not used as EDTUtil (osx)
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
- Passed tests MacOSX, LinuxX64 ATI/NVidia/MesaSW, Win32(VBox - !offscreen)
- timeout -> 30s
- Surface validation after lock on GLContextImpl ..
NEWT
- declare <NSWindowDelegate> only for MacOSX >= 10.6
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
JOGL-JAR-BUNDELING.txt
A first FAQ about the (new) JAR partitioning.
lstjars/lstjars.linux_amd64-20100406.log
A first deployment payload measurement in kBytes :)
New JAR Partitioning:
All-In-One (*all*):
- with AWT
- without AWT
See JOGL-JAR-BUNDELING.txt
Atomic:
See JOGL-JAR-BUNDELING.txt
- Removed property setup.noall, since the *all* targets are mandatory now.
Currently
- Added gl4 part (still empty)
- Fixed make/lstjars.sh and etc/profile.jogl (new JAR bundles)
- Fixed make/lstjars.sh to produce JAR and PACK200 numbers,
and using the *all* bundles if possible.
MacOsX:
- Fix missing refactoring in src/newt/native/MacWindow.m
- Adding missing NSWindowDelegate protocol to NewtMacWindow
as mandatory since 10.3.6
Misc:
- Applied: 'gluegen.cpptasks.striplibs' to all native libraries.
- Use path.seperator (ant) and system.env.library.path (gluegen),
for junit runs.
|
| |
|
|
git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@1959 232f8b59-042b-4e1e-8c03-345bb8c30851
|